/* ============================================================
   PALMERBETT — Base: reset, elements, typography, utilities
   ============================================================ */

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

* { margin: 0; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  font-family: var(--font-body);
  font-size: var(--fs-400);
  line-height: var(--lh-base);
  color: var(--text);
  background-color: var(--bg);
  background-image:
    radial-gradient(110% 80% at 100% -10%, rgba(124, 77, 255, 0.16), transparent 55%),
    radial-gradient(90% 70% at -10% 0%, rgba(194, 75, 224, 0.10), transparent 60%);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
  overflow-x: hidden;
  overflow-wrap: break-word;
}

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

/* Iconify web component — scales with font-size like text */
iconify-icon {
  display: inline-flex;
  width: 1em;
  height: 1em;
  vertical-align: -0.125em;
  flex: none;
}

input, button, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: none; }

a { color: var(--accent-bright); text-decoration: none; transition: color var(--dur-fast) var(--ease); }
a:hover { color: var(--gold); }

ul[role="list"], ol[role="list"] { list-style: none; padding: 0; }

/* ---- Headings (Anton — single weight, dramatic) ---- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: var(--track-display);
}
h1, h2 { line-height: var(--lh-tight); text-transform: uppercase; }
h3, h4 { line-height: var(--lh-snug); }
h1 { font-size: var(--fs-900); }
h2 { font-size: var(--fs-800); }
h3 { font-size: var(--fs-700); }
h4 { font-size: var(--fs-600); }

p { color: var(--muted); }
p.lead { font-size: var(--fs-500); color: var(--text); }

strong { color: var(--text); font-weight: 700; }

/* ---- Selection & focus ---- */
::selection { background: var(--accent); color: #fff; }

:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---- Layout helpers ---- */
.container {
  width: min(100% - 2.5rem, var(--container));
  margin-inline: auto;
}
.container--wide { width: min(100% - 2.5rem, var(--container-wide)); }

.section { padding-block: clamp(3rem, 2rem + 5vw, 6rem); }
.section--tight { padding-block: clamp(2rem, 1.5rem + 3vw, 4rem); }

.stack > * + * { margin-top: var(--sp-4); }
.stack-lg > * + * { margin-top: var(--sp-6); }

/* ---- Typographic accents ---- */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-body);
  font-size: var(--fs-300);
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
}
.text-gradient {
  background: var(--grad-violet-magenta);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.text-gold { color: var(--gold); }
.text-muted { color: var(--muted); }
.measure { max-width: 60ch; }
.center { text-align: center; }
.mx-auto { margin-inline: auto; }

/* ---- Accessibility ---- */
.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;
}
.skip-link {
  position: absolute;
  left: 1rem; top: -100%;
  z-index: var(--z-toast);
  background: var(--gold);
  color: var(--on-accent);
  padding: 0.7rem 1.2rem;
  border-radius: var(--r-sm);
  font-weight: 700;
  transition: top var(--dur) var(--ease);
}
.skip-link:focus { top: 1rem; color: var(--on-accent); }

[hidden] { display: none !important; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}
