/* ============================================================
   Heathrow Helper — Base
   Reset, body, typography defaults, focus rings, motion guards.
   Depends on: tokens.css (loaded first).
   ============================================================ */

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

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
}

body {
  font-family: var(--font-sans);
  font-size: var(--text-md);
  line-height: var(--leading-normal);
  color: var(--ink-body);
  background: var(--bg-page);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  font-feature-settings: "ss01", "cv11";  /* Geist stylistic alts */
}

/* --- Typography defaults --------------------------------- */

h1, h2, h3, h4, h5, h6 {
  color: var(--ink-strong);
  font-weight: 600;
  line-height: var(--leading-snug);
  letter-spacing: -0.01em;
  margin: 0;
}

p { margin: 0; }

a {
  color: var(--brand-accent);
  text-decoration: none;
  transition: opacity var(--dur-fast) var(--ease-out);
}
a:hover { opacity: 0.78; text-decoration: underline; }

strong { color: var(--ink-strong); font-weight: 600; }
em { font-style: italic; color: var(--ink-muted); }

code, kbd, samp {
  font-family: var(--font-mono);
  font-size: 0.92em;
  background: var(--bg-inset);
  padding: 1px 6px;
  border-radius: var(--radius-sm);
  color: var(--ink-strong);
}

/* --- Eyebrow / overline utility -------------------------- */

.eyebrow {
  font-family: var(--font-mono);
  font-size: var(--text-2xs);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--brand-accent-2);
  font-weight: 500;
}

/* --- Form & interactive baseline ------------------------- */

button, input, textarea, select {
  font: inherit;
  color: inherit;
}

button {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  color: inherit;
}

input, textarea { background: transparent; border: none; outline: none; }

/* --- Focus ring (universal :focus-visible) --------------- */

:focus { outline: none; }

:focus-visible {
  outline: none;
  box-shadow: var(--shadow-focus);
  border-radius: var(--radius-md);
}

/* When the focused element is already pill-shaped, keep the
   ring conforming. */
button:focus-visible,
a:focus-visible,
input:focus-visible {
  outline: none;
}

/* --- Screen reader only ---------------------------------- */

.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;
  top: -40px;
  left: var(--space-3);
  background: var(--brand-navy);
  color: var(--ink-inverse);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-md);
  font-size: var(--text-sm);
  font-weight: 500;
  z-index: 100;
  transition: top var(--dur-base) var(--ease-out);
}
.skip-link:focus { top: var(--space-3); }

/* --- Selection ------------------------------------------- */

::selection {
  background: var(--brand-accent-soft);
  color: var(--ink-strong);
}

/* --- Scrollbars (subtle) --------------------------------- */

* {
  scrollbar-width: thin;
  scrollbar-color: var(--line-strong) transparent;
}
*::-webkit-scrollbar { width: 8px; height: 8px; }
*::-webkit-scrollbar-track { background: transparent; }
*::-webkit-scrollbar-thumb {
  background: var(--line-strong);
  border-radius: var(--radius-pill);
}
*::-webkit-scrollbar-thumb:hover { background: var(--ink-subtle); }

/* --- Reduced motion -------------------------------------- */

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