/* Case study detail layout (applied by scripts/case_study_layout.py to every page in content/case-studies.json).
   Type scale = article template (.at-h1 / .at-prose h2 / h3). CTA banner reuses .at-cta from article.css, just bigger. */
main.csd{ position:relative; z-index:0; font-family:inherit; color:inherit; width:auto; max-width:none; margin:0; padding:0; }
.csd-shell{ max-width:1200px; margin:0 auto; padding:0 24px; }
.csd-grid{ display:grid; grid-template-columns:minmax(0,1fr) 280px; gap:0 64px; padding:64px 0 96px; }
.csd-content{ min-width:0; max-width:820px; }
.csd #document h1{ max-width:none; width:100%; margin:0 0 40px; color:var(--fg); font-family:var(--disp); font-weight:600; font-size:clamp(2rem,4vw,2.75rem); line-height:1.08; letter-spacing:-.026em; text-wrap:balance; overflow-wrap:break-word; }
.csd #document h1 br{ display:none; }
.csd #document h2{ max-width:none; text-wrap:balance; overflow-wrap:break-word; }
.csd #document > :first-child{ margin-top:0; }
.csd #document h1.has-hero-evidence{ margin-bottom:0; }
.csd #document h2{ margin:56px 0 16px; padding-top:0; border-top:0; color:var(--fg); font-family:var(--disp); font-weight:600; font-size:28px; line-height:1.2; letter-spacing:-.018em; }
.csd #document h3{ margin:32px 0 12px; color:var(--fg); font-family:var(--disp); font-weight:600; font-size:20px; line-height:1.3; letter-spacing:-.01em; }
.csd-aside{ position:relative; }
.csd-float{ position:sticky; top:calc(var(--hdr-h,116px) + 24px); padding:24px; border-radius:16px; background:#fff; border:1px solid rgba(0,0,0,.08); box-shadow:0 1px 2px rgba(0,0,0,.04); color:var(--fg); overflow:hidden; }
.csd-float-title{ margin:0; color:var(--fg); font-family:var(--disp); font-weight:600; font-size:19px; line-height:1.25; letter-spacing:-.012em; }
.csd-float-sub{ margin:8px 0 18px; color:var(--muted); font-size:14px; line-height:1.5; }
.csd-float .ds-btn{ width:100%; text-decoration:none; }
.csd-cta{ padding:64px 0; }
.csd-cta .at-cta{ margin:0; padding:64px 56px; min-height:300px; border-radius:20px; }
.csd-cta .at-cta .at-cta-title{ font-size:clamp(28px,3.4vw,40px); line-height:1.12; letter-spacing:-.022em; }
.csd-cta .at-cta .at-cta-sub{ margin-top:14px; font-size:17px; }
.csd-cta .at-cta .at-cta-btn{ margin-top:28px; }
.csd-cta .at-cta-mark{ width:420px; right:-30px; }
@media (max-width:1000px){
  .csd-grid{ grid-template-columns:minmax(0,1fr); padding:40px 0 64px; }
  .csd-aside{ display:none; }
}
@media (max-width:680px){
  .csd-shell{ padding:0 18px; }
  .csd #document h2{ font-size:24px; margin-top:44px; }
  .csd-cta{ padding:40px 0; }
  .csd-cta .at-cta{ padding:36px 22px; min-height:0; }
  .csd-cta .at-cta-mark{ width:240px; right:-90px; } .csd-cta .at-cta-mark path{ stroke-opacity:.1; }
}
/* Decorative calendar in the sticky box: top/left edges visible, clipped at the right card edge, fades out at the bottom. */
.csd-float{ position:sticky; top:calc(var(--hdr-h,116px) + 24px); padding:24px; border-radius:16px; background:#fff; border:1px solid rgba(0,0,0,.08); box-shadow:0 1px 2px rgba(0,0,0,.04); color:var(--fg); overflow:hidden; }
.cal{ width:372px; height:196px; margin:-4px -120px 6px -4px; border:1px solid rgba(0,0,0,.1); border-right:0; border-radius:12px 0 0 0; background:#fff; font:500 9px/1.2 var(--ui,system-ui),system-ui,sans-serif; color:#5f6368; overflow:hidden;
  -webkit-mask-image:linear-gradient(#000 45%,transparent); mask-image:linear-gradient(#000 45%,transparent); user-select:none; }
.cal-top{ display:flex; justify-content:space-between; align-items:center; padding:9px 12px; border-bottom:1px solid rgba(0,0,0,.08); }
.cal-name{ color:#3c4043; font-size:12px; }
.cal-mo{ color:#3c4043; font-size:10.5px; margin-right:6px; } .cal-ar{ margin-left:8px; color:#70757a; letter-spacing:6px; }
.cal-body{ display:grid; grid-template-columns:34px repeat(4,1fr); }
.cal-times{ display:flex; flex-direction:column; padding-top:0; }
.cal-times b{ height:34px; display:flex; align-items:flex-end; padding:0 0 4px 3px; font-size:7px; font-weight:500; color:#70757a; }
.cal-times span{ height:26px; padding:2px 5px 0 0; text-align:right; font-size:7.5px; color:#70757a; }
.cal-col{ border-left:1px solid rgba(0,0,0,.08); }
.cal-col > b{ display:flex; flex-direction:column; align-items:center; height:34px; justify-content:center; font-size:7.5px; font-weight:500; color:#70757a; border-bottom:1px solid rgba(0,0,0,.08); }
.cal-col > b span{ font-size:14px; color:#3c4043; line-height:1.1; }
.cal-ev{ position:relative; height:182px; background:repeating-linear-gradient(transparent 0 25px,rgba(0,0,0,.07) 25px 26px); }
.cal-ev i{ position:absolute; left:3px; right:3px; padding:1.5px 5px; border-radius:4px; line-height:1.15; font-style:normal; white-space:nowrap; overflow:hidden; font-size:8px; }
.cal-ev em{ font-style:normal; opacity:.65; font-size:7px; margin-left:2px; }
.k-s{ background:#d3e3fd; color:#174ea6; }
.k-p{ background:#e9ddfb; color:#5b2c9f; }
.k-m{ background:#d4ecda; color:#1e6b34; }
.k-g{ background:#f1f3f4; color:#5f6368; }
/* Second button in the dark CTA (case studies only). Cal Sans for every headline in the layout. */
.csd-cta-actions{ display:flex; flex-wrap:wrap; gap:10px; margin-top:28px; }
.csd-cta .at-cta .csd-cta-actions .at-cta-btn{ margin-top:0; }
.csd-cta .csd-cta-more{ background:transparent; color:#fafafa; border-color:rgba(255,255,255,.18); box-shadow:none; text-decoration:none; }
.csd-cta .csd-cta-more:hover{ background:rgba(255,255,255,.06); border-color:rgba(255,255,255,.28); }
.csd-float-title{ font-family:"CS Display","CS UI",ui-sans-serif,system-ui,sans-serif !important; }
@media (max-width:680px){ .csd-cta-actions{ flex-direction:column; align-items:stretch; } .csd-cta-actions .ds-btn{ width:100%; } }
