/* Страница входа Estaro — фон как в основном приложении (3x-ui dark) */

@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap");
@import url("https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@500;600&display=swap");

:root {
  --login-gold: #d4af37;
  --login-gold-bright: #e8c96a;
  --login-surface: rgba(21, 31, 49, 0.92);
  --login-border: rgba(255, 255, 255, 0.12);
  --dark-color-background: #0a1222;
}

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

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

body.login-landing {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  color: rgba(255, 255, 255, 0.92);
  background-color: var(--dark-color-background);
  position: relative;
  overflow-x: hidden;
}

/* Сразу форма входа: без полноэкранных intro/stats при прокрутке */
body.login-landing--direct .login-intro-slide,
body.login-landing--direct .login-stats-section,
body.login-landing--direct .login-scroll-hint {
  display: none;
}

body.login-landing--direct .login-layout {
  min-height: 100dvh;
  align-items: center;
}

.login-mesh-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.login-layout {
  position: relative;
  z-index: 1;
  min-height: auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 440px);
  gap: clamp(24px, 4vw, 56px);
  align-items: center;
  max-width: 1180px;
  margin: 0 auto;
  padding: clamp(36px, 7vh, 72px) clamp(22px, 4vw, 48px) 48px;
  box-sizing: border-box;
}

.login-hero {
  padding-right: clamp(0px, 2vw, 20px);
  max-width: 540px;
}

.login-hero-kicker {
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
  margin: 0 0 14px;
  font-weight: 600;
}

.login-hero-title {
  font-size: clamp(1.65rem, 2.8vw, 2.25rem);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.02em;
  margin: 0 0 16px;
  color: rgba(255, 255, 255, 0.96);
}

.login-hero-title-line {
  display: block;
}

.login-hero-title-accent {
  display: block;
  margin-top: 4px;
  background: linear-gradient(105deg, var(--login-gold-bright), #6ec4b8 50%, var(--login-gold));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.login-hero-lead {
  font-size: clamp(0.94rem, 1.25vw, 1.04rem);
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.72);
  margin: 0 0 20px;
  max-width: 52ch;
}

.login-hero-list {
  margin: 0;
  padding: 0 0 0 1.15rem;
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.91rem;
  line-height: 1.55;
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 52ch;
}

.login-hero-list li::marker {
  color: rgba(0, 135, 113, 0.8);
}

@media (prefers-reduced-motion: no-preference) {
  .login-hero-kicker {
    animation: login-hero-in 0.65s cubic-bezier(0.22, 1, 0.36, 1) both;
  }

  .login-hero-title {
    animation: login-hero-in 0.65s cubic-bezier(0.22, 1, 0.36, 1) 0.06s both;
  }

  .login-hero-lead {
    animation: login-hero-in 0.65s cubic-bezier(0.22, 1, 0.36, 1) 0.12s both;
  }

  .login-hero-list {
    animation: login-hero-in 0.65s cubic-bezier(0.22, 1, 0.36, 1) 0.18s both;
  }
}

@keyframes login-hero-in {
  from {
    opacity: 0;
    transform: translateY(14px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

.login-intro-slide {
  position: relative;
  z-index: 1;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 80px 22px 40px;
  box-sizing: border-box;
}

.login-intro-inner {
  width: 100%;
  max-width: 720px;
  text-align: center;
}

.login-intro-kicker {
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.45);
  margin: 0 0 22px;
  font-weight: 600;
}

.login-scramble-headline {
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: clamp(1.2rem, 4vw, 2.2rem);
  font-weight: 600;
  line-height: 1.22;
  letter-spacing: -0.03em;
  margin: 0 auto 22px;
  min-height: 2.75em;
  max-width: 22ch;
  color: rgba(255, 255, 255, 0.93);
}

.login-intro-sub {
  font-size: clamp(0.92rem, 2.6vw, 1.05rem);
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.62);
  margin: 0 auto 8px;
  max-width: 38ch;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.55s cubic-bezier(0.22, 1, 0.36, 1), transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.login-intro-sub.login-intro-sub--visible {
  opacity: 1;
  transform: none;
}

.login-scroll-cue {
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.36);
  margin: 20px 0 0;
  padding-top: 4px;
}

.login-scroll-cue::after {
  content: "";
  display: block;
  width: 1px;
  height: 32px;
  margin: 14px auto 0;
  background: linear-gradient(180deg, rgba(212, 175, 55, 0.45), transparent);
}

@media (prefers-reduced-motion: reduce) {
  .login-intro-sub {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .login-scroll-cue::after {
    opacity: 0.5;
  }
}

.login-scroll-hint {
  position: relative;
  z-index: 1;
  text-align: center;
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.42);
  margin: 0 auto;
  padding: 8px 22px 28px;
  max-width: 1180px;
}

.login-scroll-hint--form {
  padding-top: 20px;
  padding-bottom: 12px;
}

.login-stats-section {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(48px, 12vh, 100px) 22px clamp(64px, 14vh, 120px);
  box-sizing: border-box;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.login-stats-inner {
  width: 100%;
  max-width: 520px;
  text-align: center;
}

.login-stats-heading {
  font-size: clamp(1.15rem, 2.4vw, 1.45rem);
  font-weight: 600;
  color: rgba(255, 255, 255, 0.94);
  margin: 0 0 12px;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.login-stats-sub {
  font-size: 0.91rem;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.58);
  margin: 0 0 16px;
  max-width: 42ch;
  margin-left: auto;
  margin-right: auto;
}

.login-stats-primary-label {
  font-size: 0.78rem;
  line-height: 1.45;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.48);
  margin: 0 0 10px;
  max-width: 40ch;
  margin-left: auto;
  margin-right: auto;
}

.login-stats-counter {
  margin-bottom: 28px;
}

.login-stats-value {
  display: block;
  font-size: clamp(2.75rem, 10vw, 4.25rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
  background: linear-gradient(115deg, var(--login-gold-bright), #fff 42%, var(--login-gold));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.login-stats-split {
  display: flex;
  flex-wrap: wrap;
  gap: 20px 32px;
  justify-content: center;
  align-items: flex-start;
}

.login-stats-split-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  min-width: 120px;
}

.login-stats-split-value {
  font-size: clamp(1.35rem, 4vw, 1.75rem);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: rgba(255, 255, 255, 0.92);
}

.login-stats-split-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.45);
}

.login-lang--corner {
  position: fixed;
  top: 14px;
  right: 14px;
  z-index: 20;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
  max-width: calc(100vw - 28px);
}

.login-lang--corner button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  font-size: 0.88rem;
  font-family: inherit;
  color: rgba(255, 255, 255, 0.88);
  background: rgba(21, 31, 49, 0.85);
  border: 1px solid var(--login-border);
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
}

.login-lang--corner button:hover {
  background: rgba(34, 45, 66, 0.95);
}

.login-lang--corner button.active {
  background: rgba(34, 45, 66, 0.98);
  border-color: rgba(0, 135, 113, 0.45);
}

.login-layout .login-main {
  position: relative;
  z-index: 1;
  max-width: 440px;
  width: 100%;
  margin: 0;
  justify-self: end;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
  padding: 0 0 28px;
  gap: 1.35rem;
}

.login-brand {
  margin: 0 0 0.25rem;
  text-align: center;
  line-height: 0;
}

.login-brand-logo {
  display: inline-block;
  height: clamp(52px, 9vw, 80px);
  width: auto;
  max-width: min(96vw, 420px);
  object-fit: contain;
  object-position: center;
  background: transparent;
}

.login-form-block {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
}

.login-form-block label.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.login-form-block input {
  width: 100%;
  padding: 14px 16px;
  font-size: 1rem;
  font-family: inherit;
  color: rgba(255, 255, 255, 0.95);
  background: var(--dark-color-surface-200, #222d42);
  border: 1px solid var(--login-border);
  border-radius: 10px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.login-form-block input::placeholder {
  color: rgba(255, 255, 255, 0.4);
}

.login-form-block input:focus {
  border-color: rgba(0, 135, 113, 0.55);
  box-shadow: 0 0 0 3px rgba(0, 135, 113, 0.15);
}

.login-form-block button[type="submit"],
.login-form-block button[type="button"].register-secondary {
  width: 100%;
  margin-top: 4px;
  padding: 14px 18px;
  font-size: 1rem;
  font-weight: 600;
  font-family: inherit;
  color: #fff;
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(34, 45, 66, 0.98) 0%, rgba(21, 31, 49, 0.99) 100%);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
  transition: background 0.2s, transform 0.15s;
}

.login-form-block button[type="submit"]:hover,
.login-form-block button[type="button"].register-secondary:hover {
  background: linear-gradient(180deg, rgba(44, 57, 80, 0.99) 0%, rgba(28, 38, 58, 1) 100%);
}

.login-form-block button[type="submit"]:active,
.login-form-block button[type="button"].register-secondary:active {
  transform: scale(0.99);
}

.login-form-block button.register-secondary {
  margin-top: 0;
  font-weight: 500;
  background: transparent;
  border-color: var(--login-border);
}

.login-forgot-wrap {
  margin: 10px 0 0;
  text-align: center;
}

.login-forgot-link {
  padding: 0;
  font-size: 0.88rem;
  font-family: inherit;
  font-weight: 500;
  color: var(--login-gold-bright);
  background: none;
  border: none;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.login-forgot-link:hover {
  color: var(--login-gold);
}

.register-step-hint {
  font-size: 0.92rem;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.78);
  margin: 0 0 8px;
  text-align: center;
}

.register-email-display {
  font-weight: 600;
  color: var(--login-gold-bright);
  word-break: break-all;
}

.login-error {
  color: #ff8a80;
  font-size: 0.88rem;
  text-align: center;
  min-height: 1.35em;
  margin: 0;
}

.login-expired-banner {
  margin: 0 0 12px;
  padding: 10px 12px;
  font-size: 0.88rem;
  line-height: 1.45;
  text-align: center;
  color: #ffccbc;
  background: rgba(255, 138, 128, 0.12);
  border: 1px solid rgba(255, 138, 128, 0.35);
  border-radius: 8px;
}

.login-tagline {
  text-align: center;
  margin: 0.35rem 0 0;
  line-height: 1.35;
}

.login-tagline .login-tagline-gold {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: baseline;
  gap: 0.35em;
  font-size: clamp(1.35rem, 4.5vw, 1.65rem);
  font-weight: 700;
  color: var(--login-gold-bright);
}

.login-tagline-count {
  font-family: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

.login-tagline .login-tagline-sub {
  display: block;
  margin-top: 6px;
  font-size: clamp(1.05rem, 3.5vw, 1.2rem);
  font-weight: 700;
  color: #fff;
}

.pricing-tiers {
  list-style: none;
  margin: 0.25rem 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
}

.pricing-tiers li {
  margin: 0;
  padding: 0;
}

.pricing-tier-btn {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 12px;
  width: 100%;
  padding: 12px 14px;
  text-align: left;
  font-size: 0.88rem;
  line-height: 1.45;
  font-family: inherit;
  color: rgba(255, 255, 255, 0.92);
  background: var(--login-surface);
  border: 1px solid var(--login-border);
  border-radius: 10px;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s, transform 0.15s;
}

.pricing-tier-btn:hover {
  border-color: rgba(212, 175, 55, 0.45);
  background: rgba(21, 31, 49, 0.98);
}

.pricing-tier-btn:active {
  transform: scale(0.99);
}

.pricing-tier-btn:focus-visible {
  outline: 2px solid var(--login-gold);
  outline-offset: 2px;
}

.pricing-tiers .p-price {
  margin-left: auto;
  white-space: nowrap;
  color: var(--login-gold-bright);
  font-weight: 700;
  font-size: 0.95rem;
}

.login-contact {
  text-align: center;
  margin-top: auto;
  padding-top: 8px;
  font-size: 0.95rem;
  color: rgba(255, 255, 255, 0.88);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.login-contact:hover {
  color: #fff;
}

body.login-pricing-modal-open {
  overflow: hidden;
}

.login-pricing-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.login-pricing-modal[hidden] {
  display: none !important;
}

.login-pricing-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 10, 20, 0.72);
  backdrop-filter: blur(4px);
}

.login-pricing-modal-panel {
  position: relative;
  width: min(100%, 400px);
  padding: 24px 22px 22px;
  background: var(--login-surface);
  border: 1px solid var(--login-border);
  border-radius: 14px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45);
}

.login-pricing-modal-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 36px;
  height: 36px;
  padding: 0;
  border: none;
  border-radius: 8px;
  font-size: 1.5rem;
  line-height: 1;
  color: rgba(255, 255, 255, 0.65);
  background: transparent;
  cursor: pointer;
}

.login-pricing-modal-close:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.06);
}

.login-pricing-modal-title {
  margin: 0 0 12px;
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
}

.login-pricing-modal-text {
  margin: 0 0 18px;
  font-size: 0.92rem;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.88);
}

.login-pricing-modal-wa {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 14px 16px;
  text-decoration: none;
  border-radius: 10px;
  background: rgba(37, 211, 102, 0.14);
  border: 1px solid rgba(37, 211, 102, 0.35);
  transition: background 0.2s, border-color 0.2s;
}

.login-pricing-modal-wa:hover {
  background: rgba(37, 211, 102, 0.22);
  border-color: rgba(37, 211, 102, 0.55);
}

.login-pricing-modal-wa-num {
  font-size: 1.05rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.02em;
}

.login-pricing-modal-wa-label {
  font-size: 0.88rem;
  font-weight: 600;
  color: #25d366;
}

.login-auth-card {
  width: 100%;
}

.login-tabs {
  display: flex;
  gap: 0;
  margin-bottom: 14px;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--login-border);
  background: rgba(15, 22, 36, 0.75);
}

.login-tab {
  flex: 1;
  padding: 12px 14px;
  font-size: 0.92rem;
  font-weight: 600;
  font-family: inherit;
  color: rgba(255, 255, 255, 0.5);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

.login-tab:hover {
  color: rgba(255, 255, 255, 0.85);
  background: rgba(255, 255, 255, 0.04);
}

.login-tab.active {
  color: #fff;
  background: rgba(34, 45, 66, 0.95);
  box-shadow: inset 0 0 0 1px rgba(0, 135, 113, 0.25);
}

.login-panel[hidden] {
  display: none !important;
}

.register-step[hidden] {
  display: none !important;
}

.login-success {
  color: #81c784;
  font-size: 0.88rem;
  text-align: center;
  margin: 0;
  line-height: 1.4;
}

@media (max-width: 900px) {
  .login-layout {
    grid-template-columns: 1fr;
    padding-top: 52px;
    align-items: start;
  }

  .login-hero {
    order: 1;
    max-width: none;
    padding-right: 0;
  }

  .login-layout .login-main {
    order: 2;
    justify-self: stretch;
    max-width: 440px;
    margin-left: auto;
    margin-right: auto;
    width: 100%;
  }
}

