/* estilo.css · App del hotel. Móvil primero: letra y botones grandes. */
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { font-size: 20px; }
body {
  margin: 0; color: #1a1a1a; background: #f3f6f8; line-height: 1.35;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
header {
  position: sticky; top: 0; z-index: 2; display: flex; flex-wrap: wrap; gap: .3rem .8rem;
  align-items: center; justify-content: space-between; padding: .5rem .8rem;
  background: #0b5f8a; color: #fff; font-size: .9rem;
}
#sin-enviar { font-weight: 700; background: #fff; color: #0b5f8a; border-radius: 1rem; padding: .15rem .7rem; }
#sin-enviar.pendiente { background: #ffd54a; color: #4a3500; }
#red { font-weight: 700; }
main, #zona-voz { max-width: 40rem; margin: 0 auto; padding: .8rem; }
#zona-voz { padding-bottom: 0; }
h1 { font-size: 1.5rem; margin: .4rem 0 .4rem; }
h2 { font-size: 1.1rem; margin: 1.2rem 0 .5rem; color: #0b5f8a; }
.donde { margin: 0 0 .5rem; color: #4d5b64; font-size: .9rem; }
button {
  font: inherit; font-size: 1.1rem; min-height: 3.2rem; padding: .6rem 1rem; border: 0; border-radius: .6rem;
  background: #0b5f8a; color: #fff; cursor: pointer; touch-action: manipulation;
}
button:disabled { background: #9aa9b3; }
button.secundario { background: #dfe8ee; color: #0b5f8a; }
button.peligro { background: #b3261e; }
.grande { width: 100%; min-height: 4.2rem; font-size: 1.4rem; font-weight: 700; margin-top: .5rem; }
#b-hablar { background: #1b7a3a; }
#b-hablar:disabled { background: #9aa9b3; }
.botones { display: grid; grid-template-columns: repeat(auto-fill, minmax(9rem, 1fr)); gap: .6rem; }
.botones button { min-height: 4rem; }
.campo {
  display: grid; grid-template-columns: 1fr 6.5rem 3.4rem; align-items: center; gap: .5rem;
  padding: .35rem 0; border-bottom: 1px solid #dde5ea;
}
.unidad { color: #4d5b64; font-size: .9rem; }
input[type=text], textarea {
  font: inherit; font-size: 1.2rem; width: 100%; padding: .55rem .6rem;
  border: 2px solid #9fb3c0; border-radius: .5rem; background: #fff;
}
input.de-voz { border-color: #1b7a3a; background: #e7f6ec; }
.mensaje { min-height: 1.4rem; margin: .6rem 0; font-weight: 600; }
.mensaje.bien { color: #1b5e20; }
.mensaje.mal { color: #b3261e; }
#codigo { font-size: 1.8rem; letter-spacing: .2rem; text-transform: uppercase; text-align: center; }
.codigo-grande {
  font-size: 2.4rem; font-weight: 800; letter-spacing: .3rem; text-align: center; padding: 1rem;
  background: #fff; border: 3px dashed #0b5f8a; border-radius: .8rem; word-break: break-all;
}
ul.lista { list-style: none; padding: 0; margin: 0; }
ul.lista li { padding: .55rem .2rem; border-bottom: 1px solid #dde5ea; font-size: .95rem; }
li.sin-enviar { color: #7a5a00; }
li.tel { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem; }
.tel-dato { color: #4d5b64; font-size: .85rem; }
/* Pantalla general: un desplegable por zona (cerrados al abrir la app); se abre y se cierra al tocar su barra. */
details.zona { margin: .6rem 0; }
details.zona > summary {
  display: flex; align-items: center; justify-content: space-between; min-height: 3.6rem; padding: .6rem 1rem;
  border-radius: .6rem; background: #dfe8ee; color: #0b5f8a; font-size: 1.3rem; font-weight: 700;
  list-style: none; cursor: pointer; touch-action: manipulation; user-select: none;
}
details.zona > summary::-webkit-details-marker { display: none; }
details.zona > summary::after { content: "\25B8"; font-size: 1.2rem; }
details.zona[open] > summary { background: #0b5f8a; color: #fff; }
details.zona[open] > summary::after { content: "\25BE"; }
details.zona h3 { font-size: 1rem; margin: .8rem 0 .4rem; color: #0b5f8a; }
/* Botón «i» de la ficha: pequeño, al lado del sitio. */
.sitio { display: flex; gap: .3rem; }
.sitio > button:first-child { flex: 1; min-width: 0; }
button.info { flex: none; width: 2.4rem; min-height: 2.4rem; padding: 0; font-weight: 700; font-style: italic; }
.titulo { display: flex; align-items: center; justify-content: space-between; gap: .6rem; }
.titulo button.info { height: 2.4rem; }
.ficha {
  position: fixed; top: 0; right: 0; bottom: 0; left: 0; z-index: 5; display: flex; align-items: flex-start; justify-content: center;
  padding: .8rem; background: rgba(0, 0, 0, .45); overflow-y: auto;
}
.ficha-caja { width: 100%; max-width: 40rem; padding: .8rem; background: #fff; border-radius: .8rem; }
.ficha-caja h2 { margin-top: .2rem; }
.ficha-texto { font-weight: 700; }
/* Transparencia: elegir una opción (pulsar otra vez la elegida la quita). */
.campo-opciones { padding: .35rem 0; border-bottom: 1px solid #dde5ea; }
.opciones { display: grid; grid-template-columns: repeat(auto-fill, minmax(7rem, 1fr)); gap: .4rem; margin-top: .3rem; }
.opciones button { min-height: 2.8rem; font-size: 1rem; line-height: 1.15; padding: .3rem .4rem; }
button.elegido, button.si { background: #0b5f8a; color: #fff; }
/* Acciones: una fila por grupo; las que tienen cantidad con − y +, las otras con Sí/No. */
.accion {
  display: flex; flex-wrap: wrap; align-items: center; gap: .4rem .6rem;
  padding: .35rem 0; border-bottom: 1px solid #dde5ea;
}
.accion-texto { flex: 1 1 4rem; }
.contador { display: flex; align-items: center; gap: .3rem; margin-left: auto; }
.contador button { width: 2.8rem; min-height: 2.8rem; padding: 0; font-size: 1.4rem; }
.contador input[type=text] { width: 3rem; text-align: center; padding: .45rem .1rem; }
.contador .unidad { min-width: 2.6rem; }
.accion button.sino { min-width: 5rem; min-height: 2.8rem; margin-left: auto; }
.accion input.nota-otra { flex: 1 1 12rem; }
/* Fuera de lo que permite sanidad: aviso amarillo. */
input.fuera-sanidad { border-color: #c79100; background: #fff6d5; }
.campo-opciones.fuera-sanidad { background: #fff6d5; }
.aviso { margin: 1rem 0 .5rem; padding: .6rem .8rem; background: #fff3c4; border: 2px solid #e0b000; border-radius: .6rem; color: #4a3500; }
.aviso-titulo { margin: 0 0 .3rem; font-weight: 700; }
.aviso ul { margin: 0 0 .6rem; padding-left: 1.2rem; }
.aviso label { display: block; font-weight: 700; margin-bottom: .3rem; }
/* Historial: «← Sitios» y «Historial» en la fila de arriba; «Ver más» a lo ancho, del tamaño normal. */
.barra { display: flex; justify-content: space-between; gap: .6rem; }
button.ancho { width: 100%; margin-top: .5rem; }
/* Pedidos (Carlos 02-11 22:4x): al final de cada zona, cerrado; dentro, pedir y la lista con el estado de cada uno. */
details.pedidos { margin: 1rem 0 .3rem; border-top: 2px solid #dde5ea; }
details.pedidos > summary {
  display: flex; align-items: center; justify-content: space-between; min-height: 3.2rem; padding: .6rem 1rem;
  border: 2px solid #c5d5df; border-radius: .6rem; background: #fff; color: #0b5f8a; font-weight: 700;
  list-style: none; cursor: pointer; touch-action: manipulation; user-select: none;
}
details.pedidos .botones { grid-template-columns: repeat(auto-fill, minmax(8rem, 1fr)); }
details.pedidos .botones button { font-size: 1rem; line-height: 1.2; padding: .5rem .4rem; overflow-wrap: anywhere; }
details.pedidos > summary::-webkit-details-marker { display: none; }
details.pedidos > summary::after { content: "\25B8"; }
details.pedidos[open] > summary::after { content: "\25BE"; }
details.pedidos h4 { font-size: 1rem; margin: .8rem 0 .4rem; color: #0b5f8a; }
.cuantos { display: flex; align-items: center; gap: .6rem; margin: .6rem 0; }
.cuantos input[type=text] { width: 4.4rem; }
label.nota-pedido { display: block; }
label.nota-pedido span { display: block; font-weight: 600; margin-bottom: .2rem; }
.pedido-que { font-weight: 700; }
li.pedido .pedido-pie { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem .6rem; margin-top: .3rem; }
li.pedido .pedido-pie button { min-height: 2.8rem; font-size: 1rem; }
.estado-pedido { flex: 1 0 100%; font-weight: 700; }
.estado-pedido.pendiente { color: #b3261e; }
.estado-pedido.pedido { color: #7a5a00; }
.estado-pedido.llego { color: #1b5e20; }
button.aviso-pedidos { background: #ffd54a; color: #4a3500; }
/* Preventivos (Carlos 03-11): cada edificio, un desplegable como las zonas; dentro, cada tarea otro, blanco con borde.
   Revisión: «Correcto» verde y «Incorrecto» rojo lado a lado; «No se ha realizado» gris a lo ancho (como EISI). */
#b-preventivos { margin-top: 1rem; }
details.tarea { margin: .5rem 0; border: 2px solid #c5d5df; border-radius: .6rem; background: #fff; }
details.tarea > summary {
  display: flex; align-items: center; justify-content: space-between; gap: .6rem; min-height: 3.6rem; padding: .5rem .8rem;
  color: #0b5f8a; font-weight: 700; list-style: none; cursor: pointer; touch-action: manipulation; user-select: none;
}
details.tarea > summary::-webkit-details-marker { display: none; }
details.tarea[open] > summary { border-bottom: 1px solid #dde5ea; }
.cuenta { flex: none; font-size: .85rem; font-weight: 600; color: #4d5b64; }
.cuenta.completa { color: #1b5e20; font-weight: 700; }
.tarea-dentro { padding: .3rem .7rem .7rem; }
.tarea-codigo { display: flex; justify-content: flex-end; }
.codigo-tarea { font-size: .7rem; color: #6b7a83; }
button.codigo-tarea { min-height: 1.8rem; padding: .1rem .5rem; border-radius: .4rem; background: #eef3f6; color: #4d5b64; font-size: .7rem; }
.texto-eisi { margin: .3rem 0; padding: .4rem .6rem; border-radius: .4rem; background: #f3f6f8; color: #4d5b64; font-size: .85rem; }
.casilla { padding: .6rem 0; border-top: 1px solid #dde5ea; }
.casilla-nombre { font-size: 1.1rem; font-weight: 700; margin-bottom: .3rem; }
p.hoy { margin: .2rem 0 .4rem; font-weight: 700; }
p.hoy.correcto, p.hoy.hecho { color: #1b5e20; }
p.hoy.incorrecto { color: #b3261e; }
p.hoy.no_realizado { color: #4d5b64; }
.casilla input[data-observaciones] { font-size: 1rem; margin-bottom: .5rem; }
.numero { display: grid; grid-template-columns: 1fr auto 7rem; align-items: center; gap: .5rem; }
.revision { display: grid; grid-template-columns: 1fr 1fr; gap: .5rem; }
.numero button, .revision button, button.no-realizado { min-height: 3.6rem; font-weight: 700; }
button.correcto { background: #2e6b1f; }
button.incorrecto { background: #b3261e; }
button.no-realizado { width: 100%; margin-top: .5rem; background: #6d7478; }
.numero button:disabled, .revision button:disabled, button.no-realizado:disabled { opacity: .6; }
.motivos { display: grid; gap: .4rem; margin-top: .5rem; padding: .5rem; border: 2px solid #6d7478; border-radius: .6rem; background: #f3f6f8; }
.motivos-titulo { margin: 0; font-weight: 700; }
.motivos button { min-height: 3rem; font-size: 1rem; text-align: left; }
/* Casilla de dato real (Carlos 03-11): sin texto; a la vista, la mitad (11:5x: 22 px), en el centro de su zona de toque
   de 44 px para el dedo (label.toque); en el sitio, pegada a la derecha de su nombre (el «i» sigue a la derecha del
   todo); en Preventivos, bajo el título. Las del Excel, iguales. En el historial, ✓ verde. */
input.casilla-real, #p-excel input[type=checkbox] { flex: none; width: 1.1rem; height: 1.1rem; margin: 0; accent-color: #1b7a3a; cursor: pointer; }
label.toque { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 2.2rem; height: 2.2rem; cursor: pointer; }
.titulo label.toque { margin: 0 auto 0 -.55rem; }
#p-preventivos label.toque { display: flex; margin: .2rem 0 .4rem -.55rem; }
li .real { color: #1b7a3a; font-weight: 700; }
/* «Descargar» (en «Descargar Excel»): un enlace con aspecto de botón; «principal», azul como «Guardar». */
a.boton {
  display: flex; align-items: center; justify-content: center; text-decoration: none;
  padding: .6rem 1rem; border-radius: .6rem; background: #dfe8ee; color: #0b5f8a;
}
a.boton.principal { background: #0b5f8a; color: #fff; }
/* «Descargar Excel» (Carlos 03-11 11:3x): Dónde, Desde y Hasta grandes; cada grupo de «Qué sale», un desplegable blanco
   con su casilla en la barra (se marca sin abrirlo); las casillas, como la de dato real: 22 px con 44 para el dedo. */
.excel-etiqueta { display: block; margin: .8rem 0 .3rem; font-weight: 700; color: #0b5f8a; }
#p-excel select, #p-excel input[type=date] {
  font: inherit; font-size: 1.1rem; font-weight: 400; width: 100%; min-height: 3.2rem; padding: .45rem .6rem;
  border: 2px solid #9fb3c0; border-radius: .5rem; background: #fff; color: #1a1a1a;
}
.excel-nota { margin: .3rem 0 0; color: #4d5b64; font-size: .85rem; }
/* Desde y Hasta, cada una en su fila con su nombre a la izquierda (lado a lado no caben en el móvil). */
.fechas .excel-etiqueta { display: grid; grid-template-columns: 4.6rem minmax(0, 1fr); align-items: center; gap: .4rem;
  margin: .5rem 0 0; }
.excel-casilla { display: flex; align-items: center; gap: .7rem; min-height: 3rem; cursor: pointer; }
/* Su caja, alineada con la de los grupos; el margen es parte de su zona de toque. */
#p-excel .excel-casilla > input { margin: 0 .55rem; }
.excel-todo { padding: 0 .9rem; font-size: 1.15rem; font-weight: 700; }
details.grupo-excel { margin: .5rem 0; border: 2px solid #c5d5df; border-radius: .6rem; background: #fff; }
details.grupo-excel > summary {
  display: flex; align-items: center; gap: .7rem; min-height: 3.6rem; padding: .5rem .8rem;
  color: #0b5f8a; font-weight: 700; list-style: none; cursor: pointer; touch-action: manipulation; user-select: none;
}
details.grupo-excel > summary > span { flex: 1; }
details.grupo-excel > summary::-webkit-details-marker { display: none; }
details.grupo-excel > summary::after { content: "\25B8"; }
details.grupo-excel[open] > summary::after { content: "\25BE"; }
details.grupo-excel[open] > summary { border-bottom: 1px solid #dde5ea; }
.cosas-excel { padding: .3rem .8rem .6rem; }
