/* Shared case-study system: Global Personals (dating.html) and Highbucha (highbucha.html).
   Nov 22 (CJ: "maybe the dating and highbucha case study pages can be closer in design"). One type scale, one hero
   layout, one overview strip, numbered section labels, one heading color rule, one picker, one in-page link and one
   closing block. Loaded last on both pages; each page keeps only its own accent color and content. */

:is(.case-gp,.case-hb,.case-xm){
 --cs-h1:clamp(54px,6.6vw,100px);
 --cs-h2:clamp(40px,5vw,74px);
 --cs-lede:clamp(19px,1.65vw,24px);
}

/* Hero type */
:is(.case-gp,.case-hb,.case-xm) .case-page h1{font-size:var(--cs-h1);font-weight:480;line-height:.98;letter-spacing:-.065em;max-width:12ch;margin:0}
:is(.case-gp .gp-hero-intro,.case-hb .hb-hero-copy)>p:not(.gp-hero-eyebrow,.case-kicker){font-size:var(--cs-lede);line-height:1.5;letter-spacing:-.03em;max-width:33rem;margin:22px 0 0}
.case-gp .gp-hero-intro>.gp-hero-brand-copy{font-size:clamp(16px,1.2vw,18px);margin-top:12px;opacity:.82}

/* Section labels: "01 / Name", the same everywhere */
:is(.case-gp,.case-hb,.case-xm) .case-page :is(.case-kicker,.gp-hero-eyebrow){font-size:12px;font-weight:500;line-height:1.7;letter-spacing:.08em;text-transform:uppercase;margin:0 0 18px}
:is(.case-gp,.case-hb,.case-xm) [data-case-theme=light] .case-kicker{color:var(--case-accent)}
:is(.case-gp,.case-hb,.case-xm) [data-case-theme=dark] .case-kicker,.case-gp .gp-hero-eyebrow{color:color-mix(in srgb,currentColor 74%,transparent)}

/* Section headings: accent on white, white on color */
:is(.case-gp,.case-hb,.case-xm) .case-page .cs-title{font-size:var(--cs-h2);font-weight:450;line-height:1.02;letter-spacing:-.06em;max-width:15ch;margin:0}
:is(.case-gp,.case-hb,.case-xm) [data-case-theme=light] .cs-title{color:var(--case-accent)}
:is(.case-gp,.case-hb,.case-xm) [data-case-theme=dark] .cs-title{color:inherit}

/* Overview strip: Role / Scope / Client */
:is(.case-gp,.case-hb,.case-xm) .case-facts{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:clamp(24px,4vw,72px);padding-block:clamp(36px,4vw,60px);border-bottom:1px solid color-mix(in srgb,currentColor 12%,transparent)}
:is(.case-gp,.case-hb,.case-xm) .case-facts span{display:block;margin:0 0 12px;color:var(--case-accent);font-size:12px;font-weight:500;letter-spacing:.08em;text-transform:uppercase}
:is(.case-gp,.case-hb,.case-xm) .case-facts p{margin:0;font-size:clamp(17px,1.35vw,20px);line-height:1.45;letter-spacing:-.025em}
.case-gp .case-facts{padding-top:0;margin-bottom:clamp(48px,6vw,96px)}
@media(max-width:760px){
 :is(.case-gp,.case-hb,.case-xm) .case-facts{grid-template-columns:1fr;gap:22px}
}

/* In-page link: one pill, used for "Take a tour" and "Explore the brand" */
:is(.case-gp,.case-hb,.case-xm) .gp-scroll-link{
 position:relative;overflow:hidden;isolation:isolate;display:inline-flex;align-items:center;justify-content:space-between;
 gap:.85rem;width:fit-content;max-width:100%;min-height:50px;padding:.55rem .6rem .55rem 1.2rem;
 border:1px solid color-mix(in srgb,currentColor 35%,transparent);border-radius:99px;background:transparent;
 color:inherit;text-decoration:none;font:550 1rem/1.2 var(--sans,sans-serif);
}
:is(.case-gp,.case-hb,.case-xm) .gp-scroll-link span{display:grid;place-items:center;width:2rem;height:2rem;border-radius:50%;background:color-mix(in srgb,currentColor 10%,transparent);font-size:1.05rem}
:is(.case-gp,.case-hb,.case-xm) .gp-scroll-link:hover{border-color:currentColor}
:is(.case-gp,.case-hb,.case-xm) .gp-scroll-link:focus-visible{outline:2px solid currentColor;outline-offset:4px}
:is(.case-gp,.case-hb,.case-xm) .gp-scroll-link::after{
 content:"";position:absolute;inset:-1px;z-index:1;pointer-events:none;border-radius:inherit;
 background:linear-gradient(105deg,transparent 22%,color-mix(in srgb,currentColor 16%,transparent) 38%,color-mix(in srgb,currentColor 42%,transparent) 50%,color-mix(in srgb,currentColor 16%,transparent) 62%,transparent 78%);
 transform:translateX(-130%);
}
@media(min-width:900px){
 :is(.case-gp,.case-hb,.case-xm) .gp-scroll-link{min-height:58px;padding:.65rem .7rem .65rem 1.45rem;gap:1rem;font-size:1.1rem}
 :is(.case-gp,.case-hb,.case-xm) .gp-scroll-link span{width:2.35rem;height:2.35rem;font-size:1.15rem}
}
@media(prefers-reduced-motion:no-preference){
 :is(.case-gp,.case-hb,.case-xm) .gp-scroll-link::after{animation:cs-link-sweep 5.2s cubic-bezier(.45,.05,.25,1) 1.4s infinite}
 :is(.case-gp,.case-hb,.case-xm) .gp-scroll-link span{animation:cs-link-nudge 2.6s ease-in-out 1.4s infinite}
 :is(.case-gp,.case-hb,.case-xm) .gp-scroll-link[href="#main"] span{animation-name:cs-link-nudge-up}
 :is(.case-gp,.case-hb,.case-xm) .gp-scroll-link:is(:hover,:focus-visible)::after,:is(.case-gp,.case-hb,.case-xm) .gp-scroll-link:is(:hover,:focus-visible) span{animation-play-state:paused}
}
@keyframes cs-link-sweep{0%,64%{transform:translateX(-130%)}88%,100%{transform:translateX(130%)}}
@keyframes cs-link-nudge{0%,58%,100%{translate:0 0}70%{translate:0 3px}82%{translate:0 0}}
@keyframes cs-link-nudge-up{0%,58%,100%{translate:0 0}70%{translate:0 -3px}82%{translate:0 0}}
:is(.case-gp .gp-hero-intro,.case-hb .hb-hero-copy)>.gp-scroll-link{margin-top:32px}

/* Picker: the same swatch row for brands (dating) and states (Highbucha) */
.case-hb .cs-picker{margin:28px 0 0}
.case-hb .cs-picker>div{justify-content:flex-start}
.case-hb [data-case-theme=light] .cs-picker button[aria-pressed=true]{border-color:var(--case-accent)}

/* Closing block: "What we learned" */
:is(.case-gp,.case-hb,.case-xm) .cs-close{margin:0 0 24px;padding:clamp(72px,9vw,144px) var(--edge) clamp(48px,6vw,86px);border-radius:36px;background:var(--case-paper,#fff);color:var(--case-ink,#161616)}
.case-hb .hb-motion+.hb-dialog+.cs-close,.case-hb .hb-motion+.cs-close{margin-top:24px}
:is(.case-gp,.case-hb,.case-xm) .cs-close .gp-close-head h2{max-width:18ch}
:is(.case-gp,.case-hb,.case-xm) .cs-close .gp-lessons{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:clamp(16px,2.4vw,32px);margin:clamp(28px,4vw,48px) 0 0;padding:0;list-style:none}
:is(.case-gp,.case-hb,.case-xm) .cs-close .gp-lessons li{display:grid;align-content:start;gap:10px;margin:0;padding:clamp(22px,2.4vw,32px);border-radius:22px;background:color-mix(in srgb,var(--case-accent) 6%,#fff);transition:background .6s ease}
:is(.case-gp,.case-hb,.case-xm) .cs-close .gp-lesson-num{color:var(--case-accent);font:600 13px/1 var(--sans,sans-serif);letter-spacing:.08em;font-variant-numeric:tabular-nums}
:is(.case-gp,.case-hb,.case-xm) .cs-close .gp-lessons h3{margin:6px 0 0;color:var(--case-ink,#17161c);font:650 clamp(20px,1.7vw,25px)/1.15 var(--sans,sans-serif);letter-spacing:-.025em}
:is(.case-gp,.case-hb,.case-xm) .cs-close .gp-lessons p{margin:0;color:color-mix(in srgb,var(--case-ink,#17161c) 66%,transparent);font-size:clamp(15px,1.1vw,16.5px);line-height:1.55}
@media(max-width:820px){:is(.case-gp,.case-hb,.case-xm) .cs-close .gp-lessons{grid-template-columns:1fr}}
@media(max-width:640px){:is(.case-gp,.case-hb,.case-xm) .cs-close{border-radius:24px;padding:56px 28px 36px}}

/* Dating hero: copy on the left, the brand and its picker on the right (Highbucha: copy left, cans right) */
@media(min-width:901px){
 .case-gp .gp-hero .case-hero-copy{display:grid;grid-template-columns:minmax(0,1.25fr) minmax(260px,.75fr);grid-template-areas:"intro brand" "intro actions";column-gap:clamp(40px,6vw,120px);row-gap:0;align-items:center;text-align:left;width:100%;max-width:none}
 .case-gp .gp-hero-intro{grid-area:intro;text-align:left}
 .case-gp .gp-hero-intro>*{margin-inline:0}
 .case-gp .gp-showcased-brand{grid-area:brand;align-self:end;justify-self:center}
 .case-gp .gp-hero-actions{grid-area:actions;align-self:start;justify-self:center}
}

/* Section intro: label and heading on the left, the paragraph on the right (Highbucha's case-story layout) */
:is(.case-hb .case-prose>p,.case-hb .hb-motion-copy>p:not(.case-kicker,.hb-motion-name),.case-gp .gp-scope-heading>p:last-child,.case-gp .tour-story-head>p){font-size:clamp(18px,1.6vw,24px);line-height:1.55;letter-spacing:-.025em}
.case-gp .gp-scope-heading{grid-column:1/-1}
@media(min-width:901px){
 .case-gp .gp-scope-heading{display:grid;grid-template-columns:1fr 1fr;column-gap:6%;align-items:start}
 .case-gp .gp-scope-heading>:is(.case-kicker,.cs-title){grid-column:1}
 .case-gp .gp-scope-heading>p:last-child{grid-column:2;grid-row:1/3;align-self:end;max-width:34rem}
}
@media(max-width:900px){.case-gp .gp-scope-heading>.cs-title{margin-bottom:20px}}
@media(min-width:901px){
 .case-gp .gp-test-final #design-decisions{grid-template-columns:minmax(0,1fr);grid-template-rows:auto auto;row-gap:clamp(32px,4vw,56px)}
 .case-gp .gp-test-final .gp-decisions>:is(.gp-decisions-heading,.measure-study){grid-area:auto}
 .case-gp .gp-decisions-heading{display:grid;grid-template-columns:1fr 1fr;column-gap:6%;align-items:start;max-width:none}
 .case-gp .gp-decisions-heading>:is(.case-kicker,.cs-title){grid-column:1}
 .case-gp .gp-test-final .gp-decisions-heading>p:last-child{grid-column:2;grid-row:1/3;align-self:end;max-width:34rem;margin:0}
}
.case-gp .gp-test-final .gp-decisions-heading>p:last-child{font-size:clamp(18px,1.6vw,24px);line-height:1.55;letter-spacing:-.025em;color:inherit}
@media(max-width:900px){.case-gp .gp-decisions-heading>.cs-title{margin-bottom:16px}}
.case-hb .hb-label-copy .cs-picker{margin:24px 0 22px}
.case-hb .hb-motion-copy .cs-title{margin-bottom:clamp(20px,2.4vw,32px)}
.case-hb .hb-motion-copy .cs-picker{margin:28px 0 18px}
/* Tour system: the heading shares its row with the spinning phone, so it steps down a size to keep two clean lines */
.case-gp .case-page .gp-feature-above .cs-title{font-size:clamp(40px,3.8vw,56px);max-width:none;margin-bottom:24px}

/* A/B card (CJ: "use the brand color instead of the black so it has the same monochromatic feel"):
   the data side is the brand field, the read side a pale tint of it, the headline in the brand color. */
.case-gp .measure-study{border-color:color-mix(in srgb,var(--tint) 22%,transparent)}
.case-gp .measure-lab{background:linear-gradient(140deg,color-mix(in srgb,var(--tint) 90%,#fff) 0%,var(--tint) 45%,color-mix(in srgb,var(--tint) 78%,#000) 100%);color:#fff;transition:background .6s ease}
.case-gp .measure-lab .study-label{color:color-mix(in srgb,#fff 78%,transparent)}
.case-gp .measure-lab .study-controls{background:color-mix(in srgb,#000 14%,transparent);border-color:color-mix(in srgb,#fff 30%,transparent)}
.case-gp .measure-lab .study-controls button[aria-pressed="true"]{background:#fff;color:var(--tint)}
.case-gp .measure-row small{color:color-mix(in srgb,#fff 74%,transparent)}
.case-gp .measure-row i{background:color-mix(in srgb,#fff 22%,transparent)}
.case-gp .measure-row i::after{background:color-mix(in srgb,#fff 62%,transparent)}
.case-gp .measure-row:last-child i::after{background:#fff}
.case-gp .measure-reading{background:color-mix(in srgb,var(--tint) 7%,#fff);color:var(--case-ink,#201c22);transition:background .6s ease}
.case-gp .measure-reading .study-label{color:var(--tint)}
.case-gp .measure-reading h4{color:var(--tint);transition:color .6s ease}

/* Phone + tablet hero (CJ: "this is weird on mobile. center the button"): copy, then the brand and picker,
   then "Take a tour" centered under them, leading straight into the deck. */
@media(max-width:900px){
 .case-gp .gp-hero .case-hero-copy{display:flex;flex-direction:column}
 .case-gp .gp-hero-intro{display:contents}
 .case-gp .gp-showcased-brand{order:1;align-self:center;margin-top:36px}
 .case-gp .gp-hero-actions{order:2;align-self:center}
 .case-gp .gp-hero-intro>.gp-scroll-link{order:3;align-self:center;margin-top:8px}
}
@media(min-width:901px){.case-gp .case-page .gp-feature-above .cs-title{font-size:clamp(38px,3.2vw,50px)}}

/* Dating: fine print above the footer (sample content, NDA) */
.case-gp .gp-fine-print{margin:0 0 24px;padding:clamp(32px,4vw,52px) var(--edge);border-radius:28px;background:color-mix(in srgb,var(--case-accent) 5%,#fff);color:var(--case-ink,#17161c)}
.case-gp .gp-fine-print .case-kicker{margin-bottom:16px}
.case-gp .gp-fine-print-cols{display:grid;grid-template-columns:1fr 1fr;gap:clamp(20px,4vw,64px)}
.case-gp .gp-fine-print p:not(.case-kicker){margin:0;font-size:15px;line-height:1.6;color:color-mix(in srgb,var(--case-ink,#17161c) 72%,transparent)}
.case-gp .gp-fine-print strong{color:var(--case-ink,#17161c);font-weight:600}
.case-gp .gp-fine-print a{color:var(--case-accent);font-weight:600;text-underline-offset:3px}
@media(max-width:760px){.case-gp .gp-fine-print-cols{grid-template-columns:1fr}.case-gp .gp-fine-print{border-radius:22px;padding:30px 24px}}
