.desk-flow {
  --df-ink: #252332;
  --df-muted: #696775;
  --df-line: #dfdde5;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--df-line);
  border-radius: 15px;
  background: #fff;
  color: var(--df-ink);
  box-shadow: 0 2px 5px #34274608;
  container: desk-flow / inline-size;
}
.desk-flow button {
  font-family: inherit;
  line-height: 1.35;
}
.desk-flow :focus-visible {
  outline: 2px solid #684ba0;
  outline-offset: 3px;
}
.df-title, .df-detail-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.df-title {
  padding: 15px 20px 13px;
  border-bottom: 1px solid var(--df-line);
}
.df-title h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 760;
  line-height: 1.4;
  letter-spacing: -.035em;
}
.df-header-links, .df-tracking-select { display: flex; align-items: center; gap: 8px; min-width: 0; }
.df-header-links { gap: 12px; }
.df-tracking-select span {
  color: var(--df-muted);
  white-space: nowrap;
  font-size: 12px;
  font-weight: 600;
}
.df-tracking-select select {
  max-width: min(22cqw, 190px);
  min-width: 80px;
  width: 120px;
  border: 1px solid var(--df-line);
  border-radius: 6px;
  padding: 4px 3px 4px 6px;
  background: #fbfafc;
  color: #44404e;
  font: inherit;
  font-size: 12px;
  line-height: 1.4;
  text-overflow: ellipsis;
}
.df-overview, .df-open, .df-proof {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border: 0;
  padding: 4px;
  background: transparent;
  color: #565161;
  font-size: 13px;
  font-weight: 650;
  white-space: nowrap;
}
.df-overview:hover, .df-open:hover, .df-proof:hover { color: #823c81; text-decoration: underline; }
.df-overview svg, .df-open svg, .df-proof svg { width: 15px; height: 15px; flex-shrink: 0; }
.df-detail-links { display: flex; align-items: center; flex-wrap: wrap; justify-content: end; gap: 3px 8px; }
.df-proof { color: #825035; }
.df-canvas {
  position: relative;
  padding: 14px 19px 12px;
  isolation: isolate;
  background-color: #fcfbfd;
  background-image: radial-gradient(#dcd7e4 .8px, transparent .9px);
  background-position: 4px 3px;
  background-size: 12px 12px;
}
.df-candidates {
  display: flex;
  gap: 6px;
  align-items: center;
  min-width: 0;
}
.df-candidates strong, .df-empty {
  color: var(--df-muted);
  font-size: 12px;
  line-height: 1.5;
}
.df-candidates strong {
  flex-shrink: 0;
  padding-right: 2px;
  color: #575562;
  font-weight: 650;
}
.df-chip {
  display: inline-flex;
  align-items: center;
  min-width: 0;
  max-width: 185px;
  overflow: hidden;
  border: 1px solid #e0dce5;
  border-radius: 6px;
  padding: 4px 8px;
  background: #fff;
  color: #4c4755;
  font-size: 12px;
  font-weight: 560;
  box-shadow: 0 1px 1px #2e263505;
}
.df-chip span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.df-chip:hover, .df-chip[aria-pressed=true] {
  border-color: #dcab7c;
  background: #fff5ea;
  color: #78471e;
}
.df-track-window {
  margin: 8px -7px 0;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: thin;
  scrollbar-color: #c7c2d0 transparent;
}
.df-map { min-width: 470px; }
.df-track {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  position: relative;
  padding: 12px 3px 5px;
}
.df-branches {
  height: 38px;
  margin: -2px 3px 0;
  position: relative;
}
.df-branch-label {
  position: absolute;
  left: 0;
  top: 10px;
  padding: 1px 4px 1px 0;
  color: var(--df-muted);
  font-size: 12px;
  font-weight: 600;
}
.df-wires { position: absolute; inset: 0; width: 100%; height: 36px; pointer-events: none; }
.df-wires path { vector-effect: non-scaling-stroke; stroke-width: 1.2; }
.df-return-wire { stroke: #bc8b7c; stroke-dasharray: 3 2; }
.df-pass-wire { stroke: #7ca38b; }
.df-branch {
  position: absolute;
  top: 6px;
  transform: translateX(-50%);
  min-height: 26px;
  border: 1px solid currentColor;
  border-radius: 10px;
  padding: 2px 8px;
  font-size: 12px;
  font-weight: 640;
  white-space: nowrap;
}
.df-return { left: 50%; border-color: #dbb8a7; background: #fcf4ed; color: #87553d; }
.df-pass { left: 71.43%; border-color: #acd3b6; background: #eff8ef; color: #39644b; }
.df-branch:hover { border-color: currentColor; }
.df-node, .df-spec { --df-accent: #428b8a; --df-figure: #73cec5; --df-stroke: #275e60; --df-tint: #e8f7f3; }
[data-df-step=trend], [data-df-detail=trend] { --df-accent: #b66b30; --df-figure: #fab06d; --df-stroke: #854718; --df-tint: #fff1e1; }
[data-df-step=write], [data-df-detail=write] { --df-accent: #8461a5; --df-figure: #bd9fe1; --df-stroke: #5e4779; --df-tint: #f4effa; }
[data-df-step=design], [data-df-detail=design] { --df-accent: #b65e7f; --df-figure: #f3a5c1; --df-stroke: #904862; --df-tint: #fff0f5; }
[data-df-step=check], [data-df-detail=check] { --df-accent: #9b7d35; --df-figure: #efd37a; --df-stroke: #755d23; --df-tint: #fff7dd; }
[data-df-step=send], [data-df-detail=send] { --df-accent: #55886b; --df-figure: #99d7a6; --df-stroke: #3c6a4d; --df-tint: #ebf6ed; }
[data-df-step=measure], [data-df-detail=measure] { --df-accent: #557da9; --df-figure: #96bce3; --df-stroke: #3b597d; --df-tint: #edf4fc; }
.df-node {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  position: relative;
  min-width: 0;
  padding: 4px 0;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: #4d4957;
}
.df-node:not(:last-child)::before {
  content: "";
  position: absolute;
  top: 24px;
  left: calc(50% + 24px);
  width: calc(100% - 48px);
  height: 1px;
  background: repeating-linear-gradient(to right, #a6a0b0 0 3px, transparent 3px 6px);
}
.df-node:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 22px;
  left: calc(150% - 30px);
  width: 4px;
  height: 4px;
  border-top: 1px solid #a6a0b0;
  border-right: 1px solid #a6a0b0;
  transform: rotate(45deg);
}
.df-piece {
  display: grid;
  place-items: center;
  position: relative;
  width: 41px;
  height: 41px;
  border: 1px solid color-mix(in srgb, var(--df-accent) 46%, white);
  border-radius: 13px;
  background: var(--df-tint);
  box-shadow: inset 0 1px 0 white, 0 2px 0 color-mix(in srgb, var(--df-accent) 22%, white);
  transition: transform .15s ease;
}
.df-piece svg { width: 35px; height: 35px; }
.df-node-name { font-size: 13px; font-weight: 650; line-height: 1.4; }
.df-node[aria-pressed=true] .df-piece {
  outline: 1px dashed var(--df-accent);
  outline-offset: 3px;
}
.df-node[aria-pressed=true] .df-node-name { color: var(--df-stroke); }
.df-node[aria-current=step] .df-piece::after {
  content: "";
  position: absolute;
  width: 10px;
  height: 10px;
  right: -3px;
  top: -3px;
  border: 2px solid white;
  border-radius: 50%;
  background: #37323e;
  box-shadow: 0 0 0 1px #716e7c;
}
.df-node:hover .df-piece { transform: translateY(-2px); }
.df-tracked:not([hidden]) {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 18px;
  border-top: 1px solid var(--df-line);
  background: #f4f2f7;
}
.df-tracked > div { min-width: 0; }
.df-tracked b { display: block; font-size: 14px; overflow-wrap: anywhere; }
.df-tracked small { display: block; color: var(--df-muted); font-size: 12px; }
.df-detail {
  border-top: 1px solid var(--df-line);
  padding: 10px 19px 13px;
}
.df-role {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--df-stroke);
  font-size: 14px;
  font-weight: 730;
}
.df-role i { width: 8px; height: 8px; border-radius: 2px; background: var(--df-figure); border: 1px solid var(--df-accent); }
.df-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 20px; margin: 3px 0 0; }
.df-fields > div { display: flex; align-items: baseline; gap: 8px; min-width: 0; }
.df-fields dt, .df-fields dd { margin: 0; font-size: 13px; line-height: 1.5; }
.df-fields dt { flex-shrink: 0; color: var(--df-muted); }
.df-fields dd { color: var(--df-ink); overflow-wrap: anywhere; }
.df-source { display: block; color: var(--df-muted); }
@container desk-flow (max-width: 490px) {
  .df-title { padding: 12px 14px; flex-wrap: wrap; gap: 6px 12px; }
  .df-header-links { flex: 1 0 auto; justify-content: space-between; }
  .df-tracked:not([hidden]) { padding: 8px 13px; }
  .df-canvas { padding: 12px 13px 9px; }
  .df-candidates { flex-wrap: wrap; }
  .df-chip { max-width: min(160px, 62%); }
  .df-detail { padding: 8px 13px 12px; }
  .df-fields { grid-template-columns: 1fr; }
  .df-track { padding-top: 9px; }
}
@media (prefers-reduced-motion: reduce) { .df-piece { transition: none; } }

.df-node .df-piece {border-radius:50%;background:linear-gradient(150deg,#fff,var(--df-tint));}
.df-node[aria-pressed=true] .df-piece {outline-style:solid;box-shadow:0 0 0 6px var(--df-tint);}
