/* ============================================================
   Chicken Road Fan Hub — "Neon Night Highway"
   Тема: тёмный асфальт, неоновые акценты, пунктирная разметка
   ============================================================ */

:root {
  /* Фон и поверхности */
  --bg: #0b0e13;
  --bg-soft: #11151d;
  --surface: #161b25;
  --surface-2: #1c2230;
  --line: #2a3140;

  /* Акценты */
  --neon: #ffc53d;        /* неоново-жёлтая фара */
  --neon-soft: rgba(255, 197, 61, 0.14);
  --cool: #4fd8e0;        /* холодный голубой */
  --cool-soft: rgba(79, 216, 224, 0.12);
  --danger: #ff6b5e;      /* стоп-огни */
  --ok: #7ee787;

  /* Текст */
  --text: #e8eaf0;
  --text-muted: #9aa3b5;
  --text-faint: #6b7386;

  /* Шрифты */
  --font-display: "Archivo Black", "Arial Black", sans-serif;
  --font-body: "Space Grotesk", "Segoe UI", Tahoma, sans-serif;
  --font-mono: "JetBrains Mono", "Consolas", monospace;

  /* Форма */
  --radius: 14px;
  --radius-sm: 8px;
  --radius-lg: 22px;

  --maxw: 1180px;
  --shadow: 0 12px 32px rgba(0, 0, 0, 0.45);
}

* { 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;
  /* лёгкая текстура ночной трассы */
  background-image:
    radial-gradient(ellipse 90% 40% at 50% -10%, rgba(255, 197, 61, 0.06), transparent),
    linear-gradient(var(--line) 1px, transparent 1px);
  background-size: auto, 100% 120px;
}

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

a { color: var(--cool); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  line-height: 1.15;
  letter-spacing: 0.5px;
}

h1 { font-size: clamp(2.1rem, 5.5vw, 3.6rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.3rem); margin-bottom: 0.6rem; }
h3 { font-size: 1.2rem; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 22px; }

section { padding: 64px 0; }

.section-kicker {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--cool);
  border: 1px dashed var(--line);
  border-radius: 999px;
  padding: 4px 14px;
  margin-bottom: 14px;
  background: var(--cool-soft);
}

.lead { color: var(--text-muted); font-size: 1.1rem; max-width: 62ch; }

/* Пунктирная разделительная линия — как разметка на трассе */
.road-divider {
  height: 3px;
  max-width: var(--maxw);
  margin: 0 auto;
  background: repeating-linear-gradient(90deg,
    var(--neon) 0 26px, transparent 26px 52px);
  opacity: 0.35;
  border: none;
}

/* ---------- Бегущая строка новостей ---------- */
.ticker {
  background: var(--neon);
  color: #14100a;
  overflow: hidden;
  white-space: nowrap;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 7px 0;
  border-bottom: 2px solid #d9a320;
}
.ticker-track {
  display: inline-block;
  animation: ticker-move 42s linear infinite;
}
.ticker-track span { margin-right: 60px; }
@keyframes ticker-move {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ---------- Шапка ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(11, 14, 19, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.nav-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 22px;
  max-width: var(--maxw);
  margin: 0 auto;
}
.logo {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
}
.logo:hover { text-decoration: none; }
.logo .logo-chick { font-size: 1.5rem; }
.logo b { color: var(--neon); }
.main-nav { display: flex; gap: 6px; align-items: center; }
.main-nav a {
  color: var(--text-muted);
  padding: 8px 13px;
  border-radius: var(--radius-sm);
  font-weight: 500;
  transition: color 0.2s, background 0.2s;
}
.main-nav a:hover,
.main-nav a.active {
  color: var(--neon);
  background: var(--neon-soft);
  text-decoration: none;
}
.nav-toggle {
  display: none;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: 1.3rem;
  padding: 6px 14px;
  cursor: pointer;
}

/* ---------- Hero ---------- */
.hero {
  padding: 80px 0 70px;
  position: relative;
  overflow: hidden;
}
.hero::before {
  /* ночная трасса под углом */
  content: "";
  position: absolute;
  inset: auto -20% -60px -20%;
  height: 240px;
  background:
    repeating-linear-gradient(180deg, transparent 0 22px,
      rgba(255, 197, 61, 0.22) 22px 25px, transparent 25px 44px);
  transform: perspective(300px) rotateX(55deg);
  opacity: 0.5;
  pointer-events: none;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 44px;
  align-items: center;
  position: relative;
}
.hero h1 .glow {
  color: var(--neon);
  text-shadow: 0 0 22px rgba(255, 197, 61, 0.45);
}
.hero-actions { display: flex; gap: 14px; margin-top: 26px; flex-wrap: wrap; }

.hero-photo {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  background: var(--surface);
}
.hero-photo img { width: 100%; height: 300px; object-fit: cover; }

/* ---------- Кнопки ---------- */
.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.98rem;
  padding: 12px 24px;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.2s, background 0.2s;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }
.btn-primary {
  background: var(--neon);
  color: #14100a;
  box-shadow: 0 0 24px rgba(255, 197, 61, 0.35);
}
.btn-primary:hover { box-shadow: 0 0 34px rgba(255, 197, 61, 0.55); }
.btn-ghost {
  background: transparent;
  color: var(--cool);
  border-color: var(--cool);
}
.btn-ghost:hover { background: var(--cool-soft); }
.btn-small { padding: 8px 16px; font-size: 0.88rem; }

/* ---------- Симулятор забега в hero ---------- */
.run-panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 22px;
  box-shadow: var(--shadow);
}
.run-panel h3 {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--cool);
  margin-bottom: 14px;
}
.run-lanes {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
  position: relative;
}
.run-lane {
  height: 38px;
  background: var(--bg-soft);
  border-radius: var(--radius-sm);
  border-left: 4px solid var(--line);
  display: flex;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-faint);
  padding: 0 12px;
  position: relative;
}
.run-lane .lane-mult { margin-left: auto; color: var(--neon); font-weight: 700; }
.run-lanes .chicken-pos {
  font-size: 1.3rem;
  position: absolute;
  left: 8px;
  top: 7px;
  z-index: 2;
  transition: left 0.25s ease, top 0.25s ease;
}
.run-lane.lane-active { border-left-color: var(--neon); background: var(--neon-soft); }
.run-lane.lane-danger { border-left-color: var(--danger); background: rgba(255, 107, 94, 0.12); }
.run-stats {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 0.95rem;
  margin-bottom: 14px;
}
.run-stats b { color: var(--neon); font-size: 1.15rem; }
.run-status {
  min-height: 22px;
  font-size: 0.88rem;
  color: var(--text-muted);
  margin-bottom: 12px;
}
.run-controls { display: flex; gap: 10px; flex-wrap: wrap; }

/* ---------- Счётчики статистики ---------- */
.stats-band {
  background: var(--bg-soft);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 42px 0;
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
  text-align: center;
}
.stat-item .stat-num {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 4vw, 2.8rem);
  color: var(--neon);
  text-shadow: 0 0 18px rgba(255, 197, 61, 0.35);
}
.stat-item .stat-label {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-top: 4px;
}

/* ---------- Карточки ---------- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-top: 30px;
}
.card-grid-2 { grid-template-columns: repeat(2, 1fr); }
.card-grid-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  transition: transform 0.2s, border-color 0.2s;
}
.card:hover { transform: translateY(-4px); border-color: var(--cool); }
.card .card-emoji { font-size: 1.9rem; margin-bottom: 12px; display: block; }
.card h3 { margin-bottom: 8px; }
.card p { color: var(--text-muted); font-size: 0.95rem; }

/* Карточка с фото */
.photo-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.photo-card .ph {
  height: 190px;
  background: var(--surface-2); /* мягкая заглушка */
  background-size: cover;
  background-position: center;
}
.photo-card .ph img {
  width: 100%; height: 100%;
  object-fit: cover;
  background: var(--surface-2);
}
.photo-card .pc-body { padding: 22px; }

/* Блок фото + текст рядом */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 36px;
  align-items: center;
}
.split .photo-frame {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface-2);
  box-shadow: var(--shadow);
}
.split .photo-frame img { width: 100%; height: 320px; object-fit: cover; }

/* ---------- Таблица режимов ---------- */
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  margin-top: 30px;
}
table.modes {
  width: 100%;
  border-collapse: collapse;
  min-width: 640px;
  font-size: 0.95rem;
}
table.modes th, table.modes td {
  padding: 14px 18px;
  text-align: left;
  border-bottom: 1px solid var(--line);
}
table.modes th {
  font-family: var(--font-mono);
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 1.5px;
  color: var(--cool);
  background: var(--bg-soft);
}
table.modes td:first-child { font-weight: 700; color: var(--neon); }
table.modes tr:last-child td { border-bottom: none; }
.table-note {
  color: var(--text-faint);
  font-size: 0.85rem;
  margin-top: 12px;
  font-style: italic;
}

/* ---------- Чек-лист / интерактив ---------- */
.interactive-box {
  background: var(--surface);
  border: 1px dashed var(--cool);
  border-radius: var(--radius-lg);
  padding: 28px;
  margin-top: 30px;
}
.quiz-q { margin-bottom: 22px; }
.quiz-q h4 { margin-bottom: 10px; font-family: var(--font-body); font-size: 1.05rem; }
.quiz-opts { display: flex; gap: 10px; flex-wrap: wrap; }
.quiz-opt {
  background: var(--bg-soft);
  border: 1px solid var(--line);
  color: var(--text-muted);
  border-radius: 999px;
  padding: 8px 18px;
  font-family: var(--font-body);
  font-size: 0.92rem;
  cursor: pointer;
  transition: all 0.2s;
}
.quiz-opt:hover { border-color: var(--cool); color: var(--text); }
.quiz-opt.picked { border-color: var(--neon); color: var(--neon); background: var(--neon-soft); }
.quiz-opt.right { border-color: var(--ok); color: var(--ok); }
.quiz-opt.wrong { border-color: var(--danger); color: var(--danger); }
.quiz-result {
  margin-top: 14px;
  font-weight: 700;
  min-height: 26px;
  color: var(--neon);
}

/* Генератор совета */
.tip-machine {
  background: var(--bg-soft);
  border-radius: var(--radius);
  padding: 20px;
  margin-top: 16px;
  border: 1px solid var(--line);
}
.tip-machine .tip-output {
  font-size: 1.08rem;
  color: var(--cool);
  min-height: 52px;
  margin-bottom: 12px;
  font-style: italic;
}

/* ---------- FAQ-аккордеон ---------- */
.faq-list { margin-top: 30px; display: grid; gap: 12px; }
.faq-item {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.faq-q {
  width: 100%;
  background: none;
  border: none;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.02rem;
  font-weight: 600;
  text-align: left;
  padding: 18px 22px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
}
.faq-q .faq-arrow { color: var(--neon); transition: transform 0.25s; font-size: 1.1rem; }
.faq-item.open .faq-arrow { transform: rotate(180deg); }
.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}
.faq-a-inner {
  padding: 0 22px 18px;
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* ---------- Trust-бейджи ---------- */
.badges {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 30px;
}
.badge {
  border: 1px dashed var(--line);
  border-radius: 999px;
  padding: 9px 18px;
  font-size: 0.88rem;
  color: var(--text-muted);
  background: var(--surface);
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ---------- CTA-баннер ---------- */
.cta-banner {
  background: linear-gradient(120deg, var(--neon-soft), var(--cool-soft));
  border: 1px solid var(--neon);
  border-radius: var(--radius-lg);
  padding: 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}
.cta-banner h2 { margin-bottom: 6px; }
.cta-banner p { color: var(--text-muted); }

/* ---------- Глоссарий ---------- */
.glossary-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 30px;
}
.glossary-item {
  background: var(--surface);
  border-left: 3px solid var(--cool);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 14px 18px;
}
.glossary-item dt { font-weight: 700; color: var(--neon); }
.glossary-item dd { color: var(--text-muted); font-size: 0.92rem; margin-top: 4px; }

/* ---------- Контентные страницы ---------- */
.page-head { padding: 64px 0 34px; }
.page-head h1 { margin-bottom: 12px; }
.page-head .lead { color: var(--text-muted); font-size: 1.12rem; max-width: 66ch; }

.prose { max-width: 76ch; }
.prose h2 { margin: 42px 0 14px; }
.prose h3 { margin: 28px 0 10px; }
.prose p { color: var(--text-muted); margin-bottom: 14px; }
.prose ul, .prose ol { margin: 0 0 16px 22px; color: var(--text-muted); }
.prose li { margin-bottom: 8px; }
.prose strong { color: var(--text); }

.step-list { counter-reset: step; margin-top: 24px; }
.step-item {
  display: flex;
  gap: 18px;
  padding: 18px 0;
  border-bottom: 1px dashed var(--line);
}
.step-item::before {
  counter-increment: step;
  content: counter(step, decimal-leading-zero);
  font-family: var(--font-display);
  font-size: 1.6rem;
  color: var(--neon);
  min-width: 54px;
}

/* ---------- Форма связи ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  margin-top: 30px;
  align-items: start;
}
.contact-form { display: grid; gap: 16px; }
.contact-form label { font-size: 0.9rem; color: var(--text-muted); font-weight: 600; }
.contact-form input,
.contact-form textarea,
.contact-form select {
  width: 100%;
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 0.98rem;
  padding: 11px 14px;
  margin-top: 5px;
}
.contact-form input:focus,
.contact-form textarea:focus,
.contact-form select:focus {
  outline: none;
  border-color: var(--cool);
}
.form-error { color: var(--danger); font-size: 0.85rem; min-height: 18px; }
.form-success {
  background: rgba(126, 231, 135, 0.12);
  border: 1px solid var(--ok);
  color: var(--ok);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  display: none;
}

/* ---------- Cookie-баннер ---------- */
.cookie-banner {
  position: fixed;
  bottom: 20px;
  left: 20px;
  right: 20px;
  max-width: 560px;
  background: var(--surface);
  border: 1px solid var(--neon);
  border-radius: var(--radius);
  padding: 20px 22px;
  box-shadow: var(--shadow);
  z-index: 100;
  display: none;
}
.cookie-banner.show { display: block; }
.cookie-banner p { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 14px; }
.cookie-banner a { color: var(--neon); }
.cookie-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* ---------- Футер ---------- */
.site-footer {
  background: var(--bg-soft);
  border-top: 1px solid var(--line);
  padding: 54px 0 30px;
  margin-top: 60px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 34px;
}
.footer-grid h4 {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--cool);
  margin-bottom: 14px;
}
.footer-grid ul { list-style: none; }
.footer-grid li { margin-bottom: 9px; }
.footer-grid a { color: var(--text-muted); font-size: 0.93rem; }
.footer-grid a:hover { color: var(--neon); }
.footer-disclaimer {
  color: var(--text-faint);
  font-size: 0.85rem;
  border-top: 1px dashed var(--line);
  margin-top: 34px;
  padding-top: 20px;
  max-width: 90ch;
}
.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  color: var(--text-faint);
  font-size: 0.82rem;
  margin-top: 16px;
}

/* ---------- Reveal-анимации ---------- */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ---------- Адаптив ---------- */
@media (max-width: 960px) {
  .hero-grid, .split, .contact-grid { grid-template-columns: 1fr; }
  .card-grid, .card-grid-4 { grid-template-columns: repeat(2, 1fr); }
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 30px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .glossary-grid { grid-template-columns: 1fr; }

  .nav-toggle { display: block; }
  .main-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-soft);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    align-items: stretch;
    padding: 12px 22px 18px;
    gap: 4px;
  }
  .main-nav.open { display: flex; }
  .main-nav a { padding: 12px 14px; }
}

@media (max-width: 560px) {
  .card-grid, .card-grid-2, .card-grid-4 { grid-template-columns: 1fr; }
  section { padding: 48px 0; }
  .cta-banner { padding: 28px; }
}