/* ============================================================
   BEYOND THE SERP — case-studies.css
   Styles for both the Case Studies listing page and the
   individual Case Study Detail pages.
   ============================================================ */

/* ─────────────────────────────────────────────────────────────
   LISTING PAGE — page hero eyebrow / heading
───────────────────────────────────────────────────────────── */
.case-studies-hero-eyebrow {
  margin-bottom: 12px;
}

.case-studies-hero-heading {
  font-size: clamp(2.4rem, 6vw, 4.5rem);
  max-width: 800px;
}


/* ─────────────────────────────────────────────────────────────
   LISTING PAGE — CARD GRID LAYOUT
───────────────────────────────────────────────────────────── */
.cs-listing-section .container-site {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.cs-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: hsl(263, 50%, 12%, 0.02);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  text-decoration: none;
  color: var(--foreground);
  box-shadow: var(--shadow-card);
  transition: border-color 0.3s;
  min-height: 360px;
}

.cs-row:hover {
  border-color: hsl(263, 73%, 52%, 0.4);
  color: var(--foreground);
}

/* ─── Logo / image panel (left col) ─────────────────────── */
.cs-logo-panel {
  position: relative;
  overflow: hidden;
  min-height: 360px;
}

/* Dot grid overlay */
.cs-logo-panel::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(0,0,0,0.3) 1px, transparent 1px);
  background-size: 20px 20px;
  opacity: 0.3;
  z-index: 1;
  pointer-events: none;
}

.cs-logo-panel-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.7s var(--ease-quart);
}

.cs-row:hover .cs-logo-panel-img {
  transform: scale(1.04);
}

.cs-logo-panel-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  z-index: 2;
}

.cs-panel-industry,
.cs-panel-period {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: rgba(0, 0, 0, 0.4);
}

.cs-logo-panel-inner {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  min-height: 360px;
  padding: 40px;
}

.cs-logo-img {
  max-height: 176px;
  width: auto;
  object-fit: contain;
}

/* ─── Content col (right) ─────────────────────────────────── */
.cs-content-col {
  padding: clamp(28px, 4vw, 48px);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.cs-tag-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  gap: 12px;
}

.cs-tag {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: hsl(263, 73%, 52%, 0.8);
}

.cs-arrow {
  color: hsl(263, 50%, 12%, 0.3);
  flex-shrink: 0;
  transition: color 0.2s, transform 0.2s;
}

.cs-arrow svg {
  display: block;
}

.cs-row:hover .cs-arrow {
  color: var(--primary);
  transform: rotate(45deg);
}

.cs-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(1.4rem, 2.5vw, 1.75rem);
  font-weight: 600;
  line-height: 1.3;
  margin: 0 0 16px;
  color: var(--foreground);
  transition: color 0.2s;
}

.cs-row:hover .cs-title {
  color: var(--primary);
}

.cs-desc {
  font-size: 0.875rem;
  color: hsl(263, 50%, 12%, 0.6);
  line-height: 1.7;
  margin: 0 0 auto;
  padding-bottom: 24px;
}

/* 4-stat grid: 2 cols on all, stretches to 4 at medium+ */
.cs-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

.cs-stat-val {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(1.15rem, 2vw, 1.5rem);
  font-weight: 700;
  background: linear-gradient(135deg, hsl(263, 73%, 52%) 0%, hsl(263, 90%, 68%) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  line-height: 1;
  display: block;
}

.cs-stat-label {
  font-size: 0.68rem;
  color: hsl(263, 50%, 12%, 0.5);
  margin-top: 4px;
  line-height: 1.4;
  display: block;
}

.cs-stat-sub {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6rem;
  color: hsl(263, 50%, 12%, 0.35);
  margin-top: 3px;
  display: block;
  line-height: 1.4;
}

@media (min-width: 992px) {
  .cs-stats {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (max-width: 767px) {
  .cs-row {
    grid-template-columns: 1fr;
  }

  .cs-logo-panel {
    min-height: 240px;
  }

  .cs-content-col {
    padding: 24px;
  }

  .cs-title {
    font-size: 1.35rem;
    line-height: 1.3;
  }
}

/* CTA block inner wrap (shared pattern) */
.cta-inner-wrap {
  position: relative;
  z-index: 1;
  max-width: 720px;
}

.cta-eyebrow {
  margin-bottom: 20px;
}

/* ─────────────────────────────────────────────────────────────
   CASE DETAIL — eyebrow labels with opacity override
───────────────────────────────────────────────────────────── */
.case-detail-eyebrow-visible {
  opacity: 1;
}

.case-detail-eyebrow-separator {
  color: hsl(263, 50%, 12%, 0.4);
  opacity: 1;
}

.case-detail-eyebrow-client {
  color: hsl(263, 50%, 12%, 0.7);
  opacity: 1;
}

/* ─────────────────────────────────────────────────────────────
   CASE DETAIL — hero heading
───────────────────────────────────────────────────────────── */
.case-detail-hero-heading {
  font-size: clamp(2rem, 5vw, 3.75rem);
  max-width: 820px;
}

/* ─────────────────────────────────────────────────────────────
   RESULTS STRIP — stat label top margin
───────────────────────────────────────────────────────────── */
.stat-label-top {
  margin-top: 8px;
}

/* ─────────────────────────────────────────────────────────────
   CHALLENGE + APPROACH section
───────────────────────────────────────────────────────────── */
.case-challenge-section {
  padding: 40px 0;
}

.case-services-eyebrow {
  margin-bottom: 16px;
}

.case-challenge-eyebrow {
  margin-bottom: 12px;
}

.case-challenge-text {
  font-size: 1.05rem;
  color: hsl(263, 50%, 12%, 0.8);
  line-height: 1.75;
  max-width: 660px;
  margin-bottom: 48px;
}

.case-approach-eyebrow {
  margin-bottom: 16px;
}

/* ─────────────────────────────────────────────────────────────
   TESTIMONIAL — center text
───────────────────────────────────────────────────────────── */
.testimonial-centered {
  text-align: center;
}

/* ─────────────────────────────────────────────────────────────
   MORE WORK section
───────────────────────────────────────────────────────────── */
.case-more-work-section {
  padding: 40px 0 80px;
}

.case-more-work-eyebrow {
  margin-bottom: 12px;
}

.case-more-work-heading {
  font-size: clamp(1.6rem, 3vw, 2.25rem);
  margin-bottom: 36px;
}

/* Caption eyebrow inside more-work cards */
.more-work-card-eyebrow {
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 6px;
}

/* ─────────────────────────────────────────────────────────────
   CASE STUDY DETAIL — HERO AREA
───────────────────────────────────────────────────────────── */
.case-detail-hero {
  padding-top: 8rem;
  padding-bottom: 5rem;
}

.case-detail-breadcrumb {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--primary);
  opacity: 0.85;
  margin-bottom: 20px;
  transition: opacity 0.2s;
}

.case-detail-breadcrumb:hover {
  opacity: 1;
}

.case-hero-img {
  border-radius: var(--radius);
  overflow: hidden;
  margin-top: 40px;
}

.case-hero-img img {
  width: 100%;
  max-height: 500px;
  object-fit: cover;
  display: block;
}


/* ─────────────────────────────────────────────────────────────
   RESULTS STRIP (3 stats)
───────────────────────────────────────────────────────────── */
.case-results-strip {
  padding: 56px 0 40px;
}

.case-results-strip .stat-value {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(2.4rem, 5vw, 3.8rem);
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1;
  background: linear-gradient(135deg, hsl(263, 73%, 52%) 0%, hsl(263, 90%, 68%) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.case-results-strip .stat-label {
  font-size: 0.8rem;
  color: hsl(263, 50%, 12%, 0.55);
  line-height: 1.45;
  margin-top: 8px;
  display: block;
}


/* ─────────────────────────────────────────────────────────────
   SERVICES SIDEBAR
───────────────────────────────────────────────────────────── */
.case-services-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.case-services-list li {
  color: var(--primary);
  font-weight: 600;
  font-size: 0.9rem;
}


/* ─────────────────────────────────────────────────────────────
   SOLUTION STEPS
───────────────────────────────────────────────────────────── */
.solution-step {
  display: flex;
  gap: 20px;
  padding: 20px 24px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: hsl(263, 73%, 52%, 0.03);
  margin-bottom: 12px;
  transition: border-color 0.2s, background 0.2s;
}

.solution-step:hover {
  border-color: hsl(263, 73%, 52%, 0.25);
  background: hsl(263, 73%, 52%, 0.06);
}

.step-num {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.72rem;
  color: var(--primary);
  flex-shrink: 0;
  padding-top: 2px;
  min-width: 24px;
  font-weight: 500;
}

.solution-step p {
  margin: 0;
  font-weight: 500;
  font-size: 0.95rem;
  line-height: 1.55;
  color: hsl(263, 50%, 12%, 0.85);
}


/* ─────────────────────────────────────────────────────────────
   TESTIMONIAL (full-width on detail page)
───────────────────────────────────────────────────────────── */
.case-testimonial {
  padding: 40px 0;
}

.case-testimonial blockquote {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(1.1rem, 2.5vw, 1.35rem);
  font-style: italic;
  line-height: 1.55;
  color: hsl(263, 50%, 12%, 0.85);
  margin: 0 0 24px;
}

.case-testimonial .open-quote {
  font-size: 3rem;
  line-height: 1;
  color: var(--primary);
  margin-bottom: 8px;
  display: block;
}


/* ─────────────────────────────────────────────────────────────
   "MORE WORK" THUMBNAIL CARDS
───────────────────────────────────────────────────────────── */
.more-work-card {
  display: block;
  text-decoration: none;
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
  height: 240px;
  transition: transform 0.4s var(--ease-quart);
}

.more-work-card:hover {
  transform: translateY(-4px);
}

.more-work-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.7s var(--ease-quart);
}

.more-work-card:hover img {
  transform: scale(1.05);
}

.more-work-card .overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(10, 5, 30, 0.85), transparent);
}

.more-work-card .caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 20px;
}

.more-work-card .caption .eyebrow {
  color: rgba(255, 255, 255, 0.5);
  margin-bottom: 6px;
}

.more-work-card .caption p {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
  margin: 0;
  line-height: 1.35;
}


/* ============================================================
   CASE STUDY DETAIL — KINSHIP AIO CITATIONS
   All component classes for the full-length detail page layout
   ============================================================ */

/* ─────────────────────────────────────────────────────────────
   HERO — eyebrow pill badge
───────────────────────────────────────────────────────────── */
.cd-hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--border);
  background: hsl(263, 10%, 97%, 0.6);
  border-radius: 9999px;
  padding: 8px 16px;
  margin-bottom: 24px;
}

/* Animated ping dot */
.cd-ping-dot {
  position: relative;
  width: 8px;
  height: 8px;
  flex-shrink: 0;
}

.cd-ping-dot::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: var(--primary);
  animation: cd-ping 1.6s ease-out infinite;
}

.cd-ping-dot::after {
  content: '';
  position: absolute;
  inset: 1px;
  border-radius: 50%;
  background: var(--primary);
}

@keyframes cd-ping {
  0%   { transform: scale(1); opacity: 0.7; }
  100% { transform: scale(2.4); opacity: 0; }
}

.cd-hero-eyebrow-text {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--primary);
}

/* ─────────────────────────────────────────────────────────────
   HERO — meta grid
───────────────────────────────────────────────────────────── */
.cd-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px 24px;
  border-top: 1px solid var(--border);
  padding-top: 24px;
  margin-top: 28px;
}

@media (min-width: 768px) {
  .cd-meta-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.cd-meta-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.58rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: hsl(263, 50%, 12%, 0.45);
  display: block;
  margin-bottom: 5px;
}

.cd-meta-value {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--foreground);
  line-height: 1.4;
}

/* ─────────────────────────────────────────────────────────────
   HERO — right panel
───────────────────────────────────────────────────────────── */
.cd-hero-panel {
  border-radius: 24px;
  border: 1px solid var(--border);
  overflow: hidden;
  aspect-ratio: 4 / 5;
  position: relative;
}

.cd-hero-panel-dot {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle at 1px 1px, #2a1a10 1px, transparent 0);
  background-size: 24px 24px;
  opacity: 0.07;
  pointer-events: none;
}

.cd-hero-panel-top {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  padding: 18px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.cd-hero-panel-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 18px 20px 22px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}

.cd-panel-meta {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: rgba(42, 26, 16, 0.55);
}

.cd-panel-num {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  font-weight: 700;
  color: #2a1a10;
  line-height: 1;
  letter-spacing: -0.02em;
}

.cd-panel-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.58rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: rgba(42, 26, 16, 0.6);
  margin-top: 4px;
}

/* ─────────────────────────────────────────────────────────────
   HEADLINE STAT CARDS
───────────────────────────────────────────────────────────── */
.cd-stat-card {
  border-radius: 16px;
  border: 1px solid var(--border);
  background: linear-gradient(160deg, rgba(255,255,255,0.92) 0%, rgba(238,240,252,0.92) 100%);
  padding: 28px;
  position: relative;
  overflow: hidden;
  transition: border-color 0.3s;
}

.cd-stat-card:hover {
  border-color: hsl(263, 73%, 52%, 0.4);
}

.cd-stat-orb {
  position: absolute;
  top: -20px;
  right: -20px;
  width: 112px;
  height: 112px;
  border-radius: 50%;
  background: hsl(263, 73%, 52%, 0.1);
  filter: blur(30px);
  pointer-events: none;
}

.cd-stat-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.cd-stat-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: hsl(263, 73%, 52%, 0.1);
  border: 1px solid hsl(263, 73%, 52%, 0.2);
  display: grid;
  place-items: center;
  color: var(--primary);
  flex-shrink: 0;
}

.cd-stat-icon svg {
  display: block;
}

.cd-stat-trend {
  color: hsl(263, 73%, 52%, 0.5);
}

.cd-stat-trend svg {
  display: block;
}

.cd-stat-value {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(2rem, 3.5vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1;
  background: linear-gradient(135deg, hsl(263, 73%, 52%) 0%, hsl(263, 90%, 68%) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  display: block;
}

.cd-stat-lbl {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1rem;
  font-weight: 500;
  color: var(--foreground);
  margin-top: 12px;
  display: block;
}

.cd-stat-sub {
  font-size: 0.75rem;
  color: hsl(263, 50%, 12%, 0.5);
  font-style: italic;
  margin-top: 4px;
  display: block;
}

/* ─────────────────────────────────────────────────────────────
   SECTION EYEBROW PILL
───────────────────────────────────────────────────────────── */
.cd-section-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid hsl(263, 73%, 52%, 0.3);
  background: hsl(263, 73%, 52%, 0.05);
  border-radius: 9999px;
  padding: 6px 12px;
  margin-bottom: 20px;
}

.cd-section-eyebrow svg {
  color: var(--primary);
  flex-shrink: 0;
}

.cd-section-eyebrow span {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--primary);
}

/* ─────────────────────────────────────────────────────────────
   PULL QUOTE
───────────────────────────────────────────────────────────── */
.cd-pull-quote {
  margin: 48px 0;
  border-radius: 24px;
  border: 1px solid hsl(263, 73%, 52%, 0.3);
  background: linear-gradient(160deg, hsl(263, 73%, 52%, 0.06) 0%, hsl(263, 10%, 97%) 100%);
  padding: 32px;
}

@media (min-width: 768px) {
  .cd-pull-quote {
    padding: 48px;
  }
}

.cd-pull-quote-icon {
  color: hsl(263, 73%, 52%, 0.4);
  margin-bottom: 20px;
}

.cd-pull-quote-icon svg {
  display: block;
}

.cd-pull-quote blockquote {
  font-family: 'Space Grotesk', sans-serif;
  font-size: clamp(1.1rem, 2.5vw, 1.5rem);
  font-style: italic;
  line-height: 1.55;
  color: hsl(263, 50%, 12%, 0.9);
  max-width: 760px;
  margin: 0;
}

/* ─────────────────────────────────────────────────────────────
   STRATEGY PILLAR CARDS
───────────────────────────────────────────────────────────── */
.cd-pillar-card {
  border-radius: 24px;
  border: 1px solid var(--border);
  background: linear-gradient(160deg, rgba(255,255,255,0.92) 0%, rgba(238,240,252,0.92) 100%);
  padding: 28px;
  display: flex;
  flex-direction: column;
  height: 100%;
  transition: border-color 0.3s;
}

.cd-pillar-card:hover {
  border-color: hsl(263, 73%, 52%, 0.4);
}

.cd-pillar-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--primary);
  border: 1px solid hsl(263, 73%, 52%, 0.3);
  background: hsl(263, 73%, 52%, 0.1);
  border-radius: 9999px;
  padding: 5px 12px;
  margin-bottom: 16px;
  width: fit-content;
}

.cd-pillar-icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: hsl(263, 73%, 52%, 0.1);
  display: grid;
  place-items: center;
  color: var(--primary);
  flex-shrink: 0;
}

.cd-pillar-icon svg {
  display: block;
}

.cd-pillar-h3 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--foreground);
  margin: 12px 0 8px;
  letter-spacing: -0.02em;
}

.cd-pillar-body {
  font-size: 0.9rem;
  color: hsl(263, 50%, 12%, 0.7);
  line-height: 1.75;
  margin-bottom: 16px;
}

.cd-pillar-checklist {
  list-style: none;
  padding: 0;
  margin: 0 0 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.cd-check-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.85rem;
  color: hsl(263, 50%, 12%, 0.7);
  line-height: 1.6;
}

.cd-check-icon {
  color: var(--primary);
  flex-shrink: 0;
  margin-top: 2px;
}

.cd-check-icon svg {
  display: block;
}

.cd-pillar-footer {
  border-top: 1px solid var(--border);
  padding-top: 20px;
  margin-top: auto;
}

.cd-pillar-footer p {
  font-size: 0.875rem;
  color: hsl(263, 50%, 12%, 0.65);
  line-height: 1.7;
  margin-bottom: 12px;
}

.cd-pillar-footer p:last-child {
  margin-bottom: 0;
}

.cd-pillar-sub-h4 {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}

.cd-pillar-sub-p {
  font-size: 0.83rem;
  color: hsl(263, 50%, 12%, 0.65);
  line-height: 1.7;
  margin-bottom: 16px;
}

.cd-pillar-sub-p:last-child {
  margin-bottom: 0;
}

/* Layer cards (inside pillar 3) */
.cd-layers {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
}

.cd-layer {
  border-radius: 12px;
  border: 1px solid var(--border);
  background: hsl(260, 40%, 99%, 0.6);
  padding: 16px;
}

.cd-layer-badge {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--primary);
  display: block;
  margin-bottom: 6px;
}

.cd-layer-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--foreground);
  margin-bottom: 6px;
}

.cd-layer-body {
  font-size: 0.83rem;
  color: hsl(263, 50%, 12%, 0.65);
  line-height: 1.65;
  margin: 0;
}

/* ─────────────────────────────────────────────────────────────
   BAR CHART BLOCK
───────────────────────────────────────────────────────────── */
.cd-bar-chart {
  border-radius: 24px;
  border: 1px solid var(--border-strong);
  background: var(--background);
  padding: 32px 40px;
}

.cd-bar-chart-header {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 28px;
}

.cd-bar-chart-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--foreground);
}

.cd-bar-chart-source {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.58rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: hsl(263, 50%, 12%, 0.4);
}

.cd-bar-rows {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.cd-bar-row {
  display: grid;
  grid-template-columns: 160px 1fr 80px;
  align-items: center;
  gap: 16px;
}

.cd-bar-domain {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--foreground);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cd-bar-domain.highlight {
  color: var(--primary);
}

.cd-bar-domain-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.cd-bar-kinship-chip {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.55rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--primary);
  border: 1px solid hsl(263, 73%, 52%, 0.35);
  background: hsl(263, 73%, 52%, 0.08);
  border-radius: 9999px;
  padding: 2px 7px;
  white-space: nowrap;
}

.cd-bar-track {
  height: 10px;
  border-radius: 9999px;
  background: var(--surface-muted);
  border: 1px solid var(--border);
  overflow: hidden;
}

.cd-bar-fill {
  height: 100%;
  border-radius: 9999px;
  background: hsl(263, 50%, 12%, 0.25);
  transition: width 1s var(--ease-quart);
}

.cd-bar-fill.highlight {
  background: linear-gradient(90deg, hsl(263, 73%, 52%) 0%, hsl(263, 90%, 68%) 100%);
}

.cd-bar-value {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  color: var(--foreground);
  text-align: right;
}

.cd-bar-value.highlight {
  background: linear-gradient(135deg, hsl(263, 73%, 52%) 0%, hsl(263, 90%, 68%) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ─────────────────────────────────────────────────────────────
   AI VISIBILITY METRICS TABLE
───────────────────────────────────────────────────────────── */
.cd-metrics-table {
  border-radius: 16px;
  border: 1px solid var(--border);
  overflow: hidden;
}

.cd-mt-head {
  display: grid;
  grid-template-columns: 1fr 120px 1fr;
  gap: 0;
  background: hsl(263, 10%, 97%);
  padding: 14px 24px;
  border-bottom: 1px solid var(--border);
}

.cd-mt-head span {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: hsl(263, 50%, 12%, 0.5);
}

.cd-mt-row {
  display: grid;
  grid-template-columns: 1fr 120px 1fr;
  gap: 0;
  padding: 18px 24px;
  align-items: center;
}

.cd-mt-row:nth-child(even) {
  background: hsl(263, 10%, 97%, 0.4);
}

.cd-mt-row:not(:last-child) {
  border-bottom: 1px solid var(--border);
}

.cd-mt-name {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 0.95rem;
  color: var(--foreground);
}

.cd-mt-val {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  background: linear-gradient(135deg, hsl(263, 73%, 52%) 0%, hsl(263, 90%, 68%) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.cd-mt-ctx {
  font-size: 0.8rem;
  color: hsl(263, 50%, 12%, 0.55);
  line-height: 1.5;
  padding-left: 16px;
}

@media (max-width: 991px) {
  .cd-mt-head {
    grid-template-columns: 1fr 100px;
  }
  .cd-mt-head .cd-mt-ctx-head {
    display: none;
  }
  .cd-mt-row {
    grid-template-columns: 1fr 100px;
  }
  .cd-mt-ctx {
    display: none;
  }
}

/* ─────────────────────────────────────────────────────────────
   TOP CITED PAGES CARDS
───────────────────────────────────────────────────────────── */
.cd-cited-card {
  border-radius: 16px;
  border: 1px solid var(--border);
  background: hsl(263, 10%, 97%, 0.4);
  padding: 20px;
  transition: border-color 0.3s;
}

.cd-cited-card:hover {
  border-color: hsl(263, 73%, 52%, 0.4);
}

.cd-cited-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 12px;
  gap: 12px;
}

.cd-cited-left {
  min-width: 0;
}

.cd-cited-num {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.62rem;
  text-transform: uppercase;
  color: hsl(263, 73%, 52%, 0.7);
  display: block;
  margin-bottom: 4px;
}

.cd-cited-slug {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78rem;
  color: var(--foreground);
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cd-cited-right {
  text-align: right;
  flex-shrink: 0;
}

.cd-cited-count {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  line-height: 1;
  background: linear-gradient(135deg, hsl(263, 73%, 52%) 0%, hsl(263, 90%, 68%) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  display: block;
}

.cd-cited-sub {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.56rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: hsl(263, 50%, 12%, 0.4);
  display: block;
  margin-top: 3px;
}

.cd-cited-bar {
  height: 6px;
  border-radius: 9999px;
  background: var(--surface-muted);
}

.cd-cited-bar-fill {
  height: 100%;
  border-radius: 9999px;
  background: linear-gradient(90deg, hsl(263, 73%, 52%) 0%, hsl(263, 90%, 68%) 100%);
}

/* ─────────────────────────────────────────────────────────────
   KEY TAKEAWAYS
───────────────────────────────────────────────────────────── */
.cd-takeaway {
  border-radius: 16px;
  border: 1px solid var(--border);
  background: var(--background);
  padding: 24px 28px;
  display: flex;
  gap: 20px;
  align-items: flex-start;
  transition: border-color 0.3s;
}

.cd-takeaway:hover {
  border-color: hsl(263, 73%, 52%, 0.4);
}

.cd-num-badge {
  width: 48px;
  height: 48px;
  min-width: 48px;
  border-radius: 16px;
  background: linear-gradient(135deg, hsl(263, 73%, 52%) 0%, hsl(263, 73%, 52%, 0.7) 100%);
  color: #fff;
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  display: grid;
  place-items: center;
  box-shadow: 0 4px 16px hsl(263, 73%, 52%, 0.35);
}

.cd-takeaway-body {
  flex: 1;
  min-width: 0;
}

.cd-takeaway-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--foreground);
  margin-bottom: 10px;
  line-height: 1.3;
  letter-spacing: -0.01em;
}

.cd-takeaway-body p {
  font-size: 0.9rem;
  color: hsl(263, 50%, 12%, 0.7);
  line-height: 1.75;
  margin-bottom: 10px;
}

.cd-takeaway-body p:last-child {
  margin-bottom: 0;
}

/* ─────────────────────────────────────────────────────────────
   ABOUT BEYOND THE SERP CARD
───────────────────────────────────────────────────────────── */
.cd-about {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  border: 1px solid hsl(263, 73%, 52%, 0.3);
  background: linear-gradient(160deg, hsl(263, 73%, 52%, 0.15) 0%, hsl(263, 10%, 97%) 40%, hsl(260, 40%, 99%) 100%);
  padding: clamp(32px, 5vw, 56px) clamp(28px, 6vw, 64px);
}

.cd-about-orb1 {
  position: absolute;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  background: hsl(263, 73%, 52%, 0.2);
  filter: blur(60px);
  top: -80px;
  right: -80px;
  pointer-events: none;
}

.cd-about-orb2 {
  position: absolute;
  width: 280px;
  height: 280px;
  border-radius: 50%;
  background: hsl(263, 73%, 52%, 0.1);
  filter: blur(60px);
  bottom: -80px;
  left: -80px;
  pointer-events: none;
}

.cd-about-inner {
  position: relative;
  z-index: 1;
}

.cd-about h2 {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  margin-bottom: 20px;
}

.cd-about p {
  font-size: 1rem;
  color: hsl(263, 50%, 12%, 0.75);
  line-height: 1.75;
  max-width: 720px;
  margin-bottom: 16px;
}

.cd-about p:last-of-type {
  margin-bottom: 28px;
}

.cd-about-disclaimer {
  border-top: 1px solid var(--border);
  padding-top: 20px;
  margin-top: 28px;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  max-width: 760px;
}

.cd-about-disclaimer p {
  font-size: 0.75rem;
  font-style: italic;
  color: hsl(263, 50%, 12%, 0.45);
  margin: 0;
  line-height: 1.6;
}

.cd-about-disclaimer svg {
  color: hsl(263, 50%, 12%, 0.35);
  flex-shrink: 0;
  margin-top: 2px;
}

/* ─────────────────────────────────────────────────────────────
   BODY TEXT UTILITIES (shared across reading sections)
───────────────────────────────────────────────────────────── */
.cd-body-text {
  font-size: 1rem;
  color: hsl(263, 50%, 12%, 0.75);
  line-height: 1.8;
  /* max-width: 760px; */
  margin-bottom: 20px;
}

.cd-body-text:last-child {
  margin-bottom: 0;
}

.cd-section-h2 {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  margin-bottom: 24px;
  letter-spacing: -0.025em;
}

/* ─────────────────────────────────────────────────────────────
   SURFACE SECTION BG
───────────────────────────────────────────────────────────── */
.cd-surface-section {
  background: hsl(263, 10%, 97%, 0.3);
}

/* ─────────────────────────────────────────────────────────────
   RESPONSIVE OVERRIDES
───────────────────────────────────────────────────────────── */
@media (max-width: 991px) {
  .cd-meta-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .cd-bar-chart {
    padding: 24px;
  }
  .cd-bar-row {
    grid-template-columns: 130px 1fr 70px;
    gap: 10px;
  }
}

@media (max-width: 767px) {
  .cd-hero-panel {
    aspect-ratio: auto;
    min-height: 280px;
  }
  .cd-pull-quote {
    padding: 24px;
    margin: 32px 0;
  }
  .cd-takeaway {
    flex-direction: column;
    gap: 14px;
  }
  .cd-bar-chart {
    padding: 20px;
  }
  .cd-bar-row {
    grid-template-columns: 110px 1fr 60px;
    gap: 8px;
    font-size: 0.85rem;
  }
  .cd-about {
    padding: 32px 24px;
  }
}
/* ═══════════════════════════════════════════════════════════════
   CS-* CLASS ALIASES
   Template (single-bts_case_study.php) uses cs-* prefix;
   original CSS used cd-* for detail elements — aliases added.
═══════════════════════════════════════════════════════════════ */

/* Hero */
.cs-hero {
  position: relative;
  overflow: hidden;
}

.cs-h1 {
  font-size: clamp(2rem, 5vw, 3.75rem);
  line-height: 1.1;
  margin: 12px 0 16px;
}

.cs-hero-subhead {
  font-size: 1.1rem;
  color: hsl(263, 50%, 12%, 0.7);
  line-height: 1.75;
  margin-top: 16px;
  max-width: 520px;
}

/* Meta chips row */
.cs-meta-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
}

.cs-meta-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 14px;
  border-radius: 9999px;
  border: 1px solid var(--border);
  background: var(--gradient-card);
  backdrop-filter: blur(8px);
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.65rem;
  color: hsl(263, 50%, 12%, 0.6);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

/* Hero right panel (glass card with logo + stats) */
.cs-hero-panel {
  border-radius: var(--radius);
  border: 1px solid hsl(263, 73%, 52%, 0.2);
  padding: clamp(24px, 4vw, 40px);
  backdrop-filter: blur(12px);
}

.cs-client-logo-wrap {
  border-radius: 8px;
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 28px;
  min-height: 80px;
}

.cs-client-logo-wrap img {
  max-width: 160px;
  height: auto;
  display: block;
}

.cs-panel-stats {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}

.cs-panel-stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.cs-panel-stat-value {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.9rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--primary) 0%, hsl(263, 90%, 68%) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
}

.cs-panel-stat-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: hsl(263, 50%, 12%, 0.5);
}

/* Stats section — 4 metric cards */
.cs-stats-section {
  border-top: 1px solid var(--border);
}

.cs-stat-card {
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--gradient-card);
  backdrop-filter: blur(8px);
  transition: transform 0.3s var(--ease-quart), border-color 0.3s;
}

.cs-stat-card:hover {
  transform: translateY(-3px);
  border-color: hsl(263, 73%, 52%, 0.35);
}

.cs-stat-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: hsl(263, 73%, 52%, 0.1);
  color: var(--primary);
  display: grid;
  place-items: center;
  margin: 0 auto 12px;
}

.cs-stat-value {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 2rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--primary) 0%, hsl(263, 90%, 68%) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  margin-bottom: 6px;
}

.cs-stat-card .cs-stat-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: hsl(263, 50%, 12%, 0.55);
}

.cs-stat-card .cs-stat-sub {
  font-size: 0.8rem;
  color: hsl(263, 50%, 12%, 0.42);
  margin-top: 6px;
}

/* Body content section */
.cs-body-section {
  border-top: 1px solid var(--border);
}

.cs-body-content {
  /* inherits .wysiwyg styles from common.css */
}

/* Takeaways section */
.cs-takeaways-section {
  border-top: 1px solid var(--border);
}

.cs-takeaways-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 40px;
}

.cs-takeaway {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  padding: 24px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--gradient-card);
  transition: border-color 0.3s;
}

.cs-takeaway:hover {
  border-color: hsl(263, 73%, 52%, 0.3);
}

.cs-takeaway-num {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 2rem;
  font-weight: 700;
  color: hsl(263, 73%, 52%, 0.22);
  line-height: 1;
  flex-shrink: 0;
  width: 48px;
  text-align: center;
  padding-top: 2px;
}

.cs-takeaway-title {
  font-family: 'Space Grotesk', sans-serif;
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--foreground);
}

.cs-takeaway-body {
  font-size: 0.9rem;
  color: hsl(263, 50%, 12%, 0.65);
  line-height: 1.65;
  margin: 0;
}

/* About client block */
.cs-about-client {
  border-radius: var(--radius);
}

/* Disclaimer */
.cs-disclaimer {
  font-size: 0.8rem;
  color: hsl(263, 50%, 12%, 0.4);
  margin: 16px 0 32px;
  line-height: 1.6;
}
