/* ============================================================
   RIOMONTE MASTER PLAN - Frontend Styles
   ============================================================ */

.rmp-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    font-family: inherit;
}

/* MAPA */
.rmp-map-wrapper {
    position: relative;
    width: 100%;
    display: block;
    overflow: hidden;
    line-height: 0;
}

.rmp-map-img {
    width: 100%;
    height: auto;
    display: block;
    max-width: 100%;
}

.rmp-svg-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* LOTES */
.rmp-lot-circle {
    transition: fill-opacity 0.2s, r 0.2s;
}

.rmp-lot:hover .rmp-lot-circle {
    fill-opacity: 0.85;
    cursor: pointer;
}

/* LEYENDA */
.rmp-legend {
    display: flex;
    gap: 24px;
    padding: 12px 0;
    margin-top: 8px;
}

.rmp-legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}

.rmp-legend-dot {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    display: inline-block;
}

/* MODAL */
.rmp-modal {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.rmp-modal-overlay {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.7);
    cursor: pointer;
}

.rmp-modal-content {
    position: relative;
    background: #fff;
    border-radius: 12px;
    width: 90%;
    max-width: 800px;
    max-height: 85vh;
    overflow-y: auto;
    z-index: 1;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.rmp-modal-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px 24px 16px;
    border-bottom: 1px solid #eee;
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 2;
}

.rmp-modal-header h3 {
    margin: 0;
    font-size: 20px;
    color: #1a202c;
}

.rmp-modal-close {
    margin-left: auto;
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: #666;
    padding: 4px 8px;
    border-radius: 4px;
}

.rmp-modal-close:hover { background: #f5f5f5; }

.rmp-modal-body {
    padding: 20px 24px;
}

/* STATUS BADGE */
.rmp-status-badge {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.rmp-status-badge.disponible { background: #c6f6d5; color: #276749; }
.rmp-status-badge.reservado  { background: #feebc8; color: #7b341e; }
.rmp-status-badge.vendido    { background: #fed7d7; color: #742a2a; }

/* GALERÍA */
.rmp-gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 12px;
}

.rmp-gallery-item {
    position: relative;
    aspect-ratio: 1;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
}

.rmp-gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.2s;
}

.rmp-gallery-item:hover img { transform: scale(1.05); }

.rmp-no-images {
    text-align: center;
    padding: 40px;
    color: #888;
}

.rmp-no-images p { margin: 0; font-size: 15px; }

.rmp-loading {
    text-align: center;
    padding: 40px;
    color: #888;
}

/* LIGHTBOX */
.rmp-lightbox {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.92);
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.rmp-lightbox img {
    max-width: 90vw;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 4px;
}

.rmp-lb-prev, .rmp-lb-next, .rmp-lb-close {
    position: absolute;
    background: rgba(255,255,255,0.15);
    border: none;
    color: white;
    font-size: 24px;
    padding: 12px 16px;
    cursor: pointer;
    border-radius: 8px;
    transition: background 0.2s;
}

.rmp-lb-prev:hover, .rmp-lb-next:hover, .rmp-lb-close:hover {
    background: rgba(255,255,255,0.3);
}

.rmp-lb-prev  { left: 20px; top: 50%; transform: translateY(-50%); }
.rmp-lb-next  { right: 20px; top: 50%; transform: translateY(-50%); }
.rmp-lb-close { top: 20px; right: 20px; }

/* RESPONSIVE */
@media (max-width: 600px) {
    .rmp-legend { flex-wrap: wrap; gap: 12px; }
    .rmp-gallery-grid { grid-template-columns: repeat(2, 1fr); }
    .rmp-modal-content { width: 96%; }
}