/* =====================================================
   AI导演平台 - 完整样式
   配色: 背景#F5F7FA, 卡片#FFFFFF, 主按钮#FF6D00, 选中#8B5CF6
   ===================================================== */

/* ---- Reset & Base ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Microsoft YaHei', sans-serif; font-size: 14px; color: #1A1A1F; background: #F5F7FA; }

/* ---- 顶部导航栏 ---- */
.top-nav {
  position: fixed; top: 0; left: 0; right: 0; height: 56px;
  background: #fff; border-bottom: 1px solid #E8E9EF; display: flex;
  align-items: center; justify-content: space-between; padding: 0 20px;
  z-index: 1000; box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}
.top-nav-left { display: flex; align-items: center; gap: 32px; }
.logo { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: 16px; color: #1A1A1F; }
.logo span { color: #8B5CF6; }
.primary-nav { display: flex; gap: 4px; }
.nav-item {
  padding: 6px 14px; border: none; background: transparent;
  border-radius: 6px; cursor: pointer; font-size: 13px; color: #6B6B78;
  transition: all 0.2s; font-family: inherit;
}
.nav-item:hover { background: #F5F7FA; color: #1A1A1F; }
.nav-item.active { background: #8B5CF6; color: #fff; font-weight: 600; }
.top-nav-right { display: flex; align-items: center; gap: 8px; }
.btn-icon { width: 32px; height: 32px; border: none; background: transparent; border-radius: 6px; cursor: pointer; font-size: 16px; }
.btn-icon:hover { background: #F5F7FA; }
.user-avatar { width: 32px; height: 32px; background: #8B5CF6; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 700; font-size: 13px; }

/* ---- 右上角悬浮Agent头像 ---- */
.floating-agents {
  position: fixed; top: 68px; right: 20px; z-index: 999;
  display: flex; flex-direction: column; gap: 8px;
  background: rgba(255,255,255,0.95); border-radius: 12px;
  padding: 10px 8px; box-shadow: 0 4px 20px rgba(0,0,0,0.1);
  backdrop-filter: blur(10px);
}
.agent-pill { display: flex; align-items: center; gap: 6px; cursor: pointer; }
.agent-avatar {
  width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center;
  justify-content: center; font-size: 11px; font-weight: 700; color: #fff;
}
.agent-avatar.writer { background: #FF6D00; }
.agent-avatar.camera { background: #8B5CF6; }
.agent-avatar.style { background: #10B981; }
.agent-avatar.cut { background: #3B82F6; }
.agent-avatar.review { background: #EF4444; }
.agent-status {
  width: 8px; height: 8px; border-radius: 50%; border: 2px solid #fff;
}
.agent-status.online { background: #10B981; }
.agent-status.busy { background: #F59E0B; }
.agent-status.idle { background: #9CA3AF; }

/* ---- 主内容区 ---- */
.main-container {
  margin-top: 56px; padding: 20px; padding-bottom: 200px;
  min-height: calc(100vh - 56px); display: flex; flex-direction: column;
}
.module { display: none; flex-direction: column; gap: 16px; }
.module.active { display: flex; }
.module-header { display: flex; align-items: center; justify-content: space-between; padding-bottom: 8px; border-bottom: 1px solid #E8E9EF; }
.module-header h2 { font-size: 20px; font-weight: 700; color: #1A1A1F; }
.module-actions { display: flex; gap: 8px; }

/* ---- 通用面板 ---- */
.panel {
  background: #fff; border-radius: 12px; padding: 16px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}
.panel-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.panel-header h3, .panel-header h4 { font-size: 14px; font-weight: 600; color: #1A1A1F; }

/* ---- 按钮样式 ---- */
.btn-bracket {
  display: inline-flex; align-items: center; gap: 4px; padding: 8px 16px;
  background: #FF6D00; color: #fff; border: none; border-radius: 8px;
  cursor: pointer; font-size: 13px; font-weight: 600; font-family: inherit;
  transition: all 0.2s;
}
.btn-bracket:hover { background: #e55f00; }
.btn-bracket-sm {
  display: inline-flex; align-items: center; gap: 4px; padding: 5px 12px;
  background: #F5F7FA; color: #1A1A1F; border: 1px solid #E8E9EF;
  border-radius: 6px; cursor: pointer; font-size: 12px; font-family: inherit;
  transition: all 0.2s;
}
.btn-bracket-sm:hover { background: #E8E9EF; }
.btn-icon-sm { width: 28px; height: 28px; border: none; background: #F5F7FA; border-radius: 6px; cursor: pointer; font-size: 12px; }
.btn-close { width: 24px; height: 24px; border: none; background: #F5F7FA; border-radius: 50%; cursor: pointer; font-size: 12px; }
.generate-btn { width: 100%; justify-content: center; padding: 10px; font-size: 14px; }
.push-btn { width: 100%; justify-content: center; margin-top: 12px; }

/* ---- 标签 ---- */
.tag { padding: 2px 8px; border-radius: 4px; font-size: 11px; font-weight: 600; }
.tag-active { background: #DCFCE7; color: #16A34A; }
.tag-review { background: #FEF3C7; color: #D97706; }
.tag-done { background: #DBEAFE; color: #2563EB; }
.tag-sm { padding: 1px 6px; background: #F5F7FA; border-radius: 4px; font-size: 10px; color: #6B6B78; margin-right: 4px; }

/* ---- Agent芯片 ---- */
.agent-chip {
  display: inline-flex; align-items: center; justify-content: center;
  width: 20px; height: 20px; border-radius: 50%; font-size: 10px;
  font-weight: 700; color: #fff;
}
.agent-chip.writer { background: #FF6D00; }
.agent-chip.camera { background: #8B5CF6; }
.agent-chip.style { background: #10B981; }
.agent-chip.cut { background: #3B82F6; }
.agent-chip.review { background: #EF4444; }

/* ---- 工作台首页 ---- */
.dashboard-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 16px; }
.stat-cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; grid-column: 1 / -1; }
.stat-card {
  background: #fff; border-radius: 12px; padding: 16px;
  display: flex; align-items: center; gap: 12px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}
.stat-icon { font-size: 24px; }
.stat-num { font-size: 24px; font-weight: 700; color: #1A1A1F; }
.stat-label { font-size: 12px; color: #6B6B78; margin-top: 2px; }
.dashboard-right { display: flex; flex-direction: column; gap: 16px; }

/* 项目卡片 */
.project-list { display: flex; flex-direction: column; gap: 10px; }
.project-card {
  display: flex; align-items: center; gap: 12px; padding: 12px;
  background: #F5F7FA; border-radius: 8px; cursor: pointer;
  transition: all 0.2s;
}
.project-card:hover { background: #ECEEF3; }
.project-thumb { width: 60px; height: 40px; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 10px; color: rgba(255,255,255,0.8); }
.project-info { flex: 1; }
.project-name { font-weight: 600; font-size: 13px; margin-bottom: 4px; }
.project-meta { font-size: 11px; color: #6B6B78; margin-bottom: 4px; }
.project-agents { display: flex; gap: 4px; }
.quick-btns { display: flex; flex-direction: column; gap: 8px; }
.quick-btns .btn-bracket { justify-content: center; }

/* Agent动态 */
.agent-feed { display: flex; flex-direction: column; gap: 8px; }
.feed-item { display: flex; align-items: center; gap: 8px; font-size: 12px; }
.feed-text { flex: 1; color: #1A1A1F; }
.feed-time { font-size: 10px; color: #9CA3AF; }

/* ---- AI解析工作台 ---- */
.analysis-layout { display: grid; grid-template-columns: 240px 1fr 280px; gap: 16px; min-height: 600px; }
.left-panel {
  background: #fff; border-radius: 12px; padding: 16px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06); overflow-y: auto; max-height: calc(100vh - 180px);
}
.material-list { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.material-item {
  display: flex; align-items: center; gap: 8px; padding: 8px;
  border-radius: 8px; cursor: pointer; transition: all 0.2s;
}
.material-item:hover, .material-item.selected { background: #F5F7FA; }
.material-item.selected { border-left: 3px solid #8B5CF6; }
.material-thumb { width: 32px; height: 24px; background: #E8E9EF; border-radius: 4px; display: flex; align-items: center; justify-content: center; font-size: 12px; }
.material-info { flex: 1; }
.material-name { font-size: 11px; font-weight: 600; }
.material-tags { display: flex; gap: 4px; margin-top: 2px; }
.material-score { font-size: 12px; font-weight: 700; color: #8B5CF6; }
.filter-section { margin-top: 12px; }
.filter-title { font-size: 11px; font-weight: 600; color: #6B6B78; margin-bottom: 8px; text-transform: uppercase; letter-spacing: 0.5px; }
.filter-tags { display: flex; flex-wrap: wrap; gap: 4px; }
.tag-filter { padding: 3px 8px; background: #F5F7FA; border-radius: 4px; font-size: 11px; cursor: pointer; }
.tag-filter.active { background: #8B5CF6; color: #fff; }
.score-slider { width: 100%; }
.score-label { font-size: 11px; color: #6B6B78; margin-top: 4px; }
.stats-section { margin-top: 16px; border-top: 1px solid #E8E9EF; padding-top: 12px; }
.stats-title { font-size: 11px; font-weight: 600; color: #6B6B78; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 8px; }
.stats-row { display: flex; justify-content: space-between; font-size: 12px; padding: 4px 0; color: #6B6B78; }

/* 主工作区 */
.work-area { display: flex; flex-direction: column; gap: 12px; }
.video-preview-panel { background: #fff; border-radius: 12px; padding: 16px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.video-player { position: relative; }
.video-placeholder {
  background: linear-gradient(135deg, #1A1A1F 0%, #2D2D3A 100%);
  height: 280px; border-radius: 8px; display: flex; align-items: center;
  justify-content: center; color: rgba(255,255,255,0.5); font-size: 16px; cursor: pointer;
}
.playback-controls {
  display: flex; align-items: center; gap: 8px; margin-top: 10px;
}
.ctrl-btn { width: 28px; height: 28px; border: none; background: #F5F7FA; border-radius: 50%; cursor: pointer; font-size: 12px; display: flex; align-items: center; justify-content: center; }
.ctrl-btn:hover { background: #E8E9EF; }
.play-btn { background: #8B5CF6; color: #fff; }
.progress-bar { flex: 1; height: 4px; background: #E8E9EF; border-radius: 2px; overflow: hidden; }
.progress-fill { height: 100%; background: #8B5CF6; border-radius: 2px; transition: width 0.3s; }
.time-display { font-size: 11px; color: #6B6B78; white-space: nowrap; }
.timecode { font-size: 11px; color: #9CA3AF; font-family: monospace; }

/* 解析配置 */
.parse-config { margin-top: 12px; padding-top: 12px; border-top: 1px solid #E8E9EF; }
.config-title { font-size: 12px; font-weight: 600; margin-bottom: 8px; }
.mode-tabs { display: flex; gap: 4px; margin-bottom: 8px; }
.mode-tab { padding: 5px 12px; border: 1px solid #E8E9EF; background: #F5F7FA; border-radius: 6px; cursor: pointer; font-size: 12px; font-family: inherit; }
.mode-tab.active { background: #FF6D00; color: #fff; border-color: #FF6D00; }
.progress-bar-parse { height: 6px; background: #E8E9EF; border-radius: 3px; overflow: hidden; margin-bottom: 4px; }
.progress-label { font-size: 11px; color: #6B6B78; }

/* 视图切换 */
.view-tabs-bar { display: flex; gap: 4px; background: #fff; border-radius: 8px; padding: 6px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.view-tab { padding: 6px 14px; border: none; background: transparent; border-radius: 6px; cursor: pointer; font-size: 12px; font-weight: 600; color: #6B6B78; font-family: inherit; transition: all 0.2s; }
.view-tab.active { background: #8B5CF6; color: #fff; }
.view-content { display: none; }
.view-content.active { display: block; }

/* 语义地图 */
.semantic-map { background: #fff; border-radius: 12px; padding: 20px; min-height: 300px; position: relative; box-shadow: 0 1px 4px rgba(0,0,0,0.06); overflow: hidden; }
.map-node { position: absolute; text-align: center; cursor: pointer; }
.node-circle { width: 48px; height: 48px; border-radius: 50%; margin: 0 auto 6px; opacity: 0.85; border: 3px solid rgba(255,255,255,0.8); box-shadow: 0 2px 8px rgba(0,0,0,0.2); }
.node-label { font-size: 11px; font-weight: 600; color: #1A1A1F; background: #fff; padding: 2px 6px; border-radius: 4px; box-shadow: 0 1px 3px rgba(0,0,0,0.1); }
.node-emotion { font-size: 10px; color: #6B6B78; margin-top: 2px; }
.node-duration { font-size: 10px; color: #9CA3AF; }

/* 时间线视图 */
.timeline-view { background: #fff; border-radius: 12px; padding: 16px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.timeline-row { display: flex; flex-direction: column; gap: 8px; }
.shot-card {
  display: flex; align-items: center; gap: 12px; padding: 10px 14px;
  border: 1px solid #E8E9EF; border-radius: 8px; cursor: pointer;
  transition: all 0.2s;
}
.shot-card:hover { border-color: #8B5CF6; box-shadow: 0 2px 8px rgba(139,92,246,0.1); }
.shot-thumb { width: 48px; height: 36px; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; color: rgba(255,255,255,0.9); }
.shot-info { flex: 1; }
.shot-title { font-size: 12px; font-weight: 600; }
.shot-meta { font-size: 11px; color: #6B6B78; margin-top: 2px; }
.shot-emotion { font-size: 11px; color: #8B5CF6; margin-top: 2px; }
.shot-score { font-size: 16px; font-weight: 700; color: #8B5CF6; }

/* 标签云 */
.tag-cloud { background: #fff; border-radius: 12px; padding: 24px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: center; min-height: 200px; }
.cloud-tag { cursor: pointer; transition: all 0.2s; }
.cloud-tag:hover { opacity: 0.7; text-decoration: underline; }

/* 镜头列表 */
.shot-table { width: 100%; border-collapse: collapse; background: #fff; border-radius: 12px; overflow: hidden; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.shot-table th { background: #F5F7FA; padding: 10px 12px; text-align: left; font-size: 11px; font-weight: 600; color: #6B6B78; text-transform: uppercase; letter-spacing: 0.5px; }
.shot-table td { padding: 10px 12px; font-size: 12px; border-top: 1px solid #F5F7FA; }
.shot-table tr:hover td { background: #F5F7FA; }
.score-hi { color: #10B981; font-weight: 700; }
.score-mid { color: #F59E0B; font-weight: 700; }

/* 右侧弹出 */
.right-popup { background: #fff; border-radius: 12px; padding: 16px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); overflow-y: auto; max-height: calc(100vh - 180px); }
.shot-detail-content { display: flex; flex-direction: column; gap: 8px; }
.detail-thumb { height: 120px; background: linear-gradient(135deg, #FF6D00, #8B5CF6); border-radius: 8px; display: flex; align-items: center; justify-content: center; color: rgba(255,255,255,0.8); font-size: 12px; }
.detail-row { display: flex; justify-content: space-between; font-size: 12px; padding: 4px 0; border-bottom: 1px solid #F5F7FA; }
.detail-row span:first-child { color: #6B6B78; }
.detail-row span:last-child { font-weight: 600; }

/* ---- AI导演工作台 ---- */
.director-layout { display: grid; grid-template-columns: 240px 1fr; gap: 16px; }
.intent-form { display: flex; flex-direction: column; gap: 12px; }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label { font-size: 11px; font-weight: 600; color: #6B6B78; text-transform: uppercase; letter-spacing: 0.5px; }
.form-input { padding: 8px 10px; border: 1px solid #E8E9EF; border-radius: 6px; font-size: 12px; font-family: inherit; outline: none; transition: border 0.2s; }
.form-input:focus { border-color: #8B5CF6; }
.form-textarea { padding: 8px 10px; border: 1px solid #E8E9EF; border-radius: 6px; font-size: 12px; font-family: inherit; outline: none; resize: vertical; min-height: 80px; transition: border 0.2s; }
.form-textarea:focus { border-color: #8B5CF6; }
.form-select { padding: 8px 10px; border: 1px solid #E8E9EF; border-radius: 6px; font-size: 12px; font-family: inherit; background: #fff; outline: none; cursor: pointer; }
.type-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.type-chip { padding: 4px 10px; border: 1px solid #E8E9EF; background: #F5F7FA; border-radius: 16px; cursor: pointer; font-size: 12px; font-family: inherit; }
.type-chip.active { background: #8B5CF6; color: #fff; border-color: #8B5CF6; }
.agent-monitor { background: #F5F7FA; border-radius: 8px; padding: 12px; }
.monitor-title { font-size: 11px; font-weight: 600; color: #6B6B78; margin-bottom: 8px; }
.agent-monitor-row { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; font-size: 12px; }
.agent-progress { flex: 1; height: 4px; background: #E8E9EF; border-radius: 2px; overflow: hidden; }

/* 叙事弧线 */
.narrative-arc-panel { background: #fff; border-radius: 12px; padding: 16px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.arc-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.arc-header h4 { font-size: 14px; font-weight: 600; }
.arc-legend { display: flex; gap: 12px; }
.arc-legend-item { font-size: 11px; color: #6B6B78; }
.narrative-arc {
  position: relative; height: 160px; display: flex;
  align-items: flex-end; padding-bottom: 24px;
}
.arc-segment { position: relative; display: flex; flex-direction: column; align-items: center; border-left: 1px dashed #E8E9EF; cursor: pointer; }
.arc-bar { width: 80%; border-radius: 4px 4px 0 0; transition: height 0.3s; min-height: 8px; }
.arc-label { font-size: 12px; font-weight: 700; color: #6B6B78; margin-top: 6px; position: absolute; bottom: 0; }
.arc-handle { position: absolute; width: 10px; height: 10px; background: #8B5CF6; border-radius: 50%; top: 50%; transform: translate(-50%, -50%); cursor: grab; border: 2px solid #fff; box-shadow: 0 1px 4px rgba(0,0,0,0.2); }
.arc-x-axis { position: absolute; bottom: 0; left: 0; right: 0; display: flex; justify-content: space-between; font-size: 10px; color: #9CA3AF; }

/* 分镜脚本 */
.storyboard-panel { background: #fff; border-radius: 12px; padding: 16px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.version-tag { font-size: 11px; background: #FEF3C7; color: #D97706; padding: 2px 8px; border-radius: 4px; font-weight: 600; }
.storyboard { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; margin-top: 8px; }
.storyboard-card {
  border: 1px solid #E8E9EF; border-radius: 8px; padding: 12px;
  display: flex; flex-direction: column; gap: 8px; position: relative;
  transition: all 0.2s;
}
.storyboard-card.unmatched { border: 2px dashed #EF4444; background: #FEF2F2; }
.storyboard-thumb { width: 48px; height: 36px; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; color: rgba(255,255,255,0.9); align-self: flex-start; }
.storyboard-desc { flex: 1; }
.storyboard-title { font-size: 12px; font-weight: 600; margin-bottom: 4px; }
.storyboard-text { font-size: 11px; color: #6B6B78; line-height: 1.4; }
.storyboard-tags { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 6px; }
.storyboard-transition { font-size: 10px; color: #9CA3AF; margin-top: 4px; }
.storyboard-match { font-size: 11px; font-weight: 600; padding: 2px 8px; border-radius: 4px; align-self: flex-start; }
.storyboard-match.matched { background: #DCFCE7; color: #16A34A; }
.storyboard-match.unmatched { background: #FEE2E2; color: #DC2626; }
.ai-generate { margin-top: 6px; width: 100%; justify-content: center; }

/* Agent协同面板 */
.agent-collab-panel { background: #fff; border-radius: 12px; padding: 14px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.collab-header { font-size: 12px; font-weight: 600; color: #6B6B78; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 10px; }
.collab-stats { display: flex; gap: 16px; margin-bottom: 12px; }
.collab-stat { display: flex; flex-direction: column; gap: 2px; }
.collab-label { font-size: 10px; color: #9CA3AF; }
.collab-value { font-size: 14px; font-weight: 700; color: #1A1A1F; }
.collab-agents { display: flex; flex-direction: column; gap: 6px; }
.collab-agent { display: flex; align-items: center; gap: 8px; font-size: 12px; }
.collab-agent span:first-of-type { font-size: 11px; color: #6B6B78; min-width: 60px; }
.mini-bar { flex: 1; height: 4px; background: #E8E9EF; border-radius: 2px; overflow: hidden; }
.mini-fill { height: 100%; background: #8B5CF6; border-radius: 2px; }

/* ---- AI生成工作台 ---- */
.generation-layout { display: grid; grid-template-columns: 240px 1fr 240px; gap: 16px; }
.right-panel { background: #fff; border-radius: 12px; padding: 16px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); overflow-y: auto; max-height: calc(100vh - 180px); }
.prompt-section, .param-section { display: flex; flex-direction: column; gap: 10px; }
.param-section { margin-top: 12px; padding-top: 12px; border-top: 1px solid #E8E9EF; }
.ratio-chips { display: flex; gap: 4px; }
.ratio-chip { padding: 4px 10px; border: 1px solid #E8E9EF; background: #F5F7FA; border-radius: 6px; cursor: pointer; font-size: 12px; font-family: inherit; }
.ratio-chip.active { background: #8B5CF6; color: #fff; border-color: #8B5CF6; }
.gen-header-tabs { display: flex; gap: 4px; background: #fff; border-radius: 8px; padding: 6px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); margin-bottom: 12px; }
.gen-tab { padding: 6px 14px; border: none; background: transparent; border-radius: 6px; cursor: pointer; font-size: 12px; font-weight: 600; color: #6B6B78; font-family: inherit; }
.gen-tab.active { background: #FF6D00; color: #fff; }
.gen-preview-area { display: grid; grid-template-columns: 1fr; gap: 12px; }
.gen-preview-main { background: #fff; border-radius: 12px; padding: 16px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.gen-placeholder {
  background: linear-gradient(135deg, #1A1A1F, #2D2D3A);
  height: 280px; border-radius: 8px; display: flex; flex-direction: column;
  align-items: center; justify-content: center; color: rgba(255,255,255,0.4);
  font-size: 16px; gap: 8px;
}
.gen-status { font-size: 12px; color: rgba(255,255,255,0.5); margin-top: 4px; }
.gen-versions { background: #fff; border-radius: 12px; padding: 14px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.version-label { font-size: 12px; font-weight: 600; color: #6B6B78; margin-bottom: 8px; }
.version-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.version-card { border: 2px solid #E8E9EF; border-radius: 8px; overflow: hidden; cursor: pointer; text-align: center; transition: border 0.2s; }
.version-card:hover, .version-card.selected { border-color: #8B5CF6; }
.version-card > div:first-child { font-size: 11px; padding: 4px; background: #F5F7FA; }
.ver-thumb { height: 50px; display: flex; align-items: center; justify-content: center; font-size: 14px; font-weight: 700; color: rgba(255,255,255,0.8); }
.inpaint-area { background: #fff; border-radius: 12px; padding: 14px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.inpaint-label { font-size: 12px; font-weight: 600; color: #6B6B78; margin-bottom: 8px; }
.inpaint-canvas { height: 80px; background: #F5F7FA; border: 2px dashed #E8E9EF; border-radius: 8px; display: flex; align-items: center; justify-content: center; color: #9CA3AF; font-size: 13px; cursor: pointer; }

/* 右侧增强 */
.enhance-section { display: flex; flex-direction: column; gap: 10px; }
.enhance-item { padding: 10px; background: #F5F7FA; border-radius: 8px; }
.enhance-title { font-size: 12px; font-weight: 600; margin-bottom: 4px; }
.enhance-desc { font-size: 11px; color: #6B6B78; margin-bottom: 6px; }
.gen-queue, .temp-pool { margin-top: 12px; }
.queue-title, .pool-title { font-size: 11px; font-weight: 600; color: #6B6B78; text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 8px; }
.queue-item, .pool-item { display: flex; justify-content: space-between; align-items: center; padding: 6px 8px; border-radius: 6px; font-size: 11px; cursor: pointer; }
.queue-item:hover, .pool-item:hover { background: #F5F7FA; }
.queue-item.active { background: #FEF3C7; color: #D97706; }
.queue-progress { font-size: 10px; color: #9CA3AF; }
.pool-items { display: flex; flex-direction: column; gap: 4px; }
.pool-item { background: #F5F7FA; }

/* ---- AI剪辑工作台 ---- */
.editing-layout { display: grid; grid-template-columns: 240px 1fr 240px; gap: 16px; }
.material-filter-tabs { display: flex; gap: 4px; flex-wrap: wrap; margin-bottom: 12px; }
.mat-tab { padding: 3px 8px; border: 1px solid #E8E9EF; background: #F5F7FA; border-radius: 4px; cursor: pointer; font-size: 11px; font-family: inherit; }
.mat-tab.active { background: #8B5CF6; color: #fff; border-color: #8B5CF6; }
.project-material-list { display: flex; flex-direction: column; gap: 4px; margin-bottom: 12px; }
.proj-mat-item { display: flex; align-items: center; gap: 8px; padding: 6px; border-radius: 6px; cursor: pointer; }
.proj-mat-item:hover { background: #F5F7FA; }
.proj-mat-thumb { width: 28px; height: 20px; background: #E8E9EF; border-radius: 4px; display: flex; align-items: center; justify-content: center; font-size: 11px; }
.proj-mat-name { font-size: 11px; font-weight: 600; }
.proj-mat-meta { font-size: 10px; color: #9CA3AF; }
.cut-tools { margin-top: 8px; padding-top: 8px; border-top: 1px solid #E8E9EF; }
.tools-title { font-size: 11px; font-weight: 600; color: #6B6B78; margin-bottom: 8px; }
.tool-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; }
.tool-btn { width: 100%; aspect-ratio: 1; border: 1px solid #E8E9EF; background: #F5F7FA; border-radius: 6px; cursor: pointer; font-size: 14px; display: flex; align-items: center; justify-content: center; }
.tool-btn:hover { background: #E8E9EF; }
.agent-status-bar { margin-top: 12px; }
.astatus-title { font-size: 11px; font-weight: 600; color: #6B6B78; margin-bottom: 6px; }
.astatus-row { display: flex; align-items: center; gap: 6px; font-size: 11px; padding: 3px 0; }
.center-area { display: flex; flex-direction: column; gap: 12px; }
.smart-timeline {
  background: #fff; border-radius: 12px; padding: 16px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06); position: relative;
}
.timeline-track { display: flex; align-items: center; margin-bottom: 8px; }
.track-label { width: 56px; font-size: 10px; font-weight: 700; color: #6B6B78; text-transform: uppercase; letter-spacing: 0.5px; flex-shrink: 0; }
.track-content { flex: 1; height: 32px; background: #F5F7FA; border-radius: 6px; position: relative; overflow: visible; }
.clip-card {
  position: absolute; height: 28px; top: 2px; border-radius: 6px;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 8px; font-size: 10px; color: rgba(255,255,255,0.9); font-weight: 600;
  cursor: pointer; box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}
.clip-emotion { font-size: 12px; }
.extend-handle {
  position: absolute; width: 6px; height: 100%; background: rgba(255,255,255,0.3);
  cursor: ew-resize; border-radius: 3px;
}
.extend-handle.right { right: 0; top: 0; }
.inpaint-layer { position: absolute; top: 0; left: 0; right: 0; bottom: 0; border: 2px dashed #8B5CF6; border-radius: 6px; pointer-events: none; opacity: 0.5; }
.prompt-track { position: absolute; top: -8px; height: 6px; background: #FF6D00; border-radius: 3px; width: 10%; opacity: 0.7; }
.subtitle-marker { position: absolute; height: 20px; top: 6px; background: #F59E0B; border-radius: 4px; display: flex; align-items: center; justify-content: center; font-size: 9px; color: #fff; font-weight: 600; cursor: pointer; }
.marker-dot { position: absolute; width: 8px; height: 8px; background: #EF4444; border-radius: 50%; top: 50%; transform: translateY(-50%); cursor: pointer; }
.lock-indicator { position: absolute; top: 8px; right: 8px; font-size: 14px; cursor: pointer; }

/* 右侧剪辑Agent */
.cut-agent-panel { display: flex; flex-direction: column; gap: 8px; }
.cut-agent-item { padding: 10px; background: #F5F7FA; border-radius: 8px; }
.cut-agent-header { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; margin-bottom: 4px; }
.cut-agent-desc { font-size: 11px; color: #6B6B78; padding-left: 26px; }
.quality-meter { padding-left: 26px; margin-top: 4px; }
.q-bar { height: 6px; background: #E8E9EF; border-radius: 3px; overflow: hidden; margin-bottom: 4px; }
.q-fill { height: 100%; background: linear-gradient(90deg, #EF4444, #F59E0B, #10B981); border-radius: 3px; }
.quality-meter span { font-size: 10px; color: #6B6B78; }

/* ---- 素材资产中心 ---- */
.assets-layout { display: flex; flex-direction: column; gap: 12px; }
.assets-topbar { background: #fff; border-radius: 12px; padding: 14px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.search-box { margin-bottom: 12px; }
.search-input { width: 100%; padding: 10px 14px; border: 1px solid #E8E9EF; border-radius: 8px; font-size: 13px; font-family: inherit; outline: none; }
.search-input:focus { border-color: #8B5CF6; }
.filter-row { display: flex; gap: 16px; flex-wrap: wrap; align-items: center; margin-bottom: 10px; }
.filter-group { display: flex; align-items: center; gap: 8px; }
.filter-label { font-size: 11px; font-weight: 600; color: #6B6B78; white-space: nowrap; }
.filter-chips { display: flex; gap: 4px; }
.filter-chip { padding: 3px 10px; border: 1px solid #E8E9EF; background: #F5F7FA; border-radius: 16px; cursor: pointer; font-size: 11px; font-family: inherit; }
.filter-chip.active { background: #8B5CF6; color: #fff; border-color: #8B5CF6; }
.filter-select { padding: 4px 8px; border: 1px solid #E8E9EF; border-radius: 6px; font-size: 11px; font-family: inherit; background: #fff; cursor: pointer; }
.view-switch-bar { display: flex; gap: 4px; }
.view-switch-btn { padding: 5px 12px; border: none; background: transparent; border-radius: 6px; cursor: pointer; font-size: 12px; font-weight: 600; color: #6B6B78; font-family: inherit; }
.view-switch-btn.active { background: #FF6D00; color: #fff; }
.asset-stats { display: flex; gap: 24px; }
.asset-stat { display: flex; align-items: center; gap: 8px; font-size: 13px; color: #6B6B78; }
.asset-stat strong { font-size: 18px; font-weight: 700; color: #1A1A1F; }
.asset-library-tabs { display: flex; gap: 4px; }
.lib-tab { padding: 8px 16px; border: 1px solid #E8E9EF; background: #fff; border-radius: 8px; cursor: pointer; font-size: 13px; font-weight: 600; color: #6B6B78; font-family: inherit; }
.lib-tab.active { background: #8B5CF6; color: #fff; border-color: #8B5CF6; }
.asset-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; }
.asset-card {
  background: #fff; border-radius: 10px; overflow: hidden;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06); cursor: pointer;
  transition: all 0.2s; border: 1px solid transparent;
}
.asset-card:hover { border-color: #8B5CF6; box-shadow: 0 4px 12px rgba(139,92,246,0.15); transform: translateY(-2px); }
.asset-thumb { height: 100px; display: flex; align-items: center; justify-content: center; font-size: 28px; color: rgba(255,255,255,0.8); }
.asset-info { padding: 10px; }
.asset-name { font-size: 12px; font-weight: 600; margin-bottom: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.asset-tags { display: flex; gap: 4px; flex-wrap: wrap; margin-bottom: 4px; }
.asset-score { font-size: 11px; color: #F59E0B; font-weight: 600; }

/* ---- 设置与管理 ---- */
.settings-layout { display: flex; gap: 16px; }
.settings-nav { display: flex; flex-direction: column; gap: 4px; width: 180px; flex-shrink: 0; }
.settings-nav-item { padding: 8px 14px; border: none; background: transparent; border-radius: 8px; cursor: pointer; font-size: 13px; font-weight: 600; color: #6B6B78; text-align: left; font-family: inherit; transition: all 0.2s; }
.settings-nav-item:hover { background: #F5F7FA; }
.settings-nav-item.active { background: #8B5CF6; color: #fff; }
.settings-panel { display: none; flex-direction: column; gap: 12px; flex: 1; background: #fff; border-radius: 12px; padding: 20px; box-shadow: 0 1px 4px rgba(0,0,0,0.06); }
.settings-panel.active { display: flex; }
.settings-panel h4 { font-size: 16px; font-weight: 700; color: #1A1A1F; padding-bottom: 8px; border-bottom: 1px solid #E8E9EF; }
.settings-table { width: 100%; border-collapse: collapse; }
.settings-table th { text-align: left; padding: 8px 10px; font-size: 11px; font-weight: 600; color: #6B6B78; text-transform: uppercase; letter-spacing: 0.5px; border-bottom: 2px solid #E8E9EF; }
.settings-table td { padding: 10px; font-size: 12px; border-bottom: 1px solid #F5F7FA; vertical-align: middle; }
.member-cell { display: flex; align-items: center; gap: 8px; }
.member-avatar { width: 28px; height: 28px; border-radius: 50%; background: #8B5CF6; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 11px; font-weight: 700; }
.role-tag { padding: 2px 8px; border-radius: 4px; font-size: 11px; font-weight: 600; }
.role-tag.owner { background: #FEF3C7; color: #D97706; }
.role-tag.admin { background: #DBEAFE; color: #2563EB; }
.role-tag.director { background: #E0E7FF; color: #4F46E5; }
.role-tag.external { background: #F5F7FA; color: #6B6B78; }
.brand-config { display: flex; flex-direction: column; gap: 12px; }
.brand-color-row { display: flex; align-items: center; gap: 8px; }
.color-swatch { width: 28px; height: 28px; border-radius: 6px; cursor: pointer; border: 2px solid rgba(0,0,0,0.1); }
.lut-chips { display: flex; gap: 6px; }
.lut-chip { padding: 5px 12px; border: 1px solid #E8E9EF; background: #F5F7FA; border-radius: 6px; cursor: pointer; font-size: 12px; font-family: inherit; }
.lut-chip.active { background: #8B5CF6; color: #fff; border-color: #8B5CF6; }
.template-preview { display: flex; gap: 8px; }
.template-item { width: 60px; height: 40px; background: #E8E9EF; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 10px; cursor: pointer; border: 2px solid transparent; }
.template-item.selected { border-color: #8B5CF6; background: #EDE9FE; color: #8B5CF6; font-weight: 600; }
.watermark-config { display: flex; gap: 16px; align-items: center; }
.watermark-position, .watermark-opacity { display: flex; align-items: center; gap: 8px; font-size: 12px; }
.subtitle-preview { padding: 10px 14px; background: #F5F7FA; border-radius: 6px; font-size: 12px; color: #1A1A1F; }
.export-preset { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.multi-version-export { grid-column: 1 / -1; background: #F5F7FA; border-radius: 8px; padding: 12px; }
.mv-title { font-size: 12px; font-weight: 600; margin-bottom: 8px; }
.mv-check { display: flex; align-items: center; gap: 6px; font-size: 12px; cursor: pointer; margin-bottom: 4px; }
.export-actions { grid-column: 1 / -1; display: flex; gap: 8px; flex-wrap: wrap; }
.api-key-section { display: flex; flex-direction: column; gap: 8px; }
.api-key-display { display: flex; align-items: center; gap: 8px; padding: 10px 12px; background: #F5F7FA; border-radius: 8px; font-family: monospace; font-size: 13px; }
.api-key-masked { flex: 1; color: #6B6B78; }
.webhook-config { display: flex; flex-direction: column; gap: 10px; }
.event-checks { display: flex; flex-wrap: wrap; gap: 12px; }
.event-checks label { display: flex; align-items: center; gap: 6px; font-size: 12px; cursor: pointer; }
.usage-monitor { display: flex; flex-direction: column; gap: 12px; }
.usage-item { display: flex; align-items: center; gap: 10px; }
.usage-label { width: 100px; font-size: 12px; color: #6B6B78; }
.usage-bar { flex: 1; height: 8px; background: #E8E9EF; border-radius: 4px; overflow: hidden; }
.usage-fill { height: 100%; background: linear-gradient(90deg, #8B5CF6, #FF6D00); border-radius: 4px; }
.usage-item span { font-size: 11px; color: #6B6B78; min-width: 80px; }

/* ---- 底部面板 ---- */
.bottom-panel {
  position: fixed; bottom: 0; left: 0; right: 0; height: 180px;
  background: #fff; border-top: 1px solid #E8E9EF;
  box-shadow: 0 -2px 12px rgba(0,0,0,0.08); z-index: 998;
  display: flex; flex-direction: column;
  transition: height 0.3s ease;
}
.bottom-panel.collapsed { height: 36px; overflow: hidden; }
.bottom-panel-tabs { display: flex; align-items: center; gap: 4px; padding: 6px 16px; border-bottom: 1px solid #E8E9EF; height: 36px; flex-shrink: 0; }
.bp-tab { padding: 4px 10px; border: none; background: transparent; border-radius: 4px; cursor: pointer; font-size: 12px; font-weight: 600; color: #6B6B78; font-family: inherit; }
.bp-tab.active { background: #8B5CF6; color: #fff; }
.bp-collapse { margin-left: auto; width: 24px; height: 24px; border: none; background: #F5F7FA; border-radius: 4px; cursor: pointer; font-size: 10px; }
.bottom-panel-content { flex: 1; overflow-y: auto; padding: 12px 16px; }
.bp-content { display: none; }
.bp-content.active { display: block; }

/* 底部时间线 */
.bp-timeline-mini { display: flex; align-items: center; height: 60px; position: relative; }
.btm-clip { position: absolute; height: 44px; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 10px; color: rgba(255,255,255,0.9); font-weight: 600; cursor: pointer; box-shadow: 0 1px 4px rgba(0,0,0,0.15); }

/* 底部Agent对话 */
.bp-dialog { display: flex; flex-direction: column; height: 100%; }
.dialog-messages { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; }
.dialog-msg { display: flex; align-items: flex-start; gap: 8px; }
.dialog-msg.bot { }
.dialog-msg.user { flex-direction: row-reverse; }
.msg-bubble { max-width: 70%; padding: 8px 12px; border-radius: 10px; font-size: 12px; line-height: 1.5; }
.bot .msg-bubble { background: #F5F7FA; color: #1A1A1F; border-bottom-left-radius: 2px; }
.user-msg { background: #8B5CF6; color: #fff; border-bottom-right-radius: 2px; }
.dialog-input-area { display: flex; gap: 8px; margin-top: 8px; }
.dialog-input { flex: 1; padding: 8px 12px; border: 1px solid #E8E9EF; border-radius: 8px; font-size: 12px; font-family: inherit; outline: none; }
.dialog-input:focus { border-color: #8B5CF6; }

/* 底部审核报告 */
.bp-report { display: flex; gap: 20px; align-items: center; height: 100%; }
.report-summary { text-align: center; }
.report-score { font-size: 36px; font-weight: 700; color: #10B981; }
.report-score span { font-size: 18px; color: #6B6B78; }
.report-label { font-size: 11px; color: #6B6B78; margin-top: 4px; }
.report-items { flex: 1; display: flex; flex-wrap: wrap; gap: 6px; }
.report-item { padding: 5px 10px; border-radius: 6px; font-size: 11px; font-weight: 600; }
.report-item.pass { background: #DCFCE7; color: #16A34A; }
.report-item.warn { background: #FEF3C7; color: #D97706; }

/* ---- Toast ---- */
.toast {
  position: fixed; bottom: 200px; left: 50%; transform: translateX(-50%);
  background: #1A1A1F; color: #fff; padding: 10px 20px; border-radius: 8px;
  font-size: 13px; font-weight: 500; z-index: 9999; opacity: 0;
  transition: opacity 0.3s; pointer-events: none;
}
.toast.show { opacity: 1; }

/* ---- Responsive ---- */
@media (max-width: 1200px) {
  .dashboard-grid { grid-template-columns: 1fr 1fr; }
  .stat-cards { grid-column: 1 / -1; }
  .analysis-layout { grid-template-columns: 220px 1fr; }
  .right-popup { display: none; }
  .director-layout { grid-template-columns: 220px 1fr; }
  .generation-layout { grid-template-columns: 220px 1fr; }
  .editing-layout { grid-template-columns: 220px 1fr; }
}
@media (max-width: 768px) {
  .primary-nav { display: none; }
  .floating-agents { display: none; }
  .dashboard-grid { grid-template-columns: 1fr; }
  .stat-cards { grid-template-columns: repeat(2, 1fr); }
  .analysis-layout, .director-layout, .generation-layout, .editing-layout { grid-template-columns: 1fr; }
  .settings-layout { flex-direction: column; }
  .settings-nav { width: 100%; flex-direction: row; flex-wrap: wrap; }
  .asset-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
}