/* Cases on the landing: one illustrative Case, read as a story while you scroll.
   A single thread runs from the question to the decision; the recorded movements
   flow into it where Ginsi's reading begins. No card, no tabs. data-case-* owns state. */

html[data-landing-style='photographic'] .case-scene {
  padding: clamp(96px, 11vw, 168px) var(--f-gutter) clamp(120px, 13vw, 200px);
  background: var(--f-paper);
}
.case-story {
  --case-indent: clamp(28px, 7.5vw, 116px);
  /* The Case keeps its original olive-grey tones. */
  --case-ink: #282b25;
  --case-ink-2: #3a3d37;
  --case-muted: #6d6e69;
  --case-faint: #8b8e85;
  --case-rule: rgb(19 19 18 / 0.14);
  position: relative;
  max-width: 1320px;
  margin: clamp(56px, 7vw, 110px) auto 0;
  padding-left: var(--case-indent);
  color: var(--case-ink);
}

/* ---------- The thread ---------- */
.case-thread {
  position: absolute;
  left: 0;
  top: calc(0.47 * clamp(44px, 5.4vw, 92px));
  bottom: 13px;
  width: 1px;
  background: var(--case-rule);
}
.case-thread > i {
  position: absolute;
  inset: 0;
  background: var(--case-ink);
  transform-origin: 50% 0;
  transform: scaleY(var(--case-progress, 1));
}
.case-opening h3::before,
.case-signals::before,
.case-evidence h4::before,
.case-facts::before,
.case-decided h4::before,
.case-story > .exhibit-link::before {
  content: '';
  position: absolute;
  left: calc(-1 * var(--case-indent) - 4px);
  width: 9px;
  height: 9px;
  box-sizing: border-box;
  border: 1px solid var(--case-ink);
  border-radius: 50%;
  background: var(--case-ink);
  transition:
    background-color 500ms ease,
    transform 700ms var(--f-ease);
}
.case-opening h3::before,
.case-evidence h4::before,
.case-decided h4::before {
  top: calc(0.49em - 4.5px);
}
.case-signals::before {
  top: 4px;
}
.case-facts {
  position: relative;
}
.case-facts::before {
  top: calc(0.4 * clamp(64px, 6.4vw, 108px) - 4.5px);
}
.case-story > .exhibit-link::before {
  top: calc(50% - 4.5px);
}
/* With motion, a step fills as the thread reaches it. */
.case-story.case-live
  :is(.case-opening h3, .case-signals, .case-evidence h4, .case-facts, .case-decided h4)::before,
.case-story.case-live > .exhibit-link::before {
  background: var(--f-paper, #fff);
}
.case-story.case-live
  :is(
    .case-opening h3,
    .case-signals,
    .case-evidence h4,
    .case-facts,
    .case-decided h4
  )[data-reached]::before,
.case-story.case-live > .exhibit-link[data-reached]::before {
  background: var(--case-ink);
  transform: scale(1.15);
}

/* ---------- The question and the people in the Case ---------- */
.case-opening h3,
.case-beat h4 {
  position: relative;
  margin: 0;
  font-family: var(--ginsi-public-font);
  font-weight: 400;
}
.case-opening h3 {
  font-size: clamp(44px, 5.4vw, 92px);
  line-height: 0.96;
  letter-spacing: -0.052em;
}
.case-team {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 32px;
  margin-top: clamp(26px, 3vw, 44px);
}
.case-investigation .ci-sharing {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px 16px;
}
.case-investigation .ci-members {
  display: flex;
  padding-left: 8px;
}
.case-investigation .ci-members > span {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  margin-left: -8px;
  border: 2px solid var(--f-paper, #fff);
  border-radius: 50%;
  color: #f5f5f2;
  background: #41454a;
  font: 500 10px/1 var(--ginsi-public-font);
  letter-spacing: 0.02em;
}
.case-investigation .ci-members > span + span {
  background: #727877;
}
.case-investigation .ci-human-member {
  overflow: hidden;
}
.case-investigation .ci-human-member img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.case-investigation [data-case-new-member] {
  animation: ci-member-in 520ms var(--f-ease) both;
}
@keyframes ci-member-in {
  from {
    opacity: 0;
    transform: translateX(-10px) scale(0.8);
  }
}
.case-investigation .ci-sharing-button {
  display: inline-flex;
  white-space: nowrap;
  align-items: center;
  gap: 12px;
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid rgb(19 19 18 / 0.22);
  border-radius: 0;
  background: transparent;
  color: var(--case-ink);
  font: 400 14px/1 var(--ginsi-public-font);
  cursor: pointer;
  transition:
    background-color 300ms ease,
    border-color 300ms ease,
    color 300ms ease;
}
.case-investigation .ci-sharing-button:hover {
  border-color: var(--case-ink);
  background: var(--case-ink);
  color: var(--f-paper, #fff);
}
.case-investigation .ci-sharing-button > span {
  font-size: 16px;
}
.case-investigation :is(.ci-sharing-button, .ci-share-panel button):focus-visible {
  outline: 2px solid var(--case-ink);
  outline-offset: 4px;
}
.case-investigation .ci-identity {
  margin: 0;
  color: var(--case-muted);
  font-size: 14px;
  line-height: 1.4;
}
.case-investigation .ci-identity strong {
  margin-right: 10px;
  color: var(--case-ink);
  font-weight: 500;
}
.case-investigation .ci-share-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  max-width: 880px;
  margin-top: 24px;
  padding: 22px 26px;
  background: #f6f6f6;
  border-left: 2px solid var(--tone, #ad9da9);
  animation: ci-panel-open 600ms var(--f-ease) both;
}
@keyframes ci-panel-open {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
}
.case-investigation .ci-share-panel h4 {
  margin: 0 0 8px;
  font-size: 19px;
  font-weight: 500;
  letter-spacing: -0.025em;
}
.case-investigation .ci-share-panel p {
  max-width: 64ch;
  color: var(--case-ink-2);
  font-size: 14px;
  line-height: 1.55;
}
.case-investigation .ci-share-panel > div > span {
  display: block;
  margin-top: 12px;
  color: var(--case-muted);
  font-size: 12px;
}
.case-investigation .ci-share-panel button {
  flex: none;
  padding: 9px 0;
  border-bottom: 1px solid var(--case-ink);
  font-size: 14px;
}

/* ---------- Beats ---------- */
.case-beat {
  position: relative;
  margin-top: clamp(104px, 11vw, 176px);
}
.case-beat h4 {
  font-size: clamp(40px, 4.6vw, 78px);
  line-height: 0.98;
  letter-spacing: -0.048em;
}
.case-beat p {
  color: var(--case-ink-2);
  font-size: 17px;
  line-height: 1.55;
}
.case-beat .case-note,
.case-beat .case-caption {
  color: var(--case-muted);
  font-size: 13px;
  line-height: 1.5;
}
.case-beat .case-note {
  max-width: 46ch;
  margin-top: 18px;
}
.case-earlier,
.case-later {
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.case-earlier {
  color: var(--case-faint);
  font-size: 0.5em;
  letter-spacing: -0.02em;
}
.case-later {
  font-weight: 400;
}
.case-earlier small,
.case-later small {
  margin-left: 0.06em;
  color: var(--case-muted);
  font-size: 0.4em;
  letter-spacing: 0;
}
.case-earlier small {
  font-size: 0.6em;
  color: inherit;
}
.case-arrow {
  position: relative;
  display: inline-block;
  flex: none;
  width: 0.55em;
  height: 1px;
  margin: 0 0.16em;
  align-self: center;
  background: var(--case-faint);
}
.case-arrow::after {
  content: '';
  position: absolute;
  right: 0;
  top: -3px;
  width: 6px;
  height: 6px;
  border-top: 1px solid var(--case-faint);
  border-right: 1px solid var(--case-faint);
  transform: rotate(45deg);
}

/* Evidence: three recorded movements, side by side. */
.case-signals {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(24px, 4vw, 64px);
  margin: 0;
  padding: 0;
  list-style: none;
}
.case-signals > li {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.case-signal-name {
  color: var(--case-muted);
  font-size: 15px;
}
.case-signal-values {
  display: flex;
  align-items: baseline;
  font-size: clamp(52px, 5.8vw, 96px);
  line-height: 0.9;
  letter-spacing: -0.055em;
}
.case-signal-note {
  margin-top: -4px;
  color: var(--case-muted);
  font-size: 13px;
}
.case-converge {
  position: absolute;
  z-index: 0;
  top: 0;
  left: calc(-1 * var(--case-indent));
  width: calc(100% + var(--case-indent));
  height: 100%;
  overflow: visible;
  pointer-events: none;
}
.case-converge path {
  fill: none;
  stroke: var(--case-ink);
  stroke-width: 1;
  stroke-dasharray: 1;
  /* The three lines pour in together, the furthest a moment behind. */
  stroke-dashoffset: min(1, calc(var(--case-draw, 0) * (1 + var(--i, 0) * 0.3)));
  opacity: 0.42;
}
.case-reading {
  position: relative;
  z-index: 1;
}
.case-evidence .case-reading {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: clamp(32px, 6vw, 110px);
  align-items: end;
  margin-top: clamp(100px, 10vw, 150px);
}
.case-evidence .case-reading p:first-child {
  max-width: 38ch;
}

/* Context: new facts that change the reading. */
.case-context,
.case-decision {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr);
  gap: clamp(40px, 8vw, 150px);
  align-items: start;
}
.case-facts {
  display: grid;
}
.case-investigation .ci-cohort,
.case-investigation .ci-routing {
  display: flex;
  align-items: center;
  gap: 26px;
  padding: 26px 0;
}
.case-investigation .ci-cohort {
  padding-top: 0;
}
.case-investigation .ci-routing {
  border-top: 1px solid var(--case-rule);
}
.case-investigation .ci-cohort > strong {
  min-width: 1.2em;
  font: 400 clamp(64px, 6.4vw, 108px) / 0.8 var(--ginsi-public-font);
  letter-spacing: -0.06em;
}
.case-facts p {
  color: var(--case-ink);
  font-size: 17px;
  line-height: 1.35;
}
.case-facts p span {
  display: block;
  margin-top: 6px;
  color: var(--case-muted);
  font-size: 13px;
}
.case-investigation .ci-routing svg {
  flex: none;
  width: clamp(56px, 5.4vw, 88px);
  height: auto;
  fill: none;
  /* A change in how work is routed belongs to integrations: slate. */
  stroke: var(--t-integrations, #596e7b);
  stroke-width: 1.2;
}
.case-context .case-reading > div {
  margin-top: 26px;
}
.case-context .case-reading p:first-child {
  max-width: 44ch;
}
.case-investigation .ci-missing {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 22px;
  margin-top: 22px;
  font-size: 15px;
}
.case-investigation .ci-missing strong {
  color: var(--case-muted);
  font-weight: 400;
}
.case-investigation .ci-missing span {
  color: var(--case-ink-2);
  text-decoration: underline dashed rgb(19 19 18 / 0.4);
  text-decoration-thickness: 1px;
  text-underline-offset: 6px;
}

/* Decision: what was decided, and what happened after. */
.case-decision {
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  align-items: end;
}
.case-decided h4 {
  font-size: clamp(44px, 5.2vw, 88px);
}
.case-decided-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 18px;
  margin-top: 28px;
}
.case-investigation .ci-duration {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  margin: 0;
  color: var(--case-ink);
  font-size: 17px;
}
.case-investigation .ci-duration strong {
  font-weight: 500;
}
.case-beat .case-outcome-values {
  display: flex;
  align-items: baseline;
  margin: 14px 0 0;
  color: var(--case-ink);
  font-size: clamp(52px, 5.8vw, 96px);
  line-height: 0.9;
  letter-spacing: -0.055em;
}
.case-investigation .ci-unresolved {
  display: inline-block;
  margin-top: 22px;
  color: var(--case-ink);
  text-decoration: underline dashed rgb(19 19 18 / 0.4);
  text-decoration-thickness: 1px;
  text-underline-offset: 6px;
}

html[data-landing-style='photographic'] .case-story > .exhibit-link {
  position: relative;
  margin-top: clamp(100px, 10vw, 160px);
  color: var(--case-ink);
  font-size: 15px;
}

@media (max-width: 1000px) {
  .case-signals {
    grid-template-columns: minmax(0, 1fr);
    gap: 34px;
  }
  .case-signals > li {
    gap: 10px;
  }
  .case-converge {
    display: none;
  }
  .case-evidence .case-reading,
  .case-context,
  .case-decision {
    grid-template-columns: minmax(0, 1fr);
    gap: 26px;
  }
  .case-evidence .case-reading {
    margin-top: 72px;
  }
}
@media (max-width: 700px) {
  .case-story {
    --case-indent: 26px;
  }
  .case-story .ci-desktop-break {
    display: none;
  }
  .case-beat {
    margin-top: 96px;
  }
  .case-beat p {
    font-size: 16px;
  }
  .case-team {
    gap: 14px;
  }
  .case-investigation .ci-share-panel {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
    padding: 18px;
  }
  .case-investigation .ci-cohort,
  .case-investigation .ci-routing {
    gap: 18px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .case-investigation [data-case-new-member],
  .case-investigation .ci-share-panel {
    animation: none;
  }
}
