/* FITVYR Zentrale – schlicht, schnell, fürs Handy. Farben wie die Website: Weiß, Anthrazit, Sand #D8CA9F, keine Schatten. */
:root {
  --papier: #ffffff; --anth: #1d1d1d; --text: #3a3833; --grau: #6d685e; --sand: #d8ca9f; --sandhell: #f4efe2;
  --linie: #ddd3bd; --rahmen: #857c69; --hell: #f1f1ef; --gut: #3f6b4e; --guthell: #e7efe9; --warn: #8c2f23; --warnhell: #f6e7e4;
  --schrift: "Helvetica Neue", Helvetica, Arial, system-ui, sans-serif;
  --r: 14px; --r-feld: 10px;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--papier); color: var(--anth); font: 16px/1.45 var(--schrift); }
a { color: inherit; }
h1 { font-size: 24px; line-height: 1.2; margin: 4px 0 16px; letter-spacing: -.01em; }
h2 { font-size: 18px; margin: 28px 0 10px; }
h3 { font-size: 15px; margin: 18px 0 6px; text-transform: uppercase; letter-spacing: .06em; color: var(--grau); }
p { margin: 0 0 10px; }
[hidden] { display: none !important; }
.klein { font-size: 13px; color: var(--grau); }
.zahl { font-variant-numeric: tabular-nums; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; }

/* Kopf und Navigation */
.kopf { position: sticky; top: 0; z-index: 5; background: var(--papier); border-bottom: 1px solid var(--linie); }
.kopf-zeile { max-width: 1100px; margin: 0 auto; padding: 12px 16px 6px; display: flex; align-items: center; gap: 10px; }
.kopf-zeile img { height: 16px; width: auto; display: block; }
.kopf-zeile b { font-size: 13px; letter-spacing: .14em; text-transform: uppercase; }
.kopf-zeile .wer { margin-left: auto; font-size: 12px; color: var(--grau); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 45vw; }
.nav { max-width: 1100px; margin: 0 auto; padding: 0 8px; display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; }
.nav::-webkit-scrollbar { display: none; }
.nav a { flex: none; padding: 10px 10px 11px; text-decoration: none; font-size: 15px; color: var(--text); border-bottom: 3px solid transparent; }
.nav a[aria-current="page"] { color: var(--anth); font-weight: 700; border-bottom-color: var(--sand); }
main { max-width: 1100px; margin: 0 auto; padding: 18px 16px 64px; }

/* Bausteine */
.karte { border: 1px solid var(--linie); border-radius: var(--r); padding: 16px; background: var(--papier); }
.karte > h2:first-child, .karte > h3:first-child { margin-top: 0; }
.kacheln + p, .liste + .karte, .mehr + .karte { margin-top: 14px; }
.kacheln { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.kachel { display: block; border: 1px solid var(--linie); border-radius: var(--r); padding: 14px; text-decoration: none; min-height: 92px; }
.kachel:hover, .kachel:focus-visible { background: var(--hell); }
.kachel b { display: block; font-size: 30px; line-height: 1.1; font-variant-numeric: tabular-nums; }
.kachel span { font-size: 14px; color: var(--text); }
.kachel.achtung { border-color: var(--warn); }
.kachel.achtung b { color: var(--warn); }
.hinweis { border-radius: var(--r); padding: 12px 14px; background: var(--sandhell); border: 1px solid var(--sand); margin: 0 0 14px; }
.hinweis.fehler { background: var(--warnhell); border-color: var(--warn); color: var(--warn); }
.hinweis.gut { background: var(--guthell); border-color: var(--gut); color: var(--gut); }

.knopf { appearance: none; border: 0; border-radius: 999px; background: var(--anth); color: #fff; font: 600 15px/1 var(--schrift); padding: 13px 18px; min-height: 44px; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.knopf.zweit { background: var(--sand); color: var(--anth); }
.knopf.leise { background: transparent; color: var(--anth); border: 1px solid var(--rahmen); }
.knopf.warn { background: var(--warn); }
.knopf:disabled { opacity: .5; cursor: default; }
.knopf.klein { min-height: 36px; padding: 9px 14px; font-size: 14px; }
.knoepfe { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }

/* Filter */
.leiste { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 14px; }
.chips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; max-width: 100%; }
.chips button { flex: none; appearance: none; border: 1px solid var(--rahmen); background: var(--papier); color: var(--anth); border-radius: 999px; padding: 8px 13px; font: 14px/1 var(--schrift); min-height: 38px; cursor: pointer; }
.chips button[aria-pressed="true"] { background: var(--anth); border-color: var(--anth); color: #fff; }
input[type="search"], input[type="text"], input[type="password"], input[type="email"], input[type="date"], input[type="datetime-local"], select, textarea {
  font: 16px/1.3 var(--schrift); color: var(--anth); background: var(--papier); border: 1px solid var(--rahmen); border-radius: var(--r-feld);
  padding: 10px 12px; min-height: 44px; width: 100%; max-width: 100%;
}
textarea { min-height: 96px; resize: vertical; }
input:focus-visible, select:focus-visible, textarea:focus-visible, button:focus-visible, a:focus-visible { outline: 3px solid var(--sand); outline-offset: 2px; }
.suche { flex: 1 1 240px; }
.haken { display: inline-flex; align-items: center; gap: 8px; font-size: 15px; min-height: 44px; cursor: pointer; }
.haken input { width: 20px; height: 20px; accent-color: var(--anth); }
label.feld { display: block; margin: 0 0 12px; font-size: 14px; font-weight: 600; }
label.feld input, label.feld select, label.feld textarea { margin-top: 5px; font-weight: 400; }
label.feld small { display: block; font-weight: 400; color: var(--grau); margin-top: 4px; }
.felder2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 10px; }
@media (max-width: 420px) { .felder2 { grid-template-columns: 1fr; } }

/* Listen */
.liste { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--linie); }
.liste > li { border-bottom: 1px solid var(--linie); }
.zeile { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; padding: 12px 4px; text-decoration: none; width: 100%; text-align: left; background: none; border: 0; font: inherit; color: inherit; cursor: pointer; }
.zeile:hover, .zeile:focus-visible { background: var(--hell); }
.zeile .haupt { font-weight: 600; min-width: 0; overflow-wrap: anywhere; }
.zeile .haupt .klein, .zeile .rechts .klein { font-weight: 400; }
.zeile .rechts { text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.zeile .neben { grid-column: 1 / -1; font-size: 13px; color: var(--grau); display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: center; }
.leer { padding: 24px 4px; color: var(--grau); }
.mehr { margin: 14px 0; }

.marke { display: inline-block; border-radius: 999px; padding: 2px 9px; font-size: 12px; font-weight: 700; line-height: 18px; background: var(--hell); color: var(--text); white-space: nowrap; }
.marke.gut { background: var(--guthell); color: var(--gut); }
.marke.offen { background: var(--sand); color: var(--anth); }
.marke.warn { background: var(--warnhell); color: var(--warn); }
.marke.test { background: var(--papier); color: var(--anth); border: 1.5px dashed var(--anth); line-height: 15px; }
.marke.aus { background: var(--anth); color: #fff; }

/* Detail */
.raster { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; }
dl.daten { margin: 0; display: grid; grid-template-columns: minmax(110px, 38%) 1fr; gap: 6px 12px; font-size: 15px; }
dl.daten dt { color: var(--grau); }
dl.daten dd { margin: 0; overflow-wrap: anywhere; }
table.tab { width: 100%; border-collapse: collapse; font-size: 15px; }
table.tab th, table.tab td { text-align: left; padding: 9px 6px; border-bottom: 1px solid var(--linie); vertical-align: top; }
table.tab th { font-size: 13px; color: var(--grau); font-weight: 600; }
table.tab td.re, table.tab th.re { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
table.tab tfoot td { font-weight: 700; border-bottom: 0; }
.rollen { overflow-x: auto; }
.zurueck { display: inline-block; margin-bottom: 8px; font-size: 15px; text-decoration: none; color: var(--grau); }
.kopieren { appearance: none; border: 1px solid var(--linie); background: var(--papier); border-radius: 8px; font: 12px/1 var(--schrift); padding: 5px 8px; margin-left: 6px; cursor: pointer; }

/* Dialog (Bearbeiten, Anfrage) – auf dem Handy als Blatt von unten */
dialog { border: 1px solid var(--linie); border-radius: 18px; padding: 0; width: min(560px, calc(100vw - 24px)); max-height: calc(100vh - 24px); color: var(--anth); }
dialog::backdrop { background: rgba(29, 29, 29, .45); }
.dlg-kopf { position: sticky; top: 0; background: var(--papier); display: flex; align-items: flex-start; gap: 10px; padding: 16px 16px 10px; border-bottom: 1px solid var(--linie); }
.dlg-kopf h2 { margin: 0; font-size: 18px; flex: 1; overflow-wrap: anywhere; }
.dlg-kopf button { appearance: none; border: 0; background: var(--hell); border-radius: 999px; width: 36px; height: 36px; font-size: 20px; line-height: 1; cursor: pointer; flex: none; }
.dlg-inhalt { padding: 14px 16px 18px; }
@media (max-width: 600px) {
  dialog { width: 100vw; max-width: 100vw; margin: auto 0 0; border-radius: 18px 18px 0 0; max-height: 92vh; }
}
.verlauf { list-style: none; padding: 0; margin: 0; font-size: 13px; }
.verlauf li { padding: 8px 0; border-bottom: 1px solid var(--linie); }

.ladeleiste { height: 3px; background: linear-gradient(90deg, var(--sand) 40%, transparent 40%); background-size: 200% 100%; animation: laden 1s linear infinite; margin: 6px 0 12px; border-radius: 3px; }
@keyframes laden { to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .ladeleiste { animation: none; } }
.abgemeldet { position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 20; }

/* Abmelden im Kopf */
.abmelden { appearance: none; border: 1px solid var(--linie); background: var(--papier); color: var(--anth); border-radius: 999px; font: 13px/1 var(--schrift); padding: 8px 12px; min-height: 34px; cursor: pointer; flex: none; }
.kopf-zeile .wer { margin-left: auto; }
.knopf.breit { width: 100%; }

/* Anmeldeseiten: eine Karte in der Mitte, auf dem Handy volle Breite */
body.anmeldung { min-height: 100vh; display: grid; place-items: start center; padding: 8vh 16px 32px; }
.anmelde-karte { width: 100%; max-width: 400px; margin: 0; padding: 24px 20px; border: 1px solid var(--linie); border-radius: 18px; }
.anmelde-marke { display: flex; align-items: center; gap: 10px; margin: 0 0 22px; }
.anmelde-marke img { height: 22px; width: auto; }
.anmelde-marke b { font-size: 13px; letter-spacing: .14em; text-transform: uppercase; }
.anmelde-karte h1 { font-size: 22px; margin-bottom: 14px; }
.anmelde-karte .haken { margin-bottom: 8px; }
.anmelde-karte .knopf.breit { margin-top: 6px; }
.unten { margin: 18px 0 0; }
@media (max-width: 480px) { body.anmeldung { padding-top: 24px; } .anmelde-karte { border: 0; padding: 8px 0; } }
.link-ergebnis { grid-column: 1 / -1; }
.link-ergebnis:empty { display: none; }
.hinweis input[readonly] { margin: 8px 0; font-size: 14px; }

.karte.abstand { margin: 6px 0 8px; }
.marke.quelle-wix { background: var(--papier); border: 1px solid var(--rahmen); line-height: 16px; }
.marke.quelle-shop { background: var(--anth); color: #fff; }
.leiste .chips + .chips { margin-left: 0; }
button.kachel { appearance: none; background: var(--papier); color: inherit; font: inherit; text-align: left; cursor: pointer; width: 100%; }
.kachel b.kachel-text { font-size: 16px; padding: 6px 0 4px; }
.abstand-unten { margin-bottom: 12px; }
details.hinweis summary { cursor: pointer; }
details.hinweis p { margin: 8px 0 0; }
.kundentitel { font-weight: 700; margin: 14px 0 0; overflow-wrap: anywhere; }
.kundentext { white-space: pre-wrap; overflow-wrap: anywhere; border-left: 3px solid var(--sand); padding: 4px 0 4px 12px; margin: 10px 0; }
.sterne { color: var(--gold, #9b7b45); letter-spacing: 1px; }
