/* SelfAgent – Gestaltung nach Apples Prinzipien:
   ruhige Flächen, Materialien statt Linien, größenabhängige Laufweite,
   sofortiges Feedback beim Drücken, Rücksicht auf Systemeinstellungen. */

:root {
  --bg: #f5f5f7;
  --surface: #ffffff;
  --surface-2: #fbfbfd;
  --ink: #1d1d1f;
  --ink-2: #424245;
  --muted: #6e6e73;
  --sep: rgba(0, 0, 0, 0.08);
  --fill: rgba(120, 120, 128, 0.12);
  --fill-2: rgba(120, 120, 128, 0.08);
  --accent: #0071e3;
  --accent-ink: #ffffff;
  --accent-soft: rgba(0, 113, 227, 0.1);
  --pos: #248a3d;
  --neg: #d70015;
  --warn: #b25000;
  --s0: #1d1d1f; --s1: #0071e3; --s2: #ff9f0a; --s3: #af52de;
  --side-bg: rgba(242, 242, 247, 0.72);
  --side-solid: #f2f2f7;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04), 0 1px 1px rgba(0, 0, 0, 0.02);
  --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.1), 0 2px 6px rgba(0, 0, 0, 0.04);
  --r: 18px;
  --r-sm: 12px;
  --ease: cubic-bezier(0.25, 0.1, 0.25, 1);
}
:root:not([data-theme="light"]) { color-scheme: light dark; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #000000; --surface: #1c1c1e; --surface-2: #232325; --ink: #f5f5f7; --ink-2: #d1d1d6; --muted: #98989d;
    --sep: rgba(255, 255, 255, 0.1); --fill: rgba(120, 120, 128, 0.24); --fill-2: rgba(120, 120, 128, 0.16);
    --accent: #2997ff; --accent-soft: rgba(41, 151, 255, 0.16); --pos: #30d158; --neg: #ff453a; --warn: #ff9f0a;
    --s0: #f5f5f7; --s1: #2997ff; --side-bg: rgba(28, 28, 30, 0.72); --side-solid: #1c1c1e;
    --shadow-sm: none; --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.5);
  }
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  font: 100%/1.47 system-ui, -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, sans-serif;
  font-size: 0.9375rem; letter-spacing: -0.006em;
  color: var(--ink); background: var(--bg);
  -webkit-font-smoothing: antialiased; font-optical-sizing: auto;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
code, pre { font: 0.8125rem/1.5 ui-monospace, "SF Mono", Menlo, monospace; }
code { background: var(--fill-2); border-radius: 6px; padding: 1px 6px; }

/* Typografie: Laufweite und Zeilenabstand passend zur Größe */
h1 { font-size: 2rem; line-height: 1.1; letter-spacing: -0.025em; font-weight: 700; margin: 0; }
h1.h-small { font-size: 1.0625rem; letter-spacing: -0.01em; }
h2 { font-size: 1.0625rem; line-height: 1.25; letter-spacing: -0.012em; font-weight: 600; margin: 0; }
h3 { font-size: 0.75rem; letter-spacing: 0.02em; text-transform: uppercase; color: var(--muted); font-weight: 600; margin: 0 0 8px; }
.muted { color: var(--muted); margin: 2px 0 0; }
.pos { color: var(--pos); } .neg { color: var(--neg); }
.r { text-align: right; }

/* Struktur */
.shell { display: grid; grid-template-columns: 248px minmax(0, 1fr); min-height: 100vh;
  background: linear-gradient(90deg, var(--side-solid) 248px, transparent 248px); }
.side {
  position: sticky; top: 0; height: 100vh; overflow-y: auto;
  display: flex; flex-direction: column; gap: 18px; padding: 20px 12px 16px;
  background: var(--side-bg);
  backdrop-filter: blur(30px) saturate(180%); -webkit-backdrop-filter: blur(30px) saturate(180%);
  border-right: 1px solid var(--sep);
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; letter-spacing: -0.015em; padding: 0 8px; }
.brand .mark { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; color: #fff;
  background: linear-gradient(160deg, #3a8dff, #0058c2); font-size: 0.875rem; }
.brand.big { font-size: 1.25rem; justify-content: center; margin-bottom: 20px; }
.brand.big .mark { width: 36px; height: 36px; border-radius: 10px; font-size: 1.05rem; }
.side nav { display: flex; flex-direction: column; gap: 1px; }
.nav-label { font-size: 0.6875rem; font-weight: 600; color: var(--muted); letter-spacing: 0.02em; margin: 12px 10px 4px; }
.nav-label:first-child { margin-top: 0; }
.side nav a {
  display: flex; align-items: center; gap: 10px; color: var(--ink); padding: 7px 10px; border-radius: 8px;
  transition: background-color 120ms var(--ease);
}
.side nav a:hover { background: var(--fill-2); text-decoration: none; }
.side nav a.on { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.ico { width: 18px; height: 18px; flex: none; color: var(--accent); }
.side nav a:not(.on) .ico { color: var(--muted); }
.side-agents { margin-top: auto; display: flex; flex-direction: column; gap: 2px; }
.agent-chip { display: flex; gap: 10px; align-items: center; padding: 5px 10px; border-radius: 10px; color: var(--ink); }
.agent-chip > span:last-child { display: flex; align-items: baseline; gap: 6px; min-width: 0; }
.agent-chip:hover { background: var(--fill-2); text-decoration: none; }
.agent-chip strong { font-size: 0.875rem; } .agent-chip small { color: var(--muted); font-size: 0.75rem; }
.logout { margin: 0; padding: 0 10px; }
.link { background: none; border: 0; color: var(--muted); cursor: pointer; padding: 0; font: inherit; }
.link:hover { color: var(--ink); }

.avatar { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; flex: none;
  color: #fff; font-weight: 600; background: linear-gradient(160deg, #8e8e93, #636366); }
.avatar.sm { width: 28px; height: 28px; font-size: 0.8125rem; }
.avatar.lg { width: 52px; height: 52px; font-size: 1.25rem; }
.avatar.a-harlo { background: linear-gradient(160deg, #3a8dff, #0058c2); }
.avatar.a-mira { background: linear-gradient(160deg, #ff9f0a, #e5631a); }
.avatar.a-theo { background: linear-gradient(160deg, #ac8e68, #7a5a35); }
.avatar.a-otto { background: linear-gradient(160deg, #8e8e93, #3a3a3c); }
.avatar.a-clara { background: linear-gradient(160deg, #bf5af2, #7d2ae8); }
.avatar.a-iris { background: linear-gradient(160deg, #40c8e0, #0a7ea4); }
.avatar.neutral { background: var(--fill); color: var(--ink-2); }

.main { padding: 32px 40px 64px; max-width: 1320px; width: 100%; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 24px; }
.page-head.sticky {
  position: sticky; top: 0; z-index: 5; align-items: center; margin: 0 -40px 16px; padding: 14px 40px;
  background: color-mix(in srgb, var(--bg) 75%, transparent);
  backdrop-filter: blur(20px) saturate(180%); -webkit-backdrop-filter: blur(20px) saturate(180%);
  -webkit-mask-image: linear-gradient(#000 85%, transparent); mask-image: linear-gradient(#000 85%, transparent);
}
.banner { display: inline-block; font-size: 0.75rem; font-weight: 600; color: var(--warn); background: color-mix(in srgb, var(--warn) 12%, transparent);
  padding: 4px 10px; border-radius: 999px; margin-bottom: 14px; }
.notice { background: var(--accent-soft); color: var(--ink); padding: 12px 16px; border-radius: var(--r-sm); margin-bottom: 20px; }
.grid { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 20px; align-items: start; }
.col-main, .col-side, .stack-lg { display: flex; flex-direction: column; gap: 20px; min-width: 0; }

/* Flächen: Material statt Rahmen */
.card { background: var(--surface); border-radius: var(--r); padding: 20px 22px; box-shadow: var(--shadow-sm); }
.card-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.card.empty { text-align: center; padding: 48px 24px; }
.count { background: var(--accent); color: var(--accent-ink); border-radius: 999px; min-width: 22px; height: 22px; padding: 0 7px;
  display: inline-grid; place-items: center; font-size: 0.75rem; font-weight: 600; }
.count-soft { color: var(--muted); font-weight: 500; }

.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 20px; }
.kpi { background: var(--surface); border-radius: var(--r); padding: 18px 20px; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; gap: 2px; }
.kpi span { color: var(--muted); font-size: 0.8125rem; }
.kpi strong { font-size: 1.75rem; line-height: 1.15; letter-spacing: -0.028em; font-weight: 700; font-variant-numeric: tabular-nums; }
.kpi em { color: var(--muted); font-size: 0.75rem; font-style: normal; }

/* Diagramm */
.chart { width: 100%; height: auto; display: block; }
.chart .grid-line { stroke: var(--sep); stroke-width: 1; }
.chart .axis { fill: var(--muted); font-size: 11px; font-variant-numeric: tabular-nums; }
.chart .line { fill: none; stroke-width: 2.25; stroke-linejoin: round; stroke-linecap: round; }
.chart .invested { fill: none; stroke: var(--muted); stroke-width: 1.25; stroke-dasharray: 4 5; opacity: 0.8; }
.chart .s0, .legend .s0 { stroke: var(--s0); background: var(--s0); }
.chart .s1, .legend .s1 { stroke: var(--s1); background: var(--s1); }
.chart .s2, .legend .s2 { stroke: var(--s2); background: var(--s2); }
.chart .s3, .legend .s3 { stroke: var(--s3); background: var(--s3); }
.legend { list-style: none; display: flex; gap: 18px; padding: 0; margin: 12px 0 0; color: var(--muted); font-size: 0.8125rem; flex-wrap: wrap; }
.legend i { display: inline-block; width: 12px; height: 12px; border-radius: 4px; margin-right: 6px; vertical-align: -1px; }
.legend i.dash { height: 2px; border-radius: 1px; vertical-align: 3px; background: repeating-linear-gradient(90deg, var(--muted) 0 3px, transparent 3px 6px); }

/* Tabellen & Listen */
.table-wrap { overflow-x: auto; margin: 0 -6px; }
table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
th { text-align: left; font-weight: 500; color: var(--muted); font-size: 0.75rem; padding: 6px; border-bottom: 1px solid var(--sep); }
td { padding: 12px 6px; border-bottom: 1px solid var(--sep); white-space: nowrap; font-size: 0.875rem; }
tr:last-child td { border-bottom: 0; }
.tag { font-size: 0.75rem; padding: 2px 8px; border-radius: 999px; background: var(--fill-2); color: var(--ink-2); }
.tag.sim { background: var(--accent-soft); color: var(--accent); }
.tag.bad { background: color-mix(in srgb, var(--neg) 12%, transparent); color: var(--neg); }
.positions, .keys, .codes, .people, .plain { list-style: none; margin: 0; padding: 0; }
.positions li, .keys li, .plain li { display: flex; justify-content: space-between; gap: 10px; padding: 11px 0; border-bottom: 1px solid var(--sep); }
.positions li:last-child, .keys li:last-child, .plain li:last-child { border-bottom: 0; }
.positions span, .keys span, .plain span { display: block; font-size: 0.75rem; color: var(--muted); }
.positions .r { white-space: nowrap; } .positions .r span { color: inherit; }
.plain li { flex-direction: column; gap: 0; }
.codes { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; font-family: ui-monospace, monospace; margin: 10px 0 14px; }

/* Personen, Urlaub, Bewerbungen */
.people li { display: grid; grid-template-columns: minmax(0, 1fr) minmax(160px, 260px); gap: 16px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--sep); }
.people li:last-child { border-bottom: 0; }
.meter-wrap { display: flex; flex-direction: column; gap: 4px; }
.meter { width: 100%; height: 6px; display: block; }
.meter .track { fill: var(--fill); } .meter .fill { fill: var(--accent); }
.num { font-size: 0.75rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.board { display: grid; grid-template-columns: repeat(5, minmax(128px, 1fr)); gap: 10px; overflow-x: auto; padding-bottom: 4px; }
.lane { background: var(--fill-2); border-radius: var(--r-sm); padding: 10px; min-height: 120px; min-width: 0; }
.ticket { background: var(--surface); border-radius: 10px; padding: 10px 12px; box-shadow: var(--shadow-sm); margin-bottom: 8px; }
.ticket strong { display: block; font-size: 0.875rem; } .ticket span { font-size: 0.75rem; color: var(--muted); }
.ticket p { font-size: 0.75rem; color: var(--ink-2); margin: 6px 0 0; }
.request { padding: 12px 0; border-bottom: 1px solid var(--sep); display: flex; flex-direction: column; gap: 4px; }
.request:last-child { border-bottom: 0; }
.request > span { font-size: 0.8125rem; color: var(--muted); }
.doc { border-bottom: 1px solid var(--sep); padding: 10px 0; }
.doc:last-child { border-bottom: 0; }
.doc summary { display: flex; justify-content: space-between; align-items: center; gap: 8px; cursor: pointer; list-style: none; }
.doc summary .tag { flex: none; }
.doc summary::-webkit-details-marker { display: none; }
.doc-body { white-space: pre-wrap; font: 0.8125rem/1.55 system-ui, sans-serif; background: var(--fill-2); padding: 12px; border-radius: 10px; margin: 10px 0; }

/* Team */
.team-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 20px; }
.agent-card { display: flex; flex-direction: column; gap: 14px; }
.who { display: flex; gap: 10px; align-items: center; }
.who strong { display: block; font-size: 0.875rem; } .who div > span { font-size: 0.75rem; color: var(--muted); display: block; }
.who.big h2 { font-size: 1.375rem; letter-spacing: -0.02em; } .who.big div > span { font-size: 0.875rem; }
.persona { color: var(--ink-2); margin: 0; font-size: 0.875rem; }
.facts { margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px 16px; }
.facts dt { font-size: 0.6875rem; color: var(--muted); font-weight: 600; } .facts dd { margin: 0; font-size: 0.8125rem; }
.autonomy { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.autonomy li { display: flex; justify-content: space-between; font-size: 0.8125rem; }
.autonomy span:first-child { text-transform: capitalize; color: var(--ink-2); }
.level { font-size: 0.75rem; padding: 1px 8px; border-radius: 999px; background: var(--fill-2); }
.level.l3, .level.l4 { background: color-mix(in srgb, var(--warn) 14%, transparent); color: var(--warn); }
.level.l2 { background: var(--accent-soft); color: var(--accent); }

/* Chat – vertraut wie Nachrichten */
.chat { display: flex; flex-direction: column; gap: 8px; max-width: 760px; margin: 0 auto; padding-bottom: 110px; }
.bubble { max-width: 82%; padding: 10px 14px; border-radius: 20px; white-space: pre-wrap; line-height: 1.42; }
.bubble.user { align-self: flex-end; background: var(--accent); color: #fff; border-bottom-right-radius: 6px; }
.bubble.agent { align-self: flex-start; background: var(--surface); box-shadow: var(--shadow-sm); border-bottom-left-radius: 6px; }
.tool-step { align-self: flex-start; margin: 0 0 0 6px; font-size: 0.75rem; color: var(--muted); }
.tool-step::before { content: "◦ "; }
.chat-empty { text-align: center; color: var(--muted); margin-top: 8vh; }
.suggestions { list-style: none; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.suggestions li { background: var(--surface); box-shadow: var(--shadow-sm); padding: 8px 14px; border-radius: 999px; color: var(--ink-2); font-size: 0.875rem; }
.composer {
  position: fixed; bottom: 16px; left: calc(248px + 40px); right: 40px; max-width: 760px; margin: 0 auto;
  display: flex; gap: 8px; align-items: flex-end; padding: 8px; border-radius: 24px;
  background: color-mix(in srgb, var(--surface) 78%, transparent);
  backdrop-filter: blur(24px) saturate(180%); -webkit-backdrop-filter: blur(24px) saturate(180%);
  box-shadow: var(--shadow-lg);
}
.composer textarea { flex: 1; resize: none; border: 0; background: transparent; color: var(--ink); font: inherit; padding: 9px 10px; outline: none; max-height: 220px; }
.composer .btn { border-radius: 18px; }
.composer.busy { opacity: 0.85; }

/* Freigaben */
.proposal + .proposal { border-top: 1px solid var(--sep); margin-top: 14px; padding-top: 14px; }
.proposal .what { margin: 12px 0 6px; }
.proposal .why, .why, .note p { color: var(--muted); font-size: 0.875rem; margin: 0 0 12px; }
.note p { margin-top: 10px; }
.approve { display: flex; flex-direction: column; gap: 8px; margin-bottom: 8px; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* Bedienelemente – Feedback sofort beim Drücken */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; white-space: nowrap;
  font: inherit; font-weight: 500; letter-spacing: -0.01em; border-radius: 980px; padding: 9px 18px;
  border: 0; cursor: pointer; text-decoration: none !important;
  transition: transform 100ms var(--ease), background-color 150ms var(--ease), opacity 150ms var(--ease);
}
.btn:active:not(:disabled) { transform: scale(0.97); }
.btn.sm { padding: 6px 14px; font-size: 0.8125rem; }
.btn.wide { width: 100%; }
.btn.primary { background: var(--accent); color: var(--accent-ink); }
.btn.primary:hover:not(:disabled) { background: color-mix(in srgb, var(--accent) 88%, #000); }
.btn.secondary { background: var(--fill); color: var(--ink); }
.btn.secondary:hover:not(:disabled) { background: color-mix(in srgb, var(--fill) 100%, var(--fill)); filter: brightness(0.97); }
.btn.ghost { background: transparent; color: var(--accent); }
.btn.ghost:hover:not(:disabled) { background: var(--accent-soft); }
.btn:disabled { opacity: 0.45; cursor: not-allowed; }
input, select {
  font: inherit; width: 100%; padding: 10px 12px; border: 1px solid transparent; border-radius: 10px;
  background: var(--fill-2); color: var(--ink); margin-top: 4px; transition: background-color 120ms var(--ease), box-shadow 120ms var(--ease);
}
input:focus, select:focus { outline: none; background: var(--surface); box-shadow: 0 0 0 3px var(--accent-soft), 0 0 0 1px var(--accent); }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 55%, transparent); outline-offset: 2px; }
input.code { font-size: 1.5rem; letter-spacing: 0.35em; text-align: center; font-variant-numeric: tabular-nums; }
label { display: block; font-size: 0.8125rem; color: var(--muted); }
.stack { display: flex; flex-direction: column; gap: 14px; }
.row { display: flex; gap: 10px; margin-top: 12px; align-items: center; }
.row input { margin: 0; }
.hint { font-size: 0.8125rem; color: var(--muted); min-height: 1em; }
.alert { background: color-mix(in srgb, var(--neg) 10%, transparent); color: var(--neg); padding: 10px 14px; border-radius: 10px; }

/* Anmeldung */
body.auth { min-height: 100vh; display: grid; place-items: center; padding: 16px;
  background: radial-gradient(900px 500px at 50% -10%, color-mix(in srgb, var(--accent) 16%, transparent), transparent), var(--bg); }
.auth-card { width: 100%; max-width: 380px; background: var(--surface); border-radius: 22px; padding: 36px 30px; box-shadow: var(--shadow-lg); }
.auth-card h1 { font-size: 1.375rem; text-align: center; }
.auth-card .muted { text-align: center; }
.or { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 0.8125rem; margin: 18px 0; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--sep); }
.fine { font-size: 0.75rem; color: var(--muted); text-align: center; margin: 20px 0 0; }

/* Anpassung an Bildschirmgröße */
@media (max-width: 1180px) { .grid { grid-template-columns: 1fr; } .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 800px) {
  .shell { grid-template-columns: minmax(0, 1fr); }
  .side, .side nav { min-width: 0; max-width: 100%; }
  .side { position: sticky; z-index: 10; height: auto; flex-direction: row; flex-wrap: wrap; align-items: center; gap: 8px; padding: 10px 16px; border-right: 0; border-bottom: 1px solid var(--sep); }
  .side nav { flex-direction: row; flex-wrap: wrap; } .nav-label, .side-agents, .ico { display: none; }
  .main { padding: 20px 16px 48px; }
  .page-head.sticky { margin: 0 -16px 12px; padding: 12px 16px; }
  .shell { background: none; }
  .composer { left: 16px; right: 16px; }
  .people li { grid-template-columns: 1fr; gap: 8px; }
  h1 { font-size: 1.625rem; }
}

/* Barrierefreiheit: Systemeinstellungen respektieren */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 1ms !important; animation-duration: 1ms !important; scroll-behavior: auto !important; }
  .btn:active:not(:disabled) { transform: none; }
}
@media (prefers-reduced-transparency: reduce) {
  .side, .composer, .page-head.sticky { backdrop-filter: none; -webkit-backdrop-filter: none; background: var(--surface); }
}
@media (prefers-contrast: more) {
  :root { --sep: rgba(0, 0, 0, 0.35); --muted: #3a3a3c; }
  .card, .kpi, .auth-card { box-shadow: none; border: 1px solid var(--sep); }
  input, select { border-color: var(--sep); }
}

/* ===================== Heute, Palette, Toasts, Bewegung ===================== */

.brand { text-decoration: none !important; color: var(--ink); }
.brand svg.mark { width: 28px; height: 28px; border-radius: 8px; box-shadow: 0 2px 8px rgba(47, 107, 255, 0.35); }
.palette-trigger {
  display: flex; align-items: center; gap: 8px; width: 100%; margin-top: -4px;
  padding: 8px 10px; border: 0; border-radius: 10px; background: var(--fill-2); color: var(--muted);
  font: inherit; font-size: 0.8125rem; cursor: pointer; transition: background-color 120ms var(--ease);
}
.palette-trigger:hover { background: var(--fill); color: var(--ink-2); }
.palette-trigger svg { width: 16px; height: 16px; flex: none; }
.palette-trigger span { flex: 1; text-align: left; }
kbd { font: 600 0.6875rem/1 system-ui, sans-serif; color: var(--muted); background: var(--surface); border-radius: 5px; padding: 3px 5px; box-shadow: 0 0 0 1px var(--sep); }

/* Seiteneinstieg: weich, ohne Hüpfen */
.main > * { animation: rise 420ms cubic-bezier(0.2, 0.8, 0.2, 1) both; }
.main > *:nth-child(2) { animation-delay: 40ms; } .main > *:nth-child(3) { animation-delay: 80ms; }
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* Heute */
.hero { max-width: 860px; margin: 8px 0 32px; }
.eyebrow { font-size: 0.8125rem; font-weight: 600; color: var(--muted); margin: 0 0 6px; letter-spacing: 0.01em; }
.display { font-size: clamp(2.4rem, 4.6vw, 3.5rem); line-height: 1.02; letter-spacing: -0.035em; font-weight: 700; margin: 0;
  background: linear-gradient(100deg, var(--ink) 30%, color-mix(in srgb, var(--accent) 70%, var(--ink)) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent; }
.lede { font-size: 1.1875rem; line-height: 1.4; letter-spacing: -0.012em; color: var(--ink-2); margin: 10px 0 24px; }
.lede a { font-weight: 600; }
.ask { background: var(--surface); border-radius: 22px; padding: 14px; box-shadow: var(--shadow-lg); display: flex; flex-direction: column; gap: 10px; }
.ask-agents { display: flex; gap: 6px; flex-wrap: wrap; }
.agent-pick { position: relative; display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px 5px 5px; border-radius: 999px;
  background: var(--fill-2); color: var(--ink-2); font-size: 0.875rem; cursor: pointer; transition: background-color 150ms var(--ease), box-shadow 150ms var(--ease); }
.agent-pick input { position: absolute; opacity: 0; inset: 0; cursor: pointer; margin: 0; }
.agent-pick:has(input:checked) { background: var(--accent-soft); color: var(--accent); box-shadow: inset 0 0 0 1.5px var(--accent); font-weight: 600; }
.agent-pick:has(input:focus-visible) { outline: 3px solid color-mix(in srgb, var(--accent) 55%, transparent); outline-offset: 2px; }
.ask-field { display: flex; gap: 8px; align-items: flex-end; }
.ask-field textarea { flex: 1; resize: none; border: 0; outline: none; background: transparent; color: var(--ink); font: inherit; font-size: 1.0625rem; padding: 10px 6px; max-height: 220px; }
.ask.busy { opacity: 0.85; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chips.center { justify-content: center; }
.chip { text-align: left; border: 0; font: inherit; font-size: 0.8125rem; padding: 6px 12px; border-radius: 999px; cursor: pointer;
  background: var(--fill-2); color: var(--ink-2); transition: background-color 120ms var(--ease), transform 100ms var(--ease); }
.chip:hover { background: var(--accent-soft); color: var(--accent); }
.chip:active { transform: scale(0.97); }

.today-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr); gap: 20px; align-items: start; }
.today-col { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.inbox { list-style: none; margin: 0; padding: 0; }
.inbox-item { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--sep); }
.inbox-item:last-child { border-bottom: 0; }
.inbox-body { flex: 1; min-width: 0; }
.inbox-body strong { display: block; font-size: 0.9375rem; }
.inbox-body span { display: block; font-size: 0.8125rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kind { width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; flex: none; font-weight: 700; color: #fff; }
.k-order { background: linear-gradient(160deg, #3a8dff, #0058c2); }
.k-absence { background: linear-gradient(160deg, #ff9f0a, #e5631a); }
.k-doc { background: linear-gradient(160deg, #bf5af2, #8944ab); }
.inline-actions { display: flex; gap: 4px; }
.all-done { text-align: center; color: var(--pos); padding: 28px 0 12px; }
.all-done svg { width: 56px; height: 56px; }
.all-done p { color: var(--muted); margin: 8px 0 0; }
.more { display: inline-block; margin-top: 10px; font-size: 0.875rem; }
a.card { color: var(--ink); text-decoration: none; transition: transform 200ms cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 200ms var(--ease); }
a.card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.glance-head { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.glance-num { font-size: 2rem; font-weight: 700; letter-spacing: -0.03em; line-height: 1.1; margin: 0; font-variant-numeric: tabular-nums; }
.glance-num small { font-size: 1rem; font-weight: 500; color: var(--muted); letter-spacing: 0; }
.glance-sub { margin: 4px 0 0; color: var(--ink-2); font-size: 0.875rem; font-variant-numeric: tabular-nums; }
.glance-note { margin: 12px 0 0; color: var(--muted); font-size: 0.8125rem; }
.team-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; }
.team-list a { display: flex; gap: 12px; align-items: flex-start; padding: 10px; border-radius: 14px; color: var(--ink); text-decoration: none; transition: background-color 120ms var(--ease); }
.team-list a:hover { background: var(--fill-2); }
.team-text strong { display: block; } .team-text small { display: block; color: var(--muted); font-size: 0.75rem; }
.team-text em { display: block; font-style: normal; color: var(--ink-2); font-size: 0.8125rem; margin-top: 6px; line-height: 1.35; }
.avatar { position: relative; }
.presence { position: absolute; right: -1px; bottom: -1px; width: 11px; height: 11px; border-radius: 50%; background: #30d158; box-shadow: 0 0 0 2px var(--surface); }
.avatar.xl { width: 72px; height: 72px; font-size: 1.75rem; margin: 0 auto 14px; }
.avatar.a-kai { background: linear-gradient(160deg, #64d2ff, #5e5ce6); }
.status-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; font-size: 0.875rem; }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 10px; vertical-align: 1px; }
.dot.on { background: var(--pos); box-shadow: 0 0 0 3px color-mix(in srgb, var(--pos) 18%, transparent); }
.dot.off { background: var(--neg); } .dot.idle { background: var(--muted); }
.agent-chip.helper { margin-left: 14px; }
.chat-empty h2 { font-size: 1.375rem; letter-spacing: -0.02em; margin-bottom: 4px; color: var(--ink); }
.chat-empty .muted { max-width: 460px; margin: 0 auto 18px; }
.chips.follow { align-self: flex-start; margin-top: 6px; }

/* Befehlspalette */
.palette { border: 0; padding: 0; background: transparent; text-align: left; color: var(--ink); width: min(640px, calc(100vw - 32px)); margin: 12vh auto auto; overflow: visible; }
.palette::backdrop { background: rgba(0, 0, 0, 0.28); backdrop-filter: blur(2px); }
.palette[open] .palette-box { animation: pop 220ms cubic-bezier(0.2, 0.9, 0.3, 1.1) both; }
@keyframes pop { from { opacity: 0; transform: scale(0.97) translateY(-6px); } to { opacity: 1; transform: none; } }
.palette-box { background: color-mix(in srgb, var(--surface) 88%, transparent); backdrop-filter: blur(30px) saturate(180%); -webkit-backdrop-filter: blur(30px) saturate(180%);
  border-radius: 18px; box-shadow: 0 30px 80px rgba(0, 0, 0, 0.3), 0 0 0 1px var(--sep); overflow: hidden; }
.palette-input { width: 100%; margin: 0; border: 0; border-bottom: 1px solid var(--sep); border-radius: 0; background: transparent; font-size: 1.125rem; padding: 18px 20px; }
.palette-input:focus { box-shadow: none; background: transparent; }
.palette-list { list-style: none; margin: 0; padding: 6px; max-height: 50vh; overflow-y: auto; }
.palette-list .palette-item { display: flex; flex-direction: row; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 10px; cursor: pointer; text-align: left; }
.palette-item small { flex: none; }
.palette-item small { color: var(--muted); font-size: 0.75rem; }
.palette-item.active { background: var(--accent); color: #fff; }
.palette-item.active small { color: rgba(255, 255, 255, 0.8); }
.palette-item.ask span::before { content: "↗ "; opacity: 0.7; }
.palette-empty { padding: 14px; color: var(--muted); font-size: 0.875rem; }
.palette-foot { margin: 0; padding: 10px 16px; border-top: 1px solid var(--sep); font-size: 0.75rem; color: var(--muted); display: flex; gap: 4px; align-items: center; }

/* Toast */
.toast { position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%); z-index: 50; padding: 12px 20px; border-radius: 999px;
  font-weight: 500; font-size: 0.9375rem; color: #fff; background: rgba(29, 29, 31, 0.92); backdrop-filter: blur(20px);
  box-shadow: var(--shadow-lg); animation: toast-in 380ms cubic-bezier(0.2, 0.9, 0.3, 1.15) both; }
.toast.ok::before { content: "✓  "; color: #30d158; font-weight: 700; }
.toast.warn::before { content: "!  "; color: #ffd60a; font-weight: 700; }
.toast.leave { opacity: 0; transform: translateX(-50%) translateY(8px); transition: opacity 400ms var(--ease), transform 400ms var(--ease); }
@keyframes toast-in { from { opacity: 0; transform: translateX(-50%) translateY(16px) scale(0.96); } to { opacity: 1; transform: translateX(-50%); } }

@media (max-width: 1100px) { .today-grid { grid-template-columns: 1fr; } }
@media (max-width: 800px) {
  .palette-trigger { display: none; }
  .side nav { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; width: 100%; }
  .side nav a { white-space: nowrap; } .logout { display: none; }
  .inbox-item { flex-wrap: wrap; } .inline-actions { width: 100%; padding-left: 46px; }
  .hero { margin-top: 0; } .lede { font-size: 1.0625rem; }
}
@media (prefers-reduced-motion: reduce) {
  .main > *, .palette[open] .palette-box, .toast { animation: none !important; }
  a.card:hover { transform: none; }
}
@media (prefers-reduced-transparency: reduce) { .palette-box { backdrop-filter: none; background: var(--surface); } }

/* ===================== Sprache, Kennenlernen, Alltag ===================== */
.icon-btn { flex: none; width: 40px; height: 40px; border-radius: 50%; border: 0; display: grid; place-items: center; cursor: pointer;
  background: var(--fill-2); color: var(--ink-2); transition: background-color 150ms var(--ease), color 150ms var(--ease), transform 100ms var(--ease); }
.icon-btn:hover { background: var(--fill); color: var(--ink); }
.icon-btn:active { transform: scale(0.94); }
.icon-btn svg { width: 22px; height: 22px; }
.icon-btn.mic.listening { background: #ff3b30; color: #fff; animation: breathe 1.4s ease-in-out infinite; }
@keyframes breathe { 0%, 100% { box-shadow: 0 0 0 0 rgba(255, 59, 48, 0.45); } 50% { box-shadow: 0 0 0 10px rgba(255, 59, 48, 0); } }
.icon-btn.speaker[data-mode="vorlesen"], .icon-btn.speaker[data-mode="gespraech"] { background: var(--accent-soft); color: var(--accent); }
.icon-btn.speaker[data-mode="gespraech"] { box-shadow: inset 0 0 0 2px var(--accent); }
.icon-btn.speaker[data-mode="aus"] .waves { opacity: 0.25; }
body.is-speaking .icon-btn.speaker .waves { animation: wave 900ms ease-in-out infinite; }
@keyframes wave { 50% { opacity: 0.3; } }
.head-actions { display: flex; align-items: center; gap: 8px; }
.head-actions form { margin: 0; }
.dictate-wrap { position: relative; display: block; }
.dictate-wrap .field, .dictate-wrap input, .dictate-wrap textarea { padding-right: 48px; }
.icon-btn.inline { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); width: 34px; height: 34px; background: transparent; margin-top: 2px; }
.icon-btn.inline.listening { transform: translateY(-50%); }
.bubble.agent { position: relative; padding-right: 36px; }
.say { position: absolute; right: 8px; bottom: 8px; width: 22px; height: 22px; border: 0; border-radius: 50%; background: transparent; color: var(--muted);
  cursor: pointer; opacity: 0; transition: opacity 150ms var(--ease); display: grid; place-items: center; padding: 0; }
.say svg { width: 14px; height: 14px; }
.bubble.agent:hover .say, .say:focus-visible { opacity: 1; }
@media (hover: none) { .say { opacity: 0.6; } }
.play-hint { align-self: flex-start; }

/* Kennenlernen */
.onboard { max-width: 640px; margin: 0 auto; }
.onboard-head { display: flex; align-items: center; gap: 16px; margin-bottom: 18px; }
.steps { list-style: none; display: flex; gap: 6px; padding: 0; margin: 0 0 18px; }
.steps li { flex: 1; height: 5px; border-radius: 3px; background: var(--fill); position: relative; transition: background-color 300ms var(--ease); }
.steps li.done { background: color-mix(in srgb, var(--accent) 55%, var(--fill)); }
.steps li.now { background: var(--accent); }
.steps a { position: absolute; inset: -8px 0; }
.onboard-card { padding: 28px; display: flex; flex-direction: column; gap: 10px; }
.intro { background: var(--accent-soft); border-radius: 14px; padding: 14px 16px; margin: 0 0 8px; color: var(--ink); }
.counter { font-size: 0.75rem; font-weight: 600; color: var(--muted); margin: 0; letter-spacing: 0.02em; }
.question { font-size: 1.5rem; line-height: 1.2; letter-spacing: -0.02em; font-weight: 700; color: var(--ink); }
.field { font-size: 1.0625rem; } .field.big { font-size: 1.25rem; padding: 14px 16px; }
textarea.field { font: inherit; width: 100%; padding: 12px 14px; border: 1px solid transparent; border-radius: 12px; background: var(--fill-2); color: var(--ink); resize: vertical; }
textarea.field:focus { outline: none; background: var(--surface); box-shadow: 0 0 0 3px var(--accent-soft), 0 0 0 1px var(--accent); }
.options { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.option { position: relative; color: var(--ink); font-size: 0.9375rem; }
.option input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.option span { display: inline-block; padding: 10px 16px; border-radius: 999px; background: var(--fill-2); transition: background-color 150ms var(--ease), box-shadow 150ms var(--ease); }
.option input:checked + span { background: var(--accent-soft); color: var(--accent); box-shadow: inset 0 0 0 1.5px var(--accent); font-weight: 600; }
.option input:focus-visible + span { outline: 3px solid color-mix(in srgb, var(--accent) 55%, transparent); outline-offset: 2px; }
.onboard-actions { display: flex; gap: 8px; align-items: center; margin-top: 12px; }
.spacer { flex: 1; }
.onboard-card.done { text-align: center; align-items: center; }
.onboard-card.done .check { width: 64px; height: 64px; color: var(--pos); }
.summary { width: 100%; text-align: left; margin: 10px 0 16px; display: flex; flex-direction: column; gap: 10px; }
.summary dt { font-size: 0.75rem; color: var(--muted); } .summary dd { margin: 0; } .summary dd a { font-size: 0.75rem; margin-left: 6px; }
.onboard-link { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 10px; font-size: 0.8125rem; color: var(--ink-2); }
.onboard-link .bar { width: 100%; height: 4px; } .bar .t { fill: var(--fill); } .bar .f { fill: var(--accent); }

/* Heute: Kennenlernen-Hinweis */
.meet { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; margin: -12px 0 24px; padding: 16px 20px;
  border-radius: var(--r); background: linear-gradient(110deg, var(--accent-soft), color-mix(in srgb, #af52de 10%, transparent)); }
.meet strong { display: block; } .meet span { color: var(--ink-2); font-size: 0.875rem; }
.meet ul { list-style: none; display: flex; gap: 8px; margin: 0; padding: 0; flex-wrap: wrap; }
.meet a { display: inline-flex; align-items: center; gap: 8px; padding: 5px 8px 5px 5px; border-radius: 999px; background: var(--surface); color: var(--ink); box-shadow: var(--shadow-sm); text-decoration: none; font-weight: 500; font-size: 0.875rem; }
.ring { width: 22px; height: 22px; transform: rotate(-90deg); }
.ring-track { fill: none; stroke: var(--fill); stroke-width: 4; } .ring-fill { fill: none; stroke: var(--accent); stroke-width: 4; stroke-linecap: round; }
.avatar.a-ella { background: linear-gradient(160deg, #30d158, #0a8f5a); }
.glance-num.small { font-size: 1.375rem; letter-spacing: -0.02em; }

/* Alltag */
.tasks, .checklist, .agenda { list-style: none; margin: 0; padding: 0; }
.tasks li, .checklist li { display: flex; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--sep); }
.tasks li:last-child, .checklist li:last-child { border-bottom: 0; }
.tasks form, .checklist form { margin: 0; }
.tasks strong { display: block; } .tasks span { font-size: 0.8125rem; color: var(--muted); }
.tasks li.overdue span { color: var(--neg); }
.tick { width: 24px; height: 24px; border-radius: 50%; border: 2px solid color-mix(in srgb, var(--muted) 60%, transparent); background: transparent; cursor: pointer; padding: 0;
  transition: border-color 150ms var(--ease), background-color 150ms var(--ease), transform 100ms var(--ease); }
.tick:hover { border-color: var(--pos); background: color-mix(in srgb, var(--pos) 12%, transparent); }
.tick:active { transform: scale(0.9); background: var(--pos); }
.tick.sm { width: 20px; height: 20px; }
.quick-add { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1.3fr) auto; gap: 8px; margin-top: 14px; align-items: center; }
.quick-add input { margin: 0; }
.agenda li { display: flex; gap: 16px; padding: 10px 0; border-bottom: 1px solid var(--sep); align-items: center; }
.agenda li:last-child { border-bottom: 0; }
.agenda time { width: 58px; flex: none; text-align: center; font-size: 0.75rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.agenda time b { display: block; font-size: 1rem; color: var(--accent); }
.agenda strong { display: block; } .agenda span { font-size: 0.8125rem; color: var(--muted); }
@media (max-width: 800px) { .quick-add { grid-template-columns: 1fr 1fr; } .quick-add input[name=titel] { grid-column: 1 / -1; } .meet { margin-top: 0; } }
@media (prefers-reduced-motion: reduce) { .icon-btn.mic.listening, body.is-speaking .icon-btn.speaker .waves { animation: none; } }

#ende { display: block; scroll-margin-bottom: 120px; }
@media (max-width: 800px) {
  .side { position: relative; }
  .page-head.sticky { position: relative; backdrop-filter: none; -webkit-backdrop-filter: none; background: transparent; -webkit-mask-image: none; mask-image: none; }
}

/* ===================== Über mich / Profil ===================== */
.profile-layout { display: grid; grid-template-columns: 220px minmax(0, 760px); gap: 32px; align-items: start; }
.profile-layout:not(:has(.profile-nav)) { grid-template-columns: minmax(0, 760px); }
.profile-nav { position: sticky; top: 24px; }
.profile-nav .back { font-size: 0.875rem; display: inline-block; margin-bottom: 12px; }
.profile-nav ol { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; counter-reset: s; }
.profile-nav li a { display: block; padding: 7px 10px; border-radius: 8px; color: var(--ink-2); font-size: 0.875rem; text-decoration: none; counter-increment: s; }
.profile-nav li a::before { content: counter(s) ". "; color: var(--muted); }
.profile-nav li a.on { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.profile-head { display: flex; gap: 16px; align-items: flex-start; margin-bottom: 18px; }
.lede.small { font-size: 1rem; margin: 6px 0 0; }
.audience { display: inline-flex; align-items: center; gap: 6px; font-size: 0.8125rem; color: var(--muted); margin: 10px 0 0; }
.audience svg { width: 16px; height: 16px; } .audience.small { margin-top: 10px; font-size: 0.75rem; }
.q-group { display: flex; flex-direction: column; gap: 22px; margin-bottom: 18px; padding: 24px; }
.q-group h2 small { font-weight: 400; color: var(--muted); font-size: 0.8125rem; }
.q { display: flex; flex-direction: column; gap: 6px; scroll-margin-top: 24px; }
.q-label { font-size: 1.0625rem; font-weight: 600; color: var(--ink); letter-spacing: -0.01em; line-height: 1.3; }
.q-help { margin: 0; font-size: 0.8125rem; color: var(--muted); }
.q-flag { font-size: 0.6875rem; font-weight: 600; padding: 2px 7px; border-radius: 999px; background: var(--fill-2); color: var(--muted); vertical-align: 2px; }
.q-flag.must { background: var(--accent-soft); color: var(--accent); }
.q-bad .field { box-shadow: 0 0 0 2px var(--neg); }
.field.num { max-width: 220px; }
.journal { list-style: none; margin: 6px 0 0; padding: 0 0 0 12px; border-left: 2px solid var(--fill); display: flex; flex-direction: column; gap: 6px; font-size: 0.875rem; color: var(--ink-2); }
.profile-actions { display: flex; gap: 8px; align-items: center; position: sticky; bottom: 12px; padding: 10px; border-radius: 18px;
  background: color-mix(in srgb, var(--surface) 82%, transparent); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); box-shadow: var(--shadow-lg); }
.me-hero { display: flex; align-items: center; gap: 20px; margin-bottom: 20px; flex-wrap: wrap; }
.me-hero-text { flex: 1; min-width: 220px; }
.ring.big { width: 72px; height: 72px; }
.ring-text { font-size: 8px; font-weight: 700; fill: var(--ink); transform: rotate(90deg); transform-origin: 18px 18px; }
.me-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; margin-bottom: 24px; }
.me-card { display: flex; flex-direction: column; gap: 8px; }
.me-card-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.me-card .bar { width: 100%; height: 4px; margin-top: auto; }
.me-pct { font-size: 0.8125rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.me-pct.done { color: var(--pos); font-weight: 600; }
.section-title { font-size: 0.8125rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted); margin: 8px 0 12px; }
.intro.wide { max-width: 760px; margin: -6px 0 22px; }
.shared-list { list-style: none; padding: 6px 20px; margin: 0; }
.shared-list li a { display: flex; justify-content: space-between; padding: 12px 0; border-bottom: 1px solid var(--sep); color: var(--ink); text-decoration: none; }
.shared-list li:last-child a { border-bottom: 0; }
.shared-list span { color: var(--muted); font-variant-numeric: tabular-nums; }
.meet a.primary-pill { background: var(--accent); color: #fff; padding-left: 14px; }
.meet a.primary-pill .ring-track { stroke: rgba(255, 255, 255, 0.35); } .meet a.primary-pill .ring-fill { stroke: #fff; }
@media (max-width: 900px) { .profile-layout { grid-template-columns: 1fr; } .profile-nav { position: static; } .profile-nav ol { flex-direction: row; flex-wrap: wrap; } }
.profile-form { min-width: 0; }
@media (max-width: 900px) {
  .profile-layout, .profile-layout:not(:has(.profile-nav)) { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .profile-nav ol { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; gap: 4px; padding-bottom: 4px; }
  .profile-nav li a { white-space: nowrap; background: var(--fill-2); border-radius: 999px; padding: 6px 12px; }
  .profile-head .avatar.lg { width: 40px; height: 40px; font-size: 1rem; }
  .profile-head h1 { font-size: 1.625rem; }
  .q-group { padding: 18px; }
  .q-label { font-size: 1rem; }
}
@media (max-width: 600px) {
  .profile-actions { gap: 4px; padding: 8px; }
  .profile-actions .btn { padding: 9px 12px; font-size: 0.875rem; }
  .profile-actions .spacer { display: none; }
  .profile-actions .btn.primary { flex: 1; }
}

/* Sicherheit / Datenschutz */
.checks { list-style: none; margin: 0; padding: 0; }
.checks li { display: flex; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--sep); align-items: flex-start; }
.checks li:last-child { border-bottom: 0; }
.checks i { flex: none; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-weight: 700; font-size: 0.75rem; color: #fff; }
.checks .c-ok i { background: var(--pos); } .checks .c-warn i { background: #ff9f0a; } .checks .c-fail i { background: var(--neg); }
.checks strong { display: block; font-weight: 500; } .checks span { display: block; font-size: 0.8125rem; color: var(--muted); }
.check-sum { font-size: 0.75rem; font-weight: 600; padding: 3px 10px; border-radius: 999px; }
.check-sum.ok { background: color-mix(in srgb, var(--pos) 14%, transparent); color: var(--pos); }
.check-sum.warn { background: color-mix(in srgb, #ff9f0a 16%, transparent); color: var(--warn); }
.check-sum.bad { background: color-mix(in srgb, var(--neg) 14%, transparent); color: var(--neg); }
tr.denied td { color: var(--neg); }
.danger { margin-top: 14px; } .danger summary { cursor: pointer; color: var(--neg); font-size: 0.875rem; }
.danger form { margin-top: 10px; }
.btn.danger-btn { background: var(--neg); color: #fff; }
a.btn[aria-disabled=true] { opacity: 0.45; pointer-events: none; }

/* Verwaltung & Betrieb */
.checks { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.checks li { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 10px; padding: 12px 4px; border-bottom: 1px solid var(--sep); }
.checks li:last-child { border-bottom: 0; }
.checks strong { display: block; font-weight: 600; }
.checks span { color: var(--muted); font-size: 0.875rem; overflow-wrap: anywhere; }
.checks code { display: block; margin-top: 6px; font-size: 0.8125rem; background: var(--fill-2); padding: 6px 10px; border-radius: 8px; overflow-wrap: anywhere; white-space: pre-wrap; }
.st { width: 12px; height: 12px; border-radius: 50%; margin-top: 5px; background: var(--muted); }
.st.ok { background: var(--pos); } .st.warn { background: var(--warn); } .st.fail { background: var(--neg); }
.tag.warn { background: color-mix(in srgb, var(--warn) 14%, transparent); color: var(--warn); }
.tag.good { background: color-mix(in srgb, var(--pos) 14%, transparent); color: var(--pos); }
.brief { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; font-size: 0.9375rem; }
.brief li { display: grid; grid-template-columns: 8px minmax(0, 1fr); gap: 10px; align-items: baseline; }
.brief li::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--muted); }
.brief li.p1::before { background: var(--neg); } .brief li.p2::before { background: var(--warn); }
.brief a { color: inherit; text-decoration: none; } .brief a:hover { color: var(--accent); }
.brief small { color: var(--muted); margin-left: 6px; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px; }
.form-grid .wide { grid-column: 1 / -1; }
.card-head h2 .avatar { vertical-align: -6px; margin-right: 6px; }
.card-head h2:has(.avatar) { display: flex; align-items: center; gap: 8px; } .card-head h2:has(.avatar) .avatar { margin: 0; }

/* Privater Modus (lokales Modell) */
.private-toggle { display: inline-flex; align-items: center; gap: 6px; font-size: 0.8125rem; color: var(--muted); white-space: nowrap; cursor: pointer; padding: 0 6px; }
.private-toggle input { accent-color: var(--accent); width: 16px; height: 16px; }
.private-toggle:has(input:checked) { color: var(--accent); font-weight: 600; }
.bubble.private { outline: 1.5px dashed color-mix(in srgb, var(--accent) 45%, transparent); outline-offset: 2px; }
.bubble .lock { display: block; font-size: 0.6875rem; font-weight: 600; color: var(--accent); margin-bottom: 4px; letter-spacing: 0.02em; }
.bubble.user .lock { color: rgba(255, 255, 255, 0.85); }
.composer .private-toggle { align-self: center; }

/* Gesprächsrunden */
.pick-agents { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.pick-agents legend { margin-bottom: 6px; font-size: 0.8125rem; }
.pick-agents .agent-pick:has(input:checked) { background: var(--accent-soft); color: var(--accent); }
label.check { display: flex; align-items: center; gap: 8px; font-size: 0.875rem; }
.round-log { display: flex; flex-direction: column; gap: 14px; }
.round-turn { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: 12px; }
.round-turn p { margin: 4px 0 0; white-space: pre-wrap; line-height: 1.5; overflow-wrap: anywhere; }
.result .prose { white-space: pre-wrap; line-height: 1.55; overflow-wrap: anywhere; }
.checks li > .avatar { margin-top: 2px; }

/* Ideen */
.idea { border-bottom: 1px solid var(--sep); padding: 12px 0; }
.idea:last-child { border-bottom: 0; }
.idea summary { display: grid; grid-template-columns: 46px minmax(0, 1fr) auto; gap: 12px; align-items: center; cursor: pointer; list-style: none; }
.idea summary::-webkit-details-marker { display: none; }
.score { width: 42px; height: 42px; border-radius: 12px; display: grid; place-items: center; font-weight: 700; font-variant-numeric: tabular-nums;
  background: var(--accent-soft); color: var(--accent); }
.idea-title strong { display: block; } .idea-title small { color: var(--muted); }
.idea-body { padding: 10px 0 4px 58px; font-size: 0.9375rem; }
.idea-body p { margin: 6px 0; }
.bars { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 6px 10px; align-items: center; margin: 12px 0; font-size: 0.8125rem; }
.bar { height: 6px; border-radius: 3px; background: var(--fill-2); overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--accent); border-radius: 3px; }
.bar i.w1 { width: 20%; } .bar i.w2 { width: 40%; } .bar i.w3 { width: 60%; } .bar i.w4 { width: 80%; } .bar i.w5 { width: 100%; }
.bar-val { color: var(--muted); font-variant-numeric: tabular-nums; }
.two-col { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; margin: 8px 0; }
.two-col ul, .idea-body ol { margin: 4px 0; padding-left: 18px; }
.inline-form { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 10px; }
.signal { width: 22px; height: 22px; border-radius: 7px; display: grid; place-items: center; font-size: 0.75rem; font-weight: 700; background: var(--fill-2); color: var(--ink-2); }
.signal.s4, .signal.s5 { background: var(--accent-soft); color: var(--accent); }
.checks li span + span { display: block; }
.avatar.a-nova { background: linear-gradient(160deg, #ff6482, #d6336c); }
@media (max-width: 800px) { .idea-body { padding-left: 0; } .idea summary { grid-template-columns: 42px minmax(0, 1fr); } .idea summary .tag { grid-column: 2; justify-self: start; } }
.checks li:has(> .avatar) { grid-template-columns: 28px minmax(0, 1fr); }
.checks li > .avatar.sm { color: #fff; font-size: 0.8125rem; font-weight: 600; display: grid; place-items: center; }
.mode-form { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.mode-form select { max-width: 100%; font-size: 0.8125rem; }
.consent { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 12px 14px; border-radius: 14px;
  background: var(--accent-soft); margin: 8px 0; }
.consent p { flex: 1 1 260px; margin: 0; font-size: 0.875rem; overflow-wrap: anywhere; }
.reask { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 4px 0; font-size: 0.8125rem; }
.avatar.a-lea { background: linear-gradient(160deg, #5ac8a8, #1f7a6d); }
.avatar.a-finn { background: linear-gradient(160deg, #ffb340, #ff7a00); }
.checks li.muted { display: block; }

/* ==========================================================================================
   Gestaltung „Wegweiser“
   Bild: deutsche Wegweiser und Emaille-Schilder. Eine Leitstand-Seite für ein persönliches Team.
   Tinte  #15233F  Grundfarbe, Seitenleiste, Primärknöpfe
   Mineral #E4E9EC  Fläche (kühl, wie lackiertes Blech)
   Emaille #FFFFFF  Schildflächen
   Verkehrsblau #1E5AA8  Links und Auswahl
   Signalgelb #F5C400  NUR für „wartet auf deine Entscheidung“
   Schrift: DIN-artige Schmalschrift für Überschriften (Bahnschrift, DIN Alternate), Systemschrift für Text.
   ========================================================================================== */
:root {
  --bg: #e4e9ec; --surface: #ffffff; --surface-2: #f3f6f8;
  --ink: #15233f; --ink-2: #2e3d5a; --muted: #5d6b7e;
  --sep: rgba(21, 35, 63, 0.13); --fill: rgba(21, 35, 63, 0.08); --fill-2: rgba(21, 35, 63, 0.05);
  --accent: #1e5aa8; --accent-ink: #ffffff; --accent-soft: rgba(30, 90, 168, 0.1);
  --signal: #f5c400; --signal-ink: #15233f;
  --pos: #1f7a4d; --neg: #b3261e; --warn: #9a5b00;
  --side-bg: #15233f; --side-solid: #15233f; --side-ink: #e8edf3; --side-muted: #95a3b8;
  --shadow-sm: none; --shadow-lg: none;
  --r: 6px; --r-sm: 4px;
  --display: "Bahnschrift", "DIN Alternate", "DIN Next", "D-DIN", "Roboto Condensed", "Arial Narrow", system-ui, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0c1424; --surface: #142038; --surface-2: #1a2742; --ink: #e8edf3; --ink-2: #c7d0dc; --muted: #93a1b5;
    --sep: rgba(232, 237, 243, 0.12); --fill: rgba(232, 237, 243, 0.1); --fill-2: rgba(232, 237, 243, 0.06);
    --accent: #7fb0f0; --accent-ink: #0c1424; --accent-soft: rgba(127, 176, 240, 0.14);
    --side-bg: #08101d; --side-solid: #08101d; --pos: #5fc28f; --neg: #ff8a80; --warn: #e3a948;
  }
}
:root[data-theme="dark"] {
  --bg: #0c1424; --surface: #142038; --surface-2: #1a2742; --ink: #e8edf3; --ink-2: #c7d0dc; --muted: #93a1b5;
  --sep: rgba(232, 237, 243, 0.12); --fill: rgba(232, 237, 243, 0.1); --fill-2: rgba(232, 237, 243, 0.06);
  --accent: #7fb0f0; --accent-ink: #0c1424; --accent-soft: rgba(127, 176, 240, 0.14); --side-bg: #08101d; --side-solid: #08101d;
}

body { letter-spacing: 0; font-size: 0.9375rem; }
h1, h2, .display, .score, .brand span, .card-head h2 { font-family: var(--display); font-stretch: condensed; }
h1 { font-size: 2.5rem; font-weight: 700; letter-spacing: -0.005em; line-height: 1.05; }
h1.h-small { font-size: 1.25rem; }
h2 { font-size: 1.1875rem; font-weight: 600; letter-spacing: 0; }
h3 { text-transform: none; letter-spacing: 0; font-size: 0.8125rem; color: var(--ink-2); font-weight: 700; }
a { color: var(--accent); }

/* Seitenleiste: der Wegweiser-Mast */
.shell { background: linear-gradient(90deg, var(--side-solid) 248px, transparent 248px); }
.side { background: var(--side-bg); color: var(--side-ink); backdrop-filter: none; -webkit-backdrop-filter: none; border-right: 0; }
.brand { color: #fff; font-size: 1.125rem; }
.brand .mark { display: none; }
.brand::before { content: ""; width: 26px; height: 26px; border-radius: 4px; flex: none;
  background: var(--signal) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 26 26'%3E%3Cpath d='M6 9h10l4 4-4 4H6z' fill='%2315233f'/%3E%3C/svg%3E") center/26px no-repeat; }
.brand svg.mark { display: none; }
.side nav a { color: var(--side-ink); border-radius: 0 4px 4px 0; border-left: 3px solid transparent; padding: 7px 10px 7px 9px; }
.side nav a:hover { background: rgba(255, 255, 255, 0.07); }
.side nav a.on { background: rgba(255, 255, 255, 0.1); color: #fff; border-left-color: var(--signal); font-weight: 600; }
.side nav a .ico, .side nav a:not(.on) .ico { color: var(--side-muted); }
.side nav a.on .ico { color: var(--signal); }
.nav-label { color: var(--side-muted); font-weight: 600; }
.palette-trigger { background: rgba(255, 255, 255, 0.08) !important; color: var(--side-ink) !important; border-radius: 4px !important; }
.palette-trigger kbd { background: transparent; color: var(--side-muted); box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.2); }
.agent-chip { color: var(--side-ink); border-radius: 4px; }
.agent-chip small { color: var(--side-muted); }
.agent-chip:hover { background: rgba(255, 255, 255, 0.07); }
.link { color: var(--side-muted); } .link:hover { color: #fff; }

/* Schilder statt schwebender Karten */
.card { border-radius: var(--r); border: 1px solid var(--sep); box-shadow: none; padding: 20px 22px; }
.card-head h2 { font-size: 1.25rem; }
.main > * { animation: none; }
.hero .display { animation: plate 520ms cubic-bezier(0.2, 0.7, 0.2, 1) both; }
@keyframes plate { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
@media (prefers-reduced-motion: reduce) { .hero .display { animation: none; } }

.display { background: none; -webkit-background-clip: initial; background-clip: initial; color: var(--ink);
  font-size: clamp(2.8rem, 6vw, 4.6rem); font-weight: 700; letter-spacing: -0.01em; line-height: 0.95; }
.eyebrow { color: var(--ink-2); font-weight: 600; }
.lede { color: var(--ink-2); }
.lede a { color: var(--ink); background: var(--signal); padding: 0 6px; border-radius: 3px; text-decoration: none; }

/* Bedienelemente */
.btn { border-radius: 4px; font-weight: 600; letter-spacing: 0; }
.btn.primary { background: var(--ink); color: #fff; }
.btn.primary:hover:not(:disabled) { background: color-mix(in srgb, var(--ink) 85%, var(--accent)); }
.btn.secondary { background: var(--surface); color: var(--ink); box-shadow: inset 0 0 0 1px var(--sep); }
.btn.ghost { color: var(--accent); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .btn.primary { background: var(--accent); color: var(--accent-ink); } }
input, select, textarea { border-radius: 4px; background: var(--surface-2); border: 1px solid var(--sep); }
input:focus, select:focus, textarea:focus { box-shadow: 0 0 0 3px var(--accent-soft); border-color: var(--accent); }
.ask { border-radius: 6px; border: 1px solid var(--sep); box-shadow: none; }
.agent-pick { border-radius: 4px; background: var(--surface-2); }
.agent-pick:has(input:checked) { background: var(--ink); color: #fff; box-shadow: none; }
.chip { border-radius: 4px; background: var(--surface-2); box-shadow: inset 0 0 0 1px var(--sep); }
.chip:hover { background: var(--accent-soft); }
.tag { border-radius: 3px; }
.banner { border-radius: 3px; }
.score { border-radius: 4px; background: var(--ink); color: #fff; }

/* Agenten als Schilder: flache Einheitsfarben, eckig */
.avatar { border-radius: 5px; background: #56657a; font-family: var(--display); font-stretch: condensed; font-weight: 700; }
.avatar.a-clara { background: #6b3fa0; } .avatar.a-harlo { background: #1e5aa8; } .avatar.a-ella { background: #2e7d4f; }
.avatar.a-mira { background: #c2571a; } .avatar.a-kai { background: #2f8fa6; } .avatar.a-theo { background: #7a5a35; }
.avatar.a-otto { background: #3d4655; } .avatar.a-iris { background: #0f7b8a; } .avatar.a-nova { background: #b03060; }
.avatar.a-lea { background: #2a7a6a; } .avatar.a-finn { background: #c98a00; }
.presence { border-radius: 2px; }

/* Signalgelb: alles, was auf eine Entscheidung wartet */
.card.waiting { border-left: 5px solid var(--signal); }
.count { background: var(--signal) !important; color: var(--signal-ink) !important; border-radius: 3px !important; font-weight: 700; }
.consent { background: color-mix(in srgb, var(--signal) 22%, var(--surface)); border: 1px solid color-mix(in srgb, var(--signal) 70%, transparent); border-radius: 4px; }
.brief li.p1::before { background: var(--signal); box-shadow: 0 0 0 1px var(--ink); }
.st.warn { background: var(--signal); box-shadow: 0 0 0 1px rgba(21, 35, 63, 0.35); }
.bubble { border-radius: 6px; }
.bubble.user { background: var(--ink); color: #fff; }
.meet { border-radius: 6px; background: var(--surface); border: 1px solid var(--sep); }

/* Organigramm: wie eine Wegweiser-Tafel mit rechtwinkligen Verbindungen */
.orgchart { display: flex; flex-direction: column; align-items: center; gap: 0; padding: 28px 22px 26px; margin-bottom: 20px; overflow-x: auto; }
.org-owner { display: flex; gap: 10px; align-items: center; padding: 8px 14px 8px 8px; border: 2px solid var(--ink); border-radius: 6px; background: var(--surface); }
.org-owner strong, .plate strong { display: block; font-family: var(--display); font-stretch: condensed; font-size: 1.0625rem; color: var(--ink); }
.org-owner span:not(.avatar), .plate-body > span { display: block; font-size: 0.8125rem; color: var(--muted); }
.org-level { position: relative; padding-top: 22px; }
.org-level::before, .org-units::before { content: ""; position: absolute; left: 50%; top: 0; height: 22px; border-left: 2px solid var(--ink); }
.org-units { position: relative; list-style: none; margin: 0; padding: 22px 0 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 22px 14px; width: 100%; }
.org-units > li { position: relative; display: flex; flex-direction: column; align-items: center; }
.org-units { border-top: 2px solid var(--ink); margin-top: 0; padding-top: 18px; max-width: 980px; }
.org-helpers { list-style: none; margin: 0; padding: 10px 0 0 18px; border-left: 2px solid var(--sep); align-self: stretch; margin-left: 22px; }
.plate { display: flex; gap: 10px; align-items: flex-start; width: 210px; padding: 10px 12px 10px 10px; background: var(--surface); border: 1px solid var(--sep);
  border-top: 4px solid var(--ink); border-radius: 4px; }
.org-level .plate { width: 250px; border-top-color: var(--signal); }
.plate.paused { opacity: 0.55; border-top-style: dashed; }
.plate-body { min-width: 0; flex: 1; }
.plate-body a { text-decoration: none; }
.plate-meta { margin-top: 4px; }
.sig { background: var(--signal); color: var(--signal-ink); padding: 0 4px; border-radius: 2px; font-weight: 700; }
.budget { display: block; height: 4px; margin-top: 6px; background: var(--fill); border-radius: 2px; overflow: hidden; }
.budget i { display: block; height: 100%; width: 0; background: var(--accent); }
.budget i.p0 { width: 2%; }
.budget i.p1 { width: 10%; }
.budget i.p2 { width: 20%; }
.budget i.p3 { width: 30%; }
.budget i.p4 { width: 40%; }
.budget i.p5 { width: 50%; }
.budget i.p6 { width: 60%; }
.budget i.p7 { width: 70%; }
.budget i.p8 { width: 80%; }
.budget i.p9 { width: 90%; }
.budget i.p10 { width: 100%; }
.budget.warn i { background: var(--signal); } .budget.stop i { background: var(--neg); }

.board { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 16px; }
.board-col { background: var(--surface-2); border-radius: 4px; padding: 10px; min-height: 120px; }
.board-col.sig-col { background: color-mix(in srgb, var(--signal) 16%, var(--surface)); }
.board-col h3 { display: flex; justify-content: space-between; margin-bottom: 8px; }
.task { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: 8px; padding: 8px; margin-bottom: 6px; background: var(--surface); border: 1px solid var(--sep);
  border-radius: 4px; color: var(--ink); text-decoration: none !important; font-size: 0.875rem; }
.task:hover { border-color: var(--accent); }
.task strong { display: block; font-weight: 600; overflow-wrap: anywhere; } .task small { color: var(--muted); }
.small { font-size: 0.8125rem; }
.goal-tree { list-style: none; margin: 0 0 14px; padding: 0; }
.goal-tree li { padding: 8px 0 8px 12px; border-left: 3px solid var(--ink); margin-bottom: 6px; }
.goal-tree li.d1 { margin-left: 16px; border-left-color: var(--accent); } .goal-tree li.d2, .goal-tree li.d3 { margin-left: 32px; border-left-color: var(--sep); }
.goal-tree strong { display: block; } .goal-tree span { font-size: 0.8125rem; color: var(--muted); }
.budget-table { width: 100%; font-size: 0.875rem; }
.budget-table td { padding: 6px 4px; border-top: 1px solid var(--sep); vertical-align: middle; }
.budget-table td:first-child { white-space: nowrap; } .budget-table .avatar { display: inline-grid; vertical-align: middle; margin-right: 4px; }
.mini-form { display: flex; gap: 4px; align-items: center; flex-wrap: wrap; } .mini-form input { width: 76px; margin: 0; padding: 5px 8px; }
.feed { list-style: none; margin: 0; padding: 0; font-size: 0.8125rem; } .feed li { padding: 6px 0; border-top: 1px solid var(--sep); }
textarea { font: inherit; width: 100%; padding: 10px 12px; border-radius: 4px; background: var(--surface-2); border: 1px solid var(--sep); color: var(--ink); }
@media (max-width: 1000px) { .board { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .board { grid-template-columns: minmax(0, 1fr); } .plate { width: 100%; } .org-units > li { width: 100%; } }

.tasks-card { margin-bottom: 20px; }
.budget-table { table-layout: fixed; }
.budget-table td:nth-child(2) { width: 92px; white-space: nowrap; }
.budget-table td:first-child { width: 96px; overflow: hidden; text-overflow: ellipsis; }
.mini-form input { width: 58px; }
.mini-form .btn.sm { padding: 5px 6px; }
@media (max-width: 800px) {
  .shell { background: none; }
  .side { position: sticky; top: 0; z-index: 10; }
  .side nav a { border-left: 0; border-bottom: 3px solid transparent; border-radius: 4px 4px 0 0; padding: 6px 10px; }
  .side nav a.on { border-bottom-color: var(--signal); }
  .display { font-size: clamp(2.4rem, 12vw, 3.2rem); }
}

/* ==========================================================================================
   Verfeinerungen für beide Stile: Bedienbarkeit, Fokus, Rhythmus
   ========================================================================================== */
.btn { min-height: 38px; }
.btn.sm { min-height: 32px; }
@media (pointer: coarse) { .btn, .btn.sm, .chip, .side nav a, .agent-pick { min-height: 44px; } }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.page-head { padding-bottom: 14px; border-bottom: 2px solid var(--ink); margin-bottom: 26px; }
.page-head.sticky { border-bottom: 0; }
.page-head .muted { font-size: 0.9375rem; }
.card-head { padding-bottom: 10px; border-bottom: 1px solid var(--sep); margin-bottom: 14px; }
.num, td.num { font-variant-numeric: tabular-nums; }

/* Stil-Umschalter in der Seitenleiste */
.style-switch { display: flex; gap: 4px; margin: 0 10px; padding: 3px; border-radius: 6px; background: rgba(255, 255, 255, 0.08); }
.style-switch button { flex: 1; font: inherit; font-size: 0.75rem; font-weight: 600; color: var(--side-muted); background: none; border: 0;
  padding: 6px 4px; border-radius: 4px; cursor: pointer; min-height: 30px; }
.style-switch button.on { background: var(--signal); color: var(--signal-ink); }
.style-switch button:hover:not(.on) { color: #fff; }
@media (max-width: 800px) { .style-switch { display: none; } }

/* ==========================================================================================
   Stil „Stellwerk“
   Bild: Gleisbild-Stellpult im Stellwerk. Dunkle, matte Pultflächen, beschriftete Schalter, Meldelampen.
   Schiefer   #12191B  Raum
   Pult       #1B2528  Flächen      Pult hell #243134
   Kreide     #E4ECE9  Schrift      Patina #8FA39D  Nebenschrift
   Gleislicht #8DC2FF  Links, Auswahl
   Meldelampe #FFB21A  NUR offene Entscheidungen (pulsiert langsam)
   Fahrt frei #47C98A  in Ordnung   Halt #FF6B5E  Störung
   ========================================================================================== */
:root[data-style="stellwerk"] {
  color-scheme: dark;
  --bg: #12191b; --surface: #1b2528; --surface-2: #243134;
  --ink: #e4ece9; --ink-2: #c3d0cc; --muted: #8fa39d;
  --sep: rgba(228, 236, 233, 0.1); --fill: rgba(228, 236, 233, 0.08); --fill-2: rgba(228, 236, 233, 0.05);
  --accent: #8dc2ff; --accent-ink: #0d1416; --accent-soft: rgba(141, 194, 255, 0.13);
  --signal: #ffb21a; --signal-ink: #1a1305;
  --pos: #47c98a; --neg: #ff6b5e; --warn: #ffb21a;
  --side-bg: #0d1315; --side-solid: #0d1315; --side-ink: #dce6e2; --side-muted: #7f938d;
  --r: 10px; --r-sm: 6px;
}
:root[data-style="stellwerk"] body { background: var(--bg);
  background-image: linear-gradient(rgba(255, 255, 255, 0.018) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.018) 1px, transparent 1px);
  background-size: 24px 24px; }
/* Pultflächen: matt, mit feiner Kante oben (Lichtkante) statt Schatten */
:root[data-style="stellwerk"] .card, :root[data-style="stellwerk"] .ask, :root[data-style="stellwerk"] .meet {
  background: var(--surface); border: 1px solid rgba(0, 0, 0, 0.5); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06); border-radius: 10px; }
:root[data-style="stellwerk"] .page-head { border-bottom-color: var(--sep); }
:root[data-style="stellwerk"] .card-head { border-bottom-color: var(--sep); }
:root[data-style="stellwerk"] .display { color: var(--ink); letter-spacing: 0.005em; }
:root[data-style="stellwerk"] h1, :root[data-style="stellwerk"] h2 { color: var(--ink); }
/* Gleisbild-Linie unter der Begrüßung */
:root[data-style="stellwerk"] .hero .display::after { content: ""; display: block; height: 4px; width: min(420px, 70%); margin-top: 14px;
  background: linear-gradient(90deg, var(--pos) 0 60%, transparent 60% 64%, var(--surface-2) 64%); border-radius: 2px; }
:root[data-style="stellwerk"] .lede a { background: none; color: var(--signal); border: 1px solid var(--signal); padding: 0 6px; }

/* Schalter in der Seitenleiste: beschriftete Tasten mit Meldelampe */
:root[data-style="stellwerk"] .side nav a { border-left: 0; border-radius: 6px; margin: 1px 0; }
:root[data-style="stellwerk"] .side nav a::after { content: ""; width: 7px; height: 7px; border-radius: 50%; margin-left: auto; background: #2b383b; }
:root[data-style="stellwerk"] .side nav a.on { background: #1f2b2e; box-shadow: inset 0 0 0 1px rgba(141, 194, 255, 0.35); }
:root[data-style="stellwerk"] .side nav a.on::after { background: var(--pos); box-shadow: 0 0 8px rgba(71, 201, 138, 0.8); }
:root[data-style="stellwerk"] .side nav a.on .ico { color: var(--accent); }

/* Tasten */
:root[data-style="stellwerk"] .btn { border-radius: 6px; }
:root[data-style="stellwerk"] .btn.primary { background: var(--accent); color: var(--accent-ink); }
:root[data-style="stellwerk"] .btn.primary:hover:not(:disabled) { background: #a9d2ff; }
:root[data-style="stellwerk"] .btn.secondary { background: var(--surface-2); color: var(--ink); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 0 0 1px rgba(0, 0, 0, 0.45); }
:root[data-style="stellwerk"] .btn.ghost { color: var(--accent); }
:root[data-style="stellwerk"] input, :root[data-style="stellwerk"] select, :root[data-style="stellwerk"] textarea {
  background: #121a1c; border: 1px solid #2e3c3f; color: var(--ink); border-radius: 6px; }
:root[data-style="stellwerk"] .chip, :root[data-style="stellwerk"] .agent-pick { background: var(--surface-2); color: var(--ink-2); border-radius: 6px; box-shadow: none; }
:root[data-style="stellwerk"] .agent-pick:has(input:checked) { background: #1f2b2e; color: #fff; box-shadow: inset 0 0 0 1px var(--accent); }

/* Meldelampen: Status als Lampen, offene Entscheidungen pulsieren langsam */
:root[data-style="stellwerk"] .st, :root[data-style="stellwerk"] .dot, :root[data-style="stellwerk"] .brief li::before {
  border-radius: 50%; box-shadow: inset 0 -2px 3px rgba(0, 0, 0, 0.35); }
:root[data-style="stellwerk"] .st.ok, :root[data-style="stellwerk"] .dot.on { background: var(--pos); box-shadow: 0 0 8px rgba(71, 201, 138, 0.6); }
:root[data-style="stellwerk"] .st.fail, :root[data-style="stellwerk"] .dot.off { background: var(--neg); box-shadow: 0 0 8px rgba(255, 107, 94, 0.55); }
:root[data-style="stellwerk"] .st.warn, :root[data-style="stellwerk"] .brief li.p1::before { background: var(--signal); box-shadow: 0 0 10px rgba(255, 178, 26, 0.75); animation: lamp 2.4s ease-in-out infinite; }
@keyframes lamp { 50% { opacity: 0.45; box-shadow: 0 0 2px rgba(255, 178, 26, 0.2); } }
@media (prefers-reduced-motion: reduce) { :root[data-style="stellwerk"] .st.warn, :root[data-style="stellwerk"] .brief li.p1::before { animation: none; } }
:root[data-style="stellwerk"] .card.waiting { border-left: 4px solid var(--signal); }
:root[data-style="stellwerk"] .count, :root[data-style="stellwerk"] .sig { background: var(--signal) !important; color: var(--signal-ink) !important; }

/* Agenten als beleuchtete Kennzeichen */
:root[data-style="stellwerk"] .avatar { border-radius: 6px; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18), inset 0 -8px 12px rgba(0, 0, 0, 0.25); }
:root[data-style="stellwerk"] .avatar.neutral { background: #2b383b; color: var(--ink); }

/* Organigramm als Gleisbild */
:root[data-style="stellwerk"] .org-owner { background: var(--surface-2); border-color: var(--accent); }
:root[data-style="stellwerk"] .org-level::before, :root[data-style="stellwerk"] .org-units::before { border-left-color: var(--pos); }
:root[data-style="stellwerk"] .org-units { border-top-color: var(--pos); }
:root[data-style="stellwerk"] .org-helpers { border-left-color: #2e3c3f; }
:root[data-style="stellwerk"] .plate { background: var(--surface-2); border-color: rgba(0, 0, 0, 0.5); border-top: 3px solid var(--accent); }
:root[data-style="stellwerk"] .org-level .plate { border-top-color: var(--signal); }
:root[data-style="stellwerk"] .board-col { background: #161f22; }
:root[data-style="stellwerk"] .board-col.sig-col { background: rgba(255, 178, 26, 0.08); box-shadow: inset 0 0 0 1px rgba(255, 178, 26, 0.35); }
:root[data-style="stellwerk"] .task { background: var(--surface-2); border-color: rgba(0, 0, 0, 0.45); }
:root[data-style="stellwerk"] .goal-tree li { border-left-color: var(--pos); } :root[data-style="stellwerk"] .goal-tree li.d1 { border-left-color: var(--accent); }

/* Gesprächsblasen und Meldungen */
:root[data-style="stellwerk"] .bubble.agent { background: var(--surface-2); color: var(--ink); }
:root[data-style="stellwerk"] .bubble.user { background: #2a4f78; color: #fff; }
:root[data-style="stellwerk"] .consent { background: rgba(255, 178, 26, 0.1); border-color: rgba(255, 178, 26, 0.5); }
:root[data-style="stellwerk"] .banner { background: rgba(255, 178, 26, 0.14); color: var(--signal); }
:root[data-style="stellwerk"] .tag { background: var(--surface-2); color: var(--ink-2); }
:root[data-style="stellwerk"] .tag.good { color: var(--pos); } :root[data-style="stellwerk"] .tag.warn { color: var(--signal); } :root[data-style="stellwerk"] .tag.bad { color: var(--neg); }
:root[data-style="stellwerk"] code { background: #121a1c; }
:root[data-style="stellwerk"] .score { background: var(--surface-2); color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
:root[data-style="stellwerk"] table th { color: var(--muted); }
:root[data-style="stellwerk"] .shell { background: linear-gradient(90deg, var(--side-solid) 248px, transparent 248px); }
@media (max-width: 800px) { :root[data-style="stellwerk"] .shell { background: none; } }
:root[data-style="stellwerk"] .brief li.p2::before { background: var(--accent); box-shadow: 0 0 6px rgba(141, 194, 255, 0.5); }
.budget-table small.fc { display: block; font-size: 0.6875rem; }

/* KI-Werkstatt */
.sessions { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.session { border: 1px solid var(--sep); border-radius: var(--r); padding: 14px; background: var(--surface-2); min-width: 0; }
.session.off { opacity: 0.85; }
.session-head { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.session-head strong { font-family: var(--display); font-stretch: condensed; font-size: 1.125rem; flex: 1; }
.session .st { width: 12px; height: 12px; margin: 0; }
.kv { display: grid; gap: 4px; margin: 0 0 10px; font-size: 0.8125rem; }
.kv > div { display: grid; grid-template-columns: 90px minmax(0, 1fr); gap: 8px; }
.kv dt { color: var(--muted); } .kv dd { margin: 0; overflow-wrap: anywhere; }
code.secret { display: block; white-space: pre-wrap; overflow-wrap: anywhere; padding: 10px; margin: 6px 0 10px; user-select: all; }
.notice { overflow-wrap: anywhere; }
.alert { background: color-mix(in srgb, var(--neg) 12%, var(--surface)); color: var(--ink); padding: 10px 14px; border-radius: var(--r-sm); border-left: 4px solid var(--neg); overflow-wrap: anywhere; }
.col-main h3, .col-side h3 { margin-top: 18px; }
.cc-card { margin-bottom: 20px; }
.form-grid > .btn { justify-self: start; align-self: end; }
.model-table { width: 100%; font-size: 0.875rem; border-collapse: collapse; }
.model-table td { padding: 6px 4px; border-top: 1px solid var(--sep); vertical-align: middle; }
.model-table td.num { white-space: nowrap; text-align: right; width: 70px; }
.model-table td:last-child { width: 1%; white-space: nowrap; }
.checks span code { display: inline; margin: 0; padding: 1px 6px; white-space: nowrap; }
label.check input[type="checkbox"] { width: auto; margin: 0; flex: none; }

/* Einstellungen */
.toc { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.toc a { padding: 6px 12px; border-radius: 4px; background: var(--surface); border: 1px solid var(--sep); color: var(--ink); text-decoration: none; font-weight: 600; font-size: 0.875rem; }
#agenten { margin-bottom: 20px; }
.agent-set { border-top: 1px solid var(--sep); padding: 10px 0; }
.agent-set summary { display: flex; gap: 12px; align-items: center; cursor: pointer; list-style: none; }
.agent-set summary::-webkit-details-marker { display: none; }
.agent-set summary strong { display: block; } .agent-set summary small { color: var(--muted); }
.agent-set form { margin-top: 12px; }
.form-grid label, .stack label { display: flex; flex-direction: column; gap: 4px; }
.form-grid .wide { grid-column: 1 / -1; }
fieldset.plan { border: 1px solid var(--sep); border-radius: var(--r-sm); padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; margin: 0; }
.avatar.preview-play::after { animation-iteration-count: infinite; }
.form-grid label.check, .stack label.check { flex-direction: row; align-items: center; gap: 8px; }

/* Info, Rechtliches */
.big-version { font-family: var(--display); font-stretch: condensed; font-size: 3rem; font-weight: 700; margin: 0 0 8px; line-height: 1; }
.version-card { margin-bottom: 0; }
.release { border-top: 1px solid var(--sep); padding: 10px 0; }
.release h3 { font-size: 1rem; margin: 0 0 4px; } .release ul { margin: 0; padding-left: 18px; }
.release.current { border-left: 4px solid var(--signal); padding-left: 10px; }
pre.log { max-height: 340px; overflow: auto; background: var(--surface-2); padding: 10px; border-radius: 4px; font-size: 0.75rem; white-space: pre-wrap; }
table.sbom { max-height: 520px; display: block; overflow-y: auto; }
.side-legal { margin: 0 10px; font-size: 0.6875rem; color: var(--side-muted); }
.side-legal a { color: var(--side-muted); } .side-legal a:hover { color: #fff; }
.legal-links { text-align: center; } .legal-links a { color: var(--muted); }
body.legal-page { display: block; place-items: initial; }
main.legal { max-width: 760px; margin: 0 auto; padding: 32px 20px 64px; background: var(--surface); border: 1px solid var(--sep); border-radius: var(--r); margin-top: 24px; margin-bottom: 24px; }
main.legal h2 { margin: 22px 0 6px; } main.legal p, main.legal li { line-height: 1.6; }

/* System */
.sys-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: 16px; align-items: start; }
.sys-grid .card { margin: 0; }
.key-state { display: inline-block; font-size: 0.75rem; padding: 1px 8px; border-radius: 99px; margin: 2px 0 4px; width: fit-content; }
.key-state.on { background: color-mix(in srgb, var(--good, #2e7d4f) 15%, transparent); color: var(--good, #2e7d4f); }
.key-state.off { background: var(--surface-2); color: var(--muted); }
ul.plain { list-style: none; padding: 0; margin: 0; } ul.plain li { padding: 6px 0; border-top: 1px solid var(--sep); }
.sys-grid form.stack > p.muted, .sys-grid .card > p.muted.small { margin-bottom: 10px; }
ul.plain li br { display: none; } ul.plain li span { display: block; margin-top: 2px; }
.rot-table input { width: 100%; min-width: 0; } .rot-table td { vertical-align: top; }
.key-alert { margin-bottom: 12px; }
@media (max-width: 700px) { .rot-table thead { display: none; } .rot-table tr { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 8px 0; } .rot-table td:first-child, .rot-table td:nth-child(2) { grid-column: 1 / -1; } }

/* Sprachausgabe: Steuerleiste und Gesamtschalter */
.voice-bar { position: fixed; left: 50%; bottom: 18px; transform: translateX(-50%); z-index: 60; display: flex; align-items: center; gap: 8px;
  padding: 8px 10px 8px 14px; border-radius: 99px; background: var(--ink, #15233F); color: #fff; box-shadow: 0 8px 24px rgba(0,0,0,.25); max-width: calc(100vw - 32px); }
.voice-bar[hidden] { display: none; }
.voice-bar-label { font-size: 0.8125rem; white-space: nowrap; }
.voice-bar button { border: 0; border-radius: 99px; padding: 6px 12px; font: inherit; font-size: 0.8125rem; cursor: pointer; background: rgba(255,255,255,.14); color: #fff; min-height: 32px; }
.voice-bar button:hover, .voice-bar button:focus-visible { background: rgba(255,255,255,.26); }
.voice-bar [data-vb="stop"] { background: var(--signal, #F5C518); color: #15233F; font-weight: 600; }
.voice-master { margin: 0 10px 8px; padding: 6px 10px; border-radius: 6px; border: 1px solid rgba(255,255,255,.18); background: transparent;
  color: var(--side-muted, #b8c2d0); font: inherit; font-size: 0.75rem; text-align: left; cursor: pointer; }
.voice-master[aria-pressed="false"] { color: #fff; border-color: var(--signal, #F5C518); }
.voice-off .say { display: none; }
@media (max-width: 520px) { .voice-bar { bottom: 10px; gap: 4px; padding-left: 10px; } .voice-bar-label { display: none; } }

/* Monitoring */
.mon-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr)); gap: 16px; margin-bottom: 16px; align-items: start; }
.mon-grid .card { margin: 0; }
.mon-list { list-style: none; margin: 0; padding: 0; }
.mon-list li { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; border-top: 1px solid var(--sep); }
.mon-list li:first-child { border-top: 0; }
.lamp { display: inline-block; flex: none; width: 10px; height: 10px; border-radius: 50%; margin-top: 5px; background: var(--muted); opacity: .45; vertical-align: baseline; }
.lamp.good { background: #2e7d4f; opacity: 1; } .lamp.warn { background: #c98a00; opacity: 1; } .lamp.bad { background: #b3261e; opacity: 1; box-shadow: 0 0 0 3px rgba(179,38,30,.18); }
.lamp.run { background: #1e5aa8; opacity: 1; animation: lamp-pulse 1.4s ease-in-out infinite; }
@keyframes lamp-pulse { 50% { box-shadow: 0 0 0 4px rgba(30,90,168,.22); } }
@media (prefers-reduced-motion: reduce) { .lamp.run { animation: none; } }
.legend { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; } .legend .lamp { margin: 0 0 0 6px; }
.small-head { font-size: .875rem; margin: 16px 0 4px; }
.mon-agents { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 460px), 1fr)); gap: 14px; }
.mon-agent { border: 1px solid var(--sep); border-radius: var(--r, 8px); padding: 12px; background: var(--surface); min-width: 0; }
.mon-agent > header { display: flex; justify-content: space-between; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 8px; }
.mon-who { display: flex; gap: 10px; align-items: center; color: inherit; text-decoration: none; }
.mon-jobs { width: 100%; border-collapse: collapse; font-size: .875rem; }
.mon-jobs th { text-align: left; font-weight: 600; font-size: .75rem; color: var(--muted); padding: 4px 6px 4px 0; }
.mon-jobs td { padding: 5px 6px 5px 0; border-top: 1px solid var(--sep); vertical-align: top; }
.mon-tasks { list-style: none; padding: 0; margin: 8px 0 0; font-size: .875rem; } .mon-tasks li { padding: 3px 0; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media (max-width: 560px) { .mon-jobs thead { display: none; } .mon-jobs tr { display: grid; grid-template-columns: 1fr 1fr; } .mon-jobs td:first-child { grid-column: 1 / -1; } .mon-jobs td:nth-child(2) { display: none; } }
/* Feinschliff: Tabellen bleiben in ihren Karten */
.mon-agents { grid-template-columns: repeat(auto-fit, minmax(min(100%, 520px), 1fr)); }
.mon-jobs { table-layout: fixed; }
.mon-jobs th:nth-child(1) { width: 48%; } .mon-jobs th:nth-child(2) { width: 17%; } .mon-jobs th:nth-child(3) { width: 14%; } .mon-jobs th:nth-child(4) { width: 21%; }
.mon-jobs td { overflow-wrap: anywhere; }
.rot-table { width: 100%; table-layout: fixed; }
.rot-table th:nth-child(1) { width: 30%; } .rot-table th:nth-child(2) { width: 34%; } .rot-table th:nth-child(3) { width: 20%; } .rot-table th:nth-child(4) { width: 16%; }
.rot-table td { overflow-wrap: anywhere; }
body:has([data-composer]) .voice-bar { bottom: 96px; }
.mon-jobs td, .rot-table td, .sbom td { white-space: normal; }

/* Agenten steuern */
.ctl-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 520px), 1fr)); gap: 14px; }
.ctl { margin: 0; }
.ctl.is-off { border-left: 4px solid #b3261e; }
.ctl.is-off .avatar { filter: grayscale(.85); opacity: .7; }
.ctl-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.ctl-state { display: inline-flex; align-items: center; gap: 6px; font-size: .875rem; }
.ctl-state .lamp { margin-top: 0; }
.ctl-row { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; padding: 8px 0; border-top: 1px solid var(--sep); }
.ctl-model label { display: flex; flex-direction: column; gap: 2px; min-width: 0; flex: 1 1 140px; }
.ctl-model select { width: 100%; }
.ctl-model .btn { align-self: flex-end; }
.ctl-foot { margin: 6px 0 0; }
.row-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.btn.sm { padding: 5px 10px; font-size: .8125rem; min-height: 32px; }

/* Merkliste */
.merk-list { list-style: none; margin: 0; padding: 0; }
.merk-list li { padding: 10px 0; border-top: 1px solid var(--sep); }
.merk-list li:first-child { border-top: 0; }
.merk-note { margin: 4px 0; white-space: pre-line; color: var(--muted); }
.merk-actions { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.merk-add { margin-top: 10px; } .merk-add summary { cursor: pointer; font-weight: 600; padding: 6px 0; }

/* Hilfe auf jeder Seite */
.main { position: relative; }
.help-panel { position: absolute; top: 18px; right: 24px; z-index: 40; max-width: min(440px, calc(100vw - 32px)); }
.help-panel > summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; float: right;
  padding: 6px 12px; border-radius: 99px; background: var(--surface); border: 1px solid var(--sep); font-size: .8125rem; font-weight: 600; color: var(--ink, #15233F); }
.help-panel > summary::-webkit-details-marker { display: none; }
.help-panel > summary span { display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: var(--signal, #F5C518); color: #15233F; font-size: .75rem; }
.help-panel[open] > summary { background: var(--ink, #15233F); color: #fff; }
.help-body { clear: both; margin-top: 8px; padding: 14px 16px; background: var(--surface); border: 1px solid var(--sep); border-radius: var(--r, 8px);
  box-shadow: 0 12px 32px rgba(0,0,0,.18); max-height: 70vh; overflow: auto; }
.help-title { margin: 0 0 2px; } .help-topic { border-top: 1px solid var(--sep); padding: 6px 0; }
.help-topic summary { cursor: pointer; font-weight: 600; font-size: .875rem; padding: 4px 0; }
.help-topic ol { margin: 4px 0 6px; padding-left: 20px; font-size: .875rem; line-height: 1.5; }
.help-topic li + li { margin-top: 3px; }
.help-foot { margin: 8px 0 0; }
.main > .page-head { padding-right: 110px; }
@media (max-width: 700px) { .help-panel { top: 10px; right: 16px; } .main > .page-head { padding-right: 0; padding-top: 34px; } }
