/* ============================================================
   Neural Studio · 网页版样式
   深色工作台 + 纯白画布，参考现代仪表盘风格
   ============================================================ */
:root {
  --bg: #0c0e13;
  --bg-2: #10131b;
  --panel: #151a24;
  --panel-2: #1a2130;
  --panel-3: #212a3d;
  --line: #273043;
  --line-soft: #1f2735;
  --text: #e9eef8;
  --muted: #8b98ae;
  --muted-2: #6b7789;
  --accent: #2fd6a8;
  --accent-2: #7c6cff;
  --accent-soft: rgba(47, 214, 168, 0.14);
  --purple-soft: rgba(124, 108, 255, 0.16);
  --orange: #f5a524;
  --orange-soft: rgba(245, 165, 36, 0.16);
  --danger: #ff6b6b;
  --shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
  --radius: 16px;
}

* { box-sizing: border-box; }

html, body {
  height: 100%;
  margin: 0;
  background: radial-gradient(1200px 800px at 12% -10%, #1b1f3a 0%, transparent 55%),
              radial-gradient(900px 700px at 100% 0%, #172a2a 0%, transparent 50%),
              var(--bg);
  color: var(--text);
  font-family: "PingFang SC", "Microsoft YaHei", "Segoe UI", system-ui, -apple-system, sans-serif;
  overflow: hidden;
}

button, input, select { font-family: inherit; }

#app {
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: 14px 16px 16px;
  gap: 12px;
}

/* ============ 顶栏 ============ */
.topbar {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 10px 16px;
  background: linear-gradient(180deg, rgba(28, 34, 50, 0.92) 0%, rgba(20, 25, 37, 0.92) 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  flex-shrink: 0;
}
.brand { display: flex; align-items: center; gap: 10px; min-width: 200px; }
.brand-logo {
  width: 38px; height: 38px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 20px; color: #08110e;
  background: linear-gradient(135deg, #53f0c4 0%, #7c6cff 100%);
  box-shadow: 0 8px 20px rgba(83, 240, 196, 0.25);
}
.brand-name { font-size: 15px; font-weight: 700; letter-spacing: 0.3px; }
.brand-sub { font-size: 11px; color: var(--muted-2); margin-top: 1px; }

.topbar-fields { display: flex; gap: 12px; flex: 1; }
.field { display: flex; align-items: center; gap: 8px; }
.field-label { font-size: 12px; color: var(--muted); white-space: nowrap; }
.model-field { min-width: 190px; }
.preset-field { min-width: 210px; }
.style-field { min-width: 0; }

.input {
  height: 34px;
  padding: 0 12px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #10141d;
  color: var(--text);
  font-size: 13px;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.input:focus { border-color: rgba(47, 214, 168, 0.65); box-shadow: 0 0 0 3px rgba(47, 214, 168, 0.12); }
.input.select { padding-right: 8px; cursor: pointer; }
.input.small { height: 30px; font-size: 12px; padding: 0 8px; }
.model-field .input { width: 100%; }
.preset-field .input { width: 100%; }

.topbar-actions { display: flex; align-items: center; gap: 10px; }

.btn {
  height: 36px;
  padding: 0 16px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: var(--panel-2);
  color: var(--text);
  font-size: 13px;
  cursor: pointer;
  transition: transform 0.12s, background 0.15s, border-color 0.15s, box-shadow 0.15s;
  white-space: nowrap;
}
.btn:hover { background: var(--panel-3); border-color: #35405a; }
.btn:active { transform: translateY(1px); }
.btn.primary {
  background: linear-gradient(135deg, #2fd6a8 0%, #21b98f 100%);
  border-color: transparent;
  color: #04120d;
  font-weight: 700;
  box-shadow: 0 8px 20px rgba(47, 214, 168, 0.22);
}
.btn.primary:hover { filter: brightness(1.06); }
.btn.ghost { background: rgba(255, 255, 255, 0.04); }
.btn.danger-ghost { color: #ff9b9b; border-color: rgba(255, 107, 107, 0.32); background: rgba(255, 107, 107, 0.06); }
.btn:disabled { opacity: 0.4; cursor: not-allowed; }

/* ============ 主体三栏 ============ */
.main {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: 252px minmax(0, 1fr) 300px;
  gap: 12px;
}

/* ---- 左侧组件库 ---- */
.palette {
  display: flex;
  flex-direction: column;
  min-height: 0;
  background: linear-gradient(180deg, rgba(26, 32, 46, 0.95) 0%, rgba(19, 24, 35, 0.95) 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.palette-head {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 14px 14px 10px;
  border-bottom: 1px solid var(--line-soft);
  font-size: 13px;
  font-weight: 700;
}
.palette-search {
  height: 30px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: #10141d;
  color: var(--text);
  font-size: 12px;
  padding: 0 10px;
  outline: none;
}
.palette-search:focus { border-color: rgba(47, 214, 168, 0.5); }
.palette-list {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 10px 12px 14px;
}
.palette-group { margin-bottom: 14px; }
.palette-group-title {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: var(--muted-2);
  letter-spacing: 0.6px;
  margin: 2px 2px 8px;
}
.palette-group-title::before {
  content: "";
  width: 6px; height: 6px; border-radius: 2px;
  background: var(--accent);
  opacity: 0.8;
}
.palette-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.tile {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 9px 10px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: linear-gradient(180deg, #1a2130 0%, #161c28 100%);
  cursor: grab;
  user-select: none;
  transition: transform 0.12s, border-color 0.15s, background 0.15s;
}
.tile:hover { border-color: rgba(47, 214, 168, 0.55); background: #1d2536; transform: translateY(-1px); }
.tile:active { cursor: grabbing; }
.tile-name { font-size: 12px; font-weight: 700; }
.tile-short { font-size: 10px; color: var(--muted-2); }
.palette-tip {
  padding: 10px 14px 12px;
  border-top: 1px solid var(--line-soft);
  font-size: 10.5px;
  line-height: 1.7;
  color: var(--muted-2);
}
.palette-tip b { color: var(--muted); font-weight: 600; }

/* ---- 中间画布 ---- */
.workspace {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  gap: 10px;
}
.canvas {
  position: relative;
  flex: 1;
  min-height: 0;
  background: #ffffff;
  border-radius: var(--radius);
  border: 1px solid #0b0d12;
  box-shadow: var(--shadow);
  overflow: hidden;
  cursor: grab;
}
.canvas.panning { cursor: grabbing; }
.canvas.drop-active { outline: 2px dashed rgba(47, 214, 168, 0.7); outline-offset: -8px; }
.canvas-title {
  position: absolute;
  right: 14px;
  bottom: 10px;
  font-size: 10px;
  color: #c3cad6;
  pointer-events: none;
  letter-spacing: 0.4px;
}
.world {
  position: absolute;
  left: 0; top: 0;
  transform-origin: 0 0;
  width: 0; height: 0;
}
#edgeSvg {
  position: absolute;
  left: 0; top: 0;
  overflow: visible;
  pointer-events: none;
}
.node-layer { position: absolute; left: 0; top: 0; }

/* 普通节点 */
.node {
  position: absolute;
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 9px 12px 10px;
  border-radius: 11px;
  border: 1px solid #d9e0ea;
  background: #ffffff;
  box-shadow: 0 2px 6px rgba(16, 24, 40, 0.08);
  cursor: grab;
  user-select: none;
  overflow: visible;
}
.node::before {
  content: "";
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 4px;
  background: var(--node-color, #93a4bd);
  border-radius: 4px 0 0 4px;
}
.node:hover { border-color: #b7c4d6; box-shadow: 0 6px 16px rgba(16, 24, 40, 0.12); }
.node.selected { border-color: #12a879; box-shadow: 0 0 0 3px rgba(18, 168, 121, 0.18), 0 8px 20px rgba(16, 24, 40, 0.14); }
.node.has-error { border-color: #ef6b6b; box-shadow: 0 0 0 3px rgba(239, 107, 107, 0.16); }
.node.dragging { cursor: grabbing; opacity: 0.92; }
.node-title {
  font-size: 12px;
  font-weight: 700;
  color: #12202f;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.node-type { font-size: 9px; color: #93a1b5; position: absolute; right: 9px; top: 9px; }
.node-summary { font-size: 10px; color: #5d6b7d; line-height: 1.35; }
.node-shape {
  align-self: flex-start;
  margin-top: auto;
  font-size: 9.5px;
  padding: 2px 6px;
  border-radius: 6px;
  background: #f2f5f9;
  color: #43536a;
  font-family: "JetBrains Mono", Consolas, monospace;
}
.node-error-dot {
  position: absolute;
  right: 8px;
  bottom: 8px;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #ef6b6b;
}

/* 块节点 */
.node.block {
  color: #103049;
  border: 1.5px solid rgba(47, 92, 128, 0.45);
  background: #ffffff;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 2px;
  box-shadow: 0 6px 16px rgba(16, 40, 60, 0.12);
}
.node.block::before { display: none; }
.node.block .block-name { font-size: 13px; font-weight: 800; }
.node.block .block-meta { font-size: 9.5px; color: #5a6c80; }
.node.block.circle {
  border-radius: 50%;
  padding: 8px;
  box-shadow: 0 8px 18px rgba(16, 40, 60, 0.16);
}
.node.block.circle .block-name { font-size: 12px; }
.node.block.expanded { outline: 2px dashed rgba(18, 168, 121, 0.6); outline-offset: 3px; }

/* 端口 */
.port {
  position: absolute;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #ffffff;
  border: 2px solid #8fa2ba;
  z-index: 3;
  opacity: 0.55;
  transition: opacity 0.12s, transform 0.12s, border-color 0.12s;
}
.node:hover .port, .port.available { opacity: 1; }
.port:hover { border-color: #12a879; transform: scale(1.25); opacity: 1; }
.port[data-port="out"] { right: -6px; top: 50%; margin-top: -5.5px; }
.port[data-port="in"] { left: -6px; top: 50%; margin-top: -5.5px; }
.port[data-port="top"] { top: -6px; left: 50%; margin-left: -5.5px; }
.port[data-port="bottom"] { bottom: -6px; left: 50%; margin-left: -5.5px; }

/* 连线 */
.edge-path {
  fill: none;
  stroke: #3b4a5f;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: stroke 0.12s;
}
.edge-path.edge-skip { stroke: #e08b2c; stroke-width: 2.6; }
.edge-path.edge-selected { stroke: #12a879; stroke-width: 3; }
.edge-hit {
  fill: none;
  stroke: transparent;
  stroke-width: 14;
  pointer-events: stroke;
  cursor: pointer;
}
.edge-plus {
  font-size: 12px;
  font-weight: 700;
  fill: #b4630f;
  paint-order: stroke;
  stroke: #ffffff;
  stroke-width: 3px;
  pointer-events: none;
}
.edge-arrow { fill: #3b4a5f; }
.edge-arrow.skip { fill: #e08b2c; }
.edge-temp {
  fill: none;
  stroke: #12a879;
  stroke-width: 2;
  stroke-dasharray: 6 5;
  pointer-events: none;
}

.marquee {
  position: absolute;
  border: 1px solid rgba(18, 168, 121, 0.9);
  background: rgba(18, 168, 121, 0.08);
  border-radius: 6px;
  pointer-events: none;
  z-index: 9;
}

/* 状态栏 */
.statusbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 6px;
  height: 30px;
  flex-shrink: 0;
}
.status-left { display: flex; align-items: center; gap: 12px; font-size: 12px; color: var(--muted); }
.status-errors { color: #ffb4a8; }
.status-right { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.icon-btn {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--panel-2);
  color: var(--text);
  cursor: pointer;
  font-size: 14px;
  line-height: 1;
}
.icon-btn:hover { background: var(--panel-3); }
.icon-btn.wide { width: auto; padding: 0 10px; font-size: 11px; }

/* ---- 右侧属性面板 ---- */
.inspector {
  display: flex;
  flex-direction: column;
  min-height: 0;
  background: linear-gradient(180deg, rgba(26, 32, 46, 0.95) 0%, rgba(19, 24, 35, 0.95) 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.inspector-head {
  padding: 14px 16px 10px;
  font-size: 13px;
  font-weight: 700;
  border-bottom: 1px solid var(--line-soft);
}
.inspector-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 12px 14px 16px;
}
.inspector-empty {
  font-size: 12px;
  color: var(--muted-2);
  line-height: 1.8;
  padding: 18px 4px;
  text-align: center;
}
.insp-title { font-size: 14px; font-weight: 800; margin-bottom: 2px; }
.insp-sub { font-size: 11px; color: var(--muted-2); margin-bottom: 12px; }
.insp-shape {
  display: inline-block;
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 7px;
  background: var(--accent-soft);
  color: #7ff0cf;
  font-family: "JetBrains Mono", Consolas, monospace;
  margin-bottom: 12px;
}
.insp-error {
  font-size: 11px;
  color: #ffb4a8;
  background: rgba(255, 107, 107, 0.1);
  border: 1px solid rgba(255, 107, 107, 0.25);
  border-radius: 9px;
  padding: 8px 10px;
  margin-bottom: 12px;
  line-height: 1.6;
}
.insp-section { margin-bottom: 14px; }
.insp-section-title {
  font-size: 10.5px;
  letter-spacing: 0.6px;
  color: var(--muted-2);
  margin-bottom: 8px;
  text-transform: uppercase;
}
.field-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}
.field-row label { font-size: 12px; color: var(--muted); flex: 1; }
.field-row input[type="number"], .field-row input[type="text"], .field-row select {
  width: 96px;
  height: 30px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: #10141d;
  color: var(--text);
  font-size: 12px;
  padding: 0 8px;
  outline: none;
}
.field-row input:focus, .field-row select:focus { border-color: rgba(47, 214, 168, 0.6); }
.switch {
  position: relative;
  width: 38px; height: 22px;
  border-radius: 11px;
  background: #2a3346;
  border: 1px solid var(--line);
  cursor: pointer;
  flex-shrink: 0;
}
.switch::after {
  content: "";
  position: absolute;
  left: 2px; top: 2px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: #93a4bd;
  transition: left 0.15s, background 0.15s;
}
.switch.on { background: rgba(47, 214, 168, 0.25); border-color: rgba(47, 214, 168, 0.5); }
.switch.on::after { left: 18px; background: var(--accent); }

.insp-actions { display: flex; flex-direction: column; gap: 8px; margin-top: 6px; }
.insp-actions .btn { height: 32px; font-size: 12px; }

/* ============ 弹窗 ============ */
.modal-mask {
  position: fixed;
  inset: 0;
  background: rgba(4, 6, 10, 0.62);
  backdrop-filter: blur(3px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
}
.modal {
  width: min(860px, 92vw);
  max-height: 84vh;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #171d29 0%, #121722 100%);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5);
  overflow: hidden;
}
.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  font-size: 14px;
  font-weight: 700;
  border-bottom: 1px solid var(--line-soft);
}
.modal-body { padding: 16px 18px; overflow: auto; }
.modal-foot {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 12px 18px;
  border-top: 1px solid var(--line-soft);
}
.modal-field { margin-bottom: 14px; }
.modal-field > label { display: block; font-size: 12px; color: var(--muted); margin-bottom: 6px; }
.modal-field .input { width: 100%; }
.modal-error { color: #ffb4a8; font-size: 12px; margin-top: 6px; }
.code-view {
  margin: 0;
  padding: 14px;
  max-height: 52vh;
  overflow: auto;
  background: #0b0f16;
  border: 1px solid var(--line);
  border-radius: 12px;
  font-family: "JetBrains Mono", Consolas, "Courier New", monospace;
  font-size: 12px;
  line-height: 1.62;
  color: #cfe0f5;
  white-space: pre;
  tab-size: 4;
}
.shape-options { display: flex; gap: 10px; }
.shape-option {
  flex: 1;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: var(--panel-2);
  cursor: pointer;
  text-align: center;
  font-size: 12px;
  color: var(--muted);
}
.shape-option.active { border-color: rgba(47, 214, 168, 0.65); background: var(--accent-soft); color: #b7f7e6; }
.shape-option .shape-preview {
  margin: 0 auto 8px;
  width: 44px; height: 30px;
  border-radius: 8px;
  border: 2px solid #6f7f97;
}
.shape-option.circle .shape-preview { width: 34px; height: 34px; border-radius: 50%; }

/* 滚动条 */
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: #2a3448; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #39465f; }
::-webkit-scrollbar-track { background: transparent; }

.modal-mask[hidden] { display: none !important; }

/* ============================================================
   动效与质感：动态渐变背景 / 玻璃面板 / 悬停微交互
   ============================================================ */
body::before {
  content: "";
  position: fixed;
  inset: -20%;
  z-index: -2;
  background:
    radial-gradient(520px 420px at 18% 12%, rgba(124, 108, 255, 0.20), transparent 62%),
    radial-gradient(560px 460px at 82% 8%, rgba(47, 214, 168, 0.16), transparent 60%),
    radial-gradient(680px 520px at 60% 100%, rgba(70, 120, 255, 0.12), transparent 65%);
  filter: blur(8px);
  animation: aurora-drift 18s ease-in-out infinite alternate;
  pointer-events: none;
}
@keyframes aurora-drift {
  0% { transform: translate3d(-1.5%, -1%, 0) scale(1); }
  50% { transform: translate3d(1.5%, 1.5%, 0) scale(1.03); }
  100% { transform: translate3d(-0.5%, 2%, 0) scale(1.01); }
}

.topbar, .palette, .inspector {
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

/* 按钮扫光 */
.btn { position: relative; overflow: hidden; }
.btn::after {
  content: "";
  position: absolute;
  top: 0; left: -120%;
  width: 60%; height: 100%;
  transform: skewX(-18deg);
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.18), transparent);
  transition: left 0.45s ease;
  pointer-events: none;
}
.btn:hover::after { left: 130%; }
.btn.primary::after { background: linear-gradient(90deg, transparent, rgba(255,255,255,0.42), transparent); }
.btn.primary { animation: primary-glow 3.2s ease-in-out infinite; }
@keyframes primary-glow {
  0%, 100% { box-shadow: 0 8px 20px rgba(47, 214, 168, 0.22); }
  50% { box-shadow: 0 10px 30px rgba(47, 214, 168, 0.40); }
}

/* 面板入场 */
.palette { animation: panel-in 0.45s cubic-bezier(.2,.7,.3,1) both; }
.inspector { animation: panel-in 0.5s 0.05s cubic-bezier(.2,.7,.3,1) both; }
@keyframes panel-in {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* 组件库卡片 */
.tile { position: relative; overflow: hidden; }
.tile::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(120px 60px at 50% 0%, rgba(47,214,168,0.16), transparent 70%);
  opacity: 0;
  transition: opacity 0.2s;
  pointer-events: none;
}
.tile:hover::before { opacity: 1; }
.tile:hover .tile-name { color: #d7fff4; }

/* 节点：柔和悬浮 + 选中呼吸描边 */
.node {
  transition: box-shadow 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
}
.node:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(16, 24, 40, 0.16), 0 0 0 1px rgba(18, 168, 121, 0.18);
}
.node.selected { animation: node-selected 2.4s ease-in-out infinite; }
@keyframes node-selected {
  0%, 100% { box-shadow: 0 0 0 3px rgba(18,168,121,0.16), 0 8px 20px rgba(16,24,40,0.14); }
  50% { box-shadow: 0 0 0 5px rgba(18,168,121,0.24), 0 10px 26px rgba(16,24,40,0.18); }
}
.node.pop { animation: node-pop 0.34s cubic-bezier(.2,1.3,.4,1) both; }
@keyframes node-pop {
  from { opacity: 0; transform: scale(0.82); }
  to { opacity: 1; transform: scale(1); }
}

/* 端口：默认低调，hover 节点时亮起 + 光晕 */
.port { opacity: 0; transition: opacity .16s, transform .16s, box-shadow .16s, border-color .16s; }
.node:hover .port, .node.selected .port { opacity: 0.95; }
.port:hover {
  transform: scale(1.35);
  box-shadow: 0 0 0 4px rgba(18,168,121,0.18), 0 0 10px rgba(18,168,121,0.55);
  border-color: #0f9c72;
}

/* 连线 hover 高亮 + 选中流动虚线 */
.edge-g { cursor: pointer; }
.edge-g:hover .edge-path:not(.edge-skip) { stroke: #12a879; stroke-width: 2.7; }
.edge-g:hover .edge-path.edge-skip { stroke: #f0a03c; stroke-width: 3.2; }
.edge-path.edge-selected {
  stroke: #0f9c72 !important;
  stroke-dasharray: 8 5;
  animation: edge-flow 0.9s linear infinite;
}
@keyframes edge-flow { to { stroke-dashoffset: -26; } }

/* 画布：跟随鼠标的柔光 */
.canvas::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(260px 260px at var(--mx, 50%) var(--my, 50%), rgba(47, 214, 168, 0.07), transparent 70%);
  opacity: 0.9;
  transition: opacity 0.3s;
}

/* 状态栏 / 滚动条等细节 */
.statusbar { transition: color 0.2s; }
.icon-btn { transition: background 0.15s, transform 0.12s; }
.icon-btn:hover { transform: translateY(-1px); }
.icon-btn:active { transform: translateY(0); }

/* 弹窗入场 */
.modal { animation: modal-in 0.26s cubic-bezier(.2,.9,.3,1.05) both; }
@keyframes modal-in {
  from { opacity: 0; transform: translateY(14px) scale(0.98); }
  to { opacity: 1; transform: none; }
}
.modal-mask { animation: mask-in 0.2s ease both; }
@keyframes mask-in { from { opacity: 0; } to { opacity: 1; } }

/* 属性面板行 hover */
.field-row { border-radius: 8px; transition: background .15s; }
.field-row:hover { background: rgba(255,255,255,0.03); }
