:root {
  color-scheme: dark;
  --bg: #071013;
  --panel: rgba(13, 27, 32, 0.86);
  --panel-strong: rgba(19, 38, 44, 0.96);
  --line: rgba(146, 232, 214, 0.2);
  --line-strong: rgba(146, 232, 214, 0.42);
  --text: #edf7f5;
  --muted: #91a9a6;
  --teal: #36f0c3;
  --amber: #ffbf4d;
  --red: #ff6575;
  --blue: #58a6ff;
  --green: #75e186;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
}

* { box-sizing: border-box; }

body {
  min-height: 100vh;
  margin: 0;
  background:
    radial-gradient(circle at 16% 18%, rgba(54, 240, 195, 0.16), transparent 26%),
    radial-gradient(circle at 84% 12%, rgba(88, 166, 255, 0.15), transparent 28%),
    linear-gradient(145deg, #071013 0%, #0b191e 48%, #101717 100%);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a { color: inherit; }

button,
input,
select,
textarea {
  font: inherit;
}

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

.command-shell {
  width: min(1680px, 100%);
  margin: 0 auto;
  padding: 22px;
}

.command-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  min-height: 74px;
}

.command-topbar h1,
.hero-panel h2,
.panel-heading h2 {
  margin: 0;
  letter-spacing: 0;
}

.command-topbar h1 {
  font-size: 34px;
  line-height: 1;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--teal);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.top-actions {
  display: flex;
  gap: 10px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
}

.nav-pill-button {
  border: 0;
  cursor: pointer;
  font: inherit;
}

.landing-shell {
  max-width: 1240px;
}

.landing-topbar {
  margin-bottom: 14px;
}

.landing-subtitle {
  margin: 8px 0 0;
  color: var(--muted);
  max-width: 52ch;
}

.landing-hero-panel {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 18px;
  margin-bottom: 18px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: linear-gradient(180deg, rgba(16, 34, 40, 0.96), rgba(11, 25, 30, 0.98));
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.22);
}

.landing-hero-copy {
  display: grid;
  gap: 10px;
  align-content: start;
}

.landing-hero-copy h2 {
  margin: 0;
  font-size: 34px;
  line-height: 1.08;
}

.landing-hero-copy p:last-child {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  max-width: 60ch;
}

.landing-hero-stats {
  display: grid;
  gap: 12px;
}

.landing-stat-card {
  display: grid;
  gap: 4px;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid rgba(146, 232, 214, 0.14);
  background: rgba(255, 255, 255, 0.04);
}

.landing-stat-card span {
  color: var(--teal);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.landing-stat-card small,
.landing-panel-intro {
  color: var(--muted);
}

.landing-panel-intro {
  margin: 0 0 14px;
  font-size: 14px;
}

.landing-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.landing-panel {
  min-width: 0;
}

.landing-links-panel {
  grid-column: 1 / -1;
}

.landing-link-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.landing-link-card {
  text-decoration: none;
}

.single-action {
  grid-template-columns: 1fr;
}

.staffing-schedule-toolbar {
  margin-bottom: 14px;
  align-items: stretch;
}

.staffing-rule-box {
  display: grid;
  gap: 4px;
  min-width: 280px;
}

.staffing-schedule-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 14px;
}

.staffing-shift-card {
  display: grid;
  gap: 12px;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
}

.staffing-shift-card.covered {
  border-color: rgba(54, 240, 195, 0.22);
}

.staffing-shift-card.uncovered {
  border-color: rgba(255, 101, 117, 0.24);
}

.staffing-assigned-list,
.staffing-errors {
  display: grid;
  gap: 10px;
}

.staffing-member-pill {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(3, 14, 17, 0.42);
}

.staffing-member-pill small,
.staffing-errors small,
.staffing-ok small {
  color: var(--muted);
}

.staffing-add-row {
  display: grid;
  gap: 10px;
}

.staffing-ok {
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(54, 240, 195, 0.08);
  border: 1px solid rgba(54, 240, 195, 0.14);
}

.tenant-module-pills {
  display: flex;
  gap: 10px;
  margin-top: 14px;
  padding: 5px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  overflow-x: auto;
}

.tenant-dashboard .module-page-only {
  display: none !important;
}

.nav-pill {
  min-width: 108px;
  padding: 11px 16px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 800;
  text-align: center;
  text-decoration: none;
}

.nav-pill.active {
  color: #041211;
  background: var(--teal);
}

.command-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr 0.8fr;
  gap: 16px;
  margin-top: 18px;
}

.hero-panel,
.tenant-filter-panel,
.map-panel,
.queue-panel,
.ops-panel,
.triage-outcomes-panel,
.intel-panel,
.dispatch-board,
.task-compose,
.triage-panel,
.public-report-panel,
.public-report-aside,
.tenant-directory,
.tenant-detail,
.membership-panel,
.boundary-panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.hero-panel {
  grid-column: span 2;
  display: flex;
  justify-content: space-between;
  gap: 24px;
  min-height: 230px;
  padding: 28px;
  overflow: hidden;
  position: relative;
}

.hero-panel::after {
  content: "";
  position: absolute;
  inset: auto -12% -44% 30%;
  height: 170px;
  background: linear-gradient(90deg, transparent, rgba(54, 240, 195, 0.18), transparent);
  transform: rotate(-8deg);
}

.hero-copy {
  max-width: 780px;
  position: relative;
  z-index: 1;
}

.hero-copy h2 {
  max-width: 820px;
  font-size: 40px;
  line-height: 1.04;
}

.hero-note {
  max-width: 640px;
  margin: 20px 0 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.6;
}

.mission-clock {
  align-self: flex-start;
  min-width: 168px;
  padding: 18px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: rgba(3, 14, 17, 0.64);
  text-align: right;
  position: relative;
  z-index: 1;
}

.mission-clock span {
  display: block;
  font-variant-numeric: tabular-nums;
  font-size: 28px;
  font-weight: 900;
}

.mission-clock small,
.metric-tile small,
.queue-item small,
.capacity-row small,
.dispatch-card small,
.context-box span,
.empty-state {
  color: var(--muted);
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.tenant-filter-panel {
  display: grid;
  gap: 12px;
  padding: 18px;
}

.tenant-filter-panel label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.tenant-filter-panel select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  color: var(--text);
  background: rgba(3, 14, 17, 0.82);
}

.tenant-filter-summary {
  min-height: 74px;
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.tenant-filter-summary strong,
.tenant-filter-summary span {
  display: block;
}

.tenant-filter-summary span {
  margin-top: 7px;
  color: var(--muted);
  line-height: 1.45;
}

.metric-tile {
  min-height: 109px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(8, 21, 26, 0.82);
}

.metric-tile span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.metric-tile strong {
  display: block;
  margin: 10px 0 4px;
  color: var(--teal);
  font-size: 38px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.metric-tile.alert {
  border-color: rgba(255, 101, 117, 0.48);
  background: linear-gradient(180deg, rgba(59, 15, 23, 0.92), rgba(36, 12, 17, 0.92));
  box-shadow: 0 0 0 1px rgba(255, 101, 117, 0.16), 0 18px 40px rgba(0, 0, 0, 0.22);
}

.metric-tile.alert strong,
.metric-tile.alert span {
  color: #ffd3d8;
}

.map-panel {
  grid-column: span 2;
  min-height: 520px;
  padding: 18px;
}

.queue-panel,
.ops-panel,
.triage-outcomes-panel,
.intel-panel,
.dispatch-board,
.task-compose,
.triage-panel,
.public-report-panel,
.public-report-aside,
.tenant-directory,
.tenant-detail,
.membership-panel,
.boundary-panel {
  padding: 18px;
}

.panel-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.panel-heading h2 {
  font-size: 21px;
}

.status-chip {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid rgba(54, 240, 195, 0.36);
  border-radius: 999px;
  color: var(--teal);
  background: rgba(54, 240, 195, 0.08);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.text-link {
  color: var(--teal);
  font-size: 14px;
  font-weight: 800;
  text-decoration: none;
}

.city-map {
  height: 420px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(0deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(145deg, rgba(5, 20, 24, 0.94), rgba(12, 35, 41, 0.86));
  background-size: 42px 42px, 42px 42px, auto;
  overflow: hidden;
  position: relative;
}

.river-line {
  position: absolute;
  left: 12%;
  top: 6%;
  width: 70%;
  height: 96%;
  border-left: 12px solid rgba(88, 166, 255, 0.18);
  border-radius: 44% 0 0 54%;
  transform: rotate(18deg);
}

.map-gridline {
  position: absolute;
  background: rgba(54, 240, 195, 0.13);
}

.map-gridline.vertical {
  top: 0;
  bottom: 0;
  width: 1px;
}

.map-gridline.horizontal {
  left: 0;
  right: 0;
  height: 1px;
}

.map-gridline.a { left: 33%; top: 35%; }
.map-gridline.b { left: 68%; top: 66%; }

.map-pin {
  position: absolute;
  width: 28px;
  height: 28px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  transform: translate(-50%, -50%);
  cursor: pointer;
}

.map-pin::before,
.map-pin::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
}

.map-pin::before {
  border: 1px solid currentColor;
  animation: pulse 2.2s infinite;
}

.map-pin::after {
  inset: 8px;
  background: currentColor;
  box-shadow: 0 0 18px currentColor;
}

.map-pin.critical { color: var(--red); }
.map-pin.high { color: var(--amber); }
.map-pin.medium { color: var(--teal); }
.map-pin.enc-active { color: var(--green); }
.map-pin.enc-dismantled { color: #8e9aa3; }
.map-pin.worker { color: var(--blue); }
.map-pin.worker::after {
  inset: 7px;
  border-radius: 3px;
}

.map-readout {
  position: absolute;
  right: 18px;
  bottom: 18px;
  width: min(320px, calc(100% - 36px));
  padding: 16px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: rgba(3, 14, 17, 0.82);
}

.map-readout strong,
.map-readout span,
.map-readout small {
  display: block;
}

.map-readout span { margin-top: 6px; color: var(--muted); }
.map-readout small { margin-top: 10px; color: var(--teal); }

.queue-list,
.capacity-stack,
.context-stack {
  display: grid;
  gap: 10px;
}

.queue-item,
.capacity-row,
.dispatch-card,
.context-box {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.queue-item {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  padding: 14px;
  border-left: 4px solid var(--teal);
}

.queue-item.critical { border-left-color: var(--red); }
.queue-item.high { border-left-color: var(--amber); }

.queue-item span,
.dispatch-card span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.incident-attention-chip,
.incident-live-chip,
.staff-live-chip {
  position: relative;
}

.incident-attention-chip::after,
.incident-live-chip::after,
.staff-live-chip::after {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 999px;
  border: 1px solid currentColor;
  opacity: 0.28;
  animation: dashboardPulse 1.8s ease-out infinite;
}

.incident-attention-chip,
.incident-live-chip {
  color: #ffd7dc;
  background: rgba(255, 101, 117, 0.18);
  border-color: rgba(255, 101, 117, 0.46);
}

.staff-live-chip {
  color: #d8fff5;
  background: rgba(54, 240, 195, 0.15);
  border-color: rgba(54, 240, 195, 0.36);
}

.queue-item strong,
.dispatch-card strong,
.context-box strong {
  display: block;
  line-height: 1.35;
}

.capacity-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 120px 44px;
  align-items: center;
  gap: 12px;
  padding: 14px;
}

.capacity-row span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.capacity-meter {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
}

.capacity-meter span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--teal), var(--green));
}

.intel-panel {
  grid-column: span 3;
}

.triage-outcomes-panel {
  display: grid;
  gap: 12px;
}

.triage-outcomes-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.triage-outcome {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.triage-outcome strong,
.triage-outcome span,
.triage-outcome small {
  display: block;
}

.triage-outcome strong {
  color: var(--teal);
  font-size: 30px;
  line-height: 1;
}

.triage-outcome span {
  margin-top: 8px;
  font-size: 13px;
  text-transform: uppercase;
  color: var(--muted);
}

.triage-outcome small {
  margin-top: 6px;
  color: var(--muted);
}

.triage-outcome.dismiss strong { color: var(--red); }
.triage-outcome.monitor strong { color: var(--amber); }

.intel-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.intel-grid div {
  min-height: 112px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.intel-grid strong,
.intel-grid span {
  display: block;
}

.intel-grid span {
  margin-top: 10px;
  color: var(--muted);
  line-height: 1.5;
}

.dispatch-grid,
.tenant-grid {
  display: grid;
  gap: 16px;
  margin-top: 18px;
}

.dispatch-grid {
  grid-template-columns: minmax(0, 1fr) 390px;
}

.triage-panel {
  grid-column: 1 / -1;
}

.tenant-grid {
  grid-template-columns: 360px minmax(0, 1fr) 430px;
}

.tenant-tasks-panel {
  grid-column: 1 / span 2;
  grid-row: 1;
}

.tenant-map-panel {
  grid-column: 3;
  grid-row: 1;
}

.tenant-map-panel .city-map {
  height: 360px;
}

.tenant-housing-panel {
  grid-column: 3;
}

.public-report-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 430px;
  gap: 16px;
  margin-top: 18px;
}

.public-shell {
  width: min(1220px, 100%);
}

.dispatch-columns {
  display: grid;
  grid-template-columns: repeat(4, minmax(190px, 1fr));
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 4px;
}

.dispatch-context-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 14px;
}

.dispatch-context-row label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.dispatch-context-row select,
.dispatch-context-row input {
  width: 100%;
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  background: rgba(3, 14, 17, 0.82);
  padding: 8px 10px;
}

.dispatch-session-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.dispatch-column {
  min-height: 620px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(2, 10, 13, 0.32);
}

.dispatch-column h3 {
  margin: 0 0 12px;
  font-size: 14px;
  text-transform: uppercase;
  color: var(--muted);
}

.dispatch-card {
  display: grid;
  gap: 9px;
  margin-bottom: 10px;
  padding: 14px;
  border-top: 4px solid var(--teal);
}

.dispatch-card.critical { border-top-color: var(--red); }
.dispatch-card.high { border-top-color: var(--amber); }

.dispatch-source {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}

.dispatch-card button,
.btn {
  min-height: 40px;
  border: 0;
  border-radius: 8px;
  color: #041211;
  background: var(--teal);
  font-weight: 900;
  cursor: pointer;
}

.dispatch-card button {
  margin-top: 4px;
}

.task-compose {
  position: sticky;
  top: 18px;
  align-self: start;
}

.tenant-directory,
.membership-panel {
  align-self: start;
}

.tenant-detail {
  min-height: 610px;
}

.boundary-panel {
  grid-column: span 3;
}

.outreach3-form {
  display: grid;
  gap: 12px;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.outreach3-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.outreach3-form input,
.outreach3-form select,
.outreach3-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 11px 12px;
  color: var(--text);
  background: rgba(3, 14, 17, 0.82);
}

.outreach3-form textarea {
  resize: vertical;
}

.form-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.btn.ghost {
  color: var(--text);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line);
}

.btn.ghost.danger {
  color: #ffdfe3;
  border-color: rgba(255, 101, 117, 0.4);
  background: rgba(255, 101, 117, 0.12);
}

.form-status {
  min-height: 20px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}

.form-status[data-kind="success"] { color: var(--green); }
.form-status[data-kind="error"] { color: var(--red); }

.context-stack {
  margin-top: 16px;
}

.context-box {
  min-height: 74px;
  padding: 13px;
}

.context-box span {
  display: block;
  margin-top: 7px;
  line-height: 1.45;
}

.tenant-list,
.member-list,
.settings-grid,
.boundary-grid {
  display: grid;
  gap: 10px;
}

.tenant-card,
.member-row,
.boundary-grid div,
.toggle-row {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.tenant-card {
  display: grid;
  gap: 8px;
  width: 100%;
  padding: 14px;
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.tenant-card.active {
  border-color: var(--teal);
  background: rgba(54, 240, 195, 0.1);
  box-shadow: 0 0 0 1px rgba(54, 240, 195, 0.18), 0 12px 28px rgba(0, 0, 0, 0.18);
}

.tenant-card span,
.tenant-card small,
.member-row span,
.boundary-grid span {
  color: var(--muted);
}

.tenant-card span {
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.settings-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.toggle-row {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 12px;
  color: var(--text) !important;
}

.toggle-row input {
  width: auto;
}

.member-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 13px;
}

.member-row strong,
.member-row span,
.boundary-grid strong,
.boundary-grid span {
  display: block;
}

.member-row button {
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.08);
  cursor: pointer;
}

.inline-member-form {
  margin-top: 14px;
}

.boundary-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.boundary-grid div {
  min-height: 118px;
  padding: 16px;
}

.boundary-grid span {
  margin-top: 10px;
  line-height: 1.5;
}

.demo-reset-box {
  display: grid;
  gap: 10px;
  margin-top: 16px;
  padding: 16px;
  border: 1px solid rgba(255, 101, 117, 0.22);
  border-radius: 8px;
  background: rgba(255, 101, 117, 0.08);
}

.demo-reset-box strong,
.demo-reset-box span {
  display: block;
}

.demo-reset-box span {
  color: var(--muted);
  line-height: 1.5;
}

.public-report-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 12px;
}

.public-report-card {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.public-report-card span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.public-report-card strong {
  display: block;
}

.public-report-card p,
.public-report-aside p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.duplicate-hint {
  display: block;
  color: var(--muted);
  font-size: 12px;
}

.public-report-card textarea,
.public-report-card input[type="text"] {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 11px;
  color: var(--text);
  background: rgba(3, 14, 17, 0.82);
}

.public-report-actions {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr) 170px;
  gap: 10px;
}

.public-report-actions select,
.public-report-actions button {
  min-height: 40px;
  border-radius: 8px;
}

.public-report-actions select {
  min-width: 0;
  border: 1px solid var(--line);
  color: var(--text);
  background: rgba(3, 14, 17, 0.82);
}

.public-report-actions button {
  border: 0;
  color: #041211;
  background: var(--teal);
  font-weight: 900;
  cursor: pointer;
}

.public-report-actions.triage-buttons {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.public-report-actions .btn.ghost {
  color: var(--text);
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--line);
}

.public-report-actions .btn.ghost.danger {
  color: #ffdfe3;
  border-color: rgba(255, 101, 117, 0.4);
  background: rgba(255, 101, 117, 0.12);
}

.public-report-aside {
  display: grid;
  align-content: start;
  gap: 16px;
}

.city-briefing-panel {
  margin-top: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-strong);
  box-shadow: var(--shadow);
  padding: 18px;
}

.city-briefing-content {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  padding: 14px;
  color: var(--muted);
}

.briefing-header strong,
.briefing-header span {
  display: block;
}

.briefing-header span {
  margin-top: 6px;
  color: var(--muted);
}

.briefing-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 12px;
}

.briefing-grid article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(3, 14, 17, 0.62);
  padding: 12px;
}

.briefing-grid h3 {
  margin: 0 0 8px;
  font-size: 14px;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--teal);
}

.briefing-grid p {
  margin: 0 0 6px;
  color: var(--text);
  line-height: 1.4;
}

.triage-history-list {
  display: grid;
  gap: 10px;
}

.triage-history-item {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
}

.triage-history-item span,
.triage-history-item small {
  color: var(--muted);
  font-size: 12px;
}

.interaction-badge {
  display: inline-flex;
  align-items: center;
  min-height: 20px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  margin-right: 6px;
  font-size: 11px;
  text-transform: uppercase;
  color: var(--text);
  background: rgba(255, 255, 255, 0.08);
}

.interaction-badge.shared_operational {
  border-color: rgba(54, 240, 195, 0.36);
  background: rgba(54, 240, 195, 0.12);
}

.interaction-badge.private_org {
  border-color: rgba(88, 166, 255, 0.36);
  background: rgba(88, 166, 255, 0.12);
}

.interaction-badge.restricted_sensitive {
  border-color: rgba(255, 101, 117, 0.42);
  background: rgba(255, 101, 117, 0.16);
}

.triage-history-item strong,
.triage-history-item span,
.triage-history-item small {
  display: block;
}

.triage-history-item p {
  margin: 8px 0 0;
  color: var(--text);
  font-size: 13px;
}

.triage-history-actions {
  display: grid;
  gap: 8px;
  min-width: 180px;
}

.triage-history-actions select {
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--text);
  background: rgba(3, 14, 17, 0.82);
  padding: 6px 8px;
}

.triage-history-actions button {
  min-height: 34px;
  border: 0;
  border-radius: 8px;
  color: #041211;
  background: var(--teal);
  font-weight: 800;
  cursor: pointer;
}

.public-boundary {
  grid-template-columns: 1fr;
}

.empty-state {
  margin: 0;
  padding: 12px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  font-size: 13px;
}

@keyframes pulse {
  0% { transform: scale(0.8); opacity: 0.8; }
  100% { transform: scale(2.25); opacity: 0; }
}

@keyframes dashboardPulse {
  0% { transform: scale(0.98); opacity: 0.34; }
  70% { transform: scale(1.08); opacity: 0; }
  100% { transform: scale(1.08); opacity: 0; }
}

@media (max-width: 1180px) {
  .command-grid,
  .dispatch-grid,
  .tenant-grid,
  .public-report-grid {
    grid-template-columns: 1fr;
  }

  .hero-panel,
  .map-panel,
  .intel-panel,
  .boundary-panel {
    grid-column: auto;
  }

  .metric-grid,
  .intel-grid,
  .boundary-grid,
  .triage-outcomes-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .task-compose {
    position: static;
  }
}

@media (max-width: 720px) {
  .command-shell {
    padding: 14px;
  }

  .command-topbar,
  .hero-panel,
  .panel-heading {
    flex-direction: column;
    align-items: stretch;
  }

  .command-topbar h1 {
    font-size: 28px;
  }

  .top-actions,
  .form-actions,
  .form-row,
  .metric-grid,
  .intel-grid,
  .settings-grid,
  .boundary-grid {
    grid-template-columns: 1fr;
  }

  .top-actions {
    display: grid;
    border-radius: 8px;
  }

  .nav-pill {
    border-radius: 8px;
  }

  .hero-copy h2 {
    font-size: 30px;
  }

  .mission-clock {
    width: 100%;
    text-align: left;
  }

  .city-map {
    height: 360px;
  }

  .capacity-row {
    grid-template-columns: 1fr;
  }

  .public-report-actions {
    grid-template-columns: 1fr;
  }

  .briefing-grid {
    grid-template-columns: 1fr;
  }

  .triage-history-item {
    flex-direction: column;
  }

  .triage-history-actions {
    min-width: 0;
    width: 100%;
  }
}

@media print {
  body {
    background: #fff;
    color: #111;
  }

  .command-topbar,
  .public-report-grid,
  #printCityBriefingBtn {
    display: none !important;
  }

  .command-shell.public-shell {
    width: 100%;
    padding: 0;
  }

  .city-briefing-panel {
    margin-top: 0;
    border: 0;
    box-shadow: none;
    background: #fff;
    padding: 0;
  }

  .city-briefing-content,
  .briefing-grid article {
    border: 1px solid #cfcfcf;
    background: #fff;
    color: #111;
  }

  .briefing-grid h3 {
    color: #111;
  }

  .briefing-header span,
  .briefing-grid p {
    color: #111;
  }
}

.surface-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 16px;
  margin-top: 18px;
}

.surface-hero {
  grid-column: 1 / -1;
}

.surface-panel,
.surface-grid > section,
.surface-grid > aside {
  min-width: 0;
}

.full-span {
  grid-column: 1 / -1;
}

.surface-metric-strip,
.surface-card-grid,
.task-list-grid {
  display: grid;
  gap: 12px;
}

.surface-metric-strip {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.surface-card-grid,
.task-list-grid {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.info-callout {
  margin-top: 18px;
  padding: 14px 16px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: rgba(255,255,255,0.04);
  color: var(--text);
}

.info-card,
.history-card {
  display: grid;
  gap: 8px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255,255,255,0.03);
}

.info-card strong,
.history-card strong {
  font-size: 15px;
}

.info-card span,
.history-card span,
.info-card small,
.history-card small {
  color: var(--muted);
  line-height: 1.45;
}

.member-list {
  display: grid;
  gap: 12px;
}

.surface-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.surface-actions button,
.stacked-actions .btn,
.stacked-actions button,
.dispatch-card button {
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  padding: 10px 14px;
  background: rgba(255,255,255,0.04);
  color: var(--text);
  cursor: pointer;
}

.surface-actions button:hover,
.dispatch-card button:hover {
  border-color: var(--teal);
}

.surface-actions .danger,
.stacked-actions .danger {
  border-color: rgba(255,101,117,0.45);
}

.public-surface-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
  margin-top: 18px;
}

.surface-link-card {
  display: grid;
  gap: 10px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--panel);
  text-decoration: none;
  box-shadow: var(--shadow);
}

.surface-link-card strong {
  font-size: 16px;
}

.surface-link-card span,
.surface-link-card small {
  color: var(--muted);
  line-height: 1.45;
}

@media (max-width: 1100px) {
  .landing-hero-panel,
  .landing-grid,
  .landing-link-grid,
  .staffing-schedule-grid,
  .surface-grid {
    grid-template-columns: 1fr;
  }

  .surface-metric-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  .surface-metric-strip,
  .surface-card-grid,
  .task-list-grid,
  .public-surface-grid {
    grid-template-columns: 1fr;
  }
}


.demo-steps {
  display: grid;
  gap: 12px;
}

.demo-step {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 12px;
  align-items: start;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255,255,255,0.03);
}

.demo-step-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 999px;
  background: rgba(76, 201, 240, 0.14);
  border: 1px solid rgba(76, 201, 240, 0.35);
  font-weight: 700;
}


.task-detail-panel {
  margin-top: 14px;
}

.detail-stack {
  display: grid;
  gap: 10px;
}

.task-card.active {
  border-left: 3px solid var(--teal);
  padding-left: 10px;
}

.compact-list {
  max-height: 260px;
  overflow: auto;
}


.tenant-dashboard .tenant-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  align-items: start;
}

.tenant-dashboard .tenant-grid > .boundary-panel,
.tenant-dashboard .tenant-grid > .membership-panel {
  min-width: 0;
  height: 100%;
}

.tenant-dashboard .tenant-map-panel,
.tenant-dashboard .tenant-tasks-panel,
.tenant-dashboard .boundary-panel:has(#tenantTaskColumn),
.tenant-dashboard .boundary-panel:has(#tenantOpsMap) {
  grid-column: 1 / -1;
}

.tenant-dashboard .dashboard-summary-panel {
  grid-column: 1 / -1;
}

.tenant-dashboard .dashboard-incidents-panel {
  grid-column: 1;
}

.tenant-dashboard .dashboard-roster-panel {
  grid-column: 2;
}

.tenant-dashboard .dashboard-metrics-panel,
.tenant-dashboard .dashboard-shared-beds-panel,
.tenant-dashboard .dashboard-encampments-panel,
.tenant-dashboard .dashboard-clients-panel {
  align-self: stretch;
}

.tenant-dashboard .dashboard-roster-panel .member-list,
.tenant-dashboard .dashboard-incidents-panel .triage-history-list {
  gap: 12px;
}

.dashboard-roster-card {
  min-height: 88px;
  padding: 16px;
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(13, 28, 34, 0.92), rgba(8, 20, 25, 0.9));
}

.dashboard-roster-card strong {
  margin-bottom: 4px;
}

.incident-card {
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(28, 16, 22, 0.9), rgba(18, 12, 17, 0.94));
  border-color: rgba(255, 101, 117, 0.28);
}

.incident-card strong {
  color: #fff1f3;
}

.incident-card small,
.incident-card span {
  color: #f1c8cf;
}

.incident-card-critical,
.incident-card-high {
  box-shadow: 0 0 0 1px rgba(255, 101, 117, 0.18), 0 12px 30px rgba(0, 0, 0, 0.24);
}

.incident-card-critical {
  border-color: rgba(255, 101, 117, 0.54);
}

.incident-card-high {
  border-color: rgba(255, 191, 77, 0.45);
  background: linear-gradient(180deg, rgba(39, 25, 13, 0.9), rgba(24, 18, 12, 0.94));
}

.incident-card-high strong {
  color: #fff3df;
}

.incident-card-high small,
.incident-card-high span {
  color: #ffdba7;
}

.dashboard-map-panel .city-map {
  min-height: 420px;
}

.dashboard-summary-panel .surface-metric-strip {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

@media (max-width: 1180px) {
  .tenant-dashboard .dashboard-incidents-panel,
  .tenant-dashboard .dashboard-roster-panel,
  .tenant-dashboard .dashboard-metrics-panel,
  .tenant-dashboard .dashboard-shared-beds-panel,
  .tenant-dashboard .dashboard-encampments-panel,
  .tenant-dashboard .dashboard-clients-panel {
    grid-column: auto;
  }

  .dashboard-summary-panel .surface-metric-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.tenant-staffing-module .member-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
}

.tenant-staffing-module .member-row {
  display: grid;
  gap: 10px;
  align-content: start;
  padding: 18px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.03);
}

.tenant-staffing-module .member-row .stacked-actions {
  justify-content: flex-start;
}

.tenant-staffing-module .inline-member-form,
.tenant-tasks-module .inline-member-form,
.tenant-housing-module .outreach3-form,
.tenant-wards-module .outreach3-form {
  margin-top: 16px;
}

.tenant-tasks-module .tenant-grid,
.tenant-housing-module .tenant-grid,
.tenant-staffing-module .tenant-grid,
.tenant-wards-module .tenant-grid {
  grid-template-columns: 1fr;
}

.task-card .surface-actions {
  margin-top: 10px;
}

.task-create-source-block {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px;
  background: rgba(255,255,255,0.03);
}

.compact-heading h3 {
  margin: 0;
  font-size: 1rem;
}

.helper-text {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 0.92rem;
}


.member-card-head {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 14px;
  align-items: start;
}

.member-avatar {
  width: 72px;
  height: 88px;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255,255,255,0.06);
}

.member-avatar.placeholder {
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 1.5rem;
}

.member-card-actions {
  align-self: start;
}

.member-edit-form {
  grid-column: 1 / -1;
  margin-top: 6px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.inline-actions {
  margin-top: 8px;
}

.member-row[data-member-status="inactive"] { opacity: 0.72; }


.operational-spine-panel {
  gap: 12px;
}

.spine-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 10px;
}

.spine-card {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px;
  background: rgba(255,255,255,0.03);
}

.task-client-create-box {
  display: grid;
  gap: 10px;
  margin-top: 12px;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid rgba(88, 166, 255, 0.24);
  background: rgba(88, 166, 255, 0.07);
}

.client-picker-results {
  display: grid;
  gap: 8px;
  margin: 10px 0 0;
  max-height: 260px;
  overflow-y: auto;
}

.client-picker-option {
  display: grid;
  gap: 3px;
  width: 100%;
  padding: 10px 12px;
  text-align: left;
  border-radius: 12px;
  border: 1px solid rgba(146, 232, 214, 0.14);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
}

.client-picker-option.selected {
  border-color: rgba(54, 240, 195, 0.42);
  background: rgba(54, 240, 195, 0.1);
}

.client-picker-option strong {
  color: #f4fbfa;
}

.compact-empty {
  margin: 0;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px dashed rgba(146, 232, 214, 0.18);
}

.spine-card .compact-list {
  margin-top: 10px;
}

.chain-story-card {
  display: grid;
  gap: 12px;
  padding: 16px;
  border-radius: 16px;
  border: 1px solid rgba(86, 130, 214, 0.22);
  background: linear-gradient(180deg, rgba(17, 28, 48, 0.9), rgba(20, 34, 58, 0.96));
}

.chain-story-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.chain-node {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 700;
  border: 1px solid rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.06);
  color: #e7eefc;
}

.chain-node.complete {
  background: rgba(48, 123, 255, 0.18);
  border-color: rgba(94, 156, 255, 0.38);
  color: #f3f7ff;
}

.chain-node.pending {
  background: rgba(255,255,255,0.04);
  color: #c3d1eb;
}

.chain-arrow {
  color: #8fb1f4;
  font-weight: 700;
}

.chain-story-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  color: #d7e2f5;
  font-size: 0.88rem;
}

.chain-story-context {
  color: #c8d5eb;
  font-size: 0.9rem;
}

@media (max-width: 900px) {
  .spine-grid {
    grid-template-columns: 1fr;
  }
}


.outreach2-ward-grid {
  display:grid;
  grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
  gap:16px;
}

.ward-tile {
  display:block;
  text-decoration:none;
  color:#122033;
  border:1px solid #c8d5ea;
  border-radius:16px;
  padding:18px;
  background:linear-gradient(180deg, #ffffff 0%, #f5f8fd 100%);
  box-shadow:0 10px 24px rgba(25,35,58,.08);
  text-align:left;
  transition:transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}

.ward-tile:hover {
  transform:translateY(-1px);
  box-shadow:0 14px 28px rgba(25,35,58,.12);
}

.ward-tile.selected {
  border-color: #2a64c5;
  background:linear-gradient(180deg, #eef4ff 0%, #e2ecff 100%);
  box-shadow: 0 0 0 2px rgba(42,100,197,.15), 0 12px 26px rgba(25,35,58,.10);
}

.ward-title { font-size:1.08rem; font-weight:800; margin-bottom:12px; color:#132847; }
.ward-selector-tile { display:flex; flex-direction:column; justify-content:space-between; min-height:170px; gap:16px; }
.ward-selection-help { color:#364a63; font-size:.95rem; line-height:1.5; max-width:32ch; }
.ward-selection-note { margin-top:12px; font-size:.85rem; color:#38506f; font-weight:700; }
.ward-metrics { display:grid; grid-template-columns:repeat(3,1fr); gap:10px; }
.metric { background:#f7f9fc; border-radius:10px; padding:10px; text-align:center; }
.metric-value { font-size:1.2rem; font-weight:700; }
.metric-label { font-size:.75rem; color:#5c667a; text-transform:uppercase; }
.enc-grid { display:grid; grid-template-columns:1fr 1.2fr; gap:18px; }
.enc-list { display:grid; gap:12px; }
.enc-card { border:1px solid #dfe5ef; border-radius:12px; padding:14px; background:#fff; }
.enc-name { font-weight:700; font-size:1.05rem; }
.pill { display:inline-block; padding:4px 10px; border-radius:999px; font-size:.75rem; font-weight:700; }
.pill.active { background:#e8f7ee; color:#167a3b; }
.pill.inactive { background:#f3f4f6; color:#666; }
@media (max-width: 900px) { .enc-grid { grid-template-columns:1fr; } }

.gps-block {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px;
  background: rgba(255,255,255,0.04);
}
.enc-card-readable {
  border-color: #c8d5ea;
  background: linear-gradient(180deg, #ffffff 0%, #f6f9fe 100%);
  box-shadow: 0 10px 24px rgba(25,35,58,.08);
  color: #15263d;
}
.enc-card-top {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: flex-start;
}
.enc-location {
  color: #31465f;
  font-size: .98rem;
  line-height: 1.45;
}
.enc-card-meta {
  display: grid;
  gap: 8px;
  margin-top: 12px;
  color: #324861;
  font-size: .9rem;
}
.enc-card-meta strong {
  color: #132847;
  margin-right: 6px;
}
.enc-status-stack {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: flex-end;
}
.enc-card-actions {
  margin-top: 14px;
}
.housing-resource-tile {
  display: grid;
  gap: 14px;
}
.housing-resource-meta {
  color: #364a63;
  font-size: .95rem;
  line-height: 1.45;
  margin-bottom: 12px;
}
.housing-bed-preview {
  display: grid;
  gap: 8px;
}
.housing-bed-preview-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 10px;
  border-radius: 10px;
  background: rgba(255,255,255,.72);
  border: 1px solid #d9e3f2;
  font-size: .9rem;
}
.housing-bed-preview-row strong {
  color: #132847;
}
.housing-bed-card.available {
  border-style: dashed;
}
.housing-bed-card.occupied {
  border-color: #bcd0ef;
}
.housing-request-claim-box {
  display: grid;
  gap: 10px;
  margin-top: 12px;
  padding: 14px;
  border: 1px solid rgba(146, 232, 214, 0.18);
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(13, 28, 34, 0.96), rgba(9, 21, 26, 0.96));
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.03);
}
.housing-request-box-title {
  color: #d9f7f0;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.housing-request-card {
  border-radius: 16px;
  border: 1px solid rgba(146, 232, 214, 0.14);
  background: linear-gradient(180deg, rgba(16, 31, 37, 0.96), rgba(10, 22, 27, 0.98));
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.18);
}
.housing-request-card .housing-request-body {
  display: grid;
  gap: 10px;
  width: 100%;
}
.housing-request-topline {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.housing-request-type,
.housing-request-date,
.housing-request-status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.03em;
}
.housing-request-type {
  color: #d7ffef;
  background: rgba(54, 240, 195, 0.12);
  border: 1px solid rgba(54, 240, 195, 0.22);
}
.housing-request-date {
  color: var(--muted);
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.06);
}
.housing-request-status-pill {
  color: #fff;
  background: rgba(88, 166, 255, 0.16);
  border: 1px solid rgba(88, 166, 255, 0.24);
}
.housing-request-status-pill.status-open {
  color: #d7ffef;
  background: rgba(54, 240, 195, 0.14);
  border-color: rgba(54, 240, 195, 0.22);
}
.housing-request-status-pill.status-claimed_transport_pending {
  color: #fff3df;
  background: rgba(255, 191, 77, 0.16);
  border-color: rgba(255, 191, 77, 0.24);
}
.housing-request-status-pill.status-transport_arrived {
  color: #ffe5c2;
  background: rgba(255, 143, 77, 0.18);
  border-color: rgba(255, 143, 77, 0.28);
}
.housing-request-status-pill.status-intake_completed {
  color: #d9f7ff;
  background: rgba(61, 174, 233, 0.16);
  border-color: rgba(61, 174, 233, 0.24);
}
.housing-request-client {
  font-size: 18px;
  color: #f2fbf8;
}
.housing-request-summary {
  color: #b8d4cf;
  font-size: 13px;
}
.housing-request-note {
  margin: 0;
  padding: 12px 13px;
  border-radius: 12px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.05);
  color: #e8f4f2;
}
.housing-request-meta {
  display: grid;
  gap: 4px;
  padding-top: 2px;
}
.housing-request-meta small {
  color: #9ec1bb;
}
.housing-request-claim-box label {
  color: #bfd8d3;
}
.housing-request-claim-box input,
.housing-request-claim-box select {
  background: rgba(3, 14, 17, 0.9);
  border-color: rgba(146, 232, 214, 0.14);
  color: #eefaf8;
}
.housing-request-claim-box .form-actions {
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}
.housing-request-card button.btn.primary {
  box-shadow: 0 10px 20px rgba(54, 240, 195, 0.16);
}
.housing-request-card.housing-request-transport_arrived {
  border-color: rgba(255, 143, 77, 0.24);
}
.housing-request-card.housing-request-claimed_transport_pending {
  border-color: rgba(255, 191, 77, 0.2);
}
.pill.priority-critical { background:#fdeaea; color:#b42318; }
.pill.priority-high { background:#fff3df; color:#9a5b00; }
.pill.priority-medium { background:#eef4ff; color:#2457b2; }
.pill.priority-low { background:#edf7ef; color:#256f3a; }
@media (max-width: 900px) {
  .enc-card-top { flex-direction: column; }
  .enc-status-stack { align-items: flex-start; }
}

.tenant-clients-grid {
  grid-template-columns: 1.4fr 1fr;
}

.client-directory {
  display: grid;
  gap: 14px;
}

.client-card {
  display: grid;
  gap: 10px;
  padding: 16px;
  border-radius: 18px;
  border: 1px solid var(--line-strong);
  background: rgba(18, 34, 40, 0.92);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.22);
}

.client-share-banner {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(88, 166, 255, 0.2);
  background: linear-gradient(180deg, rgba(19, 39, 52, 0.94), rgba(12, 28, 38, 0.96));
}

.client-share-banner.prominent {
  border-color: rgba(54, 240, 195, 0.22);
  background: linear-gradient(180deg, rgba(15, 40, 38, 0.95), rgba(10, 29, 28, 0.98));
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.16);
}

.client-share-banner.status-claimed_transport_pending {
  border-color: rgba(255, 191, 77, 0.28);
  background: linear-gradient(180deg, rgba(43, 31, 16, 0.94), rgba(31, 23, 12, 0.98));
}

.client-share-banner.status-transport_arrived {
  border-color: rgba(255, 143, 77, 0.3);
  background: linear-gradient(180deg, rgba(52, 28, 14, 0.94), rgba(35, 20, 10, 0.98));
}

.client-share-banner.status-intake_completed {
  border-color: rgba(61, 174, 233, 0.26);
  background: linear-gradient(180deg, rgba(15, 36, 48, 0.94), rgba(10, 24, 34, 0.98));
}

.client-share-banner strong {
  color: #e8fbf6;
  font-size: 13px;
}

.client-share-banner small {
  color: #a9cbc5;
}

.client-card-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.client-card-title-wrap {
  display: flex;
  gap: 12px;
  align-items: center;
}

.client-card-photo,
.client-photo-preview {
  width: 58px;
  height: 58px;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(146, 232, 214, 0.22);
  background: rgba(255, 255, 255, 0.05);
  display: grid;
  place-items: center;
  color: #d8eeea;
  font-weight: 800;
}

.client-card-photo img,
.client-photo-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.client-card-photo.placeholder {
  font-size: 20px;
}

.client-card-head span,
.client-card small,
.client-meta-list small,
.client-history-preview small {
  color: #d6ebe6;
  display: block;
}

.client-card-head strong,
.client-history-preview strong {
  display: block;
}

.client-meta-list {
  display: grid;
  gap: 6px;
}

.client-history-preview {
  display: grid;
  gap: 4px;
  padding-top: 4px;
  border-top: 1px solid rgba(146, 232, 214, 0.18);
}

.history-preview-row {
  display: grid;
  gap: 2px;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid rgba(146, 232, 214, 0.12);
  background: rgba(255, 255, 255, 0.03);
}

.history-preview-row.housing,
.client-timeline-card.housing {
  border-color: rgba(54, 240, 195, 0.28);
  background: rgba(54, 240, 195, 0.08);
}

.history-preview-row.return,
.client-timeline-card.return {
  border-color: rgba(255, 191, 77, 0.28);
  background: rgba(255, 191, 77, 0.08);
}

.history-preview-row.move,
.client-timeline-card.move {
  border-color: rgba(88, 166, 255, 0.26);
  background: rgba(88, 166, 255, 0.08);
}

.client-timeline-card strong {
  color: #f0f8f6;
}

.client-timeline-card small,
.history-preview-row small {
  line-height: 1.45;
}

.client-dialog {
  width: min(860px, calc(100vw - 32px));
  border: 1px solid var(--line-strong);
  border-radius: 22px;
  background: rgba(10, 21, 26, 0.98);
  color: var(--text);
  box-shadow: var(--shadow);
  padding: 0;
}

.client-dialog::backdrop {
  background: rgba(3, 8, 10, 0.72);
}

.client-dialog-shell {
  padding: 20px;
}

.client-form-grid {
  display: grid;
  gap: 14px;
}

.client-photo-strip {
  display: flex;
  gap: 16px;
  align-items: center;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid rgba(146, 232, 214, 0.14);
  background: rgba(255, 255, 255, 0.03);
}

.client-form-section {
  display: grid;
  gap: 12px;
  padding: 14px;
  border-radius: 14px;
  border: 1px solid rgba(146, 232, 214, 0.14);
  background: rgba(255, 255, 255, 0.03);
}

.client-form-section h3 {
  margin: 0;
}

.client-picker-option[data-active="1"] {
  outline: 2px solid rgba(88, 166, 255, 0.5);
  outline-offset: 1px;
}

@media (max-width: 960px) {
  .tenant-clients-grid {
    grid-template-columns: 1fr;
  }
}
