/*
 * Landing map — filtros overlay + markers de marca
 * Ruta rastreada por git (fuera de public/build y public/brand).
 */

.landing-map-wrap {
    position: relative;
}

.landing-map-wrap--fullbleed {
    width: 100%;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.landing-concesionarias-map {
    width: 100%;
}

.landing-map-scroll-hint {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 900;
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
    background: rgba(33, 37, 41, 0.82);
    color: #fff;
    padding: 0.65rem 1rem;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    white-space: nowrap;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.landing-map-scroll-hint.is-visible {
    opacity: 1;
    visibility: visible;
}

.landing-map-scroll-hint kbd {
    display: inline-block;
    padding: 0.1rem 0.4rem;
    margin: 0 0.15rem;
    font-size: 0.8em;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 0.25rem;
}

.landing-map-filters {
    position: absolute;
    top: 12px;
    left: 12px;
    right: 12px;
    z-index: 1000;
    pointer-events: none;
    max-width: 600px;
}

.landing-map-filters__toggle {
    display: none;
    pointer-events: auto;
    align-items: center;
    border: 1px solid rgba(0, 0, 0, 0.08);
    background: rgba(255, 255, 255, 0.96);
}

.landing-map-filters__panel {
    pointer-events: auto;
    background: rgba(255, 255, 255, 0.96);
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 0.5rem;
    padding: 0.75rem;
}

.dealer-brand-marker {
    background: transparent !important;
    border: none !important;
    width: 40px !important;
    height: 40px !important;
    margin-left: -20px !important;
    margin-top: -20px !important;
    overflow: hidden !important;
}

.dealer-brand-marker__inner {
    width: 40px;
    height: 40px;
    min-width: 40px;
    min-height: 40px;
    max-width: 40px;
    max-height: 40px;
    overflow: hidden;
    box-sizing: border-box;
    background: #fff;
    border-radius: 50%;
    box-shadow: 0 1px 5px rgba(0, 0, 0, 0.35);
    border: 2px solid #405189;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #405189;
}

.dealer-brand-marker__logo {
    width: 24px;
    height: 24px;
    display: block;
    flex-shrink: 0;
    background-color: currentColor;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
    -webkit-mask-size: contain;
    mask-size: contain;
}

/* Audi / SEAT: logo gris, fondo blanco */
.dealer-brand-marker--audi,
.dealer-brand-marker--seat {
    background: #ffffff;
    border-color: #d0d4da;
    color: #6c757d;
}

/* VW / VWVC: logo blanco, fondo azul */
.dealer-brand-marker--vw,
.dealer-brand-marker--vwvc {
    background: #001e50;
    border-color: #001e50;
    color: #ffffff;
}

/* CUPRA: logo cobre, fondo negro */
.dealer-brand-marker--cupra {
    background: #111111;
    border-color: #111111;
    color: #c4783a;
}

.dealer-brand-marker--default {
    background: #ffffff;
    border-color: #405189;
    color: #405189;
}

@media (max-width: 575.98px) {
    .landing-map-filters {
        top: auto;
        bottom: 16px;
        left: 12px;
        right: 12px;
        max-width: none;
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }

    .landing-map-filters__toggle {
        display: inline-flex;
    }

    .landing-map-filters__panel {
        display: none;
        width: 100%;
        max-height: min(50vh, 280px);
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .landing-map-filters.is-open .landing-map-filters__panel {
        display: block;
    }

    .landing-map-filters.is-open .landing-map-filters__toggle {
        display: none;
    }

    .landing-concesionarias-map {
        height: 60vh !important;
        min-height: 420px !important;
    }

    /* Zoom de Leaflet arriba a la derecha; filtros abajo para no chocar */
    .landing-map-wrap .leaflet-top.leaflet-right {
        top: 8px;
    }
}
