/* ============================================================================
   ATLAS v1.4 · PANEL WEB — panel.css
   Dark club: negro profundo, acento rojo Brava, dorado VIP.
   Pensado para pantalla táctil (targets ≥ 44px) y para leerse de lejos en la
   oscuridad de la puerta: números tabulares, semáforos grandes, contraste alto.
   ============================================================================ */

:root {
  --bg: #0a0a0f;
  --panel: #12121a;
  --panel-2: #1a1a26;
  --panel-3: #232333;
  --linea: #26263a;
  --txt: #eeeaf4;
  --muted: #8f8ca3;
  --rojo: #ff4d5e;          /* acento Brava */
  --rojo-osc: #b52836;
  --dorado: #d9a441;        /* VIP / walk-in */
  --verde: #2ee08c;
  --amarillo: #f5c542;
  --rojo-sem: #ff5d6c;
  --sombra: 0 10px 30px rgba(0, 0, 0, .45);
  --radio: 14px;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, monospace;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
/* El hidden del HTML SIEMPRE gana: sin esto, los display:flex/grid de abajo
   dejarían vistas y modales visibles aunque estén ocultos (bug clásico). */
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  background:
    radial-gradient(1200px 500px at 85% -10%, rgba(255, 77, 94, .07), transparent 60%),
    radial-gradient(900px 420px at -10% 110%, rgba(217, 164, 65, .05), transparent 55%),
    var(--bg);
  color: var(--txt);
  font-family: -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  min-height: 100vh;
  min-height: 100dvh;
}
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
input, select { font: inherit; color: inherit; }
.view { animation: aparecer .25s ease; }
@keyframes aparecer { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ══ LOGIN ═════════════════════════════════════════════════════════════════ */
.view-login {
  min-height: 100vh; min-height: 100dvh;
  display: grid; place-items: center; padding: 24px;
}
.login-box {
  width: min(360px, 94vw);
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  border: 1px solid var(--linea);
  border-radius: 22px;
  padding: 34px 26px 26px;
  box-shadow: var(--sombra);
  text-align: center;
}
.login-logo {
  font-size: 40px; font-weight: 800; letter-spacing: 6px; line-height: 1;
  background: linear-gradient(90deg, #fff 20%, var(--rojo) 90%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.login-logo span {
  display: block; font-size: 11px; font-weight: 600; letter-spacing: 4px;
  color: var(--muted); margin-top: 10px; -webkit-text-fill-color: var(--muted);
}
.pin-dots { display: flex; gap: 14px; justify-content: center; margin: 26px 0 22px; }
.pin-dots i {
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--panel-3); border: 1px solid var(--linea);
  transition: all .15s ease;
}
.pin-dots i.on { background: var(--rojo); border-color: var(--rojo); box-shadow: 0 0 12px rgba(255, 77, 94, .6); }
.numpad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.numpad button {
  height: 60px; border-radius: 14px;
  background: var(--panel-3); border: 1px solid var(--linea);
  font-size: 22px; font-weight: 600; font-variant-numeric: tabular-nums;
  transition: transform .08s ease, background .15s ease;
  touch-action: manipulation; user-select: none;
}
.numpad button:active { transform: scale(.94); background: #2c2c40; }
.numpad .np-del { font-size: 20px; color: var(--muted); }
.numpad .np-ok { font-size: 14px; font-weight: 800; letter-spacing: 1px; background: var(--rojo-osc); border-color: var(--rojo); color: #fff; }
.numpad .np-ok:active { background: var(--rojo); }
.login-err { color: var(--rojo-sem); font-size: 13px; min-height: 18px; margin-top: 16px; }
.login-demo { color: var(--dorado); font-size: 12px; letter-spacing: 1px; }
.login-box.error { animation: temblar .4s; border-color: var(--rojo); }
@keyframes temblar { 20%, 60% { transform: translateX(-7px); } 40%, 80% { transform: translateX(7px); } }

/* ══ SHELL ═════════════════════════════════════════════════════════════════ */
#shell { display: flex; flex-direction: column; min-height: 100vh; min-height: 100dvh; }
.topbar {
  position: sticky; top: 0; z-index: 40;
  display: flex; align-items: center; gap: 18px;
  padding: 10px 18px;
  background: rgba(10, 10, 15, .88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--linea);
}
.brand { font-weight: 800; letter-spacing: 3px; font-size: 19px; white-space: nowrap; }
.brand-sub { font-size: 10px; letter-spacing: 2px; color: var(--muted); display: block; margin-top: -2px; font-weight: 600; }
.badge-demo {
  display: inline-block; margin-left: 8px; padding: 2px 8px; border-radius: 999px;
  background: var(--dorado); color: #1a1206; font-size: 10px; font-weight: 800; letter-spacing: 1px;
  vertical-align: middle;
}
.tabs { display: flex; gap: 4px; flex: 1; overflow-x: auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button {
  padding: 9px 15px; border-radius: 999px; white-space: nowrap;
  color: var(--muted); font-size: 14px; font-weight: 600;
  border: 1px solid transparent;
}
.tabs button:hover { color: var(--txt); background: var(--panel-2); }
.tabs button.tab-activo { color: #fff; background: var(--rojo-osc); border-color: var(--rojo); }
.topbar-right { display: flex; align-items: center; gap: 12px; }
.clock { font-variant-numeric: tabular-nums; color: var(--muted); font-size: 14px; }
.btn-salir {
  padding: 8px 14px; border-radius: 10px; border: 1px solid var(--linea);
  color: var(--muted); font-size: 13px; font-weight: 600;
}
.btn-salir:hover { color: var(--rojo-sem); border-color: var(--rojo-sem); }
main { flex: 1; padding: 22px clamp(14px, 3vw, 34px); max-width: 1280px; width: 100%; margin: 0 auto; }
.foot {
  display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap;
  padding: 12px 20px; border-top: 1px solid var(--linea);
  color: var(--muted); font-size: 12px;
}

/* ══ LA NOCHE ══════════════════════════════════════════════════════════════ */
.noche-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; flex-wrap: wrap; margin-bottom: 18px; }
.noche-titulo h2 { font-size: clamp(22px, 3.4vw, 32px); letter-spacing: .5px; }
.noche-titulo p { color: var(--muted); margin-top: 3px; font-size: 14px; }
.live-pill {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 14px; border-radius: 999px;
  background: var(--panel-2); border: 1px solid var(--linea);
  font-size: 12px; font-weight: 700; letter-spacing: 1px; color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.live-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--verde); box-shadow: 0 0 10px var(--verde); animation: latir 2s infinite; }
@keyframes latir { 50% { opacity: .35; } }

.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin-bottom: 22px; }
.kpi {
  background: var(--panel); border: 1px solid var(--linea); border-radius: var(--radio);
  padding: 14px 16px; position: relative; overflow: hidden;
}
.kpi::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 3px; background: var(--kpi, var(--rojo)); }
.kpi .kpi-num { font-size: 34px; font-weight: 800; font-variant-numeric: tabular-nums; line-height: 1.1; }
.kpi .kpi-num small { font-size: 16px; color: var(--muted); font-weight: 600; }
.kpi .kpi-tag { color: var(--muted); font-size: 12px; font-weight: 600; letter-spacing: .5px; margin-top: 2px; }
.kpi.k-verde { --kpi: var(--verde); } .kpi.k-amarillo { --kpi: var(--amarillo); }
.kpi.k-rojo { --kpi: var(--rojo-sem); } .kpi.k-gris { --kpi: var(--muted); } .kpi.k-dorado { --kpi: var(--dorado); }

.noche-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(280px, 1fr); gap: 22px; align-items: start; }
.col-title { font-size: 13px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.col-title .hint { text-transform: none; letter-spacing: 0; font-weight: 400; opacity: .8; }

.feed { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.feed li {
  display: flex; align-items: center; gap: 12px;
  background: var(--panel); border: 1px solid var(--linea); border-radius: 12px;
  padding: 10px 12px;
}
.feed li.anulado { opacity: .55; }
.feed li.anulado .feed-rut, .feed li.anulado .feed-nombre { text-decoration: line-through; }
.feed-hora {
  font-variant-numeric: tabular-nums; font-size: 13px; color: var(--muted);
  min-width: 44px; text-align: center; background: var(--panel-3); border-radius: 8px; padding: 6px 4px;
}
.feed-luz { font-size: 18px; line-height: 1; }
.feed-main { flex: 1; min-width: 0; }
.feed-rut { font-family: var(--mono); font-size: 15px; font-weight: 700; }
.feed-nombre { color: var(--muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.feed-medio {
  font-size: 10px; font-weight: 800; letter-spacing: 1px; padding: 3px 7px; border-radius: 6px;
  color: var(--muted); border: 1px solid var(--linea); white-space: nowrap;
}
.feed-medio.m-panel { color: var(--dorado); border-color: rgba(217, 164, 65, .45); }
.feed-resultado { font-size: 11px; font-weight: 700; white-space: nowrap; }
.feed-resultado.r-en_lista { color: var(--verde); }
.feed-resultado.r-ya_ingreso { color: var(--amarillo); }
.feed-resultado.r-no_en_lista, .feed-resultado.r-rut_invalido { color: var(--rojo-sem); }
.btn-deshacer {
  padding: 8px 12px; border-radius: 9px; font-size: 12px; font-weight: 700;
  color: var(--rojo-sem); border: 1px solid rgba(255, 93, 108, .4); white-space: nowrap;
  transition: all .15s ease;
}
.btn-deshacer:hover { background: rgba(255, 93, 108, .12); }
.feed-deshecho { font-size: 11px; color: var(--muted); white-space: nowrap; }
.feed-vacio { color: var(--muted); text-align: center; padding: 30px 10px; font-size: 14px; }

.mini-listas { display: flex; flex-direction: column; gap: 10px; margin-bottom: 22px; }
.mini-lista {
  background: var(--panel); border: 1px solid var(--linea); border-radius: 12px; padding: 12px 14px;
}
.mini-lista-top { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.mini-lista-nombre { font-weight: 700; font-size: 14px; }
.mini-lista-cifra { font-variant-numeric: tabular-nums; font-size: 13px; color: var(--muted); }
.mini-lista-cifra b { color: var(--verde); font-size: 15px; }
.barra { height: 7px; border-radius: 99px; background: var(--panel-3); margin-top: 9px; overflow: hidden; }
.barra i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--verde), #7df0bb); transition: width .5s ease; }
.mini-lista .tipo-chip { font-size: 10px; color: var(--dorado); border: 1px solid rgba(217, 164, 65, .4); padding: 1px 6px; border-radius: 6px; margin-left: 6px; vertical-align: middle; }

.mini-reservas { display: flex; flex-direction: column; gap: 6px; }
.mini-reserva {
  display: flex; justify-content: space-between; gap: 10px; align-items: center;
  background: var(--panel); border: 1px solid var(--linea); border-radius: 10px; padding: 9px 12px; font-size: 13px;
}
.mini-reserva b { font-variant-numeric: tabular-nums; }
.mini-reserva .hora-r { color: var(--dorado); font-variant-numeric: tabular-nums; }
.mini-reserva.cancelada { opacity: .5; text-decoration: line-through; }

/* ══ PUERTA ════════════════════════════════════════════════════════════════ */
.puerta-head { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 16px; }
.sel-wrap { display: flex; flex-direction: column; gap: 5px; font-size: 11px; letter-spacing: 1px; text-transform: uppercase; color: var(--muted); font-weight: 700; }
.sel-wrap select {
  background: var(--panel); border: 1px solid var(--linea); color: var(--txt);
  border-radius: 10px; padding: 10px 12px; min-width: 210px; font-size: 14px;
}
.rut-box { display: flex; gap: 10px; }
.rut-input {
  flex: 1; background: var(--panel); border: 2px solid var(--linea); border-radius: 14px;
  padding: 16px 18px; font-size: clamp(22px, 4vw, 30px); font-weight: 700;
  font-family: var(--mono); letter-spacing: 2px; color: var(--txt);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.rut-input:focus { outline: none; border-color: var(--rojo); box-shadow: 0 0 0 4px rgba(255, 77, 94, .15); }
.rut-input::placeholder { color: #4a4660; font-weight: 500; }
.btn { border-radius: 14px; padding: 14px 22px; font-weight: 800; letter-spacing: .5px; font-size: 15px; transition: all .15s ease; }
.btn:active { transform: scale(.97); }
.btn-consultar { background: var(--rojo-osc); border: 1px solid var(--rojo); color: #fff; min-width: 130px; }
.btn-consultar:hover { background: var(--rojo); }
.rut-hint { min-height: 22px; margin-top: 8px; font-size: 13px; color: var(--muted); }
.rut-hint.mal { color: var(--rojo-sem); font-weight: 600; }

.ficha { margin-top: 18px; display: flex; flex-direction: column; gap: 14px; }
.ficha-caja {
  background: var(--panel); border: 1px solid var(--linea); border-left: 5px solid var(--luz, var(--muted));
  border-radius: var(--radio); padding: 20px 22px; box-shadow: var(--sombra);
}
.ficha-caja.f-verde { --luz: var(--verde); } .ficha-caja.f-amarillo { --luz: var(--amarillo); }
.ficha-caja.f-rojo { --luz: var(--rojo-sem); } .ficha-caja.f-gris { --luz: var(--muted); }
.ficha-titulo { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.ficha-emoji { font-size: 34px; line-height: 1; }
.ficha-titulo h3 { font-size: clamp(18px, 2.6vw, 24px); letter-spacing: .5px; }
.ficha-rut { font-family: var(--mono); font-size: 17px; color: var(--muted); margin-top: 4px; font-variant-numeric: tabular-nums; }
.ficha-lineas { margin-top: 14px; display: flex; flex-direction: column; gap: 7px; font-size: 14px; color: #cfcbe0; }
.ficha-lineas b { color: var(--txt); }
.ficha-lineas .det { color: var(--muted); font-size: 13px; }
.chip-cliente {
  display: inline-flex; gap: 8px; align-items: center; margin-top: 14px;
  background: rgba(217, 164, 65, .1); border: 1px solid rgba(217, 164, 65, .35);
  color: var(--dorado); border-radius: 999px; padding: 6px 12px; font-size: 12.5px; font-weight: 600;
}
.ficha-acciones { display: flex; gap: 10px; flex-wrap: wrap; }
.btn-validar { background: linear-gradient(180deg, #24c97b, #17a562); color: #04170d; border: 1px solid #2ee08c; font-size: 17px; padding: 16px 26px; }
.btn-validar:hover { filter: brightness(1.1); }
.btn-reingreso { background: linear-gradient(180deg, #e0b53a, #bd8f1f); color: #221a04; border: 1px solid var(--amarillo); font-size: 17px; padding: 16px 26px; }
.btn-reingreso:hover { filter: brightness(1.08); }
.btn-fuera { background: transparent; border: 1px solid rgba(255, 93, 108, .5); color: var(--rojo-sem); padding: 14px 20px; }
.btn-fuera:hover { background: rgba(255, 93, 108, .1); }
.btn-walkin { background: linear-gradient(180deg, #e5b455, #c8963a); color: #211604; border: 1px solid var(--dorado); padding: 14px 20px; }
.btn-walkin:hover { filter: brightness(1.08); }
.ficha-nota { color: var(--muted); font-size: 13px; }

/* ══ EVENTOS ═══════════════════════════════════════════════════════════════ */
.vista-titulo { font-size: 20px; margin-bottom: 16px; }
.vista-titulo .hint { font-size: 13px; color: var(--muted); font-weight: 400; }
.cards-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; }
.card-evento {
  background: var(--panel); border: 1px solid var(--linea); border-radius: var(--radio); padding: 18px;
  display: flex; flex-direction: column; gap: 10px; cursor: pointer; transition: border-color .15s ease, transform .15s ease;
}
.card-evento:hover { border-color: var(--rojo); transform: translateY(-2px); }
.card-evento h4 { font-size: 17px; }
.card-evento .ev-fecha { color: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; }
.card-evento .ev-cifras { display: flex; gap: 14px; font-size: 13px; color: var(--muted); }
.card-evento .ev-cifras b { color: var(--txt); font-size: 16px; }
.ev-estado { align-self: flex-start; font-size: 10px; font-weight: 800; letter-spacing: 1px; padding: 3px 8px; border-radius: 6px; }
.ev-estado.e-publicado { color: var(--verde); border: 1px solid rgba(46, 224, 140, .4); }
.ev-estado.e-borrador { color: var(--muted); border: 1px solid var(--linea); }
.ev-estado.e-activo { background: var(--verde); color: #04170d; }

/* ══ LISTAS ════════════════════════════════════════════════════════════════ */
.listas-head { display: flex; gap: 14px; align-items: end; flex-wrap: wrap; margin-bottom: 18px; }
.listas-head .vista-titulo { margin-bottom: 0; margin-right: auto; }
.buscar {
  background: var(--panel); border: 1px solid var(--linea); border-radius: 10px;
  padding: 10px 14px; min-width: 230px; font-size: 14px;
}
.buscar:focus { outline: none; border-color: var(--rojo); }
.seccion-lista { margin-bottom: 22px; }
.seccion-lista > header {
  display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap;
  padding: 10px 4px; border-bottom: 1px solid var(--linea); margin-bottom: 8px;
}
.seccion-lista h3 { font-size: 17px; }
.seccion-lista .cifras { color: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; }
.tabla-ruts { width: 100%; border-collapse: collapse; }
.tabla-ruts td { padding: 8px 8px; border-bottom: 1px solid rgba(38, 38, 58, .55); font-size: 14px; }
.tabla-ruts tr.retirado td { opacity: .45; }
.tabla-ruts tr.retirado .t-rut, .tabla-ruts tr.retirado .t-nombre { text-decoration: line-through; }
.t-rut { font-family: var(--mono); font-weight: 700; white-space: nowrap; }
.t-nombre { color: #cfcbe0; }
.t-pax, .t-agregado { color: var(--muted); font-size: 12.5px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.luz-chip { font-size: 11.5px; font-weight: 700; white-space: nowrap; padding: 4px 10px; border-radius: 999px; }
.luz-chip.l-verde { color: var(--verde); background: rgba(46, 224, 140, .1); border: 1px solid rgba(46, 224, 140, .35); }
.luz-chip.l-amarillo { color: var(--amarillo); background: rgba(245, 197, 66, .1); border: 1px solid rgba(245, 197, 66, .35); }
.luz-chip.l-gris { color: var(--muted); background: var(--panel-2); border: 1px solid var(--linea); }

/* ══ RESERVAS ══════════════════════════════════════════════════════════════ */
.tabla-wrap { background: var(--panel); border: 1px solid var(--linea); border-radius: var(--radio); overflow-x: auto; }
.tabla { width: 100%; border-collapse: collapse; min-width: 640px; }
.tabla th {
  text-align: left; font-size: 11px; letter-spacing: 1.5px; text-transform: uppercase;
  color: var(--muted); padding: 12px 14px; border-bottom: 1px solid var(--linea);
}
.tabla td { padding: 11px 14px; border-bottom: 1px solid rgba(38, 38, 58, .55); font-size: 14px; }
.tabla tr:last-child td { border-bottom: 0; }
.tabla .hora-c { font-weight: 800; color: var(--dorado); font-variant-numeric: tabular-nums; }
.res-estado { font-size: 11px; font-weight: 700; padding: 3px 9px; border-radius: 999px; }
.res-estado.e-confirmada { color: var(--verde); background: rgba(46, 224, 140, .1); }
.res-estado.e-pendiente { color: var(--amarillo); background: rgba(245, 197, 66, .1); }
.res-estado.e-cancelada { color: var(--rojo-sem); background: rgba(255, 93, 108, .1); }
.tabla-vacia { color: var(--muted); text-align: center; padding: 26px; font-size: 14px; }

/* ══ MODAL + TOASTS ════════════════════════════════════════════════════════ */
.modal-fondo {
  position: fixed; inset: 0; z-index: 90;
  background: rgba(5, 5, 9, .75); backdrop-filter: blur(4px);
  display: grid; place-items: center; padding: 18px;
}
.modal {
  width: min(430px, 96vw); background: var(--panel-2);
  border: 1px solid var(--linea); border-radius: 18px;
  padding: 24px; box-shadow: var(--sombra);
  animation: aparecer .2s ease;
}
.modal h3 { font-size: 18px; margin-bottom: 10px; }
.modal p { color: #cfcbe0; font-size: 14px; line-height: 1.55; }
.modal .modal-rut { font-family: var(--mono); color: var(--txt); font-weight: 700; }
.campo { display: flex; flex-direction: column; gap: 6px; margin-top: 14px; }
.campo label { font-size: 11px; letter-spacing: 1px; text-transform: uppercase; color: var(--muted); font-weight: 700; }
.campo input, .campo select {
  background: var(--panel); border: 1px solid var(--linea); border-radius: 10px;
  padding: 11px 13px; font-size: 15px;
}
.campo input:focus, .campo select:focus { outline: none; border-color: var(--rojo); }
.campo-row { display: flex; gap: 10px; }
.campo-row .campo { flex: 1; }
.modal-acciones { display: flex; gap: 10px; justify-content: flex-end; margin-top: 22px; flex-wrap: wrap; }
.btn-modal-sec { padding: 12px 18px; border-radius: 12px; border: 1px solid var(--linea); color: var(--muted); font-weight: 700; }
.btn-modal-sec:hover { color: var(--txt); }
.btn-modal-ok { padding: 12px 20px; border-radius: 12px; font-weight: 800; }
.btn-modal-ok.o-rojo { background: var(--rojo-osc); border: 1px solid var(--rojo); color: #fff; }
.btn-modal-ok.o-dorado { background: linear-gradient(180deg, #e5b455, #c8963a); color: #211604; border: 1px solid var(--dorado); }

#toast-zone { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); z-index: 99; display: flex; flex-direction: column; gap: 8px; width: min(480px, 92vw); }
.toast {
  background: var(--panel-3); border: 1px solid var(--linea); border-left: 4px solid var(--t, var(--verde));
  border-radius: 12px; padding: 13px 16px; font-size: 14px; box-shadow: var(--sombra);
  animation: toast-in .25s ease;
}
.toast b { display: block; margin-bottom: 2px; }
.toast.t-verde { --t: var(--verde); } .toast.t-rojo { --t: var(--rojo-sem); }
.toast.t-amarillo { --t: var(--amarillo); } .toast.t-dorado { --t: var(--dorado); }
@keyframes toast-in { from { opacity: 0; transform: translateY(12px); } }

/* ══ CLIENTES (la base de los 14 mil · solo lectura) ═══════════════════════ */
.sel-mini {
  background: var(--panel-2); color: var(--txt); border: 1px solid var(--linea);
  border-radius: 10px; padding: 10px 12px; font-size: 14px; font-weight: 700;
  cursor: pointer;
}
#tabla-clientes tbody tr[data-rut] { cursor: pointer; }
#tabla-clientes tbody tr[data-rut]:hover td { background: rgba(217, 164, 65, .05); }
#tabla-clientes tbody tr[data-rut]:hover .t-rut { color: var(--dorado); }
.t-tel { font-variant-numeric: tabular-nums; white-space: nowrap; color: #cfcbe0; }
.luz-chip.l-dorado { color: var(--dorado); background: rgba(217, 164, 65, .1); border: 1px solid rgba(217, 164, 65, .35); }
.cli-paginacion { display: flex; align-items: center; justify-content: center; gap: 16px; margin-top: 14px; flex-wrap: wrap; }
.btn-pag {
  background: var(--panel-2); color: var(--txt); border: 1px solid var(--linea);
  padding: 9px 16px; border-radius: 10px; font-size: 13px; font-weight: 700; cursor: pointer;
}
.btn-pag:hover:not(:disabled) { border-color: var(--rojo); }
.btn-pag:disabled { opacity: .35; cursor: default; }
.cli-info { color: var(--muted); font-size: 12.5px; font-variant-numeric: tabular-nums; }
.cli-pie { color: var(--muted); font-size: 12.5px; text-align: center; margin-top: 10px; }

/* ══ RESPONSIVE ════════════════════════════════════════════════════════════ */
@media (max-width: 920px) {
  .noche-grid { grid-template-columns: 1fr; }
  .topbar { flex-wrap: wrap; gap: 8px; }
  .topbar-right { margin-left: auto; }
  .clock { display: none; }
}
@media (max-width: 560px) {
  .rut-box { flex-direction: column; }
  .btn-consultar { width: 100%; padding: 16px; }
  .feed li { flex-wrap: wrap; }
  .feed-medio { display: none; }
  .kpis { grid-template-columns: repeat(2, 1fr); }
}
