/* 天河物理考研官网 · 公共样式（深色版）：近黑底 + 冷白文字 + 极少量冰蓝 / 香槟金点缀。 */
@font-face { font-family: "TH Serif"; src: url("../fonts/th-serif.woff") format("woff"); font-weight: 900; font-display: swap; }

:root {
  --bg: #030409;
  --bg2: #07080f;
  --navy: #0c0f1f;
  --indigo: #262b6b;
  --blue: #6f7cff;
  --sky: #aab6ff;
  --violet: #9a86ff;
  --gold: #d8c39a;
  --text: #ecedf5;
  --mute: #8d92ab;
  --dim: #5a5f78;
  --line: rgba(255, 255, 255, .07);
  --line2: rgba(255, 255, 255, .14);
  --panel: rgba(255, 255, 255, .025);
  --pill: #f3f3f6;
  --ok: #6fe3b0;
  --bad: #ff8597;
  --serif: "TH Serif", "Noto Serif SC", "Source Han Serif SC", "Songti SC", "STSong", "SimSun", serif;
  --sans: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", sans-serif;
  --latin: "Space Grotesk", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --mono: "JetBrains Mono", "Cascadia Mono", Consolas, monospace;
  --ease: cubic-bezier(.22, .8, .2, 1);
  --ease2: cubic-bezier(.7, 0, .2, 1);
  --nav-h: 72px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scrollbar-color: #2a2d48 #030409; }
html, body { overflow-x: clip; }
body { margin: 0; background: var(--bg); color: var(--text); font: 15px/1.7 var(--sans); -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
img, video { display: block; max-width: 100%; }
::selection { background: var(--blue); color: #fff; }
input, select, textarea { font: inherit; color: inherit; }
::-webkit-scrollbar { width: 9px; height: 9px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: #23263d; border-radius: 9px; border: 2px solid var(--bg); }
.panel, .list, .side { scrollbar-color: rgba(170, 180, 255, .2) transparent; }

/* 背景层：物理模型画布 + 暗角 + 颗粒 */
#bgfx { position: fixed; inset: 0; z-index: 0; width: 100%; height: 100%; pointer-events: none; opacity: 0; transition: opacity 1.6s var(--ease); }
html.ready #bgfx { opacity: 1; }
html.ready.bg-blank #bgfx { opacity: 0; transition-duration: 1s; }   /* data-bg="blank"：整片背景淡出，没有星星、星云和光粒 */
.vignette { position: fixed; inset: 0; z-index: 1; pointer-events: none; background: radial-gradient(120% 90% at 50% 40%, transparent 40%, rgba(0, 0, 0, .75)), linear-gradient(180deg, rgba(3, 4, 9, .4), transparent 20%, transparent 80%, rgba(3, 4, 9, .6)); }
.grain { position: fixed; inset: -50%; z-index: 90; pointer-events: none; opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1.2s steps(6) infinite; }
@keyframes grain { 0% { transform: translate(0, 0) } 20% { transform: translate(-3%, 2%) } 40% { transform: translate(2%, -3%) } 60% { transform: translate(-2%, -1%) } 80% { transform: translate(3%, 3%) } 100% { transform: translate(0, 0) } }
main, .flowpage { position: relative; z-index: 2; }

/* ---------- 加载图案 ---------- */
#loader { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; background: var(--bg); transition: opacity .9s var(--ease), visibility .9s; }
#loader.gone { opacity: 0; visibility: hidden; pointer-events: none; }
#loader .ld { display: flex; flex-direction: column; align-items: center; gap: 30px; transition: transform 1s var(--ease2), opacity .8s; }
#loader.gone .ld { transform: scale(.7); opacity: 0; }
.atom { position: relative; width: 150px; height: 150px; }
.atom i { position: absolute; inset: 0; border-radius: 50%; border: 1px solid rgba(200, 210, 255, .35); }
.atom i:nth-child(1) { transform: rotate(0deg) scaleY(.36); }
.atom i:nth-child(2) { transform: rotate(60deg) scaleY(.36); }
.atom i:nth-child(3) { transform: rotate(120deg) scaleY(.36); }
.atom i::after { content: ""; position: absolute; width: 7px; height: 7px; margin: -3.5px; border-radius: 50%; background: #fff; box-shadow: 0 0 12px #c9d2ff, 0 0 24px #7d8cff; offset-path: ellipse(50% 50% at 50% 50%); animation: orbit 1.8s linear infinite; }
.atom i:nth-child(2)::after { animation-duration: 2.3s; animation-delay: -.6s; }
.atom i:nth-child(3)::after { animation-duration: 2.9s; animation-delay: -1.3s; }
@keyframes orbit { to { offset-distance: 100%; } }
.atom b { position: absolute; left: 50%; top: 50%; width: 12px; height: 12px; margin: -6px; border-radius: 50%; background: radial-gradient(#fff, #c8b88f 60%, transparent 70%); box-shadow: 0 0 30px 6px rgba(216, 195, 154, .5); animation: beat 1.8s ease-in-out infinite; }
@keyframes beat { 50% { transform: scale(1.35); } }
/* 加载页 LOGO：天河头像放在原子中心（电子绕着头像转），下面是「TianHe Physics 天河物理考研」字标，一道光扫过 */
.ld-logo { position: relative; width: 190px; height: 190px; display: grid; place-items: center; }
.ld-logo .atom { position: absolute; inset: 0; width: auto; height: auto; }
.ld-logo .atom i { border-color: rgba(200, 210, 255, .3); }
.ld-av { position: relative; z-index: 1; width: 92px; height: 92px; border-radius: 50%; padding: 3px; background: conic-gradient(from 0deg, #f3d98f, #9fe9ff, #c3a6ff, #f3d98f); box-shadow: 0 0 0 1px rgba(255, 255, 255, .15), 0 0 30px 4px rgba(216, 195, 154, .35), 0 0 60px 10px rgba(120, 160, 255, .18); animation: ldring 6s linear infinite; }
.ld-av img { display: block; width: 100%; height: 100%; border-radius: 50%; object-fit: cover; background: #0b0c16; animation: ldring 6s linear infinite reverse; }
@keyframes ldring { to { transform: rotate(360deg); } }
.ld-word { position: relative; width: 250px; }
.ld-word img { display: block; width: 100%; filter: drop-shadow(0 0 12px rgba(200, 210, 255, .25)); }
.ld-word::after { content: ""; position: absolute; inset: 0; background: linear-gradient(105deg, transparent 40%, rgba(255, 230, 170, .95) 50%, transparent 60%) 0 0 / 300% 100% no-repeat; background-position: 100% 0; animation: ldsheen 2.2s ease-in-out infinite; -webkit-mask: url(../img/logo-word.png) center / 100% 100% no-repeat; mask: url(../img/logo-word.png) center / 100% 100% no-repeat; }
@keyframes ldsheen { 0% { background-position: 100% 0; } 60%, 100% { background-position: 0 0; } }
.ld-meta { display: flex; align-items: center; gap: 16px; font: 500 11px var(--mono); letter-spacing: .25em; color: var(--dim); }
.ld-bar { width: 140px; height: 1px; background: var(--line2); position: relative; overflow: hidden; }
.ld-bar i { position: absolute; inset: 0; background: linear-gradient(90deg, var(--sky), var(--gold)); transform-origin: left; transform: scaleX(0); transition: transform .4s var(--ease); }
/* 离场：当前内容先淡出 */
html.leaving main, html.leaving .flowpage, html.leaving .nav, html.leaving .dots, html.leaving #hint { opacity: 0; filter: blur(8px); transform: translateY(-14px); transition: opacity .55s var(--ease), filter .55s, transform .6s var(--ease); }
html.leaving #bgfx { opacity: 0; transition: opacity .7s; }

/* ---------- 导航 ---------- */
.nav { position: fixed; top: 0; left: 0; right: 0; z-index: 60; height: var(--nav-h); display: flex; align-items: center; gap: 28px; padding: 0 clamp(16px, 3vw, 44px);
  transition: background .5s var(--ease), border-color .5s, transform .9s var(--ease), opacity .9s; border-bottom: 1px solid transparent; transform: translateY(-100%); opacity: 0; }
html.ready .nav { transform: none; opacity: 1; }
.nav.solid { background: rgba(3, 4, 9, .72); backdrop-filter: blur(18px) saturate(1.2); -webkit-backdrop-filter: blur(18px) saturate(1.2); border-bottom-color: var(--line); }
.nav.hide { transform: translateY(-100%); }
.brand { display: flex; align-items: center; gap: 10px; flex: none; }
.brand .av { width: 64px; height: 64px; border-radius: 50%; box-shadow: 0 0 0 1px rgba(255, 255, 255, .2); }
.brand .word { height: 56px; width: auto; }
.nav ul { list-style: none; display: flex; gap: 2px; margin: 0 auto; padding: 0; }
.nav li a { position: relative; display: block; padding: 8px 16px; font-size: 14px; letter-spacing: .1em; color: rgba(236, 237, 245, .62); transition: color .3s; }
.nav li a::after { content: ""; position: absolute; left: 50%; bottom: 0; width: 4px; height: 4px; margin-left: -2px; border-radius: 50%; background: var(--gold); transform: scale(0); transition: transform .4s var(--ease); }
.nav li a:hover, .nav li a.on { color: #fff; }
.nav li a.on::after, .nav li a:hover::after { transform: scale(1); }
.nav .cta { flex: none; }
.nav .contact { flex: none; margin-right: -14px; }
.burger { display: none; width: 44px; height: 44px; margin-left: auto; position: relative; z-index: 70; }
.burger i { position: absolute; left: 12px; right: 12px; height: 1.5px; background: #fff; transition: transform .45s var(--ease), top .45s var(--ease), opacity .3s; }
.burger i:nth-child(1) { top: 16px } .burger i:nth-child(2) { top: 22px } .burger i:nth-child(3) { top: 28px }
body.menu-open .burger i:nth-child(1) { top: 22px; transform: rotate(45deg) }
body.menu-open .burger i:nth-child(2) { opacity: 0 }
body.menu-open .burger i:nth-child(3) { top: 22px; transform: rotate(-45deg) }
.menu { position: fixed; inset: 0; z-index: 65; background: rgba(3, 4, 9, .97); display: flex; flex-direction: column; justify-content: center; padding: 80px 28px 40px; clip-path: circle(0 at calc(100% - 38px) 36px); transition: clip-path .8s var(--ease2); }
body.menu-open .menu { clip-path: circle(150% at calc(100% - 38px) 36px); }
.menu a { display: flex; align-items: baseline; gap: 14px; padding: 13px 0; border-bottom: 1px solid var(--line); font: 900 28px/1.3 var(--serif); opacity: 0; transform: translateY(24px); transition: opacity .5s, transform .6s var(--ease); }
.menu a small { font: 500 11px var(--mono); color: var(--dim); letter-spacing: .2em; }
body.menu-open .menu a { opacity: 1; transform: none; }
body.menu-open .menu a:nth-child(2) { transition-delay: .05s } body.menu-open .menu a:nth-child(3) { transition-delay: .1s }
body.menu-open .menu a:nth-child(4) { transition-delay: .15s } body.menu-open .menu a:nth-child(5) { transition-delay: .2s } body.menu-open .menu a:nth-child(6) { transition-delay: .25s }
@media (max-width: 1080px) { .nav ul, .nav .cta { display: none; } .burger { display: block; } .nav .contact { margin-left: auto; margin-right: 0; } }
@media (max-width: 1280px) and (min-width: 1081px) { .nav li a { padding: 8px 10px; } .brand .word { height: 44px; } .brand .av { width: 50px; height: 50px; } }

/* ---------- 光标 ---------- */
.cursor { position: fixed; left: 0; top: 0; z-index: 110; pointer-events: none; width: 34px; height: 34px; margin: -17px 0 0 -17px; border: 1px solid rgba(255, 255, 255, .4); border-radius: 50%; transition: width .35s var(--ease), height .35s var(--ease), margin .35s var(--ease), background .35s, border-color .35s; mix-blend-mode: difference; }
.cursor.dot { width: 5px; height: 5px; margin: -2.5px 0 0 -2.5px; background: #fff; border: 0; transition: none; }
.cursor.big { width: 76px; height: 76px; margin: -38px 0 0 -38px; background: rgba(255, 255, 255, .92); border-color: transparent; }
.cursor .lbl { position: absolute; inset: 0; display: grid; place-items: center; font: 600 11px var(--mono); letter-spacing: .1em; color: #000; opacity: 0; transition: opacity .2s; }
.cursor.big .lbl { opacity: 1; }
@media (hover: none), (max-width: 900px) { .cursor { display: none; } }

/* ---------- 整屏翻页 ---------- */
html.deck, html.deck body { height: 100%; overflow: hidden; }
.deck { position: fixed; inset: 0; z-index: 2; }
.scene { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: center; visibility: hidden; overflow: hidden; }
.scene.active { visibility: visible; }
.scene > .in { position: relative; width: min(1320px, 100% - 2 * clamp(18px, 4.5vw, 64px)); margin: 0 auto; padding-top: var(--nav-h); transition: opacity .6s var(--ease), filter .6s, transform .8s var(--ease); }
.scene.leave > .in { opacity: 0; filter: blur(10px); transform: translateY(var(--leave-y, -40px)) scale(.985); }
.scene.leave.up > .in { --leave-y: 40px; }
html.flow .deck { position: relative; }
html.flow .scene { position: relative; min-height: 100vh; min-height: 100svh; visibility: visible; padding: 40px 0; }
/* 右侧页签栏：每一屏一个横条 + 名称，当前页高亮 */
.dots { position: fixed; right: clamp(12px, 1.6vw, 26px); top: 50%; z-index: 50; transform: translateY(-50%); display: flex; flex-direction: column; gap: 2px; padding: 10px 8px; border-radius: 16px; background: rgba(8, 9, 16, .5); border: 1px solid rgba(255, 255, 255, .08); backdrop-filter: blur(10px); opacity: 0; transition: opacity 1s .4s; }
html.ready .dots { opacity: 1; }
.dots button { position: relative; display: flex; align-items: center; justify-content: flex-end; gap: 10px; height: 30px; padding: 0 8px 0 12px; border-radius: 99px; font: 500 13px var(--sans); color: rgba(220, 224, 240, .55); letter-spacing: .12em; white-space: nowrap; transition: color .4s, background .4s; }
.dots button::after { content: ""; flex: none; width: 16px; height: 3px; border-radius: 3px; background: rgba(255, 255, 255, .3); transition: all .5s var(--ease); }
.dots button:hover { color: #fff; background: rgba(255, 255, 255, .06); }
.dots button.on { color: #fff; font-weight: 700; background: rgba(216, 195, 154, .14); }
.dots button.on::after { width: 30px; background: var(--gold); box-shadow: 0 0 10px rgba(216, 195, 154, .7); }
html.flow .dots { display: none; }
/* 滚轮提示：像米哈游一样提示用户滑动鼠标滚轮 */
#hint { position: fixed; left: 50%; bottom: 26px; z-index: 50; transform: translate(-50%, 12px); display: flex; flex-direction: column; align-items: center; gap: 10px; opacity: 0; pointer-events: none; transition: opacity .8s var(--ease), transform .8s var(--ease); }
#hint.show { opacity: 1; transform: translate(-50%, 0); }
#hint .mouse { width: 24px; height: 38px; border: 1.5px solid rgba(255, 255, 255, .7); border-radius: 13px; position: relative; }
#hint .mouse::after { content: ""; position: absolute; left: 50%; top: 7px; width: 3px; height: 7px; margin-left: -1.5px; border-radius: 3px; background: #fff; animation: wheel 1.8s var(--ease) infinite; }
@keyframes wheel { 0% { transform: translateY(0); opacity: 1; } 70% { transform: translateY(11px); opacity: 0; } 100% { opacity: 0; } }
#hint span { font: 500 11px var(--sans); letter-spacing: .3em; padding-left: .3em; color: rgba(255, 255, 255, .7); }
#hint .chev { width: 9px; height: 9px; border-right: 1.5px solid rgba(255, 255, 255, .5); border-bottom: 1.5px solid rgba(255, 255, 255, .5); transform: rotate(45deg); margin-top: -4px; animation: chev 1.8s ease-in-out infinite; }
@keyframes chev { 50% { transform: translateY(5px) rotate(45deg); opacity: .3; } }
html.touch #hint .mouse { display: none; }
/* 讲解模式（site.js 的 data-spot / data-say） */
.spot { position: relative; z-index: 20; transition: transform 1s var(--ease), opacity .6s, filter .6s !important; }
[data-fx].tdim.on, .tdim:not([data-fx]) { opacity: .1 !important; filter: blur(2.5px) !important; transition: opacity .7s, filter .7s, transform 1.2s var(--ease) !important; }
.tour-say { position: absolute; left: 50%; top: 70%; z-index: 25; width: min(980px, 88vw); transform: translate(-50%, 10px); text-align: center; font-size: clamp(18px, 1.5vw, 24px); line-height: 1.7; color: #eef2fb; text-shadow: 0 2px 12px #000, 0 0 2px #000; opacity: 0; pointer-events: none; transition: opacity .35s, transform .5s var(--ease); }
.tour-say.on { opacity: 1; transform: translate(-50%, 0); }
.tour-say b { color: #fff; font-weight: 900; } .tour-say em { font-style: normal; color: #9fe9ff; }
/* 控制条：重播本屏（左）+ 快进 ×3（右），整体在底部居中 */
#ctl { position: fixed; left: 50%; bottom: 106px; z-index: 55; display: flex; gap: 14px; transform: translateX(-50%); opacity: 0; pointer-events: none; transition: opacity .8s .4s; }
html.ready #ctl { opacity: 1; pointer-events: auto; }
html.ready #ctl.hide, html.leaving #ctl, body.menu-open #ctl { opacity: 0; pointer-events: none; transition-delay: 0s; }
#ctl button { display: flex; align-items: center; gap: 10px; height: 48px; padding: 0 24px 0 18px; border-radius: 99px; border: 1px solid rgba(216, 195, 154, .6); background: rgba(8, 9, 16, .8); backdrop-filter: blur(8px); color: #f1e4c6; box-shadow: 0 0 18px -6px rgba(216, 195, 154, .6); font: 500 15px var(--sans); letter-spacing: .08em; white-space: nowrap; transition: background .3s, border-color .3s, color .3s, box-shadow .3s; }
#ctl button:hover { background: rgba(216, 195, 154, .14); border-color: var(--gold); color: #fff; }
#ctl svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
#ctl .ff svg { fill: currentColor; stroke: none; width: 18px; }
#ctl .ff.on { background: linear-gradient(135deg, rgba(169, 228, 255, .28), rgba(120, 170, 255, .18)); border-color: #a9e4ff; color: #fff; box-shadow: 0 0 22px -4px rgba(169, 228, 255, .7); }
#ctl .rp.spin svg { animation: rpspin .7s var(--ease); }
@media (max-width: 760px) { #ctl { bottom: 18px; gap: 8px; } #ctl button { height: 40px; padding: 0 14px 0 12px; font-size: 13px; } }
@keyframes rpspin { from { transform: rotate(0); } to { transform: rotate(-360deg); } }

/* ---------- 动效库：每个元素写 data-fx（效果）和 data-t（第几毫秒出现） ---------- */
[data-fx] { transition: opacity 1s var(--ease), transform 1.2s var(--ease), filter 1.1s var(--ease), clip-path 1.2s var(--ease2), letter-spacing 1.6s var(--ease); transition-delay: 0s; }
[data-fx="fade"] { opacity: 0; }
[data-fx="rise"] { opacity: 0; transform: translateY(46px); }
[data-fx="drop"] { opacity: 0; transform: translateY(-40px); }
[data-fx="left"] { opacity: 0; transform: translateX(-70px); }
[data-fx="right"] { opacity: 0; transform: translateX(70px); }
[data-fx="blur"] { opacity: 0; filter: blur(22px); transform: scale(1.05); }
[data-fx="zoom"] { opacity: 0; filter: blur(12px); transform: scale(1.45); }
[data-fx="scale"] { opacity: 0; transform: scale(.78); }
[data-fx="flip"] { opacity: 0; transform: perspective(900px) rotateX(78deg); transform-origin: 50% 100%; }
[data-fx="swing"] { opacity: 0; transform: perspective(900px) rotateY(-60deg) translateX(-40px); transform-origin: 0 50%; }
[data-fx="space"] { opacity: 0; letter-spacing: .9em; filter: blur(6px); }
[data-fx="mask"] { clip-path: inset(-20% 100% -20% 0); }
/* 故障风出场：横向切片错位、红蓝分色、闪烁几下后稳定 */
[data-fx="glitch"] { opacity: 0; }
[data-fx="glitch"].on { animation: glitchIn .6s steps(1, end) both; }
@keyframes glitchIn {
  0% { opacity: 0; }
  6% { opacity: 1; clip-path: inset(12% 0 60% 0); transform: translate(-.09em, 0) skewX(-14deg); text-shadow: .07em 0 rgba(255, 60, 200, .85), -.07em 0 rgba(0, 235, 255, .85); }
  13% { clip-path: inset(58% 0 18% 0); transform: translate(.11em, 0); }
  20% { opacity: .15; clip-path: none; transform: none; }
  27% { opacity: 1; clip-path: inset(0 0 72% 0); transform: translate(.05em, -.02em); text-shadow: -.05em 0 rgba(255, 60, 200, .85), .05em 0 rgba(0, 235, 255, .85); }
  34% { clip-path: inset(38% 0 36% 0); transform: translate(-.13em, 0) skewX(9deg); }
  41% { clip-path: inset(76% 0 0 0); transform: translate(.05em, 0); }
  48% { clip-path: none; transform: translate(-.02em, 0); }
  56% { opacity: .45; }
  63% { opacity: 1; clip-path: inset(22% 0 48% 0); transform: translate(.06em, 0); text-shadow: .03em 0 rgba(255, 60, 200, .7), -.03em 0 rgba(0, 235, 255, .7); }
  72% { clip-path: none; transform: none; }
  84% { transform: translate(-.015em, 0); text-shadow: .015em 0 rgba(255, 60, 200, .5), -.015em 0 rgba(0, 235, 255, .5); }
  100% { opacity: 1; clip-path: none; transform: none; text-shadow: none; }
}
[data-fx="maskup"] { clip-path: inset(100% -5% -20% -5%); transform: translateY(30px); }
[data-fx="line"] { transform: scaleX(0); transform-origin: left; }
[data-fx="vline"] { transform: scaleY(0); transform-origin: top; }
[data-fx="count"], [data-fx="type"] { opacity: 0; }
[data-fx="chars"] .c, [data-fx="words"] .c { display: inline-block; opacity: 0; transform: translateY(.7em) rotate(6deg); filter: blur(4px); transition: opacity .7s var(--ease), transform 1s var(--ease), filter .8s; transition-delay: calc(var(--i) * var(--cs, 38ms)); }
[data-fx="scatter"] .c { display: inline-block; opacity: 0; transform: translate(var(--sx), var(--sy)) rotate(var(--sr)); filter: blur(6px); transition: opacity .9s var(--ease), transform 1.4s var(--ease), filter 1s; transition-delay: calc(var(--i) * 26ms); }
[data-fx="draw"] .dr { stroke-dasharray: var(--len, 600); stroke-dashoffset: var(--len, 600); transition: stroke-dashoffset 1.8s var(--ease); transition-delay: calc(var(--k, 0) * 140ms); }
[data-fx].on { opacity: 1; transform: none; filter: none; clip-path: inset(-20% -20% -20% -20%); letter-spacing: var(--ls, normal); }
[data-fx].on .c { opacity: 1; transform: none; filter: none; }
[data-fx="draw"].on .dr { stroke-dashoffset: 0; }
.scene:not(.active) [data-fx], .seq:not(.played) [data-fx] { transition-duration: 0s !important; transition-delay: 0s !important; }
@media (prefers-reduced-motion: reduce) { [data-fx] { transition: none !important; opacity: 1 !important; transform: none !important; filter: none !important; clip-path: none !important; } [data-fx] .c { opacity: 1 !important; transform: none !important; filter: none !important; } .grain { animation: none; } }

/* ---------- 排版 ---------- */
.wrap { width: min(1320px, 100% - 2 * clamp(18px, 4.5vw, 64px)); margin: 0 auto; }
.section { position: relative; padding: clamp(80px, 12vw, 160px) 0; }
.eyebrow { display: inline-flex; align-items: center; gap: 12px; font: 500 11.5px/1 var(--mono); letter-spacing: .32em; text-transform: uppercase; color: var(--gold); --ls: .32em; }
.eyebrow::before { content: ""; width: 26px; height: 1px; background: currentColor; opacity: .7; }
.display { font: 900 clamp(40px, 7vw, 108px)/1.08 var(--serif); letter-spacing: .01em; margin: 0; }
.h2 { font: 900 clamp(30px, 4.4vw, 62px)/1.18 var(--serif); margin: 18px 0 0; letter-spacing: .01em; }
.h3 { font: 900 clamp(22px, 2.2vw, 30px)/1.3 var(--serif); margin: 0; }
.lead { font-size: clamp(15px, 1.2vw, 17.5px); color: var(--mute); max-width: 620px; line-height: 1.95; }
.latin { font-family: var(--latin); } .mono { font-family: var(--mono); }
.grad { background: linear-gradient(100deg, #fff 0%, #cfd6ff 40%, var(--gold) 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }
.gold { color: var(--gold); }
.outline { color: transparent; -webkit-text-stroke: 1px rgba(255, 255, 255, .22); }
.demo-note { font: 12px/1.6 var(--sans); color: var(--dim); }
.demo-badge { display: inline-block; padding: 1px 9px; border: 1px dashed rgba(216, 195, 154, .5); color: var(--gold); border-radius: 99px; font: 500 11px/1.7 var(--sans); letter-spacing: .05em; }

/* ---------- 按钮 ---------- */
.btn { position: relative; display: inline-flex; align-items: center; gap: 10px; height: 52px; padding: 0 28px; border-radius: 99px; font: 600 14.5px/1 var(--sans); letter-spacing: .1em; overflow: hidden; isolation: isolate; background: var(--pill); color: #07080f; transition: transform .4s var(--ease), box-shadow .4s, color .4s; }
.btn::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(100deg, #d9c49b, #f4e6c6); transform: translateY(101%); transition: transform .5s var(--ease); }
.btn:hover::before { transform: none; }
.btn .arr { display: inline-block; transition: transform .4s var(--ease); }
.btn:hover .arr { transform: translateX(5px); }
.btn.ghost { background: rgba(255, 255, 255, .03); color: #fff; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .25); backdrop-filter: blur(6px); }
.btn.ghost::before { background: rgba(255, 255, 255, .1); }
.btn.sm { height: 40px; padding: 0 18px; font-size: 13px; }
.btn .play { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: #fff; color: #07080f; font-size: 9px; margin-left: -12px; }
.btn[disabled] { opacity: .45; pointer-events: none; }
.link-arrow { display: inline-flex; align-items: center; gap: 10px; font: 600 13.5px var(--sans); letter-spacing: .12em; color: #fff; }
.link-arrow i { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line2); display: grid; place-items: center; font-style: normal; transition: background .4s, transform .4s var(--ease), color .4s; }
.link-arrow:hover i { background: #fff; color: #07080f; transform: rotate(-45deg); }
.chip { display: inline-flex; align-items: center; height: 32px; padding: 0 14px; border-radius: 99px; border: 1px solid var(--line2); font-size: 13px; color: var(--mute); transition: all .3s; white-space: nowrap; }
.chip:hover { color: #fff; border-color: rgba(255, 255, 255, .45); }
.chip.on { background: var(--pill); color: #07080f; border-color: var(--pill); font-weight: 600; }
.pilltag { display: inline-flex; align-items: center; font: 900 14px/1 var(--serif); color: #07080f; background: var(--pill); padding: 7px 14px; border-radius: 99px; }

/* ---------- 卡片 / 面板 ---------- */
.panel { background: linear-gradient(160deg, rgba(255, 255, 255, .05), rgba(255, 255, 255, .012) 60%); border: 1px solid var(--line); border-radius: 22px; backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); }
.tilt { transform-style: preserve-3d; transition: transform .6s var(--ease); will-change: transform; }
.shine { position: absolute; inset: 0; border-radius: inherit; pointer-events: none; background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), rgba(255, 255, 255, .12), transparent 45%); opacity: 0; transition: opacity .4s; }
.tilt:hover .shine { opacity: 1; }

/* ---------- 流式页（刷题、院校）的页头与出场 ---------- */
.phead { position: relative; padding: calc(var(--nav-h) + clamp(50px, 8vw, 110px)) 0 clamp(40px, 6vw, 70px); overflow: hidden; }
.phead .idx { position: absolute; right: clamp(16px, 4vw, 48px); top: calc(var(--nav-h) + 20px); font: 700 clamp(90px, 18vw, 250px)/1 var(--latin); color: transparent; -webkit-text-stroke: 1px rgba(255, 255, 255, .06); pointer-events: none; user-select: none; }
.phead .crumb { font: 500 11.5px var(--mono); color: var(--dim); letter-spacing: .22em; margin-bottom: 24px; }
.phead .crumb a:hover { color: #fff; }
[data-reveal] { opacity: 0; transform: translateY(40px); transition: opacity 1s var(--ease), transform 1.2s var(--ease); transition-delay: var(--d, 0s); }
[data-reveal].in { opacity: 1; transform: none; }

/* ---------- 弹窗 / 提示 ---------- */
.modal { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 20px; background: rgba(2, 2, 6, .86); backdrop-filter: blur(14px); opacity: 0; pointer-events: none; transition: opacity .5s; }
.modal.open { opacity: 1; pointer-events: auto; }
.modal .box { position: relative; width: min(1100px, 100%); max-height: calc(100vh - 40px); overflow: auto; transform: translateY(30px) scale(.97); transition: transform .7s var(--ease); overscroll-behavior: contain; }
.modal.open .box { transform: none; }
.modal .x { position: absolute; top: 14px; right: 14px; z-index: 3; width: 44px; height: 44px; border-radius: 50%; background: rgba(255, 255, 255, .08); backdrop-filter: blur(6px); font-size: 18px; transition: background .3s, transform .4s var(--ease), color .3s; }
.modal .x:hover { background: #fff; color: #000; transform: rotate(90deg); }
.player { position: relative; border-radius: 18px; overflow: hidden; background: #000; aspect-ratio: 16/9; }
.player video { width: 100%; height: 100%; object-fit: cover; }
.player .cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 40px 24px 18px; background: linear-gradient(transparent, rgba(0, 0, 0, .75)); font: 900 20px var(--serif); pointer-events: none; }
.player .cap small { display: block; font: 12px var(--sans); color: var(--mute); margin-top: 4px; }
.toast { position: fixed; left: 50%; bottom: 32px; z-index: 210; transform: translate(-50%, 30px); opacity: 0; padding: 12px 22px; border-radius: 99px; background: var(--pill); color: #07080f; font-weight: 600; font-size: 14px; box-shadow: 0 20px 50px -10px rgba(0, 0, 0, .7); transition: all .5s var(--ease); pointer-events: none; }
.toast.on { opacity: 1; transform: translate(-50%, 0); }

/* ---------- 页脚 ---------- */
.foot { position: relative; z-index: 2; padding: 90px 0 36px; border-top: 1px solid var(--line); background: linear-gradient(180deg, transparent, rgba(30, 28, 70, .18)); }
.foot .big { font: 900 clamp(52px, 12vw, 190px)/.9 var(--serif); margin: 0 0 56px; background: linear-gradient(180deg, rgba(255, 255, 255, .9), rgba(255, 255, 255, .06)); -webkit-background-clip: text; background-clip: text; color: transparent; white-space: nowrap; }
.foot .cols { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 40px; }
.foot h4 { margin: 0 0 16px; font: 500 11.5px var(--mono); letter-spacing: .22em; color: var(--dim); }
.foot ul { padding: 0; margin: 0; } .foot li { list-style: none; margin: 8px 0; }
.foot li a { color: var(--mute); transition: color .3s; } .foot li a:hover { color: #fff; }
.foot .social { display: flex; gap: 8px; margin-top: 18px; flex-wrap: wrap; }
.foot .social span { height: 34px; padding: 0 14px; border-radius: 99px; border: 1px solid var(--line2); display: inline-flex; align-items: center; font-size: 12.5px; color: var(--mute); }
.foot .qr { width: 100px; height: 100px; border-radius: 12px; background: repeating-conic-gradient(#e8e8ee 0 25%, #b7b9c8 0 50%) 0 0/12px 12px; position: relative; }
.foot .qr::after { content: "二维码位"; position: absolute; inset: 28px; background: #fff; border-radius: 6px; display: grid; place-items: center; color: #07080f; font-size: 11px; font-weight: 700; }
.foot .legal { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-top: 56px; padding-top: 22px; border-top: 1px solid var(--line); font-size: 12px; color: var(--dim); }
@media (max-width: 820px) { .foot .cols { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
html.deck .scene > .in { padding-bottom: 76px; padding-right: clamp(0px, 3vw, 44px); }
.flowpage .panel, .flowpage ~ .tray { background: linear-gradient(160deg, rgba(18, 20, 34, .92), rgba(8, 9, 16, .94)); }

/* ---------- 已看过的一屏：不再叙事，整屏一起淡入 ---------- */
.snap, .snap *, .snap *::before, .snap *::after { transition: none !important; }
.scene.qfade > .in, .seq.qfade { animation: qfade .8s var(--ease) both; }
@keyframes qfade { from { opacity: 0; } }

/* ---------- 左侧返回按钮 ---------- */
/* 左侧返回按钮：横向的胶囊，离屏幕边缘远一点 */
.backbtn { position: fixed; left: clamp(18px, 2.4vw, 46px); top: 50%; z-index: 58; display: flex; align-items: center; gap: 12px; height: 56px; padding: 0 24px 0 9px; border-radius: 99px; background: linear-gradient(170deg, #f7fbff, #d6ebff 55%, #a9cdf2); color: #0b1626; box-shadow: 0 10px 30px -8px rgba(0, 0, 0, .7), 0 0 0 1px rgba(235, 247, 255, .6) inset, 0 0 24px rgba(169, 228, 255, .3); transform: translateY(-50%); transition: transform .4s var(--ease), box-shadow .3s, filter .3s; }
.backbtn i { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: #0b1626; color: #e3f2ff; font: 600 22px var(--latin); font-style: normal; transition: transform .4s var(--ease); }
.backbtn span { position: relative; font: 900 19px/1 var(--serif); letter-spacing: .2em; }
.backbtn span small { position: absolute; left: calc(100% + 26px); top: 50%; transform: translate(-6px, -50%); padding: 6px 12px; border-radius: 99px; background: rgba(10, 11, 18, .9); border: 1px solid var(--line2); color: #e9e2cf; font: 500 12.5px var(--sans); letter-spacing: .04em; white-space: nowrap; opacity: 0; pointer-events: none; transition: opacity .3s, transform .4s var(--ease); }
.backbtn:hover { filter: brightness(1.07); box-shadow: 0 14px 36px -8px rgba(0, 0, 0, .7), 0 0 0 1px rgba(235, 247, 255, .7) inset, 0 0 34px rgba(169, 228, 255, .5); }
.backbtn:hover i { transform: translateX(-3px); } .backbtn:hover span small { opacity: 1; transform: translate(0, -50%); }
html:not(.ready) .backbtn, html.leaving .backbtn, body.menu-open .backbtn { opacity: 0; pointer-events: none; }
@media (max-width: 760px) { .backbtn { left: 14px; top: auto; bottom: 18px; transform: none; height: 46px; padding: 0 16px 0 6px; gap: 8px; } .backbtn i { width: 34px; height: 34px; } .backbtn span { font-size: 15px; } }

/* ---------- 新手引导 ---------- */
.coach { position: fixed; inset: 0; z-index: 300; pointer-events: none; opacity: 0; transition: opacity .45s; }
.coach.on { opacity: 1; }
.coach > i { position: fixed; background: rgba(3, 4, 10, .86); pointer-events: auto; transition: all .5s var(--ease); }
.coach .hole { position: fixed; border-radius: 14px; box-shadow: 0 0 0 1.5px var(--gold), 0 0 30px 4px rgba(216, 195, 154, .35); transition: all .5s var(--ease); pointer-events: none; animation: cpulse 2s ease-in-out infinite; }
@keyframes cpulse { 50% { box-shadow: 0 0 0 1.5px var(--gold), 0 0 46px 10px rgba(216, 195, 154, .2); } }
.coach .ctip { position: fixed; pointer-events: auto; padding: 18px 20px; border-radius: 16px; background: linear-gradient(150deg, #151829, #0b0c16); border: 1px solid var(--line2); box-shadow: 0 30px 70px -20px #000; transition: left .5s var(--ease), top .5s var(--ease); }
.coach .ctip.in { animation: up .5s var(--ease); }
.coach .ctip small { font: 500 11px var(--mono); letter-spacing: .2em; color: var(--gold); }
.coach .ctip b { display: block; font: 900 19px/1.4 var(--serif); margin: 6px 0 6px; }
.coach .ctip p { margin: 0; color: #d4d7e6; font-size: 14.5px; line-height: 1.8; }
.coach .ctip em { display: block; margin-top: 10px; font-style: normal; font-size: 12px; color: var(--dim); }
@keyframes up { from { opacity: 0; transform: translateY(14px); } }

/* ---------- 护眼模式：整站叠一层暖色滤光（减少蓝光），降低亮度和对比度，去掉颗粒闪烁 ---------- */
.eyebtn { flex: none; display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px; border-radius: 99px; border: 1px solid var(--line2); color: var(--mute); font-size: 13px; transition: color .3s, border-color .3s, background .3s; }
.eyebtn svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.6; }
.eyebtn:hover { color: #fff; }
.eyebtn.on { color: #f3d9a4; border-color: rgba(243, 217, 164, .5); background: rgba(243, 190, 110, .1); }
.nav .eyebtn { margin-right: -14px; }
@media (max-width: 1280px) { .eyebtn span { display: none; } .eyebtn { padding: 0 9px; } }
html.eye { --text: #e2dccd; --mute: #9d968a; --pill: #efe6d2; }
html.eye::after { content: ""; position: fixed; inset: 0; z-index: 9999; pointer-events: none; background: rgba(255, 160, 60, .16); mix-blend-mode: multiply; }
html.eye::before { content: ""; position: fixed; inset: 0; z-index: 9998; pointer-events: none; background: rgba(20, 12, 4, .14); }
html.eye .grain { display: none; }
html.eye video, html.eye #bgfx { filter: brightness(.82) saturate(.8); }
@media (max-width: 1080px) { .nav .eyebtn { margin-left: auto; margin-right: 0; } .nav .contact { margin-left: 0; } }

/* 左下角（批改按钮上方）：重置使用记录 */
.resetbtn { position: fixed; left: 18px; bottom: 118px; z-index: 300; height: 34px; padding: 0 14px; border-radius: 99px; border: 1px solid rgba(255, 140, 140, .5); background: rgba(30, 12, 16, .85); backdrop-filter: blur(8px); color: #ffc9c9; font: 500 12.5px var(--sans); cursor: pointer; transition: background .3s; }
.resetbtn:hover { background: rgba(120, 30, 40, .85); }
html:not(.ready) .resetbtn, html.leaving .resetbtn { opacity: 0; pointer-events: none; }
@media (max-width: 760px) { .resetbtn { display: none; } }
