/* Shared by every page but the deck: the page frame, the header, the footer and the mark. */
:root {
  --page: 1240px;
  --edge: max(16px, env(safe-area-inset-left, 0px), clamp(16px, 4.2vw, 48px));
}
  /* the mark's lowest stripe, the tack's head and the "OS" are lilac in both themes */
  :root { --band-1: #8fa1ff; --band-1-ink: #0e131b; }
  [data-theme="light"] { --pin-hl: #e2e7fb; }
  [data-theme="dark"] { --pin-hl: #e6ebf2; }

  html { -webkit-text-size-adjust: 100%; }
  @media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
  body { margin: 0; background: var(--bg); color: var(--ink); font-size: var(--fs-b); -webkit-font-smoothing: antialiased; overflow-x: clip; }
  .wrap { width: 100%; max-width: calc(var(--page) + 2 * var(--edge)); margin-inline: auto; padding-inline: var(--edge); }
  .vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .skip { position: absolute; left: var(--edge); top: -60px; background: var(--accent); color: var(--accent-ink) !important; padding: .5em .9em; border-radius: var(--r-button); z-index: 20; }
  .skip:focus { top: 8px; }
  .gh { display: inline-flex; align-items: center; gap: .5em; }

  .b1 { fill: var(--band-1); } .b2 { fill: var(--l2); } .b3 { fill: var(--l3); } .b4 { fill: var(--l4); }
  .needle { fill: var(--ink); } .ball { fill: var(--band-1); } .shine { fill: var(--pin-hl); }

  /* ---------- navigation ---------- */
  .nav { display: flex; align-items: center; justify-content: space-between; gap: var(--gap); padding-block: 14px; }
  .brand.wordmark.inline { font-size: 1.5rem; color: var(--ink); text-decoration: none; }
  /* the mark follows the name; no flex gap, so "tack" and "OS" stay one word */
  .wordmark.inline { gap: 0; }
  .wordmark span { color: var(--band-1); }
  .wordmark.inline .logo { margin-left: .14em; }
  .brand .logo { width: 1.2em; height: 1.2em; }
  .nav-links { display: none; gap: 1.8em; font-family: var(--font-mono); font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .06em; }
  .nav-links a { color: var(--muted); text-decoration: none; }
  .nav-links a:hover { color: var(--ink); }
  @media (min-width: 860px) { .nav-links { display: flex; } }
  /* the deck, for walking a team through tackOS */
  .btn.deck { border-color: var(--accent); color: var(--accent) !important; }
  .btn.deck .ico { margin: 0; width: 1.15em; height: 1.15em; --hue: currentColor; --hue-bg: none; }
  .btn.deck .long { display: none; }
  @media (min-width: 1100px) { .btn.deck .long { display: inline; } .btn.deck .short { display: none; } }
  .nav .btn { white-space: nowrap; }
  /* on a phone the theme follows the system, so the toggle makes room for the deck */
  @media (max-width: 479px) { .btn.deck .ico { display: none; } .nav .seg { display: none; } }
  .nav-end { display: flex; align-items: center; gap: 10px; }
  .btn { display: inline-flex; align-items: center; gap: .5em; font-family: var(--font-mono); font-size: var(--fs-xs); font-weight: 500; text-transform: uppercase; letter-spacing: .06em; text-decoration: none; padding: .62em .9em; border-radius: var(--r-button); border: 1px solid var(--line); color: var(--ink) !important; background: var(--surface); }
  .btn:hover { border-color: var(--accent); }
  .seg { display: inline-flex; border: 1px solid var(--line); border-radius: var(--r-button); overflow: hidden; background: var(--surface); }
  .seg button { font-family: var(--font-mono); font-size: var(--fs-xs); font-weight: 500; text-transform: uppercase; letter-spacing: .06em; padding: .62em .8em; background: none; border: 0; color: var(--muted); cursor: pointer; }
  .seg button[aria-pressed="true"] { background: var(--sunk); color: var(--ink); }
  @media (max-width: 479px) { .nav { gap: 8px; } .nav-end { gap: 6px; } .nav .btn, .seg button { padding-inline: .6em; letter-spacing: .03em; } .brand.wordmark.inline { font-size: 1.3rem; } }

  /* ---------- footer ---------- */
  .tk .foot { border-top: 1px solid var(--line); padding-block: 44px 36px; }
  .tk .foot-grid { display: grid; grid-template-columns: 1fr; gap: 32px; }
  @media (min-width: 720px) { .tk .foot-grid { grid-template-columns: 2fr 1fr 1fr; } }
  .tk .foot .wordmark.inline { font-size: 1.25rem; color: var(--ink); text-decoration: none; }
  .tk .foot-tag { margin: 14px 0 16px; color: var(--ink); }
  .tk .foot-tag .t1 { color: var(--band-1); } .tk .foot-tag .t2 { color: var(--l2); } .tk .foot-tag .t3 { color: var(--l3); }
  .tk .foot-icon { color: var(--muted) !important; display: inline-flex; }
  .tk .foot-icon:hover { color: var(--ink) !important; }
  .tk .foot-col { display: flex; flex-direction: column; gap: .7em; }
  .tk .foot-col h2 { font-size: var(--fs-b); font-weight: 600; margin: 0 0 .3em; }
  .tk .foot-col .c1 { color: var(--band-1); } .tk .foot-col .c2 { color: var(--l2); }
  .tk .foot-col a { color: var(--ink); text-decoration: none; }
  .tk .foot-col a:hover { color: var(--accent); }
  .tk .foot-copy { border-top: 1px solid var(--line); margin: 36px 0 0; padding-top: 24px; text-align: center; color: var(--muted); font-size: var(--fs-xs); }
  .foot-copy .heart { display: inline-block; margin-right: .3em; }

  /* ---------- legal pages ---------- */
  .legal { padding-block: 18px 72px; }
