/* Gasmotor - Mise en page */

:root {
    --gm-side-w: 250px;
    --gm-side-mini: 84px;
    --gm-navy: #0e1a2b;
    --gm-navy-2: #16263d;
    --gm-accent: #f28c1e;
    --gm-accent-dark: #d67410;
    --gm-bg: #f3f5f8;
    --gm-card: #ffffff;
    --gm-text: #1b2533;
    --gm-muted: #5d6b7e;
    --gm-line: #e1e6ee;
    --gm-radius: 14px;
    --gm-shadow: 0 2px 10px rgba(14, 26, 43, .07);
    --gm-shadow-hover: 0 10px 28px rgba(14, 26, 43, .14);
    --gm-top: var(--wp-admin--admin-bar--height, 0px);
}

body.gm-layout {
    background: var(--gm-bg);
    color: var(--gm-text);
}

.gm-layout .gm-wrap {
    width: 100%;
    max-width: 1320px;
    margin: 0 auto;
    padding: 0 28px;
    box-sizing: border-box;
}

.gm-layout .gm-ico { width: 20px; height: 20px; flex: none; }

/* ---------- Boutons ---------- */
.gm-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 20px;
    border-radius: 999px;
    font-weight: 600;
    font-size: 15px;
    line-height: 1.2;
    text-decoration: none !important;
    transition: background .2s, color .2s, transform .2s;
    border: 2px solid transparent;
    cursor: pointer;
}
.gm-btn .gm-ico { width: 18px; height: 18px; }
.gm-btn-accent { background: var(--gm-accent); color: #fff !important; }
.gm-btn-accent:hover { background: var(--gm-accent-dark); }
.gm-btn-ghost { border-color: rgba(255, 255, 255, .5); color: #fff !important; }
.gm-btn-ghost:hover { background: rgba(255, 255, 255, .1); }
.gm-btn-dark { background: var(--gm-navy); color: #fff !important; }

/* ---------- Barre laterale ---------- */
.gm-sidebar {
    position: fixed;
    top: var(--gm-top);
    left: 0;
    bottom: 0;
    width: var(--gm-side-w);
    background: var(--gm-navy);
    color: #fff;
    display: flex;
    flex-direction: column;
    padding: 22px 14px;
    box-sizing: border-box;
    z-index: 9990;
    overflow-y: auto;
}

.gm-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #fff !important;
    text-decoration: none !important;
}
.gm-brand-mark {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: var(--gm-accent);
}
.gm-brand-mark .gm-ico { width: 26px; height: 26px; }
.gm-brand-text { font-size: 22px; font-weight: 800; letter-spacing: .06em; }
.gm-sidebar .gm-brand { padding: 0 8px 26px; }

.gm-side-nav { display: flex; flex-direction: column; gap: 6px; }

.gm-side-link {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 9px 10px;
    border-radius: 12px;
    color: #d6deea !important;
    text-decoration: none !important;
    font-size: 17px;
    transition: background .2s, color .2s;
}
.gm-side-icon {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--gm-navy-2);
    color: var(--gm-accent);
    transition: background .2s, color .2s;
    flex: none;
}
.gm-side-icon .gm-ico { width: 22px; height: 22px; }
.gm-side-link:hover, .gm-side-link.is-current { background: var(--gm-navy-2); color: #fff !important; }
.gm-side-link:hover .gm-side-icon, .gm-side-link.is-current .gm-side-icon { background: var(--gm-accent); color: #fff; }

.gm-side-foot {
    margin-top: auto;
    padding: 18px 10px 0;
    border-top: 1px solid rgba(255, 255, 255, .08);
    font-size: 13px;
}
.gm-side-foot a { color: #9fb0c6 !important; text-decoration: none; word-break: break-all; }

/* ---------- Bandeau du haut ---------- */
.gm-topbar { background: #fff; border-bottom: 1px solid var(--gm-line); position: relative; z-index: 50; }

.gm-infobar { background: var(--gm-navy-2); color: #c9d4e3; font-size: 13px; }
.gm-infobar-inner { display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 36px; }
.gm-info-contact { display: flex; flex-wrap: wrap; gap: 18px; }
.gm-info-item { display: inline-flex; align-items: center; gap: 6px; color: inherit !important; text-decoration: none; }
.gm-info-item .gm-ico { width: 15px; height: 15px; color: var(--gm-accent); }

.gm-mainbar { display: flex; align-items: center; gap: 20px; min-height: 74px; }

.gm-top-nav { display: flex; flex-wrap: wrap; gap: 4px 20px; flex: 1; }
.gm-top-nav a {
    color: var(--gm-text) !important;
    text-decoration: none !important;
    font-weight: 600;
    font-size: 15px;
    padding: 6px 0;
    border-bottom: 2px solid transparent;
}
.gm-top-nav a:hover { border-color: var(--gm-accent); }

.gm-search {
    display: flex;
    align-items: center;
    background: var(--gm-bg);
    border: 1px solid var(--gm-line);
    border-radius: 999px;
    padding: 0 6px 0 16px;
    min-width: 240px;
}
.gm-search input[type="search"] {
    border: 0 !important;
    background: transparent !important;
    outline: 0;
    box-shadow: none !important;
    flex: 1;
    min-width: 0;
    padding: 10px 0;
    font-size: 14px;
    color: var(--gm-text);
}
.gm-search button {
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border: 0;
    border-radius: 50%;
    background: var(--gm-navy);
    color: #fff;
    cursor: pointer;
}
.gm-search button .gm-ico { width: 18px; height: 18px; }

.gm-burger, .gm-brand-mobile { display: none; }
.gm-burger {
    border: 0;
    background: var(--gm-navy);
    color: #fff;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    place-items: center;
    cursor: pointer;
}
.gm-brand-mobile .gm-brand-text { color: var(--gm-navy); font-size: 20px; }

.gm-overlay { position: fixed; inset: 0; background: rgba(8, 15, 26, .5); z-index: 9980; }

/* ---------- Decalage du contenu ---------- */
/* Ordinateur : barre repliee en icones, deployee au survol ou au clavier, par-dessus le contenu. */
@media (min-width: 1025px) {
    body.gm-layout { padding-left: var(--gm-side-mini); }
    .gm-overlay { display: none !important; }
    .gm-sidebar {
        width: var(--gm-side-mini);
        padding-left: 10px;
        padding-right: 10px;
        overflow-x: hidden;
        transition: width .25s ease, box-shadow .25s ease;
    }
    .gm-sidebar:hover, .gm-sidebar:focus-within {
        width: var(--gm-side-w);
        box-shadow: 8px 0 30px rgba(8, 15, 26, .25);
    }
    .gm-sidebar .gm-brand { padding-left: 11px; padding-right: 0; }
    .gm-side-label, .gm-sidebar .gm-brand-text, .gm-side-foot {
        white-space: nowrap;
        opacity: 0;
        transition: opacity .15s ease;
    }
    .gm-sidebar:hover .gm-side-label, .gm-sidebar:hover .gm-brand-text, .gm-sidebar:hover .gm-side-foot,
    .gm-sidebar:focus-within .gm-side-label, .gm-sidebar:focus-within .gm-brand-text, .gm-sidebar:focus-within .gm-side-foot {
        opacity: 1;
        transition-delay: .1s;
    }
}

@media (max-width: 1280px) {
    .gm-top-nav { display: none; }
    .gm-mainbar { justify-content: flex-end; }
    .gm-search { flex: 1; max-width: 520px; margin-right: auto; }
}

@media (max-width: 1024px) {
    .gm-sidebar { transform: translateX(-100%); transition: transform .25s ease; box-shadow: none; }
    body.gm-nav-open .gm-sidebar { transform: none; box-shadow: 0 0 40px rgba(0, 0, 0, .35); }
    body.gm-nav-open { overflow: hidden; }
    .gm-burger { display: grid; }
    .gm-brand-mobile { display: flex; }
    .gm-info-tagline { display: none; }
    .gm-mainbar { gap: 12px; flex-wrap: wrap; padding-top: 12px; padding-bottom: 12px; }
    .gm-search { order: 5; flex-basis: 100%; max-width: none; }
    .gm-quote-btn { margin-left: auto; padding: 9px 14px; font-size: 14px; }
}

@media (max-width: 600px) {
    .gm-layout .gm-wrap { padding: 0 16px; }
    .gm-info-contact { gap: 12px; }
    .gm-infobar-inner { justify-content: center; }
}

/* ---------- Contenu Bricks ---------- */
.gm-is-home #brx-content > h1 { display: none; }
.gm-is-home #brx-content { max-width: none; width: 100%; padding: 0; }
.gm-layout #brx-content { min-height: 50vh; }
.gm-layout #brx-content > .brxe-container,
.gm-layout #brx-content > article,
.gm-layout .gm-home { box-sizing: border-box; }

/* ---------- Cartes FluentCart ---------- */
.gm-layout .fct-product-card {
    background: var(--gm-card);
    border: 1px solid var(--gm-line) !important;
    border-radius: var(--gm-radius) !important;
    overflow: hidden;
    box-shadow: var(--gm-shadow);
    transition: transform .2s, box-shadow .2s;
    display: flex;
    flex-direction: column;
}
.gm-layout .fct-product-card:hover { transform: translateY(-3px); box-shadow: var(--gm-shadow-hover); }
.gm-layout .fct-product-card-image-wrap { background: #fff; }
.gm-layout .fct-product-card-image { object-fit: contain !important; }
.gm-layout .fct-product-card-title { font-weight: 700; color: var(--gm-text); }
.gm-layout .fct-product-card-prices { color: var(--gm-navy); font-weight: 700; }
.gm-layout .fct-product-card button,
.gm-layout .fct-product-card .fct-button,
.gm-layout .fct-product-card a[class*="button"] {
    border-radius: 999px !important;
    background: var(--gm-navy) !important;
    color: #fff !important;
    border: 0 !important;
}
.gm-layout .fct-product-card button:hover,
.gm-layout .fct-product-card .fct-button:hover { background: var(--gm-accent) !important; }

/* ---------- Accueil [gm_home] ---------- */
.gm-home { max-width: 1320px; margin: 0 auto; padding: 28px; }
.gm-home h1, .gm-home h2 { margin: 0; line-height: 1.15; }

.gm-hero {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 36px;
    align-items: center;
    padding: 56px;
    border-radius: 22px;
    color: #fff;
    background:
        radial-gradient(circle at 85% 20%, rgba(242, 140, 30, .35), transparent 45%),
        linear-gradient(135deg, var(--gm-navy) 0%, #1d3553 100%);
}
.gm-eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: 13px; color: var(--gm-accent); font-weight: 700; margin: 0 0 12px; }
.gm-hero h1 { font-size: clamp(30px, 3.4vw, 46px); color: #fff; }
.gm-hero p { color: #c9d4e3; font-size: 17px; }
.gm-hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.gm-hero-search {
    background: rgba(255, 255, 255, .08);
    border: 1px solid rgba(255, 255, 255, .15);
    border-radius: 18px;
    padding: 26px;
}
.gm-hero-search label { display: block; font-weight: 700; margin-bottom: 12px; }
.gm-search-lg { background: #fff; min-width: 0; }
.gm-search-lg input[type="search"] { padding: 14px 0; font-size: 16px; }
.gm-search-lg button { width: 44px; height: 44px; background: var(--gm-accent); }

.gm-section { margin-top: 56px; }
.gm-section-head { display: flex; justify-content: space-between; align-items: end; gap: 16px; margin-bottom: 22px; }
.gm-section h2 { font-size: clamp(24px, 2.4vw, 32px); color: var(--gm-navy); }
.gm-section-head a { display: inline-flex; align-items: center; gap: 6px; color: var(--gm-accent-dark) !important; font-weight: 600; text-decoration: none; }
.gm-section-head a .gm-ico { width: 18px; height: 18px; }

.gm-cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.gm-cat {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 20px 22px;
    background: var(--gm-card);
    border: 1px solid var(--gm-line);
    border-left: 4px solid var(--gm-accent);
    border-radius: var(--gm-radius);
    text-decoration: none !important;
    box-shadow: var(--gm-shadow);
    transition: transform .2s, box-shadow .2s;
}
.gm-cat:hover { transform: translateY(-3px); box-shadow: var(--gm-shadow-hover); }
.gm-cat-name { color: var(--gm-navy); font-weight: 700; font-size: 16px; }
.gm-cat-count { color: var(--gm-muted); font-size: 14px; }

.gm-prod-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
@media (max-width: 1100px) { .gm-prod-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 760px) { .gm-prod-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; } }
.gm-prod {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 0 0 20px;
    background: var(--gm-card);
    border: 1px solid var(--gm-line);
    border-radius: var(--gm-radius);
    overflow: hidden;
    text-decoration: none !important;
    text-align: center;
    box-shadow: var(--gm-shadow);
    transition: transform .2s, box-shadow .2s;
}
.gm-prod:hover { transform: translateY(-3px); box-shadow: var(--gm-shadow-hover); }
.gm-prod-img { display: grid; place-items: center; aspect-ratio: 1; background: #fff; padding: 18px; border-bottom: 1px solid var(--gm-line); }
.gm-prod-img img { width: 100%; height: 100%; object-fit: contain; }
.gm-prod-title { color: var(--gm-text); font-weight: 700; padding: 0 16px; line-height: 1.35; }
.gm-prod-price { color: var(--gm-navy); font-weight: 800; font-size: 18px; margin-top: auto; }
.gm-prod-price small { font-size: 12px; color: var(--gm-muted); font-weight: 600; }
.gm-prod .gm-btn { align-self: center; padding: 9px 18px; font-size: 14px; }
.gm-prod:hover .gm-btn { background: var(--gm-accent); }

.gm-brands ul { display: flex; flex-wrap: wrap; gap: 12px; list-style: none; padding: 0; margin: 18px 0 0; }
.gm-brands li {
    padding: 12px 22px;
    border-radius: 999px;
    background: var(--gm-card);
    border: 1px solid var(--gm-line);
    font-weight: 700;
    color: var(--gm-navy);
}

.gm-cta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
    flex-wrap: wrap;
    padding: 36px 44px;
    border-radius: 22px;
    background: var(--gm-card);
    border: 1px solid var(--gm-line);
    border-left: 6px solid var(--gm-accent);
}
.gm-cta p { margin: 8px 0 0; color: var(--gm-muted); }

@media (max-width: 900px) {
    .gm-hero { grid-template-columns: 1fr; padding: 32px 24px; }
    .gm-home { padding: 16px; }
    .gm-cta { padding: 26px; }
}

/* ---------- Pied de page ---------- */
.gm-footer { background: var(--gm-navy); color: #c9d4e3; margin-top: 64px; font-size: 15px; }
.gm-footer .gm-footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.1fr; gap: 40px; padding-top: 56px; padding-bottom: 44px; }
.gm-footer h3 { color: #fff; font-size: 16px; margin: 0 0 16px; }
.gm-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 9px; }
.gm-footer a { color: #c9d4e3 !important; text-decoration: none; }
.gm-footer a:hover { color: var(--gm-accent) !important; }
.gm-brand-footer { margin-bottom: 14px; }
.gm-footer-desc { margin: 0 0 20px; max-width: 320px; }
.gm-footer-contact li { display: flex; align-items: center; gap: 8px; }
.gm-footer-contact .gm-ico { width: 17px; height: 17px; color: var(--gm-accent); }
.gm-footer-bottom { border-top: 1px solid rgba(255, 255, 255, .08); padding: 18px 0; font-size: 13px; color: #8597ad; }

@media (max-width: 900px) {
    .gm-footer .gm-footer-grid { grid-template-columns: 1fr 1fr; gap: 30px; }
}
@media (max-width: 560px) {
    .gm-footer .gm-footer-grid { grid-template-columns: 1fr; }
}

/* ---------- Filtre categories FluentCart repliable ---------- */
.gm-collapsible { position: relative; }
.gm-collapsible > .fct-shop-checkbox { padding-right: 30px; }
.gm-collapsible > .fct-shop-checkbox-child-options { display: none; }
.gm-collapsible.is-open > .fct-shop-checkbox-child-options { display: block; }
.gm-cat-toggle {
    position: absolute;
    top: 0;
    right: 0;
    width: 26px;
    height: 26px;
    padding: 0;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: var(--gm-muted);
    cursor: pointer;
    display: grid;
    place-items: center;
}
.gm-cat-toggle:hover { background: var(--gm-bg); color: var(--gm-navy); }
.gm-cat-toggle::before {
    content: "";
    width: 7px;
    height: 7px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(-45deg);
    transition: transform .15s;
}
.gm-collapsible.is-open > .gm-cat-toggle::before { transform: rotate(45deg); }
