/* Autorepuestos Alvarado (v2, 2026-10-29). Tokens from the live property (soul.md), the order in
   three steps, one component vocabulary. The 20 UX laws each rule answers: UX-LAWS.md. */
:root {
  --navy: #1c2e60;
  --navy-900: #121e40;
  --azul: #228dcb;          /* brand blue: progress, focus ring. 3.66:1, never text */
  --azul-accion: #1b78b0;   /* primary fill, 4.82:1 with white */
  --azul-tinta: #17699a;    /* links, secondary text, the stamp, 5.96:1 */
  --azul-50: #eaf3fa;
  --fondo: #f3f5f9;
  --tinta: #141c2f;
  --tinta-2: #4a5570;
  --linea: #d9dfea;
  --campo: #b3bfd3;
  --abierto: #1f8a4c;
  --cerrado: #b26b00;
  --error: #b3261e;
  --sombra: 0 1px 2px rgba(20, 28, 47, .04), 0 8px 24px rgba(20, 28, 47, .07);
  --ease: cubic-bezier(.16, 1, .3, 1);
  --z-sticky: 10;
  --z-acciones: 15;
  --z-barra: 20;
  --z-aviso: 30;
  --cab: 60px;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-padding-top: calc(var(--cab) + 12px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font: 400 16px/1.5 Barlow, system-ui, sans-serif;
  color: var(--tinta);
  background: var(--fondo);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
img { max-width: 100%; height: auto; display: block; }
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
button:disabled { cursor: default; }
h1, h2, h3 { text-wrap: balance; margin: 0; }
p { text-wrap: pretty; }
a { color: var(--azul-tinta); }
:focus-visible { outline: 3px solid var(--azul); outline-offset: 2px; }
[tabindex="-1"]:focus { outline: none; }
.cont { max-width: 1180px; margin: 0 auto; padding: 0 16px; }
.icono { width: 20px; height: 20px; flex: none; }
.bandera { width: 21px; height: 14px; flex: none; border-radius: 2px; box-shadow: 0 0 0 1px rgba(20, 28, 47, .12); }
.simbolos { position: absolute; width: 0; height: 0; overflow: hidden; }
.sr { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.saltar { position: absolute; left: -999px; top: 8px; z-index: 100; background: #fff; color: var(--navy); padding: 12px 16px; border-radius: 8px; font-weight: 700; }
.saltar:focus { left: 16px; }
.trampa { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

/* ---- buttons: one component, three variants, heights 44 / 48 / 56 (law 16) ---------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 18px;
  border: 1.5px solid transparent; border-radius: 10px;
  font: 600 16px/1.1 Barlow, system-ui, sans-serif; text-decoration: none; white-space: nowrap;
  transition: background-color .16s, border-color .16s, color .16s, transform .12s;
}
.btn:active:not(:disabled) { transform: scale(.98); }
.btn--primario { background: var(--azul-accion); color: #fff; }
.btn--primario:hover:not(:disabled) { background: var(--azul-tinta); }
.btn--primario:disabled { background: #dde3ee; color: #5d6880; }
.btn--sec { background: #fff; color: var(--azul-tinta); border-color: #b9c9de; }
.btn--sec:hover { border-color: var(--azul-tinta); background: #f4f8fc; }
.btn--grande { min-height: 56px; padding: 0 22px; font-size: 18px; font-weight: 700; }
.btn--agregar { min-height: 44px; padding: 0 14px; }
.btn--apilado { flex-direction: column; gap: 4px; min-height: 56px; padding: 6px 8px; font-size: 14px; }

/* ---- header ---------------------------------------------------------------------------- */
.cabecera { position: sticky; top: 0; z-index: var(--z-sticky); background: var(--navy); color: #fff; }
.cabecera__in { display: flex; align-items: center; gap: 12px; min-height: var(--cab); }
.marca { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; color: #fff; text-decoration: none; }
.marca__placa { display: flex; flex-direction: column; }
.marca__nombre { font: 800 25px/.9 "Barlow Condensed", sans-serif; letter-spacing: .06em; }
.marca__sub { font: 600 9.5px/1 Barlow, sans-serif; letter-spacing: .2em; color: #b8c4e2; margin-top: 4px; }
.marca__ruta { display: flex; gap: 3px; }
.marca__ruta .bandera { width: 18px; height: 12px; box-shadow: none; }
.nav { display: none; }
.estado { display: inline-flex; align-items: center; gap: 8px; margin: 0; font: 600 14px/1.2 Barlow, sans-serif; color: var(--tinta); }
.estado__punto { width: 10px; height: 10px; border-radius: 50%; flex: none; background: #8a94a8; }
[data-abierto="si"] .estado__punto { background: var(--abierto); box-shadow: 0 0 0 3px rgba(31, 138, 76, .18); }
[data-abierto="no"] .estado__punto { background: var(--cerrado); box-shadow: 0 0 0 3px rgba(178, 107, 0, .18); }
.estado__corto { display: none; }
.estado--cab { margin-left: auto; color: #e4e9f5; }
.estado--cab[data-abierto="si"] .estado__punto { background: #3ccf7a; box-shadow: 0 0 0 3px rgba(60, 207, 122, .22); }
.estado--cab[data-abierto="no"] .estado__punto { background: #f0a92b; box-shadow: 0 0 0 3px rgba(240, 169, 43, .22); }
.cabecera__tiendas { width: 44px; height: 44px; display: grid; place-items: center; flex: none; border-radius: 10px; color: #fff; border: 1.5px solid rgba(255, 255, 255, .25); }
.cabecera__tiendas:hover { background: rgba(255, 255, 255, .08); }
@media (max-width: 1023px) {
  .estado--cab .estado__largo { display: none; }
  .estado--cab .estado__corto { display: inline; }
}

/* ---- the band ---------------------------------------------------------------------------- */
.portada { background: var(--navy); color: #fff; padding: 18px 0 52px; }
.portada h1 { font: 800 34px/1 "Barlow Condensed", sans-serif; letter-spacing: -.005em; }
.portada__sub { margin: 10px 0 14px; max-width: 46ch; font-size: 17px; line-height: 1.4; color: #d6deef; }
.portada__datos { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 14px; font: 500 14px/1.3 Barlow, sans-serif; color: #b9c6e4; }
.portada__datos li { display: inline-flex; align-items: center; gap: 6px; }
.portada__datos .bandera { width: 18px; height: 12px; box-shadow: none; }

/* ---- the order --------------------------------------------------------------------------- */
.pedido { position: relative; margin-top: -32px; padding-bottom: 40px; }
.flujo {
  margin: 0 -16px; padding: 14px 16px 24px;
  background: #fff; border-top: 1px solid var(--linea); border-radius: 18px 18px 0 0;
  scroll-margin-top: calc(var(--cab) + 8px);
}

/* progress (laws 11, 17, 20) */
.pasos { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; }
.paso button { display: flex; align-items: center; gap: 8px; width: 100%; min-height: 48px; padding: 2px 0; background: none; border: 0; text-align: left; color: var(--tinta-2); }
.paso__n { flex: none; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; border: 2px solid #b9c3d6; background: #fff; font: 700 17px/1 "Barlow Condensed", sans-serif; color: var(--tinta-2); transition: background-color .2s, border-color .2s, color .2s; }
.paso__n .icono { display: none; width: 18px; height: 18px; }
.paso__txt { min-width: 0; }
.paso__t { display: block; font: 600 15px/1.15 Barlow, sans-serif; }
.paso__v { display: block; min-height: 15px; font: 500 13px/1.2 Barlow, sans-serif; color: var(--tinta-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.paso[aria-current="step"] .paso__n { background: var(--navy); border-color: var(--navy); color: #fff; }
.paso[aria-current="step"] .paso__t { color: var(--navy); font-weight: 700; }
.paso.hecho .paso__n { background: var(--azul-accion); border-color: var(--azul-accion); color: #fff; }
.paso.hecho .paso__n span { display: none; }
.paso.hecho .paso__n .icono { display: block; }
.paso.hecho .paso__t { color: var(--tinta); }
.paso button:not(:disabled):hover .paso__t { text-decoration: underline; text-underline-offset: 3px; }
.progreso__linea { height: 4px; margin-top: 8px; background: #e3e8f1; border-radius: 2px; overflow: hidden; }
.progreso__linea span { display: block; width: 18%; height: 100%; background: var(--azul); border-radius: 2px; transition: width .24s var(--ease); }

/* views replace each other in place (no modal, law 3) */
.js .vista { display: none; }
.js .vista.activa { display: block; animation: entra .2s var(--ease); }
@keyframes entra { from { opacity: 0; transform: translateY(6px); } }
.vista__cab { margin-top: 16px; }
.vista__titulo { margin: 18px 0 14px; font: 800 26px/1.08 "Barlow Condensed", sans-serif; color: var(--navy); }
.vista__cab .vista__titulo { margin-top: 4px; margin-bottom: 4px; }
.vista__sub { margin: 0 0 6px; font: 500 15px/1.35 Barlow, sans-serif; color: var(--tinta-2); }
.volver, .enlace { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 8px 0 0; background: none; border: 0; color: var(--azul-tinta); font: 600 16px/1 Barlow, sans-serif; }
.volver:hover span, .enlace:hover span { text-decoration: underline; text-underline-offset: 3px; }

/* step 1: tabs and unit tiles (laws 1, 2, 13) */
.pestanas { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; background: #eef1f6; border-radius: 12px; margin-bottom: 12px; }
.pestana { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 8px; border: 0; border-radius: 9px; background: transparent; color: var(--tinta-2); font: 600 16px/1.1 Barlow, sans-serif; transition: background-color .16s, color .16s; }
.pestana[aria-selected="true"] { background: var(--navy); color: #fff; }
.pestana:not([aria-selected="true"]):hover { background: #e2e7f0; color: var(--tinta); }
.fichas { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.fichas[hidden] { display: none; }
.ficha {
  display: flex; flex-direction: column; justify-content: center; min-height: 84px; padding: 8px 10px;
  background: #fff; border: 1.5px solid var(--linea); border-radius: 12px;
  color: var(--navy); text-decoration: none;
  transition: border-color .16s, background-color .16s, transform .12s;
}
.ficha:hover { border-color: var(--navy); background: #f6f8fc; }
.ficha:active { transform: scale(.98); }
.ficha[aria-current="true"] { background: var(--navy); border-color: var(--navy); color: #fff; }
.ficha[aria-current="true"] .ficha__tipo { color: #c9d3ea; }
.ficha__codigo { font: 800 30px/1 "Barlow Condensed", sans-serif; letter-spacing: .01em; white-space: nowrap; }
.ficha.n5 .ficha__codigo, .ficha.n6 .ficha__codigo { font-size: 26px; }
.ficha.n7 .ficha__codigo, .ficha.n8 .ficha__codigo { font-size: 22px; }
.ficha.n9 .ficha__codigo, .ficha.n10 .ficha__codigo, .ficha.n11 .ficha__codigo, .ficha.n12 .ficha__codigo { font-size: 18px; }
.ficha__tipo { margin-top: 6px; font: 500 14px/1.2 Barlow, sans-serif; color: var(--tinta-2); }
.otra { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 52px; margin-top: 10px; padding: 0 14px 0 16px; border: 1.5px dashed #b4c1d6; border-radius: 12px; color: var(--navy); text-decoration: none; font: 500 16px/1.2 Barlow, sans-serif; }
.otra b { font-weight: 700; }
.otra:hover { border-style: solid; border-color: var(--navy); background: #f6f8fc; }

/* step 2: parts in chunks by system (laws 5, 14, 15) */
.grupo { margin-top: 18px; }
.grupo__t { display: flex; align-items: center; gap: 8px; padding-bottom: 8px; border-bottom: 2px solid var(--navy); font: 700 16px/1.1 Barlow, sans-serif; color: var(--navy); }
.grupo__t .icono { color: var(--azul-tinta); }
.grupo__n { margin-left: auto; min-width: 24px; padding: 2px 7px; border-radius: 12px; background: #eef1f6; color: var(--tinta-2); font: 600 13px/1.2 Barlow, sans-serif; text-align: center; }
.filas { list-style: none; margin: 0; padding: 0; }
.fila {
  display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; align-items: center; gap: 12px;
  min-height: 68px; padding: 10px 8px; border-bottom: 1px solid var(--linea);
  transition: background-color .16s;
}
.fila__icono { width: 44px; height: 44px; border-radius: 10px; background: #eef2f8; display: grid; place-items: center; color: var(--navy); overflow: hidden; transition: background-color .16s, color .16s; }
.fila__icono .icono { width: 24px; height: 24px; }
.fila__icono img { width: 100%; height: 100%; object-fit: cover; }
.fila__nombre { display: block; font: 600 17px/1.25 Barlow, sans-serif; color: var(--tinta); }
.fila__meta { display: block; margin-top: 2px; font: 500 13px/1.3 Barlow, sans-serif; color: var(--tinta-2); overflow-wrap: anywhere; }
.fila.en-pedido { background: var(--azul-50); }
.fila.en-pedido .fila__icono { background: var(--azul-accion); color: #fff; }
.fila__accion { display: flex; justify-content: flex-end; }
.cantidad { display: inline-flex; align-items: center; border: 1.5px solid var(--azul-tinta); border-radius: 10px; background: #fff; }
.cantidad[hidden] { display: none; }
.cantidad__b { width: 44px; height: 44px; display: grid; place-items: center; padding: 0; border: 0; background: none; color: var(--azul-tinta); border-radius: 8px; }
.cantidad__b:hover:not(:disabled) { background: var(--azul-50); }
.cantidad__b:disabled { color: #a9b3c4; }
.cantidad output { min-width: 30px; text-align: center; font: 700 18px/1 Barlow, sans-serif; color: var(--navy); }
.cantidad .icono--quitar, .cantidad.es-uno .icono--menos { display: none; }
.cantidad.es-uno .icono--quitar { display: block; }

.libre { margin-top: 22px; padding: 16px; background: #f6f8fb; border: 1px solid var(--linea); border-radius: 12px; }
.libre__lead { margin: 0 0 12px; font: 500 17px/1.4 Barlow, sans-serif; color: var(--tinta); }
.libre__label { display: block; margin-bottom: 8px; font: 600 16px/1.2 Barlow, sans-serif; color: var(--navy); }
.libre__fila { display: flex; gap: 8px; }
.libre__fila input { flex: 1; min-width: 0; }
.libre__msg { min-height: 20px; margin: 8px 0 0; font: 500 15px/1.3 Barlow, sans-serif; color: var(--tinta-2); }
.libre__msg.error { color: var(--error); }
.libre--solo { margin-top: 16px; }

/* fields */
input:not([type="radio"]):not([type="checkbox"]), textarea {
  width: 100%; min-height: 48px; padding: 0 14px;
  background: #fff; border: 1.5px solid var(--campo); border-radius: 10px;
  font: 400 17px/1.3 Barlow, sans-serif; color: var(--tinta);
  transition: border-color .16s;
}
textarea { padding: 12px 14px; min-height: 112px; resize: vertical; }
input::placeholder, textarea::placeholder { color: #69748c; }
input:focus, textarea:focus { border-color: var(--azul-tinta); }
[aria-invalid="true"] { border-color: var(--error) !important; }

/* step 3: three groups, one action (laws 4, 7, 8, 13) */
.bloque { margin-top: 22px; }
.bloque__t { display: block; margin: 0 0 8px; font: 700 17px/1.2 Barlow, sans-serif; color: var(--navy); }
.bloque__t small { font-weight: 500; color: var(--tinta-2); font-size: 15px; }
.filas--pedido { border-top: 1px solid var(--linea); }
.vacio { padding: 16px; background: #f6f8fb; border-radius: 12px; }
.vacio p { margin: 0 0 10px; }
fieldset.bloque { border: 0; padding: 0; min-width: 0; }
fieldset.bloque legend { padding: 0; }
.opciones { display: grid; gap: 10px; }
.opcion { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; background: #fff; border: 1.5px solid var(--linea); border-radius: 12px; cursor: pointer; transition: border-color .16s, background-color .16s; }
.opcion input { width: 22px; height: 22px; margin: 2px 0 0; flex: none; accent-color: var(--navy); }
.opcion:has(input:checked) { border-color: var(--navy); background: var(--azul-50); box-shadow: inset 0 0 0 1px var(--navy); }
.opcion__caja { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.opcion__nombre { font: 700 18px/1.2 Barlow, sans-serif; color: var(--navy); }
.opcion__dir { font: 500 15px/1.3 Barlow, sans-serif; color: var(--tinta-2); }
.opcion .estado { margin-top: 6px; font-size: 13px; }
.campo { display: flex; flex-direction: column; }
.acciones {
  position: sticky; bottom: 0; z-index: var(--z-acciones);
  margin: 10px -16px -24px; padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
  background: #fff; border-top: 1px solid var(--linea); box-shadow: 0 -8px 20px rgba(20, 28, 47, .06);
}
.acciones .btn { width: 100%; }
.acciones__nota { margin: 20px 0 0; font: 500 15px/1.4 Barlow, sans-serif; color: var(--tinta-2); }

/* done: the end people remember (law 10) */
.listo { padding: 18px 0 8px; text-align: center; }
.listo__check { width: 64px; height: 64px; margin: 8px auto 14px; border-radius: 50%; display: grid; place-items: center; background: var(--azul-accion); color: #fff; animation: pop .34s var(--ease); }
.listo__check .icono { width: 34px; height: 34px; stroke-width: 2.4; }
@keyframes pop { from { opacity: 0; transform: scale(.6); } }
.listo .vista__titulo { margin: 0 0 8px; font-size: 28px; }
.listo__txt { max-width: 38ch; margin: 0 auto 6px; font-size: 17px; line-height: 1.45; }
.listo__otra { margin: 0 auto 22px; font: 500 15px/1.4 Barlow, sans-serif; color: var(--tinta-2); }
.listo__otra a { display: inline-flex; align-items: center; min-height: 44px; font-weight: 600; }
.boleta { position: relative; max-width: 420px; margin: 0 auto; padding: 16px 20px 96px; text-align: left; background: #fff; border: 1px solid var(--linea); border-top: 6px solid var(--navy); border-radius: 4px 4px 12px 12px; box-shadow: 0 10px 28px rgba(20, 28, 47, .1); }
.boleta__cab { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding-bottom: 10px; margin-bottom: 10px; border-bottom: 1.5px dashed #c3ccdb; }
.boleta__marca { font: 800 22px/1 "Barlow Condensed", sans-serif; letter-spacing: .05em; color: var(--navy); }
.boleta__num { font: 600 15px/1.2 Barlow, sans-serif; color: var(--tinta-2); }
.boleta__num b { color: var(--navy); }
.boleta__lineas { margin: 0; padding-left: 22px; font: 500 16px/1.5 Barlow, sans-serif; }
.boleta__lineas li { padding: 2px 0; }
.boleta__lineas small { color: var(--tinta-2); font-size: 14px; }
.sello {
  position: absolute; right: 18px; bottom: 14px; transform: rotate(-8deg);
  display: flex; flex-direction: column; align-items: center; padding: 5px 12px;
  border: 3px solid var(--azul-tinta); border-radius: 8px; color: var(--azul-tinta);
  font: 800 12px/1.2 "Barlow Condensed", sans-serif; letter-spacing: .1em; text-transform: uppercase;
  filter: url(#tinta); animation: sellar .36s var(--ease) .3s backwards;
}
.sello b { font-size: 17px; letter-spacing: .06em; }
@keyframes sellar { from { opacity: 0; transform: rotate(-8deg) scale(1.4); } }
.listo__acciones { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 28px; }

/* the order summary: desktop aside, phone bottom bar (laws 8, 11) */
.resumen { display: none; }
.insignia { display: inline-block; min-width: 26px; height: 26px; padding: 0 7px; border-radius: 13px; background: var(--azul-accion); color: #fff; font: 700 14px/26px Barlow, sans-serif; text-align: center; vertical-align: middle; }
.insignia.cero { background: #dde3ee; color: var(--tinta-2); }
.barra { position: fixed; left: 0; right: 0; bottom: 0; z-index: var(--z-barra); padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid var(--linea); box-shadow: 0 -8px 24px rgba(20, 28, 47, .08); }
.barra[hidden] { display: none; }
.barra__in { display: flex; align-items: center; gap: 12px; max-width: 640px; margin: 0 auto; }
.barra__info { flex: 1; min-width: 0; margin: 0; }
.barra__info b { display: block; font: 700 17px/1.2 Barlow, sans-serif; color: var(--navy); }
.barra__info span { display: block; font: 500 14px/1.3 Barlow, sans-serif; color: var(--tinta-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.barra .btn { flex: none; min-width: 152px; }
body.con-barra { padding-bottom: 84px; }

/* undo toast (law 15) */
.aviso { position: fixed; left: 50%; bottom: 16px; z-index: var(--z-aviso); transform: translateX(-50%); display: flex; align-items: center; gap: 10px; width: max-content; max-width: calc(100vw - 32px); padding: 4px 4px 4px 16px; background: var(--tinta); color: #fff; border-radius: 12px; box-shadow: 0 10px 30px rgba(0, 0, 0, .25); font: 500 15px/1.3 Barlow, sans-serif; animation: aviso .2s var(--ease); }
.aviso[hidden] { display: none; }
.aviso button { min-height: 44px; padding: 0 14px; border: 0; border-radius: 8px; background: transparent; color: #8fd0ff; font: 700 15px/1 Barlow, sans-serif; }
.aviso button:hover { background: rgba(255, 255, 255, .08); }
@keyframes aviso { from { opacity: 0; transform: translate(-50%, 10px); } }
body.con-barra .aviso, body[data-paso="3"] .aviso { bottom: 88px; }

/* ---- branches ---------------------------------------------------------------------------- */
.tiendas { padding: 44px 0; }
.seccion__t { margin-bottom: 18px; font: 800 30px/1.05 "Barlow Condensed", sans-serif; color: var(--navy); }
.tiendas__grid { display: grid; gap: 16px; }
.tienda { display: flex; flex-direction: column; gap: 14px; padding: 20px; background: #fff; border: 1px solid var(--linea); border-radius: 16px; }
.tienda__cab { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 12px; }
.tienda__nombre { font: 800 28px/1 "Barlow Condensed", sans-serif; color: var(--navy); }
.tienda__dir { display: flex; align-items: flex-start; gap: 8px; margin: 0; font: 500 17px/1.35 Barlow, sans-serif; }
.tienda__dir .icono { color: var(--azul-tinta); margin-top: 1px; }
.horas { display: grid; gap: 4px; margin: 0; }
.horas div { display: flex; justify-content: space-between; gap: 12px; padding-bottom: 4px; border-bottom: 1px dotted #cfd7e4; font-size: 15px; }
.horas dt { color: var(--tinta-2); }
.horas dd { margin: 0; font-weight: 600; }
.tienda__acciones { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.tienda__acciones .btn { flex-direction: column; gap: 4px; min-height: 56px; padding: 6px 4px; font-size: 14px; }
.tienda__mas summary { display: inline-flex; align-items: center; min-height: 44px; color: var(--azul-tinta); font: 600 15px/1 Barlow, sans-serif; cursor: pointer; list-style: none; }
.tienda__mas summary::-webkit-details-marker { display: none; }
.tienda__mas summary::after { content: "+"; margin-left: 8px; font-size: 18px; }
.tienda__mas[open] summary::after { content: "−"; }
.tienda__mas ul { list-style: none; margin: 0; padding: 0; }
.tienda__mas a { display: flex; align-items: center; gap: 10px; min-height: 44px; color: var(--tinta); text-decoration: none; font: 600 17px/1 Barlow, sans-serif; }
.tienda__mas a .icono { color: var(--azul-tinta); }

/* ---- companies (law 19: the form opens on request) ---------------------------------------- */
.empresas { padding: 44px 0 56px; background: #fff; border-top: 1px solid var(--linea); }
.empresas__in { display: grid; gap: 24px; }
.empresas__foto { margin: 0; aspect-ratio: 16 / 10; border-radius: 16px; overflow: hidden; background: var(--navy); }
.empresas__foto img { width: 100%; height: 100%; object-fit: cover; }
.empresas__lead { margin: 0 0 16px; max-width: 46ch; font-size: 18px; line-height: 1.45; }
.checks { list-style: none; margin: 0 0 16px; padding: 0; display: grid; gap: 8px; }
.checks li { display: flex; align-items: center; gap: 10px; font: 600 17px/1.3 Barlow, sans-serif; }
.checks .icono { width: 22px; height: 22px; color: var(--azul-accion); }
.clientes { margin: 0 0 20px; font-size: 15px; line-height: 1.5; color: var(--tinta-2); }
.clientes span { font-weight: 700; color: var(--navy); }
.formulario { display: grid; grid-template-columns: 1fr; gap: 14px 12px; margin-top: 4px; padding: 20px 16px; background: #f6f8fb; border: 1px solid var(--linea); border-radius: 16px; }
.formulario[hidden] { display: none; }
.formulario .campo { gap: 6px; }
.formulario label { font: 600 15px/1.3 Barlow, sans-serif; }
.formulario label small { font-weight: 500; color: var(--tinta-2); }
.check { display: flex; align-items: flex-start; gap: 10px; min-height: 44px; font-size: 14px; line-height: 1.45; color: var(--tinta-2); cursor: pointer; }
.check input { width: 22px; height: 22px; margin: 1px 0 0; flex: none; accent-color: var(--navy); }
.formulario__estado { margin: 0; min-height: 20px; font: 500 15px/1.4 Barlow, sans-serif; }
.formulario__estado.error { color: var(--error); }

/* ---- footer ------------------------------------------------------------------------------ */
.pie { padding: 32px 0 36px; background: var(--navy-900); color: #c9d3ea; }
.pie__in { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 16px 40px; }
.pie__txt p { margin: 0 0 6px; font-size: 14px; line-height: 1.5; }
.pie a { color: #fff; text-underline-offset: 3px; }
.marca--pie { min-height: 0; }

/* ---- no JavaScript: a readable catalog and the branches ------------------------------------ */
html:not(.js) .progreso, html:not(.js) .pestanas, html:not(.js) .fila__accion, html:not(.js) .libre,
html:not(.js) .volver, html:not(.js) .vista--3, html:not(.js) .vista--4, html:not(.js) .resumen,
html:not(.js) .barra, html:not(.js) [data-abrir-form] { display: none; }
html:not(.js) .formulario[hidden] { display: grid; }

/* ---- larger screens ---------------------------------------------------------------------- */
@media (min-width: 560px) {
  .formulario { grid-template-columns: 1fr 1fr; padding: 24px; }
  .formulario .campo, .formulario .check, .formulario .btn, .formulario__estado { grid-column: 1 / -1; }
  .formulario .campo--medio { grid-column: span 1; }
}
@media (min-width: 760px) {
  :root { --cab: 68px; }
  .cont { padding: 0 24px; }
  .portada { padding: 32px 0 88px; }
  .portada h1 { font-size: 52px; }
  .portada__sub { font-size: 19px; }
  .pedido { margin-top: -64px; }
  .flujo { margin: 0; padding: 22px 28px 32px; border: 1px solid var(--linea); border-radius: 18px; box-shadow: var(--sombra); }
  .fichas { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
  .ficha { min-height: 96px; padding: 12px 14px; }
  .ficha__codigo { font-size: 34px; }
  .ficha.n5 .ficha__codigo, .ficha.n6 .ficha__codigo { font-size: 30px; }
  .ficha.n7 .ficha__codigo, .ficha.n8 .ficha__codigo { font-size: 27px; }
  .ficha.n9 .ficha__codigo, .ficha.n10 .ficha__codigo, .ficha.n11 .ficha__codigo, .ficha.n12 .ficha__codigo { font-size: 23px; }
  .pestanas { max-width: 460px; }
  .vista__titulo { font-size: 32px; }
  .opciones { grid-template-columns: 1fr 1fr; }
  .acciones { position: static; margin: 24px 0 0; padding: 0; border: 0; box-shadow: none; background: none; }
  .acciones .btn { width: auto; min-width: 320px; }
  .acciones__nota { margin-top: 20px; }
  .tiendas { padding: 64px 0; }
  .seccion__t { font-size: 38px; }
  .tiendas__grid { grid-template-columns: 1fr 1fr; gap: 20px; }
  .tienda { padding: 24px; }
  .tienda__acciones .btn { flex-direction: row; gap: 8px; min-height: 48px; font-size: 15px; }
  body[data-paso="3"] .aviso { bottom: 16px; }
}
@media (min-width: 1024px) {
  .nav { display: flex; gap: 2px; margin-left: 20px; }
  .nav a { display: flex; align-items: center; min-height: 44px; padding: 0 12px; border-radius: 8px; color: #dfe5f3; text-decoration: none; font: 600 15px/1 Barlow, sans-serif; }
  .nav a:hover { background: rgba(255, 255, 255, .08); color: #fff; }
  .cabecera__tiendas { display: none; }
  .pedido__grid { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 24px; align-items: start; }
  [data-paso="3"] .pedido__grid, [data-paso="4"] .pedido__grid { grid-template-columns: minmax(0, 800px); justify-content: center; }
  [data-paso="3"] .resumen, [data-paso="4"] .resumen { display: none; }
  .resumen { display: block; position: sticky; top: calc(var(--cab) + 16px); padding: 20px; background: #fff; border: 1px solid var(--linea); border-radius: 18px; box-shadow: var(--sombra); }
  .resumen__t { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; font: 800 24px/1 "Barlow Condensed", sans-serif; color: var(--navy); }
  .resumen__vacio { margin: 0 0 16px; font-size: 15px; color: var(--tinta-2); }
  .resumen__lineas { list-style: none; margin: 0 0 16px; padding: 0; max-height: calc(100vh - 380px); overflow: auto; border-top: 1px solid var(--linea); }
  .resumen__lineas li { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 0 10px; padding: 9px 0; border-bottom: 1px solid var(--linea); font: 600 15px/1.3 Barlow, sans-serif; }
  .resumen__lineas .cant { color: var(--navy); font-weight: 700; }
  .resumen__lineas .meta { grid-column: 2; font: 500 13px/1.3 Barlow, sans-serif; color: var(--tinta-2); }
  .resumen .btn { width: 100%; }
  .resumen__nota { margin: 10px 0 0; font-size: 14px; color: var(--tinta-2); }
  .barra { display: none !important; }
  body.con-barra { padding-bottom: 0; }
  body.con-barra .aviso { bottom: 16px; }
  .empresas { padding: 72px 0 80px; }
  .empresas__in { grid-template-columns: 1.05fr 1fr; gap: 48px; align-items: start; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
