/* PraviloKirov — брендбук-стиль. Антрацит #0F0F0F + золото #BFA98A + песок #E5DED2 + cream #F6F4EF.
   Montserrat Extra Light для брендового текста, тонкие линии, минимум плотностей. */

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@200;300;400;500&display=swap');

:root {
  color-scheme: dark;
  --bg: #0F0F0F;
  --surface: #1C1C1C;
  --surface-2: #232323;
  --gold: #BFA98A;
  --gold-soft: rgba(191,169,138,0.55);
  --gold-dim: rgba(191,169,138,0.20);
  --sand: #E5DED2;
  --light: #F6F4EF;
  --fg: #F6F4EF;
  --muted: rgba(245,245,239,0.55);
  --muted-2: rgba(245,245,239,0.32);
  --line: rgba(245,245,239,0.08);
  --line-strong: rgba(191,169,138,0.32);
  --shadow-soft: 0 2px 12px rgba(0,0,0,0.45);
  --shadow-card: 0 8px 32px rgba(0,0,0,0.55);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; touch-action: manipulation; -webkit-text-size-adjust: 100%; }
body {
  background: var(--bg);
  color: var(--fg);
  font: 16px/1.5 'Montserrat', -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, sans-serif;
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  padding: 16px;
  padding-top: max(20px, env(safe-area-inset-top));
  padding-bottom: max(20px, env(safe-area-inset-bottom));
  min-height: 100dvh;
}

main { max-width: 560px; margin: 0 auto; }

.screen { display: none; flex-direction: column; gap: 18px; animation: pk-fade 380ms ease both; }
.screen[data-active] { display: flex; }
@keyframes pk-fade {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: none; }
}

h1 {
  font-size: 24px; line-height: 1.22; margin: 0;
  font-weight: 300; letter-spacing: -0.005em;
  color: var(--light);
}
h2 {
  font-size: 20px; line-height: 1.25; margin: 0;
  font-weight: 400; letter-spacing: 0.005em;
  color: var(--light);
}
.lede { color: var(--muted); margin: 8px 0 0; font-size: 15px; font-weight: 300; }
.muted { color: var(--muted); margin: 0; font-weight: 300; }
.muted.small { font-size: 12px; opacity: 0.85; line-height: 1.45; }
.hero { padding: 6px 0 2px; }

/* подсказка для пришедших по реф-ссылке (welcome) */
.ref-hint {
  margin: 12px 0 0;
  padding: 10px 14px;
  font-size: 13px; color: var(--gold); font-weight: 400;
  background: var(--gold-dim);
  border: 1px solid var(--gold-soft);
  border-radius: 12px;
  letter-spacing: 0.01em;
}

/* Метод-подсказка под lede на welcome — для скептика, который ждёт научное обоснование */
.method-hint {
  margin: 8px 0 0;
  font-size: 12px; line-height: 1.5;
  color: var(--muted-2); font-weight: 300;
  letter-spacing: 0.005em;
}

/* приватность на финальном экране — снимает страх «фото уйдёт мастеру» */
.privacy-pledge {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 14px;
  margin: 6px 0 4px;
  font-size: 13px; line-height: 1.45;
  color: var(--sand); font-weight: 300;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
}
.privacy-icon {
  flex: 0 0 auto; font-size: 14px; line-height: 1;
  color: var(--gold);
}

/* === debug overlay === */
#pk-debug-log {
  position: fixed;
  top: 0; left: 0; right: 0;
  max-height: 45vh;
  overflow: auto;
  background: rgba(0,0,0,0.92);
  color: #7fff7f;
  font: 11px/1.35 ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  padding: 8px 10px;
  z-index: 9999;
  white-space: pre-wrap;
  word-break: break-word;
}
#pk-debug-log[hidden] { display: none; }
#pk-debug-log > div { margin-bottom: 2px; }

/* === splash === */
/* Самодостаточный overlay: видимость и уход управляются ТОЛЬКО CSS,
   не зависит от main.js. Если JS не загрузился — splash сам уходит
   через 3.2с, welcome остаётся виден под ним. */
#splash {
  display: flex; flex-direction: column;
  position: fixed; inset: 0;
  align-items: center; justify-content: center;
  background: var(--bg);
  z-index: 100;
  animation: pk-splash-out 2400ms ease forwards;
  pointer-events: none;
}
.splash-content {
  text-align: center;
  display: flex; flex-direction: column; align-items: center; gap: 26px;
}
.brand-logo {
  width: 138px; height: auto;
  display: block;
  opacity: 0;
  transform: scale(0.92);
  filter: drop-shadow(0 0 14px rgba(229,222,210,0.18));
  animation: pk-mark-in 1000ms cubic-bezier(0.2, 0.7, 0.2, 1) 150ms forwards;
}
@keyframes pk-mark-in {
  from { opacity: 0; transform: scale(0.92); }
  to   { opacity: 1; transform: scale(1); }
}

.brand-title {
  display: flex; align-items: center; justify-content: center;
  opacity: 0;
  animation: pk-title-in 500ms ease 1200ms forwards;
}
.brand-title .line {
  font-family: 'Montserrat', sans-serif;
  font-weight: 300;
  font-size: 22px;
  letter-spacing: 0.42em;
  color: var(--sand);
  text-transform: uppercase;
  padding-left: 0.42em;
  white-space: nowrap;
}
@keyframes pk-title-in {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: none; }
}

.brand-divider {
  width: 300px; height: auto; display: block;
  opacity: 0;
  transform-origin: center;
  filter: drop-shadow(0 0 6px rgba(213,164,109,0.45));
  animation: pk-divider-in 500ms cubic-bezier(0.2, 0.7, 0.2, 1) 1200ms forwards;
}
@keyframes pk-divider-in {
  from { opacity: 0; transform: scaleX(0); }
  to   { opacity: 1; transform: scaleX(1); }
}
@keyframes pk-splash-out {
  0%, 92% { opacity: 1; }
  100% { opacity: 0; visibility: hidden; }
}

/* === шаги === */
.steps {
  list-style: none; padding: 0; margin: 0;
  display: flex; flex-direction: column; gap: 10px;
}
.steps li {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px 16px;
  display: flex; align-items: center; gap: 14px;
  box-shadow: var(--shadow-soft);
}
.step-n {
  flex: 0 0 30px; height: 30px; border-radius: 15px;
  background: var(--gold-dim);
  color: var(--gold);
  border: 1px solid var(--gold-soft);
  display: flex; align-items: center; justify-content: center;
  font-weight: 400; font-size: 14px;
  letter-spacing: 0.02em;
}
.step-t { font-size: 15px; color: var(--fg); font-weight: 300; }

.consent {
  display: flex; gap: 10px; align-items: flex-start;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 12px 14px;
  font-size: 13px; color: var(--muted);
  line-height: 1.5; font-weight: 300;
}
.consent input {
  margin: 2px 0 0; transform: scale(1.1);
  accent-color: var(--gold);
}
.consent a { color: var(--gold); text-decoration: none; border-bottom: 1px solid var(--gold-soft); }

/* === кнопки === */
button.primary, .primary.as-button {
  background: var(--gold);
  color: var(--bg);
  border: 1px solid var(--gold);
  border-radius: 14px;
  padding: 15px 18px;
  font-weight: 500; font-size: 15px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer; text-align: center;
  display: inline-block; width: 100%;
  font-family: 'Montserrat', sans-serif;
  transition: transform 100ms ease, box-shadow 200ms ease, opacity 150ms ease;
  position: relative;
}
button.primary:hover, .primary.as-button:hover { box-shadow: var(--shadow-card); }
button.primary:active, .primary.as-button:active { transform: scale(0.985); }
button.primary[disabled] { opacity: 0.4; cursor: not-allowed; }

.secondary.as-button {
  background: transparent; color: var(--sand);
  border: 1px solid var(--gold-soft);
  border-radius: 14px;
  padding: 14px 18px; font-weight: 400; font-size: 14px;
  letter-spacing: 0.04em;
  text-align: center; display: inline-block; width: 100%;
  font-family: 'Montserrat', sans-serif;
  cursor: pointer;
  transition: color 150ms ease, border-color 150ms ease;
}
.secondary.as-button:hover { color: var(--gold); border-color: var(--gold); }

/* === модальная инструкция «как сфотографироваться» === */
.how { padding-left: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; list-style: none; }
.how li {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: 12px; padding: 12px 14px;
  font-size: 14px; line-height: 1.5; color: var(--muted); font-weight: 300;
}
.how li strong { color: var(--gold); font-weight: 400; }

/* подсказка-кнопка под инпутом фото */
.photo-hint {
  background: none; border: none; color: var(--gold);
  font-size: 13px; padding: 8px 12px; margin: 4px auto 0;
  text-decoration: none; border-bottom: 1px dashed var(--gold-soft);
  cursor: pointer; font-family: inherit; font-weight: 300;
  letter-spacing: 0.02em;
  align-self: center;
}
.photo-hint:hover { color: var(--light); border-bottom-color: var(--gold); }

.photo-actions { display: flex; flex-direction: column; gap: 10px; }
#photo-preview {
  width: 100%; max-height: 42dvh;
  object-fit: contain;
  border-radius: 14px;
  background: #000;
  box-shadow: var(--shadow-card);
}

/* Прогресс-копирайт — отдельной строкой под CTA-кнопкой, не внутри неё.
   Внутри кнопки длинная фраза («Сравниваем с эталоном Правила 87%») ломает layout
   на две строки и кнопка «расходится». Снаружи — стабильно при любой длине. */
.model-progress {
  margin: -2px 0 0;
  text-align: center;
  font-size: 11px; font-weight: 300;
  letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--muted-2);
  line-height: 1.4;
  min-height: 16px;
}

/* === camera-live === */
.camera-stage {
  width: 100%;
  background: #000;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--shadow-card);
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 40dvh;
}
#camera-video {
  display: block;
  width: 100%;
  height: auto;
  max-height: 65dvh;
  background: #000;
  object-fit: contain;
}
.camera-status { text-align: center; color: var(--muted); font-size: 13px; min-height: 18px; }
.camera-error { color: var(--gold); text-align: center; }
.camera-controls { display: flex; flex-direction: column; gap: 10px; }
.camera-controls > button { width: 100%; }

/* === processing === */
.screen[data-screen="processing"] { align-items: center; padding-top: 56px; text-align: center; }
.screen[data-screen="card"] { gap: 12px; }
.processing-spinner {
  width: 56px; height: 56px; border-radius: 50%;
  border: 1.5px solid var(--line);
  border-top-color: var(--gold);
  animation: pk-spin 1100ms linear infinite;
  margin: 12px auto;
}
@keyframes pk-spin { to { transform: rotate(360deg); } }

/* === pose-fail === */
.screen[data-screen="pose-fail"] .secondary.as-button { width: 100%; }

/* === квиз === */
.quiz-progress {
  font-size: 12px; color: var(--muted-2);
  display: flex; align-items: center; gap: 12px;
  letter-spacing: 0.06em; text-transform: uppercase;
}
.quiz-bar { flex: 1; height: 1px; background: var(--line); border-radius: 1px; overflow: hidden; }
#quiz-bar-fill { height: 100%; background: var(--gold); width: 0%; transition: width 320ms cubic-bezier(0.2,0.8,0.2,1); }
.quiz-options { display: flex; flex-direction: column; gap: 10px; }
.quiz-option {
  background: var(--surface); color: var(--fg);
  border: 1px solid var(--line); border-radius: 14px;
  padding: 14px 16px; font-size: 15px; line-height: 1.45;
  text-align: left; cursor: pointer; font-weight: 300;
  font-family: 'Montserrat', sans-serif;
  transition: border-color 150ms ease, transform 100ms ease;
}
.quiz-option:hover { border-color: var(--gold-soft); }
.quiz-option:active { transform: scale(0.99); background: var(--surface-2); }

/* === карточка === */
.card-frame {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 22px 18px 18px;
  display: flex; flex-direction: column; align-items: center;
  gap: 6px;
  position: relative;
  box-shadow: var(--shadow-card);
  overflow: hidden;
}
.card-frame::before {
  content: "";
  position: absolute; top: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  opacity: 0.7;
}
.card-carousel {
  width: 100%; max-width: 320px;
  margin: 2px 0 4px;
  display: flex; flex-direction: column; align-items: stretch;
  gap: 12px;
}
.card-viewport {
  width: 100%;
  overflow: hidden;
  border-radius: 14px;
  position: relative;
}
.card-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: 34px; height: 34px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(15, 15, 15, 0.55);
  border: 1px solid var(--gold-soft);
  border-radius: 50%;
  color: var(--sand);
  cursor: pointer;
  padding: 0;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  transition: background 160ms ease, color 160ms ease, border-color 160ms ease, transform 100ms ease;
}
.card-arrow-prev { left: 8px; }
.card-arrow-next { right: 8px; }
.card-arrow:hover { color: var(--gold); border-color: var(--gold); background: rgba(15, 15, 15, 0.75); }
.card-arrow:active { transform: translateY(-50%) scale(0.92); }
.card-arrow:focus-visible { outline: 2px solid var(--gold-soft); outline-offset: 2px; }
.card-track {
  display: flex;
  width: 100%;
  transition: transform 360ms cubic-bezier(0.2, 0.8, 0.2, 1);
  will-change: transform;
  touch-action: pan-y;
}
.card-track[data-dragging="true"] { transition: none; }
.card-slide {
  flex: 0 0 100%;
  width: 100%;
  display: flex; align-items: center; justify-content: center;
  touch-action: pan-y;
}
/* iOS WebView съедает горизонтальный жест на дочерних canvas/svg, если у них
   touch-action не задан — pointermove не доходит до моих listeners, и свайп
   назад с слайда 2 ломается. Принудительно отдаём горизонтальное движение JS. */
.card-slide canvas, .card-slide svg, .card-silhouette, .card-archetype { touch-action: pan-y; }
.card-silhouette {
  width: 100%;
  aspect-ratio: 4 / 5;
  max-height: 36dvh;
  display: flex; align-items: center; justify-content: center;
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  background: var(--bg);
  box-shadow: inset 0 0 0 1px var(--gold-dim);
}
.card-archetype {
  width: 100%;
  aspect-ratio: 4 / 5;
  max-height: 36dvh;
  border-radius: 14px;
  overflow: hidden;
  background: #0a0a0a;
  box-shadow: inset 0 0 0 1px var(--gold-dim);
}
.card-archetype canvas {
  width: 100%; height: 100%;
  display: block;
}
.card-dots {
  display: flex; align-items: center; justify-content: center;
  gap: 8px;
  padding: 0;
}
.card-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--muted-2);
  border: none;
  padding: 0;
  cursor: pointer;
  opacity: 0.55;
  transition: background 180ms ease, opacity 180ms ease, transform 180ms ease;
}
.card-dot[data-active="true"] {
  background: var(--gold);
  opacity: 1;
  transform: scale(1.45);
}
.card-dot:focus-visible {
  outline: 2px solid var(--gold-soft);
  outline-offset: 3px;
}
.card-silhouette svg {
  width: 110px; height: 220px;
  background: transparent;
}
.card-silhouette canvas { width: 100%; height: 100%; display: block; object-fit: cover; }
.bone { stroke: var(--gold); stroke-width: 2.5; stroke-linecap: round; opacity: 0.95; }
.head { fill: var(--gold); opacity: 0.95; }
.joint { fill: var(--light); }
.card-index {
  font-family: 'Montserrat', sans-serif;
  font-size: 64px; font-weight: 200; line-height: 1;
  letter-spacing: -0.02em;
  color: var(--gold);
  margin-top: 6px;
}
.card-index-of {
  font-size: 16px; color: var(--muted-2); font-weight: 300; margin-left: 6px;
  letter-spacing: 0;
}
.card-index-label {
  font-size: 13px; letter-spacing: 0.30em; text-transform: uppercase;
  color: var(--sand); margin-top: 14px; font-weight: 500;
}
.card-scale-label {
  font-size: 10px; letter-spacing: 0.42em; text-transform: uppercase;
  color: var(--muted-2); margin-top: 8px; font-weight: 400;
}

/* Блок «Выявлено в позе» — конкретные находки SAPO человеческим языком.
   Это loss aversion frame: юзер видит свои реальные проблемы (плечи, голова, таз),
   и понимает что мастер увидит то же самое. Без блока карточка = «и что?». */
.card-findings {
  width: 100%;
  margin-top: 14px;
  padding: 12px 14px;
  background: rgba(245, 245, 239, 0.03);
  border: 1px solid var(--line);
  border-radius: 12px;
}
.card-findings-label {
  font-size: 10px; letter-spacing: 0.42em; text-transform: uppercase;
  color: var(--gold); font-weight: 400;
  margin-bottom: 8px;
}
.card-findings-list {
  list-style: none; padding: 0; margin: 0;
  display: flex; flex-direction: column; gap: 6px;
}
.card-findings-list li {
  font-size: 14px; line-height: 1.45;
  color: var(--sand); font-weight: 300;
  padding-left: 18px;
  position: relative;
}
.card-findings-list li::before {
  content: '·';
  position: absolute; left: 6px;
  color: var(--gold); font-weight: 500;
  font-size: 18px; line-height: 1;
}

/* Тонкие текстовые ссылки под card-actions — «о сеансе» / «пройти ещё раз». */
.card-links {
  display: flex; align-items: center; justify-content: center;
  gap: 8px; margin-top: 4px;
  font-size: 12px;
}
.card-link {
  background: none; border: none; padding: 4px 6px;
  color: var(--muted); font-family: inherit; font-weight: 300;
  font-size: 12px; cursor: pointer;
  text-decoration: underline; text-underline-offset: 3px;
  text-decoration-color: var(--muted-2);
}
.card-link:hover { color: var(--gold); text-decoration-color: var(--gold-soft); }
.card-disclaimer {
  font-size: 10px; color: var(--muted-2); text-align: center;
  margin-top: 12px; opacity: 0.7; letter-spacing: 0.04em;
  line-height: 1.45; font-weight: 300;
}
.card-scale-info {
  background: none; border: none; color: var(--muted);
  font-size: 12px; padding: 4px 8px; margin-top: 4px;
  text-decoration: underline; text-underline-offset: 3px;
  cursor: pointer; font-family: inherit; font-weight: 300;
}
.card-scale-info:active { color: var(--gold); }

.modal {
  position: fixed; inset: 0; z-index: 100;
  display: flex; align-items: flex-end; justify-content: center;
}
.modal[hidden] { display: none; }
.modal-backdrop {
  position: absolute; inset: 0;
  background: rgba(0,0,0,0.65);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}
.modal-card {
  position: relative;
  width: 100%; max-width: 560px;
  background: var(--surface);
  border-top: 1px solid var(--gold-soft);
  border-radius: 18px 18px 0 0;
  padding: 18px 20px max(20px, env(safe-area-inset-bottom));
  box-shadow: 0 -16px 40px rgba(0,0,0,0.7);
  max-height: 80dvh;
  overflow-y: auto;
  animation: pk-modal-up 240ms ease both;
}
@keyframes pk-modal-up {
  from { transform: translateY(20px); opacity: 0.6; }
  to   { transform: translateY(0);    opacity: 1;   }
}
.modal-head {
  display: flex; align-items: center; justify-content: space-between;
  font-weight: 400; font-size: 16px; margin-bottom: 14px;
  letter-spacing: 0.04em; text-transform: uppercase; color: var(--gold);
}
.modal-close {
  background: none; border: none; color: var(--muted);
  font-size: 26px; line-height: 1; padding: 4px 8px;
  cursor: pointer;
}
.modal-body { display: flex; flex-direction: column; gap: 10px; }
.modal-foot { margin-top: 14px; text-align: center; color: var(--muted-2); }

/* Цветовая полоса шкалы асимметрии: золото (свободное, 0) → песок → кирпичный (каменное, 100).
   Frame асимметрии: низкий = хорошо, высокий = плохо. Поэтому слева светлый, справа тёмный. */
.scale-gradient-bar {
  position: relative;
  height: 14px;
  margin: 0 0 16px;
  border-radius: 7px;
  background: linear-gradient(90deg, #E0C58A 0%, #BFA98A 35%, #8C5A3C 72%, #5C2A26 100%);
  box-shadow: inset 0 0 0 1px var(--gold-dim);
}
.scale-gradient-mark {
  position: absolute; top: 16px;
  font-size: 10px; letter-spacing: 0.06em;
  color: var(--muted); font-variant-numeric: tabular-nums;
}
.scale-gradient-mark-low { left: 0; }
.scale-gradient-mark-high { right: 0; }
.scale-gradient-caption {
  position: absolute; left: 50%; top: 16px;
  transform: translateX(-50%);
  font-size: 10px; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--gold); font-weight: 400;
  white-space: nowrap;
}
.scale-gradient-bar + .modal-body { margin-top: 26px; }
.scale-row {
  display: grid; grid-template-columns: 56px 1fr;
  gap: 10px; align-items: start;
  padding: 10px 12px; border-radius: 12px;
  background: rgba(245,245,239,0.02);
  border: 1px solid var(--line);
}
.scale-row[data-current="true"] {
  background: var(--gold-dim);
  border-color: var(--gold);
}
.scale-range { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.scale-row-word { font-weight: 400; font-size: 15px; line-height: 1.2; color: var(--sand); }
.scale-row[data-current="true"] .scale-row-word { color: var(--gold); }
.scale-row-desc { font-size: 13px; color: var(--muted); line-height: 1.5; margin-top: 3px; font-weight: 300; }

.card-actions {
  display: flex; flex-direction: column; gap: 10px;
  margin-top: 14px;
}

/* === история === */
.history-list { display: flex; flex-direction: column; gap: 10px; }
.history-item {
  display: flex; align-items: center; gap: 14px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: 14px; padding: 10px 14px 10px 10px;
  cursor: pointer; font: inherit; color: inherit; text-align: left;
  width: 100%; font-family: 'Montserrat', sans-serif;
  transition: border-color 150ms ease, transform 100ms ease;
}
.history-item:hover { border-color: var(--gold-soft); }
.history-item:active { transform: scale(0.995); background: var(--surface-2); }
.history-thumb {
  flex: 0 0 56px; width: 56px; height: 72px;
  border-radius: 8px; overflow: hidden;
  background: var(--bg);
  border: 1px solid var(--line);
}
.history-thumb img {
  width: 100%; height: 100%; object-fit: cover;
  display: block;
}
.history-meta { display: flex; flex-direction: column; gap: 2px; flex: 1; }
.history-index {
  font-size: 22px; font-weight: 200; letter-spacing: -0.01em;
  color: var(--gold);
}
.history-of { font-size: 13px; color: var(--muted-2); margin-left: 4px; font-weight: 300; }
.history-scale { font-size: 13px; color: var(--sand); letter-spacing: 0.005em; font-weight: 300; }
.history-date { font-size: 11px; color: var(--muted-2); letter-spacing: 0.02em; font-weight: 300; }

/* === Кусок 4: раскрывашка «Что такое Правило» на welcome + модалка === */
.welcome-pravilo-link {
  display: inline-block;
  margin: 8px 0 0;
  padding: 0;
  background: none;
  border: none;
  font: inherit;
  font-size: 13px;
  color: var(--gold);
  text-decoration: none;
  letter-spacing: 0.01em;
  cursor: pointer;
  border-bottom: 1px dashed var(--gold-soft);
  align-self: flex-start;
}
.welcome-pravilo-link:active { opacity: 0.7; }

/* === card-level-copy + блок «По результатам скрининга» (entry + recommended) === */
.card-level-copy {
  margin: 14px 0 0;
  padding: 0 6px;
  font-size: 13px;
  color: var(--sand);
  line-height: 1.5;
  text-align: center;
  font-weight: 300;
}
.card-level-copy[hidden] { display: none; }

.card-complex {
  margin: 16px 0 6px;
  padding: 14px 14px 12px;
  border: 1px solid var(--gold-soft);
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(224,185,130,0.05), rgba(224,185,130,0.02));
  display: flex; flex-direction: column; gap: 12px;
}
.card-complex-eyebrow {
  font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--gold); font-weight: 400;
}
.card-offer-row {
  display: flex; flex-direction: column; gap: 2px;
  padding: 10px 0;
  border-top: 1px solid var(--line);
}
.card-offer-row:first-of-type { border-top: none; padding-top: 0; }
.card-offer-row[hidden] { display: none; }
.card-offer-name {
  font-size: 16px; color: var(--sand); font-weight: 400; letter-spacing: 0.005em;
}
.card-offer-meta {
  font-size: 13px; color: var(--gold); letter-spacing: 0.01em;
}
.card-offer-lede {
  margin-top: 4px;
  font-size: 13px; color: var(--muted); line-height: 1.45; font-weight: 300;
}
.card-offer-where {
  margin-top: 4px;
  font-size: 12px; color: var(--gold); letter-spacing: 0.01em; line-height: 1.4;
}
.card-offer-recommended .card-offer-name { color: var(--gold); }
.card-offer-recommended::before {
  content: "под твой индекс";
  font-size: 9px; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--gold); font-weight: 400;
  margin-bottom: 4px;
}

/* Видимая ссылка на сайт под privacy-pledge */
a.card-link {
  display: block;
  margin-top: 4px;
  text-align: center;
  font-size: 13px;
  color: var(--gold);
  text-decoration: none;
  letter-spacing: 0.01em;
  padding: 8px 0;
  border-bottom: 1px dashed var(--gold-soft);
  cursor: pointer;
}
a.card-link:active { opacity: 0.7; }

.quiz-hint {
  margin-top: 18px;
  text-align: center;
}
