/* ===================================================================
   云翼航空 · 民航模拟  ——  UI 样式
   深色玻璃座舱风格：近黑蓝底 + 青色/琥珀色仪表色
   =================================================================== */

:root {
  --bg: #05080d;
  --panel: rgba(10, 18, 28, 0.88);
  --panel-solid: #0b131d;
  --line: rgba(120, 190, 230, 0.18);
  --line-strong: rgba(120, 200, 240, 0.42);
  --cyan: #47d7e8;
  --cyan-dim: #2b93a6;
  --amber: #ffb547;
  --green: #5fe08a;
  --red: #ff5d5d;
  --magenta: #e264d6;
  --text: #e7f0f7;
  --text-dim: #9db2c4;
  --text-faint: #64798c;
  --shadow: 0 18px 48px rgba(0, 0, 0, 0.62);
  --mono: "DIN Alternate", "Bahnschrift", "Consolas", "SF Mono", monospace;
  --sans: "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", "Segoe UI", system-ui, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html, body {
  width: 100%; height: 100%;
  overflow: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
  user-select: none;
}

#scene {
  position: fixed; inset: 0;
  width: 100%; height: 100%;
  display: block;
  background: #0a1420;
}

.hidden { display: none !important; }

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
  outline: none;
}

/* ============================ 按钮 ============================ */
.btn-primary {
  display: block;
  width: 100%;
  padding: 14px 20px;
  margin-top: 14px;
  border-radius: 3px;
  background: linear-gradient(180deg, #1fb3c8, #128094);
  color: #04141a;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 2px;
  box-shadow: 0 6px 20px rgba(31, 179, 200, 0.32), inset 0 1px 0 rgba(255, 255, 255, 0.28);
  transition: transform 0.13s ease, box-shadow 0.2s ease, filter 0.2s ease;
}
.btn-primary:hover { filter: brightness(1.12); box-shadow: 0 8px 26px rgba(31, 179, 200, 0.48), inset 0 1px 0 rgba(255, 255, 255, 0.35); }
.btn-primary:active { transform: translateY(1px); }

.btn-ghost {
  display: block;
  width: 100%;
  padding: 11px 18px;
  margin-top: 8px;
  border-radius: 3px;
  border: 1px solid var(--line-strong);
  color: var(--text-dim);
  font-size: 13px;
  letter-spacing: 1.4px;
  transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}
.btn-ghost:hover { background: rgba(71, 215, 232, 0.09); color: var(--text); border-color: var(--cyan); }

/* ============================ 主菜单 ============================ */
#menu {
  position: fixed; inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 40;
}

.menu-bg {
  position: absolute; inset: 0;
  background:
    radial-gradient(1200px 620px at 18% 8%, rgba(30, 110, 150, 0.32), transparent 62%),
    radial-gradient(900px 520px at 86% 92%, rgba(120, 60, 150, 0.20), transparent 60%),
    linear-gradient(160deg, #070d16 0%, #060a11 46%, #04070c 100%);
}
.menu-bg::after {
  content: "";
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(90, 160, 200, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(90, 160, 200, 0.055) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: radial-gradient(circle at 50% 40%, #000 20%, transparent 78%);
  -webkit-mask-image: radial-gradient(circle at 50% 40%, #000 20%, transparent 78%);
}

.menu-wrap {
  position: relative;
  width: min(1240px, 94vw);
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 26px 30px 20px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: linear-gradient(180deg, rgba(9, 16, 25, 0.92), rgba(6, 11, 18, 0.96));
  box-shadow: var(--shadow);
  backdrop-filter: blur(3px);
}
.menu-wrap::before {
  content: "";
  position: absolute; left: 0; right: 0; top: 0; height: 2px;
  background: linear-gradient(90deg, transparent, var(--cyan), transparent);
  opacity: 0.55;
}

.brand {
  display: flex;
  align-items: center;
  gap: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}
.brand-mark {
  width: 46px; height: 46px;
  display: grid; place-items: center;
  font-size: 22px;
  color: var(--cyan);
  border: 1px solid var(--line-strong);
  border-radius: 3px;
  background: rgba(71, 215, 232, 0.08);
  box-shadow: inset 0 0 18px rgba(71, 215, 232, 0.18);
}
.brand h1 {
  font-size: 25px;
  font-weight: 700;
  letter-spacing: 7px;
  color: #f2f8fc;
}
.brand p {
  margin-top: 3px;
  font-size: 10.5px;
  letter-spacing: 3.4px;
  color: var(--text-faint);
  text-transform: uppercase;
}

.profile {
  margin-left: auto;
  display: flex;
  gap: 26px;
}
.profile > div {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}
.pf-num {
  font-family: var(--mono);
  font-size: 21px;
  font-weight: 600;
  color: var(--cyan);
  line-height: 1;
}
.pf-lab {
  font-size: 10px;
  letter-spacing: 2px;
  color: var(--text-faint);
}

.menu-main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 22px;
  min-height: 0;
  flex: 1;
}

.section-title {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 12px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 3px;
  color: var(--text-dim);
}
.section-title b { font: inherit; color: inherit; }
.section-title span {
  font-size: 10.5px;
  font-weight: 400;
  letter-spacing: 1.6px;
  color: var(--text-faint);
}

.menu-tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}
.menu-tabs button {
  padding: 6px 10px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: rgba(10, 20, 30, 0.6);
  color: var(--text-dim);
  font-family: inherit;
  font-size: 10.5px;
  letter-spacing: 1px;
  cursor: pointer;
  transition: border-color .16s ease, color .16s ease, background .16s ease;
}
.menu-tabs button:hover { border-color: var(--cyan); color: var(--text); }
.menu-tabs button.active {
  border-color: var(--cyan);
  color: #eafaff;
  background: rgba(31, 179, 200, 0.16);
  box-shadow: inset 0 0 0 1px rgba(71, 215, 232, 0.18);
}
.menu-tabs button em {
  font-style: normal;
  margin-left: 5px;
  color: var(--text-faint);
  font-family: var(--mono);
}

.mission-list-wrap { min-height: 0; display: flex; flex-direction: column; }

.mission-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  overflow-y: auto;
  padding-right: 4px;
  align-content: start;
}
.mission-list::-webkit-scrollbar { width: 6px; }
.mission-list::-webkit-scrollbar-thumb { background: rgba(120, 190, 230, 0.25); border-radius: 3px; }

.mission-card {
  position: relative;
  padding: 13px 14px 12px;
  border: 1px solid var(--line);
  border-left: 2px solid rgba(120, 190, 230, 0.28);
  border-radius: 3px;
  background: linear-gradient(120deg, rgba(16, 28, 42, 0.75), rgba(9, 16, 25, 0.6));
  cursor: pointer;
  transition: border-color 0.16s ease, background 0.16s ease, transform 0.16s ease;
}
.mission-card:hover {
  border-color: var(--line-strong);
  border-left-color: var(--cyan);
  background: linear-gradient(120deg, rgba(22, 40, 58, 0.9), rgba(10, 18, 28, 0.8));
  transform: translateY(-1px);
}
.mission-card.selected {
  border-color: var(--cyan);
  border-left-color: var(--cyan);
  background: linear-gradient(120deg, rgba(26, 62, 78, 0.95), rgba(10, 22, 32, 0.85));
  box-shadow: 0 0 0 1px rgba(71, 215, 232, 0.25), 0 10px 26px rgba(0, 0, 0, 0.45);
}
.mission-card.selected::after {
  content: "";
  position: absolute; right: 10px; bottom: 10px;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 10px var(--cyan);
}
.mission-card.next { border-left-color: #8fe0ad; }
.mc-next {
  display: inline-block;
  margin-top: 7px;
  padding: 2px 7px;
  border: 1px solid rgba(111, 224, 176, 0.4);
  border-radius: 2px;
  font-size: 9.5px;
  letter-spacing: 1.2px;
  color: #8fe0ad;
  background: rgba(111, 224, 176, 0.08);
}

.mc-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 7px;
}
.mc-code {
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 2.2px;
  color: var(--cyan-dim);
}
.mc-diff {
  padding: 2px 7px;
  border-radius: 2px;
  font-size: 9.5px;
  letter-spacing: 1.4px;
  color: var(--text-dim);
  border: 1px solid var(--line);
}
.diff-入门 { color: #6fe0b0; border-color: rgba(111, 224, 176, 0.35); }
.diff-普通 { color: #7fc8ef; border-color: rgba(127, 200, 239, 0.35); }
.diff-困难 { color: var(--amber); border-color: rgba(255, 181, 71, 0.38); }
.diff-专家 { color: #ff8080; border-color: rgba(255, 128, 128, 0.4); }

.mc-name {
  font-size: 14.5px;
  font-weight: 600;
  color: #eef6fb;
  letter-spacing: 0.6px;
}
.mc-sub {
  margin-top: 4px;
  font-size: 11.5px;
  line-height: 1.5;
  color: var(--text-faint);
}
.mc-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  margin-top: 9px;
  padding-top: 8px;
  border-top: 1px dashed rgba(120, 190, 230, 0.14);
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--text-faint);
}

/* 简报侧栏 */
.brief {
  display: flex;
  flex-direction: column;
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: linear-gradient(180deg, rgba(14, 24, 36, 0.9), rgba(7, 12, 19, 0.92));
}
.brief-tag {
  align-self: flex-start;
  padding: 3px 9px;
  margin-bottom: 12px;
  font-size: 9.5px;
  letter-spacing: 2.6px;
  color: var(--cyan);
  border: 1px solid rgba(71, 215, 232, 0.4);
  border-radius: 2px;
}
.brief h2 {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0.8px;
  color: #f3f9fd;
  line-height: 1.35;
}
.brief-sub {
  margin-top: 6px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.8px;
  color: var(--cyan-dim);
}
.ac-select {
  margin-top: 12px;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: rgba(7, 14, 22, 0.5);
}
.ac-label {
  font-size: 9.5px;
  letter-spacing: 2px;
  color: var(--text-faint);
  margin-bottom: 7px;
}
.ac-choices { display: flex; gap: 5px; }
.ac-choices button {
  flex: 1;
  padding: 6px 4px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: rgba(14, 26, 38, 0.8);
  color: var(--text-dim);
  font-family: var(--mono);
  font-size: 10.5px;
  cursor: pointer;
  transition: all .16s ease;
}
.ac-choices button:hover { border-color: var(--cyan); color: var(--text); }
.ac-choices button.active {
  border-color: var(--cyan);
  color: #eafaff;
  background: rgba(31, 179, 200, 0.18);
  box-shadow: inset 0 0 0 1px rgba(71, 215, 232, 0.18);
}
.ac-speeds {
  margin-top: 7px;
  font-family: var(--mono);
  font-size: 10px;
  color: var(--text-faint);
  line-height: 1.5;
}
.ac-speeds b { color: var(--cyan-dim); font-weight: 400; }

.brief-list {
  flex: 1;
  list-style: none;
  margin: 16px 0 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow-y: auto;
}
.brief-list li {
  position: relative;
  padding-left: 18px;
  font-size: 12.5px;
  line-height: 1.62;
  color: #c3d4e2;
}
.brief-list li::before {
  content: "";
  position: absolute; left: 2px; top: 7px;
  width: 5px; height: 5px;
  border: 1px solid var(--cyan-dim);
  transform: rotate(45deg);
}
.brief-foot {
  margin-top: 12px;
  text-align: center;
  font-size: 10px;
  letter-spacing: 1.2px;
  color: rgba(100, 121, 140, 0.8);
}

.menu-foot {
  display: flex;
  justify-content: space-between;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1.6px;
  color: rgba(100, 121, 140, 0.85);
}

/* ============================ 飞行 HUD ============================ */
#hud {
  position: fixed; inset: 0;
  z-index: 20;
  pointer-events: none;
  font-family: var(--mono);
}
#hud button { pointer-events: auto; }
#hud .sp-cont, #hud .sp-cont input { pointer-events: auto; }

.hud-top {
  position: absolute;
  top: 0; left: 0; right: 0;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 12px 16px;
  background: linear-gradient(180deg, rgba(4, 8, 13, 0.82) 0%, rgba(4, 8, 13, 0.34) 68%, transparent 100%);
}

/* HUD 右上角快捷工具 */
.hud-tools {
  position: absolute;
  top: 96px; right: 16px;
  display: flex;
  gap: 6px;
}
.hud-tool {
  pointer-events: auto;
  padding: 6px 10px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.6px;
  color: #c6dfee;
  background: rgba(8, 16, 25, 0.74);
  border: 1px solid rgba(120, 190, 230, 0.24);
  border-radius: 3px;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s, background 0.15s;
}
.hud-tool:hover {
  color: #ffffff;
  border-color: var(--cyan);
  background: rgba(16, 34, 48, 0.88);
}
.hud-tool.off {
  color: #81909c;
  border-color: rgba(120, 190, 230, 0.12);
}

/* 任务徽章 */
.mission-badge {
  min-width: 178px;
  padding: 9px 13px;
  border-left: 2px solid var(--cyan);
  background: rgba(8, 16, 25, 0.72);
  border-radius: 2px;
}
.mb-name {
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.8px;
  color: #f0f7fc;
}
.mb-stage {
  margin-top: 4px;
  font-size: 10.5px;
  letter-spacing: 1.6px;
  color: var(--amber);
}
.mb-stage::before {
  content: "▸ ";
  color: var(--cyan);
}

/* FCU */
.fcu {
  display: flex;
  align-items: stretch;
  gap: 6px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: rgba(8, 15, 23, 0.82);
  box-shadow: inset 0 0 24px rgba(0, 0, 0, 0.5);
}
.fcu-group {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 3px;
  min-width: 58px;
  padding-right: 7px;
  border-right: 1px solid rgba(120, 190, 230, 0.12);
}
.fcu-group:last-of-type { border-right: none; padding-right: 0; }

.fcu-btn {
  padding: 2px 0;
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: 1.8px;
  color: rgba(157, 178, 196, 0.72);
  border: 1px solid rgba(120, 190, 230, 0.16);
  border-radius: 2px;
  transition: color 0.15s, border-color 0.15s, background 0.15s;
}
.fcu-btn:hover { color: var(--cyan); border-color: var(--cyan-dim); }

.fcu-val {
  text-align: center;
  font-size: 18px;
  font-weight: 600;
  letter-spacing: 0.5px;
  color: var(--cyan);
  text-shadow: 0 0 12px rgba(71, 215, 232, 0.45);
  line-height: 1.2;
}
.fcu-val.small { font-size: 14px; color: var(--amber); text-shadow: 0 0 10px rgba(255, 181, 71, 0.4); }

.fcu-nudge { display: flex; gap: 3px; }
.fcu-nudge button {
  flex: 1;
  padding: 1px 0;
  font-size: 11px;
  line-height: 1.1;
  color: var(--text-faint);
  border: 1px solid rgba(120, 190, 230, 0.12);
  border-radius: 2px;
  transition: color 0.12s, background 0.12s;
}
.fcu-nudge button:hover { color: #04141a; background: var(--cyan); border-color: var(--cyan); }

.fcu-modes {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding-left: 8px;
  border-left: 1px solid rgba(120, 190, 230, 0.12);
}
.mode {
  padding: 3px 9px;
  font-family: var(--mono);
  font-size: 9.5px;
  letter-spacing: 1.6px;
  text-align: left;
  color: rgba(140, 162, 180, 0.68);
  border: 1px solid rgba(120, 190, 230, 0.14);
  border-radius: 2px;
  transition: all 0.15s ease;
}
.mode:hover { color: var(--cyan); border-color: var(--cyan-dim); }
.mode.on {
  color: #04141a;
  background: var(--green);
  border-color: var(--green);
  box-shadow: 0 0 12px rgba(95, 224, 138, 0.45);
}

/* 顶部数据条 */
.data-strip {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 9px 14px;
  border: 1px solid var(--line);
  border-radius: 3px;
  background: rgba(8, 15, 23, 0.8);
}
.data-strip > div {
  display: flex;
  align-items: baseline;
  gap: 3px;
}
.data-strip span {
  font-size: 17px;
  font-weight: 600;
  color: #eaf4fa;
  letter-spacing: 0.4px;
}
.data-strip em {
  font-style: normal;
  font-size: 9.5px;
  letter-spacing: 1px;
  color: var(--text-faint);
}
.data-strip .clock span { color: var(--amber); }

/* 目标列表 */
.objectives {
  position: absolute;
  top: 92px; left: 16px;
  width: 244px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.obj {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 10px;
  font-size: 11.5px;
  color: #c9dae7;
  background: rgba(7, 14, 22, 0.66);
  border-left: 2px solid rgba(120, 190, 230, 0.3);
  border-radius: 2px;
}
.obj em {
  font-style: normal;
  font-size: 10px;
  color: var(--text-faint);
  white-space: nowrap;
}
.obj.next { border-left-color: var(--cyan); color: #ffffff; }
.obj.next::before { content: "▸"; color: var(--cyan); margin-right: 6px; }
.obj.ok { border-left-color: var(--green); color: #b6e9c8; }
.obj.run { border-left-color: var(--amber); color: #ffe0b0; }

.mission-card.school { border-left-color: var(--cyan); }
.mission-card.school .mc-code { color: var(--cyan); }

.mission-card.range { border-left-color: var(--amber); }
.mission-card.range .mc-code { color: var(--amber); }

/* 通用训练场面板 */
.range-panel {
  position: absolute;
  top: 92px; left: 16px;
  width: 268px;
  padding: 12px 14px 10px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 3px solid var(--amber);
  border-radius: 4px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
}
.rp-head {
  display: flex; justify-content: space-between; align-items: center;
  font-size: 10px; letter-spacing: .16em; color: var(--amber);
  padding-bottom: 7px; border-bottom: 1px solid var(--line);
}
.rp-head span:last-child { color: var(--text-faint); letter-spacing: .05em; }
.rp-tip { margin-top: 9px; font-size: 11.5px; line-height: 1.6; color: var(--text-dim); }
.rp-readouts { margin-top: 11px; display: flex; flex-direction: column; gap: 4px; }
.rp-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 5px 8px; border-radius: 3px;
  background: rgba(120, 190, 230, 0.06);
  border-left: 2px solid var(--line-strong);
  font-size: 12px;
}
.rp-k { color: var(--text-dim); }
.rp-v { font-family: var(--mono); font-size: 12.5px; font-weight: 700; }
.rp-row.ok   { border-left-color: var(--green); }
.rp-row.ok .rp-v   { color: var(--green); }
.rp-row.warn { border-left-color: var(--amber); background: rgba(224, 158, 48, 0.08); }
.rp-row.warn .rp-v { color: var(--amber); }
.rp-row.bad  { border-left-color: var(--red); background: rgba(255, 93, 93, 0.10); }
.rp-row.bad .rp-v  { color: var(--red); }
.rp-foot { margin-top: 10px; padding-top: 7px; border-top: 1px solid var(--line); font-size: 10px; color: var(--text-faint); }

/* 飞行学堂面板 */
.school-panel {
  position: absolute;
  top: 92px; left: 16px;
  width: 300px;
  padding: 12px 14px 10px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 3px solid var(--cyan);
  border-radius: 4px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
}
.sp-head {
  display: flex; align-items: center; gap: 8px;
  font-size: 10px; letter-spacing: .16em; color: var(--cyan);
  padding-bottom: 7px; border-bottom: 1px solid var(--line);
}
.sp-head > span:nth-child(2) { margin-left: auto; color: var(--text-faint); letter-spacing: .05em; }
.sp-cont {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 2px 5px;
  border: 1px solid var(--line);
  border-radius: 3px;
  color: var(--text-dim);
  font-size: 9.5px;
  letter-spacing: .05em;
  cursor: pointer;
  user-select: none;
}
.sp-cont input { width: 11px; height: 11px; margin: 0; accent-color: var(--cyan); cursor: pointer; }
.sp-cont:hover { border-color: var(--cyan); color: var(--text); }
.sp-title { margin-top: 9px; font-size: 15px; font-weight: 700; color: #fff; }
.sp-tip { margin-top: 4px; font-size: 11.5px; line-height: 1.55; color: var(--text-dim); }
.sp-hint {
  margin-top: 7px; padding: 6px 8px; border-radius: 4px;
  font-size: 11px; line-height: 1.5; color: #ffd9a0;
  background: rgba(224, 158, 48, 0.12); border-left: 2px solid var(--amber);
}
.sp-hint.hidden { display: none; }
.sp-readouts { margin-top: 8px; gap: 3px; }
.sp-readouts .rp-row { padding: 3px 7px; font-size: 11px; }
.sp-readouts .rp-v { font-size: 11.5px; }
.sp-readouts.hidden { display: none; }
.sp-segments { display: flex; gap: 3px; margin: 10px 0 0; }
.sp-seg { flex: 1; height: 3px; border-radius: 2px; background: rgba(120, 190, 230, 0.14); overflow: hidden; }
.sp-seg > span { display: block; height: 100%; width: 0; background: var(--cyan); transition: width .16s linear; }
.sp-progress {
  height: 4px; margin: 5px 0 8px; border-radius: 3px;
  background: rgba(120, 190, 230, 0.14); overflow: hidden;
}
.sp-progress span {
  display: block; height: 100%; width: 0;
  background: linear-gradient(90deg, var(--cyan-dim), var(--cyan));
  transition: width .18s linear;
}
.sp-steps { display: flex; flex-direction: column; gap: 3px; }
.sp-step {
  display: flex; align-items: center; gap: 7px;
  font-size: 10.5px; color: var(--text-faint);
}
.sp-step i {
  display: inline-block; width: 12px; height: 12px; flex: none;
  border: 1px solid var(--line-strong); border-radius: 50%;
  font-style: normal; font-size: 8px; line-height: 10px; text-align: center;
}
.sp-step.done { color: #b6e9c8; }
.sp-step.done i { color: #0b131d; background: var(--green); border-color: var(--green); }
.sp-step.now { color: #fff; }
.sp-step.now i { color: #0b131d; background: var(--cyan); border-color: var(--cyan); }
.sp-q { font-style: normal; font-size: 9px; padding: 0 4px; border-radius: 6px; margin-left: 2px; background: rgba(120,190,230,.16); color: var(--cyan); }
.sp-step.done .sp-q { background: rgba(74, 201, 132, .18); color: #8fe0ad; }
.atc-line.tutor { color: #b8e9f2; border-left-color: var(--cyan); }
.atc-line.tutor-ok { color: #b6e9c8; border-left-color: var(--green); }
.atc-line.tutor-hint { color: #ffd9a0; border-left-color: var(--amber); }
.q-tag { font-style: normal; font-size: 9px; padding: 1px 5px; border-radius: 7px; margin-left: 3px; vertical-align: 1px; }
.q-perfect { background: rgba(74, 201, 132, .18); color: #7fe0a4; }
.q-good { background: rgba(120, 190, 230, .18); color: #8fd8f2; }
.q-pass { background: rgba(224, 158, 48, .18); color: #ffd08a; }

/* 警告 */
.warnings {
  position: absolute;
  top: 96px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
}
.warn {
  padding: 6px 14px;
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  color: #1a0505;
  background: var(--red);
  border-radius: 2px;
  animation: warnBlink 0.9s steps(2, end) infinite;
  box-shadow: 0 0 22px rgba(255, 93, 93, 0.55);
}
@keyframes warnBlink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.42; }
}

/* 中央提示 */
.flash {
  position: absolute;
  top: 42%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.96);
  padding: 12px 26px;
  font-family: var(--sans);
  font-size: 16px;
  letter-spacing: 2px;
  color: #fff4e0;
  background: rgba(40, 20, 6, 0.86);
  border: 1px solid rgba(255, 181, 71, 0.6);
  border-radius: 3px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease, transform 0.22s ease;
  white-space: nowrap;
}
.flash.show { opacity: 1; transform: translate(-50%, -50%) scale(1); }

/* ATC 日志 */
.atc-log {
  position: absolute;
  left: 16px;
  bottom: 262px;
  width: 330px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.atc-line {
  padding: 5px 10px;
  font-family: var(--sans);
  font-size: 11.5px;
  line-height: 1.5;
  color: #bcd0de;
  background: rgba(6, 12, 19, 0.62);
  border-left: 2px solid rgba(71, 215, 232, 0.45);
  border-radius: 2px;
  animation: logIn 0.26s ease;
}
.atc-line.atc { border-left-color: var(--cyan); color: #dff3f8; }
.atc-line.info { border-left-color: rgba(157, 178, 196, 0.5); color: var(--text-dim); }
.atc-line.warn { border-left-color: var(--amber); color: #ffdda8; }
.atc-line.gpws { border-left-color: var(--red); color: #ffc9c9; font-weight: 600; }
@keyframes logIn {
  from { opacity: 0; transform: translateX(-8px); }
  to { opacity: 1; transform: none; }
}

/* ============================ 玻璃座舱 ============================ */
.glass {
  position: absolute;
  left: 50%;
  bottom: 34px;
  transform: translateX(-50%);
  display: flex;
  align-items: flex-end;
  gap: 8px;
  padding: 8px 10px 10px;
  border-radius: 4px;
  border: 1px solid rgba(120, 190, 230, 0.22);
  background: linear-gradient(180deg, rgba(6, 11, 18, 0.72), rgba(4, 8, 13, 0.88));
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55), inset 0 0 40px rgba(0, 0, 0, 0.5);
}
.glass-frame {
  position: relative;
  padding: 3px;
  border-radius: 3px;
  background: #02060a;
  border: 1px solid rgba(120, 190, 230, 0.18);
}
.glass-label {
  position: absolute;
  top: 5px; left: 8px;
  font-family: var(--mono);
  font-size: 8.5px;
  letter-spacing: 2px;
  color: rgba(120, 200, 240, 0.55);
  pointer-events: none;
}
#pfd, #nd { width: 236px; height: 236px; display: block; }
#eicas { width: 168px; height: 236px; display: block; }
.glass-frame.small { align-self: flex-end; }

/* 底部操作提示 */
.hint {
  position: absolute;
  left: 0; right: 0;
  bottom: 8px;
  text-align: center;
  font-family: var(--sans);
  font-size: 10px;
  letter-spacing: 1.1px;
  color: rgba(120, 145, 165, 0.55);
}

/* ============================ 遮罩面板 ============================ */
.overlay {
  position: fixed; inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  background: rgba(2, 5, 9, 0.72);
  backdrop-filter: blur(4px);
}
.panel {
  width: min(420px, 90vw);
  padding: 30px 32px 26px;
  border: 1px solid var(--line-strong);
  border-radius: 4px;
  background: linear-gradient(180deg, rgba(13, 22, 33, 0.98), rgba(7, 12, 19, 0.99));
  box-shadow: var(--shadow);
  text-align: center;
}
.panel h2 {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 5px;
  color: #f2f8fc;
  margin-bottom: 6px;
}
.panel h2.res-ok { color: var(--green); }
.panel h2.res-fail { color: var(--red); }
.res-sub {
  margin-top: 8px;
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 1.2px;
  color: var(--text-dim);
  line-height: 1.7;
}

/* 结算 */
.result-panel {
  width: min(560px, 92vw); text-align: left;
  max-height: 94vh; overflow-y: auto;
}
.result-panel::-webkit-scrollbar { width: 6px; }
.result-panel::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 3px; }
.result-panel h2 { text-align: center; }
.res-sub { text-align: center; }

.res-main {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 22px;
  margin: 22px 0 8px;
  align-items: center;
}
.res-grade-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.grade {
  width: 92px; height: 92px;
  display: grid; place-items: center;
  font-family: var(--mono);
  font-size: 46px;
  font-weight: 700;
  border-radius: 50%;
  border: 2px solid var(--line-strong);
  color: var(--cyan);
  box-shadow: inset 0 0 28px rgba(71, 215, 232, 0.16);
}
.grade-S { color: #ffe9a8; border-color: #ffd166; box-shadow: inset 0 0 28px rgba(255, 209, 102, 0.28), 0 0 26px rgba(255, 209, 102, 0.25); }
.grade-A { color: var(--green); border-color: rgba(95, 224, 138, 0.7); box-shadow: inset 0 0 28px rgba(95, 224, 138, 0.18); }
.grade-B { color: var(--cyan); border-color: rgba(71, 215, 232, 0.7); }
.grade-C { color: var(--amber); border-color: rgba(255, 181, 71, 0.62); }
.grade-D { color: #ff9a5a; border-color: rgba(255, 154, 90, 0.62); }
.grade-F { color: var(--red); border-color: rgba(255, 93, 93, 0.7); box-shadow: inset 0 0 28px rgba(255, 93, 93, 0.2); }
.mission-card .grade {
  width: 22px; height: 22px;
  font-size: 11px;
  border-width: 1px;
  box-shadow: none;
}
.mc-best {
  position: absolute;
  top: 10px; right: 34px;
}

.res-score {
  font-family: var(--mono);
  font-size: 15px;
  color: var(--text-dim);
}
.res-score span {
  font-size: 26px;
  font-weight: 700;
  color: #fff;
  margin-right: 3px;
}
.res-best {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 1.4px;
  color: var(--text-faint);
}

.res-bars {
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.bar-row {
  display: grid;
  grid-template-columns: 58px 1fr 42px;
  align-items: center;
  gap: 10px;
}
.bar-name {
  font-family: var(--sans);
  font-size: 11.5px;
  color: var(--text-dim);
  letter-spacing: 0.6px;
}
.bar-track {
  position: relative;
  height: 6px;
  border-radius: 3px;
  background: rgba(120, 190, 230, 0.12);
  overflow: hidden;
}
.bar-fill {
  display: block;
  height: 100%;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--cyan-dim), var(--cyan));
  box-shadow: 0 0 12px rgba(71, 215, 232, 0.5);
  transition: width 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.bar-val {
  font-family: var(--mono);
  font-size: 11px;
  text-align: right;
  color: #dce9f2;
}

.res-actions {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 22px;
}
.res-actions .btn-primary,
.res-actions .btn-ghost { margin-top: 0; }

/* 帮助 */
.help-panel {
  width: min(880px, 94vw);
  text-align: left;
}
.help-panel h2 { text-align: center; }
.help-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin: 22px 0 18px;
}
.help-grid h3 {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2.4px;
  color: var(--cyan);
  padding-bottom: 8px;
  margin-bottom: 10px;
  border-bottom: 1px solid var(--line);
}
.help-grid ul { list-style: none; display: flex; flex-direction: column; gap: 7px; }
.help-grid li {
  font-size: 11.5px;
  line-height: 1.55;
  color: #c0d2e0;
}
.help-grid b {
  display: inline-block;
  min-width: 62px;
  padding: 1px 6px;
  margin-right: 6px;
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 600;
  color: var(--cyan);
  background: rgba(71, 215, 232, 0.1);
  border: 1px solid rgba(71, 215, 232, 0.25);
  border-radius: 2px;
  text-align: center;
}
.help-tip {
  padding: 12px 16px;
  margin-bottom: 16px;
  font-size: 11.5px;
  line-height: 1.8;
  color: #d8c9a8;
  background: rgba(255, 181, 71, 0.07);
  border-left: 2px solid var(--amber);
  border-radius: 2px;
}

/* ============================ C 训练闭环 ============================ */
/* 技能档案入口按钮 */
.skills-btn {
  margin-left: 12px;
  align-self: center;
  padding: 7px 14px;
  font-family: var(--sans);
  font-size: 11px;
  letter-spacing: .12em;
  color: var(--cyan);
  background: rgba(71, 215, 232, .08);
  border: 1px solid var(--line-strong);
  border-radius: 3px;
  cursor: pointer;
  transition: background .2s, border-color .2s;
}
.skills-btn:hover { background: rgba(71, 215, 232, .18); border-color: var(--cyan); }

/* 交互检查单面板 */
.checklist-panel {
  position: absolute;
  right: 18px;
  top: 118px;
  width: 268px;
  max-height: calc(100vh - 210px);
  overflow-y: auto;
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 2px solid var(--cyan);
  border-radius: 4px;
  padding: 12px 13px 10px;
  font-size: 12px;
  box-shadow: var(--shadow);
  pointer-events: auto;
  z-index: 6;
}
.checklist-panel.hidden { display: none; }
.cl-head {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 11px; letter-spacing: .16em; color: var(--cyan);
  padding-bottom: 8px; border-bottom: 1px solid var(--line);
}
.cl-progress { font-family: var(--mono); color: var(--green); letter-spacing: .04em; }
.cl-head button {
  background: none; border: none; color: var(--text-faint);
  font-size: 18px; line-height: 1; cursor: pointer; padding: 0 2px;
}
.cl-head button:hover { color: var(--text); }
.cl-tabs { display: flex; gap: 6px; margin: 10px 0 6px; }
.cl-tabs button {
  flex: 1; padding: 5px 0; font-family: var(--sans); font-size: 11px;
  color: var(--text-dim); background: rgba(255,255,255,.03);
  border: 1px solid var(--line); border-radius: 3px; cursor: pointer;
}
.cl-tabs button.active { color: var(--bg); background: var(--cyan); border-color: var(--cyan); font-weight: 600; }
.cl-hint { font-size: 10.5px; color: var(--text-faint); margin: 4px 0 8px; line-height: 1.5; }
.cl-items { display: flex; flex-direction: column; gap: 4px; }
.cl-item {
  display: flex; align-items: flex-start; gap: 8px;
  padding: 6px 7px; border: 1px solid rgba(255,255,255,.05);
  border-radius: 3px; background: rgba(255,255,255,.02);
  cursor: pointer; transition: background .15s, border-color .15s;
}
.cl-item:hover { background: rgba(71,215,232,.07); border-color: var(--line); }
.cl-item.done { background: rgba(95,224,138,.07); border-color: rgba(95,224,138,.3); cursor: default; }
.cl-box {
  flex: 0 0 16px; height: 16px; margin-top: 1px;
  border: 1px solid var(--text-faint); border-radius: 3px;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; color: var(--bg);
}
.cl-item.done .cl-box { background: var(--green); border-color: var(--green); }
.cl-item.auto:not(.done) .cl-box { border-color: var(--amber); }
.cl-body { flex: 1; min-width: 0; }
.cl-label { font-size: 11.5px; color: var(--text); line-height: 1.35; }
.cl-item.done .cl-label { color: var(--green); }
.cl-tip { font-size: 10px; color: var(--text-faint); margin-top: 2px; line-height: 1.4; }
.cl-auto-tag { font-size: 9px; color: var(--amber); margin-left: 5px; }
.cl-foot { font-size: 9.5px; color: var(--text-faint); margin-top: 10px; line-height: 1.5; text-align: center; }

/* 结算：复盘曲线 */
.res-debrief {
  margin-top: 18px; padding: 12px 13px 10px;
  border: 1px solid var(--line); border-radius: 4px;
  background: rgba(6, 12, 20, .55);
}
.rd-head { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.rd-head > span { font-size: 11px; letter-spacing: .16em; color: var(--cyan); margin-right: auto; }
.rd-select, .rd-play, .rd-mini {
  font-family: var(--sans); font-size: 10.5px;
  background: rgba(71,215,232,.08); color: var(--cyan);
  border: 1px solid var(--line); border-radius: 3px;
  padding: 4px 8px; cursor: pointer;
}
.rd-select option { background: var(--panel-solid); color: var(--text); }
.rd-play:hover, .rd-mini:hover, .rd-select:hover { border-color: var(--cyan); }
.debrief-chart { width: 100%; height: 150px; display: block; border-radius: 3px; }
.rd-foot { display: flex; align-items: center; gap: 10px; margin-top: 8px; }
.rd-seek { flex: 1; accent-color: var(--cyan); }
.rd-foot span { font-family: var(--mono); font-size: 11px; color: var(--text-dim); min-width: 34px; text-align: right; }
.debrief-steps { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 10px; }
.debrief-steps button {
  font-family: var(--sans); font-size: 10px; padding: 3px 8px;
  color: var(--text-dim); background: rgba(255,255,255,.03);
  border: 1px solid var(--line); border-radius: 10px; cursor: pointer;
}
.debrief-steps button:hover { color: var(--cyan); border-color: var(--cyan); }

/* 结算：弱项诊断 */
.res-skills { margin-top: 14px; font-size: 11px; }
.res-sk-line {
  display: flex; align-items: center; gap: 8px; padding: 7px 9px;
  border: 1px solid var(--line); border-radius: 3px; margin-top: 6px;
  background: rgba(255,255,255,.02);
}
.res-sk-line .rsk-tag { color: var(--amber); font-size: 10px; letter-spacing: .1em; }
.res-sk-line .rsk-name { color: var(--text); font-weight: 600; }
.res-sk-line .rsk-val { font-family: var(--mono); color: var(--text-dim); margin-left: auto; }
.res-sk-line .rsk-rec { color: var(--green); font-size: 10.5px; }
.brief-lock { color: var(--amber) !important; font-size: 10.5px !important; line-height: 1.5; }

/* 技能档案面板 */
.skills-panel { width: min(720px, 94vw); text-align: left; }
.skills-panel h2 { text-align: center; }
.skills-bars { margin: 22px 0 16px; }
.skill-row {
  display: flex; align-items: center; gap: 9px;
  padding: 7px 4px; border-bottom: 1px solid rgba(255,255,255,.04);
}
.skill-ico { width: 20px; text-align: center; font-size: 14px; color: var(--cyan); }
.skill-name { width: 96px; font-size: 11.5px; color: var(--text); }
.skill-track { flex: 1; height: 7px; background: rgba(255,255,255,.06); border-radius: 4px; overflow: hidden; }
.skill-track > span { display: block; height: 100%; border-radius: 4px; background: var(--cyan); transition: width .4s; }
.skill-row.good .skill-track > span { background: var(--green); }
.skill-row.mid .skill-track > span { background: var(--cyan); }
.skill-row.low .skill-track > span { background: var(--amber); }
.skill-row.none .skill-track > span { background: var(--text-faint); }
.skill-val { width: 28px; font-family: var(--mono); font-size: 11px; color: var(--text-dim); text-align: right; }
.skill-lv { width: 38px; font-size: 10px; color: var(--text-faint); text-align: right; }
.skills-weak { font-size: 11px; color: var(--amber); line-height: 1.7; margin-bottom: 12px; }
.skills-recommend {
  font-size: 12px; color: var(--green); line-height: 1.7;
  padding: 10px 12px; border: 1px solid rgba(95,224,138,.3);
  border-radius: 3px; background: rgba(95,224,138,.06); margin-bottom: 16px;
}
.skills-panel .btn-primary { width: 100%; }

/* 帮助面板底部操作 */
.help-actions { display: flex; gap: 10px; }
.help-actions > button { flex: 1; width: auto; margin-top: 0; }

/* 键位设置面板 */
.keybind-panel {
  width: min(720px, 94vw);
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  text-align: left;
}
.keybind-panel h2 { text-align: center; }
.keybind-list {
  overflow-y: auto;
  padding-right: 6px;
  margin: 14px 0;
}
.kb-group {
  font-size: 10px;
  letter-spacing: 0.18em;
  color: var(--cyan);
  padding: 12px 4px 5px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 4px;
}
.kb-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 7px 10px;
  margin: 2px 0;
  font-family: var(--sans);
  font-size: 11.5px;
  color: var(--text);
  text-align: left;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid transparent;
  border-radius: 3px;
  cursor: pointer;
}
.kb-row:hover { background: rgba(71, 215, 232, 0.07); border-color: var(--line-strong); }
.kb-row.pending { border-color: var(--cyan); background: rgba(71, 215, 232, 0.12); }
.kb-key {
  font-family: var(--mono);
  font-size: 10.5px;
  color: var(--cyan);
  padding: 3px 9px;
  border: 1px solid var(--line-strong);
  border-radius: 3px;
  min-width: 64px;
  text-align: center;
}
.keybind-actions { display: flex; gap: 10px; }
.keybind-actions > button { flex: 1; width: auto; margin-top: 0; }

/* ============================ 自适应 ============================ */
@media (max-width: 1180px) {
  .menu-main { grid-template-columns: minmax(0, 1fr) 300px; }
  #pfd, #nd { width: 200px; height: 200px; }
  #eicas { width: 144px; height: 200px; }
}

@media (max-width: 980px) {
  .menu-main { grid-template-columns: 1fr; }
  .mission-list { grid-template-columns: 1fr; }
  .brief { max-height: 240px; }
  .glass { display: none; }
  .atc-log { bottom: 56px; }
  .fcu-modes { display: none; }
  .res-actions { grid-template-columns: 1fr 1fr; }
  .checklist-panel { right: 8px; top: auto; bottom: 70px; width: 232px; max-height: 46vh; }
  .help-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-height: 720px) {
  #pfd, #nd { width: 178px; height: 178px; }
  #eicas { width: 128px; height: 178px; }
  .atc-log { bottom: 208px; }
  .checklist-panel { top: 96px; max-height: calc(100vh - 150px); }
  .debrief-chart { height: 116px; }
}

/* ===================================================================
   操控方式选择（主菜单简报区）
   =================================================================== */
.ctrl-select { margin-top: 9px; }
.ctrl-choices button { font-family: var(--sans); font-size: 11px; letter-spacing: .5px; }
.ctrl-note {
  margin-top: 7px;
  font-size: 9.5px;
  line-height: 1.5;
  color: var(--text-faint);
  min-height: 14px;
}

/* ===================================================================
   触屏操控层
   =================================================================== */
.touch-controls {
  position: absolute;
  inset: 0;
  z-index: 40;
  pointer-events: none;               /* 容器透传，只有具体控件接收触摸 */
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}
.touch-controls * { touch-action: none; -webkit-tap-highlight-color: transparent; }

/* 通用触屏按钮 */
.tc-btn {
  pointer-events: auto;
  min-width: 46px;
  min-height: 42px;
  padding: 0 10px;
  border: 1px solid rgba(120, 200, 240, 0.35);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(18, 40, 56, 0.9), rgba(9, 20, 30, 0.92));
  color: var(--cyan);
  font-family: var(--sans);
  font-size: 12px;
  letter-spacing: .5px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  transition: transform .08s ease, background .12s ease, border-color .12s ease;
}
.tc-btn:active { transform: scale(0.94); background: rgba(71, 215, 232, 0.28); border-color: var(--cyan); }
.tc-btn.pressed { background: rgba(71, 215, 232, 0.32); border-color: var(--cyan); color: #fff; }
.tc-btn.tc-toggle.on { background: rgba(95, 224, 138, 0.26); border-color: var(--green); color: #d8ffe7; }

/* 左右两组操纵集群 */
.tc-cluster {
  position: absolute;
  bottom: 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
}
.tc-left { left: 18px; }
.tc-right { right: 18px; }

/* 姿态摇杆 */
.tc-stick {
  position: relative;
  width: 132px; height: 132px;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 40%, rgba(20, 46, 62, 0.82), rgba(6, 14, 22, 0.9));
  border: 1px solid rgba(120, 200, 240, 0.35);
  box-shadow: 0 8px 26px rgba(0, 0, 0, 0.55), inset 0 0 24px rgba(0, 0, 0, 0.5);
  pointer-events: auto;
  overflow: hidden;
}
.tc-stick-ring {
  position: absolute; inset: 12px;
  border-radius: 50%;
  border: 1px dashed rgba(120, 200, 240, 0.18);
}
.tc-stick-cross-h, .tc-stick-cross-v { position: absolute; background: rgba(120, 200, 240, 0.14); }
.tc-stick-cross-h { left: 12px; right: 12px; top: 50%; height: 1px; }
.tc-stick-cross-v { top: 12px; bottom: 12px; left: 50%; width: 1px; }
.tc-stick-knob {
  position: absolute;
  left: 50%; top: 50%;
  width: 52px; height: 52px;
  margin: -26px 0 0 -26px;
  border-radius: 50%;
  background: radial-gradient(circle at 40% 35%, #6fe4f2, #2b93a6 60%, #1a5c6b);
  border: 1px solid rgba(180, 245, 255, 0.7);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.6), 0 0 18px rgba(71, 215, 232, 0.4);
  transform: translate(0px, 0px);
  will-change: transform;
}
.tc-stick-label {
  font-size: 9px;
  letter-spacing: 1px;
  color: var(--text-faint);
}

/* 油门推杆 */
.tc-throttle-wrap { display: flex; flex-direction: column; align-items: center; gap: 5px; }
.tc-throttle-label { font-size: 10px; letter-spacing: 1px; color: var(--text-dim); }
.tc-throttle-label span { color: var(--amber); font-family: var(--mono); font-weight: 700; }
.tc-throttle {
  position: relative;
  width: 46px; height: 132px;
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(8, 16, 24, 0.92), rgba(18, 34, 46, 0.86));
  border: 1px solid rgba(120, 200, 240, 0.32);
  box-shadow: 0 8px 26px rgba(0, 0, 0, 0.55), inset 0 0 18px rgba(0, 0, 0, 0.6);
  pointer-events: auto;
  overflow: hidden;
}
.tc-throttle-fill {
  position: absolute; left: 0; right: 0; bottom: 0; height: 0%;
  background: linear-gradient(180deg, rgba(255, 181, 71, 0.55), rgba(255, 181, 71, 0.22));
  border-top: 1px solid rgba(255, 200, 120, 0.7);
  transition: height .06s linear;
}
.tc-throttle-knob {
  position: absolute;
  left: 3px; right: 3px;
  bottom: 0;
  height: 26px;
  margin-bottom: 0;
  border-radius: 7px;
  background: linear-gradient(180deg, #ffcf85, #d98a24 60%, #a5661a);
  border: 1px solid rgba(255, 226, 180, 0.8);
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.6), 0 0 14px rgba(255, 181, 71, 0.35);
  transform: translateY(0px);
  will-change: transform;
}

/* 方向舵 / 刹车 */
.tc-rudder { display: flex; gap: 6px; }
.tc-rudder .tc-btn { min-width: 44px; padding: 0 8px; font-size: 13px; }
.tc-rudder .tc-brake { color: var(--red); border-color: rgba(255, 93, 93, 0.45); font-size: 11px; }

/* 顶部功能按钮条 */
.tc-actions {
  position: absolute;
  top: 132px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  width: min(560px, 76vw);
}
.tc-actions .tc-btn { min-height: 38px; font-size: 11px; padding: 0 9px; }

/* 底部小工具 */
.tc-tools {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
}
.tc-tools .tc-btn { min-height: 36px; font-size: 11px; opacity: 0.9; }

/* 触屏模式：隐藏键盘提示与底部玻璃仪表，腾出操纵空间 */
body.touch-mode .hint { display: none; }
body.touch-mode .glass { display: none; }
body.touch-mode .atc-log { bottom: 190px; width: 300px; }

/* 触屏模式下的横屏矮屏适配 */
@media (max-height: 560px) {
  .tc-stick { width: 108px; height: 108px; }
  .tc-stick-knob { width: 44px; height: 44px; margin: -22px 0 0 -22px; }
  .tc-throttle { height: 108px; }
  .tc-actions { top: 110px; gap: 5px; }
  .tc-actions .tc-btn { min-height: 34px; min-width: 42px; font-size: 10px; padding: 0 7px; }
  .tc-cluster { bottom: 10px; }
  .tc-tools { bottom: 10px; }
}

/* 竖屏（手机）适配 */
@media (max-width: 620px) {
  .tc-actions { top: 158px; width: 94vw; gap: 5px; }
  .tc-actions .tc-btn { min-width: 44px; min-height: 36px; font-size: 10px; padding: 0 7px; }
  .tc-cluster { bottom: 12px; }
  .tc-left { left: 10px; }
  .tc-right { right: 10px; }
  .tc-stick { width: 116px; height: 116px; }
  .tc-throttle { height: 116px; }
  /* 竖屏底部横向空间不足：工具按钮移到顶部功能条下方作第二行，避开摇杆/油门/方向舵 */
  .tc-tools { top: 202px; bottom: auto; gap: 6px; }
  .tc-tools .tc-btn { min-height: 32px; min-width: 60px; font-size: 10px; padding: 0 6px; }
  body.touch-mode .atc-log { bottom: 148px; width: 260px; font-size: 9px; }
  .objectives { max-width: 210px; }
}
