/* ---------- Tokens (from Figma variables) ---------- */
:root {
  --c-white: #ffffff;
  --c-dark: #121416;
  --c-dark-gradient: #1c1e21;
  --c-red: #ee3c3b;
  --c-blue: #4f5ce8;
  --c-grey: #d6d6d6;
  --c-text-dark: #121416;
  --c-text-dark-gray: #1e2027;
  --c-text-light: #808080;
  --c-bg-light: #f7f8fb;
  --c-border: #e6ebf5;

  --font-sans: "Inter", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  --font-display: "DM Sans", "Inter", system-ui, sans-serif;

  --radius-block-s: 9px;
  --radius-block-m: 16px;
  --radius-tag: 100px;
  --radius-checkbox: 3px;

  --page-pad-x: 16px;
  --page-pad-y: 72px;
  --container-w: 1224px;
}

/* ---------- Reset ---------- */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font-sans);
  color: var(--c-text-dark);
  background: var(--c-white);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.4;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { border: none; background: none; font: inherit; color: inherit; cursor: pointer; }
ul { list-style: none; padding: 0; margin: 0; }
input, button { font-family: inherit; }

/* ---------- Navigation ---------- */
.nav {
  position: sticky;
  top: 8px;
  z-index: 50;
  margin: 8px 8px 0;
  background: linear-gradient(to right, var(--c-dark), var(--c-dark-gradient));
  border-radius: var(--radius-block-s);
}
.nav__inner {
  max-width: var(--container-w);
  margin: 0 auto;
  height: 64px;
  padding: 0 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}
.logo {
  display: inline-flex;
  align-items: center;
  gap: 9.593px;
}
.logo__x { width: 37.198px; height: 25.436px; }
.logo__text { width: 67.209px; height: 18.652px; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 46px;
  padding: 8px 16px;
  border-radius: var(--radius-block-s);
  font-weight: 600;
  font-size: 16px;
  letter-spacing: -0.5px;
  white-space: nowrap;
  transition: opacity .15s ease, transform .05s ease;
}
.btn:hover { opacity: .92; }
.btn:active { transform: scale(.98); }
.btn--back { background: var(--c-red); color: var(--c-white); }
.btn--primary {
  background: var(--c-red);
  color: var(--c-white);
  height: 56px;
  padding: 8px 36px;
  width: 100%;
}
.btn--primary img { height: 14px; width: 20.474px; }

/* ---------- Page main block ---------- */
.page {
  width: 100%;
  padding: var(--page-pad-y) var(--page-pad-x);
}
.block {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  justify-content: center;
  gap: 24px;
  max-width: var(--container-w);
  margin: 0 auto;
}

/* ---------- Card base ---------- */
.card {
  border-radius: var(--radius-block-m);
  width: 600px;
  flex: 1 0 0;
  min-width: 0;
}

/* ---------- Dark promo card ---------- */
.card--dark {
  position: relative;
  height: 734px;
  padding: 46px 36px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: var(--c-white);
  overflow: hidden;
  background-image: url("../images/card-bg.png");
  background-size: cover;
  background-position: center;
  background-color: var(--c-dark);
  flex: 0 0 600px;
}

.tags {
  display: flex;
  gap: 8px;
}
.tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  height: 37px;
  padding: 0 12px;
  border-radius: var(--radius-tag);
  font-size: 14px;
  font-weight: 500;
  line-height: 28px;
  color: var(--c-white);
  white-space: nowrap;
  background: linear-gradient(265deg, rgba(255, 255, 255, 0.20) -21.2%, rgba(255, 255, 255, 0.04) 284.15%);
}
.tag img { width: 13px; height: 13px; flex-shrink: 0; }

.card__heading { display: flex; flex-direction: column; gap: 16px; }
.card__lead {
  margin: 0;
  font-size: 16px;
  line-height: 26px;
  letter-spacing: -0.5px;
  color: var(--c-grey);
}
.strong-white { color: var(--c-white); font-weight: 600; letter-spacing: -0.5px; }
.strong-lg { font-size: 18px; line-height: 30px; }
.accent-red { color: var(--c-red); }

.h2 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 36px;
  line-height: 42px;
  letter-spacing: -1px;
  color: var(--c-text-dark);
}
.h2--inverse { color: var(--c-white); }

.features {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.feature {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 16px;
  font-weight: 600;
  line-height: 24px;
  letter-spacing: -0.5px;
  color: var(--c-white);
}
.feature p { margin: 0; flex: 1; }
.feature__icon {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 180px;
  border: 0.9px solid rgba(255, 255, 255, 0.5);
  background-image: linear-gradient(77deg, rgba(255, 255, 255, 0.2) 10%, rgba(255, 255, 255, 0.035) 119%);
  backdrop-filter: blur(63px);
  -webkit-backdrop-filter: blur(63px);
  box-shadow: 0 2.154px 53.847px 0 rgba(69, 42, 124, 0.1);
}
.feature__icon img { width: 19.8px; height: 19.8px; }

/* ---------- Light registration card ---------- */
.card--light {
  background: var(--c-white);
  border: 1px solid var(--c-border);
  padding: 46px 36px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  flex: 1 1 600px;
  height: 734px;
}
.card-light__header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  width: 100%;
}

/* Stepper */
.stepper {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  width: 100%;
  max-width: 526px;
}
.stepper__bar {
  display: flex;
  align-items: center;
  width: 100%;
  justify-content: center;
}
.step {
  position: relative;
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
}
.step__circle { position: absolute; inset: 0; width: 32px; height: 32px; }
.step__icon {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 14px;
  height: 14px;
  transform: translate(-50%, -50%);
}
.stepper__line {
  flex: 1;
  height: 2px;
  background: var(--c-border);
  max-width: 243px;
}
.stepper__labels {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  width: 100%;
  gap: 16px;
}
.stepper__label {
  flex: 1;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.stepper__title {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  line-height: 22px;
  letter-spacing: -0.5px;
  color: var(--c-text-dark-gray);
}
.stepper__desc {
  margin: 0;
  font-size: 12px;
  line-height: 20px;
  color: var(--c-text-light);
}
.stepper__label--muted .stepper__title,
.stepper__label--muted .stepper__desc { color: var(--c-text-light); opacity: .5; }

.card-light__title {
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 4px;
  width: 100%;
}
.card-light__lead {
  margin: 0;
  font-size: 16px;
  line-height: 26px;
  letter-spacing: -0.5px;
  color: var(--c-text-dark-gray);
}
.muted-12 {
  margin: 0;
  font-size: 12px;
  line-height: 20px;
  color: var(--c-text-light);
}
.center { text-align: center; }

/* ---------- Form ---------- */
#emailSuggestion:empty,
#formError:empty { display: none; }

.form {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 528px;
  max-width: 100%;
}
.input {
  display: flex;
  align-items: center;
  height: 56px;
  padding: 16px 24px;
  background: var(--c-bg-light);
  border-radius: var(--radius-block-s);
  width: 100%;
}
.input input {
  flex: 1;
  width: 100%;
  border: none;
  outline: none;
  background: transparent;
  font-size: 16px;
  letter-spacing: -0.5px;
  color: var(--c-text-dark);
  line-height: 26px;
}
.input input::placeholder { color: var(--c-text-light); }

.input-phone {
  display: flex;
  gap: 8px;
  width: 100%;
}
.phone-code {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 56px;
  width: 128px;
  flex: 0 0 128px;
  padding: 16px 24px;
  background: var(--c-bg-light);
  border-radius: var(--radius-block-s);
  font-size: 16px;
  letter-spacing: -0.5px;
  color: var(--c-text-dark);
}
.phone-flag {
  display: inline-block;
  border-radius: 5px;
  flex-shrink: 0;
  font-size: 20px;
}
.phone-code__arrow { width: 24px; height: 24px; }
.phone-code__value { line-height: 26px; }
.input--phone { flex: 1; min-width: 0; }

/* Agreement / checkbox */
.agreement {
  display: flex;
  gap: 9px;
  align-items: flex-start;
  width: 528px;
  max-width: 100%;
  font-size: 12px;
  line-height: 20px;
  color: var(--c-text-dark);
  cursor: pointer;
}
.agreement input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
  width: 1px;
  height: 1px;
  margin: 0;
  padding: 0;
}
.agreement__box {
  flex: 0 0 24px;
  width: 24px;
  height: 24px;
  border: 1.263px solid var(--c-border);
  background: var(--c-white);
  border-radius: var(--radius-checkbox);
  position: relative;
}
.agreement input:checked + .agreement__box,
.agreement__box.is-checked {
  background: var(--c-blue);
  border-color: var(--c-blue);
}
.agreement input:checked + .agreement__box::after,
.agreement__box.is-checked::after {
  content: "";
  position: absolute;
  left: 7px;
  top: 3px;
  width: 7px;
  height: 12px;
  border: solid var(--c-white);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.agreement__text a { color: var(--c-blue); }
.agreement__text a:hover { text-decoration: underline; }

/* Primary button — reset width inside light card */
.card--light .btn--primary { width: auto; padding: 8px 36px; }

.signin {
  margin: 0;
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 16px;
  letter-spacing: -0.5px;
}
.signin span { color: var(--c-dark); }
.signin a { color: var(--c-blue); font-weight: 600; line-height: 22px; }
.signin a:hover { text-decoration: underline; }

/* ---------- Footer ---------- */
.footer {
  background: linear-gradient(to right, var(--c-dark), var(--c-dark-gradient));
  color: var(--c-text-light);
  padding: var(--page-pad-y) var(--page-pad-x);
}
.footer__inner {
  max-width: var(--container-w);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 46px;
}
.footer__cols {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 24px;
  width: 100%;
}
.footer__col,
.footer__list { width: 288px; }
.footer__col--brand {
  display: flex;
  align-items: center;
}
.ssl {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 16px;
  color: var(--c-text-light);
  line-height: 26px;
  letter-spacing: -0.5px;
}
.ssl img { width: 21.75px; height: 25.375px; object-fit: contain; }

.footer__bottom {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
}
.footer__copy {
  flex: 1;
  margin: 0;
  font-size: 16px;
  line-height: 26px;
  letter-spacing: -0.5px;
  color: var(--c-text-light);
}

.footer__list {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.footer__list a {
  font-size: 16px;
  line-height: 24px;
  letter-spacing: -0.5px;
  color: var(--c-text-light);
}
.footer__list a:hover { color: var(--c-white); }

.footer__hr {
  border: none;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin: 0;
  width: 100%;
}
.footer__hr--mobile { display: none; }
.logo__news { width: 65.608px; height: 19.586px; }
.footer__list-item--mobile { display: none; }
.footer__list-item--desktop { display: list-item; }

.footer__legal {
  display: flex;
  flex-direction: column;
  gap: 24px;
  font-size: 16px;
  line-height: 26px;
  letter-spacing: -0.5px;
  color: var(--c-text-light);
}
.footer__legal p { margin: 0; }
.footer__legal strong { color: var(--c-white); font-weight: 400; }
.footer__legal a { color: var(--c-text-light); text-decoration: underline; }
.footer__legal a:hover { color: var(--c-white); }

/* ---------- Tablet / narrow desktop: cards stack ---------- */
@media (max-width: 1256px) {
  .block { flex-direction: column-reverse; flex-wrap: nowrap; }
  .card { width: 100%; flex: 0 0 auto; }
  .card--dark { width: 100%; max-width: 600px; flex: 0 0 auto; }
  .card--light { width: 100%; max-width: 600px; flex: 0 0 auto; }
}

/* ---------- Mobile (375px design) ---------- */
@media (max-width: 640px) {
  :root {
    --page-pad-x: 16px;
    --page-pad-y: 36px;
  }

  .nav { margin: 8px; }
  .nav__inner { height: 64px; padding: 16px; }
  .btn--back { height: 46px; padding: 4px 12px; }

  .page { padding: 36px 16px 54px; }
  .block {
    flex-direction: column-reverse;
    gap: 24px;
    align-items: center;
  }

  .card { max-width: 344px; width: 100%; }

  /* Light card first on mobile */
  .card--dark { height: auto; }
  .card--light {
    height: auto;
    padding: 24px 16px;
    gap: 24px;
  }
  .card-light__header { gap: 24px; }

  /* Stepper compact */
  .stepper__line { max-width: 124px; }
  .stepper__labels { gap: 0; }
  .stepper__label { width: 156px; flex: 1; }

  .h2 { font-size: 24px; line-height: 32px; }
  .card-light__lead { font-size: 16px; line-height: 26px; }

  .form { width: 312px; max-width: 100%; gap: 12px; }
  .input { padding: 12px 24px; }
  .input-phone { gap: 8px; }
  .phone-code { padding: 12px 24px; gap: 8px; }

  .agreement { width: 100%; }

  .card--light .btn--primary { width: 100%; padding: 8px 16px; gap: 4px; }
  .btn--primary { padding: 8px 16px; }

  /* Dark card */
  .card--dark {
    padding: 24px 16px;
    height: auto;
    gap: 24px;
    flex: 0 0 auto;
  }
  .card__heading { gap: 12px; }
  .features { gap: 12px; }
  .feature { gap: 12px; }
  .card--dark .accent-red { color: var(--c-red); }

  .tags { gap: 4px; width: 100%; }
  .tag { flex: 1; padding: 0 6px; gap: 4px; }

  /* Footer */
  .footer { padding: 54px 16px; }
  .footer__inner { gap: 36px; padding: 0; }
  .footer__cols {
    gap: 36px 24px;
    flex-direction: row;
    flex-wrap: wrap;
    align-content: flex-start;
  }
  .footer__col--brand { width: 100%; height: auto; gap: 24px; }
  .footer__list { gap: 24px; flex: 1 0 0; min-width: 0; width: auto; }
  .footer__list a { font-size: 14px; line-height: 24px; letter-spacing: -0.3px; }
  .footer__list--desktop { display: none; }
  .footer__list-item--desktop { display: none; }
  .footer__list-item--mobile { display: list-item; }

  .footer__hr--mobile { display: block; }
  .footer__legal { gap: 36px; }
  .footer__legal strong { color: var(--c-white); }
  .footer__legal p { line-height: 24px; font-size: 12px; }
  .footer__legal p a { font-size: 12px; }

  .footer__bottom { flex-direction: column; align-items: flex-start; gap: 36px; }
  .footer__copy { font-size: 12px; line-height: 24px; letter-spacing: 0; }
  .ssl { font-size: 12px; line-height: 24px; gap: 4px; }
  .ssl img { width: 16.25px; height: 18.958px; }
}

