/* =========================================
   1. VARIABLES & RESET (Palette Moderne)
   ========================================= */
:root {
    /* Couleurs Principales */
    --primary: #0097e0;
    /* Bleu Daikin */
    --primary-dark: #007bb5;
    --secondary: #0f172a;
    /* Bleu Nuit Profond (Slate 900) */

    /* Couleurs de Texte */
    --text-main: #334155;
    /* Gris Ardoise (Slate 700) */
    --text-light: #64748b;
    /* Gris Clair (Slate 500) */

    /* Couleurs d'État (Gravité) */
    --red: #ef4444;
    --red-bg: #fef2f2;
    --orange: #f97316;
    --orange-bg: #fff7ed;
    --green: #22c55e;
    --green-bg: #f0fdf4;

    /* Structure */
    --bg-body: #f8fafc;
    /* Fond très léger */
    --white: #ffffff;
    --radius: 12px;

    /* Ombres */
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
}

body {
    font-family: 'Inter', 'Segoe UI', system-ui, sans-serif;
    background: var(--bg-body);
    color: var(--text-main);
    margin: 0;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a {
    text-decoration: none;
    color: inherit;
    transition: 0.2s;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

/* =========================================
   2. HEADER (Sticky & Glassmorphism)
   ========================================= */
.main-header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(8px);
    border-bottom: 1px solid #e2e8f0;
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-flex {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Container (The Link) */
.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    /* Ensures it centers within the header height */
    text-decoration: none;
    transition: opacity 0.2s ease;
}

.logo:hover {
    opacity: 0.9;
    /* Slight effect on hover */
}

/* The Image itself */
.logo img {
    display: block;
    /* Removes tiny space below image */
    max-height: 50px;
    /* Controls the maximum size */
    width: auto;
    /* Maintains aspect ratio (prevents squishing) */
    object-fit: contain;
    /* Ensures the whole logo is visible */

    /* Optional: If your JPG is square and you want rounded corners */
    /* border-radius: 6px; */
}

/* Mobile Adjustment (Optional) */
@media (max-width: 768px) {
    .logo img {
        max-height: 40px;
        /* Smaller on mobile */
    }
}

.logo-icon {
    font-size: 1.4rem;
}

.tld {
    color: var(--primary);
    font-weight: 400;
    opacity: 0.8;
}

.header-tagline {
    font-size: 0.85rem;
    color: var(--text-light);
    font-weight: 500;
    display: none;
}

@media (min-width: 768px) {
    .header-tagline {
        display: block;
    }
}

.cta-header {
    background: var(--primary);
    color: var(--white);
    padding: 8px 16px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.9rem;
    box-shadow: var(--shadow-sm);
}

.cta-header:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

/* =========================================
   3. HERO SECTION (NOUVEAU DESIGN)
   ========================================= */
.hero-section {
    position: relative;
    background: linear-gradient(135deg, var(--secondary) 0%, #1e293b 100%);
    color: var(--white);
    padding: 60px 0 100px;
    /* Espace pour que la carte flotte */
    overflow: hidden;
}

/* Motif de fond subtil */
.hero-bg-pattern {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: radial-gradient(circle at 1px 1px, rgba(255, 255, 255, 0.08) 1px, transparent 0);
    background-size: 30px 30px;
    pointer-events: none;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    position: relative;
    z-index: 2;
}

@media (max-width: 900px) {
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

/* Texte Hero */
.hero-badge {
    display: inline-block;
    background: rgba(0, 151, 224, 0.15);
    color: #38bdf8;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 20px;
    border: 1px solid rgba(56, 189, 248, 0.3);
}

.hero-text h1 {
    font-size: 3rem;
    line-height: 1.1;
    font-weight: 800;
    margin: 0 0 20px 0;
    letter-spacing: -1px;
}

.hero-text h1 .highlight {
    background: linear-gradient(to right, #38bdf8, #0097e0);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-lead {
    font-size: 1.1rem;
    color: #94a3b8;
    margin-bottom: 30px;
}

/* Chiffres Clés (Trust Metrics) */
.trust-metrics {
    display: flex;
    gap: 40px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 30px;
}

@media (max-width: 900px) {
    .trust-metrics {
        justify-content: center;
    }
}

.metric {
    display: flex;
    flex-direction: column;
}

.metric-val {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--white);
}

.metric-label {
    font-size: 0.8rem;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

/* Carte Flottante (Sélecteur) */
.hero-selector-card {
    background: var(--white);
    padding: 30px;
    border-radius: 20px;
    box-shadow: var(--shadow-lg);
    color: var(--secondary);
    text-align: left;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.hero-selector-card h2 {
    margin: 0 0 5px 0;
    font-size: 1.4rem;
    color: var(--secondary);
}

.hero-selector-card p {
    color: var(--text-light);
    margin-bottom: 20px;
    font-size: 0.9rem;
}

.selector-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

@media (max-width: 600px) {
    .selector-grid {
        grid-template-columns: 1fr;
    }
}

.device-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    background: var(--white);
}

.device-card:hover {
    border-color: var(--primary);
    background: #f0f9ff;
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.device-icon {
    font-size: 1.4rem;
}

.device-info {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.device-name {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.device-type {
    font-size: 0.75rem;
    font-weight: 600;
    margin-top: 2px;
}

.device-arrow {
    color: #cbd5e1;
    font-weight: 800;
}

.tag-pac {
    color: #0284c7;
}

.tag-clim {
    color: #059669;
}

.selector-footer {
    margin-top: 20px;
    text-align: center;
    font-size: 0.85rem;
}

.selector-footer a {
    color: var(--primary);
    font-weight: 600;
}

/* =========================================
   4. FEATURES & SEO HOME
   ========================================= */
.features-section {
    padding: 80px 0;
    background: var(--white);
}

.features-section h2 {
    text-align: center;
    margin-bottom: 50px;
    font-size: 2rem;
    color: var(--secondary);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
}

.feature-item h3 {
    color: var(--secondary);
    margin-bottom: 10px;
    font-size: 1.2rem;
}

.feature-item p {
    color: var(--text-light);
}

.all-models-section {
    padding: 60px 0;
    background: #f1f5f9;
    border-top: 1px solid #e2e8f0;
}

.links-list {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 20px;
}

.links-list a {
    color: var(--text-light);
    font-size: 0.9rem;
    text-decoration: underline;
    text-decoration-color: #cbd5e1;
}

.links-list a:hover {
    color: var(--primary);
}

/* =========================================
   5. PAGE CODE ERREUR (Landing)
   ========================================= */
.layout-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 40px;
    margin-top: 30px;
}

@media (max-width: 900px) {
    .layout-grid {
        grid-template-columns: 1fr;
    }
}

/* Fil d'Ariane */
.breadcrumbs {
    display: flex;
    align-items: center;
    gap: 8px;
    list-style: none;
    padding: 20px 0 10px;
    margin: 0;
    font-size: 0.9rem;
    flex-wrap: wrap;
}

.breadcrumbs li {
    display: flex;
    align-items: center;
    gap: 8px;
}

.breadcrumbs li:not(:first-child)::before {
    content: "/";
    color: #cbd5e1;
    font-weight: bold;
}

.breadcrumbs a {
    color: var(--text-light);
    transition: 0.2s;
}

.breadcrumbs a:hover {
    color: var(--primary);
}

/* Bandeau Erreur */
.error-banner {
    display: flex;
    align-items: center;
    gap: 25px;
    background: var(--white);
    padding: 30px;
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    border-left: 8px solid var(--primary);
    margin-bottom: 25px;
}

.error-code {
    font-size: 3.5rem;
    font-weight: 900;
    color: var(--secondary);
    line-height: 1;
    letter-spacing: -1px;
}

.error-info h1 {
    margin: 0;
    font-size: 1.5rem;
    color: var(--primary);
    font-weight: 700;
}

.error-desc {
    margin: 5px 0 0;
    color: var(--text-light);
    font-style: italic;
    font-size: 1.1rem;
}

/* Variantes de Gravité */
.error-banner.gravity-medium {
    border-left-color: var(--orange);
}

.error-banner.gravity-critical {
    border-left-color: var(--red);
}

.error-banner.gravity-critical .error-code {
    color: var(--red);
}

/* Alerte Gravité */
.gravity-alert {
    padding: 20px;
    border-radius: 8px;
    background: var(--green-bg);
    border: 1px solid #bbf7d0;
    color: #166534;
    margin-bottom: 25px;
}

.gravity-alert strong {
    display: block;
    margin-bottom: 5px;
    font-size: 1.05rem;
}

.gravity-alert.gravity-medium {
    background: var(--orange-bg);
    border-color: #fed7aa;
    color: #9a3412;
}

.gravity-alert.gravity-critical {
    background: var(--red-bg);
    border-color: #fecaca;
    color: #991b1b;
}

/* Contenu Principal */
.content-box {
    background: var(--white);
    padding: 35px;
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    border: 1px solid #e2e8f0;
}

.content-box h2 {
    margin-top: 0;
    color: var(--secondary);
    font-size: 1.6rem;
}

.content-box h3 {
    color: var(--secondary);
    font-size: 1.2rem;
    margin-top: 25px;
    margin-bottom: 15px;
}

.content-box p {
    color: var(--text-main);
    margin-bottom: 15px;
}

.cause-list {
    padding-left: 0;
    list-style: none;
}

.cause-list li {
    position: relative;
    padding-left: 20px;
    margin-bottom: 10px;
    color: var(--text-main);
}

.cause-list li::before {
    content: "•";
    color: var(--primary);
    font-weight: bold;
    font-size: 1.5rem;
    position: absolute;
    left: 0;
    top: -5px;
}

.alert-gaz {
    background: #fffbeb;
    border-left: 4px solid #f59e0b;
    padding: 15px;
    margin: 20px 0;
    font-size: 0.9rem;
    color: #92400e;
}

/* =========================================
   6. SIDEBAR & FORMULAIRE (Sticky)
   ========================================= */
.lead-card {
    background: var(--white);
    padding: 25px;
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    border-top: 5px solid var(--primary);
}

.lead-card.sticky {
    position: sticky;
    top: 100px;
}

.lead-header {
    margin-bottom: 20px;
    text-align: center;
}

.lead-header h3 {
    margin: 0;
    color: var(--secondary);
    font-size: 1.3rem;
}

.lead-header p {
    margin: 5px 0 0;
    color: var(--text-light);
    font-size: 0.9rem;
}

.diagnosis-summary {
    background: var(--bg-body);
    padding: 12px;
    margin-bottom: 15px;
    border-radius: 6px;
    font-size: 0.9rem;
    color: var(--text-main);
    border-left: 3px solid var(--secondary);
}

#leadForm label {
    display: block;
    margin: 12px 0 5px;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--secondary);
}

#leadForm input,
#leadForm textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    font-family: inherit;
    box-sizing: border-box;
    transition: 0.2s;
}

#leadForm input:focus,
#leadForm textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(0, 151, 224, 0.1);
}

.input-group {
    display: flex;
    gap: 10px;
}

.input-group input {
    width: 50%;
}

.btn-submit {
    width: 100%;
    background: var(--primary);
    color: var(--white);
    padding: 16px;
    border: none;
    font-weight: 700;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1rem;
    margin-top: 20px;
    transition: background 0.2s;
}

.btn-submit:hover {
    background: var(--primary-dark);
}

.btn-submit:disabled {
    background: #cbd5e1;
    cursor: not-allowed;
}

/* Animation Pulse */
@keyframes pulse-btn {
    0% {
        box-shadow: 0 0 0 0 rgba(0, 151, 224, 0.7);
    }

    70% {
        box-shadow: 0 0 0 10px rgba(0, 151, 224, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(0, 151, 224, 0);
    }
}

.pulse-effect {
    animation: pulse-btn 2s infinite;
}

.rgpd {
    font-size: 0.75rem;
    color: #94a3b8;
    text-align: center;
    margin-top: 15px;
}

/* =========================================
   7. PAGE HUB MODELE (Liste Codes)
   ========================================= */
.hero-model {
    text-align: center;
    padding: 40px 0;
}

.hero-model h1 {
    color: var(--secondary);
    font-size: 2rem;
    margin-bottom: 10px;
}

.hero-model .lead {
    color: var(--text-light);
    max-width: 600px;
    margin: 0 auto;
}

.search-box-internal {
    position: relative;
    max-width: 500px;
    margin: 0 auto 30px;
}

.search-box-internal input {
    width: 100%;
    padding: 16px 20px;
    font-size: 1.1rem;
    border: 2px solid #e2e8f0;
    border-radius: 30px;
    box-shadow: var(--shadow-sm);
}

.search-box-internal input:focus {
    border-color: var(--primary);
    outline: none;
}

.codes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 15px;
}

.code-card {
    background: var(--white);
    padding: 15px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 15px;
    border: 1px solid #e2e8f0;
    transition: all 0.2s;
}

.code-card:hover {
    transform: translateY(-2px);
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
}

.code-badge {
    background: var(--bg-body);
    color: var(--secondary);
    font-weight: 700;
    padding: 6px 12px;
    border-radius: 6px;
    min-width: 45px;
    text-align: center;
}

.code-badge.red {
    background: var(--red-bg);
    color: var(--red);
}

.code-desc {
    flex-grow: 1;
    font-size: 0.9rem;
    color: var(--text-main);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.arrow {
    color: #cbd5e1;
    font-weight: 900;
}

/* Maillage Interne Bas de Page */
.related-codes {
    margin-top: 50px;
    padding-top: 30px;
    border-top: 1px solid #e2e8f0;
}

.related-codes h3 {
    color: var(--secondary);
    margin-bottom: 20px;
}

.tags-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.tags-cloud a {
    background: var(--white);
    border: 1px solid #e2e8f0;
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 0.85rem;
    color: var(--text-main);
    transition: 0.2s;
}

.tags-cloud a:hover {
    background: var(--primary);
    color: var(--white);
    border-color: var(--primary);
}

/* =========================================
   8. FOOTER
   ========================================= */
.main-footer {
    background: var(--secondary);
    color: #94a3b8;
    padding: 60px 0 30px;
    margin-top: 80px;
    text-align: center;
    font-size: 0.9rem;
}

.main-footer p {
    margin-bottom: 10px;
}

.disclaimer {
    opacity: 0.6;
    font-size: 0.8rem;
    max-width: 700px;
    margin: 20px auto 0;
}

/* =========================================
   9. MOBILE RESPONSIVE OPTIMIZATIONS
   ========================================= */
@media (max-width: 768px) {

    /* General Layout */
    .container {
        padding: 0 15px;
    }

    /* Header */
    .main-header {
        padding: 12px 0;
    }

    .logo {
        font-size: 1.1rem;
    }

    .logo-icon {
        font-size: 1.2rem;
    }

    /* Hero Section */
    .hero-section {
        padding: 40px 0 60px;
    }

    .hero-text h1 {
        font-size: 2rem;
        line-height: 1.2;
    }

    .hero-lead {
        font-size: 1rem;
    }

    .trust-metrics {
        gap: 20px;
        padding-top: 20px;
    }

    .metric-val {
        font-size: 1.5rem;
    }

    .metric-label {
        font-size: 0.7rem;
    }

    /* Selector Card */
    .hero-selector-card {
        padding: 20px;
    }

    .hero-selector-card h2 {
        font-size: 1.2rem;
    }

    .device-card {
        padding: 10px;
        min-height: 60px;
    }

    .device-icon {
        font-size: 1.2rem;
    }

    .device-name {
        font-size: 0.85rem;
    }

    .device-type {
        font-size: 0.7rem;
    }

    /* Features Section */
    .features-section {
        padding: 50px 0;
    }

    .features-section h2 {
        font-size: 1.5rem;
        margin-bottom: 30px;
    }

    .features-grid {
        gap: 25px;
    }

    .feature-item h3 {
        font-size: 1.1rem;
    }

    .feature-item p {
        font-size: 0.95rem;
    }

    /* All Models Section */
    .all-models-section {
        padding: 40px 0;
    }

    .all-models-section h3 {
        font-size: 1.3rem;
    }

    .links-list {
        gap: 10px;
    }

    .links-list a {
        font-size: 0.85rem;
        padding: 8px 12px;
        background: var(--white);
        border-radius: 6px;
        border: 1px solid #e2e8f0;
    }

    /* Footer */
    .main-footer {
        padding: 40px 0 20px;
        margin-top: 50px;
    }

    .main-footer p {
        font-size: 0.85rem;
    }

    .disclaimer {
        font-size: 0.75rem;
    }
}

/* Tablet adjustments (768px - 1024px) */
@media (min-width: 769px) and (max-width: 1024px) {
    .hero-text h1 {
        font-size: 2.5rem;
    }

    .selector-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Small mobile adjustments (below 480px) */
@media (max-width: 480px) {
    .hero-text h1 {
        font-size: 1.75rem;
    }

    .hero-badge {
        font-size: 0.75rem;
        padding: 5px 10px;
    }

    .device-card {
        padding: 8px;
    }

    .device-name {
        font-size: 0.8rem;
    }

    .selector-footer {
        font-size: 0.8rem;
    }

    .selector-footer a {
        display: block;
        margin-top: 5px;
    }
}

/* Ensure touch targets are at least 44x44px for mobile */
@media (max-width: 768px) {

    a.device-card,
    .links-list a {
        min-height: 44px;
        display: flex;
        align-items: center;
    }

    .device-card {
        padding: 12px;
    }
}

/* Prevent horizontal scroll on mobile */
@media (max-width: 768px) {
    body {
        overflow-x: hidden;
    }

    .container {
        max-width: 100%;
    }
}

/* Improve text readability on mobile */
@media (max-width: 768px) {
    body {
        -webkit-text-size-adjust: 100%;
        text-size-adjust: 100%;
    }

    .hero-text h1,
    .hero-lead,
    .feature-item p {
        word-wrap: break-word;
        overflow-wrap: break-word;
    }
}

/* =========================================
   10. LANDING CODE PAGE MOBILE STYLES
   ========================================= */
@media (max-width: 768px) {

    /* Breadcrumbs */
    .breadcrumbs {
        padding: 15px 0 10px;
        font-size: 0.85rem;
    }

    /* Error Banner */
    .error-banner {
        flex-direction: column;
        gap: 15px;
        padding: 20px;
        text-align: center;
    }

    .error-code {
        font-size: 2.5rem;
    }

    .error-info h1 {
        font-size: 1.2rem;
    }

    .error-desc {
        font-size: 1rem;
    }

    /* Gravity Alert */
    .gravity-alert {
        padding: 15px;
        font-size: 0.95rem;
    }

    /* Content Box */
    .content-box {
        padding: 20px;
    }

    .content-box h2 {
        font-size: 1.3rem;
    }

    .content-box h3 {
        font-size: 1.1rem;
    }

    /* Lead Card (Sticky on desktop) */
    .lead-card {
        padding: 20px;
        margin-top: 30px;
    }

    .lead-card.sticky {
        position: static;
        top: auto;
    }

    .lead-header h3 {
        font-size: 1.1rem;
    }

    .lead-header p {
        font-size: 0.85rem;
    }

    /* Diagnosis Summary */
    .diagnosis-summary {
        padding: 10px;
        font-size: 0.85rem;
    }

    /* Form Elements */
    #leadForm label {
        font-size: 0.85rem;
    }

    #leadForm input,
    #leadForm textarea {
        padding: 10px;
        font-size: 0.95rem;
    }

    .input-group {
        flex-direction: column;
        gap: 10px;
    }

    .input-group input {
        width: 100%;
    }

    .btn-submit {
        padding: 14px;
        font-size: 0.95rem;
    }

    .rgpd {
        font-size: 0.7rem;
    }

    /* Related Codes Section */
    .related-codes {
        margin-top: 30px;
        padding-top: 20px;
    }

    .related-codes h3 {
        font-size: 1.1rem;
        margin-bottom: 15px;
    }

    .related-subtitle {
        font-size: 0.9rem;
        margin-bottom: 15px;
    }

    .related-grid {
        display: flex;
        flex-direction: column;
        gap: 10px;
    }

    .related-card {
        padding: 12px;
        min-height: 50px;
    }

    .related-badge {
        font-size: 0.9rem;
        padding: 4px 8px;
    }

    .related-desc {
        font-size: 0.85rem;
    }

    /* Footer */
    .footer-content {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }

    .footer-section {
        padding: 0;
    }

    .footer-links {
        flex-direction: column;
        gap: 10px;
    }

    .footer-links a {
        padding: 8px 12px;
        background: rgba(255, 255, 255, 0.05);
        border-radius: 6px;
    }
}

/* Small mobile for landing code page */
@media (max-width: 480px) {
    .error-code {
        font-size: 2rem;
    }

    .error-info h1 {
        font-size: 1.1rem;
    }

    .content-box h2 {
        font-size: 1.2rem;
    }

    .related-card {
        padding: 10px;
    }
}

/* =========================================
   11. HUB MODELE PAGE MOBILE STYLES
   ========================================= */
@media (max-width: 768px) {

    /* Hero Model */
    .hero-model {
        padding: 30px 0;
    }

    .hero-model h1 {
        font-size: 1.5rem;
        margin-bottom: 10px;
    }

    .hero-model .lead {
        font-size: 0.95rem;
    }

    /* Search Box */
    .search-box-internal {
        margin-bottom: 25px;
    }

    .search-box-internal input {
        padding: 14px 18px;
        font-size: 1rem;
        border-width: 2px;
    }

    /* Codes Grid */
    .codes-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .code-card {
        padding: 12px;
        min-height: 55px;
    }

    .code-badge {
        font-size: 0.9rem;
        padding: 5px 10px;
        min-width: 40px;
    }

    .code-desc {
        font-size: 0.85rem;
    }
}

/* Small mobile for hub model page */
@media (max-width: 480px) {
    .hero-model h1 {
        font-size: 1.3rem;
    }

    .search-box-internal input {
        padding: 12px 15px;
        font-size: 0.95rem;
    }

    .code-card {
        padding: 10px;
    }

    .code-badge {
        font-size: 0.85rem;
        padding: 4px 8px;
    }

    .code-desc {
        font-size: 0.8rem;
    }
}

/* =========================================
   12. FORM VALIDATION & FEEDBACK MOBILE
   ========================================= */
@media (max-width: 768px) {

    /* Success/Error Messages */
    .msg-success,
    .msg-error {
        padding: 12px;
        margin: 10px 0;
        border-radius: 6px;
        font-size: 0.9rem;
    }

    /* Loading Spinner */
    .loading-spinner {
        width: 20px;
        height: 20px;
        border-width: 3px;
    }
}

/* =========================================
   13. COOKIE CONSENT MOBILE
   ========================================= */
@media (max-width: 768px) {
    .cookie-consent {
        padding: 15px;
        font-size: 0.85rem;
    }

    .cookie-consent-buttons {
        flex-direction: column;
        gap: 8px;
    }

    .cookie-consent-buttons button {
        width: 100%;
        padding: 10px;
    }
}

/* --- SEARCH BAR HERO --- */
.search-container-hero {
    position: relative;
    max-width: 550px;
    margin-bottom: 40px;
    z-index: 100;
    /* Important pour passer au dessus */
}

.search-container-hero .input-wrapper {
    display: flex;
    background: white;
    border-radius: 50px;
    padding: 5px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

#globalSearch {
    flex-grow: 1;
    border: none;
    padding: 15px 25px;
    font-size: 1.1rem;
    border-radius: 50px;
    outline: none;
    color: var(--secondary);
}

.search-btn {
    background: var(--primary);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    transition: 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-btn:hover {
    background: var(--primary-dark);
    transform: scale(1.05);
}

/* RÉSULTATS FLOTTANTS */
.results-dropdown {
    position: absolute;
    top: 65px;
    left: 15px;
    right: 15px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    max-height: 350px;
    overflow-y: auto;
    display: none;
    /* Caché par défaut */
    overflow-x: hidden;
}

.result-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 20px;
    border-bottom: 1px solid #f1f5f9;
    color: var(--text-main);
    text-decoration: none;
    transition: 0.1s;
}

.result-item:last-child {
    border-bottom: none;
}

.result-item:hover {
    background: #f0f9ff;
    padding-left: 25px;
}

.res-left {
    display: flex;
    align-items: center;
    gap: 15px;
}

.res-code {
    background: var(--bg-body);
    color: var(--secondary);
    font-weight: 800;
    padding: 5px 10px;
    border-radius: 6px;
    min-width: 35px;
    text-align: center;
}

.res-desc {
    font-size: 0.9rem;
    color: #64748b;
}

.res-model {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--primary);
    background: rgba(0, 151, 224, 0.1);
    padding: 4px 8px;
    border-radius: 4px;
}

/* Mobile Adapt */
@media (max-width: 600px) {
    .res-desc {
        display: none;
    }

    /* On cache la description sur mobile pour gagner de la place */
}

/* Badge de date */
.update-badge {
    float: right;
    font-size: 0.75rem;
    color: #166534;
    background: #dcfce7;
    padding: 4px 10px;
    border-radius: 20px;
    font-weight: 600;
    margin-left: 10px;
}

/* Encart Expert Design Pro */
.expert-tip-box {
    display: flex;
    gap: 15px;
    background: #f0f9ff;
    /* Bleu très pâle */
    border: 1px solid #bae6fd;
    padding: 20px;
    border-radius: 8px;
    margin: 25px 0;
}

.tip-icon {
    font-size: 1.8rem;
    line-height: 1;
}

.tip-content h4 {
    margin: 0 0 5px 0;
    color: #0369a1;
    /* Bleu foncé */
    font-size: 1rem;
}

.tip-content p {
    margin: 0;
    color: #334155;
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Alerte Gaz (Améliorée) */
.alert-gaz {
    display: flex;
    gap: 15px;
    background: #fffbeb;
    border-left: 4px solid #f59e0b;
    padding: 15px;
    margin: 20px 0;
    border-radius: 4px;
}

.alert-gaz p {
    margin-bottom: 0;
    font-size: 0.9rem;
    color: #92400e;
}

.gaz-icon {
    font-size: 1.5rem;
}

/* Responsive Mobile */
@media (max-width: 600px) {
    .update-badge {
        float: none;
        display: inline-block;
        margin-bottom: 10px;
    }

    .expert-tip-box {
        flex-direction: column;
        gap: 10px;
    }

    .tip-icon {
        font-size: 1.5rem;
    }
}