/* === AMAZON-STYLE PRODUCT COMPONENTS === */

/* === PRODUCT CARDS === */
.product-card {
    background: var(--background-white);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    overflow: hidden;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
    position: relative;
}

.product-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    border-color: var(--amazon-orange);
}

/* Product Image */
.product-card-image {
    position: relative;
    height: 200px;
    overflow: hidden;
    background: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 15px;
}

.product-card-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.product-card:hover .product-card-image img {
    transform: scale(1.05);
}

/* Product Badges */
.product-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    padding: 4px 8px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: bold;
    color: white;
    z-index: 5;
}

.product-badge.sale {
    background: #cc0c39;
}

.product-badge.bestseller {
    background: var(--amazon-orange);
    top: 30px;
}

.product-badge.new {
    background: #067d62;
    top: 52px;
}

.product-badge.choice {
    background: #232f3e;
    top: 74px;
}

/* Product Info */
.product-card-info {
    padding: 15px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.product-title {
    font-size: 14px;
    line-height: 1.4;
    margin-bottom: 8px;
    color: var(--link-color);
    font-weight: normal;
    height: 40px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    text-decoration: none;
}

.product-title:hover {
    color: var(--amazon-orange);
    text-decoration: underline;
}

/* Product Rating */
.product-rating {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-bottom: 8px;
}

.product-rating .stars {
    color: #ffa41c;
    font-size: 14px;
    letter-spacing: 1px;
}

.product-rating .rating-count {
    color: var(--link-color);
    font-size: 12px;
    text-decoration: none;
}

.product-rating .rating-count:hover {
    color: var(--amazon-orange);
    text-decoration: underline;
}

/* Product Price */
.product-price {
    margin-bottom: 12px;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.product-price .price-current {
    font-size: 18px;
    font-weight: bold;
    color: #B12704;
}

.product-price .price-original {
    font-size: 13px;
    color: #999;
    text-decoration: line-through;
}

.product-price .discount {
    background: #CC0C39;
    color: white;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: bold;
    align-self: flex-start;
}

/* Product Description */
.product-excerpt {
    color: var(--text-color-muted);
    font-size: 13px;
    line-height: 1.4;
    margin-bottom: 12px;
    flex-grow: 1;
}

/* Stock Status */
.stock-status {
    margin-bottom: 10px;
    font-size: 12px;
    font-weight: bold;
}

.stock-status.in-stock {
    color: #067d62;
}

.stock-status.low-stock {
    color: #cc0c39;
}

.stock-status.out-of-stock {
    color: #999;
}

/* Add to Cart Button */
.product-actions {
    margin-top: auto;
}

.product-actions .button,
.product-actions .add_to_cart_button {
    width: 100%;
    background: var(--amazon-yellow);
    border: 1px solid #a88734;
    color: var(--text-color-dark);
    padding: 8px 12px;
    border-radius: var(--border-radius);
    font-weight: bold;
    text-align: center;
    cursor: pointer;
    transition: background-color 0.2s ease;
    text-decoration: none;
    display: block;
    font-size: 14px;
}

.product-actions .button:hover,
.product-actions .add_to_cart_button:hover {
    background: var(--button-secondary-hover);
    color: var(--text-color-dark);
    text-decoration: none;
}

/* === PRODUCT GRIDS === */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.product-carousel-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

/* === CATEGORY CARDS === */
.category-card {
    background: var(--background-white);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    overflow: hidden;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.category-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.15);
}

.category-card-image {
    height: 200px;
    overflow: hidden;
    position: relative;
    background: #f8f9fa;
}

.category-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.category-card:hover .category-card-image img {
    transform: scale(1.05);
}

.category-card-content {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.category-card h3 {
    color: var(--text-color-dark);
    font-size: 18px;
    margin-bottom: 8px;
    font-weight: bold;
}

.category-description {
    color: var(--text-color-muted);
    font-size: 13px;
    margin-bottom: 12px;
    line-height: 1.4;
}

.category-products {
    background: #f0f2f2;
    padding: 8px 12px;
    border-radius: var(--border-radius);
    margin-bottom: 15px;
    font-size: 12px;
    color: var(--text-color-muted);
}

.shop-now-link {
    background: var(--amazon-yellow);
    color: var(--text-color-dark);
    padding: 10px 16px;
    border-radius: var(--border-radius);
    text-decoration: none;
    font-weight: bold;
    text-align: center;
    transition: background-color 0.2s ease;
    margin-top: auto;
    display: block;
}

.shop-now-link:hover {
    background: var(--button-secondary-hover);
    color: var(--text-color-dark);
    text-decoration: none;
}

/* === PRODUCT SECTIONS === */
.product-section {
    background: var(--background-white);
    margin-bottom: 20px;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    overflow: hidden;
}

.product-section-header {
    padding: 20px;
    border-bottom: 1px solid var(--border-color);
    background: #f8f9fa;
}

.product-section h2 {
    color: var(--text-color-dark);
    font-size: 24px;
    margin-bottom: 5px;
    font-weight: bold;
}

.product-section-subtitle {
    color: var(--text-color-muted);
    font-size: 14px;
}

.product-section-content {
    padding: 20px;
}

/* === HERO SECTION === */
.hero-section {
    min-height: 400px;
    background: linear-gradient(135deg, #232f3e 0%, #37475a 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--text-color-light);
    margin-bottom: 20px;
    position: relative;
    overflow: hidden;
}

.hero-content {
    z-index: 2;
    max-width: 600px;
    padding: 40px 20px;
}

.hero-title {
    font-size: 2.5rem;
    margin-bottom: 15px;
    font-weight: bold;
}

.hero-subtitle {
    font-size: 1.2rem;
    margin-bottom: 25px;
    opacity: 0.9;
}

.hero-cta {
    background: var(--amazon-yellow);
    color: var(--text-color-dark);
    padding: 12px 24px;
    border-radius: var(--border-radius);
    font-weight: bold;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s ease;
    font-size: 16px;
}

.hero-cta:hover {
    background: var(--button-secondary-hover);
    color: var(--text-color-dark);
    transform: translateY(-2px);
    text-decoration: none;
}

/* === RESPONSIVE DESIGN === */
@media (max-width: 768px) {
    .products-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 15px;
    }
    
    .product-carousel-grid {
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .products-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 10px;
    }
    
    .product-card-image {
        height: 150px;
        padding: 10px;
    }
    
    .product-card-info {
        padding: 12px;
    }
    
    .hero-title {
        font-size: 1.5rem;
    }
    
    .product-section-content {
        padding: 15px;
    }
}