@import url("/fonts.css");
/* Base visual exacta de agenda/demo/agenda-demo.html. */

/* Concepto: tarjeta de cita. Columna estrecha para la clienta, panel amplio para la dueña.
   Blanco y el color del logo (los colores de marca los pone CONFIG); Bodoni para la marca y los titulares, Outfit para todo lo demás. */
:root {
  --bg: #ffffff;
  --surface: #ffffff;
  --sunk: #fbf0f6;
  --ink: #3b2132;
  --muted: #86677a;
  --line: #f0d9e6;
  --accent: #b0508d;
  --accent-ink: #ffffff;
  --accent-soft: #fbe6f2;
  --logo: #c266a0;
  --ok: #2e6a4e;
  --ok-soft: #e1efe7;
  --warn: #8f5a10;
  --warn-soft: #f6ead6;
  --danger: #a03a3a;
  --danger-soft: #f6e1df;
  --info: #3c5f86;
  --info-soft: #e2eaf4;
  --yellow: #e2b203;
  --yellow-soft: #fdf3c4;
  --yellow-ink: #5a4600;
  --orange: #d9660b;
  --orange-soft: #fde3cc;
  --orange-ink: #94420a;
  --gris-soft: #ececec;
  --gris-ink: #555555;
  --p1: #c266a0;
  --p2: #2f6d70;
  --p3: #8a6a2a;
  --p4: #55558d;
  --p5: #5f7531;
  --raised: #ffffff;
  --shadow: 0 1px 2px rgb(120 40 90 / 0.08), 0 4px 14px rgb(120 40 90 / 0.07);
  --f-display: "Bodoni Moda", "Didot", "Bodoni 72", Georgia, serif;
  --f-body: "Outfit", "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --r: 12px;
  color-scheme: light;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 15px/1.5 var(--f-body);
  -webkit-font-smoothing: antialiased;
}
button,
input,
select {
  font: inherit;
  color: inherit;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: not-allowed;
}
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.wrap {
  max-width: 1120px;
  margin-inline: auto;
  padding-inline: 16px;
  padding-block: 10px 40px;
}
.estrecho {
  max-width: 620px;
  margin-inline: auto;
}
.num {
  font-variant-numeric: tabular-nums;
}
.muted {
  color: var(--muted);
}
.small {
  font-size: 13px;
}
h1,
h2,
h3 {
  margin: 0;
  font-weight: 500;
  text-wrap: balance;
}
h2 {
  font-family: var(--f-display);
  font-size: 26px;
  line-height: 1.15;
  letter-spacing: -0.01em;
}
h3 {
  font-size: 15px;
  font-weight: 600;
}
p {
  margin: 0;
}
.eyebrow {
  font-size: 11.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 500;
}

/* Cabecera */
.barra-demo {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  margin-top: 6px;
  background: var(--sunk);
  border-radius: 12px;
}
.barra-demo .aviso {
  font-size: 12px;
  letter-spacing: 0.03em;
  color: var(--warn);
  background: var(--warn-soft);
  border-radius: 99px;
  padding: 3px 12px;
}
.barra-demo .vistas {
  flex: 1 1 220px;
  max-width: 340px;
}
.top {
  position: sticky;
  top: env(safe-area-inset-top, 0px);
  z-index: 20;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-block: 10px;
  border-bottom: 1px solid var(--line);
}
.marca {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
  min-width: 0;
}
.marca-nombre {
  font-family: var(--f-display);
  font-size: 22px;
  font-weight: 500;
  letter-spacing: -0.01em;
}
.marca-nombre em {
  font-style: italic;
  color: var(--accent);
}
.marca-logo {
  display: block;
  align-self: flex-start;
  height: 72px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
}
.marca-sub {
  font-size: 12px;
  color: var(--muted);
  margin-top: 3px;
}
.reset {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
}
/* Menú de secciones del panel, a la derecha del logo */
.menu {
  position: relative;
}
.menu summary {
  list-style: none;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 12px;
  padding: 10px 14px;
  font-weight: 500;
  cursor: pointer;
  min-height: 44px;
  box-shadow: var(--shadow);
}
.menu summary::-webkit-details-marker {
  display: none;
}
.menu summary svg {
  width: 18px;
  height: 18px;
  flex: none;
}
.menu[open] summary {
  border-color: var(--accent);
  color: var(--accent);
}
.menu-lista {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  z-index: 30;
  display: grid;
  gap: 2px;
  min-width: 200px;
  padding: 6px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--shadow);
}
.menu-lista button {
  border: 0;
  background: transparent;
  text-align: left;
  padding: 12px 14px;
  border-radius: 8px;
  font-weight: 500;
  color: var(--ink);
}
.menu-lista button:hover {
  background: var(--sunk);
}
.menu-lista button[aria-current="true"] {
  background: var(--accent-soft);
  color: var(--accent);
}
.seg {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  background: var(--sunk);
  border-radius: 12px;
  padding: 3px;
  gap: 2px;
}
.seg button {
  border: 0;
  background: transparent;
  padding: 8px 10px;
  border-radius: 9px;
  font-weight: 500;
  color: var(--muted);
  white-space: nowrap;
}
.seg button[aria-pressed="true"] {
  background: var(--raised);
  color: var(--ink);
  box-shadow: var(--shadow);
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 10px;
  padding: 8px 14px;
  font-weight: 500;
  line-height: 1.2;
}
.btn:hover {
  border-color: var(--muted);
}
.btn.primario {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}
.btn.primario:disabled {
  opacity: 0.45;
}
.btn.peligro {
  color: var(--danger);
  border-color: var(--danger);
}
.btn.peligro.lleno {
  background: var(--danger);
  color: var(--surface);
}
.btn.mini {
  padding: 5px 10px;
  font-size: 13px;
  border-radius: 8px;
}
.btn.texto {
  border-color: transparent;
  background: transparent;
  padding-inline: 6px;
  color: var(--accent);
}
.btn.ancho {
  width: 100%;
  padding-block: 12px;
  font-size: 16px;
}

/* Vista clienta */
.hero {
  padding-block: 22px 6px;
  display: grid;
  gap: 6px;
}
.hero h1 {
  font-family: var(--f-display);
  font-size: 34px;
  line-height: 1.05;
  letter-spacing: -0.015em;
  font-weight: 500;
}
.hero h1 em {
  color: var(--accent);
}
.hero p {
  color: var(--muted);
  max-width: 52ch;
}
.pasos {
  display: flex;
  gap: 6px;
  margin-block: 18px 14px;
  list-style: none;
  padding: 0;
}
.pasos li {
  flex: 1;
  min-width: 0;
  font-size: 12px;
  color: var(--muted);
  padding-top: 8px;
  border-top: 2px solid var(--line);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.pasos li.hecho {
  border-color: var(--accent);
  color: var(--ink);
}
.pasos li.actual {
  border-color: var(--accent);
  color: var(--accent);
  font-weight: 600;
}
.grupo {
  margin-block: 16px 0;
  display: grid;
  gap: 8px;
}
.grupo > .eyebrow {
  margin-bottom: 2px;
}
.trat {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 4px 12px;
  text-align: left;
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 12px 14px;
}
.trat:hover {
  border-color: var(--muted);
}
.trat[aria-pressed="true"] {
  border-color: var(--accent);
  background: var(--accent-soft);
}
.trat-nombre {
  font-weight: 500;
  min-width: 0;
}
.trat-meta {
  grid-column: 1;
  font-size: 13px;
  color: var(--muted);
}
.trat-desc {
  grid-column: 1;
  font-size: 12.5px;
  line-height: 1.4;
  color: var(--muted);
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.trat[aria-pressed="true"] .trat-desc {
  -webkit-line-clamp: unset;
  display: block;
}
.trat .marca-check {
  grid-row: 1 / span 3;
  grid-column: 2;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 1.5px solid var(--line);
  display: grid;
  place-items: center;
}
.trat[aria-pressed="true"] .marca-check {
  background: var(--accent);
  border-color: var(--accent);
}
.trat[aria-pressed="true"] .marca-check::after {
  content: "";
  width: 9px;
  height: 5px;
  border: 2px solid var(--accent-ink);
  border-top: 0;
  border-right: 0;
  transform: translateY(-1px) rotate(-45deg);
}
.barra {
  position: sticky;
  bottom: 0;
  margin-top: 18px;
  padding-bottom: calc(10px + env(safe-area-inset-bottom, 0px));
  padding-top: 10px;
  background: linear-gradient(to bottom, transparent, var(--bg) 30%);
}
.barra-in {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 10px 10px 10px 14px;
  box-shadow: var(--shadow);
}
.barra-in .small {
  min-width: 0;
  display: flex;
  flex-direction: column;
}
.barra-elegido {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.resumen {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  justify-content: space-between;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 12px 14px;
}
.resumen > div {
  min-width: 0;
}
.asap {
  margin-block: 14px 4px;
}
.dias {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-block: 4px 10px;
  scroll-snap-type: x proximity;
  scrollbar-width: thin;
}
.dia {
  flex: 0 0 62px;
  scroll-snap-align: start;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 12px;
  padding: 8px 4px;
  display: grid;
  justify-items: center;
  gap: 0;
  line-height: 1.15;
}
.dia .d1 {
  font-size: 12px;
  color: var(--muted);
  text-transform: capitalize;
}
.dia .d2 {
  font-size: 20px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}
.dia .d3 {
  font-size: 12px;
  color: var(--muted);
}
.dia[aria-pressed="true"] {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}
.dia[aria-pressed="true"] .d1,
.dia[aria-pressed="true"] .d3 {
  color: var(--accent-ink);
}
.horas {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(74px, 1fr));
  gap: 8px;
}
.hora {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 10px;
  padding: 9px 4px;
  font-variant-numeric: tabular-nums;
  font-weight: 500;
}
.hora:hover {
  border-color: var(--accent);
}
.hora[aria-pressed="true"] {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}
.franja {
  margin-top: 14px;
  display: grid;
  gap: 8px;
}
.form {
  display: grid;
  gap: 14px;
  margin-top: 14px;
}
.campo {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 5px;
  min-width: 0;
}
.campo label {
  font-size: 13px;
  font-weight: 500;
}
.campo input {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 10px;
  padding: 11px 12px;
  font-size: 16px;
  width: 100%;
}
.campo input[aria-invalid="true"] {
  border-color: var(--danger);
}
.error {
  font-size: 13px;
  color: var(--danger);
}
.nota {
  font-size: 13px;
  color: var(--muted);
}
.caja-aviso {
  background: var(--warn-soft);
  color: var(--warn);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 14px;
}
.confirmada {
  margin-top: 22px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 22px 18px;
  display: grid;
  gap: 14px;
  box-shadow: var(--shadow);
}
.sello {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--ok-soft);
  display: grid;
  place-items: center;
}
.sello::after {
  content: "";
  width: 16px;
  height: 9px;
  border: 2.5px solid var(--ok);
  border-top: 0;
  border-right: 0;
  transform: translateY(-2px) rotate(-45deg);
}
.confirmada h2 {
  font-size: 28px;
}
.dl {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 6px 14px;
  margin: 0;
}
.dl dt {
  color: var(--muted);
  font-size: 13px;
  padding-top: 1px;
}
.dl dd {
  margin: 0;
  min-width: 0;
}
.acciones {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

/* Panel */
.panel-cab {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 16px;
  align-items: end;
  justify-content: space-between;
  padding-block: 18px 12px;
}
.tabs {
  max-width: 520px;
  width: 100%;
}
.nav-fecha {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  margin-block: 6px 12px;
}
.nav-fecha .titulo {
  font-weight: 600;
  min-width: 0;
  text-transform: none;
}
.flecha {
  width: 34px;
  height: 34px;
  padding: 0;
  border-radius: 50%;
}
.lista-citas {
  display: grid;
  gap: 8px;
}
.cita {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 4px 12px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--pc, var(--line));
  border-radius: var(--r);
  padding: 11px 12px;
}
.cita.cancelada {
  opacity: 0.55;
}
.cita.cancelada .c-trat {
  text-decoration: line-through;
}
.c-hora {
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}
.c-hora b {
  display: block;
  font-size: 16px;
  font-weight: 600;
}
.c-hora span {
  font-size: 12px;
  color: var(--muted);
}
.c-cuerpo {
  min-width: 0;
  display: grid;
  gap: 3px;
}
.c-trat {
  font-weight: 500;
}
.c-pie {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  align-items: center;
  font-size: 13px;
  color: var(--muted);
}
.c-acc {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: flex-end;
}
.confirmar {
  grid-column: 1 / -1;
  background: var(--danger-soft);
  border-radius: 10px;
  padding: 10px 12px;
  display: grid;
  gap: 8px;
  font-size: 14px;
}
.chip-p {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  color: var(--ink);
}
.chip-p::before {
  content: "";
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--pc, var(--muted));
}
.pill {
  display: inline-flex;
  align-items: center;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.03em;
  border-radius: 99px;
  padding: 2px 9px;
  white-space: nowrap;
}
.pill.web {
  background: var(--info-soft);
  color: var(--info);
}
.pill.ej {
  background: var(--sunk);
  color: var(--muted);
  font-weight: 500;
}
.pill.nueva {
  background: var(--info-soft);
  color: var(--info);
}
.pill.fidelizar {
  background: var(--ok-soft);
  color: var(--ok);
}
.pill.dormida {
  background: var(--orange-soft);
  color: var(--orange-ink);
}
.pill.pronto {
  background: var(--yellow-soft);
  color: var(--yellow-ink);
}
.pill.recuperar {
  background: var(--danger-soft);
  color: var(--danger);
}
.vacio {
  background: var(--surface);
  border: 1px dashed var(--line);
  border-radius: var(--r);
  padding: 18px;
  color: var(--muted);
  text-align: center;
}
.resumen-dia {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 10px;
}

/* Agenda mes */
.mes {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 4px;
}
.mes .cab {
  font-size: 11px;
  text-align: center;
  color: var(--muted);
  letter-spacing: 0.08em;
  padding-bottom: 2px;
}
.celda {
  min-height: 58px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 8px;
  padding: 5px;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}
.celda.fuera {
  opacity: 0.4;
}
.celda.hoy {
  border-color: var(--accent);
}
.celda.hoy .cn {
  color: var(--accent);
  font-weight: 700;
}
.celda .cn {
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}
.puntos {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
}
.puntos i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--pc);
}
.celda .cc {
  font-size: 11px;
  color: var(--muted);
  margin-top: auto;
}
@media (min-width: 700px) {
  .celda {
    min-height: 86px;
    padding: 7px;
  }
}
/* Rejilla de agenda (Hoy, Día, Semana): eje de horas fijo a la izquierda, cabeceras fijas arriba,
   una columna por persona (o por día). Gris = fuera de turno; claro = libre (se toca); rayado = bloqueado. */
:root {
  --rej-fuera: var(--sunk);
  --rej-libre: var(--surface);
}
.quien {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}
.quien .filtro {
  min-height: 40px;
}
.quien .punto {
  width: 10px;
  height: 10px;
}
.rej-env {
  overflow: auto;
  max-width: 100%;
  max-height: max(380px, calc(100vh - 170px));
  max-height: max(380px, calc(100dvh - 170px));
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: var(--surface);
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}
.rej {
  display: flex;
  min-width: 100%;
  width: calc(48px + var(--n) * var(--cmin));
}
.rej-eje {
  position: sticky;
  left: 0;
  z-index: 8;
  flex: 0 0 48px;
  background: var(--surface);
  border-right: 1px solid var(--line);
}
.rej-esq,
.rej-cab {
  height: 56px;
  position: sticky;
  top: 0;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}
.rej-esq {
  z-index: 2;
}
.rej-eje-cuerpo {
  position: relative;
}
.rej-eje-cuerpo span {
  position: absolute;
  right: 6px;
  font-size: 11.5px;
  line-height: 1;
  padding-top: 3px;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.rej-eje-cuerpo span.media {
  color: var(--muted);
  font-size: 10.5px;
}
.rej-eje-cuerpo .ahora-marca {
  right: 2px;
  left: 2px;
  text-align: center;
  padding: 2px 0;
  border-radius: 4px;
  background: var(--danger);
  color: var(--surface);
  font-weight: 600;
  transform: translateY(-50%);
  z-index: 2;
}
.rej-col {
  flex: 1 1 0;
  min-width: var(--cmin);
  border-right: 1px solid var(--line);
}
.rej-col:last-child {
  border-right: 0;
}
.rej-cab {
  z-index: 6;
  padding: 7px 8px;
  display: grid;
  align-content: center;
  gap: 2px;
  overflow: hidden;
}
.rej-col.hoy .rej-cab {
  box-shadow: inset 0 -2px 0 var(--accent);
}
.cab-l1 {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  font-size: 14px;
  min-width: 0;
}
.cab-l1 b {
  font-weight: 600;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.cab-l1 .n {
  margin-left: auto;
  font-weight: 400;
  font-size: 12px;
  color: var(--muted);
}
.cab-l2 {
  font-size: 11.5px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
button.cab-dia {
  all: unset;
  box-sizing: border-box;
  cursor: pointer;
  display: grid;
  gap: 2px;
  width: 100%;
  height: 100%;
  align-content: center;
}
button.cab-dia:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
  border-radius: 6px;
}
.rej-col.hoy .cab-l1 {
  color: var(--accent);
}
.cab-carriles {
  display: flex;
  gap: 2px;
}
.cab-carriles i {
  flex: 1;
  height: 3px;
  border-radius: 2px;
  background: var(--pc);
}
.carriles {
  display: flex;
}
.carril {
  position: relative;
  flex: 1 1 0;
  min-width: 0;
  background: var(--rej-fuera);
  container-type: inline-size;
}
.carril + .carril {
  border-left: 1px dashed var(--line);
}
.lineas {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  background-image:
    linear-gradient(to bottom, var(--line) 1px, transparent 1px),
    linear-gradient(
      to bottom,
      color-mix(in srgb, var(--line) 55%, transparent) 1px,
      transparent 1px
    );
  background-size:
    100% 96px,
    100% var(--fila, 24px);
}
.libre {
  position: absolute;
  left: 0;
  right: 0;
  z-index: 0;
  border: 0;
  padding: 3px 6px;
  margin: 0;
  text-align: left;
  background: var(--rej-libre);
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.2;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
  overflow: hidden;
  border-radius: 0;
}
.libre:hover {
  background: color-mix(in srgb, var(--accent) 7%, var(--rej-libre));
}
.libre:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
  z-index: 3;
}
.libre-txt {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  position: relative;
  z-index: 2;
}
.fantasma {
  display: none;
  position: absolute;
  left: 3px;
  right: 3px;
  height: 24px;
  border: 1.5px dashed var(--accent);
  border-radius: 6px;
  color: var(--accent);
  font-weight: 600;
  align-items: center;
  padding-left: 6px;
  background: var(--accent-soft);
  z-index: 2;
  pointer-events: none;
}
@media (hover: hover) {
  .libre:hover .fantasma {
    display: flex;
  }
}
.bloque-cita,
.bloqueo {
  position: absolute;
  left: 3px;
  right: 3px;
  z-index: 2;
  border-radius: 7px;
  padding: 3px 6px;
  text-align: left;
  overflow: hidden;
  font-size: 12px;
  line-height: 1.25;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: stretch;
  gap: 1px;
  min-height: 18px;
}
.bloque-cita {
  border: 0;
  border-left: 4px solid var(--pc);
  background: color-mix(in srgb, var(--pc) 17%, var(--surface));
  color: var(--ink);
  box-shadow: 0 1px 0 color-mix(in srgb, var(--pc) 25%, transparent);
}
.bloque-cita:hover {
  background: color-mix(in srgb, var(--pc) 26%, var(--surface));
}
.bloque-cita b,
.bloqueo b {
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-variant-numeric: tabular-nums;
}
.bloque-cita span,
.bloqueo span {
  color: var(--muted);
  font-size: 11.5px;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.bloque-cita.corta span {
  display: none;
}
.bloque-cita .web {
  color: var(--info);
  font-weight: 600;
}
.bloqueo {
  border: 1px solid color-mix(in srgb, var(--muted) 45%, transparent);
  color: var(--muted);
  background:
    repeating-linear-gradient(
      135deg,
      color-mix(in srgb, var(--muted) 20%, transparent) 0 5px,
      transparent 5px 10px
    ),
    var(--rej-fuera);
}
.bloqueo b {
  color: var(--ink);
}
.raya-ahora {
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--danger);
  z-index: 4;
  pointer-events: none;
  transform: translateY(-1px);
}
.raya-ahora::before {
  content: "";
  position: absolute;
  left: -1px;
  top: -3px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--danger);
}
/* Carriles estrechos (semana con todo el equipo): hora y nombre en dos líneas, sin detalle */
@container (max-width:100px) {
  .bloque-cita b,
  .bloqueo b {
    white-space: normal;
    overflow-wrap: anywhere;
    text-overflow: clip;
  }
  .bloque-cita span,
  .bloqueo span,
  .libre-dur {
    display: none;
  }
  .bloque-cita,
  .bloqueo {
    padding: 3px 4px;
    font-size: 11.5px;
  }
  .libre {
    padding: 3px 4px;
  }
}
.leyenda {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 14px;
  font-size: 12.5px;
  color: var(--muted);
  margin-top: 8px;
  align-items: center;
}
.leyenda > span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.sw {
  width: 14px;
  height: 14px;
  border-radius: 4px;
  border: 1px solid var(--line);
  display: inline-block;
}
.sw.libre-sw {
  background: var(--rej-libre);
}
.sw.fuera-sw {
  background: var(--rej-fuera);
}
.sw.bloq-sw {
  background:
    repeating-linear-gradient(
      135deg,
      color-mix(in srgb, var(--muted) 35%, transparent) 0 3px,
      transparent 3px 6px
    ),
    var(--rej-fuera);
}
.sw.cita-sw {
  background: color-mix(in srgb, var(--p1) 22%, var(--surface));
  border-left: 3px solid var(--p1);
}
.campo-tit {
  font-size: 13px;
  font-weight: 500;
}
.pill.activo {
  background: var(--ok-soft);
  color: var(--ok);
}
.cat-acc {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  margin-top: 10px;
  min-width: 0;
}
.cat-acc[open] {
  border-color: var(--muted);
}
.cat-acc > summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 4px 10px;
  padding: 14px 40px 14px 16px;
  min-height: 54px;
  position: relative;
}
.cat-acc > summary::-webkit-details-marker {
  display: none;
}
.cat-acc > summary::after {
  content: "";
  position: absolute;
  right: 18px;
  top: 22px;
  width: 9px;
  height: 9px;
  border: solid var(--muted);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
  transition: transform 0.15s;
}
.cat-acc[open] > summary::after {
  transform: rotate(-135deg);
  top: 26px;
}
.cat-nombre {
  font-family: var(--f-display);
  font-size: 20px;
  line-height: 1.1;
}
.cat-n {
  font-size: 13px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}
.cat-n b {
  color: var(--accent);
  font-weight: 600;
}
.cat-acc .grupo {
  margin: 0;
  padding: 0 10px 10px;
}
.elegidos {
  margin-top: 12px;
  display: grid;
  gap: 6px;
}
.persona-aj .p-cuerpo {
  display: grid;
  gap: 12px;
  padding: 14px;
  border-top: 1px solid var(--line);
  min-width: 0;
}
/* Seguimiento de clientas */
.seg-resumen {
  display: grid;
  gap: 2px;
  font-size: 14.5px;
}
.seg-resumen .toca {
  color: var(--warn);
  font-weight: 600;
}
.k-form {
  display: grid;
  gap: 12px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 12px;
  min-width: 0;
}
.k-form .campo input {
  font-size: 16px;
}
.k-form .seg button {
  min-height: 42px;
}
.k-hist {
  display: grid;
  gap: 0;
}
.k-hist > div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 2px 8px;
  padding-block: 8px;
  border-top: 1px solid var(--line);
  align-items: start;
}
.k-hist > div:first-child {
  border-top: 0;
}
.k-hist .k-l1 {
  font-size: 14px;
}
.btn.wa {
  display: inline-flex;
  margin-top: 8px;
  text-decoration: none;
  color: var(--accent);
  border-color: var(--accent);
}
.k-conf {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  justify-content: flex-end;
}
.k-hist .k-l2 {
  grid-column: 1;
  font-size: 13px;
  color: var(--muted);
}
.k-hist .x {
  grid-row: 1 / span 2;
  grid-column: 2;
  width: 40px;
  height: 40px;
}
.contactar {
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--warn);
  border-radius: var(--r);
  padding: 12px 14px;
  margin-top: 14px;
  display: grid;
  gap: 8px;
}
.contactar h3 {
  font-size: 15px;
}
.contactar-fila {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  align-items: center;
  justify-content: space-between;
  padding-top: 8px;
  border-top: 1px solid var(--line);
}
.contactar-fila:first-of-type {
  border-top: 0;
  padding-top: 0;
}
.contactar-fila > div {
  min-width: 0;
  flex: 1 1 200px;
}
.cita-para {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
  justify-content: space-between;
  background: var(--accent-soft);
  border: 1px solid var(--accent);
  border-radius: 10px;
  padding: 10px 12px;
  margin-bottom: 10px;
  font-size: 14px;
}
/* Estados con su punto de color: Nueva azul, Fidelizar verde, Le toca pronto amarillo, En riesgo naranja, Perdida rojo */
.pill.estado::before,
.punto-e,
.motivo::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex: none;
  background: var(--dot, var(--muted));
}
.pill.estado::before {
  margin-right: 6px;
}
.pill.estado.nueva,
.e-nueva,
.m-nueva {
  --dot: var(--info);
}
.pill.estado.fidelizar,
.e-fidelizar {
  --dot: var(--ok);
}
.pill.estado.pronto,
.e-pronto,
.m-pronto {
  --dot: var(--yellow);
}
.pill.estado.dormida,
.e-dormida,
.m-dormida {
  --dot: var(--orange);
}
.pill.estado.recuperar,
.e-recuperar,
.m-recuperar {
  --dot: var(--danger);
}
.m-seguimiento,
.m-cumple {
  --dot: var(--accent);
}
.motivo {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
  line-height: 1.3;
}
.motivo.m-pronto {
  background: var(--yellow-soft);
  color: var(--yellow-ink);
  border-radius: 99px;
  padding: 1px 9px 1px 7px;
  font-weight: 500;
}
/* «Hoy toca escribir a…», recomendaciones, cumpleaños y recuperadas */
.contactar.escribir {
  border-left-color: var(--accent);
}
.fila-acc {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  align-items: center;
}
.fila-acc .btn.wa,
.reco-acc .btn.wa {
  margin-top: 0;
}
.reco {
  background: var(--accent-soft);
}
.reco-item {
  display: grid;
  gap: 8px;
}
.reco-item + .reco-item {
  border-top: 1px solid var(--line);
  padding-top: 10px;
}
.reco-linea {
  font-weight: 500;
}
.reco-acc {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}
.cumple-campo {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
  padding: 10px 14px;
}
.cumple-campo .nota,
.cumple-campo .error {
  flex-basis: 100%;
}
.cumple-sel {
  display: flex;
  gap: 6px;
  min-width: 0;
  flex-wrap: wrap;
}
.cumple-sel select {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 10px;
  padding: 9px 10px;
  font-size: 16px;
  min-height: 44px;
  min-width: 0;
}
.cumple-sel select[aria-invalid="true"] {
  border-color: var(--danger);
}
.recup {
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--ok);
  border-radius: var(--r);
  padding: 10px 14px;
  margin-bottom: 12px;
  display: grid;
  gap: 2px;
}
.recup-n {
  font-size: 16px;
}
.cli-herr {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
  margin-bottom: 12px;
  min-width: 0;
}
.cli-herr .buscar {
  margin-bottom: 0;
  flex: 1 1 220px;
  min-height: 44px;
}
.sub-menu {
  margin-bottom: 12px;
}
.k-resumen {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 10px;
  align-items: center;
  font-weight: 500;
}
/* «No vino», «No escribir», citas terminadas sin próxima cita */
.pill.noesc {
  background: var(--gris-soft);
  color: var(--gris-ink);
}
.pill.nv {
  background: var(--danger-soft);
  color: var(--danger);
}
.m-novino {
  --dot: var(--danger);
}
.bloque-cita.novino {
  background:
    repeating-linear-gradient(
      135deg,
      color-mix(in srgb, var(--danger) 10%, transparent) 0 6px,
      transparent 6px 12px
    ),
    var(--surface);
  border-left-color: var(--danger);
}
.bloque-cita.novino b {
  text-decoration: line-through;
  color: var(--muted);
}
.bloque-cita .nv {
  color: var(--danger);
  font-weight: 600;
  font-style: normal;
}
.hist .novino {
  color: var(--muted);
}
.caja-novino {
  background: var(--danger-soft);
  color: var(--danger);
  border-radius: 10px;
  padding: 8px 12px;
  font-size: 14px;
  margin-bottom: 8px;
}
.no-escribir {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
  justify-content: flex-end;
}
.cli-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  justify-content: flex-end;
}
.contactar.terminadas {
  border-left-color: var(--ok);
  margin: 0 0 10px;
}
.recup-hoy {
  margin: -4px 0 8px;
}
.recup-hoy .btn {
  padding-left: 0;
}
/* Menús desplegables (secciones, filtro de Clientes y apartados de Ajustes) */
.menu-flecha {
  font-size: 12px;
  opacity: 0.7;
}
.menu summary .n {
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  font-weight: 400;
}
.menu-lista {
  max-width: calc(100vw - 32px);
}
.menu-lista button {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
}
.menu-lista .n {
  margin-left: auto;
  padding-left: 12px;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  font-weight: 400;
}
.menu.izq .menu-lista {
  left: 0;
  right: auto;
}
/* Cierres, festivos y vacaciones */
.carril-aviso {
  position: absolute;
  left: 4px;
  right: 4px;
  top: 8px;
  z-index: 3;
  text-align: center;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  background:
    repeating-linear-gradient(
      135deg,
      color-mix(in srgb, var(--muted) 16%, transparent) 0 5px,
      transparent 5px 10px
    ),
    var(--surface);
  border: 1px dashed var(--line);
  border-radius: 8px;
  padding: 6px 4px;
  line-height: 1.25;
}
.rej-col.cerrada .cab-l2 {
  color: var(--danger);
}
.celda .cerr {
  font-size: 10.5px;
  color: var(--danger);
  font-weight: 600;
  line-height: 1.1;
}
.dia.cerrado {
  opacity: 0.55;
  border-style: dashed;
  cursor: not-allowed;
}
.dia.cerrado .d3 {
  color: var(--danger);
  font-weight: 600;
}
.hero .horario-web {
  font-size: 13px;
  color: var(--muted);
  display: grid;
  gap: 1px;
}
.hero .horario-web b {
  color: var(--ink);
  font-weight: 500;
}
.lista-rangos {
  display: grid;
  gap: 0;
}
.lista-rangos > div {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 10px;
  align-items: center;
  padding-block: 8px;
  border-top: 1px solid var(--line);
}
.lista-rangos > div:first-child {
  border-top: 0;
}
.lista-rangos .r-txt {
  flex: 1 1 180px;
  min-width: 0;
}
.form-rango {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  align-items: end;
  min-width: 0;
}
.form-rango label {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 4px;
  font-size: 12.5px;
  color: var(--muted);
  min-width: 0;
}
.form-rango .inp {
  width: 100%;
  min-width: 0;
  color: var(--ink);
  font-size: 15px;
  padding: 9px 10px;
}
.form-rango .ancho2 {
  grid-column: 1 / -1;
}
.ajustes-intro {
  background: var(--accent-soft);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 14px;
  margin-bottom: 12px;
}
.carril-cerrado {
  position: absolute;
  left: 0;
  right: 0;
  z-index: 3;
  pointer-events: none;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 6px;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  background:
    repeating-linear-gradient(
      135deg,
      color-mix(in srgb, var(--muted) 16%, transparent) 0 5px,
      transparent 5px 10px
    ),
    var(--rej-fuera);
}
.cierre-nota {
  font-size: 13px;
  color: var(--muted);
  margin-top: 8px;
  display: grid;
  gap: 2px;
}
.pros {
  display: grid;
  gap: 8px;
}
.pro {
  display: flex;
  gap: 12px;
  align-items: center;
  text-align: left;
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 12px 14px;
  min-height: 60px;
}
.pro:hover {
  border-color: var(--muted);
}
.pro[aria-pressed="true"] {
  border-color: var(--accent);
  background: var(--accent-soft);
}
.pro-ava {
  flex: 0 0 40px;
  height: 40px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-weight: 600;
  color: var(--accent-ink);
  background: var(--pc, var(--accent));
}
.pro-ava.todas {
  background: var(--sunk);
  color: var(--accent);
  font-size: 20px;
}
.pro-txt {
  display: grid;
  min-width: 0;
}
.pro-txt small {
  color: var(--muted);
  font-size: 13px;
}
.tipo-cierre {
  max-width: 360px;
}
.caja-ok {
  background: var(--ok-soft);
  color: var(--ok);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 14px;
  margin-bottom: 10px;
}

/* Hoja: tarjeta centrada en la pantalla en todos los tamaños (16 px de margen en el móvil), con scroll dentro;
   la cabecera y los botones del pie quedan siempre a la vista. */
.con-hoja body {
  overflow: hidden;
}
.velo {
  position: fixed;
  inset: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--ink) 42%, transparent);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}
.hoja {
  background: var(--surface);
  color: var(--ink);
  width: 100%;
  max-width: 540px;
  max-height: 85vh;
  max-height: min(85dvh, 820px);
  display: flex;
  flex-direction: column;
  border-radius: 18px;
  box-shadow: var(--shadow);
  overflow: hidden;
  min-width: 0;
}
@media (min-width: 700px) {
  .velo {
    padding: 24px;
  }
}
/* Si la página va dentro de un marco más alto que la pantalla, la hoja se coloca junto a lo que se ha tocado (lo pone colocarHoja). */
.velo.en-marco {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: auto;
  display: block;
  padding: 0;
}
.velo.en-marco .hoja {
  position: absolute;
  left: 16px;
  right: 16px;
  margin-inline: auto;
  width: auto;
  border-radius: 18px;
}
.hoja-cab {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 2px 10px;
  align-items: start;
  padding: 14px 12px 12px 16px;
  border-bottom: 1px solid var(--line);
  border-top: 5px solid var(--pc, var(--accent));
}
.hoja-cab h3 {
  font-family: var(--f-display);
  font-size: 22px;
  font-weight: 500;
  line-height: 1.15;
  overflow-wrap: anywhere;
}
.hoja-cab .x {
  width: 44px;
  height: 44px;
  font-size: 24px;
  grid-row: 1 / span 3;
  grid-column: 2;
}
.hoja-cuerpo {
  overflow-y: auto;
  padding: 14px 16px 16px;
  display: grid;
  gap: 14px;
  overscroll-behavior: contain;
  min-width: 0;
}
.hoja-cuerpo > * {
  min-width: 0;
}
.hoja-pie {
  border-top: 1px solid var(--line);
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom, 0px));
  display: grid;
  gap: 8px;
  background: var(--surface);
}
.hoja-pie .estado-cita {
  font-size: 13.5px;
}
.hoja-pie .estado-cita.mal {
  color: var(--danger);
}
.hoja-pie .acciones .btn {
  min-height: 44px;
}
.campo select,
.campo textarea {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 10px;
  padding: 11px 12px;
  font-size: 16px;
  width: 100%;
  min-width: 0;
}
.campo textarea {
  font: inherit;
  font-size: 15px;
  resize: vertical;
  min-height: 84px;
  line-height: 1.45;
}
.opciones {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.opciones .filtro {
  min-height: 40px;
  text-align: left;
}
.opciones .filtro small {
  white-space: nowrap;
  font-weight: 400;
  color: inherit;
  opacity: 0.75;
  font-variant-numeric: tabular-nums;
}
.res-cli {
  display: grid;
  gap: 6px;
}
.res-cli button {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  text-align: left;
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 10px;
  padding: 8px 12px;
}
.res-cli button:hover {
  border-color: var(--muted);
}
.res-cli button span:last-child {
  font-size: 13px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.elegida {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
  background: var(--accent-soft);
  border: 1px solid var(--accent);
  border-radius: 10px;
  padding: 8px 8px 8px 12px;
}
.seg.mini button {
  padding: 7px 8px;
  font-size: 14px;
}
.hoja .dl {
  font-size: 14.5px;
}

/* Clientes */
.filtros {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.filtro {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 99px;
  padding: 6px 12px;
  font-size: 13.5px;
  font-weight: 500;
  display: inline-flex;
  gap: 6px;
  align-items: center;
}
.filtro[aria-pressed="true"] {
  background: var(--accent);
  color: var(--accent-ink);
  border-color: var(--accent);
}
.filtro .n {
  font-variant-numeric: tabular-nums;
  opacity: 0.7;
}
.buscar {
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 10px;
  padding: 9px 12px;
  width: 100%;
  max-width: 360px;
  margin-bottom: 12px;
}
.lista-cli {
  display: grid;
  gap: 8px;
}
.cli {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 4px 10px;
  text-align: left;
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 12px 14px;
}
.cli:hover {
  border-color: var(--muted);
}
.cli-nombre {
  font-weight: 600;
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
  min-width: 0;
}
.cli-linea {
  grid-column: 1 / -1;
  font-size: 13px;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  gap: 2px 12px;
}
.cli-seg {
  grid-column: 1 / -1;
  font-size: 13px;
}
.cli-seg .toca {
  color: var(--warn);
  font-weight: 600;
}
.cli-seg.sin {
  color: var(--muted);
  font-style: italic;
}
.ficha {
  display: grid;
  gap: 14px;
}
.ficha-cab {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
  justify-content: space-between;
}
.ficha-cab h2 {
  font-size: 28px;
}
.metricas {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
@media (min-width: 700px) {
  .metricas {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
.metrica {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 10px 12px;
  display: grid;
  gap: 2px;
  min-width: 0;
}
.metrica .v {
  font-size: 20px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
  overflow-wrap: anywhere;
}
.metrica .v.txt {
  font-size: 15px;
}
.metrica .l {
  font-size: 12px;
  color: var(--muted);
}
.bloque {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 14px;
  display: grid;
  gap: 10px;
  min-width: 0;
}
.hist {
  display: grid;
  gap: 0;
  font-size: 14px;
}
.hist div {
  display: grid;
  grid-template-columns: 96px 1fr auto;
  gap: 8px;
  padding-block: 7px;
  border-top: 1px solid var(--line);
}
.hist div:first-child {
  border-top: 0;
}
.hist .num {
  color: var(--muted);
}
.estado-expl {
  font-size: 13px;
  color: var(--muted);
}
.leyenda-estados {
  margin-top: 14px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 10px 14px;
  display: grid;
  gap: 6px;
  font-size: 13.5px;
  color: var(--muted);
}
.leyenda-estados p {
  margin: 0;
  line-height: 1.4;
}
.leyenda-estados .pill {
  margin-right: 4px;
}
.cita-mod {
  font-size: 12.5px;
  color: var(--muted);
}

/* Ajustes */
.sub {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 6px;
  margin-bottom: 12px;
}
.sub button {
  flex: 0 0 auto;
  border: 1px solid var(--line);
  background: var(--surface);
  border-radius: 99px;
  padding: 6px 12px;
  font-size: 13.5px;
  font-weight: 500;
}
.sub button[aria-pressed="true"] {
  background: var(--accent);
  color: var(--accent-ink);
  border-color: var(--accent);
}
.intro {
  color: var(--muted);
  font-size: 14px;
  max-width: 70ch;
  margin-bottom: 12px;
}
.tarjetas {
  display: grid;
  gap: 12px;
}
@media (min-width: 900px) {
  .tarjetas.dos {
    grid-template-columns: 1fr 1fr;
  }
}
.tarjeta {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px;
  display: grid;
  gap: 12px;
  min-width: 0;
}
.t-cab {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
}
.t-cab .nombre {
  display: flex;
  gap: 8px;
  align-items: center;
  flex: 1;
  min-width: 0;
}
.punto {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--pc);
  flex: 0 0 auto;
}
.inp {
  border: 1px solid var(--line);
  background: var(--bg);
  border-radius: 8px;
  padding: 7px 9px;
  min-width: 0;
}
.inp[aria-invalid="true"] {
  border-color: var(--danger);
}
.inp.nombre-in {
  font-weight: 600;
  width: 100%;
  max-width: 260px;
}
input[type="time"].inp {
  width: 6.6em;
  font-variant-numeric: tabular-nums;
  padding-inline: 6px;
}
.filas-dia {
  display: grid;
}
.fila-dia {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 8px;
  align-items: start;
  padding-block: 7px;
  border-top: 1px solid var(--line);
}
.fila-dia:first-child {
  border-top: 0;
}
.fila-dia .dn {
  font-weight: 600;
  font-size: 13px;
  padding-top: 7px;
}
.tramos {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  align-items: center;
  min-width: 0;
}
.tramo {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.x {
  border: 0;
  background: transparent;
  color: var(--muted);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  font-size: 18px;
  line-height: 1;
}
.x:hover {
  background: var(--sunk);
  color: var(--danger);
}
.no-trab {
  font-size: 13px;
  color: var(--muted);
  padding-top: 6px;
}
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.chk {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px solid var(--line);
  border-radius: 99px;
  padding: 5px 10px;
  font-size: 13px;
  cursor: pointer;
  background: var(--bg);
}
.chk:has(input:checked) {
  background: var(--accent-soft);
  border-color: var(--accent);
}
.chk input {
  accent-color: var(--accent);
  margin: 0;
}
.fila-online {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 8px;
  align-items: center;
  padding-block: 8px;
  border-top: 1px solid var(--line);
}
.fila-online:first-child {
  border-top: 0;
}
.fila-online .horas-in {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 12px;
  align-items: center;
}
.fila-online label.lb {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--muted);
}
.grupo-trat {
  display: grid;
  gap: 8px;
  margin-bottom: 16px;
}
.nueva-cat {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: flex-end;
  min-width: 0;
}
.nueva-cat label {
  flex: 1 1 220px;
  min-width: 0;
}
.trat-aj {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  min-width: 0;
}
.trat-aj[open] {
  border-color: var(--muted);
  box-shadow: var(--shadow);
}
.trat-aj.inactivo > summary .ta-nombre {
  color: var(--muted);
}
.trat-aj > summary {
  list-style: none;
  cursor: pointer;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 2px 12px;
  align-items: center;
  padding: 12px 14px;
  min-height: 56px;
}
.trat-aj > summary::-webkit-details-marker {
  display: none;
}
.trat-aj > summary::after {
  /* Misma flecha que los demás desplegables (▾ cerrado, ▴ abierto). */
  content: "▾";
  grid-row: 1 / span 2;
  grid-column: 2;
  align-self: center;
  color: var(--muted);
  font-size: 14px;
}
.trat-aj[open] > summary::after {
  content: "▴";
}
.trat-aj.persona-aj > summary {
  grid-template-columns: auto minmax(0, 1fr) auto;
}
.trat-aj.persona-aj > summary .punto {
  grid-row: 1 / span 2;
  grid-column: 1;
  align-self: center;
}
.trat-aj.persona-aj > summary .ta-nombre {
  grid-column: 2;
}
.trat-aj.persona-aj > summary .ta-meta {
  grid-column: 2;
}
.trat-aj.persona-aj > summary::after {
  grid-column: 3;
}
.ta-nombre {
  font-weight: 600;
  min-width: 0;
  overflow-wrap: anywhere;
}
.ta-meta.ta-horario {
  flex-direction: column;
  align-items: flex-start;
}
.ta-meta {
  grid-column: 1;
  font-size: 13px;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  gap: 2px 10px;
  align-items: center;
  font-variant-numeric: tabular-nums;
}
.ta-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 4px 14px 14px;
  border-top: 1px solid var(--line);
  padding-top: 14px;
  min-width: 0;
}
.ta-form .ancho2 {
  grid-column: 1 / -1;
}
.ta-form label {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 4px;
  font-size: 12.5px;
  color: var(--muted);
  min-width: 0;
}
.ta-form .inp {
  width: 100%;
  min-width: 0;
  color: var(--ink);
  font-size: 15px;
  padding: 9px 10px;
}
.ta-form textarea.inp {
  font: inherit;
  font-size: 15px;
  resize: vertical;
  min-height: 76px;
  line-height: 1.45;
}
.ta-form label.chk {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  justify-self: start;
  align-self: end;
  min-height: 42px;
  padding: 8px 14px;
  font-size: 14px;
  color: var(--ink);
}
@media (min-width: 760px) {
  .ta-form {
    grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 1fr));
  }
  .ta-form .ancho2 {
    grid-column: 1 / -1;
  }
}
.reglas {
  display: grid;
  gap: 14px;
  max-width: 520px;
}
.reglas label {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 4px;
  font-size: 14px;
  font-weight: 500;
  min-width: 0;
}
.reglas .inp {
  width: 100%;
  max-width: 240px;
}
.enlace {
  font-family: var(--f-display);
  font-size: clamp(19px, 5.4vw, 28px);
  overflow-wrap: anywhere;
  color: var(--accent);
  line-height: 1.2;
}
.fuente {
  font-size: 12.5px;
  color: var(--warn);
  background: var(--warn-soft);
  border-radius: 8px;
  padding: 6px 10px;
  display: inline-block;
}
.pie {
  margin-top: 28px;
  font-size: 12px;
  color: var(--muted);
  text-align: center;
}
@media (prefers-reduced-motion: no-preference) {
  .dia,
  .hora,
  .trat,
  .btn,
  .cli {
    transition:
      background-color 0.15s,
      border-color 0.15s,
      color 0.15s;
  }
}
/* Extensiones de la base: acceso, puesta en marcha y formularios persistentes. */
#notice:empty {
  display: none;
}
#notice {
  padding: 12px;
  margin-block: 12px;
  border-radius: 12px;
}
.error {
  color: var(--danger);
}
.success {
  color: var(--ok);
}
.warning {
  background: var(--warn-soft);
}
.panel-tabs,
.ajustes-tabs {
  margin-block: 14px;
}
.panel-tabs [aria-current="true"] {
  background: var(--accent);
  color: white;
}
.extra {
  margin-top: 14px;
  max-width: 640px;
}
.extra form,
.acceso-persona,
.trat-extra,
#login {
  display: grid;
  gap: 12px;
}
.extra label,
.acceso-persona label,
.trat-extra label,
#login label {
  display: grid;
  gap: 4px;
}
.check {
  display: flex !important;
  align-items: center;
  gap: 8px !important;
}
.check input {
  width: auto;
}
input:not([type="checkbox"]):not([type="radio"]),
select,
textarea {
  max-width: 100%;
}
input,
select,
textarea {
  font: inherit;
  border: 1px solid var(--line);
  background: var(--bg);
  border-radius: 8px;
  padding: 7px 9px;
  min-width: 0;
}
textarea {
  width: 100%;
}
button:disabled {
  opacity: 0.45;
}
.primary {
  background: var(--accent);
  color: white;
  border: 1px solid var(--accent);
  border-radius: 10px;
  padding: 10px 14px;
}
.full {
  width: 100%;
}
.row,
.acciones {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.spread {
  justify-content: space-between;
}
.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.card {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px;
  margin-block: 12px;
}
.soft {
  background: var(--sunk);
}
.part {
  border-bottom: 1px solid var(--line);
  padding: 16px 0;
  display: grid;
  grid-template-columns: 32px 1fr;
  gap: 10px;
}
.part button {
  grid-column: 2;
  justify-self: start;
}
.number {
  border-radius: 50%;
  background: var(--sunk);
  width: 28px;
  height: 28px;
  text-align: center;
}
progress {
  width: 100%;
  accent-color: var(--accent);
}
#login {
  max-width: 420px;
  margin: 24px auto;
}
#login + h1,
h1 {
  font-family: var(--f-display);
  font-weight: 500;
}
footer {
  margin-top: 30px;
  font-size: 13px;
  color: var(--muted);
}
dialog {
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 22px;
  width: min(620px, calc(100% - 24px));
  max-height: 90dvh;
  color: var(--ink);
}
dialog::backdrop {
  background: rgb(35 15 28/0.3);
}
dialog form {
  display: grid;
  gap: 12px;
}
dialog label {
  display: grid;
  gap: 4px;
}
dialog h2 {
  margin: 14px 0;
}
.hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.closed {
  text-align: center;
  padding: 48px 0;
}
.closed h1 {
  font-size: 38px;
}
.closed p {
  margin-block: 20px;
}
.hist button {
  text-align: left;
  border: 0;
  background: none;
}
.ficha {
  margin-top: 18px;
}
.ficha .bloque {
  border: 1px solid var(--line);
  padding: 16px;
  border-radius: 12px;
}
.tarjeta a,
.enlace {
  overflow-wrap: anywhere;
}
.session {
  margin-top: 18px;
  font-size: 13px;
}

[hidden] {
  display: none !important;
}
dialog.dialog-hoja {
  padding: 0;
  border: 0;
  border-radius: 18px;
  width: min(540px, calc(100% - 24px));
  overflow: hidden;
}
dialog.dialog-hoja .hoja {
  width: 100%;
  max-height: 85dvh;
}
dialog.dialog-hoja .hoja-cab h3 {
  margin: 0;
}
dialog.dialog-hoja .hoja-pie {
  flex-shrink: 0;
}
@media (max-width: 600px) {
  dialog.dialog-hoja {
    margin: auto 0 0;
    width: 100%;
    max-width: 100%;
    border-radius: 18px 18px 0 0;
  }
}

a{color:var(--accent)}

/* Usuario y «Salir» dentro del menú ☰, en vez de una línea suelta al pie de cada pantalla. */
.menu-usuario {
  margin: 6px 0 0;
  padding: 10px 14px 4px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--muted);
}
.enlace-fila { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: 6px 0 14px; }
.enlace-fila code { flex: 1 1 220px; min-width: 0; overflow-wrap: anywhere; font-size: 14px; background: var(--sunk); padding: 8px 10px; border-radius: 8px; }

/* iPhone: los campos de fecha y hora tienen un ancho mínimo propio y se salían de la tarjeta. */
input[type="date"],
input[type="time"] {
  -webkit-appearance: none;
  appearance: none;
  min-width: 0;
  max-width: 100%;
  width: 100%;
  box-sizing: border-box;
}
input[type="date"]::-webkit-date-and-time-value,
input[type="time"]::-webkit-date-and-time-value {
  text-align: left;
}
.cat-hace {
  margin: 12px 0 0;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* Dar cita: tratamientos en desplegables por categoría. */
.cat-hoja {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
}
.cat-hoja > summary {
  list-style: none;
  cursor: pointer;
  padding: 12px 14px;
  font-weight: 600;
  display: flex;
  justify-content: space-between;
  align-items: center;
  min-height: 44px;
}
.cat-hoja > summary::-webkit-details-marker { display: none; }
.cat-hoja > summary .n { font-weight: 400; color: var(--muted); font-size: 13px; }
.cat-hoja > summary::after { content: "▾"; margin-left: 8px; opacity: 0.6; }
.cat-hoja[open] > summary::after { content: "▴"; }
.cat-hoja > .opciones { padding: 0 12px 12px; }
/* Botón «+» para dar cita (solo en Hoy y Agenda). */
.fab {
  position: fixed;
  right: calc(16px + env(safe-area-inset-right));
  bottom: calc(18px + env(safe-area-inset-bottom));
  width: 58px;
  height: 58px;
  border-radius: 50%;
  border: 0;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 32px;
  line-height: 1;
  box-shadow: 0 6px 18px rgb(35 15 28 / 0.28);
  z-index: 30;
  cursor: pointer;
}
.fab:active {
  transform: scale(0.96);
}
/* Que el botón no tape lo último de la agenda. */
#content.con-fab {
  padding-bottom: 84px;
}
/* Hoja del «+»: pasos numerados (Día, Tratamiento, Hora, Clienta). */
.paso-hoja {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 12px 14px;
  display: grid;
  gap: 10px;
  background: var(--surface);
}
.paso-hoja h4 {
  margin: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 16px;
}
.paso-hoja.hecho {
  grid-template-columns: auto 1fr auto;
  align-items: center;
}
.paso-hoja.pendiente {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
}
.paso-res {
  display: grid;
  gap: 2px;
  min-width: 0;
}
.paso-n {
  flex: none;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: inline-grid;
  place-items: center;
  font-size: 13px;
  font-weight: 600;
  border: 1px solid var(--line);
}
.paso-hoja.activo .paso-n,
.paso-hoja.hecho .paso-n {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}
.paso-hoja .franja {
  margin-top: 0;
}
/* En el paso 4 el título ya dice «Clienta». */
.paso-hoja .campo-tit {
  display: none;
}
/* Horas del «+»: desplegables «Antes de comer» / «Después de comer». */
.franja-hoja > .horas {
  padding: 0 12px 12px;
}
/* El «+» en el móvil: a pantalla completa. */
@media (max-width: 600px) {
  dialog.dialog-hoja.dialog-nueva {
    margin: 0;
    height: 100dvh;
    max-height: 100dvh;
    border-radius: 0;
  }
  dialog.dialog-hoja.dialog-nueva .hoja {
    height: 100dvh;
    max-height: 100dvh;
    border-radius: 0;
    box-shadow: none;
  }
  dialog.dialog-hoja.dialog-nueva .hoja-cuerpo {
    flex: 1;
    align-content: start;
  }
  dialog.dialog-hoja.dialog-nueva .hoja-pie {
    padding-bottom: calc(14px + env(safe-area-inset-bottom));
  }
}
.bloquear-rato {
  justify-self: start;
  padding-left: 0;
}
/* Ajustes → Reglas → Envío de emails: con aire entre las piezas. */
.envio-emails {
  display: grid;
  gap: 14px;
}
.envio-emails .estado-envio {
  margin: 0;
  font-weight: 500;
}
.envio-emails #prueba-email {
  display: grid;
  gap: 10px;
}
.registro-tit {
  margin: 10px 0 0;
  font-size: 15px;
}
.registro-emails {
  display: grid;
  gap: 8px;
}
.registro-emails details {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 10px 12px;
}
.registro-emails summary {
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}
.registro-emails details p {
  margin: 8px 0 0;
  overflow-wrap: anywhere;
}

/* Avisos de arriba (guardado, copiado, errores): en una caja suave, no texto suelto. */
#notice.success {
  background: rgb(46 125 80 / 0.1);
}
#notice.error {
  background: rgb(180 40 60 / 0.08);
}
/* Un enlace con forma de botón no va subrayado. */
a.btn {
  text-decoration: none;
}

/* Norma de Bel (17/10): ninguna página se mueve a los lados (solo la rejilla de la agenda y las tiras de días,
   dentro de su caja). */
html {
  overflow-x: hidden;
}
body {
  overflow-x: clip;
}
/* En el iPhone, un campo con letra de menos de 16 px hace zoom al tocarlo y la página queda movida a los lados. */
@media (max-width: 768px) {
  input,
  select,
  textarea {
    font-size: 16px !important;
  }
}
/* Barra de «cargando» arriba mientras hay una petición en marcha. */
body.cargando::before {
  content: "";
  position: fixed;
  inset: 0 0 auto 0;
  height: 3px;
  z-index: 1000;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  background-size: 50% 100%;
  background-repeat: no-repeat;
  animation: cargando 0.9s linear infinite;
}
body.cargando {
  cursor: progress;
}
@keyframes cargando {
  from {
    background-position: -50% 0;
  }
  to {
    background-position: 150% 0;
  }
}
@media (prefers-reduced-motion: reduce) {
  body.cargando::before {
    animation: none;
    background: var(--accent);
  }
}

/* Reglas → Pausa de la reserva online. */
.pausa-horas {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.pausa-dias {
  border: 0;
  padding: 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
}
.pausa-dias legend {
  padding: 0;
  margin-bottom: 6px;
  font-weight: 500;
}
/* Mi cita: cambiar o cancelar en la propia página. */
.cambio {
  display: grid;
  gap: 12px;
  margin-top: 14px;
}
.hoja-form {
  display: grid;
  gap: 14px;
}
.historial {
  margin: 0;
  padding-left: 18px;
  display: grid;
  gap: 4px;
  font-size: 13px;
}

/* Evita el zoom de foco en iPhone, también en formularios de la demo. */
@media (max-width: 600px) {
  body input:not([type="checkbox"]):not([type="radio"]),
  body select, body textarea, body .ta-form textarea.inp {
    font-size: 16px !important;
  }
}
/* Horas como en todas las agendas de CRECE Local (Bel, 17/10): cuadrícula de 3 por fila en el móvil, 4-5 en
   escritorio, botones de al menos 44 px, solo la hora. */
.horas {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
@media (min-width: 600px) {
  .horas {
    grid-template-columns: repeat(auto-fill, minmax(84px, 1fr));
  }
}
.hora {
  min-height: 44px;
}

/* Mi cita (Bel, 17/10: nada pegado, todo uniforme): acciones con aire y botones del mismo ancho. */
.mi-cita-acciones {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}
.mi-cita-acciones p {
  margin: 0;
}
.dos {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
.dos > .btn {
  width: 100%;
  min-height: 44px;
}
.contacto-centro {
  display: grid;
  gap: 8px;
  margin-top: 24px;
}
.contacto-centro .eyebrow {
  margin: 0;
}
@media (min-width: 700px) {
  #app .card.soft,
  .mi-cita-acciones,
  .contacto-centro,
  #cambio {
    max-width: 560px;
  }
}
/* Nada pegado (Bel, 17/10): todos los grupos de botones con el mismo aire, también cuando bajan de línea. */
.horas,
.quien,
.row,
.acciones,
.hoja-pie,
.hoja-pie .row,
.hoja-pie .acciones,
.dos {
  gap: 12px;
}

/* Ajustes: Editar / Guardar cambios / Cancelar. Editando, la barra se queda abajo a la vista. */
.barra-edicion {
  display: grid;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  margin-bottom: 14px;
}
.barra-edicion.ver {
  grid-template-columns: 1fr auto;
  align-items: center;
}
.barra-edicion:not(.ver) {
  /* Editando: la barra de Guardar / Cancelar se queda siempre a la vista, abajo. */
  position: fixed;
  left: 12px;
  right: 12px;
  bottom: calc(10px + env(safe-area-inset-bottom));
  max-width: 616px;
  margin: 0 auto;
  z-index: 40;
  box-shadow: 0 6px 18px rgb(35 15 28 / 0.18);
}
#content.con-barra {
  padding-bottom: 140px;
}
.barra-edicion span {
  font-size: 14px;
}
/* Safari del iPhone no siempre respeta overflow-x en html/body: deja arrastrar la página a los lados. Se bloquea
   también el gesto horizontal de la página (la rejilla de la agenda y las tiras de días son cajas con su propio
   desplazamiento y siguen moviéndose por dentro). */
html,
body {
  max-width: 100%;
  overscroll-behavior-x: none;
}
body {
  position: relative;
  touch-action: pan-y pinch-zoom;
}
.rej-env,
.dias,
.sub,
.horario-semana {
  touch-action: pan-x pan-y pinch-zoom;
}

/* «Hoy» compacto en el móvil: cabecera más baja y filtros en una fila, para que el día entero quepa (Bel, 20/10). */
@media (max-width: 600px) {
  body:has(#content.vista-hoy) .marca-logo {
    height: 40px;
  }
  body:has(#content.vista-hoy) .marca-sub {
    display: none;
  }
  #content.vista-hoy .panel-cab h2 {
    font-size: 28px;
    margin: 0;
  }
  #content.vista-hoy .panel-cab {
    padding-block: 8px 2px;
  }
  #content.vista-hoy .resumen-dia {
    margin-bottom: 6px;
  }
  #content.vista-hoy > p.muted {
    margin: 0 0 4px !important;
  }
  #content.vista-hoy .quien {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: none;
  }
  #content.vista-hoy .quien .filtro {
    flex: 0 0 auto;
    padding: 6px 12px;
    min-height: 36px;
  }
  #content.vista-hoy .rej-env {
    max-height: none;
  }
  /* Columnas estrechas: el número de citas ya sale en el resumen de arriba; aquí, el nombre entero. */
  #content.vista-hoy .rej-cab .n {
    display: none;
  }
  #content.vista-hoy .rej-cab .cab-l1 b {
    overflow: visible;
    text-overflow: clip;
  }
  /* En las citas, hora y clienta en una línea con «…» si no cabe, en vez de cortarse a media letra. */
  #content.vista-hoy .bloque-cita b,
  #content.vista-hoy .bloque-cita span {
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  #content.vista-hoy .bloque-cita.corta span {
    display: none;
  }
  /* Sin nada debajo de la rejilla: la leyenda ya está en «Agenda». */
  #content.vista-hoy .leyenda {
    display: none;
  }
  #content.vista-hoy.con-fab {
    padding-bottom: 8px;
  }
  body:has(#content.vista-hoy) .top {
    padding-block: 6px;
  }
  /* En «Hoy» solo la agenda: sin pie ni margen bajo la rejilla, para que la página no se mueva. */
  body:has(#content.vista-hoy) main {
    padding-bottom: 0;
  }
  body:has(#content.vista-hoy) footer {
    display: none;
  }
}
