/* Define CSS variables for consistent branding and spacing */
:root {
    --brand-primary: #ff4500; /* Saffron-inspired orange */
    --brand-secondary: #8b0000; /* Saffron-inspired red */
    --gradient: linear-gradient(to right, var(--brand-secondary), var(--brand-primary));
    --text-dark: #333;
    --text-light: #fff;
    --text-contrast: #ffffff; /* Pure white for maximum contrast */
    --font-primary: 'Arial', sans-serif;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 2rem;
}

/* Utility Classes for reusable layouts */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

.flex-row {
    display: flex;
    flex-direction: row;
}

.flex-wrap {
    flex-wrap: wrap;
}

.align-center {
    align-items: center;
}

.justify-between {
    justify-content: space-between;
}

.justify-center {
    justify-content: center;
}

.gap-1 { gap: var(--spacing-sm); }
.gap-2 { gap: var(--spacing-md); }
.gap-3 { gap: var(--spacing-lg); }

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

.d-none { display: none; }
.d-block { display: block; }
.d-flex { display: flex; }
.w-100 { width: 100%; }

@media (min-width: 769px) {
    .d-md-none { display: none; }
    .d-md-block { display: block; }
    .d-md-flex { display: flex; }
}

@media (max-width: 768px) {
    .d-md-none { display: block; }
    .d-md-block { display: none; }
    .d-md-flex { display: none; }
}

/* Button component styles (reusable across sections) */
.btn {
    display: inline-block;
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: 4px;
    text-decoration: none;
    font-family: var(--font-primary);
    font-size: 1rem;
    font-weight: 500;
    text-align: center;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.2s ease;
    border: none; /* Ensure no default button borders */
}

/* Primary button variant for main CTAs (e.g., Catalog, Shop Now, View Details) */
.btn--primary {
    background-color: var(--brand-primary); /* Saffron orange for visibility */
    color: var(--text-contrast); /* Pure white for maximum readability */
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2); /* Subtle shadow for depth */
}

.btn--primary:hover {
    background-color: #a52a2a; /* Slightly lighter red (brownish-red) for better contrast */
    color: var(--text-contrast); /* Pure white for consistency */
    transform: scale(1.05);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3); /* Enhanced shadow on hover */
}

.btn--primary:active {
    transform: scale(0.98); /* Slight press effect */
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2); /* Reduced shadow on click */
}

/* Header bar styles */
.header-bar {
    background: var(--gradient);
    color: var(--text-light);
    padding: var(--spacing-md) 0;
}

.header-bar--top {
    font-size: 0.9rem;
}

.header-bar .contact-info span {
    margin-right: var(--spacing-md);
}

.header-bar .contact-info i {
    margin-right: var(--spacing-sm);
}

.header-bar .contact-info a {
    color: var(--text-light);
    text-decoration: none;
}

.header-bar .contact-info a:hover {
    text-decoration: underline;
}

/* Social media icons */
.social-icons a {
    color: var(--text-light);
    margin-left: var(--spacing-sm);
    font-size: 1.2rem;
    transition: color 0.3s ease;
}

.social-icons a:hover {
    color: #ddd;
}

/* Hamburger Menu Styles */
.hamburger {
    display: none; /* Hidden on larger screens */
    background: none;
    border: none;
    cursor: pointer;
    padding: var(--spacing-sm);
    z-index: 1000;
}

.hamburger__line {
    display: block;
    width: 24px;
    height: 3px;
    background: var(--text-dark);
    margin: 5px 0;
    transition: all 0.3s ease;
}

.hamburger--active .hamburger__line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.hamburger--active .hamburger__line:nth-child(2) {
    opacity: 0;
}

.hamburger--active .hamburger__line:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

/* Navigation menu styles */
.nav-menu {
    background-color: var(--text-light);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    padding: var(--spacing-md) 0;
}

.nav-menu--primary .brand-logo {
    display: flex;
    align-items: center;
}

.logo-img {
    height: 40px;
    width: auto;
}

.nav-menu__content {
    transition: transform 0.3s ease, opacity 0.3s ease;
}

@media (min-width: 769px) {
    .nav-menu__content {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: var(--spacing-md);
    }
}

@media (max-width: 768px) {
    .nav-menu__content {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background: var(--text-light);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        transform: translateX(-100%);
        opacity: 0;
        z-index: 999;
    }

    .nav-menu__content--active {
        transform: translateX(0);
        opacity: 1;
    }

    .nav-links {
        flex-direction: column;
        align-items: center;
        gap: var(--spacing-lg);
    }

    .nav-link {
        font-size: 1.5rem; /* Larger text for mobile */
        padding: var(--spacing-md);
    }

    .btn--primary {
        font-size: 1.2rem;
        padding: var(--spacing-md) var(--spacing-lg);
        width: 80%; /* Full-width button on mobile */
        text-align: center;
    }
}

.nav-links {
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-link {
    color: var(--text-dark);
    text-decoration: none;
    font-family: var(--font-primary);
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: var(--brand-primary);
}

/* Section styles */
.section {
    padding: var(--spacing-lg) 0;
}

/* Hero section with carousel */
.section--hero {
    position: relative;
    min-height: 600px; /* Standard hero height */
    display: flex;
    align-items: center;
    overflow: hidden;
}

.slideshow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.slideshow__slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1s ease;
}

.slideshow__slide.active {
    opacity: 1;
}

.slideshow__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.slideshow__btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: var(--text-light);
    border: none;
    padding: var(--spacing-sm);
    cursor: pointer;
    font-size: 1.5rem;
    z-index: 2;
    transition: background 0.3s ease;
}

.slideshow__btn:hover {
    background: var(--brand-primary);
}

.slideshow__btn--prev {
    left: 10px;
}

.slideshow__btn--next {
    right: 10px;
}

.carousel-indicators {
    position: absolute;
    bottom: var(--spacing-md);
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: var(--spacing-sm);
    z-index: 2;
}

.carousel-indicator {
    width: 0.75rem;
    height: 0.75rem;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.carousel-indicator--active {
    background-color: var(--brand-primary);
    transform: scale(1.2);
}

.carousel-indicator:hover {
    background-color: var(--brand-secondary);
}

.hero-content {
    position: relative;
    z-index: 3; /* Above buttons and slides */
    background: rgba(0, 0, 0, 0.6); /* Slightly darker overlay for readability */
    padding: var(--spacing-lg);
    border-radius: 8px;
    color: var(--text-light);
    max-width: 80%; /* Reduce horizontal size to avoid overlap with nav buttons */
    margin: 0 auto; /* Center the overlay horizontally */
}

/* Headings and text */
.section-heading {
    font-size: 2.5rem;
    margin-bottom: var(--spacing-md);
}

.section-subheading {
    font-size: 1.2rem;
    margin-bottom: var(--spacing-lg);
}

/* Grid for product cards */
.grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--spacing-lg);
}

/* Card component */
.card {
    background: var(--text-light);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
}

.card-img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.card-body {
    padding: var(--spacing-md);
}

.card-title {
    font-size: 1.5rem;
    margin-bottom: var(--spacing-sm);
}

.card-text {
    margin-bottom: var(--spacing-md);
}

/* Footer styles */
.section--footer {
    background: var(--brand-secondary);
    color: var(--text-light);
}

/* Back to Top button */
.back-to-top {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: var(--brand-primary);
    color: var(--text-light);
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.back-to-top.visible {
    opacity: 1;
}

.back-to-top:hover {
    background: var(--brand-secondary);
}

/* Responsive Design for Mobile and Tablet */
@media (max-width: 992px) {
    /* Tablet adjustments */
    .section--hero {
        min-height: 500px;
    }
    .section-heading {
        font-size: 2rem;
    }
    .section-subheading {
        font-size: 1.1rem;
    }
}

@media (max-width: 768px) {
    /* Top Bar Mobile Styles */
    .header-bar--top {
        padding: var(--spacing-sm) 0;
        font-size: 0.8rem;
    }

    .header-bar .container {
        flex-direction: column;
        align-items: flex-start;
        gap: var(--spacing-sm);
    }

    .header-bar .contact-info {
        flex-direction: column;
        gap: var(--spacing-sm);
    }

    .header-bar .contact-info span {
        margin-right: 0;
    }

    .social-icons {
        justify-content: flex-start;
    }

    .social-icons a {
        font-size: 1rem;
        margin: 0 var(--spacing-sm) 0 0;
    }

    /* Show hamburger on mobile */
    .hamburger {
        display: block;
    }
}

@media (max-width: 576px) {
    /* Mobile adjustments */
    .section--hero {
        min-height: 400px;
    }
    .section-heading {
        font-size: 1.6rem;
    }
    .section-subheading {
        font-size: 0.9rem;
    }
    .slideshow__btn {
        font-size: 1rem;
        padding: calc(var(--spacing-sm) / 2);
    }
    .hero-content {
        max-width: 95%;
        padding: var(--spacing-sm);
    }
}