/* A vertical counterpart to the KRT verification diagram. */
.ca-stage .ca-plan-sequence {
  --lab-ink: #26363d;
  --lab-line: rgb(48 71 82 / .32);
  --lab-paper: rgb(248 249 244 / .93);
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto 36px auto 30px minmax(0, 1fr) 38px auto;
  align-content: center;
  min-width: 0;
  margin: 0;
  padding: clamp(26px, 2.8vw, 42px) clamp(20px, 2.4vw, 36px);
  overflow: hidden;
  background: linear-gradient(90deg, var(--ca-story-blue), var(--ca-story-cream));
  color: var(--lab-ink);
  container-type: inline-size;
}
.ca-plan-sequence svg { display: block; width: 100%; height: auto; }
.ca-lab__variants {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(7px, 2cqw, 14px) clamp(9px, 3cqw, 22px);
}
.ca-lab__option {
  min-width: 0;
  padding: 6px;
  border: 1px solid transparent;
  opacity: .43;
  transition: opacity 280ms ease, border-color 280ms ease;
}
.ca-lab__option.is-selected { opacity: 1; border-color: var(--accent); }
.ca-lab__option.is-final { opacity: 1; border-color: var(--accent); }
.ca-lab__option.is-scanning { opacity: .68; border-color: rgb(239 43 36 / .78); }
.ca-plan-sequence .ca-lab__connector { height: 100%; overflow: visible; }
.ca-lab__connector path { fill: none; stroke: var(--accent); stroke-opacity: .58; stroke-width: 1; vector-effect: non-scaling-stroke; }
.ca-lab__connector circle { fill: var(--accent); stroke: none; }
.ca-lab__system { display: grid; gap: 8px; }
.ca-plan-sequence ul { margin: 0; padding: 0; list-style: none; }
.ca-lab__inputs,
.ca-lab__programme,
.ca-lab__checks { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.ca-lab__inputs li,
.ca-lab__programme li,
.ca-lab__checks li {
  min-width: 0;
  border: 1px solid var(--lab-line);
  border-radius: 10px;
  font-size: clamp(10px, 2.1cqw, 14px);
  font-weight: 500;
  line-height: 1.14;
  letter-spacing: -.025em;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}
.ca-lab__inputs li {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 62px;
  padding: 10px;
  background: var(--lab-paper);
}
.ca-lab__inputs svg { flex: 0 0 24px; width: 24px; fill: none; stroke: #6a838d; stroke-width: 1.15; }
.ca-lab__expert {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 42px;
  margin: 0;
  padding: 10px;
  border: 1px solid var(--lab-line);
  border-radius: 10px;
  background: var(--lab-paper);
  font-size: clamp(10px, 2.1cqw, 13px);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: -.02em;
  text-transform: uppercase;
  text-align: center;
}
.ca-lab__expert b { color: var(--accent); font-size: 20px; font-weight: 400; opacity: var(--signal, 1); }
.ca-lab__programme li {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 19px;
  min-height: 72px;
  padding: 12px 10px;
  background: var(--function-color);
}
.ca-lab__measure { display: block; width: 100%; height: 4px; background: rgb(38 54 61 / .13); }
.ca-lab__measure i { display: block; width: 100%; height: 100%; background: rgb(38 54 61 / .62); transform-origin: left center; }
.ca-lab__model { display: grid; align-items: center; min-width: 0; }
.ca-lab__model-svg { overflow: visible; }
.ca-lab__checks li {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  min-height: 96px;
  padding: 12px 10px;
  background: var(--lab-paper);
  transition: border-color 220ms ease;
}
.ca-lab__checks svg { width: 24px; height: 24px; fill: none; stroke-width: 1.2; }
.ca-lab__check-box { stroke: #829197; }
.ca-lab__check-mark { stroke: var(--accent); stroke-dasharray: 16; stroke-dashoffset: 16; transition: stroke-dashoffset 280ms cubic-bezier(.16, 1, .3, 1); }
.ca-lab__checks .is-checked { border-color: rgb(48 71 82 / .5); }
.ca-lab__checks .is-checked .ca-lab__check-mark { stroke-dashoffset: 0; }

/* Retail follows the KRT verification language: quiet paper cards, compact
   uppercase labels and red tracks. The inputs are text-only; the coloured
   programme and lower check cards are intentionally absent. */
.ca-stage .ca-plan-sequence[data-commercial-plan-lab="retail"] {
  grid-template-rows: auto 36px auto 30px minmax(0, 1fr);
}
.ca-plan-sequence[data-commercial-plan-lab="retail"] .ca-lab__option polygon,
.ca-plan-sequence[data-commercial-plan-lab="retail"] .ca-lab__model-svg polygon { stroke: none; }
.ca-plan-sequence[data-commercial-plan-lab="retail"] .ca-lab__model-svg circle { stroke: none; }
.ca-plan-sequence[data-commercial-plan-lab="retail"] .ca-lab__inputs li,
.ca-plan-sequence[data-commercial-plan-lab="retail"] .ca-lab__expert {
  border-color: rgb(32 33 36 / .32);
  border-radius: 12px;
  background: rgb(246 246 242 / .97);
  color: #202124;
  font-size: clamp(11px, 2cqw, 14px);
  font-weight: 600;
  line-height: 1.14;
  letter-spacing: -.025em;
}
.ca-plan-sequence[data-commercial-plan-lab="retail"] .ca-lab__inputs li {
  min-height: 64px;
  justify-content: flex-start;
  padding: 12px clamp(12px, 2.2cqw, 16px);
}
.ca-plan-sequence[data-commercial-plan-lab="retail"] .ca-lab__expert {
  min-height: 46px;
  padding: 11px 14px;
}
.ca-plan-sequence[data-commercial-plan-lab="retail"] .ca-lab__model {
  width: 100%;
  max-width: 680px;
  margin-inline: auto;
}
.ca-plan-sequence[data-commercial-plan-lab="retail"] .ca-lab__floor { transform-box: fill-box; transform-origin: center; }

/* A single architectural sheet. The blue remains in the glazing, with the
   site's red reserved for selection and connections, not a competing field. */
#retail-scenarios .ca-stage__copy--stack > article {
  background: #f3eedf;
  color: #1e2022;
}
#retail-scenarios .ca-stage__copy h3,
#retail-scenarios .ca-stage__subtitle { color: #1e2022; }
#retail-scenarios .ca-stage__copy article > p:not(.ca-stage__subtitle) { color: #575e5b; }
#retail-scenarios .ca-plan-sequence {
  --lab-ink: #26363d;
  --lab-line: rgb(65 77 78 / .28);
  --lab-paper: #f8f6ef;
  grid-template-rows: auto 32px auto 38px minmax(0, 1fr);
  background: #eeece4;
  padding: clamp(26px, 2.5vw, 40px) clamp(16px, 2vw, 32px);
}
#retail-scenarios .ca-lab__variants { gap: clamp(8px, 1.6cqw, 12px); }
#retail-scenarios .ca-lab__option {
  padding: 4px 0;
  opacity: .68;
}
#retail-scenarios .ca-lab__option.is-selected { opacity: 1; }
#retail-scenarios .ca-lab__option img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 56 / 39;
}
#retail-scenarios .ca-lab__inputs li,
#retail-scenarios .ca-lab__expert {
  background: #f8f6ef;
  border-color: var(--lab-line);
  color: #26363d;
  font-weight: 500;
}
#retail-scenarios .ca-lab__inputs li { min-height: 58px; }
#retail-scenarios .ca-lab__model { max-width: 640px; align-self: center; }
#retail-scenarios .ca-plan-sequence > img { display: block; width: 100%; height: auto; }

@media (max-width: 920px) {
  .ca-stage .ca-plan-sequence { order: 2; padding: 32px clamp(20px, 5vw, 46px); }
  .ca-lab__inputs li { min-height: 66px; }
  .ca-lab__model { width: 100%; max-width: 640px; margin-inline: auto; }
}
@media (max-width: 620px) {
  .ca-stage .ca-plan-sequence {
    grid-template-rows: auto 32px auto 26px auto 30px auto;
    padding: 28px 18px;
  }
  .ca-stage .ca-plan-sequence[data-commercial-plan-lab="retail"] {
    grid-template-rows: auto 32px auto 26px auto;
  }
  .ca-lab__option { padding: 2px; }
  .ca-lab__inputs { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
  .ca-lab__inputs li { flex-direction: column; align-items: flex-start; gap: 8px; min-height: 72px; padding: 10px; border-radius: 10px; }
  .ca-lab__inputs li,
  .ca-lab__programme li,
  .ca-lab__checks li { font-size: 11px; line-height: 1.2; overflow-wrap: normal; }
  .ca-lab__programme { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
  .ca-lab__programme li { min-height: 59px; gap: 12px; padding: 10px; }
  .ca-lab__expert { gap: 6px; font-size: 10px; }
  .ca-lab__checks { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
  .ca-lab__checks li { flex-direction: column; align-items: flex-start; gap: 8px; min-height: 84px; padding: 10px; }
  .ca-lab__checks svg { flex: 0 0 23px; }
  .ca-plan-sequence[data-commercial-plan-lab="retail"] .ca-lab__inputs li {
    flex-direction: row;
    align-items: center;
    min-height: 58px;
    padding: 11px 12px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .ca-lab__option,
  .ca-lab__checks li,
  .ca-lab__check-mark { transition: none; }
}
