/**
 * 新版前端（SPA）补充样式 —— 主体复用 ../assets/style.css
 * 这里只放旧站没有、SPA 需要的少量样式。
 */

/* 表单内联复选 */
.chk {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  align-items: center;
  padding-top: 6px;
}
.chk label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 13px;
  color: var(--ink-2, #444);
  cursor: pointer;
}

/* 首页 hero 内的起盘表单：宽幅卡片里整体居中，不再左贴边 */.hero .form-row {
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
  justify-content: center;
  row-gap: 16px;
}
.hero .form-row .field { align-items: center; }
.hero .form-row .field > label { text-align: center; }
.hero .form-row .chk { justify-content: center; }
.hero .form-row input[type=number],
.hero .form-row select { text-align: center; }
.hero .form-row .btn { min-width: 128px; letter-spacing: 6px; }

/* 顶栏搜索框（nav.mainnav 内部，与旧站导航同一行） */
nav.mainnav .head-search {
  display: inline-flex;
  gap: 6px;
  align-items: center;
  margin-left: auto;
}
nav.mainnav .head-search input {
  width: 170px;
  padding: 7px 10px;
  font: inherit;
  font-size: 13px;
  border: 1px solid var(--line, #e0d5bd);
  border-radius: 2px;
  background: rgba(255, 255, 255, .55);
  color: var(--ink, #3b3326);
}
nav.mainnav .head-search input:focus {
  outline: none;
  border-color: var(--red, #8c2f24);
  background: #fff;
}
@media (max-width: 900px) {
  nav.mainnav .head-search { display: none; }
}

/* 打印时隐藏导航 */
@media print {
  .site-head, .site-foot, .no-print { display: none !important; }
}

/* 排盘页顶部操作条：徽标居左、操作按钮居右，窄屏自动纵排 */
.pan-top {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 14px;
  align-items: center;
  justify-content: space-between;
}
.pan-top .pan-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  min-width: 0;
}
.pan-top .pan-badges .badge { margin: 0; }
.pan-top .pan-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-shrink: 0;
}
.pan-top .btn { white-space: nowrap; }
@media (max-width: 620px) {
  .pan-top { flex-direction: column; align-items: stretch; }
  .pan-top .pan-actions { justify-content: flex-end; }
}

/* 列表卡片标题行：标题居左、徽标居右，窄屏自然换行 */
.row-top {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 8px;
}
.row-top.mb6 { margin-bottom: 6px; }
.row-top h3 { margin: 0; flex: 1; min-width: 180px; }
.row-top .badge { margin: 0; }

/* 顶栏搜索框 */
.head-search {
  display: flex;
  gap: 6px;
  align-items: center;
  margin-left: 14px;
}
.head-search input {
  width: 190px;
  padding: 6px 10px;
  border: 1px solid var(--line, #d8cfba);
  border-radius: 3px;
  background: var(--paper-2, #faf6ec);
  font-size: 13px;
  color: var(--ink, #333);
}
.head-search input:focus { outline: 1px solid var(--red, #8c2f24); }
@media (max-width: 960px) { .head-search { display: none; } }

/* 排盘历史操作列 */
.hist-act { white-space: nowrap; }
.hist-act .btn + .btn { margin-left: 6px; }

/* 接口连接异常提示条：部署不完整 / 服务端报错时给出自查入口，
   避免用户只看到「服务不可用」而无从下手 */
.api-alert {
  position: relative;
  padding: 10px 44px 10px 16px;
  background: #fbf2ef;
  border-bottom: 1px solid var(--red, #8c2f24);
  color: #6d2119;
  font-size: 13.5px;
  line-height: 1.85;
}
.api-alert b { color: var(--red, #8c2f24); }
.api-alert a { color: var(--red, #8c2f24); text-decoration: underline; }
.api-alert .tiny { color: #8a6a62; }
.api-alert-x {
  position: absolute; right: 14px; top: 8px;
  cursor: pointer; font-size: 18px; line-height: 1; color: #8a6a62;
}
.api-alert-x:hover { color: var(--red, #8c2f24); }
@media print { .api-alert { display: none; } }
