/* DepEd Escalante City C19 Monitoring System Styles */
/* Zero horizontal scroll guarantee across all viewports */
html {
  box-sizing: border-box;
  overflow-x: hidden;
  max-width: 100vw;
  width: 100%;
}

*, *:before, *:after {
  box-sizing: inherit;
}

body {
  overflow-x: hidden;
  max-width: 100vw;
  width: 100%;
  margin: 0;
  padding: 0;
}

/* Critical utility: Ensure hidden modals and backdrops are always completely hidden */
[hidden],
.modal-backdrop.hidden,
.modal.hidden {
  display: none !important;
}

:root {
  --deped-blue: #0b3b60;
  --deped-dark-blue: #07253d;
  --deped-light-blue: #1a568c;
  --deped-gold: #f59e0b;
  --deped-gold-hover: #d97706;
  --gov-slate: #1e293b;
  --gov-bg: #f8fafc;
  --gov-border: #e2e8f0;

  /* Global Print Color Preservation across all engines */
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
  color-adjust: exact;
  forced-color-adjust: none;
}

html, body {
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
  color-adjust: exact;
  forced-color-adjust: none;
}

#employee-profile-modal,
#employee-profile-content,
.profile-print-page,
.profile-print-page * {
  -webkit-print-color-adjust: exact !important;
  print-color-adjust: exact !important;
  color-adjust: exact !important;
  forced-color-adjust: none !important;
}

/* Custom Scrollbars */
::-webkit-scrollbar {
  width: 7px;
  height: 7px;
}
::-webkit-scrollbar-track {
  background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Organization Chart Connectors */
.org-tree {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}

.org-connector-vertical {
  width: 2px;
  height: 24px;
  background-color: #94a3b8;
  margin: 0 auto;
}

.org-connector-horizontal {
  position: relative;
  height: 20px;
  border-top: 2px solid #94a3b8;
  margin: 0 40px;
}

/* ==========================================================================
   PRINT STYLING & EXACT 2-PAGE EMPLOYEE PROFILE SPECIFICATION
   ========================================================================== */
/* Screen mode: hide print-only elements */
.print-only,
.print-only-flex {
  display: none !important;
}

@media print {
  @page {
    size: A4 portrait;
    margin: 5mm 8mm 4mm 8mm;
  }

  /* Universal scrollbar and clipping removal */
  ::-webkit-scrollbar {
    display: none !important;
    width: 0 !important;
    height: 0 !important;
    background: transparent !important;
  }

  :root, html, body {
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
    color-adjust: exact !important;
    forced-color-adjust: none !important;
    color-scheme: light !important;
  }

  *, *:before, *:after {
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
    color-adjust: exact !important;
    forced-color-adjust: none !important;
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
    box-sizing: border-box !important;
  }

  html, body {
    background: #ffffff !important;
    color: #0f172a !important;
    font-size: 8.5pt !important;
    line-height: 1.3 !important;
    margin: 0 !important;
    padding: 0 !important;
    width: 100% !important;
    overflow: visible !important;
  }

  .no-print, nav, #role-switcher-banner, button:not(.allow-print) {
    display: none !important;
  }

  /* When printing Employee Profile, hide background dashboard, headers, footers */
  body.profile-modal-open > header,
  body.profile-modal-open > footer,
  body.profile-modal-open > main,
  body.profile-modal-open #app-content,
  body.profile-modal-open #app-main-content,
  body.profile-modal-open #confidentiality-notice-banner,
  body.profile-modal-open #role-switcher-banner,
  body.profile-modal-open #toast-container,
  body.profile-modal-open .modal-backdrop:not(#employee-profile-modal),
  body:has(#employee-profile-modal:not(.hidden)) > header,
  body:has(#employee-profile-modal:not(.hidden)) > footer,
  body:has(#employee-profile-modal:not(.hidden)) > main,
  body:has(#employee-profile-modal:not(.hidden)) #app-content,
  body:has(#employee-profile-modal:not(.hidden)) #app-main-content,
  body:has(#employee-profile-modal:not(.hidden)) #confidentiality-notice-banner,
  body:has(#employee-profile-modal:not(.hidden)) #role-switcher-banner,
  body:has(#employee-profile-modal:not(.hidden)) #toast-container,
  body:has(#employee-profile-modal:not(.hidden)) .modal-backdrop:not(#employee-profile-modal),
  #employee-profile-modal.printing-profile ~ * {
    display: none !important;
  }

  /* Flatten employee-profile-modal into full-page unconstrained printable document */
  #employee-profile-modal,
  #employee-profile-modal > div,
  #employee-profile-content,
  body.profile-modal-open #employee-profile-modal,
  body.profile-modal-open #employee-profile-modal > div,
  body:has(#employee-profile-modal:not(.hidden)) #employee-profile-modal,
  body:has(#employee-profile-modal:not(.hidden)) #employee-profile-modal > div {
    display: block !important;
    position: static !important;
    inset: auto !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 100% !important;
    height: auto !important;
    max-height: none !important;
    min-height: 0 !important;
    overflow: visible !important;
    overflow-x: visible !important;
    overflow-y: visible !important;
    background: transparent !important;
    padding: 0 !important;
    margin: 0 !important;
    box-shadow: none !important;
    border: none !important;
    border-radius: 0 !important;
    transform: none !important;
    z-index: auto !important;
  }

  /* Hide screen-only modal close button and interactive button bar */
  #employee-profile-modal button,
  .profile-modal-actions-row,
  .no-print,
  .no-print-profile,
  .profile-print-page .no-print,
  #employee-profile-modal .no-print,
  #employee-profile-content .no-print {
    display: none !important;
  }

  a[href]:after {
    content: none !important;
  }

  /* Exact 1-Page Layout with Dynamic Responsive Spacing */
  .profile-print-page {
    width: 100% !important;
    box-sizing: border-box !important;
    position: relative !important;
    background: #ffffff !important;
    font-size: 8.5pt !important;
    line-height: 1.3 !important;
    padding: 0 4px !important;
    margin: 0 !important;
    page-break-before: avoid !important;
    break-before: avoid !important;
    page-break-after: avoid !important;
    break-after: avoid !important;
    page-break-inside: avoid !important;
    break-inside: avoid !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    min-height: 278mm !important;
    max-height: 287mm !important;

    /* Base dynamic spacing variables (defaults for balanced tier - 200% photo dimensions) */
    --print-card-pad: 6px 10px;
    --print-subcard-pad: 5px 8px;
    --print-row-pad: 2px 0;
    --print-section-gap: 8px;
    --print-body-gap: 8px;
    --print-sig-pt: 10px;
    --print-sig-gap: 22px;
    --print-avatar-size: 104px;
    --print-avatar-icon-size: 40px;
    --print-avatar-text-size: 8.5pt;
    --print-header-logo-size: 78px;
  }

  /* Density Tier 1: Spacious (Data-Light profiles: few/no transfers, short remarks, few custom attributes) */
  .profile-print-page.density-spacious {
    --print-card-pad: 8px 12px;
    --print-subcard-pad: 6px 10px;
    --print-row-pad: 3px 0;
    --print-section-gap: 10px;
    --print-body-gap: 10px;
    --print-sig-pt: 14px;
    --print-sig-gap: 30px;
    --print-avatar-size: 112px;
    --print-avatar-icon-size: 44px;
    --print-avatar-text-size: 9pt;
    --print-header-logo-size: 80px;
  }

  /* Density Tier 2: Balanced (Standard profiles: normal career history, standard length) */
  .profile-print-page.density-balanced {
    --print-card-pad: 6px 10px;
    --print-subcard-pad: 5px 8px;
    --print-row-pad: 2px 0;
    --print-section-gap: 8px;
    --print-body-gap: 8px;
    --print-sig-pt: 10px;
    --print-sig-gap: 22px;
    --print-avatar-size: 104px;
    --print-avatar-icon-size: 40px;
    --print-avatar-text-size: 8.5pt;
    --print-header-logo-size: 78px;
  }

  /* Density Tier 3: Compact (Moderately dense profiles: C18 tag, separation details, or multiple transfers) */
  .profile-print-page.density-compact {
    --print-card-pad: 4.5px 8px;
    --print-subcard-pad: 3.5px 6px;
    --print-row-pad: 1.2px 0;
    --print-section-gap: 6px;
    --print-body-gap: 6px;
    --print-sig-pt: 6px;
    --print-sig-gap: 14px;
    --print-avatar-size: 92px;
    --print-avatar-icon-size: 36px;
    --print-avatar-text-size: 8pt;
    --print-header-logo-size: 74px;
  }

  /* Density Tier 4: Ultra-Compact (Data-heavy profiles: long remarks, multiple transfers, many custom attributes) */
  .profile-print-page.density-ultra-compact {
    --print-card-pad: 2.5px 6px;
    --print-subcard-pad: 2px 4px;
    --print-row-pad: 0.3px 0;
    --print-section-gap: 3px;
    --print-body-gap: 3px;
    --print-sig-pt: 4px;
    --print-sig-gap: 10px;
    --print-avatar-size: 76px;
    --print-avatar-icon-size: 30px;
    --print-avatar-text-size: 7.5pt;
    --print-header-logo-size: 68px;
    line-height: 1.22 !important;
  }

  .profile-print-page.density-ultra-compact h2 {
    font-size: 13pt !important;
    margin-bottom: 0 !important;
  }

  .profile-print-page.density-ultra-compact h4 {
    margin-bottom: 1px !important;
    padding-bottom: 1px !important;
  }

  .profile-print-page.density-ultra-compact .profile-print-top {
    margin-bottom: 2px !important;
  }

  .profile-print-page.density-ultra-compact .space-y-1 > * + * {
    margin-top: 2px !important;
  }

  /* Dynamic Flexible Content Body (Spans between Header and Footer) */
  .profile-print-body {
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    flex: 1 1 auto !important;
    gap: var(--print-body-gap, 8px) !important;
    min-height: 0 !important;
  }

  .profile-print-page-1,
  .profile-print-page-2 {
    page-break-before: avoid !important;
    break-before: avoid !important;
    page-break-after: avoid !important;
    break-after: avoid !important;
    page-break-inside: avoid !important;
    break-inside: avoid !important;
    min-height: 0 !important;
  }

  .profile-print-section {
    page-break-inside: avoid !important;
    break-inside: avoid !important;
  }

  .print-only {
    display: block !important;
  }

  .print-only-flex {
    display: flex !important;
  }

  /* Force multi-column grid layouts in print regardless of screen viewport */
  .print-grid-2,
  .profile-print-page .print-grid-2,
  .profile-print-page .grid.grid-cols-1.md\:grid-cols-2 {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: var(--print-section-gap, 8px) !important;
  }

  .print-grid-3,
  .profile-print-page .print-grid-3,
  .profile-print-page .grid.grid-cols-1.lg\:grid-cols-3 {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: calc(var(--print-section-gap, 8px) * 0.75) !important;
  }

  /* High-Readability Print Typography & Space Utilization (Preserves 8.5pt / 9pt Font Sizes) */
  .profile-print-page h2 {
    font-size: 14pt !important;
    font-weight: 900 !important;
    line-height: 1.15 !important;
    margin-bottom: 2px !important;
    color: #0f172a !important;
  }

  .profile-print-page h4 {
    font-size: 9pt !important;
    font-weight: 800 !important;
    margin-bottom: 2px !important;
    padding-bottom: 2px !important;
    letter-spacing: 0.02em !important;
  }

  /* Dotted row styling for key-value pairs to prevent wrapping and maximize legibility */
  .profile-print-row {
    display: flex !important;
    justify-content: space-between !important;
    align-items: baseline !important;
    gap: 6px !important;
    padding-top: var(--print-row-pad, 1.5px) !important;
    padding-bottom: var(--print-row-pad, 1.5px) !important;
    border-bottom: 1px dashed #e2e8f0 !important;
    font-size: 8.5pt !important;
  }

  .profile-print-row:last-child {
    border-bottom: none !important;
  }

  .profile-print-label {
    color: #475569 !important;
    font-weight: 600 !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
    font-size: 8.5pt !important;
  }

  .profile-print-val {
    color: #0f172a !important;
    font-weight: 700 !important;
    text-align: right !important;
    word-break: break-word !important;
    font-size: 8.5pt !important;
  }

  .profile-print-page dl dt,
  .profile-print-page dl dd {
    font-size: 8.5pt !important;
  }

  .profile-print-page dl > div {
    padding-top: var(--print-row-pad, 1.5px) !important;
    padding-bottom: var(--print-row-pad, 1.5px) !important;
    border-bottom: 1px dashed #e2e8f0 !important;
  }

  .profile-print-page dl > div:last-child {
    border-bottom: none !important;
  }

  .profile-print-page .text-xs {
    font-size: 8.5pt !important;
  }

  .profile-print-page .text-sm {
    font-size: 9pt !important;
  }

  .profile-print-card,
  .profile-print-page .profile-print-card,
  .profile-print-page .p-2,
  .profile-print-page .p-2\.5,
  .profile-print-page .p-3,
  .profile-print-page .p-3\.5,
  .profile-print-page .p-4,
  .profile-print-page .p-5 {
    padding: var(--print-card-pad, 6px 8px) !important;
  }

  .profile-print-subcard,
  .profile-print-page .profile-print-subcard,
  .profile-print-page .p-1\.5 {
    padding: var(--print-subcard-pad, 4px 6px) !important;
  }

  .profile-print-signature-block {
    padding-top: var(--print-sig-pt, 10px) !important;
  }

  .profile-sig-space {
    height: var(--print-sig-gap, 20px) !important;
    min-height: var(--print-sig-gap, 20px) !important;
  }

  /* Profile Photo Box (Portrait with Strict Aspect Ratio & Auto Centering) */
  .profile-avatar-display-box {
    width: var(--print-avatar-size, 104px) !important;
    height: calc(var(--print-avatar-size, 104px) * 1.16) !important;
    min-width: var(--print-avatar-size, 104px) !important;
    min-height: calc(var(--print-avatar-size, 104px) * 1.16) !important;
    max-width: var(--print-avatar-size, 104px) !important;
    max-height: calc(var(--print-avatar-size, 104px) * 1.16) !important;
    border-radius: 8px !important;
    border: 1.5px solid #cbd5e1 !important;
    overflow: hidden !important;
    background: #f8fafc !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-shrink: 0 !important;
    box-shadow: 0 1px 2px rgba(0,0,0,0.06) !important;
  }

  .profile-avatar-display-box img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    object-position: center top !important;
    display: block !important;
    border-radius: inherit !important;
  }

  .profile-avatar-display-box > div {
    width: 100% !important;
    height: 100% !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 4px !important;
    text-align: center !important;
  }

  .profile-avatar-display-box svg {
    width: var(--print-avatar-icon-size, 40px) !important;
    height: var(--print-avatar-icon-size, 40px) !important;
    color: #94a3b8 !important;
    flex-shrink: 0 !important;
    margin-bottom: 2px !important;
  }

  .profile-avatar-display-box span {
    font-size: var(--print-avatar-text-size, 8.5pt) !important;
    font-weight: 700 !important;
    letter-spacing: 0.04em !important;
    color: #64748b !important;
    text-transform: uppercase !important;
    line-height: 1.1 !important;
  }

  /* SDO Escalante Official Print Header Logo */
  .profile-print-header-logo {
    width: var(--print-header-logo-size, 44px) !important;
    height: var(--print-header-logo-size, 44px) !important;
    min-width: var(--print-header-logo-size, 44px) !important;
    min-height: var(--print-header-logo-size, 44px) !important;
    max-width: var(--print-header-logo-size, 44px) !important;
    max-height: var(--print-header-logo-size, 44px) !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 9999px !important;
    border: 1.5px solid #f59e0b !important;
    padding: 1px !important;
    background: #ffffff !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    overflow: hidden !important;
    flex-shrink: 0 !important;
    box-sizing: border-box !important;
  }

  .profile-print-header-logo img {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important;
    border-radius: 9999px !important;
    display: block !important;
  }

  .profile-print-page .profile-print-identity-row {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 12px !important;
  }

  .profile-print-page .profile-print-identity-details {
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    min-width: 0 !important;
    flex: 1 1 0% !important;
  }

  .profile-print-page .profile-print-summary-box {
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    min-width: 195px !important;
    max-width: 235px !important;
    background: #f8fafc !important;
    border: 1px solid #cbd5e1 !important;
    border-radius: 8px !important;
    padding: 6px 10px !important;
    box-sizing: border-box !important;
    flex-shrink: 0 !important;
  }

  .profile-print-page.density-compact .profile-print-summary-box {
    padding: 4px 8px !important;
    min-width: 180px !important;
    max-width: 215px !important;
  }

  .profile-print-page.density-ultra-compact .profile-print-summary-box {
    padding: 3px 6px !important;
    min-width: 165px !important;
    max-width: 200px !important;
    font-size: 7.5pt !important;
  }

  .profile-print-page .mt-3\.5,
  .profile-print-page .mt-4,
  .profile-print-page .mt-5,
  .profile-print-page .mt-6 {
    margin-top: 4px !important;
  }

  .profile-print-page .mb-3,
  .profile-print-page .mb-4,
  .profile-print-page .mb-5 {
    margin-bottom: 3px !important;
  }

  .profile-print-page .rounded-xl,
  .profile-print-page .rounded-2xl {
    border-radius: 6px !important;
  }

  .profile-print-page .pr-11,
  .profile-print-page .sm\:pr-14 {
    padding-right: 0 !important;
  }

  /* ==========================================================================
     EMPLOYEE PROFILE PRINT COLOR PRESERVATION (FULL COLOR FIDELITY)
     Guarantees that all badges, cards, gradients, borders, highlighted values,
     branding, and photos are printed in full color without grayscale conversion.
     ========================================================================== */
  .profile-print-page {
    background: #ffffff !important;
    color: #0f172a !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
    color-adjust: exact !important;
    forced-color-adjust: none !important;
  }

  /* Header Branding & Divider */
  .profile-print-page .profile-print-header-logo {
    border: 1.5px solid #f59e0b !important;
    background-color: #ffffff !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .profile-print-page .border-\[\#0b3b60\],
  .profile-print-page .profile-header-divider {
    border-color: #0b3b60 !important;
  }

  .profile-print-page .text-\[\#0b3b60\],
  .profile-print-page h4.text-\[\#0b3b60\] {
    color: #0b3b60 !important;
  }

  /* Badges - Full Color Backgrounds, Text & Borders */
  .profile-print-page .badge-active,
  .profile-print-page .bg-emerald-100 {
    background-color: #d1fae5 !important;
    color: #065f46 !important;
    border: 1px solid #6ee7b7 !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .profile-print-page .badge-active .bg-emerald-500 {
    background-color: #10b981 !important;
  }

  .profile-print-page .badge-archived,
  .profile-print-page .bg-purple-100 {
    background-color: #f3e8ff !important;
    color: #6b21a8 !important;
    border: 1px solid #d8b4fe !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .profile-print-page .badge-deped-id,
  .profile-print-page .bg-blue-50 {
    background-color: #eff6ff !important;
    color: #1e3a8a !important;
    border: 1px solid #bfdbfe !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .profile-print-page .badge-teaching {
    background-color: #f5f3ff !important;
    color: #6d28d9 !important;
    border: 1px solid #ddd6fe !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .profile-print-page .badge-related-teaching {
    background-color: #ecfeff !important;
    color: #0e7490 !important;
    border: 1px solid #a5f3fc !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .profile-print-page .badge-permanent {
    background-color: #eff6ff !important;
    color: #1d4ed8 !important;
    border: 1px solid #bfdbfe !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .profile-print-page .badge-casual {
    background-color: #fffbeb !important;
    color: #b45309 !important;
    border: 1px solid #fde68a !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .profile-print-page .badge-female {
    background-color: #fdf2f8 !important;
    color: #db2777 !important;
    border: 1px solid #fbcfe8 !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .profile-print-page .badge-male {
    background-color: #eff6ff !important;
    color: #1d4ed8 !important;
    border: 1px solid #bfdbfe !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .profile-print-page .badge-due {
    background-color: #fee2e2 !important;
    color: #b91c1c !important;
    border: 1px solid #fca5a5 !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .profile-print-page .badge-due-soon {
    background-color: #fef3c7 !important;
    color: #b45309 !important;
    border: 1px solid #fcd34d !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .profile-print-page .badge-upcoming {
    background-color: #eff6ff !important;
    color: #1d4ed8 !important;
    border: 1px solid #bfdbfe !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  /* Cards & Subcards */
  .profile-print-page .profile-print-card,
  .profile-print-page .bg-slate-50\/70,
  .profile-print-page .bg-slate-50 {
    background-color: #f8fafc !important;
    border: 1px solid #cbd5e1 !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .profile-print-page .profile-benefits-tracking-card,
  .profile-print-page .bg-gradient-to-br {
    background-color: #f0f7ff !important;
    background-image: linear-gradient(135deg, #eff6ff 0%, #fffbeb 100%) !important;
    border: 1px solid #bfdbfe !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .profile-print-page .profile-print-subcard,
  .profile-print-page .bg-white {
    background-color: #ffffff !important;
    border: 1px solid #cbd5e1 !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .profile-print-page .profile-station-callout {
    background-color: #f8fafc !important;
    border: 1px solid #cbd5e1 !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  /* Text & Highlighted Values Colors */
  .profile-print-page .text-blue-900 { color: #1e3a8a !important; }
  .profile-print-page .text-blue-800 { color: #1e40af !important; }
  .profile-print-page .text-blue-700 { color: #1d4ed8 !important; }
  .profile-print-page .text-emerald-800 { color: #065f46 !important; }
  .profile-print-page .text-emerald-700 { color: #047857 !important; }
  .profile-print-page .text-rose-600 { color: #e11d48 !important; }
  .profile-print-page .text-amber-500 { color: #f59e0b !important; }
  .profile-print-page .text-amber-700 { color: #b45309 !important; }

  /* SVG Icons in Headers */
  .profile-print-page svg.text-blue-700 { color: #1d4ed8 !important; stroke: #1d4ed8 !important; }
  .profile-print-page svg.text-emerald-700 { color: #047857 !important; stroke: #047857 !important; }
  .profile-print-page svg.text-amber-500 { color: #f59e0b !important; stroke: #f59e0b !important; }
  .profile-print-page svg.text-\[\#0b3b60\] { color: #0b3b60 !important; stroke: #0b3b60 !important; }
  .profile-print-page svg.text-blue-600 { color: #2563eb !important; stroke: #2563eb !important; }

  /* Photo Box & Image Full Color Fidelity */
  .profile-print-page .profile-avatar-display-box {
    background-color: #f8fafc !important;
    border: 1.5px solid #cbd5e1 !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  .profile-print-page .profile-avatar-display-box img {
    filter: none !important;
    -webkit-filter: none !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }

  /* ==========================================================================
     REPORTS TAB: LANDSCAPE & MULTI-PAGE PRINT RULES
     ========================================================================== */
  body.printing-reports > header,
  body.printing-reports > footer,
  body.printing-reports #role-switcher-banner,
  body.printing-reports #confidentiality-notice-banner,
  body.printing-reports #beta-evaluation-banner,
  body.printing-reports .beta-evaluation-banner-bar,
  body.printing-reports #toast-container,
  body:has(.reports-print-document) > header,
  body:has(.reports-print-document) > footer,
  body:has(.reports-print-document) #role-switcher-banner,
  body:has(.reports-print-document) #confidentiality-notice-banner,
  body:has(.reports-print-document) #beta-evaluation-banner,
  body:has(.reports-print-document) .beta-evaluation-banner-bar,
  body:has(.reports-print-document) #toast-container {
    display: none !important;
  }

  .reports-screen-content {
    display: none !important;
  }

  .reports-print-document {
    display: block !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    background: #ffffff !important;
    font-size: 7.5pt !important;
    line-height: 1.25 !important;
  }

  /* Robust Multi-Column Grids for Print Engines */
  .reports-print-document .grid-cols-8,
  .report-print-grid-8 {
    display: grid !important;
    grid-template-columns: repeat(8, minmax(0, 1fr)) !important;
    gap: 6px !important;
  }

  .reports-print-document .grid-cols-4,
  .report-print-grid-4 {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 6px !important;
  }

  .reports-print-document .grid-cols-3,
  .report-print-grid-3 {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 8px !important;
  }

  .reports-print-document .grid-cols-2,
  .report-print-grid-2 {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 8px !important;
  }

  .reports-print-document .flex {
    display: flex !important;
  }

  .reports-print-document .flex-row {
    flex-direction: row !important;
  }

  .reports-print-document .flex-col {
    flex-direction: column !important;
  }

  .reports-print-document .items-center {
    align-items: center !important;
  }

  .reports-print-document .justify-between {
    justify-content: space-between !important;
  }

  .reports-print-document .justify-center {
    justify-content: center !important;
  }

  .report-print-page {
    width: 100% !important;
    min-height: 194mm !important;
    max-height: 198mm !important;
    box-sizing: border-box !important;
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    page-break-after: always !important;
    break-after: page !important;
    page-break-inside: avoid !important;
    break-inside: avoid !important;
    padding: 2mm 0 !important;
    margin: 0 !important;
    background: #ffffff !important;
    overflow: hidden !important;
  }

  .report-print-page.allow-multi-page {
    min-height: 194mm !important;
    max-height: none !important;
    overflow: visible !important;
    page-break-inside: auto !important;
    break-inside: auto !important;
  }

  .report-print-page:last-child {
    page-break-after: auto !important;
    break-after: auto !important;
  }

  .report-print-table-wrap {
    overflow: visible !important;
    max-height: none !important;
  }

  .report-print-table {
    width: 100% !important;
    border-collapse: collapse !important;
  }

  .report-print-table thead {
    display: table-header-group !important;
  }

  .report-print-table tr {
    page-break-inside: avoid !important;
    break-inside: avoid !important;
  }
}

.reports-screen-content {
  display: block;
}

.reports-print-document {
  display: none;
}

/* Robust Multi-Column Grids for Print Previews and Engines */
.reports-print-document .grid-cols-8,
.report-print-grid-8 {
  display: grid !important;
  grid-template-columns: repeat(8, minmax(0, 1fr)) !important;
  gap: 5px !important;
}

.reports-print-document .grid-cols-4,
.report-print-grid-4 {
  display: grid !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 6px !important;
}

.reports-print-document .grid-cols-3,
.report-print-grid-3 {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 8px !important;
}

.reports-print-document .grid-cols-2,
.report-print-grid-2 {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 8px !important;
}

/* ==========================================================================
   Printable Employee Profile Dynamic Density & 200% Avatar Rules
   (Active across both screen modal preview and @media print)
   ========================================================================== */
.profile-print-page {
  --print-card-pad: 6px 10px;
  --print-subcard-pad: 5px 8px;
  --print-row-pad: 2px 0;
  --print-section-gap: 8px;
  --print-body-gap: 8px;
  --print-sig-pt: 10px;
  --print-sig-gap: 22px;
  --print-avatar-size: 104px;
  --print-avatar-icon-size: 40px;
  --print-avatar-text-size: 8.5pt;
  --print-header-logo-size: 78px;
}

.profile-print-page.density-spacious {
  --print-card-pad: 8px 12px;
  --print-subcard-pad: 6px 10px;
  --print-row-pad: 3px 0;
  --print-section-gap: 10px;
  --print-body-gap: 10px;
  --print-sig-pt: 14px;
  --print-sig-gap: 30px;
  --print-avatar-size: 112px;
  --print-avatar-icon-size: 44px;
  --print-avatar-text-size: 9pt;
  --print-header-logo-size: 80px;
}

.profile-print-page.density-balanced {
  --print-card-pad: 6px 10px;
  --print-subcard-pad: 5px 8px;
  --print-row-pad: 2px 0;
  --print-section-gap: 8px;
  --print-body-gap: 8px;
  --print-sig-pt: 10px;
  --print-sig-gap: 22px;
  --print-avatar-size: 104px;
  --print-avatar-icon-size: 40px;
  --print-avatar-text-size: 8.5pt;
  --print-header-logo-size: 78px;
}

.profile-print-page.density-compact {
  --print-card-pad: 4.5px 8px;
  --print-subcard-pad: 3.5px 6px;
  --print-row-pad: 1.2px 0;
  --print-section-gap: 6px;
  --print-body-gap: 6px;
  --print-sig-pt: 6px;
  --print-sig-gap: 14px;
  --print-avatar-size: 92px;
  --print-avatar-icon-size: 36px;
  --print-avatar-text-size: 8pt;
  --print-header-logo-size: 74px;
}

.profile-print-page.density-ultra-compact {
  --print-card-pad: 2.5px 6px;
  --print-subcard-pad: 2px 4px;
  --print-row-pad: 0.3px 0;
  --print-section-gap: 3px;
  --print-body-gap: 3px;
  --print-sig-pt: 4px;
  --print-sig-gap: 10px;
  --print-avatar-size: 76px;
  --print-avatar-icon-size: 30px;
  --print-avatar-text-size: 7.5pt;
  --print-header-logo-size: 68px;
}

.profile-print-page .profile-avatar-display-box {
  width: var(--print-avatar-size, 104px) !important;
  height: calc(var(--print-avatar-size, 104px) * 1.16) !important;
  min-width: var(--print-avatar-size, 104px) !important;
  min-height: calc(var(--print-avatar-size, 104px) * 1.16) !important;
  max-width: var(--print-avatar-size, 104px) !important;
  max-height: calc(var(--print-avatar-size, 104px) * 1.16) !important;
  border-radius: 8px !important;
  border: 1.5px solid #cbd5e1 !important;
  overflow: hidden !important;
  background: #f8fafc !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-shrink: 0 !important;
  box-shadow: 0 1px 2px rgba(0,0,0,0.06) !important;
}

.profile-print-page .profile-avatar-display-box img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: center top !important;
  display: block !important;
  border-radius: inherit !important;
}

.profile-print-page .profile-avatar-display-box > div {
  width: 100% !important;
  height: 100% !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 4px !important;
  text-align: center !important;
}

.profile-print-page .profile-avatar-display-box svg {
  width: var(--print-avatar-icon-size, 40px) !important;
  height: var(--print-avatar-icon-size, 40px) !important;
  color: #94a3b8 !important;
  flex-shrink: 0 !important;
  margin-bottom: 2px !important;
}

.profile-print-page .profile-avatar-display-box span {
  font-size: var(--print-avatar-text-size, 8.5pt) !important;
  font-weight: 700 !important;
  letter-spacing: 0.04em !important;
  color: #64748b !important;
  text-transform: uppercase !important;
  line-height: 1.1 !important;
}

/* SDO Escalante Official Print Header Logo */
.profile-print-header-logo {
  width: var(--print-header-logo-size, 44px) !important;
  height: var(--print-header-logo-size, 44px) !important;
  min-width: var(--print-header-logo-size, 44px) !important;
  min-height: var(--print-header-logo-size, 44px) !important;
  max-width: var(--print-header-logo-size, 44px) !important;
  max-height: var(--print-header-logo-size, 44px) !important;
  aspect-ratio: 1 / 1 !important;
  border-radius: 9999px !important;
  border: 1.5px solid #f59e0b !important;
  padding: 1px !important;
  background: #ffffff !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  overflow: hidden !important;
  flex-shrink: 0 !important;
  box-sizing: border-box !important;
}

.profile-print-header-logo img {
  width: 100% !important;
  height: 100% !important;
  object-fit: contain !important;
  border-radius: 9999px !important;
  display: block !important;
}

.profile-print-page .profile-print-identity-row {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 12px !important;
}

.profile-print-page .profile-print-identity-details {
  display: flex !important;
  flex-direction: column !important;
  justify-content: center !important;
  min-width: 0 !important;
  flex: 1 1 0% !important;
}

.profile-print-page .profile-print-summary-box {
  display: flex !important;
  flex-direction: column !important;
  justify-content: center !important;
  min-width: 195px !important;
  max-width: 235px !important;
  background: #f8fafc !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 8px !important;
  padding: 6px 10px !important;
  box-sizing: border-box !important;
  flex-shrink: 0 !important;
}

.profile-print-page.density-compact .profile-print-summary-box {
  padding: 4px 8px !important;
  min-width: 180px !important;
  max-width: 215px !important;
}

.profile-print-page.density-ultra-compact .profile-print-summary-box {
  padding: 3px 6px !important;
  min-width: 165px !important;
  max-width: 200px !important;
  font-size: 7.5pt !important;
}

/* Multi-column grid rules for employee profile across screen modal and print */
.profile-print-page .print-grid-2,
.profile-print-page .profile-grid-2 {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: var(--print-section-gap, 8px) !important;
}

.profile-print-page .print-grid-3,
.profile-print-page .profile-grid-3 {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: calc(var(--print-section-gap, 8px) * 0.75) !important;
}

/* Mobile responsive collapse for screen modal on smaller screens */
@media (max-width: 639px) {
  #employee-profile-modal .profile-print-page .print-grid-2,
  #employee-profile-modal .profile-print-page .profile-grid-2,
  #employee-profile-modal .profile-print-page .print-grid-3,
  #employee-profile-modal .profile-print-page .profile-grid-3 {
    grid-template-columns: 1fr !important;
    gap: 8px !important;
  }
}

.profile-print-page .profile-print-card dl > div {
  min-width: 0;
}

/* Shared full-color definitions for screen and print */
.profile-print-page .profile-print-card {
  background-color: #f8fafc !important;
  border: 1px solid #cbd5e1 !important;
  -webkit-print-color-adjust: exact !important;
  print-color-adjust: exact !important;
}

.profile-print-page .profile-benefits-tracking-card {
  background-color: #f0f7ff !important;
  background-image: linear-gradient(135deg, #eff6ff 0%, #fffbeb 100%) !important;
  border: 1px solid #bfdbfe !important;
  -webkit-print-color-adjust: exact !important;
  print-color-adjust: exact !important;
}

.profile-print-page .profile-station-callout {
  background-color: #f8fafc !important;
  border: 1px solid #cbd5e1 !important;
  -webkit-print-color-adjust: exact !important;
  print-color-adjust: exact !important;
}

/* Subtle Card Hover Effects */
.interactive-card {
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.interactive-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px -5px rgba(11, 59, 96, 0.12), 0 8px 10px -6px rgba(11, 59, 96, 0.08);
}

/* Status Badges */
.badge-due {
  background-color: #fee2e2;
  color: #b91c1c;
  border: 1px solid #fca5a5;
}
.badge-due-soon {
  background-color: #fef3c7;
  color: #b45309;
  border: 1px solid #fcd34d;
}
.badge-upcoming {
  background-color: #e0f2fe;
  color: #0369a1;
  border: 1px solid #bae6fd;
}
.badge-completed {
  background-color: #dcfce7;
  color: #15803d;
  border: 1px solid #86efac;
}

/* Table row highlight on hover */
.employee-row:hover {
  background-color: #f8fafc;
}

/* Modal animation */
.modal-backdrop {
  backdrop-filter: blur(2px);
}

/* Custom modal internal scroll styling */
.custom-modal-scroll::-webkit-scrollbar {
  width: 5px;
}
.custom-modal-scroll::-webkit-scrollbar-track {
  background: transparent;
}
.custom-modal-scroll::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 9999px;
}
.custom-modal-scroll::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Elegant Pastel UI Colors for Mass Update System */
.pastel-emerald {
  background-color: #ecfdf5;
  border-color: #a7f3d0;
  color: #065f46;
}
.pastel-sky {
  background-color: #f0f9ff;
  border-color: #bae6fd;
  color: #0369a1;
}
.pastel-amber {
  background-color: #fffbeb;
  border-color: #fde68a;
  color: #92400e;
}
.pastel-rose {
  background-color: #fff1f2;
  border-color: #fecdd3;
  color: #9f1239;
}
.pastel-teal {
  background-color: #f0fdfa;
  border-color: #99f6e4;
  color: #0f766e;
}
.pastel-indigo {
  background-color: #eef2ff;
  border-color: #c7d2fe;
  color: #3730a3;
}

/* Diff visual badges */
.diff-badge-old {
  background-color: #fee2e2;
  color: #991b1b;
  text-decoration: line-through;
  padding: 1px 5px;
  border-radius: 4px;
}
.diff-badge-new {
  background-color: #dcfce7;
  color: #166534;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: 4px;
}

/* Pastel Purple */
.pastel-purple {
  background-color: #faf5ff;
  border-color: #e9d5ff;
  color: #6b21a8;
}

/* Separation Reason Badges */
.badge-retirement {
  background-color: #faf5ff;
  color: #6b21a8;
  border: 1px solid #d8b4fe;
}
.badge-transfer {
  background-color: #f0f9ff;
  color: #0369a1;
  border: 1px solid #7dd3fc;
}
.badge-resignation {
  background-color: #fffbeb;
  color: #b45309;
  border: 1px solid #fcd34d;
}
.badge-deceased {
  background-color: #f1f5f9;
  color: #334155;
  border: 1px solid #cbd5e1;
}
.badge-others {
  background-color: #f0fdfa;
  color: #0f766e;
  border: 1px solid #99f6e4;
}

/* Position Classification Badges */
.badge-teaching {
  background-color: #eef2ff;
  color: #3730a3;
  border: 1px solid #c7d2fe;
}
.badge-non-teaching {
  background-color: #ecfdf5;
  color: #065f46;
  border: 1px solid #a7f3d0;
}
.badge-related-teaching {
  background-color: #f0fdfa;
  color: #0f766e;
  border: 1px solid #99f6e4;
}

/* Employment Status Badges */
.badge-permanent {
  background-color: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
}
.badge-casual {
  background-color: #fffbeb;
  color: #b45309;
  border: 1px solid #fde68a;
}
.badge-provisional {
  background-color: #faf5ff;
  color: #7e22ce;
  border: 1px solid #e9d5ff;
}
.badge-contract-of-service {
  background-color: #fff1f2;
  color: #be123c;
  border: 1px solid #fecdd3;
}

/* Sex at Birth Badges */
.badge-male {
  background-color: #f0f9ff;
  color: #0369a1;
  border: 1px solid #bae6fd;
}
.badge-female {
  background-color: #fdf2f8;
  color: #be185d;
  border: 1px solid #fbcfe8;
}
.badge-unassigned {
  background-color: #f8fafc;
  color: #64748b;
  border: 1px solid #cbd5e1;
}

/* Report Tab Styles */
.report-card-kpi {
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.report-card-kpi:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px -2px rgba(11, 59, 96, 0.08);
}
.report-tab-btn {
  transition: all 0.15s ease;
}
.report-tab-btn.active {
  background-color: #0b3b60;
  color: #fde047;
  box-shadow: 0 2px 4px rgba(11, 59, 96, 0.15);
}

/* Official Header Branding & Logos */
header.masthead-header {
  background: linear-gradient(135deg, #0b3b60 0%, #0d4775 50%, #0b3b60 100%);
  color: #ffffff;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
  position: sticky;
  top: 0;
  z-index: 40;
  width: 100%;
}

.masthead-inner {
  max-width: 96rem;
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  padding: 0.5rem 1rem;
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 0.5rem;
  box-sizing: border-box;
}

.masthead-branding {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  gap: 0.5rem;
  flex: 1 1 auto !important;
  min-width: 0 !important;
  overflow: hidden !important;
}

.masthead-brand-item {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
  flex-shrink: 1;
}

/* ==========================================================================
   Masthead Header Responsive Visibility (Deterministic Rules)
   ========================================================================== */

/* Base / Mobile (< 640px): Compact single-line branding to fit small screens */
.deped-subtitle {
  display: none !important;
}
.deped-title-desktop {
  display: none !important;
}
.deped-title-mobile {
  display: inline !important;
}
#masthead-personnel-brand {
  display: none !important;
}
.masthead-divider {
  display: none !important;
}
#header-school-search-input {
  display: none !important;
}
#header-school-search-clear-btn.hidden,
.hidden#header-school-search-clear-btn {
  display: none !important;
}

@media (max-width: 639px) {
  .masthead-inner {
    padding: 0.35rem 0.5rem !important;
    gap: 0.35rem !important;
    min-width: 0 !important;
  }
  .masthead-branding {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    overflow: hidden !important;
  }
  .masthead-right {
    margin-left: auto !important;
    gap: 0.35rem !important;
    flex-shrink: 0 !important;
  }
  #header-school-search-clear-btn {
    display: none !important;
  }
}

@media (max-width: 420px) {
  .deped-title-mobile {
    font-size: 0.7rem !important;
    letter-spacing: -0.01em !important;
    white-space: nowrap !important;
  }
  .masthead-branding img {
    width: 30px !important;
    height: 30px !important;
  }
  .masthead-right {
    gap: 0.25rem !important;
  }
  .header-search-icon-btn {
    width: 30px !important;
    height: 30px !important;
    min-width: 30px !important;
    min-height: 30px !important;
  }
}

/* Tablet & Mobile Landscape (>= 640px) */
@media (min-width: 640px) {
  .deped-subtitle {
    display: block !important;
  }
  .deped-title-desktop {
    display: inline !important;
  }
  .deped-title-mobile {
    display: none !important;
  }
  #header-school-search-input {
    display: block !important;
  }
}

/* Tablet Landscape, Laptop & Desktop (>= 768px): Show Personnel Section & Divider */
@media (min-width: 768px) {
  #masthead-personnel-brand {
    display: flex !important;
    align-items: center !important;
  }
  .masthead-divider {
    display: block !important;
  }
}

.masthead-text-block {
  display: flex;
  flex-direction: column;
  justify-content: center;
  line-height: 1.15;
  min-width: 0;
  overflow: hidden;
}

.masthead-text-block h1 {
  font-size: 0.9rem !important;
  font-weight: 800 !important;
  color: #fde047 !important;
  margin: 0 !important;
  padding: 0 !important;
  line-height: 1.2 !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}

.masthead-text-block span {
  margin: 0;
  padding: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.masthead-right {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  gap: 0.5rem;
  flex-shrink: 0 !important;
  margin-left: auto !important;
}

.header-search-icon-btn {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 36px !important;
  height: 36px !important;
  min-width: 36px !important;
  min-height: 36px !important;
  background: transparent !important;
  border: none !important;
  border-radius: 8px !important;
  color: #cbd5e1 !important;
  cursor: pointer !important;
  padding: 0 !important;
  position: relative !important;
  transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out !important;
}

.header-search-icon-btn:hover {
  color: #fde047 !important;
  background-color: rgba(255, 255, 255, 0.12) !important;
}

.header-search-icon-btn:focus-visible {
  outline: 2px solid #f59e0b !important;
  outline-offset: 2px !important;
}

.header-search-icon-btn svg {
  width: 18px !important;
  height: 18px !important;
  display: block !important;
}

/* ==========================================================================
   SCHOOLS & CLCS HEADER SEARCH FIELD (#header-school-search-input)
   High-contrast, DepEd-themed focus, typing, hover, and idle styling.
   Isolated strictly to the Schools Header Search component.
   Does NOT affect Employee Search.
   ========================================================================== */

/* 1. Base / Idle state on dark navy masthead */
#header-school-search-input {
  background-color: rgba(255, 255, 255, 0.15) !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.3) !important;
  outline: none !important;
  caret-color: #f59e0b !important;
  transition: background-color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease, color 0.15s ease !important;
}

#header-school-search-input::placeholder {
  color: rgba(219, 234, 254, 0.8) !important; /* Soft pastel blue */
}

/* 2. Hover state */
#header-school-search-input:hover:not(:focus) {
  background-color: rgba(255, 255, 255, 0.22) !important;
  border-color: rgba(251, 191, 36, 0.6) !important; /* DepEd Gold accent */
  color: #ffffff !important;
}

/* 3. Focused, Active & Typing state: Solid white background with crisp dark slate text */
#header-school-search-input:focus,
#header-school-search-input:focus-visible,
#header-school-search-input:active {
  background-color: #ffffff !important;
  color: #0f172a !important; /* Very dark slate-900: sharp contrast, maximum readability */
  border: 1.5px solid #d97706 !important; /* DepEd Gold / Amber-600 */
  box-shadow: 0 0 0 2.5px rgba(245, 158, 11, 0.4) !important;
  caret-color: #0b3b60 !important; /* DepEd Navy blue cursor */
}

#header-school-search-input:focus::placeholder {
  color: #64748b !important; /* Slate-500 placeholder on white */
}

/* 4. When input has typed content, preserve crisp white background & dark text even if blurred */
#header-school-search-input:not(:placeholder-shown) {
  background-color: #ffffff !important;
  color: #0f172a !important;
}

#header-school-search-input:not(:placeholder-shown):not(:focus) {
  border-color: #cbd5e1 !important;
  box-shadow: none !important;
}

/* 5. Synchronize Search & Clear Icons with Focus State */
.header-search-input-wrap:focus-within .header-search-icon-btn svg,
.header-search-input-wrap:has(#header-school-search-input:not(:placeholder-shown)) .header-search-icon-btn svg {
  color: #0b3b60 !important; /* Deep navy icon against white input background */
}

.header-search-input-wrap:focus-within #header-school-search-clear-btn,
.header-search-input-wrap:focus-within #header-school-search-clear-btn svg,
.header-search-input-wrap:has(#header-school-search-input:not(:placeholder-shown)) #header-school-search-clear-btn svg {
  color: #64748b !important; /* Slate-500 clear cross on white */
}

.header-search-input-wrap:focus-within #header-school-search-clear-btn:hover svg {
  color: #0f172a !important; /* Darker slate-900 on clear button hover */
}

.masthead-divider {
  height: 2rem;
  width: 1px;
  background-color: rgba(255, 255, 255, 0.25);
  margin: 0 0.25rem;
  flex-shrink: 0;
}

.header-logo-container {
  width: 40px !important;
  height: 40px !important;
  min-width: 40px !important;
  min-height: 40px !important;
  max-width: 40px !important;
  max-height: 40px !important;
  border-radius: 9999px !important;
  background-color: #ffffff !important;
  border: 2px solid #f59e0b !important;
  padding: 2px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  flex-shrink: 0 !important;
  overflow: hidden !important;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15) !important;
  box-sizing: border-box !important;
}

.header-logo-img {
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  max-height: 100% !important;
  object-fit: contain !important;
  border-radius: 9999px !important;
  display: block !important;
}

/* Navigation Bar Layout & Even Distribution */
nav.portal-nav {
  background-color: #07253d;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 0 0.5rem;
  width: 100%;
}

nav.portal-nav .nav-container {
  max-width: 96rem;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 0.25rem 0;
  overflow-x: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

nav.portal-nav .nav-container::-webkit-scrollbar {
  height: 3px;
}

nav.portal-nav .nav-container::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.25);
  border-radius: 4px;
}

/* Primary links track distributed across the available space */
nav.portal-nav .nav-links-track {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex: 1 1 auto;
  min-width: 0;
  gap: 0.25rem;
}

/* Administration section pinned to the far right */
nav.portal-nav .nav-admin-section {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  margin-left: auto;
  padding-left: 0.5rem;
  border-left: 1px solid rgba(255, 255, 255, 0.12);
}

nav.portal-nav button {
  padding: 0.35rem 0.55rem;
  font-size: 0.775rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  cursor: pointer;
  background: transparent;
  border: 1px solid transparent;
  border-bottom: 3px solid transparent;
  border-radius: 0.5rem;
  color: #cbd5e1;
  white-space: nowrap;
  flex-shrink: 0;
  transition: all 0.15s ease-in-out;
}

nav.portal-nav .nav-links-track button {
  flex: 0 1 auto;
}

nav.portal-nav button:hover:not(.nav-active-tab):not([aria-current="page"]) {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
}

/* Clear, Noticeable Active Navigation Tab (Desktop) */
nav.portal-nav button.nav-active-tab,
nav.portal-nav button[aria-current="page"] {
  background: rgba(255, 255, 255, 0.15) !important;
  color: #fde047 !important; /* DepEd Golden Amber 300 */
  font-weight: 700 !important;
  border: 1px solid rgba(251, 191, 36, 0.45) !important;
  border-bottom: 3px solid #f59e0b !important; /* Bold Amber 500 Active Stripe */
  border-radius: 0.5rem !important;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.2) !important;
}

nav.portal-nav button.nav-active-tab svg,
nav.portal-nav button[aria-current="page"] svg {
  color: #fde047 !important;
}

nav.portal-nav button[data-nav="admin"] {
  flex-shrink: 0;
  background: rgba(6, 78, 59, 0.35);
  border: 1px solid rgba(16, 185, 129, 0.3);
  border-bottom: 3px solid transparent;
  color: #6ee7b7;
}

nav.portal-nav button[data-nav="admin"]:hover:not(.nav-active-tab):not([aria-current="page"]) {
  background: rgba(6, 78, 59, 0.55);
  color: #ffffff;
  border-color: rgba(16, 185, 129, 0.5);
}

nav.portal-nav button[data-nav="admin"].nav-active-tab,
nav.portal-nav button[data-nav="admin"][aria-current="page"] {
  background: rgba(6, 78, 59, 0.8) !important;
  color: #fde047 !important;
  border: 1px solid rgba(251, 191, 36, 0.6) !important;
  border-bottom: 3px solid #f59e0b !important;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.15) !important;
}

nav.portal-nav button[data-nav="admin"].nav-active-tab svg,
nav.portal-nav button[data-nav="admin"][aria-current="page"] svg {
  color: #fde047 !important;
}

/* Mobile Collapsible Drawer Active Tab Highlighting */
#mobile-nav-drawer button {
  transition: all 0.15s ease-in-out;
  border: 1px solid transparent;
  border-left: 4px solid transparent;
}

#mobile-nav-drawer button:hover:not(.mobile-nav-active):not([aria-current="page"]) {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

#mobile-nav-drawer button.mobile-nav-active,
#mobile-nav-drawer button[aria-current="page"] {
  background: rgba(255, 255, 255, 0.16) !important;
  color: #fde047 !important;
  font-weight: 700 !important;
  border: 1px solid rgba(251, 191, 36, 0.5) !important;
  border-left: 4px solid #f59e0b !important;
  border-radius: 0.75rem !important;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.15) !important;
}

#mobile-nav-drawer button.mobile-nav-active svg:first-child,
#mobile-nav-drawer button[aria-current="page"] svg:first-child {
  color: #fde047 !important;
}

#mobile-nav-drawer button[data-mobile-nav="admin"].mobile-nav-active,
#mobile-nav-drawer button[data-mobile-nav="admin"][aria-current="page"] {
  background: rgba(6, 78, 59, 0.8) !important;
  color: #fde047 !important;
  border: 1px solid rgba(251, 191, 36, 0.6) !important;
  border-left: 4px solid #f59e0b !important;
}

@media (max-width: 1023px) {
  nav.portal-nav {
    display: none !important;
  }
}

@media (min-width: 1024px) {
  #mobile-nav-toggle-btn,
  #mobile-nav-drawer {
    display: none !important;
  }
  nav.portal-nav {
    display: block !important;
    padding: 0 0.75rem;
  }
  nav.portal-nav button {
    font-size: 0.8125rem;
    padding: 0.38rem 0.6rem;
    gap: 0.35rem;
  }
}

@media (min-width: 1280px) {
  nav.portal-nav {
    padding: 0 1rem;
  }
  nav.portal-nav .nav-links-track {
    gap: 0.5rem;
  }
  nav.portal-nav button {
    padding: 0.4rem 0.75rem;
    font-size: 0.825rem;
    gap: 0.4rem;
  }
}

@media (min-width: 1536px) {
  nav.portal-nav .nav-links-track {
    gap: 0.75rem;
  }
  nav.portal-nav button {
    padding: 0.45rem 0.85rem;
    font-size: 0.85rem;
    gap: 0.45rem;
  }
}

/* Default typography & box sizing */
*, *::before, *::after {
  box-sizing: border-box;
}

body, button, input, select, textarea {
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

nav.portal-nav button svg {
  width: 1rem !important;
  height: 1rem !important;
  max-width: 1rem !important;
  max-height: 1rem !important;
}

/* Defensive SVG scaling fallbacks */
svg {
  box-sizing: border-box;
  display: inline-block;
  vertical-align: middle;
}
svg.w-3, svg.h-3 { width: 0.75rem !important; height: 0.75rem !important; max-width: 0.75rem !important; max-height: 0.75rem !important; }
svg.w-3\.5, svg.h-3\.5 { width: 0.875rem !important; height: 0.875rem !important; max-width: 0.875rem !important; max-height: 0.875rem !important; }
svg.w-4, svg.h-4 { width: 1rem !important; height: 1rem !important; max-width: 1rem !important; max-height: 1rem !important; }
svg.w-5, svg.h-5 { width: 1.25rem !important; height: 1.25rem !important; max-width: 1.25rem !important; max-height: 1.25rem !important; }
svg.w-6, svg.h-6 { width: 1.5rem !important; height: 1.5rem !important; max-width: 1.5rem !important; max-height: 1.5rem !important; }
svg.w-7, svg.h-7 { width: 1.75rem !important; height: 1.75rem !important; max-width: 1.75rem !important; max-height: 1.75rem !important; }
svg.w-8, svg.h-8 { width: 2rem !important; height: 2rem !important; max-width: 2rem !important; max-height: 2rem !important; }
svg.w-10, svg.h-10 { width: 2.5rem !important; height: 2.5rem !important; max-width: 2.5rem !important; max-height: 2.5rem !important; }
svg.w-12, svg.h-12 { width: 3rem !important; height: 3rem !important; max-width: 3rem !important; max-height: 3rem !important; }
svg.w-14, svg.h-14 { width: 3.5rem !important; height: 3.5rem !important; max-width: 3.5rem !important; max-height: 3.5rem !important; }
svg.w-16, svg.h-16 { width: 4rem !important; height: 4rem !important; max-width: 4rem !important; max-height: 4rem !important; }
svg.w-80, svg.h-80 { width: 20rem !important; height: 20rem !important; max-width: 100% !important; }

/* Essential Utility Fallbacks for Robust Offline / Sandboxed Rendering */
.flex { display: flex !important; }
.inline-flex { display: inline-flex !important; }
.flex-col { flex-direction: column !important; }
.flex-row { flex-direction: row !important; }
.flex-1 { flex: 1 1 0% !important; }
.flex-shrink-0, .shrink-0 { flex-shrink: 0 !important; }
.items-center { align-items: center !important; }
.items-start { align-items: flex-start !important; }
.items-end { align-items: flex-end !important; }
.items-baseline { align-items: baseline !important; }
.justify-between { justify-content: space-between !important; }
.justify-center { justify-content: center !important; }
.justify-end { justify-content: flex-end !important; }
.text-center { text-align: center !important; }
.text-right { text-align: right !important; }
.text-left { text-align: left !important; }
.space-y-1 > :not([hidden]) ~ :not([hidden]) { margin-top: 0.25rem !important; }
.space-y-1\.5 > :not([hidden]) ~ :not([hidden]) { margin-top: 0.375rem !important; }
.space-y-2 > :not([hidden]) ~ :not([hidden]) { margin-top: 0.5rem !important; }
.space-y-2\.5 > :not([hidden]) ~ :not([hidden]) { margin-top: 0.625rem !important; }
.gap-1 { gap: 0.25rem !important; }
.gap-1\.5 { gap: 0.375rem !important; }
.gap-2 { gap: 0.5rem !important; }
.gap-2\.5 { gap: 0.625rem !important; }
.gap-3 { gap: 0.75rem !important; }
.gap-4 { gap: 1rem !important; }
.gap-5 { gap: 1.25rem !important; }
.gap-6 { gap: 1.5rem !important; }

/* Truncation & Line Clamping */
.truncate { overflow: hidden !important; text-overflow: ellipsis !important; white-space: nowrap !important; }
.line-clamp-1 { display: -webkit-box !important; -webkit-line-clamp: 1 !important; -webkit-box-orient: vertical !important; overflow: hidden !important; }
.line-clamp-2 { display: -webkit-box !important; -webkit-line-clamp: 2 !important; -webkit-box-orient: vertical !important; overflow: hidden !important; }
.line-clamp-3 { display: -webkit-box !important; -webkit-line-clamp: 3 !important; -webkit-box-orient: vertical !important; overflow: hidden !important; }

/* Common Font & Layout Helpers */
.font-sans { font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif !important; }
.font-mono { font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace !important; }
.font-medium { font-weight: 500 !important; }
.font-semibold { font-weight: 600 !important; }
.font-bold { font-weight: 700 !important; }
.font-extrabold { font-weight: 800 !important; }
.font-black { font-weight: 900 !important; }
.uppercase { text-transform: uppercase !important; }
.lowercase { text-transform: lowercase !important; }
.italic { font-style: italic !important; }
.underline { text-decoration: underline !important; }
.leading-none { line-height: 1 !important; }
.leading-tight { line-height: 1.25 !important; }
.leading-snug { line-height: 1.375 !important; }
.leading-relaxed { line-height: 1.625 !important; }
.tracking-tight { letter-spacing: -0.025em !important; }
.tracking-wider { letter-spacing: 0.05em !important; }
.tracking-widest { letter-spacing: 0.1em !important; }
.cursor-pointer { cursor: pointer !important; }
.relative { position: relative !important; }
.absolute { position: absolute !important; }
.inset-0 { inset: 0 !important; }
.overflow-hidden { overflow: hidden !important; }
.rounded-lg { border-radius: 0.5rem !important; }
.rounded-xl { border-radius: 0.75rem !important; }
.rounded-2xl { border-radius: 1rem !important; }
.rounded-full { border-radius: 9999px !important; }
.w-full { width: 100% !important; }
.h-full { height: 100% !important; }
.min-w-0 { min-width: 0 !important; }
.max-w-xs { max-width: 20rem !important; }

/* Font sizes */
.text-\[9px\] { font-size: 9px !important; line-height: 12px !important; }
.text-\[10px\] { font-size: 10px !important; line-height: 14px !important; }
.text-\[11px\] { font-size: 11px !important; line-height: 15px !important; }
.text-xs { font-size: 0.75rem !important; line-height: 1rem !important; }
.text-sm { font-size: 0.875rem !important; line-height: 1.25rem !important; }
.text-base { font-size: 1rem !important; line-height: 1.5rem !important; }
.text-lg { font-size: 1.125rem !important; line-height: 1.75rem !important; }
.text-xl { font-size: 1.25rem !important; line-height: 1.75rem !important; }
.text-2xl { font-size: 1.5rem !important; line-height: 2rem !important; }

/* Backgrounds & Text Colors */
.bg-white { background-color: #ffffff !important; }
.bg-slate-50 { background-color: #f8fafc !important; }
.bg-slate-100 { background-color: #f1f5f9 !important; }
.bg-slate-200 { background-color: #e2e8f0 !important; }
.bg-blue-100 { background-color: #dbeafe !important; }
.bg-amber-50 { background-color: #fffbeb !important; }
.bg-amber-100 { background-color: #fef3c7 !important; }
.bg-pink-50 { background-color: #fdf2f8 !important; }
.bg-pink-100 { background-color: #fce7f3 !important; }
.bg-pink-200 { background-color: #fbcfe8 !important; }
.bg-pink-600 { background-color: #db2777 !important; }
.bg-rose-500 { background-color: #f43f5e !important; }
.bg-rose-600 { background-color: #e11d48 !important; }
.bg-emerald-100 { background-color: #d1fae5 !important; }

.text-white { color: #ffffff !important; }
.text-slate-400 { color: #94a3b8 !important; }
.text-slate-500 { color: #64748b !important; }
.text-slate-600 { color: #475569 !important; }
.text-slate-700 { color: #334155 !important; }
.text-slate-800 { color: #1e293b !important; }
.text-slate-900 { color: #0f172a !important; }
.text-blue-700 { color: #1d4ed8 !important; }
.text-pink-600 { color: #db2777 !important; }
.text-pink-700 { color: #be185d !important; }
.text-pink-800 { color: #9d174d !important; }
.text-pink-900 { color: #831843 !important; }
.text-amber-700 { color: #b45309 !important; }
.text-amber-800 { color: #92400e !important; }
.text-amber-900 { color: #78350f !important; }
.text-emerald-700 { color: #047857 !important; }
.text-emerald-800 { color: #065f46 !important; }

.border { border-width: 1px !important; border-style: solid !important; }
.border-b { border-bottom-width: 1px !important; border-bottom-style: solid !important; }
.border-t { border-top-width: 1px !important; border-top-style: solid !important; }
.border-slate-100 { border-color: #f1f5f9 !important; }
.border-slate-200 { border-color: #e2e8f0 !important; }
.border-pink-100 { border-color: #fce7f3 !important; }
.border-pink-200 { border-color: #fbcfe8 !important; }
.border-amber-200 { border-color: #fde68a !important; }

/* ========================================== */
/* HOME DASHBOARD FEATURED TRI-CARD SHOWCASE */
/* News & Updates, Vacancies & Birthday Celebrants */
/* ========================================== */
/* HOME FEATURED TRI-CARDS SHOWCASE           */
/* ========================================== */

.home-featured-cards-section {
  width: 100%;
  margin-bottom: 2rem;
  box-sizing: border-box;
}

.home-featured-cards-grid {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  width: 100%;
  box-sizing: border-box;
}

.home-secondary-cards-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
  width: 100%;
  box-sizing: border-box;
}

@media (min-width: 1024px) {
  .home-secondary-cards-row.two-cols {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

#home-card-news.home-feature-card,
#home-card-vacancies.home-feature-card {
  min-height: auto;
  padding: 1.25rem 1.5rem;
}

/* Announcement & Vacancy Cards & Responsive Grid */
.announcement-cards-grid,
.vacancy-cards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  width: 100%;
  box-sizing: border-box;
}

@media (min-width: 640px) {
  .announcement-cards-grid,
  .vacancy-cards-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
  }
}

@media (min-width: 1024px) {
  .announcement-cards-grid,
  .vacancy-cards-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.25rem;
  }
}

.announcement-card,
.vacancy-card {
  background: #ffffff;
  border: 1px solid rgba(226, 232, 240, 0.95);
  border-radius: 0.875rem;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-sizing: border-box;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s ease, border-color 0.2s ease;
  position: relative;
  overflow: hidden;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.04);
}

.announcement-card:hover {
  transform: translateY(-2px);
  border-color: #f59e0b;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -2px rgba(0, 0, 0, 0.04);
}

.vacancy-card:hover {
  transform: translateY(-2px);
  border-color: #0284c7;
  box-shadow: 0 10px 15px -3px rgba(11, 59, 96, 0.12), 0 4px 6px -2px rgba(0, 0, 0, 0.04);
}

.card-media-wrapper {
  position: relative;
  width: 100%;
  border-radius: 0.75rem;
  overflow: hidden;
}

/* Publication of Vacancy Multi-Format Media Engine */
.vac-media-container {
  position: relative;
  width: 100%;
  height: 180px;
  background-color: #0b1329;
  border-radius: 0.625rem;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 2px 4px 0 rgba(0, 0, 0, 0.2);
}

.vac-media-container img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  display: block !important;
}

.vac-media-container video {
  width: 100% !important;
  height: 100% !important;
  object-fit: contain !important;
  background: #000000 !important;
}

/* PDF Document First-Page Canvas Preview */
.vac-pdf-page-container {
  position: relative;
  width: 100%;
  height: 180px;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 0.625rem;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 3px 6px -1px rgba(0, 0, 0, 0.08), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
  box-sizing: border-box;
  text-align: left;
}

/* Control buttons inside vacancy media preview */
.vac-ctrl-btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  background: rgba(15, 23, 42, 0.8) !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.25) !important;
  border-radius: 9999px !important;
  padding: 0.25rem !important;
  cursor: pointer !important;
  transition: all 0.15s ease !important;
  box-shadow: 0 2px 4px rgba(0,0,0,0.2) !important;
  width: 1.625rem !important;
  height: 1.625rem !important;
}
.vac-ctrl-btn:hover {
  background: rgba(15, 23, 42, 0.95) !important;
  border-color: rgba(255, 255, 255, 0.6) !important;
  transform: scale(1.05);
}

.vac-view-doc-action-btn {
  display: inline-flex !important;
  align-items: center !important;
  gap: 0.35rem !important;
  background: #0b3b60 !important;
  color: #fde047 !important;
  border: 1px solid #1e3a8a !important;
  border-radius: 0.5rem !important;
  padding: 0.25rem 0.65rem !important;
  font-size: 0.6875rem !important;
  font-weight: 700 !important;
  cursor: pointer !important;
  box-shadow: 0 2px 4px rgba(0,0,0,0.15) !important;
  transition: all 0.15s ease !important;
}
.vac-view-doc-action-btn:hover {
  background: #07253d !important;
  color: #fef08a !important;
  transform: translateY(-1px);
}

.home-feature-card,
.home-tri-card {
  background: #ffffff;
  border: 1px solid rgba(226, 232, 240, 0.9);
  border-radius: 1rem;
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
  min-height: 380px;
  max-height: none;
  width: 100%;
  min-width: 0; /* Prevents grid/flex child overflow */
  box-sizing: border-box;
  position: relative;
  overflow: hidden;
  box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.05), 0 1px 2px 0 rgba(0, 0, 0, 0.03);
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s ease, border-color 0.2s ease;
}

.home-feature-card:hover,
.home-tri-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.07), 0 4px 6px -2px rgba(0, 0, 0, 0.04);
}

/* Card Button Reset & Styling */
.home-feature-card button,
.home-tri-card button {
  background: transparent;
  border: none;
  padding: 0;
  margin: 0;
  font: inherit;
  color: inherit;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  text-align: left;
}

/* Individual list item button styling */
.home-item-btn {
  display: flex !important;
  align-items: flex-start !important;
  gap: 0.625rem !important;
  width: 100% !important;
  padding: 0.625rem 0.75rem !important;
  border-radius: 0.75rem !important;
  border: 1px solid transparent !important;
  background-color: transparent !important;
  text-align: left !important;
  cursor: pointer !important;
  transition: all 0.15s ease-in-out !important;
  box-sizing: border-box !important;
}
.home-item-btn:hover {
  background-color: #f8fafc !important;
  border-color: #e2e8f0 !important;
}
.home-item-btn.news-item:hover {
  background-color: #fefce8 !important;
  border-color: #fde68a !important;
}
.home-item-btn.vacancy-item:hover {
  background-color: #eff6ff !important;
  border-color: #bfdbfe !important;
}

.home-feature-card button[onclick*="Slide"] {
  background-color: #f8fafc !important;
  border: 1px solid #e2e8f0 !important;
  border-radius: 0.5rem !important;
  width: 1.5rem !important;
  height: 1.5rem !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-weight: 700 !important;
  font-size: 0.75rem !important;
  color: #334155 !important;
}

.home-feature-card button[onclick*="setNewsSlide"],
.home-feature-card button[onclick*="setVacancySlide"],
.home-feature-card button[onclick*="setCelebrantSlide"] {
  border-radius: 9999px !important;
  padding: 0 !important;
  min-width: 0 !important;
  height: 6px !important;
  background-color: #e2e8f0 !important;
}

/* Ensure internal media and containers never overflow */
.home-feature-card img,
.home-tri-card img {
  max-width: 100%;
  height: auto;
  display: block;
}

.home-feature-card svg,
.home-tri-card svg {
  flex-shrink: 0;
}

.home-feature-card *,
.home-tri-card * {
  min-width: 0;
}

/* Birthday Celebration Visual Accents & Animation */
@keyframes floatParticle {
  0% { transform: translateY(0px) rotate(0deg); opacity: 0.8; }
  50% { transform: translateY(-8px) rotate(10deg); opacity: 1; }
  100% { transform: translateY(0px) rotate(0deg); opacity: 0.8; }
}

.celebration-sparkle {
  position: absolute;
  pointer-events: none;
  animation: floatParticle 3.5s ease-in-out infinite;
}

.celebrant-avatar-ring {
  background: linear-gradient(135deg, #f59e0b, #ec4899, #8b5cf6);
  padding: 2.5px;
  border-radius: 9999px;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.25);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.celebrant-avatar-ring img,
.celebrant-avatar-ring .avatar-placeholder {
  border-radius: 9999px;
  border: 2px solid #ffffff;
}

.celebrant-bounce {
  animation: floatParticle 4s ease-in-out infinite;
}

/* ==========================================================================
   Party Confetti & Floating Pastel Balloon Birthday Celebration Theme
   ========================================================================== */

/* Party Container & Celebratory Outer Border */
.birthday-party-container {
  position: relative;
  background: linear-gradient(135deg, #fff7ed 0%, #ffffff 45%, #fdf2f8 100%);
  border: 2px solid #fbcfe8;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 4px 20px -2px rgba(244, 63, 94, 0.08);
  transition: all 0.3s ease;
}

.birthday-party-container:hover {
  border-color: #f472b6;
  box-shadow: 0 8px 25px -4px rgba(244, 63, 94, 0.14);
}

/* Background Confetti & Balloon Layer (Positioned behind content at z-0) */
.birthday-confetti-canvas {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}

/* Continuously Falling & Rotating Paper Confetti */
@keyframes confettiFall {
  0% {
    top: -12px;
    transform: translateY(0) rotate(0deg) scale(1);
    opacity: 0.95;
  }
  25% {
    transform: translateY(0) rotate(180deg) translateX(10px) scale(0.92);
  }
  50% {
    transform: translateY(0) rotate(360deg) translateX(-10px) scale(0.85);
  }
  75% {
    transform: translateY(0) rotate(540deg) translateX(8px) scale(0.78);
  }
  100% {
    top: 105%;
    transform: translateY(0) rotate(720deg) translateX(-6px) scale(0.7);
    opacity: 0;
  }
}

.confetti-piece {
  position: absolute;
  top: -12px;
  pointer-events: none;
  animation: confettiFall 5.5s linear infinite;
  will-change: transform, top, opacity;
}

/* Confetti Shapes & Sizes */
.confetti-rect {
  width: 8px;
  height: 14px;
  border-radius: 2px;
}

.confetti-square {
  width: 9px;
  height: 9px;
  border-radius: 2px;
}

.confetti-circle {
  width: 8px;
  height: 8px;
  border-radius: 9999px;
}

.confetti-ribbon {
  width: 6px;
  height: 16px;
  border-radius: 3px;
}

/* Confetti Colors (Vibrant festive cheerful tones) */
.confetti-c1 { background-color: #f43f5e; } /* Rose */
.confetti-c2 { background-color: #38bdf8; } /* Sky Blue */
.confetti-c3 { background-color: #facc15; } /* Amber Gold */
.confetti-c4 { background-color: #34d399; } /* Mint Green */
.confetti-c5 { background-color: #c084fc; } /* Lavender Purple */
.confetti-c6 { background-color: #fb923c; } /* Tangerine Orange */
.confetti-c7 { background-color: #f472b6; } /* Pink */
.confetti-c8 { background-color: #2dd4bf; } /* Teal */

/* Gentle Floating Pastel Balloons */
@keyframes balloonSway {
  0%, 100% {
    transform: translateY(0px) rotate(0deg);
  }
  50% {
    transform: translateY(-12px) rotate(4deg);
  }
}

.party-balloon {
  position: absolute;
  pointer-events: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  opacity: 0.60;
  animation: balloonSway 4.8s ease-in-out infinite;
  z-index: 0;
}

.balloon-body {
  width: 24px;
  height: 30px;
  border-radius: 50% 50% 50% 50% / 40% 40% 60% 60%;
  position: relative;
  box-shadow: inset -3px -3px 6px rgba(0, 0, 0, 0.08), 0 4px 8px rgba(0, 0, 0, 0.06);
}

.balloon-body::after {
  content: '';
  position: absolute;
  top: 4px;
  left: 5px;
  width: 5px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.65);
}

.balloon-knot {
  width: 4px;
  height: 3px;
  border-radius: 1px;
  margin-top: -1px;
}

.balloon-string {
  width: 1px;
  height: 18px;
  background: rgba(148, 163, 184, 0.5);
}

/* Balloon Colors in Soft Pastels */
.balloon-pink .balloon-body { background: #fbcfe8; border: 1px solid #f472b6; }
.balloon-pink .balloon-knot { background: #f472b6; }
.balloon-blue .balloon-body { background: #bae6fd; border: 1px solid #38bdf8; }
.balloon-blue .balloon-knot { background: #38bdf8; }
.balloon-lavender .balloon-body { background: #e9d5ff; border: 1px solid #c084fc; }
.balloon-lavender .balloon-knot { background: #c084fc; }
.balloon-mint .balloon-body { background: #bbf7d0; border: 1px solid #4ade80; }
.balloon-mint .balloon-knot { background: #4ade80; }
.balloon-yellow .balloon-body { background: #fef08a; border: 1px solid #facc15; }
.balloon-yellow .balloon-knot { background: #facc15; }

/* Foreground Content Container (z-10 ensures content is never covered) */
.birthday-content-layer {
  position: relative;
  z-index: 10;
}

/* Individual Celebrant Card Styles */
.celebrant-card-item {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(4px);
  border: 1.5px solid #fbcfe8;
  border-radius: 0.875rem;
  box-shadow: 0 2px 8px -1px rgba(244, 63, 94, 0.08);
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
}

.celebrant-card-item:hover {
  transform: translateY(-2px);
  border-color: #f472b6;
  box-shadow: 0 6px 16px -2px rgba(244, 63, 94, 0.16);
  background: #ffffff;
}

.celebrant-avatar-pastel-ring {
  background: linear-gradient(135deg, #fbcfe8, #bae6fd, #fef08a);
  padding: 2.5px;
  border-radius: 9999px;
  box-shadow: 0 0 10px rgba(244, 114, 182, 0.25);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.celebrant-avatar-pastel-ring img,
.celebrant-avatar-pastel-ring .avatar-placeholder {
  border-radius: 9999px;
  border: 2px solid #ffffff;
}

/* Responsive Adaptive Grids for Celebrants */
.celebrant-grid-1 {
  display: grid;
  grid-template-columns: 1fr;
  width: 100%;
}

.celebrant-grid-2 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
  width: 100%;
}
@media (min-width: 640px) {
  .celebrant-grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.celebrant-grid-3 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
  width: 100%;
}
@media (min-width: 640px) {
  .celebrant-grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.celebrant-grid-4 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.625rem;
  width: 100%;
}
@media (min-width: 640px) {
  .celebrant-grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (min-width: 1024px) {
  .celebrant-grid-4 {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

.celebrant-grid-multi {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.5rem;
  width: 100%;
}
@media (min-width: 640px) {
  .celebrant-grid-multi {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (min-width: 768px) {
  .celebrant-grid-multi {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (min-width: 1024px) {
  .celebrant-grid-multi {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

/* Schools Top Toolbar - Single Horizontal Row Alignment */
.schools-controls-toolbar {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  flex-wrap: nowrap !important;
  gap: 0.75rem !important;
  width: 100% !important;
}

.schools-filter-pills-row {
  display: flex !important;
  align-items: center !important;
  flex-wrap: nowrap !important;
  gap: 0.375rem !important;
  overflow-x: auto !important;
  -webkit-overflow-scrolling: touch;
  flex-shrink: 0 !important;
}

.school-filter-btn {
  display: inline-flex !important;
  align-items: center !important;
  white-space: nowrap !important;
  flex-shrink: 0 !important;
}

.school-filter-btn span {
  white-space: nowrap !important;
}

.schools-search-box-wrapper {
  position: relative !important;
  flex-shrink: 0 !important;
  margin-left: auto !important;
  width: 220px !important;
  max-width: 240px !important;
}

@media (max-width: 640px) {
  .schools-search-box-wrapper {
    width: 160px !important;
    max-width: 180px !important;
  }
}

/* Employee Search Top Toolbar - Single Horizontal Row Alignment */
.search-controls-toolbar {
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  flex-wrap: nowrap !important;
  gap: 0.75rem !important;
  width: 100% !important;
  overflow: visible !important;
  position: relative !important;
}

.search-filter-controls-row {
  display: flex !important;
  align-items: center !important;
  flex-wrap: nowrap !important;
  gap: 0.5rem !important;
  overflow-x: auto !important;
  -webkit-overflow-scrolling: touch;
  flex-shrink: 0 !important;
}

.search-filter-select {
  white-space: nowrap !important;
  flex-shrink: 0 !important;
  font-size: 0.75rem !important;
  line-height: 1rem !important;
  padding: 0.35rem 0.65rem !important;
  border-radius: 0.5rem !important;
  border: 1px solid #cbd5e1 !important;
  background-color: #f8fafc !important;
  color: #334155 !important;
  cursor: pointer !important;
}

.search-filter-select:hover {
  background-color: #f1f5f9 !important;
  border-color: #94a3b8 !important;
}

.search-box-wrapper {
  position: relative !important;
  flex-shrink: 0 !important;
  margin-left: auto !important;
  display: flex !important;
  align-items: center !important;
  gap: 0.375rem !important;
  width: auto !important;
  max-width: 320px !important;
}

.search-box-wrapper .search-input-field-container {
  position: relative !important;
  width: 190px !important;
  max-width: 220px !important;
}

#search-page-suggestions {
  display: none !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

@media (max-width: 640px) {
  .search-box-wrapper .search-input-field-container {
    width: 135px !important;
    max-width: 155px !important;
  }
}

/* ========================================================
   Mobile Responsiveness, Touch Optimization & Modal Bounds
   ======================================================== */

/* Prevent horizontal viewport spillover on all touch devices */
html, body {
  max-width: 100vw !important;
  overflow-x: hidden !important;
  position: relative;
  -webkit-text-size-adjust: 100%;
}

/* Touch inertia for horizontally scrollable tables */
.table-container,
.overflow-x-auto {
  -webkit-overflow-scrolling: touch !important;
  max-width: 100% !important;
}

/* Mobile Navigation Drawer Animations & Touch Targets */
#mobile-nav-drawer {
  animation: mobileNavSlideDown 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  -webkit-overflow-scrolling: touch;
}

@keyframes mobileNavSlideDown {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

#mobile-nav-drawer button {
  min-height: 44px !important;
  touch-action: manipulation;
}

/* Modal containment and responsiveness across handheld displays */
@media (max-width: 639px) {
  .modal-backdrop {
    padding: 0.5rem !important;
  }
  .modal-backdrop > div {
    width: 100% !important;
    max-width: calc(100vw - 1rem) !important;
    max-height: 92vh !important;
    margin: auto !important;
  }
}

/* Defensive chart responsiveness */
svg {
  max-width: 100%;
}

/* ========================================================
   Accessibility & Readability: Global Typography & Contrast Standards
   ======================================================== */

/* Elevate pale/low-contrast text classes on light surfaces to WCAG AA / AAA compliant tones */
main .text-slate-400:not(.masthead-header *):not(.portal-nav *):not(#mobile-nav-drawer *):not(footer *):not(.bg-\[\#0b3b60\] *):not(.bg-slate-900 *),
#main-content .text-slate-400:not(.masthead-header *):not(.portal-nav *):not(#mobile-nav-drawer *):not(footer *):not(.bg-\[\#0b3b60\] *):not(.bg-slate-900 *),
.modal-backdrop .text-slate-400,
.bg-white .text-slate-400:not(.masthead-header *):not(.portal-nav *):not(#mobile-nav-drawer *):not(footer *):not(.bg-\[\#0b3b60\] *):not(.bg-slate-900 *),
.bg-slate-50 .text-slate-400:not(.masthead-header *):not(.portal-nav *):not(#mobile-nav-drawer *):not(footer *):not(.bg-\[\#0b3b60\] *):not(.bg-slate-900 *),
table .text-slate-400 {
  color: #475569 !important; /* Slate-600: Contrast ratio 7.0:1 on white (WCAG AA > 4.5:1) */
}

main .text-slate-500:not(.masthead-header *):not(.portal-nav *):not(#mobile-nav-drawer *):not(footer *):not(.bg-\[\#0b3b60\] *):not(.bg-slate-900 *),
#main-content .text-slate-500:not(.masthead-header *):not(.portal-nav *):not(#mobile-nav-drawer *):not(footer *):not(.bg-\[\#0b3b60\] *):not(.bg-slate-900 *),
.modal-backdrop .text-slate-500,
.bg-white .text-slate-500:not(.masthead-header *):not(.portal-nav *):not(#mobile-nav-drawer *):not(footer *):not(.bg-\[\#0b3b60\] *):not(.bg-slate-900 *),
.bg-slate-50 .text-slate-500:not(.masthead-header *):not(.portal-nav *):not(#mobile-nav-drawer *):not(footer *):not(.bg-\[\#0b3b60\] *):not(.bg-slate-900 *),
table .text-slate-500 {
  color: #334155 !important; /* Slate-700: Contrast ratio 9.6:1 on white (WCAG AAA) */
}

/* Secondary text readability */
main .text-slate-600:not(.masthead-header *):not(.portal-nav *):not(#mobile-nav-drawer *):not(footer *):not(.bg-\[\#0b3b60\] *):not(.bg-slate-900 *),
#main-content .text-slate-600:not(.masthead-header *):not(.portal-nav *):not(#mobile-nav-drawer *):not(footer *):not(.bg-\[\#0b3b60\] *):not(.bg-slate-900 *),
.modal-backdrop .text-slate-600,
.bg-white .text-slate-600:not(.masthead-header *):not(.portal-nav *):not(#mobile-nav-drawer *):not(footer *):not(.bg-\[\#0b3b60\] *):not(.bg-slate-900 *) {
  color: #1e293b !important; /* Slate-800: Contrast ratio 13.4:1 */
}

/* Scale up micro-fonts that strain readability without breaking layout */
main .text-\[8px\],
#main-content .text-\[8px\],
.modal-backdrop .text-\[8px\] {
  font-size: 11px !important;
}

main .text-\[9px\],
#main-content .text-\[9px\],
.modal-backdrop .text-\[9px\] {
  font-size: 11.5px !important;
}

main .text-\[10px\],
#main-content .text-\[10px\],
.modal-backdrop .text-\[10px\] {
  font-size: 12px !important;
}

main .text-\[11px\],
#main-content .text-\[11px\],
.modal-backdrop .text-\[11px\] {
  font-size: 12.5px !important;
}

/* Table Header and Row Typography Standardization */
table thead th {
  color: #0f172a !important;
  font-weight: 700 !important;
  font-size: 12px !important;
  letter-spacing: 0.03em;
}

table tbody td {
  font-size: 12.5px;
  color: #1e293b;
}

/* Form labels and helper text */
.modal-backdrop label,
#main-content label {
  color: #0f172a !important;
  font-weight: 600;
}

/* Protect dark surfaces - keep high-contrast light text */
.masthead-header .text-slate-400,
.portal-nav .text-slate-400,
#mobile-nav-drawer .text-slate-400,
footer.bg-slate-900 .text-slate-400,
.bg-\[\#0b3b60\] .text-slate-400,
.bg-slate-900 .text-slate-400 {
  color: #cbd5e1 !important; /* Slate-300: High contrast on dark surfaces */
}

.masthead-header .text-slate-500,
.portal-nav .text-slate-500,
#mobile-nav-drawer .text-slate-500,
footer.bg-slate-900 .text-slate-500,
.bg-\[\#0b3b60\] .text-slate-500,
.bg-slate-900 .text-slate-500 {
  color: #e2e8f0 !important; /* Slate-200: High contrast on dark surfaces */
}

footer.bg-slate-900 .text-\[11px\] {
  font-size: 12px !important;
  color: #cbd5e1 !important;
}

/* ============================================================
   Schools Station Cards: Action Button & Interactive Controls
   Accessible Pastel Blue & DepEd Navy / Gold Theme
   ============================================================ */
.school-card-action-btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0.375rem !important; /* 6px */
  width: 100% !important;
  padding: 0.45rem 0.75rem !important;
  border-radius: 0.5rem !important; /* 8px */
  font-size: 0.75rem !important; /* 12px */
  font-weight: 700 !important;
  line-height: 1rem !important;
  background-color: #f0f7ff !important; /* delicate pastel sky blue */
  color: #0b3b60 !important;           /* DepEd navy text */
  border: 1px solid #bfdbfe !important; /* soft pastel border */
  box-shadow: 0 1px 2px 0 rgba(11, 59, 96, 0.05) !important;
  cursor: pointer !important;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1) !important;
  text-decoration: none !important;
  outline: none !important;
}

.school-card-action-btn span {
  color: inherit !important;
  font-weight: 700 !important;
}

.school-card-action-btn svg {
  width: 0.875rem !important;
  height: 0.875rem !important;
  color: #0b3b60 !important;
  transition: transform 0.2s ease, color 0.2s ease !important;
  flex-shrink: 0 !important;
}

/* Hover state: rich pastel blue background (#dbeafe) with ultra-readable navy text (#07253d, contrast > 13.5:1) */
.school-card-action-btn:hover {
  background-color: #dbeafe !important;
  color: #07253d !important;
  border-color: #93c5fd !important;
  box-shadow: 0 3px 8px -1px rgba(11, 59, 96, 0.16), 0 0 0 1px rgba(59, 130, 246, 0.25) !important;
}

.school-card-action-btn:hover span {
  color: #07253d !important;
}

.school-card-action-btn:hover svg {
  color: #07253d !important;
  transform: translateX(3px) !important;
}

/* Active / Pressed state: subtle light gold / amber background distinguishing from hover */
.school-card-action-btn:active,
.school-card-action-btn.active,
.school-card-action-btn[aria-pressed="true"] {
  background-color: #fef3c7 !important; /* light gold/amber */
  color: #78350f !important;           /* dark amber */
  border-color: #f59e0b !important;     /* DepEd gold */
  transform: translateY(1px) !important;
  box-shadow: inset 0 2px 4px rgba(180, 83, 9, 0.15) !important;
}

.school-card-action-btn:active span,
.school-card-action-btn.active span {
  color: #78350f !important;
}

.school-card-action-btn:active svg,
.school-card-action-btn.active svg {
  color: #78350f !important;
  transform: translateX(3px) translateY(1px) !important;
}

/* Focus-visible: accessible navy outline with gold aura */
.school-card-action-btn:focus-visible {
  outline: 2px solid #0b3b60 !important;
  outline-offset: 2px !important;
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.45) !important;
}

/* Parent card hover polish: ensure button retains clear contrast even when card is hovered */
.interactive-card:hover .school-card-action-btn:not(:hover) {
  border-color: #93c5fd;
  background-color: #f0f7ff;
}

/* ==========================================================================
   BETA EVALUATION NOTICE & CALLOUT STYLES
   Subtle Light Yellow / Pale Gold Compact Theme (Beta Viewer Only)
   ========================================================================== */
#beta-evaluation-banner,
.beta-evaluation-banner-bar {
  background: linear-gradient(90deg, #fffbeb 0%, #fefce8 50%, #fef9c3 100%) !important;
  border-bottom: 1px solid #fde047 !important;
  box-shadow: 0 1px 2px rgba(180, 83, 9, 0.05) !important;
  color: #713f12 !important;
}

@media print {
  #beta-evaluation-banner,
  .beta-evaluation-banner-bar,
  #beta-viewer-login-card {
    display: none !important;
  }
}

/* ==========================================================================
   SYSTEM MESSAGES & NOTIFICATIONS - ALWAYS IN FRONT OF ALL INTERFACE ELEMENTS
   Guarantees system messages, toast notifications, confirmation dialogs,
   and alert popups always render in front of all open windows, modals,
   backdrops, dropdowns, sticky headers, and components.
   ========================================================================== */
#toast-container,
.system-toast-container {
  position: fixed !important;
  z-index: 999999 !important;
  pointer-events: none !important;
  max-width: min(92vw, 440px) !important;
}

#toast-container > *,
.system-toast-container > *,
.system-message-toast {
  position: relative !important;
  z-index: 999999 !important;
  pointer-events: auto !important;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.45), 0 10px 10px -5px rgba(0, 0, 0, 0.3) !important;
  filter: drop-shadow(0 10px 8px rgba(0, 0, 0, 0.25));
}

/* System Confirmation & Security Modals (Must overlay standard modals) */
#confirm-modal,
#user-delete-confirm-modal,
#clc-delete-confirm-modal,
#role-delete-modal,
#password-display-modal {
  z-index: 90000 !important;
}

#force-change-password-modal {
  z-index: 95000 !important;
}



