/* ============================================================
   Вадим Ходаев — личный сайт
   Палитра из референса: #06010D / #1516C7 / #9949FF / #F9F3FF
   Шрифты: Unbounded (заголовки) + Manrope (текст) + JetBrains Mono (метки)
   ============================================================ */

:root {
  --bg: #06010D;
  --surface: #0E0819;
  --surface-2: #150C24;
  --border: #251A3A;
  --violet: #9949FF;
  --blue: #1516C7;
  --text: #F9F3FF;
  --muted: #9C92B8;
  --radius: 18px;
  --font-display: 'Unbounded', sans-serif;
  --font-body: 'Manrope', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  overflow-x: hidden;
}

::selection { background: var(--violet); color: var(--bg); }

a { color: inherit; text-decoration: none; }

/* --- Фоновое свечение (сигнатурный элемент) --- */
.glow {
  position: absolute;
  pointer-events: none;
  filter: blur(120px);
  opacity: 0.55;
  z-index: 0;
}
.glow-top {
  top: -220px; right: -160px;
  width: 640px; height: 640px;
  background: radial-gradient(circle at 40% 40%, var(--violet) 0%, var(--blue) 45%, transparent 70%);
}

/* --- Шапка --- */
.header {
  position: relative; z-index: 10;
  max-width: 1120px; margin: 0 auto;
  padding: 26px 24px;
  display: flex; justify-content: space-between; align-items: center;
}
.logo {
  font-family: var(--font-display);
  font-weight: 800; font-size: 22px; letter-spacing: 0.02em;
}
.logo-dot { color: var(--violet); }
.nav { display: flex; gap: 28px; align-items: center; font-weight: 500; font-size: 15px; }
.nav a:not(.nav-cta) { color: var(--muted); transition: color 0.2s; }
.nav a:not(.nav-cta):hover { color: var(--text); }
.nav-cta {
  padding: 10px 20px;
  border: 1px solid var(--violet);
  border-radius: 100px;
  color: var(--text);
  transition: background 0.2s, box-shadow 0.2s;
}
.nav-cta:hover { background: rgba(153, 73, 255, 0.15); box-shadow: 0 0 24px rgba(153, 73, 255, 0.35); }

/* --- Контейнер --- */
.container { max-width: 1120px; margin: 0 auto; padding: 0 24px; position: relative; z-index: 1; }

/* --- Моно-метка (eyebrow) --- */
.eyebrow {
  font-family: var(--font-mono);
  font-size: 13px; letter-spacing: 0.12em;
  color: var(--violet);
  text-transform: uppercase;
  display: block; margin-bottom: 18px;
}

/* --- Герой --- */
.hero { padding: 90px 0 110px; }
.hero h1 {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(34px, 5.4vw, 62px);
  line-height: 1.12;
  letter-spacing: -0.01em;
  max-width: 860px;
}
.accent {
  background: linear-gradient(100deg, var(--violet), #C79CFF 60%, var(--violet));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-sub {
  margin-top: 26px;
  max-width: 560px;
  color: var(--muted);
  font-size: 19px;
}
.hero-actions { margin-top: 40px; display: flex; gap: 18px; flex-wrap: wrap; align-items: center; }

/* --- Кнопки --- */
.btn {
  display: inline-block;
  font-family: var(--font-body); font-weight: 700; font-size: 16px;
  padding: 16px 34px;
  border-radius: 100px;
  border: none; cursor: pointer;
  background: linear-gradient(100deg, var(--blue), var(--violet));
  color: var(--text);
  transition: box-shadow 0.25s, transform 0.15s;
}
.btn:hover { box-shadow: 0 0 40px rgba(153, 73, 255, 0.5); transform: translateY(-1px); }
.btn-ghost {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--muted);
}
.btn-ghost:hover { border-color: var(--violet); color: var(--text); box-shadow: none; }
.btn-small { padding: 10px 22px; font-size: 14px; }

/* --- Секции --- */
.section { padding: 90px 0; }
.section-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(26px, 3.4vw, 40px);
  margin-bottom: 48px;
  max-width: 700px;
}

/* --- Услуги --- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}
.service-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px;
  transition: border-color 0.25s, transform 0.25s, box-shadow 0.25s;
}
.service-card:hover {
  border-color: var(--violet);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(153, 73, 255, 0.15);
}
.service-num {
  font-family: var(--font-mono);
  font-size: 13px; color: var(--violet);
  display: block; margin-bottom: 20px;
}
.service-card h3 {
  font-family: var(--font-display);
  font-weight: 600; font-size: 19px;
  margin-bottom: 12px;
}
.service-card p { color: var(--muted); font-size: 15px; }

/* --- Блог --- */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}
.post-card {
  display: block;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color 0.25s, transform 0.25s;
}
.post-card:hover { border-color: var(--violet); transform: translateY(-4px); }
.post-cover {
  width: 100%; aspect-ratio: 16 / 9;
  object-fit: cover; display: block;
  background: linear-gradient(120deg, var(--surface-2), #1B0F33);
}
.post-cover-placeholder {
  width: 100%; aspect-ratio: 16 / 9;
  background: linear-gradient(120deg, #12081F 0%, #1E0E3C 50%, #12081F 100%);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-weight: 800; font-size: 28px;
  color: rgba(153, 73, 255, 0.45);
}
.post-body { padding: 24px; }
.post-date { font-family: var(--font-mono); font-size: 12px; color: var(--muted); display: block; margin-bottom: 10px; }
.post-card h3 { font-size: 18px; font-weight: 700; line-height: 1.4; margin-bottom: 10px; }
.post-card p { color: var(--muted); font-size: 14px; }
.blog-empty { color: var(--muted); }

/* --- Статья --- */
.article { max-width: 760px; margin: 0 auto; padding: 60px 24px 90px; }
.article h1 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.25;
  margin-bottom: 16px;
}
.article-cover { width: 100%; border-radius: var(--radius); margin: 30px 0; }
.article-content h2 {
  font-family: var(--font-display); font-weight: 600;
  font-size: 24px; margin: 44px 0 16px;
}
.article-content h3 { font-size: 19px; font-weight: 700; margin: 32px 0 12px; }
.article-content p { margin-bottom: 18px; color: #DDD5EE; }
.article-content ul, .article-content ol { margin: 0 0 18px 24px; color: #DDD5EE; }
.article-content li { margin-bottom: 8px; }
.article-content a { color: var(--violet); text-decoration: underline; }
.article-content strong { color: var(--text); }
.article-cta {
  margin-top: 50px;
  background: var(--surface);
  border: 1px solid var(--violet);
  border-radius: var(--radius);
  padding: 34px;
  text-align: center;
}
.article-cta h3 { font-family: var(--font-display); font-weight: 600; font-size: 21px; margin-bottom: 10px; }
.article-cta p { color: var(--muted); margin-bottom: 22px; }

/* --- Форма --- */
.contact-wrap {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 26px;
  padding: 54px 44px;
  position: relative;
  overflow: hidden;
}
.contact-wrap::before {
  content: '';
  position: absolute; top: -180px; left: 50%;
  transform: translateX(-50%);
  width: 500px; height: 320px;
  background: radial-gradient(ellipse, rgba(153, 73, 255, 0.28), transparent 70%);
  pointer-events: none;
}
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; position: relative; }
.contact-info h2 { font-family: var(--font-display); font-weight: 600; font-size: 30px; margin-bottom: 16px; }
.contact-info p { color: var(--muted); }
.form-field { margin-bottom: 18px; }
.form-field input, .form-field textarea {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 15px 18px;
  color: var(--text);
  font-family: var(--font-body); font-size: 16px;
  transition: border-color 0.2s;
}
.form-field input:focus, .form-field textarea:focus {
  outline: none; border-color: var(--violet);
  box-shadow: 0 0 0 3px rgba(153, 73, 255, 0.15);
}
.form-field textarea { resize: vertical; min-height: 100px; }
.consent {
  display: flex; gap: 12px; align-items: flex-start;
  font-size: 13.5px; color: var(--muted);
  margin: 6px 0 22px;
  cursor: pointer;
}
.consent input {
  width: 18px; height: 18px; margin-top: 2px;
  accent-color: var(--violet);
  flex-shrink: 0; cursor: pointer;
}
.consent a { color: var(--violet); text-decoration: underline; }
.form-status { margin-top: 16px; font-size: 15px; min-height: 22px; }
.form-status.ok { color: #7CE7A8; }
.form-status.err { color: #FF8B8B; }

/* --- Страница политики --- */
.legal { max-width: 800px; margin: 0 auto; padding: 60px 24px 90px; }
.legal h1 { font-family: var(--font-display); font-weight: 600; font-size: clamp(24px, 3.5vw, 34px); margin-bottom: 10px; }
.legal h2 { font-family: var(--font-display); font-weight: 600; font-size: 20px; margin: 36px 0 14px; }
.legal p, .legal li { color: #CFC6E4; margin-bottom: 12px; font-size: 15.5px; }
.legal ul { margin-left: 22px; }
.legal-meta { font-family: var(--font-mono); font-size: 13px; color: var(--muted); margin-bottom: 34px; }

/* --- Футер --- */
.footer {
  border-top: 1px solid var(--border);
  margin-top: 40px;
  padding: 54px 24px 30px;
}
.footer-inner {
  max-width: 1120px; margin: 0 auto;
  display: flex; justify-content: space-between; gap: 40px; flex-wrap: wrap;
}
.footer-note { color: var(--muted); font-size: 14px; margin-top: 14px; }
.footer-links { display: flex; flex-direction: column; gap: 12px; font-size: 15px; }
.footer-links a { color: var(--muted); transition: color 0.2s; }
.footer-links a:hover { color: var(--violet); }
.footer-copy {
  max-width: 1120px; margin: 40px auto 0;
  color: #5C5375; font-size: 13px; font-family: var(--font-mono);
}

/* --- Куки-баннер --- */
.cookie-banner {
  position: fixed; bottom: 20px; left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  width: min(680px, calc(100% - 32px));
  background: var(--surface-2);
  border: 1px solid var(--violet);
  border-radius: 16px;
  padding: 18px 22px;
  display: flex; gap: 20px; align-items: center;
  box-shadow: 0 12px 50px rgba(0, 0, 0, 0.6);
}
.cookie-banner p { font-size: 13.5px; color: var(--muted); flex: 1; }
.cookie-banner a { color: var(--violet); text-decoration: underline; }

/* --- 404 --- */
.notfound { text-align: center; padding: 120px 24px; }
.notfound h1 { font-family: var(--font-display); font-size: 70px; color: var(--violet); }
.notfound p { color: var(--muted); margin: 16px 0 30px; }

/* --- Появление секций --- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal.visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn, .service-card, .post-card { transition: none; }
}

/* --- Мобильная версия --- */
@media (max-width: 720px) {
  .nav { gap: 16px; font-size: 14px; }
  .nav a:first-child { display: none; }
  .hero { padding: 50px 0 70px; }
  .section { padding: 60px 0; }
  .contact-grid { grid-template-columns: 1fr; gap: 30px; }
  .contact-wrap { padding: 36px 24px; }
  .glow-top { width: 400px; height: 400px; top: -140px; right: -140px; }
  .footer-inner { flex-direction: column; }
}

/* ============================================================
   Дополнение: анимации героя, боли, квиз, процесс, FAQ
   ============================================================ */

/* --- Каскадное появление героя при загрузке --- */
@keyframes heroIn {
  from { opacity: 0; transform: translateY(22px); }
  to { opacity: 1; transform: none; }
}
.hero-anim {
  opacity: 0;
  animation: heroIn 0.7s ease forwards;
  animation-delay: calc(var(--d) * 0.13s);
}

/* --- Пульс главной кнопки --- */
@keyframes btnPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(153, 73, 255, 0.45); }
  55% { box-shadow: 0 0 0 14px rgba(153, 73, 255, 0); }
}
.btn-pulse { animation: btnPulse 2.6s ease-out infinite; }

/* --- Дыхание фонового свечения --- */
@keyframes glowBreathe {
  0%, 100% { opacity: 0.5; transform: scale(1); }
  50% { opacity: 0.68; transform: scale(1.07); }
}
.glow-top { animation: glowBreathe 9s ease-in-out infinite; }

/* --- Статистика в герое --- */
.hero-stats {
  margin-top: 58px;
  display: flex; gap: 48px; flex-wrap: wrap;
  border-top: 1px solid var(--border);
  padding-top: 30px;
}
.stat { display: flex; flex-direction: column; gap: 4px; }
.stat-num {
  font-family: var(--font-display);
  font-weight: 800; font-size: 28px;
  color: var(--violet);
}
.stat-label { font-size: 14px; color: var(--muted); }

/* --- Боли --- */
.pains-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 20px;
}
.pain-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px 28px;
  transition: border-color 0.25s, transform 0.25s;
}
.pain-card:hover { border-color: var(--violet); transform: translateY(-3px); }
.pain-text {
  font-weight: 700; font-size: 17px;
  color: #FFB4C0;
  line-height: 1.5;
}
.pain-arrow {
  font-family: var(--font-mono);
  color: var(--violet);
  font-size: 20px;
  margin: 14px 0 12px;
}
.pain-fix { color: var(--muted); font-size: 15px; }

/* --- Квиз --- */
.quiz-wrap {
  background: var(--surface);
  border: 1px solid var(--violet);
  border-radius: 26px;
  padding: 54px 44px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 0 80px rgba(153, 73, 255, 0.12);
}
.quiz-wrap::before {
  content: '';
  position: absolute; top: -200px; right: -120px;
  width: 480px; height: 400px;
  background: radial-gradient(ellipse, rgba(21, 22, 199, 0.35), transparent 70%);
  pointer-events: none;
}
.quiz-head { position: relative; max-width: 640px; }
.quiz-head h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(22px, 3vw, 32px);
  margin-bottom: 12px;
}
.quiz-note { color: var(--muted); font-size: 15px; }

.quiz-progress {
  position: relative;
  display: flex; align-items: center; gap: 24px;
  margin: 34px 0 8px;
  flex-wrap: wrap;
}
.quiz-bar {
  flex: 1; min-width: 200px; height: 8px;
  background: var(--bg);
  border-radius: 100px;
  overflow: hidden;
}
.quiz-bar-fill {
  height: 100%; width: 20%;
  background: linear-gradient(90deg, var(--blue), var(--violet));
  border-radius: 100px;
  transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}
.quiz-discount {
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--text);
  background: rgba(153, 73, 255, 0.14);
  border: 1px solid var(--violet);
  border-radius: 100px;
  padding: 7px 16px;
}
.quiz-discount span { color: var(--violet); font-weight: 700; }
@keyframes discountPop {
  0% { transform: scale(1); }
  50% { transform: scale(1.18); }
  100% { transform: scale(1); }
}
.quiz-discount.pop { animation: discountPop 0.4s ease; }

.quiz-body { position: relative; margin-top: 26px; min-height: 240px; }
.quiz-step { display: none; }
.quiz-step.active { display: block; animation: heroIn 0.45s ease; }
.quiz-q {
  font-family: var(--font-display);
  font-weight: 600; font-size: 20px;
  margin-bottom: 22px;
}
.quiz-options {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 14px;
}
.quiz-opt {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 18px 20px;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 15.5px; font-weight: 500;
  text-align: left;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s, transform 0.15s;
}
.quiz-opt:hover {
  border-color: var(--violet);
  background: rgba(153, 73, 255, 0.08);
  transform: translateY(-2px);
}
.quiz-final-note { color: var(--muted); margin-bottom: 22px; max-width: 460px; }
.quiz-step form { max-width: 460px; }

.quiz-success { text-align: center; padding: 30px 0; }
.quiz-success-icon {
  width: 68px; height: 68px;
  margin: 0 auto 20px;
  border-radius: 50%;
  background: linear-gradient(120deg, var(--blue), var(--violet));
  display: flex; align-items: center; justify-content: center;
  font-size: 30px; font-weight: 700;
  box-shadow: 0 0 40px rgba(153, 73, 255, 0.4);
}
.quiz-success .quiz-final-note { margin: 0 auto; }

/* --- Процесс --- */
.process-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  counter-reset: step;
}
.process-step {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px 28px;
  transition: border-color 0.25s, transform 0.25s;
}
.process-step:hover { border-color: var(--violet); transform: translateY(-3px); }
.process-step h3 {
  font-family: var(--font-display);
  font-weight: 600; font-size: 18px;
  margin: 16px 0 10px;
}
.process-step p { color: var(--muted); font-size: 15px; }

/* --- FAQ --- */
.faq-list { max-width: 820px; display: flex; flex-direction: column; gap: 12px; }
.faq-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  transition: border-color 0.25s;
}
.faq-item:hover, .faq-item[open] { border-color: var(--violet); }
.faq-item summary {
  cursor: pointer;
  list-style: none;
  padding: 22px 56px 22px 26px;
  font-weight: 700; font-size: 16.5px;
  position: relative;
  user-select: none;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: '+';
  position: absolute; right: 24px; top: 50%;
  transform: translateY(-50%);
  font-family: var(--font-mono);
  font-size: 22px; color: var(--violet);
  transition: transform 0.3s;
}
.faq-item[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq-item p {
  padding: 0 26px 24px;
  color: var(--muted);
  font-size: 15.5px;
  animation: heroIn 0.35s ease;
}

/* --- Мобильные доработки новых блоков --- */
@media (max-width: 720px) {
  .hero-stats { gap: 26px; padding-top: 24px; margin-top: 42px; }
  .stat-num { font-size: 23px; }
  .quiz-wrap { padding: 34px 22px; }
  .quiz-options { grid-template-columns: 1fr; }
  .quiz-progress { gap: 14px; }
  .pain-card, .process-step { padding: 26px 22px; }
  .faq-item summary { padding: 18px 48px 18px 20px; font-size: 15.5px; }
  .faq-item p { padding: 0 20px 20px; }
  .hero-actions .btn { width: 100%; text-align: center; }
}
@media (max-width: 420px) {
  .hero h1 { font-size: 30px; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-anim { animation: none; opacity: 1; }
  .btn-pulse, .glow-top { animation: none; }
  .quiz-bar-fill, .quiz-step.active { transition: none; animation: none; }
}

/* Фикс: атрибут hidden должен побеждать display:flex */
.cookie-banner[hidden] { display: none; }

/* --- Кто я --- */
.about-wrap {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 50px;
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 26px;
  padding: 44px;
}
.about-photo { position: relative; }
.about-photo::before {
  content: '';
  position: absolute; inset: -18px;
  background: radial-gradient(circle, rgba(153, 73, 255, 0.35), transparent 70%);
  filter: blur(30px);
  z-index: 0;
}
.about-photo img {
  position: relative; z-index: 1;
  width: 100%; height: auto;
  border-radius: 20px;
  border: 1px solid rgba(153, 73, 255, 0.4);
  box-shadow: 0 12px 50px rgba(0, 0, 0, 0.5);
}
.about-text h2 {
  font-family: var(--font-display);
  font-weight: 600; font-size: 30px;
  margin-bottom: 14px;
}
.about-lead { color: var(--muted); font-size: 17px; margin-bottom: 22px; }
.about-facts { list-style: none; }
.about-facts li {
  position: relative;
  padding-left: 26px;
  margin-bottom: 12px;
  color: #DDD5EE;
  font-size: 15.5px;
}
.about-facts li::before {
  content: '→';
  position: absolute; left: 0;
  font-family: var(--font-mono);
  color: var(--violet);
}
@media (max-width: 720px) {
  .about-wrap { grid-template-columns: 1fr; gap: 30px; padding: 30px 22px; }
  .about-photo { max-width: 260px; margin: 0 auto; }
}
