/* Basecamp by ZM Media — Gestaltung der Kladde.
   Handy zuerst, ruhig und erdig: keine Verläufe, keine Schatten, Systemschrift.
   Tippflächen mindestens 44px, Eingabefelder mindestens 16px Schrift, sonst
   zoomt iOS beim Antippen in das Formular hinein. */

:root {
  --petrol: #1E6E74;
  --petrol-dunkel: #175055;
  --tinte-hell: #E4EDEB;
  --ocker: #C8843C;
  --auf-ocker: #3F2408;
  --grund: #F7F2E8;
  --karte: #FFFFFF;
  --rand: #EDE5D3;
  --text: #2B2722;
  --gedaempft: #7C7264;

  --radius: 8px;
  --tippflaeche: 44px;
  --schrift: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;

  color-scheme: light;
}

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

html {
  font-size: 100%;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--grund);
  color: var(--text);
  font-family: var(--schrift);
  font-size: 1.0625rem;
  line-height: 1.55;
}

/* ------------------------------------------------------------------ Kopf */

.kopf {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.5rem 1rem;
  padding-top: calc(0.5rem + env(safe-area-inset-top));
  padding-left: calc(1rem + env(safe-area-inset-left));
  padding-right: calc(1rem + env(safe-area-inset-right));
  background: var(--petrol);
  color: var(--tinte-hell);
}

.marke {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  min-height: var(--tippflaeche);
  color: inherit;
  text-decoration: none;
}

.marke-zeichen {
  display: block;
  width: 34px;
  height: 34px;
  border-radius: 6px;
}

.marke-name {
  font-size: 1.125rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.kopf-aktion {
  margin: 0;
}

/* Abmelden ist ein Formular, damit es niemand von außen auslösen kann;
   aussehen soll es trotzdem wie ein Verweis. */
.verweis {
  min-height: var(--tippflaeche);
  padding: 0 0.25rem;
  border: 0;
  background: none;
  color: var(--tinte-hell);
  font: inherit;
  font-size: 0.9375rem;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}

/* ------------------------------------------------------------- Grundraster */

.inhalt {
  flex: 1;
  width: 100%;
  max-width: 34rem;
  margin: 0 auto;
  padding: 1rem;
  padding-left: calc(1rem + env(safe-area-inset-left));
  padding-right: calc(1rem + env(safe-area-inset-right));
}

.fuss {
  padding: 1.25rem 1rem;
  padding-bottom: calc(1.25rem + env(safe-area-inset-bottom));
  color: var(--gedaempft);
  font-size: 0.875rem;
  text-align: center;
}

.fuss p {
  margin: 0;
}

.karte {
  background: var(--karte);
  border: 1px solid var(--rand);
  border-radius: var(--radius);
  padding: 1.25rem;
  margin-bottom: 1rem;
}

.karte--schmal {
  max-width: 26rem;
  margin-left: auto;
  margin-right: auto;
}

.titel {
  margin: 0 0 0.5rem;
  font-size: 1.375rem;
  font-weight: 600;
  line-height: 1.25;
}

.hinweis {
  margin: 0 0 1.25rem;
  color: var(--gedaempft);
  font-size: 0.9375rem;
}

.statuszahl {
  margin: 0;
  color: var(--ocker);
  font-size: 0.9375rem;
  font-weight: 600;
  letter-spacing: 0.08em;
}

/* -------------------------------------------------------------- Meldungen */

.meldung {
  margin: 0 0 1rem;
  padding: 0.75rem 1rem;
  border-left: 4px solid var(--petrol);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: var(--tinte-hell);
  color: var(--text);
  font-size: 0.9375rem;
}

.meldung--schlecht {
  border-left-color: var(--ocker);
  background: #F6E7D6;
  color: var(--auf-ocker);
}

/* -------------------------------------------------------------- Formulare */

.formular {
  margin: 0;
}

.feld {
  margin-bottom: 1.125rem;
}

.feld label {
  display: block;
  margin-bottom: 0.375rem;
  font-size: 0.9375rem;
  font-weight: 600;
}

.feld-erklaerung {
  margin: 0.375rem 0 0;
  color: var(--gedaempft);
  font-size: 0.875rem;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="search"],
input[type="url"],
input[type="date"],
input[type="file"],
select,
textarea {
  display: block;
  width: 100%;
  min-height: var(--tippflaeche);
  padding: 0.625rem 0.75rem;
  border: 1px solid var(--rand);
  border-radius: var(--radius);
  background: var(--karte);
  color: var(--text);
  font-family: inherit;
  font-size: 1rem; /* nie kleiner: sonst zoomt iOS beim Antippen */
  line-height: 1.4;
  -webkit-appearance: none;
  appearance: none;
}

select {
  /* eigener Pfeil entfällt bewusst; die Systemdarstellung bleibt erhalten */
  appearance: auto;
  -webkit-appearance: menulist;
}

textarea {
  min-height: 8rem;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--petrol);
  outline: 2px solid var(--petrol);
  outline-offset: 1px;
}

/* ----------------------------------------------------------------- Knöpfe */

.knopf {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 48px;
  padding: 0.75rem 1.25rem;
  border: 1px solid var(--petrol);
  border-radius: var(--radius);
  background: var(--petrol);
  color: var(--tinte-hell);
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}

.knopf:active {
  background: var(--petrol-dunkel);
  border-color: var(--petrol-dunkel);
}

.knopf--zweit {
  background: transparent;
  color: var(--petrol);
}

.knopf--zweit:active {
  background: var(--tinte-hell);
}

.knopf--ocker {
  background: var(--ocker);
  border-color: var(--ocker);
  color: var(--auf-ocker);
}

.knopf[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
}

.knopf + .knopf {
  margin-top: 0.75rem;
}

/* ------------------------------------------------------------------ Listen */

.liste {
  margin: 0;
  padding: 0;
  list-style: none;
}

.liste li + li {
  margin-top: 0.75rem;
}

.marke-zustand {
  display: inline-block;
  padding: 0.125rem 0.5rem;
  border: 1px solid var(--rand);
  border-radius: 999px;
  color: var(--gedaempft);
  font-size: 0.8125rem;
  font-weight: 600;
}

.marke-zustand--freigegeben {
  border-color: var(--petrol);
  color: var(--petrol);
}

.marke-zustand--entwurf {
  border-color: var(--ocker);
  color: var(--auf-ocker);
}

a {
  color: var(--petrol-dunkel);
  text-underline-offset: 3px;
}

/* --------------------------------------------------------- Bedienbarkeit */

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

@media (min-width: 40rem) {
  .inhalt {
    padding: 2rem 1.5rem;
  }

  .knopf {
    width: auto;
    min-width: 12rem;
  }
}
