/* Grindvale legal pages (tools/web/grindvale, served from /var/www/grindvale by Caddy on grindvale.demonfork.io).
   Black and white, Resurrect 64 greys, red only for danger. Self-hosted Barlow (SIL OFL 1.1, fonts/Barlow-OFL.txt). */
@font-face { font-family: "Barlow"; font-weight: 500; src: url("/fonts/barlow-500.woff") format("woff"); font-display: swap; }
@font-face { font-family: "Barlow"; font-weight: 600; src: url("/fonts/barlow-600.woff") format("woff"); font-display: swap; }
@font-face { font-family: "Barlow Condensed"; font-weight: 700; src: url("/fonts/barlow-condensed-700.woff") format("woff"); font-display: swap; }

:root {
  color-scheme: dark;
  --bg: #0e0d10;
  --plate: #2e222f;
  --slate: #3e3546;
  --line: #625565;
  --ink: #ffffff;
  --text: #c7dcd0;
  --muted: #9babb2;
  --dim: #7f708a;
  --danger: #e83b3b;
  --danger-deep: #ae2334;
  --gutter: 16px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--text);
  font: 500 17px/1.65 "Barlow", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  overflow-wrap: break-word;
}
main { flex: 1 0 auto; }
.wrap { width: 100%; max-width: 820px; margin: 0 auto; padding: 0 var(--gutter); }
@media (min-width: 720px) { :root { --gutter: 32px; } }

a { color: var(--ink); text-decoration-color: var(--line); text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--ink); }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
strong, b { color: var(--ink); font-weight: 600; }
code { font-family: ui-monospace, Consolas, monospace; font-size: 0.9em; color: var(--ink); }

/* ---------- header band ---------- */
.top { border-bottom: 1px solid var(--slate); }
.bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 24px; padding-top: 12px; padding-bottom: 12px; }
.brand {
  display: inline-flex; align-items: center; gap: 12px; min-height: 44px;
  font: 700 22px/1 "Barlow Condensed", sans-serif; letter-spacing: 0.28em; text-transform: uppercase;
  color: var(--ink); text-decoration: none;
}
.brand::before { content: ""; width: 8px; height: 8px; background: var(--ink); transform: rotate(45deg); flex: none; }
.brand span { font: 600 13px/1 "Barlow", sans-serif; letter-spacing: 0.08em; text-transform: none; color: var(--dim); }
.tabs { display: flex; flex-wrap: wrap; gap: 0 20px; }
.tabs a {
  display: inline-flex; align-items: center; min-height: 44px;
  font: 700 15px/1 "Barlow Condensed", sans-serif; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--muted); text-decoration: none; border-bottom: 2px solid transparent;
}
.tabs a:hover { color: var(--ink); }
.tabs a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--ink); }

/* ---------- page ---------- */
.legal { padding-top: 40px; padding-bottom: 72px; }
.kicker {
  display: flex; align-items: center; gap: 12px; margin: 0 0 14px;
  font: 700 13px/1 "Barlow Condensed", sans-serif; letter-spacing: 0.24em; text-transform: uppercase; color: var(--muted);
}
.kicker::after { content: ""; flex: 1; height: 1px; background: var(--slate); }
h1 {
  margin: 0 0 8px; color: var(--ink);
  font: 700 34px/1.1 "Barlow Condensed", sans-serif; letter-spacing: 0.06em; text-transform: uppercase;
}
@media (min-width: 720px) { h1 { font-size: 44px; } }
h2 {
  margin: 44px 0 10px; color: var(--ink);
  font: 700 21px/1.25 "Barlow Condensed", sans-serif; letter-spacing: 0.1em; text-transform: uppercase;
}
h3 { margin: 26px 0 6px; color: var(--ink); font: 600 18px/1.35 "Barlow", sans-serif; }
p { margin: 0 0 14px; }
ul, ol { margin: 0 0 14px; padding-left: 1.3rem; }
li { margin: 6px 0; }
.meta { color: var(--dim); margin: 0 0 28px; }
.small { font-size: 15px; color: var(--dim); }
hr { border: 0; border-top: 1px solid var(--slate); margin: 36px 0; }
section { scroll-margin-top: 16px; }

/* thin L corners (ornament) on the summary boxes, no full border */
.box { position: relative; background: var(--plate); padding: 18px 20px; margin: 24px 0; }
.box > :last-child { margin-bottom: 0; }
.box .label { display: block; margin: 0 0 8px; font: 700 14px/1 "Barlow Condensed", sans-serif; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink); }
.corners {
  --c: var(--muted);
  --k: 14px;
  background:
    linear-gradient(var(--c), var(--c)) top left / var(--k) 1px no-repeat,
    linear-gradient(var(--c), var(--c)) top left / 1px var(--k) no-repeat,
    linear-gradient(var(--c), var(--c)) top right / var(--k) 1px no-repeat,
    linear-gradient(var(--c), var(--c)) top right / 1px var(--k) no-repeat,
    linear-gradient(var(--c), var(--c)) bottom left / var(--k) 1px no-repeat,
    linear-gradient(var(--c), var(--c)) bottom left / 1px var(--k) no-repeat,
    linear-gradient(var(--c), var(--c)) bottom right / var(--k) 1px no-repeat,
    linear-gradient(var(--c), var(--c)) bottom right / 1px var(--k) no-repeat,
    var(--plate);
}
.danger { border-left: 3px solid var(--danger-deep); }
.danger .label { color: var(--danger); }

.steps { counter-reset: step; list-style: none; padding-left: 0; }
.steps li { counter-increment: step; position: relative; padding-left: 44px; min-height: 32px; margin: 12px 0; }
.steps li::before {
  content: counter(step); position: absolute; left: 0; top: 0;
  width: 30px; height: 30px; display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--muted); color: var(--ink); font: 700 16px/1 "Barlow Condensed", sans-serif;
}

.toc ul { list-style: none; padding-left: 0; columns: 2 220px; column-gap: 24px; }
.toc li { margin: 0 0 6px; break-inside: avoid; }
.toc a { color: var(--muted); text-decoration: none; }
.toc a:hover { color: var(--ink); text-decoration: underline; }

.cards { display: grid; gap: 12px; margin: 28px 0; }
@media (min-width: 640px) { .cards { grid-template-columns: repeat(3, 1fr); } }
.cards a { display: block; padding: 18px 20px; background: var(--plate); text-decoration: none; color: var(--text); }
.cards a:hover { background: var(--slate); }
.cards strong { display: block; margin-bottom: 4px; font: 700 18px/1.2 "Barlow Condensed", sans-serif; letter-spacing: 0.1em; text-transform: uppercase; }

/* ---------- footer ---------- */
.foot { border-top: 1px solid var(--slate); padding: 22px 0 28px; color: var(--dim); font-size: 15px; }
.foot nav { display: flex; flex-wrap: wrap; gap: 4px 20px; margin-bottom: 8px; }
.foot nav a { display: inline-flex; align-items: center; min-height: 40px; color: var(--muted); text-decoration: none; }
.foot nav a:hover { color: var(--ink); }
