/* ------------------------------------------------------------------
   Moonlit Straits — page styles
   The only rule the scene itself needs is #scene-canvas.
   ------------------------------------------------------------------ */

:root {
  --ink: #dff3f1;
  --ink-dim: #7fa8ab;
  --edge: rgba(190, 240, 235, 0.22);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  height: 100%;
  background: #04171d;
  color: var(--ink);
  font-family: ui-sans-serif, -apple-system, "Segoe UI", Inter, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

body { overflow: hidden; }

/* The scene canvas: fixed full-bleed backdrop.
   Swap to `position:absolute; inset:0` inside a positioned wrapper to embed it
   in a hero section instead of the whole viewport. */
#scene-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  z-index: 0;
  /* Fallback tint while the first frame compiles. */
  background: linear-gradient(180deg, #0b3d86 0%, #10617f 55%, #1f8f86 78%, #07333a 100%);
  opacity: 0;
  transition: opacity 900ms ease;
}
#scene-canvas.is-ready { opacity: 1; }

/* ---------- demo chrome ---------- */

.page {
  position: fixed;
  inset: 0;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(20px, 4vw, 56px);
  pointer-events: none;
  transition: opacity 300ms ease;
}
.page.is-hidden { opacity: 0; }

.eyebrow {
  margin: 0 0 10px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-dim);
}

h1 {
  margin: 0;
  font-size: clamp(34px, 7vw, 76px);
  font-weight: 300;
  letter-spacing: -0.02em;
  line-height: 0.95;
  text-shadow: 0 2px 40px rgba(0, 20, 25, 0.55);
}

.lede {
  margin: 14px 0 0;
  max-width: 34ch;
  font-size: clamp(13px, 1.5vw, 16px);
  line-height: 1.5;
  color: var(--ink-dim);
}

.page__foot {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 22px;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--ink-dim);
}

.hud { font-variant-numeric: tabular-nums; }

.keys { display: flex; gap: 14px; align-items: center; pointer-events: auto; }
.keys a { color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--edge); }
.keys a:hover { border-bottom-color: var(--ink); }

kbd {
  display: inline-block;
  min-width: 18px;
  padding: 2px 5px;
  margin-right: 4px;
  border: 1px solid var(--edge);
  border-radius: 4px;
  font: inherit;
  font-size: 10px;
  text-align: center;
  color: var(--ink);
}

.noscript {
  position: fixed;
  inset: auto 0 50% 0;
  z-index: 2;
  text-align: center;
}

@media (max-width: 640px) {
  .lede { display: none; }
  .keys { display: none; }
}
