/* ============================================================
   实拍工作台 — 样式
   深色工具界面：低饱和底 + 单一强调色，所有面板靠层级和描边分层，
   不用大面积色块。像素密度按 8px 网格走。
   ============================================================ */

:root {
  --bg: #08090b;
  --bg-elev: #0d0f12;
  --line: rgba(255, 255, 255, 0.072);
  --line-soft: rgba(255, 255, 255, 0.045);
  --line-strong: rgba(255, 255, 255, 0.12);

  --fg: #eef1f5;
  --fg-mid: #99a1ae;
  --fg-dim: #626b79;

  --accent: #37e0a0;
  --accent-dim: #1fae7a;
  --accent-glow: rgba(55, 224, 160, 0.18);
  --danger: #ff6b6b;
  --warn: #ffb454;

  --r-lg: 16px;
  --r-md: 11px;
  --r-sm: 8px;

  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI",
          "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --mono: ui-monospace, "SF Mono", "JetBrains Mono", Menlo, Consolas, monospace;
}

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

html, body {
  height: 100%;
  overflow: hidden;
}

body {
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font);
  font-size: 13.5px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* 背景层：径向光晕 + 细网格，让纯黑不死板 */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(900px 500px at 18% -10%, rgba(55, 224, 160, 0.055), transparent 62%),
    radial-gradient(700px 420px at 92% 6%, rgba(90, 140, 255, 0.045), transparent 60%),
    linear-gradient(180deg, #08090b 0%, #07080a 100%);
  z-index: 0;
}

body::after {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.016) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.016) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 90% 70% at 50% 0%, #000 20%, transparent 78%);
  -webkit-mask-image: radial-gradient(ellipse 90% 70% at 50% 0%, #000 20%, transparent 78%);
}

/* 极轻的颗粒，压住大面积渐变的色带 */
.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.035;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ============ 顶栏 ============ */

.topbar {
  position: relative;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
  padding: 0 18px;
  border-bottom: 1px solid var(--line-soft);
  background: rgba(8, 9, 11, 0.72);
  backdrop-filter: blur(18px) saturate(1.3);
  -webkit-backdrop-filter: blur(18px) saturate(1.3);
}

.brand { display: flex; align-items: center; gap: 11px; }

.brand__mark {
  width: 32px; height: 32px;
  display: grid; place-items: center;
  border-radius: 9px;
  color: var(--accent);
  background: linear-gradient(160deg, rgba(55, 224, 160, 0.16), rgba(55, 224, 160, 0.04));
  border: 1px solid rgba(55, 224, 160, 0.22);
  box-shadow: 0 0 18px -6px var(--accent-glow), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}
.brand__mark svg { width: 18px; height: 18px; }

.brand__text { display: flex; flex-direction: column; line-height: 1.2; }
.brand__name { font-size: 13.5px; font-weight: 600; letter-spacing: 0.2px; }
.brand__sub {
  font-size: 9.5px;
  color: var(--fg-dim);
  letter-spacing: 1.4px;
  text-transform: uppercase;
  font-weight: 500;
}

.topbar__right { display: flex; align-items: center; gap: 10px; }

.status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 28px;
  padding: 0 11px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.026);
  font-size: 11.5px;
  color: var(--fg-mid);
  transition: border-color .2s, color .2s;
}

.status__dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--fg-dim);
  box-shadow: 0 0 0 0 transparent;
  transition: background .25s, box-shadow .25s;
}

.status[data-state="ok"] { border-color: rgba(55, 224, 160, 0.28); color: #a8f0d2; }
.status[data-state="ok"] .status__dot {
  background: var(--accent);
  box-shadow: 0 0 0 3px rgba(55, 224, 160, 0.14);
  animation: pulse 2.6s ease-in-out infinite;
}

.status[data-state="off"] { border-color: rgba(255, 180, 84, 0.3); color: #ffcf95; }
.status[data-state="off"] .status__dot { background: var(--warn); box-shadow: 0 0 0 3px rgba(255, 180, 84, 0.14); }

.status[data-state="checking"] .status__dot { animation: blink 1.1s steps(2, start) infinite; }

@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 3px rgba(55, 224, 160, 0.14); }
  50% { box-shadow: 0 0 0 5px rgba(55, 224, 160, 0.05); }
}
@keyframes blink { 50% { opacity: 0.25; } }

/* ============ 按钮 ============ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  height: 34px;
  padding: 0 14px;
  border-radius: var(--r-md);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  color: var(--fg);
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  transition: background .18s, border-color .18s, transform .1s, box-shadow .2s;
  white-space: nowrap;
  -webkit-tap-highlight-color: transparent;
}

.btn:hover { background: rgba(255, 255, 255, 0.065); border-color: var(--line-strong); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: 0.42; cursor: not-allowed; transform: none; }
.btn svg { width: 15px; height: 15px; }

.btn--ghost { height: 28px; padding: 0 11px; font-size: 11.5px; color: var(--fg-mid); }
.btn--ghost:hover { color: var(--fg); }

.btn--mini {
  height: 24px;
  padding: 0 9px;
  font-size: 11px;
  color: var(--fg-mid);
  border-radius: 6px;
}

.btn--primary {
  height: 38px;
  padding: 0 20px;
  font-size: 13px;
  font-weight: 600;
  color: #04120c;
  border: 1px solid rgba(55, 224, 160, 0.5);
  background: linear-gradient(180deg, #4ef0b4 0%, #24cf90 100%);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.28) inset, 0 8px 22px -10px rgba(55, 224, 160, 0.7);
}
.btn--primary:hover {
  background: linear-gradient(180deg, #5cf7bd 0%, #2ad99a 100%);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.32) inset, 0 10px 26px -9px rgba(55, 224, 160, 0.85);
  border-color: rgba(55, 224, 160, 0.7);
}
.btn--primary:disabled { background: rgba(255, 255, 255, 0.07); color: var(--fg-dim); border-color: var(--line); box-shadow: none; }

.btn--full { width: 100%; }

/* ============ 布局 ============ */

.layout {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 306px minmax(340px, 1fr) minmax(348px, 1.12fr);
  gap: 12px;
  padding: 12px;
  height: calc(100vh - 60px);
  height: calc(100dvh - 60px);
}

.col {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.12) transparent;
  padding-right: 2px;
}
.col::-webkit-scrollbar { width: 6px; }
.col::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.11); border-radius: 3px; }
.col::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, 0.2); }
.col::-webkit-scrollbar-track { background: transparent; }

/* ============ 卡片 ============ */

.card {
  position: relative;
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.042) 0%, rgba(255, 255, 255, 0.014) 100%);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.045) inset, 0 14px 32px -22px #000;
  padding: 14px;
  flex-shrink: 0;
  backdrop-filter: blur(6px);
}

.card--grow { flex: 1 1 auto; display: flex; flex-direction: column; min-height: 0; }
.card--log { flex: 0 0 190px; display: flex; flex-direction: column; min-height: 120px; }

.card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}
.card__head h2 {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 1.1px;
  text-transform: uppercase;
  color: var(--fg-mid);
}
.card__hint { font-size: 11px; color: var(--fg-dim); text-align: right; }

.card__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line-soft);
}

.counter { font-family: var(--mono); font-size: 11px; color: var(--fg-dim); }

/* ============ 上传 ============ */

.drop {
  display: block;
  border-radius: var(--r-md);
  border: 1px dashed rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.014);
  cursor: pointer;
  transition: border-color .2s, background .2s;
  overflow: hidden;
}
.drop:hover, .drop.is-over {
  border-color: rgba(55, 224, 160, 0.42);
  background: rgba(55, 224, 160, 0.035);
}

.drop__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  padding: 22px 12px;
  color: var(--fg-dim);
}
.drop__inner svg { width: 24px; height: 24px; opacity: 0.65; margin-bottom: 3px; }
.drop__title { font-size: 12.5px; color: var(--fg-mid); font-weight: 500; }
.drop__sub { font-size: 10.5px; color: var(--fg-dim); }

.thumbs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 6px;
  padding: 6px;
}
.thumb {
  position: relative;
  aspect-ratio: 3 / 4;
  border-radius: var(--r-sm);
  overflow: hidden;
  background: #000;
  border: 1px solid var(--line);
}
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.thumb__x {
  position: absolute;
  top: 3px; right: 3px;
  width: 18px; height: 18px;
  border-radius: 50%;
  border: none;
  background: rgba(0, 0, 0, 0.66);
  color: #fff;
  font-size: 12px;
  line-height: 1;
  cursor: pointer;
  display: grid;
  place-items: center;
  backdrop-filter: blur(4px);
  opacity: 0;
  transition: opacity .16s;
}
.thumb:hover .thumb__x { opacity: 1; }

/* ============ 场景 ============ */

.scene-list { display: flex; flex-direction: column; gap: 5px; }

.scene {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 10px;
  border-radius: var(--r-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: background .16s, border-color .16s;
}
.scene:hover { background: rgba(255, 255, 255, 0.035); }

.scene__radio {
  width: 13px; height: 13px;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.24);
  flex-shrink: 0;
  position: relative;
  transition: border-color .16s;
}
.scene__radio::after {
  content: '';
  position: absolute;
  inset: 2.5px;
  border-radius: 50%;
  background: var(--accent);
  transform: scale(0);
  transition: transform .16s cubic-bezier(.34, 1.56, .64, 1);
}

.scene__body { display: flex; flex-direction: column; min-width: 0; }
.scene__label { font-size: 12.5px; color: var(--fg); }
.scene__hint { font-size: 10.5px; color: var(--fg-dim); }

.scene.is-on {
  background: rgba(55, 224, 160, 0.055);
  border-color: rgba(55, 224, 160, 0.24);
}
.scene.is-on .scene__radio { border-color: var(--accent); }
.scene.is-on .scene__radio::after { transform: scale(1); }
.scene.is-on .scene__label { color: #a8f0d2; }

/* ============ 分段控件 ============ */

.seg {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  gap: 3px;
  padding: 3px;
  border-radius: var(--r-md);
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--line-soft);
}

.seg__item {
  height: 28px;
  border-radius: 7px;
  border: none;
  background: transparent;
  color: var(--fg-mid);
  font-family: inherit;
  font-size: 11.5px;
  font-weight: 500;
  cursor: pointer;
  transition: background .16s, color .16s, box-shadow .16s;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  padding: 0 6px;
}
.seg__item:hover { color: var(--fg); }
.seg__item.is-on {
  background: rgba(255, 255, 255, 0.09);
  color: var(--fg);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.07) inset;
}

/* ============ 参数 ============ */

.fields { display: flex; flex-direction: column; gap: 13px; margin-top: 14px; }

.field__row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 6px;
}
.field__row label { font-size: 11.5px; color: var(--fg-mid); }
.field__row output {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--accent);
  letter-spacing: 0.2px;
}

input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 3px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.1);
  outline: none;
  cursor: pointer;
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 13px; height: 13px;
  border-radius: 50%;
  background: #e6eaf0;
  border: 2px solid #0b0d10;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.22), 0 2px 6px rgba(0, 0, 0, 0.5);
  transition: transform .14s, box-shadow .14s;
}
input[type="range"]::-webkit-slider-thumb:hover {
  transform: scale(1.14);
  box-shadow: 0 0 0 1px var(--accent), 0 0 12px -2px var(--accent-glow);
}
input[type="range"]::-moz-range-thumb {
  width: 13px; height: 13px;
  border-radius: 50%;
  background: #e6eaf0;
  border: 2px solid #0b0d10;
  cursor: pointer;
}

/* ============ 提示词 ============ */

textarea {
  flex: 1 1 auto;
  min-height: 150px;
  width: 100%;
  resize: none;
  border-radius: var(--r-md);
  border: 1px solid var(--line);
  background: rgba(0, 0, 0, 0.28);
  color: var(--fg);
  font-family: var(--font);
  font-size: 13px;
  line-height: 1.72;
  padding: 12px 13px;
  outline: none;
  transition: border-color .18s, box-shadow .18s;
  scrollbar-width: thin;
}
textarea::placeholder { color: var(--fg-dim); }
textarea:focus {
  border-color: rgba(55, 224, 160, 0.36);
  box-shadow: 0 0 0 3px rgba(55, 224, 160, 0.07);
}

/* ============ 日志 ============ */

.log {
  flex: 1 1 auto;
  overflow-y: auto;
  font-family: var(--mono);
  font-size: 11px;
  line-height: 1.85;
  color: var(--fg-mid);
  padding-right: 4px;
  scrollbar-width: thin;
}
.log::-webkit-scrollbar { width: 5px; }
.log::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.1); border-radius: 3px; }

.log__empty { color: var(--fg-dim); font-family: var(--font); font-size: 11.5px; padding: 4px 0; }

.log__line {
  display: flex;
  gap: 7px;
  padding: 1.5px 0;
  animation: slideIn .22s ease both;
}
@keyframes slideIn {
  from { opacity: 0; transform: translateY(-3px); }
  to { opacity: 1; transform: none; }
}

.log__t { color: #4a525f; flex-shrink: 0; font-size: 10px; padding-top: 1px; }
.log__dot { width: 4px; height: 4px; border-radius: 50%; margin-top: 6px; flex-shrink: 0; background: var(--fg-dim); }
.log__m { flex: 1; word-break: break-word; }

.log__line[data-level="ok"] .log__dot { background: var(--accent); }
.log__line[data-level="ok"] .log__m { color: #9fe8c9; }
.log__line[data-level="error"] .log__dot { background: var(--danger); }
.log__line[data-level="error"] .log__m { color: #ff9c9c; }

/* ============ 结果 ============ */

.results {
  flex: 1 1 auto;
  overflow-y: auto;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  align-content: start;
  padding-right: 2px;
  scrollbar-width: thin;
}
.results::-webkit-scrollbar { width: 5px; }
.results::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.1); border-radius: 3px; }

.results__empty {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 50px 0;
  color: var(--fg-dim);
  font-size: 11.5px;
}
.results__empty svg { width: 30px; height: 30px; opacity: 0.4; }

.shot {
  position: relative;
  border-radius: var(--r-md);
  overflow: hidden;
  border: 1px solid var(--line);
  background: #000;
  aspect-ratio: 3 / 4;
  animation: pop .34s cubic-bezier(.2, .9, .3, 1) both;
}
@keyframes pop {
  from { opacity: 0; transform: scale(0.96) translateY(6px); }
  to { opacity: 1; transform: none; }
}

.shot img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s cubic-bezier(.2,.9,.3,1); }
.shot:hover img { transform: scale(1.03); }

.shot__bar {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 20px 8px 7px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.82), transparent);
  opacity: 0;
  transition: opacity .22s;
}
.shot:hover .shot__bar { opacity: 1; }

.shot__meta {
  font-family: var(--mono);
  font-size: 9px;
  color: rgba(255, 255, 255, 0.72);
  line-height: 1.4;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.shot__dl {
  width: 26px; height: 26px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
  flex-shrink: 0;
  backdrop-filter: blur(6px);
  transition: background .16s, transform .16s;
}
.shot__dl:hover { background: rgba(255, 255, 255, 0.26); transform: scale(1.06); }
.shot__dl svg { width: 13px; height: 13px; }

/* 生成中的骨架 */
.shot--skeleton {
  background: linear-gradient(100deg, rgba(255,255,255,0.03) 30%, rgba(255,255,255,0.075) 50%, rgba(255,255,255,0.03) 70%);
  background-size: 220% 100%;
  animation: shimmer 1.5s linear infinite;
  border-color: var(--line-soft);
}
@keyframes shimmer {
  from { background-position: 130% 0; }
  to { background-position: -30% 0; }
}

/* ============ 弹层 ============ */

.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: 20px;
}
.modal[hidden] { display: none; }

.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(3, 4, 6, 0.76);
  backdrop-filter: blur(10px);
  animation: fade .2s ease;
}
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }

.modal__box {
  position: relative;
  width: min(360px, 100%);
  padding: 18px;
  border-radius: 18px;
  border: 1px solid var(--line-strong);
  background: linear-gradient(180deg, #14171c 0%, #0d0f12 100%);
  box-shadow: 0 32px 70px -20px rgba(0, 0, 0, 0.9), 0 1px 0 rgba(255, 255, 255, 0.07) inset;
  animation: rise .26s cubic-bezier(.2, .9, .3, 1) both;
}
@keyframes rise {
  from { opacity: 0; transform: translateY(12px) scale(0.97); }
  to { opacity: 1; transform: none; }
}

.modal__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}
.modal__head h3 { font-size: 14px; font-weight: 600; }

.modal__x {
  width: 26px; height: 26px;
  border-radius: 7px;
  border: none;
  background: transparent;
  color: var(--fg-dim);
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: background .16s, color .16s;
}
.modal__x:hover { background: rgba(255, 255, 255, 0.07); color: var(--fg); }
.modal__x svg { width: 15px; height: 15px; }

.qr {
  aspect-ratio: 1;
  border-radius: 14px;
  background: #fff;
  display: grid;
  place-items: center;
  overflow: hidden;
  padding: 10px;
}
.qr img { width: 100%; height: 100%; object-fit: contain; display: block; border-radius: 6px; }

.qr__loading { display: grid; place-items: center; }

.spinner {
  width: 22px; height: 22px;
  border-radius: 50%;
  border: 2px solid rgba(0, 0, 0, 0.12);
  border-top-color: #1fae7a;
  animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.qr__tip {
  text-align: center;
  font-size: 11.5px;
  color: var(--fg-mid);
  margin: 13px 0 14px;
}

/* ============ Toast ============ */

.toast {
  position: fixed;
  left: 50%;
  bottom: 26px;
  transform: translateX(-50%) translateY(10px);
  z-index: 200;
  padding: 9px 17px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: rgba(20, 23, 28, 0.94);
  backdrop-filter: blur(14px);
  color: var(--fg);
  font-size: 12px;
  box-shadow: 0 12px 32px -12px rgba(0, 0, 0, 0.8);
  opacity: 0;
  transition: opacity .22s, transform .22s;
  pointer-events: none;
  max-width: 88vw;
}
.toast.is-show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast[data-type="error"] { border-color: rgba(255, 107, 107, 0.4); color: #ffb4b4; }

/* ============ 响应式 ============ */

@media (max-width: 1180px) {
  html, body { overflow: auto; }
  .layout {
    grid-template-columns: 1fr;
    height: auto;
    min-height: calc(100vh - 60px);
  }
  .col { overflow: visible; }
  .col--left { order: 1; }
  .col--center { order: 2; }
  .col--right { order: 3; }

  .col--left { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
  .col--left > .card:first-child { grid-column: 1 / -1; }

  .card--grow, .card--log { flex: none; }
  textarea { min-height: 190px; }
  .log { max-height: 210px; }
  .results { max-height: none; }
}

@media (max-width: 720px) {
  .topbar { height: 54px; padding: 0 12px; }
  .brand__sub { display: none; }
  .layout { padding: 10px; gap: 10px; }
  .col--left { grid-template-columns: 1fr; }
  .card { padding: 12px; border-radius: 14px; }
  .results { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .status { padding: 0 9px; font-size: 11px; }
  .btn--primary { width: 100%; }
  .card__foot { flex-direction: column-reverse; gap: 10px; align-items: stretch; }
  .counter { text-align: center; }
  .modal__box { width: 100%; }
}

/* 画幅选择：与机型分段控件同款，三个等分 */
/* 直接挂在 card 下的 field：与上方场景列表拉开距离 */
.card > .field { margin-top: 18px; }
.card > .field .field__row { margin-bottom: 8px; }
.seg--frame { margin-top: 0; }
