/* 帐篷尺寸与人数匹配计算器 · 重做版
   主题：橙绿（#c2410c / #65a30d）
   骨架：12 栏 bento 卡片流 + 九档目录卡
   前缀：tp-
*/
:root {
  --tp-a: #c2410c;
  --tp-a2: #65a30d;
  --tp-a-soft: #ffedd5;
  --tp-a2-soft: #ecfccb;
  --tp-bg: #f8f5ee;
  --tp-card: #ffffff;
  --tp-card2: #fdfbf5;
  --tp-txt: #241c12;
  --tp-txt2: #675846;
  --tp-txt3: #9a8871;
  --tp-line: #e6dbc7;
  --tp-line2: #f2ebdd;
  --tp-ok: #3f6212;
  --tp-warn: #b45309;
  --tp-bad: #b91c1c;
  --tp-shadow: 0 1px 2px rgba(90, 62, 18, .05), 0 12px 28px -18px rgba(90, 62, 18, .35);
  --tp-r: 14px;
  --tp-r2: 10px;
}

[data-theme='dark'] .tp {
  --tp-a: #fb923c;
  --tp-a2: #a3e635;
  --tp-a-soft: #38220f;
  --tp-a2-soft: #24310f;
  --tp-bg: #14120d;
  --tp-card: #1f1b14;
  --tp-card2: #191610;
  --tp-txt: #f4ebdd;
  --tp-txt2: #c5b5a0;
  --tp-txt3: #94836c;
  --tp-line: #3a3225;
  --tp-line2: #2a241a;
  --tp-ok: #bef264;
  --tp-warn: #fbbf24;
  --tp-bad: #f87171;
  --tp-shadow: 0 1px 2px rgba(0, 0, 0, .45), 0 12px 28px -18px rgba(0, 0, 0, .7);
}

.tp { background: var(--tp-bg); color: var(--tp-txt); padding: 26px 0 46px; }
.tp-inner { width: min(1140px, calc(100% - 44px)); max-width: none; margin: 0 auto; }
.tp * { box-sizing: border-box; }

/* ---------- Hero ---------- */
.tp-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr);
  gap: 24px;
  align-items: stretch;
  padding: 28px 28px 26px;
  border-radius: 22px;
  border: 1px solid var(--tp-line);
  background:
    radial-gradient(700px 260px at 8% 0%, rgba(194, 65, 12, .14), transparent 62%),
    linear-gradient(140deg, var(--tp-card) 0%, var(--tp-card2) 100%);
  box-shadow: var(--tp-shadow);
}
.tp-kicker {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12.5px; font-weight: 700; letter-spacing: .3px;
  color: var(--tp-a);
  background: var(--tp-a-soft);
  border: 1px solid color-mix(in srgb, var(--tp-a) 24%, transparent);
  padding: 5px 11px; border-radius: 999px;
}
.tp-hero h1 {
  margin: 14px 0 0;
  font-size: clamp(26px, 3.3vw, 39px);
  line-height: 1.24; letter-spacing: -.7px; font-weight: 800;
}
.tp-hero h1 em {
  font-style: normal; display: inline-block; margin-top: 4px;
  color: var(--tp-a);
  background: linear-gradient(180deg, transparent 64%, rgba(101, 163, 13, .3) 64%);
  padding: 0 2px;
}
.tp-sub { margin: 12px 0 0; font-size: 14.5px; line-height: 1.85; color: var(--tp-txt2); max-width: 66ch; }
.tp-sub b { color: var(--tp-txt); font-weight: 700; }
.tp-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 15px; }
.tp-tag {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 12.5px; padding: 5px 10px; border-radius: 8px;
  background: var(--tp-card2); border: 1px solid var(--tp-line); color: var(--tp-txt2);
}
.tp-tag i { color: var(--tp-a2); font-style: normal; font-weight: 800; }
.tp-hero-preset { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.tp-preset {
  border: 1px dashed color-mix(in srgb, var(--tp-a) 40%, var(--tp-line));
  background: transparent; color: var(--tp-a); cursor: pointer;
  font-size: 12.5px; font-weight: 600; padding: 7px 12px; border-radius: 9px;
  transition: background .18s, transform .12s;
}
.tp-preset:hover { background: var(--tp-a-soft); transform: translateY(-1px); }

/* 纯 CSS 帐篷 + 星空 */
.tp-hero-art { position: relative; min-height: 238px; }
.tp-sky {
  position: absolute; inset: 0; border-radius: 18px; overflow: hidden;
  background:
    radial-gradient(420px 200px at 78% 12%, rgba(251, 191, 36, .18), transparent 70%),
    linear-gradient(175deg, #1b2b22 0%, #122019 52%, #0c1712 100%);
  border: 1px solid rgba(255, 255, 255, .08);
}
.tp-moon {
  position: absolute; right: 34px; top: 26px; width: 42px; height: 42px; border-radius: 50%;
  background: radial-gradient(circle at 34% 32%, #fef3c7, #fbbf24 62%, #d97706);
  box-shadow: 0 0 28px rgba(251, 191, 36, .55), 0 0 70px rgba(251, 191, 36, .25);
}
.tp-star {
  position: absolute; width: 4px; height: 4px; border-radius: 50%;
  background: #e0f2fe; opacity: .75;
  animation: tpTwinkle 3.4s ease-in-out infinite;
}
.tp-star.s1 { left: 10%; top: 14%; }
.tp-star.s2 { left: 22%; top: 30%; width: 3px; height: 3px; animation-delay: .5s; }
.tp-star.s3 { left: 36%; top: 10%; animation-delay: 1.1s; }
.tp-star.s4 { left: 52%; top: 24%; width: 3px; height: 3px; animation-delay: 1.7s; }
.tp-star.s5 { left: 66%; top: 8%; animation-delay: .9s; }
.tp-star.s6 { left: 88%; top: 34%; width: 3px; height: 3px; animation-delay: 2.1s; }
.tp-star.s7 { left: 14%; top: 44%; width: 2px; height: 2px; animation-delay: 1.4s; }
.tp-star.s8 { left: 78%; top: 20%; width: 2px; height: 2px; animation-delay: 2.6s; }
@keyframes tpTwinkle { 0%, 100% { opacity: .35; transform: scale(.8); } 50% { opacity: 1; transform: scale(1.15); } }

.tp-tent { position: absolute; left: 50%; bottom: 30px; transform: translateX(-50%); width: 220px; height: 132px; }
.tp-tent-shape {
  position: absolute; inset: 0;
  clip-path: polygon(50% 0, 100% 88%, 100% 100%, 0 100%, 0 88%);
  background:
    linear-gradient(150deg, rgba(255, 255, 255, .22), transparent 42%),
    linear-gradient(180deg, #ea7a35 0%, #c2410c 58%, #8a2c08 100%);
  box-shadow: inset 0 -14px 26px -16px rgba(0, 0, 0, .6);
}
.tp-tent-door {
  position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%);
  width: 62px; height: 66px;
  clip-path: polygon(50% 0, 100% 100%, 0 100%);
  background: linear-gradient(180deg, #2a1a0d, #4a2c12);
  box-shadow: inset 0 0 14px rgba(251, 191, 36, .35);
}
.tp-tent-ridge {
  position: absolute; left: 50%; top: 4px; transform: translateX(-50%);
  width: 2px; height: 78%; background: rgba(255, 255, 255, .35);
}
.tp-tent-window {
  position: absolute; left: 18px; bottom: 22px; width: 34px; height: 24px;
  border-radius: 4px 4px 2px 2px; background: rgba(163, 230, 53, .45);
  border: 1px solid rgba(163, 230, 53, .7);
}
.tp-tent-pole {
  position: absolute; left: 50%; top: 6px; transform: translateX(-50%);
  width: 2px; height: 120px; background: rgba(255, 255, 255, .25);
}
.tp-guy {
  position: absolute; bottom: 6px; width: 96px; height: 1px;
  background: rgba(255, 255, 255, .28); transform-origin: 0 50%;
}
.tp-guy.g1 { left: 42px; transform: rotate(24deg); }
.tp-guy.g2 { right: 42px; transform: rotate(-24deg); transform-origin: 100% 50%; }
.tp-ground {
  position: absolute; left: 0; right: 0; bottom: 0; height: 32px;
  background: linear-gradient(180deg, rgba(101, 163, 13, .22), rgba(63, 98, 18, .42));
  border-top: 1px solid rgba(163, 230, 53, .28);
}
.tp-chip {
  position: absolute; font-size: 11.5px; padding: 5px 10px; border-radius: 8px;
  background: rgba(255, 255, 255, .94); border: 1px solid rgba(0, 0, 0, .06);
  color: #4b3520; box-shadow: 0 8px 18px -12px rgba(0, 0, 0, .7); white-space: nowrap;
}
.tp-chip b { color: #c2410c; }
.tp-chip.c1 { left: 10px; top: 96px; animation: tpFloat 4.2s ease-in-out infinite; }
.tp-chip.c2 { right: 10px; top: 138px; animation: tpFloat 4.2s ease-in-out .7s infinite; }
@keyframes tpFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }

/* ---------- 12 栏卡片流 ---------- */
.tp-flow { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 16px; margin-top: 16px; align-items: start; }
.tp-span5 { grid-column: span 5; min-width: 0; }
.tp-span7 { grid-column: span 7; min-width: 0; }
.tp-span12 { grid-column: span 12; min-width: 0; }

.tp-card {
  position: relative;
  background: var(--tp-card);
  border: 1px solid var(--tp-line);
  border-radius: var(--tp-r);
  box-shadow: var(--tp-shadow);
  padding: 20px 22px 22px;
  overflow: hidden;
}
.tp-card::before {
  content: ''; position: absolute; left: 0; right: 0; top: 0; height: 3px;
  background: linear-gradient(90deg, var(--tp-a), var(--tp-a2));
  opacity: .85;
}
.tp-card-h { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.tp-card-h h2 { margin: 0; font-size: 16.5px; font-weight: 800; letter-spacing: -.2px; display: flex; align-items: center; gap: 9px; }
.tp-no {
  font-size: 11px; font-weight: 800; letter-spacing: .5px; color: #fff;
  background: var(--tp-a); padding: 3px 7px; border-radius: 6px;
}
[data-theme='dark'] .tp .tp-no { color: #1a1409; }
.tp-card-h small { font-size: 12px; color: var(--tp-txt3); }

.tp-field { margin-bottom: 16px; }
.tp-field.keep { margin-bottom: 0; }
.tp-label { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.tp-label label { font-size: 13.5px; font-weight: 600; color: var(--tp-txt); }
.tp-label label b { color: var(--tp-bad); }
.tp-hint { font-size: 11.5px; color: var(--tp-txt3); }

.tp-range-row { display: grid; grid-template-columns: 1fr 112px; gap: 14px; align-items: center; }
.tp-range-row input[type='range'] {
  -webkit-appearance: none; appearance: none; height: 6px; border-radius: 999px;
  background: linear-gradient(90deg, var(--tp-a2), var(--tp-a)); outline: none; cursor: pointer;
}
.tp-range-row input[type='range']::-webkit-slider-thumb {
  -webkit-appearance: none; width: 20px; height: 20px; border-radius: 50%;
  background: var(--tp-a); border: 3px solid var(--tp-card); box-shadow: 0 0 0 1px var(--tp-a);
  cursor: pointer;
}
.tp-range-row input[type='range']::-moz-range-thumb { width: 15px; height: 15px; border: none; border-radius: 50%; background: var(--tp-a); cursor: pointer; }

.tp-numbox { display: flex; align-items: center; border: 1px solid var(--tp-line); border-radius: var(--tp-r2); background: var(--tp-card2); overflow: hidden; }
.tp-numbox input { flex: 1; min-width: 0; border: 0; background: transparent; color: var(--tp-txt); font-size: 15px; font-weight: 700; padding: 9px 10px; outline: none; }
.tp-numbox span { padding: 0 10px; font-size: 12px; color: var(--tp-txt3); background: var(--tp-line2); align-self: stretch; display: flex; align-items: center; }
.tp-numbox.wide { width: 100%; }
.tp-err { display: none; margin-top: 6px; font-size: 12px; color: var(--tp-bad); }
.tp-err.on { display: block; }
.tp-field.bad .tp-numbox, .tp-field.bad .tp-control { border-color: var(--tp-bad); box-shadow: 0 0 0 3px color-mix(in srgb, var(--tp-bad) 14%, transparent); }

.tp-grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }

.tp-control { border: 1px solid var(--tp-line); border-radius: var(--tp-r2); background: var(--tp-card2); }
.tp-control select {
  width: 100%; border: 0; background: transparent; color: var(--tp-txt);
  font-size: 13.5px; padding: 10px 11px; outline: none; cursor: pointer; appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--tp-txt3) 50%), linear-gradient(135deg, var(--tp-txt3) 50%, transparent 50%);
  background-position: calc(100% - 16px) 50%, calc(100% - 11px) 50%;
  background-size: 5px 5px, 5px 5px; background-repeat: no-repeat;
}

.tp-seg { display: flex; gap: 6px; flex-wrap: wrap; background: var(--tp-line2); padding: 4px; border-radius: var(--tp-r2); }
.tp-segbtn {
  flex: 1 1 auto; min-width: 108px; border: 0; background: transparent; color: var(--tp-txt2);
  font-size: 12.5px; font-weight: 600; padding: 9px 10px; border-radius: 8px; cursor: pointer;
  transition: background .18s, color .18s, box-shadow .18s; text-align: left;
}
.tp-segbtn.on { background: var(--tp-card); color: var(--tp-a); box-shadow: 0 1px 3px rgba(0, 0, 0, .12); }
.tp-segbtn:hover { color: var(--tp-a); }

.tp-quick { display: flex; flex-wrap: wrap; gap: 8px; }
.tp-quickbtn {
  border: 1px solid var(--tp-line); background: var(--tp-card2); color: var(--tp-txt2);
  font-size: 12.5px; font-weight: 600; padding: 8px 12px; border-radius: 9px; cursor: pointer;
  transition: border-color .18s, color .18s, background .18s;
}
.tp-quickbtn:hover { border-color: var(--tp-a2); color: var(--tp-a2); background: var(--tp-a2-soft); }

.tp-tip {
  margin: 12px 0 0; font-size: 12.5px; line-height: 1.75; color: var(--tp-txt3);
  background: var(--tp-line2); border-left: 3px solid var(--tp-a2); padding: 9px 12px; border-radius: 0 8px 8px 0;
}
.tp-tip code { font-size: 12px; background: var(--tp-card); padding: 1px 5px; border-radius: 4px; color: var(--tp-a); }

.tp-actions { display: flex; flex-wrap: wrap; gap: 9px; }
.tp-actions.tight { margin-top: 12px; }
.tp-btn {
  border: 1px solid var(--tp-line); background: var(--tp-card); color: var(--tp-txt);
  font-size: 13px; font-weight: 600; padding: 10px 16px; border-radius: 10px; cursor: pointer;
  transition: transform .12s, box-shadow .18s, background .18s;
}
.tp-btn:hover { transform: translateY(-1px); box-shadow: 0 7px 18px -12px rgba(0, 0, 0, .6); }
.tp-btn.primary { background: var(--tp-a); border-color: var(--tp-a); color: #fff; }
[data-theme='dark'] .tp .tp-btn.primary { color: #1a1409; }
.tp-btn.ghost { background: transparent; color: var(--tp-txt2); }
.tp-msg { margin-top: 12px; font-size: 12.5px; color: var(--tp-txt3); min-height: 18px; }

/* ---------- 结果卡 ---------- */
.tp-result {
  background: var(--tp-card); border: 1px solid var(--tp-line);
  border-radius: var(--tp-r); box-shadow: var(--tp-shadow); overflow: hidden;
  align-self: start;
}
.tp-result-h { display: flex; align-items: center; justify-content: space-between; padding: 15px 20px; border-bottom: 1px solid var(--tp-line2); }
.tp-result-h h2 { margin: 0; font-size: 15px; font-weight: 800; }
.tp-badge { font-size: 11.5px; font-weight: 700; padding: 4px 10px; border-radius: 999px; background: var(--tp-line2); color: var(--tp-txt3); }
.tp-badge.ok { background: color-mix(in srgb, var(--tp-ok) 15%, transparent); color: var(--tp-ok); }
.tp-badge.warn { background: color-mix(in srgb, var(--tp-warn) 16%, transparent); color: var(--tp-warn); }
.tp-badge.bad { background: color-mix(in srgb, var(--tp-bad) 14%, transparent); color: var(--tp-bad); }

.tp-verdict { padding: 18px 20px 14px; text-align: center; background: linear-gradient(180deg, var(--tp-a-soft), transparent 92%); }
.tp-verdict-label { display: block; font-size: 12px; color: var(--tp-txt3); letter-spacing: .4px; }
.tp-verdict-num { display: inline-block; font-size: 40px; line-height: 1.06; font-weight: 800; color: var(--tp-a); letter-spacing: -1.4px; margin-top: 3px; }
.tp-verdict-sub { margin: 6px 0 0; font-size: 12.5px; color: var(--tp-txt2); }

.tp-kpis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; background: var(--tp-line2); }
.tp-kpi { background: var(--tp-card); padding: 12px 15px; }
.tp-kpi span { display: block; font-size: 11.5px; color: var(--tp-txt3); }
.tp-kpi b { display: inline-block; font-size: 18px; font-weight: 800; color: var(--tp-txt); margin-top: 2px; letter-spacing: -.4px; }
.tp-kpi small { font-size: 11px; color: var(--tp-txt3); margin-left: 3px; }

.tp-ruler { padding: 18px 20px 10px; }
.tp-ruler-track { position: relative; height: 12px; border-radius: 999px; background: var(--tp-line2); }
.tp-ruler-band {
  position: absolute; left: 25%; width: 50%; top: 0; bottom: 0; border-radius: 999px;
  background: linear-gradient(90deg, rgba(101, 163, 13, .32), rgba(101, 163, 13, .62));
  border: 1px solid rgba(101, 163, 13, .5);
}
.tp-ruler-tick { position: absolute; top: -5px; width: 2px; height: 22px; background: var(--tp-line); }
.tp-ruler-tick.t1 { left: 25%; }
.tp-ruler-tick.t2 { left: 75%; }
.tp-ruler-marker {
  position: absolute; top: -9px; width: 3px; height: 30px; border-radius: 2px;
  background: var(--tp-a); left: 0; transition: left .45s ease;
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--tp-a) 22%, transparent);
}
.tp-ruler-marker i {
  position: absolute; top: -22px; left: 50%; transform: translateX(-50%);
  font-style: normal; font-size: 11px; font-weight: 800; color: var(--tp-a);
  background: var(--tp-card); padding: 1px 5px; border-radius: 5px; white-space: nowrap;
}
.tp-ruler-scale { display: flex; justify-content: space-between; margin-top: 14px; font-size: 10.5px; color: var(--tp-txt3); gap: 6px; }
.tp-ruler-note { margin: 8px 0 0; font-size: 12px; line-height: 1.7; color: var(--tp-txt3); }

.tp-advice { padding: 4px 20px 16px; }
.tp-advice h3 { margin: 0 0 8px; font-size: 13px; font-weight: 700; }
.tp-advice ul { margin: 0; padding-left: 18px; }
.tp-advice li { font-size: 12.5px; line-height: 1.78; color: var(--tp-txt2); margin-bottom: 5px; }
.tp-risk {
  margin: 0 16px 16px; padding: 10px 12px; border-radius: 10px;
  background: color-mix(in srgb, var(--tp-warn) 11%, transparent);
  border: 1px solid color-mix(in srgb, var(--tp-warn) 34%, transparent);
  font-size: 12.5px; line-height: 1.7; color: var(--tp-txt2);
}
.tp-risk strong { color: var(--tp-warn); margin-right: 6px; }

/* ---------- 三档方案 ---------- */
.tp-plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.tp-plan {
  border: 1.5px solid var(--tp-line); border-radius: 12px; background: var(--tp-card2);
  padding: 16px 16px 14px; position: relative; transition: border-color .2s, transform .2s, box-shadow .2s;
}
.tp-plan:hover { transform: translateY(-2px); }
.tp-plan.rec { border-color: var(--tp-a); background: var(--tp-card); box-shadow: 0 0 0 3px color-mix(in srgb, var(--tp-a) 15%, transparent); }
.tp-plan-tag {
  position: absolute; right: 12px; top: -10px; font-size: 10.5px; font-weight: 800;
  color: #fff; background: var(--tp-a); padding: 3px 9px; border-radius: 999px;
}
[data-theme='dark'] .tp .tp-plan-tag { color: #1a1409; }
.tp-plan h3 { margin: 0; font-size: 17px; font-weight: 800; letter-spacing: -.2px; }
.tp-plan h3 span { display: block; margin-top: 2px; font-size: 11.5px; color: var(--tp-txt3); font-weight: 500; }
.tp-plan .tp-plan-area { margin: 10px 0 12px; font-size: 12px; color: var(--tp-txt3); }
.tp-plan .tp-plan-area b { color: var(--tp-a2); font-size: 20px; letter-spacing: -.5px; }
.tp-plan dl { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 6px 10px; font-size: 12.5px; }
.tp-plan dt { color: var(--tp-txt3); }
.tp-plan dd { margin: 0; text-align: right; font-weight: 600; color: var(--tp-txt); }
.tp-plan-pros { margin: 11px 0 0; font-size: 12px; line-height: 1.7; color: var(--tp-txt2); }
.tp-plan-pros em { font-style: normal; color: var(--tp-ok); font-weight: 700; }
.tp-plan-pros s { text-decoration: none; color: var(--tp-warn); font-weight: 700; }
.tp-plan-pick {
  margin-top: 12px; width: 100%; border: 1px solid var(--tp-line); border-radius: 9px;
  padding: 8px; font-size: 12.5px; font-weight: 700; cursor: pointer;
  background: var(--tp-line2); color: var(--tp-txt2); transition: background .18s, color .18s;
}
.tp-plan.rec .tp-plan-pick { background: var(--tp-a); border-color: var(--tp-a); color: #fff; }
[data-theme='dark'] .tp .tp-plan.rec .tp-plan-pick { color: #1a1409; }

/* ---------- 九档目录 ---------- */
.tp-catalog { display: grid; grid-template-columns: repeat(auto-fill, minmax(196px, 1fr)); gap: 11px; }
.tp-cat {
  border: 1.5px solid var(--tp-line); border-radius: 11px; background: var(--tp-card2);
  padding: 13px 13px 11px; cursor: pointer; text-align: left;
  transition: border-color .18s, transform .15s, box-shadow .18s;
  font-family: inherit; color: inherit;
}
.tp-cat:hover { transform: translateY(-2px); border-color: var(--tp-a2); }
.tp-cat.rec { border-color: var(--tp-a); background: var(--tp-card); box-shadow: 0 0 0 3px color-mix(in srgb, var(--tp-a) 14%, transparent); }
.tp-cat.sel { border-color: var(--tp-a2); box-shadow: 0 0 0 3px color-mix(in srgb, var(--tp-a2) 18%, transparent); }
.tp-cat-top { display: flex; align-items: baseline; justify-content: space-between; gap: 6px; }
.tp-cat-top b { font-size: 15px; font-weight: 800; letter-spacing: -.2px; }
.tp-cat-top em { font-style: normal; font-size: 10.5px; font-weight: 700; padding: 2px 6px; border-radius: 5px; background: var(--tp-a2-soft); color: var(--tp-ok); }
.tp-cat.rec .tp-cat-top em { background: var(--tp-a-soft); color: var(--tp-a); }
.tp-cat-area { margin: 7px 0 2px; font-size: 11.5px; color: var(--tp-txt3); }
.tp-cat-area b { font-size: 22px; font-weight: 800; color: var(--tp-a); letter-spacing: -.8px; }
.tp-cat-area span { margin-left: 2px; }
.tp-cat-dim { font-size: 11.5px; color: var(--tp-txt2); }
.tp-cat-meta { margin-top: 8px; display: flex; justify-content: space-between; font-size: 11px; color: var(--tp-txt3); border-top: 1px dashed var(--tp-line); padding-top: 7px; }
.tp-cat-meta b { color: var(--tp-txt2); font-weight: 600; }

/* ---------- 表格 / 步骤 / 批量 / 历史 ---------- */
.tp-table-wrap { overflow-x: auto; border: 1px solid var(--tp-line); border-radius: 11px; }
.tp-table { width: 100%; border-collapse: collapse; font-size: 13px; min-width: 600px; }
.tp-table th, .tp-table td { padding: 10px 13px; text-align: left; border-bottom: 1px solid var(--tp-line2); }
.tp-table th { background: var(--tp-line2); font-size: 12px; color: var(--tp-txt2); font-weight: 700; }
.tp-table td:last-child { color: var(--tp-txt3); font-size: 12px; }
.tp-table td b { color: var(--tp-a); }
.tp-table tr:last-child td { border-bottom: 0; }

.tp-steps { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 10px; }
.tp-steps li { display: grid; grid-template-columns: 26px 1fr; gap: 12px; align-items: start; font-size: 13px; line-height: 1.8; color: var(--tp-txt2); }
.tp-steps li b {
  width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  background: var(--tp-a2-soft); color: var(--tp-ok); font-size: 12px; font-weight: 800;
}
.tp-steps li b em { font-style: normal; }
.tp-steps li strong { color: var(--tp-txt); font-weight: 700; }
.tp-steps li code {
  display: block; margin-top: 3px; font-size: 12px; color: var(--tp-a);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  background: var(--tp-line2); padding: 4px 8px; border-radius: 6px; width: fit-content; max-width: 100%;
}

.tp-textarea {
  width: 100%; min-height: 118px; resize: vertical;
  border: 1px solid var(--tp-line); border-radius: 11px; background: var(--tp-card2);
  color: var(--tp-txt); font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12.5px; line-height: 1.7; padding: 12px; outline: none;
}
.tp-textarea:focus { border-color: var(--tp-a2); }

.tp-history { display: flex; flex-direction: column; gap: 8px; }
.tp-hist-item {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  border: 1px solid var(--tp-line); border-radius: 10px; padding: 10px 12px;
  background: var(--tp-card2); font-size: 12.5px; color: var(--tp-txt2);
}
.tp-hist-item button {
  border: 0; background: var(--tp-a2-soft); color: var(--tp-ok); font-size: 12px;
  font-weight: 700; padding: 5px 10px; border-radius: 7px; cursor: pointer; flex: none;
}
.tp-empty { font-size: 12.5px; color: var(--tp-txt3); margin: 0; }

/* ---------- 响应式 ---------- */
@media (max-width: 1024px) {
  .tp-hero { grid-template-columns: 1fr; padding: 22px 20px; }
  .tp-hero-art { display: none; }
  .tp-span5, .tp-span7 { grid-column: span 12; }
  .tp-plans { grid-template-columns: 1fr; }
}
@media (max-width: 700px) {
  .tp-inner { width: calc(100% - 28px); }
  .tp-hero { border-radius: 16px; }
  .tp-card { padding: 16px 16px 18px; }
  .tp-grid2 { grid-template-columns: 1fr; }
  .tp-range-row { grid-template-columns: 1fr; }
  .tp-kpis { grid-template-columns: 1fr 1fr; }
  .tp-catalog { grid-template-columns: 1fr 1fr; }
  .tp-actions .tp-btn { flex: 1 1 44%; }
  .tp-verdict-num { font-size: 34px; }
  .tp-ruler-scale { font-size: 9.5px; }
}

/* ---------- 打印 ---------- */
@media print {
  .tp-actions, .tp-textarea, .tp-history, .tp-hero-preset, .tp-msg, .tsk-crumb-bar { display: none !important; }
  .tp { padding: 0; background: #fff; }
  .tp-card, .tp-result { box-shadow: none; border-color: #ddd; break-inside: avoid; }
  .tp-hero { box-shadow: none; border-color: #ddd; }
  .tp-flow { display: block; }
  .tp-card { margin-bottom: 10px; }
}

/* ---------- 全局对齐：面包屑与内容同宽 ---------- */
.tsk-crumb-bar-in {
  width: min(1140px, calc(100% - 44px)) !important;
  max-width: none !important;
  margin: 0 auto !important;
  padding: 11px 0 !important;
}
.tsk-crumb { font-size: 13px; }
@media (max-width: 700px) {
  .tsk-crumb-bar-in { width: calc(100% - 28px) !important; padding: 9px 0 !important; }
}
