.vca-root {
  --vca-grape: #7c3aed;
  --vca-grape-light: #a855f7;
  --vca-bg: #f8fafc;
  padding: 0 0 32px;
  min-height: 100%;
  background: var(--vca-bg);
}

.vca-hero {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 28px 32px 20px;
  background: linear-gradient(135deg, #4c1d95 0%, #6d28d9 45%, #a855f7 100%);
  color: #fff;
  border-radius: 0 0 16px 16px;
  margin-bottom: 20px;
}

.vca-hero-icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
}

.vca-hero-title {
  margin: 0 0 4px;
  font-size: 1.65rem;
  font-weight: 700;
}

.vca-hero-engine {
  margin: 0 0 4px;
  opacity: 0.95;
  font-size: 0.95rem;
}

.vca-hero-sub {
  margin: 0;
  opacity: 0.82;
  font-size: 0.85rem;
  max-width: 820px;
}

.vca-body {
  padding: 0 24px;
}

.vca-module-layout {
  display: grid;
  grid-template-columns: minmax(300px, 38%) 1fr;
  gap: 20px;
  align-items: start;
}

.vca-module-layout--stack {
  grid-template-columns: 1fr;
}

@media (max-width: 960px) {
  .vca-module-layout {
    grid-template-columns: 1fr;
  }
}

.vca-card {
  background: #fff;
  border: 1px solid #e2e8f0;
}

.vca-result-card {
  min-height: 360px;
}

.vca-upload-zone {
  width: 100%;
  border: 2px dashed #ddd6fe;
  border-radius: 12px;
  background: #f5f3ff;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
}

.vca-upload-zone:hover {
  border-color: var(--vca-grape);
  background: #ede9fe;
}

.vca-upload-zone--audio {
  border-color: #c4b5fd;
}

.vca-upload-inner {
  padding: 28px 16px;
  text-align: center;
  color: #6d28d9;
}

.vca-upload-inner i {
  font-size: 28px;
  margin-bottom: 8px;
  display: block;
}

.vca-upload-inner p {
  margin: 0;
  font-size: 0.9rem;
}

.vca-upload-list {
  margin-top: 4px;
}

.vca-upload-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: #f1f5f9;
  border-radius: 8px;
  font-size: 0.85rem;
}

.vca-upload-size {
  margin-left: auto;
  color: #64748b;
  font-size: 0.8rem;
}

.vca-upload-empty {
  font-size: 0.85rem;
  color: #94a3b8;
}

.vca-status {
  margin-top: 4px;
}

.vca-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 280px;
  color: #94a3b8;
  text-align: center;
  gap: 12px;
}

.vca-empty-state i {
  font-size: 42px;
  opacity: 0.5;
}

.vca-empty-state--dark {
  color: #64748b;
  background: #0f172a;
  border-radius: 12px;
  min-height: 200px;
}

.vca-chart {
  width: 100%;
}

.vca-insight-card {
  margin-top: 12px;
  border-left: 4px solid var(--vca-grape);
}

/* 模块二：运动学视口 */
.vca-kine-viewport {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  max-height: 360px;
  border-radius: 12px;
  overflow: hidden;
  background: #0f172a;
  border: 1px solid #334155;
}

.vca-kine-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 45% 35% at 38% 52%, #475569 0%, transparent 70%),
    radial-gradient(ellipse 45% 35% at 62% 52%, #64748b 0%, transparent 70%),
    linear-gradient(180deg, #1e293b 0%, #0f172a 100%);
}

.vca-flow-overlay {
  position: absolute;
  inset: 0;
}

.vca-track-box {
  position: absolute;
  top: 38%;
  width: 22%;
  height: 28%;
  border: 2px solid;
  border-radius: 6px;
  font-size: 0.7rem;
  font-weight: 600;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 4px;
  pointer-events: none;
}

.vca-track-left {
  left: 24%;
  border-color: #a855f7;
  color: #c4b5fd;
  animation: vca-track-pulse 1.2s ease-in-out infinite;
}

.vca-track-right {
  right: 24%;
  border-color: #22d3ee;
  color: #67e8f9;
  animation: vca-track-pulse 1.2s ease-in-out infinite 0.3s;
}

.vca-kine-viewport--active .vca-track-left {
  animation: vca-track-scan 2s linear infinite;
}

.vca-kine-viewport--active .vca-track-right {
  animation: vca-track-scan 2s linear infinite reverse;
}

.vca-flow-field {
  position: absolute;
  inset: 0;
  opacity: 0;
  background-image:
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 18px,
      rgba(124, 58, 237, 0.08) 18px,
      rgba(124, 58, 237, 0.08) 19px
    ),
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 18px,
      rgba(34, 211, 238, 0.06) 18px,
      rgba(34, 211, 238, 0.06) 19px
    );
  background-size: 40px 40px;
}

.vca-kine-viewport--active .vca-flow-field {
  opacity: 1;
  animation: vca-flow-drift 3s linear infinite;
}

@keyframes vca-track-pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(168, 85, 247, 0.4); }
  50% { box-shadow: 0 0 12px 4px rgba(168, 85, 247, 0.25); }
}

@keyframes vca-track-scan {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

@keyframes vca-flow-drift {
  from { background-position: 0 0; }
  to { background-position: 40px 40px; }
}

.vca-kine-hud {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  background: rgba(15, 23, 42, 0.85);
  font-size: 0.75rem;
  color: #cbd5e1;
}

.vca-kine-graphs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 12px;
}

@media (max-width: 768px) {
  .vca-kine-graphs {
    grid-template-columns: 1fr;
  }
}

.vca-chart--dark {
  border-radius: 8px;
  overflow: hidden;
}

.vca-kine-diagnosis {
  margin-top: 12px;
}

.vca-kine-diagnosis--alert {
  font-weight: 600;
}

.vca-kine-diagnosis--alert .mantine-Alert-title,
.vca-kine-diagnosis--alert .mantine-Alert-message {
  color: #fff !important;
}

/* 模块三：特征闪现 */
.vca-feature-flash-wrap {
  min-height: 36px;
}

.vca-feature-flash {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  background: #1e1b4b;
  border-radius: 8px;
  color: #a5b4fc;
  font-size: 0.78rem;
  opacity: 0.7;
  transition: opacity 0.2s;
}

.vca-feature-flash--active {
  opacity: 1;
  animation: vca-flash-pulse 0.5s ease;
}

.vca-feature-flash code {
  font-family: "Cascadia Code", "Fira Code", monospace;
  color: #c4b5fd;
}

@keyframes vca-flash-pulse {
  0% { background: #312e81; }
  100% { background: #1e1b4b; }
}

.vca-m3-analyzing {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 320px;
  gap: 16px;
  text-align: center;
  color: #64748b;
}

.vca-audio-report {
  border-left: 4px solid var(--vca-grape);
}

.vca-metric-cell {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 6px 0;
}

.vca-metric-label {
  font-size: 0.75rem;
  color: #64748b;
}

.vca-metric-value {
  font-size: 0.95rem;
  color: #334155;
}
