/* Layout: full-bleed map under a 50px site bar; filters float left, point detail floats right
   (bottom sheet on phones). Shared-chrome token names follow the dodies.lv family (see the parent CLAUDE.md). */
@font-face {
  font-family: 'Outfit';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/fonts/outfit.woff2') format('woff2');
}
@font-face {
  font-family: 'Fraunces';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/fonts/fraunces.woff2') format('woff2');
}

:root {
  --header-h: 50px;
  --radius: 12px;
  --bg: #f6f1e6;
  --panel-bg: rgba(255, 253, 248, 0.96);
  --border: #e3dac7;
  --ink: #221c14;
  --ink-muted: #6d6353;
  --ink-soft: #9c9382;
  --accent: #8a5a2b;
  --accent-soft: rgba(138, 90, 43, 0.14);
  --accent-line: rgba(138, 90, 43, 0.32);
  --font-brand: 'Fraunces', Georgia, serif;
  --font-ui: 'Outfit', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-ui-display: var(--font-ui);
  --font-data: ui-monospace, 'SF Mono', Menlo, Consolas, monospace;
  /* reliability ramp (pin fill) and personal marks (pin edge) */
  --r5: #00b85c;
  --r4: #8fd629;
  --r3: #ffcf33;
  --r2: #ff9a1f;
  --r1: #ff5a4e;
  --r0: #a39d93;
  --m-virtual: #ffffff;
  --m-field: #14100a;
  --m-usable: #7a2fd0;
  --m-other: #1f6fd0;
  --m-gone: #d0342c;
  --pin-edge: #1a140c;
  --shadow: 0 6px 24px rgba(34, 28, 20, 0.18);
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { height: 100%; margin: 0; }
body {
  background: var(--bg);
  color: var(--ink);
  font: 15px/1.45 var(--font-ui);
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
button, input, select, textarea { font: inherit; color: inherit; }
kbd {
  font: 600 11px/1 var(--font-data);
  padding: 2px 5px;
  border: 1px solid var(--border);
  border-bottom-width: 2px;
  border-radius: 4px;
  background: #fff;
  color: var(--ink-muted);
}
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---- site bar ---- */
.bar {
  flex: none;
  height: calc(var(--header-h) + env(safe-area-inset-top, 0px));
  padding: env(safe-area-inset-top, 0px) 16px 0;
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--panel-bg);
  border-bottom: 1px solid var(--border);
  z-index: 1001;
}
.brand {
  display: inline-flex;
  align-items: baseline;
  gap: 2px;
  font: 600 19px/1 var(--font-brand);
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}
.brand-slash { color: var(--ink-soft); font-weight: 400; }
.brand-section { color: var(--accent); }
.bar h1 {
  margin: 0;
  font: 600 17px/1.1 var(--font-ui);
  letter-spacing: 0.01em;
  white-space: nowrap;
}
.progress {
  flex: 1;
  min-width: 0;
  color: var(--ink-muted);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.progress b { color: var(--ink); font-weight: 600; }

/* ---- buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 7px 12px;
  border: 1px solid var(--accent-line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-size: 14px;
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
}
.btn:hover { background: var(--accent-soft); }
.btn.ghost { background: transparent; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary kbd { background: transparent; color: #fff; border-color: rgba(255, 255, 255, 0.5); }
.btn.primary:hover { background: #774b20; }
.btn.icon { width: 34px; height: 34px; padding: 0; font-size: 22px; line-height: 1; }
.btn:focus-visible, .check input:focus-visible + .box, select:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.btnrow { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---- stage ---- */
.stage { position: relative; flex: 1; min-height: 0; }
#map { position: absolute; inset: 0; background: #d9d3c4; }
.leaflet-container { font-family: var(--font-ui); }

.panel {
  position: absolute;
  top: 12px;
  z-index: 1000;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  backdrop-filter: blur(6px);
  overflow-y: auto;
  max-height: calc(100% - 24px);
}
.panel h2 {
  margin: 0 0 8px;
  font: 600 12px/1.2 var(--font-ui);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-muted);
  display: flex;
  justify-content: space-between;
  gap: 8px;
}
.panel .hint { text-transform: none; letter-spacing: 0; font-weight: 400; color: var(--ink-muted); }

/* filters */
.filters {
  left: 12px;
  width: 300px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.filters section { display: flex; flex-direction: column; gap: 8px; }
.filters h2 { margin: 0; }   /* the section gap already spaces it */
.legend, .keylegend { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.legend label {
  display: grid;
  grid-template-columns: 18px 14px 1fr auto;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  padding: 2px 4px;
  border-radius: 6px;
}
.legend label:hover { background: var(--accent-soft); }
.legend input { margin: 0; accent-color: var(--accent); }
.legend .dot { width: 14px; height: 14px; border-radius: 50%; border: 1.5px solid var(--pin-edge); }
.legend .name { font-weight: 500; }
.legend .count { font-variant-numeric: tabular-nums; color: var(--ink-muted); font-size: 13px; }
.keylegend { flex-direction: row; flex-wrap: wrap; gap: 6px 14px; font-size: 13px; color: var(--ink-muted); }
.keylegend li { display: flex; align-items: center; gap: 6px; }
.kdot { width: 14px; height: 14px; border-radius: 50%; background: var(--r3); border: 1.5px solid var(--pin-edge); }
.kdot.k-virtual { border: 3px solid var(--m-virtual); box-shadow: 0 0 0 1px var(--pin-edge); }
.kdot.k-field { border: 3px solid var(--m-field); }
.kdot.k-usable { background: var(--m-usable); border: 3px solid #fff; box-shadow: 0 0 0 1px var(--pin-edge); }
.kdot.k-other { background: var(--m-other); border: 3px solid #fff; box-shadow: 0 0 0 1px var(--pin-edge); }
.kdot.k-gone { background: var(--r0); opacity: 0.6; border: 2px solid var(--m-gone); }
.field { display: flex; flex-direction: column; gap: 4px; }
.field .lbl { font-size: 13px; color: var(--ink-muted); }
.field input, .field select, .field textarea {
  width: 100%;
  padding: 7px 9px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
}
.field textarea { resize: vertical; min-height: 54px; }
.note { margin: 0; font-size: 13px; color: var(--ink-muted); }
.warn { margin: 0; font-size: 13px; color: var(--m-gone); font-weight: 500; }

/* detail */
.detail {
  right: 12px;
  width: 440px;
  padding: 14px 16px 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.dhead { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.dtitle { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.dtitle h2 {
  margin: 0;
  font: 600 21px/1.15 var(--font-brand);
  text-transform: none;
  letter-spacing: 0;
  color: var(--ink);
  text-wrap: balance;
  overflow-wrap: anywhere;
}
.chip {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 9px 2px 6px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  background: var(--accent-soft);
}
.from { margin: 0; font-size: 13px; color: var(--ink-muted); font-variant-numeric: tabular-nums; }
.chip::before { content: ''; width: 10px; height: 10px; border-radius: 50%; background: var(--chip, var(--r3)); border: 1.5px solid var(--pin-edge); }

.previews { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.previews figure { position: relative; margin: 0; min-width: 0; }
.pmap {
  width: 100%;
  aspect-ratio: 1;
  max-width: 100%;
  border-radius: 8px;
  overflow: hidden;
  background: #cfc8b8;
  border: 1px solid var(--border);
}
.previews figcaption { margin-top: 4px; font-size: 12px; color: var(--ink-muted); text-align: center; }
.cross {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 22px;
  height: 22px;
  margin: -11px 0 0 -11px;
  border-radius: 50%;
  border: 2px solid #fff;
  box-shadow: 0 0 0 1.5px rgba(0, 0, 0, 0.75), inset 0 0 0 1.5px rgba(0, 0, 0, 0.75);
  pointer-events: none;
  z-index: 500;
}
.previews .cross { top: calc(50% - 10px); }
.sat { margin-top: -4px; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; font-size: 13.5px; }
.sat .lbl { color: var(--ink-muted); }
.sat a {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border: 1px solid var(--accent-line);
  border-radius: 999px;
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
}
.sat a::after { content: '↗'; margin-left: 5px; font-size: 12px; }
.sat a:hover { background: var(--accent-soft); }

.marks { display: flex; flex-direction: column; gap: 10px; }
.checks { display: grid; grid-template-columns: 1fr; gap: 6px; }
.check {
  position: relative;
  display: grid;
  grid-template-columns: 24px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  user-select: none;
}
.check:hover { border-color: var(--accent-line); }
.check input { position: absolute; opacity: 0; pointer-events: none; }
.check .box {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  border: 2px solid var(--ink-soft);
  display: grid;
  place-items: center;
  background: #fff;
}
.check input:checked + .box::after {
  content: '';
  width: 6px;
  height: 11px;
  border: solid #fff;
  border-width: 0 3px 3px 0;
  transform: translateY(-1px) rotate(45deg);
}
.check .ctext { font-weight: 500; display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.check .ctext small { font-size: 12.5px; font-weight: 400; color: var(--ink-muted); }
.check.c-virtual input:checked + .box { background: #6d6353; border-color: #6d6353; }
.check.c-field input:checked + .box { background: var(--m-field); border-color: var(--m-field); }
.check.c-usable input:checked + .box { background: var(--m-usable); border-color: var(--m-usable); }
.check.c-usable:has(input:checked) { border-color: var(--m-usable); background: rgba(122, 47, 208, 0.07); }
.check.c-usable .ctext { font-weight: 600; }
.check.c-other input:checked + .box { background: var(--m-other); border-color: var(--m-other); }
.check.c-other:has(input:checked) { border-color: var(--m-other); background: rgba(31, 111, 208, 0.07); }
.check.c-gone { padding: 6px 12px; background: transparent; }
.check.c-gone .ctext { font-size: 14px; color: var(--ink-muted); font-weight: 400; }
.check.c-gone input:checked + .box { background: var(--m-gone); border-color: var(--m-gone); }
.check.c-gone:has(input:checked) .ctext { color: var(--m-gone); text-decoration: line-through; }
.pos { margin: -4px 0 0; font-size: 13px; color: var(--ink-muted); }
.pos b { color: var(--m-other); font-weight: 600; }
.stamp { margin: -2px 0 0; font-size: 12px; color: var(--ink-muted); min-height: 1em; }

.nav { display: flex; gap: 8px; }
.nav .primary { flex: 1; }

.facts {
  margin: 0;
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 5px 12px;
  font-size: 13.5px;
  border-top: 1px solid var(--border);
  padding-top: 12px;
}
.facts dt { color: var(--ink-muted); }
.facts dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.facts .num { font-family: var(--font-data); font-size: 12.5px; font-variant-numeric: tabular-nums; }
.facts .copy {
  margin-left: 6px;
  padding: 0 6px;
  font-size: 12px;
  border: 1px solid var(--border);
  border-radius: 5px;
  background: #fff;
  cursor: pointer;
}
.links { display: flex; flex-wrap: wrap; gap: 8px; }
.links a {
  font-size: 13.5px;
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid var(--accent-line);
}
.links a:hover { border-bottom-color: var(--accent); }

/* hover preview */
.hovercard {
  position: absolute;
  z-index: 1002;
  width: 300px;
  padding: 6px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  pointer-events: none;
}
.hmap { width: 288px; height: 288px; border-radius: 8px; overflow: hidden; background: #cfc8b8; }
.hovercard .cross { top: calc(6px + 144px); margin-top: -11px; }
.hcap { padding: 6px 4px 2px; font-size: 13px; display: flex; flex-direction: column; gap: 2px; }
.hcap b { font-weight: 600; }
.hcap span { color: var(--ink-muted); font-size: 12px; }

.toast {
  position: absolute;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  z-index: 1003;
  padding: 9px 16px;
  border-radius: 10px;
  background: var(--ink);
  color: #fff;
  font-size: 14px;
  box-shadow: var(--shadow);
  max-width: calc(100% - 32px);
}

/* main-map extras */
.selring { pointer-events: none; }
.leaflet-control-layers-expanded { font-size: 13px; }

/* ---- account + sync ---- */
.acct { display: flex; align-items: center; gap: 10px; min-width: 0; }
.acct .who { font-weight: 600; font-size: 14px; white-space: nowrap; }
.acct .sync {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--ink-muted);
  white-space: nowrap;
}
.acct .sync::before { content: ''; width: 9px; height: 9px; border-radius: 50%; background: var(--ink-soft); flex: none; }
.acct .sync.s-ok::before { background: #00a651; }
.acct .sync.s-busy::before { background: #f2c200; }
.acct .sync.s-offline::before { background: var(--m-gone); }
.acct .cog { width: 32px; height: 32px; margin-left: -4px; color: var(--ink-muted); }
.acct .cog:hover, .acct .cog[aria-expanded="true"] { color: var(--accent); }
.acct .cog[aria-expanded="true"] { background: var(--accent-soft); }

/* ---- colour switch ---- */
.seg { display: grid; grid-template-columns: 1fr 1fr; border: 1px solid var(--accent-line); border-radius: 8px; overflow: hidden; }
.seg button {
  border: 0;
  background: transparent;
  padding: 6px 8px;
  font-size: 13px;
  cursor: pointer;
  color: var(--ink-muted);
}
.seg button[aria-pressed="true"] { background: var(--accent); color: #fff; font-weight: 600; }
.statuslegend { margin-bottom: 4px; }
.teamme { margin: 0; display: flex; align-items: center; justify-content: space-between; gap: 10px; font-weight: 600; }
.teamtoggle { display: flex; align-items: center; gap: 8px; font-size: 14px; cursor: pointer; }
.teamtoggle input { margin: 0; accent-color: var(--accent); }
.teamtoggle .count { color: var(--ink-muted); font-variant-numeric: tabular-nums; }

/* ---- teammates on a point ---- */
.team { border-top: 1px solid var(--border); padding-top: 10px; display: flex; flex-direction: column; gap: 4px; }
.team h3 { margin: 0 0 2px; font: 600 12px/1.2 var(--font-ui); text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-muted); }
.trow { margin: 0; font-size: 13.5px; display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; }
.tdot { width: 10px; height: 10px; border-radius: 50%; flex: none; align-self: center; border: 1.5px solid var(--pin-edge); }

/* ---- team towers ---- */
.obj-pin { background: none; border: 0; }
.obj-pin i {
  position: absolute;
  inset: 4px;
  transform: rotate(45deg);
  border-radius: 3px;
  border: 2px solid #fff;
  box-shadow: 0 0 0 1.5px var(--pin-edge);
}
.obj-pin.is-ok i { box-shadow: 0 0 0 1.5px var(--pin-edge), 0 0 0 4.5px var(--m-usable); }
.obj-pin.is-sel i { box-shadow: 0 0 0 1.5px var(--pin-edge), 0 0 0 5px var(--accent); }
.objpanel select:disabled, .objpanel textarea:disabled { background: var(--bg); color: var(--ink-muted); }
.objpanel .check:has(input:disabled) { cursor: default; opacity: 0.75; }
.btn.danger { color: var(--m-gone); border-color: rgba(208, 52, 44, 0.4); }
.btn.danger:hover { background: rgba(208, 52, 44, 0.08); }

.fab {
  position: absolute;
  right: 16px;
  bottom: calc(28px + env(safe-area-inset-bottom, 0px));
  z-index: 1001;
  padding: 12px 18px;
  border: 0;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font: 600 16px/1 var(--font-ui);
  box-shadow: var(--shadow);
  cursor: pointer;
}
.fab:hover { background: #774b20; }
.obj-pin.is-round i { transform: none; border-radius: 50%; }
.obj-pin.is-note i { transform: none; border-radius: 50%; color: #fff; font: 700 11px/10px var(--font-ui); text-align: center; }
.ofields { display: flex; flex-direction: column; gap: 10px; }
.ofields:empty { display: none; }
.field input:invalid { border-color: var(--m-gone); }

/* ---- “Kas tas ir?”: the type of a new object ---- */
.klist { display: flex; flex-direction: column; gap: 12px; }
.klist section { display: flex; flex-direction: column; gap: 6px; }
.klist h3 { margin: 0; font: 600 12px/1.2 var(--font-ui); text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink-muted); }
.kgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.kbtn {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 42px;
  padding: 7px 10px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
  font-size: 14px;
  line-height: 1.2;
  text-align: left;
  cursor: pointer;
}
.kbtn:hover { border-color: var(--accent-line); background: var(--accent-soft); }
.kbtn i { flex: none; width: 12px; height: 12px; border-radius: 50%; border: 1.5px solid var(--pin-edge); }
.kbtn.is-tower i { border-radius: 2px; transform: rotate(45deg); }
.kdup { padding: 10px 12px; border-radius: 10px; background: rgba(242, 194, 0, 0.18); display: flex; flex-direction: column; gap: 8px; }
.kdup p { margin: 0; font-weight: 500; }
.detail:not([hidden]) ~ .fab { display: none; }

/* placing: the map centre is the tower */
.placecross {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 44px;
  height: 44px;
  margin: -22px 0 0 -22px;
  z-index: 1000;
  pointer-events: none;
  border-radius: 50%;
  border: 2.5px solid #fff;
  box-shadow: 0 0 0 1.5px rgba(0, 0, 0, 0.8), inset 0 0 0 1.5px rgba(0, 0, 0, 0.8);
}
.placecross::before, .placecross::after {
  content: '';
  position: absolute;
  background: #fff;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.8);
}
.placecross::before { left: 50%; top: -14px; bottom: -14px; width: 2px; margin-left: -1px; }
.placecross::after { top: 50%; left: -14px; right: -14px; height: 2px; margin-top: -1px; }
.placebar {
  position: absolute;
  left: 50%;
  top: 12px;
  transform: translateX(-50%);
  z-index: 1002;
  width: min(420px, calc(100% - 24px));
  padding: 12px 14px;
  background: var(--panel-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.placebar p { margin: 0; font-weight: 500; font-variant-numeric: tabular-nums; }
.placebar .btnrow { justify-content: flex-end; }
.placebar .btn { padding: 9px 16px; font-size: 15px; }

/* ---- exports (folded away) ---- */
.exports summary, .sentbox summary {
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-muted);
  padding: 4px 0;
  list-style-position: inside;
}
.exports summary:hover, .sentbox summary:hover { color: var(--ink); }
.exportbody { display: flex; flex-direction: column; gap: 8px; padding-top: 8px; }
#btn-send:disabled { opacity: 0.5; cursor: default; }

/* ---- access (admins) ---- */
.ainvite { display: flex; flex-direction: column; gap: 8px; }
.arow { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.badge { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 999px; font-size: 11.5px; font-weight: 600;
  background: var(--accent-soft); color: var(--accent); }
.badge.off { background: rgba(208, 52, 44, 0.1); color: var(--m-gone); }
.badge.wait { background: rgba(242, 194, 0, 0.18); color: #8a6d00; }
.aacts { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.aacts .btn { padding: 4px 10px; font-size: 13px; }
.srow.is-off .stitle { color: var(--ink-muted); }

/* ---- send to OSM ---- */
.sres { margin: 0; padding: 8px 10px; border-radius: 8px; background: rgba(0, 166, 81, 0.1); font-size: 14px; }
.sres a, .slist a { color: var(--accent); }
.slist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.srow {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2px 8px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
  font-size: 14px;
}
.srow label { display: flex; align-items: center; gap: 8px; min-width: 0; cursor: pointer; }
.srow label input { margin: 0; accent-color: var(--accent); flex: none; }
.srow .stitle { font-weight: 600; min-width: 0; overflow-wrap: anywhere; }
.srow .ssub, .srow .sstat { grid-column: 1 / -1; font-size: 12.5px; color: var(--ink-muted); }
.srow .sstat.new { color: #00843f; font-weight: 600; }
.srow .sstat.no { color: var(--m-gone); }
.slink { border: 0; background: none; color: var(--accent); cursor: pointer; font-size: 13px; padding: 0; }
.sstat .slink { margin-left: 8px; font-weight: 600; text-decoration: underline; }
.sempty { color: var(--ink-muted); font-size: 14px; }
.sendpanel .nav .primary:disabled { opacity: 0.5; cursor: default; }

/* ---- narrow screens ---- */
@media (max-width: 760px) {
  .bar { gap: 10px; }
  .bar h1 { font-size: 15px; }
  .progress { display: none; }
  .filters { left: 8px; right: 8px; width: auto; top: 8px; max-height: calc(100% - 16px); }
  .filters:not(.open) { display: none; }
  .detail {
    left: 0;
    right: 0;
    top: auto;
    bottom: 0;
    width: auto;
    max-height: 62%;
    border-radius: var(--radius) var(--radius) 0 0;
    padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px));
  }
  .hovercard { display: none; }
  /* the attribution wraps to two lines here: keep the scale and the add button above it */
  .leaflet-bottom.leaflet-left .leaflet-control-scale { margin-bottom: 38px; }
  .fab { bottom: calc(44px + env(safe-area-inset-bottom, 0px)); }
  .acct .who, .acct .sync { font-size: 0; gap: 0; }
  .acct .btn:not(.login):not(.cog), .login .wide { display: none; }
  .bar h1 { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
  .acct .sync::before { width: 11px; height: 11px; }
}
@media (min-width: 761px) {
  #btn-filters { display: none; }
  .teamme { display: none; }   /* the bar already shows who you are and Iziet */
  .detail:not([hidden]) ~ .hovercard { right: auto; }
}
@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; animation: none !important; }
}
