/* Case study pages: the live case-study format, restyled in Clear Authority v2. Shared by cs-*.html */
.cs-hero { padding: 56px 0 40px; }
.cx-back { display: inline-flex; align-items: center; min-height: 44px; color: var(--ink-3); text-decoration: none; font-weight: 500; font-size: .9375rem; margin-bottom: 20px; }
.cx-back:hover { color: var(--brick); }
.cs-top { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, .65fr); gap: 56px; align-items: center; }
.cs-kicker { color: var(--brick); font-weight: 600; font-size: .9375rem; margin-bottom: 18px; }
.cs-top h1 { font-size: clamp(2.3rem, 4.4vw, 3.9rem); line-height: 1.05; }
.cs-top h1 .name { display: block; color: var(--ink-3); font-size: .5em; letter-spacing: -.02em; margin-bottom: 10px; }
.cs-top .sub { margin-top: 22px; color: var(--ink-2); font-size: 1.1875rem; max-width: 56ch; }
.cx-by { display: flex; align-items: center; gap: 12px; margin-top: 28px; font-size: .9375rem; color: var(--ink-3); }
.cx-by img { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; }
.cx-by b { display: block; color: var(--ink); font-weight: 600; }
.cs-portrait img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--radius); }

.cx-stats { display: grid; grid-template-columns: repeat(var(--n, 4), minmax(0, 1fr)); border-top: 2px solid var(--ink); margin-top: 8px; }
.cx-stat { padding: 26px 24px 8px 0; }
.cx-stat + .cx-stat { padding-left: 24px; border-left: 1px solid var(--line); }
.cx-stat .v { color: var(--brick); font-weight: 600; font-size: clamp(2rem, 3.6vw, 3rem); line-height: 1; letter-spacing: -.04em; white-space: nowrap; }
.cx-stat .v .arrow { color: var(--coral); margin: 0 .08em; }
.cx-stat .k { margin-top: 10px; color: var(--ink-3); font-size: .9375rem; line-height: 1.4; }

.cx-snap { margin: 48px 0 0; background: var(--warm); border-radius: var(--radius); padding: 28px 32px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px 32px; }
.cx-snap dt { font-weight: 600; font-size: .875rem; color: var(--brick); margin-bottom: 6px; }
.cx-snap dd { margin: 0; color: var(--ink-2); font-size: .9688rem; line-height: 1.5; }

.cx-body { display: grid; grid-template-columns: 230px minmax(0, 1fr); gap: 72px; padding: 72px 0 40px; }
.cx-toc { position: sticky; top: 100px; align-self: start; display: flex; flex-direction: column; border-left: 2px solid var(--line); }
.cx-toc span { font-weight: 600; font-size: .875rem; color: var(--ink); padding: 0 0 10px 18px; }
.cx-toc a { display: flex; align-items: center; min-height: 44px; padding: 4px 0 4px 18px; margin-left: -2px; border-left: 2px solid transparent; color: var(--ink-3); text-decoration: none; font-size: .9375rem; line-height: 1.35; }
.cx-toc a:hover { color: var(--brick); border-left-color: var(--coral); }
.cx-art { max-width: 740px; }
.cx-ch { scroll-margin-top: 96px; }
.cx-ch + .cx-ch { margin-top: 64px; padding-top: 64px; border-top: 1px solid var(--line); }
.cx-ch h2 { font-size: clamp(1.75rem, 2.6vw, 2.25rem); line-height: 1.12; letter-spacing: -.03em; margin-bottom: 20px; }
.cx-ch p { color: var(--ink-2); margin-bottom: 18px; }
.cx-ch p b { color: var(--ink); font-weight: 600; }
.cx-ch .bl { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 12px; }
.cx-ch .bl li { position: relative; padding-left: 26px; color: var(--ink-2); }
.cx-ch .bl li::before { content: ""; position: absolute; left: 0; top: .62em; width: 10px; height: 10px; border-radius: 50%; background: var(--coral); }
.cx-ch .bl b { color: var(--ink); font-weight: 600; }
.cx-ch blockquote { margin: 28px 0; padding: 4px 0 4px 24px; border-left: 4px solid var(--coral); font-size: 1.25rem; line-height: 1.5; color: var(--ink); font-weight: 500; }

/* Proof: the live carousel, shown as a static gallery of framed screenshots with captions below */
.cs-gallery { margin-top: 36px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 24px; }
.cs-gallery figure { margin: 0; }
.cs-gallery figure:first-child { grid-column: 1 / -1; }
.cs-gallery .frame { background: var(--warm); }
.cs-gallery .frame img { aspect-ratio: 4 / 3; object-fit: contain; }
.cs-gallery figure:first-child .frame img { aspect-ratio: auto; }
.cs-gallery figcaption { margin-top: 10px; color: var(--ink-3); font-size: .9063rem; line-height: 1.45; }

.cx-tl { list-style: none; margin: 8px 0 0; padding: 0; position: relative; }
.cx-tl::before { content: ""; position: absolute; left: 7px; top: 10px; bottom: 10px; width: 2px; background: var(--line); }
.cx-tl li { position: relative; display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 20px; padding: 12px 0 12px 36px; }
.cx-tl li::before { content: ""; position: absolute; left: 0; top: 19px; width: 16px; height: 16px; border-radius: 50%; background: #fff; border: 3px solid var(--brick); }
.cx-tl .d { font-weight: 600; color: var(--brick); }
.cx-tl .t { color: var(--ink-2); }

.cx-fix { margin-top: 24px; display: grid; gap: 14px; }
.cx-fix + p { margin-top: 32px; }
.cx-fix .row { display: grid; grid-template-columns: 1fr 1fr; border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; }
.cx-fix .row > div { padding: 20px 22px; color: var(--ink-2); font-size: 1rem; line-height: 1.55; }
.cx-fix .row > div:first-child { background: var(--warm); }
.cx-fix small { display: block; font-weight: 600; font-size: .8125rem; color: var(--brick); margin-bottom: 6px; }

.cx-next { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 16px; margin-top: 72px; padding-top: 32px; border-top: 2px solid var(--ink); }
.cx-next .nx { display: inline-flex; align-items: center; gap: 14px; min-height: 44px; text-decoration: none; font-weight: 600; font-size: 1.25rem; }
.cx-next .nx small { display: block; font-weight: 500; font-size: .875rem; color: var(--ink-3); }
.cx-next .nx:hover { color: var(--brick); }
.cx-next .link { text-decoration: none; color: var(--ink-3); }

.cs-cta { background: var(--brick); color: #fff; padding: 96px 0; margin-top: 48px; }
.cs-cta .inner { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, .6fr); gap: 48px; align-items: end; }
.cs-cta h2 { color: #fff; }
.cs-cta .u { text-decoration-color: var(--coral); }
.cs-cta p { color: #f1dcd6; font-size: 1.1875rem; margin-top: 18px; max-width: 46ch; }
.cs-cta .emailed { margin-top: 18px; font-size: .9375rem; color: #e6c9c1; }
.cs-cta .act { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; }
.cs-cta .act small { color: #e6c9c1; font-size: .9375rem; }

@media (max-width: 960px) {
  .cx-body { grid-template-columns: 1fr; gap: 0; padding-top: 48px; }
  .cx-toc { display: none; }
  .cx-snap { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cs-cta .inner { grid-template-columns: 1fr; align-items: start; }
}
@media (max-width: 720px) {
  .wrap { padding: 0 20px; }
  .cs-hero { padding: 28px 0 28px; }
  .cs-top { grid-template-columns: 1fr; gap: 28px; }
  .cs-portrait { order: -1; max-width: 220px; }
  .cs-portrait img { aspect-ratio: 1; }
  .cx-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cx-stat, .cx-stat + .cx-stat { padding: 20px 12px 8px 0; border-left: 0; }
  .cx-stat:nth-child(even) { padding-left: 16px; border-left: 1px solid var(--line); }
  .cx-stat .v { font-size: 1.9rem; white-space: normal; }
  .cx-snap { grid-template-columns: 1fr; padding: 22px; margin-top: 32px; }
  .cs-gallery { grid-template-columns: 1fr; }
  .cx-ch + .cx-ch { margin-top: 44px; padding-top: 44px; }
  .cx-tl li { grid-template-columns: 1fr; gap: 2px; }
  .cx-fix .row { grid-template-columns: 1fr; }
  .cs-cta { padding: 64px 0; }
}
