/* =====================================================================
   LANDORA — COUCHE RESPONSIVE (site web)
   Chargée en DERNIER sur toutes les pages : corrige l'affichage sur
   téléphone, tablette et ordinateur sans toucher aux feuilles d'origine.
   ===================================================================== */

/* ---------- Partout : jamais de défilement horizontal ---------- */
html { overflow-x: hidden; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { width: auto !important; max-width: 100% !important; overflow-x: hidden; }
img, video, canvas, iframe, svg { max-width: 100%; }
input, select, textarea, button { max-width: 100%; font-family: inherit; }
table { max-width: 100%; }

/* ---------- Pied de page commun (réseaux + liens) ---------- */
footer .social,
footer .fi {
    left: 0 !important;
    right: auto !important;
    width: 100%;
    justify-content: center;
    flex-wrap: wrap;
}
footer .fi { gap: 10px 32px; padding: 0 16px; bottom: auto; }
footer .fi a { font-size: clamp(15px, 1.5vw, 19px); }
footer .social { top: 0; margin-bottom: 14px; }

/* ---------- Bouton « Acheter / Louer » : catégories ---------- */
#buy {
    left: auto !important;
    top: auto !important;
    margin: 150px auto 60px;
    width: min(1120px, calc(100% - 32px));
}
#buy .icons-buy {
    width: 100% !important;
    height: auto !important;
    padding: 24px;
    gap: 24px;
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr));
}
#buy .icons-buy > section {
    width: auto !important;
    height: auto !important;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 16px 12px 20px;
    text-align: center;
}
#buy .icons-buy img {
    width: 100% !important;
    max-width: 300px;
    height: auto !important;
    aspect-ratio: 1 / 1;
    object-fit: contain;
    margin: 0 !important;
}

/* ---------- Pages de catégories (Appartements, Villas…) ---------- */
#appartsmeub > h1, #apparts > h1, #chambreMeublés > h1, #Chambre > h1, #Locaux > h1, #Maison > h1,
#Salledefete > h1, #Studio > h1, #Studiomeubles > h1, #terrains > h1, #Villasmeubles > h1, #Villas > h1,
#Discover > h1, #page-title {
    top: auto !important;
    margin: 130px 16px 24px !important;
    font-size: clamp(28px, 4.6vw, 56px) !important;
    line-height: 1.15;
}
#appartsmeub .annonce-card, #apparts .annonce-card, #chambreMeublés .annonce-card, #Chambre .annonce-card,
#Locaux .annonce-card, #Maison .annonce-card, #Salledefete .annonce-card, #Studio .annonce-card,
#Studiomeubles .annonce-card, #terrains .annonce-card, #Villasmeubles .annonce-card, #Villas .annonce-card,
#Discover .annonce-card {
    margin-top: 0;
}
#Salledefete > p, #Salledefete > #lodging-search { margin-left: 16px; margin-right: 16px; }
#fi2 { margin-top: 120px; }

/* ---------- Détail d'un bien ---------- */
.details-container .btn-contact {
    width: 100% !important;
    font-size: clamp(18px, 2vw, 24px) !important;
    padding: 14px 20px;
    border-radius: 999px;
}

/* ---------- Abonnements (Subscribe) ---------- */
.type button {
    width: auto !important;
    min-width: 160px;
    font-size: 18px !important;
    padding: 10px 24px;
    margin-left: auto !important;
    margin-right: auto !important;
    display: block;
    line-height: 1.2;
}

/* ---------- Publier un bien (Sell) ---------- */
#publication { font-size: 16px; }
#publication h1, #publication > h2 { font-size: clamp(26px, 4vw, 40px); }
.location-section h2, .location-heading h2 { font-size: clamp(22px, 3vw, 30px); }
.location-section p, .location-heading p { font-size: 15px; line-height: 1.5; }

/* ---------- Champ téléphone (pays + numéro) ---------- */
.lp-phone { flex-wrap: nowrap; }
.lp-phone > .lp-trigger.lp-dial,
#form .lp-phone > button.lp-dial,
#Sign-In .lp-phone > button.lp-dial {
    flex: 0 0 auto;
    width: auto !important;
    max-width: 42% !important;
    margin: 0 !important;
}
.lp-phone > .lp-number { flex: 1 1 auto; min-width: 0; }
#form .lp-phone { max-width: 450px; width: 100%; margin-top: 0; }
@media (max-width: 768px) { #form .lp-phone { width: 85%; margin: 15px auto 0; } }

/* =====================================================================
   TABLETTE (≤ 1024 px)
   ===================================================================== */
@media (max-width: 1024px) {
    /* Bouton loupe : en bas à droite, au-dessus d'EJNA (il recouvrait les titres). */
    .search-btn button {
        top: auto !important;
        left: auto !important;
        right: 24px !important;
        bottom: 96px !important;
        width: 56px !important;
        height: 56px !important;
        box-shadow: 0 0 0 3px #0b0b0b, 0 6px 18px rgba(218, 165, 32, .55) !important;
    }
    .search-btn button img { width: 26px; height: 26px; }

    #buy .icons-buy { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* =====================================================================
   TÉLÉPHONE (≤ 600 px)
   ===================================================================== */
@media (max-width: 600px) {
    #buy { margin-top: 120px; width: calc(100% - 24px); gap: 18px; }
    #buy .icons-buy { padding: 14px; gap: 14px; }
    #buy .icons-buy > section { padding: 10px 6px 14px; }
    #buy .icons-buy h2 { font-size: 15px; margin: 8px 0 0; }

    #appartsmeub > h1, #apparts > h1, #chambreMeublés > h1, #Chambre > h1, #Locaux > h1, #Maison > h1,
    #Salledefete > h1, #Studio > h1, #Studiomeubles > h1, #terrains > h1, #Villasmeubles > h1, #Villas > h1,
    #Discover > h1, #page-title {
        margin: 110px 12px 16px !important;
        font-size: 28px !important;
    }

    #fi, #fi2, #fi3 { margin-top: 60px !important; }
    footer .fi { gap: 8px 22px; }
    footer .fi a { font-size: 15px; }

    .details-container { margin-left: 12px !important; margin-right: 12px !important; }

    .type h1 { font-size: 26px !important; }
    .type ul { padding-left: 20px; }
}

/* =====================================================================
   GRAND ÉCRAN (≥ 1600 px) : contenu centré, pas étiré sur toute la largeur
   ===================================================================== */
@media (min-width: 1600px) {
    .annonce-card { max-width: 1500px; }
}

/* =====================================================================
   ACCUEIL : barre « Acheter · Louer · Types · Localisation · Rechercher »
   (largeur fixe de 1150 px : elle débordait sous 1300 px de large)
   ===================================================================== */
@media (min-width: 769px) {
    #undernav {
        left: auto !important;
        width: min(1150px, calc(100% - 48px)) !important;
        margin-left: auto !important;
        margin-right: auto !important;
    }
}
@media (min-width: 1400px) { #undernav { width: min(1300px, calc(100% - 48px)) !important; } }
@media (min-width: 1800px) { #undernav { width: min(1500px, calc(100% - 48px)) !important; } }

/* =====================================================================
   CONNEXION (Sign in) : formulaire centré, lien « Mot de passe oublié »
   sous le mot de passe (il était décalé à gauche sur ordinateur)
   ===================================================================== */
#Sign-In {
    display: flex !important;
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
    width: min(420px, calc(100% - 32px)) !important;
    margin: 0 auto !important;
}
#Sign-In br { display: none; }
#Sign-In #email-number,
#Sign-In #Password {
    order: 1;
    position: static !important;
    left: auto !important; top: auto !important;
    width: 100% !important;
    max-width: none !important;
    height: 46px !important;
    margin: 0 !important;
    padding: 0 12px;
    border-radius: 10px;
    font-size: 17px !important;
}
#Sign-In #Password { order: 2; }
#Sign-In .Sign-a {
    order: 3;
    position: static !important;
    left: auto !important; top: auto !important;
    align-self: flex-end;
    font-size: 15px !important;
    margin: 0 !important;
}
#Sign-In #Ne {
    order: 4;
    position: static !important;
    left: auto !important; top: auto !important;
    width: 100% !important;
    max-width: none !important;
    margin: 10px 0 0 !important;
    height: 50px;
    font-size: 20px !important;
    border-radius: 999px;
}
.Sign .Newp { position: static !important; margin: 18px 16px 0 !important; font-size: 16px !important; }
.Sign > h1, .Sign > h3 { position: static !important; top: auto !important; left: auto !important; }
.Sign > h1 { margin: 12px 16px 6px !important; font-size: clamp(30px, 5vw, 50px) !important; }
.Sign > h3 { margin: 0 16px 22px !important; font-size: clamp(18px, 2.4vw, 25px) !important; }
#Sign > .header { top: auto !important; margin-top: 100px !important; }
.Sign > h1, .Sign > h3, .Sign .Newp { width: auto !important; }
#slogan, main.main > p { width: auto !important; max-width: calc(100% - 40px); }

/* Cartes de biens loués : la durée (« / 1 mois ») était noire sur fond
   gris foncé, presque invisible. */
.carte-bien .price-period {
    display: block;
    margin: -2px 0 6px;
    font-size: 14px;
    font-weight: 700;
    color: #e8e8e8;
    text-align: left;
}

/* Accueil : libellés de la barre horizontale en gras. */
#undernav > a { font-weight: 700; }

/* =====================================================================
   CHARGEMENT : cases à la taille du contenu attendu + logo qui bat
   (posées par LandoraSkeleton.js)
   ===================================================================== */
.lsk {
    position: relative;
    overflow: hidden;
    background: #161616;
    border: 1px solid #262626;
    border-radius: 16px;
    box-sizing: border-box;
}
.lsk::before {               /* reflet qui passe */
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(100deg, transparent 30%, rgba(255, 255, 255, .05) 50%, transparent 70%);
    background-size: 250% 100%;
    animation: lsk-shine 1.6s linear infinite;
}
.lsk::after {                /* logo au centre, qui bat comme un cœur */
    content: "";
    position: absolute;
    inset: 0;
    background: url("Image/small/landora-logo-mark.webp") center / auto min(64px, 46%) no-repeat;
    animation: lsk-beat 1.3s ease-in-out infinite;
}
.lsk--card { min-height: 420px; width: 100%; }
.lsk--pro  { min-height: 280px; width: 100%; }
.lsk--row  { height: 78px; width: 100%; border-radius: 14px; margin-bottom: 12px; }
.lsk--row::after { background-size: auto 44px; }

@keyframes lsk-beat {
    0%, 60%, 100% { transform: scale(1);    opacity: .85; }
    15%           { transform: scale(1.18); opacity: 1; }
    30%           { transform: scale(1); }
    45%           { transform: scale(1.1);  opacity: 1; }
}
@keyframes lsk-shine { from { background-position: 120% 0; } to { background-position: -120% 0; } }
@media (prefers-reduced-motion: reduce) {
    .lsk::before, .lsk::after { animation: none; }
}

/* =====================================================================
   APPLI MOBILE : boutons Google Play / App Store (LandoraSite.js)
   ===================================================================== */
.app-badges {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin: 6px auto 18px;
    padding: 0 16px;
    position: static;
}
.app-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-width: 168px;
    padding: 8px 16px;
    border-radius: 12px;
    background: #000;
    color: #fff !important;
    border: 1px solid rgba(255, 255, 255, .35);
    text-decoration: none !important;
    font-size: 17px;
    font-weight: 700;
    line-height: 1.1;
    text-align: left;
    box-sizing: border-box;
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}
.app-badge i { font-size: 26px; width: 28px; text-align: center; }
.app-badge small { display: block; font-size: 11px; font-weight: 500; opacity: .85; letter-spacing: .02em; }
a.app-badge:hover { border-color: goldenrod; }
.app-badge.is-soon { opacity: .6; cursor: default; }
.footer .app-badges { margin: 0; padding: 0; justify-content: flex-start; }
.footer-legal a { color: inherit; }
.footer-legal { font-size: 14px; opacity: .85; }

/* Section « Landora dans votre poche » (accueil) */
.app-promo {
    width: min(1100px, calc(100% - 32px));
    margin: 60px auto 30px;
    padding: clamp(22px, 4vw, 40px);
    border-radius: 22px;
    background: linear-gradient(135deg, #141414, #0b0b0b);
    border: 1px solid rgba(218, 165, 32, .35);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
    box-sizing: border-box;
    color: #fff;
}
.app-promo h2 { margin: 0 0 8px; font-size: clamp(24px, 3.4vw, 36px); color: goldenrod; }
.app-promo p { margin: 0; max-width: 520px; line-height: 1.6; font-size: 16px; color: #e8e8e8; }
.app-promo .app-badges { margin: 0; padding: 0; justify-content: flex-start; }

/* Bandeau d'information cookies */
.cookie-notice {
    position: fixed;
    left: 16px;
    right: 16px;
    bottom: 16px;
    z-index: 10000;
    max-width: 760px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    border-radius: 14px;
    background: #111;
    color: #eee;
    border: 1px solid rgba(218, 165, 32, .45);
    box-shadow: 0 10px 30px rgba(0, 0, 0, .5);
    font-size: 14px;
    line-height: 1.5;
}
.cookie-notice p { margin: 0; flex: 1; }
.cookie-notice a { color: goldenrod; }
.cookie-notice button {
    flex: 0 0 auto;
    padding: 9px 16px;
    border: 0;
    border-radius: 999px;
    background: goldenrod;
    color: #000;
    font-weight: 700;
    cursor: pointer;
}
@media (max-width: 600px) {
    .app-badge { min-width: 0; flex: 1 1 140px; max-width: 180px; padding: 7px 12px; font-size: 15px; gap: 8px; }
    .app-badge i { font-size: 22px; width: 24px; }
    .cookie-notice { flex-direction: column; align-items: stretch; text-align: left; }
    .app-promo { flex-direction: column; align-items: flex-start; }
}

/* =====================================================================
   ACCUEIL : Top agences / agents / hôtels / motels (zone du visiteur)
   ===================================================================== */
.top-pros { width: min(1300px, calc(100% - 32px)); margin: 40px auto 0; }
.top-pro-section { margin: 0 0 36px; }
.top-pro-section[hidden] { display: none; }
.top-pro-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.top-pro-head h2 { margin: 0; color: #fff; font-size: clamp(22px, 2.6vw, 30px); }
.top-pro-head a { color: goldenrod; text-decoration: none; font-weight: 600; white-space: nowrap; }
.top-pro-row { display: flex; gap: 16px; overflow-x: auto; padding: 4px 2px 12px; scroll-snap-type: x mandatory; scrollbar-width: thin; }
.top-pro-card {
    flex: 0 0 200px;
    scroll-snap-align: start;
    display: flex; flex-direction: column; align-items: center; gap: 6px;
    padding: 20px 14px 16px;
    border-radius: 18px;
    background: #141414;
    border: 1px solid #262626;
    color: #fff; text-decoration: none; text-align: center;
    transition: border-color .2s, transform .2s;
}
.top-pro-card:hover { border-color: goldenrod; transform: translateY(-2px); }
.top-pro-avatar { position: relative; width: 76px; height: 76px; margin-bottom: 6px; }
.top-pro-avatar img, .top-pro-initial {
    width: 76px; height: 76px; border-radius: 50%; object-fit: cover; display: flex;
    align-items: center; justify-content: center; background: #222; color: goldenrod;
    font-size: 30px; font-weight: 800; border: 2px solid rgba(218, 165, 32, .5);
}
.top-pro-check {
    position: absolute; right: -2px; bottom: -2px; width: 24px; height: 24px; border-radius: 50%;
    background: goldenrod; color: #000; font-size: 14px; font-weight: 900;
    display: flex; align-items: center; justify-content: center; border: 2px solid #141414;
}
.top-pro-name { font-weight: 700; font-size: 16px; line-height: 1.3; }
.top-pro-place { font-size: 13px; color: #b5b5b5; }
.top-pro-rating { font-size: 13px; color: goldenrod; }
.top-pro-rating small { color: #8a8a8a; }
.top-pro-badge { margin-top: 2px; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 700; background: rgba(218, 165, 32, .15); color: goldenrod; }
@media (max-width: 600px) { .top-pro-card { flex-basis: 160px; padding: 16px 10px 14px; } }

/* Carte NNEJ Wallet de la grille du compte : cachée tant que le solde n'est pas actif */
[data-wallet-grid-card][hidden] { display: none !important; }
