/* ============================================================
   CASE STUDIES — hub + pages individuelles
   ============================================================ */

.cs-page { background: #FFF9F0; color: #001A17; }

/* ==================== HUB ==================== */
.cs-hub-hero {
  background: linear-gradient(135deg, #0B1F1C 0%, #0F3330 55%, #1A4A42 100%);
  color: #FFF9F0;
  padding: clamp(72px, 10vw, 140px) 0 clamp(64px, 9vw, 120px);
  position: relative;
  overflow: hidden;
}
.cs-hub-hero::before {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(circle at 80% 30%, rgba(0, 150, 136, 0.25), transparent 55%);
  pointer-events: none;
}
.cs-hub-hero .container { position: relative; z-index: 1; max-width: 820px; }

.cs-hub-kicker {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #7EE0D0;
  padding: 6px 14px;
  border: 1px solid rgba(126, 224, 208, 0.35);
  border-radius: 999px;
  background: rgba(126, 224, 208, 0.08);
  margin-bottom: 24px;
}
.cs-hub-title {
  font-family: var(--heading, "Montserrat", sans-serif);
  font-size: clamp(2.2rem, 5.5vw, 3.8rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
  font-weight: 900;
  margin: 0 0 20px;
  color: #FFF9F0;
}
.cs-hub-sub {
  font-size: clamp(1rem, 1.5vw, 1.15rem);
  line-height: 1.7;
  color: rgba(255, 249, 240, 0.78);
  max-width: 620px;
  margin: 0;
}

.cs-hub-list-section {
  padding: clamp(56px, 8vw, 96px) 0;
}
.cs-hub-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 28px;
}
.cs-hub-card {
  background: #fff;
  border: 1px solid rgba(0, 26, 23, 0.08);
  border-radius: 18px;
  overflow: hidden;
  transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease;
}
.cs-hub-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 40px -16px rgba(0, 26, 23, 0.15);
  border-color: rgba(0, 150, 136, 0.25);
}
.cs-hub-card-link { text-decoration: none; color: inherit; display: block; }
.cs-hub-card-visual {
  aspect-ratio: 16 / 10;
  background: #F0F2F0;
  overflow: hidden;
}
.cs-hub-card-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}
.cs-hub-card:hover .cs-hub-card-visual img { transform: scale(1.04); }

.cs-hub-card-body { padding: 26px 26px 24px; }
.cs-hub-card-kicker {
  display: block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #009688;
  margin-bottom: 10px;
}
.cs-hub-card-title {
  font-family: var(--heading, "Montserrat", sans-serif);
  font-size: 1.35rem;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 0 0 12px;
  color: #001A17;
}
.cs-hub-card-intro {
  font-size: 0.92rem;
  line-height: 1.6;
  color: rgba(0, 26, 23, 0.65);
  margin: 0 0 16px;
}
.cs-hub-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 20px;
}
.cs-tag {
  font-size: 0.72rem;
  font-weight: 500;
  padding: 4px 10px;
  border-radius: 6px;
  background: rgba(0, 150, 136, 0.08);
  color: #007A6E;
}
.cs-hub-card-cta {
  font-size: 0.9rem;
  font-weight: 600;
  color: #009688;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.cs-hub-cta {
  background: linear-gradient(135deg, #009688 0%, #00796B 100%);
  color: #FFF9F0;
  padding: clamp(56px, 7vw, 88px) 0;
}
.cs-hub-cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
}
.cs-hub-cta h2 {
  font-family: var(--heading, "Montserrat", sans-serif);
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0 0 8px;
}
.cs-hub-cta p { font-size: 1rem; opacity: 0.85; margin: 0; max-width: 540px; }
.cs-hub-cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 28px;
  background: #FFF9F0;
  color: #001A17;
  font-family: var(--heading, "Montserrat", sans-serif);
  font-weight: 700;
  font-size: 0.95rem;
  text-decoration: none;
  border-radius: 12px;
  transition: transform .2s ease, box-shadow .2s ease;
  white-space: nowrap;
}
.cs-hub-cta-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px -12px rgba(0, 0, 0, 0.3);
}

/* ==================== CASE STUDY PAGE ==================== */
.cs-detail-hero {
  background: linear-gradient(135deg, #0B1F1C 0%, #0F3330 55%, #1A4A42 100%);
  color: #FFF9F0;
  padding: clamp(56px, 8vw, 100px) 0 clamp(40px, 6vw, 72px);
  position: relative;
  overflow: hidden;
}
.cs-detail-hero::before {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(circle at 85% 25%, rgba(0, 150, 136, 0.22), transparent 50%);
  pointer-events: none;
}
.cs-detail-hero .container { position: relative; z-index: 1; max-width: 900px; }

.cs-detail-breadcrumb {
  display: flex;
  gap: 10px;
  font-size: 0.82rem;
  margin-bottom: 24px;
  color: rgba(255, 249, 240, 0.6);
}
.cs-detail-breadcrumb a { color: #7EE0D0; text-decoration: none; }
.cs-detail-breadcrumb a:hover { text-decoration: underline; }

.cs-detail-kicker {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #7EE0D0;
  padding: 6px 14px;
  border: 1px solid rgba(126, 224, 208, 0.35);
  border-radius: 999px;
  background: rgba(126, 224, 208, 0.08);
  margin-bottom: 20px;
}
.cs-detail-title {
  font-family: var(--heading, "Montserrat", sans-serif);
  font-size: clamp(1.9rem, 4.5vw, 3.2rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  font-weight: 900;
  margin: 0 0 22px;
  color: #FFF9F0;
}
.cs-detail-intro {
  font-size: clamp(1rem, 1.5vw, 1.15rem);
  line-height: 1.7;
  color: rgba(255, 249, 240, 0.8);
  margin: 0 0 40px;
  max-width: 720px;
}
.cs-detail-meta {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  padding-top: 32px;
  border-top: 1px solid rgba(255, 249, 240, 0.12);
  max-width: 640px;
}
.cs-detail-meta-item { display: flex; flex-direction: column; gap: 4px; }
.cs-detail-meta-item span {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(126, 224, 208, 0.8);
}
.cs-detail-meta-item strong {
  font-family: var(--heading, "Montserrat", sans-serif);
  font-size: 0.95rem;
  font-weight: 700;
  color: #FFF9F0;
}

/* Cover */
.cs-detail-cover {
  padding: clamp(40px, 6vw, 72px) 0 0;
  background: #FFF9F0;
}
.cs-detail-cover img {
  width: 100%;
  height: auto;
  border-radius: 20px;
  box-shadow: 0 24px 60px -20px rgba(0, 26, 23, 0.25);
}

/* Sections */
.cs-detail-section { padding: clamp(56px, 8vw, 100px) 0; }
.cs-detail-section--cream { background: #FFF9F0; }
.cs-detail-section--white { background: #fff; }
.cs-detail-section--dark {
  background: #0B1F1C;
  color: #FFF9F0;
}
.cs-detail-section--dark .cs-detail-heading { color: #FFF9F0; }
.cs-detail-section--dark .cs-detail-heading span { color: #7EE0D0; }
.cs-detail-section--dark .cs-detail-text p { color: rgba(255, 249, 240, 0.75); }

.cs-detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
}
.cs-detail-centered {
  max-width: 780px;
  margin: 0 auto;
  text-align: center;
}
.cs-detail-kicker {
  /* already defined above — keep specific contexts */
}

.cs-detail-text-block .cs-detail-kicker { color: #009688; border-color: rgba(0, 150, 136, 0.3); background: rgba(0, 150, 136, 0.06); }
.cs-detail-section--dark .cs-detail-text-block .cs-detail-kicker { color: #7EE0D0; border-color: rgba(126, 224, 208, 0.3); background: rgba(126, 224, 208, 0.08); }
.cs-detail-centered .cs-detail-kicker { color: #009688; border-color: rgba(0, 150, 136, 0.3); background: rgba(0, 150, 136, 0.06); }

.cs-detail-heading {
  font-family: var(--heading, "Montserrat", sans-serif);
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  line-height: 1.15;
  letter-spacing: -0.02em;
  font-weight: 800;
  margin: 0 0 20px;
  color: #001A17;
}
.cs-detail-heading span { color: #009688; }

.cs-detail-text p {
  font-size: 1rem;
  line-height: 1.75;
  color: rgba(0, 26, 23, 0.72);
  margin: 0 0 16px;
}
.cs-detail-text p:last-child { margin-bottom: 0; }

.cs-detail-img-frame {
  border-radius: 16px;
  overflow: hidden;
  background: #F0F2F0;
  display: grid;
  place-items: center;
  padding: clamp(24px, 4vw, 48px);
}
.cs-detail-img-frame-light { background: #fff; }
.cs-detail-img-frame-dark { background: #0B1F1C; }
.cs-detail-img-frame img {
  width: 100%;
  height: auto;
  max-width: 100%;
  display: block;
  border-radius: 8px;
}

/* Gallery */
.cs-detail-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
}
.cs-detail-gallery-item {
  margin: 0;
  border-radius: 16px;
  overflow: hidden;
  background: #F0F2F0;
  aspect-ratio: 4 / 3;
  display: grid;
  place-items: center;
  padding: 24px;
}
.cs-detail-gallery-item img {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
}

/* Next steps */
.cs-detail-next {
  background: linear-gradient(135deg, #009688 0%, #00796B 100%);
  color: #FFF9F0;
  padding: clamp(56px, 7vw, 88px) 0;
}
.cs-detail-next-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
}
.cs-detail-next h2 {
  font-family: var(--heading, "Montserrat", sans-serif);
  font-size: clamp(1.4rem, 2.8vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0 0 8px;
}
.cs-detail-next p { font-size: 1rem; opacity: 0.85; margin: 0; max-width: 540px; }
.cs-detail-next-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 28px;
  background: #FFF9F0;
  color: #001A17;
  font-family: var(--heading, "Montserrat", sans-serif);
  font-weight: 700;
  font-size: 0.95rem;
  text-decoration: none;
  border-radius: 12px;
  transition: transform .2s ease, box-shadow .2s ease;
  white-space: nowrap;
}
.cs-detail-next-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px -12px rgba(0, 0, 0, 0.3);
}

/* ==================== RESPONSIVE ==================== */
@media (max-width: 900px) {
  .cs-hub-grid { grid-template-columns: 1fr; }
  .cs-detail-grid { grid-template-columns: 1fr !important; gap: 32px; }
  .cs-detail-meta { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 640px) {
  .cs-hub-hero { padding: 64px 0 72px; }
  .cs-detail-hero { padding: 40px 0 40px; }
  .cs-detail-meta { grid-template-columns: 1fr; gap: 16px; }
  .cs-hub-cta-inner,
  .cs-detail-next-inner { flex-direction: column; align-items: flex-start; }
  .cs-hub-cta-btn,
  .cs-detail-next-btn { width: 100%; justify-content: center; }
  .cs-hub-card-body { padding: 22px; }
  .cs-detail-centered { text-align: left; }
  .cs-detail-gallery { grid-template-columns: 1fr; }
}

/* ============ BOUTONS RETOUR ============ */
.cs-detail-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  color: rgba(126, 224, 208, 0.9);
  text-decoration: none;
  padding: 8px 14px;
  border: 1px solid rgba(126, 224, 208, 0.25);
  border-radius: 8px;
  margin-bottom: 24px;
  transition: all .2s ease;
  background: rgba(126, 224, 208, 0.06);
}
.cs-detail-back:hover {
  color: #FFF9F0;
  background: rgba(126, 224, 208, 0.15);
  border-color: rgba(126, 224, 208, 0.5);
  transform: translateX(-3px);
}
.cs-detail-back svg { width: 16px; height: 16px; }

.cs-detail-back-section {
  padding: 40px 0 20px;
  background: #FFF9F0;
}
.cs-detail-section--cream + .cs-detail-back-section,
.cs-detail-section--white + .cs-detail-back-section {
  padding-top: 40px;
  padding-bottom: 40px;
}

.cs-detail-back-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--heading, "Montserrat", sans-serif);
  font-size: 0.9rem;
  font-weight: 700;
  color: #009688;
  text-decoration: none;
  padding: 12px 20px;
  border: 1px solid rgba(0, 150, 136, 0.3);
  border-radius: 10px;
  transition: all .2s ease;
}
.cs-detail-back-link:hover {
  background: #009688;
  color: #FFF9F0;
  transform: translateX(-3px);
}
.cs-detail-back-link svg { width: 16px; height: 16px; }

/* ============ TOP BARS + KICKER CLIQUABLE ============ */
.cs-hub-top-bar,
.cs-detail-top-bar {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 28px;
}
.cs-hub-top-bar .cs-detail-back,
.cs-detail-top-bar .cs-detail-back {
  margin-bottom: 0;
}

.cs-hub-kicker-link {
  display: inline-block;
  text-decoration: none;
  margin-bottom: 24px;
}
.cs-hub-kicker-link:hover .cs-hub-kicker {
  background: rgba(126, 224, 208, 0.18);
  border-color: rgba(126, 224, 208, 0.55);
}

@media (max-width: 640px) {
  .cs-hub-top-bar .cs-detail-back,
  .cs-detail-top-bar .cs-detail-back {
    font-size: 0.78rem;
    padding: 6px 10px;
  }
}
