:root {
  --ink: #1e2b2b;
  --muted: #6b7875;
  --canvas: #f2f4f0;
  --paper: #ffffff;
  --paper-soft: #f8faf7;
  --line: #dde5df;
  --line-strong: #c7d2ca;
  --forest: #1d5148;
  --forest-2: #2c7465;
  --purple: #5f5ba8;
  --purple-soft: #f0effa;
  --warm: #d58b42;
  --warm-soft: #fff4e7;
  --danger: #b65045;
  --shadow: 0 10px 30px rgba(26, 51, 44, 0.07);
  --radius: 18px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--canvas);
}

* { box-sizing: border-box; }
html, body { width: 100%; height: 100%; overflow: hidden; }
body { margin: 0; min-width: 0; background: radial-gradient(circle at 7% 0%, #fff 0, var(--canvas) 42%); }
button, input, select { font: inherit; }
button { cursor: pointer; }
.app-shell { width: 100%; height: 100vh; min-height: 0; margin: 0; padding: 10px 14px 12px; display: flex; flex-direction: column; gap: 9px; }
.topbar { min-height: 60px; display: grid; grid-template-columns: minmax(220px, .75fr) minmax(390px, 1.4fr) auto auto; align-items: center; gap: 14px; flex: 0 0 auto; }
.brand { display: flex; align-items: flex-start; gap: 15px; }
.brand-mark { width: 36px; height: 36px; display: grid; place-items: center; color: #fff; border-radius: 11px; background: linear-gradient(145deg, var(--forest), #163933); box-shadow: 0 8px 18px rgba(29,81,72,.22); font-size: 18px; }
.eyebrow, .section-kicker { margin: 0; color: var(--forest-2); text-transform: uppercase; letter-spacing: .12em; font-size: 10px; font-weight: 800; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin: 3px 0 0; font-size: clamp(21px, 1.8vw, 29px); line-height: 1; letter-spacing: -.055em; font-weight: 760; }
h2 { margin: 4px 0 0; font-size: 18px; letter-spacing: -.025em; }
.subtitle { color: var(--muted); margin: 0; font-size: 14px; }
.header-actions { display: flex; justify-content: flex-end; gap: 7px; }
.save-status { color: var(--muted); align-self: center; font-size: 10px; font-weight: 700; white-space: nowrap; }
.save-status.is-dirty { color: #b45b20; }
.button { border: 1px solid transparent; border-radius: 10px; min-height: 38px; padding: 0 14px; font-weight: 700; font-size: 12px; transition: .18s ease; }
.button:hover { transform: translateY(-1px); }
.button-primary { color: #fff; background: var(--forest); box-shadow: 0 5px 12px rgba(29,81,72,.2); }
.button-primary:hover { background: #17433b; }
.button-outline { border-color: var(--line-strong); color: var(--forest); background: #fff; }
.button-quiet { border-color: var(--line); color: var(--muted); background: transparent; }
.button-quiet:hover { background: var(--paper-soft); color: var(--ink); }
.button-danger { color: #fff; background: var(--danger); }
.button-icon { border: 0; background: transparent; color: #80908a; padding: 3px 5px; line-height: 1; border-radius: 7px; }
.button-icon:hover { color: var(--danger); background: #fff0ed; }
.card { background: rgba(255,255,255,.88); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.compact-imports { display: flex; align-items: center; gap: 7px; min-width: 0; }
.compact-import { min-width: 0; height: 44px; display: flex; align-items: center; gap: 8px; padding: 5px 7px; border: 1px solid var(--line); border-radius: 11px; background: rgba(255,255,255,.78); transition: .18s ease; }
.compact-import.is-dragover { border-color: var(--forest-2); background: #f1faf4; box-shadow: 0 0 0 3px rgba(44,116,101,.1); }
.compact-file-badge { width: 28px; height: 28px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 8px; font-size: 8px; font-weight: 850; letter-spacing: .04em; }
.compact-file-badge.purple { color: var(--purple); background: var(--purple-soft); }
.compact-file-badge.green { color: var(--forest); background: #e8f3ed; }
.compact-import-copy { min-width: 102px; display: grid; gap: 1px; }
.compact-import-copy strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 10px; }
.compact-import-copy .file-status { display: block; max-width: 145px; font-size: 9px; }
.compact-import .button { min-height: 29px; padding: 0 9px; font-size: 10px; }
.compact-stats { display: flex; align-items: center; justify-content: flex-end; gap: 10px; white-space: nowrap; }
.compact-stats span { display: grid; gap: 0; text-align: right; }
.compact-stats b { color: var(--forest); font-size: 15px; line-height: 1; }
.compact-stats small { color: var(--muted); font-size: 8px; text-transform: uppercase; letter-spacing: .06em; }
.compact-stats .ready b { color: #a65b20; }
.import-strip { display: none; }
.import-card { display: flex; align-items: center; gap: 14px; min-height: 108px; padding: 17px 18px; background: rgba(255,255,255,.76); border: 1px solid var(--line); border-radius: var(--radius); transition: .18s ease; }
.import-card.is-dragover { border-color: var(--forest-2); background: #f1faf4; box-shadow: 0 0 0 3px rgba(44,116,101,.1); }
.import-icon { width: 39px; height: 39px; display: grid; place-items: center; flex: 0 0 auto; border-radius: 11px; font-size: 10px; font-weight: 850; letter-spacing: .05em; }
.import-icon.purple { color: var(--purple); background: var(--purple-soft); }
.import-icon.green { color: var(--forest); background: #e8f3ed; }
.import-copy { flex: 1; min-width: 0; }
.import-heading { font-size: 14px; font-weight: 800; }
.import-copy p { color: var(--muted); font-size: 11px; line-height: 1.35; margin: 4px 0 8px; }
.file-status { display: inline-flex; max-width: 100%; color: #8a9891; font-size: 10px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.file-status.loaded { color: var(--forest-2); font-weight: 700; }
.summary-row { display: none; }
.summary-card { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 14px 16px; background: rgba(255,255,255,.62); border: 1px solid var(--line); border-radius: 14px; }
.summary-card-accent { border-color: #e9ceb0; background: var(--warm-soft); }
.summary-label { color: var(--muted); font-size: 11px; font-weight: 650; }
.summary-card strong { color: var(--forest); font-size: 23px; letter-spacing: -.04em; }
.summary-card-accent strong { color: #a65b20; }
.toolbar { display: flex; align-items: end; gap: 13px; padding: 9px 13px; margin: 0; flex: 0 0 auto; }
.toolbar-title { min-width: 180px; margin-right: auto; }
.toolbar-title h2 { font-size: 16px; }
.field { display: grid; gap: 5px; }
.field span { color: var(--muted); font-size: 10px; font-weight: 750; text-transform: uppercase; letter-spacing: .08em; }
.compact-field input, .compact-field select { min-width: 148px; height: 34px; border: 1px solid var(--line); border-radius: 8px; padding: 0 9px; color: var(--ink); background: #fff; font-size: 12px; outline: none; }
.compact-field select[multiple] { min-width: 180px; overflow: hidden; }
.compact-field input { min-width: 205px; }
.compact-field input:focus, .compact-field select:focus { border-color: var(--forest-2); box-shadow: 0 0 0 3px rgba(44,116,101,.1); }
.multi-filter { position: relative; min-width: 180px; }
.multi-filter-button { width: 100%; height: 38px; padding: 0 28px 0 11px; border: 1px solid var(--line); border-radius: 8px; color: var(--ink); background: #fff; font-size: 13px; text-align: left; position: relative; }
.multi-filter-button::after { content: ""; position: absolute; right: 11px; top: 50%; width: 6px; height: 6px; border-right: 1px solid currentColor; border-bottom: 1px solid currentColor; transform: translateY(-65%) rotate(45deg); }
.multi-filter-button[aria-expanded="true"] { border-color: var(--forest-2); box-shadow: 0 0 0 3px rgba(44,116,101,.1); }
.multi-filter-popover { position: absolute; z-index: 12; top: calc(100% + 5px); left: 0; width: 100%; min-width: 190px; padding: 6px; border: 1px solid var(--line); border-radius: 10px; background: #fff; box-shadow: 0 12px 28px rgba(20,50,42,.16); }
.multi-filter-option { display: flex; align-items: center; gap: 8px; min-height: 31px; padding: 0 7px; border-radius: 6px; color: var(--ink); font-size: 12px; cursor: pointer; }
.multi-filter-option:hover { background: #f1f7f3; }
.multi-filter-option input { width: 14px; height: 14px; margin: 0; accent-color: var(--forest); }
.multi-filter-divider { height: 1px; margin: 4px 7px; background: var(--line); }
.toggle-field { display: flex; align-items: center; gap: 7px; height: 34px; padding: 0 4px; color: var(--muted); font-size: 11px; white-space: nowrap; }
.toggle-field input { accent-color: var(--forest); }
.workspace-grid { display: grid; grid-template-columns: 305px minmax(0, 1fr); gap: 12px; align-items: stretch; flex: 1 1 auto; min-height: 0; overflow: hidden; }
.sidebar { display: grid; grid-template-rows: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; min-height: 0; overflow: hidden; }
.bucket-panel { min-height: 0; display: flex; flex-direction: column; overflow: hidden; }
.bucket-panel.is-dragover { border-color: var(--forest-2); background: #f0faf4; box-shadow: inset 0 0 0 2px rgba(44,116,101,.08); }
.panel-heading { display: flex; align-items: center; justify-content: space-between; padding: 17px 17px 0; }
.panel-heading-actions { display: flex; align-items: center; gap: 4px; }
.panel-fullscreen-button { width: 25px; height: 25px; padding: 0; color: #81908a; font-size: 15px; }
.panel-fullscreen-button:hover { color: var(--forest); background: #edf7f1; }
.panel-note { margin: 7px 17px 14px; color: var(--muted); font-size: 11px; line-height: 1.4; }
.bucket-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; margin: 0 17px; padding: 3px; border-radius: 9px; background: #eef3ef; }
.bucket-tab { min-height: 27px; border: 0; border-radius: 7px; color: var(--muted); background: transparent; font-size: 10px; font-weight: 750; }
.bucket-tab span { display: inline-grid; min-width: 17px; height: 17px; place-items: center; margin-left: 3px; padding: 0 4px; border-radius: 999px; color: #7b8982; background: rgba(255,255,255,.65); font-size: 9px; }
.bucket-tab.is-active { color: var(--forest); background: #fff; box-shadow: 0 2px 6px rgba(31,57,46,.08); }
.bucket-tab.is-active span { color: var(--forest); background: #e5f1eb; }
.readiness-button { color: #7e9a8b; font-size: 14px; }
.readiness-button:hover, .readiness-button.is-ready { color: var(--forest); background: #e4f3eb; }
.bucket-search { display: block; margin: 0 17px 8px; }
.bucket-search input { width: 100%; height: 30px; padding: 0 9px; border: 1px solid var(--line); border-radius: 8px; outline: none; color: var(--ink); background: #fff; font-size: 11px; }
.bucket-search input:focus { border-color: var(--forest-2); box-shadow: 0 0 0 3px rgba(44,116,101,.1); }
.count-pill { display: inline-grid; place-items: center; min-width: 28px; height: 24px; padding: 0 7px; color: var(--forest); background: #e7f3ed; border-radius: 999px; font-size: 11px; font-weight: 800; }
.count-pill.warm { color: #a65b20; background: var(--warm-soft); }
.bucket-dropzone { min-height: 0; flex: 1 1 auto; overflow-y: auto; margin: 0 10px 10px; padding: 6px; border: 1px dashed var(--line-strong); border-radius: 13px; background: var(--paper-soft); transition: .15s ease; }
.bucket-dropzone.is-dragover, .route-drop.is-dragover { border-color: var(--forest-2); background: #f0faf4; box-shadow: inset 0 0 0 2px rgba(44,116,101,.08); }
.bucket-empty { display: grid; place-items: center; min-height: 130px; padding: 20px; color: #94a39c; font-size: 11px; text-align: center; }
.person-row, .household-row { display: flex; align-items: center; gap: 8px; padding: 9px 8px; margin: 3px 0; border: 1px solid transparent; border-radius: 10px; background: #fff; cursor: grab; }
.person-row:hover, .household-row:hover { border-color: var(--line); box-shadow: 0 3px 10px rgba(33, 62, 51, .06); }
.person-row:active, .household-row:active { cursor: grabbing; }
.avatar { width: 25px; height: 25px; display: grid; place-items: center; flex: 0 0 auto; color: var(--forest); background: #e4f0eb; border-radius: 8px; font-size: 10px; font-weight: 850; }
.avatar.warm { color: #a65b20; background: #fff0dc; }
.row-copy { min-width: 0; flex: 1; }
.row-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; font-weight: 750; }
.row-meta { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); font-size: 10px; margin-top: 2px; }
.diagram-wrap { min-height: 0; height: 100%; display: flex; flex-direction: column; overflow: hidden; }
.diagram-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; padding: 19px 20px 15px; border-bottom: 1px solid var(--line); }
.diagram-help { max-width: 650px; margin: 5px 0 0; color: var(--muted); font-size: 11px; }
.legend { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 10px; white-space: nowrap; }
.legend-dot { display: inline-block; width: 7px; height: 7px; margin-right: 4px; background: var(--forest-2); border-radius: 50%; }
.legend-dot.needs { background: var(--warm); }
.diagram { display: grid; grid-template-columns: repeat(3, minmax(280px, 1fr)); gap: 13px; align-items: start; flex: 1 1 auto; min-height: 0; padding: 12px; overflow: auto; }
.route-district-dropbar { display: none; position: sticky; top: -12px; z-index: 8; grid-column: 1 / -1; gap: 8px; min-width: 0; margin: -12px -12px 0; padding: 8px 12px; border-bottom: 1px solid var(--line); background: rgba(247,250,248,.96); box-shadow: 0 5px 12px rgba(31,57,46,.08); backdrop-filter: blur(5px); overflow-x: auto; }
.diagram.is-route-dragging .route-district-dropbar { display: flex; }
.district-drop-target { display: grid; place-items: center; flex: 1 0 180px; min-height: 38px; padding: 0 12px; border: 1px dashed #b9c9bf; border-radius: 9px; color: #7f9188; background: #fff; font-size: 11px; font-weight: 750; white-space: nowrap; }
.district-drop-target.is-dragover { border-color: var(--forest-2); color: var(--forest); background: #eaf7ef; box-shadow: inset 0 0 0 2px rgba(44,116,101,.1); }
.district-column { min-width: 280px; border: 1px solid var(--line); border-radius: 15px; background: #f8faf8; }
.district-column.is-dragover { border-color: var(--forest-2); box-shadow: inset 0 0 0 2px rgba(44,116,101,.1); }
.district-header { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 14px 14px 11px; border-bottom: 1px solid var(--line); }
.district-title { display: flex; align-items: baseline; gap: 7px; }
.district-title h3 { margin: 0; font-size: 15px; }
.district-title span { color: var(--muted); font-size: 10px; }
.district-drop-hint { color: #a3afa8; font-size: 10px; }
.route-stack { display: grid; gap: 10px; padding: 10px; min-height: 110px; }
.route-card { border: 1px solid var(--line); border-radius: 13px; background: #fff; box-shadow: 0 3px 10px rgba(31, 57, 46, .045); transition: .15s ease; }
.route-card:hover { border-color: #b5cbc0; box-shadow: 0 7px 18px rgba(31, 57, 46, .08); }
.route-card.is-locked { border-color: #d8cce9; background: #fcfbff; }
.route-card.is-dragging { opacity: .45; }
.route-card.is-dimmed { opacity: .3; }
.route-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; padding: 11px 11px 8px; border-bottom: 1px solid #edf1ee; }
.route-label { display: flex; align-items: center; gap: 7px; min-width: 0; }
.route-grip { color: #9ca9a3; font-size: 14px; cursor: grab; }
.route-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; font-weight: 800; }
.route-sub { color: var(--muted); font-size: 10px; margin-top: 3px; }
.route-actions { display: flex; gap: 1px; }
.route-actions button { color: #81908a; }
.route-actions button:hover { color: var(--forest); background: #edf7f1; }
.route-body { display: grid; gap: 7px; padding: 9px 10px 10px; }
.route-section-label { display: flex; justify-content: space-between; color: #8a9891; text-transform: uppercase; letter-spacing: .08em; font-size: 9px; font-weight: 800; }
.route-section-label span:last-child { color: #b1bbb4; font-weight: 650; letter-spacing: 0; text-transform: none; }
.route-drop { min-height: 20px; padding: 1px; border: 1px dashed transparent; border-radius: 9px; transition: .15s ease; }
.route-drop:empty { min-height: 32px; border-color: #e6ece7; }
.route-drop:empty::after { content: "Drop here"; display: grid; place-items: center; min-height: 28px; color: #a9b4ad; font-size: 10px; }
.route-row { margin: 2px 0; padding: 6px; background: #f7faf8; }
.route-row .avatar { width: 22px; height: 22px; border-radius: 7px; }
.route-row .row-name { font-size: 11px; }
.route-row .row-meta { font-size: 9px; }
.route-row.household-row { align-items: flex-start; }
.household-flags { display: flex; align-items: center; gap: 2px; }
.needs-button { color: #111; font-size: 13px; font-weight: 400; }
.needs-button.is-active { color: #d32626; font-weight: 950; }
.lock-button { color: #aab5af; }
.lock-button.is-locked { color: #c93434; }
.lock-glyph { position: relative; display: inline-block; width: 13px; height: 11px; margin-top: 5px; border: 2px solid currentColor; border-radius: 2px; }
.lock-glyph::before { content: ""; position: absolute; left: 1px; top: -9px; width: 7px; height: 8px; border: 2px solid currentColor; border-bottom: 0; border-radius: 7px 7px 0 0; }
.lock-glyph::after { content: ""; position: absolute; left: 4px; top: 3px; width: 2px; height: 4px; border-radius: 2px; background: currentColor; }
.household-address { color: #8a9891; font-size: 9px; line-height: 1.3; margin-top: 2px; }
.household-members { color: #6f8178; font-size: 10px; line-height: 1.35; margin-top: 3px; }
.empty-route { padding: 13px 8px; border: 1px dashed #dfe7e1; border-radius: 9px; color: #a1aea6; font-size: 10px; text-align: center; }
.empty-state { display: grid; place-items: center; min-height: 455px; padding: 50px; color: var(--muted); text-align: center; }
.empty-state h2 { color: var(--ink); font-size: 20px; }
.empty-state p { max-width: 390px; line-height: 1.5; font-size: 12px; }
.empty-orb { width: 55px; height: 55px; display: grid; place-items: center; margin-bottom: 14px; color: var(--forest); background: #e7f3ed; border-radius: 18px; font-size: 26px; }
.hidden, .visually-hidden { display: none !important; }
.toast { position: fixed; right: 25px; bottom: 24px; z-index: 20; max-width: 370px; padding: 12px 15px; color: #fff; background: #1e3832; border-radius: 10px; box-shadow: 0 12px 30px rgba(20,50,42,.22); font-size: 12px; opacity: 0; transform: translateY(10px); pointer-events: none; transition: .2s ease; }
.toast.show { opacity: 1; transform: translateY(0); }
.modal-backdrop { position: fixed; inset: 0; z-index: 15; display: grid; place-items: center; padding: 20px; background: rgba(20, 39, 34, .34); backdrop-filter: blur(4px); }
.modal { width: min(420px, 100%); padding: 22px; }
.modal p { color: var(--muted); line-height: 1.5; font-size: 13px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 9px; margin-top: 20px; }
.bucket-panel:fullscreen { width: 100vw; height: 100vh; min-height: 0; border: 0; border-radius: 0; box-shadow: none; background: var(--canvas); }
.bucket-panel:fullscreen .panel-heading { padding-top: 22px; }
.bucket-panel:fullscreen .bucket-dropzone { margin-bottom: 18px; }
.map-modal { width: min(1000px, 100%); padding: 0; overflow: hidden; }
.map-modal-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; padding: 20px 22px 15px; border-bottom: 1px solid var(--line); }
.map-modal-header h2 { margin-top: 4px; font-size: 21px; }
.map-modal-header p { margin: 5px 0 0; color: var(--muted); font-size: 11px; }
.route-map { height: 570px; background: #e8efe9; }
.map-legend { display: flex; align-items: center; gap: 17px; min-height: 44px; padding: 0 22px; color: var(--muted); font-size: 11px; }
.map-legend-dot { display: inline-block; width: 9px; height: 9px; margin-right: 5px; border-radius: 50%; }
.map-legend-dot.minister { background: var(--forest); }
.map-legend-dot.household { background: var(--warm); }
.leaflet-popup-content { margin: 11px 13px; }
.popup-kicker { color: var(--forest-2); text-transform: uppercase; letter-spacing: .1em; font-size: 9px; font-weight: 800; }
.popup-name { margin-top: 3px; font-weight: 800; }
.popup-address { margin-top: 4px; color: #697974; font-size: 11px; line-height: 1.35; }

@media (max-width: 1250px) {
  .app-shell { padding-left: 10px; padding-right: 10px; }
  .topbar { grid-template-columns: minmax(190px, .7fr) minmax(300px, 1.2fr) auto; }
  .brand h1 { white-space: normal; }
  .header-actions { grid-column: 3; grid-row: 1; }
  .compact-stats { display: none; }
  .workspace-grid { grid-template-columns: 260px minmax(0, 1fr); }
  .toolbar { flex-wrap: wrap; align-items: center; }
  .toolbar-title { min-width: 100%; }
  .route-map { height: 480px; }
}

/* Comfortable default density: approximately the previous 110% browser zoom. */
.app-shell { padding: 12px 16px 14px; gap: 10px; }
.topbar { min-height: 66px; gap: 16px; grid-template-columns: minmax(320px, .9fr) minmax(420px, 1.2fr) auto auto; }
.brand { gap: 16px; }
.brand-mark { width: 40px; height: 40px; border-radius: 12px; font-size: 20px; }
.eyebrow, .section-kicker { font-size: 11px; }
h1 { font-size: clamp(24px, 2vw, 32px); }
.brand h1 { white-space: nowrap; }
.button { min-height: 42px; padding: 0 16px; font-size: 13px; }
.compact-import { height: 49px; gap: 9px; padding: 6px 8px; border-radius: 12px; }
.compact-file-badge { width: 31px; height: 31px; font-size: 9px; }
.compact-import-copy strong { font-size: 11px; }
.compact-import-copy .file-status { font-size: 10px; }
.compact-import .button { min-height: 33px; padding: 0 10px; font-size: 11px; }
.compact-stats { gap: 12px; }
.compact-stats b { font-size: 17px; }
.compact-stats small { font-size: 9px; }
.toolbar { gap: 15px; padding: 11px 15px; }
.toolbar-title h2 { font-size: 18px; }
.field span { font-size: 11px; }
.compact-field input, .compact-field select { height: 38px; font-size: 13px; }
.toggle-field { height: 38px; font-size: 12px; }
.workspace-grid { gap: 14px; }
.sidebar { gap: 14px; }
.panel-heading { padding: 19px 19px 0; }
.panel-heading h2 { font-size: 20px; }
.panel-note { margin: 8px 19px 15px; font-size: 12px; }
.bucket-tabs { margin: 0 19px; }
.bucket-tab { min-height: 30px; font-size: 11px; }
.bucket-search { margin: 0 19px 9px; }
.bucket-search input { height: 34px; font-size: 12px; }
.bucket-dropzone { margin: 0 11px 11px; padding: 7px; }
.person-row, .household-row { gap: 9px; padding: 10px 9px; }
.avatar { width: 28px; height: 28px; font-size: 11px; }
.row-name { font-size: 13px; }
.row-meta, .household-members { font-size: 11px; }
.route-row { padding: 7px; }
.route-row .avatar { width: 24px; height: 24px; }
.route-row .row-name { font-size: 12px; }
.route-row .row-meta, .route-row .household-members { font-size: 10px; }
.diagram-header { padding: 21px 22px 17px; }
.diagram-help { font-size: 12px; }
.legend { font-size: 11px; }
.diagram { gap: 15px; padding: 14px; }
.district-header { padding: 16px 16px 13px; }
.district-title h3 { font-size: 17px; }
.route-stack { gap: 12px; padding: 12px; }
.route-head { padding: 13px 13px 10px; }
.route-name { font-size: 13px; }
.route-sub { font-size: 11px; }
.route-body { gap: 8px; padding: 11px 12px 12px; }
.bucket-panel:fullscreen .panel-heading,
.bucket-panel:fullscreen .bucket-tabs,
.bucket-panel:fullscreen .panel-note,
.bucket-panel:fullscreen .bucket-search,
.bucket-panel:fullscreen .bucket-dropzone,
.bucket-panel.is-panel-fullscreen .panel-heading,
.bucket-panel.is-panel-fullscreen .bucket-tabs,
.bucket-panel.is-panel-fullscreen .panel-note,
.bucket-panel.is-panel-fullscreen .bucket-search,
.bucket-panel.is-panel-fullscreen .bucket-dropzone { inline-size: min(1100px, calc(100% - 40px)); max-width: calc(100% - 40px); margin-left: auto; margin-right: auto; align-self: center; flex: 0 1 auto; }
.bucket-panel:fullscreen .panel-heading { padding-left: 0; padding-right: 0; }
.bucket-panel:fullscreen .bucket-dropzone,
.bucket-panel.is-panel-fullscreen .bucket-dropzone { flex: 1 1 auto; min-height: 0; }

/* Keep fullscreen readiness views readable instead of stretching them across the monitor. */
.bucket-panel.is-panel-fullscreen,
.bucket-panel:fullscreen { display: flex; align-items: center; }
.bucket-panel.is-panel-fullscreen { width: 100vw; height: 100vh; min-height: 0; border: 0; border-radius: 0; box-shadow: none; background: var(--canvas); }
.bucket-panel.is-panel-fullscreen > .panel-heading,
.bucket-panel.is-panel-fullscreen > .panel-note,
.bucket-panel.is-panel-fullscreen > .bucket-tabs,
.bucket-panel.is-panel-fullscreen > .bucket-search,
.bucket-panel.is-panel-fullscreen > .bucket-dropzone,
.bucket-panel:fullscreen > .panel-heading,
.bucket-panel:fullscreen > .panel-note,
.bucket-panel:fullscreen > .bucket-tabs,
.bucket-panel:fullscreen > .bucket-search,
.bucket-panel:fullscreen > .bucket-dropzone {
  inline-size: min(1100px, calc(100% - 40px));
  max-width: calc(100% - 40px);
  margin-left: auto;
  margin-right: auto;
}
.bucket-panel.is-panel-fullscreen > .bucket-dropzone,
.bucket-panel:fullscreen > .bucket-dropzone { flex: 1 1 auto; inline-size: min(400px, calc(100% - 40px)); width: min(400px, calc(100% - 40px)); max-width: 400px; }
