/* ============================================================
   dashboard.css — Panel del negocio (blanco · negro · gris)
   Usa los tokens de styles.css (cárgalo antes).
   ============================================================ */

.dash-body {
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg-2);
  color: var(--ink);
}

/* ----------------------------- Layout general ----------------------------- */
.dash {
  display: grid;
  grid-template-columns: 264px 1fr;
  min-height: 100vh;
  min-height: 100dvh;
}
@media (max-width: 960px) {
  .dash { grid-template-columns: 1fr; }
}

/* Cortina del drawer móvil. En escritorio NO debe existir en el flujo:
   si no, ocupa la primera casilla del grid y descoloca todo el panel. */
.dash-scrim { display: none; }

/* ----------------------------- Sidebar ----------------------------- */
.dash-side {
  position: sticky;
  top: 0;
  align-self: start;
  height: 100vh;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  background: #fff;
  border-right: 1px solid var(--line);
  padding: 20px 14px;
  overflow-y: auto;
}
.dash-side__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 8px 18px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.1rem;
  text-decoration: none;
  color: var(--ink);
}
.dash-side__brand .brand-logo { height: 34px; }
@media (min-width: 961px) {
  .dash-side__brand { padding-bottom: 22px; }
  .dash-side__brand .brand-logo { height: 56px; }
}
.dash-nav { display: grid; gap: 2px; }
.dash-nav__item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 11px 12px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .9rem;
  color: var(--ink-soft);
  text-align: left;
  text-decoration: none;
  cursor: pointer;
  transition: background .15s, color .15s;
}
.dash-nav__item:hover { background: var(--bg-2); color: var(--ink); }
.dash-nav__item.is-active { background: var(--ink); color: #fff; }
.dash-nav__sep {
  margin: 12px 12px 8px;
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted-2);
}
.dash-side__foot {
  margin-top: auto;
  padding-top: 16px;
  display: grid;
  gap: 8px;
}
.dash-side__foot a {
  font-size: .82rem;
  color: var(--muted);
  text-decoration: none;
}
.dash-side__foot a:hover { color: var(--ink); text-decoration: underline; }

/* ----------------------------- Topbar ----------------------------- */
.dash-main { min-width: 0; display: flex; flex-direction: column; }
.dash-top {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px clamp(16px, 4vw, 32px);
  background: rgba(255, 255, 255, .9);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.dash-top__title {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: -.01em;
}
.dash-top__spacer { flex: 1; }
.dash-top__user {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: .85rem;
  color: var(--muted);
}
.dash-avatar {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: .9rem;
}
.dash-burger {
  display: none;
  width: 40px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  font-size: 1.1rem;
  cursor: pointer;
}
@media (max-width: 960px) {
  .dash-burger { display: grid; place-items: center; }
  .dash-side {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 60;
    width: 264px;
    transform: translateX(-100%);
    transition: transform .25s var(--ease);
    box-shadow: var(--shadow-lg);
  }
  .dash.is-drawer-open .dash-side { transform: translateX(0); }
  .dash-scrim {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 55;
    background: rgba(10, 10, 10, .4);
  }
  .dash.is-drawer-open .dash-scrim { display: block; }
  .dash-top__user-mail { display: none; }
}

/* ----------------------------- Contenido ----------------------------- */
.dash-content { padding: clamp(18px, 4vw, 32px); }
.dash-view { display: none; animation: dash-fade .2s var(--ease); }
.dash-view.is-active { display: block; }
@keyframes dash-fade { from { opacity: 0; transform: translateY(6px); } }
@media (prefers-reduced-motion: reduce) { .dash-view { animation: none; } }

.dash-view__head { margin-bottom: 22px; }
.dash-view__head h1 {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(1.4rem, 4vw, 1.9rem);
  letter-spacing: -.02em;
}
.dash-view__head p { margin-top: 6px; color: var(--muted); font-size: .95rem; }

/* ----------------------------- Tarjetas ----------------------------- */
.dash-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(16px, 3vw, 24px);
  box-shadow: var(--shadow-sm);
  margin-bottom: 18px;
}
.dash-card__title {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.dash-card__hint { color: var(--muted); font-size: .84rem; margin-bottom: 16px; }

/* ----------------------------- Stats ----------------------------- */
.dash-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 14px;
  margin-bottom: 20px;
}
.dash-stat {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--shadow-sm);
}
.dash-stat__v {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.9rem;
  letter-spacing: -.02em;
}
.dash-stat__l { color: var(--muted); font-size: .82rem; margin-top: 2px; }

/* ----------------------------- Formularios ----------------------------- */
.dash-field { display: grid; gap: 6px; margin-bottom: 14px; }
.dash-field[hidden] { display: none; }
.dash-field label {
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .82rem;
  color: var(--ink-soft);
}
.dash-field input,
.dash-field select,
.dash-field textarea {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  font: inherit;
  color: var(--ink);
  transition: border-color .2s, box-shadow .2s;
}
.dash-field textarea { resize: vertical; min-height: 96px; line-height: 1.5; }
.dash-field select {
  padding-right: 38px;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236f6f6f' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 13px center;
  background-size: 11px;
  cursor: pointer;
}
.dash-field select:hover { border-color: var(--ink-soft); }
.dash-field select::-ms-expand { display: none; }
.dash-field input:focus,
.dash-field select:focus,
.dash-field textarea:focus {
  outline: none;
  border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(10, 10, 10, .08);
}

/* ---- Selectores de la tarjeta "País y moneda" ----
   Dos <select> nativos con el mismo aspecto: ancho completo, bordes
   suaves, altura cómoda, flecha discreta y foco elegante. */
.geo-select {
  position: relative;
  width: 100%;
  max-width: 420px;
}
.geo-select::after {
  content: "";
  position: absolute;
  right: 14px;
  top: 50%;
  width: 11px;
  height: 11px;
  margin-top: -6px;
  pointer-events: none;
  background: no-repeat center / contain
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236f6f6f' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  transition: transform .2s ease;
}
.geo-select:focus-within::after { transform: translateY(1px); }
.geo-select select {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  width: 100%;
  height: 46px;
  padding: 0 40px 0 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  font: inherit;
  font-size: .95rem;
  color: var(--ink);
  cursor: pointer;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.geo-select select:hover { border-color: var(--ink-soft); }
.geo-select select:focus {
  outline: none;
  border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(10, 10, 10, .08);
}
.geo-select select::-ms-expand { display: none; }
@media (max-width: 640px) {
  .geo-select { max-width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  .geo-select::after,
  .geo-select select { transition: none !important; }
}

.dash-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: end;
}
.dash-row > * { flex: 1; min-width: 140px; }
.dash-inline { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

.dash-msg { font-size: .84rem; margin-top: 8px; min-height: 1.1em; }
.dash-msg.ok { color: #1e6b2e; }
.dash-msg.err { color: #b00020; }

.dash-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 44px;
  padding: 0 18px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .9rem;
  cursor: pointer;
  text-decoration: none;
  transition: transform .15s var(--ease), background .2s, box-shadow .2s;
}
.dash-btn:hover { background: #242424; box-shadow: var(--shadow-md); }
.dash-btn:active { transform: translateY(1px); }
/* Mismo motivo que .dash-field[hidden] (arriba): display:inline-flex empata en
   especificidad con el [hidden] global de styles.css y, al cargar dashboard.css
   DESPUÉS, le gana por orden de aparición — un .dash-btn que se oculta solo (sin
   un contenedor padre ya oculto) se quedaría visible sin esto. */
.dash-btn[hidden] { display: none; }
.dash-btn--ghost { background: #fff; color: var(--ink); border-color: var(--line); }
.dash-btn--ghost:hover { background: var(--bg-2); border-color: var(--ink); box-shadow: none; }
.dash-btn--danger { background: #fff; color: #b00020; border-color: #e7b7bf; }
.dash-btn--danger:hover { background: #fdecee; box-shadow: none; }
.dash-btn--sm { height: 36px; padding: 0 12px; font-size: .8rem; }
.dash-btn[disabled] { opacity: .5; cursor: not-allowed; }
.dash-btn-block { width: 100%; }

/* ----------------------------- Tabla de citas ----------------------------- */
.dash-table-wrap { overflow-x: auto; }
.dash-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .86rem;
}
.dash-table th {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-head);
  font-size: .74rem;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
}
.dash-table td {
  padding: 12px;
  border-bottom: 1px solid var(--line-2);
  vertical-align: middle;
}
.dash-table tr:last-child td { border-bottom: 0; }

.stag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: .74rem;
  font-weight: 600;
  white-space: nowrap;
}
.stag-pending { background: #fff4e0; color: #8a5a00; }
.stag-confirmed { background: #e6f0ff; color: #1c4f9c; }
.stag-cancelled { background: #fdecee; color: #b00020; }
.stag-completed { background: #eef7ee; color: #1e6b2e; }
.stag-no_show { background: #ececec; color: #555; }

.dash-empty {
  text-align: center;
  color: var(--muted);
  font-size: .88rem;
  padding: 28px 12px;
}

/* ----------------------------- Lista de citas (resumen) ----------------------------- */
.appt-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line-2);
}
.appt-row:last-child { border-bottom: 0; }
.appt-row__time {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: .82rem;
  width: 74px;
  flex: none;
}
.appt-row__info { flex: 1; min-width: 0; }
.appt-row__name { font-weight: 600; font-size: .9rem; }
.appt-row__sub { color: var(--muted); font-size: .8rem; }

/* ----------------------------- Calendario ----------------------------- */
.cal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}
.cal-head__label {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1rem;
  text-transform: capitalize;
}
.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
}
.cal-dow {
  text-align: center;
  font-size: .72rem;
  font-weight: 700;
  color: var(--muted-2);
  padding: 4px 0;
  text-transform: uppercase;
}
.cal-cell {
  position: relative;
  aspect-ratio: 1 / 1;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .85rem;
  color: var(--ink-soft);
  cursor: pointer;
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  padding: 6px 8px;
  transition: border-color .15s, background .15s;
}
.cal-cell:hover { border-color: var(--ink); }
.cal-cell.is-empty { visibility: hidden; }
.cal-cell.is-today { border-color: var(--ink); }
.cal-cell.has-appts { background: var(--ink); color: #fff; border-color: var(--ink); }
.cal-cell__badge {
  position: absolute;
  left: 6px;
  bottom: 6px;
  font-size: .68rem;
  font-weight: 700;
  background: rgba(255, 255, 255, .25);
  border-radius: 999px;
  padding: 1px 6px;
}
.cal-cell:not(.has-appts) .cal-cell__badge { background: var(--bg-3); color: var(--ink-soft); }
@media (max-width: 560px) {
  .cal-cell { font-size: .78rem; padding: 4px 5px; border-radius: 9px; }
  .cal-cell__badge { font-size: .6rem; left: 3px; bottom: 3px; }
}

/* ----------------------------- Listas editables (empleados / servicios) ----------------------------- */
.dash-list { display: grid; gap: 10px; margin-bottom: 14px; }
.dash-list__item {
  display: flex;
  gap: 8px;
  align-items: center;
}
.dash-list__item input {
  flex: 1;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font: inherit;
}
.dash-list__item input:focus {
  outline: none;
  border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(10, 10, 10, .08);
}
.dash-list__del {
  height: 38px;
  flex: none;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .82rem;
  color: var(--muted);
}
.dash-list__del:hover { background: #fdecee; border-color: #e7b7bf; }

/* ----------------------------- Clientes ----------------------------- */
.dash-client {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line-2);
}
.dash-client:last-child { border-bottom: 0; }
.dash-client__av {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  flex: none;
  border-radius: 999px;
  background: var(--bg-3);
  font-family: var(--font-head);
  font-weight: 700;
}
.dash-client__body { flex: 1; min-width: 0; }
.dash-client__name { font-weight: 600; font-size: .92rem; }
.dash-client__meta { color: var(--muted); font-size: .8rem; }

/* ----------------------------- Suscripción ----------------------------- */
.plan-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}
.plan {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
}
.plan.is-current { border-color: var(--ink); box-shadow: var(--shadow-md); }
.plan__name {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.05rem;
}
.plan__price {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.8rem;
  margin: 8px 0 2px;
}
.plan__price span { font-size: .8rem; font-weight: 500; color: var(--muted); }
.plan__list { list-style: none; margin: 14px 0 18px; display: grid; gap: 8px; }
.plan__list li { font-size: .85rem; color: var(--ink-soft); padding-left: 20px; position: relative; }
.plan__list li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: .28em;
  width: 5px;
  height: 9px;
  border: solid var(--ink);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.plan__tag {
  align-self: flex-start;
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .05em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  margin-bottom: 10px;
}
.plan .dash-btn { margin-top: auto; }

.dash-note {
  background: var(--bg-2);
  border: 1px dashed var(--line);
  border-radius: 12px;
  padding: 14px 16px;
  font-size: .85rem;
  color: var(--ink-soft);
  margin-bottom: 18px;
}

/* ----------------------------- WhatsApp preview ----------------------------- */
.wa-preview {
  white-space: pre-wrap;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px;
  font-size: .82rem;
  color: var(--ink-soft);
  line-height: 1.5;
}

/* ----------------------------- Toast + modal ----------------------------- */
.dash-toast-host {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  z-index: 200;
  display: grid;
  gap: 8px;
  width: min(92vw, 420px);
}
.dash-toast {
  padding: 12px 16px;
  border-radius: 12px;
  background: var(--ink);
  color: #fff;
  font-size: .86rem;
  box-shadow: var(--shadow-lg);
}
.dash-toast.err { background: #b00020; }

.dash-modal {
  position: fixed;
  inset: 0;
  z-index: 210;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(10, 10, 10, .45);
}
.dash-modal.is-open { display: flex; }
.dash-modal__box {
  width: 100%;
  max-width: 440px;
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 26px;
  box-shadow: var(--shadow-lg);
}
.dash-modal__box h3 {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 8px;
}
.dash-modal__box p { color: var(--ink-soft); font-size: .9rem; }
.dash-modal__actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  margin-top: 20px;
}
.dash-modal__msg {
  white-space: pre-wrap;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 12px;
  font-size: .82rem;
  line-height: 1.5;
  margin: 10px 0;
  max-height: 200px;
  overflow-y: auto;
}

/* ============================================================
   AMPLIACIÓN DEL PANEL — Inicio, Agenda, Servicios, Profesionales,
   Horarios, Notificaciones, Perfil y Página pública.
   Usa los tokens de styles.css y las clases base de arriba.
   ============================================================ */

/* Modal con scroll para formularios largos */
.dash-modal__box { max-height: 88vh; max-height: 88dvh; overflow-y: auto; overscroll-behavior: contain; }
.dash-modal__box .dash-field:last-child { margin-bottom: 0; }

/* ---------- Interruptor reutilizable ---------- */
.dash-switch {
  position: relative;
  flex: none;
  width: 42px;
  height: 24px;
  display: inline-block;
  cursor: pointer;
}
.dash-switch input {
  position: absolute; inset: 0; width: 100%; height: 100%;
  margin: 0; opacity: 0; cursor: pointer;
}
.dash-switch__track {
  position: absolute; inset: 0;
  border-radius: 999px;
  background: var(--bg-3);
  border: 1px solid var(--line);
  transition: background .18s var(--ease), border-color .18s;
}
.dash-switch__track::after {
  content: "";
  position: absolute; top: 2px; left: 2px;
  width: 18px; height: 18px;
  border-radius: 999px; background: #fff;
  box-shadow: var(--shadow-sm);
  transition: transform .18s var(--ease);
}
.dash-switch input:checked + .dash-switch__track { background: var(--ink); border-color: var(--ink); }
.dash-switch input:checked + .dash-switch__track::after { transform: translateX(18px); }
.dash-switch input:focus-visible + .dash-switch__track { outline: 2px solid var(--ink); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) {
  .dash-switch__track, .dash-switch__track::after { transition: none; }
}
.emp-inline { display: inline-flex; align-items: center; gap: 8px; font-size: .85rem; color: var(--ink-soft); }

/* ---------- Estado bloqueado ---------- */
.stag-blocked { background: #ececec; color: #555; }

/* ---------- Gráfica de actividad (Inicio) ---------- */
.dash-chart {
  display: flex;
  align-items: flex-end;
  gap: clamp(4px, 1.6vw, 10px);
  height: 140px;
  padding-top: 6px;
}
.dash-chart__col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; min-width: 0; }
.dash-chart__barwrap { width: 100%; height: 110px; display: flex; align-items: flex-end; }
.dash-chart__bar {
  position: relative;
  width: 100%;
  max-width: 26px;
  margin: 0 auto;
  background: var(--bg-3);
  border-radius: 6px 6px 0 0;
  min-height: 2px;
}
.dash-chart__bar-done {
  position: absolute; left: 0; right: 0; bottom: 0;
  background: #1e6b2e;
  border-radius: 6px 6px 0 0;
}
.dash-chart__label { font-size: .68rem; color: var(--muted-2); font-weight: 600; }

/* ---------- Agenda: barra de herramientas ---------- */
.ag-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}
.ag-segment {
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 3px;
  background: var(--bg-2);
}
.ag-segment__btn {
  border: 0;
  background: transparent;
  padding: 7px 14px;
  border-radius: 999px;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .82rem;
  color: var(--muted);
  cursor: pointer;
}
.ag-segment__btn.is-active { background: var(--ink); color: #fff; }
.ag-nav { display: inline-flex; align-items: center; gap: 8px; }
.ag-nav__label {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: .9rem;
  min-width: 8ch;
  text-align: center;
  text-transform: capitalize;
}
.ag-actions { display: inline-flex; gap: 8px; flex-wrap: wrap; }

/* ---------- Agenda: pizarra "Próximos turnos" ---------- */
.up-board__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}
.up-board__clock { color: var(--muted); font-size: .82rem; }
.up-board__tools { display: inline-flex; align-items: center; gap: 8px; }
.up-step {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 3px;
  background: var(--bg-2);
}
.up-step__btn {
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
}
.up-step__btn:hover:not(:disabled) { background: #fff; }
.up-step__btn:disabled { opacity: .35; cursor: default; }
.up-step__val {
  min-width: 2.4ch;
  text-align: center;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: .9rem;
}
/* minmax(0,1fr): un nombre largo (nowrap + …) no ensancha la columna ni saca el × de pantalla */
.up-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
.up-list .dash-empty { padding: 18px 12px; }
.up-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  border: 1px solid var(--line-2);
  border-radius: 12px;
  background: var(--bg);
}
.up-item:first-child { border-color: var(--ink); }   /* el siguiente turno */
.up-item__when { flex: none; width: 84px; }
.up-item__time {
  display: block;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1rem;
  white-space: nowrap;
}
.up-item__day { display: block; color: var(--muted); font-size: .74rem; }
.up-item__day::first-letter { text-transform: uppercase; }
.up-item__info { flex: 1; min-width: 0; }
.up-item__name,
.up-item__svc { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.up-item__name { font-weight: 600; font-size: .95rem; }
.up-item__svc { color: var(--muted); font-size: .82rem; }
.up-item__cancel {
  flex: none;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--muted);
  font-size: 1.15rem;
  line-height: 1;
  cursor: pointer;
}
.up-item__cancel:hover,
.up-item__cancel:focus-visible { color: #b00020; border-color: #f3c2c8; background: #fdecee; }
@media (max-width: 560px) {
  .up-board__tools { width: 100%; justify-content: space-between; }
  .up-item { gap: 10px; padding: 10px 12px; }
  .up-item__when { width: 70px; }
  .up-item .stag { display: none; }   /* en móvil manda hora · nombre · servicio */
}

/* Pantalla completa (tablet / pantalla del local): legibilidad primero.
   z-index bajo el toast (200) y el modal (210): la confirmación de
   cancelar sigue viéndose encima. */
.up-board.is-full {
  position: fixed;
  inset: 0;
  z-index: 150;
  margin: 0;
  border: 0;
  border-radius: 0;
  overflow-y: auto;
  padding: clamp(20px, 4vw, 48px);
}
body.up-full-open { overflow: hidden; }
.up-board.is-full .dash-card__title { font-size: clamp(1.4rem, 3vw, 2.2rem); }
.up-board.is-full .up-board__clock { font-size: clamp(.95rem, 1.8vw, 1.3rem); }
.up-board.is-full .up-list { gap: clamp(10px, 1.6vw, 16px); }
.up-board.is-full .up-item {
  gap: clamp(14px, 3vw, 32px);
  padding: clamp(14px, 2.4vw, 26px) clamp(16px, 3vw, 32px);
  border-radius: var(--radius);
}
.up-board.is-full .up-item__when { width: clamp(108px, 20vw, 210px); }
.up-board.is-full .up-item__time { font-size: clamp(1.3rem, 4vw, 2.6rem); }
.up-board.is-full .up-item__day { font-size: clamp(.85rem, 1.6vw, 1.1rem); }
.up-board.is-full .up-item__name { font-size: clamp(1.15rem, 3vw, 2rem); }
.up-board.is-full .up-item__svc { font-size: clamp(.95rem, 2vw, 1.3rem); }
.up-board.is-full .stag { font-size: clamp(.75rem, 1.4vw, .95rem); }
/* Puede estar de cara a los clientes (TV/tablet): sin cancelar desde aquí. */
.up-board.is-full .up-item__cancel { display: none; }

/* ---------- Agenda: vista semana ---------- */
.ag-week {
  display: grid;
  grid-template-columns: repeat(7, minmax(140px, 1fr));
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 6px;
}
.ag-week__col {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  min-height: 120px;
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.ag-week__col.is-today { border-color: var(--ink); box-shadow: var(--shadow-sm); }
.ag-week__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: .78rem;
  text-transform: capitalize;
}
.ag-day-add {
  width: 24px; height: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  color: var(--ink-soft);
}
.ag-day-add:hover { background: var(--bg-2); border-color: var(--ink); }
.ag-week__item {
  text-align: left;
  border: 1px solid var(--line-2);
  border-radius: 9px;
  background: var(--bg-2);
  padding: 7px 8px;
  font-size: .78rem;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.ag-week__item:hover { border-color: var(--ink); }
.ag-week__item.is-blocked { background: #ececec; color: #555; }
.ag-week__svc { color: var(--muted); font-size: .72rem; }
.ag-week__empty { color: var(--muted-2); font-size: .8rem; text-align: center; padding: 12px 0; }

/* ---------- Servicios: tarjetas ---------- */
.svc-card, .emp-card {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 16px;
  margin-bottom: 12px;
  background: var(--bg-2);
}
.svc-card__row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.svc-card__row > .dash-field { flex: 1; min-width: 140px; margin-bottom: 8px; }
.svc-card__name { font-weight: 600; }
.svc-extras { margin-top: 6px; }
.svc-extra {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 8px;
}
.svc-extra input[type="text"] { flex: 1; min-width: 140px; }
.svc-extra input[type="number"] { width: 100px; flex: none; }
.svc-extra select { width: 130px; flex: none; }
.svc-extra input,
.svc-extra select {
  padding: 9px 11px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font: inherit;
}
.svc-extra select {
  padding-right: 30px;
  background-color: #fff;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236f6f6f' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 9px center;
  background-size: 10px;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  cursor: pointer;
  transition: border-color .18s ease;
}
.svc-extra select:hover { border-color: var(--ink-soft); }
.svc-extra select::-ms-expand { display: none; }
.svc-extra .dash-switch { flex: none; }

/* ---------- Profesionales: tarjetas ---------- */
.emp-chks { margin-top: 8px; }
.emp-chks .dash-card__hint { margin-bottom: 6px; }
.emp-chk {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: .84rem;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 12px;
  margin: 0 6px 6px 0;
  cursor: pointer;
}

/* Fila de opciones tipo "pastilla" con casilla (p. ej. Notificaciones >
   Anticipación). Sin esto, dentro de un .dash-field la casilla hereda
   width:100% y la pastilla se estira a todo el ancho (se rompe en móvil). */
.chk-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 2px;
}
.chk-row .emp-chk { margin: 0; }
.chk-row input[type="checkbox"] {
  width: auto;
  flex: none;
  padding: 0;
  margin: 0;
}
@media (max-width: 720px) {
  .chk-row .emp-chk { padding: 9px 14px; font-size: .88rem; }
}
.emp-days { display: flex; flex-wrap: wrap; gap: 6px; }
.emp-day {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: .8rem;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 6px 10px;
  background: #fff;
  cursor: pointer;
}
.emp-own, .emp-sub { margin-top: 12px; }
.emp-range {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 8px;
}
.emp-range input[type="date"], .emp-range input[type="time"] { flex: none; }
.emp-range input[type="text"] { flex: 1; min-width: 120px; }
.emp-range input {
  padding: 9px 11px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font: inherit;
}

/* ---------- Horarios ---------- */
.hrs-day, .hrs-special {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: 12px 0;
  border-bottom: 1px solid var(--line-2);
}
.hrs-day:last-of-type { border-bottom: 0; }
.hrs-day__name {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: .85rem;
  width: 92px;
  flex: none;
}
.hrs-day__times { display: inline-flex; align-items: center; gap: 6px; }
.hrs-day__times input, .hrs-special input[type="time"], .hrs-special input[type="date"] {
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font: inherit;
}
.hrs-day__breaks { display: flex; flex-direction: column; gap: 6px; }
.hrs-break { display: inline-flex; align-items: center; gap: 6px; }
.hrs-break input {
  padding: 7px 9px;
  border: 1px solid var(--line);
  border-radius: 8px;
  font: inherit;
}
.hrs-special input[type="text"] {
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font: inherit;
  flex: 1;
  min-width: 120px;
}

/* ---------- Notificaciones ---------- */
.notif-row {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px 16px;
  margin-bottom: 12px;
  background: var(--bg-2);
}
.notif-row:last-child { margin-bottom: 0; }
.notif-row__top { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 10px; }
.notif-row__t { display: grid; gap: 2px; }
.notif-row__t b { font-family: var(--font-head); font-size: .9rem; }
.notif-row__t span { color: var(--muted); font-size: .8rem; }

/* ---------- Perfil: logo + galería ---------- */
.pf-cover { margin-bottom: 18px; }
.pf-cover__frame {
  width: 100%; aspect-ratio: 21 / 9; margin-bottom: 10px;
  border-radius: 14px; border: 1px solid var(--line);
  background: var(--bg-3) center / cover no-repeat;
}
.pf-logo { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; margin-bottom: 16px; }
.pf-logo__frame {
  width: 76px; height: 76px; flex: none;
  border-radius: 18px;
  overflow: hidden;
  display: grid;
  place-items: center;
  background: var(--bg-3);
  border: 1px solid var(--line);
}
.pf-logo__frame img { width: 100%; height: 100%; object-fit: cover; }
img[hidden], .pf-logo__initials[hidden], #cfgLogoInitials[hidden] { display: none !important; }
.pf-logo__initials { font-family: var(--font-head); font-weight: 700; font-size: 1.7rem; color: var(--ink-soft); }
.pf-logo__actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }

.pf-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 10px;
}
.pf-gallery__item {
  position: relative;
  aspect-ratio: 4 / 3;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--line);
}
.pf-gallery__item img { width: 100%; height: 100%; object-fit: cover; }
.pf-gallery__del {
  position: absolute; top: 6px; right: 6px;
  width: 26px; height: 26px;
  border: 0;
  border-radius: 999px;
  background: rgba(10, 10, 10, .65);
  color: #fff;
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
}

/* ---------- Página pública ---------- */
.pub-slug { display: flex; align-items: stretch; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.pub-slug__base {
  display: flex; align-items: center;
  padding: 0 10px;
  background: var(--bg-2);
  color: var(--muted);
  font-size: .82rem;
  white-space: nowrap;
  border-right: 1px solid var(--line);
}
.pub-slug input { border: 0 !important; border-radius: 0 !important; flex: 1; min-width: 0; }
.pub-slug input:focus { box-shadow: none !important; }
.pub-url {
  margin-top: 10px;
  padding: 12px 14px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 12px;
  font-family: var(--font-head);
  font-size: .86rem;
  word-break: break-all;
}
.pub-qr { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; }
.pub-qr img {
  width: 200px; height: 200px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
}
.pub-qr__fallback { color: var(--muted); font-size: .84rem; }

.pub-preview {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 18px;
  background: var(--bg-2);
  display: grid;
  gap: 14px;
}
.pub-preview__head { display: flex; gap: 14px; align-items: center; }
.pub-preview__logo {
  width: 56px; height: 56px; flex: none;
  border-radius: 14px;
  background-size: cover;
  background-position: center;
  background-color: var(--bg-3);
}
.pub-preview__logo--txt {
  display: grid; place-items: center;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.4rem;
  color: var(--ink);
}
.pub-preview__name { font-family: var(--font-head); font-weight: 700; font-size: 1.05rem; }
.pub-preview__sub { color: var(--muted); font-size: .84rem; }
.pub-preview__desc { font-size: .88rem; color: var(--ink-soft); }
.pub-preview__col b { font-family: var(--font-head); font-size: .85rem; display: block; margin-bottom: 6px; }
.pub-preview__svcs { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.pub-preview__svcs li { display: flex; justify-content: space-between; gap: 12px; font-size: .84rem; }
.pub-preview__svcs li span:last-child { color: var(--muted); white-space: nowrap; }
.pub-preview__cta { display: flex; align-items: center; gap: 10px; }
.pub-preview__cta .dash-btn[aria-disabled="true"] { opacity: .6; cursor: default; pointer-events: none; }
.pub-preview__hint { color: var(--muted); font-size: .78rem; }

@media (max-width: 720px) {
  /* Barra de herramientas: apilada y a todo el ancho */
  .ag-toolbar { flex-direction: column; align-items: stretch; gap: 10px; }
  .ag-segment { display: flex; width: 100%; }
  .ag-segment__btn { flex: 1; text-align: center; padding: 9px 10px; }
  .ag-nav { justify-content: space-between; gap: 6px; }
  .ag-nav__label { flex: 1; min-width: 0; font-size: .82rem; line-height: 1.3; }
  .ag-actions { display: flex; }
  .ag-actions .dash-btn { flex: 1; }

  /* Vista SEMANA: de 7 columnas con scroll lateral -> días apilados en
     vertical (sin scroll horizontal, legible en el móvil) */
  .ag-week {
    grid-template-columns: 1fr;
    gap: 10px;
    overflow-x: visible;
    padding-bottom: 0;
  }
  .ag-week__col { min-height: 0; padding: 10px 12px; }
  .ag-week__col.is-today { box-shadow: 0 0 0 2px var(--ink) inset; }
  .ag-week__head { font-size: .86rem; }
  .ag-week__empty { text-align: left; padding: 4px 0 2px; }
  .ag-week__item { font-size: .82rem; padding: 9px 10px; }

  /* Vista DÍA: cada cita pasa de fila apretada (hora | datos | estado |
     columna de botones) a una TARJETA apilada legible */
  .appt-row {
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 10px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 12px;
    margin-bottom: 10px;
    background: #fff;
  }
  .appt-row:last-child { margin-bottom: 0; }
  .appt-row__time { width: auto; font-size: .88rem; order: 1; }
  .appt-row .stag { order: 2; margin-left: auto; }
  .appt-row__info { order: 3; flex-basis: 100%; }
  .appt-row__name { font-size: .95rem; }
  .appt-row__sub { font-size: .82rem; margin-top: 2px; }
  .appt-row > .dash-inline {
    order: 4;
    flex-basis: 100%;
    width: 100%;
    gap: 8px;
    margin-top: 2px;
  }
  .appt-row > .dash-inline .dash-btn {
    flex: 1 1 calc(50% - 4px);
    min-width: calc(50% - 4px);
  }

  .hrs-day__name { width: 100%; }
}

/* ============================================================
   RESEÑAS  (vista "resenas" — js/reviews-core.js)
   ============================================================ */
.dash-grid-2 { display: grid; gap: 16px; grid-template-columns: 1fr; }
@media (min-width: 760px) { .dash-grid-2 { grid-template-columns: 1fr 1fr; } }

/* Distribución por estrellas */
.dash-revbar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 5px 0;
  font-size: .85rem;
}
.dash-revbar__k { width: 30px; color: var(--muted); font-variant-numeric: tabular-nums; }
.dash-revbar__track {
  flex: 1;
  height: 8px;
  border-radius: 999px;
  background: var(--bg-3, #efefef);
  overflow: hidden;
}
.dash-revbar__fill { display: block; height: 100%; background: var(--ink); border-radius: 999px; }
.dash-revbar__n { width: 28px; text-align: right; color: var(--muted); font-variant-numeric: tabular-nums; }

/* Filas de promedio por profesional / servicio */
.dash-revrow {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 12px;
  padding: 10px 0;
  border-top: 1px solid var(--line-2, #efefef);
  font-size: .9rem;
}
.dash-revrow:first-child { border-top: 0; }
.dash-revrow__name { flex: 1 1 120px; font-family: var(--font-head); font-weight: 600; }
.dash-revrow__avg { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); }
.dash-revrow__c { color: var(--muted-2, #a0a0a0); font-size: .8rem; }

/* Tarjeta de reseña */
.dash-revcard {
  padding: 14px 0;
  border-top: 1px solid var(--line-2, #efefef);
}
.dash-revcard:first-child { border-top: 0; }
.dash-revcard__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.dash-revcard__date { color: var(--muted-2, #a0a0a0); font-size: .78rem; }
.dash-revcard__sub {
  margin-top: 6px;
  font-size: .78rem;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--muted);
}
.dash-revcard__who { margin-top: 2px; font-size: .85rem; color: var(--ink-soft, #3d3d3d); font-weight: 600; }
.dash-revcard__text { margin-top: 6px; font-size: .92rem; color: var(--ink-soft, #3d3d3d); }
.dash-revcard__badges { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.dash-revcard__badge {
  padding: 3px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: .74rem;
  color: var(--muted);
}

/* ======================================================================
   SELECTOR DE TIPO DE NEGOCIO  (Perfil del negocio → Identidad)
   Botón compacto que abre un diálogo con buscador + categorías
   agrupadas (js/business-type-picker.js).
====================================================================== */
.biztype-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  min-width: 0; /* grid item: sin esto, el texto sin wrap fuerza el ancho de la tarjeta */
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  font: inherit;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  transition: border-color .2s, box-shadow .2s;
}
.biztype-trigger:hover { border-color: var(--ink-soft); }
.biztype-trigger:focus-visible {
  outline: none;
  border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(10, 10, 10, .08);
}
.biztype-trigger__text {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.biztype-trigger.is-empty .biztype-trigger__text { color: var(--muted); }
.biztype-trigger__action {
  flex: none;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .82rem;
  color: var(--ink-soft);
}

.biztype-dialog {
  position: fixed;
  inset: 0;
  z-index: 220;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(10, 10, 10, .45);
}
.biztype-dialog[hidden] { display: none; }
.biztype-dialog__box {
  width: 100%;
  max-width: 480px;
  max-height: 80vh;
  max-height: 80dvh;
  display: flex;
  flex-direction: column;
  background: #fff;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.biztype-dialog__head {
  flex: none;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 16px 16px 12px;
  border-bottom: 1px solid var(--line);
}
.biztype-dialog__search {
  flex: 1;
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--bg-2);
  font: inherit;
  color: var(--ink);
}
.biztype-dialog__search:focus {
  outline: none;
  border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(10, 10, 10, .08);
}
.biztype-dialog__close {
  flex: none;
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  color: var(--ink-soft);
  cursor: pointer;
}
.biztype-dialog__close:hover { border-color: var(--ink-soft); }
.biztype-dialog__list {
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 8px 10px 16px;
}
.biztype-group__title {
  margin: 14px 6px 6px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: .78rem;
  letter-spacing: .01em;
  color: var(--muted);
}
.biztype-group__title:first-child { margin-top: 4px; }
.biztype-opt {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  padding: 10px 10px;
  border: none;
  border-radius: 10px;
  background: none;
  font: inherit;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}
.biztype-opt:hover,
.biztype-opt:focus-visible { background: var(--bg-2); outline: none; }
.biztype-opt.is-selected { background: var(--bg-2); font-weight: 600; }
.biztype-opt__check { flex: none; color: var(--ink); }
.biztype-dialog__empty { padding: 20px 10px; color: var(--muted); font-size: .88rem; text-align: center; }
@media (max-width: 520px) {
  .biztype-dialog { padding: 0; align-items: flex-end; }
  .biztype-dialog__box { max-width: none; max-height: 85vh; max-height: 85dvh; border-radius: var(--radius-lg) var(--radius-lg) 0 0; }
}

/* ======================================================================
   UBICACIÓN Y SERVICIO A DOMICILIO  (Perfil del negocio)
   Selector "¿Cómo atiendes?", switches de ubicación y constructor de
   campos personalizados del servicio a domicilio.
====================================================================== */
.mode-options {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
@media (max-width: 720px) { .mode-options { grid-template-columns: 1fr; } }
.mode-opt {
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-align: left;
  padding: 14px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
  transition: border-color .18s ease, background .18s ease, box-shadow .18s ease;
}
.mode-opt:hover { border-color: var(--ink-soft, #3d3d3d); }
.mode-opt[aria-checked="true"] {
  border-color: var(--ink);
  background: var(--bg-2);
  box-shadow: 0 0 0 1px var(--ink) inset;
}
.mode-opt__title { font-family: var(--font-head); font-weight: 600; font-size: .92rem; color: var(--ink); }
.mode-opt__desc { font-size: .8rem; color: var(--muted); line-height: 1.4; }
.mode-opt:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }

.dash-switchrow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
  font-size: .9rem;
  color: var(--ink-soft, #3d3d3d);
}
.dash-switchrow > span { flex: 1; }

/* Constructor de campos personalizados (una tarjeta por campo) */
.hsf-card {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 12px;
  background: var(--bg-2);
}
.hsf-card__row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px 12px;
}
.hsf-card__row + .hsf-card__row { margin-top: 10px; }
.hsf-card__foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
  margin-top: 12px;
}
.hsf-card__foot .dash-switchrow { border: 0; padding: 0; gap: 8px; }
.hsf-card__spacer { flex: 1; }
.hsf-card__opts { margin-top: 10px; }


/* ============================================================
   MÓVIL / TÁCTIL — panel (sin rediseño)
   · Drawer: el pie (Cerrar sesión) siempre visible, aunque el menú sea
     más alto que la pantalla; sin depender de la unidad vh (barra de Safari).
   · Modales largos: caben en pantallas pequeñas y hacen scroll dentro.
   · Safe-area de iPhone (notch / barra de gestos).
   ============================================================ */
.dash-toast-host { bottom: calc(24px + env(safe-area-inset-bottom)); }
.dash-modal__actions { flex-wrap: wrap; }

@media (max-width: 960px) {
  .dash-side {
    /* fixed + inset (arriba y abajo) lo estira al alto VISIBLE; hace falta
       align-self:stretch porque en escritorio es "start" y, con height:auto,
       el drawer se quedaba con el alto de su contenido (footer fuera de pantalla). */
    align-self: stretch;
    height: auto;
    padding-left: max(14px, env(safe-area-inset-left));
    padding-bottom: 0;
    overscroll-behavior: contain;
  }
  .dash-side__foot {
    position: sticky;
    bottom: 0;
    margin-top: auto;
    padding: 12px 0 calc(12px + env(safe-area-inset-bottom));
    background: #fff;
    border-top: 1px solid var(--line);
  }
}
@media (max-width: 560px) {
  .dash-modal {
    padding: max(12px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right))
             max(12px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left));
  }
  .dash-modal__box { padding: 20px; }
}

@media (pointer: coarse) {
  .dash-burger { width: 44px; height: 44px; }
  .dash-nav__item, .dash-btn { min-height: 44px; }
  .dash-btn--sm { min-height: 40px; }
  .dash-side__foot a { display: flex; align-items: center; min-height: 44px; font-size: .9rem; }
}

/* ---------- Profesionales desactivados / exceso de plan (0048) ---------- */
.emp-card--inactive { opacity: .72; border-style: dashed; }
.emp-card__badge {
  margin-bottom: 10px;
  padding: 8px 12px;
  border-radius: 10px;
  background: #fff4e5;
  border: 1px solid #f2c77b;
  color: #6b4500;
  font-size: .82rem;
}
.emp-card__badge[hidden] { display: none; }
.plan__overflow { color: #8a5a00; }
#seatOverflowModal .emp-chks { max-height: 220px; overflow-y: auto; }

.emp-danger { border-top: 1px dashed var(--line); padding-top: 8px; }
.emp-danger > summary { cursor: pointer; color: #8a1f1f; font-size: .82rem; font-weight: 600; }

/* Pie legal permanente en la barra lateral del panel */
.dash-side__legal { display: flex; flex-wrap: wrap; gap: 2px 12px; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line, #e6e6e6); }
.dash-side__foot .dash-side__legal a { font-size: .74rem; color: var(--muted, #6f6f6f); }

/* ── Sucursales (solo plan Business; js/dashboard.js renderSucursales) ── */
.dash-nav__item[hidden] { display: none; }
.brn-summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-bottom: 14px; }
.brn-summary__item { padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: #fff; display: grid; gap: 4px; }
.brn-summary__k { font-size: .76rem; color: var(--muted); }
.brn-summary__v { font-family: var(--font-head); font-weight: 600; color: var(--ink); }
.brn-list { display: grid; gap: 12px; }
.brn-card__head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.brn-card__name { margin: 0; font-family: var(--font-head); font-size: 1.05rem; }
.brn-card__tags { display: flex; flex-wrap: wrap; gap: 6px; }
.brn-tag { display: inline-block; padding: 3px 9px; border-radius: 999px; border: 1px solid var(--line); font-size: .74rem; font-weight: 600; color: var(--ink-soft); background: var(--bg-2, #f6f6f6); }
.brn-tag--primary { background: var(--ink); border-color: var(--ink); color: #fff; }
.brn-tag--pending_verification { background: #fff6e0; border-color: #f0d79a; color: #7a5300; }
.brn-tag--rejected { background: #fdeaea; border-color: #f3c4c4; color: #8a1f1f; }
.brn-tag--inactive { color: var(--muted); }
.brn-card__meta { display: grid; gap: 3px; font-size: .88rem; color: var(--ink-soft); }
.brn-card__meta b { color: var(--ink); font-weight: 600; }
.brn-card__note { margin: 10px 0 0; padding: 9px 12px; border-radius: 10px; background: var(--bg-2, #f6f6f6); font-size: .84rem; color: var(--ink-soft); line-height: 1.45; }
.brn-card__actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.brn-card--rejected { opacity: .8; }
.brn-addrow { margin: 14px 0; }
.brn-form__title { margin-bottom: 4px; }
.brn-form__price { margin: 0 0 8px; font-size: 1rem; }
.brn-form__actions { margin-top: 12px; }
.brn-hours { margin: 6px 0 4px; }
.brn-hours__switch { display: flex; align-items: center; gap: 10px; font-size: .88rem; margin-bottom: 8px; }
.brn-hours__grid { display: grid; gap: 6px; }
.brn-hours__grid[hidden] { display: none; }
.brn-hours__row { display: grid; grid-template-columns: 96px auto 1fr 1fr; align-items: center; gap: 8px; font-size: .86rem; }
.brn-hours__row input[type="time"] { min-width: 0; padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; font: inherit; }
.brn-hours__closed { display: inline-flex; align-items: center; gap: 4px; white-space: nowrap; }
.emp-branchwarn { margin-bottom: 12px; padding: 12px 14px; border: 1px solid #f0d79a; border-radius: 12px; background: #fff6e0; color: #5c3f00; font-size: .88rem; line-height: 1.45; }
.emp-branchwarn p { margin: 0 0 10px; }
.emp-branchwarn[hidden] { display: none; }
.brn-staff { display: grid; gap: 8px; }
.brn-staff__row { display: grid; grid-template-columns: 1fr minmax(0, 220px); align-items: center; gap: 10px; }
.brn-staff__name { font-size: .9rem; font-weight: 600; overflow-wrap: anywhere; }
@media (max-width: 720px) {
  .brn-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .brn-hours__row { grid-template-columns: 1fr auto; }
  .brn-hours__row input[type="time"] { grid-column: span 1; }
  .brn-staff__row { grid-template-columns: 1fr; }
}
