/* ============================================================
 * Telemetry / 日志查看器 / 反馈入口 样式（新增观测层，不改动游戏玩法/UI）
 * 仅作用于 #tel-root 内部元素，z-index 高于游戏层，但默认不阻挡游戏交互。
 * ============================================================ */
#tel-root {
  position: fixed;
  inset: 0;
  pointer-events: none;       /* 容器本身穿透，仅按钮/面板可点 */
  z-index: 99999;
  font-family: "Noto Serif SC", "PingFang SC", "Microsoft YaHei", sans-serif;
}
#tel-root button {
  pointer-events: auto;
  border: none;
  border-radius: 18px;
  padding: 8px 14px;
  font-size: 13px;
  color: #f3e6cf;
  background: rgba(40, 28, 16, 0.82);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
  cursor: pointer;
  backdrop-filter: blur(3px);
}
#tel-root button:hover { background: rgba(60, 42, 24, 0.92); }

#tel-log-btn  { position: fixed; left: 12px;  bottom: 12px; }
#tel-fb-btn   { position: fixed; right: 12px; bottom: 12px; background: rgba(120, 40, 30, 0.85); }
#tel-fb-btn:hover { background: rgba(150, 52, 38, 0.95); }

/* 日志面板 */
#tel-panel {
  position: fixed;
  left: 12px; bottom: 52px;
  width: min(440px, 92vw);
  max-height: 70vh;
  display: flex; flex-direction: column;
  background: rgba(26, 18, 10, 0.94);
  color: #ecdfc8;
  border: 1px solid rgba(214, 168, 63, 0.35);
  border-radius: 12px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
  pointer-events: auto;
  overflow: hidden;
}
.tel-hidden { display: none !important; }
.tel-head {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 10px; border-bottom: 1px solid rgba(214, 168, 63, 0.25);
}
.tel-title { font-weight: 700; font-size: 14px; }
.tel-sess { font-size: 11px; color: #b89a6a; flex: 1; }
#tel-close { padding: 2px 10px; font-size: 16px; line-height: 1; border-radius: 8px; }
.tel-meta { padding: 6px 10px; font-size: 11px; color: #c9b48a; border-bottom: 1px solid rgba(214,168,63,0.15); word-break: break-all; }
.tel-filters { display: flex; gap: 6px; padding: 8px 10px; flex-wrap: wrap; align-items: center; }
.tel-filters select { pointer-events: auto; background: rgba(40,28,16,0.9); color: #ecdfc8; border: 1px solid rgba(214,168,63,0.35); border-radius: 8px; padding: 4px 6px; font-size: 12px; }
.tel-filters button { padding: 4px 10px; font-size: 12px; }
#tel-list { overflow-y: auto; padding: 4px 6px 8px; font-size: 11px; line-height: 1.5; }
.tel-row { display: flex; gap: 6px; padding: 2px 4px; border-bottom: 1px solid rgba(255,255,255,0.04); align-items: baseline; }
.tel-cat { flex: 0 0 64px; color: #8fb3d9; }
.tel-kind { flex: 0 0 110px; color: #d8b27a; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tel-sum { flex: 1 1 auto; color: #d8d0c0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tel-t { flex: 0 0 44px; text-align: right; color: #7e7058; }
.tel-sev-err .tel-kind, .tel-sev-err .tel-sum { color: #ff9b86; }
.tel-sev-warn .tel-kind, .tel-sev-warn .tel-sum { color: #ffd98a; }

/* 反馈弹窗 */
#tel-fb {
  position: fixed; right: 12px; bottom: 52px;
  width: min(360px, 92vw);
  background: rgba(26, 18, 10, 0.96);
  color: #ecdfc8;
  border: 1px solid rgba(214, 168, 63, 0.35);
  border-radius: 12px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
  pointer-events: auto;
  padding: 12px;
}
.tel-fb-head { display: flex; justify-content: space-between; align-items: center; font-weight: 700; margin-bottom: 8px; }
#tel-fb-close { padding: 2px 10px; font-size: 16px; line-height: 1; border-radius: 8px; }
.tel-fb-cats { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 10px; font-size: 13px; }
.tel-fb-cats label { display: flex; align-items: center; gap: 6px; cursor: pointer; }
#tel-fb-note {
  width: 100%; margin-top: 10px; min-height: 64px; resize: vertical;
  background: rgba(40, 28, 16, 0.9); color: #ecdfc8;
  border: 1px solid rgba(214, 168, 63, 0.35); border-radius: 8px; padding: 8px; font-size: 12px;
  font-family: inherit;
}
.tel-fb-rating { display: flex; gap: 6px; margin-bottom: 10px; }
.tel-fb-rating .tel-rate {
  flex: 1; padding: 8px 4px; font-size: 12px; border-radius: 8px; line-height: 1.2;
  background: rgba(40, 28, 16, 0.6); color: #d8c6a6; border: 1px solid transparent;
}
.tel-fb-rating .tel-rate.tel-rate-on {
  background: rgba(214, 168, 63, 0.92); color: #2a1c10; font-weight: 700;
  border-color: rgba(255, 240, 200, 0.6);
}
.tel-fb-tip { font-size: 11px; color: #b89a6a; margin: 8px 0; line-height: 1.4; }
.tel-fb-actions { display: flex; gap: 8px; }
.tel-fb-actions button { flex: 1; }

#tel-toast {
  position: fixed; left: 50%; top: 18px; transform: translateX(-50%);
  background: rgba(40, 28, 16, 0.95); color: #f3e6cf;
  padding: 8px 16px; border-radius: 20px; font-size: 13px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.4); pointer-events: none;
}
