/**
 * MCPRO — Interface MOBILE / tablette (≤900px, aligné sur <link media="(max-width: 900px)">)
 * Fichier séparé de desktop.css — ne pas mélanger les breakpoints.
 */
@media (max-width: 900px) {
  /* Panneau langue : règles centralisées dans i18n.css */

  body.cat-drawer-open .nav-mobile-drawer,
  body.cat-drawer-open .nav-mobile-backdrop {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }

  /* Tiroir catégories FERMÉ : ne jamais couvrir l'accueil */
  body:not(.cat-drawer-open) .cat-drawer {
    display: none !important;
    transform: translateX(-100%) !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }

  body:not(.cat-drawer-open) .cat-drawer-backdrop {
    display: none !important;
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }

  body.cat-drawer-open .cat-drawer {
    display: flex !important;
    visibility: visible !important;
    pointer-events: auto !important;
  }

  body.cat-drawer-open .cat-drawer-backdrop,
  body.cat-drawer-open #cat-drawer-backdrop {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
  }
  :root {
    --mcp-bottom: calc(3.6rem + env(safe-area-inset-bottom));
    --mcp-touch: 44px;
    --mcp-accent: #e85d04;
    --mcp-primary: #4a2c2a;
    --mcp-surface: #fff;
    --mcp-bg: #f5f1e8;
    --mcp-border: #e8dfd4;
    --mcp-muted: #6b534f;
    --mcp-radius: 12px;
    --page-gutter: clamp(0.75rem, 3vw, 1.25rem);
  }

  html {
    overflow-x: hidden;
    overscroll-behavior-y: none;
    height: auto;
  }

  body {
    overflow-x: hidden;
    max-width: 100vw;
    min-height: 100%;
    position: relative;
  }

  /* Site public : le contenu défile ; header + barre du bas restent fixes */
  body.mcpro-public-site {
    padding-bottom: var(--mcp-bottom);
    overflow-y: visible;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    -webkit-tap-highlight-color: transparent;
    opacity: 1 !important;
    visibility: visible !important;
  }

  /* Verrouillage scroll uniquement quand un tiroir est ouvert */
  body.mcpro-public-site.cat-drawer-open,
  body.mcpro-public-site.nav-mobile-open {
    overflow: hidden !important;
    touch-action: none;
  }

  /* Contenu page : toujours affiché sauf tiroir ouvert */
  body.mcpro-public-site:not(.cat-drawer-open):not(.nav-mobile-open) .hero-pro,
  body.mcpro-public-site:not(.cat-drawer-open):not(.nav-mobile-open) .section,
  body.mcpro-public-site:not(.cat-drawer-open):not(.nav-mobile-open) main {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
  }

  /* ─── Masquer barre desktop uniquement ─── */
  .site-header--public .navbar-center.header-desktop-only,
  .site-header--public .cat-hamburger-btn,
  .site-header--public .navbar-actions-shop .notif-center-wrap,
  .site-header--public .navbar-actions-shop .navbar-action-fav,
  .site-header--public .navbar-actions-shop a[href*="comparateur"],
  .site-header--public .navbar-actions-shop .nav-icon-label,
  .mcpro-ai-chat,
  .footer-categories {
    display: none !important;
  }

  /* Header mobile allégé par défaut (logo + ☰ + thème — panier/compte/cat dans la barre du bas) */
  .site-header--public .header-mobile-only-cat,
  .site-header--public .header-mobile-suppressed,
  .site-header--public .nav-mobile-cat-btn,
  .site-header--public .navbar-actions-shop,
  .site-header--public .navbar-actions-account {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }

  .site-header--public .navbar-actions-tools {
    gap: 0.35rem !important;
    overflow: visible !important;
  }

  .site-header--public .lang-switcher:not(.lang-switcher--mobile-off) {
    display: inline-flex !important;
    visibility: visible !important;
    pointer-events: auto !important;
    flex-shrink: 0;
  }

  .lang-switcher--mobile-off,
  .auth-lang-switcher,
  #lang-switcher.auth-lang-switcher {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }

  .site-header--public .navbar-theme-toggle {
    display: inline-flex !important;
    visibility: visible !important;
    pointer-events: auto !important;
    position: relative;
    z-index: 1400;
  }

  .site-header--public .nav-mobile-toggle {
    min-width: 2.85rem;
    min-height: 2.85rem;
    padding: 0.45rem;
    border-radius: 12px;
    background: var(--mcp-accent, #e85d04);
    color: #fff;
    border: none;
    box-shadow: 0 2px 10px rgba(232, 93, 4, 0.35);
  }

  .site-header--public .nav-mobile-toggle .nav-mobile-toggle-bars span {
    background: #fff;
  }

  .nav-mobile-drawer-tools {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-start;
    gap: 0.65rem;
    width: 100%;
    margin-bottom: 0.85rem;
    padding-bottom: 0.85rem;
    border-bottom: 1px solid var(--cp-border, #e2e8f0);
  }

  .nav-mobile-drawer-tools .lang-switcher-btn,
  .nav-mobile-drawer-tools .navbar-theme-toggle {
    min-width: 3rem;
    min-height: 3rem;
  }

  .nav-mobile-drawer-foot .btn[data-nav-mobile-categories] {
    width: 100%;
    min-height: 48px;
    font-size: 0.95rem;
  }

  /* ─── Header mobile : logo + menu ☰ (reste dans le tiroir / barre du bas) ─── */
  .site-header--public {
    position: sticky;
    top: 0;
    z-index: 900;
    overflow: visible;
    background: var(--mcp-surface);
    border-bottom: 1px solid var(--mcp-border);
    box-shadow: 0 2px 14px rgba(15, 39, 68, 0.08);
  }

  .site-header--public .main-navbar,
  .site-header--public .main-navbar-inner,
  .site-header--public .navbar-actions,
  .site-header--public .navbar-actions-tools {
    overflow: visible;
  }

  .site-header--public .main-navbar-inner {
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    gap: 0.35rem !important;
    padding: 0.45rem 0 !important;
    grid-template-columns: unset !important;
    grid-template-areas: unset !important;
  }

  .site-header--public .navbar-logo {
    flex: 0 0 auto;
    order: 1;
    min-width: 5.5rem;
    max-width: min(38vw, 7.5rem);
    overflow: visible;
    align-items: center;
  }

  .site-header--public .navbar-logo-img,
  .site-header--public .navbar-logo img {
    display: block;
    height: 2.75rem !important;
    width: auto !important;
    max-width: min(42vw, 9rem) !important;
    object-fit: contain;
    object-position: left center;
  }

  .site-header--public .navbar-logo-fallback {
    display: none;
    font-family: var(--cp-font-heading, Montserrat, sans-serif);
    font-size: 0.85rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    color: var(--cp-primary, #4A2C2A);
    line-height: 1;
    white-space: nowrap;
  }

  .site-header--public .navbar-logo-fallback.is-visible {
    display: block;
  }

  html[data-theme="dark"] .site-header--public .navbar-logo-fallback,
  body.mcpro-public-site.theme-dark .site-header--public .navbar-logo-fallback {
    color: #f8fafc;
  }

  .site-header--public .navbar-actions {
    order: 2;
    flex: 1 1 auto;
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 0.2rem !important;
    margin-left: 0 !important;
    min-width: 0;
  }

  .site-header--public .navbar-actions-tools,
  .site-header--public .mcpro-hdr-toolbar {
    display: flex !important;
    align-items: center !important;
    gap: 0.35rem !important;
    flex-shrink: 0;
    overflow: visible;
  }

  /* Boutons header : tailles fixes, pas de chevauchement (Safari) */
  .site-header--public .mcpro-hdr-btn {
    box-sizing: border-box;
    flex: 0 0 auto;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: 2.75rem;
    height: 2.75rem;
    min-width: 2.75rem;
    max-width: 2.75rem;
    min-height: 2.75rem;
    max-height: 2.75rem;
    padding: 0;
    margin: 0;
    position: relative;
    z-index: 1;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    border-radius: 10px;
    border: 1px solid var(--mcp-border, var(--cp-border, #e2e8f0));
    background: var(--mcp-surface, var(--cp-surface, #fff));
    color: var(--mcp-primary, var(--cp-primary, #4a2c2a));
    cursor: pointer;
    overflow: hidden;
  }

  .site-header--public .mcpro-hdr-btn--cat {
    width: auto;
    min-width: 2.75rem;
    max-width: 3.1rem;
    padding: 0.2rem 0.35rem;
    flex-direction: column;
    gap: 0.05rem;
    border: none;
    background: linear-gradient(180deg, #f97316 0%, var(--mcp-accent, #e85d04) 100%);
    color: #fff;
    box-shadow: 0 2px 8px rgba(232, 93, 4, 0.35);
  }

  .site-header--public .mcpro-hdr-lang {
    display: inline-flex !important;
    flex: 0 0 auto;
    position: relative;
    z-index: 1;
    margin: 0;
  }

  .site-header--public .mcpro-hdr-btn--lang {
    flex-direction: column;
    gap: 0.05rem;
    padding: 0.2rem;
    font-size: 0.62rem;
    font-weight: 800;
  }

  .site-header--public .mcpro-hdr-btn--lang .lang-flag {
    font-size: 1rem;
    line-height: 1;
  }

  .site-header--public .mcpro-hdr-btn--menu .nav-mobile-toggle-bars {
    width: 18px;
    gap: 4px;
  }

  .site-header--public .navbar-actions-tools {
    flex-wrap: nowrap;
    gap: 0.25rem !important;
  }

  /* Sélecteur de langue — identique au bouton lune (valeurs littérales, pas de variables CSS) */
  .site-header--public .navbar-actions-tools .lang-switcher-btn,
  .site-header--public .navbar-actions-tools .lang-switcher {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-sizing: border-box !important;
    width: 2.75rem !important;
    height: 2.75rem !important;
    min-width: 2.75rem !important;
    min-height: 2.75rem !important;
    max-width: 2.75rem !important;
    max-height: 2.75rem !important;
    padding: 0 !important;
    border-radius: 10px !important;
    background: #ffffff !important;
    border: 1px solid #c9b8ae !important;
    box-shadow: 0 1px 4px rgba(74, 44, 42, 0.12) !important;
    flex-shrink: 0 !important;
    gap: 0 !important;
    overflow: visible !important;
  }

  html[data-theme="dark"] .site-header--public .navbar-actions-tools .lang-switcher-btn,
  html[data-theme="dark"] .site-header--public .navbar-actions-tools .lang-switcher,
  body.theme-dark .site-header--public .navbar-actions-tools .lang-switcher-btn,
  body.theme-dark .site-header--public .navbar-actions-tools .lang-switcher {
    background: #334155 !important;
    border-color: #64748b !important;
  }

  .site-header--public .navbar-actions-tools .lang-switcher-btn .lang-flag {
    font-size: 1.3rem;
    line-height: 1;
    display: block;
  }

  .site-header--public .navbar-actions-tools .lang-label {
    display: none;
  }

  /* Page d'accueil : conserver le même style que les autres boutons (cohérence avec le bouton lune) */

  .site-header--public .nav-mobile-toggle {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    position: relative;
    z-index: 1;
    touch-action: manipulation;
    margin-inline-end: 0.15rem;
    cursor: pointer;
  }

  .site-header--public .nav-mobile-toggle .sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
  }

  /* Thème clair/sombre (icône soleil) */
  .site-header--public .navbar-theme-toggle {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    min-width: 2.4rem;
    min-height: 2.4rem;
    padding: 0.35rem;
    border: 1px solid #c9b8ae;
    border-radius: 10px;
    background: #ffffff;
    color: #4a2c2a;
    flex-shrink: 0;
    box-shadow: 0 1px 4px rgba(74, 44, 42, 0.12);
  }

  html[data-theme="dark"] .site-header--public .navbar-theme-toggle,
  body.mcpro-public-site.theme-dark .site-header--public .navbar-theme-toggle {
    background: #334155;
    border-color: #64748b;
    color: #f8fafc;
  }

  .site-header--public .navbar-theme-toggle .nav-icon {
    color: currentColor;
  }

  .site-header--public .navbar-theme-toggle .nav-icon-label {
    display: none;
  }

  body.lang-menu-open {
    overflow: hidden;
  }

  body.lang-menu-open .mobile-bottom-nav {
    pointer-events: none;
  }

  .site-header--public .navbar-cart {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    min-width: 2.5rem;
    min-height: 2.5rem;
    padding: 0.35rem;
    flex-shrink: 0;
    border-radius: 10px;
    background: rgba(232, 93, 4, 0.08);
  }

  .site-header--public .btn-navbar-account {
    display: inline-flex !important;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0;
    font-size: 0 !important;
    font-weight: 800;
    padding: 0.35rem !important;
    min-height: 2.5rem;
    min-width: 2.5rem;
    max-width: 2.5rem;
    line-height: 1;
    border-radius: 10px;
    background: var(--mcp-accent) !important;
    color: #fff !important;
    border: none !important;
    box-shadow: 0 2px 8px rgba(232, 93, 4, 0.3);
  }

  .site-header--public .btn-account-icon {
    font-size: 1.05rem;
    line-height: 1;
  }

  .site-header--public .btn-account-label {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
  }

  /* Recherche */
  .site-header--public .navbar-search-row {
    padding: 0 0 0.5rem;
    background: var(--mcp-surface);
  }

  .site-header--public .navbar-search-row .container {
    width: 100%;
    max-width: 100%;
    padding-inline: var(--page-gutter);
  }

  .site-header--public .search-bar {
    width: 100%;
    display: flex;
    gap: 0.35rem;
  }

  .site-header--public .search-bar input {
    flex: 1;
    min-width: 0;
    font-size: 16px;
    min-height: var(--mcp-touch);
    border-radius: 10px;
    border: 1px solid var(--mcp-border);
    padding: 0 0.75rem;
  }

  .site-header--public .search-bar button {
    min-height: var(--mcp-touch);
    padding: 0 0.85rem;
    border-radius: 10px;
    background: var(--mcp-accent);
    color: #fff;
    font-weight: 700;
    font-size: 0.8rem;
    border: none;
    flex-shrink: 0;
  }

  /* Menu ouvert : barre du bas sous le tiroir (clics X + backdrop OK) */
  body.nav-mobile-open .mobile-bottom-nav {
    z-index: 1100 !important;
    pointer-events: none !important;
  }

  body.nav-mobile-open .nav-mobile-backdrop.is-open {
    z-index: 1250 !important;
  }

  body.nav-mobile-open .nav-mobile-drawer.is-open {
    z-index: 1260 !important;
  }

  .nav-mobile-drawer-close {
    position: relative;
    z-index: 2;
    cursor: pointer;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
  }

  /* ─── Barre du bas : 6 onglets ─── */
  .mobile-bottom-nav {
    display: flex !important;
    position: fixed !important;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1200;
    align-items: stretch;
    background: var(--mcp-primary);
    border-top: none;
    padding: 0.2rem 0.15rem calc(0.25rem + env(safe-area-inset-bottom));
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.2);
  }

  .mobile-bottom-nav .mobile-nav-item {
    flex: 1 1 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.12rem;
    padding: 0.35rem 0.1rem;
    font-size: 0.5rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.75);
    text-decoration: none;
    border: none;
    background: transparent;
    font-family: inherit;
    cursor: pointer;
    border-radius: 8px;
  }

  .mobile-bottom-nav .mobile-nav-item.is-active {
    color: #fff;
    background: rgba(232, 93, 4, 0.35);
  }

  .mobile-bottom-nav .mobile-nav-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 1.5rem;
    height: 1.5rem;
    font-size: 1rem;
    line-height: 1;
  }

  .mobile-bottom-nav .mobile-nav-item > span:last-child {
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .mobile-bottom-nav .mobile-nav-badge {
    position: absolute;
    top: 0.1rem;
    right: calc(50% - 1.2rem);
    min-width: 1rem;
    height: 1rem;
    padding: 0 0.2rem;
    font-size: 0.55rem;
    font-weight: 800;
    line-height: 1rem;
    text-align: center;
    background: var(--mcp-accent);
    color: #fff;
    border-radius: 999px;
  }

  .mobile-bottom-nav .mobile-nav-badge[hidden] {
    display: none !important;
  }

  .mobile-bottom-nav .mobile-nav-item {
    position: relative;
  }

  /* Tiroir menu */
  .nav-mobile-drawer {
    width: min(92vw, 340px);
  }

  .nav-mobile-menu a {
    display: block;
    padding: 0.85rem 1rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 10px;
    margin-bottom: 0.25rem;
    min-height: 48px;
  }

  .nav-mobile-menu a.active {
    background: rgba(232, 93, 4, 0.12);
    color: var(--mcp-accent);
  }

  .nav-mobile-drawer-foot .btn {
    width: 100%;
  }

  .cat-drawer-body,
  .nav-mobile-drawer-body {
    overscroll-behavior: contain;
  }

  /* Contenu */
  .page-header {
    padding: 1rem 0;
  }

  .page-header h1 {
    font-size: clamp(1.2rem, 5vw, 1.45rem);
  }

  .page-content,
  .hero-pro,
  .section {
    padding-bottom: 1rem;
  }

  .page-content {
    padding-top: 1rem;
  }

  .hero-pro .container,
  .section .container {
    padding-left: var(--page-gutter);
    padding-right: var(--page-gutter);
  }

  .hero-pro.hero-pro-cover {
    min-height: min(72vh, 34rem);
    padding: 2.25rem 0 2.5rem;
    background:
      linear-gradient(160deg, rgba(74, 44, 42, 0.42) 0%, rgba(74, 44, 42, 0.28) 55%, rgba(61, 34, 32, 0.38) 100%),
      url("../images/categories/hero-procurement.webp") center 35% / cover no-repeat;
  }

  .hero-pro.hero-pro-cover::after {
    opacity: 0.65;
  }

  .hero-pro .badge {
    background: rgba(255, 255, 255, 0.18);
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
  }

  .hero-pro h1,
  .hero-pro .lead {
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.35);
  }

  .hero-mobile-dots {
    display: none;
  }

  body[data-page="home"] .site-header--public {
    border-bottom: 1px solid rgba(74, 44, 42, 0.08);
    box-shadow: 0 1px 8px rgba(74, 44, 42, 0.08);
  }

  body[data-page="home"] .site-header--public .main-navbar-inner {
    min-height: 5.45rem;
    padding: 0.75rem 0 !important;
    gap: 0.4rem !important;
  }

  body[data-page="home"] .site-header--public .navbar-logo {
    max-width: min(48vw, 12rem);
  }

  body[data-page="home"] .site-header--public .navbar-logo-img,
  body[data-page="home"] .site-header--public .navbar-logo img {
    height: 3.8rem !important;
    max-width: min(48vw, 12rem) !important;
  }

  body[data-page="home"] .site-header--public .navbar-actions {
    gap: 0.35rem !important;
  }

  body[data-page="home"] .site-header--public .navbar-actions-shop.header-mobile-suppressed {
    display: inline-flex !important;
    visibility: visible !important;
    pointer-events: auto !important;
    order: 1;
    align-items: center;
    gap: 0.45rem;
    margin: 0;
    padding: 0;
  }

  body[data-page="home"] .site-header--public .navbar-actions-tools {
    order: 2;
    gap: 0 !important;
  }

  /* Accueil : on garde le sélecteur de langue + le dark mode (cohérence avec
     les autres pages) ; on masque seulement notifs/favoris/comparateur. */
  body[data-page="home"] .site-header--public .notif-center-wrap,
  body[data-page="home"] .site-header--public .navbar-action-fav,
  body[data-page="home"] .site-header--public .navbar-actions-shop a[href*="comparateur"] {
    display: none !important;
  }

  body[data-page="home"] .site-header--public .lang-switcher,
  body[data-page="home"] .site-header--public .navbar-theme-toggle {
    display: inline-flex !important;
    visibility: visible !important;
  }

  body[data-page="home"] .site-header--public .mobile-header-chat,
  body[data-page="home"] .site-header--public .navbar-cart,
  body[data-page="home"] .site-header--public .nav-mobile-toggle {
    width: 2.75rem;
    height: 2.75rem;
    min-width: 2.75rem;
    min-height: 2.75rem;
    border: 0;
    border-radius: 0;
    background: transparent !important;
    box-shadow: none !important;
    color: var(--mcp-primary, #4a2c2a);
  }

  body[data-page="home"] .site-header--public .mobile-header-chat,
  body[data-page="home"] .site-header--public .navbar-cart {
    display: inline-flex !important;
    visibility: visible !important;
    pointer-events: auto !important;
  }

  body[data-page="home"] .site-header--public .mobile-header-chat .nav-icon-label,
  body[data-page="home"] .site-header--public .navbar-cart .nav-icon-label {
    display: none !important;
  }

  body[data-page="home"] .site-header--public .nav-mobile-toggle .nav-mobile-toggle-bars {
    width: 1.7rem;
    gap: 0.34rem;
  }

  body[data-page="home"] .site-header--public .nav-mobile-toggle .nav-mobile-toggle-bars span {
    height: 0.18rem;
    background: currentColor;
  }

  body[data-page="home"] .site-header--public .cart-badge {
    top: 0.2rem;
    right: 0.08rem;
    min-width: 1.25rem;
    height: 1.25rem;
    line-height: 1.25rem;
    padding: 0 0.28rem;
    font-size: 0.68rem;
    background: var(--mcp-accent, #e85d04);
    color: #fff;
  }

  body[data-page="home"] .hero-pro.hero-pro-cover {
    min-height: calc(100svh - 16rem);
    padding: 5.75rem 0 0;
    display: flex;
    align-items: stretch;
    background:
      linear-gradient(145deg, rgba(74, 44, 42, 0.72) 0%, rgba(155, 76, 39, 0.48) 48%, rgba(245, 241, 232, 0.18) 100%),
      url("../images/categories/hero-procurement.webp") center 35% / cover no-repeat;
  }

  body[data-page="home"] .hero-pro .container {
    display: flex;
    flex-direction: column;
    width: 100%;
  }

  body[data-page="home"] .hero-pro .badge {
    width: fit-content;
    margin-bottom: 1.25rem;
    padding: 0.38rem 0.9rem;
    border: 0;
    background: rgba(232, 93, 4, 0.36);
    color: #f9c21a;
    font-size: 0.82rem;
    font-weight: 800;
  }

  body[data-page="home"] .hero-pro h1 {
    max-width: 22rem;
    margin-bottom: 1.15rem;
    font-size: clamp(2rem, 10vw, 2.65rem);
    line-height: 1.18;
    letter-spacing: 0;
  }

  body[data-page="home"] .hero-pro .lead {
    max-width: 21rem;
    margin-bottom: 1.75rem;
    font-size: 1.08rem;
    line-height: 1.55;
    opacity: 0.94;
  }

  /* Transition de slide du carrousel hero (titre + sous-titre) */
  @keyframes mcproHeroSlideIn {
    from { opacity: 0; transform: translateY(0.6rem); }
    to { opacity: 1; transform: none; }
  }

  body[data-page="home"] .hero-pro h1.hero-slide-in,
  body[data-page="home"] .hero-pro .lead.hero-slide-in {
    animation: mcproHeroSlideIn 0.5s ease both;
  }

  body[data-page="home"] .hero-mobile-arrow {
    cursor: pointer;
    user-select: none;
  }

  body[data-page="home"] .hero-actions {
    display: grid;
    width: min(100%, 20rem);
    gap: 0.85rem;
  }

  body[data-page="home"] .hero-actions .btn {
    justify-content: center;
    min-height: 3.45rem;
    border-radius: 8px;
    font-size: 0.98rem;
    font-weight: 800;
  }

  body[data-page="home"] .hero-actions .btn-outline {
    width: 68%;
    border: 1px solid rgba(255, 255, 255, 0.58);
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
  }

  body[data-page="home"] .hero-mobile-dots {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.65rem;
    margin: auto 0 0;
    padding: 3rem 0 1.85rem;
  }

  body[data-page="home"] .hero-mobile-dots span:not(.hero-mobile-arrow) {
    width: 0.62rem;
    height: 0.62rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.48);
  }

  body[data-page="home"] .hero-mobile-dots span.is-active {
    background: var(--mcp-accent, #e85d04);
  }

  body[data-page="home"] .hero-mobile-arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.85rem;
    height: 2.85rem;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.42);
    color: #fff;
    font-size: 2rem;
    line-height: 1;
  }

  body[data-page="home"] .hero-stats {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem 0.5rem;
    margin: 0 calc(var(--page-gutter) * -1);
    padding: 1.45rem var(--page-gutter) 1.35rem;
    border: 0;
    background: #fff;
    color: var(--mcp-primary, #4a2c2a);
    text-align: center;
  }

  body[data-page="home"] .hero-stats div strong {
    display: block;
    font-size: clamp(1.65rem, 8vw, 2rem);
    line-height: 1;
    color: var(--mcp-accent, #e85d04);
    text-shadow: none;
  }

  body[data-page="home"] .hero-stats div:nth-child(odd) strong {
    color: var(--mcp-primary, #4a2c2a);
  }

  body[data-page="home"] .hero-stats div span {
    display: block;
    margin-top: 0.35rem;
    font-size: 0.84rem;
    line-height: 1.25;
    color: #76635f;
    opacity: 1;
    text-shadow: none;
  }

  body[data-page="home"] .trust-bar {
    padding-top: 1.25rem;
  }

  /* Panier cartes */
  .cart-table-desktop {
    display: none !important;
  }

  .cart-cards {
    display: grid;
    gap: 0.65rem;
  }

  .cart-card {
    background: var(--mcp-surface);
    border: 1px solid var(--mcp-border);
    border-radius: var(--mcp-radius);
    padding: 1rem;
  }

  .cart-page-layout .cart-summary {
    position: sticky;
    bottom: calc(var(--mcp-bottom) + 0.35rem);
    z-index: 100;
  }

  /* Catalogue */
  .catalog-filters {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.65rem;
    padding: 1rem;
    border-radius: var(--mcp-radius);
    border: 1px solid var(--mcp-border);
    margin-bottom: 1rem;
  }

  .catalog-filters-check {
    grid-column: 1 / -1;
  }

  .grid-4,
  .catalog-page-products .grid-4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.65rem;
  }

  .site-footer {
    padding-bottom: calc(var(--mcp-bottom) + 0.75rem);
  }

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

  .form-group input,
  .form-group select,
  .form-group textarea {
    font-size: 16px;
    min-height: 48px;
  }

  .mcpro-toast {
    bottom: calc(var(--mcp-bottom) + 0.5rem) !important;
    left: var(--page-gutter);
    right: var(--page-gutter);
  }
}

/* ─── Mode nuit mobile (lisibilité header, recherche, contenu) ─── */
@media (max-width: 900px) {
  html[data-theme="dark"] body.mcpro-public-site,
  body.mcpro-public-site.theme-dark {
    --mcp-surface: #1e293b;
    --mcp-bg: #0f172a;
    --mcp-border: #475569;
    --mcp-muted: #cbd5e1;
    --mcp-primary: #e2e8f0;
    --cp-text: #e2e8f0;
    --cp-surface: #1e293b;
    --cp-bg: #0f172a;
    --cp-border: #475569;
    --cp-muted: #94a3b8;
    color: #e2e8f0;
  }

  /* Header sombre : règles centralisées dans theme.css */

  html[data-theme="dark"] .lang-switcher-menu,
  body.mcpro-public-site.theme-dark .lang-switcher-menu {
    background: #1e293b;
    border-color: #475569;
    color: #e2e8f0;
  }

  html[data-theme="dark"] .lang-switcher-menu-head,
  body.mcpro-public-site.theme-dark .lang-switcher-menu-head {
    background: #1e293b;
    border-bottom-color: #475569;
  }

  html[data-theme="dark"] .lang-option,
  body.mcpro-public-site.theme-dark .lang-option {
    color: #e2e8f0;
  }

  html[data-theme="dark"] .page-header,
  html[data-theme="dark"] .page-content,
  html[data-theme="dark"] .page-header h1,
  html[data-theme="dark"] .breadcrumb,
  html[data-theme="dark"] .breadcrumb a,
  body.mcpro-public-site.theme-dark .page-header,
  body.mcpro-public-site.theme-dark .page-content,
  body.mcpro-public-site.theme-dark .page-header h1,
  body.mcpro-public-site.theme-dark .breadcrumb,
  body.mcpro-public-site.theme-dark .breadcrumb a {
    color: #e2e8f0;
  }

  html[data-theme="dark"] .breadcrumb a,
  body.mcpro-public-site.theme-dark .breadcrumb a {
    color: #fbbf24;
  }

  html[data-theme="dark"] .hero-pro .lead,
  html[data-theme="dark"] .hero-stats,
  html[data-theme="dark"] .hero-stats span,
  body.mcpro-public-site.theme-dark .hero-pro .lead,
  body.mcpro-public-site.theme-dark .hero-stats,
  body.mcpro-public-site.theme-dark .hero-stats span {
    color: #e2e8f0;
  }

  /* hero-stats : fond blanc (#fff) → surface sombre */
  html[data-theme="dark"] body[data-page="home"] .hero-stats,
  body.mcpro-public-site.theme-dark[data-page="home"] .hero-stats {
    background: var(--cp-surface, #1e293b) !important;
    color: var(--cp-text, #e2e8f0);
  }

  html[data-theme="dark"] body[data-page="home"] .hero-stats div strong,
  body.mcpro-public-site.theme-dark[data-page="home"] .hero-stats div strong {
    color: var(--mcp-accent, #e85d04) !important;
  }

  html[data-theme="dark"] body[data-page="home"] .hero-stats div:nth-child(odd) strong,
  body.mcpro-public-site.theme-dark[data-page="home"] .hero-stats div:nth-child(odd) strong {
    color: var(--cp-orange-light, #f4a261) !important;
  }

  html[data-theme="dark"] body[data-page="home"] .hero-stats div span,
  body.mcpro-public-site.theme-dark[data-page="home"] .hero-stats div span {
    color: var(--cp-muted, #94a3b8) !important;
  }

  html[data-theme="dark"] .section-title,
  html[data-theme="dark"] .card,
  body.mcpro-public-site.theme-dark .section-title,
  body.mcpro-public-site.theme-dark .card {
    color: #e2e8f0;
  }

  html[data-theme="dark"] .nav-mobile-drawer,
  body.mcpro-public-site.theme-dark .nav-mobile-drawer {
    background: #1e293b;
    color: #e2e8f0;
  }

  html[data-theme="dark"] .nav-mobile-menu a,
  body.mcpro-public-site.theme-dark .nav-mobile-menu a {
    color: #e2e8f0;
    border-bottom-color: #475569;
  }

  html[data-theme="dark"] .nav-mobile-drawer-hint,
  body.mcpro-public-site.theme-dark .nav-mobile-drawer-hint {
    color: #94a3b8;
  }

  /* ─── Arbre catégories mobile ─── */
  .cat-drawer {
    width: 100vw;
    max-width: 100vw;
  }

  .cat-drawer-body {
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
  }

  .cat-drawer-body-split {
    display: block;
    overflow: visible;
    min-height: auto;
  }

  .cat-drawer--mega {
    width: 100vw;
    max-width: 100vw;
  }

  .cat-drawer--mega .cat-tree-accordion {
    width: 100%;
    border-right: 0;
    overflow: visible;
  }

  .cat-drawer--mega .cat-tree-l2-wrap {
    display: block !important;
  }

  .cat-mega-panel {
    display: none !important;
  }

  .cat-tree--mobile .cat-tree-l1:not(.is-open) .cat-tree-l2-wrap {
    max-height: 0 !important;
    overflow: hidden !important;
    display: block !important;
  }

  .cat-tree--mobile .cat-tree-l1.is-open .cat-tree-l2-wrap {
    max-height: 2000px !important;
    overflow: visible;
  }

  .cat-tree--mobile .cat-tree-l2:not(.is-open) .cat-tree-l3 {
    max-height: 0 !important;
    overflow: hidden !important;
  }

  .cat-tree--mobile .cat-tree-l2.is-open .cat-tree-l3 {
    max-height: 600px !important;
    overflow: visible;
  }

  /* Tiroir catégories au-dessus de la barre du bas (1200) */
  body.cat-drawer-open .mobile-bottom-nav {
    z-index: 1100 !important;
    pointer-events: none !important;
  }

  body.cat-drawer-open .cat-drawer {
    flex-direction: column !important;
    width: 100vw !important;
    max-width: 100vw !important;
    height: 100dvh !important;
    max-height: 100dvh !important;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    transform: translateX(0) !important;
    z-index: 1280 !important;
  }

  body.cat-drawer-open .cat-drawer-backdrop {
    z-index: 1270 !important;
  }

  .cat-drawer-head {
    flex-shrink: 0;
  }

  body.cat-drawer-open .cat-drawer-body,
  body.cat-drawer-open .cat-drawer-body-split {
    flex: 1 1 auto !important;
    min-height: 0 !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch !important;
    display: block !important;
    background: var(--cp-surface, #fff);
  }

  body.cat-drawer-open .cat-drawer-body-split .cat-tree-accordion,
  body.cat-drawer-open #cat-tree.cat-tree-accordion {
    display: block !important;
    width: 100% !important;
    min-height: 8rem;
    visibility: visible !important;
    opacity: 1 !important;
  }

  .cat-tree--mobile .cat-tree-l1 {
    display: block !important;
    border-bottom: 1px solid var(--cp-border, #e2e8f0);
  }

  .cat-tree--mobile .cat-tree-l1-btn {
    display: flex !important;
    width: 100%;
    min-height: 48px;
    color: #4a2c2a !important;
    background: var(--cp-surface, #fff) !important;
  }

  .cat-tree--mobile .cat-tree-l2-wrap {
    display: block !important;
  }

  .cat-tree--mobile .cat-tree-l1-btn {
    padding: 0.65rem 1rem;
    font-size: 0.95rem;
  }

  .cat-tree--mobile .cat-tree-l1-thumb {
    width: 40px;
    height: 32px;
    object-fit: cover;
    border-radius: 6px;
  }

  .cat-drawer-head {
    padding: 1rem 1rem 0.75rem;
    border-bottom: 1px solid var(--cp-border, #e2e8f0);
  }

  .cat-drawer-head strong {
    font-size: 1.1rem;
  }

  .cat-drawer-sub {
    display: block;
    margin-top: 0.25rem;
    font-size: 0.8rem;
    color: var(--cp-muted, #64748b);
  }

  .cat-drawer-loading,
  .cat-drawer-error {
    padding: 1.25rem 1rem;
    font-size: 0.95rem;
    color: var(--cp-text, #1a1a1a);
    text-align: center;
  }
}
