/* NOTEBOOK SCROLL SECTION */
.notebook-scroll-container {
    position: relative;
    width: 100%;
    background-color: #FDF6EB;
    /* Match surface color */
    overflow-x: hidden;
}

.notebook-scroll-section {
    /* Height is set by JS */
    position: relative;
    width: 100%;
}

.notebook-sticky-wrapper {
    position: fixed;
    left: 0;
    top: 0;
    z-index: 50;
    /* Below Navbar (100) but above content */
    width: 100vw;
    height: 100vh;
    background-color: #FDF6EB;
    /* transition removed to avoid fighting with scroll */
    pointer-events: none;
    /* Let scroll pass through? No, wait.
       If it's fixed covering everything, we need to be able to scroll the page.
       Pointer events none is good for overlays.
    */
}

.notebook-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
    /* Subtle enhancement to hide low-res upscaling artifacts */
    filter: contrast(1.05) saturate(1.05);
}

.notebook-loading {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    /* text-xs */
    text-transform: uppercase;
    letter-spacing: 0.4em;
    color: rgba(110, 11, 20, 0.8);
    /* #6E0B14 / 80 */
    background-color: #FDF6EB;
    transition: opacity 0.5s ease;
    z-index: 10;
}

.final-frame-container {
    position: relative;
    height: 100vh;
    width: 100vw;
    background-color: #FDF6EB;
}

.final-frame-canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
}

.notebook-content-section {
    width: 100%;
    background-color: #FDF6EB;
    padding: 7rem 0;
    /* py-28 */
}

@media (min-width: 768px) {
    .notebook-content-section {
        padding: 10rem 0;
        /* md:py-40 */
    }
}

.notebook-content-container {
    margin: 0 auto;
    width: 100%;
    max-width: 64rem;
    /* max-w-5xl */
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 1.5rem;
    /* px-6 */
    text-align: center;
}

@media (min-width: 768px) {
    .notebook-content-container {
        padding: 0 2.5rem;
        /* px-10 */
    }
}

.notebook-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.4em;
    color: rgba(110, 11, 20, 0.8);
}

.notebook-heading {
    margin-top: 1.5rem;
    font-family: var(--font-serif);
    font-size: 2.25rem;
    /* text-4xl */
    line-height: 1.05;
    color: rgba(11, 11, 11, 0.9);
}

@media (min-width: 768px) {
    .notebook-heading {
        font-size: 3.75rem;
        /* text-6xl */
    }
}

.notebook-text {
    margin-top: 1.5rem;
    max-width: 48rem;
    /* max-w-3xl */
    font-size: 1rem;
    line-height: 1.625;
    color: rgba(11, 11, 11, 0.8);
}

@media (min-width: 768px) {
    .notebook-text {
        font-size: 1.125rem;
        /* text-lg */
    }
}

.notebook-text span {
    display: block;
}

.notebook-cta-wrapper {
    margin-top: 3rem;
}

.notebook-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 9999px;
    background-color: #6E0B14;
    padding: 0.75rem 2rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.32em;
    color: #FDF6EB;
    box-shadow: 0 14px 30px rgba(110, 11, 20, 0.2);
    transition: box-shadow 0.3s ease;
}

.notebook-cta:hover {
    box-shadow: 0 18px 36px rgba(110, 11, 20, 0.28);
}

@media (min-width: 768px) {
    .notebook-cta {
        font-size: 0.875rem;
        /* text-sm */
    }
}

/* Nav Helper */
.navbar.nav-hidden {
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

/* HERO OVERLAY */
.hero-overlay {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100vh;
    display: flex;
    align-items: flex-start;
    /* Was center */
    justify-content: center;
    padding-top: 120px;
    /* Clear navbar */
    z-index: 10;
    pointer-events: none;
    /* Default to none, enable when visible */
    opacity: 0;
    background: transparent;
}

.hero-overlay.visible {
    pointer-events: auto;
}



/* Force container to ignore grid from styles.css and center content */
#hero-overlay .hero-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 1000px;
}

.hero-text-wrapper {
    text-align: center;
    max-width: 800px;
    padding: 0 1rem;
    transform: scale(0.9);
    transition: transform 0.1s ease-out;
}

.hero-title {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    color: var(--ink);
}

.hero-subtitle {
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
    color: #444;
}

.hero-overlay .btn-primary {
    font-size: 1.1rem;
    padding: 1rem 2rem;
}

/* MOBILE STATIC HERO */
body.is-mobile-hero .notebook-scroll-section {
    height: auto !important;
    min-height: 100vh;
}

body.is-mobile-hero .notebook-sticky-wrapper {
    position: relative !important;
    height: auto !important;
    min-height: 100vh;
    width: 100%;
    background-color: #FDF6EB;
}

body.is-mobile-hero .notebook-canvas,
body.is-mobile-hero .notebook-loading,
body.is-mobile-hero .notebook-canvas-wrapper {
    display: none !important;
}

body.is-mobile-hero .hero-overlay {
    position: relative !important;
    opacity: 1 !important;
    pointer-events: auto !important;
    height: auto !important;
    min-height: 100vh;
    padding-top: 100px !important;
    transform: none !important;
    display: flex;
    align-items: center;
    justify-content: center;
}

body.is-mobile-hero .hero-text-wrapper {
    transform: scale(1) !important;
}