/* Affiliate Product Cards */
.products-section {
    margin: 40px 0;
    padding: 30px 0;
    background: #f8f9fa;
    border-radius: 12px;
}

.products-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding: 0 20px;
}

.products-section-title {
    font-size: 24px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0;
}

.products-section-title i {
    color: #007bff;
    margin-right: 10px;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 15px;
    padding: 0 20px;
}

.product-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    position: relative;
}

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

.product-image-wrapper {
    position: relative;
    padding-top: 100%; /* 1:1 Aspect Ratio */
    background: #f5f5f5;
    overflow: hidden;
}

.product-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 12px;
}

.product-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: #ff4444;
    color: white;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    z-index: 2;
}

.product-badge.featured {
    background: #ffa500;
}

.product-content {
    padding: 12px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.product-brand {
    font-size: 11px;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
    font-weight: 600;
}

.product-title {
    font-size: 13px;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 8px 0;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 34px;
}

.product-pricing {
    margin: 8px 0;
}

.product-price-row {
    display: flex;
    align-items: baseline;
    gap: 6px;
    margin-bottom: 3px;
    flex-wrap: wrap;
}

.product-sale-price {
    font-size: 18px;
    font-weight: 700;
    color: #1a1a1a;
}

.product-original-price {
    font-size: 12px;
    color: #999;
    text-decoration: line-through;
}

.product-discount {
    font-size: 12px;
    color: #00a650;
    font-weight: 600;
}

.product-cashback {
    font-size: 11px;
    color: #007bff;
    background: #e7f3ff;
    padding: 3px 6px;
    border-radius: 4px;
    display: inline-block;
    margin-top: 4px;
}

.product-footer {
    padding: 0 12px 12px;
    margin-top: auto;
}

.product-buy-btn {
    display: block;
    width: 100%;
    padding: 10px;
    background: #ed174f;
    color: white;
    text-align: center;
    border-radius: 8px;
    font-weight: 600;
    font-size: 13px;
    text-decoration: none;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.product-buy-btn:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 12px rgba(237, 23, 79, 0.4);
    background: #d01545;
    color: white;
    text-decoration: none;
}

.product-buy-btn i {
    margin-right: 5px;
}

/* Best Price Badge */
.product-best-price {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #00a650;
    color: white;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    z-index: 2;
}

/* Responsive */
@media (max-width: 768px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
        padding: 0 10px;
    }
    
    .products-section {
        padding: 20px 0;
    }
    
    .products-section-header {
        padding: 0 10px;
        margin-bottom: 16px;
    }
    
    .products-section-title {
        font-size: 18px;
    }
    
    .product-content {
        padding: 10px;
    }
    
    .product-title {
        font-size: 13px;
        min-height: 36px;
    }
    
    .product-sale-price {
        font-size: 16px;
    }
    
    .product-original-price {
        font-size: 12px;
    }
    
    .product-discount {
        font-size: 11px;
    }
    
    .product-cashback {
        font-size: 10px;
        padding: 3px 6px;
    }
    
    .product-footer {
        padding: 0 10px 10px;
    }
    
    .product-buy-btn {
        padding: 10px;
        font-size: 13px;
    }
    
    .product-badge {
        font-size: 10px;
        padding: 3px 8px;
    }
}

@media (max-width: 480px) {
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
        padding: 0 8px;
    }
    
    .products-section {
        padding: 15px 0;
        border-radius: 8px;
    }
    
    .products-section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        padding: 0 8px;
    }
    
    .products-section-title {
        font-size: 16px;
    }
    
    .product-content {
        padding: 8px;
    }
    
    .product-brand {
        font-size: 10px;
    }
    
    .product-title {
        font-size: 12px;
        min-height: 32px;
        -webkit-line-clamp: 2;
    }
    
    .product-pricing {
        margin: 6px 0;
    }
    
    .product-sale-price {
        font-size: 15px;
    }
    
    .product-original-price {
        font-size: 11px;
    }
    
    .product-discount {
        font-size: 10px;
    }
    
    .product-cashback {
        font-size: 9px;
        padding: 2px 5px;
        margin-top: 4px;
    }
    
    .product-footer {
        padding: 0 8px 8px;
    }
    
    .product-buy-btn {
        padding: 8px;
        font-size: 12px;
        border-radius: 6px;
    }
    
    .product-badge {
        font-size: 9px;
        padding: 2px 6px;
        top: 6px;
        left: 6px;
    }
    
    .product-image {
        padding: 10px;
    }
}

/* Empty State */
.products-empty {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}

.products-empty i {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.5;
}

.products-empty p {
    font-size: 16px;
    margin: 0;
}
