#map-container {
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
    border-radius: 8px;
    padding: 4px;
    min-height: 200px;
}

#map-holder {
    width: 100%;
    max-width: 1080px;
    position: relative;
    overflow: hidden;
    height: 0;
    padding-bottom: 100%;
    box-sizing: border-box;
}

#map-svg-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    pointer-events: none;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    display: flex;
    justify-content: center;
    align-items: center;
    box-sizing: border-box;
}

#map-svg-wrapper {
    position: relative;
    width: 100%;
    max-width: 1080px;
    height: 0;
    padding-bottom: 100%;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    pointer-events: all;
    box-sizing: border-box;
    flex-shrink: 0;
}

#map-pointer {
    width: auto;
    height: 40px;
}

.click-pointer {
    transition: transform 0.2s ease-out;
    transform-origin: 50% 100%;
    cursor: pointer;
}

.click-pointer.bounce-in {
    animation: bounce-in 0.5s ease-out;
}

.click-pointer.navigate-mode.pointer-hover {
    animation: hithere 0.6s ease-in-out;
}

.click-pointer.animating {
    animation: swing 0.5s ease-in-out;
    transform-origin: 50% 100%;
}

@keyframes bounce-in {
    0% {
        opacity: 0;
        transform: translate(-50%, -100%) scale(0.3);
    }
    50% {
        opacity: 1;
        transform: translate(-50%, -100%) scale(1.05);
    }
    70% {
        transform: translate(-50%, -100%) scale(0.9);
    }
    100% {
        transform: translate(-50%, -100%) scale(1);
    }
}

@keyframes hithere {
    30% {
        transform: translate(-50%, -100%) scale(1.2);
    }
    40%, 60% {
        transform: translate(-50%, -100%) rotate(-20deg) scale(1.2);
    }
    50% {
        transform: translate(-50%, -100%) rotate(20deg) scale(1.2);
    }
    70% {
        transform: translate(-50%, -100%) rotate(0deg) scale(1.2);
    }
    100% {
        transform: translate(-50%, -100%) scale(1);
    }
}

@keyframes swing {
    20% {
        transform: translate(-50%, -100%) rotate(15deg);
    }
    40% {
        transform: translate(-50%, -100%) rotate(-10deg);
    }
    60% {
        transform: translate(-50%, -100%) rotate(5deg);
    }
    80% {
        transform: translate(-50%, -100%) rotate(-5deg);
    }
    100% {
        transform: translate(-50%, -100%) rotate(0deg);
    }
}

#map-svg-wrapper.pan-ready {
    cursor: grab;
}

#map-svg-wrapper.dragging {
    cursor: grabbing;
}

#map-svg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    max-width: 1080px;
    pointer-events: all;
    transform-origin: center center;
    transition: transform 0.1s ease-out;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.zoom-controls {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 12px;
    height: 200px;
    z-index: 1001;
    display: flex;
    align-items: center;
    justify-content: center;
}

.zoom-controls input[type="range"] {
    width: 200px;
    height: 12px;
    transform: rotate(-90deg);
    transform-origin: center;
    border-radius: 6px;
    background: #982365;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
}

.zoom-controls input[type="range"]::-webkit-slider-thumb {
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #FF51DB;
    cursor: pointer;
    transition: background 0.2s ease;
}

.zoom-controls input[type="range"]::-webkit-slider-thumb:hover {
    background: #FF21D1;
}

.zoom-controls input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #FF51DB;
    cursor: pointer;
    border: none;
    transition: background 0.2s ease;
}

.zoom-controls input[type="range"]::-moz-range-thumb:hover {
    background: #FF21D1;
}

.mode-indicator {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 8px 16px;
    border-radius: 4px;
    font-size: 14px;
    z-index: 1000;
    pointer-events: none;
}

.mode-indicator.edit-mode {
    background: rgba(76, 175, 80, 0.9);
}

.mode-indicator.navigate-mode {
    background: rgba(33, 150, 243, 0.9);
}

#map-svg .st0 {
    fill: #ffffff;
    transition: fill 0.2s ease, stroke 0.2s ease, stroke-width 0.2s ease, filter 0.2s ease;
}

#map-svg .st0:hover {
    fill: rgba(255, 81, 219, 0.20);             
    stroke: #FF51DB;                            
    stroke-width: 2;      
    filter: drop-shadow(0 0 4px rgba(255,81,219,0.7));
    cursor: pointer;
}

/* Modo miniatura */
.map-thumbnail {
    width: 400px;
    max-width: 100%;
    margin: 0 auto;
}

.map-thumbnail #map-holder {
    max-width: 400px;
    width: 400px;
}

/* En pantallas pequeñas, el mapa puede ser más pequeño */
@media (max-width: 640px) {
    .map-thumbnail {
        width: 100%;
        max-width: 100%;
    }
    
    .map-thumbnail #map-holder {
        width: 100%;
        max-width: 100%;
    }
}

.map-thumbnail .zoom-controls {
    display: none !important;
}

.map-thumbnail #map-svg-wrapper {
    cursor: default;
    pointer-events: none;
}

.map-thumbnail #map-svg-wrapper.pan-ready,
.map-thumbnail #map-svg-wrapper.dragging {
    cursor: default;
}

.map-thumbnail #map-container {
    min-height: 400px;
}

.map-thumbnail .click-pointer {
    pointer-events: auto !important;
    cursor: pointer !important;
}

