/* Site styles: the front page and the roadmap. Colours are the HUD's (client/ui/UiTheme.cs); type sizes follow its scale. */
@font-face { font-family: "Fira Sans Condensed"; font-weight: 400; font-display: swap; src: url("fonts/FiraSansCondensed-Regular.woff2") format("woff2"); }
@font-face { font-family: "Fira Sans Condensed"; font-weight: 500; font-display: swap; src: url("fonts/FiraSansCondensed-Medium.woff2") format("woff2"); }
@font-face { font-family: "Fira Sans Condensed"; font-weight: 600; font-display: swap; src: url("fonts/FiraSansCondensed-SemiBold.woff2") format("woff2"); }

:root {
  --desk: rgb(7, 9, 12); --win: rgb(12, 16, 21); --head: rgb(18, 24, 32); --edge: rgb(35, 45, 55); --line: rgb(27, 35, 44); --edge-focus: rgb(58, 108, 120);
  --text: rgb(213, 220, 228); --text2: rgb(138, 150, 163); --soft: rgb(179, 189, 199);
  --accent: rgb(86, 208, 224); --amber: rgb(240, 180, 92); --green: rgb(111, 217, 140); --violet: rgb(159, 168, 255); --rose: rgb(231, 154, 208);
  --ease: cubic-bezier(.2, .7, .2, 1);
  color-scheme: dark;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { background: var(--desk); }
body {
  margin: 0; background: var(--desk); color: var(--text);
  font: 400 16px/1.45 "Fira Sans Condensed", "Fira Sans", "Arial Narrow", sans-serif;
  -webkit-text-size-adjust: 100%; text-rendering: optimizeLegibility;
}
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: rgb(143, 228, 239); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* Picture and title */
.hero { position: relative; min-height: 300px; display: flex; align-items: flex-end; overflow: hidden; border-bottom: 1px solid var(--edge); }
.hero-art { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 40%; }
.hero::after { content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(7, 9, 12, .94) 0%, rgba(7, 9, 12, .8) 45%, rgba(7, 9, 12, .12) 78%),
              linear-gradient(0deg, rgba(7, 9, 12, .85) 0%, rgba(7, 9, 12, 0) 55%); }
.hero-text { position: relative; z-index: 1; width: 100%; max-width: 1200px; margin: 0 auto; padding: 48px 24px 26px; }
h1 { margin: 2px 0 6px; font-size: 44px; line-height: 1.05; font-weight: 600; letter-spacing: .01em; color: rgb(238, 243, 247); }
.lede { margin: 0; max-width: 34em; font-size: 18px; color: var(--soft); }
.caveat { margin: 10px 0 0; font-size: 14px; color: var(--text2); }
.updated { margin: 6px 0 0; font-size: 14px; color: var(--text2); min-height: 1.45em; }
.updated b { color: var(--text); font-weight: 500; }

main { max-width: 1200px; margin: 0 auto; padding: 22px 24px 8px; }
.notice { margin: 24px 0; padding: 16px 18px; background: var(--win); border: 1px solid var(--edge); color: var(--soft); }

/* Counts per stage */
.stages { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin: 0 0 32px; padding: 0; list-style: none; }
.stages li { position: relative; }
.stages a { display: block; height: 100%; padding: 12px 16px 12px; background: var(--win); border: 1px solid var(--edge);
  border-top: 2px solid var(--c, var(--edge)); color: inherit; text-decoration: none; transition: border-color .25s var(--ease), background-color .25s var(--ease); }
.stages a:hover { background: var(--head); border-color: var(--edge-focus); border-top-color: var(--c, var(--edge-focus)); }
.stages b { display: block; font-size: 35px; line-height: 1.05; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--c, var(--text)); }
.stages span { display: block; font-size: 14px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: var(--text2); }
.stage-building { --c: var(--accent); } .stage-built { --c: var(--green); }

/* Sections */
section { margin: 0 0 36px; scroll-margin-top: 16px; }
h2 { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; margin: 0 0 12px; padding-bottom: 8px; border-bottom: 1px solid var(--line);
  font-size: 15px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--text); }
h3 { margin: 0; }


/* Being built */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px; margin: 0; padding: 0; list-style: none; }
.card { display: flex; flex-direction: column; padding: 14px 16px 13px; background: var(--win); border: 1px solid var(--edge); border-left: 3px solid var(--c); }
.card h3 { font-size: 19px; font-weight: 600; line-height: 1.2; }
.card p { flex: 1; margin: 4px 0 12px; color: var(--soft); }
.state { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; padding-top: 10px; border-top: 1px solid var(--line); font-size: 14px; color: var(--text2); }
.state strong { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--c); }
.state strong::before { content: ""; flex: none; width: 9px; height: 9px; background: var(--c); }
.state-building { --c: var(--accent); }
.state-polishing { --c: var(--amber); } .state-polishing strong::before { background: transparent; border: 2px solid var(--c); border-radius: 50%; }
.state-weekend { --c: var(--violet); } .state-weekend strong::before { background: transparent; border: 2px solid var(--c); transform: rotate(45deg); width: 8px; height: 8px; }

/* Next */
.queue { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.queue li { display: grid; grid-template-columns: 52px 1fr; gap: 14px; align-items: start; padding: 12px 16px; background: var(--win); border: 1px solid var(--edge); }
.queue li.first { border-color: var(--edge-focus); box-shadow: inset 3px 0 0 var(--accent); }
.queue .n { font-size: 25px; font-weight: 600; line-height: 1.1; font-variant-numeric: tabular-nums; color: var(--text2); }
.queue .first .n { color: var(--accent); }
.queue h3 { display: inline; font-size: 17px; font-weight: 600; }
.queue p { margin: 2px 0 0; color: var(--soft); }

/* Built */
.groups { display: grid; grid-template-columns: repeat(auto-fill, minmax(420px, 1fr)); gap: 12px; align-items: start; }
.group { background: var(--win); border: 1px solid var(--edge); }
.group h3 { display: flex; justify-content: space-between; gap: 8px; padding: 9px 16px 8px; background: var(--head); border-bottom: 1px solid var(--edge);
  font-size: 14px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--text); }
.group h3 span { color: var(--green); font-variant-numeric: tabular-nums; letter-spacing: 0; }
.group ul { margin: 0; padding: 4px 16px 6px; list-style: none; }
.group li { position: relative; padding: 9px 0 9px 16px; border-top: 1px solid var(--line); }
.group li:first-child { border-top: 0; }
.group li::before { content: ""; position: absolute; left: 0; top: 17px; width: 6px; height: 6px; background: var(--green); }
.group li strong { display: block; font-weight: 600; color: var(--text); }
.group li p { margin: 1px 0 0; color: var(--soft); }

/* Later */
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.chips li { padding: 5px 12px; font-size: 16px; color: var(--soft); background: var(--win); border: 1px solid var(--edge); }
.chips strong { font-weight: 600; color: var(--text); }
.chips span { margin-left: 8px; color: var(--text2); }


/* Way back from the roadmap */
.back { margin: 0 0 14px; font-size: 16px; }
.back a { color: var(--soft); text-decoration: none; }
.back a::before { content: "\2190\00a0"; color: var(--accent); }
.back a:hover { color: var(--text); text-decoration: underline; }

/* Front page: the clip, the downloads, four shots and the way to the roadmap */
.landing main { max-width: 1000px; padding-top: 30px; }

/* The still always sits under the clip; the clip fades in once it plays. */
.reel { position: relative; height: clamp(440px, 56.25vw, 72vh); overflow: hidden; background: var(--desk); border-bottom: 1px solid var(--edge); }
.reel-still, .reel-clip { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%; }
.reel-clip { opacity: 0; transition: opacity 1.2s ease-in-out; }
.reel.is-playing .reel-clip { opacity: 1; }
.reel::after { content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none;
  background: linear-gradient(0deg, rgba(7, 9, 12, .96) 0%, rgba(7, 9, 12, .9) 22%, rgba(7, 9, 12, .6) 42%, rgba(7, 9, 12, 0) 66%),
              linear-gradient(90deg, rgba(7, 9, 12, .55) 0%, rgba(7, 9, 12, 0) 55%); }
.reel-text { position: absolute; z-index: 3; left: 0; right: 0; bottom: 0; max-width: 1000px; margin: 0 auto; padding: 0 24px 30px; }
.landing h1 { margin: 0 0 8px; font-size: 56px; line-height: 1; }
.landing .lede { max-width: 30em; font-size: 19px; color: var(--text); }
.landing .caveat { margin-top: 12px; font-size: 16px; color: var(--soft); }

/* One pause and resume button, drawn with CSS shapes. */
.clip-toggle { position: absolute; z-index: 4; right: max(24px, calc((100% - 1000px) / 2 + 24px)); bottom: 30px;
  display: inline-flex; align-items: center; gap: 10px; height: 44px; min-width: 44px; padding: 0 16px 0 14px;
  background: rgba(7, 9, 12, .78); border: 1px solid var(--edge); color: var(--text); cursor: pointer;
  font: 500 16px/1 "Fira Sans Condensed", "Fira Sans", "Arial Narrow", sans-serif; letter-spacing: .02em;
  transition: border-color .2s ease-in-out, background-color .2s ease-in-out; }
.clip-toggle:hover { border-color: var(--edge-focus); background: rgba(18, 24, 32, .92); }
.clip-icon { flex: none; box-sizing: border-box; width: 12px; height: 14px; border-left: 4px solid currentColor; border-right: 4px solid currentColor; }
.clip-toggle.is-paused .clip-icon { width: 0; height: 0; border-right: 0; border-left: 12px solid currentColor;
  border-top: 7px solid transparent; border-bottom: 7px solid transparent; }

/* Downloads: the visitor's own system gets the filled button. */
.play { margin: 0 0 52px; }
.intro { margin: 0 0 18px; max-width: 46em; color: var(--soft); }
.downloads { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 0 0 18px; padding: 0; list-style: none; }
.download { padding: 18px 18px 16px; background: var(--win); border: 1px solid var(--edge); border-top: 2px solid var(--edge-focus); }
.download p { margin: 14px 0 0; color: var(--soft); }
.download.is-yours { order: -1; border-color: var(--edge-focus); border-top-color: var(--accent); }
.button { display: inline-block; padding: 10px 20px 11px; background: transparent; border: 1px solid var(--accent);
  color: var(--accent); font-size: 18px; font-weight: 600; letter-spacing: .02em; text-decoration: none;
  transition: background-color .2s ease-in-out, border-color .2s ease-in-out, color .2s ease-in-out; }
.button:hover { background: rgba(86, 208, 224, .12); color: rgb(143, 228, 239); }
.is-yours .button { background: var(--accent); color: var(--desk); }
.is-yours .button:hover { background: rgb(143, 228, 239); border-color: rgb(143, 228, 239); color: var(--desk); }
code { padding: 1px 5px; background: var(--head); border: 1px solid var(--line); color: var(--text);
  font: 15px/1.3 ui-monospace, "DejaVu Sans Mono", Menlo, Consolas, monospace; white-space: nowrap; }
.talk { margin: 14px 0 0; color: var(--soft); }

/* Three shots from the game: the first spans the row on wide screens */
.shown { margin: 0 0 52px; }
.shots { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 34px 24px; }
.shot { margin: 0; }
.shot:first-child { grid-column: 1 / -1; }
.shot:first-child figcaption { max-width: 40em; }
.shot img { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; background: var(--win); border: 1px solid var(--edge); }
.shot figcaption { padding: 14px 2px 0; }
.shot h3 { font-size: 19px; font-weight: 600; line-height: 1.2; color: var(--text); }
.shot p { margin: 5px 0 0; color: var(--soft); }

/* The way to the roadmap: a block of its own */
.onward { position: relative; display: flex; align-items: center; min-height: 168px; margin: 0 0 48px; overflow: hidden;
  background: var(--win); border: 1px solid var(--edge); color: inherit; text-decoration: none; transition: border-color .25s ease-in-out; }
.onward img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 40%; }
.onward::after { content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(7, 9, 12, .95) 0%, rgba(7, 9, 12, .85) 50%, rgba(7, 9, 12, .25) 100%); }
.onward-text { position: relative; z-index: 1; display: block; padding: 26px 26px 28px; }
.onward strong { display: block; font-size: 28px; font-weight: 600; line-height: 1.1; color: rgb(238, 243, 247); }
.onward strong::after { content: "\00a0\2192"; color: var(--accent); }
.onward-text span { display: block; max-width: 30em; margin-top: 8px; font-size: 18px; color: var(--soft); }
.onward:hover { border-color: var(--edge-focus); }
.onward:hover strong { color: rgb(143, 228, 239); }

/* Things arrive with an ease; nothing blinks. */
.arrive { animation: arrive .5s var(--ease) both; animation-delay: calc(var(--i, 0) * 60ms); }
@keyframes arrive { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .arrive { animation: none; } * { transition: none !important; } .reel-clip, .clip-toggle { display: none !important; } }

@media (max-width: 720px) {
  .hero { min-height: 250px; }
  .hero-art { object-position: 50% 30%; }
  .hero::after { background: linear-gradient(0deg, rgba(7, 9, 12, .97) 0%, rgba(7, 9, 12, .82) 55%, rgba(7, 9, 12, .3) 100%); }
  .hero-text { padding: 72px 16px 18px; }
  h1 { font-size: 35px; }
  .lede { font-size: 16px; }
  main { padding: 18px 16px 4px; }
  .stages { grid-template-columns: repeat(2, 1fr); gap: 8px; margin-bottom: 28px; }
  .stages b { font-size: 30px; }
  .cards, .groups { grid-template-columns: 1fr; }
  .queue li { grid-template-columns: 34px 1fr; gap: 10px; padding: 11px 14px; }
  .reel::after { background: linear-gradient(0deg, rgba(7, 9, 12, .96) 0%, rgba(7, 9, 12, .9) 34%, rgba(7, 9, 12, .66) 54%, rgba(7, 9, 12, 0) 82%); }
  .reel-text { padding: 0 16px 22px; }
  .landing h1 { font-size: 40px; }
  .landing .lede { font-size: 17px; }
  .clip-toggle { top: 16px; right: 16px; bottom: auto; }
  .downloads, .shots { grid-template-columns: 1fr; }
  .shots { gap: 28px; }
  .onward { min-height: 150px; }
  .onward-text { padding: 22px 18px 24px; }
}
