/* ============================================================
   United College Management — Global Stylesheet
   ============================================================ */

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

/* ── Design Tokens ─────────────────────────────────────────── */
:root {
  --navy:        #02133E;
  --navy-light:  #0a1f5c;
  --teal:        #07FFC3;
  --teal-dark:   #05d9a6;
  --white:       #FFFFFF;
  --bg:          #F4F6F9;
  --surface:     #FFFFFF;
  --text:        #212529;
  --muted:       #6C757D;
  --border:      #CBCBCB;
  --success:     #198754;
  --warning:     #FFC107;
  --danger:      #DC3545;
  --info:        #0dcaf0;

  --font-head:   'Poppins', sans-serif;
  --font-body:   'Inter', sans-serif;

  --radius-sm:   6px;
  --radius-md:   10px;
  --radius-lg:   16px;
  --shadow-sm:   0 1px 4px rgba(2, 19, 62, 0.08);
  --shadow-md:   0 4px 16px rgba(2, 19, 62, 0.12);
  --shadow-lg:   0 8px 32px rgba(2, 19, 62, 0.16);

  --sidebar-w:   260px;
  --topbar-h:    64px;
}

/* ── Reset ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  min-height: 100vh;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; font-family: var(--font-body); }

/* ── Auth Layout ────────────────────────────────────────────── */
.auth-page {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
}

/* Left image-slider panel */
.auth-brand {
  position: relative;
  overflow: hidden;
  background: var(--navy);
}

/* ── Slider track ── */
.auth-slider {
  position: absolute;
  inset: 0;
  display: flex;
  transition: none;
}

.auth-slider-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.8s ease;
  pointer-events: none;
}
.auth-slider-slide.active {
  opacity: 1;
  pointer-events: auto;
}
.auth-slider-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Bottom gradient + dots */
.auth-slider-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.55) 0%, transparent 50%);
  pointer-events: none;
  z-index: 2;
}

.auth-slider-dots {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 0.45rem;
  z-index: 3;
}
.auth-slider-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255,255,255,0.4);
  cursor: pointer;
  transition: background 0.25s, transform 0.25s;
  border: none;
  padding: 0;
}
.auth-slider-dot.active {
  background: #fff;
  transform: scale(1.3);
}

/* Fallback: when no slides loaded (keep old navy panel feel) */
.auth-brand-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding: 3rem 4rem;
  z-index: 1;
}
.auth-brand-fallback::before {
  content: '';
  position: absolute;
  width: 500px; height: 500px;
  border-radius: 50%;
  background: rgba(7,255,195,0.05);
  top: -120px; right: -160px;
  pointer-events: none;
}
.auth-brand-fallback::after {
  content: '';
  position: absolute;
  width: 300px; height: 300px;
  border-radius: 50%;
  background: rgba(7,255,195,0.04);
  bottom: -80px; left: -60px;
  pointer-events: none;
}

.auth-brand-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 3.5rem;
  position: relative;
  z-index: 1;
}

.auth-mobile-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

.auth-brand-logo-mark {
  width: 48px;
  height: 48px;
  background: var(--teal);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--navy);
  flex-shrink: 0;
}

.auth-brand-logo-text {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1rem;
  color: var(--white);
  line-height: 1.3;
}

.auth-brand-logo-text span {
  display: block;
  font-size: 0.75rem;
  font-weight: 400;
  color: rgba(255,255,255,0.55);
  margin-top: 1px;
}

.auth-brand-content {
  position: relative;
  z-index: 1;
}

.auth-brand-tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--teal);
  background: rgba(7, 255, 195, 0.1);
  border: 1px solid rgba(7, 255, 195, 0.25);
  padding: 0.3rem 0.85rem;
  border-radius: 999px;
  margin-bottom: 1.25rem;
}

.auth-brand-heading {
  font-family: var(--font-head);
  font-size: 2rem;
  font-weight: 700;
  color: var(--white);
  line-height: 1.25;
  margin-bottom: 1rem;
}

.auth-brand-heading em {
  font-style: normal;
  color: var(--teal);
}

.auth-brand-desc {
  font-size: 0.9375rem;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.7;
  max-width: 380px;
  margin-bottom: 2.5rem;
}

.auth-brand-features {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.auth-brand-features li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.7);
}

.auth-brand-features li::before {
  content: '';
  width: 6px;
  height: 6px;
  background: var(--teal);
  border-radius: 50%;
  flex-shrink: 0;
}

/* Right form panel */
.auth-form-panel {
  background: var(--white);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 3rem 2rem;
  overflow-y: auto;
}

.auth-form-inner {
  width: 100%;
  max-width: 420px;
}

.auth-form-header {
  margin-bottom: 2rem;
}

.auth-form-title {
  font-family: var(--font-head);
  font-size: 1.625rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 0.375rem;
}

.auth-form-subtitle {
  font-size: 0.9rem;
  color: var(--muted);
}

.auth-form-subtitle a {
  color: var(--navy);
  font-weight: 600;
  border-bottom: 1.5px solid var(--teal);
  padding-bottom: 1px;
  transition: color 0.15s;
}

.auth-form-subtitle a:hover { color: var(--teal-dark); }

/* ── Form Controls ──────────────────────────────────────────── */
.form-group {
  margin-bottom: 1.25rem;
}

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

.form-label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 0.4rem;
  letter-spacing: 0.01em;
}

.form-label .required {
  color: var(--danger);
  margin-left: 2px;
}

.form-control {
  display: block;
  width: 100%;
  padding: 0.65rem 0.875rem;
  font-family: var(--font-body);
  font-size: 0.9375rem;
  color: var(--text);
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-md);
  transition: border-color 0.15s, box-shadow 0.15s;
  outline: none;
  -webkit-appearance: none;
}

.form-control::placeholder { color: #adb5bd; }

.form-control:focus {
  border-color: var(--navy);
  box-shadow: 0 0 0 3px rgba(2, 19, 62, 0.08);
}

.form-control.is-invalid {
  border-color: var(--danger);
  box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.08);
}

.form-error {
  font-size: 0.8125rem;
  color: var(--danger);
  margin-top: 0.3rem;
}

.input-wrapper {
  position: relative;
}

.input-wrapper .form-control { padding-right: 2.75rem; }

.input-icon {
  position: absolute;
  right: 0.875rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted);
  display: flex;
  align-items: center;
  background: none;
  border: none;
  padding: 0;
  line-height: 1;
}

.input-icon svg { width: 18px; height: 18px; }

/* ── Buttons ────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1.5rem;
  font-family: var(--font-body);
  font-size: 0.9375rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s, box-shadow 0.15s, opacity 0.15s;
  white-space: nowrap;
  text-decoration: none;
}

.btn-primary {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
}

.btn-primary:hover {
  background: var(--navy-light);
  border-color: var(--navy-light);
}

.btn-primary:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(2, 19, 62, 0.3);
}

.btn-primary:active { opacity: 0.9; }

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

.btn-block { width: 100%; }

.btn-sm { padding: 0.45rem 1rem; font-size: 0.875rem; }

/* ── Alert / Flash ──────────────────────────────────────────── */
.alert {
  padding: 0.85rem 1rem;
  border-radius: var(--radius-md);
  font-size: 0.875rem;
  margin-bottom: 1.25rem;
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  line-height: 1.5;
}

.alert-success { background: #d1faec; color: #0d6e43; border: 1px solid #a8edcd; }
.alert-danger  { background: #fde8e9; color: #a01d28; border: 1px solid #f5c2c5; }
.alert-warning { background: #fff4cc; color: #856404; border: 1px solid #ffdf7e; }
.alert-info    { background: #d0f4fb; color: #0c5460; border: 1px solid #9de9f7; }

/* ── Divider ────────────────────────────────────────────────── */
.auth-divider {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 1.5rem 0;
  font-size: 0.8125rem;
  color: var(--muted);
}

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

.auth-divider span { white-space: nowrap; }

/* ── Google Sign-In button ─────────────────────────────────── */
.btn-google-signin {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.625rem;
  width: 100%;
  padding: 0.65rem 1rem;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  background: #fff;
  color: #3c4043;
  font-size: 0.9375rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, box-shadow 0.15s;
}
.btn-google-signin:hover {
  background: #f8f9fa;
  border-color: #c6c9cc;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
  color: #1a1a1a;
  text-decoration: none;
}
.btn-google-signin:active {
  background: #f1f3f4;
}

/* ── Password strength ─────────────────────────────────────── */
.password-strength {
  margin-top: 0.5rem;
  display: flex;
  gap: 4px;
}

.strength-bar {
  height: 3px;
  flex: 1;
  background: var(--border);
  border-radius: 2px;
  transition: background 0.2s;
}

.strength-bar.weak   { background: var(--danger); }
.strength-bar.fair   { background: var(--warning); }
.strength-bar.good   { background: #5bc0de; }
.strength-bar.strong { background: var(--success); }

.strength-label {
  font-size: 0.75rem;
  color: var(--muted);
  margin-top: 0.25rem;
}

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 900px) {
  .auth-page { grid-template-columns: 1fr; }
  .auth-brand { display: none; }
  .auth-form-panel {
    padding: 2.5rem 1.5rem;
    min-height: 100vh;
  }
  .auth-form-inner { max-width: 440px; }
}

@media (max-width: 480px) {
  .form-row { grid-template-columns: 1fr; }
  .auth-form-panel { padding: 2rem 1.25rem; }
}

/* ── Utilities ──────────────────────────────────────────────── */
.hidden { display: none !important; }

/* ── Utilities ──────────────────────────────────────────────── */
.hidden { display: none !important; }

/* ── App Shell ──────────────────────────────────────────────── */
:root {
  --modules-w:  84px;
  --items-w:   220px;
  --topbar-h:   60px;
  --strip-bg:  #010d2a;
}

.app-shell {
  display: grid;
  grid-template-columns: var(--modules-w) var(--items-w) 1fr;
  height: 100vh;
  overflow: hidden;
}

.app-body {
  display: grid;
  grid-template-rows: var(--topbar-h) 1fr;
  min-height: 0;
}

.app-main {
  overflow-y: auto;
  padding: 1.5rem;
  background: var(--bg);
}

/* ── Sidebar: Module Strip (Level 1) ────────────────────────── */
.sidebar-modules {
  background: var(--strip-bg);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-bottom: 1rem;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: none;
}
.sidebar-modules::-webkit-scrollbar { display: none; }

.sidebar-logo-mark {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  background: transparent;
  border-radius: var(--radius-md);
  font-family: var(--font-head);
  font-size: 1.125rem;
  font-weight: 700;
  color: white;
  margin: 1.125rem auto 1.25rem;
  flex-shrink: 0;
  text-decoration: none;
  transition: transform 0.15s;
}
.sidebar-logo-mark:hover { transform: scale(1.05); }
.sidebar-logo-img {
  width: 38px;
  height: 38px;
  object-fit: contain;
  display: block;
  border-radius: var(--radius-md);
}
.sidebar-logo-img {
  width: 38px;
  height: 38px;
  object-fit: contain;
  display: block;
  border-radius: var(--radius-md);
}

.sidebar-modules-list {
  display: flex;
  flex-direction: column;
  width: 100%;
  gap: 2px;
  flex: 1;
}

.module-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  padding: 0.65rem 0.25rem;
  width: 100%;
  background: none;
  border: none;
  color: rgba(255,255,255,0.4);
  cursor: pointer;
  transition: color 0.15s, background 0.15s;
  position: relative;
  font-family: var(--font-body);
}
.module-btn span {
  font-size: 0.5625rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1;
}
.module-btn svg { flex-shrink: 0; width: 20px; height: 20px; }

.module-btn:hover  { color: rgba(255,255,255,0.8); background: rgba(255,255,255,0.05); }
.module-btn.active { color: var(--teal); }
.module-btn.active::after {
  content: '';
  position: absolute;
  right: 0; top: 20%; bottom: 20%;
  width: 3px;
  background: var(--teal);
  border-radius: 2px 0 0 2px;
}

.module-logout {
  margin-top: auto;
  color: rgba(255,255,255,0.25);
}
.module-logout:hover { color: var(--danger); background: rgba(220,53,69,0.08); }

/* ── Sidebar: Items Panel (Level 2) ─────────────────────────── */
.sidebar-items {
  background: #ffffff;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: thin;
  scrollbar-color: rgba(0,0,0,0.12) transparent;
  border-right: 1px solid #e5e7eb;
}
.sidebar-items::-webkit-scrollbar { width: 4px; }
.sidebar-items::-webkit-scrollbar-track { background: transparent; }
.sidebar-items::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.12); border-radius: 2px; }

.sidebar-panel { display: none; }
.sidebar-panel.active { display: block; }

.sidebar-panel-header {
  font-family: var(--font-head);
  font-size: 0.875rem;
  font-weight: 600;
  color: #111827;
  padding: 1.25rem 1rem 0.75rem;
  letter-spacing: 0.01em;
}

.sidebar-section-title {
  font-size: 0.625rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #9ca3af;
  padding: 0.875rem 1rem 0.375rem;
  margin: 0;
}

.sidebar-item {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.55rem 1rem;
  font-size: 0.8125rem;
  font-weight: 400;
  color: #4b5563;
  text-decoration: none;
  transition: color 0.12s, background 0.12s;
  position: relative;
  line-height: 1.4;
}
.sidebar-item svg { flex-shrink: 0; opacity: 0.6; }
.sidebar-item:hover { color: #111827; background: #f3f4f6; }
.sidebar-item:hover svg { opacity: 1; }

.sidebar-item.active {
  color: var(--navy);
  background: #eff6ff;
  font-weight: 600;
}
.sidebar-item.active svg { opacity: 1; color: var(--navy); }
.sidebar-item.active::before {
  content: '';
  position: absolute;
  left: 0; top: 25%; bottom: 25%;
  width: 3px;
  background: var(--teal);
  border-radius: 0 2px 2px 0;
}

/* ── Sidebar dropdown (details/summary) ────────────────────── */
.sidebar-dropdown { display: block; }
.sidebar-dropdown > summary { list-style: none; cursor: pointer; }
.sidebar-dropdown > summary::-webkit-details-marker { display: none; }
.sidebar-dropdown-trigger {
  display: flex; align-items: center;
  user-select: none;
}
.sidebar-dropdown-chevron {
  margin-left: auto;
  flex-shrink: 0;
  opacity: 0.4;
  transition: transform 0.18s;
}
.sidebar-dropdown[open] .sidebar-dropdown-chevron { transform: rotate(180deg); opacity: 0.7; }
.sidebar-item--child {
  padding-left: 2.25rem;
  font-size: 0.78rem;
  color: #6b7280;
}
.sidebar-item--child::before { display: none !important; }
.sidebar-item--child.active { color: var(--navy); background: #eff6ff; font-weight: 600; }
.sidebar-item--child svg { opacity: 0.4; }

/* Admin nav table: child row indent */
.ac-nav-child-row td:first-child { padding-left: 1.75rem; }
.ac-nav-child-prefix { color: #9ca3af; margin-right: 4px; font-size: 0.85rem; }
.ac-pill--teal { background: #e0fdf4; color: #065f46; }

/* ── Topbar ─────────────────────────────────────────────────── */
.app-topbar {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  height: var(--topbar-h);
  display: flex;
  align-items: center;
  padding: 0 1.25rem;
  gap: 0.75rem;
  position: relative;
  z-index: 200;
}

.topbar-left { display: flex; align-items: center; gap: 0.75rem; flex: 1; min-width: 0; }

.topbar-menu-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px; height: 34px;
  background: none;
  border: none;
  border-radius: var(--radius-sm);
  color: var(--muted);
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
  flex-shrink: 0;
}
.topbar-menu-btn:hover { background: var(--bg); color: var(--navy); }

.topbar-breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  font-size: 0.8125rem;
  color: var(--muted);
  min-width: 0;
}
.topbar-breadcrumb-home { display: flex; align-items: center; color: var(--muted); }
.topbar-breadcrumb-sep { opacity: 0.5; }
.topbar-breadcrumb-current { font-weight: 600; color: var(--navy); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.topbar-right { display: flex; align-items: center; gap: 0.5rem; flex-shrink: 0; }

.topbar-icon-btn {
  display: flex; align-items: center; justify-content: center;
  width: 34px; height: 34px;
  background: none; border: none;
  border-radius: var(--radius-sm);
  color: var(--muted);
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
}
.topbar-icon-btn:hover { background: var(--bg); color: var(--navy); }

.topbar-divider { width: 1px; height: 24px; background: var(--border); margin: 0 0.25rem; }

/* Search trigger pill */
.topbar-search-trigger {
  display: flex; align-items: center; gap: 0.5rem;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0.35rem 0.625rem 0.35rem 0.5rem;
  color: var(--muted);
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 0.8125rem;
  transition: border-color 0.12s, box-shadow 0.12s, color 0.12s;
  white-space: nowrap;
}
.topbar-search-trigger:hover {
  border-color: rgba(2,19,62,0.25);
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
  color: var(--text);
}
.topbar-search-label { color: var(--muted); }
.topbar-search-kbd {
  display: inline-flex; align-items: center; gap: 1px;
  font-size: 0.6875rem; color: var(--muted);
  background: var(--white); border: 1px solid var(--border);
  border-radius: 5px; padding: 1px 5px;
  font-family: var(--font-body);
  margin-left: 0.25rem;
}
.topbar-search-kbd span { font-size: 0.75rem; line-height: 1; }

/* Profile */
.topbar-profile-wrap { position: relative; }

.topbar-profile-btn {
  display: flex; align-items: center; gap: 0.625rem;
  background: none; border: none; cursor: pointer;
  padding: 0.35rem 0.5rem 0.35rem 0.35rem;
  border-radius: var(--radius-md);
  transition: background 0.12s;
}
.topbar-profile-btn:hover { background: var(--bg); }

.topbar-avatar {
  width: 32px; height: 32px;
  background: var(--navy);
  color: var(--teal);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-head);
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  flex-shrink: 0;
}

.topbar-profile-info {
  display: flex; flex-direction: column; align-items: flex-start; gap: 1px;
}
.topbar-profile-name {
  font-size: 0.8125rem; font-weight: 600; color: var(--text); white-space: nowrap; line-height: 1.2;
}
.topbar-profile-role {
  font-size: 0.6875rem; color: var(--muted); white-space: nowrap; line-height: 1.2;
}

/* Profile Dropdown */
.profile-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  width: 240px;
  z-index: 300;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-6px);
  transition: opacity 0.15s, transform 0.15s;
}
.profile-dropdown.open { opacity: 1; pointer-events: auto; transform: translateY(0); }

.profile-dropdown-header {
  display: flex; align-items: center; gap: 0.75rem;
  padding: 1rem;
}
.profile-dropdown-avatar {
  width: 40px; height: 40px;
  background: var(--navy); color: var(--teal);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-head); font-size: 0.8125rem; font-weight: 700;
  flex-shrink: 0;
}
.profile-dropdown-info { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.profile-dropdown-name { font-size: 0.875rem; font-weight: 600; color: var(--text); line-height: 1.3; }
.profile-dropdown-email { font-size: 0.72rem; color: var(--muted); word-break: break-all; line-height: 1.4; }
.profile-dropdown-role-tag {
  display: inline-block; margin-top: 4px;
  font-size: 0.625rem; font-weight: 700;
  letter-spacing: 0.07em; text-transform: uppercase;
  color: var(--muted); line-height: 1;
}

.role-badge {
  display: inline-flex; align-items: center;
  font-size: 0.6875rem; font-weight: 600;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  letter-spacing: 0.04em; text-transform: uppercase;
}
.role-badge--admin      { background: rgba(2,19,62,0.08);  color: var(--navy); }
.role-badge--staff      { background: rgba(13,202,240,0.12); color: #0891b2; }
.role-badge--student    { background: rgba(7,255,195,0.12); color: #059669; }
.role-badge--super_admin { background: rgba(220,53,69,0.1); color: var(--danger); }

.profile-dropdown-divider { height: 1px; background: var(--border); }

.profile-dropdown-item {
  display: flex; align-items: center; gap: 0.625rem;
  padding: 0.6rem 1rem; font-size: 0.8125rem;
  color: var(--text); text-decoration: none;
  transition: background 0.1s, color 0.1s;
}
.profile-dropdown-item:hover { background: var(--bg); }
.profile-dropdown-item:last-child { border-radius: 0 0 var(--radius-lg) var(--radius-lg); }
.profile-dropdown-item--danger { color: var(--danger); }
.profile-dropdown-item--danger:hover { background: rgba(220,53,69,0.06); }

/* ── Welcome Banner ─────────────────────────────────────────── */
.welcome-banner {
  background: linear-gradient(135deg, var(--navy) 0%, #0a2460 60%, #122f7a 100%);
  border-radius: var(--radius-lg);
  padding: 2rem 2rem 2rem 2.25rem;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  overflow: hidden;
  position: relative;
}
.welcome-banner-body { position: relative; z-index: 1; }
.welcome-banner-tag {
  font-size: 0.75rem; font-weight: 500;
  color: rgba(255,255,255,0.5);
  letter-spacing: 0.04em; margin-bottom: 0.375rem;
}
.welcome-banner-title {
  font-family: var(--font-head);
  font-size: 1.5rem; font-weight: 700;
  color: white; line-height: 1.25; margin-bottom: 0.5rem;
}
.welcome-banner-sub { font-size: 0.9rem; color: rgba(255,255,255,0.65); line-height: 1.6; }
.welcome-banner-sub strong { color: var(--teal); }

.welcome-banner-visual {
  position: relative; flex-shrink: 0;
  width: 130px; height: 110px;
  display: flex; align-items: center; justify-content: center;
}
.welcome-circle {
  position: absolute; border-radius: 50%;
  background: rgba(7,255,195,0.07);
  border: 1px solid rgba(7,255,195,0.12);
}
.welcome-circle--lg { width: 160px; height: 160px; top: -30px; right: -30px; }
.welcome-circle--sm { width: 90px; height: 90px; bottom: -15px; left: -10px; }

/* ── Buttons (extended) ─────────────────────────────────────── */
.btn-teal {
  background: var(--teal);
  color: var(--navy);
  border-color: var(--teal);
  font-weight: 700;
}
.btn-teal:hover { background: var(--teal-dark); border-color: var(--teal-dark); }

.btn-ghost {
  background: rgba(255,255,255,0.1);
  color: white;
  border-color: rgba(255,255,255,0.2);
}
.btn-ghost:hover { background: rgba(255,255,255,0.18); border-color: rgba(255,255,255,0.35); }

/* ── KPI Cards ──────────────────────────────────────────────── */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.kpi-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(203,203,203,0.4);
  transition: box-shadow 0.15s, transform 0.15s;
}
.kpi-card:hover { box-shadow: var(--shadow-md); transform: translateY(-1px); }

.kpi-icon {
  width: 46px; height: 46px;
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.kpi-icon--teal  { background: rgba(7,255,195,0.12);  color: #059669; }
.kpi-icon--amber { background: rgba(255,193,7,0.12);  color: #b45309; }
.kpi-icon--blue  { background: rgba(13,202,240,0.12); color: #0891b2; }
.kpi-icon--green { background: rgba(25,135,84,0.1);   color: #198754; }

.kpi-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.kpi-label { font-size: 0.75rem; font-weight: 500; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kpi-value { font-family: var(--font-head); font-size: 1.625rem; font-weight: 700; color: var(--navy); line-height: 1.1; }

/* ── Dashboard Content Grid ─────────────────────────────────── */
.dash-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.dash-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(203,203,203,0.4);
}
.dash-card--wide { grid-column: span 1; }
.dash-card--full { grid-column: 1 / -1; }

.dash-card-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 1rem;
}
.dash-card-title { font-family: var(--font-head); font-size: 0.9375rem; font-weight: 600; color: var(--navy); }
.dash-card-link  { font-size: 0.8125rem; color: var(--teal-dark); font-weight: 500; text-decoration: none; transition: color 0.12s; }
.dash-card-link:hover { color: var(--navy); }
.dash-card-meta  { font-size: 0.75rem; color: var(--muted); }

/* ── Table ──────────────────────────────────────────────────── */
.table-wrap { overflow-x: auto; margin: -0.25rem; }

.dash-table {
  width: 100%; border-collapse: collapse; font-size: 0.8125rem;
  white-space: nowrap;
}
.dash-table th {
  text-align: left; padding: 0.5rem 0.75rem;
  font-size: 0.6875rem; font-weight: 700; letter-spacing: 0.06em;
  text-transform: uppercase; color: var(--muted);
  border-bottom: 1px solid var(--border);
}
.dash-table td {
  padding: 0.65rem 0.75rem;
  color: var(--text);
  border-bottom: 1px solid rgba(203,203,203,0.3);
}
.dash-table tr:last-child td { border-bottom: none; }
.dash-table tr:hover td { background: rgba(2,19,62,0.02); }
.dash-table code {
  font-size: 0.75rem; color: var(--navy); font-weight: 600;
  background: rgba(2,19,62,0.06); padding: 2px 6px; border-radius: 4px;
}

/* ── Status Pill ────────────────────────────────────────────── */
.status-pill {
  display: inline-flex; align-items: center;
  padding: 0.2rem 0.6rem;
  font-size: 0.6875rem; font-weight: 600;
  border-radius: 999px;
  background: color-mix(in srgb, var(--pill-color) 12%, white);
  color: var(--pill-color);
  white-space: nowrap;
}

/* ── Ops Snapshot ───────────────────────────────────────────── */
.ops-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.75rem; }

.ops-pill {
  display: flex; align-items: center; gap: 0.5rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md);
  font-size: 0.8125rem;
}
.ops-pill-label { flex: 1; font-weight: 500; }
.ops-pill-value { font-family: var(--font-head); font-weight: 700; font-size: 1.125rem; }

.ops-pill--blue  { background: rgba(13,202,240,0.1);  color: #0891b2; }
.ops-pill--teal  { background: rgba(7,255,195,0.1);   color: #059669; }
.ops-pill--amber { background: rgba(255,193,7,0.12);  color: #b45309; }
.ops-pill--red   { background: rgba(220,53,69,0.1);   color: var(--danger); }

/* ── Empty State ────────────────────────────────────────────── */
.dash-empty {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 0.5rem; padding: 2rem 1rem;
  color: var(--muted); text-align: center; font-size: 0.875rem;
}
.dash-empty svg { opacity: 0.35; }

/* ── Responsive (app shell) ─────────────────────────────────── */
@media (max-width: 1100px) {
  .kpi-grid  { grid-template-columns: repeat(2, 1fr); }
  .dash-grid { grid-template-columns: 1fr; }
  .ops-grid  { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .app-shell { grid-template-columns: var(--modules-w) 0 1fr; }
  .sidebar-items { display: none; }
  .sidebar-items.open { display: block; position: fixed; left: var(--modules-w); top: 0; bottom: 0; width: var(--items-w); z-index: 500; }
  .topbar-profile-info { display: none; }
  .topbar-breadcrumb-current { max-width: 120px; }
  .kpi-grid { grid-template-columns: 1fr 1fr; }
  .ops-grid { grid-template-columns: 1fr 1fr; }
}

/* ── Mobile sidebar drawer (≤640px) ─────────────────────────── */
.sidebar-mobile-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  z-index: 598;
  backdrop-filter: blur(1px);
}
.sidebar-mobile-backdrop.visible { display: block; }

@media (max-width: 640px) {
  /* Single column — sidebar elements are out of flow (display:none / position:fixed),
     so app-body would land in col 1 (0px) with the 3-col grid. Use 1fr instead. */
  .app-shell { grid-template-columns: 1fr; }
  .sidebar-modules { display: none !important; }
  /* Always render (not display:none) so CSS transform animates */
  .sidebar-items,
  .sidebar-items.open {
    display: block !important;
    position: fixed !important;
    left: 0 !important;
    top: 0; bottom: 0;
    width: 80vw; max-width: 300px;
    z-index: 599 !important;
    background: #fff;
    box-shadow: 4px 0 24px rgba(0,0,0,0.18);
    transform: translateX(-100%);
    transition: transform 0.25s ease;
    overflow-y: auto;
    visibility: hidden;
  }
  .sidebar-items.open {
    transform: translateX(0) !important;
    visibility: visible;
  }
  .topbar-search-trigger { display: none; }
}

@media (max-width: 480px) {
  .kpi-grid { grid-template-columns: 1fr; }
  .ops-grid { grid-template-columns: 1fr; }
  .app-main { padding: 1rem; }
  .welcome-banner-visual { display: none; }
  .topbar-search-label { display: none; }
  .topbar-search-kbd   { display: none; }
}

/* ── Quick Search Modal ─────────────────────────────────────── */
.qs-overlay {
  position: fixed; inset: 0;
  background: rgba(2,13,42,0.55);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
  z-index: 1000;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 10vh;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s;
}
.qs-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

.qs-modal {
  background: var(--white);
  border-radius: 14px;
  box-shadow: 0 24px 60px rgba(2,13,42,0.22), 0 4px 16px rgba(0,0,0,0.08);
  width: min(580px, calc(100vw - 2rem));
  overflow: hidden;
  transform: translateY(-12px) scale(0.98);
  transition: transform 0.18s;
}
.qs-overlay.open .qs-modal {
  transform: translateY(0) scale(1);
}

.qs-input-row {
  display: flex; align-items: center; gap: 0.75rem;
  padding: 0.875rem 1rem;
  border-bottom: 1px solid var(--border);
}

.qs-icon { color: var(--muted); flex-shrink: 0; }

.qs-input {
  flex: 1; border: none; outline: none;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--text);
  background: transparent;
}
.qs-input::placeholder { color: var(--muted); }

.qs-close {
  display: flex; align-items: center;
  background: none; border: none; cursor: pointer; padding: 0;
  flex-shrink: 0;
}
.qs-close kbd {
  font-size: 0.6875rem; color: var(--muted);
  background: var(--bg); border: 1px solid var(--border);
  border-radius: 5px; padding: 2px 6px;
  font-family: var(--font-body);
  transition: background 0.1s;
}
.qs-close:hover kbd { background: var(--border); }

.qs-results {
  max-height: 360px;
  overflow-y: auto;
  overscroll-behavior: contain;
}
.qs-results::-webkit-scrollbar { width: 4px; }
.qs-results::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }

.qs-section { padding: 0.625rem 0 0.375rem; }

.qs-section-label {
  font-size: 0.6875rem; font-weight: 700;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--muted); padding: 0 1rem 0.375rem;
  margin: 0;
}

.qs-result-item {
  display: flex; align-items: center; gap: 0.75rem;
  padding: 0.5rem 1rem;
  text-decoration: none; color: var(--text);
  font-size: 0.875rem;
  transition: background 0.1s;
  cursor: pointer;
  border-radius: 0;
}
.qs-result-item:hover,
.qs-result-item.qs-focused {
  background: rgba(2,19,62,0.04);
}
.qs-result-item.qs-focused { outline: none; }

.qs-result-icon {
  width: 30px; height: 30px;
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.qs-result-icon--home     { background: rgba(2,19,62,0.08);   color: var(--navy); }
.qs-result-icon--apps     { background: rgba(255,193,7,0.12); color: #b45309; }
.qs-result-icon--students { background: rgba(7,255,195,0.12); color: #059669; }
.qs-result-icon--staff    { background: rgba(13,202,240,0.12);color: #0891b2; }
.qs-result-icon--page     { background: rgba(2,19,62,0.06);   color: var(--muted); }

.qs-result-label { flex: 1; font-weight: 500; }

.qs-result-tag {
  font-size: 0.6875rem; font-weight: 500;
  color: var(--muted);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 1px 6px;
  flex-shrink: 0;
}

.qs-empty {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 0.5rem; padding: 2.5rem 1rem;
  color: var(--muted); text-align: center; font-size: 0.875rem;
}
.qs-empty svg { opacity: 0.3; }
.qs-empty strong { color: var(--text); }

.qs-footer {
  display: flex; align-items: center; gap: 1rem;
  padding: 0.625rem 1rem;
  border-top: 1px solid var(--border);
  background: var(--bg);
}
.qs-hint {
  display: flex; align-items: center; gap: 0.25rem;
  font-size: 0.6875rem; color: var(--muted);
}
.qs-hint kbd {
  font-size: 0.6875rem;
  background: var(--white); border: 1px solid var(--border);
  border-radius: 4px; padding: 1px 5px;
  font-family: var(--font-body); color: var(--muted);
  min-width: 18px; text-align: center;
}

.qs-hidden { display: none !important; }

/* ── Page Header ────────────────────────────────────────────── */
.page-header {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 1rem; margin-bottom: 1.5rem;
}
.page-title { font-family: var(--font-head); font-size: 1.375rem; font-weight: 700; color: var(--navy); margin: 0 0 0.25rem; }
.page-sub   { font-size: 0.875rem; color: var(--muted); margin: 0; }

/* ── Settings Layout ────────────────────────────────────────── */
.settings-wrap { background: var(--white); border-radius: var(--radius-lg); border: 1px solid rgba(203,203,203,0.4); box-shadow: var(--shadow-sm); overflow: hidden; }

.settings-tabs {
  display: flex; gap: 0;
  border-bottom: 1px solid var(--border);
  padding: 0 1.5rem;
  background: var(--white);
}

.settings-tab {
  display: flex; align-items: center; gap: 0.5rem;
  padding: 0.875rem 1rem;
  font-size: 0.875rem; font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: color 0.12s, border-color 0.12s;
  white-space: nowrap;
}
.settings-tab:hover   { color: var(--navy); }
.settings-tab.active  { color: var(--navy); border-bottom-color: var(--navy); }
.settings-tab svg     { opacity: 0.6; }
.settings-tab.active svg { opacity: 1; }

.settings-body { padding: 2rem 2rem 1.5rem; }

.settings-section { display: grid; grid-template-columns: 280px 1fr; gap: 2rem; align-items: start; padding: 1.25rem 0; }
.settings-section-head {}
.settings-section-title { font-family: var(--font-head); font-size: 0.9375rem; font-weight: 600; color: var(--navy); margin: 0 0 0.375rem; }
.settings-section-desc  { font-size: 0.8125rem; color: var(--muted); line-height: 1.6; margin: 0; }
.settings-divider { height: 1px; background: var(--border); margin: 0.5rem 0; }
.settings-actions { display: flex; gap: 0.75rem; justify-content: flex-end; padding-top: 1.5rem; border-top: 1px solid var(--border); margin-top: 1.5rem; }

/* ── Upload Zone ────────────────────────────────────────────── */
.settings-upload-zone {
  border: 2px dashed var(--border);
  border-radius: var(--radius-lg);
  min-height: 140px;
  display: flex; align-items: center; justify-content: center;
  position: relative;
  background: var(--bg);
  transition: border-color 0.15s, background 0.15s;
  overflow: hidden;
}
.settings-upload-zone:hover,
.settings-upload-zone.drag-over { border-color: var(--navy); background: rgba(2,19,62,0.03); }
.settings-upload-zone--square { width: 140px; min-height: 140px; }

.settings-upload-empty {
  display: flex; flex-direction: column; align-items: center; gap: 0.5rem;
  text-align: center; padding: 1.5rem; color: var(--muted);
}
.settings-upload-empty p   { font-size: 0.875rem; margin: 0; }
.settings-upload-empty svg { opacity: 0.4; }
.upload-browse-link { color: var(--navy); font-weight: 600; cursor: pointer; text-decoration: underline; }
.upload-hint { font-size: 0.75rem; color: var(--muted); }

.settings-upload-preview {
  width: 100%; height: 100%;
  min-height: 138px;
  display: flex; align-items: center; justify-content: center;
  position: relative; padding: 0.5rem;
}
.settings-upload-img { max-width: 100%; max-height: 120px; object-fit: contain; border-radius: 6px; }

.settings-upload-remove {
  position: absolute; top: 8px; right: 8px;
  width: 24px; height: 24px;
  background: rgba(220,53,69,0.1); border: none; border-radius: 50%;
  color: var(--danger); cursor: pointer; font-size: 0.75rem;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.12s;
}
.settings-upload-remove:hover { background: rgba(220,53,69,0.2); }

.upload-file-input {
  position: absolute; inset: 0; opacity: 0; width: 100%; height: 100%;
  cursor: pointer;
}

/* ── Toggle Switch ──────────────────────────────────────────── */
.toggle-switch { display: inline-flex; align-items: center; cursor: pointer; }
.toggle-switch input { display: none; }
.toggle-track {
  width: 40px; height: 22px;
  background: var(--border);
  border-radius: 999px;
  position: relative;
  transition: background 0.2s;
  display: block;
}
.toggle-thumb {
  position: absolute; top: 3px; left: 3px;
  width: 16px; height: 16px;
  background: var(--white);
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
  transition: transform 0.2s;
}
.toggle-switch input:checked + .toggle-track { background: var(--navy); }
.toggle-switch input:checked + .toggle-track .toggle-thumb { transform: translateX(18px); }

/* ── Integration Cards ──────────────────────────────────────── */
.integration-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.integration-card-head {
  display: flex; align-items: center; gap: 1rem;
  padding: 1.125rem 1.25rem;
}

.integration-logo {
  width: 44px; height: 44px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.integration-logo--google { background: #f8f9fa; border: 1px solid #e8eaed; }
.integration-logo--aws    { background: #1a1a2e; }

.integration-info { min-width: 0; }
.integration-name { font-family: var(--font-head); font-size: 0.9375rem; font-weight: 600; color: var(--navy); margin: 0 0 2px; }
.integration-desc { font-size: 0.8125rem; color: var(--muted); margin: 0; line-height: 1.5; }

.integration-fields {
  border-top: 1px solid var(--border);
  padding: 1.25rem;
  background: var(--bg);
}

.integration-note {
  display: flex; align-items: flex-start; gap: 0.5rem;
  font-size: 0.8125rem; color: var(--muted);
  background: rgba(2,19,62,0.04); border-radius: var(--radius-md);
  padding: 0.625rem 0.875rem; margin-top: 0.875rem;
}
.integration-note svg { flex-shrink: 0; margin-top: 1px; color: #0891b2; }
.integration-note code { font-size: 0.75rem; color: var(--navy); word-break: break-all; }

.integration-actions {
  display: flex; gap: 0.75rem; align-items: center;
  margin-top: 1.25rem;
}

/* ── Field grids ────────────────────────────────────────────── */
.field-grid   { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.field-grid--3 { grid-template-columns: 1fr 1fr 1fr; }

/* ── Secret reveal ──────────────────────────────────────────── */
.input-reveal-wrap { position: relative; }
.input-reveal-wrap .form-control { padding-right: 2.5rem; }
.input-reveal-btn {
  position: absolute; right: 10px; top: 50%; transform: translateY(-50%);
  background: none; border: none; cursor: pointer; color: var(--muted); padding: 0;
  display: flex; align-items: center;
  transition: color 0.12s;
}
.input-reveal-btn:hover { color: var(--navy); }

/* ── Button variants ────────────────────────────────────────── */
.btn { display: inline-flex; align-items: center; gap: 0.375rem; font-family: var(--font-body); font-size: 0.875rem; font-weight: 500; border-radius: var(--radius-md); border: 1px solid transparent; padding: 0.5rem 1.125rem; cursor: pointer; transition: background 0.12s, border-color 0.12s, color 0.12s; text-decoration: none; }
.btn--sm { font-size: 0.8125rem; padding: 0.4rem 0.875rem; }
.btn-primary { background: var(--navy); color: var(--white); border-color: var(--navy); }
.btn-primary:hover { background: #0a1f54; }
.btn-outline { background: var(--white); color: var(--text); border-color: var(--border); }
.btn-outline:hover { background: var(--bg); border-color: rgba(2,19,62,0.2); }
.btn:disabled { opacity: 0.6; cursor: not-allowed; }

@media (max-width: 900px) {
  .settings-section { grid-template-columns: 1fr; gap: 1rem; }
  .field-grid   { grid-template-columns: 1fr; }
  .field-grid--3 { grid-template-columns: 1fr; }
}

/* ── Page Header ────────────────────────────────────────────── */
.page-header {
  display: flex; align-items: flex-start; justify-content: space-between;
  gap: 1rem; margin-bottom: 1.5rem;
}
.page-title { font-family: var(--font-head); font-size: 1.375rem; font-weight: 700; color: var(--navy); margin: 0 0 0.25rem; }
.page-sub   { font-size: 0.875rem; color: var(--muted); margin: 0; }

/* ── Settings Layout ────────────────────────────────────────── */
.settings-wrap { background: var(--white); border-radius: var(--radius-lg); border: 1px solid rgba(203,203,203,0.4); box-shadow: var(--shadow-sm); overflow: hidden; }

.settings-tabs {
  display: flex; gap: 0;
  border-bottom: 1px solid var(--border);
  padding: 0 1.5rem;
  background: var(--white);
}

.settings-tab {
  display: flex; align-items: center; gap: 0.5rem;
  padding: 0.875rem 1rem;
  font-size: 0.875rem; font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  transition: color 0.12s, border-color 0.12s;
  white-space: nowrap;
}
.settings-tab:hover   { color: var(--navy); }
.settings-tab.active  { color: var(--navy); border-bottom-color: var(--navy); }
.settings-tab svg     { opacity: 0.6; }
.settings-tab.active svg { opacity: 1; }

.settings-body { padding: 2rem 2rem 1.5rem; }

.settings-section { display: grid; grid-template-columns: 280px 1fr; gap: 2rem; align-items: start; padding: 1.25rem 0; }
.settings-section-head {}
.settings-section-title { font-family: var(--font-head); font-size: 0.9375rem; font-weight: 600; color: var(--navy); margin: 0 0 0.375rem; }
.settings-section-desc  { font-size: 0.8125rem; color: var(--muted); line-height: 1.6; margin: 0; }
.settings-divider { height: 1px; background: var(--border); margin: 0.5rem 0; }
.settings-actions { display: flex; gap: 0.75rem; justify-content: flex-end; padding-top: 1.5rem; border-top: 1px solid var(--border); margin-top: 1.5rem; }

/* ── Upload Zone ────────────────────────────────────────────── */
.settings-upload-zone {
  border: 2px dashed var(--border);
  border-radius: var(--radius-lg);
  min-height: 140px;
  display: flex; align-items: center; justify-content: center;
  position: relative;
  background: var(--bg);
  transition: border-color 0.15s, background 0.15s;
  overflow: hidden;
}
.settings-upload-zone:hover,
.settings-upload-zone.drag-over { border-color: var(--navy); background: rgba(2,19,62,0.03); }
.settings-upload-zone--square { width: 140px; min-height: 140px; }

.settings-upload-empty {
  display: flex; flex-direction: column; align-items: center; gap: 0.5rem;
  text-align: center; padding: 1.5rem; color: var(--muted);
}
.settings-upload-empty p   { font-size: 0.875rem; margin: 0; }
.settings-upload-empty svg { opacity: 0.4; }
.upload-browse-link { color: var(--navy); font-weight: 600; cursor: pointer; text-decoration: underline; }
.upload-hint { font-size: 0.75rem; color: var(--muted); }

.settings-upload-preview {
  width: 100%; height: 100%;
  min-height: 138px;
  display: flex; align-items: center; justify-content: center;
  position: relative; padding: 0.5rem;
}
.settings-upload-img { max-width: 100%; max-height: 120px; object-fit: contain; border-radius: 6px; }

.settings-upload-remove {
  position: absolute; top: 8px; right: 8px;
  width: 24px; height: 24px;
  background: rgba(220,53,69,0.1); border: none; border-radius: 50%;
  color: var(--danger); cursor: pointer; font-size: 0.75rem;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.12s;
}
.settings-upload-remove:hover { background: rgba(220,53,69,0.2); }

.upload-file-input {
  position: absolute; inset: 0; opacity: 0; width: 100%; height: 100%;
  cursor: pointer;
}

/* ── Toggle Switch ──────────────────────────────────────────── */
.toggle-switch { display: inline-flex; align-items: center; cursor: pointer; }
.toggle-switch input { display: none; }
.toggle-track {
  width: 40px; height: 22px;
  background: var(--border);
  border-radius: 999px;
  position: relative;
  transition: background 0.2s;
  display: block;
}
.toggle-thumb {
  position: absolute; top: 3px; left: 3px;
  width: 16px; height: 16px;
  background: var(--white);
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
  transition: transform 0.2s;
}
.toggle-switch input:checked + .toggle-track { background: var(--navy); }
.toggle-switch input:checked + .toggle-track .toggle-thumb { transform: translateX(18px); }

/* ── Integration Cards ──────────────────────────────────────── */
.integration-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.integration-card-head {
  display: flex; align-items: center; gap: 1rem;
  padding: 1.125rem 1.25rem;
}

.integration-logo {
  width: 44px; height: 44px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.integration-logo--google { background: #f8f9fa; border: 1px solid #e8eaed; }
.integration-logo--aws    { background: #1a1a2e; }

.integration-info { min-width: 0; }
.integration-name { font-family: var(--font-head); font-size: 0.9375rem; font-weight: 600; color: var(--navy); margin: 0 0 2px; }
.integration-desc { font-size: 0.8125rem; color: var(--muted); margin: 0; line-height: 1.5; }

.integration-fields {
  border-top: 1px solid var(--border);
  padding: 1.25rem;
  background: var(--bg);
}

.integration-note {
  display: flex; align-items: flex-start; gap: 0.5rem;
  font-size: 0.8125rem; color: var(--muted);
  background: rgba(2,19,62,0.04); border-radius: var(--radius-md);
  padding: 0.625rem 0.875rem; margin-top: 0.875rem;
}
.integration-note svg { flex-shrink: 0; margin-top: 1px; color: #0891b2; }
.integration-note code { font-size: 0.75rem; color: var(--navy); word-break: break-all; }

.integration-actions {
  display: flex; gap: 0.75rem; align-items: center;
  margin-top: 1.25rem;
}

/* ── Field grids ────────────────────────────────────────────── */
.field-grid   { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.field-grid--3 { grid-template-columns: 1fr 1fr 1fr; }

/* ── Secret reveal ──────────────────────────────────────────── */
.input-reveal-wrap { position: relative; }
.input-reveal-wrap .form-control { padding-right: 2.5rem; }
.input-reveal-btn {
  position: absolute; right: 10px; top: 50%; transform: translateY(-50%);
  background: none; border: none; cursor: pointer; color: var(--muted); padding: 0;
  display: flex; align-items: center;
  transition: color 0.12s;
}
.input-reveal-btn:hover { color: var(--navy); }

/* ── Button variants ────────────────────────────────────────── */
.btn { display: inline-flex; align-items: center; gap: 0.375rem; font-family: var(--font-body); font-size: 0.875rem; font-weight: 500; border-radius: var(--radius-md); border: 1px solid transparent; padding: 0.5rem 1.125rem; cursor: pointer; transition: background 0.12s, border-color 0.12s, color 0.12s; text-decoration: none; }
.btn--sm { font-size: 0.8125rem; padding: 0.4rem 0.875rem; }
.btn-primary { background: var(--navy); color: var(--white); border-color: var(--navy); }
.btn-primary:hover { background: #0a1f54; }
.btn-outline { background: var(--white); color: var(--text); border-color: var(--border); }
.btn-outline:hover { background: var(--bg); border-color: rgba(2,19,62,0.2); }
.btn:disabled { opacity: 0.6; cursor: not-allowed; }

@media (max-width: 900px) {
  .settings-section { grid-template-columns: 1fr; gap: 1rem; }
  .field-grid   { grid-template-columns: 1fr; }
  .field-grid--3 { grid-template-columns: 1fr; }
}

/* ── Status pill colour modifiers ───────────────────────────── */
.status-pill--active   { --pill-color: #16a34a; }
.status-pill--inactive { --pill-color: #9ca3af; }
.status-pill--draft    { --pill-color: #d97706; }

/* ── Sidebar: Pin Button ────────────────────────────────────── */
.pin-btn {
  display: none;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-left: auto;
  width: 20px; height: 20px;
  border: none;
  background: transparent;
  cursor: pointer;
  color: #9ca3af;
  border-radius: 4px;
  padding: 0;
  transition: color 0.12s, background 0.12s;
  line-height: 1;
}
.pin-btn:hover { color: var(--navy); background: rgba(2,19,62,0.07); }
.pin-btn.pinned { display: flex; color: var(--teal-dark); }
.sidebar-item:hover .pin-btn { display: flex; }
.sidebar-item .sidebar-item-label {
  flex: 1; min-width: 0;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

/* ── Access Control: Section & Table ───────────────────────── */
.ac-section { padding: 1.5rem; }
.ac-section-head {
  display: flex; align-items: flex-start;
  justify-content: space-between; gap: 1rem;
  margin-bottom: 1.25rem;
}
.ac-section-title { font-size: 1rem; font-weight: 600; color: var(--navy); margin: 0 0 0.25rem; }
.ac-section-desc  { font-size: 0.8125rem; color: var(--muted); margin: 0; }
.ac-muted         { color: var(--muted); font-size: 0.8125rem; }

.ac-table { width: 100%; border-collapse: collapse; font-size: 0.8125rem; }
.ac-table thead th {
  padding: 0.6rem 1rem;
  text-align: left;
  font-size: 0.6875rem; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.05em;
  color: var(--muted);
  border-bottom: 1px solid var(--border);
  background: var(--bg);
  white-space: nowrap;
}
.ac-table tbody td {
  padding: 0.875rem 1rem;
  border-bottom: 1px solid rgba(0,0,0,0.05);
  vertical-align: middle;
}
.ac-table tbody tr:last-child td { border-bottom: none; }
.ac-table tbody tr:hover { background: rgba(2,19,62,0.02); }
.ac-table tbody td strong { font-weight: 600; color: var(--text); }

.ac-code {
  font-family: 'Courier New', Courier, monospace;
  font-size: 0.75rem; font-weight: 600;
  color: var(--navy);
  background: rgba(2,19,62,0.06);
  padding: 2px 7px; border-radius: 4px;
  white-space: nowrap;
}

.ac-pill {
  display: inline-flex; align-items: center;
  padding: 0.2rem 0.625rem;
  font-size: 0.6875rem; font-weight: 500;
  border-radius: 999px; white-space: nowrap;
  margin: 2px;
}
.ac-pill--blue  { background: rgba(59,130,246,0.1);  color: #1d4ed8; }
.ac-pill--teal  { background: rgba(7,255,195,0.12);  color: #059669; }
.ac-pill--gray  { background: var(--bg); color: var(--text); border: 1px solid var(--border); }
.ac-pill--red   { background: rgba(220,53,69,0.1);   color: var(--danger); }
.ac-pill--amber { background: rgba(217,119,6,0.1);   color: #b45309; }

.ac-actions { display: flex; gap: 0.5rem; align-items: center; white-space: nowrap; }
.ac-empty   { text-align: center; padding: 2.5rem 1rem; color: var(--muted); font-style: italic; font-size: 0.875rem; }

.ac-row-actions {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.25rem;
  white-space: nowrap;
}
.ac-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: none;
  background: transparent;
  border-radius: 6px;
  color: var(--muted);
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s, color 0.15s;
  padding: 0;
  flex-shrink: 0;
}
.ac-action-btn:hover {
  background: rgba(2,19,62,0.07);
  color: var(--navy);
}
.ac-action-btn svg { display: block; }

/* Nav item visibility toggle */
.ac-visibility-toggle {
  display: inline-flex; align-items: center; gap: 0.35rem;
  padding: 0.25rem 0.6rem; border-radius: 20px; font-size: 0.75rem;
  font-weight: 600; cursor: pointer; border: 1.5px solid transparent;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  white-space: nowrap;
}
.ac-visibility-toggle--on {
  background: rgba(7,255,195,0.12); color: #059669;
  border-color: rgba(7,255,195,0.35);
}
.ac-visibility-toggle--on:hover {
  background: rgba(7,255,195,0.22); border-color: #07ffc3;
}
.ac-visibility-toggle--off {
  background: rgba(0,0,0,0.04); color: var(--muted);
  border-color: var(--border);
}
.ac-visibility-toggle--off:hover {
  background: rgba(7,255,195,0.08); color: #059669;
  border-color: rgba(7,255,195,0.25);
}

.btn--danger {
  background: transparent; color: var(--danger);
  border-color: rgba(220,53,69,0.35);
}
.btn--danger:hover { background: rgba(220,53,69,0.06); border-color: var(--danger); }

/* ── Access Control: Modals ─────────────────────────────────── */
.ac-modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.35);
  display: flex; align-items: center; justify-content: center;
  z-index: 1000;
}
.ac-modal-overlay[hidden] { display: none; }
.ac-modal {
  background: var(--white);
  border-radius: var(--radius-lg);
  box-shadow: 0 8px 32px rgba(0,0,0,0.18);
  width: 480px; max-width: 95vw; max-height: 90vh;
  display: flex; flex-direction: column;
  overflow: hidden;
}
.ac-modal--wide { width: 680px; }
.ac-modal--xl   { width: min(860px, 94vw); }

/* Icon picker */
.icon-picker-wrap { border: 1.5px solid var(--border); border-radius: var(--radius-md); overflow: hidden; display: flex; flex-direction: column; max-height: 320px; }
.icon-picker-search-row { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--border); background: var(--bg); flex-shrink: 0; }
.icon-picker-search-row .form-control { margin: 0; flex: 1; height: 34px; font-size: 0.8rem; }
.icon-picker-selected-preview { width: 36px; height: 36px; border-radius: 8px; background: var(--navy); color: #fff; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.icon-picker-selected-preview svg { color: #fff; }
.icon-picker { display: grid; grid-template-columns: repeat(auto-fill, minmax(72px, 1fr)); gap: 4px; padding: 10px; overflow-y: auto; flex: 1; background: var(--white); min-height: 0; }
.icon-picker-btn { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: 8px 4px; border-radius: 8px; border: 1.5px solid transparent; background: none; cursor: pointer; color: var(--muted); transition: all 0.12s; min-width: 0; }
.icon-picker-btn:hover { background: var(--bg); border-color: var(--border); color: var(--navy); }
.icon-picker-btn.selected { background: var(--navy); border-color: var(--navy); color: #fff; }
.icon-picker-btn.selected svg { stroke: #fff; }
.icon-picker-label { font-size: 0.6rem; line-height: 1; text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 64px; }
.icon-picker-btn[hidden] { display: none; }
.ac-modal-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.25rem 1.5rem 1rem;
  border-bottom: 1px solid var(--border);
}
.ac-modal-head h3 { font-size: 1rem; font-weight: 600; color: var(--navy); margin: 0; }
.ac-modal-close {
  background: none; border: none; cursor: pointer;
  color: var(--muted); font-size: 1rem; line-height: 1;
  padding: 0.3rem; border-radius: 4px;
  transition: color 0.12s, background 0.12s;
}
.ac-modal-close:hover { color: var(--danger); background: rgba(220,53,69,0.06); }
.ac-modal-body {
  padding: 1.25rem 1.5rem;
  overflow-y: auto; flex: 1;
  display: flex; flex-direction: column; gap: 1rem;
}
.ac-modal-foot {
  padding: 1rem 1.5rem;
  border-top: 1px solid var(--border);
  display: flex; justify-content: flex-end; gap: 0.75rem;
}

.ac-check-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 0.375rem;
  max-height: 240px; overflow-y: auto;
  padding: 0.75rem;
  background: var(--bg);
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
}
.ac-check-item {
  display: flex; align-items: flex-start; gap: 0.5rem;
  cursor: pointer; padding: 0.4rem 0.5rem;
  border-radius: var(--radius-sm);
  font-size: 0.8125rem; transition: background 0.1s;
}
.ac-check-item:hover { background: rgba(2,19,62,0.04); }
.ac-check-item input { margin-top: 2px; accent-color: var(--navy); flex-shrink: 0; }
.ac-check-item strong { display: block; font-weight: 500; color: var(--text); }
.ac-check-item em { font-style: normal; color: var(--muted); font-size: 0.75rem; }
.ac-check-item--sm { padding: 0.25rem 0.375rem; }

.ac-perm-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1rem;
  max-height: 360px; overflow-y: auto;
}
.ac-perm-module {
  background: var(--bg); border: 1px solid var(--border);
  border-radius: var(--radius-md); padding: 0.75rem;
}
.ac-perm-module-label {
  font-size: 0.6875rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.05em;
  color: var(--navy); margin: 0 0 0.5rem;
}

/* ── Access Control: Module filter tabs (Navigation tab) ────── */
.ac-module-tabs {
  display: flex; gap: 0.25rem; flex-wrap: wrap;
  padding: 0 1.5rem 1.25rem;
  border-bottom: 1px solid var(--border);
}
.ac-module-tab {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.375rem 0.875rem;
  font-size: 0.8125rem; font-weight: 500;
  color: #6b7280;
  border: 1px solid transparent;
  border-radius: 999px;
  text-decoration: none;
  transition: color 0.12s, background 0.12s, border-color 0.12s;
  white-space: nowrap;
}
.ac-module-tab svg { opacity: 0.55; flex-shrink: 0; transition: opacity 0.12s; }
.ac-module-tab:hover { color: var(--navy); background: rgba(2,19,62,0.04); }
.ac-module-tab:hover svg { opacity: 0.8; }
.ac-module-tab.active {
  color: var(--navy); font-weight: 600;
  background: rgba(2,19,62,0.07);
  border-color: rgba(2,19,62,0.18);
}
.ac-module-tab.active svg { opacity: 1; }

/* ── Access Control: Icon preview cell ──────────────────────── */
.ac-icon-preview {
  display: inline-flex; align-items: center;
  color: var(--text); opacity: 0.75;
}

/* ── Access Control: navy pill variant ──────────────────────── */
.ac-pill--navy { background: rgba(2,19,62,0.08); color: var(--navy); }

/* Give table some breathing room after the module tabs */
.ac-module-tabs + .ac-table { margin-top: 0; }
.ac-section .ac-module-tabs { margin: 0 -1.5rem 0; padding: 0 1.5rem 1.25rem; }

/* ── Users Page ─────────────────────────────────────────────── */
.users-filter-bar {
  display: flex; align-items: center; gap: 0.625rem; flex-wrap: wrap;
}
.search-wrap { position: relative; flex: 1; min-width: 200px; max-width: 340px; }
.search-icon { position: absolute; left: 0.75rem; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.search-input { padding-left: 2.375rem; }
.filter-select { min-width: 140px; width: auto; }

.user-avatar-row { display: flex; align-items: center; gap: 0.625rem; }
.user-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--navy); color: #fff;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 0.75rem; font-weight: 700; flex-shrink: 0;
}

.status-pill--pending   { --pill-color: #d97706; }
.status-pill--suspended { --pill-color: #dc2626; }
.btn-ghost { background: transparent; color: var(--muted); border-color: transparent; }
.btn-ghost:hover { background: var(--bg); color: var(--text); }

/* ── Permissions pagination ────────────────────────────────── */
.ac-table-meta { padding: 0.5rem 1.5rem 0.75rem; }
.ac-pagination { display: flex; align-items: center; gap: 0.25rem; padding: 1rem 1.5rem; flex-wrap: wrap; }
.ac-page-btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 2rem; height: 2rem; padding: 0 0.5rem;
  font-size: 0.8125rem; font-weight: 500; color: var(--text);
  border: 1px solid var(--border); border-radius: 6px;
  text-decoration: none; transition: background 0.12s, color 0.12s, border-color 0.12s;
  white-space: nowrap;
}
.ac-page-btn:hover { background: rgba(2,19,62,0.05); border-color: rgba(2,19,62,0.2); color: var(--navy); }
.ac-page-btn--active { background: var(--navy); color: #fff; border-color: var(--navy); font-weight: 600; }
.ac-page-btn--active:hover { background: var(--navy-light); border-color: var(--navy-light); color: #fff; }
.ac-page-btn--disabled { color: var(--muted); pointer-events: none; opacity: 0.45; }
.ac-page-ellipsis { display: inline-flex; align-items: center; padding: 0 0.25rem; color: var(--muted); font-size: 0.8125rem; }

.ac-pagination-row { display: flex; align-items: center; justify-content: space-between; padding: 0.75rem 1.5rem; gap: 1rem; flex-wrap: wrap; border-top: 1px solid var(--border); }
.ac-pag-count { font-size: 0.8125rem; }
.ac-pagination-row .ac-pagination { padding: 0; border-top: none; }

/* ── Permissions toolbar (search + bulk) ──────────────────── */
.ac-perm-toolbar { display: flex; align-items: center; gap: 0.75rem; padding: 0 1.5rem 1rem; flex-wrap: wrap; }
.ac-perm-search-form { display: flex; align-items: center; gap: 0.5rem; flex: 1; min-width: 0; }
.ac-bulk-bar { display: flex; align-items: center; gap: 0.625rem; }
.ac-bulk-count { font-size: 0.8125rem; font-weight: 600; color: var(--navy); }

/* ── Profile Page ─────────────────────────────────────────── */
.profile-layout { display: grid; grid-template-columns: 240px 1fr; gap: 1.5rem; align-items: start; }
@media (max-width: 768px) { .profile-layout { grid-template-columns: 1fr; } }

/* Avatar card */
.profile-avatar-card {
  background: var(--white); border: 1px solid var(--border); border-radius: 12px;
  padding: 1.75rem 1.25rem; text-align: center; display: flex; flex-direction: column;
  align-items: center; gap: 0.5rem; position: sticky; top: 1rem;
}
.profile-avatar-wrap { margin-bottom: 0.25rem; }
.profile-avatar-circle {
  width: 72px; height: 72px; border-radius: 50%;
  background: var(--navy); color: #fff;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 1.75rem; font-weight: 700; font-family: 'Poppins', sans-serif;
}
.profile-avatar-name  { font-size: 1rem; font-weight: 600; color: var(--text); }
.profile-avatar-email { font-size: 0.8125rem; color: var(--muted); word-break: break-all; }
.profile-avatar-roles { display: flex; flex-wrap: wrap; gap: 0.3rem; justify-content: center; margin-top: 0.25rem; }
.profile-avatar-meta  { display: flex; flex-direction: column; gap: 0.25rem; font-size: 0.75rem; color: var(--muted); margin-top: 0.5rem; }

/* Panels */
.profile-panels { min-width: 0; }
.profile-tabs {
  display: flex; gap: 0.125rem;
  border-bottom: 2px solid var(--border);
  margin-bottom: 1.5rem;
}
.profile-tab {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.625rem 1rem; font-size: 0.875rem; font-weight: 500;
  color: var(--muted); text-decoration: none; border-bottom: 2px solid transparent;
  margin-bottom: -2px; transition: color 0.12s, border-color 0.12s;
  white-space: nowrap;
}
.profile-tab svg { opacity: 0.6; transition: opacity 0.12s; }
.profile-tab:hover { color: var(--text); }
.profile-tab.active { color: var(--navy); border-bottom-color: var(--navy); font-weight: 600; }
.profile-tab.active svg { opacity: 1; }

.profile-panel {
  background: var(--white); border: 1px solid var(--border); border-radius: 12px; overflow: hidden;
}
.profile-panel-head { padding: 1.5rem 1.5rem 1.25rem; border-bottom: 1px solid var(--border); }
.profile-panel-head h2 { font-size: 1rem; font-weight: 600; color: var(--text); margin: 0 0 0.2rem; }
.profile-panel-head p  { font-size: 0.8125rem; color: var(--muted); margin: 0; }
.profile-form { padding: 1.5rem; display: flex; flex-direction: column; gap: 1.25rem; }
.profile-form-foot { display: flex; justify-content: flex-end; padding-top: 0.5rem; }

/* Password strength */
.pw-strength-wrap { display: flex; align-items: center; gap: 0.75rem; }
.pw-strength-bar { flex: 1; height: 5px; background: var(--border); border-radius: 99px; overflow: hidden; }
.pw-strength-fill { height: 100%; border-radius: 99px; transition: width 0.2s, background 0.2s; width: 0; }
.pw-strength-label { font-size: 0.75rem; font-weight: 600; min-width: 70px; }

/* ── Applicant Dashboard ───────────────────────────────────── */

/* Hero banner */
.apd-hero {
  position: relative; overflow: hidden;
  background: linear-gradient(135deg, var(--navy) 0%, #0d2260 60%, #0a3060 100%);
  border-radius: 16px; padding: 2.5rem 2rem 2.5rem 2.5rem;
  display: flex; align-items: center; justify-content: space-between;
  gap: 1.5rem; margin-bottom: 1.5rem;
  min-height: 200px;
}
.apd-hero-content { flex: 1; min-width: 0; position: relative; z-index: 1; }
.apd-hero-date {
  font-size: 0.8rem; font-weight: 500; letter-spacing: 0.04em;
  color: rgba(255,255,255,0.5); margin-bottom: 0.5rem;
}
.apd-hero-title {
  font-family: 'Poppins', sans-serif;
  font-size: clamp(1.5rem, 3vw, 2.125rem);
  font-weight: 700; color: #fff; line-height: 1.15; margin-bottom: 0.4rem;
}
.apd-hero-sub {
  font-size: 1rem; color: rgba(255,255,255,0.65); margin-bottom: 1.5rem; font-weight: 400;
}
.apd-cta {
  display: inline-flex; align-items: center; gap: 0.5rem;
  background: var(--teal); color: var(--navy);
  padding: 0.625rem 1.375rem; border-radius: 8px;
  font-weight: 700; font-size: 0.9rem; text-decoration: none;
  border: none; cursor: pointer; transition: background 0.15s, transform 0.12s;
}
.apd-cta:hover { background: var(--teal-dark); transform: translateY(-1px); }
.apd-cta--outline {
  background: transparent; color: var(--teal);
  border: 1.5px solid rgba(7,255,195,0.45);
}
.apd-cta--outline:hover { background: rgba(7,255,195,0.08); }
.apd-hero-status-row {
  display: flex; align-items: center; gap: 0.75rem; margin-bottom: 1.25rem;
}
.apd-hero-status-pill {
  display: inline-block; padding: 0.25rem 0.75rem; border-radius: 99px;
  background: rgba(255,255,255,0.12); color: #fff;
  font-size: 0.75rem; font-weight: 600; letter-spacing: 0.04em;
  border: 1px solid rgba(255,255,255,0.2);
}
.apd-hero-app-no {
  font-size: 0.8rem; color: rgba(255,255,255,0.45); font-family: monospace;
}

/* Decorative circles inside hero */
.apd-hero-deco {
  position: relative; width: 180px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
}
.apd-hero-svg { position: relative; z-index: 1; opacity: 0.9; }
.apd-circle {
  position: absolute; border-radius: 50%; pointer-events: none;
}
.apd-circle--1 {
  width: 200px; height: 200px;
  background: radial-gradient(circle, rgba(7,255,195,0.12) 0%, transparent 70%);
  top: -60px; right: -60px;
}
.apd-circle--2 {
  width: 120px; height: 120px;
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.08);
  bottom: -40px; left: 0;
}
.apd-circle--3 {
  width: 60px; height: 60px;
  background: rgba(7,255,195,0.08);
  top: 10px; left: 10px;
}
@media (max-width: 640px) { .apd-hero-deco { display: none; } }

/* Cards */
.apd-card {
  background: var(--white); border: 1px solid var(--border);
  border-radius: 14px; overflow: hidden; margin-bottom: 1.5rem;
}
.apd-card--steps { }
.apd-card-head {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem;
  padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--border);
}
.apd-card-title { font-size: 0.9375rem; font-weight: 600; color: var(--text); margin: 0; }
.apd-card-sub   { font-size: 0.8125rem; color: var(--muted); margin: 0.2rem 0 0; }

/* Status tracker */
.apd-tracker {
  display: flex; align-items: flex-start; padding: 1.5rem 1.75rem;
  gap: 0; overflow-x: auto;
}
.apd-tracker-step {
  display: flex; flex-direction: column; align-items: center;
  position: relative; flex: 1; min-width: 80px;
}
.apd-tracker-node {
  width: 28px; height: 28px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  position: relative; z-index: 1; flex-shrink: 0;
  background: var(--border); color: var(--muted);
  border: 2px solid var(--border);
}
.apd-tracker-step--done    .apd-tracker-node { background: var(--navy); border-color: var(--navy); color: #fff; }
.apd-tracker-step--current .apd-tracker-node { background: var(--white); border-color: var(--teal-dark); color: var(--teal-dark); }
.apd-tracker-step--rejected .apd-tracker-node { background: #dc2626; border-color: #dc2626; color: #fff; }
.apd-tracker-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--teal-dark); animation: tracker-pulse 1.6s ease-in-out infinite;
}
.apd-tracker-dot--empty { background: var(--border); animation: none; }
@keyframes tracker-pulse {
  0%,100% { transform: scale(1); opacity: 1; }
  50%      { transform: scale(1.4); opacity: 0.7; }
}
.apd-tracker-line {
  position: absolute; top: 14px; left: calc(50% + 14px);
  height: 2px; right: calc(-50% + 14px);
  background: var(--border); z-index: 0;
}
.apd-tracker-line--done { background: var(--navy); }

/* Kebab / vertical-dot menu on tracker card */
.apd-kebab-wrap { position: relative; }
.apd-kebab-btn {
  display: flex; align-items: center; justify-content: center;
  width: 32px; height: 32px; border-radius: 6px;
  border: 1.5px solid var(--border); background: var(--white);
  color: var(--text-muted); cursor: pointer; transition: background 0.15s, border-color 0.15s;
}
.apd-kebab-btn:hover { background: #F4F6FA; border-color: #C8D0DC; color: var(--text); }
.apd-kebab-menu {
  position: absolute; top: calc(100% + 6px); right: 0; z-index: 200;
  background: var(--white); border: 1.5px solid var(--border);
  border-radius: 10px; box-shadow: 0 6px 24px rgba(0,0,0,0.10);
  min-width: 210px; padding: 4px;
}
.apd-kebab-item {
  display: flex; align-items: center; gap: 9px; width: 100%;
  padding: 9px 12px; border: none; background: none; border-radius: 7px;
  font-size: 0.875rem; color: var(--text); cursor: pointer; text-align: left;
  transition: background 0.12s;
}
.apd-kebab-item:hover { background: #F4F6FA; }
.apd-kebab-item--danger { color: #DC2626; }
.apd-kebab-item--danger:hover { background: #FEF2F2; }
.apd-kebab-divider { height: 1px; background: var(--border); margin: 3px 0; }

.apd-tracker-label {
  font-size: 0.7rem; color: var(--muted); margin-top: 0.5rem;
  text-align: center; white-space: nowrap;
}
.apd-tracker-step--done    .apd-tracker-label { color: var(--navy); font-weight: 600; }
.apd-tracker-step--current .apd-tracker-label { color: var(--teal-dark); font-weight: 600; }

/* Remark / notice */
.apd-remark {
  display: flex; align-items: flex-start; gap: 0.5rem;
  margin: 0 1.5rem 1.25rem; padding: 0.75rem 1rem;
  background: rgba(2,19,62,0.04); border: 1px solid rgba(2,19,62,0.1);
  border-radius: 8px; font-size: 0.8125rem; color: var(--muted);
}
.apd-remark svg { flex-shrink: 0; margin-top: 1px; }

/* Quick link grid */
.apd-quick-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem; margin-bottom: 1.5rem;
}
@media (max-width: 900px)  { .apd-quick-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px)  { .apd-quick-grid { grid-template-columns: 1fr; } }

.apd-quick-card {
  display: flex; flex-direction: column; gap: 0.75rem;
  padding: 1.25rem 1.25rem 1rem;
  border-radius: 14px; border: 1px solid transparent;
  text-decoration: none; transition: transform 0.14s, box-shadow 0.14s;
  position: relative; overflow: hidden;
}
.apd-quick-card:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(2,19,62,0.1); }
.apd-quick-card--teal  { background: rgba(7,255,195,0.08);  border-color: rgba(7,255,195,0.25); }
.apd-quick-card--blue  { background: rgba(8,145,178,0.07);  border-color: rgba(8,145,178,0.2); }
.apd-quick-card--amber { background: rgba(217,119,6,0.07);  border-color: rgba(217,119,6,0.2); }
.apd-quick-card--navy  { background: rgba(2,19,62,0.05);    border-color: rgba(2,19,62,0.15); }

.apd-quick-icon {
  width: 40px; height: 40px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
}
.apd-quick-card--teal  .apd-quick-icon { background: rgba(7,255,195,0.2);  color: #059669; }
.apd-quick-card--blue  .apd-quick-icon { background: rgba(8,145,178,0.15); color: #0891b2; }
.apd-quick-card--amber .apd-quick-icon { background: rgba(217,119,6,0.12); color: #d97706; }
.apd-quick-card--navy  .apd-quick-icon { background: rgba(2,19,62,0.1);    color: var(--navy); }

.apd-quick-label {
  font-size: 0.875rem; font-weight: 600; color: var(--text); flex: 1;
}
.apd-quick-arrow { color: var(--muted); margin-top: auto; }

/* How-to steps */
.apd-steps {
  display: flex; flex-direction: column; gap: 0; padding: 0.5rem 0;
}
.apd-step {
  display: flex; align-items: flex-start; gap: 1rem;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--border);
}
.apd-step:last-child { border-bottom: none; }
.apd-step-num {
  width: 28px; height: 28px; border-radius: 50%; flex-shrink: 0;
  background: var(--navy); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.75rem; font-weight: 700; font-family: 'Poppins', sans-serif;
}
.apd-step-body {
  display: flex; flex-direction: column; gap: 0.15rem; padding-top: 0.2rem;
}
.apd-step-body strong { font-size: 0.875rem; font-weight: 600; color: var(--text); }
.apd-step-body span   { font-size: 0.8125rem; color: var(--muted); line-height: 1.5; }

/* ═══════════════════════════════════════════════════════════════
   PROGRAMS — listing page
   ═══════════════════════════════════════════════════════════════ */
.prog-filter-bar {
  display: flex; align-items: center; gap: 0.625rem;
  margin-bottom: 1.25rem; flex-wrap: wrap;
}
.prog-search-wrap {
  position: relative; flex: 1; min-width: 200px;
}
.prog-search-icon {
  position: absolute; left: 0.75rem; top: 50%; transform: translateY(-50%);
  color: var(--muted); pointer-events: none;
}
.prog-search-input { padding-left: 2.25rem !important; }
.prog-filter-select { width: auto; min-width: 130px; }

.prog-code {
  font-size: 0.75rem; font-family: ui-monospace, monospace;
  background: rgba(2,19,62,0.06); color: var(--navy);
  padding: 0.15rem 0.5rem; border-radius: 4px; letter-spacing: 0.03em;
}
.prog-applicant-count {
  font-weight: 600; font-size: 0.875rem; color: var(--navy);
}

.status-pill {
  display: inline-block;
  padding: 0.2rem 0.625rem; border-radius: 99px;
  font-size: 0.72rem; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase;
}
.status-pill--active   { background: rgba(7,255,195,0.14); color: #059669; }
.status-pill--inactive { background: rgba(108,117,125,0.12); color: var(--muted); }

/* ═══════════════════════════════════════════════════════════════
   CREATE / EDIT PROGRAM — tabs + form
   ═══════════════════════════════════════════════════════════════ */
.cp-back-link {
  display: inline-flex; align-items: center; gap: 0.35rem;
  font-size: 0.8125rem; color: var(--muted); text-decoration: none;
  margin-bottom: 0.35rem; transition: color 0.12s;
}
.cp-back-link:hover { color: var(--navy); }

/* Tabs bar */
.cp-tabs-wrap {
  border-bottom: 1px solid var(--border);
  margin-bottom: 1.5rem;
}
.cp-tabs {
  display: flex; gap: 0; overflow-x: auto;
}
.cp-tab {
  display: inline-flex; align-items: center; gap: 0.45rem;
  padding: 0.75rem 1.25rem;
  font-size: 0.875rem; font-weight: 500; color: var(--muted);
  text-decoration: none; white-space: nowrap;
  border-bottom: 2px solid transparent;
  transition: color 0.12s, border-color 0.12s;
  position: relative; top: 1px;
}
.cp-tab svg { opacity: 0.65; }
.cp-tab:hover { color: var(--text); }
.cp-tab.active { color: var(--navy); border-bottom-color: var(--navy); font-weight: 600; }
.cp-tab.active svg { opacity: 1; }
.cp-tab--disabled { opacity: 0.45; cursor: not-allowed; }
.cp-tab-lock { font-size: 0.65rem; }

/* Section card */
.cp-section-card {
  background: var(--white); border: 1px solid var(--border);
  border-radius: 12px; overflow: hidden; margin-bottom: 1.25rem;
}
.cp-section-head {
  padding: 1.25rem 1.5rem 1rem;
  border-bottom: 1px solid var(--border);
  background: rgba(2,19,62,0.015);
}
.cp-section-title {
  font-family: var(--font-head); font-size: 0.9375rem; font-weight: 600;
  color: var(--navy); margin: 0 0 0.2rem;
}
.cp-section-sub { font-size: 0.8125rem; color: var(--muted); margin: 0; }

/* Form grid */
.cp-form-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 1.25rem 1.5rem; padding: 1.5rem;
}
.cp-field { display: flex; flex-direction: column; gap: 0.35rem; }
.cp-field--full { grid-column: 1 / -1; }
.cp-label { font-size: 0.8125rem; font-weight: 600; color: var(--text); }
.cp-label .req { color: var(--danger); }
.cp-hint { font-size: 0.75rem; color: var(--muted); margin: 0; }

/* Prefix input */
.cp-input-prefix-wrap { position: relative; }
.cp-input-prefix {
  position: absolute; left: 0.75rem; top: 50%; transform: translateY(-50%);
  font-size: 0.875rem; color: var(--muted); pointer-events: none;
}
.cp-input-with-prefix { padding-left: 1.75rem !important; }

/* Form footer */
.cp-form-wrap { display: flex; flex-direction: column; }
.cp-form-foot {
  display: flex; justify-content: flex-end; align-items: center;
  gap: 0.625rem; padding: 1rem 1.5rem;
  background: rgba(2,19,62,0.015); border: 1px solid var(--border);
  border-radius: 12px;
}

/* Coming soon placeholder inside a tab */
.cp-coming-soon {
  display: flex; flex-direction: column; align-items: center;
  gap: 0.75rem; padding: 3.5rem 1.5rem;
  color: var(--muted); text-align: center;
}
.cp-coming-soon svg { opacity: 0.4; }
.cp-coming-soon p { margin: 0; font-size: 0.9rem; }

@media (max-width: 640px) {
  .cp-form-grid { grid-template-columns: 1fr; }
  .cp-field--full { grid-column: 1; }
}

/* ============================================================
   APPLICATION FORM (apply.php) — af-* classes
   ============================================================ */

.af-main { padding: 0 !important; display: flex; flex-direction: column; }

/* ── Hero banner ── */
.af-hero {
  background: var(--navy);
  padding: 28px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.af-hero__badge {
  display: inline-block;
  padding: 3px 12px;
  background: var(--teal);
  color: var(--navy);
  font-size: 0.72rem;
  font-weight: 700;
  border-radius: 20px;
  margin-bottom: 10px;
  letter-spacing: 0.4px;
}
.af-hero__title {
  font-family: var(--font-head);
  font-size: 1.4rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 4px;
}
.af-hero__sub { font-size: 0.82rem; color: rgba(255,255,255,0.6); }
.af-hero__icon { opacity: 0.3; flex-shrink: 0; }

/* ── Info cards grid ── */
.af-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  padding: 24px 32px;
  background: var(--bg);
}
.af-card {
  background: #fff;
  border: 1.5px solid #E8ECF1;
  border-radius: 10px;
  padding: 20px 22px;
}
.af-card__head {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-head);
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1.5px solid #E8ECF1;
}
.af-card__head svg { color: var(--teal-dark); flex-shrink: 0; }

.af-checklist { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.af-checklist li {
  display: flex; align-items: baseline; gap: 8px;
  font-size: 0.835rem; color: #212529; line-height: 1.5;
}
.af-checklist li::before {
  content: ''; width: 7px; height: 7px; border-radius: 50%;
  background: var(--teal); flex-shrink: 0; margin-top: 2px;
}
.af-checklist--warn li::before { background: #f59e0b; }
.af-checklist li span { font-size: 0.78rem; color: #6c757d; }

.af-steps-list { padding-left: 18px; display: flex; flex-direction: column; gap: 8px; }
.af-steps-list li { font-size: 0.835rem; color: #212529; line-height: 1.5; }
.af-steps-list li strong { color: var(--navy); }

/* ── Program selection card ── */
.af-select-card {
  background: #fff;
  border: 1px solid #E8ECF1;
  border-radius: 10px;
  padding: 24px 32px;
  margin: 20px 32px 0;
}

/* ── Rich-text content from DB ── */
.af-prog-content { font-size: 0.835rem; color: #374151; line-height: 1.65; }
.af-prog-content p { margin: 0 0 6px; }
.af-prog-content p:last-child { margin-bottom: 0; }
.af-prog-content ul, .af-prog-content ol { margin: 4px 0 4px 18px; padding: 0; }
.af-prog-content li { margin-bottom: 4px; }
.af-prog-content strong { font-weight: 600; }
.af-prog-content em { font-style: italic; }

/* Phone prefix (+91 flag) */
.af-phone-wrap { position: relative; display: flex; align-items: stretch; }
.af-phone-prefix {
  display: flex; align-items: center; gap: 5px; white-space: nowrap;
  padding: 0 10px; background: #F4F6FA; border: 1.5px solid var(--border);
  border-right: none; border-radius: var(--radius-md) 0 0 var(--radius-md);
  font-size: 0.875rem; font-weight: 600; color: var(--text);
  pointer-events: none; user-select: none;
}
.af-phone-wrap .form-control {
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  flex: 1; min-width: 0;
}
.af-phone-wrap .form-control:focus { z-index: 1; }
.af-phone-wrap .form-control.is-invalid + .af-phone-prefix,
.af-phone-wrap.is-invalid .af-phone-prefix { border-color: var(--danger); }

.af-btn-spinner {
  display: inline-block;
  width: 14px; height: 14px;
  border: 2px solid rgba(255,255,255,0.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: af-spin 0.7s linear infinite;
  vertical-align: middle;
  margin-right: 6px;
}
@keyframes af-spin { to { transform: rotate(360deg); } }

/* ── Action bar ── */
.af-action-bar {
  background: #fff;
  border-top: 2px solid #E8ECF1;
  padding: 18px 32px;
  position: sticky;
  bottom: 0;
  z-index: 10;
}
.af-action-bar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.af-resume { display: flex; flex-direction: column; gap: 8px; }
.af-resume__input { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

/* ── Stepper ── */
.af-stepper {
  background: #fff;
  border-bottom: 1.5px solid #E8ECF1;
  position: sticky;
  top: 0;
  z-index: 20;
  padding: 16px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.af-stepper__inner {
  display: flex;
  align-items: center;
  flex: 1;
}
.af-stepper__step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
}
.af-stepper__circle {
  width: 32px; height: 32px;
  border-radius: 50%;
  border: 2px solid #CBD5E0;
  background: #fff;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.25s;
}
.af-stepper__num { font-family: var(--font-head); font-size: 0.8rem; font-weight: 700; color: #6c757d; }
.af-stepper__check { display: none; color: #fff; }
.af-stepper__label { font-size: 0.67rem; font-weight: 600; color: #6c757d; white-space: nowrap; font-family: var(--font-head); }
.af-stepper__line { flex: 1; height: 2px; background: #E8ECF1; margin: 0 6px 18px; min-width: 16px; transition: background 0.25s; }

.af-step--active .af-stepper__circle { border-color: var(--navy); background: var(--navy); }
.af-step--active .af-stepper__num { color: #fff; }
.af-step--active .af-stepper__label { color: var(--navy); }

.af-step--done .af-stepper__circle { border-color: var(--teal-dark); background: var(--teal-dark); }
.af-step--done .af-stepper__num { display: none; }
.af-step--done .af-stepper__check { display: block; }
.af-step--done .af-stepper__label { color: var(--teal-dark); }
.af-line--done { background: var(--teal-dark) !important; }

.af-stepper__appno {
  display: flex; align-items: center; gap: 6px;
  font-size: 0.78rem; color: #6c757d;
  border-left: 1.5px solid #E8ECF1;
  padding-left: 16px; white-space: nowrap;
}
.af-stepper__appno svg { color: var(--teal-dark); }
.af-stepper__appno strong { color: var(--navy); font-family: var(--font-head); }
.af-copy-btn {
  display: inline-flex; align-items: center; justify-content: center;
  background: none; border: 1px solid #CBD5E0; border-radius: 4px;
  padding: 3px 5px; cursor: pointer; color: #6c757d;
  transition: all 0.2s; margin-left: 2px;
}
.af-copy-btn:hover { border-color: var(--navy); color: var(--navy); }

/* ── Form body ── */
.af-form-body { padding: 28px 32px 100px; }

/* ── Section cards ── */
.af-section {
  background: #fff;
  border: 1.5px solid #E8ECF1;
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 20px;
}
.af-section__head {
  display: flex; align-items: center; gap: 14px;
  padding: 16px 24px;
  background: var(--bg);
  border-bottom: 1.5px solid #E8ECF1;
}
.af-section__icon {
  width: 38px; height: 38px;
  border-radius: 8px;
  background: var(--navy);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.af-section__icon svg { color: var(--teal); }
.af-section__title {
  font-family: var(--font-head); font-size: 0.95rem; font-weight: 700;
  color: var(--navy); margin-bottom: 2px;
}
.af-section__sub { font-size: 0.78rem; color: #6c757d; }
.af-section__body { padding: 22px 24px 18px; display: flex; flex-direction: column; gap: 16px; }

/* ── Step header (steps 2–4) ── */
.af-step-header { margin-bottom: 20px; padding-bottom: 14px; border-bottom: 2px solid #E8ECF1; }
.af-step-title { font-family: var(--font-head); font-size: 1.2rem; font-weight: 800; color: var(--navy); margin-bottom: 4px; }
.af-step-sub { font-size: 0.85rem; color: #6c757d; }

/* ── Form layout ── */
.af-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.af-grid--4 { grid-template-columns: repeat(4, 1fr); }
.af-field--span2 { grid-column: span 2; }

.af-field { display: flex; flex-direction: column; gap: 5px; }
.af-label {
  font-family: var(--font-head); font-size: 0.82rem; font-weight: 600; color: var(--navy);
}
.af-label .req, .af-label span.req { color: var(--danger); }
.req { color: var(--danger); }
.af-hint { font-size: 0.75rem; color: #6c757d; margin-top: 2px; }
.af-sub-head {
  font-family: var(--font-head); font-size: 0.75rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 1px; color: var(--teal-dark);
  padding-bottom: 4px; border-bottom: 1.5px solid #E8ECF1; margin-bottom: 14px;
}
.af-field-error { font-size: 0.77rem; color: var(--danger); margin-top: 2px; }

/* ── Radio group ── */
.af-radio-group { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.af-radio {
  display: flex; align-items: center; gap: 7px;
  padding: 7px 14px; border: 1.5px solid #CBD5E0; border-radius: 6px;
  cursor: pointer; font-size: 0.84rem; color: #212529; font-weight: 500;
  transition: all 0.2s; user-select: none;
}
.af-radio input[type="radio"] { accent-color: var(--navy); width: 14px; height: 14px; }
.af-radio:has(input:checked) { border-color: var(--navy); background: rgba(2,19,62,0.05); color: var(--navy); }

/* ── Same address row ── */
.af-same-addr-row {
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px;
  background: var(--bg); border: 1.5px solid #E8ECF1; border-radius: 6px;
  padding: 12px 16px; margin-top: 4px;
}
.af-same-addr-label {
  display: flex; align-items: center; gap: 7px;
  font-size: 0.84rem; font-weight: 600; color: var(--navy); font-family: var(--font-head);
}

/* ── Academics ── */
.af-qual-head {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-head); font-size: 0.9rem; font-weight: 700; color: var(--navy);
}
.af-qual-badge {
  width: 36px; height: 36px; border-radius: 6px;
  background: var(--navy); color: var(--teal);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-head); font-size: 0.85rem; font-weight: 800; flex-shrink: 0;
}
.af-qual-badge sup { font-size: 0.55rem; }
.af-pcb-calc {
  display: flex; align-items: center; gap: 8px;
  padding: 9px 14px; background: var(--bg); border-radius: 6px;
  border: 1.5px solid #E8ECF1; font-size: 0.84rem; color: #6c757d;
}
.af-pcb-calc svg { color: var(--teal-dark); }
.af-pcb-calc strong { color: var(--navy); font-size: 0.95rem; }

/* ── Document upload blocks ── */
.af-doc-block {
  border: 1.5px solid #E8ECF1; border-radius: 10px; overflow: hidden; margin-bottom: 16px;
}
.af-doc-block__head {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 20px; background: var(--navy);
}
.af-doc-block__icon {
  width: 38px; height: 38px; flex-shrink: 0;
  border-radius: 50%; background: rgba(255,255,255,0.12);
  display: flex; align-items: center; justify-content: center;
}
.af-doc-block__icon svg { color: #fff; }
.af-doc-block__title { font-family: var(--font-head); font-size: 0.9rem; font-weight: 600; color: #fff; margin-bottom: 2px; }
.af-doc-block__sub { font-size: 0.77rem; color: rgba(255,255,255,0.65); }
.af-doc-block__body { display: grid; grid-template-columns: 1fr 260px; background: #fff; }
.af-doc-block__instructions { padding: 16px 20px; border-right: 1.5px solid #E8ECF1; }
.af-doc-specs { list-style: none; display: flex; flex-direction: column; gap: 5px; }
.af-doc-specs li {
  font-size: 0.8rem; color: #212529; padding-left: 12px;
  position: relative; line-height: 1.5;
}
.af-doc-specs li::before { content: '–'; position: absolute; left: 0; color: var(--teal-dark); }
.af-upload-col { display: flex; flex-direction: column; }
.af-upload-zone { padding: 16px; display: flex; flex-direction: column; justify-content: center; flex: 1; }
.af-upload-input { display: none; }
.af-upload-label {
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px;
  padding: 20px 14px; border: 2px dashed #CBD5E0; border-radius: 8px;
  cursor: pointer; background: var(--bg); transition: all 0.2s;
}
.af-upload-label:hover { border-color: var(--teal-dark); background: rgba(7,255,195,0.05); }
.af-upload-icon {
  width: 40px; height: 40px; border-radius: 50%;
  background: #fff; border: 1.5px solid #E8ECF1;
  display: flex; align-items: center; justify-content: center;
}
.af-upload-icon svg { color: #6c757d; }
.af-upload-label strong { font-family: var(--font-head); font-size: 0.82rem; color: var(--navy); }
.af-upload-label span { font-size: 0.73rem; color: #6c757d; }
.af-upload-label em { font-style: normal; font-size: 0.73rem; color: var(--teal-dark); font-weight: 600; }
.af-opt-badge { display: inline-block; font-size: 0.68rem; font-weight: 700; background: rgba(255,255,255,0.18); color: rgba(255,255,255,0.85); border: 1px solid rgba(255,255,255,0.3); border-radius: 4px; padding: 1px 6px; margin-left: 4px; vertical-align: middle; letter-spacing: 0.03em; }

/* File preview area (shown after upload, replaces upload zone) */
.af-file-preview {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 12px;
  min-height: 140px;
}
.af-preview-img {
  max-width: 100%;
  max-height: 140px;
  width: auto;
  border-radius: 6px;
  object-fit: contain;
  border: 1.5px solid #E8ECF1;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}
.af-preview-file {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #f4f6f9;
  border: 1.5px solid #dde3ec;
  border-radius: 8px;
  padding: 10px 14px;
  width: 100%;
}
.af-preview-file svg { flex-shrink: 0; color: var(--navy); }
.af-preview-filename {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--navy);
  word-break: break-all;
  line-height: 1.3;
}
.af-preview-remove {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border: 1.5px solid #dc3545;
  background: #fff;
  color: #dc3545;
  border-radius: 6px;
  padding: 5px 12px;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}
.af-preview-remove:hover { background: #dc3545; color: #fff; }

/* ── Review grid ── */
.af-review { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-bottom: 20px; }
.af-review__section {
  background: var(--bg); border: 1.5px solid #E8ECF1; border-radius: 8px; padding: 16px 20px;
}
.af-review__section-title {
  font-family: var(--font-head); font-size: 0.75rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 1px; color: var(--teal-dark);
  margin-bottom: 12px; display: flex; align-items: center; justify-content: space-between;
}
.af-review__edit {
  font-size: 0.73rem; color: var(--navy); cursor: pointer;
  text-decoration: underline; font-weight: 600; text-transform: none; letter-spacing: 0;
}
.af-review__row { display: flex; flex-direction: column; gap: 2px; margin-bottom: 8px; }
.af-review__label { font-size: 0.73rem; color: #6c757d; font-weight: 500; }
.af-review__value { font-size: 0.84rem; color: var(--navy); font-weight: 600; font-family: var(--font-head); }

/* ── Declaration ── */
.af-declaration {
  background: #fff; border: 1.5px solid #E8ECF1; border-radius: 10px; padding: 22px 24px; margin-top: 4px;
}
.af-declaration__title {
  display: flex; align-items: center; gap: 8px;
  font-family: var(--font-head); font-size: 0.95rem; font-weight: 700;
  color: var(--navy); margin-bottom: 16px;
}
.af-declaration__title svg { color: var(--teal-dark); flex-shrink: 0; }
.af-declaration__text {
  background: var(--bg); border-left: 3px solid var(--teal-dark);
  border-radius: 0 6px 6px 0; padding: 14px 18px; margin-bottom: 16px;
  display: flex; flex-direction: column; gap: 8px;
}
.af-declaration__text p { font-size: 0.82rem; color: #212529; line-height: 1.65; }
.af-declaration__check {
  display: flex; align-items: flex-start; gap: 10px; cursor: pointer;
  font-size: 0.84rem; font-weight: 600; color: var(--navy); line-height: 1.5;
  margin-bottom: 20px; padding: 12px 14px;
  border: 1.5px solid #E8ECF1; border-radius: 6px; transition: all 0.2s;
}
.af-declaration__check:hover { border-color: var(--navy); background: rgba(2,19,62,0.03); }
.af-declaration__check input[type="checkbox"] { accent-color: var(--navy); width: 16px; height: 16px; flex-shrink: 0; margin-top: 2px; }
.af-sign-row { display: grid; grid-template-columns: 1fr 1fr auto; gap: 16px; padding-top: 16px; border-top: 1.5px solid #E8ECF1; }

/* ── Nav buttons ── */
.af-nav {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 0; border-top: 1.5px solid #E8ECF1;
  position: sticky; bottom: 0; background: #fff; z-index: 10;
  margin-top: 8px;
}
.af-nav__back { display: flex; align-items: center; gap: 6px; }
.af-nav__right { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.af-nav__status { font-size: 0.78rem; color: var(--teal-dark); }
.af-submit-btn { background: var(--teal) !important; color: var(--navy) !important; border-color: var(--teal) !important; }
.af-submit-btn:hover { background: var(--teal-dark) !important; border-color: var(--teal-dark) !important; }

/* ── Program info card ── */
.af-program-card {
  display: flex; align-items: center; gap: 12px;
  margin-top: 4px; padding: 12px 16px;
  background: rgba(7,255,195,0.06); border: 1px solid rgba(7,255,195,0.3); border-radius: 8px;
}
.af-program-card__icon {
  width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0;
  background: rgba(7,255,195,0.15); display: flex; align-items: center; justify-content: center;
  color: var(--teal-dark);
}
.af-program-card__body { flex: 1; display: flex; flex-direction: column; gap: 1px; }
.af-program-card__body strong { font-size: 0.875rem; font-weight: 700; color: var(--navy); }
.af-program-card__body span { font-size: 0.75rem; color: #6c757d; }
.af-program-card__quota {
  flex-shrink: 0; padding: 3px 10px; border-radius: 99px;
  background: var(--navy); color: var(--teal);
  font-size: 0.7rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase;
}

/* ── Confirmation ── */
.af-confirm { display: flex; align-items: center; justify-content: center; padding: 60px 24px; min-height: 70vh; width: 100%; }
.af-confirm__card {
  background: #fff; border: 1.5px solid #E8ECF1; border-radius: 12px;
  padding: 44px 40px; max-width: 480px; width: 100%; text-align: center;
  box-shadow: 0 8px 40px rgba(2,19,62,0.12);
}
.af-confirm__icon {
  width: 64px; height: 64px; border-radius: 50%;
  background: rgba(7,255,195,0.12); display: flex; align-items: center; justify-content: center;
  margin: 0 auto 20px; color: var(--teal-dark);
}
.af-confirm__title { font-family: var(--font-head); font-size: 1.5rem; font-weight: 800; color: var(--navy); margin-bottom: 10px; }
.af-confirm__text { font-size: 0.875rem; color: #6c757d; margin-bottom: 24px; }
.af-confirm__number {
  background: var(--navy); border-radius: 8px; padding: 16px 24px; margin-bottom: 16px;
  display: flex; flex-direction: column; gap: 4px;
}
.af-confirm__number span { font-size: 0.75rem; color: rgba(255,255,255,0.6); text-transform: uppercase; letter-spacing: 1px; }
.af-confirm__number strong { font-family: var(--font-head); font-size: 1.35rem; font-weight: 800; color: var(--teal); letter-spacing: 2px; }
.af-confirm__note { font-size: 0.8rem; color: #6c757d; line-height: 1.6; margin-bottom: 24px; }
.af-confirm__actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }

/* ── Responsive ── */
@media (max-width: 1100px) {
  .af-grid--4 { grid-template-columns: 1fr 1fr; }
  .af-field--span2 { grid-column: span 2; }
  .af-review { grid-template-columns: 1fr 1fr; }
  .af-info-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 800px) {
  .af-form-body { padding: 20px 20px 80px; }
  .af-hero { padding: 20px; }
  .af-info-grid { padding: 16px 20px; grid-template-columns: 1fr; }
  .af-action-bar { padding: 14px 20px; }
  .af-stepper { padding: 12px 20px; }
  .af-stepper__label { display: none; }
  .af-doc-block__body { grid-template-columns: 1fr; }
  .af-doc-block__instructions { border-right: none; border-bottom: 1.5px solid #E8ECF1; }
  .af-sign-row { grid-template-columns: 1fr 1fr; }
  .af-review { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .af-grid, .af-grid--4 { grid-template-columns: 1fr; }
  .af-field--span2 { grid-column: span 1; }
  .af-sign-row { grid-template-columns: 1fr; }
  .af-action-bar__inner { flex-direction: column; align-items: stretch; }
}

/* ══════════════════════════════════════════════════════════
   Error / Special Pages  (403 · 404 · 500 · coming-soon · maintenance)
   All these pages embed inside .app-shell → use ep-* classes
══════════════════════════════════════════════════════════ */

/* Centre content within app-main */
.ep-main {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - 56px); /* minus topbar */
  padding: 2rem 1rem;
}

/* ── Card ──────────────────────────────────────────────── */
.ep-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 3rem 2.5rem;
  max-width: 480px;
  width: 100%;
  text-align: center;
  box-shadow: 0 4px 24px rgba(2,19,62,0.06), 0 1px 4px rgba(2,19,62,0.03);
}

/* ── Icon ring ─────────────────────────────────────────── */
.ep-icon-ring {
  width: 84px; height: 84px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  margin-bottom: 1.5rem;
  position: relative;
}
.ep-icon-ring::after {
  content: '';
  position: absolute; inset: -6px; border-radius: 50%;
  border: 2px dashed rgba(2,19,62,0.10);
  animation: ep-spin 20s linear infinite;
}
@keyframes ep-spin { to { transform: rotate(360deg); } }

.ep-icon-ring--lock    { background: rgba(2,19,62,0.06);    color: var(--navy); }
.ep-icon-ring--error   { background: rgba(220,53,69,0.08);  color: var(--danger); }
.ep-icon-ring--warning { background: rgba(217,119,6,0.10);  color: #d97706; }
.ep-icon-ring--teal    { background: rgba(7,255,195,0.12);  color: var(--teal-dark); }

.ep-icon-ring--error::after  { border-color: rgba(220,53,69,0.15); }
.ep-icon-ring--warning::after{ border-color: rgba(217,119,6,0.15); }
.ep-icon-ring--teal::after   { border-color: rgba(7,255,195,0.25); }

/* ── Code chip ─────────────────────────────────────────── */
.ep-code {
  font-size: 0.6875rem; font-weight: 700; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--teal-dark);
  margin-bottom: 0.5rem;
}

/* ── Big 404 number ────────────────────────────────────── */
.ep-big-num {
  font-family: var(--font-head, 'Poppins', sans-serif);
  font-size: clamp(4.5rem, 14vw, 6.5rem);
  font-weight: 800; line-height: 1; letter-spacing: -0.04em;
  background: linear-gradient(135deg, var(--navy) 30%, var(--teal-dark) 100%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
  margin-bottom: 0.25rem; display: inline-block;
}

/* ── Title & description ───────────────────────────────── */
.ep-title {
  font-family: var(--font-head, 'Poppins', sans-serif);
  font-size: 1.5rem; font-weight: 700;
  color: var(--navy); line-height: 1.2;
  margin-bottom: 0.75rem;
}
.ep-desc {
  font-size: 0.9375rem; color: var(--muted);
  line-height: 1.65; margin-bottom: 1.75rem;
}
.ep-teal { color: var(--teal-dark); }

/* ── URL hint (404) ────────────────────────────────────── */
.ep-url-hint {
  display: flex; align-items: center; gap: 0.45rem;
  background: var(--bg); border: 1px solid var(--border);
  border-radius: 8px; padding: 0.55rem 0.9rem;
  font-size: 0.8rem; color: var(--muted);
  margin-bottom: 1.5rem; text-align: left;
}
.ep-url-hint svg { flex-shrink: 0; color: var(--teal-dark); }
.ep-url-hint code { font-size: 0.75rem; color: var(--text); overflow-wrap: anywhere; }

/* ── Actions ───────────────────────────────────────────── */
.ep-actions { display: flex; gap: 0.6rem; justify-content: center; flex-wrap: wrap; margin-bottom: 1.5rem; }

/* ── Meta link ─────────────────────────────────────────── */
.ep-meta { font-size: 0.8rem; color: var(--muted); }
.ep-meta a { color: var(--navy); text-decoration: none; font-weight: 500; }
.ep-meta a:hover { text-decoration: underline; }

/* ── Coming Soon extras ────────────────────────────────── */
.ep-cs-badge {
  display: inline-block;
  padding: 0.3rem 0.875rem;
  background: rgba(7,255,195,0.1); border: 1px solid rgba(7,255,195,0.3);
  border-radius: 99px; font-size: 0.68rem; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--teal-dark);
  margin-bottom: 1.25rem;
}
.ep-progress-wrap { margin-bottom: 1.5rem; }
.ep-progress-labels {
  display: flex; justify-content: space-between;
  font-size: 0.75rem; color: var(--muted); margin-bottom: 0.45rem;
}
.ep-progress-track {
  height: 6px; background: var(--bg); border-radius: 99px; overflow: hidden;
  border: 1px solid var(--border);
}
.ep-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--teal-dark), var(--teal));
  border-radius: 99px; width: 0;
  animation: ep-fill 1.4s cubic-bezier(.4,0,.2,1) 0.3s forwards;
}
@keyframes ep-fill { to { width: 65%; } }
.ep-eta-badge {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.4rem 0.9rem;
  background: var(--bg); border: 1px solid var(--border);
  border-radius: 8px; font-size: 0.8125rem; color: var(--muted);
  margin-bottom: 1.75rem;
}
.ep-eta-badge svg { color: var(--teal-dark); }

/* ── Maintenance extras ────────────────────────────────── */
.ep-mnt-icon-wrap { position: relative; display: inline-flex; margin-bottom: 1.5rem; }
.ep-mnt-ping {
  position: absolute; inset: -8px; border-radius: 50%;
  background: rgba(217,119,6,0.12);
  animation: ep-ping 2s ease-in-out infinite;
}
@keyframes ep-ping {
  0%,100% { transform: scale(1); opacity: 1; }
  50%      { transform: scale(1.18); opacity: 0.4; }
}
.ep-mnt-icon-wrap .ep-icon-ring { margin-bottom: 0; }
.ep-mnt-label {
  font-size: 0.68rem; font-weight: 700; letter-spacing: 0.13em;
  text-transform: uppercase; color: #d97706; margin-bottom: 0.5rem;
}
.ep-mnt-status-row {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-size: 0.8rem; color: var(--muted); margin-bottom: 1.75rem;
}
.ep-mnt-status-dot {
  width: 8px; height: 8px; border-radius: 50%; background: #d97706;
  animation: ep-blink 1.4s ease-in-out infinite;
}
@keyframes ep-blink {
  0%,100% { opacity: 1; } 50% { opacity: 0.3; }
}

@media (max-width: 600px) {
  .ep-card { padding: 2rem 1.25rem; border-radius: 14px; }
  .ep-actions { flex-direction: column; align-items: stretch; }
  .ep-actions .btn { justify-content: center; }
}

/* ── Security tab ──────────────────────────────────────────────── */
.sec-panel { padding: 0; overflow: hidden; }

.sec-section { padding: 24px 28px; }
.sec-section + .sec-section { border-top: 1px solid #e4e4e7; }
.sec-section--last { border-bottom: none; }

.sec-section-hd {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
.sec-section-info { flex: 1; min-width: 0; }
.sec-section-info h3 {
  font-size: .9rem;
  font-weight: 650;
  color: #09090b;
  margin: 0 0 2px;
}
.sec-section-info p {
  font-size: .8rem;
  color: #71717a;
  margin: 0;
}
.sec-section-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.sec-section-body { margin-top: 20px; }

/* Icon wraps */
.sec-icon-wrap {
  width: 38px; height: 38px;
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.sec-icon-wrap--blue  { background: #eff6ff; color: #3b82f6; }
.sec-icon-wrap--green { background: #f0fdf4; color: #16a34a; }
.sec-icon-wrap--gray  { background: #f4f4f5; color: #a1a1aa; }
.sec-icon-wrap--white { background: #fff; border: 1px solid #e4e4e7; }

/* Status badges */
.sec-badge {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: .75rem; font-weight: 600;
  padding: 3px 9px; border-radius: 20px;
  white-space: nowrap;
}
.sec-badge--on  { background: #f0fdf4; color: #16a34a; }
.sec-badge--off { background: #f4f4f5; color: #71717a; }

/* Danger ghost variant */
.sec-btn-danger { color: #dc2626 !important; }
.sec-btn-danger:hover { background: #fef2f2 !important; border-color: #fca5a5 !important; }

/* ── 2FA setup card ──────────────────────────────────────────── */
.sec-2fa-card {
  margin-top: 20px;
  background: #f9fafb;
  border: 1px solid #e4e4e7;
  border-radius: 12px;
  padding: 20px 22px;
}
.sec-2fa-intro {
  font-size: .8125rem;
  color: #52525b;
  margin: 0 0 18px;
  line-height: 1.6;
}
.sec-2fa-body {
  display: flex;
  gap: 28px;
  align-items: flex-start;
  flex-wrap: wrap;
}
.sec-qr-frame {
  flex-shrink: 0;
  background: #fff;
  border: 1px solid #e4e4e7;
  border-radius: 10px;
  padding: 12px;
  display: inline-flex;
}
.sec-2fa-side { flex: 1; min-width: 200px; }
.sec-2fa-label {
  font-size: .75rem;
  font-weight: 600;
  color: #71717a;
  text-transform: uppercase;
  letter-spacing: .04em;
  margin: 0 0 8px;
}
.sec-key-box {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border: 1px solid #e4e4e7;
  border-radius: 8px;
  padding: 8px 12px;
  margin-bottom: 16px;
}
.sec-key-box code {
  flex: 1;
  font-family: 'Courier New', monospace;
  font-size: .8125rem;
  letter-spacing: .15em;
  color: #02133E;
  word-break: break-all;
}
.sec-copy-btn {
  background: none; border: none; cursor: pointer;
  color: #a1a1aa; padding: 2px;
  display: flex; align-items: center;
  transition: color .15s;
}
.sec-copy-btn:hover { color: #07FFC3; }

.sec-2fa-step {
  font-size: .8125rem;
  font-weight: 600;
  color: #3f3f46;
  margin: 0 0 8px;
}
.sec-otp-row {
  display: flex;
  gap: 8px;
  align-items: center;
}
.sec-otp-input {
  width: 130px !important;
  text-align: center;
  font-size: 1.25rem !important;
  letter-spacing: .3em;
  font-family: monospace;
  padding: 8px 12px !important;
}
.sec-2fa-foot {
  margin-top: 14px;
  display: flex;
  justify-content: flex-end;
}
.sec-2fa-active {
  margin-top: 14px;
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: .8125rem;
  color: #16a34a;
  font-weight: 500;
}

/* ── Google connected row ────────────────────────────────────── */
.sec-google-btn {
  display: inline-flex !important;
  align-items: center;
  gap: 7px;
}
.sec-google-connected {
  margin-top: 14px;
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: .8125rem;
  color: #52525b;
}

/* ── Security indicator pills on avatar card ─────────────────── */
.sec-indicators {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 10px;
}
.sec-indicator {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: .7rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 20px;
}
.sec-indicator--on  { background: #f0fdf4; color: #16a34a; }
.sec-indicator--off { background: #fafafa; color: #a1a1aa; border: 1px solid #e4e4e7; }

/* Profile tab dot (unread indicator) */
.profile-tab-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #f59e0b;
  flex-shrink: 0;
}

@media (max-width: 640px) {
  .sec-section { padding: 18px 16px; }
  .sec-section-hd { gap: 10px; }
  .sec-section-actions { width: 100%; justify-content: flex-start; margin-top: 6px; }
  .sec-2fa-body { flex-direction: column; align-items: center; }
  .sec-otp-row { flex-wrap: wrap; }
}
