/* Reset + typography + CSS custom property contract */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-size: var(--font-size-base);
  line-height: var(--line-height-body);
  color: var(--text-primary);
  background: var(--bg-primary);
  transition: background-color 150ms ease, color 150ms ease;
  min-height: 100vh;
}

/* Default property contract (terminal fallback) */
:root {
  --bg-primary: #0a0e14;
  --bg-secondary: #0f1520;
  --bg-card: rgba(15, 25, 40, 0.8);
  --bg-code: rgba(0, 255, 136, 0.06);
  --text-primary: #c5f0c5;
  --text-secondary: #8ab8a0;
  --text-muted: #4a6a5a;
  --text-accent: #00ff88;
  --text-link: #00dd77;
  --border-primary: rgba(0, 255, 136, 0.15);
  --border-accent: rgba(0, 255, 136, 0.3);
  --border-width: 1px;
  --border-radius: 6px;
  --glow-color: rgba(0, 255, 136, 0.1);
  --shadow-card: 0 0 20px rgba(0, 255, 136, 0.08);
  --font-body: 'Inter', sans-serif;
  --font-heading: 'Space Grotesk', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
  --font-size-base: 1rem;
  --line-height-body: 1.7;
  --transition-speed: 150ms;
  --scanline-opacity: 0;
  --blur-amount: 0px;
  --max-width: 740px;
}

a { color: var(--text-link); text-decoration: none; transition: color var(--transition-speed) ease; }
a:hover { color: var(--text-accent); }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  color: var(--text-primary);
}

code, pre {
  font-family: var(--font-mono);
  font-size: 0.9em;
}

pre {
  background: var(--bg-code);
  border: var(--border-width) solid var(--border-primary);
  border-radius: var(--border-radius);
  padding: 1rem 1.25rem;
  overflow-x: auto;
  margin: 1.5rem 0;
}

code {
  background: var(--bg-code);
  padding: 0.15em 0.4em;
  border-radius: 3px;
}

pre code {
  background: none;
  padding: 0;
  border-radius: 0;
}

img { max-width: 100%; height: auto; border-radius: var(--border-radius); }

hr {
  border: none;
  border-top: var(--border-width) solid var(--border-primary);
  margin: 2.5rem 0;
}

blockquote {
  border-left: 3px solid var(--text-accent);
  padding: 0.5rem 1rem;
  margin: 1.5rem 0;
  color: var(--text-secondary);
  font-style: italic;
}

ul, ol { padding-left: 1.5rem; margin: 1rem 0; }
li { margin: 0.3rem 0; }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
  position: relative;
  z-index: 1;
}

::selection {
  background: var(--text-accent);
  color: var(--bg-primary);
}
