*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font-family: var(--font); font-size: 15px; line-height: 1.5;
  font-variant-numeric: tabular-nums; -webkit-font-smoothing: antialiased;
}
.wrap { max-width: 2400px; margin: 0 auto; padding: 0 clamp(16px, 3vw, 48px); }

/* Header */
.header { display: flex; align-items: center; justify-content: space-between; padding: var(--s5) 0; }
.brand { display: flex; align-items: center; gap: var(--s3); font-weight: 650; letter-spacing: -0.01em; font-size: 17px; }
.brand-mark { width: 26px; height: 26px; border-radius: 8px; background: linear-gradient(135deg, var(--accent), #8f9bff); }
.nav { display: flex; gap: var(--s5); color: var(--text-muted); font-size: 14px; }
.nav a { color: inherit; text-decoration: none; }
.nav a:hover, .nav a.active { color: var(--text); }

.pill { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px;
  background: var(--surface-2); color: var(--text-muted); font-size: 12px; font-weight: 500; }
.pill .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--text-faint); }

/* Hero */
.hero { padding: var(--s6) 0 var(--s5); }
.hero h1 { margin: var(--s3) 0 var(--s2); font-size: clamp(28px, 4vw, 40px); line-height: 1.1; letter-spacing: -0.03em; font-weight: 700; }
.hero p { margin: 0; color: var(--text-muted); max-width: 56ch; }

/* Karten */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); padding: var(--s5); }
.grid { display: grid; gap: var(--s4); }
.grid-kpi { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); margin-bottom: var(--s4); }
.grid-charts { grid-template-columns: repeat(auto-fit, minmax(440px, 1fr)); }
@media (max-width: 520px) { .grid-charts { grid-template-columns: 1fr; } .nav { display: none; } }

/* KPI */
.kpi-label { color: var(--text-muted); font-size: 13px; }
.kpi-row { display: flex; align-items: baseline; gap: var(--s3); margin: var(--s1) 0 var(--s3); }
.kpi-value { font-size: 30px; font-weight: 650; letter-spacing: -0.02em; }
.chip { font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 999px; }
.chip.pos { color: var(--pos); background: var(--pos-soft); }
.chip.neg { color: var(--neg); background: var(--neg-soft); }
.spark { height: 40px; }

/* Chart-Karte */
.card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: var(--s4); margin-bottom: var(--s4); }
.card-title { margin: 0; font-size: 16px; font-weight: 650; letter-spacing: -0.01em; }
.card-sub { margin: 2px 0 0; color: var(--text-muted); font-size: 13px; }
.legend { display: flex; gap: var(--s4); flex-wrap: wrap; margin-top: var(--s3); font-size: 12px; color: var(--text-muted); }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }

.chart { position: relative; width: 100%; }
.chart svg { display: block; width: 100%; overflow: visible; }
.chart .tt { position: absolute; pointer-events: none; opacity: 0; transition: opacity .12s;
  background: var(--text); color: var(--bg); padding: 6px 10px; border-radius: var(--radius-sm);
  font-size: 12px; line-height: 1.35; white-space: nowrap; transform: translate(-50%, -100%); }
.chart .tt b { display: block; font-size: 14px; font-weight: 650; }

.footer { color: var(--text-faint); font-size: 12px; padding: var(--s6) 0 var(--s7); }

/* ---- Makro → Mikro: Abschnitte und Granularitäts-Leiste ---- */
.level { padding: var(--s6) 0 var(--s5); scroll-margin-top: var(--s5); }
.level-head { margin-bottom: var(--s5); max-width: 62ch; }
.eyebrow { font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); }
.level-head h2 { margin: var(--s2) 0 var(--s2); font-size: clamp(24px, 3vw, 32px); letter-spacing: -0.025em; line-height: 1.15; }
.level-head p { margin: 0; color: var(--text-muted); }
.src { margin: var(--s3) 0 0; font-size: 12px; color: var(--text-faint); }
.placeholder { display: grid; place-items: center; min-height: 160px; color: var(--text-faint); border-style: dashed; box-shadow: none; background: transparent; }


/* Erklärung + aktuelle Lage pro Chart */
.about { margin: calc(var(--s2) * -1) 0 var(--s4); color: var(--text-muted); font-size: 13px; max-width: none; }
.now { display: flex; gap: var(--s3); align-items: flex-start; margin-top: var(--s4); padding-top: var(--s4); border-top: 1px solid var(--border); }
.now p { margin: 0; font-size: 14px; line-height: 1.45; }
.now .label { flex: none; }
.chip.hot { color: var(--warn); background: var(--warn-soft); }
.chip.cool { color: var(--accent); background: var(--accent-soft); }
.chip.mid { color: var(--text-muted); background: var(--surface-2); }
.tag { display: inline-block; margin-left: var(--s2); font-size: 11px; color: var(--text-faint); border: 1px dashed var(--border); border-radius: 6px; padding: 0 6px; white-space: nowrap; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* ---- Zeithorizont-Strahl ---- */
.beam { position: fixed; top: 20px; bottom: 20px; right: 18px; width: 160px; z-index: 10; pointer-events: none; }
.beam-hud { position: absolute; top: 0; right: 0; text-align: right; line-height: 1.15; }
.beam-hud small { display: block; font-size: 10px; letter-spacing: .08em; text-transform: uppercase; color: var(--text-faint); }
.beam-hud b { display: block; margin-top: 2px; font-size: 16px; font-weight: 650; letter-spacing: -0.02em; color: var(--text); }
.beam-hud span { display: block; margin-top: 2px; font-size: 11px; color: var(--accent); }
.beam-body { position: absolute; top: 72px; bottom: 0; left: 0; right: 0; }
.beam-track { position: absolute; top: 0; bottom: 0; right: 0; width: 2px; border-radius: 2px; background: var(--border); }
.beam-track::before { content: ""; position: absolute; top: 0; bottom: 0; right: 7px; width: 6px;
  background: repeating-linear-gradient(to bottom, var(--border) 0 1px, transparent 1px 9px); opacity: .9; }
.beam-fill { position: absolute; top: 0; right: 0; width: 2px; height: 0; border-radius: 2px;
  background: linear-gradient(to bottom, transparent, var(--accent)); box-shadow: 0 0 14px var(--accent-soft); }
.beam-thumb { position: absolute; top: 0; right: -5.5px; width: 13px; height: 13px; margin-top: -6.5px; border-radius: 50%;
  background: var(--surface); border: 2px solid var(--accent); box-shadow: 0 0 0 5px var(--accent-soft), 0 0 18px var(--accent); will-change: transform; }
.beam-mark { position: absolute; right: 22px; display: flex; align-items: center; gap: 8px; white-space: nowrap; pointer-events: auto;
  transform: translateY(-50%) translateX(calc(var(--w, 0) * -6px)); color: var(--text-faint); text-decoration: none; font-size: 13px;
  opacity: calc(.45 + var(--w, 0) * .55); font-weight: 500; }
.beam-mark i { width: calc(8px + var(--w, 0) * 14px); height: 1px; background: currentColor; }
.beam-mark.on { color: var(--text); font-weight: 650; }
@media (max-width: 1299px) {
  .beam { width: 12px; right: 6px; top: 16px; bottom: 16px; }
  .beam-hud, .beam-mark { display: none; }
  .beam-body { top: 0; }
  .beam-track::before { display: none; }
}

.grid-fit3 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid-fit3 .card { padding: var(--s4) var(--s5) var(--s5); }

/* Layouts: eine Spalte (Dekaden) und zwei Spalten (Monate, Tage) */
.grid-one { grid-template-columns: 1fr; }
.grid-two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 820px) { .grid-two { grid-template-columns: 1fr; } }
.grid-two .card { padding: var(--s4) var(--s5) var(--s5); }
.now-body { flex: 1; min-width: 0; }
.now-body p { margin: 0; font-size: 14px; line-height: 1.5; }
.facts { margin: var(--s3) 0 0; padding: 0; list-style: none; display: grid; gap: 6px; font-size: 13px; color: var(--text-muted); line-height: 1.45; }
.facts li { position: relative; padding-left: 14px; }
.facts li::before { content: ""; position: absolute; left: 0; top: .6em; width: 5px; height: 5px; border-radius: 50%; background: var(--axis); }
.facts b { color: var(--text); font-weight: 600; }

.outlook { display: flex; gap: var(--s3); align-items: flex-start; margin-bottom: var(--s5); }
.outlook .chip { flex: none; font-size: 13px; padding: 3px 10px; }
.outlook-note { margin: var(--s3) 0 0 !important; font-size: 12px !important; color: var(--text-faint); line-height: 1.45 !important; }
.sigline { display: flex; flex-wrap: wrap; gap: 6px 8px; align-items: center; margin-top: var(--s3); padding-top: var(--s3); border-top: 1px dashed var(--border); font-size: 12px; color: var(--text-muted); line-height: 1.45; }
.overview { margin-bottom: var(--s6); }
.ov-card { padding: var(--s5); }
.ov-head h2 { margin: 0; font-size: 18px; }
.ov-head p { margin: 4px 0 var(--s4); font-size: 13px; color: var(--text-muted); line-height: 1.45; }
.ov-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: var(--s4); }
.ov-col { display: block; padding: var(--s4); border: 1px solid var(--border); border-radius: var(--radius-sm); text-decoration: none; color: inherit; background: var(--surface); transition: border-color .15s, background .15s; }
.ov-col:hover { border-color: var(--accent); background: var(--surface-2); }
.ov-verdict { display: flex; align-items: center; gap: var(--s3); margin: var(--s2, 8px) 0 var(--s3); }
.ov-verdict b { font-size: 20px; font-variant-numeric: tabular-nums; }
.ov-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: 12.5px; }
.ov-list li { display: flex; align-items: center; gap: 8px; }
.ov-name { flex: 1; min-width: 0; color: var(--text-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ov-w { width: 22px; text-align: right; color: var(--text-faint); font-variant-numeric: tabular-nums; }
.ov-list .chip { min-width: 30px; text-align: center; padding: 1px 6px; }
.ov-chart { margin-top: var(--s5); padding-top: var(--s5); border-top: 1px solid var(--border); }
.ov-chart h3 { margin: 0; font-size: 15px; }
.ov-chart > p { margin: 4px 0 var(--s3); font-size: 13px; color: var(--text-muted); line-height: 1.45; }
.ov-sub { margin: var(--s5) 0 var(--s3) !important; font-size: 14px !important; }
.sc-bar { display: flex; flex-wrap: wrap; gap: var(--s3) var(--s5); align-items: center; margin-bottom: var(--s3); }
.sc-group { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.sc-lab { font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--text-faint); margin-right: 2px; }
.sc-chip { display: inline-flex; align-items: center; gap: 6px; font: inherit; font-size: 12.5px; padding: 4px 10px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); color: var(--text-faint); cursor: pointer; }
.sc-chip i { width: 9px; height: 9px; border-radius: 50%; opacity: .35; }
.sc-chip.on { color: var(--text); border-color: var(--axis); }
.sc-chip.on i { opacity: 1; }
.sc-seg { display: inline-flex; border: 1px solid var(--border); border-radius: 8px; overflow: hidden; }
.sc-seg button { font: inherit; font-size: 12px; padding: 4px 10px; border: 0; background: var(--surface); color: var(--text-muted); cursor: pointer; }
.sc-seg button + button { border-left: 1px solid var(--border); }
.sc-seg button.on { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.sc-plot { position: relative; }
.sc-plot svg { display: block; width: 100%; user-select: none; }
.sc-tt { position: absolute; opacity: 0; pointer-events: none; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); box-shadow: var(--shadow); padding: 8px 10px; font-size: 12px; line-height: 1.5; white-space: nowrap; transition: opacity .1s; }
.sc-tt b { display: block; margin-bottom: 2px; }
.sc-tt span { display: block; color: var(--text-muted); }
.sc-tt i { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; }
.sc-tt em { color: var(--text-faint); font-style: normal; }
.sc-hint { margin: var(--s3) 0 0; font-size: 12px; color: var(--text-faint); line-height: 1.45; }
.sc-table-wrap { overflow-x: auto; }
.sc-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.sc-table th { text-align: left; font-weight: 500; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--text-faint); padding: 0 12px 8px 0; }
.sc-table td { padding: 10px 12px 10px 0; border-top: 1px solid var(--border); vertical-align: top; font-variant-numeric: tabular-nums; }
.sc-table small { display: block; font-size: 11.5px; color: var(--text-faint); margin-top: 2px; }
.sc-table .muted { color: var(--text-faint); }

/* Zusammenhang Score / Rezessionen */
.rel-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: var(--s5); margin-top: var(--s3); }
.rel-grid h4 { margin: 0 0 var(--s3); font-size: 13px; color: var(--text-muted); font-weight: 600; }
.rel-row { display: grid; grid-template-columns: 112px 1fr 38px 70px; align-items: center; gap: 8px; margin: 8px 0; font-size: 12.5px; }
.rel-lab { color: var(--text-muted); }
.rel-bar { height: 12px; background: var(--surface-2); border-radius: 6px; overflow: hidden; }
.rel-bar i { display: block; height: 100%; border-radius: 6px; background: var(--text-faint); }
.rel-bar i.pos { background: var(--pos); } .rel-bar i.neg { background: var(--warn); } .rel-bar i.mid { background: var(--text-faint); } .rel-bar i.base { background: var(--border-strong, var(--border)); }
.rel-val { text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; }
.rel-n { color: var(--text-faint); font-size: 11.5px; text-align: right; }
.rel-base { padding-top: 8px; border-top: 1px dashed var(--border); }
.rel-tab { width: 100%; border-collapse: collapse; font-size: 12.5px; font-variant-numeric: tabular-nums; }
.rel-tab th, .rel-tab td { padding: 6px 8px; text-align: right; border-bottom: 1px solid var(--border); }
.rel-tab th:first-child { text-align: left; font-weight: 500; color: var(--text-muted); }
.rel-tab thead th { font-size: 11.5px; color: var(--text-faint); font-weight: 500; }
.rel-tab td small { display: block; font-size: 10.5px; color: var(--text-faint); }

.ov-total { display: flex; align-items: center; gap: var(--s3); flex-wrap: wrap; margin: 0 0 var(--s4); }
.ov-total b { font-size: 24px; font-variant-numeric: tabular-nums; }
.ov-total p { flex: 1 1 320px; margin: 0; font-size: 13px; color: var(--text-muted); line-height: 1.45; }

/* Zusammenhang-Streifen */
.rel { margin-top: var(--s3); }
.rel-cells { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.rel-cell { display: grid; gap: 4px; padding: 8px 10px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); }
.rel-cell.is-now { border-color: var(--text); box-shadow: 0 0 0 1px var(--text) inset; background: var(--surface-2); }
.rel-l { display: flex; align-items: center; justify-content: space-between; gap: 6px; font-size: 11.5px; color: var(--text-muted); }
.rel-l em { font-style: normal; font-size: 10px; letter-spacing: .06em; text-transform: uppercase; padding: 1px 6px; border-radius: 999px; background: var(--text); color: var(--surface); }
.rel-cell b { font-size: 19px; font-variant-numeric: tabular-nums; line-height: 1.1; }
.rel-cell .rel-bar { display: block; height: 5px; border-radius: 3px; background: var(--border); overflow: hidden; }
.rel-cell .rel-bar i { display: block; height: 100%; border-radius: 3px; background: var(--text-faint); }
.rel-cell.neg .rel-bar i { background: var(--warn); } .rel-cell.pos .rel-bar i { background: var(--pos); }
.rel-cell small { font-size: 10.5px; color: var(--text-faint); line-height: 1.3; }
.rel-cap { margin: 6px 0 0; font-size: 11.5px; color: var(--text-faint); line-height: 1.4; }
.ov-card .rel { margin: 0 0 var(--s4); }
@media (max-width: 520px) { .rel-cells { gap: 6px; } .rel-cell { padding: 6px 7px; } .rel-cell b { font-size: 16px; } }
/* Kacheln gleich hoch, aktuelle nicht absenken */
.rel-cells { align-items: stretch; }
.rel-cell { align-content: start; }
.rel-l { min-height: 20px; }
.rel-l em { line-height: 1.4; }

.rel-cell.is-click { cursor: pointer; transition: box-shadow .15s, transform .15s; }
.rel-cell.is-click:hover { box-shadow: 0 0 0 1px var(--text-faint); }
.rel-cell.is-click:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.rel-cell.is-sel.neg { box-shadow: 0 0 0 2px var(--warn); }
.rel-cell.is-sel.mid { box-shadow: 0 0 0 2px var(--text-muted); }
.rel-cell.is-sel.pos { box-shadow: 0 0 0 2px var(--accent); }

.scale { margin: 22px 0 14px; padding: 0 2px; }
.scale-bar { position: relative; display: flex; height: 8px; border-radius: 999px; }
.scale-bar i { display: block; height: 100%; }
.scale-bar .z-neg { background: var(--warn); opacity: .35; border-radius: 999px 0 0 999px; }
.scale-bar .z-mid { background: var(--text-faint); opacity: .3; }
.scale-bar .z-pos { background: var(--pos); opacity: .35; border-radius: 0 999px 999px 0; }
.scale-pin { position: absolute; top: 50%; width: 16px; height: 16px; margin: -8px 0 0 -8px; border-radius: 50%; background: var(--text); border: 3px solid var(--surface, #fff); box-shadow: 0 0 0 1px var(--text); }
.scale-pin b { position: absolute; bottom: 20px; left: 50%; transform: translateX(-50%); font-size: 12px; font-weight: 700; white-space: nowrap; color: var(--text); }
.scale-ticks { position: relative; height: 16px; margin-top: 8px; font-size: 11px; color: var(--text-faint); }
.scale-ticks span { position: absolute; transform: translateX(-50%); }
.scale-ticks span:first-child { transform: none; }
.scale-ticks span:last-child { transform: translateX(-100%); }

.ov-build { margin: 18px 0 10px; font-size: 14px; color: var(--text-muted); }
.ov-build b { color: var(--text); font-weight: 600; }

.rel-t { display: block; font-size: 11px; font-weight: 400; color: var(--text-faint); margin-top: 1px; }
.rel-cell .rel-l { min-height: 34px; align-items: flex-start; }

/* ---- Refinement: ruhiger, mathematischer Charakter ---- */
h1, h2, h3, .ov-total b, .ov-verdict b, .rel-cell b, .scale-pin b { font-family: var(--serif); font-weight: 500; letter-spacing: -0.01em; }
h2 { font-weight: 600; }
.ov-total b { font-size: 34px; }
.ov-verdict b { font-size: 26px; }
.rel-cell b { font-size: 26px; font-weight: 500; }
.scale-pin b { font-size: 13px; font-weight: 600; }
.eyebrow { color: var(--text-muted); font-size: 11px; letter-spacing: .16em; }
.chip { border-radius: 4px; letter-spacing: .01em; }
.brand { font-family: var(--serif); font-weight: 600; font-size: 19px; letter-spacing: .01em; }
.brand-mark { position: relative; border-radius: 4px; background: var(--accent); }
.brand-mark::after { content: "\03A3"; position: absolute; inset: 0; display: grid; place-items: center; color: #fff; font: 600 16px/1 var(--serif); }
.header { border-bottom: 1px solid var(--border); margin-bottom: var(--s5); }
.rel-bar { height: 3px; border-radius: 0; }
.rel-bar i { border-radius: 0; }
.scale-bar { height: 6px; border-radius: 0; }
.scale-bar .z-neg, .scale-bar .z-pos { border-radius: 0; }
.scale-ticks { font-family: var(--serif); font-style: italic; font-size: 12px; }
.card, .ov-col, .rel-cell { box-shadow: none; }
.ov-col { border-radius: var(--radius); }
.ov-chart, .ov-head { border-color: var(--border); }
.rel-cell .rel-bar { height: 3px; border-radius: 0; }
.rel-cell .rel-bar i { border-radius: 0; }
.rel-l em, .pill, .sc-chip { border-radius: 4px; }
.sc-seg { border-radius: 4px; }
.scale-bar { height: 6px; }
.scale-bar .z-neg, .scale-bar .z-pos { border-radius: 0; }
.rel-cell.is-now { border-color: var(--text); }

/* ---- Layout: Fast-Charts in 3 Spalten, Kacheln passen sich der Kartenbreite an, Kopfbereiche zentriert ---- */
.grid-fast { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 1560px) { .grid-fast { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 1100px) { .grid-fast { grid-template-columns: 1fr; } }
.card { container-type: inline-size; min-width: 0; }
.rel-cells > * { min-width: 0; }
@container (max-width: 540px) {
  .rel-cells { grid-template-columns: 1fr; }
  .rel-cell { grid-template-columns: 1fr auto; grid-template-areas: "l b" "bar bar" "s s"; align-items: center; }
  .rel-cell .rel-l { grid-area: l; min-height: 0; }
  .rel-cell b { grid-area: b; justify-self: end; }
  .rel-cell .rel-bar { grid-area: bar; }
  .rel-cell small { grid-area: s; }
}
.level-head { margin-left: auto; margin-right: auto; max-width: 72ch; text-align: center; }
.ov-head, .ov-build, .ov-chart h3, .ov-chart > p { text-align: center; }
.ov-total { justify-content: center; }
.outlook { flex-direction: column; align-items: center; text-align: center; }
.outlook .now-body { width: 100%; }
.outlook .rel, .outlook .rel-cap { text-align: left; }
.footer { text-align: center; }

/* Bewertung (z. B. "Well above target") zentriert, Rest darunter */
.now { flex-direction: column; align-items: stretch; gap: var(--s3); }
.now .label { align-self: center; }
.now-body { width: 100%; }
.now-body > p { text-align: center; }
.sigline { justify-content: center; text-align: center; }

/* Bernoulli logo: inline SVG mark replaces the Σ placeholder */
.brand-mark { background: none; border-radius: 0; display: block; }
.brand-mark::after { content: none; }

/* ---- Shell: linke Sidebar + Hauptbereich ---- */
.shell { display: grid; grid-template-columns: 232px minmax(0, 1fr); min-height: 100vh; }
.sidebar { position: sticky; top: 0; align-self: start; height: 100vh; display: flex; flex-direction: column; gap: var(--s5); padding: var(--s5) var(--s4); border-right: 1px solid var(--border); background: var(--surface); }
.sidebar .brand { padding: 0 var(--s2); }
.side-nav { display: grid; gap: 2px; }
.side-nav a { display: block; padding: 8px var(--s3); border-radius: var(--radius-sm); color: var(--text-muted); text-decoration: none; font-size: 14px; }
.side-nav a:hover { background: var(--surface-2); color: var(--text); }
.side-nav a.active { background: var(--accent-soft); color: var(--accent); font-weight: 600; }
.sidebar .pill { margin-top: auto; align-self: flex-start; margin-left: var(--s2); }
.main { min-width: 0; }
.main .wrap { padding-top: var(--s5); }
@media (max-width: 820px) {
  .shell { grid-template-columns: minmax(0, 1fr); }
  .sidebar { position: fixed; z-index: 60; top: 0; left: 0; bottom: 0; width: min(290px, 84vw); height: 100dvh; overflow-y: auto; overscroll-behavior: contain; transform: translateX(-100%); visibility: hidden; transition: transform .22s ease, visibility 0s .22s; box-shadow: none; }
  body.nav-open .sidebar { transform: none; visibility: visible; transition: transform .22s ease; box-shadow: 0 0 40px rgba(0,0,0,.18); }
  .side-nav a { padding: 12px var(--s3); font-size: 15px; }
  .nav-backdrop { display: block; position: fixed; inset: 0; z-index: 55; background: rgba(15,18,30,.38); opacity: 0; pointer-events: none; transition: opacity .22s ease; }
  body.nav-open .nav-backdrop { opacity: 1; pointer-events: auto; }
  body.nav-open { overflow: hidden; }
  .topbar { display: flex; }
}
}

/* ---------- Seitenleiste mit Gruppen (Zielgruppen / spätere Bundles) ---------- */
.side-nav { gap: var(--s4); }
.side-group { display: grid; gap: 2px; }
.side-label { padding: 0 var(--s3) 4px; font-size: 10.5px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--text-faint); }
@media (max-width: 820px) { .side-group { margin-top: var(--s2); } .side-label { padding: 0 var(--s3) 6px; } }

/* ---------- Themenseiten ---------- */
.topic-ov { margin-bottom: var(--s5); }
.topic-ov .ov-head h2 { margin-bottom: var(--s4); }
.ov-asof { margin: 0; font-size: 12px; color: var(--text-faint); }
.rel-dual { align-content: start; }
.rel-pair { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 4px 8px; font-size: 12px; }
.rel-pair .rp-n { color: var(--text-muted); }
.rel-pair b { font-size: 16px !important; text-align: right; }
.rel-pair .rel-bar { display: block; height: 3px; background: var(--border); overflow: hidden; }
.rel-pair .rel-bar i { display: block; height: 100%; }
.rel-pair .rel-bar.a i { background: var(--warn); }
.rel-pair .rel-bar.b i { background: var(--pos); }
body[data-page="fed-rates"] .rel-pair .rel-bar.a i { background: var(--accent); }
body[data-page="fed-rates"] .rel-pair .rel-bar.b i { background: var(--warn); }
.rel-pair > * { grid-area: auto !important; justify-self: stretch; }
.rel-pair b { justify-self: end !important; }
@container (max-width: 540px) { .rel-cell.rel-dual { grid-template-columns: 1fr; grid-template-areas: "l" "p" "s"; } .rel-dual .rel-l { grid-area: l; } .rel-dual .rel-pair { grid-area: p !important; } .rel-dual > small { grid-area: s; } }
.now-body .rel-cap { font-size: 11.5px; line-height: 1.4; color: var(--text-faint); text-align: left; }

/* ---------- Asset playbook ---------- */
.rg-gi { background: var(--pos-soft); fill: var(--pos-soft); }
.rg-GI { background: var(--warn-soft); fill: var(--warn-soft); }
.rg-gI { background: var(--neg-soft); fill: var(--neg-soft); }
.rg-gi2 { background: var(--accent-soft); fill: var(--accent-soft); }
#regime, .pb-signals, .method { margin-bottom: var(--s5); }
.ov-head p b { color: var(--text); }
.rg-grid { display: grid; grid-template-columns: 22px 1fr; grid-template-rows: auto auto; gap: 8px; }
.rg-axis { display: flex; justify-content: space-around; font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--text-faint); }
.rg-y { writing-mode: vertical-rl; transform: rotate(180deg); flex-direction: row-reverse; }
.rg-x { grid-column: 2; }
.rg-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.rg-tile, .pb-cell { display: grid; gap: 6px; align-content: start; padding: 10px 12px; border: 1px solid var(--border); border-radius: var(--radius-sm); min-width: 0; }
.rg-tile.is-now, .pb-cell.is-now { border-color: var(--text); box-shadow: 0 0 0 1px var(--text) inset; }
.rg-tile small, .pb-cell small { font-size: 10.5px; color: var(--text-faint); }
.pb-pair { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; align-items: baseline; font-size: 12px; color: var(--text-muted); }
.pb-pair b { font-family: var(--serif); font-weight: 500; font-size: 20px; color: var(--text); text-align: right; }
.pb-cell .pb-pair b { font-size: 17px; }
.rg-hist { width: 100%; margin-top: var(--s3); }
.rg-tick { font-size: 10.5px; fill: var(--axis); }
.legend i.rg-gi, .legend i.rg-GI, .legend i.rg-gI, .legend i.rg-gi2 { border: 1px solid var(--border); }
.pb-row { display: grid; grid-template-columns: minmax(180px, 220px) 1fr; gap: var(--s4); padding: var(--s4) 0; border-top: 1px solid var(--border); align-items: start; }
.pb-name a { display: block; font-weight: 600; color: var(--text); text-decoration: none; }
.pb-name a:hover { color: var(--accent); }
.pb-now { font-size: 12px; color: var(--text-faint); }
.pb-cells { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.pb-all { background: var(--surface-2); border-style: dashed; }
@media (max-width: 1100px) { .pb-row { grid-template-columns: 1fr; } }
@media (max-width: 640px) { .pb-cells, .rg-tiles { grid-template-columns: 1fr 1fr; } }
.method h3 { margin: 0 0 var(--s2); font-size: 15px; }

/* ---------- Evidence lab ---------- */
.ev-card .card-head { align-items: center; margin-bottom: var(--s3); }
.ev-card p { margin: 0 0 var(--s2); font-size: 13.5px; line-height: 1.5; color: var(--text-muted); }
.ev-card p b { color: var(--text); font-weight: 600; }
.ev-card .ev-why { margin: 0; padding-top: var(--s2); border-top: 1px solid var(--border); }
.ev-grid { margin-top: var(--s5); }

/* Stabilität je Periode */
.rel-cell .rob { display: block; margin-top: 3px; }
.rob.ok { color: var(--pos); } .rob.part { color: var(--warn); } .rob.no { color: var(--text-faint); }
.rg-hist rect.rg-gi { fill: var(--pos); opacity: .55; } .rg-hist rect.rg-GI { fill: var(--warn); opacity: .5; }
.rg-hist rect.rg-gI { fill: var(--neg); opacity: .55; } .rg-hist rect.rg-gi2 { fill: var(--accent); opacity: .45; }
.legend i.rg-gi { background: var(--pos); opacity: .55; } .legend i.rg-GI { background: var(--warn); opacity: .5; }
.legend i.rg-gI { background: var(--neg); opacity: .55; } .legend i.rg-gi2 { background: var(--accent); opacity: .45; }

/* ---------- About, Alerts, Privacy ---------- */
.prose h3 { margin: 0 0 var(--s3); font-size: 17px; }
.prose p { margin: 0 0 var(--s3); font-size: 14px; line-height: 1.6; color: var(--text-muted); }
.prose p:last-child { margin-bottom: 0; }
.prose a, .al-fine a, .footer a { color: var(--accent); }
.privacy { max-width: 820px; margin: 0 auto; }
.privacy h3 { margin-top: var(--s5); } .privacy h3:first-child { margin-top: 0; }
.al-card h3 { margin: 0 0 var(--s3); font-size: 17px; }
.al-card > p { margin: 0 0 var(--s4); font-size: 14px; color: var(--text-muted); line-height: 1.5; }
.al-card label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; }
.al-row { display: flex; gap: 8px; flex-wrap: wrap; }
.al-row input { flex: 1 1 220px; min-width: 0; padding: 10px 12px; font: inherit; font-size: 15px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); color: var(--text); }
.al-row input:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.al-btn { padding: 10px 18px; font: inherit; font-size: 14px; font-weight: 600; color: #fff; background: var(--accent); border: 0; border-radius: var(--radius-sm); cursor: pointer; }
.al-btn:disabled { opacity: .5; cursor: default; }
.al-hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.al-msg { margin: var(--s3) 0 0; padding: 10px 12px; font-size: 14px; border-radius: var(--radius-sm); }
.al-msg.ok { color: var(--pos); background: var(--pos-soft); } .al-msg.err { color: var(--neg); background: var(--neg-soft); }
.al-fine { margin: var(--s4) 0 0; font-size: 12px; color: var(--text-faint); line-height: 1.5; }
.al-mail { border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 14px; margin-bottom: var(--s4); background: var(--surface-2); font-size: 14px; }
.al-mail p { margin: 10px 0 0; line-height: 1.5; } .al-mail a { color: var(--accent); text-decoration: underline; }
.al-subj { font-weight: 600; } .al-ctx { font-size: 12.5px; color: var(--text-muted); }
/* Playbook auf schmalen Bildschirmen: Werte nicht umbrechen */
.pb-pair b { white-space: nowrap; }
@media (max-width: 520px) { .pb-pair { font-size: 11.5px; gap: 2px 6px; } .pb-pair b { font-size: 17px; } .pb-cell .pb-pair b { font-size: 15px; } .rg-tile, .pb-cell { padding: 8px 10px; } }
@media (max-width: 520px) { .rg-tile .pb-pair, .pb-cell .pb-pair { grid-template-columns: 1fr; gap: 0; } .rg-tile .pb-pair b, .pb-cell .pb-pair b { text-align: left; margin-bottom: 4px; } }

/* About: Kunstmotiv */
.ab-art { margin: 0 0 var(--s5); }
.ab-canvas { position: relative; height: 240px; border-radius: var(--radius); background: radial-gradient(120% 140% at 100% 50%, var(--accent-soft) 0%, transparent 60%), linear-gradient(180deg, var(--surface) 0%, var(--surface-2) 100%); overflow: hidden; }
.ab-runs { position: absolute; inset: 0; width: 100%; height: 100%; }
.ab-run { fill: none; stroke: var(--accent); stroke-opacity: .13; stroke-width: 1; vector-effect: non-scaling-stroke; }
.ab-run-hi { stroke-opacity: .85; stroke-width: 1.6; }
.ab-half { stroke: var(--accent); stroke-opacity: .35; stroke-dasharray: 2 5; vector-effect: non-scaling-stroke; }
.ab-art figcaption { margin-top: var(--s2); font-size: 12.5px; color: var(--text-muted); }
@media (max-width: 520px) { .ab-canvas { height: 180px; } }
/* Randleiste rechts: Motiv zieht sich beim Scrollen über die Seite */
.bn-rail { display: none; }
@media (min-width: 1100px) {
  .bn-rail { display: block; position: fixed; top: 0; right: 0; width: 46px; height: 100vh; pointer-events: none; z-index: 0;
    -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 8%, #000 92%, transparent 100%); mask-image: linear-gradient(180deg, transparent 0%, #000 8%, #000 92%, transparent 100%); }
  .bn-rail svg { position: absolute; inset: 0; width: 100%; height: 100%; }
  .bn-rail path { fill: none; stroke: var(--accent); vector-effect: non-scaling-stroke; stroke-width: .8; stroke-linecap: round; }
  .bn-rail .base path { stroke-opacity: .06; }
  .bn-rail .ink path { stroke-opacity: .2; }
  .bn-rail .ink path.hi { stroke-opacity: .55; stroke-width: 1.1; }
  .bn-rail .base path.hi { stroke-opacity: .12; }
  .has-rail .main { padding-right: 46px; }
}
@media (prefers-reduced-motion: reduce) { .bn-rail .ink { -webkit-mask-image: none !important; mask-image: none !important; } }

/* Feedback-Seite */
.fb-form { max-width: 640px; margin: 0 auto; padding: var(--s5); display: grid; gap: var(--s4); }
.fb-stars { border: 0; margin: 0; padding: 0; }
.fb-stars legend { font-size: 14px; color: var(--text); margin-bottom: var(--s2); padding: 0; }
.fb-stars legend span { color: var(--text-faint); }
.fb-row { display: flex; gap: var(--s2); }
.fb-row label { position: relative; }
.fb-row input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.fb-row span { display: grid; place-items: center; width: 40px; height: 36px; border: 1px solid var(--border); border-radius: var(--radius-sm); font-size: 14px; color: var(--text-muted); }
.fb-row input:checked + span { background: var(--accent); border-color: var(--accent); color: #fff; }
.fb-row input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.fb-scale { display: flex; justify-content: space-between; width: 232px; margin-top: 4px; font-size: 11px; color: var(--text-faint); }
.fb-label { display: grid; gap: 6px; font-size: 14px; color: var(--text); }
.fb-label textarea { font: inherit; font-size: 14px; padding: 10px 12px; border: 1px solid var(--border); border-radius: var(--radius-sm); resize: vertical; color: var(--text); background: var(--surface); }
.fb-label textarea:focus { outline: 2px solid var(--accent-soft); border-color: var(--accent); }
.fb-hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.fb-foot { display: flex; align-items: center; justify-content: flex-end; gap: var(--s4); }
.fb-msg { font-size: 13px; color: var(--text-muted); }
.fb-send { font: inherit; font-size: 14px; padding: 9px 18px; border: 0; border-radius: var(--radius-sm); background: var(--accent); color: #fff; cursor: pointer; }
.fb-send:disabled { opacity: .6; cursor: default; }
.level .al-fine { text-align: center; }
/* Admin */
.adm { max-width: 860px; padding-top: var(--s6); }
.adm-login { display: flex; gap: var(--s2); align-items: center; flex-wrap: wrap; font-size: 14px; }
.adm-login input { font: inherit; padding: 6px 8px; border: 1px solid var(--border); border-radius: var(--radius-sm); }
.adm-login button, .adm-item button { font: inherit; font-size: 13px; padding: 6px 12px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); cursor: pointer; }
.adm-msg { font-size: 13px; color: var(--text-muted); }
.adm-list { display: grid; gap: var(--s3); }
.adm-item { padding: var(--s3) var(--s4); }
.adm-meta { display: flex; gap: var(--s2); align-items: center; font-size: 12px; color: var(--text-faint); }
.adm-meta button { margin-left: auto; }
.adm-item p { margin: var(--s2) 0 0; font-size: 14px; white-space: normal; }

/* Crypto-Seite */
.crypto-note { padding: var(--s3) var(--s4); font-size: 13.5px; color: var(--text-muted); border-color: var(--accent); background: var(--accent-soft); margin-bottom: var(--s4); line-height: 1.5; }
.crypto-note b { color: var(--text); }
.crypto-ov { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 720px) { .crypto-ov { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.ov-note { margin: var(--s2) var(--s4) var(--s3); font-size: 12px; color: var(--text-faint); }
.now-body .rule { margin-top: 6px; font-size: 12px; color: var(--text-faint); }

/* Tabellen (Sell-off check) */
.tbl-wrap { overflow-x: auto; margin: var(--s2) 0 var(--s3); }
.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.tbl th { text-align: left; font-weight: 600; color: var(--text-muted); font-size: 12px; padding: 8px 10px; border-bottom: 1px solid var(--border); white-space: nowrap; }
.tbl td { padding: 9px 10px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.tbl td:first-child { white-space: nowrap; font-variant-numeric: tabular-nums; }
.tbl .chip { font-size: 11.5px; }

/* ---------- Handy-Menü: Seitenleiste als ausklappbare Schublade ---------- */
.topbar { position: sticky; top: 0; z-index: 50; align-items: center; gap: var(--s3); padding: 8px var(--s4); background: var(--surface); border-bottom: 1px solid var(--border); font-family: var(--serif, inherit); font-weight: 600; font-size: 17px; }
.topbar .brand-mark { width: 26px; height: 26px; }
.menu-btn { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; margin-left: -10px; border: 0; background: none; border-radius: var(--radius-sm); color: var(--text); cursor: pointer; }
.menu-btn:active { background: var(--surface-2); }
.menu-btn svg { width: 24px; height: 24px; }
@media (min-width: 821px) { .topbar, .nav-backdrop { display: none !important; } }

.ov-vcap { font-size: 12px; color: var(--text-muted); }
.ov-verdict { margin-bottom: var(--s4); }
.scale-pin b { display: none; }
.scale-ticks span:last-child { transform: translateX(-100%); }
.scale-ticks span { white-space: nowrap; }
.scale-ticks span:last-child { left: auto !important; right: 0; transform: none; }

/* Scrollleiste: schmal, zurückhaltend */
html { scrollbar-width: thin; scrollbar-color: rgba(120, 125, 140, .28) transparent; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(120, 125, 140, .28); border-radius: 8px; border: 2px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background: rgba(120, 125, 140, .5); background-clip: padding-box; border: 2px solid transparent; }
