/* renovation.css — 星网数科 3D 室内装修与房屋改造工作室
   暗曜石玻璃主题 · 香槟金 / 翡翠青强调 · 1440×900 零重叠工作台。
   层级：canvas(0) < 覆盖层(2) < 坞/HUD(10) < boot(50) < toast/modal(80)。 */

:root {
  color-scheme: dark;
  --rv-bg: #090c12;
  --rv-bg-2: #0d1119;
  --rv-panel: rgba(20, 26, 37, .72);
  --rv-panel-solid: #121926;
  --rv-glass: rgba(16, 22, 32, .78);
  --rv-line: rgba(148, 163, 184, .14);
  --rv-line-strong: rgba(148, 163, 184, .26);
  --rv-text: #e8edf5;
  --rv-dim: rgba(232, 237, 245, .62);
  --rv-faint: rgba(232, 237, 245, .34);
  --rv-gold: #f59e0b;
  --rv-gold-2: #ffb347;
  --rv-teal: #2dd4bf;
  --rv-teal-2: #34d399;
  --rv-danger: #f87171;
  --rv-radius: 14px;
  --rv-mono: 'JetBrains Mono Variable', ui-monospace, SFMono-Regular, Menlo, monospace;
  --rv-font: 'Inter Variable', 'Noto Sans SC Variable', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html, body { height: 100%; margin: 0; }

body {
  font-family: var(--rv-font);
  background: var(--rv-bg);
  color: var(--rv-text);
  font-size: 13px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}

button, input, textarea { font-family: inherit; }
button { cursor: pointer; color: inherit; }
a { color: inherit; text-decoration: none; }
button:focus-visible, a:focus-visible, input:focus-visible { outline: 2px solid var(--rv-gold); outline-offset: 2px; }
[hidden] { display: none !important; }

.rv-app {
  display: flex;
  flex-direction: column;
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
  background:
    radial-gradient(1200px 600px at 70% -10%, rgba(45, 212, 191, .06), transparent 60%),
    radial-gradient(900px 500px at 10% 110%, rgba(245, 158, 11, .05), transparent 60%),
    var(--rv-bg);
}

/* ─────────── 顶部栏 56px ─────────── */
.rv-topbar {
  flex: 0 0 56px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: 16px;
  height: 56px;
  padding: 0 18px;
  border-bottom: 1px solid var(--rv-line);
  background: rgba(9, 12, 18, .86);
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  z-index: 20;
}

.rv-brand-cluster { display: flex; align-items: center; gap: 20px; min-width: 0; }
.rv-brand { display: flex; align-items: center; gap: 9px; flex: 0 0 auto; }
.rv-brand-glyph {
  display: grid; place-items: center;
  width: 30px; height: 30px; border-radius: 9px;
  background: linear-gradient(135deg, var(--rv-gold), var(--rv-gold-2));
  color: #0b0e14; font-size: 16px; font-weight: 800;
  box-shadow: 0 4px 16px rgba(245, 158, 11, .28);
}
.rv-brand-text { display: flex; flex-direction: column; line-height: 1.15; white-space: nowrap; }
.rv-brand-text b { font-size: 13px; letter-spacing: .04em; }
.rv-brand-text small { font-family: var(--rv-mono); font-size: 8px; letter-spacing: .18em; color: var(--rv-gold-2); }

.rv-quicknav { display: flex; align-items: center; gap: 15px; min-width: 0; overflow: hidden; }
.rv-quicknav a {
  font-size: 11.5px; color: var(--rv-dim); white-space: nowrap;
  transition: color .18s ease; position: relative;
}
.rv-quicknav a:hover { color: var(--rv-gold-2); }
.rv-quicknav a:hover::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: -6px;
  height: 1px; background: var(--rv-gold); opacity: .7;
}

.rv-mode-tabs {
  display: flex; align-items: center; gap: 3px;
  padding: 4px; border-radius: 11px;
  background: rgba(255, 255, 255, .04);
  border: 1px solid var(--rv-line);
  justify-self: center;
}
.rv-mode-tab {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 12px; border: 0; border-radius: 8px;
  background: transparent; color: var(--rv-dim);
  font-size: 11.5px; font-weight: 600; white-space: nowrap;
  transition: background .18s ease, color .18s ease, box-shadow .18s ease;
}
.rv-mode-tab .rv-tab-ico { font-size: 13px; color: var(--rv-faint); }
.rv-mode-tab small {
  font-family: var(--rv-mono); font-size: 9px; padding: 1px 4px;
  border-radius: 4px; background: rgba(245, 158, 11, .14); color: var(--rv-gold-2);
}
.rv-mode-tab:hover { color: var(--rv-text); background: rgba(255, 255, 255, .05); }
.rv-mode-tab.is-active {
  color: #12161f;
  background: linear-gradient(135deg, var(--rv-gold-2), var(--rv-gold));
  box-shadow: 0 3px 14px rgba(245, 158, 11, .24);
}
.rv-mode-tab.is-active .rv-tab-ico { color: #12161f; }
.rv-mode-tab.is-active small { background: rgba(0, 0, 0, .16); color: #12161f; }

.rv-topbar-actions { display: flex; align-items: center; justify-content: flex-end; gap: 8px; min-width: 0; }
.rv-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 7px 13px; border-radius: 9px; border: 1px solid var(--rv-line-strong);
  background: rgba(255, 255, 255, .04); color: var(--rv-text);
  font-size: 11.5px; font-weight: 600; white-space: nowrap;
  transition: transform .15s ease, background .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.rv-btn:hover { transform: translateY(-1px); background: rgba(255, 255, 255, .08); }
.rv-btn:active { transform: translateY(0); }
.rv-btn-sm { padding: 5px 10px; font-size: 10.5px; }
.rv-btn-block { width: 100%; }
.rv-btn-gold {
  border-color: transparent;
  background: linear-gradient(135deg, var(--rv-gold-2), var(--rv-gold));
  color: #12161f;
  box-shadow: 0 4px 18px rgba(245, 158, 11, .2);
}
.rv-btn-gold:hover { box-shadow: 0 6px 22px rgba(245, 158, 11, .34); }
.rv-btn-ghost { background: rgba(255, 255, 255, .04); }
.rv-credit {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 11px; border-radius: 999px;
  border: 1px solid rgba(45, 212, 191, .36);
  background: rgba(45, 212, 191, .1);
  color: var(--rv-teal); font-size: 11px; font-weight: 700;
  font-variant-numeric: tabular-nums; white-space: nowrap;
}
.rv-credit-ico { font-size: 12px; }
.rv-credit-gift {
  border-color: rgba(245, 158, 11, .42);
  background: rgba(245, 158, 11, .12);
  color: var(--rv-gold-2);
}

/* ─────────── 工作台三栏 ─────────── */
.rv-workspace {
  flex: 1 1 auto;
  display: grid;
  grid-template-columns: 286px minmax(0, 1fr) 296px;
  min-height: 0;
  overflow: hidden;
  transition: grid-template-columns .25s ease;
}
.rv-app.rv-sidebar-collapsed .rv-workspace { grid-template-columns: 44px minmax(0, 1fr) 296px; }
.rv-app.rv-inspector-collapsed .rv-workspace { grid-template-columns: 286px minmax(0, 1fr) 44px; }
.rv-app.rv-sidebar-collapsed.rv-inspector-collapsed .rv-workspace { grid-template-columns: 44px minmax(0, 1fr) 44px; }

.rv-sidebar, .rv-inspector {
  min-height: 0; overflow: hidden;
  display: flex; flex-direction: column;
  background: var(--rv-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 8;
}
.rv-sidebar { border-right: 1px solid var(--rv-line); }
.rv-inspector { border-left: 1px solid var(--rv-line); }

.rv-sidebar-head, .rv-inspector-head {
  flex: 0 0 40px;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 12px 0 15px;
  border-bottom: 1px solid var(--rv-line);
  font-size: 11px; font-weight: 700; letter-spacing: .08em;
  color: var(--rv-dim);
}
.rv-sidebar-title { display: inline-flex; align-items: center; gap: 7px; }
.rv-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--rv-teal); box-shadow: 0 0 8px var(--rv-teal); }
.rv-icon-btn {
  width: 24px; height: 24px; display: grid; place-items: center;
  border: 1px solid var(--rv-line); border-radius: 6px;
  background: rgba(255, 255, 255, .03); color: var(--rv-dim);
  font-size: 15px; line-height: 1;
}
.rv-icon-btn:hover { color: var(--rv-text); border-color: var(--rv-line-strong); }

.rv-sidebar-body, .rv-inspector-body {
  flex: 1 1 auto; min-height: 0; overflow-y: auto; overflow-x: hidden;
  padding: 10px 12px 18px;
  scrollbar-width: thin; scrollbar-color: rgba(148, 163, 184, .3) transparent;
}
.rv-sidebar-body::-webkit-scrollbar, .rv-inspector-body::-webkit-scrollbar,
.rv-photo-scroll::-webkit-scrollbar, .rv-boq-scroll::-webkit-scrollbar { width: 6px; height: 6px; }
.rv-sidebar-body::-webkit-scrollbar-thumb, .rv-inspector-body::-webkit-scrollbar-thumb,
.rv-photo-scroll::-webkit-scrollbar-thumb, .rv-boq-scroll::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, .26); border-radius: 6px;
}

.rv-app.rv-sidebar-collapsed .rv-sidebar-body,
.rv-app.rv-inspector-collapsed .rv-inspector-body { display: none; }
.rv-app.rv-sidebar-collapsed .rv-sidebar-title,
.rv-app.rv-inspector-collapsed .rv-inspector-head > span { display: none; }
.rv-app.rv-sidebar-collapsed #rv-sidebar-toggle { transform: rotate(180deg); }
.rv-app.rv-inspector-collapsed #rv-inspector-toggle { transform: rotate(180deg); }

.rv-panel { padding: 10px 0 14px; border-bottom: 1px solid var(--rv-line); }
.rv-panel:last-child { border-bottom: 0; }
.rv-section-title {
  display: flex; align-items: baseline; justify-content: space-between;
  margin-bottom: 10px; font-size: 11.5px; font-weight: 700; color: var(--rv-text);
}
.rv-section-title small { font-family: var(--rv-mono); font-size: 8.5px; letter-spacing: .14em; color: var(--rv-faint); }

/* 空间模板 2×3 */
.rv-room-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.rv-room-card {
  position: relative; display: flex; flex-direction: column; gap: 2px;
  min-height: 62px; padding: 8px 8px 7px;
  border: 1px solid var(--rv-line); border-radius: 9px;
  background: rgba(255, 255, 255, .025); text-align: left;
  transition: border-color .18s ease, background .18s ease, transform .15s ease;
}
.rv-room-card:hover { transform: translateY(-1px); border-color: var(--rv-line-strong); background: rgba(255, 255, 255, .05); }
.rv-room-card.is-active {
  border-color: rgba(245, 158, 11, .6);
  background: linear-gradient(140deg, rgba(245, 158, 11, .16), rgba(245, 158, 11, .04));
  box-shadow: inset 0 0 0 1px rgba(245, 158, 11, .12);
}
.rv-room-glyph { font-size: 14px; line-height: 1; color: var(--rv-gold-2); }
.rv-room-name { font-size: 11.5px; font-weight: 700; margin-top: 3px; }
.rv-room-note { font-size: 9px; color: var(--rv-faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rv-room-index { position: absolute; top: 7px; right: 8px; font-family: var(--rv-mono); font-size: 8px; color: var(--rv-faint); }

/* 风格 2×4 */
.rv-style-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 5px; }
.rv-style-chip {
  display: flex; align-items: center; gap: 6px;
  padding: 6px 7px; border: 1px solid var(--rv-line); border-radius: 8px;
  background: rgba(255, 255, 255, .025); font-size: 10.5px; color: var(--rv-dim);
  transition: all .18s ease; overflow: hidden;
}
.rv-style-chip span:last-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rv-style-chip:hover { border-color: var(--rv-line-strong); color: var(--rv-text); }
.rv-style-chip.is-active {
  color: var(--rv-text); border-color: rgba(45, 212, 191, .5);
  background: rgba(45, 212, 191, .1);
}
.rv-swatch {
  flex: 0 0 12px; width: 12px; height: 12px; border-radius: 50%;
  background: var(--swatch, #d4af37);
  box-shadow: 0 0 0 2px rgba(255, 255, 255, .08), 0 2px 6px rgba(0, 0, 0, .4);
}

/* 滑杆 */
.rv-slider-row { margin-bottom: 10px; }
.rv-slider-row label {
  display: flex; justify-content: space-between; align-items: baseline;
  font-size: 10.5px; color: var(--rv-dim); margin-bottom: 5px;
}
.rv-slider-row output { font-family: var(--rv-mono); font-size: 11px; color: var(--rv-gold-2); font-variant-numeric: tabular-nums; }
.rv-slider-row input[type="range"], .rv-cn-slider input[type="range"] {
  width: 100%; height: 4px; margin: 0;
  appearance: none; -webkit-appearance: none; border-radius: 4px;
  background: linear-gradient(90deg, var(--rv-gold), var(--rv-teal));
  outline: none;
}
.rv-slider-row input[type="range"]::-webkit-slider-thumb, .rv-cn-slider input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 14px; height: 14px; border-radius: 50%;
  background: #e9eef6; border: 3px solid var(--rv-bg-2);
  box-shadow: 0 0 0 1px var(--rv-gold), 0 2px 8px rgba(0, 0, 0, .5);
  cursor: pointer;
}
.rv-slider-row input[type="range"]::-moz-range-thumb, .rv-cn-slider input[type="range"]::-moz-range-thumb {
  width: 12px; height: 12px; border-radius: 50%; background: #e9eef6;
  border: 2px solid var(--rv-bg-2); box-shadow: 0 0 0 1px var(--rv-gold); cursor: pointer;
}
.rv-area-badge {
  display: flex; align-items: baseline; gap: 8px;
  margin-top: 12px; padding: 9px 11px; border-radius: 9px;
  background: linear-gradient(120deg, rgba(45, 212, 191, .12), rgba(245, 158, 11, .08));
  border: 1px solid rgba(45, 212, 191, .22);
}
.rv-area-badge span { font-size: 10.5px; color: var(--rv-dim); }
.rv-area-badge b { font-family: var(--rv-mono); font-size: 17px; color: var(--rv-teal); margin-left: auto; font-variant-numeric: tabular-nums; }
.rv-area-badge small { font-family: var(--rv-mono); font-size: 9px; color: var(--rv-faint); }

/* 档次 */
.rv-tier-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5px; }
.rv-tier-card {
  position: relative; display: flex; flex-direction: column; gap: 2px;
  padding: 8px 6px; border: 1px solid var(--rv-line); border-radius: 9px;
  background: rgba(255, 255, 255, .025); cursor: pointer; transition: all .18s ease;
}
.rv-tier-card input { position: absolute; opacity: 0; pointer-events: none; }
.rv-tier-card:hover { border-color: var(--rv-line-strong); }
.rv-tier-card.is-active {
  border-color: rgba(245, 158, 11, .6);
  background: linear-gradient(140deg, rgba(245, 158, 11, .16), rgba(245, 158, 11, .03));
}
.rv-tier-name { font-size: 10px; font-weight: 700; white-space: nowrap; }
.rv-tier-price { font-family: var(--rv-mono); font-size: 12px; color: var(--rv-gold-2); font-variant-numeric: tabular-nums; }
.rv-tier-price small { font-size: 8px; color: var(--rv-faint); }
.rv-tier-note { font-size: 8px; color: var(--rv-faint); line-height: 1.3; }
.rv-check {
  display: flex; align-items: center; gap: 8px; margin-top: 9px;
  font-size: 10.5px; color: var(--rv-dim); cursor: pointer;
}
.rv-check input { accent-color: var(--rv-gold); width: 14px; height: 14px; margin: 0; }

.rv-input {
  width: 100%; padding: 8px 10px; border-radius: 8px;
  border: 1px solid var(--rv-line-strong);
  background: rgba(0, 0, 0, .26); color: var(--rv-text); font-size: 11px;
  transition: border-color .18s ease;
}
.rv-input::placeholder { color: var(--rv-faint); }
.rv-input:focus { border-color: rgba(245, 158, 11, .6); outline: none; }
.rv-hint { margin: 6px 0 0; font-size: 9px; color: var(--rv-faint); }

.rv-filing dl { margin: 0; display: flex; flex-direction: column; gap: 6px; }
.rv-filing dl div { display: flex; justify-content: space-between; gap: 10px; align-items: baseline; }
.rv-filing dt { font-size: 9.5px; color: var(--rv-faint); white-space: nowrap; }
.rv-filing dd { margin: 0; font-size: 9.5px; color: var(--rv-dim); text-align: right; }

/* ─────────── 中央舞台 ─────────── */
.rv-stage-wrap { position: relative; min-width: 0; min-height: 0; overflow: hidden; background: #05070b; }
.rv-stage { position: absolute; inset: 0; display: none; overflow: hidden; }
.rv-stage.is-active { display: block; }

#rv-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; touch-action: none; }
.rv-vignette {
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse at 50% 45%, transparent 45%, rgba(3, 5, 9, .5) 100%);
  z-index: 2;
}

.rv-split-overlay { position: absolute; inset: 0; z-index: 4; pointer-events: none; }
.rv-split-line {
  position: absolute; top: 0; bottom: 0; left: var(--split, 50%);
  width: 2px; transform: translateX(-1px);
  background: linear-gradient(180deg, transparent, var(--rv-gold-2) 8%, var(--rv-gold) 50%, var(--rv-gold-2) 92%, transparent);
  box-shadow: 0 0 14px rgba(245, 158, 11, .7), 0 0 30px rgba(245, 158, 11, .3);
}
.rv-split-handle {
  position: absolute; top: 50%; left: var(--split, 50%);
  width: 38px; height: 38px; margin: -19px 0 0 -19px;
  border-radius: 50%; border: 2px solid var(--rv-gold-2);
  background: rgba(9, 12, 18, .9);
  box-shadow: 0 0 0 5px rgba(245, 158, 11, .14), 0 4px 20px rgba(0, 0, 0, .5);
  color: var(--rv-gold-2); font-size: 15px;
  pointer-events: auto; cursor: ew-resize;
  display: grid; place-items: center;
  transition: transform .15s ease, box-shadow .15s ease;
}
.rv-split-handle::before { content: '⇄'; }
.rv-split-handle:hover, .rv-split-handle.is-dragging {
  transform: scale(1.12);
  box-shadow: 0 0 0 8px rgba(245, 158, 11, .2), 0 4px 24px rgba(0, 0, 0, .6);
}
.rv-split-badge {
  position: absolute; top: 14px; z-index: 5;
  padding: 5px 11px; border-radius: 999px;
  font-size: 10px; font-weight: 700; letter-spacing: .03em;
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  pointer-events: none;
}
.rv-split-badge-before { left: 16px; background: rgba(15, 20, 28, .7); border: 1px solid var(--rv-line-strong); color: var(--rv-dim); }
.rv-split-badge-after { right: 16px; background: rgba(245, 158, 11, .16); border: 1px solid rgba(245, 158, 11, .5); color: var(--rv-gold-2); }

.rv-hotspot-layer { position: absolute; inset: 0; z-index: 5; pointer-events: none; }
.rv-hotspot {
  position: absolute; width: 20px; height: 20px; margin: -10px 0 0 -10px;
  border-radius: 50%; border: 1px solid rgba(255, 255, 255, .85);
  background: rgba(45, 212, 191, .22);
  box-shadow: 0 0 0 4px rgba(45, 212, 191, .13), 0 0 12px rgba(45, 212, 191, .6);
  pointer-events: auto; cursor: pointer; animation: rv-pulse 2.4s ease-in-out infinite;
}
.rv-hotspot::after { content: ''; position: absolute; inset: 7px; border-radius: 50%; background: #fff; }
@keyframes rv-pulse { 0%, 100% { box-shadow: 0 0 0 4px rgba(45, 212, 191, .13), 0 0 12px rgba(45, 212, 191, .5); } 50% { box-shadow: 0 0 0 8px rgba(45, 212, 191, .05), 0 0 20px rgba(45, 212, 191, .8); } }
.rv-hotspot-card {
  position: absolute; z-index: 12; width: 232px; padding: 12px 13px;
  border-radius: 12px; border: 1px solid rgba(45, 212, 191, .32);
  background: rgba(12, 18, 26, .94);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, .5);
}
.rv-hotspot-card-head { display: flex; justify-content: space-between; align-items: center; font-family: var(--rv-mono); font-size: 9px; letter-spacing: .1em; color: var(--rv-teal); }
.rv-hotspot-card-head button { border: 0; background: none; color: var(--rv-faint); font-size: 12px; }
.rv-hotspot-card h4 { margin: 7px 0 5px; font-size: 13px; }
.rv-hotspot-card p { margin: 0; font-size: 10.5px; color: var(--rv-dim); }

.rv-viewbar {
  position: absolute; top: 12px; left: 50%; transform: translateX(-50%); z-index: 10;
  display: flex; align-items: center; gap: 3px;
  padding: 4px; border-radius: 11px;
  background: rgba(9, 12, 18, .78); border: 1px solid var(--rv-line);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  max-width: calc(100% - 32px); overflow-x: auto;
}
.rv-viewbar button {
  padding: 6px 10px; border: 0; border-radius: 7px; background: transparent;
  color: var(--rv-dim); font-size: 10.5px; font-weight: 600; white-space: nowrap;
}
.rv-viewbar button small { font-family: var(--rv-mono); font-size: 8px; opacity: .7; }
.rv-viewbar button:hover { color: var(--rv-text); background: rgba(255, 255, 255, .05); }
.rv-viewbar button.is-active {
  color: var(--rv-gold-2); background: rgba(245, 158, 11, .14);
  box-shadow: inset 0 0 0 1px rgba(245, 158, 11, .28);
}
.rv-viewbar button[data-view="xray"].is-active { color: var(--rv-teal); background: rgba(45, 212, 191, .14); box-shadow: inset 0 0 0 1px rgba(45, 212, 191, .32), 0 0 16px rgba(45, 212, 191, .2); }
.rv-viewbar button[data-view="3dgs"].is-active { color: #a5b4fc; background: rgba(129, 140, 248, .16); box-shadow: inset 0 0 0 1px rgba(129, 140, 248, .35), 0 0 16px rgba(129, 140, 248, .25); }

.rv-camera-dock {
  position: absolute; bottom: 14px; left: 50%; transform: translateX(-50%); z-index: 10;
  display: flex; align-items: center; gap: 6px;
  padding: 6px; border-radius: 12px;
  background: rgba(9, 12, 18, .84); border: 1px solid var(--rv-line-strong);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, .4);
  max-width: calc(100% - 24px); overflow-x: auto;
}
.rv-dock-group { display: flex; align-items: center; gap: 2px; }
.rv-dock-group button, .rv-dock-download {
  padding: 6px 9px; border: 0; border-radius: 7px;
  background: transparent; color: var(--rv-dim); font-size: 10px; white-space: nowrap;
}
.rv-dock-group button:hover, .rv-dock-download:hover { color: var(--rv-text); background: rgba(255, 255, 255, .06); }
.rv-dock-group button.is-active { color: var(--rv-gold-2); background: rgba(245, 158, 11, .13); }
.rv-dock-sep { width: 1px; height: 20px; background: var(--rv-line-strong); flex: 0 0 auto; }
.rv-dock-download { color: var(--rv-teal); font-weight: 700; }

.rv-boot {
  position: absolute; inset: 0; z-index: 50;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: radial-gradient(circle at 50% 50%, #131a26, #05070b 70%);
  transition: opacity .55s ease, visibility .55s ease;
}
.rv-boot.done { opacity: 0; visibility: hidden; pointer-events: none; }
.rv-boot-mark { font-size: 17px; font-weight: 800; letter-spacing: .1em; }
.rv-boot-sub { margin-top: 8px; font-family: var(--rv-mono); font-size: 9px; letter-spacing: .22em; color: var(--rv-gold-2); }
.rv-boot-bar { width: 200px; height: 3px; margin-top: 22px; border-radius: 3px; background: rgba(255, 255, 255, .1); overflow: hidden; }
.rv-boot-bar i { display: block; width: 40%; height: 100%; background: linear-gradient(90deg, var(--rv-gold), var(--rv-teal)); animation: rv-boot-slide 1.2s ease-in-out infinite; }
@keyframes rv-boot-slide { 0% { transform: translateX(-100%); } 100% { transform: translateX(350%); } }

/* ─────────── CAD 阶段 ─────────── */
.rv-cad-selector, .rv-cad-toolbar {
  display: flex; align-items: center; gap: 6px;
  padding: 8px 12px; border-bottom: 1px solid var(--rv-line);
  background: rgba(9, 12, 18, .9); overflow-x: auto;
}
.rv-cad-selector { flex: 0 0 auto; }
.rv-cad-selector button {
  padding: 7px 12px; border: 1px solid var(--rv-line); border-radius: 8px;
  background: rgba(255, 255, 255, .03); color: var(--rv-dim);
  font-family: var(--rv-mono); font-size: 10.5px; white-space: nowrap;
}
.rv-cad-selector button:hover { border-color: var(--rv-line-strong); color: var(--rv-text); }
.rv-cad-selector button.is-active {
  border-color: rgba(245, 158, 11, .6); color: var(--rv-gold-2);
  background: rgba(245, 158, 11, .12);
}
.rv-cad-toolbar { flex-wrap: wrap; }
.rv-cad-themes, .rv-zoom-group { display: flex; align-items: center; gap: 2px; }
.rv-cad-themes button, .rv-zoom-group button {
  padding: 5px 9px; border: 1px solid var(--rv-line); border-radius: 7px;
  background: rgba(255, 255, 255, .03); color: var(--rv-dim); font-size: 10px;
}
.rv-cad-themes button.is-active { color: var(--rv-teal); border-color: rgba(45, 212, 191, .45); background: rgba(45, 212, 191, .1); }
.rv-cad-themes button:hover, .rv-zoom-group button:hover { color: var(--rv-text); }
.rv-zoom-group span { min-width: 44px; text-align: center; font-family: var(--rv-mono); font-size: 10.5px; color: var(--rv-gold-2); }
.rv-cad-sep { width: 1px; height: 20px; background: var(--rv-line-strong); }
.rv-cad-action { padding: 5px 10px; border: 1px solid var(--rv-line); border-radius: 7px; background: rgba(255, 255, 255, .03); color: var(--rv-text); font-size: 10px; white-space: nowrap; }
.rv-cad-action:hover { border-color: var(--rv-line-strong); background: rgba(255, 255, 255, .07); }
.rv-cad-action-gold { color: var(--rv-gold-2); border-color: rgba(245, 158, 11, .4); }
.rv-cad-viewport {
  position: absolute; top: 98px; bottom: 0; left: 0; right: 0;
  display: grid; place-items: center; padding: 18px; overflow: auto;
  background:
    linear-gradient(rgba(148, 163, 184, .035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 163, 184, .035) 1px, transparent 1px),
    #0a0e15;
  background-size: 24px 24px;
}
.rv-cad-frame {
  transform-origin: center center;
  transition: transform .18s ease;
  max-width: 100%;
  filter: drop-shadow(0 14px 40px rgba(0, 0, 0, .5));
}
.rv-cad-frame svg { display: block; width: 100%; height: auto; max-height: calc(100vh - 160px); }
.rv-cad-frame svg text { font-family: var(--rv-font); }

/* ─────────── AI 实拍阶段 ─────────── */
.rv-photo-scroll, .rv-boq-scroll {
  position: absolute; inset: 0; overflow-y: auto; overflow-x: hidden; padding: 14px;
}
.rv-photo-upload-row { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 12px; margin-bottom: 12px; }
.rv-dropzone {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px;
  min-height: 118px; padding: 14px; border-radius: 12px;
  border: 1.5px dashed rgba(45, 212, 191, .4);
  background: rgba(45, 212, 191, .05); cursor: pointer; text-align: center;
  transition: background .18s ease, border-color .18s ease;
}
.rv-dropzone:hover, .rv-dropzone.is-dragover { background: rgba(45, 212, 191, .12); border-color: var(--rv-teal); }
.rv-dropzone-ico { font-size: 22px; color: var(--rv-teal); line-height: 1; }
.rv-dropzone b { font-size: 11.5px; }
.rv-dropzone small { font-size: 9px; color: var(--rv-faint); }
.rv-samples { min-width: 0; }
.rv-samples-title { font-size: 10.5px; font-weight: 700; color: var(--rv-dim); margin-bottom: 7px; }
.rv-sample-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.rv-sample-card {
  padding: 0; border: 1px solid var(--rv-line); border-radius: 10px; overflow: hidden;
  background: rgba(255, 255, 255, .03); text-align: left; transition: all .18s ease;
}
.rv-sample-card:hover { transform: translateY(-2px); border-color: var(--rv-line-strong); }
.rv-sample-card.is-active { border-color: rgba(245, 158, 11, .6); box-shadow: 0 0 0 1px rgba(245, 158, 11, .2); }
.rv-sample-card canvas { display: block; width: 100%; height: 62px; background: #101722; }
.rv-sample-card span { display: block; padding: 5px 7px; font-size: 9.5px; color: var(--rv-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.rv-cn-bar {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 10px; margin-bottom: 12px; border-radius: 11px;
  border: 1px solid var(--rv-line); background: var(--rv-panel);
}
.rv-cn-modes { display: flex; gap: 4px; }
.rv-cn-mode {
  padding: 6px 9px; border: 1px solid var(--rv-line); border-radius: 7px;
  background: rgba(255, 255, 255, .03); color: var(--rv-dim); font-size: 10px; white-space: nowrap;
}
.rv-cn-mode.is-active { color: var(--rv-gold-2); border-color: rgba(245, 158, 11, .5); background: rgba(245, 158, 11, .12); }
.rv-cn-slider { flex: 0 0 130px; }
.rv-cn-slider label { display: flex; justify-content: space-between; font-size: 9.5px; color: var(--rv-dim); margin-bottom: 5px; }
.rv-cn-slider output { font-family: var(--rv-mono); color: var(--rv-teal); }
.rv-notes-input { flex: 1 1 180px; min-width: 140px; }
.rv-cta small { font-family: var(--rv-mono); font-size: 8.5px; opacity: .75; }

.rv-compare-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.rv-compare-card {
  border: 1px solid var(--rv-line); border-radius: 12px; overflow: hidden;
  background: var(--rv-panel);
}
.rv-compare-head {
  display: flex; justify-content: space-between; align-items: center;
  padding: 9px 12px; border-bottom: 1px solid var(--rv-line);
  font-size: 11px; font-weight: 700;
}
.rv-compare-head small { font-family: var(--rv-mono); font-size: 9px; color: var(--rv-teal); }
.rv-compare-card > canvas { display: block; width: 100%; height: 260px; background: #080c13; object-fit: cover; }
.rv-compare-foot { margin: 0; padding: 7px 12px; font-size: 9px; color: var(--rv-faint); border-top: 1px solid var(--rv-line); }
.rv-photo-compare {
  position: relative; height: 260px; overflow: hidden;
  background: #080c13; user-select: none; touch-action: none;
}
.rv-photo-before, .rv-photo-after {
  position: absolute; inset: 0; background-size: cover; background-position: center;
}
.rv-photo-before { clip-path: inset(0 calc(100% - var(--split, 50%)) 0 0); }
.rv-photo-line { position: absolute; top: 0; bottom: 0; left: var(--split, 50%); width: 2px; transform: translateX(-1px); background: var(--rv-gold); box-shadow: 0 0 12px rgba(245, 158, 11, .7); pointer-events: none; }
.rv-photo-handle {
  position: absolute; top: 50%; left: var(--split, 50%); transform: translate(-50%, -50%);
  width: 34px; height: 34px; border-radius: 50%; border: 2px solid var(--rv-gold-2);
  background: rgba(9, 12, 18, .88); color: var(--rv-gold-2); font-size: 14px;
  cursor: ew-resize; box-shadow: 0 0 0 5px rgba(245, 158, 11, .14), 0 4px 16px rgba(0, 0, 0, .5);
  display: grid; place-items: center;
}

/* ─────────── BOQ 阶段 ─────────── */
.rv-kpi-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-bottom: 12px; }
.rv-kpi {
  padding: 12px 14px; border-radius: 12px;
  border: 1px solid var(--rv-line); background: var(--rv-panel);
  display: flex; flex-direction: column; gap: 3px;
}
.rv-kpi small { font-size: 10px; color: var(--rv-dim); }
.rv-kpi b { font-family: var(--rv-mono); font-size: 20px; color: var(--rv-gold-2); font-variant-numeric: tabular-nums; }
.rv-kpi i { font-size: 9px; color: var(--rv-faint); font-style: normal; }
.rv-kpi b.rv-safe { color: var(--rv-teal); }
.rv-boq-layout { display: grid; grid-template-columns: minmax(0, 1fr) 250px; gap: 12px; }
.rv-boq-main, .rv-boq-side { min-width: 0; }
.rv-boq-head, .rv-gantt-head {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 4px 0 8px;
}
.rv-boq-head h3, .rv-gantt-head h3 { margin: 0; font-size: 12px; }
.rv-boq-head h3 small, .rv-gantt-head h3 small { font-family: var(--rv-mono); font-size: 8px; letter-spacing: .12em; color: var(--rv-faint); margin-left: 6px; }
.rv-gantt-head span { font-family: var(--rv-mono); font-size: 9px; color: var(--rv-teal); }
.rv-table-wrap { border: 1px solid var(--rv-line); border-radius: 10px; overflow: hidden; background: var(--rv-panel); }
.rv-boq-table { width: 100%; border-collapse: collapse; font-size: 10.5px; }
.rv-boq-table th {
  padding: 8px 9px; text-align: left; font-size: 9.5px; color: var(--rv-dim); font-weight: 700;
  background: rgba(255, 255, 255, .035); border-bottom: 1px solid var(--rv-line); white-space: nowrap;
}
.rv-boq-table td { padding: 7px 9px; border-bottom: 1px solid rgba(148, 163, 184, .07); color: var(--rv-text); }
.rv-boq-table tbody tr:last-child td { border-bottom: 0; }
.rv-boq-table tbody tr:hover { background: rgba(255, 255, 255, .025); }
.rv-boq-table .rv-cell-code { font-family: var(--rv-mono); color: var(--rv-gold-2); font-size: 9.5px; }
.rv-boq-table .rv-cell-num { font-family: var(--rv-mono); font-variant-numeric: tabular-nums; text-align: right; }
.rv-boq-table .rv-cell-empty { text-align: center; color: var(--rv-faint); padding: 24px; }
.rv-share-bar { display: inline-block; width: 56px; height: 4px; border-radius: 4px; background: rgba(255, 255, 255, .1); vertical-align: middle; overflow: hidden; margin-left: 6px; }
.rv-share-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--rv-teal), var(--rv-gold)); }
.rv-gantt { padding: 10px 12px; border: 1px solid var(--rv-line); border-radius: 10px; background: var(--rv-panel); }
.rv-gantt-row { display: grid; grid-template-columns: 96px minmax(0, 1fr); align-items: center; gap: 8px; margin-bottom: 7px; }
.rv-gantt-row:last-child { margin-bottom: 0; }
.rv-gantt-label { font-size: 9.5px; color: var(--rv-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rv-gantt-track { position: relative; height: 16px; border-radius: 5px; background: rgba(255, 255, 255, .05); overflow: hidden; }
.rv-gantt-bar {
  position: absolute; top: 0; bottom: 0; border-radius: 5px;
  background: linear-gradient(90deg, rgba(245, 158, 11, .8), rgba(45, 212, 191, .8));
  box-shadow: 0 0 10px rgba(245, 158, 11, .2);
}
.rv-gantt-bar span { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--rv-mono); font-size: 8px; color: #0a0e15; font-weight: 700; }
.rv-redline-card {
  padding: 12px; border: 1px solid rgba(248, 113, 113, .28); border-radius: 11px;
  background: rgba(248, 113, 113, .06); margin-bottom: 10px;
}
.rv-redline-card h3 { margin: 0 0 8px; font-size: 11.5px; color: #fca5a5; }
.rv-redline-card ul { margin: 0; padding-left: 16px; }
.rv-redline-card li { font-size: 10px; color: var(--rv-dim); margin-bottom: 5px; line-height: 1.45; }
.rv-ai-brief { margin-top: 10px; padding: 11px; border: 1px solid var(--rv-line); border-radius: 10px; background: var(--rv-panel); font-size: 10.5px; color: var(--rv-dim); line-height: 1.6; max-height: 260px; overflow: auto; }
.rv-ai-brief b { color: var(--rv-gold-2); }

/* ─────────── 右侧智能坞 ─────────── */
.rv-card {
  padding: 12px; margin-bottom: 10px; border-radius: 12px;
  border: 1px solid var(--rv-line); background: var(--rv-panel);
}
.rv-card-title { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 9px; font-size: 11px; font-weight: 700; }
.rv-card-title small { font-family: var(--rv-mono); font-size: 8.5px; letter-spacing: .1em; color: var(--rv-teal); }
.rv-big-cost { font-family: var(--rv-mono); font-size: 26px; font-weight: 700; color: var(--rv-gold-2); font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.rv-budget-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; margin: 10px 0; }
.rv-budget-grid div { display: flex; flex-direction: column; gap: 1px; padding: 6px 8px; border-radius: 7px; background: rgba(255, 255, 255, .035); }
.rv-budget-grid small { font-size: 9px; color: var(--rv-faint); }
.rv-budget-grid b { font-family: var(--rv-mono); font-size: 11.5px; color: var(--rv-text); }
.rv-card-link { display: block; font-size: 10px; color: var(--rv-teal); margin-top: 7px; }
.rv-card-link:hover { text-decoration: underline; }
.rv-material-list { display: flex; flex-direction: column; gap: 6px; }
.rv-material {
  display: flex; align-items: center; gap: 8px; padding: 6px 8px;
  border-radius: 8px; background: rgba(255, 255, 255, .035);
}
.rv-material i { width: 16px; height: 16px; border-radius: 5px; box-shadow: 0 0 0 1px rgba(255, 255, 255, .12); }
.rv-material code { font-family: var(--rv-mono); font-size: 9px; color: var(--rv-gold-2); }
.rv-material span { font-size: 10px; color: var(--rv-dim); margin-left: auto; }
.rv-advisor-text { margin: 0 0 10px; font-size: 10.5px; line-height: 1.6; color: var(--rv-dim); }

/* ─────────── 页脚 / toast / modal ─────────── */
.rv-footer {
  flex: 0 0 28px; display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 0 16px; border-top: 1px solid var(--rv-line);
  background: rgba(9, 12, 18, .92);
  font-size: 9px; color: var(--rv-faint); overflow: hidden;
}
.rv-footer a { color: var(--rv-teal); }
.rv-footer-right { white-space: nowrap; }

.rv-toast-stack {
  position: fixed; right: 18px; bottom: 44px; z-index: 80;
  display: flex; flex-direction: column; gap: 8px; max-width: 340px;
}
.rv-toast {
  padding: 10px 14px; border-radius: 10px;
  border: 1px solid var(--rv-line-strong);
  background: rgba(16, 22, 32, .96);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .45);
  font-size: 11px; color: var(--rv-text);
  animation: rv-toast-in .25s ease;
}
.rv-toast.ok { border-color: rgba(45, 212, 191, .5); }
.rv-toast.err { border-color: rgba(248, 113, 113, .5); }
.rv-toast a { color: var(--rv-gold-2); text-decoration: underline; }
@keyframes rv-toast-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

.rv-modal { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; }
.rv-modal-backdrop { position: absolute; inset: 0; background: rgba(3, 5, 9, .74); backdrop-filter: blur(6px); }
.rv-modal-card {
  position: relative; width: min(420px, calc(100% - 32px)); padding: 28px;
  border-radius: 16px; border: 1px solid rgba(245, 158, 11, .34);
  background: linear-gradient(150deg, #151c28, #0c1017);
  box-shadow: 0 24px 70px rgba(0, 0, 0, .6); text-align: center;
}
.rv-modal-close { position: absolute; top: 12px; right: 12px; border: 0; background: none; color: var(--rv-faint); font-size: 14px; }
.rv-modal-glyph {
  width: 46px; height: 46px; margin: 0 auto 12px; border-radius: 13px;
  display: grid; place-items: center; font-size: 22px;
  background: linear-gradient(135deg, var(--rv-gold-2), var(--rv-gold)); color: #0c1017;
}
.rv-modal-card h3 { margin: 0 0 8px; font-size: 16px; }
.rv-modal-card p { margin: 0 0 18px; font-size: 11.5px; color: var(--rv-dim); line-height: 1.6; }
.rv-modal-actions { display: flex; flex-direction: column; gap: 8px; }

/* ─────────── 响应式 ─────────── */
@media (max-width: 1180px) {
  .rv-workspace { grid-template-columns: 246px minmax(0, 1fr) 250px; }
  .rv-app.rv-sidebar-collapsed .rv-workspace { grid-template-columns: 44px minmax(0, 1fr) 250px; }
  .rv-app.rv-inspector-collapsed .rv-workspace { grid-template-columns: 246px minmax(0, 1fr) 44px; }
  .rv-app.rv-sidebar-collapsed.rv-inspector-collapsed .rv-workspace { grid-template-columns: 44px minmax(0, 1fr) 44px; }
  .rv-quicknav a:nth-child(n+4) { display: none; }
  .rv-mode-tab { padding: 6px 8px; font-size: 10.5px; }
  .rv-topbar-actions .rv-btn-ghost { display: none; }
  .rv-photo-upload-row { grid-template-columns: 240px minmax(0, 1fr); }
  .rv-boq-layout { grid-template-columns: minmax(0, 1fr) 220px; }
}

@media (max-width: 820px) {
  body { overflow: auto; }
  .rv-app { height: auto; min-height: 100vh; overflow: visible; }
  .rv-topbar {
    height: auto; flex-basis: auto; grid-template-columns: 1fr;
    gap: 8px; padding: 10px 12px;
  }
  .rv-brand-cluster { justify-content: space-between; }
  .rv-quicknav { display: none; }
  .rv-mode-tabs { justify-self: stretch; overflow-x: auto; }
  .rv-mode-tab { flex: 1 0 auto; }
  .rv-topbar-actions { justify-content: flex-start; flex-wrap: wrap; }
  .rv-workspace { grid-template-columns: 1fr; overflow: visible; }
  .rv-app.rv-sidebar-collapsed .rv-workspace,
  .rv-app.rv-inspector-collapsed .rv-workspace,
  .rv-app.rv-sidebar-collapsed.rv-inspector-collapsed .rv-workspace { grid-template-columns: 1fr; }
  .rv-sidebar, .rv-inspector { border: 0; border-bottom: 1px solid var(--rv-line); }
  .rv-sidebar-body, .rv-inspector-body { max-height: 420px; }
  .rv-app.rv-sidebar-collapsed .rv-sidebar-body,
  .rv-app.rv-inspector-collapsed .rv-inspector-body { display: block; }
  .rv-app.rv-sidebar-collapsed .rv-sidebar-title,
  .rv-app.rv-inspector-collapsed .rv-inspector-head > span { display: inline; }
  .rv-stage-wrap { height: 72vh; min-height: 520px; }
  .rv-stage { position: absolute; }
  .rv-photo-scroll, .rv-boq-scroll { position: relative; height: auto; }
  .rv-compare-grid { grid-template-columns: 1fr; }
  .rv-kpi-grid { grid-template-columns: 1fr 1fr; }
  .rv-boq-layout { grid-template-columns: 1fr; }
  .rv-footer { flex-wrap: wrap; height: auto; padding: 8px 12px; gap: 4px; }
}

@media (max-width: 640px) {
  .rv-room-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rv-style-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .rv-photo-upload-row { grid-template-columns: 1fr; }
  .rv-sample-grid { grid-template-columns: 1fr 1fr; }
  .rv-cn-modes { flex-wrap: wrap; }
  .rv-cn-slider { flex: 1 1 100%; }
  .rv-kpi-grid { grid-template-columns: 1fr; }
  .rv-mode-tabs { gap: 2px; }
  .rv-mode-tab { font-size: 10px; padding: 6px; }
  .rv-split-badge { font-size: 8.5px; padding: 4px 8px; }
  .rv-camera-dock { flex-wrap: nowrap; }
  .rv-toast-stack { right: 10px; left: 10px; max-width: none; }
}

/* ─────────── 打印施工图 ─────────── */
@media print {
  @page { size: A3 landscape; margin: 10mm; }
  body { background: #fff; color: #000; overflow: visible; }
  .rv-topbar, .rv-sidebar, .rv-inspector, .rv-footer,
  .rv-cad-toolbar, .rv-cad-selector, .rv-toast-stack, .rv-modal { display: none !important; }
  .rv-app, .rv-workspace, .rv-stage-wrap, .rv-stage, .rv-cad-viewport { position: static; display: block; height: auto; overflow: visible; background: #fff; }
  .rv-stage:not(#rv-stage-cad) { display: none !important; }
  .rv-cad-viewport { padding: 0; background: #fff; }
  .rv-cad-frame { transform: none !important; filter: none; }
  .rv-cad-frame svg { max-height: none; width: 100%; }
}
