/* =============================================================================
 * base.css — document defaults, expressed in design-system tokens
 * =============================================================================
 * Load order: tokens.css -> base.css -> components.css -> wizard.css.
 * Nothing here is wizard-specific; it is what every screen can assume.
 * ========================================================================== */

/* Inter is the design system's typeface (website: `next/font/google` Inter, weights
 * 300-700, latin). Vendored rather than linked because the egress gate DROPs
 * fonts.gstatic.com while the evaluator is on the full-tunnel profile — see
 * ../../tools/fonts.md. One variable file covers 400-700. */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('/fonts/inter-latin-var.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;
}

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

body {
  margin: 0;
  font-family: var(--font-sans);
  /* The DS's body step. Its pairing is textMd 16px / 24px, and 24/16 = 1.5 — written as a
   * ratio, not as var(--lh-text-md), so that the ~20 rules in wizard.css which set only a
   * font-size keep sensible leading instead of inheriting a flat 24px. Anything that wants
   * an exact DS step has the paired .ovpn-text-* / .ovpn-display-* classes in
   * components.css. */
  font-size: var(--fs-text-md);
  line-height: 1.5;
  font-weight: var(--fw-regular);
  /* NOTE: this is the wizard's existing body colour, now named. It is the DS's darkest
   * brand blue, not its body-copy neutral (--c-neutral-body, #404968). Whether body copy
   * should move to the neutral ramp is a UX-pass decision, not a token-plumbing one. */
  color: var(--c-brand-blueActive);
  background: var(--c-neutral-white);
  -webkit-font-smoothing: antialiased;
}

/* One focus ring for the whole app, from the DS's outline tokens (it is a box-shadow there,
 * not an `outline`). `:focus-visible` so a mouse click on a button does not leave a ring
 * behind while keyboard tabbing does.
 *
 * Deliberately does NOT set border-radius: the shadow already follows whatever radius the
 * element has, and forcing one here would square off the pill-shaped controls (rail steps,
 * countdown, chips — all 999px) the moment they take focus. */
:focus-visible {
  outline: none;
  box-shadow: var(--o-primary);
}

/* The wizard runs on a countdown and animates the rail; respect the OS setting. */
@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;
  }
}

/* Visible to screen readers, not to eyes. For labels the layout cannot show. */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}
