/* Layout only. Every color / font / border / shadow is a var set by skin.js from skins/<name>.js. */
* { box-sizing: border-box; margin: 0; }
html, body { height: 100%; background: var(--page); color: var(--ink); font-family: var(--font-body); overflow: hidden; }
a { color: var(--link); } a:hover { color: var(--link-hover); }
::-webkit-scrollbar { display: none; }
.app { position: fixed; inset: 0; display: flex; flex-direction: column; background: var(--surface); }
.top { background: var(--accent); padding: 10px 14px 8px; border-bottom: var(--bw) solid var(--ink); display: flex; align-items: center; gap: 10px; }
.top .t { flex: 1; min-width: 0; }
.top h1 { font-family: var(--font-display); font-weight: 400; font-size: 24px; line-height: 1; letter-spacing: .5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-family: var(--font-label); font-size: 10px; letter-spacing: .6px; opacity: .75; }
.top button { background: var(--ink); color: var(--paper); border: 0; font-family: var(--font-label); font-size: 11px; padding: 7px 10px; border-radius: 3px; }
.top .skin { background: var(--paper); color: var(--ink); border: 2px solid var(--ink); font-size: 9px; padding: 5px 7px; }
.kw { background: var(--kwbar); border-bottom: var(--bw) solid var(--ink); display: flex; align-items: center; }
.kw button { background: none; border: 0; font: 20px var(--font-display); width: 48px; height: 42px; color: var(--ink); }
.kw .name { flex: 1; text-align: center; font-family: var(--font-display); font-size: 19px; letter-spacing: .5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kw .cnt { font-family: var(--font-label); font-size: 10px; opacity: .7; margin-left: 6px; }
.mapwrap { position: relative; flex: 1; min-height: 0; overflow: hidden; }
.map { position: absolute; inset: 0; }
.tag { position: absolute; top: 10px; z-index: 5; background: var(--ink); color: var(--paper); font: 15px var(--font-display); letter-spacing: 1px; padding: 4px 9px; border-radius: 2px; pointer-events: none; }
.tag.l { left: 10px; } .tag.r { right: 10px; background: var(--paper); color: var(--ink); border: 2px solid var(--ink); }
.zoomhint { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); z-index: 5; background: var(--scrim); color: var(--paper); font-family: var(--font-label); font-size: 10px; letter-spacing: .5px; padding: 5px 9px; border-radius: 12px; pointer-events: none; white-space: nowrap; }
.months { background: var(--monthbar); border-top: var(--bw) solid var(--ink); display: flex; padding: 8px 10px 4px; gap: 6px; }
.month { flex: 1; font: 18px var(--font-display); letter-spacing: 1px; background: var(--surface); color: var(--ink); border: 2px solid var(--ink); border-radius: 3px; padding: 6px 0; }
.month.on { background: var(--ink); color: var(--accent); }
.month.prev { background: var(--paper); outline: 2px dashed var(--ink); outline-offset: -6px; }
.month:disabled { opacity: .45; }
.hint { background: var(--monthbar); color: var(--paper); font-family: var(--font-label); font-size: 10px; letter-spacing: .5px; text-align: center; padding: 2px 0 8px; }
.stats { background: var(--ink); color: var(--paper); display: flex; padding: 8px 10px calc(8px + env(safe-area-inset-bottom)); gap: 8px; }
[data-skin="night"] .stats, [data-skin="night"] .tag.l, [data-skin="night"] .top button:not(.skin) { background: var(--paper); color: var(--ink); }
.stat { flex: 1; text-align: center; }
.stat b { display: block; font: 22px var(--font-display); }
.stat span { font-family: var(--font-label); font-size: 9px; letter-spacing: .6px; opacity: .7; }
.up { color: var(--up); } .down { color: var(--down); }
.sheet { position: absolute; left: 0; right: 0; bottom: 0; z-index: 20; background: var(--paper); border-top: var(--bw) solid var(--ink); max-height: 70%; overflow: auto; transform: translateY(105%); transition: transform .2s; }
.sheet.open { transform: none; }
.sheet h3 { font: 16px var(--font-display); padding: 12px 14px 6px; letter-spacing: .5px; }
.sheet button { display: flex; width: 100%; justify-content: space-between; background: none; border: 0; border-top: 1px solid var(--surface); color: var(--ink); font-family: var(--font-label); font-size: 13px; padding: 11px 14px; text-align: left; }
.sheet button b { font-family: var(--font-display); font-weight: 400; color: var(--up); }
.home-pin { width: 22px; height: 22px; background: var(--pin-you); border: 3px solid var(--ink); border-radius: 50% 50% 50% 0; transform: rotate(-45deg); }
.home-pin.pin-rival { background: var(--pin-rival); }
.seg { display: flex; border: 2px solid var(--ink); border-radius: 3px; overflow: hidden; }
.seg button { border-radius: 0; background: var(--surface); color: var(--ink); padding: 6px 8px; }
.seg button.on { background: var(--ink); color: var(--accent); }
/* compare plugin slider in skin colors */
.mapboxgl-compare .compare-swiper-vertical { background-color: var(--accent); border: 3px solid var(--ink); width: 44px; height: 44px; margin: -22px 1px 0; box-shadow: none; }
.mapboxgl-compare { background-color: var(--ink); width: 4px; }

/* ---- linked (head-to-head) layout: Claude Design "Map Dominance Linked Maps" ---- */
.h2h .bar { height: 56px; background: var(--accent); border-bottom: var(--bw) solid var(--ink); display: flex; align-items: center; gap: 10px; padding: 0 10px; flex: none; }
.h2h .back { width: 44px; height: 44px; background: var(--ink); color: var(--accent); display: grid; place-items: center; font-size: 20px; flex: none; }
.h2h .addr { font-family: var(--font-display); font-size: 17px; line-height: 1.2; text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.h2h .sub { font-family: var(--font-label); font-size: 8px; letter-spacing: .1em; margin-top: 3px; }
.h2h .btn { height: 36px; padding: 0 10px; border: var(--bw) solid var(--ink); background: var(--paper); color: var(--ink); display: grid; place-items: center; flex: none; font-family: var(--font-label); font-size: 9px; letter-spacing: .08em; cursor: pointer; }
.h2h .pane { flex: 1; position: relative; overflow: hidden; background: var(--surface); }
.h2h .badge { position: absolute; top: 8px; left: 8px; z-index: 5; height: 36px; display: flex; align-items: center; gap: 8px; padding: 0 10px; border: var(--bw) solid var(--ink); font-family: var(--font-label); font-size: 9px; letter-spacing: .08em; cursor: pointer; max-width: 80%; box-shadow: var(--chip-shadow); }
.h2h .badge.you { background: var(--you); color: var(--on-you); }
.h2h .badge.rival { background: var(--rival); color: var(--on-rival); }
.h2h .badge .nm { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.h2h .badge .v { font-family: var(--font-display); font-size: 15px; }
.h2h .badge .u { opacity: .8; }
.h2h .band { flex: none; border-top: var(--bw) solid var(--ink); border-bottom: var(--bw) solid var(--ink); background: var(--paper); }
.h2h .row { height: 37px; display: flex; align-items: stretch; background: var(--paper); }
.h2h .row.kwrow { background: var(--kwbar); border-bottom: var(--bw) solid var(--ink); }
.h2h .arr { width: 40px; display: grid; place-items: center; font-size: 18px; color: var(--ink); cursor: pointer; flex: none; }
.h2h .arr.l { border-right: var(--bw) solid var(--ink); } .h2h .arr.r { border-left: var(--bw) solid var(--ink); }
/* chips are flat segments split by vertical rules (no box-in-a-band), so the type can be bigger */
.h2h .chips { flex: 1; display: flex; align-items: stretch; overflow-x: auto; min-width: 0; scrollbar-width: none; }
.h2h .chip { flex: none; padding: 0 14px; display: flex; align-items: center; gap: 8px; border-right: 2px solid var(--ink); background: transparent; color: var(--ink); font-family: var(--font-label); font-size: 11px; letter-spacing: .05em; text-transform: uppercase; white-space: nowrap; cursor: pointer; }
.h2h .chip:last-child { border-right: 0; }
.h2h .chip .rk { font-family: var(--font-display); font-size: 16px; }
.h2h .kwrow .chip.on { background: var(--ink); color: var(--accent); }
.h2h .firmrow .chip.on { background: var(--rival); color: var(--on-rival); }
.h2h .modal { position: absolute; inset: 0; background: var(--scrim); display: none; align-items: flex-end; z-index: 30; }
.h2h .modal.open { display: flex; }
.h2h .card { width: 100%; max-height: 70%; background: var(--paper); border-top: var(--bw) solid var(--ink); display: flex; flex-direction: column; }
.h2h .card .hd { padding: 8px 14px 10px; border-bottom: var(--bw) solid var(--ink); display: flex; align-items: flex-end; gap: 8px; }
.h2h .card h2 { font-family: var(--font-display); font-weight: 400; font-size: 20px; text-transform: uppercase; line-height: 1; }
.h2h .card .ms { font-size: 11px; color: var(--ink2); margin-top: 3px; }
.h2h .card .x { width: 36px; height: 36px; display: grid; place-items: center; background: var(--ink); color: var(--accent); font-size: 14px; cursor: pointer; flex: none; }
.h2h .rows { overflow-y: auto; }
.h2h .fr { height: 50px; display: flex; align-items: center; gap: 10px; padding: 0 14px; border-bottom: 2px solid var(--ink); background: var(--paper); }
.h2h .fr.me { background: var(--me-row); }
.h2h .fr .sq { width: 28px; height: 28px; display: grid; place-items: center; font-family: var(--font-display); font-size: 15px; border: 2px solid var(--ink); flex: none; }
.h2h .fr .fn { flex: 1; min-width: 0; font-family: var(--font-label); font-size: 11px; letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.h2h .fr .tg { font-family: var(--font-label); font-size: 8px; letter-spacing: .1em; padding: 3px 6px; }
.h2h .fr .tg.you { background: var(--you); color: var(--on-you); }
.h2h .fr .tg.rival { background: var(--rival); color: var(--on-rival); }
/* share-of-local-voice table */
.h2h .sv { display: grid; grid-template-columns: 30px 1fr 52px; align-items: center; gap: 10px; padding: 9px 14px; border-bottom: 2px solid var(--ink); background: var(--paper); }
.h2h .sv.me { background: var(--me-row); }
.h2h .sv .pos { font-family: var(--font-display); font-size: 18px; text-align: center; color: var(--ink2); }
.h2h .sv .nm { font-family: var(--font-label); font-size: 11px; letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.h2h .sv .tr { height: 8px; margin-top: 6px; border: 2px solid var(--ink); background: var(--surface); }
.h2h .sv .fill { height: 100%; background: var(--ink2); }
.h2h .sv.me .fill { background: var(--you); }
.h2h .sv.rv .fill { background: var(--rival); }
.h2h .sv .pc { font-family: var(--font-display); font-size: 22px; text-align: right; }
.h2h .card .note { padding: 10px 14px 14px; font-size: 10px; color: var(--ink2); }
.mapboxgl-ctrl-logo { display: none !important; }
/* headline banner over the top map (replaces the SOLV badge): the verdict in one sentence + competitors button */
.h2h .headline { position: absolute; top: 8px; left: 8px; right: 8px; z-index: 5; display: flex; align-items: stretch; background: var(--you); color: var(--on-you); border: var(--bw) solid var(--ink); box-shadow: var(--chip-shadow); cursor: pointer; }
.h2h .headline .hl { flex: 1; min-width: 0; padding: 5px 10px; }
.h2h .headline .l1 { font-family: var(--font-label); font-size: 10px; letter-spacing: .06em; text-transform: uppercase; white-space: nowrap; }
.h2h .headline .l1 .v { font-family: var(--font-display); font-size: 20px; letter-spacing: 0; margin-right: 2px; }
.h2h .headline .mom { margin-left: 4px; opacity: .9; }
.h2h .headline .l2 { font-size: 11px; margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.h2h .headline .see { flex: none; display: grid; place-items: center; padding: 0 10px; border-left: var(--bw) solid var(--ink); background: var(--paper); color: var(--ink); font-family: var(--font-label); font-size: 8px; letter-spacing: .08em; line-height: 1.4; text-align: center; }
/* colour key strip above the months */
.h2h .legend { flex: none; display: flex; justify-content: space-between; gap: 6px; padding: 5px 10px; background: var(--paper); border-top: var(--bw) solid var(--ink); font-family: var(--font-label); font-size: 8px; letter-spacing: .06em; color: var(--ink); }
.h2h .legend .k { display: flex; align-items: center; gap: 4px; white-space: nowrap; }
.h2h .legend i { width: 10px; height: 10px; border-radius: 50%; border: 1px solid var(--ink); flex: none; }
/* target-firm picker: the header title is the button */
.h2h .target { flex: 1; min-width: 0; cursor: pointer; padding-left: 4px; }
.h2h .tq { margin: 10px 14px; padding: 10px 12px; border: var(--bw) solid var(--ink); background: var(--surface); color: var(--ink); font: 14px var(--font-body); outline: none; }
.h2h .fr .fa { font-family: var(--font-body); font-size: 10px; letter-spacing: 0; text-transform: none; color: var(--ink2); margin-top: 2px; overflow: hidden; text-overflow: ellipsis; }
.h2h .fr .tg { color: var(--ink2); }
.h2h .mrow { display: flex; gap: 6px; padding: 6px 8px; background: var(--monthbar); border-top: var(--bw) solid var(--ink); }
.h2h .mrow button { flex: 1; font: 15px var(--font-display); letter-spacing: 1px; background: var(--ink); color: var(--muted); border: 2px solid var(--ink); padding: 4px 0; }
.h2h .mrow button.on { background: var(--accent); color: var(--ink); }
