:root {
  --auth-bg: #eef3f8;
  --auth-surface: #ffffff;
  --auth-ink: #102033;
  --auth-muted: #637083;
  --auth-line: #d8e1ec;
  --auth-primary: #184c9a;
  --auth-primary-strong: #0e2f68;
  --auth-accent: #c89f45;
  --auth-success: #0f8c56;
  --auth-danger: #b91c1c;
}

* {
  box-sizing: border-box;
}

body.auth-page {
  min-height: 100vh;
  margin: 0;
  color: var(--auth-ink);
  font-family: "Segoe UI", Arial, sans-serif;
  background:
    linear-gradient(90deg, rgba(14, 47, 104, 0.08) 0 1px, transparent 1px 100%),
    linear-gradient(180deg, #f7fafc 0%, #eef3f8 54%, #e8edf5 100%);
  background-size: 36px 36px, auto;
}

.auth-shell {
  min-height: 100vh;
  width: min(1180px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(360px, 0.82fr);
  gap: 18px;
  align-items: center;
  padding: 28px 18px;
}

.auth-panel,
.auth-card,
.auth-mini-card {
  border: 1px solid var(--auth-line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 20px 50px rgba(16, 32, 51, 0.10);
}

.auth-panel {
  min-height: 620px;
  display: grid;
  align-content: space-between;
  padding: 28px;
  overflow: hidden;
  background:
    linear-gradient(135deg, rgba(14, 47, 104, 0.98), rgba(24, 76, 154, 0.94)),
    #0e2f68;
  color: #ffffff;
}

.auth-brand-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.auth-logo {
  width: 54px;
  height: 54px;
  border-radius: 8px;
  object-fit: contain;
  background: #ffffff;
  padding: 6px;
}

.auth-brand-copy strong {
  display: block;
  font-size: 1.05rem;
  font-weight: 900;
}

.auth-brand-copy span {
  display: block;
  margin-top: 3px;
  color: rgba(255, 255, 255, 0.74);
  font-weight: 700;
  font-size: 0.86rem;
}

.auth-hero {
  max-width: 620px;
  padding: 42px 0 20px;
}

.auth-kicker {
  margin: 0 0 10px;
  color: #f4d27e;
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.auth-hero h1 {
  margin: 0;
  font-size: clamp(2.15rem, 5vw, 4.4rem);
  line-height: 1.02;
  font-weight: 900;
}

.auth-hero p {
  margin: 18px 0 0;
  max-width: 560px;
  color: rgba(255, 255, 255, 0.80);
  font-size: 1.02rem;
  line-height: 1.55;
  font-weight: 700;
}

.auth-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.auth-metric {
  min-height: 86px;
  padding: 13px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
}

.auth-metric strong {
  display: block;
  font-size: 1.1rem;
  font-weight: 900;
}

.auth-metric span {
  display: block;
  margin-top: 5px;
  color: rgba(255, 255, 255, 0.74);
  font-size: 0.8rem;
  font-weight: 800;
}

.auth-card {
  padding: 26px;
}

.auth-card-head {
  margin-bottom: 18px;
}

.auth-card-head h2,
.auth-card-head h1 {
  margin: 0;
  color: var(--auth-primary-strong);
  font-size: 1.6rem;
  line-height: 1.15;
}

.auth-card-head p {
  margin: 8px 0 0;
  color: var(--auth-muted);
  font-weight: 700;
  line-height: 1.45;
}

.auth-field {
  display: grid;
  gap: 7px;
  margin-bottom: 14px;
}

.auth-field label,
.auth-label {
  color: var(--auth-primary-strong);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.auth-input,
.auth-field input,
.auth-field textarea,
.auth-card input,
.auth-card textarea {
  width: 100%;
  min-height: 46px;
  border: 1px solid #bdcbea;
  border-radius: 8px;
  background: #f8fbff;
  padding: 11px 12px;
  color: var(--auth-ink);
  font: inherit;
}

.auth-input:focus,
.auth-field input:focus,
.auth-field textarea:focus,
.auth-card input:focus,
.auth-card textarea:focus {
  outline: none;
  border-color: var(--auth-primary);
  box-shadow: 0 0 0 4px rgba(24, 76, 154, 0.12);
  background: #ffffff;
}

.auth-button,
.auth-card button,
.auth-link-button,
.login-btn {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 8px;
  padding: 10px 14px;
  background: #184c9a;
  color: #ffffff;
  font-weight: 900;
  text-decoration: none;
  cursor: pointer;
}

.auth-button.primary,
.login-btn {
  width: 100%;
  background: linear-gradient(135deg, #0e2f68, #184c9a 72%, #c89f45 180%);
  box-shadow: 0 14px 26px rgba(24, 76, 154, 0.20);
}

.auth-button.secondary,
.auth-link-button,
.auth-links a,
.auth-card a.ghost,
.auth-card a.btn.ghost {
  background: #ffffff;
  color: var(--auth-primary);
  border: 1px solid var(--auth-line);
}

.auth-button.success {
  background: var(--auth-success);
}

.auth-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 16px;
}

.auth-actions > * {
  flex: 1 1 130px;
}

.auth-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
  margin-top: 16px;
}

.auth-links a {
  min-height: 42px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  padding: 9px 11px;
  text-align: center;
  font-size: 0.9rem;
  font-weight: 900;
  text-decoration: none;
}

.auth-alert,
.login-error,
.login-flash,
.flash {
  margin: 0 0 12px;
  padding: 11px 12px;
  border: 1px solid #f0c5c5;
  border-radius: 8px;
  background: #fff1f1;
  color: var(--auth-danger);
  font-weight: 800;
}

.auth-alert.success,
.login-flash.success,
.flash.success {
  border-color: #bfe8d1;
  background: #ecfff5;
  color: #0c6d43;
}

.auth-foot {
  padding: 18px;
  text-align: center;
  color: var(--auth-muted);
  font-size: 0.88rem;
  font-weight: 700;
}

.auth-foot a {
  color: inherit;
  text-decoration: none;
}

.auth-top-link {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 10;
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  border: 1px solid var(--auth-line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--auth-primary);
  text-decoration: none;
  font-weight: 900;
  box-shadow: 0 12px 28px rgba(16, 32, 51, 0.10);
}

.webinar-floating-cta {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 1200;
  min-width: 230px;
  min-height: 62px;
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 10px 15px 10px 10px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 8px;
  background: #0f8c56;
  color: #ffffff;
  text-decoration: none;
  box-shadow: 0 16px 38px rgba(15, 92, 61, 0.30);
  transition: transform 160ms ease, background 160ms ease, box-shadow 160ms ease;
}

.webinar-floating-cta:hover,
.webinar-floating-cta:focus-visible {
  transform: translateY(-3px);
  background: #0b7548;
  box-shadow: 0 20px 42px rgba(15, 92, 61, 0.36);
}

.webinar-floating-cta:focus-visible {
  outline: 3px solid rgba(200, 159, 69, 0.55);
  outline-offset: 3px;
}

.webinar-floating-cta__mark {
  flex: 0 0 auto;
  min-width: 48px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  background: #ffffff;
  color: #0b7548;
  font-size: 0.7rem;
  font-weight: 900;
}

.webinar-floating-cta__copy {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.webinar-floating-cta__copy strong,
.webinar-floating-cta__copy small {
  display: block;
  letter-spacing: 0;
}

.webinar-floating-cta__copy strong {
  font-size: 0.96rem;
  line-height: 1.15;
}

.webinar-floating-cta__copy small {
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.76rem;
  font-weight: 700;
}

.auth-simple-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 28px 14px;
}

.auth-simple-card {
  width: min(460px, 100%);
}

.auth-page .terms-open-btn,
.auth-page .terms-close-btn {
  border-radius: 8px;
}

body.auth-registration .register-shell,
body.auth-registration .shell {
  width: min(1180px, 100%);
}

body.auth-registration .register-top,
body.auth-registration .top {
  min-height: 140px;
  align-items: center;
  padding: 22px;
  border: 1px solid var(--auth-line);
  border-radius: 8px;
  background: linear-gradient(135deg, #0e2f68, #184c9a);
  color: #ffffff;
  box-shadow: 0 18px 40px rgba(16, 32, 51, 0.10);
}

body.auth-registration .auth-logo {
  flex: 0 0 auto;
}

body.auth-registration .register-title,
body.auth-registration .top > div {
  min-width: 0;
}

body.auth-registration .register-title h1,
body.auth-registration .top h1 {
  color: #ffffff;
}

body.auth-registration .register-title p,
body.auth-registration .top p {
  color: rgba(255, 255, 255, 0.78);
}

body.auth-registration .top-link,
body.auth-registration .login-link {
  border-radius: 8px;
  color: #0e2f68;
  border-color: rgba(255, 255, 255, 0.72);
}

body.auth-registration .section-card,
body.auth-registration .summary-card,
body.auth-registration .card,
body.auth-registration .gate {
  border-radius: 8px;
}

@media (max-width: 900px) {
  .auth-shell {
    min-height: auto;
    grid-template-columns: 1fr;
    padding: 16px;
  }

  .auth-panel {
    min-height: auto;
    gap: 32px;
  }

  .auth-metrics {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  body.auth-page {
    padding-bottom: 86px;
  }

  .auth-shell {
    padding: 10px;
  }

  .auth-panel,
  .auth-card {
    padding: 18px;
  }

  .auth-links {
    grid-template-columns: 1fr;
  }

  .auth-top-link {
    position: static;
    margin: 10px 10px 0 auto;
    width: max-content;
  }

  .webinar-floating-cta {
    right: 10px;
    bottom: 10px;
    left: 10px;
    min-width: 0;
    min-height: 58px;
    justify-content: center;
  }

  body.auth-registration .register-top,
  body.auth-registration .top {
    display: grid;
    padding: 18px;
  }
}

/* Login-only visual system aligned with the public landing page. */
body.auth-login-page {
  --auth-primary: #2367f2;
  --auth-primary-strong: #0b2554;
  --auth-accent: #e9bd63;
  background:
    radial-gradient(circle at 80% 15%, rgba(35, 103, 242, 0.13), transparent 26%),
    linear-gradient(90deg, rgba(12, 34, 72, 0.055) 1px, transparent 1px),
    linear-gradient(180deg, #f8fbff, #edf3fb);
  background-size: auto, 52px 52px, auto;
}

.auth-login-page .auth-shell {
  width: min(1120px, calc(100% - 32px));
  grid-template-columns: minmax(0, 1.08fr) minmax(370px, 0.82fr);
  gap: 0;
  padding: 74px 0 48px;
}

.auth-login-page .auth-panel,
.auth-login-page .auth-card {
  border-radius: 22px;
}

.auth-login-page .auth-panel {
  position: relative;
  min-height: 620px;
  padding: 34px;
  border-color: rgba(133, 173, 239, 0.22);
  background:
    radial-gradient(circle at 82% 15%, rgba(87, 215, 255, 0.15), transparent 26%),
    linear-gradient(145deg, #071a3b, #123f83);
  box-shadow: 0 28px 72px rgba(7, 27, 62, 0.25);
}

.auth-login-page .auth-panel::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(87, 215, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(87, 215, 255, 0.045) 1px, transparent 1px);
  background-size: 46px 46px;
}

.auth-login-page .auth-panel > * {
  position: relative;
  z-index: 1;
}

.auth-login-page .auth-card {
  position: relative;
  z-index: 2;
  width: calc(100% + 14px);
  margin-left: -14px;
  padding: 36px;
  border-color: rgba(194, 209, 232, 0.92);
  box-shadow: 0 28px 70px rgba(18, 48, 94, 0.17);
}

.auth-login-page .auth-logo {
  border-radius: 13px;
}

.auth-login-page .auth-role-icon {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  margin-bottom: 22px;
  border-radius: 15px;
  background: #2367f2;
  color: #fff;
  box-shadow: 0 14px 30px rgba(35, 103, 242, 0.28);
}

.partner-login-page .auth-role-icon {
  background: #e9bd63;
  color: #10203f;
  box-shadow: 0 14px 30px rgba(233, 189, 99, 0.24);
}

.auth-login-page .auth-role-icon svg,
.auth-login-page .auth-top-link svg,
.auth-login-page .auth-links svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.auth-login-page .auth-role-icon svg {
  width: 29px;
  height: 29px;
}

.auth-login-page .auth-hero {
  padding: 28px 0 16px;
}

.auth-login-page .auth-hero h1 {
  max-width: 560px;
  font-size: clamp(2.7rem, 5vw, 4.7rem);
  letter-spacing: -0.045em;
}

.auth-login-page .auth-metric {
  min-height: 94px;
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.065);
}

.auth-login-page .auth-portal-label {
  display: inline-flex;
  margin-bottom: 12px;
  padding: 6px 9px;
  border-radius: 999px;
  background: #eaf1ff;
  color: #1557cb;
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.partner-login-page .auth-portal-label {
  background: #fff5dd;
  color: #8b5c00;
}

.auth-login-page .auth-card-head h1 {
  font-size: 2rem;
  letter-spacing: -0.035em;
}

.auth-login-page .auth-field {
  margin-bottom: 16px;
}

.auth-login-page .auth-card input {
  min-height: 52px;
  border-radius: 12px;
  background: #f7faff;
}

.auth-login-page .auth-button.primary {
  min-height: 52px;
  border-radius: 12px;
  background: linear-gradient(135deg, #1559d6, #2367f2);
  box-shadow: 0 14px 28px rgba(35, 103, 242, 0.22);
}

.auth-login-page .auth-links {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 12px;
}

.auth-login-page .auth-links a {
  min-height: 48px;
  gap: 8px;
  border-radius: 11px;
  background: #fff;
  transition: border-color 0.16s ease, transform 0.16s ease, background 0.16s ease;
}

.auth-login-page .auth-links a:hover {
  transform: translateY(-2px);
  border-color: #91b4ed;
  background: #f5f9ff;
}

.auth-login-page .auth-links svg {
  width: 19px;
  height: 19px;
}

.auth-login-page .auth-top-link {
  top: 20px;
  right: 24px;
  min-height: 44px;
  gap: 8px;
  padding: 9px 14px;
  border-radius: 999px;
  border-color: #bcd0ee;
  background: rgba(255, 255, 255, 0.96);
}

.auth-login-page .auth-top-link svg {
  width: 20px;
  height: 20px;
}

.auth-login-page .auth-foot {
  padding-top: 0;
}

@media (max-width: 900px) {
  .auth-login-page .auth-shell {
    width: min(720px, calc(100% - 24px));
    grid-template-columns: 1fr;
    padding-top: 72px;
  }

  .auth-login-page .auth-panel {
    min-height: auto;
    border-radius: 22px 22px 0 0;
  }

  .auth-login-page .auth-card {
    width: 100%;
    margin: -1px 0 0;
    border-radius: 0 0 22px 22px;
  }

  .auth-login-page .auth-metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .auth-login-page .auth-shell {
    width: calc(100% - 16px);
    padding: 64px 0 16px;
  }

  .auth-login-page .auth-top-link {
    position: absolute;
    top: 10px;
    right: 10px;
    margin: 0;
  }

  .auth-login-page .auth-panel,
  .auth-login-page .auth-card {
    padding: 22px;
  }

  .auth-login-page .auth-hero h1 {
    font-size: 2.45rem;
  }

  .auth-login-page .auth-metrics {
    grid-template-columns: 1fr;
  }

  .auth-login-page .auth-links {
    grid-template-columns: 1fr;
  }
}
