/* ============================================================
   Carnet de Voyage — front.css
   Mobile-first · Typographie soignée · Palette thème dynamique
   ============================================================ */

/* ── Fonts (chargées via le template) ─────────────────────── */
/* Playfair Display (titres) + DM Sans (corps) */

/* ── Variables par défaut (surchargées par PHP inline) ─────── */
:root {
    --cv-color:       #2A7A6F;
    --cv-color-d:     #1E5C53;
    --cv-color-l:     #E6F4F1;
    --cv-color-xl:    #F0FAF8;
    --cv-off-white:   #FAFAF8;
    --cv-gray-100:    #F3F4F6;
    --cv-gray-200:    #E5E7EB;
    --cv-gray-400:    #9CA3AF;
    --cv-gray-500:    #6B7280;
    --cv-gray-700:    #374151;
    --cv-gray-900:    #111827;
    --cv-radius:      14px;
    --cv-radius-sm:   8px;
    --cv-font-title:  'Playfair Display', Georgia, 'Times New Roman', serif;
    --cv-font-body:   'DM Sans', system-ui, -apple-system, sans-serif;
    --cv-nav-h:       0px; /* sera mis à jour via JS si nécessaire */
}

/* ── Reset minimal ──────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

.cv-body {
    margin: 0;
    font-family: var(--cv-font-body);
    font-size: 16px;
    line-height: 1.6;
    color: var(--cv-gray-700);
    background: var(--cv-off-white);
    -webkit-font-smoothing: antialiased;
}

.cv-container {
    max-width: 720px;
    margin: 0 auto;
    padding: 0 18px;
}

/* ══════════════════════════════════════════════════════════════
   HERO
══════════════════════════════════════════════════════════════ */
.cv-hero {
    position: relative;
    height: 64vw;
    min-height: 260px;
    max-height: 480px;
    background: var(--cv-color) var(--hero-bg, none) center / cover no-repeat;
    display: flex;
    align-items: flex-end;
    overflow: hidden;
}

.cv-hero__overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(0,0,0,.78) 0%,
        rgba(0,0,0,.30) 45%,
        rgba(0,0,0,.05) 100%
    );
    display: flex;
    align-items: flex-end;
    width: 100%;
}

.cv-hero__content {
    width: 100%;
    max-width: 720px;
    margin: 0 auto;
    padding: 24px 18px 28px;
}

.cv-hero__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-family: var(--cv-font-body);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .8px;
    text-transform: uppercase;
    color: rgba(255,255,255,.7);
    margin-bottom: 8px;
}

.cv-hero__title {
    font-family: var(--cv-font-title);
    font-size: clamp(24px, 6vw, 42px);
    font-weight: 700;
    color: #fff;
    margin: 0 0 14px;
    line-height: 1.15;
    text-shadow: 0 1px 4px rgba(0,0,0,.25);
}

.cv-hero__pills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.cv-pill {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    background: rgba(255,255,255,.16);
    backdrop-filter: blur(6px);
    color: rgba(255,255,255,.92);
    border: 1px solid rgba(255,255,255,.2);
}

/* ══════════════════════════════════════════════════════════════
   DESCRIPTION INTRO
══════════════════════════════════════════════════════════════ */
.cv-intro {
    background: #fff;
    border-bottom: 1px solid var(--cv-gray-200);
}
.cv-intro__text {
    padding: 20px 0;
    margin: 0;
    font-size: 15px;
    line-height: 1.7;
    color: var(--cv-gray-700);
    font-style: italic;
}

/* ══════════════════════════════════════════════════════════════
   NAV STICKY
══════════════════════════════════════════════════════════════ */
.cv-nav {
    position: sticky;
    top: 0;
    z-index: 200;
    background: #fff;
    border-bottom: 1px solid var(--cv-gray-200);
    transition: box-shadow .25s;
}
.cv-nav.cv-nav--shadow { box-shadow: 0 2px 12px rgba(0,0,0,.08); }

.cv-nav .cv-container { padding-top: 0; padding-bottom: 0; }

/* Onglets jours */
.cv-nav__days {
    display: flex;
    gap: 2px;
    padding: 10px 0 4px;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}
.cv-nav__days::-webkit-scrollbar { display: none; }

.cv-day-tab {
    flex-shrink: 0;
    padding: 6px 16px;
    border: none;
    border-radius: 20px;
    font-family: var(--cv-font-body);
    font-size: 13px;
    font-weight: 600;
    color: var(--cv-gray-500);
    background: transparent;
    cursor: pointer;
    white-space: nowrap;
    transition: background .15s, color .15s;
}
.cv-day-tab:hover { background: var(--cv-gray-100); color: var(--cv-gray-900); }
.cv-day-tab.is-active {
    background: var(--cv-color);
    color: #fff;
}

/* Filtres moment */
.cv-nav__moments {
    display: flex;
    gap: 6px;
    padding: 6px 0 10px;
    overflow-x: auto;
    scrollbar-width: none;
}
.cv-nav__moments::-webkit-scrollbar { display: none; }

.cv-moment-btn {
    flex-shrink: 0;
    padding: 4px 13px;
    border: 1px solid var(--cv-gray-200);
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    color: var(--cv-gray-500);
    background: transparent;
    cursor: pointer;
    white-space: nowrap;
    transition: all .15s;
}
.cv-moment-btn:hover { border-color: var(--cv-color); color: var(--cv-color); }
.cv-moment-btn.is-active {
    background: var(--cv-color-l);
    border-color: var(--cv-color);
    color: var(--cv-color-d);
}

/* ══════════════════════════════════════════════════════════════
   MAIN — ÉTAPES
══════════════════════════════════════════════════════════════ */
.cv-main { padding: 28px 0 56px; }

.cv-empty-msg {
    text-align: center;
    padding: 64px 0;
    color: var(--cv-gray-400);
    font-style: italic;
}

/* ── Section jour ── */
.cv-jour-section { margin-bottom: 36px; }

.cv-jour-heading {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 18px;
}
.cv-jour-heading::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--cv-gray-200);
}

.cv-jour-badge {
    font-family: var(--cv-font-body);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: .7px;
    text-transform: uppercase;
    color: #fff;
    background: var(--cv-color);
    padding: 5px 14px;
    border-radius: 20px;
    white-space: nowrap;
}

/* ── Bloc moment ── */
.cv-moment-section { margin-bottom: 6px; }

.cv-moment-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .6px;
    color: var(--cv-gray-400);
    margin-bottom: 10px;
    padding-left: 2px;
}

/* ══════════════════════════════════════════════════════════════
   CARTE ÉTAPE
══════════════════════════════════════════════════════════════ */
.cv-etape-card {
    background: #fff;
    border-radius: var(--cv-radius);
    overflow: hidden;
    margin-bottom: 16px;
    box-shadow: 0 1px 3px rgba(0,0,0,.07), 0 1px 2px rgba(0,0,0,.05);
    transition: box-shadow .22s, transform .22s;
}
.cv-etape-card:hover {
    box-shadow: 0 6px 18px rgba(0,0,0,.10);
    transform: translateY(-1px);
}
.cv-etape-card.cv-highlight {
    box-shadow: 0 0 0 3px var(--cv-color), 0 6px 18px rgba(0,0,0,.10);
}

/* ── Photos slider ── */
.cv-card__photos {
    position: relative;
    height: 220px;
    background: var(--cv-gray-100);
    overflow: hidden;
    cursor: pointer;
}

.cv-card__photo {
    position: absolute;
    inset: 0;
    background: center / cover no-repeat;
    opacity: 0;
    transition: opacity .35s ease;
}
.cv-card__photo.is-active { opacity: 1; }

/* Navigation photo */
.cv-photo-ctrl {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 6px;
    pointer-events: none;
}
.cv-photo-arrow {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(255,255,255,.82);
    backdrop-filter: blur(4px);
    border: none;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: all;
    transition: background .15s, transform .15s;
    box-shadow: 0 1px 4px rgba(0,0,0,.15);
}
.cv-photo-arrow:hover { background: #fff; transform: scale(1.05); }

.cv-photo-dots {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 5px;
}
.cv-photo-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(255,255,255,.5);
    border: none;
    cursor: pointer;
    padding: 0;
    transition: background .2s, transform .2s;
}
.cv-photo-dot.is-active { background: #fff; transform: scale(1.35); }

.cv-photo-expand {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 32px;
    height: 32px;
    border-radius: 7px;
    background: rgba(0,0,0,.38);
    backdrop-filter: blur(4px);
    border: none;
    color: #fff;
    font-size: 15px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .15s;
}
.cv-photo-expand:hover { background: rgba(0,0,0,.55); }

/* ── Corps de la carte ── */
.cv-card__body { padding: 16px 18px 18px; }

.cv-card__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 10px;
}

.cv-tag {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 3px 9px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .2px;
}
.cv-tag--visite   { background: #EDE9FE; color: #5B21B6; }
.cv-tag--repas    { background: #FEF3C7; color: #92400E; }
.cv-tag--logement { background: #DBEAFE; color: #1E40AF; }
.cv-tag--trajet   { background: #D1FAE5; color: #065F46; }
.cv-tag--activite { background: #FFE4E6; color: #9F1239; }
.cv-tag--libre    { background: #ECFDF5; color: #065F46; }
.cv-tag--duree    { background: var(--cv-gray-100); color: var(--cv-gray-500); }

.cv-card__title {
    font-family: var(--cv-font-title);
    font-size: 19px;
    font-weight: 700;
    color: var(--cv-gray-900);
    margin: 0 0 10px;
    line-height: 1.2;
}

.cv-card__desc {
    font-size: 14px;
    line-height: 1.65;
    color: var(--cv-gray-700);
    margin-bottom: 12px;
}
.cv-card__desc p { margin: 0 0 6px; }

.cv-card__location {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    font-size: 13px;
    color: var(--cv-gray-500);
    margin-bottom: 10px;
}
.cv-card__location svg { flex-shrink: 0; margin-top: 2px; }
.cv-location-link {
    color: var(--cv-color);
    text-decoration: none;
    font-weight: 600;
}
.cv-location-link:hover { text-decoration: underline; }

.cv-card__ext-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    font-weight: 600;
    color: var(--cv-color);
    text-decoration: none;
    border-bottom: 2px solid var(--cv-color-l);
    transition: border-color .15s;
    padding-bottom: 1px;
}
.cv-card__ext-link:hover { border-color: var(--cv-color); }

/* ══════════════════════════════════════════════════════════════
   SECTION CARTE
══════════════════════════════════════════════════════════════ */
.cv-map-section {
    background: #fff;
    border-top: 1px solid var(--cv-gray-200);
    padding: 0 0 32px;
}

.cv-map-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 90%;
    max-width: 720px;
    margin: 0 auto;
    padding: 18px 0 14px;
    background: none;
    border: none;
    font-family: var(--cv-font-body);
    font-size: 15px;
    font-weight: 700;
    color: var(--cv-gray-900);
    cursor: pointer;
    letter-spacing: .2px;
}
.cv-map-toggle svg { flex-shrink: 0; }
.cv-toggle-chevron { transition: transform .3s ease; color: var(--cv-gray-400); }
.cv-map-toggle[aria-expanded="true"] .cv-toggle-chevron { transform: rotate(180deg); }

.cv-map-wrap {
    overflow: hidden;
    max-height: 0;
    transition: max-height .45s cubic-bezier(.4,0,.2,1);
    width: 90%;
    margin: 0 auto;
    border-radius: var(--cv-radius-sm);
}
.cv-map-wrap.is-open { max-height: 480px; }

.cv-map-el {
    height: 420px;
    border-radius: var(--cv-radius-sm);
    overflow: hidden;
}

.cv-map-popup strong { display: block; font-size: 13px; margin-bottom: 2px; }
.cv-map-popup small  { color: var(--cv-gray-500); font-size: 11px; }

/* ── Marqueurs Leaflet numérotés (frontend) ── */
.cv-marker-wrap {
    display: inline-flex; flex-direction: column; align-items: center;
    filter: drop-shadow(0 2px 5px rgba(0,0,0,.35));
}
.cv-marker-n {
    width: 30px; height: 30px;
    border-radius: 50%;
    border: 3px solid #fff; /* overridden inline */
    display: flex; align-items: center; justify-content: center;
    font-size: 13px; font-weight: 900; color: #fff;
    font-family: var(--cv-font-body);
}
.cv-marker-n-tip {
    width: 0; height: 0;
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-top: 8px solid #000; /* overridden inline */
    margin-top: -1px;
}

/* ══════════════════════════════════════════════════════════════
   LIGHTBOX
══════════════════════════════════════════════════════════════ */
.cv-lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.94);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cv-lightbox__img-wrap {
    max-width: 92vw;
    max-height: 88vh;
    display: flex;
    align-items: center;
    justify-content: center;
}
.cv-lightbox__img {
    max-width: 100%;
    max-height: 88vh;
    object-fit: contain;
    border-radius: 6px;
    user-select: none;
}

.cv-lightbox__close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: rgba(255,255,255,.12);
    border: none;
    border-radius: 50%;
    width: 42px;
    height: 42px;
    font-size: 22px;
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .15s;
}
.cv-lightbox__close:hover { background: rgba(255,255,255,.22); }

.cv-lightbox__prev,
.cv-lightbox__next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,.10);
    border: none;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    font-size: 26px;
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background .15s;
}
.cv-lightbox__prev { left: 12px; }
.cv-lightbox__next { right: 12px; }
.cv-lightbox__prev:hover,
.cv-lightbox__next:hover { background: rgba(255,255,255,.22); }

.cv-lightbox__counter {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 13px;
    color: rgba(255,255,255,.6);
    font-family: var(--cv-font-body);
}

/* ══════════════════════════════════════════════════════════════
   SHORTCODE LISTE (page /carnets/)
══════════════════════════════════════════════════════════════ */
.cv-liste {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 20px;
    padding: 24px 0;
}
.cv-liste__item {
    display: block;
    background: #fff;
    border-radius: var(--cv-radius);
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    box-shadow: 0 1px 3px rgba(0,0,0,.08);
    transition: box-shadow .2s, transform .2s;
}
.cv-liste__item:hover { box-shadow: 0 6px 18px rgba(0,0,0,.10); transform: translateY(-2px); }
.cv-liste__cover { height: 165px; background: var(--cv-color) center / cover no-repeat; }
.cv-liste__body { padding: 14px 16px; }
.cv-liste__title { font-family: var(--cv-font-title); font-size: 16px; font-weight: 700; color: var(--cv-gray-900); margin: 0 0 4px; }
.cv-liste__dest  { font-size: 13px; color: var(--cv-gray-500); margin: 0 0 4px; }
.cv-liste__meta  { font-size: 12px; color: var(--cv-gray-400); margin: 0; }

/* ══════════════════════════════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════════════════════════════ */
@media (min-width: 560px) {
    .cv-hero { height: 46vw; min-height: 280px; }
    .cv-card__photos { height: 255px; }
    .cv-hero__title { font-size: clamp(28px, 5.5vw, 42px); }
}

@media (min-width: 768px) {
    .cv-hero { height: 380px; max-height: 520px; }
    .cv-hero__content { padding: 32px 24px 36px; }
    .cv-container { padding: 0 24px; }
    .cv-card__photos { height: 300px; }
    .cv-map-wrap.is-open { max-height: 520px; }
    .cv-map-el { height: 480px; }
    .cv-card__title { font-size: 21px; }
}

/* ══════════════════════════════════════════════════════════════
   BOUTON PDF / IMPRIMER
══════════════════════════════════════════════════════════════ */
.cv-pill--btn {
    background: rgba(255,255,255,.22) !important;
    border: 1px solid rgba(255,255,255,.4) !important;
    cursor: pointer;
    font-family: var(--cv-font-body);
    font-size: 12px;
    gap: 5px;
    transition: background .2s;
}
.cv-pill--btn:hover { background: rgba(255,255,255,.35) !important; }

/* Bouton flottant bas-droite */
.cv-fab-print {
    position: fixed;
    bottom: 28px;
    right: 28px;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: var(--cv-color);
    color: #fff;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(0,0,0,.25);
    z-index: 500;
    transition: transform .2s, box-shadow .2s;
}
.cv-fab-print:hover { transform: scale(1.08); box-shadow: 0 6px 20px rgba(0,0,0,.3); }

/* ══════════════════════════════════════════════════════════════
   STYLES D'IMPRESSION  @media print
══════════════════════════════════════════════════════════════ */
@media print {

    /* Masquer tout ce qui n'a pas sa place dans le PDF */
    .cv-nav,
    .cv-map-section,
    .cv-lightbox,
    .cv-photo-expand,
    .cv-photo-ctrl,
    .cv-photo-dots,
    .cv-fab-print,
    .cv-no-print,
    .cv-card__ext-link::after { display: none !important; }

    /* Fond blanc, reset */
    .cv-body { background: #fff !important; font-size: 11pt; }

    /* ── En-tête du PDF ── */
    .cv-hero {
        height: auto !important;
        min-height: 0 !important;
        background-color: var(--cv-color) !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
        page-break-after: avoid;
    }
    .cv-hero__content { padding: 24pt 20pt !important; }
    .cv-hero__title   { font-size: 22pt !important; }
    .cv-hero__eyebrow { font-size: 10pt !important; }
    .cv-pill { font-size: 9pt !important; padding: 2pt 8pt !important; }
    .cv-pill--btn { display: none !important; }

    /* ── Introduction ── */
    .cv-intro__text { font-size: 10pt; font-style: italic; }

    /* ── Forcer l'affichage de toutes les étapes ── */
    .cv-jour-section,
    .cv-moment-section { display: block !important; }

    /* ── Saut de page entre les jours ── */
    .cv-jour-section {
        page-break-before: always;
        break-before: page;
    }
    .cv-jour-section:first-of-type {
        page-break-before: avoid;
        break-before: avoid;
    }

    /* ── Titres de jour ── */
    .cv-jour-heading  { margin-bottom: 10pt; }
    .cv-jour-badge    {
        background: var(--cv-color) !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
        font-size: 10pt; padding: 3pt 12pt;
    }
    .cv-moment-label  { font-size: 9pt; color: #666 !important; margin-bottom: 6pt; }

    /* ── Carte étape ── */
    .cv-etape-card {
        page-break-inside: avoid;
        break-inside: avoid;
        box-shadow: none !important;
        border: 1pt solid #ddd !important;
        border-radius: 6pt !important;
        margin-bottom: 10pt !important;
    }

    /* Photo : afficher la photo active en taille réduite */
    .cv-card__photos {
        height: 140pt !important;
        position: relative !important;
        overflow: hidden !important;
    }
    .cv-card__photo { opacity: 0 !important; position: absolute !important; }
    .cv-card__photo.is-active {
        opacity: 1 !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }

    /* Corps de la carte */
    .cv-card__body    { padding: 8pt 10pt !important; }
    .cv-card__title   { font-size: 13pt !important; margin-bottom: 4pt !important; }
    .cv-card__desc    { font-size: 10pt !important; }
    .cv-tag           { font-size: 8pt !important; padding: 2pt 6pt !important; }

    /* Adresse */
    .cv-card__location { font-size: 9pt !important; color: #555 !important; }
    .cv-location-link  { color: #333 !important; }

    /* Liens : afficher l'URL en texte */
    .cv-card__ext-link::after {
        content: ' (' attr(href) ')';
        font-size: 8pt;
        color: #666;
    }

    /* Marges A4 */
    @page {
        margin: 15mm 12mm;
        size: A4 portrait;
    }

    /* Numéros de page dans le pied */
    @page { @bottom-center { content: counter(page) ' / ' counter(pages); font-size: 9pt; } }
}

/* ── Bouton partage (hero pill) ── */
.cv-share-trigger { cursor: pointer; }

/* ── Panel de partage ── */
.cv-share-panel {
    position: fixed;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%) scale(.92);
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 20px 48px rgba(0,0,0,.22);
    padding: 20px;
    width: 280px;
    z-index: 600;
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s, transform .2s;
}
.cv-share-panel.is-open {
    opacity: 1;
    pointer-events: auto;
    transform: translate(-50%, -50%) scale(1);
}
.cv-share-panel__title {
    font-size: 13px; font-weight: 700; color: var(--cv-gray-500, #6B7280);
    text-transform: uppercase; letter-spacing: .5px;
    margin: 0 0 12px;
}
.cv-share-option {
    display: flex; align-items: center; gap: 12px;
    width: 100%; padding: 10px 12px;
    border: none; border-radius: 10px;
    background: transparent; cursor: pointer;
    font-family: var(--cv-font-body); font-size: 14px; font-weight: 500;
    color: var(--cv-gray-900, #111);
    text-decoration: none;
    transition: background .15s;
    margin-bottom: 4px;
}
.cv-share-option:hover { background: var(--cv-gray-100, #F3F4F6); }

/* ── FABs groupés (bas d'écran) ── */
.cv-fabs {
    position: fixed;
    bottom: 24px; right: 24px;
    display: flex; flex-direction: column;
    gap: 12px; z-index: 500;
}
.cv-fab {
    width: 52px; height: 52px;
    border-radius: 50%;
    border: none; cursor: pointer;
    display: flex; align-items: center; justify-content: center;
    color: #fff;
    box-shadow: 0 4px 14px rgba(0,0,0,.22);
    transition: transform .2s, box-shadow .2s;
}
.cv-fab:hover { transform: scale(1.08); box-shadow: 0 6px 20px rgba(0,0,0,.28); }
.cv-fab--print { background: var(--cv-fab-pdf, var(--cv-color)); }
.cv-fab--share { background: var(--cv-fab-share, #1A73E8); }

/* ── Badge météo ── */
.cv-weather-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 9px;
    border-radius: 6px;
    background: #EFF6FF;
    border: 1px solid #BFDBFE;
    font-size: 11px;
    font-weight: 600;
    color: #1E40AF;
    cursor: default;
    transition: opacity .3s;
}
.cv-weather-badge:not(.cv-weather-ready) { opacity: .5; }
.cv-weather-icon { font-size: 14px; line-height: 1; }
.cv-weather-temp { font-variant-numeric: tabular-nums; }
@media print { .cv-weather-badge { background: #f0f4ff; border: 1pt solid #c0d0f0; } }

/* ══════════════════════════════════════════════════════════════
   BOUTON TIP + POPUP CONSEIL
══════════════════════════════════════════════════════════════ */

/* Bouton inline sur la ligne des tags */
.cv-tip-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 9px;
    border-radius: 6px;
    background: #FFFBEB;
    border: 1px solid #FDE68A;
    font-size: 11px;
    font-weight: 700;
    color: #92400E;
    cursor: pointer;
    font-family: var(--cv-font-body);
    transition: background .15s, border-color .15s, transform .1s;
}
.cv-tip-btn:hover {
    background: #FEF3C7;
    border-color: #F59E0B;
    transform: scale(1.04);
}
.cv-tip-btn__icon { font-size: 13px; line-height: 1; }

/* Overlay */
.cv-tip-overlay {
    position: fixed;
    inset: 0;
    background: rgba(17, 24, 39, .55);
    z-index: 8000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

/* Modal conseil */
.cv-tip-modal {
    background: #fff;
    border-radius: 16px;
    width: 100%;
    max-width: 460px;
    box-shadow: 0 20px 48px rgba(0,0,0,.18);
    overflow: hidden;
}

.cv-tip-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: #FFFBEB;
    border-bottom: 1px solid #FDE68A;
}

.cv-tip-modal__title {
    font-family: var(--cv-font-body);
    font-size: 15px;
    font-weight: 700;
    color: #92400E;
}

.cv-tip-modal__close {
    background: none;
    border: none;
    font-size: 24px;
    color: #92400E;
    cursor: pointer;
    line-height: 1;
    padding: 0;
    opacity: .7;
    transition: opacity .15s;
}
.cv-tip-modal__close:hover { opacity: 1; }

.cv-tip-modal__body {
    padding: 20px;
    font-size: 15px;
    line-height: 1.65;
    color: var(--cv-gray-700, #374151);
}

@media print { .cv-tip-overlay, .cv-tip-btn { display: none !important; } }

/* ══════════════════════════════════════════════════════════════
   MARQUEURS LEAFLET NUMÉROTÉS
══════════════════════════════════════════════════════════════ */
.cv-marker-wrap {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,.3));
}
.cv-marker {
    display: flex;
    align-items: center;
    gap: 3px;
    padding: 4px 8px;
    border-radius: 14px;
    border: 2px solid rgba(255,255,255,.95);
    font-size: 11px;
    font-weight: 800;
    color: #fff;
    white-space: nowrap;
    line-height: 1;
    cursor: pointer;
    transition: transform .15s;
}
.cv-marker:hover { transform: scale(1.1); }
.cv-m-num { font-size: 12px; font-weight: 900; }
.cv-m-ico { font-size: 12px; line-height: 1; }
.cv-marker-tip {
    width: 0; height: 0;
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-top: 8px solid #000; /* overridden inline */
    margin-top: -1px;
}

/* Marqueurs de référence (admin modal — plus petits) */
.cv-ref-marker-wrap {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    filter: drop-shadow(0 1px 3px rgba(0,0,0,.25));
}
.cv-ref-marker {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,.9);
    font-size: 10px;
    font-weight: 800;
    color: #fff;
    line-height: 1;
}
.cv-ref-marker-tip {
    width: 0; height: 0;
    border-left: 4px solid transparent;
    border-right: 4px solid transparent;
    border-top: 5px solid #000;
    margin-top: -1px;
}

/* Popup map custom */
.cv-map-popup strong { display: block; font-size: 13px; font-weight: 700; margin-bottom: 2px; }
.cv-map-popup small  { color: #6B7280; font-size: 11px; }
