/* Case Studies template (cs2-*). Paste into the CMS template → Page settings → Custom code → Head.
   Full-fidelity layer over the native basic styles. Fonts inherit the site. */
.cs2-container { max-width: 1240px; margin: 0 auto; padding-left: max(40px, env(safe-area-inset-left, 0px)); padding-right: max(40px, env(safe-area-inset-right, 0px)); }
@media (max-width: 767px) { .cs2-container { padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); } }
.cs2-main a:focus-visible { outline: 2px solid #1257E8; outline-offset: 3px; border-radius: 6px; }
.cs2-label { font-family: 'Geist Mono', ui-monospace, monospace; font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: #35353C; }

/* Head + hero */
.cs2-head { display: grid; gap: clamp(14px, 1.6vw, 20px); padding-block: clamp(28px, 4vw, 56px) clamp(24px, 3vw, 36px); }
.cs2-back { display: inline-flex; align-items: center; gap: 8px; width: max-content; font-size: 14px; color: #35353C; text-decoration: none; padding-bottom: 4px; border-bottom: 1px solid #E2E2E6; margin-bottom: clamp(16px, 2.4vw, 32px); transition: border-color .2s, color .2s; }
.cs2-back:hover { color: #0B0B0C; border-color: #0B0B0C; text-decoration: none; }
.cs2-client { margin: 0; font-size: 15px; font-weight: 500; color: #35353C; }
.cs2-title { margin: 0; font-size: clamp(36px, 5.4vw, 72px); font-weight: 500; letter-spacing: -0.045em; line-height: 1.02; max-width: 17ch; text-wrap: balance; }
.cs2-hero { position: relative; border-radius: 14px; overflow: hidden; background: #F3F3F5; aspect-ratio: 16 / 9; max-width: 100%; }
.cs2-hero-img, .cs2-hero-video, .cs2-hero-video-wrap { position: absolute; inset: 0; width: 100%; height: 100%; }
.cs2-hero-img, .cs2-hero-video { object-fit: cover; }
.cs2-hero-video-wrap { z-index: 1; }
.cs2-hero-typo { position: absolute; inset: 0; background: #041C2C; display: grid; align-content: end; padding: clamp(20px, 3vw, 40px); }
.cs2-hero-typo::before { content: ""; position: absolute; inset: 0; background: repeating-linear-gradient(0deg, rgba(224,214,196,.07) 0 1px, transparent 1px 40px), repeating-linear-gradient(90deg, rgba(224,214,196,.07) 0 1px, transparent 1px 40px); }
.cs2-hero-typo-name { position: relative; font-size: clamp(56px, 10vw, 150px); font-weight: 500; letter-spacing: -0.055em; line-height: .88; color: #E0D6C4; }

/* Facts */
.cs2-facts { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); padding-block: clamp(24px, 3vw, 36px); border-bottom: 1px solid #ECECEE; }
.cs2-fact { display: grid; gap: 8px; align-content: start; min-width: 0; }
.cs2-fact-val { font-size: 15px; font-weight: 500; }
.cs2-fact-link { font-size: 15px; font-weight: 500; color: #0B0B0C; text-decoration: underline; text-decoration-color: #E2E2E6; text-underline-offset: 4px; transition: text-decoration-color .2s; }
.cs2-fact-link:hover { text-decoration-color: #0B0B0C; }
.cs2-pills { display: flex; flex-wrap: wrap; gap: 6px; }
.cs2-pill { font-size: 13px; padding: 5px 12px; border-radius: 999px; background: #F3F3F5; color: #35353C; }

/* Intro + stats */
.cs2-intro { display: grid; gap: 18px; max-width: 860px; padding-block: clamp(48px, 6vw, 88px) clamp(32px, 4vw, 56px); }
.cs2-intro-title { margin: 0; font-size: clamp(28px, 3.4vw, 46px); font-weight: 500; letter-spacing: -0.04em; line-height: 1.06; text-wrap: balance; }
.cs2-intro-text { margin: 0; font-size: clamp(17px, 1.4vw, 19px); line-height: 1.55; color: #35353C; max-width: 62ch; }
.cs2-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: clamp(14px, 1.4vw, 18px); padding-bottom: clamp(48px, 6vw, 80px); }
.cs2-stat { border-top: 1px solid #0B0B0C; padding-top: 18px; display: grid; gap: 8px; align-content: start; }
.cs2-stat-value { font-size: clamp(40px, 4.2vw, 56px); font-weight: 500; letter-spacing: -0.045em; line-height: 1; font-variant-numeric: tabular-nums; }
.cs2-stat-label { font-size: 15px; color: #35353C; max-width: 28ch; }

/* Story sections: label left, story right */
.cs2-sec { display: grid; gap: 16px clamp(24px, 4vw, 64px); padding-block: clamp(48px, 6vw, 96px); }
@media (min-width: 992px) { .cs2-sec { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } .cs2-story { grid-column: 2; } .cs2-sec-label { position: sticky; top: 100px; } }
.cs2-sec-label { align-self: start; justify-self: start; font-size: 13px; font-weight: 500; color: #0B0B0C; padding-bottom: 8px; border-bottom: 2px solid #0B0B0C; }
.cs2-story { display: grid; gap: 18px; min-width: 0; }
.cs2-sec-title { margin: 0; font-size: clamp(26px, 2.8vw, 38px); font-weight: 500; letter-spacing: -0.035em; line-height: 1.1; text-wrap: balance; }
.cs2-rich { font-size: 17px; line-height: 1.6; color: #35353C; }
.cs2-rich p { margin: 0 0 16px; max-width: 60ch; }
.cs2-rich p:last-child { margin-bottom: 0; }
.cs2-rich ul { margin: 0; padding: 0; list-style: none; border-top: 1px solid #ECECEE; }
.cs2-rich li { padding: 14px 0; border-bottom: 1px solid #ECECEE; }
.cs2-rich li strong { display: block; color: #0B0B0C; font-weight: 500; font-size: 17px; }

/* Media rhythm */
.cs2-media { display: grid; gap: clamp(14px, 1.4vw, 18px); }
.cs2-media + .cs2-media { margin-top: clamp(14px, 1.4vw, 18px); }
.cs2-media-wide { position: relative; border-radius: 14px; overflow: hidden; background: #F3F3F5; aspect-ratio: 16 / 9; max-width: 100%; }
.cs2-media-pair { display: grid; gap: clamp(14px, 1.4vw, 18px); grid-template-columns: 1fr; }
@media (min-width: 640px) { .cs2-media-pair { grid-template-columns: 1fr 1fr; } }
.cs2-media-cell { position: relative; border-radius: 14px; overflow: hidden; background: #F3F3F5; aspect-ratio: 4 / 5; max-width: 100%; }
.cs2-media-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1.1s cubic-bezier(.16,.84,.28,1); }
.cs2-media-wide:hover .cs2-media-img, .cs2-media-cell:hover .cs2-media-img { transform: scale(1.03); }

/* FAQ */
.cs2-faq { border-top: 1px solid #ECECEE; }
.cs2-faq-list { border-top: 1px solid #E2E2E6; }
.cs2-faq-list details { border-bottom: 1px solid #E2E2E6; }
.cs2-faq-list summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; gap: 16px; align-items: center; padding: 20px 0; font-size: clamp(17px, 1.5vw, 19px); font-weight: 500; letter-spacing: -0.015em; color: #0B0B0C; }
.cs2-faq-list summary::-webkit-details-marker { display: none; }
.cs2-pm { flex: 0 0 auto; width: 30px; height: 30px; border-radius: 50%; border: 1px solid #E2E2E6; position: relative; transition: background .25s, border-color .25s; }
.cs2-pm::before, .cs2-pm::after { content: ""; position: absolute; left: 50%; top: 50%; width: 11px; height: 2px; background: #0B0B0C; transform: translate(-50%, -50%); transition: transform .25s, background .25s; }
.cs2-pm::after { transform: translate(-50%, -50%) rotate(90deg); }
.cs2-faq-list details[open] .cs2-pm { background: #0B0B0C; border-color: #0B0B0C; }
.cs2-faq-list details[open] .cs2-pm::before, .cs2-faq-list details[open] .cs2-pm::after { background: #fff; }
.cs2-faq-list details[open] .cs2-pm::after { transform: translate(-50%, -50%) rotate(0); }
.cs2-faq-list details p { margin: 0; padding: 0 44px 22px 0; color: #35353C; font-size: 16px; line-height: 1.6; max-width: 64ch; }
.cs2-miglink { display: inline-flex; gap: 8px; margin-top: 8px; font-size: 15.5px; font-weight: 500; color: #1257E8; text-decoration: underline; text-decoration-color: rgba(18,87,232,.3); text-underline-offset: 4px; transition: text-decoration-color .2s; }
.cs2-miglink:hover { text-decoration-color: #1257E8; }

/* Details + related */
.cs2-details { border-top: 1px solid #ECECEE; padding-block: clamp(40px, 5vw, 64px); }
.cs2-drow { display: grid; grid-template-columns: minmax(120px, 1fr) minmax(0, 2fr); gap: 16px; padding: 14px 0; border-bottom: 1px solid #ECECEE; font-size: 15px; }
.cs2-drow .cs2-label { align-self: center; }
.cs2-related { display: grid; gap: 24px; padding-block: clamp(32px, 4vw, 56px) clamp(64px, 8vw, 110px); }
.cs2-related-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 16px; }
.cs2-related-title { margin: 0; font-size: clamp(26px, 2.8vw, 38px); font-weight: 500; letter-spacing: -0.035em; }
.cs2-related-all { font-size: 14.5px; padding: 10px 18px; border-radius: 999px; border: 1px solid #E2E2E6; color: #0B0B0C; text-decoration: none; transition: border-color .2s; }
.cs2-related-all:hover { border-color: #0B0B0C; text-decoration: none; }
.cs2-rel-items { display: grid; gap: clamp(14px, 1.4vw, 18px); grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); }
.cs2-rcard { display: grid; gap: 12px; align-content: start; color: inherit; text-decoration: none; min-width: 0; }
.cs2-rcard:hover { text-decoration: none; }
.cs2-rcard-media { position: relative; border-radius: 14px; overflow: hidden; background: #F3F3F5; aspect-ratio: 4 / 5; max-width: 100%; }
.cs2-rcard-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1.1s cubic-bezier(.16,.84,.28,1); }
.cs2-rcard:hover .cs2-rcard-img { transform: scale(1.04); }
.cs2-rcard-typo { position: absolute; inset: 0; background: #041C2C; color: #E0D6C4; display: grid; align-content: center; padding: 22px; font-size: 44px; font-weight: 500; letter-spacing: -0.045em; line-height: .95; }
.cs2-rcard-title { margin: 0; font-size: 21px; font-weight: 500; letter-spacing: -0.02em; color: #0B0B0C; }
.cs2-rcard-line { margin: -6px 0 0; color: #6A6A72; font-size: 15px; line-height: 1.45; }

@media (prefers-reduced-motion: reduce) { .cs2-main * { transition: none !important; animation: none !important; } }
