/* Nepal Disaster Search — mobile first.
   Most visitors arrive on a phone, often on a poor connection, so this file is
   deliberately small: no framework, no web fonts, system UI stack. */

:root {
  --bg: #f6f7f9;
  --surface: #ffffff;
  --surface-2: #eef1f5;
  --text: #12181f;
  --text-muted: #5b6673;
  --border: #d8dee6;
  --brand: #b8253a;          /* Nepal crimson */
  --brand-dark: #8f1a2c;
  --brand-ink: #ffffff;
  --accent: #0f3d6e;
  --good: #10714a;
  --good-bg: #e2f5ec;
  --alert: #9a5b00;
  --alert-bg: #fdf1dc;
  --bad: #a3182b;
  --bad-bg: #fdeaec;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgba(16, 24, 40, .06), 0 4px 12px rgba(16, 24, 40, .06);
  --tap: 44px;               /* minimum comfortable touch target */
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e1319;
    --surface: #161d26;
    --surface-2: #1f2833;
    --text: #e9edf2;
    --text-muted: #9aa7b5;
    --border: #2b3644;
    --brand: #e04257;
    --brand-dark: #c02f43;
    --accent: #7fb2e8;
    --good: #5bd6a0;
    --good-bg: #102f24;
    --alert: #e9b464;
    --alert-bg: #33270f;
    --bad: #f38b98;
    --bad-bg: #3a1219;
    --shadow: 0 1px 2px rgba(0, 0, 0, .4);
  }
}

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans Devanagari", sans-serif;
  font-size: 16px;
  line-height: 1.55;
  overflow-wrap: break-word;
}

h1, h2, h3 { line-height: 1.25; margin: 0 0 .5rem; }
h1 { font-size: 1.5rem; letter-spacing: -.01em; }
h2 { font-size: 1.15rem; }
p { margin: 0 0 .85rem; }
a { color: var(--accent); }
a:focus-visible, button:focus-visible, input:focus-visible,
select:focus-visible, textarea:focus-visible, summary:focus-visible {
  outline: 3px solid var(--brand);
  outline-offset: 2px;
}

.wrap { width: 100%; max-width: 1040px; margin: 0 auto; padding: 0 1rem; }
.muted { color: var(--text-muted); }
.preserve { white-space: pre-wrap; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: -999px; top: 0; background: var(--brand);
  color: var(--brand-ink); padding: .75rem 1rem; z-index: 100;
}
.skip-link:focus { left: 0; }

/* ---------- Donation strip ---------- */
.donate-bar {
  background: var(--accent); color: #fff;
  font-size: .85rem; padding: .5rem 0;
  padding-top: calc(.5rem + env(safe-area-inset-top));
}
.donate-inner {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  gap: .35rem .75rem; text-align: center;
}
.donate-text { opacity: .95; }
.donate-link {
  color: #fff; font-weight: 700; text-decoration: underline;
  text-underline-offset: 3px; white-space: nowrap;
  display: inline-flex; align-items: center; gap: .3rem;
  min-height: 32px; padding: 0 .2rem;
}
.donate-link:hover { text-decoration-thickness: 2px; }
@media (prefers-color-scheme: dark) {
  .donate-bar { background: #16283d; }
}

/* ---------- Header / footer ---------- */
.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 20;
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: .75rem; min-height: 60px; flex-wrap: wrap;
}
.brand { display: flex; align-items: center; gap: .6rem; text-decoration: none; color: var(--text); }
.brand-mark { width: 26px; height: 26px; flex: none; object-fit: contain; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { font-size: .98rem; }
.brand-text small { color: var(--text-muted); font-size: .75rem; }

.site-nav { display: flex; align-items: center; gap: .35rem; flex-wrap: wrap; }
.site-nav a {
  padding: .5rem .55rem; border-radius: var(--radius-sm);
  text-decoration: none; color: var(--text); font-size: .9rem;
}
.site-nav a[aria-current="page"] { background: var(--surface-2); font-weight: 600; }

.lang-switch {
  display: flex; align-items: center; gap: .15rem; margin-left: .25rem;
  border: 1px solid var(--border); border-radius: 999px; padding: .1rem;
  background: var(--surface);
}
.lang-switch a, .lang-switch .lang-current {
  padding: .35rem .6rem; border-radius: 999px; font-size: .82rem;
  font-weight: 600; text-decoration: none; white-space: nowrap;
  display: inline-flex; align-items: center; min-height: 34px;
}
.lang-switch a { color: var(--text-muted); }
.lang-switch a:hover { background: var(--surface-2); color: var(--text); }
.lang-switch .lang-current { background: var(--text); color: var(--bg); }
.site-nav a.btn-primary { color: var(--brand-ink); }

.site-footer {
  margin-top: 3rem; padding: 1.5rem 0 calc(2rem + env(safe-area-inset-bottom));
  border-top: 1px solid var(--border); background: var(--surface);
  font-size: .85rem; color: var(--text-muted);
}

main { padding-top: 1.25rem; padding-bottom: 2rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: .4rem; min-height: var(--tap); padding: .6rem 1rem;
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  background: var(--surface); color: var(--text);
  font: inherit; font-size: .95rem; font-weight: 600;
  text-decoration: none; cursor: pointer;
  transition: background .12s ease, border-color .12s ease;
}
.btn:hover { background: var(--surface-2); }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--brand); border-color: var(--brand); color: var(--brand-ink); }
.btn-primary:hover { background: var(--brand-dark); border-color: var(--brand-dark); }
.btn-danger { color: var(--bad); border-color: var(--bad); background: transparent; }
.btn-danger:hover { background: var(--bad-bg); }
.btn-lg { min-height: 52px; padding: .8rem 1.4rem; font-size: 1.02rem; width: 100%; }
.btn-sm { min-height: 38px; padding: .35rem .7rem; font-size: .85rem; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
@media (min-width: 640px) { .btn-lg { width: auto; } }

/* ---------- Flash messages ---------- */
.flashes { display: grid; gap: .5rem; margin-bottom: 1rem; }
.flash {
  padding: .75rem .9rem; border-radius: var(--radius-sm);
  border-left: 4px solid var(--accent); background: var(--surface); box-shadow: var(--shadow);
  font-size: .92rem;
}
.flash-error { border-left-color: var(--bad); background: var(--bad-bg); color: var(--bad); }
.flash-warning { border-left-color: var(--alert); background: var(--alert-bg); color: var(--alert); }
.flash-success { border-left-color: var(--good); background: var(--good-bg); color: var(--good); }

/* ---------- Hero + stats ---------- */
.hero { margin-bottom: 1.5rem; }
.hero h1 { font-size: 1.6rem; }
.lede { color: var(--text-muted); font-size: 1rem; }
.hero-actions { margin: 1rem 0; }

.stat-row {
  display: flex; gap: .6rem; flex-wrap: wrap; margin: 1rem 0 0; padding: 0;
}
.stat {
  flex: 1 1 130px; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: .7rem .85rem; box-shadow: var(--shadow);
}
.stat dt { font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; color: var(--text-muted); }
.stat dd { margin: .15rem 0 0; font-size: 1.5rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.stat-good { color: var(--good); }
.stat-bad { color: var(--bad); }

/* ---------- Search + filters ---------- */
.search-bar { display: flex; gap: .5rem; margin: 1.25rem 0 .75rem; }
.search-bar input {
  flex: 1; min-width: 0; min-height: var(--tap); padding: .6rem .8rem;
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  background: var(--surface); color: var(--text); font: inherit; font-size: 16px;
}

.filter-chips {
  display: flex; gap: .4rem; overflow-x: auto; padding-bottom: .5rem;
  margin-bottom: .75rem; scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.filter-chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none; padding: .45rem .8rem; border-radius: 999px;
  border: 1px solid var(--border); background: var(--surface);
  color: var(--text); text-decoration: none; font-size: .85rem; font-weight: 600;
  white-space: nowrap;
}
.chip-active { background: var(--text); color: var(--bg); border-color: var(--text); }
.result-count { font-size: .85rem; color: var(--text-muted); }

/* ---------- Person cards ---------- */
.person-grid {
  list-style: none; margin: 0; padding: 0;
  display: grid; gap: .85rem; grid-template-columns: 1fr;
}
@media (min-width: 560px) { .person-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .person-grid { grid-template-columns: repeat(3, 1fr); } }

.person-card {
  display: flex; gap: .85rem; height: 100%;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow);
  text-decoration: none; color: inherit;
}
.person-card:hover { border-color: var(--brand); }
.person-photo {
  position: relative; flex: none; width: 108px; background: var(--surface-2);
  display: flex; align-items: center; justify-content: center;
}
.person-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.no-photo { font-size: .72rem; color: var(--text-muted); text-align: center; padding: .5rem; }
.person-body { padding: .75rem .85rem .75rem 0; min-width: 0; }
.person-body h2 { font-size: 1.02rem; margin-bottom: .2rem; }
.person-meta, .person-location, .person-ref { margin: 0 0 .15rem; font-size: .84rem; color: var(--text-muted); }
.person-location { color: var(--text); }
.person-ref { font-size: .74rem; letter-spacing: .02em; }

.badge {
  position: absolute; left: 0; bottom: 0; right: 0;
  font-size: .68rem; font-weight: 700; text-align: center; padding: .2rem;
  text-transform: uppercase; letter-spacing: .03em;
}
.badge-good { background: var(--good); color: #fff; }

@media (min-width: 560px) {
  .person-card { flex-direction: column; }
  .person-photo { width: 100%; aspect-ratio: 4 / 3; }
  .person-body { padding: .75rem .85rem; }
}

.pagination {
  display: flex; align-items: center; justify-content: space-between;
  gap: .75rem; margin: 1.5rem 0;
}
.page-indicator { font-size: .85rem; color: var(--text-muted); }

/* ---------- Cards / panels ---------- */
.card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 1.25rem; box-shadow: var(--shadow);
}
.centered-card { max-width: 32rem; margin: 2rem auto; text-align: center; }
.login-card { text-align: left; }
.empty-state { text-align: center; }
.error-code { font-size: 3rem; font-weight: 800; margin: 0; color: var(--brand); }
.ref-badge {
  display: inline-block; padding: .2rem .5rem; border-radius: var(--radius-sm);
  background: var(--surface-2); font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: .05em;
}

/* ---------- Detail page ---------- */
.breadcrumb { font-size: .9rem; }
.detail-header { margin-bottom: 1rem; }
.detail-ref { font-size: .8rem; color: var(--text-muted); font-family: ui-monospace, Menlo, monospace; }
.banner {
  padding: .65rem .85rem; border-radius: var(--radius-sm); font-weight: 600; font-size: .92rem;
}
.banner-good { background: var(--good-bg); color: var(--good); }
.banner-alert { background: var(--alert-bg); color: var(--alert); }

.photo-strip {
  display: flex; gap: .6rem; overflow-x: auto; padding-bottom: .5rem;
  scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch;
}
.photo-strip img {
  flex: none; width: min(84vw, 380px); aspect-ratio: 3 / 4; object-fit: cover;
  border-radius: var(--radius); scroll-snap-align: center; background: var(--surface-2);
}

.detail-facts {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .75rem; margin: 1.25rem 0; padding: 0;
}
.detail-facts > div { min-width: 0; }
.detail-facts .full { grid-column: 1 / -1; }
.detail-facts dt { font-size: .74rem; text-transform: uppercase; letter-spacing: .04em; color: var(--text-muted); }
.detail-facts dd { margin: .1rem 0 0; }

.detail-section { margin: 1.5rem 0; }
.contact-list { list-style: none; padding: 0; margin: 0; display: grid; gap: .5rem; }
.contact-list a { display: inline-flex; min-height: var(--tap); align-items: center; }

.report-spam { margin-top: 2rem; font-size: .9rem; }
.report-spam summary { cursor: pointer; color: var(--text-muted); min-height: var(--tap); display: flex; align-items: center; }
.report-spam textarea { width: 100%; }

.prose { max-width: 42rem; }
.prose li { margin-bottom: .4rem; }
.prose h2 { margin-top: 1.75rem; }

/* ---------- Emergency contact block ---------- */
.emergency-block {
  border: 2px solid var(--bad); border-radius: var(--radius);
  padding: 1rem; margin: 1rem 0; background: var(--surface);
}
.emergency-block h2 { font-size: 1.05rem; margin-bottom: .25rem; }
.emergency-numbers { list-style: none; margin: .85rem 0 .5rem; padding: 0; display: grid; gap: .5rem; }
@media (min-width: 560px) { .emergency-numbers { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); } }
.emergency-call {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: .1rem; padding: .7rem .5rem; min-height: 60px;
  border-radius: var(--radius-sm); background: var(--bad); color: #fff;
  text-decoration: none; font-weight: 700;
}
.emergency-call:hover { filter: brightness(1.08); }
.emergency-number { font-size: 1.5rem; line-height: 1.1; letter-spacing: .02em; }
.emergency-label { font-size: .78rem; font-weight: 600; opacity: .92; }
.notice-urgent { border-left-color: var(--bad); color: var(--bad); }

/* ---------- Tips queue (admin) ---------- */
.tip-card.tip-urgent { border-left: 4px solid var(--bad); }
.tip-head { display: flex; flex-wrap: wrap; gap: .5rem; justify-content: space-between; align-items: center; }
.tip-person { font-weight: 700; margin: .5rem 0 .35rem; }
.tip-person .muted { font-weight: 400; font-size: .85rem; }
.tip-message {
  margin: 0 0 .75rem; padding: .7rem .85rem; border-left: 3px solid var(--border);
  background: var(--bg); border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

/* ---------- Notices, callouts and policy pages ---------- */
.notice-strip {
  font-size: .86rem; color: var(--text-muted);
  border-left: 3px solid var(--alert); background: var(--surface);
  padding: .6rem .8rem; border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin: 0 0 1rem;
}
.callout {
  background: var(--surface); border: 1px solid var(--border);
  border-left: 4px solid var(--accent);
  border-radius: var(--radius); padding: .9rem 1rem; margin: 1.25rem 0;
}
.callout > :last-child { margin-bottom: 0; }
.callout-alert { border-left-color: var(--alert); background: var(--alert-bg); color: var(--alert); }
.callout-alert a { color: inherit; }
.callout-alert h2 { font-size: 1rem; margin-top: 0; }
.disclosure ul { margin: .5rem 0; padding-left: 1.1rem; }
.disclosure li { margin-bottom: .35rem; font-size: .92rem; }
.disclosure .muted { font-size: .84rem; margin-bottom: 0; }

.policy-meta { font-size: .82rem; color: var(--text-muted); margin-top: -.35rem; }
.policy-footer {
  margin-top: 2rem; padding-top: 1rem; border-top: 1px solid var(--border);
  font-size: .9rem;
}

.footer-links { display: flex; flex-wrap: wrap; gap: .25rem 1rem; margin-top: .75rem; }
.footer-links a { color: var(--text-muted); font-size: .85rem; }

/* ---------- Forms ---------- */
.form-intro { margin-bottom: 1.25rem; }
.report-form { max-width: 42rem; }
fieldset {
  border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1rem; margin: 0 0 1.25rem; background: var(--surface);
}
legend { font-weight: 700; padding: 0 .4rem; font-size: 1rem; }

.field { margin-bottom: 1rem; }
/* Only the last field of a whole block loses its margin. Fields nested in a
   .field-row keep theirs, because on mobile that row stacks vertically. */
fieldset > .field:last-child,
form > .field:last-child { margin-bottom: 0; }
.field label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: .3rem; }
.field input, .field select, .field textarea, .report-spam textarea {
  width: 100%; min-height: var(--tap); padding: .6rem .75rem;
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  background: var(--bg); color: var(--text);
  font: inherit; font-size: 16px; /* 16px stops iOS zooming on focus */
}
.field textarea { min-height: 6rem; resize: vertical; }
.field input[aria-invalid="true"], .field textarea[aria-invalid="true"] { border-color: var(--bad); }
.hint { font-size: .82rem; color: var(--text-muted); margin: .3rem 0 0; }
.field-error { color: var(--bad); font-size: .84rem; font-weight: 600; margin: .3rem 0 0; }
.req { color: var(--bad); font-weight: 600; font-size: .74rem; text-transform: uppercase; }

.field-row { display: grid; gap: 0; }
@media (min-width: 560px) {
  .field-row { grid-template-columns: 1fr 1fr; gap: 0 1rem; }
}

.checkbox-field { display: flex; gap: .7rem; align-items: flex-start; padding: 0 .25rem 1rem; }
.checkbox-field input { width: 22px; height: 22px; min-height: 0; flex: none; margin-top: .15rem; }
.checkbox-field label { font-weight: 400; font-size: .9rem; }

.honeypot { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-actions { margin-bottom: 3rem; }

/* ---------- Uploader ---------- */
.upload-drop {
  display: flex; align-items: center; gap: .85rem; padding: 1.1rem;
  border: 2px dashed var(--border); border-radius: var(--radius);
  background: var(--bg); cursor: pointer; font-weight: 400;
}
.upload-drop:hover, .upload-drop.is-dragging { border-color: var(--brand); background: var(--surface-2); }
.upload-icon {
  flex: none; width: 40px; height: 40px; border-radius: 50%;
  background: var(--surface-2); border: 1px solid var(--border); position: relative;
}
.upload-icon::before, .upload-icon::after {
  content: ""; position: absolute; background: var(--text-muted);
}
.upload-icon::before { left: 50%; top: 11px; width: 2px; height: 18px; margin-left: -1px; }
.upload-icon::after { top: 50%; left: 11px; height: 2px; width: 18px; margin-top: -1px; }
.upload-text { display: flex; flex-direction: column; }
.upload-text small { color: var(--text-muted); font-size: .82rem; }

.upload-list { list-style: none; margin: .85rem 0 0; padding: 0; display: grid; gap: .5rem; }
.upload-item {
  display: flex; align-items: center; gap: .7rem; padding: .5rem;
  border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--bg);
}
.upload-item img {
  width: 52px; height: 52px; object-fit: cover; border-radius: var(--radius-sm); flex: none;
  background: var(--surface-2);
}
.upload-info { min-width: 0; flex: 1; }
.upload-name {
  display: block; font-size: .86rem; font-weight: 600;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.upload-status { font-size: .78rem; color: var(--text-muted); }
.upload-item.is-error { border-color: var(--bad); background: var(--bad-bg); }
.upload-item.is-error .upload-status { color: var(--bad); }
.upload-item.is-done .upload-status { color: var(--good); }
.upload-remove {
  flex: none; min-height: 38px; min-width: 38px; border-radius: var(--radius-sm);
  border: 1px solid var(--border); background: var(--surface); color: var(--text-muted);
  font-size: 1.1rem; line-height: 1; cursor: pointer;
}
.progress-track { height: 4px; border-radius: 2px; background: var(--surface-2); overflow: hidden; margin-top: .3rem; }
.progress-bar { height: 100%; background: var(--brand); width: 0; transition: width .2s ease; }

/* ---------- Admin ---------- */
body.admin { --bg: #f1f3f6; }
@media (prefers-color-scheme: dark) { body.admin { --bg: #0b0f14; } }

.inline-form { display: inline-flex; gap: .4rem; align-items: center; margin: 0; }
.admin-stats .stat dd { font-size: 1.3rem; }

.admin-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.admin-row {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.admin-row.row-flagged { border-left: 4px solid var(--bad); }
.admin-row-main { display: block; padding: .8rem .9rem; text-decoration: none; color: inherit; }
.admin-row-main:hover { background: var(--surface-2); border-radius: var(--radius); }
.admin-row-name { display: block; font-weight: 700; }
.admin-row-meta { display: block; font-size: .82rem; color: var(--text-muted); margin-bottom: .35rem; }

.tag-row { display: flex; flex-wrap: wrap; gap: .3rem; }
.tag {
  display: inline-block; padding: .15rem .5rem; border-radius: 999px;
  font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .03em;
  background: var(--surface-2); color: var(--text-muted);
}
.tag-good { background: var(--good-bg); color: var(--good); }
.tag-bad { background: var(--bad-bg); color: var(--bad); }
.tag-alert { background: var(--alert-bg); color: var(--alert); }

.panel {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1rem; margin-bottom: 1rem; box-shadow: var(--shadow);
}
.panel-contact { border-left: 4px solid var(--alert); }
.panel-credentials { border-left: 4px solid var(--good); background: var(--good-bg); }

/* Call-the-family block: sized for a volunteer holding a phone on site. */
.contact-actions { display: grid; gap: .5rem; margin: .75rem 0 1rem; }
@media (min-width: 560px) { .contact-actions { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); } }
.contact-primary {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: .15rem; padding: .8rem .6rem; min-height: 62px;
  border-radius: var(--radius-sm); background: var(--good); color: #fff;
  text-decoration: none; font-weight: 700; text-align: center;
}
.contact-primary:hover { filter: brightness(1.08); }
.contact-secondary { background: var(--accent); }
.contact-number { font-size: 1.15rem; line-height: 1.15; word-break: break-all; }
.contact-caption { font-size: .76rem; font-weight: 600; opacity: .92; }
.credential-block { display: grid; gap: .6rem; margin: .75rem 0; }
.credential-block dt { font-size: .74rem; text-transform: uppercase; letter-spacing: .04em; color: var(--text-muted); }
.credential-block dd { margin: .15rem 0 0; }
.credential-block code {
  display: inline-block; padding: .4rem .6rem; border-radius: var(--radius-sm);
  background: var(--surface); border: 1px solid var(--border);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .95rem;
  user-select: all; word-break: break-all;
}
.credential-secret { font-size: 1.05rem; letter-spacing: .04em; }
.volunteer-actions { margin-top: .5rem; }

/* --- Photo review ------------------------------------------------------- */
.review-grid {
  display: grid; gap: .85rem; grid-template-columns: 1fr;
}
@media (min-width: 560px) { .review-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .review-grid { grid-template-columns: repeat(3, 1fr); } }
.review-card {
  margin: 0; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow);
}
.review-card img {
  width: 100%; aspect-ratio: 3 / 4; object-fit: cover; display: block;
  background: var(--surface-2);
}
.review-card figcaption { padding: .7rem .8rem; display: grid; gap: .3rem; }
.photo-pending img { outline: 3px solid var(--alert); outline-offset: -3px; }
.photo-pending { opacity: .95; }

/* --- Rescue matches ----------------------------------------------------- */
.sync-bar { align-items: center; margin-bottom: 1rem; }
.sync-history summary { cursor: pointer; font-weight: 600; }
.match-card { border-left: 4px solid var(--accent); }
.match-score { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; margin-bottom: .75rem; }
.match-score .muted { font-size: .82rem; }
.match-columns { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 720px) { .match-columns { grid-template-columns: 1fr 1fr; } }
.match-side {
  background: var(--bg); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: .8rem;
}
.match-side h3 {
  margin: 0 0 .4rem; font-size: .74rem; text-transform: uppercase;
  letter-spacing: .05em; color: var(--text-muted);
}
.match-name { font-weight: 700; font-size: 1.05rem; margin-bottom: .5rem; }
.match-name .muted { font-weight: 400; font-size: .9rem; display: block; }
.match-side .detail-facts { margin: 0; gap: .5rem; }
.panel-flags { border-left: 4px solid var(--bad); }
.panel-danger { border-left: 4px solid var(--bad); }
.button-row { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.delete-form { flex-wrap: wrap; }
.reason-input {
  min-height: var(--tap); padding: .5rem .7rem; border: 1px solid var(--border);
  border-radius: var(--radius-sm); background: var(--bg); color: var(--text);
  font: inherit; font-size: 16px; min-width: 12rem; flex: 1;
}
.purge-block { margin-top: 1rem; font-size: .9rem; }
.purge-block summary { cursor: pointer; color: var(--bad); font-weight: 600; min-height: var(--tap); display: flex; align-items: center; }

.admin-photos { display: flex; gap: .6rem; overflow-x: auto; padding-bottom: .5rem; }
.admin-photos figure { margin: 0; flex: none; width: 180px; }
.admin-photos img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: var(--radius); }
.admin-photos figcaption { margin-top: .35rem; }

.flag-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .4rem; font-size: .88rem; }
.flag-list li { padding-bottom: .4rem; border-bottom: 1px solid var(--border); }

.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.audit-table { width: 100%; border-collapse: collapse; font-size: .85rem; background: var(--surface); }
.audit-table th, .audit-table td { padding: .5rem .6rem; text-align: left; border-bottom: 1px solid var(--border); white-space: nowrap; }
.audit-table th { background: var(--surface-2); font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; }
.maintenance { margin-top: 2rem; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
