/* RESET & BASE */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    /* Palette AES - MODE CLAIR */
    --color-bg-main: #ffffff;
    --color-text-main: #1e293b;
    /* Bleu gris très sombre pour le texte */
    --color-primary-blue: #0284c7;
    /* Bleu vif pour light mode */
    --color-accent-orange: #f97316;
    /* Orange vif */

    /* Typography */
    --font-main: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

body {
    background-color: var(--color-bg-main);
    color: var(--color-text-main);
    font-family: var(--font-main);
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

/* TYPOGRAPHY */
h1,
h2,
h3 {
    color: #0f1c2e;
    /* Dark slate */
    text-shadow: none;
    font-weight: 700;
    margin-bottom: 1rem;
}

/* Navigation Links */
nav a {
    color: var(--color-text-main);
    font-weight: 500;
    transition: color 0.3s ease;
}

nav a:hover {
    color: var(--color-primary-blue);
}

/* HEADER & NAVIGATION */
header {
    background-color: var(--color-bg-main);
    padding-bottom: 1rem;
}

header>div:first-child {
    background-color: var(--color-accent-orange);
    color: white;
    font-weight: bold;
    text-align: center;
    padding: 0.5rem 1rem;
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header>div:first-child a {
    background: white;
    color: var(--color-accent-orange);
    padding: 0.3rem 0.8rem;
    border-radius: 4px;
    font-size: 0.9rem;
    font-weight: 800;
    text-transform: uppercase;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
    position: sticky;
    top: 40px;
    /* Below the top bar */
    z-index: 999;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

nav h1 {
    margin: 0;
    font-size: 2rem;
    letter-spacing: -1px;
}

nav ul {
    display: none;
    /* Mobile first: hide menu links by default or keep simple */
}

/* HERO SECTION */
main>section:first-of-type {
    padding: 3rem 1.5rem;
    text-align: center;
    background: #f8fafc;
    /* Light Grey/White */
    border-bottom: 1px solid #e2e8f0;
}

main>section:first-of-type h2 {
    color: #0f1c2e;
    font-size: 2.2rem;
    line-height: 1.2;
    margin-bottom: 1rem;
}

main>section:first-of-type p {
    font-size: 1.1rem;
    color: #475569;
    margin-bottom: 2rem;
}

/* BUTTONS */
main>section:first-of-type div a {
    display: block;
    width: 100%;
    padding: 1rem;
    text-align: center;
    border-radius: 8px;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 1rem;
    transition: transform 0.2s;
}

main>section:first-of-type div a:first-child {
    background-color: var(--color-accent-orange);
    color: white;
    box-shadow: 0 4px 6px rgba(249, 115, 22, 0.3);
    animation: pulse 2s infinite;
}

main>section:first-of-type div a:last-child {
    background-color: transparent;
    border: 2px solid var(--color-primary-blue);
    color: var(--color-primary-blue);
}

@keyframes pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(249, 115, 22, 0.7);
    }

    70% {
        transform: scale(1.02);
        box-shadow: 0 0 0 10px rgba(249, 115, 22, 0);
    }

    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(249, 115, 22, 0);
    }
}

/* TRUST BADGES */
main>section:first-of-type ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
    padding: 0;
}

main>section:first-of-type ul li {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--color-primary-blue);
    background: #e0f2fe;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    white-space: nowrap;
}

/* SECTIONS GENERAL */
main>section:nth-of-type(2) {
    padding: 3rem 1.5rem;
}

main>section:nth-of-type(2) h3 {
    text-align: center;
    font-size: 1.8rem;
    margin-bottom: 2rem;
}

/* ARTICLES / CARDS */
article {
    background: white;
    padding: 2rem;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    transition: transform 0.3s, border-color 0.3s;
}

article:hover {
    transform: translateY(-5px);
    border-color: var(--color-primary-blue);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

article h4 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--color-primary-blue);
}

/* Icons via Unicode/Emoji for now */
article:nth-of-type(1) h4::before {
    content: "⏱️";
    font-size: 1.5rem;
    filter: none;
}

article:nth-of-type(2) h4::before {
    content: "💶";
    font-size: 1.5rem;
    filter: none;
}

article:nth-of-type(3) h4::before {
    content: "📍";
    font-size: 1.5rem;
    filter: none;
}

article p {
    color: #475569;
    font-size: 1rem;
}

/* LOGO */
.logo-img {
    height: 240px;
    /* Adjust based on logo aspect ratio */
    width: auto;
    display: block;
}

/* FOOTER */
footer {
    background-color: black;
    padding: 3rem 1.5rem;
    text-align: center;
    border-top: 1px solid rgba(0, 240, 255, 0.2);
    color: #cbd5e1;
}

footer p:first-child {
    font-weight: 700;
    color: white;
    margin-bottom: 2rem;
    font-size: 1.2rem;
    letter-spacing: 1px;
}

footer section h5 {
    color: var(--color-primary-blue);
    font-size: 1.1rem;
    margin-bottom: 1rem;
    text-transform: uppercase;
}

footer ul {
    margin-bottom: 2rem;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    padding: 0;
}

footer ul li {
    font-size: 0.9rem;
    color: #94a3b8;
}

footer a {
    color: #64748b;
    font-size: 0.8rem;
}

/* MEDIA QUERIES (DESKTOP) */
@media (min-width: 768px) {
    /* Changed from 1024px to 768px to align cards sooner */

    /* Header */
    nav ul {
        display: flex;
        /* Show menu on desktop */
        gap: 2rem;
    }

    /* Hero */
    main>section:first-of-type h2 {
        font-size: 3.5rem;
        max-width: 800px;
        margin: 0 auto 1.5rem auto;
    }

    main>section:first-of-type div {
        display: flex;
        justify-content: center;
        gap: 1.5rem;
    }

    main>section:first-of-type div a {
        width: auto;
        padding: 1rem 2rem;
        display: inline-block;
    }

    /* Content Cards Grid */
    .why-choose-us {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        /* Force 3 columns side-by-side */
        align-items: stretch;
        /* Stretch to same height */
        gap: 1.5rem;
        /* Reduced gap slightly */
        max-width: 1200px;
        margin: 0 auto;
    }

    /* Ensure title spans full width inside grid */
    .why-choose-us h3 {
        grid-column: 1 / -1;
    }

    article {
        margin-bottom: 0;
        /* Reset mobile margin */
        height: 100%;
        /* Equal height */
        display: flex;
        flex-direction: column;
        justify-content: center;
    }
}

/* TRUST BANNER */
.trust-banner {
    background-color: #0f1c2e;
    /* Dark Blue */
    color: white;
    font-size: 0.8rem;
    padding: 0.5rem 1rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    text-align: center;
}

.banner-badge {
    background: #fbbf24;
    /* Gold/Yellow */
    color: #0f1c2e;
    padding: 0.3rem 0.8rem;
    border-radius: 6px;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-transform: uppercase;
}

.banner-items {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    font-weight: 600;
}

.banner-sector {
    border-left: 1px solid rgba(255, 255, 255, 0.2);
    padding-left: 1rem;
    font-size: 0.75rem;
    line-height: 1.2;
    text-transform: uppercase;
    display: none;
}

@media (min-width: 768px) {
    .trust-banner {
        justify-content: space-between;
    }

    .banner-sector {
        display: block;
        text-align: left;
    }
}

/* CERTIFICATION SECTION */
.certification-section {
    padding: 2rem 1.5rem;
    background: #f1f5f9;
    text-align: center;
    /* Center aligning content container */
}

.cert-card {
    background: white;
    border: 2px solid #0f1c2e;
    border-radius: 16px;
    padding: 1.5rem 3rem;
    /* More horizontal padding, less vertical */
    max-width: 1200px;
    /* Wider card */
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    align-items: center;
    text-align: left;
}

.cert-badge-placeholder {
    width: 120px;
    /* Smaller badge to reduce height */
    height: 120px;
    background: #e2e8f0;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    font-weight: 700;
    color: #475569;
    font-size: 0.7rem;
    border: 4px solid #0f1c2e;
    flex-shrink: 0;
}

.cert-content {
    flex: 1;
    /* Take remaining width */
}

.cert-content h3 {
    font-size: 1.8rem;
    color: #0f1c2e;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.cert-content h3::before {
    content: "◉";
    color: #d97706;
    font-size: 1.2rem;
}

.cert-content p {
    font-size: 1rem;
    color: #334155;
    margin-bottom: 0.5rem;
    /* Reduced bottom margin */
}

.cert-footer {
    color: #d97706 !important;
    font-weight: 600;
    margin-top: 0.5rem;

    @media (min-width: 768px) {
        .cert-card {
            flex-direction: row;
            align-items: center;
            /* Vertically center items */
            text-align: left;
            padding: 2rem 4rem;
            /* Even wider on desktop */
        }
    }
}

/* SERVICE BENTO GRID */
.service-grid {
    padding: 3rem 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.grid-card {
    border-radius: 16px;
    padding: 2rem;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    position: relative;
    overflow: hidden;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    background-size: cover;
    background-position: center;
    border: none;
}

.grid-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(15, 28, 46, 0.3), rgba(15, 28, 46, 0.85));
    z-index: 1;
    transition: background 0.3s;
}

.grid-card:hover::before {
    background: linear-gradient(to bottom, rgba(15, 28, 46, 0.1), rgba(15, 28, 46, 0.7));
}

.grid-card:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.2), 0 10px 10px -5px rgba(0, 0, 0, 0.1);
}

.grid-card>* {
    position: relative;
    z-index: 2;
}

/* Target specific IDs for images */
#card-ouverture {
    background-image: url('ouverture.png');
}

#card-blindage {
    background-image: url('blindage.png');
}

#card-changement {
    background-image: url('changement.png');
}

#card-audit {
    background-image: url('audit.png');
}

.card-icon {
    font-size: 2rem;
    margin-bottom: 1rem;
    display: inline-block;
    padding: 0.5rem;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(5px);
    border-radius: 12px;
    width: fit-content;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.grid-card h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: white;
}

.grid-card p {
    font-size: 0.95rem;
    line-height: 1.5;
    color: #e2e8f0;
}

/* Styles Spécifiques - Cleaned up */
.card-dark,
.card-light,
.card-beige,
.card-wide {
    /* Resetting generic backgrounds as IDs take precedence */
    background-color: #1e293b;
}

.card-dark p,
.card-light p,
.card-beige p,
.card-wide p {
    color: #e2e8f0;
}

.card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: auto;
}

.card-tags span {
    background: rgba(251, 191, 36, 0.9);
    color: #0f1c2e;
    font-size: 0.7rem;
    font-weight: 800;
    padding: 0.3rem 0.6rem;
    border-radius: 4px;
    text-transform: uppercase;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.card-wide {
    flex-direction: column;
}


.grid-column-right {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.grid-split-row {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* Desktop Layout */
@media (min-width: 992px) {
    .service-grid {
        display: grid;
        grid-template-columns: 1.2fr 1fr;
        /* Left card slightly larger */
        grid-template-rows: auto;
    }

    .card-dark {
        min-height: 400px;
    }

    .card-wide {
        flex-direction: row;
        align-items: center;
        gap: 1.5rem;
    }

    .grid-split-row {
        flex-direction: row;
    }

    .grid-split-row>a {
        flex: 1;
    }
}

/* --- OUVERTURE PAGE SPECIFIC STYLES --- */

/* Hero Pedagogical */
.hero-pedagogical {
    background: linear-gradient(rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.8)), url('ouverture.png');
    background-size: cover;
    background-position: center;
    color: #0f1c2e;
    padding: 6rem 1.5rem;
    text-align: center;
}

.hero-content h1 {
    font-size: 2.5rem;
    color: black;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.highlight-blue {
    color: var(--color-primary-blue);
    text-shadow: 0 0 20px rgba(2, 132, 199, 0.5);
}

.cta-group {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    max-width: 400px;
    margin: 2rem auto 0;
}

.btn-primary {
    background: var(--color-accent-orange);
    color: white;
    padding: 1rem 2rem;
    border-radius: 8px;
    font-weight: 700;
    box-shadow: 0 4px 15px rgba(249, 115, 22, 0.4);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: white;
    padding: 1rem 2rem;
    border-radius: 8px;
    backdrop-filter: blur(5px);
}

/* Diagnostic Section */
.diagnostic-section,
.science-section {
    padding: 4rem 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 0.5rem;
    color: #0f1c2e;
}

.section-subtitle {
    text-align: center;
    color: #64748b;
    margin-bottom: 3rem;
}

.diagnostic-grid {
    display: grid;
    gap: 2rem;
}

.diag-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.1);
    border: 1px solid #e2e8f0;
}

.diag-header {
    padding: 1.5rem;
    color: white;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.card-green .diag-header {
    background: #10b981;
}

.card-orange .diag-header {
    background: #f59e0b;
}

.diag-header h3 {
    color: white;
    margin: 0;
    font-size: 1.5rem;
}

.diag-icon {
    font-size: 2rem;
}

.diag-body {
    padding: 2rem;
}

.diag-solution {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e2e8f0;
}

.diag-badge {
    display: inline-block;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    margin-top: 1rem;
}

.diag-badge.success {
    background: #d1fae5;
    color: #065f46;
}

.diag-badge.warning {
    background: #fef3c7;
    color: #92400e;
}

/* Science / Tools Section */
.tools-grid {
    display: grid;
    gap: 1.5rem;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.tool-card {
    background: #f8fafc;
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    text-align: center;
}

.tool-card h4 {
    color: #0f1c2e;
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

/* Transparency Section */
.transparency-section {
    background: #0f1c2e;
    color: white;
    padding: 4rem 1.5rem;
    text-align: center;
}

.transparency-container h2 {
    color: white;
}

.transparency-container p {
    color: #94a3b8;
}

.price-breakdown {
    text-align: left;
    max-width: 500px;
    margin: 2rem auto;
    background: rgba(255, 255, 255, 0.05);
    padding: 2rem;
    border-radius: 12px;
}

.price-breakdown li {
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    color: #cbd5e1;
}

.price-breakdown li:last-child {
    border: none;
}

.price-breakdown strong {
    color: #fbbf24;
    display: inline-block;
    width: 50px;
}

@media (min-width: 768px) {
    .cta-group {
        flex-direction: row;
        justify-content: center;
        max-width: none;
    }

    .diagnostic-grid {
        grid-template-columns: 1fr 1fr;
    }
}

/* Diagnostic Images */
.diag-img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

/* Adjust card header to be below image */
.diag-header {
    border-radius: 0;
}/* --- BLINDAGE PAGE SPECIFIC STYLES --- */

.hero-blindage {
    background: linear-gradient(rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.8)), url('blindage.png');
    background-size: cover;
    background-position: center;
}

.diag-list {
    list-style: none;
    padding: 0;
    margin-top: 1rem;
    text-align: left;
}

.diag-list li {
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
    color: #475569;
}/* --- CHANGEMENT PAGE SPECIFIC STYLES --- */

.hero-changement {
    background: linear-gradient(rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.8)), url('changement.png');
    background-size: cover;
    background-position: center;
}/* --- AUDIT PAGE SPECIFIC STYLES --- */

.hero-audit {
    background: linear-gradient(rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.8)), url('audit.png');
    background-size: cover;
    background-position: center;
}/* --- CONTACT PAGE SPECIFIC STYLES --- */

/* Hero Contact - Reusing logic but simpler background? Or maybe a generic office/phone img? 
   Let's make it dark blue gradient for professional feel if no image yet. 
*/
.hero-contact {
    background: linear-gradient(135deg, #0f1c2e 0%, #1e293b 100%);
    color: white;
    padding: 6rem 1.5rem;
    text-align: center;
}

.hero-contact .highlight-blue {
    color: #38bdf8;
    /* Lighter blue for dark background */
}

/* Contact Grid */
.contact-info-section {
    padding: 4rem 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
}

.contact-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    justify-content: center;
}

.info-card {
    background: white;
    padding: 2rem;
    border-radius: 16px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    border: 1px solid #e2e8f0;
    text-align: center;
    flex: 1;
    min-width: 250px;
    max-width: 350px;
}

.contact-link {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--color-primary-blue);
    text-decoration: none;
}

/* Map & Reviews */
.map-reviews-section {
    background: #f8fafc;
    padding: 0 0 4rem 0;
    /* Map touches top */
}

.map-container iframe {
    /* Full width map */
    filter: grayscale(20%) contrast(1.1);
    /* Slight aesthetic tweak */
}

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

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

.review-card {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.05);
    position: relative;
    border-top: 4px solid var(--color-accent-orange);
}

.review-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.avatar {
    width: 40px;
    height: 40px;
    background: #e2e8f0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: #475569;
}

.stars {
    color: #fbbf24;
    font-size: 0.9rem;
}

.date {
    margin-left: auto;
    font-size: 0.8rem;
    color: #94a3b8;
}

.review-text {
    font-style: italic;
    color: #334155;
    margin-bottom: 1.5rem;
}

.service-tag {
    position: absolute;
    bottom: 1rem;
    right: 2rem;
    font-size: 0.7rem;
    text-transform: uppercase;
    color: #94a3b8;
    font-weight: 600;
}