:root {
  color-scheme: light;
  font-size: 125%;
  --ink: #222222;
  --muted: #515151;
  --paper: #fafafa;
  --line: #dee0e3;
  --teal: #385953;
  --soft: #e7f2fc;
  --white: #fff;
  --focus: #14679e;
  --shadow: none;
}
html[data-reading-size="large"] { font-size: 150%; }
html[data-reading-size="extra"] { font-size: 175%; }
html[data-reading-size="double"] { font-size: 250%; }
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 1rem/1.75 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
button, input, textarea, select { font: inherit; }
button, a, input, textarea, select, summary { outline-offset: 4px; touch-action: manipulation; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; }
button, summary { cursor: pointer; }
a { color: var(--teal); text-underline-offset: .2em; text-decoration-thickness: .08em; overflow-wrap: anywhere; }
a:hover { text-decoration-thickness: .14em; }
button:disabled { cursor: wait; color: #47584e; background: #e4e9e2; border-color: #aebbb0; }
[hidden] { display: none !important; }
h1, h2, h3, h4, p, li, small, strong { overflow-wrap: anywhere; }
p { color: var(--muted); margin: 0 0 1.1em; }
h2 { font-size: 1.35rem; line-height: 1.4; font-weight: 650; margin: .5rem 0 1rem; }
h3 { line-height: 1.5; }
.skip-link { position: absolute; top: -10rem; left: 1rem; z-index: 20; padding: .7rem 1rem; background: white; border: 2px solid var(--focus); }
.skip-link:focus { top: .7rem; }
.skip-reader:focus { top: 4.5rem; }
.sidebar { position: fixed; inset: 0 auto 0 0; width: 260px; overflow-y: auto; background: white; border-right: 1px solid var(--line); padding: 1.8rem 1.1rem; display: flex; flex-direction: column; }
.brand { display: flex; gap: .65rem; align-items: center; color: var(--ink); text-decoration: none; font-size: 1.45rem; font-weight: 750; line-height: 1.3; }
.brand-mark { width: 2.4rem; height: 2.4rem; flex-shrink: 0; background: var(--ink); border-radius: .7rem; color: white; display: flex; align-items: center; justify-content: center; position: relative; font: italic 2rem Georgia, serif; }
.brand-mark span { font: 1.4rem sans-serif; color: #baddb8; position: absolute; right: .4rem; top: 0; }
.brand-sub { display: block; font-size: .7rem; letter-spacing: .06em; font-weight: 650; margin-top: .25rem; }
.nav-caption { color: var(--muted); letter-spacing: .08em; font-size: .75rem; font-weight: 700; margin: 2.6rem .5rem 1rem; }
.nav { width: 100%; min-height: 2.5rem; text-align: left; display: flex; align-items: center; gap: .65rem; padding: .75rem .6rem; margin-bottom: .5rem; border: 2px solid transparent; background: transparent; color: var(--muted); border-radius: .45rem; font-size: .95rem; font-weight: 600; }
.nav > span:first-child { font-size: 1.2rem; line-height: 1; }
.nav.active { background: var(--soft); color: var(--teal); border-color: #b5cab9; }
.nav-count { margin-left: auto; background: #d9e7db; border-radius: .3rem; padding: 0 .4rem; font-size: .8rem; }
.sidebar-note { margin-top: auto; padding: 2rem .4rem 1rem; font-size: .8rem; font-weight: 650; }
.sidebar-note p { font-weight: 400; margin: .6rem 0; font-size: .8rem; }
.local-dot, .local-label i { display: inline-block; background: #28704b; width: .4rem; height: .4rem; border-radius: 100%; margin-right: .4rem; }
.sidebar-bottom { border-top: 1px solid var(--line); padding-top: 1rem; font-size: .75rem; color: var(--muted); }
.sidebar-bottom span { display: block; }
main { margin-left: 260px; padding: 0 36px; max-width: 1800px; min-width: 0; }
.topbar { min-height: 5rem; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; padding: 1rem 0; border-bottom: 1px solid var(--line); color: var(--muted); font-size: .75rem; font-weight: 650; }
.local-label { font-size: .8rem; font-weight: 500; }
.reading-size { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; }
.reading-size label { font-size: .85rem; }
.reading-size select { font-size: .85rem; max-width: 100%; }
.hero { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 2.6rem 0 2.2rem; }
.eyebrow, .section-kicker { font-size: .75rem; letter-spacing: .07em; color: var(--teal); font-weight: 750; }
h1 { font: 750 2.3rem/1.2 system-ui, -apple-system, "Segoe UI", sans-serif; margin: .8rem 0 1rem; }
.hero p { font-size: 1rem; margin: 0; max-width: 58ch; }
.hero-seal { border: 1px solid #839d83; border-radius: 50%; width: 5rem; height: 5rem; display: flex; flex-direction: column; align-items: center; justify-content: center; font: 1.7rem Georgia, serif; color: #3f6647; flex-shrink: 0; }
.hero-seal span { font: .7rem system-ui; letter-spacing: .05em; margin-top: .4rem; }
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.1rem; margin-bottom: 2rem; }
.stats article { background: white; border: 1px solid var(--line); border-radius: .65rem; padding: 1.3rem 1.4rem; box-shadow: var(--shadow); }
.stat-label { font-size: .85rem; color: var(--muted); }
.stats strong { display: block; font: 750 2.3rem/1.4 system-ui, sans-serif; margin: .3rem 0; }
.stats small { font-size: .8rem; color: var(--muted); }
.stats .stat-accent { background: var(--soft); border-color: #bcd1be; }
.tools-panel { background: white; border: 1px solid var(--line); border-radius: .65rem; display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.4fr); gap: 2rem; padding: 1.8rem; margin-bottom: 2.3rem; }
.tools-panel p { font-size: .95rem; max-width: 35ch; }
.tool-forms { display: flex; flex-direction: column; gap: 1.6rem; min-width: 0; }
.tool-forms label { font-size: .9rem; font-weight: 650; display: block; margin-bottom: .6rem; }
.input-row { display: flex; flex-wrap: wrap; gap: .75rem; }
.input-row input { min-width: 0; flex: 1 1 14rem; }
input, textarea, select { border: 1px solid #859a89; border-radius: .35rem; min-height: 2.5rem; padding: .65rem .8rem; background: #fff; color: var(--ink); max-width: 100%; }
input::placeholder { color: #52695c; opacity: 1; }
.tool-forms small { font-size: .8rem; color: var(--muted); display: block; margin-top: .65rem; }
.primary, .secondary, .button { min-width: 0; min-height: 2.5rem; border-radius: .35rem; border: 1px solid transparent; padding: .7rem 1rem; font-size: .9rem; font-weight: 650; white-space: normal; overflow-wrap: anywhere; text-align: center; text-decoration: none; display: inline-flex; justify-content: center; align-items: center; gap: .6rem; line-height: 1.5; }
.primary { background: var(--teal); color: white; }
.primary:hover { background: #263f3b; }
.secondary { background: white; border-color: #859a89; color: var(--ink); }
.secondary:hover { background: var(--soft); }
#month-form label { white-space: normal; }
.workspace { display: grid; grid-template-columns: minmax(310px, .8fr) minmax(0, 1.7fr); gap: 1.6rem; align-items: start; }
.session-panel, .reader { min-width: 0; background: white; border: 1px solid var(--line); border-radius: .65rem; box-shadow: var(--shadow); }
.section-heading { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .8rem; }
.session-panel > .section-heading { padding: 1.5rem 1.2rem 0; }
.section-heading h2 { font-size: 1.15rem; }
.quiet { font-size: .8rem; color: var(--muted); }
.search-label { display: block; margin: .8rem 1.2rem .5rem; font-size: .85rem; font-weight: 650; }
.search { margin: .4rem 1.2rem 1.2rem; display: flex; align-items: center; background: #fafafa; border: 1px solid #859a89; border-radius: .35rem; padding-left: .6rem; gap: .4rem; }
.search span { font-size: 1.5rem; color: var(--muted); }
.search input { width: 100%; min-width: 0; border: 0; background: transparent; font-size: .9rem; padding: .7rem .5rem; }
.filters { padding: 0 1.2rem 1.5rem; display: flex; gap: .65rem; flex-wrap: wrap; }
.filter { min-height: 2.5rem; padding: .55rem .8rem; border: 1px solid #a9b9ab; background: white; font-size: .85rem; color: var(--muted); border-radius: .35rem; }
.filter.selected { background: var(--soft); color: var(--teal); border-color: var(--teal); font-weight: 700; }
.session-list { max-height: 34rem; overflow-y: auto; scrollbar-gutter: stable; border-radius: 0 0 .65rem .65rem; }
.session-card { display: flex; gap: .85rem; align-items: flex-start; padding: 1.3rem 1.15rem; border: 0; border-top: 1px solid var(--line); border-left: 4px solid transparent; background: white; text-align: left; width: 100%; min-height: 3rem; color: var(--ink); }
.session-card:hover { background: #f1f6fa; }
.session-card.selected { border-left-color: var(--teal); background: var(--soft); }
.session-card:focus-visible { outline-offset: -4px; }
.date-box { min-width: 2.7rem; flex-shrink: 0; border: 1px solid #a4b7a6; border-radius: .4rem; display: flex; flex-direction: column; align-items: center; padding: .3rem; background: white; }
.date-box strong { font-size: 1.4rem; font-weight: 600; line-height: 1.4; }
.date-box small { text-transform: uppercase; font-size: .75rem; color: var(--muted); }
.session-info { min-width: 0; flex: 1; }
.session-info h3 { font-size: 1rem; margin: 0 0 .6rem; font-weight: 650; }
.session-info p { font-size: .8rem; margin: 0 0 .65rem; }
.badge { font-size: .75rem; line-height: 1.6; display: inline-block; padding: .25rem .55rem; background: #edf0e9; color: #415446; border-radius: .3rem; overflow-wrap: anywhere; }
.badge.ready { background: #e3efe4; color: #285b38; }
.badge.later { background: #f6eee2; color: #78561d; }
.session-arrow { color: #526e5b; margin-top: .7rem; }
.empty-reader { padding: 3.5rem 2rem; text-align: center; min-height: 22rem; display: flex; flex-direction: column; justify-content: center; align-items: center; }
.empty-symbol { width: 4rem; height: 4rem; background: var(--soft); border: 1px solid #b2c5a8; border-radius: 50%; font: 2.3rem Georgia, serif; margin-bottom: 1.5rem; color: #426c42; }
.empty-reader h2 { font: 700 1.7rem/1.4 system-ui, sans-serif; margin-top: 1rem; }
.empty-reader p { font-size: 1rem; max-width: 34ch; }
.reader-header { padding: 2rem; border-bottom: 1px solid var(--line); border-radius: .65rem .65rem 0 0; background: var(--soft); }
.reader-header h2 { font: 700 1.9rem/1.35 system-ui, sans-serif; margin: .9rem 0; }
.reader-header p { font-size: .95rem; margin: .7rem 0; }
.reader-actions { display: flex; gap: .85rem; flex-wrap: wrap; margin: 1.4rem 0 0; }
.reader-actions a { font-size: .9rem; }
.version-bar { padding: 1.3rem 2rem; display: flex; flex-wrap: wrap; gap: .85rem; align-items: center; border-bottom: 1px solid var(--line); font-size: .85rem; }
.version-bar select { min-width: 0; flex: 1 1 16rem; font-size: .85rem; }
.version-bar a { min-height: 2.5rem; display: inline-flex; align-items: center; }
.summary-meta { padding: 1.1rem 2rem; font-size: .8rem; color: var(--muted); background: #fafafa; border-bottom: 1px solid var(--line); }
.agenda-item { padding: 2.5rem 2rem; border-bottom: 2px solid var(--line); }
.agenda-item:last-child { border: 0; }
.item-head { display: flex; gap: .9rem; align-items: flex-start; margin-bottom: 1.7rem; }
.top-number { background: var(--soft); color: var(--teal); font-size: .8rem; padding: .35rem .5rem; border-radius: .3rem; white-space: nowrap; margin-top: .2rem; }
.item-head h3 { font-size: 1.25rem; line-height: 1.5; font-weight: 700; margin: 0 0 .6rem; }
.item-head small { color: var(--muted); font-size: .85rem; }
.document { margin-top: 1.6rem; }
.document + .document { padding-top: 1.5rem; border-top: 1px solid var(--line); }
.document .badge { margin-bottom: 1.1rem; }
.summary-field { font-size: 1rem; margin: 0 0 1.5rem; line-height: 1.8; max-width: 65ch; }
.summary-field strong { font-size: .9rem; display: block; color: #284f3e; font-weight: 750; margin-bottom: .45rem; }
.source-links { display: flex; gap: .65rem 1.1rem; flex-wrap: wrap; align-items: center; font-size: .85rem; margin-top: 1rem; }
.source-links a, .source-links button { min-height: 2.5rem; display: inline-flex; align-items: center; padding: .4rem 0; }
.edit-button { border: 0; min-height: 2.5rem; padding: .5rem 0; background: transparent; color: var(--teal); font-size: .85rem; text-decoration: underline; text-underline-offset: .2em; text-align: left; }
.attachments { margin-top: 1.4rem; color: var(--muted); font-size: .85rem; }
.attachments summary { padding: .6rem 0; min-height: 2.5rem; }
.attachments ul { padding-left: 1.3rem; margin-bottom: 0; }
.attachments a { display: inline-block; color: var(--teal); padding: .5rem 0; }
.editor { border: 1px solid #9eb791; background: #f1f6fa; padding: 1.5rem; border-radius: .4rem; margin-top: 1.5rem; }
.editor label { display: block; font-size: .9rem; font-weight: 650; margin: 0 0 .6rem; }
.editor textarea, .editor input { width: 100%; font-size: 1rem; line-height: 1.75; margin-bottom: 1.3rem; }
.editor textarea { min-height: 9rem; resize: vertical; }
.editor textarea.short { min-height: 5rem; }
.editor-actions { display: flex; flex-wrap: wrap; gap: 1rem; }
.empty-list { padding: 2rem 1.3rem; color: var(--muted); font-size: .95rem; }
.knowledge-intro { max-width: 65ch; margin-bottom: 2.2rem; }
.knowledge-intro h2 { font: 700 1.8rem/1.4 system-ui, sans-serif; }
.knowledge-card { background: white; border: 1px solid var(--line); border-radius: .65rem; padding: 2rem; max-width: 65ch; }
.knowledge-card h3 { margin-top: 0; font-size: 1.3rem; }
.knowledge-card ol { padding-left: 1.3rem; color: var(--muted); font-size: 1rem; }
.knowledge-card li { margin-bottom: 1.5rem; padding-left: .5rem; }
.knowledge-card strong { color: var(--ink); }
.knowledge-card .quiet { margin-top: 1.6rem; }
.jobs-panel { background: white; border: 1px solid var(--line); border-radius: .65rem; padding: 1.6rem; margin-top: 2rem; }
.jobs-panel h2 { margin: 0; font-size: 1.2rem; }
.job { padding: 1rem 0; border-bottom: 1px solid var(--line); display: flex; flex-wrap: wrap; align-items: center; gap: .8rem; font-size: .9rem; }
.job > div { min-width: 0; flex: 1 1 15rem; overflow-wrap: anywhere; }
.job:last-child { border-bottom: 0; }
.job span:last-child { margin-left: auto; color: var(--muted); font-size: .8rem; }
#notification { border: 1px solid #a4bf9a; background: #eaf3e5; padding: 1rem 1.3rem; border-radius: .5rem; margin-bottom: 1.5rem; font-size: .95rem; }
#notification.error { background: #fbede6; border-color: #c29c83; color: #75371e; }
footer { padding: 2rem 0; font-size: .8rem; color: var(--muted); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; }
.disabled { pointer-events: none; color: #47584e; background: #e4e9e2; }
.loading { padding: 3rem; text-align: center; color: var(--muted); font-size: 1rem; }
.discussion-box { background: #fbf4e9; border: 1px solid #c8ae86; border-left: 4px solid #966a32; border-radius: .4rem; padding: 1.8rem; margin-top: 2.2rem; }
.discussion-box .section-kicker { color: #704e22; font-size: .75rem; }
.discussion-box h4 { font: 700 1.5rem/1.4 system-ui, sans-serif; color: #68491e; margin: .6rem 0 1rem; }
.discussion-notice { font-size: .85rem; color: #6b4d26; margin: 0 0 1.5rem; }
.discussion-suggestion { color: #443721; font-size: 1rem; line-height: 1.8; max-width: 65ch; }
.discussion-box ul { font-size: 1rem; color: #53432a; padding-left: 1.3rem; }
.discussion-box li { padding-left: .2rem; margin-bottom: .8rem; }
.discussion-box .summary-field strong { color: #68491e; }
.discussion-box .edit-button { margin-top: 1rem; color: #68491e; }
.context-hash { font-size: .8rem; overflow-wrap: anywhere; color: var(--muted); }
.discussion-box .editor { background: #fffaf2; border-color: #c8ae86; }
html:is([data-reading-size="extra"], [data-reading-size="double"]) .sidebar { position: static; width: auto; border-right: 0; border-bottom: 1px solid var(--line); }
html:is([data-reading-size="extra"], [data-reading-size="double"]) .sidebar nav { display: flex; flex-wrap: wrap; gap: .6rem; }
html:is([data-reading-size="extra"], [data-reading-size="double"]) .nav { width: auto; flex: 1 1 12rem; }
html:is([data-reading-size="extra"], [data-reading-size="double"]) .sidebar-note,
html:is([data-reading-size="extra"], [data-reading-size="double"]) .sidebar-bottom,
html:is([data-reading-size="extra"], [data-reading-size="double"]) .nav-caption { display: none; }
html:is([data-reading-size="extra"], [data-reading-size="double"]) main { margin-left: auto; margin-right: auto; }
html:not([data-reading-size="normal"]) .workspace,
html:not([data-reading-size="normal"]) .tools-panel { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 1650px) { main { padding: 0 60px; } .workspace { grid-template-columns: 360px minmax(0, 1fr); } }
@media (max-width: 1250px) { .workspace, .tools-panel { grid-template-columns: minmax(0, 1fr); } .tools-panel p { max-width: 60ch; } .session-list { max-height: 28rem; } .hero-seal { display: none; } }
@media (max-width: 1100px) {
  .sidebar { position: static; width: auto; border-right: 0; border-bottom: 1px solid var(--line); padding: 1.3rem; }
  .sidebar nav { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: 1.2rem; }
  .nav { width: auto; flex: 1 1 12rem; margin: 0; }
  .nav-caption, .sidebar-note, .sidebar-bottom { display: none; }
  main { margin: 0 auto; padding: 0 24px; }
}
@media (max-width: 760px) {
  .stats { grid-template-columns: minmax(0, 1fr); }
  .hero { padding: 1.8rem 0; }
  h1 { font-size: 1.9rem; }
  .topbar { align-items: flex-start; flex-direction: column; }
  .tools-panel { padding: 1.3rem; }
  .input-row input { flex-basis: 100%; }
  .input-row button { flex: 1 1 auto; }
  .reader-header, .version-bar, .summary-meta, .agenda-item { padding: 1.5rem; }
  .item-head { flex-wrap: wrap; }
  .discussion-box { padding: 1.2rem; }
}
@media (max-width: 420px) {
  main { padding: 0 12px; }
  .reader-header, .version-bar, .summary-meta, .agenda-item { padding: 1rem; }
  .sidebar { padding: 1rem; }
  .discussion-box { padding: .85rem; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; animation: none !important; transition: none !important; } }
@media (forced-colors: active) { .badge, .top-number, .discussion-box, .session-card.selected, .nav.active { border: 1px solid CanvasText; } }

.calendar-fields { border: 0; padding: 0; margin: 0; min-width: 0; }
.calendar-fields legend { font-size: .9rem; font-weight: 650; margin-bottom: .8rem; padding: 0; }
.calendar-controls { display: flex; flex-wrap: wrap; align-items: end; gap: .75rem; }
.calendar-choice { min-width: 0; flex: 1 1 7rem; }
.calendar-choice select { width: 100%; }
.calendar-controls button { flex: 0 1 auto; }
@media (max-width: 600px) { .calendar-controls button { flex: 1 1 100%; } }
.research-tools { margin-top: 1rem; }
.research-tools label { display: block; font-weight: 650; margin-bottom: .6rem; }
.research-tools input { width: 100%; }
.search-result, .analysis-box { background: white; border: 1px solid var(--line); border-radius: .65rem; padding: 1.8rem; margin: 1.5rem 0; max-width: 75ch; }
.search-result h3 { font-size: 1.2rem; }
.search-excerpt { white-space: pre-line; line-height: 1.8; }
.search-result > a { display: inline-flex; align-items: center; min-height: 2.5rem; }
.coverage-note { color: var(--muted); background: var(--soft); border-left: 3px solid var(--teal); padding: 1rem 1.3rem; font-size: .9rem; }
.document-warning { color: #75371e; background: #fbede6; border-left: 3px solid #a85b31; padding: 1rem; font-size: .9rem; }
#history-panel { margin: 0 0 2rem; }
#history-panel h2 { margin-bottom: .7rem; }
@media (max-width: 600px) { .search-result, .analysis-box { padding: 1.1rem; } }
.event-preview main { max-width: 70ch; margin: 2rem auto; padding: 1.5rem; }
.event-preview section { padding: 1.5rem 0; border-bottom: 1px solid var(--line); }
.event-preview details { margin: 1.2rem 0; padding: 1.2rem; background: #fbf4e9; }
.event-preview summary { min-height: 2.5rem; }

#calendar-availability { margin-top: 1rem; }

/* Stadtlabor-Anlehnung: #385953, helle blaue Flächen, klare Kopf-Navigation.
   Eigenständiger Radar-Auftritt; Schriftgröße und Lesefunktionen bleiben bestehen. */
.sidebar {
  position: static; width: auto; overflow: visible; padding: 0;
  display: grid; grid-template-columns: minmax(0, 1fr) auto;
  background: var(--teal); color: white; border: 0;
}
.brand { color: white; padding: 1.4rem max(24px, calc((100vw - 1500px) / 2)); font-size: 1.5rem; }
.brand-mark { background: transparent; border: 2px solid #fff; border-radius: .2rem; }
.brand-mark span { color: white; }
.brand-sub { font-size: .7rem; letter-spacing: .12em; }
.sidebar-note { margin: 0; padding: 1.5rem 2rem; align-self: center; font-size: .8rem; }
.sidebar-note p { color: white; margin-bottom: 0; }
.sidebar-note .local-dot { background: white; }
.sidebar nav {
  grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 0;
  background: white; padding: 0 max(24px, calc((100vw - 1500px) / 2));
  border-bottom: 1px solid var(--line);
}
.nav-caption, .sidebar-bottom { display: none; }
.nav {
  width: auto; flex: 0 1 auto; margin: 0; padding: 1rem 1.2rem;
  border: 0; border-bottom: 4px solid transparent; border-radius: 0;
  font-weight: 700; color: var(--ink);
}
.nav:hover { background: #f1f6fa; }
.nav.active { color: var(--teal); border-color: var(--teal); background: var(--soft); }
.nav-count { background: #dee9ed; color: var(--ink); }
main { margin: 0 auto; max-width: 1500px; padding: 0 32px; }
.topbar { border: 0; min-height: 4.5rem; }
.hero {
  background: var(--soft); padding: 2.4rem; margin: 0 0 2rem;
  border-left: 6px solid var(--teal); align-items: flex-start;
}
.hero h1 { max-width: none; letter-spacing: -.025em; }
.hero p { max-width: 65ch; }
.hero-seal { display: none; }
.eyebrow, .section-kicker { letter-spacing: .04em; }
.stats article, .tools-panel, .session-panel, .reader, .knowledge-card,
.jobs-panel, .search-result, .analysis-box { border-radius: .2rem; box-shadow: none; }
.stats .stat-accent { border-color: #c8d8e4; }
.stats strong { color: var(--teal); }
.reader-header { border-radius: .2rem .2rem 0 0; }
.primary, .secondary, .button, input, select, textarea, .filter { border-radius: .2rem; }
.primary:hover { background: #263f3b; }
.secondary { border-color: var(--teal); color: var(--teal); }
.filter.selected { background: var(--soft); }
.session-card.selected { border-left-color: var(--teal); }
.date-box { border-radius: .15rem; border-color: #a5b8b4; }
.summary-field strong { color: var(--teal); }
.empty-symbol { background: var(--soft); border-color: #b9ccd9; color: var(--teal); }
footer { border-top: 1px solid var(--line); margin-top: 2rem; }
html:is([data-reading-size="extra"], [data-reading-size="double"]) .sidebar {
  display: block; padding: 0;
}
html:is([data-reading-size="extra"], [data-reading-size="double"]) .sidebar nav {
  display: flex; gap: 0;
}
html:is([data-reading-size="extra"], [data-reading-size="double"]) .nav { flex: 1 1 12rem; }
@media (min-width: 1650px) { main { padding: 0 40px; } }
@media (max-width: 1100px) {
  .sidebar { padding: 0; }
  .sidebar nav { margin-top: 0; gap: 0; }
  .sidebar-note { display: none; }
  .brand { grid-column: 1 / -1; }
  .nav { flex: 1 1 auto; }
  main { padding: 0 24px; }
}
@media (max-width: 760px) {
  .brand { padding: 1.2rem; }
  .sidebar nav { padding: 0 .5rem; }
  .nav { padding: .8rem .65rem; flex: 1 1 45%; font-size: .9rem; }
  .hero { padding: 1.5rem; }
  .hero h1 { font-size: 1.9rem; }
}
@media (max-width: 420px) { main { padding: 0 12px; } .hero { padding: 1.2rem; } }
@media print {
  .sidebar, .topbar, .tools-panel, .session-panel, .reader-actions, .version-bar, footer { display: none; }
  .workspace { display: block; }
  .reader { border: 0; }
  .hero { background: white; border: 0; padding: 0; }
}

/* Kompakter Kopf: Hinweise stehen auf breiten Bildschirmen nebeneinander. */
.brand { padding-top: .8rem; padding-bottom: .8rem; }
.sidebar-note { display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: center; gap: .35rem .9rem; padding: .7rem 1.2rem; font-size: .75rem; }
.sidebar-note > span:last-child { font-weight: 400; }
@media (max-width: 1100px) { .sidebar-note { display: none; } }
html:is([data-reading-size="extra"], [data-reading-size="double"]) .sidebar-note { display: none; }

.documentation-layout { display: grid; grid-template-columns: minmax(12rem, .65fr) minmax(0, 2fr); gap: 1.5rem; align-items: start; margin: 2rem 0; }
#documentation-list { display: flex; flex-direction: column; gap: .6rem; }
#documentation-list button { text-align: left; justify-content: flex-start; }
#documentation-list [aria-pressed="true"] { background: var(--soft); border-width: 2px; font-weight: 750; }
#documentation-reader { max-width: none; min-width: 0; }
#documentation-reader p, #documentation-reader li { max-width: 70ch; }
#documentation-reader h2, #documentation-reader h3 { margin-top: 1.8rem; }
#documentation-reader pre { white-space: pre-wrap; overflow-wrap: anywhere; background: #f1f6fa; padding: 1rem; font-size: .85rem; }
#documentation-reader code { font-size: .9em; overflow-wrap: anywhere; }
@media (max-width: 1000px) { .documentation-layout { grid-template-columns: minmax(0, 1fr); } }
html:not([data-reading-size="normal"]) .documentation-layout { grid-template-columns: minmax(0, 1fr); }

/* Das bereitgestellte Original-Logo wird unverändert lokal ausgeliefert. */
.brand-logo { display: block; width: 3.2rem; height: 3.2rem; object-fit: contain; flex-shrink: 0; border-radius: .15rem; }
.brand { min-width: 0; gap: .8rem; }
@media (max-width: 420px) { .brand { font-size: 1.3rem; } .brand-logo { width: 2.8rem; height: 2.8rem; } }

.document-illustration { margin: 0 0 2rem; padding: 1rem; border: 1px solid var(--line); background: #f1f6fa; border-radius: .2rem; }
.document-illustration > a { display: block; width: fit-content; max-width: 100%; margin: 0 auto; }
.document-illustration img { display: block; width: auto; height: auto; max-width: 100%; max-height: 25rem; background: white; border: 1px solid var(--line); }
.document-illustration figcaption { margin-top: 1rem; font-size: .9rem; }
.document-illustration figcaption > strong, .document-illustration figcaption > span { display: block; }
.document-illustration .source-links { margin-top: .5rem; }
@media (max-width: 600px) { .document-illustration { padding: .6rem; } }

.brand-logo { width: 5rem; height: 5rem; }
@media (max-width: 420px) { .brand-logo { width: 4rem; height: 4rem; } }

.team-auth main { max-width: 32rem; margin: 2rem auto; padding: 1.5rem; }
.team-auth h1 { font-size: 1.9rem; }
.team-auth label, #admin-view label, #feedback-view label { display: block; font-weight: 650; margin: 1rem 0 .4rem; }
.team-auth input, #admin-view input:not([type="checkbox"]), #admin-view select, #feedback-view select, #feedback-view textarea { display: block; width: 100%; margin-bottom: 1rem; }
#admin-view input[type="checkbox"] { min-height: auto; width: 1.1rem; height: 1.1rem; margin-right: .4rem; }
#admin-view .knowledge-card { max-width: none; margin: 1.5rem 0; }
#admin-user-form, #feedback-form, #team-settings-form { max-width: 45rem; }
.admin-section { margin-top: 2.5rem; }
.admin-user { background: white; border: 1px solid var(--line); padding: 1.5rem; margin: 1rem 0; border-radius: .2rem; }
.admin-user h3 { margin-top: 0; }
.feedback-text { white-space: pre-wrap; }
#team-public-url { overflow-wrap: anywhere; }

.generation-status { margin-top: 1rem; padding: 1rem; background: var(--soft); border-left: 4px solid var(--teal); }
.generation-status p { margin-bottom: .7rem; color: var(--ink); }
.generation-status progress { display: block; width: 100%; height: .6rem; margin: .8rem 0; accent-color: var(--teal); }
.generation-status.error { background: #fbede6; border-color: #a85b31; }
.source-dialog { color: var(--ink); background: white; border: 1px solid var(--line); border-radius: .2rem; width: min(90vw,50rem); max-height: 85vh; padding: 1.5rem; overflow-y: auto; }
.source-dialog::backdrop { background: #173b3899; }
.source-dialog form { display: flex; justify-content: flex-end; position: sticky; top: 0; background: white; padding-bottom: .5rem; }
.source-article-text { white-space: pre-wrap; line-height: 1.8; margin-top: 1.8rem; overflow-wrap: anywhere; }

footer nav { display: flex; flex-wrap: wrap; gap: .7rem 1.5rem; width: 100%; }
footer nav a { display: inline-flex; align-items: center; min-height: 2.5rem; }
.legal-page main { max-width: 75ch; margin: 2rem auto; padding: 0 1.2rem; }
.legal-page h2 { margin-top: 2rem; }
.standalone-image { display: block; max-width: 100%; height: auto; }

.press-coverage { margin: 2rem 0; padding: 1.5rem; border: 1px solid var(--border, #aabdb4); border-radius: .5rem; }
.coverage-entry { margin: 1.5rem 0; padding-bottom: 1.5rem; border-bottom: 1px solid #dce4df; }
.coverage-entry h3 { margin: .7rem 0; overflow-wrap: anywhere; }
