/* ==========================================================================
   CUSTOM.CSS — Styles globaux du site (chargés sur toutes les pages)
   ========================================================================== */

/* Fallback font matching pour éviter le FOUT */
@font-face {
    font-family: 'Open Sans Fallback';
    src: local('Arial');
    size-adjust: 100%;
    ascent-override: 101%;
    descent-override: 28%;
    line-gap-override: 0%;
}

@font-face {
    font-family: 'Montserrat Fallback';
    src: local('Arial');
    size-adjust: 100%;
    ascent-override: 95%;
    descent-override: 24%;
    line-gap-override: 0%;
}

body, html {
    font-family: "Open Sans", "Open Sans Fallback", Arial, sans-serif;
}


/* ==========================================================================
   1. TYPOGRAPHIE & TEXTE
   ========================================================================== */

.ast-single-post.ast-page-builder-template .site-main > article, .ast-page-builder-template .post-navigation{
    pagging : 0 !important;
}

/* Date du jour dans le H1 des pages marques */
.date-du-jour {
    font-size: 14px !important;
    color: #7A7A7A !important;
    font-weight: 400 !important;
    display: block;
}

h2.sous-titre-seo-marque {
    font-size: 22px;
}


/* ==========================================================================
   2. BREADCRUMB RANK MATH (sur pages marques)
   ========================================================================== */

.rank-math-breadcrumb {
    font-family: 'Open Sans', sans-serif;
    font-size: 13px;
    color: #4b5563;
}

.rank-math-breadcrumb a {
    color: #1c74f4;
    text-decoration: none;
    font-weight: 500;
}

.rank-math-breadcrumb a:hover {
    text-decoration: underline;
}

.rank-math-breadcrumb .separator {
    margin: 0 8px;
    color: #9ca3af;
}


/* ==========================================================================
   3. BOUTON "DÉCOUVRIR LES OFFRES" (pages marques)
   ========================================================================== */

.btn-decouvrir-offres {
    display: block;
    width: 100%;
    max-width: 240px;
    margin: 0 auto;
    padding: 0;
    background-color: transparent !important;
    color: #16A34A !important;
    border: 2px solid #16A34A !important;
    text-align: center;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none !important;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    transition: all 0.25s ease-in-out;
}

.btn-decouvrir-offres:hover {
    background-color: #16A34A !important;
    color: #ffffff !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(22, 163, 74, 0.2);
}

.btn-decouvrir-offres:active {
    transform: translateY(0);
}


/* ==========================================================================
   4. BADGE "NOUVEAU !" (menu Guides + ailleurs)
   ========================================================================== */

.badge-nouveau-guide {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background-color: #16A34A;
    color: #ffffff;
    font-family: 'Open Sans', sans-serif;
    font-size: 9px;
    font-weight: 700;
    padding: 3px 13px;
    border-radius: 50px;
    margin-left: 3px;
    line-height: 1;
    white-space: nowrap;
    vertical-align: middle;
}


/* ==========================================================================
   5. GRILLE MARQUES SIDEBAR (utilisée dans single.php + page.php guides)
   ========================================================================== */

.mcp-guides-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    align-items: center;
    justify-items: center;
    background: #fff;
    padding: 10px;
    border-radius: 8px;
}

.mcp-guides-grid__item {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    padding: 5px;
    transition: transform 0.2s ease;
    text-decoration: none;
}

.mcp-guides-grid__item:hover {
    transform: scale(1.1);
}

.mcp-guides-grid__item img {
    max-width: 100%;
    height: auto;
    max-height: 50px;
    object-fit: contain;
    mix-blend-mode: multiply;
}


/* ==========================================================================
   6. TABLES RESPONSIVES (Guides & Articles)
   ========================================================================== */

@media (max-width: 768px) {

    .entry-content table,
    .mcp-guide__content table,
    .mcp-article__content table {
        display: block;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        font-size: 13px;
        width: 100%;
    }

    .entry-content table th,
    .entry-content table td,
    .mcp-guide__content table th,
    .mcp-guide__content table td,
    .mcp-article__content table th,
    .mcp-article__content table td {
        white-space: nowrap;
        padding: 10px 12px;
    }

    .entry-content table td:first-child,
    .entry-content table th:first-child,
    .mcp-guide__content table td:first-child,
    .mcp-guide__content table th:first-child,
    .mcp-article__content table td:first-child,
    .mcp-article__content table th:first-child {
        min-width: 100px;
        font-weight: bold;
    }
}


/* ==========================================================================
   7. FIX — Empêcher CookieYes de créer un scroll horizontal sur mobile
   ========================================================================== */

html,
body {
    overflow-x: hidden !important;
    max-width: 100vw !important;
}

.cky-preference-center,
.cky-preference-header,
.cky-preference-body-wrapper,
.cky-preference-content-wrapper,
.cky-footer-wrapper {
    max-width: 100vw !important;
}

#primary{
    margin: 0 !important;
}