/* ===== 通用设计系统：深色科技风 + 玻璃拟态（音视频转文字 / 媒体工具箱共用） ===== */
:root, [data-theme="dark"] {
  --bg: #19140c;
  --bg-elev: #272013;
  --text: #ede8de;
  --text-2: #b4bbcc;
  --muted: #7d869c;
  --card: rgba(255, 255, 255, 0.045);
  --card-strong: rgba(255, 255, 255, 0.07);
  --card-solid: #2b2314;
  --border: rgba(255, 255, 255, 0.085);
  --border-strong: rgba(255, 255, 255, 0.16);
  --input: rgba(255, 255, 255, 0.05);
  --a1: #d5b379;
  --a2: #d6b57c;
  --grad: linear-gradient(135deg, #d5b379 0%, #d6b57c 100%);
  --grad-soft: linear-gradient(135deg, rgba(213,179,121, 0.16), rgba(214,181,124, 0.16));
  --glow: 0 0 0 1px rgba(222,195,149, 0.35), 0 8px 30px -8px rgba(215,182,125, 0.55);
  --shadow: 0 10px 40px -12px rgba(0, 0, 0, 0.55);
  --ok: #34d399;
  --warn: #fbbf24;
  --err: #f87171;
  --radius: 16px;
  --radius-sm: 12px;
  --glow-1: rgba(213,179,121, 0.20);
  --glow-2: rgba(214,181,124, 0.18);
  --grid-line: rgba(255, 255, 255, 0.028);
  --bar-bg: rgba(25,20,12, 0.72);
  --panel-bg: rgba(38,31,18, 0.985);
  color-scheme: dark;
}
[data-theme="light"] {
  --bg: #f0e8db;
  --bg-elev: #ffffff;
  --text: #282011;
  --text-2: #524836;
  --muted: #64748b;
  --card: rgba(255, 255, 255, 0.62);
  --card-strong: rgba(255, 255, 255, 0.85);
  --card-solid: #ffffff;
  --border: rgba(40,32,17, 0.08);
  --border-strong: rgba(40,32,17, 0.16);
  --input: rgba(255, 255, 255, 0.8);
  --grad-soft: linear-gradient(135deg, rgba(213,179,121, 0.10), rgba(214,181,124, 0.10));
  --glow: 0 0 0 1px rgba(215,182,125, 0.35), 0 8px 26px -10px rgba(215,182,125, 0.45);
  --shadow: 0 10px 34px -14px rgba(57,48,32, 0.22);
  --glow-1: rgba(213,179,121, 0.16);
  --glow-2: rgba(214,181,124, 0.13);
  --grid-line: rgba(40,32,17, 0.035);
  --bar-bg: rgba(240,232,219, 0.75);
  --panel-bg: rgba(255, 255, 255, 0.985);
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", "Noto Sans CJK SC", "Source Han Sans SC", sans-serif;
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  transition: background-color .3s ease, color .3s ease;
}
/* 背景：柔和的渐变光晕 + 极淡的网格线 */
body::before {
  content: "";
  position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background:
    radial-gradient(620px 420px at 8% -6%, var(--glow-1), transparent 70%),
    radial-gradient(680px 460px at 96% 4%, var(--glow-2), transparent 70%),
    radial-gradient(900px 520px at 50% 115%, var(--glow-1), transparent 70%);
}
body::after {
  content: "";
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 30%, transparent 85%);
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 30%, transparent 85%);
}
a { color: var(--a1); text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
svg { flex: none; }
.hidden { display: none !important; }
.muted { color: var(--muted); }
.grad-text { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ===== 顶栏 ===== */
.topbar {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(18px) saturate(150%);
  -webkit-backdrop-filter: blur(18px) saturate(150%);
  background: var(--bar-bg);
  border-bottom: 1px solid var(--border);
}
.topbar-inner { max-width: 1120px; margin: 0 auto; padding: 12px 20px; display: flex; align-items: center; gap: 12px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 650; font-size: 16px; letter-spacing: .2px; }
.brand-mark {
  width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; color: #fff;
  background: var(--grad); box-shadow: 0 6px 18px -6px rgba(215,182,125, .7);
}
.spacer { flex: 1; }
.icon-btn {
  height: 38px; min-width: 38px; padding: 0 12px; border-radius: 11px; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  background: var(--card); border: 1px solid var(--border); color: var(--text-2); font-size: 14px;
  transition: border-color .2s, background .2s, color .2s;
}
.icon-btn:hover { border-color: var(--border-strong); color: var(--text); background: var(--card-strong); }
.icon-btn.square { padding: 0; width: 38px; }
.badge {
  min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; font-size: 11px; line-height: 18px; text-align: center;
  background: var(--grad); color: #fff; font-weight: 600;
}

/* ===== 历史下拉面板 ===== */
.history-wrap { position: relative; }
.history-panel {
  position: absolute; right: 0; top: calc(100% + 10px); width: 380px; max-height: min(70vh, 560px);
  display: flex; flex-direction: column;
  background: var(--panel-bg);
  backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--border-strong); border-radius: var(--radius); box-shadow: var(--shadow);
  transform-origin: top right; animation: pop .18s ease-out;
}
.history-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px 10px; border-bottom: 1px solid var(--border); }
.history-head b { font-size: 14px; }
.history-list { overflow-y: auto; padding: 8px; }
.history-empty { padding: 28px 16px; text-align: center; color: var(--muted); font-size: 13px; }
.h-item { display: flex; gap: 10px; align-items: center; padding: 10px; border-radius: 12px; cursor: pointer; transition: background .15s; }
.h-item:hover { background: var(--card-strong); }
.h-icon { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: var(--grad-soft); color: var(--a1); border: 1px solid var(--border); }
.h-main { flex: 1; min-width: 0; }
.h-title { font-size: 13.5px; font-weight: 550; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.h-sub { font-size: 12px; color: var(--muted); display: flex; gap: 8px; flex-wrap: wrap; }
.h-del { opacity: .55; background: none; border: 0; color: var(--muted); padding: 6px; border-radius: 8px; }
.h-del:hover { opacity: 1; color: var(--err); background: var(--card); }
.link-btn { background: none; border: 0; color: var(--muted); font-size: 12.5px; padding: 4px 6px; border-radius: 6px; }
.link-btn:hover { color: var(--text); }
@keyframes pop { from { opacity: 0; transform: translateY(-6px) scale(.98); } to { opacity: 1; transform: none; } }

/* ===== 主体 ===== */
.container { max-width: 1120px; margin: 0 auto; padding: 28px 20px 80px; }
.hero { text-align: center; padding: 18px 0 26px; }
.hero h1 { margin: 0 0 8px; font-size: clamp(26px, 4.2vw, 38px); line-height: 1.2; font-weight: 750; letter-spacing: -.5px; }
.hero p { margin: 0 auto; max-width: 620px; color: var(--muted); font-size: 15px; }
.chips { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 16px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 999px; font-size: 12.5px;
  background: var(--card); border: 1px solid var(--border); color: var(--text-2);
}
.chip i { width: 6px; height: 6px; border-radius: 50%; background: var(--grad); display: inline-block; }

body.compact .hero p, body.compact .chips { display: none; }
body.compact .hero { padding: 6px 0 16px; }
body.compact .hero h1 { font-size: clamp(22px, 3vw, 28px); }

/* ===== 步骤条 ===== */
.stepper { display: flex; align-items: center; justify-content: center; gap: 0; margin: 4px auto 24px; max-width: 560px; }
.step { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 14px; white-space: nowrap; }
.step-dot {
  width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-size: 13px; font-weight: 650;
  background: var(--card); border: 1px solid var(--border-strong); color: var(--muted); transition: all .25s;
}
.step.active { color: var(--text); font-weight: 600; }
.step.active .step-dot { background: var(--grad); border-color: transparent; color: #fff; box-shadow: 0 0 0 4px rgba(215,182,125, .18), 0 6px 18px -6px rgba(215,182,125, .8); }
.step.done { color: var(--text-2); }
.step.done .step-dot { background: var(--grad-soft); border-color: rgba(215,182,125, .5); color: var(--a1); }
.step-line { flex: 1; height: 2px; min-width: 24px; margin: 0 12px; border-radius: 2px; background: var(--border-strong); position: relative; overflow: hidden; }
.step-line.done::after { content: ""; position: absolute; inset: 0; background: var(--grad); }

/* ===== 卡片 ===== */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  box-shadow: var(--shadow);
  padding: 22px;
}
.card + .card { margin-top: 16px; }
.card-title { display: flex; align-items: center; gap: 10px; margin: 0 0 14px; font-size: 15.5px; font-weight: 650; }
.card-title .num { width: 22px; height: 22px; border-radius: 7px; font-size: 12px; display: grid; place-items: center; background: var(--grad-soft); color: var(--a1); border: 1px solid var(--border); }
.card-title small { font-weight: 400; color: var(--muted); font-size: 12.5px; margin-left: auto; }
.section-label { font-size: 13px; color: var(--muted); margin: 18px 0 10px; display: flex; align-items: center; gap: 8px; }
.section-label::after { content: ""; flex: 1; height: 1px; background: var(--border); }

/* ===== 上传区 ===== */
.dropzone {
  display: block; position: relative; border: 1.5px dashed var(--border-strong); border-radius: 14px; padding: 34px 18px; text-align: center;
  background: var(--grad-soft); background-blend-mode: normal; cursor: pointer; transition: border-color .2s, box-shadow .2s, transform .2s;
}
.dropzone:hover, .dropzone.drag { border-color: var(--a1); box-shadow: var(--glow); }
.dropzone.drag { transform: scale(1.005); }
.dz-icon {
  width: 56px; height: 56px; margin: 0 auto 12px; border-radius: 16px; display: grid; place-items: center; color: #fff;
  background: var(--grad); box-shadow: 0 10px 28px -10px rgba(215,182,125, .9);
}
.dz-title { font-weight: 600; font-size: 15.5px; }
.dz-sub { color: var(--muted); font-size: 13px; margin-top: 4px; }
.dropzone input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; }

/* ===== 选项网格（模板卡片） ===== */
.opt-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 12px; }
.opt-grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.opt-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.opt-grid.cols-4 { grid-template-columns: repeat(4, 1fr); }
.opt {
  position: relative; text-align: left; padding: 14px; border-radius: 14px; background: var(--card); border: 1px solid var(--border);
  transition: border-color .2s, background .2s, box-shadow .2s, transform .15s; display: flex; flex-direction: column; gap: 4px; min-width: 0;
}
.opt:hover { border-color: var(--border-strong); background: var(--card-strong); }
.opt:active { transform: scale(.99); }
.opt .opt-ico { width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center; margin-bottom: 6px; background: var(--grad-soft); color: var(--a1); border: 1px solid var(--border); }
.opt .opt-t { font-weight: 600; font-size: 14px; }
.opt .opt-d { font-size: 12px; color: var(--muted); line-height: 1.45; }
.opt .opt-tag { position: absolute; top: 10px; right: 10px; font-size: 11px; padding: 1px 7px; border-radius: 999px; background: var(--card-strong); color: var(--muted); border: 1px solid var(--border); }
.opt.selected {
  background: linear-gradient(var(--card-solid), var(--card-solid)) padding-box, var(--grad) border-box;
  border: 1px solid transparent; box-shadow: 0 8px 26px -12px rgba(215,182,125, .75);
}
[data-theme="dark"] .opt.selected { background: linear-gradient(#312716, #312716) padding-box, var(--grad) border-box; }
.opt.selected .opt-ico { background: var(--grad); color: #fff; border-color: transparent; }
.opt.selected::after {
  content: ""; position: absolute; top: 12px; right: 12px; width: 18px; height: 18px; border-radius: 50%; background: var(--grad);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a10 10 0 100 20 10 10 0 000-20zm-1.2 14.2l-4-4 1.4-1.4 2.6 2.6 5.6-5.6 1.4 1.4-7 7z'/%3E%3C/svg%3E") center/contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a10 10 0 100 20 10 10 0 000-20zm-1.2 14.2l-4-4 1.4-1.4 2.6 2.6 5.6-5.6 1.4 1.4-7 7z'/%3E%3C/svg%3E") center/contain no-repeat;
}
.opt.selected .opt-tag { display: none; }
.opt:disabled { opacity: .45; cursor: not-allowed; }

/* 小型分段选择 */
.seg { display: inline-flex; flex-wrap: wrap; gap: 6px; padding: 4px; border-radius: 12px; background: var(--input); border: 1px solid var(--border); }
.seg button { border: 0; background: none; padding: 6px 14px; border-radius: 9px; font-size: 13.5px; color: var(--text-2); transition: all .15s; }
.seg button:hover { color: var(--text); }
.seg button.on { background: var(--grad); color: #fff; box-shadow: 0 4px 14px -6px rgba(215,182,125, .8); }

/* 开关 */
.toggles { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; }
.toggle { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; background: var(--card); border: 1px solid var(--border); cursor: pointer; }
.toggle .t-main { flex: 1; min-width: 0; }
.toggle .t-t { font-size: 14px; font-weight: 550; }
.toggle .t-d { font-size: 12px; color: var(--muted); }
.switch { position: relative; width: 42px; height: 24px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.switch span { position: absolute; inset: 0; border-radius: 999px; background: var(--border-strong); transition: .2s; }
.switch span::before { content: ""; position: absolute; width: 18px; height: 18px; left: 3px; top: 3px; border-radius: 50%; background: #fff; transition: .2s; box-shadow: 0 1px 3px rgba(0,0,0,.3); }
.switch input:checked + span { background: var(--grad); }
.switch input:checked + span::before { transform: translateX(18px); }

/* 表单控件 */
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field label, .field .lbl { font-size: 12.5px; color: var(--muted); }
.input, select.input, textarea.input {
  width: 100%; padding: 10px 12px; border-radius: 11px; background: var(--input); border: 1px solid var(--border); outline: none;
  transition: border-color .2s, box-shadow .2s;
}
.input:focus { border-color: var(--a1); box-shadow: 0 0 0 3px rgba(213,179,121, .18); }
select.input { appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%237d869c' stroke-width='2.5'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 32px; }
input[type=range] { -webkit-appearance: none; appearance: none; width: 100%; height: 6px; border-radius: 6px; background: var(--border-strong); outline: none; }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 18px; height: 18px; border-radius: 50%; background: #fff; border: 4px solid var(--a2); box-shadow: 0 2px 8px rgba(215,182,125,.5); }
input[type=range]::-moz-range-thumb { width: 12px; height: 12px; border-radius: 50%; background: #fff; border: 4px solid var(--a2); }
input[type=color] { -webkit-appearance: none; border: 1px solid var(--border); width: 42px; height: 38px; border-radius: 10px; padding: 3px; background: var(--input); }
input[type=color]::-webkit-color-swatch-wrapper { padding: 0; }
input[type=color]::-webkit-color-swatch { border: 0; border-radius: 7px; }

/* 按钮 */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 44px; padding: 0 20px; border-radius: 12px;
  border: 1px solid var(--border); background: var(--card); color: var(--text); font-weight: 600; font-size: 14.5px; white-space: nowrap;
  transition: transform .15s, box-shadow .2s, background .2s, border-color .2s, opacity .2s;
}
.btn:hover { border-color: var(--border-strong); background: var(--card-strong); }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--grad); color: #fff; border-color: transparent; box-shadow: 0 10px 28px -12px rgba(215,182,125, .95); }
.btn.primary:hover { box-shadow: 0 12px 32px -10px rgba(215,182,125, 1); filter: brightness(1.06); }
.btn.sm { height: 36px; padding: 0 14px; font-size: 13.5px; border-radius: 10px; }
.btn.danger:hover { color: var(--err); border-color: rgba(248, 113, 113, .5); }
.btn:disabled { opacity: .45; cursor: not-allowed; transform: none; box-shadow: none; }
.actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-top: 20px; }
.actions.end { justify-content: flex-end; }

/* 进度 */
.progress { height: 10px; border-radius: 999px; background: var(--input); border: 1px solid var(--border); overflow: hidden; }
.progress > div {
  height: 100%; width: 0; border-radius: 999px; background: var(--grad); transition: width .4s ease; position: relative; overflow: hidden;
}
.progress > div::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .35), transparent);
  transform: translateX(-100%); animation: shimmer 1.6s infinite;
}
@keyframes shimmer { to { transform: translateX(100%); } }
.proc-wrap { text-align: center; padding: 18px 0 8px; }
.orb {
  width: 84px; height: 84px; margin: 0 auto 16px; border-radius: 50%; position: relative; display: grid; place-items: center; color: #fff;
  background: var(--grad); box-shadow: 0 0 0 10px rgba(215,182,125, .10), 0 0 0 22px rgba(215,182,125, .05), 0 16px 40px -10px rgba(215,182,125, .9);
  animation: breathe 2.4s ease-in-out infinite;
}
@keyframes breathe { 50% { box-shadow: 0 0 0 14px rgba(215,182,125, .12), 0 0 0 30px rgba(215,182,125, .04), 0 16px 40px -10px rgba(215,182,125, .9); } }
.proc-stage { font-weight: 650; font-size: 17px; }
.proc-meta { color: var(--muted); font-size: 13px; margin: 4px 0 16px; display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.pct { font-variant-numeric: tabular-nums; }

/* 文件条 */
.file-pill { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; background: var(--card); border: 1px solid var(--border); }
.file-pill .fp-ico { width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center; background: var(--grad); color: #fff; }
.file-pill .fp-main { flex: 1; min-width: 0; }
.file-pill .fp-name { font-weight: 600; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.file-pill .fp-sub { font-size: 12px; color: var(--muted); }

/* 统计 */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; }
.stat { padding: 12px 14px; border-radius: 14px; background: var(--card); border: 1px solid var(--border); }
.stat .s-v { font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; }
.stat .s-l { font-size: 12px; color: var(--muted); }

/* 提示 */
.toast-wrap { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 100; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; width: calc(100% - 32px); max-width: 420px; }
.toast {
  padding: 10px 16px; border-radius: 12px; font-size: 14px; background: var(--panel-bg);
  border: 1px solid var(--border-strong); box-shadow: var(--shadow); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  animation: pop .2s ease-out; pointer-events: auto; display: flex; gap: 8px; align-items: center;
}
.toast.err { border-color: rgba(248, 113, 113, .5); }
.toast.ok { border-color: rgba(52, 211, 153, .45); }
.notice { padding: 10px 14px; border-radius: 12px; font-size: 13px; background: var(--grad-soft); border: 1px solid var(--border); color: var(--text-2); display: flex; gap: 8px; align-items: flex-start; }
.notice.err { background: rgba(248, 113, 113, .08); border-color: rgba(248, 113, 113, .35); color: var(--err); }

/* 弹窗 */
.modal-back { position: fixed; inset: 0; z-index: 90; background: rgba(14,11,6, .6); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); display: grid; place-items: center; padding: 20px; }
.modal { width: 100%; max-width: 380px; background: var(--card-solid); border: 1px solid var(--border-strong); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); animation: pop .2s ease-out; }
.modal h3 { margin: 0 0 6px; }

.footer { text-align: center; color: var(--muted); font-size: 12px; padding: 10px 0 30px; }

/* 进入动画 */
.fade-in { animation: fadeUp .35s ease-out; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* ===== 手机适配 ===== */
@media (max-width: 720px) {
  body { font-size: 14.5px; }
  .topbar-inner { padding: 10px 14px; }
  .brand { font-size: 15px; }
  .icon-btn .lbl { display: none; }
  .container { padding: 16px 14px 70px; }
  .hero { padding: 8px 0 18px; }
  .hero p { font-size: 13.5px; }
  .card { padding: 16px; border-radius: 15px; }
  .stepper { margin-bottom: 16px; }
  .step { font-size: 13px; gap: 6px; }
  .step-dot { width: 26px; height: 26px; font-size: 12px; }
  .step-line { margin: 0 8px; min-width: 14px; }
  .opt-grid, .opt-grid.cols-3, .opt-grid.cols-4 { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .opt { padding: 12px; }
  .opt .opt-d { font-size: 11.5px; }
  .history-panel { position: fixed; left: 10px; right: 10px; top: 62px; width: auto; max-height: 72vh; }
  .actions .btn { flex: 1; }
  .dropzone { padding: 26px 14px; }
  .toggles { grid-template-columns: 1fr; }
}
@media (max-width: 380px) {
  .step span.step-label { display: none; }
  .step.active span.step-label { display: inline; }
}
