/* 地震沙盒 · 第三轮界面（在 game-2.css 之后加载）
 * 三款统一：左上目标卡（DSKit.goal，原右上遥测卡与能量条并入，遥测进「详情」）；底部从左到右
 * 本局档位 .ds-lv → 防护托盘 → 震中 / 震级 / 震源 → 操作组 [撤销][重新开始][暂停][倍速][跳过] → 触发地震。
 * 宽屏：左列（档位在上、托盘在下）+ 右侧操作条；801–1240：托盘单独一行，档位与操作条同一行；
 * 手机：档位 + 震中 / 震源、（防护）托盘、震级 + 触发、播放操作固定分行。
 * 参数与播放操作始终保留位置，动画开始、暂停和结束不会重新排布。 */

/* ---------- 顶栏：右侧只留挑战与「⋯」；左上的大标题让位给目标卡 ---------- */
.d2g-eq .live,.d2g-eq .scene-heading{display:none!important}
.d2g-eq .dsq-scene-btn small{display:none}

/* ---------- 目标卡（左上，顶栏下方） ---------- */
.d2g-eq .ds-hud{position:fixed;z-index:3;top:calc(74px + env(safe-area-inset-top));left:calc(28px + env(safe-area-inset-left));pointer-events:none}
.d2g-eq .ds-hud .dsk-goal{pointer-events:auto;max-height:calc(100dvh - 90px - var(--dock-height,120px) - 24px);overflow:auto;scrollbar-width:none}
.d2g-eq .ds-goal-weak{margin:6px 0 0;font-size:11.5px;line-height:1.5;color:var(--ds-dim)}
.d2g-eq .ds-goal-weak span{margin-left:7px;color:var(--d2-on-ink);font-weight:700;white-space:nowrap}
.d2g-eq .ds-goal-weak span.ok{color:var(--ds-dim2);text-decoration:line-through;font-weight:600}
/* 原遥测卡放进「详情」：去掉浮层外观，详情总是展开（外层的「详情」负责收起） */
.d2g-eq .dsk-goal .telemetry{position:static;display:block!important;width:auto;max-width:none;max-height:none;overflow:visible;margin:0;padding:2px 0 0;
  background:none;border:0;box-shadow:none;-webkit-backdrop-filter:none;backdrop-filter:none}
.d2g-eq .dsk-goal #dsq-data>summary,.d2g-eq .dsk-goal .dsq-key>div:first-child{display:none}
.d2g-eq .dsk-goal .dsq-key{margin-top:4px}
.d2g-eq .dsk-goal .dsq-key div::before{content:none}
.d2g-eq .dsk-goal .dsq-key span{display:block}
.d2g-eq .dsk-hud{display:none!important}

/* ---------- 底栏 ---------- */
.d2g-eq .dsq-dock{display:flex;align-items:flex-end;justify-content:space-between;gap:12px}
.d2g-eq .dsq-left{display:flex;flex-direction:column;align-items:flex-start;gap:8px;min-width:0}
.d2g-eq .ds-mode-destroy .dsq-traybox{display:none}
.d2g-eq .ds-act{gap:8px;max-width:100%;min-width:0}
.d2g-eq .ds-act-p{display:flex;align-items:center;gap:8px;min-width:0}
.d2g-eq #dsq-epi{display:flex}
.d2g-eq #ds-en-depth{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:1px;min-width:52px;min-height:52px;padding:4px 6px;
  border:0;border-radius:var(--d2-r-sm);background:var(--ds-chip);box-shadow:inset 0 0 0 1px var(--ds-chip-l);color:var(--d2-on-ink);cursor:pointer}
.d2g-eq #ds-en-depth:hover{background:var(--ds-chip-h)}
.d2g-eq #ds-en-depth b{font:800 16px/1 var(--d2-font-num)}
.d2g-eq #ds-en-depth span{font:600 10px/1.2 var(--d2-font);color:var(--ds-dim);white-space:nowrap}
.d2g-eq .ds-ops .ds-op{min-height:52px}
.d2g-eq #pause,.d2g-eq #ds-spd,.d2g-eq #ds-skip{display:inline-flex;font-size:var(--d2-fs-sm);padding:0 12px}
.d2g-eq #terrain-undo:disabled{opacity:.4}
/* 本局档位：与操作条等高 */
.d2g-eq .ds-lv button{min-height:44px;min-width:44px}
/* 恢复视角：右下，底栏上方 */
.d2g-eq .ds-home{right:calc(22px + env(safe-area-inset-right));bottom:calc(var(--dock-height,120px) + 30px + env(safe-area-inset-bottom))}
.d2g-eq .clean .ds-home,.d2g-eq .clean .ds-hud{display:none}

@media (max-width:1366px) and (min-width:801px){.d2g-eq #ds-mag{width:150px}}
/* 801–1240：托盘单独一行，档位与操作条同一行 */
@media (max-width:1240px) and (min-width:801px) and (min-height:501px){
  .d2g-eq .dsq-dock{flex-wrap:wrap;justify-content:space-between}
  .d2g-eq .dsq-left{display:contents}
  .d2g-eq .dsq-traybox{order:-1;flex:1 1 100%}
  .d2g-eq #ds-mag{width:120px}
  .d2g-eq .ds-act-mag{width:52px}
  .d2g-eq .ds-ops .ds-op{padding:0 10px}
  .d2g-eq .ds-act{display:grid;grid-template-columns:minmax(0,1fr) auto}
  .d2g-eq .ds-act-p{grid-column:1/-1}
  .d2g-eq .ds-ops{justify-self:end}
}
@media (max-width:1080px) and (min-width:801px) and (min-height:501px){
  .d2g-eq .dsq-dock{justify-content:space-between}
  .d2g-eq #ds-mag{width:96px}
  .d2g-eq .ds-lv-k small{display:none}
}

/* ---------- 手机与矮屏 ---------- */
@media (max-width:800px),(max-height:500px){
  .d2g-eq .ds-hud{top:calc(58px + env(safe-area-inset-top));left:calc(8px + env(safe-area-inset-left));right:calc(8px + env(safe-area-inset-right))}
  .d2g-eq .ds-hud .dsk-goal{width:100%;max-height:calc(100dvh - 70px - var(--dock-height,180px) - 20px)}
  .d2g-eq .dsq-dock{flex-direction:row;flex-wrap:wrap;align-items:center;gap:6px;padding:6px;border-radius:var(--d2-r-md);
    background:var(--ds-glass);border:1px solid var(--ds-gl);box-shadow:var(--ds-gsh);-webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px)}
  .d2g-eq .dsq-left,.d2g-eq .ds-act,.d2g-eq .ds-act-p{display:contents}
  .d2g-eq .dsq-dock .ds-lv{order:1;padding:0;background:none;box-shadow:none;-webkit-backdrop-filter:none;backdrop-filter:none}
  .d2g-eq .ds-lv-k small{display:none}
  .d2g-eq #dsq-epi{order:2;margin-left:auto}
  .d2g-eq #ds-en-depth{order:3;min-width:46px;min-height:46px}
  .d2g-eq .dsq-traybox{order:4;flex:1 1 100%;width:auto}
  .d2g-eq .dsq-dock::after{content:"";order:5;flex:1 1 100%;height:0}
  .d2g-eq .ds-act-mag{order:6;width:50px}
  .d2g-eq #ds-mag{order:7;flex:1 1 40px;min-width:40px;width:auto}
  .d2g-eq #terrain-undo{order:8}
  .d2g-eq #ds-restart{order:9}
  .d2g-eq #pause{order:10}
  .d2g-eq #ds-spd{order:11}
  .d2g-eq #ds-skip{order:12}
  .d2g-eq #ds-go{order:13;flex:none;margin-left:auto;padding:0 12px;min-width:0;min-height:48px;height:48px}
  .d2g-eq #ds-go .ds-go-cost,.d2g-eq #ds-go i{display:none}
  .d2g-eq .ds-ops{order:14;flex:1 1 100%;display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:5px;min-width:0}
  .d2g-eq .ds-ops .ds-op{min-height:48px;min-width:0;padding:0 4px;font-size:10.5px;flex-direction:column;gap:3px}
  .d2g-eq #pause,.d2g-eq #ds-spd,.d2g-eq #ds-skip{padding:0 4px;font-size:10.5px}
  .d2g-eq #dsq-tray .dsk-tray{background:none;border:0;box-shadow:none;padding:0}
  .d2g-eq .ds-pill{top:auto;bottom:calc(var(--dock-height,180px) + 22px + env(safe-area-inset-bottom))}
  .d2g-eq #toast{top:auto;bottom:calc(var(--dock-height,180px) + 22px + env(safe-area-inset-bottom))}
  .d2g-eq .ds-home{right:calc(12px + env(safe-area-inset-right));bottom:calc(var(--dock-height,180px) + 72px + env(safe-area-inset-bottom))}
}
@media (max-width:380px){
  .d2g-eq .dsq-dock .ds-lv button{min-width:36px;padding:0 6px}
  .d2g-eq .ds-lv-k{padding:0 4px;font-size:11px}
}
/* 挑战与灾害等级：震级、震中、深度由关卡定好，底栏只留读数（不放置灰按钮） */
.d2g-eq .dsq-ch #dsq-epi,.d2g-eq .dsq-ch #ds-en-depth,.d2g-eq .dsq-ch #ds-mag{display:none}
/* 提示条：放在底栏上方居中，不压左上目标卡 */
.d2g-eq #toast{top:auto;bottom:calc(var(--dock-height,120px) + 24px + env(safe-area-inset-bottom))}
/* 三星的第二个条件：小震命中薄弱点 ✓ / ✗ */
.d2g-eq .ds-goal-weak em{font-style:normal;font-weight:800}
.d2g-eq .ds-goal-weak em.ok{color:var(--d2-ok)}
.d2g-eq .ds-goal-weak em.no{color:var(--d2-star)}
