/* Barbik — estilos. Minimalista: un color de marca, grises, mucho espacio. */

:root {
  --fondo: #f4f4f6;
  --panel: #ffffff;
  --texto: #1d1d1f;
  --suave: #6e6e73;
  --linea: rgba(60, 60, 67, .12);
  --marca: #a8552e;          /* cobre: acento para íconos, enlaces y detalles */
  --marca-suave: rgba(168, 85, 46, .10);
  --sobre-marca: #ffffff;
  --tinta: #1d1d1f;          /* acción principal: botones y selección */
  --sobre-tinta: #ffffff;
  --ok: #1f7a3a;
  --ok-suave: rgba(36, 138, 61, .11);
  --alerta: #a65200;
  --alerta-suave: rgba(178, 80, 0, .11);
  --error: #c4001a;
  --error-suave: rgba(215, 0, 21, .08);
  /* Vidrio */
  --vidrio: rgba(255, 255, 255, .62);
  --vidrio-fuerte: rgba(255, 255, 255, .86);
  --vidrio-suave: rgba(255, 255, 255, .5);
  --borde-luz: rgba(255, 255, 255, .95);
  --borde-sombra: rgba(60, 60, 67, .16);
  --blur: blur(22px) saturate(170%);
  --brillo-1: rgba(214, 140, 90, .34);
  --brillo-2: rgba(232, 190, 150, .40);
  --brillo-3: rgba(160, 170, 205, .24);
  --radio: 20px;
  --sombra: 0 1px 2px rgba(0, 0, 0, .04), 0 10px 30px -14px rgba(0, 0, 0, .16);
  --sombra-alta: 0 30px 70px -24px rgba(0, 0, 0, .30), 0 2px 8px rgba(0, 0, 0, .06);
  --rapido: 180ms;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --fondo: #101012;
    --panel: #1c1c1e;
    --texto: #f2f2f7;
    --suave: #98989f;
    --linea: rgba(235, 235, 245, .10);
    --marca: #e09a72;
    --marca-suave: rgba(224, 154, 114, .14);
    --sobre-marca: #1a0f0a;
    --tinta: #f2f2f7;
    --sobre-tinta: #111113;
    --ok: #4cd964;
    --ok-suave: rgba(76, 217, 100, .13);
    --alerta: #ffb340;
    --alerta-suave: rgba(255, 159, 10, .14);
    --error: #ff6961;
    --error-suave: rgba(255, 69, 58, .14);
    --vidrio: rgba(30, 30, 33, .62);
    --vidrio-fuerte: rgba(38, 38, 42, .9);
    --vidrio-suave: rgba(48, 48, 52, .5);
    --borde-luz: rgba(255, 255, 255, .16);
    --borde-sombra: rgba(255, 255, 255, .04);
    --brillo-1: rgba(190, 100, 55, .22);
    --brillo-2: rgba(120, 80, 60, .18);
    --brillo-3: rgba(70, 80, 120, .18);
    --sombra: 0 1px 2px rgba(0, 0, 0, .3), 0 12px 32px -16px rgba(0, 0, 0, .6);
    --sombra-alta: 0 30px 70px -20px rgba(0, 0, 0, .7);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
    --fondo: #101012;
    --panel: #1c1c1e;
    --texto: #f2f2f7;
    --suave: #98989f;
    --linea: rgba(235, 235, 245, .10);
    --marca: #e09a72;
    --marca-suave: rgba(224, 154, 114, .14);
    --sobre-marca: #1a0f0a;
    --tinta: #f2f2f7;
    --sobre-tinta: #111113;
    --ok: #4cd964;
    --ok-suave: rgba(76, 217, 100, .13);
    --alerta: #ffb340;
    --alerta-suave: rgba(255, 159, 10, .14);
    --error: #ff6961;
    --error-suave: rgba(255, 69, 58, .14);
    --vidrio: rgba(30, 30, 33, .62);
    --vidrio-fuerte: rgba(38, 38, 42, .9);
    --vidrio-suave: rgba(48, 48, 52, .5);
    --borde-luz: rgba(255, 255, 255, .16);
    --borde-sombra: rgba(255, 255, 255, .04);
    --brillo-1: rgba(190, 100, 55, .22);
    --brillo-2: rgba(120, 80, 60, .18);
    --brillo-3: rgba(70, 80, 120, .18);
    --sombra: 0 1px 2px rgba(0, 0, 0, .3), 0 12px 32px -16px rgba(0, 0, 0, .6);
    --sombra-alta: 0 30px 70px -20px rgba(0, 0, 0, .7);
    color-scheme: dark;
  }
@media (prefers-reduced-motion: reduce) {
  :root { --rapido: 0ms; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font: 15.5px/1.5 Inter, -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, sans-serif;
  background: var(--fondo);
  color: var(--texto);
  -webkit-font-smoothing: antialiased;
}
/* Brillos suaves detrás del vidrio */
body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(38rem 30rem at -6% -8%, var(--brillo-1), transparent 70%),
    radial-gradient(34rem 30rem at 108% 104%, var(--brillo-2), transparent 70%),
    radial-gradient(28rem 22rem at 70% 30%, var(--brillo-3), transparent 70%);
}
/* Vidrio: fondo translúcido + desenfoque + borde de luz */
.tarjeta, .cifra, .plan, .menu, dialog, .agenda, .pestanas, .opcion {
  -webkit-backdrop-filter: var(--blur);
  backdrop-filter: var(--blur);
}
.tarjeta, .cifra, .plan, .agenda, .opcion { position: relative; }
.tarjeta::after, .cifra::after, .plan::after, .agenda::after, .opcion::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px; pointer-events: none;
  background: linear-gradient(145deg, var(--borde-luz), transparent 38%, var(--borde-sombra) 72%, var(--borde-luz));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
}
h1, h2, h3 { line-height: 1.2; margin: 0 0 .5rem; letter-spacing: -.022em; font-weight: 700; }
h1 { font-size: 1.75rem; }
h2 { font-size: 1.2rem; }
h3 { font-size: 1rem; }
p { margin: 0 0 .75rem; }
a { color: var(--marca); text-underline-offset: 3px; }
.suave { color: var(--suave); }
.chico { font-size: .875rem; }

/* ---------- Botones y campos ---------- */
button, .boton {
  font: inherit;
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  min-height: 44px; padding: .55rem 1rem;
  border: 1px solid var(--linea); border-radius: 12px;
  background: var(--vidrio-fuerte); color: var(--texto); font-weight: 500;
  cursor: pointer; text-decoration: none;
  transition: background var(--rapido), border-color var(--rapido), transform var(--rapido);
}
button:hover, .boton:hover { border-color: var(--borde-sombra); background: var(--panel); }
button:active, .boton:active { transform: scale(.98); }
button:disabled { opacity: .55; cursor: default; }
.primario { background: var(--tinta); border-color: var(--tinta); color: var(--sobre-tinta); font-weight: 600;
  box-shadow: 0 6px 16px -8px rgba(0, 0, 0, .45); }
.primario:hover { background: var(--tinta); border-color: var(--tinta); filter: brightness(1.12); }
.peligro { color: var(--error); }
button svg, .boton svg { width: 18px; height: 18px; flex: none; }
.icono-btn { min-height: 40px; min-width: 40px; padding: .4rem; border-color: transparent; background: transparent; }
.ancho { width: 100%; }

label { display: block; font-size: .875rem; font-weight: 500; margin-bottom: .9rem; }
input, select, textarea {
  font: inherit; display: block; width: 100%;
  margin-top: .3rem; min-height: 44px; padding: .55rem .75rem;
  border: 1px solid var(--linea); border-radius: 12px;
  background: var(--vidrio-fuerte); color: var(--texto);
  transition: border-color var(--rapido), box-shadow var(--rapido), background var(--rapido);
}
input:focus, select:focus, textarea:focus, button:focus-visible {
  outline: none; border-color: var(--marca); box-shadow: 0 0 0 3px var(--marca-suave);
}
input[type="checkbox"] { display: inline; width: 18px; height: 18px; min-height: 0; margin: 0 .5rem 0 0; vertical-align: -3px; accent-color: var(--marca); }
label.check { font-weight: 400; display: flex; align-items: flex-start; }
.fila { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.ayuda { font-size: .8rem; color: var(--suave); font-weight: 400; margin-top: .25rem; display: block; }

/* ---------- Tarjetas y listas ---------- */
.tarjeta {
  background: var(--vidrio); border: 0; border-radius: var(--radio);
  padding: 1.35rem; box-shadow: var(--sombra); margin-bottom: 1rem;
}
.lista { list-style: none; margin: 0; padding: 0; }
.lista > li {
  display: flex; align-items: center; gap: .75rem;
  padding: .85rem 0; border-bottom: 1px solid var(--linea);
}
.lista > li:last-child { border-bottom: 0; }
.lista .crece { flex: 1; min-width: 0; }
.etiqueta {
  display: inline-block; font-size: .75rem; font-weight: 600;
  padding: .15rem .55rem; border-radius: 99px;
  background: var(--vidrio-suave); color: var(--suave); border: 1px solid var(--linea);
}
.etiqueta.marca { background: var(--marca-suave); color: var(--marca); border-color: transparent; }
.etiqueta.ok { background: var(--ok-suave); color: var(--ok); border-color: transparent; }
.aviso {
  border-radius: 16px; padding: .9rem 1.1rem; margin-bottom: 1rem;
  background: var(--alerta-suave); color: var(--texto); border: 1px solid var(--linea);
  -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur);
}
.aviso.error { background: var(--error-suave); }
.aviso.ok { background: var(--ok-suave); }
.error-form { color: var(--error); font-size: .875rem; min-height: 1.25rem; margin: 0 0 .5rem; }

/* ---------- Entrada (login / registro) ---------- */
.entrada { min-height: 100dvh; display: grid; place-items: center; padding: 1.5rem 1rem; }
.entrada .caja { width: 100%; max-width: 400px; animation: aparecer var(--rapido) ease-out; }
.marca-logo { display: flex; align-items: center; gap: .55rem; font-weight: 700; font-size: 1.35rem; letter-spacing: -.02em; margin-bottom: 1.25rem; }
.marca-logo svg { width: 34px; height: 34px; }
.pestanas { display: flex; gap: .25rem; padding: .3rem; background: var(--vidrio-suave); border: 1px solid var(--linea); border-radius: 14px; margin-bottom: 1.25rem; overflow-x: auto; }
.pestanas button { flex: 1; min-height: 40px; border: 0; background: transparent; color: var(--suave); border-radius: 10px; white-space: nowrap; }
.pestanas button[aria-selected="true"] { background: var(--vidrio-fuerte); color: var(--texto); font-weight: 600; box-shadow: 0 2px 8px -2px rgba(0,0,0,.14); }

/* ---------- Panel ---------- */
.app { min-height: 100dvh; }
.menu {
  position: fixed; inset: auto 0 0 0; z-index: 10;
  display: flex; justify-content: space-around;
  background: var(--vidrio); border-top: 1px solid var(--linea);
  padding: .3rem .25rem calc(.3rem + env(safe-area-inset-bottom));
}
.menu .marca-logo, .menu .pie { display: none; }
.menu a {
  flex: 1; display: flex; flex-direction: column; align-items: center; gap: .1rem;
  padding: .35rem .25rem; border-radius: 10px;
  color: var(--suave); text-decoration: none; font-size: .72rem; font-weight: 500;
  transition: color var(--rapido), background var(--rapido);
}
.menu a svg { width: 22px; height: 22px; }
.menu a[aria-current="page"] { color: var(--texto); font-weight: 650; }
.menu a[aria-current="page"] svg { color: var(--marca); }
.contenido { padding: 1rem 1rem calc(5.5rem + env(safe-area-inset-bottom)); max-width: 860px; margin: 0 auto; }
.encabezado { display: flex; align-items: center; gap: .75rem; margin: .5rem 0 1.25rem; }
.encabezado h1 { flex: 1; margin: 0; }
.vista { animation: aparecer var(--rapido) ease-out; }

@media (min-width: 900px) {
  .menu {
    inset: 12px auto 12px 12px; width: 232px; flex-direction: column; justify-content: flex-start; gap: .15rem;
    border: 1px solid var(--linea); border-radius: 24px; padding: 1.25rem .75rem;
    box-shadow: var(--sombra);
  }
  .menu .marca-logo { display: flex; padding: 0 .6rem; }
  .menu a { flex: 0; flex-direction: row; gap: .7rem; font-size: .95rem; padding: .6rem .75rem; }
  .menu a[aria-current="page"] { background: var(--vidrio-fuerte); box-shadow: 0 2px 10px -4px rgba(0,0,0,.14); }
  .menu .pie { display: block; margin-top: auto; padding: .75rem .6rem 0; border-top: 1px solid var(--linea); font-size: .85rem; }
  .contenido { margin-left: 256px; margin-right: 0; max-width: 1000px; padding: 1.9rem 2.4rem; }
  .solo-celular { display: none !important; }
}

/* ---------- Diálogos y avisos ---------- */
dialog {
  width: min(520px, calc(100% - 2rem)); max-height: calc(100dvh - 2rem);
  border: 1px solid var(--linea); border-radius: 26px; padding: 1.4rem;
  background: var(--vidrio-fuerte); color: var(--texto); box-shadow: var(--sombra-alta);
}
dialog[open] { animation: subir var(--rapido) ease-out; }
dialog::backdrop { background: rgba(20, 20, 24, .28); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.acciones { display: flex; gap: .5rem; justify-content: flex-end; margin-top: 1rem; flex-wrap: wrap; }
.toast {
  position: fixed; left: 50%; bottom: calc(5.5rem + env(safe-area-inset-bottom)); z-index: 50;
  transform: translateX(-50%); max-width: calc(100% - 2rem);
  background: rgba(29, 29, 31, .86); color: #fff; padding: .75rem 1.2rem; border-radius: 999px;
  -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur);
  font-size: .9rem; font-weight: 500; box-shadow: var(--sombra-alta); animation: subir var(--rapido) ease-out;
}
@media (min-width: 900px) { .toast { bottom: 2rem; left: calc(50% + 116px); } }

/* ---------- Horario ---------- */
.dia { padding: .8rem 0; border-bottom: 1px solid var(--linea); }
.dia:last-child { border-bottom: 0; }
.dia-cab { display: flex; align-items: center; justify-content: space-between; }
.tramo { display: flex; align-items: center; gap: .5rem; margin-top: .5rem; }
.tramo input { margin: 0; flex: 1; }
.pasos { list-style: none; padding: 0; margin: 0; }
.pasos li { display: flex; gap: .75rem; align-items: center; padding: .7rem 0; border-bottom: 1px solid var(--linea); }
.pasos li:last-child { border-bottom: 0; }
.pasos .punto { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-size: .8rem; font-weight: 700; background: var(--vidrio-suave); border: 1px solid var(--linea); flex: none; }
.pasos .hecho .punto { background: var(--ok-suave); color: var(--ok); border-color: transparent; }
.vacio { text-align: center; padding: 2.5rem 1rem; color: var(--suave); }

@keyframes aparecer { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
@keyframes subir { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

/* ---------- Campanita ---------- */
.campana { position: relative; }
.campana svg { width: 22px; height: 22px; }
.globo {
  position: absolute; top: 2px; right: 0; min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 99px; background: var(--marca); color: #fff;
  font-size: .68rem; font-weight: 700; line-height: 18px; text-align: center;
  animation: subir var(--rapido) ease-out;
}
.avisos li.nuevo a { font-weight: 600; }
.avisos li.nuevo::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--marca); flex: none; }
.avisos a { color: var(--texto); text-decoration: none; }

/* ---------- Agenda ---------- */
.barra-fecha { display: flex; align-items: center; gap: .35rem; margin-bottom: .75rem; }
.fecha-actual { position: relative; flex: 1; margin: 0; display: flex; align-items: baseline; gap: .5rem; font-size: 1.05rem; cursor: pointer; }
.fecha-actual input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.agenda {
  display: flex; background: var(--vidrio); border: 0; border-radius: var(--radio);
  overflow-x: auto; box-shadow: var(--sombra); position: relative;
}
.col-cab {
  position: sticky; top: 0; z-index: 3; height: 44px; padding: 0 .6rem;
  display: flex; align-items: center; justify-content: center; text-align: center;
  font-weight: 600; font-size: .9rem; background: var(--vidrio-fuerte); border-bottom: 1px solid var(--linea);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.horas-col { position: sticky; left: 0; z-index: 4; width: 52px; flex: none; background: var(--vidrio-fuerte); border-right: 1px solid var(--linea); }
.horas-cuerpo { position: relative; }
.horas-cuerpo span { position: absolute; right: 6px; transform: translateY(-50%); font-size: .7rem; color: var(--suave); white-space: nowrap; }
.horas-cuerpo span:first-child { transform: none; }
.columnas { display: grid; grid-template-columns: repeat(var(--n), minmax(150px, 1fr)); flex: 1; }
.col { border-right: 1px solid var(--linea); min-width: 0; }
.col:last-child { border-right: 0; }
.col-cuerpo {
  position: relative; cursor: pointer;
  background-color: rgba(127, 127, 127, .07);
  background-image: repeating-linear-gradient(to bottom, transparent 0, transparent calc(78px - 1px), var(--linea) calc(78px - 1px), var(--linea) 78px);
}
.abierto { position: absolute; left: 0; right: 0; background: var(--vidrio-fuerte); opacity: .9; }
.cita, .bloqueo {
  position: absolute; left: 4px; right: 4px; z-index: 1; min-height: 0;
  display: flex; flex-direction: column; align-items: flex-start; justify-content: flex-start; gap: 0;
  padding: .3rem .5rem; border-radius: 9px; text-align: left; overflow: hidden; line-height: 1.25;
  font-size: .8rem; border: 1px solid transparent; border-left: 4px solid var(--marca);
  background: var(--marca-suave); color: var(--texto);
}
.cita:hover { border-color: var(--marca); border-left-color: var(--marca); }
.cita strong { font-size: .85rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.cita-hora, .cita-serv { color: var(--suave); font-size: .72rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.cita.baja { flex-direction: row; align-items: center; gap: .4rem; padding-top: 0; padding-bottom: 0; }
.cita.baja .cita-serv { display: none; }
.cita.estado-en_servicio { background: var(--ok-suave); border-left-color: var(--ok); }
.cita.estado-por_cobrar { background: var(--alerta-suave); border-left-color: var(--alerta); }
.cita.estado-pagada { background: var(--fondo); border-left-color: var(--suave); opacity: .75; }
.cita.estado-no_llego { background: var(--error-suave); border-left-color: var(--error); opacity: .7; }
.cita.estado-no_llego strong { text-decoration: line-through; }
.bloqueo {
  border-left-color: var(--suave); color: var(--suave); cursor: pointer;
  background: repeating-linear-gradient(45deg, var(--fondo) 0 8px, var(--linea) 8px 9px);
}
.bloqueo span { display: flex; align-items: center; gap: .3rem; font-size: .75rem; }
.bloqueo svg { width: 14px; height: 14px; }
.ahora { position: absolute; left: 0; right: 0; height: 2px; background: var(--error); z-index: 2; pointer-events: none; }
.ahora::before { content: ""; position: absolute; left: -4px; top: -4px; width: 10px; height: 10px; border-radius: 50%; background: var(--error); }

.etiqueta.estado-confirmada, .etiqueta.estado-pendiente { background: var(--marca-suave); color: var(--marca); border-color: transparent; }
.etiqueta.estado-en_servicio, .etiqueta.estado-pagada { background: var(--ok-suave); color: var(--ok); border-color: transparent; }
.etiqueta.estado-por_cobrar { background: var(--alerta-suave); color: var(--alerta); border-color: transparent; }
.etiqueta.estado-no_llego, .etiqueta.estado-cancelada { background: var(--error-suave); color: var(--error); border-color: transparent; }
.resumen-cita { list-style: none; padding: 0; margin: .5rem 0; }
.resumen-cita li { display: flex; justify-content: space-between; gap: 1rem; padding: .55rem 0; border-bottom: 1px solid var(--linea); }
.resumen-cita li span { color: var(--suave); }
.resumen-cita li strong { text-align: right; }
.fila.tres { grid-template-columns: 1fr 1fr 1fr; }
@media (max-width: 560px) { .fila.tres { grid-template-columns: 1fr; } }
.filtros label { margin-bottom: .5rem; }
.dia-lista { padding: .9rem 0 .3rem !important; border-bottom: 0 !important; }
.hora-lista { font-variant-numeric: tabular-nums; font-weight: 600; min-width: 68px; font-size: .9rem; }
.qr-tarjeta canvas { width: 100%; max-width: 330px; height: auto; display: block; margin: .5rem 0 1rem; border: 1px solid var(--linea); border-radius: 12px; }

/* ---------- Caja ---------- */
.cifras { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .75rem; margin-bottom: 1rem; }
.cifra { background: var(--vidrio); border: 0; border-radius: 18px; padding: 1rem 1.1rem; box-shadow: var(--sombra); }
.cifra span { display: block; font-size: .8rem; color: var(--suave); }
.cifra strong { font-size: 1.25rem; font-variant-numeric: tabular-nums; }
.cifra.destacada { background: var(--tinta); }
.cifra.destacada span { color: var(--sobre-tinta); opacity: .72; }
.cifra.destacada strong { color: var(--sobre-tinta); font-size: 1.5rem; }
.recibo { list-style: none; padding: 0; margin: .5rem 0 1rem; font-variant-numeric: tabular-nums; }
.recibo li { display: flex; justify-content: space-between; gap: 1rem; padding: .5rem 0; border-bottom: 1px dashed var(--linea); }
.recibo li:last-child { border-bottom: 0; }
.recibo li.grande { font-size: 1.1rem; border-bottom-style: solid; }
.cobro-lineas { margin-bottom: .75rem; }
.cobro-linea { display: flex; align-items: center; gap: .5rem; padding: .55rem 0; border-bottom: 1px solid var(--linea); }
.cobro-linea input { width: 96px; margin: 0; min-height: 40px; }
.cobro-total { background: var(--vidrio-suave); border: 1px solid var(--linea); border-radius: 14px; padding: .75rem 1rem; margin-top: .75rem; font-variant-numeric: tabular-nums; }
.cobro-total div { display: flex; justify-content: space-between; padding: .15rem 0; }
.cobro-total .grande { font-size: 1.25rem; }
.segmentos { display: grid; grid-template-columns: repeat(auto-fit, minmax(90px, 1fr)); gap: .4rem; margin: .25rem 0 1rem; }
.segmento { margin: 0; }
.segmento input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.segmento span {
  display: flex; align-items: center; justify-content: center; min-height: 44px; padding: .4rem;
  border: 1px solid var(--linea); border-radius: 12px; font-weight: 500; cursor: pointer; background: var(--vidrio-fuerte);
  transition: background var(--rapido), border-color var(--rapido), color var(--rapido);
}
.segmento input:checked + span { background: var(--tinta); border-color: var(--tinta); color: var(--sobre-tinta); }
.segmento input:focus-visible + span { box-shadow: 0 0 0 3px var(--marca-suave); }
.devuelta { font-size: 1.15rem; font-weight: 700; color: var(--ok); min-height: 1.5rem; margin: 0 0 .5rem; }
.diferencia { min-height: 1.6rem; margin: 0 0 .75rem; }
.cuadre { font-weight: 700; padding: .2rem .6rem; border-radius: 99px; white-space: nowrap; font-size: .9rem; }
.cuadre.ok { background: var(--ok-suave); color: var(--ok); }
.cuadre.sobra { background: var(--alerta-suave); color: var(--alerta); }
.cuadre.falta { background: var(--error-suave); color: var(--error); }
.listo-cierre .cuadre { font-size: 1.2rem; }
.lista li[data-accion] { cursor: pointer; }
.lista li[data-accion]:hover { background: var(--vidrio-suave); }
.lista li.anulada strong { text-decoration: line-through; color: var(--suave); }
.positivo { color: var(--ok); }
.negativo { color: var(--error); }

/* ---------- Clientes e inventario ---------- */
.oculto { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.buscador { margin-bottom: .6rem; }
.buscador input { margin: 0; }
.chips { display: flex; gap: .4rem; overflow-x: auto; padding-bottom: .5rem; margin-bottom: .5rem; }
.chip { flex: none; min-height: 36px; padding: .3rem .85rem; border-radius: 99px; font-size: .85rem; }
.chip[aria-pressed="true"] { background: var(--tinta); color: var(--sobre-tinta); border-color: var(--tinta); }
.avatar-chico, .avatar-grande {
  flex: none; border-radius: 50%; display: grid; place-items: center; font-weight: 700;
  background: var(--marca-suave); color: var(--marca);
}
.avatar-chico { width: 38px; height: 38px; font-size: .8rem; }
.avatar-grande { width: 56px; height: 56px; font-size: 1.1rem; }
textarea { font: inherit; display: block; width: 100%; padding: .6rem .75rem; border: 1px solid var(--linea); border-radius: 10px; background: var(--panel); color: var(--texto); resize: vertical; }
textarea:focus { outline: none; border-color: var(--marca); box-shadow: 0 0 0 3px var(--marca-suave); }
.stock { font-weight: 600; font-size: .85rem; padding: .2rem .6rem; border-radius: 99px; background: var(--vidrio-suave); border: 1px solid var(--linea); white-space: nowrap; font-variant-numeric: tabular-nums; }
.stock.bajo { background: var(--alerta-suave); color: var(--alerta); border-color: transparent; }
.stock.agotado { background: var(--error-suave); color: var(--error); border-color: transparent; }
.cifra.alerta strong { color: var(--alerta); }
.cobro-linea input.cantidad { width: 64px; }
@media (max-width: 560px) {
  .lista.envuelve > li { flex-wrap: wrap; }
  .lista.envuelve > li > .crece { flex-basis: 60%; }
}
.encabezado button { white-space: nowrap; }
@media (max-width: 430px) {
  .encabezado { gap: .4rem; }
  .encabezado button:not(.icono-btn) { padding: .5rem .7rem; font-size: .9rem; }
}

/* ---------- Planes ---------- */
.planes { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: .75rem; margin-bottom: .5rem; }
.plan { background: var(--vidrio); border: 0; border-radius: var(--radio); padding: 1.1rem 1.2rem; box-shadow: var(--sombra); }
.plan.actual { box-shadow: 0 0 0 2px var(--marca), var(--sombra); }
.plan h3 { margin-bottom: .25rem; }
.plan .precio { font-size: 1.4rem; font-weight: 700; margin: 0 0 .4rem; font-variant-numeric: tabular-nums; }
.plan .precio span { font-size: .85rem; font-weight: 400; color: var(--suave); }
.cifra span + strong + span { font-size: .75rem; margin-top: .15rem; }
