:root { --azul: #1d4e89; --azul-oscuro: #12355f; --azul-claro: #eaf1fa; --texto: #1e293b; --gris: #64748b; --fondo: #f1f5f9; --rojo: #b91c1c; --verde: #047857; }
* { box-sizing: border-box; }
body { margin: 0; background: var(--fondo); color: var(--texto); font: 16px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
.cabecera { background: #fff; border-bottom: 3px solid var(--azul); padding: 12px 16px; text-align: center; }
.logo { height: 44px; width: auto; }
.contenido { max-width: 920px; margin: 0 auto; padding: 16px; }
.tarjeta { background: #fff; border-radius: 12px; padding: 18px 20px; margin: 0 0 16px; box-shadow: 0 1px 3px rgba(15, 23, 42, .08); }
h1 { font-size: 1.35rem; color: var(--azul-oscuro); margin: .2em 0 .5em; }
h2 { font-size: 1.05rem; color: var(--azul-oscuro); margin: 1.2em 0 .4em; }
.antetitulo { text-transform: uppercase; letter-spacing: .06em; font-size: .75rem; color: var(--gris); margin: 0; }
.nota { font-size: .8rem; color: var(--gris); }
code { font-size: .75rem; word-break: break-all; }
.oculto { display: none !important; }
.paginas { display: flex; flex-direction: column; align-items: center; gap: 12px; margin-bottom: 16px; }
.pagina { max-width: 100%; height: auto; background: #fff; box-shadow: 0 1px 4px rgba(15, 23, 42, .18); }
.aviso { text-align: center; background: var(--azul-claro); color: var(--azul-oscuro); border-radius: 8px; padding: 10px; font-weight: 600; }
.fila { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.boton { background: var(--azul); color: #fff; border: 0; border-radius: 10px; padding: 14px 22px; font-size: 1rem; font-weight: 700; width: 100%; cursor: pointer; margin-top: 8px; }
.boton.secundario { width: auto; background: #fff; color: var(--azul); border: 2px solid var(--azul); padding: 10px 16px; margin: 0; }
.boton:disabled { opacity: .55; cursor: default; }
.codigo { font-size: 1.4rem; letter-spacing: .3em; width: 9.5em; padding: 8px 10px; border: 2px solid #cbd5e1; border-radius: 10px; text-align: center; }
.lienzo-caja { border: 2px dashed var(--azul); border-radius: 10px; background: #fff; }
.lienzo { display: block; width: 100%; height: 200px; touch-action: none; cursor: crosshair; }
.enlace { background: none; border: 0; color: var(--azul); text-decoration: underline; padding: 6px 0; cursor: pointer; font-size: .9rem; }
.acepto { display: flex; gap: 10px; align-items: flex-start; margin: 14px 0 4px; font-size: .9rem; }
.acepto input { width: 22px; height: 22px; flex: none; margin-top: 2px; }
.error { color: var(--rojo); font-weight: 600; min-height: 1.2em; }
.pie { text-align: center; font-size: .75rem; color: var(--gris); padding: 20px 16px 32px; }
.pie a { color: var(--azul); }
.resultado { margin-top: 16px; }
.resultado.bien { border-left: 4px solid var(--verde); padding-left: 12px; }
.resultado.bien h2 { color: var(--verde); }
.resultado.mal { border-left: 4px solid var(--rojo); padding-left: 12px; }
.resultado.mal h2 { color: var(--rojo); }
input[type=file] { margin-top: 8px; max-width: 100%; }
.campo { display: block; font-size: .85rem; color: var(--gris); margin: 10px 0; }
.campo input { display: block; width: 100%; margin-top: 4px; font-size: 1.05rem; padding: 10px 12px; border: 2px solid #cbd5e1; border-radius: 10px; color: var(--texto); }
.mayusculas { text-transform: uppercase; }
.fotos { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.foto input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.foto-marco { position: relative; display: flex; align-items: center; justify-content: center; aspect-ratio: 3 / 4; border: 2px dashed var(--azul); border-radius: 10px; background: var(--azul-claro); cursor: pointer; overflow: hidden; text-align: center; }
.foto-marco img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: none; }
.foto-texto { position: relative; font-size: .8rem; font-weight: 600; color: var(--azul-oscuro); padding: 4px; background: rgba(255, 255, 255, .85); border-radius: 6px; }
.foto.hecha .foto-marco { border-style: solid; border-color: var(--verde); }
.foto.hecha img { display: block; }
.foto.subiendo .foto-marco { opacity: .6; }
.paso-hecho { border-left: 4px solid var(--verde); }
.foto.hecha .foto-texto { position: absolute; left: 4px; right: 4px; bottom: 4px; font-size: .7rem; }
.foto.hecha .foto-texto::before { content: "✓ "; color: var(--verde); }
