/* Helmyard (cpmarina.net) v1.0.0: own design system (SPEC 5). Night harbour + chart paper; Geologica + Chakra Petch. */
@font-face { font-family: "Geologica"; src: url("fonts/geologica-latin-300-800.woff2") format("woff2"); font-weight: 300 800; font-display: swap; }
@font-face { font-family: "Chakra Petch"; src: url("fonts/chakrapetch-latin-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Chakra Petch"; src: url("fonts/chakrapetch-latin-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }

:root {
  --night: #0d2226;
  --night-2: #12343a;
  --night-3: #1b4a50;
  --water: #0f3a40;
  --paper: #f2eee3;
  --paper-2: #e8e2d1;
  --ink: #142326;
  --ink-2: #3c5054;
  --mute: #6b7c7f;
  --line: #cfc6b0;
  --signal: #ffc93c;
  --signal-ink: #2a2000;
  --red: #e2483a;
  --green: #2f9e6b;
  --wood: #d9cba8;
  --white: #fffdf7;
  --r: 14px;
  --r-s: 8px;
  --shadow: 0 1px 0 rgba(13, 34, 38, .06), 0 14px 34px -18px rgba(13, 34, 38, .45);
  --display: "Geologica", system-ui, -apple-system, "Segoe UI", sans-serif;
  --hud: "Chakra Petch", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --w: 1180px;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 17px/1.6 var(--display); font-optical-sizing: auto; }
img, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--red); }
:focus-visible { outline: 3px solid var(--signal); outline-offset: 2px; border-radius: 4px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--signal); color: var(--signal-ink); padding: 8px 14px; border-radius: 8px; z-index: 50; }
.skip:focus { left: 12px; }
.wrap { width: min(var(--w), 100% - 32px); margin-inline: auto; }
.narrow { width: min(760px, 100% - 32px); margin-inline: auto; }
h1, h2, h3 { font-family: var(--display); line-height: 1.12; letter-spacing: -.015em; margin: 0 0 .5em; }
h1 { font-weight: 750; font-size: clamp(2.2rem, 5.2vw, 4.1rem); letter-spacing: -.03em; }
h2 { font-weight: 700; font-size: clamp(1.6rem, 3.2vw, 2.45rem); }
h3 { font-weight: 650; font-size: 1.18rem; letter-spacing: -.005em; }
p { margin: 0 0 1em; }
.lede { font-size: clamp(1.06rem, 1.6vw, 1.24rem); color: var(--ink-2); max-width: 40em; }
.kicker { font: 600 .78rem/1 var(--hud); letter-spacing: .16em; text-transform: uppercase; color: var(--red); margin: 0 0 14px; display: inline-flex; gap: 10px; align-items: center; }
.kicker::before { content: ""; width: 22px; height: 2px; background: currentColor; }
.num { font-family: var(--hud); font-variant-numeric: tabular-nums; }
.small { font-size: .9rem; color: var(--ink-2); }

/* ---- buttons ---- */
.btn { --b: var(--signal); display: inline-flex; align-items: center; gap: 10px; min-height: 48px; padding: 0 22px; border-radius: 999px; border: 2px solid var(--b);
  background: var(--b); color: var(--signal-ink); font: 650 1rem/1 var(--display); text-decoration: none; cursor: pointer; transition: transform .15s ease, box-shadow .15s ease; }
.btn:hover { transform: translateY(-1px); box-shadow: 0 10px 22px -12px rgba(0, 0, 0, .55); text-decoration: none; }
.btn .arr { font-family: var(--hud); }
.btn--line { background: transparent; color: inherit; border-color: currentColor; }
.btn--ink { --b: var(--ink); color: var(--white); }
.btn--small { min-height: 38px; padding: 0 14px; font-size: .92rem; }
.btns { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
button.linkish { background: none; border: 0; padding: 0; font: inherit; color: inherit; text-decoration: underline; cursor: pointer; }

/* ---- top bar ---- */
.top { background: var(--night); color: var(--paper); position: relative; z-index: 5; }
.top__in { display: flex; align-items: center; gap: 28px; min-height: 68px; }
.mark { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--white); font: 750 1.28rem/1 var(--display); letter-spacing: -.02em; }
.mark svg { width: 30px; height: 30px; }
.mark small { font: 500 .66rem/1 var(--hud); letter-spacing: .14em; color: #9fb7b9; text-transform: uppercase; margin-left: 2px; }
.nav { display: flex; gap: 6px; margin-left: auto; align-items: center; }
.nav a { position: relative; padding: 10px 12px; color: #d6dfdc; text-decoration: none; font-weight: 500; font-size: .97rem; border-radius: 8px; }
.nav a:hover { color: var(--white); background: rgba(255, 255, 255, .06); }
.nav a[aria-current="page"] { color: var(--white); }
.nav a[aria-current="page"]::after { content: ""; position: absolute; left: 50%; bottom: 2px; width: 22px; height: 5px; margin-left: -11px; border-radius: 4px; background: var(--signal); box-shadow: 9px 0 0 -1px var(--signal); }
.nav .btn { margin-left: 8px; }
.menu-btn { display: none; }

/* preview ribbon (own: a night tide-gauge strip with graduation ticks along its foot, not a coloured bar) */
.tide { background: repeating-linear-gradient(90deg, rgba(255, 201, 60, .75) 0 2px, transparent 2px 12px) left bottom / 100% 5px no-repeat, var(--night-2); color: #d6dfdc; font-size: .88rem; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06); }
.tide__in { display: flex; gap: 8px 16px; align-items: center; justify-content: flex-start; min-height: 40px; text-align: left; flex-wrap: wrap; padding: 8px 0 13px; }
.tide b { font: 600 .72rem/1 var(--hud); letter-spacing: .16em; background: var(--signal); color: var(--signal-ink); padding: 5px 7px 4px; border-radius: 4px; }
.tide a { font-weight: 650; color: var(--signal); margin-left: auto; }
@media (max-width: 720px) { .tide a { margin-left: 0; } }

/* ---- hero ---- */
.hero { background: radial-gradient(1200px 520px at 78% 30%, #1b4a50 0%, transparent 60%), var(--night); color: var(--paper); overflow: hidden; }
.hero__in { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 48px; align-items: center; padding: 64px 0 40px; }
.hero h1 { color: var(--white); }
.hero h1 em { font-style: normal; color: var(--signal); }
.hero .lede { color: #c9d6d3; }
.hero .btn--line { color: var(--paper); }
.scope { position: relative; border-radius: 22px; padding: 10px; background: linear-gradient(160deg, #24575d, #0a1c1f); box-shadow: 0 40px 80px -40px #000, inset 0 0 0 1px rgba(255, 255, 255, .08); }
.scope canvas { width: 100%; height: auto; border-radius: 14px; background: var(--water); }
.scope__tag { position: absolute; left: 22px; top: 20px; font: 600 .72rem/1 var(--hud); letter-spacing: .14em; text-transform: uppercase; color: var(--signal);
  background: rgba(13, 34, 38, .75); padding: 7px 10px; border-radius: 6px; }
.scope__cap { margin: 10px 6px 2px; font-size: .85rem; color: #9fb7b9; }
.specs { border-top: 1px solid rgba(255, 255, 255, .1); }
.specs__in { display: grid; grid-template-columns: repeat(4, 1fr); }
.spec { padding: 22px 18px 26px; border-left: 1px solid rgba(255, 255, 255, .1); }
.spec:first-child { border-left: 0; padding-left: 0; }
.spec b { display: block; font: 600 clamp(2rem, 4vw, 3rem)/1 var(--hud); color: var(--signal); letter-spacing: -.01em; }
.spec span { color: #b8c8c5; font-size: .95rem; }

/* ---- sections ---- */
.band { padding: clamp(56px, 8vw, 104px) 0; }
.band--chart { background-color: var(--paper); background-image: linear-gradient(rgba(20, 35, 38, .045) 1px, transparent 1px), linear-gradient(90deg, rgba(20, 35, 38, .045) 1px, transparent 1px); background-size: 48px 48px; }
.band--night { background: var(--night); color: var(--paper); }
.band--night .lede, .band--night .small { color: #b8c8c5; }
.band--sand { background: var(--paper-2); }
.head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px; align-items: end; margin-bottom: 40px; }
.head p { margin: 0; }

/* forces: three drawn diagrams */
.forces { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.force { background: var(--white); border-radius: var(--r); padding: 22px 22px 24px; box-shadow: var(--shadow); border-top: 5px solid var(--night); }
.force svg { width: 100%; height: auto; margin: -4px 0 14px; }
.force:nth-child(2) { border-top-color: var(--red); }
.force:nth-child(3) { border-top-color: var(--green); }
.force p { color: var(--ink-2); margin: 0; }

/* the route: drills on a buoyed channel */
.route { list-style: none; margin: 0; padding: 0; position: relative; display: grid; grid-template-columns: 1fr 1fr; column-gap: 72px; }
.route::before { content: ""; position: absolute; left: 50%; top: 10px; bottom: 10px; width: 0; border-left: 2px dashed rgba(242, 238, 227, .28); }
.leg { position: relative; display: grid; grid-template-columns: 54px minmax(0, 1fr); gap: 16px; padding: 18px 0; }
.leg:nth-child(odd) { grid-column: 1; }
.leg:nth-child(even) { grid-column: 2; transform: translateY(54px); }
.buoy { width: 46px; height: 46px; display: grid; place-items: center; font: 600 1.05rem/1 var(--hud); color: var(--white); }
.buoy--g { background: var(--green); border-radius: 6px; }
.buoy--r { background: var(--red); clip-path: polygon(50% 0, 100% 100%, 0 100%); padding-top: 14px; }
.leg h3 { margin: 2px 0 4px; color: var(--white); }
.leg h3 a { text-decoration: none; }
.leg h3 a:hover { text-decoration: underline; text-decoration-color: var(--signal); }
.leg p { margin: 0 0 6px; color: #b8c8c5; font-size: .96rem; }
.tag { display: inline-flex; align-items: center; gap: 6px; font: 600 .7rem/1 var(--hud); letter-spacing: .12em; text-transform: uppercase; padding: 5px 8px; border-radius: 5px; }
.tag--free { background: rgba(47, 158, 107, .18); color: #7fe0b2; }
.tag--pass { background: rgba(255, 201, 60, .16); color: var(--signal); }
.tag--par { background: rgba(255, 255, 255, .07); color: #cfdcd9; }
.on-paper .tag--free { background: #d9efe2; color: #1d6a46; }
.on-paper .tag--pass { background: #fbe9b5; color: #6b4c00; }
.on-paper .tag--par { background: var(--paper-2); color: var(--ink-2); }

/* scorecard: a ticket */
.ticket { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); background: var(--white); border-radius: 18px; box-shadow: var(--shadow); overflow: hidden; }
.ticket__l { padding: 30px 32px; }
.ticket__r { background: var(--night); color: var(--paper); padding: 30px 32px; position: relative; }
.ticket__r .small { color: #b8c8c5; }
.ticket__r::before { content: ""; position: absolute; left: -9px; top: 0; bottom: 0; width: 18px; background: radial-gradient(circle at 9px 12px, var(--white) 6px, transparent 6.5px) 0 0 / 18px 24px repeat-y; }
.lines { list-style: none; margin: 0 0 14px; padding: 0; }
.lines li { display: flex; justify-content: space-between; gap: 16px; padding: 9px 0; border-bottom: 1px dashed rgba(242, 238, 227, .18); }
.lines li b { font-family: var(--hud); font-weight: 600; }
.big { font: 600 clamp(3.4rem, 8vw, 5.6rem)/1 var(--hud); color: var(--signal); letter-spacing: -.02em; }
.facts { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0; margin: 14px 0 0; }
.facts div { padding: 12px 0; border-top: 1px solid var(--line); }
.facts dt { font-size: .82rem; color: var(--mute); text-transform: uppercase; letter-spacing: .08em; }
.facts dd { margin: 2px 0 0; font: 600 1.35rem/1.2 var(--hud); }

/* boats */
.boats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.boat { background: var(--white); border-radius: var(--r); padding: 18px; box-shadow: var(--shadow); }
.boat svg { height: 92px; width: auto; margin: 0 auto 10px; }
.boat h3 { margin: 0 0 4px; font-size: 1.02rem; }
.boat p { margin: 0; font-size: .92rem; color: var(--ink-2); }

/* pricing */
.plans { display: grid; grid-template-columns: 1fr 1.15fr; gap: 22px; align-items: stretch; }
.plan { border-radius: 20px; padding: 32px; background: var(--white); box-shadow: var(--shadow); display: flex; flex-direction: column; }
.plan--pass { background: var(--night); color: var(--paper); position: relative; }
.plan--pass::after { content: "PREVIEW"; position: absolute; right: 22px; top: 22px; font: 600 .7rem/1 var(--hud); letter-spacing: .16em; color: var(--signal-ink); background: var(--signal); padding: 6px 8px; border-radius: 5px; }
.plan h3 { font-size: 1.35rem; }
.price { font: 600 3.2rem/1 var(--hud); letter-spacing: -.02em; margin: 6px 0 4px; }
.price small { font: 500 1rem/1 var(--display); color: inherit; opacity: .75; letter-spacing: 0; }
.plan--pass .price { color: var(--signal); }
.alt { font-size: .95rem; opacity: .85; margin: 0 0 18px; }
.ticks { list-style: none; padding: 0; margin: 0 0 22px; }
.ticks li { padding: 7px 0 7px 28px; position: relative; border-top: 1px solid rgba(127, 127, 127, .18); }
.ticks li::before { content: ""; position: absolute; left: 2px; top: 15px; width: 12px; height: 7px; border-left: 2.5px solid var(--green); border-bottom: 2.5px solid var(--green); transform: rotate(-45deg); }
.plan--pass .ticks li::before { border-color: var(--signal); }
.plan .btns { margin-top: auto; }
.preview-note { border: 2px dashed currentColor; border-radius: 12px; padding: 12px 14px; font-size: .94rem; opacity: .95; }
.pricebar { display: flex; flex-wrap: wrap; gap: 8px 18px; align-items: center; background: var(--white); border-left: 6px solid var(--signal); border-radius: 10px; padding: 12px 16px; box-shadow: var(--shadow); font-size: .96rem; }

/* honesty */
.honest { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 22px; align-items: start; background: var(--white); border-radius: 18px; padding: 26px 28px; box-shadow: var(--shadow); }
.honest svg { width: 56px; height: 56px; }
.honest p { margin: 0 0 .5em; }

/* ---- yard index ---- */
.pagehead { background: var(--night); color: var(--paper); padding: 52px 0 46px; }
.pagehead h1 { color: var(--white); font-size: clamp(2rem, 4.4vw, 3.2rem); }
.pagehead .lede { color: #c2d0cd; }
.drills { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.drill { display: flex; flex-direction: column; background: var(--white); border-radius: var(--r); box-shadow: var(--shadow); overflow: hidden; text-decoration: none; transition: transform .15s ease; }
.drill:hover { transform: translateY(-3px); text-decoration: none; }
.drill__map { background: var(--water); aspect-ratio: 16 / 9; position: relative; }
.drill__map svg { width: 100%; height: 100%; }
.drill__n { position: absolute; left: 12px; top: 12px; font: 600 .78rem/1 var(--hud); letter-spacing: .1em; color: var(--night); background: var(--signal); padding: 6px 8px; border-radius: 5px; }
.drill__b { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.drill__b h3 { margin: 0; }
.drill__b p { margin: 0; color: var(--ink-2); font-size: .95rem; }
.drill__meta { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; padding-top: 8px; }

/* ---- play screen ---- */
.is-play { background: var(--night); }
.play { color: var(--paper); padding: 22px 0 40px; }
.play__grid { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 24px; align-items: start; }
.play__top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 18px; align-items: baseline; margin-bottom: 12px; }
.play__top h1 { font-size: clamp(1.5rem, 3vw, 2.2rem); margin: 0; color: var(--white); }
.crumbs { font: 500 .78rem/1 var(--hud); letter-spacing: .12em; text-transform: uppercase; color: #9fb7b9; }
.crumbs a { color: inherit; }
.stage { position: relative; border-radius: 16px; overflow: hidden; background: var(--water); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .08); touch-action: none; }
.stage canvas { width: 100%; height: auto; }
.hud { position: absolute; left: 10px; top: 10px; display: flex; gap: 6px; flex-wrap: wrap; pointer-events: none; }
.hud span { background: rgba(8, 22, 25, .78); color: var(--paper); font: 600 .82rem/1 var(--hud); padding: 7px 9px; border-radius: 6px; letter-spacing: .04em; }
.hud span b { color: var(--signal); font-weight: 600; }
.hud .g-F b { color: #7fe0b2; } .hud .g-R b { color: #ff8f84; }
.toast { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); background: rgba(8, 22, 25, .9); color: var(--white); padding: 16px 20px; border-radius: 12px; text-align: center; font-weight: 600; max-width: 80%; }
.toast[hidden] { display: none; }
.deck { margin-top: 14px; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 18px; align-items: center; background: linear-gradient(180deg, #163c42, #0f2c31); border-radius: 16px; padding: 16px 18px; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .07); }
.levers { display: flex; gap: 12px; }
.lever { width: 64px; height: 170px; position: relative; border-radius: 12px; background: #0a1f23; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .08); cursor: ns-resize; touch-action: none; user-select: none; }
.lever::before { content: ""; position: absolute; left: 50%; top: 14px; bottom: 14px; width: 6px; margin-left: -3px; border-radius: 3px; background: #26494e; }
.lever__n { position: absolute; left: 8px; right: 8px; top: 50%; height: 2px; background: rgba(242, 238, 227, .35); }
.lever__knob { position: absolute; left: 7px; right: 7px; height: 30px; margin-top: -15px; border-radius: 9px; background: var(--signal); box-shadow: 0 3px 0 #b8901c; top: 50%; }
.lever__lab { position: absolute; left: 0; right: 0; bottom: -22px; text-align: center; font: 600 .66rem/1 var(--hud); letter-spacing: .12em; color: #9fb7b9; }
.lever__f, .lever__r { position: absolute; left: 0; right: 0; text-align: center; font: 600 .62rem/1 var(--hud); color: #7d9a9c; }
.lever__f { top: 3px; } .lever__r { bottom: 3px; }
.helm { display: grid; justify-items: center; gap: 8px; }
.wheel { width: min(100%, 260px); height: 70px; position: relative; cursor: ew-resize; touch-action: none; user-select: none; }
.wheel svg { width: 100%; height: 100%; }
.helm__lab { font: 600 .7rem/1 var(--hud); letter-spacing: .12em; color: #9fb7b9; }
.keys { display: grid; gap: 8px; }
.keys .btn { min-height: 40px; padding: 0 14px; font-size: .9rem; }
.keyhelp { font-size: .84rem; color: #9fb7b9; margin: 12px 2px 0; }
.keyhelp kbd { font: 600 .74rem/1 var(--hud); background: #0a1f23; border: 1px solid #2c5257; border-bottom-width: 2px; border-radius: 5px; padding: 3px 6px; color: var(--paper); }
.side { display: grid; gap: 16px; }
.card { background: var(--night-2); border-radius: 14px; padding: 18px; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .06); }
.card h2 { font-size: 1.05rem; margin: 0 0 8px; color: var(--white); }
.card p { color: #c2d0cd; font-size: .95rem; margin: 0 0 .7em; }
.card .small { color: #9fb7b9; }
.cond { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.cond label { display: grid; gap: 4px; font-size: .82rem; color: #9fb7b9; }
select, input[type="text"], input[type="number"] { font: inherit; font-size: 1rem; min-height: 44px; padding: 8px 10px; border-radius: 10px; border: 1.5px solid var(--line); background: var(--white); color: var(--ink); width: 100%; }
.card select { background: #0a1f23; border-color: #2c5257; color: var(--paper); }
.result { margin-top: 16px; background: var(--white); color: var(--ink); border-radius: 16px; padding: 22px; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 22px; align-items: start; }
.result[hidden] { display: none; }
.result .big { color: var(--night); }
.result h2 { margin: 0 0 6px; font-size: 1.4rem; }
.result ul { list-style: none; margin: 0 0 12px; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: .95rem; color: var(--ink-2); }
.result ul b { font-family: var(--hud); color: var(--ink); }
.result form { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.result .small { width: 100%; }
.lockpanel { background: var(--white); color: var(--ink); border-radius: 16px; padding: 28px; }

/* ---- logbook ---- */
.book__hd { display: flex; flex-wrap: wrap; gap: 16px; align-items: end; justify-content: space-between; }
.keybox { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; background: var(--white); border: 2px dashed var(--ink); border-radius: 12px; padding: 12px 14px; }
.keybox code { font: 600 .98rem/1.3 var(--hud); word-break: break-all; }
.note { background: #d9efe2; color: #154a33; border-radius: 10px; padding: 10px 14px; font-weight: 600; }
.warn { background: #fde4e0; color: #7a1c12; border-radius: 10px; padding: 10px 14px; }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin: 24px 0; }
.stat { background: var(--white); border-radius: 12px; padding: 16px; box-shadow: var(--shadow); }
.stat b { display: block; font: 600 2rem/1 var(--hud); }
.stat span { font-size: .86rem; color: var(--mute); }
.board { width: 100%; border-collapse: collapse; background: var(--white); border-radius: 12px; overflow: hidden; box-shadow: var(--shadow); font-size: .95rem; }
.board th, .board td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--paper-2); vertical-align: middle; }
.board th { font: 600 .72rem/1.2 var(--hud); letter-spacing: .1em; text-transform: uppercase; color: var(--mute); background: #faf7ef; }
.board td.n { font-family: var(--hud); font-variant-numeric: tabular-nums; }
.steady { display: inline-flex; gap: 6px; align-items: center; font: 600 .72rem/1 var(--hud); letter-spacing: .1em; text-transform: uppercase; color: #1d6a46; background: #d9efe2; padding: 5px 8px; border-radius: 5px; }
.scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; border-radius: 12px; }
.form-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: end; }
.form-row label { display: grid; gap: 4px; font-size: .88rem; color: var(--ink-2); flex: 1 1 220px; }
.danger { border: 1.5px solid #e9b8b0; border-radius: 12px; padding: 16px; background: #fff7f5; }
.danger label { display: flex; gap: 8px; align-items: center; margin: 0 0 10px; }

/* ---- prose pages ---- */
.prose { font-size: 1.04rem; }
.prose h2 { font-size: 1.5rem; margin-top: 1.6em; }
.prose blockquote { margin: 1em 0; padding: 12px 18px; border-left: 4px solid var(--signal); background: var(--white); border-radius: 0 10px 10px 0; }
.prose blockquote cite { display: block; font-size: .86rem; color: var(--mute); font-style: normal; margin-top: 4px; }
.prose ul { padding-left: 1.2em; }
.prose li { margin: .3em 0; }
.cols2 { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }

/* ---- footer ---- */
.foot { background: var(--night); color: #b8c8c5; padding: 48px 0 26px; font-size: .94rem; }
.foot__grid { display: grid; grid-template-columns: minmax(0, 1.4fr) repeat(2, minmax(0, 1fr)); gap: 32px; }
.foot h2 { color: var(--white); font-size: .82rem; font-family: var(--hud); letter-spacing: .14em; text-transform: uppercase; margin: 0 0 12px; }
.foot ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.foot a { color: #dfe8e5; }
.indep { border-top: 1px solid rgba(255, 255, 255, .1); margin-top: 32px; padding-top: 18px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 24px; }
.indep p { margin: 0; max-width: 62em; }

/* ---- print card ---- */
.is-print { background: #fff; }
.printcard { max-width: 760px; margin: 24px auto; padding: 24px; border: 2px solid var(--ink); border-radius: 16px; background: #fff; }
@media print {
  .top, .tide, .foot, .noprint { display: none !important; }
  body { background: #fff; }
  .printcard { border: 0; margin: 0; }
}

/* ---- phone ---- */
@media (max-width: 980px) {
  .hero__in { grid-template-columns: 1fr; padding-top: 40px; gap: 28px; }
  .play__grid { grid-template-columns: 1fr; }
  .drills { grid-template-columns: repeat(2, 1fr); }
  .boats { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  body { font-size: 16px; }
  .top__in { min-height: 60px; gap: 12px; }
  .menu-btn { display: inline-flex; margin-left: auto; background: none; border: 1.5px solid rgba(255, 255, 255, .3); color: var(--white); border-radius: 10px; min-height: 42px; padding: 0 12px; font: 600 .9rem/1 var(--display); align-items: center; gap: 8px; cursor: pointer; }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; align-items: stretch; background: var(--night); padding: 8px 16px 16px; gap: 2px; box-shadow: 0 20px 30px -20px #000; }
  .nav.open { display: flex; }
  .nav a { padding: 12px 10px; }
  .nav a[aria-current="page"]::after { left: auto; right: 10px; top: 50%; margin-top: -2px; }
  .nav .btn { margin: 8px 0 0; justify-content: center; }
  .specs__in { grid-template-columns: 1fr 1fr; }
  .spec { border-left: 0; padding-left: 0; border-top: 1px solid rgba(255, 255, 255, .1); }
  .head, .forces, .ticket, .plans, .cols2, .foot__grid { grid-template-columns: 1fr; }
  .ticket__r::before { display: none; }
  .route { grid-template-columns: 1fr; }
  .route::before { left: 23px; }
  .leg:nth-child(even) { grid-column: 1; transform: none; }
  .drills, .boats { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr 1fr; }
  .deck { grid-template-columns: auto minmax(0, 1fr); }
  .keys { grid-column: 1 / -1; grid-template-columns: repeat(3, 1fr); }
  .lever { height: 150px; width: 58px; }
  .result { grid-template-columns: 1fr; }
  .honest { grid-template-columns: 1fr; }
  .board th, .board td { padding: 8px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }
.foot__line { margin-top: 12px; }
.hero__price { margin-top: 18px; color: #b8c8c5; }
.pricebar { margin: 0 0 26px; }
.book__tools { margin-top: 36px; }
.band h2 + .scroll, .band h2 + p { margin-top: 0; }
.band--chart h2 { margin-top: 28px; }
.keybox { margin-bottom: 4px; }
.demo-note { position: absolute; right: 10px; bottom: 10px; margin: 0; background: var(--signal); color: var(--signal-ink); font: 600 .74rem/1 var(--hud); letter-spacing: .08em; padding: 7px 9px; border-radius: 6px; }
.demo-note[hidden] { display: none; }
button[disabled] { opacity: .55; cursor: not-allowed; transform: none !important; }
.nav a.btn { color: var(--signal-ink); }
.nav a.btn:hover { background: var(--signal); color: var(--signal-ink); }
.play .small { color: #9fb7b9; }
@media (max-width: 760px) {
  .hud { position: static; padding: 8px; background: #0a1f23; }
  .toast { font-size: .9rem; padding: 10px 12px; }
  .deck { padding-bottom: 26px; }
  .lever__lab { bottom: -18px; }
}
.drill__map { overflow: hidden; }
.drill__map canvas { width: 100%; height: 100%; object-fit: cover; object-position: top center; }

/* ---------- v1.1.0: AdEngine banner (adengine.us) ----------
   One labelled slot between the main content and the night footer, on public pages only (the controllers opt in), on a
   sand band so it reads as its own strip. The label and the reserved height are on the <ins>, and all the band's height
   is the <ins>'s own margin (flow-root keeps it inside the band), so when tag.js (or ae-size.js) hides a slot it cannot
   fill, the label, the space and the band go with it. 110px = 16px label + 4px gap + 90px banner; 270px on phones
   (300x250). display stays in this file and is never !important: tag.js hides a slot with style.display='none'.
   Label: the HUD face in --ink-2 (6.6:1 on the sand band). */
.ae-slot { display: flow-root; background: var(--paper-2); border-top: 1px solid var(--line); padding: 0 16px; }
.ae-slot ins.adengine { display: block; max-width: 728px; min-height: 110px; margin: 36px auto 40px; text-align: center; text-decoration: none; }
.ae-slot ins.adengine::before { content: "Advertisement"; display: block; margin-bottom: 4px; font: 600 12px/16px var(--hud); letter-spacing: .16em; text-transform: uppercase; color: var(--ink-2); }
.ae-slot ins.adengine a { display: inline-block; vertical-align: top; }
@media (max-width: 767px) { .ae-slot ins.adengine { max-width: 300px; min-height: 270px; margin: 28px auto 32px; } }
/* a slot that stays empty (no ad, or tag.js blocked) drops its labelled landmark too, not only the <ins> */
.ae-slot:has(> ins.adengine[style*="none"]) { display: none; }
@media print { .ae-slot { display: none; } }
