/* ==========================================================================
   Basketball Arcade — Core stylesheet
   basketballarcade.xyz
   --------------------------------------------------------------------------
   Contents
   1.  Design tokens
   2.  Reset & base elements
   3.  Layout primitives
   4.  Typography & prose
   5.  Buttons & pills
   6.  Site header / navigation
   7.  Breadcrumbs
   8.  Hero
   9.  Section headers
   10. Cards (game, article, category, author)
   11. FAQ / accordion
   12. Table of contents
   13. Author box
   14. Callouts, key takeaways, references
   15. Forms
   16. Ad slots
   17. Site footer
   18. Utilities
   ========================================================================== */

/* ==========================================================================
   1. Design tokens
   ========================================================================== */

:root {
  /* Brand — basketball leather orange, deliberately deep rather than neon */
  --brand: #d94f1a;
  --brand-600: #b83f12;
  --brand-700: #93310c;
  --brand-50: #fff3ed;
  --brand-100: #ffe1d2;

  /* Deep court navy — headers, footer, display type */
  --navy: #101a2e;
  --navy-700: #1a2742;
  --navy-500: #2b3b5c;

  /* Supporting accents */
  --court: #0b6d63;   /* guides / informational */
  --court-50: #e6f5f3;
  --gold: #c58a26;    /* hardwood highlight */
  --gold-50: #fdf5e6;

  /* Neutrals */
  --ink: #0d1420;
  --ink-soft: #414e66;
  --ink-mute: #66748c;
  --paper: #ffffff;
  --surface: #f6f8fb;
  --surface-2: #edf1f7;
  --line: #e0e6ef;
  --line-strong: #cfd8e5;

  /* Semantic */
  --focus: #1257d6;

  /* Elevation */
  --shadow-sm: 0 1px 2px rgba(13, 20, 32, .06), 0 1px 3px rgba(13, 20, 32, .05);
  --shadow-md: 0 2px 4px rgba(13, 20, 32, .05), 0 8px 20px -6px rgba(13, 20, 32, .12);
  --shadow-lg: 0 4px 8px rgba(13, 20, 32, .05), 0 20px 40px -12px rgba(13, 20, 32, .20);

  /* Radii */
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 18px;
  --r-xl: 26px;
  --r-pill: 999px;

  /* Rhythm */
  --gap: 24px;
  --shell: 1200px;
  --shell-narrow: 760px;

  /* Type */
  --font-body: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-display: "Segoe UI Semibold", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;

  color-scheme: light;
}

/* Dark theme. Applies on an explicit choice, or on system preference when the
   visitor has not chosen. Every token is redefined so nothing inherits a
   light-only value. */
:root[data-theme="dark"] {
  --brand: #ff7a45;
  --brand-600: #ff5c1c;
  --brand-700: #ffa27c;
  --brand-50: #2a1710;
  --brand-100: #3d2118;

  --navy: #070c16;
  --navy-700: #0e1628;
  --navy-500: #1c2940;

  --court: #3fb5a6;
  --court-50: #0c2521;
  --gold: #e0ad55;
  --gold-50: #2a2110;

  --ink: #e8edf6;
  --ink-soft: #b3bed1;
  --ink-mute: #8d99ad;
  --paper: #0d131f;
  --surface: #121a29;
  --surface-2: #1a2434;
  --line: #24304a;
  --line-strong: #33405c;

  --focus: #79a6ff;

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .5);
  --shadow-md: 0 8px 20px -6px rgba(0, 0, 0, .6);
  --shadow-lg: 0 20px 40px -12px rgba(0, 0, 0, .7);

  color-scheme: dark;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --brand: #ff7a45;
    --brand-600: #ff5c1c;
    --brand-700: #ffa27c;
    --brand-50: #2a1710;
    --brand-100: #3d2118;

    --navy: #070c16;
    --navy-700: #0e1628;
    --navy-500: #1c2940;

    --court: #3fb5a6;
    --court-50: #0c2521;
    --gold: #e0ad55;
    --gold-50: #2a2110;

    --ink: #e8edf6;
    --ink-soft: #b3bed1;
    --ink-mute: #8d99ad;
    --paper: #0d131f;
    --surface: #121a29;
    --surface-2: #1a2434;
    --line: #24304a;
    --line-strong: #33405c;

    --focus: #79a6ff;

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .5);
    --shadow-md: 0 8px 20px -6px rgba(0, 0, 0, .6);
    --shadow-lg: 0 20px 40px -12px rgba(0, 0, 0, .7);

    color-scheme: dark;
  }
}

/* ==========================================================================
   2. Reset & base elements
   ========================================================================== */

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg, video, canvas { max-width: 100%; }
img { height: auto; display: block; }

h1, h2, h3, h4, h5 {
  font-family: var(--font-display);
  color: var(--ink);
  line-height: 1.18;
  letter-spacing: -.018em;
  margin: 0 0 .5em;
  font-weight: 700;
  text-wrap: balance;
}

h1 { font-size: clamp(2rem, 1.35rem + 2.6vw, 3.1rem); font-weight: 800; }
h2 { font-size: clamp(1.45rem, 1.2rem + 1.1vw, 2rem); }
h3 { font-size: clamp(1.18rem, 1.06rem + .5vw, 1.4rem); }
h4 { font-size: 1.07rem; }

p { margin: 0 0 1.15em; }

a {
  color: var(--brand-600);
  text-decoration-thickness: 1px;
  text-underline-offset: .18em;
}
a:hover { color: var(--brand-700); }

:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
  border-radius: 4px;
}

hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 2.5rem 0;
}

code, kbd {
  font-family: var(--font-mono);
  font-size: .88em;
}

kbd {
  background: var(--surface-2);
  border: 1px solid var(--line-strong);
  border-bottom-width: 2px;
  border-radius: 6px;
  padding: .12em .45em;
  color: var(--ink);
  white-space: nowrap;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: .95rem;
}
th, td {
  text-align: left;
  padding: .7rem .85rem;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
th {
  font-family: var(--font-display);
  font-weight: 700;
  background: var(--surface);
  color: var(--ink);
}

::selection { background: var(--brand-100); color: var(--ink); }

/* Skip link */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 200;
  background: var(--brand);
  color: #fff;
  padding: .75rem 1.25rem;
  font-weight: 700;
  border-radius: 0 0 var(--r-sm) 0;
}
.skip-link:focus {
  left: 0;
  color: #fff;
}

/* ==========================================================================
   3. Layout primitives
   ========================================================================== */

.shell {
  width: 100%;
  max-width: var(--shell);
  margin-inline: auto;
  padding-inline: 20px;
}

.shell--narrow { max-width: var(--shell-narrow); }

.section { padding-block: clamp(2.5rem, 1.6rem + 3.4vw, 4.25rem); }
.section--tight { padding-block: clamp(1.75rem, 1.2rem + 2vw, 2.75rem); }
.section--surface { background: var(--surface); }
.section--court {
  background: var(--navy);
  color: #e8edf6;
}
.section--court h2,
.section--court h3 { color: #fff; }
.section--court p { color: #c3cdde; }

.grid { display: grid; gap: var(--gap); }
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid--auto { grid-template-columns: repeat(auto-fill, minmax(255px, 1fr)); }

/* Article + sidebar */
.layout-aside {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 48px;
  align-items: start;
}
.sidebar { position: sticky; top: 92px; }

/* Thin hardwood rule used as a decorative court line */
.court-rule {
  height: 4px;
  border: 0;
  margin: 0;
  background: linear-gradient(90deg, var(--brand) 0%, var(--brand) 22%, var(--gold) 22%, var(--gold) 34%, var(--line) 34%);
  border-radius: var(--r-pill);
}

/* ==========================================================================
   4. Typography & prose
   ========================================================================== */

.prose { font-size: 1.06rem; }
.prose > h2 {
  margin-top: 2.2em;
  padding-top: .35em;
  border-top: 3px solid var(--brand);
  display: inline-block;
  padding-right: .4em;
}
.prose > h2:first-child { margin-top: 0; }
.prose > h3 { margin-top: 1.9em; color: var(--navy-500); }
:root[data-theme="dark"] .prose > h3 { color: var(--ink); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .prose > h3 { color: var(--ink); }
}

.prose ul, .prose ol { margin: 0 0 1.3em; padding-left: 1.35em; }
.prose li { margin-bottom: .55em; }
.prose li::marker { color: var(--brand); font-weight: 700; }

.prose blockquote {
  margin: 1.8em 0;
  padding: .2em 0 .2em 1.3em;
  border-left: 4px solid var(--gold);
  color: var(--ink-soft);
  font-size: 1.06em;
}

.prose figure { margin: 2em 0; }
.prose figcaption {
  font-size: .87rem;
  color: var(--ink-mute);
  margin-top: .6em;
}

.prose img { border-radius: var(--r-md); }

.lede {
  font-size: clamp(1.1rem, 1.02rem + .35vw, 1.28rem);
  color: var(--ink-soft);
  line-height: 1.55;
}

.eyebrow {
  display: inline-block;
  font-family: var(--font-display);
  font-size: .74rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--brand-600);
  margin-bottom: .75rem;
}
.eyebrow--light { color: var(--brand); }

.meta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .55rem 1rem;
  font-size: .89rem;
  color: var(--ink-mute);
  margin: 0 0 1.4rem;
}
.meta-row a { color: var(--ink-soft); }
.meta-dot { width: 4px; height: 4px; border-radius: 50%; background: var(--line-strong); }

/* ==========================================================================
   5. Buttons & pills
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5em;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.2;
  padding: .82em 1.5em;
  border-radius: var(--r-pill);
  border: 2px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: transform .14s ease, background-color .14s ease, border-color .14s ease, color .14s ease;
  min-height: 44px;
}
.btn:active { transform: translateY(1px); }

.btn--primary { background: var(--brand); color: #fff; }
.btn--primary:hover { background: var(--brand-600); color: #fff; }
:root[data-theme="dark"] .btn--primary { color: #16100c; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .btn--primary { color: #16100c; }
}

.btn--ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-strong);
}
.btn--ghost:hover { border-color: var(--brand); color: var(--brand-600); background: var(--brand-50); }

.btn--dark { background: var(--navy); color: #fff; }
.btn--dark:hover { background: var(--navy-700); color: #fff; }

.btn--sm { font-size: .88rem; padding: .6em 1.1em; min-height: 38px; }
.btn--lg { font-size: 1.08rem; padding: .95em 1.85em; }
.btn--block { width: 100%; }

.btn-row { display: flex; flex-wrap: wrap; gap: .75rem; }

.tag {
  display: inline-flex;
  align-items: center;
  gap: .35em;
  font-size: .73rem;
  font-weight: 700;
  font-family: var(--font-display);
  letter-spacing: .07em;
  text-transform: uppercase;
  padding: .32em .72em;
  border-radius: var(--r-pill);
  background: var(--surface-2);
  color: var(--ink-soft);
  text-decoration: none;
  white-space: nowrap;
}
.tag--brand { background: var(--brand-50); color: var(--brand-600); }
.tag--court { background: var(--court-50); color: var(--court); }
.tag--gold  { background: var(--gold-50);  color: var(--gold); }
a.tag:hover { background: var(--brand); color: #fff; }

.tag-list { display: flex; flex-wrap: wrap; gap: .45rem; }

/* ==========================================================================
   6. Site header / navigation
   ========================================================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--navy);
  color: #fff;
  border-bottom: 3px solid var(--brand);
}

.header-bar {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: 68px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  text-decoration: none;
  color: #fff;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.16rem;
  letter-spacing: -.02em;
  margin-right: auto;
  padding: .35rem 0;
}
.brand:hover { color: #fff; }
.brand-mark { flex: 0 0 auto; width: 34px; height: 34px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-text small {
  font-size: .6rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--brand);
  font-weight: 700;
}

.nav { display: flex; align-items: center; gap: .15rem; }

.nav a {
  display: inline-block;
  color: #d7deeb;
  text-decoration: none;
  font-size: .93rem;
  font-weight: 600;
  padding: .55rem .68rem;
  border-radius: var(--r-sm);
  white-space: nowrap;
}
.nav a:hover { color: #fff; background: rgba(255, 255, 255, .09); }
.nav a[aria-current="page"],
.nav a.is-active {
  color: #fff;
  box-shadow: inset 0 -3px 0 var(--brand);
}

.nav-actions { display: flex; align-items: center; gap: .4rem; }

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: var(--r-sm);
  background: rgba(255, 255, 255, .08);
  border: 1px solid rgba(255, 255, 255, .14);
  color: #fff;
  cursor: pointer;
  padding: 0;
}
.icon-btn:hover { background: rgba(255, 255, 255, .18); }
.icon-btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.nav-toggle { display: none; }

/* Mobile drawer */
.mobile-nav {
  display: none;
  background: var(--navy-700);
  border-top: 1px solid rgba(255, 255, 255, .1);
  padding: .5rem 0 1rem;
}
.mobile-nav.is-open { display: block; }
.mobile-nav a {
  display: block;
  color: #e3e9f3;
  text-decoration: none;
  font-weight: 600;
  padding: .8rem .4rem;
  border-bottom: 1px solid rgba(255, 255, 255, .07);
  min-height: 44px;
}
.mobile-nav a:hover { color: var(--brand); }
.mobile-nav .mobile-nav__group {
  font-size: .72rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #8b9ab5;
  padding: 1rem .4rem .3rem;
  font-weight: 700;
}

/* Header search overlay */
.header-search {
  display: none;
  background: var(--navy-700);
  padding: 1rem 0 1.25rem;
  border-top: 1px solid rgba(255, 255, 255, .1);
}
.header-search.is-open { display: block; }
.header-search form { display: flex; gap: .5rem; }
.header-search input[type="search"] {
  flex: 1;
  min-height: 48px;
  border-radius: var(--r-sm);
  border: 1px solid rgba(255, 255, 255, .2);
  background: rgba(255, 255, 255, .06);
  color: #fff;
  padding: 0 1rem;
  font-size: 1rem;
  font-family: inherit;
}
.header-search input[type="search"]::placeholder { color: #93a1bb; }

/* ==========================================================================
   7. Breadcrumbs
   ========================================================================== */

.breadcrumbs {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  font-size: .85rem;
}
.breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .4rem;
  list-style: none;
  margin: 0;
  padding: .7rem 0;
}
.breadcrumbs li { display: flex; align-items: center; gap: .4rem; color: var(--ink-mute); }
.breadcrumbs li + li::before {
  content: "›";
  color: var(--line-strong);
  font-size: 1.1em;
  line-height: 1;
}
.breadcrumbs a { color: var(--ink-soft); text-decoration: none; }
.breadcrumbs a:hover { color: var(--brand-600); text-decoration: underline; }
.breadcrumbs [aria-current="page"] { color: var(--ink); font-weight: 600; }

/* ==========================================================================
   8. Hero
   ========================================================================== */

.hero {
  position: relative;
  background: var(--navy);
  color: #fff;
  overflow: hidden;
  padding-block: clamp(2.75rem, 1.8rem + 4vw, 5rem);
}

/* Decorative court arc, drawn in CSS so it costs no request */
.hero::before {
  content: "";
  position: absolute;
  right: -160px;
  top: 50%;
  transform: translateY(-50%);
  width: 620px;
  height: 620px;
  border: 2px solid rgba(217, 79, 26, .35);
  border-radius: 50%;
  pointer-events: none;
}
.hero::after {
  content: "";
  position: absolute;
  right: -40px;
  top: 50%;
  transform: translateY(-50%);
  width: 320px;
  height: 320px;
  border: 2px solid rgba(255, 255, 255, .08);
  border-radius: 50%;
  pointer-events: none;
}

.hero__inner { position: relative; z-index: 1; max-width: 720px; }
.hero h1 { color: #fff; margin-bottom: .45em; }
.hero p { color: #c6d0e0; font-size: clamp(1.05rem, .98rem + .45vw, 1.28rem); }
.hero .btn-row { margin-top: 1.9rem; }

.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem 2.75rem;
  margin-top: 2.5rem;
  padding-top: 1.75rem;
  border-top: 1px solid rgba(255, 255, 255, .13);
}
.hero-stat strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.85rem;
  font-weight: 800;
  color: var(--brand);
  line-height: 1;
}
.hero-stat span {
  font-size: .8rem;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: #93a1bb;
  font-weight: 600;
}

/* Compact page header for interior pages */
.page-head {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  padding-block: clamp(2rem, 1.4rem + 2.2vw, 3.25rem);
}
.page-head h1 { margin-bottom: .35em; }
.page-head .lede { max-width: 68ch; margin-bottom: 0; }

/* ==========================================================================
   9. Section headers
   ========================================================================== */

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 1.75rem;
}
.section-head h2 { margin-bottom: .25em; }
.section-head p { color: var(--ink-mute); margin: 0; max-width: 62ch; font-size: .97rem; }
.section-head__link {
  flex: 0 0 auto;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: .92rem;
  text-decoration: none;
  white-space: nowrap;
}
.section-head__link::after { content: " →"; }

/* ==========================================================================
   10. Cards
   ========================================================================== */

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform .16s ease, box-shadow .16s ease, border-color .16s ease;
}
.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--line-strong);
}
.card__media {
  position: relative;
  aspect-ratio: 3 / 2;
  background: var(--surface-2);
  overflow: hidden;
}
.card__media img { width: 100%; height: 100%; object-fit: cover; }
.card__body { padding: 1.15rem 1.2rem 1.3rem; display: flex; flex-direction: column; flex: 1; }
.card__title {
  font-size: 1.1rem;
  margin: .55rem 0 .45rem;
  letter-spacing: -.015em;
}
.card__title a { color: var(--ink); text-decoration: none; }
.card__title a::after {
  content: "";
  position: absolute;
  inset: 0;
}
.card:hover .card__title a { color: var(--brand-600); }
.card__desc {
  font-size: .93rem;
  color: var(--ink-soft);
  margin: 0 0 1rem;
  line-height: 1.55;
}
.card__foot {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  padding-top: .85rem;
  border-top: 1px solid var(--line);
  font-size: .8rem;
  color: var(--ink-mute);
}

/* Badge floating over the thumbnail */
.card__badge {
  position: absolute;
  top: .65rem;
  left: .65rem;
  z-index: 2;
  background: rgba(16, 26, 46, .88);
  color: #fff;
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .09em;
  text-transform: uppercase;
  padding: .3em .6em;
  border-radius: var(--r-sm);
  backdrop-filter: blur(4px);
}
.card__badge--brand { background: var(--brand); }

/* Favourite toggle sits above the stretched card link */
.fav-btn {
  position: absolute;
  top: .55rem;
  right: .55rem;
  z-index: 3;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .35);
  background: rgba(16, 26, 46, .7);
  color: #fff;
  cursor: pointer;
  display: grid;
  place-items: center;
  padding: 0;
  transition: background-color .14s ease, transform .14s ease;
}
.fav-btn:hover { background: var(--brand); transform: scale(1.06); }
.fav-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; }
.fav-btn[aria-pressed="true"] { background: var(--brand); }
.fav-btn[aria-pressed="true"] svg { fill: #fff; }

/* Article card variant */
.card--article .card__media { aspect-ratio: 16 / 9; }

/* Compact list row (sidebars, related lists) */
.mini-list { list-style: none; margin: 0; padding: 0; }
.mini-list li {
  padding: .8rem 0;
  border-bottom: 1px solid var(--line);
}
.mini-list li:last-child { border-bottom: 0; }
.mini-list a {
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
  font-size: .96rem;
  line-height: 1.4;
  display: block;
}
.mini-list a:hover { color: var(--brand-600); }
.mini-list span {
  display: block;
  font-size: .78rem;
  color: var(--ink-mute);
  margin-top: .2rem;
  font-weight: 400;
}

/* Category tile */
.cat-tile {
  position: relative;
  display: block;
  padding: 1.5rem 1.4rem;
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  background: var(--paper);
  text-decoration: none;
  color: var(--ink);
  box-shadow: var(--shadow-sm);
  transition: transform .16s ease, box-shadow .16s ease;
  overflow: hidden;
}
.cat-tile::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 5px;
  background: var(--brand);
}
.cat-tile:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); color: var(--ink); }
.cat-tile h3 { font-size: 1.12rem; margin-bottom: .35rem; }
.cat-tile p { font-size: .9rem; color: var(--ink-soft); margin: 0 0 .8rem; }
.cat-tile__count {
  font-size: .76rem;
  font-weight: 700;
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--brand-600);
}

/* Author card */
.author-card {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
  padding: 1.5rem;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: var(--surface);
}
.author-card img {
  flex: 0 0 auto;
  width: 84px;
  height: 84px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--paper);
  box-shadow: var(--shadow-sm);
}

/* ==========================================================================
   11. FAQ / accordion
   ========================================================================== */

.faq { border-top: 1px solid var(--line); }
.faq details {
  border-bottom: 1px solid var(--line);
  background: transparent;
}
.faq summary {
  cursor: pointer;
  list-style: none;
  padding: 1.15rem 2.5rem 1.15rem 0;
  position: relative;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.04rem;
  color: var(--ink);
  line-height: 1.4;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "";
  position: absolute;
  right: .55rem;
  top: 1.5rem;
  width: 11px;
  height: 11px;
  border-right: 2.5px solid var(--brand);
  border-bottom: 2.5px solid var(--brand);
  transform: rotate(45deg);
  transition: transform .18s ease;
}
.faq details[open] summary::after { transform: rotate(-135deg); top: 1.75rem; }
.faq summary:hover { color: var(--brand-600); }
.faq__answer { padding: 0 2.5rem 1.35rem 0; color: var(--ink-soft); }
.faq__answer > :last-child { margin-bottom: 0; }

/* ==========================================================================
   12. Table of contents
   ========================================================================== */

.toc {
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--brand);
  border-radius: var(--r-md);
  padding: 1.25rem 1.4rem;
  margin: 0 0 2.25rem;
}
.toc h2 {
  font-size: .8rem !important;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-mute);
  margin: 0 0 .75rem !important;
  border: 0 !important;
  padding: 0 !important;
  display: block !important;
}
.toc ol { margin: 0; padding-left: 1.25rem; counter-reset: none; }
.toc li { margin-bottom: .4rem; font-size: .95rem; }
.toc li::marker { color: var(--ink-mute); font-weight: 600; }
.toc a { color: var(--ink-soft); text-decoration: none; }
.toc a:hover { color: var(--brand-600); text-decoration: underline; }

/* ==========================================================================
   13. Author box
   ========================================================================== */

.author-box {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
  margin: 3rem 0 0;
  padding: 1.5rem;
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: var(--surface);
}
.author-box img {
  flex: 0 0 auto;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
}
.author-box__name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.06rem;
  margin: 0 0 .1rem;
}
.author-box__role {
  font-size: .82rem;
  color: var(--brand-600);
  font-weight: 600;
  margin: 0 0 .6rem;
}
.author-box p { font-size: .93rem; color: var(--ink-soft); margin-bottom: .6rem; }
.author-box a { font-size: .9rem; font-weight: 600; }

/* ==========================================================================
   14. Callouts, key takeaways, references
   ========================================================================== */

.callout {
  border-radius: var(--r-md);
  padding: 1.25rem 1.4rem;
  margin: 2rem 0;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: .97rem;
}
.callout > :last-child { margin-bottom: 0; }
.callout__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: .78rem;
  letter-spacing: .13em;
  text-transform: uppercase;
  margin: 0 0 .55rem;
  color: var(--brand-600);
}
.callout--tip { background: var(--brand-50); border-color: var(--brand-100); }
.callout--note { background: var(--court-50); border-color: var(--court-50); }
.callout--note .callout__title { color: var(--court); }

.takeaways {
  border: 2px solid var(--navy);
  border-radius: var(--r-lg);
  padding: 1.5rem 1.6rem;
  margin: 2.75rem 0;
  background: var(--paper);
}
.takeaways h2 {
  font-size: 1.1rem !important;
  border: 0 !important;
  padding: 0 !important;
  margin: 0 0 .85rem !important;
  display: block !important;
}
.takeaways ul { margin: 0; padding-left: 1.25rem; }
.takeaways li { font-size: .97rem; margin-bottom: .5rem; }

.refs { font-size: .9rem; }
.refs ol { padding-left: 1.3rem; }
.refs li { margin-bottom: .6rem; color: var(--ink-soft); }

.updated-stamp {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  font-size: .8rem;
  color: var(--ink-mute);
  background: var(--surface-2);
  padding: .3em .7em;
  border-radius: var(--r-pill);
  font-weight: 600;
}

/* ==========================================================================
   15. Forms
   ========================================================================== */

.field { margin-bottom: 1.15rem; }
.field label {
  display: block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: .9rem;
  margin-bottom: .4rem;
  color: var(--ink);
}
.field .hint { font-size: .82rem; color: var(--ink-mute); margin: .35rem 0 0; }

input[type="text"],
input[type="email"],
input[type="search"],
select,
textarea {
  width: 100%;
  font-family: inherit;
  font-size: 1rem;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--line-strong);
  border-radius: var(--r-sm);
  padding: .7rem .85rem;
  min-height: 46px;
}
textarea { min-height: 150px; resize: vertical; line-height: 1.6; }
input:focus, select:focus, textarea:focus { border-color: var(--brand); }

.form-note {
  border: 1px dashed var(--line-strong);
  background: var(--surface);
  border-radius: var(--r-md);
  padding: 1.1rem 1.25rem;
  font-size: .92rem;
  color: var(--ink-soft);
  margin-bottom: 1.75rem;
}
.form-note strong { color: var(--ink); }

/* ==========================================================================
   16. Ad slots
   ========================================================================== */

/* Reserved advertising containers. They are empty on purpose — paste an
   AdSense unit inside the container to activate one. Reserved min-heights
   keep cumulative layout shift at zero when a unit loads. */
.ad-slot {
  display: block;
  margin-inline: auto;
  width: 100%;
  overflow: hidden;
  contain: layout;
}
.ad-slot:empty { display: block; }
.ad-slot--header { max-width: 970px; min-height: 100px; margin-block: 1.5rem; }
.ad-slot--content { max-width: 728px; min-height: 280px; margin-block: 2.5rem; }
.ad-slot--sidebar { max-width: 300px; min-height: 600px; margin-block: 1.5rem; }
.ad-slot--game-bottom { max-width: 970px; min-height: 250px; margin-block: 2rem; }
.ad-slot--footer { max-width: 970px; min-height: 250px; margin-block: 2rem; }

/* Optional dev outline: add class "ad-debug" to <body> to visualise slots. */
.ad-debug .ad-slot:empty {
  outline: 1px dashed var(--line-strong);
  border-radius: var(--r-sm);
}
.ad-debug .ad-slot:empty::before {
  content: "Ad slot — " attr(data-slot);
  display: grid;
  place-items: center;
  height: 100%;
  min-height: inherit;
  color: var(--ink-mute);
  font-size: .78rem;
  letter-spacing: .1em;
  text-transform: uppercase;
}

/* ==========================================================================
   17. Site footer
   ========================================================================== */

.site-footer {
  background: var(--navy);
  color: #b9c4d6;
  padding-block: 3.25rem 1.75rem;
  margin-top: 4rem;
  font-size: .93rem;
}
.site-footer a { color: #d3dbe8; text-decoration: none; }
.site-footer a:hover { color: var(--brand); text-decoration: underline; }

.footer-grid {
  display: grid;
  grid-template-columns: 1.7fr repeat(3, 1fr);
  gap: 2.5rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, .11);
}
.footer-brand .brand { margin-bottom: 1rem; }
.footer-brand p { max-width: 42ch; color: #98a6bd; font-size: .9rem; }

.footer-col h2 {
  font-size: .76rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #fff;
  margin-bottom: .95rem;
}
.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-col li { margin-bottom: .55rem; }

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 1.5rem;
  font-size: .84rem;
  color: #8b9ab5;
}
.footer-bottom p { margin: 0; }
.footer-disclaimer {
  max-width: 70ch;
  font-size: .82rem;
  color: #7f8ea9;
  margin-top: .75rem;
}

/* ==========================================================================
   18. Utilities
   ========================================================================== */

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.stack > * + * { margin-top: 1rem; }
.center { text-align: center; }
.mx-auto { margin-inline: auto; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: .5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.measure { max-width: 68ch; }
.text-mute { color: var(--ink-mute); }
.small { font-size: .88rem; }

.empty-state {
  text-align: center;
  padding: 3rem 1.5rem;
  border: 1px dashed var(--line-strong);
  border-radius: var(--r-lg);
  color: var(--ink-mute);
  background: var(--surface);
}
.empty-state h2,
.empty-state h3 { color: var(--ink); font-size: 1.18rem; }
