/* The Dusty Penny site. One look for now (CH03's wall of TVs); a new game can bring a new one. */
@import url('/assets/fonts/fonts.css');

:root { --bg: #050407; --ink: #f1ebe0; --dim: #9a94a0; --gold: #ffc832; --line: #25212c; --copper: #dc9a55; }
* { box-sizing: border-box; }
html { background: var(--bg); color: var(--ink); font: 400 18px/1.5 'Inter Tight', system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
body { margin: 0; }
a { color: inherit; }
a:focus-visible, button:focus-visible, select:focus-visible, input:focus-visible, textarea:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
[hidden] { display: none !important; }
.label { font: 400 11px/1.4 'JetBrains Mono', monospace; letter-spacing: 0.22em; text-transform: uppercase; color: var(--dim); margin: 0; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------------------------------------------------------------- the top bar */
.top { position: absolute; left: 0; right: 0; top: 0; z-index: 3; display: flex; justify-content: space-between; align-items: center; padding: 22px 36px; pointer-events: none; }
.top.flat { position: static; pointer-events: auto; border-bottom: 1px solid var(--line); }
.top a { pointer-events: auto; }
.mark { font-weight: 800; font-size: 19px; text-decoration: none; }
.top nav { display: flex; gap: 28px; }
.top nav a { font: 400 11px/1 'JetBrains Mono', monospace; letter-spacing: 0.22em; text-transform: uppercase; color: var(--dim); text-decoration: none; padding: 6px 0; border-bottom: 1px solid transparent; }
.top nav a:hover, .top nav a[aria-current] { color: var(--ink); border-bottom-color: var(--gold); }

/* ---------------------------------------------------------------- the wall, the name, a TV's card */
.hero { position: relative; height: 100svh; min-height: 640px; overflow: hidden; }
#stage { position: absolute; inset: 0; }
#stage canvas { display: block; width: 100%; height: 100%; }
.name { position: absolute; left: 36px; right: 36px; bottom: 30px; z-index: 2; transition: opacity 0.3s; }
.focused .name { opacity: 0; pointer-events: none; }
.name .big { display: block; white-space: nowrap; margin: 0; font-family: 'Press Start 2P', monospace; font-weight: 400; text-transform: uppercase; color: var(--copper); text-shadow: 0 0.07em 0 #8a4b2a, 0 0.14em 0 #3e2018; line-height: 1.05; padding-bottom: 0.14em; }
.name .line { display: flex; justify-content: space-between; align-items: baseline; gap: 18px 40px; margin-top: 18px; }
.name .line p { margin: 0; font-size: 17px; line-height: 1.4; max-width: 46em; }
.name .line .label { white-space: nowrap; }
#card { position: absolute; left: 36px; top: 46%; transform: translateY(-50%); z-index: 2; width: 440px; padding: 22px 26px; background: rgba(12, 10, 16, 0.34); -webkit-backdrop-filter: blur(18px) saturate(1.25); backdrop-filter: blur(18px) saturate(1.25); border: 1px solid rgba(255, 255, 255, 0.1); border-left: 3px solid var(--gold); opacity: 0; pointer-events: none; transition: opacity 0.25s; }
.focused #card { opacity: 1; pointer-events: auto; }
#card h2 { font-weight: 800; font-size: 44px; line-height: 1.05; letter-spacing: -0.03em; margin: 8px 0 8px; }
#card p.what { margin: 0; font-size: 17px; line-height: 1.4; }
#card .tag { color: var(--gold); }
.btns { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 16px; }
.btn { all: unset; box-sizing: border-box; cursor: pointer; display: inline-block; padding: 13px 18px; font: 700 12px/1 'JetBrains Mono', monospace; letter-spacing: 0.18em; text-transform: uppercase; border: 1px solid var(--ink); color: var(--ink); background: rgba(255, 255, 255, 0.04); }
.btn.solid { background: var(--gold); border-color: var(--gold); color: #050407; }
.btn:hover { background: var(--ink); border-color: var(--ink); color: #050407; }
/* the TVs as buttons, for the keyboard and screen readers: out of sight until tabbed to */
#tvlist { position: absolute; left: 36px; top: 70px; z-index: 4; display: flex; flex-wrap: wrap; gap: 6px; max-width: 70%; }
#tvlist button { position: absolute; left: -9999px; }
#tvlist button:focus { position: static; font: 700 12px/1 'JetBrains Mono', monospace; padding: 10px 12px; background: var(--gold); color: #050407; border: 0; }

/* ---------------------------------------------------------------- the demo shelf */
.below { overflow: hidden; }
.bay { position: relative; max-width: 1368px; margin: 0 auto; padding: 70px 36px 0; display: grid; grid-template-columns: 650px 1fr; gap: 64px; align-items: end; }
.bay .rig { grid-column: 1; grid-row: 1; }
.bay .words { grid-column: 2; grid-row: 1; }
.shelf { height: 16px; background: #1c0f0b; border-top: 2px solid #3a2014; border-bottom: 5px solid #0d0705; }
.rig { position: relative; width: 650px; height: 450px; margin-bottom: -4px; }
.rig img { position: absolute; inset: 0; width: 650px; height: 450px; image-rendering: pixelated; }
.rig canvas.glass { position: absolute; left: 32px; top: 128px; width: 384px; height: 288px; }
.rig .glow { position: absolute; left: 224px; top: 272px; width: 1100px; height: 820px; transform: translate(-50%, -50%); filter: blur(80px); opacity: 0.5; mix-blend-mode: screen; pointer-events: none; }
.words { padding-bottom: 56px; }
.words h2 { font-weight: 800; font-size: clamp(36px, 4vw, 60px); line-height: 0.98; letter-spacing: -0.03em; margin: 14px 0 18px; }
.words p { font-size: 20px; line-height: 1.45; max-width: 26em; margin: 0 0 10px; }
/* the demo's buttons: chunky, like the game's own buttons, with a lip that presses in */
.get { display: flex; flex-wrap: wrap; gap: 14px; margin: 26px 0 0; }
.dl { display: inline-flex; flex-direction: column; gap: 9px; min-width: 210px; padding: 16px 20px 15px; background: var(--gold); color: #140c1c; border: 3px solid #140c1c; box-shadow: 0 6px 0 #d18a1c, 0 6px 0 3px #140c1c; text-decoration: none; cursor: pointer; transition: transform 0.06s, box-shadow 0.06s; }
.dl .os { font: 400 20px/1 'Press Start 2P', monospace; text-transform: uppercase; }
.dl .act { font: 700 12px/1 'JetBrains Mono', monospace; letter-spacing: 0.18em; text-transform: uppercase; }
.dl:hover { background: #fff07a; }
.dl:active { transform: translateY(4px); box-shadow: 0 2px 0 #d18a1c, 0 2px 0 3px #140c1c; }
.dl.second { background: #fbf6ea; box-shadow: 0 6px 0 #8d8aa8, 0 6px 0 3px #140c1c; }
.dl.second:hover { background: #fff0c8; }
.dl[aria-disabled='true'] { background: #2a1d3a; color: #8d8aa8; border-color: #45305a; box-shadow: none; cursor: not-allowed; }
.dl[aria-disabled='true']:hover { background: #2a1d3a; }
.dl:focus-visible { outline: 3px solid #fbf6ea; outline-offset: 4px; }

/* ---------------------------------------------------------------- the fine print */
.fine { max-width: 1368px; margin: 0 auto; padding: 30px 36px 70px; display: flex; flex-wrap: wrap; gap: 14px 34px; }
.fine a { text-decoration: none; }
.fine a:hover { color: var(--ink); }

/* ---------------------------------------------------------------- the small pages (privacy, feedback) */
.page { max-width: 760px; margin: 0 auto; padding: 70px 36px 40px; }
.page h1 { font-weight: 800; font-size: clamp(44px, 6vw, 72px); line-height: 0.98; letter-spacing: -0.035em; margin: 12px 0 26px; }
.prose { white-space: pre-wrap; font-size: 19px; line-height: 1.55; color: var(--ink); }
.lead { font-size: 21px; line-height: 1.45; margin: 0 0 30px; }
form.feedback { display: grid; gap: 22px; }
.fld { display: grid; gap: 8px; }
.fld > span { font: 400 11px/1.4 'JetBrains Mono', monospace; letter-spacing: 0.22em; text-transform: uppercase; color: var(--dim); }
.fld small { color: var(--dim); font-size: 14px; }
.fld select, .fld input, .fld textarea { font: inherit; font-size: 18px; color: var(--ink); background: #0e0c12; border: 1px solid #3a3642; padding: 12px 14px; width: 100%; }
.fld textarea { min-height: 180px; resize: vertical; }
.fld select:focus, .fld input:focus, .fld textarea:focus { border-color: var(--gold); outline: none; }
.trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
form.feedback button[type='submit'] { justify-self: start; }
.status { min-height: 1.5em; margin: 0; font-size: 18px; }
.status.ok { color: #4ed46a; }
.status.bad { color: #f25a4a; }

/* ---------------------------------------------------------------- phones and small windows */
@media (max-width: 1100px) {
  .bay { display: block; padding: 40px 16px 0; }
  .words { padding-bottom: 26px; }
  .rig { transform: scale(0.5); transform-origin: 0 0; margin: 0 0 -227px; }
  .get { flex-direction: column; }
  .dl { min-width: 0; }
  .fine { padding: 26px 16px 50px; flex-direction: column; }
}
@media (max-width: 1000px) {
  /* on a phone the wall sits on top, at its own height, and the words follow it */
  .hero { height: auto; min-height: 0; overflow: visible; }
  #stage { position: relative; inset: auto; height: min(118vw, 520px); }
  .name { position: static; padding: 6px 16px 26px; }
  .name .line { display: block; margin-top: 12px; }
  .name .line p { font-size: 15.5px; margin-bottom: 10px; }
  .name .line .label { white-space: normal; }
  #card { position: static; transform: none; width: auto; margin: 0 16px 20px; display: none; }
  .focused #card { display: block; }
  #card h2 { font-size: 26px; }
  .top { padding: 16px 16px; }
  .top nav { gap: 18px; }
  .page { padding: 40px 16px 30px; }
  .prose { font-size: 17px; }
}
