/* /fenia/reportar: el reporte ciudadano en una pantalla (views/pages/fenia-reportar.ejs).
 *
 * Pensado para el pulgar y para la lluvia: nada que tocar mide menos de 48 px,
 * los campos van a 16 px (con menos, el iPhone hace zoom al escribir y descuadra
 * la página) y el botón de enviar queda pegado abajo, siempre a la vista.
 * Violeta = el color de los reportes en el mapa de FENIA.
 */
.rr-cuerpo { margin: 0; background: #f6f5fb; color: #101828; font-family: Inter, -apple-system, 'Segoe UI', Arial, sans-serif; -webkit-text-size-adjust: 100%; }
.rr-barra { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 16px; padding-top: max(10px, env(safe-area-inset-top)); background: #fff; border-bottom: 1px solid #e4e2ee; position: sticky; top: 0; z-index: 5; }
.rr-volver { display: inline-flex; align-items: center; min-height: 44px; padding: 0 6px; font-size: 16px; font-weight: 700; color: #0b6e64; text-decoration: none; }
.rr-marca { font-size: 12.5px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: #6d28d9; }
.rr { max-width: 560px; margin: 0 auto; padding: 16px 16px 150px; }
.rr-h { margin: 4px 0 12px; font-size: 28px; line-height: 1.15; letter-spacing: -.01em; }

.rr-para { margin: -4px 0 14px; font-size: 15px; line-height: 1.45; color: #475467; }

/* La emergencia en una franja: el aviso en una línea y los tres números al lado, cada uno de 48 px. */
.rr-sos { padding: 10px 12px; border-radius: 14px; background: #fdf1f1; border: 1px solid #f0b8b8; }
.rr-sos b { display: block; font-size: 14px; line-height: 1.3; color: #7f1d1d; }
.rr-sos-nums { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 8px; }
.rr-sos-nums a { display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 48px; border-radius: 12px; background: #fff; border: 1px solid #f0b8b8; color: #7f1d1d; font-size: 12.5px; text-decoration: none; }
.rr-sos-nums strong { font-size: 18px; line-height: 1.1; color: #b91c1c; }

.rr-vivo { display: flex; align-items: center; gap: 9px; margin: 0 0 12px; padding: 10px 12px; border-radius: 12px; background: #efe8fd; color: #3b1a78; font-size: 14.5px; font-weight: 600; line-height: 1.35; }
.rr-vivo::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: #6d28d9; flex: none; }
.rr-vivo[hidden], .rr-vuelve[hidden], .rr-zona[hidden], .rr-boton[hidden] { display: none; }

/* «¿Sigue igual?»: al volver (arriba) y al terminar el reporte. */
.rr-vuelve { display: grid; gap: 8px; margin-top: 14px; padding: 14px; border-radius: 14px; background: #fff; border: 1.5px solid #6d28d9; font-size: 15px; line-height: 1.4; color: #344054; }
.rr-vuelve b { color: #101828; }
.rr-seguir { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.rr-seguir button { min-height: 48px; padding: 4px; border-radius: 12px; border: 1.5px solid #cfcbe0; background: #fff; color: #101828; font: inherit; font-size: 14.5px; font-weight: 600; cursor: pointer; }
.rr-seguir button.on { border-color: #0b6e64; background: #e6f4f1; color: #0b6e64; }
.rr-seguir button:disabled { opacity: .6; }
.rr-seguir-msg { margin: 0; font-size: 14.5px; font-weight: 600; color: #0b6e64; }
.rr-seguir-msg:empty { display: none; }

.rr-priv { margin: -12px 0 0; font-size: 13.5px; color: #475467; }
.rr-priv summary { min-height: 44px; display: flex; align-items: center; color: #4c1d95; font-weight: 600; cursor: pointer; }
.rr-priv p { margin: 0 0 6px; line-height: 1.5; }

.rr-cargando, .rr-cerrado { margin: 22px 0; font-size: 16px; line-height: 1.5; color: #475467; }
.rr-form { display: grid; gap: 22px; margin-top: 22px; }
.rr-form[hidden] { display: none; }   /* sin esto, display:grid le gana al atributo y el formulario seguía a la vista tras enviar */
.rr-paso { border: 0; margin: 0; padding: 0; min-width: 0; display: grid; gap: 10px; }
.rr-paso legend, .rr-leyenda { margin: 0 0 2px; padding: 0; font-size: 18px; font-weight: 700; display: flex; align-items: center; gap: 10px; }
.rr-paso legend span, .rr-leyenda span { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: #6d28d9; color: #fff; font-size: 15px; font-weight: 700; flex: none; }
.rr-paso legend { margin-bottom: 10px; }

/* Los tipos: seis fichas grandes, dos por fila. El radio queda encima, invisible, para que toda la ficha se toque. */
.rr-tipos { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.rr-tipos .ef-rep-chip { position: relative; display: block; }
.rr-tipos .ef-rep-chip input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.rr-tipos .ef-rep-chip span { display: flex; align-items: center; min-height: 76px; padding: 10px 12px; border-radius: 14px; border: 2px solid #dcd9ea; background: #fff; font-size: 15.5px; font-weight: 600; line-height: 1.25; }
.rr-tipos .ef-rep-chip input:checked + span { border-color: #6d28d9; background: #efe8fd; box-shadow: 0 0 0 2px #6d28d9 inset; }
.rr-tipos .ef-rep-chip input:focus-visible + span { outline: 3px solid #6d28d9; outline-offset: 2px; }

.rr-gps { width: 100%; min-height: 56px; border-radius: 14px; border: 2px solid #0b6e64; background: #fff; color: #0b6e64; font: inherit; font-size: 17px; font-weight: 700; cursor: pointer; }
.rr-gps.listo { background: #e6f4f1; }
.rr-donde { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.rr-donde .rr-gps { font-size: 15.5px; padding: 6px 8px; line-height: 1.2; }
.rr-gps--mapa { border-color: #6d28d9; color: #4c1d95; }
.rr-gps--mapa.listo { background: #efe8fd; }
.rr-mapa { position: relative; display: grid; gap: 10px; }
.rr-mapa[hidden] { display: none; }
.rr-mapa-lienzo { height: 300px; border-radius: 14px; border: 1.5px solid #cfcbe0; background: #e8e6f2; z-index: 0; }
/* El pin: fijo al centro del mapa, con la punta en el punto exacto. No recibe toques: el mapa se mueve debajo. */
.rr-mapa-caja { position: relative; }
.rr-mapa-buscar { display: grid; grid-template-columns: 1fr auto; gap: 8px; }
.rr-mapa-buscar input { min-height: 48px; border-radius: 12px; border: 1.5px solid #cfcbe0; padding: 0 12px; font-size: 16px; min-width: 0; }
.rr-mapa-buscar button { min-height: 48px; border-radius: 12px; border: 0; background: #4c1d95; color: #fff; font-size: 15.5px; font-weight: 600; padding: 0 16px; }
.rr-mapa-res { display: grid; gap: 6px; }
.rr-mapa-res:empty { display: none; }
.rr-mapa-res button { text-align: left; border: 1.5px solid #cfcbe0; background: #fff; border-radius: 10px; padding: 9px 12px; font-size: 15px; color: #1d2939; }
.rr-mapa-res button small { display: block; color: #667085; font-size: 13px; }
.rr-mapa-res p { margin: 0; font-size: 14.5px; color: #475467; }
.rr-mapa-mira { position: absolute; left: 50%; top: 150px; transform: translate(-50%, -100%); font-size: 44px; line-height: 1; pointer-events: none; z-index: 2; filter: drop-shadow(0 3px 4px rgba(0,0,0,.35)); }
.rr-mapa-ayuda { margin: 0; font-size: 14.5px; color: #475467; }
/* El botón va DENTRO del mapa, abajo: así se confirma sin bajar la página (el botón de enviar tapa lo que queda debajo). */
.rr-mapa .rr-boton { position: absolute; left: 10px; right: 10px; top: 238px; width: auto; max-width: none; min-height: 52px; z-index: 3; background: #6d28d9; box-shadow: 0 4px 14px rgba(0,0,0,.28); }
.rr-gps.buscando { opacity: .7; }
.rr-ubic { margin: 0; font-size: 14.5px; line-height: 1.4; color: #0b6e64; font-weight: 600; }
.rr-ubic:empty { display: none; }
.rr-dist, .rr-desc { display: grid; gap: 6px; font-size: 14.5px; font-weight: 600; color: #475467; }
.rr-form input[type=text], .rr-form textarea { font: inherit; font-size: 16px; font-weight: 400; color: #101828; min-height: 52px; padding: 12px 14px; border-radius: 12px; border: 1.5px solid #cfcbe0; background: #fff; width: 100%; box-sizing: border-box; }
.rr-form textarea { resize: vertical; min-height: 96px; }
.rr-form input[type=text]:focus, .rr-form textarea:focus { outline: 3px solid #c4b5fd; border-color: #6d28d9; }
.rr-sugs { display: flex; flex-wrap: wrap; gap: 8px; }
.rr-sugs:empty { display: none; }
.rr-sugs .ef-rep-sug { font: inherit; font-size: 15px; min-height: 44px; padding: 8px 14px; border-radius: 100px; border: 1.5px dashed #6d28d9; background: #fff; color: #4c1d95; cursor: pointer; }

.rr-mas summary { min-height: 48px; display: flex; align-items: center; font-size: 16px; font-weight: 600; color: #4c1d95; cursor: pointer; }
.rr-mas summary em { font-style: normal; font-weight: 400; color: #667085; margin-left: 6px; }
.rr-fotos { display: grid; gap: 8px; }
.rr-leyenda em { font-style: normal; font-weight: 400; font-size: 15px; color: #667085; }
.rr-fotos[hidden] { display: none; }
.rr-fotos small { font-size: 13.5px; color: #667085; }
.rr-foto-botones { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.rr-foto-btn--cam { border-style: solid; border-width: 2px; background: #efe8fd; }
.rr-foto-lista .ef-rep-foto-quitar { margin-left: auto; min-height: 40px; padding: 0 12px; border-radius: 10px; border: 1px solid #cfcbe0; background: #fff; font: inherit; font-size: 14px; color: #b91c1c; cursor: pointer; }
.rr-foto-btn { position: relative; display: flex; align-items: center; justify-content: center; min-height: 52px; border-radius: 12px; border: 1.5px dashed #6d28d9; color: #4c1d95; font-size: 16px; font-weight: 600; cursor: pointer; }
.rr-foto-btn input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.rr-foto-lista { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.rr-foto-lista li { display: flex; align-items: center; gap: 10px; font-size: 14px; color: #475467; }
.rr-foto-lista img { width: 52px; height: 52px; object-fit: cover; border-radius: 8px; flex: none; }
.rr-foto-lista .ef-rep-foto-ok { color: #047857; }
.rr-foto-lista .ef-rep-foto-no { color: #b91c1c; }

.rr-trampa { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.rr-acepta { display: flex; gap: 12px; align-items: flex-start; padding: 14px; border-radius: 14px; border: 1.5px solid #cfcbe0; background: #fff; font-size: 14.5px; line-height: 1.45; color: #344054; cursor: pointer; }
.rr-acepta input { width: 26px; height: 26px; margin: 0; flex: none; accent-color: #6d28d9; }
.rr-nota { margin: -10px 0 0; font-size: 13.5px; color: #667085; }
.rr-nota a, .rr-wsp a { color: #0b6e64; font-weight: 600; }

.rr-enviar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 6; padding: 10px 16px; padding-bottom: max(12px, env(safe-area-inset-bottom)); background: rgba(255,255,255,.96); border-top: 1px solid #e4e2ee; box-shadow: 0 -6px 18px rgba(16,24,40,.08); }
.rr-enviar .ef-susc-msg { max-width: 528px; margin: 0 auto 8px; font-size: 14.5px; line-height: 1.4; min-height: 0; }
.rr-enviar .ef-susc-msg:empty { display: none; }
.rr-enviar .ef-susc-msg--ok { color: #0b6e64; font-weight: 600; }
.rr-enviar .ef-susc-msg--error { color: #b91c1c; font-weight: 600; }
.rr-boton { display: flex; align-items: center; justify-content: center; width: 100%; max-width: 528px; margin: 0 auto; min-height: 56px; border: 0; border-radius: 14px; background: #0b6e64; color: #fff; font: inherit; font-size: 18px; font-weight: 700; text-decoration: none; cursor: pointer; box-sizing: border-box; }
.rr-boton[data-falta] { background: #98a2b3; }
.rr-boton:disabled { opacity: .7; }
.rr-boton--claro { background: #fff; color: #0b6e64; border: 2px solid #0b6e64; margin-top: 10px; }

/* La pantalla de «listo»: lo que se recibe a cambio de reportar. */
.rr-listo { margin-top: 22px; display: grid; gap: 14px; }
.rr-listo[hidden] { display: none; }
.rr-listo-cab { display: flex; gap: 14px; align-items: flex-start; padding: 16px; border-radius: 18px; background: #fff; border: 1.5px solid #cfcbe0; }
.rr-listo-ok { width: 52px; height: 52px; flex: none; border-radius: 50%; background: #0b6e64; color: #fff; font-size: 28px; display: grid; place-items: center; }
.rr-listo h2 { margin: 0 0 4px; font-size: 21px; }
.rr-listo-cab p { margin: 0 0 8px; font-size: 15.5px; line-height: 1.45; color: #344054; }
.rr-listo > p { margin: 0; font-size: 15.5px; line-height: 1.5; color: #344054; white-space: pre-line; }
.rr-listo-nivel { display: inline-block; padding: 4px 11px; border-radius: 100px; background: #f2f4f7; color: #475467; font-size: 13px; font-weight: 700; }
.rr-listo-nivel.si { background: #e6f4f1; color: #0b6e64; }
.rr-listo-nivel:empty { display: none; }
.rr-listo .rr-foto-lista:empty { display: none; }
.rr-listo .rr-boton--claro { margin-top: 0; }
.rr-zona { padding: 16px; border-radius: 18px; background: #fff; border: 1.5px solid #cfcbe0; display: grid; gap: 10px; }
.rr-zona h3 { margin: 0; font-size: 13px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; color: #6d28d9; }
.rr-zona p { margin: 0; font-size: 14.5px; line-height: 1.45; color: #475467; }
.rr-zona ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.rr-zona-filas li { display: flex; gap: 10px; font-size: 15px; line-height: 1.4; color: #101828; }
.rr-zona-filas li > span { flex: none; width: 24px; text-align: center; }
.rr-zona-filas small { display: block; margin-top: 2px; font-size: 12.5px; color: #667085; }
.rr-zona-consejos li { position: relative; padding-left: 18px; font-size: 15px; line-height: 1.4; color: #101828; }
.rr-zona-consejos li::before { content: ""; position: absolute; left: 4px; top: .55em; width: 6px; height: 6px; border-radius: 50%; background: #6d28d9; }
.rr-zona .rr-zona-sos { padding: 9px 11px; border-radius: 10px; background: #fdf1f1; color: #7f1d1d; font-size: 13.5px; font-weight: 600; }
.rr-boton--wsp { background: #128c4a; }
.rr-wsp { margin: 26px 0 0; font-size: 14.5px; line-height: 1.5; color: #475467; }

/* La franja «sin conexión» de fenia-pwa.js, que aquí no trae su hoja. */
.ef-sinred { margin: 0; padding: 10px 16px; background: #7c2d12; color: #fff; font-size: 14px; line-height: 1.4; }
