/* ============================================
   LOGIN PAGE
   ============================================ */

.login-page {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
}

/* Left pane — brand / benefits */
.login-brand-pane {
  position: relative;
  padding: 56px 64px;
  background: var(--gradient);
  color: white;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  isolation: isolate;
}
.login-brand-pane::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 80%, rgba(255, 255, 255, 0.3), transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.2), transparent 50%);
  z-index: -1;
}
.login-brand-pane::after {
  content: "";
  position: absolute;
  width: 480px;
  height: 480px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.25), transparent 70%);
  filter: blur(40px);
  top: -120px;
  right: -120px;
  z-index: -1;
  animation: blob-pulse 8s ease-in-out infinite;
}

.login-brand-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.login-brand-top .brand {
  color: white;
}
.login-brand-top .brand-mark {
  background: rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.3);
}
.back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: rgba(255, 255, 255, 0.85);
  font-size: 14px;
  padding: 8px 14px;
  border-radius: 100px;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  transition: background 0.2s, transform 0.2s;
  white-space: nowrap;
}
.back-link:hover {
  background: rgba(255, 255, 255, 0.2);
  transform: translateY(-1px);
}

.login-brand-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
}

.login-mascot-stage {
  position: absolute;
  inset: auto -40px -120px auto;
  width: 380px;
  height: 380px;
  pointer-events: none;
  opacity: 0.95;
}

.login-eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  opacity: 0.8;
  margin-bottom: 18px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.login-eyebrow::before {
  content: "";
  width: 24px;
  height: 1px;
  background: white;
}

.login-h1 {
  font-family: var(--font-display);
  font-size: clamp(42px, 5vw, 64px);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.02;
  margin-bottom: 18px;
  max-width: 14ch;
  color: white;
}
.login-h1 .squiggle {
  position: relative;
  display: inline-block;
}
.login-h1 .squiggle::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -6px;
  height: 10px;
  background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 14' preserveAspectRatio='none'><path d='M0 7 Q 15 0 30 7 T 60 7 T 90 7 T 120 7' stroke='white' stroke-width='3' fill='none' stroke-linecap='round'/></svg>") repeat-x;
  background-size: 60px 10px;
  opacity: 0.7;
}

.login-lede {
  font-size: 18px;
  line-height: 1.45;
  opacity: 0.9;
  max-width: 38ch;
  margin-bottom: 36px;
  text-wrap: pretty;
}

.login-benefits {
  display: grid;
  gap: 14px;
  max-width: 480px;
  position: relative;
  z-index: 2;
}
.login-benefit {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 16px 18px;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 18px;
  transition: transform 0.3s, background 0.3s;
}
.login-benefit:hover {
  transform: translateX(6px);
  background: rgba(255, 255, 255, 0.18);
}
.login-benefit-icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 12px;
  background: white;
  color: var(--ink);
  display: grid;
  place-items: center;
}
.login-benefit-icon svg { width: 20px; height: 20px; }
.login-benefit-text {
  font-size: 15px;
  line-height: 1.4;
  padding-top: 7px;
}
.login-benefit-text strong {
  display: block;
  font-weight: 600;
  margin-bottom: 2px;
}

.login-brand-footer {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 24px;
  padding-top: 32px;
  font-size: 13px;
  opacity: 0.75;
  font-family: var(--font-mono);
}
.login-brand-footer .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--mint);
  box-shadow: 0 0 0 4px rgba(136, 239, 209, 0.3);
}

/* Right pane — form */
.login-form-pane {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 56px 64px;
  position: relative;
}
.login-form {
  width: 100%;
  max-width: 440px;
}

.login-form-head {
  margin-bottom: 32px;
}
.login-form-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px 6px 10px;
  border-radius: 100px;
  background: var(--bg-card);
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-2);
  margin-bottom: 18px;
}
.login-form-tag::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gradient);
}
.login-form-title {
  font-family: var(--font-display);
  font-size: 38px;
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.05;
  margin-bottom: 8px;
}
.login-form-sub {
  color: var(--ink-2);
  font-size: 15px;
}

.field {
  display: block;
  margin-bottom: 16px;
}
.field-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}
.field-label-text {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
}
.field-hint {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--ink-3);
}
.field-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.field-input {
  width: 100%;
  padding: 16px 18px 16px 48px;
  background: var(--bg-card);
  border: 1.5px solid var(--line);
  border-radius: 16px;
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--ink);
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}
.field-input::placeholder { color: var(--ink-3); }
.field-input:hover { border-color: #d8cec0; }
.field-input:focus {
  outline: none;
  border-color: var(--violet);
  box-shadow: 0 0 0 4px rgba(91, 141, 239, 0.15);
}
.field-input.has-value { border-color: #d8cec0; }
.field-icon {
  position: absolute;
  left: 16px;
  pointer-events: none;
  color: var(--ink-3);
  display: grid;
  place-items: center;
}
.field-input:focus + .field-icon,
.field-input-wrap:has(.field-input:focus) .field-icon {
  color: var(--violet);
}
.field-trailing {
  position: absolute;
  right: 8px;
  background: none;
  border: none;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  color: var(--ink-3);
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.field-trailing:hover {
  background: var(--bg);
  color: var(--ink);
}
.field-err {
  font-size: 12px;
  color: #e74c5a;
  margin-top: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.form-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 14px 0 26px;
  font-size: 14px;
}
.checkbox-row {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  user-select: none;
  white-space: nowrap;
}
.checkbox-row input { display: none; }
.checkbox-box {
  width: 20px;
  height: 20px;
  border-radius: 6px;
  border: 1.5px solid var(--line);
  background: var(--bg-card);
  display: grid;
  place-items: center;
  transition: border-color 0.2s, background 0.2s;
}
.checkbox-row input:checked + .checkbox-box {
  background: var(--gradient);
  border-color: transparent;
}
.checkbox-row input:checked + .checkbox-box svg {
  opacity: 1;
  transform: scale(1);
}
.checkbox-box svg {
  opacity: 0;
  transform: scale(0.5);
  transition: opacity 0.2s, transform 0.2s;
}
.forgot-link {
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 500;
  position: relative;
  white-space: nowrap;
}
.forgot-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 1px;
  background: currentColor;
  opacity: 0.4;
  transform: scaleX(0.6);
  transform-origin: left;
  transition: opacity 0.2s, transform 0.2s;
}
.forgot-link:hover { color: var(--ink); }
.forgot-link:hover::after { opacity: 1; transform: scaleX(1); }

.login-cta {
  width: 100%;
  padding: 18px;
  background: var(--ink);
  color: white;
  border-radius: 100px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.3s;
  position: relative;
  overflow: hidden;
  isolation: isolate;
}
.login-cta::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--gradient);
  opacity: 0;
  transition: opacity 0.3s;
  z-index: -1;
}
.login-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 40px -12px rgba(87, 217, 176, 0.5);
}
.login-cta:hover::before { opacity: 1; }
.login-cta:disabled {
  background: #d8cec0;
  cursor: not-allowed;
  transform: none;
}
.login-cta:disabled::before { opacity: 0; }
.login-cta .arrow { transition: transform 0.3s; }
.login-cta:hover .arrow { transform: translateX(4px); }

.divider {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 28px 0 22px;
  color: var(--ink-3);
  font-size: 12px;
  font-family: var(--font-mono);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}
.divider::before, .divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line);
}

.telegram-btn {
  width: 100%;
  padding: 16px;
  background: var(--bg-card);
  border: 1.5px solid var(--line);
  border-radius: 100px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 15px;
  color: var(--ink);
  cursor: pointer;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
  position: relative;
  overflow: hidden;
  white-space: nowrap;
}
.telegram-btn::before {
  content: "";
  position: absolute;
  top: -50%;
  right: -10%;
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, rgba(91, 141, 239, 0.15), transparent 60%);
  pointer-events: none;
}
.telegram-btn:hover {
  border-color: #5b8def;
  transform: translateY(-2px);
  box-shadow: 0 16px 32px -12px rgba(91, 141, 239, 0.4);
}
.telegram-btn .tg-icon {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, #5b8def, #88bbef);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}
.telegram-btn .tg-icon svg { width: 16px; height: 16px; color: white; }

.tg-note {
  font-size: 13px;
  color: var(--ink-2);
  text-align: center;
  margin: 16px 0 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  line-height: 1.5;
}
.tg-note svg { flex-shrink: 0; color: var(--ink-3); }

.signup-row {
  text-align: center;
  font-size: 14px;
  color: var(--ink-2);
  padding-top: 22px;
  border-top: 1px solid var(--line);
}
.signup-row a {
  color: var(--ink);
  font-weight: 600;
  position: relative;
}
.signup-row a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 2px;
  background: var(--gradient);
  border-radius: 1px;
}

/* Decorative floating shapes on form pane */
.form-deco {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  opacity: 0.5;
  filter: blur(60px);
}

/* Mobile login */
@media (max-width: 980px) {
  .login-page { grid-template-columns: 1fr; }
  .login-brand-pane {
    padding: 36px 28px 48px;
    min-height: 380px;
  }
  .login-mascot-stage { width: 240px; height: 240px; inset: auto -20px -80px auto; }
  .login-h1 { font-size: 36px; }
  .login-lede { font-size: 16px; margin-bottom: 24px; }
  .login-benefits { gap: 10px; }
  .login-benefit { padding: 12px 14px; }
  .login-benefit-text { font-size: 14px; }
  .login-brand-footer { display: none; }
  .login-form-pane { padding: 40px 24px 56px; }
  .login-form-title { font-size: 30px; }
}

@media (max-width: 480px) {
  .login-brand-pane { padding: 28px 22px 40px; }
  .login-mascot-stage { width: 200px; height: 200px; }
  .login-h1 { font-size: 30px; }
  .login-form-pane { padding: 32px 20px 48px; }
  .form-row { flex-direction: column; align-items: flex-start; gap: 12px; }
}


/* --- Регистрация: индикатор шагов (1—2—3 / Аккаунт · Тариф · Готово) --- */
.reg-step { display:flex; align-items:center; justify-content:center; flex-wrap:wrap; gap:8px; margin:0 0 22px; }
.reg-step-dot { display:inline-flex; align-items:center; justify-content:center; width:30px; height:30px; border-radius:50%; background:#ececf2; color:#9a9aa6; font-weight:700; font-size:14px; flex:0 0 auto; line-height:1; }
.reg-step-dot-active { background:linear-gradient(135deg,#5b8def,#5b8def); color:#fff; box-shadow:0 4px 12px rgba(120,110,255,.35); }
.reg-step-line { width:26px; height:2px; border-radius:2px; background:#e2e2ea; flex:0 0 auto; }
.reg-step-lbl { flex-basis:100%; text-align:center; font-size:13px; color:#9a9aa6; margin-top:8px; letter-spacing:.01em; }


/* --- Telegram bot-deeplink вход (работает в РФ без VPN) --- */
.tg-app-btn { display:flex; align-items:center; justify-content:center; gap:8px; width:100%; padding:13px 18px; border:none; border-radius:12px; background:#229ED9; color:#fff; font-weight:600; font-size:15px; cursor:pointer; transition:opacity .15s, transform .05s; }
.tg-app-btn:hover { opacity:.92; }
.tg-app-btn:active { transform:translateY(1px); }
.tg-app-btn:disabled { opacity:.6; cursor:default; }

/* --- Фикс мобильной вёрстки: переносы в строках согласий (текст уходил за экран) --- */
.checkbox-row.consent-row {
  white-space: normal;
  align-items: flex-start;
}
.checkbox-row.consent-row .checkbox-box { margin-top: 1px; flex: 0 0 auto; }
.consents {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin: 4px 0 8px;
}
.consent-text {
  white-space: normal;
  overflow-wrap: anywhere;
  min-width: 0;
  font-size: 13.5px;
  line-height: 1.45;
  color: var(--ink-2);
}
.consent-text a { color: var(--ink); text-decoration: underline; text-underline-offset: 2px; }
.consent-text-muted { color: var(--ink-3); }

/* --- Мобильные страховки (аудит 16.07.2026): ничего не должно уходить за экран --- */
@media (max-width: 480px) {
  .login-brand-top { flex-wrap: wrap; }
  .field-label { flex-wrap: wrap; row-gap: 2px; }
  .field-hint { white-space: normal; }
  .reg-step-lbl { white-space: normal; text-align: center; }
  .login-form { min-width: 0; }
  .login-form-pane { min-width: 0; }
}
.login-page { overflow-x: clip; }

/* ============ chill vpn: новый дизайн (24.09.2026) ============ */
/* бонус-карточка регистрации: стили раньше жили только в шаблоне восстановления пароля */
.bonus-card { margin-top: 22px; padding: 16px 18px; border-radius: 18px; background: rgba(255,255,255,0.14);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px); border: 1px solid rgba(255,255,255,0.22); max-width: 420px; }
.bonus-card-pill { display: inline-block; margin-bottom: 10px; padding: 4px 10px; border-radius: 100px; background: rgba(255,255,255,0.22);
  font-size: 11px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; }
.bonus-card-main { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.bonus-card-amount { display: flex; align-items: center; gap: 10px; }
.bonus-card-num { font-family: var(--font-display); font-size: 52px; font-weight: 700; line-height: 1; }
.bonus-card-unit { font-weight: 700; font-size: 16px; }
.bonus-card-sub { font-size: 13px; opacity: 0.85; }
.bonus-card-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; font-size: 14px; line-height: 1.4; }
.bonus-card-list li { display: flex; align-items: center; gap: 8px; }
/* собачка — поверх стеклянных карточек (иначе размывается), чуть меньше */
@media (min-width: 981px) { .login-mascot-stage { width: 290px; height: 290px; inset: auto -10px -30px auto; z-index: 3; opacity: 1; } }
/* белый текст на светлой мяте — лёгкая тень для читаемости */
.login-h1, .login-eyebrow { text-shadow: 0 2px 14px rgba(20, 60, 110, 0.22); }
/* карточки не уходят под собачку */
@media (min-width: 981px) { .login-benefits { max-width: calc(100% - 230px); } }
/* 27.09.2026: на телефоне собачке негде стоять на входе (карточки на всю ширину — просвечивала сквозь стекло)
   и в «Как это работает» восстановления (закрывала строки). На регистрации рядом с коротким списком ей место есть. */
@media (max-width: 980px) {
  .login-benefits ~ .login-mascot-stage,
  .bonus-card:not(:has(.bonus-card-amount)) ~ .login-mascot-stage { display: none; }
}

/* 29.09.2026: ободок при наведении — см. styles.css */
.login-cta:hover:not(:disabled) { border-color: transparent; background: var(--gradient) border-box; }
