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

/* Komponenten verwenden häufig eigene display-Regeln (flex/grid). Ohne
   Autor-Regel können diese die native Browser-Regel für `[hidden]`
   überschreiben und ein fachlich ausgeblendetes Element wieder sichtbar
   machen. `hidden` bleibt deshalb projektweit verbindlich. */
[hidden] {
  display: none !important;
}

html, body {
  height: 100%;
  /* Nur die Inhalte der Smartphone-Shell scrollen, nicht die Seite. */
  overflow: hidden;
  overscroll-behavior: none;
}

body {
  margin: 0;
  font-family: var(--font-ui);
  font-size: var(--fs-body);
  font-weight: 400;
  color: var(--color-text-primary);
  background: var(--color-surface-app);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  margin: 0;
  font-weight: 900;
  color: var(--color-text-primary);
}

p {
  margin: 0;
}

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

/* Unter 16 px zoomt iOS beim Fokussieren automatisch in Formularfelder. */
input:not([type="checkbox"]):not([type="radio"]):not([type="range"]),
textarea:not([readonly]):not([disabled]),
select:not([disabled]) {
  font-size: 16px;
}

button {
  cursor: pointer;
}

ul, dl, dd {
  margin: 0;
  padding: 0;
  list-style: none;
}

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

:focus-visible {
  outline: 2px solid var(--color-pearl-aqua);
  outline-offset: 2px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}
