/* docs/assets/css/base.css
   Reset, body, typography, grain overlay, container, hero.
   Depends on tokens.css. */

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

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.7;
  overflow-x: hidden;
}

.grain {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.015'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--sp-5);
}

.container-wide {
  max-width: var(--max-wide);
  margin: 0 auto;
  padding: 0 var(--sp-5);
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.15;
}

h1 {
  font-size: clamp(3rem, 8vw, 5.5rem);
  letter-spacing: -0.02em;
}

h2 {
  font-size: clamp(2rem, 5vw, 3rem);
  letter-spacing: -0.01em;
}

h3 {
  font-size: 1.5rem;
}

em {
  font-style: italic;
  color: var(--accent);
}

p {
  margin-bottom: var(--sp-3);
}

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

a:hover {
  color: var(--text);
}

a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

a:active {
  opacity: 0.7;
}

/* Hero */
.hero {
  padding: var(--sp-7) 0 var(--sp-6);
  position: relative;
}

.hero-label {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: var(--sp-4);
}

.hero h1 {
  margin-bottom: var(--sp-3);
}

.hero-sub {
  font-size: 1.25rem;
  color: var(--text-muted);
  max-width: 36rem;
}

/* Section primitives */
.section {
  padding: var(--sp-6) 0;
  border-top: 1px solid var(--border);
}

.section-number {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  color: var(--accent);
  margin-bottom: var(--sp-3);
}

.section-tagline {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.5rem;
  color: var(--text-muted);
  margin-bottom: var(--sp-4);
}

/* Footer */
.footer {
  padding: var(--sp-6) 0;
  border-top: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 0.875rem;
  color: var(--text-muted);
  text-align: center;
}
