.cde-section {
  --cde-stroke: #393443;
  --cde-panel: #1b1b22;
  --cde-text: #f3eff7;
  --cde-muted: #c6bfce;
  --cde-accent: #d2b2f5;
  --cde-gap: clamp(12px, 1.8vw, 22px);
  border-top: 1px solid var(--cde-stroke);
}

.cde-intro {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, .85fr);
  align-items: end;
  gap: 14px clamp(22px, 5vw, 70px);
  margin-bottom: clamp(24px, 4vw, 46px);
}

.cde-intro h2 { margin: 8px 0 0; max-width: 21ch; }
.cde-intro > p { margin: 0; max-width: 44ch; color: var(--cde-muted); line-height: 1.55; }

.cde-flow-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--cde-gap);
}

.cde-inputs,
.cde-context,
.cde-checklist,
.cde-legend { padding: 0; margin: 0; list-style: none; }

.cde-input,
.cde-output,
.cde-layer,
.cde-curve {
  min-width: 0;
  border: 1px solid var(--cde-stroke);
  background: var(--cde-panel);
}

.cde-input,
.cde-output,
.cde-layer,
.cde-curve { padding: clamp(15px, 2.1vw, 26px); }

.cde-input,
.cde-output h3,
.cde-layer-head {
  display: flex;
  align-items: flex-start;
  gap: 11px;
}

.cde-icon { flex: 0 0 23px; width: 23px; height: 23px; color: var(--cde-accent); }
.cde-input strong,
.cde-output h3,
.cde-layer h3,
.cde-curve figcaption {
  margin: 0;
  color: var(--cde-text);
  font-size: clamp(16px, 1.65vw, 22px);
  font-weight: 620;
  line-height: 1.21;
}

.cde-input span,
.cde-layer-head p { display: block; margin: 4px 0 0; color: var(--cde-muted); font-size: .9rem; line-height: 1.42; }

.cde-connector {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--cde-gap);
  height: clamp(14px, 2vw, 28px);
}

.cde-connector span {
  justify-self: center;
  width: 1px;
  background: #82669b;
}

.cde-hub {
  padding: clamp(16px, 2.5vw, 28px);
  border: 1px solid #825b9e;
  background: #291e38;
  text-align: center;
}

.cde-hub h3 {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 0;
  color: var(--cde-text);
  font-size: clamp(18px, 2.2vw, 27px);
  font-weight: 620;
  line-height: 1.22;
}

.cde-context {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 15px;
  margin-top: 9px;
  color: #e3d3ef;
  font-size: .875rem;
}

.cde-context li { padding-inline: 7px; }

.cde-checklist { display: grid; gap: 8px; margin-top: 14px; }
.cde-checklist li {
  display: grid;
  grid-template-columns: 13px minmax(0, 1fr);
  align-items: start;
  gap: 8px;
  color: var(--cde-muted);
  font-size: 1rem;
  line-height: 1.42;
}

.cde-checklist li::before {
  content: "";
  width: 8px;
  height: 4px;
  margin: .42em 0 0 2px;
  border: solid var(--cde-accent);
  border-width: 0 0 1.5px 1.5px;
  transform: rotate(-45deg);
}

.cde-layer[data-layer="bim"] { --cde-accent: #d2b2f5; }
.cde-layer[data-layer="points"] { --cde-accent: #9fd3d1; }
.cde-layer[data-layer="gaussian"] { --cde-accent: #edd1a1; }
.cde-layer { border-top: 2px solid var(--cde-accent); }
.cde-layer .cde-icon { flex-basis: 27px; width: 27px; height: 27px; }
.cde-layer-head { padding-bottom: 14px; border-bottom: 1px solid var(--cde-stroke); }

.cde-overview {
  display: grid;
  grid-template-columns: minmax(0, .68fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(20px, 4.5vw, 60px);
  margin-top: clamp(24px, 4.5vw, 58px);
  padding-top: clamp(22px, 4vw, 46px);
  border-top: 1px solid var(--cde-stroke);
}

.cde-overview-copy h3 {
  margin: 0;
  color: var(--cde-text);
  font-size: clamp(23px, 3vw, 38px);
  font-weight: 550;
  letter-spacing: -.035em;
  line-height: 1.15;
}

.cde-curve { margin: 0; }
.cde-legend { display: flex; flex-wrap: wrap; gap: 5px 16px; margin-top: 8px; }
.cde-legend li { display: flex; align-items: center; gap: 7px; color: var(--cde-muted); font-size: .875rem; }
.cde-legend li::before { content: ""; width: 19px; border-top: 2px solid #ae96ce; }
.cde-legend .cde-planned::before { border-top-style: dashed; }
.cde-legend .cde-actual::before { border-color: #a5dfd8; }

.cde-chart { display: block; width: 100%; height: auto; margin-top: 5px; }
.cde-chart text { fill: var(--cde-muted); font: 16px sans-serif; }
.cde-gridlines path { stroke: #4b4455; stroke-width: 1; }
.cde-chart-guide { stroke: #83728e; stroke-dasharray: 3 5; fill: none; }
.cde-series { fill: none; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.cde-planned-series { stroke: #ae96ce; }
polyline.cde-planned-series { stroke-dasharray: 7 6; }
.cde-actual-series { stroke: #a5dfd8; }
circle.cde-planned-series { fill: #ae96ce; }
circle.cde-actual-series { fill: #a5dfd8; }

.cde-curve > p { margin: 6px 0 0; color: var(--cde-muted); font-size: .875rem; line-height: 1.4; }

@media (max-width: 740px) {
  .cde-intro,
  .cde-flow-row,
  .cde-overview { grid-template-columns: minmax(0, 1fr); }
  .cde-connector { grid-template-columns: minmax(0, 1fr); }
  .cde-connector span:not(:first-child) { display: none; }
  .cde-chart text { font-size: 20px; }
}

@media (max-width: 420px) {
  .cde-hub h3 { align-items: flex-start; }
  .cde-chart text { font-size: 21px; }
}
