/* ============================================================
   Case study pages — builds on styles.css + freelance.css
   ============================================================ */

.page-head {
  padding-top: 24px;
}

.page-head__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.page-head__name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
}

@media (max-width: 720px) {
  .page-head__inner { flex-wrap: nowrap; }
}

/* ---------------- intro ---------------- */

.cs-intro { padding-top: 72px; }

@media (min-width: 810px) {
  .cs-intro { padding-top: 112px; }
}

.cs-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  margin-bottom: 32px;
  font-size: 15px;
  color: var(--muted-3);
  transition: color 150ms ease-out;
}

@media (hover: hover) {
  .cs-back:hover { color: var(--fg); }
}

.cs-meta {
  font-size: 15px;
  color: var(--muted-3);
  margin-bottom: 16px;
}

.cs-title {
  max-width: 16ch;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(40px, 6.4vw, 88px);
  line-height: 1;
  letter-spacing: -0.035em;
}

.cs-lede {
  max-width: 38em;
  margin-top: 28px;
  font-size: clamp(17px, 1.8vw, 21px);
  line-height: 1.55;
  color: var(--muted-2);
}

.cs-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  margin: 56px 0 0;
  padding-top: 28px;
  border-top: 1px solid var(--border);
}

@media (min-width: 900px) {
  .cs-facts { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

.cs-facts dt { font-size: 14px; color: var(--muted-3); margin-bottom: 6px; }
.cs-facts dd { margin: 0; font-size: 16px; line-height: 1.45; }

/* ---------------- hero video ---------------- */

.cs-hero { padding-top: 56px; }

.cs-hero__video {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius);
  background: var(--card-bg);
}

.cs-stats { padding-top: 72px; }

/* ---------------- body ---------------- */

.cs-body {
  padding-top: 40px;
}

.cs-section {
  padding-top: 96px;
}

.cs-section h2 {
  max-width: 22ch;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(30px, 3.6vw, 48px);
  line-height: 1.1;
  letter-spacing: -0.025em;
  margin-bottom: 28px;
}

.cs-prose {
  display: grid;
  gap: 18px;
  max-width: 40em;
  font-size: 18px;
  line-height: 1.65;
  color: var(--muted-2);
}

.cs-prose strong { color: var(--fg); font-weight: 600; }

.cs-prose h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 22px;
  line-height: 1.3;
  color: var(--fg);
}

.cs-prose ul {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.cs-prose ul li {
  position: relative;
  padding-left: 26px;
}

.cs-prose ul li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.5em;
  width: 12px;
  height: 7px;
  border-left: 1.5px solid var(--accent);
  border-bottom: 1.5px solid var(--accent);
  transform: rotate(-45deg);
}

/* Decisions: text beside a whole, uncropped screenshot */
.cs-decision {
  display: grid;
  gap: 28px;
  padding-block: 40px;
  border-top: 1px solid var(--border);
}

.cs-decision:first-of-type { border-top: 0; padding-top: 8px; }

@media (min-width: 1000px) {
  .cs-decision {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: 56px;
    align-items: center;
  }
}

.cs-fig {
  margin: 0;
}

.cs-fig img {
  width: 100%;
  height: auto;
  border-radius: var(--radius-sm);
}

/* ---------------- feature loops: recorded from usecamomila.com ---------------- */

.cs-video {
  display: grid;
  place-items: center;
  padding: clamp(4px, 1.5vw, 16px);
  border-radius: var(--radius);
  background: #f7faf2; /* Camomila's page background */
}

.cs-video video {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 0;
}

.cs-phones {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 40px;
}

@media (min-width: 700px) {
  .cs-phones { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
}

.cs-phones img { width: 100%; height: auto; }

.cs-timeline {
  max-width: 40em;
  margin: 40px 0 0;
  padding: 0;
  list-style: none;
}

.cs-timeline li {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 16px;
  padding-block: 14px;
  border-bottom: 1px solid var(--border);
  font-size: 16px;
  color: var(--muted-2);
}

.cs-timeline time {
  color: var(--fg);
  font-variant-numeric: tabular-nums;
}

/* ---------------- closing CTA ---------------- */

.cs-final { padding-top: 140px; }

.cs-final__text {
  max-width: 34em;
  margin-top: -8px;
  font-size: 18px;
  line-height: 1.55;
  color: var(--muted-2);
}

.cs-final__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
