/* IIINITY-Designvorlage v1.0.1 (2026-09-23) · Bauteile
   Nur Tokens, keine festen Farbwerte. Maße wie Vergleichsrechner.html. Ein Schmuckelement je Fläche. */

/* ── Kopf ─────────────────────────────────────────── */
.kopf { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: var(--abstand-polster); margin-bottom: 32px; padding: 0 4px; }
.kopf-marken { display: flex; align-items: center; gap: var(--abstand-block); flex-wrap: wrap; }
/* Logos sind Marine auf transparent: im dunklen Thema auf heller Plakette (--logo-flaeche) */
.kopf-logo { display: block; box-sizing: content-box; background: var(--logo-flaeche); padding: var(--logo-polster); border-radius: var(--radius-klein); }
.kopf-logo--links { height: 28px; }
.kopf-logo--mitte { height: 44px; }
.thema-schalter {
  appearance: none; -webkit-appearance: none; cursor: pointer; font-family: inherit;
  font-size: var(--t-label); font-weight: 500; color: var(--color-text-stark);
  background: transparent; border: 1px solid var(--color-feldrand); border-radius: var(--radius-rund);
  min-height: 32px; padding: 4px 16px;
  transition: border-color var(--zeit-schnell) var(--kurve-zustand);
}
.thema-schalter:hover { border-color: var(--color-primary); }

/* ── Fuß ──────────────────────────────────────────── */
.fuss { margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--color-border); font-size: var(--t-hinweis); line-height: 1.6; color: var(--color-text); }
.fuss p + p { margin-top: 8px; }
.fuss-werbung { font-weight: 600; letter-spacing: 1px; text-transform: uppercase; margin-bottom: 8px; }
.fuss-version { margin-top: 12px; }

/* ── Karte ────────────────────────────────────────── */
.karte { background: var(--color-surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 32px; margin-bottom: 24px; }
.karte--gold { border-top: 3px solid var(--color-primary); }
.karte-kopf { font-weight: 600; font-size: var(--t-kartentitel); color: var(--color-headings); margin-bottom: 24px; padding-bottom: 12px; border-bottom: 2px solid var(--color-border); }
.karte-zwischen { font-weight: 600; font-size: var(--t-text); color: var(--color-headings); margin: 0 0 14px; padding: 0 0 6px 10px; border-bottom: 1px solid var(--color-border); border-left: 3px solid var(--color-primary); }
.raster + .karte-zwischen { margin-top: 26px; }
@media (max-width: 700px) { .karte { padding: 20px; } }

/* ── Felder ───────────────────────────────────────── */
.feld { display: flex; flex-direction: column; }
.feld > label, .feld-titel { font-weight: 500; font-size: var(--t-label); color: var(--color-text-stark); margin-bottom: 6px; }
.hinweis { font-size: var(--t-hinweis); color: var(--color-text); margin-top: 3px; }
input[type="number"], input[type="text"], input[type="email"], input[type="date"], select {
  width: 100%; height: 40px; padding: 0 12px;
  font-family: inherit; font-size: var(--t-text); font-weight: 500; color: var(--color-text-stark);
  background-color: var(--color-surface); border: 2px solid var(--color-eingabe-rand); border-radius: var(--radius);
  transition: border-color var(--zeit-schnell) var(--kurve-zustand);
}
input:focus, select:focus { border-color: var(--color-primary); }
select {
  appearance: none; -webkit-appearance: none; padding-right: 36px;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--color-text-stark) 50%),
    linear-gradient(135deg, var(--color-text-stark) 50%, transparent 50%);
  background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}
input.ist-gesperrt { background-color: var(--color-surface-alt); border-color: var(--color-feldrand); color: var(--color-text); cursor: not-allowed; }
.mit-einheit { position: relative; }
.mit-einheit input { padding-right: 40px; }
.einheit {
  position: absolute; right: 0; top: 0; height: 40px; width: 32px;
  display: flex; align-items: center; justify-content: center;
  background: var(--color-eingabe-rand); color: var(--color-einheit-text);
  font-size: var(--t-text); font-weight: 500;
  border-radius: 0 var(--radius) var(--radius) 0; pointer-events: none;
}

/* Schalter (Checkbox) */
.schalter-zeile { display: flex; align-items: center; gap: 10px; min-height: 40px; }
.schalter {
  position: relative; width: 44px; height: 24px; flex-shrink: 0;
  appearance: none; -webkit-appearance: none; cursor: pointer; border: none; border-radius: 12px;
  background: var(--color-feldrand); transition: background-color var(--zeit-schnell) var(--kurve-zustand);
}
.schalter:checked { background: var(--color-primary); }
.schalter::after {
  content: ''; position: absolute; top: 2px; left: 2px; width: 20px; height: 20px; border-radius: 50%;
  background: var(--color-auf-marine); transition: transform var(--zeit-schnell) var(--kurve-zustand);
}
.schalter:checked::after { transform: translateX(20px); }

/* Regler */
.regler-zeile { display: flex; align-items: center; gap: 12px; }
.regler { flex: 1; height: 6px; appearance: none; -webkit-appearance: none; border: none; border-radius: 3px; background: var(--color-surface-alt); }
.regler::-webkit-slider-thumb { -webkit-appearance: none; appearance: none; width: 22px; height: 22px; border-radius: 50%; background: var(--color-eingabe-rand); border: 3px solid var(--color-surface); box-shadow: var(--shadow); cursor: pointer; }
.regler::-moz-range-thumb { width: 16px; height: 16px; border-radius: 50%; background: var(--color-eingabe-rand); border: 3px solid var(--color-surface); cursor: pointer; }
.regler-wert { min-width: 60px; text-align: center; font-weight: 600; font-size: 16px; color: var(--color-headings); background: var(--color-surface-alt); border-radius: var(--radius); padding: 6px 10px; }

/* ── Aktion ───────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 8px 32px; border-radius: var(--radius); border: 2px solid transparent;
  font-family: inherit; font-weight: 300; font-size: 18px; cursor: pointer; text-decoration: none;
  transition: background-color var(--zeit-schnell) var(--kurve-zustand), border-color var(--zeit-schnell) var(--kurve-zustand);
}
.btn--primaer { background: var(--color-primary); border-color: var(--color-primary); color: var(--color-auf-gold); font-weight: 400; }
.btn--primaer:hover { background: var(--color-primary-hover); border-color: var(--color-primary-hover); }
.btn--sekundaer { background: var(--color-marine-flaeche); border-color: var(--color-marine-flaeche); color: var(--color-auf-marine); }
.btn--sekundaer:hover { filter: brightness(1.15); }
.btn--kontur { background: transparent; border-color: var(--color-eingabe-rand); color: var(--color-text-stark); }
.btn--kontur:hover { background: var(--zustand-hover); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: var(--zustand-aus); cursor: not-allowed; }
.btn-zeile { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin: 32px 0; }

.filter-leiste { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-bottom: 24px; padding: 12px 16px; background: var(--color-surface); border-radius: var(--radius); box-shadow: var(--shadow); }
.filter-knopf { padding: 6px 16px; border-radius: var(--radius); border: 2px solid var(--color-eingabe-rand); background: transparent; color: var(--color-text-stark); font-family: inherit; font-size: var(--t-label); font-weight: 500; cursor: pointer; }
.filter-knopf.ist-aktiv, .filter-knopf[aria-pressed="true"] { background: var(--color-marine-flaeche); border-color: var(--color-marine-flaeche); color: var(--color-auf-marine); }
.filter-knopf:not(.ist-aktiv):not([aria-pressed="true"]):hover { background: var(--zustand-hover); }

/* ── Tabelle ──────────────────────────────────────── */
.tabelle-rahmen { overflow-x: auto; margin-bottom: 24px; }
.tabelle { width: 100%; border-collapse: separate; border-spacing: 0; font-size: var(--t-label); }
.tabelle thead th { background: var(--color-tabellenkopf); color: var(--color-auf-marine); font-weight: 600; padding: 10px 12px; text-align: right; white-space: nowrap; }
.tabelle thead th:first-child { text-align: left; border-radius: var(--radius) 0 0 0; }
.tabelle thead th:last-child { border-radius: 0 var(--radius) 0 0; }
.tabelle tbody td { padding: 10px 12px; text-align: right; white-space: nowrap; color: var(--color-text); border-bottom: 1px solid var(--color-border); }
.tabelle tbody td:first-child { text-align: left; font-weight: 500; color: var(--color-text-stark); }
.tabelle tbody tr:hover { background: var(--zustand-hover); }
.tabelle tr.hervorheben { background: var(--color-surface-alt); }
.tabelle tr.hervorheben td { font-weight: 600; color: var(--color-headings); }
.tabelle tr.unterzeile td { font-size: var(--t-klein); }
.tabelle tr.unterzeile td:first-child { padding-left: 28px; font-weight: 400; color: var(--color-text); }

/* ── Ergebnis ─────────────────────────────────────── */
.kennzahlen { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 24px; }
.kennzahl { background: var(--color-kennzahl-flaeche); border-radius: var(--radius); padding: 20px; text-align: center; }
.kennzahl-label { font-size: var(--t-label); font-weight: 500; color: var(--color-text); margin-bottom: 4px; }
.kennzahl-wert { font-size: var(--t-kennzahl); font-weight: 600; color: var(--color-headings); }
.kennzahl-wert.ist-positiv { color: var(--color-green-text); }
.kennzahl-wert.ist-negativ { color: var(--color-red-text); }
.kennzahl-unter { font-size: var(--t-klein); color: var(--color-text); margin-top: 4px; }

.buehne-banner { position: relative; overflow: hidden; margin-bottom: 24px; padding: 32px; text-align: center; border-radius: var(--radius); border: 1px solid var(--buehne-rand); background: linear-gradient(135deg, var(--buehne-flaeche) 0%, var(--buehne-karte) 100%); }
.buehne-banner::before { content: ''; position: absolute; top: 0; left: 50%; transform: translateX(-50%); width: 60px; height: 3px; background: var(--color-primary); }
.buehne-label { font-size: var(--t-text); color: var(--buehne-text-leise); margin-bottom: 4px; }
.buehne-name { font-size: 22px; font-weight: 600; color: var(--color-primary); margin-bottom: 12px; }
.buehne-betrag { font-size: var(--t-betrag); font-weight: 700; color: var(--buehne-gruen); line-height: 1.2; }
.buehne-unter { font-size: var(--t-label); color: var(--buehne-text); margin-top: 8px; }

.vorteil-karte { margin-bottom: 24px; padding: 24px; text-align: center; border-radius: var(--radius); border: 2px solid var(--color-green); background: var(--tint-erfolg); }
.vorteil-label { font-size: var(--t-text); color: var(--color-text-stark); margin-bottom: 8px; }
.vorteil-betrag { font-size: 32px; font-weight: 700; color: var(--color-green-text); margin-bottom: 4px; }
.vorteil-unter { font-size: var(--t-text); color: var(--color-text-stark); }

.diagramm { background: var(--color-surface); border-radius: var(--radius); box-shadow: var(--shadow); padding: 24px; margin-bottom: 24px; }
.diagramm-titel { font-weight: 600; font-size: 16px; color: var(--color-headings); margin-bottom: 16px; }
.diagramm-flaeche { position: relative; height: 320px; }

@media (max-width: 700px) {
  .kennzahlen { grid-template-columns: 1fr; }
  .buehne-betrag { font-size: 32px; }
}

/* ── Hinweise: heller Grundton, 3 px Kante links, Radius nur rechts ── */
.box { margin-top: 12px; padding: 10px 14px; font-size: var(--t-klein); line-height: 1.55; color: var(--color-text-stark); background: var(--box-grund); border-left: 3px solid var(--box-kante); border-radius: 0 6px 6px 0; }
.box-titel { display: block; font-weight: 600; margin-bottom: 2px; color: var(--box-titel); }
.box--info { --box-grund: var(--tint-info); --box-kante: var(--color-blue); --box-titel: var(--color-blue-text); }
.box--warnung { --box-grund: var(--tint-warnung); --box-kante: var(--color-red); --box-titel: var(--color-red-text); }
.box--erfolg { --box-grund: var(--tint-erfolg); --box-kante: var(--color-green); --box-titel: var(--color-green-text); }
.box--gold { --box-grund: var(--tint-gold); --box-kante: var(--color-primary); --box-titel: var(--color-text-stark); }

/* ── Erläuterung (?): immer ein <button type="button"> mit aria-label ── */
.tt {
  display: inline-flex; align-items: center; justify-content: center; position: relative;
  width: 15px; height: 15px; margin-left: 3px; vertical-align: middle; border-radius: 50%;
  background: var(--color-text); color: var(--color-surface);
  font-family: inherit; font-size: 10px; font-weight: 700; line-height: 1;
  border: 0; padding: 0; cursor: help; appearance: none; -webkit-appearance: none;
}
.tt:hover::after, .tt:focus-visible::after {
  content: attr(data-tip); position: absolute; bottom: calc(100% + 6px); left: 50%; transform: translateX(-50%); z-index: 20;
  width: max-content; max-width: min(240px, 80vw); padding: 6px 10px; border-radius: 6px;
  background: var(--buehne-flaeche); color: var(--buehne-text-stark); border: 1px solid var(--buehne-rand);
  font-size: var(--t-hinweis); font-weight: 400; line-height: 1.4; text-align: left; white-space: normal; pointer-events: none;
}
.tt--breit:hover::after, .tt--breit:focus-visible::after { max-width: min(380px, 80vw); }
.karte-kopf .tt { font-size: 10px; font-weight: 700; }

/* ── Sprungmarke: echtes <a>, Ziel leuchtet kurz auf (outline, damit der Kartenschatten bleibt) ── */
.sprung { color: var(--color-blue-text); text-decoration: underline; cursor: pointer; }
.sprung:hover { text-decoration: none; }
.sprung-aufleuchten { animation: sprung-aufleuchten 1.4s ease-out; }
@keyframes sprung-aufleuchten {
  0%, 15% { outline: 3px solid var(--color-primary); outline-offset: 2px; }
  100% { outline: 3px solid transparent; outline-offset: 2px; }
}
