:root {
  color-scheme: dark;
  --bg: #080b0f;
  --surface: #101722;
  --surface-strong: #15202d;
  --line: #263343;
  --line-strong: #33465c;
  --text: #f2f6fb;
  --muted: #a8b3c4;
  --muted-strong: #c8d1de;
  --accent: #39d98a;
  --accent-strong: #10b981;
  --accent-soft: rgba(57, 217, 138, 0.14);
  --warning: #f6bd60;
  --danger: #ff6b6b;
  --info: #74c0fc;
  --shadow: 0 24px 70px rgba(0, 0, 0, 0.34);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg);
}

body {
  min-height: 100vh;
  margin: 0;
  background:
    radial-gradient(circle at top left, rgba(57, 217, 138, 0.13), transparent 32rem),
    linear-gradient(135deg, #080b0f 0%, #0d131b 54%, #10151d 100%);
  color: var(--text);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  line-height: 1.5;
}

button,
input {
  font: inherit;
}

input[type="checkbox"] {
  accent-color: var(--accent);
}

button {
  cursor: pointer;
}

button:focus-visible,
input:focus-visible {
  outline: 3px solid rgba(116, 192, 252, 0.78);
  outline-offset: 3px;
}

.app-shell {
  width: min(100%, 760px);
  min-height: 100vh;
  margin: 0 auto;
  padding: 20px;
  display: flex;
  align-items: center;
}

.app-shell.is-result {
  width: min(100%, 980px);
  align-items: flex-start;
}

.panel {
  width: 100%;
  background: rgba(16, 23, 34, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: clamp(22px, 5vw, 42px);
}

.report-panel {
  margin: 18px 0;
}

.start-panel {
  position: relative;
  overflow: hidden;
}

.start-panel::after {
  content: "";
  position: absolute;
  inset: auto -20% -34% 42%;
  height: 220px;
  pointer-events: none;
  background: linear-gradient(135deg, rgba(57, 217, 138, 0.2), rgba(116, 192, 252, 0.08));
  transform: rotate(-8deg);
}

.start-panel > * {
  position: relative;
  z-index: 1;
}

.brand-header {
  margin-bottom: 24px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  text-align: center;
}

.brand-link {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  margin: 0 auto;
  color: var(--text);
  text-decoration: none;
}

.brand-name {
  font-size: clamp(1.55rem, 7vw, 2.45rem);
  font-weight: 900;
  line-height: 1;
  letter-spacing: 0;
}

.brand-subline {
  color: var(--info);
  font-size: 0.76rem;
  font-weight: 850;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.brand-link:hover .brand-name {
  color: var(--muted-strong);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 18px;
  color: var(--accent);
  font-size: 0.82rem;
  font-weight: 750;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 18px rgba(57, 217, 138, 0.72);
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 16px;
  font-size: clamp(2.05rem, 9vw, 4.4rem);
  line-height: 0.98;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 14px;
  font-size: clamp(1.65rem, 5vw, 2.8rem);
  line-height: 1.08;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 10px;
  font-size: 1.05rem;
  line-height: 1.25;
}

.lead {
  margin-bottom: 22px;
  color: var(--muted-strong);
  font-size: clamp(1rem, 2.6vw, 1.18rem);
}

.hint {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.bonus-hint {
  display: inline-flex;
  margin: 12px 0 0;
  padding: 8px 10px;
  color: #ffe0a6;
  font-size: 0.9rem;
  font-weight: 750;
  background: rgba(246, 189, 96, 0.1);
  border: 1px solid rgba(246, 189, 96, 0.24);
  border-radius: var(--radius);
}

.benefit-list {
  display: grid;
  gap: 10px;
  margin: 0 0 24px;
  padding: 0;
  list-style: none;
}

.benefit-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 40px;
  padding: 10px 12px;
  color: var(--muted-strong);
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
}

.benefit-list li::before {
  content: "";
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--accent);
}

.topbar {
  margin-bottom: 22px;
}

.progress-meta {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 0.9rem;
}

.question-text {
  margin-bottom: 18px;
}

.question-hint {
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 0.93rem;
}

.answer-list {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.answer-button {
  width: 100%;
  min-height: 64px;
  padding: 17px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: var(--text);
  text-align: left;
  background: linear-gradient(180deg, #101823, #0b1119);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.035);
  transition:
    border-color 160ms ease,
    background 160ms ease,
    transform 160ms ease;
}

.answer-button:hover,
.answer-button[aria-pressed="true"] {
  background: linear-gradient(180deg, #172332, #111a26);
  border-color: var(--accent);
}

.answer-button:hover {
  transform: translateY(-1px);
}

.answer-button::after {
  content: "";
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  border: 2px solid var(--line-strong);
  border-radius: 50%;
}

.answer-button[aria-pressed="true"]::after {
  border-color: var(--accent);
  background: radial-gradient(circle, var(--accent) 0 40%, transparent 45%);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

.button {
  min-height: 52px;
  padding: 14px 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #06110d;
  font-weight: 800;
  text-decoration: none;
  background: var(--accent);
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  transition:
    transform 160ms ease,
    background 160ms ease,
    border-color 160ms ease;
}

.button:hover {
  transform: translateY(-1px);
  background: #51e69e;
  border-color: #51e69e;
}

.button.secondary {
  color: var(--text);
  background: transparent;
  border-color: var(--line-strong);
}

.button.secondary:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--muted);
}

.quiz-panel .actions {
  align-items: center;
}

.quiz-panel .button.secondary {
  min-height: 44px;
  padding: 11px 14px;
  color: var(--muted-strong);
  font-weight: 750;
}

.button.full {
  width: 100%;
}

.button:disabled {
  cursor: not-allowed;
  opacity: 0.52;
  transform: none;
}

.report-topline {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}

.report-topline .eyebrow {
  margin-bottom: 0;
}

.report-meta,
.section-kicker,
.summary-label {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.result-card {
  display: grid;
  gap: 22px;
  margin-bottom: 24px;
  padding: clamp(20px, 4vw, 34px);
  background:
    linear-gradient(135deg, rgba(57, 217, 138, 0.14), rgba(116, 192, 252, 0.07)),
    #0b1118;
  border: 1px solid rgba(57, 217, 138, 0.34);
  border-radius: var(--radius);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.result-label {
  color: var(--accent);
}

.result-subline {
  margin-bottom: 0;
  color: var(--muted-strong);
  font-weight: 750;
}

.result-summary {
  display: grid;
  gap: 10px;
}

.summary-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 12px;
  background: rgba(8, 11, 15, 0.56);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
}

.summary-item strong {
  text-align: right;
}

.report-section {
  margin-top: 24px;
}

.report-copy {
  padding: 18px;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: var(--radius);
}

.report-copy p:last-child {
  margin-bottom: 0;
}

.legend-list {
  display: grid;
  gap: 10px;
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
}

.legend-list li {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  align-items: start;
  color: var(--muted-strong);
  font-size: 0.94rem;
}

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  margin-bottom: 12px;
}

.section-heading h3 {
  margin-bottom: 0;
}

.insight-box {
  margin: 12px 0;
  padding: 16px;
  background: rgba(116, 192, 252, 0.09);
  border: 1px solid rgba(116, 192, 252, 0.32);
  border-radius: var(--radius);
  color: var(--muted-strong);
}

.warning-box {
  margin: 12px 0;
  padding: 16px;
  background: rgba(255, 107, 107, 0.1);
  border: 1px solid rgba(255, 107, 107, 0.36);
  border-radius: var(--radius);
  color: #ffd4d4;
}

.result-grid {
  display: grid;
  gap: 14px;
  margin: 0;
}

.metric {
  padding: 14px;
  background: #0c121a;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.metric-main {
  background: var(--accent-soft);
  border-color: rgba(57, 217, 138, 0.5);
  box-shadow: inset 3px 0 0 var(--accent);
}

.metric-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.metric-name {
  font-weight: 800;
}

.badge {
  flex: 0 0 auto;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 0.76rem;
  font-weight: 850;
  text-transform: uppercase;
}

.badge.stabil {
  color: #bff7dc;
  background: rgba(57, 217, 138, 0.13);
}

.badge.auffaellig {
  color: #ffe0a6;
  background: rgba(246, 189, 96, 0.15);
}

.badge.kritisch {
  color: #ffd4d4;
  background: rgba(255, 107, 107, 0.16);
}

.progress-native,
.score-native {
  width: 100%;
  height: 8px;
  appearance: none;
  -webkit-appearance: none;
  border: 0;
  border-radius: 999px;
  background: #05070a;
}

.progress-native {
  height: 9px;
  border: 1px solid var(--line);
}

.progress-native::-webkit-progress-bar,
.score-native::-webkit-progress-bar {
  background: #05070a;
  border-radius: 999px;
}

.progress-native::-webkit-progress-value {
  background: linear-gradient(90deg, var(--accent), var(--info));
  border-radius: 999px;
}

.progress-native::-moz-progress-bar {
  background: linear-gradient(90deg, var(--accent), var(--info));
  border-radius: 999px;
}

.score-native::-webkit-progress-value {
  background: linear-gradient(90deg, var(--accent), var(--warning), var(--danger));
  border-radius: 999px;
}

.score-native::-moz-progress-bar {
  background: linear-gradient(90deg, var(--accent), var(--warning), var(--danger));
  border-radius: 999px;
}

.score-row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 12px;
}

.score-value {
  color: var(--muted);
  font-size: 0.88rem;
  white-space: nowrap;
}

.advice-grid {
  display: grid;
  gap: 14px;
}

.advice-card {
  padding: 16px;
  background: #0c121a;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.warning-advice {
  border-color: rgba(255, 107, 107, 0.3);
}

.advice-card p:last-child {
  margin-bottom: 0;
}

.next-step {
  padding: 18px;
  background: rgba(57, 217, 138, 0.1);
  border: 1px solid rgba(57, 217, 138, 0.34);
  border-radius: var(--radius);
}

.next-step p:last-child {
  margin-bottom: 0;
}

.discount-panel {
  display: grid;
  gap: 16px;
  margin-top: 24px;
  padding: clamp(18px, 4vw, 26px);
  background:
    linear-gradient(135deg, rgba(246, 189, 96, 0.16), rgba(57, 217, 138, 0.08)),
    #0b1118;
  border: 1px solid rgba(246, 189, 96, 0.46);
  border-radius: var(--radius);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.discount-panel h3 {
  margin-bottom: 8px;
  font-size: clamp(1.18rem, 4vw, 1.55rem);
}

.discount-panel p {
  margin-bottom: 0;
  color: var(--muted-strong);
}

.discount-code-wrap {
  display: grid;
  gap: 6px;
  align-content: center;
  justify-items: center;
  padding: 16px;
  background: rgba(8, 11, 15, 0.72);
  border: 1px dashed rgba(246, 189, 96, 0.72);
  border-radius: var(--radius);
  text-align: center;
}

.discount-label,
.discount-note {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.discount-code {
  color: var(--warning);
  font-size: clamp(1.85rem, 9vw, 2.8rem);
  line-height: 1;
  letter-spacing: 0.08em;
}

.cta-panel {
  display: grid;
  gap: 18px;
  margin-top: 24px;
  padding: 18px;
  background: #080d13;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
}

.cta-panel p:last-child {
  margin-bottom: 0;
}

.cta-actions {
  margin-top: 0;
}

.email-block {
  margin-top: 24px;
  padding: 18px;
  background: rgba(116, 192, 252, 0.06);
  border: 1px solid rgba(116, 192, 252, 0.2);
  border-radius: var(--radius);
}

.form-row {
  display: grid;
  gap: 10px;
}

.input-label {
  color: var(--muted-strong);
  font-weight: 700;
}

.email-input {
  min-height: 52px;
  width: 100%;
  padding: 13px 14px;
  color: var(--text);
  background: #070a0f;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
}

.checkbox-row {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  align-items: start;
  margin-top: 14px;
  color: var(--muted-strong);
  font-size: 0.94rem;
}

.checkbox-row input {
  width: 18px;
  height: 18px;
  margin-top: 2px;
}

.privacy-note {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 0.88rem;
}

.privacy-note a {
  color: var(--muted-strong);
  font-weight: 800;
}

.form-message {
  min-height: 24px;
  margin: 10px 0 0;
  color: var(--accent);
  font-weight: 700;
}

.form-message.error {
  color: var(--danger);
}

.screen-footer {
  margin-top: 18px;
  color: var(--muted);
  font-size: 0.86rem;
}

.legal-footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 10px 18px;
  margin-top: 28px;
  padding: 14px 0 0;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--muted);
  font-size: 0.8rem;
}

.legal-footer p {
  margin: 0;
}

.legal-footer a {
  color: var(--muted-strong);
  font-weight: 700;
  text-decoration: none;
  transition: color 160ms ease;
}

.legal-footer a:hover {
  color: var(--text);
  text-decoration: underline;
}

.legal-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
}

.legal-links a {
  color: var(--muted);
}

@media (min-width: 700px) {
  .app-shell {
    padding: 34px;
  }

  .panel {
    padding: 46px;
  }

  .actions .button:not(.full) {
    width: auto;
  }

  .benefit-list {
    grid-template-columns: 1fr 1fr;
  }

  .advice-grid {
    grid-template-columns: 1fr 1fr;
  }

  .result-card,
  .cta-panel,
  .discount-panel {
    grid-template-columns: minmax(0, 1fr) 280px;
    align-items: stretch;
  }

  .result-grid {
    grid-template-columns: 1fr 1fr;
  }

  .answer-button {
    min-height: 68px;
  }

  .form-row {
    grid-template-columns: 1fr auto;
    align-items: end;
  }
}

@media (max-width: 520px) {
  .app-shell {
    align-items: stretch;
    padding: 12px;
  }

  .panel {
    min-height: calc(100vh - 24px);
    display: flex;
    flex-direction: column;
    justify-content: center;
  }

  .report-panel {
    justify-content: flex-start;
  }

  .actions,
  .button {
    width: 100%;
  }

  .quiz-panel .button.secondary {
    width: auto;
  }
}
