.card {
  background: var(--card);
  border: 1px solid var(--sep);
  border-radius: var(--radius);
  box-shadow: 0 1px 2px rgba(16, 16, 20, .03), 0 6px 16px rgba(16, 16, 20, .04);
}

.stat-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; margin-bottom: 18px; }
.stat-card { padding: 16px 18px; }
.stat-card .n { font-family: var(--font-display); font-size: 24px; font-weight: 800; color: var(--ink); line-height: 1.1; }
.stat-card .lbl { font-size: 12.5px; color: var(--ink-soft); margin-top: 4px; }

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  background: var(--accent-soft);
  color: var(--accent-dark);
}

.staff-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 700;
  font-size: 12.5px;
  flex-shrink: 0;
  overflow: hidden;
}
.staff-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Botones */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 16px;
  border-radius: var(--radius-sm);
  font-size: 13.5px;
  font-weight: 700;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
}
.btn-primary { background: var(--accent-action); color: #fff; box-shadow: 0 2px 6px rgba(255,107,74,.28); transition: filter .12s, box-shadow .12s; }
.btn-primary:hover { filter: brightness(1.05); box-shadow: 0 3px 10px rgba(255,107,74,.36); }
.btn-ghost { background: var(--card); border-color: var(--sep); color: var(--ink); transition: border-color .12s, background .12s; }
.btn-ghost:hover { border-color: var(--sep-strong); background: var(--bg); }
/* Discreta en reposo (no compite con el CTA primario), solo se vuelve "de alarma" al hover/foco - misma intencion que un boton destructivo real */
.btn-danger-ghost { background: var(--card); border-color: var(--sep); color: var(--ink-soft); transition: border-color .12s, color .12s, background .12s; }
.btn-danger-ghost:hover, .btn-danger-ghost:focus-visible { color: var(--accent-dark); border-color: #FFD3C2; background: var(--accent-soft); }
.btn-sm { padding: 6px 12px; font-size: 12.5px; }

/* Formularios */
.form-field { margin-bottom: 16px; }
.form-label { display: block; font-size: 12.5px; font-weight: 700; color: var(--ink-soft); margin-bottom: 5px; }
.form-input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--sep);
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-family: var(--font-body);
  background: var(--card);
  transition: border-color .12s, box-shadow .12s;
}
.form-input:hover { border-color: var(--sep-strong); }
.form-input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.form-check { display: flex; align-items: center; gap: 8px; font-size: 13.5px; }
.form-color { width: 46px; height: 38px; padding: 2px; border: 1px solid var(--sep); border-radius: var(--radius-sm); cursor: pointer; }

.card-eyebrow {
  display: flex; align-items: center; gap: 9px;
  font-size: 13px; margin-bottom: 18px; color: var(--ink-soft);
  text-transform: uppercase; letter-spacing: .05em; font-weight: 700;
  padding-bottom: 14px; border-bottom: 1px solid var(--sep);
}
.card-eyebrow i { color: var(--accent); font-size: 13px; }

.business-page { max-width: 1000px; margin: 0 auto; }
.business-layout { display: grid; grid-template-columns: minmax(0, 620px) minmax(280px, 340px); gap: 24px; align-items: start; }

.logo-upload-zone {
  display: flex; align-items: center; gap: 16px;
  border: 1.5px dashed var(--sep-strong);
  border-radius: var(--radius);
  padding: 14px 18px;
  cursor: pointer;
  transition: border-color .12s, background .12s;
}
.logo-upload-zone:hover { border-color: var(--accent); background: var(--accent-soft); }
.logo-upload-title { font-size: 13px; font-weight: 700; color: var(--ink); display: flex; align-items: center; gap: 7px; }
.logo-upload-title i { color: var(--accent-dark); font-size: 12px; }
.logo-upload-sub { font-size: 11.5px; color: var(--ink-soft); margin-top: 2px; }
.business-preview { position: sticky; top: 28px; }
.business-preview-card { padding: 24px; text-align: center; }
.bp-eyebrow { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-soft); margin-bottom: 18px; }

.business-logo-preview {
  width: 56px; height: 56px; border-radius: 14px; overflow: hidden; background: var(--bg);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.business-logo-preview img { width: 100%; height: 100%; object-fit: cover; }
.business-logo-preview span, .business-logo-preview i { font-size: 18px; color: var(--ink-soft); }
.business-logo-preview-lg {
  width: 72px; height: 72px; border-radius: 18px; margin: 0 auto 14px;
  background: var(--accent-soft); color: var(--accent-dark); font-family: var(--font-display); font-size: 26px; font-weight: 800;
}

.bp-name { font-family: var(--font-display); font-size: 17px; font-weight: 700; margin-bottom: 3px; }
.bp-address { font-size: 12.5px; color: var(--ink-soft); margin-bottom: 14px; }
.bp-hours-today {
  display: inline-flex; align-items: center; font-size: 12.5px; font-weight: 600;
  background: var(--bg); padding: 6px 12px; border-radius: 999px; margin-bottom: 16px;
}
.bp-social { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-bottom: 16px; }
.bp-social-chip {
  font-size: 11.5px; font-weight: 700; color: var(--ink-soft);
  background: var(--bg); padding: 5px 10px; border-radius: 999px;
}
.bp-note { font-size: 11px; color: var(--ink-soft); line-height: 1.5; padding-top: 14px; border-top: 1px solid var(--sep); }

@media (max-width: 980px) {
  .business-layout { grid-template-columns: 1fr; }
  .business-preview { position: static; }
}

.hours-row { display: flex; align-items: center; gap: 14px; padding: 8px 0; border-bottom: 1px solid var(--sep); }
.hours-row:last-child { border-bottom: none; }
.hours-day { min-width: 90px; font-size: 13px; font-weight: 600; }
.hours-time { max-width: 140px; }
.hours-time:disabled { opacity: .4; }

.form-error { font-size: 12px; color: var(--accent-dark); margin-top: 4px; }
.form-actions { display: flex; gap: 10px; margin-top: 20px; }

.alert { font-size: 13px; font-weight: 600; padding: 10px 12px; border-radius: var(--radius-sm); margin-bottom: 18px; }
.alert-error { background: var(--accent-soft); color: #B8371C; }
.alert-success { background: #E4F8EA; color: #1A7535; }

/* Listas admin */
.list-toolbar { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 18px; }
.list-toolbar h2 { font-size: 20px; margin-bottom: 3px; }
.list-toolbar .sub { font-size: 13px; color: var(--ink-soft); }
.data-table { width: 100%; border-collapse: collapse; }
.data-table th, .data-table td { text-align: left; padding: 13px 16px; border-bottom: 1px solid var(--sep); font-size: 13.5px; vertical-align: middle; }
.data-table th {
  font-size: 11px; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-soft); font-weight: 700;
  background: var(--bg); position: sticky; top: 0;
}
.data-table th:first-child { border-top-left-radius: var(--radius); }
.data-table th:last-child { border-top-right-radius: var(--radius); }
.data-table tr:last-child td { border-bottom: none; }
.data-table tbody tr { transition: background .1s; }
.data-table tbody tr:hover { background: var(--bg); }
/* Sin display:flex en el <td>: un td flex rompe la alineacion del borde inferior de la fila. */
.row-actions { text-align: right; white-space: nowrap; }
.row-actions > * + * { margin-left: 6px; }
.status-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; margin-right: 6px; }
.status-active { background: var(--green); }
.status-inactive { background: var(--sep-strong); }
.color-dot { width: 16px; height: 16px; border-radius: 5px; display: inline-block; vertical-align: middle; margin-right: 8px; }

/* ---------- Horario individual, servicios por persona y ausencias (/staff/{id}/schedule) ---------- */
.schedule-page { max-width: 1080px; margin: 0 auto; }
.back-link { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 600; color: var(--ink-soft); margin-bottom: 14px; }
.back-link:hover { color: var(--ink); }
.schedule-head { display: flex; align-items: center; gap: 16px; margin-bottom: 20px; }
.schedule-head h2 { font-size: 21px; }
.schedule-head .sub { font-size: 13.5px; color: var(--ink-soft); margin: 3px 0 0; max-width: 62ch; }
.schedule-head-edit { margin-left: auto; flex-shrink: 0; }
.staff-avatar-lg { width: 52px; height: 52px; font-size: 20px; }
.schedule-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 22px; align-items: start; }

.sched-card { padding: 22px 24px; margin-bottom: 18px; }
.sched-card-top {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  padding-bottom: 14px; margin-bottom: 4px; border-bottom: 1px solid var(--sep);
}
.sched-card-top .card-eyebrow { border: 0; padding: 0; margin: 0; }

.sched-day { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 12px; align-items: start; padding: 12px 0; border-bottom: 1px solid var(--sep); }
.sched-day-toggle { display: flex; align-items: center; gap: 10px; min-height: 40px; font-size: 14px; font-weight: 600; cursor: pointer; }
.sched-day-toggle input, .check-chip input, .check-row input, .timeoff-form input[type="checkbox"] { width: 17px; height: 17px; margin: 0; accent-color: var(--accent-action); flex-shrink: 0; }
.sched-blocks { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.sched-block { display: flex; align-items: center; gap: 8px; }
.sched-time { width: 140px; }
.sched-sep { font-size: 13px; color: var(--ink-soft); }
.sched-remove {
  width: 32px; height: 32px; border-radius: 50%; border: 1px solid transparent; background: none;
  color: var(--ink-soft); cursor: pointer; display: inline-flex; align-items: center; justify-content: center;
}
.sched-remove:hover, .sched-remove:focus-visible { background: var(--bg); border-color: var(--sep); color: #B8371C; }
.sched-add { background: none; border: 0; padding: 4px 0; font: 600 13px var(--font-body); color: var(--accent-action); cursor: pointer; display: inline-flex; align-items: center; gap: 6px; }
.sched-add:hover { text-decoration: underline; }
.sched-off-label { display: none; min-height: 40px; align-items: center; font-size: 13.5px; color: var(--ink-soft); }
/* Dia de descanso: se oculta el horario (se conserva para cuando lo activen), funciona sin JS. */
.sched-day:not(:has(.sched-on:checked)) .sched-block,
.sched-day:not(:has(.sched-on:checked)) .sched-add { display: none; }
.sched-day:not(:has(.sched-on:checked)) .sched-off-label { display: inline-flex; }
.sched-day:not(:has(.sched-on:checked)) .sched-day-name { color: var(--ink-soft); }
.field-hint { font-size: 12px; color: var(--ink-soft); margin: 12px 0 0; }

.check-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 8px; margin-top: 14px; }
.check-chip, .check-row {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px;
  border: 1px solid var(--sep); border-radius: var(--radius-sm); cursor: pointer;
  transition: border-color .12s, background .12s;
}
.check-chip:hover, .check-row:hover { border-color: var(--sep-strong); }
.check-chip:has(input:checked), .check-row:has(input:checked) { border-color: var(--accent); background: #FFF6F3; }
.check-chip .color-dot { width: 10px; height: 10px; border-radius: 3px; margin: 0; flex-shrink: 0; }
.cc-text { display: flex; flex-direction: column; min-width: 0; }
.cc-name { font-size: 13.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cc-meta { font-size: 12px; color: var(--ink-soft); }
.check-list { display: flex; flex-direction: column; gap: 6px; }
.check-row { padding: 8px 10px; font-size: 13.5px; }
.check-row .staff-avatar { width: 24px; height: 24px; font-size: 10.5px; }
.check-row .cr-sub { margin-left: auto; font-size: 12px; color: var(--ink-soft); }

.empty-inline { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 14px; font-size: 13.5px; color: var(--ink-soft); }
.empty-inline p { margin: 0; }

.notice-inline {
  display: flex; align-items: flex-start; gap: 10px; margin-bottom: 18px; padding: 11px 14px;
  border-radius: var(--radius-sm); background: #FFF6E5; color: #7A4B00; font-size: 13px; line-height: 1.5;
}
.notice-inline i { margin-top: 3px; }
.notice-inline a { color: inherit; font-weight: 700; text-decoration: underline; }

.week-preview { padding: 20px; margin-bottom: 18px; }
.wp-title { font-family: var(--font-display); font-size: 15px; font-weight: 700; margin-bottom: 14px; }
.wp-rows { display: flex; flex-direction: column; gap: 7px; }
.wp-row { display: grid; grid-template-columns: 34px minmax(0, 1fr); align-items: center; gap: 10px; }
.wp-day { font-size: 12px; font-weight: 700; color: var(--ink-soft); }
.wp-track { position: relative; height: 14px; border-radius: 999px; background: var(--bg); overflow: hidden; }
.wp-seg { position: absolute; top: 0; bottom: 0; border-radius: 999px; }
.wp-scale { position: relative; height: 16px; margin: 6px 0 0 44px; font-size: 10.5px; color: var(--ink-soft); }
.wp-scale span { position: absolute; top: 0; transform: translateX(-50%); white-space: nowrap; }
.wp-scale span:first-child { transform: none; }
.wp-scale span:last-child { transform: translateX(-100%); }
.wp-total { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--sep); font-size: 13px; font-weight: 600; }

.timeoff-card { padding: 20px; }
.timeoff-list { list-style: none; margin: 14px 0; padding: 0; }
.timeoff-item { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--sep); }
.timeoff-item:first-child { border-top: 1px solid var(--sep); }
.to-when { font-size: 13px; font-weight: 600; }
.to-reason { font-size: 12px; color: var(--ink-soft); }
.to-empty { font-size: 13px; color: var(--ink-soft); margin: 14px 0; }
.timeoff-form { padding-top: 14px; border-top: 1px solid var(--sep); }
.to-allday { margin-bottom: 12px; font-weight: 600; cursor: pointer; }
.to-fields { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0 10px; }
.to-fields .form-input { min-width: 0; }
.to-span { grid-column: 1 / -1; }
.timeoff-form:has(input[name="all_day"]:checked) .to-hours { display: none; }
.timeoff-form:not(:has(input[name="all_day"]:checked)) .to-days { display: none; }

/* ---------- Estado de configuracion para recibir reservas ---------- */
.setup-card { padding: 20px 22px; margin-bottom: 16px; border-color: #FFD3C2; }
.setup-head { display: flex; align-items: flex-start; gap: 14px; margin-bottom: 14px; }
.setup-icon {
  width: 40px; height: 40px; border-radius: 12px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: var(--accent-soft); color: #B8371C; font-size: 17px;
}
.setup-title { font-family: var(--font-display); font-size: 16px; font-weight: 700; margin: 0; }
.setup-sub { font-size: 13.5px; color: var(--ink-soft); margin: 2px 0 0; }
.setup-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.setup-step { display: flex; align-items: flex-start; gap: 10px; padding: 12px 14px; border: 1px solid var(--sep); border-radius: var(--radius-sm); }
.setup-step.is-done { background: var(--bg); border-color: var(--bg); }
.setup-mark {
  width: 22px; height: 22px; border-radius: 50%; flex-shrink: 0; margin-top: 1px;
  border: 2px solid #8E8E93; color: #fff; font-size: 11px;
  display: flex; align-items: center; justify-content: center;
}
.setup-step.is-done .setup-mark { background: #1A7535; border-color: #1A7535; }
.setup-step-name { font-size: 13.5px; font-weight: 700; }
.setup-step-desc { font-size: 12.5px; color: var(--ink-soft); }
.setup-step a { display: inline-block; margin-top: 4px; font-size: 13px; font-weight: 700; color: var(--accent-action); }
.setup-inline {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 16px; padding: 11px 14px;
  border: 1px solid #FFD3C2; border-radius: var(--radius-sm); background: #FFF6F3; font-size: 13px; color: var(--ink);
}
.setup-inline i { color: #B8371C; }
.setup-inline a { font-weight: 700; color: #B8371C; }

.tag-warn {
  display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: 999px;
  background: #FFF3DC; color: #8A4B00; font-size: 12px; font-weight: 700; white-space: nowrap;
}
.cell-sub { display: block; font-size: 12px; color: var(--ink-soft); }

.booking-link-box { padding: 20px; margin-top: 18px; text-align: left; }
.booking-link-row { display: flex; gap: 8px; margin: 10px 0; }
.booking-link-row .form-input { font-size: 12.5px; color: var(--ink-soft); min-width: 0; }
.booking-link-status { display: flex; align-items: center; font-size: 12.5px; font-weight: 600; }

@media (max-width: 980px) {
  .schedule-layout { grid-template-columns: 1fr; }
  .setup-steps { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .schedule-head { flex-wrap: wrap; }
  .schedule-head-edit { margin-left: 0; }
  .sched-card { padding: 18px 16px; }
  .sched-day { grid-template-columns: 1fr; gap: 4px; }
  .sched-time { width: 128px; }
}

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.booking-link-actions { display: inline-flex; gap: 6px; }

/* Clientes: lista con resumen y ficha (2026-09-28) */
.cell-link { font-weight: 600; color: var(--ink); text-decoration: none; }
.cell-link:hover { text-decoration: underline; }
.cell-sub { display: block; font-size: 12px; color: var(--ink-soft); }
.cell-notes { max-width: 260px; font-size: 13px; color: var(--ink-soft); }
.nowrap { white-space: nowrap; }
.back-link { display: inline-flex; align-items: center; gap: 6px; font-size: 13.5px; font-weight: 600; margin-bottom: 6px; text-decoration: none; }
.stat-card .n-sm { font-size: 17px; line-height: 1.3; }
.stat-card .n-warn { color: #9A3412; }
.lbl-sm { font-size: 12.5px; color: var(--ink-soft); font-weight: 600; margin-bottom: 4px; }
.cl-status { display: inline-block; font-size: 12px; font-weight: 700; padding: 2px 9px; border-radius: 999px; background: #EFEFF4; color: #4A4A4F; margin: 1px 4px 1px 0; }
.cl-completed { background: #E4F8EA; color: #1B6E34; }
.cl-no_show { background: #FDECEA; color: #A1261E; }
.cl-cancelled { background: #F2F2F7; color: #6B6B70; }
.cl-web { background: #FFF1EC; color: #B8371C; }

/* Reportes (2026-09-29) */
.rep-filter { display: flex; flex-wrap: wrap; gap: 12px 20px; align-items: flex-end; margin-bottom: 16px; }
.rep-presets { display: flex; gap: 6px; flex-wrap: wrap; }
.rep-preset { padding: 7px 14px; border-radius: 999px; border: 1px solid var(--sep-strong); font-size: 13.5px; font-weight: 600; color: var(--ink); text-decoration: none; background: #fff; }
.rep-preset.on { background: var(--ink); border-color: var(--ink); color: #fff; }
.rep-custom { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; }
.rep-custom label { display: flex; flex-direction: column; gap: 4px; font-size: 12.5px; color: var(--ink-soft); font-weight: 600; }
.rep-custom .form-input { width: 160px; }
.rep-small { font-size: 14px; font-weight: 600; color: var(--ink-soft); }
.rep-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-bottom: 16px; }
.data-table .num { text-align: right; white-space: nowrap; }
.rep-empty { text-align: center; color: var(--ink-soft); padding: 18px; }
.rep-box { padding: 18px 20px; }
.rep-h { font-size: 15px; margin: 0 0 12px; }
.rep-bar-row { display: grid; grid-template-columns: 90px 1fr 40px; gap: 10px; align-items: center; margin-bottom: 8px; font-size: 13.5px; }
.rep-bar { height: 10px; border-radius: 6px; background: #EFEFF4; overflow: hidden; }
.rep-bar span { display: block; height: 100%; background: #D93A18; border-radius: 6px; }
.rep-bar-n { text-align: right; font-weight: 600; }
.rep-hours { margin: 0 0 12px; padding-left: 20px; font-size: 14px; }
.rep-hours li { margin-bottom: 6px; }
.rep-note { font-size: 12.5px; color: var(--ink-soft); margin: 4px 0 16px; }
@media (max-width: 1000px) { .rep-grid { grid-template-columns: 1fr; } }

/* Mi negocio: días cerrados (2026-09-29) */
.business-main { min-width: 0; }
.closures-list { list-style: none; margin: 0 0 14px; padding: 0; border: 1px solid var(--sep); border-radius: 12px; }
.closures-list li { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 8px 14px; border-top: 1px solid var(--sep); font-size: 14px; }
.closures-list li:first-child { border-top: 0; }
.closures-add { display: grid; grid-template-columns: 180px minmax(0, 1fr); gap: 12px; align-items: end; }
.closures-add .btn { grid-column: 1 / -1; justify-self: start; }
@media (max-width: 900px) { .closures-add { grid-template-columns: 1fr; } }

/* Agenda: filtro por persona (2026-09-29) */
.agenda-person .form-input { min-height: 34px; padding: 5px 30px 5px 10px; font-size: 13.5px; width: auto; max-width: 220px; }

