/* =====================================================================
   Naija Sports — 01 base: tokens, reset, buttons, badges, surfaces
   Visual language inspired by Exambly: Quicksand, soft shadows, rounded
   surfaces, emerald accent on dark slate, light-grey canvas.
   ===================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Quicksand:wght@400;500;600;700&family=Inter:wght@400;500;600;700&display=swap');

/* --------------------------------------------------------------- *
   1. Tokens
   --------------------------------------------------------------- */
:root {
  --accent:       #2bb58e;
  --accent-dark:  #00ad8a;
  --accent-soft:  #e6f7f2;
  --amber:        #fabf61;
  --danger:       #e36b6b;
  --info:         #22a3c9;

  --ink:      #2d3e51;
  --ink-2:    #46596e;
  --muted:    #969fa9;
  --line:     #eaebed;
  --canvas:   #f7f7f7;
  --surface:  #ffffff;
  --surface-2:#fafafa;

  --radius-sm: 6px;
  --radius:    10px;
  --radius-lg: 16px;
  --radius-xl: 22px;

  --shadow-xs: 0 1px 2px rgba(45,62,81,.06);
  --shadow-sm: 0 2px 8px rgba(45,62,81,.07);
  --shadow:    0 6px 22px rgba(45,62,81,.09);
  --shadow-lg: 0 16px 40px rgba(45,62,81,.13);

  --font: 'Quicksand', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  --wrap: 1240px;
  --head-h: 140px;
}

[data-theme="dark"] {
  --accent-soft: rgba(43,181,142,.15);
  --ink:      #e8edf2;
  --ink-2:    #b9c4cf;
  --muted:    #8b96a3;
  --line:     #2a3746;
  --canvas:   #131b23;
  --surface:  #1b242e;
  --surface-2:#212c38;
  --shadow-sm: 0 2px 8px rgba(0,0,0,.35);
  --shadow:    0 6px 22px rgba(0,0,0,.40);
  --shadow-lg: 0 16px 40px rgba(0,0,0,.50);
}

/* --------------------------------------------------------------- *
   2. Reset & base
   --------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

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

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink-2);
  background: var(--canvas);
  -webkit-font-smoothing: antialiased;
  transition: background .25s ease, color .25s ease;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font);
  color: var(--ink);
  line-height: 1.25;
  letter-spacing: -.015em;
  margin: 0 0 .5em;
  font-weight: 700;
}
h1 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); }
h2 { font-size: clamp(1.4rem, 2.4vw, 1.85rem); }
h3 { font-size: 1.22rem; }
h4 { font-size: 1.05rem; }

p { margin: 0 0 1rem; }
a { color: var(--accent-dark); text-decoration: none; transition: color .15s ease; }
a:hover { color: var(--accent); }
img { max-width: 100%; height: auto; display: block; }
/* icon() emits <svg viewBox="0 0 24 24"> with no width/height, so an SVG with
   no matching rule falls back to the 300x150 replaced-element default and
   blows up whatever button it sits in. Size every icon once here; the
   component rules in the other stylesheets override as needed. */
svg { width: 1.05em; height: 1.05em; fill: currentColor; flex-shrink: 0; vertical-align: -.15em; }
ul, ol { margin: 0 0 1rem; padding-left: 1.25rem; }
hr { border: 0; border-top: 1px solid var(--line); margin: 2rem 0; }
small { font-size: .8rem; }
code, pre { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .88em; }

:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
::selection { background: var(--accent); color: #fff; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: 20px; }
.wrap-narrow { max-width: 860px; }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 999;
  background: var(--accent); color: #fff; padding: 12px 20px;
  border-radius: 0 0 var(--radius) 0; font-family: var(--font); font-weight: 600;
}
.skip-link:focus { left: 0; color: #fff; }

.text-muted { color: var(--muted); }
.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.mb-2 { margin-bottom: 1rem; }

/* --------------------------------------------------------------- *
   3. Buttons
   --------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--font); font-weight: 600; font-size: .93rem;
  padding: 11px 22px; border-radius: 999px; border: 1px solid transparent;
  cursor: pointer; white-space: nowrap; text-align: center; line-height: 1.3;
  transition: transform .12s ease, box-shadow .2s ease, background .2s ease, color .2s ease, border-color .2s ease;
}
.btn:active { transform: translateY(1px); }
.btn svg { width: 1.05em; height: 1.05em; fill: currentColor; flex-shrink: 0; }
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 6px 16px rgba(43,181,142,.28); }
.btn-primary:hover { background: var(--accent-dark); color: #fff; box-shadow: 0 10px 24px rgba(43,181,142,.34); }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #1c2a38; color: #fff; }
.btn-ghost { background: var(--surface); color: var(--ink); border-color: var(--line); box-shadow: var(--shadow-xs); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent-dark); }
.btn-soft { background: var(--accent-soft); color: var(--accent-dark); }
.btn-soft:hover { background: var(--accent); color: #fff; }
.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #cf5b5b; color: #fff; }
.btn-outline-danger { background: transparent; color: var(--danger); border-color: var(--danger); }
.btn-outline-danger:hover { background: var(--danger); color: #fff; }
.btn-sm { padding: 7px 15px; font-size: .82rem; }
.btn-lg { padding: 14px 30px; font-size: 1rem; }
.btn-block { display: flex; width: 100%; }
.btn-icon { padding: 0; width: 38px; height: 38px; border-radius: 50%; }
.btn-icon svg { width: 16px; height: 16px; fill: currentColor; }
.btn[disabled], .btn.is-disabled { opacity: .55; pointer-events: none; }

.icon-btn {
  width: 38px; height: 38px; display: grid; place-items: center;
  border-radius: 50%; border: 1px solid var(--line); background: var(--surface);
  color: var(--muted); cursor: pointer; transition: all .2s ease;
}
.icon-btn:hover { color: var(--accent-dark); border-color: var(--accent); background: var(--accent-soft); }
.icon-btn svg { width: 17px; height: 17px; fill: currentColor; }

/* --------------------------------------------------------------- *
   4. Badges & pills
   --------------------------------------------------------------- */
.badge {
  display: inline-flex; align-items: center; gap: 5px;
  font-family: var(--font); font-weight: 700; font-size: .7rem; letter-spacing: .05em;
  text-transform: uppercase; padding: 4px 11px; border-radius: 999px;
  background: var(--accent-soft); color: var(--accent-dark); white-space: nowrap;
}
.badge-amber  { background: #fff3e0; color: #b57a1e; }
.badge-danger { background: #fdecec; color: #c25454; }
.badge-info   { background: #e5f4fa; color: #1a7d9b; }
.badge-grey   { background: #eef0f2; color: #6b7684; }
.badge-dot::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
[data-theme="dark"] .badge-amber  { background: rgba(250,191,97,.16);  color: var(--amber); }
[data-theme="dark"] .badge-danger { background: rgba(227,107,107,.16); color: #f19a9a; }
[data-theme="dark"] .badge-info   { background: rgba(34,163,201,.16);  color: #6ecbe8; }
[data-theme="dark"] .badge-grey   { background: rgba(150,159,169,.16); color: #b3bcc6; }

/* --------------------------------------------------------------- *
   5. Surfaces & panels
   --------------------------------------------------------------- */
.surface {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius-lg); box-shadow: var(--shadow-sm);
}
.surface-pad { padding: 22px; }
.panel {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); overflow: hidden;
}
.panel-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 15px 20px; border-bottom: 1px solid var(--line);
  background: var(--surface-2);
}
.panel-head h2, .panel-head h3 { margin: 0; font-size: 1.02rem; }
.panel-body { padding: 20px; }
.panel-body-flush { padding: 0; }

.section { margin: 0 0 46px; }
.section-head {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  margin-bottom: 20px; padding-bottom: 12px; border-bottom: 2px solid var(--line);
  position: relative;
}
.section-head::after {
  content: ''; position: absolute; left: 0; bottom: -2px;
  width: 62px; height: 3px; background: var(--accent); border-radius: 3px;
}
.section-head h2 { margin: 0; display: flex; align-items: center; gap: 10px; }
.section-bar { color: var(--accent); }
.view-all {
  font-family: var(--font); font-weight: 700; font-size: .84rem; color: var(--muted);
  display: inline-flex; align-items: center; gap: 5px; transition: color .15s;
}
.view-all:hover { color: var(--accent-dark); }
.view-all svg { width: 11px; height: 11px; fill: currentColor; }

/* avatars */
.avatar { border-radius: 50%; object-fit: cover; flex-shrink: 0; display: inline-grid; place-items: center; }
.avatar-initials {
  font-family: var(--font); font-weight: 700; color: #fff;
  background: hsl(var(--h, 160) 55% 45%);
}

/* -------------------------------------------------------------------
   9. Motion preferences
   Respect prefers-reduced-motion: visitors who get motion sickness (or
   simply dislike animation) still see a complete, static page. Every
   transition and animation is neutralised rather than removed, so any
   final state still applies.
   ------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    transition-delay: 0s !important;
    scroll-behavior: auto !important;
  }
  .sticky-side { position: static !important; }
}

/* Visible, high-contrast focus ring for keyboard users. */
:focus-visible {
  outline: 3px solid var(--accent, #2bb58e);
  outline-offset: 2px;
  border-radius: 4px;
}
