/* ============================================
   ADVANCED MONKEY — CASE STUDY PAGE CSS
   Reusable template styling for all case studies
   ============================================ */

/* ─── CASE HERO ─── */
.cs-hero {
  padding-top: calc(var(--nav-height) + 80px);
  padding-bottom: 80px;
  padding-left: var(--pad-x);
  padding-right: var(--pad-x);
  background: var(--ink);
}
.cs-hero-inner { max-width: 900px; }
.cs-breadcrumb {
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 32px;
  font-size: 12px; color: rgba(255,255,255,0.4);
}
.cs-breadcrumb a { color: rgba(255,255,255,0.4); text-decoration: none; transition: color var(--transition); }
.cs-breadcrumb a:hover { color: white; }
.cs-breadcrumb span { color: rgba(255,255,255,0.2); }
.cs-tag {
  display: inline-block;
  font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--accent); font-weight: 500; margin-bottom: 20px;
}
.cs-hero h1 {
  color: white; margin-bottom: 24px;
  font-size: clamp(34px, 4.5vw, 56px);
}
.cs-hero-lead {
  font-size: 19px; font-weight: 300;
  color: rgba(255,255,255,0.6); line-height: 1.7;
  max-width: 680px;
}

/* ─── HEADLINE STATS BAR ─── */
.cs-stats-bar {
  background: var(--accent);
  padding: 32px var(--pad-x);
  display: flex; gap: 48px; flex-wrap: wrap;
}
.cs-stat-val {
  font-family: var(--font-head);
  font-size: clamp(26px, 3vw, 34px); font-weight: 700;
  color: white; letter-spacing: -0.02em; line-height: 1;
}
.cs-stat-key {
  font-size: 12px; color: rgba(255,255,255,0.75);
  margin-top: 8px; font-weight: 400; max-width: 180px;
}

/* ─── BODY LAYOUT ─── */
.cs-body { max-width: 820px; margin: 0 auto; }

.cs-section { padding: 72px var(--pad-x); border-bottom: 1px solid var(--faint); }
.cs-section:last-of-type { border-bottom: none; }

.cs-section-label {
  font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--accent); font-weight: 500; margin-bottom: 12px;
}
.cs-section h2 {
  font-size: clamp(26px, 3vw, 38px);
  margin-bottom: 28px;
}
.cs-section h3 {
  font-size: 20px; margin-bottom: 14px; margin-top: 32px;
  color: var(--ink);
}
.cs-section p {
  font-size: 17px; color: var(--mid); font-weight: 300;
  line-height: 1.85; margin-bottom: 20px;
}
.cs-section p strong { color: var(--ink); font-weight: 500; }
.cs-section p:last-child { margin-bottom: 0; }

/* ─── LEAD PARA ─── */
.cs-lead {
  font-size: 20px !important;
  color: var(--ink) !important;
  font-weight: 300;
  line-height: 1.7 !important;
}

/* ─── PROBLEM/BEFORE LIST ─── */
.cs-list {
  list-style: none;
  display: flex; flex-direction: column; gap: 14px;
  margin: 24px 0;
}
.cs-list li {
  font-size: 16px; color: var(--mid); font-weight: 300;
  line-height: 1.6; padding-left: 24px; position: relative;
}
.cs-list li::before {
  content: '→'; position: absolute; left: 0;
  color: var(--accent); font-weight: 500;
}
.cs-list li strong { color: var(--ink); font-weight: 500; }

/* ─── CALLOUT / PULL QUOTE ─── */
.cs-callout {
  background: var(--ink);
  border-radius: var(--radius);
  padding: 36px;
  margin: 36px 0;
}
.cs-callout-label {
  font-size: 10px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--accent); font-weight: 500; margin-bottom: 14px;
}
.cs-callout p {
  font-family: var(--font-head);
  font-size: 21px !important; font-weight: 600;
  color: white !important; line-height: 1.5 !important;
  letter-spacing: -0.01em; margin: 0 !important;
}
.cs-callout p em { font-style: normal; color: var(--accent); }

/* ─── BEFORE / AFTER ─── */
.cs-beforeafter {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 1px; background: var(--faint);
  border: 1px solid var(--faint); border-radius: var(--radius);
  overflow: hidden; margin: 32px 0;
}
.cs-ba-col { background: var(--paper); padding: 32px; }
.cs-ba-col.after { background: var(--warm); }
.cs-ba-label {
  font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase;
  font-weight: 600; margin-bottom: 16px;
}
.cs-ba-col .cs-ba-label { color: var(--mid); }
.cs-ba-col.after .cs-ba-label { color: var(--accent); }
.cs-ba-col ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.cs-ba-col li {
  font-size: 14px; color: var(--mid); font-weight: 300;
  line-height: 1.5; padding-left: 18px; position: relative;
}
.cs-ba-col li::before { content: '—'; position: absolute; left: 0; color: var(--faint); }
.cs-ba-col.after li::before { content: '✓'; color: var(--accent); }

/* ─── SCOPE TABLE ─── */
.cs-scope {
  width: 100%; border-collapse: collapse;
  margin: 24px 0; font-size: 15px;
  border: 1px solid var(--faint); border-radius: var(--radius); overflow: hidden;
}
.cs-scope th {
  background: var(--ink); color: rgba(255,255,255,0.7);
  font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase;
  font-weight: 500; padding: 14px 18px; text-align: left;
}
.cs-scope td {
  padding: 14px 18px; border-bottom: 1px solid var(--faint);
  vertical-align: top; color: var(--mid); font-weight: 300; line-height: 1.5;
}
.cs-scope tr:last-child td { border-bottom: none; }
.cs-scope tr:nth-child(even) td { background: var(--warm); }
.cs-scope td strong { color: var(--ink); font-weight: 600; }
.cs-scope td:first-child { white-space: nowrap; }

/* ─── PHASE BLOCKS (what was built) ─── */
.cs-phase {
  margin: 28px 0;
  padding-left: 28px;
  border-left: 2px solid var(--faint);
}
.cs-phase-title {
  font-family: var(--font-head);
  font-size: 17px; font-weight: 700; color: var(--ink);
  margin-bottom: 12px;
  position: relative;
}
.cs-phase-title::before {
  content: '';
  position: absolute; left: -33px; top: 6px;
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--accent);
}

/* ─── RESULT GRID ─── */
.cs-results {
  display: grid; grid-template-columns: repeat(2, 1fr);
  gap: 1px; background: var(--faint);
  border: 1px solid var(--faint); border-radius: var(--radius);
  overflow: hidden; margin: 28px 0;
}
.cs-result { background: var(--paper); padding: 28px; }
.cs-result-val {
  font-family: var(--font-head);
  font-size: 32px; font-weight: 700; color: var(--ink);
  letter-spacing: -0.02em; line-height: 1; margin-bottom: 8px;
}
.cs-result-val span { color: var(--accent); }
.cs-result-desc {
  font-size: 14px; color: var(--mid); font-weight: 300; line-height: 1.5;
}

/* ─── CLOSING ARC QUOTE ─── */
.cs-arc {
  background: var(--warm);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 36px;
  margin: 8px 0;
}
.cs-arc p {
  font-size: 19px !important; color: var(--ink) !important;
  font-weight: 400; line-height: 1.7 !important;
  font-style: italic; margin: 0 !important;
}

/* ─── NEXT CASE / NAV ─── */
.cs-next {
  background: var(--warm);
  padding: 56px var(--pad-x);
  text-align: center;
}
.cs-next .label { display: block; margin-bottom: 16px; }
.cs-next a { text-decoration: none; }

/* ─── RESPONSIVE ─── */
@media (max-width: 768px) {
  .cs-stats-bar { gap: 28px; }
  .cs-beforeafter { grid-template-columns: 1fr; }
  .cs-results { grid-template-columns: 1fr; }
  .cs-section { padding: 56px var(--pad-x); }
}
