/* 醫師星系 Doctor Galaxy — full-screen night-sky layer opened from the island wormhole */
.gx{position:fixed;inset:0;z-index:40;background:#0F1733;color:#fff;overflow:hidden;font-family:var(--f-body)}
.gx[hidden]{display:none}
.gx.in{animation:gxIn .55s ease-out both}
.gx.out{animation:gxOut .38s ease-in both}
@keyframes gxIn{from{opacity:0;clip-path:circle(6% at 72% 22%)}to{opacity:1;clip-path:circle(150% at 72% 22%)}}
@keyframes gxOut{from{opacity:1}to{opacity:0}}
@media (prefers-reduced-motion: reduce){.gx.in,.gx.out{animation-duration:.01s}}
html.gx-lock,html.gx-lock body{overflow:hidden}
.gx-stage,.gx-stage canvas{position:absolute;inset:0;width:100%;height:100%;display:block;touch-action:none}
.gx-ov{position:absolute;inset:0;pointer-events:none}
.gx-top{position:absolute;left:0;right:0;top:0;padding:12px max(14px,env(safe-area-inset-left,0px)) 0;pointer-events:none}
.gx-top>*{pointer-events:auto}
.gx-back{font:inherit;font-size:13px;color:#fff;background:rgba(255,255,255,.14);border:1.5px solid rgba(255,255,255,.35);border-radius:99px;padding:5px 13px;cursor:pointer}
.gx-top h2{margin:8px 0 0;font-family:var(--f-display);font-weight:400;font-size:24px;letter-spacing:.06em}
.gx-sub{margin:0 0 8px;font-size:12.5px;opacity:.75}
.gx-chips{display:flex;gap:6px;flex-wrap:wrap}
.gx-chips button{font:inherit;font-size:12.5px;color:#fff;background:rgba(255,255,255,.08);border:1.5px solid rgba(255,255,255,.35);border-radius:99px;padding:4px 12px;cursor:pointer}
.gx-chips button.on{background:#fff;color:#1B2650;border-color:#fff;font-weight:700}
.gx.focused .gx-top h2,.gx.focused .gx-sub,.gx.focused .gx-chips,.gx.focused .gx-legend{display:none}
.gx-lab{position:absolute;left:0;top:0;pointer-events:auto;cursor:pointer;font:inherit;white-space:nowrap;text-align:center;font-size:12.5px;font-weight:700;color:#fff;
  background:rgba(15,23,51,.82);border-radius:10px;padding:3px 9px;border:1.5px solid #fff;will-change:transform}
.gx-lab small{display:block;font-weight:500;font-size:10.5px;opacity:.85}
.gx-lab.bq{border-color:#53E580}.gx-lab.tc{border-color:#56AAFF}.gx-lab.exit{border-color:#C9B6F0}
.gx-lab.off{display:none}
@media (max-width:600px){.gx-lab{font-size:11.5px;padding:2px 7px}.gx-lab small{font-size:9.5px}}
.gx.portrait .gx-lab small{display:none}
.gx.portrait .gx-lab.exit small{display:block}
.gx-legend{position:absolute;left:14px;bottom:max(14px,env(safe-area-inset-bottom,0px));display:flex;gap:14px;font-size:12px;background:rgba(15,23,51,.7);padding:6px 10px;border-radius:10px}
.gx-legend i{display:inline-block;width:18px;height:3px;border-radius:2px;vertical-align:middle;margin-right:5px}
.gx-say{position:absolute;left:0;top:0;max-width:230px;background:#fff;color:var(--ink);border-radius:16px;padding:9px 13px;font-size:15px;line-height:1.45;box-shadow:0 6px 18px rgba(0,0,0,.3);will-change:transform}
.gx-say b{display:block;font-size:12px;color:#8E6743;margin-bottom:2px}
.gx-say::after{content:"";position:absolute;left:-9px;top:22px;border:10px solid transparent;border-right-color:#fff;border-left:0}
.gx-card{position:absolute;left:0;right:0;bottom:0;max-height:58%;overflow:auto;background:var(--paper-2);color:var(--ink);border-radius:22px 22px 0 0;
  padding:12px 18px max(18px,env(safe-area-inset-bottom,0px));box-shadow:0 -8px 24px rgba(0,0,0,.35);animation:gxUp .35s ease-out both}
@keyframes gxUp{from{transform:translateY(40px);opacity:0}to{transform:none;opacity:1}}
@media (min-width:900px){.gx-card{left:auto;right:24px;bottom:24px;width:420px;max-height:calc(100% - 140px);border-radius:22px}}
.gx-grab{width:40px;height:4px;border-radius:2px;background:#D9CFBC;margin:0 auto 10px}
.gx-head{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.gx-head h3{margin:0;font-size:21px}.gx-head h3 span{font-size:14px;font-weight:500;color:var(--muted)}
.gx-tag{font-size:12px;border-radius:99px;padding:2px 10px;color:#14301F;font-weight:700}
.gx-lbl{font-size:12.5px;font-weight:700;color:var(--wood-dk);margin:12px 0 4px}
.gx-sp{display:flex;flex-wrap:wrap;gap:6px}
.gx-sp span{font-size:12.5px;border:1.5px solid var(--accent);color:var(--accent);border-radius:99px;padding:2px 9px}
.gx-cred{margin:0;font-size:12.5px;color:var(--muted);line-height:1.55}
.gx-steps{margin:0;padding-left:20px;font-size:13.5px;line-height:1.7}
.gx-steps b{color:var(--ink)}
.gx-btns{display:flex;gap:8px;margin-top:12px}
.gx-btn{flex:1;text-align:center;border-radius:12px;padding:11px 8px;font-weight:700;font-size:14px;text-decoration:none}
.gx-btn.main{background:var(--accent);color:#fff}.gx-btn.ghost{border:1.5px solid var(--accent);color:var(--accent)}
.gx-note{font-size:11px;color:#9A9083;margin:10px 0 0;line-height:1.5}
.gx-toast{position:absolute;left:50%;top:70px;transform:translateX(-50%);background:rgba(15,23,51,.92);color:#fff;font-size:13px;padding:7px 14px;border-radius:99px;z-index:2}
.gx-fx{position:absolute;inset:0;pointer-events:none;background:radial-gradient(circle at 50% 45%,rgba(201,182,240,.0),rgba(15,23,51,.0))}
.lbl.gx-entry{background:#F4EEFF;border-color:#C9B6F0;color:#5B3FA8}
.gx-rec{margin-top:16px;background:#F3EEFB;border-radius:14px;padding:12px}
.gx-rec h4{margin:0;font-size:15px;color:#5B3FA8}
.gx-rec-sub{margin:2px 0 8px;font-size:12px;color:var(--muted)}
.gx-rec-d{display:flex;align-items:center;gap:10px;width:100%;font:inherit;text-align:left;background:#fff;border:1.5px solid #E2D8F5;border-radius:12px;padding:8px 10px;margin-top:6px;cursor:pointer;color:var(--ink)}
.gx-rec-d i{flex:none;width:34px;height:34px;border-radius:50%;display:grid;place-items:center;font-style:normal;font-weight:700;color:#1B2650}
.gx-rec-d span{flex:1;min-width:0}.gx-rec-d b{display:block;font-size:14.5px}.gx-rec-d small{font-weight:500;color:var(--muted)}
.gx-rec-d em{display:block;font-style:normal;font-size:12px;color:var(--muted)}
.gx-rec-d u{flex:none;text-decoration:none;font-size:11.5px;font-weight:700;color:#14301F;border-radius:99px;padding:2px 8px}
.gx-rec-d::after{content:"›";font-size:18px;color:#9A86CC}
.gx-rec-note{margin:8px 0 0;font-size:11px;color:#9A9083}
.gx-zoom{position:absolute;right:14px;bottom:max(14px,env(safe-area-inset-bottom,0px));display:flex;flex-direction:column;gap:8px;align-items:flex-end}
.gx-zoom button{font:inherit;width:44px;height:44px;border-radius:50%;font-size:22px;line-height:1;color:#fff;background:rgba(15,23,51,.82);border:1.5px solid rgba(255,255,255,.45);cursor:pointer}
.gx-zoom button.rs{width:auto;height:auto;border-radius:99px;font-size:13px;padding:6px 12px}
.gx.focused .gx-zoom{display:none}
.gx.zoomed .gx-lab small{display:block}
.gx-lbl small{font-weight:500;color:#9A9083;font-size:11px;margin-left:4px}
.gx-sp a{font-size:12.5px;border:1.5px solid var(--accent);background:var(--accent);color:#fff;border-radius:99px;padding:2px 9px;text-decoration:none}
.gx-cred a{color:var(--accent);font-weight:700;text-decoration:none;white-space:nowrap}
.gx-sched{width:100%;border-collapse:separate;border-spacing:3px;table-layout:fixed;font-size:12.5px;text-align:center}
.gx-sched th{font-weight:700;color:var(--muted);padding:3px 0}
.gx-sched td{background:#EEE9DF;border-radius:6px;height:26px}
.gx-sched td.on i{display:inline-block;width:12px;height:12px;border-radius:50%;background:var(--bc)}
.gx-sched td.on{background:color-mix(in srgb,var(--bc) 18%,#fff)}
.gx-sched td.rot{color:#14301F;font-weight:700;background:color-mix(in srgb,var(--bc) 18%,#fff)}
.gx-sched td.off{color:#B5AC9E;font-size:11.5px}
.gx-sched-n{margin:4px 0 0;font-size:11.5px;color:var(--muted);line-height:1.6}
.gx-sched-n a{color:var(--accent);font-weight:700;text-decoration:none}
.gx.zoomed .gx-top h2,.gx.zoomed .gx-sub{display:none}
.gx-zoom{z-index:3}
.gx-zoom button{box-shadow:0 2px 8px rgba(0,0,0,.35)}
.gx-ret{position:relative;background:#EEF8F1;border:1.5px solid #9ED4AE;border-radius:14px;padding:10px 12px 12px;margin:2px 0 6px}
.gx-ret b{display:block;font-size:14.5px;color:#245C34}
.gx-ret span{display:block;font-size:12.5px;color:var(--muted);margin:2px 0 8px}
.gx-ret .gx-btn{display:block;padding:9px 8px}
.gx-ret .x{position:absolute;right:6px;top:4px;border:0;background:none;font-size:20px;color:#9A9083;cursor:pointer}
.gx-zhint{display:none}
.gx.portrait .gx-zhint{display:inline}
.gx.portrait:not(.zoomed) .gx-lab{font-size:10.5px;padding:1px 6px;border-radius:8px}
.sh-top .shback{flex:none;align-self:center;font:inherit;font-size:13px;font-weight:700;color:var(--accent);background:#fff;border:1.5px solid var(--accent);border-radius:99px;padding:5px 11px;cursor:pointer;white-space:nowrap}
.gx-ctx{margin-top:12px;background:#F3EEFB;border-radius:12px;padding:8px 10px;font-size:12px;color:var(--muted);display:flex;flex-wrap:wrap;align-items:center;gap:2px 8px}
.gx-ctx span{flex:1 1 100%}
.gx-ctx b{flex:1;color:#5B3FA8;font-size:13px;min-width:0}
.gx-ctx button{font:inherit;font-size:12px;color:#8E6743;background:none;border:0;text-decoration:underline;cursor:pointer;padding:0}
