:root{--bg:#f1f5f9;--surface:#fff;--border:#cbd5e1;--text:#0f172a;--muted:#64748b;--ocean:#e8eef6;--land:#fff;--land-stroke:#94a3b8;--land-hover:#dbeafe;--land-inactive:#c3cedb;--selected:#facc15;--solved:#4ade80;--wrong:#f87171;--accent:#2563eb;--lightningcss-light:initial;--lightningcss-dark: ;color-scheme:light}*{box-sizing:border-box}body{color:var(--text);background:var(--bg);margin:0;font:15px/1.5 system-ui,-apple-system,Segoe UI,Roboto,sans-serif}#app{flex-direction:column;height:100vh;display:flex}.topbar{background:var(--surface);border-bottom:1px solid var(--border);justify-content:space-between;align-items:center;gap:16px;padding:12px 20px;display:flex}.topbar h1{letter-spacing:-.01em;margin:0;font-size:17px;font-weight:650}.modes{background:var(--bg);border:1px solid var(--border);border-radius:8px;padding:2px;display:flex}.modes button{font:inherit;color:var(--muted);cursor:pointer;background:0 0;border:0;border-radius:6px;padding:6px 12px;font-size:13px}.modes button.active{background:var(--surface);color:var(--text);font-weight:600;box-shadow:0 1px 2px #0f172a1f}.picker{color:var(--muted);align-items:center;gap:6px;font-size:13px;display:flex}.picker select{font:inherit;color:var(--text);background:var(--bg);border:1px solid var(--border);border-radius:6px;padding:5px 8px}main{flex:1;grid-template-columns:minmax(0,1fr) 320px;min-height:0;display:grid}.map-pane{--map-pad:12px;min-width:0;padding:var(--map-pad);position:relative}#map{background:var(--border);touch-action:none;cursor:grab;border-radius:10px;width:100%;height:100%;display:block;overflow:hidden}#map:active{cursor:grabbing}.help-panel{border:1px solid var(--border);background:var(--surface);max-width:320px;color:var(--text);border-radius:10px;padding:20px 24px}.help-panel h2{margin:0 0 12px;font-size:15px}.help-panel ul{color:var(--muted);margin:0 0 16px;padding-left:20px;font-size:13px;line-height:1.6}.help-panel:popover-open{flex-direction:column;max-height:min(80vh,560px);display:flex}.help-body{overflow-y:auto}.help-panel h2+ul+h2{border-top:1px solid var(--border);margin-top:4px;padding-top:14px}.help-panel .credits{font-size:12px;line-height:1.55}.help-panel .credits a{color:inherit;text-decoration:underline}.help-panel .credits a:hover,.help-panel .credits a:focus-visible{color:var(--text)}.icon-btn{text-align:center;border-radius:50%;width:28px;height:28px;padding:0;font-weight:600;line-height:1}.map-actions{gap:8px;display:flex}.topbar>*,.topbar button,.topbar .picker,.topbar .ghost{white-space:nowrap}.topbar{scrollbar-width:none;overflow-x:auto}.topbar::-webkit-scrollbar{display:none}#capture{min-width:8.5em}.ghost.active{color:var(--text);border-color:var(--accent);font-weight:600}.capture-overlay{inset:var(--map-pad);z-index:1;cursor:crosshair;touch-action:none;border-radius:10px;position:absolute;overflow:hidden}.capture-box{border:1px dashed var(--surface);outline:1px solid #0f172a80;position:absolute;box-shadow:0 0 0 9999px #0f172a61}.ocean{fill:var(--ocean)}.country{fill:var(--land);stroke:var(--land-stroke);stroke-width:.6px;vector-effect:non-scaling-stroke;cursor:pointer;transition:fill .12s}.country:hover{fill:var(--land-hover)}.country.inactive{fill:var(--land-inactive);stroke:#b8c2d0;pointer-events:none;cursor:default}.country.undrawn,.markers circle.undrawn{display:none}.country.solved,.country.solved:hover{fill:var(--solved);cursor:pointer}.country.selected,.country.selected:hover{fill:var(--selected);stroke:#a16207;stroke-width:1.2px}.country.skipped,.country.skipped:hover{fill:var(--wrong);cursor:default;pointer-events:none}.country.wrong,.country.wrong:hover{fill:var(--wrong);transition:none}.markers circle{r:calc(var(--marker-r,6) * 1px);stroke-width:1px}.markers circle.inactive{display:none}.markers circle.selected:not(.wrong),.markers circle.selected:not(.wrong):hover{fill:none;stroke-width:1.6px;pointer-events:all}.labels{pointer-events:none;-webkit-user-select:none;user-select:none}.label{font-family:system-ui,-apple-system,Segoe UI,Roboto,sans-serif;font-weight:600;font-size:calc(var(--label-font,10) * 1px);text-anchor:middle;dominant-baseline:central;fill:#14532d;paint-order:stroke;stroke:#ffffffbf;stroke-width:.15em;stroke-linejoin:round}.panel{background:var(--surface);border-left:1px solid var(--border);flex-direction:column;gap:14px;padding:16px;display:flex;overflow:visible}.answer{align-items:flex-start;gap:8px;display:flex}.combo{flex:1;min-width:0;position:relative}#answer{width:100%;font:inherit;color:var(--text);background:var(--surface);border:1px solid var(--border);border-radius:8px;padding:8px 10px}#answer:focus{outline:2px solid var(--accent);outline-offset:-1px}#answer:disabled{background:var(--bg);color:var(--muted)}#options{z-index:20;background:var(--surface);border:1px solid var(--border);border-radius:8px;max-height:260px;margin:0;padding:4px;list-style:none;position:absolute;top:calc(100% + 4px);left:0;right:0;overflow-y:auto;box-shadow:0 8px 24px #0f172a24}#options li{cursor:pointer;border-radius:5px;padding:6px 8px;font-size:14px}#options li.active{background:var(--accent);color:#fff}#options li.empty{color:var(--muted);cursor:default}button{font:inherit}#submit{background:var(--accent);color:#fff;cursor:pointer;white-space:nowrap;border:0;border-radius:8px;padding:8px 14px;font-weight:600}#submit:disabled{color:#f8fafc;cursor:not-allowed;background:#cbd5e1}.ghost{border:1px solid var(--border);background:var(--surface);color:var(--muted);cursor:pointer;border-radius:8px;padding:6px 10px;font-size:13px;text-decoration:none;display:inline-block}.ghost:hover{color:var(--text)}.ghost.danger:hover{color:#b91c1c;border-color:#fca5a5}.panel>.ghost.danger{align-self:flex-start;margin-top:auto}#whats-left{align-self:flex-end}.status{min-height:2.4em;color:var(--muted);margin:0;font-size:13px}.status.good{color:#15803d;font-weight:600}.status.bad{color:#b91c1c;font-weight:600}.status-flag{border-radius:2px;width:auto;height:1.4em;margin-top:4px;display:block;box-shadow:0 0 0 1px #0000001a}.stats{grid-template-columns:repeat(3,1fr);gap:8px;margin:0;display:grid}.stats div{background:var(--bg);text-align:center;border-radius:8px;padding:8px}.stats dt{text-transform:uppercase;letter-spacing:.06em;color:var(--muted);font-size:10px}.stats dd{font-variant-numeric:tabular-nums;margin:2px 0 0;font-size:15px;font-weight:650}.progress-track{background:var(--bg);border-radius:999px;height:6px;overflow:hidden}.progress-bar{background:var(--solved);border-radius:inherit;width:0;height:100%;transition:width .22s}.skips{flex-direction:column;gap:6px;display:flex}.skips-heading{color:var(--muted);margin:0;font-size:13px;font-weight:650}.skips-heading span{color:var(--text)}#skips-list{max-height:140px;margin:0;padding:0;list-style:none;overflow-y:auto}#skips-list:empty{display:none}#skips-list li{background:var(--bg);border-radius:6px;padding:4px 8px;font-size:13px}#skips-list li+li{margin-top:2px}@media (width<=860px){main{grid-template-rows:minmax(240px,1fr) auto;grid-template-columns:1fr}.panel{border-left:0;border-top:1px solid var(--border)}.panel>.ghost.danger{margin-top:4px}}#datasheet{flex-direction:column;min-height:100vh;display:flex}.datasheet-nav{align-items:center;gap:8px;display:flex}.datasheet-main{flex:1;padding:20px;display:block;overflow:auto}.datasheet-summary{color:var(--muted);margin:0 0 12px;font-size:13px}.datasheet-scroll{border:1px solid var(--border);background:var(--surface);border-radius:10px;overflow-x:auto}.datasheet-table{border-collapse:collapse;white-space:nowrap;width:100%;font-size:14px}.datasheet-table th,.datasheet-table td{text-align:left;border-bottom:1px solid var(--border);padding:8px 14px}.datasheet-table thead tr:first-child th{background:var(--bg);padding:0;position:sticky;top:0}.col-sort{width:100%;font:inherit;text-transform:uppercase;letter-spacing:.06em;color:var(--muted);text-align:left;cursor:pointer;background:0 0;border:0;align-items:center;gap:4px;padding:8px 14px;font-size:11px;display:flex}.col-sort:hover{color:var(--text)}.sort-indicator{font-size:9px}.datasheet-table thead tr.filters th{background:var(--surface);padding:6px 10px}.col-filter{position:relative}.filter-toggle{width:100%;font:inherit;text-transform:none;letter-spacing:normal;color:var(--text);background:var(--surface);border:1px solid var(--border);cursor:pointer;border-radius:6px;justify-content:space-between;align-items:center;gap:6px;padding:5px 8px;font-size:13px;font-weight:400;display:flex}.filter-toggle:after{content:"▾";color:var(--muted);font-size:10px}.filter-toggle[aria-expanded=true]{border-color:var(--accent)}.filter-popup{z-index:20;background:var(--surface);border:1px solid var(--border);white-space:normal;border-radius:8px;flex-direction:column;max-height:320px;display:flex;position:fixed;box-shadow:0 8px 24px #0f172a24}.filter-popup[hidden]{display:none}.filter-popup-actions{border-bottom:1px solid var(--border);gap:4px;padding:6px;display:flex}.filter-popup-actions button{border:1px solid var(--border);background:var(--bg);color:var(--muted);cursor:pointer;border-radius:6px;flex:1;padding:4px 8px;font-size:12px}.filter-popup-actions button:hover{color:var(--text)}.filter-options{margin:0;padding:4px;list-style:none;overflow-y:auto}.filter-options label{cursor:pointer;border-radius:5px;align-items:center;gap:8px;padding:5px 8px;font-size:13px;font-weight:400;display:flex}.filter-options label:hover{background:var(--bg)}.datasheet-table tbody tr:last-child td{border-bottom:0}.datasheet-table tbody tr:hover{background:var(--land-hover)}
