/* =========================================================================
   PRESTIGE — Reset & base element styles
   ========================================================================= */

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

html {
  font-size: var(--fs-root);
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  color-scheme: dark;
}

html, body { height: 100%; cursor: auto; }

body {
  font-family: var(--font-body);
  background: var(--surface-0);
  color: var(--text-secondary);
  line-height: var(--lh-normal);
  font-size: var(--fs-base);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: clip;
}

body.is-locked { overflow: hidden; }

img, picture, video, canvas, svg { display: block; max-width: 100%; }
img { height: auto; }

input, button, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: none; padding: 0; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; padding: 0; }
table { border-collapse: collapse; }
address { font-style: normal; }

::selection { background: rgba(var(--c-gold-rgb), 0.32); color: var(--text-primary); }

/* ---- Focus states — always visible, on-brand, never suppressed ---- */
:focus-visible {
  outline: 2px solid var(--c-gold-400);
  outline-offset: 3px;
  border-radius: var(--r-xs);
}

/* ---- Scrollbar --------------------------------------------------------- */
html { scrollbar-color: rgba(var(--c-gold-rgb), 0.4) var(--surface-0); scrollbar-width: thin; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: var(--surface-0); }
::-webkit-scrollbar-thumb { background: rgba(var(--c-gold-rgb), 0.35); border-radius: var(--r-pill); border: 2px solid var(--surface-0); }
::-webkit-scrollbar-thumb:hover { background: rgba(var(--c-gold-rgb), 0.6); }

/* ---- Typography --------------------------------------------------------- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 500;
  color: var(--text-primary);
  line-height: var(--lh-snug);
  letter-spacing: var(--ls-tight);
}

h1 { font-size: var(--fs-5xl); line-height: var(--lh-tight); }
h2 { font-size: var(--fs-3xl); }
h3 { font-size: var(--fs-2xl); }
h4 { font-size: var(--fs-xl); font-family: var(--font-body); font-weight: 600; }
h5 { font-size: var(--fs-lg); font-family: var(--font-body); font-weight: 600; }
h6 { font-size: var(--fs-md); font-family: var(--font-body); font-weight: 600; }

p { color: var(--text-secondary); line-height: var(--lh-normal); }

a[href] { cursor: pointer; }

.lede {
  font-size: var(--fs-lg);
  font-weight: 400;
  line-height: var(--lh-relaxed);
  color: var(--text-secondary);
}

small, .text-sm { font-size: var(--fs-sm); }

strong, b { font-weight: 600; color: var(--text-primary); }
em, i.italic { font-style: italic; }

.font-display { font-family: var(--font-display); }
.italic-serif { font-family: var(--font-display); font-style: italic; font-weight: 400; }

/* ---- Generic utility layer (small, purposeful — not a framework) ------- */
.u-visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}

.u-nowrap { white-space: nowrap; }
.u-text-gold { color: var(--text-gold); }
.u-text-primary { color: var(--text-primary); }
.u-text-center { text-align: center; }

.skip-link {
  position: fixed;
  top: -100px;
  left: var(--sp-4);
  z-index: var(--z-toast);
  background: var(--c-gold-400);
  color: var(--text-on-gold);
  padding: var(--sp-3) var(--sp-5);
  border-radius: var(--r-sm);
  font-weight: 600;
  transition: top var(--dur-fast) var(--ease-out-soft);
}
.skip-link:focus { top: var(--sp-4); }
