/* KI-Reifegrad-Check · gleiches Erscheinungsbild wie www.humainize.de
   Farben, Schriften und Rundungen aus humainize/app/(site)/globals.css übernommen. */

@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal;
  font-weight: 300 500;
  font-display: swap;
  src: url("fonts/cormorant-garamond-latin.woff2") format("woff2");
}
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url("fonts/archivo-latin.woff2") format("woff2");
}

:root {
  --teal: #507474;
  --teal-light: #69a49d;
  --teal-dark: #3f5e5e;
  --sand: #e8e5db;
  --grey: #bfbfbf;
  --black: #000;
  --white: #fff;
  --muted: rgba(0, 0, 0, 0.66);
  --line: rgba(0, 0, 0, 0.12);
  --error: #8a3b2e;

  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-text: "Archivo", system-ui, sans-serif;

  /* Kritisch gedämpft: schnelles Ankommen ohne Überschwingen */
  --ease-out: cubic-bezier(0.2, 0, 0, 1);
  --radius-sm: 6px;
  --radius-lg: 16px;
  --shadow-card: 0 1px 0 rgba(0, 0, 0, 0.04), 0 24px 60px -28px rgba(0, 0, 0, 0.55);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  font-family: var(--font-text);
  font-size: 1rem;
  line-height: 1.625;
  color: var(--black);
  background: var(--teal-dark);
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }
a { color: var(--teal-dark); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: var(--black); }
:focus-visible { outline: 2px solid var(--teal); outline-offset: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ── Kopf und Fuß wie auf der Website ───────────────────────── */
.kopf {
  background: var(--white);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.08);
}
.kopf-inner {
  max-width: 1120px; margin: 0 auto; padding: 0 16px;
  height: 84px; display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.kopf img { height: 68px; width: auto; }
.kopf nav a {
  font-size: 0.875rem; font-weight: 500; line-height: 1.25rem; text-decoration: none; color: var(--black);
  border-bottom: 2px solid transparent; padding-bottom: 4px;
}
.kopf nav a:hover { border-color: var(--teal); color: var(--teal-dark); }
@media (min-width: 1024px) { .kopf-inner, .fuss-inner { padding-left: 32px; padding-right: 32px; } .kopf-inner { height: 112px; } .kopf img { height: 92px; } }

.fuss {
  background: var(--white); border-top: 2px solid var(--black);
  font-size: 0.8125rem; line-height: 1.6; color: var(--muted);
}
.fuss-inner {
  max-width: 1120px; margin: 0 auto; padding: 22px 16px;
  display: flex; flex-wrap: wrap; gap: 6px 24px; justify-content: space-between;
}
.fuss a { color: var(--black); text-decoration: none; }
.fuss a:hover { color: var(--teal); }
.fuss nav { display: flex; gap: 20px; }

/* ── Bühne: dunkles Teal mit Linienraster ───────────────────── */
.buehne {
  flex: 1;
  background-color: var(--teal-dark);
  background-image:
    linear-gradient(to right, rgba(105, 164, 157, 0.14) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(105, 164, 157, 0.14) 1px, transparent 1px);
  background-size: 56px 56px;
  background-position: center top;
  color: var(--white);
  padding: 40px 16px 72px;
}
@media (min-width: 768px) { .buehne { padding: 64px 24px 96px; } }
.wrap { max-width: 640px; margin: 0 auto; }

/* ── Typografie ─────────────────────────────────────────────── */
.label {
  font-family: var(--font-text);
  font-size: 0.6875rem; line-height: 1.45; font-weight: 600;
  letter-spacing: 0.18em; text-transform: uppercase;
}
h1, h2, h3, .serif { font-family: var(--font-display); }
h1 {
  font-size: clamp(2.5rem, 6vw, 3.5rem); line-height: 1.08; font-weight: 300;
  letter-spacing: -0.02em; text-wrap: balance;
}
h2 { font-size: clamp(1.75rem, 4vw, 2.125rem); line-height: 1.14; font-weight: 400; letter-spacing: -0.012em; text-wrap: balance; }
h3 { font-size: 1.5rem; line-height: 1.2; font-weight: 500; letter-spacing: -0.005em; }
p + p { margin-top: 14px; }
.lead { font-size: 1.125rem; line-height: 1.56; }
.muted { color: var(--muted); }
.klein { font-size: 0.875rem; line-height: 1.55; }

/* Einleitung direkt auf der Bühne */
.intro { display: flex; flex-direction: column; gap: 18px; margin-bottom: 32px; }
.intro .label { color: rgba(255, 255, 255, 0.9); }
.intro .lead { color: rgba(255, 255, 255, 0.86); max-width: 46ch; }
.intro ul { list-style: none; display: grid; gap: 8px; margin-top: 4px; }
.intro li { position: relative; padding-left: 22px; color: rgba(255, 255, 255, 0.92); }
.intro li::before {
  content: ""; position: absolute; left: 0; top: 0.62em; width: 10px; height: 2px; background: var(--teal-light);
}

/* ── Karte ──────────────────────────────────────────────────── */
.card {
  background: var(--white); color: var(--black);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: 32px 28px;
}
.card + .card { margin-top: 20px; }
@media (max-width: 520px) { .card { padding: 24px 18px; } }
.card .label { color: var(--teal); margin-bottom: 10px; }
.card h2 + p, .card h3 + p { margin-top: 12px; }

/* ── Buttons ────────────────────────────────────────────────── */
.btn {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; min-height: 48px; margin-top: 20px; padding: 12px 22px;
  font: 600 0.9375rem/1.25rem var(--font-text);
  text-align: center; text-decoration: none; cursor: pointer;
  border-radius: var(--radius-sm); border: 2px solid transparent;
  background: var(--teal); color: var(--white);
  user-select: none; -webkit-tap-highlight-color: transparent;
  transition: background-color 160ms var(--ease-out), color 160ms var(--ease-out),
    border-color 160ms var(--ease-out), transform 100ms var(--ease-out), opacity 160ms var(--ease-out);
}
.btn:hover { background: var(--teal-light); color: var(--white); }
.btn:active:not(:disabled) { background: var(--teal-dark); transform: scale(0.97); }
.btn:disabled { opacity: 0.38; cursor: not-allowed; }
.btn.hell { background: var(--white); color: var(--teal); border-color: var(--white); }
.btn.hell:hover { background: var(--sand); border-color: var(--sand); color: var(--teal-dark); }
.btn.linie { background: var(--white); color: var(--teal); border-color: var(--teal); }
.btn.linie:hover { background: var(--teal); color: var(--white); }
.btnRow { display: flex; gap: 10px; margin-top: 20px; }
.btnRow .btn { margin-top: 0; }
@media (max-width: 520px) { .btnRow { flex-direction: column; } }

.backLink {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px; margin-top: 8px;
  background: none; border: none; cursor: pointer;
  font: 500 0.875rem/1.25rem var(--font-text); color: var(--muted);
  transition: color 160ms var(--ease-out);
}
.backLink:hover { color: var(--black); }

/* ── Fortschritt ────────────────────────────────────────────── */
.progressWrap { margin-bottom: 28px; }
.progressMeta {
  display: flex; justify-content: space-between; gap: 12px; align-items: baseline;
  font-size: 0.8125rem; color: var(--muted); margin-bottom: 10px;
}
.progressMeta > span { white-space: nowrap; }
.progressMeta .label { color: var(--teal); margin: 0; }
.progressTrack { display: flex; gap: 4px; }
.progressStep { position: relative; flex: 1; height: 4px; border-radius: 2px; background: var(--line); overflow: hidden; }
.progressStep::after {
  content: ""; position: absolute; inset: 0; background: var(--teal);
  transform: scaleX(0); transform-origin: left;
  transition: transform 420ms var(--ease-out);
}
.progressStep.done::after { transform: scaleX(1); }
.progressStep.now::after { transform: scaleX(0.5); background: var(--teal-light); }

/* ── Fragen und Antworten ───────────────────────────────────── */
.qBlock + .qBlock { margin-top: 30px; padding-top: 26px; border-top: 1px solid var(--line); }
.qText { font-family: var(--font-display); font-size: 1.5rem; line-height: 1.22; font-weight: 500; letter-spacing: -0.005em; margin-bottom: 14px; }
.opts { display: grid; gap: 8px; }
.opt {
  position: relative; display: block; width: 100%; text-align: left; cursor: pointer;
  padding: 12px 14px 12px 46px; min-height: 48px;
  font: 400 0.9375rem/1.4 var(--font-text); color: var(--black);
  background: var(--white); border: 2px solid var(--line); border-radius: var(--radius-sm);
  -webkit-tap-highlight-color: transparent;
  transition: border-color 160ms var(--ease-out), background-color 160ms var(--ease-out), transform 100ms var(--ease-out);
}
.opt:hover { border-color: var(--teal-light); }
/* Rückmeldung schon beim Drücken, nicht erst beim Loslassen */
.opt:active { transform: scale(0.985); background: #f6f5f0; }
.opt .dot {
  position: absolute; left: 14px; top: 50%; width: 20px; height: 20px; margin-top: -10px;
  border-radius: 50%; border: 2px solid var(--grey); background: var(--white);
  transition: border-color 160ms var(--ease-out), box-shadow 220ms var(--ease-out);
}
.opt.sel { border-color: var(--teal); background: rgba(80, 116, 116, 0.07); }
.opt.sel .dot { border-color: var(--teal); box-shadow: inset 0 0 0 4px var(--white), inset 0 0 0 10px var(--teal); }

/* ── Formular ───────────────────────────────────────────────── */
label.fl { display: block; font-size: 0.875rem; font-weight: 500; margin: 18px 0 6px; }
label.fl .opt-hint { font-weight: 400; color: var(--muted); }
select, input[type=text], input[type=email] {
  width: 100%; min-height: 48px; padding: 11px 14px;
  font: 400 1rem/1.4 var(--font-text); color: var(--black);
  background: var(--white); border: 2px solid var(--line); border-radius: var(--radius-sm);
  transition: border-color 160ms var(--ease-out);
  -webkit-appearance: none; appearance: none;
}
select {
  padding-right: 40px; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%23000' stroke-width='1.6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
}
select:hover, input:hover { border-color: var(--grey); }
select:focus, input:focus { outline: none; border-color: var(--teal); }
.cbRow { display: flex; gap: 12px; align-items: flex-start; margin-top: 16px; font-size: 0.875rem; line-height: 1.5; }
.cbRow input { flex: none; width: 20px; height: 20px; margin-top: 1px; accent-color: var(--teal); cursor: pointer; }
.cbRow label { cursor: pointer; }
.req { color: var(--teal-dark); font-weight: 600; }
.hint { font-size: 0.8125rem; color: var(--muted); margin-top: 16px; line-height: 1.5; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ── Hinweise ───────────────────────────────────────────────── */
.dsBox { margin-top: 22px; padding: 16px 18px; border-radius: var(--radius-sm); background: #f4f3ee; }
.dsBox > p { font-size: 0.8125rem; line-height: 1.6; color: var(--muted); }
.dsBox > p + p { margin-top: 8px; }
.dsBox strong { color: var(--black); }
.intro + .dsBox, .dsBox.dunkel { background: rgba(255, 255, 255, 0.08); }
.dsBox.dunkel > p { color: rgba(255, 255, 255, 0.82); }
.dsBox.dunkel strong { color: var(--white); }
.dsBox.dunkel a { color: var(--white); }
details.ds { margin-top: 12px; }
details.ds > summary {
  cursor: pointer; list-style: none; display: inline-flex; align-items: center; gap: 8px; min-height: 32px;
  font-size: 0.8125rem; font-weight: 500; color: var(--teal-dark);
}
details.ds > summary::-webkit-details-marker { display: none; }
details.ds > summary::before {
  content: ""; width: 8px; height: 8px; border-right: 1.6px solid currentColor; border-bottom: 1.6px solid currentColor;
  transform: rotate(-45deg); transition: transform 220ms var(--ease-out);
}
details.ds[open] > summary::before { transform: rotate(45deg); }
.dsBody { font-size: 0.8125rem; line-height: 1.6; color: var(--muted); margin-top: 8px; }
.dsBody dt { font-weight: 600; color: var(--black); margin-top: 10px; }
.dsBody dd { margin: 2px 0 0; }

.note {
  margin: 22px 0; padding: 14px 16px; border-left: 3px solid var(--teal-light);
  background: #f4f3ee; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; font-size: 0.9375rem; line-height: 1.55;
}
.fehler {
  margin-top: 16px; padding: 14px 16px; border-left: 3px solid var(--error);
  background: #f7efec; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; font-size: 0.9375rem; line-height: 1.55;
}
.schritte { counter-reset: s; list-style: none; margin: 18px 0; display: grid; gap: 14px; }
.schritte li { counter-increment: s; position: relative; padding-left: 40px; font-size: 0.9375rem; }
.schritte li::before {
  content: counter(s); position: absolute; left: 0; top: -1px; width: 26px; height: 26px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  border: 1.5px solid var(--teal); color: var(--teal-dark); font-family: var(--font-display); font-size: 1rem;
}
ul.plain { list-style: none; display: grid; gap: 8px; margin-top: 10px; }
ul.plain li { position: relative; padding-left: 22px; font-size: 0.9375rem; }
ul.plain li::before { content: ""; position: absolute; left: 0; top: 0.68em; width: 10px; height: 2px; background: var(--teal-light); }
.sec { border-top: 1px solid var(--line); margin-top: 26px; padding-top: 22px; }

/* ── Ergebnis ───────────────────────────────────────────────── */
.scoreBox { text-align: center; padding-bottom: 26px; margin-bottom: 24px; border-bottom: 1px solid var(--line); }
.scoreBox .label { margin-bottom: 8px; }
.stufeName { font-size: clamp(1.75rem, 5vw, 2.25rem); line-height: 1.12; font-weight: 400; letter-spacing: -0.012em; margin: 4px 0 10px; text-wrap: balance; }
.scoreNum { font-family: var(--font-display); font-weight: 300; font-size: 4rem; line-height: 1; letter-spacing: -0.02em; color: var(--teal); font-variant-numeric: lining-nums tabular-nums; }
.scoreNum span { font-size: 1.25rem; color: var(--muted); letter-spacing: 0; }
.stufenLeiter { display: flex; gap: 4px; justify-content: center; margin: 14px auto 0; max-width: 220px; }
.stufenLeiter i { flex: 1; height: 4px; border-radius: 2px; background: var(--line); }
.stufenLeiter i.on { background: var(--teal); }

.barRow { padding: 10px 12px; border-radius: var(--radius-sm); }
.barRow + .barRow { margin-top: 4px; }
.barRow.hebel { background: rgba(80, 116, 116, 0.08); }
.barHead { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; font-size: 0.875rem; margin-bottom: 7px; }
.barHead .nm { font-weight: 500; }
.barHead .pc { color: var(--muted); font-variant-numeric: tabular-nums; }
.segs { display: flex; gap: 3px; }
.seg { flex: 1; height: 10px; border-radius: 2px; background: var(--line); }
.seg.on { background: var(--teal); }
.chip {
  display: inline-block; margin-left: 8px; padding: 2px 8px; border-radius: 999px; vertical-align: 1px;
  font-size: 0.6875rem; font-weight: 600; letter-spacing: 0.02em; background: var(--teal); color: var(--white);
}
.hebelBox { border-top: 1px solid var(--line); margin-top: 22px; padding-top: 22px; }
.hebelTitel { font-family: var(--font-display); font-size: 1.625rem; line-height: 1.16; font-weight: 500; margin-bottom: 10px; }
.bereich + .bereich { margin-top: 20px; }
.bereich .kopfzeile { display: flex; justify-content: space-between; gap: 10px; font-size: 1rem; margin-bottom: 4px; }
.bereich .kopfzeile span { color: var(--muted); font-size: 0.875rem; font-variant-numeric: tabular-nums; }
.bereich p, .pot { font-size: 0.9375rem; }
.pot + .pot { margin-top: 16px; }

/* Ausblick: Platzhalter-Balken, bewusst nicht die echten Werte */
.teaser { position: relative; }
.teaser .fake { filter: blur(5px); opacity: 0.7; user-select: none; pointer-events: none; }
.lock { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; padding: 12px; }
.lock span {
  max-width: 320px; padding: 12px 16px; text-align: center; font-size: 0.875rem; line-height: 1.5;
  background: var(--white); border-radius: var(--radius-sm); box-shadow: 0 10px 30px -12px rgba(0, 0, 0, 0.35);
}

/* Bestätigt: Haken */
.haken { width: 44px; height: 44px; border-radius: 50%; background: var(--teal); display: flex; align-items: center; justify-content: center; margin-bottom: 20px; }
.haken svg { width: 20px; height: 20px; }

/* ── Bewegung reduzieren ────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0.01ms !important; }
  .btn:active:not(:disabled), .opt:active { transform: none; }
}
@media (prefers-contrast: more) {
  .opt, select, input[type=text], input[type=email] { border-color: var(--black); }
  .muted, .dsBox > p, .dsBody { color: var(--black); }
}
