/* ───────────────────────────────────────────────────────────────────────────
   groovemark.app — the shared site stylesheet (2026-09-16, the site rebuild).
   ONE copy of the tokens, the base, the header and the footer for every page
   (index, groovemark, gp-33, help + its articles, privacy, terms). Page-specific
   rules stay inline in each page. Tokens are copied from static/style.css :root
   — never retyped from memory (style-guide § 2).
   The header is the apps' own (Derek, 2026-09-15): the groove-maze mark + the
   GROOVEMARK wordmark upper-left, Help / GMK-1 / GP-33 upper-right beside the
   handle. The mark's path is copied from static/index.html's .brand-mark
   (canonical: ~/grooveplay/assets/gmk-mark.svg).
   ─────────────────────────────────────────────────────────────────────────── */

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

:root {
  --bg: #0e0e0e;
  --surface: #1a1a1a;
  --border: #2e2e2e;
  --text: #f0f0f0;
  --muted: #888;
  --accent: #e8d5a3;
  --accent-dim: #c4b07a;
  --danger: #e05c5c;
  --success: #5ce06a;
  --radius: 10px;
  --font: 'Courier New', Courier, monospace;
}

html, body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.6;
}

/* The page scrolls normally; the header holds the top edge; the footer arrives at
   the end of the content. MIN-height, never height (the iOS 100vh lesson, 2026-07-22). */
body { min-height: 100vh; display: flex; flex-direction: column; }
main { flex: 1 0 auto; }
html, main { scroll-behavior: smooth; }

/* ── The header ── */
header.site {
  position: sticky; top: 0; z-index: 50;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  padding: 1.25rem 2rem;
  display: flex; align-items: center; justify-content: space-between; gap: 1.5rem;
}
.brand { display: flex; align-items: center; gap: 14px; color: var(--text); text-decoration: none; border-bottom: none; }
.brand-mark { color: var(--accent); display: flex; }
.brand-mark svg { width: 30px; height: 30px; display: block; }
.wordmark {
  font-size: 22px;
  letter-spacing: 0.24em;
  font-weight: 700;
  line-height: 1;
  color: var(--text);
}
.brand:hover .wordmark, .brand:focus-visible .wordmark { color: var(--accent); }
.brand:focus-visible { outline: 1px solid var(--accent); outline-offset: 4px; }

.site-nav { display: flex; align-items: center; gap: 1.6rem; }
.site-nav a {
  font-size: 13px; letter-spacing: 0.1em; font-weight: 700;
  color: var(--muted); text-decoration: none; border-bottom: none;   /* privacy/terms style every `a` with a rule; the nav opts out */
  transition: color 0.15s;
}
.site-nav a:hover, .site-nav a:focus-visible { color: var(--accent); }
.site-nav a[aria-current="page"] { color: var(--text); }
.site-nav a:focus-visible { outline: 1px solid var(--accent); outline-offset: 3px; }
/* The handle: quieter than the three page links, and last. */
.site-nav .handle { font-size: 12px; font-weight: normal; letter-spacing: 0.05em; margin-left: 0.4rem; }

@media (max-width: 640px) {
  header.site { padding: 1rem 1.25rem; gap: 1rem; }
  .brand { gap: 10px; }
  .brand-mark svg { width: 24px; height: 24px; }
  .wordmark { font-size: 17px; letter-spacing: 0.18em; }
  .site-nav { gap: 1rem; }
  .site-nav a { font-size: 12px; }
  .site-nav .handle { display: none; }
}

/* ── The footer ── */
footer.site {
  flex: none;
  border-top: 1px solid var(--border);
  padding: 1.25rem 2rem;
  display: flex; justify-content: space-between; align-items: baseline;
  font-size: 12px; color: var(--muted); letter-spacing: 0.05em;
  background: var(--bg);
}
footer.site a { color: var(--muted); text-decoration: none; border-bottom: none; }
footer.site a:hover, footer.site a:focus-visible { color: var(--accent); }
@media (max-width: 700px) {
  footer.site {
    flex-direction: column; align-items: center; gap: 0.4rem; text-align: center;
    padding-bottom: calc(1.25rem + env(safe-area-inset-bottom));
  }
}
