/**
 * CSS pour les études de cas v2 - DESIGN B2B PROFESSIONNEL
 * Chaque champ CMB2 = rendu CSS spécifique garanti
 * 
 * @package ISI_Forecast_Theme
 * @version 2.1.0
 */

/* ==========================================================================
   VARIABLES GLOBALES - DESIGN B2B PROFESSIONNEL
   ========================================================================== */
:root {
  --color-primary: #005496;
  --color-secondary: #40b1a1;
  --color-text: #1f2937;
  --color-text-light: #6b7280;
  --color-text-muted: #9ca3af;
  
  --bg-white: #ffffff;
  --bg-light: #f9fafb;
  --bg-section: #f8f9fa;
  --bg-card: #ffffff;
  
  --border-light: #e5e7eb;
  --border-primary: var(--color-primary);
  
  --shadow-subtle: 0 1px 3px 0 rgb(0 0 0 / 0.1);
  --shadow-card: 0 4px 6px -1px rgb(0 0 0 / 0.1);
  --shadow-elevated: 0 10px 15px -3px rgb(0 0 0 / 0.12);
}

/* ==========================================================================
   LAYOUT GÉNÉRAL
   ========================================================================== */
.case-study-v2 {
  background: var(--bg-white);
  min-height: 100vh;
}

.container {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.content-container {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

@media (max-width: 1200px) {
  .container {
    max-width: 100%;
  }
}

/* ==========================================================================
   HEADER DE L'ÉTUDE DE CAS
   ========================================================================== */
.case-study-header {
  background: var(--bg-white);
  padding: 0.5rem 0 1rem 0;
}

/* Breadcrumb */
.breadcrumb ol {
  display: flex;
  align-items: center;
  list-style: none;
  margin: 0 0 1rem 0;
  padding: 0;
  font-size: 0.875rem;
}

.breadcrumb li {
  color: var(--color-text-light);
}

.breadcrumb li:not(:last-child)::after {
  content: '/';
  margin: 0 0.5rem;
  color: var(--color-text-muted);
}

.breadcrumb a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color 0.2s;
}

.breadcrumb a:hover {
  color: var(--color-secondary);
}

.breadcrumb .current {
  font-weight: 600;
  color: var(--color-text);
}

/* Header Content */
.header-content {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2rem;
  align-items: start;
}

.main-title {
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.3;
  color: var(--color-text);
  margin: 0 0 1rem 0;
}

.company-name {
  color: var(--color-primary);
}

.short-description {
  font-size: 1.125rem;
  color: var(--color-text-light);
  line-height: 1.6;
  margin: 0 0 1.5rem 0;
}

/* Badges d'informations */
.company-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  background: var(--bg-section);
  border: 1px solid var(--border-light);
  border-radius: 6px;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--color-text);
}

.badge .icon {
  width: 1rem;
  height: 1rem;
  color: var(--color-primary);
}

/* Logo entreprise */
.company-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 120px;
  height: 120px;
  background: var(--bg-white);
  border: 1px solid var(--border-light);
  border-radius: 8px;
  box-shadow: var(--shadow-card);
}

.logo-image {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

/* ==========================================================================
   SECTIONS PRINCIPALES
   ========================================================================== */
.section {
  padding: 1rem 0;
  position: relative;
}

.section-inner {
  max-width: calc(1140px - 3rem); /* Soustraction du padding horizontal */
  margin: 0 auto 0.5rem auto;
  padding: 2.5rem 1.5rem;
  background: var(--bg-card);
  border-radius: 8px;
  border-left: 2px solid var(--border-primary);
  box-shadow: var(--shadow-card);
}

@media (max-width: 1200px) {
  .section-inner {
    max-width: calc(100% - 3rem);
    margin: 0 1.5rem 0.5rem 1.5rem;
  }
}

/* Container pour limiter la largeur du contenu à celle de la navbar */
.content-wrapper {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section-title {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--color-text);
  margin: 0 0 2rem 0;
}

.section-icon {
  width: 1.5rem;
  height: 1.5rem;
  color: var(--color-primary);
  flex-shrink: 0;
}

/* ==========================================================================
   CONTENU DES SECTIONS
   ========================================================================== */

/* Blocs de contenu génériques */
.content-block {
  background: var(--bg-section);
  padding: 1.5rem;
  border-radius: 6px;
  border: 1px solid var(--border-light);
  margin: 1.5rem 0;
  color: var(--color-text);
  line-height: 1.6;
}

.content-block h3 {
  color: var(--color-primary);
  font-size: 1.25rem;
  font-weight: 600;
  margin: 0 0 1rem 0;
}

/* Listes de problèmes et objectifs */
.problems-list ul,
.objectives-list ul {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0;
}

.problems-list li,
.objectives-list li {
  position: relative;
  padding: 0.75rem 0 0.75rem 2rem;
  color: var(--color-text);
  border-bottom: 1px solid var(--border-light);
}

.problems-list li:last-child,
.objectives-list li:last-child {
  border-bottom: none;
}

.problems-list li::before {
  content: '•';
  position: absolute;
  left: 0.5rem;
  color: var(--color-primary);
  font-weight: bold;
  font-size: 1.25rem;
}

.objectives-list li::before {
  content: '✓';
  position: absolute;
  left: 0.5rem;
  color: var(--color-primary);
  font-weight: bold;
  font-size: 1rem;
}

/* Boîtes d'impact et d'attentes */
.impact-box,
.expectations-box {
  background: var(--bg-section);
  border: 1px solid var(--color-primary);
  border-radius: 6px;
  padding: 2rem;
  margin: 2rem 0;
  text-align: center;
  font-weight: 600;
  color: var(--color-text);
}

/* Modules de solution */
.modules-grid {
  margin: 2rem 0;
}

.modules-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.module-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem;
  background: var(--bg-section);
  border: 1px solid var(--border-light);
  border-radius: 6px;
  font-weight: 500;
  color: var(--color-text);
  transition: all 0.2s;
}

.module-item:hover {
  background: var(--bg-white);
  box-shadow: var(--shadow-card);
}

.check-icon {
  width: 1rem;
  height: 1rem;
  color: var(--color-primary);
  flex-shrink: 0;
}

.technical-box {
  background: var(--bg-section);
  border: 1px solid var(--color-primary);
  border-radius: 6px;
  padding: 2rem;
  margin: 2rem 0;
  color: var(--color-text);
  font-weight: 500;
  text-align: center;
}

/* ==========================================================================
   📊 SECTION RÉSULTATS - MÉTRIQUES PROFESSIONNELLES
   ========================================================================== */

.metrics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin: 2rem 0;
}

.metric-card {
  background: var(--bg-white);
  border: 1px solid var(--border-light);
  border-radius: 8px;
  padding: 2rem 1.5rem;
  text-align: center;
  box-shadow: var(--shadow-card);
  transition: all 0.3s ease;
}

.metric-card:hover {
  box-shadow: var(--shadow-elevated);
  transform: translateY(-2px);
}

.metric-value {
  font-size: 2.25rem;
  font-weight: 700;
  color: var(--color-primary);
  line-height: 1.1;
  margin: 0.5rem 0 1rem 0;
  display: block;
  font-family: system-ui, -apple-system, sans-serif;
}

.metric-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--color-text);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin: 0 0 0.5rem 0;
}

.metric-description {
  font-size: 0.875rem;
  color: var(--color-text-light);
  line-height: 1.4;
}

/* ==========================================================================
   💬 SECTION TÉMOIGNAGE
   ========================================================================== */
.testimonial-quote {
  background: transparent;
  border-radius: 0;
  padding: 0;
  box-shadow: none;
  border: none;
  position: relative;
  max-width: none;
  margin: 0;
}

.quote-content {
  font-size: 1.125rem;
  line-height: 1.6;
  color: var(--color-text);
  font-style: italic;
  margin: 0 0 2rem 0;
}

.quote-author {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-light);
  margin-top: 1.5rem;
}

.author-name {
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-primary);
  margin: 0;
}

.author-title {
  font-size: 0.875rem;
  color: var(--color-text-light);
  margin: 0.25rem 0 0 0;
}

.author-photo {
  flex-shrink: 0;
}

.author-image {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--border-light);
}

/* ==========================================================================
   🎯 CONCLUSION ET PERSPECTIVES
   ========================================================================== */

.bilan-block,
.perspectives-block {
  background: var(--bg-section);
  border: 1px solid var(--color-primary);
  border-radius: 6px;
  padding: 2rem;
  margin: 2rem 0;
  text-align: center;
  font-weight: 600;
  color: var(--color-text);
}

/* ==========================================================================
   CTA FINAL
   ========================================================================== */
.section-cta {
  background: var(--bg-white);
  text-align: center;
  padding: 4rem 0;
  margin-top: 2rem;
}

.section-cta .section-inner {
  background: transparent;
  border: none;
  box-shadow: none;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.cta-content h2 {
  font-size: 2rem;
  font-weight: 700;
  color: var(--color-text);
  margin: 0 0 1rem 0;
}

.cta-content p {
  font-size: 1.125rem;
  color: var(--color-text-light);
  margin: 0 0 2rem 0;
}

.cta-button {
  background: linear-gradient(to right, var(--color-primary), var(--color-secondary));
  color: white;
  transform-gpu: translateZ(0);
  will-change: transform;
  border-radius: 0.75rem;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem 2rem;
  font-size: 1.125rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: inline-flex;
  position: relative;
  overflow: hidden;
}

.cta-button::before {
  content: "";
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  width: 100%;
  height: 100%;
  transition: left 0.6s;
  position: absolute;
  top: 0;
  left: -100%;
}

.cta-button:hover {
  transform: translateY(-0.125rem);
  box-shadow: 0 10px 25px -3px rgba(0, 84, 150, 0.3);
}

.cta-button:hover::before {
  left: 100%;
}

.button-icon {
  width: 1rem;
  height: 1rem;
}

/* ==========================================================================
   NAVIGATION ENTRE ÉTUDES
   ========================================================================== */
.case-study-navigation {
  background: var(--bg-white);
  border-top: 1px solid var(--border-light);
  padding: 2rem 0;
}

.nav-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.nav-item {
  padding: 1.5rem;
  border: 1px solid var(--border-light);
  border-radius: 6px;
  transition: all 0.2s;
}

.nav-item:hover {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-card);
}

.nav-label {
  display: block;
  font-size: 0.875rem;
  color: var(--color-text-light);
  font-weight: 500;
  margin: 0 0 0.5rem 0;
}

.nav-link {
  font-weight: 600;
  color: var(--color-primary);
  text-decoration: none;
  font-size: 1rem;
}

.nav-link:hover {
  color: var(--color-secondary);
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 768px) {
  .header-content {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .company-logo {
    width: 100px;
    height: 100px;
    justify-self: center;
  }
  
  .main-title {
    font-size: 1.75rem;
  }
  
  .section {
    padding: 1.5rem 0;
  }
  
  .section-inner {
    padding: 2rem;
    margin-bottom: 2rem;
  }
  
  .section-title {
    font-size: 1.5rem;
  }
  
  .metric-value {
    font-size: 2rem;
  }
  
  .metrics-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .testimonial-quote {
    padding: 2rem;
  }
  
  .quote-author {
    flex-direction: column;
    text-align: center;
  }
  
  .cta-content h2 {
    font-size: 1.75rem;
  }
}