:root {
    /* Typography notes: IBM Plex Mono (data readout); Space Grotesk (geometric technical sans) = instrument; Space Grotesk's technical precision. This is the "eclectic-hybrid" pairing: geometric sans meets calligraphic serif. Interactive elements use Intersection Observer + requestAnimationFrame scroll tracker. The floating elements use (Google Fonts. */
    --abyss-primary: #0a1628;
    --bathyal-secondary: #0d2137;
    --bioluminescent-accent: #00e5ff;
    --pelagic-text: #e0f7fa;
    --mesopelagic-mid: #546e7a;
    --surface-inversion: #eceff1;
    --signal-warm: #ff6f00;
    --body-muted: #b0bec5;
    --surface-text: #37474f;
    --gradient-descent: linear-gradient(180deg, #0d2137 0%, #0a1628 100%);
    --gradient-bioluminescence: radial-gradient(ellipse at 30% 70%, rgba(0, 229, 255, 0.08) 0%, transparent 70%);
    --gradient-surface: linear-gradient(180deg, #0a1628 0%, #eceff1 100%);
    --gutter: 24px;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    scroll-snap-type: y mandatory;
    background: #0a1628;
}

body {
    min-height: 100vh;
    overflow-x: hidden;
    background: #0a1628;
    color: #b0bec5;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-size: clamp(1rem, 1.4vw, 1.25rem);
    line-height: 1.7;
}

.viewport-container {
    width: 100%;
    scroll-snap-type: y mandatory;
}

.spread {
    position: relative;
    min-height: 100vh;
    width: 100%;
    overflow: hidden;
    scroll-snap-align: start;
    perspective: 1000px;
    isolation: isolate;
}

.depth-lines {
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    opacity: 0.78;
    background-image:
        linear-gradient(to bottom, transparent 13%, rgba(84, 110, 122, 0.36) 13.08%, transparent 13.16%),
        linear-gradient(to bottom, transparent 43%, rgba(84, 110, 122, 0.18) 43.08%, transparent 43.16%),
        linear-gradient(to bottom, transparent 76%, rgba(84, 110, 122, 0.26) 76.08%, transparent 76.16%);
    transform: translate3d(0, var(--parallax-y, 0px), 0);
}

.parallax-layer {
    transform: translate3d(0, var(--parallax-y, 0px), 0);
}

.spread-1 {
    display: grid;
    place-items: center;
    background: var(--gradient-bioluminescence), var(--gradient-descent);
}

.spread-1-content {
    position: relative;
    z-index: 2;
    display: grid;
    place-items: center;
    min-height: 100vh;
    width: 100%;
}

.bioluminescence-glow {
    position: absolute;
    top: 27%;
    left: 50%;
    width: min(72vw, 680px);
    height: min(72vw, 680px);
    border-radius: 999px;
    background: radial-gradient(circle, rgba(0, 229, 255, 0.16) 0%, rgba(0, 229, 255, 0.055) 36%, transparent 70%);
    transform: translateX(-50%);
    filter: blur(4px);
}

.hero-text {
    position: absolute;
    top: 45%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #e0f7fa;
    font-family: "Space Grotesk", Inter, sans-serif;
    font-size: clamp(4rem, 10vw, 8rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 0.9;
    text-transform: lowercase;
    text-shadow: 0 0 44px rgba(0, 229, 255, 0.09);
}

.waterline {
    position: absolute;
    top: 55vh;
    left: 0;
    width: 100vw;
    height: 1px;
    background: #546e7a;
    opacity: 0.4;
}

.spread-1-subtitle {
    position: absolute;
    top: calc(55vh + 7.5vh);
    left: 50%;
    transform: translateX(-50%);
    width: max-content;
    max-width: calc(100vw - 48px);
    color: #b0bec5;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-size: 1.1rem;
    font-style: italic;
}

.scroll-indicator {
    position: absolute;
    bottom: 5vh;
    left: 50%;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-top: 12px solid #00e5ff;
    filter: drop-shadow(0 0 12px rgba(0, 229, 255, 0.55));
    transform: translateX(-50%);
    animation: pulse-scroll 2s ease-in-out infinite;
}

.spread-grid {
    position: relative;
    z-index: 2;
    display: grid;
    min-height: 100vh;
    width: 100%;
}

.pressure-grid {
    grid-template-columns: 62fr 38fr;
}

.signal-grid {
    grid-template-columns: 38fr 62fr;
}

.visual-field {
    position: relative;
    min-height: 100vh;
    overflow: hidden;
    background: #0d2137;
}

.ocean-photo {
    position: absolute;
    inset: -3%;
    mask-image: linear-gradient(to right, black 60%, transparent 100%);
    -webkit-mask-image: linear-gradient(to right, black 60%, transparent 100%);
    filter: grayscale(70%) brightness(0.8) sepia(15%);
}

.ocean-svg {
    display: block;
    width: 100%;
    height: 100%;
}

.photo-tint {
    position: absolute;
    inset: 0;
    background: #0d2137;
    mix-blend-mode: luminosity;
    opacity: 0.52;
}

.sonar-grid {
    position: absolute;
    inset: 0;
    z-index: 3;
    background-image:
        linear-gradient(rgba(0, 229, 255, 0.06) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 229, 255, 0.06) 1px, transparent 1px);
    background-size: 80px 80px;
    opacity: 0.06;
}

.sonar-grid.pulse {
    animation: sonar-pulse 4s ease-in-out 0.5s 1;
}

.annotation-zone,
.text-zone {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    min-height: 100vh;
    padding: clamp(42px, 7vw, 92px) clamp(32px, 4vw, 62px);
    background: #0a1628;
}

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

.body-text {
    color: #b0bec5;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-size: clamp(1rem, 1.4vw, 1.25rem);
    font-weight: 400;
    line-height: 1.7;
    text-align: justify;
    hyphens: auto;
}

.margin-notes {
    display: grid;
    gap: 18px;
    margin-top: 34px;
    margin-left: max(-5vw, -82px);
    color: #00e5ff;
    font-family: "IBM Plex Mono", ui-monospace, monospace;
    font-size: clamp(0.8rem, 1.2vw, 1rem);
    letter-spacing: 0.05em;
    line-height: 1.4;
    opacity: 0.82;
    text-shadow: 0 0 18px rgba(0, 229, 255, 0.25);
}

.thermal {
    color: #ff6f00;
    text-shadow: 0 0 18px rgba(255, 111, 0, 0.24);
}

.spread-title {
    margin-bottom: 30px;
    color: #e0f7fa;
    font-family: "Space Grotesk", Inter, sans-serif;
    font-size: clamp(2rem, 5vw, 4.5rem);
    font-weight: 500;
    letter-spacing: -0.03em;
    line-height: 0.96;
    text-transform: lowercase;
}

.distribution-field {
    background:
        radial-gradient(circle at 52% 48%, rgba(0, 229, 255, 0.12), transparent 24%),
        linear-gradient(180deg, #0d2137, #0a1628);
}

#particleCanvas {
    display: block;
    width: 100%;
    height: 100%;
}

.spread-4 {
    display: grid;
    place-items: center;
    background: radial-gradient(circle at 50% 50%, rgba(0, 229, 255, 0.065) 0%, transparent 60%), #0a1628;
}

.spread-4-content {
    position: relative;
    z-index: 2;
    display: grid;
    justify-items: center;
    align-content: center;
    min-height: 100vh;
    padding: 0 var(--gutter);
    text-align: center;
}

.monumental-number {
    display: flex;
    justify-content: center;
    color: #e0f7fa;
    font-family: "Space Grotesk", Inter, sans-serif;
    font-size: clamp(6rem, 15vw, 14rem);
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 0.88;
}

.digit {
    display: inline-block;
}

.digit-1 { transform: translateY(0); }
.digit-2 { transform: translateY(-8px); }
.digit-3 { transform: translateY(4px); }
.digit-4 { transform: translateY(-12px); }
.digit-5 { transform: translateY(6px); }
.digit-6 { transform: translateY(-4px); }
.digit-7 { transform: translateY(10px); }
.digit-8 { transform: translateY(-2px); }
.accent-digit { color: #00e5ff; }

.depth-caption {
    max-width: 40ch;
    margin-top: 40px;
    color: #b0bec5;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-size: 1rem;
    font-style: italic;
    line-height: 1.6;
}

.spread-5 {
    display: grid;
    place-items: center;
    background: var(--gradient-surface);
}

.spread-5-content {
    position: relative;
    display: grid;
    place-items: center;
    min-height: 100vh;
    width: 100%;
    padding: 0 var(--gutter);
}

.closing-text {
    max-width: 45ch;
    color: #0a1628;
    font-family: "Space Grotesk", Inter, sans-serif;
    font-size: clamp(1.5rem, 3vw, 2.5rem);
    font-weight: 500;
    letter-spacing: -0.02em;
    line-height: 1.4;
    text-align: center;
    text-transform: lowercase;
}

.float-element,
.float-integral {
    position: absolute;
    z-index: 4;
    pointer-events: none;
    transform: translate3d(0, var(--parallax-y, 0px), 0);
}

.float-value {
    color: #00e5ff;
    font-family: "IBM Plex Mono", ui-monospace, monospace;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    opacity: 0.2;
    text-shadow: 0 0 16px rgba(0, 229, 255, 0.35);
}

.float-operator,
.float-integral {
    color: #e0f7fa;
    font-family: "Cormorant Garamond", Georgia, serif;
    font-size: 1.5rem;
    opacity: 0.1;
}

.float-circle {
    width: 7px;
    height: 7px;
    border: 1px solid #00e5ff;
    border-radius: 50%;
    opacity: 0.15;
}

.float-line {
    width: 88px;
    height: 1px;
    background: #546e7a;
    opacity: 0.3;
}

.float-integral {
    top: 23%;
    left: 50%;
    color: #546e7a;
    font-size: 4rem;
    opacity: 0.15;
    animation: drift-1 40s ease-in-out infinite;
}

.float-1 { top: 15%; left: 10%; animation: drift-1 40s ease-in-out infinite; }
.float-2 { top: 24%; right: 8%; animation: drift-2 35s ease-in-out infinite; }
.float-3 { top: 40%; left: 5%; animation: drift-3 50s ease-in-out infinite; }
.float-4 { top: 61%; right: 12%; animation: drift-4 45s ease-in-out infinite; }
.float-5 { top: 35%; left: 15%; animation: drift-5 55s ease-in-out infinite; }
.float-6 { top: 70%; right: 6%; animation: drift-6 38s ease-in-out infinite; }
.float-7 { top: 19%; right: 20%; animation: drift-7 48s ease-in-out infinite; }
.float-8 { top: 66%; left: 8%; animation: drift-8 42s ease-in-out infinite; }
.float-9 { top: 45%; right: 15%; animation: drift-9 52s ease-in-out infinite; }
.float-10 { top: 75%; left: 18%; animation: drift-10 44s ease-in-out infinite; }
.float-11 { top: 18%; left: 20%; animation: drift-1 40s ease-in-out infinite; }
.float-12 { top: 42%; right: 10%; animation: drift-2 35s ease-in-out infinite; }
.float-13 { top: 57%; left: 12%; animation: drift-3 50s ease-in-out infinite; }
.float-14 { top: 72%; right: 18%; animation: drift-4 45s ease-in-out infinite; }
.float-15 { top: 20%; left: 15%; animation: drift-1 40s ease-in-out infinite; }
.float-16 { top: 31%; right: 8%; animation: drift-2 35s ease-in-out infinite; }
.float-17 { top: 70%; left: 22%; animation: drift-3 50s ease-in-out infinite; }
.float-18 { top: 81%; right: 16%; animation: drift-8 46s ease-in-out infinite; }
.float-19 { top: 24%; right: 14%; animation: drift-1 40s ease-in-out infinite; }
.float-20 { top: 75%; left: 11%; animation: drift-2 48s ease-in-out infinite; }

.navigation-strip {
    position: fixed;
    top: 50%;
    right: 30px;
    z-index: 100;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    transform: translateY(-50%);
}

.nav-line {
    position: absolute;
    top: 6px;
    bottom: 6px;
    left: 50%;
    width: 1px;
    background: #546e7a;
    opacity: 0.3;
    transform: translateX(-50%);
}

.nav-dot {
    position: relative;
    width: 12px;
    height: 12px;
    border: 1px solid #00e5ff;
    border-radius: 50%;
    background: transparent;
    cursor: pointer;
    opacity: 0.5;
    transition: opacity 300ms ease, background-color 300ms ease, border-color 300ms ease, box-shadow 300ms ease;
}

.nav-dot:hover,
.nav-dot.active {
    opacity: 1;
}

.nav-dot.active {
    background: #00e5ff;
    box-shadow: 0 0 12px #00e5ff;
}

.navigation-strip.surface .nav-dot {
    border-color: #0a1628;
}

.navigation-strip.surface .nav-dot.active {
    background: #0a1628;
    box-shadow: none;
}

.reveal-on-view {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 800ms cubic-bezier(0.16, 1, 0.3, 1), transform 800ms cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-on-view.is-visible {
    opacity: 1;
    transform: translateY(0);
}

@keyframes pulse-scroll {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.8; }
}

@keyframes sonar-pulse {
    0%, 100% { opacity: 0.06; }
    50% { opacity: 0.12; }
}

@keyframes drift-1 { 0%, 100% { margin: 0; } 50% { margin: -30px 0 0 20px; } }
@keyframes drift-2 { 0%, 100% { margin: 0; } 50% { margin: -40px 0 0 -25px; } }
@keyframes drift-3 { 0%, 100% { margin: 0; } 50% { margin: -35px 0 0 15px; } }
@keyframes drift-4 { 0%, 100% { margin: 0; } 50% { margin: -45px 0 0 -20px; } }
@keyframes drift-5 { 0%, 100% { margin: 0; } 50% { margin: -25px 0 0 25px; } }
@keyframes drift-6 { 0%, 100% { margin: 0; } 50% { margin: -50px 0 0 -30px; } }
@keyframes drift-7 { 0%, 100% { margin: 0; } 50% { margin: -30px 0 0 28px; } }
@keyframes drift-8 { 0%, 100% { margin: 0; } 50% { margin: -38px 0 0 -18px; } }
@keyframes drift-9 { 0%, 100% { margin: 0; } 50% { margin: -42px 0 0 22px; } }
@keyframes drift-10 { 0%, 100% { margin: 0; } 50% { margin: -32px 0 0 -24px; } }

@media (max-width: 900px) {
    .pressure-grid,
    .signal-grid {
        grid-template-columns: 1fr;
    }

    .visual-field,
    .annotation-zone,
    .text-zone {
        min-height: 50vh;
    }

    .annotation-zone,
    .text-zone {
        padding-right: 64px;
    }

    .margin-notes {
        grid-template-columns: repeat(2, minmax(0, max-content));
        margin-left: 0;
    }
}

@media (max-width: 640px) {
    .navigation-strip {
        right: 15px;
    }

    .monumental-number {
        font-size: clamp(4.3rem, 18vw, 7rem);
    }
}
