/* Carey Creative — Work index and case study pages.
   Loads after services.css (shared layout, nav, Button, Badge, final CTA, footer)
   and home.css (Card, primary/ghost Button, ink Badge). */

/* ---------- Case study hero ---------- */
.cs-hero { max-width: 1040px; padding: 88px 0 72px; gap: 28px; }
.cs-hero .hero__kicker { line-height: 1.8; }
.cs-hero .hero__title { font-size: clamp(38px, 5.4vw, 68px); }

.hero__title em, .h2 em { font-style: italic; font-weight: 700; }

/* Hero photo: copy beside a circular portrait, facts below */
.sc-hero__main, .sc-hero__copy { display: contents; }
.sc-hero--portrait { max-width: var(--container-max); text-align: left; align-items: stretch; }
.sc-hero--portrait .sc-hero__main {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: 40px 64px;
  align-items: center;
}
.sc-hero--portrait .sc-hero__copy { display: flex; gap: 24px; align-items: flex-start; }
.sc-hero--portrait .hero__title { font-size: clamp(36px, 4.4vw, 60px); }
.sc-portrait { position: relative; margin: 0; width: 100%; max-width: 420px; justify-self: center; }
.sc-portrait__frame { aspect-ratio: 1; border-radius: 50%; overflow: hidden; box-shadow: 0 0 0 6px var(--ink-800), 0 0 0 7px var(--border-onDark); }
.sc-portrait__frame img { display: block; width: 100%; height: 100%; object-fit: cover; }
.sc-portrait__frame .asset-slot { width: 100%; height: 100%; padding: 18%; border-radius: 0; }
.sc-portrait__handle {
  position: absolute;
  right: 4%;
  bottom: 8%;
  padding: 10px 18px;
  border-radius: var(--radius-pill);
  background: var(--paper);
  color: var(--ink-950);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: .01em;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .35);
}

.cs-meta {
  width: 100%;
  margin: 24px 0 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
  border-top: 1px solid var(--border-onDark);
  text-align: left;
}
.cs-meta__item { padding: 22px 24px 0 0; display: flex; flex-direction: column; gap: 6px; }
.cs-meta dt {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--indigo-300);
}
.cs-meta dd { margin: 0; font-size: 14px; line-height: 1.55; color: var(--text-onDark); }

/* ---------- Figures and asset slots ---------- */
.cs-figure { margin: 0; display: flex; flex-direction: column; gap: 12px; }
.cs-figure img { display: block; width: 100%; height: auto; border-radius: var(--radius-md); }
.cs-figure figcaption { font-size: 13px; line-height: 1.55; color: var(--text-muted); }

/* A labelled slot that stands in for an approved photo or screenshot.
   Swap each .asset-slot for an <img> once the asset is approved. */
.asset-slot {
  aspect-ratio: var(--slot-ratio, 16 / 10);
  border: 1.5px dashed var(--ink-400);
  border-radius: var(--radius-md);
  background: var(--oat-100);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 8px;
  padding: 24px;
  text-align: center;
  color: var(--text-secondary);
}
.asset-slot__tag { font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--orange-700); }
.asset-slot__desc { max-width: 420px; font-size: 14px; line-height: 1.5; }
.asset-slot--wide { --slot-ratio: 21 / 9; }
.asset-slot--pair { display: grid; grid-template-columns: 3fr 1fr; gap: 12px; padding: 0; border: none; background: none; aspect-ratio: auto; }
.asset-slot--pair > .asset-slot { height: 100%; }
.asset-slot--pair > .asset-slot:last-child { --slot-ratio: 9 / 16; }
.asset-slot--pair { align-items: center; grid-template-columns: 5fr 1fr; }
.cs-figure img.cs-shot { border-radius: 0; }

.cs-photo { padding: 72px 24px 100px; background: var(--cream-50); }
.cs-photo .cs-figure { margin: 0 auto; }

/* ---------- Brief ---------- */
.cs-brief .split { align-items: start; }
.cs-brief .body-copy { font-size: 16px; }
.cs-brief__goal { color: var(--text-primary); font-weight: 500; }

/* ---------- What we built ---------- */
.built { gap: 72px; }
.built__intro { gap: 20px; max-width: 640px; }
.module {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 40px 72px;
  align-items: center;
  padding-top: 56px;
  border-top: 1px solid var(--border-subtle);
}
.module:nth-of-type(even) .module__copy { order: 2; }
.module__copy { gap: 16px; }
.module__num { font-family: var(--font-mono); font-size: 12px; letter-spacing: .08em; color: var(--text-muted); }
.module__title {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(26px, 2.8vw, 34px);
  line-height: 1.12;
  letter-spacing: -.02em;
}
.module__tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 0; padding: 0; list-style: none; }
.module__tags li {
  font-size: 12px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  background: var(--indigo-100);
  color: var(--indigo-700);
}

/* ---------- Outcome ---------- */
.outcome .split { align-items: start; }
.outcome__copy { gap: 18px; }
.outcome__copy .body-copy { font-size: 16px; }
.outcome__lead { color: var(--text-onDark) !important; font-size: 19px !important; line-height: 1.6 !important; }
.role {
  margin-top: 12px;
  background: var(--bg-card-dark);
  border: 1px solid var(--border-onDark);
  border-radius: var(--radius-md);
  padding: 24px 28px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.role__label { font-size: 11px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--orange-500); }
.role p { margin: 0; font-size: 15px; line-height: 1.6; color: var(--text-onDark); }

/* ---------- Closing statement ---------- */
.keep-working .container { max-width: 820px; gap: 20px; align-items: flex-start; }
.keep-working .body-copy { font-size: 17px; }

/* ---------- Work index ---------- */
.work-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 360px), 1fr)); gap: 20px; }
.work-card { gap: 14px; padding: 0 0 28px; }
.work-card > :not(.work-card__media) { margin: 0 28px; }
.work-card__media { margin: 0 0 8px; }
.work-card__media .asset-slot { border-radius: 0; border-width: 0 0 1.5px; }
.work-card__media img { display: block; width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.work-card__eyebrow { font-size: 11px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--text-muted); }
.work-card .card__title { font-size: 24px; }
.work-card__services { font-size: 13px; color: var(--text-secondary); }

@media (max-width: 860px) {
  .module { grid-template-columns: 1fr; }
  .module:nth-of-type(even) .module__copy { order: 0; }
  .sc-hero--portrait .sc-hero__main { grid-template-columns: 1fr; }
  .sc-portrait { max-width: 300px; order: -1; }
}

@media (max-width: 560px) {
  .cs-hero { padding: 64px 0 56px; }
  .cs-meta { grid-template-columns: 1fr 1fr; margin-top: 8px; }
  .cs-meta__item { padding-top: 16px; }
  .cs-meta__item:last-child { grid-column: 1 / -1; }
  .asset-slot--pair { grid-template-columns: 1fr; }
  .asset-slot--pair > .asset-slot:last-child { --slot-ratio: 4 / 5; }
  .asset-slot--pair > img:last-child { max-width: 240px; margin: 0 auto; }
  .cs-photo { padding: 48px 20px 72px; }
}
