/* ============================================================
   SUCCESS STORIES PAGE — #fafafa throughout
   ============================================================ */
body.cs-page{background:var(--mist)}
.cs-page .nav{position:sticky;background:#000;border-bottom:1px solid rgba(255,255,255,.08)}
.cs-wrap{max-width:var(--maxw);margin:0 auto;padding:0 var(--pad)}

/* hero feature — full bleed, 80vh, split 50/50 */
.cs-hero{padding:0}
.cs-feature{display:grid;grid-template-columns:1fr 1fr;min-height:80vh;text-decoration:none;color:inherit;overflow:hidden}
.cf-text{background:#fff;display:flex;flex-direction:column;justify-content:center;gap:20px;padding:clamp(34px,5vw,72px)}
.cf-text .eyebrow{margin-bottom:2px}
.cf-text h1{font-family:var(--display);font-weight:800;font-size:var(--fs-h1,clamp(2rem,3.6vw,3.3rem));line-height:1.04;letter-spacing:-.015em;margin:0;color:#0a0a0a;max-width:18ch}
.cf-text .tag{align-self:flex-start}
.cf-stats{font-family:var(--mono);font-size:.82rem;letter-spacing:calc(.024em * var(--mono-track, 1));color:var(--grey-deep);line-height:1.7;margin:0}
.cf-stats b{color:#0a0a0a}
/*
 * "Read the story" — the feature's only visible control.
 *
 * Sized to the stats line above it rather than to a number picked for this one
 * label: at .72rem it was the smallest type on a link 700px tall, and the whole
 * card read as a picture with a caption instead of as something to click.
 * Matching .cf-stats keeps the two mono lines in the same voice.
 */
.cf-read{font-family:var(--mono);font-size:.82rem;letter-spacing:calc(.064em * var(--mono-track, 1));text-transform:uppercase;color:var(--neon);display:inline-flex;align-items:center;gap:10px;margin-top:4px;transition:color .2s}
.cf-read .arw{transition:transform .2s}
/*
 * Orange to black on hover, arrow and all — the arrow is inside the label, so
 * it takes the colour with it and the control changes as one thing.
 *
 * Stated for :focus-visible too. The whole feature is a single link, and a
 * keyboard user arriving on it had nothing at all to tell them so.
 */
.cs-feature:hover .cf-read,
.cs-feature:focus-visible .cf-read{color:#000}
.cs-feature:hover .cf-read .arw,
.cs-feature:focus-visible .cf-read .arw{transform:translateX(5px)}
.cf-image{position:relative;overflow:hidden;background:#080808;min-height:300px}
.cf-image svg{position:absolute;inset:0;width:100%;height:100%}

/* controls: search + filters (same behaviour as /insights) */
.cs-controls{padding:clamp(40px,6vw,64px) 0 8px}
.searchbar{position:relative;max-width:660px}
.searchbar input{width:100%;padding:14px 46px 14px 2px;border:0;border-bottom:2px solid var(--neon);background:transparent;color:#111;font-size:1.15rem;font-family:var(--body);border-radius:0}
.searchbar input:focus{outline:none;box-shadow:0 2px 0 0 var(--neon),0 8px 12px -10px rgba(255,122,41,.7)}
.searchbar input::placeholder{color:var(--grey)}
.searchbar .s-icon{position:absolute;right:4px;top:50%;transform:translateY(-50%);width:22px;height:22px;color:var(--grey-deep);pointer-events:none}
.filters{display:flex;gap:12px;flex-wrap:wrap;margin-top:24px}
.filter{position:relative}
.filter-btn{display:inline-flex;align-items:center;gap:9px;padding:9px 16px;border:1px solid #d8d8d8;border-radius:30px;background:#fff;font-size:.88rem;cursor:pointer;font-family:var(--body);color:#333;transition:border-color .18s,color .18s}
.filter-btn:hover{border-color:var(--neon)}
.filter-btn.active{border-color:var(--neon);color:#111}
.filter-btn .cnt{display:none;min-width:18px;height:18px;padding:0 5px;border-radius:9px;background:var(--orange);color:#fff;font-family:var(--mono);font-size:.62rem;align-items:center;justify-content:center}
.filter-btn.active .cnt{display:inline-flex}
.filter-btn .chev{transition:transform .2s}
.filter.open .filter-btn .chev{transform:rotate(180deg)}
.filter-panel{position:absolute;top:calc(100% + 8px);left:0;min-width:230px;background:#fff;border:1px solid #e4e4e4;border-radius:12px;box-shadow:0 22px 44px rgba(0,0,0,.12);padding:8px;display:none;z-index:40}
.filter.open .filter-panel{display:block}
.filter-opt{display:flex;align-items:center;gap:11px;padding:8px 10px;border-radius:8px;cursor:pointer;font-size:.9rem;color:#222}
.filter-opt:hover{background:#f5f5f5}
.filter-opt input{accent-color:var(--neon);width:15px;height:15px}
.chips{display:flex;gap:9px;flex-wrap:wrap;margin-top:16px;min-height:2px}
.chip{display:inline-flex;align-items:center;gap:9px;padding:6px 12px;border-radius:30px;background:var(--orange-soft);color:var(--orange);font-size:.78rem;font-family:var(--mono);letter-spacing:calc(.012em * var(--mono-track, 1))}
.chip button{background:none;border:0;color:var(--orange);cursor:pointer;font-size:1.05rem;line-height:1;padding:0}
.chips .clear-all{background:none;border:0;color:var(--grey-deep);font-family:var(--mono);font-size:.72rem;letter-spacing:calc(.048em * var(--mono-track, 1));text-transform:uppercase;cursor:pointer;padding:6px 4px}

/* case cards grid */
.cs-list{padding:26px 0 90px}
.cs-grid{display:grid;grid-template-columns:1fr 1fr;gap:24px}
.cs-card{background:#fff;border:1px solid #ececec;border-radius:16px;overflow:hidden;display:flex;flex-direction:column;text-decoration:none;color:inherit;transition:transform .2s,box-shadow .2s,border-color .2s}
.cs-card:hover{transform:translateY(-4px);box-shadow:0 20px 44px rgba(0,0,0,.09);border-color:#e0e0e0}
.cs-card .cc-img{position:relative;aspect-ratio:16/10;background:#080808;overflow:hidden}
.cs-card .cc-img svg{position:absolute;inset:0;width:100%;height:100%}
/* The helper's wrapper carries the box; the img keeps its own fit/position. */
.cs-card .cc-img .peepal-media{position:absolute;inset:0;height:100%}
.cs-card .cc-img > img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;display:block}

/* Hover: the picture dissolves into the story's headline stat. */
.cs-card .cc-img.has-stat::after{content:"";position:absolute;inset:0;z-index:1;pointer-events:none;opacity:0;transition:opacity .34s ease;
  /* Plain first, color-mix second. An unsupported color-mix invalidates the
     whole declaration rather than just that stop — without a fallback the
     overlay would be transparent and the stat would read straight over the
     photograph. The values are the same mixes, resolved against #fff. */
  background:linear-gradient(180deg,#fff 0%,#fff 46%,#FFDECD 74%,#FFA97A 100%);
  background:linear-gradient(180deg,#fff 0%,#fff 46%,color-mix(in srgb,var(--orange) 22%,#fff) 74%,color-mix(in srgb,var(--orange) 58%,#fff) 100%)}
.cs-card .cc-img.has-stat:hover::after,.cs-card:focus-visible .cc-img.has-stat::after{opacity:1}
.cs-card .cc-img.has-stat img,.cs-card .cc-img.has-stat svg{transition:transform .5s ease}
.cs-card .cc-img.has-stat:hover img,.cs-card .cc-img.has-stat:hover svg,
.cs-card:focus-visible .cc-img.has-stat img,.cs-card:focus-visible .cc-img.has-stat svg{transform:scale(1.04)}
.cs-card .cc-stat{position:absolute;inset:0;z-index:2;display:grid;place-items:center;
  padding:0 22px;text-align:center;pointer-events:none;opacity:0;transform:translateY(10px) scale(.96);transition:opacity .34s ease,transform .34s ease}
/* Inline, so the number and the word sit on one shared baseline at any size. */
.cs-card .cc-stat-line{display:block;text-wrap:balance}
.cs-card .cc-stat-value,.cs-card .cc-stat-label{display:inline}
.cs-card .cc-stat-value + .cc-stat-label{margin-left:.26em}
.cs-card .cc-img.has-stat:hover .cc-stat,.cs-card:focus-visible .cc-stat{opacity:1;transform:none}
.cs-card .cc-stat-value{font-family:var(--display);font-weight:700;font-size:clamp(1.8rem,3.6vw,2.7rem);line-height:1.05;letter-spacing:-.01em;color:var(--orange)}
.cs-card .cc-stat-label{font-family:var(--display);font-weight:500;font-size:clamp(1.55rem,3.1vw,2.3rem);line-height:1.05;color:var(--ink)}

/*
 * On touch the card is just the card.
 *
 * This block used to do the opposite: with no hover to reveal the stat, it
 * pinned the wash and the figure permanently on, so a phone showed every card
 * already in its hovered state. Asked for the other way round — a phone should
 * show the photograph, not a hover effect nobody triggered.
 *
 * The consequence is deliberate and worth knowing: the stat is now a pointer
 * affordance only, so "287+ Joinees" is not shown on a phone at all. If it
 * should be readable there, it wants to be part of the card — a line under the
 * title — rather than an overlay, because there is no gesture on touch that
 * corresponds to hovering.
 *
 * Keyboard is kept: :focus-visible still reveals it, and the smaller type
 * below is what it is drawn at when a narrow window does.
 */
@media(hover:none),(max-width:640px){
  .cs-card .cc-stat-value{font-size:clamp(1.4rem,5.4vw,1.9rem)}
  .cs-card .cc-stat-label{font-size:clamp(1.2rem,4.6vw,1.65rem)}
}
/*
 * Mobile: no hover animation on the card.
 *
 * Width, not hover capability — a phone already lands in the (hover:none) block
 * above, and this is about the size the card is being read at. The lift and its
 * shadow are a pointer affordance; at this width the card is tapped, and a
 * transform that fires on tap reads as the page moving under the finger.
 * Desktop is untouched.
 */
@media(max-width:640px){
  .cs-card{transition:none}
  .cs-card:hover{transform:none;box-shadow:none;border-color:#ececec}
  .cs-card .cc-img.has-stat img,.cs-card .cc-img.has-stat svg{transition:none}
  .cs-card .cc-img.has-stat:hover img,.cs-card .cc-img.has-stat:hover svg,
  .cs-card:focus-visible .cc-img.has-stat img,.cs-card:focus-visible .cc-img.has-stat svg{transform:none}
}

@media(prefers-reduced-motion:reduce){
  .cf-read,.cf-read .arw{transition:none}
  .cs-feature:hover .cf-read .arw,.cs-feature:focus-visible .cf-read .arw{transform:none}
  .cs-card .cc-img.has-stat::after,.cs-card .cc-stat,
  .cs-card .cc-img.has-stat img,.cs-card .cc-img.has-stat svg{transition:none}
  .cs-card .cc-stat{transform:none}
  .cs-card .cc-img.has-stat:hover img,.cs-card .cc-img.has-stat:hover svg{transform:none}
}
.cs-card .cc-body{padding:22px 22px 24px;display:flex;flex-direction:column;gap:14px}
/* The chip row. align-self keeps a lone chip hugging its label rather than
   stretching across the column, as it did when it was the body's own child. */
.cs-card .cc-tags{display:flex;flex-wrap:wrap;gap:8px;align-self:flex-start}
.cs-card .cc-body .tag{align-self:flex-start}
.cs-card h3{font-family:var(--display);font-size:var(--fs-h3,1.35rem);line-height:1.25;font-weight:700;margin:0;color:#0a0a0a}
#csSentinel{grid-column:1/-1;height:1px}
.cs-end{grid-column:1/-1;text-align:center;padding:36px 0 4px;font-family:var(--mono);font-size:.72rem;letter-spacing:calc(.056em * var(--mono-track, 1));text-transform:uppercase;color:var(--grey)}
.cs-empty{padding:60px 0;text-align:center;color:var(--grey-deep);font-size:1.05rem;font-family:var(--display)}

@media(max-width:900px){
  .cs-feature{grid-template-columns:1fr;min-height:0}
  .cf-image{min-height:320px;order:-1}
  .cf-text{padding:clamp(28px,6vw,44px)}
}
@media(max-width:640px){ .cs-grid{grid-template-columns:1fr} }


/* ============================================================
   TERM ARCHIVES (Role, and any story-side taxonomy)
   The stories feed has no hero on a term page, so the controls
   carry the title block instead.
   ============================================================ */
.cs-termhead{padding:0 0 6px}
.cs-termhead .eyebrow{margin-bottom:14px}
.cs-termtitle{
  font-family:var(--display);font-weight:700;
  font-size:clamp(2rem,4vw,3rem);letter-spacing:-.01em;
  margin:0 0 18px;max-width:20ch;line-height:1.06;
}
.cs-termintro{max-width:62ch;margin:0 0 26px;color:var(--grey-deep);font-size:1.02rem;line-height:1.65}
