/* === Bridge Digital — case studies styles ==================================
   Loaded by:
     - src/pages/cases/index.html  (case index landing)
     - src/pages/cases/*.html      (per-case detail pages)
     - src/pages/index.html        (homepage 'What We've Built' grid)
     - src/pages/your-business.html (services landing + featured grid)

   Uses CSS variables from site.css (--yellow, --blue, --muted, --border,
   --gray, --black/--white). Does not redeclare them.
   ----------------------------------------------------------------------- */

/* ===== SECTION-LABEL EYEBROW (matches home.css pattern) ================= */
.cases-grid .section-label,
.cases-index-hero .section-label,
.cases-index-body .section-label,
.case-section .section-label,
.case-detail-brand-tag {
  font-family: 'Geist Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 11px;
  letter-spacing: 3px;
  color: var(--yellow);
  text-transform: uppercase;
}

/* ===== CASE-CARD GRID (shared by index, home usecases, your-business) === */
.cases-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 56px;
}

.case-card {
  display: flex;
  flex-direction: column;
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 6px;
  text-decoration: none;
  color: inherit;
  overflow: hidden;
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}
.case-card:hover {
  transform: translateY(-4px);
  border-color: var(--yellow);
  box-shadow: 0 12px 32px rgba(16, 44, 57, 0.10);
}
.case-card:focus-visible {
  outline: 2px solid var(--yellow);
  outline-offset: 3px;
}

.case-card-image {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  background: var(--gray);
}

.case-card-body {
  padding: 24px 24px 28px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.case-card-tag {
  font-family: 'Geist Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 10px;
  letter-spacing: 2.5px;
  color: var(--muted);
  text-transform: uppercase;
  margin-bottom: 12px;
}

.case-card-title {
  font-family: 'Onest', sans-serif;
  font-size: 22px;
  font-weight: 700;
  line-height: 1.25;
  color: var(--blue);
  margin-bottom: 10px;
  letter-spacing: -0.01em;
}

.case-card-hook {
  font-size: 14px;
  line-height: 1.55;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.cases-more-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 48px;
  padding: 14px 0;
  color: var(--yellow);
  text-decoration: none;
  font-family: 'Geist Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13px;
  letter-spacing: 2px;
  text-transform: uppercase;
  border-bottom: 1px solid rgba(246, 146, 32, 0.25);
  transition: color 0.2s, border-color 0.2s;
  align-self: flex-start;
}
.cases-more-link:hover {
  color: var(--blue);
  border-color: var(--blue);
}

/* ===== CASES INDEX PAGE FRAME ========================================== */
.cases-index-hero {
  padding: 140px 6vw 60px;
}
.cases-index-hero-inner {
  max-width: 1100px;
  margin: 0 auto;
}
.cases-index-hero h1 {
  font-family: 'Onest', sans-serif;
  font-size: clamp(48px, 7vw, 84px);
  line-height: 1.0;
  margin: 24px 0 28px;
  letter-spacing: -0.01em;
  color: var(--blue);
}
.cases-index-hero p {
  font-size: clamp(16px, 1.6vw, 19px);
  line-height: 1.6;
  color: var(--muted);
  max-width: 640px;
  font-weight: 300;
}

.cases-index-body {
  padding: 20px 6vw 100px;
}
.cases-index-body-inner {
  max-width: 1100px;
  margin: 0 auto;
}

/* ===== CASE DETAIL PAGE =============================================== */
.case-back-link-wrap {
  padding: 110px 6vw 0;
}
.case-back-link-inner {
  max-width: 1100px;
  margin: 0 auto;
}
.case-back-link {
  color: var(--muted);
  font-family: 'Geist Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px;
  letter-spacing: 2px;
  text-transform: uppercase;
  text-decoration: none;
  transition: color 0.2s;
}
.case-back-link:hover { color: var(--yellow); }

.case-detail-hero {
  position: relative;
  margin: 24px 6vw 0;
  background: var(--blue);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border-radius: 10px;
  overflow: hidden;
  min-height: 460px;
  display: flex;
  align-items: center;
}
.case-detail-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(16, 44, 57, 0.86) 0%, rgba(16, 44, 57, 0.62) 100%);
  z-index: 1;
}
.case-detail-hero-inner {
  position: relative;
  z-index: 2;
  max-width: 1100px;
  margin: 0 auto;
  width: 100%;
  padding: 80px 5vw;
  color: #ffffff;
}
.case-detail-brand-tag {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 28px;
  color: var(--yellow);
}
.case-detail-brand-tag::before {
  content: '';
  width: 32px;
  height: 2px;
  background: var(--yellow);
}
.case-detail-h1 {
  font-family: 'Onest', sans-serif;
  font-size: clamp(48px, 7.5vw, 92px);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: -0.02em;
  margin-bottom: 24px;
  color: #ffffff;
}
.case-detail-tagline {
  font-size: clamp(17px, 1.8vw, 21px);
  line-height: 1.5;
  font-weight: 300;
  color: rgba(255, 255, 255, 0.88);
  max-width: 720px;
}

/* ===== STACK / INTEGRATIONS STRIP ====================================== */
.case-stack {
  padding: 56px 6vw 32px;
}
.case-stack-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.case-stack-label {
  font-family: 'Geist Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 10px;
  letter-spacing: 3px;
  color: var(--muted);
  text-transform: uppercase;
}
.case-stack-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.case-stack-badge {
  display: inline-block;
  padding: 8px 14px;
  border: 1px solid var(--border);
  border-radius: 4px;
  font-size: 13px;
  color: var(--blue);
  background: var(--gray);
  letter-spacing: 0.2px;
}
.case-stack-badge.primary {
  border-color: rgba(246, 146, 32, 0.35);
  background: rgba(246, 146, 32, 0.08);
  color: var(--blue);
  font-weight: 600;
}

/* ===== CONTENT BLOCKS (challenge / solution) =========================== */
.case-section {
  padding: 56px 6vw;
}
.case-section-inner {
  max-width: 1100px;
  margin: 0 auto;
}
.case-section h2 {
  font-family: 'Onest', sans-serif;
  font-size: clamp(28px, 3.4vw, 40px);
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--blue);
  margin: 16px 0 24px;
  max-width: 820px;
}
.case-section p {
  font-size: 17px;
  line-height: 1.75;
  color: var(--blue);
  font-weight: 300;
  max-width: 780px;
}
.case-section p strong {
  font-weight: 600;
  color: var(--blue);
}
.case-section + .case-section {
  padding-top: 0;
}

.case-block {
  border-left: 3px solid var(--yellow);
  padding: 4px 0 4px 24px;
  margin-top: 28px;
}
.case-block-label {
  font-family: 'Geist Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 10px;
  letter-spacing: 3px;
  color: var(--yellow);
  text-transform: uppercase;
  display: block;
  margin-bottom: 6px;
}

/* ===== RESULTS BAR ===================================================== */
.case-results {
  margin: 32px 6vw;
  background: var(--blue);
  border-radius: 10px;
  padding: 56px 6vw;
}
.case-results-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 32px;
}
.case-result {
  color: #ffffff;
}
.case-result-num {
  display: block;
  font-family: 'Onest', sans-serif;
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--yellow);
  line-height: 1;
  margin-bottom: 12px;
}
.case-result-label {
  font-size: 14px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.78);
  display: block;
}

/* ===== FINAL CTA (per-case) ============================================ */
.case-final-cta {
  padding: 80px 6vw 120px;
  text-align: center;
}
.case-final-cta-inner {
  max-width: 720px;
  margin: 0 auto;
}
.case-final-cta h2 {
  font-family: 'Onest', sans-serif;
  font-size: clamp(28px, 3.4vw, 40px);
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--blue);
  margin-bottom: 32px;
}
.case-final-cta p {
  font-size: 16px;
  line-height: 1.6;
  color: var(--muted);
  margin-bottom: 32px;
}

/* ===== YOUR-BUSINESS PAGE (extends shared patterns) ==================== */
.yb-hero {
  padding: 150px 6vw 70px;
}
.yb-hero-inner {
  max-width: 1100px;
  margin: 0 auto;
}
.yb-hero h1 {
  font-family: 'Onest', sans-serif;
  font-size: clamp(52px, 8vw, 96px);
  line-height: 0.98;
  letter-spacing: -0.02em;
  color: var(--blue);
  margin: 24px 0 32px;
}
.yb-hero h1 em {
  font-style: normal;
  color: var(--yellow);
  display: block;
}
.yb-hero p {
  font-size: clamp(17px, 1.8vw, 21px);
  line-height: 1.6;
  color: var(--muted);
  max-width: 680px;
  font-weight: 300;
  margin-bottom: 36px;
}

.yb-scope {
  padding: 80px 6vw;
  background: var(--gray);
}
.yb-scope-inner {
  max-width: 1100px;
  margin: 0 auto;
}
.yb-scope h2 {
  font-family: 'Onest', sans-serif;
  font-size: clamp(32px, 4.5vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.01em;
  color: var(--blue);
  margin: 18px 0 56px;
  max-width: 820px;
}
.yb-scope-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}
.yb-scope-card {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 32px;
}
.yb-scope-card h3 {
  font-family: 'Onest', sans-serif;
  font-size: 20px;
  font-weight: 600;
  color: var(--blue);
  margin-bottom: 12px;
}
.yb-scope-card p {
  font-size: 15px;
  line-height: 1.6;
  color: var(--muted);
}

.yb-engage {
  padding: 80px 6vw;
}
.yb-engage-inner {
  max-width: 1100px;
  margin: 0 auto;
}
.yb-engage h2 {
  font-family: 'Onest', sans-serif;
  font-size: clamp(32px, 4.5vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.01em;
  color: var(--blue);
  margin: 18px 0 56px;
  max-width: 820px;
}
.yb-engage-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}
.yb-engage-card {
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 36px 28px;
  background: #ffffff;
}
.yb-engage-card h3 {
  font-family: 'Onest', sans-serif;
  font-size: 22px;
  font-weight: 700;
  color: var(--blue);
  margin-bottom: 16px;
}
.yb-engage-card p {
  font-size: 15px;
  line-height: 1.65;
  color: var(--muted);
}

.yb-platforms {
  padding: 60px 6vw 80px;
  background: var(--blue);
  color: #ffffff;
}
.yb-platforms-inner {
  max-width: 1100px;
  margin: 0 auto;
}
.yb-platforms h2 {
  font-family: 'Onest', sans-serif;
  font-size: clamp(28px, 3.5vw, 42px);
  line-height: 1.1;
  color: #ffffff;
  margin: 16px 0 24px;
  max-width: 820px;
}
.yb-platforms p {
  font-size: 17px;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.82);
  max-width: 780px;
  font-weight: 300;
}
.yb-platforms-list {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}
.yb-platforms-list span {
  padding: 10px 18px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.05);
  font-size: 13px;
  letter-spacing: 0.4px;
  color: #ffffff;
}

.yb-cases {
  padding: 80px 6vw;
}
.yb-cases-inner {
  max-width: 1100px;
  margin: 0 auto;
}
.yb-cases h2 {
  font-family: 'Onest', sans-serif;
  font-size: clamp(32px, 4.5vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.01em;
  color: var(--blue);
  margin: 18px 0 24px;
  max-width: 820px;
}
.yb-cases p {
  font-size: 17px;
  line-height: 1.6;
  color: var(--muted);
  max-width: 720px;
  font-weight: 300;
}

/* ===== RESPONSIVE ====================================================== */
@media (max-width: 900px) {
  .cases-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
  .case-detail-hero {
    min-height: 380px;
    margin: 16px 4vw 0;
  }
  .case-detail-hero-inner {
    padding: 56px 5vw;
  }
  .case-back-link-wrap {
    padding: 100px 4vw 0;
  }
  .yb-scope-grid,
  .yb-engage-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .cases-grid {
    grid-template-columns: 1fr;
  }
  .case-detail-hero {
    border-radius: 0;
    margin: 16px 0 0;
  }
  .case-detail-hero-inner {
    padding: 48px 6vw;
  }
  .case-detail-h1 {
    font-size: clamp(38px, 9vw, 56px);
  }
  .case-results {
    margin: 24px 0;
    border-radius: 0;
  }
  .cases-index-hero {
    padding: 110px 6vw 32px;
  }
  .yb-hero {
    padding: 120px 6vw 48px;
  }
}
