/* ==========================================================================
   Reset + document primitives
   ========================================================================== */

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

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

body {
  margin: 0;
  min-height: 100vh;
  background-color: var(--bg-base);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: var(--fs-base);
  line-height: var(--lh-normal);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-variant-numeric: tabular-nums;
}

/* Ambient light — two soft radial washes fixed behind all content.
   Kept on a pseudo-element so it never enters the scroll or paint path
   of the cards that blur against it. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(
      58rem 42rem at 12% -8%,
      rgba(247, 147, 26, 0.10),
      transparent 62%
    ),
    radial-gradient(
      52rem 40rem at 92% 4%,
      rgba(57, 135, 229, 0.10),
      transparent 60%
    ),
    radial-gradient(
      44rem 40rem at 50% 108%,
      rgba(144, 133, 233, 0.07),
      transparent 62%
    );
}

h1,
h2,
h3,
h4 {
  margin: 0;
  font-weight: var(--fw-semibold);
  line-height: var(--lh-tight);
  letter-spacing: var(--tracking-heading);
}

p {
  margin: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

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

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

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

table {
  border-collapse: collapse;
  width: 100%;
}

canvas {
  display: block;
}

svg {
  display: block;
  flex-shrink: 0;
}

/* --- Focus -------------------------------------------------------------- */

:focus {
  outline: none;
}

/* No border-radius here. Outlines already follow the element's own radius,
   and setting one made every focused control change shape — a 10px button
   snapping to 6px the moment it was tabbed to. */
:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

/* --- Scrollbars --------------------------------------------------------- */

* {
  scrollbar-width: thin;
  scrollbar-color: var(--surface-3) transparent;
}

*::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

*::-webkit-scrollbar-track {
  background: transparent;
}

*::-webkit-scrollbar-thumb {
  background-color: var(--surface-3);
  border: 3px solid transparent;
  border-radius: var(--radius-pill);
  background-clip: content-box;
}

*::-webkit-scrollbar-thumb:hover {
  background-color: #2e3a4b;
}

/* --- Utilities ---------------------------------------------------------- */




/* Visible to screen readers 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 — first tab stop, hidden until focused. */
.skip-link {
  position: absolute;
  top: var(--sp-3);
  left: var(--sp-3);
  z-index: var(--z-toast);
  padding: var(--sp-2) var(--sp-4);
  border-radius: var(--radius-md);
  background: var(--brand);
  color: var(--text-inverse);
  font-weight: var(--fw-semibold);
  transform: translateY(-200%);
  transition: transform var(--dur-fast) var(--ease-out);
}

.skip-link:focus-visible {
  transform: translateY(0);
}

[hidden] {
  display: none !important;
}
