* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body, html {
    height: 100%;
    width: 100%;
}

#map {
    height: 100vh;
    width: 100vw;
    z-index: 1; /* Leaflet usa z-index 400 internamente */
}

/* Sistema de Modales superpuestos */
.overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.hidden {
    display: none !important;
}

.modal {
    background: #fff;
    padding: 25px;
    border-radius: 12px;
    width: 90%;
    max-width: 400px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    text-align: center;
}

.modal h2, .modal h3 { margin-bottom: 15px; color: #333; }
.modal p, .modal small { color: #666; margin-bottom: 15px; display: block; }

input, textarea {
    width: 100%;
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 16px;
}

textarea { resize: vertical; height: 80px; }

button {
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 6px;
    background: #007bff;
    color: white;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.3s;
}

button:hover { background: #0056b3; }
.btn-cancel { background: #dc3545; margin-right: 10px; }
.btn-cancel:hover { background: #a71d2a; }
.modal-buttons { display: flex; justify-content: space-between; }