/* Layout: eine schmale, mobile Spalte mit Tab-Leiste unten; Grün für Energie, Orange für Protein */
:root {
  --bg: #f3f6f1;
  --surface: #ffffff;
  --surface-2: #e9efe7;
  --ink: #16211a;
  --muted: #5d6b61;
  --line: #dbe3d8;
  --primary: #2e6a45;
  --primary-ink: #ffffff;
  --primary-soft: #dcebdf;
  --accent: #d2632a;
  --accent-soft: #f8e3d5;
  --danger: #b3261e;
  --danger-soft: #fbe3e0;
  --warn: #a86a00;
  --warn-soft: #fbefd5;
  --water: #2b7bb9;
  --water-soft: #dcebf7;
  --shadow: 0 1px 2px rgb(22 33 26 / 6%), 0 4px 16px rgb(22 33 26 / 5%);
  --radius: 18px;
  --font: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --tabs-h: 64px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0e1410; --surface: #162019; --surface-2: #1d2a21; --ink: #e5ece6; --muted: #98a69c;
    --line: #283429; --primary: #6cc08a; --primary-ink: #0e1410; --primary-soft: #1d3826;
    --accent: #f0955b; --accent-soft: #3b2619; --danger: #ff8a80; --danger-soft: #3d1f1c; --warn: #f2b84b; --warn-soft: #3a2e14; --water: #7cc0f0; --water-soft: #16303f;
    --shadow: 0 1px 2px rgb(0 0 0 / 30%); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0e1410; --surface: #162019; --surface-2: #1d2a21; --ink: #e5ece6; --muted: #98a69c;
  --line: #283429; --primary: #6cc08a; --primary-ink: #0e1410; --primary-soft: #1d3826;
  --accent: #f0955b; --accent-soft: #3b2619; --danger: #ff8a80; --danger-soft: #3d1f1c; --warn: #f2b84b; --warn-soft: #3a2e14; --water: #7cc0f0; --water-soft: #16303f;
  --shadow: 0 1px 2px rgb(0 0 0 / 30%); color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 15px/1.5 var(--font); font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased;
}
body.no-scroll { overflow: hidden; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; text-align: inherit; }
:focus-visible { outline: 2.5px solid var(--primary); outline-offset: 2px; border-radius: 10px; }
h1, h2, h3 { margin: 0; text-wrap: balance; line-height: 1.2; }
p { margin: 0; }
[hidden] { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

.wrap {
  max-width: 640px; margin: 0 auto;
  padding-top: calc(env(safe-area-inset-top, 0px) + 20px);
  padding-bottom: calc(var(--tabs-h) + env(safe-area-inset-bottom, 0px) + 28px);
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
  display: flex; flex-direction: column; gap: 14px;
}

/* Icons */
.ic { width: 22px; height: 22px; flex: none; }
.ic-sm { width: 15px; height: 15px; flex: none; vertical-align: -2px; }
.ic-tick { width: 16px; height: 16px; stroke-width: 3; }

/* Kopf */
.page-head { display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 2px 12px; padding: 4px 2px 6px; }
.page-head .eyebrow { grid-column: 1 / -1; }
.eyebrow { font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
h1 { font-size: 32px; font-weight: 800; letter-spacing: -.02em; }
h2 { font-size: 17px; font-weight: 700; }
h3 { font-size: 13px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); margin: 18px 0 8px; }
.muted { color: var(--muted); font-size: 13.5px; }
.hint { color: var(--muted); font-size: 13px; }

/* Karten */
.card { background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.note { background: var(--primary-soft); box-shadow: none; font-size: 14px; }
.note-inline { background: var(--surface-2); border-radius: 12px; padding: 10px 12px; font-size: 13.5px; margin-top: 12px; }

/* Chips */
.chips { display: flex; gap: 8px; overflow-x: auto; padding: 2px; scrollbar-width: none; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; white-space: nowrap;
  padding: 7px 13px; border-radius: 999px; font-size: 13.5px; font-weight: 600;
  background: var(--surface); color: var(--muted); box-shadow: inset 0 0 0 1px var(--line);
}
.chip-on { background: var(--primary); color: var(--primary-ink); box-shadow: none; }

/* Tagesbilanz */
.summary { gap: 8px; }
.sum-row { display: flex; justify-content: space-between; gap: 12px; }
.sum-right { text-align: right; }
.sum-label { font-size: 12.5px; font-weight: 600; color: var(--muted); }
.sum-value { font-size: 14px; color: var(--muted); }
.sum-value b { font-size: 26px; font-weight: 800; color: var(--ink); letter-spacing: -.02em; }
.sum-foot { font-size: 13px; color: var(--muted); margin-top: 2px; }
.bar { height: 8px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.bar span { display: block; height: 100%; border-radius: inherit; transition: width .35s ease; }
.bar-kcal span { background: var(--primary); }
.bar-protein span { background: var(--accent); }

/* Mahlzeiten */
.meals { display: flex; flex-direction: column; gap: 10px; }
.meal {
  background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow);
  display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 4px 12px; padding: 12px 14px 12px 12px;
}
.tick {
  width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center;
  box-shadow: inset 0 0 0 2px var(--line); color: transparent; transition: background .2s, color .2s;
}
.tick:hover { box-shadow: inset 0 0 0 2px var(--primary); }
.is-done .tick { background: var(--primary); color: var(--primary-ink); box-shadow: none; }
.meal-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; padding: 2px 0; }
.meal-slot { font-size: 11.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--primary); }
.meal-slot em { font-style: normal; font-weight: 600; color: var(--muted); letter-spacing: .02em; text-transform: none; }
.meal-name { font-size: 16px; font-weight: 700; }
.is-done .meal-name { color: var(--muted); text-decoration: line-through; text-decoration-thickness: 1.5px; }
.meta { font-size: 13px; color: var(--muted); display: inline-flex; flex-wrap: wrap; align-items: center; gap: 0 4px; }
.meta b { color: var(--ink); font-weight: 700; }
.chev { color: var(--muted); width: 18px; height: 18px; }
.meal-extra { grid-column: 2 / -1; }
.link-btn { display: inline-flex; align-items: center; gap: 6px; font-size: 13.5px; font-weight: 600; color: var(--primary); padding: 4px 0; }
.link-btn.danger { color: var(--danger); }

/* Woche */
.daypicker { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.day {
  display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 10px 0 8px;
  border-radius: 14px; background: var(--surface); box-shadow: var(--shadow); font-weight: 700; font-size: 14px;
}
.day.is-today span { color: var(--accent); }
.day.is-active { background: var(--primary); color: var(--primary-ink); }
.day.is-active.is-today span { color: inherit; }
.dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .75; }
.dot-off { opacity: .18; }
.day-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.day-list { list-style: none; margin: 4px 0 0; padding: 0; }
.day-list li { display: grid; grid-template-columns: 96px 1fr auto; gap: 10px; align-items: baseline; padding: 9px 0; border-top: 1px solid var(--line); }
.dl-slot { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.dl-name { font-weight: 600; min-width: 0; }
.dl-name:hover { color: var(--primary); }
.dl-num { font-size: 13px; color: var(--muted); }
.field { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; color: var(--muted); margin-top: 6px; }
select, input[type="number"] {
  width: 100%; min-width: 0; padding: 11px 12px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--surface-2); color: var(--ink); font-size: 15px; font-weight: 500;
}
.week-bars { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; align-items: end; margin-top: 6px; }
.wb { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.wb-col { width: 100%; height: 84px; display: flex; align-items: flex-end; background: var(--surface-2); border-radius: 10px; overflow: hidden; }
.wb-col span { width: 100%; background: var(--primary); opacity: .45; border-radius: 10px 10px 0 0; }
.wb.is-active .wb-col span { opacity: 1; }
.wb-k { font-size: 11px; color: var(--muted); }
.wb-d { font-size: 12.5px; font-weight: 700; }

/* Gewicht */
.weight-form { display: grid; grid-template-columns: 1fr auto auto; gap: 8px; align-items: center; }
.unit { color: var(--muted); font-weight: 600; }
.btn { background: var(--primary); color: var(--primary-ink); font-weight: 700; padding: 11px 16px; border-radius: 12px; }
.weight-sum { display: flex; gap: 24px; }
.weight-sum p { display: flex; flex-direction: column; }
.weight-sum b { font-size: 20px; font-weight: 800; }
.weight-list { list-style: none; margin: 0; padding: 0; }
.weight-list li { display: grid; grid-template-columns: 1fr auto 32px; align-items: center; padding: 6px 0; border-top: 1px solid var(--line); font-size: 14px; }
.x-btn { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; color: var(--muted); }
.x-btn:hover { background: var(--surface-2); color: var(--ink); }

/* Rezepte */
.recipe-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.recipe { text-align: left; gap: 6px; transition: transform .15s; }
.recipe:hover { transform: translateY(-1px); }
.recipe-name { font-size: 17px; font-weight: 700; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { font-size: 12px; font-weight: 600; padding: 3px 9px; border-radius: 999px; background: var(--primary-soft); color: var(--primary); }

/* Rezept-Blatt */
#sheet { position: fixed; inset: 0; z-index: 50; }
.sheet-backdrop { position: absolute; inset: 0; background: rgb(10 16 12 / 45%); animation: fade .2s ease; }
.sheet {
  position: absolute; left: 0; right: 0; bottom: 0; max-height: 88vh; overflow-y: auto;
  background: var(--surface); border-radius: 24px 24px 0 0;
  padding: 10px max(20px, env(safe-area-inset-right, 0px)) calc(28px + env(safe-area-inset-bottom, 0px)) max(20px, env(safe-area-inset-left, 0px));
  animation: up .25s ease;
}
@media (min-width: 720px) {
  .sheet { left: 50%; top: 50%; bottom: auto; width: 560px; max-height: 84vh; transform: translate(-50%, -50%); border-radius: 24px; padding: 24px 28px 28px; animation: fade .2s ease; }
  .sheet-grip { display: none; }
}
.sheet-grip { width: 40px; height: 4px; border-radius: 4px; background: var(--line); margin: 0 auto 14px; }
.sheet-close { position: absolute; top: 12px; right: 12px; }
.sheet h2 { font-size: 23px; font-weight: 800; margin: 4px 40px 10px 0; }
.pills { display: flex; flex-wrap: wrap; gap: 6px; }
.pill { display: inline-flex; align-items: center; gap: 5px; font-size: 13px; font-weight: 700; padding: 5px 11px; border-radius: 999px; background: var(--primary-soft); color: var(--primary); }
.pill-protein { background: var(--accent-soft); color: var(--accent); }
.ing { margin: 0; padding: 0; list-style: none; }
.ing li { padding: 8px 0 8px 18px; border-top: 1px solid var(--line); position: relative; }
.ing li::before { content: ""; position: absolute; left: 2px; top: 17px; width: 6px; height: 6px; border-radius: 50%; background: var(--primary); }
.steps { margin: 0; padding: 0; list-style: none; counter-reset: s; display: flex; flex-direction: column; gap: 10px; }
.steps li { counter-increment: s; display: grid; grid-template-columns: 28px 1fr; gap: 10px; }
.steps li::before { content: counter(s); width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-size: 13px; font-weight: 800; background: var(--surface-2); }
@keyframes up { from { transform: translateY(30px); opacity: 0; } }
@keyframes fade { from { opacity: 0; } }

/* Einkauf */
.shop-head p b { font-size: 20px; font-weight: 800; }
.shop-actions { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px; }
.switch { display: inline-flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 600; cursor: pointer; }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.switch-track { width: 38px; height: 22px; border-radius: 99px; background: var(--line); position: relative; transition: background .2s; }
.switch-track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; border-radius: 50%; background: var(--surface); box-shadow: 0 1px 2px rgb(0 0 0 / 25%); transition: transform .2s; }
.switch input:checked + .switch-track { background: var(--primary); }
.switch input:checked + .switch-track::after { transform: translateX(16px); }
.switch input:focus-visible + .switch-track { outline: 2.5px solid var(--primary); outline-offset: 2px; }
.shop-group { display: flex; flex-direction: column; gap: 8px; }
.shop-group h2 { display: flex; justify-content: space-between; align-items: baseline; padding: 6px 4px 0; }
.shop-group h2 .muted { font-weight: 600; font-size: 12.5px; }
.shop-list { list-style: none; margin: 0; padding: 4px 14px; gap: 0; }
.shop-list li + li { border-top: 1px solid var(--line); }
.shop-item { width: 100%; display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; padding: 11px 0; }
.box { width: 24px; height: 24px; border-radius: 8px; display: grid; place-items: center; box-shadow: inset 0 0 0 2px var(--line); color: transparent; }
.is-done .box { background: var(--primary); color: var(--primary-ink); box-shadow: none; }
.si-text { display: flex; flex-direction: column; min-width: 0; }
.si-name { font-weight: 600; }
.si-note { font-size: 12.5px; color: var(--muted); }
.si-amount { font-size: 13px; color: var(--muted); font-weight: 600; text-align: right; max-width: 120px; }
.is-done .si-name { text-decoration: line-through; color: var(--muted); }

/* Tipps */
.tips { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.tip { gap: 6px; }
.tip p { font-size: 14px; color: var(--muted); }
.foot { font-size: 12.5px; color: var(--muted); text-align: center; padding: 8px 0; }

/* Tab-Leiste */
.tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-top: 1px solid var(--line);
  display: flex; justify-content: center;
  padding: 6px max(8px, env(safe-area-inset-right, 0px)) calc(6px + env(safe-area-inset-bottom, 0px)) max(8px, env(safe-area-inset-left, 0px));
}
.tab {
  flex: 1; max-width: 120px; display: flex; flex-direction: column; align-items: center; gap: 2px;
  padding: 6px 0; border-radius: 12px; color: var(--muted); text-decoration: none; font-size: 11.5px; font-weight: 600;
}
.tab.is-active { color: var(--primary); }
.tab.is-active .ic { stroke-width: 2.4; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* Kosten & Teilen */
.costs { display: grid; grid-template-columns: 1fr auto; gap: 8px 16px; align-items: end; }
.cost-big { font-size: 34px; font-weight: 800; letter-spacing: -.02em; line-height: 1.1; }
.cost-side { display: flex; flex-direction: column; gap: 8px; text-align: right; }
.cost-side p { display: flex; flex-direction: column; }
.cost-side b { font-size: 17px; font-weight: 800; }
.cost-note { grid-column: 1 / -1; font-size: 12.5px; color: var(--muted); border-top: 1px solid var(--line); padding-top: 10px; }
.si-right { display: flex; flex-direction: column; align-items: flex-end; text-align: right; }
.si-price { font-size: 12.5px; color: var(--muted); }
.is-done .si-price { text-decoration: line-through; }
.btn-wide { width: 100%; display: inline-flex; justify-content: center; align-items: center; gap: 8px; padding: 14px; font-size: 15.5px; }
.share-text { width: 100%; margin: 12px 0; padding: 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink); font: 13.5px/1.5 var(--font); resize: vertical; }
.toast {
  position: fixed; left: 50%; transform: translateX(-50%); z-index: 60;
  bottom: calc(var(--tabs-h) + env(safe-area-inset-bottom, 0px) + 16px);
  background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 12px; font-size: 14px; font-weight: 600;
  box-shadow: 0 6px 24px rgb(0 0 0 / 20%); max-width: calc(100% - 32px); animation: fade .2s ease;
}

/* Wochen-Rotation & berechnete Liste */
.week-chips small { font-size: 11px; font-weight: 700; opacity: .75; margin-left: 2px; }
.si-need { font-size: 12px; color: var(--muted); }
.si-tip { color: var(--accent); }
.used { font-size: 12.5px; color: var(--muted); border-top: 1px solid var(--line); padding-top: 8px; margin-top: 2px; }
.dinner-overview { list-style: none; margin: 6px 0 0; padding: 0; }
.dinner-overview li { display: grid; grid-template-columns: 34px 1fr; gap: 8px; padding: 7px 0; border-top: 1px solid var(--line); font-size: 14px; }
.dinner-overview li span { font-weight: 700; color: var(--muted); }
.tip-key { box-shadow: inset 0 0 0 2px var(--accent), var(--shadow); }
.tip-key h2 { color: var(--accent); }

/* ---------- Version 4: Serie, Wasser, Nährstoffe, Vorrat, Koch-Modus, Formular, Gewichtskurve ---------- */
.ic-xs { width: 13px; height: 13px; vertical-align: -2px; }
.sum-foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
.streak { display: inline-flex; align-items: center; gap: 4px; font-weight: 700; font-size: 12.5px; padding: 3px 10px; border-radius: 999px; background: var(--surface-2); color: var(--muted); }
.streak.is-on { background: var(--accent-soft); color: var(--accent); }

.stepper { display: flex; gap: 8px; }
.round-btn { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); color: var(--ink); }
.round-btn:disabled { opacity: .4; cursor: default; }
.round-main { background: var(--primary); color: var(--primary-ink); }
.glasses { display: grid; grid-template-columns: repeat(10, 1fr); gap: 4px; }
.glass { display: grid; place-items: center; aspect-ratio: 3 / 4; max-width: 100%; border-radius: 8px; background: var(--surface-2); color: var(--line); }
.glass.is-full { background: var(--water-soft); color: var(--water); }
.ic-glass { width: 60%; height: 60%; fill: currentColor; stroke: none; }

.nutri { display: flex; flex-direction: column; gap: 12px; margin-top: 2px; }
.nutri-top { display: grid; grid-template-columns: 1fr auto auto; gap: 8px; align-items: baseline; margin-bottom: 6px; }
.nutri-label { font-weight: 700; font-size: 14px; }
.nutri-val { font-size: 13px; color: var(--muted); }
.nutri-val b { color: var(--ink); }
.nutri-note { font-size: 12.5px; color: var(--muted); margin-top: 6px; }
.pill-s { font-size: 11.5px; font-weight: 700; padding: 2px 8px; border-radius: 999px; }
.s-ok { background: var(--primary-soft); color: var(--primary); }
.s-mid { background: var(--warn-soft); color: var(--warn); }
.s-low { background: var(--danger-soft); color: var(--danger); }
.bar-ok span { background: var(--primary); }
.bar-mid span { background: var(--warn); }
.bar-low span { background: var(--danger); }
.micro { font-size: 12.5px; color: var(--muted); margin: 8px 0 12px; }

.prep { list-style: none; margin: 0; padding: 0; }
.prep li { display: grid; grid-template-columns: 92px 1fr; gap: 10px; padding: 9px 0; border-top: 1px solid var(--line); font-size: 14px; }
.prep-when { font-weight: 700; color: var(--primary); font-size: 13px; }
.card h2 .ic-sm { vertical-align: -1px; margin-right: 2px; }

.shop-list li { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 6px; }
.home-btn { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; color: var(--muted); }
.home-btn:hover { background: var(--surface-2); color: var(--primary); }
.at-home li { padding: 10px 0; }

.custom-actions { display: flex; justify-content: space-between; margin-top: 18px; padding-top: 12px; border-top: 1px solid var(--line); }
.empty { align-items: flex-start; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.btn-ghost { background: var(--surface-2); color: var(--ink); }
.btn:disabled { opacity: .4; cursor: default; }
.sheet .btn-wide { margin-top: 4px; }

/* Koch-Modus: ganzer Bildschirm */
.cook {
  position: absolute; inset: 0; background: var(--bg); display: flex; flex-direction: column;
  padding: calc(env(safe-area-inset-top, 0px) + 12px) max(16px, env(safe-area-inset-right, 0px)) calc(env(safe-area-inset-bottom, 0px) + 16px) max(16px, env(safe-area-inset-left, 0px));
  animation: fade .2s ease;
}
.cook > * { width: 100%; max-width: 640px; margin-left: auto; margin-right: auto; }
.cook-head { display: flex; align-items: center; gap: 10px; }
.cook-title h2 { font-size: 19px; font-weight: 800; }
.cook-progress { display: flex; gap: 4px; margin: 14px auto 0; }
.cook-progress span { flex: 1; height: 5px; border-radius: 9px; background: var(--line); }
.cook-progress .is-done { background: var(--primary-soft); }
.cook-progress .is-on { background: var(--primary); }
.cook-body { flex: 1; overflow-y: auto; padding: 22px 2px; display: flex; flex-direction: column; gap: 18px; }
.cook-step-label { font-size: 13px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); }
.cook-text { font-size: 24px; line-height: 1.4; font-weight: 600; text-wrap: pretty; }
.cook-ing { list-style: none; margin: 0; padding: 0; }
.cook-ing li { border-top: 1px solid var(--line); }
.cook-ing label { display: flex; gap: 12px; align-items: center; padding: 12px 0; font-size: 17px; cursor: pointer; }
.cook-ing input { width: 22px; height: 22px; accent-color: var(--primary); flex: none; }
.cook-ing input:checked + span { color: var(--muted); text-decoration: line-through; }
.cook-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.cook-nav .btn { padding: 15px; font-size: 16px; }
.timer { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px 16px; }
.timer-time { font-size: 40px; font-weight: 800; letter-spacing: -.02em; }
.timer.is-running .timer-time { color: var(--primary); }
.timer.is-done .timer-time { color: var(--accent); }
.timer-btns { display: flex; gap: 8px; }
.timer-chip {
  position: fixed; right: max(16px, env(safe-area-inset-right, 0px)); z-index: 25;
  bottom: calc(var(--tabs-h) + env(safe-area-inset-bottom, 0px) + 14px);
  display: inline-flex; align-items: center; gap: 6px; padding: 9px 14px; border-radius: 999px;
  background: var(--primary); color: var(--primary-ink); font-weight: 700; font-size: 14px; box-shadow: 0 6px 20px rgb(0 0 0 / 18%);
}
.timer-chip.is-done { background: var(--accent); }

/* Formular */
.recipe-form { display: flex; flex-direction: column; gap: 10px; margin-top: 6px; }
.recipe-form input[type="text"], .recipe-form textarea, .ing-row input, .ing-row select {
  width: 100%; min-width: 0; padding: 11px 12px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--surface-2); color: var(--ink); font: 500 15px var(--font);
}
.recipe-form textarea { resize: vertical; line-height: 1.5; }
.form-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.form-grid .field { margin-top: 0; }
.ing-rows { display: flex; flex-direction: column; gap: 8px; }
.ing-row { display: grid; grid-template-columns: 1fr 96px 32px; gap: 6px; align-items: center; }
.ing-row input[name="ing-text"]:not([hidden]) { grid-column: 2 / 3; }
.ing-row:has(input[name="ing-text"]:not([hidden])) { grid-template-columns: 1fr 1fr 32px; }
.form-error { color: var(--danger); font-weight: 600; font-size: 14px; }

/* Gewichtskurve */
.wchart { margin: 4px 0 0; }
.wchart svg { width: 100%; height: auto; display: block; overflow: visible; }
.wc-grid { stroke: var(--line); stroke-width: 1; }
.wc-tick { fill: var(--muted); font: 600 10.5px var(--font); }
.wc-band { fill: var(--primary-soft); }
.wc-line { stroke: var(--accent); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.wc-dot { fill: var(--surface); stroke: var(--accent); stroke-width: 2; }
.wc-last { fill: var(--accent); }
.wchart figcaption { font-size: 12px; color: var(--muted); display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; margin-top: 4px; }
.lg { display: inline-block; width: 14px; height: 8px; border-radius: 3px; }
.lg-band { background: var(--primary-soft); }
.lg-line { background: var(--accent); height: 3px; margin-left: 8px; }

/* ---------- Version 5: Tauschen, Suche, Rückblick, Einstellungen ---------- */
.swap-grid { display: grid; grid-template-columns: 1fr; gap: 2px; }
@media (min-width: 520px) { .swap-grid { grid-template-columns: 1fr 1fr; gap: 2px 12px; } }

.search { display: flex; align-items: center; gap: 8px; padding: 0 14px; border-radius: 14px; background: var(--surface); box-shadow: var(--shadow); color: var(--muted); }
.search input { flex: 1; min-width: 0; border: 0; background: transparent; padding: 13px 0; font: 500 15px var(--font); color: var(--ink); outline: none; }
.search:focus-within { box-shadow: inset 0 0 0 2px var(--primary), var(--shadow); }
.chip-toggle { font-size: 13px; }

.review-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.review-stats p { display: flex; flex-direction: column; background: var(--surface-2); border-radius: 12px; padding: 10px; min-width: 0; }
.review-stats b { font-size: 20px; font-weight: 800; }
.review-stats span { font-size: 11.5px; color: var(--muted); line-height: 1.3; }
@media (max-width: 400px) { .review-stats { grid-template-columns: repeat(2, 1fr); } }
.review-bars { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.rb { display: flex; flex-direction: column; align-items: center; gap: 3px; }
.rb-col { width: 100%; height: 56px; display: flex; align-items: flex-end; background: var(--surface-2); border-radius: 8px; overflow: hidden; }
.rb-col span { width: 100%; background: var(--primary); opacity: .5; }
.rb-col span.is-full { opacity: 1; }
.rb-n { font-size: 11px; color: var(--muted); }
.rb-d { font-size: 12px; font-weight: 700; }

.set-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line); }
.set-row:first-of-type { border-top: 0; }
.set-row > span { display: flex; flex-direction: column; min-width: 0; }
.set-row small { color: var(--muted); font-size: 12.5px; }
.set-col { flex-direction: column; align-items: stretch; }
.step-val { min-width: 72px; text-align: center; font-weight: 700; font-size: 14px; align-self: center; }
.set-inline { display: flex; align-items: center; gap: 6px; }
.set-inline input, .set-one { width: 92px; padding: 9px 10px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink); font: 600 15px var(--font); text-align: center; }
select.set-one { width: auto; text-align: left; }
.day-toggles { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.day-t { padding: 9px 0; border-radius: 10px; background: var(--surface-2); font-weight: 700; font-size: 13.5px; color: var(--muted); }
.day-t.is-on { background: var(--primary); color: var(--primary-ink); }
.seg { display: grid; grid-template-columns: repeat(3, 1fr); background: var(--surface-2); border-radius: 12px; padding: 3px; }
.seg button { padding: 9px 4px; border-radius: 10px; font-weight: 600; font-size: 13.5px; color: var(--muted); text-align: center; }
.seg button.is-on { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.btn-row { display: flex; flex-wrap: wrap; gap: 8px; }
label.btn { cursor: pointer; }
a.btn { text-decoration: none; }
.confirm-box { background: var(--accent-soft); border-radius: 12px; padding: 12px; display: flex; flex-direction: column; gap: 10px; font-size: 14px; }
.section-title { font-size: 20px; font-weight: 800; padding: 10px 2px 0; }
.week-chips { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; overflow: visible; }
.week-chips .chip { justify-content: center; flex-direction: column; gap: 0; padding: 7px 4px; line-height: 1.2; font-size: 13px; }
.week-chips small { margin-left: 0; min-height: 13px; }

/* ---------- Version 6: Portionen, eigene Artikel, Laden-Reihenfolge ---------- */
.portion-box { background: var(--surface-2); border-radius: 14px; padding: 12px 14px; margin-top: 12px; display: flex; flex-direction: column; gap: 6px; }
.portion-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.portion-row > span { display: flex; flex-direction: column; min-width: 0; }
.portion-row small { color: var(--muted); font-size: 12.5px; line-height: 1.35; }
.portion-box .round-btn { background: var(--surface); }
.people-card .step-val { min-width: 92px; }
.add-extra { gap: 8px; }
.extra-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.extra-grid #extra-name { grid-column: 1 / -1; }
.extra-grid .btn { grid-column: 1 / -1; }
@media (min-width: 520px) { .extra-grid { grid-template-columns: 2fr 1fr 1fr auto; } .extra-grid #extra-name, .extra-grid .btn { grid-column: auto; } }
.extra-grid input { width: 100%; min-width: 0; padding: 11px 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink); font: 500 15px var(--font); }
.order-list { list-style: none; margin: 12px 0; padding: 0; }
.order-list li { display: grid; grid-template-columns: 28px 1fr auto auto; gap: 8px; align-items: center; padding: 8px 0; border-top: 1px solid var(--line); }
.order-n { font-weight: 800; color: var(--muted); text-align: center; }
.order-name { font-weight: 600; }
.order-btns { justify-content: space-between; align-items: center; }
#sheet.no-anim .sheet, #sheet.no-anim .sheet-backdrop, #sheet.no-anim .cook { animation: none; }

/* ---------- Gesundheits-Check ---------- */
.health { display: flex; flex-direction: column; gap: 14px; }
.health h2 { margin: 0 0 2px; }
.health-head { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: 14px; align-items: center; }
.score { position: relative; width: 72px; height: 72px; }
.score svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.score circle { fill: none; stroke-width: 8; }
.score-track { stroke: var(--surface-2); }
.score-bar { stroke: var(--spinach); stroke-linecap: round; transition: stroke-dashoffset .6s ease; }
.score span { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 13px; color: var(--muted); }
.score span b { font-size: 20px; color: var(--ink); }
.health-problems { display: flex; flex-direction: column; gap: 8px; }
.hp { border-radius: 14px; padding: 10px 12px; }
.hp p { margin: 0; }
.hp p:first-child { display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: baseline; }
.hp p:first-child span { font-size: 13px; color: var(--muted); }
.hp-note { font-size: 13.5px; margin-top: 4px !important; }
.s-mid-box { background: var(--saffron-soft); }
.s-low-box { background: var(--tomato-soft); }
.health-all summary { cursor: pointer; font-weight: 700; color: var(--primary); padding: 4px 0; }
.health-all[open] summary { margin-bottom: 12px; }
.health-all .hint { margin: 10px 0 0; }
.health-facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin-top: 14px; }
.health-facts p { margin: 0; background: var(--surface-2); border-radius: 12px; padding: 8px 6px; text-align: center; display: flex; flex-direction: column; }
.health-facts b { font-size: 16px; }
.health-facts span { font-size: 11.5px; color: var(--muted); line-height: 1.25; }
.supp-card { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; align-items: center; --tone: var(--berry); --tone-soft: var(--berry-soft); }
.supp-card h2 { margin: 0; font-size: 16px; }
.supp-card p { margin: 2px 0 0; }
.set-row > .set-supp { width: 120px; flex: none; flex-direction: row; }
.set-supp input { text-align: right; }

/* ---------- Sprache ---------- */
.lang-card h2 { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 10px; }
.lang-also { font: 600 13px var(--font); color: var(--muted); letter-spacing: 0; }
.lang-tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-top: 14px; }
.lang-tile {
  position: relative; display: flex; flex-direction: column; align-items: flex-start; min-width: 0;
  text-align: left; border-radius: 18px; overflow: hidden; padding: 0 0 12px;
  background: var(--surface-2); box-shadow: inset 0 0 0 2px transparent;
  transition: transform .3s cubic-bezier(.2, .8, .2, 1), box-shadow .3s, background-color .3s;
}
.lang-art { display: block; width: 100%; height: 66px; }
.lang-art svg { display: block; width: 100%; height: 100%; transition: filter .4s, opacity .4s; }
.lang-tile:not(.is-on) .lang-art svg { filter: saturate(.45); opacity: .8; }
.lang-code {
  position: relative; margin: -20px 0 0 10px; padding: 6px 9px 5px; border-radius: 12px 12px 12px 4px;
  background: var(--surface); color: var(--tone-ink); box-shadow: var(--shadow);
  font: 800 24px/1 var(--display); letter-spacing: .02em;
}
.lang-name { margin: 9px 10px 0; font-weight: 800; font-size: 14px; color: var(--ink); max-width: calc(100% - 20px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lang-hello { margin: 2px 10px 0; font-size: 12px; font-style: italic; color: var(--muted); line-height: 1.3; }
.lang-check {
  position: absolute; top: 8px; right: 8px; display: grid; place-items: center;
  width: 26px; height: 26px; border-radius: 50%; background: var(--tone); color: #fff;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .18);
  transform: scale(0) rotate(-45deg); transition: transform .35s cubic-bezier(.3, 1.6, .5, 1);
}
.lang-tile.is-on { background: var(--tone-soft); box-shadow: inset 0 0 0 2.5px var(--tone); }
.lang-tile.is-on .lang-check { transform: scale(1) rotate(0); }
.lang-tile.is-on .lang-code { background: var(--tone); color: #fff; }
.lang-tile:hover { transform: translateY(-2px); }
.lang-tile:active { transform: scale(.97); }
@media (prefers-reduced-motion: reduce) { .lang-tile, .lang-check, .lang-art svg { transition: none; } }

/* Kopf: lange Überschriften (z. B. „Aujourd’hui“) – Chip rutscht bei Platzmangel in die nächste Zeile */
.page-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 6px 12px; }
.page-head .eyebrow { flex: 0 0 auto; max-width: 100%; margin-right: 100%; }
.page-head .chip { margin-left: auto; }
.tab { min-width: 0; }
.tab > span:last-child { max-width: 100%; white-space: nowrap; letter-spacing: -.01em; }
@media (max-width: 380px) {
  .tab { font-size: 10.5px; }
  .lang-tiles { gap: 8px; }
  .lang-name { font-size: 12.5px; }
  .lang-code { font-size: 21px; }
}
.lang-name { white-space: normal; text-overflow: clip; overflow-wrap: anywhere; }

/* ---------- Präparate: Höchstmengen ---------- */
.supp-row { border-top: 1px solid var(--line); padding-bottom: 10px; }
.supp-row:first-of-type { border-top: 0; }
.supp-row .set-row { border-top: 0; padding-bottom: 6px; }

/* ---------- Sport ---------- */
.sport-week-chip { cursor: default; }
.sport-today { padding: 0; overflow: hidden; gap: 0; }
.st-art { display: block; height: 170px; width: 100%; padding: 0; border-radius: 0; }
.st-art .art { width: 100%; height: 100%; display: block; transition: transform .6s cubic-bezier(.2, .8, .2, 1); }
.st-art:hover .art { transform: scale(1.03); }
.st-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 8px; position: relative; }
.st-body .meal-slot { color: var(--tone-ink); }
.st-body h2 { font-size: 23px; line-height: 1.15; }
.st-btns { margin-top: 4px; }
.st-btns .btn:first-child { background: var(--tone); color: #fff; }
.st-done[aria-pressed="true"] { background: var(--spinach); color: #fff; }
.sport-today.is-done .st-art .art { filter: saturate(.6); }

.sw-days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.sw-day {
  display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 6px 2px 8px; min-width: 0;
  border-radius: 16px; background: var(--tone-soft); transition: transform .25s cubic-bezier(.2, .8, .2, 1), box-shadow .25s;
}
.sw-day:hover { transform: translateY(-2px); }
.sw-day:active { transform: scale(.95); }
.sw-day.is-today { box-shadow: inset 0 0 0 2.5px var(--tone); }
.sw-d { font-size: 12px; font-weight: 800; color: var(--tone-ink); }
.sw-art { position: relative; width: 100%; aspect-ratio: 1; border-radius: 12px; overflow: hidden; display: block; }
.sw-art .art { width: 100%; height: 100%; display: block; }
.sw-check { position: absolute; inset: 0; display: grid; place-items: center; background: rgb(47 143 91 / 72%); color: #fff; }
.sw-check .ic-tick { width: 22px; height: 22px; }
.sw-t { font-size: 10.5px; font-weight: 700; line-height: 1.15; text-align: center; color: var(--ink); max-width: 100%; overflow-wrap: anywhere; }
.sw-m { font-size: 10.5px; color: var(--muted); font-weight: 600; }

.sport-balance .nutri-note { margin-top: 5px; }
.sport-facts-mini { grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 6px; }

.sport-lib { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; }
.sport-card { text-align: left; gap: 6px; padding-top: 0; overflow: hidden; transition: transform .2s; }
.sport-card:hover { transform: translateY(-2px); }
.sc-art { display: block; margin: 0 -16px 4px; height: 118px; }
.sc-art .art { width: 100%; height: 100%; display: block; }
.sc-name { font: 800 17px/1.2 var(--display); }

.sport-facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 10px; }
.sport-fact { flex-direction: row; align-items: flex-start; gap: 14px; }
.sport-fact h2 { font-size: 17px; margin-bottom: 4px; }
.sport-fact p { font-size: 14px; color: var(--muted); line-height: 1.5; }
.sf-badge {
  flex: 0 0 74px; min-height: 74px; display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 8px 4px; border-radius: 20px 20px 20px 6px; background: var(--tone); color: #fff; text-align: center;
  transform: rotate(-3deg); box-shadow: 0 8px 18px -10px var(--tone);
}
.sport-fact:nth-child(even) .sf-badge { transform: rotate(3deg); border-radius: 20px 20px 6px 20px; }
.sf-badge b { font: 800 22px/1 var(--display); letter-spacing: -.02em; white-space: nowrap; }
.sf-badge span { font-size: 10px; font-weight: 700; line-height: 1.15; margin-top: 4px; opacity: .92; }
.sport-sources ul { margin: 0; padding-left: 18px; font-size: 14px; display: flex; flex-direction: column; gap: 4px; }
.sport-sources a { color: var(--primary); }

.pd-list { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.pd-opt {
  display: grid; grid-template-columns: 56px minmax(0, 1fr) 28px; align-items: center; gap: 12px; text-align: left;
  padding: 8px 10px 8px 8px; border-radius: 16px; background: var(--surface-2); transition: background .2s, box-shadow .2s;
}
.pd-opt.is-on { background: var(--tone-soft); box-shadow: inset 0 0 0 2.5px var(--tone); }
.pd-art { width: 56px; height: 56px; border-radius: 12px; overflow: hidden; display: block; }
.pd-art .art { width: 100%; height: 100%; display: block; }
.pd-text { display: flex; flex-direction: column; gap: 2px; }
.pd-text b { font-size: 15px; }
.pd-text small { font-size: 12.5px; color: var(--muted); }
.pd-check { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--tone); color: #fff; transform: scale(0); transition: transform .3s cubic-bezier(.3, 1.6, .5, 1); }
.pd-opt.is-on .pd-check { transform: scale(1); }

.ex-list { margin: 0; padding: 0; list-style: none; counter-reset: ex; display: flex; flex-direction: column; }
.ex-list li { counter-increment: ex; position: relative; padding: 12px 0 12px 40px; border-top: 1px solid var(--line); }
.ex-list li::before {
  content: counter(ex); position: absolute; left: 0; top: 12px; width: 28px; height: 28px; display: grid; place-items: center;
  border-radius: 50% 50% 50% 6px; background: var(--tomato); color: #fff; font: 800 14px var(--display);
}
.ex-list li:nth-child(3n+2)::before { background: var(--berry); }
.ex-list li:nth-child(3n)::before { background: var(--spinach); }
.ex-top { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.ex-reps { flex: none; font-weight: 800; font-size: 13px; padding: 2px 8px; border-radius: 99px; background: var(--surface-2); }
.ex-list p { font-size: 14px; color: var(--muted); margin: 4px 0 2px; }
.ex-list small { font-size: 12px; color: var(--muted); font-weight: 600; }

.workout .cook-progress .is-on { background: var(--tone); }
.workout .cook-num { background: var(--tone); }
.wo-reps { font: 800 20px var(--display); color: var(--tone-ink); margin-top: -8px; }
.wo-cue { font-size: 16px; color: var(--muted); line-height: 1.5; }
.wo-sets { display: flex; gap: 8px; }
.wo-sets i { flex: 1; max-width: 70px; height: 12px; border-radius: 99px; background: var(--line); transition: background .3s, transform .3s; }
.wo-sets i.is-on { background: var(--tone); transform: scaleY(1.25); }
.wo-load { max-width: 240px; }
.wo-set { padding: 16px; font-size: 17px; background: var(--tone); color: #fff; }
.wo-rest { border: 2px solid var(--tone-soft); }
.wo-rest .timer-btns { flex-direction: column; align-items: stretch; }
.wo-rest-l { font-weight: 800; color: var(--tone-ink); text-align: center; }
.wo-rest.timer.is-running .timer-time { color: var(--tone-ink); }
.btn-glow { animation: glow 1.6s ease-in-out infinite; }
@keyframes glow { 0%, 100% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--primary) 50%, transparent); } 50% { box-shadow: 0 0 0 8px color-mix(in srgb, var(--primary) 0%, transparent); } }
@media (max-width: 380px) {
  .sw-days { gap: 4px; }
  .sw-t, .sw-m { font-size: 9.5px; }
  .sf-badge { flex-basis: 62px; min-height: 64px; }
  .sf-badge b { font-size: 19px; }
}
.wo-rest.timer.is-running .dial-bar { stroke: var(--tone); }
.sport-fact { display: grid; grid-template-columns: 74px minmax(0, 1fr); column-gap: 14px; row-gap: 10px; align-items: center; }
.sport-fact p { grid-column: 1 / -1; }
.sport-fact h2 { margin: 0; line-height: 1.25; }
.sport-daily { margin-top: 10px; padding: 10px 12px; border-radius: 14px; background: var(--surface-2); }
.sport-daily .round-btn { background: var(--surface); }
@media (max-width: 380px) { .sport-fact { grid-template-columns: 62px minmax(0, 1fr); } }
.t-short { display: none; }
@media (max-width: 380px) { .t-long { display: none; } .t-short { display: inline; } }
.sport-daily { flex-wrap: wrap; row-gap: 8px; }
.sport-daily > span { flex: 1 1 150px; }
.sport-daily .stepper { flex: none; margin-left: auto; }
.sport-facts-mini p span { overflow-wrap: anywhere; }

/* Heute: Training-Karte */
.sport-mini { display: grid; grid-template-columns: 76px minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 12px; }
.sm-art { display: block; width: 76px; height: 76px; border-radius: 20px 24px 18px 26px; overflow: hidden; box-shadow: 0 8px 18px -10px var(--tone); }
.sm-art .art { width: 100%; height: 100%; display: block; }
.sm-body h2 { margin: 2px 0 2px; font-size: 17px; line-height: 1.2; }
.sm-body h2 a { color: inherit; text-decoration: none; }
.sm-body .muted { margin: 0; font-size: 13.5px; }
.sm-body .meal-slot { color: var(--tone-ink); }
.sm-go { background: var(--tone); color: #fff; width: 48px; height: 48px; }
.sm-done { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--tone); color: #fff; }
.sport-mini.is-done .sm-art .art { filter: saturate(.6); }

/* ---------- Sport, Version 2: kompakter ---------- */
.st2 {
  display: grid; grid-template-columns: 104px minmax(0, 1fr); grid-template-areas: "art body" "btns btns";
  gap: 12px 14px; align-items: center; padding: 14px;
}
.st2-art { grid-area: art; position: relative; display: block; width: 104px; height: 104px; padding: 0; border-radius: 26px 30px 22px 32px; overflow: hidden; box-shadow: 0 12px 24px -14px var(--tone); }
.st2-art .art { width: 100%; height: 100%; display: block; transition: transform .6s cubic-bezier(.2, .8, .2, 1); }
.st2-art:hover .art { transform: scale(1.06) rotate(-2deg); }
.st2-body { grid-area: body; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.st2-body .meal-slot { color: var(--tone-ink); }
.st2-body h2 { margin: 0; font-size: 20px; line-height: 1.15; }
.st2-body .muted { margin: 0; font-size: 14px; }
.st2-btns { grid-area: btns; display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); gap: 8px; }
.st2-btns .btn:first-child:not(.btn-ghost) { background: var(--tone); color: #fff; }
.st2.is-done .st2-art .art { filter: saturate(.6); }

.sw-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.sw-head h2 { margin: 0; }
.club-chip {
  display: inline-flex; align-items: center; gap: 8px; padding: 4px 12px 4px 4px; max-width: 100%;
  border-radius: 99px; background: var(--tone-soft); color: var(--tone-ink); text-align: left;
  transition: transform .2s, box-shadow .2s;
}
.club-chip:hover { box-shadow: inset 0 0 0 2px var(--tone); }
.club-chip:active { transform: scale(.97); }
.cc-art { flex: none; width: 34px; height: 34px; border-radius: 50%; overflow: hidden; display: block; }
.cc-art .art { width: 100%; height: 100%; display: block; }
.cc-text { display: flex; flex-direction: column; line-height: 1.1; min-width: 0; }
.cc-text small { font-size: 10.5px; font-weight: 700; opacity: .8; text-transform: uppercase; letter-spacing: .04em; }
.cc-text b { font-size: 14px; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sw-hint { margin: 10px 0 0; }
.club-nudge { display: flex; gap: 8px; align-items: center; width: 100%; text-align: left; margin-top: 10px; color: var(--ink); }

.sport-seg { margin: 6px 0 12px; position: sticky; top: 8px; z-index: 5; box-shadow: 0 6px 20px -14px rgba(0, 0, 0, .35); }
.sport-pane { display: flex; flex-direction: column; gap: 12px; }

.sport-list { padding: 6px; gap: 0; }
.sl-row {
  display: grid; grid-template-columns: 56px minmax(0, 1fr) auto 18px; align-items: center; gap: 12px;
  padding: 8px; border-radius: 16px; text-align: left; color: var(--ink); transition: background .2s;
}
.sl-row + .sl-row { border-top: 1px solid var(--line); border-radius: 0 0 16px 16px; }
.sl-row:hover { background: var(--tone-soft); border-radius: 16px; }
.sl-art { width: 56px; height: 56px; border-radius: 16px 18px 14px 20px; overflow: hidden; display: block; }
.sl-art .art { width: 100%; height: 100%; display: block; }
.sl-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.sl-text b { font-size: 15.5px; line-height: 1.2; }
.sl-text small { font-size: 13px; color: var(--muted); }
.sl-count { font: 800 13px var(--display); padding: 3px 9px; border-radius: 99px; background: var(--tone); color: #fff; }
.sl-count.is-zero { background: var(--surface-2); color: var(--muted); font-family: var(--font); font-weight: 700; }
.sl-row > svg { color: var(--muted); }

.sport-facts2 { display: flex; flex-direction: column; gap: 10px; }
.sf2 { padding: 12px 14px; gap: 0; }
.sf2 summary { display: grid; grid-template-columns: 64px minmax(0, 1fr) 20px; gap: 14px; align-items: center; cursor: pointer; list-style: none; }
.sf2 summary::-webkit-details-marker { display: none; }
.sf2 .sf-badge { flex: none; min-height: 60px; padding: 6px 4px; border-radius: 18px 18px 18px 6px; }
.sf2:nth-child(even) .sf-badge { transform: rotate(3deg); border-radius: 18px 18px 6px 18px; }
.sf2 .sf-badge b { font-size: 19px; }
.sf2 .sf-badge span { font-size: 9.5px; }
.sf2-title { font: 800 16px/1.25 var(--display); }
.sf2-chev { color: var(--muted); transform: rotate(90deg); transition: transform .3s; display: grid; place-items: center; }
.sf2[open] .sf2-chev { transform: rotate(-90deg); }
.sf2 p { margin: 12px 0 2px; font-size: 14.5px; line-height: 1.55; color: var(--muted); }
.sf2[open] p { animation: sfin .35s ease both; }
@keyframes sfin { from { opacity: 0; transform: translateY(-4px); } }

.club-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; margin: 12px 0; }
.club-opt {
  position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 8px 6px 10px;
  border-radius: 18px; background: var(--surface-2); text-align: center; transition: background .2s, box-shadow .2s, transform .2s;
}
.club-opt:active { transform: scale(.96); }
.club-opt.is-on { background: var(--tone-soft); box-shadow: inset 0 0 0 2.5px var(--tone); }
.co-art { width: 64px; height: 64px; border-radius: 18px 22px 16px 24px; overflow: hidden; display: block; }
.co-art .art { width: 100%; height: 100%; display: block; }
.co-name { font-size: 12.5px; font-weight: 700; line-height: 1.2; color: var(--ink); overflow-wrap: anywhere; }
.club-opt .pd-check { position: absolute; top: 6px; right: 6px; width: 22px; height: 22px; }
.club-opt.is-on .pd-check { transform: scale(1); }
.club-name { margin-bottom: 12px; }
@media (max-width: 380px) {
  .st2 { grid-template-columns: 84px minmax(0, 1fr); }
  .st2-art { width: 84px; height: 84px; }
  .st2-body h2 { font-size: 18px; }
  .club-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
.st2-btns .btn { white-space: nowrap; min-width: 0; }
@media (max-width: 380px) {
  .st2-btns .btn { font-size: 14px; padding-left: 10px; padding-right: 10px; }
  .sl-row { grid-template-columns: 48px minmax(0, 1fr) auto; gap: 10px; }
  .sl-row > svg { display: none; }
  .sl-art { width: 48px; height: 48px; }
  .sl-text b { font-size: 14.5px; }
  .sl-text small { font-size: 12px; }
}
.sport-seg { background: color-mix(in srgb, var(--surface-2) 88%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }

/* ===================== Profil ===================== */
.me-btn {
  position: absolute; top: 12px; right: 12px; z-index: 2;
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px 4px 4px; border-radius: 999px;
  background: var(--surface); color: var(--ink); box-shadow: 0 6px 16px -8px rgb(0 0 0 / 40%); text-decoration: none;
}
.me-btn .ic-xs { width: 15px; height: 15px; color: var(--muted); }
.me-av {
  width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center;
  background: var(--plum); color: #fff; font: 800 14px var(--display);
}
.me-av .ic-sm { width: 14px; height: 14px; }
.me-btn:active { transform: scale(.95); }

.pf-avatar {
  width: 48px; height: 48px; border-radius: 46% 54% 50% 50% / 52% 48% 52% 48%; display: grid; place-items: center; flex: none;
  background: var(--plum); color: #fff; font: 800 22px var(--display);
}
.pf-art { position: relative; overflow: visible; margin-bottom: 40px; }
.pf-art > .art { border-radius: 0; }
.pf-art .pf-avatar {
  position: absolute; left: 20px; bottom: -32px; width: 72px; height: 72px; font-size: 32px;
  box-shadow: 0 0 0 5px var(--surface), 0 10px 22px -10px rgb(0 0 0 / 45%);
}
.pf-art .pf-avatar .ic-sm { width: 28px; height: 28px; }
.pf-form { display: flex; flex-direction: column; gap: 6px; }
.pf-form #pf-name, .pf-form #mf-name {
  width: 100%; min-width: 0; padding: 11px 12px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--surface-2); color: var(--ink); font: 700 17px var(--font);
}
.pf-form #pf-name:focus, .pf-form #pf-year:focus, .pf-form #mf-name:focus { outline: none; box-shadow: 0 0 0 2px var(--plum); }
.pf-form #pf-year { font: 700 17px var(--font); }
.pf-row3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.pf-row3 .input-unit { padding-right: 10px; }
.pf-row3 .input-unit input { padding-left: 10px; padding-right: 4px; }
.pf-row3 .input-unit span { font-size: 13px; }
.pf-group { border: 0; padding: 0; margin: 12px 0 0; min-width: 0; }
.pf-group legend { font-size: 13px; font-weight: 600; color: var(--muted); padding: 0; margin-bottom: 6px; }
.pf-group .hint { margin: 6px 0 0; font-size: 12.5px; }
.pf-opts { display: grid; gap: 8px; }
.pf-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.pf-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.pf-opt { position: relative; display: block; cursor: pointer; }
.pf-opt input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.pf-opt > span {
  display: flex; flex-direction: column; justify-content: center; gap: 2px; height: 100%; min-height: 48px;
  padding: 10px 12px; border-radius: 14px; background: var(--surface-2); transition: background .2s, box-shadow .2s, transform .15s;
}
.pf-opt b { font-size: 14.5px; line-height: 1.2; overflow-wrap: anywhere; }
.pf-opt small { font-size: 12px; color: var(--muted); line-height: 1.3; }
.pf-3 .pf-opt > span { align-items: center; text-align: center; }
.pf-opt input:checked + span { background: var(--plum-soft); box-shadow: inset 0 0 0 2.5px var(--plum); color: var(--plum-ink); }
.pf-opt input:checked + span small { color: var(--plum-ink); opacity: .8; }
.pf-opt input:focus-visible + span { outline: 2.5px solid var(--plum); outline-offset: 2px; }
.pf-opt:active > span { transform: scale(.97); }
.pf-preview {
  margin-top: 14px; padding: 12px; border-radius: 18px;
  background: linear-gradient(150deg, var(--plum-soft), var(--sky-soft));
}
.pf-preview .hint { margin: 10px 2px 0; color: var(--ink); opacity: .75; }
.pf-preview .muted { margin: 2px; }
.pf-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.pf-stats p { margin: 0; display: flex; flex-direction: column; align-items: center; text-align: center; padding: 8px 4px; border-radius: 12px; background: var(--surface); min-width: 0; }
.pf-stats b { font: 800 16px var(--display); letter-spacing: -.01em; white-space: nowrap; }
.pf-stats span { font-size: 11.5px; color: var(--muted); }
.pf-form .btn-wide { margin-top: 12px; background: var(--plum); color: #fff; }
.pf-later { align-self: center; color: var(--muted); }
.pf-card { gap: 12px; }
.pf-card .pf-stats p { background: var(--surface-2); }
.pf-head { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; align-items: center; }
.pf-head h2 { margin: 0; overflow-wrap: anywhere; }
.pf-head .muted { margin: 2px 0 0; font-size: 13px; }
.pf-goal { margin: 0; font-size: 13.5px; font-weight: 700; color: var(--plum-ink); }
.pf-empty { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; align-items: center; background: linear-gradient(150deg, var(--plum-soft), var(--surface) 70%); }
.pf-empty h2 { margin: 0; }
.pf-empty .muted { margin: 2px 0 0; font-size: 13.5px; }
.pf-empty .btn { grid-column: 1 / -1; background: var(--plum); color: #fff; }

/* ===================== Schlaf & Energie ===================== */
.sl-card { background: linear-gradient(165deg, var(--sky-soft), var(--surface) 62%); }
.sl-head { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; align-items: start; }
.sl-head h2 { margin: 0; }
.sl-head .muted { margin: 2px 0 0; font-size: 13px; }
.sl-moon {
  width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; flex: none;
  background: #1f2a5a; color: #ffe08a; box-shadow: inset -6px -4px 0 rgb(255 255 255 / 8%);
}
.sl-moon .ic-sm { width: 18px; height: 18px; }
.sl-mini { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 14px; }
.sl-mini p { margin: 0; font-size: 14px; }
.sl-edit { display: flex; flex-direction: column; gap: 10px; }
.sl-q { margin: 4px 0 0; font-size: 13.5px; font-weight: 700; }
.en-row { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; }
.en-btn {
  display: flex; flex-direction: column; align-items: center; gap: 5px; padding: 9px 2px 8px; border-radius: 16px;
  background: var(--surface-2); font-size: 11.5px; font-weight: 700; color: var(--muted); line-height: 1.15; text-align: center;
  transition: background .2s, box-shadow .2s, transform .15s; min-width: 0;
}
.en-btn > span:last-child { overflow-wrap: anywhere; }
.en-dot { display: block; width: 32px; height: 32px; transition: transform .25s cubic-bezier(.3,1.6,.5,1), opacity .2s, filter .2s; }
.en-dot svg { width: 100%; height: 100%; display: block; }
.en-btn.is-on { background: var(--tone-soft); box-shadow: inset 0 0 0 2.5px var(--tone); color: var(--tone-ink); }
.en-btn.is-on .en-dot { transform: scale(1.15) rotate(-6deg); }
.en-row:has(.is-on) .en-btn:not(.is-on) .en-dot { opacity: .45; filter: saturate(.4); }
.en-btn:active { transform: scale(.95); }
.sl-edit.is-compact .portion-row { padding: 2px 0; }

.sleep-panel h3 { margin: 10px 0 0; font-size: 13px; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.sleep-chart { margin: 4px 0 0; }
.sleep-chart svg { width: 100%; height: auto; display: block; overflow: visible; }
.sleep-chart figcaption { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 12px; color: var(--muted); margin-top: 4px; }
.sleep-chart figcaption span { display: inline-flex; align-items: center; gap: 6px; }
.sc-band { fill: var(--sky); opacity: .16; }
.sc-grid { stroke: var(--line); stroke-dasharray: 3 4; }
.sc-tick { fill: var(--muted); font: 600 10.5px var(--font); }
.sc-today { fill: var(--sky-ink); font-weight: 800; }
.sc-bar, .sc-empty { cursor: pointer; transition: opacity .2s; }
.sc-bar:hover { opacity: .8; }
.sc-ok { fill: var(--sky); }
.sc-mid { fill: var(--saffron); }
.sc-low { fill: var(--tomato); }
.sc-empty { fill: var(--line); }
.sc-en { stroke: var(--surface); stroke-width: 1.5; }
.lg-dot { width: 10px; height: 10px; border-radius: 50%; background: conic-gradient(var(--beet), var(--saffron), var(--spinach), var(--sky), var(--beet)); }
.sleep-panel .lg-band { background: color-mix(in srgb, var(--sky) 30%, transparent); }

.tips-mini ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.tips-mini li { position: relative; padding-left: 24px; font-size: 14px; line-height: 1.45; }
.tips-mini li::before {
  content: ""; position: absolute; left: 2px; top: .45em; width: 11px; height: 11px;
  border-radius: 50% 50% 50% 3px; background: var(--sky); transform: rotate(-20deg);
}
.tips-mini li:nth-child(2n)::before { background: var(--saffron); }
.tips-mini li:nth-child(3n)::before { background: var(--beet); }

/* ===================== Körper ===================== */
.body-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.body-tile {
  position: relative; overflow: hidden; isolation: isolate;
  display: grid; grid-template-columns: auto minmax(0, 1fr); grid-template-areas: "ic t" "v v" "s s";
  align-items: center; gap: 2px 8px; padding: 12px 14px; border-radius: 20px; text-align: left;
  background: var(--surface); box-shadow: var(--shadow); transition: background .2s, box-shadow .2s, transform .15s;
}
.body-tile::after {
  content: ""; position: absolute; z-index: -1; right: -18px; bottom: -22px; width: 70px; height: 70px;
  border-radius: 46% 54% 42% 58%; background: var(--tone-soft); transition: transform .4s cubic-bezier(.3,1.4,.5,1);
}
.body-tile:active { transform: scale(.97); }
.bt-ic { grid-area: ic; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--tone-soft); color: var(--tone-ink); }
.bt-t { grid-area: t; font-size: 13px; font-weight: 700; color: var(--muted); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bt-v { grid-area: v; font: 800 22px var(--display); letter-spacing: -.01em; margin-top: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bt-s { grid-area: s; font-size: 12px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.body-tile.is-on { background: var(--tone-soft); box-shadow: inset 0 0 0 2.5px var(--tone), var(--shadow); }
.body-tile.is-on::after { background: var(--tone); opacity: .22; transform: scale(1.5); }
.body-tile.is-on .bt-ic { background: var(--tone); color: #fff; }
.body-tile.is-on .bt-t, .body-tile.is-on .bt-v { color: var(--tone-ink); }
.body-pane { display: flex; flex-direction: column; gap: 14px; }

/* ===================== Blutwerte ===================== */
.lab-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.lab-row {
  width: 100%; display: grid; grid-template-columns: minmax(0, 1fr) auto auto; grid-template-areas: "n sp v";
  align-items: center; gap: 2px 10px; padding: 10px 12px 10px 16px; border-radius: 16px; text-align: left;
  background: var(--surface-2); box-shadow: inset 5px 0 0 var(--tone); transition: transform .15s;
}
.lab-row:active { transform: scale(.98); }
.lab-name { grid-area: n; display: flex; flex-direction: column; min-width: 0; }
.lab-name b { font-size: 14.5px; line-height: 1.25; overflow-wrap: anywhere; }
.lab-name small { font-size: 12px; color: var(--muted); }
.spark { grid-area: sp; width: 72px; height: 26px; }
.lab-val { grid-area: v; justify-self: end; white-space: nowrap; }
.lab-val b { font: 800 18px var(--display); }
.lab-val small { font-size: 11.5px; color: var(--muted); }
.lab-empty { background: linear-gradient(150deg, var(--tomato-soft), var(--surface-2) 75%); border-radius: 16px; padding: 14px; }
.lab-empty p { margin: 0; font-size: 14px; line-height: 1.45; }
.lab-empty .hint { margin-top: 8px; font-size: 13px; }
.labs .chip-on { flex: none; }
.lab-chart { width: 100%; height: auto; display: block; margin: 10px 0 4px; overflow: visible; }
.lab-line { fill: none; stroke: var(--ink); stroke-opacity: .55; stroke-width: 2.2; stroke-linejoin: round; stroke-linecap: round; }
.lab-pt { fill: var(--sky); stroke: var(--surface); stroke-width: 2.5; }
.lab-note { margin-top: 12px; }
.lab-hist li { grid-template-columns: minmax(0, 1fr) auto 32px; gap: 8px; }
.lab-hist li > span:first-child { font-size: 13.5px; }
.lab-form { display: flex; flex-direction: column; }
.lab-form #lab-date { width: 100%; min-width: 0; padding: 11px 10px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink); font: 600 15px var(--font); min-height: 46px; margin-bottom: 8px; }
.lab-in { display: grid; grid-template-columns: minmax(0, 1fr) 118px 62px; gap: 8px; align-items: center; padding: 8px 0; border-top: 1px solid var(--line); }
.lab-in label { display: flex; align-items: center; gap: 8px; font-size: 14px; line-height: 1.25; min-width: 0; }
.lab-in label::before { content: ""; flex: none; width: 10px; height: 10px; border-radius: 50% 50% 50% 3px; background: var(--tone); transform: rotate(-20deg); }
.lab-in label b { overflow-wrap: anywhere; font-weight: 700; }
.lab-in .input-unit { padding-right: 8px; }
.lab-in .input-unit input { padding: 9px 8px; font-size: 16px; }
.lab-in .input-unit span { font-size: 11.5px; white-space: nowrap; }
.unit-sw {
  font-size: 11.5px; font-weight: 700; padding: 7px 4px; border-radius: 10px; line-height: 1.1;
  background: var(--tone-soft); color: var(--tone-ink); white-space: nowrap;
}
.unit-sw::before { content: "⇄ "; }
.lab-form .btn-wide { margin-top: 14px; }

/* ===================== Erinnerungen ===================== */
.reminders h2 { display: flex; align-items: center; gap: 6px; margin: 0; }
.reminders h2 .ic-sm { width: 18px; height: 18px; color: var(--saffron-ink); }
.reminders .day-head .muted { margin: 2px 0 0; }
.rem-row { display: flex; flex-direction: column; gap: 8px; padding: 12px 0; border-top: 1px solid var(--line); }
.rem-row:first-of-type { border-top: 0; }
.rem-row .switch { width: 100%; align-items: center; gap: 12px; }
.rem-row .switch-track { flex: none; }
.rem-row .switch input:checked + .switch-track { background: var(--saffron-ink); }
.rem-text { display: flex; flex-direction: column; min-width: 0; }
.rem-text b { font-size: 14.5px; color: var(--ink); }
.rem-text small { font-size: 12.5px; color: var(--muted); font-weight: 500; }
.rem-time { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding-left: 50px; animation: rise .35s cubic-bezier(.2,.8,.2,1) both; }
.rem-time span { color: var(--muted); font-weight: 700; }
.rem-time input[type="time"], .rem-time select {
  width: auto; min-width: 0; padding: 8px 10px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--saffron-soft); color: var(--saffron-ink); font: 700 15px var(--font); min-height: 40px;
}
.rem-time select { padding-right: 28px; }
.rem-ways { display: flex; flex-wrap: wrap; gap: 8px; padding-top: 4px; }
.rem-ways .btn { flex: 1 1 auto; }
.rem-ways .btn:not(.btn-ghost) { background: var(--saffron); color: #2a1d00; }
.reminders > .hint { margin: 0; line-height: 1.45; }

@media (max-width: 380px) {
  /* minmax(0, …): Spalten dürfen nicht breiter werden als der Platz (sonst lag „Gewicht“ auf dem iPhone SE außerhalb des Bildschirms) */
  .pf-row3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pf-row3 > .field, .pf-row3 input { min-width: 0; }
  .pf-row3 #pf-year { width: 100%; }
  /* Knöpfe mit drei Spalten (Geschlecht, Ziel): nicht mitten im Wort umbrechen */
  .pf-3 .pf-opt > span { padding-left: 4px; padding-right: 4px; }
  .pf-3 .pf-opt b { font-size: 13.5px; overflow-wrap: normal; hyphens: auto; }
  .pf-row3 .field:first-child { grid-column: 1 / -1; }
  .pf-stats b { font-size: 14.5px; }
  .pf-stats span { font-size: 10.5px; }
  .en-btn { font-size: 10.5px; padding-left: 0; padding-right: 0; }
  .en-dot { width: 28px; height: 28px; }
  .lab-row { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "n v"; }
  .spark { display: none; }
  .lab-in { grid-template-columns: minmax(0, 1fr) 104px 56px; gap: 6px; }
  .rem-time { padding-left: 0; }
  .bt-v { font-size: 19px; }
}
.pf-row3 { align-items: end; }
@media (max-width: 430px) { .rem-time { padding-left: 0; } }
.page-head { padding-top: 58px; }
@media (max-width: 380px) {
  .body-tile { grid-template-columns: auto minmax(0, 1fr); grid-template-areas: "ic ." "t t" "v v" "s s"; }
  .bt-t { margin-top: 6px; }
  .bt-v { margin-top: 0; }
  .lab-in { grid-template-columns: minmax(0, 1fr) 60px; row-gap: 6px; }
  .lab-in label { grid-column: 1 / -1; }
  .lab-in > span:last-child:empty { display: none; }
}

/* =====================================================================
   iOS-Design: neutraler Hintergrund, klare Karten, Glas nur an den Rändern
   (Tab-Leiste, Titelleiste, Knöpfe, Fenster). Jeder Bereich hat seine
   Apple-Systemfarbe. Schrift: San Francisco (Systemschrift).
   ===================================================================== */
:root {
  --font: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Helvetica Neue', 'Segoe UI', Roboto, system-ui, sans-serif;
  --display: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Helvetica Neue', 'Segoe UI', Roboto, system-ui, sans-serif;
  --rounded: ui-rounded, 'SF Pro Rounded', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;

  --bg: #f2f2f7;
  --surface: #ffffff;
  --surface-2: #eeeef3;
  --fill: rgb(120 120 128 / 12%);
  --line: #e5e5ea;
  --ink: #000000;
  --muted: #6e6e73;
  --radius: 24px;
  --shadow: 0 0.5px 1px rgb(0 0 0 / 4%);

  --glass: rgb(255 255 255 / 62%);
  --glass-strong: rgb(250 250 252 / 84%);
  --glass-hl: inset 0 1px 0 rgb(255 255 255 / 90%), inset 0 -0.5px 0 rgb(255 255 255 / 40%), inset 0 0 0 0.5px rgb(0 0 0 / 6%);
  --glass-shadow: 0 8px 28px rgb(0 0 0 / 12%), 0 1px 3px rgb(0 0 0 / 6%);
  --glass-blur: blur(22px) saturate(180%);
  --dim: rgb(0 0 0 / 28%);

  --tomato: #ff3b30;  --tomato-ink: #d70015;  --tomato-soft: rgb(255 59 48 / 12%);
  --orange: #ff9500;  --orange-ink: #c93400;  --orange-soft: rgb(255 149 0 / 14%);
  --saffron: #ffcc00; --saffron-ink: #a05a00; --saffron-soft: rgb(255 204 0 / 18%);
  --spinach: #34c759; --spinach-ink: #248a3d; --spinach-soft: rgb(52 199 89 / 14%);
  --sky: #32ade6;     --sky-ink: #0071a4;     --sky-soft: rgb(50 173 230 / 14%);
  --berry: #007aff;   --berry-ink: #0040dd;   --berry-soft: rgb(0 122 255 / 12%);
  --beet: #ff2d55;    --beet-ink: #d30f45;    --beet-soft: rgb(255 45 85 / 12%);
  --plum: #af52de;    --plum-ink: #8944ab;    --plum-soft: rgb(175 82 222 / 13%);
  --indigo: #5856d6;  --indigo-ink: #3634a3;  --indigo-soft: rgb(88 86 214 / 13%);

  --primary: var(--berry); --primary-soft: var(--berry-soft); --primary-text: var(--berry-ink); --primary-ink: #ffffff;
  --accent: var(--orange); --accent-soft: var(--orange-soft);
  --danger: var(--tomato-ink); --danger-soft: var(--tomato-soft);
  --warn: var(--orange-ink); --warn-soft: var(--orange-soft);
  --water: var(--sky); --water-soft: var(--sky-soft);

  --ring-kcal: #fa114f; --ring-prot: #4cc300; --ring-water: #00b4d8;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #000000; --surface: #1c1c1e; --surface-2: #2c2c2e; --fill: rgb(120 120 128 / 24%); --line: #38383a; --ink: #ffffff; --muted: #98989f;
    --shadow: none;
    --glass: rgb(36 36 38 / 58%); --glass-strong: rgb(30 30 32 / 84%);
    --glass-hl: inset 0 1px 0 rgb(255 255 255 / 16%), inset 0 0 0 0.5px rgb(255 255 255 / 10%);
    --glass-shadow: 0 10px 30px rgb(0 0 0 / 55%); --dim: rgb(0 0 0 / 50%);
    --tomato: #ff453a;  --tomato-ink: #ff6961;  --tomato-soft: rgb(255 69 58 / 20%);
    --orange: #ff9f0a;  --orange-ink: #ffb340;  --orange-soft: rgb(255 159 10 / 20%);
    --saffron: #ffd60a; --saffron-ink: #ffd426; --saffron-soft: rgb(255 214 10 / 18%);
    --spinach: #30d158; --spinach-ink: #30db5b; --spinach-soft: rgb(48 209 88 / 20%);
    --sky: #64d2ff;     --sky-ink: #70d7ff;     --sky-soft: rgb(100 210 255 / 18%);
    --berry: #0a84ff;   --berry-ink: #409cff;   --berry-soft: rgb(10 132 255 / 22%);
    --beet: #ff375f;    --beet-ink: #ff6482;    --beet-soft: rgb(255 55 95 / 20%);
    --plum: #bf5af2;    --plum-ink: #da8fff;    --plum-soft: rgb(191 90 242 / 22%);
    --indigo: #5e5ce6;  --indigo-ink: #7d7aff;  --indigo-soft: rgb(94 92 230 / 24%);
    --ring-kcal: #fa114f; --ring-prot: #a6ff00; --ring-water: #00f0ff;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #000000; --surface: #1c1c1e; --surface-2: #2c2c2e; --fill: rgb(120 120 128 / 24%); --line: #38383a; --ink: #ffffff; --muted: #98989f;
  --shadow: none;
  --glass: rgb(36 36 38 / 58%); --glass-strong: rgb(30 30 32 / 84%);
  --glass-hl: inset 0 1px 0 rgb(255 255 255 / 16%), inset 0 0 0 0.5px rgb(255 255 255 / 10%);
  --glass-shadow: 0 10px 30px rgb(0 0 0 / 55%); --dim: rgb(0 0 0 / 50%);
  --tomato: #ff453a;  --tomato-ink: #ff6961;  --tomato-soft: rgb(255 69 58 / 20%);
  --orange: #ff9f0a;  --orange-ink: #ffb340;  --orange-soft: rgb(255 159 10 / 20%);
  --saffron: #ffd60a; --saffron-ink: #ffd426; --saffron-soft: rgb(255 214 10 / 18%);
  --spinach: #30d158; --spinach-ink: #30db5b; --spinach-soft: rgb(48 209 88 / 20%);
  --sky: #64d2ff;     --sky-ink: #70d7ff;     --sky-soft: rgb(100 210 255 / 18%);
  --berry: #0a84ff;   --berry-ink: #409cff;   --berry-soft: rgb(10 132 255 / 22%);
  --beet: #ff375f;    --beet-ink: #ff6482;    --beet-soft: rgb(255 55 95 / 20%);
  --plum: #bf5af2;    --plum-ink: #da8fff;    --plum-soft: rgb(191 90 242 / 22%);
  --indigo: #5e5ce6;  --indigo-ink: #7d7aff;  --indigo-soft: rgb(94 92 230 / 24%);
  --ring-kcal: #fa114f; --ring-prot: #a6ff00; --ring-water: #00f0ff;
  color-scheme: dark;
}

/* ---------- Grundlagen ---------- */
body { background: var(--bg); font: 15px/1.45 var(--font); letter-spacing: -0.01em; }
h1, h2, h3, .meal-name, .recipe-name, .sheet h2, .cost-big, .timer-time, .cook-text, .section-title { font-family: var(--display); }
h2 { font-size: 20px; font-weight: 700; letter-spacing: -0.02em; }
.card h2 { font-size: 20px; }
h3 { font-size: 13px; font-weight: 600; letter-spacing: 0; text-transform: uppercase; color: var(--muted); }
.muted, .hint { color: var(--muted); }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--primary) 60%, transparent); outline-offset: 2px; border-radius: 12px; }
.wrap { gap: 16px; padding-top: calc(env(safe-area-inset-top, 0px) + 8px); padding-bottom: calc(var(--tabs-h) + env(safe-area-inset-bottom, 0px) + 40px); }
.wrap > h3, .page > h3, .section-title { padding-left: 4px; }
.section-title { font-size: 22px; font-weight: 700; letter-spacing: -0.02em; }

.card { border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px; gap: 12px; background: var(--surface); }
.note { background: var(--surface); }
.note-inline { background: var(--fill); border-radius: 14px; }
.s-ok-box { background: var(--spinach-soft); }
.s-mid-box { background: var(--orange-soft); }
.s-low-box { background: var(--tomato-soft); }

/* ---------- Glas-Leiste oben (kleiner Titel beim Scrollen) ---------- */
.topbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 30;
  height: calc(env(safe-area-inset-top, 0px) + 48px); padding-top: env(safe-area-inset-top, 0px);
  display: grid; place-items: center; cursor: pointer;
  background: var(--glass-strong); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
  box-shadow: 0 0.5px 0 var(--line);
  opacity: 0; transform: translateY(-6px); pointer-events: none;
  transition: opacity .25s ease, transform .25s ease;
}
.topbar.is-on { opacity: 1; transform: none; pointer-events: auto; }
.tb-title { font: 600 17px var(--font); letter-spacing: -0.02em; max-width: 70%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- Seitenkopf: großer Titel wie in iOS ---------- */
.page-head {
  position: relative; display: flex; flex-wrap: wrap; align-items: flex-end; gap: 4px 10px;
  min-height: 0; padding: 10px 4px 2px; margin: 0; border-radius: 0; box-shadow: none; background: none; overflow: visible; isolation: auto;
}
.page-head .eyebrow {
  order: 0; flex: 1 1 calc(100% - 52px); min-height: 38px; display: flex; align-items: flex-end;
  margin: 0; padding: 0 0 2px; background: none; box-shadow: none; transform: none;
  font-size: 13px; font-weight: 600; letter-spacing: 0; text-transform: uppercase; color: var(--muted);
}
.page-head h1 {
  order: 2; flex: 1 1 auto; margin: 0; padding: 0; background: none; box-shadow: none; transform: none; border-radius: 0;
  font: 700 34px/1.12 var(--display); letter-spacing: -0.01em; color: var(--ink);
}
.page-head h1::before, .page-head h1::after { content: none; }
.page-head > :not(.eyebrow):not(h1):not(.me-btn) { order: 3; margin-left: auto; margin-bottom: 4px; }
.me-btn {
  order: 1; position: static; flex: none; display: grid; place-items: center; width: 38px; height: 38px; padding: 0;
  border-radius: 50%; background: none; box-shadow: none; text-decoration: none;
}
.me-av {
  width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center;
  background: linear-gradient(180deg, #a8a8ae, #85858b); color: #fff; font: 600 16px var(--rounded);
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 35%);
}
.me-av .ic-sm { width: 18px; height: 18px; }
.me-btn:active { opacity: .7; transform: none; }

/* ---------- Chips, Knöpfe, Felder ---------- */
.chip {
  padding: 7px 14px; border-radius: 999px; font-size: 14px; font-weight: 600; letter-spacing: -0.01em;
  background: var(--surface); color: var(--ink); box-shadow: var(--shadow);
}
.chip .ic-sm, .chip .ic-xs { color: var(--muted); }
.chip-on, .chips .chip-on, .week-chips .chip-on { background: var(--primary); color: #fff; box-shadow: none; }
.chip-on .ic-sm, .chip-on .ic-xs { color: #fff; }
.week-chips .chip { border-radius: 16px; }

.btn {
  border-radius: 999px; padding: 12px 18px; font-size: 16px; font-weight: 600; letter-spacing: -0.01em;
  background: var(--primary); color: #fff; box-shadow: none;
}
.btn-ghost { background: var(--fill); color: var(--primary-text); }
.btn-wide { padding: 15px; font-size: 17px; }
.link-btn { color: var(--primary-text); font-weight: 600; font-size: 15px; }
.link-btn.danger { color: var(--danger); }
.round-btn { width: 40px; height: 40px; background: var(--fill); color: var(--primary-text); }
.round-main { background: var(--primary); color: #fff; }
.x-btn { color: var(--muted); }
button:active:not(:disabled) { transform: scale(.97); }
.btn:active:not(:disabled), .chip:active { opacity: .85; }

select, input[type="number"], .recipe-form input[type="text"], .recipe-form textarea, .ing-row input, .ing-row select,
.extra-grid input, .share-text, .set-inline input, .set-one, .input-unit {
  border: 0; border-radius: 12px; background: var(--fill); color: var(--ink);
}
.input-unit:focus-within, .search:focus-within { box-shadow: 0 0 0 2px var(--primary); }
.weight-form2 input[type="date"], .lab-form #lab-date, .pf-form #pf-name { border: 0; background: var(--fill); }

.search { border-radius: 14px; background: var(--fill); box-shadow: none; }
.search input { padding: 11px 0; }

/* Segmente wie im iOS-Segmented-Control */
.seg { background: var(--fill); border-radius: 999px; padding: 3px; }
.seg button { border-radius: 999px; color: var(--ink); font-weight: 600; }
.seg button.is-on { background: var(--surface); color: var(--ink); box-shadow: 0 3px 8px rgb(0 0 0 / 12%), 0 0 0 0.5px rgb(0 0 0 / 4%); }

/* Schalter wie in iOS */
.switch-track { width: 51px; height: 31px; background: var(--fill); }
.switch-track::after { top: 2px; left: 2px; width: 27px; height: 27px; background: #fff; box-shadow: 0 3px 8px rgb(0 0 0 / 15%), 0 1px 1px rgb(0 0 0 / 16%); transition: transform .25s cubic-bezier(.3, 1.3, .5, 1); }
.switch input:checked + .switch-track { background: #34c759; }
.switch input:checked + .switch-track::after { transform: translateX(20px); }

.pill { background: var(--fill); color: var(--ink); font-weight: 600; }
.pill-protein { background: var(--beet-soft); color: var(--beet-ink); }
.tag { background: var(--fill); color: var(--muted); font-weight: 600; }
.recipe .tag { background: var(--tone-soft); color: var(--tone-ink); }
.pill-s { font-weight: 600; }
.s-ok { background: var(--spinach-soft); color: var(--spinach-ink); }
.s-mid { background: var(--orange-soft); color: var(--orange-ink); }
.s-low { background: var(--tomato-soft); color: var(--tomato-ink); }
.bar { height: 6px; background: var(--fill); }
.bar-kcal span { background: var(--ring-kcal); }
.bar-protein span { background: var(--ring-prot); }
.bar-ok span { background: var(--spinach); }
.bar-mid span { background: var(--orange); }
.bar-low span { background: var(--tomato); }
.streak { background: var(--fill); color: var(--muted); font-weight: 600; }
.streak.is-on { background: var(--orange-soft); color: var(--orange-ink); }

/* ---------- Emoji-Kacheln (statt Kunstbilder) ---------- */
.emo {
  container-type: inline-size; position: relative; display: grid; place-items: center;
  width: 100%; aspect-ratio: 1; border-radius: 26%;
  background: linear-gradient(160deg, color-mix(in srgb, var(--tone) 26%, var(--surface)), color-mix(in srgb, var(--tone) 12%, var(--surface)));
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 55%), inset 0 0 0 0.5px color-mix(in srgb, var(--tone) 30%, transparent);
}
.emo-g { font-size: 56cqi; line-height: 1; font-family: 'Apple Color Emoji', 'Segoe UI Emoji', 'Noto Color Emoji', sans-serif; letter-spacing: 0; }
.meal-art, .recipe-art, .sheet-art, .cook-art, .sw-art, .sc-art, .pd-art, .sm-art, .st2-art, .cc-art, .sl-art, .co-art, .lang-art, .st-art {
  background: none; border-radius: 0; overflow: visible; box-shadow: none; transform: none; filter: none;
}
.meal-art .emo, .recipe-art .emo, .sw-art .emo, .pd-art .emo, .sm-art .emo, .st2-art .emo, .cc-art .emo, .sl-art .emo, .co-art .emo { height: 100%; }

/* ---------- Heute: Ringe ---------- */
.rings-card { gap: 14px; }
.rings-row { display: grid; grid-template-columns: 132px minmax(0, 1fr); gap: 18px; align-items: center; }
.rings { width: 132px; height: 132px; display: block; }
.rg-track, .rg-bar { fill: none; stroke-width: 13; }
.rg-bar { stroke-linecap: round; }
.rg-track.rg-kcal { stroke: color-mix(in srgb, var(--ring-kcal) 20%, transparent); }
.rg-track.rg-prot { stroke: color-mix(in srgb, var(--ring-prot) 22%, transparent); }
.rg-track.rg-water { stroke: color-mix(in srgb, var(--ring-water) 22%, transparent); }
.rg-bar.rg-kcal { stroke: var(--ring-kcal); }
.rg-bar.rg-prot { stroke: var(--ring-prot); }
.rg-bar.rg-water { stroke: var(--ring-water); }
.page.enter .rg-bar { animation: ringIn 1s cubic-bezier(.3, .9, .3, 1) both .1s; }
@keyframes ringIn { from { stroke-dasharray: 0 400; } }
.ring-stats { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.rs { display: flex; flex-direction: column; line-height: 1.15; }
.rs span { font-size: 15px; font-weight: 600; color: var(--ink); }
.rs b { font: 600 24px/1.1 var(--rounded); letter-spacing: -0.01em; white-space: nowrap; }
.rs small { font-size: 15px; font-weight: 600; margin-left: 1px; }
.rs-kcal b { color: var(--ring-kcal); }
.rs-prot b { color: var(--spinach-ink); }
.rs-water b { color: var(--sky-ink); }
:root[data-theme="dark"] .rs-prot b { color: var(--ring-prot); }
:root[data-theme="dark"] .rs-water b { color: var(--ring-water); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .rs-prot b { color: var(--ring-prot); } :root:not([data-theme="light"]) .rs-water b { color: var(--ring-water); } }
.rings-foot { display: flex; align-items: center; gap: 10px; padding-top: 12px; border-top: 0.5px solid var(--line); font-size: 14px; color: var(--muted); }
.rf-text { flex: 1; min-width: 0; }
.meal-dots { display: inline-flex; gap: 4px; }
.meal-dots i { width: 8px; height: 8px; border-radius: 50%; background: var(--fill); transition: background .3s; }
.meal-dots i.on { background: var(--tone); }
.rings-card.is-complete .rf-text { color: var(--ink); font-weight: 600; }
@media (max-width: 370px) {
  .rings-row { grid-template-columns: 108px minmax(0, 1fr); gap: 14px; }
  .rings { width: 108px; height: 108px; }
  .rs b { font-size: 20px; }
  .rs span, .rs small { font-size: 13px; }
}

/* ---------- Mahlzeiten ---------- */
.meals { gap: 10px; }
.meal {
  position: relative; overflow: visible; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center;
  gap: 4px 12px; padding: 12px 14px 12px 12px; border-radius: 20px; background: var(--surface); box-shadow: var(--shadow); transition: none;
}
.meal::before { content: none; }
.meal:active { transform: none; }
.meal-body { flex-direction: row; align-items: center; gap: 12px; padding: 0; }
.meal-art { width: 52px; height: 52px; flex: none; display: block; }
.meal-text { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.meal-slot, .meal .meal-slot, .recipe .meal-slot, .sheet .meal-slot[style] { font-size: 12px; font-weight: 600; letter-spacing: 0; text-transform: uppercase; color: var(--tone-ink, var(--primary-text)); }
.meal-slot em { color: var(--muted); text-transform: none; font-weight: 500; }
.meal-name { font-size: 17px; font-weight: 600; letter-spacing: -0.02em; line-height: 1.25; }
.meta { font-size: 13px; }
.meta b { font-weight: 600; }
.tick { width: 30px; height: 30px; box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--muted) 45%, transparent); background: none; transition: background .2s, box-shadow .2s; }
.tick:hover { box-shadow: inset 0 0 0 2px var(--tone); background: none; }
.is-done .tick { background: var(--tone); color: #fff; box-shadow: none; }
.meal.pop .tick { animation: tickPop .45s cubic-bezier(.3, 1.6, .5, 1); }
@keyframes tickPop { 0% { transform: scale(.6); } 60% { transform: scale(1.12); } 100% { transform: scale(1); } }
.is-done .meal-art { opacity: .45; filter: grayscale(.5); }
.is-done .meal-name { color: var(--muted); text-decoration: none; }
.chev { color: color-mix(in srgb, var(--muted) 60%, transparent); width: 16px; height: 16px; }
@media (max-width: 380px) { .meal-art { width: 44px; height: 44px; } .meal-name { font-size: 16px; } }

/* ---------- Wasser ---------- */
.water { display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 16px; align-items: center; background: var(--surface); }
.water-emo { width: 64px; }
.water-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.water-big { font: 600 15px var(--rounded); color: var(--muted); }
.water-big b { font: 600 30px var(--rounded); color: var(--sky-ink); letter-spacing: -0.01em; }
.water-body .stepper { margin-top: 8px; }
.water-plus { width: auto; padding: 0 18px; border-radius: 999px; gap: 6px; display: inline-flex; font-weight: 600; }
.water .round-main { background: var(--sky); color: #fff; }

/* ---------- Woche ---------- */
.mosaic { display: grid; grid-template-columns: 12px repeat(7, minmax(0, 1fr)); gap: 5px; align-items: center; }
.mz-day { font-size: 12px; font-weight: 600; text-align: center; padding: 4px 0; border-radius: 999px; color: var(--muted); }
.mz-day.is-today { color: var(--tomato); }
.mz-day.is-sel { background: var(--ink); color: var(--surface); }
.mz-slot i { display: block; width: 8px; height: 8px; border-radius: 50%; background: var(--tone); }
.mz-cell { display: block; aspect-ratio: 1; border-radius: 26%; transition: transform .2s; }
.mz-cell .emo { height: 100%; }
.mz-cell .emo-g { font-size: 58cqi; }
.mz-cell:hover { transform: scale(1.08); position: relative; z-index: 1; }
.mz-cell.is-sel .emo { box-shadow: 0 0 0 2px var(--ink); }
.mz-legend { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 12px; color: var(--muted); }
.mz-legend span { display: inline-flex; align-items: center; gap: 5px; }
.mz-legend i { width: 8px; height: 8px; border-radius: 50%; background: var(--tone); }

/* Tage als Kreise */
.daypicker { gap: 4px; }
.day { background: none; box-shadow: none; border-radius: 0; padding: 0; gap: 6px; font-weight: 600; font-size: 15px; }
.daypicker { grid-template-columns: repeat(7, minmax(0, 1fr)); }
.day > span {
  width: 100%; max-width: 42px; height: auto; aspect-ratio: 1; border-radius: 50%; display: grid; place-items: center;
  background: var(--surface); color: var(--ink); transition: background .2s, color .2s;
}
.day.is-today > span { color: var(--tomato); }
.day.is-active > span { background: var(--primary); color: #fff; }
.day.is-active.is-today > span { color: #fff; }
.day .dot { width: 5px; height: 5px; color: var(--primary); opacity: 1; }
.day .dot-off { opacity: .2; color: var(--muted); }
.day-list li { border-top: 0.5px solid var(--line); }
.dl-name:hover { color: var(--primary-text); }
.prep-when { color: var(--primary-text); }
.wb-col, .rb-col { background: var(--fill); border-radius: 8px; }
.wb-col span { background: var(--primary); opacity: .4; border-radius: 8px 8px 0 0; }
.wb.is-active .wb-col span { opacity: 1; }
.rb-col span { background: var(--orange); opacity: .5; }
.rb-col span.is-full { background: var(--spinach); opacity: 1; }
.review-stats p { background: var(--fill); border-radius: 14px; }
.review-stats b { font: 600 22px var(--rounded); }

/* ---------- Gewicht ---------- */
.weight { gap: 12px; }
.weight-form2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px; align-items: end; }
.weight-form2 .field { margin-top: 0; min-width: 0; }
.weight-form2 .btn { grid-column: 1 / -1; padding: 13px; }
@media (min-width: 520px) { .weight-form2 { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; } .weight-form2 .btn { grid-column: auto; } }
.input-unit { display: flex; align-items: center; gap: 0; padding-right: 12px; min-width: 0; }
.input-unit input { flex: 1; min-width: 0; border: 0; background: transparent; padding: 11px 12px; font: 600 17px var(--font); color: var(--ink); outline: none; }
.input-unit span { color: var(--muted); font-weight: 600; }
.weight-form2 input[type="date"] { width: 100%; min-width: 0; padding: 11px 10px; border-radius: 12px; color: var(--ink); font: 500 15px var(--font); min-height: 46px; }
.w-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.w-stats p, .w-stats p:nth-child(n) { display: flex; flex-direction: column; border-radius: 16px; padding: 10px 12px; min-width: 0; background: var(--fill); }
.w-stats span { font-size: 12px; font-weight: 600; color: var(--muted); }
.w-stats b { font: 600 21px var(--rounded); letter-spacing: -0.01em; }
.w-stats small { font-size: 11.5px; color: var(--muted); }
@media (max-width: 380px) { .w-stats b { font-size: 18px; } }
.w-empty { border: 1.5px dashed var(--line); border-radius: 16px; padding: 22px 16px; text-align: center; color: var(--muted); font-size: 14px; }
.wchart2 { margin: 0; }
.wchart2 svg { width: 100%; height: auto; display: block; overflow: visible; touch-action: manipulation; }
.wc-axis { stroke: var(--line); stroke-width: 1; }
.wc-tick { fill: var(--muted); font: 500 10px var(--font); }
.wc-grid { stroke: var(--line); stroke-dasharray: none; }
.wc-band { fill: var(--spinach); opacity: .14; }
.wc-today { stroke: var(--tomato); stroke-width: 1.2; stroke-dasharray: 3 4; }
.wc-today-t { fill: var(--tomato); }
.wc-fill-a { stop-color: var(--primary); stop-opacity: .22; }
.wc-fill-b { stop-color: var(--primary); stop-opacity: 0; }
.wc-line2 { stroke: var(--primary); stroke-width: 2.6; stroke-linejoin: round; stroke-linecap: round; }
.wc-trend { stroke: var(--muted); stroke-width: 1.5; stroke-dasharray: 4 4; fill: none; }
.wc-hit { fill: transparent; cursor: pointer; }
.wc-dot { fill: var(--surface); stroke: var(--primary); stroke-width: 2.2; }
.wc-last { fill: var(--primary); stroke: var(--surface); stroke-width: 2; }
.wc-pt { outline: none; }
.wc-tip { opacity: 0; pointer-events: none; transition: opacity .15s; }
.wc-tip rect { fill: var(--ink); }
.wc-tip-kg { fill: var(--bg); font: 600 13px var(--rounded); }
.wc-tip-d { fill: var(--saffron); font: 600 10.5px var(--font); }
.wc-tip-date { fill: var(--bg); opacity: .8; font: 500 10px var(--font); }
.wc-pt:hover .wc-tip, .wc-pt:focus .wc-tip, .wc-pt:focus-visible .wc-tip { opacity: 1; }
.wc-pt:hover .wc-dot, .wc-pt:focus .wc-dot { fill: var(--primary); }
.wchart2 figcaption { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 12.5px; color: var(--muted); margin-top: 6px; }
.wchart2 figcaption span { display: inline-flex; align-items: center; gap: 6px; }
.lg { display: inline-block; width: 16px; height: 9px; border-radius: 3px; margin: 0; }
.lg-band { background: color-mix(in srgb, var(--spinach) 28%, transparent); }
.lg-line { background: var(--primary); height: 3px; }
.lg-trend { height: 0; border-top: 2px dashed var(--muted); background: none; }
.weight h3 { margin: 6px 0 0; }
.weight-list li { grid-template-columns: 1fr auto 32px; gap: 8px; border-top: 0.5px solid var(--line); }
.w-kg { font-weight: 600; display: inline-flex; gap: 6px; align-items: baseline; }
.w-kg small { font-size: 12px; font-weight: 600; }
.w-kg small.up { color: var(--spinach-ink); }
.w-kg small.down { color: var(--tomato-ink); }

/* ---------- Rezepte ---------- */
.recipe-grid { gap: 10px; }
.recipe {
  display: grid; grid-template-columns: 56px minmax(0, 1fr); column-gap: 14px; row-gap: 3px; align-content: start;
  padding: 16px; transform: none; transition: none;
}
.recipe > * { grid-column: 2; }
.recipe-art { grid-column: 1; grid-row: 1 / span 3; width: 56px; height: 56px; margin: 0; display: block; }
.recipe-art::after { content: none; }
.recipe-name { font-size: 17px; font-weight: 600; letter-spacing: -0.02em; line-height: 1.25; }
.recipe .tags { margin-top: 4px; }
.recipe .used { margin-top: 6px; border-top: 0.5px solid var(--line); }
.recipe:hover { transform: none; }

/* ---------- Fenster (Sheets) aus Glas ---------- */
.sheet-backdrop { background: var(--dim); }
.sheet {
  left: 8px; right: 8px; bottom: 8px; max-height: calc(100% - env(safe-area-inset-top, 0px) - 28px);
  border-radius: 34px; background: color-mix(in srgb, var(--surface) 93%, transparent); -webkit-backdrop-filter: blur(40px) saturate(180%); backdrop-filter: blur(40px) saturate(180%);
  box-shadow: var(--glass-hl), var(--glass-shadow);
  padding: 8px max(20px, env(safe-area-inset-right, 0px)) calc(24px + env(safe-area-inset-bottom, 0px)) max(20px, env(safe-area-inset-left, 0px));
  animation: sheetUp .38s cubic-bezier(.2, .9, .25, 1);
}
@keyframes sheetUp { from { transform: translateY(40px); opacity: 0; } }
@media (min-width: 720px) {
  .sheet { left: 50%; right: auto; top: 50%; bottom: auto; width: 560px; transform: translate(-50%, -50%); border-radius: 34px; padding: 24px 28px 28px; animation: fade .2s ease; }
}
.sheet-grip { width: 36px; height: 5px; border-radius: 3px; background: color-mix(in srgb, var(--muted) 45%, transparent); margin: 0 auto 12px; position: static; transform: none; }
.sheet:has(.sheet-art) .sheet-grip { position: static; transform: none; margin: 0 auto 12px; background: color-mix(in srgb, var(--muted) 45%, transparent); }
.sheet-close, .cook-head .x-btn {
  width: 34px; height: 34px; border-radius: 50%; background: var(--fill); color: var(--muted); box-shadow: none;
}
.sheet-close { top: 14px; right: 14px; }
.sheet h2 { font-size: 28px; font-weight: 700; letter-spacing: -0.02em; margin: 2px 44px 10px 0; }
.sheet-art { display: block; width: 76px; height: auto; margin: 4px 0 12px; }
.sheet .card, .sheet .note-inline { background: var(--fill); box-shadow: none; }
.ing li, .prep li, .day-list li, .dinner-overview li, .order-list li, .cook-ing li, .set-row, .weight-list li, .shop-list li + li { border-color: var(--line); border-top-width: 0.5px; }
.ing li::before { background: var(--primary); border-radius: 50%; transform: none; width: 6px; height: 6px; }
.steps li::before { background: var(--fill); color: var(--ink); font-weight: 600; }
.pills .pill:last-child:not(.pill-protein) { background: var(--fill); color: var(--ink); }

/* ---------- Einkauf ---------- */
.costs { background: var(--surface); }
.cost-big { font: 700 34px var(--rounded); color: var(--ink); letter-spacing: -0.01em; }
.area-name { display: inline-flex; align-items: center; gap: 8px; }
.area-name::after { content: none !important; }
.area-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--tone); transform: none; }
.shop-group h2 { font-size: 20px; }
.shop-group .shop-list { box-shadow: var(--shadow); border-radius: var(--radius); }
.box { width: 24px; height: 24px; border-radius: 50%; box-shadow: inset 0 0 0 1.8px color-mix(in srgb, var(--muted) 50%, transparent); }
.shop-group .box { box-shadow: inset 0 0 0 1.8px color-mix(in srgb, var(--muted) 50%, transparent); }
.is-done .box, .shop-group .is-done .box { background: var(--tone, var(--primary)); color: #fff; box-shadow: none; }
.shop-group .is-done .si-name { background: none; color: var(--muted); text-decoration: none; }
.people-card, .add-extra { background: var(--surface); }
.home-btn:hover { color: var(--primary-text); }

/* ---------- Mehr & Tipps ---------- */
.tip { padding-left: 18px; overflow: visible; }
.tip::before { content: none; }
.tip h2 { font-size: 17px; }
.tip-key { background: var(--surface); box-shadow: inset 0 0 0 1.5px var(--primary); }
.tip-key h2 { color: var(--primary-text); }
.day-t { background: var(--fill); color: var(--ink); font-weight: 600; border-radius: 999px; text-align: center; }
.day-t.is-on { background: var(--primary); color: #fff; }
.confirm-box { background: var(--tomato-soft); }

/* ---------- Koch-Modus ---------- */
.cook { background: var(--bg); }
.cook > .cook-art { width: 64px; height: 64px; max-width: none; margin: 4px 0 6px; }
.cook-head { margin-top: 0; }
.cook-title { background: none; box-shadow: none; transform: none; padding: 0; }
.cook-title h2 { font-size: 20px; font-weight: 700; }
.cook-num { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--primary); color: #fff; font: 600 15px var(--rounded); margin-right: 8px; vertical-align: middle; }
.cook-text { font-size: 26px; font-weight: 600; letter-spacing: -0.02em; }
.cook-progress span { background: var(--fill); height: 4px; }
.cook-progress .is-done { background: color-mix(in srgb, var(--primary) 45%, transparent); }
.cook-progress .is-on { background: var(--primary); }
.timer { gap: 16px; background: var(--surface); }
.timer-dial { position: relative; width: 128px; height: 128px; flex: none; }
.timer-dial svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.dial-track { fill: none; stroke: var(--fill); stroke-width: 10; }
.dial-bar { fill: none; stroke: var(--orange); stroke-width: 10; stroke-linecap: round; transition: stroke-dashoffset .5s linear; }
.timer.is-running .dial-bar { stroke: var(--spinach); }
.timer-dial .timer-time { position: absolute; inset: 0; display: grid; place-items: center; font: 600 28px var(--rounded); }
.timer .round-main { background: var(--spinach); }
.timer-chip, .toast {
  background: var(--glass-strong); color: var(--ink); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
  box-shadow: var(--glass-hl), var(--glass-shadow); border-radius: 999px; font-weight: 600;
}
.timer-chip { bottom: calc(var(--tabs-h) + env(safe-area-inset-bottom, 0px) + 26px); }
.timer-chip.is-done { background: var(--orange); color: #fff; }
.toast { bottom: calc(var(--tabs-h) + env(safe-area-inset-bottom, 0px) + 28px); padding: 11px 18px; text-align: center; }
.cook-body { padding-bottom: 28px; }

/* ---------- Tab-Leiste aus Glas ---------- */
.tabs {
  left: max(14px, env(safe-area-inset-left, 0px)); right: max(14px, env(safe-area-inset-right, 0px));
  bottom: calc(8px + env(safe-area-inset-bottom, 0px)); max-width: 540px; margin: 0 auto;
  border: 0; border-radius: 999px; padding: 4px;
  background: var(--glass); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
  box-shadow: var(--glass-hl), var(--glass-shadow);
}
.tab { border-radius: 999px; padding: 6px 0 5px; gap: 1px; color: var(--ink); font-size: 10px; font-weight: 600; letter-spacing: 0; transition: background .25s, color .25s; }
.tab .tab-ic { display: grid; place-items: center; width: auto; height: 26px; border-radius: 0; background: none; animation: none; }
.tab .ic { width: 24px; height: 24px; stroke-width: 1.9; }
.tab.is-active { color: var(--tone); background: var(--fill); }
.tab.is-active .tab-ic { background: none; border-radius: 0; animation: none; }
.tab.is-active .ic { stroke-width: 2.2; }

/* ---------- Seitenwechsel: ruhig und kurz ---------- */
/* nur die ersten Karten gleiten herein – der Rest ist eh außerhalb des Bildschirms */
.page.enter > :nth-child(-n+4) { animation: settle .35s cubic-bezier(.2, .8, .2, 1) both; }
.page.enter > *:nth-child(2) { animation-delay: .03s; }
.page.enter > *:nth-child(3) { animation-delay: .06s; }
.page.enter > *:nth-child(4) { animation-delay: .09s; }
@keyframes settle { from { opacity: 0; transform: translateY(8px); } }
@keyframes rise { from { opacity: 0; transform: translateY(6px); } }

/* ---------- Gesundheit, Sprache, Präparate ---------- */
.score-track { stroke: var(--fill); }
.score-bar { stroke: var(--spinach); }
.score span b { font: 600 20px var(--rounded); }
.health-all summary { color: var(--primary-text); font-weight: 600; }
.health-facts p, .sport-daily { background: var(--fill); }
.health-facts b { font: 600 17px var(--rounded); }
.supp-row { border-top-width: 0.5px; }

.lang-tile {
  align-items: center; text-align: center; padding: 14px 8px 12px; gap: 2px; border-radius: 20px;
  background: var(--fill); box-shadow: none; overflow: visible;
}
.lang-art { width: 48px; height: 48px; margin-bottom: 6px; }
.lang-art .emo { height: 100%; border-radius: 50%; }
.lang-art .emo-g { font-size: 64cqi; }
.lang-code { margin: 0; padding: 0; background: none; box-shadow: none; border-radius: 0; color: var(--muted); font: 600 12px var(--font); letter-spacing: .04em; }
.lang-name { margin: 0; font-weight: 600; font-size: 15px; }
.lang-hello { margin: 2px 0 0; font-style: normal; }
.lang-check { top: 8px; right: 8px; width: 22px; height: 22px; transform: scale(0); box-shadow: none; background: var(--primary); }
.lang-check .ic-tick { width: 13px; height: 13px; }
.lang-tile.is-on { background: var(--surface); box-shadow: inset 0 0 0 2px var(--primary); }
.lang-tile.is-on .lang-code { background: none; color: var(--primary-text); }
.lang-tile.is-on .lang-check { transform: scale(1); }
.lang-tile:hover { transform: none; }
.lang-tile:not(.is-on) .lang-art .emo { filter: saturate(.8); }

/* ---------- Sport ---------- */
.sw-days { gap: 2px; }
.sw-day { background: none; padding: 2px 0 4px; gap: 5px; border-radius: 14px; }
.sw-day:hover { transform: none; }
.sw-day.is-today { box-shadow: none; background: var(--fill); }
.sw-d { font-size: 12px; font-weight: 600; color: var(--muted); }
.sw-day.is-today .sw-d { color: var(--tomato); }
.sw-art { width: 100%; max-width: 44px; aspect-ratio: 1; }
.sw-art .emo { border-radius: 50%; }
.sw-art .emo-g { font-size: 52cqi; }
.sw-day.is-done .sw-art .emo { box-shadow: 0 0 0 2.5px var(--tone); }
.sw-check {
  inset: auto -3px -3px auto; width: 18px; height: 18px; border-radius: 50%; background: var(--tone); color: #fff;
  box-shadow: 0 0 0 2px var(--surface);
}
.sw-check .ic-tick { width: 11px; height: 11px; }
.sw-t { font-size: 10.5px; font-weight: 600; color: var(--muted); }
.sw-day.is-today .sw-t { color: var(--ink); }

.st2 { grid-template-columns: 76px minmax(0, 1fr); }
.st2-art { width: 76px; height: 76px; }
.st2-art .emo { border-radius: 24%; }
.st2-art:hover .emo { transform: none; }
.st2-body h2 { font-size: 22px; font-weight: 700; letter-spacing: -0.02em; }
.st2-btns .btn:first-child:not(.btn-ghost), .st-btns .btn:first-child { background: var(--tone); }
.st-done[aria-pressed="true"] { background: var(--spinach-soft); color: var(--spinach-ink); }
.st2.is-done .st2-art .emo, .sport-mini.is-done .sm-art .emo { opacity: .5; }
@media (max-width: 380px) { .st2 { grid-template-columns: 64px minmax(0, 1fr); } .st2-art { width: 64px; height: 64px; } }

.sm-art { width: 56px; height: 56px; }
.sport-mini { grid-template-columns: 56px minmax(0, 1fr) auto; padding: 14px; }
.sm-go { background: var(--tone); }
.sm-done { background: var(--spinach); }

.club-chip { background: var(--fill); color: var(--muted); padding: 4px 12px 4px 4px; }
.club-chip:hover { box-shadow: none; }
.cc-art { width: 32px; height: 32px; }
.cc-art .emo { border-radius: 50%; }
.cc-text small { letter-spacing: 0; font-weight: 600; }

.sport-seg { top: calc(env(safe-area-inset-top, 0px) + 56px); background: var(--glass); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur); box-shadow: var(--glass-hl), var(--glass-shadow); }

.sport-list { padding: 6px; }
.sl-row + .sl-row { border-top: 0.5px solid var(--line); }
.sl-row:hover { background: var(--fill); }
.sl-art { width: 48px; height: 48px; }
.sl-row { grid-template-columns: 48px minmax(0, 1fr) auto 18px; }
.sl-count { font: 600 13px var(--rounded); background: var(--tone-soft); color: var(--tone-ink); }
.sl-count.is-zero { background: var(--fill); }

.sf-badge, .sport-fact:nth-child(even) .sf-badge, .sf2 .sf-badge, .sf2:nth-child(even) .sf-badge {
  transform: none; border-radius: 16px; box-shadow: none; background: var(--tone-soft); color: var(--tone-ink);
}
.sf-badge b, .sf2 .sf-badge b { font: 700 20px/1 var(--rounded); letter-spacing: -0.01em; }
.sf-badge span { font-weight: 600; opacity: 1; }
.sf2-title { font: 600 16px/1.3 var(--font); letter-spacing: -0.01em; }
.sport-sources a { color: var(--primary-text); }

.pd-opt { background: var(--fill); }
.pd-opt.is-on, .club-opt.is-on { background: var(--surface); box-shadow: inset 0 0 0 2px var(--tone); }
.pd-art { width: 48px; height: 48px; }
.pd-opt { grid-template-columns: 48px minmax(0, 1fr) 28px; }
.club-opt { background: var(--fill); border-radius: 18px; }
.co-art { width: 52px; height: 52px; }
.co-art .emo { border-radius: 50%; }
.co-name { font-weight: 600; }

.ex-list li { border-top: 0.5px solid var(--line); }
.ex-list li::before, .ex-list li:nth-child(n)::before { border-radius: 50%; background: var(--fill); color: var(--ink); font: 600 14px var(--rounded); }
.ex-reps { background: var(--fill); font-weight: 600; }
.wo-reps { font: 600 20px var(--rounded); }
.wo-sets i { background: var(--fill); }
.wo-set { background: var(--tone); }
.btn-glow { animation: none; }

/* ---------- Profil ---------- */
.pf-avatar {
  width: 48px; height: 48px; border-radius: 50%; background: linear-gradient(180deg, #a8a8ae, #85858b); color: #fff;
  font: 600 21px var(--rounded); box-shadow: inset 0 1px 0 rgb(255 255 255 / 35%);
}
.pf-art { display: flex; justify-content: center; margin: 6px 0 10px; }
.pf-art .pf-avatar { position: static; width: 84px; height: 84px; font-size: 36px; box-shadow: inset 0 1px 0 rgb(255 255 255 / 35%); }
.pf-art .pf-avatar .ic-sm { width: 34px; height: 34px; }
.sheet:has(.pf-art) .meal-slot, .sheet:has(.pf-art) h2 { text-align: center; margin-right: 0; }
.sheet:has(.pf-art) h2 + p { text-align: center; }
.pf-opt > span { background: var(--fill); border-radius: 14px; }
.pf-opt input:checked + span { background: var(--surface); box-shadow: inset 0 0 0 2px var(--primary); color: var(--ink); }
.pf-opt input:checked + span small { color: var(--muted); opacity: 1; }
.pf-opt input:focus-visible + span { outline-color: var(--primary); }
.pf-preview { background: var(--fill); border-radius: 20px; }
.pf-preview .hint { color: var(--muted); opacity: 1; }
.pf-stats p { background: var(--surface); border-radius: 14px; }
.pf-card .pf-stats p { background: var(--fill); }
.pf-stats b { font: 600 17px var(--rounded); }
.pf-form .btn-wide, .pf-empty .btn { background: var(--primary); }
.pf-goal { color: var(--primary-text); font-weight: 600; }
.pf-empty { background: var(--surface); }
.pf-form #pf-name, .pf-form #pf-year { font-weight: 600; }
.pf-form #pf-name:focus, .pf-form #pf-year:focus { box-shadow: 0 0 0 2px var(--primary); }

/* ---------- Schlaf ---------- */
.sl-card { background: var(--surface); }
.sl-moon { background: var(--indigo); color: #fff; box-shadow: none; }
.en-btn { background: var(--fill); font-weight: 600; }
.en-btn.is-on { background: var(--surface); box-shadow: inset 0 0 0 2px var(--tone); }
.en-btn.is-on .en-dot { transform: scale(1.12); }
.sc-band { fill: var(--sky); opacity: .14; }
.sc-grid { stroke-dasharray: none; }
.lg-dot { background: conic-gradient(var(--tomato), var(--orange), var(--spinach), var(--sky), var(--tomato)); }
.tips-mini li::before, .tips-mini li:nth-child(n)::before { width: 7px; height: 7px; top: .55em; left: 4px; border-radius: 50%; transform: none; background: var(--primary); }

/* ---------- Körper ---------- */
.body-tile { box-shadow: var(--shadow); padding: 14px; border-radius: 22px; }
.body-tile::after { content: none; }
.bt-ic { background: var(--tone); color: #fff; width: 28px; height: 28px; }
.bt-ic .ic-sm { width: 15px; height: 15px; }
.bt-t { color: var(--tone-ink); font-weight: 600; font-size: 14px; }
.bt-v { font: 600 24px var(--rounded); letter-spacing: -0.01em; }
.body-tile.is-on { background: var(--surface); box-shadow: inset 0 0 0 2px var(--tone); }
.body-tile.is-on .bt-ic { background: var(--tone); }
.body-tile.is-on .bt-t { color: var(--tone-ink); }
.body-tile.is-on .bt-v { color: var(--ink); }

/* ---------- Blutwerte ---------- */
.lab-row { background: var(--fill); box-shadow: none; padding: 10px 12px; }
.lab-name b::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--tone); margin-right: 7px; vertical-align: 1px; }
.lab-val b { font: 600 19px var(--rounded); }
.lab-empty { background: var(--fill); }
.lab-range { background: var(--spinach-soft); color: var(--spinach-ink); }
.lab-band { fill: var(--spinach); opacity: .14; }
.lab-in { border-top-width: 0.5px; }
.lab-in label::before { border-radius: 50%; transform: none; width: 8px; height: 8px; }
.unit-sw { background: var(--fill); color: var(--primary-text); }

/* ---------- Erinnerungen ---------- */
.reminders h2 .ic-sm { color: var(--primary-text); }
.rem-row { border-top-width: 0.5px; }
.rem-row .switch input:checked + .switch-track { background: #34c759; }
.rem-time input[type="time"], .rem-time select { border: 0; background: var(--fill); color: var(--ink); font-weight: 600; }
.rem-ways .btn:not(.btn-ghost) { background: var(--primary); color: #fff; }

/* Bewegung reduzieren */
@media (prefers-reduced-motion: reduce) {
  .topbar, .meal.pop .tick, .page.enter .rg-bar { transition: none !important; animation: none !important; }
}

.en-btn > span:last-child { overflow-wrap: normal; word-break: normal; -webkit-hyphens: auto; hyphens: auto; }
.dl-name { text-align: left; }
a.chip { text-decoration: none; }

/* =====================================================================
   Liquid Glass (iOS 26): farbiges, weiches Licht im Hintergrund,
   Karten und Knöpfe aus Glas mit leuchtender Kante.
   ===================================================================== */
:root {
  --bg: #eceef5;
  --cg: rgb(255 255 255 / 50%);
  --cg-strong: rgb(255 255 255 / 68%);
  --fill: rgb(255 255 255 / 45%);
  --rim: linear-gradient(150deg, rgb(255 255 255 / 100%), rgb(255 255 255 / 35%) 30%, rgb(255 255 255 / 10%) 60%, rgb(255 255 255 / 75%));
  --card-shadow: 0 10px 34px rgb(30 40 80 / 10%), 0 1px 2px rgb(30 40 80 / 6%), inset 0 1px 1px rgb(255 255 255 / 70%);
  --blob: 55%;
  --line: rgb(60 60 67 / 14%);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #050508; --cg: rgb(58 58 64 / 38%); --cg-strong: rgb(48 48 54 / 62%); --fill: rgb(255 255 255 / 9%);
    --rim: linear-gradient(150deg, rgb(255 255 255 / 40%), rgb(255 255 255 / 8%) 30%, rgb(255 255 255 / 3%) 60%, rgb(255 255 255 / 22%));
    --card-shadow: 0 10px 34px rgb(0 0 0 / 45%), inset 0 1px 1px rgb(255 255 255 / 10%);
    --blob: 38%; --line: rgb(255 255 255 / 10%);
  }
}
:root[data-theme="dark"] {
  --bg: #050508; --cg: rgb(58 58 64 / 38%); --cg-strong: rgb(48 48 54 / 62%); --fill: rgb(255 255 255 / 9%);
  --rim: linear-gradient(150deg, rgb(255 255 255 / 40%), rgb(255 255 255 / 8%) 30%, rgb(255 255 255 / 3%) 60%, rgb(255 255 255 / 22%));
  --card-shadow: 0 10px 34px rgb(0 0 0 / 45%), inset 0 1px 1px rgb(255 255 255 / 10%);
  --blob: 38%; --line: rgb(255 255 255 / 10%);
}

/* Licht im Hintergrund: in der Farbe des Bereichs, zieht ganz langsam */
body::before {
  content: ""; position: fixed; inset: -15%; z-index: -1; pointer-events: none;
  background:
    radial-gradient(38% 30% at 12% 8%, color-mix(in srgb, var(--primary) var(--blob), transparent), transparent 70%),
    radial-gradient(42% 34% at 92% 26%, color-mix(in srgb, var(--sky) calc(var(--blob) - 10%), transparent), transparent 70%),
    radial-gradient(46% 38% at 22% 62%, color-mix(in srgb, var(--plum) calc(var(--blob) - 22%), transparent), transparent 70%),
    radial-gradient(44% 36% at 88% 88%, color-mix(in srgb, var(--primary) calc(var(--blob) - 12%), transparent), transparent 70%),
    radial-gradient(36% 30% at 40% 100%, color-mix(in srgb, var(--spinach) calc(var(--blob) - 25%), transparent), transparent 70%);
  animation: glassLight 40s ease-in-out infinite alternate;
  transition: background .6s;
}
@keyframes glassLight { 0% { transform: translate(0, 0) scale(1); } 50% { transform: translate(3%, 2%) scale(1.06); } 100% { transform: translate(-2%, 4%) scale(.98); } }

/* Glas-Flächen */
.card, .meal, .body-tile, .search, .sw-day.is-today, .club-opt, .pd-opt, .lang-tile, .lab-row, .en-btn, .pf-opt > span,
.w-stats p, .w-stats p:nth-child(n), .review-stats p, .health-facts p, .sport-daily, .pf-preview, .lab-empty, .note-inline {
  background: linear-gradient(var(--cg), var(--cg)) padding-box, var(--rim) border-box;
  border: 1px solid transparent;
  -webkit-backdrop-filter: blur(24px) saturate(180%); backdrop-filter: blur(24px) saturate(180%);
}
.card, .meal, .body-tile { box-shadow: var(--card-shadow); }
/* Glas in Glas: innere Flächen etwas heller, ohne zweiten Weichzeichner */
.card .w-stats p, .card .review-stats p, .card .health-facts p, .card .sport-daily, .card .lab-row, .card .en-btn, .card .lang-tile, .card .pf-preview, .card .lab-empty,
.card .note-inline, .sheet .note-inline, .sheet .card, .sheet .pd-opt, .sheet .club-opt, .sheet .pf-opt > span, .sheet .pf-preview, .sheet .lab-empty {
  -webkit-backdrop-filter: none; backdrop-filter: none;
  background: linear-gradient(var(--fill), var(--fill)) padding-box, var(--rim) border-box;
}
/* Ausgewählt: klares, helleres Glas mit Farbkante */
.body-tile.is-on, .lang-tile.is-on, .en-btn.is-on, .pd-opt.is-on, .club-opt.is-on, .pf-opt input:checked + span, .card .lang-tile.is-on, .card .en-btn.is-on, .sheet .pd-opt.is-on, .sheet .club-opt.is-on, .sheet .pf-opt input:checked + span {
  background: linear-gradient(var(--cg-strong), var(--cg-strong)) padding-box, linear-gradient(150deg, var(--tone, var(--primary)), color-mix(in srgb, var(--tone, var(--primary)) 40%, transparent)) border-box;
  border: 2px solid transparent; box-shadow: 0 6px 20px color-mix(in srgb, var(--tone, var(--primary)) 25%, transparent);
}
.pf-opt input:checked + span, .sheet .pf-opt input:checked + span, .lang-tile.is-on, .card .lang-tile.is-on {
  background: linear-gradient(var(--cg-strong), var(--cg-strong)) padding-box, linear-gradient(150deg, var(--primary), color-mix(in srgb, var(--primary) 40%, transparent)) border-box;
}
.s-ok-box { background: linear-gradient(var(--spinach-soft), var(--spinach-soft)) padding-box, var(--rim) border-box; border: 1px solid transparent; }
.s-mid-box { background: linear-gradient(var(--orange-soft), var(--orange-soft)) padding-box, var(--rim) border-box; border: 1px solid transparent; }
.s-low-box { background: linear-gradient(var(--tomato-soft), var(--tomato-soft)) padding-box, var(--rim) border-box; border: 1px solid transparent; }

/* Knöpfe als Glas-Kapseln */
.chip, .btn-ghost, .round-btn, .x-btn.sheet-close, .sheet-close, .cook-head .x-btn, .club-chip, .unit-sw, .day > span, .day-t, .mz-day {
  background: linear-gradient(var(--cg-strong), var(--cg-strong)) padding-box, var(--rim) border-box;
  border: 1px solid transparent;
  -webkit-backdrop-filter: blur(16px) saturate(180%); backdrop-filter: blur(16px) saturate(180%);
  box-shadow: 0 4px 14px rgb(30 40 80 / 8%), inset 0 1px 1px rgb(255 255 255 / 60%);
}
.card .round-btn, .card .btn-ghost, .card .day-t, .sheet .round-btn, .sheet .btn-ghost, .card .chip, .sheet .chip, .card .unit-sw, .sheet .unit-sw { -webkit-backdrop-filter: none; backdrop-filter: none; }
.round-btn:disabled { opacity: .45; }
/* Gefüllte Knöpfe: farbiges Glas mit Glanz oben */
.btn:not(.btn-ghost), .chip-on, .chips .chip-on, .week-chips .chip-on, .round-main, .day.is-active > span, .day-t.is-on, .mz-day.is-sel, .sm-go, .water .round-main {
  background: linear-gradient(180deg, rgb(255 255 255 / 30%), rgb(255 255 255 / 0%) 55%), var(--tone-fill, var(--primary));
  border: 1px solid rgb(255 255 255 / 30%); color: #fff;
  box-shadow: 0 6px 18px color-mix(in srgb, var(--tone-fill, var(--primary)) 35%, transparent), inset 0 1px 1px rgb(255 255 255 / 55%), inset 0 -1px 2px rgb(0 0 0 / 10%);
}
.water .round-main { --tone-fill: var(--sky); }
.sm-go, .st2-btns .btn:first-child:not(.btn-ghost), .wo-set { --tone-fill: var(--tone); }
.st2-btns .btn:first-child:not(.btn-ghost), .wo-set {
  background: linear-gradient(180deg, rgb(255 255 255 / 30%), rgb(255 255 255 / 0%) 55%), var(--tone);
}
.timer .round-main { --tone-fill: var(--spinach); }
.mz-day.is-sel { --tone-fill: var(--ink); color: var(--surface); }
.st-done[aria-pressed="true"] { background: linear-gradient(var(--spinach-soft), var(--spinach-soft)) padding-box, var(--rim) border-box; }

/* Segmente: Glas-Schiene mit Glas-Linse */
.seg, .sport-seg {
  background: linear-gradient(var(--cg), var(--cg)) padding-box, var(--rim) border-box; border: 1px solid transparent;
  -webkit-backdrop-filter: blur(24px) saturate(180%); backdrop-filter: blur(24px) saturate(180%);
  box-shadow: var(--card-shadow);
}
.seg button.is-on {
  background: linear-gradient(180deg, rgb(255 255 255 / 95%), rgb(255 255 255 / 70%)); color: #000;
  box-shadow: 0 4px 12px rgb(0 0 0 / 12%), inset 0 1px 1px #fff, inset 0 -1px 2px rgb(0 0 0 / 6%);
}
:root[data-theme="dark"] .seg button.is-on { background: linear-gradient(180deg, rgb(255 255 255 / 28%), rgb(255 255 255 / 14%)); color: #fff; box-shadow: inset 0 1px 1px rgb(255 255 255 / 30%), 0 4px 12px rgb(0 0 0 / 30%); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .seg button.is-on { background: linear-gradient(180deg, rgb(255 255 255 / 28%), rgb(255 255 255 / 14%)); color: #fff; box-shadow: inset 0 1px 1px rgb(255 255 255 / 30%), 0 4px 12px rgb(0 0 0 / 30%); } }

/* Tab-Leiste: dickeres Glas, aktive Linse */
.tabs {
  background: linear-gradient(rgb(255 255 255 / 38%), rgb(255 255 255 / 38%)) padding-box, var(--rim) border-box;
  border: 1px solid transparent;
  -webkit-backdrop-filter: blur(28px) saturate(200%) brightness(1.05); backdrop-filter: blur(28px) saturate(200%) brightness(1.05);
  box-shadow: 0 14px 40px rgb(20 30 70 / 18%), inset 0 1px 1px rgb(255 255 255 / 80%), inset 0 -1px 1px rgb(255 255 255 / 30%);
}
.tab.is-active {
  background: linear-gradient(180deg, rgb(255 255 255 / 75%), rgb(255 255 255 / 40%));
  box-shadow: 0 3px 10px rgb(0 0 0 / 10%), inset 0 1px 1px #fff, inset 0 -1px 2px rgb(0 0 0 / 5%);
}
:root[data-theme="dark"] .tabs { background: linear-gradient(rgb(40 40 46 / 45%), rgb(40 40 46 / 45%)) padding-box, var(--rim) border-box; box-shadow: 0 14px 40px rgb(0 0 0 / 55%), inset 0 1px 1px rgb(255 255 255 / 18%); }
:root[data-theme="dark"] .tab.is-active { background: linear-gradient(180deg, rgb(255 255 255 / 20%), rgb(255 255 255 / 8%)); box-shadow: inset 0 1px 1px rgb(255 255 255 / 25%); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .tabs { background: linear-gradient(rgb(40 40 46 / 45%), rgb(40 40 46 / 45%)) padding-box, var(--rim) border-box; box-shadow: 0 14px 40px rgb(0 0 0 / 55%), inset 0 1px 1px rgb(255 255 255 / 18%); }
  :root:not([data-theme="light"]) .tab.is-active { background: linear-gradient(180deg, rgb(255 255 255 / 20%), rgb(255 255 255 / 8%)); box-shadow: inset 0 1px 1px rgb(255 255 255 / 25%); }
}

/* Titelleiste und Fenster: durchsichtiger, mit Kante */
.topbar {
  background: linear-gradient(180deg, color-mix(in srgb, var(--bg) 70%, transparent), color-mix(in srgb, var(--bg) 35%, transparent));
  -webkit-backdrop-filter: blur(24px) saturate(180%); backdrop-filter: blur(24px) saturate(180%);
  box-shadow: none;
}
.sheet {
  background: linear-gradient(var(--cg-strong), var(--cg-strong)) padding-box, var(--rim) border-box; border: 1px solid transparent;
  -webkit-backdrop-filter: blur(50px) saturate(200%); backdrop-filter: blur(50px) saturate(200%);
  box-shadow: 0 20px 60px rgb(0 0 0 / 25%), inset 0 1px 1px rgb(255 255 255 / 60%);
}
.sheet-backdrop { background: rgb(0 0 0 / 18%); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
.toast, .timer-chip {
  background: linear-gradient(var(--cg-strong), var(--cg-strong)) padding-box, var(--rim) border-box; border: 1px solid transparent;
  -webkit-backdrop-filter: blur(30px) saturate(200%); backdrop-filter: blur(30px) saturate(200%);
}
.cook { background: transparent; -webkit-backdrop-filter: blur(60px) saturate(180%); backdrop-filter: blur(60px) saturate(180%); }
.cook::before { content: ""; position: absolute; inset: 0; z-index: -1; background: color-mix(in srgb, var(--bg) 55%, transparent); }

/* Emoji-Kacheln: Glas mit Lichtkante */
.emo {
  background: linear-gradient(160deg, color-mix(in srgb, var(--tone) 34%, rgb(255 255 255 / 55%)), color-mix(in srgb, var(--tone) 14%, rgb(255 255 255 / 25%))) padding-box, var(--rim) border-box;
  border: 1px solid transparent;
  box-shadow: 0 6px 16px color-mix(in srgb, var(--tone) 22%, transparent), inset 0 1px 1px rgb(255 255 255 / 70%);
}
.me-av, .pf-avatar {
  background: linear-gradient(180deg, rgb(255 255 255 / 35%), rgb(255 255 255 / 0%) 60%), var(--primary);
  border: 1px solid rgb(255 255 255 / 45%);
  box-shadow: 0 4px 14px color-mix(in srgb, var(--primary) 35%, transparent), inset 0 1px 1px rgb(255 255 255 / 60%);
}

/* Felder: leicht vertieftes Glas */
select, input[type="number"], .recipe-form input[type="text"], .recipe-form textarea, .ing-row input, .ing-row select,
.extra-grid input, .share-text, .set-inline input, .set-one, .input-unit, .weight-form2 input[type="date"], .lab-form #lab-date, .pf-form #pf-name, .rem-time input[type="time"], .rem-time select {
  background: rgb(255 255 255 / 40%); box-shadow: inset 0 1px 3px rgb(0 0 0 / 8%), inset 0 0 0 1px rgb(255 255 255 / 50%);
}
:root[data-theme="dark"] :is(select, input[type="number"], .input-unit, .set-one, .extra-grid input, .share-text, .pf-form #pf-name, .lab-form #lab-date, .weight-form2 input[type="date"], .rem-time input[type="time"], .rem-time select, .recipe-form input[type="text"], .recipe-form textarea, .ing-row input, .ing-row select) { background: rgb(0 0 0 / 25%); box-shadow: inset 0 1px 3px rgb(0 0 0 / 30%), inset 0 0 0 1px rgb(255 255 255 / 8%); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) :is(select, input[type="number"], .input-unit, .set-one, .extra-grid input, .share-text, .pf-form #pf-name, .lab-form #lab-date, .weight-form2 input[type="date"], .rem-time input[type="time"], .rem-time select, .recipe-form input[type="text"], .recipe-form textarea, .ing-row input, .ing-row select) { background: rgb(0 0 0 / 25%); box-shadow: inset 0 1px 3px rgb(0 0 0 / 30%), inset 0 0 0 1px rgb(255 255 255 / 8%); } }
.input-unit input, .search input { background: transparent; box-shadow: none; }
.input-unit:focus-within, .search:focus-within { box-shadow: 0 0 0 2px var(--primary); }

/* Ringe leuchten leicht */
.rg-bar { filter: drop-shadow(0 0 4px color-mix(in srgb, currentColor 0%, transparent)); }
.rg-bar.rg-kcal { filter: drop-shadow(0 0 5px rgb(250 17 79 / 45%)); }
.rg-bar.rg-prot { filter: drop-shadow(0 0 5px color-mix(in srgb, var(--ring-prot) 50%, transparent)); }
.rg-bar.rg-water { filter: drop-shadow(0 0 5px color-mix(in srgb, var(--ring-water) 50%, transparent)); }

@media (prefers-reduced-motion: reduce) { body::before { animation: none; } }
@media (prefers-reduced-transparency: reduce) {
  :root { --cg: rgb(255 255 255 / 94%); --cg-strong: #fff; }
  :root[data-theme="dark"] { --cg: rgb(28 28 30 / 96%); --cg-strong: #2c2c2e; }
}

/* Klareres Glas: weniger milchiges Weiß, etwas mehr Farbe im Hintergrund */
:root {
  --cg: rgb(255 255 255 / 24%);
  --cg-strong: rgb(255 255 255 / 36%);
  --fill: rgb(255 255 255 / 22%);
  --blob: 68%;
  --bg: #e6e8f2;
  --card-shadow: 0 10px 34px rgb(30 40 80 / 10%), 0 1px 2px rgb(30 40 80 / 5%), inset 0 1px 1px rgb(255 255 255 / 55%);
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --cg: rgb(70 70 78 / 26%); --cg-strong: rgb(80 80 90 / 34%); --fill: rgb(255 255 255 / 7%); --blob: 46%; } }
:root[data-theme="dark"] { --cg: rgb(70 70 78 / 26%); --cg-strong: rgb(80 80 90 / 34%); --fill: rgb(255 255 255 / 7%); --blob: 46%; }
.card, .meal, .body-tile, .seg, .sport-seg { -webkit-backdrop-filter: blur(30px) saturate(200%); backdrop-filter: blur(30px) saturate(200%); }
.seg button.is-on, .tab.is-active { background: linear-gradient(180deg, rgb(255 255 255 / 55%), rgb(255 255 255 / 22%)); }
.tabs { background: linear-gradient(rgb(255 255 255 / 20%), rgb(255 255 255 / 20%)) padding-box, var(--rim) border-box; }
.sheet { background: linear-gradient(rgb(255 255 255 / 52%), rgb(255 255 255 / 52%)) padding-box, var(--rim) border-box; }
:root[data-theme="dark"] .sheet { background: linear-gradient(rgb(40 40 46 / 60%), rgb(40 40 46 / 60%)) padding-box, var(--rim) border-box; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .sheet { background: linear-gradient(rgb(40 40 46 / 60%), rgb(40 40 46 / 60%)) padding-box, var(--rim) border-box; } }
.emo { background: linear-gradient(160deg, color-mix(in srgb, var(--tone) 40%, transparent), color-mix(in srgb, var(--tone) 16%, transparent)) padding-box, var(--rim) border-box; }
select, input[type="number"], .input-unit, .set-one, .extra-grid input, .share-text, .pf-form #pf-name, .lab-form #lab-date, .weight-form2 input[type="date"], .rem-time input[type="time"], .rem-time select, .recipe-form input[type="text"], .recipe-form textarea, .ing-row input, .ing-row select { background: rgb(255 255 255 / 22%); }
body::before {
  background:
    radial-gradient(42% 34% at 10% 6%, color-mix(in srgb, var(--primary) var(--blob), transparent), transparent 72%),
    radial-gradient(46% 38% at 94% 24%, color-mix(in srgb, var(--sky) calc(var(--blob) - 8%), transparent), transparent 72%),
    radial-gradient(50% 40% at 18% 58%, color-mix(in srgb, var(--plum) calc(var(--blob) - 16%), transparent), transparent 72%),
    radial-gradient(48% 40% at 90% 84%, color-mix(in srgb, var(--primary) calc(var(--blob) - 8%), transparent), transparent 72%),
    radial-gradient(40% 32% at 42% 100%, color-mix(in srgb, var(--spinach) calc(var(--blob) - 20%), transparent), transparent 72%),
    linear-gradient(160deg, color-mix(in srgb, var(--primary) 10%, transparent), color-mix(in srgb, var(--sky) 10%, transparent));
}
:root { --blob: 76%; --cg: rgb(255 255 255 / 18%); --cg-strong: rgb(255 255 255 / 30%); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --blob: 50%; --cg: rgb(70 70 78 / 24%); --cg-strong: rgb(80 80 90 / 32%); } }
:root[data-theme="dark"] { --blob: 50%; --cg: rgb(70 70 78 / 24%); --cg-strong: rgb(80 80 90 / 32%); }
body { background: linear-gradient(170deg, color-mix(in srgb, var(--primary) 14%, var(--bg)), color-mix(in srgb, var(--sky) 12%, var(--bg)) 50%, color-mix(in srgb, var(--plum) 12%, var(--bg))) fixed; }

/* Sprachwahl oben im Profil-Fenster – für alle verständlich */
.pf-lang {
  display: flex; align-items: center; gap: 4px; margin: 0 48px 4px 0; padding: 4px; border-radius: 999px; width: fit-content; max-width: calc(100% - 48px);
  background: linear-gradient(var(--fill), var(--fill)) padding-box, var(--rim) border-box; border: 1px solid transparent;
}
.pf-lang-ic { font-size: 17px; padding: 0 4px 0 6px; line-height: 1; }
.pf-lang-btn { display: inline-flex; align-items: center; gap: 5px; padding: 7px 11px; border-radius: 999px; font-size: 14px; font-weight: 600; color: var(--ink); white-space: nowrap; }
.pf-lang-btn span { font-size: 16px; line-height: 1; font-family: 'Apple Color Emoji', 'Segoe UI Emoji', 'Noto Color Emoji', sans-serif; }
.pf-lang-btn.is-on {
  background: linear-gradient(180deg, rgb(255 255 255 / 30%), rgb(255 255 255 / 0%) 55%), var(--primary); color: #fff;
  box-shadow: 0 4px 12px color-mix(in srgb, var(--primary) 35%, transparent), inset 0 1px 1px rgb(255 255 255 / 55%);
}
@media (max-width: 380px) { .pf-lang-ic { display: none; } .pf-lang-btn { padding: 7px 9px; font-size: 13px; gap: 4px; } }
@media (max-width: 400px) {
  .pf-lang { width: 100%; max-width: none; margin: 32px 0 4px; }
  .pf-lang-btn { flex: 1; justify-content: center; min-width: 0; }
}

/* Drücken wie in iOS 26: Knopf wird unter dem Finger kurz größer und federt zurück */
button, a.chip, a.me-btn, .tab, .pf-opt > span, .lang-tile, .switch-track {
  transition-property: scale, filter, background, box-shadow, color, opacity;
  transition-duration: .5s, .25s, .25s, .25s, .25s, .25s;
  transition-timing-function: cubic-bezier(.28, 1.7, .45, 1), ease, ease, ease, ease, ease;
  -webkit-tap-highlight-color: transparent; touch-action: manipulation;
}
button:active:not(:disabled), a.chip:active, a.me-btn:active, .tab:active, .meal:active, .btn:active:not(:disabled), .chip:active, .me-btn:active { transform: none; opacity: 1; }
button:active:not(:disabled), a.chip:active, a.me-btn:active, .tab:active, .pf-opt:active > span {
  scale: 1.12; filter: brightness(1.08) saturate(1.1);
  transition-duration: .16s; transition-timing-function: cubic-bezier(.2, .8, .2, 1);
}
/* Größere Flächen wachsen weniger */
:is(.btn-wide, .meal-body, .body-tile, .recipe, .lang-tile, .pd-opt, .club-opt, .sl-row, .lab-row, .dl-name, .en-btn, .pf-opt, .sport-mini, .st2-art, .wb, .rem-ways .btn, .seg button):active:not(:disabled) { scale: 1.04; }
:is(.pf-opt):active > span { scale: 1.05; }
:is(.mz-cell, .sw-day, .day, .tick, .box, .round-btn, .x-btn):active:not(:disabled) { scale: 1.18; }
.tab:active { scale: 1.15; }
@media (prefers-reduced-motion: reduce) { button:active, a.chip:active, a.me-btn:active, .tab:active { scale: 1; } }

/* Stärker: Knöpfe +30 %, sauberes Zurückgleiten ohne Nachschwingen */
button, a.chip, a.me-btn, .tab, .pf-opt > span, .lang-tile, .switch-track {
  transition-duration: .38s, .25s, .25s, .25s, .25s, .25s;
  transition-timing-function: cubic-bezier(.22, 1, .36, 1), ease, ease, ease, ease, ease;
}
button:active:not(:disabled), a.chip:active, a.me-btn:active, .tab:active {
  scale: 1.3; z-index: 5;
  transition-duration: .2s; transition-timing-function: cubic-bezier(.2, .9, .3, 1.15);
}
:is(.mz-cell, .sw-day, .day, .tick, .box, .round-btn, .x-btn, .pf-lang-btn):active:not(:disabled) { scale: 1.35; }
.tab:active { scale: 1.3; }
/* Breite Knöpfe und große Flächen: weniger, sonst ragen sie aus dem Bildschirm */
:is(.btn-wide, .rem-ways .btn):active:not(:disabled) { scale: 1.08; }
:is(.meal-body, .body-tile, .recipe, .lang-tile, .pd-opt, .club-opt, .sl-row, .lab-row, .dl-name, .sport-mini, .wb, .seg button, .en-btn):active:not(:disabled) { scale: 1.06; }
.pf-opt:active > span { scale: 1.12; position: relative; z-index: 5; }
/* Langsamer zurück auf normale Größe */
button, a.chip, a.me-btn, .tab, .pf-opt > span, .lang-tile, .switch-track { transition-duration: .8s, .4s, .25s, .25s, .25s, .25s; }



/* ===================== Essens-Vorlieben ===================== */
.pref-chips { flex-wrap: wrap; overflow: visible; gap: 7px; }
.pref-chip { font-size: 14px; padding: 8px 13px; }
.pref-chip.chip-on { --tone-fill: var(--primary); }
.sheet h3 { margin: 18px 0 8px; }
.pref-seg { grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); grid-auto-flow: column; }
.pref-seg button { padding: 9px 2px; font-size: 13.5px; white-space: nowrap; }
.pp-box { margin-top: 18px; padding: 14px; border-radius: 20px; background: linear-gradient(var(--fill), var(--fill)) padding-box, var(--rim) border-box; border: 1px solid transparent; }
.pp-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.pp-stats p { margin: 0; display: flex; flex-direction: column; align-items: center; text-align: center; min-width: 0; }
.pp-stats b { font: 600 20px var(--rounded); color: var(--primary-text); white-space: nowrap; }
.pp-stats span { font-size: 11.5px; color: var(--muted); line-height: 1.25; }
.pp-box .hint { margin: 10px 2px 0; font-size: 13px; }
.pp-warn { display: flex; gap: 6px; align-items: flex-start; color: var(--orange-ink); }
.pp-note { text-align: center; margin: 8px 0 0; }
.plan-prefs { gap: 12px; }
.pp-head { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; align-items: center; }
.pp-head h2 { margin: 0; }
.pp-head .muted { margin: 2px 0 0; font-size: 13.5px; }
.pp-ic { width: 44px; height: 44px; border-radius: 26%; display: grid; place-items: center; font-size: 24px;
  background: linear-gradient(160deg, color-mix(in srgb, var(--primary) 38%, transparent), color-mix(in srgb, var(--primary) 14%, transparent)) padding-box, var(--rim) border-box; border: 1px solid transparent; }
.pp-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.pp-btns .btn { display: inline-flex; justify-content: center; align-items: center; gap: 6px; white-space: nowrap; padding-inline: 10px; }
.fit-note { display: flex; gap: 8px; align-items: flex-start; margin: 4px 0 10px; padding: 10px 12px; border-radius: 14px; font-size: 14px; line-height: 1.4; }
.fit-note .ic-sm { flex: none; margin-top: 2px; }
.fit-ok { background: var(--spinach-soft); color: var(--ink); }
.fit-ok .ic-sm { color: var(--spinach-ink); }
.fit-no { background: var(--orange-soft); color: var(--ink); }
.fit-no .ic-sm { color: var(--orange-ink); }
.allergen-line { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 0 0 12px; font-size: 13px; color: var(--muted); }
.tag-no { background: var(--orange-soft) !important; color: var(--orange-ink) !important; }
.recipe.is-blocked { opacity: .62; }
.recipe.is-blocked .emo { filter: grayscale(.6); }
.cuisine-chips { margin-top: -6px; }
@media (max-width: 380px) {
  .pp-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 10px; }
  .pref-seg button { font-size: 12.5px; }
}

.sheet .pf-later { display: block; margin: 12px auto 0; }
.day.is-active { background: none; color: var(--ink); box-shadow: none; }

/* ===================== Tab-Leiste wie iOS 26: Glaslinse ===================== */
.tabs { position: fixed; touch-action: none; -webkit-user-select: none; user-select: none; -webkit-tap-highlight-color: transparent; overflow: visible; transform-origin: 50% 100%; }
.tab-row { flex: 1; display: flex; justify-content: center; min-width: 0; position: relative; z-index: 1; }
.tab { position: relative; -webkit-user-drag: none; -webkit-touch-callout: none; }
.tab.is-active, :root[data-theme="dark"] .tab.is-active { background: none; box-shadow: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .tab.is-active { background: none; box-shadow: none; } }
.tab:active, .tabs .tab:active { scale: 1; }
/* Farbe zeigt nur die Linse – die Leiste darunter bleibt neutral (wie bei iOS) */
.tab-row .tab.is-active { color: var(--ink); }
.tab-row .tab.is-active .ic { stroke-width: 1.9; }

.tab-lens {
  --lift: 0;
  position: absolute; left: 0; top: 0; z-index: 2; pointer-events: none;
  border-radius: 999px; isolation: isolate; will-change: transform, width, height;
  box-shadow: 0 10px 28px rgb(20 30 60 / calc(var(--lift) * 16%)), 0 2px 6px rgb(20 30 60 / calc(var(--lift) * 10%));
  transition: opacity .2s;
}
.tab-lens.is-off { opacity: 0; }
/* Ruhezustand: graue Kapsel */
.tab-lens::before {
  content: ''; position: absolute; inset: 0; z-index: 0; border-radius: inherit;
  background: rgb(120 120 128 / 16%); opacity: calc(1 - var(--lift));
}
/* Glas-Körper: fast klar, helle dicke Kante wie eine Glasscheibe */
.lens-clip {
  position: absolute; inset: 0; z-index: 1; overflow: hidden; border-radius: inherit;
  background: linear-gradient(180deg, rgb(255 255 255 / calc(var(--lift) * 22%)), rgb(255 255 255 / calc(var(--lift) * 6%)));
  box-shadow:
    inset 0 1.5px 1.5px rgb(255 255 255 / calc(var(--lift) * 95%)),
    inset 0 -1.5px 2px rgb(255 255 255 / calc(var(--lift) * 50%)),
    inset 0 0 7px 1px rgb(255 255 255 / calc(var(--lift) * 45%)),
    inset 4px 0 6px -3px rgb(255 90 170 / calc(var(--lift) * 22%)),
    inset -4px 0 6px -3px rgb(70 190 255 / calc(var(--lift) * 26%));
}
.lens-row { position: absolute; left: 0; top: 0; display: flex; justify-content: center; will-change: transform; }
.lens-row .tab { flex: 1; pointer-events: none; }
.lens-row .tab .ic { stroke-width: 2.3; }
/* Regenbogen-Saum an der Kante (Lichtbrechung) */
.tab-lens::after {
  content: ''; position: absolute; inset: 0; z-index: 2; border-radius: inherit; padding: 1.5px;
  background: conic-gradient(from 210deg, rgb(255 80 170 / 70%), rgb(255 210 80 / 60%), rgb(90 225 255 / 70%), rgb(150 120 255 / 65%), rgb(255 255 255 / 90%), rgb(255 80 170 / 70%));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
  opacity: calc(var(--lift) * .7);
}
:root[data-theme="dark"] .tab-lens::before { background: rgb(255 255 255 / 16%); }
:root[data-theme="dark"] .lens-clip { background: linear-gradient(180deg, rgb(255 255 255 / calc(var(--lift) * 12%)), rgb(255 255 255 / calc(var(--lift) * 3%))); }
:root[data-theme="dark"] .tab-lens { box-shadow: 0 10px 28px rgb(0 0 0 / calc(var(--lift) * 45%)); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .tab-lens::before { background: rgb(255 255 255 / 16%); }
  :root:not([data-theme="light"]) .lens-clip { background: linear-gradient(180deg, rgb(255 255 255 / calc(var(--lift) * 12%)), rgb(255 255 255 / calc(var(--lift) * 3%))); }
  :root:not([data-theme="light"]) .tab-lens { box-shadow: 0 10px 28px rgb(0 0 0 / calc(var(--lift) * 45%)); }
}

/* ===================== Schneller ===================== */
.page, .timer-slot { display: contents; }
/* Der Hintergrund bewegt sich nicht mehr dauernd: sonst muss das Handy jedes Glas in jedem Bild neu weichzeichnen */
body::before { animation: none !important; }

/* ===================== Heute: nächste Mahlzeit groß ===================== */
.hero-meal { display: flex; flex-direction: column; gap: 12px; padding: 18px; }
.hm-eyebrow { font-size: 13px; font-weight: 700; color: var(--tone-ink); letter-spacing: .01em; }
.hm-main { all: unset; cursor: pointer; display: flex; align-items: center; gap: 16px; -webkit-tap-highlight-color: transparent; }
.hm-main:focus-visible { outline: 2.5px solid var(--tone); outline-offset: 4px; border-radius: 16px; }
.hm-art { width: 84px; height: 84px; flex: none; display: block; }
.hm-art .emo { height: 100%; }
.hm-text { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.hm-name { font-family: var(--display); font-size: 22px; font-weight: 700; letter-spacing: -0.025em; line-height: 1.2; }
.hm-note { font-size: 13px; color: var(--muted); }
.hm-actions { display: grid; grid-template-columns: 1.4fr 1fr; gap: 10px; }
.hm-actions .btn { justify-content: center; }
.hm-done { background: var(--tone); color: #fff; }
.hm-extra .link-btn { font-size: 14px; }
.hero-done { display: flex; align-items: center; gap: 14px; padding: 16px 18px; }
.hero-done h2 { font-size: 19px; margin: 0 0 2px; }
.hd-emo { width: 52px; flex: none; }
/* die übrigen Mahlzeiten kompakt */
.meals-sm { gap: 8px; }
.meal-sm { padding: 9px 12px 9px 10px; border-radius: 18px; gap: 2px 10px; }
.meal-sm .meal-art { width: 40px; height: 40px; }
.meal-sm .meal-name { font-size: 15px; }
.meal-sm .meal-slot { font-size: 11px; }
.meal-sm .meta { font-size: 12px; }
.meal-sm .tick { width: 26px; height: 26px; }
@media (max-width: 380px) { .hm-art { width: 70px; height: 70px; } .hm-name { font-size: 20px; } }
.hero-done { flex-direction: row; text-align: left; }
.meal-sm .meal-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.meal-sm .meta { opacity: .85; }

/* ===================== Familie ===================== */
.fam-row { display: flex; align-items: center; gap: 12px; }
.card.fam-row { padding: 14px 16px; }
.fam-txt { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.fam-txt small { color: var(--muted); font-size: 12.5px; line-height: 1.35; overflow-wrap: anywhere; }
.fam-faces { display: flex; flex: none; }
.fam-faces i { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-weight: 700; font-size: 13px; color: var(--tone-ink); background: var(--tone-soft); box-shadow: 0 0 0 2px var(--surface); }
.fam-faces i + i { margin-left: -9px; }
.fam-faces i.more { background: var(--fill); color: var(--muted); font-size: 11px; }
.fam-modes { display: grid; gap: 8px; margin: 16px 0; }
.fam-mode { display: flex; align-items: center; gap: 12px; text-align: left; padding: 12px 14px; border-radius: 18px; background: var(--fill); color: var(--ink); box-shadow: inset 0 0 0 1.5px transparent; }
.fam-mode > span:last-child { display: flex; flex-direction: column; min-width: 0; }
.fam-mode b { font-size: 15.5px; }
.fam-mode small { color: var(--muted); font-size: 12.5px; line-height: 1.35; }
.fam-mode.is-on { background: var(--primary-soft); box-shadow: inset 0 0 0 1.5px var(--primary); }
.fm-ic { font-size: 24px; width: 34px; text-align: center; flex: none; }
.fam-counts { display: grid; gap: 14px; }
.fam-list { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 8px; }
.fam-list li { display: flex; align-items: center; gap: 12px; padding: 10px 8px 10px 12px; border-radius: 16px; background: var(--fill); }
.fam-av { width: 38px; height: 38px; flex: none; border-radius: 50%; display: grid; place-items: center; font-weight: 700; color: var(--tone-ink); background: var(--tone-soft); }
.fam-mtxt { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.fam-mtxt small { color: var(--muted); font-size: 12.5px; }
.fam-list .icon-btn { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; color: var(--muted); background: none; flex: none; }
.fam-sum { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 16px 0; }
.fam-sum p { display: flex; flex-direction: column; padding: 12px 14px; border-radius: 16px; background: var(--fill); }
.fam-sum b { font-family: var(--display); font-size: 22px; }
.fam-sum span { color: var(--muted); font-size: 12.5px; line-height: 1.3; }
.mem-form { margin-top: 12px; }
.mem-form > * { min-width: 0; }
.mf-row2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.back-ic { transform: rotate(180deg); }
.set-row.fam-set { padding: 12px 0; }

/* ===================== Fortschritt ===================== */
.prog-card { gap: 12px; }
.prog-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.prog-head h2 { display: flex; align-items: center; gap: 6px; margin: 0; }
.prog-seg button { padding: 6px 12px; font-size: 13px; white-space: nowrap; }
.prog-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.prog-row { padding: 12px 12px 8px; border-radius: 18px; background: var(--fill); min-width: 0; }
.pr-top { display: flex; align-items: baseline; justify-content: space-between; gap: 6px; margin: 0; }
.pr-t { font-size: 13px; font-weight: 600; display: flex; align-items: center; gap: 6px; }
.pr-t::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--tone); flex: none; }
.pr-sub { font-size: 11px; color: var(--muted); white-space: nowrap; }
.pr-val { margin: 2px 0 6px; display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; }
.pr-val b { font-family: var(--display); font-size: 20px; font-weight: 700; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.pr-delta { font-size: 11.5px; font-weight: 600; color: var(--muted); white-space: nowrap; }
.pr-delta.is-good { color: var(--spinach-ink); }
.pr-delta.is-bad { color: var(--tomato-ink); }
.pr-chart { display: block; width: 100%; height: auto; overflow: visible; }
.pr-bar { fill: var(--tone); opacity: .38; transition: opacity .2s; }
.pr-bar.is-on { opacity: 1; }
.pr-stub { fill: color-mix(in srgb, var(--muted) 30%, transparent); }
.pr-target { stroke: color-mix(in srgb, var(--ink) 35%, transparent); stroke-width: 1; vector-effect: non-scaling-stroke; }
.pr-line { fill: none; stroke: var(--tone); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.pr-dot { fill: var(--tone); stroke: var(--surface); stroke-width: 2; opacity: .55; }
.pr-dot.is-on { opacity: 1; }
.pr-hit { cursor: pointer; }
.prog-axis { display: flex; justify-content: space-between; margin: -2px 4px 0; font-size: 11px; color: var(--muted); }
.prog-empty { margin: 0; }
.pr-val { margin-bottom: 0; }
.pr-goal { margin: 0 0 6px; font-size: 11px; color: var(--muted); }
.pr-val + .pr-chart { margin-top: 6px; }
@media (max-width: 360px) { .prog-row { padding: 10px 10px 6px; } .pr-val b { font-size: 18px; } .pr-sub { display: none; } }

/* ===================== Push ===================== */
.push-box { margin-top: 14px; padding: 14px; border-radius: 18px; background: var(--fill); display: grid; gap: 10px; }
.push-head { margin: 0; display: flex; flex-direction: column; }
.push-head small { color: var(--muted); font-size: 12.5px; line-height: 1.35; }
.push-box .hint { margin: 0; }
.push-state { margin: 0; display: flex; align-items: center; gap: 8px; font-weight: 600; color: var(--spinach-ink); }
.push-on { background: var(--tone); color: #fff; }
.card.fam-row { flex-direction: row; align-items: center; text-align: left; }
.fam-faces i { width: 28px; height: 28px; font-size: 12px; }
.fam-row .chip { flex: none; }
@media (max-width: 400px) { .fam-chip-t { display: none; } .fam-row .chip { padding: 8px 10px; } }

/* ===================== Außer Plan gegessen ===================== */
.hm-other { justify-self: center; font-size: 14px; margin-top: -2px; }
.add-extra { align-self: flex-start; font-size: 14px; padding: 8px 14px; }
.tick-static { display: grid; place-items: center; border-radius: 50%; color: #fff; background: var(--tone); flex: none; }
.meal-sm .tick-static { width: 26px; height: 26px; }
.tick-static .ic-tick { width: 15px; height: 15px; }
.is-swapped .meal-name, .extra-row .meal-name { color: var(--ink); }
.is-swapped .meal-art, .extra-row .meal-art { opacity: 1; filter: none; }
.meal .icon-btn { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; color: var(--muted); background: none; }
.extra-row .meal-body { cursor: default; }
.food-ctrl { display: flex; gap: 8px; align-items: center; margin: 14px 0 12px; flex-wrap: wrap; }
.food-tabs { flex: 1 1 auto; }
.food-tabs button, .food-size button { padding: 8px 12px; font-size: 14px; white-space: nowrap; }
.food-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.food-tile { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 12px 6px 10px; border-radius: 16px; background: var(--fill); color: var(--ink); text-align: center; min-width: 0; }
.ft-emo { font-size: 30px; line-height: 1; }
.ft-name { font-size: 12.5px; font-weight: 600; line-height: 1.25; overflow-wrap: anywhere; }
.ft-kcal { font-size: 11.5px; color: var(--muted); }
.food-search { width: 100%; padding: 11px 14px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink); font: inherit; margin-bottom: 10px; }
.food-list { display: grid; gap: 6px; }
.food-row { display: flex; align-items: center; gap: 12px; padding: 8px 12px 8px 8px; border-radius: 14px; background: var(--fill); color: var(--ink); text-align: left; }
.fr-art { width: 40px; height: 40px; flex: none; display: block; }
.fr-art .emo { height: 100%; }
.fr-name { flex: 1; min-width: 0; font-weight: 600; font-size: 14.5px; }
.fr-kcal { font-size: 12.5px; color: var(--muted); white-space: nowrap; }
.own-food { margin-top: 4px; }

/* ===================== Daten & Sicherung ===================== */
.backup-card h2 { display: flex; align-items: center; gap: 8px; }
.bk-box { display: grid; gap: 10px; padding: 14px; border-radius: 18px; background: var(--fill); margin: 10px 0 4px; }
.bk-box p { margin: 0; }
.bk-state { display: flex; gap: 10px; align-items: flex-start; color: var(--spinach-ink); }
.bk-state > span { display: flex; flex-direction: column; color: var(--ink); }
.bk-state small { color: var(--muted); font-size: 12.5px; }
.bk-code { white-space: nowrap; font: 700 clamp(13px, 4.2vw, 18px)/1.3 ui-monospace, 'SF Mono', Menlo, monospace; letter-spacing: .06em; text-align: center; padding: 12px; border-radius: 14px; background: var(--surface); user-select: all; -webkit-user-select: all; overflow-wrap: anywhere; }
.bk-confirm { display: flex; gap: 10px; align-items: center; font-size: 14.5px; font-weight: 600; }
.bk-confirm input { width: 20px; height: 20px; accent-color: var(--spinach); }
.bk-box .btn-wide[disabled] { opacity: .45; }
.bk-sub { margin: 14px 0 2px; font-size: 15px; }

/* ===================== Rechtliches ===================== */
.legal-text { font-size: 14.5px; line-height: 1.55; }
.legal-text h3 { font-size: 15.5px; margin: 18px 0 4px; }
.legal-text p { margin: 0 0 10px; }
.legal-text .ph { background: var(--saffron-soft); color: var(--saffron-ink); border-radius: 6px; padding: 0 4px; font-weight: 600; }
.consent { font-size: 12px !important; line-height: 1.4; margin: 0 !important; }
.consent .link-btn { font-size: 12px; padding: 0; display: inline; min-height: 0; }

/* ===================== Erster Start ===================== */
.sheet.sheet-onb { min-height: min(88vh, 760px); display: flex; flex-direction: column; }
.sheet-onb .onb-go { margin-top: auto; }
.sheet-onb .onb-go, .sheet-onb .onb-link { flex: none; }
.onb-link { align-self: center; margin-top: 10px; }
.onb-lang { margin: 6px 44px 0 0; }
.onb-hero { display: grid; grid-template-columns: repeat(3, 64px); gap: 12px; justify-content: center; margin: 26px auto 22px; }
.onb-tile { display: block; width: 64px; height: 64px; animation: onbPop .6s cubic-bezier(.3, 1.5, .5, 1) both; animation-delay: calc(var(--d) * 60ms); }
.onb-tile .emo { height: 100%; }
.onb-tile:nth-child(2), .onb-tile:nth-child(5), .onb-tile:nth-child(8) { transform: translateY(14px); }
@keyframes onbPop { from { opacity: 0; scale: .6; } }
.onb-brand { text-align: center; margin: 4px 0 0; color: var(--spinach-ink, var(--muted)); }
.onb-title { font-family: var(--display); font-size: clamp(30px, 8.5vw, 40px); line-height: 1.08; letter-spacing: -0.03em; text-align: center; margin: 8px 0 10px; }
.onb-sub { text-align: center; color: var(--muted); font-size: 16px; line-height: 1.45; margin: 0 auto 22px; max-width: 30ch; }
.onb-h { font-size: 26px; margin: 18px 0 8px; }
.onb-dots { display: flex; gap: 6px; justify-content: center; margin: 6px 40px 4px; }
.onb-dots i { width: 7px; height: 7px; border-radius: 4px; background: color-mix(in srgb, var(--muted) 35%, transparent); transition: width .3s, background .3s; }
.onb-dots i.done { background: color-mix(in srgb, var(--primary) 55%, transparent); }
.onb-dots i.on { width: 22px; background: var(--primary); }
.onb-feats { list-style: none; margin: 12px 0 22px; padding: 0; display: grid; gap: 16px; }
.onb-feats li { display: flex; gap: 14px; align-items: center; animation: rise .45s cubic-bezier(.2, .8, .2, 1) both; animation-delay: calc(var(--d) * 80ms); }
.onb-feats li > span:last-child { display: flex; flex-direction: column; gap: 2px; }
.onb-feats b { font-size: 16px; }
.onb-feats small { color: var(--muted); font-size: 13.5px; line-height: 1.4; }
.onb-emo { width: 50px; flex: none; }
.onb-fam { margin: 14px 0; }
.onb-done-emo { width: 84px; margin: 26px auto 6px; animation: onbPop .7s cubic-bezier(.3, 1.6, .5, 1) both; }
.onb-stats { margin: 12px 0 16px; }
.onb-next { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 18px; background: var(--fill); margin-bottom: 18px; }
.onb-next .emo { width: 52px; height: 52px; flex: none; }
.onb-next > span { display: flex; flex-direction: column; min-width: 0; }
.onb-next small { color: var(--muted); font-size: 12.5px; }
.onb-next b { font-size: 16px; }
@media (prefers-reduced-motion: reduce) { .onb-tile, .onb-feats li, .onb-done-emo { animation: none; } }

/* ===================== Bedienung für alle ===================== */
/* Textgröße: Inhalt und Blätter werden etwas größer (Tab-Leiste bleibt gleich) */
main, .sheet { zoom: var(--zoom, 1); }
/* Mehr Kontrast: klare Flächen statt Glas, kräftigere Schrift und Linien */
:root[data-contrast] {
  --cg: #ffffff; --cg-strong: #ffffff; --fill: #e9e9ee; --muted: #3c3c43; --line: #b9b9c0;
  --rim: linear-gradient(#8e8e93, #8e8e93); --blob: 0%;
}
:root[data-contrast][data-theme="dark"] { --cg: #1c1c1e; --cg-strong: #2c2c2e; --fill: #3a3a3c; --muted: #d1d1d6; --line: #636366; }
@media (prefers-color-scheme: dark) { :root[data-contrast]:not([data-theme="light"]) { --cg: #1c1c1e; --cg-strong: #2c2c2e; --fill: #3a3a3c; --muted: #d1d1d6; --line: #636366; } }
:root[data-contrast] .card, :root[data-contrast] .sheet, :root[data-contrast] .tabs, :root[data-contrast] .meal { -webkit-backdrop-filter: none; backdrop-filter: none; }
:root[data-contrast] .chip, :root[data-contrast] .btn-ghost, :root[data-contrast] .seg { box-shadow: inset 0 0 0 1.5px var(--line); }
:root[data-contrast] body::before { opacity: .35; }
@media (prefers-contrast: more) {
  :root { --muted: #3c3c43; --line: #b9b9c0; }
  :root[data-theme="dark"] { --muted: #d1d1d6; --line: #636366; }
}
/* Größere Tippflächen, ohne das Aussehen zu ändern (mind. ~44 px) */
.tick, .mz-day, .icon-btn, .round-btn { position: relative; }
.tick::after { content: ''; position: absolute; inset: -9px; }
.mz-day::after { content: ''; position: absolute; inset: -8px -2px; }
.dl-name { padding-block: 6px; }
#sheet-title:focus, .sheet h2:focus { outline: none; }
:root[data-contrast] .tabs { background: linear-gradient(var(--cg-strong), var(--cg-strong)) padding-box, var(--rim) border-box; }
.hm-actions .btn { min-width: 0; white-space: normal; text-align: center; }
.own-food .field input, .restore-form .field input, .login-form .field input, .wd-form .field input:not([type=date]) { width: 100%; min-width: 0; padding: 11px 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink); font: 600 17px var(--font); }
.own-food .field input:focus, .restore-form .field input:focus, .login-form .field input:focus, .wd-form .field input:focus { outline: none; box-shadow: 0 0 0 2px var(--primary); }
.restore-form #rs-code { font-family: ui-monospace, 'SF Mono', Menlo, monospace; letter-spacing: .04em; text-transform: uppercase; }

/* Beim Drücken nach vorne holen – aber nur Knöpfe ohne eigene Position.
   (Früher bekam jeder Knopf position: relative: das X oben rechts und die Timer-Pille
   sprangen dadurch beim Antippen weg, und der Tipp kam nicht an.) */
:where(button:active, a.chip:active, a.me-btn:active) { position: relative; }

/* ===================== Laptop: beim Drüberfahren mit der Maus größer ===================== */
/* Nur bei echter Maus/Trackpad – auf dem Handy gibt es kein „Drüberfahren“, dort bleibt alles wie es ist. */
@media (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  button, a[href], a.chip, a.me-btn, .tab, .pf-opt > span, [data-action] { cursor: pointer; }
  :is(button, a[href], .pf-opt > span) {
    transition-property: scale, filter, background, box-shadow, color, opacity;
    transition-duration: .45s, .25s, .25s, .25s, .25s, .25s;
    transition-timing-function: cubic-bezier(.22, 1, .36, 1), ease, ease, ease, ease, ease;
  }
  /* normale Knöpfe */
  :where(button, a.chip, a.me-btn, a.sm-art, .tab):hover:not(:active):not(:disabled),
  .pf-opt:hover > span { scale: 1.07; filter: brightness(1.04); transition-duration: .3s, .25s, .25s, .25s, .25s, .25s; }
  /* kleine Knöpfe (X, Plus/Minus, Häkchen, Symbole) etwas mehr */
  :is(.round-btn, .x-btn, .home-btn, .me-btn, .tick, .mz-day, .icon-btn, .pf-lang-btn, .link-btn):hover:not(:active):not(:disabled) { scale: 1.14; }
  /* große Flächen (Karten, Listen-Zeilen, breite Knöpfe) nur ein bisschen – sonst ragen sie heraus */
  :is(.recipe, .hm-main, .body-tile, .btn-wide, .shop-item, .meal-body, .lang-tile, .note-inline, .dl-name, .fam-mode, .club-opt, .food-row, .sl-row, .lab-row, .pd-opt, .sport-mini, .wb, .search):hover:not(:active):not(:disabled) { scale: 1.025; }
  /* mittelgroße Kacheln */
  :is(.food-tile, .sw-day, .en-btn, .mz-cell, .st2-art):hover:not(:active):not(:disabled) { scale: 1.06; }
  /* Nicht wachsen: gesperrte Knöpfe, aktiver Tab unter der Glaslinse, ausgewählter Tag */
  .tab.is-active:hover, .tab-row .tab.is-active:hover { scale: 1; }
}

/* ===================== Neue Version ===================== */
#update-bar {
  position: fixed; left: 50%; top: calc(env(safe-area-inset-top, 0px) + 10px); z-index: 80;
  display: flex; align-items: center; gap: 10px; width: min(440px, calc(100% - 24px)); padding: 10px 10px 10px 14px;
  border-radius: 22px; background: linear-gradient(var(--cg-strong), var(--cg-strong)) padding-box, var(--rim) border-box; border: 1px solid transparent;
  -webkit-backdrop-filter: blur(24px) saturate(180%); backdrop-filter: blur(24px) saturate(180%);
  box-shadow: 0 12px 40px rgb(20 30 60 / 18%);
  transform: translate(-50%, calc(-100% - 30px)); transition: transform .5s cubic-bezier(.22, 1, .36, 1);
}
#update-bar.is-on { transform: translate(-50%, 0); }
#update-bar > span:first-child { font-size: 22px; }
.ub-txt { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.ub-txt b { font-size: 15px; }
.ub-txt small { font-size: 12.5px; color: var(--muted); }
.ub-go { padding: 9px 14px; font-size: 14px; background: var(--primary); color: #fff; flex: none; }
.ub-x { flex: none; }

/* ===================== Plan lernt mit ===================== */
.adapt-card h2 { display: flex; align-items: center; gap: 6px; }
.ad-rate { margin: 4px 0 8px; display: flex; flex-direction: column; }
.ad-rate b { font-family: var(--display); font-size: 26px; letter-spacing: -0.02em; display: inline; }
.ad-rate small { color: var(--muted); font-size: 13px; }
.ad-ok { display: flex; align-items: center; gap: 6px; color: var(--spinach-ink); font-weight: 600; margin: 0; }
.ad-sug { display: grid; gap: 10px; padding: 14px; border-radius: 18px; background: var(--tone-soft); }
.ad-sug p { margin: 0; display: flex; flex-direction: column; gap: 3px; }
.ad-sug small { font-size: 13px; line-height: 1.4; }
.ad-adj { margin: 10px 0 0; font-size: 13px; color: var(--muted); display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.adapt-nudge { display: flex; align-items: center; gap: 8px; width: 100%; text-align: left; }
.adapt-nudge > span { flex: 1; }

/* ===================== Einkaufsliste teilen ===================== */
.share-sheet .seg { display: grid; grid-template-columns: 1fr 1fr; margin: 14px 0 4px; }
.share-sheet .seg button { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.share-sheet .btn-row { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 10px; }
.share-sheet .share-text { font-size: 14px; }

/* ===================== Leiste schrumpft beim Scrollen (iOS 26) ===================== */
:root {
  /* Feder mit kaum sichtbarem Nachschwingen */
  --spring: cubic-bezier(.3, 1.25, .5, 1);
  --spring: linear(0, 0.0787, 0.2515, 0.4495, 0.6326, 0.7817, 0.8917, 0.9653, 1.0091, 1.031, 1.0382, 1.0365, 1.0305, 1.0229, 1.0157, 1.0096, 1.005, 1.0019, 1, 0.9989, 0.9986, 0.9986, 0.9988, 0.9991, 0.9993, 0.9996, 1);
}
.tabs { transition: transform .55s var(--spring), opacity .28s ease .06s; }
:root.nav-min .tabs {
  transform: translate(var(--min-tx, 0px), var(--min-ty, 0px)) scale(.42);
  opacity: 0; pointer-events: none;
  transition: transform .42s cubic-bezier(.32, .72, .2, 1), opacity .2s ease;
}
.tab-mini {
  position: fixed; z-index: 21; padding: 0; margin: 0;
  left: max(14px, env(safe-area-inset-left, 0px)); bottom: calc(8px + env(safe-area-inset-bottom, 0px));
  width: 62px; height: 62px; border-radius: 50%; display: grid; place-items: center;
  color: var(--tone-ink, var(--ink)); -webkit-tap-highlight-color: transparent;
  background: linear-gradient(rgb(255 255 255 / 38%), rgb(255 255 255 / 38%)) padding-box, var(--rim) border-box; border: 1px solid transparent;
  -webkit-backdrop-filter: blur(28px) saturate(200%) brightness(1.05); backdrop-filter: blur(28px) saturate(200%) brightness(1.05);
  box-shadow: 0 14px 40px rgb(20 30 70 / 18%), inset 0 1px 1px rgb(255 255 255 / 80%), inset 0 -1px 1px rgb(255 255 255 / 30%);
  opacity: 0; visibility: hidden; transform: translateX(var(--from-x, 0px)) scale(.8);
  transition: opacity .18s ease, transform .4s cubic-bezier(.32, .72, .2, 1), visibility 0s linear .4s;
}
:root.nav-min .tab-mini {
  opacity: 1; visibility: visible; transform: none;
  transition: opacity .22s ease .06s, transform .55s var(--spring), visibility 0s;
}
.tab-mini .ic { width: 27px; height: 27px; stroke-width: 2.1; }
.tab-mini:active { scale: .92; }
:root[data-theme="dark"] .tab-mini { background: linear-gradient(rgb(40 40 46 / 45%), rgb(40 40 46 / 45%)) padding-box, var(--rim) border-box; box-shadow: 0 14px 40px rgb(0 0 0 / 55%), inset 0 1px 1px rgb(255 255 255 / 18%); color: var(--tone, var(--ink)); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .tab-mini { background: linear-gradient(rgb(40 40 46 / 45%), rgb(40 40 46 / 45%)) padding-box, var(--rim) border-box; box-shadow: 0 14px 40px rgb(0 0 0 / 55%), inset 0 1px 1px rgb(255 255 255 / 18%); color: var(--tone, var(--ink)); } }
:root[data-contrast] .tab-mini { background: linear-gradient(var(--cg-strong), var(--cg-strong)) padding-box, var(--rim) border-box; }
@media (prefers-reduced-motion: reduce) { .tab-mini { display: none; } }
@media (min-width: 720px) and (hover: hover) { .tab-mini { display: none; } }

/* ===================== Fenster: wachsen, wegwischen, Seite rückt nach hinten ===================== */
#main { transition: transform .42s cubic-bezier(.32, .72, 0, 1); }
#main.is-back { transform: scale(.94); }
.art-fly { position: fixed; z-index: 70; margin: 0; pointer-events: none; transform-origin: 0 0; will-change: transform; }
.art-fly .emo { height: 100%; }
/* der Griff zeigt, dass man das Fenster ziehen kann */
.sheet-grip { touch-action: none; }
@media (prefers-reduced-motion: reduce) { #main { transition: none; } #main.is-back { transform: none; } }

/* ===================== Glas reagiert aufs Kippen ===================== */
/* Glanz-Ring auf der Kante: nur dieser kleine Ring wird neu gemalt, wenn sich das Handy neigt */
:root.tilt :is(.tabs, .tab-mini)::after {
  content: ""; position: absolute; inset: -1px; z-index: 3; border-radius: inherit; pointer-events: none;
  padding: 1.5px;
  background: linear-gradient(var(--spec-a, 150deg), rgb(255 255 255 / calc(var(--spec-i, .6) * 100%)), rgb(255 255 255 / 0) 26%, rgb(255 255 255 / 0) 70%, rgb(255 255 255 / calc(var(--spec-i, .6) * 60%)));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
}
/* dazu ein weicher Schimmer auf der Fläche, der mitwandert */
:root.tilt :is(.tabs, .tab-mini)::before {
  content: ""; position: absolute; inset: 0; z-index: 0; border-radius: inherit; pointer-events: none;
  background: linear-gradient(var(--spec-a, 150deg), rgb(255 255 255 / calc(var(--spec-i, .6) * 22%)), rgb(255 255 255 / 0) 45%);
}
:root.tilt .sheet {
  /* gleiche Kante wie sonst (--rim), nur der Winkel und die Helligkeit folgen der Neigung */
  --k: calc(var(--spec-i, .6) / .6);
  background: linear-gradient(rgb(255 255 255 / 52%), rgb(255 255 255 / 52%)) padding-box,
    linear-gradient(var(--spec-a, 150deg), rgb(255 255 255 / 100%), rgb(255 255 255 / calc(35% * var(--k))) 30%, rgb(255 255 255 / calc(10% * var(--k))) 60%, rgb(255 255 255 / calc(75% * var(--k)))) border-box;
}
:root.tilt[data-theme="dark"] .sheet {
  background: linear-gradient(rgb(40 40 46 / 60%), rgb(40 40 46 / 60%)) padding-box,
    linear-gradient(var(--spec-a, 150deg), rgb(255 255 255 / calc(40% * var(--k))), rgb(255 255 255 / calc(8% * var(--k))) 30%, rgb(255 255 255 / 3%) 60%, rgb(255 255 255 / calc(22% * var(--k)))) border-box;
}
@media (prefers-color-scheme: dark) {
  :root.tilt:not([data-theme="light"]) .sheet {
    background: linear-gradient(rgb(40 40 46 / 60%), rgb(40 40 46 / 60%)) padding-box,
      linear-gradient(var(--spec-a, 150deg), rgb(255 255 255 / calc(40% * var(--k))), rgb(255 255 255 / calc(8% * var(--k))) 30%, rgb(255 255 255 / 3%) 60%, rgb(255 255 255 / calc(22% * var(--k)))) border-box;
  }
}

/* Profil: Hinweis beim Überspringen */
.pf-pitch { margin: 2px 0 6px; font-weight: 600; color: var(--plum-ink, inherit); }
.pf-skip { margin-top: 14px; padding: 14px; border-radius: 16px; background: var(--plum-soft, var(--surface)); }
.pf-skip p { margin: 0 0 12px; }
.pf-skip[hidden] { display: none; }
.onb-neutral { text-align: center; margin: 4px 0 12px; }

/* Premium */
.set-row[hidden] { display: none; }
.chip-locked { opacity: .7; }
.chip-locked .ic-xs { vertical-align: -1px; }
.prem-feats { margin: 6px 0 14px; }
.prem-opts { display: grid; gap: 10px; margin-bottom: 14px; }
.pd-opt.prem-opt { grid-template-columns: minmax(0, 1fr) auto; padding: 14px 16px; --tone: var(--orange); --tone-soft: var(--orange-soft); }
.prem-opt > span:first-child { display: flex; flex-direction: column; gap: 2px; }
.prem-opt b { font-size: 16px; }
.prem-opt small { font-size: 13px; color: var(--muted); }
.prem-price { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; }
.prem-price i { font-style: normal; font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 99px; background: var(--spinach-soft); color: var(--spinach-ink); }
.prem-fine { margin-top: 12px; text-align: center; }
.prem-card .btn { margin-top: 12px; }
.prem-card .link-btn { display: block; margin: 10px auto 0; }

/* Konto */
.acc-card .btn-wide { margin-top: 12px; }
.acc-btns { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 10px; flex-wrap: wrap; }
.login-links, .prem-login { text-align: center; margin-top: 12px; }
#login-code { letter-spacing: .3em; font-variant-numeric: tabular-nums; }

/* 31-Tage-Challenge */
.ch-card { --tone: var(--spinach); --tone-soft: var(--spinach-soft); }
.ch-head { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; align-items: center; }
.ch-head .eyebrow { margin: 0; font-size: 11px; }
.ch-head h2, .ch-head h3 { margin: 2px 0 0; font-size: 17px; line-height: 1.25; overflow-wrap: anywhere; }
.ch-card.is-done .tick, .ch-card .tick[aria-pressed="true"] { background: var(--tone); color: #fff; box-shadow: none; }
.ch-text { margin: 10px 0 12px; font-size: 14.5px; line-height: 1.45; }
.ch-card > .muted { margin: 10px 0 0; }
.fm-card > .muted { margin: 10px 0 0; }
.fm-card a.btn { text-decoration: none; }
/* Story-Bild der Challenge */
.ch-mile { margin: 10px 0 0; font-weight: 600; }
.story-prev { display: grid; place-items: center; min-height: 160px; margin: 12px 0; }
.story-img { display: block; width: auto; height: auto; max-width: 100%; max-height: 52vh; border-radius: 18px; box-shadow: 0 8px 28px rgb(0 0 0 / 18%); }
.story-sheet .btn-wide + .btn-wide { margin-top: 10px; }
.bar-ch span { background: var(--spinach); }
.ch-meta { display: flex; flex-wrap: wrap; gap: 4px 12px; margin: 8px 0 0; font-size: 12.5px; color: var(--muted); }
.ch-btns { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin-top: 12px; }
.ch-stats { margin: 6px 0 14px; }
.ch-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; }
.ch-cell { display: grid; place-items: center; aspect-ratio: 1; min-height: 34px; border-radius: 12px; font-weight: 700; font-size: 14px; background: var(--surface-2); color: var(--ink); }
.ch-cell.is-done { background: var(--spinach); color: #fff; }
.ch-cell.is-today { box-shadow: inset 0 0 0 2px var(--spinach); }
.ch-cell.is-done.is-today { box-shadow: inset 0 0 0 2px var(--spinach-ink); }
.ch-cell.is-sel { outline: 2.5px solid var(--ink); outline-offset: 1px; }
.ch-cell.is-locked { opacity: .4; font-weight: 500; }
.ch-detail { margin-top: 16px; padding: 14px; border-radius: 18px; background: var(--spinach-soft); }
.ch-detail .ch-head { grid-template-columns: auto minmax(0, 1fr); }
.ch-wait { margin-top: 14px; text-align: center; }
.ch-foot { justify-content: space-between; margin-top: 16px; }
.ch-head .emo { width: 46px; }
.ch-detail .ch-head .emo { width: 40px; }
.ch-head h3 { font-size: 17px; font-weight: 700; letter-spacing: 0; text-transform: none; color: var(--ink); }
.nowrap { white-space: nowrap; }
.ch-rem { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; color: var(--muted); }
.ch-btns .link-btn .ic-xs { vertical-align: -1px; }

/* Schwangerschaft im Profil */
.pf-check { display: flex; align-items: center; gap: 10px; font-weight: 600; padding: 6px 0; cursor: pointer; }
.pf-check input { width: 22px; height: 22px; accent-color: var(--plum, var(--primary)); }
.pf-preg .pf-due, .pf-goal-preg { display: none; }
.pf-preg:has(#pf-preg:checked) .pf-due { display: flex; }
.pf-preg:has(#pf-preg:checked) p.pf-due { display: block; }
.pf-form:has(input[name="sex"][value="m"]:checked) .pf-preg { display: none; }
.pf-form:has(#pf-preg:checked):not(:has(input[name="sex"][value="m"]:checked)) .pf-goal-preg { display: block; }
/* Premium: „sofort starten“ – normal gesetzt, Häkchen oben bündig; Widerrufs-Formular */
.prem-start { align-items: flex-start; font-weight: 400; font-size: 14px; line-height: 1.4; margin: 14px 0 4px; }
.prem-start input { flex: none; margin: 0; }
.wd-form { display: grid; gap: 10px; margin-top: 12px; }
.wd-receipt { font-weight: 600; }
/* Kündigungsseite: Grund nur bei „außerordentlich“, Datum nur bei „Wunschtermin“, Termin entfällt bei „außerordentlich“ */
.cancel-form textarea { width: 100%; min-width: 0; padding: 11px 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink); font: 500 16px/1.4 var(--font); resize: vertical; }
.cancel-form textarea:focus { outline: none; box-shadow: 0 0 0 2px var(--primary); }
.cancel-reason, .cancel-date { display: none; }
.cancel-form:has(input[name="mode"][value="extraordinary"]:checked) .cancel-reason { display: flex; }
.cancel-form:has(input[name="mode"][value="extraordinary"]:checked) .cancel-when { display: none; }
.cancel-form:has(input[name="when"][value="date"]:checked) .cancel-date { display: flex; margin-top: 8px; }
.cancel-date input { width: 100%; min-width: 0; padding: 11px 12px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink); font: 600 16px var(--font); min-height: 46px; }
.cancel-end { font-size: 16px; }
.cancel-form .pf-opt b { overflow-wrap: normal; -webkit-hyphens: auto; hyphens: auto; }
.legal-links { margin: 10px 0 0; }
/* Stillzeit: nur sichtbar, solange „schwanger“ nicht angehakt ist; Auswahl voll/teilweise erst nach dem Haken */
.pf-preg:has(#pf-preg:checked) .pf-nurse-box, .pf-nurse, .pf-goal-nurse { display: none; }
.pf-nurse-box { margin-top: 4px; }
.pf-nurse-box:has(#pf-nurse:checked) .pf-nurse { display: grid; }
.pf-nurse-box:has(#pf-nurse:checked) p.pf-nurse { display: block; }
.pf-form:has(#pf-nurse:checked):not(:has(#pf-preg:checked)):not(:has(input[name="sex"][value="m"]:checked)) .pf-goal-nurse { display: block; }
.pf-due input { width: 100%; min-width: 0; padding: 11px 12px; border-radius: 12px; border: 0; background: var(--fill); color: var(--ink); font: 600 16px var(--font); min-height: 46px; }

/* Schwangerschaft */
.preg-card { --tone: var(--plum); --tone-soft: var(--plum-soft); }
.preg-card > .muted { margin: 10px 0 0; }
.preg-list { margin: 6px 0 4px; padding-left: 20px; display: grid; gap: 8px; font-size: 14.5px; line-height: 1.45; }
.preg-note { margin-top: 10px; }
.pf-form .w-pre { display: none; }
.pf-form:has(#pf-preg:checked):not(:has(input[name="sex"][value="m"]:checked)) .w-pre { display: inline; }
.pf-form:has(#pf-preg:checked):not(:has(input[name="sex"][value="m"]:checked)) .w-now { display: none; }

/* Heute: Fokus – weitere Hinweise und „Mehr für heute“ erst auf Tippen */
.more-hints { align-self: center; min-height: 44px; }
.more-hints .ic-xs, .today-more-btn .ic-sm { transform: rotate(90deg); transition: transform .2s; flex: none; }
.more-hints[aria-expanded="true"] .ic-xs, .today-more-btn[aria-expanded="true"] .ic-sm { transform: rotate(-90deg); }
.today-more-btn { width: 100%; flex-direction: row; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 18px; color: var(--ink); }
.today-more-btn > span { display: grid; gap: 2px; min-width: 0; }
.today-more-btn b { font-size: 16px; }
.today-more-btn small { color: var(--muted); font-size: 13px; }

/* Einkaufsliste drucken / als PDF: nur #print-area, schwarz auf weiß, zwei Spalten */
#print-area { display: none; }
@media print {
  @page { margin: 12mm; }
  html.printing, html.printing body { background: #fff !important; color: #000; min-height: 0; }
  html.printing body::before, html.printing body::after { display: none !important; }
  html.printing body > :not(#print-area) { display: none !important; }
  html.printing #print-area { display: block; font: 10.5pt/1.3 -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; color: #000; }
  #print-area h1 { font-size: 18pt; margin: 0 0 2pt; }
  #print-area .pl-sub { margin: 0 0 10pt; color: #444; }
  #print-area .pl-sub b { color: #000; }
  #print-area .pl-groups { columns: 2; column-gap: 12mm; }
  #print-area .pl-group { break-inside: avoid; margin: 0 0 8pt; }
  #print-area h2 { font-size: 11pt; text-transform: uppercase; letter-spacing: .04em; margin: 0 0 3pt; padding-bottom: 2pt; border-bottom: 1pt solid #000; }
  #print-area ul { list-style: none; margin: 0; padding: 0; }
  #print-area li { display: flex; align-items: baseline; gap: 6pt; padding: 1.6pt 0; border-bottom: .5pt solid #ccc; }
  #print-area .pl-box { flex: none; width: 9pt; height: 9pt; border: 1pt solid #000; border-radius: 2pt; transform: translateY(1pt); }
  #print-area .pl-name { flex: 1; }
  #print-area .pl-amt { color: #333; white-space: nowrap; }
  #print-area .pl-foot { margin: 8pt 0 0; color: #777; font-size: 8.5pt; }
}
