:root {
  --bg: #ffffff;
  --bg-soft: #f4f3f7;
  --ink: #141118;
  --ink-dim: #56526a;
  --line: #e2e0ea;
  --space: #b8b5c4;   /* пространство — светло-серый (тихий элемент на белом) */
  --air:   #1ba35e;   /* ветер — чистый зелёный */
  --fire:  #e63127;   /* огонь — тёплый алый */
  --water: #1e90d6;   /* вода — сине-голубой */
  --earth: #e0a81f;   /* земля — жёлтая охра */
  /* притемнённые версии — только для текста-подписей на белом */
  --space-ink: #6f6b80;
  --air-ink:   #158049;
  --fire-ink:  #c72219;
  --water-ink: #1a72ab;
  --earth-ink: #a9790a;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  /* Фиксированная светлая тема — НЕ наследуем тему Telegram. */
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  padding: 0 0 80px;
}
.wrap { max-width: 560px; margin: 0 auto; padding: 0 22px; }

/* Intro */
.hero { padding: 68px 0 40px; text-align: center; }
.hero .eyebrow {
  font-size: 12px; letter-spacing: 0.28em; text-transform: uppercase;
  color: var(--ink-dim); margin-bottom: 22px;
}
.hero h1 {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-weight: 600; font-size: 33px; line-height: 1.18;
  letter-spacing: -0.02em; margin-bottom: 18px;
}
.hero p { color: var(--ink-dim); font-size: 15.5px; max-width: 400px; margin: 0 auto 32px; }
.dots { display: flex; gap: 10px; justify-content: center; margin-bottom: 34px; }
.dot { width: 11px; height: 11px; border-radius: 50%; opacity: 0.95; box-shadow: 0 0 0 1px rgba(0,0,0,0.10); }
.dot.space { background: var(--space); }
.dot.air { background: var(--air); }
.dot.fire { background: var(--fire); }
.dot.water { background: var(--water); }
.dot.earth { background: var(--earth); }

.btn {
  display: inline-block; border: none; cursor: pointer;
  background: var(--ink); color: var(--bg);
  font-size: 15px; font-weight: 500; letter-spacing: 0.01em;
  padding: 15px 38px; border-radius: 40px;
  transition: transform 0.15s ease, opacity 0.15s ease;
  font-family: inherit;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
.btn:disabled { opacity: 0.28; cursor: not-allowed; transform: none; }
.gate-note { margin-top: 14px; font-size: 13px; color: var(--ink-dim); min-height: 18px; }

/* Questions */
.q {
  padding: 26px 0; border-bottom: 1px solid var(--line);
  opacity: 0; transform: translateY(8px);
  animation: rise 0.5s ease forwards;
}
@keyframes rise { to { opacity: 1; transform: translateY(0); } }
.q .tag {
  font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase;
  margin-bottom: 12px; display: inline-flex; align-items: center; gap: 7px;
}
.q .tag .swatch { width: 9px; height: 9px; border-radius: 50%; }
.q .text { font-size: 17px; margin-bottom: 20px; line-height: 1.4; }

.slider-row { display: flex; align-items: center; gap: 14px; }
input[type=range] {
  -webkit-appearance: none; appearance: none;
  flex: 1; height: 4px; border-radius: 4px;
  background: var(--line); outline: none; cursor: pointer;
}
input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--thumb, var(--ink)); cursor: pointer;
  border: 3px solid var(--bg);
  box-shadow: 0 0 0 1px var(--thumb, var(--ink)), 0 0 14px -2px var(--thumb, transparent);
  transition: transform 0.12s ease;
}
input[type=range]::-webkit-slider-thumb:hover { transform: scale(1.12); }
input[type=range].untouched::-webkit-slider-thumb {
  background: #cfccdc;
  box-shadow: 0 0 0 1px #b4b0c6;
}
input[type=range].untouched::-moz-range-thumb {
  background: #cfccdc; border-color: var(--bg);
}
input[type=range].untouched { opacity: 0.75; }
input[type=range]::-moz-range-thumb {
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--thumb, var(--ink)); cursor: pointer; border: 3px solid var(--bg);
}
.ends { display: flex; justify-content: space-between; margin-top: 10px; }
.ends span { font-size: 13px; color: #6b6780; max-width: 45%; line-height: 1.35; }
.ends span:last-child { text-align: right; }

.screen { display: none; }
.screen.active { display: block; animation: fade 0.4s ease; }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

.foot { text-align: center; padding-top: 40px; }
.progress-note { text-align:center; color: var(--ink-dim); font-size: 13px; margin: 30px 0 0; }

/* Report */
.report-head { padding: 60px 0 10px; text-align: center; }
.report-head .eyebrow { font-size: 12px; letter-spacing: 0.26em; text-transform: uppercase; color: var(--ink-dim); margin-bottom: 16px; }
.report-head h2 { font-family: Georgia, serif; font-weight: 400; font-size: 28px; }

.chart { margin: 34px 0 10px; }
.bar-block { margin-bottom: 26px; }
.bar-top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 9px; }
.bar-name { font-size: 16px; display: flex; align-items: center; gap: 9px; }
.bar-name .swatch { width: 11px; height: 11px; border-radius: 50%; }
.bar-meta { font-size: 13.5px; color: #4a4660; letter-spacing: 0.01em; }
.track { height: 8px; background: var(--bg-soft); border-radius: 8px; overflow: hidden; position: relative; }
.fill { height: 100%; border-radius: 8px; width: 0; transition: width 1s cubic-bezier(.2,.7,.2,1); }
.neuro { font-size: 13px; margin-top: 8px; display: flex; align-items: center; gap: 8px; }
.neuro .nbar { flex: 1; height: 3px; background: var(--bg-soft); border-radius: 3px; overflow: hidden; }
.neuro .nfill { height: 100%; width: 0; background: repeating-linear-gradient(90deg, currentColor, currentColor 3px, transparent 3px, transparent 6px); transition: width 1.1s ease; }

.comment { background: var(--bg-soft); border: 1px solid var(--line); border-radius: 16px; padding: 26px 24px; margin: 30px 0; }
.comment h3 { font-family: Georgia, serif; font-weight: 400; font-size: 20px; margin-bottom: 14px; }
.comment p { font-size: 15px; color: var(--ink); margin-bottom: 12px; }
.comment p:last-child { margin-bottom: 0; }
.comment p.row { margin-bottom: 10px; font-size: 14.5px; line-height: 1.4; }
.comment .accent { color: #4a4660; }
.comment .summary { margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--line); }
.comment .summary h4 { font-size: 12px; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-dim); margin-bottom: 10px; font-weight: 600; }
.comment .summary p { font-size: 15px; line-height: 1.55; }

.cta-block { text-align: center; padding: 24px 0 10px; }
.cta-block .lead { font-size: 16px; margin-bottom: 6px; }
.cta-block .sub { font-size: 14px; color: var(--ink-dim); margin-bottom: 22px; max-width: 380px; margin-left: auto; margin-right: auto; }

.restart { display:block; margin: 30px auto 0; background: none; border: none; color: var(--ink-dim); font-size: 13px; cursor: pointer; text-decoration: underline; font-family: inherit; }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }
