/* Claro por omisión aunque el sistema esté en oscuro (titular 2026-10-28): el oscuro solo con el botón (data-tema).
   Sistema visual de cuenta.dessirena.com — tomado de los mockups aprobados (ronda 1, sistema B/N de dessirena.com).
   Auditoría de front 2026-10-28. Un solo archivo para todas las páginas de cuenta (entrar, perfil). */
@font-face { font-family: Carattere; src: url(/estatico/Carattere-Regular.ttf); font-display: swap; }
@font-face { font-family: Geist; src: url(/estatico/Geist-Regular.ttf); font-weight: 400; font-display: swap; }
@font-face { font-family: Geist; src: url(/estatico/Geist-SemiBold.ttf); font-weight: 600 700; font-display: swap; }

:root { --fondo: #fff; --alt: #f2f2f2; --texto: #000; --suave: #4d4d4d; --linea: #d4d4d4; --borde-input: #bdbdbd;
  --ph: #8a8a8a; --sobre: #fff; --boleto: #000; --boleto-txt: #fff; --boleto-suave: #d0d0d0; --sombra: rgba(0,0,0,.14);
  --apagado: #8a8a8a; --ease: cubic-bezier(.22,1,.36,1); color-scheme: light; }
:root[data-tema=oscuro] { --fondo: #111; --alt: #1c1c1c; --texto: #f2f2f2; --suave: #b5b5b5; --linea: #333; --borde-input: #555;
  --ph: #9a9a9a; --sobre: #000; --boleto: #f2f2f2; --boleto-txt: #000; --boleto-suave: #333; --sombra: rgba(0,0,0,.6);
  --apagado: #666; color-scheme: dark; }

* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--fondo); color: var(--texto); font: 16px/1.5 Geist, "Segoe UI", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased; min-height: 100svh; display: flex; flex-direction: column; }
button, input, select { font: inherit; color: inherit; }
a { color: inherit; }
p { margin: 0; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 2px solid var(--texto); outline-offset: 3px; }
svg.i { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: none; }
svg.i.color { stroke: none; }
.cur { font-family: Carattere, "Snell Roundhand", cursive; font-weight: 400; font-size-adjust: .42; line-height: 1.25; text-wrap: balance; margin: 0;
  word-spacing: .12em; }  /* SPEC-C16 F-M2: «Hola, Mariana» sin palabras pegadas */
h1.cur { font-size: 2.9rem; } h2.cur { font-size: 2.3rem; }
.lead { color: var(--suave); }
.rot { font: 700 .7rem Geist; letter-spacing: .14em; text-transform: uppercase; color: var(--suave); margin: 0; }
.ayuda { font-weight: 400; color: var(--suave); font-size: .82rem; }
.legal { font-size: .78rem; color: var(--suave); line-height: 1.45; }
.centro { text-align: center; }

/* Cabecera: la de dessirena.com (estatico/cabecera.css). Barra de regreso al entrar: */
.regreso { display: flex; align-items: center; gap: 10px; background: var(--alt); padding: 9px max(16px, env(safe-area-inset-left)); font-size: .86rem; }
.regreso b { font-weight: 600; } .regreso a { margin-left: auto; font-weight: 600; min-height: 44px; display: inline-flex; align-items: center; }
.avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--texto); color: var(--fondo); display: grid; place-items: center;
  font: 600 1.05rem/1 Geist, system-ui, sans-serif; flex: none; text-decoration: none; }  /* SPEC-C16 F-M2: la inicial en Geist 600 */

/* Botones, enlaces, campos */
.btn { min-height: 52px; border-radius: 999px; display: inline-flex; align-items: center; justify-content: center; gap: 10px; font-weight: 700;
  font-size: 1rem; text-decoration: none; cursor: pointer; padding: 0 22px; border: 0; }
.btn.negro { background: var(--texto); color: var(--fondo); }
.btn.linea { background: var(--fondo); color: var(--texto); border: 1.5px solid var(--texto); }
.btn.gris { background: var(--fondo); color: var(--texto); border: 1.5px solid var(--borde-input); }
.btn.ancho { width: 100%; } .btn.chico { min-height: 44px; font-size: .9rem; padding: 0 16px; }
.btn[disabled], .btn.apagado { background: var(--apagado); color: #fff; border-color: transparent; cursor: default; }
.giro { width: 18px; height: 18px; border: 2.5px solid rgba(255,255,255,.35); border-top-color: #fff; border-radius: 50%; animation: giro .8s linear infinite; }
.giro.oscuro { border-color: var(--linea); border-top-color: var(--texto); }
@keyframes giro { to { rotate: 360deg; } }
.enlace { font-weight: 600; text-decoration: underline; text-underline-offset: 3px; background: none; border: 0; padding: 0 2px; cursor: pointer;
  font-size: .92rem; min-height: 44px; display: inline-flex; align-items: center; }
/* SPEC-C16 F-M1 (I-5): un enlace dentro de una oración sigue el renglón (excepción de WCAG 2.5.8); los botones solos conservan 44 px. */
.enlace.en-texto { display: inline; min-height: 0; padding: 0; font-size: inherit; line-height: inherit; vertical-align: baseline; }
.enlace.chico.gris { font-size: .82rem; font-weight: 500; color: var(--suave); }  /* SPEC-C16 F-M12: «Entrar como equipo», discreto al pie */
h2.rot { font: 700 .7rem Geist; }  /* F-M4: los rótulos que titulan bloque son encabezados, con el mismo aspecto */
/* F-M5: «Saltar al contenido», visible solo con el foco, por encima de la cabecera fija. */
.saltar { position: fixed; left: 12px; top: -120px; z-index: 1000; background: var(--texto); color: var(--fondo); padding: 10px 16px;
  border-radius: 12px; font-weight: 600; text-decoration: none; }
.saltar:focus { top: 12px; }
#contenido { scroll-margin-top: calc(var(--dh-alto, 68px) + 8px); } #contenido:focus { outline: none; }
.o { display: flex; align-items: center; gap: 12px; color: var(--suave); font-size: .82rem; }
.o::before, .o::after { content: ""; flex: 1; height: 1px; background: var(--linea); }
.campo { display: grid; gap: 6px; font-weight: 600; font-size: .9rem; }
.campo input:not([type=checkbox]):not([type=file]), .campo select { min-height: 50px; border: 1.5px solid var(--borde-input); border-radius: 14px;
  padding: 0 14px; background: var(--fondo); font-weight: 400; font-size: 1rem; width: 100%; }
.campo input::placeholder { color: var(--ph); }
.campo input:focus, .campo select:focus { outline: none; border-color: var(--texto); box-shadow: 0 0 0 3px var(--sombra); }
.campo input[aria-invalid=true], .campo select[aria-invalid=true] { border-width: 2px; border-color: var(--texto); background: var(--alt); }
.campo input:disabled { background: var(--alt); color: var(--suave); }
.campo .con-accion { position: relative; } .campo .con-accion .enlace { position: absolute; right: 12px; top: 50%; translate: 0 -50%; font-size: .82rem; }
.err { display: flex; gap: 8px; align-items: flex-start; font-size: .86rem; font-weight: 600; color: var(--texto); }
.err:empty { display: none; }
.err::before { content: "!"; flex: none; width: 18px; height: 18px; border-radius: 50%; background: var(--texto); color: var(--fondo); font: 700 .72rem/18px Geist; text-align: center; }
.toast { background: var(--texto); color: var(--fondo); border-radius: 14px; padding: 12px 14px; font-size: .9rem; display: flex; gap: 10px; align-items: center; }
.toast::before { content: "✓"; font-weight: 700; }
.casilla { display: flex; gap: 12px; align-items: flex-start; font-size: .9rem; line-height: 1.4; cursor: pointer; font-weight: 400; }
.casilla input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.casilla i { flex: none; width: 24px; height: 24px; border: 2px solid var(--texto); border-radius: 7px; margin-top: 1px; display: grid; place-items: center; }
.casilla input:checked + i { background: var(--texto); }
.casilla input:checked + i::after { content: ""; width: 10px; height: 6px; border-left: 2.5px solid var(--fondo); border-bottom: 2.5px solid var(--fondo); rotate: -45deg; translate: 0 -2px; }
.casilla input:focus-visible + i { outline: 2px solid var(--texto); outline-offset: 3px; }
.interruptor { appearance: none; width: 48px; height: 28px; border-radius: 999px; background: var(--borde-input); position: relative; flex: none; cursor: pointer; margin: 0; }
.interruptor::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.3); transition: left .2s var(--ease); }
.interruptor:checked { background: var(--texto); } .interruptor:checked::after { left: 23px; background: var(--fondo); }
.esqueleto { border-radius: 14px; min-height: 64px; background: linear-gradient(90deg, var(--alt) 0, var(--fondo) 40%, var(--alt) 80%); background-size: 200% 100%; animation: brillo 1.2s linear infinite; }
@keyframes brillo { to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .esqueleto, .giro { animation: none; } .interruptor::after { transition: none; } }

/* Código de 6 dígitos */
.otp { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; }
.otp input { height: 58px; width: 100%; border: 1.5px solid var(--borde-input); border-radius: 14px; text-align: center; font: 600 1.6rem Geist; background: var(--fondo); padding: 0; }
.otp input:focus { outline: none; border-color: var(--texto); box-shadow: 0 0 0 3px var(--sombra); }
.otp.mal input { border: 2px solid var(--texto); background: var(--alt); }
.otp.apagado input { color: var(--ph); background: var(--alt); border-color: var(--alt); }

/* Listas, tarjetas, chips */
.lista { list-style: none; margin: 0; padding: 0; border: 1px solid var(--linea); border-radius: 14px; overflow: hidden; }
.lista > li { border-top: 1px solid var(--linea); } .lista > li:first-child { border-top: 0; }
.lista .fila { display: flex; align-items: center; gap: 14px; padding: 12px 14px; min-height: 64px; text-decoration: none; color: inherit;
  width: 100%; background: none; border: 0; text-align: left; cursor: pointer; }
a.fila:hover, button.fila:hover { background: var(--alt); }
.lista .ico { width: 40px; height: 40px; border-radius: 12px; background: var(--alt); display: grid; place-items: center; flex: none; }
.lista .txt { display: grid; min-width: 0; } .lista .txt b { font-size: .96rem; font-weight: 600; }
.lista .txt small { color: var(--suave); font-size: .82rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lista .flecha { margin-left: auto; width: 8px; height: 8px; border-right: 2px solid currentColor; border-top: 2px solid currentColor; rotate: 45deg; flex: none; }
.lista .acc { margin-left: auto; flex: none; }
.tarjeta { border: 1px solid var(--linea); border-radius: 14px; padding: 14px; display: grid; gap: 6px; font-size: .92rem; }
.tarjeta.pred { border: 2px solid var(--texto); }
/* F-M14: radio de 14 px en tarjetas, listas, campos y en Administración (.ficha, .caja, .opcion); el boleto queda para B1. */
.acciones-t .pred-boton { flex-basis: 100%; justify-content: flex-start; }  /* «Usar como predeterminada» en su renglón */
[data-confirmar-pagina] h1.cur { font-size: clamp(2.1rem, 10.5vw, 2.9rem); overflow-wrap: normal; hyphens: manual; }
/* SPEC-C16 D-6: «Eliminar mi cuenta» plegado al final de Privacidad, con el borde de siempre (no el de 2 px de lo predeterminado). */
.tarjeta.baja { display: block; }
.tarjeta.baja > summary { cursor: pointer; font-weight: 600; min-height: 44px; display: flex; align-items: center; list-style: none; }
/* Auditoría completa M-5: con display flex el marcador nativo desaparece (Chrome, Firefox); flecha propia que gira al abrir. */
.tarjeta.baja > summary::-webkit-details-marker { display: none; }
.tarjeta.baja > summary::after { content: ""; margin-left: auto; width: 8px; height: 8px; border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor; rotate: 45deg; translate: 0 -2px; flex: none; transition: rotate .2s var(--ease); }
.tarjeta.baja[open] > summary::after { rotate: -135deg; translate: 0 2px; }
@media (prefers-reduced-motion: reduce) { .tarjeta.baja > summary::after { transition: none; } }
.tarjeta.baja > form { display: grid; gap: 12px; margin-top: 8px; }
.tarjeta .cab { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.acciones-t { display: flex; gap: 16px; flex-wrap: wrap; }
.chip { font: 700 .7rem Geist; letter-spacing: .05em; border-radius: 999px; padding: 3px 9px; background: var(--texto); color: var(--fondo); white-space: nowrap; }
.chip.claro { background: var(--alt); color: var(--texto); }
.chip.linea { background: var(--fondo); color: var(--texto); border: 1px solid var(--texto); }
.vacio { text-align: center; display: grid; gap: 10px; justify-items: center; padding: 30px 10px; }
.vacio .circulo { width: 84px; height: 84px; border-radius: 50%; background: var(--alt); display: grid; place-items: center; }
.vacio .circulo svg { width: 36px; height: 36px; }
.dos { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.confirmar { border: 1.5px solid var(--texto); border-radius: 14px; padding: 12px 14px; display: grid; gap: 8px; }

/* Cupón: boleto con muescas */
.cupon { border-radius: 20px; background: var(--boleto); color: var(--boleto-txt); padding: 18px; position: relative; overflow: hidden; display: grid; gap: 6px; text-decoration: none; }
.cupon::before, .cupon::after { content: ""; position: absolute; top: 50%; width: 22px; height: 22px; border-radius: 50%; background: var(--fondo); translate: 0 -50%; }
.cupon::before { left: -11px; } .cupon::after { right: -11px; }
.cupon .rotulo { font-size: .8rem; }
.cupon .grande { font: 700 2.6rem/1 Geist; letter-spacing: -.02em; }
.cupon .codigo { border: 1.5px solid currentColor; border-radius: 12px; padding: 10px; text-align: center; font: 700 .95rem Geist; letter-spacing: .12em; margin-top: 4px; background: none; color: inherit; cursor: pointer; width: 100%; }
.cupon .codigo.pend { border-style: dashed; opacity: .85; font-weight: 600; font-size: .86rem; cursor: default; }
.cupon small { opacity: .82; font-size: .82rem; }
/* SPEC-C16 F-B2: dentro del boleto el contorno del foco usa el color del texto del boleto (el de la página no se veía) */
.cupon :focus-visible { outline-color: var(--boleto-txt); }
/* SPEC-C16 F-I4 y A2-B0: el código como texto y «Copiar» aparte, con su icono y 44 px (la pieza que reutilizará el boleto de B1) */
.copiable { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 4px 10px; }
.copiable .cod { font: 700 .95rem Geist; letter-spacing: .12em; overflow-wrap: anywhere; user-select: all; }
.copiar { min-height: 44px; min-width: 44px; display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 0 14px;
  border-radius: 12px; border: 1.5px solid currentColor; background: none; color: inherit; font: 600 .86rem Geist; cursor: pointer; white-space: nowrap; }
.copiar svg.i { width: 18px; height: 18px; }
.copiar.hecho svg { display: none; }
.copiar-ayuda { grid-column: 1 / -1; font-size: .82rem; }
.cupon .copiable { border: 1.5px solid currentColor; border-radius: 12px; padding: 4px 4px 4px 12px; margin-top: 4px; }
.cupon .copiar { background: var(--boleto-txt); color: var(--boleto); border-color: var(--boleto-txt); }
.lista .copiable { padding: 0 14px 12px 68px; }
/* SPEC-C16 F-I5: en Inicio el boleto (con su copiar) y «Ver mis cupones» van aparte; separados del pedido también en el teléfono */
.fila-inicio { display: grid; gap: 14px; }
.regalo-inicio { display: grid; gap: 6px; align-content: start; }
.regalo-inicio .enlace { justify-self: start; }
/* Usados y apartados en un pedido sin pagar: en gris, con su estado y sin copiar */
.lista li.gastado .txt b, .lista li.gastado .ico { color: var(--suave); }
.lista li.gastado .txt b { font-weight: 500; }
/* Maqueta c16-a2 §3 (auditoría A2 M-12): fondo gris y, en el usado, el valor tachado */
.lista li.gastado { background: var(--alt); }
.lista li.gastado .ico { background: var(--fondo); }
.lista li.gastado s { text-decoration-thickness: 2px; }
.lista .txt small.cod-usado { letter-spacing: .08em; }
/* SPEC-C16 F-I1 mínimo: en «Otros» la vigencia va completa en su propio renglón (sin «…») */
.lista .txt small.vig { white-space: normal; }
/* K-16 (SPEC-C13 §5.3): campaña en pausa, sin código, en gris (borde punteado; el texto conserva su contraste) */
.lista-pausa { list-style: none; margin: 0 0 16px; padding: 0; display: grid; gap: 10px; }
/* SPEC-C13 §5.4: los cupones que esperan al crear la cuenta (mockup c13 §3) */
.cupones-bienvenida { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.cupones-bienvenida li { border: 1px solid var(--linea); border-radius: 14px; padding: 14px; display: grid; gap: 4px; }
.cupones-bienvenida .cod { font: 700 1.05rem ui-monospace, monospace; letter-spacing: .08em; overflow-wrap: anywhere; }
.cupon-pausa { border: 1.5px dashed var(--linea); border-radius: 14px; padding: 14px; display: grid; gap: 4px; color: var(--suave); }
.cupon-pausa .chip { justify-self: start; }
.cupon-pausa b { color: var(--texto); font-weight: 600; }

/* SPEC-C16 F-I2: en el teléfono el total del pedido se lee completo (el renglón se parte y el chip baja si no cabe) */
.lista-pedidos .fila { flex-wrap: wrap; row-gap: 6px; }
.fila-interruptor { cursor: pointer; }
.lista-pedidos .txt { flex: 1 1 10rem; }
.lista-pedidos .txt small { white-space: normal; }
/* Línea de tiempo del pedido */
.tiempo { list-style: none; margin: 0; padding: 0; display: grid; }
.tiempo li { display: grid; grid-template-columns: 26px 1fr; gap: 12px; padding-bottom: 16px; position: relative; font-size: .92rem; }
.tiempo li::before { content: ""; width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--texto); background: var(--texto); margin-top: 2px; z-index: 1; }
.tiempo li::after { content: ""; position: absolute; left: 9px; top: 20px; bottom: 0; width: 2px; background: var(--texto); }
.tiempo li:last-child::after { display: none; }
.tiempo li.pend::before { background: var(--fondo); border-color: var(--borde-input); } .tiempo li.pend { color: var(--suave); }  /* --ph no llega a 4.5:1 en texto (axe, C5 F1) */
.tiempo li.pend::after, .tiempo li.ult::after { background: var(--linea); }
.tiempo small { display: block; color: var(--suave); }

/* Páginas */
.pagina { flex: 1; width: 100%; max-width: 30rem; margin: 0 auto; padding: 18px max(20px, env(safe-area-inset-left)) 32px; display: flex; flex-direction: column; gap: 14px; }
.sub { display: flex; align-items: center; gap: 10px; padding: 8px max(16px, env(safe-area-inset-left)); border-bottom: 1px solid var(--linea); font-weight: 600; }
.sub .atras { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--linea); display: grid; place-items: center; text-decoration: none; flex: none; }
.sub .atras::before { content: ""; width: 9px; height: 9px; border-left: 2px solid currentColor; border-bottom: 2px solid currentColor; rotate: 45deg; translate: 2px 0; }
.pie { text-align: center; font-size: .8rem; color: var(--suave); padding: 8px 16px 24px; }

/* Perfil con menú lateral (escritorio) */
.perfil { flex: 1; display: grid; }
.lateral { display: none; }
.rejilla { display: grid; gap: 14px; }
/* SPEC-C19 §3.2 (D-1): lo que depende de que haya menú lateral va junto y al corte del marco (1100 px, el de la tienda y la cabecera);
   lo que depende del ancho del contenido sigue en 900 px. La rejilla, el riel y el plegado están en marco.css. */
@media (min-width: 1100px) {
  /* El menú abierto es una pieza (borde y radio de 22 px, como el estante de la tienda) dentro del lateral .mc-izq, que es el pegajoso. */
  .lateral { display: grid; align-content: start; gap: 4px; border: 1px solid var(--linea); border-radius: 22px; padding: 1rem .9rem; background: var(--fondo); }
  .lateral a, .lateral button { display: flex; gap: 12px; align-items: center; min-height: 46px; padding: 0 12px; border-radius: 12px; text-decoration: none; font-weight: 500; background: none; border: 0; cursor: pointer; text-align: left; }
  .lateral a:hover, .lateral button:hover { background: var(--alt); }
  .lateral a[aria-current=page] { background: var(--texto); color: var(--fondo); font-weight: 600; }
  .lateral .salir { margin-top: 18px; color: var(--suave); }
  .perfil .sub { display: none; }
  .solo-movil { display: none !important; }
}
@media (min-width: 900px) {
  .perfil .pagina { max-width: 46rem; margin: 0; padding: 34px 48px 48px; }
  .rejilla.tres { grid-template-columns: repeat(3, 1fr); }
  .rejilla.tres .tarjeta { min-height: 120px; align-content: start; text-decoration: none; }
  .fila-inicio { display: grid; grid-template-columns: 1fr 1.4fr; gap: 14px; align-items: stretch; }
  .lista-inicio { display: none; }
  .dos-esc { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
}
@media (max-width: 899px) { .solo-esc { display: none !important; } }

/* Entrar en escritorio: foto + formulario */
.entrar { flex: 1; display: grid; }
.entrar .foto { display: none; }
@media (min-width: 960px) {
  .entrar { grid-template-columns: 1.05fr 1fr; }
  .entrar .foto { display: block; position: relative; background: #000 url(/estatico/ambiente-botanico.webp) center/cover; min-height: 640px; }
  .entrar .foto::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,0) 40%, rgba(0,0,0,.75)); }
  .entrar .cita { position: absolute; left: 40px; right: 40px; bottom: 36px; color: #fff; z-index: 1; }
  .entrar .cita p { font: 400 2.3rem/1.25 Carattere, cursive; font-size-adjust: .42; margin: 0 0 6px; }
  .entrar .cita img { width: 150px; filter: invert(1); }
  .entrar .pagina { max-width: 560px; padding: 56px 80px; margin: 0; }
  .entrar h1.cur { font-size: 3.4rem; }
}
.pagina.sin-pad { padding: 0; max-width: none; margin: 0; }
.avatar.grande { width: 64px; height: 64px; font-size: 1.5rem; }
.chip.dentro-campo { position: absolute; right: 12px; top: 50%; translate: 0 -50%; }
.sub .sr-titulo { font: 600 1rem Geist; margin: 0; }
.perfil main { min-width: 0; display: flex; flex-direction: column; }
.regalo-enlace { text-decoration: none; display: grid; }
.pedido-h { display: grid; gap: 10px; }
.tiempo.h { grid-auto-flow: column; grid-auto-columns: 1fr; margin-top: 6px; }
.tiempo.h li { grid-template-columns: 1fr; justify-items: start; gap: 8px; padding: 0; font-size: .82rem; font-weight: 600; }
.tiempo.h li::after { left: 20px; right: 0; top: 10px; bottom: auto; width: auto; height: 2px; }
.acciones-perfil { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.archivo { position: relative; } .archivo input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.archivo .btn { width: 100%; pointer-events: none; }
.fila-control { display: flex; align-items: center; gap: 14px; }
.chip { justify-self: start; width: fit-content; }
.lista .acc .chip { justify-self: auto; }
.dos-esc { display: grid; gap: 14px; }
.tiempo.h li { font-size: .74rem; overflow-wrap: anywhere; padding-right: 4px; }
h2.folio { font: 700 1.5rem/1.2 Geist; margin: 0; }

/* Menú agrupado del perfil (propuesta A + acordeón, titular 2026-10-28) */
.pestanas { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 12px max(16px, env(safe-area-inset-left)) 0; border-bottom: 1px solid var(--linea); }
.pestanas::-webkit-scrollbar { display: none; }
.pestanas a { flex: none; min-height: 44px; display: inline-flex; align-items: center; padding: 0 16px; border-radius: 999px;
  border: 1.5px solid var(--linea); text-decoration: none; font-weight: 600; font-size: .9rem; margin-bottom: 12px; white-space: nowrap; }
.pestanas a[aria-current=page] { background: var(--texto); color: var(--fondo); border-color: var(--texto); }
.titulo-grupo { display: none; }
.lateral .grupo { display: grid; gap: 2px; }
.lateral .flecha-g { margin-left: auto; width: 7px; height: 7px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
  rotate: 45deg; translate: 0 -2px; transition: rotate .2s var(--ease), translate .2s var(--ease); }
.lateral [aria-expanded=false] .flecha-g { rotate: -45deg; translate: -2px 0; }
/* Acordeón: se desliza (filas 0fr→1fr) y lo cerrado sale del orden de tabulación con visibility */
.lateral .hijos { display: grid; grid-template-rows: 1fr; padding-left: 44px; opacity: 1;
  transition: grid-template-rows .3s var(--ease), opacity .24s var(--ease), visibility 0s; }
.lateral .hijos > div { display: grid; gap: 2px; min-height: 0; overflow: hidden; }
.lateral .hijos[data-cerrado] { grid-template-rows: 0fr; opacity: 0; visibility: hidden;
  transition: grid-template-rows .26s var(--ease), opacity .16s ease-out, visibility 0s .26s; }
@media (min-width: 1100px) {
  .lateral .grupo > button { width: 100%; }
  .lateral .grupo.activo > button { font-weight: 600; }
  .lateral .hijos a { min-height: 44px; font-size: .92rem; }  /* SPEC-C16 F-I9: 44 px de zona táctil */
  .lateral .etq { white-space: nowrap; overflow: hidden; }
  .titulo-grupo { display: block; padding: 30px 48px 4px; }
  .pestanas { padding: 0 48px; gap: 28px; }
  .pestanas a { border: 0; border-radius: 0; padding: 0 2px; min-height: 52px; margin: 0; color: var(--suave); position: relative; }
  .pestanas a:hover { color: var(--texto); }
  .pestanas a[aria-current=page] { background: none; color: var(--texto); }
  .pestanas a[aria-current=page]::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 3px; border-radius: 3px; background: var(--texto); }
  .lateral a, .lateral button { position: relative; }
}

/* Cambio entre páginas del perfil: la cabecera y el menú no se mueven; el contenido se funde y la marca activa se desliza
   (el nombre «menu» lo lleva ahora el lateral .mc-izq, en marco.css) */
@view-transition { navigation: auto; }
.lateral a[aria-current=page] { view-transition-name: menu-activo; }
.titulo-grupo { view-transition-name: titulo; }
.pestanas a[aria-current=page] { view-transition-name: pestana-activa; }
.perfil [data-zona] { view-transition-name: contenido; }
::view-transition-group(*) { animation-duration: .34s; animation-timing-function: cubic-bezier(.22,1,.36,1); }
::view-transition-old(contenido) { animation: .14s ease-out both vt-salir; }
::view-transition-new(contenido) { animation: .34s cubic-bezier(.22,1,.36,1) .04s both vt-entrar; }
@keyframes vt-salir { to { opacity: 0; } }
@keyframes vt-entrar { from { opacity: 0; translate: 0 6px; } }
/* Lo que llega de la API aparece suave en lugar de sustituir de golpe al esqueleto */
[data-zona].aparece { animation: aparece .3s cubic-bezier(.22,1,.36,1) both; }
@keyframes aparece { from { opacity: 0; translate: 0 4px; } }
.lateral a, .lateral button { transition: background-color .18s ease-out, color .18s ease-out; }
@media (prefers-reduced-motion: reduce) {
  .lateral .flecha-g, .lateral .hijos, .lateral a, .lateral button { transition: none; }
  [data-zona].aparece { animation: none; }
  ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; }
}

/* «Confirma que eres tú» (titular 2026-10-28): hoja inferior en el teléfono, ventana centrada en escritorio */
.dlg-confirmar { border: 0; padding: 22px 20px calc(22px + env(safe-area-inset-bottom)); background: var(--fondo); color: var(--texto);
  width: 100%; max-width: 100%; margin: auto 0 0; border-radius: 22px 22px 0 0; box-shadow: 0 -10px 40px var(--sombra); }
.dlg-confirmar::backdrop { background: rgb(0 0 0 / .4); }
.dlg-confirmar[open] { animation: dlg-sube .32s cubic-bezier(.22,1,.36,1); }
@keyframes dlg-sube { from { translate: 0 24px; opacity: 0; } }
@media (min-width: 640px) { .dlg-confirmar { max-width: 26rem; margin: auto; border-radius: 22px; padding: 26px; } }
@media (prefers-reduced-motion: reduce) { .dlg-confirmar[open] { animation: none; } }

/* Administración (SPEC-C3, variante B) */
.lateral .admin-enlace, .lateral .admin-grupo { margin-top: 14px; border-top: 1px solid var(--linea); padding-top: 10px; }
.lateral .admin-grupo { display: grid; gap: 4px; }
.perfil.admin .pagina.admin { max-width: none; }
@media (min-width: 900px) { .perfil.admin .pagina.admin { max-width: 72rem; padding: 26px 40px 48px; } }
.periodo { display: flex; gap: 6px; flex-wrap: wrap; }
.periodo button { min-height: 36px; padding: 0 12px; border-radius: 999px; border: 1.5px solid var(--linea); background: none; font-weight: 600; font-size: .84rem; cursor: pointer; color: inherit; }
.periodo button[aria-pressed=true] { background: var(--texto); color: var(--fondo); border-color: var(--texto); }
.cifras { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 900px) { .cifras { grid-template-columns: repeat(4, 1fr); } }
.cifra { border: 1px solid var(--linea); border-radius: 16px; padding: 12px 14px; display: grid; gap: 2px; align-content: start; }
.cifra .rot { font-size: .64rem; }
.cifra b { font: 700 1.7rem/1.1 Geist; letter-spacing: -.02em; }
.cifra small { color: var(--suave); font-size: .78rem; }
.cifra.pend b { color: var(--ph); }
.barras { display: flex; align-items: flex-end; gap: 3px; height: 88px; padding: 8px 0 0; border-bottom: 1px solid var(--linea); }
.barras i { flex: 1; background: var(--texto); border-radius: 3px 3px 0 0; opacity: .85; min-height: 2px; }
.barras i.hoy { opacity: 1; }
.ejes { display: flex; justify-content: space-between; font-size: .7rem; color: var(--suave); }
.alertas .fila .ico { background: var(--texto); color: var(--fondo); }
.tabla { width: 100%; border-collapse: collapse; font-size: .88rem; }
.tabla th { text-align: left; font: 700 .66rem Geist; letter-spacing: .12em; text-transform: uppercase; color: var(--suave); padding: 8px 10px; border-bottom: 1px solid var(--linea); }
.tabla td { padding: 10px; border-bottom: 1px solid var(--linea); vertical-align: middle; }
.tabla .n { text-align: right; font-variant-numeric: tabular-nums; }
.tabla a.quien { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.tabla .quien .avatar { width: 32px; height: 32px; font-size: .86rem; }
.tabla .quien small { display: block; color: var(--suave); }
.tabla tr:has(a.quien):hover td { background: var(--alt); }
.buscar { display: flex; gap: 8px; }
.buscar input { flex: 1; min-height: 46px; border: 1.5px solid var(--borde-input); border-radius: 999px; padding: 0 16px; background: var(--fondo); font-size: 1rem; }
.filtros { display: flex; gap: 6px; flex-wrap: wrap; }
.filtros button { font: 700 .7rem Geist; letter-spacing: .05em; border-radius: 999px; padding: 4px 10px; border: 0; background: var(--alt); color: var(--texto); cursor: pointer; }
.filtros button[aria-pressed=true] { background: var(--texto); color: var(--fondo); }
.chip.ok { background: var(--alt); color: var(--texto); }
.chip.bloq { background: var(--texto); color: var(--fondo); }
.chip.baja { background: var(--fondo); border: 1px solid var(--linea); color: var(--suave); }
.con-ficha { display: grid; gap: 14px; }
@media (min-width: 1100px) { .con-ficha { grid-template-columns: 1fr 24rem; align-items: start; } .ficha { position: sticky; top: calc(var(--dh-alto, 0px) + 21px); transition: top .35s ease; } }
.ficha { border: 1px solid var(--linea); border-radius: 14px; padding: 16px; display: grid; gap: 12px; }
.ficha .cab { display: flex; gap: 12px; align-items: center; }
.ficha .cab b { font-size: 1.05rem; display: block; } .ficha .cab small { color: var(--suave); overflow-wrap: anywhere; }
.ficha dl { display: grid; grid-template-columns: auto 1fr; gap: 4px 12px; margin: 0; font-size: .86rem; }
.ficha dt { color: var(--suave); } .ficha dd { margin: 0; overflow-wrap: anywhere; }
.ficha .oculto { color: var(--ph); letter-spacing: .1em; }
.ficha .ver { font-size: .78rem; margin-left: 6px; min-height: 32px; }
.ficha .acciones { display: grid; gap: 6px; }
.ficha .acciones .btn { min-height: 42px; font-size: .9rem; }
.notas { background: var(--alt); border-radius: 12px; padding: 10px 12px; font-size: .84rem; display: grid; gap: 6px; }
.hist { list-style: none; margin: 0; padding: 0; }
.hist li { display: grid; grid-template-columns: 5.6rem 1fr; gap: 8px; padding: 4px 0; font-size: .82rem; border-top: 1px dashed var(--linea); }
.hist li small { color: var(--suave); }
.tabla-alt { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.con-ficha > * { min-width: 0; }
.ficha { min-width: 0; }
.ficha dl { grid-template-columns: minmax(5.5rem, auto) minmax(0, 1fr); }
.buscar input { min-width: 0; }
.ficha .cab > div { min-width: 0; }
@media (max-width: 899px) {
  .tabla { table-layout: fixed; }
  .tabla th, .tabla td { padding: 8px 6px; overflow-wrap: anywhere; }
  .tabla a.quien { align-items: flex-start; } .tabla .quien > span { min-width: 0; }
}
.ficha { grid-template-columns: minmax(0, 1fr); } .ficha > * { min-width: 0; }
.notas { min-width: 0; } .notas > * { min-width: 0; }
.buscar input[type=date], .buscar select { min-height: 46px; border: 1.5px solid var(--borde-input); border-radius: 999px; padding: 0 14px; background: var(--fondo); font-size: .95rem; min-width: 0; }
@media (max-width: 639px) { .buscar { flex-wrap: wrap; } .buscar input, .buscar select { flex: 1 1 10rem; } }

/* Bienvenida de una cuenta importada (SPEC-C4 C2, mockups c4) */
.caja { border: 1px solid var(--linea); border-radius: 14px; padding: 14px 16px; font-size: .92rem; display: grid; gap: 6px; }
.caja.regalo { background: #f4ece3; border-color: #f4ece3; }
:root[data-tema=oscuro] .caja.regalo { background: var(--alt); border-color: var(--alt); }
.chip.confirmar { background: #fff1c9; color: #5a4300; }
.opcion { border: 1px solid var(--linea); border-radius: 14px; padding: 14px 16px; display: flex; gap: 12px; align-items: flex-start; }
.opcion input { margin-top: 4px; }
.opcion b { display: block; }

/* Privacidad con días hábiles (SPEC-C10 §5.5, mockup c10): el semáforo lleva texto, no depende del color */
.cab-privacidad { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.cab-privacidad h2 { margin: 0; }
.comando-tienda code { overflow-wrap: anywhere; font-size: .92em; }  /* SPEC-C16 A-7: el comando de la tienda, sin desbordar a 390 */
.sem { display: inline-block; font: 600 .78rem Geist; padding: 2px 9px; border-radius: 999px; border: 1px solid var(--texto); white-space: nowrap; }
.sem.rojo { background: var(--texto); color: var(--fondo); }
.sem.ambar { border-style: dashed; }
.sem.verde { border-color: var(--linea); color: var(--suave); }
.marca { display: inline-block; font: 600 .68rem Geist; letter-spacing: .06em; text-transform: uppercase; border: 1px solid var(--linea);
  border-radius: 6px; padding: 1px 6px; margin: 4px 6px 0 0; color: var(--texto); }
.pend-lista .txt small { white-space: normal; }
.pend-lista .acc { display: grid; gap: 6px; justify-items: end; }
.acciones-fila { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
@media (min-width: 900px) { .solo-tel { display: none !important; } }
.dlg-privacidad { max-height: 92vh; overflow-y: auto; }
@media (min-width: 640px) { .dlg-privacidad { max-width: 30rem; } }
.dlg-privacidad fieldset.opciones { border: 0; padding: 0; margin: 8px 0; display: grid; gap: 4px; }
.dlg-privacidad fieldset.opciones legend { font-weight: 600; font-size: .9rem; margin-bottom: 4px; }
.dlg-privacidad fieldset.opciones label, .opcion-chica { display: flex; gap: 10px; align-items: center; font-weight: 400; min-height: 32px; }
.dlg-privacidad fieldset.opciones input, .opcion-chica input { width: 18px; height: 18px; margin: 0; flex: none; accent-color: var(--texto); }
.dlg-privacidad [data-resultados] { display: grid; gap: 4px; margin-top: 8px; }
.dlg-privacidad .casilla { margin: 10px 0; }
.lista-simple { margin: 0; padding-left: 18px; display: grid; gap: 6px; overflow-wrap: anywhere; }
.cab-privacidad ~ .rot { margin-top: 22px; }
/* SPEC-C16 F-I6: el título del detalle recibe el foco al abrir (para el lector de pantalla); no es un control, sin contorno */
h2.folio[data-titulo]:focus { outline: none; }
@media (prefers-reduced-motion: reduce) { .ficha { transition: none; } }  /* SPEC-C18 §3 */
