/* Home: ways to work together and fit (owned by the shapes rework).
   A path, not three boxes: 01 start, 02 widen, 03 the alternative branch.
   Each option gets a small diagram in the site's language: dot map, trigger lanes, sellers. */

.ways { --gap: clamp(40px, 5.6vw, 84px); }
.ways__head { margin-bottom: clamp(44px, 5vw, 68px); }

/* ---------- the path ---------- */
.ways__path { display: grid; grid-template-columns: 5fr 7fr; grid-template-rows: auto auto auto; column-gap: var(--gap); }
.way { display: grid; grid-template-rows: subgrid; grid-row: span 3; align-content: start; }
.way__txt { display: grid; gap: 10px; align-content: start; padding-top: 30px; }
.way__txt h3 { color: var(--on-ink); }
.way__txt .body { max-width: 44ch; }

/* rail: a node, a label and a line that runs on to the next station */
.way__tag { display: flex; align-items: center; gap: 12px; margin: 0 0 22px; font-size: 15px; color: var(--on-ink); font-weight: 500; }
.way__node { width: 30px; height: 30px; flex: none; border-radius: 50%; display: grid; place-items: center;
  font: 500 11px/1 var(--mono); letter-spacing: .02em; color: var(--on-ink); border: 1px solid var(--ink-line-strong); }
.way--start .way__node { background: var(--accent); border-color: var(--accent); color: var(--ink); }
.way--wide .way__node { background: var(--on-ink); border-color: var(--on-ink); color: var(--ink); }
.way__tag--or .way__node { border-style: dashed; border-color: rgba(244,240,232,.5); }
.way__rail { flex: 1; height: 1px; background: var(--ink-line-strong); position: relative; margin-left: 6px; }
.way--start .way__rail { margin-right: calc(-1 * var(--gap) + 10px); }
.way--start .way__rail::after { content: ""; position: absolute; right: 0; top: -4px; width: 8px; height: 8px;
  border-top: 1px solid rgba(244,240,232,.5); border-right: 1px solid rgba(244,240,232,.5); transform: rotate(45deg); }
.way--start .way__rail { background: rgba(244,240,232,.4); }
.way__tag--or .way__rail { background: repeating-linear-gradient(90deg, var(--ink-line-strong) 0 5px, transparent 5px 10px); }

/* ---------- diagram panel ---------- */
.wd { margin: 0; background: var(--ink-2); border: 1px solid var(--ink-line); border-radius: 16px;
  padding: clamp(18px, 2vw, 26px); display: grid; grid-template-columns: auto 1fr auto; gap: clamp(14px, 1.6vw, 22px); align-items: center; min-width: 0; }
.wd__cap { font: 11px/1.3 var(--mono); color: var(--on-ink-muted); letter-spacing: .02em; text-align: center; }

/* dot map: a 12px grid with the sellable accounts lit and a few trigger colours.
   Built from background layers so it needs no markup; size stays a multiple of 12 so no dot is clipped. */
.dots { display: block; width: 96px; height: 156px; border-radius: 4px;
  --g: rgba(244,240,232,.16);
  --s: rgba(244,240,232,.82);
  --L-faint: radial-gradient(circle at 6px 6px, var(--g) 1.2px, transparent 1.7px) 0 0 / 12px 12px;
  --L-s1: radial-gradient(circle at 6px 6px, var(--s) 2px, transparent 2.5px) 12px 0 / 36px 48px;
  --L-s2: radial-gradient(circle at 6px 6px, var(--s) 2px, transparent 2.5px) 36px 24px / 60px 36px;
  --L-s3: radial-gradient(circle at 6px 6px, var(--s) 2px, transparent 2.5px) 0 36px / 48px 60px;
  --L-s4: radial-gradient(circle at 6px 6px, var(--s) 2px, transparent 2.5px) 72px 12px / 84px 72px;
  --L-role: radial-gradient(circle at 6px 6px, var(--sig-role) 2.8px, transparent 3.3px) 24px 72px / 96px 108px;
  --L-champ: radial-gradient(circle at 6px 6px, var(--sig-champion) 2.8px, transparent 3.3px) 60px 24px / 108px 96px;
  --L-social: radial-gradient(circle at 6px 6px, var(--sig-social) 2.8px, transparent 3.3px) 0 108px / 72px 132px;
  --L-hiring: radial-gradient(circle at 6px 6px, var(--sig-hiring) 2.8px, transparent 3.3px) 84px 0 / 120px 84px;
  --L-news: radial-gradient(circle at 6px 6px, var(--sig-news) 2.8px, transparent 3.3px) 36px 144px / 84px 120px;
  --L-visit: radial-gradient(circle at 6px 6px, var(--sig-visit) 2.8px, transparent 3.3px) 48px 48px / 132px 108px;
  background: var(--L-s1), var(--L-s2), var(--L-s3), var(--L-s4), var(--L-faint);
  background-repeat: repeat; }
.dots--3 { background: var(--L-role), var(--L-champ), var(--L-social), var(--L-s1), var(--L-s2), var(--L-s3), var(--L-s4), var(--L-faint); }
.dots--6 { background: var(--L-role), var(--L-champ), var(--L-social), var(--L-hiring), var(--L-news), var(--L-visit), var(--L-s1), var(--L-s2), var(--L-s3), var(--L-s4), var(--L-faint); }
.wd__map { display: grid; gap: 10px; justify-items: center; }

/* trigger lanes: label above a line that runs into the sellers */
.wd__lanes { display: grid; gap: 20px; align-content: center; min-width: 0; }
.wd--wide .wd__lanes { gap: 9px; }
.ln { display: grid; gap: 6px; min-width: 0; }
.ln b { font: 500 11.5px/1.2 var(--mono); color: var(--on-ink); letter-spacing: .01em; display: flex; align-items: center; gap: 7px; white-space: nowrap; min-width: 0; }
.ln b::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--c); flex: none; }
.ln i { display: block; height: 2px; border-radius: 2px; background: var(--c); position: relative; transform-origin: left center; }
.ln i::after { content: ""; position: absolute; right: -1px; top: -3px; border-left: 6px solid var(--c); border-top: 4px solid transparent; border-bottom: 4px solid transparent; }
.wd--wide .ln i { height: 1.5px; }
.wd--wide .ln i::after { top: -3.25px; }
/* the funnel lane: wide at the market, narrow at the seller */
.ln--funnel { margin-top: 6px; }
.ln--funnel b::before { border-radius: 2px; }
.ln--funnel b { flex-wrap: wrap; row-gap: 6px; }
.langs { display: inline-flex; gap: 4px; }
.langs em { font-style: normal; font-size: 10px; color: var(--on-ink-muted); border: 1px solid var(--ink-line-strong); border-radius: 4px; padding: 2px 4px; }
.ln--funnel i, .wd--wide .ln--funnel i { height: 10px; border-radius: 0; background: var(--accent); clip-path: polygon(0 0, 100% 42%, 100% 58%, 0 100%); }
.ln--funnel i::after { display: none; }

/* sellers */
.wd__out { display: grid; gap: 8px; justify-items: center; align-content: center; min-width: 76px; }
.wchip { font: 500 10.5px/1 var(--mono); color: var(--on-ink); border: 1px solid var(--ink-line-strong); border-radius: 999px; padding: 5px 9px; white-space: nowrap; }
.seats { display: grid; grid-template-columns: 12px; gap: 6px; margin: 6px 0 2px; }
.seats--2 { grid-template-columns: 12px 12px; }
.seats i { width: 12px; height: 12px; border-radius: 50%; background: var(--on-ink); display: block; }

/* ---------- 03: our workspace into yours ---------- */
.way--own { margin-top: clamp(56px, 5.4vw, 76px); display: grid; grid-template-columns: 5fr 7fr; column-gap: var(--gap); grid-template-areas: "tag tag" "txt fig"; align-items: center; }
.way--own .way__tag { grid-area: tag; }
.way--own .way__txt { grid-area: txt; padding-top: 0; }
.way--own .wd { grid-area: fig; }
.wd--own { grid-template-columns: 1fr auto 1fr; align-items: stretch; }
.ws { border: 1px dashed var(--ink-line-strong); border-radius: 12px; padding: 14px 16px 16px; display: grid; gap: 14px; align-content: start; min-width: 0; }
.ws--yours { border: 1px solid rgba(244,240,232,.34); background: var(--ink-3); }
.ws__h { font: 500 11.5px/1 var(--mono); color: var(--on-ink-muted); display: flex; align-items: center; gap: 8px; min-height: 20px; }
.ws--yours .ws__h { color: var(--on-ink); }
.ws__h img { width: 18px; height: auto; }
.mini { display: grid; grid-template-columns: 48px 1fr; gap: 14px; align-items: center; }
.dots.dots--mini { width: 48px; height: 48px; }
.mini__lanes { display: grid; gap: 11px; }
.mini__lanes i { display: block; height: 2px; border-radius: 2px; background: var(--c); position: relative; transform-origin: left center; }
.mini__lanes i::after { content: ""; position: absolute; right: -1px; top: -3px; border-left: 6px solid var(--c); border-top: 4px solid transparent; border-bottom: 4px solid transparent; }
.ws__chips { display: flex; flex-wrap: wrap; gap: 6px; }
.ws__arrow { display: flex; align-items: center; width: clamp(28px, 3vw, 44px); }
.ws__arrow i { flex: 1; height: 1px; background: var(--on-ink); position: relative; transform-origin: left center; }
.ws__arrow i::after { content: ""; position: absolute; right: 0; top: -4px; width: 8px; height: 8px; border-top: 1px solid var(--on-ink); border-right: 1px solid var(--on-ink); transform: rotate(45deg); }

/* ---------- lists ---------- */
.way__list { list-style: none; padding: 0; margin: 10px 0 0; display: grid; gap: 9px; font-size: 15.5px; color: var(--on-ink); }
.way__list li { display: flex; gap: 11px; align-items: baseline; }
.way__list li::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--on-ink-muted); flex: none; transform: translateY(-3px); }

/* ---------- fit: five figures on a paper card ---------- */
.fitp { margin-top: clamp(64px, 7vw, 96px); background: var(--paper); color: var(--text); border-radius: var(--radius-lg); padding: clamp(24px, 3vw, 42px) clamp(22px, 3.2vw, 46px); }
.fitp__h { font-size: clamp(26px, 2.4vw, 34px); color: var(--text); }
.fitp__row { list-style: none; padding: 0; margin: clamp(26px, 3vw, 40px) 0 0; display: grid; grid-template-columns: repeat(5, 1fr); }
.fitp__row li { display: grid; gap: 14px; align-content: start; padding: 4px clamp(14px, 1.8vw, 26px) 0; border-left: 1px solid var(--line); }
.fitp__row li:first-child { border-left: 0; padding-left: 0; }
.fitp__n { font-family: var(--serif); font-weight: 700; font-variation-settings: "opsz" 60; font-size: clamp(44px, 4.6vw, 70px); line-height: .95; letter-spacing: -0.045em; white-space: nowrap; }
.fitp__n small { font-size: .4em; font-weight: 650; letter-spacing: -0.01em; }
.fitp__n .c { margin: 0 .06em; white-space: pre; }
.fitp__n .u { margin-left: .1em; white-space: pre; }
.fitp__row span { font-size: 15px; line-height: 1.45; color: var(--muted); max-width: 24ch; }

/* ---------- motion: lanes draw toward the sellers, then the sellers light up ---------- */
.wd .ln i, .wd .ws__arrow i { transform: scaleX(0); transition: transform .9s var(--ease); }
.wd .ln:nth-child(2) i { transition-delay: .1s; } .wd .ln:nth-child(3) i { transition-delay: .2s; }
.wd .ln:nth-child(4) i { transition-delay: .3s; } .wd .ln:nth-child(5) i { transition-delay: .4s; }
.wd .ln:nth-child(6) i { transition-delay: .5s; } .wd .ln:nth-child(7) i { transition-delay: .6s; }
.wd .seats i { opacity: .18; transition: opacity .5s var(--ease); }
.wd .seats i:nth-child(odd) { transition-delay: .9s; } .wd .seats i:nth-child(even) { transition-delay: 1.05s; }
.wd.in .ln i, .wd.in .ws__arrow i { transform: none; }
.wd.in .seats i { opacity: 1; }
/* 03: the system leaves our workspace and settles in yours */
.wd--own .ws--ours .mini { transition: opacity .9s var(--ease) .5s; }
.wd--own .ws--yours .mini, .wd--own .ws__chips { opacity: 0; transform: translateX(-10px); transition: opacity .8s var(--ease) .8s, transform .8s var(--ease) .8s; }
.wd--own .ws__chips { transition-delay: 1.05s; }
.wd--own .ws__arrow i { transition-delay: .3s; }
.wd--own.in .ws--ours .mini { opacity: .42; }
.wd--own.in .ws--yours .mini, .wd--own.in .ws__chips { opacity: 1; transform: none; }
.fitp__row li { opacity: 0; transform: translateY(12px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.fitp__row li:nth-child(2) { transition-delay: .08s; } .fitp__row li:nth-child(3) { transition-delay: .16s; }
.fitp__row li:nth-child(4) { transition-delay: .24s; } .fitp__row li:nth-child(5) { transition-delay: .32s; }
.fitp__row.in li { opacity: 1; transform: none; }

/* end states without motion or without JS */
@media (prefers-reduced-motion: reduce) {
  .wd .ln i, .wd .ws__arrow i, .wd--own .ws--yours .mini, .wd--own .ws__chips, .fitp__row li { transform: none; transition: none; }
  .wd .seats i, .wd--own .ws--yours .mini, .wd--own .ws__chips, .fitp__row li { opacity: 1; transition: none; }
  .wd--own .ws--ours .mini { opacity: .42; transition: none; }
}
.no-js .wd .ln i, .no-js .wd .ws__arrow i, .no-js .wd--own .ws--yours .mini, .no-js .wd--own .ws__chips, .no-js .fitp__row li { transform: none; }
.no-js .wd .seats i, .no-js .wd--own .ws--yours .mini, .no-js .wd--own .ws__chips, .no-js .fitp__row li { opacity: 1; }
.no-js .wd--own .ws--ours .mini { opacity: .42; }

/* ---------- smaller screens ---------- */
@media (max-width: 1180px) {
  .ways__path { grid-template-columns: 1fr; grid-template-rows: none; row-gap: clamp(56px, 6vw, 72px); }
  .way, .way--own { grid-row: auto; grid-template-rows: none; grid-template-columns: 5fr 7fr; column-gap: clamp(28px, 4vw, 48px); grid-template-areas: "tag tag" "txt fig"; align-items: center; }
  .way .way__tag { grid-area: tag; }
  .way .way__txt { grid-area: txt; padding-top: 0; }
  .way .wd { grid-area: fig; }
  .way--start .way__rail { margin-right: 0; }
  .way--start .way__rail::after { display: none; }
}
@media (max-width: 900px) {
  .fitp__row { grid-template-columns: 1fr; }
  .fitp__row li { grid-template-columns: clamp(112px, 22vw, 180px) 1fr; align-items: center; gap: 14px; border-left: 0; padding: 16px 0; border-top: 1px solid var(--line); }
  .fitp__row li:first-child { border-top: 0; padding-top: 4px; }
  .fitp__row span { max-width: 44ch; }
  .fitp__n { font-size: clamp(38px, 6vw, 52px); }
}
@media (max-width: 900px) {
  .way, .way--own { grid-template-columns: 1fr; grid-template-areas: "tag" "fig" "txt"; }
  .way .way__txt { padding-top: 24px; }
}
@media (max-width: 480px) {
  .wd { padding: 16px 14px; gap: 12px; }
  .dots { width: 60px; height: 144px; }
  .ln b { font-size: 11px; }
  .wd__out { min-width: 0; }
  .wd__out .wd__cap { max-width: 8ch; }
  .wd--own { gap: 8px; }
  .ws { padding: 12px; }
  .mini { grid-template-columns: 36px 1fr; gap: 10px; }
  .dots.dots--mini { width: 36px; height: 48px; }
  .ws__arrow { width: 18px; }
}

/* Round 2 QA */
#clay + .sec.ink { padding-top: 0; }
@media (max-width: 480px) { .ln b { white-space: normal; align-items: flex-start; } .ln b::before { margin-top: 3px; } }
