* { box-sizing: border-box; margin: 0; padding: 0; }

html, body { height: 100%; width: 100%; overflow-y: scroll; scrollbar-gutter: stable; }

.test-wrapper {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: linear-gradient(rgba(255, 250, 245, 0.7), rgba(255, 250, 245, 0.7)), url('./flex-how-bg.png');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  color: #2D2D2D;
  min-height: 100%;
  width: 100%;
  height: auto;
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 5px;
}

.test-container {
  max-width: 900px;
  width: 100%;
  margin: 0 auto;
  padding: 37px 40px;
  position: relative;
  z-index: 1;
  background: #FFFFFF;
  border-radius: 20px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  height: auto;
  backdrop-filter: none;
}

@media (max-width: 480px) {
  .test-container { padding: 25px 20px; }
}

.heading-font {
  font-family: 'Segoe UI', sans-serif;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.progress-track {
  height: 4px;
  background: #E8E8E8;
  border-radius: 99px;
  overflow: hidden;
  position: relative;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #EE71B7, #1DAF8B);
  border-radius: 99px;
  transition: width 0.6s cubic-bezier(0.22, 1, 0.36, 1);
  position: relative;
}

.progress-fill::after {
  content: '';
  position: absolute;
  right: 0;
  top: -3px;
  width: 10px;
  height: 10px;
  background: #EE71B7;
  border-radius: 50%;
  box-shadow: 0 0 12px rgba(238, 113, 183, 0.4);
  transition: opacity 0.3s;
  display: none;
}

@keyframes slideIn {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes slideOut {
  from { opacity: 1; transform: translateY(0); }
  to { opacity: 0; transform: translateY(-16px); }
}

.slide {
  opacity: 0;
  transform: translateY(16px);
  pointer-events: none;
  position: relative;
  z-index: 0;
}

.slide.active {
  animation: slideIn 0.5s ease-out forwards;
  pointer-events: auto;
  z-index: 1;
}

.slide.exit-up {
  animation: slideOut 0.4s ease-out forwards;
}

/* =========================================================
   OPTION CARD – Basis
========================================================= */
.option-card {
  background: #FFFFFF;
  border: 1.5px solid #E0E0E0;
  border-radius: 12px;
  padding: 14px 16px;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  -webkit-tap-highlight-color: transparent;

  /* Wahrnehmung bewusst verlangsamt */
  transition:
    background-color 0.35s cubic-bezier(0.22, 1, 0.36, 1),
    border-color     0.35s cubic-bezier(0.22, 1, 0.36, 1),
    transform        0.25s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow       0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

/* =========================================================
   DESKTOP: Hover
========================================================= */
.option-card:hover {
  border-color: #EE71B7;
  background: #FEF9F4;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(238,113,183,0.08);
}

/* =========================================================
   SELECTED (Desktop + Mobile)
========================================================= */
.option-card.selected {
  border-color: #EE71B7;
  background: #F9F3ED;
}

/* =========================================================
   CHECK ICON – Basis
========================================================= */
.option-check {
  width: 22px;
  height: 22px;
  min-width: 22px;
  min-height: 22px;
  border-radius: 50%;
  border: 2px solid #D0D0D0;
  background: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;

  transition:
    background-color 0.35s cubic-bezier(0.22, 1, 0.36, 1),
    border-color     0.35s cubic-bezier(0.22, 1, 0.36, 1),
    transform        0.25s cubic-bezier(0.22, 1, 0.36, 1);
}

/* Desktop Hover auf Icon */
.option-card:hover .option-check {
  border-color: #EE71B7;
}

/* Selected Icon */
.option-card.selected .option-check {
  border-color: #EE71B7;
  background: #EE71B7;
}

/* =========================================================
   CHECK SVG
========================================================= */
.option-check svg {
  width: 12px;
  height: 12px;
  stroke: #FFFFFF;
  opacity: 0;

  transition:
    opacity   0.35s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.25s cubic-bezier(0.22, 1, 0.36, 1);
}

/* Selected SVG */
.option-card.selected .option-check svg {
  opacity: 1;
}

/* =========================================================
   MOBILE: Hover optisch neutralisieren
   (Hover = Non-Active)
========================================================= */
@media (hover: none) and (pointer: coarse) {

  .option-card:hover {
    background: #FFFFFF;
    border-color: #E0E0E0;
    box-shadow: none;
    transform: none;
  }

  .option-card:hover .option-check {
    border-color: #D0D0D0;
    background: #FFFFFF;
  }

  /* =====================================
     MOBILE: aktives Touch-Feedback
  ===================================== */
  .option-card:active {
    background-color: rgba(238,113,183,0.12);
    border-color: #EE71B7;
    transform: scale(0.97);
  }

  .option-card:active .option-check {
    background: #EE71B7;
    border-color: #EE71B7;
    transform: scale(1.05);
  }

  .option-card:active .option-check svg {
    opacity: 1;
    transform: scale(1.1);
  }
}

input[type="checkbox"] { cursor: pointer; border-radius: 4px !important; }

.multiple-choice-note {
  font-size: 12px;
  opacity: 0.6;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #EE71B7;
  margin-bottom: 14px;
  display: inline-block;
}

.button-group {
  margin-top: 28px;
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
}

.next-button { flex: 1; width: 100%; }

.button-group.multiple-choice { justify-content: space-between; }

.button-group.multiple-choice .back-button { order: -1; }

.button-group.multiple-choice .next-button { flex: 0 0 auto; width: auto; }

.back-button {
  background: transparent;
  color: #EE71B7;
  border: 1.5px solid #E0E0E0;
  border-radius: 8px;
  padding: 10px 12px;
    margin-top: 15px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  position: relative;
  overflow: hidden;
  -webkit-tap-highlight-color: transparent;
  font-family: 'Segoe UI', sans-serif;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex-shrink: 0;
  min-width: fit-content;
}

.back-button:hover {
  border-color: #EE71B7;
  background: #FEF9F4;
  box-shadow: 0 2px 8px rgba(238, 113, 183, 0.08);
}

.back-button:active { transform: translateY(0); }

.back-button:disabled {
  opacity: 0.3;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
  border-color: #E0E0E0;
}

@media (max-width: 480px) {
  .back-button { padding: 9px 10px; font-size: 12px; gap: 4px; }
  .back-button i { width: 16px !important; height: 16px !important; }
  .button-group { gap: 10px; }
}
.cta-btn {
  background: linear-gradient(135deg, #EE71B7, #1DAF8B);
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 14px 28px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  position: relative;
  overflow: hidden;
  -webkit-tap-highlight-color: transparent;
  font-family: 'Segoe UI', sans-serif;

  /* ✅ FIX: Icon & Text IMMER korrekt ausrichten */
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  line-height: 1;
}

/* Feinschliff für SVG / Lucide Icons */
.cta-btn i {
  display: inline-flex;
  align-items: center;
}

/* Mobile Anpassungen */
@media (max-width: 480px) {
  .cta-btn {
    padding: 10px 16px;
    font-size: 13px;
    gap: 6px;
    white-space: normal;
    line-height: 1.2;
  }

  #introSlide .cta-btn {
    padding: 10px 14px;
    font-size: 12px;
    line-height: 1.2;
  }

  #introSlide .cta-btn span {
    display: inline;
  }
}

.cta-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(238, 113, 183, 0.25);
}

.cta-btn:active {
  transform: translateY(0);
}

.cta-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}
.gauge-ring {
  stroke-dasharray: 283;
  stroke-dashoffset: 283;
  transition: stroke-dashoffset 1.5s cubic-bezier(0.22, 1, 0.36, 1);
  transform: rotate(-90deg);
  transform-origin: 50% 50%;
}

.stagger {
  opacity: 0;
  animation: groupFadeIn 0.4s ease-out 0.1s forwards;
}

@keyframes groupFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes pulseGlow {
  0%, 100% { box-shadow: 0 0 20px rgba(238, 113, 183, 0.15); }
  50% { box-shadow: 0 0 40px rgba(238, 113, 183, 0.25); }
}

.result-card {
  background: #F9F7F9;
  border: 1px solid #E8E0EC;
  border-radius: 12px;
  padding: 20px;
}

@media (max-width: 480px) { .result-card { padding: 16px; } }

.tag {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 99px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.intro-subtitle {
  font-size: 18px;
  font-weight: 500;
  opacity: 0.75;
  margin-bottom: 24px;
  line-height: 1.5;
}

@media (max-width: 480px) {
  .intro-subtitle { font-size: 16px; margin-bottom: 20px; }
}

.options-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.list-item {
  font-size: 14px;
  line-height: 1.6;
  opacity: 0.8;
  color: #2D2D2D;
  margin-bottom: 12px;
  padding-left: 24px;
  position: relative;
}

@media (max-width: 480px) {
  .list-item { font-size: 13px; margin-bottom: 10px; }
}
/* =========================================================
   QUIZ-FRAGEN
========================================================= */
#chapterHeaderText {
  color: #775190 !important;
}

.question-heading {
  font-size: 16.5px;
  font-weight: 700;
  line-height: 1.35;
  color: #432544; /* dunkler Lilaton der Kapitel */
  margin-bottom: 20px;
}

@media (max-width: 480px) {
  .question-heading {
    font-size: 15px;
  }
}


/* Logo: 20px mehr Abstand vom Rand */
img[src$="flex-how-logo.jpg"] {
  margin-left: 20px;
}
/* =========================================
   Mobile Header Layout (sauber & korrekt)
========================================= */
@media (max-width: 600px) {

  /* Header darf umbrechen */
  .quiz-header {
    flex-wrap: wrap;
  }

  /* Titel unter Logo ziehen */
  .quiz-header .heading-font {
    flex-basis: 100%;
    order: 2;
    text-align: left;
    margin-left: 25px;
    margin-top: -40px;   /* ✅ bewusstes Overlay */
    font-size: 15px;
    line-height: 1.2;
  }

  /* Extra-Bild mobil etwas kleiner */
  .quiz-header img[src$=".png"] {
    width: 80px !important;     /* überschreibt Inline-Style */
    height: auto !important;
    flex-shrink: 0;
    margin-left: auto;
  }
}

/* =========================================
   Mobile Außenabstände der Container
========================================= */
@media (max-width: 600px) {

  .quiz-header {
    margin: 20px 8px 5px !important;
    width: auto !important;
  }

  .test-container {
    margin: 5px 8px 20px;
    width: auto;
  }
}

/* =========================================
   Horizontaler Overflow Fix
========================================= */
html, body {
  overflow-x: hidden;
}

.test-wrapper {
  overflow-x: hidden;
}

/* =========================================
   Start-Button – Mobile größer & griffiger
========================================= */
@media (max-width: 480px) {

  #introSlide .cta-btn {
    font-size: 18px;
    padding: 16px 24px;
  }
}

/* =========================================
   START-BUTTON – finale Präsenz (Desktop + Mobile)
========================================= */
#introSlide #startBtn {
  width: 100%;
  max-width: 340px;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
  padding: 18px 38px;
}

#introSlide #startBtnText {
  font-size: inherit;
}

/* =========================================================
   MOBILE: Hover optisch neutralisieren
   (Hover = Non‑Active)
========================================================= */
@media (hover: none) and (pointer: coarse) {

  .option-card:hover {
    background: #FFFFFF;
    border-color: #E0E0E0;
    box-shadow: none;
    transform: none;
  }

  .option-card:hover .option-check {
    border-color: #D0D0D0;
    background: transparent;
  }
}
/* =========================================================
   MOBILE: Sichtbares Touch‑Feedback beim Antippen
========================================================= */
@media (hover: none) and (pointer: coarse) {

  /* Kurz beim Antippen sichtbar */
  .option-card:active {
    background-color: rgba(238,113,183,0.12);
    border-color: #EE71B7;
    transform: scale(0.97);
  }

  /* Checkbox beim Antippen leicht mitnehmen */
  .option-card:active .option-check {
    border-color: #EE71B7;
  }
}
/* =========================================================
   MOBILE: Kräftiges Icon‑Feedback beim Antippen
========================================================= */
@media (hover: none) and (pointer: coarse) {

  /* Kreis deutlich färben */
  .option-card:active .option-check {
    border-color: #EE71B7;
    background: #EE71B7;      /* richtig kräftig */
    transform: scale(1.05);  /* leichtes Aufpoppen */
  }

  /* Häkchen klar & satt */
  .option-card:active .option-check svg {
    opacity: 1;
    stroke: #FFFFFF;          /* satt weiß auf Pink */
  }
}

/* =========================================
   Back-Button: PNG-Icon korrekt behandeln
========================================= */
.back-button img {
  width: 18px;
  height: 18px;
  display: inline-block;
  object-fit: contain;
  flex-shrink: 0;
}

