:root {
  color-scheme: dark;
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  --bg: #05040d;
  --panel: #120c2b;
  --panel-2: #1a1241;
  --text: #fff8ff;
  --muted: #c8b7d8;
  --line: rgba(255, 255, 255, 0.12);
  --cyan: #31e7ff;
  --lime: #c9ff3b;
  --pink: #ff3df2;
  --orange: #ff8b2b;
  --good: #6dffaf;
  --bad: #ff6f8f;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 20% 0%, rgba(255, 61, 242, 0.22), transparent 31rem),
    radial-gradient(circle at 82% 5%, rgba(49, 231, 255, 0.2), transparent 34rem),
    linear-gradient(135deg, #05040d 0%, #14092d 48%, #061421 100%);
  color: var(--text);
}

button,
textarea {
  font: inherit;
}

.shell {
  width: min(1160px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0 44px;
}

.hero {
  min-height: 540px;
  padding: 18px 0 30px;
  border-bottom: 1px solid rgba(49, 231, 255, 0.2);
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 46px;
}

.mark {
  display: grid;
  place-items: center;
  width: 46px;
  aspect-ratio: 1;
  border: 1px solid rgba(49, 231, 255, 0.62);
  color: var(--cyan);
  font-weight: 900;
  background: linear-gradient(135deg, rgba(49, 231, 255, 0.18), rgba(255, 61, 242, 0.18));
}

.hero-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 28px;
  align-items: center;
  padding-top: 54px;
}

.system-line {
  margin: 0 0 8px;
  color: var(--lime);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  letter-spacing: 0;
}

h1 {
  margin: 0;
  max-width: 660px;
  font-size: clamp(2.5rem, 6vw, 5.8rem);
  line-height: 0.94;
}

h2 {
  margin: 0;
  font-size: clamp(1.8rem, 3vw, 3.2rem);
  line-height: 1;
}

h3 {
  margin: 0 0 16px;
  font-size: 1.35rem;
}

.lede,
.module-body,
.receipt-panel p {
  color: var(--muted);
  line-height: 1.62;
}

.lede {
  max-width: 680px;
  font-size: 1.08rem;
}

.hero-actions,
.lesson-actions,
.receipt-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

button {
  min-height: 46px;
  border: 1px solid rgba(201, 255, 59, 0.55);
  background: linear-gradient(135deg, var(--lime), var(--cyan));
  color: #090512;
  padding: 0 18px;
  cursor: pointer;
  font-weight: 900;
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

button:hover {
  transform: translateY(-1px);
  box-shadow: 0 0 26px rgba(49, 231, 255, 0.22);
}

button.secondary {
  color: var(--text);
  border-color: rgba(255, 61, 242, 0.38);
  background: rgba(255, 255, 255, 0.055);
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
  transform: none;
}

.video-shell {
  border: 1px solid rgba(49, 231, 255, 0.32);
  padding: 10px;
  background: rgba(18, 12, 43, 0.72);
  box-shadow: 0 30px 74px rgba(0, 0, 0, 0.32);
}

video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #080512;
}

.status-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin: 18px 0 12px;
}

.status-grid article,
.rail,
.lesson-card,
.receipt-panel {
  border: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(26, 18, 65, 0.82), rgba(9, 7, 23, 0.9)),
    radial-gradient(circle at top right, rgba(49, 231, 255, 0.09), transparent 42%);
}

.status-grid article {
  min-height: 112px;
  padding: 16px;
  display: grid;
  align-content: space-between;
}

.status-grid span {
  color: var(--muted);
  font-weight: 700;
}

.status-grid strong {
  font-size: 2rem;
  background: linear-gradient(90deg, var(--cyan), var(--lime));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lesson-layout {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 12px;
}

.rail {
  padding: 14px;
}

.module-button {
  width: 100%;
  justify-content: start;
  min-height: 66px;
  margin-bottom: 8px;
  border-color: var(--line);
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
  text-align: left;
}

.module-button.active {
  border-color: rgba(49, 231, 255, 0.72);
  background: linear-gradient(135deg, rgba(49, 231, 255, 0.18), rgba(255, 61, 242, 0.12));
}

.module-button.passed::after {
  content: "passed";
  display: block;
  margin-top: 4px;
  color: var(--good);
  font-size: 0.78rem;
}

.lesson-card {
  min-height: 560px;
  padding: 24px;
}

.lesson-head {
  margin-bottom: 18px;
}

.bullet-list {
  display: grid;
  gap: 10px;
  margin: 20px 0;
}

.bullet-list div {
  border-left: 3px solid var(--cyan);
  background: rgba(255, 255, 255, 0.05);
  padding: 12px 14px;
  color: #f3ecfb;
}

.quiz-card {
  margin-top: 24px;
  padding: 18px;
  border: 1px solid rgba(201, 255, 59, 0.2);
  background: rgba(0, 0, 0, 0.2);
}

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

.answer {
  min-height: auto;
  padding: 13px 14px;
  color: var(--text);
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.045);
  text-align: left;
}

.answer.correct {
  border-color: rgba(109, 255, 175, 0.7);
  background: rgba(109, 255, 175, 0.12);
}

.answer.incorrect {
  border-color: rgba(255, 111, 143, 0.7);
  background: rgba(255, 111, 143, 0.12);
}

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

.feedback.good {
  color: var(--good);
}

.feedback.bad {
  color: var(--bad);
}

.lesson-actions {
  justify-content: space-between;
  margin-top: 20px;
}

.receipt-panel {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 18px;
  margin-top: 12px;
  padding: 22px;
}

textarea {
  width: 100%;
  min-height: 220px;
  resize: vertical;
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.28);
  color: var(--text);
  padding: 14px;
  line-height: 1.5;
}

.receipt-actions {
  grid-column: 2;
}

@media (max-width: 900px) {
  .hero-grid,
  .status-grid,
  .lesson-layout,
  .receipt-panel {
    grid-template-columns: 1fr;
  }

  .receipt-actions {
    grid-column: auto;
  }
}
