/* Caminho.DEV — the work pages: /case-studies (the hub) and /case-studies/{slug}
   (case-study.php). Built on pages.css; everything here is scoped to .mp-page--work or
   to the cs- classes those two pages print. */

/* ── Shared: the laptop-and-phone frame every piece of work is shown in ─────────── */
.cs-devices { position: relative; padding: 0 9% 7% 0; }
.cs-devices .mp-laptop-screen { aspect-ratio: 16 / 10; }
.cs-devices .mp-laptop-screen > * { height: 100%; }
.cs-screen img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top center; }
.cs-devices .mp-browser { height: 100%; border: 0; border-radius: 8px; box-shadow: none; }
.cs-devices .cs-phone { right: 0; bottom: 0; width: 24%; min-width: 74px; padding: 5px; border-radius: 18px; }
.cs-phone .mp-phone-screen { min-height: 0; aspect-ratio: 9 / 18.5; border-radius: 13px; display: flex; flex-direction: column; }
.cs-phone .mp-phone-notch { flex: none; width: 34%; height: 4px; margin: 4px auto 4px; }
.cs-phone .mp-phone-screen img { flex: 1; min-height: 0; width: 100%; object-fit: cover; object-position: top center; display: block; }
/* A desktop screenshot on the phone: its left-hand column, which is where a site's
   headline sits, rather than the whole page shrunk to a sliver. */
.cs-phone .mp-phone-screen img.is-desk { object-position: 12% top; }
.cs-phone .mp-site-copy { padding: 10px 8px; }
.cs-phone .mp-site-copy h4 { font-size: 0.66rem; }
.cs-phone .mp-site-copy p { display: none; }
.cs-phone .mp-site-pic { min-height: 54px; }

/* Tags and ticks. */
.cs-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.cs-tag { display: inline-flex; align-items: center; font-size: 0.66rem; font-weight: 700; letter-spacing: .01em; color: #3a47b8;
  background: #e9ecff; border-radius: 999px; padding: 4px 10px; }
.cs-tag--alt { color: #b4235a; background: #fde8f0; }
.cs-tag--soft { color: #8a5a00; background: #fff3dc; }
.cs-tag--wait { color: #9a5b00; background: #fff3dc; }
.mp-page--work .cs-ticks { gap: 7px; margin: 14px 0 0; }
.mp-page--work .cs-ticks li { font-size: 0.86rem; color: var(--mp-ink-2); }

/* ── Hub: the featured piece ─────────────────────────────────────────────────── */
.cs-feature { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: 40px; align-items: center;
  background: #fff; border: 1px solid var(--mp-line); border-radius: 20px; padding: 34px 36px;
  box-shadow: 0 24px 60px rgba(31, 45, 96, 0.08); }
.cs-feature .mp-h2 { margin: 0; }
.cs-meta { margin: 6px 0 0; font-size: 0.82rem; color: var(--mp-muted); }
.cs-summary { margin: 14px 0 0; font-size: 0.93rem; line-height: 1.65; max-width: 52ch; }
.cs-feature .mp-actions { margin-top: 22px; }
.cs-feature-art { display: block; }
.cs-results { display: flex; flex-wrap: wrap; gap: 10px 24px; margin-top: 16px; }
.cs-results b { display: block; font-size: 1.1rem; color: var(--mp-ink); }
.cs-results small { font-size: 0.7rem; color: var(--mp-muted); }

/* ── Hub: more of our work ──────────────────────────────────────────────────── */
.cs-more-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 18px; flex-wrap: wrap; margin-bottom: 22px; }
.cs-more-head .mp-h2 { margin: 0; font-size: clamp(1.45rem, 2.3vw, 1.85rem); }
.cs-more-head .mp-small { margin: 0; }
.cs-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.cs-card { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--mp-line); border-radius: 16px; overflow: hidden;
  box-shadow: 0 14px 34px rgba(31, 45, 96, 0.06); transition: transform .25s ease, box-shadow .25s ease; }
.cs-card:hover { transform: translateY(-4px); box-shadow: 0 22px 46px rgba(31, 45, 96, 0.12); }
.cs-card[hidden] { display: none; }
.cs-card-art { display: block; padding: 22px 22px 18px; background: linear-gradient(160deg, #f3f6ff, #f6f2fe); }
.cs-card-art .mp-laptop-screen { border-width: 6px; border-radius: 10px; }
.cs-card-art .mp-laptop-screen > * { border-radius: 5px; }
.cs-card-art .mp-laptop-base { height: 8px; }
.cs-card-art .mp-browser-bar { padding: 5px 8px; }
.cs-card-art .mp-site-copy h4 { font-size: 0.7rem; }
.cs-card-body { display: flex; flex-direction: column; flex: 1; padding: 18px 20px 20px; }
.cs-card-body .cs-tags { margin-bottom: 8px; }
.cs-card-body h3 { margin: 0 0 6px; font-size: 1.05rem; color: var(--mp-ink); }
.cs-card-body h3 a { color: inherit; text-decoration: none; }
.cs-card-body h3 a:hover { color: var(--mp-accent); }
.cs-card-body > p { margin: 0; font-size: 0.84rem; line-height: 1.6; color: var(--mp-body); }
.cs-card-result { display: flex; gap: 9px; align-items: flex-start; margin-top: 12px !important; padding-top: 12px; border-top: 1px solid var(--mp-line-2); }
.cs-card-result svg { flex: none; width: 18px; height: 18px; color: var(--mp-accent); }
.cs-card-result b { display: block; color: var(--mp-ink-2); }
.cs-card-link { display: inline-flex; align-items: center; gap: 6px; margin-top: auto; padding-top: 14px; font-size: 0.82rem; font-weight: 700;
  color: var(--mp-accent); text-decoration: none; }
.cs-card-link svg { width: 14px; height: 14px; transition: transform .2s; }
.cs-card:hover .cs-card-link svg { transform: translateX(3px); }

/* ── Case study: hero ───────────────────────────────────────────────────────── */
.cs-hero .mp-hero-grid { grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr); gap: 36px; }
.cs-back { display: inline-flex; gap: 6px; margin-bottom: 18px; font-size: 0.8rem; font-weight: 600; color: var(--mp-accent); text-decoration: none; }
.cs-back:hover { text-decoration: underline; }
.cs-hero .mp-h1 { margin-bottom: 6px; }
.cs-sub { margin: 0 0 12px; font-size: 1.12rem; line-height: 1.45; color: var(--mp-ink-2); font-weight: 500; max-width: 40ch; }
.cs-hero .mp-lead { margin-top: 0; }
.cs-hero .mp-actions { margin-top: 24px; }
.cs-hero .mp-btn svg { width: 15px; height: 15px; }
.cs-hero-art { position: relative; }

/* ── Case study: the project ────────────────────────────────────────────────── */
.cs-project { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 44px; align-items: start; }
.cs-project--solo { grid-template-columns: minmax(0, 760px); }
.cs-project p { margin: 14px 0 0; font-size: 0.93rem; line-height: 1.7; color: var(--mp-body); max-width: 62ch; }
.cs-project .mp-h2 { margin-bottom: 4px; }
.cs-points { display: grid; gap: 4px; background: linear-gradient(160deg, #fbf5fb, #f6f3fe); border: 1px solid #efe4f3; border-radius: 18px; padding: 10px 24px; }
.cs-point { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 16px; padding: 18px 0; }
.cs-point + .cs-point { border-top: 1px solid rgba(220, 205, 232, 0.6); }
.cs-point-ico { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: #fff; color: var(--mp-accent);
  box-shadow: 0 8px 18px rgba(31, 45, 96, 0.08); }
.cs-point-ico svg { width: 20px; height: 20px; }
.cs-point h3 { margin: 2px 0 4px; font-size: 0.95rem; color: var(--mp-ink); }
.cs-point p { margin: 0; font-size: 0.84rem; line-height: 1.6; }
.cs-point ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 4px; }
.cs-point li { position: relative; padding-left: 14px; font-size: 0.84rem; line-height: 1.5; color: var(--mp-body); }
.cs-point li::before { content: ''; position: absolute; left: 0; top: .6em; width: 5px; height: 5px; border-radius: 50%; background: var(--mp-accent); }

/* ── Case study: a look at the website ─────────────────────────────────────── */
.cs-look-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 18px; }
.cs-look-head .mp-h2 { margin: 0 0 4px; }
.cs-look-head .mp-small { margin: 0; }
.cs-look-nav { display: flex; gap: 8px; }
.cs-look-nav button { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; cursor: pointer;
  background: #fff; border: 1px solid var(--mp-line); color: var(--mp-accent); box-shadow: 0 6px 14px rgba(31, 45, 96, 0.08); }
.cs-look-nav button:hover { border-color: #cfdcfb; }
.cs-look-nav button svg { width: 16px; height: 16px; }
.cs-look-nav button[data-dir="-1"] svg { transform: rotate(180deg); }
.cs-look { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 40px) / 3); gap: 20px; overflow-x: auto;
  scroll-snap-type: x mandatory; scrollbar-width: none; padding: 4px 2px 10px; }
.cs-look::-webkit-scrollbar { display: none; }
.cs-shot { margin: 0; scroll-snap-align: start; }
.cs-shot-img { border-radius: 14px; overflow: hidden; border: 1px solid var(--mp-line); background: #fff; aspect-ratio: 16 / 10;
  box-shadow: 0 14px 30px rgba(31, 45, 96, 0.08); }
.cs-shot-img img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top center; }
.cs-shot figcaption { margin-top: 12px; font-size: 0.8rem; line-height: 1.55; color: var(--mp-body); }
.cs-shot figcaption b { display: block; font-size: 0.88rem; color: var(--mp-ink); margin-bottom: 2px; }

/* ── Case study: details and feedback ──────────────────────────────────────── */
.cs-facts { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 22px; align-items: start; }
.cs-facts--solo { grid-template-columns: minmax(0, 640px); }
.cs-details, .cs-quote { background: #fff; border: 1px solid var(--mp-line); border-radius: 18px; padding: 24px 26px; margin: 0;
  box-shadow: 0 14px 34px rgba(31, 45, 96, 0.05); }
.cs-details h2, .cs-quote h2 { margin: 0 0 14px; font-size: 1rem; color: var(--mp-ink); }
.cs-details dl { margin: 0; display: grid; gap: 11px; }
.cs-details dl > div { display: grid; grid-template-columns: 130px minmax(0, 1fr); gap: 12px; align-items: start; }
.cs-details dt { display: flex; align-items: center; gap: 9px; font-size: 0.8rem; color: var(--mp-muted); }
.cs-details dt svg { width: 16px; height: 16px; color: var(--mp-accent); flex: none; }
.cs-details dd { margin: 0; font-size: 0.84rem; color: var(--mp-ink-2); }
.cs-details dd a { display: inline-flex; align-items: center; gap: 5px; color: var(--mp-accent); font-weight: 600; text-decoration: none; }
.cs-details dd a svg { width: 13px; height: 13px; }
.cs-live { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; color: #0f7a3a; }
.cs-live i { width: 7px; height: 7px; border-radius: 50%; background: #16a34a; box-shadow: 0 0 0 3px rgba(22, 163, 74, .18); }
.cs-quote blockquote { margin: 0; font-size: 0.95rem; line-height: 1.65; color: var(--mp-ink-2); }
.cs-quote figcaption { margin-top: 14px; font-size: 0.8rem; color: var(--mp-muted); }
.cs-quote figcaption b { display: block; color: var(--mp-ink); font-size: 0.86rem; }

/* ── Narrower screens ──────────────────────────────────────────────────────── */
@media (max-width: 1080px) {
  .cs-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cs-look { grid-auto-columns: calc((100% - 20px) / 2); }
}
@media (max-width: 920px) {
  .cs-feature { grid-template-columns: minmax(0, 1fr); padding: 26px 22px; gap: 26px; }
  .cs-feature-art { order: -1; }
  .cs-project, .cs-facts { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .cs-hero-art { max-width: 560px; margin-top: 8px; }
}
@media (max-width: 640px) {
  /* pages.css hides drawn phones on a phone; this one is sized to its laptop, so it stays. */
  .cs-devices .cs-phone { display: block; }
  .cs-grid { grid-template-columns: minmax(0, 1fr); }
  .cs-look { grid-auto-columns: 82%; }
  .cs-points { padding: 6px 18px; }
  .cs-details { padding: 20px; }
  .cs-details dl > div { grid-template-columns: minmax(0, 1fr); gap: 2px; }
  .cs-look-nav { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .cs-card, .cs-card-link svg { transition: none; }
}
