/* ═══════════════════════════════════════════════════════════════
   Stratum Books V2 — Base / Reset
   Industrial Core: Technical Typography + Precision Reset
   ═══════════════════════════════════════════════════════════════ */

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

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

body {
  font-family: var(--font-sans);
  font-size: var(--text-base);
  color: var(--color-text);
  background: var(--color-background);
  line-height: var(--leading-normal);
  font-feature-settings: 'ss01' on, 'ss02' on;
}

/* Technical Typography — uppercase system headers */
h1 {
  font-size: var(--text-2xl);
  font-weight: var(--weight-bold);
  line-height: var(--leading-tight);
  color: var(--color-text);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

h2 {
  font-size: var(--text-xl);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-tight);
  color: var(--color-text);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

h3 {
  font-size: var(--text-lg);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-tight);
  color: var(--color-text);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

h4 {
  font-size: var(--text-base);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-tight);
  color: var(--color-text);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

p { line-height: var(--leading-normal); }

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

code, pre {
  font-family: var(--font-mono);
  font-size: var(--text-sm);
}

/* Focus-visible — instrument-grade precision ring */
:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

:focus:not(:focus-visible) {
  outline: none;
  box-shadow: none;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* Scrollbar — thin, industrial */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb {
  background: var(--color-border);
  border-radius: var(--radius-md);
}
::-webkit-scrollbar-thumb:hover { background: var(--color-text-muted); }

/* Selection — Safety Orange */
::selection {
  background: rgba(252, 148, 48, 0.25);
  color: inherit;
}
