/**
 * TetHub campus-editorial auth surfaces
 * Shared by login, register, login sheet, welcome, auth success modals.
 */

:root {
  --auth-primary: #046FAD;
  --auth-primary-dark: #034E7A;
  --auth-primary-light: #0A8FDB;
  --auth-ink: #0B1F2A;
  --auth-muted: #5B6B75;
  --auth-line: #D9E2E8;
  --auth-surface: #FFFFFF;
  --auth-soft: #F3F7FA;
  --auth-success: #0D9F6E;
  --auth-danger: #DC2626;
  --auth-radius: 1.25rem;
  --auth-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --auth-shadow: 0 24px 48px -24px rgba(3, 78, 122, 0.35);
}

[data-theme="dark"] {
  --auth-ink: #E7E9EA;
  --auth-muted: #AAB8C2;
  --auth-line: #2F3336;
  --auth-surface: #0F1419;
  --auth-soft: #16181C;
  --auth-shadow: 0 24px 48px -24px rgba(0, 0, 0, 0.55);
}

/* ── Page shell ─────────────────────────────────────────── */
.auth-campus-body {
  margin: 0;
  min-height: 100vh;
  font-family: "Inter", system-ui, sans-serif;
  color: var(--auth-ink);
  background: var(--auth-soft);
  overflow-x: hidden;
}

.auth-campus {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
  align-items: start;
  width: 100%;
  min-height: 100vh;
  animation: authFadeIn 0.55s var(--auth-ease) both;
}

@keyframes authFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes authRise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ── Atmosphere panel (fixed while form scrolls) ────────── */
.auth-atmosphere {
  position: sticky;
  top: 0;
  height: 100vh;
  max-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(2rem, 5vw, 4.5rem);
  color: #fff;
  background:
    radial-gradient(90% 70% at 85% 15%, rgba(10, 143, 219, 0.35) 0%, transparent 55%),
    linear-gradient(165deg, #035a8c 0%, #023A5C 42%, #011f33 100%);
  overflow: hidden;
  isolation: isolate;
}

.auth-atmosphere::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 56px 56px;
  opacity: 0.35;
  pointer-events: none;
  z-index: 0;
}

.auth-atmosphere::after {
  content: "";
  position: absolute;
  width: 70%;
  height: 70%;
  right: -18%;
  bottom: -22%;
  background: radial-gradient(circle, rgba(10, 143, 219, 0.28) 0%, transparent 68%);
  pointer-events: none;
  z-index: 0;
}

.auth-atmosphere-inner {
  position: relative;
  z-index: 1;
  max-width: 26rem;
  padding: 1.75rem 1.85rem 1.6rem;
  border-radius: 1.35rem;
  background: rgba(1, 24, 40, 0.62);
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow:
    0 24px 48px -20px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  animation: authRise 0.7s var(--auth-ease) 0.08s both;
}

.auth-eyebrow {
  display: inline-block;
  margin: 0 0 0.85rem;
  padding: 0.28rem 0.7rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 650;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #e8f4fc;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
}

.auth-wordmark {
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  font-size: clamp(2.6rem, 5.5vw, 3.75rem);
  line-height: 0.95;
  letter-spacing: -0.04em;
  margin: 0 0 1rem;
  color: #ffffff;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.25);
}

.auth-wordmark img {
  display: block;
  height: clamp(2.5rem, 5vw, 3.25rem);
  width: auto;
  margin-bottom: 0.75rem;
  filter: brightness(0) invert(1);
}

.auth-tagline {
  font-size: 1.05rem;
  line-height: 1.55;
  margin: 0;
  max-width: 22rem;
  color: #f4f9fc;
  font-weight: 450;
}

.auth-rotator {
  margin-top: 1.35rem;
  padding-top: 1.1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  min-height: 1.5rem;
  font-size: 0.9rem;
  letter-spacing: 0.01em;
  color: #d7e8f4;
}

.auth-rotator span {
  display: none;
}

.auth-rotator span.is-active {
  display: inline;
  animation: authRise 0.45s var(--auth-ease) both;
}

.auth-atmosphere-mobile {
  display: none;
  padding: 1.25rem 1.25rem 0.85rem;
  background: linear-gradient(160deg, #035a8c, #023A5C);
  color: #fff;
  text-align: center;
}

.auth-atmosphere-mobile .auth-wordmark {
  font-size: 1.75rem;
  margin-bottom: 0.35rem;
}

.auth-atmosphere-mobile .auth-tagline {
  font-size: 0.875rem;
  margin: 0 auto;
  max-width: 18rem;
  color: #f4f9fc;
}

/* ── Form column (scrolls independently on tall pages) ──── */
.auth-panel {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  min-height: 100vh;
  padding: clamp(1.75rem, 4vw, 3.25rem) clamp(1.25rem, 4vw, 3.5rem) 3rem;
  background:
    radial-gradient(80% 50% at 100% 0%, rgba(4, 111, 173, 0.06) 0%, transparent 55%),
    var(--auth-surface);
  animation: authRise 0.65s var(--auth-ease) 0.12s both;
}

.auth-panel-inner {
  width: 100%;
  max-width: 23.5rem;
  margin: auto 0 auto auto;
  padding: 1.75rem 0 2rem;
}

@media (min-width: 992px) {
  .auth-panel-inner {
    margin-right: auto;
    margin-left: auto;
  }
}

.auth-back {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--auth-muted);
  text-decoration: none;
  font-size: 0.8125rem;
  font-weight: 500;
  margin-bottom: 2rem;
  transition: color 0.2s ease;
}

.auth-back:hover {
  color: var(--auth-primary);
}

.auth-header {
  margin-bottom: 1.65rem;
}

.auth-header .auth-logo {
  display: none;
}

.auth-title {
  font-family: "Poppins", sans-serif;
  font-size: clamp(1.65rem, 3vw, 1.95rem);
  font-weight: 700;
  letter-spacing: -0.035em;
  margin: 0 0 0.4rem;
  color: var(--auth-ink);
}

.auth-subtitle {
  margin: 0;
  color: var(--auth-muted);
  font-size: 0.925rem;
  line-height: 1.45;
}

.auth-subtitle a {
  color: var(--auth-primary);
  font-weight: 600;
  text-decoration: none;
}

.auth-subtitle a:hover {
  text-decoration: underline;
}

.auth-notice {
  border-radius: 0.75rem;
  padding: 0.8rem 1rem;
  font-size: 0.9rem;
  margin-bottom: 1rem;
  border: 1px solid transparent;
}

.auth-notice.error {
  background: #FEF2F2;
  color: #B91C1C;
  border-color: #FECACA;
}

.auth-notice.success {
  background: #ECFDF5;
  color: #047857;
  border-color: #A7F3D0;
}

/* ── Form controls ──────────────────────────────────────── */
.form-group {
  margin-bottom: 1.15rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
}

.form-group.half {
  margin-bottom: 0;
}

.form-label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  margin-bottom: 0.4rem;
  color: var(--auth-ink);
}

.form-label .optional {
  font-weight: 500;
  color: var(--auth-muted);
}

.form-input-group {
  position: relative;
}

.form-input,
.form-select {
  width: 100%;
  box-sizing: border-box;
  appearance: none;
  border: 1.5px solid var(--auth-line);
  background: var(--auth-soft);
  color: var(--auth-ink);
  border-radius: 0.9rem;
  padding: 0.9rem 2.75rem 0.9rem 2.75rem;
  font-size: 0.95rem;
  font-family: inherit;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.form-input:focus,
.form-select:focus {
  outline: none;
  border-color: var(--auth-primary);
  background: var(--auth-surface);
  box-shadow: 0 0 0 4px rgba(4, 111, 173, 0.12);
}

.input-icon {
  position: absolute;
  left: 0.95rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--auth-muted);
  pointer-events: none;
  font-size: 1rem;
}

.password-toggle {
  position: absolute;
  right: 0.65rem;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  background: transparent;
  color: var(--auth-muted);
  cursor: pointer;
  padding: 0.35rem;
  display: inline-flex;
}

.password-toggle:hover {
  color: var(--auth-primary);
}

.error-message {
  color: var(--auth-danger);
  font-size: 0.8rem;
  margin-top: 0.35rem;
  min-height: 0;
}

.form-options {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin: 0.25rem 0 1.35rem;
  font-size: 0.875rem;
}

.checkbox-group {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  margin-bottom: 0.85rem;
  font-size: 0.875rem;
  color: var(--auth-muted);
}

.checkbox-group input {
  margin-top: 0.2rem;
  accent-color: var(--auth-primary);
}

.checkbox-group a {
  color: var(--auth-primary);
  text-decoration: none;
  font-weight: 600;
}

.forgot-link {
  color: var(--auth-primary);
  text-decoration: none;
  font-weight: 600;
}

.forgot-link:hover {
  text-decoration: underline;
}

.form-hint {
  font-size: 0.8rem;
  color: var(--auth-muted);
  margin-top: 0.35rem;
}

/* ── Buttons ────────────────────────────────────────────── */
.btn-primary,
.btn-submit,
.btn-next,
.btn.btn-submit,
.btn.btn-next {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  border: none;
  border-radius: 0.9rem;
  padding: 0.95rem 1.25rem;
  font-size: 0.975rem;
  font-weight: 650;
  font-family: inherit;
  color: #fff;
  background: var(--auth-primary);
  cursor: pointer;
  transition: transform 0.18s var(--auth-ease), background 0.18s ease, box-shadow 0.18s ease;
  box-shadow: 0 10px 24px -12px rgba(4, 111, 173, 0.7);
}

.btn-primary:hover,
.btn-submit:hover,
.btn-next:hover,
.btn.btn-submit:hover,
.btn.btn-next:hover {
  background: var(--auth-primary-dark);
  transform: translateY(-1px);
}

.btn-primary:active,
.btn-submit:active,
.btn-next:active {
  transform: translateY(0);
}

.btn-primary:disabled,
.btn-submit:disabled,
.btn-next:disabled,
.btn.btn-submit:disabled,
.btn.btn-next:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-back,
.btn.btn-back,
.btn-secondary,
.btn.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  width: 100%;
  border: 1.5px solid var(--auth-line);
  border-radius: 0.9rem;
  padding: 0.9rem 1.1rem;
  background: var(--auth-surface);
  color: var(--auth-ink);
  font-size: 0.95rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease, transform 0.15s ease;
}

.btn-back:hover,
.btn.btn-back:hover,
.btn-secondary:hover,
.btn.btn-secondary:hover {
  border-color: var(--auth-primary);
  color: var(--auth-primary);
  background: var(--auth-soft);
}

.btn-back:active,
.btn-secondary:active {
  transform: translateY(1px);
}

.btn-group {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: 0.65rem;
  margin-top: 1.35rem;
}

.btn-group .btn,
.btn-group .btn-next,
.btn-group .btn-submit,
.btn-group .btn-back,
.btn-group .btn-secondary {
  width: auto;
  flex: 1 1 auto;
  min-width: 0;
}

/* Single primary CTA */
.btn-group:has(> :only-child),
.form-step[data-step="1"] .btn-group,
.btn-group[data-layout="stack"] {
  display: grid;
  grid-template-columns: 1fr;
}

/* Back + Continue */
.btn-group[data-layout="split"] {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.4fr);
}

/* Back + Skip + Continue */
.btn-group[data-layout="triple"] {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) minmax(0, 1.35fr);
}

.btn-group[data-layout="triple"] .btn-back {
  flex: 0 0 auto;
  width: auto;
  padding-left: 0.95rem;
  padding-right: 0.95rem;
}

.btn-group[data-layout="triple"] .btn-secondary {
  font-weight: 550;
  color: var(--auth-muted);
  background: transparent;
}

@media (max-width: 520px) {
  .btn-group[data-layout="triple"] {
    grid-template-columns: 1fr 1fr;
  }
  .btn-group[data-layout="triple"] .btn-next {
    grid-column: 1 / -1;
  }
}

.spinner {
  width: 1.15rem;
  height: 1.15rem;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: authSpin 0.6s linear infinite;
}

@keyframes authSpin {
  to { transform: rotate(360deg); }
}

/* ── Login tabs / social ────────────────────────────────── */
.login-tabs {
  display: flex;
  gap: 0.35rem;
  margin-bottom: 1.35rem;
  padding: 0.25rem;
  background: var(--auth-soft);
  border-radius: 0.85rem;
}

.login-tab {
  flex: 1;
  border: none;
  background: transparent;
  color: var(--auth-muted);
  font-weight: 600;
  font-size: 0.85rem;
  border-radius: 0.7rem;
  padding: 0.7rem 0.75rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  font-family: inherit;
  transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.login-tab.active {
  background: var(--auth-surface);
  color: var(--auth-primary);
  box-shadow: 0 1px 3px rgba(11, 31, 42, 0.08);
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  margin: 1.5rem 0 1.1rem;
  color: var(--auth-muted);
  font-size: 0.8rem;
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--auth-line);
}

.social-login {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.65rem;
}

.btn-social {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 2.85rem;
  padding: 0.7rem 0.5rem;
  border: 1.5px solid var(--auth-line);
  border-radius: 0.85rem;
  background: var(--auth-surface);
  color: var(--auth-ink);
  text-decoration: none;
  font-size: 0.82rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease, transform 0.18s var(--auth-ease), background 0.2s ease;
}

.btn-social i {
  font-size: 1.05rem;
}

.btn-social:hover {
  border-color: var(--auth-primary);
  color: var(--auth-primary);
  background: rgba(4, 111, 173, 0.04);
  transform: translateY(-1px);
}

.auth-panel-footnote {
  margin-top: 1.75rem;
  text-align: center;
  font-size: 0.8rem;
  color: var(--auth-muted);
  line-height: 1.55;
}

.auth-panel-footnote a {
  color: var(--auth-primary);
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.auth-panel-footnote a:hover {
  color: var(--auth-primary-dark, #034e7a);
}

/* ── Register steps ─────────────────────────────────────── */
.progress-steps {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.35rem;
  margin-bottom: 1.75rem;
}

.progress-line {
  position: absolute;
  top: 1rem;
  left: 12%;
  right: 12%;
  height: 2px;
  background: var(--auth-line);
  z-index: 0;
}

.progress-line::after {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: var(--progress, 0%);
  background: var(--auth-primary);
  transition: width 0.35s var(--auth-ease);
}

.step {
  position: relative;
  z-index: 1;
  text-align: center;
}

.step-circle {
  width: 2rem;
  height: 2rem;
  margin: 0 auto 0.4rem;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 700;
  background: var(--auth-soft);
  color: var(--auth-muted);
  border: 2px solid var(--auth-line);
  transition: all 0.25s ease;
}

.step.active .step-circle,
.step.completed .step-circle {
  background: var(--auth-primary);
  border-color: var(--auth-primary);
  color: #fff;
}

.step-label {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--auth-muted);
}

.step.active .step-label {
  color: var(--auth-primary);
}

.form-step {
  display: none;
  animation: authRise 0.4s var(--auth-ease) both;
}

.form-step.active {
  display: block;
}

.step-title {
  font-family: "Poppins", sans-serif;
  font-size: 1.2rem;
  margin: 0 0 0.25rem;
}

.step-description {
  margin: 0 0 1.25rem;
  color: var(--auth-muted);
  font-size: 0.9rem;
}

.password-strength {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.35rem;
  margin-top: 0.55rem;
}

.strength-bar {
  height: 4px;
  border-radius: 999px;
  background: var(--auth-line);
}

.strength-bar.active {
  background: var(--auth-primary);
}

.strength-bar.weak { background: #F59E0B; }
.strength-bar.fair { background: #EAB308; }
.strength-bar.medium { background: #10B981; }
.strength-bar.good { background: #10B981; }
.strength-bar.strong { background: #059669; }

.password-hint {
  font-size: 0.75rem;
  color: var(--auth-muted);
  margin-top: 0.4rem;
}

.error-message.show {
  display: block;
}

/* ── Guest auth info sheet ──────────────────────────────── */
#login-sheet.auth-sheet .modal-dialog {
  margin: 0 auto;
  max-width: 420px;
}

@media (max-width: 575.98px) {
  #login-sheet.auth-sheet .modal-dialog {
    margin: 0;
    max-width: 100%;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
  }
}

#login-sheet.auth-sheet .modal-content {
  border: none;
  border-radius: 1.25rem 1.25rem 0 0;
  overflow: hidden;
  box-shadow: var(--auth-shadow);
  background: var(--auth-surface);
}

#login-sheet.auth-sheet .modal-body {
  padding: 0;
}

.auth-sheet-handle {
  width: 2.5rem;
  height: 0.28rem;
  border-radius: 999px;
  background: var(--auth-line);
  margin: 0.65rem auto 0;
}

.auth-sheet-body {
  padding: 0.75rem 1.35rem 1.5rem;
}

.auth-sheet-brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin-bottom: 0.85rem;
}

.auth-sheet-brand img {
  height: 1.6rem;
  width: auto;
}

.auth-sheet-brand-text {
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: -0.02em;
  color: var(--auth-primary);
}

.auth-sheet-icon {
  width: 3.25rem;
  height: 3.25rem;
  border-radius: 0.9rem;
  margin: 0 auto 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(4, 111, 173, 0.1);
  color: var(--auth-primary);
  font-size: 1.45rem;
}

#login-sheet-title {
  font-family: "Poppins", sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 0.4rem;
  color: var(--auth-ink);
  text-align: center;
}

#login-sheet-body {
  margin: 0 0 1.15rem;
  color: var(--auth-muted);
  font-size: 0.92rem;
  line-height: 1.5;
  text-align: center;
}

.auth-sheet-actions {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-bottom: 0.85rem;
}

#login-sheet .btn-primary.btn-block {
  width: 100%;
  border: none;
  border-radius: 0.85rem;
  padding: 0.9rem 1rem;
  font-weight: 650;
  background: var(--auth-primary);
  color: #fff;
  box-shadow: 0 10px 22px -12px rgba(4, 111, 173, 0.7);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

#login-sheet .btn-primary.btn-block:hover {
  background: var(--auth-primary-dark);
  color: #fff;
}

#login-sheet .btn-outline-primary.btn-block {
  width: 100%;
  border-radius: 0.85rem;
  font-weight: 650;
  border: 1.5px solid var(--auth-line);
  color: var(--auth-ink);
  background: var(--auth-soft, #f3f4f6);
  padding: 0.85rem 1rem;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

#login-sheet .btn-outline-primary.btn-block:hover {
  border-color: var(--auth-primary);
  color: var(--auth-primary);
  background: #fff;
}

#login-sheet .auth-sheet-footer a {
  color: var(--auth-primary);
  font-weight: 600;
  text-decoration: none;
}

#login-sheet .auth-sheet-footer {
  text-align: center;
  margin-top: 0.25rem;
  font-size: 0.9rem;
  color: var(--auth-muted);
}

#login-sheet #login-sheet-keep-browsing {
  margin: 0;
}

/* ── Auth success Swal ──────────────────────────────────── */
@keyframes swalAuthEnter {
  from { opacity: 0; transform: translateY(14px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes swalAuthLeave {
  from { opacity: 1; transform: scale(1); }
  to { opacity: 0; transform: scale(0.97); }
}

@keyframes swalAuthProgress {
  from { transform: scaleX(1); }
  to { transform: scaleX(0); }
}

@keyframes swalAuthCheck {
  0% { transform: scale(0.6); opacity: 0; }
  60% { transform: scale(1.08); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}

.swal2-popup.swal-tethub-auth {
  border-radius: 1.35rem !important;
  padding: 0 !important;
  overflow: hidden !important;
  font-family: "Inter", system-ui, sans-serif !important;
  box-shadow: 0 28px 64px -28px rgba(3, 58, 92, 0.55) !important;
  border: 1px solid rgba(4, 111, 173, 0.12) !important;
}

.swal2-popup.swal-tethub-auth.swal-auth-enter {
  animation: swalAuthEnter 0.38s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.swal2-popup.swal-tethub-auth.swal-auth-leave {
  animation: swalAuthLeave 0.2s ease both;
}

.swal2-popup.swal-tethub-auth .swal2-title {
  display: none !important;
}

.swal2-popup.swal-tethub-auth .swal-auth-html,
.swal2-popup.swal-tethub-auth .swal2-html-container {
  margin: 0 !important;
  padding: 0 !important;
  overflow: visible !important;
  color: inherit !important;
}

.swal-auth-card {
  text-align: center;
  padding: 0 0 0.25rem;
}

.swal-auth-hero {
  background:
    radial-gradient(90% 120% at 80% 0%, rgba(10, 143, 219, 0.35) 0%, transparent 55%),
    linear-gradient(160deg, #046FAD 0%, #023A5C 100%);
  color: #fff;
  padding: 1.65rem 1.5rem 1.35rem;
  position: relative;
}

.swal-auth-brand {
  margin: 0.65rem 0 0;
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.88;
}

.swal-auth-mark {
  width: 3.35rem;
  height: 3.35rem;
  margin: 0 auto;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: #fff;
  font-size: 1.45rem;
  animation: swalAuthCheck 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.swal-auth-title {
  font-family: "Poppins", sans-serif;
  font-weight: 700;
  letter-spacing: -0.03em;
  font-size: 1.4rem;
  margin: 1.25rem 1.35rem 0.4rem;
  color: #0B1F2A;
}

.swal-auth-body {
  padding: 0 1.5rem;
  color: #5B6B75;
  font-size: 0.95rem;
  line-height: 1.5;
}

.swal-auth-body p,
.swal-auth-msg {
  margin: 0;
}

.swal-auth-progress {
  margin: 1.15rem 1.5rem 0.55rem;
  height: 4px;
  border-radius: 999px;
  background: #E6EEF4;
  overflow: hidden;
}

.swal-auth-progress-bar {
  height: 100%;
  width: 100%;
  transform-origin: left center;
  background: linear-gradient(90deg, #046FAD, #0A8FDB);
  border-radius: inherit;
  animation-name: swalAuthProgress;
  animation-timing-function: linear;
  animation-fill-mode: forwards;
}

.swal-auth-countdown {
  margin: 0 1.5rem 0.25rem;
  font-size: 0.8rem;
  color: #7A8A94;
}

.swal-auth-countdown strong {
  color: #046FAD;
  font-variant-numeric: tabular-nums;
}

.swal2-popup.swal-tethub-auth .swal-auth-actions {
  margin: 1rem 1.35rem 1.35rem !important;
  width: auto !important;
}

.swal2-popup.swal-tethub-auth .swal-auth-confirm {
  width: 100% !important;
  border: none !important;
  border-radius: 0.85rem !important;
  font-weight: 650 !important;
  font-size: 0.95rem !important;
  padding: 0.85rem 1.25rem !important;
  background: #046FAD !important;
  color: #fff !important;
  box-shadow: 0 12px 24px -14px rgba(4, 111, 173, 0.8);
  transition: background 0.18s ease, transform 0.18s ease;
}

.swal2-popup.swal-tethub-auth .swal-auth-confirm:hover {
  background: #034E7A !important;
  transform: translateY(-1px);
}

/* Lightweight post-auth redirect (no modal) */
.auth-redirect-overlay {
  position: fixed;
  inset: 0;
  z-index: 10050;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(11, 31, 42, 0.35);
  backdrop-filter: blur(2px);
}

.auth-redirect-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.85rem;
  padding: 1.25rem 1.5rem;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 16px 40px rgba(11, 31, 42, 0.18);
  min-width: 12rem;
}

.auth-redirect-spinner {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 2.5px solid rgba(4, 111, 173, 0.2);
  border-top-color: #046FAD;
  animation: auth-redirect-spin 0.7s linear infinite;
}

.auth-redirect-text {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 500;
  color: #0B1F2A;
}

@keyframes auth-redirect-spin {
  to { transform: rotate(360deg); }
}

/* ── Welcome page ───────────────────────────────────────── */
.welcome-campus {
  min-height: 100vh;
  background: var(--auth-soft);
}

.welcome-campus-banner {
  background: linear-gradient(155deg, #046FAD 0%, #023A5C 100%);
  color: #fff;
  padding: 2.5rem 1.5rem 2rem;
  text-align: center;
}

.welcome-campus-banner .auth-wordmark {
  font-size: 2.25rem;
  margin-bottom: 0.75rem;
}

.welcome-campus-banner h1 {
  font-family: "Poppins", sans-serif;
  font-size: clamp(1.4rem, 3vw, 1.85rem);
  margin: 0 0 0.35rem;
  letter-spacing: -0.02em;
}

.welcome-campus-banner p {
  margin: 0;
  opacity: 0.88;
}

.welcome-campus .welcome-container {
  max-width: 720px;
  margin: -1rem auto 0;
  padding: 1.5rem 1.25rem 3rem;
  position: relative;
  z-index: 1;
}

.welcome-campus .interests-section,
.welcome-campus .quick-tips {
  background: var(--auth-surface);
  border-radius: var(--auth-radius);
  padding: 1.35rem;
  margin-bottom: 1rem;
  border: 1px solid var(--auth-line);
}

.welcome-campus .section-title {
  font-family: "Poppins", sans-serif;
  font-size: 1.15rem;
  margin: 0 0 0.35rem;
  text-align: center;
}

.welcome-campus .section-subtitle {
  text-align: center;
  color: var(--auth-muted);
  font-size: 0.9rem;
  margin: 0 0 1.25rem;
}

.welcome-campus .selected-count {
  text-align: center;
  font-size: 0.875rem;
  color: var(--auth-muted);
  margin-bottom: 1rem;
}

.welcome-campus .interests-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 0.65rem;
}

.welcome-campus .interest-card {
  border: 1.5px solid var(--auth-line);
  border-radius: 0.85rem;
  padding: 0.85rem 0.5rem;
  text-align: center;
  cursor: pointer;
  background: var(--auth-surface);
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.18s var(--auth-ease);
}

.welcome-campus .interest-card:hover {
  border-color: var(--auth-primary);
  transform: translateY(-1px);
}

.welcome-campus .interest-card.selected {
  border-color: var(--auth-primary);
  background: rgba(4, 111, 173, 0.08);
}

.welcome-campus .interest-icon {
  font-size: 1.35rem;
  display: block;
  margin-bottom: 0.35rem;
}

.welcome-campus .interest-name {
  font-size: 0.8rem;
  font-weight: 600;
}

.welcome-campus .action-buttons {
  display: flex;
  gap: 0.75rem;
  margin: 1rem 0 1.25rem;
}

.welcome-campus .btn {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  border-radius: 0.85rem;
  padding: 0.9rem 1rem;
  font-weight: 650;
  font-family: inherit;
  cursor: pointer;
  border: none;
}

.welcome-campus .btn-primary {
  background: var(--auth-primary);
  color: #fff;
}

.welcome-campus .btn-primary:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.welcome-campus .btn-secondary {
  background: transparent;
  border: 1.5px solid var(--auth-line);
  color: var(--auth-ink);
}

.welcome-campus .quick-tips h3 {
  font-size: 0.95rem;
  margin: 0 0 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.welcome-campus .tip-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.welcome-campus .tip-list li {
  display: flex;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: var(--auth-muted);
  padding: 0.4rem 0;
}

.welcome-campus .tip-list li i {
  color: var(--auth-success);
  margin-top: 0.15rem;
}

.welcome-campus .spinner {
  display: none;
}

.welcome-campus .onboard-step { display: none; }
.welcome-campus .onboard-step.is-active { display: block; }

.welcome-campus .onboard-profile-form {
  margin-top: 0.5rem;
  text-align: left;
}

.welcome-campus .onboard-profile-form .form-group { margin-bottom: 1rem; }

.welcome-campus .onboard-profile-form .form-hint {
  margin: 0.35rem 0 0;
  font-size: 0.8rem;
  color: var(--auth-muted);
}

.welcome-campus .onboard-verified {
  color: var(--auth-success) !important;
  font-weight: 500;
}

.welcome-campus .optional {
  font-weight: 400;
  color: var(--auth-muted);
  font-size: 0.85em;
}

/* ── Responsive ─────────────────────────────────────────── */
@media (max-width: 991px) {
  .auth-campus {
    grid-template-columns: 1fr;
  }

  .auth-atmosphere {
    display: none;
    position: static;
    height: auto;
  }

  .auth-atmosphere-mobile {
    display: block;
  }

  .auth-panel {
    padding: 1.25rem 1.15rem 2.5rem;
    min-height: calc(100vh - 6rem);
  }

  .social-login {
    grid-template-columns: 1fr;
  }

  .form-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .progress-steps .step-label {
    display: none;
  }

  .auth-title {
    font-size: 1.45rem;
  }
}
