/* ============================================================
   游戏界面的样式：颜色、位置、大小都在这里
   ============================================================ */
:root {
  --cell: 44px;        /* 背包里一个格子的大小 */
  --line: #343b36;
  --panel: #1a1d1b;
  --accent: #c8b06a;
  --good: #6fbf73;
  --bad: #d05a4e;
}

* { box-sizing: border-box; scrollbar-width: thin; scrollbar-color: #3a403b transparent; }

html, body {
  margin: 0;
  height: 100%;
  overflow: hidden;
  background: #0d0f0e;
  color: #d6d6cc;
  font-family: -apple-system, "PingFang SC", "Microsoft YaHei", "Helvetica Neue", sans-serif;
  font-size: 14px;
  user-select: none;
  -webkit-user-select: none;
}

#canvas { position: fixed; inset: 0; width: 100%; height: 100%; display: block; }
/* 简易操作（锁不了鼠标）时，游戏画面上不显示鼠标箭头 */
body.free-mode #canvas { cursor: none; }
.hidden { display: none !important; }

#loading, .fatal {
  position: fixed; inset: 0; z-index: 50;
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; background: #0d0f0e;
}
.fatal { color: var(--bad); z-index: 60; }

h1 { margin: 0 0 6px; font-size: 30px; letter-spacing: 4px; color: #ecebe2; }
h3 { margin: 16px 0 8px; font-size: 14px; color: var(--accent); font-weight: 600; letter-spacing: 1px; }
p { margin: 6px 0; line-height: 1.6; }
.hint { color: #868a80; font-size: 12px; }
.sub { color: #9a9d92; }

/* ---------------- 按钮 ---------------- */
.btn {
  font: inherit; color: #e8e6da; background: #2b302c; border: 1px solid #4a514b;
  padding: 10px 18px; cursor: pointer; letter-spacing: 2px;
}
.btn:hover { background: #363c37; }
.btn.primary { background: #5c6b3a; border-color: #8a9c5a; font-size: 18px; padding: 12px 28px; margin: 10px 0; }
.btn.primary:hover { background: #6c7d45; }
.btn.small { font-size: 12px; padding: 6px 12px; margin-top: 16px; color: #a9aca0; letter-spacing: 0; }
.warn { color: #e0b050; font-size: 13px; margin: 4px 0 8px; }

/* ---------------- 战斗界面 HUD ---------------- */
#hud { position: fixed; inset: 0; pointer-events: none; z-index: 5; }

#crosshair {
  position: absolute; left: 50%; top: 50%; width: 4px; height: 4px; margin: -2px 0 0 -2px;
  border-radius: 50%; background: rgba(255, 255, 255, 0.9); box-shadow: 0 0 2px #000;
}

/* 打中敌人时出现的 X 标记 */
#hitmarker {
  --hm: #ffffff;
  position: absolute; left: 50%; top: 50%; width: 24px; height: 24px; margin: -12px 0 0 -12px;
  opacity: 0; transition: opacity 0.3s;
  background:
    linear-gradient(45deg, transparent 45%, var(--hm) 45%, var(--hm) 55%, transparent 55%),
    linear-gradient(-45deg, transparent 45%, var(--hm) 45%, var(--hm) 55%, transparent 55%);
  -webkit-mask: radial-gradient(circle, transparent 5px, #000 6px);
  mask: radial-gradient(circle, transparent 5px, #000 6px);
}
#hitmarker.show { opacity: 1; transition: none; }
#hitmarker.kill { --hm: #ff4a3a; }

/* 指南针 */
#compass {
  position: absolute; top: 14px; left: 50%; width: 420px; height: 26px; margin-left: -210px;
  background: rgba(0, 0, 0, 0.35); border: 1px solid rgba(255, 255, 255, 0.14); overflow: hidden;
}
#compass .cm {
  position: absolute; left: 0; top: 0; width: 40px; margin-left: -20px; line-height: 24px;
  text-align: center; font-size: 13px; color: #cfd0c6;
}
#compass .cm.ex { color: #5dff8a; font-weight: 700; font-size: 16px; }
#compass::after {
  content: ""; position: absolute; left: 50%; top: 0; width: 1px; height: 6px; background: #fff;
}

#top-right { position: absolute; top: 14px; right: 18px; text-align: right; text-shadow: 0 1px 2px #000; }
#timer { font-size: 26px; font-variant-numeric: tabular-nums; letter-spacing: 2px; }
#timer.low { color: var(--bad); }
#extract-list { font-size: 13px; color: #8cf0a6; line-height: 1.7; }

#bottom-left { position: absolute; left: 20px; bottom: 20px; display: flex; align-items: flex-end; gap: 12px; }
#status-icons { display: flex; flex-direction: column; gap: 4px; font-size: 12px; }
#status-icons span { padding: 2px 8px; background: rgba(0, 0, 0, 0.55); border-left: 3px solid; }
#status-icons .bleed { color: #ff6b5e; }
#status-icons .frac { color: #e8c14e; }
#status-icons .dead { color: #9a9a9a; }
#status-icons .heavy { color: #e8a04e; }
#status-icons .tired { color: #9fc6ff; }

/* 体力条（屏幕下方中间） */
#stamina {
  position: absolute; left: 50%; bottom: 22px; width: 240px; height: 5px; margin-left: -120px;
  background: rgba(0, 0, 0, 0.55); border: 1px solid rgba(255, 255, 255, 0.2);
  opacity: 0; transition: opacity 0.5s;
}
#stamina.show { opacity: 1; }
#stamina-fill { height: 100%; width: 100%; background: #d9dccd; }
#stamina.tired #stamina-fill { background: #c0392b; }

/* 背包标题旁边的负重：快超重变黄，超重变红 */
#weight-info { margin-left: 8px; font-size: 12px; font-weight: normal; color: #9a9c92; }
#weight-info.warn { color: #e8c14e; }
#weight-info.over { color: #ff6b5e; }

#bottom-right { position: absolute; right: 22px; bottom: 20px; text-align: right; text-shadow: 0 1px 3px #000; }
#weapon-name { font-size: 14px; color: #c9cabf; }
#ammo-count { font-size: 34px; font-variant-numeric: tabular-nums; line-height: 1.1; }
#fire-mode { font-size: 12px; color: var(--accent); }

#prompt {
  position: absolute; left: 50%; top: 58%; transform: translateX(-50%);
  padding: 6px 14px; background: rgba(0, 0, 0, 0.55); font-size: 15px; white-space: nowrap;
}
#prompt:empty { display: none; }

/* 受伤时屏幕边缘变红 */
#vignette {
  position: absolute; inset: 0; opacity: 0;
  background: radial-gradient(ellipse at center, transparent 45%, rgba(150, 0, 0, 0.75) 100%);
}
#damage-flash { position: absolute; inset: 0; background: rgba(200, 20, 10, 0.35); opacity: 0; }
/* 被压制、伤得很重时，视野四周变暗（像"眼前发黑"） */
#tunnel {
  position: absolute; inset: 0; opacity: 0;
  background: radial-gradient(ellipse at center, transparent 30%, rgba(0, 0, 0, 0.85) 100%);
}

/* 提示子弹从哪个方向打过来 */
#dmg-dir { position: absolute; left: 50%; top: 50%; width: 0; height: 0; opacity: 0; }
#dmg-dir .arc {
  position: absolute; left: -45px; top: -150px; width: 90px; height: 16px;
  border-top: 5px solid rgba(255, 50, 30, 0.95); border-radius: 50% 50% 0 0;
}

/* ---------------- 进度条 ---------------- */
#progress {
  position: fixed; left: 50%; top: 66%; width: 260px; margin-left: -130px; z-index: 30;
  text-align: center; pointer-events: none; text-shadow: 0 1px 2px #000;
}
#progress-label { margin-bottom: 5px; font-size: 13px; }
#progress-bar { height: 7px; background: rgba(0, 0, 0, 0.6); border: 1px solid rgba(255, 255, 255, 0.25); }
#progress-fill { height: 100%; width: 0; background: var(--accent); }

/* ---------------- 提示消息 ---------------- */
#messages {
  position: fixed; left: 50%; top: 58px; transform: translateX(-50%); z-index: 40;
  display: flex; flex-direction: column; align-items: center; gap: 5px; pointer-events: none;
}
#messages div {
  padding: 5px 14px; background: rgba(0, 0, 0, 0.65); font-size: 14px; animation: msg 3.5s forwards;
}
#messages .good { color: #8cf0a6; }
#messages .bad { color: #ff8a7a; }
@keyframes msg { 0% { opacity: 0; } 8% { opacity: 1; } 80% { opacity: 1; } 100% { opacity: 0; } }

/* ---------------- 人形血量图 ---------------- */
.body-figure { position: relative; width: 64px; height: 114px; }
.body-figure .bp {
  position: absolute; background: #4f9d57; border: 1px solid rgba(0, 0, 0, 0.7); border-radius: 3px;
}
.body-figure .bp.bleed { box-shadow: 0 0 0 2px #ff4a3a; }
.body-figure .head    { left: 22px; top: 0;    width: 20px; height: 20px; border-radius: 8px; }
.body-figure .thorax  { left: 16px; top: 22px; width: 32px; height: 26px; }
.body-figure .stomach { left: 18px; top: 50px; width: 28px; height: 16px; }
.body-figure .lArm    { left: 3px;  top: 22px; width: 11px; height: 42px; }
.body-figure .rArm    { left: 50px; top: 22px; width: 11px; height: 42px; }
.body-figure .lLeg    { left: 18px; top: 68px; width: 13px; height: 46px; }
.body-figure .rLeg    { left: 33px; top: 68px; width: 13px; height: 46px; }
.body-holder { width: 100px; height: 176px; flex: none; }
.body-figure.big { transform: scale(1.5); transform-origin: top left; }

/* ---------------- 全屏的界面（菜单、暂停、结算）---------------- */
.overlay { position: fixed; inset: 0; z-index: 20; background: rgba(12, 14, 13, 0.93); }
.overlay.center { display: flex; align-items: center; justify-content: center; text-align: center; }
.overlay .box { max-width: 560px; padding: 30px 40px; background: var(--panel); border: 1px solid var(--line); }
#pause { cursor: pointer; z-index: 25; }
table.keys { border-collapse: collapse; margin: 8px auto; font-size: 12px; text-align: left; }
table.keys td { padding: 2px 8px; }
table.keys td:first-child { color: var(--accent); white-space: nowrap; text-align: right; }
#menu-keys table.keys { margin: 0; }

/* ---------------- 背包界面 ---------------- */
#inventory { display: flex; gap: 26px; padding: 26px 30px; overflow-x: auto; overflow-y: hidden; }
#inventory[data-mode="raid"] { background: rgba(12, 14, 13, 0.82); }
/* 每一栏内容太长时可以自己上下滚动 */
#col-left { width: 310px; flex: none; overflow-y: auto; padding-right: 6px; }
#col-mid { flex: none; overflow-y: auto; }
#col-right { flex: 1; min-width: 300px; display: flex; flex-direction: column; min-height: 0; }
#right-scroll { overflow: auto; flex: 1; min-height: 0; }
#col-left h3:first-child, #col-mid h3:first-child, #col-right h3:first-child { margin-top: 0; }
.howto { padding-left: 20px; margin: 6px 0; line-height: 1.7; color: #c4c5ba; }
.howto b { color: #5dff8a; }
#stats { margin: 6px 0; font-size: 13px; color: #a9aca0; line-height: 1.8; }
#stats b { color: #e8e6da; }

.slots { display: flex; gap: 14px; }
.slot-label { font-size: 12px; color: #868a80; margin-bottom: 4px; }

/* 格子 */
.grid {
  position: relative; overflow: hidden; background-color: #171a18;
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: var(--cell) var(--cell);
  border-right: 1px solid var(--line); border-bottom: 1px solid var(--line);
}
.grid.slot {
  width: calc(var(--cell) * 3); height: calc(var(--cell) * 1.5);
  background-image: none; border: 1px dashed #4a514b;
}

/* 物品 */
.item {
  position: absolute; overflow: hidden; cursor: grab; padding: 3px 4px;
  border: 1px solid rgba(255, 255, 255, 0.28); box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.35);
  font-size: 11px; line-height: 1.2; color: #fff; text-shadow: 0 1px 2px rgba(0, 0, 0, 0.9);
}
.item:hover { border-color: #fff; }
.item.dragging { opacity: 0.3; }
/* 物品图标：居中放在格子里；旋转过的物品图标也转 90 度 */
.item .ic {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  background: center / 88% 88% no-repeat; pointer-events: none;
  filter: drop-shadow(0 0 1px rgba(255, 255, 255, 0.4));   /* 一圈很淡的亮边，深色的东西在深色底上也能看清 */
}
.item .ic.rot { transform: translate(-50%, -50%) rotate(90deg); }
.item .ic.fill { width: 100%; height: 100%; background-size: contain; }
.item .nm { position: relative; display: block; word-break: break-all; font-size: 10px; color: #d6d8cc; }
.item .ct { position: absolute; right: 3px; bottom: 1px; font-size: 11px; font-variant-numeric: tabular-nums; }
.item.ghost { position: fixed; z-index: 100; pointer-events: none; opacity: 0.85; cursor: grabbing; }

/* 拖动时显示"能不能放在这里"的高亮 */
.drop-hl { position: absolute; pointer-events: none; background: rgba(90, 200, 110, 0.32); border: 1px solid #5ac86e; z-index: 5; }
.drop-hl.bad { background: rgba(210, 70, 60, 0.32); border-color: #d2463c; }

#tooltip {
  position: fixed; z-index: 110; max-width: 240px; padding: 8px 10px; pointer-events: none;
  background: #0f1110; border: 1px solid #4a514b; font-size: 12px; line-height: 1.6;
}
#tooltip b { font-size: 13px; color: #fff; }
#tooltip .st { color: #a9aca0; }
#tooltip .val { color: var(--accent); }

#ctx-menu { position: fixed; z-index: 120; min-width: 110px; background: #0f1110; border: 1px solid #4a514b; }
.ctx-item { padding: 7px 14px; cursor: pointer; font-size: 13px; }
.ctx-item:hover { background: #2b302c; }

/* ---------------- 身体状况面板 ---------------- */
.health-wrap { display: flex; gap: 14px; }
#part-list { flex: 1; font-size: 12px; }
.prow { margin-bottom: 7px; }
.prow .top { display: flex; justify-content: space-between; }
.prow .ps { color: #ff8a7a; }
.pbar { height: 6px; background: #0b0c0b; border: 1px solid #333; margin-top: 2px; }
.pfill { height: 100%; background: #4f9d57; }
#med-buttons { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
#med-buttons button { font: inherit; font-size: 12px; padding: 7px 4px; color: #e8e6da; background: #2b302c; border: 1px solid #4a514b; cursor: pointer; }
#med-buttons button:hover { background: #363c37; }
#med-buttons button.none { opacity: 0.4; }

/* ============================================================
   出击流程的界面：主菜单、操作说明、出击准备、部署、进场、结算
   ============================================================ */
h2 { margin: 0 0 4px; font-size: 22px; letter-spacing: 3px; color: #ecebe2; font-weight: 600; }
.row { display: flex; gap: 10px; align-items: center; margin: 12px 0; }
.row.end { justify-content: flex-end; margin: 22px 0 0; }
.row .btn.primary { margin: 0; }

/* 全屏界面。背后是慢慢转动的地图，所以左边深、右边透一点 */
.screen {
  position: fixed; inset: 0; z-index: 20; display: flex; align-items: center;
  background: linear-gradient(90deg, rgba(8, 10, 9, 0.95) 0%, rgba(8, 10, 9, 0.78) 38%, rgba(8, 10, 9, 0.35) 70%, rgba(8, 10, 9, 0.6) 100%);
}
.screen.solid { background: #070908; z-index: 27; justify-content: center; }

/* ---- 主菜单 ---- */
.home-left { margin-left: 8vw; width: 360px; }
.logo { font-size: 58px; font-weight: 700; letter-spacing: 12px; color: #f0efe6; line-height: 1.1; }
.logo-sub { font-size: 12px; letter-spacing: 5px; color: var(--accent); margin: 8px 0 46px; }
.mbtn {
  display: block; width: 100%; margin: 0 0 10px; padding: 14px 20px; text-align: left; cursor: pointer;
  font: inherit; font-size: 17px; letter-spacing: 6px; color: #d6d6cc;
  background: rgba(30, 34, 31, 0.72); border: 1px solid #3a413b; border-left: 3px solid #3a413b;
  transition: background 0.15s, padding-left 0.15s, border-color 0.15s;
}
.mbtn:hover { background: rgba(52, 58, 53, 0.9); padding-left: 30px; border-left-color: var(--accent); color: #fff; }
.mbtn.primary { border-left-color: var(--accent); color: #fff; font-size: 20px; }
.mbtn.dim { font-size: 13px; letter-spacing: 3px; color: #8d9086; margin-top: 26px; padding: 9px 20px; }
.home-right { position: absolute; right: 6vw; bottom: 12vh; width: 300px; }
.foot { position: absolute; left: 8vw; bottom: 26px; font-size: 12px; color: #6f7269; letter-spacing: 1px; }

/* ---- 小卡片和"名称 …… 数值"的行 ---- */
.card { background: rgba(18, 21, 19, 0.86); border: 1px solid #333a35; padding: 16px 18px; }
.card-title { font-size: 12px; letter-spacing: 4px; color: var(--accent); margin-bottom: 10px; padding-bottom: 8px; border-bottom: 1px solid #2c322d; }
.kv { display: flex; justify-content: space-between; gap: 18px; padding: 5px 0; font-size: 13px; color: #a4a79c; }
.kv b { color: #e6e5da; font-weight: 500; text-align: right; }
.kv b.dim { color: #6f7269; }
.good { color: #8cf0a6 !important; }
.bad { color: #ff8a7a !important; }
.note { font-size: 12px; color: #868a80; margin: 10px 0 0; line-height: 1.7; }
.warn-line { color: #e6b450; font-size: 13px; padding: 4px 0; }
.ok-line { color: #8cf0a6; font-size: 13px; padding: 6px 0; }

/* ---- 居中的大面板（操作说明、出击准备）---- */
.panel { margin: 0 auto; width: min(760px, 92vw); max-height: 92vh; overflow-y: auto; background: rgba(14, 17, 15, 0.94); border: 1px solid #333a35; padding: 26px 30px; }
.panel.wide { width: min(900px, 94vw); }
.panel-title { font-size: 20px; letter-spacing: 6px; color: #ecebe2; margin-bottom: 8px; }
.cols { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.cols.three { grid-template-columns: 1.25fr 1fr 1fr; }
.steps { display: flex; gap: 26px; font-size: 12px; letter-spacing: 3px; color: #5d6058; margin-bottom: 18px; }
.steps span.on { color: var(--accent); border-bottom: 2px solid var(--accent); padding-bottom: 5px; }
.loc-name { font-size: 30px; letter-spacing: 8px; color: #f0efe6; }
.loc-sub { font-size: 11px; letter-spacing: 4px; color: #7d8076; margin: 4px 0 12px; }

/* ---- 部署中 ---- */
.deploy-box { width: min(520px, 90vw); }
#deploy-stages { margin-top: 26px; min-height: 104px; }
.stage { display: flex; justify-content: space-between; padding: 7px 0; border-bottom: 1px solid #1d211e; font-size: 14px; color: #a4a79c; letter-spacing: 2px; }
.stage b { color: #6f7269; font-weight: 400; }
.stage b.done { color: #8cf0a6; }
#deploy-count { height: 130px; margin-top: 14px; font-size: 96px; line-height: 110px; color: #f0efe6; font-variant-numeric: tabular-nums; }
#deploy-count small { display: block; font-size: 12px; line-height: 20px; letter-spacing: 5px; color: var(--accent); }
#deploy-tip { margin-top: 20px; font-size: 13px; color: #868a80; line-height: 1.7; min-height: 44px; }

/* ---- 进场：全黑慢慢变透明，中间的地点标题多停一会儿 ---- */
#intro { position: fixed; inset: 0; z-index: 15; background: #000; pointer-events: none; display: flex; align-items: center; justify-content: center; text-align: center; }
#intro.fade { background: rgba(0, 0, 0, 0); transition: background 1.8s ease-out; }
#intro-card { transition: opacity 1.2s; text-shadow: 0 2px 10px #000; }
#intro.gone #intro-card { opacity: 0; }
#intro-sub { margin-top: 10px; font-size: 14px; letter-spacing: 3px; color: #cfd0c6; }

/* ---- 结算：先只有大字，展开后标题上移、露出详细统计 ---- */
#result { cursor: pointer; }
.result-box { width: min(980px, 94vw); text-align: center; }
.result-kicker { font-size: 12px; letter-spacing: 8px; color: #7d8076; }
#result-title { font-size: 72px; letter-spacing: 18px; margin: 14px 0 10px; font-weight: 700; }
#result-sub { font-size: 15px; letter-spacing: 2px; color: #b4b6ab; }
#result-more { max-height: 0; opacity: 0; overflow: hidden; text-align: left; transition: max-height 0.6s ease, opacity 0.6s ease 0.2s, margin-top 0.6s; }
#result.open { cursor: default; }
#result.open #result-more { max-height: 640px; opacity: 1; margin-top: 30px; }
#result.open #result-title { font-size: 46px; letter-spacing: 12px; transition: font-size 0.5s, letter-spacing 0.5s; }
.kill-list { margin-top: 8px; max-height: 190px; overflow-y: auto; border-top: 1px solid #2c322d; }
.kill { display: grid; grid-template-columns: 1.3fr 0.8fr 1.3fr 0.8fr; gap: 6px; padding: 4px 0; font-size: 12px; color: #c4c5ba; border-bottom: 1px solid #1d211e; }
.kill span:last-child { text-align: right; color: #8d9086; }

/* ============================================================
   交易界面
   ============================================================ */
#trade { display: flex; gap: 22px; padding: 24px 28px; overflow: hidden; }
#trade-left { width: 300px; flex: none; overflow-y: auto; }
#trade-mid { flex: 1; min-width: 320px; display: flex; flex-direction: column; min-height: 0; }
#trade-right { flex: none; display: flex; flex-direction: column; min-height: 0; max-width: 46vw; }
#trade-scroll { overflow: auto; flex: 1; min-height: 120px; }
#trade-list { overflow-y: auto; flex: 1; min-height: 0; padding-right: 6px; }
#trade-listings { flex: none; max-height: 34%; overflow-y: auto; }
#trade h3:first-child { margin-top: 0; }

.wallet { display: flex; align-items: baseline; gap: 10px; margin: 10px 0 14px; padding: 10px 14px; background: #141714; border: 1px solid #333a35; }
.wallet span { font-size: 12px; color: #868a80; letter-spacing: 2px; }
.wallet b { font-size: 22px; color: #8cf0a6; font-variant-numeric: tabular-nums; }
.wallet i { margin-left: auto; font-style: normal; font-size: 12px; color: #6f7269; }

.tab { display: block; width: 100%; margin-bottom: 6px; padding: 9px 14px; text-align: left; cursor: pointer; font: inherit; color: #c4c5ba; background: #1a1d1b; border: 1px solid #333a35; border-left: 3px solid #333a35; }
.tab b { display: block; font-size: 15px; letter-spacing: 3px; font-weight: 500; }
.tab span { font-size: 11px; color: #7d8076; }
.tab:hover { background: #242824; }
.tab.on { border-left-color: var(--accent); background: #262b26; color: #fff; }
#trade-info { margin: 12px 0; }
.lvbar { height: 4px; background: #0b0c0b; margin: 2px 0 6px; }
.lvbar div { height: 100%; background: var(--accent); }

#trade-filters { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
#trade-filters:empty { display: none; }
.chip { font: inherit; font-size: 12px; padding: 4px 11px; cursor: pointer; color: #a4a79c; background: #1a1d1b; border: 1px solid #333a35; }
.chip.on { color: #fff; border-color: var(--accent); }
.gap { flex: 1; }

/* 一行货物：图标 + 名称说明 + 价格 + 按钮 */
.offer { display: flex; align-items: center; gap: 12px; padding: 7px 10px; margin-bottom: 5px; background: #171a18; border: 1px solid #2a302b; }
.offer.off { opacity: 0.5; }
.t-ic { width: 54px; height: 40px; flex: none; background: center / contain no-repeat; filter: drop-shadow(0 0 1px rgba(255, 255, 255, 0.4)); }
.o-main { flex: 1; min-width: 0; }
.o-main b { display: block; font-size: 14px; font-weight: 500; color: #e6e5da; }
.o-main span { font-size: 11px; color: #7d8076; }
.o-price { font-size: 15px; color: #e8d9a0; font-variant-numeric: tabular-nums; white-space: nowrap; }
.o-price.poor { color: #b0625a; }
.btn.mini { padding: 5px 12px; font-size: 12px; letter-spacing: 1px; }
.btn[disabled] { opacity: 0.35; cursor: not-allowed; }

/* 挂单窗口 */
#list-dialog { position: fixed; inset: 0; z-index: 60; background: rgba(0, 0, 0, 0.6); display: flex; align-items: center; justify-content: center; }
.dialog { width: 400px; background: #121512; border: 1px solid #4a514b; padding: 20px 22px; }
.dialog .offer { margin-bottom: 10px; }
.dialog input { width: 130px; font: inherit; font-size: 15px; text-align: right; color: #fff; background: #0b0c0b; border: 1px solid #4a514b; padding: 4px 8px; }
#list-hint { margin-top: 10px; font-size: 13px; min-height: 20px; }

/* ============================================================
   瞄准镜的镜框：中间圆形透明，外面全黑，中间一个十字线
   ============================================================ */
#scope-overlay { position: absolute; inset: 0; display: none; background: radial-gradient(circle at center, transparent 0, transparent 40vh, #000 40.3vh); }
#scope-overlay.on { display: block; }
#scope-overlay .reticle { position: absolute; left: 50%; top: 50%; width: 80vh; height: 80vh; transform: translate(-50%, -50%); border-radius: 50%;
  background:
    linear-gradient(#000, #000) center / 100% 1px no-repeat,
    linear-gradient(#000, #000) center / 1px 100% no-repeat,
    linear-gradient(#000, #000) left center / 40% 4px no-repeat,
    linear-gradient(#000, #000) right center / 40% 4px no-repeat,
    linear-gradient(#000, #000) center bottom / 4px 40% no-repeat;
  box-shadow: inset 0 0 6vh rgba(0, 0, 0, 0.7);
}

/* ============================================================
   改装台：中间是透明的，能看到后面画出来的 3D 枪
   ============================================================ */
#modding { display: flex; gap: 20px; padding: 24px 28px; background: none; pointer-events: none; }
#modding > div { pointer-events: auto; }
#mod-left, #mod-right { flex: none; overflow-y: auto; background: rgba(14, 17, 15, 0.94); border: 1px solid #333a35; padding: 18px; }
#mod-left { width: 280px; }
#mod-right { width: 360px; }
#mod-mid { flex: 1; min-width: 300px; display: flex; flex-direction: column; }
#mod-title b { font-size: 26px; letter-spacing: 6px; color: #f0efe6; font-weight: 500; }
#mod-title span { margin-left: 14px; font-size: 12px; color: #6f7269; }
#mod-view { flex: 1; min-height: 200px; cursor: grab; }
#mod-view:active { cursor: grabbing; }
#mod-stats { flex: none; }
#mod-weapons .tab { display: flex; flex-wrap: wrap; align-items: center; column-gap: 10px; }
#mod-weapons .tab .t-ic { width: 70px; height: 34px; }
#mod-weapons .tab b { font-size: 14px; }
#mod-weapons .tab span { width: 100%; }
.slot-card { margin-bottom: 14px; }
.slot-card .card-title { margin-bottom: 6px; }
.empty-slot { padding: 10px; font-size: 13px; color: #6f7269; border: 1px dashed #3a413b; margin-bottom: 5px; }
.offer.cand { background: #121412; border-style: dashed; }
.stat-row { display: grid; grid-template-columns: 82px 1fr 78px 72px; align-items: center; gap: 10px; padding: 3px 0; font-size: 12px; color: #a4a79c; }
.stat-row b { font-weight: 500; color: #e6e5da; text-align: right; font-variant-numeric: tabular-nums; }
.stat-row i { font-style: normal; font-size: 11px; }
.sbar { height: 5px; background: #0b0c0b; }
.sbar div { height: 100%; background: #8a8c80; transition: width 0.2s; }
