:root {
  --rgs-navy: #061b63;
  --rgs-blue: #073bb5;
  --rgs-purple: #51107c;
  --rgs-gold: #f4b400;
  --rgs-text: #334155;
  --rgs-surface: #ffffff;
  --rgs-border: #dbe4f3;
}

body.rgs-auth-enhanced {
  padding-top: 76px !important;
  background: #f7f9fc !important;
}

body.rgs-auth-modal-open {
  overflow: hidden !important;
}

body.rgs-auth-enhanced #root {
  min-height: calc(100vh - 76px) !important;
}

.rgs-auth-header,
.rgs-auth-header *,
.rgs-auth-hero,
.rgs-auth-hero *,
.rgs-auth-modal,
.rgs-auth-modal *,
.rgs-auth-mobile-notice,
.rgs-auth-mobile-notice * {
  box-sizing: border-box;
  font-family: Arial, Helvetica, sans-serif;
}

.rgs-auth-header {
  align-items: center;
  background: #ffffff;
  border-bottom: 1px solid #dbe4f3;
  box-shadow: 0 5px 20px rgba(6, 27, 99, 0.10);
  display: flex;
  height: 76px;
  justify-content: space-between;
  left: 0;
  padding: 7px clamp(18px, 4vw, 64px);
  position: fixed;
  right: 0;
  top: 0;
  z-index: 10020;
}

.rgs-auth-brand {
  align-items: center;
  color: var(--rgs-navy) !important;
  display: inline-flex;
  gap: 11px;
  min-width: 250px;
  text-decoration: none !important;
}

.rgs-auth-brand img {
  height: 58px;
  object-fit: contain;
  width: 58px;
}

.rgs-auth-brand span {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.rgs-auth-brand b {
  color: var(--rgs-navy);
  font-size: 15px;
  font-weight: 800;
}

.rgs-auth-brand small {
  color: #64748b;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .08em;
  margin-top: 4px;
  text-transform: uppercase;
}

.rgs-auth-nav {
  align-items: center;
  display: flex;
  gap: 4px;
}

.rgs-auth-nav-link,
.rgs-auth-policy-link {
  background: transparent;
  border: 0;
  border-radius: 8px;
  color: #334155 !important;
  cursor: pointer;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
  padding: 12px 13px;
  text-decoration: none !important;
  white-space: nowrap;
}

.rgs-auth-nav-link:hover,
.rgs-auth-nav-link:focus,
.rgs-auth-policy-link:hover,
.rgs-auth-policy-link:focus {
  background: #eef4ff;
  color: var(--rgs-blue) !important;
  outline: 2px solid transparent;
}

.rgs-auth-policy-link {
  background: var(--rgs-navy);
  color: #ffffff !important;
  margin-left: 5px;
}

.rgs-auth-policy-link:hover,
.rgs-auth-policy-link:focus {
  background: var(--rgs-purple);
  color: #ffffff !important;
}

.rgs-auth-menu-button {
  background: var(--rgs-navy);
  border: 0;
  border-radius: 7px;
  color: #fff;
  display: none;
  font-size: 14px;
  font-weight: 800;
  padding: 10px 14px;
}

.rgs-auth-hero {
  background-image:
    linear-gradient(145deg, rgba(6, 27, 99, .96) 0%, rgba(7, 59, 181, .85) 48%, rgba(81, 16, 124, .88) 100%),
    url("./rgs-login-learning.png");
  background-position: center;
  background-size: cover;
  bottom: 0;
  color: #ffffff;
  left: 0;
  overflow: auto;
  padding: clamp(30px, 5vh, 70px) clamp(30px, 4.2vw, 72px);
  position: fixed;
  top: 76px;
  width: 48%;
  z-index: 100;
}

.rgs-auth-hero::after {
  background: radial-gradient(circle at 20% 10%, rgba(244, 180, 0, .30), transparent 32%);
  content: "";
  inset: 0;
  pointer-events: none;
  position: absolute;
}

.rgs-auth-hero-content {
  margin: 0 auto;
  max-width: 590px;
  position: relative;
  z-index: 2;
}

.rgs-auth-eyebrow {
  background: var(--rgs-gold);
  border-radius: 999px;
  color: var(--rgs-navy) !important;
  display: inline-block;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .13em;
  padding: 8px 13px;
}

.rgs-auth-hero h1 {
  color: #ffffff !important;
  font-size: clamp(34px, 3.8vw, 58px);
  font-weight: 900;
  letter-spacing: -.035em;
  line-height: 1.03;
  margin: 20px 0 16px;
  max-width: 560px;
}

.rgs-auth-intro {
  color: #edf4ff !important;
  font-size: clamp(15px, 1.3vw, 18px);
  line-height: 1.65;
  margin: 0 0 24px;
  max-width: 560px;
}

.rgs-auth-integrity-card {
  align-items: flex-start;
  backdrop-filter: blur(12px);
  background: rgba(255, 255, 255, .94);
  border: 1px solid rgba(255, 255, 255, .7);
  border-left: 7px solid var(--rgs-gold);
  border-radius: 16px;
  box-shadow: 0 18px 48px rgba(0, 0, 0, .22);
  color: var(--rgs-text);
  display: flex;
  gap: 16px;
  padding: 20px;
}

.rgs-auth-integrity-icon {
  align-items: center;
  background: var(--rgs-navy);
  border-radius: 50%;
  color: #fff;
  display: flex;
  flex: 0 0 42px;
  font-size: 21px;
  font-weight: 900;
  height: 42px;
  justify-content: center;
}

.rgs-auth-card-label {
  color: var(--rgs-purple);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .12em;
}

.rgs-auth-integrity-card h2 {
  color: var(--rgs-navy) !important;
  font-size: 20px;
  font-weight: 900;
  line-height: 1.2;
  margin: 4px 0 8px;
}

.rgs-auth-integrity-card p {
  color: #475569 !important;
  font-size: 13px;
  line-height: 1.55;
  margin: 0 0 12px;
}

.rgs-auth-read-policy {
  background: transparent;
  border: 0;
  border-bottom: 2px solid var(--rgs-gold);
  color: var(--rgs-blue);
  cursor: pointer;
  font-size: 13px;
  font-weight: 900;
  padding: 2px 0 4px;
}

.rgs-auth-support-row {
  align-items: center;
  color: #ffffff;
  display: flex;
  flex-wrap: wrap;
  font-size: 12px;
  gap: 7px 14px;
  margin-top: 18px;
}

.rgs-auth-support-row span {
  flex-basis: 100%;
}

.rgs-auth-support-row a {
  color: #ffffff !important;
  font-weight: 800;
  text-decoration-color: var(--rgs-gold) !important;
  text-underline-offset: 4px;
}

.rgs-auth-mobile-notice {
  display: none;
}

.rgs-auth-terms-notice {
  background: #fff8da;
  border: 1px solid #efd15b;
  border-left: 6px solid var(--rgs-gold);
  border-radius: 10px;
  bottom: 20px;
  box-shadow: 0 10px 28px rgba(6,27,99,.10);
  color: #475569;
  font-size: 11px;
  line-height: 1.5;
  padding: 12px 14px;
  position: fixed;
  right: 3.5%;
  width: 43%;
  z-index: 120;
}
.rgs-auth-terms-notice b { color: var(--rgs-navy); }
.rgs-auth-terms-notice a { color: var(--rgs-blue)!important; font-weight: 900; }

.rgs-auth-modal[hidden] {
  display: none !important;
}

.rgs-auth-modal {
  align-items: center;
  display: flex;
  inset: 0;
  justify-content: center;
  padding: 24px;
  position: fixed;
  z-index: 20000;
}

.rgs-auth-modal-backdrop {
  background: rgba(6, 20, 61, .82);
  inset: 0;
  position: absolute;
}

.rgs-auth-modal-panel {
  background: #ffffff;
  border-radius: 20px;
  box-shadow: 0 28px 80px rgba(0, 0, 0, .36);
  max-height: calc(100vh - 48px);
  max-width: 900px;
  overflow: hidden;
  position: relative;
  width: 100%;
}

.rgs-auth-modal-head {
  align-items: flex-start;
  background: linear-gradient(135deg, var(--rgs-navy), var(--rgs-purple));
  border-bottom: 6px solid var(--rgs-gold);
  display: flex;
  justify-content: space-between;
  padding: 24px 26px 20px;
}

.rgs-auth-modal-head h2 {
  color: #ffffff !important;
  font-size: clamp(22px, 3vw, 32px);
  font-weight: 900;
  line-height: 1.15;
  margin: 12px 0 0;
}

.rgs-auth-modal-close {
  background: rgba(255, 255, 255, .14);
  border: 1px solid rgba(255, 255, 255, .35);
  border-radius: 50%;
  color: #ffffff;
  cursor: pointer;
  flex: 0 0 40px;
  font-size: 28px;
  height: 40px;
  line-height: 34px;
}

.rgs-auth-modal-body {
  max-height: calc(100vh - 250px);
  overflow-y: auto;
  padding: 22px 28px;
}

.rgs-auth-modal-body section {
  border-bottom: 1px solid var(--rgs-border);
  padding: 0 0 15px;
  margin: 0 0 15px;
}

.rgs-auth-modal-body h3 {
  color: var(--rgs-navy) !important;
  font-size: 17px;
  font-weight: 900;
  margin: 0 0 6px;
}

.rgs-auth-modal-body p {
  color: #475569 !important;
  font-size: 14px;
  line-height: 1.65;
  margin: 0;
}

.rgs-auth-modal-body .rgs-auth-consequence {
  background: #fff8dc;
  border: 1px solid #f4d35e;
  border-left: 6px solid var(--rgs-gold);
  border-radius: 10px;
  padding: 15px 16px;
}

.rgs-auth-policy-support {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.rgs-auth-policy-support a {
  background: #eef4ff;
  border-radius: 8px;
  color: var(--rgs-blue) !important;
  font-size: 13px;
  font-weight: 800;
  padding: 10px 12px;
  text-decoration: none !important;
}

.rgs-auth-full-policy {
  background: linear-gradient(135deg, var(--rgs-navy), var(--rgs-purple));
  border-radius: 10px;
  color: #ffffff !important;
  display: block;
  font-size: 14px;
  font-weight: 900;
  margin: 18px 0;
  padding: 14px 18px;
  text-align: center;
  text-decoration: none !important;
}

.rgs-auth-full-policy:hover,
.rgs-auth-full-policy:focus {
  box-shadow: 0 8px 24px rgba(6, 27, 99, .22);
  color: #ffffff !important;
  transform: translateY(-1px);
}

.rgs-auth-modal-foot {
  background: #f8fafc;
  border-top: 1px solid var(--rgs-border);
  padding: 14px 26px;
  text-align: right;
}

.rgs-auth-modal-foot button {
  background: var(--rgs-navy);
  border: 0;
  border-radius: 8px;
  color: #ffffff;
  cursor: pointer;
  font-size: 14px;
  font-weight: 900;
  padding: 11px 18px;
}

@media (max-width: 1100px) {
  .rgs-auth-nav-link,
  .rgs-auth-policy-link {
    padding-left: 9px;
    padding-right: 9px;
  }

  .rgs-auth-brand span {
    display: none;
  }

  .rgs-auth-brand {
    min-width: 60px;
  }
}

@media (max-width: 900px) {
  body.rgs-auth-enhanced {
    padding-top: 112px !important;
  }

  body.rgs-auth-enhanced #root {
    min-height: calc(100vh - 112px) !important;
  }

  .rgs-auth-header {
    height: 68px;
    padding: 5px 16px;
  }

  .rgs-auth-brand img {
    height: 52px;
    width: 52px;
  }

  .rgs-auth-menu-button {
    display: block;
  }

  .rgs-auth-nav {
    align-items: stretch;
    background: #ffffff;
    border: 1px solid var(--rgs-border);
    border-radius: 12px;
    box-shadow: 0 18px 45px rgba(6, 27, 99, .18);
    display: none;
    flex-direction: column;
    padding: 10px;
    position: absolute;
    right: 16px;
    top: 61px;
    width: 210px;
  }

  .rgs-auth-nav.is-open {
    display: flex;
  }

  .rgs-auth-nav-link,
  .rgs-auth-policy-link {
    margin: 0;
    text-align: left;
  }

  .rgs-auth-hero {
    display: none;
  }

  .rgs-auth-mobile-notice {
    align-items: center;
    background: linear-gradient(90deg, var(--rgs-navy), var(--rgs-purple));
    color: #ffffff;
    display: flex;
    font-size: 12px;
    gap: 7px;
    height: 44px;
    justify-content: center;
    left: 0;
    padding: 5px 12px;
    position: fixed;
    right: 0;
    top: 68px;
    z-index: 10010;
  }

  .rgs-auth-mobile-notice button,
  .rgs-auth-mobile-notice a {
    background: transparent;
    border: 0;
    border-bottom: 1px solid var(--rgs-gold);
    color: #ffffff;
    cursor: pointer;
    font-size: 12px;
    font-weight: 900;
    padding: 2px;
    text-decoration: none;
  }

  .rgs-auth-terms-notice {
    border-radius: 0;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
  }
}

@media (max-width: 540px) {
  .rgs-auth-modal {
    padding: 8px;
  }

  .rgs-auth-modal-panel {
    border-radius: 13px;
    max-height: calc(100vh - 16px);
  }

  .rgs-auth-modal-head {
    padding: 18px 16px 15px;
  }

  .rgs-auth-modal-body {
    max-height: calc(100vh - 210px);
    padding: 17px;
  }

  .rgs-auth-mobile-notice {
    justify-content: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
  }
}