*{box-sizing:border-box}
body{margin:0;font:16px/1.4 system-ui,sans-serif;background:#f4f6f9;color:#1b1f24}
header{position:sticky;top:0;z-index:1000;display:flex;gap:.6rem;align-items:center;padding:.6rem .8rem;background:#1f3a5f;color:#fff}
header strong{flex:1}
header button{background:#2f5686;color:#fff;border:0;border-radius:8px;padding:.4rem .8rem;font-size:1.1rem}
.chip{font-size:.8rem;padding:.15rem .5rem;border-radius:99px;background:#2f5686}
.chip.off{background:#a35a00}.chip.ok{background:#2e7d32}
section#setup{padding:1rem;max-width:30rem;margin:auto}
input,select,textarea,button{font:inherit}
input,select,textarea{width:100%;padding:.55rem;border:1px solid #bcc5d0;border-radius:8px;background:#fff;margin:.2rem 0}
button{padding:.55rem .9rem;border:0;border-radius:8px;background:#1f3a5f;color:#fff}
.barra{display:grid;gap:.3rem;padding:.6rem;grid-template-columns:1fr 1fr}
.barra #q{grid-column:1/-1}.vista{grid-column:1/-1;display:flex;gap:.3rem}
.vista button{flex:1;background:#d9e0ea;color:#1b1f24}.vista button.on{background:#1f3a5f;color:#fff}
#resumen{padding:0 .8rem;font-size:.85rem;color:#4a5560}
#lista{list-style:none;margin:0;padding:.4rem .6rem 5rem}
#lista li{background:#fff;border-radius:10px;padding:.6rem .8rem;margin:.4rem 0;box-shadow:0 1px 2px #0002;display:flex;gap:.6rem;align-items:center}
#lista li .p{flex:1;min-width:0}#lista li b{display:block;overflow:hidden;text-overflow:ellipsis}
#lista li small{color:#5d6975}
.dot{width:.9rem;height:.9rem;border-radius:50%;flex:none}
#mapa{height:calc(100vh - 14rem);margin:.4rem .6rem;border-radius:10px}
#leyenda{padding:.2rem .8rem;font-size:.8rem}#leyenda span{margin-right:.7rem;white-space:nowrap}
dialog{width:min(96vw,34rem);max-height:92vh;border:0;border-radius:14px;padding:1rem;overflow:auto}
dialog::backdrop{background:#0008}
dialog h3{margin:.2rem 0}dialog label{display:block;margin-top:.5rem;font-size:.85rem;color:#4a5560}
dialog .fila{display:flex;gap:.4rem;margin-top:.6rem;flex-wrap:wrap}
.visita{border-left:3px solid #1f3a5f;padding:.2rem .6rem;margin:.4rem 0;background:#f4f6f9}
.aviso{background:#fff3cd;padding:.4rem .6rem;border-radius:8px;margin:.4rem 0;font-size:.85rem}
.sec{background:#d9e0ea;color:#1b1f24}
