/* Landing-aligned authentication pages. Loaded after legacy auth styles. */
html.light-mode body.auth-page,
body.auth-page {
  --auth-ink: #081226;
  --auth-muted: #68758e;
  --auth-line: #e5e7ee;
  --auth-violet: #6337f2;
  --auth-soft: #f4f0ff;
  margin: 0 !important;
  min-height: 100svh !important;
  padding: 92px 24px 68px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  background:
    radial-gradient(circle at 50% 2%, rgba(99,55,242,.10), transparent 34rem),
    #fff !important;
  color: var(--auth-ink) !important;
  font-family: 'Syne', system-ui, sans-serif !important;
  overflow: hidden !important;
  box-sizing: border-box !important;
}

.auth-page *,
.auth-page input,
.auth-page button,
.auth-page select { font-family: 'Syne', system-ui, sans-serif !important; }

/* Preserve the icon font after the broad landing-page typography override. */
.auth-page i.fa-solid,
.auth-page i.fas { font-family: "Font Awesome 6 Free" !important; font-weight: 900 !important; }
.auth-page i.fa-regular,
.auth-page i.far { font-family: "Font Awesome 6 Free" !important; font-weight: 400 !important; }
.auth-page i.fa-brands,
.auth-page i.fab { font-family: "Font Awesome 6 Brands" !important; font-weight: 400 !important; }

.auth-page-header {
  position: fixed;
  z-index: 100;
  inset: 0 0 auto;
  height: 78px;
  padding: 0 clamp(24px, 5.2vw, 82px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255,255,255,.90);
  border-bottom: 1px solid #eceef3;
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}
.auth-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--auth-ink) !important;
  text-decoration: none !important;
  font-weight: 700;
  font-size: 19px;
  letter-spacing: -.045em;
}
.auth-brand img { width: 29px; height: 29px; border-radius: 8px; }
.auth-page-switch {
  min-height: 40px;
  padding: 0 18px;
  border: 1px solid #d8ccff;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  color: var(--auth-violet) !important;
  background: #fff;
  text-decoration: none !important;
  font-size: 12px;
  font-weight: 700;
  box-shadow: 0 8px 22px rgba(99,55,242,.08);
}
.auth-page-switch:hover { border-color: var(--auth-violet); transform: translateY(-1px); }
.auth-page .login-hero-container { display: none !important; }

html.light-mode .auth-page .auth-container,
.auth-page .auth-container {
  width: 100% !important;
  position: relative !important;
  margin: 0 !important;
  padding: 42px !important;
  border: 1px solid var(--auth-line) !important;
  border-radius: 26px !important;
  background: rgba(255,255,255,.97) !important;
  color: var(--auth-ink) !important;
  box-shadow: 0 24px 70px rgba(35,24,92,.11) !important;
  overflow: hidden !important;
}
.auth-page .auth-container::before {
  display: block !important;
  content: '' !important;
  position: absolute !important;
  inset: 0 0 auto !important;
  height: 3px !important;
  background: linear-gradient(90deg, transparent, #7c4dff, transparent) !important;
}
.auth-page .logo-container { display: none !important; }
.auth-page .auth-container h1 {
  color: var(--auth-ink) !important;
  font-size: clamp(2rem, 4vw, 3.15rem) !important;
  line-height: 1 !important;
  letter-spacing: -.055em !important;
}
.auth-page .intro-text,
.auth-page .auth-link-group { color: var(--auth-muted) !important; }

html.light-mode .auth-page .back-button,
html.light-mode .auth-page .lang-top-btn,
.auth-page .back-button,
.auth-page .lang-top-btn {
  top: 20px !important;
  height: 38px !important;
  background: #fff !important;
  color: #536078 !important;
  border: 1px solid #dde1e9 !important;
  box-shadow: none !important;
}
.auth-page .back-button { left: 20px !important; width: 38px !important; }
.auth-page .lang-top-btn { right: 20px !important; padding: 0 13px !important; border-radius: 999px !important; }
.auth-page .back-button:hover,
.auth-page .lang-top-btn:hover { color: var(--auth-violet) !important; border-color: #c9b9ff !important; background: var(--auth-soft) !important; }

html.light-mode .auth-page input[type="password"],
html.light-mode .auth-page input[type="text"],
html.light-mode .auth-page input[type="email"],
.auth-page input[type="password"],
.auth-page input[type="text"],
.auth-page input[type="email"] {
  min-height: 46px !important;
  padding: 0 14px !important;
  background: #fafafe !important;
  color: var(--auth-ink) !important;
  border: 1px solid #dfe2ea !important;
  border-radius: 12px !important;
  font-size: 13px !important;
  box-shadow: none !important;
}
.auth-page input:focus {
  background: #fff !important;
  border-color: #9c82f8 !important;
  box-shadow: 0 0 0 4px rgba(99,55,242,.10) !important;
}
.auth-page input::placeholder { color: #a0a8b7 !important; }
.auth-page label { color: #59657b !important; font-size: 11px !important; font-weight: 700 !important; }

html.light-mode .auth-page .auth-container button[type="submit"],
.auth-page .auth-container button[type="submit"] {
  min-height: 46px !important;
  margin: 0 !important;
  border-radius: 999px !important;
  background: linear-gradient(135deg,#5524ef,#7c4dff) !important;
  color: #fff !important;
  box-shadow: 0 10px 26px rgba(99,55,242,.22) !important;
  text-transform: none !important;
}
html.light-mode .auth-page .auth-container button.social-btn,
.auth-page .auth-container button.social-btn {
  min-height: 44px !important;
  margin-top: 0 !important;
  padding: 0 15px !important;
  border: 1px solid #dfe2ea !important;
  border-radius: 999px !important;
  background: #fff !important;
  color: #20283a !important;
  box-shadow: none !important;
  font-size: 12px !important;
}
html.light-mode .auth-page .auth-container button.social-btn:hover:not(:disabled),
.auth-page .auth-container button.social-btn:hover:not(:disabled) {
  border-color: #c9b9ff !important;
  background: #f8f6ff !important;
  color: var(--auth-violet) !important;
  box-shadow: none !important;
}
.auth-page .divider { margin: 10px 0 !important; color: #9ca4b3 !important; }
.auth-page .divider::before,
.auth-page .divider::after { border-color: #dfe2ea !important; }
.auth-page a { color: var(--auth-violet) !important; }

.auth-page #lang-overlay { background: rgba(8,12,26,.50) !important; }
html.light-mode .auth-page .lang-modal,
.auth-page .lang-modal { background: #fff !important; border: 1px solid #ddd5ff !important; box-shadow: 0 28px 80px rgba(8,12,26,.22) !important; }
html.light-mode .auth-page .lang-option,
.auth-page .lang-option { background: #fafafe !important; border-color: #e5e7ee !important; color: #4f5c73 !important; }

.auth-page .auth-footer {
  position: fixed !important;
  z-index: 20;
  bottom: 0;
  left: 0;
  padding: 13px 20px 15px !important;
  margin: 0 !important;
  color: #8791a2 !important;
  background: linear-gradient(transparent,rgba(255,255,255,.94) 35%);
  box-sizing: border-box !important;
}
.auth-page .footer-links { margin-bottom: 3px !important; }

/* Login: two columns, same shape as signup — showcase left, form right. */
html.light-mode body.auth-login .auth-container,
body.auth-login .auth-container {
  max-width: 1040px !important;
  min-height: 570px;
  /* Top padding clears the absolutely-positioned back / language buttons so the
     left column's heading never runs under them. */
  padding: 104px 52px 34px !important;
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) minmax(0, .92fr);
  grid-template-rows: auto auto 1fr auto auto;
  column-gap: 60px;
  /* start, not center: rows begin below the padding so the heading always
     clears the back / language buttons pinned to the card's top corners. */
  align-content: start;
  text-align: left !important;
}
.auth-login .auth-container h1 { grid-column: 1; grid-row: 1; font-size: 2.5rem !important; margin: 0 0 8px !important; }
.auth-login .intro-text { grid-column: 1; grid-row: 2; max-width: 400px; margin: 0 0 20px !important; line-height: 1.55; }
.auth-login .login-showcase {
  grid-column: 1;
  grid-row: 3 / 6;
  align-self: stretch;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid #d8ccff;
  border-radius: 20px;
  background: linear-gradient(145deg, #f2edff, #faf8ff);
  box-shadow: 0 18px 44px rgba(99, 55, 242, .10);
}
.auth-login .login-showcase img {
  display: block;
  width: 100%;
  flex: 1;
  min-height: 0;
  object-fit: cover;
  object-position: top center;
  border-bottom: 1px solid #e2d9ff;
}
.auth-login .login-showcase-copy { padding: 16px 20px 18px; }
.auth-login .login-showcase-tag {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 11px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid #ded3ff;
  color: var(--auth-violet);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.auth-login .login-showcase-copy p {
  margin: 11px 0 0 !important;
  color: #5f6b80 !important;
  font-size: 14px !important;
  line-height: 1.6;
}
.auth-login #login-error-message,
.auth-login #social-login-container,
.auth-login .divider,
.auth-login #login-form,
.auth-login .auth-link-group { grid-column: 2; }
.auth-login #login-error-message { grid-row: 1; margin: 0 0 8px !important; }
.auth-login #social-login-container { grid-row: 2; gap: 10px; margin: 0 !important; }
.auth-login #social-login-container button { margin-top: 0 !important; }
.auth-login .divider { grid-row: 3; align-self: start; margin: 12px 0 !important; }
.auth-login .auth-container form { grid-row: 4; align-self: start; gap: 12px !important; margin: 0 !important; }
.auth-login .auth-link-group { grid-row: 5; align-self: start; margin: 16px 0 0 !important; text-align: center; }

/* Signup: two columns keep the complete form in one desktop viewport. */
html.light-mode body.auth-signup .auth-container,
body.auth-signup .auth-container {
  max-width: 1040px !important;
  min-height: 570px;
  /* Top padding clears the back / language buttons pinned to the card corners. */
  padding: 104px 52px 34px !important;
  display: grid !important;
  grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr);
  grid-template-rows: auto auto 44px auto auto auto;
  column-gap: 68px;
  align-content: start;
  text-align: left !important;
}
.auth-signup .auth-container h1,
.auth-signup .marketing-pills,
.auth-signup .video-spotlight { grid-column: 1; }
html.light-mode body.auth-signup .auth-container h1,
.auth-signup .auth-container h1 { grid-row: 1; margin: 0 0 16px !important; font-size: 2.25rem !important; }
.auth-signup .marketing-pills { grid-row: 2; justify-content: flex-start !important; gap: 7px !important; margin-bottom: 18px; }
.auth-signup .model-pill { border-color: #ded8ef !important; background: #faf8ff !important; }
.auth-signup .video-spotlight {
  grid-row: 3 / 7;
  align-self: stretch;
  margin: 0 !important;
  padding: 0 !important;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: linear-gradient(145deg,#f2edff,#faf8ff) !important;
  border: 1px solid #d8ccff !important;
  border-radius: 20px !important;
  box-shadow: 0 18px 44px rgba(99,55,242,.10);
}
.auth-signup .video-spotlight::after { display: none; }
.auth-signup .spotlight-shot {
  display: block;
  width: 100%;
  flex: 1;
  min-height: 0;
  object-fit: cover;
  object-position: top center;
  border-bottom: 1px solid #e2d9ff;
}
.auth-signup .spotlight-badge { margin: 16px 20px 0 !important; }
.auth-signup .spotlight-desc { padding: 0 20px 18px; }
.auth-signup .feature-mini-grid { display: none !important; }
.auth-signup .spotlight-badge {
  position: static !important;
  transform: none !important;
  width: fit-content;
  padding: 5px 11px !important;
  border-radius: 999px !important;
  background: #fff !important;
  border: 1px solid #ded3ff !important;
  color: var(--auth-violet) !important;
  font-size: 11px !important;
}
.auth-signup .spotlight-desc { margin: 11px 0 0 !important; color: #5f6b80 !important; font-size: 14px !important; line-height: 1.6; }
.auth-signup #signup-error-message,
.auth-signup .form-group-checkbox,
.auth-signup > .auth-container .social-btn,
.auth-signup .divider,
.auth-signup #signup-form,
.auth-signup .auth-link-group { grid-column: 2; }
.auth-signup #signup-error-message { grid-row: 1; margin: 0 0 8px !important; }
.auth-signup .form-group-checkbox { grid-row: 2; margin: 0 0 12px !important; }
.auth-signup #google-signin-btn { grid-row: 3; align-self: start; width: calc(50% - 5px) !important; }
.auth-signup #apple-signin-btn { grid-row: 3; align-self: start; justify-self: end; width: calc(50% - 5px) !important; }
.auth-signup .divider { grid-row: 4; margin: 9px 0 !important; }
.auth-signup #signup-form {
  grid-row: 5;
  margin: 0;
  display: grid !important;
  grid-template-columns: 1fr 1fr;
  gap: 12px !important;
}
.auth-signup #signup-form button[type="submit"] { grid-column: 1 / -1; }
.auth-signup .auth-link-group { grid-row: 6; margin: 12px 0 0 !important; text-align: center; }

html.light-mode body.auth-page .auth-container #google-signin-btn.social-btn,
html.light-mode body.auth-page .auth-container #apple-signin-btn.social-btn {
  background: #fff !important;
  color: #20283a !important;
  border: 1px solid #dfe2ea !important;
  box-shadow: none !important;
}

@media (min-width: 801px) and (max-height: 760px) {
  html.light-mode body.auth-page,
  body.auth-page { padding-top: 78px !important; padding-bottom: 44px !important; }
  .auth-page-header { height: 68px; }
  .auth-page .auth-footer { padding-top: 7px !important; padding-bottom: 7px !important; }
  html.light-mode body.auth-signup .auth-container,
  body.auth-signup .auth-container { min-height: 476px; padding: 66px 42px 24px !important; }
  html.light-mode body.auth-login .auth-container,
  body.auth-login .auth-container { min-height: 476px; padding: 88px 42px 24px !important; }
  .auth-login .auth-container h1 { font-size: 2.05rem !important; }
  .auth-login .intro-text { margin-bottom: 14px !important; }
  .auth-login .divider { margin: 8px 0 !important; }
  .auth-login .auth-container form { gap: 10px !important; }
  .auth-login .auth-link-group { margin-top: 10px !important; }
  .auth-login .login-showcase-copy { padding: 13px 18px 15px; }
  .auth-signup .auth-container h1 { font-size: 2.05rem !important; margin-bottom: 12px !important; }
  .auth-signup .spotlight-desc { font-size: 13px !important; }
}

@media (max-width: 800px) {
  html.light-mode body.auth-login .auth-container,
  body.auth-login .auth-container { display: block !important; min-height: 0; max-width: 540px !important; text-align: center !important; padding: 78px 22px 30px !important; }
  .auth-login .login-showcase { display: none !important; }
  .auth-login .intro-text { max-width: 340px; margin: 0 auto 20px !important; }
  .auth-login #social-login-container button { margin-top: 10px !important; }
  html.light-mode body.auth-page,
  body.auth-page { padding: 84px 14px 28px !important; min-height: 100vh !important; overflow-y: auto !important; align-items: flex-start !important; }
  .auth-page-header { height: 68px; padding: 0 18px; }
  .auth-page .auth-container { margin: 0 auto !important; padding: 76px 22px 30px !important; }
  .auth-page .auth-footer { position: static !important; background: transparent; }
  /* Clear the absolutely-positioned back / language buttons at the card's top. */
  html.light-mode body.auth-signup .auth-container,
  body.auth-signup .auth-container { display: block !important; min-height: 0; max-width: 540px !important; text-align: center !important; padding-top: 78px !important; }
  .auth-signup .marketing-pills { justify-content: center !important; }
  .auth-signup .video-spotlight { margin-bottom: 20px !important; text-align: left; }
  .auth-signup .spotlight-shot { flex: none; height: 170px; }
  .auth-signup #google-signin-btn,
  .auth-signup #apple-signin-btn { width: 100% !important; margin-bottom: 10px !important; }
  .auth-signup .divider { margin: 10px 0 !important; }
  .auth-signup #signup-form { margin: 0; display: flex !important; }
  .auth-signup .auth-link-group { margin-top: 18px !important; }
}

@media (max-width: 520px) {
  .auth-page-switch { padding: 0 13px; font-size: 11px; }
  .auth-page .auth-container { border-radius: 21px !important; }
  .auth-login .auth-container h1 { font-size: 2.15rem !important; }
}
