/* ─── MCC-MRF ULTRA-PREMIUM SPLIT LAYOUT FORM CSS ─── */
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;500;700&display=swap');

:root {
  --mcc-maroon: #78091E;
  --mcc-red: #c0392b;
  --bg-main: #fcfcfd;
  --sidebar-bg: #78091E;
  --sidebar-text: #ffffff;
  --text-primary: #111827;
  --text-secondary: #4b5563;
  --border-premium: #e5e7eb;
  --accent-gold: #c5a059;
  --shadow-premium: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}


body,
html {
  margin: 0;
  padding: 0;
  height: 100%;
  font-family: 'Roboto', sans-serif;
  background-color: var(--bg-main);
  color: var(--text-primary);
  overflow: hidden;
  /* Main container handles scroll */
}

h1,
h2,
h3,
h4,
.sidebar-brand-name,
.step-title,
.nav-label {
  font-family: "Times New Roman", Sans-serif;
  font-weight: 700;
}


/* Layout Wrapper */
.premium-wrapper {
  display: flex;
  height: 100vh;
  width: 100vw;
  overflow: hidden;
  /* Prevent body scroll, container handles it */
}

.main-container {
  display: flex;
  width: 100%;
  height: 100%;
}

.sidebar-nav {
  width: 350px;
  background: var(--sidebar-bg);
  color: #fff;
  flex-shrink: 0;
  padding: 40px 40px;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  border-right: none;
}


.sidebar-content {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.brand-logo {
  width: 100%;
}

.sidebar-brand-name {
  font-size: 26px;
  font-weight: 800;
  margin: 0;
  letter-spacing: -0.01em;
  color: #fff;
  line-height: 1.2;
}

.sidebar-tagline {
  font-size: 11px;
  color: rgba(255, 255, 255, 0.7);
  text-transform: uppercase;
  letter-spacing: 0.2em;
  margin: 0;
  margin-top: 5px;

}

/* Step Navigation Styles - Crystal Clear Contrast */
.step-navigation {
  margin-top: 30px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 35px;
  transition: all 0.2s ease;
  position: relative;
  cursor: pointer;
  opacity: 0.4;
  z-index: 1;
}

.nav-item::after {
  content: '';
  position: absolute;
  left: 22px;
  /* Center of 44px circle */
  top: 44px;
  bottom: -35px;
  /* Matches margin-bottom */
  width: 2px;
  background: rgba(255, 255, 255, 0.1);
  z-index: -1;
}

.nav-item:last-child::after {
  display: none;
}


.nav-item.active {
  opacity: 1;
}

.nav-num {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid rgba(255, 255, 255, 0.15);
  border-radius: 50%;
  font-size: 16px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.3);
  background: transparent;
  transition: all 0.3s ease;
}

.nav-item.active .nav-num,
.nav-item.completed .nav-num {
  border-color: #fff;
  color: var(--mcc-maroon);
  background-color: #fff;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

.nav-label {
  display: block;
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0;
  line-height: 1.2;
}

.nav-desc {
  display: block;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.5);
  font-weight: 500;
  margin-top: 2px;

}

.nav-item.active .nav-label {
  color: #fff;
}



/* Content Area */
.content-area {
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  background: #fcfcfd;
  /* Match exactly the gray-white background */
  position: relative;
}

.content-header {

  background: white;
  z-index: 10;
}

.content-header {

  background: transparent;
  /* Makes it airy */
  z-index: 10;
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: 0 40px;
}

.form-container-scroll {
  flex-grow: 1;
  overflow-y: auto;
  padding: 0px 0;
}

.form-content-wrapper {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 50px;
}

/* Progress Bar */
.progress-container {
  display: flex;
  align-items: center;
  gap: 15px;
}

.progress-bar-wrap {
  width: 120px;
  height: 6px;
  background: #f3f4f6;
  border-radius: 3px;
  overflow: hidden;
}

.progress-bar-fill {
  height: 100%;
  width: 25%;
  background: #10b981;
  transition: width 0.4s ease;
}

.progress-text {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
}

/* Form Steps */
.form-step {
  animation: slideUp 0.5s ease forwards;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.step-title {
  font-size: 34px;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 10px;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.banner-premium {
  border-left: 4px solid var(--mcc-maroon);
  padding: 5px 25px;
  margin-bottom: 50px;
  background: transparent;
}

.step-subtitle {
  font-size: 14px;
  color: var(--text-secondary);
  font-weight: 400;
  line-height: 1.5;
  margin-bottom: 0;
}

/* Premium Fields */
.premium-field label {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
  display: block;
}

.premium-input {
  border: 1.5px solid var(--border-premium);
  background-color: white;
  padding: 14px 18px;
  border-radius: 12px;
  font-size: 15px;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
}

.premium-input:hover {
  border-color: #cbd5e1;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.04);
}

.premium-input:focus {
  border-color: var(--mcc-maroon);
  box-shadow: 0 0 0 4px rgba(117, 20, 33, 0.08), 0 4px 12px rgba(117, 20, 33, 0.05);
  outline: none;
}

.required-star {
  color: var(--mcc-red);
}

.hint-text-premium {
  font-size: 12px;
  color: var(--text-secondary);
  font-weight: 400;
  margin-left: 5px;
}

/* Custom Checkbox Cards */
.premium-check-card {
  position: relative;
}

.premium-check-card input {
  position: absolute;
  opacity: 0;
}

.premium-check-card label {
  display: block;
  padding: 16px;
  background: white;
  border: 1.5px solid var(--border-premium);
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
  margin: 0;
}

.premium-check-card input:checked+label {
  background: #fdf2f4;
  border-color: var(--mcc-maroon);
  color: var(--mcc-maroon);
}

.premium-check-card label span {
  font-size: 13px;
  font-weight: 600;
}

/* File Upload Zone */
.file-premium-zone {
  position: relative;
}

.icon-circle {
  width: 48px;
  height: 48px;
  background: white;
  border: 1px solid var(--border-premium);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 20px;
}

/* Navigation Buttons */
.btn-premium-maroon {
  background: var(--mcc-maroon);
  color: white;
  font-weight: 600;
  padding: 14px 32px;
  border-radius: 12px;
  border: none;
  transition: all 0.3s;
}

.btn-premium-maroon:hover:not(:disabled) {
  background: #8b1c2a;
  box-shadow: 0 10px 15px -3px rgba(117, 20, 33, 0.2);
  transform: translateY(-2px);
  color: white;
}

.btn-premium-secondary {
  color: var(--text-primary);
  font-weight: 600;
  padding: 14px 32px;
  border: 1px solid var(--border-premium);
  border-radius: 12px;
  background: white;
}

.btn-premium-secondary:hover {
  background: #f9fafb;
}

/* Error Messages */
.error-msg {
  font-size: 12px;
  color: var(--mcc-red);
  margin-top: 6px;
  font-weight: 500;
  min-height: 18px;
}

.premium-input.error {
  border-color: var(--mcc-red);
  background-color: #fffafb;
}

/* Modal */
.premium-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(8px);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
}

.premium-modal-overlay.active {
  display: flex;
}

.premium-modal {
  max-width: 500px;
  width: 90%;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Photo Upload Styling */
.photo-upload-container {
  width: 155px;
  height: 185px;
  border: 2px dashed #e2e8f0;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  background: white;
  transition: all 0.3s ease;
  overflow: hidden;
}

.photo-upload-container:hover {
  border-color: var(--mcc-maroon);
  background: #fffafa;
}

.photo-upload-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.success-lottie span {
  font-size: 64px;
}

/* ─── Physical Form Header Elements ─── */
.school-main-title {
  color: var(--mcc-maroon);
  font-weight: 800;
  letter-spacing: -0.01em;
  font-size: 1.6rem;
}

.school-address,
.school-contact {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
}

.office-use-box {
  background: #f8f9fa;
  color: #6c757d;
  font-weight: 600;
  border-radius: 4px;
}

/* ─── Static Photo Upload ─── */
.photo-container-wrap {
  background: white;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
}

.photo-container-wrap:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
  border-color: var(--mcc-maroon) !important;
}

.photo-box {
  width: 110px;
  height: 140px;
  margin: 0 auto;
  overflow: hidden;
  border-radius: 4px;
  background: #fdfdfd;
}

.photo-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 0.3s;
}

/* Mobile-only form title in sidebar — hidden on desktop */
.mobile-form-title {
  display: none;
}

.cursor-pointer {
  cursor: pointer;
}

/* ─── Responsive Optimizations ─── */

@media (max-width: 1024px) {
  .sidebar-nav {
    width: 280px;
    padding: 30px;
  }
}

/* ── Tablet & Mobile (≤768px) ── */
@media (max-width: 768px) {

  body,
  html {
    overflow: auto;
  }

  .premium-wrapper {
    flex-direction: column;
    height: auto;
    min-height: 100vh;
    width: 100%;
    overflow: visible;
  }

  .main-container {
    flex-direction: column;
    height: auto;
    overflow: visible;
  }

  /* ── Sidebar becomes a STICKY top bar on mobile ── */
  .sidebar-nav {
    width: 100%;
    height: auto;
    padding: 14px 20px 12px;
    border-right: none;
    border-bottom: 3px solid rgba(255, 255, 255, 0.15);
    overflow: visible;
    position: sticky;
    top: 0;
    z-index: 200;
  }

  .sidebar-content {
    height: auto;
  }

  /* Logo: 200px centered on mobile */
  .brand-section {
    margin-bottom: 0px !important;
  }

  .brand-section>div {
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 0 !important;
  }

  .brand-logo {
    width: 60%;
    height: auto;
    flex-shrink: 0;
    filter: brightness(1);
    display: block;
    margin: 0 auto;
  }

  /* Show mobile form title below logo */
  .mobile-form-title {
    display: block;
    text-align: center;
    margin: 10px 0 14px;
    padding: 0 10px;
  }

  .mobile-form-title-text {
    font-family: "Times New Roman", serif;
    font-size: 1rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.92);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin: 0;
    line-height: 1.4;

    padding: 8px 0;
  }

  /* Hide sidebar footer copyright on mobile */
  .sidebar-footer {
    display: none !important;
  }

  /* ── Step Navigation Pills ── */
  .step-navigation {
    display: flex;
    flex-direction: row;
    gap: 8px;
    margin-top: 0;
    overflow-x: auto;
    padding-bottom: 4px;
    scrollbar-width: none;
    -ms-overflow-style: none;
    display: none;
  }

  .step-navigation::-webkit-scrollbar {
    display: none;
  }

  /* Remove the vertical connector line on mobile */
  .nav-item::after {
    display: none;
  }

  .nav-item {
    flex-shrink: 0;
    flex-direction: row;
    align-items: center;
    gap: 8px;
    margin-bottom: 0;
    padding: 7px 14px;
    background: rgba(255, 255, 255, 0.1);
    border: 1.5px solid rgba(255, 255, 255, 0.2);
    border-radius: 50px;
    opacity: 0.6;
    cursor: pointer;
  }

  .nav-item.active {
    background: #fff;
    border-color: #fff;
    opacity: 1;
  }

  .nav-item.completed {
    background: rgba(255, 255, 255, 0.18);
    border-color: rgba(255, 255, 255, 0.4);
    opacity: 0.85;
  }

  .nav-num {
    width: 22px;
    height: 22px;
    font-size: 11px;
    font-weight: 700;
    border: none;
    background: transparent;
    color: rgba(255, 255, 255, 0.7);
    flex-shrink: 0;
  }

  .nav-item.active .nav-num {
    width: 22px;
    height: 22px;
    background: var(--mcc-maroon) !important;
    color: #fff !important;
    border-radius: 50%;
    box-shadow: none;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .nav-item.completed .nav-num {
    color: rgba(255, 255, 255, 0.9);
  }

  .nav-label {
    font-size: 12px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.8);
    white-space: nowrap;
  }

  .nav-item.active .nav-label {
    color: var(--mcc-maroon) !important;
  }

  .nav-desc {
    display: none;
  }

  /* ── Content Area ── */
  .content-area {
    min-height: 0;
    overflow: visible;
    height: auto;
  }

  .form-container-scroll {
    overflow-y: visible;
    height: auto;
  }

  /* Hide form title from content-header on mobile (shown below logo instead) */
  .form-title-group {
    display: none !important;
  }

  /* ── Content Header: sticky below the sidebar ── */
  .content-header {
    height: auto;
    padding: 10px 16px;
    flex-direction: row;
    align-items: center;
    justify-content: end !important;
    gap: 8px;
    background: #fff;
    border-bottom: 1px solid #f1f5f9;
    position: sticky;
    top: var(--mobile-sidebar-height, 0px);
    z-index: 100;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  }

  .form-title-group h1 {
    font-size: 1rem !important;
    line-height: 1.3;
  }

  .form-title-group p {
    font-size: 0.8rem !important;
  }

  .progress-container {
    width: auto;
    justify-content: flex-end;
  }

  .progress-bar-wrap {
    width: 100px;
  }

  /* Center passport photo upload on mobile */
  .photo-box-centered {
    margin: 0 auto !important;
  }

  .col-12.mb-3.mt-1.px-3 .d-flex {
    flex-direction: column;
    align-items: center;
  }

  #step1NameContainer {
    flex: unset !important;
    width: 100% !important;
    padding-right: 0 !important;
    order: 2;
  }

  .text-start.text-md-end {
    order: 1;
    text-align: center !important;
    width: 100%;
    margin-bottom: 16px;
  }

  .form-content-wrapper {
    padding: 16px;
    margin-top: 0;
  }

  .step-title {
    font-size: 22px;
    text-align: left;
  }

  .step-subtitle {
    text-align: left;
  }

  .banner-premium {
    margin-bottom: 20px;
    padding: 12px 16px;
  }

  /* Passport photo + name block: stack vertically */
  #step1NameContainer {
    flex: unset !important;
    width: 100% !important;
    padding-right: 0 !important;
  }

  /* ── Navigation Footer Buttons ── */
  .navigation-bar-premium {
    flex-direction: column !important;
    gap: 10px;
    padding: 16px !important;
    /* position: sticky;
    bottom: 0; */
    background: white;
    z-index: 100;
    box-shadow: 0 -6px 20px rgba(0, 0, 0, 0.07);
    border-top: 1px solid #f1f5f9;
  }

  .navigation-bar-premium .ms-auto {
    margin-left: 0 !important;
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 10px !important;
  }

  #prevBtn {
    width: 100% !important;
  }

  #prevBtn.d-none {
    display: none !important;
  }

  .btn-premium-maroon,
  .btn-premium-secondary {
    width: 100%;
    padding: 15px !important;
    font-size: 15px;
    justify-content: center;
    align-items: center;
    border-radius: 12px;
  }

  #clearBtn {
    width: 100%;
    text-align: center;
    padding: 10px;
    font-size: 14px;
    color: #94a3b8 !important;
  }
}

/* ── Small Mobile (≤480px) ── */
@media (max-width: 480px) {
  .sidebar-nav {
    padding: 12px 16px 10px;
  }

  .brand-logo {
    width: 60%;
  }

  .nav-item {
    padding: 6px 10px;
    gap: 6px;
  }

  .nav-label {
    font-size: 11px;
  }

  .form-content-wrapper {
    padding: 12px;
  }

  .step-title {
    font-size: 20px;
  }
}