:root {
  --nes-sky: #c5e4f5;
  --nes-sky-deep: #a8d1e7;
  --nes-ice: #e8f4fb;
  --nes-ink: #0b3d5c;
  --nes-teal: #007cb0;
  --nes-navy: #0b1f33;
  --nes-cyan: #7ec8e3;
  --nes-white: #ffffff;
  --nes-muted: rgba(11, 61, 92, 0.62);
  --nes-font: "Outfit", "Avenir Next", "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--nes-font);
  color: var(--nes-ink);
  background:
    radial-gradient(1200px 600px at 10% -10%, rgba(126, 200, 227, 0.45), transparent 60%),
    linear-gradient(180deg, var(--nes-sky) 0%, var(--nes-ice) 45%, #f7fbfe 100%);
  line-height: 1.55;
}

a { color: var(--nes-teal); text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { color: var(--nes-ink); }

.wrap {
  width: min(760px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 2.5rem 0 4rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--nes-ink);
  text-decoration: none;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 600;
  font-size: 0.85rem;
}

.brand svg { width: 28px; height: 36px; }

.tag {
  margin: 1.25rem 0 0.35rem;
  color: var(--nes-teal);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

h1 {
  margin: 0 0 1rem;
  font-size: clamp(1.8rem, 4vw, 2.4rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
}

h2 {
  margin: 2rem 0 0.6rem;
  font-size: 1.15rem;
  color: var(--nes-navy);
}

p, li { color: var(--nes-ink); }
.lead { font-size: 1.05rem; color: var(--nes-muted); }

.card {
  margin-top: 1.25rem;
  padding: 1.15rem 1.25rem;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(11, 61, 92, 0.1);
  border-radius: 18px;
}

nav.toc {
  display: grid;
  gap: 0.55rem;
  margin-top: 1.25rem;
}

nav.toc a {
  display: block;
  padding: 0.85rem 1rem;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(11, 61, 92, 0.1);
  border-radius: 14px;
  color: var(--nes-ink);
  text-decoration: none;
  font-weight: 500;
}

nav.toc a:hover { border-color: rgba(0, 124, 176, 0.45); }

.meta {
  margin-top: 2rem;
  font-size: 0.9rem;
  color: var(--nes-muted);
}

footer {
  margin-top: 2.5rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(11, 61, 92, 0.12);
  color: var(--nes-muted);
  font-size: 0.9rem;
}
