/* ===============================================
   4. HERO SECTION & CAROUSEL
   =============================================== */

/* Hero Carousel Styles */
.hero-carousel-section {
    position: relative;
    overflow: hidden;
}

.carousel-background {
    height: 70vh;
    background-size: cover;
    background-position: center;
    position: relative;
}

.carousel-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
}

.hero-content {
    position: relative;
    z-index: 2;
    color: white;
    padding: 2rem;
    animation-duration: 1.5s;
}

.hero-title {
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    margin-bottom: 1rem;
}

.hero-text {
    font-size: 1.2rem;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
    margin-bottom: 2rem;
    max-width: 600px;
}

/* Custom carousel indicators */
.carousel-indicators [data-bs-target] {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    margin: 0 6px;
    background-color: rgba(255, 255, 255, 0.5);
    border: none;
    opacity: 0.5;
    transition: opacity 0.3s ease;
}

.carousel-indicators .active {
    background-color: white;
    opacity: 1;
}

/* Custom control styling */
.carousel-control-prev,
.carousel-control-next {
    width: 5%;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    width: 40px;
    height: 40px;
    background-color: rgba(0, 0, 0, 0.6);
    border-radius: 50%;
    background-size: 50%;
}

#heroCarousel:hover .carousel-control-prev,
#heroCarousel:hover .carousel-control-next {
    opacity: 0.8;
}

.play-icon {
    display: inline;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    background: white;
    width: 30px;
    height: 30px;
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.5);
}

/* ========================================
   HOMEPAGE SPECIFIC STYLES
   ======================================== */

/* Hero Carousel Section */
.hero-section {
    position: relative;
    height: 100vh;
    min-height: 600px;
    overflow: hidden;
}

.hero-slide {
    height: 100vh;
    min-height: 600px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    position: relative;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2rem;
    line-height: 1.6;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.carousel-indicators {
    bottom: -30px;
}

.carousel-indicators button {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid var(--white);
    background: transparent;
    opacity: 0.5;
    transition: var(--transition-fast);
}

.carousel-indicators button.active {
    background: var(--white);
    opacity: 1;
    transform: scale(1.2);
}

.carousel-control-prev,
.carousel-control-next {
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    top: 50%;
    transform: translateY(-50%);
    backdrop-filter: blur(10px);
    transition: var(--transition-smooth);
}

.carousel-control-prev {
    left: 30px;
}

.carousel-control-next {
    right: 30px;
}

.carousel-control-prev:hover,
.carousel-control-next:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-50%) scale(1.1);
}

/* Section Headers */
.section-header {
    margin-bottom: 3rem;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 600;
    color: var(--secondary-gray-dark);
    margin-bottom: 1rem;
    position: relative;
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--secondary-gray-light);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Category Cards */
.category-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-smooth);
    height: 100%;
}

.category-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-xl);
}

.category-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.category-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition-smooth);
}

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

.category-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(220, 38, 38, 0.8), rgba(185, 28, 28, 0.9));
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition-smooth);
}

.category-card:hover .category-overlay {
    opacity: 1;
}

.category-icon {
    width: 60px;
    height: 60px;
    background: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--primary-red);
    transform: scale(0.8);
    transition: var(--transition-smooth);
}

.category-card:hover .category-icon {
    transform: scale(1);
}

.category-content {
    padding: 1.5rem;
    text-align: center;
}

.category-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--secondary-gray-dark);
    margin-bottom: 0.5rem;
}

.category-count {
    color: var(--secondary-gray-light);
    font-size: 0.875rem;
    margin-bottom: 1rem;
}

/* Feature Cards */
.feature-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-smooth);
    height: 100%;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.feature-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary-red), var(--primary-red-dark));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 1.75rem;
    color: var(--white);
    transition: var(--transition-smooth);
}

.feature-card:hover .feature-icon {
    transform: scale(1.1);
    box-shadow: var(--shadow-lg);
}

.feature-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--secondary-gray-dark);
    margin-bottom: 1rem;
}

.feature-desc {
    color: var(--secondary-gray-light);
    line-height: 1.6;
}

/* Product Cards */
.product-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-smooth);
    position: relative;
    height: 100%;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

.product-badge {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background: var(--primary-red);
    color: var(--white);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    z-index: 2;
}

.product-badge.new-badge {
    background: var(--success-green);
}

.product-image {
    position: relative;
    height: 250px;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition-smooth);
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

.product-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: var(--transition-smooth);
}

.product-card:hover .product-overlay {
    opacity: 1;
}

.product-actions {
    display: flex;
    gap: 0.5rem;
}

.product-content {
    padding: 1.5rem;
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.rating-text {
    font-size: 0.875rem;
    color: var(--secondary-gray-light);
    margin-left: 0.5rem;
}

.product-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--secondary-gray-dark);
    margin-bottom: 0.75rem;
    line-height: 1.4;
}

.product-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary-red);
    margin-bottom: 1rem;
}

.product-actions-bottom {
    display: flex;
    gap: 0.5rem;
}

/* Promo Section */
.promo-section {
    background: linear-gradient(135deg, var(--light-gray), #f1f5f9);
    padding: 5rem 0;
    position: relative;
    overflow: hidden;
}

.promo-section::before {
    content: '';
    position: absolute;
    top: 0;
    right: -100px;
    width: 300px;
    height: 300px;
    background: linear-gradient(135deg, var(--primary-red-light), var(--primary-red));
    border-radius: 50%;
    opacity: 0.05;
}

.promo-content {
    position: relative;
    z-index: 2;
}

.promo-tag {
    display: inline-block;
    background: var(--primary-red);
    color: var(--white);
    padding: 0.5rem 1rem;
    border-radius: 25px;
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.promo-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--secondary-gray-dark);
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.promo-desc {
    font-size: 1.125rem;
    color: var(--secondary-gray-light);
    margin-bottom: 2rem;
    line-height: 1.6;
}

.promo-features {
    list-style: none;
    padding: 0;
    margin-bottom: 2rem;
}

.promo-features li {
    padding: 0.5rem 0;
    font-size: 1rem;
    color: var(--secondary-gray);
}

.promo-actions {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.promo-image {
    position: relative;
}

.offer-badge {
    position: absolute;
    top: 20px;
    right: 20px;
    background: var(--primary-red);
    color: var(--white);
    width: 100px;
    height: 100px;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    animation: pulse 2s infinite;
}

.offer-text {
    font-size: 0.75rem;
}

.offer-percent {
    font-size: 1.5rem;
    line-height: 1;
}

.offer-off {
    font-size: 0.75rem;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* Testimonials Section */
.testimonials-section {
    background: linear-gradient(135deg, var(--secondary-gray-dark), var(--secondary-gray));
    color: var(--white);
    position: relative;
    overflow: hidden;
}

.testimonials-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" patternUnits="userSpaceOnUse" width="100" height="100"><circle cx="25" cy="25" r="1" fill="rgba(255,255,255,0.02)"/><circle cx="75" cy="75" r="1" fill="rgba(255,255,255,0.02)"/><circle cx="50" cy="10" r="0.5" fill="rgba(255,255,255,0.01)"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>') repeat;
    opacity: 0.3;
}

.testimonial-card {
    position: relative;
    z-index: 2;
    padding: 2rem;
}

.testimonial-rating {
    font-size: 1.25rem;
}

.testimonial-text {
    font-size: 1.25rem;
    font-style: italic;
    margin: 2rem 0;
    color: var(--white);
    line-height: 1.6;
    position: relative;
}

.testimonial-text::before,
.testimonial-text::after {
    content: '"';
    font-size: 3rem;
    color: var(--primary-red);
    position: absolute;
    font-family: serif;
}

.testimonial-text::before {
    top: -10px;
    left: -20px;
}

.testimonial-text::after {
    bottom: -30px;
    right: -20px;
}

.author-name {
    color: var(--white);
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.author-location {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 0.5rem;
}

.product-purchased {
    color: var(--primary-red-light);
    font-weight: 500;
}

/* CTA Section */
.cta-section {
    background: var(--white);
    position: relative;
}

.cta-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--secondary-gray-dark);
    margin-bottom: 1.5rem;
}

.cta-subtitle {
    font-size: 1.25rem;
    color: var(--secondary-gray-light);
    margin-bottom: 2rem;
    line-height: 1.6;
}

.cta-stats {
    background: var(--light-gray);
    border-radius: 12px;
    padding: 2rem;
}

.stat-item {
    text-align: center;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-red);
    margin-bottom: 0.5rem;
}

.stat-label {
    color: var(--secondary-gray-light);
    font-size: 0.875rem;
    margin-bottom: 0;
}

.cta-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Responsive Design */
@media (max-width: 1199.98px) {
    .hero-title {
        font-size: 3rem;
    }
    
    .section-title {
        font-size: 2.25rem;
    }
    
    .promo-title {
        font-size: 2.25rem;
    }
    
    .cta-title {
        font-size: 2.25rem;
    }
}

@media (max-width: 991.98px) {
    .hero-section {
        height: 80vh;
        min-height: 500px;
    }
    
    .hero-slide {
        height: 80vh;
        min-height: 500px;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-content {
        text-align: center;
    }
    
    .carousel-control-prev,
    .carousel-control-next {
        width: 50px;
        height: 50px;
    }
    
    .carousel-control-prev {
        left: 20px;
    }
    
    .carousel-control-next {
        right: 20px;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .promo-title {
        font-size: 2rem;
    }
    
    .cta-title {
        font-size: 2rem;
    }
    
    .testimonial-text {
        font-size: 1.125rem;
    }
}

@media (max-width: 767.98px) {
    .hero-section {
        height: 70vh;
        min-height: 400px;
    }
    
    .hero-slide {
        height: 70vh;
        min-height: 400px;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-actions {
        justify-content: center;
    }
    
    .section-title {
        font-size: 1.75rem;
    }
    
    .section-subtitle {
        font-size: 1rem;
    }
    
    .feature-icon {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }
    
    .product-image {
        height: 200px;
    }
    
    .promo-title {
        font-size: 1.75rem;
    }
    
    .promo-desc {
        font-size: 1rem;
    }
    
    .promo-actions {
        justify-content: center;
    }
    
    .cta-title {
        font-size: 1.75rem;
    }
    
    .cta-subtitle {
        font-size: 1rem;
    }
    
    .cta-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .cta-actions .btn {
        width: 100%;
        max-width: 280px;
    }
    
    .testimonial-text::before,
    .testimonial-text::after {
        display: none;
    }
}

@media (max-width: 575.98px) {
    .carousel-background {
        height: 22vh;
        
    }
    
    .hero-title {
        font-size: 1.75rem;
    }
    
    .section-padding {
        padding: 3rem 0;
    }
    
    .category-image {
        height: 150px;
    }
    
    .feature-card {
        padding: 1.5rem;
    }
    
    .product-content {
        padding: 1rem;
    }
    
    .promo-section {
        padding: 3rem 0;
    }
    
    .offer-badge {
        width: 80px;
        height: 80px;
        font-size: 0.75rem;
    }
    
    .offer-percent {
        font-size: 1.25rem;
    }
    
    .cta-stats {
        padding: 1.5rem;
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
}

/* Animation Delays */
[data-animate] {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out;
}

[data-animate].animate-fadeInUp {
    opacity: 1;
    transform: translateY(0);
}

[data-animate="fadeInLeft"] {
    transform: translateX(-30px);
}

[data-animate="fadeInLeft"].animate-fadeInUp {
    transform: translateX(0);
}

[data-animate="fadeInRight"] {
    transform: translateX(30px);
}

[data-animate="fadeInRight"].animate-fadeInUp {
    transform: translateX(0);
}