/**
 * Frontend Upsell Same Design Slider
 * Tương thích Flatsome Theme & Responsive mọi thiết bị
 */

.trumpany-group-products {
    width: 100%;
    margin: 24px 0 32px;
    padding: 24px 0 8px;
    border-top: 1px solid #eaeaea;
    clear: both;
}

.trumpany-group-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 16px;
}

.trumpany-group-header h2 {
    margin: 0;
    padding: 0;
    font-size: 20px;
    font-weight: 700;
    line-height: 1.3;
    color: #222222;
}

.trumpany-group-nav {
    display: flex;
    gap: 8px;
}

.trumpany-group-nav button {
    width: 34px;
    height: 34px;
    min-height: 34px;
    padding: 0;
    margin: 0;
    border: 1px solid #dcdfe4;
    border-radius: 50%;
    background: #ffffff;
    color: #333333;
    font-size: 15px;
    line-height: 32px;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.trumpany-group-nav button:hover {
    transform: translateY(-1px);
    border-color: #008060;
    color: #008060;
    background: #f1f8f5;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

.trumpany-group-slider {
    display: flex;
    gap: 14px;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    padding-bottom: 12px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}

.trumpany-group-slider::-webkit-scrollbar {
    display: none;
}

.trumpany-group-item {
    flex: 0 0 calc((100% - 70px) / 6);
    min-width: 0;
    scroll-snap-align: start;
    box-sizing: border-box;
}

.trumpany-group-image {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 1/1;
    overflow: hidden;
    border-radius: 10px;
    background: #f7f7f7;
    border: 1px solid #eceeed;
}

.trumpany-group-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    margin: 0;
    transition: transform 0.3s ease;
}

.trumpany-group-item:hover .trumpany-group-image img {
    transform: scale(1.05);
}

.trumpany-group-info {
    padding-top: 8px;
}

.trumpany-group-title {
    display: -webkit-box;
    overflow: hidden;
    color: #222222;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.35;
    text-decoration: none;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    min-height: 35px;
    transition: color 0.15s ease;
}

.trumpany-group-title:hover {
    color: #008060;
}

.trumpany-group-price {
    margin-top: 5px;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.3;
    color: #111111;
}

.trumpany-group-price del {
    margin-right: 5px;
    color: #999999;
    font-size: 12px;
    font-weight: 400;
    opacity: 1;
}

.trumpany-group-price ins {
    color: #e53935;
    text-decoration: none;
    font-weight: 700;
}

@media (max-width: 1024px) {
    .trumpany-group-item {
        flex-basis: calc((100% - 42px) / 4);
    }
}

@media (max-width: 767px) {
    .trumpany-group-products {
        margin-top: 16px;
        padding-top: 18px;
    }
    .trumpany-group-header {
        margin-bottom: 12px;
    }
    .trumpany-group-header h2 {
        font-size: 17px;
    }
    .trumpany-group-nav button {
        width: 32px;
        height: 32px;
        min-height: 32px;
    }
    .trumpany-group-slider {
        gap: 10px;
        padding-right: 18%;
    }
    .trumpany-group-item {
        flex: 0 0 44%;
    }
    .trumpany-group-image {
        border-radius: 8px;
    }
    .trumpany-group-title {
        font-size: 12px;
    }
    .trumpany-group-price {
        font-size: 13px;
    }
    .trumpany-group-price del {
        font-size: 11px;
    }
}

@media (max-width: 420px) {
    .trumpany-group-item {
        flex-basis: 48%;
    }
}
