/* ═══════════════ Trivia Rumble — categories page ═══════════════ */

* { margin: 0; padding: 0; box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: "Outfit", system-ui, sans-serif;
  background: var(--bg);
  background-image:
    radial-gradient(1100px 700px at 85% -10%, oklch(0.30 0.06 25 / 0.55), transparent 60%),
    radial-gradient(900px 600px at -10% 110%, oklch(0.28 0.05 255 / 0.45), transparent 60%);
  color: var(--ink);
  min-height: 100dvh;
  overflow-x: hidden;
}
a { color: var(--gold); text-decoration: none; }
main { max-width: 1440px; margin: 0 auto; padding: 0 72px; }

/* nav (shared pattern) */
.nav {
  max-width: 1440px; margin: 0 auto; padding: 24px 72px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); }
.brand-tiles { display: flex; gap: 5px; }
.brand-tiles i { width: 22px; height: 22px; border-radius: 7px; }
.brand-tiles .t-coral { background: var(--coral); box-shadow: 0 2px 0 var(--coral-edge); }
.brand-tiles .t-amber { background: var(--amber); box-shadow: 0 2px 0 var(--amber-edge); }
.brand-tiles .t-teal  { background: var(--teal);  box-shadow: 0 2px 0 var(--teal-edge); }
.brand-tiles .t-blue  { background: var(--blue);  box-shadow: 0 2px 0 var(--blue-edge); }
.brand-name { font-weight: 900; font-size: 1.35rem; text-transform: uppercase; letter-spacing: -0.02em; }
.nav-links { display: flex; align-items: center; gap: 32px; }
.nav-link { font-weight: 700; font-size: 1rem; color: var(--ink-dim); transition: color 0.2s; }
.nav-link:hover, .nav-link.is-active { color: var(--ink); }
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  font: inherit; font-weight: 800; border: 0; cursor: pointer;
  border-radius: var(--r-ctl); transition: transform 0.15s var(--ease), box-shadow 0.15s var(--ease), filter 0.2s;
  touch-action: manipulation; -webkit-tap-highlight-color: transparent;
}
.btn-ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 2px var(--line); font-weight: 700; }
.btn-nav { padding: 10px 20px; font-size: 0.95rem; }

/* hero */
.cat-hero { padding: 40px 0 16px; display: flex; flex-direction: column; gap: 14px; max-width: 62ch; }
.cat-hero h1 { font-size: clamp(2.5rem, 5vw, 3.75rem); font-weight: 900; text-transform: uppercase; letter-spacing: -0.03em; line-height: 0.95; }
.cat-hero p { font-size: 1.15rem; font-weight: 500; color: var(--ink-dim); line-height: 1.55; }

/* groups */
.cat-group { padding: 40px 0 8px; }
.cat-group h2 {
  font-size: 1.5rem; font-weight: 900; letter-spacing: -0.01em; margin-bottom: 20px;
  display: flex; align-items: center; gap: 12px;
}
.cat-group h2 .group-dot { width: 14px; height: 14px; border-radius: 5px; display: inline-block; }
.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 18px; }

/* card */
.cat-card {
  background: var(--bg-raise); border-radius: var(--r-panel); padding: 22px;
  box-shadow: inset 0 0 0 2px var(--line);
  display: flex; flex-direction: column; gap: 12px;
  transition: transform 0.15s var(--ease);
}
.cat-card:hover { transform: translateY(-2px); }
.cat-top { display: flex; align-items: center; gap: 14px; }
.cat-emoji {
  width: 54px; height: 54px; border-radius: 16px; background: var(--bg-sink);
  display: grid; place-items: center; font-size: 1.8rem; flex-shrink: 0;
}
.cat-name { font-weight: 800; font-size: 1.2rem; line-height: 1.15; }
.cat-tagline { font-weight: 500; font-size: 0.9rem; color: var(--ink-dim); line-height: 1.45; flex: 1; }
.cat-host {
  align-self: stretch; text-align: center;
  background: var(--gold); color: var(--gold-ink); box-shadow: 0 4px 0 var(--gold-edge);
  font-weight: 800; font-size: 0.95rem; padding: 11px 18px; border-radius: 12px;
}
.cat-host:active { transform: translateY(3px) scale(0.99); box-shadow: 0 1px 0 var(--gold-edge); }
.cat-card.is-wild { box-shadow: inset 0 0 0 2px var(--gold); }

/* footer */
.footer {
  max-width: 1296px; margin: 40px auto 0; padding: 32px 0 48px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  border-top: 2px solid var(--line);
}
.footer-brand { font-weight: 900; font-size: 1.05rem; text-transform: uppercase; }
.footer-links { font-weight: 600; font-size: 0.875rem; color: var(--ink-dim); }

@media (max-width: 900px) {
  main { padding: 0 20px; }
  .nav { padding: 20px; }
  .nav-links { gap: 16px; }
  .nav-links .nav-link:not(.is-active) { display: none; }
  .cat-hero { padding-top: 16px; }
  .cat-grid { grid-template-columns: 1fr; }
  .footer { margin: 24px 20px 0; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* search + chips */
.cat-search {
  font: inherit; font-weight: 600; font-size: 1.05rem;
  background: var(--bg-sink); color: var(--ink);
  border: 2px solid var(--line); border-radius: var(--r-ctl);
  padding: 14px 18px; outline: none; width: min(460px, 100%);
  transition: border-color 0.2s;
}
.cat-search:focus { border-color: var(--gold); }
.cat-search::placeholder { color: oklch(0.5 0.02 60); }
.cat-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.cat-chip {
  font: inherit; font-weight: 700; font-size: 0.85rem; cursor: pointer;
  background: var(--bg-raise); color: var(--ink-dim);
  border: 0; border-radius: 999px; padding: 8px 16px;
  box-shadow: inset 0 0 0 2px var(--line);
  transition: color 0.2s, box-shadow 0.2s;
  min-height: 36px;
}
.cat-chip.is-on { color: var(--gold-ink); background: var(--gold); box-shadow: 0 3px 0 var(--gold-edge); }
.cat-none { padding: 48px 0; font-weight: 600; color: var(--ink-dim); font-size: 1.05rem; }
.cat-card .cat-qcount { font-weight: 700; font-size: 0.75rem; color: var(--ink-dim); }
