[hidden] { display: none !important; }
@font-face { font-family: 'Montserrat'; font-weight: 400; font-display: swap; src: url('/static/fonts/montserrat-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Montserrat'; font-weight: 500; font-display: swap; src: url('/static/fonts/montserrat-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family: 'Montserrat'; font-weight: 600; font-display: swap; src: url('/static/fonts/montserrat-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Montserrat'; font-weight: 700 800; font-display: swap; src: url('/static/fonts/montserrat-latin-700-normal.woff2') format('woff2'); }
@font-face { font-family: 'Archivo Black'; font-weight: 400; font-display: swap; src: url('/static/fonts/archivo-black-latin-400-normal.woff2') format('woff2'); }
:root {
  /* Brandwell Studios brand: cyan #04D9D9, gray #737373, navy #1E265B, black, white */
  --cyan: #04D9D9; --navy: #1E265B; --gray: #737373;
  --bg: #f4f5f7; --card: #fff; --ink: #14161c; --muted: #737373; --line: #e2e5ea;
  --accent: #1E265B; --accent-soft: #e2fbfb; --good: #12a150; --bad: #dc2626; --warn: #d97706;
  --radius: 10px; --shadow: 0 1px 2px rgba(16,24,40,.06), 0 1px 3px rgba(16,24,40,.08);
}
* { box-sizing: border-box; }
body { margin: 0; font: 14px/1.5 'Montserrat', system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: var(--ink); background: var(--bg); }
h1 { font-family: 'Archivo Black', 'Montserrat', sans-serif; font-weight: 400; font-size: 24px; margin: 0; letter-spacing: .01em; }
h2 { font-size: 16px; margin: 0 0 8px; }
.sub { color: var(--muted); margin: 2px 0 0; font-size: 13px; }
input, select { font: inherit; padding: 7px 9px; border: 1px solid var(--line); border-radius: 7px; background: #fff; color: var(--ink); }
input:focus, select:focus { outline: 2px solid var(--accent-soft); border-color: var(--accent); }
label { display: block; font-weight: 600; font-size: 13px; }
label input, label select { display: block; width: 100%; margin-top: 4px; font-weight: 400; }
label.inline { display: inline-flex; align-items: center; gap: 6px; font-weight: 500; }
label.inline input { width: auto; margin: 0; }

.btn { font: inherit; font-weight: 600; padding: 8px 14px; border-radius: 8px; border: 1px solid var(--line); background: #fff; color: var(--ink); cursor: pointer; white-space: nowrap; }
.btn:hover { background: #f0f2f5; }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary:hover { background: #141a44; }
.btn.danger { color: var(--bad); }
.btn.small { padding: 5px 10px; font-size: 12.5px; }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.link { background: none; border: 0; color: var(--accent); font: inherit; cursor: pointer; text-decoration: none; padding: 0; }

/* Top bar */
.topbar { display: flex; align-items: center; gap: 28px; padding: 0 24px; height: 68px; background: #000; color: #fff; position: sticky; top: 0; z-index: 10; border-bottom: 3px solid var(--cyan); }
.logo { display: flex; align-items: center; gap: 12px; white-space: nowrap; }
.logo img { height: 50px; display: block; }
.logo span { font-size: 12px; font-weight: 600; letter-spacing: .22em; text-transform: uppercase; color: var(--cyan); border-left: 1px solid #333; padding-left: 12px; }
#tabs { display: flex; gap: 4px; height: 100%; }
#tabs button { background: none; border: 0; color: rgba(255,255,255,.7); font: inherit; font-weight: 600; padding: 0 14px; cursor: pointer; border-bottom: 3px solid transparent; }
#tabs button.active { color: #fff; border-bottom-color: var(--cyan); }
#tabs button:hover { color: #fff; }
.topbar-right { margin-left: auto; display: flex; gap: 18px; }
.topbar-right .link { color: rgba(255,255,255,.8); }

main { max-width: 1240px; margin: 0 auto; padding: 24px; }
.tab { display: none; }
.tab.active { display: block; }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }

/* Screens */
.screen-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 16px; }
.screen-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column; }
.screen-preview { aspect-ratio: 16 / 9; background: #000; position: relative; display: flex; align-items: center; justify-content: center; color: #8a96ab; font-size: 13px; }
.screen-preview img, .screen-preview video { width: 100%; height: 100%; object-fit: contain; }
.screen-preview .badge { position: absolute; left: 10px; top: 10px; }
.screen-body { padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.screen-title { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.screen-title h2 { margin: 0; font-size: 16px; }
.badge { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; padding: 3px 9px; border-radius: 999px; background: #fff; border: 1px solid var(--line); }
.badge::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--muted); }
.badge.online::before { background: var(--good); }
.badge.offline { color: var(--bad); }
.badge.paused { color: var(--warn); }
.badge.paused::before { background: var(--warn); }
.badge.offline::before { background: var(--bad); }
.kv { display: grid; grid-template-columns: 92px 1fr; gap: 4px 10px; font-size: 13px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.screen-actions { display: flex; flex-wrap: wrap; gap: 6px; border-top: 1px solid var(--line); padding-top: 10px; }
.empty { background: var(--card); border: 1px dashed #c9cfd8; border-radius: var(--radius); padding: 36px; text-align: center; color: var(--muted); }
.empty strong { color: var(--ink); display: block; margin-bottom: 4px; font-size: 15px; }

/* Media */
.dropzone { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 28px; border: 2px dashed #b9c3d3; border-radius: var(--radius); background: #fff; cursor: pointer; font-weight: 400; text-align: center; margin-bottom: 16px; transition: .15s; }
.dropzone.over { border-color: var(--cyan); background: var(--accent-soft); }
.progress { width: 60%; height: 6px; border-radius: 3px; background: #e6e9ef; overflow: hidden; margin-top: 10px; display: none; }
.progress div { height: 100%; width: 0; background: var(--cyan); transition: width .2s; }
.search { width: 280px; margin-bottom: 14px; }
.media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 14px; }
.media-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); position: relative; }
.media-card.selectable { cursor: pointer; }
.media-card.selected { outline: 3px solid var(--cyan); }
.thumb { aspect-ratio: 16 / 9; background: #000; display: flex; align-items: center; justify-content: center; color: #c9d3e3; font-size: 12px; font-weight: 600; overflow: hidden; }
.thumb img, .thumb video { width: 100%; height: 100%; object-fit: cover; }
.thumb.web { background: linear-gradient(135deg, #3a3a3a, #111); }
.thumb.inventory { background: linear-gradient(135deg, #1E265B, #0b0f26); color: var(--cyan); }
.thumb.weather { background: linear-gradient(135deg, #1E265B, #04D9D9); color: #fff; }
.media-info { padding: 9px 10px; }
.media-name { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.media-meta { color: var(--muted); font-size: 12px; display: flex; justify-content: space-between; margin-top: 2px; }
.media-tools { display: flex; flex-wrap: wrap; gap: 4px 10px; margin-top: 6px; font-size: 12.5px; }
.media-tools .link { white-space: nowrap; }
.type-tag { position: absolute; top: 8px; right: 8px; background: rgba(0,0,0,.8); color: #fff; font-size: 11px; font-weight: 700; padding: 2px 7px; border-radius: 5px; text-transform: uppercase; letter-spacing: .03em; }

/* Playlists */
.playlist-layout { display: grid; grid-template-columns: 260px 1fr; gap: 18px; align-items: start; }
.playlist-list { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.playlist-list button { display: block; width: 100%; text-align: left; background: none; border: 0; border-bottom: 1px solid var(--line); padding: 12px 14px; font: inherit; cursor: pointer; }
.playlist-list button:last-child { border-bottom: 0; }
.playlist-list button.active { background: var(--accent-soft); box-shadow: inset 4px 0 0 var(--cyan); }
.playlist-list .meta { color: var(--muted); font-size: 12px; }
.playlist-editor { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; min-height: 240px; }
.pl-head { display: flex; gap: 10px; align-items: center; margin-bottom: 6px; }
.pl-head input { font-size: 18px; font-weight: 700; flex: 1; border-color: transparent; padding-left: 4px; }
.pl-head input:hover { border-color: var(--line); }
.saved { color: var(--good); font-size: 12px; font-weight: 600; min-width: 60px; text-align: right; }
.items { margin: 14px 0; border: 1px solid var(--line); border-radius: 8px; }
.item { display: grid; grid-template-columns: 22px 28px 96px 1fr 150px 96px 70px; gap: 12px; align-items: center; padding: 8px 12px; border-bottom: 1px solid var(--line); background: #fff; }
.item:last-child { border-bottom: 0; }
.item.dragging { opacity: .4; }
.item.drop-above { box-shadow: inset 0 3px 0 var(--accent); }
.item .grip { cursor: grab; color: #9aa3b2; font-size: 18px; text-align: center; user-select: none; }
.item .num { color: var(--muted); font-variant-numeric: tabular-nums; }
.item .thumb { width: 96px; border-radius: 5px; font-size: 10px; }
.item .dur { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--muted); }
.item .dur input { width: 64px; }
.item .row-tools { display: flex; gap: 2px; justify-content: flex-end; }
.icon-btn { background: none; border: 0; cursor: pointer; color: var(--muted); font-size: 16px; padding: 2px 5px; border-radius: 5px; }
.icon-btn:hover { background: #eef1f5; color: var(--ink); }

/* Reports */
table { width: 100%; border-collapse: collapse; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); font-size: 13px; }
th { background: #f4f5f7; color: var(--muted); font-weight: 600; font-size: 12px; text-transform: uppercase; letter-spacing: .03em; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }

/* Modal + toast */
.modal { position: fixed; inset: 0; background: rgba(15,23,42,.45); display: flex; align-items: center; justify-content: center; z-index: 100; padding: 20px; }
.modal[hidden] { display: none; }
.modal-card { background: #fff; border-radius: 12px; width: min(560px, 100%); max-height: 90vh; overflow: auto; padding: 22px; box-shadow: 0 20px 50px rgba(0,0,0,.25); }
.modal-card.wide { width: min(980px, 100%); }
.modal-card h2 { font-size: 18px; margin-bottom: 14px; }
.modal-card form > * + * { margin-top: 12px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.help { color: var(--muted); font-size: 12.5px; font-weight: 400; margin-top: 4px; }
.error { color: var(--bad); font-size: 13px; min-height: 1em; }
.rule { display: grid; grid-template-columns: 1fr auto; gap: 10px; border: 1px solid var(--line); border-radius: 8px; padding: 12px; }
.rule + .rule { margin-top: 10px; }
.rule-row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.days { display: flex; gap: 4px; }
.days label { display: inline-flex; }
.days input { display: none; }
.days span { display: inline-block; width: 34px; text-align: center; padding: 5px 0; border: 1px solid var(--line); border-radius: 6px; font-size: 12px; font-weight: 600; cursor: pointer; color: var(--muted); }
.days input:checked + span { background: var(--navy); border-color: var(--navy); color: #fff; }
.geo-results button { display: block; width: 100%; text-align: left; padding: 8px 10px; border: 1px solid var(--line); border-radius: 7px; background: #fff; margin-top: 6px; cursor: pointer; font: inherit; }
.geo-results button.selected { border-color: var(--accent); background: var(--accent-soft); }
.toast { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%) translateY(20px); background: #000; border-left: 4px solid var(--cyan); color: #fff; padding: 10px 16px; border-radius: 8px; opacity: 0; transition: .2s; pointer-events: none; z-index: 200; font-weight: 500; }
.toast.show { opacity: 1; transform: translateX(-50%); }
.toast.bad { background: var(--bad); }

/* Login */
.login-page { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 26px; min-height: 100vh; background: #000; }
.login-page .login-logo { width: 240px; }
.login-page .tagline { color: var(--cyan); letter-spacing: .25em; text-transform: uppercase; font-size: 12px; font-weight: 600; margin-top: -10px; }
.login-card { background: #fff; padding: 28px 32px; border-radius: 14px; width: 340px; display: flex; flex-direction: column; gap: 16px; border-top: 4px solid var(--cyan); }
.login-card h2 { font-family: 'Archivo Black', sans-serif; font-weight: 400; font-size: 18px; margin: 0; text-align: center; }

@media (max-width: 760px) {
  .playlist-layout { grid-template-columns: 1fr; }
  .item { grid-template-columns: 22px 1fr 110px 80px 60px; }
  .item .num, .item .thumb { display: none; }
  .topbar { gap: 12px; padding: 0 12px; overflow-x: auto; }
  main { padding: 14px; }
}

/* Shuffle switch */
.toggle { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; cursor: pointer; white-space: nowrap; }
.toggle input { display: none; }
.toggle span { width: 36px; height: 20px; border-radius: 999px; background: #cbd2dc; position: relative; transition: .15s; }
.toggle span::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: .15s; box-shadow: 0 1px 2px rgba(0,0,0,.2); }
.toggle input:checked + span { background: var(--cyan); }
.toggle input:checked + span::after { left: 18px; }

.media-card.drop-target { outline: 3px dashed var(--accent); outline-offset: -3px; }

.adv-tag { display: inline-block; font-size: 11.5px; font-weight: 600; color: #7a4b00; background: #fff4dc; border-radius: 5px; padding: 1px 7px; margin-top: 4px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.per-loop select { padding: 5px 6px; font-size: 12.5px; }
.item .media-name small { display: block; font-weight: 400; color: var(--muted); font-size: 12px; }
.adv-table td .btn-row { justify-content: flex-end; }

/* Media folders, selection and preview */
.media-layout { display: grid; grid-template-columns: 210px 1fr; gap: 18px; align-items: start; }
.folder-list { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 8px; position: sticky; top: 84px; }
.folder-list .f { display: flex; align-items: center; gap: 8px; width: 100%; text-align: left; background: none; border: 0; border-radius: 7px; padding: 8px 10px; font: inherit; cursor: pointer; color: var(--ink); }
.folder-list .f:hover { background: #f1f3f6; }
.folder-list .f.active { background: var(--accent-soft); box-shadow: inset 3px 0 0 var(--cyan); font-weight: 600; }
.folder-list .f.drop { background: var(--accent-soft); outline: 2px dashed var(--cyan); }
.folder-list .f .ico { width: 16px; text-align: center; color: var(--gray); }
.folder-list .f .n { margin-left: auto; color: var(--muted); font-size: 12px; font-weight: 500; }
.folder-list .f .more { display: none; color: var(--muted); padding: 0 2px; }
.folder-list .f:hover .more { display: inline; }
.folder-list .f.user:hover .n { display: none; }
.folder-list hr { border: 0; border-top: 1px solid var(--line); margin: 6px 0; }
.folder-list .new-folder { color: var(--navy); font-weight: 600; }
.media-toolbar { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
.media-toolbar .search { margin: 0; }
.bulk-bar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; background: var(--navy); color: #fff; border-radius: 9px; padding: 6px 8px 6px 14px; }
.bulk-bar select { padding: 5px 8px; font-size: 12.5px; }
.bulk-bar .btn { padding: 5px 10px; font-size: 12.5px; }
.bulk-bar b { margin-right: 4px; }
.media-card .sel { position: absolute; top: 8px; left: 8px; z-index: 2; opacity: 0; transition: opacity .1s; }
.media-card .sel input { width: 18px; height: 18px; margin: 0; accent-color: var(--navy); cursor: pointer; }
.media-card:hover .sel, .media-grid.selecting .sel, .media-card.checked .sel { opacity: 1; }
.media-card.checked { outline: 3px solid var(--cyan); }
.media-card .thumb { cursor: pointer; position: relative; }
.media-card .thumb::after { content: "▶  Preview"; position: absolute; inset: auto 8px 8px auto; background: rgba(0,0,0,.75); color: #fff; font-size: 11px; font-weight: 600; padding: 3px 8px; border-radius: 5px; opacity: 0; transition: opacity .15s; }
.media-card .thumb:hover::after { opacity: 1; }
.thumb.facebook { background: linear-gradient(135deg, #1877F2, #0b3d91); color: #fff; }
.preview-frame { position: relative; width: 100%; aspect-ratio: 16 / 9; background: #000; border-radius: 8px; overflow: hidden; }
.preview-frame iframe { position: absolute; top: 0; left: 0; width: 1920px; height: 1080px; border: 0; transform-origin: 0 0; }
.modal-card.xwide { width: min(1180px, 100%); }
@media (max-width: 900px) { .media-layout { grid-template-columns: 1fr; } .folder-list { position: static; } }

.thumb .thumb-label { background: rgba(0,0,0,.55); padding: 3px 8px; border-radius: 5px; color: #fff; }
.color-row { gap: 16px; }
.color-row input[type=color] { width: 42px; height: 30px; padding: 2px; border-radius: 6px; cursor: pointer; }

/* community photos */
.tab-count { display: inline-block; min-width: 18px; padding: 0 5px; margin-left: 4px; border-radius: 9px; background: #04D9D9; color: #000; font-size: 11px; font-weight: 800; line-height: 18px; text-align: center; }
.ph-h { font-size: 15px; margin: 22px 0 10px; display: flex; align-items: center; gap: 8px; }
.ph-h span { color: var(--muted); font-weight: 500; }
.ph-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.ph-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column; }
.ph-card img { width: 100%; height: 210px; object-fit: contain; background: #000; cursor: zoom-in; display: block; }
.ph-body { padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.ph-title { font-weight: 700; font-size: 15px; }
.ph-kv { display: grid; grid-template-columns: 82px 1fr; gap: 3px 8px; font-size: 13px; margin: 0; }
.ph-kv dt { color: var(--muted); }
.ph-kv dd { margin: 0; word-break: break-word; }
.ph-kv .priv { color: var(--muted); font-size: 11px; }
.ph-foot { font-size: 12px; color: var(--muted); }
.ph-actions { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; border-top: 1px solid var(--line); padding-top: 10px; margin-top: auto; }
.ph-actions select { padding: 6px; }
.ph-hist { width: 100%; border-collapse: collapse; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; font-size: 13px; }
.ph-hist td, .ph-hist th { padding: 8px 10px; border-bottom: 1px solid var(--line); text-align: left; }
.ph-hist img { width: 54px; height: 40px; object-fit: cover; border-radius: 4px; display: block; }
.ph-warn { background: #fff7e6; border: 1px solid #f5d38a; border-radius: 10px; padding: 10px 14px; margin-bottom: 8px; font-size: 13px; }
.thumb.invite { background: #000; color: #04D9D9; display: grid; place-items: center; font-weight: 800; letter-spacing: 1px; font-size: 12px; }
.setup-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 14px; }
.setup-grid label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; font-weight: 600; }
.setup-grid .full { grid-column: 1 / -1; }
.setup-grid small { font-weight: 400; color: var(--muted); }
.setup-sec { font-size: 13px; font-weight: 800; text-transform: uppercase; letter-spacing: .5px; color: var(--accent); margin: 18px 0 8px; border-top: 1px solid var(--line); padding-top: 14px; }
a.btn { text-decoration: none; display: inline-block; }

/* customer inbox */
.ib-req { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin-bottom: 10px; box-shadow: var(--shadow); }
.ib-req-head { margin-bottom: 8px; }
.ib-req-head .sub { color: var(--muted); font-size: 12px; }
.ib-req-body { display: grid; gap: 4px; font-size: 14px; margin-bottom: 10px; }
.ib-req-body div { display: grid; grid-template-columns: 110px 1fr; gap: 8px; white-space: pre-wrap; }
.ib-req-body span { color: var(--muted); }
.ib-reply { background: #f0fbfb; border-left: 3px solid #04D9D9; padding: 8px 10px; border-radius: 6px; font-size: 13px; margin-bottom: 10px; }
.radio-row { display: flex !important; gap: 10px; align-items: flex-start; margin: 12px 0 8px; font-weight: 400 !important; cursor: pointer; }
.radio-row input { margin-top: 3px; }
.radio-row small { color: var(--muted); }
.ap-pls { margin: 0 0 10px 28px; display: grid; grid-template-columns: 1fr 1fr; gap: 6px; font-size: 14px; }
.ap-pls label { display: flex; gap: 6px; align-items: center; font-weight: 400; }
.creds { background: #0b0d12; color: #04D9D9; padding: 14px 16px; border-radius: 10px; font-size: 14px; white-space: pre-wrap; user-select: all; }
.leaflet-container { font: inherit; }

/* locations */
.loc-wrap { display: grid; grid-template-columns: 1.3fr 1fr; gap: 16px; align-items: start; }
.loc-map { height: 420px; border-radius: var(--radius); border: 1px solid var(--line); box-shadow: var(--shadow); }
.loc-list { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); max-height: 420px; overflow: auto; }
.loc-row { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; padding: 11px 14px; border-top: 1px solid var(--line); cursor: pointer; }
.loc-row:first-child { border-top: 0; }
.loc-row:hover { background: #f6f8fa; }
.loc-row .addr { grid-column: 1 / -1; color: var(--muted); font-size: 12px; }
.loc-row .meta { font-size: 12px; color: var(--muted); white-space: nowrap; }
.loc-row .warn { color: #a16207; font-size: 11px; font-weight: 700; }
.loc-pin { width: 24px; height: 24px; border-radius: 50% 50% 50% 0; background: #1E265B; border: 3px solid #04D9D9; transform: rotate(-45deg); box-shadow: 0 2px 6px rgba(0,0,0,.4); }
.loc-pin.pin-new { background: #fff; border-color: #737373; }
.loc-pin.pin-on { background: #0f9d58; border-color: #04D9D9; }
.loc-pin.pin-off { background: #dc2626; border-color: #fff; }
.loc-pin.pin-approx { border-style: dashed; }
.loc-legend { display: flex; gap: 16px; flex-wrap: wrap; font-size: 12px; color: var(--muted); margin: -6px 0 10px; }
.loc-legend i { display: inline-block; width: 11px; height: 11px; border-radius: 50%; margin-right: 5px; vertical-align: -1px; border: 2px solid; }
@media (max-width: 900px) { .loc-wrap { grid-template-columns: 1fr; } }

.switch-row { display: flex; align-items: center; gap: 8px; font-weight: 600; font-size: 14px; cursor: pointer; }
.switch-row input { width: 18px; height: 18px; }
.lead { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px; margin-bottom: 10px; box-shadow: var(--shadow); display: grid; grid-template-columns: 1fr auto; gap: 4px 16px; }
.lead.done { opacity: .6; }
.lead .who { font-weight: 700; }
.lead .meta { color: var(--muted); font-size: 13px; }
.lead .msg { grid-column: 1 / -1; font-size: 14px; white-space: pre-wrap; }
.lead .acts { display: flex; gap: 6px; align-items: start; }
.ok-note { background: #e8f7ef; color: #0b6b3a; border-radius: 8px; padding: 9px 13px; margin: 6px 0 10px; font-size: 14px; }

/* Maps stay in their own layer so pop-ups and the top bar always cover them */
.leaflet-container { isolation: isolate; z-index: 0; }
