/* 首页专用布局：按实际视口分配空间，优先展示学科、搜索与首排模型。 */
.science-home{--home-navy:#142f46;--home-teal:#116f67;--home-line:#d9e3e8;width:min(1720px,calc(100% - 80px));padding:24px 0 0;color:var(--home-navy)}
body:has(.science-home) .site-header,body:has(.science-home)>footer{width:min(1720px,calc(100% - 80px))}
body:has(.science-home) .nav-home{color:#116f67}
.science-home a:focus-visible,.science-home button:focus-visible,.science-home input:focus-visible{outline:3px solid #258fbe;outline-offset:3px}
.home-hero{display:grid;grid-template-columns:1.15fr 1fr;gap:48px;align-items:center;padding:30px 36px;border-radius:14px;background:#142f46;color:#fff}
.home-eyebrow{margin:0 0 14px;color:#a5d9cf;font-size:14px;letter-spacing:.08em}
.home-intro h1{margin:0;font-size:42px;line-height:1.3;letter-spacing:.015em;font-weight:700}
.home-intro h1 em{color:#93dfcd;font-style:normal}
.home-description{margin:14px 0 18px;color:#d0dce4;font-size:17px;line-height:1.7}
.home-actions{display:flex;flex-wrap:wrap;gap:12px}
.home-actions a{display:flex;align-items:center;justify-content:space-between;gap:22px;min-height:46px;padding:0 18px;border-radius:6px;font-size:17px;font-weight:600;transition:background .18s}
.home-primary{color:#123f3d;background:#a0e5d5}.home-primary:hover{background:#bcf2e6}
.home-secondary{border:1px solid #708594;color:#fff}.home-secondary:hover{background:#294c62}
.home-access{margin:12px 0 0;color:#b9cbd6;font-size:13px;line-height:1.6}.home-access>span{margin:0 5px}
.home-subjects{border-left:1px solid #456071;padding-left:36px}
.home-resource-total{display:flex;align-items:baseline;flex-wrap:wrap;gap:8px 18px;margin-bottom:18px}
.home-resource-total>span{font-size:18px;font-weight:600}.home-resource-total strong{font-size:30px;color:#a0e5d5;font-weight:600}.home-resource-total small{font-size:14px;color:#d0dce4;font-weight:400}
.home-resource-total p{flex-basis:100%;margin:0;color:#b9cbd6;font-size:14px}
.home-subject-links{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.home-subject-links>a{position:relative;display:flex;align-items:baseline;flex-wrap:wrap;gap:8px 12px;min-height:60px;padding:17px 34px 17px 16px;border:1px solid #496474;border-radius:7px;background:#203d51;transition:background .18s,border-color .18s}
.home-subject-links>a:hover{background:#2b4d5f;border-color:#8ed6c7}
.home-subject-links>a>span{font-size:18px;font-weight:600}.home-subject-links>a>small{font-size:14px;color:#bad1dc}.home-subject-links i{position:absolute;right:13px;top:18px;font-style:normal;color:#9bdfd0}
.home-section-heading{display:flex;justify-content:space-between;align-items:center;gap:20px;margin:28px 0 16px}
.home-section-heading>div{display:flex;align-items:baseline;gap:20px}.home-kicker{margin:0;color:#39776f;font-size:12px;letter-spacing:.07em;font-weight:600}
.home-section-heading h2{margin:0;font-size:26px;font-weight:700}.home-library-heading>div{flex-direction:row-reverse}.home-library-heading{scroll-margin-top:20px}
.home-library-note{margin:0;color:#607787;font-size:15px}.home-section-heading>a{color:#326b72;font-size:16px;min-height:44px;display:flex;align-items:center;gap:14px}
.science-home .model-groups{display:grid;grid-template-columns:minmax(0,1fr) 220px;align-items:center;gap:14px;padding:12px;margin:0;border:1px solid var(--home-line);border-radius:9px;box-shadow:none}
.science-home .model-group-intro{grid-column:2;grid-row:1;margin:0;min-width:0}.science-home .model-group-intro>div{display:none}
.home-search{display:flex;align-items:center;gap:10px;width:100%;min-height:46px;padding:0 13px;border:1px solid #cbd9e0;border-radius:6px;background:#f8fafb}
.home-search:focus-within{border-color:#258fbe;box-shadow:0 0 0 2px #258fbe24}.home-search svg{flex-shrink:0;stroke:#627e8e;fill:none;stroke-width:1.8}.home-search input{width:100%;min-width:0;height:44px;border:0;background:transparent;color:#18394f;font-size:17px}.science-home .home-search input:focus-visible{outline:none}.home-search input{text-overflow:ellipsis}.home-search input::placeholder{color:#617787}
.science-home .model-group-tabs{grid-column:1;grid-row:1;display:flex;gap:8px;flex-wrap:wrap}
.science-home .model-group-tab{justify-content:center;gap:8px;min-height:46px;padding:9px 10px;border:1px solid transparent;border-radius:6px;background:#f0f4f6;color:#405c70;font-size:17px;font-weight:600}
.science-home .model-group-tab:hover{border-color:#95bcb7}.science-home .model-group-tab b{min-width:0;padding:2px 5px;border-radius:4px;background:#e2e9ed;color:#526b79;font-size:13px}
.science-home .model-group-tab.active{background:#184b50;border-color:#184b50;color:#fff;box-shadow:none}.science-home .model-group-tab.active b{color:#d8f1eb;background:#37686b}
.home-results{margin:12px 2px;color:#607888;font-size:14px}
.science-home .model-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:20px}
.science-home .model-card{height:100%;border-radius:9px;box-shadow:0 2px 4px #173f5905;transition:border-color .18s,box-shadow .18s}
.science-home .model-card:not(.locked):hover{transform:none;border-color:#77a9a4;box-shadow:0 7px 20px #173f5912}
.science-home .card-visual{height:210px;border-bottom:1px solid #e3ebef;background:#f0f5f8}
.science-home .visual-top span,.science-home .visual-top b{font-size:13px;font-weight:600;white-space:nowrap}.science-home .visual-top b{max-width:68%;overflow:hidden;text-overflow:ellipsis}
.science-home .card-body{padding:18px 20px;min-height:180px}
.science-home .card-body h3{font-size:21px;line-height:1.45;margin-right:32px}
.science-home .card-body p{display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;color:#5e7484;font-size:15px;line-height:1.65;min-height:50px}
.science-home .free-badge{font-size:12px;font-weight:600;color:#226b5e;background:#ebf7f2;border:1px solid #c1ddd2;box-shadow:none}
.science-home .card-index{color:#81939f;font-size:14px;font-weight:400;top:21px;right:16px}
.science-home .card-action{display:flex;justify-content:space-between;color:#246779;font-size:16px;margin-top:12px;padding-top:10px;border-top:1px solid #edf1f4}
.home-empty{padding:40px 24px;border:1px dashed #bccfd7;border-radius:9px;background:#fff;text-align:center}.home-empty[hidden]{display:none}.home-empty h3{margin:0 0 9px}.home-empty p{color:#607787;font-size:16px}.home-empty button{min-height:46px;padding:0 20px;border:0;border-radius:5px;background:#184b50;color:#fff}
.home-featured{margin-top:32px;padding-top:6px;border-top:1px solid var(--home-line)}
.home-featured-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px}
.home-featured-card{position:relative;display:flex;align-items:center;gap:16px;min-width:0;padding:16px;border:1px solid var(--home-line);border-radius:9px;background:#fff}.home-featured-card:hover{border-color:#81b6b0}
.home-featured-visual{position:relative;flex:0 0 108px;height:108px;border-radius:6px;overflow:hidden;background:#f0f5f7}.home-featured-visual .thumbnail-diagram{background-size:contain;background-repeat:no-repeat}.home-featured-visual .thumbnail-diagram::after{display:none}
.home-featured-copy{min-width:0}.home-featured-copy>span{color:#5f7685;font-size:13px}.home-featured-copy h3{margin:7px 12px 6px 0;font-size:18px;line-height:1.5}.home-featured-copy p{margin:0;color:#607787;font-size:14px;line-height:1.6}.home-featured-card>b{position:absolute;right:12px;top:10px;color:#668c92;font-weight:400}
.home-teaching{display:grid;grid-template-columns:1fr 1.5fr;gap:40px;margin:36px 0 30px;padding:32px 36px;border-radius:10px;background:#eaf0f2}.home-teaching h2{margin:12px 0 20px;font-size:28px;line-height:1.5}.home-teaching a{color:#326e70;font-size:16px}.home-teaching ol{margin:0;padding:0;list-style:none;display:grid;gap:20px}.home-teaching li{display:flex;align-items:flex-start;gap:18px}.home-teaching li>b{color:#41857b;font-size:20px}.home-teaching h3{margin:0 0 5px;font-size:18px}.home-teaching p{margin:0;color:#5a7281;font-size:16px;line-height:1.6}
/* 较矮的桌面减少垂直留白与缩略图高度，不缩放整页或压缩图形比例。 */
@media(min-width:1101px) and (max-height:850px){
 .science-home{padding-top:16px}.home-hero{padding:12px 28px;gap:32px}.home-results{margin:8px 2px}.home-hero .home-access{display:none}.home-resource-total p{display:none}.home-intro h1 br{display:none}.home-intro h1{font-size:30px;line-height:1.35}.home-eyebrow{margin-bottom:8px}.home-description{margin:9px 0 12px;font-size:16px}.home-access{margin-top:8px}.home-subjects{padding-left:28px}.home-resource-total{margin-bottom:12px}.home-subject-links{gap:10px}.home-subject-links>a{padding-top:10px;padding-bottom:10px;min-height:44px}.home-section-heading{margin:12px 0 12px}.home-section-heading h2{font-size:24px}.science-home .model-groups{padding:12px;gap:14px;grid-template-columns:minmax(0,1fr) 220px}.science-home .model-group-tab{font-size:16px;padding:8px 10px}.science-home .card-visual{height:140px}.science-home .card-body{min-height:160px;padding:12px 16px}.science-home .card-body h3{font-size:19px}.science-home .card-index{top:18px}.science-home .card-body p{font-size:14px;min-height:46px}.science-home .card-action{margin-top:8px;padding-top:8px}.science-home .model-grid{gap:16px}
}
@media(max-width:1100px){
 .science-home,body:has(.science-home) .site-header,body:has(.science-home)>footer{width:calc(100% - 40px)}.home-hero{gap:26px;padding:26px}.home-intro h1{font-size:34px}.home-subjects{padding-left:24px}.home-subject-links>a{display:block}.home-subject-links small{display:block;margin-top:6px}.home-resource-total{gap:6px 12px}.science-home .model-groups{display:flex;flex-direction:column-reverse;align-items:stretch;gap:12px}.science-home .model-group-intro{width:100%}.science-home .model-group-tabs{justify-content:space-between}.science-home .model-group-tab{flex:1}.science-home .model-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.home-library-note{display:none}.home-featured-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.science-home .card-visual{height:180px}
}
@media(max-width:760px){
 .home-hero{grid-template-columns:1fr;gap:24px}.home-subjects{border-left:0;border-top:1px solid #456071;padding:20px 0 0}.home-subject-links>a{display:flex}.science-home .model-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.home-section-heading>div{display:block}.home-kicker{margin-bottom:6px}.home-section-heading h2{font-size:24px}.home-teaching{grid-template-columns:1fr}.home-featured-grid{grid-template-columns:1fr}
}
@media(max-width:580px){
 .science-home,body:has(.science-home) .site-header,body:has(.science-home)>footer{width:calc(100% - 28px)}.science-home{padding-top:14px}.home-hero{padding:24px 20px;border-radius:10px}.home-intro h1{font-size:34px}.home-eyebrow{font-size:12px;letter-spacing:0}.home-description{font-size:16px}.home-actions{gap:10px}.home-actions a{font-size:16px;padding:0 12px;gap:10px}.home-access{font-size:12px}.home-resource-total>span{font-size:17px}.home-resource-total strong{font-size:27px}.home-subject-links{gap:10px}.home-subject-links>a{display:block;padding:14px 28px 14px 12px}.home-subject-links>a>span{font-size:18px}.home-subject-links small{margin-top:5px}.home-section-heading{align-items:flex-start;flex-wrap:wrap;gap:8px}.home-library-heading .home-kicker{display:none}.science-home .model-groups{padding:12px}.science-home .model-group-tabs{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}.science-home .model-group-tab{font-size:16px;justify-content:space-between}.science-home .model-group-tab:first-child{grid-column:auto}.science-home .model-group-tab:last-child{grid-column:1/-1}.home-search input{font-size:16px}.science-home .model-grid{grid-template-columns:1fr;gap:16px}.science-home .card-visual{height:210px}.science-home .card-body{min-height:175px}.science-home .card-body h3{font-size:21px}.science-home .card-body p{font-size:16px}.home-teaching{padding:24px;gap:28px}.home-teaching h2{font-size:25px}
}
@media(prefers-reduced-motion:reduce){.science-home *{transition:none!important;animation:none!important}}
/* 未来感首屏：实验承担主要动效，目录保持浅底与清晰对比。 */
body:has(.science-home){background:radial-gradient(ellipse at 90% 0,#def2f6 0,transparent 38%),#f5f9fb}
.home-hero{position:relative;isolation:isolate;overflow:hidden;grid-template-columns:minmax(0,1fr) minmax(0,1.08fr);gap:24px 48px;padding:30px 36px 20px;border:1px solid #2f566e;border-radius:20px;background:radial-gradient(ellipse at 65% 0,#154b66 0,transparent 58%),linear-gradient(125deg,#101f36,#102e40 75%,#143e4a);box-shadow:0 18px 48px #173f5914}
.home-hero::before{content:'';position:absolute;z-index:-1;inset:0;background-image:radial-gradient(#b9ecf52e .8px,transparent .8px);background-size:28px 28px;mask-image:linear-gradient(90deg,transparent,#000);pointer-events:none}
.home-eyebrow{display:flex;align-items:center;gap:8px;color:#96dcdf}.home-eyebrow>span{width:6px;height:6px;flex-shrink:0;border-radius:50%;background:#7ff0d7;box-shadow:0 0 12px #7ff0d7}
.home-intro h1{font-size:clamp(34px,3.1vw,54px);letter-spacing:-.035em;line-height:1.3}.home-intro h1 em{color:#85ebdd}.home-description{max-width:460px;font-size:18px}
.home-actions a{min-height:48px;border-radius:8px;transition:background .2s,box-shadow .2s,transform .2s}.home-primary{background:#a1f2e3;box-shadow:0 0 22px #68e9d517}.home-primary:hover{box-shadow:0 0 28px #68e9d53b;transform:translateY(-2px)}.home-actions a>span{transition:transform .2s}.home-actions a:hover>span{transform:translate(3px,-2px)}
.home-optics{min-width:0;align-self:stretch;padding:16px 18px 12px;border:1px solid #6398b24d;border-radius:14px;background:#071b2b70;box-shadow:inset 0 1px #b7edff0d}
.optics-heading{display:flex;align-items:center;justify-content:space-between;gap:12px}.optics-status{font-size:11px;letter-spacing:.13em;color:#8bbacb}.optics-heading h2{font-size:23px;margin:5px 0 0;font-weight:600}
.home-optics button{min-height:44px;flex-shrink:0;padding:0 12px;border:1px solid #5e889d;border-radius:7px;background:#17394c;color:#dcf9f3;font-size:15px;transition:background .2s}.home-optics button:hover{background:#25566a}
#optics-scene{display:block;width:100%;height:230px;margin:6px 0;overflow:visible;user-select:none}.optics-labels{font-size:19px}.optics-drag-tip{font-size:17px}#optics-i-label,#optics-r-label{font-size:21px;font-style:italic}#optics-source{cursor:grab;touch-action:none}#optics-source:active{cursor:grabbing}
.optics-controls{display:flex;align-items:center;gap:12px;flex-wrap:wrap;font-size:17px}.optics-controls label,.optics-controls>span{white-space:nowrap}.optics-controls output{font-variant-numeric:tabular-nums;color:#ffcf85}.optics-controls>span output{color:#85ebdd;display:inline-block;min-width:48px}.optics-controls input{min-width:70px;width:0;flex:1;height:44px;accent-color:#85ebdd;cursor:ew-resize}.optics-controls button{font-size:14px}
.optics-note{margin:8px 0 0;color:#b9cfdc;font-size:13px;line-height:1.65}.optics-note span{display:block;color:#93afbf}
.home-subjects{grid-column:1/-1;display:flex;align-items:center;gap:28px;border:0;border-top:1px solid #7297a533;padding:16px 0 0}.home-resource-total{flex:0 0 auto;margin:0;gap:8px}.home-resource-total strong{font-size:26px;color:#a1f2e3}.home-resource-total>span{font-size:16px}.home-resource-total p{display:none}
.home-subject-links{display:flex;flex:1;gap:12px}.home-subject-links>a{flex:1;min-height:48px;align-items:center;justify-content:center;padding:10px 26px 10px 12px;gap:8px;background:#ffffff05;border-color:#8bbacb33;border-radius:8px}.home-subject-links>a>span{font-size:17px}.home-subject-links>a>small{font-size:13px;margin:0}.home-subject-links i{top:14px;right:10px}.home-subject-links>a:hover{background:#73dcc218;border-color:#8ed6c7;box-shadow:0 0 18px #6ff2d411}
/* 六个学科入口在中等桌面宽度下分两行，保持文字与点击面积，不挤压轮播。 */
@media(min-width:761px) and (max-width:1450px){.home-subject-links{display:grid;grid-template-columns:repeat(3,minmax(0,1fr))}}
.science-home .model-groups{border-radius:12px;background:#ffffffcf}.science-home .model-group-tab{transition:background .2s,color .2s,border-color .2s}.science-home .model-group-tab.active{background:#154653;border-color:#154653}
.science-home .model-card{border-radius:13px;transition:transform .22s,box-shadow .22s,border-color .22s}.science-home .model-card-link:hover .model-card,.science-home .model-card-link:focus-visible .model-card{transform:translateY(-5px);border-color:#75b7ba;box-shadow:0 14px 30px #16496919}.science-home .card-action i{font-style:normal;transition:transform .2s}.science-home .model-card-link:hover .card-action i{transform:translateX(5px)}
.home-featured-card{transition:transform .2s,border-color .2s,box-shadow .2s}.home-featured-card:hover{transform:translateY(-3px);box-shadow:0 8px 22px #16496912}
@media(min-width:1101px) and (max-height:850px){.home-hero{padding:18px 26px 14px;gap:12px 30px}.home-intro h1{font-size:38px}.home-intro h1 br{display:block}.home-description{font-size:17px}.home-optics{padding:10px 14px}.optics-heading h2{font-size:22px}#optics-scene{height:180px;margin:0}.home-subjects{padding-top:12px;gap:20px}.home-subject-links>a{min-height:44px;padding-top:8px;padding-bottom:8px}.home-section-heading{margin:16px 0 12px}}
@media(max-width:1100px){.home-hero{gap:22px;padding:24px}.home-intro h1{font-size:36px}.home-subjects{padding:16px 0 0;gap:16px;flex-wrap:wrap}.home-subject-links{flex-basis:100%;display:grid;grid-template-columns:repeat(4,minmax(0,1fr))}.home-subject-links>a{display:flex;flex-wrap:wrap}.home-subject-links small{display:inline}.optics-controls{gap:6px;font-size:16px}.optics-controls input{order:4;flex-basis:100%;width:100%}#optics-scene{height:auto}.optics-heading h2{font-size:20px}.optics-heading{align-items:flex-start}.home-optics{padding:14px}}
@media(max-width:760px){.home-hero{grid-template-columns:1fr}.home-intro h1{font-size:40px}.home-description{max-width:none}.home-optics{padding:14px}.optics-heading h2{font-size:22px}.optics-controls{font-size:17px;gap:10px}.optics-controls input{order:0;flex-basis:auto;width:0}.home-subject-links{grid-template-columns:repeat(2,minmax(0,1fr))}.home-subjects{gap:12px}.home-subject-links>a{justify-content:flex-start}.home-optics button{font-size:15px}.optics-note{font-size:13px}}
@media(max-width:580px){.home-hero{padding:24px 16px 16px;gap:24px;border-radius:16px}.home-eyebrow{font-size:12px}.home-intro h1{font-size:36px}.home-actions{display:grid;grid-template-columns:1fr}.home-actions a{font-size:17px}.home-access{font-size:12px}.home-optics{margin:0 -6px;padding:12px 10px}.optics-heading h2{font-size:21px}.optics-heading button{padding:0 8px;font-size:14px}.optics-controls{display:grid;grid-template-columns:1fr auto auto;gap:6px 10px}.optics-controls input{grid-row:2;grid-column:1/-1;width:100%;height:44px}.optics-controls>span{font-size:16px}.optics-drag-tip{display:none}.optics-labels{font-size:26px}#optics-scene{min-height:170px}.home-subject-links>a{padding:10px 24px 10px 10px}.home-subject-links>a>small{font-size:13px}}
.optics-labels{font-size:28px}.optics-note b{font-weight:400}.optics-drag-tip{font-size:23px}
#optics-pulse-in,#optics-pulse-out,#optics-i-label,#optics-r-label{pointer-events:none}
@media(max-width:580px){.optics-labels{font-size:30px}}
@media(prefers-reduced-motion:reduce){.science-home *{transition:none!important;animation:none!important}.science-home .model-card-link:hover .model-card,.science-home .model-card-link:focus-visible .model-card,.home-featured-card:hover,.home-primary:hover{transform:none}}
/* 高中物理教材目录：仅在高中筛选启用，其他学科沿用原卡片布局。 */
.physics-books{margin-top:20px;padding:22px 24px;background:#fff;border:1px solid #d9e3e8;border-radius:12px}.physics-books[hidden],.physics-chapters[hidden]{display:none}
.physics-edition{display:flex;align-items:baseline;gap:18px;margin-bottom:16px}.physics-edition strong{font-size:22px}.physics-edition span{font-size:15px;color:#607787}
.physics-book-tabs{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:10px}.physics-book-tabs button{min-height:48px;border:1px solid #d9e3e8;border-radius:7px;background:#f7fafb;color:#405c70;font-size:16px;padding:10px 8px;line-height:1.5}.physics-book-tabs button[aria-pressed=true]{background:#e5f3ef;border-color:#398b7d;color:#155b50;font-weight:700}
.physics-layout.physics-active{display:grid;grid-template-columns:240px minmax(0,1fr);gap:26px;align-items:start;margin-top:24px}.physics-results{min-width:0}.physics-chapters{background:#fff;border:1px solid #d9e3e8;border-radius:12px;padding:14px;position:sticky;top:20px}.physics-nav-title{margin:4px 8px 14px;color:#607787;font-size:14px;font-weight:600}.physics-chapters button{display:flex;align-items:center;justify-content:space-between;gap:10px;width:100%;min-height:54px;padding:12px 10px;margin:4px 0;border:1px solid transparent;border-radius:7px;background:transparent;color:#405c70;text-align:left;font-size:17px;line-height:1.6}.physics-chapters button b{font-size:13px;font-weight:500;border-radius:5px;background:#f0f4f6;padding:1px 7px}.physics-chapters button[aria-pressed=true]{background:#e8f4f0;border-color:#c1dfd5;color:#125e51;font-weight:600}.physics-chapters button:hover,.physics-book-tabs button:hover{border-color:#82b9ad}
.physics-active .home-results{margin:0 0 16px;font-size:18px;font-weight:600;color:#27495b;line-height:1.7}.science-home .physics-active .model-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.physics-card-chapter{display:none}.physics-catalog-active .physics-card-chapter{display:block;font-size:12px;color:#527d76;margin:0 30px 8px 0}.physics-catalog-active .card-body h3{margin-right:0}.physics-catalog-active .card-body{min-height:210px}.physics-catalog-active .card-body p{font-size:16px}.physics-catalog-active .card-visual{height:190px}
@media(max-width:1450px){.physics-book-tabs{grid-template-columns:repeat(3,minmax(0,1fr))}.physics-layout.physics-active{grid-template-columns:220px minmax(0,1fr);gap:20px}.science-home .physics-active .model-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:900px){.physics-layout.physics-active{grid-template-columns:1fr;gap:18px}.physics-chapters{position:static;display:flex;flex-wrap:wrap;gap:6px;padding:12px}.physics-nav-title{width:100%;margin:4px 8px}.physics-chapters button{width:auto;max-width:100%;margin:0;flex:1 1 220px}}
@media(max-width:580px){.physics-books{padding:18px 14px}.physics-edition{display:block}.physics-edition strong{display:block;font-size:21px;margin-bottom:6px}.physics-book-tabs{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.physics-book-tabs button{font-size:15px}.physics-chapters button{flex-basis:100%;font-size:17px;min-height:48px;padding:8px 10px}.science-home .physics-active .model-grid{grid-template-columns:1fr}.physics-active .home-results{font-size:17px}.physics-catalog-active .card-visual{height:210px}.physics-catalog-active .card-body{min-height:200px}}
/* 目录使用顶层浮窗，打开和关闭均不改变卡片可用宽度。 */
.physics-layout.physics-active{display:block;margin-top:22px}
.physics-catalog-bar{display:flex;align-items:center;gap:18px;margin:0 0 18px}
.physics-catalog-bar .home-results{margin:0;flex:1}
.physics-directory-button{flex-shrink:0;min-height:46px;padding:10px 18px;border:1px solid #87b7ac;border-radius:8px;background:#fff;color:#155e52;font-size:17px;font-weight:600}
.physics-directory-button[hidden]{display:none}
.physics-directory{width:min(440px,calc(100vw - 28px));max-height:calc(100dvh - 40px);padding:0;border:1px solid #d9e3e8;border-radius:16px;background:#fff;color:#27495b;box-shadow:0 24px 80px #102f4940;overflow:auto}
.physics-directory::backdrop{background:#102c454d}
.physics-directory>header{display:flex;align-items:center;justify-content:space-between;padding:16px 20px;border-bottom:1px solid #e3ecef}
.physics-directory h2{font-size:23px;margin:0}
.physics-directory-close{width:44px;height:44px;border:0;border-radius:7px;background:#f0f5f6;color:#405c70;font-size:28px}
.physics-directory .physics-chapters{display:block;position:static;border:0;padding:16px;border-radius:0}
.physics-directory .physics-chapters button{width:100%;margin:4px 0;font-size:18px;min-height:54px}
.physics-directory button:focus-visible{outline:3px solid #258fbe;outline-offset:2px}
.science-home .physics-active .model-grid{grid-template-columns:repeat(4,minmax(0,1fr))}
/* 使用完整卡片宽度按原图比例呈现，取消此前四周内缩导致的小图。 */
.physics-catalog-active .card-visual{height:auto;aspect-ratio:16/10}
.physics-active .thumbnail-diagram{inset:0;background-size:contain;transform:none}
.physics-catalog-active .model-card:hover .thumbnail-diagram{transform:none}
.physics-active .thumbnail-diagram::after{display:none}
.physics-catalog-active .visual-top{display:none}
@media(max-width:1000px){.science-home .physics-active .model-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:580px){.science-home .physics-active .model-grid{grid-template-columns:1fr}.physics-catalog-bar{align-items:flex-start;flex-direction:column;gap:12px}.physics-directory-button{font-size:17px}}
/* 首页科学轮播：固定同一观察区，切换时不推动下方模型目录。 */
.home-scene[hidden],.showcase-navigation[hidden],.showcase-progress[hidden]{display:none}
.home-scene{min-width:0}
.showcase-svg{display:block;width:100%;height:230px;margin:6px 0;overflow:visible}
.showcase-controls{display:flex;align-items:center;gap:12px;min-height:44px;font-size:17px;color:#d3e8ee}
.showcase-controls label,.showcase-controls>span{white-space:nowrap}
.showcase-controls input{width:0;min-width:65px;flex:1;height:44px;accent-color:#85ebdd}
.showcase-controls output{color:#ffcf85;font-variant-numeric:tabular-nums}
.home-showcase .optics-note{min-height:44px;margin-top:8px}
.showcase-navigation{display:flex;justify-content:space-between;gap:12px;align-items:center;border-top:1px solid #6a9cad44;padding-top:10px;margin-top:10px}
.showcase-picker{display:flex;align-items:center;gap:10px;flex:1;min-width:0;font-size:15px;color:#b8d8e1}
.showcase-picker select{min-width:0;max-width:190px;flex:1;min-height:44px;padding:0 26px 0 10px;border:1px solid #5e889d;border-radius:7px;color:#dff9f1;background:#17394c;font-size:16px}
.showcase-picker select:focus-visible{outline:3px solid #258fbe;outline-offset:3px}
.home-showcase #show-salt-ions text{font-size:16px}
@media(max-width:580px){.showcase-picker>span{display:none}.home-showcase .showcase-navigation{flex-wrap:nowrap;gap:6px}.home-showcase .showcase-navigation button{padding:0 8px}.showcase-picker select{font-size:16px;padding-left:6px}.showcase-picker{flex:1}}
.showcase-tabs{display:flex;gap:5px;flex:1}
.home-showcase .showcase-tabs button{flex:1;padding:0 8px;min-height:44px;border:1px solid transparent;background:transparent;color:#b8d8e1;font-size:15px}
.home-showcase .showcase-tabs button[aria-pressed=true]{color:#9bf0df;background:#72dec51a;border-color:#6abdab88}

.showcase-progress{height:2px;background:#a0d7df22;margin:10px 0 0;overflow:hidden}
.showcase-progress span{display:block;height:100%;background:#8ae8d7;width:0}
.showcase-announcement{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
@media(min-width:1101px) and (max-height:850px){.home-showcase .showcase-svg,.home-showcase #optics-scene{height:220px;margin:0}.showcase-navigation{padding-top:8px;margin-top:8px}}
@media(max-width:1100px){.showcase-svg{height:auto}.showcase-controls{gap:8px;font-size:16px}.showcase-controls input{order:3;flex-basis:100%;width:100%}.showcase-controls{flex-wrap:wrap}}
@media(max-width:760px){.home-showcase .optics-heading{min-height:58px}.showcase-controls input{order:0;flex-basis:auto;width:0}.home-showcase .optics-note{min-height:58px}.showcase-svg{height:auto;min-height:170px}}
@media(max-width:580px){.home-showcase .optics-heading{min-height:66px}.home-showcase .optics-heading h2{font-size:21px;line-height:1.45}.home-showcase .optics-heading>div{min-width:0}.showcase-controls{display:grid;grid-template-columns:1fr auto;gap:4px 10px;min-height:76px;font-size:16px}.showcase-controls input{grid-column:1/-1;grid-row:2;width:100%}.home-showcase .optics-controls{min-height:76px}.home-showcase .optics-note{min-height:64px;font-size:13px}.showcase-navigation{gap:8px;flex-wrap:wrap}.showcase-tabs{flex-basis:100%}.home-showcase .showcase-tabs button{font-size:16px}.showcase-svg text{font-size:25px}}
@media(max-width:580px){.home-showcase .showcase-controls,.home-showcase .optics-controls{min-height:98px}}

/* 初中物理仅三册教材，按钮直接可见，沿用全宽四列模型区。 */
.junior-physics-books .physics-book-tabs{grid-template-columns:repeat(var(--junior-book-columns,3),minmax(0,1fr))}
.junior-physics-books .physics-book-tabs button{display:flex;align-items:center;justify-content:center;gap:12px;font-size:18px;min-height:52px}
.junior-physics-books .physics-book-tabs button[hidden]{display:none}
.junior-physics-books .physics-book-tabs b{font-size:14px;font-weight:500;background:#e8efed;border-radius:5px;padding:2px 8px}
@media(max-width:580px){.junior-physics-books .physics-book-tabs{grid-template-columns:1fr}.junior-physics-books .physics-book-tabs button{justify-content:space-between;padding:10px 16px}}
