/* natesurvives.com /play/: the site's loading screen + the small plan link on the game's title / pause / fall panels (GAME agent).
   The game's own CSS stays as it is; this file only restyles #loading and adds .ns-* classes. Colours = the site's tokens
   (docs\DESIGN.md), written out because /play/ does not load the site's CSS. No blur, no flicker: one steady glow on the bar. */
.ns-load {
  --ns-ink: #05070D; --ns-night: #0A0F1E; --ns-cream: #F8ECD0; --ns-signal: #FCD01C; --ns-muted: #BDB6A6; --ns-line: rgba(248, 236, 208, .14);
  --ns-dusk: rgba(224, 131, 47, .16);
  background: radial-gradient(120% 70% at 50% 115%, var(--ns-dusk) 0%, rgba(224, 131, 47, 0) 62%), linear-gradient(180deg, var(--ns-ink) 0%, var(--ns-night) 100%) !important;
  color: var(--ns-cream); padding: 24px 16px; box-sizing: border-box; overflow: auto;
}
.ns-load-in { width: min(560px, 100%); display: flex; flex-direction: column; align-items: center; text-align: center; gap: 0; }
.ns-kicker { font-family: "Oswald", system-ui, sans-serif; font-size: 13px; font-weight: 500; letter-spacing: .5em; text-transform: uppercase; color: var(--ns-signal); margin: 0 0 6px .5em; }
#loading h1.lt { margin: 0; font-family: "Anton", Impact, sans-serif; font-weight: 400; font-size: clamp(44px, 9vw, 96px); line-height: .95; letter-spacing: .02em;
  text-transform: uppercase; color: var(--ns-cream); text-shadow: 0 4px 0 #000, 0 10px 30px rgba(0, 0, 0, .55); }
#loading .lb { position: relative; width: min(420px, 100%); height: 8px; margin: 26px 0 0; background: var(--ns-line); border-radius: 4px; overflow: hidden; }
#ns-f { position: absolute; inset: 0 auto 0 0; width: 0; background: var(--ns-signal); border-radius: 4px; box-shadow: 0 0 14px rgba(252, 208, 28, .45); transition: width .45s ease-out; }
#loading #load-f { display: none; }   /* the game still writes its own bar; ours shows bytes + the game's steps */
.ns-row { width: min(420px, 100%); display: flex; justify-content: space-between; gap: 12px; margin-top: 10px; font-family: "Oswald", system-ui, sans-serif; font-size: 14px; letter-spacing: .12em; text-transform: uppercase; color: var(--ns-muted); }
#loading #load-t { color: var(--ns-muted); font-size: 14px; letter-spacing: .12em; }
#ns-pct { font-family: "JetBrains Mono", ui-monospace, monospace; letter-spacing: 0; color: var(--ns-cream); }
.ns-tip { min-height: 3em; max-width: 34em; margin: 26px 0 0; padding: 12px 16px; border-left: 3px solid var(--ns-signal); background: rgba(248, 236, 208, .05);
  font-family: "Oswald", system-ui, sans-serif; font-size: 17px; line-height: 1.45; color: var(--ns-cream); text-align: left; transition: opacity .5s ease; }
.ns-tip.out { opacity: 0; }
.ns-hint { margin: 16px 0 0; font-family: "Oswald", system-ui, sans-serif; font-size: 15px; line-height: 1.4; color: var(--ns-muted); }
.ns-hint + .ns-hint { margin-top: 4px; }
/* messages: no WebGL, a failed download, a failed start, no JavaScript */
.ns-msg { width: min(560px, 100%); text-align: center; font-family: "Oswald", system-ui, sans-serif; font-size: 17px; line-height: 1.5; color: var(--ns-cream, #F8ECD0); }
.ns-msg h2 { margin: 0 0 10px; font-family: "Anton", Impact, sans-serif; font-weight: 400; font-size: clamp(30px, 5vw, 44px); line-height: 1.05; text-transform: uppercase; letter-spacing: .02em; }
.ns-msg p { margin: 0 0 12px; color: var(--ns-muted, #BDB6A6); }
.ns-msg .ns-tech { font-family: "JetBrains Mono", ui-monospace, monospace; font-size: 12px; opacity: .8; word-break: break-word; }
.ns-msg a, .ns-msg button { display: inline-flex; align-items: center; min-height: 44px; padding: 0 22px; margin: 6px 6px 0; border-radius: 4px; font-family: "Anton", Impact, sans-serif;
  font-size: 18px; letter-spacing: .06em; text-transform: uppercase; text-decoration: none; cursor: pointer; }
.ns-msg .ns-btn { background: var(--ns-signal, #FCD01C); color: #141006; border: 0; }
.ns-msg .ns-ghost { color: var(--ns-cream, #F8ECD0); border: 1px solid rgba(248, 236, 208, .3); background: none; }
.ns-msg a:focus-visible, .ns-msg button:focus-visible, .ns-plan a:focus-visible { outline: 2px solid #FCD01C; outline-offset: 3px; }
.ns-noscript { margin: auto; }
.ns-load[data-state="msg"] .ns-load-in { display: none; }
/* short screens: phones held sideways (844 x 390) */
@media (max-height: 520px) {
  .ns-kicker { font-size: 11px; margin-bottom: 2px; }
  #loading h1.lt { font-size: clamp(36px, 8vh, 56px); }
  #loading .lb { margin-top: 14px; }
  .ns-tip { margin-top: 12px; min-height: 0; font-size: 15px; padding: 8px 12px; }
  .ns-hint { margin-top: 8px; font-size: 13px; }
}
@media (prefers-reduced-motion: reduce) { #ns-f, .ns-tip { transition: none; } }

/* the site line on the game's title, pause and fall panels: small, quiet, never over the HUD (only inside those panels).
   Since 28 Nov 2026: the book (Amazon) first, then the free plan, then natesurvives.com. One line on computer screens; on smaller or short
   screens (phones held sideways) the book takes the first row and the plan + the site the second, so the line stays clear of the menu. */
.ns-plan { margin-top: 14px; font-family: "Oswald", system-ui, sans-serif; font-size: 14px; letter-spacing: .04em; color: rgba(236, 230, 218, .7); text-shadow: 0 1px 3px #000; white-space: nowrap; }
.ns-plan a { display: inline-block; padding: 12px 2px; color: inherit; text-decoration: underline; text-decoration-color: rgba(236, 230, 218, .35); text-underline-offset: 3px; }
.ns-plan a.ns-book { color: rgba(248, 236, 208, .9); }
.ns-plan a:hover { color: #FCD01C; text-decoration-color: currentColor; }
.ns-plan .ns-sep { margin: 0 8px; opacity: .5; }
.panel.pause .ns-plan, .panel.over .ns-plan { text-align: center; }
/* the title: its menu fills a 720p screen (the panel scrolls), so the line sits in the free bottom-right corner of the scene instead */
#modal.m-title .ns-plan { position: fixed; right: 22px; bottom: 10px; margin: 0; text-align: right; }
@media (max-height: 520px) { #modal.m-title .ns-plan { right: 14px; bottom: 2px; } }
html.tc .ns-plan { font-size: 13px; }
/* two rows: the book, then "plan · site" */
@media (max-width: 1100px), (max-height: 520px) {
  .ns-plan .ns-sep-book { display: none; }
  .ns-plan a.ns-book { display: block; width: fit-content; margin: 0 auto; padding: 12px 2px 8px; }
  #modal.m-title .ns-plan a.ns-book { margin-right: 0; }
  .ns-plan a.ns-book ~ a { padding: 8px 2px 12px; }
}
/* the title, when the game's menu needs the corner (hooks.js fit(): a returning player's longer menu on a small phone, or a menu that
   scrolls under the corner): the line joins the menu's column, under its last line, and scrolls with it */
#modal.m-title .ns-plan.ns-flow { position: static; margin: 6px 0 0; text-align: left; }
#modal.m-title .ns-plan.ns-flow a.ns-book { margin: 0 auto 0 0; }
/* touch screens: since 28 Nov 2026 the game's page runs under the notch and the home bar (viewport-fit=cover), so the corner line keeps
   inside the safe area (the game's own variables, set by touch.js; without a notch these are the 22 / 10 and 14 / 2 px of the rules above) */
html.tc #modal.m-title .ns-plan:not(.ns-flow) { right: calc(var(--sr, 10px) + 12px); bottom: calc(var(--sb, 8px) + 2px); }
@media (max-height: 520px) { html.tc #modal.m-title .ns-plan:not(.ns-flow) { right: calc(var(--sr, 10px) + 4px); bottom: calc(var(--sb, 8px) - 6px); } }
/* the game's phone layout (html.tc + css/phone.css, in the game since 28 Nov 2026): its pause menu is a two-column grid, so the line takes
   a row of its own under the buttons (in one cell it stretched QUIT TO TITLE to twice its height). One line when the screen is wide
   enough for it (the panel grows to fit it, 563 px), else the two rows above. The title and the fall panel keep the rules above. */
html.tc .panel.pause .ns-plan { grid-column: 1 / -1; margin-top: 0; }
@media (min-width: 621px) {
  html.tc .panel.pause .ns-plan .ns-sep-book { display: inline; }
  html.tc .panel.pause .ns-plan a.ns-book { display: inline-block; width: auto; margin: 0; padding: 12px 2px; }
  html.tc .panel.pause .ns-plan a.ns-book ~ a { padding: 12px 2px; }
}
