/* DiscWright - discwright.com
   One page, no build step, no third-party requests. Dark by design: the
   subject is a disc in a drive bay, and the screenshots are dark too. */

:root {
  --bg:        #0d0d10;
  --bg-lift:   #15151a;
  --bg-sunk:   #0a0a0c;
  --line:      #262630;
  --line-soft: #1c1c24;
  --ink:       #e8e6e1;
  --ink-dim:   #a29e96;
  --ink-faint: #6f6b64;
  --gold:      #d9a441;   /* the dye side of a pressed disc */
  --gold-lift: #f0be5f;
  --radius:    10px;
  --page:      1040px;
  --text:      44rem;

  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.65 system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: var(--gold); text-decoration-color: rgba(217,164,65,.35); text-underline-offset: 2px; }
a:hover { color: var(--gold-lift); text-decoration-color: currentColor; }

code, pre, .tree {
  font-family: ui-monospace, "Cascadia Mono", Consolas, "SF Mono", Menlo, monospace;
}

code {
  font-size: .875em;
  background: var(--bg-sunk);
  border: 1px solid var(--line-soft);
  border-radius: 4px;
  padding: .1em .35em;
  color: #cfc9be;
  /* setup_alan_wake_1.1_music_lang_fix_(80728).exe is one unbroken token and
     wider than a phone. anywhere lets it break mid-word rather than push the
     page sideways; break-word alone will not break a token this long. */
  overflow-wrap: anywhere;
}

.dim { color: var(--ink-dim); }

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

header.site {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  flex-wrap: wrap;
  gap: .5rem 1.5rem;
  align-items: center;
  justify-content: space-between;
  padding: .85rem clamp(1rem, 4vw, 2.5rem);
  background: rgba(13,13,16,.82);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line-soft);
}

.wordmark {
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: .01em;
  color: var(--ink);
  text-decoration: none;
}
.wordmark span { color: var(--gold); }

header.site nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  font-size: .9rem;
}
header.site nav a { color: var(--ink-dim); text-decoration: none; }
header.site nav a:hover { color: var(--ink); }
header.site nav a.gh { color: var(--gold); }

main { display: block; }

section {
  max-width: var(--page);
  margin: 0 auto;
  padding: clamp(3rem, 8vw, 5.5rem) clamp(1rem, 4vw, 2.5rem);
  border-top: 1px solid var(--line-soft);
}
section:first-child { border-top: 0; }

h1, h2, h3 { line-height: 1.2; letter-spacing: -.015em; margin: 0 0 .6em; }

h2 {
  font-size: clamp(1.5rem, 3.2vw, 2rem);
  margin-bottom: 1.4rem;
}

h3 { font-size: 1.05rem; }

p { margin: 0 0 1.1rem; }
.wide-text { max-width: var(--text); }

/* --------------------------------------------------------------- hero -- */

.hero {
  position: relative;
  text-align: center;
  padding-top: clamp(3.5rem, 10vw, 6rem);
  overflow: hidden;
}

/* A disc, drawn in CSS and turned almost all the way down. */
.rings {
  position: absolute;
  top: -22rem;
  left: 50%;
  width: 62rem;
  height: 62rem;
  margin-left: -31rem;
  pointer-events: none;
  background:
    radial-gradient(closest-side, rgba(217,164,65,.10), rgba(217,164,65,0) 70%),
    repeating-radial-gradient(circle at 50% 50%,
      rgba(232,230,225,.05) 0 1px, rgba(232,230,225,0) 1px 9px);
  -webkit-mask-image: radial-gradient(closest-side, #000 40%, transparent 72%);
          mask-image: radial-gradient(closest-side, #000 40%, transparent 72%);
}

.hero > *:not(.rings) { position: relative; }

.hero h1 {
  font-size: clamp(2rem, 6vw, 3.4rem);
  max-width: 18ch;
  margin-inline: auto;
}

.lede {
  max-width: 40rem;
  margin: 0 auto 2rem;
  font-size: clamp(1.05rem, 2.2vw, 1.25rem);
  color: var(--ink-dim);
}

.fineprint {
  font-size: .85rem;
  color: var(--ink-faint);
  margin-top: 1rem;
}

/* -------------------------------------------------------------- links -- */

.cta {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  justify-content: center;
  margin: 0;
}

.cards + .cta { margin-top: 2.5rem; }

.btn {
  display: inline-block;
  padding: .7rem 1.4rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-lift);
  color: var(--ink);
  font-weight: 600;
  font-size: .95rem;
  text-decoration: none;
  transition: border-color .15s, background .15s, transform .15s;
}
.btn:hover { border-color: #3a3a46; background: #1b1b22; color: var(--ink); transform: translateY(-1px); }

.btn.primary {
  background: var(--gold);
  border-color: var(--gold);
  color: #241a06;
}
.btn.primary:hover { background: var(--gold-lift); border-color: var(--gold-lift); color: #241a06; }

@media (prefers-reduced-motion: reduce) { .btn:hover { transform: none; } }

/* ---------------------------------------------------------- figures --- */

.shot { margin: 2.5rem 0 0; }
.shot img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-sunk);
  box-shadow: 0 18px 50px -20px rgba(0,0,0,.9);
}
.shot figcaption {
  margin-top: .8rem;
  font-size: .85rem;
  color: var(--ink-faint);
  text-align: center;
}
/* Capped at each recording's natural size - upscaling a screen capture only
   makes it blurry. disc.gif is 676x506; the app-window captures are 672x967,
   and a portrait frame that wide would run past the fold on its own. */
.shot.landscape { max-width: 676px; margin-inline: auto; }
.shot.tall      { max-width: 480px; margin-inline: auto; }
.split .shot    { max-width: 480px; }

/* ---------------------------------------------------------- sections -- */

.prose p { max-width: var(--text); }

/* 20rem is wide enough that the page never fits three across, so four cards
   land as a 2x2 block instead of three and a lonely one. */
.cards {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 20rem), 1fr));
}

.card {
  padding: 1.4rem;
  background: var(--bg-lift);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
}
.card h3 { color: var(--gold); }
.card p { margin: 0; color: var(--ink-dim); font-size: .95rem; }

/* A card that ends in links keeps them on its bottom edge, so a row of
   cards lines its links up however uneven the paragraphs above are. */
.card { display: flex; flex-direction: column; }
.card .go {
  display: flex;
  flex-wrap: wrap;
  gap: .35rem 1.25rem;
  margin-top: auto;
  padding-top: 1rem;
  font-weight: 600;
}
.card .go a { text-decoration: none; white-space: nowrap; }
.card .go a:hover { text-decoration: underline; }

.split {
  display: grid;
  gap: clamp(1.5rem, 4vw, 3rem);
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  align-items: start;
}
@media (max-width: 800px) { .split { grid-template-columns: 1fr; } }
.split .shot { margin-top: 0; }

.steps {
  list-style: none;
  counter-reset: step;
  margin: 0;
  padding: 0;
}
.steps li {
  counter-increment: step;
  position: relative;
  padding: 0 0 1.6rem 3.2rem;
}
.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: -.1rem;
  width: 2.1rem;
  height: 2.1rem;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--bg-lift);
  color: var(--gold);
  font-size: .9rem;
  font-weight: 700;
}
.steps li:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 1.05rem;
  top: 2.3rem;
  bottom: .4rem;
  border-left: 1px solid var(--line-soft);
}
.steps p { margin: 0; color: var(--ink-dim); font-size: .95rem; }

/* The disc tree. Wide content scrolls inside its own box, never the page. */
pre.tree {
  max-width: var(--page);
  margin: 0 0 1.1rem;
  padding: 1.25rem;
  overflow-x: auto;
  background: var(--bg-sunk);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  font-size: .82rem;
  line-height: 1.75;
  color: #c9c3b8;
  tab-size: 2;
}
pre.tree code { background: none; border: 0; padding: 0; font-size: inherit; color: inherit; }

table.media {
  border-collapse: collapse;
  margin-top: 2rem;
  font-size: .92rem;
}
table.media caption {
  text-align: left;
  padding-bottom: .6rem;
  color: var(--ink-faint);
  font-size: .85rem;
  text-transform: uppercase;
  letter-spacing: .08em;
}
table.media td {
  padding: .45rem 2.5rem .45rem 0;
  border-bottom: 1px solid var(--line-soft);
}
table.media td:first-child { color: var(--ink-dim); white-space: nowrap; }

ul.limits { padding-left: 1.15rem; }
ul.limits li { margin-bottom: .9rem; color: var(--ink-dim); }
ul.limits strong { color: var(--ink); }
ul.limits::marker, ul.limits li::marker { color: var(--gold); }

/* -------------------------------------------------------------- foot -- */

footer.site {
  max-width: var(--page);
  margin: 0 auto;
  padding: 3rem clamp(1rem, 4vw, 2.5rem) 4rem;
  border-top: 1px solid var(--line-soft);
  color: var(--ink-faint);
  font-size: .88rem;
}
footer.site nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  margin-bottom: 1.5rem;
}
footer.site p { max-width: var(--text); }
footer.site .disclaimer { font-size: .8rem; line-height: 1.6; }
footer.site .disclaimer strong { color: var(--ink-dim); }
