@font-face {
  font-family: "Big Shoulders Display";
  src: url("/fonts/big-shoulders-display.woff2") format("woff2");
  font-weight: 600 800;
  font-display: swap;
}
@font-face {
  font-family: "Schibsted Grotesk";
  src: url("/fonts/schibsted-grotesk.woff2") format("woff2");
  font-weight: 400 600;
  font-display: swap;
}

/* Scorebook paper: cool grey-green page, ink, one red for the plotted "hits". */
:root {
  --paper: #edf0ea;
  --ink: #18232b;
  --muted: #56636a;
  --grid: #dde2da;
  --rule: #b9c2b6;
  --surface: #2f5d4f;
  --signal: #c42e37;
  --display: "Big Shoulders Display", "Arial Narrow", sans-serif;
  --text: "Schibsted Grotesk", system-ui, sans-serif;
  --gutter: clamp(16px, 5vw, 64px);
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #10171b;
    --ink: #e3e8e1;
    --muted: #9aa69f;
    --grid: #182228;
    --rule: #2c3a40;
    --surface: #7fb39f;
    --signal: #f2615c;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background-color: var(--paper);
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 28px 28px;
  color: var(--ink);
  font: 400 1.0625rem/1.6 var(--text);
}

a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { text-decoration-color: var(--signal); }
a:focus-visible { outline: 2px solid var(--signal); outline-offset: 3px; border-radius: 2px; }

.bar, main, .legal { max-width: 72rem; margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }

.bar {
  display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap;
  padding-top: 1.5rem; padding-bottom: 1.5rem;
}
.wordmark {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font: 800 1.5rem/1 var(--display); letter-spacing: 0.01em; text-decoration: none;
}
.wordmark svg { color: var(--surface); }
.bar-link { font-size: 0.9375rem; color: var(--muted); }

.hero { padding: clamp(3rem, 9vw, 7.5rem) 0 clamp(2rem, 5vw, 3.5rem); }
h1 {
  font: 800 clamp(2.75rem, 7.4vw, 6.25rem)/0.94 var(--display);
  letter-spacing: -0.005em;
  max-width: 17ch;
  margin: 0 0 1.75rem;
}
.lede { max-width: 36rem; margin: 0; font-size: clamp(1.0625rem, 1.6vw, 1.25rem); color: var(--muted); }

/* The three playing surfaces, drawn as plans with plotted data. */
.plans {
  margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1rem, 3vw, 2.5rem);
  padding: clamp(1.5rem, 3vw, 2.5rem) 0;
  border-top: 2px solid var(--ink); border-bottom: 1px solid var(--rule);
}
.plan svg { display: block; width: 100%; height: auto; overflow: visible; }
.plan figcaption { margin-top: 0.75rem; font: 700 1.25rem/1 var(--display); letter-spacing: 0.02em; }
.lines { fill: none; stroke: var(--surface); stroke-width: 1.2; vector-effect: non-scaling-stroke; }
.lines .red { stroke: var(--signal); stroke-opacity: 0.55; }
.lines .spot { fill: var(--surface); stroke: none; }
.data circle { fill: var(--ink); fill-opacity: 0.78; }
.data .hit { fill: var(--signal); fill-opacity: 1; }

@media (prefers-reduced-motion: no-preference) {
  .data circle { transform-box: fill-box; transform-origin: center; animation: plot 420ms cubic-bezier(.2,.9,.3,1.4) both; }
  .data circle:nth-child(1) { animation-delay: 300ms; }
  .data circle:nth-child(2) { animation-delay: 360ms; }
  .data circle:nth-child(3) { animation-delay: 420ms; }
  .data circle:nth-child(4) { animation-delay: 480ms; }
  .data circle:nth-child(5) { animation-delay: 540ms; }
  .data circle:nth-child(6) { animation-delay: 600ms; }
  .data circle:nth-child(7) { animation-delay: 660ms; }
  .data circle:nth-child(8) { animation-delay: 720ms; }
  .data circle:nth-child(9) { animation-delay: 780ms; }
  .data circle:nth-child(10) { animation-delay: 840ms; }
  .data circle:nth-child(11) { animation-delay: 900ms; }
  .data circle:nth-child(12) { animation-delay: 960ms; }
  .plan:nth-child(2) .data circle { animation-duration: 460ms; }
  .plan:nth-child(3) .data circle { animation-duration: 500ms; }
}
@keyframes plot { from { transform: scale(0); opacity: 0; } }

h2 { font: 700 clamp(1.75rem, 3.2vw, 2.5rem)/1 var(--display); margin: 0 0 1.5rem; }

.work { padding: clamp(3rem, 7vw, 5.5rem) 0 0; }
.work-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1.25rem, 3vw, 2.5rem); }
.work-cols p { margin: 0; max-width: 34ch; }

.contact { padding: clamp(3rem, 7vw, 5.5rem) 0 clamp(3rem, 7vw, 5rem); }
.contact p { margin: 0 0 1rem; color: var(--muted); }
.mail {
  font: 700 clamp(1.75rem, 5vw, 3.25rem)/1.05 var(--display);
  text-decoration: none; border-bottom: 3px solid var(--signal); overflow-wrap: anywhere;
}
.mail:hover { color: var(--signal); }

.legal {
  padding-bottom: 2.5rem;
  font-size: 0.875rem; color: var(--muted);
}
.legal::before { content: ""; display: block; border-top: 1px solid var(--rule); margin-bottom: 1.5rem; }
.legal p { margin: 0 0 0.25rem; max-width: 60rem; }
.legal strong { color: var(--ink); font-weight: 600; }

/* 404 */
.lost { padding: clamp(4rem, 12vw, 9rem) 0; }
.lost p { color: var(--muted); max-width: 32rem; }

@media (max-width: 760px) {
  .plans { grid-template-columns: 1fr; }
  .plan { max-width: 26rem; }
  .work-cols { grid-template-columns: 1fr; }
}

.sprite { position: absolute; }
