/* ============================================================================
   pages/record.css · 战绩页（命中率环 / 逐场点阵 / 判定构成 / 历史折叠 / 口径说明）
   依赖：tokens + base + components（designer 共享层）
   基线：_tmp/ui-v3/design/css/pages/record.css（F 设计稿 1:1），仅追加本页新增结构
   （历史筛选 / 搜索 / 空行 / 口径弹层内容）。不得修改共享 css。
   ========================================================================== */

/* ------------------------------ 战绩 hero ------------------------------ */
.record-hero {
  display: flex;
  align-items: center;
  gap: var(--s-4);
  padding: var(--s-4);
}
.record-hero .ring { width: 92px; height: 92px; --ring-w: 8px; }
.record-hero .ring > b { font-size: var(--fs-26); }
.rh-main { flex: 1; min-width: 0; }
.rh-main .rh-line {
  display: flex;
  align-items: baseline;
  gap: 6px;
  font-size: var(--fs-20);
  font-weight: var(--fw-bold);
  letter-spacing: -.01em;
  line-height: var(--lh-2);
}
.rh-main .rh-line em { font-style: normal; font-size: var(--fs-11); font-weight: var(--fw-regular); color: var(--txt-2); }
.rh-main .rh-sub { margin-top: 4px; font-size: var(--fs-12); color: var(--txt-2); }
.rh-main .rh-stats { display: flex; gap: var(--s-3); margin-top: 10px; }
.rh-stat { min-width: 0; }
.rh-stat b { display: block; font-size: var(--fs-17); font-weight: var(--fw-bold); line-height: 1; }
.rh-stat span { display: block; margin-top: 4px; font-size: 10px; color: var(--txt-2); }
.rh-stat .gold { color: var(--brand-text); }
.rh-stat .teal { color: var(--aurora-teal); }
.rh-stat .danger { color: var(--danger); }

/* ------------------------------ 判定构成 ------------------------------ */
.dim-list { display: flex; flex-direction: column; gap: 11px; }
.dim-row { display: grid; grid-template-columns: 54px 1fr 48px; align-items: center; gap: 10px; }
.dim-k { font-size: var(--fs-12); color: var(--txt-1); }
.dim-track { height: 6px; border-radius: 3px; background: var(--surface-1); overflow: hidden; }
.dim-track > i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--aurora-teal), var(--aurora-blue));
  transition: width var(--dur-4) var(--ease-out);
}
.dim-track > i.brand { background: linear-gradient(90deg, var(--brand-2), var(--brand-hi)); }
.dim-track > i.violet { background: linear-gradient(90deg, var(--aurora-violet), var(--aurora-blue)); }
.dim-v { text-align: right; font-size: var(--fs-12); color: var(--txt-0); font-weight: var(--fw-medium); }
.dim-v em { font-style: normal; color: var(--txt-3); font-size: 10px; margin-left: 3px; }

/* ------------------------------ 逐场点阵 ------------------------------ */
.dot-grid { display: grid; grid-template-columns: repeat(10, 1fr); gap: 6px; }
.dot-grid > i {
  position: relative;
  aspect-ratio: 1 / 1;
  border-radius: 5px;
  background: var(--surface-1);
  border: 1px solid var(--line-1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0;
}
.dot-grid > i.hit { background: var(--ok-soft); border-color: var(--ok-line); }
.dot-grid > i.hit::after { content: ""; width: 7px; height: 7px; border-radius: 3px; background: var(--ok); }
.dot-grid > i.miss { background: var(--danger-soft); border-color: var(--danger-line); }
.dot-grid > i.miss::after { content: ""; width: 7px; height: 7px; border-radius: 3px; background: var(--danger); }
.dot-grid > i.void::after { content: ""; width: 5px; height: 1px; border-radius: 1px; background: var(--txt-3); }
.dot-grid > i.now { box-shadow: 0 0 0 2px var(--brand-glow), inset 0 0 0 1px var(--brand-line); }
.dot-legend { display: flex; flex-wrap: wrap; gap: 12px; margin-top: var(--s-3); font-size: 10px; color: var(--txt-2); }
.dot-legend i { display: inline-block; width: 9px; height: 9px; border-radius: 3px; margin-right: 4px; vertical-align: -1px; }
.dot-legend i.hit { background: var(--ok); }
.dot-legend i.miss { background: var(--danger); }
.dot-legend i.void { background: var(--txt-3); height: 2px; vertical-align: 2px; }
.dot-legend i.now-dot { background: transparent; box-shadow: inset 0 0 0 1.5px var(--brand); }

/* ------------------------------ 历史场次（按销售日折叠） ------------------------------ */
.history-card { padding: var(--s-4) var(--s-3) var(--s-3); }
.history-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--s-2);
  padding: 0 var(--s-1) var(--s-3);
}
.history-tools {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-bottom: var(--s-2);
  border-bottom: 1px solid var(--line-1);
}
.hist-chips { padding: 0; margin: 0; }
.hist-chips::after { content: none; }
.hist-search { position: relative; display: block; padding: 0 var(--s-1); }
.hist-search-ico {
  position: absolute;
  left: calc(var(--s-1) + 12px);
  top: 50%;
  width: 15px;
  height: 15px;
  transform: translateY(-50%);
  color: var(--txt-3);
  pointer-events: none;
}
.hist-search .input {
  min-height: 40px;
  padding-left: 38px;
  font-size: var(--fs-13);
  background: var(--surface-1);
}
.hist-body { margin-top: 2px; }

.hist-day { margin-top: 2px; }
.hist-head {
  display: flex;
  align-items: center;
  gap: var(--s-2);
  width: 100%;
  min-height: 44px;
  padding: 0 4px;
  color: var(--txt-1);
  background: none;
  border: 0;
  text-align: left;
  -webkit-tap-highlight-color: transparent;
}
.hist-head .hd-date { font-size: var(--fs-12); font-weight: var(--fw-semibold); color: var(--txt-1); }
.hist-head .hd-count { font-size: var(--fs-11); color: var(--txt-3); }
.hist-head .hd-hit { margin-left: auto; font-size: var(--fs-11); color: var(--txt-2); }
.hist-head .hd-hit b { color: var(--ok); font-weight: var(--fw-semibold); }
.hist-head svg { flex: none; transition: transform var(--dur-2) var(--ease-out); }
.hist-chev { width: 15px; height: 15px; color: var(--txt-3); transform: rotate(90deg); }
.hist-day.is-open .hist-chev { transform: rotate(-90deg); }
.hist-day:not(.is-open) .hist-list { display: none; }

.hist-list { border-radius: var(--r-md); border: 1px solid var(--line-1); background: var(--surface-1); overflow: hidden; }
.hist-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: var(--s-2);
  align-items: center;
  padding: 10px var(--s-3);
  border-bottom: 1px solid var(--line-1);
  -webkit-tap-highlight-color: transparent;
  transition: background-color var(--dur-1) var(--ease-out);
}
.hist-row:last-child { border-bottom: 0; }
.hist-row.is-link:active { background: var(--surface-2); }
.hist-main { min-width: 0; }
.hist-team { font-size: var(--fs-13); color: var(--txt-0); font-weight: var(--fw-medium); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hist-team .dim { color: var(--txt-3); font-weight: var(--fw-regular); font-size: var(--fs-11); }
.hist-sub { margin-top: 3px; font-size: 10px; color: var(--txt-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hist-trail { display: flex; align-items: center; gap: 6px; flex: none; }
.hist-trail .li-chev { display: inline-flex; color: var(--txt-3); }
.hist-trail .li-chev svg { width: 15px; height: 15px; }
.hist-score { font-size: var(--fs-15); font-weight: var(--fw-semibold); letter-spacing: .04em; }
.hist-pick { font-size: 10px; color: var(--txt-2); }
.hist-empty { padding: 14px var(--s-3); font-size: var(--fs-12); color: var(--txt-3); }

/* ------------------------------ 口径说明弹层内容 ------------------------------ */
.caliber-list { display: flex; flex-direction: column; gap: 10px; font-size: var(--fs-13); line-height: var(--lh-4); color: var(--txt-1); }
.caliber-list p { margin: 0; }
.caliber-list b { color: var(--txt-0); font-weight: var(--fw-semibold); }
.caliber-list .num { color: var(--txt-1); }
.caliber-list .hint { margin-top: 2px; }

/* ------------------------------ 亮色微调 ------------------------------ */
:root[data-theme="light"] .hist-list { background: var(--bg-1); }
:root[data-theme="light"] .dot-grid > i { background: var(--bg-2); }
