/* BENEPESO shared presentation layer.
   Loaded last so existing pages retain their layout while sharing a consistent
   accessibility, interaction, and responsive baseline. */
:root {
  --bp-color-primary: #176b49;
  --bp-color-primary-hover: #10573b;
  --bp-color-primary-soft: #eaf5ef;
  --bp-color-text: #183127;
  --bp-color-muted: #60756b;
  --bp-color-surface: #ffffff;
  --bp-color-canvas: #f5f8f6;
  --bp-color-border: #dbe6df;
  --bp-color-danger: #b42318;
  --bp-color-warning: #a15c00;
  --bp-focus: #f5a524;
  --bp-radius-sm: 8px;
  --bp-radius-md: 12px;
  --bp-radius-lg: 16px;
  --bp-shadow-sm: 0 1px 3px rgba(16, 51, 35, .08);
  --bp-shadow-md: 0 12px 32px rgba(16, 51, 35, .12);
}

html { color-scheme: light; scroll-behavior: smooth; overflow-x: hidden; }
body { color: var(--bp-color-text); text-rendering: optimizeLegibility; overflow-x: hidden; }
*, *::before, *::after { box-sizing: border-box; }
img, video, canvas, svg { max-width: 100%; }

/* Long names, codes and uploaded filenames must shrink with their card. */
:where(.main-area, .panel-card, .content-card, .stat-card, .program-card,
       .top-area, .top-left, .top-actions, .panel-head, .card-body,
       .form-group, .modal-head, .modal-form, .modal-content) {
  min-width: 0;
}

:where(.panel-title, .panel-sub, .top-big, .top-small, .card-title,
       .card-desc, .user-name, .user-role, td, .modal-title, .modal-sub) {
  overflow-wrap: anywhere;
}

:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible {
  outline: 3px solid var(--bp-focus) !important;
  outline-offset: 3px !important;
}

:where(button, .btn, .btn-main, .modal-btn, [class*="btn-"]) {
  min-height: 42px;
  transition: background-color .2s ease, border-color .2s ease,
              color .2s ease, box-shadow .2s ease, transform .2s ease;
}

:where(button, .btn, .btn-main, .modal-btn, [class*="btn-"]):disabled {
  cursor: not-allowed;
  opacity: .58;
}

:where(input, select, textarea) {
  accent-color: var(--bp-color-primary);
  font-family: inherit;
}

:where(input[type="date"], input[type="datetime-local"], input[type="time"]) {
  color: var(--bp-color-text);
  font-family: inherit !important;
  font-size: 13.5px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

:where(input, select, textarea):not([type="checkbox"]):not([type="radio"]):not([type="hidden"]) {
  min-height: 44px;
}

:where(input, select, textarea)[aria-invalid="true"] {
  border-color: var(--bp-color-danger) !important;
  box-shadow: 0 0 0 3px rgba(180, 35, 24, .12) !important;
}

:where(.flash, .alert, .notice, .error-message, .success-message) {
  border-radius: var(--bp-radius-md);
}

:where(.card, .stat-card, .program-card, .auth-card, .content-card) {
  border-color: var(--bp-color-border);
  box-shadow: var(--bp-shadow-sm);
}

:where(.table-wrap, .table-wrapper, .table-container, .activity-table-wrap, .data-table-wrap) {
  max-width: 100%;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

:where(table) {
  border-collapse: separate;
  border-spacing: 0;
}

:where(table) :where(th) {
  white-space: nowrap;
}

:where(table) tbody tr {
  transition: background-color .16s ease;
}

:where(table) tbody tr:hover {
  background-color: rgba(23, 107, 73, .045);
}

:where(.modal-dialog, .modal-content, .modal-box, .modal-landscape) {
  max-width: calc(100vw - 32px);
  max-height: min(90vh, 900px);
  max-height: min(90dvh, 900px);
}

:where(.modal-form, .modal-body, .details-body) {
  min-height: 0;
  overscroll-behavior: contain;
}

:where(.modal-close, .modal-close-btn, .modal-close-icon) {
  align-items: center;
  display: inline-flex;
  justify-content: center;
  min-height: 44px;
  min-width: 44px;
}

.bp-sr-only {
  border: 0 !important;
  clip: rect(0 0 0 0) !important;
  clip-path: inset(50%) !important;
  height: 1px !important;
  margin: -1px !important;
  overflow: hidden !important;
  padding: 0 !important;
  position: absolute !important;
  white-space: nowrap !important;
  width: 1px !important;
}

@media (max-width: 768px) {
  /* Keep the beneficiary account dropdown closed until its name button is used. */
  .menu-area .account-dropdown {
    display: none !important;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
  }

  .menu-area .account-dropdown.show {
    display: block !important;
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  :where(.app-shell, .dashboard-shell, .layout, .page-layout) {
    max-width: 100vw;
    min-width: 0;
  }

  :where(.main-area, .content-container, .page-wrap) {
    max-width: 100%;
    min-width: 0;
  }

  :where(.filter-bar, .filter-row, .toolbar, .top-actions, .modal-actions,
         .modal-actions-flex, .form-actions) {
    gap: 10px;
    flex-wrap: wrap;
  }

  :where(.stats-grid, .program-grid, .cards-grid, .card-grid,
         .form-grid, .form-grid-2, .info-grid, .landscape-form-grid) {
    grid-template-columns: minmax(0, 1fr);
  }

  :where(.panel-head, .records-toolbar, .pagination-wrapper, .pagination-bar) {
    align-items: stretch;
    flex-wrap: wrap;
  }

  :where(.search-wrap, .filter-form, .toolbar-form, .filter-container,
         .advanced-filter-row) {
    max-width: 100%;
    min-width: 0;
  }

  :where(input, select, textarea) {
    max-width: 100%;
  }

  :where(.modal-dialog, .modal-content, .modal-box, .modal-landscape) {
    margin: 0;
    max-height: calc(100dvh - 24px);
    max-width: calc(100vw - 24px) !important;
    overflow-y: auto;
    width: calc(100vw - 24px) !important;
  }

  :where(.modal-actions, .modal-actions-flex) > :where(button, a) {
    flex: 1 1 150px;
  }

  :where(.data-table, .activity-table, .spreadsheet-table) {
    min-width: 720px;
  }
}

@media (max-width: 480px) {
  :where(.main-area) {
    padding-left: 10px !important;
    padding-right: 10px !important;
  }

  :where(.top-area, .panel-card, .content-card) {
    border-radius: 14px !important;
  }

  :where(.panel-card, .content-card) {
    padding-left: 14px !important;
    padding-right: 14px !important;
  }

  :where(.btn-main, .modal-btn, .form-actions > button, .form-actions > a) {
    width: 100%;
  }

  :where(.modal) {
    padding: 0 !important;
  }

  :where(.modal-dialog, .modal-content, .modal-box, .modal-landscape) {
    width: 100vw !important;
    max-width: 100vw !important;
    max-height: 100dvh;
    border-radius: 0 !important;
  }

  :where(.modal-head, .modal-head-alt, .modal-head-sm) {
    padding-left: 16px !important;
    padding-right: 16px !important;
  }

  :where(.modal-form, .modal-body, .details-body) {
    padding-left: 16px;
    padding-right: 16px;
  }

  :where(.modal-actions, .modal-actions-flex, .form-actions) {
    align-items: stretch;
    flex-direction: column;
  }

  :where(.modal-actions, .modal-actions-flex, .form-actions) > :where(button, a) {
    flex: 0 0 auto;
    width: 100%;
  }

  :where(.pagination-controls) {
    max-width: 100%;
    overflow-x: auto;
  }
}

/* Short landscape phones need the same scrollable dialogs as narrow portrait phones. */
@media (max-height: 560px) and (orientation: landscape) {
  :where(.modal) { align-items: flex-start; overflow-y: auto; padding: 8px !important; }
  :where(.modal-dialog, .modal-content, .modal-box, .modal-landscape) {
    max-height: calc(100dvh - 16px);
  }
}

/* Beneficiary-facing footer: one canonical layout across public pages. */
.site-footer {
  width: 100%;
  margin-top: auto;
  padding: 58px 0 24px;
  border: 0;
  background: #0b2f20;
  color: rgba(255, 255, 255, .68);
}

.site-footer .content-wrap {
  width: min(1180px, calc(100% - 40px));
  margin-inline: auto;
}

.site-footer .footer-grid {
  display: grid;
  grid-template-columns: minmax(260px, 1.5fr) minmax(150px, .75fr) minmax(240px, 1fr);
  gap: 54px;
  align-items: start;
  text-align: left;
}

.site-footer .footer-brand {
  display: flex;
  grid-column: auto;
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  gap: 15px;
  text-align: left;
}

.site-footer .footer-logo {
  width: 58px;
  height: 58px;
  flex: 0 0 58px;
  padding: 3px;
  border-radius: 50%;
  background: #fff;
  object-fit: contain;
}

.site-footer .footer-title {
  color: #fff;
  font-size: 22px;
  font-weight: 900;
  letter-spacing: 0;
}

.site-footer .footer-sub {
  margin-top: 4px;
  color: rgba(255, 255, 255, .68);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.55;
  letter-spacing: 0;
  text-transform: uppercase;
}

.site-footer .footer-col { text-align: left; }
.site-footer .footer-col .footer-head {
  margin-bottom: 18px;
  color: #fff;
  font-size: 14px;
  font-weight: 900;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.site-footer .footer-col a {
  display: block;
  width: fit-content;
  margin: 11px 0;
  color: rgba(255, 255, 255, .68);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
}

.site-footer .footer-col a:hover,
.site-footer .footer-col a:focus-visible { color: #fff; transform: translateX(4px); }
.site-footer .footer-text {
  margin-bottom: 8px;
  color: rgba(255, 255, 255, .68);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.7;
}

.site-footer .footer-bottom {
  display: flex;
  margin-top: 44px;
  padding-top: 22px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid rgba(255, 255, 255, .1);
  color: rgba(255, 255, 255, .48);
  font-size: 12px;
  font-weight: 500;
  text-align: left;
}

.site-footer .footer-mini { letter-spacing: .04em; text-transform: uppercase; }

@media (max-width: 768px) {
  .site-footer { padding: 44px 0 22px; }
  .site-footer .content-wrap { width: min(calc(100% - 32px), 680px); }
  .site-footer .footer-grid { grid-template-columns: 1fr; gap: 34px; }
  .site-footer .footer-brand,
  .site-footer .footer-col { justify-content: center; text-align: center; }
  .site-footer .footer-brand { flex-direction: column; }
  .site-footer .footer-col a { margin-left: auto; margin-right: auto; }
  .site-footer .footer-bottom {
    margin-top: 34px;
    align-items: center;
    flex-direction: column;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .site-footer .content-wrap { width: calc(100% - 24px); }
  .site-footer .footer-brand { align-items: center; }
  .site-footer .footer-logo { width: 52px; height: 52px; flex-basis: 52px; }
  .site-footer .footer-title { font-size: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: .01ms !important;
  }
}

@media print {
  :where(.sidebar, .topbar, .top-area, .filters, .filter-bar, .toolbar,
         button, [class*="btn-"]) { display: none !important; }
  body { background: #fff !important; color: #000 !important; }
  :where(.main-area, .content-container, .page-wrap) { margin: 0 !important; width: 100% !important; }
}

/* Management UI consistency layer: shared by Admin and PESO Staff. */
:root {
  --bp-color-primary: #1f7a54;
  --bp-color-primary-hover: #176443;
  --bp-color-primary-active: #125238;
  --bp-color-primary-soft: #edf8f2;
  --bp-color-danger: #b42318;
  --bp-color-danger-soft: #fef2f2;
  --bp-color-warning: #a15c00;
  --bp-color-warning-soft: #fff8e8;
  --bp-motion-standard: cubic-bezier(.2, .8, .2, 1);
}

/* Icons should support labels, not change the meaning of an action. */
:where(button, .btn, .btn-main, .btn-light, [class*="btn-"], .nav-item) > i {
  flex: 0 0 auto;
  line-height: 1;
  vertical-align: -.08em;
}

:where(.btn-main, button.btn-main) {
  border-color: var(--bp-color-primary) !important;
  background-color: var(--bp-color-primary) !important;
  color: #fff !important;
}

:where(.btn-main, button.btn-main):hover:not(:disabled) {
  border-color: var(--bp-color-primary-hover) !important;
  background-color: var(--bp-color-primary-hover) !important;
  box-shadow: 0 8px 20px rgba(31, 122, 84, .2);
  transform: translateY(-1px);
}

:where(.btn-main, button.btn-main):active:not(:disabled) {
  border-color: var(--bp-color-primary-active) !important;
  background-color: var(--bp-color-primary-active) !important;
  box-shadow: none;
  transform: translateY(0) scale(.985);
}

:where(.btn-light, .btn-secondary, .btn-edit) {
  border-color: var(--bp-color-border) !important;
}

:where(.btn-light, .btn-secondary, .btn-edit):hover:not(:disabled) {
  border-color: #9fcdb6 !important;
  background-color: var(--bp-color-primary-soft) !important;
  color: var(--bp-color-primary) !important;
}

:where(.btn-danger, .btn-reject, .btn-icon-reject, .btn-remove-row,
       .btn-ghost-danger):hover:not(:disabled) {
  border-color: #ef9a92 !important;
  background-color: var(--bp-color-danger-soft) !important;
  color: var(--bp-color-danger) !important;
}

/* Subtle motion adds hierarchy without delaying work. */
.bp-ui-ready :where(.top-area, .stats-grid, .panel-card, .content-card, .program-grid) {
  animation: bp-reveal .42s var(--bp-motion-standard) both;
}
.bp-ui-ready :where(.stats-grid, .program-grid) { animation-delay: .05s; }
.bp-ui-ready :where(.panel-card, .content-card) { animation-delay: .09s; }

:where(.stat-card, .program-card, .content-card) {
  transition: border-color .2s ease, box-shadow .25s ease, transform .25s var(--bp-motion-standard);
}

:where(.stat-card, .program-card):hover {
  border-color: #c8ddd1;
  box-shadow: 0 12px 28px rgba(16, 51, 35, .1);
  transform: translateY(-2px);
}

:where(.modal.show, .modal-overlay.show, .modal-bg.show)
  :where(.modal-dialog, .modal-content, .modal-box, .modal-landscape) {
  animation: bp-dialog-in .24s var(--bp-motion-standard) both;
}

@keyframes bp-reveal {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes bp-dialog-in {
  from { opacity: 0; transform: translateY(10px) scale(.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* Fluid management typography and predictable controls at every width. */
:where(.top-big, .page-title) { font-size: clamp(1.65rem, 2.2vw, 2.35rem); }
:where(.panel-title, .card-title) { line-height: 1.25; }

@media (max-width: 1200px) {
  :where(.main-area, .content-container, .page-wrap) { min-width: 0; }
  :where(.stats-grid) { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  /* Center the final card when a two-column summary has an odd card count. */
  :where(.stats-grid) > .stat-card:last-child:nth-child(odd) {
    grid-column: 1 / -1;
    justify-self: center;
    width: calc((100% - 20px) / 2);
  }
}

@media (hover: none), (pointer: coarse) {
  :where(a, button, input, select, textarea, summary, [role="button"]) { min-height: 44px; }
  :where(.stat-card, .program-card):hover { transform: none; }
}

@media (max-width: 768px) {
  :where(.top-big, .page-title) { font-size: clamp(1.55rem, 7vw, 2rem); }
  :where(.stats-grid) { grid-template-columns: minmax(0, 1fr); }
  :where(.stats-grid) > .stat-card:last-child:nth-child(odd) {
    grid-column: auto;
    width: 100%;
  }
  :where(.top-actions) > :where(button, a) { min-width: 0; }
}

@media (max-width: 360px) {
  :where(.main-area) { padding-inline: 8px !important; }
  :where(.panel-card, .content-card) { padding-inline: 12px !important; }
  :where(button, .btn, .btn-main, .btn-light, [class*="btn-"]) {
    max-width: 100%;
    white-space: normal;
  }
}

@media (prefers-reduced-motion: reduce) {
  .bp-ui-ready :where(.top-area, .stats-grid, .panel-card, .content-card, .program-grid),
  :where(.modal.show, .modal-overlay.show, .modal-bg.show)
    :where(.modal-dialog, .modal-content, .modal-box, .modal-landscape) {
    animation: none !important;
  }
}

/* Public navigation: keep labels visible in every hover, focus and active state. */
.topbar .menu-area .menu-item {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: max-content;
  opacity: 1;
  text-indent: 0;
  -webkit-text-fill-color: currentColor;
}

.topbar .menu-area .menu-item:hover:not(.active),
.topbar .menu-area .menu-item:focus-visible:not(.active) {
  color: #176f4c !important;
  -webkit-text-fill-color: #176f4c;
}

.topbar .menu-area .menu-item.active,
.topbar .menu-area .menu-item.active:hover,
.topbar .menu-area .menu-item.active:focus-visible {
  color: #fff !important;
  -webkit-text-fill-color: #fff;
}

/* Give the signed-in identity a clearer, premium boundary without changing layout. */
.topbar .account-button {
  border: 2px solid transparent !important;
  background:
    linear-gradient(#fff, #fff) padding-box,
    linear-gradient(135deg, #1f7a54 0%, #7ab895 55%, #d6ad35 100%) border-box !important;
  box-shadow: 0 7px 18px rgba(17, 74, 50, .09), inset 0 0 0 1px rgba(255, 255, 255, .7);
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.topbar .account-button:hover,
.topbar .account-button:focus-visible,
.topbar .account-button[aria-expanded="true"] {
  transform: translateY(-1px);
  box-shadow: 0 11px 24px rgba(17, 74, 50, .15), 0 0 0 4px rgba(31, 122, 84, .08);
}

.topbar .account-button .account-icon {
  outline: 2px solid rgba(214, 173, 53, .5);
  outline-offset: 2px;
  box-shadow: 0 3px 9px rgba(18, 72, 50, .18);
}

.topbar .account-button .account-arrow {
  transition: transform .2s ease;
}

.topbar .account-button[aria-expanded="true"] .account-arrow {
  transform: rotate(180deg);
}

/* Chrome autofill must not paint a yellow block over beneficiary search fields. */
.records-filter-container input:-webkit-autofill,
.records-filter-container input:-webkit-autofill:hover,
.records-filter-container input:-webkit-autofill:focus {
  -webkit-text-fill-color: #183c2f !important;
  -webkit-box-shadow: 0 0 0 1000px #fff inset !important;
  box-shadow: 0 0 0 1000px #fff inset !important;
  caret-color: #183c2f;
}

/* Report controls stay compact and aligned; selects share one intentional arrow. */
#generateReportModal .report-form {
  gap: 12px;
}

#generateReportModal .report-form > div[style*="overflow-y: auto"] {
  flex: 0 1 auto !important;
  min-height: 0;
  max-height: calc(100vh - 235px);
  align-content: start;
}

#generateReportModal .report-form select {
  width: 100%;
  min-height: 44px;
  padding: 9px 40px 9px 12px !important;
  border: 1px solid #cfe0d7 !important;
  border-radius: 10px !important;
  color: #173b2e;
  background-color: #fff !important;
  background-image: linear-gradient(45deg, transparent 50%, #48715f 50%), linear-gradient(135deg, #48715f 50%, transparent 50%) !important;
  background-position: calc(100% - 18px) 50%, calc(100% - 12px) 50% !important;
  background-size: 6px 6px, 6px 6px !important;
  background-repeat: no-repeat !important;
  appearance: none;
  -webkit-appearance: none;
}

#generateReportModal .report-actions {
  margin-top: auto;
}

/* Contact details remain readable and keyboard-accessible in every public footer. */
.site-footer .footer-contact-link {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  width: fit-content;
  max-width: 100%;
  color: inherit;
  text-decoration: none;
  overflow-wrap: anywhere;
}

.site-footer .footer-contact-link i {
  flex: 0 0 24px;
  width: 24px;
  height: 24px;
  margin-top: 0;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(147, 212, 178, .5);
  border-radius: 50%;
  color: #a7e2c2;
  text-align: center;
  font-style: normal;
  font-weight: 800;
  line-height: 1;
}

.site-footer .footer-contact-link .fa-envelope::before { content: "\2709"; }
.site-footer .footer-contact-link .fa-phone::before { content: "\260E"; }
.site-footer .footer-contact-link .fa-facebook::before {
  content: "f";
  color: #a7e2c2;
  font: 800 12px/1 Arial, sans-serif;
}

.site-footer .footer-contact-link:hover,
.site-footer .footer-contact-link:focus-visible {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 3px;
}

html.bp-contact-open,
html.bp-contact-open body {
  overflow: hidden !important;
}

.bp-contact-modal {
  position: fixed;
  inset: 0;
  z-index: 2147483200;
  display: none;
  place-items: center;
  padding: 20px;
}

.bp-contact-modal.show { display: grid; }

.bp-contact-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  min-height: 0;
  border: 0;
  background: rgba(8, 35, 25, .66);
  backdrop-filter: blur(7px);
  cursor: default;
}

.bp-contact-dialog {
  position: relative;
  z-index: 1;
  width: min(430px, calc(100vw - 32px));
  padding: 32px;
  overflow: hidden;
  border: 1px solid #d6e8de;
  border-radius: 22px;
  color: #173b2e;
  background: #fff;
  box-shadow: 0 28px 80px rgba(7, 33, 23, .3);
  animation: bp-contact-in .25s cubic-bezier(.2, .8, .2, 1) both;
}

.bp-contact-dialog::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 5px;
  background: linear-gradient(90deg, #176b49, #54ae7f 70%, #d5a62e);
}

.bp-contact-kicker {
  display: inline-flex;
  margin-bottom: 7px;
  color: #1f7a54;
  font: 800 11px/1.3 Poppins, sans-serif;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.bp-contact-dialog h2 {
  margin: 0;
  color: #123f2f;
  font: 800 clamp(1.25rem, 4vw, 1.55rem)/1.25 Poppins, sans-serif;
}

.bp-contact-copy {
  margin: 9px 0 20px;
  color: #637b70;
  font: 500 13px/1.6 Poppins, sans-serif;
}

.bp-contact-number {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 15px 16px;
  border: 1px solid #cfe4d8;
  border-radius: 13px;
  background: #f2f9f5;
}

.bp-contact-number > span {
  display: grid;
  flex: 0 0 34px;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: #1f7a54;
}

.bp-contact-number strong {
  min-width: 0;
  color: #143d2e;
  font: 800 clamp(1rem, 5vw, 1.2rem)/1.3 Poppins, sans-serif;
  letter-spacing: .015em;
  overflow-wrap: anywhere;
}

.bp-contact-copy-button {
  width: 100%;
  margin-top: 14px;
  border: 0;
  border-radius: 11px;
  color: #fff;
  background: #176b49;
  font: 700 13px/1 Poppins, sans-serif;
  cursor: pointer;
}

.bp-contact-copy-button:hover { background: #10573b; }

.bp-contact-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 40px;
  min-width: 40px;
  height: 40px;
  min-height: 40px;
  border: 1px solid #d7e6de;
  border-radius: 50%;
  color: #476458;
  background: #fff;
  font: 400 24px/1 Arial, sans-serif;
  cursor: pointer;
}

.bp-contact-status {
  min-height: 20px;
  margin: 9px 0 -9px;
  color: #1f7a54;
  font: 700 12px/1.5 Poppins, sans-serif;
  text-align: center;
}

@keyframes bp-contact-in {
  from { opacity: 0; transform: translateY(12px) scale(.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@media (max-width: 720px) {
  .topbar .account-button {
    border-width: 1.5px !important;
  }

  #generateReportModal .report-form > div[style*="overflow-y: auto"] {
    max-height: none;
  }

  .bp-contact-dialog { padding: 28px 20px 24px; }
}

/* BENEPESO page loader: isolated from existing component and modal styles. */
html.bp-page-loading,
html.bp-page-loading body {
  overflow: hidden !important;
}

.bp-page-loader {
  --bp-loader-green: #1f7a54;
  --bp-loader-deep: #124c36;
  --bp-loader-mint: #dff4e8;
  position: fixed;
  inset: 0;
  z-index: 2147483000;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 10px;
  min-height: 100dvh;
  padding: 24px;
  color: var(--bp-loader-deep);
  background:
    radial-gradient(circle at 50% 42%, rgba(31, 122, 84, .08), transparent 31%),
    #fff;
  opacity: 1;
  visibility: visible;
  transition: opacity .32s ease, visibility .32s ease;
}

.bp-page-loader.is-leaving {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.bp-loader-visual {
  position: relative;
  width: clamp(176px, 23vw, 218px);
  height: 168px;
  display: grid;
  place-items: center;
}

.bp-loader-glow {
  position: absolute;
  width: 142px;
  height: 142px;
  border-radius: 50%;
  background: rgba(31, 122, 84, .1);
  animation: bp-loader-breathe 1.8s ease-in-out infinite;
}

.bp-loader-card {
  position: relative;
  z-index: 1;
  width: 100%;
  height: auto;
  overflow: visible;
  filter: drop-shadow(0 15px 20px rgba(18, 76, 54, .14));
  animation: bp-loader-card-float 2.1s ease-in-out infinite;
}

.bp-loader-card-bg {
  fill: #fff;
}

.bp-loader-card-line,
.bp-loader-profile-head,
.bp-loader-profile-body,
.bp-loader-info {
  fill: none;
  stroke: var(--bp-loader-green);
  stroke-linecap: round;
  stroke-linejoin: round;
}

.bp-loader-card-line {
  stroke: var(--bp-loader-deep);
  stroke-width: 4;
}

.bp-loader-profile-head {
  fill: var(--bp-loader-mint);
  stroke-width: 4;
}

.bp-loader-profile-body {
  fill: rgba(31, 122, 84, .08);
  stroke-width: 4;
}

.bp-loader-info {
  stroke-width: 6;
  opacity: .78;
  stroke-dasharray: 52;
  stroke-dashoffset: 52;
  animation: bp-loader-draw 1.8s ease-in-out infinite;
}

.bp-loader-info-two { animation-delay: .14s; opacity: .55; }
.bp-loader-info-three { animation-delay: .28s; opacity: .68; }

.bp-loader-scan {
  fill: none;
  stroke: #d5a928;
  stroke-width: 3;
  stroke-linecap: round;
  opacity: 0;
  filter: drop-shadow(0 0 5px rgba(213, 169, 40, .55));
  animation: bp-loader-scan 1.8s ease-in-out infinite;
}

.bp-loader-approval-ring {
  fill: var(--bp-loader-green);
  stroke: #fff;
  stroke-width: 4;
  filter: drop-shadow(0 6px 8px rgba(18, 76, 54, .2));
}

.bp-loader-approval-check {
  fill: none;
  stroke: #fff;
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 36;
  animation: bp-loader-approval-draw 1.8s ease-in-out infinite;
}

.bp-loader-brand {
  display: grid;
  justify-items: center;
  gap: 3px;
  text-align: center;
}

.bp-loader-brand strong {
  color: var(--bp-loader-deep);
  font: 800 clamp(1.15rem, 2vw, 1.42rem)/1.1 Poppins, Inter, system-ui, sans-serif;
  letter-spacing: .12em;
}

.bp-loader-brand span {
  color: #527164;
  font: 700 9px/1.3 Poppins, Inter, system-ui, sans-serif;
  letter-spacing: .09em;
  text-transform: uppercase;
}

.bp-page-loader > p {
  margin: 2px 0 0;
  color: #71867c;
  font: 600 11px/1.3 Poppins, Inter, system-ui, sans-serif;
}

.bp-loader-progress {
  position: relative;
  width: clamp(180px, 24vw, 225px);
  height: 3px;
  margin-top: 3px;
  overflow: hidden;
  border-radius: 999px;
  background: #dfebe5;
}

.bp-loader-progress span {
  position: absolute;
  inset-block: 0;
  left: 0;
  width: 42%;
  border-radius: inherit;
  background: linear-gradient(90deg, transparent, var(--bp-loader-green) 25%, #d5a928 78%, transparent);
  animation: bp-loader-progress 1.25s cubic-bezier(.45, 0, .55, 1) infinite;
}

.bp-loader-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@keyframes bp-loader-card-float {
  0%, 100% { transform: translateY(2px) rotate(-.45deg); }
  50% { transform: translateY(-4px) rotate(.45deg); }
}

@keyframes bp-loader-breathe {
  0%, 100% { opacity: .55; transform: scale(.9); }
  50% { opacity: 1; transform: scale(1.06); }
}

@keyframes bp-loader-draw {
  0%, 12% { stroke-dashoffset: 52; }
  45%, 82% { stroke-dashoffset: 0; }
  100% { stroke-dashoffset: -52; }
}

@keyframes bp-loader-scan {
  0%, 12% { opacity: 0; transform: translateY(-43px); }
  22% { opacity: .9; }
  66% { opacity: .9; transform: translateY(38px); }
  78%, 100% { opacity: 0; transform: translateY(38px); }
}

@keyframes bp-loader-approval-draw {
  0%, 28% { stroke-dashoffset: 36; opacity: .25; }
  52%, 82% { stroke-dashoffset: 0; opacity: 1; }
  100% { stroke-dashoffset: -36; opacity: .25; }
}

@keyframes bp-loader-progress {
  0% { transform: translateX(-110%); }
  55% { width: 54%; }
  100% { width: 42%; transform: translateX(285%); }
}

@media (max-width: 480px) {
  .bp-page-loader { gap: 9px; }
  .bp-loader-visual { width: 184px; height: 150px; }
}

@media (prefers-reduced-motion: reduce) {
  .bp-loader-glow,
  .bp-loader-card,
  .bp-loader-info,
  .bp-loader-scan,
  .bp-loader-approval-check,
  .bp-loader-progress span {
    animation: none !important;
  }

  .bp-loader-info { stroke-dashoffset: 0; }
  .bp-loader-scan { opacity: 0; }
  .bp-loader-approval-check { opacity: 1; stroke-dashoffset: 0; }
}

/* Contextual action loaders for authentication and record-changing submissions. */
html.bp-action-loading,
html.bp-action-loading body {
  overflow: hidden !important;
}

.bp-action-loader {
  --bp-action-color: #1f7a54;
  --bp-action-soft: #e5f4ec;
  position: fixed;
  inset: 0;
  z-index: 2147483100;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 13px;
  min-height: 100dvh;
  width: 100%;
  box-sizing: border-box;
  overflow: hidden;
  padding: 24px;
  color: #124c36;
  background: rgba(255, 255, 255, .98);
  opacity: 1;
  visibility: visible;
  transition: opacity .24s ease, visibility .24s ease;
}

.bp-action-loader.is-leaving {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.bp-action-loader--login { --bp-action-color: #176d54; --bp-action-soft: #e2f4eb; }
.bp-action-loader--logout { --bp-action-color: #526b61; --bp-action-soft: #edf2ef; }
.bp-action-loader--approve { --bp-action-color: #168354; --bp-action-soft: #e0f5e9; }
.bp-action-loader--reject { --bp-action-color: #c84343; --bp-action-soft: #fde9e9; }
.bp-action-loader--status { --bp-action-color: #24758a; --bp-action-soft: #e2f2f5; }

.bp-action-visual {
  position: relative;
  width: clamp(128px, 17vw, 154px);
  height: clamp(128px, 17vw, 154px);
  display: grid;
  place-items: center;
  border: 1px solid color-mix(in srgb, var(--bp-action-color) 18%, white);
  border-radius: 36%;
  color: var(--bp-action-color);
  background: radial-gradient(circle, #fff 0 50%, var(--bp-action-soft) 51% 100%);
  box-shadow: 0 19px 42px color-mix(in srgb, var(--bp-action-color) 16%, transparent);
  animation: bp-action-float 2s ease-in-out infinite;
}

.bp-action-visual::before,
.bp-action-visual::after {
  content: "";
  position: absolute;
  inset: -8px;
  border: 1px solid color-mix(in srgb, var(--bp-action-color) 22%, transparent);
  border-radius: 38%;
  animation: bp-action-ripple 1.8s ease-out infinite;
}

.bp-action-visual::after { animation-delay: .65s; }
.bp-action-visual > svg { width: 74%; height: 74%; overflow: visible; }
.bp-action-visual svg * { vector-effect: non-scaling-stroke; }

.bp-action-orbit,
.bp-action-shield,
.bp-action-lock,
.bp-action-door,
.bp-action-arrow,
.bp-action-document,
.bp-action-document-lines,
.bp-action-stamp,
.bp-action-status-card,
.bp-action-status-lines,
.bp-action-status-ring,
.bp-action-save-tray,
.bp-action-save-pulse {
  fill: none;
  stroke: currentColor;
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.bp-action-orbit { stroke-width: 2; stroke-dasharray: 18 10; opacity: .38; transform-origin: center; animation: bp-action-spin 5s linear infinite; }
.bp-action-shield { fill: color-mix(in srgb, var(--bp-action-soft) 70%, white); }
.bp-action-lock { stroke-width: 4.5; }
.bp-action-loader--login .bp-action-lock { animation: bp-action-lock-pulse 1.25s ease-in-out infinite; transform-origin: 80px 84px; }

.bp-action-door { fill: color-mix(in srgb, var(--bp-action-soft) 60%, white); }
.bp-action-knob { fill: currentColor; }
.bp-action-arrow { stroke-width: 5; animation: bp-action-exit 1.1s ease-in-out infinite; }

.bp-action-document { fill: color-mix(in srgb, var(--bp-action-soft) 50%, white); }
.bp-action-document-lines { opacity: .55; }
.bp-action-stamp { fill: var(--bp-action-color); stroke: #fff; stroke-width: 5; }
.bp-action-loader--approve .bp-action-stamp ~ path,
.bp-action-loader--reject .bp-action-stamp ~ path { stroke: #fff; stroke-width: 5; fill: none; stroke-linecap: round; stroke-linejoin: round; }
.bp-action-loader--approve .bp-action-stamp,
.bp-action-loader--approve .bp-action-stamp ~ path,
.bp-action-loader--reject .bp-action-stamp,
.bp-action-loader--reject .bp-action-stamp ~ path {
  transform-origin: 114px 111px;
  animation: bp-action-stamp-in 1.35s cubic-bezier(.2, .8, .2, 1) infinite;
}

.bp-action-status-card { fill: color-mix(in srgb, var(--bp-action-soft) 55%, white); }
.bp-action-status-lines { opacity: .65; }
.bp-action-status-ring { stroke-width: 4.5; transform-origin: center; animation: bp-action-spin 2.4s linear infinite; }

.bp-action-save-tray { stroke-width: 5; }
.bp-action-save-pulse { stroke: #d5a928; stroke-width: 4; stroke-dasharray: 64; animation: bp-action-save-line 1.3s ease-in-out infinite; }

.bp-action-copy {
  width: min(360px, calc(100vw - 44px));
  min-width: 0;
  max-width: 100%;
  display: grid;
  justify-items: center;
  gap: 5px;
  text-align: center;
}

.bp-action-copy strong {
  display: block;
  max-width: 100%;
  color: #163f31;
  font: 800 clamp(1.05rem, 2.5vw, 1.3rem)/1.2 Poppins, Inter, system-ui, sans-serif;
  letter-spacing: -.015em;
  overflow-wrap: anywhere;
}

.bp-action-copy span {
  display: block;
  max-width: 100%;
  color: #6a8076;
  font: 500 clamp(.72rem, 1.5vw, .82rem)/1.55 Poppins, Inter, system-ui, sans-serif;
  overflow-wrap: anywhere;
}

.bp-action-dots { display: flex; align-items: center; gap: 6px; height: 14px; }
.bp-action-dots i {
  width: 6px;
  height: 6px;
  display: block;
  border-radius: 50%;
  background: var(--bp-action-color);
  animation: bp-action-dot 1s ease-in-out infinite;
}
.bp-action-dots i:nth-child(2) { animation-delay: .14s; }
.bp-action-dots i:nth-child(3) { animation-delay: .28s; }

@keyframes bp-action-float {
  0%, 100% { transform: translateY(2px); }
  50% { transform: translateY(-5px); }
}

@keyframes bp-action-ripple {
  0% { opacity: .45; transform: scale(.88); }
  75%, 100% { opacity: 0; transform: scale(1.12); }
}

@keyframes bp-action-spin { to { transform: rotate(360deg); } }

@keyframes bp-action-lock-pulse {
  0%, 100% { transform: scale(.96); }
  50% { transform: scale(1.05); }
}

@keyframes bp-action-exit {
  0%, 100% { transform: translateX(-5px); opacity: .55; }
  50% { transform: translateX(7px); opacity: 1; }
}

@keyframes bp-action-stamp-in {
  0%, 20% { opacity: 0; transform: scale(.5) rotate(-12deg); }
  42%, 78% { opacity: 1; transform: scale(1) rotate(0); }
  100% { opacity: .75; transform: scale(.92); }
}

@keyframes bp-action-save-line {
  0% { stroke-dashoffset: 64; opacity: .25; }
  55%, 80% { stroke-dashoffset: 0; opacity: 1; }
  100% { stroke-dashoffset: -64; opacity: .25; }
}

@keyframes bp-action-dot {
  0%, 100% { opacity: .3; transform: translateY(0); }
  50% { opacity: 1; transform: translateY(-4px); }
}

@media (max-width: 480px) {
  .bp-action-loader { gap: 11px; padding: 20px; }
  .bp-action-visual { width: 126px; height: 126px; }
  .bp-action-copy { width: min(310px, calc(100vw - 36px)); }
}

@media (prefers-reduced-motion: reduce) {
  .bp-action-visual,
  .bp-action-visual::before,
  .bp-action-visual::after,
  .bp-action-visual svg *,
  .bp-action-dots i {
    animation: none !important;
  }
}

/* Purposeful motion shared by all Admin and PESO Staff pages. */
.bp-motion-enabled .bp-stagger-item {
  animation: bp-stagger-in .48s var(--bp-motion-standard) both;
  animation-delay: calc(var(--bp-order, 0) * 42ms + 60ms);
}

.bp-motion-enabled :where(.program-sort-options, .activity-filter-options):not([hidden]) {
  animation: bp-menu-in .18s var(--bp-motion-standard) both;
  transform-origin: top right;
}

.bp-motion-enabled :where(.modal.show, .modal-overlay.show, .modal-bg.show) > :where(.modal-backdrop, [class*="backdrop"]) {
  animation: bp-backdrop-in .2s ease-out both;
}

.bp-motion-enabled .bulk-selection-bar:not([hidden]) {
  animation: bp-selection-in .3s var(--bp-motion-standard) both;
}

.bp-motion-enabled :where(button, .btn, .btn-main, .btn-light, [class*="btn-"]):not(:disabled) > i {
  transition: transform .2s var(--bp-motion-standard);
}

.bp-motion-enabled :where(button, .btn, .btn-main, .btn-light, [class*="btn-"]):hover:not(:disabled) > i {
  transform: translateY(-1px) scale(1.06);
}

.bp-motion-enabled :where(button, .btn, .btn-main, .btn-light, [class*="btn-"]):active:not(:disabled) > i {
  transform: translateY(0) scale(.94);
}

.bp-motion-enabled :where(table tbody tr, .program-card-shell).is-selected {
  animation: bp-selected .3s var(--bp-motion-standard) both;
}

@keyframes bp-stagger-in {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes bp-menu-in {
  from { opacity: 0; transform: translateY(-5px) scale(.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes bp-backdrop-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes bp-selection-in {
  from { opacity: 0; transform: translateY(12px) scale(.99); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes bp-selected {
  50% { box-shadow: inset 4px 0 #1f7a54, 0 0 0 3px rgba(31,122,84,.08); }
}

@media (prefers-reduced-motion: reduce) {
  .bp-motion-enabled .bp-stagger-item,
  .bp-motion-enabled :where(.program-sort-options, .activity-filter-options):not([hidden]),
  .bp-motion-enabled :where(.modal.show, .modal-overlay.show, .modal-bg.show) > :where(.modal-backdrop, [class*="backdrop"]),
  .bp-motion-enabled .bulk-selection-bar:not([hidden]),
  .bp-motion-enabled :where(table tbody tr, .program-card-shell).is-selected {
    animation: none !important;
  }
}

/* BENEPESO service updates: a civic notice board, intentionally distinct from tourism UI. */
.bp-update-center {
  position: relative;
  flex: 0 0 auto;
}

.bp-update-button {
  position: relative;
  width: 44px;
  min-width: 44px;
  height: 44px;
  min-height: 44px;
  display: inline-grid;
  place-items: center;
  padding: 0;
  border: 1px solid #d5e5dc;
  border-radius: 13px;
  color: #176b49;
  background: #fff;
  box-shadow: 0 5px 14px rgba(16, 65, 45, .07);
  cursor: pointer;
}

.bp-update-button:hover,
.bp-update-button[aria-expanded="true"] {
  color: #fff;
  border-color: #176b49;
  background: #176b49;
  transform: translateY(-1px);
  box-shadow: 0 9px 20px rgba(23, 107, 73, .2);
}

.bp-update-button svg {
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.bp-update-badge {
  position: absolute;
  top: -6px;
  right: -6px;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  display: grid;
  place-items: center;
  border: 2px solid #fff;
  border-radius: 999px;
  color: #fff;
  background: #c43c32;
  font: 800 10px/1 Poppins, sans-serif;
}

.bp-update-panel {
  position: absolute;
  z-index: 1000;
  top: calc(100% + 12px);
  right: 0;
  width: min(390px, calc(100vw - 28px));
  overflow: hidden;
  border: 1px solid #d6e6dd;
  border-radius: 18px;
  color: #193b2e;
  background: #fff;
  box-shadow: 0 24px 65px rgba(9, 48, 32, .2);
}

.bp-update-panel:not([hidden]) {
  animation: bp-update-panel-in .2s cubic-bezier(.2, .8, .2, 1) both;
}

.bp-update-panel > header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 17px 18px;
  border-bottom: 1px solid #e0ebe5;
  background: linear-gradient(135deg, #f7fbf8, #edf7f1);
}

.bp-update-panel > header div { display: grid; gap: 2px; }
.bp-update-panel > header span {
  color: #648075;
  font: 700 9px/1.3 Poppins, sans-serif;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.bp-update-panel > header strong { font: 800 14px/1.35 Poppins, sans-serif; }

.bp-update-read {
  min-height: 32px;
  padding: 6px 9px;
  border: 1px solid #c9ddd2;
  border-radius: 8px;
  color: #176b49;
  background: #fff;
  font: 700 10px/1.2 Poppins, sans-serif;
  cursor: pointer;
}

.bp-update-list {
  max-height: min(430px, 58vh);
  overflow-y: auto;
  overscroll-behavior: contain;
}

.bp-update-item {
  position: relative;
  display: grid;
  grid-template-columns: 10px minmax(0, 1fr);
  gap: 10px;
  padding: 14px 18px;
  border-bottom: 1px solid #edf2ef;
  color: inherit;
  text-decoration: none;
  background: #fff;
}

.bp-update-item:hover,
.bp-update-item:focus-visible { background: #f6faf8; }
.bp-update-item.is-unread { background: #f0f8f4; }
.bp-update-dot {
  width: 8px;
  height: 8px;
  margin-top: 5px;
  border-radius: 50%;
  background: #4d8c71;
  box-shadow: 0 0 0 4px rgba(77, 140, 113, .1);
}
.bp-update-item.is-success .bp-update-dot { background: #168354; }
.bp-update-item.is-danger .bp-update-dot { background: #c84343; }
.bp-update-item.is-warning .bp-update-dot { background: #b67a11; }
.bp-update-item-copy { min-width: 0; display: grid; gap: 3px; }
.bp-update-item-copy small {
  color: #5f7c70;
  font: 700 9px/1.35 Poppins, sans-serif;
  letter-spacing: .04em;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}
.bp-update-item-copy strong { font: 800 12px/1.4 Poppins, sans-serif; }
.bp-update-item-copy > span { color: #5f756b; font: 500 11px/1.5 Poppins, sans-serif; }
.bp-update-item-copy time { color: #8b9c94; font: 600 9px/1.4 Poppins, sans-serif; }
.bp-update-empty { display: grid; gap: 5px; padding: 30px 22px; color: #6d8278; text-align: center; font: 500 11px/1.6 Poppins, sans-serif; }
.bp-update-empty strong { color: #274c3d; font-size: 13px; }
.bp-update-empty span { display: block; }
.bp-update-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 18px;
  color: #176b49;
  background: #f8fbf9;
  font: 800 11px/1.4 Poppins, sans-serif;
  text-decoration: none;
}
.bp-update-footer:hover { background: #edf7f1; }
.bp-update-badge[hidden] { display: none !important; }

@keyframes bp-update-panel-in {
  from { opacity: 0; transform: translateY(-7px) scale(.985); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* Home snapshot: one clear next action, not a decorative content carousel. */
.bp-service-snapshot-shell {
  margin-top: 24px;
  margin-bottom: 4px;
}

.bp-service-snapshot {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 17px;
  padding: 19px 20px;
  overflow: hidden;
  border: 1px solid #d4e5dc;
  border-left: 5px solid #176b49;
  border-radius: 15px;
  background: linear-gradient(105deg, #fff 0 72%, #eef8f2 100%);
  box-shadow: 0 9px 25px rgba(16, 65, 45, .07);
}

.bp-service-snapshot::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 92px;
  height: 4px;
  background: #d5a62e;
}

.bp-service-snapshot-mark {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  color: #176b49;
  background: #e5f3eb;
}
.bp-service-snapshot-mark svg { width: 27px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.bp-service-snapshot-copy { min-width: 0; }
.bp-service-snapshot-kicker { display: block; margin-bottom: 3px; color: #6a8076; font: 800 9px/1.3 Poppins, sans-serif; letter-spacing: .08em; text-transform: uppercase; }
.bp-service-snapshot-copy h2 { margin: 0; color: #133e2e; font: 800 clamp(14px, 2vw, 17px)/1.35 Poppins, sans-serif; }
.bp-service-snapshot-copy p { margin: 4px 0 0; color: #61786d; font: 500 11px/1.55 Poppins, sans-serif; }
.bp-service-snapshot-action { display: inline-flex; align-items: center; gap: 8px; min-height: 42px; padding: 10px 14px; border-radius: 9px; color: #fff; background: #176b49; font: 800 11px/1.3 Poppins, sans-serif; text-decoration: none; white-space: nowrap; }
.bp-service-snapshot-action:hover { background: #10573b; transform: translateY(-1px); }
.bp-service-snapshot-status { display: inline-flex; align-items: center; gap: 7px; max-width: 180px; padding: 7px 10px; border: 1px solid #cfe3d8; border-radius: 999px; color: #315f4c; background: #f8fcfa; font: 800 9px/1.3 Poppins, sans-serif; text-transform: uppercase; text-align: center; }
.bp-service-snapshot-status i { width: 7px; height: 7px; flex: 0 0 7px; border-radius: 50%; background: #1f8b5c; box-shadow: 0 0 0 4px rgba(31, 139, 92, .1); }
.bp-service-snapshot-shell[data-tone="danger"] .bp-service-snapshot-status i { background: #c84343; box-shadow: 0 0 0 4px rgba(200, 67, 67, .1); }

/* Application journey is process-oriented and adapts to every PESO program. */
.status-card-horizontal.bp-has-journey {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px 22px;
}
.status-card-horizontal.bp-has-journey .card-right { align-self: center; }
.bp-service-journey { grid-column: 1 / -1; padding-top: 15px; border-top: 1px solid #e5eee9; }
.bp-service-journey-heading { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 12px; }
.bp-service-journey-heading span { color: #617a6f; font: 800 9px/1.4 Poppins, sans-serif; letter-spacing: .08em; text-transform: uppercase; }
.bp-service-journey-heading strong { color: #176b49; font: 800 10px/1.4 Poppins, sans-serif; }
.bp-service-journey ol { display: grid; grid-template-columns: repeat(var(--bp-progress-steps, 5), minmax(76px, 1fr)); margin: 0; padding: 0; list-style: none; }
.bp-service-journey li { position: relative; min-width: 0; display: grid; justify-items: center; gap: 7px; padding: 0 5px; text-align: center; }
.bp-service-journey li::before { content: ""; position: absolute; z-index: 0; top: 14px; right: 50%; width: 100%; height: 2px; background: #dce7e1; }
.bp-service-journey li:first-child::before { display: none; }
.bp-journey-marker { position: relative; z-index: 1; width: 29px; height: 29px; display: grid; place-items: center; border: 2px solid #d5e2dc; border-radius: 9px; color: #788f84; background: #fff; font: 800 10px/1 Poppins, sans-serif; }
.bp-service-journey li.is-complete::before,
.bp-service-journey li.is-current::before { background: #62a986; }
.bp-service-journey li.is-complete .bp-journey-marker { border-color: #176b49; color: #fff; background: #176b49; }
.bp-service-journey li.is-current .bp-journey-marker { border-color: #d5a62e; color: #6e5100; background: #fff8df; box-shadow: 0 0 0 4px rgba(213, 166, 46, .12); }
.bp-service-journey li.not-approved .bp-journey-marker { border-color: #d9534f; color: #ad2828; background: #fff1f1; }
.bp-service-journey li > div { min-width: 0; display: grid; gap: 2px; }
.bp-service-journey li strong { color: #264b3c; font: 800 9px/1.35 Poppins, sans-serif; }
.bp-service-journey li small { color: #819088; font: 500 8px/1.35 Poppins, sans-serif; overflow-wrap: anywhere; }
.bp-service-journey li.is-upcoming { opacity: .68; }

/* Context-aware program suggestions. */
.search-container { position: relative; }
.bp-program-suggestions {
  position: absolute;
  z-index: 80;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  padding: 7px;
  border: 1px solid #d4e4db;
  border-radius: 13px;
  background: #fff;
  box-shadow: 0 18px 42px rgba(12, 52, 35, .16);
}
.bp-program-suggestions button { width: 100%; min-height: 49px; display: grid; grid-template-columns: 28px minmax(0, 1fr); grid-template-rows: auto auto; column-gap: 9px; padding: 8px 10px; border: 0; border-radius: 9px; color: #24483a; background: transparent; text-align: left; cursor: pointer; }
.bp-program-suggestions button:hover,
.bp-program-suggestions button:focus-visible { background: #eef7f2; }
.bp-program-suggestions button > span { grid-row: 1 / 3; align-self: center; width: 28px; height: 28px; display: grid; place-items: center; border-radius: 8px; background: #e2f2e9; font-size: 12px; }
.bp-program-suggestions strong { font: 800 12px/1.35 Poppins, sans-serif; }
.bp-program-suggestions small { color: #73887e; font: 500 9px/1.3 Poppins, sans-serif; }

.bp-back-to-top {
  position: fixed;
  z-index: 900;
  right: 72px;
  bottom: 22px;
  width: 48px;
  min-width: 48px;
  height: 48px;
  min-height: 48px;
  display: grid;
  place-items: center;
  gap: 0;
  padding: 5px;
  border: 1px solid rgba(255, 255, 255, .55);
  border-radius: 14px;
  color: #fff;
  background: #176b49;
  box-shadow: 0 10px 28px rgba(12, 56, 38, .24);
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  cursor: pointer;
  transition: opacity .2s ease, visibility .2s ease, transform .2s ease, background .2s ease;
}
.bp-back-to-top.show { opacity: 1; visibility: visible; transform: translateY(0); }
.bp-back-to-top:hover { background: #10573b; transform: translateY(-2px); }
.bp-back-to-top svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.bp-back-to-top span { font: 800 8px/1 Poppins, sans-serif; text-transform: uppercase; }

@media (max-width: 768px) {
  .bp-update-center { width: 100%; }
  .bp-update-button { width: 100%; grid-template-columns: 24px auto; justify-content: center; gap: 8px; }
  .bp-update-button::after { content: "Service updates"; font: 800 12px/1.3 Poppins, sans-serif; }
  .bp-update-panel { position: static; width: 100%; margin-top: 8px; box-shadow: 0 12px 30px rgba(9, 48, 32, .13); }
  .bp-service-snapshot { grid-template-columns: auto minmax(0, 1fr); }
  .bp-service-snapshot-status { grid-column: 1; grid-row: 2; justify-self: start; }
  .bp-service-snapshot-action { grid-column: 2; grid-row: 2; justify-content: center; justify-self: end; }
  .status-card-horizontal.bp-has-journey { grid-template-columns: 1fr; }
  .bp-service-journey { overflow-x: auto; padding-bottom: 7px; }
  .bp-service-journey ol { min-width: 580px; }
  .bp-back-to-top { right: 14px; bottom: 74px; }
}

@media (max-width: 480px) {
  .bp-service-snapshot-shell { width: calc(100% - 24px); margin-top: 15px; }
  .bp-service-snapshot { gap: 12px; padding: 16px 14px; border-radius: 12px; }
  .bp-service-snapshot-mark { width: 42px; height: 42px; }
  .bp-service-snapshot-status,
  .bp-service-snapshot-action { grid-column: 1 / -1; grid-row: auto; width: 100%; max-width: none; justify-content: center; justify-self: stretch; }
  .bp-update-panel > header { padding: 14px; }
  .bp-update-list { max-height: 48vh; }
}

/* Service updates: keep the complete panel visible inside the mobile menu. */
@media (max-width: 768px) {
  .topbar .menu-area { overflow-x: hidden; }
  .topbar .bp-update-center { min-width: 0; max-width: 100%; }
  .topbar .bp-update-panel {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    max-height: min(520px, calc(100dvh - 210px));
    box-sizing: border-box;
  }
  .topbar .bp-update-panel:not([hidden]) {
    display: flex;
    flex-direction: column;
  }
  .topbar .bp-update-panel > header {
    min-width: 0;
    flex: 0 0 auto;
    gap: 10px;
  }
  .topbar .bp-update-panel > header div {
    min-width: 0;
  }
  .topbar .bp-update-panel > header strong,
  .topbar .bp-update-panel > header span {
    max-width: 100%;
    overflow-wrap: anywhere;
  }
  .topbar .bp-update-read {
    flex: 0 0 auto;
    white-space: nowrap;
  }
  .topbar .bp-update-list {
    min-width: 0;
    min-height: 120px;
    max-height: none;
    flex: 1 1 auto;
  }
  .topbar .bp-update-item {
    min-width: 0;
    padding: 12px 14px;
  }
  .topbar .bp-update-footer {
    min-width: 0;
    flex: 0 0 auto;
    gap: 10px;
  }
}

@media (max-width: 480px) {
  .topbar .bp-update-panel {
    max-height: min(470px, calc(100dvh - 190px));
  }
  .topbar .bp-update-panel > header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    padding: 12px;
  }
  .topbar .bp-update-read {
    padding-inline: 7px;
    font-size: 9px;
  }
  .topbar .bp-update-footer {
    padding: 11px 13px;
    font-size: 10px;
  }
}

/* Home hero: a BENEPESO service record, kept distinct from travel-style visuals. */
.bp-record-graphic { align-items: stretch; justify-content: space-between; padding: 30px 27px; }
.bp-record-head { display: flex; align-items: center; gap: 13px; width: 100%; }
.bp-record-head .graphic-avatar { width: 58px; height: 58px; flex: 0 0 58px; margin: 0; border-radius: 15px; }
.bp-record-head .graphic-avatar svg { width: 30px; height: 30px; }
.bp-record-head > div:last-child { display: grid; gap: 3px; text-align: left; }
.bp-record-head small { color: #71857b; font: 800 9px/1.2 Poppins, sans-serif; letter-spacing: .12em; }
.bp-record-head strong { color: #123d2c; font: 800 16px/1.25 Poppins, sans-serif; }
.bp-record-steps { position: relative; display: grid; gap: 14px; width: 100%; padding: 4px 0; }
.bp-record-steps::before { content: ""; position: absolute; top: 18px; bottom: 18px; left: 15px; width: 2px; background: #d9e8e0; }
.bp-record-steps span { position: relative; z-index: 1; display: grid; grid-template-columns: 31px 1fr; align-items: center; gap: 11px; color: #6b8176; text-align: left; }
.bp-record-steps i { width: 31px; height: 31px; display: grid; place-items: center; border: 2px solid #cfdfd7; border-radius: 9px; background: #fff; font: normal 800 10px/1 Poppins, sans-serif; }
.bp-record-steps b { font: 700 11px/1.3 Poppins, sans-serif; }
.bp-record-steps .is-complete i { border-color: #1f7a54; color: #fff; background: #1f7a54; }
.bp-record-steps .is-current i { border-color: #d5a62e; color: #765600; background: #fff7d9; box-shadow: 0 0 0 4px rgba(213, 166, 46, .12); }
.bp-record-graphic .graphic-btn { display: flex; align-items: center; align-self: flex-start; gap: 7px; padding: 9px 13px; border-radius: 8px; box-shadow: none; }
.bp-record-graphic .graphic-btn span { font-size: 13px; }

/* Report workspace: compact controls, readable dropdowns, and actions beside the filters. */
#generateReportModal .report-controls {
  width: clamp(340px, 21vw, 380px) !important;
  flex-basis: clamp(340px, 21vw, 380px) !important;
  padding: 22px 20px 18px !important;
  background: linear-gradient(180deg, #ffffff 0%, #f8fcfa 100%);
}
#generateReportModal .report-controls-heading {
  display: grid;
  gap: 10px;
  margin: 0 0 16px !important;
  padding: 0 42px 15px 0;
  border-bottom: 1px solid #dce9e2;
  flex: 0 0 auto;
}
#generateReportModal .report-title-row { display: flex; align-items: center; gap: 11px; min-width: 0; }
#generateReportModal .report-title-icon {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  display: grid;
  place-items: center;
  border: 1px solid #cae2d5;
  border-radius: 11px;
  color: #176b49;
  background: #eaf6ef;
  font-size: 20px;
}
#generateReportModal .report-title-row .modal-title { margin: 0; font-size: 23px; line-height: 1.15; }
#generateReportModal .report-program-label { margin-top: 3px; color: #1f7a54; font: 800 9px/1.35 Poppins, sans-serif; letter-spacing: .055em; text-transform: uppercase; overflow-wrap: anywhere; }
#generateReportModal .report-controls-heading .modal-sub { margin: 0; color: #647a6f; font-size: 11px; line-height: 1.55; }
#generateReportModal .report-filter-list {
  flex: 0 1 auto !important;
  gap: 11px !important;
  max-height: calc(100dvh - 225px) !important;
  margin: 0 !important;
  padding: 0 5px 3px 0 !important;
  overflow-y: auto !important;
}
#generateReportModal .report-form .form-group { min-width: 0; }
#generateReportModal .report-form .form-group label { display: block; margin: 0 0 6px; color: #587164; font-size: 9px; letter-spacing: .08em; }
#generateReportModal .report-form select {
  min-height: 46px;
  padding: 9px 42px 9px 13px !important;
  border: 1px solid #cbded4 !important;
  border-radius: 10px !important;
  color: #173b2e;
  background-color: #fff !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23436f5b' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m7 10 5 5 5-5'/%3E%3C/svg%3E") !important;
  background-position: right 13px center !important;
  background-size: 16px 16px !important;
  background-repeat: no-repeat !important;
  font-size: 12px;
  font-weight: 650;
  white-space: nowrap;
  text-overflow: ellipsis;
}
#generateReportModal .report-form select:hover { border-color: #8dbba4 !important; background-color: #fbfefc !important; }
#generateReportModal .report-form select:focus { outline: none; border-color: #4b9872 !important; box-shadow: 0 0 0 3px rgba(31, 122, 84, .11) !important; }
#generateReportModal .report-column-picker { border-color: #cfdfd6; box-shadow: 0 4px 12px rgba(14, 61, 40, .035); }
#generateReportModal .report-column-picker summary { min-height: 44px; }
#generateReportModal .report-format-card {
  min-height: 58px;
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) 20px;
  align-items: center;
  gap: 10px;
  padding: 9px 11px;
  border: 1px solid #c8dfd3;
  border-radius: 11px;
  color: #173b2e;
  background: #f5fbf7;
}
#generateReportModal .report-format-icon { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 9px; color: #fff; background: #1f7a54; font-size: 18px; }
#generateReportModal .report-format-card > span:nth-child(2) { min-width: 0; display: grid; gap: 2px; }
#generateReportModal .report-format-card strong { font-size: 12px; line-height: 1.3; }
#generateReportModal .report-format-card small { color: #6b8176; font-size: 9px; line-height: 1.35; }
#generateReportModal .report-format-check { color: #1f8a5b; font-size: 18px; }
#generateReportModal .report-actions {
  margin: 13px 0 0 !important;
  padding-top: 13px !important;
  border-top-color: #d8e6df;
}
#generateReportModal .report-close-button { width: 44px; height: 44px; min-width: 44px; min-height: 44px; border-radius: 12px; }

#generateReportModal .report-view-toolbar {
  min-height: 46px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 6px 10px;
  border-bottom: 1px solid #d8e6df;
  background: #fff;
  flex: 0 0 auto;
}

#generateReportModal .report-view-label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #587165;
  font: 800 9px/1.2 Poppins, sans-serif;
  letter-spacing: .055em;
  text-transform: uppercase;
  white-space: nowrap;
}

#generateReportModal .report-view-label i { color: #1f7a54; font-size: 15px; }
#generateReportModal .report-zoom-controls { display: inline-flex; align-items: center; gap: 5px; }
#generateReportModal .report-zoom-controls button {
  min-width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 0 9px;
  border: 1px solid #c8dcd1;
  border-radius: 8px;
  color: #254f3d;
  background: #fff;
  font: 800 9px/1 Poppins, sans-serif;
  cursor: pointer;
}
#generateReportModal .report-zoom-controls button:hover { border-color: #74ad90; color: #176b49; background: #f1f9f5; }
#generateReportModal .report-zoom-controls button:focus-visible { outline: 3px solid rgba(31,122,84,.15); outline-offset: 1px; }
#generateReportModal .report-zoom-controls button:disabled { opacity: .38; cursor: not-allowed; }
#generateReportModal .report-zoom-controls .report-fit-button { min-width: 82px; }
#generateReportModal .report-zoom-controls .report-fit-button.is-active { border-color: #8dbfa4; color: #176b49; background: #eaf6ef; }
#generateReportModal .report-zoom-value { min-width: 48px; color: #183e2e; font: 800 10px/1 Poppins, sans-serif; text-align: center; }
#generateReportModal .scrollable-table-wrap {
  overflow: auto !important;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
  scrollbar-width: thin;
  scrollbar-color: #8caf9e #edf4f0;
}
#generateReportModal .scrollable-table-wrap::-webkit-scrollbar { width: 9px; height: 9px; }
#generateReportModal .scrollable-table-wrap::-webkit-scrollbar-track { background: #edf4f0; }
#generateReportModal .scrollable-table-wrap::-webkit-scrollbar-thumb { border: 2px solid #edf4f0; border-radius: 999px; background: #8caf9e; }
#generateReportModal #preview_main_table {
  width: 100% !important;
  min-width: 100% !important;
  table-layout: fixed !important;
  transform-origin: top left;
}

.bp-update-item.is-opportunity .bp-update-dot {
  background: #d5a62e;
  box-shadow: 0 0 0 5px rgba(213, 166, 46, .13);
}

@media (max-width: 900px) {
  #generateReportModal .report-controls {
    width: min(330px, 88vw) !important;
    flex-basis: auto !important;
  }
  #generateReportModal .report-filter-list { flex: 1 1 auto !important; max-height: none !important; }
}

@media (max-width: 480px) {
  #generateReportModal .report-controls { width: min(310px, 90vw) !important; padding: 16px 13px 12px !important; }
  #generateReportModal .report-controls-heading { margin-bottom: 11px !important; padding-bottom: 11px; }
  #generateReportModal .report-title-row .modal-title { font-size: 19px; }
  #generateReportModal .report-title-icon { width: 36px; height: 36px; flex-basis: 36px; font-size: 17px; }
  #generateReportModal .report-actions { grid-template-columns: 1fr; }
  #generateReportModal .report-view-toolbar { align-items: stretch; flex-direction: column; gap: 5px; padding: 7px 8px; }
  #generateReportModal .report-view-label { display: none; }
  #generateReportModal .report-zoom-controls { width: 100%; justify-content: center; }
  #generateReportModal .report-zoom-controls button { min-width: 38px; }
  #generateReportModal .report-zoom-controls .report-fit-button { flex: 1; max-width: 112px; }
}

@media (prefers-reduced-motion: reduce) {
  .bp-update-panel:not([hidden]) { animation: none; }
  .bp-back-to-top { transition: none; }
}
