:root {
  --fondo: #0b1419; --vidrio: rgba(11, 20, 25, .78); --vidrio2: rgba(11, 20, 25, .62); --linea: rgba(255, 255, 255, .12);
  --texto: #e8eef1; --suave: #9fb0b8; --acento: #14d5cf; --rojo: #d6312b; --ambar: #f2a33a;
  --r: 12px; --sombra: 0 8px 30px rgba(0, 0, 0, .35);
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; background: var(--fondo); color: var(--texto);
  font: 14px/1.4 'Outfit', system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
#lienzo { position: fixed; inset: 0; width: 100%; height: 100%; display: block; touch-action: none; outline: none; }
button, select, input { font: inherit; color: inherit; }

/* ---------- CONFIDENCIAL ---------- */
.marca-agua { position: fixed; inset: -50%; z-index: 2; pointer-events: none; transform: rotate(-24deg);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='520' height='200'%3E%3Ctext x='0' y='120' font-family='Arial,Helvetica,sans-serif' font-size='54' font-weight='700' letter-spacing='6' fill='rgba(214,49,43,0.16)' stroke='rgba(255,255,255,0.10)' stroke-width='1'%3ECONFIDENCIAL%3C/text%3E%3C/svg%3E");
  background-repeat: repeat; }
.sello { position: fixed; z-index: 6; top: 14px; right: 74px; pointer-events: none; transform: rotate(-7deg);
  color: #fff; background: rgba(214, 49, 43, .88); border: 3px double rgba(255, 255, 255, .9); border-radius: 6px;
  padding: 6px 14px 5px; font: 800 22px/1 Arial, Helvetica, sans-serif; letter-spacing: .14em; text-align: center; box-shadow: var(--sombra); }
.sello small { display: block; font: 600 10px/1.3 'Outfit', sans-serif; letter-spacing: .08em; margin-top: 3px; text-transform: uppercase; opacity: .95; }

/* ---------- cabecera ---------- */
.cabecera { position: fixed; z-index: 5; top: 12px; left: 12px; max-width: min(560px, calc(100% - 330px)); padding: 12px 16px 12px;
  background: var(--vidrio); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid var(--linea); border-radius: var(--r); box-shadow: var(--sombra); }
.marca { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.marca-logo { font-weight: 700; letter-spacing: .06em; font-size: 15px; color: #fff; }
.marca-logo b { color: var(--acento); font-weight: 700; }
.marca-sep { width: 1px; height: 14px; background: var(--linea); }
.marca-sub { color: var(--suave); font-size: 12px; text-transform: uppercase; letter-spacing: .08em; }
.cabecera h1 { margin: 0; font-size: 17px; line-height: 1.25; font-weight: 600; }
.cabecera .meta { margin: 6px 0 0; color: var(--suave); font-size: 12.5px; }
.cabecera .meta b { color: var(--texto); font-weight: 600; }

/* ---------- panel ---------- */
.boton-panel { position: fixed; z-index: 7; top: 14px; right: 14px; width: 44px; height: 44px; border-radius: 10px; border: 1px solid var(--linea);
  background: var(--vidrio); backdrop-filter: blur(10px); cursor: pointer; font-size: 18px; }
.panel { position: fixed; z-index: 5; top: 92px; right: 12px; bottom: calc(var(--atr-h, 30px) + 128px); width: 300px; overflow: auto; padding: 4px 14px 12px;
  background: var(--vidrio); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid var(--linea); border-radius: var(--r); box-shadow: var(--sombra);
  scrollbar-width: thin; }
.panel.oculto { display: none; }
.panel section { padding: 10px 0; border-bottom: 1px solid var(--linea); }
.panel section:last-of-type { border-bottom: 0; }
.kicker { font-size: 11px; text-transform: uppercase; letter-spacing: .1em; color: var(--acento); margin-bottom: 7px; font-weight: 600; }
.botones { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 6px; }
.b { border: 1px solid var(--linea); background: rgba(255, 255, 255, .06); border-radius: 8px; padding: 6px 10px; cursor: pointer; font-size: 13px; min-height: 32px; }
.b:hover { background: rgba(255, 255, 255, .12); }
.b.on, .b.acento { border-color: var(--acento); background: rgba(20, 213, 207, .16); }
.b.mia { font-size: 12px; }
.fila { display: flex; gap: 8px; align-items: center; margin: 4px 0; }
select { background: rgba(255, 255, 255, .06); border: 1px solid var(--linea); border-radius: 8px; padding: 5px 8px; min-height: 32px; }
select option { background: #13222a; }
input[type=range] { width: 100%; accent-color: var(--acento); }
.etq { color: var(--suave); font-size: 12.5px; }
.pildora { font-size: 11.5px; color: var(--suave); border: 1px solid var(--linea); border-radius: 99px; padding: 2px 8px; }
.capas { display: grid; gap: 4px; }
.capa { display: grid; grid-template-columns: 18px 12px 1fr; gap: 8px; align-items: center; font-size: 13px; cursor: pointer; }
.capa .sw { width: 12px; height: 12px; border-radius: 3px; }
.actividad { font-size: 12.5px; color: var(--suave); max-height: 220px; overflow: auto; }
.actividad div { padding: 3px 0; border-bottom: 1px dashed var(--linea); }
.actividad b { color: var(--texto); font-weight: 500; }
.actividad .crit { color: #ff8a80; }
.nota { font-size: 11.5px; color: var(--suave); margin: 10px 0 0; }

/* ---------- ficha y rótulos ---------- */
.ficha { position: fixed; z-index: 6; left: 12px; bottom: calc(var(--atr-h, 30px) + 128px); width: min(380px, calc(100% - 24px)); padding: 12px 14px;
  background: var(--vidrio); backdrop-filter: blur(10px); border: 1px solid var(--linea); border-radius: var(--r); box-shadow: var(--sombra); font-size: 13px; }
.ficha h3 { margin: 0 24px 4px 0; font-size: 15px; }
.ficha .cat { display: inline-block; font-size: 11px; padding: 1px 8px; border-radius: 99px; margin-bottom: 6px; color: #0b1419; font-weight: 600; }
.ficha p { margin: 4px 0; color: var(--suave); }
.ficha-cerrar { position: absolute; top: 6px; right: 8px; background: none; border: 0; font-size: 20px; cursor: pointer; }
#rotulos { position: fixed; inset: 0; pointer-events: none; z-index: 3; overflow: hidden; }
.rotulo { position: absolute; transform: translate(-50%, calc(-100% - 8px)); white-space: nowrap; font-size: 12px; padding: 3px 8px; border-radius: 6px;
  background: rgba(11, 20, 25, .86); border: 1px solid rgba(20, 213, 207, .6); box-shadow: 0 2px 8px rgba(0, 0, 0, .4); }
.rotulo::after { content: ''; position: absolute; left: 50%; bottom: -7px; width: 1px; height: 7px; background: rgba(20, 213, 207, .8); }
.rotulo.sel { border-color: var(--ambar); }
.leyenda-recorrido { position: fixed; z-index: 6; left: 50%; bottom: calc(var(--atr-h, 30px) + 128px); transform: translateX(-50%); max-width: min(640px, calc(100% - 24px));
  background: var(--vidrio); backdrop-filter: blur(10px); border: 1px solid var(--acento); border-radius: var(--r); padding: 10px 16px; font-size: 14px; text-align: center; }

/* ---------- línea de tiempo ---------- */
.tiempo { position: fixed; z-index: 5; left: 12px; right: 12px; bottom: calc(var(--atr-h, 30px) + 8px); padding: 10px 14px 8px; background: var(--vidrio);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid var(--linea); border-radius: var(--r); box-shadow: var(--sombra); }
.tiempo-fila { display: flex; gap: 12px; align-items: center; }
.tiempo-centro { flex: 1; min-width: 0; }
.reproducir { width: 44px; height: 44px; border-radius: 50%; font-size: 16px; flex: none; border-color: var(--acento); }
.fases { display: flex; height: 14px; border-radius: 4px; overflow: hidden; margin-bottom: 4px; }
.fases div { cursor: pointer; font-size: 9.5px; display: flex; align-items: center; justify-content: center; overflow: hidden; white-space: nowrap; color: rgba(255, 255, 255, .92); border-right: 1px solid rgba(0, 0, 0, .25); }
.fases div.act { outline: 2px solid #fff; outline-offset: -2px; }
.tiempo-texto { font-size: 13px; color: var(--suave); margin-top: 2px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tiempo-texto b { color: var(--texto); font-weight: 600; }

/* ---------- atribuciones (siempre visibles) ---------- */
.atribuciones { position: fixed; z-index: 8; left: 0; right: 0; bottom: 0; min-height: 30px; display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 4px 12px;
  padding: 4px 12px; background: rgba(11, 20, 25, .82); font-size: 11px; color: #c9d4d9; }
.atribuciones img { height: 18px; vertical-align: middle; }
.atribuciones a { color: #c9d4d9; }
.atribuciones .izq { margin-right: auto; color: var(--suave); }
.atribuciones .datos { white-space: normal; }

/* ---------- carga ---------- */
.carga { position: fixed; inset: 0; z-index: 20; display: grid; place-items: center; background: radial-gradient(circle at 50% 40%, #13262e, #0b1419 70%); transition: opacity .6s; }
.carga.fuera { opacity: 0; pointer-events: none; }
.carga-caja { display: grid; gap: 14px; justify-items: center; color: var(--suave); }
.carga .marca-logo { font-size: 26px; }
.giro { width: 34px; height: 34px; border-radius: 50%; border: 3px solid rgba(255, 255, 255, .15); border-top-color: var(--acento); animation: g 1s linear infinite; }
@keyframes g { to { transform: rotate(360deg); } }

/* ---------- móvil ---------- */
@media (max-width: 760px) {
  .cabecera { max-width: calc(100% - 24px); right: 64px; padding: 9px 12px; }
  .cabecera h1 { font-size: 14px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .cabecera .meta { font-size: 11.5px; }
  .marca-sub { display: none; }
  .sello { top: 132px; bottom: auto; right: 10px; font-size: 16px; padding: 5px 10px 4px; }
  .sello small { font-size: 8.5px; }
  .panel { top: auto; left: 8px; right: 8px; bottom: calc(var(--atr-h, 30px) + 96px); width: auto; max-height: 52vh; }
  .tiempo { left: 8px; right: 8px; padding: 8px 10px 6px; }
  .ficha { bottom: calc(var(--atr-h, 30px) + 96px); left: 8px; }
  .leyenda-recorrido { bottom: calc(var(--atr-h, 30px) + 100px); font-size: 13px; }
  .atribuciones { justify-content: flex-start; font-size: 10px; padding: 3px 8px; }
  .atribuciones .izq { display: none; }
}
@media (prefers-reduced-motion: reduce) { .giro { animation: none; } }

/* =====================================================================
   Ampliaciones del visor del puente de Málaga (4D con programa y KPI)
   ===================================================================== */
:root { --rojo-osc: #8f1d18; --e-ejec: #f39c12; --e-retira: #d64541; --e-temp: #4f86c6; --e-hecho: #9d9a93; --cab-h: 120px; --pie-h: 120px; }
.sello { background: rgba(143, 29, 24, .92); }
.cabecera h1 { font-size: 15px; }
.cabecera .meta { font-size: 12px; }
.sello-mini { display: inline-block; transform: rotate(-3deg); background: var(--rojo-osc); color: #fff; border: 2px double rgba(255, 255, 255, .85); border-radius: 4px;
  padding: 1px 7px 0; font: 800 11px/1.5 Arial, Helvetica, sans-serif; letter-spacing: .14em; vertical-align: 1px; }
.panel { bottom: auto; max-height: calc(100vh - 92px - var(--atr-h, 30px) - var(--pie-h, 120px) - 26px); width: 290px; }
.panel details.plegable { padding: 9px 0; border-bottom: 1px solid var(--linea); }
.panel details.plegable:last-of-type { border-bottom: 0; }
.panel details.plegable > summary { cursor: pointer; list-style: none; margin: 0; display: flex; justify-content: space-between; }
.panel details.plegable > summary::-webkit-details-marker { display: none; }
.panel details.plegable > summary::after { content: '▸'; color: var(--suave); transition: transform .15s; }
.panel details.plegable[open] > summary::after { transform: rotate(90deg); }
.panel details.plegable[open] > summary { margin-bottom: 7px; }
.ficha { bottom: calc(var(--atr-h, 30px) + var(--pie-h, 120px) + 18px); left: auto; right: 314px; }
.leyenda-recorrido { bottom: calc(var(--atr-h, 30px) + var(--pie-h, 120px) + 18px); }
.interruptor { display: flex; gap: 8px; align-items: center; font-size: 12.5px; color: var(--suave); margin-top: 4px; cursor: pointer; }
.segmentado { display: flex; gap: 0; }
.segmentado .b { flex: 1; border-radius: 0; font-size: 12.5px; }
.segmentado .b:first-child { border-radius: 8px 0 0 8px; }
.segmentado .b:last-child { border-radius: 0 8px 8px 0; border-left: 0; }
.leyenda-estados { display: grid; gap: 4px; margin-top: 8px; font-size: 12px; color: var(--suave); }
.leyenda-estados i, .gantt-leyenda i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.actividad small { color: var(--suave); }

/* KPI del día */
.kpi { position: fixed; z-index: 5; left: 12px; top: calc(var(--cab-h, 120px) + 10px); width: 340px;
  max-height: calc(100vh - var(--cab-h, 120px) - var(--pie-h, 120px) - var(--atr-h, 30px) - 54px); overflow: auto;
  background: var(--vidrio); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid var(--linea); border-radius: var(--r); box-shadow: var(--sombra); scrollbar-width: thin; }
.kpi-cab { display: flex; align-items: center; gap: 10px; width: 100%; background: none; border: 0; padding: 10px 14px 6px; cursor: pointer; text-align: left; }
.kpi-cab .kicker { margin: 0; }
.kpi-fecha { font-size: 13px; font-weight: 600; flex: 1; text-align: right; font-variant-numeric: tabular-nums; }
.kpi-flecha { color: var(--suave); transition: transform .2s; }
.kpi.plegado .kpi-flecha { transform: rotate(-90deg); }
.kpi.plegado .kpi-cuerpo { display: none; }
.kpi-cuerpo { padding: 0 14px 12px; }
.kpi-rejilla { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.kpi-c { background: rgba(255, 255, 255, .05); border: 1px solid var(--linea); border-radius: 9px; padding: 7px 8px 6px; min-width: 0; }
.kpi-c b { display: block; font-size: 18px; font-weight: 600; line-height: 1.1; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kpi-c span { display: block; font-size: 10.5px; color: var(--suave); text-transform: uppercase; letter-spacing: .04em; margin-top: 2px; }
.kpi-c small { display: block; font-size: 10.5px; color: var(--suave); margin-top: 3px; line-height: 1.25; }
.kpi-c small.crit, .crit { color: #ff8a80; }
.kpi-barra { display: block; height: 4px; border-radius: 3px; background: rgba(255, 255, 255, .12); margin-top: 5px; overflow: hidden; }
.kpi-barra i { display: block; height: 100%; background: var(--acento); }
.kpi-tarea { margin-top: 10px; font-size: 12.5px; }
.kpi-tarea .kicker { margin-bottom: 3px; }
.kpi-tarea small { color: var(--suave); }
.kpi-linea { display: grid; grid-template-columns: 58px 1fr; gap: 6px; font-size: 12px; margin-top: 4px; color: var(--texto); }
.kpi-linea span { color: var(--suave); }
.kpi-medios { margin-top: 8px; font-size: 12px; }
.kpi-medios summary { cursor: pointer; color: var(--acento); font-size: 12px; }
.kpi-medios p { margin: 6px 0; color: var(--suave); }
.kpi-medios b { color: var(--texto); font-weight: 600; }

/* pie: reproducción, estados y Gantt */
.velocidad { width: 44px; height: 32px; padding: 0; font-variant-numeric: tabular-nums; flex: none; }
.gantt-boton { flex: none; }
.gantt-boton[aria-expanded="true"] { border-color: var(--acento); background: rgba(20, 213, 207, .16); }
.tiempo-texto .fecha-prog { color: var(--texto); font-variant-numeric: tabular-nums; }
.tiempo-texto .noche { color: #b9c8ff; }
.gantt { margin-top: 8px; border-top: 1px solid var(--linea); padding-top: 6px; }
.gantt[hidden] { display: none; }
.gantt-cab { display: grid; grid-template-columns: 300px 1fr; font-size: 11px; color: var(--suave); }
.gantt-nombres-cab { padding: 0 6px 3px 0; text-transform: uppercase; letter-spacing: .06em; font-size: 10.5px; }
.gantt-nombres-cab small { text-transform: none; letter-spacing: 0; }
.gantt-escala { position: relative; height: 16px; border-bottom: 1px solid var(--linea); overflow: hidden; }
.gantt-escala span { position: absolute; top: 0; font-size: 10px; white-space: nowrap; color: var(--suave); border-left: 1px solid var(--linea); padding-left: 3px; height: 16px; }
.gantt-escala span.anio { color: var(--texto); font-weight: 600; }
.gantt-cuerpo { position: relative; height: 112px; overflow-y: auto; overflow-x: hidden; scrollbar-width: thin; }
.g-fila { display: grid; grid-template-columns: 300px 1fr; align-items: center; min-height: 18px; cursor: pointer; font-size: 11.5px; border-radius: 4px; }
.g-fila[hidden] { display: none; }
.g-fila:hover { background: rgba(255, 255, 255, .05); }
.g-nombre { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding: 0 8px 0 14px; color: var(--suave); }
.g-grupo .g-nombre { padding-left: 2px; color: var(--texto); font-weight: 600; }
.g-flecha { display: inline-block; width: 12px; color: var(--suave); transition: transform .15s; }
.g-grupo.abierto .g-flecha { transform: rotate(90deg); }
.g-wbs { color: rgba(159, 176, 184, .7); margin-right: 6px; font-variant-numeric: tabular-nums; }
.g-pista { position: relative; height: 18px; }
.g-barra { position: absolute; top: 5px; height: 8px; border-radius: 3px; background: #4b5e69; min-width: 2px; }
.g-grupo .g-barra { top: 6px; height: 6px; background: rgba(255, 255, 255, .28); border-radius: 1px; }
.g-barra.g-hito { width: 9px !important; height: 9px; top: 4px; transform: translateX(-4px) rotate(45deg); border-radius: 1px; background: #c9d4d9; }
.g-fila.g-hecha .g-barra { background: #6f8f7f; }
.g-fila.g-curso .g-barra { background: var(--ambar); box-shadow: 0 0 0 1px rgba(242, 163, 58, .35); }
.g-fila.g-curso .g-nombre { color: var(--texto); }
.g-fila.es-crit:not(.g-grupo) .g-barra { box-shadow: inset 0 -2px 0 #ff5a4e; }
.g-fila.g-asoc { background: rgba(20, 213, 207, .12); outline: 1px solid rgba(20, 213, 207, .55); outline-offset: -1px; }
.g-fila.g-asoc .g-nombre { color: #fff; }
.g-cursor { position: absolute; top: 0; width: 2px; margin-left: -1px; background: var(--acento); pointer-events: none; z-index: 2; }
.g-banda { position: absolute; top: 0; background: rgba(20, 213, 207, .10); pointer-events: none; z-index: 1; }
.gantt-leyenda { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 11px; color: var(--suave); padding-top: 5px; }
.gantt-leyenda i.g-hecha { background: #6f8f7f; } .gantt-leyenda i.g-curso { background: var(--ambar); } .gantt-leyenda i.g-pend { background: #4b5e69; }
.gantt-leyenda i.g-crit { background: #ff5a4e; } .gantt-leyenda i.g-asoc { background: rgba(20, 213, 207, .55); }
.ficha-estado { font-size: 11.5px; border-top: 1px solid var(--linea); padding-top: 5px; }

@media (max-width: 1180px) {
  .kpi { width: 320px; }
  .gantt-cab, .g-fila { grid-template-columns: 220px 1fr; }
}
@media (max-width: 760px) {
  .cabecera h1 { font-size: 13px; }
  .cabecera .meta { font-size: 11px; margin-top: 4px; }
  .kpi { left: 8px; right: 8px; width: auto; top: calc(var(--cab-h, 100px) + 6px); max-height: 46vh; }
  .kpi-c b { font-size: 15px; }
  .kpi-fecha { font-size: 12px; }
  .sello { top: auto; bottom: calc(var(--atr-h, 30px) + var(--pie-h, 100px) + 14px); right: 10px; }
  .panel { bottom: calc(var(--atr-h, 30px) + var(--pie-h, 100px) + 12px); }
  .ficha { left: 8px; right: 8px; bottom: calc(var(--atr-h, 30px) + var(--pie-h, 100px) + 12px); }
  .leyenda-recorrido { bottom: calc(var(--atr-h, 30px) + var(--pie-h, 100px) + 12px); }
  .gantt-cab, .g-fila { grid-template-columns: 130px 1fr; }
  .g-nombre { padding-left: 6px; }
  .gantt-cuerpo { height: 150px; }
  .velocidad { width: 38px; }
  .tiempo-texto { font-size: 12px; }
}

/* ---------- recorrido automático por defecto (autorecorrido.js) ---------- */
.b-recorrido { position: fixed; z-index: 6; left: 50%; bottom: calc(var(--atr-h, 30px) + var(--pie-h, 120px) + 18px); transform: translateX(-50%); padding: 8px 18px; min-height: 40px;
  font: 600 14px/1 'Outfit', system-ui, sans-serif; color: var(--texto); cursor: pointer; border: 1px solid var(--acento); border-radius: 999px;
  background: var(--vidrio); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); box-shadow: var(--sombra); }
.b-recorrido:hover, .b-recorrido:focus-visible { background: rgba(20, 213, 207, .24); }
.b-recorrido[hidden], .aviso-recorrido[hidden] { display: none; }
.aviso-recorrido { position: fixed; z-index: 9; left: 50%; bottom: calc(var(--atr-h, 30px) + var(--pie-h, 120px) + 18px + 52px); transform: translateX(-50%); width: max-content; max-width: min(520px, calc(100% - 24px));
  padding: 9px 14px; font-size: 13px; line-height: 1.35; text-align: center; color: var(--texto); background: var(--vidrio); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--linea); border-radius: var(--r); box-shadow: var(--sombra); pointer-events: none; }
.fundido-recorrido { position: fixed; inset: 0; z-index: 4; background: #05090b; opacity: 0; pointer-events: none; }
.leyenda-recorrido.rec-auto { width: max-content; opacity: 0; transition: opacity .45s ease; pointer-events: none; }
.leyenda-recorrido.rec-auto.ver { opacity: 1; }
.leyenda-recorrido.rec-auto small { display: block; margin-top: 3px; color: var(--suave); font-size: 12.5px; }
@media (max-width: 760px) {
  .b-recorrido { bottom: calc(var(--atr-h, 30px) + var(--pie-h, 100px) + 12px); padding: 7px 16px; min-height: 38px; font-size: 13.5px; }
  .aviso-recorrido { bottom: calc(var(--atr-h, 30px) + var(--pie-h, 100px) + 12px + 48px); font-size: 12.5px; }
  .panel:not(.oculto) ~ .b-recorrido { display: none; }
  .leyenda-recorrido.rec-auto small { font-size: 11.5px; }
}
@media (prefers-reduced-motion: reduce) { .leyenda-recorrido.rec-auto { transition: none; } }

/* ---------- mini Gantt resumen sincronizado (minigantt.js) ---------- */
.mg { position: fixed; z-index: 5; left: 12px; top: 130px; width: 440px; max-width: calc(100% - 24px); color: var(--texto, #e8eef1); font-family: 'Outfit', system-ui, sans-serif;
  background: rgba(16, 18, 22, .86); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid var(--linea, rgba(255,255,255,.12)); border-radius: var(--r, 12px); box-shadow: var(--sombra, 0 8px 30px rgba(0,0,0,.35)); }
.mg-cab { display: flex; align-items: center; gap: 8px; width: 100%; min-height: 34px; padding: 6px 12px; background: none; border: 0; color: inherit; font: 600 13px/1.2 'Outfit', system-ui, sans-serif; cursor: pointer; text-align: left; }
.mg-cab:focus-visible { outline: 2px solid #14d5cf; outline-offset: -2px; border-radius: 10px; }
.mg-ico { color: #14d5cf; }
.mg-tit { flex: 0 1 auto; }
.mg-sub { flex: 1; color: var(--suave, #9fb0b8); font-weight: 400; font-size: 12px; }
.mg.con-activas .mg-sub::before { content: '● '; color: #14d5cf; }
.mg-flecha { color: var(--suave, #9fb0b8); transition: transform .2s; }
.mg.abierto .mg-flecha { transform: rotate(180deg); }
.mg-cuerpo { display: none; position: relative; padding: 0 8px 6px; }
.mg.abierto { overflow-y: auto; scrollbar-width: thin; }
.mg.abierto .mg-cuerpo { display: block; }
.mg-lienzo { display: block; width: 100%; height: 200px; cursor: ew-resize; touch-action: none; border-radius: 6px; background: rgba(23, 29, 36, .9); }
.mg.arrastrando .mg-lienzo { cursor: grabbing; }
.mg-tip { position: absolute; z-index: 2; max-width: 240px; padding: 5px 8px; font-size: 11.5px; line-height: 1.35; pointer-events: none; color: #e8eef1;
  background: rgba(16, 18, 22, .96); border: 1px solid rgba(255, 255, 255, .14); border-radius: 6px; }
.mg-tip span { color: #9fb0b8; }
.mg-pie { margin-top: 4px; font-size: 10.5px; color: var(--suave, #9fb0b8); }
input[type=range] { touch-action: none; }
@media (max-width: 760px) {
  .mg { left: auto; right: 8px; top: auto; bottom: calc(var(--atr-h, 30px) + var(--pie-h, 100px) + 12px); width: auto; }
  .mg:not(.abierto) .mg-cab { padding: 6px 10px; min-height: 38px; }
  .mg:not(.abierto) .mg-sub { display: none; }
  .mg.abierto { left: 8px; right: 8px; z-index: 7; }
  .mg-pie { display: none; }
  body.mg-abierto .b-recorrido { display: none; }
}

/* Gantt del programa: arrastrar sobre las barras recorre el tiempo (en vertical sigue desplazando la lista) */
.g-pista { touch-action: pan-y; cursor: ew-resize; }
@media (max-width: 760px) { .b-recorrido { left: 8px; transform: none; } }   /* no tapa el sello CONFIDENCIAL */
