/* Grundstil: Normalisierung, Typografie, Fokus, Bewegung. */
*, *::before, *::after { box-sizing: border-box; }
/* Das Attribut hidden gilt immer, auch wenn eine Klasse display setzt (z. B. .btn). */
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh;
  font-family: var(--font-sans); font-size: var(--text-md); line-height: var(--leading);
  color: var(--text); background: var(--bg);
  -webkit-font-smoothing: antialiased;
  transition: background-color var(--dur-med) var(--ease-out), color var(--dur-med) var(--ease-out);
}
h1, h2, h3, h4 { margin: 0 0 var(--space-3); line-height: 1.25; font-weight: var(--weight-bold); letter-spacing: -0.01em; }
h1 { font-size: var(--text-2xl); } h2 { font-size: var(--text-xl); } h3 { font-size: var(--text-lg); }
p { margin: 0 0 var(--space-3); }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
code, kbd { font-family: var(--font-mono); font-size: 0.9em; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus { outline: none; }
:focus-visible { box-shadow: var(--focus-ring); border-radius: var(--radius-sm); }
::selection { background: var(--accent-soft); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.muted { color: var(--text-muted); }
.faint { color: var(--text-faint); }

/* Weniger Bewegung, wenn gewünscht (Barrierefreiheit) */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; scroll-behavior: auto !important; }
}
:root[data-motion="reduced"] *, :root[data-motion="reduced"] *::before, :root[data-motion="reduced"] *::after {
  animation-duration: 1ms !important; transition-duration: 1ms !important;
}

@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes pop-in { from { opacity: 0; transform: translateY(4px) scale(0.98); } to { opacity: 1; transform: none; } }
@keyframes slide-in-right { from { transform: translateX(24px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes toast-in { from { transform: translateY(12px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes shimmer { from { background-position: -200px 0; } to { background-position: 200px 0; } }
