/* ============================================================
   SupportOS product page. Everything is scoped under #spos, so the short class
   names are safe. Loaded after product-page.css, which holds what the product
   pages share (base, chips, stamp, node, rail, hero frame, question stack and
   meter, turning point, FAQ, final CTA).

   Colour meaning is fixed: red = critical, orange = high, yellow = medium,
   grey = low; blue = SupportOS working, green = done, gold = what your team
   does. Gold is never used for an AI action. Severity always carries its word.

   Motion: markup renders in its finished state. The page script "arms" a
   section before animating it, and arming only ever changes opacity, visibility
   or transform, so nothing shifts. Logical properties throughout (RTL).
   ============================================================ */

@keyframes so-land {
  from {
    opacity: 0;
    transform: translateY(-10px) scale(0.94);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes so-scan {
  0%,
  100% {
    opacity: 0;
  }

  50% {
    opacity: 1;
  }
}

@keyframes so-toast-in {
  from {
    opacity: 0;
    transform: translateX(calc(40px * var(--dir))) scale(0.96);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

/* Q3: one email passed between three desks and back. The runner is as wide as
   the row, so a third of its own width is one desk. */
@keyframes so-bounce {
  0%,
  100% {
    transform: translateX(0);
  }

  25%,
  75% {
    transform: translateX(calc(33.333% * var(--dir)));
  }

  50% {
    transform: translateX(calc(66.667% * var(--dir)));
  }
}

@keyframes so-draw {
  from {
    transform: scaleX(0);
  }

  to {
    transform: scaleX(1);
  }
}

/* ---------- base ---------- */

/* The -ink colours are the ones dark enough to read as small text on their
   own tint (AA); the plain ones are for fills, stripes and dots. */
#spos {
  --so-crit-ink: #b42318;
  --so-high: #f97316;
  --so-high-ink: #9a3412;
  --so-med: #eab308;
  --so-med-ink: #854d0e;
  --so-low: var(--nlm-gray-500);
}

/* Priority chips */
#spos .st-p-crit,
#spos .light .st-bad {
  --st-c: var(--so-crit-ink);
  --st-bg: var(--nlm-danger-soft);
}

#spos .st-p-low {
  --st-c: var(--nlm-fg-2);
}

#spos .st-p-high {
  --st-c: var(--so-high-ink);
  --st-bg: rgb(249 115 22 / 14%);
}

#spos .st-p-med {
  --st-c: var(--so-med-ink);
  --st-bg: rgb(234 179 8 / 18%);
}

#spos .dark .st-p-crit {
  --st-c: #ff8a8a;
  --st-bg: rgb(239 68 68 / 16%);
}

#spos .dark .st-p-high {
  --st-c: #fdba74;
  --st-bg: rgb(249 115 22 / 16%);
}

#spos .dark .st-p-med {
  --st-c: #fde047;
  --st-bg: rgb(234 179 8 / 14%);
}

/* Customer mood: a coloured dot and its word. */
#spos :is(.md-calm, .md-concerned, .md-frustrated, .md-angry) {
  --md: var(--pq-ok);
}

#spos .md-concerned {
  --md: var(--so-med);
}

#spos .md-frustrated {
  --md: var(--so-high);
}

#spos .md-angry {
  --md: var(--pq-bad);
}

#spos .md {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-family: var(--nlm-font-mono);
  font-size: 10px;
  color: var(--nlm-fg-2);
  white-space: nowrap;
}

#spos .md::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--md);
}

/* An angry envelope. */
#spos .env-bad {
  background: var(--pq-bad);
  box-shadow: 0 6px 18px rgb(239 68 68 / 35%);
}

/* ---------- things that fly ---------- */

#spos .fly-ack,
#spos .fly-tk {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--nlm-font-mono);
  font-size: 10.5px;
  font-weight: 600;
  white-space: nowrap;
  border-radius: 999px;
  padding: 5px 10px;
}

#spos .fly-ack {
  color: #fff;
  background: var(--nlm-success);
  box-shadow: 0 6px 18px rgb(34 197 94 / 35%);
}

#spos .fly-tk {
  color: #fff;
  background: var(--nlm-signal);
  border-radius: 7px;
  box-shadow: 0 6px 18px var(--pq-glow);
}

#spos :is(.fly-ack, .fly-tk) svg {
  width: 12px;
  height: 12px;
}

#spos .fly-bell {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  color: #fff;
  background: var(--so-high);
  box-shadow: 0 6px 18px rgb(249 115 22 / 40%);
}

#spos .fly-bell svg {
  width: 14px;
  height: 14px;
}

/* ---------- hero stage ---------- */

#spos .hs {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Where the angry email comes from: just above the stage. */
#spos .hs-src {
  position: absolute;
  inset-block-start: -40px;
  inset-inline-start: 14%;
  width: 1px;
  height: 1px;
}

#spos .hs-top {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) auto minmax(0, 1.5fr);
  gap: 12px;
  align-items: center;
}

#spos .hs-boxes {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

#spos .ibox {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  font-family: var(--nlm-font-mono);
  font-size: 10.5px;
  color: var(--nlm-navy-300);
  background: rgb(255 255 255 / 5%);
  border: 1px solid var(--nlm-line-dark);
  border-radius: 8px;
  padding: 6px 8px;
  transition: border-color 0.3s, background 0.3s;
}

#spos .ibox :is(svg, i[data-lucide]) {
  width: 12px;
  height: 12px;
  flex: none;
}

#spos .ibox span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

#spos .ibox b {
  margin-inline-start: auto;
  color: #fff;
}

#spos .ibox.is-hit {
  border-color: var(--pq-bad);
  background: rgb(239 68 68 / 14%);
}

#spos .hs-ai {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  font-family: var(--nlm-font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--nlm-navy-300);
}

#spos .tcard {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 7px;
  min-width: 0;
  background: var(--nlm-navy-900);
  border: 1px solid var(--nlm-line-dark);
  border-inline-start: 3px solid var(--pq-bad);
  border-radius: 12px;
  padding: 12px;
}

#spos .tcard .tag {
  font-family: var(--nlm-font-mono);
  font-size: 9.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--nlm-navy-400);
}

#spos .tc-id {
  font-family: var(--nlm-font-mono);
  font-size: 15px;
  color: #fff;
}

#spos .tc-subj {
  font-size: 12px;
  line-height: 1.45;
  color: var(--nlm-navy-300);
}

#spos .tc-row {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

/* SentimentBar: Calm at the start of the line, Angry at the end. */
#spos .senti {
  --pos: 0.08;
}

#spos .senti-h {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  font-family: var(--nlm-font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--nlm-navy-400);
}

#spos .senti-h b {
  font-size: 11.5px;
  letter-spacing: 0;
  color: #fff;
}

#spos .senti-track {
  position: relative;
  height: 8px;
  border-radius: 4px;
  margin-block: 9px 6px;
  background: linear-gradient(90deg, var(--pq-ok), var(--so-med), var(--so-high), var(--pq-bad));
}

[dir="rtl"] #spos .senti-track {
  background: linear-gradient(270deg, var(--pq-ok), var(--so-med), var(--so-high), var(--pq-bad));
}

/* The marker's box is as wide as the track, so moving it by a share of its own
   width moves the dot along the scale. */
#spos .senti-mk {
  position: absolute;
  inset: 0;
  transform: translateX(calc(var(--pos) * 100% * var(--dir)));
  transition: transform 1s var(--nlm-ease-soft);
}

#spos .senti-mk i {
  position: absolute;
  inset-block-start: -4px;
  inset-inline-start: -8px;
  width: 16px;
  height: 16px;
  box-sizing: border-box;
  border-radius: 50%;
  background: #fff;
  border: 3px solid var(--nlm-navy-950);
  box-shadow: 0 0 0 1px rgb(255 255 255 / 60%);
}

#spos .senti-l {
  display: flex;
  justify-content: space-between;
  font-family: var(--nlm-font-mono);
  font-size: 9.5px;
  color: var(--nlm-navy-400);
}

/* Escalation ladder */
#spos .ladder {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
}

#spos .rung {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  border: 1px solid var(--nlm-line-dark);
  border-radius: 9px;
  padding: 7px 8px;
  transition: border-color 0.3s, background 0.3s;
}

#spos .rung span {
  font-family: var(--nlm-font-mono);
  font-size: 9px;
  letter-spacing: 0.06em;
  color: var(--nlm-navy-400);
}

#spos .rung b {
  font-size: 11px;
  font-weight: 600;
  line-height: 1.25;
  color: var(--nlm-navy-300);
}

#spos .rung.is-on {
  border-color: var(--so-high);
  background: rgb(249 115 22 / 14%);
}

#spos .rung.is-on b {
  color: #fff;
}

#spos .rung.is-done {
  border-color: rgb(34 197 94 / 55%);
  background: rgb(34 197 94 / 10%);
}

#spos .rung.is-done b {
  color: #fff;
}

#spos .hs-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 40px;
}

#spos .hs-cap {
  font-size: 12.5px;
  line-height: 1.4;
  color: #fff;
}

#spos .hs-sla {
  flex: none;
}

#spos .hs-stamp {
  position: absolute;
  z-index: 2;
  inset-block-start: -22px;
  inset-inline-end: 4px;
}

/* ---------- 01 the problem ---------- */

#spos .qa {
  height: 104px;
}

#spos .qn {
  font-family: var(--nlm-font-mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  color: var(--nlm-danger);
  margin-bottom: 8px;
}

/* Q1: unread mail piling up */
#spos .qa-pile {
  position: relative;
  flex: none;
  width: 92px;
  height: 78px;
}

#spos .qa-pile .env {
  position: absolute;
  inset-block-end: calc(var(--i) * 14px);
  inset-inline-start: calc(var(--i) * 12px);
  background: var(--nlm-gray-500);
  box-shadow: var(--nlm-shadow-sm);
  animation: pq-seq 4s infinite;
  animation-delay: calc(var(--i) * 0.6s);
}

#spos .qa-unread {
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-family: var(--nlm-font-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--nlm-fg-3);
}

#spos .qa-unread b {
  font-family: var(--nlm-font-display);
  font-weight: 800;
  font-size: 34px;
  line-height: 1;
  letter-spacing: -0.02em;
  color: var(--nlm-danger);
}

[dir="rtl"] #spos .qa-unread b {
  text-align: end;
}

/* Q2: the customer's messages get shorter and angrier */
#spos .qa-2 {
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 4px;
}

#spos .qa-2 .bub {
  font-size: 11px;
  padding: 5px 9px;
  animation: pq-seq 6s infinite;
  animation-delay: calc(var(--i) * 1.2s);
}

/* Q3: forwarded from desk to desk */
#spos .qa-3 {
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
  gap: 8px;
}

#spos .qa-fwd {
  display: block;
  overflow: hidden;
}

#spos .qa-run {
  display: block;
  animation: so-bounce 4.5s ease-in-out infinite;
}

#spos .qa-run .env {
  box-sizing: border-box;
  max-width: 33.333%;
  background: var(--nlm-gray-500);
  box-shadow: none;
  white-space: nowrap;
  overflow: hidden;
}

#spos .qa-who {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

#spos .qa-who span {
  font-family: var(--nlm-font-mono);
  font-size: 10.5px;
  text-align: center;
  color: var(--nlm-fg-2);
  background: var(--nlm-gray-50);
  border: 1px dashed var(--nlm-line-strong);
  border-radius: 8px;
  padding: 8px 4px;
}

/* Q4: a refund request turns into a lost customer */
#spos .qa-4 {
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 8px;
}

#spos .qa-flip {
  display: inline-grid;
}

#spos .qa-flip .st {
  grid-area: 1 / 1;
  justify-self: start;
  font-size: 11px;
  padding: 5px 10px;
  animation: pq-flip-a 5s infinite;
}

#spos .qa-flip .st:first-child {
  opacity: 0;
}

#spos .qa-flip .st + .st {
  animation-name: pq-flip-b;
}

#spos .qa-note {
  font-family: var(--nlm-font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--nlm-fg-3);
}

/* Q5: the public review, then the General Manager */
#spos .qa-5 {
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
  gap: 5px;
}

#spos .qa-rev {
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-size: 11px;
  line-height: 1.35;
  color: var(--nlm-fg-1);
  background: #fff;
  border: 1px solid var(--nlm-line);
  border-radius: 10px;
  padding: 6px 9px;
  animation: pq-seq 6s infinite;
}

#spos .qa-stars {
  display: flex;
  gap: 2px;
  color: var(--nlm-line-strong);
}

#spos .qa-stars :is(svg, i[data-lucide]) {
  width: 11px;
  height: 11px;
}

#spos .qa-stars .is-on {
  color: var(--pq-amber);
  fill: var(--pq-amber);
}

#spos .qa-5 .bub {
  align-self: flex-end;
  font-size: 11px;
  padding: 5px 9px;
  animation: pq-seq 6s infinite;
  animation-delay: 1.6s;
}

/* the meter */
#spos .meter-h {
  margin: 0 0 14px;
}

[dir="rtl"] #spos .meter-h {
  text-align: start;
}

#spos .meter-rows {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 0;
  font-size: 13px;
}

#spos .meter-rows > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

#spos .meter-rows dd {
  margin: 0;
  font-family: var(--nlm-font-mono);
  font-weight: 600;
  white-space: nowrap;
  color: #ff8a8a;
}

#spos .qrate {
  margin-top: 0;
}

#spos .qrate input {
  width: 112px;
}

/* ---------- what if: this page's pain objects ---------- */

#spos .turn-flow {
  gap: 6px;
}

#spos .turn-flow li {
  font-size: 13.5px;
  padding: 7px 12px;
}

/* ---------- 02 the solution: six steps ---------- */

#spos .flow-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

#spos .flow-ai {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--nlm-font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--nlm-navy-300);
}

#spos .flow-ai .node {
  width: 52px;
  height: 52px;
}

#spos .flow-ai .node-core {
  width: 40px;
  height: 40px;
}

#spos .flow-ai .node-core :is(svg, i[data-lucide]) {
  width: 18px;
  height: 18px;
}

#spos .flow-replay {
  padding-inline: 12px 16px;
}

#spos .flow-replay :is(svg, i[data-lucide]) {
  width: 15px;
  height: 15px;
}

#spos .steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

#spos .step {
  background: var(--nlm-navy-800);
  border: 1px solid var(--nlm-line-dark);
  border-radius: 14px;
  padding: 20px 18px;
  transition: border-color 0.35s, opacity 0.35s;
}

#spos .step.is-done {
  border-color: rgb(34 197 94 / 45%);
}

#spos .flow.is-armed .step:not(.is-done) {
  opacity: 0.45;
}

#spos .step-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

#spos .step .ico {
  width: 36px;
  height: 36px;
  background: rgb(61 107 255 / 18%);
  color: var(--pq-ai);
}

#spos .step-n {
  font-family: var(--nlm-font-mono);
  font-size: 11px;
  color: var(--nlm-navy-400);
}

#spos .step h3 {
  display: flex;
  align-items: center;
  gap: 9px;
  font-family: var(--nlm-font-display);
  font-weight: 600;
  font-size: 16px;
  color: #fff;
  margin: 0 0 8px;
}

#spos .step p {
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--nlm-navy-300);
  margin: 0;
}

#spos .ck {
  flex: none;
  width: 20px;
  height: 20px;
  box-sizing: border-box;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid rgb(255 255 255 / 25%);
  color: transparent;
  transition: background 0.25s, border-color 0.25s, color 0.25s;
}

#spos .ck :is(svg, i[data-lucide]) {
  width: 12px;
  height: 12px;
}

#spos .step.is-done .ck {
  background: var(--pq-ok);
  border-color: var(--pq-ok);
  color: #fff;
}

#spos .flow.is-armed .step.is-done .ck {
  animation: pq-pop 0.4s var(--nlm-ease-soft);
}

/* ---------- 03 see it work: inbox triage ---------- */

#spos .tri-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 16px;
}

#spos .tri-ctl {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

#spos .tri-n {
  list-style: none;
  margin: 0 0 16px;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

#spos .tri-n li {
  display: flex;
  flex-direction: column;
  gap: 2px;
  background: #fff;
  border: 1px solid var(--nlm-line);
  border-radius: 12px;
  padding: 12px 14px;
  font-size: 12.5px;
  line-height: 1.35;
  color: var(--nlm-fg-2);
}

#spos .tri-n b {
  font-family: var(--nlm-font-display);
  font-weight: 800;
  font-size: 26px;
  line-height: 1.1;
  color: var(--nlm-fg-1);
}

[dir="rtl"] #spos .tri-n b.ltr {
  text-align: end;
}

#spos .tri-n .is-bad b {
  color: var(--nlm-danger);
}

#spos .tri-n .is-ok b {
  color: var(--nlm-success);
}

/* The inbox runs the full height of the lanes and the detail panel beside it;
   its list scrolls inside, so it never sets the height itself. */
#spos .tri-grid {
  display: grid;
  grid-template: "inbox lanes" auto "inbox detail" 1fr / minmax(260px, 330px) minmax(0, 1fr);
  gap: 14px;
}

#spos .inbox {
  grid-area: inbox;
  position: relative;
  min-height: 460px;
  background: #fff;
  border: 1px solid var(--nlm-line);
  border-radius: 16px;
  overflow: hidden;
}

#spos .inbox-h {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin: 0;
  padding: 12px 14px;
  font-family: var(--nlm-font-mono);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--nlm-fg-3);
  border-bottom: 1px solid var(--nlm-line);
}

#spos .mails {
  position: absolute;
  inset: 41px 0 0;
  overflow-y: auto;
  overscroll-behavior: contain;
}

#spos .mail {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 3px;
  width: 100%;
  box-sizing: border-box;
  font: inherit;
  text-align: start;
  color: var(--nlm-fg-2);
  background: #fff;
  border: 0;
  border-bottom: 1px solid var(--nlm-line);
  border-inline-start: 3px solid transparent;
  padding: 11px 14px;
  cursor: pointer;
  transition: background 0.2s, opacity 0.3s;
}

#spos .mail:hover {
  background: var(--nlm-gray-50);
}

#spos .mail:focus-visible {
  outline-offset: -3px;
}

#spos .mail-f {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 12px;
  color: var(--nlm-fg-3);
}

#spos .mail-s {
  font-size: 13.5px;
  line-height: 1.35;
  color: var(--nlm-fg-1);
}

#spos .mail-p {
  font-size: 12px;
  line-height: 1.4;
  color: var(--nlm-fg-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

#spos .mail-st {
  display: none;
  align-items: center;
  gap: 5px;
  font-family: var(--nlm-font-mono);
  font-size: 10.5px;
  color: var(--nlm-fg-3);
}

#spos .mail-st :is(svg, i[data-lucide]) {
  width: 12px;
  height: 12px;
}

#spos .mail.is-unread {
  border-inline-start-color: var(--nlm-signal);
}

#spos .mail.is-unread .mail-s {
  font-weight: 600;
}

/* SupportOS reading the email */
#spos .mail::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--nlm-signal-soft);
  opacity: 0;
  pointer-events: none;
}

#spos .mail.is-scan::after {
  animation: so-scan 0.5s ease-in-out;
}

#spos .mail.is-done :is(.mail-s, .mail-p) {
  color: var(--nlm-fg-3);
}

#spos .mail.is-done .mail-st {
  display: inline-flex;
}

#spos .mail.is-acked .mail-st {
  color: var(--nlm-success);
}

#spos .lanes {
  grid-area: lanes;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

#spos .lane {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 280px;
  background: rgb(15 17 55 / 4%);
  border: 1px dashed var(--nlm-line-strong);
  border-radius: 14px;
  padding: 10px 8px;
}

#spos .lane h3 {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 6px;
  margin: 0;
  font-family: var(--nlm-font-display);
  font-weight: 600;
  font-size: 12.5px;
  line-height: 1.3;
  color: var(--nlm-fg-1);
}

#spos .lane h3 b {
  flex: none;
  min-width: 20px;
  text-align: center;
  font-family: var(--nlm-font-mono);
  font-size: 11px;
  color: #fff;
  background: var(--nlm-navy-900);
  border-radius: 999px;
  padding: 2px 6px;
}

/* TicketCard */
#spos .tk {
  --sev: var(--so-low);

  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  width: 100%;
  box-sizing: border-box;
  font: inherit;
  text-align: start;
  background: #fff;
  border: 1px solid var(--nlm-line);
  border-inline-start: 3px solid var(--sev);
  border-radius: 10px;
  padding: 9px 9px 10px;
  cursor: pointer;
  box-shadow: var(--nlm-shadow-sm);
  transition: transform 0.2s var(--nlm-ease), box-shadow 0.2s var(--nlm-ease);
}

#spos .tk-crit {
  --sev: var(--pq-bad);
}

#spos .tk-high {
  --sev: var(--so-high);
}

#spos .tk-med {
  --sev: var(--so-med);
}

#spos .tk:hover {
  transform: translateY(-2px);
  box-shadow: var(--nlm-shadow-md);
}

#spos .tk.is-sel {
  border-color: var(--nlm-signal);
  border-inline-start-color: var(--sev);
  box-shadow: 0 0 0 2px var(--nlm-signal-soft);
}

/* Not created yet: out of sight, but still holding its place in the lane. */
#spos .tk.is-wait {
  visibility: hidden;
}

#spos .tk.is-land {
  animation: so-land 0.45s var(--nlm-ease-soft);
}

#spos .tk-id {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 2px 6px;
  width: 100%;
  font-family: var(--nlm-font-mono);
  font-size: 10.5px;
  font-weight: 600;
  color: var(--nlm-fg-1);
}

#spos .tk-ty {
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.3;
  color: var(--nlm-fg-1);
}

#spos .tk-cu {
  font-size: 11.5px;
  color: var(--nlm-fg-3);
}

/* The ticket detail panel */
#spos .detail {
  position: relative;
  grid-area: detail;
  align-self: start;
}

/* Nothing opened yet: the hint sits over the (invisible) panel, which keeps
   its height so nothing below moves. */
#spos .detail-empty {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 18px;
  text-align: center;
  font-size: 14px;
  color: var(--nlm-fg-3);
}

#spos .detail-g.is-blank {
  visibility: hidden;
}

#spos .detail-g {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 18px clamp(18px, 2.4vw, 32px);
}

/* The reply the agent sends runs the full width, under what the AI found. */
#spos .detail-g > :last-child {
  grid-column: 1 / -1;
}

#spos .detail .panel-t {
  display: block;
}

#spos .kv {
  margin: 0;
  font-size: 13px;
}

#spos .kv > div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 6px 0;
  border-bottom: 1px solid var(--nlm-line);
}

#spos .kv dt {
  color: var(--nlm-fg-3);
}

#spos .kv dd {
  margin: 0;
  font-weight: 600;
  text-align: end;
  color: var(--nlm-fg-1);
}

#spos .kv .is-data {
  color: var(--nlm-signal-ink);
}

#spos .mbar {
  --f: 0;

  height: 8px;
  border-radius: 4px;
  background: var(--nlm-gray-100);
  overflow: hidden;
}

#spos .mbar i {
  display: block;
  height: 100%;
  border-radius: 4px;
  background: var(--md);
  transform-origin: 0 50%;
  transform: scaleX(var(--f));
  transition: transform 0.8s var(--nlm-ease-soft);
}

[dir="rtl"] #spos .mbar i {
  transform-origin: 100% 50%;
}

#spos .quote {
  margin: 12px 0;
  font-size: 13.5px;
  line-height: 1.65;
  color: var(--nlm-fg-1);
  background: var(--nlm-gray-50);
  border: 1px solid var(--nlm-line);
  border-radius: 12px;
  padding: 12px 14px;
}

#spos .quote mark {
  color: inherit;
  border-radius: 3px;
  padding: 1px 3px;
}

#spos .mk-hot {
  background: var(--nlm-danger-soft);
  box-shadow: inset 0 -2px 0 var(--pq-bad);
}

#spos .mk-data {
  background: var(--nlm-signal-soft);
  box-shadow: inset 0 -2px 0 var(--nlm-signal);
}

#spos .ackl {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin: 0;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--nlm-success);
}

#spos .ackl :is(svg, i[data-lucide]) {
  flex: none;
  width: 14px;
  height: 14px;
  margin-top: 2px;
}

#spos .draft {
  display: block;
  width: 100%;
  box-sizing: border-box;
  font: inherit;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--nlm-fg-1);
  background: #fff;
  border: 1px solid var(--nlm-line-strong);
  border-radius: 12px;
  padding: 12px 14px;
  resize: vertical;
}

#spos .draft:read-only {
  background: var(--nlm-gray-50);
  color: var(--nlm-fg-2);
}

#spos .draft:focus-visible {
  outline: 2px solid var(--nlm-signal);
  outline-offset: 2px;
}

#spos .draft-a {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 14px;
  margin-top: 12px;
}

#spos .draft-a .hint {
  margin: 0;
}

#spos .draft-a .ic-sent,
#spos .draft-a .is-sent .ic-send {
  display: none;
}

#spos .draft-a .is-sent .ic-sent {
  display: inline-block;
}

/* A sent reply stays gold: it is the agent's action. */
#spos .draft-a .is-sent:disabled {
  opacity: 1;
  cursor: default;
  transform: none;
  box-shadow: none;
}

/* Notifications */
#spos .toasts {
  position: fixed;
  z-index: 47;
  inset-block-end: 88px;
  inset-inline-end: 64px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: min(340px, calc(100vw - 32px));
  pointer-events: none;
}

#spos .toast {
  --tc: var(--nlm-signal);

  display: flex;
  align-items: flex-start;
  gap: 10px;
  background: #fff;
  border: 1px solid var(--nlm-line);
  border-inline-start: 4px solid var(--tc);
  border-radius: 12px;
  padding: 10px 12px;
  box-shadow: var(--nlm-shadow-lg);
  animation: so-toast-in 0.35s var(--nlm-ease-soft);
  transition: opacity 0.35s, transform 0.35s;
}

#spos .toast.is-out {
  opacity: 0;
  transform: translateX(calc(30px * var(--dir)));
}

#spos .toast-ic {
  flex: none;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: var(--tc);
}

#spos .toast-ic svg {
  width: 14px;
  height: 14px;
}

#spos .toast b {
  display: block;
  font-family: var(--nlm-font-display);
  font-weight: 600;
  font-size: 13.5px;
  line-height: 1.3;
  color: var(--nlm-fg-1);
}

#spos .toast span span {
  display: block;
  font-size: 12px;
  line-height: 1.4;
  color: var(--nlm-fg-2);
}

#spos .toast-route {
  --tc: var(--nlm-navy-600);
}

#spos .toast-esc {
  --tc: var(--so-high);
}

#spos .toast-gm {
  --tc: var(--pq-bad);
}

#spos .toast-ack {
  --tc: var(--nlm-success);
}

#spos .toast-skip {
  --tc: var(--nlm-gray-500);
}

/* ---------- 04 escalation matrix ---------- */

#spos .esc-top {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 16px;
}

#spos .pick {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

#spos .pick label {
  position: relative;
  cursor: pointer;
}

#spos .pick input {
  position: absolute;
  opacity: 0;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  cursor: pointer;
}

#spos .pick-c {
  display: flex;
  flex-direction: column;
  gap: 5px;
  max-width: 230px;
  font-size: 13px;
  line-height: 1.35;
  color: var(--nlm-fg-1);
  background: #fff;
  border: 1px solid var(--nlm-line-strong);
  border-radius: 12px;
  padding: 10px 12px;
  transition: border-color 0.2s, box-shadow 0.2s;
}

#spos .pick-m {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--nlm-font-mono);
  font-size: 11px;
  color: var(--nlm-fg-3);
}

#spos .pick input:checked + .pick-c {
  border-color: var(--nlm-navy-900);
  box-shadow: 0 0 0 1px var(--nlm-navy-900);
}

#spos .pick input:focus-visible + .pick-c {
  outline: 2px solid var(--nlm-signal);
  outline-offset: 3px;
}

#spos .esc-ctl {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

#spos .esc-ctl :is(svg, i[data-lucide]) {
  width: 15px;
  height: 15px;
}

#spos .esc-g {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 260px) minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

#spos .clockbox {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  text-align: center;
}

#spos .esc-now {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  margin: 0;
  font-size: 13.5px;
  line-height: 1.35;
  color: var(--nlm-fg-1);
}

#spos .esc-now-m {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--nlm-font-mono);
  font-size: 11px;
  color: var(--nlm-fg-3);
}

#spos .ring {
  --ring: var(--nlm-signal);

  position: relative;
  width: 180px;
  height: 180px;
}

#spos .ring svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

#spos .ring circle {
  fill: none;
  stroke-width: 10;
}

#spos .ring-bg {
  stroke: var(--nlm-gray-100);
}

#spos .ring-arc {
  stroke: var(--ring);
  stroke-linecap: round;
  transition: stroke 0.3s;
}

#spos .ring[data-lv="2"],
#spos .ring[data-lv="3"] {
  --ring: var(--so-high);
}

#spos .ring[data-lv="4"] {
  --ring: var(--pq-bad);
}

#spos .ring.is-resolved {
  --ring: var(--pq-gold);
}

#spos .ring-c {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  font-size: 11.5px;
  color: var(--nlm-fg-3);
}

#spos .ring-c b {
  font-family: var(--nlm-font-mono);
  font-weight: 600;
  font-size: 26px;
  font-variant-numeric: tabular-nums;
  color: var(--nlm-fg-1);
}

#spos .esc-sla {
  min-height: 2.8em;
  margin: 0;
  font-size: 13px;
  line-height: 1.4;
  font-weight: 600;
  color: var(--nlm-fg-2);
}

#spos .esc-sla.is-late {
  color: var(--so-high-ink);
}

#spos .esc-sla.is-gold {
  color: var(--so-med-ink);
}

#spos .esc-main {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

#spos .people {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

#spos .person {
  --who: var(--so-high);

  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  background: #fff;
  border: 1px solid var(--nlm-line);
  border-radius: 14px;
  padding: 12px;
  font-size: 12px;
  color: var(--nlm-fg-3);
  transition: border-color 0.3s, box-shadow 0.3s, opacity 0.3s;
}

#spos .person:first-child {
  --who: var(--nlm-signal);
}

#spos .person.is-top {
  --who: var(--pq-bad);
}

#spos .person .av {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 4px;
  font-family: var(--nlm-font-mono);
  font-size: 11px;
  font-weight: 600;
  color: var(--nlm-fg-2);
  background: var(--nlm-gray-100);
  transition: background 0.3s, color 0.3s;
}

#spos .person .lv {
  font-family: var(--nlm-font-mono);
  font-size: 9.5px;
  letter-spacing: 0.08em;
}

#spos .person b {
  font-family: var(--nlm-font-display);
  font-weight: 600;
  font-size: 14px;
  color: var(--nlm-fg-1);
}

#spos .person.is-on {
  border-color: var(--who);
  box-shadow: 0 0 0 1px var(--who);
}

#spos .person.is-on .av {
  color: #fff;
  background: var(--who);
}

#spos .person.is-na {
  opacity: 0.45;
}

#spos .mx-wrap {
  overflow-x: auto;
  border: 1px solid var(--nlm-line);
  border-radius: 14px;
}

#spos .mx {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  font-size: 13px;
}

#spos .mx :is(th, td) {
  text-align: start;
  padding: 10px 12px;
  border-bottom: 1px solid var(--nlm-line);
  transition: background 0.3s, color 0.3s;
}

#spos .mx tbody tr:last-child :is(th, td) {
  border-bottom: 0;
}

#spos .mx thead th {
  font-family: var(--nlm-font-mono);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--nlm-fg-3);
  background: var(--nlm-gray-50);
}

#spos .mx td {
  color: var(--nlm-fg-2);
}

#spos .mx tr.is-act {
  background: var(--nlm-gray-50);
}

#spos .mx tr.is-act td {
  font-weight: 600;
  color: var(--nlm-fg-1);
}

#spos .mx td.is-na {
  color: var(--nlm-fg-3);
}

#spos .mx td.is-hit {
  color: var(--so-high-ink);
  background: rgb(249 115 22 / 14%);
}

#spos .mx td.is-hit.is-top {
  color: var(--nlm-danger);
  background: var(--nlm-danger-soft);
}

#spos .mx-note {
  margin: -6px 0 0;
  font-size: 12px;
  color: var(--nlm-fg-3);
}

#spos .esc-log {
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: 136px;
  overflow-y: auto;
  background: var(--nlm-gray-50);
  border: 1px solid var(--nlm-line);
  border-radius: 14px;
  padding: 12px 14px;
  font-size: 12.5px;
  line-height: 1.45;
  color: var(--nlm-fg-2);
}

#spos .esc-log p {
  --dot: var(--nlm-gray-500);

  display: flex;
  align-items: baseline;
  gap: 8px;
  margin: 0;
}

#spos .esc-log p::before {
  content: "";
  flex: none;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--dot);
}

#spos .esc-log .lg-ai {
  --dot: var(--nlm-signal);
}

#spos .esc-log .lg-esc {
  --dot: var(--so-high);
}

#spos .esc-log .lg-top {
  --dot: var(--pq-bad);

  font-weight: 600;
  color: var(--nlm-fg-1);
}

#spos .esc-log .lg-gold {
  --dot: var(--pq-gold);

  font-weight: 600;
  color: var(--nlm-fg-1);
}

#spos .esc-stamp {
  position: absolute;
  z-index: 2;
  inset-block-start: -16px;
  inset-inline-end: 18px;
  font-size: 12.5px;
}

#spos .legend {
  margin-top: 18px;
}

#spos .legend dl {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 24px;
  margin: 0;
}

#spos .legend dl > div {
  display: flex;
  align-items: baseline;
  gap: 10px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--nlm-fg-2);
}

#spos .legend dt {
  flex: none;
  min-width: 74px;
}

#spos .legend dd {
  margin: 0;
}

#spos .esc-report {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 18px 0 0;
  font-family: var(--nlm-font-display);
  font-weight: 600;
  font-size: 15px;
  line-height: 1.45;
  color: var(--nlm-fg-1);
}

#spos .esc-report :is(svg, i[data-lucide]) {
  flex: none;
  width: 18px;
  height: 18px;
  margin-top: 2px;
  color: var(--pq-bad);
}

/* ---------- 05 capabilities ---------- */

#spos .cloud {
  list-style: none;
  margin: 0 0 clamp(28px, 4vw, 44px);
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

#spos .cloud li {
  font-family: var(--nlm-font-display);
  font-weight: 600;
  font-size: 13.5px;
  color: var(--nlm-fg-1);
  background: #fff;
  border: 1px solid var(--nlm-line-strong);
  border-radius: 999px;
  padding: 8px 15px;
}

#spos .cloud.is-armed li {
  opacity: 0;
  transform: translateY(8px) scale(0.94);
}

#spos .cloud.is-armed.is-in li {
  opacity: 1;
  transform: none;
  transition: opacity 0.4s var(--nlm-ease), transform 0.45s var(--nlm-ease-soft);
  transition-delay: calc(var(--i) * 70ms);
}

#spos .feats {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

#spos .feat {
  background: #fff;
  border: 1px solid var(--nlm-line);
  border-radius: 16px;
  padding: 20px 18px;
  transition: transform 0.25s var(--nlm-ease), box-shadow 0.25s var(--nlm-ease);
}

#spos .feat:hover {
  transform: translateY(-4px);
  box-shadow: var(--nlm-shadow-md);
}

#spos .feat h3 {
  font-family: var(--nlm-font-display);
  font-weight: 600;
  font-size: 16px;
  line-height: 1.3;
  color: var(--nlm-fg-1);
  margin: 14px 0 6px;
}

#spos .feat p {
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--nlm-fg-2);
  margin: 0;
}

/* ---------- 06 before / after ---------- */

#spos .out-sw {
  margin-bottom: 20px;
}

#spos .out-g {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: clamp(18px, 3vw, 36px);
  align-items: start;
}

#spos .core {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0 6px;
  font-size: 13.5px;
  line-height: 1.35;
}

#spos .core :is(th, td) {
  text-align: start;
  font-weight: 500;
  padding: 10px 12px;
  background: var(--nlm-navy-900);
  border-block: 1px solid var(--nlm-line-dark);
  transition: color 0.4s var(--nlm-ease), opacity 0.4s var(--nlm-ease);
}

#spos .core :is(th, td):first-child {
  border-inline-start: 1px solid var(--nlm-line-dark);
  border-start-start-radius: 10px;
  border-end-start-radius: 10px;
}

#spos .core :is(th, td):last-child {
  border-inline-end: 1px solid var(--nlm-line-dark);
  border-start-end-radius: 10px;
  border-end-end-radius: 10px;
}

#spos .core thead th {
  font-family: var(--nlm-font-mono);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--nlm-navy-400);
  background: transparent;
  border-color: transparent;
  padding-block: 0 2px;
}

#spos .core thead th:is(:first-child, :last-child) {
  border-color: transparent;
}

#spos .core td {
  position: relative;
  padding-inline-start: 32px;
}

#spos .core td :is(svg, i[data-lucide]) {
  position: absolute;
  top: calc(50% - 7px);
  inset-inline-start: 10px;
  width: 14px;
  height: 14px;
  color: var(--nlm-navy-600);
}

#spos .c-pain {
  color: var(--nlm-navy-400);
  text-decoration: line-through;
  text-decoration-color: rgb(255 255 255 / 30%);
}

#spos .c-ai {
  color: var(--pq-ai);
}

#spos .c-out {
  color: #5ee08a;
  font-weight: 600;
}

/* The last row is the human one: readable in both states, its outcome gold. */
#spos .is-human .c-pain {
  color: #fff;
  text-decoration: none;
}

#spos .is-human .c-ai {
  color: var(--nlm-navy-400);
}

#spos .is-human .c-out {
  color: var(--pq-gold);
}

#spos [data-state="before"] tr:not(.is-human) .c-pain {
  color: #ff8a8a;
  text-decoration-color: transparent;
}

/* Before SupportOS there is no AI action and no outcome to show: the cells
   stay, empty. */
#spos .core :is(.c-ai, .c-out) > * {
  transition: opacity 0.4s var(--nlm-ease), visibility 0s;
}

#spos [data-state="before"] tr:not(.is-human) :is(.c-ai, .c-out) > * {
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s var(--nlm-ease), visibility 0s 0.4s;
}

/* The daily escalation report */
#spos .report {
  position: relative;
  background: var(--nlm-navy-900);
  border: 1px solid var(--nlm-line-dark);
  border-radius: 16px;
  overflow: hidden;
  color: var(--nlm-navy-300);
}

#spos .report-b {
  padding: clamp(18px, 2vw, 24px);
  transition: opacity 0.5s var(--nlm-ease);
}

#spos .report-h {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 6px 12px;
  margin-bottom: 14px;
  font-family: var(--nlm-font-mono);
  font-size: 10.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

#spos .report-h strong {
  font-family: var(--nlm-font-display);
  font-size: 16px;
  letter-spacing: 0;
  text-transform: none;
  color: #fff;
}

#spos .kpis {
  list-style: none;
  margin: 0 0 16px;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

#spos .kpis li {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 4px;
  font-size: 11.5px;
  line-height: 1.3;
  background: rgb(255 255 255 / 5%);
  border-radius: 10px;
  padding: 10px;
}

#spos .kpis b {
  font-family: var(--nlm-font-display);
  font-weight: 800;
  font-size: 24px;
  line-height: 1;
  color: #fff;
}

[dir="rtl"] #spos .kpis b {
  text-align: end;
}

#spos .kpis .is-bad b {
  color: #ff8a8a;
}

#spos .kpis .is-ok b {
  color: #5ee08a;
}

#spos .report-t {
  margin: 14px 0 8px;
  font-family: var(--nlm-font-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--nlm-navy-400);
}

#spos .rbars {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 7px;
  font-size: 12px;
}

#spos .rbars li {
  display: grid;
  grid-template-columns: minmax(0, 130px) minmax(0, 1fr) 40px;
  align-items: center;
  gap: 10px;
}

#spos .rbars b {
  font-family: var(--nlm-font-mono);
  font-weight: 500;
  color: #fff;
}

[dir="rtl"] #spos .rbars b {
  text-align: end;
}

#spos .rbar {
  display: block;
  height: 8px;
  border-radius: 4px;
  background: rgb(255 255 255 / 9%);
  overflow: hidden;
}

#spos .rbar i {
  display: block;
  width: calc(var(--w) * 100%);
  height: 100%;
  border-radius: 4px;
  background: var(--md, var(--nlm-signal));
  transform-origin: 0 50%;
  transition: transform 0.9s var(--nlm-ease-soft);
}

[dir="rtl"] #spos .rbar i {
  transform-origin: 100% 50%;
}

#spos .report-n {
  margin: 14px 0 0;
  font-size: 11.5px;
  font-style: italic;
  color: var(--nlm-navy-400);
}

#spos .blind {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 24px;
  background: rgb(8 9 31 / 72%);
  backdrop-filter: blur(7px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.5s var(--nlm-ease), visibility 0.5s;
}

#spos .blind b {
  display: block;
  font-family: var(--nlm-font-display);
  font-weight: 700;
  font-size: 20px;
  color: #fff;
  margin-bottom: 8px;
}

#spos .blind p {
  max-width: 34ch;
  margin: 0;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--nlm-navy-300);
}

#spos [data-state="before"] .blind {
  opacity: 1;
  visibility: visible;
}

#spos [data-state="before"] .rbar i {
  transform: scaleX(0);
}

/* ---------- 07 who it's for ---------- */

#spos .tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 22px;
}

#spos .tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--nlm-font-display);
  font-weight: 600;
  font-size: 14px;
  color: var(--nlm-fg-2);
  background: #fff;
  border: 1px solid var(--nlm-line-strong);
  border-radius: 999px;
  padding: 11px 18px;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}

#spos .tab :is(svg, i[data-lucide]) {
  width: 16px;
  height: 16px;
}

#spos .tab[aria-selected="true"] {
  color: #fff;
  background: var(--nlm-navy-900);
  border-color: var(--nlm-navy-900);
}

#spos .tabp {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(20px, 3vw, 40px);
  align-items: center;
  background: #fff;
  border: 1px solid var(--nlm-line);
  border-radius: 18px;
  padding: clamp(22px, 3vw, 36px);
  animation: pq-rise 0.45s var(--nlm-ease-soft);
}

#spos .tabp h3 {
  font-family: var(--nlm-font-display);
  font-weight: 700;
  font-size: clamp(20px, 2.2vw, 26px);
  color: var(--nlm-fg-1);
  margin: 16px 0 10px;
}

#spos .tabp p {
  font-size: 15px;
  line-height: 1.65;
  color: var(--nlm-fg-2);
  margin: 0;
}

#spos .ex {
  background: var(--nlm-gray-50);
  border: 1px solid var(--nlm-line);
  border-radius: 14px;
  padding: 18px;
}

#spos .tabp .ex-l {
  font-family: var(--nlm-font-mono);
  font-size: 10.5px;
  line-height: 1.4;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--nlm-fg-3);
  margin-bottom: 12px;
}

#spos .tabp .ex-q {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-family: var(--nlm-font-display);
  font-weight: 600;
  font-size: clamp(16px, 1.6vw, 19px);
  line-height: 1.4;
  color: var(--nlm-fg-1);
}

#spos .ex-q .env {
  flex: none;
  margin-top: 2px;
}

/* ---------- 08 getting started ---------- */

#spos .tl-wrap {
  position: relative;
}

#spos .tl {
  position: relative;
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(18px, 3vw, 40px);
}

#spos .tl-line {
  position: absolute;
  top: 21px;
  inset-inline: 21px;
  height: 2px;
  background: var(--nlm-signal);
  transform-origin: 0 50%;
}

[dir="rtl"] #spos .tl-line {
  transform-origin: 100% 50%;
}

/* Scroll-linked, so only where view() timelines exist (see .reveal). */
@supports (animation-timeline: view()) {
  #spos .tl-line {
    animation: so-draw linear both;
    animation-timeline: view();
    animation-range: entry 10% cover 45%;
  }

  #spos .tl-dot {
    animation: pq-pop 0.6s var(--nlm-ease-soft) both;
    animation-timeline: view();
    animation-range: entry 20% cover 40%;
  }
}

#spos .tl li {
  position: relative;
}

#spos .tl-dot {
  position: relative;
  z-index: 1;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  color: #fff;
  background: var(--nlm-navy-900);
  box-shadow: 0 0 0 6px #fff;
}

#spos .tl-dot :is(svg, i[data-lucide]) {
  width: 20px;
  height: 20px;
}

#spos .tl h3 {
  font-family: var(--nlm-font-display);
  font-weight: 700;
  font-size: 19px;
  color: var(--nlm-fg-1);
  margin: 0 0 8px;
}

#spos .tl p {
  font-size: 15px;
  line-height: 1.65;
  color: var(--nlm-fg-2);
  margin: 0;
}

/* ---------- final cta ---------- */

#spos .final .h2 {
  max-width: 24ch;
  margin-bottom: 16px;
}

#spos .cta-note {
  max-width: 46ch;
  margin: 0 auto 32px;
  font-size: clamp(15px, 1.5vw, 18px);
  line-height: 1.55;
  color: var(--nlm-navy-300);
}

#spos .cv-t {
  width: 34px;
}

/* The one line splits into five team lanes before it resolves into the wordmark. */
#spos .cv-fan {
  position: absolute;
  top: 50%;
  inset-inline-end: 12%;
  width: 0;
  height: 0;
}

#spos .cv-fan i {
  position: absolute;
  top: -1px;
  inset-inline-start: 0;
  width: 46px;
  height: 2px;
  background: var(--nlm-signal);
  opacity: 0;
  transform-origin: 0 50%;
  transform: rotate(calc((var(--i) - 2) * 15deg * var(--dir)));
  transition: transform 0.45s var(--nlm-ease-soft) 1.4s, opacity 0.4s 1.9s;
}

[dir="rtl"] #spos .cv-fan i {
  transform-origin: 100% 50%;
}

#spos .cv.is-armed .cv-fan i {
  opacity: 1;
  transform: rotate(calc((var(--i) - 2) * 15deg * var(--dir))) scaleX(0);
  transition: none;
}

#spos .cv.is-armed.is-in .cv-fan i {
  opacity: 0;
  transform: rotate(calc((var(--i) - 2) * 15deg * var(--dir)));
  transition: transform 0.45s var(--nlm-ease-soft) 1.4s, opacity 0.4s 1.9s;
}

#spos .also {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px 14px;
  margin: 30px 0 0;
  font-family: var(--nlm-font-mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--nlm-navy-400);
}

#spos .also a {
  color: #fff;
  text-decoration: none;
  border: 1px solid rgb(255 255 255 / 22%);
  border-radius: 999px;
  padding: 5px 12px;
  transition: border-color 0.2s, background 0.2s;
}

#spos .also a:hover {
  border-color: var(--nlm-signal);
  background: var(--nlm-signal);
}

/* ---------- responsive ---------- */

@media (width <= 1180px) {
  #spos .feats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  /* The rail is a bar under the header here, so the corner is free. */
  #spos .toasts {
    inset-inline-end: 16px;
  }

}

@media (width <= 980px) {
  #spos .esc-g,
  #spos .out-g,
  #spos .tabp {
    grid-template-columns: minmax(0, 1fr);
  }

  #spos .tri-grid {
    grid-template: "inbox" auto "lanes" auto "detail" auto / minmax(0, 1fr);
  }

  #spos .inbox {
    min-height: 0;
  }

  #spos .steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #spos .mails {
    position: static;
    max-height: 380px;
  }

  /* The meter rides the bottom of the screen here (see product-page.css), so it
     is kept short: the four figures sit two by two. */
  #spos .meter-l {
    margin-bottom: 4px;
  }

  #spos .meter-h {
    font-size: 22px;
    margin: 0 0 8px;
  }

  #spos .meter-rows {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px 16px;
    font-size: 11.5px;
    line-height: 1.3;
  }

  #spos .meter-rows > div {
    flex-direction: column;
    gap: 1px;
  }

  /* The lanes scroll sideways inside their own box; the page never does. */
  #spos .lanes {
    grid-template-columns: repeat(5, minmax(150px, 1fr));
    overflow-x: auto;
    overscroll-behavior-x: contain;
    padding-bottom: 6px;
  }

  #spos .lane {
    min-height: 220px;
  }

  #spos .clockbox {
    align-items: center;
  }
}

@media (width <= 640px) {
  #spos .hs-top {
    grid-template-columns: minmax(0, 1fr);
    justify-items: stretch;
  }

  #spos .hs-boxes {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #spos .hs-ai {
    flex-direction: row;
    justify-content: center;
    gap: 8px;
  }

  #spos .ladder,
  #spos .people,
  #spos .tri-n {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  #spos .hs-foot {
    flex-direction: column;
    align-items: flex-start;
  }

  /* Clear of the inbox tiles, which are the first thing in the stage here. */
  #spos .hs-stamp {
    inset-block-start: -36px;
  }

  #spos .steps,
  #spos .feats,
  #spos .detail-g,
  #spos .legend dl,
  #spos .tl {
    grid-template-columns: minmax(0, 1fr);
  }

  #spos .tl-line {
    display: none;
  }

  #spos .tri-ctl {
    flex-direction: column;
    width: 100%;
  }

  #spos .tri-ctl :is(.btn-n, .btn-g) {
    justify-content: center;
  }

  #spos .esc-ctl :is(.btn-n, .btn-gold) {
    flex: 1;
    justify-content: center;
  }

  #spos .pick,
  #spos .pick label {
    width: 100%;
  }

  #spos .pick-c {
    max-width: none;
  }

  #spos .esc-stamp {
    inset-inline-end: 8px;
  }

  /* The table reads as stacked cards: pain, then what the AI does, then the outcome. */
  #spos .core,
  #spos .core tbody,
  #spos .core tr,
  #spos .core :is(th, td) {
    display: block;
  }

  #spos .core thead {
    display: none;
  }

  #spos .core tr {
    margin-bottom: 8px;
    background: var(--nlm-navy-900);
    border: 1px solid var(--nlm-line-dark);
    border-radius: 10px;
    padding: 8px 4px;
  }

  #spos .core tbody :is(th, td),
  #spos .core tbody :is(th, td):is(:first-child, :last-child) {
    background: transparent;
    border: 0;
    border-radius: 0;
    padding-block: 4px;
  }

  #spos .rbars li {
    grid-template-columns: minmax(0, 104px) minmax(0, 1fr) 36px;
  }

  #spos .toasts {
    inset-inline: 12px;
    width: auto;
  }

  #spos .toast:nth-last-child(n + 3) {
    display: none;
  }
}
