/*
Theme Name: RentalHive — Je Loue Mon Van
Theme URI: https://jelouemonvan.com
Template: rentalhive
Description: Thème enfant de RentalHive personnalisé pour la marketplace Je loue mon van.
Author: Centralix
Author URI: https://centralix.ca
Version: 1.10.3
Text Domain: rentalhive-jlmv
*/

/* ═══════════════════════════════════════════════════════════════════════
   1. VARIABLES DE MARQUE
   ═══════════════════════════════════════════════════════════════════════ */
:root {
    --jlmv-orange:        #F4A02C;
    --jlmv-orange-dark:   #E8821C;
    --jlmv-orange-darker: #C76A00;
    --jlmv-orange-light:  rgba(244, 160, 44, 0.12);
    --jlmv-orange-border: rgba(244, 160, 44, 0.35);
    --jlmv-ink:           #1a1a1a;
    --jlmv-cream:         #fdfaf5;
    --jlmv-text-muted:    #666;
    --jlmv-text-soft:     #888;
    --jlmv-border:        #e5e0d6;
    --jlmv-shadow-sm:     0 2px 8px rgba(0, 0, 0, 0.04);
    --jlmv-shadow:        0 8px 20px rgba(0, 0, 0, 0.06);
    --jlmv-shadow-lg:     0 16px 40px rgba(0, 0, 0, 0.08);
}

/* ═══════════════════════════════════════════════════════════════════════
   2. TYPOGRAPHIE GLOBALE
   ═══════════════════════════════════════════════════════════════════════ */
body, .hp-page, p {
    color: var(--jlmv-ink);
}
h1, h2, h3, h4, h5, h6,
.hp-listing__title, .hp-vendor__title, .hp-page__title {
    color: var(--jlmv-ink);
    letter-spacing: -0.01em;
}

/* ═══════════════════════════════════════════════════════════════════════
   3. BOUTONS — gradient orange JLMV
   ═══════════════════════════════════════════════════════════════════════ */
.hp-form__button--primary,
.button.alt,
.wp-element-button,
button[type="submit"]:not(.search-submit),
.hp-button--primary,
.hp-link--primary {
    background: linear-gradient(135deg, var(--jlmv-orange) 0%, var(--jlmv-orange-dark) 100%) !important;
    color: var(--jlmv-ink) !important;
    border: 0 !important;
    box-shadow: 0 6px 18px rgba(232, 130, 28, 0.32);
    font-weight: 700;
    letter-spacing: 0.02em;
    transition: transform 0.15s, box-shadow 0.25s, background 0.2s;
}
.hp-form__button--primary:hover,
.button.alt:hover,
.wp-element-button:hover,
.hp-button--primary:hover,
.hp-link--primary:hover {
    box-shadow: 0 10px 26px rgba(232, 130, 28, 0.5);
    transform: translateY(-1px);
    color: var(--jlmv-ink) !important;
}

/* Boutons secondaires : outline orange */
.hp-form__button:not(.hp-form__button--primary),
.hp-button:not(.hp-button--primary),
button.hp-form__button--secondary {
    background: #fff !important;
    color: var(--jlmv-orange-darker) !important;
    border: 1.5px solid var(--jlmv-orange-border) !important;
    font-weight: 600;
}
.hp-form__button:not(.hp-form__button--primary):hover {
    background: var(--jlmv-orange-light) !important;
    border-color: var(--jlmv-orange) !important;
}

/* ═══════════════════════════════════════════════════════════════════════
   4. LIENS / ACCENTS
   ═══════════════════════════════════════════════════════════════════════ */
a {
    color: var(--jlmv-orange-dark);
    transition: color 0.15s;
}
a:hover, a:focus {
    color: var(--jlmv-orange);
}

/* ═══════════════════════════════════════════════════════════════════════
   5. NAVIGATION HEADER
   ═══════════════════════════════════════════════════════════════════════ */
.site-header,
header.site-header {
    background: #fff;
    border-bottom: 1px solid var(--jlmv-border);
    box-shadow: var(--jlmv-shadow-sm);
}
.custom-logo {
    max-height: 56px;
    width: auto;
}
.main-navigation a {
    color: var(--jlmv-ink);
    font-weight: 600;
    transition: color 0.15s;
}
.main-navigation a:hover,
.main-navigation .current-menu-item > a {
    color: var(--jlmv-orange);
}

/* ═══════════════════════════════════════════════════════════════════════
   6. CARTES LISTING / VENDOR (homepage, recherche, catégories)
   ═══════════════════════════════════════════════════════════════════════ */
.hp-listing.hp-listing--view-block,
.hp-vendor.hp-vendor--view-block {
    background: #fff;
    border: 1px solid var(--jlmv-border);
    border-radius: 14px;
    overflow: hidden;
    box-shadow: var(--jlmv-shadow-sm);
    transition: box-shadow 0.25s, transform 0.15s;
}
.hp-listing.hp-listing--view-block:hover,
.hp-vendor.hp-vendor--view-block:hover {
    box-shadow: var(--jlmv-shadow);
    transform: translateY(-2px);
}
.hp-listing__title a,
.hp-vendor__name a {
    color: var(--jlmv-ink);
    font-weight: 700;
}
.hp-listing__title a:hover,
.hp-vendor__name a:hover {
    color: var(--jlmv-orange-dark);
}
.hp-listing__price {
    color: var(--jlmv-orange-darker);
    font-weight: 700;
    font-size: 1.1em;
}
.hp-listing__attribute,
.hp-vendor__attribute {
    color: var(--jlmv-text-muted);
    font-size: 0.9em;
}
.hp-listing__rating-star,
.hp-vendor__rating-star {
    color: var(--jlmv-orange);
}

/* Badge "vedette" / featured */
.hp-listing__featured-badge {
    background: var(--jlmv-orange) !important;
    color: var(--jlmv-ink) !important;
}

/* ═══════════════════════════════════════════════════════════════════════
   7. PAGE HEADER / HERO (category, vendor profile, listing single)
   ═══════════════════════════════════════════════════════════════════════ */
.hp-page__header,
body.hp-vendor.hp-vendor--view-page .hp-page__header,
body.hp-listing-category .hp-page__header {
    background: linear-gradient(135deg, var(--jlmv-ink) 0%, #3d2c14 60%, #4d3618 100%);
    color: #fff;
    padding: 56px 24px;
    margin-bottom: 32px;
}
.hp-page__header h1,
.hp-page__header .hp-page__title {
    color: #fff;
}
.hp-page__header a {
    color: var(--jlmv-orange);
}

/* Hero header pleine largeur sur la page /listing/ — "casse" le max-width:80rem
   du parent .hp-page pour s'étendre edge-to-edge, tout en gardant le contenu
   intérieur (titre + formulaire de recherche) centré et borné. */
body.hp-page--listings-view .hp-page__header,
body.hp-page--listings-view-page .hp-page__header,
body.post-type-archive-hp_listing .hp-page__header {
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    width: 100vw;
    max-width: 100vw;
    padding: 64px 32px 56px;
}
/* Contenu interne du header — centré avec max-width raisonnable */
body.hp-page--listings-view .hp-page__header > *,
body.hp-page--listings-view-page .hp-page__header > *,
body.post-type-archive-hp_listing .hp-page__header > * {
    max-width: 1280px;
    margin-left: auto;
    margin-right: auto;
}
/* Le formulaire de recherche utilise toute la largeur du conteneur interne */
body.hp-page--listings-view .hp-page__header .hp-form,
body.hp-page--listings-view-page .hp-page__header .hp-form,
body.post-type-archive-hp_listing .hp-page__header .hp-form {
    max-width: 1100px;
    margin-left: auto;
    margin-right: auto;
}
@media (max-width: 767.98px) {
    body.hp-page--listings-view .hp-page__header,
    body.hp-page--listings-view-page .hp-page__header,
    body.post-type-archive-hp_listing .hp-page__header {
        padding: 36px 16px 28px;
    }
}

/* ═══════════════════════════════════════════════════════════════════════
   8. FORMULAIRES (recherche, login, register, listing add/edit)
   ═══════════════════════════════════════════════════════════════════════ */
.hp-form input[type="text"],
.hp-form input[type="email"],
.hp-form input[type="tel"],
.hp-form input[type="password"],
.hp-form input[type="number"],
.hp-form input[type="search"],
.hp-form input[type="url"],
.hp-form select,
.hp-form textarea {
    border: 1px solid var(--jlmv-border);
    border-radius: 9px;
    padding: 11px 13px;
    font-size: 15px;
    background: #fafaf7;
    color: var(--jlmv-ink);
    transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
}
.hp-form input::placeholder,
.hp-form textarea::placeholder {
    color: var(--jlmv-text-soft);
    opacity: 1;
}
.hp-form input:focus,
.hp-form select:focus,
.hp-form textarea:focus {
    outline: none;
    border-color: var(--jlmv-orange);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(244, 160, 44, 0.18);
}
.hp-form__label {
    font-weight: 600;
    color: var(--jlmv-ink);
    font-size: 14px;
}

/* ═══════════════════════════════════════════════════════════════════════
   9. DASHBOARD VENDOR (/account/)
   ═══════════════════════════════════════════════════════════════════════ */
body.hp-page--user-account-view,
body.hp-page--vendor-account-view {
    background: var(--jlmv-cream);
}

/* Top stats blocks (Orders / Revenue) */
.hp-stats,
.hp-dashboard__stats {
    background: #fff;
    border: 1px solid var(--jlmv-border);
    border-radius: 14px;
    box-shadow: var(--jlmv-shadow-sm);
}
.hp-stats__value,
.hp-dashboard__stat-value {
    color: var(--jlmv-orange-darker);
    font-weight: 800;
    font-size: 1.5em;
}

/* Sidebar menu account */
.hp-menu--user-account,
.hp-menu--vendor-account {
    background: #fff;
    border: 1px solid var(--jlmv-border);
    border-radius: 14px;
    padding: 12px;
}
.hp-menu--user-account a,
.hp-menu--vendor-account a {
    color: var(--jlmv-ink);
    padding: 10px 14px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
    transition: background 0.15s, color 0.15s;
}
.hp-menu--user-account a:hover,
.hp-menu--user-account .hp-menu__item--current > a,
.hp-menu--vendor-account a:hover {
    background: var(--jlmv-orange-light);
    color: var(--jlmv-orange-darker);
}

/* "List a Property" / "Ajouter un véhicule" CTA — scopé au dashboard pour
   ne pas styler les liens d'autres plugins contenant "listing/add". */
.hp-page--user-account-view a[href*="/submit-listing"],
.hp-page--vendor-account-view a[href*="/submit-listing"],
.hp-listing-submit-button {
    background: linear-gradient(135deg, var(--jlmv-orange) 0%, var(--jlmv-orange-dark) 100%) !important;
    color: var(--jlmv-ink) !important;
    padding: 10px 20px !important;
    border-radius: 10px !important;
    font-weight: 700 !important;
    box-shadow: 0 4px 12px rgba(232, 130, 28, 0.32);
}

/* Dashboard welcome banner (injecté via hivepress/v1/templates/user_account_page/blocks) */
.jlmv-dashboard-welcome {
    background: linear-gradient(135deg, var(--jlmv-ink) 0%, #3d2c14 60%, #4d3618 100%);
    color: #fff;
    border-radius: 16px;
    padding: 28px 32px;
    margin-bottom: 28px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}
.jlmv-dashboard-welcome__inner {
    display: flex; align-items: center; justify-content: space-between;
    gap: 24px; flex-wrap: wrap;
}
.jlmv-dashboard-welcome__text h2 {
    margin: 0 0 6px; color: #fff; font-size: 24px; font-weight: 700;
}
.jlmv-dashboard-welcome__text p {
    margin: 0; color: rgba(255,255,255,0.75); font-size: 14px;
}
.jlmv-dashboard-welcome__cta {
    background: linear-gradient(135deg, var(--jlmv-orange) 0%, var(--jlmv-orange-dark) 100%);
    color: var(--jlmv-ink) !important;
    font-weight: 700; padding: 12px 22px; border-radius: 12px;
    text-decoration: none !important; display: inline-block;
    box-shadow: 0 6px 18px rgba(232, 130, 28, 0.4);
    transition: transform 0.15s, box-shadow 0.25s;
}
.jlmv-dashboard-welcome__cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 24px rgba(232, 130, 28, 0.55);
    color: var(--jlmv-ink) !important;
}
@media (max-width: 640px) {
    .jlmv-dashboard-welcome { padding: 22px 18px; }
    .jlmv-dashboard-welcome__text h2 { font-size: 20px; }
}

/* ═══════════════════════════════════════════════════════════════════════
   10. FOOTER
   ═══════════════════════════════════════════════════════════════════════ */
.site-footer,
footer.site-footer {
    background: var(--jlmv-ink);
    color: rgba(255, 255, 255, 0.7);
    padding: 48px 24px 24px;
}
.site-footer a {
    color: rgba(255, 255, 255, 0.85);
}
.site-footer a:hover {
    color: var(--jlmv-orange);
}
.site-footer h3, .site-footer h4 {
    color: #fff;
}
.site-footer .footer-bottom,
.site-footer .copyright {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 16px;
    margin-top: 24px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
}
/* Footer HivePress (.footer-navbar) : le thème parent (HiveTheme) force les liens
   du menu + le copyright en rgba(15,23,39,.45) via un sélecteur plus spécifique
   (.footer-navbar__menu ul li a = 0,3,1), ce qui les rend invisibles (texte navy
   sur le fond foncé --jlmv-ink), visibles seulement au survol (orange).
   On rétablit une couleur claire avec une spécificité supérieure (0,4,1). */
.site-footer .footer-navbar__menu ul li a,
.site-footer .footer-navbar__copyright {
    color: rgba(255, 255, 255, 0.8);
}
.site-footer .footer-navbar__menu ul li a:hover {
    color: var(--jlmv-orange);
}

/* ═══════════════════════════════════════════════════════════════════════
   11. CATÉGORIES (Van / Pickup / Camion cube)
   ═══════════════════════════════════════════════════════════════════════ */
.hp-listing-categories .hp-listing-category {
    background: #fff;
    border: 1px solid var(--jlmv-border);
    border-radius: 14px;
    overflow: hidden;
    transition: transform 0.15s, box-shadow 0.25s;
}
.hp-listing-categories .hp-listing-category:hover {
    transform: translateY(-3px);
    box-shadow: var(--jlmv-shadow);
}
.hp-listing-category__title {
    color: var(--jlmv-ink);
    font-weight: 700;
}

/* ═══════════════════════════════════════════════════════════════════════
   12. WOOCOMMERCE — masquer ce qui n'a pas de sens pour van rental
   ═══════════════════════════════════════════════════════════════════════ */
/* La marketplace HivePress utilise WC en backend pour les paiements,
   mais on ne veut pas voir les pages WC publiques (Boutique, Commande, Panier). */
.menu-item-shop,
.menu-item-cart,
.menu-item-checkout {
    display: none !important;
}

/* ═══════════════════════════════════════════════════════════════════════
   13. RESPONSIVE
   ═══════════════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
    .hp-page__header {
        padding: 36px 16px;
    }
    .custom-logo {
        max-height: 44px;
    }
}

/* ═══════════════════════════════════════════════════════════════════════
   14. PAGE LISTING — DESIGN STYLE AIRBNB (desktop + mobile)
   ═══════════════════════════════════════════════════════════════════════ */

/* --- 14.1 Container global de la page /listing/ --- */
body.hp-page--listings-view .hp-page__content,
body.hp-page--listings-view-page .hp-page__content {
    background: var(--jlmv-cream);
}
body.hp-page--listings-view .hp-page__topbar,
body.hp-page--listings-view-page .hp-page__topbar {
    background: #fff;
    border: 1px solid var(--jlmv-border);
    border-radius: 14px;
    padding: 14px 20px;
    box-shadow: var(--jlmv-shadow-sm);
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 24px;
}
body.hp-page--listings-view .hp-results__count,
body.hp-page--listings-view-page .hp-results__count {
    font-weight: 700;
    color: var(--jlmv-ink);
    font-size: 15px;
}
body.hp-page--listings-view .hp-form--listing-sort,
body.hp-page--listings-view-page .hp-form--listing-sort,
.hp-form--pivot {
    margin: 0;
}
.hp-form--pivot select {
    border-radius: 999px !important;
    padding: 8px 36px 8px 16px !important;
    background: #fff !important;
    border: 1.5px solid var(--jlmv-border) !important;
    font-weight: 600;
    cursor: pointer;
    font-size: 14px;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.hp-form--pivot select:hover,
.hp-form--pivot select:focus {
    border-color: var(--jlmv-orange) !important;
    box-shadow: 0 0 0 3px rgba(244, 160, 44, 0.15);
}

/* --- 14.2 Sidebar filtres (desktop) — design Airbnb épuré --- */
.hp-widget--listing-filter {
    background: #fff;
    border: 1px solid var(--jlmv-border);
    border-radius: 16px;
    padding: 22px 20px;
    box-shadow: var(--jlmv-shadow-sm);
}
.hp-widget--listing-filter .hp-widget__title,
.hp-widget--listing-filter h3 {
    font-size: 17px;
    font-weight: 700;
    color: var(--jlmv-ink);
    margin: 0 0 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--jlmv-border);
}
.hp-widget--listing-filter .hp-form__field {
    margin-bottom: 14px;
}
.hp-widget--listing-filter .hp-form__label {
    font-size: 13px;
    font-weight: 600;
    color: var(--jlmv-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-bottom: 6px;
    display: block;
}

/* --- 14.3 Grille des cartes listing --- */
.hp-listings.hp-listings--view-block .hp-row {
    margin: 0 -10px;
}
.hp-listings.hp-listings--view-block .hp-row > [class*="hp-col"] {
    padding: 0 10px;
}
.hp-listing--view-block:not(:last-child) {
    margin-bottom: 24px !important;
}

/* --- 14.4 Carte listing — style Airbnb (image dominante, SANS bordure ni shadow) --- */
.hp-listing.hp-listing--view-block,
body.hp-page--listings-view .hp-listing--view-block,
body.hp-page--listings-view-page .hp-listing--view-block {
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    overflow: visible !important;
    box-shadow: none !important;
    transition: transform 0.2s ease;
}
.hp-listing.hp-listing--view-block:hover {
    transform: translateY(-2px);
    box-shadow: none !important;
}
.hp-listing--view-block .hp-listing__header {
    margin-bottom: 12px !important;
    position: relative;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    background: #f0ede5;
    border-radius: 16px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}
.hp-listing--view-block .hp-listing__image img,
.hp-listing--view-block .hp-listing__image-slider img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}
.hp-listing.hp-listing--view-block:hover .hp-listing__image img {
    transform: scale(1.04);
}
.hp-listing--view-block .hp-listing__content {
    padding: 0 !important;
    margin-bottom: 0 !important;
}
.hp-listing--view-block .hp-listing__title {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.35;
    margin-bottom: 4px !important;
}
.hp-listing--view-block .hp-listing__title a {
    color: var(--jlmv-ink);
    text-decoration: none;
}
.hp-listing--view-block .hp-listing__details--primary {
    color: var(--jlmv-text-muted);
    font-size: 13px;
    margin-bottom: 6px !important;
}
.hp-listing--view-block .hp-listing__details--primary,
.hp-listing--view-block .hp-listing__attributes--secondary,
.hp-listing--view-block .hp-listing__attributes--ternary {
    font-size: 13px;
    color: var(--jlmv-text-soft) !important;
    margin-bottom: 2px !important;
    padding: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}
/* Forcer chaque attribut secondaire en LIGNE PROPRE "Label : Value"
   (override le hp-row/hp-col grid du parent qui les fait wrap horizontalement) */
.hp-listing--view-block .hp-listing__attributes--secondary,
.hp-listing--view-block .hp-listing__attributes--ternary {
    display: block !important;
    margin-top: 8px !important;
}
.hp-listing--view-block .hp-listing__attributes--secondary .hp-row,
.hp-listing--view-block .hp-listing__attributes--ternary .hp-row {
    display: block !important;
    margin: 0 !important;
}
.hp-listing--view-block .hp-listing__attributes--secondary [class*="hp-col"],
.hp-listing--view-block .hp-listing__attributes--ternary [class*="hp-col"] {
    flex: 1 1 100% !important;
    max-width: 100% !important;
    padding: 0 !important;
}
.hp-listing--view-block .hp-listing__attributes--secondary .hp-listing__attribute,
.hp-listing--view-block .hp-listing__attributes--ternary .hp-listing__attribute {
    display: flex !important;
    align-items: baseline;
    gap: 4px;
    font-size: 13px !important;
    line-height: 1.5;
    color: var(--jlmv-ink) !important;
    padding: 0 !important;
    margin: 0 0 3px 0 !important;
    background: transparent !important;
    border: 0 !important;
    text-align: left !important;
}
/* Cacher les icônes HivePress dans la liste secondaire (look épuré "Label : Value") */
.hp-listing--view-block .hp-listing__attributes--secondary .hp-listing__attribute i,
.hp-listing--view-block .hp-listing__attributes--ternary .hp-listing__attribute i,
.hp-listing--view-block .hp-listing__attributes--primary .hp-listing__attribute i {
    display: none !important;
}

/* Ligne d'icônes Services (style Airbnb) — rendue par le mu-plugin
   cx-jlmv-service-icons.php. Vert = disponible, gris = non disponible. */
.jlmv-services-row {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 6px 0 8px;
    flex-wrap: wrap;
}
.jlmv-service {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    font-size: 17px;
    line-height: 1;
    background: #f3f1ea;
    cursor: help;
    transition: transform 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
    position: relative;
    user-select: none;
}
.jlmv-service--on {
    background: rgba(45, 164, 78, 0.14);
    box-shadow: inset 0 0 0 1.5px rgba(45, 164, 78, 0.5);
    filter: none;
}
.jlmv-service--off {
    filter: grayscale(1) opacity(0.4);
}
.jlmv-service:hover,
.jlmv-service:focus {
    transform: scale(1.12);
    z-index: 2;
    outline: none;
}
.jlmv-service--on:hover {
    background: rgba(45, 164, 78, 0.22);
    box-shadow: inset 0 0 0 1.5px rgba(45, 164, 78, 0.7), 0 2px 8px rgba(45, 164, 78, 0.2);
}
.jlmv-service--off:hover {
    filter: grayscale(0.5) opacity(0.7);
}

/* Tooltip custom CSS — affiche data-tooltip au hover/focus, instantané */
.jlmv-service[data-tooltip] {
    position: relative;
}
.jlmv-service[data-tooltip]::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%) translateY(4px);
    background: var(--jlmv-ink);
    color: #fff;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.3;
    white-space: nowrap;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.15s ease, transform 0.15s ease;
    z-index: 10;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.18);
}
.jlmv-service[data-tooltip]::before {
    content: "";
    position: absolute;
    bottom: calc(100% + 2px);
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: var(--jlmv-ink);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.15s ease;
    z-index: 10;
}
.jlmv-service[data-tooltip]:hover::after,
.jlmv-service[data-tooltip]:focus::after {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}
.jlmv-service[data-tooltip]:hover::before,
.jlmv-service[data-tooltip]:focus::before {
    opacity: 1;
}

/* Période de location (rate-period) */
.hp-listing--view-block .hp-listing__attribute--hp-listing-rate-period,
.hp-listing--view-block .hp-listing__attribute--rate-period {
    color: var(--jlmv-text-muted) !important;
    font-weight: 500 !important;
    font-size: 13px !important;
}

.hp-listing--view-block .hp-listing__footer {
    padding: 10px 0 0 !important;
    border-top: 0 !important;
    margin: 0 !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    gap: 12px;
}
.hp-listing--view-block .hp-listing__attributes--primary {
    font-weight: 700;
    color: var(--jlmv-ink) !important;
    font-size: 16px;
    margin: 0 !important;
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.hp-listing--view-block .hp-listing__attributes--primary .hp-listing__attribute {
    display: inline !important;
    background: transparent !important;
    padding: 0 !important;
    color: var(--jlmv-ink) !important;
}
/* Note: le suffixe "/h" est maintenant intégré au display_format de l'attribut
   Tarif (post_id 98) via meta hp_display_format = "%label% : %value% $/h".
   Pas de pseudo-element ici pour éviter de polluer les autres attributs primaires. */
.hp-listing--view-block .hp-listing__actions--primary a,
.hp-listing--view-block .hp-listing__actions--primary button {
    width: 36px; height: 36px;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 50%;
    background: rgba(255,255,255,0.92);
    color: var(--jlmv-orange-darker);
    transition: background 0.15s, transform 0.15s;
}
.hp-listing--view-block .hp-listing__actions--primary a:hover {
    background: #fff;
    transform: scale(1.08);
}

/* Badge "vedette" — position absolue sur l'image */
.hp-listing--view-block .hp-listing__featured-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 2;
    padding: 5px 12px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

/* Bouton "favoris" (cœur) HivePress — position sur image, style Airbnb */
.hp-listing--view-block .hp-listing-favorite-toggle,
.hp-listing--view-block .hp-listing__header .hp-button {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 3;
    width: 36px; height: 36px;
    display: inline-flex; align-items: center; justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.95) !important;
    color: var(--jlmv-ink) !important;
    border: 0 !important;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
    transition: transform 0.15s, background 0.15s;
}
.hp-listing--view-block .hp-listing-favorite-toggle:hover {
    transform: scale(1.1);
    background: #fff !important;
    color: var(--jlmv-orange-dark) !important;
}

/* --- 14.5 Mobile : filtre plein-écran + sticky filter/sort bar --- */
@media (max-width: 767.98px) {

    /* Topbar (résultats + tri) — pas sticky par défaut, on remplace par sticky bar custom */
    body.hp-page--listings-view .hp-page__topbar,
    body.hp-page--listings-view-page .hp-page__topbar {
        padding: 12px 14px;
        border-radius: 12px;
        position: sticky;
        top: 0;
        z-index: 50;
        background: rgba(255, 255, 255, 0.96);
        backdrop-filter: saturate(180%) blur(8px);
        -webkit-backdrop-filter: saturate(180%) blur(8px);
        border-radius: 0;
        margin: 0 -16px 16px;
        border-left: 0;
        border-right: 0;
        border-top: 0;
        box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    }
    body.hp-page--listings-view .hp-results__count,
    body.hp-page--listings-view-page .hp-results__count {
        font-size: 14px;
    }
    .hp-form--pivot select {
        font-size: 13px;
        padding: 7px 30px 7px 14px !important;
    }

    /* Bouton "Filtre" dans le header — devient une pill brandée */
    .hp-page__header .hp-listing-filter-link,
    .hp-page__header a[href="#listing_filter_modal"] {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        background: var(--jlmv-orange) !important;
        color: var(--jlmv-ink) !important;
        padding: 10px 18px;
        border-radius: 999px;
        font-weight: 700;
        text-decoration: none;
        box-shadow: 0 6px 18px rgba(232, 130, 28, 0.35);
        margin-top: 12px;
    }
    .hp-page__header .hp-listing-filter-link::before {
        content: "⚙";
        font-size: 14px;
    }

    /* Modale filtre — PLEIN ÉCRAN (override fancybox/HivePress default 380px) */
    .fancybox-content:has(.hp-form--listing-filter),
    .fancybox-slide--html .fancybox-content:has(.hp-form--listing-filter),
    .hp-modal--mobile .fancybox-content,
    body .fancybox-content #listing_filter_modal,
    body #listing_filter_modal.fancybox-content {
        width: 100vw !important;
        max-width: 100vw !important;
        height: 100vh !important;
        max-height: 100vh !important;
        margin: 0 !important;
        padding: 0 !important;
        border-radius: 0 !important;
        overflow: hidden !important;
        display: flex !important;
        flex-direction: column !important;
    }
    /* Le contenu interne de la modale scrolle */
    #listing_filter_modal .hp-form,
    .fancybox-content .hp-form--listing-filter {
        flex: 1 1 auto;
        overflow-y: auto;
        padding: 16px 20px 100px 20px;
        -webkit-overflow-scrolling: touch;
    }
    /* Titre de la modale — header sticky */
    .fancybox-content .hp-modal__title,
    #listing_filter_modal .hp-modal__title,
    #listing_filter_modal > h3:first-child {
        position: sticky;
        top: 0;
        z-index: 2;
        margin: 0 !important;
        padding: 16px 20px;
        background: #fff;
        border-bottom: 1px solid var(--jlmv-border);
        font-size: 18px;
        font-weight: 700;
        color: var(--jlmv-ink);
    }
    /* Bouton "Appliquer" — sticky en bas */
    #listing_filter_modal .hp-form__button,
    .fancybox-content .hp-form--listing-filter .hp-form__button,
    .fancybox-content .hp-form--listing-filter button[type="submit"] {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        z-index: 10;
        width: 100%;
        border-radius: 0 !important;
        padding: 16px !important;
        font-size: 16px !important;
        background: linear-gradient(135deg, var(--jlmv-orange) 0%, var(--jlmv-orange-dark) 100%) !important;
        color: var(--jlmv-ink) !important;
        border: 0 !important;
        box-shadow: 0 -4px 16px rgba(0,0,0,0.08);
    }
    /* Bouton X de fermeture fancybox — bien visible */
    .fancybox-slide--html .fancybox-button.fancybox-close-small {
        top: 8px;
        right: 8px;
        background: rgba(255,255,255,0.95);
        border-radius: 50%;
        width: 38px;
        height: 38px;
        color: var(--jlmv-ink);
        box-shadow: 0 2px 8px rgba(0,0,0,0.12);
    }

    /* Grille : 1 colonne sur petits téléphones (< 600px), 2 cols sinon (déjà géré par HP) */
    .hp-listings.hp-listings--view-block .hp-row > [class*="hp-col"] {
        flex-basis: 100%;
        max-width: 100%;
    }
    .hp-listing--view-block:not(:last-child) {
        margin-bottom: 18px !important;
    }
    .hp-listing--view-block .hp-listing__header {
        aspect-ratio: 16 / 10;
    }
    .hp-listing--view-block .hp-listing__title { font-size: 17px; }
    .hp-listing--view-block .hp-listing__attributes--primary { font-size: 17px; }

    /* Search form dans le hero header — full-width stack */
    .hp-page__header .hp-form--listing-search .hp-form__field {
        margin-bottom: 10px;
    }
    .hp-page__header .hp-form--listing-search .hp-form__field input,
    .hp-page__header .hp-form--listing-search .hp-form__field select {
        font-size: 16px; /* évite zoom iOS */
    }
}

/* --- 14.6 Petits téléphones < 600px : 1 colonne forcée --- */
@media (min-width: 600px) and (max-width: 767.98px) {
    .hp-listings.hp-listings--view-block .hp-row > [class*="hp-col"] {
        flex-basis: 50%;
        max-width: 50%;
    }
    .hp-listing--view-block .hp-listing__header {
        aspect-ratio: 4 / 3;
    }
}
