* { box-sizing: border-box; }
body { margin: 0; font-family: 'Open Sans', Arial, sans-serif; color: #333; background: #f4f6f6; }
header { background: #fff; border-bottom: 3px solid #00bc9b; padding: 10px 20px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; }
.marca { display: flex; align-items: center; gap: 8px; font-size: 20px; }
.marca img { height: 34px; }
.marca b { color: #00bc9b; }
.marca em { font-style: normal; background: #00bc9b; color: #fff; border-radius: 4px; padding: 2px 8px; font-size: 14px; }
nav a { color: #555; text-decoration: none; margin-left: 16px; font-weight: 700; }
nav a:hover, nav a.activo { color: #00bc9b; }
main { max-width: 1000px; margin: 0 auto; padding: 20px; }
h1 { font-weight: 300; display: flex; align-items: center; gap: 15px; }
.tarjeta { background: #fff; border-radius: 8px; padding: 20px; box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.angosta { max-width: 380px; margin: 40px auto; }
label { display: block; margin-bottom: 12px; font-size: 14px; flex: 1; min-width: 150px; }
label.ancho { flex: 2; }
input, select { display: block; width: 100%; padding: 8px; margin-top: 4px; border: 1px solid #ccc; border-radius: 4px; font: inherit; }
input:focus, select:focus { outline: 2px solid #00bc9b; border-color: transparent; }
.fila { display: flex; flex-wrap: wrap; gap: 0 15px; }
fieldset { border: 1px solid #e2e2e2; border-radius: 6px; margin: 0 0 15px; padding: 10px 15px 0; }
legend { color: #00bc9b; font-weight: 700; padding: 0 5px; }
button, .boton { background: #00bc9b; color: #fff; border: 0; border-radius: 4px; padding: 9px 18px; font: inherit; font-weight: 700; cursor: pointer; text-decoration: none; display: inline-block; font-size: 14px; }
button:hover, .boton:hover { background: #009c81; }
.secundario { background: #fff; color: #00bc9b; border: 1px solid #00bc9b; }
.secundario:hover { background: #e8f8f5; }
.chico { padding: 4px 10px; font-size: 13px; }
.nota { color: #777; font-size: 13px; }
.cuadros { display: flex; flex-wrap: wrap; gap: 15px; margin-bottom: 20px; }
.cuadro { background: #fff; border-radius: 8px; padding: 15px 20px; flex: 1; min-width: 180px; box-shadow: 0 1px 4px rgba(0,0,0,.08); }
.cuadro span, .cuadro small { display: block; color: #777; font-size: 13px; }
.cuadro strong { display: block; font-size: 28px; color: #00bc9b; margin: 4px 0; }
.tabla { overflow-x: auto; background: #fff; border-radius: 8px; box-shadow: 0 1px 4px rgba(0,0,0,.08); }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 9px 12px; border-bottom: 1px solid #eee; white-space: nowrap; }
th { background: #00bc9b; color: #fff; font-weight: 700; }
td.num, th.num { text-align: right; }
tr.baja td { color: #aaa; }
.errores { background: #fdecea; color: #b3261e; border-radius: 6px; padding: 10px 10px 10px 30px; font-size: 14px; }
.aviso { padding: 10px 15px; border-radius: 6px; margin-bottom: 10px; background: #fff4d6; color: #7a5a00; }
#procesando { position: fixed; inset: 0; background: rgba(255,255,255,.6); display: flex; align-items: center; justify-content: center; font-size: 18px; z-index: 10; }
#procesando[hidden], [hidden] { display: none !important; }
@media (max-width: 600px) {
	nav a { margin: 0 12px 0 0; font-size: 14px; }
	main { padding: 12px; }
}
label.casilla { display: flex; gap: 8px; align-items: center; }
label.casilla input { width: auto; margin: 0; }
.recibo { background: #fff; border-radius: 8px; box-shadow: 0 1px 4px rgba(0,0,0,.08); margin-bottom: 15px; padding: 15px 20px; border-left: 5px solid #00bc9b; }
.recibo.con-error { border-left-color: #d93025; }
.recibo.timbrado { border-left-color: #1a73e8; }
.recibo header { all: unset; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; }
.recibo h3 { margin: 0; font-size: 17px; }
.recibo .neto { font-size: 20px; color: #00bc9b; font-weight: 700; }
.recibo table { margin: 10px 0; }
.recibo th { background: #f0f0f0; color: #555; }
.recibo td input, .recibo td select { margin: 0; padding: 5px; }
.recibo td.num input { text-align: right; max-width: 110px; display: inline-block; }
.recibo .dias input { display: inline-block; width: 80px; margin-left: 6px; }
.recibo .sumas { display: flex; flex-wrap: wrap; gap: 20px; font-size: 14px; color: #555; margin-top: 8px; }
.recibo .agregar { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.etiqueta { font-size: 12px; border-radius: 10px; padding: 2px 8px; background: #e8f8f5; color: #00876f; }
.etiqueta.roja { background: #fdecea; color: #b3261e; }
.etiqueta.azul { background: #e8f0fe; color: #1a56c4; }
button[disabled] { background: #b8b8b8; cursor: not-allowed; }
.recibo td select { min-width: 170px; }
.recibo td input[data-k="Concepto"] { min-width: 170px; }
.whatsapp { background: #25d366; }
.whatsapp:hover { background: #1da851; }
.rojo { background: #d93025; color: #fff; }
.rojo:hover { background: #b3261e; }
.etiqueta.naranja { background: #fff1db; color: #a35a00; }
.recibo .cancelar { background: #fdf3f2; border-radius: 6px; padding: 10px 12px; margin-top: 8px; }
.recibo .cancelar label { max-width: 520px; }
