:root{font-family:'Microsoft YaHei','PingFang SC',system-ui,sans-serif;color:#132e49;background:#f5f8fc;font-synthesis:none;--blue:#2563eb;--muted:#6b7f94;--line:#dce5ef}*{box-sizing:border-box}body{margin:0;overflow:hidden}button,select,input{font:inherit}button,select{cursor:pointer}button{background:white;border:1px solid var(--line);border-radius:7px;color:inherit;padding:8px 12px;transition:background .15s,border-color .15s}button:hover{background:#edf3ff;border-color:#96b5f4}button:focus-visible,select:focus-visible,input:focus-visible,a:focus-visible,#stage:focus-visible{outline:3px solid #5f92ed;outline-offset:2px}button.active,button.primary{background:var(--blue);border-color:var(--blue);color:white}header{height:72px;background:#132e49;color:white;display:flex;align-items:center;justify-content:space-between;padding:0 25px;gap:15px}.brand{display:flex;align-items:center;gap:12px;color:white;text-decoration:none;font-size:23px;font-weight:650;white-space:nowrap}.brand svg{width:34px;height:38px;fill:none;stroke:#8fc9ff;stroke-width:1.6}.brand small{display:block;font-size:11px;font-weight:400;letter-spacing:1px;color:#b1c8df;margin-top:2px}.header-actions{display:flex;gap:9px}.header-actions button{background:#24435f;border-color:#48627a;color:white;font-size:13px}.header-actions button:hover{background:#375a7b}.mobile-button{display:none}main{display:grid;grid-template-columns:205px minmax(0,1fr) 330px;height:calc(100dvh - 104px)}aside{background:white;overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin}#library{padding:25px 16px 16px;border-right:1px solid var(--line);display:flex;flex-direction:column}.aside-head{font-size:15px;font-weight:650;margin-bottom:20px}.aside-head span{display:block;font-size:11px;font-weight:400;color:var(--muted);margin-top:6px}.model-button{width:100%;padding:14px 12px;text-align:left;margin-bottom:9px;display:flex;align-items:center;gap:11px;border-color:transparent;background:#f5f8fc;border-radius:8px}.model-button.active{background:#e9f0ff;color:#214d9b;border-color:#bdd0f4}.model-symbol{width:34px;height:36px;display:grid;place-items:center;font-size:13px;font-weight:700;border:1px solid currentColor;border-radius:5px;opacity:.85}.model-button strong{display:block;font-size:14px;font-weight:600}.model-button small{display:block;font-size:10px;margin-top:4px;color:var(--muted)}.library-note{margin-top:auto;padding-top:24px;font-size:11px;line-height:1.8;color:var(--muted)}.library-note strong{color:#385472;font-size:12px}.library-note button{font-size:10px;width:100%;padding:8px 3px}.workspace{min-width:0;position:relative;overflow:hidden;background:#f5f8fc}.workspace-top{position:absolute;top:25px;left:26px;right:26px;z-index:3;display:flex;justify-content:space-between;align-items:center;gap:14px;pointer-events:none}.workspace-top>*{pointer-events:auto}#type-label{font-size:11px;color:var(--muted);letter-spacing:.6px}h1{margin:7px 0 0;font-size:27px;font-weight:600}h1 small{font-size:17px;color:var(--muted);font-weight:400;margin-left:6px}.repeat-control{display:flex;align-items:center;gap:8px;font-size:11px;color:var(--muted)}select{border:1px solid var(--line);background:white;color:#24435f;border-radius:6px;padding:8px;max-width:100%}.mode-tabs{position:absolute;top:105px;left:26px;z-index:3;display:flex;background:#e7edf6;border-radius:9px;padding:4px;gap:2px}.mode-tabs button{font-size:12px;padding:8px 12px;background:transparent;border:0;color:#5f738a}.mode-tabs button.active{background:white;color:#214d9b;box-shadow:0 1px 3px #17354b12}#stage{position:absolute;inset:0;touch-action:none}#stage canvas{display:block;width:100%;height:100%;touch-action:none}#labels{position:absolute;inset:0;pointer-events:none;z-index:2;overflow:hidden}.atom-label{position:absolute;background:#ffffffed;border:1px solid #cddbed;border-radius:5px;padding:3px 6px;font-size:11px;white-space:nowrap;box-shadow:0 1px 4px #132e4910;transform:translate(-50%,-140%)}.atom-label.center{background:#fff2d5;color:#75500a;border-color:#ebc66c;font-weight:650}.stage-hint{position:absolute;bottom:76px;left:50%;transform:translateX(-50%);z-index:3;pointer-events:none;padding:8px 14px;border:1px solid #d8e2ef;border-radius:7px;font-size:11px;text-align:center;max-width:90%;background:#fffffff2;color:#5f738a;line-height:1.5}.stage-footer{position:absolute;bottom:20px;left:24px;right:24px;display:flex;justify-content:space-between;align-items:center;gap:10px;z-index:3}#legend{display:flex;gap:13px;font-size:11px;flex-wrap:wrap}#legend span{display:flex;align-items:center;gap:6px}#legend i{width:10px;height:10px;display:inline-block;border-radius:50%;background:var(--color)}.view-actions{display:flex;gap:5px}.view-actions button{font-size:11px;padding:7px 9px}#inspector{border-left:1px solid var(--line);padding:23px 22px}.panel-heading{display:flex;justify-content:space-between;align-items:center;font-size:14px;font-weight:650;padding-bottom:18px;border-bottom:1px solid var(--line);margin-bottom:19px}.live-dot{font-size:10px;font-weight:400;color:#73879b}.live-dot:before{content:'';display:inline-block;width:5px;height:5px;background:#35a58a;border-radius:50%;margin-right:5px}.section{margin:19px 0 0;padding-top:17px;border-top:1px solid var(--line)}h2{font-size:14px;font-weight:650;margin:0 0 13px}h3{font-size:12px;font-weight:600;margin:0 0 9px}.label{font-size:11px;color:var(--muted);display:block;margin-bottom:8px}.row{display:flex;align-items:center;justify-content:space-between;gap:9px;margin:10px 0;font-size:12px}.row select{font-size:12px;flex:1;min-width:0}.row label{flex:none}.subtle{font-size:11px;line-height:1.8;color:var(--muted);margin:9px 0}.note{font-size:11px;line-height:1.8;background:#f1f5fb;border-left:3px solid #adc2e2;padding:10px 11px;margin-top:13px}.result{display:flex;align-items:center;gap:15px;background:#ecf3ff;border-radius:9px;padding:16px;margin:15px 0}.result .number{font-size:44px;line-height:1;font-weight:600;color:#285dd2}.result strong{font-size:12px;display:block}.result small{font-size:11px;display:block;color:#607995;margin-top:7px}.formula{font-family:Cambria,'Times New Roman',serif;font-size:21px;color:#2657a0;line-height:1.7}.metric{display:flex;justify-content:space-between;align-items:center;font-size:12px;padding:8px 0}.metric strong{font-weight:600;color:#255caa}.toggle{display:flex;align-items:center;gap:8px;font-size:12px;margin:12px 0;cursor:pointer}.toggle input{accent-color:var(--blue);width:15px;height:15px;margin:0}input[type=range]{width:100%;accent-color:var(--blue);cursor:pointer}table{width:100%;border-collapse:collapse;font-size:11px;text-align:left}th{color:var(--muted);font-weight:400}td,th{padding:8px 3px;border-bottom:1px solid #edf1f6}td:last-child,th:last-child{text-align:right}.count-total{margin-top:12px;font-size:12px;line-height:1.8}.count-total strong{color:#255caa}.chips{display:flex;gap:5px;flex-wrap:wrap}.chips button{font-size:11px;padding:6px 9px}.neighbor-list{display:grid;grid-template-columns:repeat(3,1fr);gap:4px;margin-top:11px}.neighbor-list button{font-size:10px;padding:6px 2px;background:#f6f9fd}.quiz{padding:10px 0;border-bottom:1px solid #edf1f6}.quiz p{font-size:11px;line-height:1.7;margin:0 0 6px}.quiz button{font-size:10px;padding:4px 7px}.quiz .answer{color:#255caa;margin-top:8px}.density-grid{display:grid;grid-template-columns:1fr 1fr;gap:9px}.density-grid label{font-size:10px;color:var(--muted)}.density-grid input{display:block;min-width:0;width:100%;padding:8px;border:1px solid var(--line);border-radius:5px;color:#132e49;margin-top:6px}.hidden-answers .reveal{visibility:hidden}.statusbar{height:32px;display:flex;align-items:center;justify-content:space-between;gap:15px;border-top:1px solid var(--line);padding:0 22px;font-size:10px;color:#788b9f;background:#fff}#toast{position:absolute;top:165px;left:50%;transform:translateX(-50%);background:#132e49;color:white;font-size:12px;padding:10px 18px;border-radius:7px;z-index:5;opacity:0;pointer-events:none;transition:opacity .2s}#toast.show{opacity:1}dialog{max-width:620px;width:calc(100% - 34px);max-height:85dvh;border:1px solid var(--line);border-radius:14px;padding:25px;color:#132e49;line-height:1.9}dialog::backdrop{background:#132e4977}.dialog-head{display:flex;justify-content:space-between;align-items:center;gap:12px}.dialog-head h2{font-size:18px;margin:0}dialog p{font-size:13px}dialog a{color:#2563eb}#shade{display:none}#webgl-error{position:absolute;top:40%;left:10%;width:80%;font-size:14px;line-height:1.9;padding:20px;background:white;border:1px solid #c7d6e8;z-index:2}@media(min-width:1600px){main{grid-template-columns:230px minmax(0,1fr) 365px}#inspector{padding:26px}.model-button{padding:16px 14px}}@media(max-width:1100px){main{grid-template-columns:minmax(0,1fr) 305px}#library{position:fixed;left:0;top:72px;bottom:32px;width:230px;z-index:8;transform:translateX(-100%);transition:transform .18s}.mobile-button#models-toggle{display:block}body.library-open #library{transform:none}body.library-open #shade{display:block;position:fixed;inset:72px 0 32px;background:#132e4945;z-index:7}.workspace-top{left:20px;right:20px}.mode-tabs{left:20px}.repeat-control{display:block}.repeat-control label{display:block;margin-bottom:5px}#inspector{padding:20px 17px}}@media(max-width:760px),(max-width:1100px) and (max-height:520px){header{height:61px;padding:0 12px}.brand{font-size:18px;gap:7px}.brand svg{width:26px;height:30px}.brand small{font-size:8px;letter-spacing:0}.header-actions{gap:5px}.header-actions button{padding:7px 8px;font-size:11px}#full{display:none}#export{font-size:0}#export:after{content:'导图';font-size:11px}.mobile-button{display:block}main{height:calc(100dvh - 88px);display:block}.workspace{height:100%}#inspector{position:fixed;right:0;top:61px;bottom:27px;width:min(325px,88vw);transform:translateX(100%);transition:transform .18s;z-index:8}#library{top:61px;bottom:27px}.panel-open #inspector{transform:none}body.panel-open #shade,body.library-open #shade{display:block;position:fixed;inset:61px 0 27px;background:#132e4945;z-index:7}.statusbar{height:27px;font-size:9px;padding:0 12px}.statusbar span:last-child{display:none}.workspace-top{top:18px;left:16px;right:16px}h1{font-size:23px}h1 small{font-size:14px}.mode-tabs{top:91px;left:16px}.mode-tabs button{font-size:11px;padding:8px 10px}.stage-footer{left:14px;right:14px;bottom:13px;align-items:end}#legend{max-width:140px;font-size:10px;gap:7px}.view-actions button{font-size:10px;padding:7px}.stage-hint{bottom:63px;font-size:10px;min-width:230px}.header-actions #hide-answer{font-size:10px;padding:7px 6px}}@media(max-height:520px){header{height:49px}.brand small{display:none}main{height:calc(100dvh - 73px)}.statusbar{height:24px}#library,#inspector{top:49px;bottom:24px}body.panel-open #shade,body.library-open #shade{inset:49px 0 24px}.workspace-top{top:12px}h1{font-size:20px;margin-top:2px}.mode-tabs{top:68px}.mode-tabs button{padding:6px 9px}.stage-hint{bottom:51px;padding:4px 10px}.stage-footer{bottom:10px}}@media(prefers-reduced-motion:reduce){*{transition:none!important}}

.single-cell-badge{font-size:11px;color:#6b7f94;border:1px solid #dce5ef;border-radius:6px;padding:8px 12px;background:#fff}.model-symbol{font-size:12px}

.model-group h2{font-size:12px;color:#73879b;margin:14px 0 9px;font-weight:600}.model-group:first-child h2{margin-top:0}.model-button{padding:10px 9px;margin-bottom:6px;gap:8px}.model-button small{font-size:9px}.model-symbol{font-size:11px;width:38px;flex:none}.library-note{padding-top:14px}#model-list{flex:1;min-height:0;overflow-y:auto;scrollbar-width:thin;padding-right:2px}.library-note p{margin:5px 0 9px}@media(min-width:1600px){.model-button{padding:12px 10px}}

#distance-labels{position:absolute;inset:0;pointer-events:none;z-index:2;overflow:hidden}.distance-label{position:absolute;transform:translate(-50%,-50%);white-space:nowrap;background:#ffffffec;border:1px solid #e0c799;border-radius:4px;padding:3px 6px;color:#8b5c15;font:12px Cambria,'Microsoft YaHei',serif;line-height:16px;box-shadow:0 1px 3px #132e4910}.measurement-table{margin:14px 0}.measurement-table td:first-child{font-size:10px}.measurement-table td:last-child{color:#96651c;font-family:Cambria,serif}.mode-tabs button{padding:8px 10px}@media(max-width:760px),(max-width:1100px) and (max-height:520px){.mode-tabs button{font-size:10px;padding:8px}.distance-label{font-size:11px;padding:2px 4px}}

.distance-label{z-index:2}.distance-leader{position:absolute;height:0;border-top:1px solid #c3a461;opacity:.65;transform-origin:0 0;z-index:1;pointer-events:none}

#legend .silica-si,#legend .silica-o{background:#fff5f6;border:2px solid #9f4159}#legend .silica-si{width:14px;height:14px}#legend .silica-o{width:9px;height:9px}

#legend .silica-si{background:radial-gradient(circle at 30% 25%,#f0aec6,#d77498 55%,#9b4f6c);border:1px solid #bf7490}#legend .silica-o{background:radial-gradient(circle at 30% 25%,#fff,#e5e9ef 55%,#b4becc);border:1px solid #bac5d4}

.projection-tabs{display:flex;gap:5px;padding:0 0 10px;flex:none}.projection-tabs[hidden]{display:none}.projection-tabs button{font-size:12px;padding:7px 13px;border-radius:6px}.projection-tabs button.active{background:#e0eefb;border-color:#6e9fd1;color:#174d7d}.projection-caption{position:absolute;top:13px;left:50%;transform:translateX(-50%);font-size:11px;background:#fffffff2;border:1px solid #d4e0ed;padding:6px 10px;border-radius:5px;pointer-events:none;z-index:3;white-space:nowrap}.projection-caption[hidden]{display:none}@media(max-width:760px),(max-width:1100px) and (max-height:520px){.projection-tabs{gap:4px;padding-bottom:7px}.projection-tabs button{font-size:10px;padding:6px 9px}.projection-caption{font-size:10px;top:7px}}
.projection-tabs{position:absolute;top:151px;left:26px;z-index:3;background:#f5f8fc;padding:3px}.projection-caption{top:196px}@media(max-width:1100px){.projection-tabs{left:20px}}@media(max-width:760px),(max-width:1100px) and (max-height:520px){.projection-tabs{top:136px;left:16px}.projection-caption{top:174px}}@media(max-height:520px){.projection-tabs{top:112px}.projection-caption{top:147px}}

.projection-caption{left:auto;right:26px;top:65px;transform:none}@media(max-width:760px),(max-width:1100px) and (max-height:520px){.projection-caption{right:16px;top:55px}}

.header-actions .license-open{background:#f3ca6a;border-color:#f3ca6a;color:#273747;font-weight:600}.header-actions .license-open.unlocked{background:#24435f;color:#d7edff;border-color:#48627a}.model-lock{width:16px;height:18px;fill:none;stroke:currentColor;stroke-width:1.6;margin-left:auto;flex:none;color:#7d8d9c}.model-locked{opacity:.75}#license-form{display:grid;gap:10px;margin:20px 0}#license-code{font:24px ui-monospace,monospace;padding:12px;border:1px solid #bccfdf;border-radius:7px;letter-spacing:.15em;width:100%;min-width:0}#license-submit{background:#2563eb;color:white}#license-error{color:#b72d35;min-height:20px;font-size:13px}.license-note{font-size:12px;color:#6b7f94}#license-clear[hidden]{display:none}@media(max-width:760px),(max-width:1100px) and (max-height:520px){.header-actions #license-open{font-size:10px;padding:7px 5px}.brand{font-size:16px}.brand svg{width:22px}.header-actions{gap:3px}}
