:root {
  --bg: #f3efe7;
  --surface: rgba(255, 252, 247, 0.82);
  --surface-strong: #fffdf8;
  --border: rgba(44, 54, 69, 0.12);
  --text: #1d2733;
  --muted: #5d6875;
  --accent: #1b4d6b;
  --accent-strong: #11354b;
  --success: #275b40;
  --danger: #7c2f31;
  --shadow: 0 24px 80px rgba(20, 27, 35, 0.08);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: Georgia, "Times New Roman", serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(27, 77, 107, 0.12), transparent 28%),
    linear-gradient(180deg, #f7f2ea 0%, #ece6dc 100%);
}

button,
a {
  font: inherit;
}

.page-shell {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  padding: 36px 0 80px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(280px, 0.7fr);
  gap: 28px;
  align-items: stretch;
  margin-bottom: 36px;
}

.hero__copy,
.hero__panel,
.overview-card,
.quiz-section {
  background: var(--surface);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.hero__copy {
  border-radius: var(--radius-xl);
  padding: 40px;
}

.hero__copy h1 {
  margin: 0;
  max-width: 10ch;
  font-size: clamp(3rem, 7vw, 5.5rem);
  line-height: 0.95;
  letter-spacing: -0.04em;
}

.eyebrow {
  margin: 0 0 16px;
  font-family: "Trebuchet MS", sans-serif;
  font-size: 0.8rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

.hero__lead {
  max-width: 56ch;
  margin: 20px 0 0;
  font-size: 1.1rem;
  line-height: 1.7;
  color: var(--muted);
}

.hero__actions,
.quiz-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero__actions {
  margin-top: 28px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid transparent;
  text-decoration: none;
  cursor: pointer;
  transition:
    transform 180ms ease,
    background-color 180ms ease,
    border-color 180ms ease,
    color 180ms ease;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-1px);
}

.button--primary {
  background: var(--accent);
  color: #f8fbfd;
}

.button--primary:hover,
.button--primary:focus-visible {
  background: var(--accent-strong);
}

.button--secondary,
.button--ghost {
  border-color: var(--border);
  color: var(--text);
  background: rgba(255, 255, 255, 0.45);
}

.hero__panel {
  border-radius: var(--radius-xl);
  padding: 28px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.panel__label {
  margin: 0;
  font-family: "Trebuchet MS", sans-serif;
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

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

.panel__stats li {
  padding-top: 18px;
  border-top: 1px solid var(--border);
}

.panel__stats strong {
  display: block;
  font-size: 2.2rem;
  font-weight: 600;
}

.panel__stats span {
  display: block;
  margin-top: 6px;
  color: var(--muted);
}

.overview {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 36px;
}

.overview-card {
  border-radius: var(--radius-lg);
  padding: 24px;
}

.overview-card__title {
  margin: 0 0 8px;
  font-family: "Trebuchet MS", sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.78rem;
  color: var(--muted);
}

.overview-card p:last-child {
  margin-bottom: 0;
  line-height: 1.7;
}

.quiz-section {
  border-radius: var(--radius-xl);
  padding: 28px;
}

.quiz-section__header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  margin-bottom: 22px;
}

.quiz-section__header h2 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1;
}

.quiz-root {
  min-height: 360px;
}

.quiz-card,
.result-card {
  background: var(--surface-strong);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
}

.quiz-meta,
.result-summary {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 20px;
  color: var(--muted);
  font-family: "Trebuchet MS", sans-serif;
  font-size: 0.9rem;
}

.quiz-question {
  margin: 0 0 24px;
  font-size: clamp(1.45rem, 2.5vw, 2rem);
  line-height: 1.3;
}

.answers {
  display: grid;
  gap: 12px;
}

.answer-option {
  width: 100%;
  text-align: left;
  padding: 16px 18px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: #fcfaf5;
  color: var(--text);
  transition:
    border-color 160ms ease,
    background-color 160ms ease,
    transform 160ms ease;
}

.answer-option:hover,
.answer-option:focus-visible {
  border-color: rgba(27, 77, 107, 0.4);
  transform: translateY(-1px);
}

.answer-option.is-selected {
  border-color: var(--accent);
  background: rgba(27, 77, 107, 0.08);
}

.quiz-feedback {
  min-height: 28px;
  margin: 16px 0 0;
  color: var(--muted);
}

.quiz-feedback.is-correct {
  color: var(--success);
}

.quiz-feedback.is-incorrect {
  color: var(--danger);
}

.quiz-controls {
  margin-top: 22px;
}

.result-card h3 {
  margin-top: 0;
  font-size: clamp(1.8rem, 3vw, 2.4rem);
}

.result-list {
  margin: 18px 0 0;
  padding-left: 18px;
  color: var(--muted);
  line-height: 1.7;
}

@media (max-width: 880px) {
  .hero,
  .overview {
    grid-template-columns: 1fr;
  }

  .hero__copy {
    padding: 28px;
  }

  .quiz-section__header {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 560px) {
  .page-shell {
    width: min(100% - 24px, 1120px);
    padding-top: 20px;
  }

  .hero__copy,
  .hero__panel,
  .quiz-section,
  .overview-card,
  .quiz-card,
  .result-card {
    padding: 20px;
  }

  .hero__copy h1 {
    max-width: none;
  }
}
