/* === RESET & BASE === */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-snap-type: y proximity;
    scroll-behavior: smooth;
    background-color: #1e1e2e;
}

body {
    font-family: 'Anybody', sans-serif;
    font-weight: 400;
    font-stretch: 75%;
    color: #c8c8d8;
    background-color: #1e1e2e;
    overflow-x: hidden;
}

/* === TYPOGRAPHY === */
.dela {
    font-family: 'Dela Gothic One', sans-serif;
    font-weight: 400;
}

h2 {
    font-family: 'Dela Gothic One', sans-serif;
    font-weight: 400;
    font-size: clamp(1.8rem, 4vw, 3.2rem);
    letter-spacing: 0.02em;
    color: #c8c8d8;
}

.kanji-accent {
    font-family: 'Noto Serif JP', serif;
    font-weight: 700;
    font-size: clamp(1.2rem, 3vw, 2.4rem);
    color: #f0e8ff;
}

.large-kanji {
    font-size: clamp(3rem, 6vw, 5rem);
}

.mono-data {
    font-family: 'IBM Plex Mono', monospace;
    font-weight: 300;
    font-size: clamp(0.75rem, 1vw, 0.9rem);
    color: #7a7a94;
}

.cell-body {
    font-family: 'Anybody', sans-serif;
    font-weight: 400;
    font-stretch: 75%;
    font-size: clamp(0.9rem, 1.5vw, 1.1rem);
    color: #c0c0d0;
    line-height: 1.5;
}

.cell-label {
    font-family: 'Anybody', sans-serif;
    font-weight: 600;
    font-stretch: 125%;
    font-size: clamp(0.7rem, 1vw, 0.85rem);
    color: #7a7a94;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    margin-top: 0.5em;
}

/* === MARBLE TEXTURE === */
.marble-bg {
    background:
        linear-gradient(125deg, transparent 30%, rgba(184,115,136,0.08) 40%, transparent 50%),
        linear-gradient(235deg, transparent 40%, rgba(90,138,138,0.06) 50%, transparent 60%),
        radial-gradient(ellipse at 30% 70%, rgba(240,232,255,0.12) 0%, transparent 50%),
        linear-gradient(180deg, #c8c8d8 0%, #1e1e2e 100%);
}

/* === UNDERLINE DRAW === */
.draw-underline {
    position: relative;
    display: inline-block;
}

.draw-underline::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, #b87388, #5a8a8a);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 600ms cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.draw-underline.visible::after {
    transform: scaleX(1);
}

/* === ZONE 1: SHELL VAULT === */
.shell-vault {
    height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(180deg, #2a2a40 0%, #1e1e2e 50%, #2a2a40 100%);
    position: relative;
    overflow: hidden;
    scroll-snap-align: start;
}

.chrome-sweep-container {
    position: relative;
}

.shell-form {
    width: clamp(260px, 40vw, 440px);
    height: clamp(260px, 40vw, 440px);
    border-radius: 42% 58% 55% 45% / 38% 62% 38% 62%;
    background: radial-gradient(ellipse at 35% 35%, #f0e8ff 0%, #c8c8d8 40%, #5a8a8a 70%, #1e1e2e 100%);
    box-shadow:
        inset -8px -8px 24px rgba(30,30,46,0.4),
        inset 8px 8px 24px rgba(240,232,255,0.6),
        0 20px 60px rgba(30,30,46,0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    animation: breathe 4s ease-in-out infinite;
}

.shell-text {
    font-family: 'Dela Gothic One', sans-serif;
    font-weight: 400;
    font-size: clamp(1.8rem, 4vw, 3rem);
    letter-spacing: 0.02em;
    color: #2a2a40;
    text-shadow:
        0 1px 0 rgba(240,232,255,0.8),
        0 -1px 0 rgba(30,30,46,0.3),
        0 2px 4px rgba(30,30,46,0.2);
    z-index: 2;
    position: relative;
}

.chrome-sweep {
    position: absolute;
    top: -100%;
    left: -50%;
    width: 200%;
    height: 400%;
    background: linear-gradient(135deg, transparent 45%, rgba(240,232,255,0.4) 49%, rgba(240,232,255,0.6) 50%, rgba(240,232,255,0.4) 51%, transparent 55%);
    animation: chromeSweep 6s ease-in-out infinite;
    z-index: 1;
    pointer-events: none;
}

@keyframes breathe {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.015); }
}

@keyframes chromeSweep {
    0%, 100% { transform: translateX(-100%) translateY(-100%) rotate(0deg); }
    50% { transform: translateX(100%) translateY(100%) rotate(0deg); }
}

.sky-kanji {
    font-family: 'Noto Serif JP', serif;
    font-weight: 400;
    font-size: clamp(2rem, 4vw, 3.5rem);
    color: #f0e8ff;
    margin-top: 2rem;
    animation: pulseKanji 3s ease-in-out infinite;
}

@keyframes pulseKanji {
    0%, 100% { transform: scale(1); opacity: 0.7; }
    50% { transform: scale(1.08); opacity: 1; }
}

.shell-spiral-watermark {
    position: absolute;
    width: 80vw;
    height: 80vw;
    max-width: 600px;
    max-height: 600px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    z-index: 0;
}

/* === ZONE 2: BENTO GRID === */
.bento-grid-section {
    min-height: 180vh;
    padding: 4rem 2rem;
    background-color: #1e1e2e;
    scroll-snap-align: start;
    position: relative;
}

.bento-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    grid-template-rows: repeat(4, minmax(180px, auto));
    gap: 4px;
    max-width: 1200px;
    margin: 0 auto;
    background-color: #1e1e2e;
}

.bento-cell {
    border-radius: 6px;
    overflow: hidden;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.75rem;
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 500ms ease, transform 500ms ease;
    background:
        linear-gradient(125deg, transparent 30%, rgba(184,115,136,0.08) 40%, transparent 50%),
        linear-gradient(235deg, transparent 40%, rgba(90,138,138,0.06) 50%, transparent 60%),
        radial-gradient(ellipse at 30% 70%, rgba(240,232,255,0.12) 0%, transparent 50%),
        linear-gradient(180deg, #2a2a40 0%, #1e1e2e 100%);
}

.bento-cell.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Cell placements */
.cell-futures {
    grid-column: 1 / 4;
    grid-row: 1 / 2;
}

.cell-shells {
    grid-column: 4 / 6;
    grid-row: 1 / 2;
    align-items: center;
    text-align: center;
    background:
        radial-gradient(ellipse at 50% 50%, rgba(184,115,136,0.12) 0%, transparent 60%),
        linear-gradient(180deg, #2a2a40 0%, #1e1e2e 100%);
}

.cell-sky {
    grid-column: 6 / 7;
    grid-row: 1 / 3;
    align-items: center;
    text-align: center;
    background:
        radial-gradient(ellipse at 50% 30%, rgba(240,232,255,0.15) 0%, transparent 50%),
        linear-gradient(180deg, #5a8a8a 0%, #1e1e2e 100%);
}

.cell-exchange {
    grid-column: 1 / 3;
    grid-row: 2 / 4;
    background:
        linear-gradient(180deg, #1e1e2e 0%, #2a2a40 100%);
}

.cell-tides {
    grid-column: 3 / 6;
    grid-row: 2 / 3;
    align-items: center;
    text-align: center;
    background:
        linear-gradient(235deg, transparent 40%, rgba(90,138,138,0.1) 50%, transparent 60%),
        linear-gradient(180deg, #2a2a40 0%, #1e1e2e 100%);
}

.cell-signal {
    grid-column: 3 / 7;
    grid-row: 3 / 5;
    background:
        linear-gradient(125deg, transparent 30%, rgba(184,115,136,0.06) 40%, transparent 50%),
        radial-gradient(ellipse at 70% 30%, rgba(240,232,255,0.08) 0%, transparent 50%),
        linear-gradient(180deg, #2a2a40 0%, #1e1e2e 100%);
}

.ticker {
    font-family: 'Anybody', sans-serif;
    font-weight: 600;
    font-stretch: 125%;
    font-size: clamp(0.7rem, 1vw, 0.85rem);
    color: #5a8a8a;
    letter-spacing: 0.1em;
}

.ticker-feed {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.ticker-line {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.4rem 0;
    border-bottom: 1px solid rgba(200,200,216,0.08);
}

.price {
    color: #e8a0b0;
}

.timestamp {
    margin-top: auto;
    opacity: 0.6;
}

/* === ZONE 3: MOUNTAIN RANGE === */
.mountain-section {
    min-height: 100vh;
    position: relative;
    overflow: hidden;
    scroll-snap-align: start;
    background: linear-gradient(180deg, #1e1e2e 0%, #2a2a40 30%, #5a8a8a 60%, #c8c8d8 80%, #5a8a8a 90%, #2a2a40 95%, #1e1e2e 100%);
}

.mountain-sky {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 50%;
    background: linear-gradient(180deg, #1e1e2e 0%, #2a2a40 40%, #7a7a94 80%, #c8c8d8 100%);
}

.mountain-layer {
    position: sticky;
    width: 100%;
    height: 0;
    z-index: 2;
}

.mountain-bg {
    top: 40vh;
    height: 30vh;
    background: linear-gradient(180deg, #c8c8d8, #7a7a94);
    clip-path: polygon(0% 80%, 5% 60%, 12% 70%, 20% 40%, 28% 55%, 35% 30%, 42% 50%, 50% 25%, 58% 45%, 65% 35%, 72% 50%, 80% 20%, 88% 45%, 95% 55%, 100% 40%, 100% 100%, 0% 100%);
    opacity: 0.6;
}

.mountain-mid {
    top: 50vh;
    height: 35vh;
    background: linear-gradient(180deg, #5a8a8a, #2a2a40);
    clip-path: polygon(0% 70%, 8% 50%, 15% 65%, 22% 35%, 30% 55%, 38% 25%, 45% 45%, 52% 20%, 60% 40%, 68% 30%, 75% 50%, 82% 15%, 90% 40%, 100% 50%, 100% 100%, 0% 100%);
    opacity: 0.8;
}

.mountain-fg {
    top: 60vh;
    height: 40vh;
    background: linear-gradient(180deg, #2a2a40, #1e1e2e);
    clip-path: polygon(0% 65%, 6% 45%, 14% 60%, 20% 30%, 26% 50%, 34% 20%, 40% 40%, 48% 15%, 55% 35%, 62% 25%, 70% 45%, 78% 10%, 85% 35%, 92% 45%, 100% 30%, 100% 100%, 0% 100%);
}

.mountain-reflection {
    position: absolute;
    width: 100%;
    z-index: 1;
}

.mountain-bg-ref {
    bottom: 0;
    height: 20vh;
    background: linear-gradient(180deg, #7a7a94, #c8c8d8);
    clip-path: polygon(0% 20%, 5% 40%, 12% 30%, 20% 60%, 28% 45%, 35% 70%, 42% 50%, 50% 75%, 58% 55%, 65% 65%, 72% 50%, 80% 80%, 88% 55%, 95% 45%, 100% 60%, 100% 0%, 0% 0%);
    opacity: 0.15;
}

.mountain-mid-ref {
    bottom: 0;
    height: 18vh;
    background: linear-gradient(180deg, #2a2a40, #5a8a8a);
    clip-path: polygon(0% 30%, 8% 50%, 15% 35%, 22% 65%, 30% 45%, 38% 75%, 45% 55%, 52% 80%, 60% 60%, 68% 70%, 75% 50%, 82% 85%, 90% 60%, 100% 50%, 100% 0%, 0% 0%);
    opacity: 0.15;
}

.mountain-fg-ref {
    bottom: 0;
    height: 15vh;
    background: linear-gradient(180deg, #1e1e2e, #2a2a40);
    clip-path: polygon(0% 35%, 6% 55%, 14% 40%, 20% 70%, 26% 50%, 34% 80%, 40% 60%, 48% 85%, 55% 65%, 62% 75%, 70% 55%, 78% 90%, 85% 65%, 92% 55%, 100% 70%, 100% 0%, 0% 0%);
    opacity: 0.2;
}

.mountain-text {
    position: absolute;
    top: 35%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
    text-align: center;
}

.mountain-title {
    font-family: 'Dela Gothic One', sans-serif;
    font-weight: 400;
    font-size: clamp(1.8rem, 4vw, 3.2rem);
    letter-spacing: 0.02em;
    color: #f0e8ff;
    text-shadow: 0 2px 12px rgba(30,30,46,0.6);
}

.mountain-text-lower {
    top: 45%;
}

.shell-spiral-mountain {
    position: absolute;
    width: 50vw;
    max-width: 400px;
    height: auto;
    top: 20%;
    right: 5%;
    z-index: 3;
    opacity: 0.12;
}

.spiral-draw {
    stroke-dasharray: 1200;
    stroke-dashoffset: 1200;
    transition: stroke-dashoffset 3s ease-in-out;
}

.spiral-draw.visible {
    stroke-dashoffset: 0;
}

/* === ZONE 4: ARCHIVE === */
.archive-section {
    min-height: 80vh;
    padding: 6rem 2rem;
    background-color: #1e1e2e;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3rem;
    scroll-snap-align: start;
}

.archive-title {
    color: #c8c8d8;
}

.archive-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.2rem;
    max-width: 900px;
}

.badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.6em 1.4em;
    border-radius: 50px;
    background: radial-gradient(ellipse at 30% 30%, #f0e8ff 0%, #c8c8d8 50%, #7a7a94 100%);
    box-shadow:
        inset -3px -3px 8px rgba(30,30,46,0.3),
        inset 3px 3px 8px rgba(240,232,255,0.5),
        0 6px 20px rgba(30,30,46,0.25);
    text-shadow: 0 1px 2px rgba(240,232,255,0.8);
    font-family: 'Dela Gothic One', sans-serif;
    font-weight: 400;
    font-size: clamp(0.9rem, 1.5vw, 1.3rem);
    color: #2a2a40;
    cursor: default;
    opacity: 0;
    transform: translateY(12px) scale(0.95);
    transition: opacity 500ms ease, transform 500ms ease, box-shadow 300ms ease;
    position: relative;
    overflow: hidden;
}

.badge.visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.badge:hover {
    box-shadow:
        inset -3px -3px 8px rgba(30,30,46,0.3),
        inset 3px 3px 8px rgba(240,232,255,0.5),
        0 8px 28px rgba(184,115,136,0.3);
}

.badge::before {
    content: '';
    position: absolute;
    top: -100%;
    left: -50%;
    width: 200%;
    height: 400%;
    background: linear-gradient(135deg, transparent 45%, rgba(240,232,255,0.3) 49%, rgba(240,232,255,0.5) 50%, rgba(240,232,255,0.3) 51%, transparent 55%);
    animation: badgeSweep 6s ease-in-out infinite;
    pointer-events: none;
}

@keyframes badgeSweep {
    0%, 100% { transform: translateX(-100%) translateY(-100%); }
    50% { transform: translateX(100%) translateY(100%); }
}

/* === ZONE 5: HORIZON === */
.horizon-section {
    min-height: 40vh;
    background: linear-gradient(90deg, #c8c8d8 0%, #7a7a94 30%, #2a2a40 60%, #1e1e2e 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    scroll-snap-align: start;
    overflow: hidden;
}

.horizon-vanish {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    perspective: 600px;
}

.horizon-text {
    font-family: 'Dela Gothic One', sans-serif;
    font-weight: 400;
    letter-spacing: 0.02em;
    color: #c8c8d8;
    white-space: nowrap;
    line-height: 1.2;
}

.h-1 { font-size: clamp(2.5rem, 6vw, 5rem); opacity: 1; }
.h-2 { font-size: clamp(2rem, 4.8vw, 4rem); opacity: 0.75; }
.h-3 { font-size: clamp(1.6rem, 3.8vw, 3.2rem); opacity: 0.55; }
.h-4 { font-size: clamp(1.2rem, 2.8vw, 2.4rem); opacity: 0.4; }
.h-5 { font-size: clamp(0.9rem, 2vw, 1.8rem); opacity: 0.28; }
.h-6 { font-size: clamp(0.7rem, 1.4vw, 1.3rem); opacity: 0.18; }
.h-7 { font-size: clamp(0.5rem, 1vw, 0.9rem); opacity: 0.1; }

/* === RESPONSIVE === */
@media (max-width: 768px) {
    .bento-grid {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: auto;
    }

    .cell-futures { grid-column: 1 / 3; grid-row: auto; }
    .cell-shells { grid-column: 1 / 2; grid-row: auto; }
    .cell-sky { grid-column: 2 / 3; grid-row: auto; }
    .cell-exchange { grid-column: 1 / 3; grid-row: auto; }
    .cell-tides { grid-column: 1 / 3; grid-row: auto; }
    .cell-signal { grid-column: 1 / 3; grid-row: auto; }

    .bento-cell {
        min-height: 150px;
    }
}
