/* 扫码验证页 — 对齐参考 UI：字号 / 细线 / 图片尺寸 */

:root {
  --bg: #f2f2f2;
  --card: #ffffff;
  --line: #e6e6e6;
  --label-bg: #f7f7f7;
  --text: #333333;
  --text-muted: #999999;
  --head: #3b4b8c;
  --ok: #4caf50;
  --fail: #e53935;
  --warn: #f0a000;
  --label-w: 96px;
}

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

html, body {
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei",
    -apple-system, BlinkMacSystemFont, "Noto Sans SC", sans-serif;
  font-size: 14px;
  line-height: 1.4;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}

.page {
  max-width: 390px;
  margin: 0 auto;
  min-height: 100vh;
  padding: 18px 20px 28px;
  display: flex;
  flex-direction: column;
}

/* —— 品牌 —— */
.brand {
  background: var(--card);
  border: 1px solid var(--line);
  overflow: hidden;
  margin-bottom: 12px;
}

.brand-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 16px 12px;
}

.brand-logo {
  width: 52px;
  height: 52px;
  object-fit: contain;
  flex-shrink: 0;
  border-radius: 50%;
}

.brand-text {
  text-align: left;
}

.brand-title {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.03em;
  color: #111;
  line-height: 1.25;
}

.brand-sub {
  margin-top: 3px;
  font-size: 12px;
  font-weight: 400;
  color: #888;
  line-height: 1.3;
}

.brand-sub:empty {
  display: none;
}

/* 横幅：上传图按原比例完整显示；色块高度适中、不铺满过宽 */
.brand-banner {
  width: 100%;
  background: linear-gradient(90deg, #5b6ea0 0%, #b8c0cc 100%);
  line-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.brand-banner.is-color,
.brand-banner.is-gradient {
  height: 100px;
  min-height: 100px;
}

.brand-banner.has-image {
  height: auto;
  min-height: 0;
  background: transparent;
}

.brand-banner-img {
  display: block;
  width: 100%;
  height: auto;
  max-width: 100%;
  vertical-align: top;
}

/* —— 结果卡片 —— */
.card {
  background: var(--card);
  border: 1px solid var(--line);
  overflow: hidden;
  margin: 0 0 14px;
}

.card-head {
  background: var(--head);
  color: #fff;
  text-align: left;
  font-size: 14px;
  font-weight: 500;
  padding: 9px 12px 9px 10px;
  letter-spacing: 0.06em;
}

.table {
  width: 100%;
  border-collapse: collapse;
}

.row {
  display: flex;
  align-items: stretch;
  border-bottom: 1px solid var(--line);
  min-height: 40px;
}

.row:last-child {
  border-bottom: 1px solid var(--line);
}

/* 左侧标题比蓝色「查询结果」更靠内（更大左缩进） */
.row-label {
  width: var(--label-w);
  flex-shrink: 0;
  background: var(--label-bg);
  border-right: 1px solid var(--line);
  padding: 10px 8px 10px 24px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  text-align: left;
  color: #333;
  font-size: 13px;
  font-weight: 400;
  line-height: 1.35;
}

.row-value {
  flex: 1;
  min-width: 0;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  word-break: break-all;
  font-size: 13px;
  font-weight: 400;
  color: #222;
  line-height: 1.4;
}

.row-value.thumb-wrap {
  padding: 10px 12px;
  align-items: center;
  justify-content: flex-start;
}

.row-value.is-status {
  word-break: normal;
  overflow: visible;
}

/* 数据核实缩略图：竖图，比旧版更大 */
.thumb {
  width: 100px;
  height: auto;
  max-height: 136px;
  object-fit: contain;
  border: 1px solid #ececec;
  background: #fafafa;
  cursor: zoom-in;
  display: block;
}

.status {
  display: block;
  width: 100%;
  white-space: nowrap;
  line-height: 1.4;
  font-size: 12px;
  letter-spacing: 0;
}

.status-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  margin-right: 4px;
  vertical-align: 0.08em;
  flex-shrink: 0;
}

.status.ok { color: var(--ok); }
.status.ok .status-dot { background: var(--ok); }

.status.fail { color: var(--fail); }
.status.fail .status-dot { background: var(--fail); }

.status.warn { color: var(--warn); }
.status.warn .status-dot { background: var(--warn); }

.hint {
  padding: 12px 12px 14px;
  font-size: 12px;
  color: #444;
  text-align: center;
  line-height: 1.5;
}

.hint:empty {
  display: none;
}

.hint a {
  color: #444;
  text-decoration: none;
}

/* —— 状态区 —— */
.state {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
}

.state[hidden],
.card[hidden] {
  display: none !important;
}

.state-inner {
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.7;
}

.state-inner.error {
  color: var(--fail);
}

/* —— 页脚 —— */
.footer {
  margin-top: auto;
  padding-top: 18px;
  text-align: center;
  font-size: 11px;
  color: #b0b0b0;
  font-weight: 400;
}

/* —— 图片预览 —— */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  cursor: zoom-out;
}

.lightbox img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

@media (max-width: 360px) {
  .brand-title { font-size: 16px; }
  .brand-logo { width: 46px; height: 46px; }
  .thumb { width: 90px; max-height: 124px; }
  --label-w: 88px;
}
