/* ═══════════════════════════════════════════════════════════
   edBuddy Pro — base.css   (loaded first on every page)
   Brand tokens, type, focus, motion preferences, and the small
   site-wide UI that site.js creates: toast + cookie banner.
   Page styles live in their own file (home.css, course.css …)
   and the shared nav / footer / bottom bar in components.css.
   ═══════════════════════════════════════════════════════════ */

/* Figtree, self-hosted (SIL OFL — see /fonts/OFL.txt). Latin-ext carries ₹. */
@font-face { font-family: 'Figtree'; font-style: normal; font-weight: 300 900; font-display: swap;
  src: url(/fonts/figtree-latin-wght-normal.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Figtree'; font-style: normal; font-weight: 300 900; font-display: swap;
  src: url(/fonts/figtree-latin-ext-wght-normal.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+A720-A7FF; }
@font-face { font-family: 'Figtree'; font-style: italic; font-weight: 300 900; font-display: swap;
  src: url(/fonts/figtree-latin-wght-italic.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+2000-206F; }

:root {
  --ebp-blue: #0559B3;
  --ebp-blue-600: #044A96;
  --ebp-navy: #06213D;
  --ebp-ink: #0B1220;
  --ebp-muted: #5A6B82;
  --ebp-line: #E3E8EF;
  --ebp-paper: #FBFAF7;
  --ebp-font: 'Figtree', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --ebp-ease: cubic-bezier(0.22, 1, 0.36, 1);
}

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { font-family: var(--ebp-font); font-optical-sizing: auto; text-rendering: optimizeLegibility; }

:focus-visible { outline: 2px solid var(--ebp-blue); outline-offset: 3px; border-radius: 4px; }

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

/* ── buttons used by site.js UI ── */
.ebp-btn {
  font: 600 14px/1 var(--ebp-font); letter-spacing: .01em;
  padding: 12px 18px; border-radius: 8px; border: 1px solid var(--ebp-blue);
  background: var(--ebp-blue); color: #fff; cursor: pointer;
  transition: background .2s var(--ebp-ease), color .2s var(--ebp-ease);
}
.ebp-btn:hover { background: var(--ebp-blue-600); }
.ebp-btn--ghost { background: transparent; color: var(--ebp-ink); border-color: var(--ebp-line); }
.ebp-btn--ghost:hover { background: #F3F5F8; }

/* ── toast ── */
.ebp-toast {
  position: fixed; left: 50%; bottom: 88px; z-index: 1200;
  transform: translate(-50%, 16px); opacity: 0; pointer-events: none;
  max-width: min(92vw, 440px); padding: 14px 18px; border-radius: 10px;
  background: var(--ebp-navy); color: #fff; font: 500 14px/1.45 var(--ebp-font);
  transition: opacity .25s var(--ebp-ease), transform .25s var(--ebp-ease);
}
.ebp-toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* ── cookie banner ── */
.ebp-consent {
  position: fixed; z-index: 1100; left: 16px; right: 16px; bottom: 16px;
  max-width: 420px; padding: 20px; border-radius: 12px;
  background: #fff; color: var(--ebp-ink); border: 1px solid var(--ebp-line);
  box-shadow: 0 18px 50px -20px rgba(6, 33, 61, .35);
  transform: translateY(24px); opacity: 0;
  transition: opacity .35s var(--ebp-ease), transform .35s var(--ebp-ease);
}
.ebp-consent.is-on { opacity: 1; transform: none; }
.ebp-consent-t { margin: 0 0 6px; font: 700 15px/1.3 var(--ebp-font); }
.ebp-consent-d { margin: 0 0 16px; font: 400 13.5px/1.55 var(--ebp-font); color: var(--ebp-muted); }
.ebp-consent-d a { color: var(--ebp-blue); }
.ebp-consent-a { display: flex; gap: 8px; }
.ebp-consent-a .ebp-btn { flex: 1; }
@media (min-width: 720px) { .ebp-consent { left: 24px; bottom: 24px; } }

/* ── skip link: first tab stop on every page ── */
.skip-link { position: fixed; z-index: 2000; left: 12px; top: 12px; padding: 10px 14px; border-radius: 8px;
  background: var(--ebp-navy); color: #fff; font: 600 14px var(--ebp-font); text-decoration: none;
  transform: translateY(-160%); transition: transform .2s var(--ebp-ease); }
.skip-link:focus { transform: none; }
#content:focus { outline: none; }

/* ── environment label (staging / test / preview / local only; see site.js) ── */
.ebp-env { position: fixed; left: 50%; top: 0; transform: translateX(-50%); z-index: 2000; pointer-events: none;
  padding: 3px 10px 4px; border-radius: 0 0 6px 6px; font: 700 11px/1.2 var(--ebp-font); letter-spacing: .1em; text-transform: uppercase;
  color: #fff; background: #B45309; box-shadow: 0 4px 14px rgba(0,0,0,.18); }
.ebp-env--test { background: #7C3AED; }
.ebp-env--preview, .ebp-env--local { background: #475569; }
