/* ==========================================================================
   BASE — reset, typography, global element styles
   ========================================================================== */

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

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

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

body {
  background: var(--color-bg);
  color: var(--color-fg);
  font-family: var(--font-body);
  font-size: var(--fs-base);
  line-height: var(--lh-normal);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100dvh;
  overflow-x: hidden;
  position: relative;
}

/* Subtle film-grain / vignette so pure black doesn't feel flat */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: var(--z-base);
  background: var(--gradient-radial-glow);
  opacity: 0.6;
  mix-blend-mode: screen;
}

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

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

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

ul, ol {
  list-style: none;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: var(--lh-tight);
  letter-spacing: var(--ls-tight);
  text-wrap: balance;
}

p {
  text-wrap: pretty;
}

::selection {
  background: var(--color-accent);
  color: var(--color-on-accent);
}

/* Custom scrollbar (progressive enhancement, webkit only) */
::-webkit-scrollbar {
  width: 10px;
}
::-webkit-scrollbar-track {
  background: var(--color-bg);
}
::-webkit-scrollbar-thumb {
  background: var(--color-surface-2);
  border-radius: var(--radius-pill);
  border: 2px solid var(--color-bg);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--color-accent-deep);
}

/* Focus states — visible everywhere, on-brand */
:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

/* Skip link */
.skip-link {
  position: absolute;
  top: -100px;
  left: var(--space-4);
  background: var(--color-accent);
  color: var(--color-on-accent);
  padding: var(--space-3) var(--space-5);
  border-radius: var(--radius-sm);
  font-weight: 600;
  z-index: var(--z-toast);
  transition: top var(--dur-base) var(--ease-out);
}
.skip-link:focus {
  top: var(--space-4);
}

/* ==========================================================================
   LAYOUT UTILITIES
   ========================================================================== */

.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--container-pad);
}

.section {
  position: relative;
  padding-block: var(--space-10);
  z-index: 1;
}

.section-inner {
  position: relative;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ==========================================================================
   TYPOGRAPHY UTILITIES
   ========================================================================== */

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-family: var(--font-body);
  font-size: var(--fs-2xs);
  font-weight: 600;
  letter-spacing: var(--ls-wider);
  text-transform: uppercase;
  color: var(--color-accent-soft);
}

.eyebrow::before {
  content: "";
  width: 22px;
  height: 1px;
  background: var(--color-accent);
}

.section-title {
  font-size: var(--fs-h2);
  font-weight: 600;
  color: var(--color-fg);
  margin-top: var(--space-4);
}

.section-title em {
  font-style: italic;
  color: var(--color-accent-soft);
}

.section-lede {
  font-size: var(--fs-md);
  color: var(--color-fg-muted);
  max-width: 46ch;
  margin-top: var(--space-4);
  line-height: var(--lh-relaxed);
}

.text-accent {
  color: var(--color-accent);
}

.font-display {
  font-family: var(--font-display);
}
