/* ============================================
   Zapadauto — Premium Automotive
   Dark, minimal, cinematic
   ============================================ */

:root {
  /* Backgrounds */
  --bg-primary: #0a0a0a;
  --bg-secondary: #141414;
  --bg-card: #1a1a1a;
  --bg-card-hover: #1f1f1f;

  /* Text */
  --text-primary: #ffffff;
  --text-secondary: #737373;
  --text-muted: #525252;

  /* Accent — белозолотистый / gold */
  --accent: #d4af37;
  --accent-soft: rgba(212, 175, 55, 0.2);
  --accent-glow: rgba(212, 175, 55, 0.1);
  --gold-light: #ecd876;
  --gold-pale: #f8f4e6;
  --gold-dark: #b8960f;

  /* Spacing & layout */
  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 1.5rem;
  --space-lg: 2.5rem;
  --space-xl: 4rem;
  --space-2xl: 6rem;
  --space-3xl: 8rem;

  --container: min(90vw, 1200px);
  --header-height: 4rem;

  /* Motion */
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --duration-slow: 1.2s;
  --duration-normal: 0.6s;
  --duration-fast: 0.35s;
}

/* Reset & base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  font-family: 'Outfit', -apple-system, sans-serif;
  font-weight: 400;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.5;
  overflow-x: hidden;
}

/* Мобильная версия: стабильная высота и скролл без дёргания */
@media (max-width: 768px) {
  html {
    scroll-behavior: auto;
    -webkit-overflow-scrolling: touch;
    overflow-y: scroll;
  }
  body {
    min-height: 100%;
    touch-action: manipulation;
  }
}

/* Typography */
h1, h2, h3, .hero-headline, .section-title, .card-title {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  letter-spacing: -0.02em;
}

/* ============================================
   Header — minimal
   ============================================ */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 0;
  padding: 0;
  z-index: 100;
  background: transparent;
  pointer-events: none;
}

.header.scrolled {
  background: var(--bg-primary);
}

.logo {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 1.25rem;
  letter-spacing: 0.05em;
  text-transform: lowercase;
  color: var(--text-primary);
  text-decoration: none;
  transition: color var(--duration-fast);
}

.logo:hover {
  color: var(--accent);
}

.nav {
  display: flex;
  gap: var(--space-lg);
}

.nav-link {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-secondary);
  text-decoration: none;
  letter-spacing: 0.02em;
  transition: color var(--duration-fast);
}

.nav-link:hover {
  color: var(--text-primary);
}

/* ============================================
   Hero — full-screen cinematic scene
   Video is the background; content layered on top
   ============================================ */
.hero {
  position: relative;
  width: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  overflow: hidden;
}

@media (max-width: 768px) {
  .hero {
    min-height: 100vh;
    min-height: 100svh;
    min-height: -webkit-fill-available;
  }
}

.hero-video-wrap {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--bg-primary);
}

.hero-video-wrap::before {
  display: none;
}

@media (min-width: 769px) {
  .hero-video-wrap {
    left: auto;
    right: 0;
    width: 58%;
  }
  .hero-video-wrap::before {
    display: block;
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 160px;
    background: linear-gradient(to right, var(--bg-primary) 0%, transparent 100%);
    pointer-events: none;
    z-index: 2;
  }
}

.hero-video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

@media (max-width: 768px) {
  .hero {
    align-items: flex-start;
  }
  .hero-content {
    padding-top: 0.75rem;
    padding-left: var(--space-md);
    padding-right: var(--space-md);
  }
  .hero-headline {
    margin-bottom: 0.4em;
    line-height: 1.25;
  }
  .hero-subheadline {
    margin-top: 0.65em;
    margin-bottom: 0;
    line-height: 1.35;
  }
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(10, 10, 10, 0.4) 0%,
    rgba(10, 10, 10, 0.6) 50%,
    rgba(10, 10, 10, 0.85) 100%
  );
  pointer-events: none;
}

@media (max-width: 768px) {
  .hero-overlay {
    background: linear-gradient(
      to bottom,
      rgba(10, 10, 10, 0.15) 0%,
      rgba(10, 10, 10, 0.25) 50%,
      rgba(10, 10, 10, 0.5) 100%
    );
  }
}

/* Atmospheric haze — neutral light diffusion (no yellow) */
.hero-haze {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(
    ellipse 80% 60% at 50% 70%,
    rgba(255, 255, 255, 0.04) 0%,
    transparent 50%
  );
  opacity: 0;
  transition: opacity var(--duration-slow) var(--ease-out);
}

.hero-haze.visible {
  opacity: 1;
}

/* ============================================
   Post-video living scene (when .video-ended)
   Haze drift + headlight breathing only — без движения видео
   ============================================ */
.hero-video-wrap.video-ended .hero-video {
  /* без living-micro-drift — видео статично, при мигании машина не двигается */
}

.hero-video-wrap.video-ended .hero-haze {
  animation: living-haze-drift 25s ease-in-out infinite alternate;
  opacity: 1;
}

/* Дыхание фар: белый свет, без жёлтого, хорошо заметно */
.hero-video-wrap.video-ended::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  background: radial-gradient(
    ellipse 55% 40% at 50% 72%,
    rgba(255, 255, 255, 0.35) 0%,
    rgba(255, 255, 255, 0.12) 35%,
    rgba(255, 255, 255, 0.04) 60%,
    transparent 75%
  );
  animation: living-headlight-breathe 4s ease-in-out infinite alternate;
}

@keyframes living-micro-drift {
  0%   { transform: scale(1) translate(0, 0); }
  100% { transform: scale(1.008) translate(0.16%, 0.08%); }
}

@keyframes living-micro-drift-mobile {
  0%   { transform: scale(0.86) translate(0, 0); }
  100% { transform: scale(0.868) translate(0.16%, 0.08%); }
}

@keyframes living-haze-drift {
  0%   { opacity: 0.75; }
  100% { opacity: 1;   }
}

@keyframes living-headlight-breathe {
  0%   { opacity: 0.2;  }
  100% { opacity: 0.95; }
}

@keyframes hero-text-shimmer {
  0%, 100% { background-position: 0% 50%; }
  50%      { background-position: 100% 50%; }
}

/* Content — left-aligned, staggered reveal (initial state) */
.hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
  padding: var(--header-height) var(--space-2xl) var(--space-3xl);
  padding-left: clamp(var(--space-lg), 8vw, var(--space-2xl));
  max-width: 44rem;
  text-align: left;
}

@media (max-width: 768px) {
  .hero-content {
    min-height: 100vh;
    min-height: 100svh;
    min-height: -webkit-fill-available;
  }
}

.hero-buttons {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: var(--space-sm);
  align-items: flex-start;
  margin-top: auto;
  padding-bottom: 0;
}

.hero-buttons-col {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-sm);
}

@media (max-width: 768px) {
  .hero-buttons {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }

  .hero-buttons-col {
    width: 100%;
    max-width: 100%;
    align-items: stretch;
  }

  /* Не даём min-width:280px вылезать за край на экранах уже ~320px */
  .hero-buttons .btn-popular,
  .hero-buttons .btn-videos,
  .hero-buttons .btn-telegram-catalog {
    min-width: 0;
    width: 100%;
    max-width: 100%;
  }
}

.hero-content .hero-list {
  margin-bottom: var(--space-md);
}

.hero-headline {
  font-size: clamp(1.85rem, 4.2vw, 2.85rem);
  line-height: 1.1;
  margin-bottom: var(--space-lg);
  opacity: 0;
  transform: translateY(20px);
  transition: opacity var(--duration-slow) var(--ease-out),
              transform var(--duration-slow) var(--ease-out);
  background: linear-gradient(
    110deg,
    #fff 0%,
    var(--gold-pale) 30%,
    var(--gold-light) 50%,
    var(--gold-pale) 70%,
    #fff 100%
  );
  background-size: 180% auto;
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  animation: hero-text-shimmer 14s ease-in-out infinite;
}

.hero-headline.visible {
  opacity: 1;
  transform: translateY(0);
}

.hero-subheadline {
  font-size: 1.125rem;
  font-weight: 400;
  margin-bottom: var(--space-xl);
  opacity: 0;
  transform: translateY(18px);
  transition: opacity var(--duration-slow) var(--ease-out) 0.25s,
              transform var(--duration-slow) var(--ease-out) 0.25s;
  background: linear-gradient(
    110deg,
    #fff 0%,
    var(--gold-pale) 30%,
    var(--gold-light) 50%,
    var(--gold-pale) 70%,
    #fff 100%
  );
  background-size: 180% auto;
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  animation: hero-text-shimmer 14s ease-in-out infinite 0.5s;
}

.hero-subheadline.visible {
  opacity: 1;
  transform: translateY(0);
}

.hero-list {
  list-style: none;
  margin-bottom: 0;
  margin-left: calc(-1 * clamp(2.5rem, 8vw, 6rem));
  padding-left: 2rem;
  text-align: left;
}

.hero-list li {
  font-size: 1.40625rem;
  font-style: italic;
  padding: var(--space-sm) 0;
  padding-left: 1.5em;
  position: relative;
  opacity: 0;
  transform: translateY(14px);
  transition: opacity var(--duration-normal) var(--ease-out),
              transform var(--duration-normal) var(--ease-out);
  background: linear-gradient(
    110deg,
    #fff 0%,
    var(--gold-pale) 30%,
    var(--gold-light) 50%,
    var(--gold-pale) 70%,
    #fff 100%
  );
  background-size: 180% auto;
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  animation: hero-text-shimmer 14s ease-in-out infinite;
}

.hero-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.75;
}

.hero-list li.visible {
  opacity: 1;
  transform: translateY(0);
}

.hero-list li:nth-child(1) { transition-delay: 0.45s; animation-delay: 0s;     }
.hero-list li:nth-child(2) { transition-delay: 0.55s; animation-delay: 0.5s;  }
.hero-list li:nth-child(3) { transition-delay: 0.65s; animation-delay: 1s;   }
.hero-list li:nth-child(4) { transition-delay: 0.75s; animation-delay: 1.5s; }

/* ============================================
   Atmosphere layer (particles / haze)
   ============================================ */
.atmosphere {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  overflow: hidden;
}

.atmosphere canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

/* ============================================
   Sections — dark surfaces, lots of space
   ============================================ */
.section {
  padding: var(--space-3xl) var(--space-lg);
  background: var(--bg-primary);
}

.section-services {
  background: var(--bg-secondary);
}

.section-process {
  background: var(--bg-primary);
}

.section-contact {
  background: var(--bg-secondary);
}

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
}

.section-title {
  font-size: clamp(2rem, 4vw, 2.75rem);
  margin-bottom: var(--space-2xl);
  color: var(--text-primary);
}

/* Cards */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-lg);
}

.card {
  background: var(--bg-card);
  padding: var(--space-xl);
  border-radius: 2px;
  transition: background var(--duration-normal),
              box-shadow var(--duration-normal),
              transform var(--duration-normal) var(--ease-out);
}

.card:hover {
  background: var(--bg-card-hover);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  transform: translateY(-2px);
}

.card-label {
  font-family: 'Syne', sans-serif;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--accent);
  display: block;
  margin-bottom: var(--space-md);
}

.card-title {
  font-size: 1.5rem;
  margin-bottom: var(--space-sm);
  color: var(--text-primary);
}

.card-text {
  font-size: 0.9375rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Process steps */
.process-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--space-xl);
}

.process-step {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.process-num {
  font-family: 'Syne', sans-serif;
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent);
  opacity: 0.9;
}

.process-step p {
  font-size: 0.9375rem;
  color: var(--text-secondary);
}

/* Contact */
.contact-block {
  max-width: 28rem;
}

.contact-text {
  font-size: 1rem;
  color: var(--text-secondary);
  margin-bottom: var(--space-lg);
  line-height: 1.6;
}

.contact-link {
  display: block;
  font-size: 1.125rem;
  color: var(--text-primary);
  text-decoration: none;
  margin-bottom: var(--space-sm);
  transition: color var(--duration-fast);
}

.contact-link:hover {
  color: var(--accent);
}

/* Footer */
.footer {
  padding: var(--space-xl) var(--space-lg);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.footer .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.footer-brand {
  font-family: 'Syne', sans-serif;
  font-weight: 700;
  font-size: 0.875rem;
  letter-spacing: 0.05em;
  text-transform: lowercase;
  color: var(--text-muted);
}

.footer-copy {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

/* ============================================
   Блок предложений — отдельная секция под героем
   ============================================ */
.offers-block {
  background: var(--bg-primary);
  padding: var(--space-2xl) var(--space-lg);
}

.btn-popular {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 2.5em;
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 1.125rem;
  letter-spacing: 0.03em;
  color: #fff;
  background: var(--accent);
  min-width: 280px;
  line-height: 1;
  text-decoration: none;
  border-radius: 9999px;
  margin-bottom: 0;
  transition: background var(--duration-fast), box-shadow var(--duration-fast);
  box-shadow: 0 2px 12px rgba(212, 175, 55, 0.25);
}


.btn-popular:hover {
  background: var(--gold-light);
  color: #fff;
  box-shadow: 0 4px 16px rgba(212, 175, 55, 0.35);
}

/* Кнопка каталога в Telegram — фирменный Telegram-синий */
a.btn-telegram-catalog {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 48px;
  padding: 0 1.5rem 0 1.25rem;
  font-family: 'Outfit', sans-serif;
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: 0.02em;
  line-height: 1.25;
  text-align: center;
  text-decoration: none;
  color: #fff;
  -webkit-text-fill-color: #fff;
  background: linear-gradient(180deg, #2aabee 0%, #229ed9 100%);
  background-clip: border-box;
  -webkit-background-clip: border-box;
  border-radius: 9999px;
  min-width: 280px;
  max-width: 100%;
  box-sizing: border-box;
  box-shadow: 0 2px 14px rgba(34, 158, 217, 0.35);
  transition: background var(--duration-fast), box-shadow var(--duration-fast), transform var(--duration-fast);
}

a.btn-telegram-catalog:hover {
  background: linear-gradient(180deg, #3ab8f5 0%, #28a8e6 100%);
  color: #fff;
  -webkit-text-fill-color: #fff;
  box-shadow: 0 4px 16px rgba(34, 158, 217, 0.45);
}

.btn-telegram-catalog-icon {
  flex-shrink: 0;
}

/* Кнопка «Видеоотзывы» — красная с переливанием */
.btn-videos {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 2.5em;
  font-family: 'Outfit', sans-serif;
  font-weight: 700;
  font-size: 1.125rem;
  letter-spacing: 0.03em;
  color: #fff;
  background: linear-gradient(
    110deg,
    #b91c1c 0%,
    #dc2626 25%,
    #ef4444 50%,
    #dc2626 75%,
    #b91c1c 100%
  );
  background-size: 200% auto;
  min-width: 280px;
  line-height: 1;
  text-decoration: none;
  border-radius: 9999px;
  margin-bottom: 0;
  animation: btn-red-shimmer 4s ease-in-out infinite;
  box-shadow: 0 2px 16px rgba(185, 28, 28, 0.4);
  transition: box-shadow var(--duration-fast), transform var(--duration-fast);
}

.btn-videos:hover {
  box-shadow: 0 4px 24px rgba(185, 28, 28, 0.55);
  color: #fff;
}

@keyframes btn-red-shimmer {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

.offers-container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
}

.offers-title {
  font-family: 'Syne', sans-serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space-lg);
}

.offers-carousel-viewport {
  position: relative;
  overflow: hidden;
  padding: 16px 52px;
  min-height: 380px;
  display: flex;
  align-items: center;
}

.offers-carousel-viewport .carousel-track {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-behavior: smooth;
  gap: 20px;
  padding: 10px 0;
  align-items: stretch;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.offers-carousel-viewport .carousel-track::-webkit-scrollbar {
  display: none;
}

.offer-card {
  flex: 0 0 auto;
  width: 260px;
  min-width: 260px;
  background: var(--bg-card);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 4px;
  padding: var(--space-md);
  transition: border-color var(--duration-normal), box-shadow var(--duration-normal);
  opacity: 0.6;
}

.offer-card.is-center {
  opacity: 1;
  border-color: rgba(212, 175, 55, 0.4);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
}

.offer-card img {
  width: 100%;
  height: auto;
  border-radius: 2px;
  margin-bottom: var(--space-sm);
  display: block;
  background: var(--bg-secondary);
}

.offer-card-title {
  font-family: 'Syne', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--text-primary);
  margin-bottom: var(--space-xs);
}

.offer-card-text {
  font-size: 0.875rem;
  line-height: 1.4;
  color: var(--text-secondary);
  margin: 3px 0;
}

.offer-card-meta {
  margin: var(--space-sm) 0;
  padding-top: var(--space-sm);
  border-top: 1px dashed rgba(255, 255, 255, 0.1);
}

.offer-card-price {
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.4;
  color: var(--accent);
  margin-top: var(--space-sm);
  margin-bottom: 0;
}

.btn-consult {
  display: block;
  width: 100%;
  margin-top: var(--space-sm);
  padding: 0.5rem 1rem;
  font-size: 0.8125rem;
  font-weight: 600;
  text-align: center;
  color: var(--accent);
  background: transparent;
  border: 1px solid rgba(212, 175, 55, 0.5);
  border-radius: 9999px;
  text-decoration: none;
  transition: border-color var(--duration-fast), background var(--duration-fast);
}

.btn-consult:hover {
  background: rgba(212, 175, 55, 0.1);
  border-color: var(--accent);
  color: var(--accent);
}

@media (max-width: 768px) {
  .offers-block {
    padding-left: var(--space-sm);
    padding-right: var(--space-sm);
  }
  .offers-container {
    max-width: 100%;
  }
  .offers-carousel-viewport {
    padding-left: 36px;
    padding-right: 36px;
  }
  .offer-card {
    width: min(280px, 88vw);
    min-width: min(280px, 88vw);
  }
}

.offers-carousel-viewport .carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 44px;
  height: 44px;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: var(--bg-card);
  color: var(--accent);
  cursor: pointer;
  font-size: 22px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: background var(--duration-fast), border-color var(--duration-fast);
}

.offers-carousel-viewport .carousel-arrow:hover {
  background: var(--bg-card-hover);
  border-color: var(--accent);
}

.offers-carousel-viewport .carousel-prev::before {
  content: '\2039';
}

.offers-carousel-viewport .carousel-next::before {
  content: '\203A';
}

.offers-carousel-viewport .carousel-prev {
  left: 8px;
}

.offers-carousel-viewport .carousel-next {
  right: 8px;
}

/* Переносы только на мобильной (br скрыт на десктопе) */
.br-mobile {
  display: none;
}

.hero-headline-short {
  display: none;
}

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 768px) {
  .br-mobile {
    display: block;
  }

  .hero-headline-line1 {
    display: block;
    white-space: nowrap;
  }
  .hero-headline-line2 {
    display: block;
  }

  .hero-list {
    display: none;
  }

  .hero-buttons {
    margin-top: var(--space-lg);
  }

  .nav {
    gap: var(--space-md);
  }

  .hero-content {
    text-align: left;
  }
}

@media (max-width: 380px) {
  .hero-headline-line1,
  .hero-headline .br-mobile,
  .hero-headline-line2 {
    display: none !important;
  }
  .hero-headline-short {
    display: block !important;
  }
}

/* ============================================
   Блок видео — 4 шт., 2 в ряд (десктоп), 1 в ряд (мобильный)
   ============================================ */
.videos-block {
  padding: var(--space-2xl) var(--space-md);
  background: var(--bg-secondary);
}

.videos-container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
}

.videos-title {
  font-family: 'Syne', sans-serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: var(--space-lg);
}

.videos-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-md);
}

@media (min-width: 769px) {
  .videos-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Ячейка: постер и видео строго друг поверх друга на любом устройстве */
.video-cell {
  position: relative;
  display: block;
  width: 100%;
  min-width: 0;
  min-height: 0;
  padding-bottom: 56.25%;
  height: 0;
  background: var(--bg-card);
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

@supports (aspect-ratio: 16 / 9) {
  .video-cell {
    padding-bottom: 0;
    height: auto;
    aspect-ratio: 16 / 9;
  }
}

.video-cell-poster,
.video-cell-video {
  position: absolute;
  left: 0;
  top: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  margin: 0;
  padding: 0;
  border: none;
  vertical-align: top;
}

.video-cell-poster {
  z-index: 2;
  pointer-events: none;
}

.video-cell.playing .video-cell-poster {
  opacity: 0;
  pointer-events: none;
  z-index: 0;
}

.video-cell-video {
  z-index: 1;
}

.videos-cta-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
  text-align: center;
  margin-top: var(--space-lg);
}

/* ============================================
   Квиз — 5 вопросов + финал
   ============================================ */
.quiz-block {
  padding: var(--space-2xl) var(--space-md);
  background: var(--bg-primary);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.quiz-container {
  max-width: 520px;
  margin: 0 auto;
}

.quiz-title {
  font-family: 'Syne', sans-serif;
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: var(--space-lg);
  text-align: center;
}

.quiz-intro {
  text-align: center;
}

.quiz-intro-text {
  font-size: 1.125rem;
  font-weight: 500;
  line-height: 1.5;
  color: var(--text-secondary);
  margin-bottom: var(--space-lg);
}

.quiz-intro-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-sm);
}

.quiz-start {
  margin: 0;
}

.quiz-form {
  display: block;
}

.quiz-step {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.quiz-step-label {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 0;
}

.quiz-step-question {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0;
}

.quiz-step-hint {
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 0;
}

.quiz-messenger-label {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: var(--space-xs);
}

.quiz-messenger-btns {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  margin-bottom: var(--space-md);
}

.quiz-messenger-btn {
  flex: 1;
  min-width: 100px;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  font-weight: 600;
  font-family: inherit;
  color: var(--text-primary);
  background: var(--bg-card);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 4px;
  cursor: pointer;
  transition: border-color var(--duration-fast), background var(--duration-fast);
}

.quiz-messenger-btn:hover {
  border-color: rgba(212, 175, 55, 0.4);
  background: rgba(212, 175, 55, 0.08);
}

.quiz-messenger-btn.active {
  border-color: var(--accent);
  background: rgba(212, 175, 55, 0.15);
  color: var(--gold-light);
}

.quiz-field {
  margin: 0;
}

.quiz-field-label {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-secondary);
}

.quiz-input,
.quiz-textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  font-family: inherit;
  font-size: 1.0625rem;
  font-weight: 500;
  color: var(--text-primary);
  background: var(--bg-card);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 4px;
  outline: none;
  transition: border-color var(--duration-fast);
  box-sizing: border-box;
}

.quiz-textarea {
  resize: vertical;
  min-height: 100px;
}

.quiz-input:focus,
.quiz-textarea:focus {
  border-color: var(--accent);
}

.quiz-input::placeholder,
.quiz-textarea::placeholder {
  color: var(--text-muted);
}

.quiz-options {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.quiz-option {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.875rem 1rem;
  font-size: 1.0625rem;
  font-weight: 500;
  color: var(--text-primary);
  background: var(--bg-card);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 4px;
  cursor: pointer;
  transition: border-color var(--duration-fast), background var(--duration-fast);
}

.quiz-option:hover {
  border-color: rgba(212, 175, 55, 0.4);
  background: rgba(212, 175, 55, 0.05);
}

.quiz-option input {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  accent-color: var(--accent);
}

.quiz-option input:checked + span {
  font-weight: 700;
}

.quiz-step .quiz-prev,
.quiz-step .quiz-next,
.quiz-step .quiz-submit {
  align-self: flex-start;
}

.quiz-step .quiz-next {
  margin-right: var(--space-sm);
}

.quiz-step .quiz-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
}

.quiz-final {
  text-align: center;
  padding: var(--space-lg) 0;
}

.quiz-final-title {
  font-family: 'Syne', sans-serif;
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
}

.quiz-final-text {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-md);
}

.quiz-final-note {
  font-size: 1.0625rem;
  font-weight: 500;
  color: var(--text-secondary);
  line-height: 1.5;
  max-width: 360px;
  margin: 0 auto;
}

.quiz-error {
  min-height: 1.25rem;
  font-size: 0.9375rem;
  font-weight: 600;
  color: #f87171;
  margin: 0;
  transition: opacity 0.2s;
}

.quiz-error:empty {
  display: none;
}

.quiz-error.success {
  color: var(--gold-light);
}

/* ============================================
   Footer — реквизиты
   ============================================ */
.site-footer {
  padding: var(--space-lg) var(--space-md);
  background: var(--bg-primary);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  text-align: center;
}

.site-footer-name,
.site-footer-inn {
  font-size: 0.8125rem;
  color: var(--text-secondary);
  margin: 2px 0;
}
