/* ==========================================================================
   CheckV16 - CSS RECONSTRUIT ET UNIFIÉ (Home + Productos)
   ========================================================================== */

/* --- 1. VARIABLES & RESET --- */
:root {
    --primary-blue: #1a365d;
    /* Hero & Footer */
    --text-dark: #1f2937;
    /* Textes principaux */
    --text-light: #6b7280;
    /* Sous-titres */
    --accent-yellow: #F1BF00;
    /* Boutons action */
    --amazon-orange: #FF9900;
    /* Boutons Amazon */
    --amazon-dark: #e68a00;
    --bg-light: #f9fafb;
    /* Fond de page */
    --bg-white: #ffffff;
    --success-green: #10B981;
    --danger-red: #AA151B;
    --border-color: #e5e7eb;
    --border-radius: 8px;
    --container-width: 1100px;
}

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--bg-light);
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: inline-block;
    border-radius: var(--border-radius);
}

a {
    text-decoration: none;
    color: inherit;
    transition: 0.3s ease;
}

ul,
ol {
    list-style: none;
}

/* --- 2. HEADER & NAV --- */
.site-header {
    background-color: var(--bg-white);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.container {
    width: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 1rem;
}

.site-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--danger-red);
    text-transform: uppercase;
}

.main-nav {
    display: flex;
    gap: 1.5rem;
}

.main-nav a {
    font-weight: 500;
    color: var(--text-dark);
}

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

/* Menu Burger (Mobile) */
.mobile-menu-button {
    display: none;
    padding: 8px;
    cursor: pointer;
    background: transparent;
    border: none;
}

.mobile-menu-button .line {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--text-dark);
    margin: 5px 0;
    transition: transform 0.3s ease-out, opacity 0.3s ease-out;
}


@media (max-width: 768px) {
    .main-nav {
        display: none;
    }

    .mobile-menu-button {
        display: block;
    }
}

/* --- 3. HOME PAGE: BLOC RECHERCHE (VERIFIER) --- */
.verifier-section {
    background-color: #fffbeb;
    padding: 3rem 0;
    text-align: center;
}

.verifier-section h1 {
    margin-bottom: 1rem;
    color: var(--primary-blue);
}

.search-form-container {
    max-width: 600px;
    margin: 0 auto;
    position: relative;
    text-align: left;
}

.search-input {
    width: 100%;
    padding: 1rem;
    font-size: 1rem;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

#search-results {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: white;
    border: 1px solid #ddd;
    z-index: 99;
    max-height: 250px;
    overflow-y: auto;
    display: none;
    border-radius: 0 0 8px 8px;
}

#search-results li {
    padding: 10px;
    border-bottom: 1px solid #eee;
    cursor: pointer;
}

#search-results li:hover {
    background-color: #f5f5f5;
}

.post-search-cta {
    margin-top: 1.5rem;
    text-align: center;
}

.cta-button.amazon {
    background-color: var(--amazon-orange);
    color: #111;
    padding: 0.8rem 1.5rem;
    border-radius: 8px;
    font-weight: 700;
    display: inline-block;
}

/* --- 4. HOME PAGE: HERO SECTION --- */
.hero-section {
    background-color: var(--primary-blue);
    color: white;
    text-align: center;
    padding: 4rem 0;
}

.hero-content h2,
.hero-subtitle {
    color: white;
}

.hero-subtitle {
    margin: 1rem auto 2rem;
    max-width: 700px;
    font-size: 1.1rem;
    opacity: 0.9;
}

.hero-image {
    margin: 2rem 0;
}

.hero-image img {
    max-width: 500px;
    margin: 0 auto;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    background-color: #eee;
    min-height: 200px;
}

.hero-cta {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
}

.cta-button {
    background-color: var(--accent-yellow);
    color: var(--text-dark);
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: bold;
}

.cta-button-secondary {
    background: transparent;
    border: 2px solid white;
    color: white;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: bold;
}

/* --- 5. HOME PAGE: SECTIONS --- */
.intro-section,
.guide-section,
.installation-section,
.brands-section,
.regulation-section,
.faq-section,
.final-cta-section,
.intro-section-condensed,
.guide-section-condensed,
.installation-section-condensed {
    padding: 3rem 0;
}

section {
    border-bottom: 1px solid var(--border-color);
}

section:last-of-type {
    border-bottom: none;
}


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

.fact-item {
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.fact-icon {
    font-size: 2.5rem;
    color: var(--primary-blue);
}

.content-wrapper,
.installation-content,
.regulation-content {
    display: grid;
    gap: 3rem;
    align-items: center;
}

.image-content,
.installation-image,
.regulation-image,
.technical-image-container {
    text-align: center;
    background: #f3f4f6;
    border-radius: 8px;
    padding: 10px;
}

@media (min-width: 900px) {

    .content-wrapper,
    .installation-content,
    .regulation-content {
        grid-template-columns: 1fr 1fr;
    }
}

.features-list ul li::before {
    content: '✓';
    color: var(--success-green);
    padding-right: 10px;
}

ol.simple-steps li {
    padding: 0.5rem 0;
    font-size: 1.1rem;
    border-bottom: 1px solid var(--border-color);
}

ol.simple-steps li:last-child {
    border-bottom: none;
}

.faq-grid {
    display: grid;
    gap: 1.5rem;
}

.faq-item {
    background: var(--bg-white);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
}

.faq-item h3 {
    margin-bottom: 0.5rem;
}


/* --- 6. PAGE PRODUIT --- */
.product-page-container {
    max-width: 1000px;
    margin: 3rem auto;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.certification-status {
    background-color: var(--success-green);
    color: white;
    text-align: center;
    font-weight: bold;
    padding: 0.75rem;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.product-page-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
}

@media (min-width: 768px) {
    .product-page-grid {
        grid-template-columns: 40% 60%;
        align-items: stretch;
    }
}

.product-image-container {
    background-color: #f3f4f6;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
    min-height: 300px;
}

.product-image {
    max-width: 100%;
    max-height: 300px;
    mix-blend-mode: multiply;
    object-fit: contain;
}

.product-info {
    padding: 2rem;
}

.product-info h1 {
    font-size: 1.2rem;
    color: var(--text-light);
    text-transform: uppercase;
    margin-bottom: 0.25rem;
}

.product-info h2 {
    font-size: 2rem;
    color: var(--primary-blue);
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.product-details-list {
    margin-bottom: 2rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
}

.product-details-list li {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border-color);
}

.product-details-list li:last-child {
    border-bottom: none;
}

.main-action-button {
    display: inline-block;
    text-decoration: underline;
    color: var(--primary-blue);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.affiliation-section {
    grid-column: 1 / -1;
    background-color: #fff7ed;
    padding: 2rem;
    text-align: center;
    border-top: 1px solid var(--border-color);
}

.btn-affiliate.amazon-generic,
.cta-button.large {
    display: inline-block;
    background-color: var(--amazon-orange);
    color: #111;
    padding: 1rem 2rem;
    font-weight: 800;
    border-radius: 8px;
    font-size: 1.1rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 400px;
}

.btn-affiliate.amazon-generic:hover,
.cta-button.large:hover {
    background-color: var(--amazon-dark);
    transform: translateY(-2px);
}

/* --- 7. FOOTER & CTA --- */
.final-cta-section {
    background-color: var(--primary-blue);
    padding: 3rem 0;
    text-align: center;
    color: white;
}

.final-cta-section h2,
.final-cta-section p {
    color: white;
}

.site-footer {
    background-color: #0f172a;
    color: #94a3b8;
    padding: 3rem 0;
    text-align: center;
    font-size: 0.9rem;
}

.floating-cta {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background-color: var(--amazon-orange);
    color: #1f2937;
    padding: 1rem 2rem;
    border-radius: 50px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    font-weight: 700;
    z-index: 999;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}

.floating-cta.visible {
    opacity: 1;
    pointer-events: auto;
}

/* --- 8. STYLES POUR MENU MOBILE ACTIF --- */
/* (Uniquement pour écrans < 768px) */
@media (max-width: 768px) {

    /* Style du menu NAV qui va s'afficher */
    .main-nav.is-active {
        display: flex;
        flex-direction: column;
        /* Aligne les liens en colonne */
        align-items: center;
        /* Centre les liens */
        position: absolute;
        top: 100%;
        /* S'affiche juste en dessous du header */
        left: 0;
        width: 100%;
        background-color: var(--bg-white);
        padding: 2rem;
        /* Plus d'espace intérieur */
        border-top: 1px solid var(--border-color);
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
        animation: dropDown 0.3s ease-in-out;
    }

    @keyframes dropDown {
        from {
            opacity: 0;
            transform: translateY(-10px);
        }

        to {
            opacity: 1;
            transform: translateY(0);
        }
    }

    /* Transformation du bouton Hamburger en Croix (X) */
    .mobile-menu-button.is-active .line:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .mobile-menu-button.is-active .line:nth-child(2) {
        opacity: 0;
    }

    .mobile-menu-button.is-active .line:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }
}