/* Shared styles for the auth pages (Login, ForgotPassword, EmailPassword). */

.page-root {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 100%;
  min-height: 100%;
}

.auth-layout {
  width: 100%;
  max-width: 100%;
  flex: 1 1 auto;
  margin: 0;
  min-height: 0;
  background: #ffffff;
  border-radius: 0;
  overflow: hidden;
  box-shadow: 0 1.25rem 2.7rem rgba(49, 19, 90, 0.17);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr);
}

.auth-visual {
  min-width: 0;
  position: relative;
  background-color: #642de0;
  background-image: linear-gradient(180deg, rgba(38, 12, 78, 0.42) 0%, rgba(28, 8, 58, 0.72) 100%),
    url('https://res.cloudinary.com/grand-canyon-university/image/upload/c_scale,w_640/c_limit,w_640/q_auto:eco,f_avif/v1761698407/gcu_edu/sites/default/files/2025-05/mascot-at-basketball-game-655148.jpg');
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: flex-end;
  padding: 2rem;
}

.auth-visual__overlay {
  max-width: 27rem;
  color: #ffffff;
  display: grid;
  gap: 0.8rem;
}

.auth-visual__eyebrow,
.auth-visual__title,
.auth-visual__text {
  margin: 0;
}

.auth-visual__eyebrow {
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #ffe49c;
}

.auth-visual__title {
  font-size: clamp(2rem, 3.3vw, 2.9rem);
  line-height: 1.08;
  color: #ffffff;
  text-indent: -9999px;
  overflow: hidden;
  height: clamp(2.2rem, 3.5vw, 3.2rem);
  background-repeat: no-repeat;
  background-position: left center;
  background-size: auto 100%;
  user-select: none;
  pointer-events: none;
}

.auth-visual__title--welcome {
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 600 70"><text x="0" y="52" fill="%23ffffff" font-family="Segoe UI, sans-serif" font-size="52" font-weight="400" letter-spacing="0">Welcome!</text></svg>');
}

.auth-visual__title--covered {
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 600 70"><text x="0" y="52" fill="%23ffffff" font-family="Segoe UI, sans-serif" font-size="52" font-weight="400" letter-spacing="0">We&#8217;ve Got You Covered</text></svg>');
}

.auth-visual__text {
  font-size: 1.02rem;
  line-height: 1.5;
  color: #f1eafc;
}

.auth-panel {
  min-width: 0;
  min-height: 0;
  width: 100%;
  align-self: stretch;
  background: var(--surface);
  padding: 1.15rem 2rem 2rem;
  display: grid;
  align-content: start;
  gap: 1.25rem;
  overflow-y: auto;
}

.eyebrow {
  margin: 0;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gcu-purple);
  font-weight: 700;
}

.auth-panel h1,
.auth-panel h2,
.auth-panel p {
  margin: 0;
}

.auth-panel h1 {
  font-size: clamp(1.35rem, 2.5vw, 1.85rem);
  line-height: 1.25;
  text-align: center;
  color: var(--gcu-purple);
}

.auth-option {
  padding: 1rem;
  display: grid;
  gap: 0.75rem;
  background: linear-gradient(180deg, #ffffff 0%, #fcf9ff 100%);
}

.auth-option + .auth-option {
  border-top: 1px solid #e0d2f6;
  padding-top: 1.2rem;
  margin-top: 0.25rem;
}

.auth-panel h2 {
  color: var(--gcu-purple-strong);
  font-size: 1.4rem;
  font-weight: 800;
  margin: 0 0 0.35rem;
  letter-spacing: -0.01em;
}

.auth-option p {
  color: var(--text-muted);
}

.create-account-form {
  display: grid;
  gap: 0.6rem;
}

.create-account-form .control-container label {
  display: block;
  margin-bottom: 0.35rem;
}

.create-account-form .secondary-btn {
  width: 100%;
}

.auth-panel label {
  font-weight: 600;
  font-size: 0.9rem;
}

.auth-panel input,
.auth-panel button {
  font: inherit;
}

.auth-panel input {
  width: 100%;
  padding: 0.65rem 0.75rem;
  border: 1px solid #c6b3e9;
  border-radius: 0.5rem;
  background: #fff;
}

.auth-panel input:focus {
  outline: 2px solid var(--gcu-gold);
  outline-offset: 1px;
}

.auth-panel button {
  border: 1px solid transparent;
  border-radius: 0.6rem;
  padding: 0.75rem 0.85rem;
  cursor: pointer;
}

.secondary-btn {
  background: #FFE900;
  color: #522398;
  font-weight: 700 !important;
  font-size: 1rem;
  letter-spacing: 0.02em;
}

a.secondary-btn {
  display: block;
  padding: 0.75rem 0.85rem;
  border: 1px solid transparent;
  border-radius: 0.6rem;
  text-align: center;
  text-decoration: none;
}

.secondary-btn:hover {
  background: #f5dd00;
  opacity: 0.9;
}

.secondary-btn:focus-visible,
.auth-panel input:focus-visible {
  outline: 2px solid var(--gcu-gold);
  outline-offset: 2px;
}

/* Nested login options: collapsed by default, expanding reveals the sign-in form */
.login-toggle {
  border: 1px solid #e0d2f6;
  border-radius: 0.9rem;
  overflow: hidden;
  background: #ffffff;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.login-toggle--open {
  border-color: var(--gcu-purple);
  box-shadow: 0 0.6rem 1.4rem rgba(82, 35, 152, 0.16);
}

.login-toggle__trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 1rem 1.1rem;
  background: linear-gradient(180deg, #ffffff 0%, #fbf8ff 100%);
  border: none;
  color: var(--gcu-purple-strong);
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.login-toggle__trigger:hover {
  background: #f1e6ff;
}

.login-toggle__trigger:focus-visible {
  outline: 2px solid var(--gcu-gold);
  outline-offset: -2px;
}

.login-toggle__chevron {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: var(--gcu-purple-soft);
  color: var(--gcu-purple);
  font-size: 1.35rem;
  transition: transform 0.3s ease, background-color 0.2s ease, color 0.2s ease;
}

.login-toggle--open .login-toggle__chevron {
  transform: rotate(180deg);
  background: var(--gcu-purple);
  color: #ffffff;
}

/* Generous max-height avoids clipping form content once the panel is open */
.login-options {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
}

.login-toggle--open .login-options {
  max-height: 48rem;
}

.login-options__inner {
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity 0.3s ease 0.05s, transform 0.3s ease 0.05s;
}

.login-toggle--open .login-options__inner {
  opacity: 1;
  transform: translateY(0);
}

.login-options__inner .auth-option {
  background: #ffffff;
}

.role-group {
  border: 1px solid #c6b3e9;
  border-radius: 0.5rem;
  padding: 0.75rem 1rem;
  margin: 0;
}

.role-group legend {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--gcu-purple);
  padding: 0 0.25rem;
}

.radio-group {
  display: flex;
  gap: 1.5rem;
  margin-top: 0.5rem;
  flex-wrap: wrap;
}

.radio-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.radio-label input[type="radio"] {
  width: auto;
  margin: 0;
  accent-color: var(--gcu-purple);
  cursor: pointer;
}

.auth-signin-row {
  margin-top: 0.25rem;
  font-size: 1rem;
  color: #4b3e66;
}

.auth-signin-link {
  font-weight: 700;
  letter-spacing: 0.02em;
  text-decoration: none;
  color: var(--brand-grad-start);
  margin-left: 0.35rem;
}

.auth-signin-link:hover {
  text-decoration: underline;
}

.auth-disclaimer {
  margin-top: 0.45rem;
  font-size: 0.74rem;
  line-height: 1.45;
  color: #6a5d83;
}

@media (max-width: 980px) {
  .auth-layout {
    grid-template-columns: 1fr;
  }

  .auth-visual {
    min-height: 18.5rem;
  }
}

@media (max-width: 640px) {
  .auth-layout {
    border-radius: 0;
    border: 0;
    min-height: 0;
  }

  .auth-visual {
    display: none;
  }

  .auth-visual__title {
    font-size: 1.8rem;
  }

  .auth-panel {
    padding: 1.2rem;
  }

  .auth-option {
    padding: 0.85rem;
  }
}

