:root {
  --bg: #111;
  --bg2: #181818;
  --text: #E0E0E0;
  --gold: #D4AF37;
  --red: #C70039;
  --border: #2a2a2a;
  --radius: 18px;
  --shadow: 0 0 25px rgba(212,175,55,0.15);
}

/* RESET + BASE ------------------------------------ */
* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Montserrat', system-ui, -apple-system, Segoe UI, Roboto, 'Helvetica Neue', Arial, sans-serif;
  scroll-behavior: smooth;
}

h1, h2, h3 {
  font-family: 'Playfair Display', serif;
  color: var(--gold);
  margin-top: 0;
  letter-spacing: 0.3px;
}

p {
  line-height: 1.6;
  margin-bottom: 10px;
}

.container {
  max-width: 960px;
  margin: 0 auto;
  padding: 25px 20px 80px;
}

/* CARD -------------------------------------------- */
.card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow);
  margin-bottom: 20px;
  transition: all 0.3s ease;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 0 35px rgba(212,175,55,0.3);
}

/* HERO -------------------------------------------- */
.hero {
  text-align: center;
  margin-bottom: 40px;
}

.hero p {
  font-size: 1.05rem;
  color: var(--text);
}

/* GRID -------------------------------------------- */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}

.grid .card {
  text-align: center;
  cursor: pointer;
}

.grid .button {
  margin-top: 10px;
}

/* BUTTONS ----------------------------------------- */
button, .button {
  font-family: 'Montserrat', sans-serif;
  appearance: none;
  -webkit-appearance: none;
  border: none;
  cursor: pointer;
}

.button {
  background: var(--gold);
  color: var(--bg);
  padding: 12px 24px;
  border-radius: 999px;
  font-weight: 600;
  text-decoration: none;
  display: inline-block;
  transition: all 0.25s ease;
}

.button:hover {
  background: var(--red);
  color: #fff;
  box-shadow: 0 0 12px rgba(199,0,57,0.6);
}

.button.outline {
  background: transparent;
  border: 1px solid var(--gold);
  color: var(--gold);
}

.button.outline:hover {
  background: var(--gold);
  color: var(--bg);
}

/* PROGRESS BAR ------------------------------------ */
.progress {
  height: 10px;
  background: #222;
  border-radius: 999px;
  overflow: hidden;
  border: 1px solid var(--border);
  margin: 8px 0 16px;
}

.progress > span {
  display: block;
  height: 100%;
  width: 0;
  background: var(--gold);
  transition: width .35s ease;
}

/* ANSWERS ----------------------------------------- */
.answers {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin-top: 10px;
}

.answer {
  color: var(--text);                     /* sichtbarer Text */
  background: #141414;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px;
  width: 100%;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
  appearance: none;
  -webkit-appearance: none;
  font: inherit;
}

.answer:hover {
  border-color: var(--gold);
  background: #1a1a1a;
  color: #fff;
}

.answer.correct {
  border-color: #1fa843;
  color: #1fa843;
}

.answer.incorrect {
  border-color: #d24a4a;
  color: #d24a4a;
}

.answer:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px rgba(212,175,55,0.45);
}

/* FEEDBACK ---------------------------------------- */
.badge {
  display: inline-block;
  border-radius: 999px;
  padding: 6px 12px;
  border: 1px solid var(--border);
  font-size: .9rem;
  margin-top: 8px;
  background: #1b1b1b;
}

.small {
  font-size: .9rem;
  opacity: .9;
}

/* FOOTER ACTIONS ---------------------------------- */
.footer-actions {
  margin-top: 20px;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  justify-content: center;
}

/* POPUP & OVERLAY --------------------------------- */
.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(17, 17, 17, 0.95);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}

.overlay.fadein {
  opacity: 1;
  visibility: visible;
}

.popup {
  max-width: 650px;
  text-align: center;
  animation: fadeUp 1.2s ease forwards;
  box-shadow: inset 0 0 25px rgba(212,175,55,0.25), 0 0 25px rgba(212,175,55,0.25);
}

/* ANIMATIONS -------------------------------------- */
.hidden {
  display: none !important;
}

@keyframes fadeUp {
  0% {
    opacity: 0;
    transform: translateY(30px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/* TEXT FADE / GLOW -------------------------------- */
.result-intro {
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--gold);
  text-align: center;
  opacity: 0;
  animation: textFade 2.2s ease forwards;
  animation-delay: 0.5s;
  letter-spacing: 0.4px;
  text-shadow: 0 0 8px rgba(212,175,55,0.45);
}

@keyframes textFade {
  0% { opacity: 0; filter: blur(6px); }
  40% { opacity: 0.7; filter: blur(2px); }
  100% { opacity: 1; filter: blur(0); }
}

@keyframes loinaGlow {
  0%, 100% { text-shadow: 0 0 8px rgba(212,175,55,0.45); }
  50% { text-shadow: 0 0 14px rgba(212,175,55,0.85); }
}

.result-intro.glow {
  animation: textFade 2.2s ease forwards, loinaGlow 4s ease-in-out infinite;
}

/* RESPONSIVE -------------------------------------- */
@media (max-width: 600px) {
  h1 { font-size: 1.7rem; }
  .card { padding: 16px; }
  .grid { grid-template-columns: 1fr; }
}