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

html {
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 16px;
  line-height: 1.75;
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  min-height: 100vh;
  background-color: var(--bg);
  color: var(--text);
  overflow-x: hidden;
  transition: background-color 0.2s ease, color 0.2s ease;
}

h1, h2, h3, h4 {
  font-family: var(--font-mono);
  font-weight: 700;
  color: var(--text);
}

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

a {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 0.22em;
  text-decoration-color: var(--text-faint);
  transition: text-decoration-color 0.15s ease, color 0.15s ease;
}

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

button {
  font: inherit;
  color: inherit;
  background: none;
  border: none;
  cursor: pointer;
}

:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 3px;
}

.noscript-banner {
  padding: 1rem var(--pad-x);
  background-color: var(--bg-elevated);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 0.875rem;
  text-align: center;
}
[hidden] {
  display: none !important;
}
