/* Plan de trabajo · La Unión
   Azul de marca #096db7 + celeste. Formas redondeadas, degradados suaves, tipografía Poppins. */
:root {
  --azul: #096db7;
  --azul-osc: #064f8a;
  --celeste: #2fb0e6;
  --celeste-txt: #0a77ab;
  --azul-claro: #e9f2fc;
  --celeste-claro: #e3f5fd;
  --grad: linear-gradient(135deg, #064f8a 0%, #096db7 48%, #2fb0e6 100%);
  --bg: #f2f6fb;
  --surface: #ffffff;
  --surface-2: #f6f9fd;
  --ink: #0f2135;
  --muted: #6c7f97;
  --line: #e4ebf3;
  --ok: #0f9466;
  --ok-bg: #e2f6ee;
  --warn-ink: #8a5a00;
  --warn-bg: #fff4dc;
  --alert-ink: #b02222;
  --alert-bg: #fdeceb;
  --sombra: 0 12px 32px -14px rgba(6, 60, 120, .22), 0 2px 6px rgba(6, 60, 120, .05);
  --sombra-azul: 0 10px 24px -8px rgba(9, 109, 183, .55);
  --r-xl: 28px;
  --r-lg: 22px;
  --r-md: 16px;
  --r-sm: 12px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --azul-claro: #13263a;
    --celeste-claro: #10293a;
    --celeste-txt: #7fd0f2;
    --bg: #0b1622;
    --surface: #132131;
    --surface-2: #182a3d;
    --ink: #e7eef6;
    --muted: #8fa3ba;
    --line: #22364b;
    --ok: #3dd29b;
    --ok-bg: #10291f;
    --warn-ink: #f2c66d;
    --warn-bg: #2b2210;
    --alert-ink: #f5a3a3;
    --alert-bg: #351616;
    --sombra: 0 1px 0 rgba(255, 255, 255, .03);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.5 "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
a { color: var(--azul); }
h1, h2, h3 { margin: 0; letter-spacing: -.01em; }
p { margin: 0; }
[hidden] { display: none !important; }
.suave { color: var(--muted); font-size: .9rem; }
.ico { width: 20px; height: 20px; flex: none; }
:focus-visible { outline: 3px solid var(--celeste); outline-offset: 2px; }

/* ---------- Botones ---------- */
.boton, button.boton { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; border: 0; border-radius: 999px; background: var(--grad); color: #fff; font: 600 .95rem/1 inherit; font-family: inherit; padding: .85rem 1.35rem; cursor: pointer; text-decoration: none; box-shadow: var(--sombra-azul); transition: transform .15s ease, box-shadow .15s ease; white-space: nowrap; }
.boton:hover { transform: translateY(-1px); box-shadow: 0 14px 28px -8px rgba(9, 109, 183, .6); }
.boton:active { transform: translateY(0); }
.boton-grande { padding: 1.05rem 1.6rem; font-size: 1rem; }
.boton-chico { padding: .55rem .9rem; font-size: .82rem; }
.boton-chico .ico { width: 16px; height: 16px; }
.boton-suave, button.boton-suave { background: var(--azul-claro); color: var(--azul); box-shadow: none; }
.boton-suave:hover { box-shadow: none; background: var(--celeste-claro); }
.ancho { width: 100%; }
.boton-icono { display: grid; place-items: center; width: 40px; height: 40px; border-radius: var(--r-sm); border: 0; background: transparent; color: var(--muted); cursor: pointer; }
.boton-icono:hover { background: var(--alert-bg); color: var(--alert-ink); }

/* ---------- Formularios ---------- */
.form-linea label { display: block; margin-bottom: 1.4rem; }
.form-linea label span { display: block; font-size: .78rem; font-weight: 500; color: var(--muted); }
.form-linea input { display: block; width: 100%; border: 0; border-bottom: 1.5px solid var(--line); background: transparent; color: var(--ink); font: 500 1.1rem/1.4 inherit; font-family: inherit; padding: .55rem 0; border-radius: 0; }
.form-linea input:focus { outline: none; border-bottom-color: var(--azul); }
.form-linea input::placeholder { color: var(--muted); opacity: .6; font-weight: 400; }
.form-linea .boton { margin-top: .6rem; }

/* ---------- Mensajes (toast) ---------- */
.flash { position: fixed; z-index: 50; top: 16px; left: 50%; transform: translateX(-50%); width: min(560px, calc(100% - 32px)); display: flex; gap: .75rem; align-items: flex-start; padding: .9rem 1.1rem; border-radius: var(--r-md); background: var(--surface); color: var(--ink); box-shadow: 0 18px 40px -12px rgba(6, 40, 80, .35); animation: entra .35s ease; }
.flash .ico { margin-top: 2px; }
.flash-ok .ico { color: var(--ok); }
.flash-error .ico { color: var(--alert-ink); }
.pin { display: inline-block; font: 700 1.3rem/1 ui-monospace, monospace; letter-spacing: .25em; background: var(--azul-claro); color: var(--azul); padding: .35rem .6rem; border-radius: 10px; margin: .25rem .2rem; }
@keyframes entra { from { opacity: 0; transform: translate(-50%, -8px); } }

/* ---------- Avatar ---------- */
.avatar { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; background: var(--grad); color: #fff; font-weight: 600; font-size: .95rem; flex: none; box-shadow: var(--sombra-azul); }
.avatar.chico { width: 38px; height: 38px; font-size: .82rem; box-shadow: none; }
.avatar.mini { width: 34px; height: 34px; font-size: .75rem; box-shadow: none; background: var(--azul-claro); color: var(--azul); }

/* =========================================================
   APP DEL CHOFER (celular)
   ========================================================= */
body.cuerpo-movil { background: var(--bg); }
.app { position: relative; max-width: 480px; margin: 0 auto; min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; background: var(--bg); }
.app-cab { display: flex; justify-content: space-between; align-items: center; padding: 1.6rem 1.25rem 1rem; }
.saludo { font-size: 1.6rem; line-height: 1.2; }
.saludo strong { font-weight: 700; }
.sub { color: var(--muted); font-size: .9rem; margin-top: .15rem; }
.app-main { flex: 1; padding: 0 1.25rem 1.5rem; }
.vista { animation: aparece .25s ease; }
@keyframes aparece { from { opacity: 0; transform: translateY(6px); } }

/* Tarjeta principal "Hoy" */
.hero { position: relative; overflow: hidden; background: var(--grad); color: #fff; border-radius: var(--r-xl); padding: 1.4rem 1.35rem 1.35rem; box-shadow: var(--sombra-azul); isolation: isolate; }
.hero::before, .hero::after { content: ""; position: absolute; z-index: -1; border-radius: 50%; border: 22px solid rgba(255, 255, 255, .07); }
.hero::before { width: 220px; height: 220px; right: -70px; top: -80px; }
.hero::after { width: 150px; height: 150px; right: 40px; bottom: -95px; border-width: 16px; }
.hero-fecha { font-size: .82rem; font-weight: 500; opacity: .9; }
.hero-ico { display: grid; place-items: center; width: 48px; height: 48px; border-radius: var(--r-md); background: rgba(255, 255, 255, .18); margin: 1rem 0 .8rem; }
.hero-ico .ico { width: 26px; height: 26px; }
.hero h2 { font-size: 1.45rem; font-weight: 600; line-height: 1.25; }
.hero-det { margin-top: .35rem; opacity: .92; font-size: .92rem; }
.hero-chips { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1rem; }
.hero-chips span { background: rgba(255, 255, 255, .18); border-radius: 999px; padding: .38rem .8rem; font-size: .82rem; }
.hero-chips b { font-weight: 700; }
.hero-mas { display: inline-flex; align-items: center; gap: .35rem; margin-top: 1rem; color: #fff; font-weight: 600; font-size: .88rem; text-decoration: none; }
.hero-mas .ico { width: 16px; height: 16px; }
.hero-nota { display: flex; gap: .5rem; align-items: flex-start; margin-top: .9rem; padding: .6rem .75rem; border-radius: var(--r-sm); background: rgba(255, 255, 255, .16); font-size: .82rem; font-weight: 500; }
.hero-nota .ico { width: 17px; height: 17px; }

.resumen { display: grid; grid-template-columns: repeat(3, 1fr); gap: .65rem; margin: 1rem 0 .4rem; }
.resumen div { background: var(--surface); border-radius: var(--r-md); padding: .8rem .7rem; box-shadow: var(--sombra); text-align: center; }
.resumen strong { display: block; font-size: 1.2rem; font-weight: 700; color: var(--azul); }
.resumen span { display: block; font-size: .72rem; color: var(--muted); line-height: 1.25; }

.titulo-seccion { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; margin: 1.5rem 0 .8rem; }
.titulo-seccion h2 { font-size: 1.12rem; font-weight: 600; }
.titulo-seccion span { color: var(--muted); font-size: .82rem; }

/* Tarjeta de servicio (estilo "tarea") */
.servicio { position: relative; display: flex; gap: .9rem; align-items: flex-start; background: var(--surface); border-radius: var(--r-lg); padding: 1rem 1rem 1rem 1.05rem; margin-bottom: .75rem; box-shadow: var(--sombra); }
.servicio::before { content: ""; position: absolute; left: -1px; top: 22px; bottom: 22px; width: 3px; border-radius: 3px; background: var(--azul); }
.servicio-esp::before { background: var(--celeste); }
.servicio-ico { display: grid; place-items: center; width: 46px; height: 46px; border-radius: var(--r-md); background: var(--azul-claro); color: var(--azul); flex: none; }
.servicio-esp .servicio-ico { background: var(--celeste-claro); color: var(--celeste-txt); }
.servicio-ico .ico { width: 24px; height: 24px; }
.servicio-txt { min-width: 0; flex: 1; }
.servicio h3 { font-size: .98rem; font-weight: 600; line-height: 1.35; }
.etiqueta { display: inline-block; font-size: .68rem; font-weight: 600; text-transform: uppercase; letter-spacing: .06em; color: var(--celeste-txt); margin-bottom: .15rem; }
.detalle { font-size: .84rem; color: var(--azul); font-weight: 500; margin-top: .2rem; }
.chips { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .6rem; }
.chip { display: inline-flex; align-items: center; gap: .35rem; background: var(--surface-2); color: var(--muted); border-radius: 999px; padding: .3rem .65rem; font-size: .76rem; font-weight: 500; }
.chip .ico { width: 15px; height: 15px; }

.estado { display: flex; gap: .9rem; align-items: center; background: var(--surface); border-radius: var(--r-lg); padding: 1rem 1.05rem; margin-bottom: .75rem; box-shadow: var(--sombra); color: var(--muted); }
.estado > .ico { width: 46px; height: 46px; padding: 11px; border-radius: var(--r-md); background: var(--surface-2); }
.estado strong { display: block; color: var(--ink); font-weight: 600; }
.estado span { font-size: .84rem; }
.estado-franco > .ico { background: var(--ok-bg); color: var(--ok); }
.estado-franco strong { color: var(--ok); }
.nota-dia { display: flex; gap: .6rem; align-items: flex-start; padding: .7rem .85rem; border-radius: var(--r-md); background: var(--warn-bg); color: var(--warn-ink); font-size: .82rem; font-weight: 500; margin-bottom: .75rem; }
.nota-dia .ico { width: 18px; height: 18px; margin-top: 1px; }
.app .boton-suave.ancho { margin-top: .6rem; }

/* Semana: tira de días */
.semana-cab { display: flex; justify-content: space-between; align-items: center; margin: .2rem 0 1rem; }
.semana-cab h2 { font-size: 1.45rem; font-weight: 600; }
.leyenda { display: flex; gap: .8rem; font-size: .72rem; color: var(--muted); }
.leyenda span::before { content: ""; display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: .3rem; vertical-align: 1px; }
.l-trabajo::before { background: var(--azul); }
.l-franco::before { background: var(--ok); }
.tira { display: flex; gap: .6rem; overflow-x: auto; scroll-snap-type: x proximity; padding: .3rem .1rem 1rem; margin: 0 -1.25rem; padding-left: 1.25rem; padding-right: 1.25rem; scrollbar-width: none; }
.tira::-webkit-scrollbar { display: none; }
.dia-pill { flex: none; scroll-snap-align: center; display: flex; flex-direction: column; align-items: center; gap: .1rem; width: 58px; padding: .75rem 0 .6rem; border: 0; border-radius: 18px; background: var(--surface); color: var(--ink); font-family: inherit; cursor: pointer; box-shadow: var(--sombra); transition: transform .15s ease; }
.dia-pill:hover { transform: translateY(-2px); }
.dia-pill .n { font-size: 1.2rem; font-weight: 600; line-height: 1.1; }
.dia-pill .d { font-size: .72rem; color: var(--muted); }
.dia-pill i { width: 6px; height: 6px; border-radius: 50%; margin-top: .3rem; background: var(--line); }
.dia-pill.est-trabajo i { background: var(--azul); }
.dia-pill.est-franco i { background: var(--ok); }
.dia-pill.activo { background: var(--grad); color: #fff; box-shadow: var(--sombra-azul); }
.dia-pill.activo .d { color: rgba(255, 255, 255, .85); }
.dia-pill.activo i { background: #fff; }
.panel-dia .titulo-seccion { margin-top: .4rem; }

/* Avisos */
.aviso { display: flex; gap: .9rem; align-items: flex-start; background: var(--surface); border-radius: var(--r-lg); padding: 1rem 1.05rem; margin-bottom: .75rem; box-shadow: var(--sombra); font-size: .88rem; }
.aviso-ico { display: grid; place-items: center; width: 42px; height: 42px; border-radius: var(--r-md); background: var(--warn-bg); color: var(--warn-ink); flex: none; }
.aviso-dia .aviso-ico { background: var(--celeste-claro); color: var(--celeste-txt); }
.aviso .etiqueta { color: var(--celeste-txt); }
.vacio-app, .vacio { text-align: center; color: var(--muted); padding: 2.5rem 1rem; }
.vacio-app .ico, .vacio .ico { width: 40px; height: 40px; padding: 9px; border-radius: 50%; background: var(--azul-claro); color: var(--azul); margin-bottom: .6rem; }
.pie { text-align: center; color: var(--muted); font-size: .76rem; margin-top: 1.4rem; }

/* Navegación inferior flotante */
.nav-app { position: sticky; bottom: 0; z-index: 5; display: flex; justify-content: space-around; margin: 0 .9rem calc(.9rem + env(safe-area-inset-bottom)); padding: .45rem; background: var(--surface); border-radius: var(--r-lg); box-shadow: 0 -2px 30px -10px rgba(6, 40, 80, .28); }
.nav-app a { position: relative; flex: 1; display: flex; flex-direction: column; align-items: center; gap: .1rem; padding: .5rem .2rem .4rem; border-radius: var(--r-md); color: var(--muted); text-decoration: none; font-size: .7rem; font-weight: 500; }
.nav-app a .ico { width: 22px; height: 22px; }
.nav-app a[aria-current] { color: var(--azul); background: var(--azul-claro); }
.nav-app .punto { position: absolute; top: 7px; left: calc(50% + 6px); width: 7px; height: 7px; border-radius: 50%; background: var(--celeste); border: 2px solid var(--surface); }

/* Login del chofer */
.login-movil { max-width: 480px; margin: 0 auto; min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; background: var(--surface); }
.login-top { position: relative; overflow: hidden; background: var(--grad); color: #fff; padding: 3.2rem 1.6rem 4.2rem; isolation: isolate; }
.login-top::before, .login-top::after { content: ""; position: absolute; z-index: -1; border-radius: 50%; border: 26px solid rgba(255, 255, 255, .07); }
.login-top::before { width: 260px; height: 260px; right: -90px; top: -70px; }
.login-top::after { width: 170px; height: 170px; left: -60px; bottom: -80px; }
.logo-blanco { height: 20px; width: auto; display: block; }
.login-top h1 { font-size: 1.9rem; font-weight: 700; margin-top: 2.6rem; line-height: 1.15; }
.login-top p { opacity: .9; margin-top: .5rem; max-width: 300px; }
.login-hoja { flex: 1; background: var(--surface); border-radius: 32px 32px 0 0; margin-top: -2rem; padding: 2.2rem 1.6rem 2rem; position: relative; }
.ayuda { display: flex; gap: .55rem; align-items: center; color: var(--muted); font-size: .82rem; margin-top: 1.6rem; }
.ayuda .ico { width: 18px; height: 18px; color: var(--azul); }
body.cuerpo-movil .flash { top: 12px; }

/* =========================================================
   PANEL DE LA OFICINA
   ========================================================= */
.admin { display: grid; grid-template-columns: 250px minmax(0, 1fr); min-height: 100vh; }
.lateral { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; background: var(--surface); padding: 1.6rem 1.1rem 1.2rem; border-right: 1px solid var(--line); }
.lateral-logo { display: block; padding: 0 .5rem; }
.lateral-logo img { width: 100%; max-width: 170px; height: auto; display: block; }
.lateral-titulo { padding: 0 .55rem; margin-top: .45rem; font-size: .78rem; color: var(--muted); font-weight: 500; }
.lateral nav { display: flex; flex-direction: column; gap: .3rem; margin-top: 2rem; }
.lateral nav a { display: flex; align-items: center; gap: .75rem; padding: .75rem .9rem; border-radius: var(--r-md); color: var(--muted); text-decoration: none; font-weight: 500; }
.lateral nav a:hover { background: var(--surface-2); color: var(--ink); }
.lateral nav a[aria-current] { background: var(--grad); color: #fff; box-shadow: var(--sombra-azul); }
.lateral-pie { margin-top: auto; display: flex; gap: .7rem; align-items: center; padding: .8rem; border-radius: var(--r-md); background: var(--surface-2); }
.lateral-pie strong { display: block; font-size: .88rem; }
.lateral-pie a { font-size: .8rem; color: var(--muted); }
.contenido { padding: 2rem 2.5rem 3rem; max-width: 1180px; width: 100%; }
body.ancho .contenido { max-width: none; }
.cont-cab { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.6rem; }
.cont-cab h1 { font-size: 1.7rem; font-weight: 600; }
.cont-cab .suave { margin-top: .2rem; }
.cont-acciones { display: flex; gap: .6rem; flex-wrap: wrap; }

.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 1rem; margin-bottom: 1.25rem; }
.stat { display: flex; gap: .9rem; align-items: center; background: var(--surface); border-radius: var(--r-lg); padding: 1.1rem 1.2rem; box-shadow: var(--sombra); color: var(--ink); text-decoration: none; }
.stat > .ico { width: 46px; height: 46px; padding: 11px; border-radius: var(--r-md); background: var(--azul-claro); color: var(--azul); }
.stat span { display: block; font-size: .78rem; color: var(--muted); }
.stat strong { display: block; font-size: 1.15rem; font-weight: 600; }
.stat-azul { position: relative; overflow: hidden; background: var(--grad); color: #fff; box-shadow: var(--sombra-azul); }
.stat-azul > .ico { background: rgba(255, 255, 255, .18); color: #fff; }
.stat-azul span { color: rgba(255, 255, 255, .85); }
.stat-alerta > .ico { background: var(--alert-bg); color: var(--alert-ink); }

.tarjeta { background: var(--surface); border-radius: var(--r-xl); padding: 1.5rem; box-shadow: var(--sombra); margin-bottom: 1.25rem; }
.tarjeta-cab { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; }
.tarjeta-cab h2 { font-size: 1.08rem; font-weight: 600; margin-right: auto; }

.subir-tarjeta { display: grid; grid-template-columns: 1.15fr 1fr; gap: 2rem; align-items: center; }
.subir-info h2 { font-size: 1.3rem; font-weight: 600; }
.subir-info > p { color: var(--muted); margin-top: .4rem; }
.ultima { display: flex; flex-wrap: wrap; gap: .45rem; align-items: center; margin-top: 1.2rem; font-size: .84rem; color: var(--muted); }
.ultima a { display: inline-flex; align-items: center; gap: .25rem; font-weight: 600; text-decoration: none; }
.ultima a .ico { width: 15px; height: 15px; }
.zona { position: relative; display: flex; flex-direction: column; align-items: center; gap: .3rem; text-align: center; padding: 2rem 1.2rem; border-radius: var(--r-lg); border: 2px dashed color-mix(in srgb, var(--celeste) 55%, transparent); background: var(--celeste-claro); cursor: pointer; margin-bottom: .9rem; transition: background .15s, border-color .15s; }
.zona input { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; }
.zona strong { font-weight: 600; }
.zona span { font-size: .84rem; color: var(--muted); }
.zona-ico { width: 52px !important; height: 52px !important; padding: 13px; border-radius: 50%; background: var(--surface); color: var(--azul); box-shadow: var(--sombra); margin-bottom: .4rem; }
.zona.arrastrando { background: var(--azul-claro); border-color: var(--azul); }
.zona.con-archivo { border-style: solid; border-color: var(--ok); background: var(--ok-bg); }
.zona.con-archivo span { color: var(--ok); font-weight: 600; }

.pasos { display: flex; gap: .5rem; list-style: none; padding: 0; margin: 1.2rem 0 1.25rem; flex-wrap: wrap; }
.pasos li { display: flex; align-items: center; gap: .55rem; font-size: .84rem; color: var(--muted); font-weight: 500; }
.pasos li + li::before { content: ""; width: 22px; height: 2px; border-radius: 2px; background: var(--line); margin-right: .1rem; }
.pasos span { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--surface-2); border: 1.5px solid var(--line); font-size: .78rem; font-weight: 600; }
.pasos span .ico { width: 16px; height: 16px; }
.pasos .actual { color: var(--ink); }
.pasos .actual span { background: var(--grad); color: #fff; border-color: transparent; box-shadow: var(--sombra-azul); }
.pasos .hecho span { background: var(--ok-bg); color: var(--ok); border-color: transparent; }

.fila-semana, .fila-chofer { display: flex; align-items: center; gap: 1rem; padding: .85rem 1rem; border: 1px solid var(--line); border-radius: var(--r-lg); margin-bottom: .65rem; color: var(--ink); text-decoration: none; transition: border-color .15s, background .15s, transform .15s; }
.fila-link:hover { border-color: var(--celeste); background: var(--surface-2); }
.fila-semana.vigente { background: var(--azul-claro); border-color: transparent; }
.fila-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.fila-txt strong { font-weight: 600; font-size: .95rem; }
.fila-txt span { color: var(--muted); font-size: .8rem; }
.fila-txt b { color: var(--ink); font-weight: 600; }
.bloque-fecha { display: flex; flex-direction: column; align-items: center; justify-content: center; width: 64px; height: 66px; border-radius: var(--r-md); background: var(--azul-claro); color: var(--azul); flex: none; line-height: 1.1; }
.bloque-fecha .mes { font-size: .66rem; font-weight: 600; letter-spacing: .06em; }
.bloque-fecha strong { font-size: 1.35rem; font-weight: 700; }
.bloque-fecha .hasta { font-size: .64rem; opacity: .8; }
.vigente .bloque-fecha { background: var(--grad); color: #fff; box-shadow: var(--sombra-azul); }
.pastilla { display: inline-flex; align-items: center; gap: .3rem; padding: .32rem .7rem; border-radius: 999px; background: var(--surface-2); color: var(--muted); font-size: .74rem; font-weight: 600; white-space: nowrap; }
.pastilla .ico { width: 14px; height: 14px; }
.pastilla-azul { background: var(--azul); color: #fff; }
.pastilla-celeste { background: var(--celeste-claro); color: var(--celeste-txt); }
.pastilla-ok { background: var(--ok-bg); color: var(--ok); }
.pastilla-alerta { background: var(--alert-bg); color: var(--alert-ink); }

.tarjeta-aviso { background: var(--warn-bg); color: var(--warn-ink); box-shadow: none; }
.tarjeta-aviso .tarjeta-cab { justify-content: flex-start; gap: .6rem; }
.lista-avisos { margin: 0 0 .8rem; padding-left: 1.2rem; font-size: .88rem; }
.lista-avisos li + li { margin-top: .35rem; }
.tarjeta-aviso .suave { color: inherit; opacity: .85; }
.tarjeta-ok { display: flex; gap: .9rem; align-items: center; background: var(--ok-bg); color: var(--ok); box-shadow: none; padding: 1.1rem 1.4rem; }
.tarjeta-ok > .ico { width: 30px; height: 30px; }
.tarjeta-ok strong { display: block; font-weight: 600; }
.tarjeta-ok span { font-size: .85rem; opacity: .9; }
.lista-notas { list-style: none; margin: 0; padding: 0; display: grid; gap: .6rem; }
.lista-notas li { display: flex; gap: .8rem; align-items: flex-start; padding: .75rem .9rem; border-radius: var(--r-md); background: var(--surface-2); font-size: .88rem; }
.lista-notas .ico { color: var(--azul); margin-top: 2px; }
.lista-notas strong { display: block; font-weight: 600; }

/* Grilla de revisión */
.tarjeta-grilla { padding-bottom: 1rem; }
.grilla-scroll { overflow: auto; max-height: 70vh; margin: 0 -1.5rem; padding: 0 1.5rem; }
.grilla { border-collapse: separate; border-spacing: 0; font-size: .78rem; min-width: 100%; }
.grilla th, .grilla td { padding: .45rem .4rem; vertical-align: top; border-bottom: 1px solid var(--line); }
.grilla thead th { position: sticky; top: 0; z-index: 2; background: var(--surface); text-align: center; font-weight: 500; color: var(--muted); padding-bottom: .7rem; }
.grilla thead th span { display: block; font-size: .72rem; }
.grilla thead th strong { display: block; font-size: 1.05rem; color: var(--ink); font-weight: 600; }
.grilla thead th i { display: inline-block; font-style: normal; font-size: .62rem; font-weight: 600; background: var(--warn-bg); color: var(--warn-ink); padding: .05rem .4rem; border-radius: 999px; }
.grilla thead th:first-child { text-align: left; left: 0; z-index: 3; }
.grilla tbody th { position: sticky; left: 0; z-index: 1; background: var(--surface); text-align: left; font-weight: 400; }
.persona { display: flex; align-items: center; gap: .6rem; white-space: nowrap; padding-right: .6rem; }
.persona strong { display: block; font-weight: 600; font-size: .82rem; }
.persona small { color: var(--muted); font-size: .7rem; }
.grilla td { min-width: 128px; }
.celda-serv { display: block; background: var(--azul-claro); border-radius: 10px; padding: .4rem .55rem; line-height: 1.3; color: var(--ink); }
.celda-serv + .celda-serv { margin-top: .3rem; }
.celda-serv b { display: block; color: var(--azul); font-weight: 600; font-size: .72rem; margin-top: .1rem; }
.celda-serv.esp { background: var(--celeste-claro); }
.celda-serv.esp b { color: var(--celeste-txt); }
.celda-franco { display: block; text-align: center; background: var(--ok-bg); color: var(--ok); border-radius: 10px; padding: .55rem .4rem; font-weight: 600; }

/* Choferes */
.buscador { display: flex; align-items: center; gap: .55rem; flex: 1; max-width: 380px; background: var(--surface-2); border-radius: 999px; padding: .2rem 1rem; color: var(--muted); }
.buscador input { flex: 1; border: 0; background: transparent; font: inherit; color: var(--ink); padding: .55rem 0; }
.buscador input:focus { outline: none; }
.fila-chofer { padding: .7rem .9rem; }
.fila-acciones { display: flex; gap: .45rem; }
.nota-pie { padding: 0 .5rem; }

/* Credenciales imprimibles */
.credenciales { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 1rem; }
.credencial { background: var(--surface); border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--sombra); padding: 0 1.1rem 1rem; break-inside: avoid; display: flex; flex-direction: column; gap: .5rem; }
.credencial-top { display: flex; justify-content: space-between; align-items: center; margin: 0 -1.1rem .4rem; padding: .8rem 1.1rem; background: var(--grad); color: #fff; font-size: .72rem; font-weight: 500; }
.credencial-top img { height: 11px; }
.credencial > strong { font-size: 1.05rem; font-weight: 600; }
.credencial-datos { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
.credencial-datos div { background: var(--azul-claro); border-radius: var(--r-sm); padding: .5rem .7rem; }
.credencial-datos span { display: block; font-size: .7rem; color: var(--muted); }
.credencial-datos b { font: 700 1.25rem/1.2 ui-monospace, monospace; letter-spacing: .12em; color: var(--azul); }
.credencial small { color: var(--muted); font-size: .72rem; }

/* Vista previa del chofer dentro del panel */
.vista-previa { display: grid; grid-template-columns: auto minmax(0, 340px); gap: 2rem; align-items: start; }
.telefono { width: 390px; height: 790px; border: 11px solid #0f2135; border-radius: 48px; overflow: auto; background: var(--bg); box-shadow: 0 30px 60px -25px rgba(6, 40, 80, .45); scrollbar-width: none; }
.telefono::-webkit-scrollbar { display: none; }
.telefono .app { min-height: 100%; }
.previa-info { text-align: center; }
.previa-info .avatar { margin: 0 auto .8rem; width: 64px; height: 64px; font-size: 1.2rem; }
.previa-info h2 { font-size: 1.2rem; }
.previa-info p:last-child { margin-top: 1rem; font-size: .9rem; color: var(--muted); }

/* Acceso de la oficina */
.acceso { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); min-height: 100vh; }
.acceso-marca { position: relative; overflow: hidden; background: var(--grad); color: #fff; padding: 3.5rem; display: flex; flex-direction: column; gap: 2.6rem; isolation: isolate; }
.acceso-marca::before, .acceso-marca::after { content: ""; position: absolute; z-index: -1; border-radius: 50%; border: 40px solid rgba(255, 255, 255, .06); }
.acceso-marca::before { width: 420px; height: 420px; right: -160px; top: -120px; }
.acceso-marca::after { width: 300px; height: 300px; left: -120px; bottom: -120px; }
.acceso-marca .logo-blanco { height: 24px; align-self: flex-start; }
.acceso-marca h1 { font-size: 2.4rem; font-weight: 700; line-height: 1.1; margin-top: auto; }
.acceso-marca div > p { opacity: .85; margin-top: .3rem; }
.acceso-marca ul { list-style: none; margin: 0 0 auto; padding: 0; display: grid; gap: 1rem; max-width: 380px; }
.acceso-marca li { display: flex; gap: .9rem; align-items: center; }
.acceso-marca li .ico { width: 46px; height: 46px; padding: 11px; border-radius: var(--r-md); background: rgba(255, 255, 255, .16); }
.acceso-marca li strong { display: block; font-weight: 600; }
.acceso-marca li span { font-size: .85rem; opacity: .85; }
.acceso-form { display: grid; place-items: center; padding: 2rem 1.5rem; background: var(--surface); }
.acceso-caja { width: 100%; max-width: 380px; }
.acceso-caja h2 { font-size: 1.8rem; font-weight: 600; }
.acceso-caja .suave { margin: .3rem 0 2rem; }

/* ---------- Pantallas chicas ---------- */
@media (max-width: 900px) {
  .admin { grid-template-columns: 1fr; }
  .lateral { position: sticky; top: 0; z-index: 10; height: auto; flex-direction: row; align-items: center; gap: .8rem; padding: .7rem 16px; border-right: 0; border-bottom: 1px solid var(--line); }
  .lateral-logo { padding: 0; }
  .lateral-logo img { max-width: 110px; }
  .lateral-titulo { display: none; }
  .lateral nav { flex-direction: row; margin: 0 0 0 auto; }
  .lateral nav a { padding: .55rem .7rem; }
  .lateral nav a span { display: none; }
  .lateral-pie { margin: 0; padding: 0; background: none; }
  .lateral-pie strong { display: none; }
  .lateral-pie .avatar { display: none; }
  .contenido { padding: 1.4rem 16px 2.5rem; }
  .subir-tarjeta { grid-template-columns: 1fr; gap: 1rem; }
  .acceso { grid-template-columns: 1fr; }
  .acceso-marca { padding: 2rem 1.5rem; gap: 1.4rem; }
  .acceso-marca h1 { font-size: 1.8rem; margin-top: 1rem; }
  .acceso-marca ul { display: none; }
  .vista-previa { grid-template-columns: 1fr; }
  .telefono { width: 100%; max-width: 390px; margin: 0 auto; }
  .fila-semana, .fila-chofer { flex-wrap: wrap; }
  .fila-acciones { width: 100%; }
  .tarjeta { padding: 1.2rem; border-radius: var(--r-lg); }
}

@media print {
  .lateral, .cont-acciones, .flash { display: none !important; }
  .admin { display: block; }
  body { background: #fff; }
  .contenido { padding: 0; }
  .credencial { box-shadow: none; border: 1px dashed #999; }
  .credencial-top, .credencial-datos div { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

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

/* Marca de versión de prueba */
.marca-beta { display: inline-block; vertical-align: middle; margin-left: .4em; padding: .2em .6em; border-radius: 999px; font-size: .62rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; line-height: 1.2; background: rgba(255,255,255,.22); color: #fff; border: 1px solid rgba(255,255,255,.45); }
.lateral-titulo .marca-beta { background: var(--grad); border-color: transparent; font-size: .58rem; }
