.workflow-gallery {
  --pin-top: 88px;
  --chapter-length: clamp(265px, 49svh, 440px);
  margin-top: clamp(22px, 3.4vw, 48px);
}
.workflow-gallery[data-scroll] { min-height: calc(var(--story-height) + var(--chapter-length) * 7); }
.workflow-stage {
  margin: 0;
  padding: clamp(10px, 1.6vw, 23px);
  border: 1px solid #a9bdad;
  background: #edf1e7;
  color: var(--industry-ink);
}
.workflow-gallery[data-scroll] .workflow-stage { position: sticky; top: var(--pin-top); }
.workflow-stage figcaption, .workflow-tools {
  display: flex;
  align-items: center;
  gap: 5px 12px;
  flex-wrap: wrap;
}
.workflow-stage figcaption { justify-content: space-between; color: #385647; font: 400 clamp(.68rem, 1vw, .84rem)/1.35 var(--industry-mono); }
.workflow-stage figcaption strong { color: #214c35; font-weight: 500; }
.workflow-count { color: #436653; font-variant-numeric: tabular-nums; }
.workflow-scroll-cue { display: none; }
.workflow-gallery[data-scroll] .workflow-scroll-cue { display: inline; }
.workflow-picks, .workflow-steps, .workflow-count { display: none; }
.workflow-gallery[data-ready] .workflow-picks, .workflow-gallery[data-scroll] .workflow-steps { display: flex; }
.workflow-gallery[data-ready] .workflow-count { display: inline; }
.workflow-picks {
  flex-wrap: wrap;
  gap: 0 clamp(1px, 1.2vw, 15px);
  margin-block: 7px 9px;
  border-block: 1px solid #a8bbac;
}
.workflow-stage button {
  min-height: 37px;
  padding: 6px 6px;
  border: 0;
  background: transparent;
  color: #284f39;
  font: 520 clamp(.72rem, 1.06vw, .94rem)/1.15 Geist, sans-serif;
  cursor: pointer;
}
.workflow-stage button:hover { text-decoration: underline; text-underline-offset: 4px; }
.workflow-stage button:focus-visible { outline: 2px solid #267b50; outline-offset: -2px; }
.workflow-picks button[aria-pressed="true"] { box-shadow: inset 0 -2px #286949; font-weight: 650; }
.workflow-scenes { display: grid; gap: 14px; margin-top: 8px; }
.workflow-gallery[data-scroll] .workflow-scenes {
  position: relative;
  display: block;
  height: clamp(220px, 100svh - 305px, 352px);
  overflow: clip;
}
.workflow-scene {
  position: relative;
  isolation: isolate;
  display: grid;
  align-items: center;
  align-content: center;
  justify-content: center;
  box-sizing: border-box;
  min-width: 0;
  min-height: 310px;
  padding: 30px clamp(12px, 3vw, 46px) 16px;
  overflow: clip;
  background: radial-gradient(ellipse at 83% 20%, var(--scene-light, #d7e7ce), transparent 70%), var(--scene-base, #e6eee1);
  --p: 1;
  --a: 1;
  --b: 1;
  --c: 1;
}
.workflow-gallery[data-scroll] .workflow-scene {
  position: absolute;
  inset: 0;
  min-height: 0;
  padding-top: 16px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity .21s, visibility 0s linear .21s;
}
.workflow-gallery[data-scroll] .workflow-scene[data-active] {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  z-index: 1;
  transition: opacity .21s;
}
.workflow-scene-title {
  position: absolute;
  inset: 12px auto auto 14px;
  z-index: 1;
  margin: 0;
  color: var(--chapter-ink, #294b37);
  font: 500 .73rem/1.25 var(--industry-mono) !important;
}
.workflow-gallery[data-scroll] .workflow-scene-title { clip-path: inset(50%); width: 1px; height: 1px; overflow: hidden; }
.workflow-sheet {
  min-width: 0;
  border: 1px solid #a7b9a9;
  border-radius: 7px;
  background: #fafbf4;
  color: #1b3d2b;
  box-shadow: 0 15px 32px -24px #182e24b2;
}
.workflow-sheet-head, .workflow-kicker {
  color: #385e48;
  font: 500 clamp(.65rem, 1.05vw, .81rem)/1.3 var(--industry-mono);
}
.workflow-sheet-head { display: flex; align-items: center; gap: 6px; border-bottom: 1px solid #b4c8b5; padding: 0 0 8px; }
.workflow-confirm { color: #285a40; font: 500 clamp(.65rem, 1.06vw, .81rem)/1.3 var(--industry-mono); }
.workflow-confirm span { margin-right: 3px; }

/* A message exchange resolves into a separate viewing confirmation. */
.estate-scene {
  --scene-base: #203b2d;
  --scene-light: #385a45;
  --chapter-ink: #d8ebd9;
  grid-template-columns: minmax(0, 370px) minmax(0, 249px);
  gap: clamp(13px, 4vw, 58px);
}
.estate-thread, .estate-ticket { padding: clamp(10px, 1.65vw, 23px); }
.estate-thread { display: grid; gap: clamp(6px, 1vw, 15px); }
.estate-thread-dot { width: 8px; aspect-ratio: 1; border-radius: 50%; background: #417d54; }
.industry-page .estate-thread p { margin: 0; padding: 7px 10px; font-size: clamp(.8rem, 1.28vw, 1.03rem); color: #193d2c; line-height: 1.3; }
.estate-in { justify-self: start; background: #ebefe7; border-radius: 1px 10px 10px 10px; transform: translateX(calc((1 - var(--a)) * -24px)); opacity: calc(.48 + var(--a) * .52); }
.estate-out { justify-self: end; background: #d9ecd2; border-radius: 10px 1px 10px 10px; transform: translateX(calc((1 - var(--b)) * 34px)); opacity: var(--b); }
.estate-ticket {
  display: grid;
  gap: 6px;
  position: relative;
  background: #dcebd5;
  border-left: 3px solid #75a777;
  transform: translateX(calc((1 - var(--c)) * -49px)) rotate(calc((1 - var(--c)) * -6deg));
  opacity: var(--c);
}
.estate-ticket strong { font-size: clamp(1.16rem, 2.1vw, 2.15rem); font-weight: 550; line-height: 1.06; letter-spacing: -.045em; }
.estate-ticket .workflow-confirm { margin-top: 4px; padding-top: 7px; border-top: 1px dashed #7ca589; }

/* A form is filed into a calendar slot and the reminder follows. */
.health-scene { --scene-light: #c5e5dd; grid-template-columns: minmax(0, 540px); }
.health-calendar { padding: clamp(11px, 2vw, 23px); }
.health-slots { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); margin-top: 9px; gap: 5px; }
.health-slots span { position: relative; min-width: 0; padding: clamp(10px, 2vw, 25px) 4px; border: 1px solid #abc1b2; text-align: center; font: 500 clamp(.72rem, 1.45vw, 1rem)/1 var(--industry-mono); }
.health-slots .health-slot { isolation: isolate; }
.health-slot::before { content: ""; position: absolute; inset: 0; z-index: -1; background: #c1e3d2; transform: scaleX(var(--b)); transform-origin: left; }
.health-slot i { position: absolute; right: 4px; top: 4px; opacity: var(--b); font-style: normal; color: #206a48; }
.health-form {
  position: absolute;
  z-index: 1;
  left: calc(30% + var(--a) * 20%);
  top: calc(25% + var(--a) * 31%);
  padding: 9px 13px;
  transform: translate(-50%, -50%) scale(calc(1 - var(--b) * .36));
  opacity: calc(1 - var(--b));
  white-space: nowrap;
  font-size: clamp(.78rem, 1.28vw, 1rem);
}
.health-form span { margin-right: 4px; color: #206a48; }
.health-reminder {
  position: absolute;
  right: 10%;
  bottom: clamp(13px, 4%, 22px);
  display: grid;
  gap: 3px;
  padding: 8px 12px;
  background: #e5f2e8;
  opacity: var(--c);
  transform: translateY(calc((1 - var(--c)) * -28px));
  font-size: clamp(.74rem, 1.2vw, .94rem);
}
.health-reminder span { font: 500 .73em/1.2 var(--industry-mono); }

/* Papers align and tuck behind a folding onboarding folder. */
.legal-scene { --scene-base: #eee7da; --scene-light: #e4d2b7; }
.legal-papers { position: absolute; inset: 0; }
.legal-paper {
  position: absolute;
  width: min(39%, 260px);
  height: clamp(95px, 15vw, 162px);
  padding: clamp(8px, 1.3vw, 17px);
  left: calc(26% + var(--b) * 35%);
  top: calc(43% + var(--b) * 3%);
  transform: translate(-50%, -50%) rotate(calc(-13deg + var(--a) * 13deg));
  display: grid;
  align-content: start;
  gap: 4px;
}
.legal-paper:nth-child(2) {
  left: calc(38% + var(--b) * 26%);
  top: calc(57% - var(--b) * 9%);
  transform: translate(-50%, -50%) rotate(calc(13deg - var(--a) * 13deg));
}
.legal-paper strong, .legal-folder strong { font-size: clamp(.88rem, 1.62vw, 1.44rem); line-height: 1.1; }
.legal-paper i, .hr-form > i { height: 28px; margin-top: 5px; background: repeating-linear-gradient(0deg,transparent 0 6px,#adbcaa 6px 7px,transparent 7px 9px); }
.legal-folder {
  position: absolute;
  left: 64%;
  top: 60%;
  width: min(44%, 310px);
  height: clamp(79px, 12vw, 137px);
  opacity: calc(.24 + var(--b) * .76);
  transform: translate(-50%, -50%);
}
.legal-folder-back, .legal-folder-front { position: absolute; inset: 0; border: 1px solid #8b7659; border-radius: 2px 7px 7px 7px; }
.legal-folder-back { inset: -16% 2% 5% 0; background: #bc9e73; z-index: -1; }
.legal-folder-front {
  display: grid;
  align-content: center;
  gap: 4px;
  padding: 9px 14px;
  background: #dfc59d;
  color: #382d20;
  transform-origin: bottom center;
  transform: perspective(280px) rotateX(calc((1 - var(--c)) * 52deg));
}
.legal-folder-front strong, .legal-folder-front span { opacity: var(--c); }
.legal-folder-front span { font: 500 .72rem/1.15 var(--industry-mono); }

/* A policy lookup highlights the matching source and cites it in the reply. */
.commerce-scene { --scene-base: #eee9d9; --scene-light: #e8d7af; grid-template-columns: minmax(0, 710px); }
.commerce-workspace { display: grid; grid-template-columns: minmax(0,1.04fr) minmax(0, .96fr); padding: clamp(8px, 1.8vw, 22px); gap: clamp(7px, 1.3vw, 17px); }
.commerce-question { display: grid; align-content: center; gap: 7px; }
.commerce-question strong, .commerce-reply strong { font-size: clamp(.81rem, 1.75vw, 1.38rem); line-height: 1.15; }
.commerce-lookup { display: grid; align-content: center; gap: 4px; font: 500 clamp(.67rem, 1.2vw, .89rem)/1.22 var(--industry-mono); }
.commerce-lookup span { position: relative; isolation: isolate; padding: 5px; border: 1px solid #adbaaa; }
.commerce-lookup span:last-child::before { position: absolute; inset: 0; content: ""; z-index: -1; background: #eeddb5; transform: scaleX(var(--b)); transform-origin: left; }
.commerce-lookup i { font-style: normal; opacity: var(--b); }
.commerce-reply { grid-column: 1/-1; display: grid; gap: 5px; border-top: 1px solid #acbfae; padding: 9px 0 0; clip-path: inset(0 calc((1 - var(--c)) * 100%) 0 0); }
.commerce-citation { color: #634f2a; font: 500 clamp(.65rem,1vw,.75rem)/1 var(--industry-mono); }
.commerce-citation i { font-style: normal; }

/* Checkpoints are completed in sequence before the onboarding handoff. */
.hr-scene { --scene-light: #e1d9e9; grid-template-columns: minmax(0, 320px) minmax(0, 235px); gap: clamp(8px, 4vw, 53px); }
.hr-path { position: relative; display: grid; gap: 11px; padding-block: 5px; }
.hr-path::before { content: ""; position: absolute; top: 12%; bottom: 13%; left: 10px; border-left: 1px solid #718879; }
.hr-path::after { content: ""; position: absolute; top: 12%; bottom: 13%; left: 10px; width: 2px; background: #527f67; transform: scaleY(var(--c)); transform-origin: top; }
.hr-step { position: relative; z-index: 1; display: grid; grid-template-columns: 22px 1fr; gap: 7px; align-items: center; color: #254c36; font-size: clamp(.75rem, 1.48vw, 1.12rem); }
.hr-step:nth-child(1) { --check: var(--a); }
.hr-step:nth-child(2) { --check: var(--b); }
.hr-step:nth-child(3) { --check: var(--c); }
.hr-step i { display: grid; place-items: center; width: 21px; aspect-ratio: 1; border: 1px solid #729485; border-radius: 5px; background: #f7faf1; color: rgb(29 98 64 / var(--check)); font-style: normal; }
.hr-form { display: grid; gap: 4px; padding: clamp(8px,1.5vw,17px); opacity: calc(.24 + var(--c) * .76); transform: translateY(calc((1 - var(--c)) * 19px)); }
.hr-form strong { font-size: clamp(.84rem,1.7vw,1.3rem); }
.hr-form .workflow-confirm { opacity: var(--c); }

/* An enquiry resolves in-language within an itinerary-style display. */
.travel-scene { --scene-base: #1b303a; --scene-light: #314f58; --chapter-ink: #d7ebec; grid-template-columns: minmax(0, 675px); }
.travel-board { display: grid; color: #ebf4e9; border-block: 1px solid #b1ced181; }
.travel-board .workflow-kicker { color: #c0dada; }
.travel-query, .travel-reply { display: grid; gap: 4px; padding: clamp(8px, 1.38vw, 17px) 3px; }
.travel-query strong, .travel-reply strong { font-size: clamp(.98rem, 2.48vw, 2.2rem); font-weight: 530; line-height: 1.08; letter-spacing: -.035em; }
.travel-language { display: flex; justify-content: space-between; align-items: center; gap: 6px; border-block: 1px solid #8bb0b185; padding: 7px 3px; color: #c5d9d8; font: 500 clamp(.66rem, 1.2vw, .84rem)/1.15 var(--industry-mono); }
.travel-language strong { color: #dbf1d0; opacity: var(--b); transform: perspective(180px) rotateX(calc((1 - var(--b)) * 100deg)); }
.travel-reply { opacity: var(--c); clip-path: inset(0 calc((1 - var(--c)) * 100%) 0 0); transform: translateX(calc((1 - var(--c)) * -13px)); }

/* A scanning pass extracts the visible record fields into the report. */
.logistics-scene { --scene-base: #e7ebdb; --scene-light: #c8dbad; grid-template-columns: minmax(0, 310px) minmax(0, 300px); gap: clamp(8px, 4vw, 53px); }
.logistics-packet, .logistics-report { position: relative; display: grid; gap: 8px; overflow: clip; padding: clamp(8px,1.5vw,20px); }
.logistics-fields { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 7px 4px; font: 500 clamp(.67rem,1.12vw,.85rem)/1.3 var(--industry-mono); }
.logistics-fields span { color: #405949; }
.logistics-scan { position: absolute; left: 0; right: 0; top: calc(7% + var(--b) * 89%); height: 18px; border-top: 1px solid #3f7952; background: linear-gradient(#a2c88b63, transparent); opacity: calc(var(--a) * (1 - var(--c))); }
.logistics-report .logistics-fields { clip-path: inset(0 0 calc((1 - var(--b)) * 100%) 0); }
.logistics-report .workflow-confirm { opacity: var(--c); }

.workflow-steps {
  position: relative;
  align-items: center;
  margin-top: 10px;
  border-top: 1px solid #a0b7a5;
}
.workflow-steps::before {
  content: "";
  position: absolute;
  top: -1px;
  inset-inline: 0;
  height: 2px;
  background: #317950;
  transform: scaleX(var(--workflow-progress, 0));
  transform-origin: left;
  pointer-events: none;
}
.workflow-steps button { flex: 1; text-align: left; font-family: var(--industry-mono); }
.workflow-steps button + button { border-left: 1px solid #b3c4b2; }
.workflow-steps button[aria-pressed="true"] { color: #11452b; font-weight: 650; }
.workflow-status { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.industry-flow-list {
  margin: clamp(22px, 3.8vw, 52px) 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  column-gap: clamp(19px, 4.2vw, 60px);
}
.industry-flow-list li { padding: 12px 6px; border-top: 1px solid var(--industry-line); }
.industry-page .industry-flow-list h3 { font-size: clamp(1.15rem, 1.8vw, 1.55rem); font-weight: 575; line-height: 1.16; letter-spacing: -.04em; }
.industry-page .industry-flow-list p { margin: 5px 0 0; color: var(--industry-muted); }
@media (max-width: 730px) {
  .workflow-gallery[data-scroll] .workflow-scenes { height: clamp(225px, 100svh - 300px, 315px); }
  .workflow-stage button { min-height: 34px; }
  .workflow-stage figcaption strong { display: none; }
  .workflow-gallery[data-scroll] .workflow-scroll-cue { display: none; }
  .workflow-scene { min-height: 246px; }
  .estate-scene { grid-template-columns: minmax(0,1fr); gap: 9px; }
  .estate-thread, .estate-ticket { width: min(100%,340px); justify-self: center; }
  .health-form { left: calc(45% + var(--a) * 5%); }
  .health-reminder { right: 8%; }
  .hr-scene { grid-template-columns: minmax(0,1fr); gap: 8px; }
  .hr-path, .hr-form { width: min(100%,315px); justify-self: center; }
  .hr-form > i { height: 13px; }
  .industry-flow-list { grid-template-columns: minmax(0,1fr); }
}
@media (min-width: 850px) {
  html[data-static] .workflow-scenes { grid-template-columns: repeat(2,minmax(0,1fr)); }
  html[data-static] .workflow-scene { min-height: 254px; gap: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .workflow-gallery[data-scroll] .workflow-scene { transition: none; }
}
