/* ANO Site Hub V8.1 - route planning inside the Site map */
.rm{margin-top:12px}
.rm-tools{display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin:0 0 10px}
.rm-jump{flex:1 1 100%;margin:0!important;padding:8px 12px!important;border-radius:999px!important;background:var(--u-primary)!important;color:#fff!important;border:0!important;font-weight:700;font-size:.8rem!important;min-height:36px}
.rm-pick{display:flex!important;align-items:center;gap:10px;flex:1 1 230px;text-align:left;margin:0!important;padding:9px 12px!important;border-radius:13px!important;background:var(--u-surface2)!important;color:var(--u-text)!important;border:1px solid var(--u-line)!important;box-shadow:none!important;min-height:48px}
.rm-pick .ico{width:20px;height:20px;flex:none;color:var(--u-muted)}
.rm-pick span{display:flex;flex-direction:column;min-width:0}.rm-pick b{font-size:.86rem}.rm-pick small{font-size:.72rem;color:var(--u-muted);font-weight:500}
.rm-pick.on{background:var(--u-soft)!important;border-color:var(--u-primary)!important}.rm-pick.on .ico,.rm-pick.on b{color:var(--u-primary)}
.rm-tools>.secondary{margin:0!important;display:inline-flex;align-items:center;gap:6px;min-height:48px}
.rm-tools>.secondary.on{background:var(--u-primary)!important;color:#fff!important;border-color:var(--u-primary)!important}
.rm-tools .ico{width:17px;height:17px}
.rm-card{background:var(--u-surface);border:1px solid var(--u-line);border-radius:16px;padding:14px;box-shadow:var(--u-shadow)}
.rm-h{display:flex;justify-content:space-between;align-items:center;gap:8px}
.rm-h h3{margin:0;font-size:1.02rem;color:var(--u-text);display:flex;align-items:center;gap:8px}
.rm-count{font-size:.74rem;font-weight:700;color:var(--u-primary);background:var(--u-soft);border-radius:999px;padding:3px 9px}
.rm-grid{display:grid;grid-template-columns:1fr;gap:10px;margin-top:12px}
@media(min-width:620px){.rm-grid{grid-template-columns:1fr 1fr}}
.rm-grid label,.rm-lab{display:flex;flex-direction:column;gap:5px;font-size:.78rem;font-weight:700;color:var(--u-muted);margin:0}
.rm-grid select{margin:0;width:100%}
.rm-fin .hx-seg{margin:5px 0 0}
.rm-row{display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin-top:10px}
.rm-row input{flex:1 1 180px;margin:0}.rm-row>button{margin:0!important;display:inline-flex;align-items:center;gap:6px}
.rm-row .ico{width:16px;height:16px}
.rm-co{color:var(--u-muted);font-variant-numeric:tabular-nums}
.rm-save small{color:var(--u-muted);font-size:.76rem}
.rm-warn{margin:10px 0 0;font-size:.78rem;line-height:1.45;color:#9a6200;background:rgba(224,160,32,.13);border:1px solid rgba(224,160,32,.4);border-radius:10px;padding:8px 10px}
html[data-theme="dark"] .rm-warn{color:#f3c867}
.rm-list{list-style:none;margin:12px 0 0;padding:0;border:1px solid var(--u-line);border-radius:13px;overflow:hidden}
.rm-list li{display:flex;align-items:center;gap:10px;padding:8px 10px;border-top:1px solid var(--u-line);background:var(--u-surface)}
.rm-list li:first-child{border-top:0}
.rm-list li.rm-a-row{background:var(--u-surface2)}
.rm-no{flex:none;width:26px;height:26px;border-radius:50%;display:grid;place-items:center;background:var(--u-primary);color:#fff;font-size:.74rem;font-weight:800}
.rm-no.a{background:#0f7a5a}
.rm-nm{flex:1;min-width:0;display:flex;flex-direction:column}
.rm-nm strong{font-size:.84rem;color:var(--u-text);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.rm-nm small{font-size:.7rem;color:var(--u-muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.rm-ops{display:flex;gap:4px;flex:none}
.rm-ops .hx-icon{width:32px;height:32px;font-size:.95rem}
.rm-ops .hx-icon:disabled{opacity:.35}
.rm-acts>button{flex:1 1 auto}
.rm-calc{width:100%;justify-content:center;margin-top:12px!important}
.rm-res{margin-top:10px;border-radius:13px;background:var(--u-soft);padding:12px}
.rm-tot{display:flex;flex-direction:column;gap:2px}
.rm-tot b{font-size:1.6rem;color:var(--u-primary);letter-spacing:-.02em}
.rm-tot span{font-size:.84rem;color:var(--u-text);font-weight:600}
.rm-tot small{font-size:.72rem;color:var(--u-muted)}
.rm-legs{margin-top:8px}
.rm-legs summary{cursor:pointer;font-size:.8rem;font-weight:700;color:var(--u-primary)}
.rm-legs ol{margin:8px 0 0;padding-left:20px}
.rm-legs li{display:flex;justify-content:space-between;gap:10px;font-size:.78rem;color:var(--u-text);padding:4px 0;border-bottom:1px dashed var(--u-line)}
.rm-legs li span{min-width:0;overflow:hidden;text-overflow:ellipsis}
.rm-legs li b{flex:none;font-variant-numeric:tabular-nums}
/* map markers */
.rm-n span,.rm-a span{display:grid;place-items:center;width:26px;height:26px;border-radius:50%;background:#1268d6;color:#fff;font:800 12px/1 system-ui,sans-serif;border:2px solid #fff;box-shadow:0 2px 6px rgba(0,0,0,.35)}
.rm-a span{width:30px;height:30px;background:#0f7a5a;font-size:13px}
.hx-smmap.rm-boxing{cursor:crosshair;outline:3px solid #1268d6;outline-offset:-3px}
.hx-poproute{display:block;width:100%;margin:8px 0 0!important;padding:8px!important;border-radius:10px!important;font-weight:700;background:var(--u-primary)!important;color:#fff!important;border:0!important}
.hx-poproute.on{background:transparent!important;color:#c0392b!important;border:1px solid #c0392b!important}
.rm-n.rm-sm span{width:12px;height:12px;border-width:2px}
/* V8.2 */
.rm-add{display:flex;flex-wrap:wrap;gap:8px;align-items:flex-start;margin-top:12px}
.rm-findwrap{flex:1 1 100%;min-width:0;position:relative}
.rm-findwrap input{width:100%;margin:0}
.rm-add>.secondary{margin:0!important;flex:none;display:inline-flex;align-items:center;gap:6px;min-height:40px;padding:8px 14px!important}
.rm-add .ico{width:16px;height:16px}
.rm-findres{display:flex;flex-direction:column;gap:4px;margin-top:4px}
.rm-findres button{display:flex!important;align-items:center;justify-content:space-between;gap:8px;text-align:left;margin:0!important;padding:8px 10px!important;border-radius:10px!important;background:var(--u-surface2)!important;color:var(--u-text)!important;border:1px solid var(--u-line)!important;box-shadow:none!important}
.rm-findres button span{display:flex;flex-direction:column;min-width:0}.rm-findres strong{font-size:.84rem}.rm-findres small{font-size:.72rem;color:var(--u-muted)}
.rm-findres button b{flex:none;font-size:1.05rem;color:var(--u-primary)}.rm-findres button.in b{color:#0f7a5a}
.rm-findres button:disabled{opacity:.5}
.rm-setup{margin-top:10px;padding:12px;border-radius:13px;background:var(--u-soft);border:1px solid var(--u-line)}
.rm-setup>b{font-size:.86rem;color:var(--u-text)}
.rm-setup .rm-row:first-of-type{margin-top:8px}
.rm-name{display:flex;flex-direction:column;gap:4px;margin-top:8px;font-size:.76rem;font-weight:700;color:var(--u-muted)}.rm-name input{margin:0}
.rm-pickA{margin:8px 0 0;font-size:.82rem;color:var(--u-primary);font-weight:700}
.rm-pickbar{flex:1 1 100%;display:flex;align-items:center;gap:8px;padding:10px 12px;border-radius:13px;background:var(--u-primary);color:#fff;font-size:.86rem}
.rm-pickbar .ico{width:18px;height:18px}.rm-pickbar span{flex:1}.rm-pickbar .hx-link{color:#fff!important;text-decoration:underline}
.rm-savedline{display:flex;align-items:center;gap:6px;margin:8px 0 0;font-size:.8rem}
.rm-savedline span{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--u-text)}
.rm-savedline .ico{width:15px;height:15px;color:#0f7a5a;flex:none}
.rm-danger{color:#c0392b!important}
.rm-prov{margin-top:12px;padding-top:10px;border-top:1px dashed var(--u-line)}
.rm-prov label{display:flex;flex-direction:column;gap:5px;font-size:.78rem;font-weight:700;color:var(--u-muted)}.rm-prov select{margin:0}
.rm-prov small a{color:var(--u-primary);font-weight:700}
.rm-work{margin-top:12px;padding-top:10px;border-top:1px dashed var(--u-line)}
.rm-ok{margin:6px 0 0;font-size:.8rem;font-weight:700;color:#0f7a5a}
html[data-theme="dark"] .rm-ok,html[data-theme="dark"] .rm-savedline .ico{color:#4fd8a6}
.rm-a-new span{width:34px;height:34px;background:#e0a020;font-size:11px}
.hx-sugg{margin-top:10px}
.hx-sg-h{margin:8px 0 5px;font-size:.74rem;font-weight:700;color:var(--u-muted);text-transform:uppercase;letter-spacing:.04em}
.hx-sg-row{display:flex;flex-wrap:wrap;gap:6px}
.hx-sg-row .hx-chip small{color:var(--u-muted);font-weight:500;margin-left:3px}
.hx-chip-main{background:var(--u-soft)!important;color:var(--u-primary)!important;border-color:var(--u-primary)!important}
/* V8.4 map: floating controls */
.sm-wrap{position:relative}
.sm-wrap .hx-smmap{height:68vh;min-height:380px;max-height:720px}
.sm-fab{position:absolute;top:10px;right:10px;z-index:500;display:flex;flex-direction:column;gap:6px}
.sm-btn{position:relative;display:flex!important;flex-direction:column;align-items:center;justify-content:center;gap:1px;width:52px;height:50px;margin:0!important;padding:4px!important;border-radius:14px!important;background:var(--u-surface)!important;color:var(--u-text)!important;border:1px solid var(--u-line)!important;box-shadow:0 4px 14px rgba(16,44,78,.18)!important}
.sm-btn .ico{width:19px;height:19px}.sm-btn span{font-size:.6rem;font-weight:750;line-height:1.1}
.sm-btn.on{background:var(--u-primary)!important;color:#fff!important;border-color:var(--u-primary)!important}
.sm-badge{position:absolute;top:-4px;right:-4px;min-width:17px;height:17px;border-radius:999px;background:#e0a020;color:#fff;font-style:normal;font-size:.62rem;font-weight:800;display:grid;place-items:center;padding:0 4px}
.sm-chips{position:absolute;left:58px;right:72px;top:10px;z-index:500;display:flex;flex-wrap:wrap;gap:5px;pointer-events:none}
.sm-chip{pointer-events:auto;display:inline-flex;align-items:center;gap:3px;padding:4px 9px;border-radius:999px;background:var(--u-surface);color:var(--u-primary);font-size:.72rem;font-weight:750;box-shadow:0 2px 8px rgba(16,44,78,.18)}
.sm-chip button{all:unset;cursor:pointer;font-size:.95rem;line-height:1;padding:0 2px}
.rm-tools:empty{display:none}
.rm-h{gap:8px}
.rm-htog{all:unset;cursor:pointer;display:flex;align-items:center;gap:8px;flex:1;min-width:0}
.rm-chev{width:9px;height:9px;border-right:2px solid var(--u-muted);border-bottom:2px solid var(--u-muted);transform:rotate(-45deg);transition:transform .15s;flex:none}
.rm-chev.open{transform:rotate(45deg)}
.rm-body[hidden]{display:none!important}
/* V8.4.2: smaller icon-only map buttons */
.sm-fab{top:8px;right:8px;gap:5px}
.sm-btn{width:42px!important;height:42px!important;border-radius:12px!important;background:color-mix(in srgb,var(--u-surface) 92%,transparent)!important}
.sm-btn span{display:none}
.sm-btn .ico{width:20px;height:20px}
.sm-chips{left:54px;right:58px;top:8px}
/* full-screen map */
.rm-grab{display:none}
html.sm-fullon,html.sm-fullon body{overflow:hidden!important}
html.sm-fullon #bottomNav,html.sm-fullon header{display:none!important}
.hx-smbody.sm-full{position:fixed;inset:0;z-index:2000;background:var(--u-surface);margin:0;padding:0;display:flex;flex-direction:column}
.hx-smbody.sm-full .sm-wrap{flex:1;min-height:0}
.hx-smbody.sm-full .sm-wrap .hx-smmap{height:100%!important;max-height:none!important;min-height:0!important;border-radius:0!important;border:0!important}
.hx-smbody.sm-full .sm-fab{top:calc(10px + env(safe-area-inset-top))}
.hx-smbody.sm-full .sm-chips{top:calc(10px + env(safe-area-inset-top))}
.hx-smbody.sm-full #smInfo{display:none}
.hx-smbody.sm-full .rm-tools{position:absolute;left:10px;right:60px;top:calc(10px + env(safe-area-inset-top));z-index:600;margin:0}
.hx-smbody.sm-full #rmPanel{position:absolute;left:0;right:0;bottom:0;z-index:700;margin:0;max-height:62vh;overflow:auto;-webkit-overflow-scrolling:touch;padding-bottom:env(safe-area-inset-bottom)}
.hx-smbody.sm-full #rmPanel .rm-card{border-radius:20px 20px 0 0;border-bottom:0;box-shadow:0 -8px 28px rgba(0,0,0,.22);padding-top:6px}
.hx-smbody.sm-full .rm-grab{display:flex;justify-content:center;width:100%;margin:0 0 4px!important;padding:6px 0!important;background:none!important;border:0!important;box-shadow:none!important;touch-action:none;cursor:grab}
.hx-smbody.sm-full .rm-grab i{display:block;width:42px;height:5px;border-radius:999px;background:var(--u-line)}
/* 2: long site names wrap to two lines */
.rm-nm strong,.ih-sm strong{white-space:normal!important;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;word-break:break-word}
/* V8.9 auto-sort + navigation export */
.rm-auto{flex:1 1 200px;display:flex;align-items:center;gap:10px;padding:8px 12px;border-radius:12px;border:1px solid var(--u-line);background:var(--u-surface2);cursor:pointer;margin:0}
.rm-auto input{width:20px;height:20px;margin:0;accent-color:var(--u-primary)}
.rm-auto span{display:flex;flex-direction:column;min-width:0}.rm-auto b{font-size:.84rem;color:var(--u-text)}.rm-auto small{font-size:.7rem;color:var(--u-muted)}
.rm-nav{margin-top:14px;padding-top:12px;border-top:1px dashed var(--u-line)}
.rm-navx{width:100%;margin:8px 0 0!important;min-height:64px!important;display:flex!important;flex-direction:row!important;align-items:center;gap:12px;padding:10px 14px!important;text-align:left;border-radius:16px!important;background:var(--u-soft)!important;color:var(--u-text)!important;border:1px solid var(--u-primary)!important;box-shadow:none!important}
.rm-navi{width:40px;height:40px;border-radius:12px;display:grid;place-items:center;background:var(--u-primary);color:#fff;flex:none}
.rm-navi .ico{width:20px;height:20px;display:block}
.rm-navt{display:flex;flex-direction:column;gap:2px;min-width:0;flex:1}
.rm-navt b{font-size:.95rem;color:var(--u-primary)}.rm-navt small{font-size:.72rem;color:var(--u-muted);font-weight:600;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.rm-chev{font-size:1.4rem;color:var(--u-muted);flex:none}
.rm-acts>button{min-height:48px!important}
.nx-list{display:flex;flex-direction:column;gap:6px;margin:10px 0}
.nx-item{display:flex!important;align-items:center;justify-content:space-between;gap:10px;width:100%;text-align:left;margin:0!important;padding:12px 14px!important;border-radius:14px!important;background:var(--u-surface)!important;color:var(--u-text)!important;border:1px solid var(--u-line)!important;box-shadow:none!important}
.nx-item span{display:flex;flex-direction:column;min-width:0}.nx-item b{font-size:.9rem}.nx-item small{font-size:.72rem;color:var(--u-muted);font-weight:500}
.nx-item.pref{border-color:var(--u-primary)!important;background:var(--u-soft)!important}
.nx-item i{font-style:normal;font-size:.64rem;font-weight:800;color:var(--u-primary);flex:none}
.nx-glinks{display:flex;flex-wrap:wrap;gap:6px}
.nx-g{display:inline-flex;align-items:center;gap:5px;padding:8px 12px;border-radius:12px;border:1px solid var(--u-primary);color:var(--u-primary);text-decoration:none;font-size:.8rem;font-weight:700}
.nx-g .ico{width:15px;height:15px}
.rm-witha{display:flex;align-items:center;gap:8px;font-size:.82rem;margin:6px 0}
/* V8.10 order modes + export sheet */
.rm-order{margin-top:12px;display:flex;flex-direction:column;gap:6px}
.rm-order .hx-seg{margin:0}
.rm-ohint{font-size:.72rem;color:var(--u-muted);line-height:1.4}
.rm-order .hx-link{align-self:flex-start;padding:2px 0!important}
.nx-sum{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin:4px 0 12px}
.nx-sum>div{background:var(--u-surface2);border:1px solid var(--u-line);border-radius:14px;padding:10px 6px;text-align:center}
.nx-sum b{display:block;font-size:.95rem;color:var(--u-text)}.nx-sum span{font-size:.66rem;color:var(--u-muted);font-weight:650}
.nx-switch{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px 12px;border:1px solid var(--u-line);border-radius:14px;margin:0 0 12px;cursor:pointer}
.nx-switch span{display:flex;flex-direction:column;min-width:0}.nx-switch b{font-size:.85rem}.nx-switch small{font-size:.72rem;color:var(--u-muted)}
.nx-switch input{appearance:none;-webkit-appearance:none;width:44px;height:26px;border-radius:999px;background:var(--u-line);position:relative;flex:none;margin:0;cursor:pointer;transition:background .15s}
.nx-switch input::after{content:"";position:absolute;top:3px;left:3px;width:20px;height:20px;border-radius:50%;background:#fff;box-shadow:0 1px 3px rgba(0,0,0,.25);transition:left .15s}
.nx-switch input:checked{background:var(--u-primary)}.nx-switch input:checked::after{left:21px}
.nx-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.nx-tile{position:relative;display:flex!important;flex-direction:column;align-items:flex-start;gap:2px;text-align:left;margin:0!important;padding:12px!important;min-height:86px;border-radius:16px!important;background:var(--u-surface)!important;color:var(--u-text)!important;border:1px solid var(--u-line)!important;box-shadow:none!important}
.nx-tile b{font-size:.9rem;margin-top:auto}.nx-tile small{font-size:.7rem;color:var(--u-muted);font-weight:500;line-height:1.3}
.nx-tile.pref{border:2px solid var(--u-primary)!important;background:var(--u-soft)!important}
.nx-f{font-style:normal;font-size:.62rem;font-weight:800;letter-spacing:.04em;padding:2px 7px;border-radius:6px;background:var(--u-surface2);border:1px solid var(--u-line);color:var(--u-muted)}
.nx-tile.pref .nx-f{background:var(--u-primary);color:#fff;border-color:var(--u-primary)}
.nx-gm{margin:12px 0 0;border:1px solid var(--u-line);border-radius:14px;padding:0 12px}
.nx-gm>summary{cursor:pointer;display:flex;align-items:center;justify-content:space-between;gap:8px;padding:12px 0;list-style:none}
.nx-gm>summary::-webkit-details-marker{display:none}
.nx-gm>summary span{font-weight:750;font-size:.88rem}.nx-gm>summary small{font-size:.72rem;color:var(--u-muted)}
.nx-glinks{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;padding:0 0 12px}
.nx-g{display:flex;align-items:center;gap:8px;padding:10px;border-radius:12px;background:var(--u-surface2);border:1px solid var(--u-line);color:var(--u-text);text-decoration:none;font-size:.8rem;font-weight:700}
.nx-g b{width:22px;height:22px;border-radius:50%;display:grid;place-items:center;background:var(--u-primary);color:#fff;font-size:.7rem;flex:none}
.nx-note{font-size:.72rem;color:var(--u-muted);margin:12px 0 0;line-height:1.45}
.nx-list,.rm-witha{display:none}
.rm-chev{width:9px;height:9px;border-right:2px solid var(--u-muted);border-top:2px solid var(--u-muted);transform:rotate(45deg);margin-right:4px;flex:none;font-size:0}
.rm-acts{display:grid!important;grid-template-columns:1fr 1fr;gap:8px}
.rm-acts>button{width:100%;justify-content:center;text-align:center;white-space:normal;line-height:1.2;padding:8px 10px!important;font-size:.86rem!important}
.rm-acts{grid-template-columns:minmax(0,1fr) minmax(0,1fr)!important}
.rm-acts>button{white-space:normal!important;min-width:0!important;max-width:none!important;flex:none!important}
.rm-chev{width:20px!important;height:20px!important;border:0!important;transform:none!important;margin:0!important;color:var(--u-muted)}
.rm-navt small{white-space:normal!important;overflow:visible!important}
