/* ============================================================
   Student Registration Portal — Student Panel Stylesheet
   Blue Chip Education Consultants
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

:root {
  --navy:         #0C1A2E;
  --navy-light:   #122238;
  --navy-mid:     #1E3A5F;
  --blue:         #0EA5E9;
  --blue-light:   #38BDF8;
  --blue-dark:    #0284C7;
  --white:        #FFFFFF;
  --gray-50:      #F8FAFC;
  --gray-100:     #F1F5F9;
  --gray-200:     #E2E8F0;
  --gray-300:     #CBD5E1;
  --gray-400:     #94A3B8;
  --gray-500:     #64748B;
  --gray-600:     #475569;
  --gray-700:     #334155;
  --gray-800:     #1E293B;
  --success:      #10B981;
  --success-light:#D1FAE5;
  --warning:      #F59E0B;
  --warning-light:#FEF3C7;
  --danger:       #EF4444;
  --danger-light: #FEE2E2;
  --orange:       #F97316;
  --purple:       #8B5CF6;
  --shadow-sm:    0 1px 3px rgba(0,0,0,.08);
  --shadow-md:    0 4px 20px rgba(0,0,0,.1);
  --shadow-lg:    0 10px 40px rgba(0,0,0,.15);
  --radius-sm:    8px;
  --radius-md:    12px;
  --radius-lg:    20px;
  --transition:   all .3s cubic-bezier(.4,0,.2,1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--gray-50); color: var(--gray-800);
  line-height: 1.6; min-height: 100vh;
}
img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }

/* ── Scrollbar ─────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--gray-100); }
::-webkit-scrollbar-thumb { background: var(--blue); border-radius: 3px; }

/* ── Auth Pages (Login / Register) ─────────────────────────── */
.auth-body {
  background: linear-gradient(135deg, var(--navy) 0%, #0f2744 60%, #0a1d35 100%);
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  padding: 1.5rem; position: relative; overflow: hidden;
}
.auth-body::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse 70% 60% at 30% 30%, rgba(14,165,233,.15) 0%, transparent 60%);
}
.auth-body::after {
  content: ''; position: absolute; bottom: -20%; right: -10%;
  width: 500px; height: 500px; border-radius: 50%;
  background: radial-gradient(circle, rgba(14,165,233,.08) 0%, transparent 70%);
}
.auth-card {
  background: var(--white); border-radius: var(--radius-lg); padding: 2.75rem 2.25rem;
  width: 100%; max-width: 460px; box-shadow: 0 32px 80px rgba(0,0,0,.5);
  position: relative; z-index: 2;
  animation: authFadeIn .6s ease;
}
@keyframes authFadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}
.auth-logo { text-align: center; margin-bottom: 1.75rem; }
.auth-logo img { height: 56px; margin: 0 auto .75rem; background: #fff; padding: 6px 10px; border-radius: 8px; }
.auth-logo h2 { font-size: 1.25rem; color: var(--navy); margin-bottom: .2rem; }
.auth-logo p  { font-size: .82rem; color: var(--gray-400); }
.auth-divider { text-align: center; margin: 1.5rem 0; color: var(--gray-400); font-size: .82rem; }
.auth-footer  { text-align: center; margin-top: 1.25rem; font-size: .85rem; color: var(--gray-400); }
.auth-footer a { color: var(--blue); font-weight: 600; }
.auth-footer a:hover { text-decoration: underline; }

/* ── Navbar ────────────────────────────────────────────────── */
.portal-navbar {
  background: var(--navy); padding: 0; position: sticky; top: 0; z-index: 1000;
  box-shadow: 0 2px 12px rgba(0,0,0,.2);
}
.portal-navbar .navbar-brand { color: var(--white); font-weight: 700; font-size: 1.05rem; display: flex; align-items: center; gap: .6rem; }
.portal-navbar .navbar-brand img { height: 36px; border-radius: 6px; }
.portal-navbar .nav-link { color: rgba(255,255,255,.7); font-weight: 500; font-size: .9rem; padding: .5rem 1rem !important; border-radius: var(--radius-sm); transition: var(--transition); }
.portal-navbar .nav-link:hover { color: var(--white); background: rgba(255,255,255,.08); }
.portal-navbar .nav-link.active { color: var(--white); background: var(--blue); }
.portal-navbar .navbar-toggler { border-color: rgba(255,255,255,.2); }
.portal-navbar .navbar-toggler-icon { filter: invert(1); }
.nav-user-info { display: flex; align-items: center; gap: .6rem; color: var(--white); padding: .4rem .8rem; }
.nav-user-avatar {
  width: 34px; height: 34px; border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--blue-light));
  display: grid; place-items: center; font-weight: 700; font-size: .85rem; flex-shrink: 0;
}
.nav-user-name { font-size: .85rem; font-weight: 600; }
.nav-user-email { font-size: .72rem; color: rgba(255,255,255,.5); }

/* ── Dashboard ─────────────────────────────────────────────── */
.dash-welcome {
  background: linear-gradient(135deg, var(--navy), var(--navy-mid));
  border-radius: var(--radius-lg); padding: 2rem 2.5rem; color: var(--white);
  position: relative; overflow: hidden; margin-bottom: 2rem;
}
.dash-welcome::after {
  content: ''; position: absolute; right: -40px; bottom: -40px;
  width: 200px; height: 200px; border-radius: 50%;
  background: radial-gradient(circle, rgba(14,165,233,.2), transparent 70%);
}
.dash-welcome h2 { font-size: 1.5rem; font-weight: 700; margin-bottom: .3rem; }
.dash-welcome p { color: rgba(255,255,255,.65); font-size: .9rem; }

.stat-card {
  background: var(--white); border-radius: var(--radius-md); padding: 1.5rem;
  border: 1px solid var(--gray-200); box-shadow: var(--shadow-sm);
  display: flex; align-items: center; gap: 1rem;
  transition: var(--transition);
}
.stat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.stat-icon {
  width: 52px; height: 52px; border-radius: var(--radius-sm);
  display: grid; place-items: center; font-size: 1.3rem; flex-shrink: 0;
}
.stat-icon.blue   { background: #EFF6FF; color: var(--blue); }
.stat-icon.green  { background: #D1FAE5; color: var(--success); }
.stat-icon.yellow { background: #FEF3C7; color: var(--warning); }
.stat-icon.purple { background: #EDE9FE; color: var(--purple); }
.stat-value { font-size: 1.6rem; font-weight: 800; color: var(--navy); line-height: 1; }
.stat-label { font-size: .78rem; color: var(--gray-400); margin-top: .15rem; }

/* ── Status Timeline ───────────────────────────────────────── */
.status-timeline { display: flex; align-items: center; gap: 0; margin: 1.5rem 0; flex-wrap: wrap; }
.status-step {
  display: flex; flex-direction: column; align-items: center; flex: 1; min-width: 80px;
  position: relative; text-align: center;
}
.status-step::after {
  content: ''; position: absolute; top: 18px; left: 50%; width: 100%; height: 3px;
  background: var(--gray-200); z-index: 0;
}
.status-step:last-child::after { display: none; }
.status-step.completed::after { background: var(--success); }
.status-step.active::after { background: linear-gradient(90deg, var(--blue), var(--gray-200)); }
.status-dot {
  width: 36px; height: 36px; border-radius: 50%; border: 3px solid var(--gray-200);
  background: var(--white); display: grid; place-items: center; font-size: .8rem;
  z-index: 1; position: relative; transition: var(--transition);
}
.status-step.completed .status-dot { border-color: var(--success); background: var(--success); color: var(--white); }
.status-step.active .status-dot { border-color: var(--blue); background: var(--blue); color: var(--white); animation: pulse 2s infinite; }
@keyframes pulse { 0%,100% { box-shadow: 0 0 0 0 rgba(14,165,233,.3); } 50% { box-shadow: 0 0 0 8px rgba(14,165,233,0); } }
.status-step-label { font-size: .7rem; color: var(--gray-400); margin-top: .5rem; font-weight: 600; }
.status-step.completed .status-step-label { color: var(--success); }
.status-step.active .status-step-label { color: var(--blue); }

/* ── Multi-Step Form ───────────────────────────────────────── */
.form-wizard { background: var(--white); border-radius: var(--radius-lg); box-shadow: var(--shadow-md); overflow: hidden; }
.wizard-header {
  background: linear-gradient(135deg, var(--navy), var(--navy-mid));
  padding: 1.75rem 2rem; color: var(--white);
}
.wizard-header h3 { font-size: 1.15rem; font-weight: 700; margin-bottom: .5rem; }

/* Progress Bar */
.wizard-progress { display: flex; align-items: center; gap: 0; padding: 0 2rem; }
.wizard-step-indicator {
  display: flex; flex-direction: column; align-items: center; flex: 1;
  position: relative; cursor: pointer;
}
.wizard-step-indicator::after {
  content: ''; position: absolute; top: 15px; left: 50%; width: 100%; height: 2px;
  background: rgba(255,255,255,.15); z-index: 0;
}
.wizard-step-indicator:last-child::after { display: none; }
.wizard-step-indicator.completed::after { background: var(--success); }
.wizard-step-indicator.active::after { background: linear-gradient(90deg, var(--blue), rgba(255,255,255,.15)); }
.wizard-step-num {
  width: 30px; height: 30px; border-radius: 50%; font-size: .75rem; font-weight: 700;
  display: grid; place-items: center; z-index: 1; position: relative;
  background: rgba(255,255,255,.1); color: rgba(255,255,255,.4); border: 2px solid rgba(255,255,255,.15);
  transition: var(--transition);
}
.wizard-step-indicator.completed .wizard-step-num { background: var(--success); border-color: var(--success); color: #fff; }
.wizard-step-indicator.active .wizard-step-num { background: var(--blue); border-color: var(--blue-light); color: #fff; box-shadow: 0 0 12px rgba(14,165,233,.4); }
.wizard-step-title { font-size: .62rem; color: rgba(255,255,255,.35); margin-top: .4rem; font-weight: 600; text-transform: uppercase; letter-spacing: .03em; }
.wizard-step-indicator.completed .wizard-step-title { color: var(--success); }
.wizard-step-indicator.active .wizard-step-title { color: var(--white); }

/* Form Body */
.wizard-body { padding: 2rem; }
.form-step { display: none; animation: stepFadeIn .4s ease; }
.form-step.active { display: block; }
@keyframes stepFadeIn { from { opacity: 0; transform: translateX(16px); } to { opacity: 1; transform: translateX(0); } }
.step-title { font-size: 1.15rem; font-weight: 700; color: var(--navy); margin-bottom: .4rem; display: flex; align-items: center; gap: .5rem; }
.step-subtitle { font-size: .85rem; color: var(--gray-400); margin-bottom: 1.5rem; }

/* Wizard Footer */
.wizard-footer {
  padding: 1.25rem 2rem; border-top: 1px solid var(--gray-200);
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: .75rem;
  background: var(--gray-50);
}

/* ── Form Controls (Enhanced Bootstrap Override) ────────────── */
.form-floating > .form-control:focus ~ label,
.form-floating > .form-control:not(:placeholder-shown) ~ label { color: var(--blue); }
.form-control:focus, .form-select:focus {
  border-color: var(--blue); box-shadow: 0 0 0 4px rgba(14,165,233,.1);
}
.form-control.is-invalid, .form-select.is-invalid {
  border-color: var(--danger); box-shadow: 0 0 0 4px rgba(239,68,68,.08);
}
.form-label { font-weight: 600; font-size: .875rem; color: var(--navy); }
.form-label .req { color: var(--danger); }
.invalid-feedback { font-size: .78rem; }

/* Custom radio / checkbox */
.form-check-input:checked { background-color: var(--blue); border-color: var(--blue); }
.form-check-input:focus { box-shadow: 0 0 0 4px rgba(14,165,233,.15); }

/* ── Repeatable Sections ───────────────────────────────────── */
.repeatable-section {
  background: var(--gray-50); border: 1px solid var(--gray-200);
  border-radius: var(--radius-md); padding: 1.5rem; margin-bottom: 1rem;
  position: relative;
}
.repeatable-section .remove-section {
  position: absolute; top: .75rem; right: .75rem;
  width: 32px; height: 32px; border-radius: 50%; border: none;
  background: var(--danger-light); color: var(--danger); cursor: pointer;
  display: grid; place-items: center; font-size: .85rem;
  transition: var(--transition);
}
.repeatable-section .remove-section:hover { background: var(--danger); color: var(--white); }
.section-number {
  display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 28px; border-radius: 50%; font-size: .75rem; font-weight: 700;
  background: var(--blue); color: var(--white); margin-bottom: .75rem;
}

/* ── Buttons ───────────────────────────────────────────────── */
.btn-portal {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .65rem 1.5rem; border-radius: var(--radius-sm);
  font-size: .875rem; font-weight: 600; cursor: pointer;
  border: 2px solid transparent; transition: var(--transition);
  font-family: 'Inter', sans-serif;
}
.btn-portal-primary { background: var(--blue); color: var(--white); }
.btn-portal-primary:hover { background: var(--blue-dark); transform: translateY(-1px); box-shadow: 0 4px 16px rgba(14,165,233,.3); }
.btn-portal-success { background: var(--success); color: var(--white); }
.btn-portal-success:hover { background: #059669; transform: translateY(-1px); }
.btn-portal-outline { border-color: var(--gray-300); background: var(--white); color: var(--gray-600); }
.btn-portal-outline:hover { border-color: var(--blue); color: var(--blue); }
.btn-portal-danger { background: var(--danger); color: var(--white); }
.btn-portal-danger:hover { background: #DC2626; }
.btn-add-more {
  display: inline-flex; align-items: center; gap: .4rem;
  padding: .55rem 1.2rem; border-radius: var(--radius-sm);
  border: 2px dashed var(--blue); background: #EFF6FF; color: var(--blue);
  font-size: .85rem; font-weight: 600; cursor: pointer;
  transition: var(--transition); font-family: 'Inter', sans-serif;
}
.btn-add-more:hover { background: var(--blue); color: var(--white); border-style: solid; }

/* ── Upload Zone ───────────────────────────────────────────── */
.upload-zone {
  border: 2.5px dashed var(--gray-300); border-radius: var(--radius-md);
  padding: 2rem; text-align: center; cursor: pointer;
  transition: var(--transition); background: var(--gray-50);
}
.upload-zone:hover, .upload-zone.drag-over { border-color: var(--blue); background: #EFF6FF; }
.upload-zone i { font-size: 2rem; color: var(--gray-400); margin-bottom: .5rem; display: block; }
.upload-zone:hover i { color: var(--blue); }
.upload-zone p { color: var(--gray-600); font-size: .85rem; margin: 0; }
.upload-zone .browse-link { color: var(--blue); font-weight: 600; cursor: pointer; }
.upload-zone input[type="file"] { display: none; }

/* Uploaded File Card */
.uploaded-file {
  display: flex; align-items: center; gap: .75rem;
  padding: .75rem 1rem; background: var(--white); border: 1px solid var(--gray-200);
  border-radius: var(--radius-sm); margin-top: .5rem; transition: var(--transition);
}
.uploaded-file:hover { border-color: var(--blue); }
.uploaded-file-icon {
  width: 40px; height: 40px; border-radius: var(--radius-sm); display: grid; place-items: center;
  font-size: 1rem; flex-shrink: 0;
}
.uploaded-file-icon.pdf  { background: #FEE2E2; color: var(--danger); }
.uploaded-file-icon.img  { background: #EFF6FF; color: var(--blue); }
.uploaded-file-name { font-size: .85rem; font-weight: 600; color: var(--navy); }
.uploaded-file-size { font-size: .72rem; color: var(--gray-400); }
.uploaded-file-remove {
  margin-left: auto; width: 28px; height: 28px; border-radius: 50%; border: none;
  background: var(--gray-100); color: var(--gray-400); cursor: pointer;
  display: grid; place-items: center; font-size: .75rem; transition: var(--transition);
}
.uploaded-file-remove:hover { background: var(--danger-light); color: var(--danger); }

/* ── Badges ────────────────────────────────────────────────── */
.badge-blue    { background: #EFF6FF; color: var(--blue-dark); }
.badge-green   { background: var(--success-light); color: #065F46; }
.badge-yellow  { background: var(--warning-light); color: #92400E; }
.badge-red     { background: var(--danger-light);  color: #991B1B; }
.badge-gray    { background: var(--gray-100); color: var(--gray-600); }
.badge-orange  { background: #FFF7ED; color: #C2410C; }

/* ── Cards ─────────────────────────────────────────────────── */
.portal-card {
  background: var(--white); border-radius: var(--radius-md);
  border: 1px solid var(--gray-200); box-shadow: var(--shadow-sm);
  transition: var(--transition);
}
.portal-card:hover { box-shadow: var(--shadow-md); }
.portal-card-header {
  padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--gray-200);
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .75rem;
}
.portal-card-title { font-size: 1rem; font-weight: 700; color: var(--navy); }
.portal-card-body { padding: 1.5rem; }

/* ── Alerts ────────────────────────────────────────────────── */
.alert { border-radius: var(--radius-sm); font-size: .875rem; }

/* ── Password Strength ─────────────────────────────────────── */
.pwd-strength { height: 4px; border-radius: 2px; background: var(--gray-200); margin-top: .4rem; overflow: hidden; }
.pwd-strength-bar { height: 100%; border-radius: 2px; transition: width .3s ease, background .3s ease; width: 0; }
.pwd-strength-bar.weak     { width: 25%;  background: var(--danger); }
.pwd-strength-bar.fair     { width: 50%;  background: var(--warning); }
.pwd-strength-bar.good     { width: 75%;  background: var(--blue); }
.pwd-strength-bar.strong   { width: 100%; background: var(--success); }
.pwd-strength-text { font-size: .72rem; margin-top: .25rem; font-weight: 600; }

/* ── Empty State ───────────────────────────────────────────── */
.empty-state { text-align: center; padding: 3rem 1.5rem; color: var(--gray-400); }
.empty-state i { font-size: 3rem; margin-bottom: 1rem; display: block; }

/* ── Animations ────────────────────────────────────────────── */
.fade-in { animation: fadeIn .5s ease; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
.slide-up { animation: slideUp .5s ease; }
@keyframes slideUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }

/* ── Footer ────────────────────────────────────────────────── */
.portal-footer {
  background: var(--navy); padding: 1.5rem 0; margin-top: 3rem;
  text-align: center; color: rgba(255,255,255,.4); font-size: .8rem;
}
.portal-footer a { color: var(--blue); }

/* ── Responsive ────────────────────────────────────────────── */
@media (max-width: 992px) {
  .wizard-step-title { display: none; }
  .wizard-step-num { width: 26px; height: 26px; font-size: .7rem; }
  .wizard-body { padding: 1.25rem; }
  .wizard-header { padding: 1.25rem; }
}
@media (max-width: 768px) {
  .dash-welcome { padding: 1.5rem; }
  .dash-welcome h2 { font-size: 1.2rem; }
  .status-timeline { gap: 0; }
  .status-step-label { font-size: .6rem; }
  .wizard-footer { padding: 1rem; }
  .auth-card { padding: 2rem 1.5rem; }
}
@media (max-width: 480px) {
  .wizard-progress { padding: 0 .5rem; }
  .wizard-step-num { width: 22px; height: 22px; font-size: .65rem; }
  .portal-card-body { padding: 1rem; }
}
