/* ===========================================
   ADMIN STYLES
   =========================================== */

.rm-card {
    background: #fff;
    border: 1px solid #ccd0d4;
    border-radius: 4px;
    padding: 20px;
    box-shadow: 0 1px 1px rgba(0,0,0,.04);
}

.rm-card h2 {
    margin-top: 0;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.api-status {
    display: inline-block;
    margin-left: 10px;
    font-size: 20px;
    min-width: 30px;
}

/* ===========================================
   GALLERY STYLES
   =========================================== */

.rm-gallery {
    position: relative;
    max-width: 1000px;
    margin: 40px auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    overflow: hidden;
}

.rm-empty {
    text-align: center;
    padding: 60px 20px;
    color: #666;
    font-size: 16px;
    background: #f9f9f9;
    border-radius: 8px;
    border: 2px dashed #ddd;
}

/* Slider */
.rm-slider {
    position: relative;
    width: 100%;
}

.rm-slide {
    display: none;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.rm-slide.active {
    display: block;
    opacity: 1;
}

/* Image container */
.rm-image-container {
    position: relative;
    width: 100%;
    height: 500px;
    background: #e0e0e0;
    overflow: hidden;
}

.rm-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Loader */
.rm-loader {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
}

.rm-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(0,0,0,0.1);
    border-top-color: #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Info */
.rm-info {
    padding: 30px;
    background: linear-gradient(to bottom, #fff 0%, #f9f9f9 100%);
}

.rm-number {
    display: inline-block;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 12px;
}

.rm-address {
    font-size: 26px;
    font-weight: 700;
    color: #333;
    margin: 0 0 10px 0;
    line-height: 1.3;
}

.rm-city {
    font-size: 16px;
    color: #888;
    margin: 0 0 20px 0;
}

.rm-clean-notice {
    font-size: 14px;
    color: #666;
    background: #f0f8ff;
    padding: 10px 15px;
    border-radius: 6px;
    border-left: 3px solid #667eea;
    margin: 0 0 20px 0;
}

.rm-clean-notice strong {
    color: #667eea;
}

/* Notes system */
.rm-notes-section {

/* Toggle Switch */
.rm-toggle-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 26px;
}

.rm-toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.rm-toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.4s;
    border-radius: 26px;
}

.rm-toggle-slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.4s;
    border-radius: 50%;
}

.rm-toggle-switch input:checked + .rm-toggle-slider {
    background-color: #46b450;
}

.rm-toggle-switch input:checked + .rm-toggle-slider:before {
    transform: translateX(24px);
}

.rm-toggle-status {
    font-size: 12px;
    margin-top: 5px;
    display: none;
}

/* Notes system */
.rm-notes-section {
    margin: 20px 0;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
}

.rm-notes-label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #333;
}

.rm-has-note {
    display: inline-block;
    margin-left: 10px;
    padding: 2px 8px;
    background: #d4edda;
    color: #155724;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
}

.rm-notes-input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-family: inherit;
    font-size: 14px;
    resize: vertical;
    transition: border-color 0.3s;
}

.rm-notes-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.rm-notes-actions {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-top: 10px;
}

.rm-save-note-btn {
    background: #667eea;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
}

.rm-save-note-btn:hover {
    background: #5568d3;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.rm-save-note-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

.rm-note-date {
    font-size: 12px;
    color: #666;
}

.rm-note-status {
    margin-top: 8px;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 13px;
    display: none;
}

.rm-note-status.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.rm-note-status.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.rm-maps-btn {
    display: inline-block;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 14px 28px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    transition: all 0.3s;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

.rm-maps-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
    color: white;
    text-decoration: none;
}

/* Navigation buttons */
.rm-nav {
    position: absolute;
    top: 300px;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.95);
    border: 2px solid #667eea;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 32px;
    color: #667eea;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 4px 12px rgba(0,0,0,0.25);
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.rm-nav:hover {
    background: #667eea;
    color: white;
    transform: translateY(-50%) scale(1.15);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.5);
}

.rm-prev {
    left: 20px;
}

.rm-next {
    right: 20px;
}

/* Dots */
.rm-dots {
    display: flex;
    justify-content: center;
    gap: 12px;
    padding: 20px 0;
}

.rm-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #ddd;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    padding: 0;
}

.rm-dot:hover {
    background: #bbb;
    transform: scale(1.2);
}

.rm-dot.active {
    background: #667eea;
    width: 32px;
    border-radius: 6px;
}

.rm-dot.has-note {
    background: #ffc107;
    box-shadow: 0 0 0 2px rgba(255, 193, 7, 0.3);
}

.rm-dot.has-note.active {
    background: linear-gradient(135deg, #667eea 0%, #ffc107 100%);
}

/* Counter */
.rm-counter {
    text-align: center;
    padding: 0 0 20px 0;
    font-size: 16px;
    color: #666;
    font-weight: 500;
}

.rm-current {
    color: #667eea;
    font-weight: 700;
    font-size: 20px;
}

/* ===========================================
   RESPONSIVE
   =========================================== */

@media (max-width: 768px) {
    .rm-gallery {
        margin: 20px 10px;
    }
    
    .rm-image-container {
        height: 300px;
    }
    
    .rm-info {
        padding: 20px;
    }
    
    .rm-address {
        font-size: 20px;
    }
    
    .rm-nav {
        width: 40px;
        height: 40px;
        font-size: 24px;
        top: 150px;
    }
    
    .rm-prev {
        left: 10px;
    }
    
    .rm-next {
        right: 10px;
    }
    
    .rm-dots {
        gap: 8px;
    }
    
    .rm-dot {
        width: 10px;
        height: 10px;
    }
    
    .rm-dot.active {
        width: 24px;
    }
}

@media (max-width: 480px) {
    .rm-image-container {
        height: 250px;
    }
    
    .rm-address {
        font-size: 18px;
    }
    
    .rm-maps-btn {
        padding: 12px 20px;
        font-size: 14px;
    }
}

/* ===========================================
   MAP IFRAME STYLES (Google Maps interactivo)
   =========================================== */

.rm-map-container {
    position: relative;
    width: 100%;
    height: 600px;
    background: #e0e0e0;
    overflow: hidden;
}

.rm-map-iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.rm-no-api-key {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    background: #fff3cd;
    border: 2px dashed #ffc107;
}

.rm-no-api-key p {
    font-size: 18px;
    color: #856404;
    text-align: center;
    padding: 20px;
}

.rm-iframe-loader {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
    text-align: center;
    background: rgba(255, 255, 255, 0.95);
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
}

.rm-iframe-loader p {
    margin-top: 15px;
    font-size: 16px;
    color: #667eea;
    font-weight: 600;
}