/* DCM2 v2 visual case-study modules */

.hero-role {
  max-width: 980px;
  margin: 34px 0 0;
  padding: 24px;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 24px;
  background: rgba(0,0,0,0.34);
  backdrop-filter: blur(18px);
}
.hero-role .eyebrow {
  display: block;
  margin-bottom: 10px;
}
.hero-role strong {
  display: block;
  margin-bottom: 10px;
  color: var(--text);
  font-size: clamp(1.1rem, 1.6vw, 1.35rem);
  line-height: 1.18;
  letter-spacing: -0.03em;
}
.hero-role p {
  color: var(--text-dim);
  font-size: 0.96rem;
  line-height: 1.55;
}
.hero-role-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}
.cs-hero .hero-role-tags {
  max-width: 980px;
  margin-top: 22px;
}
.hero-role-tags span {
  padding: 6px 10px;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 999px;
  color: var(--text-dim);
  background: rgba(255,255,255,0.045);
  font: 500 0.72rem/1 "JetBrains Mono", monospace;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.card-icon {
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 14px;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.09), rgba(255,255,255,0.02)),
    rgba(10,132,255,0.1);
  color: #91c8ff;
  font-family: 'Material Symbols Outlined';
  font-size: 1.45rem;
  font-weight: normal;
  line-height: 1;
  font-style: normal;
  font-feature-settings: 'liga';
  -webkit-font-feature-settings: 'liga';
  -webkit-font-smoothing: antialiased;
  font-variation-settings: 'FILL' 0, 'wght' 500, 'GRAD' 0, 'opsz' 24;
}
.material-symbols-outlined {
  font-family: 'Material Symbols Outlined';
  font-weight: normal;
  font-style: normal;
  font-size: 1.35rem;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  white-space: nowrap;
  direction: ltr;
  font-feature-settings: 'liga';
  -webkit-font-feature-settings: 'liga';
  -webkit-font-smoothing: antialiased;
  font-variation-settings: 'FILL' 0, 'wght' 500, 'GRAD' 0, 'opsz' 24;
}
.card-icon .material-symbols-outlined {
  font-size: 1.45rem;
}

.visual-slot {
  overflow: hidden;
  border: 1px dashed rgba(255,255,255,0.22);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, rgba(255,255,255,0.035), rgba(255,255,255,0.01));
}
.visual-slot-frame {
  display: grid;
  place-items: center;
  min-height: 320px;
  padding: 32px;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.06), transparent 45%),
    rgba(0,0,0,0.22);
}
.visual-slot-frame.has-image {
  padding: 0;
  overflow: hidden;
  background: #fff;
}
.visual-slot-frame.has-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.mybambu-visual .visual-slot-frame.has-image img {
  object-fit: cover;
  object-position: calc(50% + 50px) center;
  transform: scale(1);
}
.heat-visual .visual-slot-frame.has-image {
  height: clamp(240px, 30vw, 340px);
  min-height: 0;
  background: #050507;
}
.heat-visual .visual-slot-frame.has-image img {
  width: 88%;
  height: 88%;
  object-fit: cover;
  object-position: center;
}
.greenroads-visual .visual-slot-frame.has-image img {
  object-position: calc(50% + 36px) center;
}
.visual-slot-frame span {
  max-width: 28ch;
  color: rgba(255,255,255,0.72);
  font: 500 0.82rem/1.5 "JetBrains Mono", monospace;
  letter-spacing: 0.08em;
  text-align: center;
  text-transform: uppercase;
}
.visual-slot figcaption {
  padding: 20px 22px 24px;
  color: var(--text-dim);
  font-size: 0.95rem;
  line-height: 1.5;
}
.visual-slot figcaption strong {
  display: block;
  margin-bottom: 8px;
  color: var(--text);
  font-size: 1rem;
}

.visual-narrative {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 28px;
  align-items: stretch;
  margin: 32px 0;
}
.visual-narrative .narrative,
.visual-narrative .visual-slot {
  margin: 0;
}
.visual-narrative .visual-slot,
.visual-research .visual-slot {
  display: flex;
  flex-direction: column;
  height: 100%;
}
.visual-narrative .visual-slot-frame {
  flex: 1;
  min-height: 0;
}

.visual-research {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: 28px;
  align-items: start;
  margin: 56px 0 32px;
}
.visual-research .section-head {
  margin: 0 0 28px;
}
.visual-research .tri-grid {
  grid-template-columns: 1fr;
}
.visual-research .visual-slot {
  align-self: auto;
}

.paired-narratives {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
  margin: 32px 0;
}
.paired-narratives .narrative {
  margin: 0;
}

.proof-note {
  margin: 40px 0 0;
  padding: 22px 24px;
  border-left: 2px solid var(--accent);
  background: rgba(10,132,255,0.08);
  color: var(--text-dim);
  font-size: 0.98rem;
  line-height: 1.55;
}

@media (max-width: 920px) {
  .visual-narrative,
  .visual-research,
  .paired-narratives {
    grid-template-columns: 1fr;
  }
  .visual-narrative .visual-slot-frame.has-image,
  .visual-research .visual-slot-frame.has-image {
    min-height: clamp(240px, 64vw, 380px);
  }
  .visual-narrative .visual-slot-frame.has-image img,
  .visual-research .visual-slot-frame.has-image img {
    min-height: 100%;
  }
  .visual-research .visual-slot {
    position: static;
  }
}

@media (min-width: 1024px) and (max-height: 1150px) {
  body:has(.cs-hero) section {
    padding-top: 88px;
    padding-bottom: 88px;
  }

  body:has(.cs-hero) .cs-hero {
    min-height: auto;
    padding-top: 96px;
    padding-bottom: 46px;
  }

  body:has(.cs-hero) .cs-back {
    margin-bottom: 18px;
  }

  body:has(.cs-hero) .cs-tag {
    margin-bottom: 14px;
  }

  body:has(.cs-hero) .cs-hero h1 {
    font-size: clamp(2.85rem, 5.1vw, 4.75rem);
    margin-bottom: 14px;
  }

  body:has(.cs-hero) .cs-hero .sub {
    max-width: 68ch;
    margin-bottom: 18px;
    line-height: 1.32;
  }

  body:has(.cs-hero) .cs-hero .hero-role-tags {
    margin-top: 14px;
  }

  body:has(.cs-hero) .cs-meta {
    margin-top: 24px;
    padding-top: 18px;
    gap: 18px 28px;
  }

  body:has(.cs-hero) .section-head {
    margin-bottom: 44px;
  }

  body:has(.cs-hero) .story-grid,
  body:has(.cs-hero) .tri-grid,
  body:has(.cs-hero) .metrics-grid {
    gap: 20px;
  }

  body:has(.cs-hero) .story-card,
  body:has(.cs-hero) .tri-card {
    padding: 28px;
  }

  body:has(.cs-hero) .story-card h3 {
    font-size: 1.42rem;
  }

  body:has(.cs-hero) .story-card p,
  body:has(.cs-hero) .tri-card p {
    line-height: 1.48;
  }

  body:has(.cs-hero) .narrative {
    margin: 24px 0;
    padding: 36px;
  }

  body:has(.cs-hero) .narrative h3 {
    font-size: clamp(1.45rem, 2.2vw, 2.15rem);
    margin-bottom: 16px;
  }

  body:has(.cs-hero) .narrative p {
    font-size: 1rem;
    line-height: 1.5;
  }

  body:has(.cs-hero) .visual-narrative,
  body:has(.cs-hero) .visual-research,
  body:has(.cs-hero) .paired-narratives {
    gap: 22px;
    margin-top: 28px;
    margin-bottom: 28px;
  }

  body:has(.cs-hero) .visual-narrative .narrative,
  body:has(.cs-hero) .visual-narrative .visual-slot,
  body:has(.cs-hero) .visual-research .visual-slot {
    margin: 0;
  }

  body:has(.cs-hero) .visual-slot-frame {
    min-height: 270px;
    padding: 28px;
  }

  body:has(.cs-hero) .visual-slot-frame.has-image {
    padding: 0;
  }

  body:has(.cs-hero) .visual-research .visual-slot-frame {
    min-height: clamp(330px, 38vh, 430px);
  }

  body:has(.cs-hero) .visual-research {
    align-items: stretch;
  }

  body:has(.cs-hero) .visual-research .visual-slot {
    align-self: stretch;
  }

  body:has(.cs-hero) .visual-research .visual-slot-frame {
    flex: 1;
  }

  body:has(.cs-hero) .visual-slot figcaption {
    padding: 18px 20px 20px;
  }

  body:has(.cs-hero) .pipeline {
    margin: 42px 0;
    padding: 34px;
  }

  body:has(.cs-hero) .pullquote {
    margin: 42px 0;
    padding: 36px;
  }

  body:has(.cs-hero) .proof-note {
    margin-top: 28px;
    padding: 18px 22px;
  }

  body:has(.cs-hero) .metric {
    padding: 24px 0;
  }

  body:has(.cs-hero) .cta-section {
    padding-top: 96px;
    padding-bottom: 96px;
  }
}
