/* Design tokens. The colours, fonts, radius and shadow below are grey placeholders, not a design:
   replace every one with the values from your design plan. Shipping them unchanged is a defect. */
:root {
  --bg: #061a33;
  --surface: #0a2547;
  --ink: #e6fbff;
  --ink-soft: #9fc3d9;
  --line: #1d4a75;
  --accent: #00e5ff;
  --accent-ink: #031225;
  --amber: #ffb000;
  --amber-ink: #1a1000;
  --alert: #ff8a9a;
  --glow: 0 0 6px rgba(0, 229, 255, 0.55);

  --font-display: "Silkscreen", "JetBrains Mono", monospace;
  --font-text: "Archivo", "Helvetica Neue", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, Menlo, Consolas, monospace;

  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 1rem;
  --space-4: 1.5rem;
  --space-5: 2.5rem;
  --space-6: 4rem;

  --radius: 0px;
  --wrap: 76rem;
  --shadow: 0 0 0 1px var(--line), 0 0 18px rgba(0, 229, 255, 0.08);
  color-scheme: dark;
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-text);
  font-size: 1.0625rem;
  line-height: 1.6;
}

main {
  flex: 1;
  padding-block: var(--space-5);
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  line-height: 1.15;
  margin: 0 0 var(--space-3);
  text-wrap: balance;
}

h1 {
  font-size: clamp(2.2rem, 6vw, 3.6rem);
}

h2 {
  font-size: clamp(1.6rem, 4vw, 2.3rem);
  margin-top: var(--space-5);
}

h3 {
  font-size: 1.25rem;
}

p {
  margin: 0 0 var(--space-3);
  max-width: 65ch;
}

a {
  color: var(--accent);
}

img,
svg,
canvas,
video {
  max-width: 100%;
  height: auto;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--space-3);
}

.skip {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--accent);
  color: var(--accent-ink);
  padding: var(--space-2) var(--space-3);
}

.skip:focus {
  left: 0;
  z-index: 10;
}

.site-header {
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  flex-wrap: wrap;
  padding-block: var(--space-3);
}

.brand {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
}

.site-nav {
  display: flex;
  gap: var(--space-3);
  flex-wrap: wrap;
}

.site-nav a {
  color: var(--ink-soft);
  text-decoration: none;
  padding: var(--space-1) 0;
  border-bottom: 2px solid transparent;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--ink);
  border-bottom-color: var(--accent);
}

/* The phone menu. Restyle it freely, but keep the structure: .nav-toggle right before the nav it
   controls, and its aria-expanded deciding whether the links show. Without JavaScript (no .js on
   <html>) the toggle stays hidden and the links stay visible. */
.nav-toggle {
  display: none;
}

@media (max-width: 720px) {
  .js .nav-toggle {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 0 var(--space-3);
    background: transparent;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    cursor: pointer;
  }

  .js .nav-toggle ~ .site-nav {
    display: none;
    flex-basis: 100%;
    flex-direction: column;
    gap: 0;
  }

  .js .nav-toggle[aria-expanded="true"] ~ .site-nav {
    display: flex;
  }

  .site-nav a {
    display: flex;
    align-items: center;
    min-height: 44px;
  }
}

.site-footer {
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 0.95rem;
  padding-block: var(--space-4);
}

.site-footer p {
  margin: 0;
}

.button {
  display: inline-block;
  background: var(--accent);
  color: var(--accent-ink);
  border: 0;
  border-radius: var(--radius);
  padding: 0.7rem 1.2rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
}

.button:hover {
  filter: brightness(1.08);
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--space-4);
  box-shadow: var(--shadow);
}

.grid {
  display: grid;
  gap: var(--space-4);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr));
}

.scroll-x {
  overflow-x: auto;
}

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

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}
