/* Reset & Base */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-body, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif);
  background: var(--color-background, #fff);
  color: var(--color-text, #111);
  line-height: 1.6;
  transition: background 0.3s, color 0.3s;
  overflow-x: hidden;
}
img, video, canvas, svg { max-width: 100%; height: auto; display: block; }
a { color: var(--color-primary, #0066cc); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4, h5, h6 { font-family: var(--font-heading, var(--font-body)); line-height: 1.2; }
:focus-visible { outline: 2px solid var(--color-primary); outline-offset: 2px; }

/* Responsive helpers */
.container { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 1rem; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

/* Dark mode override class */
.dark { --color-background: #121212; --color-text: #f5f5f5; }
@media (prefers-color-scheme: dark) {
  :root:not(.light) { --color-background: #121212; --color-text: #f5f5f5; }
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}