/* ============================================
   BESTSELLERS SECTION - Style Pizze and Cook
   ============================================ */

.bestsellers-section {
    padding: 60px 0;
    width: 100vw !important;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    background: #000000;
}

/* Header */
.bestsellers-header {
    text-align: center;
    margin-bottom: 50px;
    padding: 0 135px;
}

.bestsellers-title {
    font-size: 32px;
    font-weight: 600;
    letter-spacing: 8px;
    text-transform: uppercase;
    margin: 0 0 20px 0;
    color: #ffffff;
}

.bestsellers-subtitle {
    font-size: 16px;
    line-height: 1.6;
    color: #ffffff;
    max-width: 700px;
    margin: 0 auto;
}

/* Grid */
.bestsellers-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    max-width: 100%;
    margin: 0 auto;
    padding: 0 15% ;
}

/* Card */
.bestseller-card {
    background: #ffffff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.bestseller-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

/* Image */
.bestseller-card-image {
    position: relative;
    width: 100%;
    height: 280px;
    overflow: hidden;
    background: #f5f5f5;
}

.bestseller-card-image a {
    display: block;
    width: 100%;
    height: 100%;
}

.bestseller-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.bestseller-card:hover .bestseller-card-image img {
    transform: scale(1.1);
}

/* Content */
.bestseller-card-content {
    padding: 25px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.bestseller-card-title {
    font-size: 20px;
    font-weight: 600;
    margin: 0 0 12px 0;
    line-height: 1.3;
}

.bestseller-card-title a {
    color: #000000;
    text-decoration: none;
    transition: color 0.3s ease;
}

.bestseller-card-title a:hover {
    color: #FF3200;
}

.bestseller-card-description {
    font-size: 14px;
    line-height: 1.6;
    color: #666666;
    margin: 0 0 20px 0;
    flex-grow: 1;
}

/* Remove HTML tags from description */
.bestseller-card-description p {
    margin: 0;
}

/* Footer */
.bestseller-card-footer {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: auto;
}

.bestseller-card-price {
    font-size: 24px;
    font-weight: 700;
    color: #FF3200;
}

/* Add to cart button */
.add-to-cart-form {
    margin: 0;
    width: 100%;
}

.bestseller-add-to-cart {
    background: #000000;
    color: #ffffff;
    border: none;
    padding: 12px 30px;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.3s ease;
    border-radius: 0;
    letter-spacing: 1px;
    width: 100%;
}

.bestseller-add-to-cart:hover {
    background: #FF3200;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 50, 0, 0.3);
}

.bestseller-add-to-cart:active {
    transform: translateY(0);
}

/* ============================================
   RESPONSIVE
   ============================================ */

/* Desktop large */
@media (max-width: 1400px) {
    .bestsellers-grid {
        gap: 25px;
        padding: 0 100px;
    }
    
    .bestsellers-header {
        padding: 0 100px;
    }
}

/* Laptop */
@media (max-width: 1199px) {
    .bestsellers-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
        padding: 0 60px;
    }
    
    .bestsellers-header {
        padding: 0 60px;
    }
    
    .bestsellers-title {
        font-size: 28px;
        letter-spacing: 6px;
    }
    
    .bestseller-card-image {
        height: 250px;
    }
}

/* Tablet */
@media (max-width: 991px) {
    .bestsellers-section {
        padding: 40px 0;
    }
    
    .bestsellers-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
        padding: 0 40px;
    }
    
    .bestsellers-header {
        padding: 0 40px;
    }
    
    .bestsellers-title {
        font-size: 26px;
        letter-spacing: 5px;
    }
    
    .bestsellers-subtitle {
        font-size: 15px;
    }
    
    .bestseller-card-image {
        height: 220px;
    }
    
    .bestseller-card-title {
        font-size: 18px;
    }
    
    .bestseller-card-price {
        font-size: 22px;
    }
    
    .bestseller-add-to-cart {
        padding: 10px 25px;
        font-size: 13px;
    }
}

/* Mobile */
@media (max-width: 767px) {
    .bestsellers-section {
        padding: 35px 0;
    }
    
    .bestsellers-header {
        margin-bottom: 30px;
        padding: 0 20px;
    }
    
    .bestsellers-title {
        font-size: 22px;
        letter-spacing: 4px;
        margin-bottom: 15px;
    }
    
    .bestsellers-subtitle {
        font-size: 14px;
    }
    
    .bestsellers-grid {
        grid-template-columns: 1fr;
        gap: 22px;
        padding: 0px 12%;
    }
    
    .bestseller-card-image {
        height: 250px;
    }
    
    .bestseller-card-content {
        padding: 20px;
    }
    
    .bestseller-card-title {
        font-size: 18px;
        margin-bottom: 10px;
    }
    
    .bestseller-card-description {
        font-size: 13px;
        margin-bottom: 15px;
    }
    
    .bestseller-add-to-cart {
        padding: 14px 20px;
    }
}

/* Small mobile */
@media (max-width: 480px) {
    .bestsellers-title {
        font-size: 20px;
        letter-spacing: 3px;
    }
    
    .bestseller-card-image {
        height: 200px;
    }
    
    .bestseller-card-price {
        font-size: 20px;
    }
}

/* ============================================
   LOADING STATE
   ============================================ */

.bestseller-card.loading {
    pointer-events: none;
    opacity: 0.6;
}

.bestseller-add-to-cart:disabled {
    background: #cccccc;
    cursor: not-allowed;
}

.bestseller-add-to-cart:disabled:hover {
    background: #cccccc;
    transform: none;
    box-shadow: none;
}

/* ============================================
   ANIMATION VARIANTS
   ============================================ */

.bestseller-card {
    opacity: 0;
    animation: fadeInUp 0.6s ease forwards;
}

.bestseller-card:nth-child(1) { animation-delay: 0.1s; }
.bestseller-card:nth-child(2) { animation-delay: 0.2s; }
.bestseller-card:nth-child(3) { animation-delay: 0.3s; }
.bestseller-card:nth-child(4) { animation-delay: 0.4s; }
.bestseller-card:nth-child(5) { animation-delay: 0.5s; }
.bestseller-card:nth-child(6) { animation-delay: 0.6s; }
.bestseller-card:nth-child(7) { animation-delay: 0.7s; }
.bestseller-card:nth-child(8) { animation-delay: 0.8s; }

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Performance optimizations */
.bestseller-card-image,
.bestseller-card-image img {
    will-change: transform;
}

.bestseller-card:hover {
    will-change: transform, box-shadow;
}


