/* Brand themes for the case studies that share the Client 360 layout (case-client360.css).
   Each case keeps the same editorial structure but takes its own product colours:
   Cura = the app's teal, U of T Clubhouse = the app's sky blue. Loaded after case-client360.css. */
body.cs-t-cura, body.cs-t-cura .cs {
  --accent: #127479; --stage: #c4e6e3; --stage-2: #e0f3f2; --tint: #f1f9f8; --stage-rgb: 196, 230, 227;
}
body.cs-t-uoft, body.cs-t-uoft .cs {
  --accent: #1d5fc4; --stage: #bcd6f7; --stage-2: #d0e4fd; --tint: #f2f7fe; --stage-rgb: 188, 214, 247;
}
body.cs-t-cura { background-color: #e0f3f2; }
body.cs-t-uoft { background-color: #d0e4fd; }
body.cs-t-cura .footer-section { background-color: #e0f3f2 !important; }
body.cs-t-uoft .footer-section { background-color: #d0e4fd !important; }

/* pieces of the shared layout that hard-code the RBC blue */
body[class*="cs-t-"] .cs-toc a.on i, body[class*="cs-t-"] .cs-toc a:focus-visible i { background: var(--accent); }
body[class*="cs-t-"] .cs-toc a.on span { color: var(--accent); }
body[class*="cs-t-"] .cs-wall::before { background: linear-gradient(180deg, #fff, rgba(var(--stage-rgb), 0)); }
body[class*="cs-t-"] .cs-wall::after { background: linear-gradient(0deg, var(--stage), rgba(var(--stage-rgb), 0)); }
body[class*="cs-t-"] .cs-mock-frame::after { background: linear-gradient(180deg, rgba(var(--stage-rgb), 0), var(--stage)); }

/* hero: the product shot on its own colour, instead of a browser frame */
.cs-hero-img { width: min(1080px, 100%); margin: 0 auto; border-radius: 16px 16px 0 0; overflow: hidden; max-height: min(560px, 60vw); box-shadow: 0 30px 70px -30px rgba(24, 40, 70, .45); }
.cs-hero-img img { width: 100%; }

/* full-frame before/after (phone screens on their dark presentation boards) */
.cs-shot img.cs-ba { width: 100%; max-height: min(620px, 76vh); object-fit: contain; border-radius: 8px; background: #232323; box-shadow: var(--shot); animation: cs-in 240ms var(--ease-out); }

/* plain images inside the mock frame and the two-up comparison */
.cs-mock-frame > img { border-radius: 10px 10px 0 0; }
.cs-rounds figure img { width: 100%; border-radius: 8px; box-shadow: var(--shot); background: #fff; }

/* "in their hands": the final prototype as short loops */
.cs-reel { display: grid; gap: 20px; }
.cs-reel figure { margin: 0; background: var(--stage); border-radius: 18px; padding: clamp(14px, 2.4vw, 26px); }
.cs-reel img { width: 100%; border-radius: 10px; box-shadow: var(--shot); }
.cs-reel figcaption { margin-top: 14px; font-size: .95rem; line-height: 1.55; color: var(--ink); }
.cs-reel figcaption b { display: block; font: 500 1.15rem/1.3 Outfit, sans-serif; margin-bottom: 4px; }
.cs-reel.phones img { max-width: 240px; margin: 0 auto; border-radius: 24px; }
@media (min-width: 760px) {
  .cs-reel.phones { grid-template-columns: repeat(3, 1fr); }
  .cs-reel.wide figure { display: grid; grid-template-columns: 1fr 2fr; gap: 28px; align-items: center; }
  .cs-reel.wide figcaption { margin: 0; order: -1; }
}
.cs-rounds figure img { max-height: 520px; object-fit: contain; }

/* ---------- closing animations: one per case study ----------
   RBC keeps the tilted wall. Cura: two rows of screens drifting past each other.
   U of T Clubhouse: a Club Matcher deck that swipes itself, echoing the product. */
.cs-wall--marquee { height: clamp(460px, 46vw, 640px); }
.cs-wall--marquee .mq { position: absolute; inset: 0; display: flex; align-items: center; }
.mq-track { display: flex; width: max-content; animation: mq-left 80s linear infinite; }
/* every screen is the same 393x852 Figma frame, shown in the same phone shell */
.mq-track img { height: clamp(300px, 34vw, 470px); width: auto; aspect-ratio: 393 / 852; margin-right: clamp(20px, 2.6vw, 36px);
  border-radius: clamp(26px, 3vw, 40px); border: clamp(5px, .6vw, 8px) solid #14272a; background: #fff;
  box-shadow: 0 30px 50px -26px rgba(15, 50, 55, .55); }
@keyframes mq-left { to { transform: translateX(-50%); } }
.cs-wall:not(.on) .mq-track { animation-play-state: paused; }

.cs-wall--deck { background: radial-gradient(60% 70% at 50% 45%, #fff 0, var(--stage-2) 45%, var(--stage) 100%); }
.deck { position: absolute; z-index: 3; left: 50%; top: 45%; width: clamp(140px, 17vw, 210px); aspect-ratio: 320 / 648; transform: translate(-50%, -50%); }
.deck-card { position: absolute; inset: 0; border-radius: 24px; overflow: hidden; background: #fff; box-shadow: 0 30px 60px -28px rgba(24, 40, 70, .55);
  transition: transform 600ms var(--ease-out), opacity 500ms ease; }
.deck-card img { width: 100%; height: 100%; object-fit: cover; }
.deck-stamp { position: absolute; top: 20px; padding: 3px 10px; border: 3px solid currentColor; border-radius: 8px; background: rgba(255,255,255,.9);
  font: 600 16px Outfit, sans-serif; letter-spacing: .08em; text-transform: uppercase; opacity: 0; transition: opacity 150ms ease; }
.deck-stamp.like { left: 16px; color: #1a8f50; transform: rotate(-12deg); }
.deck-stamp.pass { right: 16px; color: #d6453a; transform: rotate(12deg); }
.deck-card.liked .deck-stamp.like, .deck-card.passed .deck-stamp.pass { opacity: 1; }
.deck-btn { position: absolute; top: 50%; width: 56px; height: 56px; margin-top: -28px; border-radius: 50%; background: #fff; display: grid; place-items: center;
  box-shadow: 0 12px 24px -12px rgba(24, 40, 70, .5); transition: transform 160ms var(--ease-out); }
.deck-btn svg { width: 22px; height: 22px; }
.deck-btn.x { left: -96px; color: #d6453a; } .deck-btn.h { right: -96px; color: #1a8f50; }
.deck-btn.go { transform: scale(.88); }
@media (max-width: 480px) { .deck-btn { width: 44px; height: 44px; margin-top: -22px; } .deck-btn.x { left: -64px; } .deck-btn.h { right: -64px; } }
@media (prefers-reduced-motion: reduce) { .mq-track { animation: none; } .deck-card { transition: none; } }
.cs-wall--marquee::before, .cs-wall--marquee::after { height: 64px; }
/* U of T: the app recordings already include the phone, so no extra shell */
.mq--bare .mq-track img { aspect-ratio: 320 / 648; border: 0; border-radius: 0; background: none; box-shadow: none; filter: drop-shadow(0 26px 30px rgba(24, 60, 120, .28)); }
/* The Clubhouse recordings are GIFs (no transparency): trim each to the phone's own
   rounded outline so no light rectangle shows, and put the shadow on a wrapper. */
.mq-ph { flex: none; display: block; margin-right: clamp(20px, 2.6vw, 36px); filter: drop-shadow(0 24px 26px rgba(24, 60, 120, .3)); }
.mq--bare .mq-track .mq-ph img { margin: 0; filter: none; }
.mq--bare .mq-track img, .cs-reel.phones img { clip-path: inset(0.3% 1.2% 0.2% 0.7% round 13.5% / 6.7%); border-radius: 0; box-shadow: none; }
.cs-reel.phones figure img { filter: drop-shadow(0 0 0 transparent); }
