/* CONBUS.de Akademie – Lernplattform
   Richtung A „Hell & klar“ + runde Formen aus C. Alle Farben zentral als Variablen (Farbwelten später nachrüstbar). */

@font-face { font-family: Figtree; font-weight: 400; font-display: swap; src: url(../fonts/figtree-400.woff2) format("woff2"); }
@font-face { font-family: Figtree; font-weight: 500; font-display: swap; src: url(../fonts/figtree-500.woff2) format("woff2"); }
@font-face { font-family: Figtree; font-weight: 600; font-display: swap; src: url(../fonts/figtree-600.woff2) format("woff2"); }
@font-face { font-family: Figtree; font-weight: 700; font-display: swap; src: url(../fonts/figtree-700.woff2) format("woff2"); }
@font-face { font-family: Figtree; font-weight: 800; font-display: swap; src: url(../fonts/figtree-800.woff2) format("woff2"); }

:root {
  --ink: #141414; --ink-2: #3D3D3D; --ink-3: #5E5E5E;
  --bg: #F3F4F5; --card: #FFFFFF; --line: #E4E4E4; --line-2: #EFEFEF;
  --orange: #F7931E; --orange-hover: #E8850F; --orange-text: #B4530A; --on-orange: #141414;
  --yellow: #FFC533; --mark: #FFE38A;
  --accent: #FFF1DC; --accent-2: #FFF4E0; --accent-text: #B4530A;
  --logo-1: #FF8A17; --logo-2: #E88A42; --logo-3: #F8BA45;
  --ok: #1F8A4C; --ok-bg: #E3F3E9; --ok-text: #17663A;
  --warn: #E0A400; --warn-bg: #FFF4D6; --warn-text: #7A5200;
  --bad: #C8372D; --bad-bg: #FBE6E4; --bad-text: #9E2A21;
  --shadow: 0 10px 28px rgba(20,20,20,.07);
  --img-opacity: .55;
  --r-card: 26px; --r-pill: 999px;
  --fs: 17px; --fs-read: 18px;
  --t: .25s;
  color-scheme: light;
}
html[data-mode="dunkel"] {
  --ink: #F4EFE9; --ink-2: #D8D0C6; --ink-3: #B3A99D;
  --bg: #15120F; --card: #211C17; --line: #352D25; --line-2: #2C251F;
  --orange-text: #FFB066; --accent: #2A2013; --accent-2: #2A2013; --accent-text: #FFB066;
  --mark: #6B5418;
  --ok-bg: #16301F; --ok-text: #8FD9AC; --warn-bg: #3A2F0E; --warn-text: #F2CF6B; --bad-bg: #3B1A17; --bad-text: #F2A39C;
  --shadow: 0 10px 28px rgba(0,0,0,.35);
  --img-opacity: .28;
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  html[data-mode="auto"] {
    --ink: #F4EFE9; --ink-2: #D8D0C6; --ink-3: #B3A99D;
    --bg: #15120F; --card: #211C17; --line: #352D25; --line-2: #2C251F;
    --orange-text: #FFB066; --accent: #2A2013; --accent-2: #2A2013; --accent-text: #FFB066;
    --mark: #6B5418;
    --ok-bg: #16301F; --ok-text: #8FD9AC; --warn-bg: #3A2F0E; --warn-text: #F2CF6B; --bad-bg: #3B1A17; --bad-text: #F2A39C;
    --shadow: 0 10px 28px rgba(0,0,0,.35);
    --img-opacity: .28;
    color-scheme: dark;
  }
}
html[data-font="gross"] { --fs: 19px; --fs-read: 20px; }
html[data-font="sehrgross"] { --fs: 21px; --fs-read: 23px; }
html[data-motion="aus"] { --t: 0s; }
@media (prefers-reduced-motion: reduce) { :root { --t: 0s; } }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: Figtree, system-ui, -apple-system, "Segoe UI", sans-serif; font-size: var(--fs); line-height: 1.5;
  color: var(--ink); background: var(--bg); }
a { color: inherit; }
a:hover { color: var(--orange-text); }
img { max-width: 100%; height: auto; }
/* Symbole ohne eigene Größe (z. B. Pfeile in Listen) sonst 0 px breit */
svg:not([width]) { width: 1.25em; height: 1.25em; flex: none; }
.chev svg { display: block; width: 20px; height: 20px; }
h1, h2, h3 { line-height: 1.2; margin: 0; overflow-wrap: break-word; -webkit-hyphens: auto; hyphens: auto; }
h1 { font-size: clamp(28px, 4vw, 38px); font-weight: 800; letter-spacing: -.01em; }
h2 { font-size: 22px; font-weight: 800; }
h3 { font-size: 19px; font-weight: 700; }
p { margin: 0; }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 2px; border-radius: 6px; }
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--card); padding: 10px 16px; border-radius: 12px; z-index: 100; }
.skip:focus { left: 8px; }

/* ---------- Kopf und Navigation ---------- */
.top { position: sticky; top: 0; z-index: 30; background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(1.2) blur(10px); border-bottom: 1px solid var(--line); }
.top-in { max-width: 1040px; margin: 0 auto; padding: 10px 20px; display: flex; align-items: center; gap: 16px; }
.logo { display: block; height: 40px; flex: none; }
.logo img { height: 40px; width: auto; }
.logo .dark { display: none; }
html[data-mode="dunkel"] .logo .light { display: none; }
html[data-mode="dunkel"] .logo .dark { display: inline; }
@media (prefers-color-scheme: dark) {
  html[data-mode="auto"] .logo .light { display: none; }
  html[data-mode="auto"] .logo .dark { display: inline; }
}
.nav { display: flex; gap: 4px; margin: 0 auto; background: var(--card); border: 1px solid var(--line); border-radius: var(--r-pill); padding: 4px; }
.nav a { text-decoration: none; font-weight: 700; font-size: 16px; padding: 9px 18px; border-radius: var(--r-pill); color: var(--ink-2);
  transition: background var(--t), color var(--t); display: flex; align-items: center; gap: 8px; }
.nav a:hover { background: var(--line-2); color: var(--ink); }
.nav a[aria-current="page"] { background: var(--orange); color: var(--on-orange); }
.nav svg { width: 20px; height: 20px; }
.top-right { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.chip-points { display: flex; align-items: center; gap: 6px; font-weight: 800; font-size: 15px; background: var(--card); border: 1px solid var(--line);
  border-radius: var(--r-pill); padding: 6px 12px; text-decoration: none; }
.chip-points i { width: 12px; height: 12px; border-radius: 50%; background: var(--yellow); display: inline-block; }
.iconbtn { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: var(--accent-text);
  border: 1px solid transparent; text-decoration: none; position: relative; }
.iconbtn:hover { color: var(--accent-text); border-color: var(--orange); }
.iconbtn svg { width: 22px; height: 22px; }
.iconbtn .dot { position: absolute; top: 6px; right: 6px; width: 10px; height: 10px; border-radius: 50%; background: var(--orange); border: 2px solid var(--card); }
.btn-talk { display: flex; align-items: center; gap: 8px; text-decoration: none; font-weight: 700; font-size: 15px; padding: 9px 16px;
  border-radius: var(--r-pill); background: var(--accent); color: var(--accent-text); position: relative; }
.btn-talk:hover { color: var(--accent-text); box-shadow: inset 0 0 0 2px var(--orange); }
.btn-talk svg { width: 20px; height: 20px; }
.avatar { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; background: var(--yellow); color: #141414;
  text-decoration: none; font-size: 16px; }
.avatar:hover { color: #141414; box-shadow: 0 0 0 3px var(--accent); }

/* Benutzermenü hinter dem Avatar */
.usermenu { position: relative; }
.usermenu > summary { list-style: none; cursor: pointer; }
.usermenu > summary::-webkit-details-marker { display: none; }
.usermenu[open] > summary { box-shadow: 0 0 0 3px var(--orange); }
.usermenu .menu { position: absolute; right: 0; top: calc(100% + 10px); z-index: 60; width: 270px; background: var(--card); border: 1px solid var(--line);
  border-radius: 20px; box-shadow: var(--shadow); padding: 8px; display: flex; flex-direction: column; }
.usermenu .menu-head { display: flex; flex-direction: column; gap: 2px; padding: 10px 14px 12px; border-bottom: 1px solid var(--line); margin-bottom: 6px; overflow-wrap: anywhere; }
.usermenu .menu a, .usermenu .menu button { display: flex; align-items: center; gap: 8px; padding: 11px 14px; border-radius: 12px; color: var(--ink); text-decoration: none;
  font: inherit; font-size: 15px; font-weight: 600; background: none; border: 0; width: 100%; text-align: left; cursor: pointer; }
.usermenu .menu a:hover, .usermenu .menu button:hover { background: var(--line-2); color: var(--ink); }
.usermenu .menu a.hl { background: var(--accent); color: var(--accent-text); }
.usermenu .menu a.hl svg { width: 18px; height: 18px; color: var(--orange); fill: var(--orange); }
.usermenu .menu form { border-top: 1px solid var(--line); margin-top: 6px; padding-top: 6px; }

.botnav { display: none; }
@media (max-width: 760px) {
  .nav { display: none; }
  .btn-talk span { display: none; }
  .btn-talk { padding: 0; width: 44px; height: 44px; justify-content: center; border-radius: 50%; }
  .chip-points { display: none; }
  .logo, .logo img { height: 34px; }
  .botnav { display: flex; position: fixed; z-index: 40; bottom: 0; left: 0; right: 0; background: var(--card); border-top: 1px solid var(--line);
    padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); justify-content: space-around; }
  .botnav a { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 2px; text-decoration: none; font-size: 12px; font-weight: 700;
    color: var(--ink-3); padding: 6px 2px; border-radius: 16px; }
  .botnav a span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .botnav:has(a[href^="/team"]) a { font-size: 11px; padding-left: 0; padding-right: 0; letter-spacing: -.01em; }
  .botnav a svg { width: 24px; height: 24px; }
  .botnav a[aria-current="page"] { color: var(--accent-text); background: var(--accent); }
  body.has-botnav main { padding-bottom: 96px; }
}

/* ---------- Grundlayout ---------- */
main { max-width: 1040px; margin: 0 auto; padding: 28px 20px 64px; display: flex; flex-direction: column; gap: 24px; }
.narrow { max-width: 800px; margin: 0 auto; width: 100%; }
.eyebrow { font-weight: 800; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--orange-text); }
.muted { color: var(--ink-3); }
.small { font-size: 15px; }
.stack { display: flex; flex-direction: column; gap: 12px; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.row > * { min-width: 0; }
.grow { min-width: 0; }
.card.row { flex-direction: row; }
/* Auswahlkästchen mit Text: Kästchen links, Text daneben umbrechen (nie Kästchen allein in einer Zeile) */
label.row { flex-wrap: nowrap; align-items: flex-start; }
label.row > input { flex: none; margin: 2px 0 0; }
.between { justify-content: space-between; }
.hello { display: flex; flex-direction: column; gap: 6px; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--r-card); padding: 24px; position: relative; overflow: hidden;
  display: flex; flex-direction: column; gap: 14px; }
.card.accent { background: var(--accent); border-color: transparent; }
.card.hero { padding: 28px; min-height: 220px; }
.card .bgimg { position: absolute; inset: 0 0 0 auto; width: 58%; background-size: cover; background-position: center; opacity: var(--img-opacity);
  -webkit-mask-image: linear-gradient(to left, #000 35%, transparent); mask-image: linear-gradient(to left, #000 35%, transparent); pointer-events: none; }
html[data-bilder="aus"] .bgimg { display: none; }
.card > *:not(.bgimg) { position: relative; }
@media (max-width: 760px) { .card .bgimg { width: 100%; -webkit-mask-image: linear-gradient(to top, #000 0%, transparent 85%); mask-image: linear-gradient(to top, #000, transparent 85%); opacity: calc(var(--img-opacity) * .5); } }

.bars { display: flex; gap: 5px; height: 6px; width: 64px; }
.bars i { flex: 1; border-radius: 3px; }
.bars i:nth-child(1) { background: var(--logo-1); } .bars i:nth-child(2) { background: var(--logo-2); } .bars i:nth-child(3) { background: var(--logo-3); }

/* Knöpfe */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; font: inherit; font-weight: 800; font-size: 17px; cursor: pointer;
  border: 0; border-radius: var(--r-pill); padding: 14px 28px; background: var(--orange); color: var(--on-orange); text-decoration: none;
  transition: background var(--t), transform .1s; min-height: 48px; }
.btn:hover { background: var(--orange-hover); color: var(--on-orange); }
.btn:active { transform: scale(.98); }
.btn svg { width: 20px; height: 20px; }
.btn.ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 2px var(--line); }
.btn.ghost:hover { box-shadow: inset 0 0 0 2px var(--orange); color: var(--ink); }
.btn.soft { background: var(--accent); color: var(--accent-text); }
.btn.small { padding: 9px 18px; font-size: 15px; min-height: 40px; }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.link { font-weight: 700; color: var(--orange-text); text-decoration: none; }
.link:hover { text-decoration: underline; }

/* Fortschritt */
.progress { height: 10px; border-radius: 5px; background: var(--line-2); overflow: hidden; }
.progress > i { display: block; height: 100%; border-radius: 5px; background: var(--orange); transition: width .6s; }
.progress.thin { height: 6px; }
.progress.yellow > i { background: var(--yellow); }

/* Ampel */
.ampel { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; font-size: 14px; padding: 4px 11px; border-radius: var(--r-pill); white-space: nowrap; }
.ampel::before { content: ""; width: 8px; height: 8px; border-radius: 50%; }
.ampel.gruen { background: var(--ok-bg); color: var(--ok-text); } .ampel.gruen::before { background: var(--ok); }
.ampel.gelb { background: var(--warn-bg); color: var(--warn-text); } .ampel.gelb::before { background: var(--warn); }
.ampel.rot { background: var(--bad-bg); color: var(--bad-text); } .ampel.rot::before { background: var(--bad); }

/* Lernpfad-Stationen */
.path { display: flex; align-items: center; gap: 0; margin: 4px 0; flex-wrap: nowrap; overflow: hidden; }
.path .st { width: 18px; height: 18px; border-radius: 50%; background: var(--line); flex: none; border: 3px solid var(--card); box-shadow: 0 0 0 2px var(--line); }
.path .st.done { background: var(--orange); box-shadow: 0 0 0 2px var(--orange); }
.path .st.here { width: 26px; height: 26px; background: var(--yellow); box-shadow: 0 0 0 3px var(--orange); }
.path .ln { height: 3px; flex: 1; min-width: 8px; background: var(--line); }
.path .ln.done { background: var(--orange); }

/* Listen mit komplett antippbaren Zeilen */
.list { display: flex; flex-direction: column; }
.list > a, .list > .li { display: flex; align-items: center; gap: 16px; padding: 16px 4px; border-top: 1px solid var(--line); text-decoration: none; color: inherit; }
.list > a:first-child, .list > .li:first-child { border-top: 0; }
.list > a:hover { color: inherit; background: var(--line-2); border-radius: 16px; }
.list .num { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; background: var(--line-2); flex: none; }
.list .cur .num, .list a.cur .num { background: var(--orange); color: var(--on-orange); }
.list a.cur { background: var(--accent); border-radius: 18px; border-top-color: transparent; padding-left: 12px; padding-right: 12px; }
.list a.cur + a { border-top-color: transparent; }
.list .grow { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.list .grow strong { overflow-wrap: break-word; -webkit-hyphens: auto; hyphens: auto; }
.list .grow > span { overflow-wrap: anywhere; }
.list .chev { color: var(--ink-3); flex: none; }
.list .lock { opacity: .55; }

/* Einheiten mit aufklappbaren Kapiteln */
details.unit { border-top: 1px solid var(--line); }
details.unit:first-of-type { border-top: 0; }
details.unit > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 14px; padding: 16px 4px; }
details.unit > summary::-webkit-details-marker { display: none; }
details.unit > summary > * { min-width: 0; }
details.unit > summary strong { overflow-wrap: break-word; -webkit-hyphens: auto; hyphens: auto; }
details.unit > summary .small { white-space: nowrap; flex: none; }
details.unit > summary .tog { margin-left: auto; transition: transform var(--t); color: var(--ink-3); }
details.unit[open] > summary .tog { transform: rotate(90deg); }
.chapters { display: flex; flex-direction: column; padding: 0 0 12px 58px; }
.chapters a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 14px; text-decoration: none; color: inherit; }
.chapters a:hover { background: var(--line-2); color: inherit; }
.chapters .ck { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--line); flex: none; display: grid; place-items: center; }
.chapters .ck.done { background: var(--ok); border-color: var(--ok); color: #fff; }
.chapters .ck svg { width: 14px; height: 14px; }
.flag { color: var(--orange); width: 18px; height: 18px; flex: none; }
.locked { opacity: .55; }
@media (max-width: 760px) { .chapters { padding-left: 8px; } }

/* Notizzettel (Frage des Tages) */
.note-card { background: #FFF6C9; color: #141414; border-radius: 6px 26px 26px 26px; padding: 24px; box-shadow: var(--shadow); transform: rotate(-.4deg);
  display: flex; flex-direction: column; gap: 14px; position: relative; }
html[data-mode="dunkel"] .note-card { background: #3A3218; color: #F4EFE9; }
@media (prefers-color-scheme: dark) { html[data-mode="auto"] .note-card { background: #3A3218; color: #F4EFE9; } }
.note-card::before { content: ""; position: absolute; top: -10px; left: 40px; width: 90px; height: 22px; background: rgba(247,147,30,.35); transform: rotate(-3deg); border-radius: 3px; }
.answers { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (max-width: 640px) { .answers { grid-template-columns: 1fr; } }
.answer { display: flex; gap: 12px; align-items: flex-start; font: inherit; font-weight: 600; text-align: left; padding: 14px 16px; border: 2px solid var(--line);
  border-radius: 18px; background: var(--card); color: var(--ink); cursor: pointer; transition: border-color var(--t), background var(--t); }
.note-card .answer { background: rgba(255,255,255,.7); border-color: rgba(20,20,20,.12); color: #141414; }
html[data-mode="dunkel"] .note-card .answer { background: rgba(0,0,0,.25); color: #F4EFE9; border-color: rgba(255,255,255,.15); }
@media (prefers-color-scheme: dark) { html[data-mode="auto"] .note-card .answer { background: rgba(0,0,0,.25); color: #F4EFE9; border-color: rgba(255,255,255,.15); } }
html[data-mode="dunkel"] .note-card .answer:has(input:checked) { background: rgba(247,147,30,.25); border-color: var(--orange); }
@media (prefers-color-scheme: dark) { html[data-mode="auto"] .note-card .answer:has(input:checked) { background: rgba(247,147,30,.25); border-color: var(--orange); } }
.answer:hover { border-color: var(--orange); }
.answer input { margin-top: 4px; accent-color: var(--orange); width: 18px; height: 18px; flex: none; }
.answer:has(input:checked) { border-color: var(--orange); background: var(--accent); }
.answer.right { border-color: var(--ok); background: var(--ok-bg); }
.answer.wrong { border-color: var(--bad); background: var(--bad-bg); }
.answer p { margin: 0; }
.answer > span { min-width: 0; overflow-wrap: break-word; -webkit-hyphens: auto; hyphens: auto; }
fieldset { min-width: 0; }
.answer select, .content select { max-width: 100%; text-overflow: ellipsis; }
.content select { min-height: 40px; }
.answer select { flex: 1 1 180px; }
.order .skip15 { min-width: 40px; min-height: 40px; flex: none; display: grid; place-items: center; background: var(--card); border: 2px solid var(--line);
  border-radius: 999px; font: inherit; font-weight: 800; color: var(--ink); cursor: pointer; }
.order .skip15:hover { border-color: var(--orange); }
@media (max-width: 640px) {
  .order li.answer { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 10px; row-gap: 6px; }
  .order li.answer > span { grid-column: 1; grid-row: 1 / span 2; align-self: center; }
  .order li.answer > [data-up], .order li.answer > [data-down] { grid-column: 2; }
}

/* Formulare */
label.f { display: flex; flex-direction: column; gap: 6px; font-weight: 700; font-size: 15px; }
input[type=text], input[type=email], input[type=password], input[type=date], input[type=time], input[type=search], input[type=tel], select, textarea {
  font: inherit; font-size: 17px; color: var(--ink); background: var(--card); border: 2px solid var(--line); border-radius: 16px; padding: 12px 14px; width: 100%; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--orange); }
textarea { min-height: 120px; resize: vertical; }
.pw { position: relative; }
.pw button { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); background: none; border: 0; font: inherit; font-weight: 700;
  color: var(--orange-text); cursor: pointer; padding: 8px; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
@media (max-width: 640px) { .grid2 { grid-template-columns: 1fr; } }

.msg { padding: 14px 18px; border-radius: 18px; font-weight: 600; }
.msg.ok { background: var(--ok-bg); color: var(--ok-text); }
.msg.err { background: var(--bad-bg); color: var(--bad-text); }
.msg.info { background: var(--accent); color: var(--accent-text); }
.toast { position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%); z-index: 60; background: var(--ink); color: var(--bg); padding: 12px 20px;
  border-radius: var(--r-pill); font-weight: 700; box-shadow: var(--shadow); animation: toast 3.5s forwards; }
@keyframes toast { 0% { opacity: 0; transform: translate(-50%, 10px); } 8%, 85% { opacity: 1; transform: translate(-50%, 0); } 100% { opacity: 0; } }
@media (max-width: 760px) { .toast { bottom: 96px; } }

.banner-demo { background: var(--accent); color: var(--accent-text); text-align: center; font-weight: 700; padding: 8px 16px; font-size: 15px; }

/* ---------- Kapitelansicht ---------- */
.reader { max-width: 800px; margin: 0 auto; width: 100%; display: flex; flex-direction: column; gap: 18px; }
.reader-head { display: flex; flex-direction: column; gap: 10px; }
.cover { height: 180px; border-radius: var(--r-card); background-size: cover; background-position: center; position: relative; }
.cover::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to bottom, transparent 30%, var(--bg)); border-radius: inherit; }
.content { font-size: var(--fs-read); line-height: 1.7; max-width: 760px; min-width: 0; overflow-wrap: break-word; }
.content p, .content li, .content blockquote, .content dd, .content a { overflow-wrap: anywhere; }
.content h2, .content h3, .content h4 { margin: 1.4em 0 .5em; }
.content p { margin: 0 0 1em; }
.content ul, .content ol { padding-left: 1.3em; margin: 0 0 1em; }
.content li { margin: .3em 0; }
.content img { border-radius: 18px; display: block; margin: 1em auto; }
.content table { border-collapse: collapse; width: 100%; margin: 1em 0; font-size: .92em; display: block; overflow-x: auto; }
.content td, .content th { border: 1px solid var(--line); padding: 8px 10px; text-align: left; vertical-align: top; }
.content a { color: var(--orange-text); font-weight: 600; }
.content a.law { text-decoration: underline dotted; }
.content mark, .content .hl { background: var(--mark); color: inherit; border-radius: 4px; padding: 0 2px; cursor: pointer; }
.content blockquote, .content .merke { background: var(--accent); border-radius: 20px; padding: 18px 20px; margin: 1.2em 0; border: 0; }
.content video, .content iframe { width: 100%; aspect-ratio: 16/9; border-radius: 18px; border: 0; background: #000; display: block; margin: 1em 0; height: auto; }
.content .yt { position: relative; aspect-ratio: 16/9; border-radius: 18px; background: #1d1a17 center/cover; display: grid; place-items: center; margin: 1em 0; overflow: hidden; }
.content .yt button { font: inherit; font-weight: 800; background: var(--orange); color: #141414; border: 0; border-radius: 999px; padding: 14px 22px; cursor: pointer; }
.content .yt small { position: absolute; bottom: 10px; left: 14px; right: 14px; color: #fff; font-size: 13px; text-align: center; }
.readbar { position: sticky; bottom: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(10px);
  border-top: 1px solid var(--line); margin: 0 -20px; padding: 10px 20px calc(10px + env(safe-area-inset-bottom)); }
.readbar-in { max-width: 800px; margin: 0 auto; display: flex; gap: 10px; align-items: center; }
.readbar .btn { flex: 1; }
.readbar .iconbtn { flex: none; }
body.reading .botnav { display: none; }
body.reading main { padding-bottom: 0; }
.notes { display: flex; flex-direction: column; gap: 10px; }
.zettel { background: #FFF6C9; color: #141414; border-radius: 4px 18px 18px 18px; padding: 14px 16px; box-shadow: 0 4px 12px rgba(0,0,0,.06); white-space: pre-wrap; }
html[data-mode="dunkel"] .zettel { background: #3A3218; color: #F4EFE9; }
@media (prefers-color-scheme: dark) { html[data-mode="auto"] .zettel { background: #3A3218; color: #F4EFE9; } }
.zettel form { display: inline; }
.zettel button { background: none; border: 0; color: inherit; opacity: .6; cursor: pointer; font: inherit; font-size: 13px; text-decoration: underline; }
.hl-pop { position: absolute; z-index: 50; display: flex; gap: 4px; background: var(--ink); color: var(--bg); border-radius: 999px; padding: 4px; box-shadow: var(--shadow); }
.hl-pop button { background: none; border: 0; color: inherit; font: inherit; font-weight: 700; font-size: 14px; padding: 8px 12px; border-radius: 999px; cursor: pointer; }
.hl-pop button:hover { background: rgba(255,255,255,.15); }

/* Seitenleiste-Dialog (Notiz, Chatbot) */
dialog.sheet { border: 0; padding: 0; border-radius: var(--r-card); width: min(560px, calc(100% - 24px)); background: var(--card); color: var(--ink); box-shadow: var(--shadow); }
dialog.sheet::backdrop { background: rgba(20,20,20,.35); }
dialog.sheet .in { padding: 22px; display: flex; flex-direction: column; gap: 14px; }
dialog.sheet.chat { width: min(460px, calc(100% - 24px)); height: min(680px, calc(100% - 40px)); }
dialog.sheet.chat[open] { display: flex; flex-direction: column; }
.chat-log { flex: 1; overflow-y: auto; padding: 16px 18px; display: flex; flex-direction: column; gap: 10px; }
.chat-form { display: flex; gap: 8px; padding: 12px 14px; border-top: 1px solid var(--line); align-items: flex-end; }
.chat-form textarea { min-height: 48px; resize: none; }
.chat-note { padding: 0 16px 12px; margin: 0; }
.sheet-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.x { background: none; border: 0; font-size: 28px; line-height: 1; cursor: pointer; color: var(--ink-3); width: 44px; height: 44px; border-radius: 50%; }
.x:hover { background: var(--line-2); }

/* Player */
.player { display: flex; flex-direction: column; gap: 14px; }
.player .ctrl { display: flex; align-items: center; justify-content: center; gap: 18px; }
.player .play { width: 72px; height: 72px; border-radius: 50%; background: var(--orange); color: #141414; border: 0; cursor: pointer; display: grid; place-items: center; }
.player .play svg { width: 32px; height: 32px; }
.player .skip15 { background: var(--card); border: 2px solid var(--line); border-radius: 999px; font: inherit; font-weight: 800; padding: 10px 14px; cursor: pointer; color: var(--ink); }
.player input[type=range] { width: 100%; accent-color: var(--orange); }
.tracks a { display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 14px; text-decoration: none; }
.tracks a:hover { background: var(--line-2); color: inherit; }
.tracks a.playing { background: var(--accent); color: var(--accent-text); font-weight: 700; }
.tracks .dur { margin-left: auto; font-size: 14px; color: var(--ink-3); flex: none; white-space: nowrap; }
.tracks a > span:not(.ck):not(.dur) { flex: 1; min-width: 0; overflow-wrap: break-word; }

/* Tabs / Umschalter */
.seg { display: flex; flex-wrap: wrap; gap: 6px; background: var(--card); border: 1px solid var(--line); border-radius: var(--r-pill); padding: 4px; align-self: flex-start; }
.seg a { text-decoration: none; padding: 8px 16px; border-radius: var(--r-pill); font-weight: 700; font-size: 15px; color: var(--ink-2); }
.seg a[aria-current="true"] { background: var(--orange); color: #141414; }
.az { display: flex; flex-wrap: wrap; gap: 4px; }
.az a { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; text-decoration: none; font-weight: 700; font-size: 14px; background: var(--card); border: 1px solid var(--line); }
.entry { padding: 16px 0; border-top: 1px solid var(--line); }
.entry summary { font-weight: 700; cursor: pointer; font-size: 18px; }
.entry .content { font-size: var(--fs); margin-top: 8px; }

/* Schritte */
.steps { display: flex; flex-direction: column; gap: 4px; counter-reset: s; }
.steps form { display: block; }
.steps button { width: 100%; display: flex; align-items: center; gap: 14px; text-align: left; font: inherit; color: inherit; background: none; border: 0;
  padding: 12px 6px; cursor: pointer; border-radius: 16px; }
.steps button:hover { background: var(--line-2); }
.steps .dot { width: 30px; height: 30px; border-radius: 50%; border: 2px solid var(--line); flex: none; display: grid; place-items: center; }
.steps .done .dot { background: var(--ok); border-color: var(--ok); color: #fff; }
.steps .next .dot { border-color: var(--orange); box-shadow: 0 0 0 4px var(--accent); }
.steps .done .t { text-decoration: line-through; color: var(--ink-3); }

.bubble { max-width: 85%; min-width: 0; padding: 12px 16px; border-radius: 20px; white-space: pre-wrap; overflow-wrap: anywhere; }
.bubble.me { align-self: flex-end; background: var(--accent); border-bottom-right-radius: 6px; }
.bubble.them { align-self: flex-start; background: var(--line-2); border-bottom-left-radius: 6px; }
.bubble small { display: block; font-size: 12px; color: var(--ink-3); margin-top: 4px; }

.countdown { font-size: 44px; font-weight: 800; line-height: 1; }
.level { width: 64px; height: 64px; border-radius: 50%; background: var(--yellow); color: #141414; display: grid; place-items: center; font-size: 28px; font-weight: 800; flex: none; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; }
.kv dt { color: var(--ink-3); } .kv dd { margin: 0; font-weight: 600; }
.table { width: 100%; border-collapse: collapse; font-size: 15px; }
.table th, .table td { text-align: left; padding: 10px 8px; border-top: 1px solid var(--line); vertical-align: top; }
.table th { font-size: 13px; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-3); border-top: 0; }
.table tr.click:hover { background: var(--line-2); cursor: pointer; }
.badge { display: inline-block; font-size: 12px; font-weight: 800; padding: 3px 9px; border-radius: 999px; background: var(--accent); color: var(--accent-text); }
.kpis { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.kpis .card strong { font-size: 34px; font-weight: 800; }
@media (max-width: 640px) { .kpis { grid-template-columns: 1fr; } }

/* Anmeldung */
.auth { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
.auth-l { display: flex; flex-direction: column; justify-content: center; padding: 48px clamp(24px, 6vw, 80px); gap: 22px; background: var(--card); }
.auth-r { position: relative; background: var(--accent); display: flex; flex-direction: column; justify-content: flex-end; padding: 48px clamp(24px, 5vw, 64px); gap: 14px; overflow: hidden; }
.auth-r .bgimg { position: absolute; inset: 0; background: url(../img/selbstlernen-1200.webp) center/cover; opacity: var(--img-opacity);
  -webkit-mask-image: linear-gradient(to bottom, #000 30%, transparent 85%); mask-image: linear-gradient(to bottom, #000 30%, transparent 85%); }
html[data-bilder="aus"] .auth-r .bgimg { display: none; }
.auth-r > *:not(.bgimg) { position: relative; }
.auth form { display: flex; flex-direction: column; gap: 14px; max-width: 420px; }
.auth .logo img { height: 52px; }
@media (max-width: 860px) { .auth { grid-template-columns: 1fr; } .auth-r { min-height: 0; padding-top: 140px; } }
.plain { max-width: 520px; margin: 48px auto; padding: 0 20px; display: flex; flex-direction: column; gap: 20px; }

/* Einstiegstour */
.tour-veil { position: fixed; inset: 0; z-index: 80; background: rgba(255,250,243,.62); }
html[data-mode="dunkel"] .tour-veil { background: rgba(10,8,6,.62); }
@media (prefers-color-scheme: dark) { html[data-mode="auto"] .tour-veil { background: rgba(10,8,6,.62); } }
.tour-spot { position: relative; z-index: 81; box-shadow: 0 0 0 4px var(--orange), 0 0 0 9999px rgba(0,0,0,0); border-radius: var(--r-card); }
.tour-card { position: fixed; z-index: 82; width: min(380px, calc(100% - 24px)); background: var(--card); color: var(--ink); border-radius: var(--r-card);
  box-shadow: 0 18px 50px rgba(0,0,0,.2); padding: 20px; display: flex; flex-direction: column; gap: 12px; transition: top var(--t), left var(--t); }
.tour-card .row { justify-content: space-between; }
@media (max-width: 760px) { .tour-card { left: 12px !important; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom)) !important; top: auto !important; width: auto; } }

/* Druck (Bescheinigung, Zugangskarten) */
@media print {
  body { background: #fff; color: #000; }
  .noprint { display: none !important; }
}

/* Feedback-Fragebogen */
.plain.fb { max-width: 680px; }
.fb fieldset.card { border: 1px solid var(--line); margin: 0; min-width: 0; }
.fb legend { font-weight: 700; font-size: 18px; line-height: 1.35; padding: 0; margin-bottom: 12px; float: left; width: 100%; }
.fb legend + * { clear: both; }
.fb-nr { color: var(--accent-text); margin-right: 6px; font-weight: 800; }
.fb-wahl { display: flex; flex-wrap: wrap; gap: 10px; }
.fb-wahl label { position: relative; cursor: pointer; }
.fb-wahl input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.fb-wahl span { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 10px 16px; border: 1.5px solid var(--line);
  border-radius: 12px; background: var(--card); font-weight: 600; user-select: none; }
.fb-wahl label:hover span { border-color: var(--orange); }
.fb-wahl input:focus-visible + span { outline: 3px solid var(--accent-text); outline-offset: 2px; }
.fb-wahl input:checked + span { background: var(--orange); border-color: var(--orange); color: var(--on-orange); }
.fb-mehr input:checked + span::before { content: "✓"; margin-right: 6px; font-weight: 800; }
.fb-skala { display: grid; grid-template-columns: repeat(5, 1fr); }
.fb-skala11 { display: grid; grid-template-columns: repeat(11, 1fr); gap: 6px; }
.fb-skala span, .fb-skala11 span { width: 100%; padding: 10px 0; }
@media (max-width: 520px) { .fb-skala11 { grid-template-columns: repeat(6, 1fr); } }
.fb-pole { display: flex; justify-content: space-between; gap: 12px; margin-top: 8px; }
.fb-err { box-shadow: 0 0 0 2px var(--bad) inset; }
.fb-bar { display: grid; grid-template-columns: minmax(120px, 34%) 1fr 36px; align-items: center; gap: 10px; padding: 5px 0; }
.fb-bar i { display: block; height: 12px; border-radius: 6px; background: var(--line-2); position: relative; overflow: hidden; }
.fb-bar i::after { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--w); background: var(--orange); border-radius: 6px; }
.fb-bar b { text-align: right; }
.prose h2 { font-size: 20px; margin: 18px 0 6px; } .prose h2:first-child { margin-top: 0; }
.prose ul { padding-left: 20px; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.bubble .attach { display: flex; align-items: center; gap: 8px; margin-top: 8px; padding: 10px 12px; border-radius: 12px; background: var(--card); color: var(--ink);
  border: 1px solid var(--line); text-decoration: none; font-weight: 700; white-space: normal; }
.bubble .attach:has(.fn) { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 10px; row-gap: 2px; align-items: start; }
.bubble .attach .fn { grid-column: 2; min-width: 0; overflow-wrap: anywhere; }
.bubble .attach .sz { grid-column: 2; white-space: nowrap; }
.bubble .attach svg { grid-row: 1 / span 2; margin-top: 2px; }
.bubble .attach:hover { border-color: var(--orange); color: var(--ink); }
.bubble .attach svg { width: 20px; height: 20px; flex: none; }
.bubble .attach .small { font-weight: 500; color: var(--ink-3); }

/* Videokonferenz */
.vc-body { min-height: 100vh; min-height: 100dvh; }
.vc { max-width: 1200px; margin: 0 auto; padding: 12px 16px calc(16px + env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 12px; min-height: 100dvh; }
.vc-top { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.vc-top strong { flex: 1; min-width: 160px; }
.vc-stage { position: relative; flex: 1; min-height: 50vh; border-radius: 20px; overflow: hidden; background: var(--card); border: 1px solid var(--line); }
#vc-remote { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: transparent; }
#vc-local { position: absolute; right: 14px; bottom: 14px; width: min(26%, 240px); aspect-ratio: 16 / 9; object-fit: cover; border-radius: 12px;
  border: 2px solid var(--card); box-shadow: 0 4px 18px rgba(0,0,0,.18); background: var(--line-2); transform: scaleX(-1); }
#vc-local.vc-screen { transform: none; object-fit: contain; }
#vc-remote[hidden] { display: none; }
/* Keine Abspiel-/Pause-Symbole des Browsers über den Videobildern (v. a. iPhone) */
.vc video::-webkit-media-controls, .vc video::-webkit-media-controls-start-playback-button, .vc video::-webkit-media-controls-overlay-play-button { display: none !important; -webkit-appearance: none; }
#vc-local.vc-portrait { width: auto; height: min(38%, 260px); }
.vc-btn[aria-pressed="false"]#vc-mic svg { opacity: .9; }
.vc-wait { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; padding: 24px; }
.vc-wait[hidden] { display: none; }
.vc-badge { position: absolute; left: 14px; top: 14px; background: var(--orange); color: var(--on-orange); font-weight: 700; font-size: 14px; padding: 6px 12px; border-radius: var(--r-pill); }
.vc-bar { display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; }
.vc-btn { display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 84px; padding: 10px 12px; border-radius: 16px; border: 1.5px solid var(--line);
  background: var(--card); color: var(--ink); font: inherit; font-weight: 700; font-size: 13px; cursor: pointer; text-decoration: none; }
.vc-btn svg { width: 24px; height: 24px; }
.vc-btn:hover { border-color: var(--orange); color: var(--ink); }
.vc-btn[aria-pressed="false"]#vc-mic, .vc-btn[aria-pressed="false"]#vc-cam { background: var(--bad-bg); color: var(--bad-text); border-color: transparent; }
.vc-btn[aria-pressed="true"]#vc-screen { background: var(--orange); color: var(--on-orange); border-color: var(--orange); }
.vc-btn:disabled { opacity: .45; cursor: not-allowed; }
.vc-end { background: var(--bad); color: #fff; border-color: var(--bad); }
.vc-end:hover { color: #fff; filter: brightness(1.08); }
.vc-hint { text-align: center; margin: 0; }
@media (max-width: 600px) {
  .vc-bar { flex-wrap: nowrap; gap: 8px; }
  .vc-btn { min-width: 0; flex: 1; padding: 12px 4px; }
  .vc-btn span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .vc-btn svg { width: 26px; height: 26px; }
  .vc-stage { min-height: 62vh; }
  #vc-local { right: 10px; bottom: 10px; width: 34%; }
  #vc-local.vc-portrait { width: auto; height: 34%; }
}

/* Merke-Kasten und Hervorhebung im Kapiteltext */
.content .merke { background: var(--accent); border-left: 4px solid var(--orange); border-radius: 14px; padding: 14px 18px; margin: 1.2em 0; }
.content .merke p:last-child { margin-bottom: 0; }
.content mark { background: #FFE58A; color: #141414; border-radius: 3px; padding: 0 2px; }
.content video { width: 100%; border-radius: 18px; margin: 1em 0; background: var(--line-2); }

/* Inhalts-Editor */
.ed-bar { display: flex; flex-wrap: wrap; gap: 6px; position: sticky; top: 0; z-index: 2; background: var(--card); padding: 6px 0; }
.ed-bar button { min-height: 36px; padding: 4px 10px; border-radius: 10px; border: 1.5px solid var(--line); background: var(--card); color: var(--ink); font: inherit; font-size: 14px; font-weight: 600; cursor: pointer; }
.ed-bar button:hover { border-color: var(--orange); }
.ed-bar button[aria-pressed="true"] { background: var(--orange); border-color: var(--orange); color: var(--on-orange); }
.ed-sep { width: 1px; background: var(--line); margin: 0 4px; }
.ed-area { min-height: 320px; max-width: none; border: 1.5px solid var(--line); border-radius: 14px; padding: 16px 18px; outline: none; }
.ed-area:focus { border-color: var(--orange); }
.ed-area .yt { pointer-events: none; }
.ed-source { width: 100%; min-height: 420px; font: 13px/1.5 ui-monospace, Menlo, Consolas, monospace; border: 1.5px solid var(--line); border-radius: 14px; padding: 12px; background: var(--card); color: var(--ink); }
.ed-progress { display: grid; gap: 6px; } .ed-progress[hidden] { display: none; }
.ed-progress i { display: block; height: 8px; border-radius: 4px; background: var(--line-2); position: relative; overflow: hidden; }
.ed-progress i::after { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--w, 0%); background: var(--orange); }
.ed-dialog { border: 0; border-radius: 20px; padding: 22px; width: min(520px, 92vw); background: var(--card); color: var(--ink); }
.ed-dialog::backdrop { background: rgba(0,0,0,.35); }

/* ---------- Handy (iPhone 375/390 px): Zeilen umbrechen statt quetschen ---------- */
@media (max-width: 640px) {
  h1 { font-size: 26px; }
  main { padding: 20px 14px 56px; gap: 18px; }
  .card { padding: 20px 18px; }
  .card.hero { padding: 22px 20px; min-height: 0; }
  .readbar { margin: 0 -14px; padding-left: 14px; padding-right: 14px; }
  .top-in { padding: 8px 14px; gap: 10px; }
  /* Listenzeilen: Nummer | Text | Pfeil; Ampel, Knöpfe und Zusätze rutschen unter den Text */
  .list > a, .list > .li { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 12px; row-gap: 0; align-items: center; }
  .list > a:has(> .num), .list > .li:has(> .num) { grid-template-columns: auto minmax(0, 1fr) auto; }
  .list > * > .num { grid-column: 1; grid-row: 1 / span 3; align-self: center; }
  .list > * > .grow { grid-column: 1; grid-row: 1; }
  .list > *:has(> .num) > .grow { grid-column: 2; }
  .list > * > .chev { grid-column: -2; grid-row: 1 / span 3; }
  .list > * > :not(.num):not(.grow):not(.chev):not(input[type=hidden]) { grid-column: 1; justify-self: start; margin-top: 10px; }
  .list > *:has(> .num) > :not(.num):not(.grow):not(.chev):not(input[type=hidden]) { grid-column: 2; }
  .list .num { width: 40px; height: 40px; }
  .list a.cur { padding-left: 10px; padding-right: 10px; }
  /* Karte „Weiter mit …“ auf der Lernen-Seite */
  .card-row { flex-direction: column !important; align-items: stretch !important; }
  .card-row .btn { align-self: flex-start; }
  /* Tabellen: waagerecht wischen statt quetschen */
  .table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .table th { white-space: nowrap; }
  .table td { min-width: 6.5em; }
  /* Tabellen mit Überschriften: am Handy jede Zeile als kleine Karte */
  .table.stackable { display: block; overflow: visible; }
  .table.stackable thead { display: none; }
  .table.stackable tbody, .table.stackable tr, .table.stackable td { display: block; min-width: 0; }
  .table.stackable tr { border-top: 1px solid var(--line); padding: 10px 0; }
  .table.stackable tr:first-child { border-top: 0; }
  .table.stackable td { border: 0; padding: 3px 0; overflow-wrap: anywhere; }
  .table.stackable td[data-label]:not(:first-child)::before { content: attr(data-label) ": "; color: var(--ink-3); font-size: 13px; font-weight: 700; }
  .table.stackable td:empty { display: none; }
  .content table { font-size: .85em; }
  .content td, .content th { min-width: 7em; }
  /* Schlüssel/Wert-Listen untereinander */
  .kv { grid-template-columns: 1fr; gap: 2px; }
  .kv dd { margin-bottom: 8px; }
  /* Anmeldung: Bild oben, Text unten gut lesbar */
  .auth-l { padding: 32px 20px; }
  .auth-r { padding: 120px 20px 32px; }
  .auth-r .bgimg { -webkit-mask-image: linear-gradient(to bottom, #000 0, transparent 130px); mask-image: linear-gradient(to bottom, #000 0, transparent 130px); opacity: calc(var(--img-opacity) * 1.2); }
  .card.row > label.f, .card.row > .btn { flex: 1 1 140px; }
  .seg { align-self: stretch; }
  .fb-bar { grid-template-columns: minmax(90px, 38%) 1fr 32px; }
}

/* ---------- Plattform-Feedback (Sterne) und Ideenbox ---------- */
.fb-card .stack { gap: 16px; }
.fb-rate { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.stars { display: inline-flex; flex-direction: row-reverse; gap: 2px; border: 0; margin: 0; padding: 0; }
.stars input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.stars label { width: 48px; height: 48px; display: grid; place-items: center; cursor: pointer; border-radius: 50%; }
.stars svg { width: 38px; height: 38px; fill: var(--card); stroke: #C9B89F; stroke-width: 1.6; stroke-linejoin: round; transition: transform .15s; }
.stars input:checked ~ label svg { fill: var(--orange); stroke: var(--orange); }
.stars:hover input ~ label svg { fill: var(--card); stroke: #C9B89F; }
.stars input + label:hover svg, .stars input + label:hover ~ label svg { fill: var(--orange); stroke: var(--orange); }
.stars input:focus-visible + label { outline: 3px solid var(--orange); outline-offset: 2px; }
.stars label:active svg { transform: scale(.9); }
.fb-mood { font-weight: 800; font-size: 17px; color: var(--accent-text); }
.fb-more[data-hidden] { display: none; }
.fb-card textarea, .fb-card .f textarea { background: var(--card); }
.fb-actions { gap: 18px; }
.link-btn { font: inherit; font-size: 15px; font-weight: 700; background: none; border: 0; padding: 8px 0; color: var(--orange-text); text-decoration: underline; cursor: pointer; }
.link-btn.muted { color: var(--ink-3); }
.fb-ok { width: 52px; height: 52px; border-radius: 50%; background: var(--yellow); color: #141414; display: grid; place-items: center; flex: none; }
.fb-ok svg { width: 26px; height: 26px; stroke-width: 2.6; }
fieldset.chips { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
fieldset.chips legend { font-weight: 700; font-size: 15px; margin-bottom: 8px; padding: 0; }
fieldset.chips input { position: absolute; opacity: 0; width: 1px; height: 1px; }
fieldset.chips label { padding: 10px 18px; border-radius: var(--r-pill); background: var(--card); border: 1px solid var(--line); font-weight: 600; font-size: 15px; cursor: pointer; }
fieldset.chips input:checked + label { background: var(--ink); color: var(--bg); border-color: var(--ink); }
fieldset.chips input:focus-visible + label { outline: 3px solid var(--orange); outline-offset: 2px; }
.idea-reply { background: var(--line-2); border-radius: 14px; padding: 10px 14px; font-size: 15px; white-space: pre-line; }
details.idea-done { padding: 0 8px; }
details.idea-done summary { cursor: pointer; font-weight: 700; font-size: 15px; color: var(--orange-text); padding: 6px 0; }
details.idea-done ul { list-style: none; margin: 8px 0 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
details.idea-done li { display: flex; gap: 12px; align-items: baseline; }
details.idea-done li .small { width: 64px; flex: none; }
@media (max-width: 760px) {
  .usermenu .menu { position: fixed; left: 12px; right: 12px; top: 64px; width: auto; }
  .stars label { width: 54px; height: 54px; }
  .stars svg { width: 42px; height: 42px; }
}
