/* ==========================================================================
   EARTH ONLINE — observation terminal
   A hand-built interface for the only server we share.
   ========================================================================== */

@font-face {
    font-family: "EO Serif";
    src: url("../fonts/NotoSerifSC-Bold.woff2") format("woff2");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: "EO Sans";
    src: url("../fonts/NotoSansSC-Regular.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: "EO Display";
    src: url("../fonts/Syne.woff2") format("woff2");
    font-weight: 500 800;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: "EO Italic";
    src: url("../fonts/InstrumentSerif-Italic.woff2") format("woff2");
    font-weight: 400;
    font-style: italic;
    font-display: swap;
}

:root {
    --bg: #060708;
    --bg-raised: #0b0d0f;
    --bg-glass: rgba(10, 12, 14, .78);
    --ink: #f1ece1;
    --ink-soft: #c8c2b6;
    --ink-dim: #918c82;
    --ink-faint: #615e58;
    --line: rgba(241, 236, 225, .16);
    --line-soft: rgba(241, 236, 225, .08);
    --accent: #ff4d1c;
    --accent-hot: #ff6a3d;
    --accent-wash: rgba(255, 77, 28, .12);
    --mint: #8ad8c9;
    --sun: #ffbd73;
    --blue: #7eb7ff;
    --serif: "EO Serif", "Songti SC", "STSong", "SimSun", serif;
    --sans: "EO Sans", "PingFang SC", "Microsoft YaHei", "Noto Sans SC", sans-serif;
    --display: "EO Display", "Arial Narrow", sans-serif;
    --italic: "EO Italic", Georgia, serif;
    --mono: "Cascadia Mono", "SFMono-Regular", "Menlo", "Consolas", monospace;
    --pad: clamp(20px, 4.2vw, 72px);
    --ease: cubic-bezier(.22, 1, .36, 1);
    --ease-in-out: cubic-bezier(.76, 0, .24, 1);
    --z-stage: 1;
    --z-content: 10;
    --z-chrome: 80;
    --z-modal: 100;
}

*, *::before, *::after { box-sizing: border-box; }

html {
    background: var(--bg);
    color-scheme: dark;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    min-width: 300px;
    background: var(--bg);
    color: var(--ink);
    font-family: var(--sans);
    font-size: 16px;
    line-height: 1.65;
    letter-spacing: .005em;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

body.is-booting,
body.no-scroll { overflow: hidden; }

::selection { background: var(--accent); color: #070808; }

a { color: inherit; text-decoration: none; }
button, input { font: inherit; color: inherit; }
button { border: 0; background: none; padding: 0; cursor: pointer; }
img, svg { display: block; max-width: 100%; }
[hidden] { display: none !important; }
p, h1, h2, h3, h4, dl, dd, dt, figure, blockquote { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }

:focus-visible {
    outline: 1px solid var(--accent);
    outline-offset: 4px;
}

.sr-only {
    position: absolute;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.mono {
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 400;
    letter-spacing: .09em;
    line-height: 1.55;
}

.ok { color: var(--mint); }

.skip-link {
    position: fixed;
    top: -100px; left: 16px;
    z-index: 300;
    padding: 12px 18px;
    background: var(--accent);
    color: #08090a;
    font-size: 13px;
    transition: top .2s ease;
}
.skip-link:focus { top: 12px; }

/* Film grain + vignette --------------------------------------------------- */
.noise {
    position: fixed;
    inset: 0;
    z-index: 90;
    pointer-events: none;
    opacity: .05;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.88' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.62'/%3E%3C/svg%3E");
    mix-blend-mode: soft-light;
}
.vignette {
    position: fixed;
    inset: 0;
    z-index: 5;
    pointer-events: none;
    background:
        radial-gradient(ellipse at 70% 42%, transparent 24%, rgba(0,0,0,.12) 58%, rgba(0,0,0,.55) 100%),
        linear-gradient(90deg, rgba(5,6,7,.92) 0%, rgba(5,6,7,.8) 32%, rgba(5,6,7,.42) 48%, transparent 64%);
}

.scroll-progress {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: 1px;
    z-index: 80;
    background: rgba(241,236,225,.06);
    pointer-events: none;
}
.scroll-progress span {
    display: block;
    height: 100%;
    width: 0;
    background: var(--accent);
    box-shadow: 0 0 12px rgba(255,77,28,.7);
}

/* Custom reticle ---------------------------------------------------------- */
.cursor {
    position: fixed;
    top: 0; left: 0;
    width: 34px; height: 34px;
    z-index: 95;
    pointer-events: none;
    opacity: 0;
    transform: translate(-50%, -50%);
    transition: opacity .25s ease, width .3s var(--ease), height .3s var(--ease);
    mix-blend-mode: difference;
}
.cursor.is-on { opacity: .85; }
.cursor__dot {
    position: absolute;
    top: 50%; left: 50%;
    width: 3px; height: 3px;
    border-radius: 50%;
    background: var(--accent);
    transform: translate(-50%, -50%);
}
.cursor__ring {
    position: absolute;
    inset: 0;
    border: 1px solid rgba(241,236,225,.55);
    border-radius: 50%;
    transition: transform .3s var(--ease);
}
.cursor.is-hover { width: 52px; height: 52px; }
.cursor.is-hover .cursor__ring { border-color: var(--accent); transform: rotate(45deg); border-radius: 2px; }

/* Boot curtain ------------------------------------------------------------ */
.boot {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: clamp(18px, 3vw, 42px) var(--pad);
    background: #050607;
    overflow: hidden;
    transition: clip-path 1.1s var(--ease-in-out), opacity .3s ease 1s;
    clip-path: inset(0 0 0 0);
}
.boot.is-leaving {
    clip-path: inset(0 0 100% 0);
    pointer-events: none;
}
.boot.is-gone { display: none; }
.boot__grid {
    position: absolute;
    inset: -20%;
    background-image:
        linear-gradient(rgba(241,236,225,.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(241,236,225,.05) 1px, transparent 1px);
    background-size: 72px 72px;
    transform: perspective(600px) rotateX(62deg) translateY(30%);
    transform-origin: center bottom;
    opacity: .45;
    mask-image: radial-gradient(ellipse at 50% 40%, #000 5%, transparent 66%);
}
.boot::after {
    content: "";
    position: absolute;
    left: 50%; top: 50%;
    width: 72vw; height: 72vw;
    max-width: 860px; max-height: 860px;
    transform: translate(-50%, -50%);
    border: 1px solid rgba(241,236,225,.06);
    border-radius: 50%;
    box-shadow: 0 0 120px rgba(255,77,28,.08) inset;
    pointer-events: none;
}
.boot__top, .boot__bottom {
    position: relative;
    z-index: 2;
    display: flex;
    justify-content: space-between;
    gap: 20px;
    color: var(--ink-faint);
}
.boot__top .mono, .boot__bottom .mono { font-size: 9px; }
.boot__center {
    position: relative;
    z-index: 2;
    width: min(900px, 100%);
    margin: auto;
    text-align: center;
}
.boot__mark {
    position: relative;
    width: 56px; height: 56px;
    margin: 0 auto 32px;
    border: 1px solid rgba(241,236,225,.25);
    border-radius: 50%;
}
.boot__mark::before, .boot__mark::after {
    content: "";
    position: absolute;
    inset: -9px;
    border: 1px solid rgba(241,236,225,.08);
    border-radius: 50%;
}
.boot__mark::after { inset: 13px; background: var(--accent); border: 0; box-shadow: 0 0 20px var(--accent); }
.boot__mark span {
    position: absolute;
    top: 50%; left: 50%;
    width: 6px; height: 6px;
    background: var(--bg);
    transform: translate(-50%, -50%) rotate(45deg);
    z-index: 1;
}
.boot__word {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: .8;
    margin-bottom: clamp(40px, 7vh, 72px);
}
.boot__word-cn {
    font-family: var(--serif);
    font-weight: 700;
    font-size: clamp(5rem, 15vw, 12rem);
    letter-spacing: -.09em;
    color: var(--ink);
}
.boot__word-en {
    font-family: var(--display);
    font-size: clamp(2.4rem, 8vw, 6.8rem);
    font-weight: 500;
    font-style: italic;
    letter-spacing: -.05em;
    color: transparent;
    -webkit-text-stroke: 1px rgba(241,236,225,.35);
    transform: translateX(8%);
}
.boot__progress { width: min(480px, 72vw); margin: 0 auto; }
.boot__bar {
    height: 1px;
    background: rgba(241,236,225,.15);
    overflow: hidden;
}
.boot__bar span {
    display: block;
    width: 0%;
    height: 100%;
    background: var(--accent);
    transition: width .4s var(--ease);
}
.boot__readout {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-top: 12px;
    color: var(--ink-dim);
}
.boot__readout .mono { font-size: 9px; }
#boot-pct { color: var(--accent); }
.boot__enter {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    margin-top: 34px;
    padding: 12px 20px;
    border: 1px solid rgba(241,236,225,.22);
    color: var(--ink);
    font-size: 12px;
    letter-spacing: .14em;
    opacity: 0;
    transform: translateY(8px);
    pointer-events: none;
    transition: opacity .6s ease, transform .6s var(--ease), background .3s ease, color .3s ease;
}
.boot.is-ready .boot__enter {
    opacity: 1;
    transform: none;
    pointer-events: auto;
}
.boot__enter:hover { background: var(--ink); color: var(--bg); }
.boot__enter .arrow { color: var(--accent); font-size: 16px; }
.boot__enter:hover .arrow { color: var(--bg); }

/* Top bar ----------------------------------------------------------------- */
.topbar {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: var(--z-chrome);
    display: flex;
    align-items: center;
    gap: clamp(16px, 3vw, 48px);
    height: 76px;
    padding: 0 var(--pad);
    border-bottom: 1px solid transparent;
    background: linear-gradient(180deg, rgba(6,7,8,.76), rgba(6,7,8,0));
    transition: background .5s ease, border-color .5s ease, backdrop-filter .5s ease, height .4s var(--ease);
}
.topbar.is-scrolled {
    height: 62px;
    background: rgba(6,7,8,.76);
    border-bottom-color: var(--line-soft);
    backdrop-filter: blur(18px) saturate(1.2);
    -webkit-backdrop-filter: blur(18px) saturate(1.2);
}
.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}
.brand__mark {
    position: relative;
    width: 24px; height: 24px;
    border: 1px solid rgba(241,236,225,.52);
    border-radius: 50%;
    transition: transform .6s var(--ease);
}
.brand__mark::before {
    content: "";
    position: absolute;
    top: 50%; left: -5px; right: -5px;
    height: 1px;
    background: var(--accent);
    transform: rotate(-23deg);
}
.brand__mark::after {
    content: "";
    position: absolute;
    top: 50%; left: 50%;
    width: 5px; height: 5px;
    background: var(--ink);
    border-radius: 50%;
    transform: translate(-50%,-50%);
}
.brand:hover .brand__mark { transform: rotate(180deg); }
.brand__text {
    display: flex;
    align-items: baseline;
    gap: 3px;
    font-family: var(--display);
    font-size: 17px;
    line-height: 1;
    letter-spacing: -.04em;
}
.brand__text b { font-weight: 800; }
.brand__text em { font-family: var(--italic); font-size: 18px; color: var(--accent); font-weight: 400; }
.brand__slash { color: var(--ink-faint); font-size: 9px; margin-left: 6px; }

.topbar__status {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: 6px;
    color: var(--ink-dim);
    white-space: nowrap;
}
.topbar__status .mono { font-size: 9px; }
.topbar__sep { width: 24px; height: 1px; background: var(--line); }
.live-dot {
    display: inline-block;
    width: 5px; height: 5px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 0 3px rgba(255,77,28,.12);
    animation: pulse-dot 2.4s ease-in-out infinite;
    flex: 0 0 auto;
}
@keyframes pulse-dot {
    0%, 100% { opacity: 1; box-shadow: 0 0 0 3px rgba(255,77,28,.12); }
    50% { opacity: .55; box-shadow: 0 0 0 6px rgba(255,77,28,.02); }
}

.topbar__nav {
    display: flex;
    align-items: center;
    gap: clamp(18px, 2.2vw, 36px);
    margin-left: auto;
}
.topbar__nav a {
    position: relative;
    display: flex;
    align-items: baseline;
    gap: 7px;
    font-size: 12px;
    color: var(--ink-dim);
    transition: color .25s ease;
    white-space: nowrap;
}
.topbar__nav a span {
    font-family: var(--mono);
    font-size: 8px;
    color: var(--ink-faint);
    transition: color .25s ease;
}
.topbar__nav a::after {
    content: "";
    position: absolute;
    left: 0; right: 100%;
    bottom: -7px;
    height: 1px;
    background: var(--accent);
    transition: right .35s var(--ease);
}
.topbar__nav a:hover { color: var(--ink); }
.topbar__nav a:hover span { color: var(--accent); }
.topbar__nav a:hover::after { right: 0; }
.topbar__nav a.is-active { color: var(--ink); }
.topbar__nav a.is-active span { color: var(--accent); }
.topbar__nav a.is-active::after { right: 0; }

.topbar__actions { display: flex; align-items: center; gap: 14px; margin-left: 10px; }
.sound-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--ink-dim);
    transition: color .25s ease;
}
.sound-btn:hover { color: var(--ink); }
.sound-btn__bars { display: flex; align-items: center; gap: 2px; height: 13px; }
.sound-btn__bars i {
    display: block;
    width: 1px;
    height: 5px;
    background: currentColor;
    transition: height .3s ease, background .3s ease;
}
.sound-btn.is-on { color: var(--accent); }
.sound-btn.is-on .sound-btn__bars i { animation: sound-bar .9s ease-in-out infinite alternate; height: 13px; }
.sound-btn.is-on .sound-btn__bars i:nth-child(2) { animation-delay: -.25s; }
.sound-btn.is-on .sound-btn__bars i:nth-child(3) { animation-delay: -.5s; }
.sound-btn.is-on .sound-btn__bars i:nth-child(4) { animation-delay: -.7s; }
@keyframes sound-bar { from { height: 3px; } to { height: 13px; } }
.sound-btn__label { font-size: 8px; }
.menu-btn { display: none; width: 30px; height: 30px; position: relative; }
.menu-btn span:not(.sr-only) {
    display: block;
    width: 17px; height: 1px;
    background: var(--ink);
    margin: 5px auto;
    transition: transform .35s var(--ease), opacity .2s ease;
}
.menu-btn[aria-expanded="true"] span:nth-child(1) { transform: translateY(3px) rotate(45deg); }
.menu-btn[aria-expanded="true"] span:nth-child(2) { transform: translateY(-3px) rotate(-45deg); }

.mobile-menu {
    position: fixed;
    inset: 0;
    z-index: 70;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 50px;
    padding: 100px var(--pad) 120px;
    background: rgba(6,7,8,.97);
    backdrop-filter: blur(20px);
    opacity: 0;
    visibility: hidden;
    transition: opacity .4s ease, visibility .4s ease;
}
.mobile-menu.is-open { opacity: 1; visibility: visible; }
.mobile-menu nav { display: flex; flex-direction: column; }
.mobile-menu nav a {
    display: flex;
    align-items: baseline;
    gap: 16px;
    padding: 15px 0;
    border-bottom: 1px solid var(--line-soft);
    font-family: var(--serif);
    font-size: clamp(1.8rem, 7vw, 3rem);
    line-height: 1.2;
    color: var(--ink);
}
.mobile-menu nav a span { font-family: var(--mono); font-size: 9px; color: var(--accent); }
.mobile-menu__actions { display: flex; flex-wrap: wrap; gap: 10px; }
.mobile-menu__actions button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 13px;
    border: 1px solid var(--line);
    color: var(--ink-soft);
    font-size: 11px;
}
.mobile-menu__actions button span { color: var(--accent); }
.mobile-menu p { color: var(--ink-faint); font-size: 9px; }

/* Globe stage ------------------------------------------------------------- */
.globe-stage {
    position: fixed;
    inset: 0;
    z-index: auto;
    pointer-events: none;
    overflow: hidden;
}
.globe-canvas {
    position: absolute;
    top: 0; right: 0;
    width: 72vw;
    height: 100%;
    pointer-events: auto;
    cursor: grab;
    z-index: 2;
    touch-action: pan-y;
}
.globe-canvas:active { cursor: grabbing; }
.globe-canvas canvas { display: block; width: 100% !important; height: 100% !important; }
.globe-stage.is-dragging .globe-canvas { cursor: grabbing; }
.globe-halo {
    position: absolute;
    top: 50%; right: -2vw;
    width: min(76vw, 1080px);
    aspect-ratio: 1;
    transform: translateY(-50%);
    background:
        radial-gradient(circle at 50% 50%, transparent 36%, rgba(39,96,170,.16) 45%, rgba(17,47,91,.07) 58%, transparent 72%);
    filter: blur(26px);
    pointer-events: none;
    z-index: 0;
}
.globe-halo::after {
    content: "";
    position: absolute;
    inset: 9%;
    border-radius: 50%;
    box-shadow: 0 0 110px rgba(61,126,205,.18);
}
.globe-grid {
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: .24;
    background-image:
        linear-gradient(90deg, transparent calc(50% - .5px), rgba(241,236,225,.045) 50%, transparent calc(50% + .5px)),
        linear-gradient(0deg, transparent calc(50% - .5px), rgba(241,236,225,.04) 50%, transparent calc(50% + .5px));
}
.globe-orbit {
    position: absolute;
    top: 50%; right: 1vw;
    width: min(62vw, 880px);
    height: min(50vw, 680px);
    border: 1px solid rgba(241,236,225,.07);
    border-radius: 50%;
    transform: translateY(-50%) rotate(-16deg);
    pointer-events: none;
    z-index: 1;
    mask-image: linear-gradient(90deg, transparent, #000 20%, #000 80%, transparent);
}
.globe-orbit--two {
    width: min(54vw, 760px);
    height: min(40vw, 560px);
    transform: translateY(-50%) rotate(28deg);
    border-color: rgba(255,77,28,.1);
    opacity: .7;
}
.globe-fallback {
    position: absolute;
    top: 50%; right: 4vw;
    width: min(48vw, 680px);
    height: min(48vw, 680px);
    object-fit: contain;
    border-radius: 50%;
    transform: translateY(-50%);
    filter: drop-shadow(0 0 60px rgba(55,110,190,.25));
    z-index: 2;
}
.globe-stage.is-fallback .globe-hud,
body.has-globe-fallback .globe-tools,
body.has-globe-fallback .globe-hud {
    display: none;
}

.globe-hud {
    position: absolute;
    top: 96px; right: 2.7vw; bottom: 132px;
    width: 68vw;
    z-index: 3;
    pointer-events: none;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
.globe-hud__top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2px;
}
.hud-label {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 3px 7px;
    background: rgba(6, 7, 8, .46);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    font-family: var(--mono);
    font-size: 8px;
    letter-spacing: .12em;
    color: var(--ink-dim);
}
.hud-label--dim { color: var(--ink-faint); }
.hint-mobile { display: none; }
.globe-hud__crosshair {
    position: absolute;
    top: 50%; left: 54%;
    width: 46px; height: 46px;
    transform: translate(-50%, -50%);
    opacity: .38;
}
.globe-hud__crosshair span {
    position: absolute;
    background: var(--ink);
}
.globe-hud__crosshair span:nth-child(1) { top: 0; left: 0; width: 10px; height: 1px; }
.globe-hud__crosshair span:nth-child(2) { top: 0; left: 0; width: 1px; height: 10px; }
.globe-hud__crosshair span:nth-child(3) { right: 0; bottom: 0; width: 10px; height: 1px; }
.globe-hud__crosshair span:nth-child(4) { right: 0; bottom: 0; width: 1px; height: 10px; }
.globe-hud__bottom {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    border-top: 1px solid rgba(241,236,225,.08);
    padding-top: 10px;
}
.globe-hud__bottom .mono { font-size: 8px; color: var(--ink-faint); }
.globe-stage.is-scrolled .globe-hud__top,
.globe-stage.is-scrolled .globe-hud__bottom,
.globe-stage.is-scrolled .globe-hud__crosshair {
    opacity: 0;
    transition: opacity .5s ease;
}
.globe-hud__top, .globe-hud__bottom, .globe-hud__crosshair { transition: opacity .5s ease; }

/* Markers ----------------------------------------------------------------- */
.marker-layer {
    position: absolute;
    top: 0; right: 0;
    width: 72vw;
    height: 100%;
    z-index: 4;
    pointer-events: none;
    overflow: hidden;
}
.map-marker {
    position: absolute;
    display: flex;
    align-items: center;
    gap: 7px;
    transform: translate(-50%, -50%);
    pointer-events: auto;
    color: var(--ink);
    opacity: 0;
    transition: opacity .6s ease;
    white-space: nowrap;
    z-index: 2;
}
.map-marker.is-visible { opacity: 1; }
.map-marker__dot {
    position: relative;
    width: 5px; height: 5px;
    border-radius: 50%;
    background: var(--ink);
    box-shadow: 0 0 0 3px rgba(241,236,225,.12);
    flex: 0 0 auto;
    transition: transform .3s var(--ease), background .3s ease, box-shadow .3s ease;
}
.map-marker__dot::after {
    content: "";
    position: absolute;
    inset: -5px;
    border: 1px solid rgba(241,236,225,.24);
    border-radius: 50%;
    opacity: 0;
    transform: scale(.6);
    transition: opacity .3s ease, transform .4s var(--ease);
}
.map-marker__label {
    font-family: var(--mono);
    font-size: 9px;
    letter-spacing: .1em;
    color: var(--ink-soft);
    text-shadow: 0 1px 4px rgba(0,0,0,.8);
    transition: color .25s ease;
}
.map-marker:hover .map-marker__dot {
    background: var(--accent);
    box-shadow: 0 0 0 4px rgba(255,77,28,.18), 0 0 18px rgba(255,77,28,.5);
    transform: scale(1.2);
}
.map-marker:hover .map-marker__dot::after { opacity: 1; transform: scale(1); }
.map-marker:hover .map-marker__label { color: var(--ink); }
.map-marker.is-selected .map-marker__dot { background: var(--accent); box-shadow: 0 0 0 4px rgba(255,77,28,.18); }
.map-marker.is-selected .map-marker__label { color: var(--accent); }
.map-marker--news .map-marker__dot {
    width: 5px; height: 5px;
    border-radius: 0;
    background: var(--sun);
    transform: rotate(45deg);
    box-shadow: none;
}
.map-marker--news { padding: 5px; }
.map-marker--news .map-marker__label { color: rgba(255,189,115,.78); font-size: 7px; }
.map-marker--news:hover .map-marker__dot { background: var(--accent); transform: rotate(45deg) scale(1.4); }
.map-marker--minor .map-marker__label { display: none; }
.map-marker--minor:hover .map-marker__label { display: block; }
.map-marker--news.is-minor .map-marker__label { display: none; }

/* Globe tools / node card / time panel ------------------------------------ */
.globe-tools {
    position: fixed;
    right: clamp(14px, 2.2vw, 36px);
    top: 50%;
    z-index: 45;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 18px;
    transform: translateY(-50%);
    pointer-events: auto;
    transition: opacity .4s ease, transform .5s var(--ease);
}
.view-switch {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 1px;
}
.view-switch button {
    position: relative;
    padding: 6px 0 6px 16px;
    color: var(--ink-faint);
    font-family: var(--mono);
    font-size: 8px;
    letter-spacing: .14em;
    transition: color .25s ease;
}
.view-switch button::before {
    content: "";
    position: absolute;
    right: -10px; top: 50%;
    width: 12px; height: 1px;
    background: var(--line);
    transition: width .3s var(--ease), background .3s ease;
}
.view-switch button:hover { color: var(--ink); }
.view-switch button.is-active { color: var(--accent); }
.view-switch button.is-active::before { width: 24px; background: var(--accent); }
.globe-tools__row { display: flex; flex-direction: column; gap: 8px; }
.globe-tools.is-hidden {
    opacity: 0;
    pointer-events: none;
    transform: translateY(-50%) translateX(18px);
    transition: opacity .45s ease, transform .5s var(--ease);
}
.tool-btn {
    width: 34px; height: 34px;
    display: grid;
    place-items: center;
    border: 1px solid var(--line);
    color: var(--ink-dim);
    background: rgba(8,10,12,.42);
    backdrop-filter: blur(8px);
    transition: color .25s ease, border-color .25s ease, background .25s ease;
}
.tool-btn svg {
    width: 14px; height: 14px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.4;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.tool-btn:hover, .tool-btn[aria-pressed="true"], .tool-btn[aria-expanded="true"] { color: var(--accent); border-color: rgba(255,77,28,.5); background: rgba(255,77,28,.06); }

.node-card {
    position: fixed;
    right: clamp(14px, 2.4vw, 38px);
    bottom: 112px;
    z-index: 46;    width: 330px;
    padding: 22px;
    background: linear-gradient(145deg, rgba(15,18,21,.92), rgba(8,10,12,.9));
    border: 1px solid rgba(241,236,225,.18);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    clip-path: polygon(0 0, 100% 0, 100% calc(100% - 14px), calc(100% - 14px) 100%, 0 100%);
    box-shadow: 0 24px 70px rgba(0,0,0,.45);
    opacity: 0;
    visibility: hidden;
    transform: translateY(18px);
    transition: opacity .45s ease, visibility .45s ease, transform .55s var(--ease);
    pointer-events: auto;
}
.node-card.is-open { opacity: 1; visibility: visible; transform: none; }
.node-scrim {
    position: fixed;
    inset: 0;
    z-index: 44;
    display: none;
    background: rgba(4, 5, 6, .62);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity .4s ease, visibility .4s ease;
}
.node-scrim.is-open { opacity: 1; visibility: visible; pointer-events: auto; }
.node-card::before {
    content: "";
    position: absolute;
    top: -1px; left: 0;
    width: 46px; height: 1px;
    background: var(--accent);
}
.node-card__close {
    position: absolute;
    right: 12px; top: 10px;
    width: 26px; height: 26px;
    color: var(--ink-dim);
    font-size: 18px;
    line-height: 1;
    transition: color .2s ease;
}
.node-card__close:hover { color: var(--accent); }
.node-card__eyebrow {
    display: flex;
    gap: 7px;
    align-items: center;
    color: var(--ink-faint);
    font-size: 8px;
    margin-bottom: 18px;
}
.node-card__head { display: flex; justify-content: space-between; align-items: flex-start; }
.node-card h2 {
    font-family: var(--serif);
    font-size: 32px;
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -.04em;
}
.node-card__head p { color: var(--ink-dim); font-size: 8px; margin-top: 5px; }
.node-card__icon {
    position: relative;
    width: 40px; height: 40px;
    border: 1px solid rgba(255,77,28,.28);
    border-radius: 50%;
    display: grid;
    place-items: center;
}
.node-card__ping {
    width: 7px; height: 7px;
    background: var(--accent);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--accent);
}
.node-card__ping::after {
    content: "";
    position: absolute;
    inset: 7px;
    border: 1px solid rgba(255,77,28,.4);
    border-radius: 50%;
    animation: ping 2.4s ease-out infinite;
}
@keyframes ping {
    0% { transform: scale(.3); opacity: 1; }
    80%, 100% { transform: scale(1.8); opacity: 0; }
}
.node-card__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1px;
    margin-top: 20px;
    background: var(--line-soft);
    border: 1px solid var(--line-soft);
}
.node-card__grid > div {
    background: rgba(9,11,13,.92);
    padding: 11px 12px;
}
.node-card__grid span {
    display: block;
    font-family: var(--mono);
    font-size: 7px;
    letter-spacing: .1em;
    color: var(--ink-faint);
    margin-bottom: 4px;
}
.node-card__grid strong { font-size: 15px; font-weight: 400; }
.node-card__grid strong.mono { font-size: 9px; letter-spacing: .04em; }
.node-card__weather {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-top: 14px;
    color: var(--ink-faint);
}
.node-card__weather .mono { font-size: 7px; }
.node-card__action {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid var(--line-soft);
    color: var(--ink-soft);
    font-size: 11px;
    text-align: left;
    transition: color .25s ease;
}
.node-card__action:hover { color: var(--accent); }
.node-card__action span { color: var(--accent); }

.time-panel {
    position: fixed;
    left: 50%;
    bottom: 116px;
    z-index: 46;
    width: min(560px, calc(100vw - 32px));
    padding: 20px 22px;
    background: rgba(8, 10, 12, .94);
    border: 1px solid var(--line);
    backdrop-filter: blur(20px);
    box-shadow: 0 30px 80px rgba(0,0,0,.45);
    opacity: 0;
    visibility: hidden;
    transform: translate(-50%, 14px);
    transition: opacity .4s ease, visibility .4s ease, transform .5s var(--ease);
    pointer-events: auto;
}
.time-panel.is-open { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.time-panel__head { display: flex; justify-content: space-between; color: var(--ink-soft); margin-bottom: 18px; }
.time-panel__actions { display: flex; align-items: center; gap: 14px; }
.time-panel__head button { color: var(--accent); font-size: 8px; }
.time-panel__head #time-close { color: var(--ink-dim); font-size: 14px; line-height: 1; }
.time-panel__head #time-close:hover { color: var(--accent); }
.time-panel__main { display: flex; align-items: center; gap: 18px; }
.time-panel__main input {
    flex: 1;
    accent-color: var(--accent);
    height: 2px;
    cursor: ew-resize;
}
.time-panel output { font-family: var(--mono); font-size: 11px; color: var(--accent); min-width: 58px; text-align: right; }
.time-panel p { margin-top: 14px; color: var(--ink-dim); font-size: 10px; line-height: 1.7; }

/* Content shell ----------------------------------------------------------- */
.site {
    position: relative;
    z-index: var(--z-content);
    pointer-events: none;
}
.site a, .site button, .site input, .site summary, .site details { pointer-events: auto; }
.hero, .chapter, .footer { position: relative; }

/* Typography helpers */
section[id], footer[id], main[id] { scroll-margin-top: 82px; }
.eyebrow {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--ink-soft);
    font-family: var(--mono);
    font-size: 9px;
    letter-spacing: .14em;
    line-height: 1.6;
    text-transform: uppercase;
}
.eyebrow__dim { color: var(--ink-faint); }
.chapter__index {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--accent);
    font-size: 9px;
    letter-spacing: .12em;
    margin-bottom: 34px;
}
.chapter__title {
    font-family: var(--serif);
    font-size: clamp(3.2rem, 6.4vw, 6.4rem);
    font-weight: 700;
    line-height: 1.04;
    letter-spacing: -.055em;
    text-wrap: balance;
}
.chapter__title em, .footer__end h2 em {
    font-family: var(--italic);
    font-style: italic;
    font-weight: 400;
    color: var(--accent);
    letter-spacing: -.02em;
}
.chapter__lede {
    max-width: 500px;
    margin-top: 24px;
    color: var(--ink-dim);
    font-size: 13px;
    line-height: 1.9;
}

/* Buttons */
.btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    min-height: 50px;
    padding: 0 21px;
    border: 1px solid var(--line);
    color: var(--ink);
    background: transparent;
    font-size: 12px;
    letter-spacing: .04em;
    white-space: nowrap;
    overflow: hidden;
    clip-path: polygon(0 0, calc(100% - 9px) 0, 100% 9px, 100% 100%, 0 100%);
    transition: color .3s ease, background .3s ease, border-color .3s ease, transform .35s var(--ease);
}
.btn svg {
    width: 17px; height: 17px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.4;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: transform .35s var(--ease);
}
.btn::before {
    content: "";
    position: absolute;
    inset: 0;
    background: var(--ink);
    transform: translateY(101%);
    transition: transform .45s var(--ease);
    z-index: 0;
}
.btn > * { position: relative; z-index: 1; }
.btn:hover { color: var(--bg); border-color: var(--ink); transform: translateY(-2px); }
.btn:hover::before { transform: translateY(0); }
.btn:hover svg { transform: translateX(4px); }
.btn--primary {
    background: var(--accent);
    border-color: var(--accent);
    color: #08090a;
    font-weight: 600;
}
.btn--primary::before { background: var(--ink); }
.btn--primary:hover { color: var(--bg); border-color: var(--ink); }
.btn--ghost { border-color: rgba(241,236,225,.24); }
.btn--ghost:hover { color: var(--bg); }
.btn__key {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px; height: 18px;
    margin-left: 4px;
    border: 1px solid rgba(241,236,225,.24);
    font-size: 8px;
    color: var(--ink-dim);
}
.btn:hover .btn__key { border-color: rgba(6,7,8,.3); color: var(--bg); }
.text-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--ink-soft);
    font-size: 11px;
    border-bottom: 1px solid var(--line);
    padding-bottom: 3px;
    transition: color .25s ease, border-color .25s ease;
}
.text-btn span { color: var(--accent); }
.text-btn:hover { color: var(--accent); border-color: var(--accent); }

/* Hero -------------------------------------------------------------------- */
.hero {
    min-height: 100svh;
    padding: 0 var(--pad);
    display: flex;
    align-items: center;
    overflow: hidden;
}
.hero__copy {
    width: min(720px, 49vw);
    padding-top: 9vh;
    pointer-events: auto;
}
.hero-title {
    position: relative;
    margin: 22px 0 30px;
    line-height: .8;
}
.hero-title__cn {
    display: block;
    font-family: var(--serif);
    font-size: clamp(6.4rem, 13vw, 13.4rem);
    font-weight: 700;
    letter-spacing: -.1em;
    line-height: .78;
    color: var(--ink);
    text-shadow: 0 0 80px rgba(255,255,255,.06);
}
.hero-title__en {
    display: block;
    margin-top: 2px;
    margin-left: .09em;
    font-family: var(--display);
    font-size: clamp(3.1rem, 7.4vw, 7.6rem);
    font-weight: 500;
    font-style: italic;
    letter-spacing: -.075em;
    line-height: .8;
    color: transparent;
    -webkit-text-stroke: 1px rgba(241,236,225,.48);
    transform: translateX(1.6%);
}
.hero-title__dot {
    color: var(--accent);
    -webkit-text-stroke: 0;
    font-family: var(--serif);
    font-style: normal;
    font-size: .65em;
    margin-left: .02em;
}
.hero__lede {
    max-width: 430px;
    color: var(--ink-soft);
}
.hero__lede > p:first-child {
    font-size: clamp(1.15rem, 1.55vw, 1.5rem);
    line-height: 1.65;
    letter-spacing: -.02em;
}
.hero__lede em {
    color: var(--accent);
    font-family: var(--italic);
    font-style: italic;
    font-size: 1.12em;
    letter-spacing: .01em;
}
.hero__small {
    margin-top: 14px;
    color: var(--ink-dim);
    font-size: 12px;
    line-height: 1.9;
}
.hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 38px;
}
.hero__readouts {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    margin-top: 58px;
    padding-top: 17px;
    border-top: 1px solid var(--line-soft);
    max-width: 560px;
}
.hero__readouts dt { color: var(--ink-faint); font-size: 8px; margin-bottom: 7px; }
.hero__readouts dd { color: var(--ink-soft); font-size: 11px; letter-spacing: .04em; }
.hero__readouts dd .ok { font-size: 8px; }
.hero__side {
    display: none;
    position: absolute;
    right: 84px;
    top: 22vh;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    color: var(--ink-faint);
    opacity: .65;
}
.vertical-note {
    writing-mode: vertical-rl;
    font-size: 7px;
    letter-spacing: .2em;
    text-transform: uppercase;
}
.hero__side-line { width: 1px; height: 80px; background: var(--line); }
.hero__scroll {
    position: absolute;
    left: var(--pad);
    bottom: 66px;
    display: flex;
    align-items: center;
    gap: 14px;
    color: var(--ink-faint);
    pointer-events: none;
}
.hero__scroll .mono { font-size: 8px; letter-spacing: .16em; }
.hero__scroll-line {
    position: relative;
    display: block;
    width: 54px; height: 1px;
    background: var(--line);
    overflow: hidden;
}
.hero__scroll-line i {
    position: absolute;
    top: 0; left: 0;
    width: 45%; height: 100%;
    background: var(--accent);
    animation: scroll-line 2.6s var(--ease) infinite;
}
@keyframes scroll-line {
    0% { transform: translateX(-120%); }
    55%, 100% { transform: translateX(240%); }
}
.hero__corner {
    position: absolute;
    right: 3vw;
    bottom: 64px;
    display: flex;
    gap: 20px;
    color: var(--ink-faint);
    font-size: 7px;
    letter-spacing: .08em;
    pointer-events: none;
}

/* Chapter layout ---------------------------------------------------------- */
.chapter {
    min-height: 100vh;
    padding: 17vh var(--pad) 15vh;
    display: flex;
    align-items: flex-start;
}
.chapter__rule {
    position: absolute;
    top: 9vh; left: var(--pad); right: var(--pad);
    height: 1px;
    background: var(--line-soft);
}
.chapter__rule span {
    display: block;
    width: 46px; height: 1px;
    background: var(--accent);
}
.chapter__inner {
    width: min(680px, 47vw);
    pointer-events: auto;
}
.chapter__head {
    margin-bottom: 46px;
}
