/* assets/css/ubicaciones.css
   Hoja de estilos propia de /ubicaciones — mismo patrón que preventa.css:
   independiente de style.css, copiado a mano (no @import).
   1) Variables root + reset (mismas que preventa.css/style.css).
   2) El mapa interactivo completo (#ubicacion-interactiva de inicio.php),
      copiado de style.css — selectores .section-mapa-inmersivo, .map-pin,
      .side-panel, etc. Si el diseño del mapa cambia en style.css, hay que
      replicar el cambio aquí a mano, igual que con preventa.css.
   Sin header/nav (2026-07-24, a petición de Kevin: la píldora del header
   estorbaba encima de las fotos del mapa) — solo un link mínimo de
   regreso a /preventa, ver .ubicaciones-volver más abajo.
*/

/* ==========================================================================
   VARIABLES ROOT Y RESET (mismas que style.css/preventa.css)
   ========================================================================== */
:root {
    --brand-dark: #004944;
    --brand-medium: #1A916F;
    --brand-light: #86D296;
    --brand-accent: #B8D176;
    --brand-cream: #E6D5A7;

    --bg-color: #f7f9f8;
    --text-main: #333333;
    --header-height: 85px;

    --font-heading: 'Playfair Display', serif;
    --font-body: 'Montserrat', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    color: var(--text-main);
    background-color: var(--bg-color);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    color: var(--brand-dark);
    font-weight: 600;
}

/* Link mínimo de regreso a /preventa (reemplaza al header completo). Pequeña
   píldora tipo botón (mismo lenguaje visual que .map-bottom-nav: fondo
   translúcido + blur) en vez de solo texto, para que se sienta clickeable
   y dé feedback al pasar el mouse/tocar, sin ser tan grande como el header
   que quitamos. */
.ubicaciones-volver {
    position: fixed;
    top: 25px;
    left: 25px;
    z-index: 1000;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 50px;
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    color: #fff;
    text-decoration: none;
    text-shadow: 0 2px 6px rgba(0,0,0,0.6);
    box-shadow: 0 6px 20px rgba(0,0,0,0.2);
    transition: background 0.3s ease, border-color 0.3s ease, transform 0.3s ease;
}
.ubicaciones-volver:hover {
    background: rgba(255, 255, 255, 0.24);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateX(-3px);
}
.ubicaciones-volver:active { transform: translateX(-1px) scale(0.97); }

.section-mapa-inmersivo {
    position: relative;
    width: 100vw;
    height: 100vh;
    left: 50%;
    transform: translateX(-50%);
    padding: 0 !important;
    margin: 0 !important;
    background-color: #0b2b26;
    overflow: hidden;
    color: #ffffff;
    
}

.mapa-ui-overlay { 
    position: absolute; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%; 
    padding-top: 15vh; 
    padding-left: 10%; 
    z-index: 20; 
    pointer-events: none; 
    background: none; 
}

.section-editorial-h3 {
    font-family: 'Playfair Display', serif;
    font-size: 3.8rem;
    font-weight: 500;
    letter-spacing: 2px;
    line-height: 1.1;
    margin: 0;
    text-transform: uppercase;
    /* Sin esto hereda color:var(--brand-dark) (verde oscuro) de la regla
       global "h1,h2,h3,h4" de arriba — casi ilegible sobre el mapa. Blanco,
       a petición de Kevin (2026-07-24). */
    color: #ffffff;
    text-shadow: 0 4px 8px rgba(0,0,0,1), 0 8px 40px rgba(0,0,0,1), 0 0 90px rgba(0,0,0,0.95);
}

.mapa-instruccion {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.3rem;
    font-weight: 600;
    color: #E6D5A7;
    margin-top: 15px;
    letter-spacing: 1px;
    text-shadow: 0 2px 6px rgba(0,0,0,1), 0 4px 16px rgba(0,0,0,1), 0 8px 44px rgba(0,0,0,1), 0 0 84px rgba(0,0,0,0.95);
}

.map-viewport { 
    width: 100%; 
    height: 100%; 
    position: absolute; 
    top: 0; 
    left: 0; 
    overflow: hidden; 
}

.map-container { 
    position: absolute; 
    width: 120vw; 
    height: 120vh; 
    top: -10vh; 
    left: -10vw; 
    transform-origin: center center; 
    will-change: transform; 
}

.map-layer { 
    position: absolute; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%; 
    opacity: 0; 
    visibility: hidden; 
    transition: opacity 0.8s ease-in-out; 
    z-index: 1; 
}

.map-layer.active { 
    opacity: 1; 
    visibility: visible; 
    z-index: 2; 
}

.map-image { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    pointer-events: none; 
}

.map-layer::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.28);
    z-index: 1;
    pointer-events: none;
}

.map-point-wrapper {
    position: absolute;
    z-index: 10;
    transform: translate(-50%, -50%);
}

.map-pin {
    position: relative;
    width: 50px;
    height: 50px;
    background: #1A916F;
    border-radius: 50%; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    cursor: pointer; 
    box-shadow: 0 10px 20px rgba(0,0,0,0.3); 
    transition: all 0.3s ease; 
}

.map-pin:hover { 
    transform: scale(1.1); 
    background: #A3B18A; 
}

.pin-icon { 
    font-size: 1.2rem; 
    position: relative; 
    z-index: 2; 
    color: #fff;
}

.pin-pulse { 
    position: absolute; 
    top: 0; left: 0; right: 0; bottom: 0; 
    border-radius: 50%; 
    border: 1px solid #A3B18A; 
    animation: pulseAnim 2s infinite; 
}

@keyframes pulseAnim {
    0% { transform: scale(1); opacity: 0.8; }
    100% { transform: scale(1.8); opacity: 0; }
}

.okram-wrapper { z-index: 12; }

.map-pin-okram {
    width: 78px;
    height: 78px;
    background: linear-gradient(150deg, #F4E3B0 0%, #DDBB74 55%, #C9A24B 100%);
    border: 2px solid #FFFFFF;
    border-radius: 50% 50% 50% 0;
    transform: rotate(-45deg);
    box-shadow: 0 12px 26px rgba(0,0,0,0.4), 0 0 18px rgba(217, 184, 113, 0.55);
    animation: okramGlow 2.6s ease-in-out infinite;
}

.map-pin-okram:hover {
    transform: rotate(-45deg) scale(1.08);
    background: linear-gradient(150deg, #FAEDC4 0%, #E6C684 55%, #D4AE5C 100%);
}

.okram-mark {
    font-family: 'Playfair Display', serif;
    font-size: 1.7rem;
    font-weight: 700;
    line-height: 1;
    color: var(--brand-dark);
    transform: rotate(45deg);
    text-shadow: 0 1px 1px rgba(255, 255, 255, 0.35);
}

.okram-logo {
    width: 50px;
    height: auto;
    object-fit: contain;
    text-shadow: none;
}

@keyframes okramGlow {
    0%, 100% { box-shadow: 0 12px 26px rgba(0,0,0,0.4), 0 0 16px rgba(217, 184, 113, 0.5); }
    50%      { box-shadow: 0 12px 26px rgba(0,0,0,0.4), 0 0 32px rgba(217, 184, 113, 0.95); }
}

.okram-label {
    position: absolute;
    top: calc(100% + 10px);
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 73, 68, 0.88);
    color: var(--brand-cream);
    font-family: 'Montserrat', sans-serif;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 3px;
    text-transform: uppercase;
    padding: 4px 13px;
    border-radius: 20px;
    white-space: nowrap;
    border: 1px solid rgba(230, 213, 167, 0.55);
    box-shadow: 0 6px 16px rgba(0,0,0,0.35);
    pointer-events: none;
}

.side-panel { 
    position: absolute; 
    top: 0; 
    right: 0; 
    width: 35%; 
    min-width: 350px; 
    max-width: 500px; 
    height: 100%; 
    background-color: #F8F5F0; 
    z-index: 50; 
    transform: translateX(100%); 
    transition: transform 0.6s cubic-bezier(0.25, 1, 0.5, 1);
    display: flex;
    flex-direction: column; 
}

.side-panel.is-active {
    transform: translateX(0); 
    box-shadow: -15px 0 40px rgba(0,0,0,0.15); 
}

.btn-close-panel { 
    position: absolute; 
    top: 30px; 
    right: 30px; 
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid rgba(0,0,0,0.2);
    background: transparent;
    font-size: 1.2rem;
    color: #333;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    padding: 0;
}

.btn-close-panel:hover { 
    background: #0b2b26; 
    color: #fff; 
}

.panel-content {
    padding: 100px 40px 40px 40px;
    overflow-y: auto;
    color: #333;
}

.side-panel .panel-img {
    display: block;
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 12px;
    margin: 20px 0 25px 0;
}

.cat-icon, .rating-icon {
    height: 1.05em;
    width: auto;
    vertical-align: -0.18em;
    margin-right: 7px;
}

.btn-como-llegar {
    display: inline-block;
    margin-top: 15px;
    padding: 14px 35px;
    background: transparent;
    color: var(--brand-dark);
    font-family: 'Montserrat', sans-serif;
    font-size: 0.95rem;
    font-weight: bold;
    letter-spacing: 0.3px;
    text-decoration: none;
    border: 1px solid var(--brand-dark);
    border-radius: 6px;
    transition: all 0.3s ease;
}

.btn-como-llegar:hover {
    background: var(--brand-dark);
    color: #fff;
}

.pin-icon-img {
    position: relative;
    z-index: 2;
    width: 34px;
    height: 34px;
    object-fit: contain;
    filter: brightness(0) invert(1); 
    pointer-events: none;
}

.panel-category {
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    letter-spacing: 2px;
    color: #A3B18A;
    text-transform: uppercase; 
    font-weight: 600;
}

.side-panel h4 { 
    font-family: 'Playfair Display', serif; 
    font-size: 2rem; 
    color: #0b2b26; 
    margin-top: 10px; 
    margin-bottom: 25px; 
}

.side-panel p {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.1rem;
    line-height: 1.6;
    color: #555;
    margin-bottom: 25px;
}

.map-nav-hover-area { 
    position: absolute; 
    bottom: 0; 
    left: 0; 
    width: 100%; 
    height: 150px; 
    z-index: 20; 
    display: flex; 
    justify-content: center; 
    align-items: flex-end; 
    padding-bottom: 40px; 
}

.map-bottom-nav { 
    display: flex; 
    gap: 8px; 
    padding: 8px 15px; 
    background: rgba(255, 255, 255, 0.15); 
    backdrop-filter: blur(15px); 
    -webkit-backdrop-filter: blur(15px); 
    border: 1px solid rgba(255, 255, 255, 0.3); 
    border-radius: 50px; 
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2); 
    transition: all 0.4s ease; 
}

.map-nav-thumb { 
    background: none; 
    border: 2px solid transparent; 
    padding: 0; 
    cursor: pointer; 
    border-radius: 50px; 
    overflow: hidden; 
    width: 40px; 
    height: 40px; 
    position: relative; 
    transition: all 0.4s ease; 
}

.map-nav-thumb img { 
    width: 100%; 
    height: 100%; 
    object-fit: cover; 
    transition: transform 0.5s ease; 
}

.thumb-label { 
    position: absolute; 
    bottom: 0; 
    left: 0; 
    width: 100%; 
    padding: 5px 0; 
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent); 
    color: white; 
    font-size: 0.75rem; 
    text-align: center; 
    opacity: 0; 
    visibility: hidden; 
    transition: opacity 0.3s ease; 
}

.map-nav-thumb.active { border: 2px solid rgba(255, 255, 255, 0.8); }

.map-bottom-nav {
    gap: 12px;
    padding: 12px;
    border-radius: 22px;
}

.map-nav-thumb {
    width: 105px;
    height: 65px;
    border-radius: 12px;
}

.thumb-label {
    opacity: 1;
    visibility: visible;
}

@media (max-width: 768px) {

        .section-editorial-h3 { font-size: 2.5rem; }

        .section-mapa-inmersivo { height: 100dvh; }

        .side-panel {
            top: auto; 
            bottom: 0; 
            right: 0;
            width: 100%; 
            height: auto; 
            min-height: 30dvh;
            max-height: 85dvh;
            min-width: 100%;
            border-radius: 30px 30px 0 0; 
            transform: translateY(100%); 
            box-shadow: 0 -10px 40px rgba(0,0,0,0.2); 
        }
        .side-panel.is-active {
            transform: translateY(0); 
        }
        .panel-content { padding: 60px 20px 20px 20px; }



        .map-nav-hover-area { 
            height: auto; 
            padding-bottom: 20px; 
        }

        .map-bottom-nav {
            gap: 12px;
            padding: 12px;
            border-radius: 20px;
            width: 95%; 
            overflow-x: auto; 
            justify-content: flex-start;
            scrollbar-width: none; 
        }

        .map-bottom-nav::-webkit-scrollbar { 
            display: none; 
        }
        .map-nav-thumb { 
            flex-shrink: 0; 
            width: 110px; 
            height: 70px; 
            border-radius: 12px; 
        }


        .thumb-label {
            opacity: 1;
            visibility: visible;
        }
}

.swipe-indicator { display: none; }

@media (max-width: 991px) {

        /* Título/instrucción ("MÁXIMA CONECTIVIDAD"): oculto por defecto en
           tablet Y móvil (2026-07-24, a petición de Kevin — antes esto solo
           pasaba ≤768px, así que en tablet el título se quedaba estorbando
           el mapa todo el tiempo). Aparece un momento al cambiar de zona
           (mapa.js agrega .mapa-ui-flash) y se desvanece solo. */
        .mapa-ui-overlay {
            opacity: 0;
            transition: opacity 0.5s ease;
        }
        .mapa-ui-overlay.mapa-ui-flash {
            opacity: 1;
        }

        .section-mapa-inmersivo { height: 100dvh !important; }

        html { scroll-snap-type: y proximity; }
        .section-mapa-inmersivo { scroll-snap-align: start; scroll-snap-stop: always; }
        .map-viewport { overflow-x: auto; overflow-y: hidden; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
        .map-viewport::-webkit-scrollbar { display: none; }

        #interactive-map { width: 250vw; height: 100%; top: 0; left: 0; right: auto; bottom: auto; }
        .swipe-indicator {
            display: block;
            position: absolute;
            bottom: 150px; 
            left: 50%;
            transform: translateX(-50%);
            color: #fff;
            background: rgba(11, 43, 38, 0.75);
            padding: 6px 18px;
            border-radius: 20px;
            border: 1px solid rgba(255, 255, 255, 0.2);
            backdrop-filter: blur(4px);
            -webkit-backdrop-filter: blur(4px);
            font-family: 'Montserrat', sans-serif;
            font-size: 0.8rem;
            font-weight: 500;
            letter-spacing: 1px;
            white-space: nowrap;
            z-index: 15; 
            animation: swipeAnim 2.5s infinite ease-in-out;
            pointer-events: none;
        }
        @keyframes swipeAnim {
            0%, 100% { transform: translateX(-50%); }
            25% { transform: translateX(-55%); } 
            75% { transform: translateX(-45%); } 
        }

        .side-panel {
            top: auto !important; bottom: 0 !important; left: 0 !important; right: 0 !important;
            width: 100% !important; min-width: 100% !important;
            height: auto !important;         
            min-height: 30dvh !important;    
            max-height: 85dvh !important;    
            display: block !important;
            overflow-y: auto !important;     
            border-radius: 25px 25px 0 0 !important;
            background-color: #F8F5F0 !important;
            transform: translateY(100%) !important;
            box-shadow: 0 -15px 40px rgba(0,0,0,0.4) !important;
            visibility: hidden !important; opacity: 0 !important; pointer-events: none !important;
            z-index: 9999 !important;
        }
        .side-panel.is-active {
            transform: translateY(0) !important;
            visibility: visible !important; opacity: 1 !important; pointer-events: auto !important;
        }
        .side-panel .panel-content { padding: 40px 25px 30px 25px !important; }
        .side-panel h4 { font-size: 1.8rem !important; margin-bottom: 5px !important; line-height: 1.1 !important; color: var(--brand-dark) !important; }
        .side-panel .panel-content p { color: #334155 !important; font-size: 1.05rem !important; line-height: 1.6 !important; margin-bottom: 15px !important; }
        .side-panel .panel-content p strong { color: var(--brand-dark) !important; }

        .side-panel .panel-img {
            display: block !important;
            width: 100% !important;
            height: 150px !important;
            object-fit: cover !important;
            border-radius: 12px !important;
            margin: 0 0 15px 0 !important;
        }
        .side-panel .panel-content ul { margin: 0 0 0 18px !important; padding: 0 !important; font-size: 0.9rem !important; color: #475569 !important; }
        .btn-close-panel {
            position: absolute !important; top: 20px !important; right: 20px !important;
            width: 35px !important; height: 35px !important;
            border-radius: 50% !important; border: 1px solid rgba(0,0,0,0.15) !important;
            background: transparent !important; color: #555 !important;
            font-size: 1.2rem !important; font-weight: 300 !important;
            display: flex !important; align-items: center !important; justify-content: center !important;
            z-index: 10000 !important;
        }
}

@media (max-width: 600px) {
        #interactive-map { width: 350vw; }
}
