:root {
  --grund: #f4f6f5;
  --flaeche: #ffffff;
  --text: #1b2421;
  --leise: #5f6d68;
  --linie: #dfe5e2;
  --akzent: #0f766e;
  --akzent-text: #ffffff;
  --akzent-hell: #e3f2ef;
  --gut: #15803d;
  --warn-grund: #fff7e0;
  --warn-text: #7a5600;
  --fehler-grund: #fde8e8;
  --fehler-text: #9b1c1c;
  --schatten: 0 1px 2px rgba(16, 24, 22, .06), 0 2px 8px rgba(16, 24, 22, .05);
  --rund: 14px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --grund: #0f1513;
    --flaeche: #18201d;
    --text: #e6ecea;
    --leise: #9aa9a3;
    --linie: #2a3532;
    --akzent: #2bb3a3;
    --akzent-text: #062520;
    --akzent-hell: #16302b;
    --gut: #4ade80;
    --warn-grund: #3a2f12;
    --warn-text: #f5d58a;
    --fehler-grund: #3b1b1b;
    --fehler-text: #fca5a5;
    --schatten: none;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--grund);
  color: var(--text);
  font: 16px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
h1 { font-size: 1.6rem; margin: .2rem 0 .8rem; letter-spacing: -.01em; }
h2 { font-size: 1.1rem; margin: 1.4rem 0 .6rem; }
a { color: var(--akzent); }
.leise { color: var(--leise); }
.klein { font-size: .85rem; }

/* Kopf */
.kopf {
  position: sticky; top: 0; z-index: 5;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: .7rem max(16px, env(safe-area-inset-left));
  background: var(--flaeche); border-bottom: 1px solid var(--linie);
}
.marke { display: flex; align-items: center; gap: .5rem; font-weight: 700; color: var(--text); text-decoration: none; }
.marke svg { width: 26px; height: 26px; padding: 4px; border-radius: 8px; background: var(--akzent);
  fill: none; stroke: var(--akzent-text); stroke-width: 1.8; stroke-linejoin: round; stroke-linecap: round; }
.kopf-rechts { display: flex; align-items: center; gap: .7rem; margin: 0; }
.marke img { width: 30px; height: 30px; border-radius: 8px; object-fit: cover; flex: none; }
.marke span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kopf { justify-content: flex-start; }
.kopf .kopf-rechts { margin-left: auto; }
.menue-knopf { width: 42px; height: 42px; display: grid; place-items: center; margin-left: -.4rem; background: none;
  border: 0; border-radius: 10px; color: var(--text); cursor: pointer; flex: none; }
.menue-knopf:hover { background: var(--akzent-hell); }
.menue-knopf svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }

/* Seitenleiste (je Urlaub) */
.leiste { position: fixed; top: 0; bottom: 0; left: 0; width: 280px; max-width: 85vw; z-index: 30; overflow-y: auto;
  background: var(--flaeche); border-right: 1px solid var(--linie); padding: 1rem .8rem calc(1rem + env(safe-area-inset-bottom));
  transform: translateX(-102%); transition: transform .22s ease; display: flex; flex-direction: column; gap: .8rem; }
.leiste.offen { transform: none; box-shadow: 0 0 40px rgba(0, 0, 0, .35); }
.leiste-schleier { position: fixed; inset: 0; background: rgba(0, 0, 0, .45); z-index: 25; }
.leiste-schleier[hidden] { display: none; }
body.leiste-offen { overflow: hidden; }
.leiste-kopf { display: flex; gap: .7rem; align-items: center; padding: .2rem .3rem .8rem; border-bottom: 1px solid var(--linie); }
.leiste-kopf img { border-radius: 12px; flex: none; }
.leiste-kopf div { display: flex; flex-direction: column; min-width: 0; }
.leiste-kopf strong { font-size: 1.05rem; overflow: hidden; text-overflow: ellipsis; }
.leiste-status { font-size: .8rem; font-weight: 600; color: var(--akzent); margin-top: .1rem; }
.leiste ul { list-style: none; margin: 0; padding: 0; }
.leiste-bereiche a, .leiste-unten a, .leiste-unten .link, .leiste-wechsel summary, .leiste-wechsel a {
  display: flex; align-items: center; gap: .7rem; padding: .62rem .7rem; border-radius: 10px; color: var(--text);
  text-decoration: none; font: inherit; width: 100%; text-align: left; }
.leiste-bereiche a { font-weight: 600; }
.leiste-bereiche a:hover, .leiste-unten a:hover, .leiste-unten .link:hover, .leiste-wechsel summary:hover, .leiste-wechsel a:hover { background: var(--akzent-hell); }
.leiste-bereiche a.aktiv { background: var(--akzent); color: var(--akzent-text); }
.leiste-symbol { width: 1.6rem; text-align: center; font-size: 1.15rem; }
.leiste-wechsel { border-top: 1px solid var(--linie); padding-top: .5rem; }
.leiste-wechsel summary { cursor: pointer; list-style: none; font-weight: 600; }
.leiste-wechsel summary::-webkit-details-marker { display: none; }
.leiste-wechsel summary::after { content: "›"; margin-left: auto; transition: transform .15s; color: var(--leise); }
.leiste-wechsel[open] summary::after { transform: rotate(90deg); }
.leiste-wechsel a { justify-content: space-between; padding-left: 2.9rem; }
.leiste-unten { margin-top: auto !important; border-top: 1px solid var(--linie); padding-top: .5rem !important; }
.leiste-unten form { margin: 0; }
.leiste-unten a, .leiste-unten .link { color: var(--leise); font-size: .95rem; }
.seitentitel { margin: .2rem 0 1rem; }
.seitentitel p { margin: 0; }
.seitentitel h1 { margin: 0; }
@media (min-width: 1100px) {
  body.mit-leiste { padding-left: 280px; }
  body.mit-leiste .leiste { transform: none; box-shadow: none; }
  body.mit-leiste .menue-knopf, body.mit-leiste .leiste-schleier { display: none; }
  body.leiste-offen { overflow: auto; }
}
@media (prefers-reduced-motion: reduce) { .leiste { transition: none; } }
.ich { color: var(--leise); font-size: .9rem; text-decoration: none; }
.ich:hover { color: var(--akzent); }

.inhalt { max-width: 760px; margin: 0 auto; padding: 1rem 16px 4rem; }

/* Karten & Listen */
.karte {
  background: var(--flaeche); border: 1px solid var(--linie); border-radius: var(--rund);
  padding: 1rem; margin: 1rem 0; box-shadow: var(--schatten);
}
.karte > h2:first-child, .karte > h1:first-child { margin-top: 0; }
.schmal { max-width: 380px; margin: 3rem auto; }
.liste { list-style: none; margin: 0; padding: 0; background: var(--flaeche);
  border: 1px solid var(--linie); border-radius: var(--rund); overflow: hidden; box-shadow: var(--schatten); }
.liste > li + li { border-top: 1px solid var(--linie); }
.liste.kompakt { box-shadow: none; margin-bottom: 1rem; }
.zeile { display: flex; align-items: center; gap: .8rem; padding: .75rem 1rem; color: inherit; text-decoration: none; }
a.zeile:hover { background: var(--akzent-hell); }
.zeile-haupt { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.zeile-titel { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.zeile-betrag { font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.mini-bon { width: 40px; height: 40px; border-radius: 8px; object-fit: cover; flex: none; background: var(--akzent-hell); }
.leer-bon { display: grid; place-items: center; color: var(--akzent); font-weight: 700; }
.tag { font-size: .9rem; color: var(--leise); font-weight: 600; margin: 1.3rem 0 .5rem; }
.leer { color: var(--leise); text-align: center; padding: 1.5rem 0; }
.zurueck { display: inline-block; margin-top: .3rem; text-decoration: none; font-size: .95rem; }

/* Saldo & Kacheln */
.klein-titel { font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; color: var(--leise); margin: 0 0 .4rem; }
.saldo { border-color: var(--akzent); }
.saldo-zeile { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem 1rem; }
.saldo-zeile + .saldo-zeile { border-top: 1px solid var(--linie); margin-top: .7rem; padding-top: .7rem; }
.saldo-text { margin: 0; font-size: 1.05rem; flex: 1 1 auto; }
.saldo-betrag { margin: 0; font-size: 1.5rem; font-weight: 700; color: var(--akzent); font-variant-numeric: tabular-nums; }
.saldo-zeile form { flex-basis: 100%; margin: 0; }
.ausgeglichen { color: var(--gut); font-weight: 600; }
.kacheln { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .7rem; margin: 1rem 0; }
.kachel { background: var(--flaeche); border: 1px solid var(--linie); border-radius: var(--rund);
  padding: .8rem 1rem; display: flex; flex-direction: column; box-shadow: var(--schatten); }
.kachel strong { font-size: 1.25rem; font-variant-numeric: tabular-nums; }

/* Aktionen & Filter */
.aktionen { display: flex; flex-wrap: wrap; gap: .6rem; margin: 1.2rem 0 .4rem; align-items: stretch; }
.aktionen form { margin: 0; flex: 1 1 220px; display: flex; }
.aktionen > .knopf { flex: 1 0 auto; }
@media (min-width: 560px) { .aktionen > .knopf { flex: 0 1 auto; } }
.filter { display: flex; gap: .4rem; flex-wrap: wrap; margin: 1.2rem 0 0; }
.chip { padding: .3rem .8rem; border-radius: 999px; border: 1px solid var(--linie); background: var(--flaeche);
  color: var(--text); text-decoration: none; font-size: .9rem; }
.chip.aktiv { background: var(--akzent); border-color: var(--akzent); color: var(--akzent-text); }

/* Knöpfe */
.knopf {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 44px; padding: .6rem 1.1rem; border-radius: 12px; border: 1px solid var(--akzent);
  background: var(--akzent); color: var(--akzent-text); font: inherit; font-weight: 600;
  text-decoration: none; cursor: pointer;
}
.knopf:hover { filter: brightness(1.06); }
.knopf.zweit { background: var(--flaeche); color: var(--akzent); }
.knopf.klein { min-height: 36px; padding: .35rem .8rem; font-size: .9rem; }
.knopf.gross { flex: 1; min-height: 56px; font-size: 1.05rem; }
label.knopf { flex-direction: row; color: var(--akzent-text); font-weight: 600; }
.knopf.gross svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linejoin: round; }
.knopf.voll { width: 100%; }
.link { background: none; border: 0; padding: .3rem; font: inherit; color: var(--akzent); cursor: pointer; }
.gefahr { color: var(--fehler-text); }

/* Formulare */
.formular { display: flex; flex-direction: column; gap: .8rem; }
.formular.karte { margin-top: 0; }
label { display: flex; flex-direction: column; gap: .25rem; font-size: .9rem; color: var(--leise); font-weight: 500; }
input, select {
  font: inherit; color: var(--text); background: var(--grund);
  border: 1px solid var(--linie); border-radius: 10px; padding: .6rem .7rem; min-height: 44px; width: 100%;
}
input:focus, select:focus { outline: 2px solid var(--akzent); outline-offset: 1px; border-color: transparent; }
.feldreihe { display: grid; grid-template-columns: 1fr 1fr; gap: .7rem; }
.wahl { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: .4rem; }
.wahl legend { font-size: .9rem; color: var(--leise); font-weight: 500; margin-bottom: .3rem; padding: 0; }
.wahl label { flex-direction: row; }
.wahl input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.wahl span { padding: .45rem .9rem; border: 1px solid var(--linie); border-radius: 999px; color: var(--text); cursor: pointer; background: var(--grund); }
.wahl input:checked + span { background: var(--akzent); border-color: var(--akzent); color: var(--akzent-text); }
.wahl input:focus-visible + span { outline: 2px solid var(--akzent); outline-offset: 2px; }

/* Positionen */
.pos-kopf h2 { margin: .6rem 0 0; }
.pos { display: grid; grid-template-columns: 1fr 6.5rem 8.5rem 2.2rem; gap: .4rem; margin-bottom: .4rem; }
.pos input, .pos select { min-height: 40px; padding: .45rem .55rem; font-size: .95rem; }
.pos-betrag { text-align: right; font-variant-numeric: tabular-nums; }
.pos-weg { border: 0; background: none; color: var(--leise); font-size: 1.4rem; cursor: pointer; }
.pos-fuss { display: flex; align-items: center; justify-content: space-between; gap: .6rem; flex-wrap: wrap; }
.abweichung { color: var(--warn-text); font-weight: 600; }
.anteile { margin: 0; }
.loeschen { text-align: center; margin-top: .5rem; }

/* Kauf-Seite mit Bon */
.kauf-raster { display: grid; gap: 1rem; }
.bon-bild { display: flex; flex-direction: column; align-items: center; gap: .3rem; text-decoration: none; }
.bon-bild img { width: 100%; max-height: 340px; object-fit: contain; border-radius: var(--rund);
  background: var(--flaeche); border: 1px solid var(--linie); }
@media (min-width: 720px) {
  .inhalt { max-width: 980px; }
  .kauf-raster:has(.bon-bild) { grid-template-columns: 300px 1fr; align-items: start; }
  .bon-bild { position: sticky; top: 80px; }
  .bon-bild img { max-height: 75vh; }
}

/* Rechenweg unter dem Stand */
.rechenweg { margin-top: .9rem; border-top: 1px solid var(--linie); padding-top: .6rem; }
.rechenweg summary { cursor: pointer; color: var(--akzent); font-weight: 600; font-size: .95rem; }
.rechenweg table { width: 100%; border-collapse: collapse; margin: .7rem 0 .4rem; font-size: .9rem; }
.rechenweg th, .rechenweg td { padding: .45rem .3rem; text-align: left; vertical-align: top; border-bottom: 1px solid var(--linie); }
.rechenweg th { font-size: .8rem; color: var(--leise); font-weight: 600; }
.rechenweg td a { color: var(--text); font-weight: 600; }
.rechenweg td .klein { display: block; }
.rechenweg .zahl { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.rechenweg .plus { color: var(--gut); }
.rechenweg .minus { color: var(--fehler-text); }
.rechenweg tr.zahlung td:first-child { font-style: italic; }
.rechenweg tfoot th, .rechenweg tfoot td { border-bottom: 0; border-top: 2px solid var(--linie); font-weight: 700; font-size: .95rem; color: inherit; }
.rechenweg tfoot .plus { color: var(--gut); }
.rechenweg tfoot .minus { color: var(--fehler-text); }

/* Budget */
.budget-kopf { display: flex; justify-content: space-between; align-items: baseline; gap: .5rem; flex-wrap: wrap; }
.balken { display: block; height: 10px; border-radius: 999px; background: var(--akzent-hell); overflow: hidden; margin: .5rem 0; }
.balken > span { display: block; height: 100%; border-radius: inherit; background: var(--akzent); }
.balken.klein { height: 6px; margin: .25rem 0 0; }
.budget.ueber .balken > span { background: var(--fehler-text); }
.budget-text { margin: 0; }
.budget.ueber .budget-text strong { color: var(--fehler-text); }

/* Kategorien */
.kategorien { list-style: none; margin: 0; padding: 0; display: grid; gap: .15rem; }
.kat-zeile { display: grid; grid-template-columns: 1fr auto; gap: 0 .8rem; padding: .45rem .5rem; border-radius: 10px;
  color: inherit; text-decoration: none; }
.kat-zeile:hover, .kat-zeile.aktiv { background: var(--akzent-hell); }
.kat-zeile .balken { grid-column: 1 / -1; }
.kat-betrag { font-weight: 600; font-variant-numeric: tabular-nums; }

/* Liste: Kategorie-Symbol und Fremdwährung */
.mini-bon-rahmen { position: relative; flex: none; }
.mini-kat { position: absolute; right: -6px; bottom: -6px; font-size: .8rem; line-height: 1; background: var(--flaeche);
  border-radius: 50%; padding: 2px; }
.leer-bon { font-size: 1.2rem; }
.zeile-betrag { display: flex; flex-direction: column; align-items: flex-end; }
.zeile-betrag .fremd { font-weight: 400; }

/* Umrechnung im Formular */
.umrechnung { background: var(--akzent-hell); border-radius: 12px; padding: .8rem; display: grid; gap: .5rem; }
.umrechnung[hidden] { display: none; }
.umrechnung p { margin: 0; }
.kurs-status { color: var(--warn-text); }
@media (max-width: 480px) {
  .nur-breit { display: none; }
  .kopf-rechts { gap: .5rem; }
}

/* Reiter je Urlaub */
.reiter { display: flex; gap: .3rem; margin: .2rem 0 1rem; border-bottom: 1px solid var(--linie); overflow-x: auto;
  scrollbar-width: none; }
.reiter::-webkit-scrollbar { display: none; }
@media (max-width: 480px) { .reiter { gap: 0; } .reiter a { padding: .55rem .6rem; } }
.reiter a { padding: .55rem .9rem; color: var(--leise); text-decoration: none; font-weight: 600; white-space: nowrap;
  border-bottom: 3px solid transparent; margin-bottom: -1px; }
.reiter a:hover { color: var(--text); }
.reiter a.aktiv { color: var(--akzent); border-bottom-color: var(--akzent); }
.seitenkopf h1 { margin-bottom: .2rem; }
.seitenkopf p { margin: 0 0 .4rem; }

/* Plan */
.plan-liste > li { padding: 0; }
.plan-eintrag.vorbei { opacity: .55; }
.plan-link { display: flex; align-items: flex-start; gap: .7rem; padding: .75rem 1rem; color: inherit; text-decoration: none; }
.plan-link:hover { background: var(--akzent-hell); }
.plan-zeit { width: 2.8rem; flex: none; font-variant-numeric: tabular-nums; font-weight: 600; padding-top: .1rem; }
.plan-symbol { font-size: 1.25rem; line-height: 1.3; flex: none; }
.plan-symbol.gross { font-size: 1.8rem; }
.plan-extras { display: flex; flex-wrap: wrap; gap: .4rem; padding: 0 1rem .75rem 4.3rem; }
.plan-extras .chip { font-size: .85rem; cursor: pointer; font: inherit; font-size: .85rem; }
.warnhinweis { color: var(--warn-text); }
.als-naechstes { border-color: var(--akzent); display: grid; gap: .5rem; }
.als-naechstes .klein-titel { margin: 0; }
.naechstes-link { display: flex; gap: .8rem; align-items: center; color: inherit; text-decoration: none; }
.als-naechstes .knopf { justify-self: start; }

/* Buchung */
.dok-leiste { display: flex; flex-wrap: wrap; gap: .5rem; margin: .5rem 0 1rem; }
.dok { display: flex; align-items: center; gap: .2rem; }
.dok form { margin: 0; }
.dok-dazu { margin-top: .7rem; }

/* Tickets */
.tickets { list-style: none; margin: 0; padding: 0; display: grid; gap: .8rem; }
.ticket { background: var(--flaeche); border: 1px solid var(--linie); border-radius: var(--rund); padding: 1rem;
  box-shadow: var(--schatten); display: grid; gap: .6rem; }
.ticket p { margin: 0; }
.ticket-kopf { display: flex; gap: .8rem; align-items: center; }
.buchungsnummer { font: 700 1.4rem/1.2 ui-monospace, Consolas, monospace; letter-spacing: .06em; text-align: left;
  background: var(--grund); color: var(--text); border: 1px dashed var(--linie); border-radius: 10px; padding: .5rem .8rem; cursor: pointer; }
.ticket-knoepfe { display: flex; flex-wrap: wrap; gap: .5rem; }
.ticket-knoepfe .knopf { flex: 1 1 auto; min-height: 52px; font-size: 1.05rem; }
.offline-karte { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .8rem; }
.offline-karte p { margin: 0; flex-basis: 100%; }

/* Packliste */
.pack-neu { display: grid; grid-template-columns: 1fr auto auto auto; gap: .4rem; margin: 1rem 0 .3rem; }
.pack-neu .knopf { min-width: 48px; font-size: 1.3rem; padding: .4rem .8rem; }
.pack-neu select { width: auto; max-width: 10rem; }
.pack-eintrag { display: flex; align-items: center; gap: .3rem; padding-right: .8rem; }
.pack-haken { margin: 0; }
.haken { width: 52px; height: 48px; display: grid; place-items: center; background: none; border: 0; cursor: pointer; padding: 0; }
.haken svg { width: 26px; height: 26px; border: 2px solid var(--linie); border-radius: 8px; padding: 2px;
  fill: none; stroke: transparent; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; transition: background .15s; }
.ist-gepackt .haken svg { background: var(--akzent); border-color: var(--akzent); stroke: var(--akzent-text); }
.pack-text { flex: 1; padding: .7rem 0; color: inherit; text-decoration: none; min-width: 0; }
.ist-gepackt .pack-text { color: var(--leise); text-decoration: line-through; }
.kuerzel { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-size: .75rem; font-weight: 700;
  background: var(--akzent-hell); color: var(--akzent); flex: none; }
.kuerzel[data-person="2"] { background: #f6e3d3; color: #9a4f16; }
.vorlagen { list-style: none; margin: 0 0 .5rem; padding: 0; display: flex; flex-wrap: wrap; gap: .4rem; }
.vorlagen form { margin: 0; }
.ideen > li { padding: 0; }
.idee { flex-direction: row; align-items: flex-start; gap: .8rem; padding: .75rem 1rem; color: var(--text); cursor: pointer; font-weight: 400; }
.idee input { width: 22px; height: 22px; min-height: 0; margin-top: .1rem; accent-color: var(--akzent); flex: none; }
h3.klein-titel { margin-top: 1.2rem; }
@media (max-width: 480px) {
  .pack-neu { grid-template-columns: 1fr 1fr auto; }
  .pack-neu-text { grid-column: 1 / -1; }
  .pack-neu select { max-width: none; }
}
@media (prefers-color-scheme: dark) { .kuerzel[data-person="2"] { background: #3a2a1c; color: #f0b27a; } }

/* Orte */
.karte-box { height: 320px; border-radius: var(--rund); border: 1px solid var(--linie); overflow: hidden; margin: 0 0 .3rem;
  background: var(--akzent-hell); z-index: 0; }
.karte-box[hidden] { display: none; }
.karte-hinweis { margin: 0 0 .5rem; min-height: 1em; }
.kartenpunkt { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; font-size: 18px;
  background: #fff; border: 2px solid var(--akzent); box-shadow: 0 1px 4px rgba(0, 0, 0, .35); }
.kartenpunkt.blass { opacity: .5; }
.kartenpunkt.plan { border-color: #c4a32b; border-style: dashed; }
.leaflet-popup-content a { color: #0f766e; font-weight: 600; }
.aktionen.eng { margin: .3rem 0; }
.ort { padding: 0; }
.ort-haupt { display: flex; gap: .7rem; align-items: flex-start; padding: .75rem 1rem .4rem; color: inherit; text-decoration: none; }
.ort-haupt:hover { background: var(--akzent-hell); }
.ort-knoepfe { display: flex; flex-wrap: wrap; gap: .4rem; padding: 0 1rem .75rem 3.2rem; }
.ort-knoepfe form { margin: 0; }
.ort-knoepfe .chip, .filter button.chip { font: inherit; font-size: .85rem; cursor: pointer; }
.ist-besucht .ort-haupt { opacity: .6; }
.besucht-knopf[aria-pressed="true"] { background: var(--akzent); color: var(--akzent-text); border-color: var(--akzent); }
.filter button.chip.aktiv { background: var(--akzent); color: var(--akzent-text); }
.sterne { color: #e0a526; letter-spacing: .05em; }
.entfernung:empty { display: none; }
.haken-zeile { flex-direction: row; align-items: center; gap: .6rem; color: var(--text); }
.haken-zeile input { width: 22px; height: 22px; min-height: 0; accent-color: var(--akzent); }
.sterne-wahl span { color: #e0a526; }
textarea { font: inherit; color: var(--text); background: var(--grund); border: 1px solid var(--linie); border-radius: 10px;
  padding: .6rem .7rem; width: 100%; resize: vertical; }

/* Tagebuch */
.tb-kopf { display: flex; justify-content: space-between; align-items: center; gap: .5rem; }
.tb-kopf h2 { margin: 0; font-size: 1.05rem; }
.tb-tag { scroll-margin-top: 70px; }
.tagesbild { display: flex; flex-wrap: wrap; gap: .3rem; margin: .6rem 0; }
.chip.still { font-size: .8rem; background: var(--grund); }
.tb-eintrag + .tb-eintrag { border-top: 1px dashed var(--linie); margin-top: .8rem; padding-top: .8rem; }
.tb-text { white-space: pre-line; line-height: 1.55; margin-top: .4rem; }
.tb-fuss { margin: .4rem 0 0; }
.tb-fotos { display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: .4rem; margin: .6rem 0; }
.tb-fotos:empty { display: none; }
.tb-foto { display: flex; flex-direction: column; gap: .2rem; text-decoration: none; color: var(--leise); font-size: .75rem; }
.tb-foto img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 10px; background: var(--grund); display: block; }
.tb-fotos.bearbeiten { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); }
.tb-fotos.bearbeiten input { min-height: 34px; padding: .3rem .45rem; font-size: .85rem; }
.ki-kasten { background: var(--akzent-hell); border-radius: 12px; padding: .8rem; display: grid; gap: .5rem; justify-items: start; }
.ki-kasten label { width: 100%; }
.foto-waehlen { justify-self: start; align-self: flex-start; }

/* Auswertung */
.saeulen { display: flex; align-items: flex-end; gap: 2px; height: 180px; padding: 0 0 1.4rem; margin: .5rem 0 .3rem;
  border-bottom: 1px solid var(--linie); }
.saeule { flex: 1 1 0; min-width: 4px; height: 100%; display: flex; flex-direction: column; justify-content: flex-end;
  position: relative; outline: none; cursor: default; }
.saeule-balken { display: block; background: var(--akzent); border-radius: 4px 4px 0 0; min-height: 0; }
.saeule:hover .saeule-balken, .saeule:focus-visible .saeule-balken { filter: brightness(1.15); }
.saeule-tag { position: absolute; bottom: -1.3rem; left: 50%; transform: translateX(-50%); font-size: .65rem;
  color: var(--leise); white-space: nowrap; }
[data-tip] { position: relative; }
[data-tip]:hover::after, [data-tip]:focus-visible::after {
  content: attr(data-tip); position: absolute; bottom: calc(100% + 6px); left: 50%; transform: translateX(-50%); z-index: 5;
  background: var(--text); color: var(--grund); font-size: .75rem; font-weight: 600; padding: .3rem .5rem; border-radius: 6px;
  white-space: nowrap; pointer-events: none; }
.saeule[data-tip]:hover::after, .saeule[data-tip]:focus-visible::after { bottom: auto; top: -6px; transform: translate(-50%, -100%); }
.kat-balken { list-style: none; margin: 0; padding: 0; display: grid; gap: .55rem; }
.kat-balken li { display: grid; grid-template-columns: 1fr auto; gap: .2rem .8rem; outline: none; }
.kat-balken li:focus-visible { box-shadow: 0 0 0 2px var(--akzent); border-radius: 6px; }
.kat-balken .balken { grid-column: 1 / -1; margin: 0; height: 12px; }
.kat-balken .balken > span { border-radius: 0 4px 4px 0; }
.kat-balken li[data-tip]:hover::after, .kat-balken li[data-tip]:focus-visible::after { left: 30%; }
.zahlen-tabelle { width: 100%; border-collapse: collapse; font-size: .9rem; }
.zahlen-tabelle th, .zahlen-tabelle td { padding: .4rem .3rem; border-bottom: 1px solid var(--linie); text-align: left; }
.zahlen-tabelle th { font-size: .8rem; color: var(--leise); font-weight: 600; }
.zahlen-tabelle .zahl { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tabelle-ansicht summary { cursor: pointer; color: var(--akzent); font-size: .9rem; }
.plus-text { color: var(--gut); font-weight: 600; }
.minus-text { color: var(--fehler-text); font-weight: 600; }
.top-liste { padding: 0; }
.klein-kacheln .kachel strong { font-size: 1.1rem; }

/* Nutzer, Teilnehmer, Guthaben */
.zaehler { display: inline-grid; place-items: center; min-width: 1.3rem; height: 1.3rem; padding: 0 .3rem; border-radius: 999px;
  background: var(--fehler-text); color: #fff; font-size: .72rem; font-weight: 700; margin-left: auto; }
.wahl input[type="checkbox"] { position: absolute; opacity: 0; width: 1px; height: 1px; }
.wahl input[type="checkbox"]:checked + span { background: var(--akzent); border-color: var(--akzent); color: var(--akzent-text); }
.wahl input[type="checkbox"]:checked + span::before { content: "✓ "; }
.nutzer-zeile { display: flex; flex-wrap: wrap; align-items: flex-start; gap: .4rem 1rem; padding: .75rem 1rem; }
.nutzer-zeile.gesperrt { opacity: .55; }
.nutzer-aktionen { margin-left: auto; }
.nutzer-aktionen summary { cursor: pointer; color: var(--akzent); font-size: .9rem; }
.nutzer-aktionen[open] { flex-basis: 100%; }
.feldreihe-kompakt { display: flex; gap: .4rem; margin: .5rem 0; }
.nutzer-knoepfe { display: flex; gap: 1rem; flex-wrap: wrap; }
.nutzer-knoepfe form { margin: 0; }
.aufladen { display: flex; gap: .5rem; flex-wrap: wrap; margin: .6rem 0; }
.aufladen form { margin: 0; }
.aufladen .knopf { min-width: 72px; font-size: 1.05rem; }
.einzahlung { gap: .5rem; flex-wrap: wrap; }
.einzahlung form { margin: 0; }
.status-offen { color: var(--warn-text); font-size: .85rem; }
.status-bestaetigt { color: var(--gut); font-size: .85rem; }
.status-abgelehnt { color: var(--fehler-text); font-size: .85rem; }

/* Einstellungen */
.status-zeile { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; margin: 0 0 1rem; }
.punkt { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.punkt.gut { background: var(--gut); }
.punkt.aus { background: var(--leise); }
code { font-family: ui-monospace, Consolas, monospace; font-size: .9em; background: var(--grund); padding: .1rem .35rem; border-radius: 6px; }
.modellwahl { border: 0; padding: 0; margin: 0; display: grid; gap: .5rem; }
.modell { flex-direction: row; align-items: flex-start; gap: .7rem; padding: .7rem .8rem; border: 1px solid var(--linie);
  border-radius: 12px; color: var(--text); cursor: pointer; }
.modell:has(input:checked) { border-color: var(--akzent); background: var(--akzent-hell); }
.modell input { width: auto; min-height: 0; margin-top: .25rem; accent-color: var(--akzent); }
.modell > span { display: flex; flex-direction: column; }
.zweck { border: 1px solid var(--linie); border-radius: 12px; padding: .8rem; margin: 0; display: grid; gap: .45rem; }
.zweck legend { font-weight: 700; padding: 0 .3rem; display: flex; flex-direction: column; gap: .1rem; }
.zweck legend .klein { font-weight: 400; }
.zweck .modell { display: grid; grid-template-columns: auto 1fr auto; padding: .55rem .7rem; }
.zweck .modell > span:not(.kosten) { min-width: 0; }
.modell.empfohlen { border-style: dashed; border-color: #e0a526; }
.modell.empfohlen:has(input:checked) { border-style: solid; border-color: var(--akzent); }
.stern { font-size: .75rem; font-weight: 700; color: #b9850f; white-space: nowrap; }
.kosten { font-size: .8rem; font-variant-numeric: tabular-nums; color: var(--leise); white-space: nowrap; align-self: center; }
.empfehlung-form { margin: .2rem 0 .8rem; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* Meldungen */
.meldung { padding: .7rem 1rem; border-radius: 12px; margin: .6rem 0; font-size: .95rem; }
.meldung.ok { background: var(--akzent-hell); color: var(--text); }
.meldung.info { background: var(--akzent-hell); color: var(--text); }
.meldung.warnung { background: var(--warn-grund); color: var(--warn-text); }
.meldung.fehler { background: var(--fehler-grund); color: var(--fehler-text); }
.hinweis { font-size: .85rem; color: var(--warn-text); background: var(--warn-grund); padding: .5rem .8rem; border-radius: 10px; }

/* Aufklappen */
.aufklapp summary { cursor: pointer; font-weight: 600; color: var(--akzent); }
.aufklapp[open] summary { margin-bottom: 1rem; }

/* Ladeanzeige */
.lade-schicht { position: fixed; inset: 0; background: rgba(0, 0, 0, .45); display: grid; place-items: center; z-index: 20; }
.lade-schicht[hidden] { display: none; }
.lade-box { background: var(--flaeche); border-radius: var(--rund); padding: 1.5rem 2rem; text-align: center; }
.lade-box p { margin: .3rem 0; }
.kreisel { display: inline-block; width: 36px; height: 36px; border-radius: 50%;
  border: 4px solid var(--akzent-hell); border-top-color: var(--akzent); animation: drehen .8s linear infinite; }
@keyframes drehen { to { transform: rotate(360deg); } }

@media (max-width: 480px) {
  .pos { grid-template-columns: 1fr 5.5rem 2rem; }
  .pos-fuer { grid-column: 1 / 3; grid-row: 2; }
  .pos-weg { grid-row: 1; grid-column: 3; }
  .pos { padding-bottom: .5rem; border-bottom: 1px dashed var(--linie); }
}

/* Kategoriefarben – geprüfte Palette (Farbschwäche, Kontrast), hell und dunkel */
.kf-essen { --kf: #2a78d6; }
.kf-lebensmittel { --kf: #eb6834; }
.kf-unterkunft { --kf: #1baf7a; }
.kf-anreise { --kf: #eda100; }
.kf-tanken { --kf: #e87ba4; }
.kf-ausfluege { --kf: #008300; }
.kf-shopping { --kf: #6250d6; }
.kf-sonstiges { --kf: #e34948; }
@media (prefers-color-scheme: dark) {
  .kf-essen { --kf: #3987e5; }
  .kf-lebensmittel { --kf: #d95926; }
  .kf-unterkunft { --kf: #199e70; }
  .kf-anreise { --kf: #c98500; }
  .kf-tanken { --kf: #d55181; }
  .kf-ausfluege { --kf: #008300; }
  .kf-shopping { --kf: #9085e9; }
  .kf-sonstiges { --kf: #e66767; }
}
