:root{
  --fondo:#f5f4f0; --papel:#fff; --texto:#1f2a2e; --suave:#5e6b70; --linea:#dcd9d0;
  --marca:#1f4d46; --marca-osc:#163a35; --acento:#b08a3e;
  --ok:#1d7a4a; --ok-bg:#e3f3ea; --aviso:#8a5a00; --aviso-bg:#fdf1d8; --mal:#b3261e; --mal-bg:#fbe5e3;
  --radio:12px;
}
*{box-sizing:border-box}
html{font-size:16px}
body{margin:0;background:var(--fondo);color:var(--texto);font-family:system-ui,-apple-system,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;line-height:1.5}
a{color:var(--marca)}
h1{font-size:1.6rem;margin:0 0 .25rem}
h2{font-size:1.2rem;margin:1.8rem 0 .6rem}
h3{font-size:1rem;margin:1rem 0 .4rem}
.suave{color:var(--suave)}
.pequeno{font-size:.875rem}
.derecha{text-align:right}
.nowrap{white-space:nowrap}

/* ---------- estructura: barra superior verde + menú de iconos ---------- */
:root{--alto-barra:56px;--ancho-menu:60px;--ancho-menu-abierto:244px}
.sprite{position:absolute;width:0;height:0;overflow:hidden}
.ico{width:22px;height:22px;flex:0 0 22px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.barra{position:fixed;top:0;left:0;right:0;height:var(--alto-barra);background:var(--marca);color:#fff;display:flex;align-items:center;gap:.8rem;padding:0 1rem 0 .9rem;z-index:60;box-shadow:0 1px 4px rgba(0,0,0,.25)}
.barra .marca{color:#fff;text-decoration:none;font-weight:700;font-size:1.2rem;letter-spacing:.02em;white-space:nowrap}
.barra-derecha{margin-left:auto;display:flex;align-items:center;gap:1.1rem;min-width:0}
.reloj{font-size:.92rem;color:#d3e6e2;white-space:nowrap;font-variant-numeric:tabular-nums}
.barra .quien{color:#fff;text-decoration:none;display:flex;flex-direction:column;line-height:1.2;text-align:right;min-width:0}
.barra .quien strong{font-size:.95rem;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:16rem}
.barra .quien span{font-size:.74rem;color:#b9d4cf}
.barra form{margin:0}
.boton-salir{display:inline-flex;align-items:center;gap:.4rem;background:transparent;color:#fff;border:1px solid rgba(255,255,255,.55);border-radius:6px;padding:.32rem .75rem;font:inherit;font-size:.9rem;font-weight:600;cursor:pointer}
.boton-salir:hover{background:rgba(255,255,255,.14)}
.boton-salir .ico{width:18px;height:18px;flex-basis:18px}
.boton-menu{display:none;background:transparent;border:0;color:#fff;padding:.3rem;cursor:pointer;border-radius:6px}
.boton-menu .ico{width:26px;height:26px;flex-basis:26px}
.boton-menu:hover{background:rgba(255,255,255,.14)}

.menu{position:fixed;top:var(--alto-barra);left:0;bottom:0;width:var(--ancho-menu);background:#fff;border-right:1px solid var(--linea);overflow:hidden;white-space:nowrap;z-index:50;transition:width .16s ease,box-shadow .16s ease;padding:.5rem 0}
.menu:hover,.menu:focus-within{width:var(--ancho-menu-abierto);box-shadow:4px 0 18px rgba(31,42,46,.18);overflow-y:auto}
.bloque-menu{padding:.35rem 0;border-bottom:1px solid var(--linea)}
.bloque-menu:last-child{border-bottom:0}
.menu .item{display:flex;align-items:center;gap:1rem;height:44px;margin:0 .5rem;padding:0 .85rem;border-radius:8px;color:#4a5a5e;text-decoration:none;font-size:.95rem}
.menu .item .txt{opacity:0;transition:opacity .12s ease}
.menu:hover .item .txt,.menu:focus-within .item .txt{opacity:1}
.menu .item:hover{background:#eef3f2;color:var(--marca)}
.menu .item.activo{background:#dcebe8;color:var(--marca-osc);font-weight:600}
.contenido-app{margin:var(--alto-barra) 0 0 var(--ancho-menu);min-width:0}
.fondo-menu{display:none}
main{max-width:1320px;margin:0 auto;padding:1.6rem 1.6rem 3rem}
main.ancho{max-width:none;padding:1rem 1.2rem 1.5rem}
.entrada{margin-top:6vh}
@media (max-width:900px){
  .contenido-app{margin-left:0}
  .js .boton-menu{display:inline-flex}
  .js .menu{width:var(--ancho-menu-abierto);transform:translateX(-102%);transition:transform .18s ease;overflow-y:auto}
  .js .menu .item .txt{opacity:1}
  .js body.menu-abierto .menu{transform:none;box-shadow:0 0 30px rgba(0,0,0,.35)}
  .js body.menu-abierto .fondo-menu{display:block;position:fixed;inset:var(--alto-barra) 0 0 0;background:rgba(0,0,0,.4);z-index:45}
  .reloj{display:none}
  .barra .quien span{display:none}
  .boton-salir span{display:none}
  .boton-salir{padding:.4rem}
  main{padding:1.1rem 1rem 2.5rem}
  main.ancho{padding:.7rem .6rem 1.5rem}
}
.cabecera-pagina{display:flex;justify-content:space-between;align-items:flex-start;gap:1rem;flex-wrap:wrap;margin-bottom:1rem}
.acciones{display:flex;gap:.5rem;flex-wrap:wrap;align-items:center}

.tarjeta{background:var(--papel);border:1px solid var(--linea);border-radius:var(--radio);padding:1rem 1.2rem;margin-bottom:1rem;box-shadow:0 1px 2px rgba(31,42,46,.05)}
.rejilla{display:grid;gap:1rem;grid-template-columns:repeat(auto-fit,minmax(220px,1fr))}
.cifra{font-size:1.5rem;font-weight:700}
.cifra.negativa{color:var(--mal)}
.etiqueta{font-size:.8rem;text-transform:uppercase;letter-spacing:.04em;color:var(--suave)}

table{width:100%;border-collapse:collapse;background:var(--papel);border:1px solid var(--linea);border-radius:var(--radio);overflow:hidden;font-size:.95rem}
th,td{padding:.55rem .75rem;border-bottom:1px solid var(--linea);text-align:left;vertical-align:top}
th{background:#efede6;font-size:.8rem;text-transform:uppercase;letter-spacing:.04em;color:var(--suave)}
tr:last-child td{border-bottom:0}
td.num,th.num{text-align:right;white-space:nowrap}
.tabla-scroll{overflow-x:auto}

label{display:block;font-weight:600;font-size:.9rem;margin:.7rem 0 .2rem}
input[type=text],input[type=email],input[type=password],input[type=date],input[type=search],select,textarea{
  width:100%;padding:.5rem .6rem;border:1px solid #bdb9ad;border-radius:6px;font:inherit;background:#fff;color:var(--texto)}
textarea{min-height:5rem}
input:focus,select:focus,textarea:focus,button:focus-visible,a:focus-visible{outline:3px solid #8fb9b1;outline-offset:1px}
.fila{display:grid;gap:.8rem;grid-template-columns:repeat(auto-fit,minmax(200px,1fr))}
.en-linea{display:flex;gap:.5rem;align-items:flex-end;flex-wrap:wrap}
.en-linea>*{flex:0 1 auto}
.en-linea label{margin:0 0 .2rem}
form.inline{display:inline}
.casilla{display:flex;gap:.5rem;align-items:center;font-weight:400;margin:.3rem 0}
.casilla input{width:auto}

.boton{display:inline-block;padding:.5rem .95rem;border-radius:6px;border:1px solid var(--marca);background:var(--marca);color:#fff;font:inherit;font-weight:600;cursor:pointer;text-decoration:none;font-size:.95rem}
.boton:hover{background:var(--marca-osc)}
.boton.sec{background:#fff;color:var(--marca)}
.boton.sec:hover{background:#eef3f2}
.boton.peligro{background:#fff;color:var(--mal);border-color:var(--mal)}
.boton.peligro:hover{background:var(--mal-bg)}
.boton.mini{padding:.2rem .55rem;font-size:.85rem}

.insignia{display:inline-block;padding:.1rem .55rem;border-radius:999px;font-size:.78rem;font-weight:600;background:#e8e6de;color:#4a5358}
.insignia.ok{background:var(--ok-bg);color:var(--ok)}
.insignia.aviso{background:var(--aviso-bg);color:var(--aviso)}
.insignia.mal{background:var(--mal-bg);color:var(--mal)}

.mensaje{padding:.7rem 1rem;border-radius:var(--radio);margin-bottom:1rem;border:1px solid}
.mensaje.ok{background:var(--ok-bg);border-color:#a8d5b9;color:#14522f}
.mensaje.error{background:var(--mal-bg);border-color:#efb3ae;color:#7d1a14}
.mensaje.aviso{background:var(--aviso-bg);border-color:#ecd08d;color:#5f3d00}
.clave-nueva{font-family:ui-monospace,Menlo,Consolas,monospace;font-size:1.05rem;word-break:break-all;background:#fff;border:2px dashed var(--acento);padding:.8rem;border-radius:6px;user-select:all}

.entrada{max-width:420px;margin:4rem auto}
.entrada .tarjeta{padding:1.6rem}
.entrada h1{color:var(--marca)}
.vacio{padding:1.5rem;text-align:center;color:var(--suave);background:var(--papel);border:1px dashed var(--linea);border-radius:var(--radio)}
.matriz td,.matriz th{text-align:center}
.matriz td:first-child,.matriz th:first-child{text-align:left}
.matriz input{width:auto}
details summary{cursor:pointer;color:var(--marca);font-weight:600}
pre.detalle{margin:0;font-size:.78rem;white-space:pre-wrap;word-break:break-word;color:var(--suave)}
.paginacion{display:flex;gap:.6rem;margin-top:1rem}
@media (max-width:640px){
  th,td{padding:.45rem .5rem}
}
@media print{.barra,.menu,.acciones,.gcal-izq,.gcal-barra .flecha{display:none!important}.contenido-app{margin:0}body{background:#fff}}
.crece{flex:1 1 260px}
fieldset.limpio{border:0;padding:0;margin:0;min-width:0}

/* ---------- calendario de inicio (estilo Google Calendar) ---------- */
/* colores pastel: --col es el relleno; el borde y el texto son más oscuros para que se lea bien */
.c0{--col:#f4b0b0}
.c1{--col:#f9c9b8}
.c2{--col:#fbd9a6}
.c3{--col:#fbeaa5}
.c4{--col:#cde7ad}
.c5{--col:#ade0c6}
.c6{--col:#acdcea}
.c7{--col:#b0c8f2}
.c8{--col:#c9bff0}
.c9{--col:#e5bbe9}
.c10{--col:#d5d9dc}
.c11{--col:#e0cdb9}
.tarea{--col:#fde28f}
.plazo{--col:#f4b0b0}
.ausencia{--col:#d5d9dc}
.festivo{--col:#f8cadd}
.gcal{display:grid;grid-template-columns:264px minmax(0,1fr);gap:1.1rem;align-items:start}
.gcal-izq{position:sticky;top:calc(var(--alto-barra) + .8rem);max-height:calc(100vh - var(--alto-barra) - 1.6rem);overflow-y:auto;padding-right:.2rem}
.titulo-izq{font-size:.95rem;margin:1.1rem 0 .4rem;color:var(--texto)}
.crear{position:relative;margin-bottom:.9rem}
.crear>summary{list-style:none;display:inline-flex;align-items:center;gap:.6rem;background:#fff;color:var(--texto);border-radius:999px;padding:.7rem 1.3rem .7rem 1rem;box-shadow:0 1px 3px rgba(60,64,67,.35),0 1px 8px rgba(60,64,67,.15);font-weight:600;cursor:pointer}
.crear>summary::-webkit-details-marker{display:none}
.crear>summary:hover{background:#f1f6f5;box-shadow:0 2px 6px rgba(60,64,67,.4)}
.crear>summary .ico{stroke:var(--marca);stroke-width:2.4}
.desplegable{position:absolute;left:0;top:calc(100% + .3rem);background:#fff;border-radius:8px;box-shadow:0 4px 18px rgba(60,64,67,.35);min-width:210px;padding:.35rem 0;z-index:20}
.desplegable a{display:flex;align-items:center;gap:.7rem;padding:.55rem 1rem;color:var(--texto);text-decoration:none;font-size:.93rem}
.desplegable a:hover{background:#eef3f2}
.mini-cab{display:flex;justify-content:space-between;align-items:center;font-size:.9rem;margin-bottom:.2rem}
.mini-cab strong{font-weight:600}
.mini-cab a{display:inline-block;width:1.7rem;text-align:center;text-decoration:none;color:var(--suave);font-size:1.2rem;border-radius:50%;line-height:1.7rem}
.mini-cab a:hover{background:#e6eeed}
.mini-rejilla{display:grid;grid-template-columns:repeat(7,1fr);text-align:center;font-size:.76rem;row-gap:1px}
.mini-dia-sem{color:var(--suave);padding:.2rem 0;font-weight:600}
.mini-dia{display:block;margin:0 auto;width:1.85rem;height:1.85rem;line-height:1.85rem;border-radius:50%;text-decoration:none;color:var(--texto)}
.mini-dia.fuera{color:#a3a89f}
.mini-dia:hover{background:#e6eeed}
.mini-dia.sel{background:#dcebe8}
.mini-dia.hoy{background:var(--marca);color:#fff;font-weight:700}
.cal-check{display:flex;align-items:center;gap:.65rem;margin:0;padding:.28rem .2rem;font-weight:400;font-size:.9rem;cursor:pointer;border-radius:6px}
.cal-check:hover{background:#eef3f2}
.cal-check input{position:absolute;opacity:0;width:0;height:0}
.cal-check .caja{flex:0 0 18px;width:18px;height:18px;border-radius:4px;border:2px solid var(--col,#5e6b70);border-color:color-mix(in srgb,var(--col,#5e6b70) 60%,#000);background:transparent;display:inline-block;position:relative}
.cal-check input:checked+.caja{background:var(--col,#5e6b70)}
.cal-check input:checked+.caja::after{content:"";position:absolute;left:4px;top:0;width:4px;height:9px;border:solid #2b3438;border-width:0 2px 2px 0;transform:rotate(45deg)}
.cal-check input:focus-visible+.caja{outline:3px solid #8fb9b1;outline-offset:2px}
.cal-check .nombre{min-width:0;overflow:hidden;text-overflow:ellipsis}
.cal-check.solo-mias{margin-top:.5rem;border-top:1px solid var(--linea);padding-top:.6rem;--col:#5e6b70}
.cal-fila{display:flex;align-items:center;position:relative}
.cal-fila .cal-check{flex:1 1 auto;min-width:0}
.cal-color>summary{list-style:none;cursor:pointer;width:1.7rem;height:1.7rem;line-height:1.6rem;text-align:center;border-radius:50%;color:var(--suave);font-size:1.2rem;font-weight:700}
.cal-color>summary::-webkit-details-marker{display:none}
.cal-color>summary:hover,.cal-color[open]>summary{background:#e6eeed}
.paleta{position:absolute;left:0;right:0;top:100%;z-index:30;background:#fff;border:1px solid var(--linea);border-radius:10px;box-shadow:0 6px 20px rgba(0,0,0,.18);padding:.6rem .7rem;margin:0}
.paleta-tit{margin:0 0 .5rem;font-size:.8rem;font-weight:600;color:var(--texto)}
.muestras{display:grid;grid-template-columns:repeat(6,1fr);gap:.4rem;margin-bottom:.5rem}
.muestra{width:1.7rem;height:1.7rem;border-radius:50%;border:2px solid #fff;background:var(--col);cursor:pointer;padding:0;box-shadow:0 0 0 1px #aeb4b8}
.muestra:hover{transform:scale(1.12)}
.muestra.actual{box-shadow:0 0 0 2px var(--texto)}
.solo-sin-js{margin-top:.4rem}
.js .solo-sin-js{display:none}
.pendiente h3{font-size:.74rem;text-transform:uppercase;letter-spacing:.05em;color:var(--suave);margin:.8rem 0 .2rem}
.pendiente h3.rojo{color:var(--mal)}
.lista-panel{list-style:none;margin:0;padding:0}
.lista-panel li{display:flex;gap:.5rem;align-items:flex-start;justify-content:space-between;padding:.4rem 0;border-bottom:1px solid var(--linea);font-size:.88rem}
.lista-panel li:last-child{border-bottom:0}
.lista-panel .texto{min-width:0}
.lista-panel .texto a{font-weight:600;text-decoration:none;word-break:break-word}
.lista-panel .texto small{display:block;color:var(--suave)}
.lista-panel .vence{white-space:nowrap;font-size:.78rem;font-weight:700;text-align:right}
.lista-panel .vence.mal{color:var(--mal)}
.lista-panel form{margin:0}
.todo-bien{color:var(--ok);font-size:.9rem;margin:.2rem 0}

.gcal-main{min-width:0}
.gcal-barra{display:flex;align-items:center;gap:.4rem;flex-wrap:wrap;margin-bottom:.6rem}
.gcal-barra h1{margin:0 auto 0 .6rem;font-size:1.4rem;font-weight:500}
.boton-hoy{border:1px solid #bdb9ad;border-radius:8px;padding:.4rem .95rem;background:#fff;color:var(--texto);text-decoration:none;font-weight:600;font-size:.92rem}
.boton-hoy:hover{background:#eef3f2}
.flecha{display:inline-block;width:2.2rem;height:2.2rem;line-height:2rem;text-align:center;border-radius:50%;text-decoration:none;color:var(--suave);font-size:1.5rem}
.flecha:hover{background:#e6eeed}
.conmutador{display:inline-flex;border:1px solid #bdb9ad;border-radius:8px;overflow:hidden}
.conmutador a{padding:.38rem .95rem;text-decoration:none;font-size:.9rem;font-weight:600;color:var(--texto);background:#fff}
.conmutador a+a{border-left:1px solid #bdb9ad}
.conmutador a:hover{background:#eef3f2}
.conmutador a.activo{background:#dcebe8;color:var(--marca-osc)}

/* vista día y semana: rejilla con horas */
.cal-scroll{height:calc(100vh - var(--alto-barra) - 5.4rem);min-height:420px;overflow:auto;background:var(--papel);border:1px solid var(--linea);border-radius:var(--radio);position:relative}
.cal-cab,.cal-cuerpo{display:grid;grid-template-columns:56px repeat(7,minmax(96px,1fr))}
.cal-cab.n1,.cal-cuerpo.n1{grid-template-columns:56px minmax(0,1fr)}
.cal-cab{position:sticky;top:0;z-index:6;background:var(--papel);border-bottom:1px solid var(--linea)}
.cal-cab .gutter{border-right:0}
.cab-dia{display:flex;flex-direction:column;align-items:center;padding:.4rem 0 .25rem;text-decoration:none;color:var(--suave);border-left:1px solid var(--linea)}
.cab-dia .dnom{font-size:.72rem;text-transform:uppercase;letter-spacing:.06em;font-weight:600}
.cab-dia .dnum{font-size:1.55rem;line-height:2.7rem;width:2.8rem;height:2.8rem;text-align:center;border-radius:50%;color:var(--texto)}
.cab-dia:hover .dnum{background:#eef3f2}
.cab-dia.hoy .dnom{color:var(--marca)}
.cab-dia.hoy .dnum{background:var(--marca);color:#fff}
.cab-dia.festivo:not(.hoy) .dnum{color:#c2185b}
.todo-et{display:flex;align-items:flex-end}
.todo-celda{border-left:1px solid var(--linea);padding:.15rem .2rem .3rem;min-width:0;display:flex;flex-direction:column;gap:2px;border-top:1px solid var(--linea)}
.todo-et{border-top:1px solid var(--linea)}
.todo-celda.hoy{background:#f3f8f6}
.todo-celda.festivo{background:#fff3f6}
.cal-cuerpo{position:relative;height:1152px}
.horas{position:relative}
.hora{height:48px;position:relative}
.hora span{position:absolute;top:-.55em;right:.5rem;font-size:.72rem;color:var(--suave)}
.col{position:relative;border-left:1px solid var(--linea);background-image:repeating-linear-gradient(to bottom,transparent 0,transparent 47px,var(--linea) 47px,var(--linea) 48px)}
.col.hoy{background-color:#f7fbfa}
.col.festivo{background-color:#fff7f9}
.bloque{position:absolute;display:block;overflow:hidden;border-radius:6px;padding:2px 6px;background:var(--col);color:#2b3438;text-decoration:none;font-size:.78rem;line-height:1.25;border:1px solid #fff;border-left:4px solid rgba(0,0,0,.28);border-left-color:color-mix(in srgb,var(--col) 55%,#000);z-index:2}
.bloque:hover{filter:brightness(.92);z-index:4}
.bloque .b-tit{display:block;font-weight:600;overflow:hidden;text-overflow:ellipsis}
.bloque.alerta .b-tit,.linea.alerta .tit,.chip.alerta{color:#a4161a;font-weight:700}
.bloque.alerta{outline:2px solid #a4161a;outline-offset:-2px}
.bloque .b-hora{display:block;font-size:.72rem;opacity:.92;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.bloque.corto{display:flex;gap:.4rem;align-items:baseline;white-space:nowrap}
.bloque.corto .b-tit{display:block;flex:0 1 auto;min-width:0;overflow:hidden;text-overflow:ellipsis}
.bloque.corto .b-hora{display:block;flex:0 99 auto;min-width:0;overflow:hidden;text-overflow:ellipsis}
.ahora{position:absolute;left:0;right:0;height:0;border-top:2px solid #ea4335;z-index:5;margin-top:-1px;pointer-events:none}
.ahora::before{content:"";position:absolute;left:-6px;top:-6px;width:10px;height:10px;border-radius:50%;background:#ea4335}

/* elementos de una línea (todo el día, tareas, plazos y vista mes) */
.chip{display:block;background:var(--col);color:#2b3438;border-radius:5px;padding:1px 6px;margin:1px 0;font-size:.78rem;line-height:1.35;text-decoration:none;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;border-left:4px solid rgba(0,0,0,.28);border-left-color:color-mix(in srgb,var(--col) 55%,#000)}
.chip small{opacity:.85}
.chip.festivo{font-weight:600}
.chip:hover{filter:brightness(.92)}
.chip.vencida{outline:2px solid var(--mal);outline-offset:-1px}
.chip.vencida::before{content:"¡ ";font-weight:700}
.linea{display:flex;align-items:center;gap:.3rem;padding:1px 4px;margin:1px 0;border-radius:5px;font-size:.78rem;line-height:1.35;text-decoration:none;color:var(--texto);white-space:nowrap;overflow:hidden}
.linea:hover{background:#eef3f2}
.linea .tit{overflow:hidden;text-overflow:ellipsis}
.pt{flex:0 0 9px;width:9px;height:9px;border-radius:50%;background:var(--col);box-shadow:0 0 0 1px rgba(0,0,0,.28)}

/* vista mes */
.cal-mes{background:var(--papel);border:1px solid var(--linea);border-radius:var(--radio);overflow:hidden}
.mes-cab{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));border-bottom:1px solid var(--linea)}
.mes-cab div{text-align:center;padding:.4rem 0;font-size:.74rem;text-transform:uppercase;letter-spacing:.06em;color:var(--suave);font-weight:600}
.mes-semana{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));border-bottom:1px solid var(--linea)}
.mes-semana:last-child{border-bottom:0}
.mes-dia{min-height:calc((100vh - var(--alto-barra) - 9rem) / 5);min-height:7.4rem;padding:.2rem .25rem .3rem;border-left:1px solid var(--linea);min-width:0}
.mes-dia:first-child{border-left:0}
.mes-dia.festivo{background:#fff7f9}
.mes-dia.fuera .num{color:#a3a89f}
.mes-dia .num{display:inline-block;min-width:1.7rem;height:1.7rem;line-height:1.7rem;text-align:center;font-size:.82rem;font-weight:600;color:var(--texto);text-decoration:none;border-radius:999px;padding:0 .3rem}
.mes-dia .num:hover{background:#eef3f2}
.nombre-dia{display:none}
.mes-dia.hoy .num{background:var(--marca);color:#fff}
.mas{display:block;font-size:.75rem;color:var(--suave);padding:1px 6px;text-decoration:none;font-weight:600}
.mas:hover{background:#eef3f2;border-radius:5px}

@media (max-width:1000px){
  .gcal{grid-template-columns:minmax(0,1fr)}
  .gcal-izq{position:static;max-height:none;order:2}
  .gcal-main{order:1}
  .cal-scroll{height:calc(100vh - var(--alto-barra) - 7rem)}
  .gcal-barra h1{flex-basis:100%;order:5;margin:.3rem 0 0}
}
@media (max-width:760px){
  .mes-cab{display:none}
  .mes-semana{display:block}
  .mes-dia{border-left:0;min-height:0;border-bottom:1px solid var(--linea)}
  .mes-dia.sin-nada{display:none}
  .mes-dia.hoy.sin-nada{display:block}
  .nombre-dia{display:inline;text-transform:capitalize}
  .cal-cab,.cal-cuerpo{grid-template-columns:40px repeat(7,minmax(88px,1fr))}
  .cal-cab.n1,.cal-cuerpo.n1{grid-template-columns:40px minmax(0,1fr)}
  .hora span{right:.25rem;font-size:.66rem}
}
/* posiciones de las citas en la rejilla (5 minutos = 4px). Generado. */
.t0{top:0px}
.t1{top:4px}
.t2{top:8px}
.t3{top:12px}
.t4{top:16px}
.t5{top:20px}
.t6{top:24px}
.t7{top:28px}
.t8{top:32px}
.t9{top:36px}
.t10{top:40px}
.t11{top:44px}
.t12{top:48px}
.t13{top:52px}
.t14{top:56px}
.t15{top:60px}
.t16{top:64px}
.t17{top:68px}
.t18{top:72px}
.t19{top:76px}
.t20{top:80px}
.t21{top:84px}
.t22{top:88px}
.t23{top:92px}
.t24{top:96px}
.t25{top:100px}
.t26{top:104px}
.t27{top:108px}
.t28{top:112px}
.t29{top:116px}
.t30{top:120px}
.t31{top:124px}
.t32{top:128px}
.t33{top:132px}
.t34{top:136px}
.t35{top:140px}
.t36{top:144px}
.t37{top:148px}
.t38{top:152px}
.t39{top:156px}
.t40{top:160px}
.t41{top:164px}
.t42{top:168px}
.t43{top:172px}
.t44{top:176px}
.t45{top:180px}
.t46{top:184px}
.t47{top:188px}
.t48{top:192px}
.t49{top:196px}
.t50{top:200px}
.t51{top:204px}
.t52{top:208px}
.t53{top:212px}
.t54{top:216px}
.t55{top:220px}
.t56{top:224px}
.t57{top:228px}
.t58{top:232px}
.t59{top:236px}
.t60{top:240px}
.t61{top:244px}
.t62{top:248px}
.t63{top:252px}
.t64{top:256px}
.t65{top:260px}
.t66{top:264px}
.t67{top:268px}
.t68{top:272px}
.t69{top:276px}
.t70{top:280px}
.t71{top:284px}
.t72{top:288px}
.t73{top:292px}
.t74{top:296px}
.t75{top:300px}
.t76{top:304px}
.t77{top:308px}
.t78{top:312px}
.t79{top:316px}
.t80{top:320px}
.t81{top:324px}
.t82{top:328px}
.t83{top:332px}
.t84{top:336px}
.t85{top:340px}
.t86{top:344px}
.t87{top:348px}
.t88{top:352px}
.t89{top:356px}
.t90{top:360px}
.t91{top:364px}
.t92{top:368px}
.t93{top:372px}
.t94{top:376px}
.t95{top:380px}
.t96{top:384px}
.t97{top:388px}
.t98{top:392px}
.t99{top:396px}
.t100{top:400px}
.t101{top:404px}
.t102{top:408px}
.t103{top:412px}
.t104{top:416px}
.t105{top:420px}
.t106{top:424px}
.t107{top:428px}
.t108{top:432px}
.t109{top:436px}
.t110{top:440px}
.t111{top:444px}
.t112{top:448px}
.t113{top:452px}
.t114{top:456px}
.t115{top:460px}
.t116{top:464px}
.t117{top:468px}
.t118{top:472px}
.t119{top:476px}
.t120{top:480px}
.t121{top:484px}
.t122{top:488px}
.t123{top:492px}
.t124{top:496px}
.t125{top:500px}
.t126{top:504px}
.t127{top:508px}
.t128{top:512px}
.t129{top:516px}
.t130{top:520px}
.t131{top:524px}
.t132{top:528px}
.t133{top:532px}
.t134{top:536px}
.t135{top:540px}
.t136{top:544px}
.t137{top:548px}
.t138{top:552px}
.t139{top:556px}
.t140{top:560px}
.t141{top:564px}
.t142{top:568px}
.t143{top:572px}
.t144{top:576px}
.t145{top:580px}
.t146{top:584px}
.t147{top:588px}
.t148{top:592px}
.t149{top:596px}
.t150{top:600px}
.t151{top:604px}
.t152{top:608px}
.t153{top:612px}
.t154{top:616px}
.t155{top:620px}
.t156{top:624px}
.t157{top:628px}
.t158{top:632px}
.t159{top:636px}
.t160{top:640px}
.t161{top:644px}
.t162{top:648px}
.t163{top:652px}
.t164{top:656px}
.t165{top:660px}
.t166{top:664px}
.t167{top:668px}
.t168{top:672px}
.t169{top:676px}
.t170{top:680px}
.t171{top:684px}
.t172{top:688px}
.t173{top:692px}
.t174{top:696px}
.t175{top:700px}
.t176{top:704px}
.t177{top:708px}
.t178{top:712px}
.t179{top:716px}
.t180{top:720px}
.t181{top:724px}
.t182{top:728px}
.t183{top:732px}
.t184{top:736px}
.t185{top:740px}
.t186{top:744px}
.t187{top:748px}
.t188{top:752px}
.t189{top:756px}
.t190{top:760px}
.t191{top:764px}
.t192{top:768px}
.t193{top:772px}
.t194{top:776px}
.t195{top:780px}
.t196{top:784px}
.t197{top:788px}
.t198{top:792px}
.t199{top:796px}
.t200{top:800px}
.t201{top:804px}
.t202{top:808px}
.t203{top:812px}
.t204{top:816px}
.t205{top:820px}
.t206{top:824px}
.t207{top:828px}
.t208{top:832px}
.t209{top:836px}
.t210{top:840px}
.t211{top:844px}
.t212{top:848px}
.t213{top:852px}
.t214{top:856px}
.t215{top:860px}
.t216{top:864px}
.t217{top:868px}
.t218{top:872px}
.t219{top:876px}
.t220{top:880px}
.t221{top:884px}
.t222{top:888px}
.t223{top:892px}
.t224{top:896px}
.t225{top:900px}
.t226{top:904px}
.t227{top:908px}
.t228{top:912px}
.t229{top:916px}
.t230{top:920px}
.t231{top:924px}
.t232{top:928px}
.t233{top:932px}
.t234{top:936px}
.t235{top:940px}
.t236{top:944px}
.t237{top:948px}
.t238{top:952px}
.t239{top:956px}
.t240{top:960px}
.t241{top:964px}
.t242{top:968px}
.t243{top:972px}
.t244{top:976px}
.t245{top:980px}
.t246{top:984px}
.t247{top:988px}
.t248{top:992px}
.t249{top:996px}
.t250{top:1000px}
.t251{top:1004px}
.t252{top:1008px}
.t253{top:1012px}
.t254{top:1016px}
.t255{top:1020px}
.t256{top:1024px}
.t257{top:1028px}
.t258{top:1032px}
.t259{top:1036px}
.t260{top:1040px}
.t261{top:1044px}
.t262{top:1048px}
.t263{top:1052px}
.t264{top:1056px}
.t265{top:1060px}
.t266{top:1064px}
.t267{top:1068px}
.t268{top:1072px}
.t269{top:1076px}
.t270{top:1080px}
.t271{top:1084px}
.t272{top:1088px}
.t273{top:1092px}
.t274{top:1096px}
.t275{top:1100px}
.t276{top:1104px}
.t277{top:1108px}
.t278{top:1112px}
.t279{top:1116px}
.t280{top:1120px}
.t281{top:1124px}
.t282{top:1128px}
.t283{top:1132px}
.t284{top:1136px}
.t285{top:1140px}
.t286{top:1144px}
.t287{top:1148px}
.a1{height:4px}
.a2{height:8px}
.a3{height:12px}
.a4{height:16px}
.a5{height:20px}
.a6{height:24px}
.a7{height:28px}
.a8{height:32px}
.a9{height:36px}
.a10{height:40px}
.a11{height:44px}
.a12{height:48px}
.a13{height:52px}
.a14{height:56px}
.a15{height:60px}
.a16{height:64px}
.a17{height:68px}
.a18{height:72px}
.a19{height:76px}
.a20{height:80px}
.a21{height:84px}
.a22{height:88px}
.a23{height:92px}
.a24{height:96px}
.a25{height:100px}
.a26{height:104px}
.a27{height:108px}
.a28{height:112px}
.a29{height:116px}
.a30{height:120px}
.a31{height:124px}
.a32{height:128px}
.a33{height:132px}
.a34{height:136px}
.a35{height:140px}
.a36{height:144px}
.a37{height:148px}
.a38{height:152px}
.a39{height:156px}
.a40{height:160px}
.a41{height:164px}
.a42{height:168px}
.a43{height:172px}
.a44{height:176px}
.a45{height:180px}
.a46{height:184px}
.a47{height:188px}
.a48{height:192px}
.a49{height:196px}
.a50{height:200px}
.a51{height:204px}
.a52{height:208px}
.a53{height:212px}
.a54{height:216px}
.a55{height:220px}
.a56{height:224px}
.a57{height:228px}
.a58{height:232px}
.a59{height:236px}
.a60{height:240px}
.a61{height:244px}
.a62{height:248px}
.a63{height:252px}
.a64{height:256px}
.a65{height:260px}
.a66{height:264px}
.a67{height:268px}
.a68{height:272px}
.a69{height:276px}
.a70{height:280px}
.a71{height:284px}
.a72{height:288px}
.a73{height:292px}
.a74{height:296px}
.a75{height:300px}
.a76{height:304px}
.a77{height:308px}
.a78{height:312px}
.a79{height:316px}
.a80{height:320px}
.a81{height:324px}
.a82{height:328px}
.a83{height:332px}
.a84{height:336px}
.a85{height:340px}
.a86{height:344px}
.a87{height:348px}
.a88{height:352px}
.a89{height:356px}
.a90{height:360px}
.a91{height:364px}
.a92{height:368px}
.a93{height:372px}
.a94{height:376px}
.a95{height:380px}
.a96{height:384px}
.a97{height:388px}
.a98{height:392px}
.a99{height:396px}
.a100{height:400px}
.a101{height:404px}
.a102{height:408px}
.a103{height:412px}
.a104{height:416px}
.a105{height:420px}
.a106{height:424px}
.a107{height:428px}
.a108{height:432px}
.a109{height:436px}
.a110{height:440px}
.a111{height:444px}
.a112{height:448px}
.a113{height:452px}
.a114{height:456px}
.a115{height:460px}
.a116{height:464px}
.a117{height:468px}
.a118{height:472px}
.a119{height:476px}
.a120{height:480px}
.a121{height:484px}
.a122{height:488px}
.a123{height:492px}
.a124{height:496px}
.a125{height:500px}
.a126{height:504px}
.a127{height:508px}
.a128{height:512px}
.a129{height:516px}
.a130{height:520px}
.a131{height:524px}
.a132{height:528px}
.a133{height:532px}
.a134{height:536px}
.a135{height:540px}
.a136{height:544px}
.a137{height:548px}
.a138{height:552px}
.a139{height:556px}
.a140{height:560px}
.a141{height:564px}
.a142{height:568px}
.a143{height:572px}
.a144{height:576px}
.a145{height:580px}
.a146{height:584px}
.a147{height:588px}
.a148{height:592px}
.a149{height:596px}
.a150{height:600px}
.a151{height:604px}
.a152{height:608px}
.a153{height:612px}
.a154{height:616px}
.a155{height:620px}
.a156{height:624px}
.a157{height:628px}
.a158{height:632px}
.a159{height:636px}
.a160{height:640px}
.a161{height:644px}
.a162{height:648px}
.a163{height:652px}
.a164{height:656px}
.a165{height:660px}
.a166{height:664px}
.a167{height:668px}
.a168{height:672px}
.a169{height:676px}
.a170{height:680px}
.a171{height:684px}
.a172{height:688px}
.a173{height:692px}
.a174{height:696px}
.a175{height:700px}
.a176{height:704px}
.a177{height:708px}
.a178{height:712px}
.a179{height:716px}
.a180{height:720px}
.a181{height:724px}
.a182{height:728px}
.a183{height:732px}
.a184{height:736px}
.a185{height:740px}
.a186{height:744px}
.a187{height:748px}
.a188{height:752px}
.a189{height:756px}
.a190{height:760px}
.a191{height:764px}
.a192{height:768px}
.a193{height:772px}
.a194{height:776px}
.a195{height:780px}
.a196{height:784px}
.a197{height:788px}
.a198{height:792px}
.a199{height:796px}
.a200{height:800px}
.a201{height:804px}
.a202{height:808px}
.a203{height:812px}
.a204{height:816px}
.a205{height:820px}
.a206{height:824px}
.a207{height:828px}
.a208{height:832px}
.a209{height:836px}
.a210{height:840px}
.a211{height:844px}
.a212{height:848px}
.a213{height:852px}
.a214{height:856px}
.a215{height:860px}
.a216{height:864px}
.a217{height:868px}
.a218{height:872px}
.a219{height:876px}
.a220{height:880px}
.a221{height:884px}
.a222{height:888px}
.a223{height:892px}
.a224{height:896px}
.a225{height:900px}
.a226{height:904px}
.a227{height:908px}
.a228{height:912px}
.a229{height:916px}
.a230{height:920px}
.a231{height:924px}
.a232{height:928px}
.a233{height:932px}
.a234{height:936px}
.a235{height:940px}
.a236{height:944px}
.a237{height:948px}
.a238{height:952px}
.a239{height:956px}
.a240{height:960px}
.a241{height:964px}
.a242{height:968px}
.a243{height:972px}
.a244{height:976px}
.a245{height:980px}
.a246{height:984px}
.a247{height:988px}
.a248{height:992px}
.a249{height:996px}
.a250{height:1000px}
.a251{height:1004px}
.a252{height:1008px}
.a253{height:1012px}
.a254{height:1016px}
.a255{height:1020px}
.a256{height:1024px}
.a257{height:1028px}
.a258{height:1032px}
.a259{height:1036px}
.a260{height:1040px}
.a261{height:1044px}
.a262{height:1048px}
.a263{height:1052px}
.a264{height:1056px}
.a265{height:1060px}
.a266{height:1064px}
.a267{height:1068px}
.a268{height:1072px}
.a269{height:1076px}
.a270{height:1080px}
.a271{height:1084px}
.a272{height:1088px}
.a273{height:1092px}
.a274{height:1096px}
.a275{height:1100px}
.a276{height:1104px}
.a277{height:1108px}
.a278{height:1112px}
.a279{height:1116px}
.a280{height:1120px}
.a281{height:1124px}
.a282{height:1128px}
.a283{height:1132px}
.a284{height:1136px}
.a285{height:1140px}
.a286{height:1144px}
.a287{height:1148px}
.a288{height:1152px}
.l0-1{left:calc(0*100%/1 + 1px);width:calc(100%/1 - 3px)}
.l0-2{left:calc(0*100%/2 + 1px);width:calc(100%/2 - 3px)}
.l1-2{left:calc(1*100%/2 + 1px);width:calc(100%/2 - 3px)}
.l0-3{left:calc(0*100%/3 + 1px);width:calc(100%/3 - 3px)}
.l1-3{left:calc(1*100%/3 + 1px);width:calc(100%/3 - 3px)}
.l2-3{left:calc(2*100%/3 + 1px);width:calc(100%/3 - 3px)}
.l0-4{left:calc(0*100%/4 + 1px);width:calc(100%/4 - 3px)}
.l1-4{left:calc(1*100%/4 + 1px);width:calc(100%/4 - 3px)}
.l2-4{left:calc(2*100%/4 + 1px);width:calc(100%/4 - 3px)}
.l3-4{left:calc(3*100%/4 + 1px);width:calc(100%/4 - 3px)}
.l0-5{left:calc(0*100%/5 + 1px);width:calc(100%/5 - 3px)}
.l1-5{left:calc(1*100%/5 + 1px);width:calc(100%/5 - 3px)}
.l2-5{left:calc(2*100%/5 + 1px);width:calc(100%/5 - 3px)}
.l3-5{left:calc(3*100%/5 + 1px);width:calc(100%/5 - 3px)}
.l4-5{left:calc(4*100%/5 + 1px);width:calc(100%/5 - 3px)}
.l0-6{left:calc(0*100%/6 + 1px);width:calc(100%/6 - 3px)}
.l1-6{left:calc(1*100%/6 + 1px);width:calc(100%/6 - 3px)}
.l2-6{left:calc(2*100%/6 + 1px);width:calc(100%/6 - 3px)}
.l3-6{left:calc(3*100%/6 + 1px);width:calc(100%/6 - 3px)}
.l4-6{left:calc(4*100%/6 + 1px);width:calc(100%/6 - 3px)}
.l5-6{left:calc(5*100%/6 + 1px);width:calc(100%/6 - 3px)}
.fila-dos{display:grid;gap:1rem;grid-template-columns:repeat(auto-fit,minmax(280px,1fr))}
.boton.grande{padding:.7rem 1.2rem;font-size:1.02rem}
.cuando-mal{color:var(--mal);font-weight:700}
.cuando-hoy{color:var(--aviso);font-weight:700}
.cal-herramientas{display:flex;gap:.6rem;flex-wrap:wrap;align-items:center;margin:0 0 .9rem}
.aviso-tarjeta{border-color:#ecd08d;background:#fffaf0}
.tarjeta>h2:first-child{margin-top:.1rem}

/* crear pulsando en el calendario */
.crear-aqui{cursor:pointer}
.rapido{position:fixed;z-index:60;min-width:13rem;background:#fff;border:1px solid var(--linea);border-radius:10px;box-shadow:0 8px 28px rgba(0,0,0,.22);padding:.3rem 0}
.rapido[hidden]{display:none}
.rapido-cuando{margin:0;padding:.35rem .9rem .45rem;font-size:.8rem;font-weight:600;color:var(--suave);border-bottom:1px solid var(--linea)}
.rapido a{display:flex;align-items:center;gap:.6rem;padding:.5rem .9rem;color:var(--texto);text-decoration:none;font-size:.92rem}
.rapido a:hover,.rapido a:focus-visible{background:#eef3f2}
.lista-simple{list-style:none;margin:0;padding:0}.lista-simple li{padding:.45rem 0;border-bottom:1px solid #e8e6de}.lista-simple li:last-child{border-bottom:0}
.bloque.recitar .b-tit,.linea.recitar .tit,.chip.recitar{color:#8a4b00;font-weight:700}.bloque.recitar{outline:2px dashed #d97706;outline-offset:-2px;background-image:repeating-linear-gradient(135deg,rgba(217,119,6,.14) 0 6px,transparent 6px 12px)}.linea.recitar .pt{outline:2px solid #d97706}
.menu .item{position:relative}.menu .item .globo{position:absolute;left:1.7rem;top:3px;min-width:1.1rem;height:1.1rem;padding:0 .25rem;border-radius:999px;background:#c62828;color:#fff;font-size:.7rem;font-weight:700;line-height:1.1rem;text-align:center;box-sizing:border-box}
.buscando-hueco{display:flex;flex-wrap:wrap;align-items:center;gap:.6rem;margin:0 0 .6rem;padding:.55rem .8rem;border-radius:10px;background:#fff4dc;border:1px solid #e6c36a;color:#5b4300}.buscando-hueco>span{flex:1 1 18rem}

/* fichaje */
.fichaje-estado{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:1rem}
.fichaje-estado .estado-texto{margin:0;font-size:1.15rem}
.fichaje-estado.dentro{border-left:6px solid var(--ok)}.fichaje-estado.olvido{border-left:6px solid var(--mal);display:block}
.punto-vivo{display:inline-block;width:.7rem;height:.7rem;border-radius:50%;background:var(--ok);margin-right:.3rem}
.tramo{display:inline-block;margin:.1rem .5rem .1rem 0;padding:.1rem .55rem;border-radius:.5rem;background:#eef1ee;font-variant-numeric:tabular-nums}
.tramo.manual{background:var(--aviso-bg);color:var(--aviso)}
.tramo-edicion{display:block;margin:.2rem 0}.tramo-edicion summary{cursor:pointer}

/* Presupuesto: tabla de suplidos y lista de servicios */
.sup-tabla input{width:100%}
.sup-tabla td{padding:.2rem .3rem}
details.servicio{border-top:1px solid var(--linea,#c9c6bb);padding:.5rem 0}
details.servicio summary{cursor:pointer}
details.servicio form{margin-top:.6rem}

/* ---------- panel de Dirección ---------- */
.grafico{width:100%;height:auto;max-height:280px;display:block}
.grafico .rejilla-y{stroke:var(--linea);stroke-width:1}
.grafico .eje{fill:var(--suave);font-size:11px}
.grafico .b-entra,.muestra.entra{fill:var(--marca);background:var(--marca)}
.grafico .b-sale,.muestra.sale{fill:var(--acento);background:var(--acento)}
.leyenda{display:flex;gap:1rem;align-items:center;font-size:.85rem;color:var(--suave);margin:.4rem 0 1rem}
.muestra{display:inline-block;width:.8rem;height:.8rem;border-radius:2px;margin-right:.3rem}

/* Caja */
.recuento td{padding-top:.25rem;padding-bottom:.25rem}
.recuento input.unidades{width:6rem;text-align:right}
.recuento label{margin:0;font-weight:400}

.clasificar{display:flex;flex-wrap:wrap;gap:.35rem;align-items:center}
.clasificar select{width:auto;max-width:15rem}
