@import url("https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@400;500;600;700&family=Noto+Serif+SC:wght@500;600;700&display=swap");

:root {
  --bg: #f5f1e6;
  --bg-deep: #ebe3d4;
  --ink: #1f2422;
  --muted: #6a6f6b;
  --accent: #e07a2f;
  --accent-dark: #b15316;
  --accent-cool: #196b5a;
  --accent-soft: #f4c98b;
  --stroke: rgba(31, 36, 34, 0.15);
  --card-bg: rgba(255, 255, 255, 0.8);
  --shadow: 0 30px 60px rgba(32, 27, 13, 0.15);
  --radius: 20px;
  --font-body: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-title: "Noto Serif SC", "Songti SC", serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: radial-gradient(circle at top, #fff5e1 0%, transparent 55%),
    linear-gradient(180deg, #f7f2e6 0%, #efe6d7 45%, #f4efe4 100%);
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

.bg-shape {
  position: fixed;
  border-radius: 999px;
  filter: blur(60px);
  opacity: 0.6;
  z-index: -1;
}

.bg-shape-1 {
  width: 420px;
  height: 420px;
  background: rgba(255, 191, 105, 0.45);
  top: -120px;
  left: -120px;
}

.bg-shape-2 {
  width: 520px;
  height: 520px;
  background: rgba(56, 131, 105, 0.35);
  top: 20vh;
  right: -180px;
}

.bg-shape-3 {
  width: 380px;
  height: 380px;
  background: rgba(241, 210, 154, 0.45);
  bottom: -140px;
  left: 20vw;
}

h1,
h2,
h3 {
  font-family: var(--font-title);
  letter-spacing: 0.5px;
  margin: 0;
}

p {
  line-height: 1.7;
  margin: 0;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
  gap: 48px;
  padding: 100px 8vw 70px;
  align-items: center;
}

.eyebrow {
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 3px;
  color: var(--accent-dark);
  margin-bottom: 16px;
}

.hero h1 {
  font-size: clamp(36px, 4vw, 58px);
  line-height: 1.15;
}

.hero-lead {
  margin-top: 24px;
  color: var(--muted);
  font-size: 18px;
}

.hero-meta {
  margin-top: 32px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero-meta span {
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(25, 107, 90, 0.15);
  color: var(--accent-cool);
  font-size: 13px;
  letter-spacing: 1px;
}

.hero-card {
  background: var(--card-bg);
  border: 1px solid rgba(31, 36, 34, 0.1);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
}

.hero-card-top {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--accent-dark);
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  font-size: 12px;
  margin-bottom: 18px;
}

.hero-card .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
}

.hero-card h2 {
  font-size: 24px;
  margin-bottom: 14px;
}

main {
  padding-bottom: 80px;
}

.section {
  padding: 80px 8vw;
}

.section-title {
  margin-bottom: 36px;
}

.section-title h2 {
  font-size: 32px;
  margin-bottom: 12px;
}

.section-title p {
  color: var(--muted);
  max-width: 780px;
}

.grid.two {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 36px;
  align-items: center;
}

.copy-block .lead {
  font-size: 18px;
  color: var(--ink);
}

.note {
  margin-top: 24px;
  background: rgba(25, 107, 90, 0.12);
  padding: 18px 20px;
  border-radius: 16px;
  color: var(--accent-cool);
}

.card {
  background: var(--card-bg);
  border: 1px solid rgba(31, 36, 34, 0.08);
  border-radius: var(--radius);
  padding: 26px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
}

.chart-card {
  display: grid;
  gap: 18px;
}

.chart-title {
  display: flex;
  justify-content: space-between;
  font-weight: 600;
}

.chart-value {
  color: var(--accent-dark);
}

.chart-bar {
  display: flex;
  height: 18px;
  border-radius: 999px;
  overflow: hidden;
  background: #efe5d6;
}

.segment-legacy {
  background: var(--accent-cool);
  width: 20%;
  transition: width 0.4s ease;
}

.segment-ai {
  background: linear-gradient(90deg, #f2b46a 0%, #e07a2f 100%);
  width: 80%;
  transition: width 0.4s ease;
}

.chart-labels {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  color: var(--muted);
}

.range-block {
  display: grid;
  gap: 10px;
  font-size: 14px;
  color: var(--muted);
}

input[type="range"] {
  appearance: none;
  width: 100%;
  height: 4px;
  background: rgba(31, 36, 34, 0.2);
  border-radius: 999px;
  outline: none;
}

input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid #fff;
  box-shadow: 0 4px 10px rgba(224, 122, 47, 0.35);
  cursor: pointer;
}

input[type="range"]::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid #fff;
  cursor: pointer;
}

.insight {
  font-size: 14px;
  color: var(--muted);
}

.pipeline {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  margin-bottom: 24px;
}

.step-card {
  border: 1px solid rgba(31, 36, 34, 0.15);
  background: rgba(255, 255, 255, 0.6);
  padding: 20px;
  border-radius: 18px;
  text-align: left;
  cursor: pointer;
  transition: all 0.3s ease;
}

.step-card:hover {
  transform: translateY(-4px);
  border-color: rgba(224, 122, 47, 0.5);
}

.step-card.active {
  background: rgba(224, 122, 47, 0.1);
  border-color: var(--accent);
  box-shadow: 0 16px 40px rgba(224, 122, 47, 0.2);
}

.step-index {
  font-size: 12px;
  letter-spacing: 2px;
  color: var(--accent-dark);
}

.step-name {
  display: block;
  font-size: 20px;
  font-weight: 600;
  margin-top: 8px;
}

.step-desc {
  display: block;
  font-size: 14px;
  color: var(--muted);
  margin-top: 6px;
}

.pipeline-detail .detail-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.loss-tag {
  padding: 6px 12px;
  background: rgba(224, 122, 47, 0.15);
  color: var(--accent-dark);
  border-radius: 999px;
  font-size: 12px;
  letter-spacing: 1px;
}

.loss-bars {
  margin-top: 16px;
  display: grid;
  gap: 10px;
}

.loss-item {
  display: grid;
  grid-template-columns: 100px 1fr;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  color: var(--muted);
}

.loss-track {
  width: 100%;
  height: 8px;
  background: #efe5d6;
  border-radius: 999px;
  overflow: hidden;
}

.loss-fill {
  height: 100%;
  background: linear-gradient(90deg, #f0b26d 0%, #e07a2f 100%);
}

.detail-foot {
  margin-top: 18px;
  color: var(--muted);
  font-size: 14px;
}

.badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(25, 107, 90, 0.12);
  color: var(--accent-cool);
  margin-right: 10px;
  font-size: 12px;
}

.framework-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 0.8fr);
  gap: 28px;
}

.graph-panel {
  display: grid;
  gap: 20px;
}

.graph-controls {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.case-toggle {
  display: flex;
  gap: 8px;
}

.toggle-btn,
.control-btn,
.signal-btn {
  border: 1px solid rgba(31, 36, 34, 0.15);
  background: #fff;
  padding: 8px 14px;
  border-radius: 999px;
  cursor: pointer;
  font-size: 13px;
  transition: all 0.2s ease;
}

.toggle-btn.active,
.signal-btn.active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.control-btn {
  background: rgba(25, 107, 90, 0.1);
  border-color: rgba(25, 107, 90, 0.3);
  color: var(--accent-cool);
}

.control-btn.ghost {
  background: transparent;
}

.graph-wrap {
  width: 100%;
  border-radius: 18px;
  background: #f8f1e4;
  border: 1px solid rgba(31, 36, 34, 0.08);
  overflow: hidden;
}

#flow-graph {
  width: 100%;
  height: 520px;
}

.graph-footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  align-items: center;
}

.progress {
  display: grid;
  gap: 8px;
  font-size: 12px;
  color: var(--muted);
}

.legend {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 12px;
  color: var(--muted);
}

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

.legend-line {
  display: inline-block;
  width: 26px;
  height: 2px;
  background: var(--accent);
}

.legend-line.plan {
  background: transparent;
  border-top: 2px dashed rgba(25, 107, 90, 0.6);
}

.legend-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
}

.legend-dot.current {
  box-shadow: 0 0 0 4px rgba(224, 122, 47, 0.2);
}

.insight-panel {
  display: grid;
  gap: 20px;
}

.insight-card {
  display: grid;
  gap: 16px;
}

.card-title {
  font-size: 16px;
  font-weight: 600;
}

.current-topic {
  font-size: 20px;
  font-weight: 600;
  color: var(--accent-dark);
}

.snippet {
  background: rgba(255, 255, 255, 0.6);
  border-radius: 16px;
  padding: 16px;
  border: 1px dashed rgba(31, 36, 34, 0.15);
  font-size: 14px;
  color: var(--muted);
  position: relative;
  overflow: hidden;
}

.snippet-list {
  display: grid;
  gap: 12px;
  max-height: 220px;
  overflow-y: auto;
  padding: 10px 8px;
  scroll-behavior: smooth;
}

.snippet-list::-webkit-scrollbar {
  width: 6px;
}

.snippet-list::-webkit-scrollbar-thumb {
  background: rgba(31, 36, 34, 0.2);
  border-radius: 999px;
}

.snippet-mask {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.95) 0%,
    rgba(255, 255, 255, 0) 18%,
    rgba(255, 255, 255, 0) 82%,
    rgba(255, 255, 255, 0.95) 100%
  );
  pointer-events: none;
}

.snippet-item {
  display: grid;
  gap: 8px;
  opacity: 0.45;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.snippet-item.active {
  opacity: 1;
  transform: scale(1.02);
}

.snippet .line {
  padding: 8px 12px;
  border-radius: 12px;
}

.snippet .line.sales {
  background: rgba(224, 122, 47, 0.12);
  color: var(--accent-dark);
}

.snippet .line.client {
  background: rgba(25, 107, 90, 0.1);
  color: var(--accent-cool);
}

.topic-lists {
  display: grid;
  gap: 12px;
}

.topic-list span {
  font-size: 12px;
  color: var(--muted);
}

.topic-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}

.topic-tag {
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(31, 36, 34, 0.08);
  font-size: 12px;
  color: var(--muted);
}

.plan-tags .topic-tag {
  background: rgba(25, 107, 90, 0.12);
  color: var(--accent-cool);
  border: 1px dashed rgba(25, 107, 90, 0.4);
}

.signal-groups {
  display: grid;
  gap: 14px;
}

.signal-group span {
  font-size: 12px;
  color: var(--muted);
}

.signal-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.signal-panel {
  background: rgba(255, 255, 255, 0.6);
  border-radius: 16px;
  padding: 14px 16px;
  border: 1px solid rgba(31, 36, 34, 0.08);
  color: var(--muted);
  font-size: 14px;
}

.footer {
  padding: 20px 8vw 40px;
  font-size: 12px;
  color: var(--muted);
}

.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 1100px) {
  .hero {
    grid-template-columns: 1fr;
  }

  .grid.two,
  .framework-grid {
    grid-template-columns: 1fr;
  }

  .pipeline {
    grid-template-columns: 1fr;
  }
}

/* SVG styles */
.stage-box {
  fill: rgba(255, 255, 255, 0.5);
  stroke: rgba(31, 36, 34, 0.12);
  stroke-dasharray: 4 4;
}

.stage-label {
  font-size: 14px;
  fill: rgba(31, 36, 34, 0.6);
  font-weight: 600;
}

.edge {
  fill: none;
  stroke-width: 3;
  stroke-linecap: round;
}

.edge.actual {
  stroke: var(--accent);
}

.edge.plan {
  stroke: rgba(25, 107, 90, 0.75);
  stroke-dasharray: 6 6;
}

.node circle {
  fill: #fff;
  stroke: rgba(31, 36, 34, 0.2);
  stroke-width: 2;
}

.node text {
  font-size: 12px;
  fill: var(--ink);
}

.node-past circle {
  fill: rgba(224, 122, 47, 0.18);
  stroke: var(--accent);
}

.node-current circle {
  fill: var(--accent);
  stroke: #fff;
  stroke-width: 3;
  filter: drop-shadow(0 6px 10px rgba(224, 122, 47, 0.4));
}

.node-current text {
  fill: #fff;
  font-weight: 600;
}

.node-plan circle {
  stroke: rgba(25, 107, 90, 0.7);
  stroke-dasharray: 4 4;
}

.node-signal circle {
  stroke: rgba(25, 107, 90, 0.9);
  stroke-width: 3;
}
