:root {
  --bg: #f7f1e8;
  --panel: rgba(255, 251, 246, 0.88);
  --panel-strong: #fffaf2;
  --ink: #22201b;
  --muted: #6f6559;
  --accent: #0f7b6c;
  --accent-strong: #085b50;
  --accent-soft: #d7efe9;
  --warm: #c96d3b;
  --warm-soft: #f9e3d4;
  --danger: #a53f3f;
  --danger-soft: #f9dede;
  --shadow: 0 20px 50px rgba(65, 42, 16, 0.12);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 14px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Manrope", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(255, 203, 152, 0.45), transparent 30%),
    radial-gradient(circle at top right, rgba(96, 183, 172, 0.28), transparent 28%),
    linear-gradient(135deg, #f5eee1 0%, #efe5d6 100%);
}

.page-shell {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 24px;
  max-width: 1440px;
  margin: 0 auto;
  padding: 24px;
}

.control-panel,
.practice-panel {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.brand-card,
.panel-section,
.hero-banner,
.question-card,
.mistake-card {
  background: var(--panel);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow);
}

.brand-card,
.panel-section,
.question-card,
.mistake-card {
  padding: 22px;
}

.hero-banner {
  padding: 30px;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 20px;
  overflow: hidden;
  position: relative;
}

.hero-banner::after {
  content: "";
  position: absolute;
  inset: auto -80px -90px auto;
  width: 240px;
  height: 240px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(15, 123, 108, 0.14), transparent 70%);
}

.eyebrow {
  margin: 0 0 8px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 12px;
  color: var(--warm);
  font-weight: 800;
}

.app-signature {
  font-size: 18px;
  letter-spacing: 0.08em;
  line-height: 1.3;
  margin-bottom: 12px;
}

h1,
h2,
h3,
h4 {
  margin: 0;
  font-family: "Fraunces", serif;
}

h1 {
  font-size: 34px;
  line-height: 1.05;
  margin-bottom: 10px;
}

h2 {
  font-size: 22px;
  margin-bottom: 12px;
}

h3 {
  font-size: 28px;
}

p {
  margin: 0;
  line-height: 1.65;
}

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

.segmented,
.check-grid,
.button-stack {
  display: grid;
  gap: 10px;
}

.segmented label,
.check-grid label {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  background: var(--panel-strong);
  border-radius: var(--radius-md);
  border: 1px solid rgba(12, 62, 55, 0.08);
  font-weight: 600;
}

input[type="radio"],
input[type="checkbox"] {
  accent-color: var(--accent);
  width: 18px;
  height: 18px;
}

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

.slider-row input[type="number"] {
  width: 100%;
  min-width: 0;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(34, 32, 27, 0.12);
  background: rgba(255, 255, 255, 0.82);
  font: inherit;
  font-weight: 700;
  color: var(--ink);
}

.slider-row input[type="number"]:focus {
  outline: 2px solid rgba(201, 115, 67, 0.22);
  border-color: rgba(201, 115, 67, 0.38);
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.stat-box {
  background: linear-gradient(145deg, #fff9f0, #f6eee3);
  border-radius: var(--radius-md);
  padding: 14px;
  display: grid;
  gap: 8px;
}

.stat-box span {
  color: var(--muted);
  font-size: 13px;
}

.stat-box strong {
  font-size: 24px;
}

.primary-btn,
.ghost-btn {
  appearance: none;
  border: none;
  border-radius: 999px;
  padding: 14px 18px;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

.primary-btn {
  background: linear-gradient(135deg, var(--accent) 0%, #1aa28e 100%);
  color: white;
  box-shadow: 0 16px 30px rgba(15, 123, 108, 0.24);
}

.ghost-btn {
  background: var(--panel-strong);
  color: var(--ink);
  border: 1px solid rgba(34, 32, 27, 0.08);
}

.primary-btn:hover,
.ghost-btn:hover {
  transform: translateY(-2px);
}

.hero-chip-group {
  display: flex;
  flex-wrap: wrap;
  align-content: start;
  gap: 10px;
}

.hero-chip,
.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
}

.hero-chip {
  background: var(--warm-soft);
  color: #7d461d;
}

.question-head,
.section-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: start;
}

.question-type {
  margin-bottom: 6px;
  font-size: 13px;
  color: var(--accent);
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.pill {
  background: var(--accent-soft);
  color: var(--accent-strong);
}

.prompt-box {
  margin: 20px 0;
  padding: 22px;
  border-radius: var(--radius-lg);
  background:
    linear-gradient(180deg, rgba(255, 252, 246, 0.96), rgba(248, 241, 231, 0.9)),
    repeating-linear-gradient(
      to bottom,
      transparent 0,
      transparent 33px,
      rgba(201, 109, 59, 0.08) 34px
    );
  border: 1px solid rgba(201, 109, 59, 0.12);
}

.session-bar {
  margin-top: 18px;
  padding: 14px 16px;
  border-radius: var(--radius-lg);
  background: linear-gradient(145deg, #fff8ef, #f4ecdf);
  border: 1px solid rgba(201, 109, 59, 0.12);
}

.session-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 10px;
  font-size: 14px;
  font-weight: 700;
}

.session-track {
  width: 100%;
  height: 10px;
  border-radius: 999px;
  background: rgba(201, 109, 59, 0.16);
  overflow: hidden;
}

.session-fill {
  width: 0;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--warm), #e7a05f);
  transition: width 0.2s ease;
}

#question-prompt {
  font-size: 25px;
  line-height: 1.4;
  font-weight: 800;
}

.answer-form {
  display: grid;
  gap: 14px;
}

.questions-list {
  display: grid;
  gap: 16px;
}

.question-item {
  padding: 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(34, 32, 27, 0.08);
  display: grid;
  gap: 10px;
}

.question-item-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: start;
}

.question-item-label {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--accent);
  text-transform: uppercase;
}

.question-item-prompt {
  font-size: 17px;
  font-weight: 700;
  line-height: 1.5;
}

.question-item input[type="text"] {
  width: 100%;
  padding: 14px 16px;
  border-radius: 14px;
  border: 1px solid rgba(34, 32, 27, 0.12);
  font-size: 17px;
  background: white;
}

.series-results {
  margin-top: 16px;
  display: grid;
  gap: 12px;
}

.result-item {
  padding: 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.62);
  border: 1px solid rgba(34, 32, 27, 0.08);
  display: grid;
  gap: 6px;
}

.result-item.incorrect {
  border-color: rgba(165, 63, 63, 0.18);
  background: rgba(249, 222, 222, 0.7);
}

.answer-form label {
  font-weight: 700;
}

.answer-form input[type="text"] {
  width: 100%;
  padding: 16px 18px;
  border-radius: 18px;
  border: 1px solid rgba(34, 32, 27, 0.12);
  font-size: 18px;
  background: white;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.feedback-card {
  margin-top: 16px;
  padding: 18px;
  border-radius: var(--radius-lg);
  background: var(--accent-soft);
  color: var(--accent-strong);
}

.feedback-actions {
  margin-top: 14px;
  display: flex;
  justify-content: flex-end;
}

.feedback-card.incorrect {
  background: var(--danger-soft);
  color: var(--danger);
}

.hidden {
  display: none;
}

.mistake-list {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.mistake-item {
  padding: 16px;
  border-radius: var(--radius-md);
  background: linear-gradient(145deg, #fff8f7, #fdf1ef);
  border: 1px solid rgba(165, 63, 63, 0.1);
  display: grid;
  gap: 6px;
}

.mistake-item strong {
  font-size: 15px;
}

.mistake-item span,
.empty-text {
  color: var(--muted);
}

@media (max-width: 1024px) {
  .page-shell {
    grid-template-columns: 1fr;
  }

  .hero-banner {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .page-shell {
    padding: 14px;
  }

  .brand-card,
  .panel-section,
  .hero-banner,
  .question-card,
  .mistake-card {
    padding: 18px;
    border-radius: 22px;
  }

  #question-prompt {
    font-size: 21px;
  }

  .question-head,
  .section-head,
  .slider-row {
    grid-template-columns: 1fr;
    display: grid;
  }
}
