/* ============================================================
   UK Broker Support — Base element defaults
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }

/* Anchor scroll: land below the sticky 78px header with breathing room,
   not with the target flush against it. Applies to every in-page anchor
   target site-wide (nav links, "Services that apply most" deep-links,
   the skip link, etc.) via the universal [id] selector so nothing needs
   fixing one-off as new sections/ids are added. */
html { scroll-behavior: smooth; }
[id] { scroll-margin-top: 94px; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  background: var(--surface-page);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: var(--leading-normal);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: var(--weight-extrabold);
  line-height: var(--leading-snug);
  letter-spacing: var(--tracking-tight);
  margin: 0;
}

a { color: var(--text-link); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

.ukbs-eyebrow {
  font-family: var(--font-display);
  font-weight: var(--weight-bold);
  font-size: var(--text-3xs);
  letter-spacing: var(--tracking-eyebrow);
  text-transform: uppercase;
}

.ukbs-accent {
  font-family: var(--font-accent);
  font-style: italic;
  font-weight: var(--weight-medium);
}

::selection { background: var(--aqua); color: var(--charcoal); }

/* Focus states — visible everywhere, no outline: none anywhere in this project */
:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 2px;
}

/* ============================================================
   Scroll reveal (locked) — fade + short upward settle as elements
   enter the viewport. Toggled by assets/js/scroll-reveal.js via
   IntersectionObserver.
   ============================================================ */
[data-reveal] {
  opacity: 0;
  transform: translateY(var(--reveal-distance-y));
  transition: opacity var(--reveal-duration) var(--ease-out),
              transform var(--reveal-duration) var(--ease-out);
  transition-delay: var(--reveal-delay, 0ms);
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}
