/* =========================================================
   ATPM — TRAVAUX PUBLICS & GÉNIE CIVIL PAGE STYLES
   ========================================================= */

/* --- HERO SECTION --- */
.travaux-hero {
  position: relative;
  min-height: 680px;
  display: flex;
  align-items: center;
  overflow: hidden;
  color: var(--white);
  background-color: var(--navy-dark);
}

.travaux-hero .hero-background {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-image: url("../images/placeholders/travaux-publics.jpg");
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
}

.travaux-hero .hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    90deg,
    rgba(9, 29, 38, 0.90) 0%,
    rgba(9, 29, 38, 0.72) 45%,
    rgba(9, 29, 38, 0.26) 100%
  );
}

.travaux-hero .hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
}

.travaux-hero .hero-eyebrow {
  display: block;
  margin-bottom: 20px;
  color: #D08A68;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.travaux-hero h1 {
  max-width: 850px;
  margin: 0;
  color: var(--white);
  font-family: var(--font-heading);
  font-size: clamp(52px, 7vw, 92px);
  font-weight: 700;
  line-height: 1.03;
  letter-spacing: -3px;
}

.travaux-hero .hero-description {
  max-width: 650px;
  margin: 28px 0 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 17px;
  line-height: 1.75;
}

.travaux-hero .hero-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 36px;
}

.travaux-hero .hero-link {
  color: var(--white);
  font-weight: 600;
  font-size: 14px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: opacity 0.2s ease;
}

.travaux-hero .hero-link:hover {
  opacity: 0.8;
}

/* --- INTRODUCTION --- */
.service-intro {
  padding: 120px 0;
  background: var(--white);
}

.intro-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 100px;
  align-items: start;
}

.intro-heading h2 {
  margin: 18px 0 0;
  color: var(--navy);
  font-family: var(--font-heading);
  font-size: clamp(34px, 4vw, 56px);
  line-height: 1.15;
}

.intro-content {
  padding-top: 8px;
}

.intro-lead {
  margin-top: 0;
  color: var(--navy);
  font-size: 20px;
  line-height: 1.7;
}

.intro-content p:not(.intro-lead) {
  margin-top: 24px;
  color: var(--text-light);
  font-size: 16px;
  line-height: 1.8;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 20px;
  color: var(--navy);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.text-link span {
  color: var(--terracotta);
  font-size: 18px;
}

/* --- PROJECT APPROACH --- */
.project-approach {
  padding: 110px 0;
  background: #faf9f7;
}

.project-approach .section-heading.centered {
  text-align: center;
  margin-bottom: 55px;
}

.project-approach .section-heading h2 {
  margin: 15px 0 0;
  color: var(--navy);
  font-family: var(--font-heading);
  font-size: clamp(32px, 4vw, 50px);
  line-height: 1.15;
}

.approach-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid rgba(22, 58, 74, 0.14);
  border-bottom: 1px solid rgba(22, 58, 74, 0.14);
}

.approach-item {
  padding: 40px 30px 45px;
  border-right: 1px solid rgba(22, 58, 74, 0.14);
}

.approach-item:first-child { padding-left: 0; }
.approach-item:last-child { border-right: none; }

.approach-number {
  display: block;
  margin-bottom: 55px;
  color: var(--terracotta);
  font-family: var(--font-heading);
  font-size: 15px;
  font-weight: 700;
}

.approach-item h3 {
  margin: 0 0 15px;
  color: var(--navy);
  font-family: var(--font-heading);
  font-size: 23px;
}

.approach-item p {
  margin: 0;
  color: var(--text-light);
  font-size: 14px;
  line-height: 1.7;
}

/* --- EXPERTISE BLOCKS --- */
.expertise-section {
  background: var(--white);
}

.expertise-block {
  display: flex;
  min-height: 580px;
}

.expertise-block > * {
  flex: 1 1 50%;
}

.expertise-block.reverse {
  flex-direction: row-reverse;
}

/* Image styling and mapped placeholders */
.expertise-image {
  min-height: 580px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.terrassement-image { background-image: url("../images/placeholders/terrassement.jpg"); }
.routes-image { background-image: url("../images/placeholders/routes.jpg"); }
.bassins-image { background-image: url("../images/placeholders/bassins.jpg"); }
.murs-image { background-image: url("../images/placeholders/infrastructure.jpg"); }

.expertise-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 80px;
  background: #faf9f7;
}

.expertise-content h2 {
  margin: 16px 0 24px;
  color: var(--navy);
  font-family: var(--font-heading);
  font-size: clamp(32px, 3.5vw, 48px);
  line-height: 1.15;
}

.expertise-lead {
  margin: 0 0 20px;
  color: var(--navy);
  font-size: 19px;
  line-height: 1.65;
}

.expertise-content > p:not(.expertise-lead) {
  color: var(--text-light);
  font-size: 15px;
  line-height: 1.8;
}

.expertise-list {
  margin: 28px 0 0;
  padding: 0;
  list-style: none;
}

.expertise-list li {
  position: relative;
  padding: 9px 0 9px 20px;
  border-bottom: 1px solid rgba(22, 58, 74, 0.10);
  color: var(--text-light);
  font-size: 14px;
}

.expertise-list li::before {
  content: "—";
  position: absolute;
  left: 0;
  color: var(--terracotta);
  font-weight: bold;
}

/* --- EQUIPMENT SECTION --- */
.equipment-section {
  padding: 0;
  background: #faf9f7;
}

.equipment-grid {
  display: flex;
  min-height: 600px;
}

.equipment-grid > * {
  flex: 1 1 50%;
}

.equipment-image {
  background-image: url("../images/placeholders/equipment.jpg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  min-height: 600px;
}

.equipment-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 90px;
}

.equipment-content .section-kicker {
  color: var(--terracotta);
  margin-bottom: 15px;
  font-weight: 700;
  letter-spacing: 1px;
}

.equipment-content h2 {
  margin: 0 0 28px;
  color: var(--navy);
  font-family: var(--font-heading);
  font-size: clamp(34px, 4vw, 52px);
  line-height: 1.15;
}

.equipment-content .intro-lead {
  color: var(--navy);
  font-size: 20px;
  margin-bottom: 20px;
}

.equipment-content p:not(.intro-lead) {
  color: var(--text-light);
  font-size: 16px;
  line-height: 1.8;
}

/* --- COMPLEX TERRAIN --- */
.complex-terrain {
  padding: 110px 0;
  background: var(--navy);
  color: var(--white);
}

.complex-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 120px;
  align-items: center;
}

.complex-content .section-kicker {
  color: #d49a72;
}

.complex-content h2 {
  margin: 18px 0 28px;
  font-family: var(--font-heading);
  font-size: clamp(34px, 4vw, 55px);
  line-height: 1.15;
}

.complex-content p {
  max-width: 600px;
  color: rgba(255, 255, 255, 0.70);
  font-size: 16px;
  line-height: 1.8;
}

.complex-stats {
  border-top: 1px solid rgba(255, 255, 255, 0.20);
  border-bottom: 1px solid rgba(255, 255, 255, 0.20);
}

.complex-stat {
  display: grid;
  grid-template-columns: 80px 1fr;
  align-items: center;
  min-height: 110px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.20);
}

.complex-stat:last-child { border-bottom: none; }

.complex-stat span {
  color: var(--terracotta);
  font-family: var(--font-heading);
  font-size: 22px;
  font-weight: 700;
}

.complex-stat p {
  margin: 0;
  color: var(--white);
  font-size: 16px;
}

/* --- PROJECT TYPES --- */
.project-types-section {
  padding: 110px 0;
  background: var(--white);
}

.project-types-section .section-heading.centered {
  text-align: center;
  margin-bottom: 60px;
}

.types-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.type-card {
  min-height: 250px;
  padding: 35px 30px;
  border: 1px solid rgba(22, 58, 74, 0.12);
  background: #faf9f7;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.type-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(22, 58, 74, 0.08);
}

.type-card span {
  display: block;
  margin-bottom: 55px;
  color: var(--terracotta);
  font-family: var(--font-heading);
  font-weight: 700;
}

.type-card h3 {
  margin: 0 0 12px;
  color: var(--navy);
  font-family: var(--font-heading);
  font-size: 21px;
}

.type-card p {
  margin: 0;
  color: var(--text-light);
  font-size: 14px;
  line-height: 1.7;
}

/* --- RELATED SERVICES --- */
.related-services {
  padding: 110px 0;
  background: #faf9f7;
}

.related-services .section-heading {
  margin-bottom: 55px;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.related-card {
  display: flex;
  flex-direction: column;
  min-height: 290px;
  padding: 35px;
  border: 1px solid rgba(22, 58, 74, 0.12);
  background: var(--white);
  transition: background 0.25s ease, transform 0.25s ease;
}

.related-card:hover {
  background: var(--navy);
  transform: translateY(-4px);
}

.related-card > span {
  margin-bottom: 50px;
  color: var(--terracotta);
  font-weight: 700;
}

.related-card h3 {
  margin: 0 0 12px;
  color: var(--navy);
  font-family: var(--font-heading);
  font-size: 24px;
  transition: color 0.25s ease;
}

.related-card p {
  margin: 0;
  color: var(--text-light);
  font-size: 14px;
  line-height: 1.7;
  transition: color 0.25s ease;
}

.related-card strong {
  margin-top: auto;
  padding-top: 25px;
  color: var(--terracotta);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

.related-card:hover h3 { color: var(--white); }
.related-card:hover p { color: rgba(255, 255, 255, 0.65); }

/* --- FAQ SECTION --- */
.faq-section {
  padding: 110px 0;
  background: var(--white);
}

.faq-container {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 100px;
  align-items: start;
}

.faq-list {
  border-top: 1px solid rgba(22, 58, 74, 0.15);
}

.faq-item {
  padding: 0;
  border-bottom: 1px solid rgba(22, 58, 74, 0.15);
}

.faq-item summary {
  position: relative;
  padding: 24px 40px 24px 0;
  color: var(--navy);
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}

.faq-item summary::-webkit-details-marker { display: none; }

.faq-item summary::after {
  content: "+";
  position: absolute;
  right: 0;
  color: var(--terracotta);
  font-size: 25px;
  font-weight: 400;
}

.faq-item[open] summary::after { content: "−"; }

.faq-item p {
  max-width: 700px;
  margin: 0;
  padding: 0 40px 25px 0;
  color: var(--text-light);
  font-size: 14px;
  line-height: 1.8;
}

/* --- FINAL CTA --- */
.final-cta {
  padding: 120px 0;
  text-align: center;
  background: var(--terracotta);
  color: var(--white);
}

.final-cta-content {
  max-width: 760px;
  margin: 0 auto;
}

.final-cta .section-kicker {
  color: rgba(255, 255, 255, 0.75);
}

.final-cta h2 {
  margin: 18px 0 22px;
  font-family: var(--font-heading);
  font-size: clamp(38px, 5vw, 65px);
  line-height: 1.1;
}

.final-cta p {
  max-width: 560px;
  margin: 0 auto 35px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 17px;
  line-height: 1.7;
}

.final-cta-buttons {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 14px;
}

.primary-button,
.secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  padding: 15px 22px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  border-radius: 4px;
  transition: transform 0.25s ease, background 0.25s ease, color 0.25s ease;
}

.primary-button {
  background: var(--terracotta);
  color: var(--white);
  border: 1px solid var(--terracotta);
}

.primary-button:hover {
  transform: translateY(-2px);
  background: #A95031;
  border-color: #A95031;
}

.secondary-button {
  background: transparent;
  color: var(--navy);
  border: 1px solid rgba(22, 58, 74, 0.45);
}

.final-cta .primary-button {
  background: var(--white);
  color: var(--navy);
  border-color: var(--white);
}

.final-cta .primary-button:hover {
  background: var(--navy);
  color: var(--white);
  border-color: var(--navy);
}

.final-cta .secondary-button {
  border-color: rgba(255, 255, 255, 0.70);
  color: var(--white);
}

.final-cta .secondary-button:hover {
  background: var(--white);
  color: var(--navy);
}

/* --- RESPONSIVE FIXES --- */
@media (max-width: 1000px) {
  .intro-grid,
  .complex-grid,
  .faq-container {
    grid-template-columns: 1fr;
    gap: 50px;
  }
  
  .approach-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .approach-item:nth-child(2) { border-right: none; }
  .approach-item:nth-child(-n+2) { border-bottom: 1px solid rgba(22, 58, 74, 0.14); }
  
  .types-grid { grid-template-columns: repeat(2, 1fr); }
  
  .expertise-block,
  .expertise-block.reverse,
  .equipment-grid {
    flex-direction: column !important;
  }
  
  /* CRITICAL: Force images above content */
  .expertise-image,
  .equipment-image {
    order: 1 !important;
    min-height: 380px;
    width: 100%;
  }
  
  .expertise-content,
  .equipment-content {
    order: 2 !important;
    width: 100%;
    padding: 60px 30px;
  }
}

@media (max-width: 650px) {
  .approach-grid,
  .types-grid,
  .related-grid {
    grid-template-columns: 1fr;
  }
  .approach-item {
    border-right: none;
    border-bottom: 1px solid rgba(22, 58, 74, 0.14);
  }
  
  .complex-stat {
    grid-template-columns: 60px 1fr;
  }
  
  .final-cta-buttons {
    flex-direction: column;
    align-items: stretch;
  }
}