/* Page "Pourquoi nous choisir" - Styles spécifiques uniquement */

/* Palette et variables (couleurs unies) */
:root {
  --accent: #f28c28;
  --accent-2: #2d9cdb;
  --muted: #58606b;
  --text: #111217;
  --bg-soft: #f6f7f9;
  --card-bg: #ffffff;
}

/* PAGE HERO */
.page-hero {
  background: #2c3e50;
  color: white;
  padding: 80px 20px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.page-hero::before,
.page-hero::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  background: rgba(242, 140, 40, 0.06);
  pointer-events: none;
}

.page-hero::before {
  width: 420px;
  height: 420px;
  top: -22%;
  right: -12%;
}

.page-hero::after {
  width: 360px;
  height: 360px;
  bottom: -22%;
  left: -10%;
}

.page-hero .container {
  position: relative;
  z-index: 2;
}

.page-hero h1 {
  font-size: clamp(34px, 5.2vw, 56px);
  margin-bottom: 16px;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.02;
}

.page-hero p {
  font-size: clamp(16px, 2.6vw, 22px);
  max-width: 820px;
  margin: 0 auto;
  color: rgba(236, 240, 241, 0.96);
  margin-top: 8px;
}

.page-hero-content .container {
  position: relative;
  z-index: 2;
}

/* INTRO SECTION */
.intro-section {
  padding: 64px 20px;
  background: var(--card-bg);
}

.intro-content {
  max-width: 920px;
  margin: 0 auto;
  text-align: center;
  color: var(--text);
  line-height: 1.8;
  font-size: 18px;
}

.intro-content p + p {
  margin-top: 14px;
}

.intro-content strong {
  color: var(--text);
  font-weight: 800;
}

/* TWO COLUMN SECTION */
.two-column-section {
  padding: 64px 20px;
  background: var(--bg-soft);
}

.two-column-content {
  display: grid;
  grid-template-columns: 1fr 440px;
  gap: 56px;
  align-items: center;
}

.column-text h2 {
  font-size: clamp(28px, 4vw, 40px);
  color: var(--text);
  margin-bottom: 18px;
  font-weight: 800;
}

.column-text p {
  color: var(--muted);
  font-size: 17.5px;
  line-height: 1.75;
  margin-bottom: 12px;
}

.column-text strong {
  color: var(--accent);
  font-weight: 800;
}

/* Icone large et discrète */
.column-icon {
  display: flex;
  justify-content: center;
  align-items: center;
}

.column-icon i {
  font-size: 140px;
  color: var(--accent);
  opacity: 0.12;
  transition: transform 0.6s ease, opacity 0.25s ease;
}

.column-icon:hover i {
  transform: translateY(-6px);
  opacity: 0.18;
}

/* ENGAGEMENTS SECTION */
.engagements-section {
  padding: 64px 20px;
  background: var(--card-bg);
  color: var(--text);
}

.section-title-center {
  text-align: center;
  font-size: clamp(26px, 3.6vw, 36px);
  color: var(--text);
  margin-bottom: 42px;
  font-weight: 800;
  position: relative;
  padding-bottom: 24px;
}

.section-title-center::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 92px;
  height: 5px;
  background: var(--accent);
  border-radius: 4px;
}

/* Tabs layout */
.engagements-tabs {
  max-width: 1080px;
  margin: 0 auto;
  display: flex;
  gap: 28px;
  align-items: flex-start;
}

.tabs-navigation {
  flex: 0 0 240px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* Boutons de tab */
.tab-button {
  background: transparent;
  border: 1px solid rgba(17, 18, 23, 0.06);
  padding: 16px 18px;
  text-align: left;
  font-size: 17px;
  font-weight: 700;
  color: var(--muted);
  cursor: pointer;
  border-radius: 10px;
  transition: all 0.18s ease;
  width: 100%;
}

.tab-button:hover {
  color: var(--text);
  transform: translateX(4px);
}

.tab-button.active {
  background: var(--card-bg);
  color: var(--text);
  border-left: 6px solid var(--accent);
  box-shadow: 0 8px 22px rgba(16, 24, 40, 0.05);
}

/* Contenu des tabs */
.tabs-content {
  flex: 1;
  background: var(--bg-soft);
  border-radius: 12px;
  padding: 30px;
  min-height: 180px;
}

.tab-pane {
  display: none;
}

.tab-pane.active {
  display: block;
}

/* Titres et icônes des tabpanes */
.tab-pane h3 {
  font-size: 26px;
  color: var(--text);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
}

.tab-pane h3 i {
  color: var(--accent);
  font-size: 22px;
}

.tab-pane p {
  color: var(--muted);
  line-height: 1.85;
  font-size: 17px;
}

/* CLIENTS SECTION */
.clients-section {
  padding: 64px 20px;
  background: var(--bg-soft);
  color: var(--text);
}

.clients-section h2 {
  text-align: center;
  font-size: clamp(28px, 3.8vw, 36px);
  margin-bottom: 36px;
  font-weight: 800;
}

/* Grille clients */
.clients-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
}

/* Cartes clients */
.client-item {
  background: var(--card-bg);
  padding: 26px;
  border-radius: 12px;
  border: 1px solid rgba(17, 18, 23, 0.04);
  text-align: center;
  box-shadow: 0 10px 30px rgba(16, 24, 40, 0.04);
  transition: transform 0.22s ease, box-shadow 0.22s ease;
}

.client-item:hover {
  transform: translateY(-6px);
  box-shadow: 0 18px 44px rgba(16, 24, 40, 0.07);
}

.client-item i {
  display: inline-block;
  font-size: 44px;
  width: 72px;
  height: 72px;
  line-height: 72px;
  border-radius: 18px;
  background: var(--accent-2);
  color: #fff;
  margin-bottom: 12px;
  box-shadow: 0 8px 20px rgba(45, 156, 219, 0.12);
  opacity: 1;
}

.client-item p {
  font-size: 16.5px;
  line-height: 1.6;
  color: var(--muted);
  margin: 0;
}

/* CTA SECTION */
.cta-section {
  padding: 64px 20px;
  background: var(--card-bg);
  color: var(--text);
  text-align: center;
  border-top: 1px solid rgba(17, 18, 23, 0.03);
}

.cta-content h2 {
  font-size: clamp(22px, 3.2vw, 30px);
  margin-bottom: 10px;
  font-weight: 900;
}

.cta-content p {
  font-size: 17px;
  margin-bottom: 18px;
  color: var(--muted);
}

/* Bouton CTA */
.cta-button {
  display: inline-block;
  background: #e8491d;
  color: white;
  padding: 16px 40px;
  font-size: 16px;
  font-weight: bold;
  text-decoration: none;
  border-radius: 4px;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.cta-button:hover,
.cta-button:focus {
  background: #c73d17;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(232, 73, 29, 0.3);
  color: white;
}

/* Focus/accessibilité */
.tab-button:focus,
.cta-button:focus,
.client-item:focus {
  outline: 3px solid rgba(242, 140, 40, 0.14);
  outline-offset: 4px;
}

/* Animations légères */
@keyframes subtleFadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.tab-pane.active,
.client-item,
.column-text,
.intro-content {
  animation: subtleFadeIn 420ms ease both;
}

/* ========================================
   RESPONSIVE - MEDIA QUERIES
   ======================================== */

/* Tablettes et petits écrans (≤ 1024px) */
@media (max-width: 1024px) {
  .two-column-content {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  
  .column-icon {
    order: -1;
  }
  
  .column-icon i {
    font-size: 120px;
  }
}

/* Tablettes (≤ 900px) */
@media (max-width: 900px) {
  .page-hero {
    padding: 60px 20px;
  }
  
  .intro-section,
  .two-column-section,
  .engagements-section,
  .clients-section,
  .cta-section {
    padding: 50px 20px;
  }
  
  .engagements-tabs {
    gap: 20px;
  }
  
  .tabs-navigation {
    flex: 0 0 200px;
  }
  
  .tab-button {
    font-size: 16px;
    padding: 14px 16px;
  }
  
  .tabs-content {
    padding: 26px;
  }
  
  .clients-grid {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  }
}

/* Mobile et tablettes en mode portrait (≤ 768px) */
@media (max-width: 768px) {
  .page-hero {
    padding: 50px 15px;
  }
  
  .page-hero h1 {
    font-size: clamp(28px, 6vw, 40px);
  }
  
  /* CORRECTION MAJEURE: Navigation horizontale sur mobile */
  .engagements-tabs {
    flex-direction: column;
    gap: 20px;
  }

  .tabs-navigation {
    flex: 1;
    flex-direction: row;
    overflow-x: auto;
    overflow-y: hidden;
    gap: 10px;
    padding-bottom: 8px;
    width: 100%;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: var(--accent) rgba(0,0,0,0.1);
  }
  
  /* Style de la scrollbar pour webkit */
  .tabs-navigation::-webkit-scrollbar {
    height: 6px;
  }
  
  .tabs-navigation::-webkit-scrollbar-track {
    background: rgba(0,0,0,0.05);
    border-radius: 3px;
  }
  
  .tabs-navigation::-webkit-scrollbar-thumb {
    background: var(--accent);
    border-radius: 3px;
  }

  .tab-button {
    white-space: nowrap;
    flex: 0 0 auto;
    min-width: 180px;
    font-size: 15px;
    padding: 14px 18px;
    text-align: center;
  }
  
  .tab-button:hover {
    transform: none;
  }
  
  .tab-button.active {
    border-left: 1px solid rgba(17, 18, 23, 0.06);
    border-bottom: 4px solid var(--accent);
  }

  .tabs-content {
    width: 100%;
    padding: 24px;
    min-height: 200px;
  }
  
  .tab-pane h3 {
    font-size: 22px;
    flex-wrap: wrap;
  }
  
  .tab-pane p {
    font-size: 16px;
  }
  
  .two-column-content {
    gap: 24px;
  }

  .column-icon i {
    font-size: 100px;
  }

  .clients-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }
  
  .intro-section,
  .two-column-section,
  .engagements-section,
  .clients-section,
  .cta-section {
    padding: 45px 15px;
  }
}

/* Petits mobiles (≤ 480px) */
@media (max-width: 480px) {
  .page-hero {
    padding: 40px 15px;
  }
  
  .page-hero h1 {
    font-size: clamp(24px, 7vw, 32px);
    margin-bottom: 12px;
  }
  
  .page-hero p {
    font-size: clamp(14px, 4vw, 18px);
  }
  
  .intro-section {
    padding: 35px 15px;
  }

  .intro-content {
    font-size: 16px;
  }

  .two-column-section,
  .engagements-section,
  .clients-section,
  .cta-section {
    padding: 40px 15px;
  }
  
  .section-title-center {
    font-size: clamp(22px, 5vw, 28px);
    margin-bottom: 32px;
  }
  
  .tab-button {
    min-width: 160px;
    font-size: 14px;
    padding: 12px 16px;
  }

  .tabs-content {
    padding: 20px 18px;
  }
  
  .tab-pane h3 {
    font-size: 20px;
    gap: 8px;
  }
  
  .tab-pane h3 i {
    font-size: 20px;
  }
  
  .tab-pane p {
    font-size: 15px;
    line-height: 1.7;
  }

  .client-item {
    padding: 22px 18px;
  }
  
  .client-item i {
    font-size: 38px;
    width: 64px;
    height: 64px;
    line-height: 64px;
  }
  
  .client-item p {
    font-size: 15px;
  }
  
  .column-icon i {
    font-size: 80px;
  }
  
  .cta-button {
    padding: 14px 32px;
    font-size: 15px;
    width: 100%;
    max-width: 320px;
  }
}

/* Très petits mobiles (≤ 360px) */
@media (max-width: 360px) {
  .tab-button {
    min-width: 140px;
    font-size: 13px;
    padding: 11px 14px;
  }
  
  .tabs-content {
    padding: 18px 15px;
  }
  
  .tab-pane h3 {
    font-size: 18px;
  }
  
  .client-item i {
    font-size: 36px;
    width: 60px;
    height: 60px;
    line-height: 60px;
  }
}