/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Design tokens (CSS variables) */
:root {
    --bg-page: #FDF1EC;
    --text-default: #333333;
    --muted: rgba(0,0,0,0.02);
    --accent: #000000;
    --max-width: none;
    --side-left-width: 350px;
    --side-right-width: 400px;
    --gutter: 2rem;
    --padding-large: 4rem;
    /* Use @font-face family names */
    --font-display: 'Neutra Display', sans-serif; /* weights: 100, 300, 500, 700 */
    --font-body: 'Neutra Text', sans-serif;       /* weights: 300 (Light), 500 (Book) */
    --font-body-light: 'Neutra Text', sans-serif;
    --ink: #1a1a1a;
    --ink-muted: #5b5b5b;
    --border: rgba(0,0,0,0.12);
    /* Intro collage sizing */
    --intro-art-center-h: 480px; /* height of the middle collage image on desktop */
}

/* ====================
   Base
   ==================== */

body {
    font-family: var(--font-body);
    font-weight: 300; /* prefer Light for body copy */
    line-height: 1.6;
    overflow-x: hidden;
    color: var(--text-default);
    background-color: var(--bg-page);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    scroll-behavior: smooth; /* smooth scroll for anchor links */
}

/* Typography */
h1 {
    font-family: var(--font-display);
    font-size: 4rem;
    margin-bottom: 1rem;
    text-align: center;
    font-weight: 500; /* use Display Medium */
}

h2 {
    font-family: var(--font-display);
    font-size: 2.5rem;
    margin-bottom: 1rem;
    text-align: center;
    font-weight: 500; /* use Display Medium */
}

.subtitle {
    font-family: var(--font-body);
    font-size: 1.5rem;
    margin-bottom: 2rem;
}

/* Layout containers */
.main-header {
    width: 100%;
    position: relative;
}

/* Centered logo above the menu */
.logo-wrapper {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 200px; /* reserve vertical space for the logo (updated) */
}
.nav-center-logo {
    position: relative;
    z-index: 50;
}
.nav-center-logo img {
    display: block;
    height: 144px; /* doubled size */
}

/* Ensure ingredients page logo matches index size */
.logo-wrapper img.site-logo {
    display: block;
    height: 144px;
    width: auto;
}

/* Top menu (duplicate of footer menu) placed under the centered logo */
.top-footer-menu {
    text-align: center;
    /* spacing between logo and menu now controlled by logo-wrapper height */
    margin-top: 0;
    padding-top: 20px; /* add top padding */
    padding-bottom: 20px; /* reduced bottom padding to better match spacing */
    position: relative; /* allow mobile gradient fades */
}
.top-footer-menu ul {
    list-style: none;
    display: flex;
    justify-content: center;
    gap: 2.5rem;
    align-items: center;
    padding: 0;
    margin: 0;
}
.top-footer-menu ul li {
    font-family: var(--font-display);
    font-size: 0.95rem;
}
.top-footer-menu a { text-decoration: none; color: var(--accent); }
.top-footer-menu ul li:not(:last-child)::after {
    content: '';
    display: inline-block;
    width: 4rem;
    height: 1px;
    background: var(--muted);
    margin-left: 1rem;
    vertical-align: middle;
}

/* Make top and footer menu items uppercase to match mockup style */
.top-footer-menu a,
.footer-menu a {
    text-transform: uppercase;
    letter-spacing: 0;
}

/* Banner uses background-image; JS will set a random image from img-header */
.banner {
    width: 100%;
    height: 80vh; /* use 80% of viewport height */
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    margin-bottom: 50px; /* space between banner and next module */
}

.pre-banner-text {
    text-align: center;
    font-family: var(--font-display);
    font-size: 2.5rem;
    margin-bottom: 20px; /* 20px before the banner image */
}

/* Products section */
.products-section {
    display: flex;
    align-items: stretch; /* make child columns match height */
    gap: var(--gutter);
    max-width: var(--max-width);
    margin: 0 auto;
    padding: var(--padding-large) 2rem;
    padding-top: 20px;
    background-color: var(--bg-page);
    text-align: center;
}

.brand-title {
    font-family: var(--font-display);
    text-align: center;
    margin-bottom: 0rem;
    font-size: 2.5rem;
    /* letter-spacing: 0.1em; */
}

.main-footer {
    width: 100%;
    background: var(--muted);
}

/* ====================
   Components
   (product menu, product display, description)
   ==================== */

/* Responsive design */
@media (max-width: 1024px) {
    .products-section {
        grid-template-columns: 200px 1fr 250px;
        padding: 1rem;
    }
}

@media (max-width: 768px) {
    .products-section {
        grid-template-columns: 1fr;
    }
}

/* --- Merged enhanced-styles.css content --- */

/* Product Menu Enhanced Styles */
.product-menu li {
    position: relative;
    cursor: pointer;
    padding-bottom: 40px;
    padding-top: 40px;
    list-style-type: none;
    border-bottom: 1px solid var(--accent);
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* remove bottom border for the last menu item */
.product-menu li:last-child {
    border-bottom: none;
}

/* Three-column widths for desktop */
.side-menu {
    width: var(--side-left-width);
    flex: 0 0 var(--side-left-width);
    /* show ~12 items max vertically, enable scrolling for overflow */
    max-height: calc(12 * (40px + 40px)); /* using current li padding-top/bottom */
    overflow-y: auto;
}

/* Thin 2px black scrollbar for side-menu */

/* Scrollbar styles: hidden by default, visible when hovering the side-menu */
.side-menu::-webkit-scrollbar { width: 2px; }
.side-menu::-webkit-scrollbar-track { background: transparent; }
.side-menu::-webkit-scrollbar-thumb { background: transparent; border-radius: 1px; }

/* Show thumb on hover */
.side-menu:hover::-webkit-scrollbar-thumb { background: #000; }

/* Firefox: thin + make visible only on hover using color change */
.side-menu { scrollbar-width: thin; scrollbar-color: transparent transparent; }
.side-menu:hover { scrollbar-color: #000 transparent; }

.product-content {
    flex: 1 1 auto;
    display: flex;
    align-items: stretch;
    justify-content: center;
}

.product-content .product-display {
    width: 100%;
    height: auto;
    align-self: stretch; /* stretch to match siblings */
}

.product-description {
    width: var(--side-right-width);
    flex: 0 0 var(--side-right-width);
}

.product-menu li:hover {
    /* removed background on hover for a cleaner look per design */
    background-color: transparent;
}

.menu-indicator {
    position: absolute;
    right: 0.5rem;
    top: 50%;
    transform: translateY(-50%);
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: transparent;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.product-menu li.active .menu-indicator {
    background-color: #e88756; /* updated active indicator color */
    transform: translateY(-50%) scale(1.1);
}

.product-info {
    opacity: 1;
    transform: translateX(0);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.product-info {
    padding: 0 20px; /* horizontal breathing room */
}

.product-info h3 {
    font-family: var(--font-display);
    font-size: 1rem;
    line-height: 1.4;
    margin-bottom: 0.5rem;
    /* letter-spacing: 0.05em; */
    transition: color 0.3s ease;
}

.product-subtitle {
    font-family: var(--font-body);
    font-size: 1rem;
    color: #666;
    margin: 0 0 0.3rem 0;
    /* no forced uppercase for body copy */
}

.product-menu li:hover .product-info h3 {
    color: var(--accent);
}

/* Product Display Enhanced Styles */
.product-display {
    position: relative;
    width: 100%;
    height: auto;
    min-height: 300px; /* safe fallback */
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    transition: background-image 300ms ease, transform 300ms ease, box-shadow 300ms ease;
}

.product-display:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.15);
}

/* Right Panel Enhanced Styles */
.product-description {
    padding: 1.5rem;
    border-radius: 0px;
    border: solid 1px var(--accent);
    transition: all 0.3s ease;
}

.description-container {
    max-width: 350px;
    margin: 0 auto; /* center within the right panel */
}

/* Right panel: all copy in big caps */
.product-description h2 { text-transform: uppercase; }

.product-description h2 {
    font-family: var(--font-display);
    font-size: 1.2rem;
    margin: 0 0 1.5rem 0;
    /* letter-spacing: 0.1em; */
}

.properties-text,
.ingredients-text {
    font-family: var(--font-body);
    /* match menu item title font-size */
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 2.5rem;
    color: var(--text-default);
    transition: color 0.3s ease, transform 0.3s ease;
    text-transform: none; /* body copy should not be uppercase */
    /* letter-spacing: 0.06em; */
}

/* Ensure usage copy is also normal case */
.usage-text { text-transform: none; }

.buy-button {
    display: inline-block;
    width: 100%;
    padding: 1rem;
    background-color: var(--accent);
    color: #fff;
    text-align: center;
    text-decoration: none;
    font-family: var(--font-display);
    font-size: 0.9rem;
    letter-spacing: 0.1em;
    margin-top: 2.5rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--accent);
}

.buy-button:hover {
    background-color: #fff;
    color: var(--accent);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

/* Product social icons under meta */
.product-social {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.85rem;
    margin-top: 0.5rem;
    color: var(--accent);
}
.product-social a { display: inline-flex; align-items: center; justify-content: center; }
.product-social svg { display: block; width: 26px; height: 26px; color: #000; }
.product-social a:hover { opacity: 0.85; }

/* Product meta labels under SHOP NOW */
.product-meta {
    margin-top: 0.75rem;
    text-align: center;
    color: var(--accent);
}
.product-meta p {
    margin: 0.15rem 0;
    font-family: var(--font-body);
    font-size: 0.95rem;
    line-height: 1.4;
}

/* Secondary Amazon button removed */

/* Enhanced Mobile Responsiveness */
@media (max-width: 1200px) {
    .products-section {
        display: flex;
        align-items: stretch;
        gap: 1.5rem;
        padding: 2rem;
    }
    
    .product-display {
        max-width: 400px;
    }
}

@media (max-width: 992px) {
    .products-section {
        /* stack columns vertically on tablets/phones */
        flex-direction: column;
        gap: 3rem;
    }
    /* Ensure stacked sections take full width and render height */
    .product-content { width: 100%; display: block; }
    .product-description { width: 100%; flex: 0 0 auto; }
    
    .product-menu {
        display: flex;
        flex-wrap: wrap;
        gap: 1rem;
        margin-bottom: 2rem;
    }
    
    .product-menu li {
        flex: 1 1 calc(50% - 1rem);
        border: 1px solid rgba(0,0,0,0.1);
        border-radius: 4px;
        padding: 1rem 1rem 1rem 2.5rem;
    }
    
    .product-display {
        max-width: 100%;
        aspect-ratio: 16/9;
    }

    /* Make top and footer menus horizontally scrollable with momentum */
    .top-footer-menu ul,
    .footer-menu ul {
        justify-content: flex-start;
        gap: 1.25rem;
        overflow-x: auto;
        overflow-y: hidden;
        white-space: nowrap;
        -webkit-overflow-scrolling: touch; /* iOS momentum + bounce */
        scroll-snap-type: x proximity;
        padding: 0 1rem;
        margin: 0; /* reset bottom margin for better scroll */
        scrollbar-width: none; /* Firefox hide scrollbar */
        -ms-overflow-style: none; /* IE/Edge hide scrollbar */
    }
    .top-footer-menu ul li,
    .footer-menu ul li {
        flex: 0 0 auto;
        scroll-snap-align: center;
    }
    /* Hide separators for cleaner horizontal scroll */
    .top-footer-menu ul li:not(:last-child)::after,
    .footer-menu ul li:not(:last-child)::after { display: none; }

    /* Hide scrollbars (WebKit) */
    .top-footer-menu ul::-webkit-scrollbar,
    .footer-menu ul::-webkit-scrollbar { display: none; height: 0; }
}

@media (max-width: 768px) {
    /* Product selector becomes horizontal scroll chips */
    .side-menu {
        width: 100%;
        flex: 1 1 auto;
        max-height: none;
        overflow: visible;
        margin-bottom: 0.5rem;
    }
    .product-menu {
        display: flex;
        flex-wrap: nowrap;
        gap: 0.75rem;
        overflow-x: auto;
        overflow-y: hidden;
        white-space: nowrap;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x mandatory;
        padding: 0 1rem 0.5rem;
        margin-bottom: 1rem;
    }
    .product-menu li {
        flex: 0 0 auto;
        min-width: 220px;
        border: 1px solid rgba(0,0,0,0.2);
        border-radius: 6px;
        padding: 0.75rem 1rem;
        scroll-snap-align: center;
    }
    .product-info h3 { font-size: 0.95rem; }
    .product-subtitle { display: none; }
    
    .product-description {
        padding: 1.5rem;
        width: 100%;
        flex: 1 1 auto;
    }
    
    .properties-text,
    .ingredients-text {
        /* keep same sizing on small screens as desktop menu title */
        font-size: 1rem;
        line-height: 1.6;
        margin-bottom: 2rem;
    }

    /* Taller product image on small screens for better visibility */
    .product-display { aspect-ratio: 4/5; min-height: 300px; }
}

/* --- End merged content --- */

/* Footer gallery and menu */
.main-footer {
    padding: 3rem 2rem 4rem;
    background: var(--bg-page);
}

.footer-gallery .gallery-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 1rem;
    max-width: var(--max-width);
    margin: 0 auto 2rem;
}

.footer-gallery .gallery-grid img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    display: block;
}

.footer-title {
    font-family: var(--font-display);
    font-size: 2.5rem; /* same as brand title */
    text-align: center;
    margin: 0 0 1.25rem 0;
}

/* Lightbox styles */
.lightbox-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.85);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.lightbox-overlay.active {
    display: flex;
}

.lightbox-content {
    /* Constrain content to viewport with breathing room so images always fit */
    max-width: calc(100vw - 40px);
    max-height: calc(100vh - 40px);
    padding: 20px;
    box-sizing: border-box;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lightbox-content img {
    /* Ensure the image always fits inside the content box */
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    display: block;
    border-radius: 2px;
    object-fit: contain;
    margin: 0 auto;
}

.lightbox-close,
.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.12);
    color: #fff;
    padding: 0.6rem 0.8rem;
    cursor: pointer;
}

.lightbox-close { top: 1rem; right: 1rem; transform: none; }
.lightbox-prev { left: 12px; }
.lightbox-next { right: 12px; }


.footer-menu {
    text-align: center;
    margin-top: 100px;
    position: relative; /* allow mobile gradient fades */
}

/* Footer logo (old brand mark moved to footer) */
.footer-logo {
    text-align: center;
    margin: 50px 0 0.5rem;
}
.footer-logo img {
    height: 156px;
    width: auto;
    display: inline-block;
}

.footer-menu ul {
    list-style: none;
    display: flex;
    justify-content: center;
    gap: 2.5rem;
    align-items: center;
    padding: 0;
    margin: 0 0 0.75rem 0;
}

.footer-menu ul li {
    font-family: var(--font-display);
    font-size: 0.95rem;
}

.footer-menu ul li:not(:last-child)::after {
    content: '';
    display: inline-block;
    width: 4rem;
    height: 1px;
    background: var(--muted);
    margin-left: 1rem;
    vertical-align: middle;
}

.footer-menu a {
    color: var(--accent);
    text-decoration: none;
}

/* Footer social icons */
.footer-social {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin: 0.5rem 0 0.75rem;
    color: var(--accent);
}
.footer-social a { display: inline-flex; align-items: center; justify-content: center; }
.footer-social svg { display: block; height: 28px; width: 28px; color: #000; }
.footer-social a:hover { opacity: 0.8; }

.copyright {
    font-size: 0.75rem;
    color: #666;
    margin-top: 0.5rem;
}

@media (max-width: 992px) {
    .footer-gallery .gallery-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .footer-gallery .gallery-grid img {
        height: 140px;
    }

    /* Edge gradient fades to hint scrollability on mobile */
    .top-footer-menu::before,
    .top-footer-menu::after,
    .footer-menu::before,
    .footer-menu::after {
        content: '';
        position: absolute;
        top: 0;
        bottom: 0;
        width: 28px;
        pointer-events: none;
        z-index: 5;
    }
    .top-footer-menu::before,
    .footer-menu::before { left: 0; background: linear-gradient(to right, var(--bg-page) 60%, rgba(253,241,236,0)); }
    .top-footer-menu::after,
    .footer-menu::after { right: 0; background: linear-gradient(to left, var(--bg-page) 60%, rgba(253,241,236,0)); }
}

/* Footer logo smaller on mobile */
@media (max-width: 640px) {
    .footer-logo img { height: 78px; }
    .footer-logo { margin: 50px 0 0.25rem; }
}

/* ===============
   Ingredients page
   =============== */
.extra-intro {
    padding: 4rem 1.5rem 2rem;
    text-align: center;
}
.extra-intro .intro-title {
    font-family: var(--font-display);
    font-size: 3rem;
    margin-bottom: 0.5rem;
    text-align: center;
}
.extra-intro .intro-lead {
    max-width: 820px;
    margin: 0.5rem auto 1rem;
    font-family: var(--font-body-light);
    color: var(--ink-muted);
    text-align: center;
}
.extra-intro .intro-copy {
    max-width: 780px;
    margin: 0.5rem auto 0;
    text-align: center;
}
.extra-intro .intro-copy p { margin: 0.5rem 0; }

/* Intro decorative collage inspired by template image */
.intro-art {
    position: relative;
    height: calc(var(--intro-art-center-h) + 50px); /* center image height + 50px */
    margin-top: 2rem;
}
.intro-art img {
    position: absolute;
    width: 220px;
    height: 220px;
    object-fit: cover;
    box-shadow: none; /* drop shadow removed per request */
}
.intro-art .i1 { left: 10%; top: 35%; transform: rotate(-8deg); }
/* Center image switched to portrait and made taller */
.intro-art .i2 { left: 40%; top: 0%; width: 300px; height: var(--intro-art-center-h); transform: rotate(10deg); z-index: 2; }
.intro-art .i3 { right: 12%; top: 32%; width: 180px; height: 180px; transform: rotate(-4deg); }

@media (max-width: 900px) {
    :root { --intro-art-center-h: 340px; }
    .intro-art .i2 { width: 220px; height: var(--intro-art-center-h); }
    .intro-art .i1 { left: 2%; }
    .intro-art .i3 { right: 2%; }
}
@media (max-width: 640px) {
    .intro-art { height: auto; display: grid; grid-template-columns: repeat(3,1fr); gap: 8px; margin-top: 1.25rem; }
    .intro-art img { position: static; width: 100%; height: 140px; transform: none; box-shadow: none; }
}

.ingredients-section { padding: 1rem 1.5rem 4rem; }
.ingredients-section .container { max-width: 980px; margin: 0 auto; }

.accordion { border-top: 1px solid var(--border); }
.accordion-item { border-bottom: 1px solid var(--border); }
.accordion-toggle {
    width: 100%;
    text-align: center; /* center headings */
    background: transparent;
    border: 0;
    padding: 1.2rem 0.75rem;
    cursor: pointer;
    font-family: var(--font-display);
    font-size: 2.5rem; /* match title size from index */
    letter-spacing: 0.02em;
}
.accordion-toggle[aria-expanded="true"] { color: var(--accent); }
.accordion-panel { padding: 0 0.75rem 1.25rem; text-align: center; border: 1px solid #000; }
.accordion-body { font-family: var(--font-body); color: var(--ink); max-width: 820px; margin: 0.5rem auto 0; }
.accordion-body p { margin: 0.5rem 0; }
.accordion-body h4 {
    /* Match .product-description h2 */
    font-family: var(--font-display);
    font-size: 1.2rem;
    margin: 0 0 1.5rem 0;
}
.accordion-error { color: #a00; padding: 1rem; font-family: var(--font-body); }

/* Ingredient hero image */
.ingredient-hero {
    display: block;
    width: 100%;
    max-width: 560px;
    height: auto;
    margin: 0 auto 1rem;
    border-radius: 6px;
    border: 1px solid var(--border);
    object-fit: cover;
}

/* Uppercase for titles (keep body copy normal case) */
.intro-title,
.footer-title,
.brand-title,
.pre-banner-text,
.product-info h3,
.accordion-toggle,
.accordion-body h4 { text-transform: uppercase; }

/* Lists centered as a block while keeping left alignment for readability */
.accordion-body ul { margin: 0.5rem auto; padding-left: 0; list-style-position: inside; text-align: center; }
.accordion-body li { text-align: center; }

@media (max-width: 768px) {
    .accordion-toggle { font-size: 1.7rem; }
}

/* ===============
   Beyond the Visible page
   =============== */
.btv-page { padding: 2rem 1rem 4rem; }
.btv-block { max-width: 980px; margin: 0 auto 3rem; text-align: center; }
.btv-title { font-family: var(--font-display); font-size: 2.2rem; margin-bottom: 1rem; text-transform: uppercase; }
.btv-body { font-family: var(--font-body); max-width: 820px; margin: 0 auto 50px; text-transform: none; }
.btv-image { width: 100%; height: auto; max-width: 100%; display: block; margin: 0 auto; }

/* Beyond the Visible layout overrides */
.btv-block { display: flex; gap: 2.5rem; align-items: flex-start; max-width: 1100px; margin: 0 auto 3.5rem; }
.btv-image { flex: 0 0 44%; max-width: 44%; margin: 0; object-fit: cover; }
.btv-text { flex: 1 1 auto; text-align: left; }
.btv-title { text-align: left; font-size: 2.4rem; letter-spacing: 0.02em; font-weight: 500; margin-bottom: 1.25rem; }
.btv-body { text-align: left; font-size: 1.12rem; line-height: 1.72; font-weight: 500; color: var(--text-default); }
@media (max-width: 900px) { .btv-block { flex-direction: column; } .btv-image { max-width: 100%; width: 100%; } .btv-title { font-size: 2.1rem; } .btv-body { font-size: 1.05rem; line-height: 1.68; } }

/* Beyond page: iframe embed */
.btv-embed-container { max-width: 1100px; margin: 0 auto 3rem; }
.btv-embed { width: 100%; height: 80vh; border: 1px solid var(--accent); border-radius: 12px; box-shadow: 0 4px 28px rgba(0,0,0,0.08); }
@media (max-width: 900px) { .btv-embed { height: 75vh; } }

/* =============================
     Flipbook Effect (Beyond the Visible)
     ============================= */
.btv-flipbook {
    position: relative;
    max-width: 1100px;
    margin: 0 auto 3rem;
    perspective: 1600px;
    min-height: 620px;
}
.btv-flipbook .page-sheet {
    position: absolute;
    inset: 0;
    background: var(--bg-page);
    box-shadow: 0 4px 28px rgba(0,0,0,0.08);
    transform-origin: left center;
    transform-style: preserve-3d;
    -webkit-transform-style: preserve-3d;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    transition: transform 0.85s cubic-bezier(0.77,0,0.175,1), box-shadow 0.85s;
    border: 1px solid var(--accent);
    display: flex;
    gap: 2.2rem;
    align-items: flex-start;
    width: 100%;
    will-change: transform;
    padding: 0; /* remove default padding; handled per type */
    border-radius: 12px;
    overflow: hidden;
}
/* Interaction layers */
.btv-flipbook .page-sheet:not(.active) { pointer-events: none; }
.btv-flipbook .page-sheet.active { z-index: 100; }
.btv-flipbook .page-sheet.turned { transform: rotateY(-180deg); z-index: 10; box-shadow: 0 2px 15px rgba(0,0,0,0.05); }

/* stacking base pages */
.btv-flipbook .page-sheet[data-page="1"] { z-index: 65; }
.btv-flipbook .page-sheet[data-page="2"] { z-index: 64; }
.btv-flipbook .page-sheet[data-page="3"] { z-index: 63; }
.btv-flipbook .page-sheet[data-page="4"] { z-index: 62; }
.btv-flipbook .page-sheet[data-page="5"] { z-index: 61; }
.btv-flipbook .page-sheet[data-page="6"] { z-index: 60; }
.btv-flipbook .page-sheet[data-page="7"] { z-index: 59; }
.btv-flipbook .page-sheet[data-page="8"] { z-index: 58; }
.btv-flipbook .page-sheet[data-page="9"] { z-index: 57; }
.btv-flipbook .page-sheet[data-page="10"] { z-index: 56; }

/* Image + text reused */
/* Page types */
.btv-flipbook .page-image { padding: 0; }
.btv-flipbook .page-image .btv-image { width: 100%; height: 100%; object-fit: cover; display: block; }

.btv-flipbook .page-text {
    background: #000; /* fallback if image fails */
    background-image: url('img-beyond-the-visible/text-bk.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2.5rem 2.5rem;
    position: relative;
}
.btv-flipbook .page-text .overlay-text { max-width: 640px; text-align: center; }
.btv-flipbook .page-text .btv-title { text-align: center; }
.btv-flipbook .page-text .btv-body { text-align: center; }

/* QUNABU logo watermark on text pages */
.btv-flipbook .page-text::after {
    content: '';
    position: absolute;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    width: 140px;
    height: 34px;
    background: url('img-logo-qunabu/logo-qunabu.png') no-repeat center/contain;
    opacity: 0.9;
}

/* Controls */
.flipbook-controls {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 200;
}
.flipbook-controls button {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.2);
    color: #fff;
    border: 1px solid rgba(255,255,255,0.55);
    backdrop-filter: blur(2px);
    cursor: pointer;
    transition: transform 0.25s, background 0.25s;
    border-radius: 6px;
}
.flipbook-controls button[disabled] { opacity: 0.35; cursor: not-allowed; }
.flipbook-controls button:hover:not([disabled]) { background: rgba(255,255,255,0.35); transform: translateY(-2px); }
.flip-status { display: none; }

/* Toggle off effect (accessibility fallback) */
.btv-flipbook.no-flip { perspective: none; }
.btv-flipbook.no-flip .page-sheet { position: relative; transform: none !important; backface-visibility: visible; box-shadow: none; border: none; margin: 0 0 2.5rem; padding: 0; }
.btv-flipbook.no-flip .page-sheet:not(.active) { pointer-events: auto; }
.btv-flipbook.no-flip .page-sheet .btv-image { width: 100%; max-width: 100%; margin-bottom: 1.25rem; }
.btv-flipbook.no-flip .page-sheet { display: block; }

@media (max-width: 900px) {
    .btv-flipbook { min-height: 0; }
    .btv-flipbook .page-sheet { flex-direction: column; }
    .btv-flipbook .page-text { padding: 2rem 1.25rem; }
    .btv-flipbook .page-text .overlay-text { max-width: 520px; }
    .btv-flipbook .page-image .btv-image { height: auto; min-height: 320px; }
}
@media (prefers-reduced-motion: reduce) {
    .btv-flipbook .page-sheet { transition: none; }
}

/* =============================
    Readability Overrides (append)
    ============================= */
:root { --text-default: #1d1d1d; }
body { font-weight: 500; line-height: 1.62; color: var(--text-default); }
.top-footer-menu ul li, .footer-menu ul li { font-size: 1.05rem; font-weight: 500; letter-spacing: 0.02em; }
.product-info h3 { font-size: 1.1rem; line-height: 1.35; margin-bottom: 0.55rem; letter-spacing: 0.02em; font-weight: 500; }
.product-subtitle { font-size: 1.05rem; line-height: 1.5; color: #444; margin: 0 0 0.35rem 0; }
.product-description h2 { font-size: 1.35rem; margin: 0 0 1.6rem 0; letter-spacing: 0.03em; font-weight: 500; }
.properties-text, .ingredients-text { font-size: 1.05rem; line-height: 1.68; margin-bottom: 2.4rem; letter-spacing: 0.01em; }
.usage-text { font-size: 1.05rem; line-height: 1.68; }
.buy-button { padding: 1.05rem 1rem; font-size: 0.95rem; letter-spacing: 0.11em; margin-top: 2.6rem; font-weight: 500; }
.accordion-toggle { font-size: 2.55rem; padding: 1.25rem 0.75rem; letter-spacing: 0.025em; font-weight: 500; }
.accordion-body { font-weight: 500; margin-top: 0.55rem; }
.accordion-body h4 { font-size: 1.3rem; margin: 0 0 1.55rem 0; letter-spacing: 0.02em; font-weight: 500; }
@media (max-width: 768px) { .product-info h3 { font-size: 1rem; } .accordion-toggle { font-size: 1.85rem; } }

/* ===============
   BTV Carousel
   =============== */
.btv-carousel {
    position: relative;
    max-width: 1100px;
    margin: 40px auto 80px;
    padding: 0 16px;
}
.btv-slides { position: relative; }
.btv-slide {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    align-items: stretch;
    opacity: 0;
    transform: translateX(10px);
    transition: opacity 300ms ease, transform 300ms ease;
    pointer-events: none;
}
.btv-slide.active {
    position: relative;
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
}
.btv-figure {
    margin: 0;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    background: #fff;
}
.btv-figure img { display: block; width: 100%; height: 100%; object-fit: cover; }
.btv-copy {
    border-radius: 16px;
    padding: 28px 24px;
    background: #faf7f5 url('../img-beyond-the-visible/text-bk.png') center/cover no-repeat;
    box-shadow: 0 10px 30px rgba(0,0,0,0.06);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}
.btv-copy h2 {
    font-family: var(--font-display);
    letter-spacing: 0.04em;
    font-size: clamp(22px, 3.2vw, 34px);
    margin: 0 0 12px;
    text-transform: uppercase;
}
.btv-copy p {
    font-family: var(--font-body);
    line-height: 1.5;
    font-size: clamp(14px, 1.6vw, 18px);
    margin: 0 0 10px;
}
.btv-copy .btv-cta {
    display: inline-block;
    margin-top: 8px;
    padding: 10px 16px;
    border-radius: 999px;
    border: 1px solid #0c0c0c;
    color: inherit;
    text-decoration: none;
}
.btv-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid rgba(0,0,0,0.25);
    background: rgba(255,255,255,0.8);
    backdrop-filter: blur(6px);
    display: grid;
    place-items: center;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    color: #000;
}
.btv-prev { left: 10px; }
.btv-next { right: 10px; }
.btv-dots { display: flex; gap: 8px; justify-content: center; margin-top: 18px; }
.btv-dots button {
    width: 12px; /* match product menu-indicator size */
    height: 12px; /* match product menu-indicator size */
    border-radius: 50%;
    border: none;
    background: #000; /* default dot color: black */
}
.btv-dots button[aria-selected="true"] {
    background: #e88756; /* active color: same as .menu-indicator active */
}
@media (max-width: 900px) {
    .btv-slide,
    .btv-slide.active { display: block; }
    .btv-figure { margin-bottom: 14px; }
}
