/* 环节四：路线平板（.view-g4）和记录平板（.view-g4n）共用 */
.topbar { position: absolute; left: 24px; right: 24px; top: 18px; display: flex; gap: 14px; align-items: center; z-index: 40; pointer-events: none; }
.topbar > * { pointer-events: auto; }
.topbar .grow { flex: 1; }
.play-btn.ready { animation: hint-pulse 1.2s ease-in-out infinite; }

/* ---------- 路线平板 ---------- */
.view-g4 .p1 { left: 24px; top: 92px; width: 270px; height: 132px; display: flex; align-items: center; justify-content: space-around; z-index: 30; }
.view-g4 .p2 { left: 24px; top: 248px; width: 270px; height: 120px; display: grid; place-items: center; z-index: 30; }
.view-g4 .tray { left: 24px; top: 392px; width: 270px; height: 384px; display: grid; place-items: center; z-index: 30; }
.view-g4 .tray .packs { display: grid; grid-template-columns: repeat(2, 118px); gap: 12px; }
.view-g4 .submit-btn { position: absolute; left: 104px; top: 794px; z-index: 30; }
.view-g4 .hud.panel { right: 24px; top: 92px; width: 250px; height: 92px; justify-content: center; z-index: 30; }
.view-g4 .hud .cells .cell { width: 24px; height: 52px; }
.hud .over-cells { position: absolute; left: 50%; top: 100%; margin-top: 8px; transform: translateX(-50%); }
.view-g4 .badge-tray { left: 1060px; top: 794px; width: 516px; height: 88px; display: flex; align-items: center; justify-content: center; gap: 14px; z-index: 30; }
.nbadge { width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center; font-size: 32px; font-weight: 900; color: #fff; cursor: grab; border: 4px solid #fff;
  background: radial-gradient(circle at 35% 30%, #5b9df5, #1f6fe0); box-shadow: 0 5px 12px rgba(20, 60, 140, .35); }
.nbadge.used { opacity: .25; cursor: default; }
.nbadge.on-map { position: absolute; z-index: 25; width: 50px; height: 50px; font-size: 28px; cursor: pointer; animation: cell-pop .35s cubic-bezier(.3, 1.6, .5, 1); }
.view-g4 .result { left: 330px; top: 794px; width: 700px; height: 88px; display: flex; align-items: center; gap: 16px; padding: 0 20px; z-index: 30; opacity: 0; transition: opacity .3s; }
.view-g4 .result.show { opacity: 1; }
.result .reached { flex: 1; display: flex; gap: 6px; align-items: center; overflow: hidden; }
.result .reached img { width: 84px; height: 72px; object-fit: contain; }
.result .count { width: 70px; height: 70px; border-radius: 50%; background: var(--green); color: #fff; display: grid; place-items: center; font-size: 42px; }
.result .warn-ico { width: 46px; height: 46px; border-radius: 50%; background: var(--red); color: #fff; display: grid; place-items: center; font-size: 30px; font-weight: 900; }
.result .none { font-size: 34px; font-weight: 900; color: #9ab; }

.node-mark { position: absolute; width: 46px; height: 46px; margin: -23px 0 0 -23px; z-index: 22; pointer-events: none; transition: transform .2s; }
.node-mark .mk { width: 100%; height: 100%; filter: drop-shadow(0 3px 4px rgba(0, 0, 0, .3)); }
.node-mark.hot { transform: scale(1.5); }
.node-mark.no { animation: shake .4s ease 2; }
.node-mark.reached::after { content: ""; position: absolute; inset: -10px; border-radius: 50%; border: 5px solid #ffd23f; box-shadow: 0 0 14px #ffd23f; }
.charge-tag { position: absolute; transform: translateX(-50%); z-index: 24; display: flex; align-items: center; gap: 6px; padding: 5px 10px; border-radius: 14px; border: 3px solid var(--green); background: #fff; cursor: pointer; box-shadow: 0 4px 10px rgba(20, 90, 60, .3); animation: cell-pop .35s cubic-bezier(.3, 1.6, .5, 1); }
.charge-tag .cells { gap: 3px; }
.charge-tag .cell { width: 13px; height: 30px; border-width: 2px; border-radius: 4px; }
.charge-tag .cell .bolt { width: 8px; height: 11px; }
.charge-tag b { font-size: 24px; color: var(--green-deep); }

/* ---------- 记录平板 ---------- */
.view-g4n .stage { background: var(--sky) url(../assets/img/bg-cz.jpg) center / cover no-repeat; }
.tablepanel { left: 24px; right: 24px; top: 92px; height: 440px; padding: 16px; z-index: 30; }
#table { display: grid; grid-template-columns: 76px repeat(6, 1fr); grid-template-rows: 56px 228px 118px; gap: 8px; height: 100%; }
#table .th { display: grid; place-items: center; font-size: 34px; font-weight: 900; color: #fff; background: #1f6fe0; border-radius: 14px; }
#table .th.corner { background: none; }
#table .rh { display: grid; place-items: center; color: var(--ink-soft); }
#table .rh svg { width: 44px; height: 44px; }
#table .td { border-radius: 16px; border: 3px dashed #9fcfda; background: rgba(255, 255, 255, .8); cursor: pointer; display: grid; place-items: center; padding: 6px; transition: transform .15s, background .15s; }
#table .td.hot { transform: scale(1.05); background: #d9f7e4; border-color: var(--green); }
#table .td.filled { border-style: solid; background: #fff; }
#table .td.place img { width: 100%; height: 170px; object-fit: contain; }
#table .td.place span { font-size: 20px; font-weight: 900; }
#table .td.chg { grid-auto-flow: column; gap: 8px; }
#table .td.chg .cell { width: 18px; height: 52px; border-width: 2px; }
#table .td.chg b { font-size: 34px; color: var(--green-deep); }
.view-g4n .spots { left: 24px; top: 556px; width: 1010px; height: 320px; display: flex; align-items: center; justify-content: center; gap: 10px; z-index: 30; }
.spot-card { width: 158px; height: 220px; border-radius: 20px; background: #fff; border: 3px solid #cfe7ec; display: grid; justify-items: center; align-content: center; gap: 6px; cursor: grab; box-shadow: 0 5px 12px rgba(20, 70, 90, .15); }
.spot-card img { width: 140px; height: 150px; object-fit: contain; }
.spot-card b { font-size: 20px; }
.view-g4n .tray { left: 1054px; top: 556px; width: 522px; height: 196px; display: grid; place-items: center; z-index: 30; }
.view-g4n .tray .packs { display: flex; gap: 8px; }
.view-g4n .ecard { width: 92px; height: 120px; gap: 3px; padding: 8px 4px 26px; }
.view-g4n .ecard .cell { width: 12px; }
.view-g4n .submit-btn { position: absolute; left: 1260px; top: 776px; z-index: 30; }

/* 完成卡：到了哪些景点 */
.finish-spots { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.finish-spots img { width: 120px; height: 100px; object-fit: contain; }
.finish-count { width: 90px; height: 90px; border-radius: 50%; background: var(--green); color: #fff; display: grid; place-items: center; font-size: 54px; }

/* 进入页（组号） */
.entry-group .tablets { display: flex; align-items: center; justify-content: center; gap: 24px; font-size: 60px; color: var(--ink-soft); }
.tab-ico { width: 220px; height: 300px; border-radius: 30px; border: 8px solid #c9dde2; background: #f6fdff; display: grid; place-items: center; color: #9bb8bf; }
.tab-ico svg { width: 120px; height: 120px; }
.tab-ico.on { border-color: var(--green); color: var(--green); background: #effcf3; box-shadow: 0 10px 24px rgba(47, 179, 111, .3); }
