/* ===== GIE INFRACOP — V3 : design system moins figé ===== */
:root {
    --navy: #142A47;
    --navy-light: #24466F;
    --navy-deep: #0D1D33;
    --gold: #B8964F;
    --gold-light: #D9BC7E;
    --gold-dark: #96762E;
    --black: #111111;
    --white: #FFFFFF;
    --paper: #FAF9F6;
    --gray-50: #F8F8F7;
    --gray-100: #F0EFEC;
    --gray-200: #E2E0DA;
    --gray-400: #94918A;
    --gray-600: #5F5D57;
    --gray-800: #2C2B28;
    --radius: 18px;
    --radius-sm: 12px;
    --radius-pill: 999px;
    --shadow-sm: 0 2px 10px rgba(20,42,71,0.07);
    --shadow-md: 0 14px 40px rgba(20,42,71,0.12);
    --shadow-lg: 0 24px 64px rgba(20,42,71,0.16);
    --display: 'Space Grotesk', 'Inter', sans-serif;
    --ease: cubic-bezier(.22,1,.36,1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--gray-800);
    background: var(--white);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}
h1, h2, h3 { font-family: var(--display); }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul { list-style: none; }

.container { max-width: 1160px; margin: 0 auto; padding: 0 24px; }
.container-narrow { max-width: 780px; margin: 0 auto; padding: 0 24px; }

/* ===== REVEAL ON SCROLL ===== */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
.reveal.is-visible { opacity: 1; transform: translateY(0); }
.reveal-delay-1.is-visible { transition-delay: 0.08s; }
.reveal-delay-2.is-visible { transition-delay: 0.16s; }
.reveal-delay-3.is-visible { transition-delay: 0.24s; }
.reveal-delay-4.is-visible { transition-delay: 0.32s; }

/* ===== BLOBS DÉCORATIFS ===== */
.blob { position: absolute; border-radius: 62% 38% 55% 45% / 45% 55% 45% 55%; filter: blur(0px); z-index: 0; pointer-events: none; }
@keyframes blobDrift {
    0%, 100% { border-radius: 62% 38% 55% 45% / 45% 55% 45% 55%; transform: translate(0,0) rotate(0deg); }
    33% { border-radius: 45% 55% 40% 60% / 55% 45% 60% 40%; transform: translate(10px,-14px) rotate(6deg); }
    66% { border-radius: 55% 45% 60% 40% / 40% 60% 45% 55%; transform: translate(-8px,10px) rotate(-4deg); }
}
.blob-anim { animation: blobDrift 16s ease-in-out infinite; }

/* ===== HEADER ===== */
header {
    background: rgba(255,255,255,0.92);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--gray-200);
    position: sticky; top: 0; z-index: 200;
    transition: box-shadow 0.3s var(--ease);
}
header.scrolled { box-shadow: var(--shadow-sm); }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 78px; }
.logo { display: flex; align-items: center; gap: 12px; }
.logo img { width: 36px; height: 36px; transition: transform 0.4s var(--ease); }
.logo:hover img { transform: rotate(-8deg) scale(1.05); }
.logo-text { display: flex; flex-direction: column; line-height: 1.15; }
.logo-text .gie { font-size: 0.62rem; font-weight: 600; letter-spacing: 3.5px; text-transform: uppercase; color: var(--gold-dark); }
.logo-text .name { font-family: var(--display); font-size: 1.3rem; font-weight: 600; letter-spacing: 0.5px; color: var(--navy); }
nav { display: flex; gap: 4px; }
#mainNav a { position: relative; padding: 8px 14px; font-size: 0.8rem; font-weight: 500; letter-spacing: 0.3px; color: var(--gray-600); transition: color 0.2s; }
#mainNav a::after { content: ''; position: absolute; left: 14px; right: 14px; bottom: 3px; height: 2px; background: var(--gold); border-radius: 2px; transform: scaleX(0); transform-origin: left; transition: transform 0.3s var(--ease); }
#mainNav a:hover, #mainNav a.active { color: var(--navy); }
#mainNav a:hover::after, #mainNav a.active::after { transform: scaleX(1); }
.burger { display: none; background: none; border: none; cursor: pointer; padding: 8px; }
.burger span { display: block; width: 22px; height: 2px; background: var(--navy); margin: 5px 0; }

/* ===== BREADCRUMB ===== */
.breadcrumb { background: var(--paper); border-bottom: 1px solid var(--gray-200); padding: 14px 0; }
.breadcrumb ol { display: flex; flex-wrap: wrap; gap: 6px; font-size: 0.8rem; color: var(--gray-400); }
.breadcrumb a { color: var(--gray-600); }
.breadcrumb a:hover { color: var(--gold-dark); }
.breadcrumb li:not(:last-child)::after { content: '/'; margin-left: 6px; color: var(--gray-200); }
.breadcrumb li { display: flex; }

/* ===== HERO (accueil) — asymétrique ===== */
.hero {
    background: linear-gradient(150deg, var(--navy-deep) 0%, var(--navy) 55%, var(--navy-light) 100%);
    position: relative; overflow: hidden;
}
.hero .blob { background: rgba(184,150,79,0.16); }
.hero .blob-1 { width: 460px; height: 460px; top: -140px; right: -80px; }
.hero .blob-2 { width: 280px; height: 280px; bottom: -100px; left: -60px; background: rgba(255,255,255,0.04); }
.hero-grid {
    position: relative; z-index: 1; display: grid; grid-template-columns: 1.1fr 0.9fr;
    align-items: center; gap: 40px; padding: 96px 0 64px;
}
.hero-tag {
    display: inline-flex; align-items: center; gap: 8px; font-size: 0.72rem; font-weight: 600; letter-spacing: 2.5px;
    text-transform: uppercase; color: var(--gold-light); margin-bottom: 26px;
    padding: 7px 16px; border: 1px solid rgba(217,188,126,0.35); border-radius: var(--radius-pill);
}
.hero-tag .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--gold); animation: pulse 2s ease-in-out infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.35; } }
.hero h1 { font-size: 3rem; font-weight: 500; color: var(--white); line-height: 1.18; margin-bottom: 22px; letter-spacing: -0.5px; }
.hero h1 strong { font-weight: 700; color: var(--gold-light); }
.hero p { font-size: 1.08rem; color: rgba(255,255,255,0.68); line-height: 1.75; max-width: 520px; margin-bottom: 34px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-cta {
    display: inline-flex; align-items: center; gap: 10px; background: var(--gold); color: var(--white);
    padding: 15px 30px; font-size: 0.85rem; font-weight: 600; letter-spacing: 0.3px;
    border-radius: var(--radius-pill); transition: all 0.3s var(--ease); box-shadow: 0 8px 24px rgba(184,150,79,0.25);
}
.hero-cta:hover { background: var(--gold-dark); transform: translateY(-2px); box-shadow: 0 12px 30px rgba(184,150,79,0.35); }
.hero-cta-outline {
    display: inline-flex; align-items: center; gap: 10px; background: rgba(255,255,255,0.06); color: var(--white);
    padding: 14px 28px; font-size: 0.85rem; font-weight: 600; border: 1px solid rgba(255,255,255,0.22);
    border-radius: var(--radius-pill); transition: all 0.3s var(--ease);
}
.hero-cta-outline:hover { border-color: var(--gold); background: rgba(255,255,255,0.1); }
.hero-visual { position: relative; display: flex; align-items: center; justify-content: center; height: 340px; }
.hero-visual .ring { position: absolute; border: 1.5px solid rgba(217,188,126,0.3); border-radius: 50%; }
.hero-visual .ring-1 { width: 260px; height: 260px; animation: spinSlow 40s linear infinite; }
.hero-visual .ring-2 { width: 340px; height: 340px; border-style: dashed; animation: spinSlow 60s linear infinite reverse; }
@keyframes spinSlow { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
.hero-visual .mark { width: 130px; height: 130px; filter: drop-shadow(0 20px 40px rgba(0,0,0,0.35)); animation: floatY 5s ease-in-out infinite; }
@keyframes floatY { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-14px); } }

/* ===== WAVE DIVIDER ===== */
.wave-divider { position: relative; height: 70px; margin-top: -1px; }
.wave-divider svg { position: absolute; inset: 0; width: 100%; height: 100%; }

/* ===== SECTION HEADERS ===== */
.section-header { text-align: center; margin-bottom: 52px; }
.section-header.left { text-align: left; margin: 0 0 32px; }
.section-header .overline { font-size: 0.7rem; font-weight: 600; letter-spacing: 3px; text-transform: uppercase; color: var(--gold-dark); margin-bottom: 14px; }
.section-header h2 { font-size: 2.2rem; font-weight: 600; color: var(--navy); margin-bottom: 16px; letter-spacing: -0.3px; }
.section-header p { font-size: 1.02rem; color: var(--gray-600); max-width: 560px; margin: 0 auto; }
.section-header.left p { margin: 0; }

/* ===== STATS — carte flottante ===== */
.stats-float { position: relative; z-index: 2; margin-top: -56px; padding: 0 24px 40px; }
.stats-card {
    max-width: 1000px; margin: 0 auto; background: var(--white); border-radius: var(--radius);
    box-shadow: var(--shadow-lg); display: grid; grid-template-columns: repeat(4, 1fr);
    overflow: hidden;
}
.stat { text-align: center; padding: 34px 16px; border-right: 1px solid var(--gray-100); }
.stat:last-child { border-right: none; }
.stat .number { font-family: var(--display); font-size: 2.5rem; font-weight: 600; color: var(--navy); line-height: 1; margin-bottom: 8px; }
.stat .number span { color: var(--gold); }
.stat .label { font-size: 0.74rem; font-weight: 500; color: var(--gray-400); text-transform: uppercase; letter-spacing: 1px; }
.presentation-spacer { padding-top: 72px; background: var(--white); }

/* ===== MEMBRES — grille décalée ===== */
.membres { padding: 30px 0 90px; background: var(--white); }
.membres-grid { display: flex; flex-wrap: wrap; gap: 26px; justify-content: center; max-width: 900px; margin: 0 auto; }
.membre-card {
    width: calc(33.333% - 26px); min-width: 250px; max-width: 380px; background: var(--paper);
    border-radius: var(--radius); padding: 30px 26px; border: 1px solid var(--gray-200);
    transition: all 0.4s var(--ease); display: flex; flex-direction: column;
}
.membre-card:hover { box-shadow: var(--shadow-md); transform: translateY(-6px); background: var(--white); border-color: var(--gold); }
.membre-card .tag {
    display: inline-block; font-size: 0.65rem; font-weight: 600; letter-spacing: 2px; text-transform: uppercase;
    color: var(--gold-dark); background: rgba(184,150,79,0.12); padding: 5px 12px; border-radius: var(--radius-pill);
    margin-bottom: 16px; width: fit-content;
}
.membre-card h3 { font-size: 1.15rem; font-weight: 700; color: var(--navy); margin-bottom: 4px; }
.membre-card .loc { font-size: 0.8rem; color: var(--gray-400); margin-bottom: 16px; }
.membre-card .desc { font-size: 0.88rem; color: var(--gray-600); line-height: 1.6; flex: 1; margin-bottom: 20px; }
.membre-card .links { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.membre-card .link { display: inline-flex; align-items: center; gap: 6px; font-size: 0.82rem; font-weight: 600; color: var(--navy); }
.membre-card .link:hover { color: var(--gold-dark); }
.membre-card .link svg { transition: transform 0.25s var(--ease); }
.membre-card .link:hover svg { transform: translateX(4px); }
.membre-card .ext { font-size: 0.78rem; color: var(--gray-400); }
.membre-card .ext:hover { color: var(--navy); }

/* ===== CARTE ===== */
.carte-section { padding: 30px 0 90px; background: var(--paper); }
.carte-section .section-header { margin-bottom: 40px; }
.map-frame { max-width: 1000px; margin: 0 auto; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-md); border: 1px solid var(--gray-200); }
#map { width: 100%; height: 420px; }
.infracop-marker span { display: block; width: 14px; height: 14px; border-radius: 50%; background: var(--gold); border: 3px solid var(--navy); box-shadow: 0 2px 6px rgba(20,42,71,0.35); }
.leaflet-popup-content-wrapper { border-radius: var(--radius-sm); font-family: 'Inter', sans-serif; }
.leaflet-popup-content strong { color: var(--navy); }

/* ===== EXPERTISES — zigzag éditorial ===== */
.expertises { padding: 30px 0 100px; background: var(--white); }
.expert-rows { display: flex; flex-direction: column; gap: 64px; margin-top: 20px; }
.expert-row { display: grid; grid-template-columns: 220px 1fr; gap: 44px; align-items: center; }
.expert-row:nth-child(2n) { grid-template-columns: 1fr 220px; }
.expert-row:nth-child(2n) .expert-visual { order: 2; }
.expert-visual {
    width: 220px; height: 220px; border-radius: var(--radius); background: linear-gradient(145deg, var(--navy) 0%, var(--navy-light) 100%);
    display: flex; align-items: center; justify-content: center; color: var(--gold-light); position: relative; overflow: hidden;
}
.expert-visual::before {
    content: ''; position: absolute; width: 140px; height: 140px; border-radius: 62% 38% 55% 45% / 45% 55% 45% 55%;
    background: rgba(255,255,255,0.06); top: -30px; right: -30px;
}
.expert-visual svg { width: 64px; height: 64px; position: relative; z-index: 1; }
.expert-text h3 { font-size: 1.4rem; font-weight: 700; color: var(--navy); margin-bottom: 8px; }
.expert-text .tagline { font-size: 0.95rem; color: var(--gold-dark); font-weight: 500; margin-bottom: 14px; }
.expert-text ul { display: grid; grid-template-columns: repeat(2, 1fr); gap: 4px 24px; margin-bottom: 16px; }
.expert-text li { font-size: 0.9rem; color: var(--gray-600); padding: 4px 0 4px 18px; position: relative; }
.expert-text li::before { content: ''; position: absolute; left: 0; top: 12px; width: 6px; height: 6px; border-radius: 50%; background: var(--gold); }
.expert-text .more { display: inline-flex; align-items: center; gap: 6px; font-size: 0.85rem; font-weight: 700; color: var(--navy); }
.expert-text .more:hover { color: var(--gold-dark); }
.expert-text .more svg { transition: transform 0.25s var(--ease); }
.expert-text .more:hover svg { transform: translateX(4px); }

/* ===== PAGE HERO (sous-pages) ===== */
.page-hero { background: linear-gradient(150deg, var(--navy-deep) 0%, var(--navy) 60%, var(--navy-light) 100%); padding: 60px 0 84px; position: relative; overflow: hidden; }
.page-hero .blob { background: rgba(184,150,79,0.14); width: 380px; height: 380px; top: -160px; right: -100px; }
.page-hero .inner { position: relative; z-index: 1; max-width: 720px; }
.page-hero .overline { font-size: 0.72rem; font-weight: 600; letter-spacing: 3px; text-transform: uppercase; color: var(--gold-light); margin-bottom: 14px; }
.page-hero h1 { font-size: 2.3rem; font-weight: 600; color: var(--white); line-height: 1.25; margin-bottom: 16px; letter-spacing: -0.3px; }
.page-hero p { font-size: 1rem; color: rgba(255,255,255,0.68); max-width: 640px; }

/* ===== CONTENT (sous-pages) ===== */
.content { padding: 0 0 80px; position: relative; z-index: 2; margin-top: -40px; }
.content-card { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow-lg); padding: 48px; }
.content-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 56px; align-items: start; }
.prose h2 { font-size: 1.4rem; color: var(--navy); margin: 30px 0 12px; }
.prose h2:first-child { margin-top: 0; }
.prose p { color: var(--gray-600); margin-bottom: 16px; font-size: 0.98rem; }
.prose ul { margin: 0 0 20px; }
.prose li { color: var(--gray-600); font-size: 0.95rem; padding: 6px 0 6px 20px; position: relative; }
.prose li::before { content: ''; position: absolute; left: 0; top: 15px; width: 6px; height: 6px; border-radius: 50%; background: var(--gold); }

.side-card { background: var(--paper); border-radius: var(--radius-sm); padding: 26px 24px; margin-bottom: 18px; }
.side-card h3 { font-size: 0.95rem; color: var(--navy); margin-bottom: 12px; font-weight: 700; }
.side-card p { font-size: 0.88rem; color: var(--gray-600); margin-bottom: 14px; }
.side-card ul { display: flex; flex-direction: column; gap: 8px; }
.side-card a.chip {
    display: block; font-size: 0.85rem; color: var(--navy); font-weight: 600; padding: 9px 14px;
    background: var(--white); border: 1px solid var(--gray-200); border-radius: var(--radius-pill); transition: all 0.25s var(--ease);
}
.side-card a.chip:hover { border-color: var(--gold); color: var(--gold-dark); transform: translateX(3px); }

/* ===== CTA BAND ===== */
.cta-band { background: linear-gradient(120deg, var(--navy-deep), var(--navy)); padding: 64px 0; text-align: center; border-radius: var(--radius); margin: 0 24px 80px; max-width: 1112px; margin-inline: auto; position: relative; overflow: hidden; }
.cta-band .blob { background: rgba(184,150,79,0.12); width: 260px; height: 260px; bottom: -120px; left: -60px; }
.cta-band .inner { position: relative; z-index: 1; }
.cta-band h2 { font-family: var(--display); font-size: 1.7rem; color: var(--white); margin-bottom: 10px; font-weight: 600; }
.cta-band p { color: rgba(255,255,255,0.62); margin-bottom: 28px; }

/* ===== CONTACT ===== */
.contact { padding: 30px 0 100px; background: var(--white); }
.contact-card {
    max-width: 900px; margin: 0 auto; background: linear-gradient(135deg, var(--navy-deep), var(--navy));
    border-radius: var(--radius); padding: 56px; text-align: center; position: relative; overflow: hidden;
}
.contact-card .blob { background: rgba(184,150,79,0.14); width: 300px; height: 300px; top: -140px; right: -80px; }
.contact-card .inner { position: relative; z-index: 1; }
.contact .section-header h2 { color: var(--white); }
.contact .section-header p { color: rgba(255,255,255,0.55); }
.contact-email {
    font-size: 1.5rem; font-weight: 700; color: var(--gold-light); letter-spacing: 0.5px; padding: 16px 36px;
    border: 2px solid var(--gold); border-radius: var(--radius-pill); transition: all 0.3s var(--ease); display: inline-block; margin-top: 10px;
}
.contact-email:hover { background: var(--gold); color: var(--white); }

/* ===== FOOTER ===== */
footer { background: var(--black); padding: 40px 0 36px; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px; }
.footer-left { display: flex; align-items: center; gap: 12px; }
.footer-left img { width: 28px; height: 28px; opacity: 0.7; }
.footer-copy { font-size: 0.78rem; color: rgba(255,255,255,0.3); }
.footer-nav { display: flex; gap: 20px; flex-wrap: wrap; }
.footer-nav a { font-size: 0.78rem; color: rgba(255,255,255,0.4); transition: color 0.2s; }
.footer-nav a:hover { color: var(--gold); }

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
    .hero-grid { grid-template-columns: 1fr; padding-top: 64px; }
    .hero-visual { height: 220px; order: -1; }
    .hero p { max-width: 100%; }
    .stats-card { grid-template-columns: repeat(2, 1fr); }
    .stat:nth-child(2) { border-right: none; }
    .stat { border-bottom: 1px solid var(--gray-100); }
    .content-grid { grid-template-columns: 1fr; }
    .content-card { padding: 32px 24px; }
    .membre-card { width: 100%; max-width: 100%; }
    .expert-row, .expert-row:nth-child(2n) { grid-template-columns: 1fr; }
    .expert-visual, .expert-row:nth-child(2n) .expert-visual { order: -1; width: 100%; height: 140px; }
    .expert-text ul { grid-template-columns: 1fr; }
    .page-hero h1 { font-size: 1.7rem; }
    .footer-inner { flex-direction: column; text-align: center; }
}
@media (max-width: 700px) {
    nav { display: none; }
    nav.open {
        display: flex; flex-direction: column; position: absolute; top: 78px; left: 0; right: 0;
        background: var(--white); border-bottom: 1px solid var(--gray-200); padding: 12px; box-shadow: var(--shadow-md);
    }
    nav.open a { padding: 12px 16px; }
    nav.open a::after { display: none; }
    .burger { display: block; }
    .hero h1 { font-size: 2.1rem; }
    .stats-card { grid-template-columns: 1fr 1fr; }
    .contact-card { padding: 36px 22px; }
}

@media (prefers-reduced-motion: reduce) {
    .reveal { opacity: 1; transform: none; transition: none; }
    .blob-anim, .ring-1, .ring-2, .mark, .hero-tag .dot { animation: none; }
}
