:root {
  --bg: #f7f6f2;
  --panel: #ffffff;
  --ink: #1f2937;
  --muted: #5b6472;
  --accent: #d97706;
  --accent-dark: #9a4f03;
  --ok: #2f855a;
  --line: #e6e1d5;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Source Sans 3", "Segoe UI", sans-serif;
  color: var(--ink);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(circle at 10% -20%, #fdd9a0 0%, transparent 35%),
    radial-gradient(circle at 90% 0%, #f5e7c8 0%, transparent 40%),
    var(--bg);
}

.site-top {
  border-bottom: 1px solid var(--line);
  padding: 2.4rem 0 1.5rem;
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: blur(3px);
}

.site-top h1 {
  margin: 0;
  font-size: clamp(1.8rem, 3vw, 2.7rem);
  letter-spacing: 0.5px;
  line-height: 1.05;
}

.eyebrow {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--accent-dark);
  font-weight: 700;
  font-size: 0.78rem;
}

.subtitle {
  color: var(--muted);
  margin: 0.5rem 0;
}

.main-content {
  padding: 2rem 0 3rem;
  flex: 1;
}

.quiz-box-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: 1.4rem;
}

.quiz-box {
  width: 100%;
  background: #fff9ee;
  border: 1px solid #e8d6b3;
  border-radius: 14px;
  padding: 1.2rem;
  text-align: center;
  box-shadow: 0 10px 25px rgba(31, 41, 55, 0.07);
  position: relative;
}

.quiz-box.is-locked {
  background: #fff4e2;
  border-color: #dec699;
}

.already-played {
  color: #991b1b;
  font-weight: 700;
}

.card {
  background: #fff9ee;
  border: 1px solid #e8d6b3;
  border-radius: 14px;
  padding: 1.25rem;
  margin-bottom: 1.1rem;
  box-shadow: 0 8px 24px rgba(31, 41, 55, 0.05);
}

.seo-box {
  background: var(--panel);
  border-color: var(--line);
  text-align: center;
}

.card h3,
.card h4 {
  margin-top: 0;
}

.muted {
  color: var(--muted);
}

.topic-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
}

.topic-chip {
  display: inline-block;
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  border: 1px solid #f4d8a0;
  background: #fff4de;
  color: #7a4302;
  font-size: 0.9rem;
  font-weight: 600;
}

.pillar-chart {
  display: grid;
  grid-template-columns: repeat(11, minmax(0, 1fr));
  align-items: end;
  gap: 0.45rem;
  padding: 0.35rem 0;
}

.pillar-col {
  display: grid;
  justify-items: center;
  gap: 0.35rem;
}

.pillar-value {
  font-size: 0.75rem;
  color: var(--muted);
}

.pillar-track {
  width: 100%;
  height: 170px;
  border-radius: 10px;
  background: #f2ede2;
  border: 1px solid #e7dfcf;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}

.pillar-fill {
  width: 100%;
  background: linear-gradient(180deg, #f9b233, #d97706);
  border-radius: 8px 8px 0 0;
}

.pillar-label {
  font-size: 0.76rem;
  white-space: nowrap;
}

.pillar-count {
  font-size: 0.65rem;
  color: var(--muted);
  white-space: nowrap;
}

.pillar-col.is-player-score .pillar-track {
  border-color: #15803d;
  box-shadow: 0 0 0 3px rgba(21, 128, 61, 0.15);
}

.pillar-col.is-player-score .pillar-fill {
  background: linear-gradient(180deg, #6ee7b7, #15803d);
}

.pillar-col.is-player-score .pillar-label {
  color: #166534;
  font-weight: 700;
}

.pillar-col.is-player-score .pillar-count {
  color: #166534;
}

.pillar-you {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  color: #14532d;
  background: #dcfce7;
  border: 1px solid #86efac;
  border-radius: 999px;
  padding: 0.08rem 0.35rem;
  line-height: 1;
}

.quiz-play-card .badge {
  display: inline-block;
  background: #fff3dc;
  border: 1px solid #f4d8a0;
  color: #8a4f00;
  border-radius: 999px;
  padding: 0.2rem 0.75rem;
  font-size: 0.8rem;
  margin-bottom: 0.35rem;
}

.options {
  display: grid;
  gap: 0.55rem;
}

.question-step {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.8rem;
}

.question-step.is-correct {
  background: #edf9f1;
  border-color: #78c59a;
}

.question-step.is-wrong {
  background: #fdecec;
  border-color: #e2a0a0;
}

.option-item {
  display: flex;
  gap: 0.55rem;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.55rem 0.7rem;
}

.option-item:hover {
  background: #fcfaf4;
}

.quiz-actions {
  margin-top: 1rem;
  display: flex;
  gap: 0.6rem;
}

.answer-feedback {
  margin: 0.65rem 0 0;
  font-weight: 600;
}

.resume-note {
  margin: 0.5rem 0 0.9rem;
  color: #8a4f00;
  font-weight: 600;
}

.hidden {
  display: none !important;
}

.big-score {
  font-size: 2.3rem;
  font-weight: 700;
  margin: 0.2rem 0;
}

.result-card {
  text-align: center;
  background: #fff9ee;
  border-color: #e8d6b3;
}

.quiz-play-card {
  background: #fff9ee;
  border-color: #e8d6b3;
}

.site-footer {
  background: #2f271b;
  color: #f2e6cf;
  border-top: 1px solid #4a3b27;
  margin-top: 1.2rem;
}

.site-footer p {
  margin: 0;
  text-align: center;
  font-size: 0.82rem;
  padding: 0.7rem 0;
  letter-spacing: 0.02em;
}

@media (max-width: 720px) {
  .pillar-chart {
    gap: 0.25rem;
  }

  .pillar-track {
    height: 140px;
  }

  .pillar-value,
  .pillar-label,
  .pillar-count {
    font-size: 0.68rem;
  }

  .quiz-actions {
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }
}
