/* Эскадра — premium 2026 automotive */
:root {
  --bg: #0B0D10;
  --bg-elevated: #12151A;
  --gold: #C9A96E;
  --gold-soft: #E0C892;
  --gold-dim: rgba(201, 169, 110, 0.35);
  --text: #F2EDE4;
  --text-muted: #8A8580;
  --line: rgba(242, 237, 228, 0.12);
  --glass: rgba(18, 21, 26, 0.72);
  --glass-border: rgba(201, 169, 110, 0.22);
  --danger: #E07A6A;
  --font-display: "Syne", sans-serif;
  --font-body: "Instrument Sans", sans-serif;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

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

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

body {
  min-height: 100%;
  font-family: var(--font-body);
  font-weight: 400;
  color: var(--text);
  background: var(--bg);
  line-height: 1.5;
  overflow-x: hidden;
}

a {
  color: var(--gold);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--gold-soft);
}

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

button,
input {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  border: none;
  background: none;
}

/* Grain overlay */
.grain {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 50;
  opacity: 0.045;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ===== SPLIT HERO ===== */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 100vh;
  min-height: 100dvh;
  position: relative;
}

.split__left {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(1.25rem, 3vw, 2.5rem) clamp(1.5rem, 4vw, 4rem);
  background: var(--bg);
  position: relative;
  z-index: 2;
}

.split__left::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 1px;
  height: 100%;
  background: linear-gradient(180deg, transparent, var(--gold-dim), transparent);
}

.brand {
  flex-shrink: 0;
}

.brand__name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.35rem, 2.2vw, 1.75rem);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text);
}

.brand__name:hover {
  color: var(--gold);
}

.split__content {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 2rem 0;
  max-width: 34rem;
}

.split__title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2.4rem, 5.2vw, 4.25rem);
  line-height: 0.95;
  letter-spacing: -0.03em;
  text-align: left;
  margin-bottom: 1.5rem;
}

.split__line {
  display: block;
}

.split__line--accent {
  color: var(--gold);
}

.split__line--muted {
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.72em;
  margin-top: 0.15em;
  letter-spacing: -0.02em;
}

.split__desc {
  text-align: left;
  color: var(--text-muted);
  font-size: clamp(0.95rem, 1.3vw, 1.05rem);
  max-width: 28rem;
  margin-bottom: 2rem;
  line-height: 1.65;
}

/* Features — numbered rules */
.features {
  list-style: none;
  margin-bottom: 2.25rem;
  max-width: 28rem;
}

.features__item {
  display: grid;
  grid-template-columns: 2.5rem 1fr;
  gap: 1rem;
  align-items: baseline;
  padding: 0.85rem 0;
  border-top: 1px solid var(--line);
  text-align: left;
}

.features__item:last-child {
  border-bottom: 1px solid var(--line);
}

.features__num {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.8rem;
  color: var(--gold);
  letter-spacing: 0.06em;
}

.features__text {
  font-size: 0.95rem;
  color: var(--text);
  font-weight: 500;
}

/* CTA — spring fly-in */
.cta {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 1.05rem 2.1rem;
  background: var(--gold);
  color: var(--bg);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-radius: 2px;
  opacity: 0;
  transform: translateY(120%);
  animation: ctaSpring 1.05s var(--spring) 0.45s forwards;
  transition: background 0.25s ease, transform 0.25s var(--ease-out), box-shadow 0.25s ease;
}

.cta:hover {
  background: var(--gold-soft);
  box-shadow: 0 12px 40px rgba(201, 169, 110, 0.25);
}

.cta:active {
  transform: translateY(2px) scale(0.98);
}

@keyframes ctaSpring {
  0% {
    opacity: 0;
    transform: translateY(120%);
  }
  60% {
    opacity: 1;
    transform: translateY(-12%);
  }
  80% {
    transform: translateY(4%);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.split__foot {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.75rem;
  align-items: flex-start;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
}

.split__legal {
  flex: 1 1 100%;
  margin: 0;
  font-size: 0.68rem;
  line-height: 1.55;
  color: var(--text-muted);
}

.split__phone {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text);
  letter-spacing: 0.02em;
}

.split__privacy {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.split__privacy:hover {
  color: var(--gold);
}

/* Right panel — edge-to-edge photo */
.split__right {
  background-color: var(--bg-elevated);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  position: relative;
  min-height: 50vh;
}

.split__right::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(11, 13, 16, 0.55) 0%, transparent 35%),
    linear-gradient(180deg, transparent 60%, rgba(11, 13, 16, 0.35) 100%);
  pointer-events: none;
}

/* ===== QUIZ ===== */
.quiz {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
}

.quiz[hidden] {
  display: none;
}

.quiz.is-open {
  display: flex;
}

.quiz__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 6, 8, 0.78);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  animation: fadeIn 0.35s ease;
}

.quiz__panel {
  position: relative;
  width: min(560px, 100%);
  max-height: min(92vh, 820px);
  overflow-y: auto;
  padding: clamp(1.75rem, 4vw, 2.5rem);
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(24px) saturate(1.2);
  -webkit-backdrop-filter: blur(24px) saturate(1.2);
  animation: panelIn 0.45s var(--ease-out);
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes panelIn {
  from {
    opacity: 0;
    transform: translateY(28px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.quiz__close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  border-radius: 50%;
  transition: color 0.2s, background 0.2s;
}

.quiz__close:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
}

.quiz__progress {
  height: 2px;
  background: var(--line);
  border-radius: 1px;
  margin-bottom: 1.75rem;
  overflow: hidden;
}

.quiz__bar {
  height: 100%;
  width: 25%;
  background: linear-gradient(90deg, var(--gold), var(--gold-soft));
  border-radius: 1px;
  transition: width 0.4s var(--ease-out);
}

.quiz__step {
  display: none;
}

.quiz__step.is-active {
  display: block;
  animation: stepIn 0.35s var(--ease-out);
}

@keyframes stepIn {
  from {
    opacity: 0;
    transform: translateX(16px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.quiz__step-label {
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  font-family: var(--font-display);
  font-weight: 600;
  margin-bottom: 0.65rem;
}

.quiz__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.35rem, 3vw, 1.7rem);
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-bottom: 1.5rem;
  text-align: left;
}

.quiz__subtitle {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin: -0.75rem 0 1.5rem;
  text-align: left;
}

.quiz__options {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin-bottom: 1.75rem;
}

.quiz__option {
  width: 100%;
  text-align: left;
  padding: 1.05rem 1.35rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  font-size: 1rem;
  font-weight: 500;
  transition: border-color 0.2s, background 0.2s, color 0.2s, transform 0.2s var(--ease-out);
}

.quiz__option:hover {
  border-color: var(--gold-dim);
  background: rgba(201, 169, 110, 0.08);
  transform: translateX(4px);
}

.quiz__option.is-selected {
  border-color: var(--gold);
  background: rgba(201, 169, 110, 0.14);
  color: var(--gold-soft);
  box-shadow: inset 0 0 0 1px var(--gold);
}

.quiz__nav {
  display: flex;
  gap: 0.75rem;
  align-items: center;
}

.quiz__next,
.quiz__submit {
  flex: 1;
  padding: 1rem 1.5rem;
  background: var(--gold);
  color: var(--bg);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-radius: 999px;
  transition: background 0.2s, opacity 0.2s;
}

.quiz__next:hover:not(:disabled),
.quiz__submit:hover:not(:disabled) {
  background: var(--gold-soft);
}

.quiz__next:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.quiz__back {
  padding: 1rem 1.25rem;
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 500;
  border-radius: 999px;
  transition: color 0.2s, background 0.2s;
}

.quiz__back:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.05);
}

.quiz__form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.quiz__label {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  text-align: left;
}

.quiz__label span {
  font-size: 0.8rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-weight: 500;
}

.quiz__label input {
  width: 100%;
  padding: 0.95rem 1.15rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  border-radius: 12px;
  outline: none;
  transition: border-color 0.2s, background 0.2s;
}

.quiz__label input:focus {
  border-color: var(--gold);
  background: rgba(201, 169, 110, 0.06);
}

.quiz__label input.error,
.quiz__form input.error {
  border-color: var(--danger) !important;
}

.quiz__consent {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.45;
}

.quiz__consent a {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.iti {
  width: 100%;
  display: block;
}

.iti__country-list {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  color: var(--text);
  z-index: 120;
}

body.quiz-open {
  overflow: hidden;
}

/* ===== LEGAL / THANK pages ===== */
.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
}

.page__header-bar {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: end;
  padding: clamp(1.5rem, 4vw, 3rem) clamp(1.5rem, 5vw, 4rem);
  border-bottom: 1px solid var(--line);
}

.page__header-left .brand__name {
  display: inline-block;
  margin-bottom: 1.5rem;
}

.page__back {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.page__back:hover {
  color: var(--gold);
}

.page__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  letter-spacing: -0.02em;
  line-height: 1.15;
}

.page__header-right {
  text-align: right;
  color: var(--text-muted);
  font-size: 0.85rem;
  line-height: 1.6;
}

.page__header-right strong {
  display: block;
  color: var(--gold);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  margin-bottom: 0.35rem;
}

.page__main {
  flex: 1;
  padding: clamp(2rem, 5vw, 3.5rem) clamp(1.5rem, 5vw, 4rem);
  max-width: 820px;
}

.legal-content h2 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  margin: 2rem 0 0.75rem;
  color: var(--gold-soft);
  letter-spacing: -0.01em;
}

.legal-content p,
.legal-content li {
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.7;
  margin-bottom: 0.75rem;
}

.legal-content ul {
  padding-left: 1.25rem;
  margin-bottom: 1rem;
}

.legal-content a {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.legal-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0 1.5rem;
  font-size: 0.85rem;
}

.legal-content th,
.legal-content td {
  border: 1px solid var(--line);
  padding: 0.75rem;
  text-align: left;
  vertical-align: top;
  color: var(--text-muted);
}

.legal-content th {
  background: rgba(201, 169, 110, 0.08);
  color: var(--gold);
  font-family: var(--font-display);
  font-weight: 600;
}

.legal-meta {
  margin-top: 2.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--line);
  font-size: 0.8rem !important;
  color: var(--text-muted);
}

.page__footer {
  padding: 1.5rem clamp(1.5rem, 5vw, 4rem);
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Thank page */
.thank {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
  position: relative;
}

.thank__left {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(2rem, 5vw, 4rem);
}

.thank__eyebrow {
  font-family: var(--font-display);
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1rem;
}

.thank__title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  line-height: 1;
  letter-spacing: -0.03em;
  margin-bottom: 1.25rem;
}

.thank__text {
  color: var(--text-muted);
  max-width: 26rem;
  margin-bottom: 2rem;
  line-height: 1.65;
}

.thank__btn {
  align-self: flex-start;
  display: inline-flex;
  padding: 0.95rem 1.75rem;
  background: transparent;
  border: 1px solid var(--gold);
  color: var(--gold);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  border-radius: 2px;
  transition: background 0.2s, color 0.2s;
}

.thank__btn:hover {
  background: var(--gold);
  color: var(--bg);
}

.thank__right {
  background: var(--bg-elevated) center / cover no-repeat;
  position: relative;
}

.thank__right::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(11, 13, 16, 0.7), transparent 40%);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  .split {
    grid-template-columns: 1fr;
    grid-template-rows: auto 42vh;
  }

  .split__left {
    order: 1;
    min-height: auto;
  }

  .split__left::after {
    display: none;
  }

  .split__right {
    order: 0;
    min-height: 42vh;
  }

  .split__right::before {
    background: linear-gradient(180deg, transparent 40%, var(--bg) 100%);
  }

  .split__content {
    padding: 1.5rem 0;
  }

  .page__header-bar {
    grid-template-columns: 1fr;
  }

  .page__header-right {
    text-align: left;
  }

  .thank {
    grid-template-columns: 1fr;
  }

  .thank__right {
    min-height: 36vh;
    order: -1;
  }
}

@media (max-width: 480px) {
  .quiz__nav {
    flex-direction: column-reverse;
  }

  .quiz__back,
  .quiz__next,
  .quiz__submit {
    width: 100%;
  }

  .features__item {
    grid-template-columns: 2rem 1fr;
    gap: 0.75rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cta {
    animation: none;
    opacity: 1;
    transform: none;
  }

  .quiz__panel,
  .quiz__step.is-active,
  .quiz__backdrop {
    animation: none;
  }
}
