/* Byteslip site navigation (2026-11-19).
   Metallic bulletin toolbar + slim monogram lockup for surface pages.
   Homepage keeps this toolbar inside the bulletin card; inner pages
   place it under the monogram row, constrained to the header width. */

/* Wordmark fallback when this sheet is used without site.css (notes). Harmless duplicate elsewhere. */
@font-face{font-family:'Space Grotesk';font-style:normal;font-weight:600;font-display:swap;src:url(/fonts/space-grotesk-v22-latin.woff2) format('woff2')}

/* ----- Inner-page chrome: monogram row + toolbar, not full-bleed ----- */
header.site-chrome {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  box-sizing: border-box;
  width: 100%;
  padding-left: 0;
  padding-right: 0;
  padding-bottom: 0;
  overflow-x: hidden;
  container-type: inline-size;
  container-name: site-nav;
}

.site-chrome-brand {
  display: flex;
  align-items: center;
  padding: 0 1.5rem 0.85rem;
  box-sizing: border-box;
  max-width: 100%;
}

/* Standalone pages without Tailwind max-width utilities (tools, 404). */
header.site-chrome.site-chrome-box {
  max-width: 980px;
  margin-left: auto;
  margin-right: auto;
  margin-top: 0;
  padding-top: 1.5rem;
}

/* Notes: sit inside .wrap and cancel the wrap's padding so the toolbar is flush. */
.wrap > header.site-chrome.site-chrome-in-wrap {
  margin: -1.5rem -1.25rem 1.5rem;
  width: auto;
  max-width: none;
}

.site-chrome-brand .bs-brand-head {
  font-family: "Space Grotesk", Inter, ui-sans-serif, system-ui, sans-serif;
  font-size: 1.5rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: #fff;
  text-decoration: none;
}

.site-chrome-brand .bs-brand-head:hover {
  color: #00f9ff;
}

/* Homepage: the toolbar lives in the bulletin card, which is narrower than the viewport. */
.bulletin:has(> nav.bulletin-toolbar) {
  container-type: inline-size;
  container-name: site-nav;
}

/* ----- Metallic toolbar ----- */
.bulletin-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  justify-content: center;
  gap: 1px;
  background: #0a0a0a;
  border-bottom: 1px solid rgba(0, 0, 0, 0.72);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 1px 0 rgba(255, 255, 255, 0.04);
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow-x: hidden;
  position: relative;
  z-index: 10;
}

/* Even 3×3 grid: nine links, no orphan row, no hamburger.
   Prefix beats leftover page rules such as `header a:first-child` (404, tools). */
header.site-chrome nav.bulletin-toolbar a,
nav.bulletin-toolbar a {
  flex: 1 1 calc(33.333% - 1px);
  min-width: 0;
  max-width: 100%;
  min-height: 44px;
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.35em;
  text-align: center;
  padding: 10px 8px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 11px;
  font-weight: 600;
  font-style: normal;
  line-height: 1.2;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
  color: rgba(255, 255, 255, 0.94);
  text-decoration: none;
  border: 0;
  background:
    linear-gradient(180deg,
      rgba(255, 255, 255, 0.16) 0%,
      rgba(255, 255, 255, 0.05) 10%,
      rgba(255, 255, 255, 0) 22%,
      rgba(0, 0, 0, 0.18) 62%,
      rgba(0, 0, 0, 0.42) 100%),
    linear-gradient(180deg, #555555 0%, #3a3a3a 40%, #262626 78%, #1a1a1a 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.3),
    inset 0 -1px 0 rgba(0, 0, 0, 0.55);
  text-shadow: 0 1px 0 rgba(0, 0, 0, 0.55);
  transition: color 0.15s ease, filter 0.15s ease, box-shadow 0.15s ease;
  overflow: hidden;
}

header.site-chrome nav.bulletin-toolbar a > span[aria-hidden="true"],
nav.bulletin-toolbar a > span[aria-hidden="true"] {
  font-size: 1em;
  font-weight: 400;
  font-style: normal;
  line-height: 1;
  letter-spacing: 0;
  text-shadow: none;
  transform: none;
  display: inline-block;
  flex: none;
}

header.site-chrome nav.bulletin-toolbar a:hover,
nav.bulletin-toolbar a:hover {
  color: #00f9ff;
  filter: brightness(1.1);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.38),
    inset 0 -2px 0 #00f9ff,
    0 0 10px rgba(0, 249, 255, 0.16);
  z-index: 1;
}

header.site-chrome nav.bulletin-toolbar a:active,
nav.bulletin-toolbar a:active {
  filter: brightness(0.94);
  box-shadow:
    inset 0 2px 5px rgba(0, 0, 0, 0.45),
    inset 0 -2px 0 #00f9ff;
}

header.site-chrome nav.bulletin-toolbar a:focus,
nav.bulletin-toolbar a:focus {
  outline: none;
}

header.site-chrome nav.bulletin-toolbar a:focus-visible,
header.site-chrome nav.bulletin-toolbar a[aria-current="page"]:focus-visible,
header.site-chrome nav.bulletin-toolbar a.tb-support:focus-visible,
header.site-chrome nav.bulletin-toolbar a.tb-apps:focus-visible,
header.site-chrome nav.bulletin-toolbar a.tb-games:focus-visible,
header.site-chrome nav.bulletin-toolbar a.tb-leaderboards:focus-visible,
nav.bulletin-toolbar a:focus-visible,
nav.bulletin-toolbar a[aria-current="page"]:focus-visible,
nav.bulletin-toolbar a.tb-support:focus-visible,
nav.bulletin-toolbar a.tb-apps:focus-visible,
nav.bulletin-toolbar a.tb-games:focus-visible,
nav.bulletin-toolbar a.tb-leaderboards:focus-visible {
  outline: 2px solid #00f9ff;
  outline-offset: -2px;
  z-index: 2;
  filter: none;
}

header.site-chrome nav.bulletin-toolbar a.tb-support,
nav.bulletin-toolbar a.tb-support {
  color: #ffc6e8;
  text-shadow: 0 1px 0 rgba(0, 0, 0, 0.55);
}

header.site-chrome nav.bulletin-toolbar a.tb-support:hover,
nav.bulletin-toolbar a.tb-support:hover {
  color: #ffe6f5;
  filter: brightness(1.1);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.38),
    inset 0 -2px 0 #ff7eb6,
    0 0 10px rgba(255, 110, 180, 0.16);
}

header.site-chrome nav.bulletin-toolbar a.tb-leaderboards,
nav.bulletin-toolbar a.tb-leaderboards {
  color: #ffd700;
  text-shadow: 0 0 6px rgba(255, 215, 0, 0.45);
  animation: tb-gold-pulse 2.5s ease-in-out infinite;
  letter-spacing: 0.1em;
}

header.site-chrome nav.bulletin-toolbar a.tb-leaderboards:hover,
nav.bulletin-toolbar a.tb-leaderboards:hover {
  color: #fff8dc;
  filter: brightness(1.1);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.38),
    inset 0 -2px 0 #ffd700,
    0 0 10px rgba(255, 215, 0, 0.2);
}

@keyframes tb-gold-pulse {
  0%, 100% { color: #ffd700; text-shadow: 0 0 4px rgba(255, 215, 0, 0.35); }
  50% { color: #fff2a8; text-shadow: 0 0 10px rgba(255, 242, 168, 0.8), 0 0 18px rgba(255, 215, 0, 0.45); }
}

header.site-chrome nav.bulletin-toolbar a.tb-apps,
nav.bulletin-toolbar a.tb-apps {
  color: #ffa8a8;
  text-shadow: 0 0 8px rgba(255, 40, 40, 0.7), 0 0 16px rgba(255, 60, 60, 0.4);
}

header.site-chrome nav.bulletin-toolbar a.tb-apps:hover,
nav.bulletin-toolbar a.tb-apps:hover {
  color: #ffd0d0;
  filter: brightness(1.1);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.38),
    inset 0 -2px 0 #ff6b6b,
    0 0 10px rgba(255, 40, 40, 0.24);
}

header.site-chrome nav.bulletin-toolbar a.tb-games,
nav.bulletin-toolbar a.tb-games {
  color: #8ad6ff;
  text-shadow: 0 0 8px rgba(40, 140, 255, 0.7), 0 0 16px rgba(80, 180, 255, 0.4);
}

header.site-chrome nav.bulletin-toolbar a.tb-games:hover,
nav.bulletin-toolbar a.tb-games:hover {
  color: #c4ecff;
  filter: brightness(1.1);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.38),
    inset 0 -2px 0 #6cc4ff,
    0 0 10px rgba(40, 140, 255, 0.24);
}

/* Current page: cyan, overrides accent colours. */
header.site-chrome nav.bulletin-toolbar a[aria-current="page"],
nav.bulletin-toolbar a[aria-current="page"] {
  color: #00f9ff;
  text-shadow: 0 0 8px rgba(0, 249, 255, 0.55);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.35),
    inset 0 -2px 0 #00f9ff,
    0 0 10px rgba(0, 249, 255, 0.16);
  animation: none;
  filter: none;
}

header.site-chrome nav.bulletin-toolbar a[aria-current="page"]:hover,
nav.bulletin-toolbar a[aria-current="page"]:hover {
  color: #fff;
  filter: brightness(1.06);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.35),
    inset 0 -2px 0 #00f9ff,
    0 0 10px rgba(0, 249, 255, 0.22);
}

header.site-chrome nav.bulletin-toolbar a[aria-current="page"]:active,
nav.bulletin-toolbar a[aria-current="page"]:active {
  filter: brightness(0.96);
}

/* Phones: stay on the 3×3 wrap, keep 44px taps, tighten tracking. No hamburger. */
@media (max-width: 560px) {
  header.site-chrome nav.bulletin-toolbar a,
  nav.bulletin-toolbar a {
    flex: 1 1 calc(33.333% - 1px);
    min-height: 44px;
    padding: 10px 4px;
    font-size: 10px;
    letter-spacing: 0.08em;
  }
  header.site-chrome nav.bulletin-toolbar a.tb-leaderboards,
  nav.bulletin-toolbar a.tb-leaderboards {
    letter-spacing: 0.04em;
  }
  .site-chrome-brand {
    padding-left: 1.1rem;
    padding-right: 1.1rem;
  }
}

@media (max-width: 360px) {
  header.site-chrome nav.bulletin-toolbar a,
  nav.bulletin-toolbar a {
    font-size: 9.5px;
    letter-spacing: 0.04em;
    padding: 10px 3px;
  }
  header.site-chrome nav.bulletin-toolbar a.tb-leaderboards,
  nav.bulletin-toolbar a.tb-leaderboards {
    letter-spacing: 0;
    font-size: 9px;
  }
}

@media (prefers-reduced-motion: reduce) {
  header.site-chrome nav.bulletin-toolbar a,
  nav.bulletin-toolbar a {
    transition: none;
  }
  header.site-chrome nav.bulletin-toolbar a.tb-leaderboards,
  nav.bulletin-toolbar a.tb-leaderboards {
    animation: none;
    color: #ffd700;
    text-shadow: 0 0 6px rgba(255, 215, 0, 0.45);
  }
  header.site-chrome nav.bulletin-toolbar a[aria-current="page"].tb-leaderboards,
  nav.bulletin-toolbar a[aria-current="page"].tb-leaderboards {
    color: #00f9ff;
    text-shadow: 0 0 8px rgba(0, 249, 255, 0.55);
  }
}

/* Tight toolbars (homepage card on a 320px phone): keep 3×3, shrink tracking so Leaderboards fits. */
@container site-nav (max-width: 280px) {
  header.site-chrome nav.bulletin-toolbar a,
  nav.bulletin-toolbar a {
    font-size: 8.5px;
    letter-spacing: 0.03em;
    padding: 10px 2px;
    gap: 0.15em;
  }
  header.site-chrome nav.bulletin-toolbar a.tb-leaderboards,
  nav.bulletin-toolbar a.tb-leaderboards {
    font-size: 8px;
    letter-spacing: 0;
  }
}

