/**
 * Dentylis - Motifs de consultation
 * CSS FRONT — 1.2.0-RC2
 *
 * Extraction mécanique depuis la RC1 validée.
 * IMPORTANT : aucun style de includes/admin.php n'est inclus ici.
 * Les règles et leur ordre sont conservés sans optimisation.
 */

/* ===== Source RC1 : includes/shortcodes.php ===== */
.dentylis-recherche-motifs-public{width:100%;box-sizing:border-box}
        .dentylis-recherche-motifs-form{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:12px;align-items:end}
        .dentylis-recherche-motifs-champ label{display:block;margin:0 0 6px;font-weight:600}
        .dentylis-recherche-motifs-champ input{
            width:100%;
            height:46px;
            min-height:46px;
            box-sizing:border-box;
            padding:0 38px 0 46px;
            background:#fff;
            border:1px solid #d8e5e8;
            border-radius:7px;
            color:#444;
            font-size:14px;
            box-shadow:0 4px 10px rgba(0,0,0,.08);
            outline:none;
            transition:border-color .2s ease,box-shadow .2s ease;
        }
        .dentylis-recherche-motifs-champ input:focus{
            border-color:#3c539c;
            box-shadow:0 4px 12px rgba(21,155,176,.16);
        }
        .dentylis-recherche-motif-wrap,.dentylis-recherche-lieu-wrap{position:relative}
        .dentylis-motifs-icone{
            position:absolute;
            left:16px;
            top:50%;
            transform:translateY(-50%);
            color:#3c539c;
            font-size:18px;
            line-height:1;
            pointer-events:none;
            z-index:2;
        }
        .dentylis-suggestions-motifs,.dentylis-suggestions-lieux{position:absolute;z-index:9999;left:0;right:0;top:100%;max-height:260px;overflow-y:auto;background:#fff;border:1px solid #d5d5d5;box-shadow:0 6px 16px rgba(0,0,0,.12)}
        .dentylis-suggestion-motif,.dentylis-suggestion-lieu{display:block;width:100%;padding:10px 12px;border:0;border-bottom:1px solid #eee;background:#fff;text-align:left;cursor:pointer}
        .dentylis-suggestion-lieu small{display:block;opacity:.65;margin-top:2px}
        .dentylis-suggestion-motif:last-child,.dentylis-suggestion-lieu:last-child{border-bottom:0}
        .dentylis-suggestion-motif:hover,.dentylis-suggestion-motif:focus,.dentylis-suggestion-lieu:hover,.dentylis-suggestion-lieu:focus{background:#f5f7f9}
        .dentylis-recherche-motifs-resultats{margin-top:18px;display:grid;gap:12px}
        @media(max-width:767px){
            .dentylis-recherche-motifs-form{grid-template-columns:1fr}
        }
    
    .dentylis-motifs-compteur{
        margin:10px 0 0;
        font-size:15px;
        font-weight:600;
        color:#173d75;
    }
    .dentylis-motifs-compteur:empty{display:none;}

        /* v1.1.07
           Étape unique : masquer seulement l'ancien champ texte Jobylis.
           Le conteneur .dentylis-recherche, le rayon, la géolocalisation,
           le JavaScript Jobylis, la carte et les clusters restent intacts. */
        .dentylis-recherche > input#dentylis-recherche-etablissement,
        .dentylis-recherche > .dentylis-recherche-icone{
            visibility:hidden !important;
            pointer-events:none !important;
        }

        /* v1.1.08
           Présentation uniquement : rayon + géolocalisation remontent
           sur la même ligne que Lieu et Motif.
           Aucun élément Jobylis n'est déplacé ou supprimé dans le DOM. */
        @media (min-width:768px){
            .dentylis-recherche-motifs-form{
                grid-template-columns:minmax(0,1fr) minmax(0,1fr) 125px !important;
                gap:12px !important;
            }

            /* La 3e colonne de la grille reste libre pour les contrôles Jobylis. */
            .dentylis-recherche{
                height:0 !important;
                min-height:0 !important;
                margin:0 !important;
                overflow:visible !important;
                position:relative !important;
            }

            .dentylis-recherche > input#dentylis-recherche-etablissement{
                position:absolute !important;
                width:1px !important;
                height:1px !important;
                min-height:0 !important;
                padding:0 !important;
                margin:0 !important;
                border:0 !important;
            }

            .dentylis-recherche > .dentylis-rayon-select{
                top:-23px !important;
                right:40px !important;
                transform:translateY(-50%) !important;
            }

            .dentylis-recherche > .dentylis-geolocalisation{
                top:-23px !important;
                right:0 !important;
                transform:translateY(-50%) !important;
            }
        }

        /* v1.1.10
           Finition visuelle desktop uniquement :
           le rayon et la géolocalisation forment un petit bloc compact,
           aligné sur les deux champs. Aucun JS ni moteur n'est modifié. */
        @media (min-width:768px){
            .dentylis-recherche-motifs-form{
                grid-template-columns:minmax(0,1fr) minmax(0,1fr) 118px !important;
            }

            .dentylis-recherche > .dentylis-rayon-select{
                top:-23px !important;
                right:38px !important;
                width:76px !important;
                height:36px !important;
                padding:0 18px 0 10px !important;
                border:1px solid #d8e5e8 !important;
                border-radius:7px !important;
                background:#fff !important;
                box-shadow:0 4px 10px rgba(0,0,0,.08) !important;
            }

            .dentylis-recherche > .dentylis-geolocalisation{
                top:-23px !important;
                right:0 !important;
                width:36px !important;
                height:36px !important;
                border:1px solid #d8e5e8 !important;
                border-radius:7px !important;
                background:#fff !important;
                box-shadow:0 4px 10px rgba(0,0,0,.08) !important;
            }
        }

        /* v1.1.11
           Ajustement visuel uniquement :
           un peu plus de largeur pour Lieu/Motif et moins d'espace
           avant le bloc rayon + géolocalisation. */
        @media (min-width:768px){
            .dentylis-recherche-motifs-form{
                grid-template-columns:minmax(0,1fr) minmax(0,1fr) 108px !important;
                gap:8px !important;
            }

            .dentylis-recherche > .dentylis-rayon-select{
                right:34px !important;
                width:72px !important;
            }

            .dentylis-recherche > .dentylis-geolocalisation{
                right:0 !important;
                width:32px !important;
            }
        }

        /* v1.1.12
           Ajustement visuel desktop uniquement :
           Lieu et Motif gagnent encore en largeur et le bloc
           rayon + géolocalisation se rapproche davantage. */
        @media (min-width:768px){
            .dentylis-recherche-motifs-form{
                grid-template-columns:minmax(0,1fr) minmax(0,1fr) 96px !important;
                gap:5px !important;
            }

            .dentylis-recherche > .dentylis-rayon-select{
                right:30px !important;
                width:64px !important;
                padding-left:7px !important;
                padding-right:14px !important;
            }

            .dentylis-recherche > .dentylis-geolocalisation{
                right:0 !important;
                width:29px !important;
            }
        }

        /* v1.1.13
           Le champ Lieu garde sa largeur mais son texte dispose
           de davantage d'espace utile afin d'afficher "région" en entier. */
        @media (min-width:768px){
            .dentylis-recherche-lieu-wrap input{
                padding-right:14px !important;
                font-size:13.5px !important;
            }
        }

        /* v1.1.16
           1. Rayon + géolocalisation restent calés sur la ligne des champs,
              même lorsque le compteur de résultats apparaît.
           2. Aucun changement du moteur de carte. */
        @media (min-width:768px){
            .dentylis-recherche{
                position:relative !important;
            }
            .dentylis-recherche > .dentylis-rayon-select,
            .dentylis-recherche > .dentylis-geolocalisation{
                top:-23px !important;
                margin-top:0 !important;
            }
        }

        /* v1.1.22 — retour propre après l'essai v1.1.21.
           Aucun HTML du champ Lieu n'est modifié.
           On retire seulement de l'affichage les contrôles Jobylis flottants
           avant de reprendre leur intégration proprement à l'étape suivante. */
        @media (min-width:768px){
            .dentylis-recherche{
                height:0 !important;
                min-height:0 !important;
                margin:0 !important;
                overflow:hidden !important;
            }
            .dentylis-recherche > .dentylis-rayon-select,
            .dentylis-recherche > .dentylis-geolocalisation{
                visibility:hidden !important;
                pointer-events:none !important;
            }
        }

        /* v1.1.24
           Étape visuelle sûre :
           - champs Lieu et Motif plus longs ;
           - géolocalisation Jobylis réaffichée normalement pour contrôle.
           Aucun HTML ni moteur de recherche n'est modifié. */
        @media (min-width:768px){
            .dentylis-recherche-motifs-form{
                grid-template-columns:minmax(0,1fr) minmax(0,1fr) !important;
                gap:6px !important;
                width:100% !important;
            }

            .dentylis-recherche-motifs-champ{
                min-width:0 !important;
            }

            .dentylis-recherche > .dentylis-geolocalisation{
                visibility:visible !important;
                pointer-events:auto !important;
                position:absolute !important;
                right:0 !important;
                top:50% !important;
                transform:translateY(-50%) !important;
                width:36px !important;
                height:36px !important;
                margin:0 !important;
                z-index:10 !important;
            }

            /* Le rayon reste masqué à cette étape. */
            .dentylis-recherche > .dentylis-rayon-select{
                visibility:hidden !important;
                pointer-events:none !important;
            }
        }

        /* v1.1.31 — géolocalisation Jobylis d'origine dans le champ Lieu.
           IMPORTANT : on ne crée aucun doublon. Le vrai select de rayon et
           le vrai bouton Jobylis sont déplacés visuellement dans le wrapper Lieu,
           ce qui conserve leurs écouteurs et toute la logique existante. */
        .dentylis-recherche-lieu-wrap{
            position:relative !important;
        }
        .dentylis-recherche-lieu-wrap input{
            padding-right:112px !important;
        }
        .dentylis-recherche-lieu-wrap > .dentylis-rayon-select{
            visibility:visible !important;
            pointer-events:auto !important;
            position:absolute !important;
            right:39px !important;
            top:50% !important;
            transform:translateY(-50%) !important;
            width:67px !important;
            height:30px !important;
            padding:0 16px 0 6px !important;
            margin:0 !important;
            border:0 !important;
            border-left:1px solid #d8e5e8 !important;
            border-radius:0 !important;
            background:#fff !important;
            box-shadow:none !important;
            z-index:7 !important;
        }
        .dentylis-recherche-lieu-wrap > .dentylis-geolocalisation{
            visibility:visible !important;
            pointer-events:auto !important;
            position:absolute !important;
            right:4px !important;
            top:50% !important;
            transform:translateY(-50%) !important;
            width:34px !important;
            height:34px !important;
            margin:0 !important;
            padding:0 !important;
            display:flex !important;
            align-items:center !important;
            justify-content:center !important;
            border:0 !important;
            background:transparent !important;
            box-shadow:none !important;
            z-index:8 !important;
        }
        /* v1.1.40 — finition visuelle uniquement.
           - le libellé du rayon (ex. 10 km) dispose d'un peu plus de largeur ;
           - sur mobile, Lieu et Motif forment un bloc compact à deux lignes ;
           - la carte visible commence sous ce bloc, sans chevauchement. */
        .dentylis-recherche-lieu-wrap > .dentylis-rayon-select{
            width:74px !important;
            right:39px !important;
            padding-left:6px !important;
            padding-right:14px !important;
        }
        .dentylis-recherche-lieu-wrap input{
            padding-right:120px !important;
        }
        @media (max-width:767px){
            .dentylis-recherche-motifs-form{
                gap:2px !important;
            }
            .dentylis-recherche-motifs-champ{
                margin:0 !important;
            }
        }

        /* v1.1.55 — boutons d'effacement fiables sur iPhone et desktop. */
        .dentylis-effacer-champ{
            display:none; position:absolute; top:50%; transform:translateY(-50%);
            width:26px; height:26px; padding:0; margin:0; border:0;
            border-radius:50%; background:transparent; color:#6d7785;
            font-size:22px; line-height:24px; font-family:Arial,sans-serif;
            font-weight:400; text-align:center; cursor:pointer; z-index:12;
            -webkit-appearance:none; appearance:none;
        }
        .dentylis-effacer-champ.is-visible{display:block;}
        .dentylis-effacer-lieu{right:116px;}
        .dentylis-effacer-motif{right:7px;}
        .dentylis-recherche-lieu-wrap input{padding-right:146px !important;}
        .dentylis-recherche-motif-wrap input{padding-right:38px !important;}

/* ===== Source RC1 : includes/interactions.php ===== */
.dentylis-compteur-centres-1167{
            width:100%;
            margin:0 0 12px 0;
            text-align:center;
            font-weight:600;
            font-size:17px;
        }
        /* v1.1.68 : l'ancien compteur sous les champs reste disponible
           pour le JS historique, mais n'est plus affiché. */
        .dentylis-recherche-motifs-public > .dentylis-motifs-compteur{
            display:none !important;
        }

/* ===== Source RC1 : includes/interactions.php ===== */
@media (min-width:768px){
        .dentylis-recherche-motifs-public input[type="search"]::-webkit-search-cancel-button{
            -webkit-appearance:none !important;
            appearance:none !important;
            display:none !important;
        }
        .dentylis-recherche-motifs-public input[type="search"]::-ms-clear,
        .dentylis-recherche-motifs-public input[type="search"]::-ms-reveal{
            display:none !important;
            width:0 !important;
            height:0 !important;
        }
    }

/* ===== Source RC1 : includes/interactions.php ===== */
@media (max-width:767px){
        .dentylis-scroll-reserve-1189{
            display:block !important;
            width:1px !important;
            height:0;
            margin:0 !important;
            padding:0 !important;
            border:0 !important;
            opacity:0 !important;
            pointer-events:none !important;
        }
    }
