/**
 * KURO FANGS — AUTHENTICATION & LOGIN DESIGN SYSTEM
 * Source of Truth: media_1790610106701.png
 * Warm Cream (#FBF8F3), Deep Burgundy (#7E1D2A), Soft Neutral (#6E655F)
 * Fully Bi-directional RTL/LTR via CSS Logical Properties
 */

/* ==========================================================================
   1. GLOBAL VIEWPORT & FULL BLEED LOGIN OVERRIDES
   ========================================================================== */
body.login-view-active {
  background-color: #FAF7F2 !important;
  overflow-x: hidden !important;
}

body.login-view-active #app-sidebar,
body.login-view-active #site-header,
body.login-view-active #sidebar-backdrop,
body.login-view-active .mobile-bottom-nav,
body.login-view-active .settings-mobile-sheet-backdrop,
body.login-view-active #guest-encourage-banner {
  display: none !important;
}

body.login-view-active .app-main-wrapper {
  margin: 0 !important;
  padding: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
  min-height: 100vh !important;
}

body.login-view-active #app {
  margin: 0 !important;
  padding: 0 !important;
  min-height: 100vh !important;
  width: 100% !important;
}

/* ==========================================================================
   2. LOGIN VIEWPORT & SPLIT CONTAINER
   ========================================================================== */
.kuro-login-viewport {
  min-height: 100vh;
  width: 100%;
  background-color: #FAF7F2;
  background-image: 
    radial-gradient(circle at 20% 15%, rgba(126, 29, 42, 0.03) 0%, transparent 40%),
    radial-gradient(circle at 85% 80%, rgba(188, 74, 71, 0.03) 0%, transparent 45%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
  box-sizing: border-box;
  font-family: 'IBM Plex Sans Arabic', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  color: #1F1A17;
}

.kuro-login-split-layout {
  display: grid;
  grid-template-columns: 1.15fr 0.95fr;
  align-items: center;
  gap: 56px;
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
}

/* ==========================================================================
   3. LEFT PANE: BRANDING, HEADLINE, 4 FEATURE CARDS & ILLUSTRATION
   ========================================================================== */
.kuro-login-left-pane {
  display: flex;
  flex-direction: column;
  gap: 28px;
  padding-inline-end: 20px;
}

/* 3.1 Top Branding */
.login-brand-header {
  display: flex;
  align-items: center;
  gap: 14px;
}

.login-brand-emblem-wrap {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #FFF;
  border: 1px solid #EAE3D6;
  box-shadow: 0 4px 12px rgba(126, 29, 42, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
}

.login-brand-emblem-wrap img {
  width: 38px;
  height: 38px;
  object-fit: contain;
}

.login-brand-meta {
  display: flex;
  flex-direction: column;
}

.login-brand-title {
  font-size: 1.35rem;
  font-weight: 850;
  color: #7E1D2A;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.login-brand-tagline {
  font-size: 0.82rem;
  color: #8C827A;
  font-weight: 500;
}

/* 3.2 Hero Headline */
.login-headline-group {
  margin-top: 4px;
}

.login-hero-title {
  font-family: Georgia, 'Playfair Display', 'IBM Plex Sans Arabic', serif;
  font-size: 3.25rem;
  font-weight: 900;
  color: #1F1A17;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin: 0 0 16px 0;
}

.login-hero-accent {
  color: #7E1D2A;
}

.login-hero-subtext {
  font-size: 1.05rem;
  color: #6E655F;
  line-height: 1.6;
  max-width: 520px;
  margin: 0;
  font-weight: 450;
}

/* 3.3 4 Features List (2x2 Grid) */
.login-features-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-top: 8px;
}

.login-feature-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.65);
  border: 1px solid rgba(234, 227, 214, 0.7);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.login-feature-item:hover {
  background: #FFFFFF;
  border-color: #E2D7C7;
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(126, 29, 42, 0.05);
}

.login-feat-icon-box {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 16px;
}

.feat-icon-sheets { background: #FDF2F2; color: #7E1D2A; }
.feat-icon-audio { background: #FFF4ED; color: #D96B27; }
.feat-icon-exams { background: #F2F8FD; color: #2B7A78; }
.feat-icon-schedules { background: #F6F3FB; color: #6D4C8C; }

.login-feat-icon-box svg {
  width: 18px;
  height: 18px;
}

.login-feat-text {
  display: flex;
  flex-direction: column;
}

.login-feat-title {
  font-size: 0.92rem;
  font-weight: 750;
  color: #1F1A17;
  line-height: 1.3;
}

.login-feat-desc {
  font-size: 0.78rem;
  color: #8C827A;
  margin-top: 2px;
}

/* 3.4 Desk Study Illustration */
.login-desk-illustration-wrap {
  width: 100%;
  max-width: 540px;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 
    0 12px 32px -8px rgba(126, 29, 42, 0.09),
    0 2px 6px rgba(0, 0, 0, 0.04);
  border: 1px solid #EAE3D6;
  background: #FFF;
  margin-top: 8px;
}

.login-desk-img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  object-position: bottom center;
  display: block;
}

/* 3.5 Cursive Tagline */
.login-cursive-quote {
  font-family: 'Caveat', 'Segoe Script', 'Brush Script MT', cursive, sans-serif;
  font-size: 1.45rem;
  color: #7E1D2A;
  opacity: 0.9;
  letter-spacing: 0.02em;
  margin-top: -6px;
}

/* ==========================================================================
   4. RIGHT PANE: ELEVATED WHITE LOGIN CARD
   ========================================================================== */
.kuro-login-right-pane {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.kuro-login-card {
  width: 100%;
  max-width: 480px;
  background: #FFFFFF;
  border: 1px solid #EAE3D6;
  border-radius: 28px;
  padding: 44px 38px 36px;
  box-shadow: 
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 20px 48px -12px rgba(126, 29, 42, 0.08),
    0 2px 8px rgba(0, 0, 0, 0.03);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  box-sizing: border-box;
}

/* 4.1 Mascot with Sparks */
.login-card-mascot-wrap {
  width: 92px;
  height: 92px;
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.login-card-mascot-img {
  width: 92px;
  height: auto;
  object-fit: contain;
}

/* 4.2 Card Title & Subtitle */
.login-card-title {
  font-family: Georgia, 'Playfair Display', 'IBM Plex Sans Arabic', serif;
  font-size: 1.85rem;
  font-weight: 850;
  color: #7E1D2A;
  margin: 0 0 8px 0;
  letter-spacing: -0.02em;
}

.login-card-subtitle {
  font-size: 0.95rem;
  color: #6E655F;
  margin: 0 0 20px 0;
  line-height: 1.5;
  max-width: 360px;
}

/* 4.2.1 Segmented Mode Switcher (Sign In / Register) */
.login-tabs-container {
  display: flex;
  align-items: center;
  width: 100%;
  background: #F4EFEB;
  padding: 4px;
  border-radius: 14px;
  border: 1px solid #EAE3D6;
  margin-bottom: 20px;
  box-sizing: border-box;
}

.login-tab-pill {
  flex: 1;
  padding: 9px 12px;
  font-size: 0.88rem;
  font-weight: 700;
  color: #7A7067;
  border-radius: 10px;
  border: none;
  background: transparent;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: inherit;
}

.login-tab-pill:hover {
  color: #1F1A17;
}

.login-tab-pill.active {
  background: #FFFFFF;
  color: #7E1D2A;
  box-shadow: 0 2px 8px rgba(126, 29, 42, 0.08), inset 0 1px 0 #FFF;
}

/* 4.2.2 Auth Form Container */
.login-auth-form {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 14px;
  text-align: start;
  margin-bottom: 8px;
  box-sizing: border-box;
}

.login-input-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
  width: 100%;
}

.login-input-label {
  font-size: 0.82rem;
  font-weight: 700;
  color: #3D352E;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.login-input-label-hint {
  font-size: 0.72rem;
  color: #9C9189;
  font-weight: 500;
}

.login-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
  background: #FAF7F2;
  border: 1.5px solid #E5DFD5;
  border-radius: 12px;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-sizing: border-box;
}

.login-input-wrap:focus-within {
  background: #FFFFFF;
  border-color: #7E1D2A;
  box-shadow: 0 0 0 3px rgba(126, 29, 42, 0.12);
}

.login-input-icon {
  width: 18px;
  height: 18px;
  color: #9C9189;
  margin-inline-start: 14px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.login-input-field {
  width: 100%;
  padding: 12px 14px;
  border: none;
  background: transparent;
  font-size: 0.92rem;
  font-family: inherit;
  color: #1F1A17;
  outline: none;
  box-sizing: border-box;
}

.login-input-field::placeholder {
  color: #B5ACA3;
  font-size: 0.88rem;
}

.login-pwd-toggle {
  background: none;
  border: none;
  color: #9C9189;
  cursor: pointer;
  padding: 8px 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.15s ease;
}

.login-pwd-toggle:hover {
  color: #7E1D2A;
}

.login-submit-btn {
  width: 100%;
  height: 50px;
  border-radius: 12px;
  background: #7E1D2A;
  color: #FFFFFF;
  border: none;
  font-size: 0.96rem;
  font-weight: 750;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 4px 14px rgba(126, 29, 42, 0.25);
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  font-family: inherit;
  margin-top: 4px;
}

.login-submit-btn:hover {
  background: #942534;
  transform: translateY(-1.5px);
  box-shadow: 0 6px 18px rgba(126, 29, 42, 0.32);
}

.login-submit-btn:active {
  transform: scale(0.985);
}

.login-submit-btn:disabled {
  opacity: 0.65;
  cursor: not-allowed;
  transform: none !important;
}

.login-alert-banner {
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 0.82rem;
  line-height: 1.45;
  margin-bottom: 12px;
  text-align: start;
  width: 100%;
  box-sizing: border-box;
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.login-alert-banner.error {
  background: #FEF2F2;
  border: 1px solid #FCA5A5;
  color: #B91C1C;
}

.login-alert-banner.success {
  background: #ECFDF5;
  border: 1px solid #6EE7B7;
  color: #047857;
}

.login-alert-banner.info {
  background: #F0FDF4;
  border: 1px solid #BBF7D0;
  color: #166534;
}

/* 4.3 Google Primary Button */
.login-btn-google {
  width: 100%;
  height: 54px;
  border-radius: 14px;
  background: #FFFFFF;
  border: 1px solid #E5DFD5;
  box-shadow: 
    inset 0 1px 0 rgba(255, 255, 255, 0.9),
    0 2px 6px rgba(0, 0, 0, 0.03);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  color: #1F1A17;
  font-size: 0.98rem;
  font-weight: 700;
  font-family: inherit;
  box-sizing: border-box;
}

.login-btn-google:hover {
  background: #FAF7F2;
  border-color: #D8CEBE;
  transform: translateY(-1.5px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.06);
}

.login-btn-google:active {
  transform: scale(0.985);
}

.login-btn-google-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.google-svg-logo {
  flex-shrink: 0;
}

.login-btn-chevron {
  width: 18px;
  height: 18px;
  color: #8C827A;
  transition: transform 0.2s ease;
}

.login-btn-google:hover .login-btn-chevron {
  color: #7E1D2A;
  transform: translateX(2px);
}

[dir="rtl"] .login-btn-google:hover .login-btn-chevron {
  transform: translateX(-2px);
}

/* 4.4 Divider: "────── or ──────" */
.login-card-divider {
  width: 100%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 20px 0;
}

.login-card-divider::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 1px;
  background: #EAE3D6;
}

.login-divider-text {
  position: relative;
  background: #FFFFFF;
  padding: 0 16px;
  font-size: 0.85rem;
  color: #9C9189;
  font-weight: 500;
}

/* 4.5 Guest Secondary Button */
.login-btn-guest {
  width: 100%;
  height: 54px;
  border-radius: 14px;
  background: #FBF3EF;
  border: 1px solid #EEDCD5;
  box-shadow: 0 2px 4px rgba(126, 29, 42, 0.03);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  color: #1F1A17;
  font-size: 0.98rem;
  font-weight: 700;
  font-family: inherit;
  box-sizing: border-box;
}

.login-btn-guest:hover {
  background: #F6E9E3;
  border-color: #E2C9BF;
  transform: translateY(-1.5px);
  box-shadow: 0 6px 16px rgba(126, 29, 42, 0.06);
}

.login-btn-guest:active {
  transform: scale(0.985);
}

.login-btn-guest-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.login-guest-icon-box {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: rgba(126, 29, 42, 0.1);
  color: #7E1D2A;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.login-guest-icon-box svg {
  width: 16px;
  height: 16px;
}

.login-btn-guest:hover .login-btn-chevron {
  color: #7E1D2A;
  transform: translateX(2px);
}

[dir="rtl"] .login-btn-guest:hover .login-btn-chevron {
  transform: translateX(-2px);
}

/* 4.6 Sub-caption under Guest */
.login-guest-note {
  font-size: 0.8rem;
  color: #7A7067;
  line-height: 1.45;
  margin: 12px 0 26px;
  max-width: 380px;
}

/* 4.7 3 Micro Feature Badges */
.login-card-badges-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  width: 100%;
  padding-top: 18px;
  border-top: 1px solid #F0EAE1;
  margin-bottom: 24px;
}

.login-micro-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.micro-badge-icon {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 6px;
}

.micro-icon-cap { background: #FDF2F2; color: #7E1D2A; }
.micro-icon-shield { background: #F2F8FD; color: #2B7A78; }
.micro-icon-devices { background: #FFF4ED; color: #D96B27; }

.micro-badge-icon svg {
  width: 16px;
  height: 16px;
}

.micro-badge-title {
  font-size: 0.78rem;
  font-weight: 750;
  color: #1F1A17;
  line-height: 1.25;
}

.micro-badge-desc {
  font-size: 0.68rem;
  color: #8C827A;
  margin-top: 3px;
  line-height: 1.3;
}

/* 4.8 Footer Terms & Privacy Policy */
.login-card-footer {
  width: 100%;
  padding-top: 14px;
  border-top: 1px solid #F0EAE1;
}

.login-footer-text {
  font-size: 0.76rem;
  color: #8C827A;
  margin: 0;
  line-height: 1.5;
}

.login-link {
  color: #7E1D2A;
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 600;
  transition: opacity 0.15s ease;
}

.login-link:hover {
  opacity: 0.8;
}

/* ==========================================================================
   5. BOOT LOADING SCREEN (NON-FLASHING)
   ========================================================================== */
.kf-auth-boot-loader {
  position: fixed;
  inset: 0;
  background-color: #FAF7F2;
  z-index: 999999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.kf-boot-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.kf-boot-mascot-pulse {
  width: 88px;
  height: 88px;
  border-radius: 50%;
  background: #FFF;
  border: 1px solid #EAE3D6;
  box-shadow: 0 8px 24px rgba(126, 29, 42, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: kfMascotPulse 2s infinite ease-in-out;
  margin-bottom: 16px;
}

.kf-boot-title {
  font-family: Georgia, 'Playfair Display', serif;
  font-size: 1.5rem;
  font-weight: 850;
  color: #7E1D2A;
  margin: 0 0 16px 0;
}

.kf-boot-spinner {
  width: 24px;
  height: 24px;
  border: 2.5px solid rgba(126, 29, 42, 0.15);
  border-top-color: #7E1D2A;
  border-radius: 50%;
  animation: kfSpin 0.8s linear infinite;
}

@keyframes kfMascotPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

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

/* ==========================================================================
   6. RESPONSIVE BREAKPOINTS (DESKTOP, TABLET, MOBILE)
   ========================================================================== */

/* iPad & Tablet Landscape / Portrait (768px - 1023px) */
@media (max-width: 1023px) {
  .kuro-login-split-layout {
    grid-template-columns: 1fr;
    gap: 28px;
    max-width: 560px;
  }

  .kuro-login-right-pane {
    order: -1;
  }

  .kuro-login-left-pane {
    padding-inline-end: 0;
    align-items: center;
    text-align: center;
  }

  .login-brand-header {
    justify-content: center;
  }

  .login-hero-title {
    font-size: 2.2rem;
  }

  .login-hero-subtext {
    max-width: 480px;
  }

  .login-desk-illustration-wrap {
    display: none;
  }

  .kuro-login-card {
    max-width: 100%;
    padding: 28px 24px 24px;
  }
}

/* Mobile Screens (< 768px) */
@media (max-width: 767px) {
  .kuro-login-viewport {
    padding: 24px 16px;
    align-items: flex-start;
  }

  .kuro-login-split-layout {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  /* Compact top identity on mobile */
  .kuro-login-left-pane {
    display: none; /* Hide heavy split pane on mobile, keep card 100% focused */
  }

  .kuro-login-card {
    padding: 30px 20px 24px;
    border-radius: 22px;
    box-shadow: 0 10px 28px rgba(126, 29, 42, 0.07);
  }

  .login-card-mascot-wrap {
    width: 76px;
    height: 76px;
    margin-bottom: 14px;
  }

  .login-card-mascot-img {
    width: 76px;
  }

  .login-card-title {
    font-size: 1.5rem;
  }

  .login-card-subtitle {
    font-size: 0.88rem;
    margin-bottom: 22px;
  }

  .login-btn-google,
  .login-btn-guest {
    height: 50px;
    padding: 0 16px;
    font-size: 0.92rem;
  }

  .login-card-badges-row {
    gap: 6px;
    padding-top: 14px;
    margin-bottom: 18px;
  }

  .micro-badge-title {
    font-size: 0.72rem;
  }

  .micro-badge-desc {
    font-size: 0.64rem;
  }
}


/* ==========================================================================
   STUDENT REGISTRATION WIZARD & AVATAR MODAL STYLES (media_1791551233524.jpg)
   ========================================================================== */

.kuro-register-setup-viewport {
  min-height: 100vh;
  width: 100%;
  background-color: #FAF7F2;
  background-image: 
    radial-gradient(circle at 10% 20%, rgba(126, 29, 42, 0.04) 0%, transparent 45%),
    radial-gradient(circle at 90% 80%, rgba(188, 74, 71, 0.04) 0%, transparent 50%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  box-sizing: border-box;
  font-family: 'IBM Plex Sans Arabic', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  color: #1F1A17;
}

.kuro-wizard-container {
  position: relative;
  z-index: 100;
  pointer-events: auto;
  width: 100%;
  max-width: 760px;
  background: #FFFFFF;
  border: 1px solid #EAE3D6;
  border-radius: 28px;
  box-shadow: 
    0 16px 40px rgba(126, 29, 42, 0.07),
    0 2px 8px rgba(0, 0, 0, 0.02);
  padding: 36px 40px;
  box-sizing: border-box;
}

/* Wizard Header */
.wizard-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 24px;
  border-bottom: 1px solid #F2ECE1;
  margin-bottom: 28px;
}

.wizard-brand-badge {
  display: flex;
  align-items: center;
  gap: 12px;
}

.wizard-brand-badge img {
  width: 36px;
  height: 36px;
  object-fit: contain;
}

.wizard-brand-meta {
  display: flex;
  flex-direction: column;
}

.wizard-brand-title {
  font-size: 1.15rem;
  font-weight: 850;
  color: #7E1D2A;
  line-height: 1.2;
}

.wizard-brand-tag {
  font-size: 0.78rem;
  color: #8C827A;
  font-weight: 500;
}

.wizard-step-counter {
  font-size: 0.85rem;
  color: #6E655F;
  background: #F8F4EC;
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid #E6DEC3;
}

/* Stepper Progress Bar */
.wizard-stepper-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
  position: relative;
}

.stepper-item {
  display: flex;
  align-items: center;
  gap: 10px;
  z-index: 2;
}

.stepper-circle {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #F4EFE6;
  color: #8C827A;
  border: 2px solid #EAE3D6;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  font-weight: 700;
  transition: all 0.25s ease;
}

.stepper-item.active .stepper-circle {
  background: #7E1D2A;
  color: #FFF;
  border-color: #7E1D2A;
  box-shadow: 0 0 0 4px rgba(126, 29, 42, 0.15);
}

.stepper-item.completed .stepper-circle {
  background: #2E7D32;
  color: #FFF;
  border-color: #2E7D32;
}

.stepper-label {
  font-size: 0.88rem;
  font-weight: 650;
  color: #8C827A;
}

.stepper-item.active .stepper-label,
.stepper-item.completed .stepper-label {
  color: #1F1A17;
}

.stepper-line {
  flex: 1;
  height: 3px;
  background: #EAE3D6;
  margin: 0 12px;
  border-radius: 2px;
  transition: background 0.3s ease;
}

.stepper-line.active {
  background: #7E1D2A;
}

/* Wizard Step Pane & Header */
.wizard-step-pane {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.wizard-step-header {
  margin-bottom: 6px;
}

.wizard-step-title {
  font-size: 1.55rem;
  font-weight: 850;
  color: #1F1A17;
  margin: 0 0 6px 0;
}

.wizard-step-sub {
  font-size: 0.92rem;
  color: #6E655F;
  margin: 0;
  line-height: 1.5;
}

/* Avatar Preview Section */
.wizard-avatar-section {
  display: flex;
  align-items: center;
  gap: 20px;
  background: #FAF7F2;
  border: 1px dashed #D6CBB8;
  padding: 16px 20px;
  border-radius: 18px;
}

.wizard-avatar-preview-wrap {
  position: relative;
  width: 76px;
  height: 76px;
  flex-shrink: 0;
}

.wizard-avatar-preview-wrap img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid #FFF;
  box-shadow: 0 4px 12px rgba(126, 29, 42, 0.12);
  background: #FFF;
}

.wizard-avatar-edit-badge {
  position: absolute;
  bottom: 0;
  inset-inline-end: 0;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #7E1D2A;
  color: #FFF;
  border: 2px solid #FFF;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
  transition: transform 0.2s ease;
}

.wizard-avatar-edit-badge:hover {
  transform: scale(1.1);
}

.wizard-avatar-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.avatar-title-text {
  font-size: 0.95rem;
  font-weight: 750;
  color: #1F1A17;
}

.avatar-desc-text {
  font-size: 0.8rem;
  color: #8C827A;
}

.wizard-avatar-picker-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  color: #7E1D2A;
  font-size: 0.82rem;
  font-weight: 750;
  cursor: pointer;
  padding: 4px 0;
}

/* Form Inputs Grid */
.wizard-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.wizard-field-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.wizard-field-group.full-width {
  grid-column: span 2;
}

.wizard-label {
  font-size: 0.88rem;
  font-weight: 700;
  color: #332B25;
  display: flex;
  align-items: center;
  gap: 4px;
}

.wizard-req {
  color: #D32F2F;
}

.wizard-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.wizard-input-icon {
  position: absolute;
  inset-inline-start: 14px;
  width: 18px;
  height: 18px;
  color: #8C827A;
  pointer-events: none;
}

.wizard-input {
  width: 100%;
  height: 48px;
  padding-inline-start: 44px;
  padding-inline-end: 16px;
  border-radius: 12px;
  border: 1px solid #D6CBB8;
  background: #FFF;
  font-size: 0.95rem;
  color: #1F1A17;
  transition: all 0.2s ease;
}

.wizard-input:focus {
  outline: none;
  border-color: #7E1D2A;
  box-shadow: 0 0 0 3px rgba(126, 29, 42, 0.12);
}

.wizard-input-wrap.readonly .wizard-input {
  background: #F8F4EC;
  border-color: #E6DEC3;
  color: #6E655F;
  cursor: not-allowed;
}

.wizard-verified-badge {
  position: absolute;
  inset-inline-end: 12px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.75rem;
  font-weight: 700;
  color: #2E7D32;
  background: #E8F5E9;
  padding: 3px 8px;
  border-radius: 10px;
}

/* Gender Selection Cards */
.wizard-gender-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.wizard-gender-card {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-radius: 16px;
  border: 1.5px solid #E0D6C5;
  background: #FFF;
  cursor: pointer;
  transition: all 0.2s ease;
}

.wizard-gender-card:hover {
  border-color: #7E1D2A;
  background: #FAF5EF;
}

.wizard-gender-card.selected {
  border-color: #7E1D2A;
  background: rgba(126, 29, 42, 0.05);
  box-shadow: 0 4px 12px rgba(126, 29, 42, 0.08);
}

.gender-card-content {
  display: flex;
  align-items: center;
  gap: 12px;
}

.gender-icon-box {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #F4EFE6;
  color: #7E1D2A;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gender-icon-box.female {
  background: #FCE4EC;
  color: #C2185B;
}

.gender-title {
  font-size: 0.95rem;
  font-weight: 750;
  color: #1F1A17;
}

.gender-check-mark {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 1.5px solid #D6CBB8;
  display: flex;
  align-items: center;
  justify-content: center;
  color: transparent;
  transition: all 0.2s ease;
}

.wizard-gender-card.selected .gender-check-mark {
  background: #7E1D2A;
  border-color: #7E1D2A;
  color: #FFF;
}

/* Academic Context Banner (Step 2) */
.academic-context-box {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 14px;
  background: #FAF7F2;
  border: 1px solid #EAE3D6;
  padding: 16px 20px;
  border-radius: 16px;
}

.context-item {
  display: flex;
  align-items: center;
  gap: 10px;
}

.context-item i {
  color: #7E1D2A;
  width: 20px;
  height: 20px;
}

.context-label {
  display: block;
  font-size: 0.75rem;
  color: #8C827A;
}

.context-val {
  display: block;
  font-size: 0.88rem;
  font-weight: 750;
  color: #1F1A17;
}

/* Groups Cards Grid */
.wizard-groups-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  max-height: 350px;
  overflow-y: auto;
  padding-inline-end: 4px;
}

.wizard-group-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px;
  border-radius: 16px;
  border: 1.5px solid #E0D6C5;
  background: #FFF;
  cursor: pointer;
  transition: all 0.2s ease;
}

.wizard-group-card:hover {
  border-color: #7E1D2A;
  transform: translateY(-2px);
}

.wizard-group-card.selected {
  border-color: #7E1D2A;
  background: rgba(126, 29, 42, 0.05);
  box-shadow: 0 4px 14px rgba(126, 29, 42, 0.1);
}

.group-card-badge {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: #7E1D2A;
  color: #FFF;
  font-size: 1.2rem;
  font-weight: 850;
  display: flex;
  align-items: center;
  justify-content: center;
}

.group-card-details {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding-inline-start: 14px;
}

.group-card-title {
  font-size: 1rem;
  font-weight: 800;
  color: #1F1A17;
}

.group-card-sub {
  font-size: 0.78rem;
  color: #8C827A;
}

.group-card-check {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 1.5px solid #D6CBB8;
  display: flex;
  align-items: center;
  justify-content: center;
  color: transparent;
}

.wizard-group-card.selected .group-card-check {
  background: #7E1D2A;
  border-color: #7E1D2A;
  color: #FFF;
}

/* Review Cards (Step 3) */
.wizard-review-card {
  border: 1px solid #EAE3D6;
  border-radius: 18px;
  background: #FFF;
  overflow: hidden;
}

.review-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  background: #FAF7F2;
  border-bottom: 1px solid #F0EAE1;
}

.review-card-title-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #7E1D2A;
}

.review-card-title-wrap h3 {
  font-size: 0.95rem;
  font-weight: 800;
  margin: 0;
  color: #1F1A17;
}

.review-edit-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #FFF;
  border: 1px solid #D6CBB8;
  padding: 4px 10px;
  border-radius: 8px;
  font-size: 0.78rem;
  font-weight: 700;
  color: #7E1D2A;
  cursor: pointer;
}

.review-card-body {
  padding: 18px 20px;
}

.review-avatar-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
  padding-bottom: 14px;
  border-bottom: 1px dashed #EAE3D6;
}

.review-avatar-img {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #7E1D2A;
}

.review-user-name {
  display: block;
  font-size: 1.05rem;
  font-weight: 800;
  color: #1F1A17;
}

.review-user-email {
  display: block;
  font-size: 0.82rem;
  color: #8C827A;
}

.review-details-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.review-lbl {
  font-size: 0.8rem;
  color: #8C827A;
}

.review-val {
  font-size: 0.88rem;
  font-weight: 700;
  color: #1F1A17;
  margin-inline-start: 4px;
}

.group-pill {
  background: #7E1D2A;
  color: #FFF;
  padding: 2px 10px;
  border-radius: 10px;
  font-size: 0.82rem;
}

.wizard-confirm-row {
  background: #FFFDF9;
  border: 1px solid #FFE6C5;
  padding: 14px 18px;
  border-radius: 14px;
}

.wizard-checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
}

.wizard-checkbox-label input[type="checkbox"] {
  display: none;
}

.custom-checkbox {
  width: 20px;
  height: 20px;
  border-radius: 6px;
  border: 1.5px solid #D6CBB8;
  display: flex;
  align-items: center;
  justify-content: center;
  color: transparent;
  flex-shrink: 0;
  margin-top: 2px;
}

.wizard-checkbox-label input[type="checkbox"]:checked + .custom-checkbox {
  background: #7E1D2A;
  border-color: #7E1D2A;
  color: #FFF;
}

.confirm-text {
  font-size: 0.88rem;
  color: #4A3E34;
  line-height: 1.4;
  font-weight: 600;
}

/* Action Buttons Footer Row */
.wizard-actions-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 12px;
  padding-top: 20px;
  border-top: 1px solid #F2ECE1;
}

.wizard-actions-row.single-right {
  justify-content: flex-end;
}

.wizard-actions-row.center {
  justify-content: center;
}

.wizard-btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 48px;
  padding: 0 24px;
  border-radius: 14px;
  background: #7E1D2A;
  color: #FFF;
  font-size: 0.95rem;
  font-weight: 750;
  border: none;
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(126, 29, 42, 0.2);
  transition: all 0.2s ease;
}

.wizard-btn-primary:hover {
  background: #681722;
  transform: translateY(-1px);
}

.wizard-btn-primary.submit-final {
  background: #2E7D32;
  box-shadow: 0 4px 14px rgba(46, 125, 50, 0.25);
}

.wizard-btn-primary.submit-final:hover {
  background: #236327;
}

.wizard-btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 48px;
  padding: 0 20px;
  border-radius: 14px;
  background: #FAF7F2;
  color: #6E655F;
  border: 1px solid #E0D6C5;
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.wizard-btn-secondary:hover {
  background: #F4EFE6;
  color: #1F1A17;
}

/* Saving & Checklist Animation (Step 4 & 5) */
.saving-mascot-wrap,
.success-mascot-wrap {
  width: 100px;
  height: 100px;
  margin: 0 auto 16px;
}

.saving-mascot-img,
.success-mascot-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.saving-title,
.success-title {
  font-size: 1.6rem;
  font-weight: 850;
  color: #1F1A17;
  margin: 0 0 6px 0;
}

.saving-sub,
.success-sub {
  font-size: 0.92rem;
  color: #6E655F;
  margin: 0 0 24px 0;
}

.wizard-progress-bar-wrap {
  width: 100%;
  height: 8px;
  background: #F4EFE6;
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 24px;
}

.wizard-progress-bar-fill {
  height: 100%;
  background: #7E1D2A;
  border-radius: 4px;
  transition: width 0.4s ease;
}

.saving-checklist {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 440px;
  margin: 0 auto;
  text-align: start;
}

.checklist-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
  color: #8C827A;
}

.checklist-item.active {
  color: #1F1A17;
  font-weight: 700;
}

.checklist-item.done {
  color: #2E7D32;
  font-weight: 700;
}

.spin-icon {
  animation: spin 1s linear infinite;
  color: #7E1D2A;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.success-badges-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.success-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 20px;
  background: #F4EFE6;
  color: #6E655F;
  font-size: 0.82rem;
  font-weight: 700;
}

.success-chip.highlight {
  background: #7E1D2A;
  color: #FFF;
}

/* ==========================================================================
   AVATAR MODAL OVERLAY STYLES
   ========================================================================== */

.kuro-avatar-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  background: rgba(15, 12, 10, 0.65);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.kuro-avatar-modal-overlay.active {
  opacity: 1;
}

.kuro-avatar-modal-card {
  width: 100%;
  max-width: 580px;
  background: #FFF;
  border-radius: 24px;
  border: 1px solid #EAE3D6;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
  padding: 24px 28px;
  box-sizing: border-box;
}

.avatar-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.avatar-modal-header-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.avatar-modal-header-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(126, 29, 42, 0.08);
  color: #7E1D2A;
  display: flex;
  align-items: center;
  justify-content: center;
}

.avatar-modal-title {
  font-size: 1.25rem;
  font-weight: 850;
  color: #1F1A17;
  margin: 0;
}

.avatar-modal-sub {
  font-size: 0.8rem;
  color: #8C827A;
  margin: 2px 0 0 0;
}

.avatar-modal-close-btn {
  background: none;
  border: none;
  color: #8C827A;
  cursor: pointer;
  padding: 6px;
  border-radius: 50%;
}

.avatar-modal-tabs {
  display: flex;
  gap: 8px;
  background: #F8F4EC;
  padding: 4px;
  border-radius: 14px;
  margin-bottom: 20px;
}

.avatar-modal-tab {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 38px;
  border-radius: 10px;
  border: none;
  background: transparent;
  color: #8C827A;
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
}

.avatar-modal-tab.active {
  background: #FFF;
  color: #7E1D2A;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.avatar-presets-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
  max-height: 300px;
  overflow-y: auto;
  padding-inline-end: 4px;
}

.avatar-preset-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  background: #FAF7F2;
  border: 1.5px solid #EAE3D6;
  border-radius: 14px;
  padding: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.avatar-preset-card:hover {
  border-color: #7E1D2A;
  transform: translateY(-2px);
}

.avatar-preset-card.selected {
  border-color: #7E1D2A;
  background: rgba(126, 29, 42, 0.06);
  box-shadow: 0 4px 10px rgba(126, 29, 42, 0.12);
}

.preset-avatar-img-wrap {
  position: relative;
  width: 52px;
  height: 52px;
}

.preset-avatar-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.preset-avatar-badge-check {
  position: absolute;
  top: -4px;
  inset-inline-end: -4px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #7E1D2A;
  color: #FFF;
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 10px;
}

.avatar-preset-card.selected .preset-avatar-badge-check {
  display: flex;
}

.preset-avatar-name {
  font-size: 0.72rem;
  font-weight: 700;
  color: #332B25;
  text-align: center;
}

.avatar-upload-zone {
  border: 2px dashed #D6CBB8;
  border-radius: 18px;
  padding: 30px 20px;
  text-align: center;
  background: #FAF7F2;
  cursor: pointer;
}

.upload-zone-preview {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  margin: 0 auto 14px;
  overflow: hidden;
  border: 3px solid #FFF;
  box-shadow: 0 4px 14px rgba(0,0,0,0.1);
}

.upload-zone-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.upload-icon-main {
  width: 32px;
  height: 32px;
  color: #7E1D2A;
  margin-bottom: 8px;
}

.upload-zone-title {
  font-size: 0.95rem;
  font-weight: 750;
  color: #1F1A17;
  margin: 0 0 4px 0;
}

.upload-zone-desc {
  font-size: 0.78rem;
  color: #8C827A;
  margin: 0 0 14px 0;
}

.avatar-browse-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 10px;
  background: #7E1D2A;
  color: #FFF;
  font-size: 0.82rem;
  font-weight: 750;
  border: none;
  cursor: pointer;
}

.avatar-modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid #F0EAE1;
}

.avatar-btn-cancel {
  padding: 8px 16px;
  border-radius: 10px;
  background: #FAF7F2;
  color: #6E655F;
  border: 1px solid #E0D6C5;
  font-size: 0.85rem;
  font-weight: 700;
  cursor: pointer;
}

.avatar-btn-save {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 20px;
  border-radius: 10px;
  background: #7E1D2A;
  color: #FFF;
  font-size: 0.85rem;
  font-weight: 750;
  border: none;
  cursor: pointer;
}



/* Absolute header and layout override for full-page auth/wizard views */
body.login-view-active #site-header,
body.login-view-active .site-header,
body.login-view-active #app-sidebar,
body.login-view-active #sidebar-backdrop,
body.login-view-active .mobile-bottom-nav,
body.login-view-active #guest-encourage-banner {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
  pointer-events: none !important;
  height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: hidden !important;
}
