/* =============================
   POP UP ESTILOS Y ANIMACIONES
   ============================= */

.js-chart-popup-container, .js-chart-popup-container * {
    box-sizing: border-box !important;
    margin: 0;
    padding: 0;
}

.js-chart-popup-container {
    position: fixed !important;
    bottom: 20px !important;
    right: 20px !important;
    width: 340px !important;
    /* CORRECCIÓN: Ajustamos el alto a 154px para dar el espacio exacto y que entren los botones */
    height: 154px !important; 
    background: #ffffff !important;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15) !important;
    border-radius: 4px !important;
    padding: 12px 14px 10px 14px !important; /* Optimización de espacios internos */
    z-index: 99999 !important;
    font-family: inherit !important;
    transition: all 0.4s cubic-bezier(0.25, 1, 0.5, 1) !important;
    transform: translateY(50px);
    opacity: 0;
    overflow: hidden !important;
}

.pop-up-meta-description {
    display: inline-flex !important;
    align-items: center !important;
    gap: 4px !important;
}

.js-pool-text-val {
    color: #666666 !important;
}
			
/* CORRECCIÓN: Aseguramos que la lona del SVG se estire sobre el borde exacto de la tarjeta */
.pop-up-svg {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    pointer-events: none !important;
    z-index: 11 !important;
}

.js-popup-border-line{
    x:0;
    y:0;
    width:100%;
    height:100%;
    rx:4;
    ry:4;
    fill:none;
    stroke:#e00712;
    stroke-width:4;
    stroke-dasharray:988; 
    stroke-dashoffset:0;
    transition: stroke-dashoffset 0.1s linear;
}

.pop-up-trending-header {
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    margin-bottom: 6px !important;
    color: #e00712 !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    line-height: 1.1 !important;
}
               
.pop-up-media {
    display: flex !important;
    gap: 12px !important;
    align-items: flex-start !important;
    margin-bottom: 6px !important;
}

.rh-thumb-wrapper {
    position: relative !important;
    width: 85px !important;
    height: 85px !important;
    flex-shrink: 0 !important;
    overflow: hidden !important;
    border-radius: 4px !important;
    z-index: 12 !important;
}

.rh-thumb-hover {
    width: 85px !important;
    height: 85px !important;
    object-fit: cover !important;
    border-radius: 4px !important;
    border: 1px solid #eee !important;
    cursor: pointer !important;
    transition: transform 0.25s cubic-bezier(0.175, 0.885, 0.32, 1.275) !important;
}     

.js-popup-zoom-btn {
    position: absolute !important;
    bottom: 4px !important;
    right: 4px !important;
    background: rgba(0,0,0,0.6) !important;
    color: #ffffff !important;
    width: 20px !important;
    height: 20px !important;
    border-radius: 3px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer !important;
    font-size: 10px !important;
    z-index: 13 !important;
    transition: background 0.2s !important;
}
                    
.rh-title-container {
    margin: 0 0 2px 0 !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    color: #333 !important;
    line-height: 1.2 !important;
    cursor: pointer !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;    
    max-height: 32px !important;
}                    

.pop-up-card {
    flex-grow: 1 !important;
    min-width: 0 !important;
    display: flex !important;
    flex-direction: column !important;
}

.pop-up-location {
    margin: 0 0 2px 0 !important;
    font-size: 11px !important;
    color: #777 !important;
    line-height: 1.2 !important;
}

.pop-up-footer {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    margin-bottom: 2px !important;
    gap: 4px !important;
    flex-wrap: wrap !important;
}

.pop-up-price {
    font-size: 14px !important;
    font-weight: 700 !important;
    color: #e00712 !important;
    line-height: 1.2 !important;
}
 
.pop-up-views {
    font-size: 10px !important;
    color: #666 !important;
    background: #f5f5f5 !important;
    padding: 2px 5px !important;
    border-radius: 3px !important;
    font-weight: 600 !important;
    white-space: nowrap !important;
    line-height: 1.2 !important;
}

.pop-up-icons { /* Cambiar Colores de los Iconos y Espacio */
    display: flex;
    gap: 6px; 
    font-size: 11px;
    color: #666666;
    align-items: center;
    flex-wrap: wrap;
    line-height: 2;
}

.pop-up-icons i {
    font-size: 11px;
    display: inline-block;
    width: auto;
    height: auto;
    margin-right: 2px;
}

/* CORRECCIÓN: Forzamos la fila de botones a empujarse al fondo visible de forma exacta */
.pop-up-buttons {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    border-top: 1px solid #eee !important;
    padding-top: 6px !important;
    margin-top: 4px !important;
    gap: 8px !important;
    height: auto !important;
    width: 100% !important;
}

.js-popup-later, .js-popup-disable {
    background: none !important;
    border: none !important;
    font-weight: 600 !important;
    font-size: 11px !important;
    cursor: pointer !important;
    padding: 2px 0 !important;
    font-family: inherit !important;
}

.js-popup-later { color: #888 !important; }
.js-popup-disable { color: #a30000 !important; }

.rh-close-btn {
    position: absolute !important;
    top: 6px !important;
    right: 12px !important;
    color: #aaa !important;
    font-size: 18px !important;
    cursor: pointer !important;
    font-weight: bold !important;
    line-height: 1 !important;
    transition: color 0.2s ease !important;
    z-index: 12 !important;
}

.rh_classic_icon {
    margin-right: 1px !important;
}

.rh-close-btn:hover {
    color: #e00712 !important;
}

@keyframes rh-pulse-green { 0% { opacity: 0.6; } 50% { opacity: 1; } 100% { opacity: 0.6; } }
.rh-new-pulse-badge {
    animation: rh-pulse-green 1s infinite ease-in-out !important;
}

.fa.fa-fire {
    animation: fa-fire-red 1s infinite ease-in-out !important;
}

@keyframes fa-fire-red {
    0% { transform: scale(1); color: #e00712; }
    50% { transform: scale(1.15); color: #e00712; }
    100% { transform: scale(1); color: #e00712; }
}
			
.js-popup-zoom-btn:hover {
    background: #e00712 !important;
}

.rh-thumb-hover:hover {
    transform: scale(1.12) !important;
    transform-origin: center center !important;
}

@keyframes rh-border-draw { from { stroke-dashoffset: 0; } to { stroke-dashoffset: 1215; } }
.js-popup-border-active {
    animation: rh-border-draw 15s linear forwards !important;
}
	
@media only screen and (max-width: 480px) {
    .js-chart-popup-container {
        right: auto !important;
        left: 50% !important;
        transform: translate(-50%, 120px) !important;
        width: 90% !important;
        max-width: 340px !important;
    }
    .js-chart-popup-visible-mobile {
        transform: translate(-50%, 0) !important;
    }
}

.pop-up-overlay {
position:fixed;
top:0;
left:0;
width:100vw;
height:100vh;
background:rgba(0,0,0,0.85);
z-index:100000;
display:flex;
align-items:center;
justify-content:center;
opacity:0;
transition:opacity 0.3s ease;
}

.pop-up-modal-container {
    position: relative !important;
    width: auto !important;
    height: auto !important;
    max-width: 90vw !important;
    max-height: 90vh !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.pop-up-thumbnail-zoom {
    max-width: 95vw !important;
    max-height: 85vh !important;
    width: auto !important;
    height: auto !important;
    object-fit: contain !important;
    border-radius: 6px !important;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.6) !important;
    display: block !important;
    animation: rh-modal-zoom 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.15) !important;
}

.js-modal-close {
    position: absolute !important;
    top: -45px !important;
    right: 0 !important;
    color: #ffffff !important;
    font-size: 36px !important;
    cursor: pointer !important;
    font-weight: bold !important;
    padding: 5px !important;
    line-height: 1 !important;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8) !important;
    transition: color 0.2s !important;
}

@keyframes rh-modal-zoom { from { transform: scale(0.8); opacity: 0; } to { transform: scale(1); opacity: 1; } }