/* Sprach-Tagebuch – Oberfläche.
   Leitplanken: Apple HIG (Tab-Leiste unten, 44-px-Ziele, Systemschrift, 17px Text, hell/dunkel nach System),
   HeyFox-Familie (Fuchs, Orange als einzige Aktionsfarbe), design-taste-frontend (keine Verläufe, keine Glas-
   effekte, keine Schatten auf ruhenden Flächen, Farbe auf Daten: die Farbe des Tages trägt die Ansicht). */

:root {
  --ground: #f4f5f7;
  --surface: #ffffff;
  --raised: #eceef2;
  --press: #e2e5ea;
  --border: #e3e6eb;
  --text: #1d2330;
  --muted: #5a6372;          /* 5,6:1 auf --ground */
  --primary: #c94b0a;        /* HeyFox-Orange, weißer Text 4,7:1 */
  --primary-press: #ad4009;
  --on-primary: #ffffff;
  --fox: #f26b1d;
  --danger: #b42318;
  --focus: #c94b0a;
  --day: #9aa0a6;            /* wird je Tag gesetzt */
  --on-day: #ffffff;

  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --serif: ui-serif, "New York", "Iowan Old Style", "Source Serif Pro", Georgia, serif;

  --r-card: 18px;
  --r-photo: 14px;
  --pad: 20px;
  --tabbar: 58px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --ground: #000000;
    --surface: #141414;
    --raised: #222224;
    --press: #2c2c2e;
    --border: #2a2a2c;
    --text: #f4f4f5;
    --muted: #a7a7ad;
    --primary: #ff7a33;        /* auf Dunkel mit dunkler Schrift: 7,9:1 */
    --primary-press: #f26b1d;
    --on-primary: #1a0c03;
    --focus: #ff7a33;
    --danger: #ff6b5e;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0; background: var(--ground); color: var(--text);
  font: 17px/1.45 var(--sans); -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
img { display: block; max-width: 100%; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 10px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.ico { flex: none; }
.grow { flex: 1; min-width: 0; }
a.btn, a.pick, a.row, a.iconbtn { text-decoration: none; }
.icw { display: inline-flex; }

/* ---------- Rahmen ---------- */
.screen {
  max-width: 640px; margin: 0 auto;
  padding: calc(var(--safe-t) + 18px) var(--pad) calc(var(--tabbar) + var(--safe-b) + 32px);
  min-height: 100dvh;
}
.screen.plain { padding-bottom: calc(var(--safe-b) + 32px); }
.head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin: 8px 0 22px; }
.head h1 { font-size: 32px; line-height: 1.1; letter-spacing: -0.02em; font-weight: 700; margin: 0; }
.head .sub { color: var(--muted); font-size: 15px; margin: 4px 0 0; }
.topbar {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  min-height: 44px; margin: 0 -8px 8px;
}
.iconbtn {
  min-width: 44px; height: 44px; padding: 0 10px; border: 0; background: transparent; color: var(--primary);
  display: inline-flex; align-items: center; justify-content: center; gap: 4px; border-radius: 12px; font-size: 17px;
}
.iconbtn:active { background: var(--raised); }
.iconbtn.quiet { color: var(--text); }

/* ---------- Tab-Leiste ---------- */
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  background: var(--surface); border-top: 1px solid var(--border);
  padding-bottom: var(--safe-b);
}
.tabbar nav { max-width: 640px; margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr); }
.tabbar a {
  height: var(--tabbar); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  color: var(--muted); text-decoration: none; font-size: 11px; font-weight: 500;
}
.tabbar a[aria-current="page"] { color: var(--primary); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 50px; padding: 0 22px; border-radius: 999px; border: 0;
  background: var(--primary); color: var(--on-primary); font-weight: 600; font-size: 17px;
  transition: transform .12s ease, background-color .12s ease;
}
.btn:active { transform: scale(.98); background: var(--primary-press); }
.btn.block { width: 100%; }
.btn.secondary { background: var(--raised); color: var(--text); }
.btn.secondary:active { background: var(--press); }
.btn.plain { background: transparent; color: var(--primary); min-height: 44px; padding: 0 12px; }
.btn[disabled] { opacity: .5; pointer-events: none; }
.btn.danger { background: transparent; color: var(--danger); }

/* ---------- Karten & Gruppen ---------- */
.card { background: var(--surface); border-radius: var(--r-card); padding: 20px; }
.card + .card, .card + .section, .section + .card { margin-top: 16px; }
.section { margin-top: 28px; }
.section > h2 { font-size: 20px; font-weight: 700; letter-spacing: -0.01em; margin: 0 0 12px; }
.lead { font-size: 15px; color: var(--muted); margin: 0; }

.group { background: var(--surface); border-radius: var(--r-card); overflow: hidden; }
.group + .group { margin-top: 20px; }
.group-title { font-size: 13px; color: var(--muted); margin: 26px 4px 8px; }
.row {
  display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 10px 16px;
  border-top: 1px solid var(--border); background: transparent; width: 100%; text-align: left; border-left: 0; border-right: 0; border-bottom: 0;
}
.row:first-child { border-top: 0; }
button.row:active, a.row:active { background: var(--raised); }
.row .grow { flex: 1; min-width: 0; }
.row .val { color: var(--muted); }
.select { border: 0; border-radius: 10px; background: var(--raised); min-height: 40px; padding: 0 12px; font-size: 17px; color: var(--text); }
.row input[type="time"], .row input[type="text"] {
  border: 0; background: transparent; text-align: right; min-height: 40px; color: var(--text); min-width: 0;
}
.row input[type="text"] { text-align: left; flex: 1; }
.seg { display: inline-flex; background: var(--raised); border-radius: 10px; padding: 2px; }
.seg button { border: 0; background: transparent; min-height: 36px; padding: 0 12px; border-radius: 8px; font-size: 15px; }
.seg button[aria-pressed="true"] { background: var(--surface); font-weight: 600; }
@media (prefers-color-scheme: dark) { .seg button[aria-pressed="true"] { background: var(--press); } }
.switch { position: relative; width: 51px; height: 31px; flex: none; }
.switch input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.switch span { position: absolute; inset: 0; border-radius: 99px; background: var(--press); transition: background .15s; }
.switch span::after { content: ""; position: absolute; top: 2px; left: 2px; width: 27px; height: 27px; border-radius: 50%; background: #fff; transition: transform .15s; }
.switch input:checked + span { background: #34c759; }
.switch input:checked + span::after { transform: translateX(20px); }
.switch input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 2px; }
.note { font-size: 13px; color: var(--muted); margin: 8px 4px 0; }

/* ---------- Heute ---------- */
/* Einrichtungs-Schritte: Symbol | Text (+ Hinweis) | Button */
.step { display: grid; grid-template-columns: 28px 1fr auto; gap: 10px; align-items: center; min-height: 56px; padding: 8px 0; border-top: 1px solid var(--border); }
.step .done { color: var(--muted); text-decoration: line-through; }
.step .hint { font-size: 13px; color: var(--muted); margin-top: 2px; }
.step .btn.plain { padding: 0 4px; }
/* Moment festhalten: immer erreichbar (über der Navigation) + Plus oben rechts */
.quick { position: fixed; left: 0; right: 0; bottom: calc(var(--tabbar) + var(--safe-b) + 12px); z-index: 19; display: flex; justify-content: center; pointer-events: none; }
.quick .btn { pointer-events: auto; box-shadow: 0 6px 20px rgba(0,0,0,.22); min-height: 54px; padding: 0 26px; }
.screen.has-quick { padding-bottom: calc(var(--tabbar) + var(--safe-b) + 96px); }
.headtools { display: flex; align-items: center; gap: 2px; margin-right: -8px; }
.iconbtn.plus { color: var(--primary); }
.talkcard { display: grid; grid-template-columns: 64px 1fr; gap: 16px; align-items: start; }
.fox { width: 64px; height: 64px; }
.fox.sm { width: 40px; height: 40px; }
.talkcard h2 { font-size: 22px; line-height: 1.2; margin: 2px 0 6px; letter-spacing: -0.01em; }
.talkcard .actions { grid-column: 1 / -1; display: flex; align-items: center; gap: 12px; margin-top: 4px; }
.talkcard .actions .meta { color: var(--muted); font-size: 15px; }
.donecard { display: block; text-decoration: none; color: inherit; padding: 0; overflow: hidden; }
.donecard .band { height: 72px; background: var(--day); }
.donecard .inner { padding: 16px 20px 20px; }
.donecard h2 { font-size: 22px; margin: 0 0 6px; letter-spacing: -0.01em; }
.donecard p { font-family: var(--serif); margin: 0; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.moments { display: grid; gap: 10px; }
.moment {
  display: grid; grid-template-columns: 1fr auto; gap: 10px; align-items: center;
  background: var(--surface); border-radius: var(--r-card); padding: 10px 12px 10px 10px; min-height: 96px;
}
.moment .open {
  display: grid; grid-template-columns: 76px 1fr auto; gap: 14px; align-items: center; width: 100%; min-width: 0;
  border: 0; background: transparent; color: inherit; text-align: left; padding: 0; border-radius: 12px;
}
.moment.has-sound .open { grid-template-columns: 76px 1fr; }
.moment .ttl { font-weight: 600; line-height: 1.3; overflow-wrap: anywhere; }
.moment .dots.side { width: 44px; justify-content: center; }
.moment .thumb { width: 76px; height: 76px; border-radius: 12px; object-fit: cover; background: var(--raised); }
.moment .noimg { width: 76px; height: 76px; border-radius: 12px; background: var(--raised); display: grid; place-items: center; color: var(--muted); }
.moment .noimg.snd { color: var(--text); }
.moment .txt { font-size: 15px; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.moment .when { font-size: 13px; color: var(--muted); margin-bottom: 2px; }
.moment .quiet { color: var(--muted); }
.empty { color: var(--muted); font-size: 15px; margin: 0 0 14px; }
.cta-row { display: flex; gap: 10px; margin-top: 14px; }

/* ---------- Blatt (Sheet) ---------- */
.scrim { position: fixed; inset: 0; background: rgba(0,0,0,.35); z-index: 40; animation: fade .2s ease; }
.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 41; max-height: 92dvh; overflow: auto;
  background: var(--surface); border-radius: 22px 22px 0 0; padding: 8px var(--pad) calc(var(--safe-b) + 20px);
  box-shadow: 0 -8px 30px rgba(0,0,0,.18); animation: up .25s cubic-bezier(.2,.8,.2,1);
  max-width: 640px; margin: 0 auto;
}
.sheet .grab { width: 36px; height: 5px; border-radius: 3px; background: var(--press); margin: 0 auto 10px; }
.sheet h2 { font-size: 22px; margin: 6px 0 16px; letter-spacing: -0.01em; }
.sheet .head2 { display: flex; align-items: center; justify-content: space-between; }
.pickers { display: grid; gap: 10px; }
.pick {
  display: flex; align-items: center; gap: 14px; min-height: 60px; padding: 0 18px; border-radius: 16px;
  background: var(--raised); border: 0; font-size: 17px; font-weight: 600; width: 100%; text-align: left;
}
.pick:active { background: var(--press); }
.pick .ico { color: var(--primary); }
.pick .pk { display: grid; gap: 1px; padding: 9px 0; }
.pick .pk small { font-size: 13px; font-weight: 400; color: var(--muted); line-height: 1.3; }
.sheetlead { margin: -8px 0 4px; }
.formstack { display: grid; gap: 12px; margin-top: 12px; }
.subhead { font-size: 17px; margin: 18px 0 0; }
.row.toggle { padding-left: 0; padding-right: 0; border-top: 0; gap: 14px; }
.row.toggle small { display: block; font-size: 13px; color: var(--muted); line-height: 1.3; margin-top: 2px; }
.preview { width: 100%; max-height: 46dvh; object-fit: contain; border-radius: var(--r-photo); background: var(--raised); }
@keyframes up { from { transform: translateY(100%); } to { transform: none; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

/* ---------- Aufnahme ---------- */
.recorder { display: grid; justify-items: center; gap: 10px; padding: 14px 0 4px; }
.recbtn {
  position: relative; width: 84px; height: 84px; border-radius: 50%; border: 0;
  background: var(--primary); color: var(--on-primary); display: grid; place-items: center;
  transition: transform .12s ease;
}
.recbtn:active { transform: scale(.96); }
.recbtn .ring {
  position: absolute; inset: -8px; border-radius: 50%; border: 3px solid var(--primary); opacity: .35;
  transform: scale(var(--lvl, 1)); transition: transform .08s linear; pointer-events: none;
}
.recbtn.live { background: var(--danger); }
.recbtn.live .ring { border-color: var(--danger); }
.reclabel { font-size: 15px; color: var(--muted); min-height: 22px; }
.timer { font-variant-numeric: tabular-nums; font-weight: 600; color: var(--text); }
.alt { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }
.typebox { display: grid; gap: 10px; }
textarea {
  width: 100%; min-height: 110px; resize: vertical; border: 0; border-radius: 14px; padding: 14px;
  background: var(--raised); font-size: 17px; line-height: 1.45;
}
input.field {
  width: 100%; min-height: 50px; border: 0; border-radius: 14px; padding: 0 14px; background: var(--raised); font-size: 17px;
}

/* ---------- Gespräch ---------- */
.talk { display: flex; flex-direction: column; min-height: 100dvh; max-width: 640px; margin: 0 auto; }
.talk .bar {
  position: sticky; top: 0; z-index: 5; background: var(--ground);
  display: flex; align-items: center; justify-content: space-between;
  padding: calc(var(--safe-t) + 6px) 12px 6px;
}
.talk .bar .prog { font-size: 15px; color: var(--muted); font-variant-numeric: tabular-nums; padding-right: 8px; }
.chat { flex: 1; padding: 8px var(--pad) 16px; display: flex; flex-direction: column; gap: 14px; }
.msg { display: flex; gap: 8px; align-items: flex-end; max-width: 100%; }
.msg .fox { flex: none; }
.msg.me { justify-content: flex-end; }
.bubble { border-radius: 20px; padding: 12px 16px; max-width: 80%; min-width: 0; font-size: 17px; line-height: 1.4; overflow-wrap: anywhere; }
.bubble.wide { width: 80%; }
.msg .say { min-width: 36px; height: 36px; padding: 0; color: var(--muted); align-self: flex-end; }
.msg.buddy .bubble { background: var(--surface); border-bottom-left-radius: 6px; }
.msg.buddy .bubble.q { font-size: 21px; line-height: 1.3; font-weight: 600; letter-spacing: -0.01em; }
.msg.me .bubble { background: var(--raised); border-bottom-right-radius: 6px; }
.msg.me .bubble.wait { color: var(--muted); }
.bubble .ack { display: block; font-size: 15px; font-weight: 400; color: var(--muted); margin-bottom: 4px; }
.bubble img { border-radius: 12px; margin-top: 10px; width: 100%; max-height: 44dvh; object-fit: cover; }
.bubble .tools { display: flex; gap: 4px; margin: 6px -8px -6px; }
.bubble .tools button { border: 0; background: transparent; color: var(--primary); min-height: 36px; padding: 0 8px; font-size: 15px; border-radius: 8px; display: inline-flex; align-items: center; gap: 4px; }
.dots { display: inline-flex; gap: 4px; }
.dots i { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); animation: blink 1.2s infinite ease-in-out; }
.dots i:nth-child(2) { animation-delay: .2s; } .dots i:nth-child(3) { animation-delay: .4s; }
@keyframes blink { 0%, 80%, 100% { opacity: .25; } 40% { opacity: 1; } }
.dock {
  position: sticky; bottom: 0; background: var(--ground); padding: 10px var(--pad) calc(var(--safe-b) + 14px);
  border-top: 1px solid var(--border);
}
.moods { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.moods button {
  border: 0; background: var(--surface); border-radius: 14px; min-height: 64px; padding: 8px 2px;
  display: grid; justify-items: center; gap: 4px; font-size: 13px; color: var(--text);
}
.moods button .n { font-size: 22px; font-weight: 700; }
.moods button:active { background: var(--press); }
.colors { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; margin-bottom: 12px; }
.colors button {
  aspect-ratio: 1; border-radius: 50%; border: 0; min-height: 44px; position: relative;
}
.colors button[aria-pressed="true"]::after {
  content: ""; position: absolute; inset: -5px; border-radius: 50%; border: 3px solid var(--text);
}
.kid .msg.buddy .bubble.q { font-size: 24px; }
.kid .recbtn { width: 104px; height: 104px; }
.kid .moods button { min-height: 84px; }

/* ---------- Tag (Eintrag) ---------- */
.dayhead { background: var(--day); color: var(--on-day); margin: 0; padding: calc(var(--safe-t) + 8px) 12px 22px; }
.dayhead .inner { max-width: 640px; margin: 0 auto; }
.dayhead .topbar { margin: 0 0 18px; }
.dayhead .iconbtn { color: var(--on-day); }
.dayhead .iconbtn:active { background: rgba(255,255,255,.18); }
.dayhead .date { font-size: 15px; font-weight: 600; padding: 0 8px; opacity: .92; }
.dayhead h1 { font-size: 30px; line-height: 1.12; letter-spacing: -0.02em; margin: 6px 8px 0; font-weight: 700; }
.daybody { max-width: 640px; margin: 0 auto; padding: 22px var(--pad) calc(var(--tabbar) + var(--safe-b) + 40px); }
.facts { display: flex; flex-wrap: wrap; gap: 6px 18px; color: var(--muted); font-size: 15px; margin: 0 0 18px; }
.facts b { color: var(--text); font-weight: 600; }
.prose { font-family: var(--serif); font-size: 19px; line-height: 1.6; }
.prose p { margin: 0 0 1em; }
.prose figure { margin: 22px calc(var(--pad) * -1); }
.prose figure img { width: 100%; border-radius: 0; }
@media (min-width: 680px) { .prose figure { margin: 26px 0; } .prose figure img { border-radius: var(--r-photo); } }
.prose figcaption { font-family: var(--sans); font-size: 13px; color: var(--muted); padding: 8px var(--pad) 0; }
@media (min-width: 680px) { .prose figcaption { padding: 8px 0 0; } }
.state { display: grid; justify-items: start; gap: 12px; padding: 8px 0 18px; color: var(--muted); }
.skel { height: 18px; border-radius: 6px; background: var(--raised); margin: 0 0 12px; }
.skel.w80 { width: 80%; } .skel.w60 { width: 60%; } .skel.w90 { width: 90%; }
.words { margin-top: 30px; }
.words details { background: var(--surface); border-radius: var(--r-card); }
.words summary { list-style: none; min-height: 52px; padding: 0 16px; display: flex; align-items: center; justify-content: space-between; font-weight: 600; cursor: pointer; }
.words summary::-webkit-details-marker { display: none; }
.words .qa { padding: 12px 16px; border-top: 1px solid var(--border); }
.words .qa .q { font-size: 13px; color: var(--muted); margin-bottom: 4px; }
.words .qa .a { font-size: 15px; }
/* ---------- Tonaufnahme (Andenken) ---------- */
.sp {
  display: grid; grid-template-columns: 56px 1fr; gap: 14px; align-items: center;
  background: var(--surface); border-radius: var(--r-card); padding: 12px 16px 12px 12px; font-family: var(--sans);
}
.sheet .sp, .soundrec .sp { background: var(--raised); }
.sp-btn {
  width: 56px; height: 56px; border-radius: 50%; border: 0; display: grid; place-items: center;
  background: var(--primary); color: var(--on-primary); transition: transform .12s ease;
}
.sp-btn:active { transform: scale(.96); }
.sp-btn:disabled { background: var(--raised); color: var(--muted); }
.sheet .sp-btn:disabled { background: var(--press); }
.sp-txt { min-width: 0; }
.sp-title { font-size: 17px; font-weight: 600; line-height: 1.3; overflow-wrap: anywhere; }
.sp-meta { display: flex; align-items: center; gap: 10px; margin-top: 6px; font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; min-height: 18px; }
.sp-time:empty { display: none; }
.sp-bar { flex: 1; height: 4px; border-radius: 2px; background: var(--press); overflow: hidden; }
.sp-bar i { display: block; height: 100%; width: var(--p, 0%); background: var(--primary); }
.playround {
  width: 44px; height: 44px; flex: none; border-radius: 50%; border: 0; display: grid; place-items: center;
  background: var(--primary); color: var(--on-primary);
}
.playround:active { transform: scale(.96); }
.soundrec { margin-top: 4px; }
.soundrec .alt { margin-top: 6px; }
.soundbox { display: grid; gap: 12px; margin-top: 14px; }
.transcript { font-size: 15px; line-height: 1.45; }
.transcript .q { font-size: 13px; color: var(--muted); margin-bottom: 2px; }
.prose .soundfig { margin: 22px 0; }
.bubble .sp { margin-top: 10px; background: var(--raised); font-size: 17px; font-weight: 400; letter-spacing: 0; }
.bubble .sp .sp-title { font-size: 17px; }

/* ---------- Vergessene Tage ---------- */
.opencard h2 { font-size: 20px; margin: 0 0 4px; }
.openrows { display: grid; margin: 12px -8px 0; }
.openrow {
  display: grid; grid-template-columns: 44px 1fr auto; gap: 12px; align-items: center; min-height: 60px; padding: 8px;
  border-radius: 12px; color: inherit; text-decoration: none;
}
.openrow:active { background: var(--raised); }
.openrow img, .openrow .ph { width: 44px; height: 44px; border-radius: 10px; object-fit: cover; background: var(--raised); display: grid; place-items: center; color: var(--muted); }
.openrow .d { display: block; font-weight: 600; }
.openrow .m { display: block; font-size: 13px; color: var(--muted); }
.openrow > .icw { color: var(--muted); }
.catchup { margin-top: 18px; }
.catchup h2 { font-size: 20px; margin: 0 0 4px; }
.catchup .pickers { margin-top: 14px; }
.talk .bar .pastday { font-size: 15px; font-weight: 600; }
.prose figure .sp { margin: 10px var(--pad) 0; }
@media (min-width: 680px) { .prose figure .sp { margin: 10px 0 0; } }

.audio { display: inline-flex; align-items: center; gap: 6px; border: 0; background: var(--raised); color: var(--text); border-radius: 99px; min-height: 36px; padding: 0 12px 0 8px; font-size: 13px; margin-top: 8px; font-variant-numeric: tabular-nums; }
.sharebox { margin-top: 18px; }
.editbox { display: grid; gap: 10px; }
.editbox textarea { min-height: 320px; font-family: var(--serif); }

/* ---------- Tagebuch (Zeitleiste) ---------- */
.month { margin-top: 24px; }
.month h2 { font-size: 20px; margin: 0 0 10px; letter-spacing: -0.01em; }
.strip { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; margin-bottom: 14px; max-width: 420px; }
.strip a, .strip span {
  aspect-ratio: 1; border-radius: 7px; background: var(--raised); display: grid; place-items: center;
  font-size: 13px; font-variant-numeric: tabular-nums; color: var(--muted); text-decoration: none;
}
.strip .wd { font-size: 12px; font-weight: 600; color: var(--muted); text-align: center; padding-bottom: 2px; }
.strip .pad { background: transparent; }
.strip a.has { background: var(--day); color: var(--on-day); font-weight: 600; }
.strip a.moments { color: var(--text); }
.strip a.moments { background: var(--press); }
.strip .today { box-shadow: inset 0 0 0 2px var(--text); }
.days { display: grid; gap: 8px; }
.dayrow {
  position: relative; display: grid; grid-template-columns: 6px 1fr auto; gap: 14px; align-items: center; color: inherit;
  background: var(--surface); border-radius: 16px; padding: 10px 10px 10px 0; min-height: 76px; overflow: hidden;
}
/* ganze Zeile führt zum Tag; der Abspiel-Button liegt darüber */
.dayrow .dl { color: inherit; text-decoration: none; min-width: 0; }
.dayrow .dl::after { content: ""; position: absolute; inset: 0; }
.dayrow .dl:focus-visible { outline: none; }
.dayrow:has(.dl:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; }
.dayrow .media { position: relative; z-index: 1; display: flex; align-items: center; gap: 10px; pointer-events: none; }
.dayrow .media .playround { pointer-events: auto; }
.dayrow .bar { align-self: stretch; background: var(--day); border-radius: 0 4px 4px 0; }
.dayrow .d { font-size: 13px; color: var(--muted); }
.dayrow .t { font-weight: 600; line-height: 1.3; }
.dayrow .t.quiet { font-weight: 400; color: var(--muted); }
.dayrow img, .dayrow .ph { width: 56px; height: 56px; border-radius: 10px; object-fit: cover; background: var(--raised); }

/* ---------- Anmeldung / Auswahl ---------- */
.welcome { display: grid; gap: 18px; padding-top: 10dvh; }
.welcome .fox { width: 88px; height: 88px; }
.welcome h1 { font-size: 32px; margin: 0; letter-spacing: -0.02em; }
.welcome p { margin: 0; color: var(--muted); }
/* Passwortfeld mit Auge-Symbol */
.pwbox { position: relative; }
.pwbox input.field { padding-right: 52px; }
.pwbox input::-ms-reveal { display: none; }
.pwbox .eye {
  position: absolute; right: 3px; top: 50%; transform: translateY(-50%); width: 44px; height: 44px;
  border: 0; border-radius: 10px; background: transparent; color: var(--muted); display: grid; place-items: center;
}
.pwbox .eye[aria-pressed="true"] { color: var(--text); }
.code { text-transform: uppercase; letter-spacing: .12em; font-variant-numeric: tabular-nums; text-align: center; font-size: 22px; }
.err { color: var(--danger); font-size: 15px; min-height: 22px; margin: 0; }
.who { display: grid; gap: 10px; }

/* ---------- Hinweis ---------- */
.toast {
  position: fixed; left: 50%; bottom: calc(var(--tabbar) + var(--safe-b) + 16px); transform: translateX(-50%);
  background: var(--text); color: var(--ground); padding: 12px 18px; border-radius: 14px; font-size: 15px; z-index: 60;
  box-shadow: 0 6px 24px rgba(0,0,0,.2); max-width: calc(100% - 32px); animation: fade .2s ease;
}
.help { border: 0; background: transparent; color: var(--muted); width: 44px; height: 44px; display: inline-grid; place-items: center; border-radius: 50%; }
.sheet .prose-s p { margin: 0 0 12px; font-size: 15px; line-height: 1.5; }

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