/* Menu des catégories des pages produit et prestation */
.cat-menu{margin:0;background:linear-gradient(90deg,#067f84,#0a8f8d);color:#fff;box-shadow:0 4px 14px rgba(8,35,77,.18)}
.cat-menu-bar{position:relative;z-index:30;display:flex;align-items:center;gap:6px;padding-top:8px;padding-bottom:8px;box-sizing:border-box}
.cat-menu-all{position:relative;flex:none}
.cat-menu-toggle{display:inline-flex;align-items:center;gap:9px;padding:10px 16px;border:0;border-radius:11px;background:#fff;color:#08234d;font:inherit;font-weight:800;font-size:15px;cursor:pointer}
.cat-menu-toggle i{width:8px;height:8px;border-right:2px solid #08234d;border-bottom:2px solid #08234d;transform:rotate(45deg) translateY(-2px);transition:transform .15s}
.cat-menu-toggle[aria-expanded=true] i{transform:rotate(-135deg)}
.cat-tabs{display:flex;flex:1;gap:2px;margin:0;padding:0 4px;overflow-x:auto;list-style:none;scrollbar-width:none}
.cat-tabs::-webkit-scrollbar{display:none}
.cat-tabs a{display:inline-flex;align-items:center;gap:8px;padding:10px 12px;border-radius:10px;color:#fff;font-weight:700;font-size:14px;text-decoration:none;white-space:nowrap}
.cat-tabs a:hover,.cat-tabs a.is-active{background:rgba(255,255,255,.18)}
.cat-search{flex:none;display:grid;place-items:center;width:40px;height:40px;border-radius:10px;color:#fff;border-left:1px solid rgba(255,255,255,.35)}
.cat-search:hover{background:rgba(255,255,255,.18)}
.cat-mega{position:absolute;z-index:40;top:calc(100% + 10px);left:0;display:flex;width:max-content;max-width:88vw;border-radius:12px;background:#fff;box-shadow:0 14px 40px rgba(8,35,77,.25);color:#08234d}
.cat-mega[hidden]{display:none}
.cat-mega-cats{margin:0;padding:8px;list-style:none;min-width:230px}
.cat-mega-cats>li{position:static}
.cat-mega-cat{display:flex;align-items:center;gap:10px;padding:9px 12px;border-radius:9px;color:#08234d;font-weight:700;font-size:14px;text-decoration:none}
.cat-mega-cat>span:not(.cat-ico){flex:1}
.cat-mega-cat i{width:7px;height:7px;border-right:2px solid #5d7391;border-top:2px solid #5d7391;transform:rotate(45deg)}
.cat-mega-cat .px-icon{color:#0a8f8d}
.cat-mega-cats>li:hover>.cat-mega-cat,.cat-mega-cats>li.is-open>.cat-mega-cat{background:#e8f6f6}
.cat-mega-subs{display:none;position:absolute;top:0;left:100%;margin:0;padding:8px;min-width:230px;min-height:100%;list-style:none;background:#fff;border-radius:0 12px 12px 0;box-shadow:12px 10px 30px rgba(8,35,77,.16)}
.cat-mega-cats>li:hover>.cat-mega-subs,.cat-mega-cats>li.is-open>.cat-mega-subs{display:block}
.cat-mega-subs a{display:block;padding:8px 12px;border-radius:8px;color:#08234d;font-size:14px;text-decoration:none}
.cat-mega-subs a:hover{background:#e8f6f6}
@media(max-width:700px){.cat-menu-bar{flex-wrap:wrap}.cat-tabs{order:3;flex-basis:100%}.cat-mega{flex-direction:column;max-width:calc(100vw - 48px)}.cat-mega-subs{position:static;box-shadow:none;border-radius:0;padding-left:30px;min-width:0}}
.cat-ico{display:inline-block;flex:none;width:20px;height:20px;background:currentColor;-webkit-mask:var(--ico) center/contain no-repeat;mask:var(--ico) center/contain no-repeat}
.cat-mega-cat .cat-ico{color:#0a8f8d}

/* Recherche en direct : le champ s'ouvre avec une animation à gauche du bouton */
.cat-search{position:relative;flex:none;display:block;width:auto;height:auto;border-left:0}
.cat-search-btn{display:grid;place-items:center;width:40px;height:40px;border:0;border-left:1px solid rgba(255,255,255,.35);border-radius:10px;background:transparent;color:#fff;cursor:pointer}
.cat-search-btn:hover,.cat-search-btn[aria-expanded=true]{background:rgba(255,255,255,.18)}
.cat-search-panel{position:absolute;z-index:45;top:0;right:100%;width:min(460px,calc(100vw - 110px));transform-origin:right center;transform:scaleX(.05);opacity:0;visibility:hidden;transition:transform .24s ease,opacity .2s ease,visibility 0s linear .24s}
.cat-search.is-open .cat-search-panel{transform:scaleX(1);opacity:1;visibility:visible;transition:transform .24s ease,opacity .2s ease}
.cat-search-panel form{display:flex;align-items:center;height:40px;border-radius:10px;background:#fff;box-shadow:0 6px 18px rgba(8,35,77,.25)}
.cat-search-panel input{flex:1;min-width:0;height:100%;padding:0 14px;border:0;border-radius:10px 0 0 10px;background:transparent;color:#08234d;font:inherit;font-size:14.5px;outline:0}
.cat-search-panel form button{height:calc(100% - 8px);margin:4px;padding:0 14px;border:0;border-radius:8px;background:#0a8f8d;color:#fff;font:inherit;font-weight:800;font-size:13.5px;cursor:pointer}
.cat-search-results{position:absolute;top:calc(100% + 8px);left:0;right:0;margin:0;padding:6px;max-height:60vh;overflow:auto;list-style:none;border-radius:12px;background:#fff;color:#08234d;box-shadow:0 14px 40px rgba(8,35,77,.28)}
.cat-search-results[hidden]{display:none}
.cat-search-results a{display:flex;align-items:center;gap:10px;padding:9px 12px;border-radius:9px;color:#08234d;text-decoration:none}
.cat-search-results a:hover,.cat-search-results a:focus-visible{background:#e8f6f6;outline:0}
.cat-search-results .sr-type{flex:none;padding:2px 8px;border-radius:99px;background:#e9f6f5;color:#0f6f6c;font-size:11.5px;font-weight:800}
.cat-search-results .sr-label{flex:1;min-width:0;font-weight:700;font-size:14px}
.cat-search-results .sr-label small{display:block;color:#5d7391;font-weight:500;font-size:12px}
.cat-search-results .sr-price{flex:none;color:#047f7d;font-size:12.5px;font-weight:800}
.cat-search-results .sr-empty{padding:12px;color:#5d7391;font-size:14px}
@media(prefers-reduced-motion:reduce){.cat-search-panel,.cat-search.is-open .cat-search-panel{transition:none}}
/* Les besoins se répartissent sur toute la place disponible */
.cat-tabs{justify-content:space-between;gap:4px}
.cat-tabs li{flex:1 1 auto;display:flex}
.cat-tabs a{flex:1;justify-content:center}
.cat-mega-subs{max-height:min(72vh,560px);overflow-y:auto;min-width:270px}
.cat-mega-head{padding:10px 12px 4px;color:#5d7391;font-size:11.5px;font-weight:800;letter-spacing:.04em;text-transform:uppercase}
.cat-mega-all a{background:#e8f6f6;font-weight:800;color:#047f7d}
.cat-mega-footer{margin-top:6px;padding-top:6px;border-top:1px solid #e1eaf0}
.cat-mega-footer a{display:block;padding:9px 12px;border-radius:9px;color:#047f7d;font-weight:800;font-size:14px;text-decoration:none}
.cat-mega-footer a:hover{background:#e8f6f6}
@media(max-width:700px){.cat-tabs{justify-content:flex-start}.cat-tabs li{flex:none}}
/* Bouton « Prestations » : toutes les prestations, rangées par catégorie */
.cat-mega{display:block;width:min(980px,92vw);max-height:min(78vh,640px);overflow-y:auto;padding:14px 16px 8px}
.cat-mega-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(210px,1fr));gap:18px 24px}
.cat-mega-col h3{margin:0 0 6px;font-size:14px}
.cat-mega-col h3 a{display:flex;align-items:center;gap:8px;padding:6px 8px;border-radius:8px;color:#047f7d;font-weight:800;text-decoration:none}
.cat-mega-col h3 a:hover{background:#e8f6f6}
.cat-mega-col h3 .cat-ico,.cat-mega-col h3 .px-icon{color:#0a8f8d}
.cat-mega-col ul{display:grid;gap:1px;margin:0;padding:0;list-style:none}
.cat-mega-col ul a{display:block;padding:6px 8px;border-radius:7px;color:#08234d;font-size:13.5px;text-decoration:none}
.cat-mega-col ul a:hover{background:#e8f6f6}
p.cat-mega-footer{display:flex;flex-wrap:wrap;gap:6px 18px;margin:12px 0 0;padding:10px 4px 6px;border-top:1px solid #e1eaf0}
p.cat-mega-footer a{display:inline;padding:4px 8px}
/* Menu « Prestations » à deux niveaux : catégories à gauche, sous-menu (prestations et produits) au survol */
.cat-mega{display:flex;width:max-content;max-width:88vw;max-height:none;overflow:visible;padding:0}
.cat-mega-cats{min-width:250px}
.cat-mega-subs{min-width:300px;max-width:380px;max-height:min(72vh,560px);overflow-y:auto}
.cat-mega-subs a{display:flex;align-items:center;justify-content:space-between;gap:10px;line-height:1.3}
.cat-tag{flex:none;padding:1px 7px;border-radius:99px;background:#e9f6f5;color:#0f6f6c;font-size:10.5px;font-style:normal;font-weight:800}
li.cat-mega-footer{display:flex;flex-direction:column;margin-top:6px;padding-top:6px;border-top:1px solid #e1eaf0}
li.cat-mega-footer a{display:block;padding:8px 12px;border-radius:9px;color:#047f7d;font-weight:800;font-size:14px;text-decoration:none}
li.cat-mega-footer a:hover{background:#e8f6f6}
@media(max-width:700px){.cat-mega-subs{max-width:none}}
/* Trois niveaux : catégorie → sous-catégorie → prestations et produits */
.cat-mega-subs{min-width:240px;max-width:300px;max-height:none;overflow:visible}
.cat-mega-subs.cat-mega-flat{min-width:300px;max-width:380px;max-height:min(72vh,560px);overflow-y:auto}
.cat-mega-sub{position:relative}
.cat-mega-subname{display:flex;align-items:center;gap:8px;padding:8px 12px;border-radius:8px;color:#08234d;font-size:14px;text-decoration:none}
.cat-mega-subname span{flex:1}
.cat-mega-subname i{width:6px;height:6px;border-right:2px solid #5d7391;border-top:2px solid #5d7391;transform:rotate(45deg)}
.cat-mega-sub:hover>.cat-mega-subname,.cat-mega-sub.is-open>.cat-mega-subname{background:#e8f6f6}
.cat-mega-items{display:none;position:absolute;top:0;left:100%;margin:0;padding:8px;min-width:300px;max-width:380px;max-height:min(72vh,560px);overflow-y:auto;list-style:none;background:#fff;border-radius:0 12px 12px 12px;box-shadow:12px 10px 30px rgba(8,35,77,.16)}
.cat-mega-sub:hover>.cat-mega-items,.cat-mega-sub.is-open>.cat-mega-items{display:block}
.cat-mega-items a{display:block;padding:8px 12px;border-radius:8px;color:#08234d;font-size:14px;line-height:1.3;text-decoration:none}
.cat-mega-items a:hover{background:#e8f6f6}
@media(max-width:700px){.cat-mega-items{position:static;box-shadow:none;border-radius:0;padding-left:20px;min-width:0;max-width:none}}
/* Passage d'un menu à son sous-menu : zone de tolérance invisible + fermeture différée (JS, classe is-hover) */
.cat-mega-subs::before,.cat-mega-items::before{content:'';position:absolute;top:0;bottom:0;right:100%;width:22px}
.cat-mega-cats>li.is-hover>.cat-mega-subs{display:block}
.cat-mega-cats>li.is-hover>.cat-mega-cat{background:#e8f6f6}
.cat-mega-sub.is-hover>.cat-mega-items{display:block}
.cat-mega-sub.is-hover>.cat-mega-subname{background:#e8f6f6}

/* ===== Esthétique « trois colonnes » : catégories | sous-catégories | prestations et produits ===== */
.cat-menu{background:#005a5f;box-shadow:0 4px 14px rgba(0,40,50,.22)}
.cat-menu-bar{gap:8px;padding-top:10px;padding-bottom:10px}
.cat-menu-toggle{gap:10px;padding:11px 20px;border-radius:999px;font-size:16px;box-shadow:0 2px 6px rgba(0,0,0,.15)}
.cat-menu-toggle .cat-grid{color:#0a8f8d}
.cat-menu-all{padding-right:14px;margin-right:6px;border-right:1px solid rgba(255,255,255,.28)}
.cat-tabs{gap:8px}
.cat-tabs a{padding:11px 18px;border-radius:999px;background:rgba(0,0,0,.18);font-size:15px}
.cat-tabs a:hover{background:rgba(255,255,255,.14)}
.cat-tabs a.is-active{background:#0a8f8d}
.cat-search-btn{border-radius:999px}

.cat-mega{display:block;width:min(1000px,92vw);min-height:350px;max-height:none;overflow:visible;padding:0;border:1px solid #bfe0df;border-radius:16px;background:#fff;box-shadow:0 18px 44px rgba(0,50,60,.24)}
.cat-mega-cats{width:270px;min-width:0;margin:0;padding:12px;box-sizing:border-box}
.cat-mega-cat{gap:12px;padding:12px 14px;border-radius:12px;font-size:16px;font-weight:800}
.cat-mega-cat .px-icon,.cat-mega-cat .cat-ico{width:24px;height:24px;color:#0a8f8d}
.cat-mega-cat i{width:8px;height:8px;border-color:#08234d}
.cat-mega .cat-mega-cats>li>.cat-mega-subs,.cat-mega .cat-mega-sub>.cat-mega-items{display:none}
.cat-mega .cat-mega-cats>li.is-hover>.cat-mega-subs,.cat-mega .cat-mega-cats>li.is-open>.cat-mega-subs{display:block}
.cat-mega .cat-mega-sub.is-hover>.cat-mega-items,.cat-mega .cat-mega-sub.is-open>.cat-mega-items{display:block}
.cat-mega .cat-mega-cats>li.is-hover>.cat-mega-cat,.cat-mega .cat-mega-cats>li.is-open>.cat-mega-cat{background:#d8f1ef}
.cat-mega-subs{position:absolute;top:0;bottom:0;left:270px;width:310px;min-width:0;max-width:none;margin:0;padding:12px;box-sizing:border-box;overflow-y:auto;border-left:1px solid #d7e8ec;border-radius:0;background:#fff;box-shadow:none}
.cat-mega-subs::before,.cat-mega-items::before{display:none}
.cat-mega-sub{position:static}
.cat-mega-subhead a{display:flex;align-items:center;gap:12px;padding:8px 12px 12px;color:#08234d;font-size:17px;font-weight:800;text-decoration:none}
.cat-mega-subhead .px-icon,.cat-mega-subhead .cat-ico{width:24px;height:24px;color:#0a8f8d}
.cat-mega-subname{padding:12px 14px;border-radius:12px;font-size:16px}
.cat-mega .cat-mega-sub.is-hover>.cat-mega-subname,.cat-mega .cat-mega-sub.is-open>.cat-mega-subname{background:#d8f1ef}
.cat-mega-items{position:absolute;top:0;bottom:0;left:100%;width:420px;max-width:none;max-height:none;min-width:0;margin:0;padding:12px 16px;box-sizing:border-box;overflow-y:auto;border-left:1px solid #d7e8ec;border-radius:0 16px 16px 0;background:#fff;box-shadow:none}
.cat-mega-items a{display:flex;align-items:center;gap:14px;padding:11px 8px;font-size:15.5px}
.cat-mega-items a .cat-ico{width:24px;height:24px;color:#0a8f8d}
.cat-mega-items a span:last-child{flex:1}
.cat-mega-footer{margin:8px 0 0;padding-top:10px}
.cat-mega-footer a{font-size:16px}
@media(max-width:900px){
  .cat-mega{width:calc(100vw - 32px);min-height:0}
  .cat-mega-cats{width:auto}
  .cat-mega-subs{position:static;width:auto;border-left:0;padding:4px 4px 4px 28px}
  .cat-mega-items{position:static;width:auto;border-left:0;padding:2px 4px 6px 20px}
}
/* Corrections : la 3e colonne dépasse de la 2e (pas de défilement sur celle-ci), titre aligné à gauche */
.cat-mega-subs{overflow:visible}
.cat-mega-subs .cat-mega-subhead a{justify-content:flex-start}
.cat-mega-subs .cat-mega-subname{justify-content:space-between}
@media(max-width:900px){.cat-mega-subs{overflow:visible}}
