/* Customer story detail pages. Loaded after stories-pro.css (evidence labels, section heads,
   tokens) and features/fp.css (dark hero shell, 100px section rhythm). */

/* ------------------------------ hero ------------------------------------ */
.sd-hx::before { display: none; }
.sd-hx .hero__h { max-width: 16ch; }
.sd-crumb { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 18px; font-size: 14px; color: rgba(255, 255, 255, 0.55); }
.sd-crumb a { color: rgba(255, 255, 255, 0.75); transition: color 0.2s ease; }
.sd-crumb a:hover { color: #fff; }
.sd-crumb [aria-current] { color: #fff; }
.sd-hx__k { padding: 7px 16px; background: rgba(255, 255, 255, 0.08); color: #fff; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12); }
.sd-meta { display: flex; flex-wrap: wrap; gap: 8px; margin: 24px 0 0; padding: 0; list-style: none; }
.sd-meta li { padding: 6px 13px; border-radius: 999px; background: rgba(255, 255, 255, 0.06); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12); font-size: 13.5px; color: rgba(255, 255, 255, 0.82); }
.sd-hx__art { display: grid; align-items: center; min-height: 0; }
.sd-kpis { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; width: 100%; max-width: 560px; justify-self: end; margin: 0; padding: 10px; border-radius: 26px; list-style: none; box-shadow: 0 40px 80px -40px rgba(0, 0, 0, 0.7); }
.sd-kpis li { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: 22px; border-radius: 18px; background: #f6f5fa; }
.sd-kpis li.is-wide { grid-column: 1 / -1; }
.sd-kpis b { font-family: var(--display); font-size: clamp(36px, 3.4vw, 48px); font-weight: 400; line-height: 1.05; letter-spacing: -0.045em; color: var(--cs-deep); font-variant-numeric: tabular-nums; }
.sd-kpis span:not(.cs-ev) { font-size: 14.5px; line-height: 1.4; color: var(--ink-2); }
.sd-kpis .cs-ev { margin-top: 8px; }
@media (max-width: 1100px) { .sd-kpis { max-width: none; justify-self: stretch; } }
@media (max-width: 760px) { .sd-kpis { padding: 6px; border-radius: 22px; } .sd-kpis li { padding: 18px; } }
@media (max-width: 420px) { .sd-kpis { grid-template-columns: minmax(0, 1fr); } }

/* ------------------------- the business question ------------------------ */
.sd-flows { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 56px; }
.sd-flow { padding: 32px; border-radius: 30px; background: linear-gradient(160deg, #f4f1ff 0%, #f6f5fa 46%, #f6f5fa 100%); }
.sd-flow--after { background: #1c1b22; }
.sd-flow__tag { display: inline-flex; padding: 5px 12px; border-radius: 999px; background: #fff; font-size: 12.5px; font-weight: 600; letter-spacing: 0.05em; color: #68686f; }
.sd-flow--after .sd-flow__tag { background: var(--brand); color: #fff; }
.sd-flow h3 { margin-top: 18px; font-size: clamp(26px, 2.4vw, 34px); line-height: 1.1; letter-spacing: -0.035em; }
.sd-flow--after h3 { color: #fff; }
.sd-steps { margin: 22px 0 0; padding: 0; list-style: none; }
.sd-steps li { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 16px; padding: 18px 0; border-top: 1px solid rgba(36, 36, 38, 0.08); }
.sd-flow--after .sd-steps li { border-color: rgba(255, 255, 255, 0.1); }
.sd-step__n { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: #fff; font-size: 13px; font-weight: 600; color: var(--cs-ink); font-variant-numeric: tabular-nums; }
.sd-flow--after .sd-step__n { background: rgba(255, 255, 255, 0.1); color: #fff; }
.sd-steps h4 { margin: 8px 0 0; font-family: var(--display); font-size: 18px; font-weight: 500; line-height: 1.35; letter-spacing: -0.015em; color: var(--cs-ink); }
.sd-flow--after .sd-steps h4 { color: #fff; }
.sd-steps p { margin-top: 6px; font-size: 15.5px; line-height: 1.55; color: var(--ink-2); }
.sd-flow--after .sd-steps p { color: rgba(255, 255, 255, 0.66); }
@media (max-width: 900px) { .sd-flows { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 760px) { .sd-flow { padding: 22px 20px; border-radius: 24px; } .sd-steps li { grid-template-columns: 36px minmax(0, 1fr); gap: 12px; } .sd-step__n { width: 36px; height: 36px; } }

/* ------------------------- merchant perspective ------------------------- */
.sd-mp__in { display: grid; grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); gap: 40px clamp(40px, 6vw, 96px); align-items: center; }
.sd-mp__copy { display: flex; flex-direction: column; align-items: flex-start; }
.sd-mp__copy h2 { margin-top: 20px; font-size: clamp(34px, 3.8vw, 54px); line-height: 1.08; letter-spacing: -0.04em; text-wrap: balance; }
.sd-mp__copy > p:not(.nr__pill) { margin-top: 16px; max-width: 46ch; font-size: 17px; line-height: 1.55; color: var(--ink-2); }
.sd-pull { position: relative; margin: 0; padding: clamp(28px, 3.4vw, 44px); border-radius: 30px; background: linear-gradient(160deg, #f4f1ff 0%, #f6f5fa 50%, #f6f5fa 100%); }
.sd-pull__mark { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 16px; background: var(--brand); color: #fff; }
.sd-pull__mark svg { width: 24px; height: 24px; }
.sd-pull blockquote { margin: 24px 0 0; font-family: var(--display); font-size: clamp(22px, 2vw, 28px); line-height: 1.35; letter-spacing: -0.02em; color: var(--cs-ink); text-wrap: pretty; }
.sd-pull figcaption, .sd-rev figcaption { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 24px; margin-top: 28px; padding-top: 20px; border-top: 1px solid rgba(36, 36, 38, 0.08); }
.sd-pull figcaption > span, .sd-rev figcaption > span { display: flex; flex-direction: column; gap: 3px; }
.sd-pull figcaption b, .sd-rev figcaption b { font-size: 16px; font-weight: 500; color: var(--cs-ink); }
.sd-pull figcaption em, .sd-rev figcaption em { font-style: normal; font-size: 14px; color: #68686f; }
.sd-link { display: inline-flex; align-items: center; gap: 10px; font-size: 15.5px; font-weight: 500; color: var(--cs-ink); }
.sd-link i { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; background: #fff; transition: background 0.25s ease, color 0.25s ease; }
.sd-link svg { width: 15px; height: 15px; }
.sd-link:hover i { background: var(--brand); color: #fff; }
@media (max-width: 900px) { .sd-mp__in { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 760px) { .sd-pull { border-radius: 24px; } }

/* --------------------------- observed evidence -------------------------- */
.sd-ob__grid { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: 16px; margin-top: 56px; }
.sd-big { display: flex; flex-direction: column; align-items: flex-start; padding: 32px; border-radius: 30px; background: #1c1b22; }
.sd-big__n { font-family: var(--display); font-size: clamp(56px, 6.4vw, 92px); line-height: 1; letter-spacing: -0.05em; color: #fff; font-variant-numeric: tabular-nums; }
.sd-big__c { margin: 12px 0 18px; font-size: 17px; color: rgba(255, 255, 255, 0.72); }
.sd-big__note { margin-top: auto; padding-top: 28px; font-size: 14.5px; line-height: 1.55; color: rgba(255, 255, 255, 0.55); }
.sd-chart { padding: 32px; border-radius: 30px; background: linear-gradient(160deg, #f4f1ff 0%, #f6f5fa 46%, #f6f5fa 100%); }
.sd-chart h3 { font-size: clamp(22px, 2vw, 28px); line-height: 1.15; letter-spacing: -0.03em; }
.sd-bars { display: grid; gap: 12px; margin: 24px 0 0; padding: 0; list-style: none; }
.sd-bars li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px 16px; padding: 18px 20px; border-radius: 18px; background: #fff; }
.sd-bars span { font-size: 15.5px; color: var(--cs-ink); }
.sd-bars b { font-family: var(--display); font-size: 24px; font-weight: 400; letter-spacing: -0.03em; color: var(--cs-deep); font-variant-numeric: tabular-nums; }
.sd-bars i { grid-column: 1 / -1; position: relative; height: 10px; border-radius: 99px; background: #eceaf3; overflow: hidden; }
.sd-bars i::after { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--w); border-radius: inherit; background: var(--brand); transform: scaleX(0); transform-origin: 0 50%; transition: transform 1.1s cubic-bezier(0.22, 1, 0.36, 1); }
.sd-bars li:nth-child(2) i::after { transition-delay: 0.1s; } .sd-bars li:nth-child(3) i::after { transition-delay: 0.2s; } .sd-bars li:nth-child(4) i::after { transition-delay: 0.3s; }
.sd-bars.is-in-view i::after { transform: none; }
.sd-tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 24px 0 0; padding: 0; list-style: none; }
.sd-tiles li, .sd-formula li { display: flex; flex-direction: column; gap: 8px; padding: 20px; border-radius: 18px; background: #fff; min-width: 0; }
.sd-tiles small, .sd-formula small { font-size: 12.5px; font-weight: 600; letter-spacing: 0.05em; text-transform: uppercase; color: #68686f; }
.sd-tiles b, .sd-formula b { font-family: var(--display); font-size: clamp(24px, 2.2vw, 32px); font-weight: 400; line-height: 1.15; letter-spacing: -0.035em; color: var(--cs-deep); overflow-wrap: anywhere; }
.sd-tiles span, .sd-formula span { font-size: 14.5px; line-height: 1.45; color: var(--ink-2); }
.sd-chart__note { margin-top: 20px; font-size: 14.5px; line-height: 1.55; color: var(--ink-2); }
@media (max-width: 1100px) { .sd-ob__grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 760px) { .sd-big, .sd-chart { padding: 24px 20px; border-radius: 24px; } .sd-tiles { grid-template-columns: minmax(0, 1fr); } }

/* ------------------------ financial interpretation ---------------------- */
.sd-formula { display: grid; grid-template-columns: repeat(var(--n), minmax(0, 1fr)); gap: 10px; margin: 56px 0 0; padding: 10px; border-radius: 30px; list-style: none; background: linear-gradient(160deg, #f4f1ff 0%, #f6f5fa 46%, #f6f5fa 100%); }
.sd-formula li { position: relative; padding: 24px; }
.sd-formula li:last-child { background: #1c1b22; }
.sd-formula li:last-child small { color: rgba(255, 255, 255, 0.55); }
.sd-formula li:last-child b { color: #fff; }
.sd-formula li:last-child span { color: rgba(255, 255, 255, 0.66); }
.sd-cav { margin-top: 16px; padding: 24px 28px; border-radius: 22px; background: #fbf4e6; }
.sd-cav__k { font-size: 15px; font-weight: 600; color: #8f6418; }
.sd-cav p { margin-top: 0; max-width: 90ch; font-size: 15.5px; line-height: 1.6; color: #6b5226; }
.sd-src { margin-top: 18px; max-width: 100ch; font-size: 14px; line-height: 1.6; color: #68686f; }
.sd-src a { color: var(--cs-deep); text-decoration: underline; text-decoration-color: rgba(91, 47, 214, 0.35); text-underline-offset: 3px; }
.sd-src a:hover { text-decoration-color: currentColor; }
@media (max-width: 900px) { .sd-formula { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 760px) { .sd-formula { grid-template-columns: minmax(0, 1fr); padding: 6px; border-radius: 24px; } .sd-cav { padding: 20px; } }

/* ------------------------------- takeaway ------------------------------- */
.sd-tk__grid { display: grid; grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); gap: 16px clamp(32px, 5vw, 72px); align-items: start; margin-top: 56px; }
.sd-tk__card { display: flex; flex-direction: column; align-items: flex-start; padding: 32px; border-radius: 30px; background: #1c1b22; }
.sd-tk__card h3 { margin-top: 20px; font-size: clamp(28px, 2.6vw, 38px); line-height: 1.1; letter-spacing: -0.035em; color: #fff; }
.sd-tk__card p { margin-top: 12px; font-size: 16px; line-height: 1.6; color: rgba(255, 255, 255, 0.72); }
@media (min-width: 901px) { .sd-tk__card { position: sticky; top: 120px; } }
.sd-tk__rows { margin: 0; padding: 0; list-style: none; }
.sd-tk__rows li { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 20px; padding: 28px 0; border-top: 1px solid #ececf1; }
.sd-tk__rows li:last-child { border-bottom: 1px solid #ececf1; }
.sd-tk__rows i { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 14px; background: #efe9ff; color: #6a35e8; }
.sd-tk__rows svg { width: 20px; height: 20px; stroke-width: 2.4; }
.sd-tk__rows h4 { margin: 0; font-family: var(--display); font-size: clamp(22px, 2vw, 28px); font-weight: 400; line-height: 1.15; letter-spacing: -0.03em; color: var(--cs-ink); }
.sd-tk__rows p { margin-top: 8px; font-size: 16px; line-height: 1.55; color: var(--ink-2); }
@media (max-width: 900px) { .sd-tk__grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 760px) { .sd-tk__card { padding: 24px 20px; border-radius: 24px; } .sd-tk__rows li { grid-template-columns: 38px minmax(0, 1fr); gap: 16px; padding: 22px 0; } .sd-tk__rows i { width: 38px; height: 38px; border-radius: 12px; } }

/* ----------------------------- related review --------------------------- */
.sd-rev { margin: 56px 0 0; padding: clamp(28px, 3.4vw, 48px); border-radius: 30px; background: linear-gradient(160deg, #f4f1ff 0%, #f6f5fa 46%, #f6f5fa 100%); }
.sd-rev__k { display: inline-flex; padding: 5px 12px; border-radius: 999px; background: #fff; font-size: 13px; font-weight: 500; color: var(--cs-deep); }
.sd-rev blockquote { margin: 22px 0 0; max-width: 60ch; font-family: var(--display); font-size: clamp(20px, 1.9vw, 26px); line-height: 1.45; letter-spacing: -0.02em; color: var(--cs-ink); text-wrap: pretty; }
.sd-rev__note { margin-top: 16px; font-size: 14px; line-height: 1.55; color: #68686f; }
@media (max-width: 760px) { .sd-rev { border-radius: 24px; } }

/* ------------------------- closing call to action ----------------------- */
/* ends like home: the .end lavender gradient running into the footer */
.sd-page main > .sd-end { padding: 30px 0 100px !important; background: linear-gradient(180deg, #fff 0%, #ece7ff 30%, #d8cdff 72%, #fff 100%); }
.sd-end__in { display: flex; flex-direction: column; align-items: center; text-align: center; }
.sd-end h2 { margin-top: 20px; max-width: 18ch; font-size: clamp(34px, 3.8vw, 54px); line-height: 1.08; letter-spacing: -0.04em; text-wrap: balance; }
.sd-end__in > p { margin-top: 16px; max-width: 60ch; font-size: 17px; line-height: 1.55; color: var(--ink-2); }
.sd-end .hero__btns { justify-content: center; margin-top: 32px; }
@media (max-width: 760px) { .sd-page main > .sd-end { padding-bottom: 72px !important; } }
/* the closing lavender band starts on the same rhythm as every other section (its wash fades in from white) */
.sd-page main > .sd-end { padding-top: 0 !important; }
