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

:root { color-scheme: light; --blue: #073ba8; --navy: #142b54; --muted: #718096; --border: #e4e9f1; }
* { box-sizing: border-box; }
body { margin: 0; background: #f5f7fb; color: var(--navy); font-family: Manrope, 'Segoe UI', sans-serif; font-size: 14px; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }
button, summary, a { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 3px solid #d69f00; outline-offset: 4px; }
.header { background: var(--blue); color: white; border-bottom: 4px solid #f5cf39; }
.header-inner, .nav-inner, main { max-width: 1280px; margin: auto; }
.header-inner { min-height: 84px; display: flex; align-items: center; justify-content: space-between; padding: 13px 32px; gap: 20px; }
.brand { display: flex; align-items: center; gap: 17px; }
.brand img { width: 54px; height: 54px; object-fit: contain; }
.brand strong { display: block; font-size: 17px; letter-spacing: 1.2px; font-weight: 800; }
.brand small { display: block; margin-top: 6px; font-size: 12px; color: #d3e1ff; letter-spacing: .3px; }
.account-menu { position: relative; flex-shrink: 0; }
.account-menu summary { display: flex; align-items: center; gap: 10px; padding: 7px 10px; background: #ffffff12; border: 1px solid #ffffff30; border-radius: 7px; cursor: pointer; list-style: none; }
.account-menu summary::-webkit-details-marker { display: none; }
.account-menu summary:hover, .account-menu[open] summary { background: #ffffff20; }
.account-avatar { display: grid; place-items: center; width: 32px; height: 32px; background: #ffffff20; border-radius: 50%; font-size: 10px; font-weight: 800; }
.account-name strong { display: block; font-size: 11px; }
.account-name small { display: block; margin-top: 3px; font-size: 9px; color: #d3e1ff; }
.account-chevron { margin-left: 8px; }
.account-dropdown { position: absolute; right: 0; top: calc(100% + 10px); z-index: 10; width: 245px; padding: 8px; color: var(--navy); background: white; border: 1px solid var(--border); border-radius: 9px; box-shadow: 0 10px 35px #152d5426; }
.account-description { display: block; padding: 0 10px 12px; font-size: 11px; color: var(--muted); line-height: 1.6; }
.account-dropdown button { display: block; width: 100%; text-align: left; border: 0; border-top: 1px solid #edf0f5; padding: 11px 10px; background: white; color: #8b98aa; font-size: 11px; }
.navigation { background: white; border-bottom: 1px solid var(--border); }
.nav-inner { padding: 0 32px; display: flex; align-items: center; gap: 30px; }
.nav-inner a { padding: 19px 0 17px; border-bottom: 3px solid transparent; font-weight: 750; color: var(--muted); font-size: 13px; }
.nav-inner a[aria-current="page"] { color: var(--blue); border-bottom-color: var(--blue); }
.nav-inner a:hover { color: var(--blue); }
.nav-inner > span { font-size: 10px; color: #8a96a8; letter-spacing: 1.7px; }
main { padding: 28px 32px 0; }
.breadcrumb { font-size: 11px; color: #8591a5; margin-bottom: 31px; }
.breadcrumb span { margin: 0 10px; color: #bbc3d0; }
.page-heading { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 25px; }
.eyebrow { font-size: 10px; letter-spacing: 2px; color: var(--blue); font-weight: 800; }
h1 { font-size: clamp(26px, 3vw, 34px); letter-spacing: -1.2px; margin: 8px 0; line-height: 1.25; font-weight: 800; }
.page-heading p { margin: 10px 0 0; color: var(--muted); font-size: 13px; line-height: 1.7; }
.button { border: 0; border-radius: 7px; padding: 13px 19px; font-size: 12px; font-weight: 750; white-space: nowrap; }
.primary { background: var(--blue); color: white; box-shadow: 0 3px 5px #073ba815; }
.primary span { font-size: 19px; margin-right: 6px; vertical-align: -1px; }
button:disabled, input:disabled, select:disabled { cursor: not-allowed; }
.prototype-note { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; font-size: 11px; color: #6e6240; background: #fff9e8; border: 1px solid #efe6c9; border-radius: 6px; padding: 11px 14px; margin-bottom: 22px; }
.note-dot { width: 6px; height: 6px; border-radius: 50%; background: #cc9b22; }
.records-panel { background: white; border: 1px solid var(--border); border-radius: 12px; box-shadow: 0 4px 18px #243b5304; }
.panel-heading { padding: 24px 25px 22px; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
h2 { font-size: 16px; margin: 0; letter-spacing: -.3px; font-weight: 800; }
.count { display: inline-block; vertical-align: 2px; font-size: 10px; background: #edf3ff; color: #315dba; padding: 4px 9px; border-radius: 20px; margin-left: 8px; font-weight: 700; letter-spacing: 0; }
.panel-heading p { margin: 7px 0 0; color: var(--muted); font-size: 11px; }
.directory-label { font-size: 9px; color: #98a3b3; letter-spacing: 1.4px; }
.toolbar { border-top: 1px solid #f0f2f6; padding: 17px 25px; display: flex; align-items: center; gap: 12px; }
.search { display: flex; align-items: center; gap: 10px; border: 1px solid #dfe5ee; border-radius: 6px; padding: 10px 12px; flex: 1; max-width: 430px; }
.search svg { width: 17px; height: 17px; color: #8b98aa; flex-shrink: 0; }
.search input { border: 0; outline: none; min-width: 0; width: 100%; background: white; font-size: 11px; color: var(--muted); }
.search input::placeholder { color: #929daf; opacity: 1; }
.filter { display: flex; align-items: center; gap: 8px; border: 1px solid #dfe5ee; border-radius: 6px; padding: 9px 10px; font-size: 10px; }
.filter > span { color: #8b96a7; }
.filter select { border: 0; background: white; color: #334766; font-size: 11px; opacity: 1; }
.table-scroll { overflow-x: auto; padding-bottom: 4px; }
table { width: 100%; border-collapse: collapse; min-width: 850px; text-align: left; }
thead { background: #f7f9fc; }
th { color: #7b899e; font-size: 9px; font-weight: 750; letter-spacing: .8px; padding: 14px 17px; border-block: 1px solid var(--border); white-space: nowrap; }
th:first-child, td:first-child { padding-left: 25px; }
td { padding: 17px; border-bottom: 1px solid #edf0f5; font-size: 11px; color: #596b84; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover { background: #fbfcff; }
.record-id { font-size: 10px; color: #77869c; font-variant-numeric: tabular-nums; letter-spacing: .3px; }
.person { display: flex; gap: 11px; align-items: center; }
.person strong { font-size: 12px; color: #263c5c; font-weight: 750; display: block; }
.person small { display: block; font-size: 9px; color: #99a4b4; margin-top: 4px; }
.avatar { width: 36px; height: 36px; background: #edf3ff; color: #4d73b9; display: grid; place-items: center; border-radius: 50%; font-size: 10px; font-weight: 750; flex-shrink: 0; }
.lavender { background: #f1edfc; color: #8970bd; }
.mint { background: #eaf5ef; color: #5a9377; }
.peach { background: #fff0e9; color: #ba8664; }
.status { padding: 5px 10px; border-radius: 5px; display: inline-flex; align-items: center; gap: 6px; font-size: 10px; font-weight: 700; }
.status::before { content: ''; width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.active { background: #edf8f2; color: #33956a; }
.inactive { background: #fff5e8; color: #b9842d; }
.action-heading, .action-cell { text-align: right; padding-right: 25px; }
.row-menu { position: relative; display: inline-block; text-align: left; }
.row-menu summary { list-style: none; width: 33px; height: 31px; display: grid; place-items: center; border: 1px solid #e1e7f0; border-radius: 6px; cursor: pointer; color: #71819a; background: white; }
.row-menu summary::-webkit-details-marker { display: none; }
.row-menu summary span { display: block; width: 4px; height: 4px; border-radius: 50%; background: currentColor; box-shadow: -7px 0 0 currentColor, 7px 0 0 currentColor; font-size: 0; line-height: 0; }
.row-menu summary:hover, .row-menu[open] summary { background: #edf3ff; border-color: #b9cdef; color: var(--blue); }
.dropdown { position: absolute; top: calc(100% + 6px); right: 0; z-index: 5; width: 228px; padding: 7px; background: white; border: 1px solid #e1e7f0; border-radius: 9px; box-shadow: 0 10px 35px #152d5426; }
.upward .dropdown { top: auto; bottom: calc(100% + 6px); }
.menu-title { display: block; font-size: 8px; font-weight: 800; letter-spacing: 1px; color: #99a4b4; padding: 9px 10px; }
.dropdown a { display: flex; align-items: center; gap: 11px; padding: 11px 10px; font-size: 11px; color: #4c607f; border-radius: 5px; }
.dropdown a:hover, .dropdown a:focus-visible { background: #edf3ff; color: var(--blue); }
.table-footer { border-top: 1px solid var(--border); padding: 16px 25px; display: flex; align-items: center; justify-content: space-between; color: #8e9aad; font-size: 10px; }
.table-footer strong { font-weight: 650; color: #60718a; }
.pagination { display: flex; align-items: center; gap: 6px; }
.pagination button, .pagination > span { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 5px; }
.pagination button { background: white; border: 1px solid #e8ecf2; color: #bcc5d2; font-size: 18px; }
.pagination > span { color: var(--blue); background: #edf3ff; font-weight: 800; }
.desk-note { color: #8996a9; font-size: 10px; display: flex; align-items: center; gap: 7px; margin: 18px 2px 40px; line-height: 1.7; }
.desk-note > span { font-size: 14px; }
.service-preview { display: none; padding: 25px; border: 1px solid #bfd0ef; background: #edf3ff; border-radius: 10px; margin-bottom: 28px; scroll-margin-top: 25px; }
.service-preview:target { display: block; }
.service-preview p { color: var(--muted); line-height: 1.7; font-size: 12px; }
.service-preview a { font-size: 12px; font-weight: 750; color: var(--blue); }
footer { border-top: 1px solid var(--border); padding: 20px 0 25px; color: #9aa5b5; font-size: 10px; }
footer > span:not(.footer-right) { margin: 0 8px; }
.footer-right { float: right; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.dashboard-date { font-size: 10px; color: var(--muted); text-align: right; }
.dashboard-date strong { display: block; color: #405574; font-size: 12px; margin-top: 5px; }
.stats-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin-bottom: 30px; }
.stat-card { background: white; border: 1px solid var(--border); border-radius: 10px; padding: 20px; }
.stat-label { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 11px; color: #667891; font-weight: 650; }
.stat-icon { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 7px; background: #edf3ff; color: var(--blue); font-size: 17px; flex-shrink: 0; }
.stat-value { display: block; font-size: 32px; letter-spacing: -1px; margin: 12px 0 5px; }
.stat-caption { color: #8c99ab; font-size: 10px; line-height: 1.6; }
.pending-card { border-top: 3px solid #e6bc59; padding-top: 18px; }
.dashboard-shortcuts { margin-bottom: 30px; }
.dashboard-shortcuts > h2 { margin-bottom: 15px; }
.shortcut-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.shortcut { display: flex; gap: 17px; padding: 23px; background: white; border: 1px solid var(--border); border-radius: 10px; }
.shortcut-icon { flex-shrink: 0; width: 43px; height: 43px; display: grid; place-items: center; background: #edf3ff; color: var(--blue); border-radius: 10px; font-size: 26px; }
.shortcut h3 { margin: 1px 0 7px; font-size: 14px; }
.shortcut p { color: var(--muted); font-size: 11px; line-height: 1.8; margin: 0 0 16px; }
.shortcut .button { padding: 9px 12px; font-size: 10px; box-shadow: none; }
.text-link { color: var(--blue); font-size: 11px; font-weight: 750; }
.shortcut-link:hover { border-color: #9db9ed; background: #fbfcff; }
.shortcut-link .text-link { display: inline-block; padding-top: 8px; }
.review { color: #4876c2; background: #edf3ff; }
.recent-table { min-width: 760px; }
.advisories { margin: 26px 0 20px; border: 1px solid var(--border); border-radius: 12px; overflow: hidden; background: white; }
.advisories-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 19px 24px; background: var(--blue); color: white; }
.advisories-heading { display: flex; align-items: center; gap: 13px; }
.advisories-heading h2 { font-size: 15px; }
.advisories-heading p { margin: 5px 0 0; color: #d3e1ff; font-size: 10px; }
.advisory-header-icon, .advisory-icon { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 8px; flex-shrink: 0; }
.advisory-header-icon { background: #ffffff20; }
.advisories svg { width: 21px; height: 21px; }
.advisory-preview-label { font-size: 8px; letter-spacing: 1.2px; color: #d3e1ff; white-space: nowrap; }
.advisory-list { padding: 0 24px; }
.advisory-item { display: flex; gap: 14px; padding: 19px 0; }
.advisory-item + .advisory-item { border-top: 1px solid #edf0f5; }
.advisory-icon { background: #edf3ff; color: var(--blue); }
.advisory-item h3 { margin: 0 0 5px; font-size: 12px; }
.advisory-item p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.8; }
.advisory-tag { display: inline-block; padding: 4px 7px; margin-top: 8px; background: #edf3ff; color: var(--blue); border-radius: 4px; font-size: 8px; letter-spacing: .6px; font-weight: 750; }
.advisory-footer { padding: 13px 24px; background: #f8fafd; border-top: 1px solid var(--border); color: #8996a9; font-size: 10px; line-height: 1.7; }
@media (max-width: 1000px) {
  .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .header-inner { padding: 16px 20px; min-height: 88px; }
  .brand { gap: 11px; }
  .brand img { width: 49px; height: 49px; }
  .brand strong { font-size: 11px; letter-spacing: .6px; }
  .brand small { font-size: 10px; }
  .account-name, .account-chevron { display: none; }
  .account-menu summary { padding: 5px; }
  .nav-inner { padding: 0 20px; }
  .nav-inner > span { display: none; }
  main { padding: 22px 16px 0; }
  .breadcrumb { margin-bottom: 23px; }
  .page-heading { align-items: flex-start; flex-direction: column; gap: 18px; }
  .button { width: 100%; }
  .panel-heading { padding: 20px 16px; }
  .directory-label { display: none; }
  .toolbar { flex-wrap: wrap; padding: 14px 16px; gap: 8px; }
  .search { flex-basis: 100%; max-width: none; }
  .filter { flex: 1; justify-content: space-between; }
  .filter > span { display: none; }
  .filter select { width: 100%; }
  .table-footer { padding: 14px 16px; }
  .footer-right { display: block; float: none; margin-top: 8px; }
  .dashboard-date { text-align: left; }
  .shortcut-grid { grid-template-columns: 1fr; }
  .advisories-header { padding: 18px 16px; }
  .advisory-preview-label { display: none; }
  .advisories-heading h2 { font-size: 13px; }
  .advisory-list { padding: 0 16px; }
  .advisory-footer { padding: 13px 16px; }
  .nav-inner { gap: 20px; overflow-x: auto; }
  .nav-inner a { white-space: nowrap; }
  .stat-card { padding: 15px; }
  .stat-label { font-size: 10px; }
  .stat-icon { width: 25px; height: 25px; }
  .stat-value { font-size: 28px; }
  .stats-grid { gap: 10px; }
  .shortcut { padding: 18px; }
}

.button { display: inline-block; text-align: center; cursor: pointer; }
.staff-login { font-size: 12px; font-weight: 700; white-space: nowrap; }
.account-action { display: block; padding: 12px; font-size: 12px; }
.account-action:hover { background: #edf3ff; }
.dropdown form { margin: 0; }
.dropdown button { display: flex; align-items: center; gap: 11px; width: 100%; padding: 11px 10px; border: 0; background: white; text-align: left; font-size: 11px; color: #4c607f; border-radius: 5px; cursor: pointer; }
.dropdown button:hover, .dropdown button:focus-visible { background: #edf3ff; color: var(--blue); }
.table-scroll { min-height: 330px; }
.empty-records { text-align: center; padding: 50px 20px; }
.pagination a { padding: 5px 10px; background: #edf3ff; color: var(--blue); border-radius: 5px; }

/* Inline icons remain available without an external icon font. */
.ui-icon { width: 18px; height: 18px; display: inline-block; flex-shrink: 0; vertical-align: middle; }
.stat-icon .ui-icon { width: 18px; height: 18px; }
.shortcut-icon .ui-icon { width: 25px; height: 25px; }
.text-link .ui-icon, .desk-note .ui-icon { width: 14px; height: 14px; }
.button .ui-icon { margin-right: 5px; }

.admin-login-link { display: inline-flex; align-items: center; gap: 8px; padding: 10px 14px; border: 1px solid #ffffff45; border-radius: 7px; background: #ffffff12; color: white; font-size: 12px; font-weight: 700; white-space: nowrap; }
.admin-login-link:hover { background: #ffffff25; }
@media (max-width: 480px) { .header-inner { flex-wrap: wrap; gap: 12px; } .admin-login-link { margin-left: auto; padding: 8px 10px; font-size: 11px; } }

.footer-download { float: right; display: inline-flex; align-items: center; gap: 7px; color: var(--blue); font-weight: 700; font-size: 10px; }
.footer-download:hover { text-decoration: underline; }
.footer-download .ui-icon { width: 14px; height: 14px; }
.apk-label { padding: 2px 5px; background: #e9effb; border-radius: 3px; font-size: 8px; }
@media (max-width: 760px) { .footer-download { float: none; display: flex; width: fit-content; margin-top: 12px; } }

.table-scroll-hint { display: none; }
/* Keep the records table on phones with horizontal scrolling. */
@media (max-width: 640px) {
  .records-panel .table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; min-height: 330px; padding-bottom: 8px; }
  .responsive-records { min-width: 730px; width: 100%; }
  .responsive-records th { font-size: 9px; padding: 12px; }
  .responsive-records td { font-size: 11px; padding: 13px 12px; }
  .responsive-records th:first-child, .responsive-records td:first-child { padding-left: 16px; }
  .responsive-records .action-cell, .responsive-records .action-heading { padding-right: 16px; }
  .responsive-records .person { gap: 8px; }
  .responsive-records .person strong { font-size: 11px; }
  .responsive-records .avatar { width: 30px; height: 30px; }
  .responsive-records .row-menu summary { width: 40px; height: 40px; }
  .responsive-records .dropdown a, .responsive-records .dropdown button { min-height: 44px; }
  .toolbar .button { width: auto; flex: 1; }
  .table-footer { gap: 10px; flex-wrap: wrap; }
  .table-scroll-hint { display: block; margin: 0; padding: 0 16px 12px; font-size: 10px; color: var(--muted); }
}

/* Labeled record filters with consistent control sizing. */
.record-filters { display: grid; grid-template-columns: minmax(180px, 1fr) minmax(150px, 190px) minmax(140px, 165px) auto; align-items: end; gap: 14px; padding: 20px 25px; background: #fbfcfe; border-top: 1px solid var(--border); }
.record-filters .search, .record-filters .filter { display: flex; flex-direction: column; align-items: stretch; gap: 8px; max-width: none; padding: 0; border: 0; border-radius: 0; min-width: 0; }
.record-filters .filter-label { display: block; font-size: 10px; font-weight: 750; color: #536680; }
.search-control { display: flex; align-items: center; gap: 10px; height: 43px; padding: 0 12px; background: white; border: 1px solid #dce4ef; border-radius: 7px; transition: border-color .15s; }
.record-filters .search-control svg { width: 17px; height: 17px; color: #8798af; flex-shrink: 0; }
.record-filters .search input { height: 100%; padding: 0; font-size: 12px; background: transparent; }
.record-filters select { width: 100%; height: 43px; border: 1px solid #dce4ef; border-radius: 7px; background: white; padding: 0 11px; font-size: 12px; color: #405574; }
.search-control:focus-within { border-color: #7b9edc; box-shadow: 0 0 0 3px #073ba80b; }
.filter-actions { display: flex; align-items: center; gap: 8px; }
.record-filters .button { height: 43px; padding: 0 21px; box-shadow: none; font-size: 12px; }
.filter-reset { display: inline-flex; align-items: center; justify-content: center; height: 43px; padding: 0 13px; font-size: 11px; font-weight: 700; color: #6b7c94; border: 1px solid #dce4ef; border-radius: 7px; background: white; }
.filter-reset:hover { color: var(--blue); background: #edf3ff; }
@media (max-width: 1000px) { .record-filters { grid-template-columns: 1fr 1fr; } .record-filters .search { grid-column: 1 / -1; } .record-filters .filter-actions { grid-column: 1 / -1; justify-content: flex-end; } }
@media (max-width: 640px) { .record-filters { padding: 16px; gap: 13px 10px; } .record-filters .filter { flex: initial; } .record-filters .filter-actions { justify-content: stretch; } .record-filters .button { flex: 1; } .filter-reset { min-width: 80px; } }

/* Search stays paired with its button; selects apply immediately. */
.record-filters { grid-template-columns: minmax(250px, 1fr) minmax(150px, 190px) minmax(140px, 165px) auto; }
.record-search-group { display: flex; align-items: flex-end; gap: 8px; min-width: 0; }
.record-filters .record-search-group .search { flex: 1; min-width: 0; }
.record-search-group .button { flex-shrink: 0; }
.clear-filters { display: inline-flex; align-items: center; height: 43px; font-size: 11px; color: #647794; font-weight: 700; white-space: nowrap; }
.clear-filters:hover { color: var(--blue); text-decoration: underline; }
@media (max-width: 1000px) { .record-filters { grid-template-columns: 1fr 1fr; } .record-search-group { grid-column: 1 / -1; } .record-filters .record-search-group .search { grid-column: auto; } .clear-filters { height: auto; grid-column: 1 / -1; justify-self: end; } }
@media (max-width: 640px) { .record-filters .record-search-group .button { flex: 0 0 auto; width: auto; padding: 0 15px; } }

.refresh-records { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 40px; padding: 9px 12px; background: white; border: 1px solid #dce4ef; border-radius: 7px; color: #536b8d; font-size: 11px; font-weight: 700; cursor: pointer; flex-shrink: 0; }
.refresh-records:hover { background: #edf3ff; border-color: #b9cdef; color: var(--blue); }
.refresh-records:disabled { opacity: .6; cursor: default; }
.refresh-records .ui-icon { width: 16px; height: 16px; }
.refresh-records[aria-busy="true"] .ui-icon { animation: refresh-spin .8s linear infinite; }
@keyframes refresh-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .refresh-records[aria-busy="true"] .ui-icon { animation: none; } }

.records-refresh-status { margin: 0; padding: 0 25px 12px; font-size: 11px; color: #33956a; }
.records-refresh-status:empty { display: none; }
.records-refresh-status.refresh-error { color: #b34b40; }

.public-services-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.public-service-card { display: flex; flex-direction: column; align-items: flex-start; padding: 26px; border: 1px solid var(--border); background: white; border-radius: 12px; }
.public-service-card h3 { margin: 20px 0 10px; font-size: 16px; }
.public-service-card p { margin: 0 0 24px; color: var(--muted); line-height: 1.8; font-size: 12px; }
.public-service-card .button { margin-top: auto; width: 100%; }
@media (max-width: 1000px) { .public-services-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .public-services-grid { grid-template-columns: 1fr; } }

/* Registration service menu. */
.row-menu summary { width: 38px; height: 36px; border-radius: 8px; border-color: #dce5f4; color: #1646b5; transition: background .15s, border-color .15s; }
.row-menu[open] summary { background: #edf3ff; border-color: #adc5fb; color: #073ba8; }
.row-menu .dropdown { width: 270px; padding: 13px 12px; border: 1px solid #dce5f4; border-radius: 12px; box-shadow: 0 18px 40px #243c6a20; top: calc(100% + 8px); }
.row-menu.upward .dropdown { top: auto; bottom: calc(100% + 8px); }
.row-menu .menu-title { padding: 8px 9px 12px; color: #91a0b9; font-size: 9px; font-weight: 800; letter-spacing: 1.2px; }
.row-menu .dropdown a, .row-menu .dropdown button { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 48px; padding: 12px 10px; background: transparent; border: 0; border-radius: 7px; color: #4b638c; font: inherit; font-size: 12px; text-align: left; cursor: pointer; }
.row-menu .dropdown a:hover, .row-menu .dropdown button:hover { background: #f0f5ff; color: var(--blue); }
.row-menu .dropdown .ui-icon { width: 21px; height: 21px; flex-shrink: 0; }
@media (max-width: 640px) { .row-menu .dropdown { width: 255px; } .row-menu summary { width: 40px; height: 40px; } }

.applicant-service-panel { padding: 28px; display: flex; align-items: center; justify-content: space-between; gap: 24px; border: 1px solid var(--border); border-radius: 12px; background: white; margin-bottom: 26px; }
.applicant-service-panel h2 { margin-top: 9px; font-size: 21px; }
.applicant-service-panel p { margin: 9px 0 0; font-size: 12px; color: var(--muted); line-height: 1.7; }
.public-service-menu { position: relative; width: 320px; max-width: 100%; flex-shrink: 0; }
.public-service-menu summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 15px 18px; background: var(--blue); color: white; border-radius: 8px; font-size: 13px; font-weight: 750; cursor: pointer; list-style: none; }
.public-service-menu summary::-webkit-details-marker { display: none; }
.public-service-menu[open] .service-chevron { transform: rotate(180deg); }
.public-service-options { position: absolute; right: 0; top: calc(100% + 8px); width: 100%; z-index: 15; padding: 10px; background: white; border: 1px solid #dce5f4; border-radius: 12px; box-shadow: 0 18px 40px #243c6a20; }
.public-service-options a { display: flex; align-items: center; gap: 12px; padding: 13px 10px; min-height: 48px; color: #4b638c; font-size: 12px; border-radius: 7px; }
.public-service-options a:hover { background: #edf3ff; color: var(--blue); }
.public-service-options .service-arrow { margin-left: auto; color: #8a9dbb; }
@media (max-width: 700px) { .applicant-service-panel { align-items: stretch; flex-direction: column; padding: 22px; } .public-service-menu { width: 100%; } .public-service-options { position: static; margin-top: 8px; box-shadow: none; } }

.home-lookup { border: 1px solid var(--border); border-radius: 12px; background: white; margin-bottom: 20px; }
.home-lookup-heading { padding: 24px; border-bottom: 1px solid var(--border); background: #f8fafd; border-radius: 12px 12px 0 0; }
.home-lookup-heading h2 { margin: 9px 0; font-size: 20px; }
.home-lookup-heading p { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.8; }
.home-lookup-body { padding: 24px; }
.home-reference-form label { display: block; margin-bottom: 10px; font-size: 12px; font-weight: 750; }
.home-reference-controls { display: flex; gap: 12px; }
.home-reference-controls input { flex: 1; min-width: 0; height: 46px; border: 1px solid #dce4ef; border-radius: 7px; padding: 0 14px; font-size: 12px; color: var(--navy); }
.home-reference-form small { display: block; color: var(--muted); font-size: 11px; margin-top: 10px; line-height: 1.7; }
.home-record-found { display: flex; gap: 12px; align-items: center; color: #29835b; }
.home-record-found small { display: block; margin-top: 6px; color: var(--muted); font-size: 11px; line-height: 1.7; }
.matched-reference { font-family: monospace; color: #52698d; margin: 18px 0; overflow-wrap: anywhere; }
.different-reference { display: inline-block; font-size: 11px; color: #647794; margin-top: 16px; text-decoration: underline; }
.public-service-options form { margin: 0; }
.public-service-options button { display: flex; align-items: center; gap: 12px; padding: 13px 10px; min-height: 48px; width: 100%; background: white; border: 0; border-radius: 7px; font: inherit; font-size: 12px; color: #4b638c; text-align: left; cursor: pointer; }
.public-service-options button:hover { background: #edf3ff; color: var(--blue); }
.new-applicant-prompt { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 22px 24px; border: 1px solid var(--border); border-radius: 12px; background: white; margin-bottom: 26px; }
.new-applicant-prompt h2 { font-size: 15px; }
.new-applicant-prompt p { font-size: 11px; color: var(--muted); margin: 7px 0 0; line-height: 1.8; }
.lookup-error { border: 1px solid #efc7bf; border-radius: 7px; background: #fff2ef; color: #a13e30; padding: 12px; font-size: 12px; line-height: 1.7; margin: 0 0 20px; }
@media (max-width: 700px) { .home-reference-controls, .new-applicant-prompt { flex-direction: column; align-items: stretch; } .home-reference-controls input { flex: auto; } .home-lookup-heading, .home-lookup-body { padding: 20px; } }

.record-modal-open { overflow: hidden; }
.record-found-modal { width: min(510px, calc(100vw - 32px)); max-height: calc(100dvh - 40px); margin: auto; padding: 36px 28px 24px; border: 1px solid #dce5f4; border-radius: 16px; color: var(--navy); background: white; box-shadow: 0 24px 80px #10295240; overflow-y: auto; }
.record-found-modal::backdrop { background: #12274888; backdrop-filter: blur(3px); }
.record-modal-close { position: absolute; right: 12px; top: 9px; width: 36px; height: 36px; border: 0; border-radius: 7px; background: transparent; color: #7a8aa3; font-size: 25px; cursor: pointer; }
.record-modal-close:hover { background: #edf3ff; color: var(--blue); }
.record-found-modal .home-record-found { align-items: flex-start; padding-right: 12px; }
.record-found-modal .home-record-found > .ui-icon { margin-top: 2px; }
.record-found-modal .matched-reference { padding: 13px; background: #f5f8fd; border: 1px solid var(--border); border-radius: 7px; font-size: 12px; line-height: 1.8; }
.record-found-modal .public-service-menu { width: 100%; }
.record-found-modal .public-service-options { position: static; margin-top: 8px; box-shadow: none; }
.record-modal-footer { margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--border); }
.record-modal-cancel { display: block; width: 100%; padding: 11px; border: 1px solid #dce4ef; border-radius: 7px; color: #647794; background: white; font-size: 11px; font-weight: 700; cursor: pointer; }
.record-modal-cancel:hover { background: #f5f8fd; }
@media (max-width: 480px) { .record-found-modal { padding: 38px 20px 20px; } }

.application-panel-intro { display: flex; align-items: center; gap: 18px; min-width: 0; }
.application-fill-icon { display: grid; place-items: center; width: 72px; height: 80px; flex: 0 0 72px; border-radius: 16px; background: #edf3ff; color: #073ba8; }
.application-fill-icon svg { width: 51px; height: 51px; }
@media (max-width: 575.98px) { .application-panel-intro { gap: 12px; align-items: flex-start; } .application-fill-icon { width: 50px; height: 58px; flex-basis: 50px; border-radius: 12px; } .application-fill-icon svg { width: 38px; height: 38px; } .application-panel-intro h2 { font-size: 18px; } }

.application-panel-with-art { display: grid; grid-template-columns: minmax(0, 1fr) 270px; gap: 0 36px; padding: 28px 32px; }
.application-panel-with-art .application-panel-intro { grid-column: 1; grid-row: 1; align-self: end; }
.application-panel-with-art .public-service-menu { grid-column: 1; grid-row: 2; margin-top: 22px; align-self: start; }
.application-illustration { grid-column: 2; grid-row: 1 / 3; display: flex; align-items: center; justify-content: center; min-height: 206px; padding: 12px; background: #f7f9ff; border: 1px solid #edf1fa; border-radius: 16px; }
.application-illustration svg { display: block; width: 100%; max-width: 280px; height: auto; }
@media (max-width: 700px) { .application-panel-with-art { grid-template-columns: 1fr; padding: 22px; gap: 20px; } .application-panel-with-art .application-panel-intro { grid-row: 1; } .application-panel-with-art .public-service-menu { grid-row: 2; margin-top: 0; width: 100%; } .application-illustration { grid-column: 1; grid-row: 3; min-height: 160px; } .application-illustration svg { max-width: 220px; } }
