:root {
  --bg: #fafafa; --bg-2: #ffffff; --bg-3: #f3f4f6; --line: #e7e7ea; --line-2: #d9d9de;
  --fg: #111114; --fg-2: #55565e; --fg-3: #8b8c94;
  --accent: #4f46e5; --accent-2: #6366f1; --accent-soft: #eef0ff;
  --good: #16a34a; --good-soft: #e9f8ef; --warn: #d97706; --warn-soft: #fdf4e3; --bad: #dc2626; --bad-soft: #fdecec;
  --shadow: 0 1px 2px rgba(16,16,24,.04), 0 4px 16px rgba(16,16,24,.04);
  --shadow-lg: 0 10px 40px rgba(16,16,24,.12);
  --r: 12px; --r-sm: 8px;
  --ease: cubic-bezier(.2,.8,.2,1);
  --font: ui-sans-serif, -apple-system, "Segoe UI Variable", "Segoe UI", Inter, Roboto, sans-serif;
  --mono: ui-monospace, "Cascadia Code", Consolas, monospace;
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #0b0b0e; --bg-2: #131317; --bg-3: #1b1b21; --line: #24242b; --line-2: #31313a;
  --fg: #ededf0; --fg-2: #a3a4ad; --fg-3: #6e6f78;
  --accent: #818cf8; --accent-2: #a5b4fc; --accent-soft: #1d1f3a;
  --good: #34d399; --good-soft: #0f2a20; --warn: #fbbf24; --warn-soft: #2b2310; --bad: #f87171; --bad-soft: #2e1414;
  --shadow: 0 1px 2px rgba(0,0,0,.4); --shadow-lg: 0 10px 40px rgba(0,0,0,.6);
  color-scheme: dark;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--bg); color: var(--fg); font: 14px/1.5 var(--font); -webkit-font-smoothing: antialiased; transition: background .25s var(--ease), color .25s var(--ease); }
a { color: var(--accent); text-decoration: none; } a:hover { text-decoration: underline; }
::selection { background: var(--accent-soft); }
::-webkit-scrollbar { width: 10px; height: 10px; } ::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 10px; border: 3px solid var(--bg); }

/* layout */
.app { display: grid; grid-template-columns: 232px 1fr; height: 100vh; }
.side { overflow-x: hidden; border-right: 1px solid var(--line); background: var(--bg-2); display: flex; flex-direction: column; padding: 14px 10px; gap: 2px; overflow-y: auto; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 650; letter-spacing: -.01em; padding: 6px 10px 14px; font-size: 15px; }
.brand .logo { width: 26px; height: 26px; border-radius: 8px; background: linear-gradient(135deg, var(--accent), #22d3ee); display: grid; place-items: center; color: white; font-size: 13px; font-weight: 800; }
.nav-group { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--fg-3); padding: 14px 10px 4px; }
.nav { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: var(--r-sm); color: var(--fg-2); cursor: pointer; transition: background .15s, color .15s; position: relative; user-select: none; }
.nav:hover { background: var(--bg-3); color: var(--fg); text-decoration: none; }
.nav.active { background: var(--accent-soft); color: var(--accent); font-weight: 550; }
.nav svg { width: 16px; height: 16px; flex: none; }
.nav .badge { margin-left: auto; }
.side-foot { margin-top: auto; padding-top: 12px; display: flex; gap: 6px; align-items: center; }
.main { overflow-y: auto; overflow-x: hidden; }
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 12px; padding: 10px 18px; background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.topbar h1 { font-size: 17px; margin: 0; font-weight: 650; letter-spacing: -.015em; }
.topbar .sp { flex: 1; }
.page { padding: 14px 18px 18px; min-height: calc(100vh - 56px); box-sizing: border-box; animation: pageIn .35s var(--ease); }
@keyframes pageIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* cards / grid */
.grid { display: grid; gap: 16px; }
.g2 { grid-template-columns: repeat(2, minmax(0,1fr)); } .g3 { grid-template-columns: repeat(3, minmax(0,1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0,1fr)); } .g6 { grid-template-columns: repeat(6, minmax(0,1fr)); }
.span2 { grid-column: span 2; } .span3 { grid-column: span 3; } .span-all { grid-column: 1 / -1; }
@media (max-width: 1200px) { .g4, .g6 { grid-template-columns: repeat(3, minmax(0,1fr)); } }
@media (max-width: 900px) { .app { grid-template-columns: 1fr; } .side { display: none; } .g2, .g3, .g4, .g6 { grid-template-columns: 1fr; } .span2, .span3 { grid-column: auto; } .page { padding: 16px; } .topbar { padding: 12px 16px; } }
.card { background: var(--bg-2); border: 1px solid var(--line); border-radius: var(--r); padding: 18px; box-shadow: var(--shadow); animation: cardIn .45s var(--ease) both; min-width: 0; }
.grid > .card:nth-child(2) { animation-delay: .03s } .grid > .card:nth-child(3) { animation-delay: .06s } .grid > .card:nth-child(4) { animation-delay: .09s }
.grid > .card:nth-child(5) { animation-delay: .12s } .grid > .card:nth-child(6) { animation-delay: .15s } .grid > .card:nth-child(n+7) { animation-delay: .18s }
@keyframes cardIn { from { opacity: 0; transform: translateY(8px) scale(.995); } to { opacity: 1; transform: none; } }
.card h3 { margin: 0 0 12px; font-size: 13px; font-weight: 600; color: var(--fg-2); display: flex; align-items: center; gap: 8px; }
.card h3 .sp { flex: 1; }
.card.flat { box-shadow: none; }
.card.hover { transition: transform .2s var(--ease), border-color .2s, box-shadow .2s; cursor: pointer; }
.card.hover:hover { transform: translateY(-2px); border-color: var(--line-2); box-shadow: var(--shadow-lg); }
.stat .v { font-size: 26px; font-weight: 650; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.stat .l { color: var(--fg-3); font-size: 12px; }
.stat .d { font-size: 12px; font-weight: 550; }
.up { color: var(--good); } .down { color: var(--bad); } .muted { color: var(--fg-3); } .small { font-size: 12px; } .mono { font-family: var(--mono); font-size: 12px; }
.row { display: flex; align-items: center; gap: 10px; } .row.wrap { flex-wrap: wrap; } .col { display: flex; flex-direction: column; gap: 10px; }
.between { justify-content: space-between; } .sp { flex: 1; } .mt { margin-top: 16px; } .mb { margin-bottom: 16px; } .gap-s { gap: 6px; }
.ellipsis { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
hr { border: 0; border-top: 1px solid var(--line); margin: 16px 0; }

/* buttons & inputs */
.btn { display: inline-flex; align-items: center; gap: 7px; height: 32px; padding: 0 12px; border-radius: var(--r-sm); border: 1px solid var(--line-2); background: var(--bg-2); color: var(--fg); font: inherit; font-weight: 520; cursor: pointer; transition: all .15s var(--ease); white-space: nowrap; }
.btn:hover { background: var(--bg-3); } .btn:active { transform: scale(.97); }
.btn.primary { background: var(--fg); color: var(--bg); border-color: var(--fg); } .btn.primary:hover { opacity: .88; }
.btn.accent { background: var(--accent); color: white; border-color: var(--accent); } .btn.accent:hover { filter: brightness(1.08); }
.btn.ghost { border-color: transparent; background: transparent; } .btn.ghost:hover { background: var(--bg-3); }
.btn.danger { color: var(--bad); } .btn.good { color: var(--good); }
.btn.sm { height: 26px; padding: 0 9px; font-size: 12px; } .btn.icon { width: 32px; padding: 0; justify-content: center; }
.btn[disabled] { opacity: .5; pointer-events: none; }
.btn svg { width: 15px; height: 15px; }
input, select, textarea { font: inherit; color: var(--fg); background: var(--bg-2); border: 1px solid var(--line-2); border-radius: var(--r-sm); padding: 7px 10px; outline: none; transition: border-color .15s, box-shadow .15s; min-width: 0; }
input:focus, select:focus, textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
textarea { width: 100%; resize: vertical; line-height: 1.55; }
textarea.code { font-family: var(--mono); font-size: 12.5px; }
label.f { display: flex; flex-direction: column; gap: 5px; font-size: 12px; color: var(--fg-2); font-weight: 520; }
label.f input, label.f select { width: 100%; }
.search { width: 260px; }
.switch { position: relative; width: 34px; height: 20px; background: var(--line-2); border-radius: 20px; cursor: pointer; transition: background .2s; flex: none; border: 0; padding: 0; }
.switch::after { content: ''; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; background: white; border-radius: 50%; transition: transform .25s var(--ease); box-shadow: 0 1px 2px rgba(0,0,0,.2); }
.switch.on { background: var(--accent); } .switch.on::after { transform: translateX(14px); }

/* badges / pills */
.badge { display: inline-flex; align-items: center; gap: 4px; padding: 1px 8px; border-radius: 99px; font-size: 11.5px; font-weight: 560; background: var(--bg-3); color: var(--fg-2); white-space: nowrap; }
.badge.good { background: var(--good-soft); color: var(--good); } .badge.warn { background: var(--warn-soft); color: var(--warn); }
.badge.bad { background: var(--bad-soft); color: var(--bad); } .badge.accent { background: var(--accent-soft); color: var(--accent); }
.dot { width: 7px; height: 7px; border-radius: 50%; display: inline-block; background: currentColor; }
.pulse { animation: pulse 1.4s infinite; } @keyframes pulse { 50% { opacity: .35; } }

/* tables */
.tbl-wrap { overflow: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--bg-2); max-height: calc(100vh - 96px); }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th { position: sticky; top: 0; background: var(--bg-2); text-align: left; font-weight: 560; color: var(--fg-3); font-size: 12px; padding: 9px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; cursor: default; z-index: 1; }
th.sort { cursor: pointer; } th.sort:hover { color: var(--fg); }
td { padding: 8px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
tbody tr { transition: background .12s; } tbody tr:hover { background: var(--bg-3); }
tr.click { cursor: pointer; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
td .u { max-width: 420px; display: block; }

/* tabs */
.tabs { display: inline-flex; gap: 2px; background: var(--bg-3); padding: 3px; border-radius: 10px; position: relative; }
.tab { padding: 5px 12px; border-radius: 7px; cursor: pointer; color: var(--fg-2); font-weight: 520; font-size: 13px; transition: color .15s, background .2s var(--ease), box-shadow .2s; user-select: none; }
.tab.active { background: var(--bg-2); color: var(--fg); box-shadow: var(--shadow); }

/* score ring */
.ring { position: relative; display: grid; place-items: center; }
.ring svg { transform: rotate(-90deg); }
.ring circle { fill: none; stroke-linecap: round; }
.ring .track { stroke: var(--bg-3); }
.ring .bar { transition: stroke-dashoffset 1.1s var(--ease), stroke .3s; }
.ring .val { position: absolute; text-align: center; line-height: 1.1; }
.ring .val b { font-size: 28px; font-weight: 680; letter-spacing: -.03em; font-variant-numeric: tabular-nums; display: block; }
.ring .val span { font-size: 11px; color: var(--fg-3); }
.bar-h { height: 6px; background: var(--bg-3); border-radius: 6px; overflow: hidden; }
.bar-h > i { display: block; height: 100%; border-radius: 6px; background: var(--accent); transition: width .9s var(--ease); }

/* modal & drawer & toast */
.overlay { position: fixed; inset: 0; background: rgba(10,10,14,.38); backdrop-filter: blur(3px); z-index: 50; display: grid; place-items: center; animation: fade .2s var(--ease); }
@keyframes fade { from { opacity: 0; } }
.modal { background: var(--bg-2); border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow-lg); width: min(640px, 94vw); max-height: 90vh; overflow: auto; padding: 22px; animation: pop .28s var(--ease); }
.modal.wide { width: min(1100px, 96vw); }
.modal h2 { margin: 0 0 4px; font-size: 17px; letter-spacing: -.01em; }
@keyframes pop { from { opacity: 0; transform: translateY(10px) scale(.98); } }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(760px, 96vw); background: var(--bg-2); border-left: 1px solid var(--line); z-index: 51; box-shadow: var(--shadow-lg); overflow-y: auto; padding: 22px; animation: slideIn .32s var(--ease); }
@keyframes slideIn { from { transform: translateX(40px); opacity: 0; } }
.toasts { position: fixed; right: 18px; bottom: 18px; z-index: 60; display: flex; flex-direction: column; gap: 8px; width: 340px; }
.toast { background: var(--bg-2); border: 1px solid var(--line); border-radius: 12px; padding: 11px 14px; box-shadow: var(--shadow-lg); animation: toastIn .3s var(--ease); font-size: 13px; }
.toast.error { border-color: var(--bad); }
@keyframes toastIn { from { opacity: 0; transform: translateY(10px); } }
.job { font-size: 12px; } .job .bar-h { margin-top: 6px; height: 4px; }

/* misc */
.empty { text-align: center; padding: 50px 20px; color: var(--fg-3); }
.empty h3 { color: var(--fg); font-size: 15px; margin: 0 0 6px; justify-content: center; }
.skel { background: linear-gradient(90deg, var(--bg-3), var(--line), var(--bg-3)); background-size: 200% 100%; animation: shimmer 1.2s infinite; border-radius: 8px; }
@keyframes shimmer { to { background-position: -200% 0; } }
.md { line-height: 1.7; font-size: 14.5px; }
.md h1 { font-size: 24px; letter-spacing: -.02em; } .md h2 { font-size: 19px; margin-top: 1.6em; } .md h3 { font-size: 16px; }
.md table { border: 1px solid var(--line); margin: 12px 0; } .md th, .md td { border: 1px solid var(--line); position: static; }
.md img { max-width: 100%; border-radius: 10px; } .md code { background: var(--bg-3); padding: 1px 5px; border-radius: 4px; font-size: 12.5px; }
.md blockquote { border-left: 3px solid var(--accent); margin: 0; padding: 4px 14px; color: var(--fg-2); }
.kanban { display: grid; grid-template-columns: repeat(5, minmax(220px, 1fr)); gap: 12px; overflow-x: auto; }
.kcol { background: var(--bg-3); border-radius: var(--r); padding: 10px; min-height: 200px; }
.kcol h4 { margin: 2px 4px 10px; font-size: 12px; color: var(--fg-2); display: flex; justify-content: space-between; }
.kcard { background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px; padding: 10px; margin-bottom: 8px; cursor: pointer; transition: transform .15s var(--ease), box-shadow .15s; animation: cardIn .3s var(--ease) both; }
.kcard:hover { transform: translateY(-1px); box-shadow: var(--shadow-lg); }
.kcard .t { font-weight: 550; font-size: 13px; line-height: 1.35; }
.imgcard { overflow: hidden; padding: 0; }
.imgcard .ph { aspect-ratio: 3/2; background: var(--bg-3); display: grid; place-items: center; color: var(--fg-3); overflow: hidden; }
.imgcard .ph img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.imgcard:hover .ph img { transform: scale(1.03); }
.imgcard .body { padding: 12px; }
.map { height: 620px; border-radius: var(--r); overflow: hidden; border: 1px solid var(--line); z-index: 0; }
.gpin { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; color: white; font-weight: 700; font-size: 13px; border: 2px solid rgba(255,255,255,.9); box-shadow: 0 2px 8px rgba(0,0,0,.35); animation: pinIn .35s var(--ease) both; }
@keyframes pinIn { from { transform: scale(.3); opacity: 0; } }
.leaflet-container { background: var(--bg-3); font: inherit; }
:root[data-theme="dark"] .leaflet-tile-pane { filter: invert(1) hue-rotate(180deg) brightness(.85) contrast(.9); }
.timeline { position: relative; padding-left: 20px; }
.timeline::before { content: ''; position: absolute; left: 6px; top: 4px; bottom: 4px; width: 2px; background: var(--line); }
.tl-item { position: relative; padding: 0 0 16px; }
.tl-item::before { content: ''; position: absolute; left: -18px; top: 5px; width: 10px; height: 10px; border-radius: 50%; background: var(--bg-2); border: 2px solid var(--accent); }
.tl-item.done::before { background: var(--good); border-color: var(--good); }
.chip-in { display: flex; flex-wrap: wrap; gap: 6px; }
.sev-critical { color: var(--bad); } .sev-warning { color: var(--warn); } .sev-notice { color: var(--fg-3); }
.legend { display: flex; gap: 12px; flex-wrap: wrap; align-items: center; font-size: 12px; color: var(--fg-2); }
.legend i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; margin-right: 5px; vertical-align: -1px; }
.chart-box { position: relative; height: 220px; }
.chart-box.tall { height: 300px; }
.spark { display: block; }
pre.box { background: var(--bg-3); border-radius: var(--r-sm); padding: 12px; overflow: auto; font-size: 12px; max-height: 70vh; margin: 0; white-space: pre-wrap; word-break: break-word; }
.kbd { font-family: var(--mono); font-size: 11px; padding: 1px 5px; border: 1px solid var(--line-2); border-bottom-width: 2px; border-radius: 4px; color: var(--fg-2); }
.cmdk input { width: 100%; font-size: 15px; padding: 12px 14px; }
.cmdk .it { padding: 8px 12px; border-radius: 8px; cursor: pointer; display: flex; gap: 10px; align-items: center; }
.cmdk .it.sel, .cmdk .it:hover { background: var(--bg-3); }

/* agency branding + account switcher */
.brand { color: var(--fg); padding: 4px 8px 12px; gap: 10px; }
.brand:hover { text-decoration: none; }
.brand-logo { width: 34px; height: 34px; flex: none; object-fit: contain; filter: drop-shadow(0 2px 6px rgba(124,58,237,.25)); transition: transform .3s var(--ease); }
.brand:hover .brand-logo { transform: rotate(-6deg) scale(1.05); }
.switcher { position: relative; margin: 0 2px 6px; }
.sw-btn { width: 100%; display: flex; align-items: center; gap: 9px; padding: 7px 9px; border: 1px solid var(--line-2); border-radius: 10px; background: var(--bg); color: var(--fg); font: inherit; cursor: pointer; text-align: left; transition: border-color .15s, background .15s; }
.sw-btn:hover, .sw-btn[aria-expanded="true"] { border-color: var(--accent); background: var(--bg-3); }
.sw-btn > svg:last-child { color: var(--fg-3); flex: none; }
.sw-ic { width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); flex: none; }
.sw-txt { display: flex; flex-direction: column; min-width: 0; flex: 1; line-height: 1.25; }
.sw-txt b { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sw-txt span { font-size: 11.5px; color: var(--fg-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sw-pop { position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 40; background: var(--bg-2); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); padding: 8px; animation: pop .18s var(--ease); }
.sw-pop input { width: 100%; margin-bottom: 6px; }
.sw-list { max-height: 360px; overflow-y: auto; display: flex; flex-direction: column; gap: 2px; }
.sw-it { display: flex; align-items: center; gap: 9px; padding: 7px 8px; border-radius: 8px; cursor: pointer; }
.sw-it.sel { background: var(--bg-3); }
.sw-it.cur b { color: var(--accent); }
.sw-it > svg { color: var(--accent); flex: none; }
.nav.back { color: var(--fg-3); font-size: 12.5px; }
.cdot img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; padding: 12%; box-sizing: border-box; border-radius: inherit; }
.cdot.has-ico { box-shadow: inset 0 0 0 1px var(--line); }
.site-foot { position: fixed; right: 84px; bottom: 29px; z-index: 44; display: flex; gap: 6px; }
.foot-btn { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px; border-radius: 17px; border: 1px solid var(--line); background: var(--bg-2); color: var(--fg); font: inherit; font-size: 12.5px; font-weight: 550; cursor: pointer; box-shadow: var(--shadow); }
.foot-btn:hover { border-color: var(--accent); color: var(--accent); }
details.more { margin-top: 8px; }
details.more > summary { cursor: pointer; font-size: 13px; color: var(--fg-2); list-style-position: inside; display: flex; align-items: center; gap: 8px; min-width: 0; }
details.more > summary::before { content: '▸'; color: var(--fg-2); flex: none; transition: transform .15s; }
details.more[open] > summary::before { transform: rotate(90deg); }
details.more > summary::-webkit-details-marker { display: none; }
details.more.plan { border-top: 1px solid var(--line); padding: 10px 0 2px; margin-top: 0; }
details.more.plan > summary { color: var(--fg); font-size: 14px; }
details.more.task { margin: 6px 0 0 18px; }
.cite-n { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); font-size: 12px; font-weight: 700; flex: none; }
.smap { border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; margin-bottom: 8px; background: var(--bg-2); }
.smap summary { cursor: pointer; }
.smap-row { display: flex; align-items: center; gap: 8px; padding: 5px 0; border-top: 1px solid var(--line); color: inherit; text-decoration: none; font-size: 12.5px; }
.smap-row:first-of-type { margin-top: 8px; }
.smap-row:hover .mono { color: var(--accent); }
.cdot { position: relative; overflow: hidden; border-radius: 9px; display: inline-grid; place-items: center; color: #fff; font-weight: 700; flex: none; letter-spacing: .02em; line-height: 1; box-shadow: inset 0 0 0 1px rgba(255,255,255,.18); }
.ccard { display: flex; flex-direction: column; transition: transform .2s var(--ease), box-shadow .2s, border-color .2s; }
.ccard:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); border-color: var(--line-2); }
.ccard > .row:last-child { margin-top: auto; padding-top: 14px; }

/* google reviews */
.stars { letter-spacing: 1px; white-space: nowrap; line-height: 1; }
.stars i { font-style: normal; color: var(--line-2); }
.stars i.on { color: #f5b301; } .stars i.half { background: linear-gradient(90deg, #f5b301 50%, var(--line-2) 50%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.review { padding: 14px 0; border-bottom: 1px solid var(--line); }
.review:last-child { border-bottom: 0; }
.review .avatar { width: 32px; height: 32px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-weight: 700; flex: none; text-transform: uppercase; }
.review .rtext { margin-top: 6px; white-space: pre-wrap; overflow-wrap: anywhere; }
.review .owner { margin-top: 10px; padding: 10px 12px; border-left: 3px solid var(--accent); background: var(--bg-3); border-radius: 0 8px 8px 0; font-size: 13px; white-space: pre-wrap; }
.review .owner.draft { border-left-color: var(--good); }

/* clickable score rings + pillar breakdown */
.pillar-btn { background: none; border: 0; padding: 6px; margin: -6px; border-radius: 14px; color: inherit; font: inherit; cursor: pointer; transition: background .15s, transform .2s var(--ease); }
.pillar-btn:hover { background: var(--bg-3); transform: translateY(-2px); }
.pillar-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.pill-switch { gap: 6px; }
.chip { border: 1px solid var(--line-2); background: var(--bg-2); color: var(--fg-2); border-radius: 99px; padding: 3px 10px; font: inherit; font-size: 12px; cursor: pointer; }
.chip:hover { background: var(--bg-3); } .chip.on { background: var(--accent-soft); color: var(--accent); border-color: var(--accent); }
.factor { padding: 12px 0; border-bottom: 1px solid var(--line); }
.factor:last-child { border-bottom: 0; }
.factor .fix { margin-top: 6px; color: var(--fg-2); display: flex; gap: 6px; align-items: flex-start; }
.factor .fix svg { flex: none; margin-top: 2px; color: var(--accent); }
.factor .urls { display: flex; flex-direction: column; gap: 3px; margin-top: 6px; max-height: 60vh; overflow: auto; font-size: 12px; padding: 8px; background: var(--bg-3); border-radius: 8px; }
.win { display: flex; gap: 10px; align-items: baseline; padding: 8px 12px; border-radius: 10px; background: var(--good-soft); font-size: 13px; }
.win b { color: var(--good); white-space: nowrap; }

/* connections */
.conn { display: flex; flex-direction: column; gap: 8px; }
.conn-dot { width: 10px; height: 10px; border-radius: 50%; margin-top: 5px; flex: none; background: var(--line-2); }
.conn-dot.ok { background: var(--good); box-shadow: 0 0 0 4px var(--good-soft); } .conn-dot.warn { background: var(--warn); box-shadow: 0 0 0 4px var(--warn-soft); }
.conn-dot.error { background: var(--bad); box-shadow: 0 0 0 4px var(--bad-soft); }
.conn-msg { overflow-wrap: anywhere; }
.conn-meta { display: flex; flex-direction: column; gap: 2px; }

/* goals: before → now → target */
.ba { display: flex; flex-direction: column; gap: 10px; }
.ba-row { display: flex; align-items: stretch; gap: 10px; flex-wrap: wrap; }
.ba-cell { flex: 1; min-width: 110px; background: var(--bg-3); border-radius: 10px; padding: 10px 12px; }
.ba-cell.now { background: var(--accent-soft); }
.ba-cell .l { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--fg-3); }
.ba-cell .v { font-size: 22px; font-weight: 650; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.ba-arrow { align-self: center; color: var(--fg-3); font-size: 18px; }
.ba-who { flex: 1.3; min-width: 200px; display: flex; flex-direction: column; justify-content: center; gap: 3px; padding-left: 6px; }
.win-row { display: flex; gap: 10px; align-items: flex-start; padding: 9px 10px; border-radius: 10px; background: var(--bg-3); color: inherit; }
.win-row:hover { text-decoration: none; background: var(--accent-soft); }
.tm-sum { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 18px; }
.tm-sum > div { display: flex; gap: 8px; align-items: baseline; font-size: 13px; }
@media (max-width: 900px) { .tm-sum { grid-template-columns: 1fr; } }

/* Ask Claude chat, docked bottom-right on every screen */
.chat-list { flex: 1; overflow-y: auto; padding: 12px; display: flex; flex-direction: column; gap: 8px; }
.chat-msg { max-width: 92%; padding: 8px 11px; border-radius: 12px; font-size: 13px; line-height: 1.5; overflow-wrap: anywhere; }
.chat-msg.you { align-self: flex-end; background: var(--accent); color: #fff; border-bottom-right-radius: 4px; white-space: pre-wrap; }
.chat-msg.claude { align-self: flex-start; background: var(--bg-3); border-bottom-left-radius: 4px; }
.chat-msg.err { align-self: flex-start; background: var(--bad-soft); color: var(--bad); }
.chat-msg.md { font-size: 13px; } .chat-msg.md h1, .chat-msg.md h2, .chat-msg.md h3 { font-size: 14px; margin: .6em 0 .3em; } .chat-msg.md p { margin: .4em 0; } .chat-msg.md ul, .chat-msg.md ol { margin: .4em 0; padding-left: 18px; } .chat-msg.md table { font-size: 12px; }
.chat-suggest { text-align: left; border: 1px solid var(--line-2); background: var(--bg-2); color: var(--fg-2); border-radius: 10px; padding: 7px 10px; font: inherit; font-size: 12.5px; cursor: pointer; }
.chat-suggest:hover { border-color: var(--accent); color: var(--fg); }
.chat-input { display: flex; gap: 8px; align-items: flex-end; padding: 10px; border-top: 1px solid var(--line); }
.chat-input textarea { flex: 1; resize: none; }
/* keep notifications clear of the chat button */
.toasts { bottom: 84px; }

/* usage & budgets */
.meter { height: 8px; background: var(--bg-3); border-radius: 8px; overflow: hidden; }
.meter > i { display: block; height: 100%; border-radius: 8px; transition: width .8s var(--ease); }
.svc-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 6px; vertical-align: 1px; }

/* time machine: Then | Now */
.tm-cmp-head, .tm-row { display: grid; grid-template-columns: minmax(180px, 1.5fr) 1fr 1fr 110px; gap: 0 14px; align-items: center; }
.tm-cmp-head { padding-bottom: 0; border-bottom: 2px solid var(--line); }
.tm-cmp-head .then, .tm-row .then { background: var(--bg-3); padding: 7px 12px; }
.tm-cmp-head .now, .tm-row .now { background: var(--accent-soft); padding: 7px 12px; }
.tm-cmp-head .then, .tm-cmp-head .now { border-radius: 10px 10px 0 0; padding-top: 10px; padding-bottom: 10px; }
.tm-lbl { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: var(--fg-3); }
.tm-sec { font-size: 12px; font-weight: 650; color: var(--fg-2); padding: 14px 0 6px; }
.tm-row { border-bottom: 1px solid var(--line); font-size: 13px; }
.tm-row .l { padding: 7px 0; } .tm-row .chg { text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; }
.tm-row .then, .tm-row .now { align-self: stretch; display: flex; align-items: center; font-variant-numeric: tabular-nums; font-size: 14px; }
.tm-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.tm-side { border-radius: 10px; padding: 10px 12px; min-width: 0; } .tm-side.then { background: var(--bg-3); } .tm-side.now { background: var(--accent-soft); }
.tm-f { font-size: 12.5px; margin-top: 6px; overflow-wrap: anywhere; } .tm-f > span { font-size: 11px; } .tm-f .chg { font-weight: 600; }
@media (max-width: 900px) { .tm-pair { grid-template-columns: 1fr; } .tm-cmp-head, .tm-row { grid-template-columns: 1.2fr 1fr 1fr 70px; } }

/* page links that open the page view, previews, "why" buttons, citations, client view */
.plink { display: inline-flex; align-items: center; gap: 5px; min-width: 0; max-width: 100%; } .plink > a:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.plink-ext { color: var(--fg-3); flex: none; display: inline-flex; } .plink-ext:hover { color: var(--accent); }
.urls .plink { display: flex; }
.shot { position: relative; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; background: var(--bg-3); aspect-ratio: 16 / 10; }
.shot.small { max-width: 420px; }
.shot img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.shot-msg { position: absolute; inset: 0; display: flex; flex-direction: column; gap: 8px; align-items: center; justify-content: center; font-size: 12px; color: var(--fg-2); text-align: center; padding: 12px; }
button.cat-btn { font: inherit; color: inherit; text-align: left; cursor: pointer; display: block; width: 100%; } button.cat-btn.col { display: flex; text-align: center; }
button.cat-btn:focus-visible, button.badge:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
button.badge { border: 0; font: inherit; font-size: 11.5px; }
.nap-tick { display: inline-flex; width: 22px; height: 22px; border-radius: 6px; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; background: var(--bg-3); color: var(--fg-3); }
.nap-tick.yes { background: var(--good-soft); color: var(--good); } .nap-tick.no { background: var(--bad-soft); color: var(--bad); }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
tr.grp td { background: var(--bg-3); font-size: 11.5px; font-weight: 650; letter-spacing: .04em; text-transform: uppercase; color: var(--fg-2); padding-top: 7px; padding-bottom: 7px; }

/* six-month history table */
table.six td.est { font-style: italic; color: var(--fg-2); } .est { font-style: italic; }
table.six td:first-child { font-weight: 550; white-space: nowrap; }

/* Geo Grid: new scan on the left, the map in the middle, previous scans on the right */
.geo3 { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 14px; align-items: start; }
/* Geo Grid: the map fills the screen; the summary floats on it at the left, competitors and previous scans sit on the right */
.geo-bar { display: flex; align-items: center; gap: 10px; padding: 8px 12px; flex-wrap: wrap; }
.geo-date { font-size: 15px; white-space: nowrap; } .geo-head { flex: 1 1 300px; min-width: 0; }
.geo-main { display: flex; flex-direction: column; gap: 10px; min-height: calc(100vh - 86px); } .geo-main > .geo-stage { flex: 1 1 auto; min-height: 480px; }
.geo-stage { position: relative; border-radius: var(--r); overflow: hidden; border: 1px solid var(--line); background: var(--bg-3); }
.geo-stage > [data-grid-map] { position: absolute; inset: 0; } .geo-stage .map { height: 100% !important; border: 0; border-radius: 0; }
.geo-float { position: absolute; z-index: 5; top: 12px; left: 12px; width: 300px; max-height: calc(100% - 24px); overflow-y: auto; gap: 10px; }
.geo-float .card { box-shadow: var(--shadow-lg); }
.geo-legend { position: absolute; z-index: 5; left: 324px; right: 58px; bottom: 26px; background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px; padding: 6px 10px; box-shadow: var(--shadow-lg); }
.geo-tile { flex: 1; border-radius: 10px; padding: 10px 8px; text-align: center; background: var(--bg-3); font-size: 12px; color: var(--fg-2); } .geo-tile b { display: block; font-size: 21px; color: var(--fg); font-variant-numeric: tabular-nums; }
.donut { width: 96px; height: 96px; border-radius: 50%; flex: none; -webkit-mask: radial-gradient(circle, transparent 37%, #000 38%); mask: radial-gradient(circle, transparent 37%, #000 38%); }
.comp { display: flex; gap: 10px; align-items: center; padding: 9px 6px; border-top: 1px solid var(--line); } .comp.you { background: color-mix(in srgb, #f59e0b 14%, transparent); border-radius: 8px; border-top-color: transparent; }
.comp { cursor: pointer; } .comp:hover { background: var(--bg-3); border-radius: 8px; } .comp.on { background: var(--accent-soft); border-radius: 8px; box-shadow: 0 0 0 1px var(--accent) inset; } .comp:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.comp-n { width: 22px; text-align: center; color: var(--fg-3); font-size: 12px; flex: none; }
.geo-right .geo-scans { position: static; max-height: none; }
@media print { .side, .topbar, .geo-right, .geo-bar, .toasts { display: none !important; } .app { display: block; height: auto; } .main { overflow: visible; } .geo3 { display: block; } }
.geo3 > .geo-side { position: sticky; top: 64px; max-height: calc(100vh - 74px); overflow-y: auto; }
.geo-step { display: flex; align-items: center; gap: 8px; font-weight: 600; font-size: 13px; margin-top: 4px; }
.geo-step > b { width: 20px; height: 20px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-size: 11.5px; flex: none; }
.geo-step > .muted { font-weight: 400; font-size: 12px; }
.geo-area { display: flex; align-items: center; gap: 8px; padding: 5px 6px 5px 8px; border-radius: 8px; background: var(--bg-3); font-size: 12.5px; cursor: pointer; }
.geo-stats { display: flex; flex-wrap: wrap; gap: 6px 22px; padding: 9px 14px; border: 1px solid var(--line); border-radius: var(--r); background: var(--bg-2); }
.geo-stats > div { display: flex; align-items: baseline; gap: 6px; min-width: 0; }
.geo-stats .l { color: var(--fg-3); font-size: 12px; } .geo-stats b { font-size: 16px; font-variant-numeric: tabular-nums; } .geo-stats .s { color: var(--fg-3); font-size: 11.5px; }
.geo-stats b.up, .geo-stats .s.up { color: var(--good); } .geo-stats b.down { color: var(--bad); }
.scan-list { display: flex; flex-direction: column; gap: 6px; }
.scan-card { display: flex; gap: 10px; align-items: center; padding: 7px 8px; border-radius: 10px; border: 1px solid var(--line); background: var(--bg-2); cursor: pointer; transition: border-color .15s, background .15s; }
.scan-card:hover { border-color: var(--line-2); background: var(--bg-3); }
.scan-card.active { border-color: var(--accent); background: var(--accent-soft); }
.scan-card.picked { outline: 2px dashed var(--accent); outline-offset: 1px; }
.scan-thumb { flex: none; border-radius: 8px; background: var(--bg-3); display: grid; place-items: center; font-weight: 700; font-size: 13px; }
@media (max-width: 1280px) {
  .geo3 { grid-template-columns: minmax(0, 1fr) 280px; }
}
@media (max-width: 900px) { .geo3 { grid-template-columns: 1fr; } .geo3 > .geo-side { position: static; max-height: none; }
  .geo-main { min-height: 0; } .geo-main > .geo-stage { min-height: 0; }
  .geo-stage { height: auto !important; display: flex; flex-direction: column; overflow: visible; border: 0; background: none; gap: 10px; }
  .geo-stage > [data-grid-map] { position: static; height: 62vh; order: 2; border-radius: var(--r); overflow: hidden; border: 1px solid var(--line); }
  .geo-float { position: static; width: auto; max-height: none; order: 1; } .geo-float .card { box-shadow: none; }
  .geo-legend { position: static; order: 3; box-shadow: none; } }
button.cat-btn.on { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent) inset; }
/* Rankings: where every keyword stands, as clickable groups */
.rank-bands { display: grid; grid-template-columns: repeat(auto-fit, minmax(128px, 1fr)); gap: 8px; }
button.rank-band { border: 1px solid var(--line); background: var(--bg-2); border-radius: 10px; padding: 8px 10px; }
button.rank-band:hover { background: var(--bg-3); }
.rank-band .v { font-size: 20px; font-weight: 650; font-variant-numeric: tabular-nums; display: flex; align-items: center; gap: 7px; }
.rank-band .v i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; border: 1px solid var(--line-2); }
.rank-band .l { font-size: 12.5px; font-weight: 600; } .rank-band .s { font-size: 11.5px; color: var(--fg-3); }
.badge.pos { font-size: 13px; padding: 2px 10px; min-width: 38px; justify-content: center; }
.geo-area.on { outline: 2px solid var(--accent); }

.scan-kw { font-weight: 600; font-size: 13px; line-height: 1.25; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }

/* top-bar tools (were floating over the page) */
.site-foot { position: static; right: auto; bottom: auto; display: flex; gap: 6px; flex-wrap: wrap; }
.foot-btn { height: 30px; padding: 0 10px; box-shadow: none; font-size: 12px; }
.menu-btn { display: none; }
.kcol { max-height: calc(100vh - 96px); overflow-y: auto; }
/* Recommendations */
.diag-phase { font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--fg-3); font-weight: 650; margin: 14px 2px 8px; }
.diag-step { padding: 0; margin-bottom: 8px; overflow: hidden; }
.diag-step > button { padding: 12px 14px; border: 0; background: none; }
.diag-step > button:hover { background: var(--bg-3); }
.diag-step.open { border-color: var(--accent); }
.diag-n { width: 28px; height: 28px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-weight: 700; font-size: 13px; flex: none; }
.diag-body { padding: 4px 16px 16px 54px; display: grid; gap: 12px; font-size: 13.5px; }
.diag-body .l { font-size: 11.5px; text-transform: uppercase; letter-spacing: .04em; color: var(--fg-3); font-weight: 650; margin-bottom: 2px; }
button.diag-area { border: 0; background: none; padding: 6px 6px; border-radius: 8px; margin-bottom: 4px; }
button.diag-area:hover:not(:disabled) { background: var(--bg-3); } button.diag-area:disabled { cursor: default; opacity: .7; }
/* Ask Claude: conversations on the left, the thread in the middle, what Claude can do on the right; each column scrolls by itself */
:root { --asst-off: 86px; }
.asst { display: grid; grid-template-columns: 260px minmax(0, 1fr) 330px; gap: 14px; height: calc(100vh - var(--asst-off)); min-height: 440px; }
.asst-col { display: flex; flex-direction: column; min-height: 0; min-width: 0; padding: 12px; }
.asst-scroll { flex: 1; min-height: 0; overflow-y: auto; }
.asst-item { display: block; width: 100%; text-align: left; font: inherit; color: inherit; background: none; border: 0; border-radius: 8px; padding: 7px 8px; cursor: pointer; }
.asst-item:hover { background: var(--bg-3); } .asst-item.on { background: var(--accent-soft); }
.asst-item:focus-visible, .asst-star:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }
.asst-head { display: flex; align-items: center; gap: 6px; padding-bottom: 10px; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.asst-msgs { flex: 1; min-height: 0; padding: 12px 4px; }
.asst-msgs .chat-msg { max-width: 88%; font-size: 14px; } .asst-msgs .chat-msg.claude .md { font-size: 14px; line-height: 1.6; }
.asst-msgs .md h1, .asst-msgs .md h2, .asst-msgs .md h3 { font-size: 15px; margin: .7em 0 .3em; } .asst-msgs .md p { margin: .45em 0; } .asst-msgs .md ul, .asst-msgs .md ol { margin: .45em 0; padding-left: 20px; }
.asst-msgs .md table { font-size: 13px; display: block; overflow-x: auto; }
.asst-meta { display: flex; align-items: center; gap: 6px; margin-top: 6px; border-top: 1px solid var(--line); padding-top: 4px; } .asst-meta .sp { flex: 1; }
.asst-star { background: none; border: 0; color: inherit; opacity: .75; cursor: pointer; font: inherit; margin-left: 6px; padding: 0 2px; } .asst-star:hover { opacity: 1; }
.asst-intro { padding: 4px 2px; }
.asst-input { border-top: 1px solid var(--line); padding-top: 10px; }
.asst-tool { border: 1px solid var(--line); border-radius: 10px; padding: 9px 10px; margin-bottom: 8px; } .asst-tool .sp { flex: 1; }
@media (max-width: 1250px) { .asst { grid-template-columns: 220px minmax(0, 1fr); } .asst-side { grid-column: 1 / -1; max-height: 420px; } .asst { height: auto; } .asst-thread { height: calc(100vh - var(--asst-off)); min-height: 440px; } .asst-list { height: calc(100vh - var(--asst-off)); min-height: 440px; } }
/* phones and narrow windows: one column, a menu button, nothing wider than the screen */
@media (max-width: 900px) {
  .menu-btn { display: inline-flex; }
  body.nav-open .side { display: flex; position: fixed; inset: 0 auto 0 0; width: 270px; max-width: 86vw; z-index: 70; overflow-y: auto; box-shadow: var(--shadow-lg); background: var(--bg-2); }
  .grid[style*="grid-template-columns"], .geo3 { grid-template-columns: minmax(0, 1fr) !important; }
  .geo3 > .geo-side { position: static; max-height: none; }
  .topbar { flex-wrap: wrap; gap: 8px; }
  .topbar h1 { font-size: 15px; }
  .topbar .sp { display: none; }
  .page { max-width: 100vw; overflow-x: hidden; }
  .card { min-width: 0; }
  .tbl-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .modal, .modal.wide { width: calc(100vw - 16px); max-width: none; max-height: 92vh; }
  .drawer { width: 100vw; max-width: 100vw; }
  .kanban { grid-template-columns: repeat(5, 240px); }
  .rank-bands { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .search { width: 100%; }
  .diag-body { padding-left: 16px; }
  .row.wrap > .btn, .row.wrap > select { flex: 0 1 auto; }
  .asst { grid-template-columns: minmax(0, 1fr); height: auto; }
  .asst-col { max-height: none; } .asst-list .asst-scroll { max-height: 220px; } .asst-msgs { min-height: 260px; max-height: 60vh; }
  .ask-btn { order: 5; }
}
.geo-float [data-new-scan] > button.accent { position: sticky; bottom: 0; z-index: 1; box-shadow: 0 -10px 12px var(--bg-2); }

/* the strategy on a map: a big map with numbered pins that match the list */
.sm-grid { grid-template-columns: minmax(0, 1fr) 460px; gap: 14px; align-items: start; }
.sm-pin { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 15px; border: 2.5px solid #fff; box-shadow: 0 2px 8px rgba(0,0,0,.4); }
.sm-pin.on { transform: scale(1.25); box-shadow: 0 0 0 3px #111, 0 2px 10px rgba(0,0,0,.5); }
.sm-biz { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; background: #111827; color: #fbbf24; font-size: 17px; border: 2px solid #fff; box-shadow: 0 2px 8px rgba(0,0,0,.4); }
.leaflet-tooltip { font-size: 13px; }
@media (max-width: 1250px) { .sm-grid { grid-template-columns: minmax(0, 1fr); } }
@media print { .tbl-wrap { max-height: none !important; overflow: visible !important; } .drawer { position: static; width: auto; box-shadow: none; } .overlay { position: static; background: none; } }

/* speak instead of typing: a microphone at the right edge of the text box that has the cursor */
.mic-btn { position: fixed; z-index: 9999; width: 26px; height: 26px; border-radius: 50%; border: 1px solid var(--line); background: var(--bg-2); color: var(--fg-2); display: grid; place-items: center; cursor: pointer; padding: 0; box-shadow: 0 1px 4px rgba(0,0,0,.18); }
.mic-btn:hover { color: var(--accent); border-color: var(--accent); }
.mic-btn.on { background: #dc2626; border-color: #dc2626; color: #fff; animation: micPulse 1.2s ease-in-out infinite; }
@keyframes micPulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(220,38,38,.55); } 50% { box-shadow: 0 0 0 7px rgba(220,38,38,0); } }
@media print { .mic-btn { display: none !important; } }

/* Map / Satellite switch in the corner of every map */
.map-bg { display: flex; background: var(--bg-2); border: 1px solid var(--line); border-radius: 9px; padding: 2px; box-shadow: 0 1px 6px rgba(0,0,0,.25); }
.map-bg button { border: 0; background: none; color: var(--fg-2); font: inherit; font-size: 12.5px; font-weight: 600; padding: 5px 10px; border-radius: 7px; cursor: pointer; }
.map-bg button.on { background: var(--accent); color: #fff; }

/* the menu shrunk to icons (the arrow at the bottom left) */
.app.mini { grid-template-columns: 58px 1fr; }
.app.mini .side { padding: 14px 8px; align-items: center; }
.app.mini .nav-l, .app.mini .brand > span, .app.mini .sw-txt, .app.mini .sw-btn > svg:last-child, .app.mini [data-viewer], .app.mini .side-foot .small, .app.mini .side-foot .btn.sm { display: none; }
.app.mini .nav { justify-content: center; padding: 9px 0; width: 40px; }
.app.mini .nav svg { width: 18px; height: 18px; }
.app.mini .nav .badge { position: absolute; top: 2px; right: 0; margin: 0; padding: 0 4px; font-size: 10px; }
.app.mini .nav-group { font-size: 0; padding: 0; margin: 8px 6px; height: 1px; width: 26px; background: var(--line); }
.app.mini .brand { padding: 4px 0 12px; justify-content: center; }
.app.mini .sw-btn { padding: 6px; justify-content: center; width: 40px; }
.app.mini .side-foot { flex-direction: column; }
@media (max-width: 900px) { .app.mini { grid-template-columns: 1fr; } }

/* progress cards in the corner can be shrunk to one pill */
.job-pill { cursor: pointer; font: inherit; font-size: 12.5px; font-weight: 600; color: var(--fg); padding: 7px 12px; border-radius: 999px; display: inline-flex; align-items: center; gap: 7px; }
.job-min { box-shadow: 0 1px 4px rgba(0,0,0,.15); background: var(--bg-2); }

/* alerts bell in the top bar */
.alert-dot { position: absolute; top: -3px; right: -3px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 999px; background: #dc2626; color: #fff; font-size: 10px; font-weight: 700; display: grid; place-items: center; }
.alert-pop { position: absolute; right: 0; top: calc(100% + 8px); z-index: 60; width: 360px; max-width: 86vw; max-height: 60vh; overflow-y: auto; background: var(--bg-2); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow-lg); padding: 12px 14px; }

/* Simple / Advanced switch at the bottom of the menu */
.view-mode { margin-top: auto; display: flex; background: var(--bg-3); border-radius: 9px; padding: 2px; }
.view-mode button { flex: 1; border: 0; background: none; color: var(--fg-2); font: inherit; font-size: 12.5px; font-weight: 600; padding: 6px 8px; border-radius: 7px; cursor: pointer; }
.view-mode button.on { background: var(--bg-2); color: var(--fg); box-shadow: 0 1px 3px rgba(0,0,0,.15); }
.app.mini .view-mode { flex-direction: column; width: 40px; } .app.mini .view-mode button { font-size: 0; padding: 7px 0; } .app.mini .view-mode button::before { font-size: 12px; } .app.mini .view-mode button[data-mode="simple"]::before { content: 'S'; } .app.mini .view-mode button[data-mode="advanced"]::before { content: 'A'; }
