/* Shared visual system: clear, calm and consistent across both account roles. */
:root {
  color-scheme: light;
  --ink: #17251e;
  --muted: #66756d;
  --subtle: #87948c;
  --line: #e3eae5;
  --canvas: #f3f6f3;
  --surface: #ffffff;
  --green: #24724f;
  --green-hover: #1c6042;
  --green-deep: #173b2c;
  --green-soft: #e9f3ec;
  --amber: #9a641e;
  --amber-soft: #fff4df;
  --red: #a5463c;
  --red-soft: #fff0ed;
  --blue: #426b98;
  --blue-soft: #edf4fb;
  --shadow-card: 0 8px 24px rgba(25, 56, 39, .055);
  --shadow-float: 0 18px 56px rgba(18, 45, 30, .2);
  --radius-card: 16px;
  --radius-control: 10px;
  --focus-ring: 0 0 0 3px rgba(48, 130, 87, .24);
  font-family: system-ui, 'Segoe UI', Arial, sans-serif;
  color: var(--ink);
  background: var(--canvas);
}

html { scroll-behavior: smooth; }
body { min-width: 320px; color: var(--ink); background: var(--canvas); font-size: 14px; line-height: 1.5; }
button, input, select, textarea { font: inherit; }
button { -webkit-tap-highlight-color: transparent; }
a { color: var(--green); }
:focus-visible { outline: 3px solid #68a982; outline-offset: 3px; }
::selection { color: #103522; background: #cce6d3; }
button:disabled, input:disabled, select:disabled, textarea:disabled { cursor: not-allowed; opacity: .62; }

/* Shared application frame */
.sidebar,
body.admin-ui .sidebar,
body.resident-ui .sidebar {
  width: 258px; padding: 24px 16px 14px; color: #eaf2ec;
  background: var(--green-deep); border: 0; box-shadow: 5px 0 24px rgba(18, 45, 30, .08);
}
.brand, body.admin-ui .brand { min-height: 48px; padding: 0 8px; gap: 11px; color: #fff; }
.brand-mark, body.admin-ui .brand-mark { width: 44px; height: 44px; border: 2px solid rgba(255,255,255,.72); border-radius: 50%; background: #fff; box-shadow: 0 4px 12px rgba(0,0,0,.15); }
.brand strong, body.admin-ui .brand strong { font-size: 13px; letter-spacing: -.15px; }
.brand small, body.admin-ui .brand small { margin-top: 3px; color: #b7cbbd; font-size: 9px; letter-spacing: 1.1px; }
.site-switch, body.admin-ui .site-switch { min-height: 58px; height: auto; margin: 27px 2px 24px; padding: 0 12px; border: 1px solid #365647; border-radius: 12px; background: #1d4634; }
.site-switch strong { color: #f7fbf8; font-size: 12px; }
.site-switch small { margin-top: 3px; color: #b6cbbd; font-size: 10px; }
.site-dot { background: #72c58b; box-shadow: 0 0 0 4px rgba(114,197,139,.16); }
.chevron { color: #c4d6ca; }
.nav { gap: 5px; }
.nav-label { padding: 0 12px 8px; color: #9db5a6; font-size: 9px; letter-spacing: 1.25px; }
.section-label { padding-top: 20px; }
.nav-item, body.admin-ui .nav-item {
  min-height: 44px; height: auto; gap: 12px; padding: 0 12px; border-radius: 10px;
  color: #d5e3d9; font-size: 12px; font-weight: 500; transition: background .16s ease, color .16s ease, transform .16s ease;
}
.nav-item>span, body.admin-ui .nav-item>span { width: 18px; color: #adc6b5; font-size: 16px; }
.nav-item:hover, body.admin-ui .nav-item:hover { color: #fff; background: #254b38; }
.nav-item.active, body.admin-ui .nav-item.active { color: #123522; background: #d9efdc; font-weight: 700; }
.nav-item.active>span, body.admin-ui .nav-item.active>span { color: #1e7047; }
.nav-item[aria-current="location"], body.admin-ui .nav-item[aria-current="location"] { box-shadow: inset 3px 0 #69b77f; }
.nav-item.active[aria-current="location"], body.admin-ui .nav-item.active[aria-current="location"] { box-shadow: inset 3px 0 #24724f; }
.nav-count, body.admin-ui .nav-count { min-width: 22px; height: 20px; border-radius: 999px; color: #dbe8de; background: #315540; font-size: 10px; }
.alert-count, body.admin-ui .alert-count { color: #ffe1da; background: #773e37; }
.privacy-note, body.admin-ui .privacy-note { min-height: 56px; height: auto; margin: 0 3px 12px; padding: 9px; border: 1px solid #31513e; border-radius: 12px; background: #1c422f; }
.privacy-icon { border-radius: 9px; color: #b9e5c4; background: #2a5a3d; }
.privacy-note strong { color: #f4faf5; font-size: 10px; }
.privacy-note small { color: #b5c9ba; font-size: 9px; }
.user-menu, body.admin-ui .user-menu { min-height: 58px; padding: 12px 3px 2px; border-color: #365344; }
.avatar { width: 36px; height: 36px; color: #1d603c; background: #d7ebdc; font-size: 12px; }
.user-details strong { max-width: 142px; color: #f6faf7; font-size: 11px; }
.user-details small { color: #bdcfc2; font-size: 10px; }
.user-menu .icon-button, body.admin-ui .user-menu .icon-button { color: #d5e3d9; }
.sidebar-collapse, body.admin-ui .sidebar-collapse { top: 26px; right: 8px; border: 1px solid #40624e; border-radius: 8px; color: #e8f3ea; background: #214532; }
.sidebar-collapse:hover, body.admin-ui .sidebar-collapse:hover { color: #fff; background: #2e6040; }
.main-area, body.admin-ui .main-area { margin-left: 258px; }
.topbar, body.admin-ui .topbar { position: sticky; top: 0; z-index: 3; height: 68px; padding: 0 clamp(20px, 3.2vw, 48px); color: #eaf2ec; background: var(--green-deep); border: 0; border-bottom: 1px solid #365344; backdrop-filter: blur(12px); }
.breadcrumbs { color: #c4d6ca; font-size: 12px; }
.breadcrumbs span { color: #8eaa98; }
.breadcrumbs strong { color: #fff; font-weight: 700; }
.top-actions { gap: 16px; }
.live-indicator, body.admin-ui .live-indicator { min-height: 32px; padding: 6px 11px; border: 1px solid #d9eadf; border-radius: 999px; color: #286242; background: #f2f9f4; font-size: 11px; font-weight: 600; }
.live-indicator i { width: 7px; height: 7px; background: #48a66b; box-shadow: 0 0 0 3px #dcefe1; }
.notification-button, body.admin-ui .notification-button, .topbar .icon-button { color: #eaf2ec; }
.notification-button { min-width: 32px; min-height: 32px; border-radius: 9px; }
.notification-button:hover, .topbar .icon-button:hover { background: #28513b; }
.top-date { color: #c4d6ca; font-size: 11px; }
.small-avatar { width: 34px; height: 34px; }
.content, body.admin-ui .content { max-width: 1580px; min-height: calc(100vh - 68px); padding: clamp(24px,3.1vw,44px) clamp(18px,3.2vw,48px) 26px; margin: 0 auto; color: var(--ink); background: var(--canvas); }
.welcome-row, body.admin-ui .welcome-row { align-items: center; margin-bottom: 25px; color: var(--ink); }
.eyebrow, body.admin-ui .eyebrow { color: #738479; font-size: 10px; letter-spacing: 1.2px; }
.eyebrow-line { width: 20px; border-color: #7caa88; }
.welcome-row h1, body.admin-ui .welcome-row h1 { margin: 7px 0 5px; color: #1b3024; font-size: clamp(25px,2.1vw,32px); letter-spacing: -1px; }
.welcome-row h1 span { color: var(--green); }
.subtitle, body.admin-ui .subtitle { color: #66766c; font-size: 14px; }
.welcome-actions { gap: 9px; }
.button, body.admin-ui .button { min-height: 40px; height: auto; padding: 8px 14px; border: 1px solid #dce6de; border-radius: var(--radius-control); color: #415348; background: #fff; box-shadow: 0 2px 6px rgba(27,64,43,.035); font-size: 12px; font-weight: 600; transition: background .15s ease, border-color .15s ease, transform .15s ease; }
.button:hover { border-color: #bdd3c3; background: #f7fbf8; }
.button:active { transform: translateY(1px); }
.button-primary, body.admin-ui .button-primary { color: #fff; border-color: var(--green); background: var(--green); box-shadow: 0 4px 10px rgba(36,114,79,.15); }
.button-primary:hover, body.admin-ui .button-primary:hover { color: #fff; border-color: var(--green-hover); background: var(--green-hover); }
.button-secondary, body.admin-ui .button-secondary { color: #315a40; border-color: #d3e3d7; background: #fff; }
.button:focus-visible, .icon-button:focus-visible, .nav-item:focus-visible, .text-link:focus-visible { outline-color: #76b68b; outline-offset: 2px; }

/* Summary cards, activity, camera, alerts and other shared surfaces */
.metrics-grid { gap: 16px; }
.metric-card, .panel, .workspace-panel, body.admin-ui .panel, body.admin-ui .admin-recognition {
  border: 1px solid #e5ebe6; border-radius: var(--radius-card); background: var(--surface); box-shadow: var(--shadow-card);
}
.metric-card, body.admin-ui .metric-card { min-height: 132px; height: auto; padding: 18px; }
.metric-top { gap: 12px; }
.metric-label, body.admin-ui .metric-label { color: #637268; font-size: 12px; font-weight: 600; }
.metric-icon { width: 34px; height: 34px; border-radius: 11px; font-size: 16px; }
.metric-value, body.admin-ui .metric-value { margin-top: 12px; color: #1d3325; font-size: 30px; letter-spacing: -.7px; }
.metric-foot { margin-top: 4px; }
.metric-neutral, .trend-up, .metric-pending-foot { font-size: 11px; }
.metric-neutral { color: #78867d; }
.trend-up { color: #287348; }
.metric-pending-foot { color: #94611f; }
.sparkline { right: 15px; bottom: 15px; width: 82px; opacity: .25; }
.section-grid, body.admin-ui .section-grid { gap: 18px; margin-top: 18px; grid-template-columns: minmax(0,1.65fr) minmax(280px,.85fr); }
.bottom-grid, body.admin-ui .bottom-grid { gap: 18px; margin-top: 18px; }
.activity-panel, .alerts-panel { min-height: 290px; }
.panel-heading, body.admin-ui .panel-heading { align-items: center; padding: 20px 21px 16px; }
.panel-heading h2, body.admin-ui .panel-heading h2 { margin: 0 0 5px; color: #21372a; font-size: 15px; letter-spacing: -.25px; }
.panel-heading p, body.admin-ui .panel-heading p { color: #748278; font-size: 11px; }
.text-link, .alerts-link { color: #236d49; font-size: 12px; font-weight: 700; }
.table-wrap { overflow-x: auto; }
table { min-width: 620px; }
thead { background: #f7f9f7; }
th, body.admin-ui th { height: 40px; padding: 0 13px; color: #617166; font-size: 11px; letter-spacing: .55px; }
th:first-child, td:first-child { padding-left: 20px; }
td, body.admin-ui td { height: 58px; padding: 8px 13px; color: #36483d; border-color: #edf1ed; font-size: 13px; }
.person-mini { width: 32px; height: 32px; font-size: 10px; }
.person-name { color: #263d2e; font-size: 12px; }
.person-sub { font-size: 10px; }
.type-pill, .status-pill { padding: 5px 9px; border-radius: 999px; font-size: 10px; font-weight: 700; }
.status-pending { color: var(--amber); background: var(--amber-soft); }
.status-verified { color: #286b46; background: var(--green-soft); }
.status-false { color: #596b60; background: #eff3f0; }
.table-footer { padding: 14px 20px; color: #718076; font-size: 11px; }
.loading-cell { height: 110px; color: #718076; font-size: 12px; }
.alerts-panel, body.admin-ui .alerts-panel { color: var(--ink); border-color: #f0d9d4; border-top: 3px solid #c26354; background: #fff; }
.admin-ui .alerts-panel .panel-heading { border-color: #f2e7e4; }
.admin-ui .alerts-panel .panel-heading h2 { color: #532d29; }
.admin-ui .alerts-panel .panel-heading p { color: #826b66; }
.warning-icon { color: #a65345; background: var(--red-soft); }
.live-pill { color: #9b4c3e; background: #fff0ed; font-size: 9px; }
.live-pill i { background: #cd6a58; }
.alert-list { padding: 0 20px; }
.alert-card, .admin-ui .alerts-panel .alert-card { grid-template-columns: 36px minmax(0,1fr) auto; gap: 11px; padding: 14px 0; border-color: #f1e8e5; }
.alert-camera, .admin-ui .alerts-panel .alert-camera { width: 34px; height: 34px; border-radius: 10px; color: #ad5c4c; background: var(--red-soft); }
.alert-title, .admin-ui .alerts-panel .alert-title { color: #50352f; font-size: 12px; }
.alert-detail, .admin-ui .alerts-panel .alert-detail { color: #7d6a63; font-size: 10px; }
.alert-time, .admin-ui .alerts-panel .alert-time { color: #8a756d; font-size: 10px; }
.alert-action, .admin-ui .alerts-panel .alert-action { color: #914639; font-size: 11px; font-weight: 700; }
.alerts-link, .admin-ui .alerts-panel .alerts-link { margin: 8px 20px 16px; padding-top: 13px; border-color: #f1e8e5; color: #914639; }
.alerts-actions { display: flex; flex-wrap: wrap; gap: 9px; padding: 12px 20px 18px; border-top: 1px solid #f1e8e5; }
.alert-card { display: grid; grid-template-columns: minmax(160px,240px) minmax(0,1fr) auto; align-items: center; gap: 16px; padding: 16px 0; border-bottom: 1px solid #f1e8e5; }
.alert-card-photo { min-width: 0; }
.alert-evidence { display: grid; gap: 7px; }
.alert-photo-link { display: block; overflow: hidden; border: 1px solid #e3d5d1; border-radius: 9px; background: #f4f0ee; }
.alert-snapshot { display: block; width: 100%; height: 132px; object-fit: cover; cursor: zoom-in; }
.alert-photo-download { justify-self: start; color: #8f463a; font-size: 11px; font-weight: 700; }
.alert-no-photo { display: grid; min-height: 132px; place-items: center; border: 1px dashed #e6d8d3; border-radius: 9px; color: #88736d; font-size: 11px; }
.alert-card-content { min-width: 0; }
.alert-card .alert-title { font-size: 14px; }
.alert-card .alert-detail { margin-top: 5px; overflow-wrap: anywhere; }
.alerts-actions .button { min-height: 38px; }
.empty-alert { min-height: 145px; height: auto; gap: 7px; color: #64786b; }
.empty-check { width: 33px; height: 33px; color: #267347; background: var(--green-soft); }
.empty-alert strong { color: #314c3b; font-size: 13px; }
.empty-alert>span:last-child { font-size: 11px; }
.admin-ui .alerts-panel .empty-alert { color: #64786b; }
.admin-ui .alerts-panel .empty-alert strong { color: #314c3b; }
.admin-ui .alerts-panel .empty-check { color: #267347; background: var(--green-soft); }

/* Camera preview and its explicit offline state */
.admin-ui .admin-recognition { margin-top: 18px; padding: 20px; }
.recognition-heading { gap: 16px; }
.recognition-kicker { color: #467759; font-size: 10px; letter-spacing: 1.1px; }
.recognition-heading h2 { color: #20382a; font-size: 19px; }
.recognition-heading p { color: #6d7b72; font-size: 12px; }
.recognition-live { padding: 7px 10px; border-radius: 999px; color: #286b46; background: #edf7ef; font-size: 10px; }
.recognition-live i { width: 7px; height: 7px; background: #4ca46a; box-shadow: 0 0 0 4px #dff1e4; }
.recognition-layout { grid-template-columns: minmax(0,1.45fr) minmax(280px,.85fr); gap: 18px; }
.preview-frame { min-height: 290px; border-radius: 13px; background: #152d22; }
.preview-fallback { gap: 10px; background: radial-gradient(circle at 50% 35%, #2d6044, #183425 72%); }
.preview-fallback strong { font-size: 15px; }
.preview-fallback>span:last-child { max-width: 330px; color: #d0e0d3; font-size: 12px; line-height: 1.5; }
.preview-camera-icon { font-size: 34px; }
.preview-label { left: 13px; bottom: 13px; padding: 6px 9px; border-radius: 7px; font-size: 10px; }
.recognition-stats { border-color: #e5ebe6; border-radius: 12px; }
.recognition-stats>div { min-height: 67px; border-color: #e5ebe6; }
.recognition-stats span { color: #6d7b72; font-size: 10px; }
.recognition-stats strong { color: #1e3828; font-size: 20px; }
.recognition-results-heading { margin: 16px 0 8px; color: #344b3b; font-size: 12px; }
.recognition-results-heading span { color: #75847a; }
.recognition-results { min-height: 84px; }
.recognition-result { gap: 10px; padding: 9px 0; border-color: #e9eeea; }
.recognition-result strong { color: #2d4335; font-size: 11px; }
.recognition-result small { color: #748278; font-size: 10px; }
.recognition-result time { color: #64756a; font-size: 10px; }
.recognition-empty { padding: 18px 3px; color: #748278; font-size: 12px; }
.recognition-disclaimer { padding-top: 12px; color: #697970; font-size: 10px; line-height: 1.55; }
.recognition-camera-controls label { color: #52665a; font-size: 11px; }
.recognition-camera-controls select { min-height: 38px; height: auto; border-color: #dce6de; border-radius: 9px; color: #294334; background: #fff; font-size: 12px; }
.recognition-camera-controls small { color: #6f7e74; font-size: 10px; }

/* Camera, registration and resident workspace lists */
/* Rebuild decorative icon glyphs with CSS code points so legacy mojibake text
   cannot leak into the interface. Labels and accessible names stay unchanged. */
.nav-item > span, .metric-icon, .privacy-icon, .notification-button,
.sidebar-collapse, #menu-button, #logout-button, .preview-camera-icon,
.text-link > span, .alerts-link > span, #refresh-button, #simulate-button { font-size: 0 !important; }
.nav-item > span::before, .metric-icon::before, .privacy-icon::before,
.notification-button::before, .sidebar-collapse::before, #menu-button::before,
#logout-button::before, .preview-camera-icon::before, .text-link > span::before,
.alerts-link > span::before, #refresh-button::before, #simulate-button::before {
  font-size: 1rem; line-height: 1; display: inline-block; font-family: "Segoe UI Symbol", "Segoe UI", sans-serif;
}
.nav-item[href="#dashboard"] > span::before { content: "\25A6"; }
.nav-item[href="#events"] > span::before { content: "\25F7"; }
.nav-item[href="#alerts"] > span::before { content: "\26A0"; }
.nav-item[href="#registrations"] > span::before { content: "\2659"; }
.nav-item[href="#visitors"] > span::before { content: "\265F"; }
.nav-item[data-open-visitor] > span::before { content: "+"; }
.nav-item[href="#cameras"] > span::before { content: "\25CE"; }
.nav-item[href="#audit"] > span::before { content: "\2261"; }
.nav-item[href="#users"] > span::before { content: "\2687"; }
.nav-item[href="#profile"] > span::before { content: "\2699"; }
.privacy-icon::before { content: "\1F512"; }
.notification-button::before { content: "\1F514"; }
.sidebar-collapse::before { content: "\2039"; }
#menu-button::before { content: "\2630"; }
#logout-button::before { content: "\2197"; }
.preview-camera-icon::before { content: "\25CE"; }
.text-link > span::before, .alerts-link > span::before { content: "\2192"; }
#refresh-button::before { content: "\21BB"; }
#simulate-button::before { content: "+"; }
#refresh-button > span, #simulate-button > span { font-size: 11px; }
.residents-icon::before { content: "\2659"; }
.visitors-icon::before { content: "\265F"; }
.entries-icon::before { content: "\21B5"; }
.pending-icon::before { content: "\25F7"; }
.camera-capture-modal[hidden] { display: none !important; }
.camera-capture-modal { position: fixed; inset: 0; z-index: 70; display: grid; place-items: center; padding: 18px; background: #10261dbb; }
.camera-capture-dialog { position: relative; width: min(100%, 520px); padding: 24px; border: 1px solid #e4ebe5; border-radius: 16px; background: #fff; box-shadow: 0 24px 80px #10261d55; }
.camera-capture-dialog h2 { margin: 0 38px 6px 0; color: #183c2b; font: 700 20px 'Segoe UI',sans-serif; }
.camera-capture-dialog p { margin: 0 0 14px; color: #718078; font-size: 13px; line-height: 1.5; }
.camera-capture-close { position: absolute; top: 13px; right: 14px; width: 34px; height: 34px; border: 0; border-radius: 50%; background: #eef4ef; color: #254b37; font-size: 23px; cursor: pointer; }
.camera-capture-dialog video { display: block; width: 100%; max-height: 58vh; border-radius: 12px; background: #14271e; object-fit: contain; }
.camera-capture-message { min-height: 24px; padding: 9px 0 3px; color: #56695e; font-size: 12px; }
.camera-capture-actions { display: flex; justify-content: flex-end; gap: 9px; margin-top: 8px; }
.selfie-capture-row { display: flex; align-items: end; gap: 9px; flex-wrap: wrap; }
.selfie-capture-row > label { flex: 1; min-width: 180px; }
.selfie-capture-preview { display: block; width: 120px; height: 120px; margin-top: 9px; border: 1px solid #dce6de; border-radius: 12px; object-fit: cover; }
.auth-camera-button { min-height: 35px; border: 1px solid #cfe0d3; border-radius: 8px; padding: 7px 12px; background: #f5faf6; color: #226742; font-size: 12px; font-weight: 700; cursor: pointer; }
.auth-camera-button:hover { background: #eaf4ec; }
.auth-camera-button[data-capture-selfie]::before,
.face-consent-settings [data-capture-selfie]::before { content: "\1F4F7  "; font-family: "Segoe UI Symbol", "Segoe UI Emoji", sans-serif; }
.camera-capture-close { font-size: 0; }
.camera-capture-close::before { content: "\00D7"; font: 23px/1 "Segoe UI Symbol", "Segoe UI", sans-serif; }
.camera-panel, .registrations-panel { min-height: 210px; }
.camera-list, .registration-list { padding: 0 20px 16px; }
.camera-row, .registration-row { min-height: 58px; gap: 12px; border-color: #edf1ed; }
.camera-status-icon, .register-initial { width: 34px; height: 34px; border-radius: 10px; font-size: 12px; }
.row-main strong { color: #294033; font-size: 12px; }
.row-main small { color: #6e7e73; font-size: 10px; }
.online-status, .offline-status { font-size: 10px; font-weight: 700; }
.registration-action { min-height: 32px; padding: 6px 10px; border-color: #cfe0d3; border-radius: 8px; color: #226742; background: #fff; font-size: 11px; font-weight: 700; }
.registration-action:hover { border-color: #a9cbb3; background: #eff7f0; }
.no-items { padding: 20px 8px; color: #718076; border-color: #edf1ed; font-size: 12px; }
.workspace-panel { margin-top: 20px; padding: 0 22px 24px; }
.workspace-heading { padding: 22px 0 18px; }
.workspace-kicker { color: #36744e; font-size: 10px; letter-spacing: 1.1px; }
.workspace-heading h2 { margin: 4px 0 5px; color: #1e3527; font-size: 20px; }
.workspace-heading p { color: #6c7b71; font-size: 12px; }
.workspace-grid { gap: 26px; border-color: #e8eee9; }
.workspace-form, .profile-form { gap: 14px; padding: 20px 0 0; }
.workspace-form h3, .list-heading h3 { color: #294033; font-size: 14px; }
.workspace-form label, .profile-form label { gap: 6px; color: #43574a; font-size: 12px; font-weight: 600; }
.workspace-form input, .workspace-form textarea, .profile-form input,
.camera-registration-form input, .camera-registration-form select,
.recognition-camera-controls select {
  min-height: 42px; height: auto; padding: 9px 12px; border: 1px solid #d9e4dc; border-radius: var(--radius-control);
  color: #233b2d; background: #fff; font-size: 13px; outline: none; transition: border-color .15s ease, box-shadow .15s ease;
}
.workspace-form textarea { min-height: 92px; }
.workspace-form input:focus, .workspace-form textarea:focus, .profile-form input:focus, .camera-registration-form input:focus, .camera-registration-form select:focus { border-color: #5b9d71; box-shadow: var(--focus-ring); }
.workspace-form input::placeholder, .workspace-form textarea::placeholder { color: #8a978e; }
.workspace-form .button, .profile-form .button { min-width: 150px; justify-self: start; }
.workspace-error { color: #a54035; font-size: 12px; }
.workspace-error:not(:empty), .form-error:not(:empty) { padding: 9px 11px; border: 1px solid #f0d4cf; border-radius: 9px; background: var(--red-soft); line-height: 1.45; }
.success-message { padding: 9px 11px; border: 1px solid #d7e9dc; border-radius: 9px; color: #21663e; background: #eff8f1; font-size: 12px; line-height: 1.45; }
.workspace-list { padding-top: 20px; }
.list-heading { padding-bottom: 12px; }
.list-heading .text-link, .workspace-heading .text-link { color: #286d47; font-size: 12px; font-weight: 700; }
.visitor-row { min-height: 67px; gap: 10px 14px; padding: 12px 0; border-color: #e9eeea; }
.visitor-row-main { gap: 4px; }
.visitor-row-main strong { color: #2a4033; font-size: 12px; }
.visitor-row-main small { color: #718076; font-size: 10px; }
.visitor-status { padding: 5px 9px; color: #8a5c1c; background: var(--amber-soft); font-size: 10px; font-weight: 700; }
.visitor-status.status-approved { color: #286b46; background: var(--green-soft); }
.visitor-status.status-rejected, .visitor-status.status-cancelled { color: #98483f; background: var(--red-soft); }
.visitor-status.status-completed { color: #56695d; background: #eef3ef; }
.visitor-review { gap: 8px; }
.reject-action { color: #98483f; border-color: #f0d6d1; }
.load-more { margin: 15px auto 0; }
.profile-form { max-width: 760px; border-color: #e8eee9; }
.profile-form input[readonly] { color: #627368; background: #f1f5f2; }
.face-consent-settings { margin-top: 24px; padding: 18px; border: 1px solid #e2ebe4; border-radius: 13px; background: #f8fbf8; }
.face-consent-settings h3 { color: #294033; font-size: 14px; }
.face-consent-settings p { margin-bottom: 0; color: #6f7e74; font-size: 12px; }
.audit-table-wrap { border-color: #e8eee9; }
.audit-table { min-width: 640px; }
.audit-table td { height: 54px; }
.audit-action { padding: 4px 8px; border-radius: 999px; color: #385c45; background: #edf5ef; font-size: 10px; font-weight: 700; }
.camera-registration { padding: 0 0 15px; border-color: #e8eee9; }
.camera-registration summary { color: #286d47; font-size: 12px; font-weight: 700; }
.camera-registration-form { padding-top: 16px; }
.camera-secret-note { color: #6c7b71; font-size: 11px; }
.page-footer { padding: 24px 0 5px; color: #718076; font-size: 10px; }
.toast { right: 24px; bottom: 24px; padding: 13px 17px; border: 1px solid #375a42; border-radius: 12px; background: #193b2b; font-size: 13px; box-shadow: var(--shadow-float); }
.modal-backdrop { background: rgba(16, 37, 25, .52); backdrop-filter: blur(4px); }
.modal { width: min(100%, 480px); padding: 32px; border: 1px solid #e4ebe5; border-radius: 20px; box-shadow: var(--shadow-float); }
.modal-close { width: 36px; height: 36px; border-radius: 9px; color: #5e7064; font-size: 22px; }
.modal-close:hover { background: #f1f5f2; }
.modal-kicker { color: #34734d; font-size: 10px; letter-spacing: 1.25px; }
.modal h2 { color: #1e3527; font-size: 23px; }
.modal>p { color: #6c7b71; font-size: 13px; }
.modal form { gap: 15px; }
.modal label { gap: 7px; color: #43574a; font-size: 12px; }
.modal input, .modal select { min-height: 42px; height: auto; border-color: #d9e4dc; border-radius: 10px; padding: 9px 12px; color: #233b2d; font-size: 13px; }
.form-error { color: #a54035; font-size: 12px; }
.form-submit { min-height: 44px; }

/* Login and registration */
.auth-screen { grid-template-columns: minmax(0,1.02fr) minmax(0,.98fr); overflow-y: auto; background: #f4f7f4; }
.auth-art { min-height: 100vh; padding: 20px; background: linear-gradient(145deg,#153b2b,#246c45 58%,#7fbd83); }
.auth-art-card { position: relative; min-height: 580px; height: 100%; overflow: hidden; border: 1px solid rgba(255,255,255,.25); border-radius: 28px; background: linear-gradient(155deg,#d6efc7 0%,#78c876 28%,#19854a 61%,#143a2c 100%); box-shadow: inset 0 1px rgba(255,255,255,.3); }
.auth-art-card:after { bottom: -33%; left: 8%; width: 84%; border: 1px solid #e9f3eb; box-shadow: 0 0 0 20px rgba(255,255,255,.09); }
.auth-art-card img { top: 69%; left: 50%; width: min(55%,340px); max-height: 46%; object-fit: contain; border-radius: 50%; box-shadow: 0 14px 38px rgba(18,47,30,.12); }
.auth-side { min-height: 100vh; padding: 48px clamp(24px,6vw,88px); background: radial-gradient(ellipse at 90% 5%, #e8f3e9 0, transparent 42%), #f5f7f4; }
.auth-content { width: min(100%,440px); padding: 18px 0; }
.auth-kicker { display: block; color: #34734d; font-size: 10px; letter-spacing: 1.7px; }
.auth-content h1 { margin: 13px 0 34px; color: #172b1f; line-height: 1.12; }
.auth-content h1 strong { font-size: clamp(34px,3.4vw,44px); font-weight: 800; letter-spacing: -1.2px; }
.auth-content h1 span { margin-top: 4px; color: #456251; font-size: clamp(27px,2.7vw,35px); font-weight: 500; letter-spacing: -.7px; }
.auth-content form { width: 100%; margin: 0; gap: 15px; }
.auth-content form>label.credential-label { display: grid; gap: 7px; color: #40574a; font-size: 12px; }
.field-label { display: none; }
.auth-content form.register-mode .field-label { display: block; }
.auth-content form.register-mode>label.credential-label { display: grid; color: #40574a; font-size: 12px; }
.auth-content input:not([type=file]):not([type=checkbox]), .auth-content select { min-height: 46px; height: auto; border: 1px solid #dce6de; border-radius: 11px; padding: 10px 14px; color: #20372a; background: #fff; box-shadow: 0 2px 5px rgba(30,66,43,.025); font-size: 14px; }
.auth-content input:focus, .auth-content select:focus { border-color: #5b9d71; outline: none; box-shadow: var(--focus-ring); }
.auth-content input::placeholder { color: #89958d; }
.auth-content .input-icon-control input, .auth-content .password-control input { padding-right: 48px !important; }
.input-icon { right: 15px; color: #56705e; }
.password-toggle { top: 6px; right: 7px; width: 34px; height: 34px; border-radius: 8px; color: #56705e; }
.password-toggle:hover { background: #edf4ef; }
.auth-content .file-field input { min-height: 42px; border: 1px solid #dce6de; border-radius: 10px; padding: 8px; background: #fff; }
.auth-content .consent-field { color: #516259; font-size: 11px; line-height: 1.55; }
.auth-content .consent-field input { accent-color: var(--green); }
.auth-submit { justify-self: stretch; width: 100%; min-height: 46px; height: auto; margin: 7px 0 0; border-radius: 11px; background: var(--green); box-shadow: 0 5px 13px rgba(36,114,79,.18); font-size: 14px; }
.auth-submit:hover { background: var(--green-hover); }
.auth-submit span { padding-left: 7px; }
.auth-tabs { position: static; display: flex; justify-content: center; gap: 9px; margin: 22px 0 0; opacity: 1; }
.auth-tab { min-height: 38px; padding: 7px 16px; border: 1px solid transparent; border-radius: 9px; color: #506358; font-size: 12px; }
.auth-tab:hover { background: #eaf2eb; }
.auth-tab.active { color: #1e603c; border-color: #d7e8db; background: #eaf4ec; }
.auth-content .form-error { color: #9f4037; font-size: 12px; }
.auth-content .success-message { color: #21663e; }
.auth-footnote { margin-top: 20px; color: #75847a; font-size: 11px; }

/* Saved collapsed navigation remains legible and mobile remains a drawer. */
body.sidebar-collapsed .sidebar, body.sidebar-collapsed.admin-ui .sidebar, body.sidebar-collapsed.resident-ui .sidebar { width: 74px; }
body.sidebar-collapsed .main-area, body.sidebar-collapsed.admin-ui .main-area, body.sidebar-collapsed.resident-ui .main-area { margin-left: 74px; }
body.sidebar-collapsed .sidebar-collapse { top: 75px; right: 4px; }
body.sidebar-collapsed .nav-count { color: #fff; background: #315540; }
body.sidebar-collapsed .nav-item[title]:hover::after { color: #fff; background: #102d20; }

@media (max-width: 1180px) {
  .content, body.admin-ui .content { padding-right: 26px; padding-left: 26px; }
  .metrics-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .admin-ui .recognition-layout { grid-template-columns: minmax(0,1.1fr) minmax(255px,.9fr); }
  .section-grid, body.admin-ui .section-grid { grid-template-columns: minmax(0,1.3fr) minmax(265px,.9fr); }
}
@media (max-width: 900px) {
  .section-grid, body.admin-ui .section-grid { grid-template-columns: 1fr; }
  .admin-ui .recognition-layout { grid-template-columns: 1fr; }
  .recognition-details { display: grid; grid-template-columns: 1fr; }
  .recognition-disclaimer { margin-top: 8px; }
}
@media (max-width: 760px) {
  .sidebar, body.admin-ui .sidebar, body.resident-ui .sidebar { width: 270px; }
  .main-area, body.admin-ui .main-area, body.resident-ui .main-area { margin-left: 0; }
  body.sidebar-collapsed .sidebar, body.sidebar-collapsed.admin-ui .sidebar, body.sidebar-collapsed.resident-ui .sidebar { width: 270px; }
  body.sidebar-collapsed .main-area, body.sidebar-collapsed.admin-ui .main-area, body.sidebar-collapsed.resident-ui .main-area { margin-left: 0; }
  .sidebar-collapse { display: none; }
  .sidebar-scrim { background: rgba(14,35,22,.5); backdrop-filter: blur(2px); }
  .topbar, body.admin-ui .topbar { height: 60px; padding: 0 17px; }
  .menu-button { display: block; margin-right: 10px; color: #43594b; }
  .top-actions { gap: 9px; }
  .live-indicator { min-width: 30px; width: 32px; height: 32px; overflow: hidden; justify-content: center; padding: 0; font-size: 0; }
  .live-indicator i { flex: 0 0 auto; }
  .top-date, .top-divider { display: none; }
  .content, body.admin-ui .content { min-height: calc(100vh - 60px); padding: 24px 18px; }
  .welcome-row, body.admin-ui .welcome-row { align-items: flex-start; flex-direction: column; gap: 13px; }
  .welcome-actions { align-self: stretch; flex-wrap: wrap; }
  .welcome-actions .button { flex: 0 0 auto; }
  .metric-card, body.admin-ui .metric-card { min-height: 122px; padding: 15px; }
  .admin-ui .admin-recognition { padding: 16px; }
  .recognition-heading { flex-wrap: wrap; align-items: flex-start; }
  .recognition-camera-controls { order: 3; width: 100%; margin: 0; }
  .recognition-camera-controls select { max-width: 100%; }
  .recognition-layout { grid-template-columns: 1fr; }
  .preview-frame { min-height: clamp(205px, 52vw, 330px); }
  .bottom-grid, body.admin-ui .bottom-grid { grid-template-columns: 1fr; }
  .workspace-grid { grid-template-columns: 1fr; gap: 14px; }
  .workspace-form { padding-bottom: 18px; border-bottom: 1px solid var(--line); }
  .workspace-list { padding-top: 4px; }
  .profile-form { max-width: none; }
  .page-footer { flex-wrap: wrap; gap: 8px 18px; }
  .auth-screen { grid-template-columns: 1fr; grid-template-rows: minmax(180px,27vh) minmax(0,1fr); }
  .auth-art { min-height: 0; padding: 12px 14px 0; }
  .auth-art-card { min-height: 175px; border-radius: 22px 22px 8px 8px; }
  .auth-art-card:after { left: 17%; bottom: -80%; width: 66%; }
  .auth-art-card img { top: 70%; width: min(30%,165px); max-height: 58%; }
  .auth-side { min-height: 72vh; padding: 26px clamp(20px,7vw,45px) 32px; }
  .auth-content { max-width: 520px; padding: 5px 0 18px; }
  .auth-content h1 { margin: 10px 0 24px; }
  .auth-tabs { margin-top: 18px; }
}
@media (max-width: 480px) {
  .content, body.admin-ui .content { padding-right: 13px; padding-left: 13px; }
  .topbar, body.admin-ui .topbar { padding: 0 12px; }
  .breadcrumbs { font-size: 11px; }
  .notification-button { display: none; }
  .metrics-grid { gap: 10px; }
  .metric-card, body.admin-ui .metric-card { min-height: 112px; padding: 12px; }
  .metric-label { max-width: 125px; font-size: 11px; }
  .metric-value, body.admin-ui .metric-value { font-size: 25px; }
  .sparkline { width: 48px; right: 10px; opacity: .18; }
  .welcome-row h1, body.admin-ui .welcome-row h1 { font-size: 25px; }
  .welcome-actions { gap: 7px; }
  .welcome-actions .button { min-height: 38px; padding: 7px 10px; font-size: 11px; }
  .admin-ui .admin-recognition { padding: 13px; }
  .recognition-stats>div { min-height: 57px; }
  .recognition-stats strong { font-size: 17px; }
  .panel-heading, body.admin-ui .panel-heading { padding: 17px 15px 13px; }
  .alert-list { padding: 0 15px; }
  .alerts-link { margin-right: 15px; margin-left: 15px; }
  .camera-list, .registration-list { padding-right: 14px; padding-left: 14px; }
  .workspace-panel { padding-right: 15px; padding-left: 15px; }
  .workspace-heading { align-items: flex-start; }
  .workspace-heading h2 { font-size: 18px; }
  .workspace-heading>.button { min-height: 36px; padding: 7px 10px; font-size: 11px; }
  .profile-form { grid-template-columns: 1fr; }
  .profile-form .workspace-error, .profile-form .button { grid-column: auto; }
  .visitor-row { grid-template-columns: minmax(0,1fr) auto; }
  .registration-row { flex-wrap: wrap; }
  .registration-row .registration-action { margin-left: auto; }
  .auth-screen { grid-template-rows: minmax(150px,22vh) minmax(0,1fr); }
  .auth-art { padding: 8px 9px 0; }
  .auth-art-card { min-height: 150px; }
  .auth-art-card img { width: min(32%,145px); }
  .auth-side { padding: 20px 19px 26px; }
  .auth-content h1 strong { font-size: 32px; }
  .auth-content h1 span { font-size: 27px; }
  .auth-content form { gap: 13px; }
  .auth-footnote { margin-top: 14px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* Biometric enrollment states are explicit and remain separate from access decisions. */
.resident-action[hidden], .admin-only[hidden] { display: none !important; }
.face-consent-settings { display: grid; gap: 11px; }
.face-consent-settings h3 { margin: 0; }
.face-consent-settings #face-enrollment-status { padding: 10px 12px; border: 1px solid #dce8de; border-radius: 9px; color: #375344; background: #f4f8f4; font-size: 12px; }
#face-enrollment-status[data-state="READY"] { color: #23633e; border-color: #cfe4d4; background: #eff8f1; }
#face-enrollment-status[data-state="FAILED"], #face-enrollment-error:not(:empty) { color: #913f36; border-color: #efd3ce; background: #fff2ef; }
.face-consent-settings form { display: grid; gap: 10px; }
.face-consent-settings form > label:not(.face-consent-choice) { display: grid; gap: 7px; color: #43574a; font-size: 12px; font-weight: 600; }
.face-consent-settings input[type="file"] { min-height: 40px; padding: 7px; border: 1px solid #d9e4dc; border-radius: 9px; background: #fff; }
.face-consent-settings .face-consent-choice { display: flex; align-items: flex-start; gap: 9px; color: #344b3b; font-size: 12px; line-height: 1.5; }
.face-consent-choice input { flex: 0 0 auto; margin-top: 3px; accent-color: var(--green); }
.face-consent-settings form > small { color: #6f7e74; font-size: 11px; }
.face-consent-settings form .button { justify-self: start; }
.face-admin-heading { margin-top: 12px; border-top: 1px solid #e8eee9; }
.face-enrollment-row { align-items: center; }
.face-enrollment-row .row-main { flex: 1; }
.face-enrollment-row .face-enrollment-error { color: #913f36; }
.face-enrollment-pill { flex: 0 0 auto; padding: 5px 9px; border-radius: 999px; color: #647369; background: #eff3f0; font-size: 10px; font-weight: 700; }
.face-ready { color: #23633e; background: #eaf5ec; }
.face-pending { color: #8b5b1b; background: #fff3df; }
.face-failed, .face-revoked { color: #93453b; background: #fff0ed; }
.face-enrollment-error { line-height: 1.4; }
@media (max-width: 480px) {
  .face-enrollment-row { align-items: flex-start; flex-wrap: wrap; }
  .face-enrollment-pill { margin-left: 46px; }
}

/* Recognition mode diagnostics, with compact layouts for narrow screens */
.recognition-diagnostics { margin-top: 16px; padding: 14px 16px; border: 1px solid #e6ece7; border-radius: 11px; background: #fbfdfb; color: #405347; }
.recognition-diagnostics summary { cursor: pointer; font-size: 12px; font-weight: 700; }
.diagnostic-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 10px; margin-top: 12px; }
.diagnostic-grid > div { min-width: 0; padding: 10px; border: 1px solid #e8eee9; border-radius: 8px; background: #fff; }
.diagnostic-grid span, .diagnostic-grid strong { display: block; }
.diagnostic-grid span { color: #718077; font-size: 10px; }
.diagnostic-grid strong { margin-top: 5px; color: #2c4635; font-size: 11px; overflow-wrap: anywhere; }
.diagnostic-approvals { margin-top: 12px; font-size: 10px; }
.diagnostic-approvals ul { margin: 5px 0 0; padding-left: 18px; color: #758078; line-height: 1.6; }
#diagnostic-message { margin: 9px 0 0; color: #68766e; font-size: 10px; line-height: 1.5; }
@media (max-width: 760px) { .diagnostic-grid { grid-template-columns: repeat(2,minmax(0,1fr)); } }
@media(max-width:700px) { .alert-card { grid-template-columns: minmax(0,1fr); gap: 10px; } .alert-snapshot,.alert-no-photo { height: auto; min-height: 180px; max-height: 320px; } .alert-card .registration-action { justify-self: start; } .alert-list { padding-right: 14px; padding-left: 14px; } .alerts-actions { padding-right: 14px; padding-left: 14px; } }

/* Verification alerts page polish */
.page-view[data-page-view="alerts"] > .alerts-panel { overflow: hidden; border: 1px solid #eadbd6; border-top: 4px solid #b95145; border-radius: 16px; box-shadow: 0 12px 34px rgba(86,47,39,.08); }
.page-view[data-page-view="alerts"] .panel-heading { align-items: center; padding: 23px 26px; background: linear-gradient(110deg,#fff8f6,#fff 72%); border-bottom: 1px solid #f0e5e1; }
.page-view[data-page-view="alerts"] .heading-with-icon { align-items: center; gap: 13px; }
.page-view[data-page-view="alerts"] .panel-icon { width: 42px; height: 42px; border-radius: 13px; font-size: 18px; }
.page-view[data-page-view="alerts"] .panel-heading h2 { color: #422d29; font-size: 20px; letter-spacing: -.35px; }
.page-view[data-page-view="alerts"] .panel-heading p { margin-top: 5px; color: #796a64; font-size: 12px; }
.page-view[data-page-view="alerts"] .live-pill { display: inline-flex; align-items: center; gap: 7px; padding: 7px 11px; border: 1px solid #f1d8d3; border-radius: 999px; font-weight: 700; }
.page-view[data-page-view="alerts"] .alert-list { padding: 8px 26px 4px; }
.page-view[data-page-view="alerts"] .alert-card { grid-template-columns: minmax(190px,280px) minmax(0,1fr) auto; gap: 20px; padding: 20px 0; border-bottom: 1px solid #f1e8e5; }
.page-view[data-page-view="alerts"] .alert-photo-link { border-color: #e6d7d2; box-shadow: 0 4px 12px rgba(68,44,39,.08); }
.page-view[data-page-view="alerts"] .alert-snapshot { height: 158px; transition: transform .2s ease; }
.page-view[data-page-view="alerts"] .alert-photo-link:hover .alert-snapshot { transform: scale(1.025); }
.page-view[data-page-view="alerts"] .alert-title { color: #382a27; font-size: 16px; font-weight: 750; }
.page-view[data-page-view="alerts"] .alert-detail { color: #72635e; font-size: 12px; }
.page-view[data-page-view="alerts"] .alert-card-content .alert-detail:first-of-type { margin-top: 10px; }
.page-view[data-page-view="alerts"] .alert-card .registration-action { min-height: 36px; padding: 0 14px; border-color: #e8cbc5; border-radius: 8px; color: #8d4037; background: #fff8f6; font-size: 11px; font-weight: 700; }
.page-view[data-page-view="alerts"] .alert-card .registration-action:hover { border-color: #d8a59b; background: #fff0ed; }
.page-view[data-page-view="alerts"] .alert-photo-download { display: inline-flex; align-items: center; gap: 5px; padding: 3px 0; color: #8b453a; text-decoration: none; }
.page-view[data-page-view="alerts"] .alert-photo-download:hover { text-decoration: underline; }
.page-view[data-page-view="alerts"] .alert-no-photo { min-height: 158px; background: linear-gradient(135deg,#faf7f5,#f2eeeb); }
.page-view[data-page-view="alerts"] .alerts-actions { justify-content: flex-start; padding: 18px 26px 22px; background: #fffdfc; }
.page-view[data-page-view="alerts"] .alerts-actions .button { min-height: 40px; padding: 0 16px; border-radius: 9px; font-size: 12px; font-weight: 700; }
.page-view[data-page-view="alerts"] #view-all-alerts { color: #fff; border-color: #9b493f; background: #9b493f; }
.page-view[data-page-view="alerts"] #view-all-alerts:hover { background: #803a33; }
.page-view[data-page-view="alerts"] .empty-alert { min-height: 230px; }
@media(max-width:760px) {
  .page-view[data-page-view="alerts"] .panel-heading { align-items: flex-start; gap: 14px; padding: 18px; }
  .page-view[data-page-view="alerts"] .alert-list { padding-right: 18px; padding-left: 18px; }
  .page-view[data-page-view="alerts"] .alert-card { grid-template-columns: minmax(0,1fr); gap: 12px; }
  .page-view[data-page-view="alerts"] .alert-snapshot { height: clamp(180px,42vw,300px); }
  .page-view[data-page-view="alerts"] .alert-card .registration-action { justify-self: start; }
  .page-view[data-page-view="alerts"] .alerts-actions { padding: 16px 18px; }
}

/* Public landing page for residents and visitors */
.public-landing { min-height: 100vh; color: #203128; background: #eef3ed; }
.landing-header { position: relative; z-index: 2; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 24px; min-height: 82px; padding: 12px clamp(18px,5vw,76px); background: #f2f5ef; border-bottom: 1px solid #dce5d9; }
.landing-brand { display: grid; justify-self: start; color: #3d6038; text-decoration: none; line-height: 1.05; }
.landing-brand strong { font-size: 21px; font-weight: 850; letter-spacing: .02em; }
.landing-brand span { margin-top: 4px; padding-left: 34px; font-size: 12px; font-weight: 700; }
.landing-nav { display: flex; align-items: center; gap: clamp(18px,3.2vw,48px); }
.landing-nav a { color: #17251d; font-size: 16px; text-decoration: none; }
.landing-nav a:hover,.landing-nav a:focus-visible { color: #507a43; text-decoration: underline; text-underline-offset: 5px; }
.landing-auth-actions { display: flex; justify-self: end; gap: 12px; }
.landing-auth-actions button,.landing-start,.landing-contact-action { min-height: 42px; padding: 0 21px; border: 1px solid transparent; border-radius: 9px; color: #fff; background: #73965d; cursor: pointer; font-size: 14px; font-weight: 650; transition: transform .16s ease,background-color .16s ease,box-shadow .16s ease; }
.landing-auth-actions .landing-login { background: #a5b98c; }
.landing-auth-actions .landing-admin { display: inline-flex; min-height: 42px; align-items: center; justify-content: center; padding: 0 21px; border: 1px solid #819b72; border-radius: 9px; color: #45613d; background: transparent; cursor: pointer; font-size: 14px; font-weight: 650; text-decoration: none; transition: transform .16s ease,background-color .16s ease,box-shadow .16s ease; }
.landing-auth-actions .landing-admin:hover,.landing-auth-actions .landing-admin:focus-visible { transform: translateY(-1px); color: #fff; background: #557b45; box-shadow: 0 7px 18px rgba(34,66,36,.2); }
.landing-auth-actions button:hover,.landing-start:hover,.landing-contact-action:hover { transform: translateY(-1px); background: #557b45; box-shadow: 0 7px 18px rgba(34,66,36,.2); }
.landing-hero { min-height: min(760px,calc(100svh - 82px)); padding: clamp(20px,3.5vw,48px); background: #95b18f; }
.landing-hero-frame { position: relative; display: grid; min-height: clamp(480px,72vh,680px); place-items: center; overflow: hidden; border: 7px solid rgba(235,242,232,.7); box-shadow: 0 7px 20px rgba(24,47,31,.38); background-image: linear-gradient(90deg,rgba(15,32,22,.48),rgba(15,32,22,.2) 53%,rgba(15,32,22,.35)),linear-gradient(0deg,rgba(11,24,16,.26),transparent 50%),url('User_login.jpg'); background-position: center; background-size: cover; }
.landing-hero-frame::before { position: absolute; inset: 0; background: radial-gradient(ellipse at center,transparent 23%,rgba(12,25,17,.12) 100%); content: ""; pointer-events: none; }
.landing-hero-copy { position: relative; z-index: 1; width: min(850px,90%); padding: 26px; color: #fff; text-align: center; text-shadow: 0 3px 18px rgba(0,0,0,.5); }
.landing-eyebrow,.landing-section-kicker { display: block; font-size: 11px; font-weight: 800; letter-spacing: .18em; }
.landing-eyebrow { color: #e3efd9; }
.landing-hero-copy h1 { margin: 15px 0 13px; color: #fff; font-size: clamp(39px,7vw,82px); font-weight: 750; line-height: 1.02; letter-spacing: -.045em; }
.landing-hero-copy h1 span { display: block; }
.landing-hero-copy p { max-width: 560px; margin: 0 auto 26px; color: #f6f8f2; font-size: clamp(15px,2vw,19px); line-height: 1.55; }
.landing-start { min-width: 210px; min-height: 58px; border: 2px solid #fff; border-radius: 999px; background: #7f9068; font-size: 19px; box-shadow: 0 8px 24px rgba(11,28,16,.24); }
.landing-photo-caption { position: absolute; right: 20px; bottom: 17px; z-index: 1; padding: 7px 11px; border-radius: 999px; color: #fff; background: rgba(15,37,22,.58); font-size: 11px; letter-spacing: .08em; }
.landing-registration-choice[hidden] { display: none !important; }
.public-landing.registration-choice-mode > :not(.landing-registration-choice):not(#public-visitor-registration) { display: none !important; }
.public-landing.visitor-registration-mode > :not(#public-visitor-registration) { display: none !important; }
.landing-registration-choice { min-height: 100svh; padding: clamp(22px,4vw,52px); background: #91ad8a; }
.registration-choice-frame { position: relative; display: flex; min-height: calc(100svh - clamp(44px,8vw,104px)); flex-direction: column; align-items: center; justify-content: center; overflow: hidden; padding: clamp(68px,8vh,100px) clamp(24px,7vw,90px) 54px; border: 7px solid rgba(28,58,34,.55); box-shadow: 0 3px 12px rgba(15,34,17,.45); background: linear-gradient(rgba(10,24,15,.28),rgba(10,24,15,.34)),url('User_login.jpg') center/cover; }
.registration-choice-frame > h1 { margin: 0 0 clamp(26px,4vh,43px); color: #fff; font-size: clamp(34px,5vw,54px); font-weight: 500; line-height: 1.15; text-align: center; text-shadow: 0 3px 10px rgba(0,0,0,.55); }
.registration-choice-back { position: absolute; top: 17px; left: 19px; padding: 8px 12px; border: 1px solid rgba(255,255,255,.75); border-radius: 8px; color: #fff; background: rgba(18,44,27,.7); cursor: pointer; font: inherit; }
.registration-choice-cards { display: grid; width: min(100%,810px); grid-template-columns: repeat(2,minmax(0,1fr)); gap: clamp(24px,4.2vw,54px); }
.registration-choice-card { display: flex; min-height: 310px; flex-direction: column; align-items: center; padding: 20px clamp(18px,2vw,26px) 25px; border: 1px solid rgba(52,58,50,.75); color: #111; background: rgba(255,255,255,.86); box-shadow: 0 2px 7px rgba(0,0,0,.44); text-align: center; }
.choice-avatar { display: grid; width: 96px; height: 96px; flex: 0 0 auto; place-items: center; border-radius: 50%; background: #9b8b79; font-size: 59px; line-height: 1; }
.resident-choice .choice-avatar { background: #8baa83; }
.registration-choice-card h2 { margin: 27px 0 9px; color: #111; font-size: clamp(20px,2.2vw,25px); font-weight: 750; }
.registration-choice-card p { min-height: 50px; margin: 0 0 19px; color: #111; font-size: clamp(16px,1.8vw,21px); line-height: 1.35; }
.registration-choice-card button { width: min(100%,300px); min-height: 50px; margin-top: auto; padding: 8px 13px; border: 0; border-radius: 8px; color: #fff; background: #8baa83; cursor: pointer; font: inherit; font-size: clamp(15px,1.7vw,19px); font-weight: 750; }
.registration-choice-card button:hover,.registration-choice-card button:focus-visible { background: #557b45; outline: 3px solid rgba(255,255,255,.9); outline-offset: 2px; }
.resident-choice button { background: #9b8b79; }
.resident-choice button:hover,.resident-choice button:focus-visible { background: #71604f; }
.registration-choice-logo { position: absolute; right: 12px; bottom: 11px; width: 57px; height: 57px; border-radius: 50%; background: #fff; object-fit: contain; }
#public-visitor-registration.auth-modal-backdrop { z-index: 45; padding: clamp(12px,3vw,36px); background: rgba(54,78,50,.84); }
.public-visitor-card { position: relative; width: min(100%,1400px); max-height: calc(100svh - 24px); overflow-y: auto; margin: auto; padding: clamp(28px,4vw,48px); border: 1px solid #dce1d9; border-radius: 8px; background: #f2f2f2; box-shadow: 0 4px 16px rgba(17,35,19,.38); }
.public-visitor-back { position: absolute; top: 13px; right: 20px; border: 0; color: #315a3c; background: transparent; cursor: pointer; font: inherit; text-decoration: underline; text-underline-offset: 3px; }
.public-visitor-card > h1 { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); clip-path: inset(50%); white-space: nowrap; }
#public-visitor-form { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,.95fr) minmax(0,1.35fr); align-items: start; gap: clamp(18px,3vw,44px); padding-top: 4px; }
.public-form-group { min-width: 0; }
.public-form-group h2 { margin: 0 0 20px; color: #111; font-size: clamp(20px,2vw,25px); font-weight: 750; }
.public-form-group label { display: grid; gap: 7px; margin: 0 0 17px; color: #101510; font-size: 14px; font-weight: 500; }
.public-form-group input:not([type=radio]):not([type=checkbox]),.public-form-group select { width: 100%; min-height: 48px; padding: 0 13px; border: 2px solid #222; border-radius: 9px; color: #1c2520; background: #e8e8e8; font: inherit; font-size: 14px; }
.public-form-group input:focus-visible,.public-form-group select:focus-visible,.public-visitor-back:focus-visible,.public-form-group button:focus-visible { outline: 3px solid #789b6f; outline-offset: 2px; }
.public-form-group input::placeholder { color: #64706a; }
.public-form-group fieldset { display: grid; gap: 13px; margin: 0 0 20px; padding: 0; border: 0; }
.public-form-group legend { margin-bottom: 14px; color: #111; font-size: 14px; font-weight: 650; }
.public-form-group fieldset label { display: flex; align-items: center; gap: 11px; margin: 0; font-size: clamp(15px,1.8vw,20px); }
.public-form-group input[type=radio],.public-form-group input[type=checkbox] { width: 17px; height: 17px; accent-color: #83a57a; }
.public-form-group .visitor-file-label { margin-top: 19px; }
.visitor-file-label input[type=file],.public-form-group [data-public-visitor-face] input[type=file] { min-width: 0; width: 100%; font-size: 12px; }
.companion-heading { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 23px 0 10px; }
.companion-heading h3,.homeowner-details-group h3 { margin: 0; color: #111; font-size: 19px; }
.companion-heading button { border: 0; color: #315a3c; background: transparent; cursor: pointer; font: inherit; font-weight: 700; }
.visitor-companions { display: grid; gap: 3px; }
.visitor-review-details { margin-top: 8px; padding-top: 6px; border-top: 1px solid #e6ece7; }
.visitor-review-details summary { color: #4c7052; cursor: pointer; font-size: 12px; font-weight: 700; }
.visitor-review-details > div { display: grid; gap: 4px; padding-top: 7px; }
.visitor-review-details small { color: #536159; font-size: 11px; line-height: 1.45; }
.visitor-review-details a { color: #315a3c; font-weight: 700; }
.visitor-companion-row { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: end; gap: 7px; }
.visitor-companion-row button { min-height: 36px; margin-bottom: 17px; padding: 0 12px; border: 0; border-radius: 7px; color: #fff; background: #8baa83; cursor: pointer; }
.public-form-group .visitor-face-consent { display: flex; align-items: flex-start; gap: 8px; margin-top: 12px; font-size: 13px; line-height: 1.4; }
.face-verification-title { margin: 18px 0 5px; color: #111; font-size: 16px; }
.homeowner-match-note { grid-column: 1/-1; margin: -12px 0 12px; color: #59675d; font-size: 12px; line-height: 1.4; }
.homeowner-details-group { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); align-items: start; column-gap: 15px; }
.homeowner-details-group h2,.homeowner-details-group h3 { grid-column: 1/-1; }
.homeowner-details-group h3 { margin: 4px 0 17px; text-align: center; }
.public-visitor-error { grid-column: 1/-1; margin: 0; color: #9c2828; font-size: 14px; }
.public-visitor-submit { grid-column: 3; justify-self: end; width: min(100%,305px); min-height: 54px; padding: 8px 20px; border: 0; border-radius: 10px; color: #fff; background: #8baa83; box-shadow: 0 3px 9px rgba(0,0,0,.28); cursor: pointer; font: inherit; font-size: 19px; font-weight: 650; }
.public-visitor-submit:hover,.public-visitor-submit:focus-visible { background: #557b45; }
.public-visitor-error.success { color: #285a36; font-weight: 650; }
.landing-info,.landing-contact { padding: clamp(48px,8vw,96px) 24px; }
.account-location-status,.account-location-link { flex-basis: 100%; margin: 0; color: #59675d; font-size: 12px; }
.account-location-link { color: #315a3c; font-weight: 700; }
.account-location-link[hidden] { display: none; }
.welcome-actions #landing-location-button { min-height: 38px; }
.location-map-open { overflow: hidden; }
.location-map-overlay[hidden] { display: none !important; }
.location-map-overlay { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; padding: clamp(8px,2vw,24px); background: rgba(12,24,17,.72); }
.location-map-dialog { display: grid; grid-template-rows: auto minmax(0,1fr) auto; width: min(100%,1440px); height: min(94svh,900px); overflow: hidden; border-radius: 14px; background: #fff; box-shadow: 0 24px 80px rgba(0,0,0,.4); }
.location-map-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 20px; color: #fff; background: #8eaa87; }
.location-map-header .workspace-kicker { color: #eff5eb; }
.location-map-header h2 { margin: 3px 0 0; color: #fff; font-size: 20px; }
.location-map-header p { margin: 2px 0 0; color: #f4f6f1; font-size: 12px; }
.location-map-close { flex: 0 0 auto; width: 40px; height: 40px; border: 0; border-radius: 50%; color: #fff; background: #294234; cursor: pointer; font-size: 25px; }
.location-map-panels { display: grid; min-height: 0; grid-template-rows: 1fr 1fr; gap: 2px; background: #59675d; }
.location-map-panels iframe { display: block; width: 100%; height: 100%; min-height: 0; border: 0; background: #e8eee8; }
.location-map-footer { display: flex; justify-content: space-between; gap: 12px; padding: 10px 18px; color: #4e5f53; background: #fff; font-size: 12px; }
.location-map-footer a { color: #315a3c; font-weight: 700; }
.landing-info { min-height: 500px; display: grid; align-items: start; padding: clamp(36px,5vw,64px) clamp(18px,8.4vw,108px); background: #8eaa87; }
.landing-info-inner { width: 100%; max-width: 1120px; margin: 0 auto; text-align: left; }
.landing-about-card { padding: clamp(28px,4.2vw,52px) clamp(26px,6.5vw,84px); border-radius: 30px; color: #090d0a; background: #fff; box-shadow: 0 4px 12px 5px rgba(17,35,19,.58); }
.landing-about-card h2 { margin: 0 0 24px; color: #050705; font-size: clamp(34px,4vw,50px); font-weight: 500; line-height: 1.15; letter-spacing: -.045em; }
.landing-about-card p { margin: 0 0 2px; color: #111612; font-size: clamp(17px,2vw,23px); line-height: 1.4; }
.landing-about-card p + p { text-indent: 0; }
.landing-about-card strong { display: block; margin-top: 32px; color: #080c09; font-size: clamp(18px,2.2vw,26px); line-height: 1.35; }
.landing-section-kicker { color: #668455; }
.landing-info h2,.landing-contact h2 { margin: 13px 0; color: #263c2c; font-size: clamp(27px,4vw,42px); letter-spacing: -.035em; }
.landing-info p,.landing-contact p { max-width: 710px; margin: 0 auto; color: #667367; font-size: 16px; line-height: 1.75; }
.landing-contact { display: grid; place-items: center; background: #e4ebdf; text-align: center; }
.landing-contact-action { margin-top: 24px; }
.landing-footer { display: flex; justify-content: space-between; gap: 16px; padding: 19px clamp(18px,5vw,76px); color: #eaf0e7; background: #25402e; font-size: 12px; }
.landing-footer a { color: #eaf0e7; }
.auth-dialog-open { overflow: hidden; }
.auth-modal-backdrop { position: fixed; inset: 0; z-index: 40; display: grid; place-items: center; overflow-y: auto; padding: 22px; background: rgba(15,31,20,.65); backdrop-filter: blur(7px); }
.auth-modal-backdrop[hidden] { display: none !important; }
.auth-dialog { position: relative; width: min(100%,540px); max-height: min(92svh,900px); overflow-y: auto; padding: 26px clamp(21px,5vw,46px) 34px; border: 1px solid rgba(255,255,255,.75); border-radius: 22px; background: #f7f9f5; box-shadow: 0 24px 85px rgba(0,0,0,.3); }
.auth-dialog .auth-content { width: 100%; max-width: 440px; margin: 0 auto; padding: 10px 0; }
.auth-dialog .auth-content h1 { margin: 12px 0 26px; }
.auth-dialog .auth-content h1 strong { font-size: clamp(30px,5vw,39px); }
.auth-dialog .auth-content h1 span { font-size: clamp(25px,4vw,32px); }
.auth-dialog .auth-tabs { margin-top: 15px; }
.auth-dialog .auth-footnote { margin-top: 16px; }
.auth-dialog-close { position: sticky; top: 0; z-index: 2; float: right; display: grid; width: 38px; height: 38px; margin: -10px -20px 0 0; place-items: center; border: 0; border-radius: 10px; color: #344a39; background: #eaf0e7; cursor: pointer; font-size: 24px; }
.auth-dialog-close:hover { background: #dce8d8; }
@media(max-width:760px) {
  .welcome-actions #landing-location-button { width: 100%; }
  .location-map-dialog { width: 100%; height: 96svh; border-radius: 10px; }
  .location-map-header { padding: 10px 14px; }
  .location-map-header h2 { font-size: 17px; }
  .location-map-footer { align-items: flex-start; flex-direction: column; }
  .landing-header { grid-template-columns: 1fr auto; gap: 10px; padding: 12px 16px; }
  .landing-brand strong { font-size: 17px; }
  .landing-brand span { padding-left: 22px; font-size: 10px; }
  .landing-nav { grid-column: 1/-1; grid-row: 2; justify-content: center; gap: clamp(18px,7vw,42px); padding: 4px 0 7px; }
  .landing-nav a { font-size: 14px; }
  .landing-auth-actions { grid-column: 2; grid-row: 1; gap: 7px; }
  .landing-auth-actions button { min-height: 36px; padding: 0 12px; font-size: 12px; }
  .landing-auth-actions .landing-admin { min-height: 36px; padding: 0 12px; font-size: 12px; }
  .landing-hero { min-height: 0; padding: 15px; }
  .landing-hero-frame { min-height: clamp(420px,68svh,610px); background-position: 48% center; }
  .landing-hero-copy { width: 100%; padding: 20px 10px; }
  .landing-hero-copy h1 { font-size: clamp(39px,10vw,64px); }
  .landing-hero-copy p { max-width: 420px; }
  .landing-start { min-height: 52px; }
  .landing-registration-choice { min-height: 100svh; padding: 14px; }
  .registration-choice-frame { min-height: calc(100svh - 28px); padding: 70px 20px 52px; }
  .registration-choice-frame > h1 { margin-bottom: 24px; }
  .registration-choice-cards { width: min(100%,560px); gap: 16px; }
  .registration-choice-card { min-height: 285px; padding: 18px 12px 20px; }
  .choice-avatar { width: 78px; height: 78px; font-size: 48px; }
  .registration-choice-card h2 { margin-top: 20px; }
  .registration-choice-logo { width: 44px; height: 44px; }
  #public-visitor-registration.auth-modal-backdrop { padding: 10px; }
  .public-visitor-card { max-height: calc(100svh - 20px); padding: 50px 20px 24px; }
  #public-visitor-form { grid-template-columns: minmax(0,1fr); gap: 22px; }
  .public-visitor-submit { grid-column: 1; justify-self: stretch; width: 100%; }
  .auth-modal-backdrop { align-items: start; padding: 12px; }
  .auth-dialog { max-height: calc(100svh - 24px); border-radius: 18px; padding: 22px 20px 28px; }
  .auth-dialog-close { margin-right: -10px; }
}
@media(max-width:420px) {
  .landing-header { grid-template-columns: 1fr auto; }
  .landing-nav { justify-content: space-between; gap: 8px; }
  .landing-nav a { font-size: 13px; }
  .registration-choice-cards { grid-template-columns: 1fr; width: min(100%,360px); gap: 13px; }
  .registration-choice-frame { justify-content: flex-start; padding: 65px 15px 52px; }
  .registration-choice-frame > h1 { font-size: 31px; }
  .registration-choice-card { min-height: 220px; padding: 13px 14px 15px; }
  .choice-avatar { width: 60px; height: 60px; font-size: 38px; }
  .registration-choice-card h2 { margin: 10px 0 4px; font-size: 18px; }
  .registration-choice-card p { min-height: 0; margin-bottom: 12px; font-size: 15px; }
  .registration-choice-card button { min-height: 42px; font-size: 15px; }
  .public-visitor-card { padding: 53px 16px 23px; }
  #public-visitor-form { grid-template-columns: 1fr; gap: 22px; }
  .public-form-group h2 { margin-bottom: 14px; }
  .homeowner-details-group { grid-template-columns: 1fr; }
  .homeowner-details-group h2,.homeowner-details-group h3 { grid-column: 1; }
  .public-visitor-submit { grid-column: 1; justify-self: stretch; width: 100%; }
  .landing-hero { padding: 9px; }
  .landing-hero-frame { min-height: 440px; border-width: 4px; }
  .landing-eyebrow { font-size: 9px; }
  .landing-hero-copy h1 { font-size: 39px; }
  .landing-photo-caption { right: 10px; bottom: 10px; }
  .landing-footer { font-size: 10px; }
}
@media(prefers-reduced-motion:reduce) { .landing-auth-actions button,.landing-start,.landing-contact-action { transition: none; } }
#admin-face-enrollment-form { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); align-items: start; column-gap: 22px; }
#admin-face-enrollment-form > label:not(.face-consent-choice),
#admin-face-enrollment-form > .workspace-error,
#admin-face-enrollment-form > button { min-width: 0; }
#admin-face-enrollment-form > small,
#admin-face-enrollment-form > .face-consent-choice,
#admin-face-enrollment-form > .workspace-error,
#admin-face-enrollment-form > button { grid-column: 1/-1; }
#admin-face-enrollment-form select,
.workspace-form select { display: block; width: 100%; min-width: 0; min-height: 44px; height: auto; margin-top: 3px; padding: 9px 40px 9px 12px; border: 1px solid #cbd9cf; border-radius: 9px; color: #20382a; background-color: #fff; font: inherit; font-size: 14px; line-height: 1.4; box-shadow: 0 1px 3px rgba(25,56,39,.04); }
#admin-face-enrollment-form select:focus,
.workspace-form select:focus { border-color: #5b9d71; outline: 3px solid rgba(91,157,113,.2); outline-offset: 1px; }
#admin-face-enrollment-form select option,
.workspace-form select option { color: #20382a; background: #fff; }
@media(max-width:600px) { #admin-face-enrollment-form { grid-template-columns: minmax(0,1fr); } #admin-face-enrollment-form > label,#admin-face-enrollment-form > small,#admin-face-enrollment-form > .workspace-error,#admin-face-enrollment-form > button { grid-column: 1; } }
.user-credentials-modal { width: min(100%, 480px); }
.admin-register-person-modal { width: min(100%, 760px); max-width: 100%; max-height: calc(100dvh - 36px); overflow-x: hidden; overflow-y: auto; overscroll-behavior: contain; }
#admin-register-person-backdrop { align-items: center; justify-items: center; overflow-x: hidden; overflow-y: auto; padding: 18px; }
.admin-register-person-modal form { min-width: 0; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; gap: 14px 18px; }
.admin-register-person-modal form > * { min-width: 0; }
.admin-register-person-modal form > label:not(.face-consent-choice),
.admin-register-person-modal .admin-person-selfie { display: grid; gap: 6px; color: #425348; font-size: 12px; font-weight: 650; }
.admin-register-person-modal input:not([type="checkbox"]),
.admin-register-person-modal select { width: 100%; min-height: 42px; border: 1px solid #dce6de; border-radius: 9px; padding: 8px 11px; color: #25382d; background: #fff; font-size: 13px; }
.admin-register-person-modal input[type="file"] { min-height: 0; padding: 8px; }
.admin-register-person-modal .admin-person-selfie small { color: #748279; font-size: 11px; font-weight: 400; line-height: 1.5; }
.admin-register-person-modal .admin-person-face-clear,
.admin-register-person-modal .admin-person-face-consent { grid-column: 1 / -1; display: grid !important; grid-template-columns: 20px minmax(0,1fr); align-items: start; gap: 10px; padding: 12px 14px; border: 1px solid #e3ece5; border-radius: 10px; background: #f8fbf8; color: #344b3b; font-size: 13px; font-weight: 500; line-height: 1.5; }
.admin-register-person-modal .face-consent-choice input[type="checkbox"] { display: block; width: 18px !important; min-width: 18px; max-width: 18px; height: 18px !important; min-height: 18px; margin: 2px 0 0 !important; padding: 0 !important; border: 1px solid #9fb5a5; border-radius: 4px; flex: none; accent-color: var(--green); }
.admin-register-person-modal input[type="file"] { display: block; max-width: 100%; min-height: 46px; overflow: hidden; font-size: 12px; }
.admin-register-person-modal .admin-person-selfie { min-width: 0; }
.admin-register-person-modal .selfie-capture-row { display: flex; align-items: center; min-height: 46px; }
.admin-register-person-modal .selfie-capture-row .auth-camera-button { min-height: 40px; padding: 0 14px; border: 1px solid #d7e6db; border-radius: 9px; background: #f5faf6; color: var(--green); cursor: pointer; font-weight: 650; }
.admin-register-person-modal .admin-person-selfie small { max-width: 58ch; }
.admin-register-person-modal form > .face-consent-choice { min-width: 0; }
.admin-register-person-modal [data-selfie-preview] { max-width: 220px; max-height: 220px; border-radius: 12px; object-fit: cover; }
.admin-register-person-modal form > .form-error,
.admin-register-person-modal form > .user-credentials-actions { grid-column: 1 / -1; }
.admin-register-person-modal .modal-close { position: sticky; float: right; top: 0; z-index: 2; margin: -8px -8px 0 0; }
@media(max-width:600px) {
  #admin-register-person-backdrop { padding: 10px; }
  .admin-register-person-modal { width: 100%; max-height: calc(100dvh - 20px); padding: 22px 18px; }
  .admin-register-person-modal form { grid-template-columns: minmax(0, 1fr); }
  .admin-register-person-modal .admin-person-face-clear,
  .admin-register-person-modal .admin-person-face-consent { grid-column: 1; }
  .admin-register-person-modal form > .form-error,
  .admin-register-person-modal form > .user-credentials-actions { grid-column: 1; }
}
.user-profile-modal { width: min(100%, 520px); }
.user-profile-details { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 16px; }
.user-profile-detail { min-width: 0; padding: 11px 12px; border: 1px solid #e9efea; border-radius: 8px; background: #fafcfa; }
.user-profile-detail span, .user-profile-detail strong { display: block; overflow-wrap: anywhere; }
.user-profile-detail span { margin-bottom: 5px; color: #87928c; font-size: 9px; }
.user-profile-detail strong { color: #36443b; font-size: 11px; font-weight: 600; }
.user-profile-modal .modal-close { z-index: 1; }
.user-credentials-modal form { display: grid; gap: 13px; }
.user-credentials-modal form label { display: grid; gap: 6px; color: #425348; font-size: 12px; font-weight: 650; }
.user-credentials-modal form input { width: 100%; min-height: 42px; border: 1px solid #dce6de; border-radius: 9px; padding: 0 11px; color: #25382d; background: #fff; font-size: 13px; }
.user-credentials-modal form input:focus { border-color: #78a887; outline: 3px solid rgba(72,137,91,.16); }
.user-credentials-actions { display: flex; justify-content: flex-end; gap: 9px; }
.user-actions { display: flex; min-width: 230px; flex-wrap: wrap; gap: 6px; }
.user-actions .registration-action { min-height: 30px; padding: 5px 8px; border-radius: 7px; font-size: 10px; }
@media(max-width:480px) { .user-credentials-actions { flex-direction: column-reverse; } .user-credentials-actions .button { width: 100%; min-height: 42px; } }




/* Camera monitor layouts */
.camera-module-heading { align-items: center; gap: 16px; }
.camera-layout-control { display: inline-flex; gap: 5px; padding: 4px; border: 1px solid #e3eae5; border-radius: 10px; background: #f5f8f5; }
.camera-layout-button { min-width: 38px; height: 34px; border: 0; border-radius: 7px; color: #52645a; background: transparent; cursor: pointer; font-weight: 700; }
.camera-layout-button[aria-pressed="true"] { color: #fff; background: var(--green); box-shadow: 0 2px 6px rgba(36,114,79,.2); }
.camera-monitor-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; padding: 0 20px 18px; }
.camera-monitor-grid[data-layout="1"] { grid-template-columns: minmax(0,1fr); }
.camera-monitor-grid[data-layout="2"] { grid-template-columns: repeat(2,minmax(0,1fr)); }
.camera-monitor-grid[data-layout="3"] { grid-template-columns: repeat(3,minmax(0,1fr)); }
.camera-monitor-grid[data-layout="4"] { grid-template-columns: repeat(2,minmax(0,1fr)); }
.camera-monitor-tile { min-width: 0; overflow: hidden; border: 1px solid #dce5de; border-radius: 10px; background: #14221a; }
.camera-monitor-tile.is-active { border: 2px solid #62a977; }
.camera-monitor-placeholder { position: relative; display: flex; min-height: clamp(155px,23vw,310px); flex-direction: column; align-items: center; justify-content: center; gap: 10px; color: #c9d7cc; background: linear-gradient(140deg,#34473a,#17271e 65%,#21372a); font-size: 11px; letter-spacing: .1em; }
.camera-monitor-grid[data-layout="1"] .camera-monitor-placeholder { min-height: clamp(280px,48vw,620px); }
.camera-monitor-grid[data-layout="3"] .camera-monitor-placeholder { min-height: clamp(150px,18vw,250px); }
.camera-monitor-grid[data-layout="3"] .camera-monitor-caption { align-items: flex-start; flex-direction: column; }
.camera-monitor-placeholder::before { position: absolute; inset: 0; background: repeating-linear-gradient(0deg,transparent 0 37px,rgba(255,255,255,.035) 38px),repeating-linear-gradient(90deg,transparent 0 37px,rgba(255,255,255,.035) 38px); content: ""; }
.camera-monitor-placeholder small,.camera-monitor-placeholder span { z-index: 1; }
.camera-monitor-placeholder small { color: #aebeb2; font-size: 10px; letter-spacing: 0; }
.camera-monitor-indicator { width: 9px; height: 9px; border-radius: 50%; background: #d99665; box-shadow: 0 0 0 5px rgba(217,150,101,.16); }
.camera-monitor-tile.is-active .camera-monitor-indicator { background: #70cf8c; box-shadow: 0 0 0 5px rgba(112,207,140,.18); }
.camera-monitor-caption { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 11px 13px 4px; color: #fff; }
.camera-monitor-caption>div { min-width: 0; }
.camera-monitor-caption strong,.camera-monitor-caption small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.camera-monitor-caption strong { font-size: 13px; }
.camera-monitor-caption small { margin-top: 3px; color: #b9c8bd; font-size: 10px; }
.camera-monitor-caption .button { min-height: 32px; white-space: nowrap; }
.camera-live-badge { padding: 4px 7px; border-radius: 999px; color: #b9efc5; background: #235938; font-size: 9px; font-weight: 700; }
.camera-monitor-note { margin: 0; padding: 4px 13px 11px; color: #afc0b4; font-size: 10px; line-height: 1.4; }
.camera-monitor-empty,.camera-layout-note { grid-column: 1/-1; margin: 0; padding: 22px; border: 1px dashed #d7e1d9; border-radius: 9px; color: #66756d; text-align: center; font-size: 12px; }
.camera-layout-note { padding: 2px 0; border: 0; text-align: left; font-size: 10px; }
.camera-live-view { margin: 0 20px 18px; overflow: hidden; border: 1px solid #dce5de; border-radius: 12px; background: #14221a; }
.camera-live-view .preview-frame { width: 100%; min-height: clamp(240px,42vw,560px); aspect-ratio: 16/9; }
.camera-live-view .preview-frame img { width: 100%; height: 100%; object-fit: contain; }
.camera-live-caption { display: flex; align-items: center; flex-wrap: wrap; gap: 12px 18px; padding: 12px 16px; color: #53645a; background: #fff; }
.camera-live-caption label { display: flex; align-items: center; gap: 8px; color: #415348; font-size: 11px; font-weight: 600; }
.camera-live-caption select { min-width: 180px; max-width: min(420px,55vw); height: 36px; border: 1px solid #dce6de; border-radius: 8px; padding: 0 10px; color: #34483b; background: #fff; }
.camera-live-caption>small { flex: 1 1 180px; color: #728077; font-size: 10px; }
.dashboard-recognition-details { grid-template-columns: 1fr; }
@media(max-width:1000px) { .camera-monitor-grid[data-layout="3"] { grid-template-columns: repeat(2,minmax(0,1fr)); } .camera-monitor-grid[data-layout="3"] .camera-monitor-tile:last-of-type:nth-of-type(3) { grid-column: 1/-1; } }
@media(max-width:760px) { .camera-monitor-grid { padding-right: 14px; padding-left: 14px; } .camera-monitor-grid[data-layout="1"] .camera-monitor-placeholder,.camera-monitor-placeholder { min-height: clamp(135px,34vw,230px); } .camera-monitor-grid[data-layout="3"] { grid-template-columns: repeat(2,minmax(0,1fr)); } }
@media(max-width:760px) { .camera-live-view { margin-right: 14px; margin-left: 14px; } .camera-live-caption { align-items: flex-start; flex-direction: column; } .camera-live-caption select { max-width: 100%; } }
@media(max-width:520px) { .camera-module-heading { align-items: flex-start; flex-direction: column; } .camera-monitor-grid[data-layout="2"],.camera-monitor-grid[data-layout="3"],.camera-monitor-grid[data-layout="4"] { grid-template-columns: minmax(0,1fr); } .camera-monitor-grid[data-layout="3"] .camera-monitor-tile:last-of-type:nth-of-type(3) { grid-column: auto; } .camera-monitor-grid[data-layout="1"] .camera-monitor-placeholder { min-height: 52vw; } }

/* Voice announcements (admin recognition panel) */
.voice-alerts { display: grid; gap: 10px; margin: 0 0 14px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 12px; background: #fbfdfb; }
.voice-alerts-heading { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px; }
.voice-alerts-heading strong { color: var(--ink); font-size: 14px; }
.voice-alerts-heading small { color: var(--muted); font-size: 12px; }
.voice-toggle { display: flex; align-items: center; gap: 9px; color: var(--ink); font-size: 14px; }
.voice-toggle input, .voice-volume input[type=range] { accent-color: var(--green); }
.voice-volume { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; color: var(--ink); font-size: 14px; }
.voice-volume input[type=range] { flex: 1 1 180px; min-width: 0; max-width: 320px; }
.voice-volume output { min-width: 3em; color: var(--muted); font-variant-numeric: tabular-nums; }
.voice-alerts-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.voice-alerts-actions[hidden], .voice-alerts-actions button[hidden] { display: none !important; }
.voice-alerts-note { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.4; }

/* Export dialog */
.export-modal { width: min(100%,600px); max-height: min(92svh,900px); overflow-y: auto; }
.export-form { display: grid; gap: 12px; }
.export-form > label, .export-range { display: grid; gap: 6px; margin: 0; color: var(--ink); font-size: 13px; font-weight: 600; }
.export-form select, .export-form input { width: 100%; min-height: 42px; min-width: 0; padding: 0 10px; border: 1px solid #cfd8d2; border-radius: 9px; background: #fff; font: inherit; font-size: 14px; font-weight: 400; }
.export-range { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px 12px; margin: 0; padding: 12px; border: 1px solid var(--line); border-radius: 12px; }
.export-range legend { padding: 0 6px; color: var(--ink); font-size: 13px; font-weight: 700; }
.export-count { min-height: 1.4em; margin: 0; color: #315a3c; font-size: 13px; font-weight: 600; }
.export-form .user-credentials-actions { flex-wrap: wrap; }
@media(max-width:520px) { .export-range { grid-template-columns: minmax(0,1fr); } }

/* Camera gate and direction */
.camera-assign-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.camera-new-gate[hidden], #new-camera-gate-field[hidden] { display: none !important; }
.camera-assign-table th, .camera-assign-table td { padding: 8px 6px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
.camera-assign-table th { color: var(--muted); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; }
.camera-assign-table input, .camera-assign-table select { width: 100%; min-width: 110px; min-height: 36px; padding: 0 8px; border: 1px solid #cfd8d2; border-radius: 8px; font: inherit; }
.camera-subcell { display: block; margin-top: 2px; color: var(--muted); font-size: 11px; font-weight: 400; }
.camera-connection-state { display: block; margin-top: 3px; color: #8a5a1f; font-size: 12px; }
.camera-connection-state.is-connected { color: #2e806c; font-weight: 650; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; }

/* One live feed per running camera (camera-monitor.js) */
.camera-tile-feed { position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%; object-fit: contain; background: #0b120e; }
.camera-tile-feed[hidden], .camera-tile-fallback[hidden] { display: none !important; }
.camera-monitor-placeholder .camera-tile-fallback { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px; text-align: center; }
.camera-tile-error { max-width: 38ch; color: #f0c48a; font-size: 11px; line-height: 1.4; }
.camera-tile-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.camera-tile-actions button[hidden] { display: none !important; }
.camera-monitor-tile.is-active .camera-monitor-indicator { background: #55c48e; }

/* Residents directory */
.residents-toolbar { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 10px 16px; margin: 0 0 12px; }
.residents-search-label { display: grid; gap: 6px; width: min(100%,340px); color: var(--ink); font-size: 13px; font-weight: 600; }
.residents-search-label input { min-height: 42px; min-width: 0; padding: 0 12px; border: 1px solid #cfd8d2; border-radius: 9px; background: #fff; color: var(--ink); font: inherit; font-size: 14px; font-weight: 400; }
#residents-count { color: var(--muted); font-size: 12px; }

/* Voice picker */
.voice-volume select { min-height: 36px; max-width: 100%; min-width: 0; padding: 0 8px; border: 1px solid #cfd8d2; border-radius: 8px; background: #fff; color: var(--ink); font: inherit; font-size: 13px; }

/* Visitors: filters, schedule and history */
.visitor-summary { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 0 0 12px; color: var(--muted); font-size: 13px; }
.visitor-summary strong { color: var(--ink); font-size: 16px; margin-right: 4px; }
.visitor-filters { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px 12px; margin: 0 0 14px; }
.visitor-filters label { display: grid; gap: 5px; min-width: 0; color: var(--ink); font-size: 12px; font-weight: 600; }
.visitor-filters select, .visitor-filters input { min-height: 40px; min-width: 0; padding: 0 10px; border: 1px solid #cfd8d2; border-radius: 9px; background: #fff; color: var(--ink); font: inherit; font-size: 14px; font-weight: 400; }
.visitor-search-field { flex: 1 1 220px; }
.visitor-search-field input { width: 100%; }
.visitor-day h3 { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; margin: 14px 0 6px; color: var(--ink); font-size: 14px; }
.visitor-day h3 span { color: var(--muted); font-size: 12px; font-weight: 400; }
.visitor-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.visitor-row-main { min-width: 0; display: grid; gap: 2px; }
.visitor-row-side { display: grid; justify-items: end; gap: 8px; flex: 0 0 auto; }
.visitor-checkin { color: #2e806c; font-weight: 650; }
.visitor-review-note { color: #59675d; }
.visitor-review { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
.visitor-history-modal { width: min(100%,760px); max-height: min(92svh,900px); overflow-y: auto; }
.visitor-history-body h3 { margin: 16px 0 6px; font-size: 14px; color: var(--ink); }
.visitor-history-person { display: grid; gap: 2px; margin: 0 0 6px; }
.visitor-history-person small { color: var(--muted); }
@media(max-width:560px) { .visitor-row { flex-direction: column; } .visitor-row-side { justify-items: start; } .visitor-review { justify-content: flex-start; } }

/* Pending registrations: search, applicant review and documents */
.registration-toolbar { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 10px 14px; margin: 0 0 12px; }
.registration-toolbar label { display: grid; gap: 5px; min-width: 0; color: var(--ink); font-size: 12px; font-weight: 600; }
.registration-search-label { width: min(100%,340px); }
.registration-toolbar input, .registration-toolbar select { min-height: 40px; min-width: 0; padding: 0 10px; border: 1px solid #cfd8d2; border-radius: 9px; background: #fff; color: var(--ink); font: inherit; font-size: 14px; font-weight: 400; }
#registration-count { color: var(--muted); font-size: 12px; }
.registration-review { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.registration-review-main { min-width: 0; display: grid; gap: 2px; }
.registration-review-main small { color: #59675d; }
.registration-docs a { color: #315a3c; font-weight: 700; }
.registration-review-actions { display: flex; flex: 0 0 auto; flex-wrap: wrap; justify-content: flex-end; gap: 6px; }
@media(max-width:560px) { .registration-review { flex-direction: column; } .registration-review-actions { justify-content: flex-start; } }

/* Visitor pre-registration: styled to match the Welcome to Pacific Town dialog */
#public-visitor-registration.auth-modal-backdrop { background: rgba(38, 66, 46, .72); }
#public-visitor-registration .auth-dialog { width: min(100%, 1400px); max-width: 100%; max-height: calc(100svh - 24px); margin: auto; border: 0; border-radius: 22px; background: #f7f9f5; box-shadow: 0 24px 85px rgba(0, 0, 0, .35); padding: clamp(24px, 4vw, 44px); }
#public-visitor-registration .public-visitor-back { top: 16px; right: 16px; display: grid; width: 40px; height: 40px; place-items: center; border-radius: 12px; background: #eaf0e7; color: #344a39; font-size: 26px; line-height: 1; text-decoration: none; }
#public-visitor-registration .public-visitor-back:hover { background: #dce8d8; }
#public-visitor-registration .auth-dialog > h1 { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); clip-path: inset(50%); white-space: nowrap; }
.visitor-welcome { margin: 0 0 30px; }
.visitor-kicker { display: block; color: #477e4e; font-size: 10px; font-weight: 800; letter-spacing: 2px; }
.visitor-welcome h2 { margin: 12px 0 0; color: #050b07; font-size: clamp(30px, 4vw, 40px); font-weight: 800; line-height: 1.1; letter-spacing: -.5px; }
.visitor-welcome h2 span { display: block; margin-top: 4px; color: #2a3d31; font-size: clamp(26px, 3.3vw, 34px); font-weight: 400; }
#public-visitor-form .public-form-group input:not([type=radio]):not([type=checkbox]):not([type=file]),
#public-visitor-form .public-form-group select { min-height: 48px; border: 0; border-radius: 28px; background: #fff; box-shadow: 0 2px 6px rgba(15, 31, 20, .12); padding: 0 22px; color: #17251c; font-size: 14px; outline: 2px solid transparent; }
#public-visitor-form .public-form-group input:focus-visible,
#public-visitor-form .public-form-group select:focus-visible { outline-color: #64a675; }
#public-visitor-form .public-form-group input::placeholder { color: #435149; opacity: 1; }
#public-visitor-form .public-form-group label { color: #17251c; font-weight: 600; }
#public-visitor-form .public-visitor-submit { border-radius: 24px; background: #173d2e; box-shadow: 0 6px 18px rgba(15, 48, 35, .25); }
#public-visitor-form .public-visitor-submit:hover, #public-visitor-form .public-visitor-submit:focus-visible { background: #0f3023; }

/* Pre-register as a visitor button uses the same fill as Resident registration */
.visitor-choice button { background: #9b8b79; }
.visitor-choice button:hover,.visitor-choice button:focus-visible { background: #71604f; }
