/* ============================================================
   CASE STUDIES + WORKSHOP DETAIL - extracted from style.css
   (css-reshape Phase 4, 2026-08-10)
   Loaded ONLY by pages that render these components, via extraCss
   front matter: case-study index+detail (EN/HE), workshop detail
   pages (workshop-he layout), hr-intro (cs-testimonial cards).
   Internal order preserved from the original file: base rules ->
   responsive -> readability bump, so the cascade is unchanged.
   ============================================================ */

/* About section embedded inside the narrow article body (workshop pages):
   the 680px column can't fit the homepage's 260px+80px-gap grid, so tighten it.
   Scoped to >768px because below that the grid stacks to one column anyway. */
@media (min-width: 769px) {
  .cs-body .about { padding: 56px 0 12px; border-bottom: none; }
  .cs-body .about-grid { grid-template-columns: 190px 1fr; gap: 40px; }
}

/* ============================================================
   CASE STUDIES - Index + Detail
   ============================================================ */

/* ── Index listing ── */
.cs-listing {
  padding: 96px 0 120px;
}

.cs-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}

.cs-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 36px 32px 32px;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.2s, background 0.2s, transform 0.18s;
}
.cs-card:hover {
  border-color: var(--mid);
  background: var(--bg);
  transform: translateY(-3px);
}

.cs-card-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.cs-card-industry {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--light);
}
.cs-card-service {
  font-size: 12px;
  font-weight: 500;
  color: var(--light);
  border: 1px solid var(--border);
  padding: 2px 8px;
  border-radius: 100px;
}

.cs-card h2 {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.3px;
  line-height: 1.3;
  margin: 0;
  color: var(--black);
}

.cs-card-desc {
  font-size: 16px;
  color: var(--mid);
  line-height: 1.65;
  margin: 0;
  flex: 1;
}

.cs-card-result {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 18px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.cs-card-result-stat {
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.04em;
  color: var(--black);
  line-height: 1;
}
.cs-card-result-label {
  font-size: 13px;
  color: var(--light);
  font-weight: 400;
}

.cs-card-excerpt {
  font-size: 15px;
  color: var(--mid);
  line-height: 1.6;
  margin: 0;
  font-style: italic;
}

.cs-card-cta {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--black);
  margin-top: auto;
}
.cs-card:hover .cs-card-cta {
  text-decoration: underline;
}

.cs-empty {
  font-size: 17px;
  color: var(--light);
  padding: 64px 0;
}

.cs-coming-soon {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 80px 20px;
  gap: 20px;
}

.cs-coming-soon-icon {
  font-size: 48px;
  line-height: 1;
}

.cs-coming-soon h2 {
  font-size: clamp(22px, 3vw, 30px);
  font-weight: 700;
  color: var(--black); /* was undefined var(--heading) - inherited body color anyway */
  margin: 0;
}

.cs-coming-soon p {
  font-size: 16px;
  color: var(--light);
  max-width: 480px;
  margin: 0;
  line-height: 1.6;
}

/* ── Individual case study hero chips ── */
.cs-hero-chips {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.cs-chip {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(249, 247, 242, 0.55);
  border: 1px solid rgba(249, 247, 242, 0.2);
  padding: 4px 12px;
  border-radius: 100px;
}
.cs-chip--service {
  color: rgba(249, 247, 242, 0.45);
  border-color: rgba(249, 247, 242, 0.12);
}

/* ── Article container ── */
.cs-article {
  padding: 72px 0 0;
}
.cs-body {
  max-width: 680px;
  padding-bottom: 0;
}

/* ── Result stats callout ── */
.cs-results {
  display: flex;
  gap: 0;
  margin: 56px 0;
  background: var(--black);
  border-radius: var(--radius);
  overflow: hidden;
  max-width: 680px;
}
.cs-stat-block {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 36px 40px;
  position: relative;
}
.cs-stat-block + .cs-stat-block {
  border-left: 1px solid rgba(255,255,255,0.1);
}
.cs-stat-value {
  font-size: 38px;
  font-weight: 700;
  letter-spacing: -0.04em;
  color: var(--bg);
  line-height: 1;
  white-space: nowrap;
}
.cs-stat-label {
  font-size: 15px;
  color: rgba(249, 247, 242, 0.6);
  line-height: 1.4;
}

/* ── Testimonial block ── */
.cs-testimonial {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 40px;
  margin: 56px 0;
  max-width: 680px;
}
.cs-testimonial-quote {
  font-size: 17px;
  font-weight: 400;
  line-height: 1.8;
  color: var(--dark);
  font-style: normal;
  margin: 0 0 28px 0;
  position: relative;
}
.cs-testimonial-quote::before {
  content: "\201C";
  display: block;
  font-size: 52px;
  line-height: 1;
  color: var(--border);
  margin-bottom: 8px;
  font-style: normal;
}
.cs-testimonial-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}
.cs-testimonial-role {
  font-size: 1rem;
  color: var(--mid);
}

.cs-client-photo {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
}
.cs-client-photo picture {
  display: block;
  width: 100%;
  height: 100%;
}
.cs-client-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}

.cs-client-photo-placeholder {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: 700;
  color: var(--mid);
  flex-shrink: 0;
}
.cs-client-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.cs-client-name {
  font-size: 17px;
  font-weight: 600;
  color: var(--black);
  display: block;
}
.cs-client-title {
  font-size: 15px;
  color: var(--light);
  display: block;
}

/* ── Bottom CTA on detail page ── */
.cs-bottom-cta {
  padding: 72px 0 96px;
  max-width: 580px;
}
.cs-bottom-cta h2 {
  font-size: clamp(26px, 3.5vw, 38px);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.15;
  margin-bottom: 16px;
}
.cs-bottom-cta p {
  font-size: 16px;
  color: var(--mid);
  line-height: 1.7;
  margin-bottom: 36px;
}

/* ── Responsive ── */
@media (max-width: 960px) {
  .cs-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 640px) {
  .cs-grid { grid-template-columns: 1fr; gap: 20px; }
  .cs-listing { padding: 64px 0 80px; }
  .cs-card { padding: 32px 24px 28px; }
  .cs-card h2 { font-size: 18px; }
  .cs-card-result-stat { font-size: 24px; }
  .cs-results { flex-direction: column; }
  .cs-stat-block + .cs-stat-block { border-left: none; border-top: 1px solid rgba(255,255,255,0.1); }
  .cs-stat-block { padding: 28px 32px; }
  .cs-stat-value { font-size: 30px; }
  .cs-testimonial { padding: 28px 24px; }
  .cs-bottom-cta { padding: 56px 0 72px; }
}

/* Scroll entrance for listing */
@supports (animation-timeline: view()) {
  .cs-listing {
    animation: sectionEntrance linear both;
    animation-timeline: view();
    animation-range: entry 0% entry 25%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cs-listing { animation: none !important; }
  .cs-card { transition: none; }
}

/* hr-intro: cs-testimonial cards inside the hr grid */
.hr-testimonial-grid .cs-testimonial {
  max-width: none;
  margin: 0;
}

/* ── MOBILE READABILITY BUMP (cs part, split from the global bump block;
   must stay at the END of this file to win the cascade) ──
   NOTE: no `.cs-body p` rule here on purpose. Every .cs-body in markup is
   `class="post-body cs-body"`, and the global bump's `.post-body p { 21px }`
   was always the winning rule; re-declaring .cs-body p in this (later)
   file would resurrect a rule that never actually applied. */
@media (max-width: 768px) {
  .cs-card-desc,
  .cs-coming-soon p { font-size: 19px; }
}
