:root {
  --hg: #07060f;
  --flaeche: rgba(255, 255, 255, .055);
  --flaeche-stark: rgba(255, 255, 255, .09);
  --rand: rgba(255, 255, 255, .10);
  --text: #f1eeff;
  --text-leise: #a7a2c6;
  --akzent: #a996ff;
  --akzent-2: #ff9ad5;
  --gut: #6fe3c8;
  --warn: #ff8fa3;
  --stimmung-1: #6b4cff;
  --stimmung-2: #ff7ac8;
  --schrift: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --titel: "Fraunces", Georgia, serif;
  /* Diagramm-Farben (geprüft: unterscheidbar bei Farbschwäche, ≥3:1 auf dunklem Grund) */
  --reihe-1: #3987e5;
  --reihe-2: #d95926;
  --reihe-3: #199e70;
  color-scheme: dark;
}
body[data-stimmung="zuhoeren"] { --stimmung-1: #19b9a0; --stimmung-2: #6fe3c8; }
body[data-stimmung="denken"]   { --stimmung-1: #ff8a3d; --stimmung-2: #ffcf7a; }
body[data-stimmung="sprechen"] { --stimmung-1: #8b4dff; --stimmung-2: #ff7ad9; }
body[data-stimmung="fehler"]   { --stimmung-1: #4c4870; --stimmung-2: #7b7698; }

* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  background: var(--hg);
  color: var(--text);
  font: 16px/1.5 var(--schrift);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overflow: hidden;
}
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
svg { fill: currentColor; }

/* ---------- Hintergrund: weiches Polarlicht in Vanvans Stimmung ---------- */
.aurora { position: fixed; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.aurora i {
  position: absolute; width: 70vmax; height: 70vmax; border-radius: 50%;
  filter: blur(90px); opacity: .30; transition: background 1.2s ease;
  animation: wandern 22s ease-in-out infinite alternate;
}
.aurora i:nth-child(1) { background: var(--stimmung-1); left: -22vmax; top: -28vmax; }
.aurora i:nth-child(2) { background: var(--stimmung-2); right: -28vmax; top: 8vmax; animation-duration: 28s; opacity: .16; }
.aurora i:nth-child(3) { background: var(--stimmung-1); left: 8vmax; bottom: -44vmax; animation-duration: 34s; opacity: .14; }
@keyframes wandern { to { transform: translate(6vmax, 4vmax) scale(1.08); } }

.glas {
  background: var(--flaeche);
  border: 1px solid var(--rand);
  -webkit-backdrop-filter: blur(22px) saturate(140%);
  backdrop-filter: blur(22px) saturate(140%);
}

.ansicht { position: relative; z-index: 1; height: 100dvh; }

/* ---------- Anmeldung ---------- */
#anmeldung { display: grid; place-items: center; padding: 16px; }
.anmelde-karte { width: min(400px, 100%); border-radius: 28px; padding: 26px 24px 22px; text-align: center; }
.mini-orb { width: 110px; height: 110px; }
.anmelde-karte h1 { font: 500 34px/1.1 var(--titel); margin: 4px 0 6px; letter-spacing: .2px; }
.anmelde-karte p { color: var(--text-leise); margin: 0 0 20px; }
#anmelde-form { display: flex; flex-direction: column; gap: 10px; }
#anmelde-form input {
  padding: 14px 16px; border-radius: 14px; border: 1px solid var(--rand); background: rgba(0,0,0,.25); outline: none;
}
#anmelde-form input:focus { border-color: var(--akzent); }
.haupt-knopf {
  padding: 13px 18px; border: 0; border-radius: 14px; font-weight: 600; color: #120d2b;
  background: linear-gradient(135deg, #d3c9ff, var(--akzent) 45%, var(--akzent-2));
  box-shadow: 0 8px 30px -10px var(--akzent);
}
.haupt-knopf:active { transform: translateY(1px); }
.fehlertext { color: var(--warn) !important; min-height: 1.5em; margin: 12px 0 0 !important; }

/* ---------- Hauptansicht ---------- */
#app {
  display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr) auto;
  padding: env(safe-area-inset-top) 0 0;
}
#haupt, .bereich { grid-row: 1; grid-column: 1; min-height: 0; min-width: 0; }
#haupt {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto minmax(210px, 43%) minmax(0, 1fr);
}
.kopf { display: flex; align-items: center; gap: 8px; padding: 10px 12px 0 18px; }
.marke { display: flex; align-items: center; gap: 9px; }
.punkt { width: 8px; height: 8px; border-radius: 50%; background: var(--gut); box-shadow: 0 0 12px var(--gut); transition: background .3s, box-shadow .3s; }
.punkt.aus { background: var(--warn); box-shadow: 0 0 12px var(--warn); }
.name { font: 500 21px/1 var(--titel); letter-spacing: .3px; }
.demo-schild { font-size: 11px; font-weight: 600; letter-spacing: .6px; text-transform: uppercase; padding: 3px 8px; border-radius: 999px; background: var(--flaeche-stark); color: var(--akzent); }
.kopf-knoepfe { margin-left: auto; display: flex; align-items: center; gap: 2px; }
.symbol-knopf { width: 42px; height: 42px; border-radius: 14px; border: 0; background: transparent; display: grid; place-items: center; color: var(--text-leise); }
.symbol-knopf svg { width: 22px; height: 22px; }
.symbol-knopf:hover { color: var(--text); background: var(--flaeche); }
.text-knopf { border: 1px solid var(--rand); background: var(--flaeche); border-radius: 999px; padding: 7px 13px; font-size: 14px; }

.buehne { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 0; padding: 0 16px; }
.orb { width: min(80vw, 360px, 34dvh); aspect-ratio: 1; cursor: pointer; outline: none; touch-action: manipulation; }
.status {
  margin: 2px 0 0; color: var(--text-leise); text-align: center; min-height: 1.5em; font-size: 15px;
  max-width: 36ch; transition: opacity .3s;
}
.tastenhinweis { display: none; margin: 8px 0 0; font-size: 12.5px; color: var(--text-leise); opacity: .75; }
kbd { font: 11.5px/1 ui-monospace, SFMono-Regular, monospace; padding: 3px 6px; border: 1px solid var(--rand); border-radius: 6px; background: var(--flaeche); }

/* ---------- Gespräch ---------- */
.gespraech { display: grid; grid-template-rows: minmax(0, 1fr) auto auto; min-height: 0; padding: 0 14px 12px; gap: 8px; }
.verlauf {
  overflow-y: auto; display: flex; flex-direction: column; gap: 10px; padding: 14px 4px 6px;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 28px);
  mask-image: linear-gradient(to bottom, transparent 0, #000 28px);
  scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.15) transparent;
}
.blase {
  max-width: 86%; padding: 10px 14px; border-radius: 20px; white-space: pre-wrap; overflow-wrap: anywhere;
  animation: auftauchen .35s cubic-bezier(.2,.8,.2,1);
}
@keyframes auftauchen { from { opacity: 0; transform: translateY(8px) scale(.98); } }
.blase.ich { align-self: flex-end; background: linear-gradient(135deg, rgba(169,150,255,.30), rgba(255,154,213,.20)); border: 1px solid rgba(255,255,255,.12); border-bottom-right-radius: 7px; }
.blase.vanvan { align-self: flex-start; background: var(--flaeche); border: 1px solid var(--rand); border-bottom-left-radius: 7px; }
.blase.vanvan.schreibt .inhalt::after { content: "▍"; color: var(--akzent); animation: blinken 1s steps(2) infinite; margin-left: 1px; }
@keyframes blinken { 50% { opacity: 0; } }
.blase.system { align-self: center; background: transparent; color: var(--text-leise); font-size: 14px; text-align: center; max-width: 92%; }
.blase.fehler { align-self: center; color: var(--warn); font-size: 14px; background: rgba(255,143,163,.08); border: 1px solid rgba(255,143,163,.25); }
.aktionen { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.aktionen:empty { display: none; }
.chip { font-size: 12.5px; padding: 3px 10px; border-radius: 999px; background: var(--flaeche-stark); color: #ddd6ff; border: 1px solid var(--rand); }
.denkt { display: inline-flex; gap: 5px; padding: 6px 2px; }
.denkt i { width: 7px; height: 7px; border-radius: 50%; background: var(--akzent); opacity: .4; animation: huepfen 1.2s infinite; }
.denkt i:nth-child(2) { animation-delay: .15s; } .denkt i:nth-child(3) { animation-delay: .3s; }
@keyframes huepfen { 30% { opacity: 1; transform: translateY(-4px); } }

.vorschlaege { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 4px; scrollbar-width: none; }
.vorschlaege::-webkit-scrollbar { display: none; }
.vorschlaege:empty { display: none; }
.vorschlag {
  flex: none; border: 1px solid var(--rand); background: var(--flaeche); border-radius: 999px; padding: 8px 14px; font-size: 14px;
  transition: background .2s, border-color .2s;
}
.vorschlag:hover { background: var(--flaeche-stark); border-color: rgba(169,150,255,.4); }

.eingabe { display: flex; align-items: center; gap: 4px; padding: 6px 6px 6px 18px; border-radius: 999px; }
.eingabe input { flex: 1; min-width: 0; border: 0; background: transparent; outline: none; padding: 10px 0; }
.eingabe input::placeholder { color: var(--text-leise); }
.senden, .mikro { flex: none; width: 46px; height: 46px; border-radius: 50%; border: 0; display: grid; place-items: center; position: relative; }
.senden { background: transparent; color: var(--text-leise); }
.senden svg { width: 21px; height: 21px; }
.senden:not(:disabled):hover { color: var(--text); }
.mikro { color: #120d2b; background: linear-gradient(135deg, #d3c9ff, var(--akzent) 45%, var(--akzent-2)); box-shadow: 0 8px 26px -8px var(--akzent); }
.mikro svg { width: 23px; height: 23px; position: relative; z-index: 1; }
.mikro-ring { position: absolute; inset: -5px; border-radius: 50%; border: 2px solid var(--gut); opacity: 0; }
.mikro.aktiv { background: linear-gradient(135deg, #c8fff4, var(--gut)); box-shadow: 0 8px 30px -6px var(--gut); }
.mikro.aktiv .mikro-ring { animation: ring 1.4s ease-out infinite; }
@keyframes ring { from { transform: scale(.95); opacity: .9; } to { transform: scale(1.35); opacity: 0; } }
button:disabled { opacity: .45; cursor: default; }
:focus-visible { outline: 2px solid var(--akzent); outline-offset: 2px; }

/* ---------- Einstellungen ---------- */
.blatt {
  width: min(460px, calc(100vw - 32px)); border-radius: 26px; padding: 22px; color: var(--text);
  background: rgba(20, 17, 38, .86);
}
.blatt::backdrop { background: rgba(4, 3, 10, .55); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.blatt h2 { font: 500 24px/1.2 var(--titel); margin: 0 0 8px; }
.zeile { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--rand); }
.zeile small { display: block; color: var(--text-leise); font-size: 13px; margin-top: 2px; }
.zeile select { max-width: 52%; padding: 8px 10px; border-radius: 10px; border: 1px solid var(--rand); background: rgba(0,0,0,.35); }
.zeile input[type=range] { width: 46%; accent-color: var(--akzent); }
.zeile.knoepfe { flex-wrap: wrap; justify-content: flex-start; gap: 8px; border-bottom: 0; }
.neben-knopf { border: 1px solid var(--rand); background: var(--flaeche); border-radius: 12px; padding: 8px 12px; font-size: 14px; }
.neben-knopf.warn { color: var(--warn); }
.blatt .haupt-knopf { width: 100%; margin-top: 8px; }
.schalter { appearance: none; -webkit-appearance: none; width: 48px; height: 28px; border-radius: 999px; background: rgba(255,255,255,.15); position: relative; flex: none; transition: background .2s; cursor: pointer; margin: 0; }
.schalter::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; transition: transform .2s; }
.schalter:checked { background: var(--gut); }
.schalter:checked::after { transform: translateX(20px); }

/* ---------- PC: Vanvan links, Gespräch rechts ---------- */
@media (min-width: 920px) {
  #haupt {
    grid-template-columns: minmax(380px, 1fr) minmax(440px, 600px);
    grid-template-rows: auto minmax(0, 1fr);
    max-width: 1480px; margin: 0 auto;
  }
  .kopf { grid-column: 1 / -1; padding: 16px 26px 4px 30px; }
  .buehne { grid-column: 1; grid-row: 2; padding-bottom: 40px; }
  .orb { width: min(40vw, 480px, 62dvh); }
  .status { font-size: 17px; max-width: 46ch; }
  .tastenhinweis { display: block; }
  .gespraech { grid-column: 2; grid-row: 2; padding: 12px 26px 24px 8px; }
  .verlauf { padding-right: 8px; }
}

@media (prefers-reduced-motion: reduce) {
  .aurora i, .mikro.aktiv .mikro-ring, .blase, .denkt i { animation: none !important; }
}

/* ---------- Heute-Karte ---------- */
.heute { align-self: stretch; border-radius: 20px; padding: 14px 16px; display: grid; gap: 10px; animation: auftauchen .4s cubic-bezier(.2,.8,.2,1); }
.heute-kopf { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.heute-kopf strong { font: 500 18px/1.2 var(--titel); }
.heute-kopf span { color: var(--text-leise); font-size: 13px; }
.heute ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.heute li { display: flex; gap: 10px; align-items: baseline; font-size: 15px; min-width: 0; }
.heute li::before { content: ""; flex: none; width: 14px; height: 14px; border-radius: 5px; border: 1.5px solid var(--akzent); transform: translateY(2px); }
.heute .mehr { color: var(--text-leise); font-size: 13px; }
.heute .leer { color: var(--text-leise); font-size: 14px; }
.heute-frage { display: flex; align-items: center; gap: 10px; justify-content: space-between; padding-top: 10px; border-top: 1px solid var(--rand); font-size: 15px; }
.heute-frage p { margin: 0; min-width: 0; }
.heute-frage small { display: block; color: var(--text-leise); font-size: 12px; letter-spacing: .4px; text-transform: uppercase; }
.heute-frage button { flex: none; }
.beispiel { font-size: 11px; color: var(--akzent); letter-spacing: .5px; text-transform: uppercase; }

.wach-schild { font-size: 12px; padding: 3px 9px; border-radius: 999px; background: rgba(111,227,200,.12); color: var(--gut); border: 1px solid rgba(111,227,200,.3); animation: puls 2.4s ease-in-out infinite; }
@keyframes puls { 50% { opacity: .55; } }
.kosten { font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
@media (max-width: 420px) { .wach-schild { display: none; } }
@media (prefers-reduced-motion: reduce) { .wach-schild, .heute { animation: none !important; } }

/* ---------- 👍 / 👎 ---------- */
.bewertung { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 6px; }
.daumen { width: 30px; height: 30px; border-radius: 10px; border: 0; background: transparent; color: var(--text-leise); display: grid; place-items: center; opacity: .55; transition: opacity .2s, background .2s, color .2s; }
.daumen svg { width: 16px; height: 16px; }
.daumen.runter svg { transform: rotate(180deg) scaleX(-1); }
.daumen:hover, .daumen:focus-visible { opacity: 1; background: var(--flaeche-stark); color: var(--text); }
.blase.vanvan:hover .daumen { opacity: .9; }
.grund { border: 1px solid var(--rand); background: var(--flaeche); border-radius: 999px; padding: 4px 10px; font-size: 13px; }
.grund:hover { border-color: rgba(169,150,255,.45); background: var(--flaeche-stark); }
.bewertet { color: var(--text-leise); font-size: 13px; }

/* Im laufenden Gespräch macht Vanvan am Handy Platz */
@media (max-width: 919px) {
  #haupt { transition: grid-template-rows .45s cubic-bezier(.2,.8,.2,1); }
  #haupt.kompakt { grid-template-rows: auto minmax(150px, 27%) minmax(0, 1fr); }
  #haupt.kompakt .orb { width: min(60vw, 240px, 22dvh); }
  #haupt.kompakt .status { font-size: 14px; }
}

@media (max-width: 520px) {
  .zeile.stapel { flex-direction: column; align-items: stretch; gap: 8px; }
  .zeile.stapel select, .zeile.stapel input[type=range] { width: 100%; max-width: 100%; }
  .zeile.stapel .kosten { text-align: left; }
}

.version { text-align: center; color: var(--text-leise); font-size: 12px; margin: 10px 0 0; }
.blase.system.update { color: var(--text); background: var(--flaeche); border: 1px solid rgba(169,150,255,.35); border-radius: 18px; padding: 10px 14px; text-align: left; white-space: pre-line; }

.aussprache-reihe { display: flex; gap: 8px; align-items: center; min-width: 0; }
.aussprache-reihe input { flex: 1; min-width: 0; padding: 8px 10px; border-radius: 10px; border: 1px solid var(--rand); background: rgba(0,0,0,.35); }


/* =====================================================================
   Navigation – am Handy unten, am PC links
   ===================================================================== */
.navi {
  grid-row: 2; grid-column: 1; position: relative; z-index: 2;
  display: grid; grid-template-columns: repeat(6, minmax(0, 1fr));
  border-width: 1px 0 0; border-radius: 0; padding: 4px 4px calc(4px + env(safe-area-inset-bottom));
  background: rgba(14, 12, 28, .78);
}
.navi .navi-marke, .navi .navi-unten { display: none; }
.navi-knopf {
  position: relative; border: 0; background: transparent; color: var(--text-leise);
  display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 7px 0 5px; border-radius: 14px;
  font-size: 10.5px; font-weight: 500; letter-spacing: .1px; transition: color .2s, background .2s;
}
.navi-knopf svg { width: 23px; height: 23px; transition: transform .25s cubic-bezier(.2,.8,.2,1); }
.navi-knopf span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.navi-knopf:hover { color: var(--text); }
.navi-knopf[aria-current="page"] { color: var(--text); }
.navi-knopf[aria-current="page"] svg { color: var(--akzent); transform: translateY(-1px) scale(1.06); filter: drop-shadow(0 0 10px rgba(169,150,255,.55)); }
.navi-knopf[aria-current="page"]::before {
  content: ""; position: absolute; top: 0; left: 30%; right: 30%; height: 2.5px; border-radius: 0 0 3px 3px;
  background: linear-gradient(90deg, var(--akzent), var(--akzent-2));
}
.navi-zahl {
  position: absolute; top: 3px; left: calc(50% + 6px); min-width: 17px; height: 17px; padding: 0 5px; border-radius: 999px;
  background: var(--akzent-2); color: #2a0b20; font: 700 10.5px/17px var(--schrift); text-align: center;
}

@media (min-width: 920px) {
  #app { grid-template-columns: 92px minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); padding: 0; }
  #haupt, .bereich { grid-column: 2; }
  .navi {
    grid-row: 1; grid-column: 1; grid-template-columns: none; grid-auto-rows: max-content; align-content: start; gap: 4px;
    border-width: 0 1px 0 0; padding: 18px 10px; background: rgba(14, 12, 28, .55);
  }
  .navi .navi-marke {
    display: grid; place-items: center; width: 44px; height: 44px; margin: 0 auto 18px; border-radius: 15px;
    font: 500 22px/1 var(--titel); color: #120d2b; background: linear-gradient(135deg, #d3c9ff, var(--akzent) 45%, var(--akzent-2));
    box-shadow: 0 10px 30px -10px var(--akzent);
  }
  .navi-knopf { padding: 10px 0 8px; font-size: 11.5px; }
  .navi-knopf:hover { background: var(--flaeche); }
  .navi-knopf[aria-current="page"] { background: var(--flaeche-stark); }
  .navi-knopf[aria-current="page"]::before { top: 22%; bottom: 22%; left: -10px; right: auto; width: 3px; height: auto; border-radius: 0 3px 3px 0; }
  .navi .navi-unten { display: flex; position: absolute; left: 10px; right: 10px; bottom: 18px; }
  #haupt { padding-top: 0; }
  .nur-handy { display: none !important; }
}

/* =====================================================================
   Bereiche: Heute, Archiv, Über mich, Aufgaben, Status
   ===================================================================== */
.bereich { display: grid; grid-template-rows: auto minmax(0, 1fr); position: relative; z-index: 1; }
.bereich-kopf { display: flex; align-items: flex-end; gap: 8px; padding: 16px 16px 10px 20px; }
.bereich-kopf > div { flex: 1; min-width: 0; }
.bereich-ober { margin: 0 0 2px; color: var(--text-leise); font-size: 13px; letter-spacing: .3px; }
.bereich-kopf h1 { margin: 0; font: 500 30px/1.15 var(--titel); letter-spacing: .2px; }
#bereich-neu.dreht svg { animation: drehen .8s linear infinite; }
@keyframes drehen { to { transform: rotate(360deg); } }
.bereich-inhalt {
  overflow-y: auto; padding: 4px 14px 28px; display: grid; align-content: start; gap: 14px;
  scrollbar-width: thin; scrollbar-color: rgba(255,255,255,.15) transparent;
}
.bereich-inhalt > * { animation: auftauchen .35s cubic-bezier(.2,.8,.2,1) both; }
.bereich-inhalt > *:nth-child(2) { animation-delay: .04s; } .bereich-inhalt > *:nth-child(3) { animation-delay: .08s; }
@media (min-width: 920px) {
  .bereich-kopf { padding: 30px 40px 16px; width: 100%; max-width: 1180px; margin: 0 auto; }
  .bereich-kopf h1 { font-size: 38px; }
  .bereich-inhalt { padding: 4px 40px 40px; }
  .bereich-inhalt > * { width: 100%; max-width: 1100px; margin: 0 auto; }
}

.karte { border-radius: 22px; padding: 18px 18px 16px; min-width: 0; }
.karte-titel { display: flex; align-items: center; gap: 10px; margin: 0 0 12px; font: 600 13px/1.2 var(--schrift); letter-spacing: .6px; text-transform: uppercase; color: var(--text-leise); }
.karte-titel .zaehler { margin-left: auto; text-transform: none; letter-spacing: 0; font-weight: 500; }
.leer-hinweis { text-align: center; color: var(--text-leise); padding: 26px 12px; }
.leer-hinweis b { display: block; font: 500 20px/1.3 var(--titel); color: var(--text); margin-bottom: 4px; }
.leer-hinweis .gross { font-size: 34px; display: block; margin-bottom: 6px; }
.lade { display: grid; gap: 10px; }
.lade i { display: block; height: 14px; border-radius: 7px; background: linear-gradient(90deg, var(--flaeche) 0, var(--flaeche-stark) 50%, var(--flaeche) 100%); background-size: 200% 100%; animation: schimmer 1.3s linear infinite; }
.lade i:nth-child(1) { width: 40%; height: 22px; } .lade i:nth-child(3) { width: 85%; } .lade i:nth-child(4) { width: 60%; }
@keyframes schimmer { to { background-position: -200% 0; } }
.fehler-karte { border-color: rgba(255,143,163,.3); color: var(--warn); text-align: center; }

/* Kacheln (Status, Heute) */
.kacheln { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (min-width: 700px) { .kacheln { grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); } }
.kachel { border-radius: 18px; padding: 14px 14px 12px; display: grid; gap: 4px; min-width: 0; }
.kachel small { color: var(--text-leise); font-size: 12px; letter-spacing: .4px; text-transform: uppercase; }
.kachel strong { font: 500 19px/1.25 var(--titel); overflow-wrap: anywhere; }
.kachel span { color: var(--text-leise); font-size: 13px; }
.kachel.gut strong { color: var(--gut); } .kachel.warn strong { color: var(--warn); }

/* Reiter (Über mich, Status) und Filter (Archiv) */
.reiter { display: flex; gap: 6px; overflow-x: auto; padding: 2px; scrollbar-width: none; }
.reiter::-webkit-scrollbar { display: none; }
.reiter button {
  flex: none; border: 1px solid var(--rand); background: var(--flaeche); border-radius: 999px; padding: 7px 14px; font-size: 14px;
  color: var(--text-leise); transition: background .2s, color .2s, border-color .2s;
}
.reiter button:hover { color: var(--text); }
.reiter button[aria-selected="true"] { color: #120d2b; border-color: transparent; background: linear-gradient(135deg, #d3c9ff, var(--akzent) 60%, #d9b8ff); font-weight: 600; }
.reiter button em { font-style: normal; opacity: .7; margin-left: 4px; font-size: 12.5px; }

/* Liste + Leser (Archiv) */
.sammlung { display: grid; gap: 14px; align-items: start; }
.sammlung-liste { display: grid; gap: 12px; }
.suche { display: flex; align-items: center; gap: 8px; border-radius: 14px; padding: 0 12px; }
.suche svg { width: 18px; height: 18px; color: var(--text-leise); flex: none; }
.suche input { flex: 1; min-width: 0; border: 0; outline: none; background: transparent; padding: 11px 0; }
.gruppe { display: grid; gap: 6px; }
.gruppe h3 { margin: 8px 4px 0; font-size: 12.5px; font-weight: 600; letter-spacing: .5px; text-transform: uppercase; color: var(--text-leise); }
.eintrag {
  display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; border: 1px solid var(--rand); background: var(--flaeche);
  border-radius: 16px; padding: 11px 13px; transition: background .2s, border-color .2s, transform .2s;
}
.eintrag:hover { background: var(--flaeche-stark); border-color: rgba(169,150,255,.35); }
.eintrag[aria-current="true"] { border-color: rgba(169,150,255,.65); background: rgba(169,150,255,.14); }
.eintrag .symbol { flex: none; width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; font-size: 19px; background: rgba(255,255,255,.06); }
.eintrag .text { min-width: 0; display: grid; }
.eintrag strong { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.eintrag small { color: var(--text-leise); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.eintrag .pfeil { margin-left: auto; color: var(--text-leise); flex: none; }
.zurueck { justify-self: start; border: 0; background: transparent; color: var(--akzent); padding: 4px 2px; font-weight: 500; }
.sammlung .leser-spalte { display: none; }
.sammlung.offen .sammlung-liste { display: none; }
.sammlung.offen .leser-spalte { display: grid; gap: 10px; }
@media (min-width: 920px) {
  .sammlung { grid-template-columns: minmax(280px, 340px) minmax(0, 1fr); gap: 22px; }
  .sammlung .sammlung-liste { display: grid !important; position: sticky; top: 0; max-height: calc(100dvh - 150px); overflow-y: auto; padding-right: 4px; align-content: start; scrollbar-width: thin; }
  .sammlung .leser-spalte { display: grid; }
  .sammlung .reiter { flex-wrap: wrap; overflow: visible; }
  .zurueck { display: none; }
}

/* Offene Aufgaben */
.aufgabe { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; border-top: 1px solid var(--rand); }
.aufgabe:first-of-type { border-top: 0; padding-top: 2px; }
.aufgabe .symbol { flex: none; width: 36px; height: 36px; border-radius: 12px; display: grid; place-items: center; font-size: 18px; background: rgba(255,255,255,.06); }
.aufgabe div { min-width: 0; }
.aufgabe strong { display: block; font-weight: 500; overflow-wrap: anywhere; }
.aufgabe small { color: var(--text-leise); font-size: 13px; }
.marke-art { display: inline-block; font-size: 11px; font-weight: 600; letter-spacing: .5px; text-transform: uppercase; padding: 2px 8px; border-radius: 999px; background: var(--flaeche-stark); color: var(--akzent); margin-right: 6px; }
.hinweis { color: var(--text-leise); font-size: 13.5px; margin: 10px 0 0; }

/* =====================================================================
   Notiz-Darstellung (Markdown)
   ===================================================================== */
.leser { border-radius: 24px; padding: 22px 20px 24px; min-width: 0; }
@media (min-width: 920px) { .leser { padding: 30px 36px 34px; } }
.leser-meta { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 14px; }
.leser-meta span { font-size: 12px; padding: 3px 10px; border-radius: 999px; background: var(--flaeche-stark); color: var(--text-leise); }
.leser-pfad { color: var(--text-leise); font-size: 12.5px; margin: 0 0 4px; overflow-wrap: anywhere; }
.md { font-size: 16px; line-height: 1.65; overflow-wrap: anywhere; }
.md > :first-child { margin-top: 0; }
.md h1 { font: 500 30px/1.2 var(--titel); margin: 0 0 14px; letter-spacing: .2px; }
.md h2 { font: 500 21px/1.3 var(--titel); margin: 26px 0 8px; padding-top: 18px; border-top: 1px solid var(--rand); }
.md h1 + h2 { border-top: 0; padding-top: 0; margin-top: 6px; }
.md h3 { font-size: 16.5px; font-weight: 600; margin: 18px 0 6px; }
.md h4, .md h5, .md h6 { font-size: 15px; font-weight: 600; margin: 14px 0 4px; color: var(--text-leise); }
.md p { margin: 8px 0; }
.md ul, .md ol { margin: 8px 0; padding-left: 22px; }
.md li { margin: 3px 0; }
.md li::marker { color: var(--akzent); }
.md li.aufgabe-md { list-style: none; margin-left: -22px; display: flex; gap: 10px; align-items: baseline; }
.md li.aufgabe-md > span { min-width: 0; }
.md li.aufgabe-md::before { content: ""; flex: none; width: 15px; height: 15px; border-radius: 5px; border: 1.5px solid var(--akzent); transform: translateY(2px); }
.md li.aufgabe-md.erledigt { color: var(--text-leise); text-decoration: line-through; text-decoration-color: rgba(255,255,255,.3); }
.md li.aufgabe-md.erledigt::before { background: var(--gut) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3.5 8.5 6.5 11.5 12.5 4.5' fill='none' stroke='%23071a15' stroke-width='2.2'/%3E%3C/svg%3E") center/12px no-repeat; border-color: var(--gut); }
.md li[data-ebene="1"] { margin-left: 18px; } .md li[data-ebene="2"] { margin-left: 36px; } .md li[data-ebene="3"] { margin-left: 54px; }
.md li.aufgabe-md[data-ebene="1"] { margin-left: -4px; } .md li.aufgabe-md[data-ebene="2"] { margin-left: 14px; }
.md strong { font-weight: 600; color: #fff; }
.md em { color: #e6e0ff; }
.md del { color: var(--text-leise); }
.md mark { background: rgba(255,207,122,.22); color: #ffe6b3; border-radius: 4px; padding: 0 3px; }
.md code { font: 13.5px/1.4 ui-monospace, SFMono-Regular, Menlo, monospace; background: rgba(255,255,255,.08); border-radius: 6px; padding: 2px 6px; }
.md pre { background: rgba(0,0,0,.35); border: 1px solid var(--rand); border-radius: 14px; padding: 12px 14px; overflow-x: auto; }
.md pre code { background: none; padding: 0; }
.md blockquote { margin: 12px 0; padding: 10px 14px; border-left: 3px solid var(--akzent); background: rgba(169,150,255,.08); border-radius: 0 14px 14px 0; color: #ddd8f5; }
.md blockquote p { margin: 4px 0; }
.md blockquote .callout-titel { font-weight: 600; color: var(--text); display: block; margin-bottom: 2px; }
.md hr { border: 0; height: 1px; background: var(--rand); margin: 22px 0; }
.md a { color: #cfc4ff; text-decoration: underline; text-decoration-color: rgba(169,150,255,.45); text-underline-offset: 3px; }
.md a.wiki { text-decoration: none; background: rgba(169,150,255,.14); border-radius: 6px; padding: 0 5px; }
.md a.wiki:hover { background: rgba(169,150,255,.26); }
.md .tag { font-size: 13px; color: var(--akzent-2); background: rgba(255,154,213,.1); border-radius: 999px; padding: 1px 8px; }
.md .tabelle { overflow-x: auto; margin: 12px 0; border: 1px solid var(--rand); border-radius: 14px; }
.md table { border-collapse: collapse; width: 100%; font-size: 14.5px; }
.md th, .md td { text-align: left; padding: 8px 12px; border-bottom: 1px solid var(--rand); vertical-align: top; }
.md th { background: rgba(255,255,255,.05); font-weight: 600; }
.md tr:last-child td { border-bottom: 0; }

.knopf-reihe { display: flex; flex-wrap: wrap; gap: 8px; }
.meldung-unten {
  position: fixed; left: 50%; bottom: calc(86px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 50;
  padding: 10px 16px; border-radius: 14px; background: rgba(30,26,54,.95); border: 1px solid var(--rand); font-size: 14px;
  animation: auftauchen .3s ease; max-width: calc(100vw - 32px);
}
@media (min-width: 920px) { .meldung-unten { bottom: 28px; } }
@media (prefers-reduced-motion: reduce) { .bereich-inhalt > *, .lade i { animation: none !important; } }

/* =====================================================================
   Vanvans Antworten formatiert
   ===================================================================== */
.blase .inhalt { display: block; }
.blase .inhalt.md-blase { white-space: normal; font-size: 15.5px; line-height: 1.55; }
.md-blase > :first-child { margin-top: 0; }
.md-blase > :last-child { margin-bottom: 0; }
.md-blase p { margin: 0 0 7px; }
.md-blase ul, .md-blase ol { margin: 4px 0 7px; padding-left: 20px; }
.md-blase h1, .md-blase h2, .md-blase h3 { font: 600 16px/1.35 var(--schrift); margin: 10px 0 4px; padding: 0; border: 0; }
.md-blase .tabelle { margin: 8px 0; }
.blase.vanvan.schreibt .inhalt.md-blase::after { content: none; }
.blase.vanvan.schreibt .md-blase > :last-child:not(ul):not(ol):not(div)::after,
.blase.vanvan.schreibt .md-blase > :is(ul, ol):last-child > li:last-child::after {
  content: "▍"; color: var(--akzent); animation: blinken 1s steps(2) infinite; margin-left: 1px;
}
.bereich-inhalt.still > * { animation: none; }

/* =====================================================================
   Suche (Strg+K)
   ===================================================================== */
.such-blatt { width: min(640px, calc(100vw - 24px)); padding: 0; margin-top: min(12vh, 110px); overflow: hidden; }
.such-zeile { display: flex; align-items: center; gap: 10px; padding: 14px 14px 12px 18px; border-bottom: 1px solid var(--rand); }
.such-zeile > svg { width: 21px; height: 21px; color: var(--akzent); flex: none; }
.such-zeile input { flex: 1; min-width: 0; border: 0; outline: none; background: transparent; font-size: 17px; padding: 6px 0; }
.such-zeile input::-webkit-search-cancel-button { display: none; }
.such-ergebnisse { max-height: min(56vh, 460px); overflow-y: auto; padding: 6px 8px 8px; display: grid; gap: 2px; scrollbar-width: thin; }
.such-titel { margin: 6px 10px 4px; font-size: 12px; font-weight: 600; letter-spacing: .5px; text-transform: uppercase; color: var(--text-leise); }
.such-treffer { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; border: 0; background: transparent; border-radius: 14px; padding: 9px 10px; }
.such-treffer[aria-selected="true"] { background: rgba(169,150,255,.16); }
.such-treffer .symbol { flex: none; width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; font-size: 17px; background: rgba(255,255,255,.06); }
.such-treffer .text { min-width: 0; display: grid; }
.such-treffer strong { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.such-treffer small { color: var(--text-leise); font-size: 13px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.such-treffer mark { background: rgba(255,207,122,.25); color: #ffe6b3; border-radius: 3px; padding: 0 1px; }
.such-fuss { margin: 0; padding: 9px 16px 11px; border-top: 1px solid var(--rand); font-size: 12px; color: var(--text-leise); display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
@media (max-width: 919px) {
  .such-blatt { margin-top: 10px; max-height: calc(100dvh - 20px); }
  .such-fuss { display: none; }
}
.wach-schild.aus { opacity: .45; animation: none; }

/* =====================================================================
   Morgengruß
   ===================================================================== */
.gruss { align-self: stretch; border-radius: 22px; padding: 16px 18px; display: grid; gap: 10px; border-color: rgba(255,207,122,.35);
  background: linear-gradient(135deg, rgba(255,207,122,.13), rgba(255,154,213,.08) 60%, var(--flaeche)); animation: auftauchen .5s cubic-bezier(.2,.8,.2,1); }
.gruss-kopf { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.gruss-kopf strong { font: 500 22px/1.2 var(--titel); }
.gruss-kopf span { color: var(--text-leise); font-size: 13px; }
.gruss p { margin: 0; }
.gruss .haupt-knopf { padding: 10px 16px; }
.gruss .leise { border-color: transparent; background: transparent; color: var(--text-leise); }
.gruss-tipp { color: var(--text-leise); font-size: 12.5px; }

/* =====================================================================
   Wochenblick
   ===================================================================== */
.woche-legende { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-bottom: 8px; }
.woche-summe { display: flex; gap: 9px; align-items: flex-start; min-width: 0; }
.woche-summe > i { flex: none; width: 10px; height: 10px; border-radius: 3px; margin-top: 8px; }
.woche-summe > span { display: grid; min-width: 0; }
.woche-summe strong { font: 500 24px/1.15 var(--titel); color: var(--text); }
.woche-summe span span { font-size: 14px; color: var(--text); }
.woche-summe small { font-size: 12px; color: var(--text-leise); line-height: 1.3; }
.woche-buehne { position: relative; }
.woche-svg { width: 100%; height: auto; display: block; overflow: visible; }
.woche-svg .gitter { stroke: rgba(255,255,255,.07); stroke-width: 1; }
.woche-svg .achse { stroke: rgba(255,255,255,.22); stroke-width: 1; }
.woche-svg .achse-text { fill: var(--text-leise); font: 12px var(--schrift); }
.woche-svg .achse-text.heute { fill: var(--text); font-weight: 600; }
.woche-svg .woche-ziel { fill: transparent; cursor: pointer; outline: none; }
.woche-svg .woche-ziel.aktiv, .woche-svg .woche-ziel:focus-visible { fill: rgba(255,255,255,.05); }
.woche-tipp { position: absolute; top: 0; transform: translateX(-50%); pointer-events: none; z-index: 2; min-width: 170px;
  background: rgba(24,20,44,.96); border: 1px solid var(--rand); border-radius: 12px; padding: 9px 11px; font-size: 13px; box-shadow: 0 10px 30px -10px #000; }
.woche-tipp strong { display: block; margin-bottom: 4px; font-weight: 600; }
.woche-tipp div { display: flex; align-items: center; gap: 7px; }
.woche-tipp i { width: 8px; height: 8px; border-radius: 2px; flex: none; }
.woche-tipp span { color: var(--text-leise); }
.woche-tipp b { margin-left: auto; font-weight: 600; font-variant-numeric: tabular-nums; }
.woche-tabelle { margin-top: 8px; font-size: 13.5px; }
.woche-tabelle summary { cursor: pointer; color: var(--text-leise); }
.woche-tabelle table { width: 100%; border-collapse: collapse; margin-top: 8px; }
.woche-tabelle th, .woche-tabelle td { text-align: left; padding: 5px 8px; border-bottom: 1px solid var(--rand); }
.woche-tabelle td + td, .woche-tabelle th + th { text-align: right; font-variant-numeric: tabular-nums; }
@media (max-width: 520px) { .woche-summe strong { font-size: 20px; } .woche-summe small { display: none; } }
@media (prefers-reduced-motion: reduce) { .gruss { animation: none; } }
.blase.system .neben-knopf { display: block; margin: 8px auto 0; }
.sprach-hinweis { border: 1px solid rgba(255,207,122,.35) !important; background: rgba(255,207,122,.08) !important; border-radius: 16px; padding: 10px 14px; color: var(--text) !important; }
.timer-schild { font-size: 12.5px; font-weight: 600; font-variant-numeric: tabular-nums; padding: 3px 9px; border-radius: 999px; background: rgba(255,207,122,.14); color: #ffd99a; border: 1px solid rgba(255,207,122,.3); }
.erinnerung-blase { border-color: rgba(255,207,122,.5) !important; }

/* =====================================================================
   Hilfe
   ===================================================================== */
.hilfe-blatt { width: min(680px, calc(100vw - 24px)); max-height: min(86dvh, 820px); padding: 0; overflow: hidden; display: none; }
.hilfe-blatt[open] { display: grid; grid-template-rows: auto minmax(0, 1fr); }
.hilfe-kopf { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 18px 20px 12px; border-bottom: 1px solid var(--rand); }
.hilfe-kopf h2 { margin: 0; }
.hilfe-inhalt { overflow-y: auto; padding: 6px 20px 22px; scrollbar-width: thin; }
.hilfe-abschnitt { padding: 14px 0; border-bottom: 1px solid var(--rand); }
.hilfe-abschnitt:last-child { border-bottom: 0; }
.hilfe-abschnitt h3 { margin: 0 0 6px; font-size: 15.5px; font-weight: 600; }
.hilfe-abschnitt p { margin: 0 0 10px; color: var(--text-leise); font-size: 14.5px; line-height: 1.55; }
.hilfe-beispiele { display: flex; flex-wrap: wrap; gap: 7px; }
.hilfe-beispiele .vorschlag { font-size: 13.5px; padding: 7px 12px; }
.hilfe-beispiele .vorschlag.sofort { border-color: rgba(255,207,122,.3); }
.hilfe-tasten { display: grid; gap: 8px; }
.hilfe-tasten div { display: flex; align-items: center; justify-content: space-between; gap: 12px; font-size: 14px; }
.hilfe-tasten div > span:last-child { color: var(--text-leise); }
.aussprache-reihe input { width: 150px; }
@media (max-width: 520px) { .aussprache-reihe input { width: auto; } }
.schalter:disabled { opacity: .35; cursor: not-allowed; }
.tastenhinweis { display: none !important; }
