:root {
  --azul: #123a6b; --azul2: #1d5aa6; --fondo: #f3f5f8; --carta: #fff; --texto: #17202b; --suave: #64707f;
  --linea: #dfe4ea; --verde: #17803d; --verde-f: #e3f5e9; --ama: #a86400; --ama-f: #fff3d6; --rojo: #b3261e; --rojo-f: #fde7e5;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font: 16px/1.45 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; background: var(--fondo); color: var(--texto); }
a { color: var(--azul2); }
.barra { background: var(--azul); color: #fff; display: flex; align-items: center; justify-content: space-between; padding: 10px 16px; padding-top: max(10px, env(safe-area-inset-top)); position: sticky; top: 0; z-index: 5; }
.marca { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font-weight: 600; }
.marca img { height: 26px; filter: brightness(0) invert(1); }
#menu { display: flex; gap: 6px; align-items: center; }
#menu a, #menu button { color: #fff; background: rgba(255,255,255,.14); border: 0; border-radius: 8px; padding: 7px 11px; font: inherit; font-size: 14px; text-decoration: none; cursor: pointer; }
main { max-width: 860px; margin: 0 auto; padding: 16px 16px 60px; }
h1 { font-size: 22px; margin: 4px 0 14px; }
h2 { font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--suave); margin: 26px 0 8px; display: flex; justify-content: space-between; align-items: center; }
.cargando, .vacio { color: var(--suave); padding: 18px 4px; }
.carta { background: var(--carta); border: 1px solid var(--linea); border-radius: 14px; padding: 14px 16px; margin-bottom: 10px; }
a.carta { display: block; text-decoration: none; color: inherit; }
.fila { display: flex; align-items: center; gap: 12px; }
.fila > .cuerpo { flex: 1; min-width: 0; }
.titulo { font-weight: 600; }
.sub { color: var(--suave); font-size: 14px; }
.patente { font: 600 13px ui-monospace, Menlo, monospace; background: #111; color: #fff; padding: 2px 7px; border-radius: 5px; letter-spacing: .05em; white-space: nowrap; }
.punto { width: 14px; height: 14px; border-radius: 50%; flex: none; }
.verde .punto, .punto.verde { background: var(--verde); } .amarillo .punto, .punto.amarillo { background: #e09a00; } .rojo .punto, .punto.rojo { background: var(--rojo); }
.semaforo { border-radius: 16px; padding: 18px; margin-bottom: 12px; font-size: 21px; font-weight: 700; display: flex; gap: 14px; align-items: center; }
.semaforo small { display: block; font-size: 14px; font-weight: 500; margin-top: 2px; }
.semaforo.verde { background: var(--verde-f); color: var(--verde); } .semaforo.amarillo { background: var(--ama-f); color: var(--ama); } .semaforo.rojo { background: var(--rojo-f); color: var(--rojo); }
.semaforo .luz { width: 38px; height: 38px; border-radius: 50%; background: currentColor; flex: none; }
.item { display: flex; gap: 10px; align-items: baseline; padding: 9px 0; border-bottom: 1px solid var(--linea); }
.item:last-child { border-bottom: 0; }
.item .punto { align-self: center; }
.item .cuerpo { flex: 1; min-width: 0; }
.item.rojo .sub { color: var(--rojo); font-weight: 600; } .item.amarillo .sub { color: var(--ama); font-weight: 600; }
.botones { display: flex; flex-wrap: wrap; gap: 8px; }
button, .boton { font: inherit; border: 1px solid var(--linea); background: #fff; color: var(--texto); border-radius: 10px; padding: 10px 14px; cursor: pointer; text-decoration: none; display: inline-block; }
button.primario, .boton.primario { background: var(--azul2); border-color: var(--azul2); color: #fff; font-weight: 600; }
button.chico, .boton.chico { padding: 5px 10px; font-size: 13px; border-radius: 8px; text-transform: none; letter-spacing: 0; font-weight: 500; }
button.peligro { color: var(--rojo); }
.doc { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--linea); }
.doc:last-child { border-bottom: 0; }
.doc .cuerpo { flex: 1; min-width: 0; }
.tel { display: block; font-size: 18px; font-weight: 600; padding: 6px 0; text-decoration: none; }
form label { display: block; font-size: 14px; color: var(--suave); margin: 12px 0 4px; }
input, select, textarea { width: 100%; font: inherit; padding: 11px 12px; border: 1px solid #c5ccd6; border-radius: 10px; background: #fff; color: var(--texto); }
input[type=checkbox] { width: auto; margin-right: 8px; }
label.check { display: flex; align-items: center; color: var(--texto); font-size: 16px; }
textarea { min-height: 90px; }
.error { color: var(--rojo); margin-top: 10px; font-weight: 600; }
.login { max-width: 380px; margin: 8vh auto 0; }
.pestanas { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.pestanas button { white-space: nowrap; border-radius: 999px; padding: 8px 14px; }
.pestanas button.activa { background: var(--azul); color: #fff; border-color: var(--azul); }
.etiqueta { font-size: 12px; padding: 2px 8px; border-radius: 999px; background: #e8ecf1; color: var(--suave); white-space: nowrap; }
.etiqueta.rojo { background: var(--rojo-f); color: var(--rojo); } .etiqueta.verde { background: var(--verde-f); color: var(--verde); } .etiqueta.amarillo { background: var(--ama-f); color: var(--ama); }
#modal { position: fixed; inset: 0; background: rgba(10,20,35,.5); z-index: 20; display: flex; align-items: flex-end; justify-content: center; }
#modal[hidden] { display: none; }
#modal .caja { background: #fff; width: 100%; max-width: 520px; max-height: 92vh; overflow: auto; border-radius: 18px 18px 0 0; padding: 18px 18px calc(18px + env(safe-area-inset-bottom)); }
#modal h3 { margin: 0 0 6px; font-size: 19px; }
#modal .pie { display: flex; gap: 8px; margin-top: 18px; }
#modal .pie button { flex: 1; }
pre.aviso { white-space: pre-wrap; font-family: inherit; font-size: 14px; line-height: 1.6; margin: 0; }
.qr { text-align: center; } .qr svg, .qr img { width: 220px; height: 220px; }
@media (min-width: 640px) { #modal { align-items: center; } #modal .caja { border-radius: 18px; } .dos { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; } }
@media print { .barra, .noimp { display: none !important; } body { background: #fff; } }
@media (max-width: 420px) { .marca span { display: none; } }
