/* GÉNESIS Campo · pensado para el sol y para dedos con guantes: letra grande, alto contraste, botones ≥ 48 px. */
:root {
  --verde: #1b7f3b; --verde-osc: #10502a; --fondo: #f4f6f4; --tinta: #1a1f1c; --suave: #4d5752; --borde: #dfe5e1;
  --borde-f: #b9c6be; --alerta-bg: #fff1cc; --alerta: #5a3d00; --error-bg: #fdecea; --error: #7a1610; --rojo: #b42318;
  --ok-bg: #e6f4ea;
  font-family: "Atkinson Hyperlegible", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--tinta); background: var(--fondo); font-size: 17px; line-height: 1.35;
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; background: var(--fondo); }
#app { max-width: 520px; margin: 0 auto; min-height: 100vh; display: flex; flex-direction: column; }
.cargando { padding: 40px 20px; text-align: center; color: var(--suave); }
h1 { margin: 0; font-size: 21px; }
p { margin: 0; }
button, input, select { font: inherit; color: inherit; }
.cab { background: var(--verde); color: #fff; padding: 14px 16px; display: flex; align-items: center; gap: 8px;
       padding-top: max(14px, env(safe-area-inset-top)); }
.cab p { font-size: 14px; opacity: .92; }
.cab.inicio { justify-content: space-between; padding: 18px 20px; }
.marca { font-size: 13px; letter-spacing: 1px; }
.icono { background: none; border: 0; color: #fff; width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; }
.banda { display: flex; gap: 10px; align-items: center; padding: 10px 16px; font-size: 15px; }
.banda.alerta { background: var(--alerta-bg); color: var(--alerta); }
.banda.ok { background: var(--ok-bg); color: var(--verde-osc); }
.pila { flex-grow: 1; padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.tarjeta { background: #fff; border: 1px solid var(--borde); border-radius: 14px; padding: 14px; display: flex; flex-direction: column; gap: 6px; }
.suave { color: var(--suave); font-size: 15px; }
.verde { color: var(--verde-osc); font-size: 14px; }
.rojo { color: var(--rojo); }
.g24 { font-size: 24px; }
.g26 { font-size: 26px; font-weight: 700; }
.g26 small { font-size: 18px; font-weight: 400; color: var(--suave); }
.fila { display: flex; align-items: center; gap: 8px; }
.fila-sb { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
label { font-weight: 700; font-size: 16px; }
label.fila { font-weight: 400; background: #fff; border: 1px solid var(--borde); border-radius: 12px; padding: 12px; }
label.fila input { width: 26px; height: 26px; flex-shrink: 0; }
input { min-height: 52px; border-radius: 12px; border: 2px solid var(--borde-f); padding: 0 12px; background: #fff; width: 100%; font-size: 18px; }
input:focus-visible, button:focus-visible { outline: 3px solid #2563eb; outline-offset: 2px; }
input.grande { font-size: 24px; font-weight: 700; letter-spacing: 2px; text-align: center; }
.primario, .secundario { min-height: 60px; border-radius: 14px; font-size: 19px; font-weight: 700; padding: 0 16px; width: 100%; }
.primario { background: var(--verde); color: #fff; border: 0; }
.primario.grande { min-height: 76px; font-size: 20px; display: flex; align-items: center; justify-content: center; gap: 12px; }
.primario:disabled { background: #c4d3c8; color: #3a443e; }
.secundario { background: #fff; color: var(--verde-osc); border: 2px solid var(--verde); }
.secundario.fila-sb { color: var(--tinta); border: 1px solid var(--borde); font-weight: 400; }
.enlace { background: none; border: 0; color: var(--verde-osc); font-weight: 700; text-decoration: underline; min-height: 48px; }
.enlace.rojo { color: var(--rojo); }
.chico { min-height: 44px; min-width: 52px; border-radius: 10px; border: 2px solid var(--borde-f); background: #fff; font-weight: 700; padding: 0 10px; }
.burbuja { background: var(--verde-osc); color: #fff; border-radius: 999px; min-width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; font-weight: 700; padding: 0 8px; }
.burbuja.roja { background: var(--rojo); }
.chip { font-size: 14px; font-weight: 700; padding: 6px 10px; border-radius: 999px; white-space: nowrap; }
.chip.alerta { background: var(--alerta-bg); color: var(--alerta); }
.chip.ok { background: var(--ok-bg); color: var(--verde-osc); }
.chip.error { background: var(--error-bg); color: var(--error); }
.msg { border-radius: 12px; padding: 12px; font-size: 16px; display: flex; flex-direction: column; gap: 10px; }
.msg.ok { background: var(--ok-bg); color: var(--verde-osc); border: 2px solid var(--verde); }
.msg.alerta { background: var(--alerta-bg); color: var(--alerta); border: 2px solid #c98500; }
.msg.error { background: var(--error-bg); color: var(--error); border: 2px solid var(--rojo); }
.lista { display: flex; flex-direction: column; gap: 8px; }
.item { background: #fff; border: 1px solid var(--borde); border-radius: 12px; padding: 12px; display: flex; justify-content: space-between; gap: 10px; align-items: center; flex-wrap: wrap; }
.item > div:first-child { display: flex; flex-direction: column; gap: 2px; }
.botones, .chips { display: flex; gap: 6px; flex-wrap: wrap; }
.pestanas { display: flex; gap: 4px; background: var(--verde); padding: 0 12px; }
.pestanas button { flex: 1; background: none; border: 0; color: #fff; padding: 10px 0; border-radius: 10px 10px 0 0; font-size: 15px; display: flex; flex-direction: column; align-items: center; min-height: 52px; }
.pestanas button small { font-size: 12px; opacity: .9; }
.pestanas button.activa { background: var(--fondo); color: var(--verde-osc); font-weight: 700; }
.barra { width: 100%; height: 10px; border-radius: 99px; overflow: hidden; appearance: none; border: 0; background: var(--borde); }
.barra::-webkit-progress-bar { background: var(--borde); border-radius: 99px; }
.barra::-webkit-progress-value { background: var(--verde); border-radius: 99px; }
.barra::-moz-progress-bar { background: var(--verde); border-radius: 99px; }
.codigos { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 5px; }
.codigo { min-height: 50px; border-radius: 10px; font-size: 18px; font-weight: 700; background: var(--fondo); border: 2px solid #c4d3c8; }
.codigo.activo { background: var(--verde); color: #fff; border-color: var(--verde-osc); }
.campo { background: #fff; border: 1px solid var(--borde); border-radius: 14px; padding: 10px 12px; display: flex; align-items: center; gap: 8px; }
.campo.con-error { border: 2px solid var(--rojo); }
.campo > div { display: flex; flex-direction: column; flex-grow: 1; }
.campo label { font-size: 20px; }
.campo .suave { font-size: 13px; }
.campo input { width: 78px; text-align: center; font-size: 24px; font-weight: 700; padding: 0 4px; }
.paso { width: 52px; height: 52px; flex-shrink: 0; border-radius: 12px; border: 2px solid var(--borde-f); background: #fff; font-size: 26px; }
details { background: #fff; border: 1px solid var(--borde); border-radius: 12px; padding: 10px 12px; }
summary { font-weight: 700; min-height: 32px; cursor: pointer; }
.pie { padding: 10px 16px; padding-bottom: max(14px, env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 6px;
       position: sticky; bottom: 0; background: var(--fondo); border-top: 1px solid var(--borde); }
.fila2 { display: flex; gap: 10px; align-items: center; }
.fila2 .secundario { flex: 2; min-height: 52px; font-size: 17px; }
.fila2 .enlace { flex: 1; }
