.tensor-section {
  position: relative;
  overflow: hidden;
  padding: 150px var(--pad) 130px;
  background:
    radial-gradient(circle at 73% 33%, rgba(255, 90, 54, .07), transparent 28%),
    var(--ink-950);
}

.tensor-section::before {
  position: absolute;
  inset: 0;
  content: "";
  pointer-events: none;
  opacity: .13;
  background-image:
    linear-gradient(rgba(190, 205, 214, .16) 1px, transparent 1px),
    linear-gradient(90deg, rgba(190, 205, 214, .16) 1px, transparent 1px);
  background-size: 68px 68px;
  mask-image: linear-gradient(to bottom, transparent, #000 16%, #000 78%, transparent);
}

.tensor-heading,
.tensor-stage,
.tensor-explainer {
  position: relative;
  z-index: 1;
}

.tensor-heading {
  display: grid;
  grid-template-columns: minmax(0, 8fr) minmax(260px, 3fr);
  gap: 7vw;
  align-items: end;
  max-width: 1500px;
  margin: 0 auto 80px;
}

.tensor-heading h2 {
  max-width: 980px;
  margin: 18px 0 0;
  font-size: clamp(52px, 6vw, 96px);
  line-height: .92;
  letter-spacing: -.055em;
}

.tensor-heading h2 em {
  font-family: var(--serif);
  font-weight: 400;
}

.tensor-heading > p {
  max-width: 420px;
  margin: 0 0 8px;
  color: rgba(235, 240, 239, .62);
  font-size: 17px;
  line-height: 1.55;
}

.tensor-stage {
  max-width: 1500px;
  margin: 0 auto;
  border: 1px solid rgba(190, 205, 214, .24);
  background: rgba(7, 19, 31, .77);
  box-shadow: 0 50px 140px rgba(0, 0, 0, .28);
  backdrop-filter: blur(12px);
}

.tensor-stage-head {
  display: flex;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(190, 205, 214, .18);
  color: rgba(235, 240, 239, .64);
  font: 9px var(--data);
  letter-spacing: .12em;
}

.tensor-stage-head i,
.route-status i {
  display: inline-block;
  width: 6px;
  height: 6px;
  margin-right: 8px;
  border-radius: 50%;
  background: var(--signal);
  box-shadow: 0 0 0 5px rgba(255, 90, 54, .1);
}

.tensor-stage-head b { font-weight: 500; }

.tensor-mode-switch {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-bottom: 1px solid rgba(190, 205, 214, .18);
}

.tensor-mode-switch button {
  min-height: 52px;
  border: 0;
  border-right: 1px solid rgba(190, 205, 214, .14);
  background: transparent;
  color: rgba(235, 240, 239, .5);
  font: 10px var(--data);
  letter-spacing: .08em;
  cursor: pointer;
  transition: color .25s, background .25s;
}

.tensor-mode-switch button:last-child { border-right: 0; }

.tensor-mode-switch button:hover,
.tensor-mode-switch button.active {
  color: var(--paper-050);
  background: rgba(255, 255, 255, .045);
}

.tensor-mode-switch button.active { box-shadow: inset 0 -2px var(--signal); }

.tensor-visual {
  position: relative;
  min-height: 670px;
  overflow: hidden;
}

#tensor-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  cursor: crosshair;
}

.tensor-axis,
.tensor-slice,
.tensor-cell-readout,
.tensor-operation {
  position: absolute;
  pointer-events: none;
}

.tensor-axis {
  color: rgba(235, 240, 239, .38);
  font: 8px var(--data);
  letter-spacing: .12em;
  transition: opacity .3s;
}

.tensor-axis b {
  display: block;
  margin-top: 7px;
  color: rgba(235, 240, 239, .8);
  font-weight: 500;
}

.axis-fed { top: 11%; left: 3%; }
.axis-eur { right: 3%; bottom: 9%; text-align: right; }
.axis-jpy { left: 3%; bottom: 9%; }

.tensor-slice {
  left: 3%;
  top: 21%;
  padding: 8px 10px;
  border-left: 1px solid var(--signal);
  background: rgba(7, 19, 31, .48);
  color: rgba(235, 240, 239, .38);
  font: 7px var(--data);
  letter-spacing: .1em;
  transition: opacity .3s;
}

.tensor-slice b {
  display: block;
  margin-top: 5px;
  color: rgba(235, 240, 239, .78);
  font-weight: 500;
}

.tensor-cell-readout {
  top: 9%;
  right: 3%;
  width: min(310px, 28vw);
  padding: 15px 16px;
  border-top: 1px solid rgba(235, 240, 239, .4);
  background: rgba(7, 19, 31, .58);
  backdrop-filter: blur(8px);
}

.tensor-cell-readout small {
  color: rgba(235, 240, 239, .44);
  font: 8px var(--data);
  letter-spacing: .12em;
}

.tensor-cell-readout strong {
  display: block;
  margin: 12px 0 20px;
  font-size: 14px;
  font-weight: 500;
}

.tensor-cell-readout > span {
  display: flex;
  align-items: end;
  justify-content: space-between;
}

.tensor-cell-readout b { color: var(--signal); font: 30px var(--data); }
.tensor-cell-readout i { color: rgba(235, 240, 239, .35); font: 7px var(--data); font-style: normal; }

.tensor-operation {
  left: 50%;
  bottom: 7%;
  min-width: 250px;
  padding: 11px 14px;
  border: 1px solid rgba(190, 205, 214, .16);
  background: rgba(7, 19, 31, .68);
  text-align: center;
  transform: translateX(-50%);
  backdrop-filter: blur(8px);
}

.tensor-operation span {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.tensor-operation i {
  width: 22px;
  height: 1px;
  background: var(--signal);
  box-shadow: 0 0 8px rgba(255, 90, 54, .55);
}

.tensor-operation small {
  color: rgba(235, 240, 239, .56);
  font-size: 7px;
}

.tensor-operation strong {
  display: block;
  margin-top: 6px;
  color: rgba(235, 240, 239, .82);
  font: 8px var(--data);
  letter-spacing: .08em;
}

.tensor-stage:not([data-tensor-mode="space"]) .tensor-axis { opacity: 0; }
.tensor-stage:not([data-tensor-mode="space"]) .tensor-slice { opacity: 0; }
.tensor-stage:not([data-tensor-mode="space"]) .tensor-operation { border-color: rgba(255, 90, 54, .35); }

.tensor-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid rgba(190, 205, 214, .18);
}

.tensor-stats span {
  min-height: 82px;
  padding: 20px;
  border-right: 1px solid rgba(190, 205, 214, .14);
  color: rgba(235, 240, 239, .42);
  font: 9px var(--data);
  letter-spacing: .08em;
}

.tensor-stats span:last-child { border-right: 0; }
.tensor-stats b { display: block; margin-bottom: 7px; color: var(--paper-050); font-size: 20px; }

.tensor-explainer {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  max-width: 1500px;
  margin: 30px auto 0;
  border-top: 1px solid rgba(190, 205, 214, .22);
  border-bottom: 1px solid rgba(190, 205, 214, .22);
}

.tensor-explainer article {
  min-height: 390px;
  padding: 30px;
  border-right: 1px solid rgba(190, 205, 214, .18);
}

.tensor-explainer article:last-child { border-right: 0; }
.tensor-index { color: var(--signal); font: 8px var(--data); letter-spacing: .12em; }
.tensor-explainer h3 { max-width: 330px; margin: 58px 0 14px; font-size: 30px; letter-spacing: -.03em; }
.tensor-explainer p { max-width: 370px; color: rgba(235, 240, 239, .48); font-size: 13px; line-height: 1.55; }

.claim-strip {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  height: 70px;
  margin-top: 58px;
  border: 1px solid rgba(190, 205, 214, .18);
}

.claim-strip i { border-right: 1px solid rgba(190, 205, 214, .16); background: rgba(255, 90, 54, .18); animation: claim-breathe 3.4s ease-in-out infinite; }
.claim-strip i:nth-child(2) { animation-delay: .18s; }
.claim-strip i:nth-child(3) { animation-delay: .36s; border-right: 0; }
.claim-strip.narrow i { background: transparent; }
.claim-strip.narrow i:first-child { background: rgba(255, 90, 54, .8); animation: claim-focus 2.6s ease-in-out infinite; }

.claim-strip span {
  position: absolute;
  left: 12px;
  bottom: 9px;
  color: rgba(235, 240, 239, .72);
  font: 8px var(--data);
  letter-spacing: .08em;
}

.route-graphic {
  display: grid;
  grid-template-columns: 62px 1fr 88px;
  align-items: center;
  height: 110px;
  margin-top: 28px;
}

.route-source {
  display: grid;
  place-items: center;
  width: 62px;
  height: 62px;
  border: 1px solid var(--signal);
  background: rgba(255, 90, 54, .1);
}

.route-source small,
.route-destinations small { color: rgba(235, 240, 239, .42); font: 7px var(--data); }
.route-source b { color: var(--signal); font: 18px var(--data); }
.route-lines { position: relative; height: 100%; overflow: hidden; }
.route-lines i { position: absolute; left: 0; width: 100%; height: 1px; background: rgba(190, 205, 214, .25); transform-origin: left; }
.route-lines i:nth-child(1) { top: 28%; transform: rotate(-13deg); }
.route-lines i:nth-child(2) { top: 50%; }
.route-lines i:nth-child(3) { top: 72%; transform: rotate(13deg); }

.route-lines span {
  position: absolute;
  left: -4px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--signal);
  box-shadow: 0 0 10px var(--signal);
  animation: route-packet 2.8s ease-in-out infinite;
}

.route-lines span:nth-of-type(1) { top: 20%; }
.route-lines span:nth-of-type(2) { top: 48%; animation-delay: .2s; }
.route-lines span:nth-of-type(3) { top: 76%; animation-delay: .4s; }

.route-destinations { display: grid; gap: 5px; }
.route-destinations span { display: flex; align-items: center; justify-content: space-between; padding: 7px 8px; border: 1px solid rgba(190, 205, 214, .18); }
.route-destinations b { font: 10px var(--data); }

.route-status {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-top: 13px;
  border-top: 1px solid rgba(190, 205, 214, .18);
  color: rgba(235, 240, 239, .46);
  font: 7px var(--data);
  letter-spacing: .08em;
}

.route-status b { margin-left: auto; color: var(--paper-050); font-weight: 500; }

@keyframes route-packet {
  0%, 12% { left: -4px; opacity: 0; }
  20% { opacity: 1; }
  76% { left: calc(100% - 4px); opacity: 1; }
  88%, 100% { left: calc(100% - 4px); opacity: 0; }
}

@keyframes claim-breathe {
  0%, 100% { background-color: rgba(255, 90, 54, .12); }
  50% { background-color: rgba(255, 90, 54, .3); }
}

@keyframes claim-focus {
  0%, 100% { box-shadow: inset 0 0 0 0 rgba(245, 241, 232, 0); }
  50% { box-shadow: inset 0 0 0 1px rgba(245, 241, 232, .5), 0 0 24px rgba(255, 90, 54, .16); }
}

@media (max-width: 980px) {
  .tensor-heading { grid-template-columns: 1fr; }
  .tensor-heading > p { max-width: 620px; }
  .tensor-visual { min-height: 590px; }
  .tensor-explainer { grid-template-columns: 1fr 1fr; }
  .tensor-explainer article:nth-child(2) { border-right: 0; }
  .tensor-explainer .route-card { grid-column: 1 / -1; min-height: 350px; border-top: 1px solid rgba(190, 205, 214, .18); }
  .route-graphic { max-width: 620px; }
}

@media (max-width: 700px) {
  .tensor-section { padding: 110px var(--pad) 90px; }
  .tensor-heading { margin-bottom: 48px; }
  .tensor-heading h2 { font-size: clamp(44px, 13vw, 68px); }
  .tensor-mode-switch { grid-template-columns: 1fr 1fr; }
  .tensor-mode-switch button:nth-child(-n+2) { border-bottom: 1px solid rgba(190, 205, 214, .14); }
  .tensor-visual { min-height: 500px; }
  .tensor-cell-readout { top: 14px; right: 14px; width: 220px; }
  .tensor-operation { bottom: 16px; min-width: 220px; }
  .tensor-axis { display: none; }
  .tensor-slice { display: none; }
  .tensor-stats { grid-template-columns: 1fr 1fr; }
  .tensor-stats span:nth-child(-n+2) { border-bottom: 1px solid rgba(190, 205, 214, .14); }
  .tensor-explainer { grid-template-columns: 1fr; }
  .tensor-explainer article,
  .tensor-explainer article:nth-child(2) { min-height: 350px; border-right: 0; border-bottom: 1px solid rgba(190, 205, 214, .18); }
  .tensor-explainer .route-card { grid-column: auto; border-top: 0; border-bottom: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .route-lines span { animation: none; left: 50%; opacity: 1; }
  .claim-strip i,
  .claim-strip.narrow i:first-child { animation: none; }
}
