/* =========================================================================
   Лендинг психолога — общие стили (страница 1 + страница 2)
   Концепция: «тихая премиальность», тёплый редакционный минимализм.
   Mobile-first. Все ключевые значения вынесены в CSS-переменные ниже —
   меняйте палитру/шрифты в одном месте.
   ========================================================================= */

/* ----------------------------------------------------------------------
   1. ПАЛИТРА И ТОКЕНЫ
   ---------------------------------------------------------------------- */
:root {
  /* Фон: тёплый кремовый / айвори, НЕ чисто белый */
  --bg:          #F7F1E7;
  --bg-warm:     #F2E9DA;   /* чуть глубже — для деликатных плашек */
  --bg-card:     #FBF6EE;   /* светлее фона — карточки/плейсхолдеры */

  /* Текст: глубокий тёплый графит, НЕ чёрный */
  --ink:         #322C25;
  --ink-soft:    #6E655A;   /* вторичный текст, подписи */
  --ink-faint:   #9C9183;   /* подписи плейсхолдеров, подвал */

  /* Акцент: благородная приглушённая терракота */
  --accent:      #B0604A;
  --accent-deep: #964C3A;   /* hover / нажатие */

  /* Второстепенный глубокий тон: тёмно-винный (для тонких акцентов) */
  --wine:        #7C3142;

  /* Линии и разделители */
  --line:        #E4D9C7;
  --line-soft:   #ECE3D4;

  /* Шрифты */
  --font-display: 'Cormorant', Georgia, 'Times New Roman', serif;
  --font-body:    'Golos Text', system-ui, -apple-system, sans-serif;

  /* Ритм / ширина колонки */
  --measure: 680px;       /* макс. ширина читаемой колонки */
  --measure-wide: 760px;  /* для крупных блоков (кнопки, плашки) */

  /* Радиусы и тени (мягкие, дорогие) */
  --r-sm: 10px;
  --r-md: 16px;
  --r-lg: 24px;
  --shadow-soft: 0 18px 50px -28px rgba(60, 40, 28, 0.35);
  --shadow-btn:  0 14px 30px -14px rgba(150, 76, 58, 0.55);
}

/* ----------------------------------------------------------------------
   2. БАЗА / СБРОС
   ---------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background-color: var(--bg);
  /* Деликатный тёплый меш-градиент — едва заметная атмосфера */
  background-image:
    radial-gradient(60% 50% at 18% 8%,  rgba(176, 96, 74, 0.06) 0%, transparent 60%),
    radial-gradient(55% 45% at 88% 22%, rgba(124, 49, 66, 0.05) 0%, transparent 55%),
    radial-gradient(70% 60% at 50% 100%, rgba(176, 96, 74, 0.045) 0%, transparent 60%);
  background-attachment: fixed;
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 19px;
  line-height: 1.74;
  font-weight: 400;
  letter-spacing: 0.002em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* Едва заметное тёплое зерно поверх фона */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.5;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.035'/%3E%3C/svg%3E");
}

img { max-width: 100%; display: block; }

a { color: inherit; }

/* ----------------------------------------------------------------------
   3. РАЗМЕТКА / КОЛОНКА
   ---------------------------------------------------------------------- */
.page {
  position: relative;
  z-index: 1;
  width: 100%;
  padding: clamp(40px, 9vw, 88px) 22px clamp(56px, 10vw, 110px);
}

.wrap {
  max-width: var(--measure);
  margin-inline: auto;
}

/* Вертикальный ритм между абзацами читаемой колонки */
.flow > * + * { margin-top: 1.45em; }

/* ----------------------------------------------------------------------
   4. ТИПОГРАФИКА
   ---------------------------------------------------------------------- */
h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.12;
  letter-spacing: -0.005em;
  color: var(--ink);
  margin: 0;
  text-wrap: balance;
}

/* H1 — крупный распашной заголовок */
.h1 {
  font-size: clamp(2.15rem, 7.2vw, 3.5rem);
  line-height: 1.08;
  font-weight: 500;
  letter-spacing: -0.012em;
}

/* Подзаголовок под H1 — спокойный, серифный курсив */
.subhead {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 500;
  font-size: clamp(1.3rem, 4vw, 1.7rem);
  line-height: 1.32;
  color: var(--ink-soft);
  margin: 0;
  text-wrap: balance;
}

/* Подзаголовки-якоря внутри текста */
.anchor {
  font-size: clamp(1.55rem, 4.6vw, 2.05rem);
  line-height: 1.18;
  margin: 0;
}

p { margin: 0; }

/* Абзац с лёгким приглушением — для пояснений мелче */
.note {
  font-size: 0.92em;
  color: var(--ink-soft);
  line-height: 1.66;
}

/* Акцентное выделение ключевых фраз */
.em {
  color: var(--accent);
  font-weight: 500;
}

/* Деликатное акцентное подчёркивание под текстом */
.mark {
  background-image: linear-gradient(to top,
     rgba(176, 96, 74, 0.20) 0%, rgba(176, 96, 74, 0.20) 30%, transparent 30%);
  padding: 0 0.04em;
}

/* Крупная акцентная строка (две выделенные строки в тексте) */
.lead-accent {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 4.4vw, 2rem);
  line-height: 1.28;
  font-weight: 500;
  color: var(--ink);
  text-wrap: balance;
}
.lead-accent .em { color: var(--accent); }

/* ----------------------------------------------------------------------
   5. ФОТО ЭКСПЕРТА
   ---------------------------------------------------------------------- */
.portrait {
  margin: 0 auto clamp(28px, 5vw, 40px);
}

/* Круглое фото (страница 1) */
.portrait--round {
  width: clamp(180px, 48vw, 240px);
  aspect-ratio: 1;
  border-radius: 50%;
}

/* Мягкий прямоугольник со скруглением (страница 2) */
.portrait--soft {
  width: clamp(220px, 62vw, 320px);
  aspect-ratio: 4 / 5;
  border-radius: var(--r-lg);
}

/* Плейсхолдер-фото: аккуратный блок с подписью */
.ph-photo {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-align: center;
  background: var(--bg-card);
  border: 1.5px dashed var(--line);
  color: var(--ink-faint);
  box-shadow: var(--shadow-soft);
}
.ph-photo svg { width: 30px; height: 30px; opacity: 0.55; }
.ph-photo .ph-label {
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 500;
  max-width: 80%;
}

/* ----------------------------------------------------------------------
   6. РАЗДЕЛИТЕЛИ
   ---------------------------------------------------------------------- */
.divider {
  border: 0;
  height: 1px;
  width: 100%;
  margin: clamp(36px, 7vw, 56px) auto;
  background: linear-gradient(to right, transparent, var(--line) 18%, var(--line) 82%, transparent);
}

/* Разделитель с центральным «ромбом» — чуть нарядней */
.divider-dot {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin: clamp(36px, 7vw, 56px) auto;
  color: var(--accent);
}
.divider-dot::before,
.divider-dot::after {
  content: "";
  height: 1px;
  width: min(120px, 26vw);
  background: linear-gradient(to right, transparent, var(--line));
}
.divider-dot::after { transform: scaleX(-1); }
.divider-dot span {
  width: 6px; height: 6px;
  transform: rotate(45deg);
  background: var(--accent);
  opacity: 0.7;
}

/* ----------------------------------------------------------------------
   7. КНОПКИ
   ---------------------------------------------------------------------- */
.btn {
  -webkit-appearance: none;
  appearance: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  max-width: 100%;          /* на всю ширину текстовой колонки */
  min-height: 60px;
  padding: 19px 30px;
  border: 0;
  border-radius: var(--r-md);
  font-family: var(--font-body);
  font-size: 1.08rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  text-transform: none;     /* спокойно, без капслок-крика */
  text-decoration: none;
  cursor: pointer;
  color: #FFFFFF;
  background: var(--accent);
  box-shadow: var(--shadow-btn);
  transition: transform 0.35s cubic-bezier(0.22,1,0.36,1),
              background-color 0.3s ease,
              box-shadow 0.35s ease,
              filter 0.3s ease;
}
.btn:hover {
  background: var(--accent-deep);
  transform: translateY(-2px);
  box-shadow: 0 22px 40px -14px rgba(150, 76, 58, 0.62);
}
.btn:active {
  transform: translateY(0);
  filter: brightness(0.95);
  box-shadow: 0 10px 22px -14px rgba(150, 76, 58, 0.55);
}
.btn svg { width: 22px; height: 22px; flex: none; }

/* Кнопка MAX — залита тёплым янтарём / охрой (в гамме сайта) */
.btn--max {
  background: #B0884A;
  color: #FFFFFF;
  box-shadow: 0 14px 30px -14px rgba(176, 136, 74, 0.55);
}
.btn--max:hover {
  background: #997436;       /* чуть глубже янтаря */
  transform: translateY(-2px);
  box-shadow: 0 22px 40px -14px rgba(176, 136, 74, 0.6);
}
.btn--max:active {
  transform: translateY(0);
  filter: brightness(0.95);
  box-shadow: 0 10px 22px -14px rgba(176, 136, 74, 0.55);
}

/* Обёртка кнопки — центрирование + воздух */
.btn-row {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  margin-top: clamp(34px, 6vw, 48px);
}

/* ----------------------------------------------------------------------
   8. СПИСКИ
   ---------------------------------------------------------------------- */
.list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.list li {
  position: relative;
  padding-left: 30px;
  line-height: 1.6;
}
.list li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 0.72em;
  width: 7px; height: 7px;
  transform: rotate(45deg);
  background: var(--accent);
}

/* ----------------------------------------------------------------------
   9. ПЛАШКИ / КАРТОЧКИ
   ---------------------------------------------------------------------- */
/* Мягкая честная ремарка */
.plaque {
  background: var(--bg-warm);
  border: 1px solid var(--line-soft);
  border-left: 3px solid var(--accent);
  border-radius: var(--r-md);
  padding: clamp(22px, 5vw, 30px) clamp(22px, 5vw, 32px);
  font-size: 0.98em;
  line-height: 1.66;
}

/* Цена */
.price {
  text-align: center;
  margin: clamp(28px, 5vw, 38px) 0 0;
}
.price .price-label {
  font-size: 0.82rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
.price .price-value {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 8vw, 3.4rem);
  font-weight: 500;
  color: var(--accent);
  line-height: 1;
  margin-top: 6px;
}

/* Плейсхолдер текста / отзывов */
.ph-block {
  background: var(--bg-card);
  border: 1.5px dashed var(--line);
  border-radius: var(--r-md);
  padding: clamp(26px, 6vw, 40px);
  color: var(--ink-faint);
  text-align: center;
}
.ph-block .ph-tag {
  display: inline-block;
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--accent);
  background: rgba(176, 96, 74, 0.08);
  border-radius: 999px;
  padding: 5px 13px;
  margin-bottom: 14px;
}
.ph-block .ph-lines {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 6px;
}
.ph-block .ph-lines i {
  display: block;
  height: 11px;
  border-radius: 6px;
  background: linear-gradient(to right, var(--line), var(--line-soft));
}
.ph-block .ph-lines i:nth-child(2) { width: 92%; }
.ph-block .ph-lines i:nth-child(3) { width: 78%; }
.ph-block .ph-caption {
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  margin-top: 16px;
  font-style: italic;
}

/* Черновой текст-рыба */
.draft {
  position: relative;
  color: var(--ink-soft);
  background: var(--bg-warm);
  border: 1px dashed var(--line);
  border-radius: var(--r-md);
  padding: clamp(22px, 5vw, 30px);
  font-size: 0.96em;
}
.draft::before {
  content: "ЧЕРНОВИК · ЗАМЕНИТЬ";
  position: absolute;
  top: -10px; left: 18px;
  font-family: var(--font-body);
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  font-weight: 600;
  color: var(--ink-faint);
  background: var(--bg);
  padding: 2px 9px;
  border-radius: 999px;
}

/* Инлайн-плейсхолдер в строке (название, цена и т.п.) */
.ph-inline {
  display: inline;
  color: var(--ink-faint);
  background: rgba(124, 49, 66, 0.07);
  border-bottom: 1px dashed var(--line);
  border-radius: 3px;
  padding: 1px 6px;
}

/* ----------------------------------------------------------------------
   10. FAQ (аккордеон)
   ---------------------------------------------------------------------- */
.faq { display: flex; flex-direction: column; }
.faq-item {
  border-bottom: 1px solid var(--line);
}
.faq-item:first-child { border-top: 1px solid var(--line); }
.faq-q {
  width: 100%;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  text-align: left;
  background: none;
  border: 0;
  cursor: pointer;
  padding: 22px 2px;
  font-family: var(--font-body);
  font-size: 1.06rem;
  font-weight: 500;
  line-height: 1.4;
  color: var(--ink);
}
.faq-q .faq-icon {
  flex: none;
  width: 22px; height: 22px;
  margin-top: 3px;
  position: relative;
  transition: transform 0.4s cubic-bezier(0.22,1,0.36,1);
}
.faq-q .faq-icon::before,
.faq-q .faq-icon::after {
  content: "";
  position: absolute;
  background: var(--accent);
  border-radius: 2px;
  top: 50%; left: 50%;
}
.faq-q .faq-icon::before { width: 16px; height: 1.5px; transform: translate(-50%,-50%); }
.faq-q .faq-icon::after  { width: 1.5px; height: 16px; transform: translate(-50%,-50%); transition: transform 0.4s ease, opacity 0.3s ease; }
.faq-item.open .faq-icon { transform: rotate(180deg); }
.faq-item.open .faq-icon::after { transform: translate(-50%,-50%) scaleY(0); opacity: 0; }

.faq-a {
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.45s cubic-bezier(0.4,0,0.2,1);
}
.faq-a-inner {
  padding: 0 2px 24px;
  color: var(--ink-soft);
  line-height: 1.68;
}

/* ----------------------------------------------------------------------
   11. ПОДВАЛ
   ---------------------------------------------------------------------- */
.footer {
  max-width: var(--measure);
  margin: clamp(48px, 9vw, 80px) auto 0;
  padding-top: 28px;
  border-top: 1px solid var(--line);
  font-size: 0.78rem;
  line-height: 1.7;
  color: var(--ink-faint);
  text-align: center;
}
.footer a { color: var(--ink-soft); text-decoration: underline; text-underline-offset: 3px; }
.footer a:hover { color: var(--accent); }
.footer .footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 18px;
  margin-top: 12px;
}

/* P.S. деликатно */
.ps {
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(1.15rem, 3.4vw, 1.4rem);
  line-height: 1.5;
  color: var(--ink-soft);
  text-wrap: pretty;
}
.ps .ps-tag {
  font-family: var(--font-body);
  font-style: normal;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  display: block;
  margin-bottom: 12px;
}

/* ----------------------------------------------------------------------
   12. АНИМАЦИЯ ПОЯВЛЕНИЯ (мягкий подъём, staggered)
   ВАЖНО: непрозрачность всегда = 1. Анимируется только лёгкий сдвиг вверх,
   поэтому контент ВИДЕН в любом состоянии (включая «замороженные» вкладки
   и предпросмотры) и страница не может остаться пустой.
   ---------------------------------------------------------------------- */
.reveal { opacity: 1; }

@media (prefers-reduced-motion: no-preference) {
  @keyframes om-rise {
    from { transform: translateY(20px); }
    to   { transform: none; }
  }
  .reveal {
    animation: om-rise 0.85s cubic-bezier(0.22,1,0.36,1) both;
    will-change: transform;
  }
  /* Лёгкая staggered-задержка для верхних блоков (каскад при загрузке) */
  .flow > *:nth-child(1)  { animation-delay: 0.00s; }
  .flow > *:nth-child(2)  { animation-delay: 0.07s; }
  .flow > *:nth-child(3)  { animation-delay: 0.14s; }
  .flow > *:nth-child(4)  { animation-delay: 0.21s; }
  .flow > *:nth-child(5)  { animation-delay: 0.28s; }
  .flow > *:nth-child(6)  { animation-delay: 0.34s; }
  .flow > *:nth-child(7)  { animation-delay: 0.40s; }
  .flow > *:nth-child(8)  { animation-delay: 0.46s; }
  .flow > *:nth-child(9)  { animation-delay: 0.52s; }
  .flow > *:nth-child(n+10) { animation-delay: 0.58s; }
}

/* ----------------------------------------------------------------------
   13. АДАПТИВ
   ---------------------------------------------------------------------- */
@media (min-width: 720px) {
  body { font-size: 20px; }
}

@media (max-width: 380px) {
  body { font-size: 18px; }
}
