/* Tidehaven: a harbour at sunset. Night-harbour navy, pearl sand, antique gold from the logo (the red gem is --gem).
   Signature: the ship rocks: the whole hero picture rolls and heaves on the swell.
   Shape: the notched corner of a ship's brass plate (a concave quarter circle cut from each corner).
   core.css expects the accent family ("gold" is the historic name: here it is antique gold), --ink, --ink-dim,
   --cream, --header-bg, --panel-line, the fonts, --ease-out and the .btn-gold / .btn-ghost classes. */

:root {
  /* accent family: antique gold from the logo's filigree (the coral gem is --gem). site.js `theme.accent` regenerates all of these at runtime. */
  --gold: #c79a4a;
  --gold-deep: #8e6a2c;
  --gold-text: #7a5417;        /* antique gold for small text on sand, 4.5:1 or better */
  --gold-h1: #dcb466;
  --gold-light: #e6c584;
  --gold-warm: #efd6a0;
  --gold-shine: #f6e4bb;
  --gold-pale: #fbf1d9;
  --gold-bronze: #a67a3a;
  --gold-bronze-dark: #6e4d1c;
  --gold-rgb: 199, 154, 74;
  --gold-h1-rgb: 220, 180, 102;
  --gold-deep-rgb: 142, 106, 44;
  --gold-light-rgb: 230, 197, 132;
  --gem: #d45f52;              /* the coral gem of the logo: live status and the hot spots only */

  /* the sea */
  --deep: #0a1828;             /* hero, voyage: also the water colour baked into the shoreline strips */
  --abyss: #060f1c;            /* rankings, footer */
  --tide: #10263f;             /* panels on water */
  --ink: #eef0f4;              /* text on water */
  --ink-dim: #a9b6c8;
  --panel-line: rgba(233, 240, 236, 0.14);
  --header-bg: #071422;
  --bar-bg: rgba(7, 20, 34, 0.97);
  --veil-bg: #071422;

  /* the sand */
  --cream: #efe7d8;
  --sand: #efe7d8;
  --sand-card: #f8f3ea;
  --sand-ink: #1b2432;
  --sand-ink-dim: #4a5566;
  --sand-line: rgba(28, 43, 45, 0.14);

  --font-display: "Cormorant Garamond", ui-serif, Georgia, serif;
  --font-numeral: "DM Serif Display", ui-serif, Georgia, serif;
  --font-body: "Figtree", ui-sans-serif, system-ui, sans-serif;

  --container: 1200px;
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --n: 8px;                    /* notch radius */

  /* the notched outline for ghost buttons and cards, drawn as a 9-slice so the corners never stretch */
  --ring-coral: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3E%3Cpath d='M8 .6H22A7.4 7.4 0 0 0 29.4 8V22A7.4 7.4 0 0 0 22 29.4H8A7.4 7.4 0 0 0 .6 22V8A7.4 7.4 0 0 0 8 .6Z' fill='none' stroke='%23dcb466' stroke-opacity='.7' stroke-width='1.2'/%3E%3C/svg%3E");
  --ring-pearl: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3E%3Cpath d='M8 .6H22A7.4 7.4 0 0 0 29.4 8V22A7.4 7.4 0 0 0 22 29.4H8A7.4 7.4 0 0 0 .6 22V8A7.4 7.4 0 0 0 8 .6Z' fill='none' stroke='%23eef2ee' stroke-opacity='.22' stroke-width='1.2'/%3E%3C/svg%3E");
  --ring-ink: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3E%3Cpath d='M8 .6H22A7.4 7.4 0 0 0 29.4 8V22A7.4 7.4 0 0 0 22 29.4H8A7.4 7.4 0 0 0 .6 22V8A7.4 7.4 0 0 0 8 .6Z' fill='none' stroke='%231c2b2d' stroke-opacity='.3' stroke-width='1.2'/%3E%3C/svg%3E");
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--abyss); color: var(--ink); font-family: var(--font-body); line-height: 1.6; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { font-family: var(--font-display); margin: 0; line-height: 1.08; font-weight: 700; }
p { margin: 0 0 1em; }
.wrap { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 28px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 2px solid var(--gold-h1); outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* ============================================
   Shape: the notched corner. A concave quarter circle is taken out of every corner.
   Filled things use the mask; outlined things add the 9-slice ring (same radius, so the two line up).
   ============================================ */
.notch, .social, .dock-link, .tab, .scene-tab {
  -webkit-mask:
    radial-gradient(circle at 0 0, #0000 var(--n), #000 calc(var(--n) + 0.5px)) 0 0 / 51% 51% no-repeat,
    radial-gradient(circle at 100% 0, #0000 var(--n), #000 calc(var(--n) + 0.5px)) 100% 0 / 51% 51% no-repeat,
    radial-gradient(circle at 0 100%, #0000 var(--n), #000 calc(var(--n) + 0.5px)) 0 100% / 51% 51% no-repeat,
    radial-gradient(circle at 100% 100%, #0000 var(--n), #000 calc(var(--n) + 0.5px)) 100% 100% / 51% 51% no-repeat;
  mask:
    radial-gradient(circle at 0 0, #0000 var(--n), #000 calc(var(--n) + 0.5px)) 0 0 / 51% 51% no-repeat,
    radial-gradient(circle at 100% 0, #0000 var(--n), #000 calc(var(--n) + 0.5px)) 100% 0 / 51% 51% no-repeat,
    radial-gradient(circle at 0 100%, #0000 var(--n), #000 calc(var(--n) + 0.5px)) 0 100% / 51% 51% no-repeat,
    radial-gradient(circle at 100% 100%, #0000 var(--n), #000 calc(var(--n) + 0.5px)) 100% 100% / 51% 51% no-repeat;
}
.notch-lg { --n: 14px; }
/* a mask also cuts the focus ring, so masked controls draw it inside themselves */
.notch:focus-visible, .social:focus-visible, .dock-link:focus-visible, .tab:focus-visible, .scene-tab:focus-visible { outline: 2px solid var(--ink); outline-offset: -6px; }
.btn-gold-sm:focus-visible, .btn-gold-lg:focus-visible { outline-color: #2a1a05; }

/* ---- buttons (required by core.css): a plate of brass in a chamfered frame, the way Lineage II draws its windows:
   an outer brass line, a dark gap, then the face. Engraved capitals. ---- */
.btn-gold-sm, .btn-gold-lg, .btn-ghost-sm, .btn-ghost-lg {
  --c: 9px;
  position: relative; isolation: isolate;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 44px; padding: 0 26px; border: 0; cursor: pointer; white-space: nowrap;
  font: 700 0.86rem var(--font-display); letter-spacing: 0.16em; text-transform: uppercase;
  background: linear-gradient(180deg, #f6e4bb 0%, #c99a45 46%, #6e4d1c 100%);          /* the outer brass line */
  clip-path: polygon(var(--c) 0, calc(100% - var(--c)) 0, 100% var(--c), 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, var(--c) 100%, 0 calc(100% - var(--c)), 0 var(--c));
}
.btn-gold-sm::before, .btn-gold-lg::before, .btn-ghost-sm::before, .btn-ghost-lg::before,
.btn-gold-sm::after, .btn-gold-lg::after, .btn-ghost-sm::after, .btn-ghost-lg::after {
  content: ""; position: absolute; z-index: -1;
  clip-path: polygon(var(--c) 0, calc(100% - var(--c)) 0, 100% var(--c), 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, var(--c) 100%, 0 calc(100% - var(--c)), 0 var(--c));
}
.btn-gold-sm::before, .btn-gold-lg::before, .btn-ghost-sm::before, .btn-ghost-lg::before { inset: 2px; --c: 7.5px; background: #040c16; }   /* the dark gap */
.btn-gold-sm::after, .btn-gold-lg::after, .btn-ghost-sm::after, .btn-ghost-lg::after { inset: 4px; --c: 5.5px; transition: background-position 0.45s var(--ease-out); background-size: 100% 220%; background-position: 0 0; }   /* the face */
.btn-gold-sm, .btn-gold-lg { color: #2a1a05; text-shadow: 0 1px 0 rgba(255, 246, 224, 0.5); }
.btn-gold-sm::after, .btn-gold-lg::after { background-image: linear-gradient(180deg, #fbefcf 0%, #e8c477 38%, #c39441 62%, #ecd08f 100%); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.6); }
.btn-ghost-sm, .btn-ghost-lg { color: #f6ece0; text-shadow: 0 1px 2px rgba(0, 0, 0, 0.8); }
.btn-ghost-sm::after, .btn-ghost-lg::after { background-image: linear-gradient(180deg, #1a4570 0%, #0f2c4a 45%, #081e36 100%); box-shadow: inset 0 1px 0 rgba(238, 240, 244, 0.22); }
.btn-gold-sm, .btn-ghost-sm { min-height: 42px; padding: 0 22px; font-size: 0.8rem; }
.btn-gold-lg, .btn-ghost-lg { min-height: 56px; padding: 0 34px; font-size: 0.92rem; --c: 11px; }
.btn-gold-lg::before, .btn-ghost-lg::before { --c: 9.5px; }
.btn-gold-lg::after, .btn-ghost-lg::after { --c: 7.5px; }
.btn-gold-lg svg, .btn-gold-sm svg, .btn-ghost-lg svg { width: 16px; height: 16px; flex-shrink: 0; }
.btn-gold-lg:focus-visible, .btn-gold-sm:focus-visible, .btn-ghost-lg:focus-visible, .btn-ghost-sm:focus-visible { outline: 2px solid #fff; outline-offset: -7px; }
@media (hover: hover) and (pointer: fine) {
  .btn-gold-sm:hover::after, .btn-gold-lg:hover::after, .btn-ghost-sm:hover::after, .btn-ghost-lg:hover::after { background-position: 0 100%; }
  .btn-ghost-sm:hover, .btn-ghost-lg:hover { color: #fff; }
}
button.btn-gold-sm, button.btn-ghost-sm { font-family: var(--font-display); }

.eyebrow { display: inline-block; font: 700 0.74rem var(--font-body); letter-spacing: 0.22em; text-transform: uppercase; color: var(--gold-h1); }
.section-head { margin-bottom: 44px; }
.section-head h2 { font-size: clamp(2.3rem, 4.4vw, 3.6rem); margin: 10px 0 12px; }
.section-head p { max-width: 58ch; color: var(--ink-dim); font-size: 1.04rem; }
.text-link { display: inline-flex; align-items: center; gap: 8px; font: 700 0.8rem var(--font-body); letter-spacing: 0.1em; text-transform: uppercase; color: var(--gold-h1); }
.text-link svg { width: 14px; height: 14px; transition: transform 0.25s var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .text-link:hover svg { transform: translateX(4px); } }

/* ============================================
   Header: floats on the hero, sticks once you leave it (core.css)
   ============================================ */
.site-header { position: absolute; top: 0; left: 0; right: 0; z-index: 30; }
.header-inner { display: flex; align-items: center; height: 100px; }
.brand { display: flex; align-items: center; }
.brand-logo { height: 82px; width: auto; filter: drop-shadow(0 3px 12px rgba(0, 0, 0, 0.55)); }
.main-nav { display: flex; gap: 30px; margin-left: auto; margin-right: 26px; }
.main-nav a, .main-nav .nav-menu-btn { position: relative; font: 600 0.93rem var(--font-body); color: #d3dae6; text-shadow: 0 1px 10px rgba(0,0,0,0.6); transition: color 0.15s ease; }
.main-nav > .nav-item > a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -7px; height: 1px;
  background: var(--gold-h1); transform: scaleX(0); transform-origin: left; transition: transform 0.35s var(--ease-out);
}
@media (hover: hover) and (pointer: fine) { .main-nav a:hover, .main-nav .nav-menu-btn:hover { color: var(--gold-light); } .main-nav > .nav-item > a:hover::after { transform: scaleX(1); } }
.header-right { display: flex; align-items: center; gap: 14px; }
.account-switch { display: flex; gap: 10px; }
/* the shared dock is hexagonal; here it takes the notched plate like every other control */
.dock .dock-link, .dock .dock-link::before { clip-path: none; }
.dock .dock-link::before { background: var(--header-bg); }
.dock .dock-ring { clip-path: none; border-radius: 12px; }   /* the call-out ring was a hexagon too */
/* the dock steps aside while the voyage is pinned, so the sliding chart never runs under it */
.dock { transition: opacity 0.35s ease, visibility 0.35s; }
.in-voyage .dock { opacity: 0; visibility: hidden; }

/* ============================================
   Hero: split. The water on the left carries the words; the art fills the right.
   ============================================ */
.hero { position: relative; min-height: min(100vh, 980px); padding: 150px 0 170px; background: var(--deep); overflow-x: clip; z-index: 5;   /* above the sand section that follows, so the shoreline strip is not cut at the boundary */ }
.hero-media { position: absolute; top: 0; bottom: 0; right: 0; width: 64%; z-index: 0; overflow: hidden; -webkit-mask-image: linear-gradient(90deg, transparent 0, rgba(0,0,0,0.12) 10%, rgba(0,0,0,0.38) 22%, rgba(0,0,0,0.7) 36%, rgba(0,0,0,0.92) 52%, #000 68%); mask-image: linear-gradient(90deg, transparent 0, rgba(0,0,0,0.12) 10%, rgba(0,0,0,0.38) 22%, rgba(0,0,0,0.7) 36%, rgba(0,0,0,0.92) 52%, #000 68%); }   /* the picture melts into the water: no visible panel edge */
/* the picture is cut in two layers (tools/cut_ship.py): the still sea and sky, and the ship with its captain on top.
   .hero-stage is the picture at its natural shape, placed like object-fit: cover with the focus at 66% across, so both layers line up exactly. */
.hero-stage { position: absolute; left: 66%; top: 0; height: 100%; aspect-ratio: 2150 / 1229; transform: translateX(-66%); }
.hero-stage img { position: absolute; display: block; max-width: none; }
.hero-stage .sea { inset: 0; width: 100%; height: 100%; }
/* the ship layer is padded by 100px on every side (edge pixels repeated) so its borders never show when it rolls */
.hero-stage .ship { left: -4.65%; top: -8.14%; width: 109.3%; height: 116.3%; }
.hero-scrim {
  position: absolute; inset: 0;
  background:
    linear-gradient(90deg, var(--deep) 0%, rgba(10, 24, 40, 0.82) 16%, rgba(10, 24, 40, 0.2) 48%, rgba(10, 24, 40, 0) 70%),
    linear-gradient(0deg, var(--deep) 0, rgba(10, 24, 40, 0.7) 90px, rgba(10, 24, 40, 0) 300px),
    linear-gradient(180deg, rgba(6, 15, 28, 0.8) 0, rgba(6, 15, 28, 0) 180px);
}
/* the signature: the ship rocks. Only the ship layer rolls a little around the deck and heaves on a second, slower swell (two
   individual transform properties with periods that never line up, so it never repeats visibly). Transform only. */
.hero-stage .ship { transform-origin: 68% 86%; will-change: transform; }   /* the swell is driven by script.js: several waves added together, never the same twice */

.hero-grid { position: relative; z-index: 2; }
.hero-left { position: relative; max-width: 580px; }
/* a calm pool of deep water behind the words: the light nets play around the text, not through it (static gradient) */
.hero-left::before { content: ""; position: absolute; z-index: -1; inset: -50px -140px -50px -150px; pointer-events: none; background: radial-gradient(ellipse 46% 50% at 46% 50%, rgba(6, 15, 28, 0.82) 0%, rgba(6, 15, 28, 0.6) 48%, rgba(6, 15, 28, 0) 100%); }
.hero-eyebrow { margin: 0 0 18px; font: 700 0.76rem var(--font-body); letter-spacing: 0.22em; text-transform: uppercase; color: var(--gold-h1); }
.hero h1 { margin: 0 0 22px; }
.h1-pre { display: block; font: italic 600 clamp(1.4rem, 2.3vw, 1.9rem) var(--font-display); color: var(--ink-dim); margin-bottom: 2px; }
.h1-name {
  display: block; font-size: clamp(4rem, 8vw, 7rem); letter-spacing: 0.01em; line-height: 0.95;
  background: linear-gradient(180deg, #fffaf4 0%, var(--gold-pale) 45%, var(--gold-h1) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-lede { max-width: 50ch; margin: 0 0 34px; font-size: 1.08rem; line-height: 1.72; color: #d6dce8; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 30px; }
/* the worlds of the harbour: two brass plaques, each with a lantern that is lit when the world is open */
.hero .realm-servers { display: flex; flex-wrap: wrap; gap: 12px; width: auto; margin: 0 0 26px; padding: 0; background: none; border: 0; border-radius: 0; box-shadow: none; }
.hero .realm-server {
  --c: 8px;
  position: relative; isolation: isolate; padding: 11px 22px 11px 18px; gap: 10px;
  background: linear-gradient(180deg, #f6e4bb, #c99a45 50%, #6e4d1c);
  clip-path: polygon(var(--c) 0, calc(100% - var(--c)) 0, 100% var(--c), 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, var(--c) 100%, 0 calc(100% - var(--c)), 0 var(--c));
}
.hero .realm-server + .realm-server::before { content: ""; inset: 0; left: 0; top: 0; bottom: 0; width: auto; height: auto; }
.hero .realm-server::before, .hero .realm-server::after {
  content: ""; position: absolute; z-index: -1; --c: 6.5px;
  clip-path: polygon(var(--c) 0, calc(100% - var(--c)) 0, 100% var(--c), 100% calc(100% - var(--c)), calc(100% - var(--c)) 100%, var(--c) 100%, 0 calc(100% - var(--c)), 0 var(--c));
}
.hero .realm-server::before { inset: 1.5px; left: 1.5px; top: 1.5px; bottom: 1.5px; width: auto; height: auto; background: #050d18; }
.hero .realm-server::after { inset: 3.5px; background: linear-gradient(180deg, #16385c, #0b2340 55%, #08182b); box-shadow: inset 0 1px 0 rgba(238, 240, 244, 0.2); }
.hero .realm-server.is-soon { opacity: 1; filter: none; }
.hero .realm-server.is-soon::after { background: linear-gradient(180deg, #14212f, #0d1622); }
.hero .realm-server.is-soon .realm-name, .hero .realm-server.is-soon .realm-rates, .hero .realm-server.is-soon .realm-state { opacity: 0.55; }
.hero .realm-name { color: #f6ece0; }
.hero .realm-state { color: var(--gold-light); letter-spacing: 0.16em; }
.hero .realm-server .status-dot { width: 10px; height: 10px; }
.hero .status-dot.is-online { background: #ffd58a; box-shadow: 0 0 10px 2px rgba(255, 190, 90, 0.75); }   /* the lantern */

.countdown-wrap { --n: 12px; display: inline-block; padding: 20px 28px 16px; background: rgba(4, 12, 22, 0.72); }
.countdown-head { margin: 0 0 12px; font: 700 0.7rem var(--font-body); letter-spacing: 0.24em; text-transform: uppercase; color: var(--gold-h1); }
.countdown { display: flex; gap: 26px; }
.unit { display: flex; flex-direction: column; align-items: center; min-width: 60px; overflow: hidden; }
.num { font: 400 2.9rem/1 var(--font-numeral); font-variant-numeric: tabular-nums lining-nums; color: var(--ink); }
.unit-label { margin-top: 8px; font: 700 0.62rem var(--font-body); letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink-dim); }
.countdown-date { margin: 12px 0 0; font-size: 0.82rem; color: var(--ink-dim); }
.num.is-flipping { animation: num-roll 0.45s var(--ease-out); }
@keyframes num-roll { 0% { transform: translateY(-45%); opacity: 0; } 100% { transform: none; opacity: 1; } }

/* ============================================
   Shoreline strips (tools/make_foam.py): the waterline between sea and sand.
   The strip art is 2400x120; shown 1600x80, its waterline sits 27-53px down the strip.
   ============================================ */
.shore { position: absolute; left: 0; right: 0; height: 22px; z-index: 6; pointer-events: none; }
.shore-below { bottom: -11px; }
.shore-above { top: -11px; }
/* a gilded rope laid along the seam between two sections: twisted strands between two brass lines, a knot of light in the middle */
.shore {
  background:
    repeating-linear-gradient(118deg, #6e4d1c 0 3px, #e6c584 3px 6px, #b48a3c 6px 9px, #6e4d1c 9px 11px) center / 100% 12px no-repeat,
    linear-gradient(180deg, #f6e4bb, #8e6a2c) top / 100% 2px no-repeat,
    linear-gradient(180deg, #8e6a2c, #f6e4bb) bottom / 100% 2px no-repeat;
  filter: drop-shadow(0 6px 8px rgba(0, 0, 0, 0.35));
}
.shore::after { content: ""; position: absolute; left: 50%; top: 50%; width: 26px; height: 26px; margin: -13px 0 0 -13px; transform: rotate(45deg); background: linear-gradient(135deg, #f6e4bb, #b48a3c 55%, #6e4d1c); box-shadow: inset 0 0 0 3px #0a1828, 0 0 0 2px #c79a4a; }

/* ============================================
   Sand sections
   ============================================ */
.sand { position: relative; z-index: 3; background: var(--sand) url("assets/sand.jpg") 0 0 / 512px 512px repeat; color: var(--sand-ink); }   /* wind-rippled sand: a seamless grain (tools/make_sand.py) */
.sand .eyebrow { color: var(--gold-text); }
.sand .section-head p { color: var(--sand-ink-dim); }
.sand .text-link { color: var(--gold-text); }
.sand .btn-ghost-sm, .sand .btn-ghost-lg { color: var(--sand-ink); text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5); background: linear-gradient(180deg, #a68240, #5b431a); }
.sand .btn-ghost-sm::before, .sand .btn-ghost-lg::before { background: #efe7d8; }
.sand .btn-ghost-sm::after, .sand .btn-ghost-lg::after { background-image: linear-gradient(180deg, #fbf6ec, #eadfca 60%, #dccfb6); box-shadow: inset 0 1px 0 #fff; }

/* ---- features: one big scene, tabs choose what is on stage ---- */
.features { padding: 120px 0 70px; }
.scene { display: grid; grid-template-columns: 320px minmax(0, 1fr); gap: 30px; align-items: stretch; }
.scene-tabs { display: flex; flex-direction: column; gap: 10px; }
.scene-tab {
  --n: 8px;
  flex: 1 1 0;   /* the four tabs share the height of the picture, so the column never ends early */
  display: flex; align-items: center; gap: 16px; width: 100%; padding: 20px 22px; text-align: left;
  font: inherit; color: var(--sand-ink); background: rgba(28, 43, 45, 0.045); border: none; cursor: pointer;
  transition: background-color 0.25s ease, color 0.25s ease;
}
.scene-num { font: 400 1.15rem var(--font-numeral); color: var(--gold-text); }
.scene-title { font: 700 1.45rem/1.15 var(--font-display); }
.scene-tab.is-active { background: var(--deep); color: var(--ink); }
.scene-tab.is-active .scene-num { color: var(--gold-h1); }
@media (hover: hover) and (pointer: fine) { .scene-tab:not(.is-active):hover { background: rgba(28, 43, 45, 0.09); } }
.scene-stage { --n: 14px; position: relative; min-height: 470px; background: var(--deep); overflow: hidden; }
.scene-panel { position: absolute; inset: 0; }
.scene-panel[hidden] { display: none; }
.scene-art { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.scene-panel:not([hidden]) .scene-art { animation: scene-in 0.9s var(--ease-out); }
@keyframes scene-in { 0% { opacity: 0; transform: scale(1.04); } 100% { opacity: 1; transform: none; } }
.scene-caption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 110px 36px 30px; color: var(--ink);
  background: linear-gradient(0deg, rgba(6, 15, 28, 0.94) 0, rgba(6, 15, 28, 0.7) 55%, rgba(6, 15, 28, 0));
}
.scene-caption .scene-num { color: var(--gold-h1); }
.scene-caption h3 { font-size: 2rem; margin: 4px 0 8px; }
.scene-caption p { margin: 0; max-width: 56ch; color: #d6dce8; }
.scene-panel:not([hidden]) .scene-caption { animation: caption-in 0.7s var(--ease-out) 0.12s both; }
@keyframes caption-in { 0% { opacity: 0; transform: translateY(14px); } 100% { opacity: 1; transform: none; } }

/* ---- news: the ship's log ---- */
.news { padding: 70px 0 150px; }
.news-grid { display: grid; grid-template-columns: 330px minmax(0, 1fr); gap: 64px; align-items: start; }
.news-head { position: sticky; top: 120px; margin: 0; }
/* under the heading: how the harbour stands today (the same data as the hero), so the column is never just empty sand */
.harbour-now { --n: 10px; margin-top: 34px; padding: 18px 22px 20px; background: var(--deep); color: var(--ink); }
.harbour-now .war-label { display: block; font: 700 0.66rem var(--font-body); letter-spacing: 0.22em; text-transform: uppercase; color: var(--gold-h1); }
.harbour-now strong { display: block; margin: 4px 0 12px; font: 700 1.35rem/1.2 var(--font-display); }
.harbour-now .realm-servers { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.harbour-now .realm-server { display: flex; align-items: center; gap: 10px; font-size: 0.86rem; color: var(--ink-dim); }
.harbour-now .realm-name { font-weight: 700; color: var(--ink); }
.harbour-now .realm-rates { color: var(--gold-h1); font-weight: 700; }
.log { list-style: none; margin: 0; padding: 0 0 0 34px; position: relative; }
.log::before { content: ""; position: absolute; left: 6px; top: 10px; bottom: 10px; width: 1px; background: repeating-linear-gradient(180deg, var(--sand-ink) 0 4px, transparent 4px 10px); opacity: 0.35; }
.log-entry { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 220px; gap: 10px 28px; padding: 0 0 40px; }
.log-entry + .log-entry { padding-top: 40px; border-top: 1px solid var(--sand-line); }
.log-entry::before { content: ""; position: absolute; left: -33px; top: 6px; width: 11px; height: 11px; background: var(--gold); transform: rotate(45deg); box-shadow: 0 0 0 4px var(--sand); }
.log-entry + .log-entry::before { top: 46px; }
.log-date { grid-column: 1; font: 400 0.95rem var(--font-numeral); color: var(--gold-text); letter-spacing: 0.02em; }
.log-body { grid-column: 1; }
.log-body h3 { font-size: 1.9rem; margin: 2px 0 8px; }
.log-body h3 a { transition: color 0.2s ease; }
@media (hover: hover) and (pointer: fine) { .log-body h3 a:hover { color: var(--gold-text); } }
.log-body p { color: var(--sand-ink-dim); margin-bottom: 14px; }
.log-thumb { --n: 10px; grid-column: 2; grid-row: 1 / span 2; align-self: start; aspect-ratio: 4 / 3; overflow: hidden; background: var(--deep); }
.log-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .log-entry:hover .log-thumb img { transform: scale(1.05); } }

/* ============================================
   The voyage (roadmap). Wide screens: the section is tall, its view is pinned, the chart slides sideways
   and the ship sails the route (script.js sets the transforms). Otherwise: a plain list over the chart.
   ============================================ */
.voyage { position: relative; background: var(--deep); z-index: 5; }
.voyage-pin { position: relative; padding: 110px 0 80px; }
.voyage-head { margin-bottom: 30px; position: relative; z-index: 2; }
.voyage-view { position: relative; }
.voyage-track { position: relative; }
.voyage-chart { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0.55; }
.voyage-route, .route-wake, .rose, .ship { display: none; }
.ports { list-style: none; margin: 0; padding: 0 28px; position: relative; display: grid; gap: 22px; max-width: 720px; margin-left: auto; margin-right: auto; }
.port { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 18px; align-items: start; }
.port-marker {
  position: relative; display: flex; align-items: center; justify-content: center; width: 64px; height: 64px; border-radius: 50%;
  color: var(--ink-dim); background: radial-gradient(circle at 40% 32%, #1d3f66, #081b30 72%);
  box-shadow: inset 0 0 0 1.5px rgba(238, 240, 244, 0.28), 0 0 0 6px rgba(10, 24, 40, 0.85);
  transition: color 0.5s ease, box-shadow 0.5s ease, background 0.5s ease;
}
.port-marker::after { content: ""; position: absolute; inset: -10px; border-radius: 50%; border: 1px solid rgba(238, 240, 244, 0.14); transition: border-color 0.5s ease, transform 0.5s var(--ease-out); }
.port-marker svg { width: 30px; height: 30px; }
.port-card { --n: 10px; padding: 22px 26px 24px; background: linear-gradient(180deg, rgba(16, 38, 63, 0.95), rgba(6, 15, 28, 0.95)); box-shadow: inset 0 1px 0 rgba(238, 240, 244, 0.12); transition: opacity 0.5s ease, transform 0.6s var(--ease-out); }
.port-num { font: 700 0.7rem var(--font-body); letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold-h1); }
.port-card h3 { font-size: 1.7rem; margin: 4px 0 6px; }
.port-card p { margin: 0; color: var(--ink-dim); font-size: 0.95rem; }
.port.is-lit .port-marker { color: #2a1a05; background: radial-gradient(circle at 40% 32%, var(--gold-shine), var(--gold) 55%, var(--gold-deep)); box-shadow: inset 0 0 0 1.5px rgba(255, 240, 230, 0.7), 0 0 0 6px rgba(10, 24, 40, 0.85), 0 0 26px rgba(var(--gold-rgb), 0.55); animation: port-ignite 0.6s var(--ease-out); }
.port.is-lit .port-marker::after { border-color: rgba(var(--gold-h1-rgb), 0.5); transform: scale(1.12); }
@keyframes port-ignite { 45% { transform: scale(1.12); } }

/* the pinned voyage, wide screens with motion allowed (script.js adds .is-sailing) */
.voyage.is-sailing { height: var(--voyage-h, 320vh); }
.voyage.is-sailing .voyage-pin { position: sticky; top: 0; height: 100vh; padding: 96px 0 0; display: flex; flex-direction: column; overflow: hidden; }
.voyage.is-sailing .voyage-head { margin-bottom: 18px; }
.voyage.is-sailing .voyage-head h2 { font-size: clamp(2.1rem, 3.6vw, 3rem); margin: 6px 0 6px; }
.voyage.is-sailing .voyage-head p { margin: 0; }
.voyage.is-sailing .voyage-view { flex: 1; overflow: hidden; }
.voyage.is-sailing .voyage-view::after { content: ""; position: absolute; inset: 0; z-index: 3; pointer-events: none; background: linear-gradient(180deg, var(--deep) 0, rgba(10, 24, 40, 0) 70px, rgba(10, 24, 40, 0) calc(100% - 90px), var(--deep) 100%); }
.voyage.is-sailing .voyage-track { position: absolute; top: 0; left: 0; height: 100%; will-change: transform; }
.voyage.is-sailing .voyage-chart { opacity: 1; object-fit: fill; }
.voyage.is-sailing .voyage-route, .voyage.is-sailing .route-wake, .voyage.is-sailing .rose, .voyage.is-sailing .ship { display: block; }
.voyage-route, .route-wake { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.route-line { fill: none; stroke: rgba(238, 240, 244, 0.4); stroke-width: 2; stroke-dasharray: 2 9; stroke-linecap: round; vector-effect: non-scaling-stroke; }
/* the part of the route already sailed: revealed by two opposite transforms (clip without animating a clip) */
.route-wake { overflow: hidden; transform: translateX(calc(var(--wake, 0px) - 100%)); }
.route-wake svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: translateX(calc(100% - var(--wake, 0px))); }
.route-done { fill: none; stroke: var(--gold-h1); stroke-width: 2.5; stroke-dasharray: 10 8; vector-effect: non-scaling-stroke; }
.rose { position: absolute; width: 150px; height: 150px; color: #e6e8ee; opacity: 0.4; transform: translate(-50%, -50%); }
.rose-a { left: 24%; top: 20%; }
.rose-b { left: 76%; top: 82%; width: 120px; height: 120px; }
.voyage.is-sailing .ports { position: absolute; inset: 0; display: block; max-width: none; padding: 0; }
.voyage.is-sailing .port { position: absolute; left: 0; top: 0; display: block; width: 0; height: 0; }
.voyage.is-sailing .port-marker { position: absolute; left: -32px; top: -32px; }
/* every card stays readable on the chart: a solid plate. The port the ship has reached gets the coral edge and full light;
   the ports still ahead are a step calmer, never faded into the map. */
.voyage.is-sailing .port-card { position: absolute; left: -150px; width: 300px; top: 52px; opacity: 0.86; transform: translateY(8px); background: linear-gradient(180deg, #10263f, #081a2e); box-shadow: inset 0 1px 0 rgba(238, 240, 244, 0.12), 0 14px 30px rgba(0, 0, 0, 0.35); }
.voyage.is-sailing .port-up .port-card { top: auto; bottom: 52px; transform: translateY(-8px); }
.voyage.is-sailing .port.is-lit .port-card { opacity: 1; transform: none; box-shadow: inset 0 2px 0 var(--gold), inset 0 1px 0 rgba(238, 240, 244, 0.12), 0 14px 30px rgba(0, 0, 0, 0.35); }
.voyage .port-card p { color: #cfd8e6; }
.ship { position: absolute; left: 0; top: 0; width: 46px; height: 46px; margin: -38px 0 0 -23px; color: #fffaf4; filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.5)); will-change: transform; }
.ship svg { width: 100%; height: 100%; }

/* ============================================
   Water sections: rankings and footer. The same light, faint, over the whole section (seamless tiles).
   ============================================ */
.water { color: var(--ink); }
.deep { position: relative; background: linear-gradient(180deg, var(--deep) 0, var(--abyss) 260px); padding: 120px 0 130px; overflow: hidden; }
.deep > .wrap, .site-footer > .wrap { position: relative; z-index: 1; }

/* ---- rankings: the community first, then the boards ---- */
.haven { --n: 14px; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); background: var(--tide); margin-bottom: 26px; min-height: 360px; }
.haven-media { position: relative; overflow: hidden; }
.haven-media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.haven-media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(16, 38, 63, 0) 55%, var(--tide)); }
.haven-body { padding: 40px 44px 40px 30px; }
.haven-body h3 { font-size: 2.3rem; }
.haven-sub { display: block; margin: 6px 0 16px; font: 700 0.72rem var(--font-body); letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold-h1); }
.haven-body p { color: #d6dce8; }
.haven-body strong { color: var(--gold-light); }
.haven-perks { list-style: none; margin: 0 0 26px; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 8px 22px; }
.haven-perks li { position: relative; padding-left: 18px; font-size: 0.92rem; color: var(--ink-dim); }
.haven-perks li::before { content: ""; position: absolute; left: 1px; top: 0.62em; width: 6px; height: 6px; background: var(--gold); transform: rotate(45deg); }

.board { --n: 14px; background: rgba(16, 38, 63, 0.55); padding: 8px 28px 26px; }
.board-tabs { margin: 0 -8px 18px; gap: 6px; border-bottom-color: var(--panel-line); }
.board .tab { --n: 6px; padding: 16px 20px; font: 700 0.84rem var(--font-body); letter-spacing: 0.08em; text-transform: uppercase; }
.rank-col-head { display: flex; justify-content: space-between; padding: 0 6px 10px; font: 700 0.66rem var(--font-body); letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-dim); border-bottom: 1px solid var(--panel-line); }
.rank-list, .castle-list { list-style: none; margin: 0; padding: 0; columns: 2; column-gap: 40px; }
.rank-row, .castle-row { break-inside: avoid; display: grid; align-items: center; gap: 14px; min-height: 58px; padding: 8px 6px; border-bottom: 1px solid rgba(238, 240, 244, 0.07); }
.rank-row { grid-template-columns: 30px 42px minmax(0, 1fr) auto; }
.rank-row:not(:has(.rank-avatar)) { grid-template-columns: 30px minmax(0, 1fr) auto; }
.castle-row { grid-template-columns: 34px minmax(0, 1fr) auto; }
.rank-medal { display: flex; align-items: center; justify-content: center; width: 28px; height: 28px; border-radius: 50%; font: 400 0.95rem var(--font-numeral); color: var(--ink-dim); box-shadow: inset 0 0 0 1px rgba(238, 240, 244, 0.2); }
.rank-gold .rank-medal { color: #2a1a05; background: linear-gradient(180deg, var(--gold-shine), var(--gold)); box-shadow: 0 0 12px rgba(var(--gold-rgb), 0.5); }
.rank-silver .rank-medal { color: #1b2130; background: linear-gradient(180deg, #f3f6f5, #b7c4c3); box-shadow: none; }
.rank-bronze .rank-medal { color: #2a160c; background: linear-gradient(180deg, #e2b18f, #a4674a); box-shadow: none; }
.rank-avatar { position: relative; display: flex; align-items: center; justify-content: center; width: 42px; height: 42px; border-radius: 50%; overflow: hidden; background: radial-gradient(circle at 40% 30%, #24507e, #081b30); box-shadow: 0 0 0 1.5px rgba(var(--gold-h1-rgb), 0.55), 0 0 0 3px var(--abyss), 0 0 0 4px rgba(238, 240, 244, 0.14); }
.rank-avatar::before { content: attr(data-initial); font: 700 1.05rem var(--font-display); color: var(--gold-h1); }
.rank-avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.rank-who { display: flex; flex-direction: column; min-width: 0; }
.rank-name { font: 700 1.25rem/1.1 var(--font-display); color: var(--ink); }
.rank-clan { font-size: 0.8rem; color: var(--ink-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rank-score { font: 400 1.15rem var(--font-numeral); color: var(--gold-h1); }
.castle-seal { display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 50%; color: var(--gold-h1); box-shadow: inset 0 0 0 1px rgba(var(--gold-h1-rgb), 0.45); }
.castle-seal svg { width: 16px; height: 16px; }
.castle-name { font: 700 1.2rem var(--font-display); }
.castle-owner { font-size: 0.86rem; font-weight: 700; color: var(--gold-h1); }
.castle-owner.is-free { color: var(--ink-dim); font-weight: 500; }

/* ============================================
   Footer: the deepest water
   ============================================ */
.site-footer { position: relative; padding: 90px 0 0; background: linear-gradient(180deg, var(--abyss) 0, #040b16 220px); color: var(--ink-dim); overflow: hidden; }
.footer-cta { --n: 14px; display: flex; align-items: center; justify-content: space-between; gap: 30px; flex-wrap: wrap; padding: 36px 42px; background: linear-gradient(110deg, rgba(var(--gold-deep-rgb), 0.24), rgba(16, 38, 63, 0.7) 60%); }
.footer-cta h2 { color: var(--ink); font-size: clamp(1.9rem, 3vw, 2.5rem); margin: 8px 0; }
.footer-cta p { margin: 0; max-width: 52ch; color: #d6dce8; }
.footer-cta-actions { display: flex; gap: 14px; flex-wrap: wrap; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 0.8fr 1fr 1fr 1.2fr; gap: 40px; padding: 64px 0 50px; }
.footer-logo { width: 210px; height: auto; margin-bottom: 16px; }
.footer-brand p { font-size: 0.92rem; max-width: 34ch; }
.footer-socials { display: flex; gap: 10px; margin-top: 18px; }
.social { --n: 6px; display: flex; align-items: center; justify-content: center; width: 42px; height: 42px; color: var(--ink); background: rgba(238, 240, 244, 0.07); transition: background-color 0.2s ease, color 0.2s ease; }
.social svg { width: 19px; height: 19px; }
@media (hover: hover) and (pointer: fine) { .social:hover { background: var(--gold); color: #2a1a05; } }
.footer-col h3 { font: 700 0.74rem var(--font-body); letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold-h1); margin-bottom: 16px; }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer-col a { font-size: 0.93rem; color: var(--ink-dim); transition: color 0.15s ease; }
@media (hover: hover) and (pointer: fine) { .footer-col a:hover { color: var(--ink); } }
.footer-status dl { margin: 0; display: grid; gap: 10px; }
.footer-status dl > div { display: flex; justify-content: space-between; gap: 14px; font-size: 0.9rem; }
.footer-status dt { color: var(--ink-dim); }
.footer-status dd { margin: 0; display: flex; align-items: center; gap: 8px; color: var(--ink); font-weight: 600; }
.footer-bottom { border-top: 1px solid var(--panel-line); }

/* ============================================
   Scroll reveal and the hero entrance (script.js)
   ============================================ */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.8s ease, transform 0.8s var(--ease-out); transition-delay: var(--reveal-delay, 0ms); }
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 1100px) {
  .scene { grid-template-columns: 1fr; }
  .scene-tabs { flex-direction: row; overflow-x: auto; scrollbar-width: none; gap: 8px; }
  .scene-tabs::-webkit-scrollbar { display: none; }
  .scene-tab { flex: 0 0 auto; width: auto; padding: 14px 18px; }
  .scene-title { font-size: 1.15rem; white-space: nowrap; }
  .news-grid { grid-template-columns: 1fr; gap: 20px; }
  .news-head { position: static; }
  .footer-grid { grid-template-columns: 1fr 1fr 1fr; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 980px) { .header-right { margin-left: auto; } }
@media (max-width: 900px) {
  .hero { min-height: 0; padding: 120px 0 150px; }
  .hero-media { width: 100%; opacity: 0.55; }
  .hero-scrim { background: linear-gradient(180deg, rgba(10, 24, 40, 0.55), var(--deep)); }
  .haven { grid-template-columns: 1fr; }
  .haven-media { height: 240px; }
  .haven-media::after { background: linear-gradient(180deg, rgba(16, 38, 63, 0) 50%, var(--tide)); }
  .haven-body { padding: 26px 26px 30px; }
  .rank-list, .castle-list { columns: 1; }
  .log-entry { grid-template-columns: 1fr; }
  .log-thumb { grid-column: 1; grid-row: auto; aspect-ratio: 16 / 9; max-width: 420px; }
}
@media (max-width: 640px) {
  .wrap { padding: 0 20px; }
  .header-inner { height: 66px; }
  .brand-logo { height: 42px; }
  .hero { padding: 100px 0 130px; }
  .h1-name { font-size: 3.4rem; }
  .countdown-wrap { display: block; padding: 16px 14px; }
  .countdown { gap: 8px; justify-content: space-between; }
  .num { font-size: 2rem; }
  .unit { min-width: 0; }
  .scene-stage { min-height: 420px; }
  .scene-caption { padding: 90px 22px 22px; }
  .scene-caption h3 { font-size: 1.6rem; }
  .log { padding-left: 26px; }
  .log-entry::before { left: -25px; }
  .log-body h3 { font-size: 1.55rem; }
  .haven-perks { grid-template-columns: 1fr; }
  .board { padding: 6px 14px 20px; }
  .board .tab { padding: 14px 12px; font-size: 0.74rem; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px 20px; }
  .footer-status { grid-column: 1 / -1; }
  .footer-cta { padding: 28px 22px; }
}

/* ============================================
   Lineage II window frames: a hairline of brass, a dark gap, a second hairline. On panels that carry no picture at their edge.
   ============================================ */
.board, .footer-cta, .port-card, .countdown-wrap, .harbour-now {
  box-shadow: inset 0 0 0 1px rgba(220, 180, 102, 0.55), inset 0 0 0 4px rgba(4, 12, 22, 0.55), inset 0 0 0 5px rgba(220, 180, 102, 0.28);
}
.voyage.is-sailing .port-card { box-shadow: inset 0 0 0 1px rgba(220, 180, 102, 0.55), inset 0 0 0 4px rgba(4, 12, 22, 0.55), inset 0 0 0 5px rgba(220, 180, 102, 0.28), 0 14px 30px rgba(0, 0, 0, 0.35); }
.voyage.is-sailing .port.is-lit .port-card { box-shadow: inset 0 0 0 1px rgba(246, 228, 187, 0.9), inset 0 0 0 4px rgba(4, 12, 22, 0.55), inset 0 0 0 5px rgba(220, 180, 102, 0.5), 0 0 26px rgba(var(--gold-rgb), 0.28), 0 14px 30px rgba(0, 0, 0, 0.35); }
/* section headings end in a small flourish: line, diamond, line */
.section-head h2::after { content: "◆";  display: block; width: 190px; margin-top: 14px; text-align: center; font: 400 11px/12px var(--font-body); color: var(--gold-h1); background:
  linear-gradient(var(--gold-h1), var(--gold-h1)) left center / 80px 1px no-repeat,
  linear-gradient(var(--gold-h1), var(--gold-h1)) right center / 80px 1px no-repeat; }
.sand .section-head h2::after { --gold-h1: #b3573e; }
