/* =========================================================================
   Ninety Two & More - shared visual identity
   "Parchment matchday programme" in Aston Villa claret & sky blue
   ========================================================================= */

:root {
  /* palette - Villa kit claret + sky blue on parchment */
  --parchment:   #f2efe6;
  --parchment-2: #eae5d6;   /* slightly deeper panel tone */
  --claret:      #670e36;   /* Villa claret - headers, primary UI */
  --claret-2:    #8a1f4f;   /* lifted claret - hovers, pin bodies */
  --claret-deep: #42071f;   /* outlines on claret shapes */
  --sky:         #95bfe5;   /* Villa sky blue - trim; use ON claret only */
  --sky-2:       #b9d8f0;
  /* Kit sky blue is far too light for text on parchment (1.6:1), so small text
     and links on light surfaces use this deeper blue of the same family. */
  --blue-ink:    #1f5c8b;   /* 6.2:1 on parchment - passes AA */
  --focus:       #2e86c8;   /* 3.4:1 on parchment, 3.2:1 on claret - passes on both */
  --ink:         #22131a;
  --muted:       #6b6355;
  --border:      #ddd6c4;

  /* Level colours (mirrored by the pin SVGs in js/map.js).
     The four EFL divisions are an ordered claret ramp, dark = higher, so rank
     reads at a glance; the three non-ranked categories take distinct hues so
     they can't be mistaken for a position in that ladder. */
  --lv-premier-league: #670e36;   /* claret, darkest */
  --lv-championship:   #9c2b5e;
  --lv-league-1:       #c26089;
  --lv-league-2:       #e3a6bf;
  --lv-non-league:     #f7f4ec;   /* kit cream - needs its own dark border */
  --lv-rest-of-uk:     #2b5f9e;   /* blue - UK, but outside the English pyramid */
  --lv-womens:         #6a4c93;   /* purple */
  --lv-international:  #1f7a6b;   /* teal */
  --lv-lost:           #8a8172;   /* faded grey-brown - gone */

  --font-serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  --font-sans:  "Helvetica Neue", Helvetica, Arial, "Segoe UI", system-ui, sans-serif;

  --shadow-soft: 0 1px 2px rgba(34,19,26,.10), 0 2px 8px rgba(34,19,26,.06);
  --shadow-lift: 0 4px 12px rgba(34,19,26,.16), 0 10px 28px rgba(34,19,26,.10);
  --radius: 8px;
  --maxw: 1120px;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--ink);
  background: var(--parchment);
  line-height: 1.6;
  font-size: 17px;
}

h1, h2, h3, .serif { font-family: var(--font-serif); }

a { color: var(--claret); }
a:hover { color: var(--claret-2); }

img { max-width: 100%; display: block; }

/* ---- skip link ---------------------------------------------------------- */
.skip-link {
  position: absolute;
  left: 12px; top: -60px;
  background: var(--sky);
  color: var(--ink);
  padding: 10px 16px;
  border-radius: var(--radius);
  font-weight: 700;
  z-index: 2000;
  transition: top .15s ease;
}
.skip-link:focus { top: 12px; outline: 3px solid var(--ink); }

/* ---- focus visibility (accessibility) ----------------------------------- */
:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

/* ---- site header -------------------------------------------------------- */
.site-header {
  background: var(--claret);
  color: var(--parchment);
  border-bottom: 3px solid var(--sky);
}
.site-header__inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.site-brand { text-decoration: none; color: inherit; display: block; }
.site-brand__title {
  font-family: var(--font-serif);
  font-weight: 500;
  font-size: 1.45rem;
  line-height: 1.1;
  letter-spacing: .2px;
}
.site-brand__sub {
  font-size: .74rem;
  text-transform: uppercase;
  letter-spacing: .16em;
  color: var(--sky-2);
  margin-top: 3px;
}
.site-nav { display: flex; gap: 8px; align-items: center; }
.site-nav a {
  color: var(--parchment);
  text-decoration: none;
  font-size: .82rem;
  text-transform: uppercase;
  letter-spacing: .09em;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid transparent;
}
.site-nav a:hover { border-color: rgba(242,239,230,.35); color: #fff; }
.site-nav a[aria-current="page"] {
  background: var(--sky);
  color: var(--claret);        /* claret on sky - straight off the kit, 6.4:1 */
  font-weight: 700;
}

/* ---- footer credit (required on every page) ----------------------------- */
.site-footer {
  background: var(--claret);
  color: var(--parchment);
  border-top: 3px solid var(--sky);
  margin-top: 48px;
}
.site-footer__inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 22px 20px;
  font-size: .82rem;
  color: #d7d1c0;
}
.site-footer__inner strong { color: var(--parchment); font-weight: 600; }
.site-footer a { color: var(--sky-2); }

/* ---- generic layout ----------------------------------------------------- */
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

/* ---- pills / badges ----------------------------------------------------- */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-sans);
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .07em;
  font-weight: 700;
  padding: 4px 11px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--parchment);
  color: var(--muted);
  white-space: nowrap;
}
.pill--vol   { background: var(--claret); color: var(--parchment); border-color: var(--claret); }
.pill--accent  { background: var(--sky); color: var(--claret); border-color: var(--sky); }

/* "one of the 92" mark - the grounds of the 92 clubs currently in the top four
   divisions. Small enough to sit inline after a ground name without competing
   with it. */
.badge-92 {
  display: inline-block;
  vertical-align: 2px;
  font-family: var(--font-sans);
  font-size: .62rem;
  font-weight: 700;
  letter-spacing: .06em;
  line-height: 1;
  padding: 3px 6px;
  border-radius: 999px;
  background: var(--claret);
  color: var(--parchment);
  white-space: nowrap;
}
/* on the hero the surrounding text is already light on a dark photo */
.badge-92--hero {
  background: var(--sky);
  color: var(--claret);
  vertical-align: 1px;
}

.level-dot {
  width: 12px; height: 12px; border-radius: 50%;
  display: inline-block; flex: none;
  border: 1.5px solid rgba(34,19,26,.25);
}
.level-dot--premier-league { background: var(--lv-premier-league); }
.level-dot--championship   { background: var(--lv-championship); }
.level-dot--league-1       { background: var(--lv-league-1); }
.level-dot--league-2       { background: var(--lv-league-2); }
/* the cream level would vanish on a cream page, so it carries a claret ring */
.level-dot--non-league     { background: var(--lv-non-league); border-color: var(--claret); }
.level-dot--rest-of-uk     { background: var(--lv-rest-of-uk); }
.level-dot--womens         { background: var(--lv-womens); }
.level-dot--international  { background: var(--lv-international); }
.level-dot--lost           { background: var(--lv-lost); }

/* ---- reduced motion ----------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}

.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;
}
