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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 0.95rem;
  line-height: 1.5;
  min-height: 100vh;
  transition: background-color 200ms var(--ease), color 200ms var(--ease);
}

h1, h2, h3, h4, p {
  margin: 0;
}

h1 {
  font-size: clamp(2rem, 4vw, 2.8rem);
  line-height: 1.05;
  letter-spacing: -0.04em;
  font-weight: 800;
  color: var(--text-title);
}

h2 {
  font-size: 1.35rem;
  letter-spacing: -0.02em;
  font-weight: 700;
  color: var(--text-title);
}

h3 {
  font-size: 1rem;
  letter-spacing: -0.01em;
  font-weight: 700;
  color: var(--text-title);
}

a {
  color: inherit;
}

button, input, select, textarea {
  font: inherit;
  color: inherit;
}

img {
  max-width: 100%;
  display: block;
}

.kicker {
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-secondary);
}

.small {
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.mono {
  font-variant-numeric: tabular-nums;
}

.muted {
  color: var(--text-secondary);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--primary);
  color: var(--primary-contrast);
  padding: 8px 16px;
  border-radius: 0 0 var(--r-sm) 0;
  font-weight: 700;
  z-index: 9999;
  transition: top 120ms var(--ease);
}

.skip-link:focus {
  top: 0;
}

:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
  border-radius: var(--r-sm);
}

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

.app-shell {
  width: min(1400px, calc(100vw - 28px));
  margin: 0 auto;
  padding: 16px 0 48px;
  display: grid;
  gap: 18px;
}

@media (max-width: 760px) {
  .app-shell {
    width: calc(100vw - 20px);
    padding: 10px 0 32px;
    gap: 12px;
  }
}
