:root{--bg:#070d17;--panel:#0e1828;--surface:#122035;--line:#263a54;--text:#e8eef9;--muted:#93a7c2;--blue:#3b82f6}*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--text);font:14px/1.5 "PingFang SC","Microsoft YaHei",sans-serif}.nearby-page{max-width:1580px;margin:auto;padding:27px 32px 42px}.page-head .eyebrow{color:#76aaff;font-size: var(--admin-font-caption);font-weight: var(--admin-weight-strong)}.page-head h1{margin:3px 0 3px;font-size: var(--admin-font-title);color:#f6f9ff}.page-head p{margin:0;color:var(--muted)}.search-panel{margin-top:22px;padding:18px 20px;background:var(--panel);border:1px solid var(--line);border-radius:12px}.search-fields{display:grid;grid-template-columns:minmax(150px,190px) minmax(260px,1fr) minmax(150px,190px);gap:14px}.field{min-width:0}.field label,.advanced label{display:block;color:#b6c7db;font-size: var(--admin-font-caption);font-weight: var(--admin-weight-strong);margin-bottom:7px}.field input,.field select,.advanced input{width:100%;height:44px;border:1px solid #344a65;border-radius:8px;padding:0 12px;background:var(--surface);color:var(--text);font:inherit}.field input:focus,.field select:focus,.advanced input:focus{outline:2px solid var(--blue);outline-offset:1px}.place-field{position:relative}.places{position:absolute;z-index:10;top:74px;left:0;right:0;max-height:300px;overflow-y:auto;background:#14243a;border:1px solid #42658d;border-radius:9px;box-shadow:0 16px 36px #030913b8}.places[hidden]{display:none}.place-option{display:block;width:100%;padding:10px 13px;border:0;border-bottom:1px solid #2d415b;text-align:left;background:transparent;color:var(--text);font:inherit;cursor:pointer}.place-option:last-child{border-bottom:0}.place-option:hover,.place-option:focus{background:#1b385c}.place-option small{display:block;color:#a6bad1;margin-top:2px}.location-line{margin:13px 0 0;color:#9db4d1;font-size: var(--admin-font-caption)}.location-line.confirmed{color:#9adab9}.location-line.error,.missing{color:#f9bd82}.advanced{margin-top:10px;font-size: var(--admin-font-caption);color:#93bafd}.advanced summary{cursor:pointer;width:max-content}.advanced-body{display:flex;align-items:flex-end;gap:9px;flex-wrap:wrap;padding:11px 0 1px}.advanced-body label{width:100%;margin:0}.advanced-body input{max-width:280px}.advanced-body a{color:#95c0ff;padding:10px 0}.advanced-body p{width:100%;color:var(--muted);margin:0}.btn{height:44px;padding:0 13px;border:1px solid #3a5e88;border-radius:7px;background:#1a3559;color:#dcecff;cursor:pointer}.result-toolbar{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:20px 0 12px}.result-toolbar>div:first-child{display:flex;align-items:baseline;gap:12px}.result-toolbar h2{margin:0;font-size: var(--admin-font-section);color:#f6f9ff}.result-toolbar #summary{color:var(--muted);font-size: var(--admin-font-label)}.toolbar-actions,.radius-group,.view-switch{display:flex;align-items:center;gap:6px}.radius-group span{color:var(--muted);font-size: var(--admin-font-caption);margin-right:4px}.radius-group button,.view-switch button{border:1px solid #304660;background:#152439;color:#acc0da;padding:8px 11px;border-radius:6px;font:inherit;cursor:pointer}.radius-group button.active,.view-switch button.active{background:#2f72de;border-color:#448cf9;color:#fff}.radius-group button:disabled{opacity:.5;cursor:not-allowed}.view-switch{margin-left:8px;gap:0}.view-switch button:first-child{border-radius:6px 0 0 6px}.view-switch button:last-child{border-radius:0 6px 6px 0;border-left:0}.map-layout{height:560px;display:grid;grid-template-columns:minmax(0,1fr) 330px;background:#0d192a;border:1px solid #2a405c;border-radius:12px;overflow:hidden}.map-layout[hidden],.list-view[hidden]{display:none}.map-stage{position:relative;overflow:hidden;background:#d8e4e5}.map-stage img{position:absolute;inset:0;width:100%;height:100%}.map-stage img[hidden]{display:none}.map-overlay{position:absolute;inset:0;pointer-events:none}.map-placeholder{position:absolute;inset:0;display:grid;place-items:center;text-align:center;padding:22px;color:#4b647a;font-weight: var(--admin-weight-strong)}.map-placeholder[hidden]{display:none}.map-marker{position:absolute;pointer-events:auto;transform:translate(-50%,-50%);display:grid;place-items:center;width:32px;height:32px;border-radius:50%;background:#2364cf;color:#fff;border:2px solid #fff;box-shadow:0 2px 7px #15243c88;cursor:pointer;font-weight: var(--admin-weight-strong)}.map-marker.selected{background:#fff;color:#1f5bbb;border:4px solid #3b82f6;width:40px;height:40px;z-index:2}.map-marker.center{width:auto;min-width:42px;height:30px;padding:0 9px;border-radius:16px;background:#14449a;z-index:3;white-space:nowrap}.radius-ring{position:absolute;transform:translate(-50%,-50%);border:2px dashed #4f90f9;border-radius:50%;background:#3b82f61c;pointer-events:none}.map-tools{position:absolute;top:12px;right:12px;display:grid;background:#fff;border-radius:7px;overflow:hidden;box-shadow:0 2px 9px #18304a55}.map-tools[hidden],.map-legend[hidden]{display:none}.map-tools button{width:34px;height:34px;border:0;background:#fff;color:#1b3e65;font-size:20px;cursor:pointer}.map-tools button+button{border-top:1px solid #d2dce4}.map-legend{position:absolute;bottom:12px;left:12px;padding:7px 9px;border-radius:6px;background:#102238eb;color:#e0ecf8;font-size: var(--admin-font-caption)}.map-legend i{display:inline-block;width:10px;height:10px;border-radius:50%;margin-right:4px}.center-dot{background:#3b82f6}.teacher-dot{background:#fff;border:2px solid #3b82f6;margin-left:8px}.teacher-rail{display:flex;flex-direction:column;min-height:0;border-left:1px solid #29405c}.rail-head{display:flex;justify-content:space-between;padding:13px 15px;border-bottom:1px solid #263a54}.rail-head span{color:var(--muted);font-size: var(--admin-font-caption)}.rail-results{flex:1;overflow:auto;padding:9px;display:grid;align-content:start;gap:8px}.rail-empty,.list-empty{color:var(--muted);text-align:center;padding:28px 14px}.teacher-card{padding:11px 12px;background:#132239;border:1px solid #304966;border-radius:9px;cursor:pointer}.teacher-card.selected{border-color:#5d9aff;box-shadow:inset 3px 0 #4c8ef9;background:#19314f}.teacher-card-head{display:flex;justify-content:space-between;gap:8px}.teacher-card strong{color:#f3f8ff;font-size: var(--admin-font-body)}.distance{color:#a6caff;font-weight: var(--admin-weight-strong);white-space:nowrap}.teacher-meta{margin:6px 0;color:#a7bcd6;font-size: var(--admin-font-caption)}.tags{display:flex;gap:5px;flex-wrap:wrap}.tag{color:#c6dcf9;background:#1b3553;border:1px solid #3b5f87;border-radius:4px;padding:2px 6px;font-size: var(--admin-font-caption)}.teacher-card-foot{display:flex;justify-content:space-between;gap:8px;align-items:center;margin-top:8px;color:#a7bcd6;font-size: var(--admin-font-caption)}.teacher-card a,.list-card a{color:#a2c8ff;text-decoration:none}.list-view{display:grid;gap:9px}.list-card{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:12px;align-items:center;padding:15px 18px;border:1px solid #2b405b;border-radius:9px;background:#112035;cursor:pointer}.list-card.selected{border-color:#5d9aff}.list-card h3{display:inline;margin:0 10px 0 0;font-size: var(--admin-font-body)}.list-card p{color:var(--muted);margin:7px 0 0}.list-card .right{text-align:right}.list-card .right a{display:block;margin-top:7px}.missing{margin:10px 0 0;font-size: var(--admin-font-caption)}.notice{color:#8498b2;margin:12px 0 0;font-size: var(--admin-font-caption)}@media(max-width:1180px){.map-layout{grid-template-columns:minmax(0,1fr) 290px}.nearby-page{padding:22px 18px}.result-toolbar{flex-wrap:wrap}}@media(max-width:780px){.search-fields{grid-template-columns:1fr}.map-layout{height:auto;grid-template-columns:1fr}.map-stage{height:410px}.teacher-rail{height:280px;border-left:0;border-top:1px solid #29405c}.result-toolbar>div:first-child{flex-wrap:wrap}}

.map-canvas{position:absolute;inset:0}.map-canvas[hidden]{display:none}
.map-canvas .map-marker{position:relative;left:auto;top:auto;transform:none}

/* Keep map labels readable without covering the teacher detail rail. */
.map-marker.teacher{width:156px;height:48px;padding:5px 9px;display:flex;flex-direction:column;align-items:flex-start;justify-content:center;gap:1px;border:2px solid #b8d7ff;border-radius:8px;background:#173a70;color:#fff;box-shadow:0 3px 10px #10233b88;text-align:left;line-height: var(--admin-line-title);z-index:1}
.map-marker.teacher strong,.map-marker.teacher span{display:block;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.map-marker.teacher strong{font-size: var(--admin-font-label)}.map-marker.teacher span{font-size: var(--admin-font-caption);font-weight: var(--admin-weight-medium);color:#deebff}
.map-marker.teacher::after{content:'';position:absolute;left:calc(50% - 6px);bottom:-8px;border-left:6px solid transparent;border-right:6px solid transparent;border-top:7px solid #173a70}
.map-marker.teacher.selected{width:156px;height:48px;padding:5px 9px;border:2px solid #2f77e7;background:#fff;color:#17498f;z-index:2}
.map-marker.teacher.selected span{color:#3c658f}.map-marker.teacher.selected::after{border-top-color:#fff}
.map-marker.teacher:focus-visible{outline:3px solid #75aaff;outline-offset:2px}
.map-overlay .map-marker.teacher{transform:translate(-50%,calc(-100% - 7px))}

.location-warnings{margin:0 0 12px;padding:10px 12px;border:1px solid #65523d;border-radius:8px;background:#251f1b;color:#f9bd82}
.location-warnings[hidden]{display:none}.location-warnings summary{cursor:pointer}.location-warnings a{display:inline-block;margin:8px 16px 0 0;color:#a2c8ff}.location-flag{display:block;color:#f9bd82;margin-top:4px}
.map-tools button{width:auto;min-width:34px}.map-tools .reset-map{font-size:13px;padding:0 10px}
.map-marker.teacher.compact{width:14px;height:14px;padding:0;border-radius:50%;border:2px solid #fff;background:#2364cf}.map-marker.teacher.compact strong,.map-marker.teacher.compact span,.map-marker.teacher.compact::after{display:none}

/* Portraits identify teachers consistently in the map and result cards. */
.teacher-avatar{position:relative;display:inline-grid;place-items:center;flex:none;width:42px;height:42px;overflow:hidden;border-radius:50%;background:#244a79;color:#e7f0ff;font-size:18px;font-weight:600;line-height:1}
.teacher-avatar img,.map-stage .teacher-avatar img{position:absolute;inset:0;display:block;width:100%;height:100%;object-fit:cover;border-radius:inherit}
.teacher-card-head{align-items:center;margin-bottom:10px}.teacher-identity{flex:1;min-width:0}.teacher-identity strong{display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.teacher-identity .teacher-meta{margin:3px 0 0}.list-identity{display:flex;align-items:center;gap:12px;min-width:0}.list-identity>div{min-width:0}.list-identity .teacher-avatar{width:48px;height:48px}
.teacher-marker{position:relative;width:44px;height:48px;pointer-events:auto;z-index:1}.teacher-marker.selected{z-index:3}
.avatar-pin{position:relative;display:block;width:44px;height:44px;padding:2px;border:2px solid #fff;border-radius:50%;background:#fff;box-shadow:0 2px 8px #10233b70;cursor:pointer;outline-offset:3px}
.avatar-pin .teacher-avatar{width:36px;height:36px;font-size:16px}.avatar-pin::after{content:'';position:absolute;bottom:-7px;left:15px;border-left:5px solid transparent;border-right:5px solid transparent;border-top:7px solid #fff}
.teacher-marker.selected .avatar-pin{border-color:#2563eb;box-shadow:0 0 0 4px #3b82f644,0 3px 9px #10233b66;transform:scale(1.1)}.teacher-marker.selected .avatar-pin::after{border-top-color:#2563eb}
.marker-detail{position:absolute;bottom:62px;left:22px;transform:translateX(-50%);display:grid;gap:4px;width:214px;padding:12px 14px;border:1px solid #b6cef2;border-radius:10px;background:#fff;color:#18375f;box-shadow:0 5px 20px #15243c40;font-size:13px;line-height:1.45;cursor:default}
.marker-detail strong{font-size:15px}.marker-detail span{color:#516782}.marker-detail a{color:#1d63c2;text-decoration:none;font-weight:600;padding-top:3px}.marker-detail::after{content:'';position:absolute;bottom:-8px;left:calc(50% - 8px);border-left:8px solid transparent;border-right:8px solid transparent;border-top:8px solid #fff}
.teacher-cluster{display:grid;place-items:center;width:50px;height:50px;padding:0;border:3px solid #fff;border-radius:50%;background:#2469cd;color:#fff;box-shadow:0 0 0 5px #3b82f633,0 2px 8px #10233b55;font-size:14px;line-height:1;font-weight:600;cursor:pointer;pointer-events:auto;white-space:nowrap}
.teacher-cluster:hover,.avatar-pin:hover{filter:brightness(1.08)}.teacher-cluster:focus-visible,.avatar-pin:focus-visible{outline:3px solid #74aaff}
.static-marker{position:absolute;transform:translate(-50%,-100%)}.static-marker.teacher-cluster{transform:translate(-50%,-50%)}
.search-area{position:absolute;top:12px;left:50%;transform:translateX(-50%);padding:9px 16px;background:#fff;color:#1c5ab3;border:1px solid #b6cef2;border-radius:20px;box-shadow:0 2px 8px #15243c33;font-size:14px;font-weight:600;cursor:pointer;z-index:5}.search-area[hidden]{display:none}
.result-extras{display:flex;gap:12px;align-items:flex-start;flex-wrap:wrap;margin-bottom:10px}.result-extras:has(>[hidden]:only-child){display:none}.result-extras .location-warnings{margin:0;padding:0;border:0;background:transparent;font-size:13px}.result-extras .location-warnings[open]{padding:9px 12px;border:1px solid #65523d;background:#251f1b;max-width:100%}.location-warnings[open] #locationWarningLinks{max-height:160px;overflow:auto}.result-scope{display:flex;align-items:center;gap:12px;color:#a6caff;font-size:13px}.result-scope[hidden]{display:none}.result-scope button{padding:2px 8px;border:1px solid #3a5e88;border-radius:5px;color:#c8ddfa;background:#152439;cursor:pointer}
/* Override the shared form-button radius only for geographic markers. */
.nearby-page .avatar-pin,.nearby-page .teacher-cluster{border-radius:50%!important;box-shadow:0 2px 8px #10233b70!important}
.nearby-page .teacher-cluster{box-shadow:0 0 0 5px #3b82f633,0 2px 8px #10233b55!important}.nearby-page .teacher-marker.selected .avatar-pin{box-shadow:0 0 0 4px #3b82f644,0 3px 9px #10233b66!important}.nearby-page .search-area{border-radius:20px!important}.admin-shell .map-tools button.reset-map{font-size:13px;line-height:1.4}
