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

:root { color-scheme: light dark; }
:root[data-theme="dark"] { color-scheme: dark; }
:root[data-theme="light"] { color-scheme: light; }

html, body { height: 100%; }

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: var(--text-md);
  line-height: 1.55;
  background: var(--page);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* Links */
a { color: var(--accent-500); text-decoration: none; }
a:hover { text-decoration: underline; }

.container {
  width: min(1180px, calc(100% - 2 * var(--space-6)));
  margin: 0 auto;
}

.hr {
  height: 1px;
  background: var(--border);
  border: 0;
  margin: var(--space-6) 0;
}

:focus-visible {
  outline: 3px solid rgba(59, 130, 246, 0.35); /* one accent */
  outline-offset: 2px;
  border-radius: 10px;
}

/* Minimal utilities (small set only) */
.flex { display: flex; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.wrap { flex-wrap: wrap; }
.gap-2 { gap: var(--space-2); }
.gap-3 { gap: var(--space-3); }
.gap-4 { gap: var(--space-4); }
.gap-5 { gap: var(--space-5); }
.gap-6 { gap: var(--space-6); }

/* Reduce motion */
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
