/* ===== RESET & BASE ===== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg-primary: #0D0E12;
  --bg-grid: #23262D;
  --bg-cell: #1A1D26;
  --bg-input: #161820;
  --red: #EC0928;
  --blue: #00E5FF;
  --green: #39FF14;
  --gray: #6F655F;
  --white: #E8E6E3;
  --gold-start: #FFD700;
  --gold-end: #D4AF37;
  --radius: 6px;
  --font-mono: 'JetBrains Mono', 'Courier New', monospace;
  --font-title: 'Inter', 'Noto Sans SC', sans-serif;
  --font-body: 'Noto Sans SC', 'Inter', sans-serif;
}

html { font-size: 14px; line-height: 1.6; }

body {
  background: var(--bg-primary);
  color: var(--white);
  font-family: var(--font-body);
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

/* ===== GRID BACKGROUND ===== */
.grid-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(var(--bg-grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--bg-grid) 1px, transparent 1px);
  background-size: 40px 40px;
  opacity: 0.5;
}

/* ===== MODULE-00 HERO SECTION ===== */
.hero-section {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100vh;
  min-height: 700px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: var(--bg-primary);
}

#matrix-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  opacity: 0.03;
  pointer-events: none;
}

/* 环境光晕 */
.hero-aura {
  position: absolute;
  border-radius: 50%;
  filter: blur(160px);
  pointer-events: none;
  z-index: 0;
}
.hero-aura-tl {
  top: -15%;
  left: -10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(236,9,40,0.12) 0%, transparent 70%);
}
.hero-aura-br {
  bottom: -15%;
  right: -10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(0,229,255,0.10) 0%, transparent 70%);
}

/* 内容层 */
.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 900px;
  padding: 0 24px;
}

.hero-tag {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--gray);
  letter-spacing: 2px;
  margin-bottom: 40px;
  opacity: 0.7;
}

.hero-title {
  font-family: var(--font-title);
  font-size: 56px;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 36px;
  color: var(--white);
}
.hero-line1, .hero-line2 {
  display: block;
}
.glow-cyan {
  color: var(--blue);
  text-shadow: 0 0 20px rgba(0,229,255,0.5), 0 0 40px rgba(0,229,255,0.2);
}
.glow-green {
  color: var(--green);
  text-shadow: 0 0 20px rgba(57,255,20,0.5), 0 0 40px rgba(57,255,20,0.2);
}

.hero-subtitle {
  font-size: 16px;
  color: var(--gray);
  line-height: 1.8;
  letter-spacing: 0.5px;
  margin-bottom: 40px;
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
}
.hero-subtitle strong {
  color: var(--white);
  font-weight: 700;
}

/* CTA 按钮 */
.hero-cta-btn {
  display: inline-block;
  height: 56px;
  width: 320px;
  background: linear-gradient(90deg, #EC0928, #A0061B);
  border: none;
  border-radius: var(--radius);
  color: #fff;
  font-family: var(--font-title);
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  position: relative;
  transition: transform 0.2s, box-shadow 0.2s;
  animation: hero-btn-breathe 2.5s ease-in-out infinite;
}
.hero-cta-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 24px rgba(236,9,40,0.5);
}
.hero-cta-btn:active {
  transform: translateY(0);
}

@keyframes hero-btn-breathe {
  0%, 100% { box-shadow: 0 0 12px rgba(236,9,40,0.3); }
  50% { box-shadow: 0 0 28px rgba(236,9,40,0.6); }
}

/* 箭头 */
.hero-arrow-wrap {
  margin-top: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}
.hero-arrow {
  font-size: 28px;
  color: var(--green);
  animation: hero-arrow-bounce 1.5s ease-in-out infinite;
  text-shadow: 0 0 10px rgba(57,255,20,0.5);
}
.hero-arrow-text {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--gray);
  letter-spacing: 2px;
  opacity: 0.6;
}

@keyframes hero-arrow-bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(8px); }
}

/* 首屏淡出 */
.hero-section.fade-out {
  animation: heroFadeOut 0.6s ease forwards;
}
@keyframes heroFadeOut {
  to { opacity: 0; height: 0; min-height: 0; padding: 0; overflow: hidden; }
}

/* ===== MODULE SECTIONS ===== */
.module-section {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 24px;
}

.module-header {
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.module-tag {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--gray);
  background: var(--bg-cell);
  padding: 2px 8px;
  border-radius: var(--radius);
  border: 1px solid var(--bg-grid);
  letter-spacing: 1px;
}

.module-title {
  font-family: var(--font-title);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.accent-red { color: var(--red); }
.text-white { color: #ffffff; }
.accent-blue { color: var(--blue); }
.accent-green { color: var(--green); }

.mono-text {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--gray);
}

/* ===== MODULE 1: BLOCK SYNC ===== */
.sync-status-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
  padding: 10px 16px;
  background: var(--bg-cell);
  border-radius: var(--radius);
  border: 1px solid var(--bg-grid);
}

.current-block { color: var(--blue); }

.block-grid {
  display: flex;
  gap: 6px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.block-cell {
  width: 48px;
  height: 48px;
  background: var(--bg-cell);
  border-radius: var(--radius);
  border: 1px solid var(--bg-grid);
  transition: all 0.4s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--gray);
}

.block-cell.active {
  background: var(--blue);
  border-color: var(--blue);
  color: var(--bg-primary);
  box-shadow: 0 0 12px var(--blue), 0 0 4px var(--blue);
  font-weight: 700;
}

.block-cell.flash {
  animation: cellFlash 0.6s ease;
}

.block-cell.sweep {
  animation: cellSweep 0.8s ease-out;
}

@keyframes cellSweep {
  0% {
    background: var(--bg-cell);
    box-shadow: none;
  }
  30% {
    background: rgba(0, 229, 255, 0.3);
    box-shadow: 0 0 16px var(--blue), inset 0 0 8px rgba(0, 229, 255, 0.5);
  }
  100% {
    background: var(--bg-cell);
    box-shadow: none;
  }
}

@keyframes cellFlash {
  0% { transform: scale(1); }
  50% { transform: scale(1.15); box-shadow: 0 0 24px var(--blue), 0 0 48px rgba(0,229,255,0.3); }
  100% { transform: scale(1); }
}

.result-drop-zone {
  text-align: center;
  padding: 20px;
  background: var(--bg-cell);
  border-radius: var(--radius);
  border: 1px solid var(--bg-grid);
}

.result-label {
  font-size: 12px;
  color: var(--gray);
  margin-bottom: 8px;
  font-family: var(--font-mono);
}

.result-value {
  font-family: var(--font-mono);
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 6px;
}

.result-value.state-a { color: var(--red); text-shadow: 0 0 12px var(--red); }
.result-value.state-b { color: var(--blue); text-shadow: 0 0 12px var(--blue); }

.result-hash {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--gray);
  word-break: break-all;
}

/* ===== MODULE 2: DISTRIBUTION ===== */
.mode-switcher {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  padding: 8px 12px;
  background: var(--bg-cell);
  border-radius: var(--radius);
  border: 1px solid var(--bg-grid);
}

.mode-btn {
  padding: 6px 14px;
  background: transparent;
  border: 1px solid var(--bg-grid);
  border-radius: var(--radius);
  color: var(--gray);
  font-family: var(--font-mono);
  font-size: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.mode-btn:hover { border-color: var(--blue); color: var(--white); }

.mode-btn.active {
  border-color: var(--blue);
  color: var(--blue);
  background: rgba(0, 229, 255, 0.08);
  box-shadow: 0 0 8px rgba(0, 229, 255, 0.2);
}

/* Vertical Table (竖向表格) */
.vertical-table-wrapper {
  background: var(--bg-cell);
  border-radius: var(--radius);
  border: 1px solid var(--bg-grid);
  overflow: hidden;
  max-height: 400px;
  display: flex;
  flex-direction: column;
}

.vertical-table-header {
  display: flex;
  background: rgba(35, 38, 45, 0.8);
  border-bottom: 1px solid var(--bg-grid);
  padding: 10px 12px;
  position: sticky;
  top: 0;
  z-index: 10;
}

.vertical-table-header .vt-col {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--gray);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.vertical-table-body {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
}

.vertical-table-body::-webkit-scrollbar { width: 4px; }
.vertical-table-body::-webkit-scrollbar-track { background: var(--bg-primary); }
.vertical-table-body::-webkit-scrollbar-thumb { background: var(--bg-grid); border-radius: 2px; }

.vt-row {
  display: flex;
  align-items: center;
  padding: 8px 12px;
  border-bottom: 1px solid rgba(35, 38, 45, 0.5);
  transition: background 0.2s ease;
}

.vt-row:hover {
  background: rgba(0, 229, 255, 0.03);
}

.vt-row:last-child {
  border-bottom: none;
}

.vt-col {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--white);
}

.vt-block-num {
  flex: 0 0 120px;
  color: var(--blue);
  font-weight: 600;
}

.vt-hash {
  flex: 1;
  color: var(--gray);
  font-size: 11px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding-right: 12px;
}

.vt-result {
  flex: 0 0 100px;
  text-align: center;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 4px;
}

.vt-result.result-dan {
  color: #FF3636;
  background: rgba(255, 54, 54, 0.1);
  border: 1px solid rgba(255, 54, 54, 0.3);
}

.vt-result.result-shuang {
  color: #24B3A2;
  background: rgba(36, 179, 162, 0.1);
  border: 1px solid rgba(36, 179, 162, 0.3);
}

.vt-time {
  flex: 0 0 140px;
  text-align: right;
  color: var(--gray);
  font-size: 11px;
}

.vt-row-new {
  animation: vt-row-flash 0.6s ease;
}

@keyframes vt-row-flash {
  0% { background: rgba(0, 229, 255, 0.15); }
  100% { background: transparent; }
}

.distribution-layout {
  display: flex;
  gap: 20px;
}

.main-matrix-wrapper { flex: 1; min-width: 0; }

.matrix-header {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--gray);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Big Road (大路) */
.big-road-container {
  background: var(--bg-cell);
  border-radius: var(--radius);
  border: 1px solid var(--bg-grid);
  padding: 8px;
  overflow-x: auto;
  overflow-y: hidden;
}

.big-road-container::-webkit-scrollbar { height: 4px; }
.big-road-container::-webkit-scrollbar-track { background: var(--bg-primary); }
.big-road-container::-webkit-scrollbar-thumb { background: var(--bg-grid); border-radius: 2px; }

.big-road {
  display: flex;
  gap: 2px;
  min-height: 180px;
  align-items: flex-start;
}

.big-road-column {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 28px;
}

.big-road-cell {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  color: #fff;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
}

.big-road-cell.trend-dan {
  background: #FF3636;
  box-shadow: 0 0 8px #FF3636;
}

.big-road-cell.trend-shuang {
  background: #24B3A2;
  box-shadow: 0 0 8px #24B3A2;
}

.big-road-cell:hover {
  transform: scale(1.15);
  z-index: 10;
}

.matrix-legend {
  display: flex;
  gap: 20px;
  margin-top: 10px;
  font-size: 12px;
  color: var(--gray);
}

.legend-item { display: flex; align-items: center; gap: 6px; }

.legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
}

.legend-dot.dot-red { background: #FF3636; box-shadow: 0 0 6px #FF3636; }
.legend-dot.dot-green { background: #24B3A2; box-shadow: 0 0 6px #24B3A2; }
.legend-dot.dot-blue { background: var(--blue); box-shadow: 0 0 6px var(--blue); }

/* Derived Roads (衍生路) */
.derived-matrices {
  width: 220px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex-shrink: 0;
}

.derived-matrix {
  background: var(--bg-cell);
  border-radius: var(--radius);
  border: 1px solid var(--bg-grid);
  padding: 10px;
}

.derived-title {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--gray);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.derived-road {
  display: flex;
  gap: 2px;
  min-height: 60px;
  flex-wrap: wrap;
  align-items: flex-start;
}

.derived-road .derived-col {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.derived-cell {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: transparent;
  border: 1.5px solid transparent;
}

.derived-cell.cell-red {
  background: #FF3636;
  box-shadow: 0 0 4px #FF3636;
  border-color: #FF3636;
}

.derived-cell.cell-green {
  background: #24B3A2;
  box-shadow: 0 0 4px #24B3A2;
  border-color: #24B3A2;
}

.derived-cell.cell-empty {
  border: 1.5px solid var(--bg-grid);
  background: transparent;
  box-shadow: none;
}

/* Block Numbers Bar */
.block-numbers-bar {
  margin-top: 16px;
  background: var(--bg-cell);
  border-radius: var(--radius);
  border: 1px solid var(--bg-grid);
  padding: 10px 14px;
}

.block-numbers-header {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--gray);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.block-numbers-list {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.block-number-tag {
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 3px 8px;
  border-radius: 3px;
  background: var(--bg-primary);
  border: 1px solid var(--bg-grid);
  color: var(--gray);
}

.block-number-tag.tag-dan { border-color: rgba(255, 54, 54, 0.4); color: #FF3636; }
.block-number-tag.tag-shuang { border-color: rgba(36, 179, 162, 0.4); color: #24B3A2; }

.hover-tooltip {
  position: fixed;
  z-index: 100;
  background: rgba(13, 14, 18, 0.92);
  backdrop-filter: blur(10px);
  border: 1px solid var(--bg-grid);
  border-radius: var(--radius);
  padding: 12px 16px;
  pointer-events: none;
  max-width: 360px;
}

.tooltip-hash {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--white);
  word-break: break-all;
  margin-bottom: 4px;
}

.tooltip-block-num {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--blue);
  margin-bottom: 6px;
}

.tooltip-link {
  font-size: 11px;
  color: var(--blue);
  text-decoration: none;
  pointer-events: auto;
}

.tooltip-link:hover { text-decoration: underline; }

/* ===== MODULE 3: AI MATRIX ===== */
#module-ai { position: relative; }

.ai-neural-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: var(--radius);
  pointer-events: none;
  z-index: 0;
}

.ai-neural-bg canvas {
  width: 100%;
  height: 100%;
  opacity: 0.15;
}

.ai-input-panel {
  position: relative;
  z-index: 1;
  background: rgba(26, 29, 38, 0.85);
  backdrop-filter: blur(10px);
  border-radius: var(--radius);
  border: 1px solid var(--bg-grid);
  padding: 28px;
}

.ai-dimension {
  margin-bottom: 24px;
}

.dim-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--gray);
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.dim-buttons {
  display: flex;
  gap: 12px;
}

.channel-btn {
  flex: 1;
  padding: 10px 16px;
  background: var(--bg-cell);
  border: 1px solid var(--bg-grid);
  border-radius: var(--radius);
  color: var(--gray);
  font-family: var(--font-mono);
  font-size: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.channel-btn:hover { border-color: var(--blue); color: var(--white); }

.channel-btn.active {
  border-color: var(--blue);
  color: var(--blue);
  box-shadow: 0 0 8px rgba(0, 229, 255, 0.3);
}

.slider-wrapper { padding: 0 4px; }

.risk-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  background: var(--bg-grid);
  border-radius: 3px;
  outline: none;
  cursor: pointer;
}

.risk-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--blue);
  box-shadow: 0 0 8px var(--blue);
  cursor: pointer;
}

.risk-slider::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--blue);
  box-shadow: 0 0 8px var(--blue);
  border: none;
  cursor: pointer;
}

.slider-labels {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: var(--gray);
  margin-top: 6px;
  font-family: var(--font-mono);
}

.slider-current {
  text-align: center;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--blue);
  margin-top: 8px;
}

.weight-checkboxes {
  display: flex;
  gap: 20px;
}

.weight-check {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--white);
  cursor: pointer;
}

.weight-check input[type="checkbox"] {
  accent-color: var(--blue);
  width: 16px;
  height: 16px;
}

.ai-trigger-btn {
  width: 100%;
  padding: 14px;
  background: transparent;
  border: 2px solid var(--blue);
  border-radius: var(--radius);
  color: var(--blue);
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 8px;
}

.ai-trigger-btn:hover {
  background: var(--blue);
  color: var(--bg-primary);
  box-shadow: 0 0 20px rgba(0, 229, 255, 0.4);
}

/* Code Overlay */
.code-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(13, 14, 18, 0.95);
  display: flex;
  align-items: center;
  justify-content: center;
}

.code-overlay-inner {
  width: 600px;
  max-width: 90vw;
  background: var(--bg-cell);
  border: 1px solid var(--bg-grid);
  border-radius: var(--radius);
  padding: 32px;
}

.code-lines {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--green);
  line-height: 2;
  min-height: 160px;
  overflow: hidden;
}

.code-lines .code-line {
  opacity: 0;
  animation: fadeInLine 0.3s ease forwards;
}

@keyframes fadeInLine {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.code-progress-bar {
  width: 100%;
  height: 6px;
  background: var(--bg-grid);
  border-radius: 3px;
  margin-top: 20px;
  overflow: hidden;
}

.code-progress-fill {
  height: 100%;
  width: 0%;
  background: var(--blue);
  border-radius: 3px;
  transition: width 0.3s ease;
  box-shadow: 0 0 8px var(--blue);
}

.code-progress-text {
  text-align: right;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--blue);
  margin-top: 6px;
}

/* AI Result Panel */
.ai-result-panel {
  position: relative;
  z-index: 1;
  background: rgba(26, 29, 38, 0.85);
  backdrop-filter: blur(10px);
  border-radius: var(--radius);
  border: 1px solid var(--bg-grid);
  padding: 28px;
}

.result-card {
  margin-bottom: 20px;
  padding: 16px;
  background: var(--bg-cell);
  border-radius: var(--radius);
  border: 1px solid var(--bg-grid);
}

.result-card-title {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--gray);
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.prediction-row {
  display: flex;
  gap: 20px;
}

.pred-item {
  flex: 1;
  text-align: center;
}

.pred-label {
  display: block;
  font-size: 12px;
  color: var(--gray);
  margin-bottom: 6px;
}

.pred-value {
  font-family: var(--font-mono);
  font-size: 32px;
  font-weight: 700;
}

.pred-red { color: var(--red); text-shadow: 0 0 12px var(--red); }
.pred-blue { color: var(--blue); text-shadow: 0 0 12px var(--blue); }

.risk-advice {
  font-size: 13px;
  color: var(--white);
  line-height: 1.8;
  padding: 12px;
  background: rgba(0, 229, 255, 0.05);
  border-left: 3px solid var(--blue);
  border-radius: 0 var(--radius) var(--radius) 0;
}

.ai-retry-btn {
  padding: 10px 24px;
  background: transparent;
  border: 1px solid var(--gray);
  border-radius: var(--radius);
  color: var(--gray);
  font-family: var(--font-mono);
  font-size: 12px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.ai-retry-btn:hover {
  border-color: var(--blue);
  color: var(--blue);
}

/* ===== MODULE 4: BENCHMARK ===== */
.benchmark-layout {
  display: flex;
  gap: 24px;
  margin-bottom: 20px;
}

.benchmark-left {
  flex: 0 0 280px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.accuracy-display {
  text-align: center;
  padding: 32px;
  background: var(--bg-cell);
  border-radius: var(--radius);
  border: 1px solid var(--bg-grid);
  width: 100%;
}

.accuracy-label {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--gray);
  letter-spacing: 2px;
  margin-bottom: 12px;
}

.accuracy-value {
  font-family: var(--font-mono);
  font-size: 48px;
  font-weight: 700;
  color: var(--green);
  text-shadow: 0 0 16px var(--green);
  animation: accuracyPulse 2s ease-in-out infinite;
}

.accuracy-pct { font-size: 28px; }

@keyframes accuracyPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

.benchmark-right { flex: 1; }

/* AI测算激活视窗 */
.ai-predict-window {
  background: var(--bg-cell);
  border-radius: var(--radius);
  border: 1px solid var(--bg-grid);
  padding: 20px;
  min-height: 200px;
  position: relative;
  overflow: hidden;
}

.predict-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 180px;
}

.predict-title {
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--blue);
  text-align: center;
  margin-bottom: 16px;
  text-shadow: 0 0 8px var(--blue);
}

.predict-btn {
  background: linear-gradient(135deg, rgba(0, 229, 255, 0.2), rgba(0, 229, 255, 0.1));
  border: 1px solid var(--blue);
  border-radius: var(--radius);
  color: var(--blue);
  font-family: var(--font-mono);
  font-size: 13px;
  padding: 14px 24px;
  cursor: pointer;
  transition: all 0.3s ease;
  text-shadow: 0 0 6px var(--blue);
  box-shadow: 0 0 12px rgba(0, 229, 255, 0.3);
}

.predict-btn:hover {
  background: linear-gradient(135deg, rgba(0, 229, 255, 0.3), rgba(0, 229, 255, 0.2));
  box-shadow: 0 0 20px rgba(0, 229, 255, 0.5);
  transform: scale(1.02);
}

.predict-progress {
  font-family: var(--font-mono);
  font-size: 32px;
  font-weight: 700;
  color: var(--blue);
  text-shadow: 0 0 16px var(--blue);
  margin: 10px 0;
}

/* 矩阵雨效果 */
.matrix-rain {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.matrix-rain.active {
  opacity: 1;
}

.matrix-char {
  position: absolute;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--blue);
  text-shadow: 0 0 4px var(--blue);
  animation: matrixFall 1.5s linear infinite;
}

@keyframes matrixFall {
  0% { transform: translateY(-20px); opacity: 1; }
  100% { transform: translateY(200px); opacity: 0; }
}

/* 测算结果 */
.predict-result-content {
  width: 100%;
  max-width: 400px;
}

.predict-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--bg-grid);
}

.predict-row:last-child {
  border-bottom: none;
}

.predict-label {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--gray);
}

.predict-value {
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}

.predict-value.confidence {
  color: var(--green);
  text-shadow: 0 0 8px var(--green);
  font-size: 18px;
}

.predict-countdown {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--gray);
  text-align: center;
  margin-top: 12px;
  padding: 8px;
  background: rgba(0, 229, 255, 0.05);
  border-radius: 4px;
  border: 1px dashed var(--bg-grid);
}

/* 结果炸开动画 */
.predict-state.result-enter {
  animation: resultExplode 0.5s ease-out;
}

@keyframes resultExplode {
  0% { transform: scale(0.8); opacity: 0; }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); opacity: 1; }
}

/* Ticker */
.benchmark-ticker {
  background: var(--bg-cell);
  border-radius: var(--radius);
  border: 1px solid var(--bg-grid);
  overflow: hidden;
}

.ticker-header {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--gray);
  padding: 10px 16px;
  border-bottom: 1px solid var(--bg-grid);
  letter-spacing: 1px;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 12px;
}

.ticker-subtitle {
  font-size: 10px;
  color: var(--blue);
  text-transform: none;
  letter-spacing: 0;
}

.ticker-container {
  height: 280px;
  overflow-y: auto;
  position: relative;
  scrollbar-width: thin;
  scrollbar-color: var(--bg-grid) transparent;
}

.ticker-container::-webkit-scrollbar {
  width: 6px;
}

.ticker-container::-webkit-scrollbar-track {
  background: transparent;
}

.ticker-container::-webkit-scrollbar-thumb {
  background: var(--bg-grid);
  border-radius: 3px;
}

.ticker-line {
  font-family: var(--font-mono);
  font-size: 11px;
  padding: 8px 16px;
  color: var(--gray);
  white-space: nowrap;
  animation: tickerSlideIn 0.4s ease;
  border-bottom: 1px solid rgba(35, 38, 45, 0.5);
  display: flex;
  align-items: center;
  gap: 8px;
}

.ticker-line .period {
  color: var(--text);
  min-width: 100px;
}

.ticker-line .ai-predict {
  color: var(--blue);
}

.ticker-line .actual {
  color: var(--text);
}

.ticker-line .verdict {
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 3px;
}

.ticker-line .verdict.success {
  color: var(--green);
  background: rgba(57, 255, 20, 0.1);
  border: 1px solid var(--green);
  box-shadow: 0 0 6px rgba(57, 255, 20, 0.3);
}

.ticker-line .verdict.fail {
  color: var(--red);
  background: rgba(236, 9, 40, 0.1);
  border: 1px solid var(--red);
}

.ticker-line .verify-link {
  color: var(--blue);
  text-decoration: none;
  font-size: 10px;
  opacity: 0.7;
  transition: opacity 0.2s;
}

.ticker-line .verify-link:hover {
  opacity: 1;
  text-decoration: underline;
}

.ticker-line .match { color: var(--green); }
.ticker-line .miss { color: var(--red); }

/* 新记录下沉动画 */
.ticker-line.sink-in {
  animation: sinkIn 0.6s ease-out;
}

@keyframes sinkIn {
  0% { opacity: 0; transform: translateY(-30px) scale(0.95); background: rgba(0, 229, 255, 0.1); }
  50% { background: rgba(0, 229, 255, 0.05); }
  100% { opacity: 1; transform: translateY(0) scale(1); background: transparent; }
}

@keyframes tickerSlideIn {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ===== CTA MODULE ===== */
.cta-card {
  background: var(--bg-cell);
  border-radius: var(--radius);
  padding: 36px;
  position: relative;
  overflow: hidden;
}

.cta-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: var(--radius);
  padding: 2px;
  background: linear-gradient(135deg, var(--gold-start), var(--gold-end));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.cta-title {
  font-family: var(--font-title);
  font-size: 24px;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 12px;
}

.cta-subtitle {
  font-size: 14px;
  color: var(--gray);
  line-height: 1.6;
  margin-bottom: 24px;
}

.cta-form {
  display: flex;
  gap: 12px;
}

.cta-input {
  flex: 1;
  padding: 12px 16px;
  background: var(--bg-input);
  border: 1px solid var(--bg-grid);
  border-radius: var(--radius);
  color: var(--white);
  font-size: 14px;
  font-family: var(--font-body);
  outline: none;
  transition: border-color 0.3s ease;
}

.cta-input::placeholder { color: var(--gray); }
.cta-input:focus { border-color: var(--gold-start); }

.cta-btn {
  width: 180px;
  padding: 12px 16px;
  background: linear-gradient(135deg, var(--gold-start), var(--gold-end));
  border: none;
  border-radius: var(--radius);
  color: var(--bg-primary);
  font-family: var(--font-title);
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  white-space: nowrap;
}

.cta-btn:hover {
  box-shadow: 0 0 20px rgba(255, 215, 0, 0.4);
  transform: translateY(-1px);
}

.cta-success {
  margin-top: 16px;
  font-size: 14px;
  color: var(--green);
  font-family: var(--font-mono);
  animation: fadeInLine 0.5s ease forwards;
}

/* ===== CHAT WIDGET ===== */
.chat-widget {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 300px;
  height: 420px;
  z-index: 500;
  background: rgba(26, 29, 38, 0.8);
  backdrop-filter: blur(10px);
  border-radius: var(--radius);
  border: 1px solid var(--bg-grid);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
  transition: all 0.3s ease;
}

/* 最小化状态 */
.chat-widget.minimized {
  height: 44px;
  width: 200px;
}

.chat-widget.minimized .chat-body,
.chat-widget.minimized .chat-footer {
  display: none;
}

.chat-widget.minimized .chat-header {
  cursor: pointer;
}

/* 最小化按钮 */
.chat-minimize-btn {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #fff;
  width: 22px;
  height: 22px;
  border-radius: 4px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.chat-minimize-btn:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* 需要帮助吗提示气泡 */
.chat-help-bubble {
  position: fixed;
  bottom: 80px;
  right: 30px;
  background: rgba(26, 29, 38, 0.95);
  backdrop-filter: blur(10px);
  border: 1px solid var(--cyan);
  border-radius: var(--radius);
  padding: 10px 16px;
  display: flex;
  align-items: center;
  gap: 8px;
  z-index: 499;
  opacity: 0;
  transform: translateY(10px) scale(0.9);
  transition: all 0.3s ease;
  pointer-events: none;
  box-shadow: 0 0 15px rgba(0, 229, 255, 0.3);
}

.chat-help-bubble.show {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.chat-help-bubble .help-icon {
  font-size: 16px;
}

.chat-help-bubble .help-text {
  font-size: 13px;
  color: var(--cyan);
  font-weight: 600;
}

.chat-header {
  background: var(--red);
  padding: 10px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-shrink: 0;
}

.chat-header-left {
  display: flex;
  align-items: center;
  gap: 6px;
}

.chat-badge { font-size: 18px; }

.chat-title {
  font-size: 13px;
  font-weight: 700;
  color: #fff;
}

.chat-header-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
}

.chat-status {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.9);
  display: flex;
  align-items: center;
  gap: 4px;
}

.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 6px var(--green);
  display: inline-block;
}

.chat-response-time {
  font-size: 9px;
  color: rgba(255, 255, 255, 0.7);
}

.chat-body {
  flex: 1;
  overflow-y: auto;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.chat-body::-webkit-scrollbar { width: 4px; }
.chat-body::-webkit-scrollbar-track { background: transparent; }
.chat-body::-webkit-scrollbar-thumb { background: var(--bg-grid); border-radius: 2px; }

.chat-msg {
  max-width: 85%;
  padding: 10px 12px;
  border-radius: var(--radius);
  font-size: 12px;
  line-height: 1.6;
  animation: fadeInLine 0.4s ease forwards;
}

.chat-msg.system {
  align-self: flex-start;
  background: rgba(0, 229, 255, 0.1);
  border: 1px solid rgba(0, 229, 255, 0.2);
  color: var(--white);
}

.chat-msg.user {
  align-self: flex-end;
  background: var(--blue);
  color: var(--bg-primary);
  font-weight: 500;
}

.chat-footer {
  padding: 10px;
  border-top: 1px solid var(--bg-grid);
  display: flex;
  gap: 8px;
  flex-shrink: 0;
}

.chat-input {
  flex: 1;
  padding: 8px 12px;
  background: var(--bg-input);
  border: 1px solid var(--bg-grid);
  border-radius: var(--radius);
  color: var(--white);
  font-size: 12px;
  font-family: var(--font-body);
  outline: none;
}

.chat-input::placeholder { color: var(--gray); }
.chat-input:focus { border-color: var(--blue); }

.chat-send-btn {
  width: 36px;
  height: 36px;
  background: var(--red);
  border: none;
  border-radius: var(--radius);
  color: #fff;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.chat-send-btn:hover {
  box-shadow: 0 0 12px var(--red);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .distribution-layout { flex-direction: column; }
  .derived-matrices { width: 100%; flex-direction: row; }
  .derived-matrix { flex: 1; }
  .benchmark-layout { flex-direction: column; }
  .benchmark-left { flex: none; }
  .cta-form { flex-direction: column; }
  .cta-btn { width: 100%; }
  .chat-widget { width: 260px; height: 380px; bottom: 10px; right: 10px; }
  .block-cell { width: 36px; height: 36px; font-size: 9px; }
  .sync-status-bar { flex-direction: column; gap: 6px; }
  .dim-buttons { flex-direction: column; }
  .weight-checkboxes { flex-direction: column; gap: 10px; }
  .mode-switcher { flex-wrap: wrap; }
}
