.research-cycle {
  --signal: #91e9df;
  --socket: clamp(30px, 3vw, 40px);
  --rail-inset: 10px;
  position: relative;
  width: 100%;
  min-width: 0;
  aspect-ratio: 1.64;
  isolation: isolate;
  color: #cddadd;
}
.research-cycle[data-cycle-stage="collect"] { --signal: #92c6f1; }
.research-cycle[data-cycle-stage="conclude"] { --signal: #cabcff; }
.research-cycle[data-cycle-stage="verify"] { --signal: #a2edc3; }
.research-cycle::before {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(circle, #9dc7d542 .78px, transparent .92px) 50% 50% / 12px 12px;
  mask-image: radial-gradient(ellipse at center, #0009 15%, #0006 48%, transparent 72%);
}
.research-cycle .brain-visual {
  position: absolute;
  z-index: 1;
  left: 50%;
  top: 50%;
  width: min(54%, 360px);
  aspect-ratio: 1.5;
  transform: translate(-50%, -50%);
}
.research-cycle .cycle-drawing, .research-cycle .cycle-stations {
  position: absolute;
  inset: var(--rail-inset) 0;
  width: 100%;
  height: calc(100% - 2 * var(--rail-inset));
  overflow: visible;
  pointer-events: none;
}
.cycle-drawing path {
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  vector-effect: non-scaling-stroke;
}
.cycle-conductors path { stroke: #6d94a8; stroke-width: .8; opacity: .43; }
.cycle-route-bed { stroke: #84c3be; stroke-width: 5; opacity: .052; }
.cycle-route { stroke-width: 1.35; opacity: .9; }
.cycle-segment { stroke: var(--signal); stroke-width: 1.85; opacity: .58; }
.cycle-port-ticks path { stroke: #acc9cf; stroke-width: 1.45; }
.cycle-tail { stroke: var(--signal); }
.cycle-tail-0 { stroke-width: 3.5; opacity: .21; }
.cycle-tail-1 { stroke-width: 2.7; opacity: .67; }
.cycle-tail-2 { stroke-width: 2; stroke: #e9fffb; }
.cycle-signal { fill: var(--signal); }
.cycle-signal circle:last-child { fill: #effffb; }
.research-cycle .cycle-stations { z-index: 2; }
.research-cycle .cycle-station {
  --terminal-color: #728f9a;
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: max-content;
  max-width: 39%;
  min-width: 44px;
  min-height: 44px;
  margin: 0;
  padding: 0 2px;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: #c0d1d4;
  transform: translateX(-50%);
  text-align: center;
  cursor: pointer;
  pointer-events: auto;
  -webkit-tap-highlight-color: transparent;
}
.cycle-station[data-stage-trigger="ask"], .cycle-station[data-stage-trigger="verify"] { left: 25%; }
.cycle-station[data-stage-trigger="collect"], .cycle-station[data-stage-trigger="conclude"] { left: 75%; }
.research-cycle .cycle-station:is([data-stage-trigger="ask"], [data-stage-trigger="collect"]) {
  bottom: calc(81.25% - var(--socket) / 2);
  flex-direction: column-reverse;
}
.cycle-station:is([data-stage-trigger="conclude"], [data-stage-trigger="verify"]) {
  top: calc(81.25% - var(--socket) / 2);
}
.cycle-station-label {
  display: block;
  font: 600 clamp(.84rem, 1.13vw, 1.1rem)/1.21 var(--body-font, system-ui, sans-serif);
  text-wrap: balance;
  overflow-wrap: anywhere;
  text-shadow: 0 1px 5px #07131b, 0 1px 10px #07131b;
}
.cycle-station:lang(zh) .cycle-station-label { letter-spacing: .03em; }
.cycle-terminal {
  position: relative;
  display: grid;
  width: var(--socket);
  height: var(--socket);
  place-items: center;
  color: var(--terminal-color);
  filter: drop-shadow(0 1px 4px #071017);
}
.cycle-terminal::before, .cycle-terminal::after {
  content: '';
  position: absolute;
  inset: 0;
  clip-path: polygon(21% 0, 88% 0, 100% 12%, 100% 79%, 79% 100%, 12% 100%, 0 88%, 0 21%);
}
.cycle-terminal::before { background: var(--terminal-color); }
.cycle-terminal::after { inset: 1px; background: #10202a; }
.cycle-terminal svg {
  position: relative;
  z-index: 1;
  width: 62%;
  height: 62%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.65;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.research-cycle .cycle-station[aria-pressed="true"] { --terminal-color: var(--signal); color: var(--signal); }
.cycle-station[aria-pressed="true"] .cycle-terminal {
  filter: drop-shadow(0 0 8px color-mix(in srgb, var(--signal) 42%, transparent));
}
.cycle-station[aria-pressed="true"] .cycle-terminal::after {
  background: linear-gradient(135deg, color-mix(in srgb, var(--signal) 25%, #11232e), #10202a 85%);
}
.cycle-station.cycle-receiving .cycle-terminal::before { background: var(--signal); }
.cycle-station.cycle-receiving .cycle-terminal svg { color: #d9eceb; }
.cycle-station:is(:hover, :focus-visible) .cycle-terminal { --terminal-color: #defffc; }
.cycle-station:is(:hover, :focus-visible) .cycle-station-label { color: #effffa; }
@media (max-width: 720px) {
  .research-cycle { --rail-inset: 18px; --socket: 31px; min-height: 240px; aspect-ratio: 1.45; }
  .research-cycle .brain-visual { width: min(56%, 300px); }
  .cycle-station-label { font-size: .9rem; }
}
@media (max-width: 380px) {
  .research-cycle { --rail-inset: 20px; --socket: 29px; }
  .cycle-station-label { font-size: .82rem; }
}
@media (forced-colors: active) {
  .cycle-route, .cycle-port-ticks path { stroke: CanvasText; }
  .cycle-station { color: ButtonText; }
  .cycle-terminal::before { background: ButtonText; }
  .cycle-terminal::after { background: Canvas; }
  .cycle-station[aria-pressed="true"] .cycle-station-label { text-decoration: underline; }
  .cycle-signal circle, .cycle-signal circle:last-child { fill: Highlight; }
}
