:root {
    --primary-green: #2d5016;
    --secondary-green: #4a7c2c;
    --light-green: #7fb069;
    --accent-green: #9bc184;
    --cream: #f4f1ea;
    --dark: #1a1a1a;
    --gray: #666;
    --light-gray: #f8f8f8;
    --border: #e0e0e0;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(135deg, var(--cream) 0%, #ffffff 100%);
    color: var(--dark);
    line-height: 1.6;
}

/* Header & Navigation */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0,0,0,0.1);
    z-index: 1000;
    transition: all 0.3s ease;
}

.navbar {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1rem 2rem;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.back-button {
    position: absolute;
    right: 2rem;
    top: 50%;
    transform: translateY(-50%);
    background: var(--light-green);
    color: white;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-size: 1.3rem;
    transition: all 0.3s ease;
    box-shadow: 0 3px 15px rgba(45, 80, 22, 0.3);
    z-index: 10;
}

.back-button:hover {
    background: var(--secondary-green);
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 5px 20px rgba(45, 80, 22, 0.5);
}

 .logo img {
    width: 281px;
    height: auto;
    transition: transform 0.3s ease;
}

 .footer-section img {
    width: 187px;
     height: auto;
 }

.logo img:hover {
    transform: scale(1.05);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    text-decoration: none;
    color: var(--dark);
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-link:hover, .nav-link.active {
    background: var(--light-green);
    color: white;
}

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background: var(--primary-green);
    margin: 3px 0;
    transition: 0.3s;
    border-radius: 3px;
}

/* Product Detail Section */
.product-detail {
    margin-top: 120px;
    padding: 3rem 2rem;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
}

.categories-toggle {
    display: none;
    align-items: center;
    gap: 0.5rem;
    border: none;
    background: var(--light-green);
    color: white;
    font-weight: 600;
    border-radius: 10px;
    padding: 0.7rem 1rem;
    margin: 0 0 1rem 0;
    cursor: pointer;
    box-shadow: 0 6px 20px rgba(45, 80, 22, 0.2);
}

.categories-toggle:hover {
    background: var(--secondary-green);
}

.categories-backdrop {
    display: none;
}

.quick-categories-sidebar {
    display: none;
}

@media (min-width: 1500px) {
    .product-detail {
        display: grid;
        grid-template-columns: auto 1fr;
        gap: 3rem;
        align-items: start;
    }

    .quick-categories-sidebar {
        display: block !important;
        position: relative;
        width: 285px;
        height: fit-content;
        background: white;
        border: 2px solid var(--light-green);
        border-radius: 16px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
        padding: 1rem;
        z-index: 900;
    }

    .quick-categories-sidebar h3 {
        font-size: 1.05rem;
        color: var(--primary-green);
        margin-bottom: 0.9rem;
        display: flex;
        align-items: center;
        gap: 0.5rem;
    }

    .category-group {
        margin-bottom: 0.85rem;
        padding-bottom: 0.75rem;
        border-bottom: 1px solid var(--border);
    }

    .category-group:last-child {
        margin-bottom: 0;
        padding-bottom: 0;
        border-bottom: none;
    }

    .category-group h4 {
        color: var(--secondary-green);
        font-size: 0.88rem;
        margin-bottom: 0.45rem;
        text-transform: uppercase;
        letter-spacing: 0.4px;
    }

    .category-group a {
        display: block;
        text-decoration: none;
        color: var(--dark);
        font-size: 0.86rem;
        padding: 0.4rem 0.55rem;
        border-radius: 8px;
        transition: all 0.2s ease;
    }

    .category-group a:hover,
    .category-group a.active {
        background: rgba(127, 176, 105, 0.2);
        color: var(--primary-green);
        transform: translateX(3px);
    }
}

.breadcrumb {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    margin-bottom: 2rem;
    color: var(--gray);
    font-size: 0.9rem;
}

.breadcrumb a {
    color: var(--secondary-green);
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb a:hover {
    color: var(--light-green);
}

.product-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    margin-bottom: 4rem;
}

.product-images {
    position: sticky;
    top: 140px;
    height: fit-content;
}

.main-image {
    background: white;
    border-radius: 20px;
    padding: 2rem;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
    margin-bottom: 1rem;
    text-align: center;
}

.main-image img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
}

.image-gallery {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

.gallery-thumb {
    background: white;
    border-radius: 12px;
    padding: 0.5rem;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.3s ease;
}

.gallery-thumb:hover, .gallery-thumb.active {
    border-color: var(--light-green);
    transform: translateY(-2px);
}

.gallery-thumb img {
    width: 100%;
    height: auto;
    border-radius: 8px;
}

.product-info {
    padding: 2rem 0;
}

.product-badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: linear-gradient(135deg, var(--light-green), var(--secondary-green));
    color: white;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.product-info h1 {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
    color: var(--primary-green);
    margin-bottom: 1rem;
    line-height: 1.2;
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.stars {
    color: #ffc107;
    font-size: 1.2rem;
}

.rating-text {
    color: var(--gray);
    font-size: 0.9rem;
}

.product-description {
    font-size: 1.1rem;
    color: var(--gray);
    margin-bottom: 2rem;
    line-height: 1.8;
}

.product-features {
    background: white;
    border-radius: 16px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

.product-features h3 {
    color: var(--primary-green);
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.features-list {
    list-style: none;
    display: grid;
    gap: 0.8rem;
}

.features-list li {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    color: var(--dark);
}

.features-list i {
    color: var(--light-green);
    font-size: 1.2rem;
}

.contact-box {
    background: linear-gradient(135deg, var(--primary-green), var(--secondary-green));
    border-radius: 20px;
    padding: 2.5rem;
    color: white;
    box-shadow: 0 10px 40px rgba(45, 80, 22, 0.3);
}

.contact-box h2 {
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    margin-bottom: 1rem;
}

.contact-box p {
    margin-bottom: 1rem;
    font-size: 1.1rem;
    opacity: 0.95;
}

.contact-box a {
    color: white;
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem 1.5rem;
    background: rgba(255,255,255,0.2);
    border-radius: 10px;
    transition: all 0.3s ease;
    margin-top: 1rem;
}

.contact-box a:hover {
    background: rgba(255,255,255,0.3);
    transform: translateX(5px);
}

/* Tabs */
.product-tabs {
    margin-top: 4rem;
}

.tab-buttons {
    display: flex;
    gap: 1rem;
    border-bottom: 2px solid var(--border);
    margin-bottom: 2rem;
}

.tab-btn {
    background: none;
    border: none;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--gray);
    cursor: pointer;
    position: relative;
    transition: all 0.3s ease;
}

.tab-btn:hover {
    color: var(--secondary-green);
}

.tab-btn.active {
    color: var(--primary-green);
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--light-green);
}

.tab-content {
    display: none;
    background: white;
    padding: 2rem;
    border-radius: 16px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.tab-content h3 {
    color: var(--primary-green);
    margin-bottom: 1rem;
}

.tab-content p, .tab-content ul {
    color: var(--dark);
    line-height: 1.8;
}

.tab-content ul {
    margin-left: 1.5rem;
    margin-top: 1rem;
}

.nutrition-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

.nutrition-table th, .nutrition-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.nutrition-table th {
    background: var(--light-gray);
    color: var(--primary-green);
    font-weight: 600;
}

/* Footer */
.footer {
    background: linear-gradient(135deg, var(--primary-green), var(--secondary-green));
    color: white;
    padding: 3rem 2rem 1rem;
    margin-top: 4rem;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h4 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
}

.footer-section ul {
    list-style: none;
}

.footer-section a {
    color: white;
    text-decoration: none;
    transition: color 0.3s ease;
    display: block;
    margin-bottom: 0.5rem;
}

.footer-section a:hover {
    color: var(--accent-green);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.2);
}

/* Back to Top */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 50px;
    height: 50px;
    background: var(--light-green);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
    z-index: 999;
}

.back-to-top:hover {
    background: var(--secondary-green);
    transform: translateY(-5px);
}

.back-to-top.show {
    display: flex;
}

/* Responsive */
@media (max-width: 968px) {
    .product-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .quick-categories-sidebar {
        display: none !important;
    }

    .categories-toggle {
        display: inline-flex;
    }

    body.categories-open {
        overflow: hidden;
    }

    body.categories-open .categories-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.45);
        z-index: 1090;
    }

    body.categories-open .quick-categories-sidebar {
        display: block !important;
        position: fixed;
        top: 110px;
        left: 1rem;
        right: 1rem;
        width: auto;
        max-height: calc(100vh - 130px);
        overflow-y: auto;
        background: white;
        border: 2px solid var(--light-green);
        border-radius: 14px;
        box-shadow: 0 18px 50px rgba(0, 0, 0, 0.2);
        padding: 1rem;
        z-index: 1100;
    }

    .product-images {
        position: relative;
        top: 0;
    }

    .product-info h1 {
        font-size: 2rem;
    }

    .tab-buttons {
        flex-wrap: wrap;
    }

    .tab-btn {
        padding: 0.8rem 1.2rem;
        font-size: 1rem;
    }
}

@media (max-width: 768px) {
    .mobile-menu-toggle {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        top: 80px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 80px);
        background: white;
        flex-direction: column;
        padding: 2rem;
        transition: left 0.3s ease;
        box-shadow: 0 10px 40px rgba(0,0,0,0.1);
    }

    .nav-menu.active {
        left: 0;
    }

    .product-detail {
        margin-top: 100px;
        padding: 2rem 1rem;
    }

    .quick-categories-sidebar {
        display: none !important;
    }

    .categories-toggle {
        display: inline-flex;
        margin-bottom: 1.2rem;
    }

    body.categories-open .quick-categories-sidebar {
        top: 96px;
        left: 0.75rem;
        right: 0.75rem;
        max-height: calc(100vh - 110px);
    }
    
    .product-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .image-gallery {
        grid-template-columns: repeat(3, 1fr);
    }

    .contact-box {
        padding: 1.5rem;
    }

    .contact-box h2 {
        font-size: 1.5rem;
    }
}
