/* El panel interno de a Media Voz. Diseño de Kroma, aprobado por Arlex el 22-oct-2026:
   ~/projects/kroma/entregas/a-media-voz/panel/BRIEF.md. Los colores son los de la marca, sin acento:
   la acción va en tinta llena. Lo que pide atención va en negrita, no en color. */

@font-face { font-family: 'Instrument Sans'; src: url('fuentes/InstrumentSans-Regular.ttf') format('truetype'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Instrument Sans'; src: url('fuentes/InstrumentSans-Medium.ttf') format('truetype'); font-weight: 500; font-display: swap; }
@font-face { font-family: 'Instrument Sans'; src: url('fuentes/InstrumentSans-SemiBold.ttf') format('truetype'); font-weight: 600; font-display: swap; }
@font-face { font-family: 'Instrument Sans'; src: url('fuentes/InstrumentSans-Italic.ttf') format('truetype'); font-weight: 400; font-style: italic; font-display: swap; }

:root {
  --bg: #F4EDE0; --fg: #1E3A5F; --block: #EAE0CE; --sec: #4A5E78;
  --line: rgba(30, 58, 95, .15); --edge: rgba(30, 58, 95, .35);
  --bb: #1E3A5F; --bf: #F4EDE0; --veil: rgba(30, 58, 95, .45);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-tema="claro"]) {
    --bg: #0F1A2A; --fg: #F4EDE0; --block: #1A2940; --sec: #A9B4C2;
    --line: rgba(244, 237, 224, .14); --edge: rgba(244, 237, 224, .35);
    --bb: #F4EDE0; --bf: #0F1A2A; --veil: rgba(0, 0, 0, .6);
    color-scheme: dark;
  }
}
:root[data-tema="oscuro"] {
  --bg: #0F1A2A; --fg: #F4EDE0; --block: #1A2940; --sec: #A9B4C2;
  --line: rgba(244, 237, 224, .14); --edge: rgba(244, 237, 224, .35);
  --bb: #F4EDE0; --bf: #0F1A2A; --veil: rgba(0, 0, 0, .6);
  color-scheme: dark;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--fg); font-family: 'Instrument Sans', system-ui, sans-serif; font-size: 16px; line-height: 1.35; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3 { margin: 0; }
.num { font-variant-numeric: tabular-nums; }
.sec { color: var(--sec); }
.b { font-weight: 600; }
.r { font-weight: 400; }
.chico { font-size: 14px; }
.etq { font-size: 14px; font-weight: 600; }
svg { flex-shrink: 0; }

/* --- Armazón: pestañas abajo en el teléfono, menú lateral en la computadora --- */
.app { min-height: 100vh; display: flex; flex-direction: column; }
.contenido { flex-grow: 1; display: flex; flex-direction: column; min-width: 0; padding-bottom: 72px; }
.pestanas { position: fixed; left: 0; right: 0; bottom: 0; height: calc(72px + env(safe-area-inset-bottom)); padding-bottom: env(safe-area-inset-bottom);
  background: var(--bg); border-top: 1px solid var(--line); display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); z-index: 10; }
.pestanas a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; font-size: 14px; color: var(--sec); }
.pestanas a[aria-current="page"] { color: var(--fg); font-weight: 600; }
.lateral { display: none; }
.marca { display: flex; align-items: baseline; font-size: 20px; }
.marca .a { font-size: 12px; font-weight: 600; margin-right: 3px; }
.marca .m { font-weight: 600; margin-right: 2px; }

.cabecera { display: flex; justify-content: space-between; align-items: center; padding: 14px 12px 14px 20px; }
.cabecera.volver { padding: 10px 12px; }
.icono { width: 44px; height: 44px; border: 0; background: transparent; display: flex; align-items: center; justify-content: center; border-radius: 10px; }
.atras { height: 44px; display: flex; align-items: center; gap: 4px; padding: 0 6px; font-size: 16px; }
.boton-texto { height: 44px; padding: 0 10px; border: 0; background: transparent; font-size: 16px; font-weight: 600; }

.pagina { display: flex; flex-direction: column; gap: 24px; padding: 4px 20px 32px; }
.titulo { padding: 18px 20px 8px; display: flex; flex-direction: column; gap: 14px; }
.titulo h1 { font-size: 32px; font-weight: 600; }

/* --- Piezas --- */
.bloque { background: var(--block); border-radius: 14px; padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.fila { display: flex; gap: 12px; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); min-height: 52px; }
.fila-link { justify-content: space-between; }
.fila .cuerpo { display: flex; flex-direction: column; gap: 1px; min-width: 0; flex-grow: 1; }
.fila .nombre { font-size: 17px; }
.fila .detalle { font-size: 14px; color: var(--sec); }
.lista { display: flex; flex-direction: column; }
.lista-cabeza { display: flex; justify-content: space-between; align-items: center; font-size: 14px; padding-bottom: 6px; gap: 12px; }
.lista-cabeza .b { font-weight: 600; }
.lista-cabeza a, .lista-cabeza button { min-height: 44px; display: flex; align-items: center; font-weight: 600; border: 0; background: transparent; padding: 0; font-size: 14px; }

.avatar { width: 40px; height: 40px; border-radius: 20px; background: var(--block); display: flex; align-items: center; justify-content: center; font-weight: 600; font-size: 14px; flex-shrink: 0; position: relative; }
.avatar.g44 { width: 44px; height: 44px; }
.avatar.grupo { border-radius: 12px; }
.avatar .insignia { position: absolute; right: -4px; bottom: -4px; min-width: 20px; height: 20px; padding: 0 4px; border-radius: 10px; background: var(--fg); color: var(--bg); font-size: 12px; display: flex; align-items: center; justify-content: center; border: 2px solid var(--bg); }
.avatar.grande { width: 84px; height: 84px; border-radius: 42px; font-size: 28px; }
.caras { display: flex; padding-left: 14px; }
.caras .avatar { width: 60px; height: 60px; border-radius: 30px; font-size: 18px; border: 3px solid var(--bg); margin-left: -14px; }

.pastilla { font-size: 14px; border: 1px solid var(--fg); border-radius: 12px; padding: 2px 10px; white-space: nowrap; }
.pastilla.suave { border-color: var(--edge); }

.campo { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 600; }
.campo input, .campo select, .campo textarea, .entrada { height: 48px; border-radius: 10px; border: 1px solid var(--edge); background: transparent; padding: 0 14px; font-size: 17px; font-weight: 400; color: var(--fg); min-width: 0; width: 100%; }
.campo textarea { height: auto; min-height: 96px; padding: 12px 14px; line-height: 1.45; resize: vertical; }
.campo select { appearance: none; background-image: none; }
.bloque .campo input, .bloque .entrada { background: var(--bg); }
.campo .ayuda { font-weight: 400; color: var(--sec); }
.dos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }

.buscar { display: flex; align-items: center; gap: 10px; height: 48px; padding: 0 14px; border: 1px solid var(--edge); border-radius: 12px; }
.buscar input { border: 0; outline: 0; background: transparent; font-size: 16px; color: var(--fg); flex-grow: 1; min-width: 0; }

.filtros { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: space-between; }
.filtros .grupo { display: flex; gap: 8px; flex-wrap: wrap; }
.filtro { display: flex; align-items: center; gap: 8px; height: 44px; padding: 0 14px; border: 0; border-radius: 22px; background: var(--block); color: var(--fg); font-size: 16px; }
.filtro strong { font-weight: 600; }

.boton { height: 52px; border: 0; border-radius: 12px; background: var(--bb); color: var(--bf); font-size: 17px; font-weight: 600; display: flex; align-items: center; justify-content: center; gap: 10px; padding: 0 20px; }
.boton.chico { height: 44px; border-radius: 10px; font-size: 16px; padding: 0 16px; }
.boton.borde { background: transparent; color: var(--fg); border: 2px solid var(--fg); }
.boton.punteado { background: transparent; color: var(--fg); border: 1px dashed var(--edge); font-size: 16px; }
.boton[disabled] { opacity: .5; cursor: default; }
.flotante { position: fixed; right: 20px; bottom: calc(92px + env(safe-area-inset-bottom)); height: 56px; padding: 0 20px 0 16px; border-radius: 28px; background: var(--bb); color: var(--bf); display: flex; align-items: center; gap: 8px; font-size: 16px; font-weight: 600; border: 0; z-index: 9; }

.selector { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; padding: 4px; border-radius: 12px; background: var(--block); }
.selector button { height: 40px; border: 0; border-radius: 9px; background: transparent; font-size: 15px; }
.selector button[aria-checked="true"] { background: var(--bg); font-weight: 600; }
.opciones { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.opciones button { height: 44px; border-radius: 10px; border: 1px solid var(--edge); background: transparent; font-size: 15px; font-weight: 400; padding: 0 4px; }
.formulario { max-width: 760px; width: 100%; }
.opciones button[aria-checked="true"] { border: 2px solid var(--fg); font-weight: 600; }
.opciones.tres { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.opciones.cuatro { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.elegido { min-height: 48px; border-radius: 10px; border: 1px solid var(--edge); padding: 8px 14px; display: flex; align-items: center; justify-content: space-between; gap: 10px; width: 100%; background: transparent; text-align: left; font-size: 17px; font-weight: 400; }
.elegido .cambiar { font-size: 15px; font-weight: 600; text-decoration: underline; flex-shrink: 0; }

details.pliegue { border-top: 1px solid var(--line); }
details.pliegue > summary { min-height: 56px; display: flex; justify-content: space-between; align-items: center; gap: 12px; cursor: pointer; list-style: none; }
details.pliegue > summary::-webkit-details-marker { display: none; }
details.pliegue[open] > summary svg { transform: rotate(180deg); }
details.pliegue .dentro { padding: 0 0 14px; display: flex; flex-direction: column; gap: 8px; }
details.mas > summary { min-height: 44px; font-size: 16px; }

.barra { height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; }
.barra > div { height: 100%; background: var(--fg); }
.barra-h { height: 10px; display: flex; }
.barra-h > div { height: 10px; background: var(--fg); border-radius: 0 4px 4px 0; min-width: 2px; }

.alarma { display: flex; gap: 10px; align-items: flex-start; border: 2px solid var(--fg); border-radius: 10px; padding: 10px 12px; font-size: 15px; line-height: 1.4; }
.visto { display: flex; gap: 8px; align-items: center; font-size: 15px; color: var(--sec); }
.aviso { display: flex; gap: 10px; align-items: center; background: var(--block); border-radius: 10px; padding: 10px 12px; font-size: 15px; line-height: 1.4; }
.aviso span { flex-grow: 1; }
.vacio { padding: 28px 0; color: var(--sec); font-size: 16px; line-height: 1.45; }
.error { font-weight: 600; font-size: 15px; }

.cifras { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.cifras.dos-col { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.cifra { background: var(--block); border-radius: 12px; padding: 12px; display: flex; flex-direction: column; gap: 2px; }
.cifra .n { font-size: 28px; font-weight: 600; line-height: 1.1; font-variant-numeric: tabular-nums; }
.cifra .que { font-size: 14px; color: var(--sec); line-height: 1.3; }

/* --- Panel que sube desde abajo (filtros, roles, sumar a la noche, enviar) --- */
.velo { position: fixed; inset: 0; background: var(--veil); z-index: 20; display: flex; flex-direction: column; justify-content: flex-end; }
.hoja { background: var(--bg); border-radius: 18px 18px 0 0; max-height: 92vh; display: flex; flex-direction: column; padding-bottom: env(safe-area-inset-bottom); }
.hoja .asa { display: flex; justify-content: center; padding-top: 8px; }
.hoja .asa span { width: 40px; height: 5px; border-radius: 3px; background: var(--edge); }
.hoja .cabeza { display: flex; justify-content: space-between; align-items: center; padding: 8px 20px 10px; gap: 12px; }
.hoja .cabeza h2 { font-size: 20px; font-weight: 600; }
.hoja .cuerpo { flex-grow: 1; min-height: 0; overflow-y: auto; padding: 0 20px 12px; display: flex; flex-direction: column; }
.hoja .pie { padding: 12px 20px 20px; border-top: 1px solid var(--line); display: flex; gap: 10px; align-items: center; }
.hoja .pie span { flex-grow: 1; font-size: 16px; }
.opcion { display: flex; align-items: center; gap: 14px; min-height: 48px; border-top: 1px solid var(--line); font-size: 17px; width: 100%; background: transparent; border-left: 0; border-right: 0; border-bottom: 0; text-align: left; padding: 0; }
.opcion input { width: 22px; height: 22px; margin: 0; accent-color: var(--fg); flex-shrink: 0; }
.opcion .n { margin-left: auto; font-size: 14px; color: var(--sec); }
.grupo-roles { font-size: 14px; font-weight: 600; color: var(--sec); padding: 14px 0 4px; }

.toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(96px + env(safe-area-inset-bottom)); background: var(--fg); color: var(--bg); padding: 12px 18px; border-radius: 12px; font-size: 15px; font-weight: 600; z-index: 30; max-width: calc(100vw - 40px); }

/* --- El orden nuevo (22-oct-2026): Inicio, Ventas, Eventos. Mesa de Kroma, prefijo n- --- */
/* El título de un grupo, más grande y cerrado con una raya de tinta: las rayas finas quedan solo entre las filas,
   dos niveles de línea como en un libro de cuentas (Kroma, 23-oct). */
.lista-titulo { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding-bottom: 8px; border-bottom: 2px solid var(--fg); }
.lista-titulo h2 { font-size: 22px; font-weight: 600; }
.lista-titulo + .doble { border-top: 0; }
.lista-titulo > span:last-child { font-size: 17px; font-weight: 600; font-variant-numeric: tabular-nums; }
.lista-titulo > span.chico:last-child { font-size: 14px; font-weight: 400; text-align: right; }
.rejilla { display: grid; gap: 0 12px; align-items: center; min-width: 560px; }
.rejilla > span { padding: 8px 0; border-top: 1px solid var(--line); min-height: 60px; display: flex; align-items: center; }
.rejilla > .cab { border-top: 0; min-height: 0; }
.rejilla .celda { flex-direction: column; align-items: flex-end; justify-content: center; gap: 4px; }
.rejilla input { width: 96px; height: 40px; border-radius: 10px; border: 1px solid var(--edge); background: var(--bg); padding: 0 10px; font-size: 16px; font-weight: 600; text-align: right; font-variant-numeric: tabular-nums; }
.rejilla input[disabled] { border-color: transparent; background: transparent; }
.doble, .evento-fila { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 60px; padding: 8px 0; border-top: 1px solid var(--line); font-variant-numeric: tabular-nums; }
.doble .izq, .evento-fila .izq, .plata-fila .izq { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.doble .der, .evento-fila .der, .plata-fila .der { display: flex; flex-direction: column; gap: 2px; align-items: flex-end; flex-shrink: 0; text-align: right; }
.doble .l1, .evento-fila .l1, .plata-fila .l1 { font-size: 17px; }
.doble .der .l1, .evento-fila .der .l1, .plata-fila .der .l1 { font-weight: 600; }
.doble .izq .l2, .evento-fila .izq .l2, .plata-fila .izq .l2 { font-size: 14px; color: var(--sec); }
.doble .der .l2, .evento-fila .der .l2, .plata-fila .der .l2 { font-size: 14px; }
.evento-fila { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; min-height: 68px; }
.evento-fila .dia { display: flex; flex-direction: column; align-items: center; }
.evento-fila .dia .d { font-size: 24px; font-weight: 600; line-height: 1; }
.plata-fila { display: flex; flex-direction: column; gap: 6px; padding: 10px 0; border-top: 1px solid var(--line); }
.plata-fila .arriba { display: flex; justify-content: space-between; gap: 12px; }
.mes { display: flex; align-items: center; justify-content: space-between; }
.mes .icono:first-child { margin-left: -12px; }
.mes .icono:last-child { margin-right: -12px; }
.mes > span { font-size: 17px; font-weight: 600; }
.quedo { display: flex; flex-direction: column; gap: 4px; font-variant-numeric: tabular-nums; }
.quedo .grande { font-size: 56px; line-height: 1; font-weight: 600; letter-spacing: -0.01em; }
.proximo { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 60px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.selector.cuantas { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.selector.cuantas button { height: 44px; font-size: 17px; font-weight: 600; }
.selector.cuantas button[aria-checked="true"] { background: var(--bb); color: var(--bf); }
.pestanas-noche { display: grid; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.pestanas-noche a { height: 52px; display: flex; align-items: center; justify-content: center; border-bottom: 3px solid transparent; font-size: 16px; }
.pestanas-noche a[aria-selected="true"] { border-bottom-color: var(--fg); font-weight: 600; }
.cuenta { display: grid; gap: 6px 16px; border-top: 1px solid var(--line); padding-top: 12px; font-size: 16px; align-items: baseline; }
.cuenta .der { text-align: right; }
.linea { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 8px 0; border-top: 1px solid var(--line); }
.linea .opcion { border: 0; min-height: 44px; flex-direction: column; align-items: flex-start; gap: 1px; min-width: 0; }
.linea .opcion[disabled] { cursor: default; color: inherit; }
.linea input { width: 96px; height: 44px; border-radius: 10px; border: 1px solid var(--edge); background: var(--bg); padding: 0 10px; font-size: 17px; font-weight: 600; text-align: right; font-variant-numeric: tabular-nums; }
.linea input[disabled], .bloque input[disabled] { border-color: transparent; background: transparent; padding-left: 0; }
.oculto { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.cifras-caja { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.cifras-caja > div { background: var(--block); border-radius: 12px; padding: 12px; display: flex; flex-direction: column; gap: 2px; }
.cifras-caja .n { font-size: 28px; font-weight: 600; line-height: 1.1; }
@media (min-width: 1024px) {
  .tres-listas { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 32px; }
  .cifras-caja { grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; max-width: 720px; }
  .cifras-caja > div { padding: 16px; }
  .cifras-caja .n { font-size: 36px; }
  .l2-pliegues { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); column-gap: 40px; }
}
@media (max-width: 1023px) {
  .tres-listas { display: flex; flex-direction: column; gap: 26px; }
}

/* --- La computadora --- */
@media (min-width: 1024px) {
  .app { flex-direction: row; }
  .pestanas, .flotante.solo-tel, .solo-tel { display: none !important; }
  .lateral { display: flex; position: sticky; top: 0; height: 100vh; width: 240px; flex-shrink: 0; padding: 28px 20px; border-right: 1px solid var(--line); flex-direction: column; gap: 4px; }
  .lateral .marca { font-size: 22px; padding: 0 12px 24px; }
  .lateral .marca .a { font-size: 13px; }
  .lateral a, .lateral button { display: flex; align-items: center; gap: 12px; height: 44px; padding: 0 12px; border-radius: 10px; font-size: 16px; color: var(--sec); border: 0; background: transparent; text-align: left; }
  .lateral a[aria-current="page"] { background: var(--block); color: var(--fg); font-weight: 600; }
  .lateral .tema { margin-top: auto; }
  .contenido { padding-bottom: 0; }
  .pagina { padding: 28px 40px 48px; gap: 28px; }
  .titulo { padding: 28px 40px 8px; }
  .titulo h1 { font-size: 40px; }
  .cabecera { display: none; }
  .cabecera.volver { display: flex; padding: 20px 34px 0; }
  /* Ocupa la pantalla entera: con el tope de 1160px, en una pantalla grande sobraba un tercio a la derecha (Arlex, 23-oct). */
  .ancho { max-width: none; }
  .lista-titulo h2 { font-size: 24px; }
  .columnas { display: flex; flex-wrap: wrap; gap: 40px; align-items: flex-start; }
  .columnas > .principal { flex: 3 1 420px; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
  .columnas > .costado { flex: 2 1 300px; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
  .noche-local { font-size: 64px !important; letter-spacing: -0.015em; }
  .noche-cartel { font-size: 24px !important; }
  .velo.ventana { justify-content: flex-start; align-items: center; padding: 48px 24px; overflow-y: auto; }
  .velo.ventana .hoja { width: 100%; max-width: 720px; border-radius: 16px; max-height: none; }
  .velo .hoja.lateral-hoja { width: 100%; max-width: 560px; align-self: center; border-radius: 16px; margin-bottom: 10vh; }
  .velo { justify-content: center; }
  .flotante { position: static; height: 44px; border-radius: 10px; padding: 0 18px; }
  .flotante svg { display: none; }
  .tabla { overflow-x: auto; }
  .opciones.cuatro { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .t-fila { display: grid; gap: 12px; padding: 14px 0; border-top: 1px solid var(--line); font-size: 16px; font-variant-numeric: tabular-nums; align-items: center; }
  .t-cabeza { display: grid; gap: 12px; padding: 8px 0; font-size: 14px; font-weight: 600; color: var(--sec); }
  .der { text-align: right; }
  .dos-paneles { display: flex; align-items: stretch; min-height: 100vh; }
  .dos-paneles > .lista-panel { width: 380px; flex-shrink: 0; border-right: 1px solid var(--line); }
  .dos-paneles > .ficha-panel { flex-grow: 1; min-width: 0; }
  .roles-pc { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 24px; }
  .roles-pc .opcion { border-top: 0; min-height: 40px; font-size: 16px; }
}
@media (max-width: 1023px) {
  .solo-pc { display: none !important; }
}
