.rp-prof-panel{
  --rp-blue:#0b78aa;
  --rp-text:#1f2937;
  --rp-muted:#667085;
  --rp-border:#e5e7eb;
  --rp-bg:#f5f7fa;
  --rp-sidebar-closed:78px;
  --rp-sidebar-open:280px;
  display:grid;
  grid-template-columns:var(--rp-sidebar-closed) minmax(0,1fr);
  min-height:calc(100vh - 80px);
  background:var(--rp-bg);
  color:var(--rp-text);
  font-family:Inter,system-ui,-apple-system,Segoe UI,sans-serif;
  border:1px solid var(--rp-border);
  border-radius:18px;
  overflow:hidden;
  transition:grid-template-columns .22s ease;
  position:relative;
  isolation:isolate;
  width:min(1280px, calc(100vw - 32px));
  margin-left:50%;
  transform:translateX(-50%);
}
.rp-prof-panel *{box-sizing:border-box}

.rp-prof-panel.rp-sidebar-expanded{grid-template-columns:var(--rp-sidebar-open) minmax(0,1fr)}
.rp-prof-sidebar{
  background:#fff;
  border-right:1px solid var(--rp-border);
  padding:18px 10px;
  display:flex;
  flex-direction:column;
  gap:8px;
  min-width:0;
  width:var(--rp-sidebar-closed);
  overflow:hidden;
  box-sizing:border-box;
  transition:width .22s ease,padding .22s ease;
  z-index:5;
}
.rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar{width:var(--rp-sidebar-open);padding:18px 16px}
.rp-prof-brand{display:flex;align-items:center;justify-content:center;gap:12px;margin:0 0 18px;width:100%;height:58px;overflow:hidden}
.rp-prof-panel.rp-sidebar-expanded .rp-prof-brand{justify-content:flex-start}
.rp-prof-brand .rp-brand-logo-wrap{width:50px;height:50px;min-width:50px;border-radius:14px;background:transparent;display:grid;place-items:center;line-height:1;flex:none;overflow:hidden}
.rp-prof-brand .rp-brand-logo{width:50px;height:50px;display:block;object-fit:contain;border-radius:12px}
.rp-prof-brand strong{display:block;opacity:0;max-width:0;overflow:hidden;white-space:nowrap;color:var(--rp-text);font-size:16px;line-height:1.2;font-weight:700;transition:opacity .16s ease,max-width .22s ease}
.rp-prof-panel.rp-sidebar-expanded .rp-prof-brand strong{opacity:1;max-width:200px}
.rp-sidebar-toggle{display:none}
.rp-prof-sidebar a{width:52px;height:52px;min-height:52px;margin:2px auto;border-radius:16px;display:flex;align-items:center;justify-content:center;gap:0;box-sizing:border-box;color:#344054;background:transparent;text-decoration:none;font-size:0;line-height:1;overflow:hidden;white-space:nowrap;padding:0;transition:background .15s ease,color .15s ease,width .22s ease,justify-content .22s ease,padding .22s ease}
.rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar a{width:100%;height:40px;min-height:40px;margin:1px 0;padding:0 12px;justify-content:flex-start;gap:10px;font-size:13px}
.rp-prof-sidebar a.active,.rp-prof-sidebar a:hover{background:rgba(255,255,255,.18);color:#fff}
.rp-prof-sidebar a::before{content:none!important;display:none!important}
.rp-nav-icon{width:20px;height:20px;min-width:20px;display:inline-flex;align-items:center;justify-content:center;color:currentColor;flex:0 0 24px;overflow:hidden}
.rp-nav-icon svg,.rp-prof-sidebar a svg{width:18px!important;height:18px!important;min-width:18px!important;min-height:18px!important;display:block!important;fill:none!important;stroke:currentColor!important;stroke-width:1.8!important;stroke-linecap:round!important;stroke-linejoin:round!important;transform:none!important}
.rp-nav-label{display:inline-block;opacity:0;max-width:0;width:0;overflow:hidden;white-space:nowrap;color:inherit;font-size:13px;font-weight:400;line-height:1.2;transition:opacity .16s ease,max-width .22s ease,width .22s ease}
.rp-prof-panel.rp-sidebar-expanded .rp-nav-label{opacity:1;max-width:190px;width:auto}
.rp-prof-main{padding:28px;overflow:hidden;min-width:0}
.rp-prof-section{display:none}.rp-prof-section.active{display:block}
.rp-prof-head{margin-bottom:22px}.rp-head-actions{display:flex;justify-content:space-between;gap:18px;align-items:flex-start}.rp-prof-head h1{font-size:34px;line-height:1.1;margin:0 0 8px;font-weight:700}.rp-prof-head p{margin:0;color:var(--rp-muted);font-size:16px}.rp-kpis{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;margin-bottom:20px}.rp-kpis div,.rp-card,.rp-list-card,.rp-patient-card,.rp-table-card,.rp-calendar-shell,.rp-detail-card{background:#fff;border:1px solid var(--rp-border);border-radius:14px;padding:20px;box-shadow:none}.rp-kpis strong{display:block;font-size:30px}.rp-kpis span{color:var(--rp-muted)}.rp-btn{display:inline-flex;align-items:center;justify-content:center;background:var(--rp-blue);color:#fff!important;border:0;border-radius:10px;padding:12px 18px;text-decoration:none;font-weight:500;cursor:pointer;line-height:1}.rp-btn-small{padding:9px 12px;font-size:13px}.rp-btn-light{background:#eef8fc!important;color:#075b82!important}.rp-calendar-toolbar{margin-bottom:16px}.rp-calendar-title{display:flex;justify-content:space-between;gap:12px;align-items:center;margin-bottom:14px}.rp-calendar-title strong{font-size:20px}.rp-calendar-title span{color:var(--rp-muted);font-size:14px}.rp-calendar-weekdays{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:10px;margin-bottom:8px}.rp-calendar-weekdays span{text-align:center;font-size:12px;color:var(--rp-muted);font-weight:600}.rp-admin-calendar{display:grid;grid-template-columns:repeat(7,minmax(110px,1fr));gap:10px}.rp-day-cell{min-height:118px;text-align:left;background:#fff;border:1px solid var(--rp-border);border-radius:12px;padding:12px;cursor:pointer;color:var(--rp-text);transition:border-color .15s,transform .15s}.rp-day-cell:hover{border-color:var(--rp-blue);transform:translateY(-1px)}.rp-day-cell strong{display:block;font-size:18px;margin-bottom:8px}.rp-day-cell span{display:block;font-size:12px;background:#eef8fc;border-radius:8px;padding:4px 6px;margin:4px 0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.rp-day-cell em{font-style:normal;font-size:12px;color:var(--rp-muted)}.rp-day-empty{visibility:hidden}.rp-day-cell.is-free{background:#fbfffd}.rp-day-cell.has-patients{background:#f7fbff;border-color:#c9e6f4}.rp-list-card{margin-top:22px}.rp-list-card h2,.rp-card h2{margin:0 0 16px;font-size:22px}.rp-row,.rp-note-row{display:grid;grid-template-columns:120px 1fr 140px;gap:12px;border-top:1px solid var(--rp-border);padding:12px 0}.rp-row:first-of-type,.rp-note-row:first-of-type{border-top:0}.rp-row em{font-style:normal;color:var(--rp-muted)}.rp-form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}.rp-form-grid label{display:flex;flex-direction:column;gap:7px;font-weight:500}.rp-form-grid input,.rp-form-grid select,.rp-form-grid textarea{width:100%;border:1px solid var(--rp-border);border-radius:10px;padding:12px 13px;background:#fff;min-height:46px}.rp-form-grid textarea{min-height:110px}.rp-form-grid .full{grid-column:1/-1}.rp-checks{display:flex!important;flex-direction:row!important;flex-wrap:wrap;gap:14px!important}.rp-checks strong{width:100%}.rp-checks label{flex-direction:row!important;align-items:center}.rp-modal{display:none;position:fixed;inset:0;background:rgba(15,23,42,.55);z-index:99999;padding:30px;align-items:center;justify-content:center}.rp-modal.active{display:flex}.rp-modal-box{position:relative;background:#fff;width:min(860px,96vw);max-height:90vh;overflow:auto;border-radius:18px;padding:28px;box-shadow:0 24px 70px rgba(0,0,0,.25)}.rp-modal-close{position:absolute;right:18px;top:14px;border:0;background:#f2f4f7;border-radius:50%;width:36px;height:36px;font-size:24px;cursor:pointer}.rp-modal h2{margin:0 0 18px;font-size:28px}.rp-login-required{padding:24px;background:#fff4e5;border:1px solid #ffd8a8;border-radius:12px}.rp-next-card{max-width:640px}.rp-note-row{display:block}.rp-note-row p{color:var(--rp-muted);margin:6px 0 0}.rp-table-tools{display:flex;justify-content:space-between;gap:16px;align-items:center;margin-bottom:14px}.rp-table-tools input{width:min(420px,100%);border:1px solid var(--rp-border);border-radius:10px;padding:12px 14px}.rp-table-tools span{color:var(--rp-muted);font-size:14px}.rp-responsive-table{overflow:auto}.rp-patient-table{width:100%;border-collapse:collapse;min-width:920px}.rp-patient-table th{font-size:12px;text-transform:uppercase;letter-spacing:.04em;color:var(--rp-muted);text-align:left;border-bottom:1px solid var(--rp-border);padding:12px}.rp-patient-table td{border-bottom:1px solid #eef0f3;padding:14px 12px;vertical-align:middle;font-size:14px}.rp-patient-table td strong{display:block;font-size:15px}.rp-patient-table small{display:block;color:var(--rp-muted);font-size:12px;margin-top:3px}.rp-patient-detail-screen{display:none}.rp-patient-detail-screen.active{display:block}.rp-patients-list-view.hidden{display:none}.rp-detail-topbar{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:16px;color:var(--rp-muted)}.rp-detail-hero{background:#fff;border:1px solid var(--rp-border);border-radius:16px;padding:24px;display:flex;justify-content:space-between;gap:18px;align-items:flex-start;margin-bottom:16px}.rp-detail-hero small{color:var(--rp-muted)}.rp-detail-hero h1{margin:6px 0 8px;font-size:38px;line-height:1.05}.rp-detail-hero p{margin:0;color:var(--rp-muted)}.rp-detail-actions{display:flex;gap:10px;flex-wrap:wrap}.rp-detail-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin-bottom:16px}.rp-detail-card h3{margin:0 0 14px;font-size:18px}.rp-detail-card table{width:100%;border-collapse:collapse}.rp-detail-card th,.rp-detail-card td{border-bottom:1px solid #eef0f3;padding:9px 0;text-align:left;vertical-align:top;font-size:14px}.rp-detail-card th{color:var(--rp-muted);font-weight:500;width:36%}.rp-detail-card td{color:var(--rp-text)}.rp-detail-columns{display:grid;grid-template-columns:1fr 1fr;gap:16px}.rp-mini-row{display:flex;justify-content:space-between;gap:12px;border-bottom:1px solid #eef0f3;padding:9px 0;margin:0!important}.rp-mini-row span{font-weight:500;color:var(--rp-text)}.rp-mini-row em{font-style:normal;color:var(--rp-muted);text-align:right}.rp-history-item{border-bottom:1px solid #eef0f3;padding:10px 0}.rp-history-item:first-of-type{padding-top:0}.rp-history-item strong{display:block;margin-bottom:4px}.rp-history-item p{margin:0;color:var(--rp-muted);line-height:1.5}.rp-patient-grid,.rp-patient-grid-full,.rp-patient-file,.rp-file-grid,.rp-file-columns,.rp-file-actions{all:unset}
@media(max-width:1100px){.rp-detail-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.rp-detail-hero{display:block}.rp-detail-actions{margin-top:16px}}
@media(max-width:760px){.rp-prof-panel,.rp-prof-panel.rp-sidebar-expanded{display:block;grid-template-columns:1fr;min-height:auto;overflow:visible}.rp-prof-sidebar,.rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar{width:100%;min-width:0;max-width:none;height:auto;padding:12px;position:sticky;top:0;align-items:stretch}.rp-prof-brand{justify-content:flex-start;margin:0}.rp-prof-brand strong,.rp-nav-label{opacity:1;width:auto;max-width:none}.rp-sidebar-toggle{display:inline-grid;margin-left:auto;border:0;background:#f2f4f7;border-radius:10px;width:38px;height:38px;place-items:center;cursor:pointer;color:#344054}.rp-prof-sidebar a{display:none;width:100%;height:48px;font-size:15px;justify-content:flex-start;padding:0 14px;gap:14px;margin:2px 0}.rp-prof-sidebar.mobile-open a{display:flex}.rp-prof-main{padding:18px}.rp-kpis,.rp-form-grid,.rp-detail-grid,.rp-detail-columns{grid-template-columns:1fr}.rp-admin-calendar{grid-template-columns:repeat(2,1fr)}.rp-calendar-weekdays{display:none}.rp-row{grid-template-columns:1fr}.rp-prof-head h1{font-size:28px}.rp-head-actions,.rp-detail-topbar{display:block}.rp-detail-hero h1{font-size:30px}.rp-modal{padding:14px}.rp-responsive-table{margin-left:-8px;margin-right:-8px}.rp-table-tools{display:block}.rp-table-tools input{margin-bottom:10px}.rp-day-empty{display:none}}
.rp-form-title{font-size:18px!important;margin:8px 0 0!important;color:var(--rp-text);font-weight:650;border-top:1px solid var(--rp-border);padding-top:14px}.rp-form-title:first-of-type{border-top:0;padding-top:0}.rp-coverage-details-wrap{display:none}.rp-patient-form.has-coverage-details .rp-coverage-details-wrap{display:flex}.rp-next-banner{display:flex;align-items:center;gap:14px;flex-wrap:wrap;background:#f8fbfd;border:1px solid var(--rp-border);border-radius:14px;padding:16px 18px;margin-bottom:16px}.rp-next-banner strong{font-size:16px}.rp-next-banner span{color:var(--rp-text)}.rp-next-banner em{font-style:normal;color:var(--rp-muted);margin-left:auto}.rp-detail-grid-wide{grid-template-columns:repeat(2,minmax(0,1fr))}.rp-patient-schedule-card{margin-bottom:16px}.rp-patient-schedule-card p{color:var(--rp-muted);margin-top:-4px}.rp-inline-appointment{margin-top:16px}.rp-debt-box{display:flex;justify-content:space-between;align-items:center;background:#fff7ed;border:1px solid #fed7aa;border-radius:12px;padding:12px 14px;margin-bottom:12px}.rp-debt-box span{font-size:20px;font-weight:700;color:#9a3412}.rp-payment-form{margin-top:16px;padding-top:14px;border-top:1px solid var(--rp-border)}
@media(max-width:1100px){.rp-detail-grid-wide{grid-template-columns:1fr}.rp-next-banner em{margin-left:0}}

/* Historia clínica avanzada */
.rp-history-list-view.hidden{display:none!important}
.rp-history-detail-screen{display:none}
.rp-history-detail-screen.active{display:block}
.rp-history-patient-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}
.rp-history-patient-card{appearance:none;background:#fff;border:1px solid var(--rp-border);border-radius:14px;padding:16px;text-align:left;cursor:pointer;display:flex;flex-direction:column;gap:6px;color:var(--rp-text);transition:border-color .15s,transform .15s}
.rp-history-patient-card:hover{border-color:var(--rp-blue);transform:translateY(-1px)}
.rp-history-patient-card strong{font-size:15px;line-height:1.35}
.rp-history-patient-card span{font-size:13px;color:var(--rp-muted)}
.rp-history-patient-card em{font-size:12px;font-style:normal;color:var(--rp-blue)}
.rp-history-filters{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,180px) minmax(0,180px);gap:12px;margin:0 0 16px;align-items:end;max-width:100%;overflow:hidden}
.rp-history-filter-field{display:flex!important;flex-direction:column!important;gap:6px!important;min-width:0!important;max-width:100%!important;width:100%!important;margin:0!important;font-weight:600;color:var(--rp-text)}
.rp-history-filter-field span{font-size:12px;line-height:1.2;color:var(--rp-muted);font-weight:700}
.rp-history-filter-field span em{font-style:normal;font-weight:600;color:#98a2b3}
.rp-history-filters input{display:block!important;width:100%!important;max-width:100%!important;min-width:0!important;box-sizing:border-box!important;border:1px solid var(--rp-border);border-radius:10px;padding:12px 13px;background:#fff;min-height:46px}
.rp-history-timeline{display:flex;flex-direction:column;gap:14px}
.rp-history-entry{border:1px solid #e8edf2;border-radius:14px;padding:16px;background:#fff}
.rp-history-entry time{display:inline-flex;margin-bottom:10px;font-weight:700;color:var(--rp-blue)}
.rp-history-entry h3{font-size:14px;margin:10px 0 6px;color:var(--rp-text)}
.rp-history-entry p{margin:0;color:var(--rp-muted);line-height:1.65;white-space:pre-line}
.rp-history-inline-form{margin-top:16px;padding-top:14px;border-top:1px solid #eef0f3}
.rp-history-inline-form textarea{min-height:86px}
.rp-open-history-patient{margin-top:12px}
@media(max-width:760px){.rp-history-patient-grid{grid-template-columns:1fr}.rp-history-filters{grid-template-columns:1fr!important;width:100%!important;max-width:100%!important;gap:10px!important;overflow:hidden!important}.rp-history-filters input{width:100%!important;max-width:100%!important;min-width:0!important}.rp-history-search-card{padding:16px!important;overflow:hidden!important}.rp-history-search-card h2{font-size:28px!important;line-height:1.12!important}.rp-history-search-card .rp-muted{font-size:16px!important;line-height:1.45!important}.rp-history-filter-field span{display:block!important}}
@media(max-width:520px){.rp-history-search-card{padding:14px!important}.rp-history-filters{gap:9px!important}.rp-history-filter-search input::placeholder{font-size:14px}.rp-history-filters input{font-size:16px!important;padding:11px 12px!important}}

/* Disponibilidad: guardar bien y evitar checkboxes gigantes */
.rp-form-grid input[type="checkbox"],
.rp-form-grid input[type="radio"]{
  width:18px!important;
  min-width:18px!important;
  max-width:18px!important;
  height:18px!important;
  min-height:18px!important;
  padding:0!important;
  margin:0!important;
  flex:0 0 18px!important;
  accent-color:var(--rp-blue);
  appearance:auto!important;
  -webkit-appearance:checkbox!important;
}
.rp-form-grid label.rp-switch-row{
  display:flex!important;
  flex-direction:row!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:10px!important;
  min-height:46px;
  padding:12px 13px;
  border:1px solid var(--rp-border);
  border-radius:10px;
  background:#fff;
  font-weight:500;
}
.rp-form-grid label.rp-switch-row span{line-height:1.2}
.rp-checks.rp-workdays{
  display:grid!important;
  grid-template-columns:repeat(7,minmax(0,1fr));
  gap:10px!important;
}
.rp-checks.rp-workdays strong{grid-column:1/-1;width:auto;margin-bottom:2px}
.rp-checks.rp-workdays label{
  display:flex!important;
  flex-direction:row!important;
  align-items:center!important;
  gap:8px!important;
  border:1px solid var(--rp-border);
  border-radius:10px;
  padding:10px 12px;
  background:#fff;
  font-weight:500;
}
.rp-saved-notice{background:#ecfdf3;border:1px solid #abefc6;color:#067647;border-radius:12px;padding:12px 14px;margin:0 0 14px;font-weight:600}
@media(max-width:760px){.rp-checks.rp-workdays{grid-template-columns:repeat(2,minmax(0,1fr));}}
.rp-btn-danger{background:#b42318!important;color:#fff!important}
.rp-detail-actions form{margin:0;display:inline-flex}
.rp-error-notice{background:#fff3f0;border:1px solid #fecdca;color:#b42318;border-radius:12px;padding:12px 14px;margin:12px 0;font-weight:600}
.rp-form-help{font-size:13px;color:var(--rp-muted);background:#f8fafc;border:1px solid var(--rp-border);border-radius:10px;padding:12px}
.rp-patient-calendar-picker{margin:16px 0 18px}
.rp-patient-calendar-grid .rp-day-cell.is-blocked{background:#f2f4f7;color:#98a2b3;cursor:not-allowed;opacity:.75}
.rp-patient-calendar-grid .rp-day-cell.selected{border-color:var(--rp-blue)!important;box-shadow:0 0 0 3px rgba(11,120,170,.12)}
.rp-patient-calendar-grid .rp-day-cell:disabled{transform:none!important}
.rp-inline-appointment{margin-top:16px;border-top:1px solid var(--rp-border);padding-top:16px}
@media(max-width:760px){.rp-admin-calendar{grid-template-columns:repeat(7,minmax(54px,1fr));gap:6px}.rp-day-cell{min-height:76px;padding:8px}.rp-day-cell span{display:none}.rp-detail-actions{width:100%}}

/* RP Psico v1.5.6 - calendario paciente multi-mes con globos de turnos estilo VBZ */
.rp-vbz-calendar-wrap{border:1px solid var(--rp-border);border-radius:16px;background:#fff;padding:14px;margin:16px 0 18px;overflow:hidden}
.rp-calendar-toolbar{display:grid;grid-template-columns:42px 1fr 42px;gap:12px;align-items:center;margin-bottom:12px}
.rp-calendar-toolbar strong{display:block;font-size:18px;color:var(--rp-text);line-height:1.2;text-transform:capitalize}
.rp-calendar-toolbar span{display:block;color:var(--rp-muted);font-size:13px;margin-top:3px}
.rp-cal-nav{width:42px;height:42px;border:1px solid var(--rp-border);border-radius:12px;background:#f8fafc;color:var(--rp-text);font-size:28px;line-height:1;cursor:pointer;display:grid;place-items:center;transition:background .15s,border-color .15s,opacity .15s}
.rp-cal-nav:hover:not(:disabled){background:#edf7fb;border-color:#b6ddeb;color:var(--rp-blue)}
.rp-cal-nav:disabled{opacity:.35;cursor:not-allowed}
.rp-calendar-month[hidden]{display:none!important}
.rp-patient-calendar-grid{gap:8px!important}
.rp-patient-calendar-grid .rp-day-cell{position:relative;min-height:104px!important;align-items:flex-start!important;justify-content:flex-start!important;text-align:left!important;padding:10px!important;border-radius:14px!important;overflow:hidden;background:#fff!important}
.rp-patient-calendar-grid .rp-day-cell strong{display:inline-flex;align-items:center;justify-content:center;min-width:26px;height:26px;border-radius:9px;font-size:13px;font-weight:700;background:#f3f6f8;color:var(--rp-text);margin-bottom:6px}
.rp-patient-calendar-grid .rp-day-cell em{font-size:12px;color:var(--rp-muted);font-style:normal;display:block;margin-top:2px}
.rp-patient-calendar-grid .rp-day-cell.is-free{border:1px solid #d7e9ef!important;background:#fbfdfe!important}
.rp-patient-calendar-grid .rp-day-cell.has-patients{border:1px solid #b6ddeb!important;background:#eef9fd!important}
.rp-patient-calendar-grid .rp-day-cell.is-blocked{background:#f2f4f7!important;color:#98a2b3!important;border:1px solid #e4e7ec!important;cursor:not-allowed!important;opacity:.85!important}
.rp-patient-calendar-grid .rp-day-cell.selected{border-color:var(--rp-blue)!important;box-shadow:0 0 0 3px rgba(11,120,170,.14)!important;background:#e9f7fc!important}
.rp-turno-bubbles{display:flex;flex-wrap:wrap;gap:5px;margin-top:4px;width:100%}
.rp-turno-bubble{display:inline-flex!important;align-items:center!important;justify-content:center!important;min-width:44px!important;height:22px!important;border-radius:999px!important;padding:0 8px!important;background:var(--rp-blue)!important;color:#fff!important;font-size:11px!important;font-weight:650!important;line-height:1!important;box-shadow:none!important;border:0!important;white-space:nowrap!important}
.rp-turno-bubble.rp-status-pendiente{background:#f59e0b!important;color:#fff!important}
.rp-turno-bubble.rp-status-cancelado,.rp-turno-bubble.rp-status-ausente{background:#d92d20!important;color:#fff!important}
.rp-turno-bubble.rp-status-atendido{background:#16a34a!important;color:#fff!important}
.rp-turno-bubble.rp-more{background:#344054!important;color:#fff!important;min-width:30px!important}
.rp-patient-calendar-grid .rp-day-cell small{display:block;margin-top:7px;color:#0b789f;font-size:11px;font-weight:650}
@media(max-width:760px){.rp-calendar-toolbar{grid-template-columns:38px 1fr 38px}.rp-cal-nav{width:38px;height:38px;border-radius:10px}.rp-patient-calendar-grid{grid-template-columns:repeat(7,minmax(44px,1fr))!important;gap:5px!important}.rp-patient-calendar-grid .rp-day-cell{min-height:70px!important;padding:6px!important;border-radius:10px!important}.rp-patient-calendar-grid .rp-day-cell strong{min-width:22px;height:22px;font-size:12px}.rp-turno-bubbles{gap:3px}.rp-turno-bubble{min-width:28px!important;height:18px!important;font-size:9px!important;padding:0 5px!important}.rp-patient-calendar-grid .rp-day-cell small,.rp-patient-calendar-grid .rp-day-cell em{display:none!important}}

/* RP Psico v1.5.7 - agenda paciente compacta y vista previa */
.rp-compact-form{gap:10px!important;align-items:end}
.rp-compact-form label{gap:5px!important;font-size:13px!important;font-weight:500!important}
.rp-compact-form input,.rp-compact-form select,.rp-compact-form textarea{min-height:36px!important;padding:8px 10px!important;border-radius:8px!important;font-size:14px!important;line-height:1.25!important}
.rp-compact-form textarea{min-height:72px!important}
.rp-compact-form .rp-btn{min-height:36px!important;padding:9px 14px!important}
.rp-field-hint{font-size:11px!important;color:var(--rp-muted)!important;font-weight:400!important;margin-top:-2px!important}
.rp-patient-schedule-card{margin-top:18px!important;clear:both!important}
.rp-patient-schedule-card > h3{margin-bottom:6px!important}
.rp-patient-schedule-card > p{font-size:14px!important;line-height:1.35!important;margin:0 0 12px!important}
.rp-patient-calendar-picker{margin-bottom:14px!important}
.rp-patient-calendar-grid .rp-day-cell.preview-selected{outline:2px solid var(--rp-blue)!important;background:#eaf8ff!important;box-shadow:inset 0 0 0 2px rgba(14,129,173,.12)!important}
.rp-patient-calendar-grid .rp-day-cell.selected{border-color:var(--rp-blue)!important;background:#eef9ff!important}
.rp-appointment-preview{margin-top:4px!important;border-top:1px solid var(--rp-border)!important;padding-top:12px!important}
.rp-appointment-preview:empty{display:none!important}
.rp-appointment-preview h4{margin:0 0 10px!important;font-size:15px!important;font-weight:600!important;color:var(--rp-text)!important}
.rp-preview-grid{display:grid!important;grid-template-columns:repeat(auto-fit,minmax(180px,1fr))!important;gap:8px!important}
.rp-preview-card{border:1px solid #cfe8f4!important;background:#f5fbff!important;border-radius:10px!important;padding:10px 12px!important;display:flex!important;flex-direction:column!important;gap:4px!important}
.rp-preview-card strong{font-size:14px!important;color:var(--rp-text)!important;font-weight:600!important}
.rp-preview-card span{font-size:12px!important;color:var(--rp-muted)!important}
.rp-preview-card.is-generated{background:#eef8fc!important}
.rp-preview-card.is-manual{background:#f8fbff!important;border-color:#b9dff0!important}
.rp-preview-alert{background:#fff7ed!important;border:1px solid #fed7aa!important;color:#9a3412!important;border-radius:10px!important;padding:10px 12px!important;margin-bottom:10px!important;font-size:13px!important;line-height:1.4!important}
.rp-manual-actions{margin-top:0!important}.rp-manual-actions .rp-btn{width:auto!important}
.rp-plan-edit-card .rp-form-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}
.rp-plan-edit-card .full{grid-column:1/-1!important}
@media(max-width:760px){.rp-plan-edit-card .rp-form-grid,.rp-compact-form{grid-template-columns:1fr!important}.rp-preview-grid{grid-template-columns:1fr!important}}

/* RP Psico v1.5.8 - ficha paciente compacta, calendario debajo y reprogramación */
.rp-patient-schedule-card{padding:18px!important}
.rp-patient-schedule-card .rp-inline-appointment{margin-top:10px!important;margin-bottom:14px!important}
.rp-patient-schedule-card .rp-form-grid.rp-compact-form{grid-template-columns:repeat(5,minmax(0,1fr))!important;gap:8px!important;align-items:end!important}
.rp-patient-schedule-card .rp-compact-form label{font-size:12px!important;line-height:1.15!important;font-weight:500!important;gap:4px!important;margin:0!important}
.rp-patient-schedule-card .rp-compact-form input,
.rp-patient-schedule-card .rp-compact-form select,
.rp-patient-schedule-card .rp-compact-form textarea{min-height:30px!important;height:30px!important;padding:5px 8px!important;border-radius:7px!important;font-size:13px!important;line-height:1.15!important;box-sizing:border-box!important}
.rp-patient-schedule-card .rp-compact-form input[type="checkbox"]{width:15px!important;height:15px!important;min-height:15px!important;padding:0!important}
.rp-patient-schedule-card .rp-compact-form textarea{height:auto!important;min-height:58px!important}
.rp-patient-schedule-card .rp-compact-form .full{grid-column:1/-1!important}
.rp-patient-schedule-card .rp-compact-form .rp-btn{min-height:32px!important;padding:7px 12px!important;border-radius:8px!important;font-size:13px!important}
.rp-patient-schedule-card .rp-field-hint{font-size:10.5px!important;line-height:1.2!important;margin:0!important}
.rp-patient-schedule-card .rp-form-help{font-size:12px!important;padding:7px 10px!important;border-radius:8px!important;background:#f8fafc!important;color:#64748b!important}
.rp-patient-calendar-below{margin-top:10px!important;padding-top:10px!important;border-top:1px solid var(--rp-border)!important}
.rp-patient-calendar-below .rp-vbz-calendar-wrap{margin:0!important;padding:10px!important;border-radius:12px!important}
.rp-patient-calendar-below .rp-calendar-toolbar{margin-bottom:8px!important}
.rp-patient-calendar-below .rp-calendar-toolbar strong{font-size:15px!important}
.rp-patient-calendar-grid .rp-day-cell{min-height:88px!important;padding:8px!important;border-radius:10px!important}
.rp-mini-row.rp-session-row{display:grid!important;grid-template-columns:1fr auto auto!important;gap:8px!important;align-items:center!important}
.rp-mini-action{border:1px solid var(--rp-border)!important;background:#fff!important;color:var(--rp-blue)!important;border-radius:8px!important;padding:5px 8px!important;font-size:12px!important;font-weight:500!important;cursor:pointer!important;white-space:nowrap!important}
.rp-mini-action:hover{background:#eef9ff!important;border-color:#b6ddeb!important}
.rp-patient-appointment-form.is-reprogramming{outline:2px solid rgba(11,120,170,.12)!important;background:#fbfdff!important;border-radius:12px!important;padding:10px!important;margin-left:-4px!important;margin-right:-10px!important}
@media(max-width:1180px){.rp-patient-schedule-card .rp-form-grid.rp-compact-form{grid-template-columns:repeat(3,minmax(0,1fr))!important}}
@media(max-width:760px){.rp-patient-schedule-card .rp-form-grid.rp-compact-form{grid-template-columns:1fr 1fr!important}.rp-mini-row.rp-session-row{grid-template-columns:1fr!important;align-items:start!important}.rp-mini-action{width:max-content!important}.rp-patient-calendar-grid .rp-day-cell{min-height:66px!important}}


/* RP Psico v1.5.9 - aviso moderno, ficha persistente y ajustes de reprogramación/pagos */
.rp-floating-notice{position:fixed;right:22px;bottom:22px;z-index:999999;background:#0f766e;color:#fff;border-radius:14px;padding:14px 18px;box-shadow:0 18px 40px rgba(15,23,42,.22);font-size:14px;font-weight:500;opacity:0;transform:translateY(14px);transition:opacity .25s ease,transform .25s ease;max-width:min(420px,calc(100vw - 32px))}.rp-floating-notice.show{opacity:1;transform:translateY(0)}.rp-floating-notice.is-error{background:#b42318}.rp-payment-form select[name="appointment_id"]{min-width:0}.rp-reprogram-session{cursor:pointer}.rp-patient-appointment-form.is-reprogramming .rp-save-appointment-btn{background:#075b82!important}

/* RP v1.5.8 - Reprogramación confirmada */
.rp-patient-date-pick.is-reprogram-old{outline:2px dashed #ef4444!important;opacity:.55;position:relative}
.rp-patient-date-pick.is-reprogram-old::after{content:'Reprogramando';display:block;font-size:10px;font-weight:600;color:#ef4444;margin-top:4px}
.rp-confirm-overlay{position:fixed;inset:0;background:rgba(15,23,42,.42);backdrop-filter:blur(5px);display:none;align-items:center;justify-content:center;z-index:999999;padding:18px}
.rp-confirm-overlay.active{display:flex}
.rp-confirm-box{width:min(520px,100%);background:#fff;border-radius:16px;border:1px solid #e5e7eb;box-shadow:0 24px 70px rgba(15,23,42,.22);padding:24px;position:relative;color:#111827}
.rp-confirm-box h3{margin:0 0 12px;font-size:22px;font-weight:650;color:#111827}
.rp-confirm-text{font-size:15px;line-height:1.65;color:#374151;margin:0 0 18px}
.rp-confirm-actions{display:flex;justify-content:flex-end;gap:10px;flex-wrap:wrap}
.rp-confirm-close{position:absolute;right:14px;top:12px;border:0;background:transparent;font-size:26px;line-height:1;cursor:pointer;color:#6b7280}
.rp-preview-alert.is-info{background:#eff6ff;border-color:#bfdbfe;color:#1e40af}
/* RP Psico v1.6.0 - ajustes paciente: cancelar, suspender y día desde calendario */
.rp-selected-day-label input.rp-selected-day-view{background:#f8fafc!important;color:#334155!important;cursor:default!important}
.rp-inline-cancel-form,.rp-suspend-patient-form{margin:0!important;display:inline-flex!important}
.rp-mini-row.rp-session-row{grid-template-columns:1fr auto auto auto!important}
.rp-cancel-session{border-color:#fecaca!important;background:#fff5f5!important;color:#b42318!important}
.rp-btn-warning{background:#fff7ed!important;color:#9a3412!important;border:0!important;box-shadow:none!important;filter:none!important;font-weight:400!important}
.rp-btn-warning:hover{background:#ffedd5!important;box-shadow:none!important;filter:none!important}
@media(max-width:760px){.rp-mini-row.rp-session-row{grid-template-columns:1fr!important}.rp-inline-cancel-form,.rp-suspend-patient-form{width:100%!important}.rp-inline-cancel-form button,.rp-suspend-patient-form button{width:100%!important}}

/* Estado paciente */
.rp-patient-status{
    display:inline-flex;
    align-items:center;
    gap:6px;
    padding:4px 10px;
    border-radius:999px;
    font-size:12px;
    line-height:1.2;
    font-weight:600;
    border:1px solid transparent;
    white-space:nowrap;
}
.rp-patient-status::before{
    content:'';
    width:7px;
    height:7px;
    border-radius:50%;
    background:currentColor;
}
.rp-patient-status-activo{
    color:#157347;
    background:#eaf7ef;
    border-color:#c9ead6;
}
.rp-patient-status-suspendido{
    color:#b42318;
    background:#fff0ed;
    border-color:#ffd5cc;
}
.rp-patient-state-line{
    display:block;
    margin-top:7px;
}
.rp-suspended-note{
    display:block;
    margin-top:8px;
    color:#6b7280;
    font-size:13px;
    line-height:1.35;
}
.rp-activate-patient-form,
.rp-suspend-patient-form,
.rp-delete-patient-form{
    margin:0;
}

/* v26 facturacion */
.rp-filter-inline{display:flex;gap:10px;align-items:end;flex-wrap:wrap;margin:0 0 12px}.rp-filter-inline input{border:1px solid var(--rp-border);border-radius:10px;padding:10px 12px;min-height:42px}.rp-billing-table-card{margin-top:18px}.rp-invoices-table small,.rp-invoice-row small{display:block;color:var(--rp-muted);font-size:12px;margin-top:3px}.rp-invoice-row{align-items:flex-start}.rp-invoice-row.is-done{opacity:.72}.rp-inline-invoice-form{margin:0}.rp-billing-settings-card{margin-bottom:18px}.rp-patient-billing-card .rp-debt-box{margin:12px 0}.rp-invoices-table td,.rp-invoices-table th{vertical-align:top}.rp-invoices-table form{margin:0}

.rp-card-title-row{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}.rp-card-title-row h3{margin:0}.rp-icon-edit{display:inline-flex;align-items:center;gap:7px;border:1px solid #dbe3ef;background:#fff;color:#334155;border-radius:10px;padding:8px 10px;cursor:pointer;font-size:13px;font-weight:400}.rp-icon-edit svg{width:18px!important;height:18px!important;flex:0 0 18px;fill:none!important}.rp-icon-edit:hover,.rp-icon-edit.is-open{background:#f8fafc;border-color:#b8c4d6}.rp-patient-edit-form{margin-top:16px;padding-top:16px;border-top:1px solid #e5e7eb}.rp-billing-search-label{display:flex;align-items:center;gap:8px;font-size:13px;font-weight:400;color:#475569}.rp-billing-search{height:38px;min-width:260px;border:1px solid #dbe3ef;border-radius:10px;padding:0 12px;background:#fff}.rp-table-tools{gap:12px;flex-wrap:wrap}.rp-patient-table td small.rp-patient-state-line{display:none!important}
@media(max-width:720px){.rp-billing-search-label{width:100%;align-items:stretch;flex-direction:column}.rp-billing-search{min-width:0;width:100%}.rp-card-title-row{align-items:flex-start}}

/* v28 ingresos: balance, gastos y graficos */
.rp-income-filter{margin-bottom:16px}.rp-income-kpis{grid-template-columns:repeat(4,minmax(0,1fr))}.rp-income-grid{display:grid;grid-template-columns:minmax(0,1.35fr) minmax(280px,.65fr);gap:18px;align-items:start;margin-top:18px}.rp-expense-form{margin-bottom:18px}.rp-balance-lines{display:grid;gap:10px;margin:14px 0 18px}.rp-balance-lines p{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px 0;border-bottom:1px solid #e5e7eb;margin:0}.rp-balance-lines span{color:#475569}.rp-balance-lines strong{font-size:20px;color:#111827}.rp-balance-total{border-bottom:0!important;background:#f8fafc;border-radius:12px;padding:14px!important}.rp-mini-kpis{grid-template-columns:1fr 1fr;margin-top:14px}.rp-chart-card{margin-top:18px}.rp-chart-bars{height:230px;display:flex;align-items:end;gap:14px;padding:18px 8px 8px;border:1px solid #e5e7eb;border-radius:14px;background:#fff}.rp-chart-month{flex:1;min-width:0;text-align:center;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;height:100%;gap:8px}.rp-chart-stack{height:180px;width:100%;display:flex;align-items:end;justify-content:center;gap:5px}.rp-chart-stack span{width:16px;border-radius:7px 7px 0 0;display:block;min-height:3px}.rp-bar-income{background:#2563eb}.rp-bar-mora{background:#f59e0b}.rp-bar-expense{background:#ef4444}.rp-bar-balance{background:#16a34a}.rp-chart-month small{font-size:12px;color:#64748b;white-space:nowrap}.rp-chart-legend{display:flex;gap:16px;align-items:center;justify-content:center;margin-top:12px;color:#475569;font-size:13px}.rp-chart-legend span{display:inline-flex;align-items:center;gap:6px}.rp-chart-legend span::before{content:'';width:10px;height:10px;border-radius:50%;display:inline-block}.rp-chart-legend span:nth-child(1)::before{background:#2563eb}.rp-chart-legend span:nth-child(2)::before{background:#f59e0b}.rp-chart-legend span:nth-child(3)::before{background:#ef4444}.rp-chart-legend span:nth-child(4)::before{background:#16a34a}.rp-year-table{overflow:auto}.rp-expense-table td,.rp-expense-table th{vertical-align:top}.rp-dashboard-kpis{grid-template-columns:repeat(6,minmax(0,1fr))}
@media(max-width:1180px){.rp-income-kpis{grid-template-columns:repeat(2,minmax(0,1fr))}.rp-dashboard-kpis{grid-template-columns:repeat(3,minmax(0,1fr))}.rp-income-grid{grid-template-columns:1fr}.rp-chart-bars{gap:8px}.rp-chart-stack span{width:12px}}
@media(max-width:720px){.rp-income-kpis,.rp-dashboard-kpis,.rp-mini-kpis{grid-template-columns:1fr!important}.rp-chart-bars{height:210px;overflow-x:auto;align-items:end}.rp-chart-month{min-width:62px}.rp-income-grid{gap:12px}.rp-balance-lines strong{font-size:17px}}

/* v29: ficha paciente sin edición duplicada */
.rp-patient-data-edit-only .rp-card-title-row-clean{margin-bottom:14px!important}
.rp-patient-data-edit-only .rp-patient-edit-form{display:grid!important;margin-top:0!important;padding-top:0!important;border-top:0!important}
.rp-patient-data-edit-only .rp-icon-edit{display:none!important}

/* v30 integraciones: configuracion Google / WooCommerce / WhatsApp */
.rp-config-section .rp-prof-head{margin-bottom:16px!important}
.rp-config-form{display:block!important}
.rp-config-grid{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:18px!important;align-items:start!important}
.rp-config-card{padding:20px!important;display:flex!important;flex-direction:column!important;gap:12px!important}
.rp-config-card label{display:flex!important;flex-direction:column!important;gap:6px!important;font-size:13px!important;font-weight:500!important;color:#334155!important}
.rp-config-card input,.rp-config-card select,.rp-config-card textarea{width:100%!important;border:1px solid #dbe3ef!important;border-radius:10px!important;padding:10px 12px!important;min-height:40px!important;background:#fff!important;color:#111827!important;font-size:14px!important;box-sizing:border-box!important}
.rp-config-card textarea{min-height:74px!important;resize:vertical!important;line-height:1.45!important}
.rp-config-card code{font-size:12px!important;background:#f1f5f9!important;padding:3px 6px!important;border-radius:6px!important;white-space:normal!important;word-break:break-all!important}
.rp-config-wide{grid-column:1/-1!important}
.rp-config-title{display:flex!important;align-items:flex-start!important;gap:12px!important;margin-bottom:2px!important}
.rp-config-title h2{font-size:20px!important;line-height:1.2!important;margin:0!important;color:#0f172a!important;font-weight:650!important}
.rp-config-title p{font-size:13px!important;line-height:1.35!important;margin:4px 0 0!important;color:#64748b!important;font-weight:400!important}
.rp-config-icon{width:38px!important;height:38px!important;border-radius:12px!important;background:#eef9ff!important;color:#0b78aa!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;flex:0 0 38px!important}
.rp-config-icon svg{width:20px!important;height:20px!important;fill:none!important;stroke:currentColor!important}
.rp-config-status{margin-top:-2px!important}
.rp-status-pill{display:inline-flex!important;align-items:center!important;gap:7px!important;border-radius:999px!important;padding:5px 10px!important;font-size:12px!important;font-weight:600!important;border:1px solid transparent!important;width:max-content!important}
.rp-status-pill::before{content:'';width:7px;height:7px;border-radius:50%;background:currentColor;display:block}
.rp-status-ok{color:#157347!important;background:#eaf7ef!important;border-color:#c9ead6!important}
.rp-status-off{color:#9a3412!important;background:#fff7ed!important;border-color:#fed7aa!important}
.rp-config-card .rp-switch-row{flex-direction:row!important;align-items:center!important;gap:10px!important;background:#f8fafc!important;border:1px solid #e5e7eb!important;border-radius:10px!important;padding:10px 12px!important;margin:0!important}
.rp-config-card .rp-switch-row input[type="checkbox"]{width:16px!important;height:16px!important;min-height:16px!important;padding:0!important;flex:0 0 16px!important}
.rp-config-card .rp-switch-row span{font-size:13px!important;color:#334155!important;font-weight:500!important}
.rp-sticky-save{position:sticky!important;bottom:14px!important;z-index:20!important;margin-top:18px!important;display:flex!important;justify-content:flex-end!important;padding:12px!important;background:rgba(248,250,252,.88)!important;backdrop-filter:blur(10px)!important;border:1px solid #e5e7eb!important;border-radius:14px!important}
@media(max-width:760px){.rp-config-grid{grid-template-columns:1fr!important}.rp-config-wide{grid-column:auto!important}.rp-sticky-save{position:static!important}}


/* RP Psico v1.6.7 - disponibilidad visual dentro del calendario del paciente */
.rp-patient-calendar-grid .rp-day-cell{position:relative!important}
.rp-day-availability-dot{position:absolute!important;top:7px!important;right:7px!important;width:11px!important;height:11px!important;border-radius:999px!important;border:2px solid #fff!important;box-shadow:0 2px 6px rgba(15,23,42,.18)!important;background:#94a3b8!important;z-index:2!important}
.rp-day-availability-dot.is-on{background:#10b981!important}
.rp-day-availability-dot.is-off{background:#cbd5e1!important}
.rp-patient-date-pick.is-blocked{opacity:.72!important;cursor:pointer!important;background:#f8fafc!important;color:#94a3b8!important}
.rp-patient-date-pick.selected-unavailable{outline:2px solid #cbd5e1!important;background:#f1f5f9!important}
.rp-day-availability-panel{grid-column:1/-1!important;margin:8px 0 10px!important}
.rp-day-availability-card{display:flex!important;align-items:flex-start!important;gap:10px!important;border:1px solid #bfdbfe!important;background:#eff6ff!important;border-radius:12px!important;padding:10px 12px!important;color:#1e3a8a!important;font-size:13px!important;line-height:1.35!important}
.rp-day-availability-card.is-off{border-color:#e5e7eb!important;background:#f8fafc!important;color:#64748b!important}
.rp-day-availability-card strong{display:block!important;font-weight:650!important;color:inherit!important;margin:0 0 2px!important}
.rp-day-availability-card p{margin:0!important;color:inherit!important;font-size:13px!important;line-height:1.35!important}
.rp-day-availability-icon{width:14px!important;height:14px!important;border-radius:999px!important;display:inline-block!important;background:#10b981!important;margin-top:2px!important;box-shadow:0 0 0 4px rgba(16,185,129,.14)!important;flex:0 0 auto!important}
.rp-day-availability-card.is-off .rp-day-availability-icon{background:#cbd5e1!important;box-shadow:0 0 0 4px rgba(148,163,184,.16)!important}

/* RP Psico v1.6.8 - panel claro de rango disponible al tocar día */
.rp-calendar-day-info{display:flex!important;align-items:flex-start!important;gap:10px!important;margin:8px 0 10px!important;padding:10px 12px!important;border:1px solid #dbeafe!important;background:#eff6ff!important;border-radius:12px!important;color:#1e3a8a!important;font-size:13px!important;line-height:1.35!important}
.rp-calendar-day-info strong{display:block!important;margin:0 0 2px!important;font-weight:650!important;color:inherit!important}
.rp-calendar-day-info p{margin:0!important;color:inherit!important;font-size:13px!important;line-height:1.35!important}
.rp-calendar-day-info.is-off{border-color:#e5e7eb!important;background:#f8fafc!important;color:#64748b!important}
.rp-calendar-day-info .rp-day-availability-icon.is-neutral{background:#94a3b8!important;box-shadow:0 0 0 4px rgba(148,163,184,.16)!important}
.rp-calendar-day-info.has-day{animation:rpCalInfoPulse .22s ease-out both}
@keyframes rpCalInfoPulse{from{transform:translateY(-2px);opacity:.75}to{transform:translateY(0);opacity:1}}

/* RP Psico v2.1.5 - disponibilidad visible y panel no-cache */
.rp-calendar-day-info.is-on{border-color:#bbf7d0!important;background:#f0fdf4!important;color:#166534!important}
.rp-calendar-day-info.is-off{border-color:#e5e7eb!important;background:#f8fafc!important;color:#64748b!important}
.rp-calendar-day-info .rp-day-availability-icon.is-on{background:#10b981!important;box-shadow:0 0 0 4px rgba(16,185,129,.14)!important}
.rp-calendar-day-info .rp-day-availability-icon.is-off{background:#cbd5e1!important;box-shadow:0 0 0 4px rgba(148,163,184,.16)!important}
.rp-day-availability-panel{display:block!important;min-height:44px!important}
.rp-day-availability-card{width:100%!important;box-sizing:border-box!important}
.rp-preview-card.is-generated,.rp-preview-card.is-manual{position:relative!important}

/* RP Psico v2.1.6 - calendario sin cache visual, vencidos y emergencia */
.rp-patient-calendar-grid .rp-day-cell.is-past{
  opacity:.42!important;
  filter:grayscale(1)!important;
  background:#f1f5f9!important;
  color:#94a3b8!important;
  border-color:#e2e8f0!important;
  cursor:not-allowed!important;
}
.rp-patient-calendar-grid .rp-day-cell.is-past .rp-day-availability-dot{background:#cbd5e1!important;box-shadow:none!important}
.rp-patient-calendar-grid .rp-day-cell.is-blocked{opacity:.72!important;background:#f8fafc!important;color:#64748b!important}
.rp-patient-calendar-grid .rp-day-cell.is-free .rp-day-availability-dot{background:#10b981!important}
.rp-patient-calendar-grid .rp-day-cell.has-patients .rp-day-availability-dot{background:#0ea5e9!important}
.rp-calendar-day-info.is-off,.rp-day-availability-card.is-off{background:#f8fafc!important;border-color:#e5e7eb!important;color:#64748b!important}
.rp-form-grid label.rp-emergency-switch{
  background:#fef2f2!important;
  border:1px solid #fecaca!important;
  color:#b91c1c!important;
  font-weight:650!important;
}
.rp-form-grid label.rp-emergency-switch input[type="checkbox"]{accent-color:#dc2626!important}
.rp-form-grid label.rp-emergency-switch span{display:inline-flex!important;align-items:center!important;gap:8px!important;color:#b91c1c!important;font-weight:650!important}
.rp-form-grid label.rp-emergency-switch svg{width:18px!important;height:18px!important;min-width:18px!important;stroke:#dc2626!important}
.rp-form-grid label.rp-emergency-switch:has(input:checked){background:#fee2e2!important;border-color:#ef4444!important;box-shadow:0 0 0 3px rgba(220,38,38,.08)!important}

/* V42: ficha de paciente con páginas internas separadas */
.rp-patient-header-tabs{display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin:0 0 8px 0;width:100%}
.rp-patient-tab-btn{border:1px solid #dbe2ea;background:#fff;color:#26303a;border-radius:10px;padding:9px 12px;display:inline-flex;align-items:center;gap:8px;font-size:13px;font-weight:500;cursor:pointer;line-height:1.1;transition:.18s ease}
.rp-patient-tab-btn svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;flex:0 0 17px}
.rp-patient-tab-btn:hover,.rp-patient-tab-btn.active{background:#0f6fff;color:#fff;border-color:#0f6fff}
.rp-patient-subpage-card{display:none!important}
.rp-patient-subpage-card.active{display:block!important;width:100%;max-width:100%}
.rp-patient-subpage-mode .rp-detail-grid,
.rp-patient-subpage-mode .rp-patient-schedule-card,
.rp-patient-subpage-mode .rp-patient-calendar-below,
.rp-patient-subpage-mode .rp-detail-columns:not(.rp-subpage-columns-holder){display:none!important}
.rp-patient-subpage-mode .rp-subpage-columns-holder{display:block!important;width:100%;max-width:1120px;margin:18px auto 0 auto}
.rp-patient-subpage-mode .rp-subpage-columns-holder .rp-detail-card:not(.active){display:none!important}
.rp-patient-subpage-mode .rp-detail-hero{margin-bottom:12px}
.rp-patient-subpage-mode .rp-next-banner{display:none!important}
.rp-patient-subpage-card h3{font-size:22px!important;margin-bottom:16px!important}
@media(max-width:760px){.rp-patient-header-tabs{gap:6px}.rp-patient-tab-btn{padding:8px 10px;font-size:12px}.rp-patient-tab-btn svg{width:16px;height:16px}}

.rp-session-chip{border:1px solid #e5e7eb;border-radius:14px;padding:10px 12px;margin:8px 0;background:#fff}
.rp-session-date{font-size:12px;font-weight:600}
.rp-session-meta,.rp-session-amount{font-size:11px;opacity:.8}
.rp-session-status{display:inline-block;font-size:11px;padding:3px 8px;border-radius:999px;background:#f3f4f6;margin:4px 0}

/* V44: historial de sesiones y cancelaciones más horizontal y compacto */
.rp-detail-card .rp-session-chip{
  display:grid!important;
  grid-template-columns:minmax(92px, .85fr) minmax(95px, .9fr) auto minmax(70px,.55fr) auto auto!important;
  align-items:center!important;
  gap:8px 10px!important;
  padding:8px 10px!important;
  margin:7px 0!important;
  border-radius:12px!important;
  min-height:0!important;
}
.rp-session-date{
  font-size:11px!important;
  font-weight:650!important;
  color:#243242!important;
  line-height:1.15!important;
  white-space:nowrap!important;
}
.rp-session-meta,.rp-session-amount{
  font-size:11px!important;
  line-height:1.15!important;
  opacity:.82!important;
  white-space:nowrap!important;
}
.rp-session-status{
  font-size:10px!important;
  padding:3px 7px!important;
  margin:0!important;
  line-height:1!important;
  white-space:nowrap!important;
}
.rp-detail-card .rp-session-chip .rp-mini-action,
.rp-detail-card .rp-session-chip .rp-inline-cancel-form button{
  font-size:11px!important;
  padding:5px 8px!important;
  border-radius:9px!important;
  line-height:1.1!important;
  white-space:nowrap!important;
}
.rp-detail-card .rp-session-chip .rp-inline-cancel-form{margin:0!important;display:inline-flex!important;align-items:center!important}
.rp-cancel-card-list{display:grid!important;gap:7px!important;margin-top:8px!important}
.rp-cancel-chip{
  display:grid!important;
  grid-template-columns:minmax(92px,.85fr) minmax(90px,.9fr) auto minmax(65px,.55fr)!important;
  align-items:center!important;
  gap:8px 10px!important;
  border:1px solid #e5e7eb!important;
  border-radius:12px!important;
  background:#fff!important;
  padding:8px 10px!important;
}
.rp-cancel-date{font-size:11px!important;font-weight:650!important;color:#243242!important;line-height:1.15!important;white-space:nowrap!important}
.rp-cancel-time,.rp-cancel-amount{font-size:11px!important;opacity:.82!important;white-space:nowrap!important;line-height:1.15!important}
.rp-cancel-status{font-size:10px!important;padding:3px 7px!important;border-radius:999px!important;background:#fef2f2!important;color:#b42318!important;border:1px solid #fecaca!important;white-space:nowrap!important;line-height:1!important}
@media(max-width:900px){
  .rp-detail-card .rp-session-chip{grid-template-columns:1fr 1fr auto!important}
  .rp-session-status,.rp-session-amount{justify-self:start!important}
  .rp-detail-card .rp-session-chip .rp-inline-cancel-form{grid-column:auto!important}
  .rp-cancel-chip{grid-template-columns:1fr 1fr auto!important}
}
@media(max-width:560px){
  .rp-detail-card .rp-session-chip,.rp-cancel-chip{grid-template-columns:1fr 1fr!important;gap:7px!important}
  .rp-detail-card .rp-session-chip .rp-mini-action,
  .rp-detail-card .rp-session-chip .rp-inline-cancel-form{width:100%!important}
  .rp-detail-card .rp-session-chip .rp-inline-cancel-form button{width:100%!important}
}

/* v45 dashboard próximo paciente */
.rp-next-dashboard-card{overflow:visible}
.rp-next-patient-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin:14px 0 16px}
.rp-next-patient-grid>div{border:1px solid #E4EAF2;background:#fff;background-image:none;border-radius:14px;padding:12px;color:#102A56}
.rp-next-patient-grid small{display:flex;align-items:center;gap:6px;color:#102A56;font-size:12px;margin-bottom:4px;font-weight:400}
.rp-next-patient-grid strong{display:block;color:#102A56;font-size:15px;font-weight:600}
.rp-next-actions{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.rp-next-actions .rp-inline-cancel-form{display:inline-flex;margin:0}
.rp-btn-danger,.rp-next-actions .rp-btn-danger{background:#d94141!important;color:#fff!important;border-color:#d94141!important}
@media(max-width:900px){.rp-next-patient-grid{grid-template-columns:1fr 1fr}}
@media(max-width:620px){.rp-next-patient-grid{grid-template-columns:1fr}.rp-next-actions{flex-direction:column;align-items:stretch}.rp-next-actions .rp-btn,.rp-next-actions .rp-inline-cancel-form,.rp-next-actions button{width:100%;justify-content:center}}

/* v67 Dashboard pago automático */
.rp-dashboard-payment-modal{position:fixed;inset:0;z-index:999999;background:rgba(15,23,42,.46);display:none;align-items:center;justify-content:center;padding:18px;backdrop-filter:blur(3px)}
.rp-dashboard-payment-modal.active{display:flex}
.rp-dashboard-payment-box{width:min(440px,100%);background:#fff;border-radius:18px;padding:22px;box-shadow:0 24px 70px rgba(15,23,42,.28);position:relative;color:#263849}
.rp-dashboard-payment-box small{display:inline-flex;margin-bottom:8px;padding:5px 9px;border-radius:999px;background:#eef8fb;color:#0b7fab;font-weight:800;font-size:12px}
.rp-dashboard-payment-box h3{margin:0 0 8px;font-size:22px;color:#172431}
.rp-dashboard-payment-box p{margin:0 0 18px;line-height:1.45;color:#475569}
.rp-dashboard-payment-close{position:absolute;top:10px;right:12px;border:0;background:transparent;font-size:26px;line-height:1;cursor:pointer;color:#64748b}
.rp-dashboard-payment-actions{display:flex;gap:10px;justify-content:flex-end;flex-wrap:wrap}
@media(max-width:640px){.rp-dashboard-payment-box{padding:19px;border-radius:16px}.rp-dashboard-payment-actions .rp-btn{width:100%;justify-content:center}}


/* v68 fix popup pago dashboard */
.rp-modal .rp-btn-confirm,
.rp-payment-popup .rp-btn-confirm,
button.rp-btn-confirm{
background:#f4b400 !important;
color:#111111 !important;
border:2px solid #f4b400 !important;
font-weight:700 !important;
opacity:1 !important;
}

.rp-modal .rp-btn-confirm:hover,
.rp-payment-popup .rp-btn-confirm:hover,
button.rp-btn-confirm:hover{
color:#111111 !important;
}

.rp-modal .rp-btn-cancel,
.rp-payment-popup .rp-btn-cancel,
button.rp-btn-cancel{
background:#ffffff !important;
color:#333333 !important;
border:2px solid #dcdcdc !important;
}

.rp-modal .rp-btn-confirm,
.rp-modal .rp-btn-cancel,
.rp-payment-popup .rp-btn-confirm,
.rp-payment-popup .rp-btn-cancel{
min-height:44px;
padding:10px 18px;
border-radius:8px;
}

/* v71 Mora */
.rp-filter-inline select{border:1px solid var(--rp-border);border-radius:10px;padding:10px 12px;min-height:42px;background:#fff;color:var(--rp-text)}
.rp-mora-table-card{margin-top:18px}.rp-mora-table td,.rp-mora-table th{vertical-align:top}.rp-mora-table small{display:block;color:var(--rp-muted);font-size:12px;margin-top:3px}.rp-mora-actions{display:flex;gap:8px;flex-wrap:wrap}.rp-mora-actions form{margin:0}.rp-mora-kpis{grid-template-columns:repeat(3,minmax(0,1fr))}
@media(max-width:760px){.rp-mora-kpis{grid-template-columns:1fr}.rp-mora-actions{display:grid;grid-template-columns:1fr}.rp-mora-actions .rp-btn{width:100%}}

.rp-saved-warning{background:#fff7e6!important;border-color:#f1d38a!important;color:#7a5a00!important}

/* V90: confirmar turnos pendientes desde historial de sesiones */
.rp-inline-confirm-form{display:inline-flex!important;margin:0!important;padding:0!important}
.rp-confirm-pending-session{background:#ecfdf5!important;color:#047857!important;border-color:#a7f3d0!important}
.rp-confirm-pending-session:hover{background:#047857!important;color:#fff!important;border-color:#047857!important}




/* RP Psico - Calendario General profesional */
.rp-general-calendar-layout{display:grid;grid-template-columns:minmax(360px,1.05fr) minmax(360px,.95fr);gap:18px;align-items:start}
.rp-general-calendar-grid .rp-day-cell{text-decoration:none;display:block}
.rp-general-calendar-grid .rp-day-cell.selected{border-color:var(--rp-blue)!important;box-shadow:0 0 0 3px rgba(11,120,170,.12)}
.rp-general-calendar-grid .rp-day-cell.has-blocks{background:#fff8e6;border-color:#f0cf7a}
.rp-general-day-card h2{margin:0 0 12px;font-size:24px;text-transform:capitalize}
.rp-general-day-card h3{margin:18px 0 10px;font-size:18px}
.rp-general-availability{background:#f8fbfd;border:1px solid var(--rp-border);border-radius:14px;padding:14px;margin-bottom:14px}
.rp-general-availability strong{display:block;margin-bottom:5px}
.rp-general-availability p{margin:0;color:var(--rp-muted);line-height:1.45}
.rp-general-appointments{display:grid;gap:10px}
.rp-general-appt{border:1px solid var(--rp-border);border-radius:14px;padding:13px;background:#fff}
.rp-general-appt.is-block{background:#fffaf0;border-color:#f0cf7a}
.rp-general-appt>div:first-child{display:flex;justify-content:space-between;gap:10px;align-items:center;margin-bottom:7px}
.rp-general-appt strong{font-size:16px}
.rp-general-appt span{font-size:12px;color:var(--rp-muted);font-weight:700;text-transform:uppercase}
.rp-general-appt p{margin:0;color:var(--rp-muted);line-height:1.45}
.rp-general-block-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:10px;align-items:center}
.rp-general-block-form{margin-top:18px;border-top:1px solid var(--rp-border);padding-top:14px}
@media(max-width:760px){.rp-general-calendar-layout{grid-template-columns:1fr}.rp-general-calendar-grid.rp-admin-calendar{grid-template-columns:repeat(7,minmax(40px,1fr))}.rp-general-calendar-grid .rp-day-cell{min-height:66px;padding:7px}.rp-general-calendar-grid .rp-day-cell strong{font-size:15px}.rp-general-calendar-grid .rp-day-cell em,.rp-general-calendar-grid .rp-day-cell span{display:none}.rp-general-appt>div:first-child{display:block}}

/* v104 Calendario General: layout aislado, sin superposición y sin depender del CSS viejo */
.rp-general-calendar-section,
.rp-general-calendar-section *{box-sizing:border-box}
.rp-general-calendar-section{overflow:hidden!important;max-width:100%!important}
.rp-general-calendar-layout{display:grid!important;grid-template-columns:minmax(0,1fr) minmax(320px,420px)!important;gap:22px!important;align-items:start!important;width:100%!important;max-width:100%!important;overflow:visible!important}
.rp-general-month-card,.rp-general-day-card{min-width:0!important;width:100%!important;max-width:100%!important;overflow:hidden!important}
.rp-general-month-card .rp-calendar-title{display:grid!important;grid-template-columns:42px minmax(0,1fr) 42px!important;gap:10px!important;align-items:center!important;margin-bottom:14px!important}
.rp-general-month-card .rp-calendar-title>div{min-width:0!important;text-align:left!important;display:block!important;overflow:hidden!important}
.rp-general-month-card .rp-calendar-title strong{display:block!important;font-size:22px!important;line-height:1.15!important;white-space:normal!important;text-transform:lowercase!important}
.rp-general-month-card .rp-calendar-title span{display:block!important;margin-top:3px!important;white-space:normal!important;line-height:1.25!important;overflow:visible!important;text-overflow:clip!important}
.rp-general-calendar-grid.rp-admin-calendar{display:grid!important;grid-template-columns:repeat(7,minmax(0,1fr))!important;gap:8px!important;width:100%!important;max-width:100%!important;min-width:0!important;overflow:hidden!important}
.rp-general-calendar-grid .rp-day-cell{min-width:0!important;min-height:106px!important;padding:10px!important;overflow:hidden!important;word-break:normal!important}
.rp-general-calendar-grid .rp-day-cell strong{font-size:18px!important;margin-bottom:8px!important}
.rp-general-calendar-grid .rp-day-cell span,
.rp-general-calendar-grid .rp-day-cell em{max-width:100%!important;white-space:normal!important;line-height:1.25!important;overflow:hidden!important;text-overflow:ellipsis!important}
.rp-general-calendar-grid .rp-day-cell.is-blocked{background:#f8fafc!important;border-color:#e4e7ec!important;color:#667085!important}
.rp-general-calendar-grid .rp-day-cell.has-blocks{background:#fff7e6!important;border-color:#f0c05a!important;color:#5f4300!important}
.rp-general-day-card{position:relative!important;z-index:1!important}
.rp-general-day-card .rp-form-grid.rp-compact-form{grid-template-columns:repeat(2,minmax(0,1fr))!important}
.rp-general-day-card .rp-form-grid .full{grid-column:1/-1!important}
@media(max-width:1400px){.rp-general-calendar-layout{grid-template-columns:1fr!important}.rp-general-day-card{margin-top:0!important}.rp-general-calendar-grid .rp-day-cell{min-height:92px!important}.rp-general-month-card .rp-calendar-title strong{font-size:21px!important}}
@media(max-width:760px){.rp-general-calendar-grid.rp-admin-calendar{gap:5px!important}.rp-general-calendar-grid .rp-day-cell{min-height:64px!important;padding:6px!important;border-radius:9px!important}.rp-general-calendar-grid .rp-day-cell strong{font-size:14px!important;margin-bottom:0!important}.rp-general-calendar-grid .rp-day-cell span,.rp-general-calendar-grid .rp-day-cell em{display:none!important}.rp-general-day-card .rp-form-grid.rp-compact-form{grid-template-columns:1fr!important}.rp-general-month-card .rp-calendar-title{grid-template-columns:36px minmax(0,1fr) 36px!important}.rp-general-month-card .rp-calendar-title span{display:none!important}}

/* v109 Historia clínica móvil: fecha visible completa, sin recortes en iPhone */
.rp-history-search-card,
.rp-history-filters,
.rp-history-filter-field{
  overflow:visible!important;
}
.rp-history-filter-field input[type="date"],
.rp-history-filters input[type="date"]{
  display:block!important;
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  height:58px!important;
  min-height:58px!important;
  line-height:58px!important;
  padding:0 14px!important;
  border:1px solid var(--rp-border)!important;
  border-radius:14px!important;
  background:#fff!important;
  color:var(--rp-text)!important;
  box-sizing:border-box!important;
  -webkit-appearance:none!important;
  appearance:none!important;
  overflow:visible!important;
}
.rp-history-filter-field input[type="date"]::-webkit-date-and-time-value{
  min-height:58px!important;
  line-height:58px!important;
  text-align:left!important;
  padding:0!important;
  margin:0!important;
}
.rp-history-filter-field input[type="date"]::-webkit-calendar-picker-indicator{
  opacity:.65!important;
  margin-right:0!important;
}
@media(max-width:520px){
  .rp-history-search-card{padding:16px!important;overflow:visible!important}
  .rp-history-filters{overflow:visible!important}
  .rp-history-filter-field{overflow:visible!important}
  .rp-history-filter-field input[type="date"],
  .rp-history-filters input[type="date"]{
    height:60px!important;
    min-height:60px!important;
    line-height:60px!important;
    padding:0 14px!important;
    border-radius:14px!important;
  }
  .rp-history-filter-field input[type="date"]::-webkit-date-and-time-value{
    min-height:60px!important;
    line-height:60px!important;
  }
}

/* RP v110 - menú móvil full screen */
@media (max-width:760px){
  .rp-prof-sidebar,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar{
    position:sticky;
    top:0;
    z-index:9999;
  }
  .rp-sidebar-toggle{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:42px!important;
    height:42px!important;
    min-width:42px!important;
    min-height:42px!important;
    margin-left:auto!important;
    padding:0!important;
    border:0!important;
    background:transparent!important;
    box-shadow:none!important;
    border-radius:0!important;
    color:#263445!important;
    font-size:26px!important;
    line-height:1!important;
    text-align:center!important;
    appearance:none!important;
    -webkit-appearance:none!important;
  }
  .rp-sidebar-toggle:focus,
  .rp-sidebar-toggle:active{
    outline:none!important;
    background:transparent!important;
    box-shadow:none!important;
  }
  .rp-prof-sidebar.mobile-open{
    position:fixed!important;
    inset:0!important;
    width:100vw!important;
    height:100vh!important;
    max-width:none!important;
    max-height:none!important;
    padding:22px!important;
    background:rgba(248,251,253,.98)!important;
    backdrop-filter:blur(16px)!important;
    -webkit-backdrop-filter:blur(16px)!important;
    z-index:2147483000!important;
    overflow-y:auto!important;
    display:flex!important;
    flex-direction:column!important;
  }
  .rp-prof-sidebar.mobile-open .rp-prof-brand{
    position:sticky!important;
    top:0!important;
    z-index:2!important;
    display:flex!important;
    align-items:center!important;
    gap:12px!important;
    margin:0 0 22px!important;
    padding:0 0 18px!important;
    background:transparent!important;
    border-bottom:1px solid rgba(15,23,42,.08)!important;
  }
  .rp-prof-sidebar.mobile-open .rp-sidebar-toggle{
    font-size:0!important;
  }
  .rp-prof-sidebar.mobile-open .rp-sidebar-toggle::before{
    content:'×';
    font-size:36px!important;
    line-height:1!important;
    font-weight:300!important;
    color:#263445!important;
  }
  .rp-prof-sidebar.mobile-open a{
    display:flex!important;
    width:100%!important;
    min-height:58px!important;
    height:auto!important;
    margin:5px 0!important;
    padding:0 18px!important;
    border-radius:18px!important;
    background:#fff!important;
    border:1px solid rgba(15,23,42,.08)!important;
    box-shadow:0 10px 24px rgba(15,23,42,.05)!important;
    justify-content:flex-start!important;
    gap:14px!important;
    font-size:17px!important;
  }
  .rp-prof-sidebar.mobile-open a.active{
    background:#e9f5fb!important;
    border-color:#bfe4f1!important;
    color:#075b82!important;
  }
  .rp-prof-sidebar.mobile-open .rp-nav-label{
    display:inline-block!important;
    opacity:1!important;
    width:auto!important;
    max-width:none!important;
    font-size:17px!important;
    font-weight:600!important;
  }
  body.rp-mobile-menu-lock{
    overflow:hidden!important;
    touch-action:none!important;
  }
}


/* RP v111 - menú móvil realmente fuera del contenedor */
@media (max-width:760px){
  html.rp-mobile-menu-lock,
  body.rp-mobile-menu-lock{
    overflow:hidden!important;
    height:100%!important;
    touch-action:none!important;
  }
  body > .rp-prof-sidebar.mobile-open{
    position:fixed!important;
    top:0!important;
    left:0!important;
    right:0!important;
    bottom:0!important;
    inset:0!important;
    width:100vw!important;
    height:100vh!important;
    height:100dvh!important;
    max-width:none!important;
    max-height:none!important;
    min-width:100vw!important;
    margin:0!important;
    padding:calc(18px + env(safe-area-inset-top)) 18px calc(24px + env(safe-area-inset-bottom))!important;
    border-radius:0!important;
    transform:none!important;
    background:#f8fbfd!important;
    z-index:2147483647!important;
    overflow-y:auto!important;
    -webkit-overflow-scrolling:touch!important;
    box-sizing:border-box!important;
  }
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand{
    position:relative!important;
    top:auto!important;
    width:100%!important;
    min-height:58px!important;
    padding:0 0 16px!important;
    margin:0 0 18px!important;
    background:#f8fbfd!important;
  }
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand strong{
    display:block!important;
    opacity:1!important;
    width:auto!important;
    max-width:calc(100vw - 130px)!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    white-space:nowrap!important;
  }
  body > .rp-prof-sidebar.mobile-open a{
    display:flex!important;
    width:100%!important;
    max-width:none!important;
    min-height:62px!important;
    height:auto!important;
    box-sizing:border-box!important;
  }
}

/* RP Psico v1.12.0 - fix calendario paciente móvil: evitar corte horizontal */
@media (max-width: 760px){
  .rp-patient-calendar-below,
  .rp-patient-calendar-picker,
  .rp-vbz-calendar-wrap{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
    overflow:visible!important;
  }
  .rp-patient-calendar-below .rp-vbz-calendar-wrap,
  .rp-vbz-calendar-wrap{
    padding:8px!important;
  }
  .rp-patient-calendar-grid.rp-admin-calendar,
  .rp-patient-calendar-grid{
    display:grid!important;
    grid-template-columns:repeat(7,minmax(0,1fr))!important;
    gap:4px!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
  }
  .rp-patient-calendar-grid .rp-day-cell{
    min-width:0!important;
    width:auto!important;
    max-width:100%!important;
    min-height:58px!important;
    padding:4px!important;
    border-radius:9px!important;
    box-sizing:border-box!important;
  }
  .rp-patient-calendar-grid .rp-day-cell strong{
    min-width:20px!important;
    width:20px!important;
    height:20px!important;
    font-size:11px!important;
    border-radius:999px!important;
    margin-bottom:3px!important;
  }
  .rp-turno-bubbles{
    gap:2px!important;
    width:100%!important;
    max-width:100%!important;
    overflow:hidden!important;
  }
  .rp-turno-bubble{
    min-width:0!important;
    width:100%!important;
    max-width:100%!important;
    height:17px!important;
    padding:0 2px!important;
    font-size:8px!important;
    border-radius:999px!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:clip!important;
  }
  .rp-calendar-day-info,
  .rp-day-availability-card{
    width:100%!important;
    max-width:100%!important;
    box-sizing:border-box!important;
  }
}

@media (max-width: 390px){
  .rp-patient-calendar-grid.rp-admin-calendar,
  .rp-patient-calendar-grid{gap:3px!important;}
  .rp-patient-calendar-grid .rp-day-cell{min-height:54px!important;padding:3px!important;border-radius:8px!important;}
  .rp-patient-calendar-grid .rp-day-cell strong{width:18px!important;min-width:18px!important;height:18px!important;font-size:10px!important;}
}

/* RP Psico v2.4.7 - encabezado de días visible en calendario paciente móvil */
@media(max-width:760px){
  .rp-patient-calendar-below .rp-calendar-weekdays,
  .rp-vbz-calendar-wrap .rp-calendar-weekdays{
    display:grid!important;
    grid-template-columns:repeat(7,minmax(0,1fr))!important;
    gap:5px!important;
    margin:4px 0 6px!important;
    padding:0!important;
    width:100%!important;
    box-sizing:border-box!important;
  }
  .rp-patient-calendar-below .rp-calendar-weekdays span,
  .rp-vbz-calendar-wrap .rp-calendar-weekdays span{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    min-width:0!important;
    height:22px!important;
    font-size:11px!important;
    line-height:1!important;
    font-weight:700!important;
    color:#667085!important;
    text-align:center!important;
    overflow:hidden!important;
  }
}

/* v114 - Modalidades de atención en disponibilidad */
.rp-modalities .rp-muted-small{margin:4px 0 10px!important;color:var(--rp-muted,#64748b)!important;font-size:13px!important;line-height:1.35!important;font-weight:500!important}
.rp-modalities label{align-items:center!important}

/* v116 - Disponibilidad mobile: time selectors dentro del contenedor */
@media (max-width: 760px){
  .rp-availability-card,
  .rp-availability-card *{
    box-sizing:border-box!important;
  }
  .rp-availability-card{
    overflow:hidden!important;
  }
  .rp-availability-card .rp-availability-form,
  .rp-availability-form.rp-form-grid{
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:14px!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
  }
  .rp-availability-form label,
  .rp-availability-form .rp-break-field,
  .rp-availability-form .rp-switch-row,
  .rp-availability-form .full{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    grid-column:1/-1!important;
  }
  .rp-availability-form input:not([type="checkbox"]):not([type="radio"]),
  .rp-availability-form select,
  .rp-availability-form textarea{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
    display:block!important;
  }
  .rp-availability-form input[type="time"],
  .rp-availability-form .rp-break-field input[type="time"]{
    appearance:none!important;
    -webkit-appearance:none!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    height:58px!important;
    min-height:58px!important;
    line-height:58px!important;
    padding:0 14px!important;
    text-align:center!important;
    font-size:17px!important;
    border-radius:12px!important;
  }
  .rp-availability-form .rp-checks,
  .rp-availability-form .rp-workdays,
  .rp-availability-form .rp-modalities{
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:10px!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
  }
  .rp-availability-form .rp-checks strong,
  .rp-availability-form .rp-checks p{
    grid-column:1/-1!important;
  }
  .rp-availability-form .rp-checks label{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
  }
  .rp-availability-form .rp-btn{
    width:100%!important;
    max-width:100%!important;
  }
}

@media (max-width: 390px){
  .rp-availability-form .rp-checks,
  .rp-availability-form .rp-workdays,
  .rp-availability-form .rp-modalities{
    grid-template-columns:1fr!important;
  }
}

/* v118 - Dashboard notificaciones: campana limpia + papelera visible */
.rp-dashboard-notifications-card{
  margin-top:18px;
}
.rp-dashboard-notifications-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-bottom:14px;
}
.rp-dashboard-notifications-head h2{
  display:flex;
  align-items:center;
  gap:10px;
  margin:0;
}
.rp-bell-icon{
  width:auto;
  height:auto;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:0;
  background:transparent!important;
  color:#0f83b6;
  box-shadow:none!important;
  padding:0;
  position:relative;
  flex:0 0 auto;
}
.rp-bell-icon svg{
  display:block;
  width:25px;
  height:25px;
}
.rp-notification-badge{
  min-width:30px;
  height:30px;
  padding:0 9px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border-radius:999px;
  background:#0f83b6;
  color:#fff;
  font-weight:800;
  font-size:14px;
}
.rp-dashboard-notifications-list{
  display:grid;
  gap:12px;
}
.rp-dashboard-notification-item{
  display:grid;
  grid-template-columns:minmax(180px,1.2fr) minmax(240px,1.4fr) auto;
  gap:14px;
  align-items:center;
  padding:14px;
  border:1px solid rgba(15,131,182,.16);
  background:#fff;
  border-radius:18px;
  box-shadow:0 10px 26px rgba(15,23,42,.05);
}
.rp-dashboard-notification-main strong{
  display:block;
  font-size:17px;
  color:#182236;
  line-height:1.25;
}
.rp-dashboard-notification-main span{
  display:block;
  margin-top:4px;
  color:#6b768c;
  font-weight:700;
}
.rp-dashboard-notification-meta{
  display:grid;
  gap:5px;
  color:#526176;
  font-size:14px;
}
.rp-dashboard-notification-actions{
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:8px;
}
.rp-notification-profile-btn{
  display:inline-flex!important;
  align-items:center;
  gap:7px;
  white-space:nowrap;
}
.rp-notification-delete-form{
  margin:0;
}
.rp-icon-trash-btn{
  width:40px!important;
  min-width:40px!important;
  height:40px!important;
  min-height:40px!important;
  padding:0!important;
  border:0!important;
  border-radius:12px!important;
  background:#d43b3b!important;
  color:#fff!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  cursor:pointer;
  line-height:1!important;
  appearance:none;
  -webkit-appearance:none;
}
.rp-icon-trash-btn svg{
  display:block!important;
  width:19px!important;
  height:19px!important;
  min-width:19px!important;
  color:#fff!important;
  stroke:#fff!important;
  opacity:1!important;
  visibility:visible!important;
}
.rp-icon-trash-btn svg path{
  stroke:#fff!important;
}
.rp-icon-trash-btn:hover{
  background:#b92f2f!important;
  color:#fff!important;
}
@media (max-width: 900px){
  .rp-dashboard-notification-item{
    grid-template-columns:1fr;
    align-items:start;
  }
  .rp-dashboard-notification-actions{
    justify-content:flex-start;
  }
}
@media (max-width: 520px){
  .rp-dashboard-notifications-card{
    margin-top:16px;
  }
  .rp-dashboard-notifications-head h2{
    font-size:24px;
  }
  .rp-bell-icon{
    width:auto;
    height:auto;
    border-radius:0;
  }
  .rp-dashboard-notification-item{
    padding:13px;
    border-radius:16px;
    gap:10px;
  }
  .rp-dashboard-notification-main strong{
    font-size:16px;
  }
  .rp-dashboard-notification-actions{
    width:100%;
  }
  .rp-notification-profile-btn{
    flex:1;
    justify-content:center;
  }
}

/* v126 - Notificaciones: sesiones pendientes a confirmar */
.rp-dashboard-session-notification .rp-dashboard-notification-meta{
  grid-template-columns:1fr;
}
.rp-notification-confirm-form{
  margin:0;
}
.rp-notification-confirm-btn{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:7px!important;
  white-space:nowrap!important;
  background:#16a36b!important;
  border-color:#16a36b!important;
  color:#fff!important;
}
.rp-notification-confirm-btn svg{
  display:block!important;
  color:#fff!important;
  stroke:#fff!important;
}
.rp-notification-confirm-btn:hover{
  background:#118858!important;
  border-color:#118858!important;
  color:#fff!important;
}
@media (max-width: 520px){
  .rp-notification-confirm-form{
    width:100%;
  }
  .rp-notification-confirm-btn{
    width:100%!important;
  }
}

/* v129: popup sesión activa solo visible luego de 10 minutos + botón pagada visible */
.rp-dashboard-payment-actions [data-rp-pay-yes],
.rp-dashboard-payment-actions .rp-btn[data-rp-pay-yes]{
    background:#263849 !important;
    color:#ffffff !important;
    border-color:#263849 !important;
    box-shadow:none !important;
}
.rp-dashboard-payment-actions [data-rp-pay-yes]:hover,
.rp-dashboard-payment-actions .rp-btn[data-rp-pay-yes]:hover{
    background:#172431 !important;
    color:#ffffff !important;
    border-color:#172431 !important;
}

/* v130: cuenta regresiva próximo paciente */
.rp-next-countdown{
  display:flex;
  align-items:center;
  gap:12px;
  flex-wrap:wrap;
  background:#eef8fb;
  border:1px solid #cfeaf4;
  color:#17324d;
  border-radius:16px;
  padding:12px 14px;
  margin:12px 0 14px;
}
.rp-next-countdown small{
  color:#0b6688;
  font-weight:800;
  font-size:13px;
}
.rp-next-countdown strong{
  font-size:24px;
  line-height:1;
  font-weight:900;
  color:#0b7fab;
  background:#fff;
  border:1px solid #d9edf5;
  border-radius:12px;
  padding:8px 12px;
}
.rp-next-countdown span{
  flex:1 1 240px;
  color:#64748b;
  font-size:13px;
  line-height:1.35;
}
@media(max-width:620px){
  .rp-next-countdown{align-items:flex-start;flex-direction:column;gap:8px;}
  .rp-next-countdown strong{width:100%;text-align:center;box-sizing:border-box;}
}

/* v136: contador flotante de sesión en curso */
.rp-session-floating{
  position:fixed;
  right:22px;
  bottom:22px;
  width:min(360px,calc(100vw - 28px));
  background:#fff;
  border:1px solid #dbe6ee;
  border-radius:18px;
  box-shadow:0 22px 55px rgba(15,23,42,.22);
  padding:16px;
  z-index:999998;
  color:#172431;
  opacity:0;
  pointer-events:none;
  transform:translateY(14px);
  transition:opacity .2s ease,transform .2s ease;
}
.rp-session-floating.show{opacity:1;pointer-events:auto;transform:translateY(0)}
.rp-session-floating-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:8px}
.rp-session-floating-head span{display:inline-flex;padding:5px 10px;border-radius:999px;background:#eef8fb;color:#0b7fab;font-size:12px;font-weight:800}
.rp-session-floating-head button{border:0;background:transparent;color:#64748b;font-size:24px;line-height:1;cursor:pointer;padding:0 4px}
.rp-session-floating strong{display:block;font-size:34px;line-height:1.05;color:#0b7fab;margin-bottom:6px}
.rp-session-floating p{margin:0 0 14px;color:#475569;font-size:14px;line-height:1.35}
.rp-session-floating-actions{display:flex;gap:9px;flex-wrap:wrap;justify-content:flex-end}
@media(max-width:640px){
  .rp-session-floating{right:12px;left:12px;bottom:14px;width:auto;border-radius:16px}
  .rp-session-floating-actions .rp-btn{flex:1;min-width:140px}
}

/* RP Psico v2.6.4 - sesiones atendidas: no reprogramables */
.rp-session-chip.is-attended .rp-reprogram-session.is-disabled,
.rp-mini-action.is-disabled:disabled{
  opacity:.45!important;
  cursor:not-allowed!important;
  pointer-events:none!important;
  background:#eef2f7!important;
  color:#8a94a6!important;
  border-color:#d7dee8!important;
  box-shadow:none!important;
}
.rp-session-chip.is-attended{background:#fbfcfd!important;}

/* v139: botones visibles en contador flotante y soporte de sesiones cortas reales */
.rp-session-floating .rp-session-floating-actions .rp-btn,
.rp-session-floating .rp-session-floating-actions button{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    min-height:40px;
    border-radius:12px;
    font-weight:800;
    text-decoration:none;
    opacity:1;
}
.rp-session-floating .rp-session-floating-actions [data-rp-session-finish]{
    background:#0b7fab !important;
    color:#fff !important;
    border:1px solid #0b7fab !important;
    box-shadow:0 8px 20px rgba(11,127,171,.18);
}
.rp-session-floating .rp-session-floating-actions [data-rp-session-hide-btn]{
    background:#eef8fb !important;
    color:#0b5f7c !important;
    border:1px solid #d7edf5 !important;
}
.rp-session-floating .rp-session-floating-actions [data-rp-session-finish]:hover{
    background:#075f82 !important;
    color:#fff !important;
}

/* v143: acceso directo a historia clínica desde contador flotante */
.rp-session-floating-patient-row{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:0 0 14px}
.rp-session-floating-patient-row p{margin:0!important;flex:1;min-width:0}
.rp-session-history-btn{display:inline-flex;align-items:center;gap:7px;border:1px solid rgba(11,127,171,.18);background:#eef8fb!important;color:#0b7fab!important;border-radius:999px;padding:8px 11px;font-size:12px;font-weight:800;line-height:1;cursor:pointer;white-space:nowrap;box-shadow:none!important}
.rp-session-history-btn svg{width:16px;height:16px;flex:0 0 16px}
.rp-session-history-btn:hover,.rp-session-history-btn:focus{background:#dff3f8!important;color:#075b82!important}
@media (max-width:640px){.rp-session-floating-patient-row{align-items:flex-start;flex-direction:column}.rp-session-history-btn{width:100%;justify-content:center}}

/* v145: popup de pago con criterios no presentado / pagada / no pagada */
.rp-dashboard-payment-box .rp-pay-policy-note{
  display:block;
  margin-top:6px;
  font-size:12px;
  color:#64748b;
  line-height:1.35;
}
.rp-dashboard-payment-actions [data-rp-pay-noshow],
.rp-dashboard-payment-actions [data-rp-pay-unpaid]{
  background:#eef8fb!important;
  color:#0b6f93!important;
  border-color:#d8eef6!important;
  box-shadow:none!important;
}
.rp-dashboard-payment-actions [data-rp-pay-noshow]:hover,
.rp-dashboard-payment-actions [data-rp-pay-unpaid]:hover{
  background:#dff3fa!important;
  color:#064d67!important;
}
@media(max-width:640px){
  .rp-dashboard-payment-actions{justify-content:stretch;}
  .rp-dashboard-payment-actions .rp-btn{min-height:44px;}
}

/* v147: alarmas de inicio y fin de sesión */
.rp-session-alarm-box{
  position:fixed;
  right:22px;
  bottom:190px;
  z-index:1000001;
  width:min(360px,calc(100vw - 32px));
  background:#fff;
  border:1px solid #dbeaf0;
  border-radius:18px;
  padding:16px;
  box-shadow:0 22px 60px rgba(15,23,42,.22);
  color:#263849;
  display:none;
}
.rp-session-alarm-box.show{display:block;animation:rpAlarmPulse 1s ease-in-out infinite alternate}
.rp-session-alarm-box strong{display:flex;align-items:center;gap:8px;font-size:16px;color:#0b7fab;margin:0 0 7px;font-weight:900}
.rp-session-alarm-box p{margin:0 0 12px;color:#475569;line-height:1.35;font-size:14px}
.rp-session-alarm-box .rp-session-alarm-actions{display:flex;gap:10px;justify-content:flex-end;flex-wrap:wrap}
.rp-session-alarm-box .rp-session-alarm-stop{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:40px;
  padding:9px 14px;
  border-radius:12px;
  border:0;
  background:#0b7fab!important;
  color:#fff!important;
  font-weight:800;
  cursor:pointer;
  box-shadow:0 8px 18px rgba(11,127,171,.18);
}
.rp-session-alarm-box .rp-session-alarm-stop:hover,
.rp-session-alarm-box .rp-session-alarm-stop:focus{background:#075f82!important;color:#fff!important}
@keyframes rpAlarmPulse{from{transform:translateY(0);box-shadow:0 22px 60px rgba(15,23,42,.20)}to{transform:translateY(-3px);box-shadow:0 26px 70px rgba(11,127,171,.28)}}
@media(max-width:640px){.rp-session-alarm-box{left:14px;right:14px;bottom:18px;width:auto}.rp-session-floating.show + .rp-session-alarm-box,.rp-session-alarm-box{bottom:165px}.rp-session-alarm-box .rp-session-alarm-stop{width:100%}}

/* v148: importación/exportación/impresión */
.rp-import-export-actions,.rp-detail-actions-inline{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.rp-inline-export-form,.rp-inline-import-form{display:inline-flex;align-items:center;gap:8px;flex-wrap:wrap;margin:0}
.rp-import-file{display:inline-flex!important;align-items:center;gap:8px;width:auto!important;margin:0!important}
.rp-import-file span{display:inline-flex;align-items:center;min-height:34px;padding:7px 12px;border-radius:12px;border:1px solid #dce8ef;background:#fff;color:#0b6f93;font-weight:800;font-size:13px;cursor:pointer}
.rp-import-file input{position:absolute;inline-size:1px;block-size:1px;opacity:0;pointer-events:none}
.rp-history-entry-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:8px}
@media(max-width:760px){.rp-import-export-actions,.rp-detail-actions-inline{width:100%;align-items:stretch}.rp-inline-export-form,.rp-inline-import-form,.rp-import-export-actions .rp-btn,.rp-detail-actions-inline .rp-btn{width:100%}.rp-inline-import-form{display:grid;grid-template-columns:1fr}.rp-import-file span{width:100%;justify-content:center}}
@media print{.rp-btn,.rp-mini-action,form,button,.rp-nav,.rp-prof-sidebar{display:none!important}.rp-history-entry{break-inside:avoid}}

/* v149: onboarding inicial obligatorio */
.rp-onboarding-layer{position:fixed;inset:0;z-index:999999;display:flex;align-items:center;justify-content:center;padding:18px;box-sizing:border-box;font-family:inherit}.rp-onboarding-layer[hidden],.rp-tour-layer[hidden]{display:none!important}.rp-onboarding-backdrop{position:absolute;inset:0;background:rgba(15,23,42,.72);backdrop-filter:blur(6px)}.rp-onboarding-modal{position:relative;width:min(620px,100%);max-height:calc(100vh - 36px);overflow:auto;background:#fff;border-radius:28px;padding:28px;box-shadow:0 30px 90px rgba(0,0,0,.35);color:#111827}.rp-onboarding-badge{display:inline-flex;background:#fff7ed;color:#c2410c;border:1px solid #fed7aa;border-radius:999px;padding:7px 12px;font-weight:800;font-size:12px;margin-bottom:12px}.rp-onboarding-modal h2{margin:0 0 8px;font-size:28px;line-height:1.15}.rp-onboarding-lead{margin:0 0 18px;color:#4b5563;font-size:15px;line-height:1.5}.rp-onboarding-steps{display:grid;gap:10px;margin:18px 0}.rp-onboarding-steps>div{border:1px solid #e5e7eb;border-radius:18px;padding:13px 14px;background:#f9fafb}.rp-onboarding-steps>div.is-active{border-color:#f59e0b;background:#fffbeb}.rp-onboarding-steps strong{display:block;color:#111827;font-size:14px}.rp-onboarding-steps span{display:block;color:#6b7280;font-size:13px;margin-top:3px;line-height:1.35}.rp-onboarding-actions{display:flex;gap:10px;justify-content:flex-end;margin-top:18px}.rp-onboarding-note{margin:14px 0 0;color:#6b7280;font-size:13px;line-height:1.45}.rp-onboarding-helper{position:fixed;right:18px;bottom:18px;z-index:999998;width:min(360px,calc(100vw - 36px));background:#111827;color:#fff;border-radius:22px;padding:16px;box-shadow:0 18px 50px rgba(0,0,0,.28)}.rp-onboarding-helper strong{display:block;margin-bottom:6px}.rp-onboarding-helper p{margin:0 0 10px;color:#e5e7eb;font-size:13px;line-height:1.4}.rp-tour-layer{position:fixed;right:18px;bottom:18px;z-index:999999;width:min(380px,calc(100vw - 36px))}.rp-tour-card{background:#fff;border-radius:22px;padding:18px;box-shadow:0 18px 55px rgba(15,23,42,.25);border:1px solid #e5e7eb}.rp-tour-card h3{margin:0 0 6px;font-size:19px}.rp-tour-card p{margin:0 0 14px;color:#4b5563;line-height:1.45}.rp-tour-actions{display:flex;justify-content:flex-end;gap:10px;flex-wrap:wrap}@media(max-width:760px){.rp-onboarding-modal{border-radius:22px;padding:22px}.rp-onboarding-modal h2{font-size:24px}.rp-onboarding-actions{justify-content:stretch}.rp-onboarding-actions .rp-btn{width:100%}.rp-onboarding-helper,.rp-tour-layer{right:12px;bottom:12px;width:calc(100vw - 24px)}}

/* v150: onboarding helper dentro del panel, pegajoso y no flotante abajo */
.rp-prof-panel .rp-onboarding-helper{
  position:sticky!important;
  top:14px!important;
  right:auto!important;
  bottom:auto!important;
  z-index:50!important;
  width:auto!important;
  max-width:none!important;
  margin:0 0 16px!important;
  background:#111827!important;
  color:#fff!important;
  border-radius:20px!important;
  padding:16px 18px!important;
  box-shadow:0 14px 40px rgba(15,23,42,.20)!important;
  border:1px solid rgba(255,255,255,.12)!important;
}
.rp-prof-panel .rp-onboarding-helper strong{display:block;margin:0 0 6px!important;font-size:15px!important;color:#fff!important;}
.rp-prof-panel .rp-onboarding-helper p{margin:0 0 12px!important;color:#e5e7eb!important;font-size:13px!important;line-height:1.45!important;}
.rp-prof-panel .rp-onboarding-helper .rp-btn{background:#f59e0b!important;color:#111827!important;border-color:#f59e0b!important;}
@media(max-width:760px){
  .rp-prof-panel .rp-onboarding-helper{
    top:10px!important;
    width:auto!important;
    margin:0 0 14px!important;
    border-radius:18px!important;
    padding:14px!important;
  }
}

/* v153: ficha de paciente compacta */
.rp-patient-detail-screen .rp-detail-topbar{
  margin-bottom:10px!important;
  font-size:14px!important;
}
.rp-patient-detail-screen .rp-detail-hero{
  padding:14px 18px!important;
  border-radius:14px!important;
  gap:14px!important;
  align-items:flex-start!important;
  margin-bottom:12px!important;
  min-height:0!important;
}
.rp-patient-detail-screen .rp-detail-hero small{
  font-size:13px!important;
  line-height:1.25!important;
}
.rp-patient-detail-screen .rp-detail-hero h1{
  font-size:26px!important;
  line-height:1.04!important;
  margin:4px 0 6px!important;
  max-width:300px!important;
  word-break:normal!important;
}
.rp-patient-detail-screen .rp-detail-hero p{
  font-size:14px!important;
  line-height:1.35!important;
}
.rp-patient-detail-screen .rp-patient-status{
  margin-top:7px!important;
  padding:4px 9px!important;
  font-size:12px!important;
  min-height:0!important;
}
.rp-patient-detail-screen .rp-detail-actions{
  gap:8px!important;
  align-items:center!important;
  justify-content:flex-end!important;
}
.rp-patient-detail-screen .rp-detail-actions .rp-btn,
.rp-patient-detail-screen .rp-detail-actions button,
.rp-patient-detail-screen .rp-detail-actions a{
  min-height:34px!important;
  padding:8px 12px!important;
  border-radius:10px!important;
  font-size:13px!important;
  line-height:1!important;
}
.rp-patient-detail-screen .rp-detail-actions svg,
.rp-patient-detail-screen .rp-detail-actions .dashicons{
  width:15px!important;
  height:15px!important;
  font-size:15px!important;
}
.rp-patient-detail-screen .rp-detail-actions .rp-btn-danger,
.rp-patient-detail-screen .rp-detail-actions .rp-btn-warn{
  padding-left:13px!important;
  padding-right:13px!important;
}
.rp-patient-detail-screen .rp-detail-grid,
.rp-patient-detail-screen .rp-detail-columns,
.rp-patient-detail-screen .rp-card,
.rp-patient-detail-screen .rp-detail-card{
  margin-top:12px!important;
}
@media(min-width:901px){
  .rp-patient-detail-screen .rp-detail-hero{
    display:grid!important;
    grid-template-columns:340px 1fr!important;
  }
  .rp-patient-detail-screen .rp-detail-actions{
    padding-top:2px!important;
  }
}
@media(max-width:900px){
  .rp-patient-detail-screen .rp-detail-hero{
    display:block!important;
    padding:14px!important;
  }
  .rp-patient-detail-screen .rp-detail-hero h1{
    font-size:25px!important;
    max-width:none!important;
  }
  .rp-patient-detail-screen .rp-detail-actions{
    margin-top:12px!important;
    justify-content:flex-start!important;
  }
}
@media(max-width:640px){
  .rp-patient-detail-screen .rp-detail-hero h1{
    font-size:23px!important;
  }
  .rp-patient-detail-screen .rp-detail-actions{
    gap:7px!important;
  }
  .rp-patient-detail-screen .rp-detail-actions .rp-btn,
  .rp-patient-detail-screen .rp-detail-actions button,
  .rp-patient-detail-screen .rp-detail-actions a{
    min-height:32px!important;
    padding:7px 10px!important;
    font-size:12.5px!important;
  }
}


/* v155 - Facturacion mobile: evitar desborde de campos de mes y filtros */
@media (max-width: 760px){
  #facturacion,
  #facturacion *{
    box-sizing:border-box!important;
  }
  #facturacion .rp-card,
  #facturacion .rp-table-card{
    width:100%!important;
    max-width:100%!important;
    overflow:hidden!important;
  }
  #facturacion .rp-billing-settings-card .rp-form-grid,
  #facturacion .rp-billing-settings-card form,
  #facturacion .rp-table-tools,
  #facturacion .rp-filter-inline{
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
    width:100%!important;
    max-width:100%!important;
    gap:12px!important;
  }
  #facturacion .rp-billing-settings-card label,
  #facturacion .rp-filter-inline label,
  #facturacion .rp-billing-search-label{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
  }
  #facturacion input,
  #facturacion select,
  #facturacion textarea,
  #facturacion button.rp-btn,
  #facturacion .rp-btn{
    max-width:100%!important;
    min-width:0!important;
  }
  #facturacion input[type="month"],
  #facturacion input[type="number"],
  #facturacion input[type="search"],
  #facturacion .rp-billing-search{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    display:block!important;
  }
  #facturacion .rp-billing-settings-card button.rp-btn,
  #facturacion .rp-filter-inline button.rp-btn{
    width:100%!important;
  }
  #facturacion .rp-table-tools > span{
    width:100%!important;
    display:block!important;
    overflow-wrap:anywhere!important;
  }
  #facturacion .rp-responsive-table{
    width:100%!important;
    max-width:100%!important;
    overflow-x:auto!important;
    -webkit-overflow-scrolling:touch!important;
    margin-left:0!important;
    margin-right:0!important;
  }
  #facturacion .rp-patient-table{
    min-width:760px!important;
  }
}

/* v156 - Facturacion mobile: correccion estricta input month desfasado iOS */
@media (max-width: 760px){
  #facturacion{
    overflow-x:hidden!important;
  }
  #facturacion .rp-card,
  #facturacion .rp-table-card,
  #facturacion .rp-billing-settings-card,
  #facturacion .rp-billing-settings-card form,
  #facturacion .rp-table-tools,
  #facturacion .rp-table-tools form,
  #facturacion .rp-filter-inline,
  #facturacion .rp-billing-settings-card label,
  #facturacion .rp-filter-inline label{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    margin-left:0!important;
    margin-right:0!important;
    box-sizing:border-box!important;
    overflow:hidden!important;
  }
  #facturacion .rp-billing-settings-card form.rp-form-grid,
  #facturacion .rp-table-tools{
    display:block!important;
  }
  #facturacion .rp-billing-settings-card label,
  #facturacion .rp-filter-inline label{
    display:block!important;
  }
  #facturacion input[type="month"],
  #facturacion input[type="number"],
  #facturacion input[type="search"],
  #facturacion .rp-billing-search{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    inline-size:100%!important;
    max-inline-size:100%!important;
    min-inline-size:0!important;
    box-sizing:border-box!important;
    display:block!important;
    margin:0!important;
    overflow:hidden!important;
  }
  #facturacion input[type="month"]{
    -webkit-appearance:none!important;
    appearance:none!important;
    height:56px!important;
    min-height:56px!important;
    line-height:56px!important;
    padding:0 12px!important;
    text-align:center!important;
    text-align-last:center!important;
  }
  #facturacion input[type="month"]::-webkit-date-and-time-value{
    text-align:center!important;
    width:100%!important;
    min-width:0!important;
    display:block!important;
  }
  #facturacion input[type="month"]::-webkit-calendar-picker-indicator{
    margin:0!important;
    padding:0!important;
  }
  #facturacion .rp-billing-settings-card button.rp-btn,
  #facturacion .rp-filter-inline button.rp-btn,
  #facturacion .rp-table-tools .rp-btn{
    width:100%!important;
    max-width:100%!important;
    display:block!important;
    margin-left:0!important;
    margin-right:0!important;
  }
  #facturacion .rp-filter-inline{
    margin:0 0 18px 0!important;
  }
  #facturacion .rp-billing-search-label{
    margin-top:16px!important;
  }
}

/* v159 - historial de pagos: acciones claras y compactas */
.rp-payment-row .rp-payment-actions{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  align-items:center;
  justify-content:flex-end;
}
.rp-payment-row .rp-payment-actions .rp-inline-form{
  margin:0;
}
.rp-payment-row span small{
  display:block;
  opacity:.72;
  margin-top:2px;
}
@media (max-width: 760px){
  .rp-payment-row .rp-payment-actions{
    justify-content:flex-start;
    width:100%;
  }
}


/* v162 Turnera paciente */
.rp-turnera-card .rp-field-hint{font-size:13px;color:#667085;line-height:1.45;align-self:end}
.rp-turnera-preview{background:#eef8fb;border:1px solid #cde8f2;border-radius:16px;padding:14px;color:#17445a;line-height:1.45}
.rp-public-turnos-free strong{color:#0b7fab}
@media(max-width:760px){.rp-turnera-paciente-section .rp-head-actions{gap:14px}.rp-turnera-paciente-section .rp-head-actions .rp-btn{width:100%;text-align:center}}

/* v167: popup de pago fijo, no afectado por refrescos visuales del Dashboard */
.rp-dashboard-payment-modal.active{
  position: fixed !important;
  inset: 0 !important;
  z-index: 999999 !important;
}
.rp-dashboard-payment-box{
  position: relative !important;
  z-index: 1000000 !important;
}

/* v168: header público del profesional */
.rp-public-turnos-head-profile .rp-public-prof-meta{display:flex;align-items:center;justify-content:center;gap:10px;flex-wrap:wrap;margin:6px 0 8px;color:inherit}
.rp-public-turnos-head-profile .rp-public-prof-meta strong{font-size:15px;font-weight:800;color:inherit;line-height:1.25}
.rp-public-turnos-head-profile .rp-public-prof-meta em{font-style:normal;font-size:13px;font-weight:700;opacity:.82;line-height:1.25}
.rp-header-profile-card textarea{min-height:82px!important;resize:vertical}
@media (max-width:760px){.rp-public-turnos-head-profile .rp-public-prof-meta{gap:6px;flex-direction:column}.rp-public-turnos-head-profile .rp-public-prof-meta strong{font-size:14px}.rp-public-turnos-head-profile .rp-public-prof-meta em{font-size:12px}}

/* v2.8.3-v179: mora por paciente */
.rp-patient-debt-summary-card .rp-debt-summary-table small{display:block;color:#748292;margin-top:3px;font-size:12px}.rp-patient-debt-summary-card h4{margin:10px 0 0;font-size:16px}.rp-previous-debt-form{margin-top:16px;padding-top:14px;border-top:1px solid rgba(20,40,60,.10)}.rp-debt-email-form{margin-top:12px;display:flex;gap:10px;align-items:center;flex-wrap:wrap}.rp-debt-email-form small{color:#748292}.rp-patient-debt-summary-card .rp-responsive-table{margin-top:14px}

/* v2.8.4-v180: mora dentro de historial de pagos, tabla compacta y clara */
.rp-payment-history-debt-card{
  border-radius:22px!important;
  padding:22px!important;
  background:#fff!important;
}
.rp-payment-history-debt-card .rp-card-title-row{
  align-items:flex-start!important;
  gap:16px!important;
  margin-bottom:14px!important;
}
.rp-debt-total-pill{
  min-width:190px;
  padding:12px 16px;
  border-radius:16px;
  background:#fff6ed;
  border:1px solid rgba(166,92,27,.18);
  text-align:right;
}
.rp-debt-total-pill span{display:block;font-size:12px;font-weight:800;color:#8d5a2c;text-transform:uppercase;letter-spacing:.04em;margin-bottom:4px}
.rp-debt-total-pill strong{display:block;font-size:24px;color:#7b2835;line-height:1}
.rp-debt-table-title{margin:14px 0 10px;padding:10px 12px;border-radius:14px;background:#f7f9fc;border:1px solid rgba(20,40,60,.08);font-size:13px;font-weight:800;color:#344054}
.rp-debt-responsive-table{margin-top:0!important;border-radius:16px;overflow:auto;border:1px solid rgba(20,40,60,.08)}
.rp-debt-summary-table{table-layout:fixed;min-width:760px;margin:0!important}
.rp-debt-summary-table th,.rp-debt-summary-table td{padding:12px 14px!important;vertical-align:top!important;line-height:1.35!important}
.rp-debt-summary-table .rp-debt-date-col{width:128px!important;white-space:nowrap!important}
.rp-debt-summary-table .rp-debt-concept-col{width:190px!important}
.rp-debt-summary-table .rp-debt-amount-col{width:115px!important;text-align:right!important;white-space:nowrap!important;font-weight:800;color:#7b2835}
.rp-debt-summary-table .rp-debt-note-col{width:auto!important;min-width:280px!important;white-space:normal!important;word-break:break-word!important}
.rp-debt-summary-table td.rp-debt-date-col strong{display:block;font-size:14px;color:#1f2937}.rp-debt-summary-table td.rp-debt-date-col small{display:block;font-size:12px;color:#667085;margin-top:2px}
.rp-debt-tools-grid{display:grid;grid-template-columns:minmax(0,1.15fr) minmax(280px,.85fr);gap:18px;margin-top:18px;align-items:start}.rp-debt-tools-grid h4{margin:0 0 8px;font-size:16px}.rp-debt-notice-panel{display:grid;gap:14px}.rp-debt-days-form,.rp-debt-email-form{padding:16px;border-radius:18px;background:#f8fafc;border:1px solid rgba(20,40,60,.08)}.rp-debt-days-form p{margin:0 0 12px}.rp-day-checks{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin:10px 0 14px}.rp-day-checks label{display:flex!important;align-items:center;gap:8px!important;padding:9px 10px;border-radius:12px;background:#fff;border:1px solid rgba(20,40,60,.08);font-size:13px;font-weight:700}.rp-day-checks input{width:16px!important;height:16px!important;margin:0!important}.rp-previous-debt-form{margin-top:0!important;padding-top:0!important;border-top:0!important}.rp-previous-debt-form label{min-width:0}.rp-previous-debt-form textarea{min-height:92px!important}
@media(max-width:900px){.rp-debt-tools-grid{grid-template-columns:1fr}.rp-payment-history-debt-card .rp-card-title-row{display:block!important}.rp-debt-total-pill{text-align:left;margin-top:12px;min-width:0}.rp-day-checks{grid-template-columns:1fr}.rp-debt-summary-table{min-width:680px}}

/* v2.8.5 - Historial de pagos y mora separado de la ficha */
.rp-payment-detail-screen{display:none;margin-top:24px;}
.rp-payment-detail-screen.active{display:block;}
.rp-patient-detail-screen.rp-payments-open > .rp-detail-topbar,
.rp-patient-detail-screen.rp-payments-open > .rp-detail-hero,
.rp-patient-detail-screen.rp-payments-open > .rp-next-banner,
.rp-patient-detail-screen.rp-payments-open > .rp-detail-grid{display:none!important;}
.rp-payment-summary-row{display:flex;align-items:center;justify-content:space-between;gap:16px;flex-wrap:wrap;margin:8px 0 14px;}
.rp-payments-quick-card .rp-debt-box{margin:0;min-width:210px;}
.rp-debt-summary-table th,.rp-debt-summary-table td{vertical-align:middle;}
.rp-debt-date-col{width:115px;white-space:nowrap;}
.rp-debt-time-col{width:80px;white-space:nowrap;}
.rp-debt-amount-col{width:115px;white-space:nowrap;text-align:right;}
.rp-debt-status-col{width:105px;white-space:nowrap;}
.rp-debt-actions-col{width:260px;}
.rp-debt-concept-col{min-width:190px;}
.rp-debt-actions-col{display:flex;gap:6px;flex-wrap:wrap;align-items:center;}
.rp-debt-actions-col form{margin:0;}
.rp-mini-action-warning{background:#fff7ed!important;color:#9a3412!important;border-color:#fed7aa!important;}
.rp-debt-tools-grid-clean{grid-template-columns:minmax(280px,1fr) minmax(260px,.8fr);align-items:start;}
.rp-previous-debt-form textarea{min-height:86px;}
@media(max-width:780px){.rp-debt-tools-grid-clean{grid-template-columns:1fr}.rp-debt-actions-col{width:auto}.rp-debt-summary-table{min-width:760px}.rp-payment-summary-row{align-items:stretch}.rp-payment-summary-row .rp-btn{width:100%;}}

/* v2.8.6-v182: historial de pagos/mora compacto y envío seleccionado */
.rp-btn-payments-main{
  display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:9px!important;
  width:100%!important;min-height:48px!important;padding:13px 18px!important;border-radius:14px!important;
  background:linear-gradient(135deg,#0f8fb3,#0b6f8c)!important;color:#fff!important;border:0!important;
  font-size:15px!important;font-weight:800!important;box-shadow:0 8px 22px rgba(15,143,179,.22)!important;
}
.rp-btn-payments-main:hover{filter:brightness(.96)!important;transform:translateY(-1px)}
.rp-btn-payments-main .rp-btn-icon{font-size:19px;line-height:1}
.rp-payment-history-debt-card{max-width:100%!important;overflow:visible!important}
.rp-debt-responsive-table{overflow:visible!important;border-radius:14px!important}
.rp-debt-summary-table{width:100%!important;min-width:0!important;table-layout:fixed!important;font-size:13px!important}
.rp-debt-summary-table th,.rp-debt-summary-table td{padding:8px 8px!important;line-height:1.22!important;vertical-align:middle!important}
.rp-debt-summary-table th{font-size:11px!important;letter-spacing:.03em;text-transform:uppercase;color:#667085!important}
.rp-debt-check-col{width:52px!important;text-align:center!important}
.rp-debt-check-col input{width:16px!important;height:16px!important;margin:0!important}
.rp-debt-date-col{width:86px!important;white-space:nowrap!important}
.rp-debt-time-col{width:54px!important;white-space:nowrap!important;text-align:center!important}
.rp-debt-concept-col{width:auto!important;min-width:0!important;white-space:normal!important;word-break:normal!important}
.rp-debt-amount-col{width:94px!important;white-space:nowrap!important;text-align:right!important;font-weight:800!important;color:#7b2835!important}
.rp-debt-status-col{width:82px!important;text-align:center!important;white-space:nowrap!important}
.rp-debt-actions-col{width:210px!important;display:flex!important;gap:4px!important;flex-wrap:nowrap!important;align-items:center!important;justify-content:flex-end!important;white-space:nowrap!important}
.rp-debt-actions-col form{margin:0!important;display:inline-flex!important}
.rp-debt-actions-col .rp-mini-action{padding:5px 7px!important;font-size:11px!important;border-radius:7px!important;line-height:1!important;min-height:28px!important}
.rp-debt-status-pill{display:inline-flex;align-items:center;justify-content:center;min-width:64px;padding:4px 7px;border-radius:999px;background:#fff7ed;color:#9a3412;font-size:11px;font-weight:800}
.rp-debt-tools-grid-clean{display:grid!important;grid-template-columns:minmax(0,1fr) 300px!important;gap:14px!important;margin-top:14px!important}
.rp-debt-notice-panel{display:block!important}
.rp-debt-email-form{margin-top:0!important;padding:14px!important;border-radius:14px!important;background:#f8fafc!important;border:1px solid rgba(20,40,60,.08)!important;display:block!important}
.rp-debt-email-form h4{margin:0 0 6px!important}.rp-debt-email-form p{margin:0 0 12px!important}
.rp-debt-days-form,.rp-day-checks{display:none!important}
@media(max-width:900px){
  .rp-debt-responsive-table{overflow:auto!important}.rp-debt-summary-table{min-width:760px!important}
  .rp-debt-tools-grid-clean{grid-template-columns:1fr!important}.rp-debt-actions-col{width:210px!important}
}

/* v2.8.7-v183 - ajustes visuales mora/pagos */
.rp-btn-payments-main{
  width:auto!important;
  max-width:100%!important;
  padding:11px 18px!important;
  min-height:44px!important;
  font-size:14px!important;
  border-radius:12px!important;
  justify-content:center!important;
  gap:9px!important;
}
.rp-btn-payments-main .rp-btn-icon-svg{display:inline-flex!important;width:18px!important;height:18px!important;align-items:center!important;justify-content:center!important;flex:0 0 18px!important}
.rp-btn-payments-main .rp-btn-icon-svg svg{width:18px!important;height:18px!important;display:block!important;fill:none!important;stroke:currentColor!important;stroke-width:1.8!important;stroke-linecap:round!important;stroke-linejoin:round!important}
.rp-saved-notice{
  background:#9be7b0!important;
  color:#111827!important;
  border:0!important;
  border-radius:12px!important;
  box-shadow:none!important;
}
.rp-debt-total-pill span{text-transform:none!important;letter-spacing:0!important}

/* v2.8.8-v184: ajustes mora seleccionada y aviso más discreto */
.rp-payment-history-debt-card .rp-saved-notice{
  display:inline-flex!important;
  width:auto!important;
  max-width:100%!important;
  padding:8px 14px!important;
  margin:10px 0 14px!important;
  font-size:13px!important;
  font-weight:500!important;
  line-height:1.25!important;
  border-radius:10px!important;
  background:#baf3c7!important;
  color:#111827!important;
  border:0!important;
}
.rp-payment-history-debt-card .rp-debt-total-pill strong{transition:opacity .12s ease;}

/* v187 - Bloqueos recurrentes de disponibilidad: layout compacto sin desfasar */
.rp-unavailable-box{margin-top:18px;padding:16px;border:1px solid #e7edf2;border-radius:18px;background:#fbfdfe;display:block!important;max-width:100%;overflow:hidden}
.rp-unavailable-head h2{margin:0 0 6px;font-size:21px;color:#243241}
.rp-unavailable-head p{margin:0 0 14px;color:#607080;line-height:1.45;font-size:14px}
.rp-unavailable-day{border:1px solid #e5edf2;border-radius:16px;background:#fff;margin:12px 0;padding:14px;max-width:100%;overflow:hidden}
.rp-unavailable-day h3{margin:0 0 10px;font-size:17px;color:#243241}
.rp-unavailable-row{display:grid!important;grid-template-columns:105px 135px minmax(96px,110px) minmax(96px,110px) minmax(118px,132px) minmax(130px,145px);gap:8px;align-items:end;margin:8px 0;padding:10px;border-radius:14px;background:#f8fbfd;max-width:100%;box-sizing:border-box;overflow:hidden}
.rp-unavailable-row label{font-size:11px;font-weight:700;color:#425262;display:flex;flex-direction:column;gap:5px;margin:0;min-width:0}
.rp-unavailable-row input,.rp-unavailable-row select{min-height:36px;border:1px solid #dfe8ef;border-radius:10px;background:#fff;padding:6px 8px;font-size:12.5px;box-sizing:border-box;width:100%;max-width:100%;min-width:0}
.rp-unavailable-row input[type=time]{padding-right:4px}
.rp-unavailable-row .rp-mini-check{display:flex;flex-direction:row;align-items:center;gap:6px;font-size:12.5px;min-height:36px;white-space:nowrap}
.rp-unavailable-row .rp-mini-check input{width:16px;height:16px;min-height:16px;flex:0 0 16px;padding:0}
.rp-unavailable-reason{grid-column:1/-1;min-width:0}
.rp-unavailable-reason input{width:100%;max-width:100%}
@media(min-width:981px){.rp-unavailable-row .rp-unavailable-reason{margin-top:2px}}
@media(max-width:760px){.rp-unavailable-row{grid-template-columns:1fr 1fr!important}.rp-unavailable-reason{grid-column:1/-1}}
@media(max-width:560px){.rp-unavailable-box{padding:12px}.rp-unavailable-row{grid-template-columns:1fr!important}.rp-unavailable-day{padding:10px}}

/* v2.9.4-v190: bloqueos recurrentes compactos */
.rp-unavailable-day-picker{margin:14px 0 16px;padding:14px;border:1px solid #e5edf2;border-radius:16px;background:#fff}
.rp-unavailable-day-picker>strong{display:block;margin-bottom:10px;color:#243241;font-size:14px}
.rp-unavailable-day-checks{display:flex;flex-wrap:wrap;gap:8px}
.rp-unavailable-day-checks label{display:inline-flex;align-items:center;gap:7px;padding:8px 11px;border:1px solid #dfe8ef;border-radius:999px;background:#f8fbfd;font-weight:700;font-size:13px;color:#425262;cursor:pointer}
.rp-unavailable-day-checks input{width:15px;height:15px;margin:0}
.rp-unavailable-day-title{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:10px}
.rp-unavailable-day-title h3{margin:0!important}
.rp-unavailable-rows{display:flex;flex-direction:column;gap:8px}
.rp-unavailable-row{grid-template-columns:135px minmax(96px,110px) minmax(96px,110px) minmax(118px,132px) minmax(130px,145px) minmax(100px,1fr) 74px!important;margin:0!important}
.rp-unavailable-row .rp-unavailable-reason{grid-column:auto!important}
.rp-unavailable-remove{align-self:end;min-height:36px;padding:7px 10px!important}
@media(max-width:1100px){.rp-unavailable-row{grid-template-columns:1fr 1fr!important}.rp-unavailable-row .rp-unavailable-reason{grid-column:1/-1!important}.rp-unavailable-remove{grid-column:1/-1;width:100%}}
@media(max-width:560px){.rp-unavailable-day-title{align-items:flex-start;flex-direction:column}.rp-unavailable-day-checks{gap:6px}.rp-unavailable-day-checks label{font-size:12px;padding:7px 9px}}


/* Compact typography v191 */
.rp-prof-panel{font-size:12px}
.rp-prof-panel input,
.rp-prof-panel select,
.rp-prof-panel textarea,
.rp-prof-panel button,
.rp-prof-panel table,
.rp-prof-panel label,
.rp-prof-panel .description{font-size:12px !important}
.rp-prof-panel h1,.rp-prof-panel .rp-page-title{font-size:16px !important;line-height:1.3}
.rp-prof-panel h2,.rp-prof-panel h3,.rp-prof-panel .rp-section-title{font-size:14px !important;line-height:1.3}
.rp-prof-panel small,.rp-prof-panel .help,.rp-prof-panel .hint{font-size:11px !important}
.rp-prof-panel input,
.rp-prof-panel select{min-height:36px}
.rp-prof-panel .button,.rp-prof-panel button{min-height:34px}
.rp-prof-panel .button-primary,.rp-prof-panel .rp-btn-primary{min-height:38px}

/* RP Psico v2.9.6-v192 - edad autocalculada */
.rp-age-autocalc[readonly]{background:#f3f6f8!important;color:#5b6773!important;cursor:not-allowed!important}

/* v194: acciones rápidas de Meet en próximo paciente */
.rp-next-meet-share{display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin-top:10px;padding-top:10px;border-top:1px solid rgba(11,127,171,.12)}
.rp-next-meet-share .rp-inline-meet-email-form{display:inline-flex;margin:0}
.rp-copy-meet-ok{font-size:12px;color:#0b6b3a;font-weight:700;background:#dff5e7;border-radius:999px;padding:7px 10px}
@media (max-width: 640px){.rp-next-meet-share{align-items:stretch}.rp-next-meet-share .rp-btn,.rp-next-meet-share .rp-inline-meet-email-form,.rp-next-meet-share .rp-inline-meet-email-form button{width:100%;justify-content:center}}

/* RP Psico v2.9.9 - reprogramación guiada sin popup */
.rp-reprogram-guide{
  grid-column:1/-1!important;
  display:flex!important;
  flex-wrap:wrap!important;
  gap:8px 14px!important;
  align-items:center!important;
  margin:8px 0 10px!important;
  padding:10px 12px!important;
  border-radius:12px!important;
  border:1px solid #fde68a!important;
  background:#fffbeb!important;
  color:#713f12!important;
  font-size:12px!important;
  line-height:1.35!important;
}
.rp-reprogram-guide strong{font-size:12px!important;color:#713f12!important}
.rp-reprogram-guide span{font-size:11px!important;color:#92400e!important;background:rgba(255,255,255,.65)!important;border-radius:999px!important;padding:3px 8px!important}
.rp-patient-schedule-card.is-reprogram-calendar-pulse .rp-patient-calendar-below .rp-vbz-calendar-wrap{
  border:2px solid #facc15!important;
  box-shadow:0 0 0 4px rgba(250,204,21,.12)!important;
  animation:rpYellowGuidePulse 1.8s ease-in-out infinite!important;
}
.rp-patient-schedule-card.is-reprogram-time-pulse .rp-patient-appointment-form input[name="appointment_time"]{
  border:2px solid #facc15!important;
  box-shadow:0 0 0 5px rgba(250,204,21,.16)!important;
  border-radius:999px!important;
  animation:rpYellowGuidePulse 1.8s ease-in-out infinite!important;
}
.rp-patient-schedule-card.is-reprogram-time-pulse .rp-patient-appointment-form label:has(input[name="appointment_time"]){position:static!important}
.rp-patient-schedule-card.is-reprogram-time-pulse .rp-patient-appointment-form label:has(input[name="appointment_time"])::after{content:none!important;display:none!important;}
.rp-reprogram-keep-original-btn{margin-left:8px!important;vertical-align:middle!important}
.rp-patient-appointment-form:not(.is-reprogramming) .rp-reprogram-keep-original-btn{display:none!important}
.rp-patient-date-pick.is-reprogram-old{
  outline:2px dashed #ef4444!important;
  outline-offset:2px!important;
  opacity:.72!important;
}
.rp-patient-date-pick.is-reprogram-old::after{content:'Original'!important;color:#b91c1c!important;font-size:10px!important;font-weight:800!important}
@keyframes rpYellowGuidePulse{
  0%,100%{box-shadow:0 0 0 4px rgba(250,204,21,.12)}
  50%{box-shadow:0 0 0 8px rgba(250,204,21,.28)}
}
@media(max-width:760px){.rp-reprogram-keep-original-btn{margin-left:0!important;margin-top:8px!important;width:100%!important}.rp-reprogram-save-btn{width:100%!important}}

/* RedPsico v2.10.6-v202 - logo de marca en sidebar/login */
.rp-login-logo{overflow:hidden;background:transparent!important;}
.rp-login-logo img{width:100%;height:100%;display:block;object-fit:contain;border-radius:14px;}
@media(max-width:760px){.rp-prof-brand .rp-brand-logo-wrap{width:36px;height:36px;min-width:36px}.rp-prof-brand .rp-brand-logo{width:36px;height:36px}}

/* v2.1.6.1 - Historial de sesiones: tipo de sesión */
.rp-session-history-card .rp-session-history-filters{
  display:flex!important;
  flex-wrap:wrap!important;
  gap:7px!important;
  margin:8px 0 10px!important;
}
.rp-session-history-card .rp-session-history-filters button{
  border:1px solid #dbe7ee!important;
  background:#fff!important;
  color:#40566b!important;
  border-radius:999px!important;
  padding:6px 10px!important;
  font-size:11px!important;
  font-weight:800!important;
  line-height:1!important;
  cursor:pointer!important;
  box-shadow:none!important;
}
.rp-session-history-card .rp-session-history-filters button.is-active{
  background:#eef8fb!important;
  border-color:#b9dfeb!important;
  color:#0b7fab!important;
}
.rp-detail-card .rp-session-chip{
  grid-template-columns:minmax(92px,.75fr) minmax(95px,.78fr) auto auto minmax(70px,.52fr) auto auto!important;
}
.rp-session-type-badge{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:max-content!important;
  max-width:100%!important;
  font-size:10px!important;
  font-weight:900!important;
  padding:3px 8px!important;
  border-radius:999px!important;
  line-height:1!important;
  white-space:nowrap!important;
  border:1px solid transparent!important;
}
.rp-session-type-badge-regular{
  background:#eef8fb!important;
  color:#0b7fab!important;
  border-color:#c9e8f1!important;
}
.rp-session-type-badge-emergency{
  background:#fff3e6!important;
  color:#b45309!important;
  border-color:#fed7aa!important;
}
.rp-session-chip.rp-session-hidden-by-filter{display:none!important}
@media(max-width:900px){
  .rp-detail-card .rp-session-chip{grid-template-columns:1fr 1fr auto!important}
  .rp-session-type-badge{justify-self:start!important}
}
@media(max-width:560px){
  .rp-detail-card .rp-session-chip{grid-template-columns:1fr 1fr!important}
  .rp-session-type-badge{width:100%!important}
}


/* v206 Dashboard: números más compactos y formato de horas dinámico desde PHP. */
.rp-dashboard-kpis strong{font-size:25px!important;line-height:1.08!important}

/* v210 - Configuración fiscal / ARCA */
.rp-fiscal-settings-form h2.full{margin:0 0 4px;font-size:18px;line-height:1.25;color:var(--rp-text,#172033)}
.rp-fiscal-settings-form .rp-checkline{display:flex;align-items:center;gap:8px;min-height:42px;padding:10px 12px;border:1px solid rgba(15,23,42,.08);border-radius:12px;background:rgba(255,255,255,.7);font-weight:600;color:var(--rp-text,#172033)}
.rp-fiscal-settings-form .rp-checkline input{width:auto;margin:0}
.rp-fiscal-status{padding:12px 14px;border-radius:14px;background:rgba(59,130,246,.08);border:1px solid rgba(59,130,246,.18);color:var(--rp-text,#172033)}
.rp-fiscal-status small{display:block;margin-top:4px;line-height:1.45;color:var(--rp-muted,#64748b)}

/* RedPsico v214 - tabla de facturación multi-país */
.rp-invoices-table-modern th,
.rp-invoices-table-modern td{
  white-space:normal;
}
.rp-invoices-table-modern td:nth-child(1){min-width:92px}
.rp-invoices-table-modern td:nth-child(2){min-width:130px}
.rp-invoices-table-modern td:nth-child(7){min-width:190px;max-width:280px}
.rp-invoice-badge{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border:1px solid #dbeafe;
  background:#eff6ff;
  color:#1e3a8a;
  border-radius:999px;
  padding:5px 9px;
  font-size:12px;
  font-weight:700;
  line-height:1;
}
.rp-invoice-badge.is-done{
  border-color:#d1fae5;
  background:#ecfdf5;
  color:#065f46;
}
.rp-invoice-description{
  display:block;
  color:#334155;
  line-height:1.35;
}
.rp-muted-inline{
  color:#94a3b8;
  font-size:12px;
}
.rp-billing-total-pill{
  display:inline-flex;
  align-items:center;
  min-height:38px;
  padding:0 12px;
  border-radius:999px;
  background:#f8fafc;
  border:1px solid #e2e8f0;
  font-weight:600;
  color:#334155;
}
@media(max-width:1100px){
  .rp-invoices-table-modern{min-width:980px}
}

/* v215 - Facturación interna */
.rp-invoice-receipt-link{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    margin-top:6px;
    text-decoration:none;
    white-space:nowrap;
}
.rp-invoices-table-modern td:last-child{
    min-width:130px;
}

/* v216 - Estado de cobro en historial de sesiones y tabla fiscal del paciente */
.rp-detail-card .rp-session-chip{
  grid-template-columns:minmax(88px,.65fr) minmax(86px,.65fr) auto auto minmax(70px,.52fr) auto auto auto!important;
}
.rp-session-billing-status{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:max-content!important;
  max-width:100%!important;
  font-size:10px!important;
  font-weight:900!important;
  padding:3px 8px!important;
  border-radius:999px!important;
  line-height:1!important;
  white-space:nowrap!important;
  border:1px solid transparent!important;
  background:#f3f4f6!important;
  color:#475569!important;
}
.rp-billing-status-pagado{background:#e8f8ef!important;color:#166534!important;border-color:#bbf7d0!important}
.rp-billing-status-facturado{background:#eef8fb!important;color:#0b7fab!important;border-color:#b9dfeb!important}
.rp-billing-status-pendiente{background:#fff7ed!important;color:#b45309!important;border-color:#fed7aa!important}
.rp-billing-status-reembolsado{background:#f5f3ff!important;color:#6d28d9!important;border-color:#ddd6fe!important}
.rp-billing-status-condonado{background:#f8fafc!important;color:#64748b!important;border-color:#e2e8f0!important}
.rp-billing-status-sin-cobro{background:#f8fafc!important;color:#94a3b8!important;border-color:#e2e8f0!important}
.rp-patient-invoice-history-table{margin-top:12px!important}
.rp-patient-invoice-history-table .rp-invoices-table td,
.rp-patient-invoice-history-table .rp-invoices-table th{vertical-align:top!important}
.rp-patient-invoice-history-table .rp-inline-invoice-form{display:inline-flex!important;margin:0 0 0 6px!important}
@media(max-width:900px){
  .rp-detail-card .rp-session-chip{grid-template-columns:1fr 1fr auto!important}
  .rp-session-billing-status{justify-self:start!important}
}
@media(max-width:640px){
  .rp-detail-card .rp-session-chip{grid-template-columns:1fr 1fr!important}
  .rp-session-billing-status{width:100%!important}
}


/* v217 - facturación centralizada y tabla compacta */
.rp-patient-billing-card{display:none!important}
#facturacion .rp-billing-compact-card{padding:16px!important}
#facturacion .rp-billing-compact-card h2{font-size:16px!important;margin:0 0 12px!important;line-height:1.2!important}
#facturacion .rp-billing-tools{align-items:center!important;gap:10px!important;margin-bottom:14px!important}
#facturacion .rp-filter-inline{margin:0!important;gap:8px!important}
#facturacion .rp-filter-inline input,
#facturacion .rp-filter-inline select,
#facturacion .rp-billing-search{height:34px!important;min-height:34px!important;padding:6px 10px!important;border-radius:9px!important;font-size:12px!important}
#facturacion .rp-billing-total-pill{font-size:12px!important;padding:8px 10px!important;border-radius:999px!important}
#facturacion .rp-invoices-table-compact{font-size:12px!important;min-width:860px!important}
#facturacion .rp-invoices-table-compact th{font-size:11px!important;letter-spacing:.03em!important;padding:9px 10px!important;white-space:nowrap!important}
#facturacion .rp-invoices-table-compact td{padding:10px!important;vertical-align:middle!important;line-height:1.25!important}
#facturacion .rp-invoices-table-compact td strong{font-size:13px!important;line-height:1.2!important}
#facturacion .rp-invoices-table-compact small{font-size:11px!important;line-height:1.25!important;margin-top:2px!important}
#facturacion .rp-invoice-badge{display:inline-flex!important;align-items:center!important;width:max-content!important;font-size:11px!important;line-height:1!important;padding:5px 8px!important;margin-top:5px!important;border-radius:999px!important}
#facturacion .rp-invoice-actions-stack{display:flex!important;flex-direction:column!important;align-items:flex-start!important;gap:6px!important}
#facturacion .rp-invoice-actions-stack .rp-btn,
#facturacion .rp-invoice-actions-stack .rp-mini-action{font-size:11px!important;padding:7px 9px!important;min-height:30px!important;border-radius:8px!important;white-space:nowrap!important}
#facturacion .rp-invoice-description{max-width:280px!important;color:#64748b!important}
@media(max-width:720px){#facturacion .rp-invoices-table-compact{min-width:760px!important}#facturacion .rp-billing-tools{align-items:stretch!important}}

/* v220 - Asistente ARCA */
.rp-arca-wizard-card{margin-bottom:18px;border:1px solid #dbeafe;background:linear-gradient(180deg,#f8fbff,#fff)}
.rp-arca-wizard-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:14px}
.rp-arca-wizard-head h2{margin:0 0 6px;font-size:18px}
.rp-arca-wizard-head p{margin:0;color:#64748b;font-size:13px;line-height:1.45}
.rp-arca-status-pill{white-space:nowrap;border-radius:999px;padding:8px 12px;font-size:12px;font-weight:700;background:#fee2e2;color:#991b1b;border:1px solid #fecaca}
.rp-arca-status-pill.is-ok{background:#dcfce7;color:#166534;border-color:#bbf7d0}
.rp-arca-progress{height:8px;background:#e5e7eb;border-radius:999px;overflow:hidden;margin:10px 0 16px}
.rp-arca-progress span{display:block;height:100%;background:#0f6f8f;border-radius:999px}
.rp-arca-steps{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:10px;margin-bottom:14px}
.rp-arca-step{border:1px solid #e5e7eb;border-radius:14px;padding:12px;background:#fff;min-height:82px}
.rp-arca-step strong{display:block;font-size:13px;color:#1f2937;margin-bottom:6px}
.rp-arca-step small{display:block;font-size:12px;color:#64748b;line-height:1.35}
.rp-arca-step.is-done{border-color:#bbf7d0;background:#f0fdf4}
.rp-arca-step.is-done strong{color:#166534}
.rp-arca-help-box{background:#f8fafc;border:1px solid #e5e7eb;border-radius:14px;padding:14px;margin-bottom:14px}
.rp-arca-help-box h3{font-size:15px;margin:0 0 8px}
.rp-arca-help-box ol{margin:0 0 8px 18px;padding:0;color:#334155;font-size:13px;line-height:1.45}
.rp-arca-help-box p{margin:0;color:#475569;font-size:13px}
.rp-arca-wizard-actions{display:flex;gap:10px;flex-wrap:wrap;margin-bottom:12px}
.rp-arca-csr-box textarea{font-family:monospace;font-size:12px;line-height:1.35;margin-top:8px;min-height:150px}
.rp-arca-csr-box small{display:block;margin-top:6px;color:#64748b}
@media(max-width:760px){.rp-arca-steps{grid-template-columns:1fr 1fr}.rp-arca-wizard-head{display:block}.rp-arca-status-pill{display:inline-block;margin-top:10px}}
@media(max-width:640px){.rp-arca-steps{grid-template-columns:1fr}}

/* v239: estado fiscal visual y restablecer formulario de facturación */
.rp-fiscal-state-card{display:flex;align-items:flex-start;gap:14px;margin-bottom:16px;border-width:1px!important}
.rp-fiscal-state-card .rp-fiscal-state-icon{font-size:28px;line-height:1;background:#f8fafc;border:1px solid #e5e7eb;border-radius:14px;width:54px;height:54px;display:flex;align-items:center;justify-content:center;flex:0 0 auto}
.rp-fiscal-state-card h2{margin:0 0 6px!important;font-size:20px!important}
.rp-fiscal-state-card strong{display:block;font-size:16px;margin-bottom:4px;color:#111827}
.rp-fiscal-state-card p{margin:0;color:#64748b;font-size:14px;line-height:1.45}
.rp-fiscal-state-card.is-empty{background:#fff;border-color:#e5e7eb!important}
.rp-fiscal-state-card.is-warning{background:#fffbeb;border-color:#fde68a!important}
.rp-fiscal-state-card.is-warning .rp-fiscal-state-icon{background:#fff7ed;border-color:#fed7aa}
.rp-fiscal-state-card.is-ok{background:#f0fdf4;border-color:#bbf7d0!important}
.rp-fiscal-state-card.is-ok .rp-fiscal-state-icon{background:#ecfdf5;border-color:#a7f3d0}
.rp-fiscal-form-actions{display:flex;gap:10px;flex-wrap:wrap;align-items:center}
.rp-fiscal-reset-form{margin-top:14px;padding-top:14px;border-top:1px solid #eef0f3;display:flex;align-items:center;gap:12px;flex-wrap:wrap}
.rp-fiscal-reset-form small{color:#64748b;line-height:1.4}

/* v249 - Ajuste visual dashboard: fondo blanco, menú azul oscuro y cards compactas */
.rp-prof-panel{
  --rp-bg:#ffffff!important;
  --rp-sidebar-dark:#102a56!important;
  --rp-sidebar-dark-2:#17396F!important;
  --rp-sidebar-text:#ffffff!important;
  --rp-sidebar-muted:rgba(255,255,255,.76)!important;
  background:#ffffff!important;
}
.rp-prof-main{
  background:#ffffff!important;
  padding:24px 26px!important;
}
.rp-prof-sidebar{
  background:var(--rp-sidebar-dark)!important;
  border-right:0!important;
  box-shadow:6px 0 24px rgba(15,23,42,.08)!important;
}
.rp-prof-brand{
  height:68px!important;
  margin-bottom:16px!important;
}
.rp-prof-brand .rp-brand-logo-wrap{
  background:rgba(255,255,255,.96)!important;
  border-radius:16px!important;
  width:54px!important;
  height:54px!important;
  min-width:54px!important;
}
.rp-prof-brand .rp-brand-logo{
  width:50px!important;
  height:50px!important;
  object-fit:contain!important;
}
.rp-prof-brand strong{
  color:#ffffff!important;
}
.rp-prof-sidebar a{
  color:var(--rp-sidebar-muted)!important;
  background:transparent!important;
}
.rp-prof-sidebar a.active,
.rp-prof-sidebar a:hover{
  background:rgba(255,255,255,.14)!important;
  color:#ffffff!important;
}
.rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar a.active,
.rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar a:hover{
  background:rgba(255,255,255,.16)!important;
}
.rp-nav-label,
.rp-nav-icon,
.rp-prof-sidebar a svg{
  color:inherit!important;
  stroke:currentColor!important;
}
.rp-prof-head{
  margin-bottom:14px!important;
}
.rp-prof-head h1{
  font-size:30px!important;
  margin-bottom:5px!important;
}
.rp-prof-head p{
  font-size:15px!important;
}
.rp-dashboard-kpis,
.rp-kpis.rp-dashboard-kpis{
  grid-template-columns:repeat(6,minmax(0,1fr))!important;
  gap:12px!important;
  margin-bottom:12px!important;
}
.rp-dashboard-kpis div{
  padding:16px!important;
  border-radius:16px!important;
  min-height:112px!important;
}
.rp-dashboard-kpis strong{
  font-size:28px!important;
  line-height:1.05!important;
}
.rp-dashboard-kpis span{
  font-size:13px!important;
  line-height:1.25!important;
}
.rp-next-card,
.rp-next-dashboard-card{
  width:100%!important;
  max-width:none!important;
  margin:0 0 12px!important;
  padding:20px!important;
  border-radius:18px!important;
}
.rp-next-dashboard-card h2,
.rp-dashboard-notifications-card h2{
  font-size:20px!important;
  margin-bottom:12px!important;
}
.rp-next-patient-grid{
  gap:10px!important;
}
.rp-dashboard-notifications-card{
  width:100%!important;
  max-width:none!important;
  margin-top:0!important;
  padding:20px!important;
  border-radius:18px!important;
}
.rp-card,
.rp-list-card,
.rp-table-card,
.rp-patient-card,
.rp-calendar-shell,
.rp-detail-card{
  border-radius:16px!important;
}
@media(max-width:1250px){
  .rp-dashboard-kpis,
  .rp-kpis.rp-dashboard-kpis{grid-template-columns:repeat(3,minmax(0,1fr))!important;}
}
@media(max-width:760px){
  .rp-prof-main{padding:18px 14px!important;}
  .rp-dashboard-kpis,
  .rp-kpis.rp-dashboard-kpis{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:10px!important;}
  .rp-dashboard-kpis div{min-height:96px!important;padding:14px!important;}
}


/* v250 ajustes solicitados */
.rp-prof-brand .rp-brand-logo-wrap{
    transform:translateX(6px);
}
.rp-bell-icon svg{
    width:22px!important;
    height:22px!important;
    stroke-width:1.4!important;
}


/* v272 - bloque azul viejo del calendario paciente eliminado: el calendario debe ser claro. */

/* v252 - Disponibilidad: sector no disponible azul, sin globos redondeados */
.rp-prof-panel .rp-unavailable-box{
  background:#102a56!important;
  border:0!important;
  border-radius:18px!important;
  color:#fff!important;
  padding:18px!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-unavailable-box *{
  color:#fff!important;
}
.rp-prof-panel .rp-unavailable-box p,
.rp-prof-panel .rp-unavailable-box label,
.rp-prof-panel .rp-unavailable-box span,
.rp-prof-panel .rp-unavailable-box small,
.rp-prof-panel .rp-unavailable-box button,
.rp-prof-panel .rp-unavailable-box input,
.rp-prof-panel .rp-unavailable-box select{
  font-weight:400!important;
}
.rp-prof-panel .rp-unavailable-box h1,
.rp-prof-panel .rp-unavailable-box h2,
.rp-prof-panel .rp-unavailable-box h3,
.rp-prof-panel .rp-unavailable-box strong,
.rp-prof-panel .rp-unavailable-day-title h3{
  font-weight:700!important;
}
.rp-prof-panel .rp-unavailable-head h2{
  color:#fff!important;
  font-size:21px!important;
  margin-bottom:6px!important;
}
.rp-prof-panel .rp-unavailable-head p{
  color:rgba(255,255,255,.86)!important;
  max-width:760px!important;
  line-height:1.45!important;
}
.rp-prof-panel .rp-unavailable-day-picker{
  background:rgba(255,255,255,.08)!important;
  border:1px solid rgba(255,255,255,.14)!important;
  border-radius:14px!important;
  padding:14px!important;
  margin:12px 0 16px!important;
}
.rp-prof-panel .rp-unavailable-day-picker>strong{
  color:#fff!important;
  font-weight:700!important;
}
.rp-prof-panel .rp-unavailable-day-checks{
  gap:8px!important;
}
.rp-prof-panel .rp-unavailable-day-checks label{
  border:0!important;
  border-radius:10px!important;
  background:rgba(255,255,255,.12)!important;
  color:#fff!important;
  padding:9px 12px!important;
  box-shadow:none!important;
  font-weight:400!important;
}
.rp-prof-panel .rp-unavailable-day-checks label:hover{
  background:rgba(255,255,255,.18)!important;
}
.rp-prof-panel .rp-unavailable-day-checks input{
  accent-color:#5ec7d7!important;
}
.rp-prof-panel .rp-unavailable-day{
  background:rgba(255,255,255,.08)!important;
  border:1px solid rgba(255,255,255,.14)!important;
  border-radius:16px!important;
  color:#fff!important;
}
.rp-prof-panel .rp-unavailable-day h3{
  color:#fff!important;
}
.rp-prof-panel .rp-unavailable-row{
  background:rgba(255,255,255,.09)!important;
  border:1px solid rgba(255,255,255,.10)!important;
  border-radius:14px!important;
}
.rp-prof-panel .rp-unavailable-row label{
  color:rgba(255,255,255,.92)!important;
  font-weight:400!important;
}
.rp-prof-panel .rp-unavailable-row input,
.rp-prof-panel .rp-unavailable-row select{
  background:#fff!important;
  color:#1f2937!important;
  border-color:rgba(255,255,255,.45)!important;
  font-weight:400!important;
}
.rp-prof-panel .rp-unavailable-row input::placeholder{
  color:#7b8794!important;
}
.rp-prof-panel .rp-unavailable-remove,
.rp-prof-panel .rp-unavailable-add{
  background:rgba(255,255,255,.14)!important;
  color:#fff!important;
  border:1px solid rgba(255,255,255,.18)!important;
  font-weight:400!important;
}
.rp-prof-panel .rp-unavailable-remove:hover,
.rp-prof-panel .rp-unavailable-add:hover{
  background:rgba(255,255,255,.22)!important;
}

/* v253 - Disponibilidad: botón guardar azul del menú + fila superior compacta */
@media (min-width: 981px){
  .rp-availability-form.rp-form-grid{
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
    column-gap:18px!important;
    row-gap:14px!important;
    align-items:end!important;
  }
  .rp-availability-form.rp-form-grid > label{
    grid-column:span 2!important;
  }
  .rp-availability-form.rp-form-grid > label:nth-of-type(1),
  .rp-availability-form.rp-form-grid > label:nth-of-type(2){
    grid-column:span 1!important;
  }
  .rp-availability-form.rp-form-grid > label:nth-of-type(1) input,
  .rp-availability-form.rp-form-grid > label:nth-of-type(2) input{
    max-width:260px!important;
  }
}

.rp-availability-save-row{
  display:flex!important;
  justify-content:flex-start!important;
  align-items:center!important;
  margin-top:4px!important;
}
.rp-availability-save-btn{
  background:var(--rp-sidebar-dark,#102a56)!important;
  color:#fff!important;
  border:0!important;
  min-height:46px!important;
  padding:12px 20px!important;
  gap:10px!important;
  border-radius:12px!important;
  font-weight:600!important;
  box-shadow:none!important;
}
.rp-availability-save-btn:hover{
  background:var(--rp-sidebar-dark-2,#163a66)!important;
}
.rp-availability-save-btn .rp-btn-svg{
  display:inline-flex!important;
  width:18px!important;
  height:18px!important;
  align-items:center!important;
  justify-content:center!important;
  flex:0 0 18px!important;
}
.rp-availability-save-btn .rp-btn-svg svg{
  width:18px!important;
  height:18px!important;
  display:block!important;
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.35!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
}


/* v254 - Unificar azul principal en menú, bloque disponibilidad y botón guardar */
.rp-prof-panel{
  --rp-primary:#102a56!important;
  --rp-primary-hover:#17396F!important;
  --rp-sidebar-dark:#102a56!important;
  --rp-sidebar-dark-2:#17396F!important;
  --rp-sidebar-text:#ffffff!important;
  --rp-sidebar-muted:rgba(255,255,255,.82)!important;
}
.rp-prof-panel .rp-prof-sidebar{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
}
.rp-prof-panel .rp-prof-sidebar a.active,
.rp-prof-panel .rp-prof-sidebar a:hover,
.rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar a.active,
.rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar a:hover{
  background:#17396F!important;
  color:#ffffff!important;
}
.rp-prof-panel .rp-unavailable-box{
  background:#102a56!important;
}
.rp-prof-panel .rp-availability-save-btn{
  background:#102a56!important;
  color:#ffffff!important;
}
.rp-prof-panel .rp-availability-save-btn:hover{
  background:#17396F!important;
}
@media (min-width:981px){
  .rp-availability-form.rp-form-grid{
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
    column-gap:16px!important;
    row-gap:14px!important;
  }
  .rp-availability-form.rp-form-grid > label:nth-of-type(1),
  .rp-availability-form.rp-form-grid > label:nth-of-type(2){
    grid-column:span 1!important;
    max-width:260px!important;
  }
  .rp-availability-form.rp-form-grid > label:nth-of-type(1) input,
  .rp-availability-form.rp-form-grid > label:nth-of-type(2) input{
    max-width:240px!important;
  }
}

/* v255 - Disponibilidad: modalidades y descanso en una línea, ocultar aviso anticipado visible */
@media (min-width: 981px){
  .rp-availability-form.rp-form-grid{
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
    column-gap:16px!important;
    row-gap:14px!important;
    align-items:end!important;
  }
  .rp-availability-form .rp-modalities{
    grid-column:1/-1!important;
    display:flex!important;
    align-items:center!important;
    flex-wrap:nowrap!important;
    gap:12px!important;
    width:100%!important;
  }
  .rp-availability-form .rp-modalities strong{
    flex:0 0 auto!important;
    margin-right:6px!important;
    white-space:nowrap!important;
  }
  .rp-availability-form .rp-modalities .rp-muted-small{
    display:none!important;
  }
  .rp-availability-form .rp-modalities label{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:auto!important;
    min-width:0!important;
    flex:0 0 auto!important;
    margin:0!important;
    white-space:nowrap!important;
  }
  .rp-availability-form .rp-switch-row,
  .rp-availability-form .rp-break-field{
    grid-column:span 1!important;
    width:100%!important;
    max-width:260px!important;
  }
  .rp-availability-form .rp-switch-row{
    align-self:center!important;
    min-height:46px!important;
    display:flex!important;
    align-items:center!important;
  }
  .rp-availability-form .rp-break-field input[type="time"]{
    max-width:240px!important;
  }
}

/* v256 - Disponibilidad: corregir desborde, descanso en una línea y días visibles */
.rp-prof-panel .rp-availability-card,
.rp-prof-panel .rp-availability-form,
.rp-prof-panel .rp-availability-form *{
  box-sizing:border-box!important;
}
.rp-prof-panel .rp-availability-card{
  overflow:hidden!important;
}
@media (min-width:981px){
  .rp-prof-panel .rp-availability-form.rp-form-grid{
    display:grid!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    column-gap:18px!important;
    row-gap:14px!important;
    align-items:end!important;
    width:100%!important;
    max-width:100%!important;
  }
  .rp-prof-panel .rp-availability-form.rp-form-grid > label{
    grid-column:auto!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
  }
  .rp-prof-panel .rp-availability-form.rp-form-grid > label:nth-of-type(1),
  .rp-prof-panel .rp-availability-form.rp-form-grid > label:nth-of-type(2){
    grid-column:auto!important;
    max-width:100%!important;
  }
  .rp-prof-panel .rp-availability-form input:not([type="checkbox"]):not([type="radio"]),
  .rp-prof-panel .rp-availability-form select,
  .rp-prof-panel .rp-availability-form textarea,
  .rp-prof-panel .rp-availability-form.rp-form-grid > label:nth-of-type(1) input,
  .rp-prof-panel .rp-availability-form.rp-form-grid > label:nth-of-type(2) input{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
  }
  .rp-prof-panel .rp-availability-form .full{
    grid-column:1/-1!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
  }
  .rp-prof-panel .rp-availability-form .rp-modalities{
    display:flex!important;
    flex-direction:row!important;
    align-items:center!important;
    flex-wrap:wrap!important;
    gap:10px 12px!important;
    padding:0!important;
    margin:0!important;
    overflow:visible!important;
  }
  .rp-prof-panel .rp-availability-form .rp-modalities strong{
    width:auto!important;
    flex:0 0 auto!important;
    margin:0 8px 0 0!important;
    white-space:nowrap!important;
  }
  .rp-prof-panel .rp-availability-form .rp-modalities .rp-muted-small{
    display:none!important;
  }
  .rp-prof-panel .rp-availability-form .rp-modalities label{
    display:inline-flex!important;
    flex-direction:row!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:8px!important;
    width:auto!important;
    max-width:none!important;
    min-width:0!important;
    flex:0 0 auto!important;
    margin:0!important;
    white-space:nowrap!important;
  }
  .rp-prof-panel .rp-availability-form .rp-break-row{
    display:flex!important;
    flex-direction:row!important;
    align-items:end!important;
    justify-content:flex-start!important;
    gap:16px!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    overflow:visible!important;
  }
  .rp-prof-panel .rp-availability-form .rp-break-row .rp-switch-row,
  .rp-prof-panel .rp-availability-form .rp-break-row .rp-break-field{
    grid-column:auto!important;
    width:auto!important;
    max-width:none!important;
    min-width:0!important;
    margin:0!important;
  }
  .rp-prof-panel .rp-availability-form .rp-break-row .rp-switch-row{
    flex:0 0 auto!important;
    min-height:46px!important;
    display:inline-flex!important;
    flex-direction:row!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:9px!important;
    padding:0!important;
  }
  .rp-prof-panel .rp-availability-form .rp-break-row .rp-break-field{
    flex:0 1 220px!important;
    display:flex!important;
    flex-direction:column!important;
  }
  .rp-prof-panel .rp-availability-form .rp-break-row .rp-break-field input[type="time"]{
    width:100%!important;
    max-width:220px!important;
  }
  .rp-prof-panel .rp-availability-form .rp-workdays{
    display:flex!important;
    flex-direction:row!important;
    align-items:center!important;
    flex-wrap:wrap!important;
    gap:8px!important;
    width:100%!important;
    max-width:100%!important;
    overflow:visible!important;
  }
  .rp-prof-panel .rp-availability-form .rp-workdays strong{
    width:100%!important;
    flex:0 0 100%!important;
    margin-bottom:2px!important;
  }
  .rp-prof-panel .rp-availability-form .rp-workdays label{
    display:inline-flex!important;
    flex-direction:row!important;
    align-items:center!important;
    justify-content:center!important;
    gap:8px!important;
    flex:1 1 130px!important;
    min-width:118px!important;
    max-width:180px!important;
    margin:0!important;
    white-space:nowrap!important;
  }
}
@media (max-width:760px){
  .rp-prof-panel .rp-availability-form .rp-break-row{
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:12px!important;
  }
  .rp-prof-panel .rp-availability-form .rp-break-row .rp-switch-row,
  .rp-prof-panel .rp-availability-form .rp-break-row .rp-break-field{
    width:100%!important;
    max-width:100%!important;
  }
}

/* v257 - Disponibilidad: título con SVG, modalidades arriba y descanso limpio */
.rp-prof-panel .rp-availability-head h1{
  display:flex!important;
  align-items:center!important;
  gap:10px!important;
}
.rp-prof-panel .rp-availability-head .rp-title-svg{
  width:30px!important;
  height:30px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  flex:0 0 30px!important;
  color:#102A56!important;
}
.rp-prof-panel .rp-availability-head .rp-title-svg svg{
  width:28px!important;
  height:28px!important;
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.35!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
  display:block!important;
}
.rp-prof-panel .rp-availability-save-btn,
.rp-prof-panel .rp-availability-save-btn span{
  font-weight:400!important;
}
.rp-prof-panel .rp-availability-save-btn .rp-btn-svg svg{
  stroke-width:1.25!important;
}
@media (min-width:981px){
  .rp-prof-panel .rp-availability-form.rp-form-grid{
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    column-gap:18px!important;
    row-gap:16px!important;
    align-items:end!important;
  }
  .rp-prof-panel .rp-availability-form .rp-modalities{
    grid-column:span 2!important;
    display:flex!important;
    flex-direction:row!important;
    align-items:center!important;
    flex-wrap:wrap!important;
    gap:10px 12px!important;
    padding:0!important;
    margin:0!important;
    min-height:46px!important;
  }
  .rp-prof-panel .rp-availability-form .rp-modalities strong{
    width:auto!important;
    flex:0 0 auto!important;
    margin:0 8px 0 0!important;
    white-space:nowrap!important;
  }
  .rp-prof-panel .rp-availability-form .rp-modalities .rp-muted-small{
    display:none!important;
  }
  .rp-prof-panel .rp-availability-form .rp-modalities label{
    display:inline-flex!important;
    flex-direction:row!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:8px!important;
    flex:0 0 auto!important;
    width:auto!important;
    max-width:none!important;
    margin:0!important;
    white-space:nowrap!important;
  }
  .rp-prof-panel .rp-availability-form .rp-break-row{
    grid-column:1/-1!important;
    display:flex!important;
    flex-direction:row!important;
    align-items:end!important;
    justify-content:flex-start!important;
    gap:18px!important;
    width:100%!important;
    max-width:100%!important;
    margin-top:8px!important;
    padding-top:4px!important;
    overflow:visible!important;
  }
  .rp-prof-panel .rp-availability-form .rp-break-row .rp-switch-row{
    flex:0 0 auto!important;
    display:inline-flex!important;
    flex-direction:row!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:9px!important;
    min-height:46px!important;
    height:46px!important;
    padding:0!important;
    border:0!important;
    background:transparent!important;
    border-radius:0!important;
    box-shadow:none!important;
    margin:0 2px 0 0!important;
    width:auto!important;
    max-width:none!important;
  }
  .rp-prof-panel .rp-availability-form .rp-break-row .rp-switch-row span{
    white-space:nowrap!important;
    font-weight:500!important;
  }
  .rp-prof-panel .rp-availability-form .rp-break-row .rp-break-field{
    flex:0 1 230px!important;
    display:flex!important;
    flex-direction:column!important;
    width:230px!important;
    max-width:230px!important;
    margin:0!important;
  }
  .rp-prof-panel .rp-availability-form .rp-break-row .rp-break-field input[type="time"]{
    width:100%!important;
    max-width:230px!important;
  }
}
@media (max-width:760px){
  .rp-prof-panel .rp-availability-head .rp-title-svg{
    width:26px!important;
    height:26px!important;
    flex-basis:26px!important;
  }
  .rp-prof-panel .rp-availability-head .rp-title-svg svg{
    width:24px!important;
    height:24px!important;
  }
}

/* v258 - Inicio: iconos lineales, cards centradas y próximo paciente azul */
#inicio .rp-dashboard-head h1{
  display:flex!important;
  align-items:center!important;
  gap:11px!important;
}
#inicio .rp-title-icon{
  width:31px!important;
  height:31px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  color:#102A56!important;
  flex:0 0 31px!important;
}
#inicio .rp-title-icon svg{
  width:31px!important;
  height:31px!important;
  display:block!important;
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.35!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
}
#inicio .rp-dashboard-kpis{
  gap:12px!important;
  margin-bottom:16px!important;
}
#inicio .rp-dashboard-kpis > div{
  display:flex!important;
  flex-direction:column!important;
  align-items:center!important;
  justify-content:center!important;
  text-align:center!important;
  min-height:128px!important;
  padding:18px 16px!important;
}
#inicio .rp-dashboard-kpis strong{
  text-align:center!important;
  font-weight:650!important;
  line-height:1!important;
}
#inicio .rp-dashboard-kpis span{
  display:block!important;
  text-align:center!important;
  font-weight:400!important;
  line-height:1.25!important;
  margin-top:8px!important;
}
#inicio .rp-next-dashboard-card{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  border-color:#102A56!important;
  color:#fff!important;
  box-shadow:none!important;
}
#inicio .rp-next-dashboard-card p,
#inicio .rp-next-dashboard-card span{
  color:#102A56!important;
}
#inicio .rp-next-dashboard-card > h2{
  font-weight:600!important;
}
#inicio .rp-next-patient-grid > div{
  background:#fff!important;
  background-image:none!important;
  border:1px solid #E4EAF2!important;
  color:#102A56!important;
}
#inicio .rp-next-patient-grid small{
  color:#102A56!important;
  font-weight:400!important;
}
#inicio .rp-next-patient-grid strong{
  color:#102A56!important;
  font-weight:600!important;
}
#inicio .rp-next-countdown{
  background:rgba(255,255,255,.10)!important;
  border-color:rgba(255,255,255,.18)!important;
  color:#fff!important;
}
#inicio .rp-next-countdown small,
#inicio .rp-next-countdown span{
  color:rgba(255,255,255,.78)!important;
  font-weight:400!important;
}
#inicio .rp-next-countdown strong{
  color:#102A56!important;
  background:#fff!important;
  border-color:#fff!important;
  font-weight:600!important;
}
#inicio .rp-next-actions,
#inicio .rp-next-meet-share{
  display:flex!important;
  gap:10px!important;
  align-items:center!important;
  flex-wrap:wrap!important;
}
#inicio .rp-next-actions .rp-btn,
#inicio .rp-next-meet-share .rp-btn,
#inicio .rp-next-actions button,
#inicio .rp-next-meet-share button{
  background:#fff!important;
  color:#102A56!important;
  border:1px solid rgba(255,255,255,.75)!important;
  font-weight:400!important;
  box-shadow:none!important;
  gap:7px!important;
}
#inicio .rp-next-actions .rp-btn:hover,
#inicio .rp-next-meet-share .rp-btn:hover,
#inicio .rp-next-actions button:hover,
#inicio .rp-next-meet-share button:hover{
  background:#F4F7FA!important;
  color:#102A56!important;
}
#inicio .rp-next-actions .rp-btn-danger,
#inicio .rp-next-actions button.rp-btn-danger{
  background:#fff!important;
  color:#9F1D1D!important;
  border-color:rgba(255,255,255,.75)!important;
  font-weight:400!important;
}
#inicio .rp-btn-svg{
  width:16px!important;
  height:16px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  flex:0 0 16px!important;
}
#inicio .rp-btn-svg svg{
  width:16px!important;
  height:16px!important;
  display:block!important;
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.35!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
}
#inicio .rp-dashboard-notifications-card{
  border-color:#E2E8F0!important;
}
#inicio .rp-dashboard-notifications-head h2{
  color:#102A56!important;
  font-weight:600!important;
}
#inicio .rp-bell-icon{
  color:#102A56!important;
}
#inicio .rp-bell-icon svg{
  width:22px!important;
  height:22px!important;
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.35!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
}
#inicio .rp-notification-badge{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  font-weight:500!important;
}
#inicio .rp-dashboard-notification-item{
  background:#F7F3EC!important;
  border-color:#E8DED0!important;
}
#inicio .rp-dashboard-notification-actions .rp-btn,
#inicio .rp-dashboard-notification-actions button{
  background:#fff!important;
  color:#102A56!important;
  border:1px solid #DDE6EE!important;
  font-weight:400!important;
}
@media(max-width:760px){
  #inicio .rp-dashboard-kpis > div{min-height:112px!important;}
}


/* v259 - Inicio: iconos visibles en botones y números KPI más chicos */
#inicio .rp-dashboard-kpis strong{
  font-size:27px!important;
}
#inicio .rp-next-actions .rp-btn,
#inicio .rp-next-meet-share .rp-btn,
#inicio .rp-next-actions button,
#inicio .rp-next-meet-share button{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:8px!important;
  font-weight:400!important;
}
#inicio .rp-next-actions .rp-btn-svg,
#inicio .rp-next-meet-share .rp-btn-svg,
#inicio .rp-next-actions .rp-btn-svg svg,
#inicio .rp-next-meet-share .rp-btn-svg svg{
  display:inline-flex!important;
  visibility:visible!important;
  opacity:1!important;
}
#inicio .rp-next-actions .rp-btn-svg,
#inicio .rp-next-meet-share .rp-btn-svg{
  width:17px!important;
  height:17px!important;
  min-width:17px!important;
  flex:0 0 17px!important;
  align-items:center!important;
  justify-content:center!important;
  color:currentColor!important;
}
#inicio .rp-next-actions .rp-btn-svg svg,
#inicio .rp-next-meet-share .rp-btn-svg svg{
  width:17px!important;
  height:17px!important;
  min-width:17px!important;
  max-width:17px!important;
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.25!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
  overflow:visible!important;
}
#inicio .rp-next-actions .rp-btn-svg svg *,
#inicio .rp-next-meet-share .rp-btn-svg svg *{
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.25!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
  vector-effect:non-scaling-stroke!important;
}
#inicio .rp-next-actions .rp-btn-danger .rp-btn-svg,
#inicio .rp-next-actions button.rp-btn-danger .rp-btn-svg{
  color:#9F1D1D!important;
}

/* v260 - Desktop: usar más ancho útil del panel general */
@media (min-width: 981px){
  .rp-prof-panel{
    width:calc(100vw - 36px)!important;
    max-width:none!important;
    margin-left:50%!important;
    transform:translateX(-50%)!important;
  }
  .rp-prof-main{
    padding:22px 24px!important;
    width:100%!important;
    max-width:none!important;
  }
  .rp-prof-section{
    width:100%!important;
    max-width:none!important;
  }
  .rp-card,
  .rp-list-card,
  .rp-patient-card,
  .rp-table-card,
  .rp-calendar-shell,
  .rp-detail-card,
  .rp-next-dashboard-card,
  .rp-dashboard-notifications-card,
  .rp-availability-card{
    max-width:none!important;
  }
  #inicio .rp-dashboard-kpis{
    grid-template-columns:repeat(6,minmax(0,1fr))!important;
    gap:10px!important;
  }
  #inicio .rp-next-dashboard-card,
  #inicio .rp-dashboard-notifications-card{
    width:100%!important;
  }
}

@media (min-width: 1280px){
  .rp-prof-panel{
    width:calc(100vw - 8px)!important;
  }
  .rp-prof-main{
    padding-left:26px!important;
    padding-right:26px!important;
  }
}


/* v261 - Inicio: próximo paciente más compacto, botones azules y KPIs más chicos */
#inicio .rp-dashboard-kpis strong{
  font-size:24px!important;
  line-height:1!important;
}
#inicio .rp-dashboard-kpis > div{
  min-height:116px!important;
  padding:15px 14px!important;
}
#inicio .rp-dashboard-kpis span{
  margin-top:6px!important;
}
#inicio .rp-next-dashboard-card{
  padding:18px 20px!important;
  border-radius:16px!important;
}
#inicio .rp-next-dashboard-card > h2{
  display:flex!important;
  align-items:center!important;
  gap:10px!important;
  margin:0 0 12px!important;
  font-size:23px!important;
  line-height:1.15!important;
  font-weight:600!important;
}
#inicio .rp-next-title-icon{
  width:23px!important;
  height:23px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  color:#fff!important;
  flex:0 0 23px!important;
}
#inicio .rp-next-title-icon svg{
  width:23px!important;
  height:23px!important;
  display:block!important;
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.35!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
}
#inicio .rp-next-countdown{
  padding:10px 12px!important;
  margin:0 0 10px!important;
  min-height:0!important;
  border-radius:12px!important;
  gap:12px!important;
}
#inicio .rp-next-countdown small{
  font-size:13px!important;
}
#inicio .rp-next-countdown strong{
  font-size:26px!important;
  line-height:1!important;
  padding:7px 13px!important;
  border-radius:11px!important;
}
#inicio .rp-next-countdown span{
  font-size:14px!important;
  line-height:1.25!important;
}
#inicio .rp-next-patient-grid{
  gap:9px!important;
  margin:0 0 10px!important;
}
#inicio .rp-next-patient-grid > div{
  padding:11px 13px!important;
  border-radius:12px!important;
  min-height:0!important;
}
#inicio .rp-next-patient-grid small{
  font-size:12px!important;
  margin-bottom:5px!important;
}
#inicio .rp-next-patient-grid strong{
  font-size:16px!important;
  line-height:1.15!important;
}
#inicio .rp-next-actions{
  gap:8px!important;
  margin:0!important;
}
#inicio .rp-next-actions .rp-btn,
#inicio .rp-next-actions button{
  background:#17396F!important;
  color:#fff!important;
  border:1px solid rgba(255,255,255,.22)!important;
  border-radius:10px!important;
  padding:9px 13px!important;
  min-height:38px!important;
  font-size:13px!important;
  font-weight:400!important;
  line-height:1!important;
}
#inicio .rp-next-actions .rp-btn:hover,
#inicio .rp-next-actions button:hover{
  background:#1E467F!important;
  color:#fff!important;
}
#inicio .rp-next-actions .rp-btn-danger,
#inicio .rp-next-actions button.rp-btn-danger{
  background:#8F1D1D!important;
  color:#fff!important;
  border-color:rgba(255,255,255,.24)!important;
}
#inicio .rp-next-actions .rp-btn-danger:hover,
#inicio .rp-next-actions button.rp-btn-danger:hover{
  background:#A52626!important;
  color:#fff!important;
}
#inicio .rp-next-meet-share{
  background:#fff!important;
  border:1px solid rgba(255,255,255,.9)!important;
  border-radius:14px!important;
  padding:10px!important;
  margin-top:10px!important;
  gap:8px!important;
}
#inicio .rp-next-meet-share .rp-btn,
#inicio .rp-next-meet-share button{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  border:1px solid #102A56!important;
  border-radius:10px!important;
  padding:9px 13px!important;
  min-height:38px!important;
  font-size:13px!important;
  font-weight:400!important;
  line-height:1!important;
}
#inicio .rp-next-meet-share .rp-btn:hover,
#inicio .rp-next-meet-share button:hover{
  background:#17396F!important;
  color:#fff!important;
}
#inicio .rp-next-actions .rp-btn-svg,
#inicio .rp-next-meet-share .rp-btn-svg{
  width:16px!important;
  height:16px!important;
  min-width:16px!important;
  flex:0 0 16px!important;
}
#inicio .rp-next-actions .rp-btn-svg svg,
#inicio .rp-next-meet-share .rp-btn-svg svg{
  width:16px!important;
  height:16px!important;
  stroke-width:1.2!important;
}
#inicio .rp-next-actions .rp-btn-svg svg *,
#inicio .rp-next-meet-share .rp-btn-svg svg *{
  stroke-width:1.2!important;
}
@media (min-width:981px){
  #inicio .rp-next-dashboard-card{
    margin-top:12px!important;
  }
}
@media(max-width:760px){
  #inicio .rp-dashboard-kpis strong{font-size:23px!important;}
  #inicio .rp-next-countdown{align-items:flex-start!important;}
  #inicio .rp-next-countdown strong{font-size:22px!important;}
}


/* RP Psico v262 - Pacientes visual azul unificado */
#pacientes .rp-section-title-icon{
  display:flex!important;
  align-items:center!important;
  gap:10px!important;
}
#pacientes .rp-title-svg{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  color:#102A56!important;
  line-height:0!important;
}
#pacientes .rp-title-svg svg,
#pacientes .rp-btn-svg svg{
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.5!important;
}
#pacientes .rp-btn-svg{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  margin-right:7px!important;
  line-height:0!important;
  flex:0 0 auto!important;
}
#pacientes .rp-patient-create-btn,
#pacientes .rp-patient-open-btn{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  font-weight:400!important;
  border:1px solid #102A56!important;
  box-shadow:none!important;
}
#pacientes .rp-patient-create-btn:hover,
#pacientes .rp-patient-open-btn:hover{
  background:#17396F!important;
  border-color:#17396F!important;
}
#pacientes .rp-patient-table thead th{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  text-align:center!important;
  font-weight:400!important;
  border-bottom:0!important;
  letter-spacing:.03em!important;
}
#pacientes .rp-patient-table thead th:first-child{
  border-top-left-radius:12px!important;
}
#pacientes .rp-patient-table thead th:last-child{
  border-top-right-radius:12px!important;
}
#pacientes .rp-patient-table tbody td{
  text-align:center!important;
}
#pacientes .rp-patient-table tbody td:nth-child(2),
#pacientes .rp-patient-table tbody td:nth-child(3){
  text-align:left!important;
}
#pacientes .rp-patient-table tbody td:last-child{
  text-align:center!important;
}

/* v263 ficha paciente: acciones alineadas, acordeones y agenda blanca */
.rp-patient-detail-screen .rp-detail-topbar{
  display:flex!important;
  align-items:center!important;
  gap:10px!important;
  flex-wrap:wrap!important;
}
.rp-patient-detail-screen .rp-back-patients{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  border-color:#102A56!important;
  min-height:38px!important;
  height:38px!important;
  padding:0 15px!important;
  font-size:14px!important;
  font-weight:400!important;
  border-radius:12px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:8px!important;
}
.rp-patient-detail-screen .rp-detail-hero{
  display:flex!important;
  flex-direction:column!important;
  align-items:stretch!important;
  gap:12px!important;
}
.rp-patient-detail-screen .rp-detail-hero > div:first-child{
  order:2!important;
}
.rp-patient-detail-screen .rp-detail-actions{
  order:1!important;
  width:100%!important;
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  flex-wrap:nowrap!important;
  gap:8px!important;
  margin:0!important;
  padding:0!important;
  overflow-x:auto!important;
  -webkit-overflow-scrolling:touch!important;
}
.rp-patient-detail-screen .rp-detail-actions form{
  margin:0!important;
  display:inline-flex!important;
  flex:0 0 auto!important;
}
.rp-patient-detail-screen .rp-detail-actions .rp-btn,
.rp-patient-detail-screen .rp-detail-actions button,
.rp-patient-detail-screen .rp-detail-actions a{
  height:38px!important;
  min-height:38px!important;
  padding:0 14px!important;
  font-size:14px!important;
  font-weight:400!important;
  line-height:1!important;
  border-radius:12px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:8px!important;
  white-space:nowrap!important;
}
.rp-patient-detail-screen .rp-detail-actions svg,
.rp-patient-detail-screen .rp-btn-svg svg,
.rp-patient-detail-screen .rp-line-svg{
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.45!important;
  flex:0 0 auto!important;
}
.rp-patient-detail-screen .rp-next-banner{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  border:1px solid rgba(255,255,255,.12)!important;
  border-radius:16px!important;
  padding:14px 16px!important;
  display:flex!important;
  align-items:center!important;
  gap:12px!important;
  flex-wrap:wrap!important;
}
.rp-patient-detail-screen .rp-next-banner strong,
.rp-patient-detail-screen .rp-next-banner span,
.rp-patient-detail-screen .rp-next-banner em{
  color:#fff!important;
  font-weight:400!important;
}
.rp-patient-detail-screen .rp-next-banner strong{
  font-weight:500!important;
  display:inline-flex!important;
  align-items:center!important;
  gap:8px!important;
}
.rp-detail-accordion{
  padding:0!important;
  overflow:hidden!important;
  background:#fff!important;
  border:1px solid #e5edf2!important;
  border-radius:16px!important;
}
.rp-detail-accordion > summary{
  list-style:none!important;
}
.rp-detail-accordion > summary::-webkit-details-marker{display:none!important;}
.rp-detail-accordion-head{
  cursor:pointer!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  padding:15px 18px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:12px!important;
  font-size:15px!important;
  font-weight:400!important;
}
.rp-detail-accordion-title{
  display:inline-flex!important;
  align-items:center!important;
  gap:9px!important;
  color:#fff!important;
  font-weight:400!important;
}
.rp-detail-accordion-head .rp-patient-status{
  background:rgba(255,255,255,.14)!important;
  color:#fff!important;
  border:1px solid rgba(255,255,255,.20)!important;
  margin:0!important;
}
.rp-detail-accordion-body{
  background:#fff!important;
  color:#263442!important;
  padding:18px!important;
}
.rp-detail-accordion-body .rp-btn,
.rp-detail-accordion-body button.rp-btn,
.rp-detail-accordion-body .rp-save-data-btn,
.rp-detail-accordion-body .rp-save-plan-btn{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  border-color:#102A56!important;
  height:38px!important;
  min-height:38px!important;
  padding:0 15px!important;
  border-radius:12px!important;
  font-weight:400!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:8px!important;
}
.rp-patient-detail-screen .rp-patient-schedule-card,
.rp-patient-detail-screen .rp-patient-schedule-card .rp-calendar-shell,
.rp-patient-detail-screen .rp-patient-calendar-below,
.rp-patient-detail-screen .rp-vbz-calendar-wrap,
.rp-patient-detail-screen .rp-patient-calendar-picker{
  background:#fff!important;
  color:#263442!important;
}
.rp-patient-detail-screen .rp-patient-schedule-card h3,
.rp-patient-detail-screen .rp-patient-schedule-card p,
.rp-patient-detail-screen .rp-patient-schedule-card label,
.rp-patient-detail-screen .rp-patient-schedule-card strong,
.rp-patient-detail-screen .rp-patient-schedule-card span{
  color:#263442!important;
}
@media(max-width:760px){
  .rp-patient-detail-screen .rp-detail-actions{flex-wrap:wrap!important;overflow-x:visible!important;}
}

/* RP Psico v264 - calendario paciente fondo blanco con texto visible */
.rp-patient-detail-screen .rp-patient-calendar-below,
.rp-patient-detail-screen .rp-patient-calendar-picker,
.rp-patient-detail-screen .rp-vbz-calendar-wrap,
.rp-patient-detail-screen .rp-calendar-shell,
.rp-patient-detail-screen .rp-patient-schedule-card,
.rp-patient-detail-screen .rp-patient-schedule-card .rp-card{
  background:#fff!important;
  color:#1F2937!important;
}
.rp-patient-detail-screen .rp-patient-calendar-below *,
.rp-patient-detail-screen .rp-patient-calendar-picker *,
.rp-patient-detail-screen .rp-vbz-calendar-wrap *,
.rp-patient-detail-screen .rp-calendar-shell *{
  color:#1F2937!important;
}
.rp-patient-detail-screen .rp-calendar-title strong,
.rp-patient-detail-screen .rp-calendar-title span,
.rp-patient-detail-screen .rp-calendar-title button,
.rp-patient-detail-screen .rp-calendar-title a{
  color:#102A56!important;
}
.rp-patient-detail-screen .rp-calendar-weekdays span{
  color:#475569!important;
  font-weight:500!important;
}
.rp-patient-detail-screen .rp-patient-calendar-grid,
.rp-patient-detail-screen .rp-admin-calendar.rp-patient-calendar-grid{
  background:#fff!important;
}
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell{
  background:#fff!important;
  color:#1F2937!important;
  border-color:#E5E7EB!important;
}
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell strong,
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell em,
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell span{
  color:#1F2937!important;
}
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell em{
  color:#64748B!important;
}
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell:hover{
  background:#F8FAFC!important;
  border-color:#102A56!important;
}
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.selected,
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.is-selected,
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.selected-unavailable{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  border-color:#102A56!important;
}
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.selected strong,
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.selected em,
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.selected span,
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.is-selected strong,
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.is-selected em,
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.is-selected span,
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.selected-unavailable strong,
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.selected-unavailable em,
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.selected-unavailable span{
  color:#fff!important;
}
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.is-past{
  background:#F1F5F9!important;
  color:#94A3B8!important;
  border-color:#E2E8F0!important;
}
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.is-past strong,
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.is-past em,
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.is-past span{
  color:#94A3B8!important;
}
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.is-free{
  background:#FBFFFD!important;
}
.rp-patient-detail-screen .rp-patient-calendar-grid .rp-day-cell.has-patients{
  background:#F7FBFF!important;
  border-color:#C9E6F4!important;
}
.rp-patient-detail-screen .rp-day-availability-dot{border-color:#fff!important;}
.rp-patient-detail-screen .rp-calendar-day-info,
.rp-patient-detail-screen .rp-day-availability-card{
  background:#EFF6FF!important;
  color:#1E3A8A!important;
  border-color:#DBEAFE!important;
}
.rp-patient-detail-screen .rp-calendar-day-info *,
.rp-patient-detail-screen .rp-day-availability-card *{
  color:inherit!important;
}
.rp-patient-detail-screen .rp-calendar-day-info.is-off,
.rp-patient-detail-screen .rp-day-availability-card.is-off{
  background:#F8FAFC!important;
  color:#64748B!important;
  border-color:#E5E7EB!important;
}

/* RP Psico v2.1.7 - corrección fuerte calendario paciente claro: textos visibles */
.rp-vbz-calendar-wrap,
.rp-vbz-calendar-wrap *{
  color:#1F2937!important;
  text-shadow:none!important;
}
.rp-vbz-calendar-wrap{
  background:#FFFFFF!important;
  border-color:#DDE6EF!important;
}
.rp-vbz-calendar-wrap .rp-calendar-toolbar,
.rp-vbz-calendar-wrap .rp-calendar-toolbar div,
.rp-vbz-calendar-wrap .rp-calendar-month,
.rp-vbz-calendar-wrap .rp-calendar-weekdays,
.rp-vbz-calendar-wrap .rp-patient-calendar-grid,
.rp-vbz-calendar-wrap .rp-admin-calendar{
  background:#FFFFFF!important;
}
.rp-vbz-calendar-wrap .rp-calendar-toolbar strong,
.rp-vbz-calendar-wrap .rp-cal-current-title{
  color:#102A56!important;
  font-weight:600!important;
}
.rp-vbz-calendar-wrap .rp-calendar-toolbar span{
  color:#334155!important;
  background:transparent!important;
}
.rp-vbz-calendar-wrap .rp-cal-nav{
  color:#102A56!important;
  background:#FFFFFF!important;
  border:1px solid #DDE6EF!important;
}
.rp-vbz-calendar-wrap .rp-calendar-weekdays span{
  color:#102A56!important;
  background:transparent!important;
  font-weight:600!important;
}
.rp-vbz-calendar-wrap .rp-patient-calendar-grid .rp-day-cell,
.rp-vbz-calendar-wrap .rp-admin-calendar .rp-day-cell,
.rp-vbz-calendar-wrap button.rp-day-cell{
  background:#FFFFFF!important;
  color:#1F2937!important;
  border-color:#DDE6EF!important;
  opacity:1!important;
  filter:none!important;
}
.rp-vbz-calendar-wrap .rp-day-cell strong{
  color:#111827!important;
  background:#EEF2F7!important;
  font-weight:600!important;
}
.rp-vbz-calendar-wrap .rp-day-cell em,
.rp-vbz-calendar-wrap .rp-day-cell small,
.rp-vbz-calendar-wrap .rp-day-cell .rp-turno-bubble{
  color:#334155!important;
  background:rgba(226,232,240,.78)!important;
  font-weight:400!important;
}
.rp-vbz-calendar-wrap .rp-day-cell.is-past,
.rp-vbz-calendar-wrap .rp-day-cell.is-blocked{
  background:#F8FAFC!important;
  color:#475569!important;
  border-color:#E2E8F0!important;
  opacity:1!important;
  filter:none!important;
}
.rp-vbz-calendar-wrap .rp-day-cell.is-past strong,
.rp-vbz-calendar-wrap .rp-day-cell.is-blocked strong{
  color:#475569!important;
  background:#E9EEF5!important;
}
.rp-vbz-calendar-wrap .rp-day-cell.is-past em,
.rp-vbz-calendar-wrap .rp-day-cell.is-blocked em{
  color:#475569!important;
  background:#E9EEF5!important;
}
.rp-vbz-calendar-wrap .rp-day-cell.is-free{
  background:#FFFFFF!important;
  border-color:#BFE7D4!important;
}
.rp-vbz-calendar-wrap .rp-day-cell.is-free em{
  color:#065F46!important;
  background:#DDF7EA!important;
}
.rp-vbz-calendar-wrap .rp-day-cell.has-patients{
  background:#FFFFFF!important;
  border-color:#B8DCEE!important;
}
.rp-vbz-calendar-wrap .rp-day-cell.has-patients em,
.rp-vbz-calendar-wrap .rp-day-cell.has-patients small,
.rp-vbz-calendar-wrap .rp-day-cell.has-patients .rp-turno-bubble{
  color:#075985!important;
  background:#E0F2FE!important;
}
.rp-vbz-calendar-wrap .rp-day-cell.selected,
.rp-vbz-calendar-wrap .rp-day-cell.is-selected,
.rp-vbz-calendar-wrap .rp-day-cell.preview-selected,
.rp-vbz-calendar-wrap .rp-day-cell.selected-unavailable{
  background:#FFFFFF!important;
  color:#102A56!important;
  border-color:#102A56!important;
  box-shadow:0 0 0 2px rgba(16,42,86,.16)!important;
  outline:none!important;
}
.rp-vbz-calendar-wrap .rp-day-cell.selected strong,
.rp-vbz-calendar-wrap .rp-day-cell.is-selected strong,
.rp-vbz-calendar-wrap .rp-day-cell.preview-selected strong,
.rp-vbz-calendar-wrap .rp-day-cell.selected-unavailable strong{
  background:#DBEAFE!important;
  color:#102A56!important;
}
.rp-vbz-calendar-wrap .rp-day-availability-dot{
  color:transparent!important;
  border:2px solid #FFFFFF!important;
  opacity:1!important;
  filter:none!important;
  z-index:4!important;
}
.rp-vbz-calendar-wrap .rp-day-availability-dot.is-on{background:#059669!important;}
.rp-vbz-calendar-wrap .rp-day-availability-dot.is-off{background:#CBD5E1!important;}
.rp-vbz-calendar-wrap .rp-calendar-day-info,
.rp-vbz-calendar-wrap .rp-day-availability-card{
  color:#1E3A8A!important;
  background:#EFF6FF!important;
  border-color:#DBEAFE!important;
}
.rp-vbz-calendar-wrap .rp-calendar-day-info *,
.rp-vbz-calendar-wrap .rp-day-availability-card *{
  color:inherit!important;
}
.rp-vbz-calendar-wrap .rp-calendar-day-info.is-on,
.rp-vbz-calendar-wrap .rp-day-availability-card.is-on{
  color:#065F46!important;
  background:#ECFDF5!important;
  border-color:#BBF7D0!important;
}
.rp-vbz-calendar-wrap .rp-calendar-day-info.is-off,
.rp-vbz-calendar-wrap .rp-day-availability-card.is-off{
  color:#475569!important;
  background:#F8FAFC!important;
  border-color:#E2E8F0!important;
}

/* v266 - FIX DEFINITIVO calendario paciente claro: fondo blanco y estados legibles */
.rp-prof-panel .rp-patient-calendar-picker,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap,
.rp-prof-panel .rp-patient-calendar-below,
.rp-prof-panel .rp-patient-calendar-picker .rp-calendar-month,
.rp-prof-panel .rp-patient-calendar-picker .rp-admin-calendar,
.rp-prof-panel .rp-patient-calendar-picker .rp-patient-calendar-grid{
  background:#ffffff!important;
  color:#111827!important;
  opacity:1!important;
  filter:none!important;
  text-shadow:none!important;
}
.rp-prof-panel .rp-patient-calendar-picker *,
.rp-prof-panel .rp-patient-calendar-below *{
  opacity:1!important;
  filter:none!important;
  text-shadow:none!important;
  -webkit-text-fill-color:currentColor!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-calendar-toolbar strong,
.rp-prof-panel .rp-patient-calendar-picker .rp-cal-current-title,
.rp-prof-panel .rp-patient-calendar-picker .rp-calendar-toolbar span,
.rp-prof-panel .rp-patient-calendar-picker .rp-calendar-weekdays span{
  color:#111827!important;
  background:transparent!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-calendar-toolbar strong,
.rp-prof-panel .rp-patient-calendar-picker .rp-cal-current-title{
  color:#102A56!important;
  font-weight:600!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-cal-nav{
  color:#102A56!important;
  background:#ffffff!important;
  border:1px solid #cbd5e1!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell,
.rp-prof-panel .rp-patient-calendar-picker button.rp-day-cell,
.rp-prof-panel .rp-patient-calendar-picker .rp-patient-calendar-grid .rp-day-cell,
.rp-prof-panel .rp-patient-calendar-picker .rp-admin-calendar .rp-day-cell{
  background:#ffffff!important;
  color:#111827!important;
  border:1px solid #d9e2ec!important;
  box-shadow:none!important;
  opacity:1!important;
  filter:none!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell strong{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  min-width:24px!important;
  height:24px!important;
  padding:0 6px!important;
  border-radius:7px!important;
  background:transparent!important;
  color:#111827!important;
  font-weight:600!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell em{
  display:inline-flex!important;
  width:auto!important;
  max-width:100%!important;
  margin-top:8px!important;
  padding:4px 8px!important;
  border-radius:7px!important;
  font-style:normal!important;
  font-size:12px!important;
  line-height:1.15!important;
  font-weight:400!important;
  color:#111827!important;
  background:#e5e7eb!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.is-free em{
  background:#dcfce7!important;
  color:#14532d!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.is-past em,
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.is-blocked em{
  background:#e5e7eb!important;
  color:#374151!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.is-free{
  border-color:#bbf7d0!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.is-past,
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.is-blocked{
  background:#ffffff!important;
  border-color:#e5e7eb!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.has-patients{
  background:#ffffff!important;
  border-color:#bfdbfe!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.has-patients em,
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.has-patients small{
  background:#dbeafe!important;
  color:#102A56!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell span,
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell small,
.rp-prof-panel .rp-patient-calendar-picker .rp-turno-bubble{
  color:#111827!important;
  background:#f3f4f6!important;
  font-weight:400!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-turno-bubble.rp-status-cancelado,
.rp-prof-panel .rp-patient-calendar-picker .rp-turno-bubble.rp-status-cancelada,
.rp-prof-panel .rp-patient-calendar-picker .rp-turno-bubble.rp-status-ausente{
  color:#7f1d1d!important;
  background:#fee2e2!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-turno-bubble.rp-status-confirmado,
.rp-prof-panel .rp-patient-calendar-picker .rp-turno-bubble.rp-status-atendido,
.rp-prof-panel .rp-patient-calendar-picker .rp-turno-bubble.rp-status-sesion_iniciada{
  color:#14532d!important;
  background:#dcfce7!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.selected,
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.is-selected,
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.preview-selected,
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.selected-unavailable{
  background:#ffffff!important;
  color:#111827!important;
  border-color:#102A56!important;
  box-shadow:0 0 0 2px rgba(16,42,86,.20)!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.selected strong,
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.is-selected strong,
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.preview-selected strong,
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.selected-unavailable strong{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#ffffff!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-availability-dot{
  width:11px!important;
  height:11px!important;
  border-radius:999px!important;
  border:2px solid #ffffff!important;
  box-shadow:0 1px 4px rgba(15,23,42,.22)!important;
  opacity:1!important;
  color:transparent!important;
  background:#9ca3af!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-availability-dot.is-on{background:#059669!important;}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-availability-dot.is-off{background:#9ca3af!important;}
.rp-prof-panel .rp-patient-calendar-picker .rp-calendar-day-info,
.rp-prof-panel .rp-patient-calendar-picker .rp-day-availability-card,
.rp-prof-panel .rp-patient-calendar-picker .rp-day-availability-panel{
  background:#ffffff!important;
  color:#111827!important;
  border-color:#d9e2ec!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-calendar-day-info.is-on,
.rp-prof-panel .rp-patient-calendar-picker .rp-day-availability-card.is-on{
  background:#ecfdf5!important;
  color:#14532d!important;
  border-color:#bbf7d0!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-calendar-day-info.is-off,
.rp-prof-panel .rp-patient-calendar-picker .rp-day-availability-card.is-off{
  background:#f3f4f6!important;
  color:#374151!important;
  border-color:#e5e7eb!important;
}

/* v267 - Calendario paciente: auditoría final de contraste y estados visibles */
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap,
.rp-prof-panel .rp-patient-calendar-below .rp-vbz-calendar-wrap{
  background:#fff!important;
  border:1px solid #111827!important;
  color:#111827!important;
}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap *,
.rp-prof-panel .rp-patient-calendar-below .rp-vbz-calendar-wrap *{
  -webkit-text-fill-color:currentColor!important;
  text-shadow:none!important;
  opacity:1!important;
  filter:none!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-calendar-toolbar,
.rp-prof-panel .rp-patient-calendar-below .rp-calendar-toolbar{
  background:#fff!important;
  color:#111827!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-calendar-toolbar strong,
.rp-prof-panel .rp-patient-calendar-picker .rp-cal-current-title,
.rp-prof-panel .rp-patient-calendar-below .rp-calendar-toolbar strong,
.rp-prof-panel .rp-patient-calendar-below .rp-cal-current-title{
  color:#111827!important;
  background:transparent!important;
  font-weight:600!important;
  display:block!important;
  visibility:visible!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-calendar-toolbar span,
.rp-prof-panel .rp-patient-calendar-below .rp-calendar-toolbar span{
  color:#111827!important;
  background:transparent!important;
  font-weight:400!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-cal-nav,
.rp-prof-panel .rp-patient-calendar-below .rp-cal-nav{
  color:#111827!important;
  background:#fff!important;
  border:1px solid #111827!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-calendar-weekdays span,
.rp-prof-panel .rp-patient-calendar-below .rp-calendar-weekdays span{
  color:#111827!important;
  background:transparent!important;
  font-weight:600!important;
  text-align:center!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell,
.rp-prof-panel .rp-patient-calendar-below .rp-day-cell,
.rp-prof-panel .rp-patient-calendar-picker button.rp-day-cell,
.rp-prof-panel .rp-patient-calendar-below button.rp-day-cell{
  background:#fff!important;
  border:1px solid #111827!important;
  color:#111827!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell strong,
.rp-prof-panel .rp-patient-calendar-below .rp-day-cell strong{
  color:#111827!important;
  background:transparent!important;
  font-weight:600!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell em,
.rp-prof-panel .rp-patient-calendar-below .rp-day-cell em{
  display:inline-flex!important;
  visibility:visible!important;
  color:#111827!important;
  background:#f3f4f6!important;
  font-weight:400!important;
  font-style:normal!important;
  border-radius:7px!important;
  padding:4px 8px!important;
  line-height:1.15!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.is-free em,
.rp-prof-panel .rp-patient-calendar-below .rp-day-cell.is-free em{
  color:#14532d!important;
  background:#dcfce7!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.is-blocked em,
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.is-past em,
.rp-prof-panel .rp-patient-calendar-below .rp-day-cell.is-blocked em,
.rp-prof-panel .rp-patient-calendar-below .rp-day-cell.is-past em{
  color:#111827!important;
  background:#e5e7eb!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.has-patients,
.rp-prof-panel .rp-patient-calendar-below .rp-day-cell.has-patients{
  background:#fff!important;
  border-color:#111827!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-turno-bubbles,
.rp-prof-panel .rp-patient-calendar-below .rp-turno-bubbles{
  display:flex!important;
  flex-wrap:wrap!important;
  gap:5px!important;
  margin-top:6px!important;
  visibility:visible!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-turno-bubble,
.rp-prof-panel .rp-patient-calendar-below .rp-turno-bubble{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  visibility:visible!important;
  color:#111827!important;
  background:#e5e7eb!important;
  border:1px solid #d1d5db!important;
  font-weight:400!important;
  opacity:1!important;
  min-width:44px!important;
  height:22px!important;
  border-radius:999px!important;
  padding:0 8px!important;
  font-size:11px!important;
  line-height:1!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-turno-bubble.rp-status-cancelado,
.rp-prof-panel .rp-patient-calendar-picker .rp-turno-bubble.rp-status-cancelada,
.rp-prof-panel .rp-patient-calendar-picker .rp-turno-bubble.rp-status-ausente,
.rp-prof-panel .rp-patient-calendar-below .rp-turno-bubble.rp-status-cancelado,
.rp-prof-panel .rp-patient-calendar-below .rp-turno-bubble.rp-status-cancelada,
.rp-prof-panel .rp-patient-calendar-below .rp-turno-bubble.rp-status-ausente{
  color:#7f1d1d!important;
  background:#fee2e2!important;
  border-color:#fecaca!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-turno-bubble.rp-status-confirmado,
.rp-prof-panel .rp-patient-calendar-picker .rp-turno-bubble.rp-status-atendido,
.rp-prof-panel .rp-patient-calendar-picker .rp-turno-bubble.rp-status-sesion_iniciada,
.rp-prof-panel .rp-patient-calendar-below .rp-turno-bubble.rp-status-confirmado,
.rp-prof-panel .rp-patient-calendar-below .rp-turno-bubble.rp-status-atendido,
.rp-prof-panel .rp-patient-calendar-below .rp-turno-bubble.rp-status-sesion_iniciada{
  color:#14532d!important;
  background:#dcfce7!important;
  border-color:#bbf7d0!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.selected,
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.preview-selected,
.rp-prof-panel .rp-patient-calendar-below .rp-day-cell.selected,
.rp-prof-panel .rp-patient-calendar-below .rp-day-cell.preview-selected{
  background:#fff!important;
  border:2px solid #102A56!important;
  color:#111827!important;
  box-shadow:0 0 0 2px rgba(16,42,86,.18)!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.selected strong,
.rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.preview-selected strong,
.rp-prof-panel .rp-patient-calendar-below .rp-day-cell.selected strong,
.rp-prof-panel .rp-patient-calendar-below .rp-day-cell.preview-selected strong{
  color:#fff!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-availability-dot,
.rp-prof-panel .rp-patient-calendar-below .rp-day-availability-dot{
  display:block!important;
  width:11px!important;
  height:11px!important;
  border-radius:999px!important;
  border:2px solid #fff!important;
  box-shadow:0 1px 4px rgba(17,24,39,.25)!important;
  color:transparent!important;
  opacity:1!important;
  visibility:visible!important;
}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-availability-dot.is-on,
.rp-prof-panel .rp-patient-calendar-below .rp-day-availability-dot.is-on{background:#059669!important;}
.rp-prof-panel .rp-patient-calendar-picker .rp-day-availability-dot.is-off,
.rp-prof-panel .rp-patient-calendar-below .rp-day-availability-dot.is-off{background:#9ca3af!important;}

/* v272 - BLINDAJE FINAL calendario de ficha paciente claro.
   Objetivo: solo fondo blanco; textos y números negros; estados verde/rojo/gris; bordes visibles. */
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap,
.rp-prof-panel .rp-patient-calendar-below .rp-vbz-calendar-wrap,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-patient-calendar-grid,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-admin-calendar{
    background:#ffffff!important;
    background-color:#ffffff!important;
    color:#111827!important;
    -webkit-text-fill-color:#111827!important;
    border-color:#111827!important;
    opacity:1!important;
    filter:none!important;
    text-shadow:none!important;
}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap *:not(svg):not(path):not(.rp-day-availability-dot){
    color:#111827!important;
    -webkit-text-fill-color:#111827!important;
    text-shadow:none!important;
    filter:none!important;
    opacity:1!important;
}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar *,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-weekdays,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-weekdays span{
    background:transparent!important;
    color:#111827!important;
    -webkit-text-fill-color:#111827!important;
}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar strong,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-cal-current-title{
    color:#111827!important;
    -webkit-text-fill-color:#111827!important;
    font-weight:700!important;
    display:block!important;
    visibility:visible!important;
}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-cal-nav{
    background:#ffffff!important;
    color:#111827!important;
    -webkit-text-fill-color:#111827!important;
    border:1px solid #111827!important;
    box-shadow:none!important;
}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-patient-calendar-grid{
    gap:8px!important;
}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap button.rp-day-cell,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-patient-date-pick{
    background:#ffffff!important;
    background-color:#ffffff!important;
    color:#111827!important;
    -webkit-text-fill-color:#111827!important;
    border:1px solid #111827!important;
    outline:0!important;
    box-shadow:none!important;
    opacity:1!important;
    filter:none!important;
    text-shadow:none!important;
}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell strong,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell .rp-day-number{
    color:#111827!important;
    -webkit-text-fill-color:#111827!important;
    background:transparent!important;
    border:0!important;
    font-weight:700!important;
    opacity:1!important;
    visibility:visible!important;
}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell em,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell small,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell span:not(.rp-day-availability-dot),
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-turno-bubble{
    display:inline-flex!important;
    align-items:center!important;
    width:auto!important;
    max-width:100%!important;
    border-radius:8px!important;
    padding:4px 8px!important;
    font-size:12px!important;
    line-height:1.15!important;
    font-style:normal!important;
    font-weight:400!important;
    color:#111827!important;
    -webkit-text-fill-color:#111827!important;
    background:#e5e7eb!important;
    border:1px solid #d1d5db!important;
    opacity:1!important;
    visibility:visible!important;
}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.is-free em,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.is-free small,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.is-free span:not(.rp-day-availability-dot){
    color:#14532d!important;
    -webkit-text-fill-color:#14532d!important;
    background:#dcfce7!important;
    border-color:#bbf7d0!important;
}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.is-blocked em,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.is-blocked small,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.is-blocked span:not(.rp-day-availability-dot),
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.is-past em,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.is-past small,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.is-past span:not(.rp-day-availability-dot){
    color:#111827!important;
    -webkit-text-fill-color:#111827!important;
    background:#e5e7eb!important;
    border-color:#d1d5db!important;
}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-turno-bubble.rp-status-cancelado,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-turno-bubble.rp-status-cancelada,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-turno-bubble.rp-status-ausente{
    color:#7f1d1d!important;
    -webkit-text-fill-color:#7f1d1d!important;
    background:#fee2e2!important;
    border-color:#fecaca!important;
}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-turno-bubble.rp-status-confirmado,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-turno-bubble.rp-status-atendido,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-turno-bubble.rp-status-sesion_iniciada{
    color:#14532d!important;
    -webkit-text-fill-color:#14532d!important;
    background:#dcfce7!important;
    border-color:#bbf7d0!important;
}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.selected,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.preview-selected,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.is-selected,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.selected-unavailable{
    background:#ffffff!important;
    color:#111827!important;
    -webkit-text-fill-color:#111827!important;
    border:2px solid #102A56!important;
    box-shadow:0 0 0 2px rgba(16,42,86,.16)!important;
}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.selected strong,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.preview-selected strong,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.is-selected strong{
    color:#ffffff!important;
    -webkit-text-fill-color:#ffffff!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    border-radius:7px!important;
    padding:3px 7px!important;
}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-availability-dot{
    display:block!important;
    position:absolute!important;
    top:7px!important;
    right:7px!important;
    width:11px!important;
    height:11px!important;
    border-radius:999px!important;
    color:transparent!important;
    -webkit-text-fill-color:transparent!important;
    background:#9ca3af!important;
    border:2px solid #ffffff!important;
    box-shadow:0 1px 4px rgba(17,24,39,.25)!important;
    opacity:1!important;
    visibility:visible!important;
}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-availability-dot.is-on{background:#059669!important;}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-availability-dot.is-off{background:#9ca3af!important;}


/* v275 fallback calendario paciente: scope duro para evitar herencias de disponibilidad */
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap{background:#fff!important;border:1px solid #E5E7EB!important;box-shadow:none!important;}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap button.rp-day-cell,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-patient-date-pick{border:1px solid #D9DEE6!important;background:#fff!important;box-shadow:none!important;color:#111827!important;-webkit-text-fill-color:#111827!important;}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.is-past,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.is-blocked{background:#F9FAFB!important;border-color:#E5E7EB!important;opacity:.46!important;filter:grayscale(.15)!important;}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.is-free em{background:#DCFCE7!important;color:#14532D!important;-webkit-text-fill-color:#14532D!important;border:0!important;}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.is-past em,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell.is-blocked em{background:#E5E7EB!important;color:#4B5563!important;-webkit-text-fill-color:#4B5563!important;border:0!important;}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell .rp-turno-bubbles > .rp-turno-bubble{border:0!important;box-shadow:none!important;opacity:1!important;filter:none!important;font-weight:400!important;}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell .rp-turno-bubbles > .rp-turno-bubble.rp-type-regular,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell .rp-turno-bubbles > .rp-turno-bubble:not(.rp-type-emergency):not(.rp-more){background:#DFF3FF!important;color:#075985!important;-webkit-text-fill-color:#075985!important;border:0!important;}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell .rp-turno-bubbles > .rp-turno-bubble.rp-type-emergency{background:#FFEDD5!important;color:#9A3412!important;-webkit-text-fill-color:#9A3412!important;border:0!important;}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell .rp-turno-bubbles > .rp-turno-bubble.rp-type-emergency::before{content:'!'!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;width:13px!important;height:13px!important;margin-right:4px!important;border:1px solid currentColor!important;border-radius:999px!important;font-size:9px!important;line-height:1!important;font-weight:600!important;}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell .rp-turno-bubbles > .rp-turno-bubble.rp-type-rescheduled,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell .rp-turno-bubbles > .rp-turno-bubble.rp-status-reprogramado,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell .rp-turno-bubbles > .rp-turno-bubble.rp-status-reprogramada,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell .rp-turno-bubbles > .rp-turno-bubble.rp-status-cancelado,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell .rp-turno-bubbles > .rp-turno-bubble.rp-status-cancelada,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell .rp-turno-bubbles > .rp-turno-bubble.rp-status-ausente,
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell .rp-turno-bubbles > .rp-turno-bubble.rp-status-pendiente_cancelacion{display:none!important;}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-patient-date-pick.is-reprogram-old{outline:2px dashed #F59E0B!important;outline-offset:-8px!important;border-color:#D9DEE6!important;opacity:1!important;}
.rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-patient-date-pick.is-reprogram-old::after{content:''!important;display:none!important;}

/* v276 - ajustes agenda paciente */
.rp-prof-panel .rp-patient-schedule-card > .rp-patient-agenda-title{
    display:flex!important;
    align-items:center!important;
    gap:10px!important;
    font-size:26px!important;
    line-height:1.18!important;
    font-weight:400!important;
    color:#111827!important;
    margin:0 0 8px!important;
}
.rp-prof-panel .rp-patient-schedule-card > .rp-patient-agenda-title .rp-line-svg{
    width:24px!important;
    height:24px!important;
    min-width:24px!important;
    stroke:#102A56!important;
    stroke-width:1.35!important;
    fill:none!important;
}
.rp-prof-panel .rp-patient-appointment-form label:has(input[name="meet_link"]){
    display:none!important;
}
.rp-prof-panel .rp-form-grid label.rp-emergency-switch{
    background:#F97316!important;
    border:0!important;
    box-shadow:none!important;
    color:#111827!important;
    font-weight:400!important;
}
.rp-prof-panel .rp-form-grid label.rp-emergency-switch input[type="checkbox"]{
    accent-color:#F97316!important;
}
.rp-prof-panel .rp-form-grid label.rp-emergency-switch span{
    color:#111827!important;
    font-weight:400!important;
}
.rp-prof-panel .rp-form-grid label.rp-emergency-switch svg{
    stroke:#111827!important;
    stroke-width:1.35!important;
    fill:none!important;
}
.rp-prof-panel .rp-form-grid label.rp-emergency-switch:has(input:checked){
    background:#F97316!important;
    border:0!important;
    box-shadow:none!important;
}

/* v2.7.7 - Ficha paciente: agenda e historiales ordenados */
.rp-patient-schedule-card .rp-save-appointment-btn{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  border:0!important;
  font-weight:400!important;
  gap:8px!important;
  min-height:48px!important;
  padding:12px 20px!important;
  border-radius:12px!important;
}
.rp-patient-schedule-card .rp-save-appointment-btn svg,
.rp-history-actions .rp-mini-action svg{
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.45!important;
}
.rp-patient-history-stack{
  display:grid!important;
  grid-template-columns:1fr!important;
  gap:16px!important;
  margin-top:18px!important;
}
.rp-history-accordion{
  padding:0!important;
  overflow:hidden!important;
  border:1px solid #E5E7EB!important;
  border-radius:18px!important;
  background:#fff!important;
  box-shadow:none!important;
}
.rp-history-accordion summary::-webkit-details-marker{display:none!important;}
.rp-history-summary{
  list-style:none!important;
  cursor:pointer!important;
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:14px!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  padding:16px 18px!important;
  font-size:18px!important;
  font-weight:400!important;
}
.rp-history-summary span{
  display:inline-flex!important;
  align-items:center!important;
  gap:10px!important;
  color:#fff!important;
  font-weight:400!important;
}
.rp-history-summary svg{color:#fff!important;fill:none!important;stroke:currentColor!important;stroke-width:1.45!important;}
.rp-history-accordion[open] .rp-chevron-svg{transform:rotate(180deg);}
.rp-history-body{
  background:#fff!important;
  padding:18px!important;
  color:#1F2937!important;
}
.rp-history-table-wrap{width:100%!important;overflow:auto!important;}
.rp-history-table{
  width:100%!important;
  border-collapse:separate!important;
  border-spacing:0!important;
  min-width:920px!important;
  color:#1F2937!important;
}
.rp-history-table thead th{
  background:#F8FAFC!important;
  color:#334155!important;
  text-align:center!important;
  font-size:12px!important;
  letter-spacing:.03em!important;
  text-transform:uppercase!important;
  font-weight:400!important;
  padding:12px 10px!important;
  border-bottom:1px solid #E5E7EB!important;
  white-space:nowrap!important;
}
.rp-history-table tbody tr,
.rp-history-table tbody .rp-session-chip,
.rp-history-table tbody .rp-cancel-chip{
  display:table-row!important;
  background:#fff!important;
  border:0!important;
  box-shadow:none!important;
  padding:0!important;
  margin:0!important;
}
.rp-history-table tbody td{
  padding:13px 10px!important;
  border-bottom:1px solid #EEF2F6!important;
  text-align:center!important;
  vertical-align:middle!important;
  font-size:14px!important;
  color:#1F2937!important;
  white-space:nowrap!important;
}
.rp-history-table tbody tr:last-child td{border-bottom:0!important;}
.rp-session-type-badge,
.rp-session-billing-status,
.rp-cancel-status{
  border:0!important;
  box-shadow:none!important;
  outline:0!important;
  font-weight:400!important;
  border-radius:999px!important;
  padding:6px 10px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  line-height:1!important;
}
.rp-history-actions{
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:8px!important;
}
.rp-history-actions form{display:inline-flex!important;margin:0!important;}
.rp-history-actions .rp-mini-action{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:6px!important;
  height:34px!important;
  min-height:34px!important;
  padding:0 10px!important;
  border:1px solid #D6DDE8!important;
  border-radius:10px!important;
  background:#fff!important;
  color:#102A56!important;
  font-size:12px!important;
  font-weight:400!important;
  line-height:1!important;
  white-space:nowrap!important;
}
.rp-history-actions .rp-cancel-session{color:#9A3412!important;border-color:#FED7AA!important;background:#FFF7ED!important;}
.rp-history-actions .rp-confirm-pending-session{color:#166534!important;border-color:#BBF7D0!important;background:#F0FDF4!important;}
.rp-history-actions .rp-mini-action.is-disabled{opacity:.45!important;cursor:not-allowed!important;}
@media(max-width:780px){
  .rp-history-body{padding:12px!important;}
  .rp-history-summary{font-size:16px!important;padding:14px!important;}
  .rp-history-table{min-width:780px!important;}
}

/* v278 - ficha paciente: historial compacto, limpio y alineado */
.rp-prof-panel .rp-patient-history-stack{
  gap:12px!important;
  margin-top:14px!important;
}
.rp-prof-panel .rp-history-accordion{
  border:1px solid #E5E7EB!important;
  border-radius:16px!important;
  background:#fff!important;
  overflow:hidden!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-history-summary{
  min-height:44px!important;
  padding:10px 14px!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  font-size:15px!important;
  line-height:1.2!important;
  font-weight:400!important;
  border-radius:0!important;
}
.rp-prof-panel .rp-history-summary span{
  gap:8px!important;
  font-size:15px!important;
  font-weight:400!important;
  line-height:1.2!important;
}
.rp-prof-panel .rp-history-summary svg{
  width:16px!important;
  height:16px!important;
  stroke-width:1.35!important;
}
.rp-prof-panel .rp-history-body{
  padding:12px 14px 14px!important;
  background:#fff!important;
}
.rp-prof-panel .rp-session-history-filters{
  gap:7px!important;
  margin:0 0 10px!important;
}
.rp-prof-panel .rp-session-history-filters button{
  height:28px!important;
  min-height:28px!important;
  padding:0 10px!important;
  border-radius:999px!important;
  font-size:12px!important;
  line-height:1!important;
  font-weight:400!important;
  border:1px solid #D7DEE8!important;
  background:#fff!important;
  color:#344054!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-session-history-filters button.is-active{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  border-color:#102A56!important;
  color:#fff!important;
  font-weight:400!important;
}
.rp-prof-panel .rp-history-table-wrap{
  border:1px solid #E6EAF0!important;
  border-radius:13px!important;
  overflow:auto!important;
  background:#fff!important;
}
.rp-prof-panel table.rp-history-table{
  width:100%!important;
  min-width:760px!important;
  border-collapse:collapse!important;
  border-spacing:0!important;
  table-layout:fixed!important;
  color:#1F2937!important;
}
.rp-prof-panel .rp-cancel-history-table{
  min-width:560px!important;
}
.rp-prof-panel .rp-history-table thead th{
  height:36px!important;
  padding:7px 8px!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  text-align:center!important;
  vertical-align:middle!important;
  font-size:11px!important;
  line-height:1.1!important;
  font-weight:400!important;
  text-transform:uppercase!important;
  letter-spacing:.025em!important;
  border:0!important;
  border-right:1px solid rgba(255,255,255,.12)!important;
}
.rp-prof-panel .rp-history-table thead th:last-child{border-right:0!important;}
.rp-prof-panel .rp-history-table tbody tr{
  height:42px!important;
  background:#fff!important;
}
.rp-prof-panel .rp-history-table tbody tr:nth-child(even){background:#F9FAFB!important;}
.rp-prof-panel .rp-history-table tbody td{
  padding:7px 8px!important;
  height:42px!important;
  min-height:42px!important;
  border-bottom:1px solid #EDF1F5!important;
  border-right:1px solid #F2F4F7!important;
  text-align:center!important;
  vertical-align:middle!important;
  font-size:12.5px!important;
  line-height:1.25!important;
  font-weight:400!important;
  color:#1F2937!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
}
.rp-prof-panel .rp-history-table tbody td:last-child{border-right:0!important;}
.rp-prof-panel .rp-history-table tbody tr:last-child td{border-bottom:0!important;}
.rp-prof-panel .rp-history-table .rp-session-date,
.rp-prof-panel .rp-history-table .rp-cancel-date{
  font-weight:500!important;
  font-size:12.5px!important;
  color:#111827!important;
}
.rp-prof-panel .rp-history-table .rp-session-meta,
.rp-prof-panel .rp-history-table .rp-cancel-time,
.rp-prof-panel .rp-history-table .rp-cancel-amount{
  font-size:12.5px!important;
  font-weight:400!important;
  color:#344054!important;
}
.rp-prof-panel .rp-history-table .rp-session-amount{
  font-size:12.5px!important;
  font-weight:500!important;
  color:#102A56!important;
  text-align:center!important;
}
.rp-prof-panel .rp-session-status{
  font-size:12.5px!important;
  font-weight:400!important;
  color:#1F2937!important;
}
.rp-prof-panel .rp-session-type-badge,
.rp-prof-panel .rp-session-billing-status,
.rp-prof-panel .rp-cancel-status{
  min-height:20px!important;
  padding:4px 8px!important;
  border:0!important;
  border-radius:999px!important;
  font-size:11px!important;
  line-height:1!important;
  font-weight:400!important;
  box-shadow:none!important;
  outline:0!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  white-space:nowrap!important;
}
.rp-prof-panel .rp-session-type-badge-emergency{
  background:#FFEDD5!important;
  color:#9A3412!important;
}
.rp-prof-panel .rp-session-type-badge-regular{
  background:#E0F2FE!important;
  color:#075985!important;
}
.rp-prof-panel .rp-billing-status-paid,
.rp-prof-panel .rp-billing-status-pagado{
  background:#DCFCE7!important;
  color:#166534!important;
}
.rp-prof-panel .rp-billing-status-pending,
.rp-prof-panel .rp-billing-status-pendiente,
.rp-prof-panel .rp-billing-status-due{
  background:#FEF3C7!important;
  color:#92400E!important;
}
.rp-prof-panel .rp-cancel-status{
  background:#F2F4F7!important;
  color:#667085!important;
}
.rp-prof-panel .rp-history-actions{
  gap:6px!important;
  flex-wrap:nowrap!important;
}
.rp-prof-panel .rp-history-actions .rp-mini-action{
  height:28px!important;
  min-height:28px!important;
  padding:0 8px!important;
  border-radius:8px!important;
  font-size:11.5px!important;
  line-height:1!important;
  font-weight:400!important;
  gap:5px!important;
  border:1px solid #D6DDE8!important;
  background:#fff!important;
  color:#102A56!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-history-actions .rp-mini-action svg{
  width:13px!important;
  height:13px!important;
  stroke-width:1.35!important;
}
.rp-prof-panel .rp-history-actions .rp-cancel-session{
  background:#FFF7ED!important;
  color:#9A3412!important;
  border-color:#FED7AA!important;
}
.rp-prof-panel .rp-history-actions .rp-mini-action.is-disabled{
  opacity:.38!important;
  background:#F9FAFB!important;
}
.rp-prof-panel .rp-session-history-table th:nth-child(1),
.rp-prof-panel .rp-session-history-table td:nth-child(1){width:13%!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(2),
.rp-prof-panel .rp-session-history-table td:nth-child(2){width:13%!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(3),
.rp-prof-panel .rp-session-history-table td:nth-child(3){width:15%!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(4),
.rp-prof-panel .rp-session-history-table td:nth-child(4){width:12%!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(5),
.rp-prof-panel .rp-session-history-table td:nth-child(5){width:11%!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(6),
.rp-prof-panel .rp-session-history-table td:nth-child(6){width:14%!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(7),
.rp-prof-panel .rp-session-history-table td:nth-child(7){width:22%!important;}
@media(max-width:780px){
  .rp-prof-panel .rp-history-summary{font-size:14px!important;padding:10px 12px!important;}
  .rp-prof-panel .rp-history-body{padding:10px!important;}
  .rp-prof-panel table.rp-history-table{min-width:720px!important;}
  .rp-prof-panel .rp-history-table tbody td{font-size:12px!important;}
}

/* v279 - Ficha paciente: historial corregido sin columnas cortadas */
.rp-prof-panel .rp-patient-history-stack{
  gap:14px!important;
  margin-top:16px!important;
}
.rp-prof-panel .rp-history-accordion{
  border:1px solid #E5E7EB!important;
  border-radius:16px!important;
  overflow:hidden!important;
  background:#fff!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-history-summary{
  min-height:42px!important;
  padding:10px 14px!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  font-size:15px!important;
  font-weight:400!important;
  line-height:1.15!important;
}
.rp-prof-panel .rp-history-summary span{
  display:inline-flex!important;
  align-items:center!important;
  gap:8px!important;
  font-size:15px!important;
  font-weight:400!important;
  color:#fff!important;
}
.rp-prof-panel .rp-history-summary svg{
  width:16px!important;
  height:16px!important;
  stroke-width:1.35!important;
  fill:none!important;
  stroke:currentColor!important;
}
.rp-prof-panel .rp-history-body{
  padding:12px!important;
  background:#fff!important;
}
.rp-prof-panel .rp-session-history-filters{
  display:flex!important;
  align-items:center!important;
  gap:7px!important;
  margin:0 0 10px!important;
}
.rp-prof-panel .rp-session-history-filters button{
  appearance:none!important;
  height:28px!important;
  min-height:28px!important;
  padding:0 11px!important;
  border-radius:999px!important;
  border:1px solid #D7DEE8!important;
  background:#fff!important;
  color:#344054!important;
  font-size:12px!important;
  font-weight:400!important;
  line-height:1!important;
  cursor:pointer!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-session-history-filters button.is-active{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  border-color:#102A56!important;
  color:#fff!important;
}
.rp-prof-panel .rp-history-table-wrap{
  width:100%!important;
  overflow-x:auto!important;
  overflow-y:visible!important;
  border:1px solid #E6EAF0!important;
  border-radius:13px!important;
  background:#fff!important;
}
.rp-prof-panel table.rp-history-table,
.rp-prof-panel table.rp-session-history-table,
.rp-prof-panel table.rp-cancel-history-table{
  width:100%!important;
  min-width:1040px!important;
  border-collapse:collapse!important;
  border-spacing:0!important;
  table-layout:auto!important;
  color:#1F2937!important;
}
.rp-prof-panel table.rp-cancel-history-table{
  min-width:720px!important;
}
.rp-prof-panel .rp-history-table thead th{
  height:34px!important;
  padding:7px 10px!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  text-align:center!important;
  vertical-align:middle!important;
  font-size:11px!important;
  line-height:1.1!important;
  font-weight:400!important;
  text-transform:uppercase!important;
  letter-spacing:.025em!important;
  border:0!important;
  border-right:1px solid rgba(255,255,255,.12)!important;
  white-space:nowrap!important;
}
.rp-prof-panel .rp-history-table thead th:last-child{border-right:0!important;}
.rp-prof-panel .rp-history-table tbody tr{
  height:40px!important;
  background:#fff!important;
}
.rp-prof-panel .rp-history-table tbody tr:nth-child(even){background:#F9FAFB!important;}
.rp-prof-panel .rp-history-table tbody td{
  height:40px!important;
  min-height:40px!important;
  padding:7px 10px!important;
  border-bottom:1px solid #EDF1F5!important;
  border-right:1px solid #F2F4F7!important;
  text-align:center!important;
  vertical-align:middle!important;
  font-size:12.5px!important;
  line-height:1.2!important;
  font-weight:400!important;
  color:#1F2937!important;
  white-space:nowrap!important;
  overflow:visible!important;
  text-overflow:clip!important;
}
.rp-prof-panel .rp-history-table tbody td:last-child{border-right:0!important;}
.rp-prof-panel .rp-history-table tbody tr:last-child td{border-bottom:0!important;}
.rp-prof-panel .rp-history-table .rp-session-date,
.rp-prof-panel .rp-history-table .rp-cancel-date{
  font-weight:500!important;
  color:#111827!important;
  font-size:12.5px!important;
}
.rp-prof-panel .rp-history-table .rp-session-meta,
.rp-prof-panel .rp-history-table .rp-cancel-time,
.rp-prof-panel .rp-history-table .rp-cancel-amount{
  color:#344054!important;
  font-size:12.5px!important;
  font-weight:400!important;
}
.rp-prof-panel .rp-history-table .rp-session-amount{
  color:#102A56!important;
  font-weight:500!important;
  text-align:center!important;
}
.rp-prof-panel .rp-history-table .rp-session-status{
  font-size:12.5px!important;
  color:#1F2937!important;
  font-weight:400!important;
  width:auto!important;
}
.rp-prof-panel .rp-session-type-badge,
.rp-prof-panel .rp-session-billing-status,
.rp-prof-panel .rp-cancel-status{
  min-height:20px!important;
  padding:4px 8px!important;
  border:0!important;
  border-radius:999px!important;
  font-size:11px!important;
  font-weight:400!important;
  line-height:1!important;
  box-shadow:none!important;
  outline:0!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:auto!important;
  max-width:none!important;
  white-space:nowrap!important;
}
.rp-prof-panel .rp-session-type-badge-emergency{background:#FFEDD5!important;color:#9A3412!important;}
.rp-prof-panel .rp-session-type-badge-regular{background:#E0F2FE!important;color:#075985!important;}
.rp-prof-panel .rp-billing-status-paid,
.rp-prof-panel .rp-billing-status-pagado{background:#DCFCE7!important;color:#166534!important;}
.rp-prof-panel .rp-billing-status-pending,
.rp-prof-panel .rp-billing-status-pendiente,
.rp-prof-panel .rp-billing-status-due{background:#FEF3C7!important;color:#92400E!important;}
.rp-prof-panel .rp-cancel-status{background:#F2F4F7!important;color:#667085!important;}
.rp-prof-panel .rp-history-actions{
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:6px!important;
  flex-wrap:nowrap!important;
  min-width:230px!important;
}
.rp-prof-panel .rp-history-actions form{
  display:inline-flex!important;
  align-items:center!important;
  margin:0!important;
}
.rp-prof-panel .rp-history-actions .rp-mini-action{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:5px!important;
  height:28px!important;
  min-height:28px!important;
  min-width:92px!important;
  padding:0 9px!important;
  border-radius:8px!important;
  border:1px solid #D6DDE8!important;
  background:#fff!important;
  color:#102A56!important;
  font-size:11.5px!important;
  font-weight:400!important;
  line-height:1!important;
  white-space:nowrap!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-history-actions .rp-mini-action svg{
  width:13px!important;
  height:13px!important;
  stroke-width:1.35!important;
  fill:none!important;
  stroke:currentColor!important;
}
.rp-prof-panel .rp-history-actions .rp-cancel-session{
  background:#FFF7ED!important;
  color:#9A3412!important;
  border-color:#FED7AA!important;
}
.rp-prof-panel .rp-history-actions .rp-mini-action.is-disabled{
  opacity:.35!important;
  cursor:not-allowed!important;
  background:#F9FAFB!important;
}
.rp-prof-panel .rp-session-history-table th:nth-child(1),
.rp-prof-panel .rp-session-history-table td:nth-child(1){min-width:110px!important;width:auto!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(2),
.rp-prof-panel .rp-session-history-table td:nth-child(2){min-width:115px!important;width:auto!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(3),
.rp-prof-panel .rp-session-history-table td:nth-child(3){min-width:150px!important;width:auto!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(4),
.rp-prof-panel .rp-session-history-table td:nth-child(4){min-width:120px!important;width:auto!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(5),
.rp-prof-panel .rp-session-history-table td:nth-child(5){min-width:105px!important;width:auto!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(6),
.rp-prof-panel .rp-session-history-table td:nth-child(6){min-width:140px!important;width:auto!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(7),
.rp-prof-panel .rp-session-history-table td:nth-child(7){min-width:240px!important;width:auto!important;}
.rp-prof-panel .rp-patient-schedule-card .rp-save-appointment-btn{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  border:0!important;
  font-weight:400!important;
  gap:8px!important;
}
@media(max-width:780px){
  .rp-prof-panel table.rp-history-table,
  .rp-prof-panel table.rp-session-history-table{min-width:980px!important;}
  .rp-prof-panel table.rp-cancel-history-table{min-width:680px!important;}
  .rp-prof-panel .rp-history-body{padding:10px!important;}
}


/* v281 - historial: compactado real y filtros blindados */
.rp-prof-panel .rp-session-history-card tr.rp-session-hidden-by-filter,
.rp-session-history-card tr.rp-session-hidden-by-filter{
  display:none!important;
}
.rp-prof-panel .rp-history-body{padding:10px!important;}
.rp-prof-panel .rp-session-history-filters{gap:6px!important;margin:0 0 8px!important;}
.rp-prof-panel .rp-session-history-filters button{
  height:24px!important;min-height:24px!important;padding:0 9px!important;
  font-size:11px!important;font-weight:400!important;line-height:1!important;
  border-radius:999px!important;border:1px solid #D7DEE8!important;background:#fff!important;color:#344054!important;
}
.rp-prof-panel .rp-session-history-filters button.is-active{background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;border-color:#102A56!important;color:#fff!important;}
.rp-prof-panel table.rp-history-table,
.rp-prof-panel table.rp-session-history-table,
.rp-prof-panel table.rp-cancel-history-table{
  table-layout:auto!important;min-width:0!important;width:100%!important;
}
.rp-prof-panel .rp-history-table thead th{
  height:30px!important;padding:6px 8px!important;font-size:10.5px!important;font-weight:400!important;line-height:1!important;
}
.rp-prof-panel .rp-history-table tbody tr{height:34px!important;}
.rp-prof-panel .rp-history-table tbody td{
  height:34px!important;min-height:34px!important;padding:5px 8px!important;
  font-size:11.5px!important;font-weight:400!important;line-height:1.1!important;
  white-space:nowrap!important;overflow:visible!important;text-overflow:clip!important;
}
.rp-prof-panel .rp-history-table .rp-session-date,
.rp-prof-panel .rp-history-table .rp-cancel-date,
.rp-prof-panel .rp-history-table .rp-session-meta,
.rp-prof-panel .rp-history-table .rp-cancel-time,
.rp-prof-panel .rp-history-table .rp-cancel-amount,
.rp-prof-panel .rp-history-table .rp-session-amount,
.rp-prof-panel .rp-history-table .rp-session-status{
  font-size:11.5px!important;font-weight:400!important;line-height:1.1!important;
}
.rp-prof-panel .rp-session-type-badge,
.rp-prof-panel .rp-session-billing-status,
.rp-prof-panel .rp-cancel-status{
  min-height:17px!important;height:17px!important;padding:2px 6px!important;
  border:0!important;border-radius:999px!important;font-size:9.8px!important;font-weight:400!important;
  line-height:1!important;box-shadow:none!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;
}
.rp-prof-panel .rp-history-actions{gap:5px!important;min-width:0!important;justify-content:center!important;}
.rp-prof-panel .rp-history-actions .rp-mini-action{
  height:24px!important;min-height:24px!important;min-width:78px!important;padding:0 7px!important;
  font-size:10.5px!important;font-weight:400!important;border-radius:7px!important;gap:4px!important;
}
.rp-prof-panel .rp-history-actions .rp-mini-action svg{width:12px!important;height:12px!important;stroke-width:1.25!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(1),.rp-prof-panel .rp-session-history-table td:nth-child(1){width:11%!important;min-width:82px!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(2),.rp-prof-panel .rp-session-history-table td:nth-child(2){width:11%!important;min-width:86px!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(3),.rp-prof-panel .rp-session-history-table td:nth-child(3){width:14%!important;min-width:104px!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(4),.rp-prof-panel .rp-session-history-table td:nth-child(4){width:11%!important;min-width:88px!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(5),.rp-prof-panel .rp-session-history-table td:nth-child(5){width:10%!important;min-width:82px!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(6),.rp-prof-panel .rp-session-history-table td:nth-child(6){width:12%!important;min-width:96px!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(7),.rp-prof-panel .rp-session-history-table td:nth-child(7){width:31%!important;min-width:210px!important;}
.rp-prof-panel .rp-cancel-history-table th,.rp-prof-panel .rp-cancel-history-table td{font-size:11.5px!important;}
@media(max-width:900px){
  .rp-prof-panel table.rp-session-history-table{min-width:880px!important;}
  .rp-prof-panel table.rp-cancel-history-table{min-width:620px!important;}
}

/* v282 - ficha paciente: chips de estado compactos definitivos */
.rp-prof-panel .rp-history-table .rp-session-status{
  text-align:center!important;
  font-size:0!important;
  line-height:1!important;
  padding:4px 6px!important;
}
.rp-prof-panel .rp-session-status-chip,
.rp-prof-panel .rp-session-billing-status,
.rp-prof-panel .rp-cancel-status,
.rp-prof-panel .rp-session-type-badge{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:auto!important;
  max-width:max-content!important;
  min-width:0!important;
  min-height:16px!important;
  height:16px!important;
  padding:1px 6px!important;
  margin:0!important;
  border:0!important;
  border-radius:999px!important;
  box-shadow:none!important;
  font-size:10px!important;
  font-weight:400!important;
  line-height:1!important;
  white-space:nowrap!important;
  letter-spacing:0!important;
}
.rp-prof-panel .rp-session-status-chip.rp-status-confirmado{background:#DCFCE7!important;color:#166534!important;}
.rp-prof-panel .rp-session-status-chip.rp-status-atendido{background:#DBEAFE!important;color:#1E40AF!important;}
.rp-prof-panel .rp-session-status-chip.rp-status-pendiente{background:#FEF3C7!important;color:#92400E!important;}
.rp-prof-panel .rp-session-status-chip.rp-status-cancelado{background:#E5E7EB!important;color:#374151!important;}
.rp-prof-panel .rp-session-status-chip.rp-status-reprogramado{background:#FFEDD5!important;color:#9A3412!important;}
.rp-prof-panel .rp-session-status-chip.rp-status-ausente{background:#FEE2E2!important;color:#991B1B!important;}
.rp-prof-panel .rp-session-billing-status.rp-billing-status-pendiente{background:#FEF3C7!important;color:#92400E!important;}
.rp-prof-panel .rp-session-billing-status.rp-billing-status-pagado,
.rp-prof-panel .rp-session-billing-status.rp-billing-status-done{background:#DCFCE7!important;color:#166534!important;}
.rp-prof-panel .rp-session-type-badge-emergency{background:#FFEDD5!important;color:#9A3412!important;}
.rp-prof-panel .rp-session-type-badge-regular{background:#E0F2FE!important;color:#075985!important;}
.rp-prof-panel .rp-cancel-status{background:#E5E7EB!important;color:#374151!important;}
.rp-prof-panel .rp-history-table tbody td{
  height:32px!important;
  min-height:32px!important;
  padding-top:4px!important;
  padding-bottom:4px!important;
}

/* v283 - ficha paciente: eliminar doble globo en columna Estado */
.rp-prof-panel table.rp-history-table td.rp-session-status,
.rp-prof-panel table.rp-session-history-table td.rp-session-status,
.rp-prof-panel .rp-history-table tbody td.rp-session-status{
  display:table-cell!important;
  background:transparent!important;
  border:0!important;
  border-radius:0!important;
  box-shadow:none!important;
  outline:0!important;
  padding:5px 8px!important;
  margin:0!important;
  text-align:center!important;
  vertical-align:middle!important;
  font-size:0!important;
  line-height:1!important;
  width:auto!important;
  min-width:0!important;
  max-width:none!important;
}
.rp-prof-panel table.rp-history-table td.rp-session-status::before,
.rp-prof-panel table.rp-history-table td.rp-session-status::after,
.rp-prof-panel table.rp-session-history-table td.rp-session-status::before,
.rp-prof-panel table.rp-session-history-table td.rp-session-status::after{
  content:none!important;
  display:none!important;
}
.rp-prof-panel table.rp-history-table td.rp-session-status > span.rp-session-status-chip,
.rp-prof-panel table.rp-session-history-table td.rp-session-status > span.rp-session-status-chip,
.rp-prof-panel .rp-history-table tbody td.rp-session-status > .rp-session-status-chip{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  height:18px!important;
  min-height:18px!important;
  max-height:18px!important;
  width:auto!important;
  min-width:0!important;
  max-width:max-content!important;
  padding:2px 7px!important;
  margin:0!important;
  border:0!important;
  border-radius:999px!important;
  box-shadow:none!important;
  outline:0!important;
  font-size:10.5px!important;
  font-weight:400!important;
  line-height:1!important;
  white-space:nowrap!important;
  opacity:1!important;
}
.rp-prof-panel table.rp-history-table td.rp-session-status > span.rp-status-confirmado,
.rp-prof-panel table.rp-session-history-table td.rp-session-status > span.rp-status-confirmado{background:#DCFCE7!important;color:#166534!important;}
.rp-prof-panel table.rp-history-table td.rp-session-status > span.rp-status-atendido,
.rp-prof-panel table.rp-session-history-table td.rp-session-status > span.rp-status-atendido{background:#DBEAFE!important;color:#1E40AF!important;}
.rp-prof-panel table.rp-history-table td.rp-session-status > span.rp-status-pendiente,
.rp-prof-panel table.rp-session-history-table td.rp-session-status > span.rp-status-pendiente{background:#FEF3C7!important;color:#92400E!important;}
.rp-prof-panel table.rp-history-table td.rp-session-status > span.rp-status-cancelado,
.rp-prof-panel table.rp-session-history-table td.rp-session-status > span.rp-status-cancelado{background:#E5E7EB!important;color:#374151!important;}
.rp-prof-panel table.rp-history-table td.rp-session-status > span.rp-status-reprogramado,
.rp-prof-panel table.rp-session-history-table td.rp-session-status > span.rp-status-reprogramado{background:#FFEDD5!important;color:#9A3412!important;}
.rp-prof-panel table.rp-history-table td.rp-session-status > span.rp-status-ausente,
.rp-prof-panel table.rp-session-history-table td.rp-session-status > span.rp-status-ausente{background:#FEE2E2!important;color:#991B1B!important;}


/* v284 - aislar vistas Historial de pagos e Historia clínica */
.rp-patient-detail-screen.rp-payments-open > *:not(.rp-payment-detail-screen){
    display:none !important;
}
.rp-patient-detail-screen.rp-payments-open > .rp-payment-detail-screen.active{
    display:block !important;
}


/* v288 - Historial de pagos en tabla y botones unificados */
.rp-prof-panel .rp-payments-quick-card{
  padding:18px!important;
}
.rp-prof-panel .rp-payments-quick-card h3{
  font-size:18px!important;
  font-weight:500!important;
  margin:0 0 14px!important;
  color:#1f2937!important;
}
.rp-prof-panel .rp-payment-summary-row{
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:16px!important;
  margin-bottom:16px!important;
}
.rp-prof-panel .rp-payments-quick-card .rp-debt-box{
  min-width:210px!important;
  padding:13px 16px!important;
  border-radius:12px!important;
}
.rp-prof-panel .rp-payments-quick-card .rp-open-payments-patient,
.rp-prof-panel .rp-payments-quick-card .rp-btn-payments-main,
.rp-prof-panel .rp-payment-detail-screen .rp-btn,
.rp-prof-panel .rp-debt-email-form .rp-btn{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  border-color:#102A56!important;
  color:#fff!important;
  font-weight:400!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:8px!important;
  min-height:38px!important;
  border-radius:10px!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-payments-quick-card .rp-btn svg,
.rp-prof-panel .rp-payment-detail-screen .rp-btn svg,
.rp-prof-panel .rp-mini-action svg{
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.35!important;
}
.rp-prof-panel .rp-payment-quick-table-head,
.rp-prof-panel .rp-payment-row{
  display:grid!important;
  grid-template-columns:minmax(210px,1.5fr) minmax(170px,1fr) minmax(150px,.75fr)!important;
  align-items:center!important;
  gap:14px!important;
}
.rp-prof-panel .rp-payment-quick-table-head{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  border-radius:10px 10px 0 0!important;
  padding:10px 14px!important;
  font-size:12px!important;
  font-weight:400!important;
  text-transform:uppercase!important;
  letter-spacing:.03em!important;
  margin-top:6px!important;
}
.rp-prof-panel .rp-payment-row{
  padding:12px 14px!important;
  border:1px solid #e5e7eb!important;
  border-top:0!important;
  background:#fff!important;
  min-height:54px!important;
  font-size:13px!important;
}
.rp-prof-panel .rp-payment-row:nth-of-type(even){background:#f8fafc!important;}
.rp-prof-panel .rp-payment-row span,
.rp-prof-panel .rp-payment-row em{
  font-size:13px!important;
  line-height:1.25!important;
  font-style:normal!important;
  color:#253142!important;
  font-weight:400!important;
}
.rp-prof-panel .rp-payment-row span small{
  display:block!important;
  margin-top:3px!important;
  font-size:12px!important;
  color:#526173!important;
  font-weight:400!important;
}
.rp-prof-panel .rp-payment-row .rp-inline-form{justify-self:end!important;margin:0!important;}
.rp-prof-panel .rp-mini-action,
.rp-prof-panel .rp-debt-actions-col .rp-mini-action{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:6px!important;
  min-height:30px!important;
  padding:6px 10px!important;
  border-radius:8px!important;
  border:1px solid #d7e0e8!important;
  background:#fff!important;
  color:#102A56!important;
  font-size:12px!important;
  line-height:1!important;
  font-weight:400!important;
  white-space:nowrap!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-mini-action-warning{
  color:#9a3412!important;
  background:#fff7ed!important;
  border-color:#fed7aa!important;
}
.rp-prof-panel .rp-payments-quick-card .rp-btn-payments-main{
  margin-top:14px!important;
  width:auto!important;
  padding:0 18px!important;
}
.rp-prof-panel .rp-debt-summary-table{
  border-collapse:separate!important;
  border-spacing:0!important;
  width:100%!important;
}
.rp-prof-panel .rp-debt-summary-table thead th{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  font-size:12px!important;
  font-weight:400!important;
  text-align:center!important;
  padding:10px!important;
}
.rp-prof-panel .rp-debt-summary-table tbody td{
  font-size:13px!important;
  font-weight:400!important;
  padding:10px!important;
  border-bottom:1px solid #eef2f6!important;
  vertical-align:middle!important;
}
.rp-prof-panel .rp-debt-actions-col{
  display:flex!important;
  gap:6px!important;
  align-items:center!important;
  justify-content:flex-end!important;
  flex-wrap:wrap!important;
}
@media(max-width:900px){
  .rp-prof-panel .rp-payment-quick-table-head{display:none!important;}
  .rp-prof-panel .rp-payment-row{grid-template-columns:1fr!important;gap:8px!important;border-top:1px solid #e5e7eb!important;border-radius:10px!important;margin-bottom:8px!important;}
  .rp-prof-panel .rp-payment-row .rp-inline-form{justify-self:start!important;}
}


/* v289 - historial de pagos y mora: tabla normal, iconos y tarjetas sin borde */
.rp-prof-panel .rp-title-with-icon{
  display:flex!important;
  align-items:center!important;
  gap:9px!important;
  font-weight:500!important;
  color:#1f2937!important;
}
.rp-prof-panel .rp-title-with-icon .rp-title-icon{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  color:#102A56!important;
  flex:0 0 auto!important;
}
.rp-prof-panel .rp-title-with-icon svg{
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.35!important;
}
.rp-prof-panel .rp-debt-box,
.rp-prof-panel .rp-payments-quick-card .rp-debt-box{
  border:0!important;
  box-shadow:none!important;
  background:#fff7e6!important;
  border-radius:12px!important;
}
.rp-prof-panel .rp-debt-total-pill,
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-total-pill{
  border:0!important;
  box-shadow:none!important;
  background:#fff7e6!important;
  border-radius:14px!important;
}
.rp-prof-panel .rp-payment-detail-screen .rp-btn,
.rp-prof-panel .rp-debt-email-form .rp-btn,
.rp-prof-panel .rp-previous-debt-form .rp-btn{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  border-color:#102A56!important;
  color:#fff!important;
  font-weight:400!important;
  gap:8px!important;
}
.rp-prof-panel .rp-payment-detail-screen .rp-btn svg,
.rp-prof-panel .rp-debt-email-form .rp-btn svg,
.rp-prof-panel .rp-previous-debt-form .rp-btn svg,
.rp-prof-panel .rp-debt-actions-col .rp-mini-action svg{
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.35!important;
}
/* Quita el compactado excesivo que se arrastró desde la tabla rápida */
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-responsive-table{
  overflow:auto!important;
  border:1px solid #e5e7eb!important;
  border-radius:14px!important;
  width:100%!important;
}
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-summary-table{
  width:100%!important;
  min-width:1080px!important;
  table-layout:auto!important;
  border-collapse:separate!important;
  border-spacing:0!important;
  margin:0!important;
  font-size:13px!important;
}
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-summary-table thead th{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  font-size:12px!important;
  font-weight:400!important;
  text-align:center!important;
  padding:11px 12px!important;
  letter-spacing:.03em!important;
  white-space:nowrap!important;
}
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-summary-table tbody td{
  font-size:13px!important;
  font-weight:400!important;
  color:#1f2937!important;
  padding:12px 12px!important;
  line-height:1.35!important;
  vertical-align:middle!important;
  border-bottom:1px solid #eef2f6!important;
  background:#fff!important;
}
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-summary-table tbody tr:nth-child(even) td{
  background:#f8fafc!important;
}
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-check-col{width:58px!important;text-align:center!important;min-width:58px!important;}
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-date-col{width:120px!important;min-width:120px!important;white-space:nowrap!important;}
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-time-col{width:100px!important;min-width:100px!important;white-space:nowrap!important;}
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-concept-col{width:190px!important;min-width:170px!important;}
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-amount-col{width:120px!important;min-width:115px!important;text-align:right!important;white-space:nowrap!important;font-weight:500!important;}
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-status-col{width:150px!important;min-width:145px!important;text-align:center!important;}
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-actions-col{
  width:320px!important;
  min-width:300px!important;
  display:flex!important;
  gap:6px!important;
  align-items:center!important;
  justify-content:flex-end!important;
  flex-wrap:wrap!important;
  white-space:normal!important;
}
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-actions-col form{margin:0!important;display:inline-flex!important;}
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-actions-col .rp-mini-action{
  min-height:30px!important;
  padding:6px 9px!important;
  font-size:12px!important;
  line-height:1!important;
  font-weight:400!important;
  border-radius:8px!important;
  white-space:nowrap!important;
}
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-status-pill{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  min-height:22px!important;
  padding:3px 9px!important;
  border-radius:999px!important;
  border:0!important;
  font-size:12px!important;
  font-weight:400!important;
  line-height:1!important;
}
.rp-prof-panel .rp-debt-tools-grid-clean{
  margin-top:18px!important;
  gap:18px!important;
}

/* v290 - Historia clínica: nuevo registro, campos amplios y botones lineales */
.rp-prof-panel .rp-clinical-history-card{
  --rp-clinical-blue:#102A56;
}
.rp-prof-panel .rp-clinical-history-title{
  display:flex!important;
  align-items:center!important;
  gap:10px!important;
  margin:0 0 14px!important;
  color:var(--rp-clinical-blue)!important;
  font-size:20px!important;
  font-weight:750!important;
  line-height:1.2!important;
}
.rp-prof-panel .rp-clinical-history-title .rp-title-icon{
  width:32px;
  height:32px;
  min-width:32px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border:1px solid rgba(16,42,86,.18);
  border-radius:10px;
  color:var(--rp-clinical-blue);
  background:#fff;
}
.rp-prof-panel .rp-clinical-history-title svg,
.rp-prof-panel .rp-clinical-history-actions svg{
  fill:none!important;
  stroke:currentColor!important;
}
.rp-prof-panel .rp-clinical-history-form{
  gap:14px!important;
}
.rp-prof-panel .rp-clinical-history-form label{
  font-weight:700!important;
}
.rp-prof-panel .rp-clinical-history-form input[type="date"]{
  min-height:48px!important;
  border-radius:12px!important;
}
.rp-prof-panel .rp-clinical-reason-field textarea{
  min-height:140px!important;
}
.rp-prof-panel .rp-clinical-evolution-field textarea{
  min-height:220px!important;
}
.rp-prof-panel .rp-clinical-private-field textarea{
  min-height:180px!important;
}
.rp-prof-panel .rp-clinical-history-actions{
  display:flex!important;
  align-items:center!important;
  gap:12px!important;
  flex-wrap:wrap!important;
  margin-top:4px!important;
}
.rp-prof-panel .rp-clinical-history-actions .rp-btn{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:8px!important;
  min-height:44px!important;
  padding:11px 16px!important;
  border-radius:12px!important;
  font-weight:750!important;
  text-decoration:none!important;
}
.rp-prof-panel .rp-clinical-save-btn{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  border:1px solid #102A56!important;
  color:#fff!important;
}
.rp-prof-panel .rp-clinical-view-btn{
  background:#fff!important;
  border:1px solid #102A56!important;
  color:#102A56!important;
}
.rp-prof-panel .rp-clinical-view-btn:hover{
  background:#f8fafc!important;
  color:#102A56!important;
}
@media(max-width:640px){
  .rp-prof-panel .rp-clinical-history-actions{align-items:stretch!important;}
  .rp-prof-panel .rp-clinical-history-actions .rp-btn{width:100%!important;}
}

/* v291 - Historia clínica: el alta nueva vive en la pestaña Historia clínica y ocupa todo el ancho */
.rp-prof-panel .rp-history-detail-screen .rp-clinical-history-card-wide{
  width:100%!important;
  max-width:none!important;
  margin:18px 0!important;
  box-sizing:border-box!important;
}
.rp-prof-panel .rp-history-detail-screen .rp-clinical-history-form{
  display:grid!important;
  grid-template-columns:1fr!important;
  width:100%!important;
}
.rp-prof-panel .rp-history-detail-screen .rp-clinical-history-form label,
.rp-prof-panel .rp-history-detail-screen .rp-clinical-history-form .rp-clinical-history-actions{
  grid-column:1 / -1!important;
  width:100%!important;
}
.rp-prof-panel .rp-history-detail-screen .rp-clinical-history-form textarea,
.rp-prof-panel .rp-history-detail-screen .rp-clinical-history-form input[type="date"]{
  width:100%!important;
  box-sizing:border-box!important;
}
.rp-prof-panel .rp-history-detail-screen .rp-history-search-card{
  width:100%!important;
  max-width:none!important;
}
@media(min-width:641px){
  .rp-prof-panel .rp-history-detail-screen .rp-clinical-history-actions .rp-btn{
    width:auto!important;
    min-width:210px!important;
  }
}

/* v292 - Historia clínica dentro del botón/pestaña del paciente */
.rp-prof-panel .rp-clinical-history-card .rp-subpage-marker{
  position:absolute!important;
  width:1px!important;
  height:1px!important;
  overflow:hidden!important;
  clip:rect(0 0 0 0)!important;
  white-space:nowrap!important;
  margin:-1px!important;
  padding:0!important;
  border:0!important;
}
.rp-prof-panel .rp-patient-subpage-mode .rp-subpage-columns-holder{
  max-width:none!important;
  width:100%!important;
  margin:18px 0 0!important;
}
.rp-prof-panel .rp-patient-subpage-mode .rp-clinical-history-card-wide{
  width:100%!important;
  max-width:100%!important;
  box-sizing:border-box!important;
}
.rp-prof-panel .rp-clinical-patient-history-list{
  margin-top:24px!important;
  padding-top:18px!important;
  border-top:1px solid #e5e7eb!important;
}
.rp-prof-panel .rp-clinical-patient-history-list > h3{
  font-size:20px!important;
  margin:0 0 14px!important;
  color:#102A56!important;
}

/* v293 - Historia clínica: historial completo en tabla con detalle desplegable */
.rp-prof-panel .rp-clinical-list-title{
  display:flex!important;
  align-items:center!important;
  gap:10px!important;
  font-size:20px!important;
  font-weight:800!important;
  margin:0 0 14px!important;
  color:#102A56!important;
}
.rp-prof-panel .rp-clinical-list-title .rp-title-icon{
  width:34px!important;
  height:34px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  border:1px solid rgba(16,42,86,.2)!important;
  border-radius:10px!important;
  color:#102A56!important;
}
.rp-prof-panel .rp-clinical-history-table-wrap{width:100%!important;overflow:auto!important;}
.rp-prof-panel .rp-clinical-history-table{width:100%!important;border-collapse:separate!important;border-spacing:0!important;}
.rp-prof-panel .rp-clinical-history-table th,
.rp-prof-panel .rp-clinical-history-table td{padding:13px 14px!important;vertical-align:middle!important;}
.rp-prof-panel .rp-clinical-history-table thead th{font-weight:800!important;color:#102A56!important;background:#f8fafc!important;border-bottom:1px solid #e5e7eb!important;}
.rp-prof-panel .rp-clinical-history-row td{border-bottom:1px solid #edf1f5!important;}
.rp-prof-panel .rp-clinical-detail-toggle{display:inline-flex!important;align-items:center!important;gap:7px!important;color:#102A56!important;border:1px solid rgba(16,42,86,.22)!important;background:#fff!important;border-radius:10px!important;padding:8px 11px!important;font-weight:800!important;}
.rp-prof-panel .rp-clinical-detail-row td{padding:0 14px 16px!important;background:#fbfdff!important;border-bottom:1px solid #e5e7eb!important;}
.rp-prof-panel .rp-clinical-detail-box{border:1px solid #e5e7eb!important;border-radius:16px!important;background:#fff!important;padding:16px!important;margin-top:4px!important;box-shadow:0 8px 22px rgba(15,23,42,.04)!important;}
.rp-prof-panel .rp-clinical-detail-head{display:flex!important;gap:10px!important;align-items:center!important;justify-content:space-between!important;margin-bottom:12px!important;color:#102A56!important;}
.rp-prof-panel .rp-clinical-detail-grid{display:grid!important;grid-template-columns:1fr!important;gap:14px!important;}
.rp-prof-panel .rp-clinical-detail-grid h4{margin:0 0 6px!important;font-size:14px!important;color:#102A56!important;font-weight:800!important;}
.rp-prof-panel .rp-clinical-detail-grid p{margin:0!important;line-height:1.55!important;color:#334155!important;white-space:normal!important;}

.rp-title-svg{display:inline-flex;vertical-align:middle;margin-right:8px}.rp-prof-head h1{display:flex;align-items:center;gap:8px}
/* v296 - Historias Clínicas: detalle ordenado en tabla */
.rp-history-detail-topbar{
  align-items:center;
  gap:14px;
}
.rp-topbar-title{
  display:inline-flex;
  align-items:center;
  gap:8px;
  color:#102A56;
  font-weight:700;
}
.rp-topbar-title svg,
.rp-title-with-icon svg,
.rp-history-action-buttons svg,
.rp-history-row-actions svg{
  fill:none;
  stroke:currentColor;
}
.rp-history-action-buttons,
.rp-history-row-actions{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
}
.rp-history-polished-card{
  width:100%;
  padding:26px;
}
.rp-history-polished-card .rp-title-with-icon{
  display:flex;
  align-items:center;
  gap:10px;
  color:#102A56;
  margin:0 0 6px;
}
.rp-history-filters-polished{
  display:grid;
  grid-template-columns:minmax(260px,1fr) minmax(160px,220px) minmax(160px,220px);
  gap:14px;
  align-items:end;
  margin:18px 0 20px;
}
.rp-history-filters-polished .rp-history-filter-field{
  display:flex;
  flex-direction:column;
  gap:8px;
  font-weight:700;
  color:#283347;
}
.rp-history-filters-polished input{
  width:100%;
  min-height:48px;
  border:1px solid rgba(16,42,86,.14);
  border-radius:14px;
  padding:0 14px;
  background:#fff;
}
.rp-history-table-wrap{
  width:100%;
  overflow-x:auto;
}
.rp-history-records-table{
  width:100%;
  border-collapse:separate;
  border-spacing:0;
}
.rp-history-records-table thead th{
  text-align:left;
  color:#102A56;
  font-weight:800;
  border-bottom:1px solid rgba(16,42,86,.14);
  padding:13px 14px;
  background:rgba(16,42,86,.035);
}
.rp-history-records-table tbody td{
  padding:14px;
  vertical-align:top;
  border-bottom:1px solid rgba(16,42,86,.10);
}
.rp-history-records-table tbody tr:hover td{
  background:rgba(16,42,86,.025);
}
.rp-history-row-actions .rp-btn,
.rp-history-detail-toggle summary,
.rp-history-edit-toggle summary{
  min-height:38px;
  border-radius:12px;
  display:inline-flex;
  align-items:center;
  gap:8px;
  cursor:pointer;
  list-style:none;
}
.rp-history-detail-toggle summary::-webkit-details-marker,
.rp-history-edit-toggle summary::-webkit-details-marker{display:none;}
.rp-history-detail-toggle[open],
.rp-history-edit-toggle[open]{
  flex-basis:100%;
}
.rp-history-detail-panel,
.rp-history-edit-form{
  margin-top:12px;
  padding:16px;
  border:1px solid rgba(16,42,86,.12);
  border-radius:16px;
  background:#fff;
  box-shadow:0 10px 24px rgba(16,42,86,.06);
  min-width:min(760px, calc(100vw - 80px));
}
.rp-history-detail-grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:14px;
}
.rp-history-detail-grid h4{
  margin:0 0 8px;
  color:#102A56;
  font-size:14px;
}
.rp-history-detail-grid p{
  margin:0;
  color:#283347;
  line-height:1.5;
  white-space:normal;
}
.rp-history-edit-form{
  grid-template-columns:180px 1fr 1fr 1fr auto;
  align-items:end;
}
.rp-history-edit-form label{
  display:flex;
  flex-direction:column;
  gap:7px;
  font-weight:700;
}
.rp-history-edit-form textarea{
  min-height:92px;
}
.rp-history-edit-form .rp-btn{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%);
  color:#fff;
}
.rp-history-patient-hero{
  margin-bottom:18px;
}
@media (max-width:900px){
  .rp-history-filters-polished,
  .rp-history-detail-grid,
  .rp-history-edit-form{grid-template-columns:1fr;}
  .rp-history-detail-panel,
  .rp-history-edit-form{min-width:100%;}
}

/* v297 - Historias Clínicas: tabla más compacta y edición en popup */
.rp-prof-panel .rp-clinical-list-title,
.rp-prof-panel .rp-title-with-icon{
  font-size:20px!important;
  line-height:1.25!important;
}
.rp-prof-panel .rp-clinical-history-table thead th,
.rp-prof-panel .rp-history-records-table thead th{
  font-size:12px!important;
  letter-spacing:.035em!important;
  text-transform:uppercase!important;
  padding:10px 12px!important;
}
.rp-prof-panel .rp-clinical-history-table tbody td,
.rp-prof-panel .rp-history-records-table tbody td{
  font-size:13px!important;
  padding:10px 12px!important;
  line-height:1.35!important;
}
.rp-prof-panel .rp-clinical-row-actions,
.rp-prof-panel .rp-history-row-actions{
  display:flex!important;
  align-items:center!important;
  gap:7px!important;
  flex-wrap:wrap!important;
}
.rp-prof-panel .rp-clinical-row-actions .rp-mini-action,
.rp-prof-panel .rp-history-row-actions .rp-btn,
.rp-prof-panel .rp-history-edit-open{
  min-height:32px!important;
  padding:7px 9px!important;
  font-size:12px!important;
  border-radius:10px!important;
  white-space:nowrap!important;
}
.rp-prof-panel .rp-history-edit-modal[hidden]{display:none!important;}
.rp-history-edit-modal{
  position:fixed!important;
  inset:0!important;
  z-index:999999!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  padding:22px!important;
  overflow-y:auto!important;
  box-sizing:border-box!important;
}
.rp-prof-panel .rp-history-edit-modal{
  position:fixed!important;
  inset:0!important;
  z-index:999999!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  padding:22px!important;
  overflow-y:auto!important;
  box-sizing:border-box!important;
}
.rp-history-edit-backdrop,
.rp-prof-panel .rp-history-edit-backdrop{
  position:absolute!important;
  inset:0!important;
  background:rgba(15,23,42,.46)!important;
  backdrop-filter:blur(3px)!important;
}
.rp-history-edit-dialog,
.rp-prof-panel .rp-history-edit-dialog{
  position:relative!important;
  width:min(920px,96vw)!important;
  max-height:calc(100vh - 56px)!important;
  overflow-y:auto!important;
  overflow-x:hidden!important;
  background:#fff!important;
  border:1px solid rgba(16,42,86,.14)!important;
  border-radius:22px!important;
  box-shadow:0 28px 80px rgba(15,23,42,.28)!important;
  padding:22px!important;
}
.rp-history-edit-dialog h3,
.rp-prof-panel .rp-history-edit-dialog h3{
  margin:0 44px 18px 0!important;
  display:flex!important;
  align-items:center!important;
  gap:10px!important;
  color:#102A56!important;
  font-size:20px!important;
  line-height:1.25!important;
}
.rp-history-edit-close,
.rp-prof-panel .rp-history-edit-close{
  position:absolute!important;
  top:14px!important;
  right:14px!important;
  width:34px!important;
  height:34px!important;
  border-radius:12px!important;
  border:1px solid rgba(16,42,86,.18)!important;
  background:#fff!important;
  color:#102A56!important;
  font-size:22px!important;
  line-height:1!important;
  cursor:pointer!important;
}
.rp-history-edit-form-modal,
.rp-prof-panel .rp-history-edit-form-modal{
  display:grid!important;
  grid-template-columns:180px 1fr!important;
  gap:14px!important;
  min-width:0!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  box-shadow:none!important;
}
.rp-history-edit-form-modal label,
.rp-prof-panel .rp-history-edit-form-modal label{
  display:flex!important;
  flex-direction:column!important;
  gap:7px!important;
  font-size:13px!important;
  font-weight:800!important;
  color:#283347!important;
}
.rp-history-edit-form-modal label:nth-of-type(n+2),
.rp-prof-panel .rp-history-edit-form-modal label:nth-of-type(n+2){grid-column:1 / -1!important;}
.rp-history-edit-form-modal textarea,
.rp-prof-panel .rp-history-edit-form-modal textarea{min-height:130px!important;resize:vertical!important;}
.rp-history-edit-modal-actions,
.rp-prof-panel .rp-history-edit-modal-actions{
  grid-column:1 / -1!important;
  display:flex!important;
  align-items:center!important;
  gap:10px!important;
  justify-content:flex-end!important;
  margin-top:4px!important;
}
.rp-history-edit-form-modal .rp-btn:not(.rp-btn-light),
.rp-prof-panel .rp-history-edit-form-modal .rp-btn:not(.rp-btn-light){background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;color:#fff!important;}
html.rp-history-popup-open{overflow:auto!important;}
@media (max-width:760px){
  .rp-history-edit-form-modal,
.rp-prof-panel .rp-history-edit-form-modal{grid-template-columns:1fr!important;}
  .rp-history-edit-dialog,
.rp-prof-panel .rp-history-edit-dialog{padding:18px!important;}
}

/* v299 - Historias Clínicas: popup cierre, campos visibles y columnas proporcionadas */
.rp-history-edit-form-modal input,
.rp-history-edit-form-modal textarea,
.rp-prof-panel .rp-history-edit-form-modal input,
.rp-prof-panel .rp-history-edit-form-modal textarea{
  width:100%!important;
  box-sizing:border-box!important;
  border:1px solid rgba(16,42,86,.22)!important;
  background:#fff!important;
  border-radius:14px!important;
  color:#1f2937!important;
  box-shadow:inset 0 1px 0 rgba(16,42,86,.03)!important;
  outline:none!important;
}
.rp-history-edit-form-modal input,
.rp-prof-panel .rp-history-edit-form-modal input{
  min-height:46px!important;
  padding:0 14px!important;
}
.rp-history-edit-form-modal textarea,
.rp-prof-panel .rp-history-edit-form-modal textarea{
  min-height:120px!important;
  padding:12px 14px!important;
}
.rp-history-edit-form-modal input:focus,
.rp-history-edit-form-modal textarea:focus,
.rp-prof-panel .rp-history-edit-form-modal input:focus,
.rp-prof-panel .rp-history-edit-form-modal textarea:focus{
  border-color:#102A56!important;
  box-shadow:0 0 0 3px rgba(16,42,86,.10)!important;
}
.rp-history-edit-modal[hidden],
.rp-prof-panel .rp-history-edit-modal[hidden]{display:none!important;visibility:hidden!important;opacity:0!important;pointer-events:none!important;}
.rp-history-edit-modal:not([hidden]){display:flex!important;visibility:visible!important;opacity:1!important;pointer-events:auto!important;}
.rp-history-edit-backdrop{cursor:pointer!important;}

/* tabla dentro de la ficha del paciente */
.rp-prof-panel .rp-clinical-history-table{table-layout:fixed!important;}
.rp-prof-panel .rp-clinical-history-table th:nth-child(1),
.rp-prof-panel .rp-clinical-history-table td:nth-child(1){width:118px!important;max-width:118px!important;}
.rp-prof-panel .rp-clinical-history-table th:nth-child(2),
.rp-prof-panel .rp-clinical-history-table td:nth-child(2){width:88px!important;max-width:88px!important;}
.rp-prof-panel .rp-clinical-history-table th:nth-child(3),
.rp-prof-panel .rp-clinical-history-table td:nth-child(3){width:auto!important;}
.rp-prof-panel .rp-clinical-history-table th:nth-child(4),
.rp-prof-panel .rp-clinical-history-table td:nth-child(4){width:310px!important;max-width:310px!important;}
.rp-prof-panel .rp-clinical-row-actions{
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:6px!important;
  flex-wrap:nowrap!important;
  white-space:nowrap!important;
}

/* tabla de Historias Clínicas del paciente en el módulo lateral */
.rp-prof-panel .rp-history-records-table{table-layout:fixed!important;}
.rp-prof-panel .rp-history-records-table th:nth-child(1),
.rp-prof-panel .rp-history-records-table td:nth-child(1){width:118px!important;max-width:118px!important;}
.rp-prof-panel .rp-history-records-table th:nth-child(2),
.rp-prof-panel .rp-history-records-table td:nth-child(2){width:88px!important;max-width:88px!important;}
.rp-prof-panel .rp-history-records-table th:nth-child(3),
.rp-prof-panel .rp-history-records-table td:nth-child(3){width:auto!important;}
.rp-prof-panel .rp-history-records-table th:nth-child(4),
.rp-prof-panel .rp-history-records-table td:nth-child(4){width:315px!important;max-width:315px!important;}
.rp-prof-panel .rp-history-row-actions{
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:6px!important;
  flex-wrap:nowrap!important;
  white-space:nowrap!important;
}
.rp-prof-panel .rp-history-row-actions details{display:inline-flex!important;}
.rp-prof-panel .rp-history-row-actions .rp-history-detail-panel{white-space:normal!important;}
@media (max-width:900px){
  .rp-prof-panel .rp-clinical-history-table th:nth-child(4),
  .rp-prof-panel .rp-clinical-history-table td:nth-child(4),
  .rp-prof-panel .rp-history-records-table th:nth-child(4),
  .rp-prof-panel .rp-history-records-table td:nth-child(4){width:260px!important;max-width:260px!important;}
  .rp-prof-panel .rp-clinical-row-actions,
  .rp-prof-panel .rp-history-row-actions{flex-wrap:wrap!important;}
}

/* v300 - Historias Clínicas del paciente: desplegable y filtros */
.rp-prof-panel .rp-clinical-dropdown{
  margin-top:22px!important;
  border:1px solid #e5e7eb!important;
  border-radius:18px!important;
  padding:16px!important;
  background:#fff!important;
}
.rp-prof-panel .rp-clinical-list-head{
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:14px!important;
  width:100%!important;
}
.rp-prof-panel .rp-clinical-dropdown-toggle{
  min-width:190px!important;
  justify-content:center!important;
  color:#102A56!important;
  background:#fff!important;
  border:1px solid rgba(16,42,86,.22)!important;
}
.rp-prof-panel .rp-clinical-dropdown-toggle.is-open svg{
  transform:rotate(180deg)!important;
}
.rp-prof-panel .rp-clinical-dropdown-body{
  margin-top:16px!important;
}
.rp-prof-panel .rp-clinical-table-filters{
  display:grid!important;
  grid-template-columns:minmax(260px,1fr) 170px 170px auto!important;
  gap:12px!important;
  align-items:end!important;
  margin:0 0 14px!important;
}
.rp-prof-panel .rp-clinical-table-filters label{
  display:flex!important;
  flex-direction:column!important;
  gap:7px!important;
  font-size:12px!important;
  font-weight:800!important;
  color:#334155!important;
}
.rp-prof-panel .rp-clinical-table-filters input[type="search"],
.rp-prof-panel .rp-clinical-table-filters input[type="date"]{
  width:100%!important;
  min-height:42px!important;
  border:1px solid #d8dee8!important;
  border-radius:12px!important;
  background:#fff!important;
  padding:10px 12px!important;
  color:#111827!important;
  box-shadow:0 1px 0 rgba(15,23,42,.02)!important;
}
.rp-prof-panel .rp-clinical-table-filters input:focus{
  outline:none!important;
  border-color:#102A56!important;
  box-shadow:0 0 0 3px rgba(16,42,86,.10)!important;
}
.rp-prof-panel .rp-clinical-no-results td{
  padding:18px!important;
  text-align:center!important;
  color:#64748b!important;
  font-weight:700!important;
}
@media(max-width:900px){
  .rp-prof-panel .rp-clinical-list-head{align-items:flex-start!important;flex-direction:column!important;}
  .rp-prof-panel .rp-clinical-dropdown-toggle{width:100%!important;}
  .rp-prof-panel .rp-clinical-table-filters{grid-template-columns:1fr!important;}
}

/* v301 - Historias Clínicas: encabezados azules y botones lineales */
.rp-prof-panel .rp-clinical-history-table,
.rp-prof-panel .rp-history-records-table{
  table-layout:fixed!important;
  width:100%!important;
}
.rp-prof-panel .rp-clinical-history-table thead th,
.rp-prof-panel .rp-history-records-table thead th{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  text-align:center!important;
  font-weight:400!important;
  font-size:12px!important;
  letter-spacing:.03em!important;
  text-transform:uppercase!important;
  padding:11px 12px!important;
  border-color:#102A56!important;
}
.rp-prof-panel .rp-clinical-history-table thead th:first-child,
.rp-prof-panel .rp-history-records-table thead th:first-child{
  border-top-left-radius:10px!important;
}
.rp-prof-panel .rp-clinical-history-table thead th:last-child,
.rp-prof-panel .rp-history-records-table thead th:last-child{
  border-top-right-radius:10px!important;
}
.rp-prof-panel .rp-clinical-history-table tbody td,
.rp-prof-panel .rp-history-records-table tbody td{
  font-size:13px!important;
  font-weight:400!important;
  vertical-align:middle!important;
  padding:11px 12px!important;
}
.rp-prof-panel .rp-clinical-history-table tbody td:nth-child(1),
.rp-prof-panel .rp-clinical-history-table tbody td:nth-child(2),
.rp-prof-panel .rp-history-records-table tbody td:nth-child(1),
.rp-prof-panel .rp-history-records-table tbody td:nth-child(2){
  text-align:center!important;
  white-space:nowrap!important;
}
/* Tabla dentro de la ficha del paciente */
.rp-prof-panel .rp-clinical-history-table th:nth-child(1),
.rp-prof-panel .rp-clinical-history-table td:nth-child(1){width:120px!important;max-width:120px!important;}
.rp-prof-panel .rp-clinical-history-table th:nth-child(2),
.rp-prof-panel .rp-clinical-history-table td:nth-child(2){width:82px!important;max-width:82px!important;}
.rp-prof-panel .rp-clinical-history-table th:nth-child(3),
.rp-prof-panel .rp-clinical-history-table td:nth-child(3){width:auto!important;}
.rp-prof-panel .rp-clinical-history-table th:nth-child(4),
.rp-prof-panel .rp-clinical-history-table td:nth-child(4){width:300px!important;max-width:300px!important;}
/* Tabla del módulo lateral Historias Clínicas */
.rp-prof-panel .rp-history-records-table th:nth-child(1),
.rp-prof-panel .rp-history-records-table td:nth-child(1){width:120px!important;max-width:120px!important;}
.rp-prof-panel .rp-history-records-table th:nth-child(2),
.rp-prof-panel .rp-history-records-table td:nth-child(2){width:82px!important;max-width:82px!important;}
.rp-prof-panel .rp-history-records-table th:nth-child(3),
.rp-prof-panel .rp-history-records-table td:nth-child(3){width:auto!important;}
.rp-prof-panel .rp-history-records-table th:nth-child(4),
.rp-prof-panel .rp-history-records-table td:nth-child(4){width:320px!important;max-width:320px!important;}
.rp-prof-panel .rp-clinical-row-actions,
.rp-prof-panel .rp-history-row-actions{
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:6px!important;
  flex-wrap:nowrap!important;
  white-space:nowrap!important;
}
.rp-prof-panel .rp-clinical-row-actions .rp-mini-action,
.rp-prof-panel .rp-history-row-actions .rp-mini-action,
.rp-prof-panel .rp-history-row-actions .rp-btn,
.rp-prof-panel .rp-history-row-actions summary.rp-btn{
  background:#fff!important;
  color:#102A56!important;
  border:1px solid rgba(16,42,86,.22)!important;
  box-shadow:none!important;
  font-size:11.5px!important;
  font-weight:500!important;
  min-height:32px!important;
  height:32px!important;
  padding:6px 8px!important;
  line-height:1!important;
}
.rp-prof-panel .rp-clinical-row-actions .rp-mini-action svg,
.rp-prof-panel .rp-history-row-actions .rp-mini-action svg,
.rp-prof-panel .rp-history-row-actions .rp-btn svg,
.rp-prof-panel .rp-history-row-actions summary.rp-btn svg{
  stroke:#102A56!important;
  width:13px!important;
  height:13px!important;
  flex:0 0 13px!important;
}
.rp-prof-panel .rp-clinical-row-actions .rp-mini-action:hover,
.rp-prof-panel .rp-history-row-actions .rp-mini-action:hover,
.rp-prof-panel .rp-history-row-actions .rp-btn:hover,
.rp-prof-panel .rp-history-row-actions summary.rp-btn:hover{
  background:#f8fafc!important;
  border-color:#102A56!important;
}
@media(max-width:900px){
  .rp-prof-panel .rp-clinical-history-table th:nth-child(4),
  .rp-prof-panel .rp-clinical-history-table td:nth-child(4),
  .rp-prof-panel .rp-history-records-table th:nth-child(4),
  .rp-prof-panel .rp-history-records-table td:nth-child(4){width:250px!important;max-width:250px!important;}
  .rp-prof-panel .rp-clinical-row-actions,
  .rp-prof-panel .rp-history-row-actions{flex-wrap:wrap!important;justify-content:flex-start!important;}
}

/* v303 - ficha paciente: próxima/última sesión diferenciadas de los acordeones */
.rp-patient-detail-screen .rp-next-banner{display:none!important;}
.rp-patient-detail-screen .rp-turnos-resumen{
  display:grid!important;
  grid-template-columns:repeat(2,minmax(0,1fr))!important;
  gap:14px!important;
  margin:0 0 16px!important;
}
.rp-patient-detail-screen .rp-turno-resumen-card{
  position:relative!important;
  background:#fff!important;
  color:#102A56!important;
  border:1px solid #D8E3F0!important;
  border-radius:16px!important;
  padding:14px 42px 14px 16px!important;
  display:grid!important;
  grid-template-columns:minmax(0,1fr) auto!important;
  align-items:center!important;
  gap:6px 14px!important;
  min-height:66px!important;
  box-shadow:none!important;
}
.rp-patient-detail-screen .rp-turno-resumen-card::after{
  content:'⌄'!important;
  position:absolute!important;
  right:16px!important;
  top:50%!important;
  transform:translateY(-50%)!important;
  color:#102A56!important;
  font-size:18px!important;
  line-height:1!important;
  font-weight:400!important;
}
.rp-patient-detail-screen .rp-turno-resumen-card strong,
.rp-patient-detail-screen .rp-turno-resumen-card span,
.rp-patient-detail-screen .rp-turno-resumen-card em{
  color:#102A56!important;
  font-weight:400!important;
}
.rp-patient-detail-screen .rp-turno-resumen-card strong{
  grid-column:1/-1!important;
  font-weight:400!important;
  display:inline-flex!important;
  align-items:center!important;
  gap:8px!important;
  white-space:nowrap!important;
  font-size:14px!important;
}
.rp-patient-detail-screen .rp-turno-resumen-card span{
  display:block!important;
  font-size:13px!important;
  line-height:1.35!important;
}
.rp-patient-detail-screen .rp-turno-resumen-card em{
  justify-self:end!important;
  font-style:normal!important;
  white-space:nowrap!important;
  background:#EEF6FF!important;
  border:1px solid #D8E3F0!important;
  border-radius:999px!important;
  padding:4px 9px!important;
  font-size:12px!important;
}
.rp-patient-detail-screen .rp-turno-resumen-card svg{fill:none!important;stroke:#102A56!important;stroke-width:1.45!important;}
.rp-patient-subpage-mode .rp-turnos-resumen,
.rp-patient-detail-screen.rp-payments-open > .rp-turnos-resumen{display:none!important;}
@media(max-width:900px){.rp-patient-detail-screen .rp-turnos-resumen{grid-template-columns:1fr!important}.rp-patient-detail-screen .rp-turno-resumen-card em{justify-self:start!important}}

/* v304: Turnera paciente y Configurar facturación dentro de Configuración */
.rp-config-accordion-wrap{
  display:flex;
  flex-direction:column;
  gap:14px;
  margin:18px 0 22px;
}
.rp-config-accordion{
  border:0!important;
  border-radius:18px;
  overflow:hidden;
  background:#ffffff;
  box-shadow:0 14px 35px rgba(15,23,42,.08);
}
.rp-config-accordion > summary{
  list-style:none;
  cursor:pointer;
  display:flex;
  align-items:center;
  gap:12px;
  width:100%;
  min-height:58px;
  padding:15px 18px;
  background:#0f5fbb;
  color:#ffffff;
  font-size:15px;
  font-weight:400;
  line-height:1.2;
  border:1px solid rgba(255,255,255,.22);
  border-radius:18px;
  box-sizing:border-box;
}
.rp-config-accordion > summary::-webkit-details-marker{display:none;}
.rp-config-accordion-icon{
  width:28px;
  height:28px;
  flex:0 0 28px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  color:#ffffff;
}
.rp-config-accordion-icon svg{
  width:24px;
  height:24px;
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.7!important;
}
.rp-config-accordion-caret{
  margin-left:auto;
  color:#ffffff;
  font-size:22px;
  line-height:1;
  font-weight:300;
  transition:transform .18s ease;
}
.rp-config-accordion[open] > summary{
  border-bottom-left-radius:0;
  border-bottom-right-radius:0;
}
.rp-config-accordion[open] .rp-config-accordion-caret{transform:rotate(180deg);}
.rp-config-accordion-body{
  padding:18px;
  background:#ffffff;
  border:1px solid #dbe7f3;
  border-top:0;
  border-bottom-left-radius:18px;
  border-bottom-right-radius:18px;
}
.rp-config-embedded-section{
  display:block!important;
  margin:0!important;
}
.rp-config-embedded-section .rp-prof-head,
.rp-config-embedded-section .rp-section-header{
  margin-top:0!important;
}
@media (max-width:760px){
  .rp-config-accordion > summary{padding:14px 15px;min-height:54px;}
  .rp-config-accordion-body{padding:14px;}
}

/* v305: Configuración completa en acordeones azules separados */
#configuracion .rp-config-accordion-wrap{
  gap:12px!important;
  margin:14px 0!important;
}
#configuracion .rp-config-accordion{
  border:0!important;
  border-radius:15px!important;
  background:#fff!important;
  box-shadow:none!important;
  overflow:hidden!important;
}
#configuracion .rp-config-accordion > summary{
  min-height:46px!important;
  padding:11px 16px!important;
  border-radius:15px!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  border:1px solid rgba(255,255,255,.18)!important;
  font-size:15px!important;
  font-weight:400!important;
}
#configuracion .rp-config-accordion[open] > summary{
  border-bottom-left-radius:0!important;
  border-bottom-right-radius:0!important;
}
#configuracion .rp-config-accordion-icon,
#configuracion .rp-config-accordion-caret{color:#fff!important;}
#configuracion .rp-config-accordion-icon svg{
  width:22px!important;
  height:22px!important;
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.7!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
}
#configuracion .rp-config-accordion-body{
  padding:14px!important;
  border:1px solid #dbe7f3!important;
  border-top:0!important;
  border-bottom-left-radius:15px!important;
  border-bottom-right-radius:15px!important;
  background:#fff!important;
}
#configuracion .rp-config-grid-single{
  display:grid!important;
  grid-template-columns:repeat(2,minmax(0,1fr))!important;
  gap:14px!important;
}
#configuracion .rp-config-grid-single .rp-card{
  margin:0!important;
}
#configuracion .rp-config-form-single{
  margin:0!important;
}
#configuracion .rp-config-save-row{
  margin-top:14px!important;
  display:flex!important;
  justify-content:flex-end!important;
}
#configuracion .rp-config-save-row .rp-btn{
  min-height:40px!important;
}
#configuracion .rp-config-embedded-section .rp-prof-head,
#configuracion .rp-config-embedded-section .rp-section-header,
#configuracion .rp-config-embedded-section > .rp-prof-head,
#configuracion .rp-config-embedded-section > .rp-section-header{
  display:none!important;
}
@media(max-width:760px){
  #configuracion .rp-config-grid-single{grid-template-columns:1fr!important;}
  #configuracion .rp-config-accordion > summary{min-height:44px!important;padding:10px 14px!important;}
}

/* v306: todos los bloques de Configuración como acordeones iguales; botones de guardado no se confunden con encabezados */
#configuracion .rp-config-accordion-wrap{
  display:flex!important;
  flex-direction:column!important;
  gap:10px!important;
  margin:14px 0 18px!important;
}
#configuracion .rp-config-modules-wrap{display:contents!important;}
#configuracion .rp-config-accordion{
  width:100%!important;
  border-radius:13px!important;
  background:transparent!important;
  box-shadow:none!important;
  overflow:visible!important;
  margin:0!important;
}
#configuracion .rp-config-accordion > summary{
  min-height:44px!important;
  padding:10px 16px!important;
  border-radius:13px!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  border:1px solid #102A56!important;
  box-shadow:none!important;
  font-size:15px!important;
  font-weight:400!important;
}
#configuracion .rp-config-accordion[open] > summary{
  border-bottom-left-radius:0!important;
  border-bottom-right-radius:0!important;
}
#configuracion .rp-config-accordion-body{
  padding:14px!important;
  border:1px solid #dbe7f3!important;
  border-top:0!important;
  border-radius:0 0 13px 13px!important;
  background:#fff!important;
  box-shadow:none!important;
}
#configuracion .rp-config-accordion-body .rp-card,
#configuracion .rp-config-accordion-body .rp-config-card{
  box-shadow:none!important;
  border:1px solid #e2e8f0!important;
  border-radius:12px!important;
  background:#fff!important;
  margin:0!important;
}
#configuracion .rp-config-accordion-body .rp-card h1,
#configuracion .rp-config-accordion-body .rp-card h2,
#configuracion .rp-config-accordion-body .rp-card h3,
#configuracion .rp-config-accordion-body .rp-prof-head,
#configuracion .rp-config-accordion-body .rp-section-header{
  display:none!important;
}
#configuracion .rp-config-save-row{
  margin-top:12px!important;
  justify-content:flex-end!important;
}
#configuracion .rp-config-save-row .rp-config-save-btn,
#configuracion .rp-config-save-row .rp-btn{
  width:auto!important;
  min-height:36px!important;
  padding:8px 14px!important;
  border-radius:10px!important;
  background:#fff!important;
  color:#102A56!important;
  border:1px solid #102A56!important;
  box-shadow:none!important;
  font-size:14px!important;
  font-weight:500!important;
}
#configuracion .rp-config-save-row .rp-config-save-btn:hover,
#configuracion .rp-config-save-row .rp-btn:hover{
  background:#f8fafc!important;
  color:#102A56!important;
}
#configuracion .rp-config-accordion-body > form,
#configuracion .rp-config-form-single{margin:0!important;}
@media(max-width:760px){
  #configuracion .rp-config-accordion > summary{min-height:42px!important;padding:9px 13px!important;}
  #configuracion .rp-config-accordion-body{padding:12px!important;}
}

/* v307: asegurar que todos los acordeones de configuración queden dentro del mismo contenedor visual */
.rp-config-accordion,
.rp-config-accordion-module{
  width:100%!important;
  border:0!important;
  border-radius:13px!important;
  background:transparent!important;
  box-shadow:none!important;
  overflow:visible!important;
  margin:0!important;
}
.rp-config-accordion > summary,
.rp-config-accordion-module > summary{
  min-height:44px!important;
  padding:10px 16px!important;
  border-radius:13px!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  border:1px solid #102A56!important;
  box-shadow:none!important;
  font-size:15px!important;
  font-weight:400!important;
  list-style:none!important;
  cursor:pointer!important;
  display:flex!important;
  align-items:center!important;
  gap:12px!important;
}
.rp-config-accordion > summary::-webkit-details-marker,
.rp-config-accordion-module > summary::-webkit-details-marker{display:none!important;}
.rp-config-accordion[open] > summary,
.rp-config-accordion-module[open] > summary{border-radius:13px 13px 0 0!important;}
.rp-config-accordion-body{
  padding:14px!important;
  border:1px solid #dbe7f3!important;
  border-top:0!important;
  border-radius:0 0 13px 13px!important;
  background:#fff!important;
  box-shadow:none!important;
}
.rp-config-accordion-icon,
.rp-config-accordion-caret{color:#fff!important;}
.rp-config-accordion-icon svg{fill:none!important;stroke:currentColor!important;stroke-width:1.7!important;stroke-linecap:round!important;stroke-linejoin:round!important;}
/* Evita que los módulos nuevos se vean sueltos si el navegador los reubica por HTML viejo/cacheado. */
.rp-config-accordion-module{display:none!important;}
#configuracion .rp-config-accordion-wrap > .rp-config-accordion-module{display:block!important;}
#configuracion .rp-config-accordion-wrap{display:flex!important;flex-direction:column!important;gap:10px!important;}


/* v308: icono fino sin relleno en título de Configuración */
#configuracion .rp-config-title-icon{
  display:flex!important;
  align-items:center!important;
  gap:10px!important;
}
#configuracion .rp-config-title-icon .rp-title-svg{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  color:#102A56!important;
  line-height:0!important;
  flex:0 0 auto!important;
}
#configuracion .rp-config-title-icon .rp-title-svg svg{
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.55!important;
}

/* v309/v310 - Barras de progreso de configuración y disponibilidad */
#configuracion .rp-config-progress-card,
#disponibilidad .rp-config-progress-card{
  background:#fff!important;
  border:1px solid rgba(16,42,86,.12)!important;
  border-radius:18px!important;
  box-shadow:0 10px 26px rgba(15,23,42,.06)!important;
  padding:16px 18px!important;
  margin:18px 0 18px!important;
}
#configuracion .rp-config-progress-head,
#disponibilidad .rp-config-progress-head{
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:14px!important;
  margin-bottom:10px!important;
}
#configuracion .rp-config-progress-title,
#disponibilidad .rp-config-progress-title{
  display:flex!important;
  align-items:center!important;
  gap:10px!important;
  color:#102A56!important;
  font-weight:500!important;
  font-size:15px!important;
}
#configuracion .rp-config-progress-icon,
#disponibilidad .rp-config-progress-icon{
  width:34px!important;
  height:34px!important;
  border:1px solid rgba(16,42,86,.22)!important;
  border-radius:12px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  color:#102A56!important;
  flex:0 0 auto!important;
}
#configuracion .rp-config-progress-icon svg,
#disponibilidad .rp-config-progress-icon svg{
  width:20px!important;
  height:20px!important;
  fill:none!important;
  stroke:currentColor!important;
}
#configuracion .rp-config-progress-head strong,
#disponibilidad .rp-config-progress-head strong{
  color:#102A56!important;
  font-size:22px!important;
  line-height:1!important;
  font-weight:650!important;
}
#configuracion .rp-config-progress-bar,
#disponibilidad .rp-config-progress-bar{
  width:100%!important;
  height:10px!important;
  background:rgba(16,42,86,.10)!important;
  border-radius:999px!important;
  overflow:hidden!important;
}
#configuracion .rp-config-progress-bar span,
#disponibilidad .rp-config-progress-bar span{
  display:block!important;
  height:100%!important;
  min-width:4px!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  border-radius:999px!important;
}
#configuracion .rp-config-progress-card p,
#disponibilidad .rp-config-progress-card p{
  margin:9px 0 0!important;
  color:#64748b!important;
  font-size:13px!important;
  line-height:1.35!important;
  font-weight:400!important;
}
@media(max-width:680px){
  #configuracion .rp-config-progress-card,
  #disponibilidad .rp-config-progress-card{padding:14px!important;border-radius:15px!important;}
  #configuracion .rp-config-progress-head strong,
  #disponibilidad .rp-config-progress-head strong{font-size:20px!important;}
}

/* v310 - Disponibilidad: icono del menú y barra de progreso */
#disponibilidad .rp-availability-head .rp-title-svg svg{
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.8!important;
}
#disponibilidad .rp-availability-progress-card{
  margin-top:16px!important;
  margin-bottom:18px!important;
}

/* v311 - Inicio: KPIs con iconos lineales y próximo paciente con contenedor principal blanco */
#inicio .rp-dashboard-kpis > div{
  position:relative!important;
  gap:6px!important;
}
#inicio .rp-dashboard-kpis .rp-kpi-icon{
  width:28px!important;
  height:28px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  color:#102A56!important;
  margin:0 0 4px!important;
}
#inicio .rp-dashboard-kpis .rp-kpi-icon svg{
  width:28px!important;
  height:28px!important;
  display:block!important;
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.35!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
}
#inicio .rp-next-card.rp-next-dashboard-card{
  background:#fff!important;
  border:1px solid #D8E0EA!important;
  color:#102A56!important;
  box-shadow:none!important;
}
#inicio .rp-next-dashboard-card > h2{
  color:#102A56!important;
}
#inicio .rp-next-dashboard-card > h2 .rp-next-title-icon{
  color:#102A56!important;
}
#inicio .rp-next-dashboard-card > h2 .rp-next-title-icon svg{
  stroke:currentColor!important;
  fill:none!important;
}
#inicio .rp-next-dashboard-card .rp-next-countdown{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  border:1px solid rgba(16,42,86,.18)!important;
  color:#fff!important;
}
#inicio .rp-next-dashboard-card .rp-next-countdown small,
#inicio .rp-next-dashboard-card .rp-next-countdown span,
#inicio .rp-next-dashboard-card .rp-next-countdown strong{
  color:#fff!important;
}
#inicio .rp-next-dashboard-card .rp-next-patient-grid > div{
  background:#fff!important;
  background-image:none!important;
  border:1px solid #E4EAF2!important;
  color:#102A56!important;
}
#inicio .rp-next-dashboard-card .rp-next-patient-grid small,
#inicio .rp-next-dashboard-card .rp-next-patient-grid strong{
  color:#102A56!important;
  opacity:1!important;
}
#inicio .rp-next-dashboard-card .rp-next-countdown small,
#inicio .rp-next-dashboard-card .rp-next-countdown span{
  opacity:.78!important;
}
#inicio .rp-next-dashboard-card .rp-next-countdown strong{
  background:#fff!important;
  color:#102A56!important;
}

/* v312 - Gastos / métricas */
.rp-income-head h1,.rp-title-with-icon{display:flex;align-items:center;gap:10px}.rp-income-head .rp-title-icon,.rp-title-with-icon .rp-title-icon{width:28px;height:28px;display:inline-flex;align-items:center;justify-content:center;color:#102A56}.rp-income-head .rp-title-icon svg,.rp-title-with-icon .rp-title-icon svg{width:100%;height:100%;stroke:currentColor;fill:none}.rp-income-kpis-icons>div{display:flex!important;flex-direction:column!important;align-items:center!important;justify-content:center!important;text-align:center!important;gap:6px!important;min-height:138px}.rp-income-kpis-icons .rp-kpi-icon{width:30px;height:30px;color:#102A56;display:inline-flex;align-items:center;justify-content:center}.rp-income-kpis-icons .rp-kpi-icon svg{width:100%;height:100%;fill:none;stroke:currentColor}.rp-expense-add-btn{background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;color:#fff!important;border-color:#102A56!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:8px!important}.rp-expense-add-btn .rp-btn-svg{width:17px;height:17px;display:inline-flex}.rp-expense-add-btn .rp-btn-svg svg{width:100%;height:100%;fill:none;stroke:currentColor}.rp-income-tables-grid{display:grid;grid-template-columns:1fr;gap:18px;margin-top:18px}.rp-income-table-card{overflow:hidden}.rp-expenses-metrics-section .rp-responsive-table,.rp-expenses-metrics-section .rp-year-table{width:100%;max-width:100%;overflow-x:visible!important}.rp-expenses-metrics-section .rp-patient-table{width:100%!important;min-width:0!important;table-layout:auto!important}.rp-expenses-metrics-section .rp-patient-table th,.rp-expenses-metrics-section .rp-patient-table td{white-space:normal!important;overflow-wrap:anywhere!important}.rp-income-chart-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px;margin-top:18px}.rp-income-chart-grid .rp-chart-card{margin-top:0}.rp-income-chart-grid .rp-chart-card:nth-child(3){grid-column:1/-1}.rp-pie-wrap{display:flex;align-items:center;gap:22px;border:1px solid #e5e7eb;border-radius:16px;background:#fff;padding:18px}.rp-pie{width:150px;height:150px;border-radius:50%;display:block;flex:0 0 150px;box-shadow:inset 0 0 0 18px #fff,0 0 0 1px #e5e7eb}.rp-pie-metrics{display:grid;gap:6px;color:#475569}.rp-pie-metrics strong{color:#102A56;font-size:18px}.rp-pie-metrics p{margin:0}.rp-chart-bars-annual{gap:8px}.rp-chart-bars-annual .rp-chart-stack{gap:3px}.rp-chart-bars-annual .rp-chart-stack span{width:10px}.rp-chart-bars-annual .rp-chart-month small{font-size:11px}.rp-expense-table td:last-child,.rp-expense-table th:last-child{text-align:right}@media(max-width:1180px){.rp-income-chart-grid{grid-template-columns:1fr}.rp-income-chart-grid .rp-chart-card:nth-child(3){grid-column:auto}.rp-expenses-metrics-section .rp-responsive-table{overflow-x:auto!important}.rp-expenses-metrics-section .rp-patient-table{min-width:640px!important}}@media(max-width:720px){.rp-pie-wrap{align-items:flex-start;flex-direction:column}.rp-pie{width:132px;height:132px;flex-basis:132px}.rp-income-chart-grid{gap:12px}.rp-income-kpis-icons>div{min-height:126px}.rp-chart-bars-annual .rp-chart-month{min-width:62px}}

/* v313 Tickets / Mora / Facturación visual unificado */
#tickets .rp-title-with-icon,
#mora .rp-title-with-icon,
#facturacion .rp-title-with-icon{
  display:flex!important;
  align-items:center!important;
  gap:10px!important;
  color:#102A56!important;
}
#tickets .rp-title-icon,
#mora .rp-title-icon,
#facturacion .rp-title-icon{
  width:30px!important;
  height:30px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  color:#102A56!important;
  flex:0 0 30px!important;
}
#tickets .rp-title-icon svg,
#mora .rp-title-icon svg,
#facturacion .rp-title-icon svg,
#tickets .rp-card-svg svg,
#mora .rp-card-svg svg,
#facturacion .rp-card-svg svg,
#tickets .rp-btn-svg svg,
#mora .rp-btn-svg svg,
#facturacion .rp-btn-svg svg{
  width:100%!important;
  height:100%!important;
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.45!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
}
#tickets .rp-tickets-kpis,
#mora .rp-mora-kpis{
  display:grid!important;
  grid-template-columns:repeat(auto-fit,minmax(170px,1fr))!important;
  gap:14px!important;
  margin:16px 0 18px!important;
}
#tickets .rp-ticket-kpi,
#mora .rp-mora-kpis > div{
  min-height:132px!important;
  border:1px solid #e5e7eb!important;
  background:#fff!important;
  border-radius:18px!important;
  padding:18px 14px!important;
  display:flex!important;
  flex-direction:column!important;
  align-items:center!important;
  justify-content:center!important;
  text-align:center!important;
  gap:7px!important;
  box-shadow:0 10px 26px rgba(15,23,42,.035)!important;
}
#tickets .rp-card-svg,
#mora .rp-card-svg{
  width:30px!important;
  height:30px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  color:#102A56!important;
  margin-bottom:2px!important;
}
#tickets .rp-ticket-kpi strong,
#mora .rp-mora-kpis > div strong{
  display:block!important;
  font-size:24px!important;
  line-height:1.05!important;
  color:#102A56!important;
  font-weight:800!important;
}
#tickets .rp-ticket-kpi span:not(.rp-card-svg),
#mora .rp-mora-kpis > div span:not(.rp-card-svg){
  display:block!important;
  color:#475569!important;
  font-size:13px!important;
  font-weight:500!important;
  margin:0!important;
}
#mora .rp-mora-table-card,
#facturacion .rp-billing-table-card,
#tickets .rp-ticket-table-wrap{
  border-radius:18px!important;
  overflow:hidden!important;
  border:1px solid #e5e7eb!important;
  background:#fff!important;
}
#mora .rp-mora-table thead th,
#facturacion .rp-invoices-table thead th,
#tickets .rp-ticket-table thead th{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  font-weight:400!important;
  text-align:center!important;
  border:0!important;
  padding:13px 12px!important;
  text-transform:none!important;
  letter-spacing:0!important;
}
#mora .rp-mora-table thead th:first-child,
#facturacion .rp-invoices-table thead th:first-child,
#tickets .rp-ticket-table thead th:first-child{
  border-top-left-radius:14px!important;
}
#mora .rp-mora-table thead th:last-child,
#facturacion .rp-invoices-table thead th:last-child,
#tickets .rp-ticket-table thead th:last-child{
  border-top-right-radius:14px!important;
}
#mora .rp-mora-table td,
#facturacion .rp-invoices-table td,
#tickets .rp-ticket-table td{
  text-align:center!important;
  vertical-align:middle!important;
}
#mora .rp-mora-table td strong,
#facturacion .rp-invoices-table td strong{
  font-weight:700!important;
}
#mora .rp-mora-actions,
#facturacion .rp-invoice-actions-stack{
  display:flex!important;
  flex-wrap:wrap!important;
  justify-content:center!important;
  align-items:center!important;
  gap:8px!important;
}
#mora .rp-mora-actions form,
#facturacion .rp-invoice-actions-stack form{
  margin:0!important;
}
#mora .rp-mora-paid-btn,
#facturacion .rp-invoice-primary-btn{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  border-color:#102A56!important;
  color:#fff!important;
  font-weight:400!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:8px!important;
  min-height:38px!important;
  border-radius:12px!important;
}
#mora .rp-mora-notice-btn,
#facturacion .rp-invoice-draft-btn{
  background:#fff!important;
  border:1px solid #102A56!important;
  color:#102A56!important;
  font-weight:400!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:8px!important;
  min-height:38px!important;
  border-radius:12px!important;
  text-decoration:none!important;
  padding:8px 12px!important;
}
#mora .rp-btn-svg,
#facturacion .rp-btn-svg{
  width:17px!important;
  height:17px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  flex:0 0 17px!important;
}
@media(max-width:860px){
  #tickets .rp-tickets-kpis,
  #mora .rp-mora-kpis{grid-template-columns:1fr 1fr!important;}
  #mora .rp-mora-table-card .rp-responsive-table,
  #facturacion .rp-billing-table-card .rp-responsive-table,
  #tickets .rp-ticket-table-wrap{overflow-x:auto!important;}
}
@media(max-width:540px){
  #tickets .rp-tickets-kpis,
  #mora .rp-mora-kpis{grid-template-columns:1fr!important;}
}

/* v314 - Calendario General: título con icono outline y botón principal unificado */
#calendario-general .rp-prof-head .rp-title-with-icon{
    display:flex;
    align-items:center;
    gap:10px;
}
#calendario-general .rp-prof-head .rp-title-icon{
    width:28px;
    height:28px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    color:#102A56;
    flex:0 0 28px;
}
#calendario-general .rp-prof-head .rp-title-icon svg{
    width:100%;
    height:100%;
    fill:none;
    stroke:currentColor;
}
#calendario-general .rp-general-block-submit{
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    border-color:#102A56!important;
    color:#fff!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    gap:8px!important;
    font-weight:400!important;
}
#calendario-general .rp-general-block-submit:hover{
    filter:brightness(1.08);
}
#calendario-general .rp-general-block-submit .rp-btn-svg{
    width:17px;
    height:17px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    flex:0 0 17px;
}
#calendario-general .rp-general-block-submit .rp-btn-svg svg{
    width:100%;
    height:100%;
    fill:none;
    stroke:currentColor;
}

/* v315 - Gastos / métricas: tablas azules y acciones editar/eliminar */
.rp-expenses-metrics-section .rp-expense-table,
.rp-expenses-metrics-section .rp-income-detail-table{
  border-collapse:separate!important;
  border-spacing:0!important;
  overflow:hidden!important;
  border-radius:14px!important;
}
.rp-expenses-metrics-section .rp-expense-table thead th,
.rp-expenses-metrics-section .rp-income-detail-table thead th{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  font-weight:400!important;
  text-align:center!important;
  border-bottom:0!important;
  padding:13px 12px!important;
  letter-spacing:.025em!important;
}
.rp-expenses-metrics-section .rp-expense-table thead th:first-child,
.rp-expenses-metrics-section .rp-income-detail-table thead th:first-child{
  border-top-left-radius:14px!important;
}
.rp-expenses-metrics-section .rp-expense-table thead th:last-child,
.rp-expenses-metrics-section .rp-income-detail-table thead th:last-child{
  border-top-right-radius:14px!important;
}
.rp-expenses-metrics-section .rp-expense-table tbody td,
.rp-expenses-metrics-section .rp-income-detail-table tbody td{
  text-align:center!important;
}
.rp-expenses-metrics-section .rp-expense-table tbody td:nth-child(2),
.rp-expenses-metrics-section .rp-income-detail-table tbody td:nth-child(2){
  text-align:left!important;
}
.rp-expense-row-actions,
.rp-expense-form-actions{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:8px!important;
  flex-wrap:wrap!important;
}
.rp-expense-row-actions form{margin:0!important;display:inline-flex!important;}
.rp-expense-edit-btn,
.rp-expense-delete-btn,
.rp-expense-cancel-btn{
  min-height:34px!important;
  border-radius:10px!important;
  padding:8px 11px!important;
  font-size:12px!important;
  font-weight:400!important;
  line-height:1!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:7px!important;
  text-decoration:none!important;
  cursor:pointer!important;
  white-space:nowrap!important;
}
.rp-expense-edit-btn{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  border:1px solid #102A56!important;
  color:#fff!important;
}
.rp-expense-delete-btn,
.rp-expense-cancel-btn{
  background:#fff!important;
  border:1px solid #102A56!important;
  color:#102A56!important;
}
.rp-expense-edit-btn .rp-btn-svg,
.rp-expense-delete-btn .rp-btn-svg,
.rp-expense-cancel-btn .rp-btn-svg{
  width:16px!important;
  height:16px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  flex:0 0 16px!important;
}
.rp-expense-edit-btn svg,
.rp-expense-delete-btn svg,
.rp-expense-cancel-btn svg{
  width:16px!important;
  height:16px!important;
  fill:none!important;
  stroke:currentColor!important;
}
.rp-expense-table td:last-child,
.rp-expense-table th:last-child{
  text-align:center!important;
}
@media(max-width:720px){
  .rp-expense-row-actions{justify-content:flex-start!important;}
}

/* v316 - Mobile: centrado real del panel, proximo paciente compacto y hamburguesa blanca */
@media (max-width: 980px){
  html, body{
    overflow-x:hidden!important;
  }
  .rp-prof-panel,
  .rp-prof-panel.rp-sidebar-expanded{
    width:calc(100% - 20px)!important;
    max-width:calc(100% - 20px)!important;
    min-width:0!important;
    margin:10px auto 18px!important;
    margin-left:auto!important;
    margin-right:auto!important;
    transform:none!important;
    left:auto!important;
    right:auto!important;
    display:block!important;
    border-radius:18px!important;
    overflow:hidden!important;
  }
  .rp-prof-main{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    padding:22px 16px!important;
    overflow:visible!important;
  }
  .rp-prof-section,
  .rp-card,
  .rp-list-card,
  .rp-patient-card,
  .rp-table-card,
  .rp-calendar-shell,
  .rp-detail-card,
  .rp-next-dashboard-card,
  .rp-dashboard-notifications-card{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
  }
  .rp-prof-sidebar,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar{
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    color:#fff!important;
    width:100%!important;
    max-width:100%!important;
    padding:14px 16px!important;
    border-radius:0!important;
  }
  .rp-sidebar-toggle{
    width:46px!important;
    height:46px!important;
    min-width:46px!important;
    min-height:46px!important;
    color:#fff!important;
    font-size:34px!important;
    line-height:1!important;
    background:transparent!important;
    border:0!important;
    box-shadow:none!important;
    opacity:1!important;
  }
  .rp-sidebar-toggle svg,
  .rp-sidebar-toggle svg *{
    width:30px!important;
    height:30px!important;
    stroke:#fff!important;
    fill:none!important;
    stroke-width:1.8!important;
  }
  .rp-sidebar-toggle::before{
    color:#fff!important;
  }
  .rp-prof-sidebar.mobile-open .rp-sidebar-toggle::before,
  body > .rp-prof-sidebar.mobile-open .rp-sidebar-toggle::before{
    color:#fff!important;
  }
}

@media (max-width: 760px){
  #inicio .rp-dashboard-kpis,
  #inicio .rp-kpis.rp-dashboard-kpis{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:14px!important;
    width:100%!important;
  }
  #inicio .rp-dashboard-kpis > div{
    min-height:144px!important;
    padding:18px 12px!important;
  }
  #inicio .rp-next-card.rp-next-dashboard-card,
  #inicio .rp-next-dashboard-card{
    padding:18px 14px!important;
    border-radius:18px!important;
    margin-left:0!important;
    margin-right:0!important;
    overflow:hidden!important;
  }
  #inicio .rp-next-dashboard-card > h2{
    font-size:26px!important;
    line-height:1.12!important;
    margin-bottom:16px!important;
  }
  #inicio .rp-next-countdown{
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
    justify-content:flex-start!important;
    gap:10px!important;
    padding:14px!important;
    margin-bottom:12px!important;
    min-height:0!important;
    height:auto!important;
    border-radius:14px!important;
  }
  #inicio .rp-next-countdown small,
  #inicio .rp-next-countdown span{
    display:block!important;
    width:100%!important;
    line-height:1.25!important;
  }
  #inicio .rp-next-countdown strong{
    display:block!important;
    width:100%!important;
    max-width:100%!important;
    box-sizing:border-box!important;
    text-align:center!important;
    font-size:28px!important;
    line-height:1.05!important;
    padding:12px 10px!important;
    margin:0!important;
    border-radius:13px!important;
  }
  #inicio .rp-next-patient-grid{
    grid-template-columns:1fr!important;
    gap:10px!important;
    width:100%!important;
    margin:0 0 12px!important;
  }
  #inicio .rp-next-patient-grid > div{
    min-height:0!important;
    height:auto!important;
    padding:15px 14px!important;
    border-radius:14px!important;
  }
  #inicio .rp-next-patient-grid small{
    font-size:14px!important;
  }
  #inicio .rp-next-patient-grid strong{
    font-size:18px!important;
    line-height:1.2!important;
    word-break:break-word!important;
  }
  #inicio .rp-next-actions,
  #inicio .rp-next-meet-share{
    width:100%!important;
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
  }
  #inicio .rp-next-actions .rp-btn,
  #inicio .rp-next-actions button,
  #inicio .rp-next-meet-share .rp-btn,
  #inicio .rp-next-meet-share button,
  #inicio .rp-next-actions .rp-inline-cancel-form,
  #inicio .rp-next-meet-share .rp-inline-meet-email-form{
    width:100%!important;
    max-width:100%!important;
    justify-content:center!important;
  }
}

/* v317 - Mobile: menu azul compacto, hamburguesa visible y próximo paciente sin bloque gigante */
@media (max-width: 980px){
  .rp-sidebar-toggle,
  .rp-prof-sidebar .rp-sidebar-toggle,
  .rp-prof-panel .rp-sidebar-toggle{
    width:56px!important;
    height:56px!important;
    min-width:56px!important;
    min-height:56px!important;
    font-size:46px!important;
    line-height:1!important;
    color:#fff!important;
    background:transparent!important;
    border:0!important;
    box-shadow:none!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    padding:0!important;
    opacity:1!important;
    font-weight:400!important;
  }
  .rp-prof-sidebar.mobile-open,
  body > .rp-prof-sidebar.mobile-open{
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    color:#fff!important;
    padding:calc(18px + env(safe-area-inset-top)) 18px calc(24px + env(safe-area-inset-bottom))!important;
  }
  .rp-prof-sidebar.mobile-open .rp-prof-brand,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand{
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    border-bottom:1px solid rgba(255,255,255,.18)!important;
    color:#fff!important;
    margin-bottom:14px!important;
  }
  .rp-prof-sidebar.mobile-open .rp-prof-brand strong,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand strong{
    color:#fff!important;
    opacity:1!important;
  }
  .rp-prof-sidebar.mobile-open .rp-sidebar-toggle,
  body > .rp-prof-sidebar.mobile-open .rp-sidebar-toggle{
    color:#fff!important;
    font-size:0!important;
  }
  .rp-prof-sidebar.mobile-open .rp-sidebar-toggle::before,
  body > .rp-prof-sidebar.mobile-open .rp-sidebar-toggle::before{
    content:'×'!important;
    color:#fff!important;
    font-size:48px!important;
    line-height:1!important;
    font-weight:300!important;
  }
  .rp-prof-sidebar.mobile-open a,
  body > .rp-prof-sidebar.mobile-open a{
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    border:1px solid rgba(255,255,255,.18)!important;
    color:#fff!important;
    box-shadow:none!important;
    min-height:46px!important;
    height:46px!important;
    padding:0 14px!important;
    margin:4px 0!important;
    border-radius:14px!important;
    gap:11px!important;
    font-size:14px!important;
    font-weight:400!important;
  }
  .rp-prof-sidebar.mobile-open a.active,
  .rp-prof-sidebar.mobile-open a:hover,
  body > .rp-prof-sidebar.mobile-open a.active,
  body > .rp-prof-sidebar.mobile-open a:hover{
    background:#0B7FAB!important;
    border-color:#0B7FAB!important;
    color:#fff!important;
  }
  .rp-prof-sidebar.mobile-open .rp-nav-label,
  body > .rp-prof-sidebar.mobile-open .rp-nav-label{
    color:#fff!important;
    font-size:14px!important;
    line-height:1.1!important;
    font-weight:400!important;
  }
  .rp-prof-sidebar.mobile-open .rp-nav-icon,
  body > .rp-prof-sidebar.mobile-open .rp-nav-icon{
    color:#fff!important;
    width:18px!important;
    height:18px!important;
    min-width:18px!important;
  }
  .rp-prof-sidebar.mobile-open .rp-nav-icon svg,
  body > .rp-prof-sidebar.mobile-open .rp-nav-icon svg{
    width:18px!important;
    height:18px!important;
    stroke:#fff!important;
    fill:none!important;
    stroke-width:1.6!important;
  }
}

@media (max-width: 760px){
  #inicio .rp-next-card.rp-next-dashboard-card,
  #inicio .rp-next-dashboard-card{
    background:#fff!important;
    border-color:#D8E1EA!important;
    color:#102A56!important;
    padding:16px 14px!important;
    overflow:visible!important;
  }
  #inicio .rp-next-dashboard-card > h2{
    color:#102A56!important;
    font-size:25px!important;
    line-height:1.12!important;
    margin:0 0 14px!important;
  }
  #inicio .rp-next-dashboard-card > h2 .rp-next-title-icon,
  #inicio .rp-next-dashboard-card > h2 .rp-next-title-icon svg{
    color:#102A56!important;
    stroke:#102A56!important;
  }
  #inicio .rp-next-countdown{
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    border-color:#102A56!important;
    color:#fff!important;
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:8px!important;
    padding:14px!important;
    margin:0 0 12px!important;
    min-height:0!important;
    height:auto!important;
    max-height:none!important;
    border-radius:14px!important;
  }
  #inicio .rp-next-countdown small,
  #inicio .rp-next-countdown span{
    color:rgba(255,255,255,.78)!important;
    font-size:15px!important;
    line-height:1.25!important;
    font-weight:400!important;
    width:auto!important;
    display:block!important;
    flex:0 0 auto!important;
  }
  #inicio .rp-next-countdown strong{
    background:#fff!important;
    color:#102A56!important;
    width:100%!important;
    display:block!important;
    box-sizing:border-box!important;
    text-align:center!important;
    font-size:30px!important;
    line-height:1!important;
    padding:11px 10px!important;
    margin:0!important;
    border-radius:13px!important;
    flex:0 0 auto!important;
  }
  #inicio .rp-next-patient-grid > div{
    background:#fff!important;
    background-image:none!important;
    border:1px solid #E4EAF2!important;
    color:#102A56!important;
  }
  #inicio .rp-next-patient-grid small{color:#102A56!important;}
  #inicio .rp-next-patient-grid strong{color:#102A56!important;}
}

/* v318 - Correcciones mobile: menú, modales, calendario, historias y disponibilidad */
@media (max-width: 980px){
  .rp-prof-sidebar.mobile-open .rp-prof-brand,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand{
    min-height:96px!important;
    height:auto!important;
    padding:14px 12px 18px!important;
    overflow:visible!important;
    align-items:center!important;
  }
  .rp-prof-sidebar.mobile-open .rp-prof-brand img,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand img{
    width:82px!important;
    height:82px!important;
    max-width:82px!important;
    max-height:82px!important;
    object-fit:contain!important;
    display:block!important;
    flex:0 0 82px!important;
  }
  .rp-prof-sidebar.mobile-open .rp-prof-brand strong,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand strong{
    line-height:1.15!important;
    white-space:normal!important;
    overflow:visible!important;
  }
}

.rp-modal[data-rp-modal="patient"] .rp-modal-box{
  width:min(880px,96vw)!important;
}
.rp-modal[data-rp-modal="patient"] .rp-patient-form label{
  color:#1f2937!important;
  font-weight:500!important;
  gap:7px!important;
  min-height:0!important;
  height:auto!important;
  overflow:visible!important;
}
.rp-modal[data-rp-modal="patient"] .rp-patient-form input,
.rp-modal[data-rp-modal="patient"] .rp-patient-form select,
.rp-modal[data-rp-modal="patient"] .rp-patient-form textarea{
  display:block!important;
  visibility:visible!important;
  opacity:1!important;
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  min-height:48px!important;
  height:auto!important;
  border:1px solid #D8E1EA!important;
  border-radius:12px!important;
  background:#fff!important;
  color:#1f2937!important;
  padding:12px 14px!important;
  box-sizing:border-box!important;
  font-size:15px!important;
  line-height:1.25!important;
}
.rp-modal[data-rp-modal="patient"] .rp-patient-form textarea{
  min-height:96px!important;
  resize:vertical!important;
}
.rp-modal[data-rp-modal="patient"] .rp-patient-save-btn{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  border:1px solid #102A56!important;
  font-weight:400!important;
  gap:8px!important;
}
.rp-modal[data-rp-modal="patient"] .rp-patient-save-btn svg{
  fill:none!important;
  stroke:#fff!important;
  stroke-width:1.45!important;
}
@media (max-width:760px){
  .rp-modal[data-rp-modal="patient"]{
    padding:12px!important;
    align-items:flex-start!important;
    padding-top:calc(18px + env(safe-area-inset-top))!important;
  }
  .rp-modal[data-rp-modal="patient"] .rp-modal-box{
    width:100%!important;
    max-width:100%!important;
    max-height:calc(100vh - 34px)!important;
    padding:24px 18px!important;
    border-radius:22px!important;
  }
  .rp-modal[data-rp-modal="patient"] .rp-patient-form{
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:14px!important;
  }
  .rp-modal[data-rp-modal="patient"] .rp-patient-form .full,
  .rp-modal[data-rp-modal="patient"] .rp-patient-form label,
  .rp-modal[data-rp-modal="patient"] .rp-patient-form button{
    grid-column:1/-1!important;
    width:100%!important;
  }
  .rp-modal[data-rp-modal="patient"] .rp-modal-close{
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    color:#fff!important;
    font-size:28px!important;
  }
}

@media (max-width:760px){
  #pacientes .rp-patient-calendar-below,
  #pacientes .rp-patient-calendar-picker,
  #pacientes .rp-vbz-calendar-wrap,
  #calendario-general .rp-calendar-shell{
    overflow-x:auto!important;
    overflow-y:visible!important;
    -webkit-overflow-scrolling:touch!important;
  }
  #pacientes .rp-patient-calendar-grid.rp-admin-calendar,
  #pacientes .rp-patient-calendar-grid,
  #calendario-general .rp-admin-calendar{
    grid-template-columns:repeat(7,74px)!important;
    min-width:560px!important;
    width:max-content!important;
    max-width:none!important;
    gap:8px!important;
  }
  #pacientes .rp-patient-calendar-grid .rp-day-cell,
  #calendario-general .rp-admin-calendar .rp-day-cell{
    min-width:74px!important;
    width:74px!important;
    min-height:96px!important;
    padding:8px 6px!important;
    overflow:hidden!important;
  }
  #pacientes .rp-patient-calendar-grid .rp-day-cell span,
  #pacientes .rp-patient-calendar-grid .rp-day-cell em,
  #calendario-general .rp-admin-calendar .rp-day-cell span,
  #calendario-general .rp-admin-calendar .rp-day-cell em{
    font-size:11px!important;
    line-height:1.1!important;
    white-space:normal!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
  }
}

@media (max-width:760px){
  #historia .rp-history-actions,
  #pacientes .rp-history-actions{
    display:flex!important;
    flex-wrap:wrap!important;
    gap:8px!important;
    justify-content:center!important;
    align-items:center!important;
  }
  #historia .rp-history-actions .rp-mini-action,
  #historia .rp-history-actions .rp-btn,
  #historia .rp-history-actions button,
  #pacientes .rp-history-actions .rp-mini-action,
  #pacientes .rp-history-actions .rp-btn,
  #pacientes .rp-history-actions button,
  #historia .rp-history-edit-open,
  #pacientes .rp-history-edit-open{
    width:44px!important;
    height:44px!important;
    min-width:44px!important;
    padding:0!important;
    border-radius:12px!important;
    font-size:0!important;
    gap:0!important;
    overflow:hidden!important;
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
  }
  #historia .rp-history-actions svg,
  #pacientes .rp-history-actions svg,
  #historia .rp-history-edit-open svg,
  #pacientes .rp-history-edit-open svg{
    width:20px!important;
    height:20px!important;
    margin:0!important;
    flex:0 0 20px!important;
  }
}

@media (max-width:760px){
  .rp-prof-panel .rp-unavailable-box,
  .rp-prof-panel .rp-unavailable-day,
  .rp-prof-panel .rp-unavailable-rows,
  .rp-prof-panel .rp-unavailable-row{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
    overflow:visible!important;
  }
  .rp-prof-panel .rp-unavailable-row{
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:12px!important;
    padding:14px!important;
  }
  .rp-prof-panel .rp-unavailable-row label,
  .rp-prof-panel .rp-unavailable-row .rp-unavailable-reason,
  .rp-prof-panel .rp-unavailable-row .rp-unavailable-remove{
    grid-column:1/-1!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
  }
  .rp-prof-panel .rp-unavailable-row input,
  .rp-prof-panel .rp-unavailable-row select{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
  }
}

@media (max-width:760px){
  #inicio .rp-next-countdown{
    min-height:0!important;
    height:auto!important;
    max-height:230px!important;
    padding:14px!important;
    overflow:hidden!important;
  }
  #inicio .rp-next-countdown strong{
    min-height:0!important;
  }
}

/* v319 - Mobile: corregir logo cortado en menú desplegado */
@media (max-width: 980px){
  .rp-prof-sidebar.mobile-open .rp-prof-brand,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand{
    display:flex!important;
    flex-direction:row!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:14px!important;
    min-height:104px!important;
    padding:16px 14px 18px!important;
    overflow:visible!important;
  }
  .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo-wrap,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo-wrap{
    width:82px!important;
    height:82px!important;
    min-width:82px!important;
    flex:0 0 82px!important;
    border-radius:16px!important;
    overflow:hidden!important;
    display:grid!important;
    place-items:center!important;
    background:#fff!important;
    padding:0!important;
    margin:0!important;
  }
  .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo,
  .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo-wrap img,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo-wrap img{
    width:76px!important;
    height:76px!important;
    max-width:76px!important;
    max-height:76px!important;
    object-fit:contain!important;
    object-position:center center!important;
    display:block!important;
    border-radius:13px!important;
    flex:none!important;
  }
  .rp-prof-sidebar.mobile-open .rp-prof-brand strong,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand strong{
    display:block!important;
    flex:1 1 auto!important;
    min-width:0!important;
    margin:0!important;
    color:#fff!important;
    white-space:normal!important;
    overflow:visible!important;
  }
}

/* v326 - Inicio: campana superior y cancelar con X blanca */
#inicio .rp-dashboard-title-row{
  display:flex!important;
  align-items:flex-start!important;
  justify-content:space-between!important;
  gap:16px!important;
  width:100%!important;
}
#inicio .rp-dashboard-title-copy{min-width:0!important;}
#inicio .rp-dashboard-bell{
  position:relative!important;
  width:46px!important;
  height:46px!important;
  min-width:46px!important;
  border-radius:14px!important;
  background:#fff!important;
  border:1px solid #D8E0EA!important;
  color:#102A56!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  text-decoration:none!important;
  box-shadow:0 8px 22px rgba(16,42,86,.08)!important;
}
#inicio .rp-dashboard-bell-icon{width:24px!important;height:24px!important;display:inline-flex!important;}
#inicio .rp-dashboard-bell-icon svg{width:100%!important;height:100%!important;fill:none!important;stroke:currentColor!important;stroke-width:1.55!important;stroke-linecap:round!important;stroke-linejoin:round!important;}
#inicio .rp-dashboard-bell-count{
  position:absolute!important;
  right:-7px!important;
  top:-7px!important;
  min-width:22px!important;
  height:22px!important;
  padding:0 6px!important;
  border-radius:999px!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  border:2px solid #fff!important;
  font-size:12px!important;
  line-height:18px!important;
  font-weight:400!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  box-sizing:border-box!important;
}
#inicio .rp-next-actions .rp-btn-danger,
#inicio .rp-next-actions button.rp-btn-danger{
  background:#d94141!important;
  color:#fff!important;
  border-color:#d94141!important;
}
#inicio .rp-next-actions .rp-btn-danger .rp-btn-svg,
#inicio .rp-next-actions button.rp-btn-danger .rp-btn-svg,
#inicio .rp-next-actions .rp-btn-danger .rp-btn-svg svg,
#inicio .rp-next-actions button.rp-btn-danger .rp-btn-svg svg{
  color:#fff!important;
  stroke:#fff!important;
}
#inicio .rp-next-actions .rp-btn-danger:hover,
#inicio .rp-next-actions button.rp-btn-danger:hover{
  background:#b42318!important;
  color:#fff!important;
  border-color:#b42318!important;
}
@media(max-width:720px){
  #inicio .rp-dashboard-title-row{align-items:center!important;}
  #inicio .rp-dashboard-bell{width:42px!important;height:42px!important;min-width:42px!important;border-radius:13px!important;}
  #inicio .rp-dashboard-bell-icon{width:22px!important;height:22px!important;}
}

/* v327 - Mobile header cerrado: alinear logo, titulo y hamburguesa */
@media (max-width: 980px){
  .rp-prof-sidebar:not(.mobile-open),
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open){
    padding:16px 18px!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand{
    height:94px!important;
    min-height:94px!important;
    width:100%!important;
    margin:0!important;
    padding:0!important;
    display:grid!important;
    grid-template-columns:84px 1fr 62px!important;
    align-items:center!important;
    justify-content:stretch!important;
    gap:0!important;
    overflow:visible!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand .rp-brand-logo-wrap,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand .rp-brand-logo-wrap{
    width:72px!important;
    height:72px!important;
    min-width:72px!important;
    margin:0!important;
    padding:0!important;
    transform:none!important;
    display:grid!important;
    place-items:center!important;
    align-self:center!important;
    justify-self:start!important;
    overflow:hidden!important;
    border-radius:18px!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand .rp-brand-logo,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand .rp-brand-logo{
    width:64px!important;
    height:64px!important;
    max-width:64px!important;
    max-height:64px!important;
    object-fit:contain!important;
    object-position:center center!important;
    display:block!important;
    transform:none!important;
    margin:0!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    align-self:center!important;
    width:100%!important;
    max-width:none!important;
    min-width:0!important;
    height:100%!important;
    margin:0!important;
    padding:0 8px!important;
    opacity:1!important;
    color:#fff!important;
    text-align:center!important;
    line-height:1.05!important;
    font-size:18px!important;
    font-weight:700!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    transform:none!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle{
    align-self:center!important;
    justify-self:end!important;
    margin:0!important;
    width:56px!important;
    height:56px!important;
    min-width:56px!important;
    min-height:56px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    color:#fff!important;
    background:transparent!important;
    border:0!important;
    box-shadow:none!important;
    line-height:1!important;
    font-size:48px!important;
    transform:none!important;
  }
}

/* v328 - Notificaciones limpias: sin sombra/borde, acciones unificadas y mobile contenido dentro */
#inicio .rp-dashboard-bell{
  background:transparent!important;
  border:0!important;
  box-shadow:none!important;
  width:auto!important;
  min-width:0!important;
  height:auto!important;
  min-height:0!important;
  padding:0!important;
  border-radius:0!important;
  color:#102A56!important;
}
#inicio .rp-dashboard-bell-count{
  top:-9px!important;
  right:-11px!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  box-shadow:none!important;
}
#inicio .rp-dashboard-notifications-card{
  box-shadow:none!important;
  border:0!important;
  background:#fff!important;
  overflow:hidden!important;
}
#inicio .rp-dashboard-notification-item{
  box-shadow:none!important;
  border:0!important;
  background:#fff!important;
  max-width:100%!important;
}
#inicio .rp-notification-confirm-btn{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  border-color:#102A56!important;
  color:#fff!important;
  font-weight:400!important;
}
#inicio .rp-notification-confirm-btn svg,
#inicio .rp-notification-confirm-btn svg path{
  color:#fff!important;
  stroke:#fff!important;
}
#inicio .rp-icon-trash-btn{
  background:#fff!important;
  color:#102A56!important;
  border:1.4px solid #102A56!important;
  box-shadow:none!important;
}
#inicio .rp-icon-trash-btn svg,
#inicio .rp-icon-trash-btn svg path{
  color:#102A56!important;
  stroke:#102A56!important;
}
#inicio .rp-icon-trash-btn:hover{
  background:#f6f9fc!important;
  color:#102A56!important;
}
#inicio .rp-dashboard-notifications-head .rp-bell-icon{
  background:transparent!important;
  box-shadow:none!important;
  border:0!important;
  padding:0!important;
  color:#102A56!important;
}

@media (max-width: 620px){
  #inicio .rp-dashboard-notifications-card{
    width:100%!important;
    max-width:100%!important;
    box-sizing:border-box!important;
    padding-left:18px!important;
    padding-right:18px!important;
    overflow:hidden!important;
  }
  #inicio .rp-dashboard-notifications-list{
    width:100%!important;
    max-width:100%!important;
    overflow-x:hidden!important;
  }
  #inicio .rp-dashboard-notification-item{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
    padding:18px 14px!important;
    overflow:hidden!important;
  }
  #inicio .rp-dashboard-notification-main,
  #inicio .rp-dashboard-notification-meta,
  #inicio .rp-dashboard-notification-actions{
    min-width:0!important;
    max-width:100%!important;
  }
  #inicio .rp-dashboard-notification-actions{
    display:grid!important;
    grid-template-columns:1fr 1fr 44px!important;
    gap:9px!important;
    align-items:center!important;
    width:100%!important;
  }
  #inicio .rp-notification-profile-btn,
  #inicio .rp-notification-confirm-form,
  #inicio .rp-notification-confirm-btn{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
  }
  #inicio .rp-notification-profile-btn,
  #inicio .rp-notification-confirm-btn{
    padding-left:10px!important;
    padding-right:10px!important;
    font-size:13px!important;
  }
  #inicio .rp-notification-delete-form{
    width:44px!important;
    min-width:44px!important;
  }
  #inicio .rp-icon-trash-btn{
    width:44px!important;
    min-width:44px!important;
    height:44px!important;
  }
}

@media (max-width: 380px){
  #inicio .rp-dashboard-notification-actions{
    grid-template-columns:1fr!important;
  }
  #inicio .rp-notification-delete-form,
  #inicio .rp-icon-trash-btn{
    width:100%!important;
    min-width:0!important;
  }
}

/* v329 - Notificaciones: separador fino y confirmar azul */
#inicio .rp-dashboard-notifications-card{
  background:#fff!important;
  box-shadow:none!important;
  border:0!important;
  overflow:hidden!important;
}
#inicio .rp-dashboard-notifications-list{
  display:block!important;
  width:100%!important;
  max-width:100%!important;
}
#inicio .rp-dashboard-notification-item{
  display:grid!important;
  grid-template-columns:minmax(180px,1.2fr) minmax(240px,1.4fr) auto!important;
  gap:14px!important;
  align-items:center!important;
  background:#fff!important;
  box-shadow:none!important;
  border:0!important;
  border-radius:0!important;
  border-bottom:1px solid #E5E7EB!important;
  padding:18px 0!important;
  margin:0!important;
}
#inicio .rp-dashboard-notification-item:last-child{
  border-bottom:0!important;
  padding-bottom:0!important;
}
#inicio .rp-notification-confirm-btn,
#inicio .rp-dashboard-notification-actions .rp-notification-confirm-btn{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:7px!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  border:1px solid #102A56!important;
  color:#fff!important;
  font-weight:400!important;
  border-radius:12px!important;
  padding:10px 16px!important;
  min-height:40px!important;
  height:auto!important;
  line-height:1!important;
  white-space:nowrap!important;
}
#inicio .rp-notification-confirm-btn svg,
#inicio .rp-notification-confirm-btn svg path{
  color:#fff!important;
  stroke:#fff!important;
}
#inicio .rp-notification-confirm-btn:hover{
  background:#0B2147!important;
  border-color:#0B2147!important;
  color:#fff!important;
}
#inicio .rp-notification-profile-btn{
  border-radius:12px!important;
  padding:10px 14px!important;
  min-height:40px!important;
}
#inicio .rp-icon-trash-btn{
  background:#fff!important;
  color:#102A56!important;
  border:1px solid #D7DEE8!important;
  border-radius:12px!important;
  box-shadow:none!important;
}
#inicio .rp-icon-trash-btn svg,
#inicio .rp-icon-trash-btn svg path{
  color:#102A56!important;
  stroke:#102A56!important;
}

@media (max-width: 900px){
  #inicio .rp-dashboard-notification-item{
    grid-template-columns:1fr!important;
    align-items:start!important;
  }
}
@media (max-width: 620px){
  #inicio .rp-dashboard-notifications-card{
    width:100%!important;
    max-width:100%!important;
    overflow:hidden!important;
  }
  #inicio .rp-dashboard-notifications-list{
    width:100%!important;
    max-width:100%!important;
    overflow-x:auto!important;
    -webkit-overflow-scrolling:touch!important;
  }
  #inicio .rp-dashboard-notification-item{
    min-width:0!important;
    width:100%!important;
    max-width:100%!important;
    padding:18px 0!important;
    box-sizing:border-box!important;
  }
  #inicio .rp-dashboard-notification-actions{
    display:grid!important;
    grid-template-columns:1fr 1fr 44px!important;
    gap:9px!important;
    width:100%!important;
  }
  #inicio .rp-notification-confirm-form,
  #inicio .rp-notification-confirm-btn,
  #inicio .rp-notification-profile-btn{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
  }
  #inicio .rp-notification-confirm-btn,
  #inicio .rp-notification-profile-btn{
    font-size:13px!important;
    padding:10px 8px!important;
  }
  #inicio .rp-notification-delete-form,
  #inicio .rp-icon-trash-btn{
    width:44px!important;
    min-width:44px!important;
  }
}


/* v330 - Notificaciones compactas con tipo, nombres normalizados y botones móviles más chicos */
#inicio .rp-dashboard-notification-item{
  grid-template-columns:minmax(170px,1.05fr) minmax(230px,1.35fr) auto!important;
  gap:10px!important;
  padding:13px 0!important;
}
#inicio .rp-dashboard-notification-main{
  display:grid!important;
  gap:2px!important;
}
#inicio .rp-notification-kind{
  display:inline-flex!important;
  align-items:center!important;
  gap:6px!important;
  margin:0 0 3px!important;
  color:#102A56!important;
  font-size:12px!important;
  line-height:1.15!important;
  font-weight:400!important;
  letter-spacing:.01em!important;
}
#inicio .rp-notification-kind svg,
#inicio .rp-notification-kind svg path{
  color:#102A56!important;
  stroke:#102A56!important;
}
#inicio .rp-dashboard-notification-main strong{
  font-size:15px!important;
  line-height:1.18!important;
  font-weight:700!important;
  text-transform:none!important;
}
#inicio .rp-dashboard-notification-main span:not(.rp-notification-kind){
  margin-top:1px!important;
  font-size:12px!important;
  line-height:1.15!important;
}
#inicio .rp-dashboard-notification-meta{
  gap:3px!important;
  font-size:13px!important;
  line-height:1.25!important;
}
#inicio .rp-dashboard-notification-actions{
  gap:7px!important;
}
#inicio .rp-notification-confirm-btn svg,
#inicio .rp-notification-confirm-btn svg path{
  color:#fff!important;
  stroke:#fff!important;
}
@media (max-width: 620px){
  #inicio .rp-dashboard-notification-item{
    padding:14px 0!important;
    gap:9px!important;
  }
  #inicio .rp-dashboard-notification-main strong{
    font-size:18px!important;
  }
  #inicio .rp-dashboard-notification-meta{
    gap:6px!important;
    font-size:15px!important;
  }
  #inicio .rp-dashboard-notification-actions{
    grid-template-columns:minmax(0,1fr) minmax(0,1.08fr) 38px!important;
    gap:8px!important;
    align-items:center!important;
  }
  #inicio .rp-notification-confirm-btn,
  #inicio .rp-notification-profile-btn{
    min-height:40px!important;
    height:40px!important;
    padding:8px 8px!important;
    font-size:13px!important;
    border-radius:12px!important;
    gap:5px!important;
  }
  #inicio .rp-notification-confirm-btn svg,
  #inicio .rp-notification-profile-btn svg{
    width:15px!important;
    height:15px!important;
    min-width:15px!important;
  }
  #inicio .rp-notification-delete-form,
  #inicio .rp-icon-trash-btn{
    width:38px!important;
    min-width:38px!important;
    height:40px!important;
    min-height:40px!important;
  }
  #inicio .rp-icon-trash-btn svg{
    width:17px!important;
    height:17px!important;
  }
}

/* v331 - Notificaciones móvil: habilita scroll horizontal real para contenido compacto */
@media (max-width: 620px){
  #inicio .rp-dashboard-notifications-card{
    overflow:hidden!important;
  }
  #inicio .rp-dashboard-notifications-list{
    display:block!important;
    width:100%!important;
    max-width:100%!important;
    overflow-x:auto!important;
    overflow-y:visible!important;
    -webkit-overflow-scrolling:touch!important;
    padding-bottom:8px!important;
    scrollbar-width:thin!important;
  }
  #inicio .rp-dashboard-notification-item{
    display:grid!important;
    grid-template-columns:180px 260px 210px!important;
    gap:10px!important;
    width:670px!important;
    max-width:none!important;
    min-width:670px!important;
    box-sizing:border-box!important;
    align-items:center!important;
  }
  #inicio .rp-dashboard-notification-main,
  #inicio .rp-dashboard-notification-meta,
  #inicio .rp-dashboard-notification-actions{
    min-width:0!important;
  }
  #inicio .rp-dashboard-notification-actions{
    display:grid!important;
    grid-template-columns:86px 98px 34px!important;
    gap:6px!important;
    width:auto!important;
  }
  #inicio .rp-notification-profile-btn,
  #inicio .rp-notification-confirm-btn{
    height:36px!important;
    min-height:36px!important;
    padding:7px 7px!important;
    font-size:12px!important;
    border-radius:11px!important;
    white-space:nowrap!important;
  }
  #inicio .rp-notification-confirm-btn svg,
  #inicio .rp-notification-profile-btn svg{
    width:14px!important;
    height:14px!important;
    min-width:14px!important;
  }
  #inicio .rp-notification-delete-form,
  #inicio .rp-icon-trash-btn{
    width:34px!important;
    min-width:34px!important;
    height:36px!important;
    min-height:36px!important;
  }
  #inicio .rp-icon-trash-btn svg{
    width:16px!important;
    height:16px!important;
  }
}

/* v332 - Notificaciones móvil: acciones completas sin cortes */
@media (max-width: 620px){
  #inicio .rp-dashboard-notifications-card{
    overflow:hidden!important;
  }
  #inicio .rp-dashboard-notifications-list{
    width:100%!important;
    max-width:100%!important;
    overflow-x:hidden!important;
    overflow-y:visible!important;
    padding-bottom:0!important;
  }
  #inicio .rp-dashboard-notification-item{
    display:grid!important;
    grid-template-columns:1fr!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    gap:8px!important;
    align-items:start!important;
    padding:14px 0!important;
    overflow:hidden!important;
  }
  #inicio .rp-dashboard-notification-main,
  #inicio .rp-dashboard-notification-meta,
  #inicio .rp-dashboard-notification-actions{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    overflow:visible!important;
  }
  #inicio .rp-dashboard-notification-main strong{
    font-size:17px!important;
    line-height:1.15!important;
  }
  #inicio .rp-notification-kind{
    font-size:12px!important;
    margin-bottom:2px!important;
  }
  #inicio .rp-dashboard-notification-meta{
    display:grid!important;
    gap:3px!important;
    font-size:13.5px!important;
    line-height:1.25!important;
  }
  #inicio .rp-dashboard-notification-actions{
    display:grid!important;
    grid-template-columns:minmax(0,1fr) minmax(0,1.08fr) 38px!important;
    gap:7px!important;
    margin-top:7px!important;
    align-items:center!important;
  }
  #inicio .rp-notification-confirm-form{
    width:100%!important;
    min-width:0!important;
  }
  #inicio .rp-notification-profile-btn,
  #inicio .rp-notification-confirm-btn{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    height:38px!important;
    min-height:38px!important;
    padding:7px 7px!important;
    border-radius:11px!important;
    font-size:12px!important;
    line-height:1!important;
    gap:5px!important;
    white-space:nowrap!important;
  }
  #inicio .rp-notification-confirm-btn{
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    border-color:#102A56!important;
    color:#fff!important;
  }
  #inicio .rp-notification-confirm-btn svg,
  #inicio .rp-notification-confirm-btn svg path{
    color:#fff!important;
    stroke:#fff!important;
  }
  #inicio .rp-notification-profile-btn svg,
  #inicio .rp-notification-confirm-btn svg{
    width:14px!important;
    height:14px!important;
    min-width:14px!important;
  }
  #inicio .rp-notification-delete-form,
  #inicio .rp-icon-trash-btn{
    width:38px!important;
    min-width:38px!important;
    max-width:38px!important;
    height:38px!important;
    min-height:38px!important;
  }
  #inicio .rp-icon-trash-btn{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    padding:0!important;
    background:#fff!important;
    color:#102A56!important;
    border:1px solid #D7DEE8!important;
  }
  #inicio .rp-icon-trash-btn svg{
    width:16px!important;
    height:16px!important;
  }
}

@media (max-width: 390px){
  #inicio .rp-dashboard-notification-actions{
    grid-template-columns:minmax(0,1fr) minmax(0,1fr) 36px!important;
    gap:6px!important;
  }
  #inicio .rp-notification-profile-btn,
  #inicio .rp-notification-confirm-btn{
    font-size:11.5px!important;
    padding-left:6px!important;
    padding-right:6px!important;
  }
  #inicio .rp-notification-delete-form,
  #inicio .rp-icon-trash-btn{
    width:36px!important;
    min-width:36px!important;
    max-width:36px!important;
  }
}

/* v333 - Notificaciones móvil: volver a formato compacto con scroll horizontal */
@media (max-width: 620px){
  #inicio .rp-dashboard-notifications-card{
    overflow:hidden!important;
  }
  #inicio .rp-dashboard-notifications-list{
    display:block!important;
    width:100%!important;
    max-width:100%!important;
    overflow-x:auto!important;
    overflow-y:visible!important;
    -webkit-overflow-scrolling:touch!important;
    padding-bottom:8px!important;
    scrollbar-width:thin!important;
  }
  #inicio .rp-dashboard-notification-item{
    display:grid!important;
    grid-template-columns:200px 245px 300px!important;
    gap:10px!important;
    width:765px!important;
    min-width:765px!important;
    max-width:none!important;
    align-items:center!important;
    padding:12px 0!important;
    overflow:visible!important;
    box-sizing:border-box!important;
  }
  #inicio .rp-dashboard-notification-main,
  #inicio .rp-dashboard-notification-meta,
  #inicio .rp-dashboard-notification-actions{
    width:auto!important;
    max-width:none!important;
    min-width:0!important;
    overflow:visible!important;
  }
  #inicio .rp-dashboard-notification-main strong{
    font-size:16px!important;
    line-height:1.14!important;
    white-space:normal!important;
  }
  #inicio .rp-notification-kind{
    font-size:12px!important;
    margin-bottom:3px!important;
    white-space:nowrap!important;
  }
  #inicio .rp-dashboard-notification-main span:not(.rp-notification-kind){
    font-size:12px!important;
    line-height:1.15!important;
  }
  #inicio .rp-dashboard-notification-meta{
    display:grid!important;
    gap:3px!important;
    font-size:13px!important;
    line-height:1.2!important;
  }
  #inicio .rp-dashboard-notification-meta > *{
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
  }
  #inicio .rp-dashboard-notification-actions{
    display:grid!important;
    grid-template-columns:92px 150px 38px!important;
    gap:7px!important;
    margin-top:0!important;
    align-items:center!important;
    justify-content:start!important;
  }
  #inicio .rp-notification-confirm-form,
  #inicio .rp-notification-delete-form{
    width:auto!important;
    min-width:0!important;
  }
  #inicio .rp-notification-profile-btn,
  #inicio .rp-notification-confirm-btn{
    width:100%!important;
    max-width:none!important;
    min-width:0!important;
    height:38px!important;
    min-height:38px!important;
    padding:7px 8px!important;
    border-radius:11px!important;
    font-size:12px!important;
    line-height:1!important;
    gap:5px!important;
    white-space:nowrap!important;
  }
  #inicio .rp-notification-confirm-btn{
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    border-color:#102A56!important;
    color:#fff!important;
  }
  #inicio .rp-notification-confirm-btn svg,
  #inicio .rp-notification-confirm-btn svg path{
    color:#fff!important;
    stroke:#fff!important;
  }
  #inicio .rp-notification-profile-btn svg,
  #inicio .rp-notification-confirm-btn svg{
    width:14px!important;
    height:14px!important;
    min-width:14px!important;
  }
  #inicio .rp-notification-delete-form,
  #inicio .rp-icon-trash-btn{
    width:38px!important;
    min-width:38px!important;
    max-width:38px!important;
    height:38px!important;
    min-height:38px!important;
  }
  #inicio .rp-icon-trash-btn{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    padding:0!important;
    background:#fff!important;
    color:#102A56!important;
    border:1px solid #D7DEE8!important;
  }
  #inicio .rp-icon-trash-btn svg{
    width:16px!important;
    height:16px!important;
  }
}


/* v334 - Próximo paciente: cards informativas blancas con iconos outline */
#inicio .rp-next-patient-info-grid > .rp-next-info-card,
#inicio .rp-next-patient-grid > .rp-next-info-card{
  background:#fff!important;
  border:1px solid #E4EAF2!important;
  border-radius:14px!important;
  color:#102A56!important;
  box-shadow:none!important;
  padding:12px 13px!important;
}
#inicio .rp-next-patient-info-grid > .rp-next-info-card small,
#inicio .rp-next-patient-grid > .rp-next-info-card small{
  display:flex!important;
  align-items:center!important;
  gap:6px!important;
  color:#102A56!important;
  font-size:12.5px!important;
  line-height:1.15!important;
  font-weight:400!important;
  margin-bottom:6px!important;
}
#inicio .rp-next-patient-info-grid > .rp-next-info-card strong,
#inicio .rp-next-patient-grid > .rp-next-info-card strong{
  color:#102A56!important;
  font-size:15px!important;
  line-height:1.25!important;
  font-weight:600!important;
}
#inicio .rp-next-info-icon{
  display:inline-flex!important;
  width:15px!important;
  height:15px!important;
  min-width:15px!important;
  align-items:center!important;
  justify-content:center!important;
  color:#102A56!important;
}
#inicio .rp-next-info-icon svg{
  width:15px!important;
  height:15px!important;
  display:block!important;
  stroke:currentColor!important;
  stroke-width:1.65!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
  fill:none!important;
}
#inicio .rp-next-info-icon svg *{
  stroke:currentColor!important;
  fill:none!important;
}
@media(max-width:620px){
  #inicio .rp-next-patient-info-grid > .rp-next-info-card,
  #inicio .rp-next-patient-grid > .rp-next-info-card{
    padding:13px 14px!important;
  }
}


/* v335 fix próximo paciente */
.rp-next-patient-grid>div,
.rp-next-patient-info-grid>.rp-next-info-card,
.rp-next-patient-grid>.rp-next-info-card{
background:#ffffff !important;
background-image:none !important;
border:1px solid #dfe6ee !important;
color:#102A56 !important;
box-shadow:none !important;
}
.rp-next-patient-grid>div small,
.rp-next-patient-grid>div strong{
color:#102A56 !important;
}
.rp-next-info-icon,
.rp-next-info-icon svg,
.rp-next-info-icon svg *{
color:#102A56 !important;
stroke:#102A56 !important;
fill:none !important;
}


/* v347 - Historial de sesiones y ficha paciente: corrección de raíz sin parches apilados */
.rp-modality-chip{display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:5px!important;white-space:nowrap!important;color:#344054!important;font-size:12px!important;font-weight:400!important;}
.rp-modality-icon{display:inline-flex!important;width:13px!important;height:13px!important;min-width:13px!important;color:#12326B!important;}
.rp-modality-icon svg{display:block!important;width:13px!important;height:13px!important;stroke:currentColor!important;fill:none!important;stroke-width:1.25!important;}

.rp-prof-panel table.rp-session-history-table{
  table-layout:fixed!important;
  width:100%!important;
  min-width:900px!important;
  border-collapse:separate!important;
  border-spacing:0!important;
}
.rp-prof-panel .rp-session-history-table th,
.rp-prof-panel .rp-session-history-table td{
  text-align:center!important;
  vertical-align:middle!important;
}
.rp-prof-panel .rp-session-history-table th:nth-child(1),
.rp-prof-panel .rp-session-history-table td:nth-child(1){width:9%!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(2),
.rp-prof-panel .rp-session-history-table td:nth-child(2){width:10%!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(3),
.rp-prof-panel .rp-session-history-table td:nth-child(3){width:13%!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(4),
.rp-prof-panel .rp-session-history-table td:nth-child(4){width:11%!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(5),
.rp-prof-panel .rp-session-history-table td:nth-child(5){width:10%!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(6),
.rp-prof-panel .rp-session-history-table td:nth-child(6){width:9%!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(7),
.rp-prof-panel .rp-session-history-table td:nth-child(7){width:13%!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(8),
.rp-prof-panel .rp-session-history-table td:nth-child(8){width:25%!important;min-width:220px!important;}

.rp-prof-panel .rp-session-history-table td.rp-history-actions{
  display:table-cell!important;
  text-align:center!important;
  vertical-align:middle!important;
  padding:6px 8px!important;
  overflow:visible!important;
}
.rp-prof-panel .rp-session-history-table .rp-session-actions-stack{
  display:flex!important;
  flex-direction:column!important;
  align-items:center!important;
  justify-content:center!important;
  gap:5px!important;
  width:100%!important;
  min-width:0!important;
  margin:0 auto!important;
}
.rp-prof-panel .rp-session-history-table .rp-session-actions-main{
  display:flex!important;
  flex-direction:row!important;
  align-items:center!important;
  justify-content:center!important;
  gap:6px!important;
  flex-wrap:nowrap!important;
  width:100%!important;
  margin:0!important;
}
.rp-prof-panel .rp-session-history-table .rp-inline-cancel-form,
.rp-prof-panel .rp-session-history-table .rp-inline-confirm-form{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  margin:0!important;
  width:auto!important;
  min-width:0!important;
  max-width:none!important;
  flex:0 0 auto!important;
}
.rp-prof-panel .rp-session-history-table .rp-history-actions .rp-mini-action{
  height:30px!important;
  min-height:30px!important;
  padding:0 8px!important;
  border-radius:9px!important;
  font-size:11px!important;
  line-height:1!important;
  font-weight:400!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:5px!important;
  white-space:nowrap!important;
  flex:0 0 auto!important;
  margin:0!important;
}
.rp-prof-panel .rp-session-history-table .rp-history-actions .rp-btn-svg,
.rp-prof-panel .rp-session-history-table .rp-history-actions svg{
  width:14px!important;
  height:14px!important;
  min-width:14px!important;
  flex:0 0 14px!important;
  margin:0!important;
  display:block!important;
}
.rp-prof-panel .rp-session-history-table .rp-history-actions .rp-confirm-pending-session{
  color:#12326B!important;
  border-color:#D7DEE8!important;
  background:#fff!important;
}
.rp-prof-panel .rp-session-history-table .rp-history-actions .rp-cancel-session{
  color:#9A3412!important;
  border-color:#FED7AA!important;
  background:#FFF7ED!important;
}
.rp-prof-panel .rp-session-history-table .rp-history-actions .rp-mini-action.is-disabled{opacity:.32!important;cursor:not-allowed!important;}

.rp-prof-panel table.rp-cancel-history-table{
  table-layout:fixed!important;
  width:100%!important;
  min-width:620px!important;
}
.rp-prof-panel .rp-cancel-history-table th,
.rp-prof-panel .rp-cancel-history-table td{text-align:center!important;vertical-align:middle!important;}
.rp-prof-panel .rp-cancel-history-table th:nth-child(1),
.rp-prof-panel .rp-cancel-history-table td:nth-child(1){width:24%!important;}
.rp-prof-panel .rp-cancel-history-table th:nth-child(2),
.rp-prof-panel .rp-cancel-history-table td:nth-child(2){width:30%!important;}
.rp-prof-panel .rp-cancel-history-table th:nth-child(3),
.rp-prof-panel .rp-cancel-history-table td:nth-child(3){width:22%!important;}
.rp-prof-panel .rp-cancel-history-table th:nth-child(4),
.rp-prof-panel .rp-cancel-history-table td:nth-child(4){width:24%!important;min-width:120px!important;}

.rp-prof-panel .rp-patient-schedule-card .rp-save-appointment-btn .rp-btn-svg,
.rp-prof-panel .rp-patient-schedule-card .rp-save-appointment-btn svg{
  color:#fff!important;
  stroke:#fff!important;
  fill:none!important;
}

@media(max-width:760px){
  .rp-prof-panel .rp-history-table-wrap{
    overflow-x:auto!important;
    overflow-y:hidden!important;
    -webkit-overflow-scrolling:touch!important;
  }
  .rp-prof-panel table.rp-session-history-table{
    min-width:760px!important;
  }
  #pacientes .rp-history-table-wrap{
    overflow-x:auto!important;
    overflow-y:hidden!important;
    -webkit-overflow-scrolling:touch!important;
  }
  #pacientes .rp-session-history-table th,
  #pacientes .rp-session-history-table td{
    height:42px!important;
    padding-top:4px!important;
    padding-bottom:4px!important;
    vertical-align:middle!important;
  }
  #pacientes .rp-session-history-table th:nth-child(8),
  #pacientes .rp-session-history-table td:nth-child(8){
    width:108px!important;
    min-width:108px!important;
    max-width:108px!important;
    padding:4px 5px!important;
    text-align:center!important;
    vertical-align:middle!important;
  }
  #pacientes .rp-session-history-table td.rp-history-actions{
    display:table-cell!important;
    height:42px!important;
    overflow:visible!important;
  }
  #pacientes .rp-session-history-table .rp-session-actions-stack{
    display:flex!important;
    flex-direction:row!important;
    gap:3px!important;
    align-items:center!important;
    justify-content:center!important;
    flex-wrap:nowrap!important;
    width:100%!important;
    height:100%!important;
    min-height:32px!important;
    margin:0!important;
  }
  #pacientes .rp-session-history-table .rp-session-actions-main{
    display:flex!important;
    flex-direction:row!important;
    gap:3px!important;
    align-items:center!important;
    justify-content:center!important;
    flex-wrap:nowrap!important;
    width:auto!important;
    flex:0 0 auto!important;
    margin:0!important;
  }
  #pacientes .rp-session-history-table .rp-inline-cancel-form,
  #pacientes .rp-session-history-table .rp-inline-confirm-form{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:26px!important;
    min-width:26px!important;
    max-width:26px!important;
    height:26px!important;
    margin:0!important;
    flex:0 0 26px!important;
  }
  #pacientes .rp-session-history-table .rp-history-actions .rp-mini-action{
    width:26px!important;
    min-width:26px!important;
    max-width:26px!important;
    height:26px!important;
    min-height:26px!important;
    max-height:26px!important;
    padding:0!important;
    border-radius:8px!important;
    font-size:0!important;
    gap:0!important;
    flex:0 0 26px!important;
    margin:0!important;
  }
  #pacientes .rp-session-history-table .rp-history-actions .rp-btn-svg,
  #pacientes .rp-session-history-table .rp-history-actions svg{
    width:13px!important;
    height:13px!important;
    min-width:13px!important;
    flex:0 0 13px!important;
  }
  .rp-prof-panel .rp-patient-schedule-card .rp-save-appointment-btn{
    grid-column:1 / -1!important;
    width:100%!important;
    max-width:100%!important;
    min-height:50px!important;
    padding:12px 16px!important;
    border-radius:12px!important;
    font-size:15px!important;
    font-weight:400!important;
    line-height:1.15!important;
    gap:8px!important;
    white-space:normal!important;
    text-align:center!important;
  }
}

/* v351 - ficha paciente: acciones cabecera limpias */
.rp-patient-detail-screen .rp-detail-actions .rp-btn,
.rp-patient-detail-screen .rp-detail-actions button,
.rp-patient-detail-screen .rp-detail-actions a{
  box-shadow:none!important;
  filter:none!important;
}
.rp-patient-detail-screen .rp-detail-actions .rp-btn-warning{
  background:#fff7ed!important;
  color:#9a3412!important;
  border:0!important;
  box-shadow:none!important;
  filter:none!important;
  font-weight:400!important;
}
.rp-patient-detail-screen .rp-detail-actions .rp-btn-warning svg{
  stroke:currentColor!important;
  fill:none!important;
}

/* v352 - Historial de pagos: modalidad, asistencia y condonar en tabla rápida */
.rp-prof-panel .rp-payment-quick-table-head,
.rp-prof-panel .rp-payment-row{
  grid-template-columns:minmax(190px,1.3fr) minmax(95px,.55fr) minmax(105px,.6fr) minmax(155px,.8fr) minmax(240px,1fr)!important;
}
.rp-prof-panel .rp-payment-row .rp-payment-modality,
.rp-prof-panel .rp-payment-row .rp-payment-attendance{
  font-size:13px!important;
  color:#253142!important;
  font-weight:400!important;
}
.rp-prof-panel .rp-payment-row .rp-payment-actions{
  display:flex!important;
  flex-wrap:wrap!important;
  align-items:center!important;
  justify-content:flex-end!important;
  gap:8px!important;
}
.rp-prof-panel .rp-payment-row .rp-payment-actions .rp-inline-form{
  margin:0!important;
}
@media (max-width: 760px){
  .rp-prof-panel .rp-payment-row{
    grid-template-columns:1fr!important;
  }
  .rp-prof-panel .rp-payment-row .rp-payment-modality::before{content:'Modalidad: ';font-weight:600;color:#102A56;}
  .rp-prof-panel .rp-payment-row .rp-payment-attendance::before{content:'Asistencia: ';font-weight:600;color:#102A56;}
  .rp-prof-panel .rp-payment-row .rp-payment-actions{
    justify-content:flex-start!important;
  }
}

/* v356 - pagos y mora: acciones seleccionadas arriba de tabla y deuda anterior separada */
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-selected-actions{
  display:flex!important;
  align-items:center!important;
  gap:10px!important;
  flex-wrap:wrap!important;
  margin:14px 0 12px!important;
}
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-selected-actions .rp-btn{
  min-height:36px!important;
  padding:0 14px!important;
  border-radius:10px!important;
  font-weight:400!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-selected-actions .rp-btn svg{
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.35!important;
}
.rp-prof-panel .rp-payment-history-debt-card .rp-debt-selected-actions small{
  color:#667085!important;
  font-size:12px!important;
}
.rp-prof-panel .rp-debt-tools-single{
  display:block!important;
  max-width:760px!important;
}
.rp-prof-panel .rp-debt-tools-single .rp-previous-debt-form{
  width:100%!important;
}
.rp-prof-panel .rp-debt-tools-single .rp-previous-debt-form h4{
  color:#1f2937!important;
  font-size:18px!important;
  font-weight:500!important;
  margin:0 0 12px!important;
}


/* v359 - separación real de historial de pagos/deuda y deuda manual */
.rp-payment-summary-row-clean{align-items:center;gap:14px}
.rp-debt-box-smart{display:flex;align-items:center;gap:8px;background:#fff!important;border:1px solid #d8e1ec!important;border-radius:14px!important;padding:12px 14px!important;box-shadow:none!important;font-weight:400!important;color:#102A56}
.rp-debt-box-smart strong{font-weight:400!important}
.rp-debt-box-smart span{font-weight:400!important}
.rp-debt-box-smart.is-debt{border-color:#f2c6c6!important;color:#9b1c1c}
.rp-debt-box-smart.is-debt .rp-debt-box-icon{color:#9b1c1c}
.rp-debt-box-smart.is-ok{border-color:#bfe8cf!important;color:#166534}
.rp-debt-box-smart.is-empty{border-color:#d8e1ec!important;color:#667085}
.rp-payment-filter-chips{display:flex;gap:8px;flex-wrap:wrap;margin:12px 0}
.rp-payment-filter-chips button{border:1px solid #d8e1ec;background:#fff;color:#102A56;border-radius:999px;padding:7px 13px;font-weight:400;cursor:pointer}
.rp-payment-filter-chips button.is-active{background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%);color:#fff;border-color:#102A56}
.rp-debt-selected-actions-main{display:flex;gap:10px;flex-wrap:wrap;margin:8px 0 12px}
.rp-payment-quick-table-head-select,.rp-payment-row-selectable{grid-template-columns:70px minmax(220px,1.5fr) minmax(110px,.8fr) minmax(120px,.9fr) minmax(160px,1fr) minmax(230px,1.1fr)!important}
.rp-payment-select{display:flex;align-items:center;justify-content:center}
.rp-payment-select input{width:17px;height:17px}
.rp-manual-debt-only-card .rp-debt-selected-actions,
.rp-manual-debt-only-card .rp-debt-responsive-table,
.rp-manual-debt-only-card .rp-debt-total-pill{display:none!important}
.rp-manual-debt-form{max-width:760px}
.rp-manual-debt-form button{width:max-content}
@media(max-width:760px){
  .rp-payment-quick-table-head-select,.rp-payment-row-selectable{min-width:980px}
  .rp-payment-filter-chips{overflow-x:auto;flex-wrap:nowrap;padding-bottom:4px}
  .rp-debt-selected-actions-main .rp-btn{white-space:nowrap}
}


/* v360 - Historial de pagos/deuda: tabla y resumen corregidos desde la estructura real */
.rp-prof-panel .rp-payment-summary-row-clean{
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:16px!important;
  flex-wrap:wrap!important;
  margin:14px 0 12px!important;
}
.rp-prof-panel .rp-debt-box.rp-debt-box-smart{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:9px!important;
  width:auto!important;
  max-width:100%!important;
  min-height:46px!important;
  margin:0!important;
  padding:10px 14px!important;
  background:#fff!important;
  border:1px solid #d8e1ec!important;
  border-radius:14px!important;
  box-shadow:none!important;
  font-weight:400!important;
  line-height:1.2!important;
}
.rp-prof-panel .rp-debt-box.rp-debt-box-smart .rp-debt-box-icon{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  flex:0 0 auto!important;
}
.rp-prof-panel .rp-debt-box.rp-debt-box-smart strong,
.rp-prof-panel .rp-debt-box.rp-debt-box-smart span{
  font-size:14px!important;
  font-weight:400!important;
  line-height:1.2!important;
  margin:0!important;
}
.rp-prof-panel .rp-debt-box.rp-debt-box-smart > span:not(.rp-debt-box-icon){
  font-size:22px!important;
  font-weight:400!important;
  margin-left:2px!important;
}
.rp-prof-panel .rp-debt-box.rp-debt-box-smart.is-debt{
  border-color:#e3a7a7!important;
  color:#9b1c1c!important;
}
.rp-prof-panel .rp-debt-box.rp-debt-box-smart.is-credit{
  border-color:#9fd8b4!important;
  color:#15803d!important;
}
.rp-prof-panel .rp-debt-box.rp-debt-box-smart.is-empty{
  border-color:#d8e1ec!important;
  color:#667085!important;
}

.rp-prof-panel .rp-payment-filter-chips{
  display:flex!important;
  flex-wrap:wrap!important;
  gap:8px!important;
  margin:10px 0 12px!important;
}
.rp-prof-panel .rp-payment-filter-chips button{
  appearance:none!important;
  border:1px solid #d8e1ec!important;
  background:#fff!important;
  color:#102A56!important;
  border-radius:999px!important;
  padding:7px 13px!important;
  font-size:13px!important;
  font-weight:400!important;
  line-height:1!important;
  cursor:pointer!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-payment-filter-chips button.is-active{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  border-color:#102A56!important;
  color:#fff!important;
}

.rp-prof-panel .rp-debt-selected-actions-main{
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:10px!important;
  flex-wrap:wrap!important;
  margin:8px 0 14px!important;
}
.rp-prof-panel .rp-debt-selected-actions-main .rp-btn{
  box-shadow:none!important;
  font-weight:400!important;
}

/* La tabla principal no debe heredar flex de .rp-mini-row */
.rp-prof-panel .rp-payment-quick-table-head-select,
.rp-prof-panel .rp-payment-row-selectable{
  display:grid!important;
  grid-template-columns:64px minmax(210px,1.45fr) minmax(100px,.75fr) minmax(110px,.8fr) minmax(155px,1fr) minmax(210px,1.05fr)!important;
  align-items:center!important;
  column-gap:0!important;
  width:100%!important;
  min-width:920px!important;
  box-sizing:border-box!important;
}
.rp-prof-panel .rp-payment-quick-table-head-select{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  border-radius:12px 12px 0 0!important;
  overflow:hidden!important;
}
.rp-prof-panel .rp-payment-quick-table-head-select span{
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  min-height:46px!important;
  padding:10px 14px!important;
  color:#fff!important;
  font-size:13px!important;
  font-weight:400!important;
  line-height:1.2!important;
  text-transform:uppercase!important;
  letter-spacing:.02em!important;
  border-right:1px solid rgba(255,255,255,.12)!important;
}
.rp-prof-panel .rp-payment-quick-table-head-select span:last-child{border-right:0!important}

.rp-prof-panel .rp-payment-row-selectable{
  border-bottom:1px solid #edf1f5!important;
  padding:0!important;
  margin:0!important;
  gap:0!important;
  background:#fff!important;
}
.rp-prof-panel .rp-payment-row-selectable > span,
.rp-prof-panel .rp-payment-row-selectable > em,
.rp-prof-panel .rp-payment-row-selectable > div{
  min-height:64px!important;
  padding:10px 14px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  box-sizing:border-box!important;
  border-right:1px solid #eef2f6!important;
  color:#1f2937!important;
  font-size:14px!important;
  font-weight:400!important;
  line-height:1.35!important;
}
.rp-prof-panel .rp-payment-row-selectable > span:last-child,
.rp-prof-panel .rp-payment-row-selectable > em:last-child,
.rp-prof-panel .rp-payment-row-selectable > div:last-child{border-right:0!important}
.rp-prof-panel .rp-payment-row-selectable .rp-payment-select{
  justify-content:center!important;
}
.rp-prof-panel .rp-payment-row-selectable small{
  display:block!important;
  margin-top:3px!important;
  color:#667085!important;
  font-size:12px!important;
  font-weight:400!important;
}
.rp-prof-panel .rp-payment-row-selectable em{
  font-style:normal!important;
  text-align:left!important;
  color:#1f2937!important;
}
.rp-prof-panel .rp-payment-row-selectable .rp-payment-actions{
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:8px!important;
  flex-wrap:wrap!important;
  width:auto!important;
}
.rp-prof-panel .rp-payment-row-selectable .rp-payment-actions form{
  margin:0!important;
  padding:0!important;
  display:inline-flex!important;
}
.rp-prof-panel .rp-payment-row-selectable .rp-mini-action{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:6px!important;
  min-height:34px!important;
  height:34px!important;
  width:auto!important;
  padding:0 10px!important;
  border-radius:10px!important;
  font-size:12px!important;
  font-weight:400!important;
  line-height:1!important;
  white-space:nowrap!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-payment-row-selectable .rp-mini-action .rp-btn-svg{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:14px!important;
  height:14px!important;
  flex:0 0 14px!important;
}
.rp-prof-panel .rp-payment-row-selectable .rp-mini-action .rp-btn-svg svg{
  width:14px!important;
  height:14px!important;
  stroke:currentColor!important;
  fill:none!important;
}

/* Deuda manual: formulario puro, sin tabla vieja ni resumen */
.rp-prof-panel .rp-manual-debt-only-card .rp-debt-selected-actions,
.rp-prof-panel .rp-manual-debt-only-card .rp-debt-responsive-table,
.rp-prof-panel .rp-manual-debt-only-card .rp-debt-total-pill,
.rp-prof-panel .rp-manual-debt-only-card .rp-debt-email-form,
.rp-prof-panel .rp-manual-debt-only-card .rp-debt-table-title{
  display:none!important;
}
.rp-prof-panel .rp-manual-debt-only-card{
  background:#fff!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-manual-debt-form{
  max-width:760px!important;
  margin-top:18px!important;
}
.rp-prof-panel .rp-manual-debt-form button{
  width:max-content!important;
  box-shadow:none!important;
  font-weight:400!important;
}

@media(max-width:760px){
  .rp-prof-panel .rp-payment-summary-row-clean{
    align-items:flex-start!important;
  }
  .rp-prof-panel .rp-payment-quick-table-head-select,
  .rp-prof-panel .rp-payment-row-selectable{
    min-width:920px!important;
  }
  .rp-prof-panel .rp-responsive-table,
  .rp-prof-panel .rp-debt-responsive-table{
    overflow-x:auto!important;
    -webkit-overflow-scrolling:touch!important;
  }
  .rp-prof-panel .rp-payment-filter-chips{
    overflow-x:auto!important;
    flex-wrap:nowrap!important;
    padding-bottom:4px!important;
  }
  .rp-prof-panel .rp-payment-filter-chips button{
    flex:0 0 auto!important;
  }
}


/* v361 - Historial de pagos/deuda: corregir ancho real, alineación y filtros */
.rp-prof-panel .rp-detail-columns > .rp-payments-quick-card,
.rp-prof-panel section.rp-payments-quick-card{
  grid-column:1 / -1 !important;
  width:100% !important;
  max-width:100% !important;
  box-sizing:border-box !important;
  overflow:visible !important;
}
.rp-prof-panel .rp-payments-quick-card .rp-payment-summary-row-clean{
  width:100% !important;
  display:flex !important;
  justify-content:space-between !important;
  align-items:flex-start !important;
  gap:16px !important;
}
.rp-prof-panel .rp-payments-quick-card .rp-debt-box-smart{
  width:auto !important;
  min-width:0 !important;
  max-width:calc(100vw - 8px) !important;
  background:#fff !important;
  border:1px solid #d8e1ec !important;
  border-radius:14px !important;
  box-shadow:none !important;
}
.rp-prof-panel .rp-payments-quick-card .rp-payment-table-scroll{
  width:100% !important;
  overflow-x:auto !important;
  -webkit-overflow-scrolling:touch !important;
}
.rp-prof-panel .rp-payments-quick-card .rp-payment-quick-table-head-select,
.rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable{
  display:grid !important;
  grid-template-columns:72px minmax(260px,1.7fr) minmax(130px,.75fr) minmax(135px,.8fr) minmax(185px,1fr) minmax(230px,1fr) !important;
  width:100% !important;
  min-width:1120px !important;
  max-width:none !important;
  margin:0 !important;
  box-sizing:border-box !important;
}
.rp-prof-panel .rp-payments-quick-card .rp-payment-quick-table-head-select{
  border-radius:12px 12px 0 0 !important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%) !important;
  overflow:hidden !important;
}
.rp-prof-panel .rp-payments-quick-card .rp-payment-quick-table-head-select span{
  min-height:46px !important;
  padding:11px 14px !important;
  display:flex !important;
  align-items:center !important;
  justify-content:flex-start !important;
  color:#fff !important;
  font-weight:400 !important;
  font-size:13px !important;
  line-height:1.2 !important;
  text-transform:uppercase !important;
  border-right:1px solid rgba(255,255,255,.14) !important;
}
.rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable{
  background:#fff !important;
  border:0 !important;
  border-bottom:1px solid #e7edf4 !important;
  padding:0 !important;
  gap:0 !important;
}
.rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > span,
.rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > em,
.rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > div{
  min-height:68px !important;
  padding:12px 14px !important;
  display:flex !important;
  align-items:center !important;
  justify-content:flex-start !important;
  border-right:1px solid #edf2f7 !important;
  box-sizing:border-box !important;
  color:#1f2937 !important;
  font-size:14px !important;
  font-weight:400 !important;
  line-height:1.35 !important;
}
.rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > .rp-payment-select{justify-content:center !important;}
.rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable small{display:block !important;margin-top:3px !important;color:#667085 !important;font-size:12px !important;font-weight:400 !important;}
.rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable em{font-style:normal !important;}
.rp-prof-panel .rp-payments-quick-card .rp-payment-actions{
  display:flex !important;
  align-items:center !important;
  justify-content:flex-start !important;
  gap:8px !important;
  flex-wrap:wrap !important;
  width:100% !important;
}
.rp-prof-panel .rp-payments-quick-card .rp-payment-actions form{margin:0 !important;display:inline-flex !important;}
.rp-prof-panel .rp-payments-quick-card .rp-payment-actions .rp-mini-action{height:34px !important;min-height:34px !important;padding:0 10px !important;border-radius:10px !important;font-size:12px !important;font-weight:400 !important;white-space:nowrap !important;box-shadow:none !important;}
.rp-prof-panel .rp-payment-filter-chips button{font-weight:400 !important;}
.rp-prof-panel .rp-payment-row-selectable.rp-payment-filter-hidden{display:none !important;}
@media(max-width:760px){
  .rp-prof-panel .rp-payments-quick-card .rp-payment-summary-row-clean{display:block !important;}
  .rp-prof-panel .rp-payments-quick-card .rp-payment-table-scroll{overflow-x:auto !important;}
  .rp-prof-panel .rp-payments-quick-card .rp-payment-quick-table-head-select,
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable{min-width:1080px !important;}
}

/* v365-fix-compact-payments-subpage: pagos/deuda oculto en ficha y tabla compacta desktop */
.rp-prof-panel .rp-patient-detail-screen:not(.rp-patient-subpage-mode) .rp-payments-quick-card.rp-patient-subpage-card{
  display:none !important;
}
.rp-prof-panel .rp-patient-subpage-mode .rp-payments-quick-card.rp-patient-subpage-card.active{
  display:block !important;
}
@media(min-width:761px){
  .rp-prof-panel .rp-payments-quick-card{
    padding:16px !important;
    border-radius:16px !important;
  }
  .rp-prof-panel .rp-payments-quick-card h3{
    font-size:18px !important;
    margin:0 0 10px !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-summary-row-clean{
    gap:10px !important;
    margin-bottom:10px !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-debt-box-smart{
    max-width:320px !important;
    padding:10px 12px !important;
    border-radius:10px !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-debt-box-smart strong{
    font-size:13px !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-debt-box-smart span,
  .rp-prof-panel .rp-payments-quick-card .rp-debt-box-smart em{
    font-size:12px !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-table-scroll{
    overflow-x:visible !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-quick-table-head-select,
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable{
    grid-template-columns:42px minmax(170px,1.55fr) minmax(90px,.65fr) minmax(95px,.7fr) minmax(125px,.85fr) minmax(145px,.9fr) !important;
    min-width:0 !important;
    width:100% !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-quick-table-head-select span{
    min-height:34px !important;
    padding:8px 9px !important;
    font-size:11px !important;
    letter-spacing:.01em !important;
    line-height:1.1 !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > span,
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > em,
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > div{
    min-height:48px !important;
    padding:8px 9px !important;
    font-size:12px !important;
    line-height:1.2 !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable small{
    margin-top:2px !important;
    font-size:11px !important;
    line-height:1.15 !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-actions{
    gap:5px !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-actions .rp-mini-action{
    height:27px !important;
    min-height:27px !important;
    padding:0 7px !important;
    border-radius:8px !important;
    font-size:11px !important;
    gap:4px !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-actions .rp-btn-svg svg,
  .rp-prof-panel .rp-payments-quick-card .rp-payment-actions svg{
    width:12px !important;
    height:12px !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-filter-chips{
    gap:6px !important;
    margin:8px 0 !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-filter-chips button,
  .rp-prof-panel .rp-payments-quick-card .rp-debt-selected-actions .rp-btn,
  .rp-prof-panel .rp-payments-quick-card .rp-open-payments-patient{
    min-height:29px !important;
    padding:6px 9px !important;
    font-size:11px !important;
    border-radius:8px !important;
  }
}

/* v366.1: ajuste fino tabla Historial de pagos / deuda */
@media(min-width:761px){
  .rp-prof-panel .rp-payments-quick-card .rp-payment-table-scroll{
    overflow-x:visible !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-quick-table-head-select,
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable{
    grid-template-columns:42px minmax(230px,1.75fr) minmax(78px,.5fr) minmax(88px,.55fr) minmax(132px,.8fr) minmax(210px,1fr) !important;
    min-width:0 !important;
    width:100% !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-quick-table-head-select span{
    justify-content:center !important;
    text-align:center !important;
    min-height:34px !important;
    padding:7px 6px !important;
    font-size:11px !important;
    line-height:1.1 !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > span,
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > em,
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > div{
    justify-content:center !important;
    text-align:center !important;
    min-height:42px !important;
    padding:7px 6px !important;
    font-size:12px !important;
    line-height:1.18 !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > span:nth-child(2){
    flex-direction:column !important;
    align-items:center !important;
    gap:4px !important;
    white-space:normal !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > span:nth-child(2) small{
    display:block !important;
    margin-top:0 !important;
    line-height:1.15 !important;
    max-width:100% !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-modality,
  .rp-prof-panel .rp-payments-quick-card .rp-payment-attendance{
    padding-left:4px !important;
    padding-right:4px !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable em{
    justify-content:center !important;
    text-align:center !important;
    white-space:nowrap !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-actions{
    justify-content:center !important;
    flex-wrap:nowrap !important;
    gap:5px !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-actions form{
    flex:0 0 auto !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-actions .rp-mini-action{
    height:27px !important;
    min-height:27px !important;
    padding:0 7px !important;
    font-size:10.5px !important;
    border-radius:8px !important;
    gap:3px !important;
    white-space:nowrap !important;
  }
}

/* v366.2: iconos finos en modalidad y facturación pendiente al marcar pagado */
.rp-prof-panel .rp-payments-quick-card .rp-modality-inline{
  display:inline-flex !important;
  align-items:center !important;
  justify-content:center !important;
  gap:4px !important;
  line-height:1 !important;
  white-space:nowrap !important;
}
.rp-prof-panel .rp-payments-quick-card .rp-modality-inline svg{
  width:1em !important;
  height:1em !important;
  min-width:1em !important;
  fill:none !important;
  stroke:currentColor !important;
  stroke-width:1.15 !important;
  stroke-linecap:round !important;
  stroke-linejoin:round !important;
  display:block !important;
}
@media(min-width:761px){
  .rp-prof-panel .rp-payments-quick-card .rp-payment-modality{
    justify-content:center !important;
    text-align:center !important;
  }
}

/* v366.8 - Dashboard: desplegable Turnos del día debajo de Próximo paciente */
.rp-prof-panel #inicio .rp-today-turns-card{
  padding:0!important;
  overflow:hidden!important;
  margin:12px 0 18px!important;
  border-radius:14px!important;
  border:1px solid #102A56!important;
  background:#fff!important;
}
.rp-prof-panel #inicio .rp-today-turns-summary{
  list-style:none!important;
  cursor:pointer!important;
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:10px!important;
  min-height:40px!important;
  padding:9px 12px!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  font-weight:400!important;
  font-size:13px!important;
  line-height:1.15!important;
}
.rp-prof-panel #inicio .rp-today-turns-summary::-webkit-details-marker{display:none!important;}
.rp-prof-panel #inicio .rp-today-turns-title{display:inline-flex!important;align-items:center!important;gap:8px!important;color:#fff!important;font-size:13px!important;font-weight:400!important;}
.rp-prof-panel #inicio .rp-today-turns-icon,
.rp-prof-panel #inicio .rp-today-turns-caret{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  color:#fff!important;
  flex:0 0 auto!important;
}
.rp-prof-panel #inicio .rp-today-turns-icon svg{width:17px!important;height:17px!important;fill:none!important;stroke:currentColor!important;stroke-width:1.35!important;stroke-linecap:round!important;stroke-linejoin:round!important;}
.rp-prof-panel #inicio .rp-today-turns-caret svg{width:16px!important;height:16px!important;fill:none!important;stroke:currentColor!important;stroke-width:1.45!important;stroke-linecap:round!important;stroke-linejoin:round!important;transition:transform .18s ease!important;}
.rp-prof-panel #inicio .rp-today-turns-card[open] .rp-today-turns-caret svg{transform:rotate(180deg)!important;}
.rp-prof-panel #inicio .rp-today-turns-count{
  margin-left:auto!important;
  min-width:23px!important;
  height:20px!important;
  padding:0 7px!important;
  border-radius:999px!important;
  background:rgba(255,255,255,.18)!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  color:#fff!important;
  font-size:11px!important;
  font-weight:400!important;
}
.rp-prof-panel #inicio .rp-today-turns-body{padding:10px 12px 12px!important;background:#fff!important;}
.rp-prof-panel #inicio .rp-today-turns-table-wrap{overflow:auto!important;}
.rp-prof-panel #inicio .rp-today-turns-table{width:100%!important;border-collapse:collapse!important;min-width:620px!important;font-size:12px!important;font-weight:400!important;}
.rp-prof-panel #inicio .rp-today-turns-table th{background:#fff!important;color:#102A56!important;text-align:center!important;font-size:10px!important;text-transform:uppercase!important;letter-spacing:.025em!important;font-weight:400!important;padding:7px 6px!important;border-bottom:1px solid #e5e7eb!important;line-height:1.15!important;}
.rp-prof-panel #inicio .rp-today-turns-table td{padding:7px 6px!important;border-bottom:1px solid #edf3f7!important;text-align:center!important;vertical-align:middle!important;color:#17324d!important;font-size:12px!important;font-weight:400!important;line-height:1.15!important;}
.rp-prof-panel #inicio .rp-today-turns-table td strong{font-weight:400!important;font-size:12px!important;}
.rp-prof-panel #inicio .rp-today-turns-table tbody tr:last-child td{border-bottom:0!important;}
.rp-prof-panel #inicio .rp-today-turns-table td:nth-child(3){text-align:center!important;font-weight:400!important;}
.rp-prof-panel #inicio .rp-today-turns-table .rp-modality-inline{justify-content:center!important;color:#17324d!important;font-weight:400!important;font-size:12px!important;}
.rp-prof-panel #inicio .rp-today-turns-table .rp-modality-inline svg{width:13px!important;height:13px!important;fill:none!important;stroke:currentColor!important;stroke-width:1.25!important;}
.rp-prof-panel #inicio .rp-today-payment-badge{display:inline-flex!important;align-items:center!important;justify-content:center!important;min-width:76px!important;border-radius:999px!important;padding:4px 7px!important;font-size:11px!important;font-weight:400!important;line-height:1!important;background:#eef2f7!important;color:#475569!important;}
.rp-prof-panel #inicio .rp-today-payment-badge.is-paid{background:#e8f8ef!important;color:#24623b!important;}
.rp-prof-panel #inicio .rp-today-payment-badge.is-pending{background:#fff7ed!important;color:#9a3412!important;}
.rp-prof-panel #inicio .rp-today-payment-badge.is-condoned{background:#eef8fc!important;color:#075b82!important;}
.rp-prof-panel #inicio .rp-today-turns-empty{margin:0!important;text-align:center!important;padding:7px!important;font-size:12px!important;font-weight:400!important;}
@media(max-width:720px){
  .rp-prof-panel #inicio .rp-today-turns-summary{font-size:12px!important;padding:8px 10px!important;font-weight:400!important;}
  .rp-prof-panel #inicio .rp-today-turns-title{font-size:12px!important;font-weight:400!important;}
  .rp-prof-panel #inicio .rp-today-turns-body{padding:10px!important;}
  .rp-prof-panel #inicio .rp-today-turns-table{min-width:560px!important;font-size:11px!important;}
}

/* v366.10 - Próximo paciente: contador con tarjeta blanca y temporizador azul */
#inicio .rp-next-dashboard-card .rp-next-countdown,
#inicio .rp-next-countdown{
  background:#ffffff!important;
  background-image:none!important;
  border:1px solid #102A56!important;
  color:#102A56!important;
  box-shadow:none!important;
}
#inicio .rp-next-dashboard-card .rp-next-countdown small,
#inicio .rp-next-dashboard-card .rp-next-countdown span,
#inicio .rp-next-countdown small,
#inicio .rp-next-countdown span{
  color:#102A56!important;
  opacity:1!important;
  font-weight:400!important;
}
#inicio .rp-next-dashboard-card .rp-next-countdown strong,
#inicio .rp-next-countdown strong{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  background-image:none!important;
  border:1px solid #102A56!important;
  color:#ffffff!important;
  box-shadow:none!important;
  font-weight:400!important;
}

/* v366.19 - acciones separadas para guardar turno con/sin aviso */
.rp-appointment-actions{display:flex;gap:10px;align-items:center;justify-content:flex-end;flex-wrap:wrap}
.rp-check-inline{display:flex!important;align-items:center!important;gap:9px!important;flex-direction:row!important;font-weight:700!important}
.rp-check-inline input[type="checkbox"]{width:auto!important;min-width:16px!important;height:16px!important;margin:0!important}
@media(max-width:640px){.rp-appointment-actions{justify-content:stretch}.rp-appointment-actions .rp-btn{width:100%;justify-content:center}}

/* v366.21: acciones de guardado de turno alineadas y visibles */
.rp-appointment-actions{display:flex;gap:10px;align-items:center;justify-content:flex-start;flex-wrap:wrap}
.rp-appointment-actions .rp-btn{min-height:48px}
@media(max-width:640px){.rp-appointment-actions{justify-content:stretch}.rp-appointment-actions .rp-btn{width:100%;justify-content:center}}

/* v366.22 - botón Guardar calendario sin avisos blanco/azul */
.rp-appointment-actions .rp-save-appointment-no-notify,
.rp-appointment-actions button[name="notify_patient"][value="0"]{
  background:#ffffff!important;
  background-image:none!important;
  color:#102A56!important;
  border:1px solid #102A56!important;
  box-shadow:none!important;
}
.rp-appointment-actions .rp-save-appointment-no-notify .rp-btn-svg,
.rp-appointment-actions button[name="notify_patient"][value="0"] .rp-btn-svg{
  color:#102A56!important;
}
.rp-appointment-actions .rp-save-appointment-no-notify svg,
.rp-appointment-actions button[name="notify_patient"][value="0"] svg{
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.45!important;
}
.rp-appointment-actions .rp-save-appointment-no-notify:hover,
.rp-appointment-actions button[name="notify_patient"][value="0"]:hover{
  background:#f8fbff!important;
  color:#102A56!important;
  border-color:#102A56!important;
}

/* RedPsico v366.23 - destacar opción de emails/recordatorios sin precio */
.rp-hide-price-email-box{
    grid-column:1 / -1!important;
    display:flex!important;
    align-items:center!important;
    gap:10px!important;
    width:100%!important;
    box-sizing:border-box!important;
    margin:4px 0 8px!important;
    padding:13px 15px!important;
    background:#fff!important;
    border:1.5px solid #1f4f7a!important;
    border-radius:14px!important;
    color:#183b5f!important;
    font-weight:700!important;
    line-height:1.35!important;
}
.rp-hide-price-email-box input[type="checkbox"]{
    width:20px!important;
    min-width:20px!important;
    height:20px!important;
    margin:0!important;
    accent-color:#1f4f7a!important;
}

/* v366.30 - Historias Clínicas: detalle en popup, sin desplegable que rompa columnas */
html.rp-history-detail-popup-open,
html.rp-history-detail-popup-open body{
  overflow:hidden!important;
}
.rp-prof-panel .rp-history-table-wrap{
  width:100%!important;
  overflow-x:visible!important;
}
.rp-prof-panel .rp-history-records-table{
  width:100%!important;
  table-layout:fixed!important;
}
.rp-prof-panel .rp-history-records-table th:nth-child(1),
.rp-prof-panel .rp-history-records-table td:nth-child(1){width:130px!important;}
.rp-prof-panel .rp-history-records-table th:nth-child(2),
.rp-prof-panel .rp-history-records-table td:nth-child(2){width:100px!important;}
.rp-prof-panel .rp-history-records-table th:nth-child(4),
.rp-prof-panel .rp-history-records-table td:nth-child(4){width:330px!important;}
.rp-prof-panel .rp-history-records-table td,
.rp-prof-panel .rp-history-records-table th{
  white-space:normal!important;
  overflow-wrap:anywhere!important;
}
.rp-prof-panel .rp-history-row-actions{
  justify-content:flex-end!important;
  gap:8px!important;
  flex-wrap:nowrap!important;
}
.rp-history-detail-modal[hidden]{display:none!important;}
.rp-history-detail-modal{
  position:fixed!important;
  inset:0!important;
  z-index:999999!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  padding:24px!important;
}
.rp-history-detail-backdrop{
  position:absolute!important;
  inset:0!important;
  background:rgba(15,23,42,.42)!important;
  backdrop-filter:blur(3px)!important;
}
.rp-history-detail-dialog{
  position:relative!important;
  z-index:1!important;
  width:min(760px, calc(100vw - 32px))!important;
  max-height:calc(100vh - 48px)!important;
  overflow:auto!important;
  background:#fff!important;
  border:1px solid rgba(16,42,86,.14)!important;
  border-radius:22px!important;
  box-shadow:0 24px 70px rgba(15,23,42,.22)!important;
  padding:24px!important;
  color:#102A56!important;
}
.rp-history-detail-dialog h3{
  margin:0 38px 14px 0!important;
  display:flex!important;
  align-items:center!important;
  gap:10px!important;
  color:#102A56!important;
  font-size:22px!important;
  font-weight:800!important;
}
.rp-history-detail-close{
  position:absolute!important;
  top:14px!important;
  right:14px!important;
  width:36px!important;
  height:36px!important;
  border-radius:50%!important;
  border:1px solid rgba(16,42,86,.18)!important;
  background:#fff!important;
  color:#102A56!important;
  font-size:24px!important;
  line-height:1!important;
  cursor:pointer!important;
}
.rp-history-detail-meta{
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:12px!important;
  background:#f8fafc!important;
  border:1px solid #e5e7eb!important;
  border-radius:14px!important;
  padding:12px 14px!important;
  margin-bottom:16px!important;
  color:#102A56!important;
}
.rp-history-detail-grid-modal{
  display:grid!important;
  grid-template-columns:1fr!important;
  gap:14px!important;
}
.rp-history-detail-grid-modal > div{
  border:1px solid #e5e7eb!important;
  border-radius:16px!important;
  padding:14px!important;
  background:#fff!important;
}
.rp-history-detail-grid-modal h4{
  margin:0 0 8px!important;
  color:#102A56!important;
  font-size:15px!important;
  font-weight:800!important;
}
.rp-history-detail-grid-modal p{
  margin:0!important;
  color:#334155!important;
  line-height:1.55!important;
  white-space:normal!important;
}
.rp-history-detail-modal-actions{
  display:flex!important;
  justify-content:flex-end!important;
  margin-top:18px!important;
}
@media (max-width: 900px){
  .rp-prof-panel .rp-history-records-table{
    table-layout:auto!important;
  }
  .rp-prof-panel .rp-history-table-wrap{
    overflow-x:auto!important;
  }
  .rp-prof-panel .rp-history-row-actions{
    flex-wrap:wrap!important;
    justify-content:flex-start!important;
  }
}

/* v366.33 - Filtros de fecha en historial de sesiones */
.rp-prof-panel .rp-session-history-toolbar{
  display:flex!important;
  align-items:flex-end!important;
  justify-content:space-between!important;
  gap:10px!important;
  flex-wrap:wrap!important;
  margin:0 0 10px!important;
}
.rp-prof-panel .rp-session-history-date-filters{
  display:flex!important;
  align-items:flex-end!important;
  gap:8px!important;
  flex-wrap:wrap!important;
}
.rp-prof-panel .rp-session-history-date-filters label{
  display:flex!important;
  flex-direction:column!important;
  gap:4px!important;
  margin:0!important;
  color:#344054!important;
  font-size:11px!important;
  font-weight:700!important;
  line-height:1.1!important;
}
.rp-prof-panel .rp-session-history-date-filters input[type="date"]{
  width:145px!important;
  height:30px!important;
  min-height:30px!important;
  border:1px solid #D7DEE8!important;
  border-radius:10px!important;
  background:#fff!important;
  color:#1f2937!important;
  font-size:12px!important;
  padding:0 9px!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-session-history-date-filters button{
  height:30px!important;
  min-height:30px!important;
  display:inline-flex!important;
  align-items:center!important;
  gap:6px!important;
  border:1px solid #D7DEE8!important;
  border-radius:10px!important;
  background:#fff!important;
  color:#344054!important;
  font-size:12px!important;
  font-weight:500!important;
  padding:0 10px!important;
  cursor:pointer!important;
  box-shadow:none!important;
}
@media(max-width:768px){
  .rp-prof-panel .rp-session-history-toolbar{align-items:stretch!important;}
  .rp-prof-panel .rp-session-history-date-filters{width:100%!important;}
  .rp-prof-panel .rp-session-history-date-filters label{flex:1 1 130px!important;}
  .rp-prof-panel .rp-session-history-date-filters input[type="date"]{width:100%!important;}
}

/* v366-42 - Onboarding inicial: estética compacta, sin bordes/fondos en pasos e iconos lineales */
.rp-onboarding-layer .rp-onboarding-modal{
  border-radius:16px!important;
  border:0!important;
  box-shadow:0 24px 70px rgba(15,23,42,.28)!important;
  padding:24px!important;
}
.rp-onboarding-layer .rp-onboarding-badge{
  background:transparent!important;
  border:0!important;
  border-radius:0!important;
  color:#102A56!important;
  padding:0!important;
  gap:7px!important;
  align-items:center!important;
  font-weight:650!important;
}
.rp-onboarding-layer .rp-onboarding-modal h2{
  display:flex!important;
  align-items:center!important;
  gap:10px!important;
  color:#102A56!important;
  font-weight:650!important;
}
.rp-onboarding-title-icon,
.rp-onboarding-step-icon,
.rp-onboarding-inline-icon,
.rp-btn-icon{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  flex:0 0 auto!important;
  color:currentColor!important;
  line-height:0!important;
}
.rp-onboarding-title-icon{width:30px!important;height:30px!important;color:#102A56!important;}
.rp-onboarding-inline-icon{width:17px!important;height:17px!important;}
.rp-onboarding-step-icon{width:24px!important;height:24px!important;color:#102A56!important;margin-top:1px!important;}
.rp-btn-icon{width:18px!important;height:18px!important;}
.rp-onboarding-title-icon svg,
.rp-onboarding-step-icon svg,
.rp-onboarding-inline-icon svg,
.rp-btn-icon svg{
  width:100%!important;
  height:100%!important;
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.55!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
}
.rp-onboarding-layer .rp-onboarding-steps{
  gap:8px!important;
  margin:16px 0!important;
}
.rp-onboarding-layer .rp-onboarding-steps>div{
  display:flex!important;
  align-items:flex-start!important;
  gap:10px!important;
  border:0!important;
  background:transparent!important;
  border-radius:0!important;
  padding:8px 0!important;
  box-shadow:none!important;
}
.rp-onboarding-layer .rp-onboarding-steps>div.is-active{
  border:0!important;
  background:transparent!important;
}
.rp-onboarding-layer .rp-onboarding-steps strong{
  font-weight:600!important;
  color:#102A56!important;
}
.rp-onboarding-layer .rp-onboarding-steps span{
  color:#64748b!important;
}
.rp-onboarding-layer .rp-onboarding-steps .rp-onboarding-step-copy{
  display:block!important;
  margin:0!important;
}
.rp-onboarding-layer .rp-onboarding-actions{
  justify-content:flex-end!important;
  margin-top:16px!important;
}
.rp-onboarding-primary,
.rp-onboarding-layer .rp-onboarding-primary,
.rp-onboarding-helper .rp-onboarding-primary{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:8px!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  border:0!important;
  color:#fff!important;
  border-radius:10px!important;
  box-shadow:none!important;
  font-weight:600!important;
}
.rp-onboarding-primary svg,
.rp-onboarding-layer .rp-onboarding-primary svg,
.rp-onboarding-helper .rp-onboarding-primary svg{
  fill:none!important;
  stroke:#fff!important;
  stroke-width:1.7!important;
}
.rp-onboarding-helper{
  border-radius:14px!important;
  border:0!important;
  box-shadow:0 18px 42px rgba(15,23,42,.22)!important;
}
.rp-onboarding-helper strong{
  display:flex!important;
  align-items:center!important;
  gap:8px!important;
}
@media(max-width:760px){
  .rp-onboarding-layer .rp-onboarding-modal{border-radius:14px!important;padding:20px!important;}
  .rp-onboarding-layer .rp-onboarding-actions .rp-btn{width:100%!important;}
}

/* v366.42b - Tour opcional: card Dashboard más compacta y limpia */
.rp-tour-layer{
  right:18px!important;
  bottom:18px!important;
  width:min(390px,calc(100vw - 36px))!important;
  z-index:999999!important;
}
.rp-tour-card{
  position:relative!important;
  background:#fff!important;
  border:0!important;
  border-radius:14px!important;
  padding:14px!important;
  box-shadow:0 16px 44px rgba(15,23,42,.18)!important;
  overflow:hidden!important;
}
.rp-tour-card:before,
.rp-tour-card:after{
  content:none!important;
  display:none!important;
}
.rp-tour-head{
  display:grid!important;
  grid-template-columns:34px 1fr auto!important;
  gap:10px!important;
  align-items:start!important;
}
.rp-tour-icon{
  width:34px!important;
  height:34px!important;
  border-radius:10px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  background:#f1f7fb!important;
  color:#0f4c81!important;
  flex:0 0 auto!important;
}
.rp-tour-icon svg,
.rp-tour-next .rp-btn-icon svg{
  width:18px!important;
  height:18px!important;
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.7!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
}
.rp-tour-copy h3,
.rp-tour-card h3{
  margin:0 0 4px!important;
  font-size:18px!important;
  line-height:1.18!important;
  font-weight:650!important;
  color:#111827!important;
}
.rp-tour-copy p,
.rp-tour-card p{
  margin:0!important;
  color:#4b5563!important;
  font-size:14px!important;
  line-height:1.35!important;
}
.rp-tour-count{
  min-width:34px!important;
  height:26px!important;
  padding:0 8px!important;
  border-radius:999px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  background:#eef6fb!important;
  color:#0f4c81!important;
  font-size:12px!important;
  font-weight:700!important;
  line-height:1!important;
}
.rp-tour-actions{
  margin-top:13px!important;
  display:flex!important;
  justify-content:flex-end!important;
  align-items:center!important;
  gap:8px!important;
  flex-wrap:nowrap!important;
}
.rp-tour-skip{
  background:transparent!important;
  border:0!important;
  box-shadow:none!important;
  color:#0f4c81!important;
  padding:8px 10px!important;
  min-height:34px!important;
  border-radius:9px!important;
  font-size:13px!important;
  font-weight:600!important;
}
.rp-tour-next{
  background:#0f4c81!important;
  color:#fff!important;
  border:0!important;
  box-shadow:none!important;
  border-radius:9px!important;
  padding:8px 12px!important;
  min-height:34px!important;
  font-size:13px!important;
  font-weight:700!important;
  display:inline-flex!important;
  align-items:center!important;
  gap:7px!important;
}
.rp-tour-next .rp-btn-icon{
  width:17px!important;
  height:17px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  color:#fff!important;
  margin:0!important;
}
@media(max-width:760px){
  .rp-tour-layer{right:10px!important;bottom:10px!important;width:calc(100vw - 20px)!important;}
  .rp-tour-card{border-radius:13px!important;padding:13px!important;}
  .rp-tour-head{grid-template-columns:32px 1fr auto!important;gap:9px!important;}
  .rp-tour-icon{width:32px!important;height:32px!important;border-radius:9px!important;}
}

/* v331 - Orden alfabético en tabla de pacientes */
#pacientes .rp-patient-sort-head{
  min-width:190px!important;
}
#pacientes .rp-patient-sort-controls{
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:6px!important;
  margin-top:7px!important;
  flex-wrap:wrap!important;
}
#pacientes .rp-patient-sort-btn{
  appearance:none!important;
  border:1px solid rgba(255,255,255,.55)!important;
  background:rgba(255,255,255,.12)!important;
  color:#fff!important;
  border-radius:8px!important;
  padding:4px 8px!important;
  font-size:11px!important;
  line-height:1.1!important;
  font-weight:400!important;
  cursor:pointer!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:4px!important;
}
#pacientes .rp-patient-sort-btn:hover,
#pacientes .rp-patient-sort-btn.is-active{
  background:#fff!important;
  color:#102A56!important;
  border-color:#fff!important;
}
#pacientes .rp-patient-sort-btn .rp-sort-arrow{
  display:inline-flex!important;
  min-width:10px!important;
  justify-content:center!important;
  font-size:11px!important;
  font-weight:400!important;
}

/* v367 - Historial de sesiones: acciones masivas */
.rp-prof-panel .rp-session-bulk-form{margin:0!important;}
.rp-prof-panel .rp-session-bulk-toolbar{display:flex!important;align-items:center!important;justify-content:space-between!important;gap:12px!important;flex-wrap:wrap!important;margin:0 0 12px!important;padding:12px!important;background:#f8fafc!important;border:1px solid #e5e7eb!important;border-radius:14px!important;}
.rp-prof-panel .rp-session-select-all-label{display:inline-flex!important;align-items:center!important;gap:8px!important;font-size:13px!important;font-weight:700!important;color:#334155!important;margin:0!important;}
.rp-prof-panel .rp-session-select-all-label input,
.rp-prof-panel .rp-session-select-col input{width:16px!important;height:16px!important;accent-color:#0b7fab!important;}
.rp-prof-panel .rp-session-bulk-buttons{display:flex!important;align-items:center!important;gap:8px!important;flex-wrap:wrap!important;}
.rp-prof-panel .rp-session-select-col{text-align:center!important;width:44px!important;min-width:44px!important;}
.rp-prof-panel .rp-session-history-table th.rp-session-select-col,
.rp-prof-panel .rp-session-history-table td.rp-session-select-col{padding-left:8px!important;padding-right:8px!important;}
@media(max-width:760px){.rp-prof-panel .rp-session-bulk-toolbar{align-items:stretch!important}.rp-prof-panel .rp-session-bulk-buttons,.rp-prof-panel .rp-session-bulk-buttons .rp-btn{width:100%!important}.rp-prof-panel .rp-session-bulk-buttons .rp-btn{justify-content:center!important}}

/* v368 - Ajuste cancelación masiva historial sesiones */
.rp-prof-panel .rp-session-select-all-label{
  font-weight:400!important;
  color:#102A56!important;
}
.rp-prof-panel .rp-session-bulk-buttons .rp-btn{
  min-height:34px!important;
  padding:7px 11px!important;
  font-size:12px!important;
  line-height:1.1!important;
  border-radius:10px!important;
  white-space:nowrap!important;
}
.rp-prof-panel .rp-session-bulk-buttons .rp-btn-light,
.rp-prof-panel .rp-session-bulk-buttons button[value="bulk_cancel_appointments"]{
  background:#fff!important;
  color:#102A56!important;
  border:1px solid #102A56!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-session-bulk-buttons .rp-btn-light .rp-btn-svg,
.rp-prof-panel .rp-session-bulk-buttons button[value="bulk_cancel_appointments"] .rp-btn-svg{
  color:#102A56!important;
}
.rp-prof-panel .rp-session-history-table th,
.rp-prof-panel .rp-session-history-table td{
  padding:9px 8px!important;
  font-size:12px!important;
  vertical-align:middle!important;
}
.rp-prof-panel .rp-session-history-table .rp-session-type-badge,
.rp-prof-panel .rp-session-history-table .rp-modality-chip,
.rp-prof-panel .rp-session-history-table .rp-session-status-chip,
.rp-prof-panel .rp-session-history-table .rp-session-billing-status{
  font-size:11px!important;
  line-height:1.15!important;
  white-space:nowrap!important;
}
.rp-prof-panel .rp-session-history-table .rp-mini-action{
  min-height:30px!important;
  padding:6px 9px!important;
  font-size:11px!important;
  border-radius:9px!important;
}
.rp-prof-panel .rp-session-actions-main{
  gap:6px!important;
}
.rp-prof-panel .rp-session-history-table th:nth-child(4),
.rp-prof-panel .rp-session-history-table td:nth-child(4){
  min-width:150px!important;
}
.rp-prof-panel .rp-session-history-table th:nth-child(5),
.rp-prof-panel .rp-session-history-table td:nth-child(5){
  min-width:110px!important;
}

/* v369 - Corrección definitiva seleccionar todo y aire visual tabla historial sesiones */
.rp-prof-panel .rp-session-select-all-label{
  font-weight:400!important;
  font-size:13px!important;
  color:#102A56!important;
}
.rp-prof-panel table.rp-session-history-table{
  min-width:1160px!important;
  table-layout:fixed!important;
}
.rp-prof-panel .rp-session-history-table th,
.rp-prof-panel .rp-session-history-table td{
  padding:8px 10px!important;
  font-size:12.5px!important;
  line-height:1.2!important;
  vertical-align:middle!important;
}
.rp-prof-panel .rp-session-history-table th:nth-child(1),
.rp-prof-panel .rp-session-history-table td:nth-child(1){width:50px!important;min-width:50px!important;max-width:50px!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(2),
.rp-prof-panel .rp-session-history-table td:nth-child(2){width:110px!important;min-width:110px!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(3),
.rp-prof-panel .rp-session-history-table td:nth-child(3){width:125px!important;min-width:125px!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(4),
.rp-prof-panel .rp-session-history-table td:nth-child(4){width:185px!important;min-width:185px!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(5),
.rp-prof-panel .rp-session-history-table td:nth-child(5){width:125px!important;min-width:125px!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(6),
.rp-prof-panel .rp-session-history-table td:nth-child(6){width:125px!important;min-width:125px!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(7),
.rp-prof-panel .rp-session-history-table td:nth-child(7){width:95px!important;min-width:95px!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(8),
.rp-prof-panel .rp-session-history-table td:nth-child(8){width:145px!important;min-width:145px!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(9),
.rp-prof-panel .rp-session-history-table td:nth-child(9){width:200px!important;min-width:200px!important;}
.rp-prof-panel .rp-session-history-table .rp-session-type-badge,
.rp-prof-panel .rp-session-history-table .rp-modality-chip,
.rp-prof-panel .rp-session-history-table .rp-session-status-chip,
.rp-prof-panel .rp-session-history-table .rp-session-billing-status{
  font-size:12px!important;
  line-height:1.15!important;
  white-space:nowrap!important;
  max-width:100%!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
}
.rp-prof-panel .rp-session-history-table .rp-modality-chip{
  justify-content:center!important;
  gap:4px!important;
}
.rp-prof-panel .rp-session-history-table .rp-mini-action{
  min-height:28px!important;
  padding:5px 8px!important;
  font-size:11px!important;
  border-radius:9px!important;
}
.rp-prof-panel .rp-session-actions-main{gap:5px!important;}
.rp-prof-panel .rp-session-bulk-buttons .rp-btn{
  min-height:34px!important;
  padding:7px 12px!important;
  font-size:12px!important;
  border-radius:10px!important;
}
.rp-prof-panel .rp-session-bulk-buttons button[value="bulk_cancel_appointments"]{
  background:#fff!important;
  color:#102A56!important;
  border:1px solid #102A56!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-session-bulk-buttons button[value="bulk_cancel_appointments"] svg,
.rp-prof-panel .rp-session-bulk-buttons button[value="bulk_cancel_appointments"] .rp-btn-svg{
  color:#102A56!important;
  stroke:#102A56!important;
}

/* v370 - Seleccionar todo estable y tabla sin desborde en PC */
.rp-prof-panel table.rp-session-history-table{
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  table-layout:fixed!important;
}
.rp-prof-panel .rp-history-table-wrap{
  max-width:100%!important;
  overflow-x:hidden!important;
}
.rp-prof-panel .rp-session-history-table th,
.rp-prof-panel .rp-session-history-table td{
  padding:8px 7px!important;
  font-size:12px!important;
  line-height:1.2!important;
  box-sizing:border-box!important;
}
.rp-prof-panel .rp-session-history-table th:nth-child(1),
.rp-prof-panel .rp-session-history-table td:nth-child(1){width:4.5%!important;min-width:0!important;max-width:none!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(2),
.rp-prof-panel .rp-session-history-table td:nth-child(2){width:10%!important;min-width:0!important;max-width:none!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(3),
.rp-prof-panel .rp-session-history-table td:nth-child(3){width:12%!important;min-width:0!important;max-width:none!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(4),
.rp-prof-panel .rp-session-history-table td:nth-child(4){width:16%!important;min-width:0!important;max-width:none!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(5),
.rp-prof-panel .rp-session-history-table td:nth-child(5){width:12%!important;min-width:0!important;max-width:none!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(6),
.rp-prof-panel .rp-session-history-table td:nth-child(6){width:10%!important;min-width:0!important;max-width:none!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(7),
.rp-prof-panel .rp-session-history-table td:nth-child(7){width:7%!important;min-width:0!important;max-width:none!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(8),
.rp-prof-panel .rp-session-history-table td:nth-child(8){width:11.5%!important;min-width:0!important;max-width:none!important;}
.rp-prof-panel .rp-session-history-table th:nth-child(9),
.rp-prof-panel .rp-session-history-table td:nth-child(9){width:17%!important;min-width:0!important;max-width:none!important;}
.rp-prof-panel .rp-session-history-table .rp-session-type-badge,
.rp-prof-panel .rp-session-history-table .rp-modality-chip,
.rp-prof-panel .rp-session-history-table .rp-session-status-chip,
.rp-prof-panel .rp-session-history-table .rp-session-billing-status{
  max-width:100%!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  white-space:nowrap!important;
}
.rp-prof-panel .rp-session-history-table .rp-mini-action{
  min-height:27px!important;
  padding:5px 7px!important;
  font-size:10.5px!important;
  border-radius:8px!important;
}
.rp-prof-panel .rp-session-history-table .rp-mini-action .rp-btn-svg{margin-right:4px!important;}
.rp-prof-panel .rp-session-actions-main{gap:4px!important;flex-wrap:nowrap!important;}
.rp-prof-panel .rp-session-select-all-label{font-weight:400!important;}
@media(max-width:900px){
  .rp-prof-panel .rp-history-table-wrap{overflow-x:auto!important;}
  .rp-prof-panel table.rp-session-history-table{min-width:900px!important;}
}

/* v371 - Ajuste fino PC historial de sesiones sin desborde */
@media (min-width:901px){
  .rp-prof-panel .rp-session-history-card,
  .rp-prof-panel .rp-session-history-card .rp-detail-card-body,
  .rp-prof-panel .rp-session-history-card .rp-history-table-wrap{
    max-width:100%!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-history-table-wrap{
    padding:0!important;
    border-radius:12px!important;
  }
  .rp-prof-panel table.rp-session-history-table{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    table-layout:fixed!important;
    border-collapse:separate!important;
    border-spacing:0!important;
  }
  .rp-prof-panel .rp-session-history-table th,
  .rp-prof-panel .rp-session-history-table td{
    padding:7px 5px!important;
    font-size:11.5px!important;
    line-height:1.18!important;
    box-sizing:border-box!important;
    overflow:hidden!important;
  }
  .rp-prof-panel .rp-session-history-table th:nth-child(1),
  .rp-prof-panel .rp-session-history-table td:nth-child(1){width:4%!important;}
  .rp-prof-panel .rp-session-history-table th:nth-child(2),
  .rp-prof-panel .rp-session-history-table td:nth-child(2){width:9.5%!important;}
  .rp-prof-panel .rp-session-history-table th:nth-child(3),
  .rp-prof-panel .rp-session-history-table td:nth-child(3){width:11.5%!important;}
  .rp-prof-panel .rp-session-history-table th:nth-child(4),
  .rp-prof-panel .rp-session-history-table td:nth-child(4){width:15%!important;}
  .rp-prof-panel .rp-session-history-table th:nth-child(5),
  .rp-prof-panel .rp-session-history-table td:nth-child(5){width:11%!important;}
  .rp-prof-panel .rp-session-history-table th:nth-child(6),
  .rp-prof-panel .rp-session-history-table td:nth-child(6){width:9.5%!important;}
  .rp-prof-panel .rp-session-history-table th:nth-child(7),
  .rp-prof-panel .rp-session-history-table td:nth-child(7){width:6.5%!important;}
  .rp-prof-panel .rp-session-history-table th:nth-child(8),
  .rp-prof-panel .rp-session-history-table td:nth-child(8){width:10.5%!important;}
  .rp-prof-panel .rp-session-history-table th:nth-child(9),
  .rp-prof-panel .rp-session-history-table td:nth-child(9){width:22.5%!important;}
  .rp-prof-panel .rp-session-history-table th:nth-child(n),
  .rp-prof-panel .rp-session-history-table td:nth-child(n){min-width:0!important;max-width:none!important;}
  .rp-prof-panel .rp-session-history-table .rp-session-type-badge,
  .rp-prof-panel .rp-session-history-table .rp-modality-chip,
  .rp-prof-panel .rp-session-history-table .rp-session-status-chip,
  .rp-prof-panel .rp-session-history-table .rp-session-billing-status{
    display:inline-flex!important;
    max-width:100%!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    white-space:nowrap!important;
    font-size:11.5px!important;
    padding:3px 6px!important;
  }
  .rp-prof-panel .rp-session-history-table .rp-mini-action{
    min-height:25px!important;
    padding:4px 6px!important;
    font-size:10px!important;
    border-radius:7px!important;
    white-space:nowrap!important;
  }
  .rp-prof-panel .rp-session-history-table .rp-mini-action svg,
  .rp-prof-panel .rp-session-history-table .rp-mini-action .rp-btn-svg{
    width:13px!important;
    height:13px!important;
    margin-right:3px!important;
    flex:0 0 13px!important;
  }
  .rp-prof-panel .rp-session-actions-main{
    display:flex!important;
    justify-content:flex-end!important;
    gap:3px!important;
    flex-wrap:nowrap!important;
  }
}


/* RedPsico v6 - Modal Crear paciente compacto + frecuencia libre/rotativa */
.rp-modal[data-rp-modal="patient"] .rp-modal-box{
  width:min(820px,94vw)!important;
  padding:20px 22px!important;
  border-radius:16px!important;
}
.rp-modal[data-rp-modal="patient"] .rp-patient-modal-title,
.rp-modal[data-rp-modal="patient"] .rp-modal-box > h2{
  display:flex!important;
  align-items:center!important;
  gap:8px!important;
  margin:0 0 12px!important;
  font-size:16px!important;
  line-height:1.25!important;
  font-weight:500!important;
  color:#102A56!important;
}
.rp-modal[data-rp-modal="patient"] .rp-patient-modal-title svg,
.rp-modal[data-rp-modal="patient"] .rp-modal-box > h2 svg{
  width:17px!important;
  height:17px!important;
  min-width:17px!important;
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.35!important;
}
.rp-modal[data-rp-modal="patient"] .rp-patient-form{
  gap:9px 12px!important;
}
.rp-modal[data-rp-modal="patient"] .rp-form-title{
  display:flex!important;
  align-items:center!important;
  gap:7px!important;
  font-size:16px!important;
  line-height:1.25!important;
  font-weight:500!important;
  margin:5px 0 0!important;
  padding-top:9px!important;
}
.rp-modal[data-rp-modal="patient"] .rp-form-title:first-of-type{
  padding-top:0!important;
  margin-top:0!important;
}
.rp-modal[data-rp-modal="patient"] .rp-form-title::before{
  content:"";
  width:15px;
  height:15px;
  flex:0 0 15px;
  display:inline-block;
  background:currentColor;
  -webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.45' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 19.5A2.5 2.5 0 0 1 6.5 17H20'/%3E%3Cpath d='M6.5 2H20v20H6.5A2.5 2.5 0 0 1 4 19.5v-15A2.5 2.5 0 0 1 6.5 2Z'/%3E%3C/svg%3E") center/contain no-repeat;
  mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.45' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 19.5A2.5 2.5 0 0 1 6.5 17H20'/%3E%3Cpath d='M6.5 2H20v20H6.5A2.5 2.5 0 0 1 4 19.5v-15A2.5 2.5 0 0 1 6.5 2Z'/%3E%3C/svg%3E") center/contain no-repeat;
}
.rp-modal[data-rp-modal="patient"] .rp-patient-form label,
.rp-modal[data-rp-modal="patient"] .rp-patient-form .rp-field-hint,
.rp-modal[data-rp-modal="patient"] .rp-patient-form .rp-check-inline{
  font-size:12px!important;
  line-height:1.25!important;
  font-weight:400!important;
  gap:4px!important;
}
.rp-modal[data-rp-modal="patient"] .rp-patient-form input,
.rp-modal[data-rp-modal="patient"] .rp-patient-form select,
.rp-modal[data-rp-modal="patient"] .rp-patient-form textarea{
  min-height:34px!important;
  height:auto!important;
  border-radius:8px!important;
  padding:7px 9px!important;
  font-size:12px!important;
  line-height:1.2!important;
  font-weight:400!important;
}
.rp-modal[data-rp-modal="patient"] .rp-patient-form textarea{
  min-height:60px!important;
}
.rp-modal[data-rp-modal="patient"] .rp-patient-form input[type="checkbox"]{
  width:15px!important;
  height:15px!important;
  min-height:15px!important;
  padding:0!important;
}
.rp-modal[data-rp-modal="patient"] .rp-patient-save-btn{
  min-height:36px!important;
  padding:9px 13px!important;
  font-size:12px!important;
  font-weight:400!important;
  border-radius:9px!important;
}
.rp-modal[data-rp-modal="patient"] .rp-modal-close{
  width:30px!important;
  height:30px!important;
  font-size:20px!important;
  top:12px!important;
  right:12px!important;
}
@media (max-width:760px){
  .rp-modal[data-rp-modal="patient"] .rp-modal-box{
    padding:18px 14px!important;
    max-height:calc(100vh - 24px)!important;
  }
  .rp-modal[data-rp-modal="patient"] .rp-patient-form{
    gap:8px!important;
  }
}


/* Compactar tabla Pacientes solo PC */
@media (min-width:1025px){
.rpp-patients-table table,
.rpp-patients-table th,
.rpp-patients-table td,
.rp-patients-table table,
.rp-patients-table th,
.rp-patients-table td{
font-size:13px!important;
}
.rpp-patients-table th,.rp-patients-table th{padding:10px 8px!important;}
.rpp-patients-table td,.rp-patients-table td{padding:8px 8px!important;line-height:1.25!important;}
.rpp-patients-table tr,.rp-patients-table tr{height:46px!important;}
.rpp-patients-table .button,.rp-patients-table .button,
.rpp-patients-table .btn,.rp-patients-table .btn{
padding:8px 12px!important;
font-size:12px!important;
min-height:36px!important;
}
.rpp-patients-table .sort-btn,.rp-patients-table .sort-btn{
padding:6px 10px!important;
font-size:12px!important;
}
}

/* RedPsico v372 - Pacientes PC compacto real sin desbordamiento */
@media (min-width: 981px){
  .rp-prof-panel #pacientes,
  .rp-prof-panel #pacientes *{
    box-sizing:border-box!important;
  }
  .rp-prof-panel #pacientes .rp-table-card{
    width:100%!important;
    max-width:100%!important;
    padding:16px 18px!important;
    overflow:hidden!important;
  }
  .rp-prof-panel #pacientes .rp-responsive-table{
    width:100%!important;
    max-width:100%!important;
    overflow:visible!important;
  }
  .rp-prof-panel #pacientes table.rp-patient-table{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    table-layout:fixed!important;
    border-collapse:collapse!important;
  }
  .rp-prof-panel #pacientes table.rp-patient-table th,
  .rp-prof-panel #pacientes table.rp-patient-table td{
    padding:9px 6px!important;
    font-size:12px!important;
    line-height:1.18!important;
    min-width:0!important;
    max-width:none!important;
    white-space:normal!important;
    overflow:hidden!important;
    overflow-wrap:anywhere!important;
    word-break:normal!important;
    vertical-align:middle!important;
  }
  .rp-prof-panel #pacientes table.rp-patient-table thead th{
    font-size:11px!important;
    line-height:1.15!important;
    letter-spacing:.025em!important;
    padding-top:11px!important;
    padding-bottom:11px!important;
    text-align:center!important;
  }
  .rp-prof-panel #pacientes table.rp-patient-table tbody td{
    height:48px!important;
  }
  .rp-prof-panel #pacientes table.rp-patient-table td strong{
    font-size:13px!important;
    line-height:1.15!important;
    margin-bottom:2px!important;
  }
  .rp-prof-panel #pacientes table.rp-patient-table td small{
    font-size:10.5px!important;
    line-height:1.18!important;
    margin-top:2px!important;
  }
  .rp-prof-panel #pacientes table.rp-patient-table th:nth-child(1),
  .rp-prof-panel #pacientes table.rp-patient-table td:nth-child(1){width:4.5%!important;text-align:center!important;}
  .rp-prof-panel #pacientes table.rp-patient-table th:nth-child(2),
  .rp-prof-panel #pacientes table.rp-patient-table td:nth-child(2){width:18%!important;}
  .rp-prof-panel #pacientes table.rp-patient-table th:nth-child(3),
  .rp-prof-panel #pacientes table.rp-patient-table td:nth-child(3){width:17%!important;}
  .rp-prof-panel #pacientes table.rp-patient-table th:nth-child(4),
  .rp-prof-panel #pacientes table.rp-patient-table td:nth-child(4){width:8%!important;text-align:center!important;}
  .rp-prof-panel #pacientes table.rp-patient-table th:nth-child(5),
  .rp-prof-panel #pacientes table.rp-patient-table td:nth-child(5){width:8.5%!important;text-align:center!important;}
  .rp-prof-panel #pacientes table.rp-patient-table th:nth-child(6),
  .rp-prof-panel #pacientes table.rp-patient-table td:nth-child(6){width:8.5%!important;text-align:center!important;}
  .rp-prof-panel #pacientes table.rp-patient-table th:nth-child(7),
  .rp-prof-panel #pacientes table.rp-patient-table td:nth-child(7){width:9%!important;text-align:center!important;}
  .rp-prof-panel #pacientes table.rp-patient-table th:nth-child(8),
  .rp-prof-panel #pacientes table.rp-patient-table td:nth-child(8){width:7.5%!important;text-align:center!important;}
  .rp-prof-panel #pacientes table.rp-patient-table th:nth-child(9),
  .rp-prof-panel #pacientes table.rp-patient-table td:nth-child(9){width:7.5%!important;text-align:center!important;}
  .rp-prof-panel #pacientes table.rp-patient-table th:nth-child(10),
  .rp-prof-panel #pacientes table.rp-patient-table td:nth-child(10){width:11.5%!important;text-align:right!important;}
  .rp-prof-panel #pacientes .rp-patient-sort-controls{
    gap:4px!important;
    margin-top:5px!important;
    justify-content:center!important;
    flex-wrap:nowrap!important;
  }
  .rp-prof-panel #pacientes .rp-patient-sort-btn{
    min-height:28px!important;
    padding:5px 8px!important;
    font-size:10.5px!important;
    line-height:1!important;
    border-radius:7px!important;
    white-space:nowrap!important;
  }
  .rp-prof-panel #pacientes .rp-patient-status{
    display:inline-flex!important;
    max-width:100%!important;
    padding:4px 8px!important;
    font-size:11px!important;
    line-height:1!important;
    white-space:nowrap!important;
  }
  .rp-prof-panel #pacientes .rp-patient-open-btn{
    min-height:32px!important;
    padding:7px 8px!important;
    font-size:10.5px!important;
    line-height:1.05!important;
    border-radius:8px!important;
    gap:5px!important;
    max-width:82px!important;
    white-space:normal!important;
  }
  .rp-prof-panel #pacientes .rp-patient-open-btn .rp-btn-svg,
  .rp-prof-panel #pacientes .rp-patient-open-btn svg{
    width:13px!important;
    height:13px!important;
    flex:0 0 13px!important;
  }
}

/* v367 - Mobile: historial de sesiones, filtros Desde/Hasta sin desborde */
@media (max-width: 768px){
  .rp-prof-panel .rp-session-history-card .rp-session-history-toolbar{
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
    justify-content:flex-start!important;
    gap:10px!important;
    width:100%!important;
    max-width:100%!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-filters{
    width:100%!important;
    max-width:100%!important;
    display:flex!important;
    flex-wrap:wrap!important;
    align-items:center!important;
    gap:7px!important;
    margin:0!important;
    box-sizing:border-box!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-filters button{
    flex:0 0 auto!important;
    max-width:100%!important;
    white-space:nowrap!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters{
    width:100%!important;
    max-width:100%!important;
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:8px!important;
    align-items:stretch!important;
    box-sizing:border-box!important;
    overflow:hidden!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters label{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    flex:none!important;
    display:flex!important;
    flex-direction:column!important;
    gap:5px!important;
    box-sizing:border-box!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters input[type="date"]{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
    height:34px!important;
    min-height:34px!important;
    font-size:13px!important;
    padding:0 10px!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters button{
    width:max-content!important;
    max-width:100%!important;
    min-width:0!important;
    height:34px!important;
    min-height:34px!important;
    padding:0 14px!important;
    justify-self:start!important;
    box-sizing:border-box!important;
  }
}

/* v368 - Mobile: calendario general con desplazamiento horizontal real */
@media (max-width: 768px){
  .rp-prof-panel #calendario-general.rp-general-calendar-section,
  .rp-prof-panel #calendario-general .rp-general-calendar-layout{
    max-width:100%!important;
    width:100%!important;
    overflow:visible!important;
    box-sizing:border-box!important;
  }
  .rp-prof-panel #calendario-general .rp-general-month-card{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    overflow-x:auto!important;
    overflow-y:visible!important;
    -webkit-overflow-scrolling:touch!important;
    overscroll-behavior-x:contain!important;
    padding-bottom:16px!important;
    box-sizing:border-box!important;
  }
  .rp-prof-panel #calendario-general .rp-general-month-card .rp-calendar-title{
    min-width:0!important;
    width:100%!important;
    max-width:100%!important;
  }
  .rp-prof-panel #calendario-general .rp-calendar-weekdays,
  .rp-prof-panel #calendario-general .rp-general-calendar-grid.rp-admin-calendar{
    width:max-content!important;
    min-width:720px!important;
    max-width:none!important;
    display:grid!important;
    grid-template-columns:repeat(7, 96px)!important;
    gap:8px!important;
    overflow:visible!important;
  }
  .rp-prof-panel #calendario-general .rp-calendar-weekdays span{
    width:96px!important;
    min-width:96px!important;
    max-width:96px!important;
    text-align:center!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell,
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-empty{
    width:96px!important;
    min-width:96px!important;
    max-width:96px!important;
    min-height:108px!important;
    padding:10px!important;
    box-sizing:border-box!important;
    overflow:hidden!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell strong{
    font-size:18px!important;
    line-height:1.1!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell span,
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell em{
    display:block!important;
    font-size:11px!important;
    line-height:1.15!important;
    white-space:normal!important;
  }
}

@media (max-width:768px){
.rp-session-history .rp-filter-row,
.rp-historial-filtros,
.rp-session-filters{display:block!important;}
.rp-session-history input[type="date"],
.rp-historial-filtros input[type="date"],
.rp-session-filters input[type="date"]{
width:100%!important;
min-width:0!important;
max-width:100%!important;
box-sizing:border-box!important;
display:block!important;
margin:0 0 12px 0!important;
}
}

/* v369 - Corrección real móvil: Desde/Hasta en historial sin desborde */
@media (max-width: 768px){
  .rp-prof-panel .rp-session-history-card,
  .rp-prof-panel .rp-session-history-card .rp-history-body,
  .rp-prof-panel .rp-session-history-card .rp-session-history-toolbar,
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters,
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters label{
    box-sizing:border-box!important;
    max-width:100%!important;
    min-width:0!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-history-body{
    overflow:hidden!important;
    padding-left:12px!important;
    padding-right:12px!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-toolbar{
    display:block!important;
    width:100%!important;
    overflow:hidden!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-filters{
    display:flex!important;
    flex-wrap:wrap!important;
    width:100%!important;
    max-width:100%!important;
    gap:7px!important;
    margin:0 0 12px!important;
    overflow:hidden!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters{
    display:block!important;
    width:100%!important;
    max-width:100%!important;
    overflow:hidden!important;
    padding:0!important;
    margin:0!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters label{
    display:block!important;
    width:100%!important;
    max-width:100%!important;
    margin:0 0 12px!important;
    padding:0!important;
    overflow:hidden!important;
    color:#344054!important;
    font-size:13px!important;
    font-weight:700!important;
    line-height:1.15!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters input[type="date"]{
    display:block!important;
    inline-size:calc(100% - 4px)!important;
    width:calc(100% - 4px)!important;
    max-inline-size:calc(100% - 4px)!important;
    max-width:calc(100% - 4px)!important;
    min-inline-size:0!important;
    min-width:0!important;
    height:48px!important;
    min-height:48px!important;
    margin:8px 0 0!important;
    padding:0 12px!important;
    border:1px solid #D7DEE8!important;
    border-radius:14px!important;
    background:#fff!important;
    color:#102A56!important;
    font-size:16px!important;
    font-weight:500!important;
    line-height:48px!important;
    box-sizing:border-box!important;
    -webkit-appearance:none!important;
    appearance:none!important;
    overflow:hidden!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters input[type="date"]::-webkit-date-and-time-value{
    display:block!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    overflow:hidden!important;
    text-align:left!important;
    padding:0!important;
    margin:0!important;
    line-height:48px!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters input[type="date"]::-webkit-calendar-picker-indicator{
    flex:0 0 auto!important;
    max-width:22px!important;
    margin:0!important;
    padding:0!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters button[data-rp-session-clear-dates]{
    display:inline-flex!important;
    width:auto!important;
    max-width:100%!important;
    min-width:0!important;
    height:40px!important;
    min-height:40px!important;
    margin:0!important;
    padding:0 18px!important;
    box-sizing:border-box!important;
  }
}

/* RedPsico ajuste final menú profesional móvil: estilo compacto igual administración */
@media (max-width:760px){
  .rp-prof-panel,
  .rp-prof-panel.rp-sidebar-expanded{
    display:block!important;
    grid-template-columns:1fr!important;
    overflow:visible!important;
  }

  .rp-prof-panel > .rp-prof-sidebar,
  .rp-prof-sidebar:not(.mobile-open){
    width:calc(100% - 44px)!important;
    max-width:760px!important;
    min-width:0!important;
    height:auto!important;
    min-height:0!important;
    margin:24px auto 0!important;
    padding:16px 18px!important;
    border-radius:20px 20px 0 0!important;
    background:#102a56!important;
    box-shadow:none!important;
    position:relative!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;
    z-index:20!important;
    display:flex!important;
    align-items:center!important;
    justify-content:space-between!important;
    flex-direction:row!important;
    overflow:hidden!important;
  }

  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand,
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand{
    width:auto!important;
    height:auto!important;
    min-height:0!important;
    margin:0!important;
    padding:0!important;
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:12px!important;
    overflow:visible!important;
  }

  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand .rp-brand-logo-wrap{
    width:58px!important;
    height:58px!important;
    min-width:58px!important;
    border-radius:16px!important;
    background:#fff!important;
    display:grid!important;
    place-items:center!important;
    overflow:hidden!important;
  }

  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand .rp-brand-logo{
    width:48px!important;
    height:48px!important;
    object-fit:contain!important;
    border-radius:12px!important;
  }

  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{
    display:block!important;
    opacity:1!important;
    max-width:170px!important;
    width:auto!important;
    color:#fff!important;
    font-size:12px!important;
    line-height:1.25!important;
    font-weight:400!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
  }

  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:44px!important;
    height:44px!important;
    min-width:44px!important;
    min-height:44px!important;
    margin:0!important;
    padding:0!important;
    border:0!important;
    background:transparent!important;
    color:#fff!important;
    font-size:0!important;
    line-height:1!important;
    box-shadow:none!important;
    border-radius:10px!important;
    overflow:visible!important;
  }

  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle::before{
    content:'☰'!important;
    display:block!important;
    font-size:34px!important;
    line-height:1!important;
    font-weight:400!important;
    color:#fff!important;
    transform:none!important;
  }

  .rp-prof-sidebar:not(.mobile-open) a{
    display:none!important;
  }

  body > .rp-prof-sidebar.mobile-open,
  .rp-prof-sidebar.mobile-open{
    position:fixed!important;
    inset:0!important;
    width:100vw!important;
    height:100vh!important;
    height:100dvh!important;
    max-width:none!important;
    max-height:none!important;
    min-width:0!important;
    margin:0!important;
    padding:18px 18px 22px!important;
    border-radius:0!important;
    background:#102a56!important;
    box-shadow:none!important;
    z-index:2147483647!important;
    overflow-y:auto!important;
    -webkit-overflow-scrolling:touch!important;
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
    box-sizing:border-box!important;
  }

  body > .rp-prof-sidebar.mobile-open .rp-prof-brand,
  .rp-prof-sidebar.mobile-open .rp-prof-brand{
    width:100%!important;
    height:auto!important;
    min-height:0!important;
    margin:0 0 14px!important;
    padding:0 0 14px!important;
    border-bottom:1px solid rgba(255,255,255,.22)!important;
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:12px!important;
    background:transparent!important;
    position:relative!important;
    top:auto!important;
  }

  body > .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo-wrap,
  .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo-wrap{
    width:58px!important;
    height:58px!important;
    min-width:58px!important;
    border-radius:16px!important;
    background:#fff!important;
  }

  body > .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo,
  .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo{
    width:48px!important;
    height:48px!important;
    object-fit:contain!important;
  }

  body > .rp-prof-sidebar.mobile-open .rp-prof-brand strong,
  .rp-prof-sidebar.mobile-open .rp-prof-brand strong{
    display:block!important;
    opacity:1!important;
    color:#fff!important;
    max-width:calc(100vw - 150px)!important;
    font-size:12px!important;
    line-height:1.25!important;
    font-weight:400!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
  }

  body > .rp-prof-sidebar.mobile-open .rp-sidebar-toggle,
  .rp-prof-sidebar.mobile-open .rp-sidebar-toggle{
    display:inline-flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:44px!important;
    height:44px!important;
    min-width:44px!important;
    min-height:44px!important;
    margin-left:auto!important;
    padding:0!important;
    border:0!important;
    background:transparent!important;
    color:#fff!important;
    font-size:0!important;
    line-height:1!important;
    box-shadow:none!important;
  }

  body > .rp-prof-sidebar.mobile-open .rp-sidebar-toggle::before,
  .rp-prof-sidebar.mobile-open .rp-sidebar-toggle::before{
    content:'×'!important;
    display:block!important;
    font-size:42px!important;
    line-height:.9!important;
    font-weight:300!important;
    color:#fff!important;
  }

  body > .rp-prof-sidebar.mobile-open a,
  .rp-prof-sidebar.mobile-open a{
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    width:100%!important;
    max-width:none!important;
    min-height:42px!important;
    height:42px!important;
    margin:3px 0!important;
    padding:0 14px!important;
    border-radius:12px!important;
    background:transparent!important;
    border:1px solid rgba(255,255,255,.18)!important;
    box-shadow:none!important;
    color:rgba(255,255,255,.88)!important;
    gap:10px!important;
    font-size:12px!important;
    line-height:1!important;
    font-weight:400!important;
    text-decoration:none!important;
    box-sizing:border-box!important;
  }

  body > .rp-prof-sidebar.mobile-open a.active,
  body > .rp-prof-sidebar.mobile-open a:hover,
  .rp-prof-sidebar.mobile-open a.active,
  .rp-prof-sidebar.mobile-open a:hover{
    background:#118fb5!important;
    border-color:#118fb5!important;
    color:#fff!important;
  }

  body > .rp-prof-sidebar.mobile-open .rp-nav-label,
  .rp-prof-sidebar.mobile-open .rp-nav-label{
    display:inline-block!important;
    opacity:1!important;
    width:auto!important;
    max-width:none!important;
    color:inherit!important;
    font-size:12px!important;
    line-height:1!important;
    font-weight:400!important;
  }

  body > .rp-prof-sidebar.mobile-open .rp-nav-icon svg,
  body > .rp-prof-sidebar.mobile-open a svg,
  .rp-prof-sidebar.mobile-open .rp-nav-icon svg,
  .rp-prof-sidebar.mobile-open a svg{
    width:17px!important;
    height:17px!important;
    min-width:17px!important;
    min-height:17px!important;
    stroke:currentColor!important;
    stroke-width:1.8!important;
  }

  .rp-prof-main{
    padding:18px 14px!important;
    min-width:0!important;
    overflow:visible!important;
  }
}

/* v329 - Mobile menu profesional: mismo criterio compacto que administración, sin cortes ni espacios blancos */
@media (max-width: 980px){
  .rp-prof-panel{
    padding-top:0!important;
    margin-top:0!important;
  }

  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open),
  .rp-prof-sidebar:not(.mobile-open){
    width:100%!important;
    max-width:none!important;
    min-width:0!important;
    margin:0!important;
    padding:0!important;
    position:relative!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;
    border-radius:0!important;
    background:transparent!important;
    box-shadow:none!important;
    overflow:visible!important;
    height:auto!important;
  }

  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand,
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand{
    width:100%!important;
    max-width:none!important;
    height:86px!important;
    min-height:86px!important;
    margin:0!important;
    padding:0 18px!important;
    border-radius:20px 20px 0 0!important;
    background:#102a56!important;
    box-shadow:none!important;
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:14px!important;
    box-sizing:border-box!important;
  }

  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand .rp-brand-logo-wrap,
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand .rp-brand-logo,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand .rp-brand-logo-wrap,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand .rp-brand-logo{
    width:58px!important;
    height:58px!important;
    min-width:58px!important;
    min-height:58px!important;
    border-radius:14px!important;
    background:#fff!important;
    object-fit:contain!important;
    overflow:hidden!important;
  }

  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand .rp-brand-logo,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand .rp-brand-logo{
    width:46px!important;
    height:46px!important;
    min-width:46px!important;
    min-height:46px!important;
    margin:auto!important;
    display:block!important;
  }

  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{
    display:block!important;
    opacity:1!important;
    width:auto!important;
    max-width:calc(100% - 130px)!important;
    color:#fff!important;
    font-size:12px!important;
    line-height:1.2!important;
    font-weight:400!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    margin:0!important;
  }

  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle{
    width:42px!important;
    height:42px!important;
    min-width:42px!important;
    min-height:42px!important;
    margin-left:auto!important;
    border:0!important;
    background:transparent!important;
    color:#fff!important;
    box-shadow:none!important;
    overflow:visible!important;
    border-radius:10px!important;
  }

  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle::before,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle::before{
    content:'☰'!important;
    font-size:30px!important;
    line-height:1!important;
    font-weight:400!important;
    color:#fff!important;
    display:block!important;
    transform:none!important;
  }

  body > .rp-prof-sidebar.mobile-open,
  .rp-prof-sidebar.mobile-open{
    padding:22px 18px 20px!important;
    background:#102a56!important;
  }

  body > .rp-prof-sidebar.mobile-open .rp-prof-brand,
  .rp-prof-sidebar.mobile-open .rp-prof-brand{
    min-height:68px!important;
    height:68px!important;
    margin:0 0 10px!important;
    padding:0 0 12px!important;
    gap:12px!important;
    align-items:center!important;
    overflow:visible!important;
  }

  body > .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo-wrap,
  .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo-wrap{
    width:56px!important;
    height:56px!important;
    min-width:56px!important;
    min-height:56px!important;
    border-radius:14px!important;
    overflow:hidden!important;
    background:#fff!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
  }

  body > .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo,
  .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo-wrap img,
  .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo-wrap img{
    width:44px!important;
    height:44px!important;
    min-width:44px!important;
    min-height:44px!important;
    object-fit:contain!important;
    display:block!important;
    margin:auto!important;
  }

  body > .rp-prof-sidebar.mobile-open .rp-prof-brand strong,
  .rp-prof-sidebar.mobile-open .rp-prof-brand strong{
    color:#fff!important;
    font-size:12px!important;
    line-height:1.2!important;
    font-weight:400!important;
    max-width:calc(100vw - 148px)!important;
    margin:0!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
  }

  body > .rp-prof-sidebar.mobile-open .rp-sidebar-toggle,
  .rp-prof-sidebar.mobile-open .rp-sidebar-toggle{
    width:42px!important;
    height:42px!important;
    min-width:42px!important;
    min-height:42px!important;
    margin-left:auto!important;
    overflow:visible!important;
  }

  body > .rp-prof-sidebar.mobile-open .rp-sidebar-toggle::before,
  .rp-prof-sidebar.mobile-open .rp-sidebar-toggle::before{
    content:'×'!important;
    font-size:38px!important;
    line-height:.9!important;
    font-weight:300!important;
    color:#fff!important;
  }

  body > .rp-prof-sidebar.mobile-open a,
  .rp-prof-sidebar.mobile-open a{
    min-height:38px!important;
    height:38px!important;
    margin:3px 0!important;
    padding:0 12px!important;
    border-radius:11px!important;
    gap:9px!important;
    font-size:12px!important;
    line-height:1!important;
    font-weight:400!important;
  }

  body > .rp-prof-sidebar.mobile-open .rp-nav-label,
  .rp-prof-sidebar.mobile-open .rp-nav-label{
    font-size:12px!important;
    line-height:1!important;
    font-weight:400!important;
  }

  body > .rp-prof-sidebar.mobile-open .rp-nav-icon svg,
  body > .rp-prof-sidebar.mobile-open a svg,
  .rp-prof-sidebar.mobile-open .rp-nav-icon svg,
  .rp-prof-sidebar.mobile-open a svg{
    width:16px!important;
    height:16px!important;
    min-width:16px!important;
    min-height:16px!important;
  }
}


/* v999 - Ajuste final menú móvil profesional + fondo global suave */
.rp-prof-panel{
  --rp-bg:#fbfcfe!important;
  background:linear-gradient(135deg,#ffffff 0%,#fbfcfe 48%,#f4f6f9 100%)!important;
}
.rp-prof-main,
.rp-prof-section{
  background:transparent!important;
}
.rp-kpis div,
.rp-card,
.rp-list-card,
.rp-patient-card,
.rp-table-card,
.rp-calendar-shell,
.rp-detail-card,
.rp-detail-hero,
.rp-modal-box{
  background:rgba(255,255,255,.94)!important;
}
.rp-prof-panel.rp-sidebar-expanded .rp-prof-brand strong{
  font-weight:450!important;
}

@media (max-width:760px){
  .rp-prof-panel,
  .rp-prof-panel.rp-sidebar-expanded{
    width:calc(100vw - 8px)!important;
    max-width:calc(100vw - 8px)!important;
    margin:0 auto!important;
    transform:none!important;
    border-radius:18px!important;
    overflow:hidden!important;
    background:linear-gradient(135deg,#ffffff 0%,#fbfcfe 48%,#f4f6f9 100%)!important;
  }
  .rp-prof-sidebar:not(.mobile-open){
    position:relative!important;
    top:0!important;
    width:100%!important;
    max-width:none!important;
    min-width:0!important;
    height:92px!important;
    min-height:92px!important;
    padding:12px 18px!important;
    margin:0!important;
    border:0!important;
    border-radius:0!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    display:block!important;
    overflow:hidden!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand{
    height:68px!important;
    min-height:68px!important;
    width:100%!important;
    margin:0!important;
    padding:0!important;
    display:grid!important;
    grid-template-columns:62px minmax(0,1fr) 46px!important;
    gap:12px!important;
    align-items:center!important;
    justify-content:initial!important;
    overflow:visible!important;
    background:transparent!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap,
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo{
    width:62px!important;
    height:62px!important;
    min-width:62px!important;
    border-radius:14px!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{
    display:block!important;
    opacity:1!important;
    width:auto!important;
    max-width:none!important;
    min-width:0!important;
    color:#fff!important;
    font-size:13px!important;
    font-weight:450!important;
    line-height:1.15!important;
    text-align:left!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    margin:0!important;
    padding:0!important;
    position:static!important;
    transform:none!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle{
    display:inline-grid!important;
    width:42px!important;
    height:42px!important;
    min-width:42px!important;
    border:0!important;
    background:transparent!important;
    color:#fff!important;
    border-radius:10px!important;
    place-items:center!important;
    margin:0!important;
    padding:0!important;
    font-size:0!important;
    justify-self:end!important;
    position:static!important;
    transform:none!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle::before{
    content:'☰'!important;
    font-size:31px!important;
    font-weight:400!important;
    line-height:1!important;
    color:#fff!important;
  }
  .rp-prof-sidebar:not(.mobile-open) a{display:none!important;}

  .rp-prof-sidebar.mobile-open,
  body > .rp-prof-sidebar.mobile-open{
    position:fixed!important;
    inset:0!important;
    z-index:999999!important;
    width:100vw!important;
    max-width:none!important;
    height:100dvh!important;
    min-height:100dvh!important;
    overflow-y:auto!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    padding:calc(12px + env(safe-area-inset-top)) 18px calc(18px + env(safe-area-inset-bottom))!important;
    border:0!important;
    border-radius:0!important;
    display:block!important;
  }
  .rp-prof-sidebar.mobile-open .rp-prof-brand,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand{
    height:78px!important;
    min-height:78px!important;
    width:100%!important;
    margin:0 0 10px!important;
    padding:0 0 10px!important;
    display:grid!important;
    grid-template-columns:78px minmax(0,1fr) 44px!important;
    gap:12px!important;
    align-items:center!important;
    border-bottom:1px solid rgba(255,255,255,.18)!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    overflow:visible!important;
  }
  .rp-prof-sidebar.mobile-open .rp-brand-logo-wrap,
  .rp-prof-sidebar.mobile-open .rp-brand-logo,
  body > .rp-prof-sidebar.mobile-open .rp-brand-logo-wrap,
  body > .rp-prof-sidebar.mobile-open .rp-brand-logo{
    width:72px!important;
    height:72px!important;
    min-width:72px!important;
    border-radius:14px!important;
    object-fit:contain!important;
  }
  .rp-prof-sidebar.mobile-open .rp-prof-brand strong,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand strong{
    display:block!important;
    opacity:1!important;
    width:auto!important;
    max-width:none!important;
    min-width:0!important;
    color:#fff!important;
    font-size:13px!important;
    font-weight:450!important;
    line-height:1.15!important;
    text-align:left!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    margin:0!important;
    padding:0!important;
    position:static!important;
    transform:none!important;
  }
  .rp-prof-sidebar.mobile-open .rp-sidebar-toggle,
  body > .rp-prof-sidebar.mobile-open .rp-sidebar-toggle{
    display:inline-grid!important;
    width:40px!important;
    height:40px!important;
    min-width:40px!important;
    margin:0!important;
    padding:0!important;
    border:0!important;
    border-radius:10px!important;
    background:transparent!important;
    color:#fff!important;
    place-items:center!important;
    justify-self:end!important;
    position:static!important;
    transform:none!important;
    font-size:0!important;
  }
  .rp-prof-sidebar.mobile-open .rp-sidebar-toggle::before,
  body > .rp-prof-sidebar.mobile-open .rp-sidebar-toggle::before{
    content:'×'!important;
    color:#fff!important;
    font-size:42px!important;
    line-height:1!important;
    font-weight:300!important;
  }
  .rp-prof-sidebar.mobile-open a,
  body > .rp-prof-sidebar.mobile-open a{
    display:flex!important;
    width:100%!important;
    max-width:none!important;
    height:42px!important;
    min-height:42px!important;
    margin:3px 0!important;
    padding:0 13px!important;
    border-radius:12px!important;
    gap:10px!important;
    justify-content:flex-start!important;
    align-items:center!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    border:1px solid rgba(255,255,255,.18)!important;
    color:#fff!important;
    box-shadow:none!important;
    text-decoration:none!important;
    overflow:hidden!important;
  }
  .rp-prof-sidebar.mobile-open a.active,
  .rp-prof-sidebar.mobile-open a:hover,
  body > .rp-prof-sidebar.mobile-open a.active,
  body > .rp-prof-sidebar.mobile-open a:hover{
    background:#0B8FB4!important;
    border-color:#0B8FB4!important;
    color:#fff!important;
  }
  .rp-prof-sidebar.mobile-open .rp-nav-label,
  body > .rp-prof-sidebar.mobile-open .rp-nav-label{
    display:inline-block!important;
    opacity:1!important;
    width:auto!important;
    max-width:none!important;
    color:#fff!important;
    font-size:12px!important;
    line-height:1!important;
    font-weight:400!important;
    white-space:nowrap!important;
  }
  .rp-prof-sidebar.mobile-open .rp-nav-icon,
  body > .rp-prof-sidebar.mobile-open .rp-nav-icon{
    width:17px!important;
    height:17px!important;
    min-width:17px!important;
    flex:0 0 17px!important;
    color:#fff!important;
  }
  .rp-prof-sidebar.mobile-open .rp-nav-icon svg,
  .rp-prof-sidebar.mobile-open a svg,
  body > .rp-prof-sidebar.mobile-open .rp-nav-icon svg,
  body > .rp-prof-sidebar.mobile-open a svg{
    width:17px!important;
    height:17px!important;
    min-width:17px!important;
    min-height:17px!important;
    stroke:#fff!important;
    fill:none!important;
    stroke-width:1.65!important;
  }
}


/* v1001 - Ajuste quirúrgico final menú móvil Mi consultorio + evitar precarga desktop */
@media (min-width:761px){
  .rp-prof-panel,
  .rp-prof-panel.rp-sidebar-expanded{
    display:grid!important;
    grid-template-columns:var(--rp-sidebar-closed) minmax(0,1fr)!important;
    width:min(1280px, calc(100vw - 32px))!important;
    max-width:min(1280px, calc(100vw - 32px))!important;
    min-height:calc(100vh - 80px)!important;
    margin-left:50%!important;
    margin-right:0!important;
    transform:translateX(-50%)!important;
    border-radius:18px!important;
    overflow:hidden!important;
  }
  .rp-prof-panel.rp-sidebar-expanded{grid-template-columns:var(--rp-sidebar-open) minmax(0,1fr)!important;}
  .rp-prof-sidebar,
  .rp-prof-sidebar:not(.mobile-open),
  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open){
    position:relative!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;
    width:var(--rp-sidebar-closed)!important;
    max-width:none!important;
    min-width:0!important;
    height:auto!important;
    min-height:0!important;
    margin:0!important;
    padding:18px 10px!important;
    border-radius:0!important;
    background:#fff!important;
    border-right:1px solid var(--rp-border)!important;
    display:flex!important;
    flex-direction:column!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:8px!important;
    overflow:hidden!important;
    box-shadow:none!important;
  }
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open){
    width:var(--rp-sidebar-open)!important;
    padding:18px 16px!important;
    align-items:stretch!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand,
  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:100%!important;
    height:58px!important;
    min-height:58px!important;
    margin:0 0 18px!important;
    padding:0!important;
    gap:12px!important;
    overflow:hidden!important;
    background:transparent!important;
    border:0!important;
  }
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand{justify-content:flex-start!important;}
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap,
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo{
    width:50px!important;
    height:50px!important;
    min-width:50px!important;
    border-radius:12px!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{
    color:var(--rp-text)!important;
    font-size:16px!important;
    line-height:1.2!important;
    font-weight:450!important;
    opacity:0!important;
    max-width:0!important;
    width:0!important;
    overflow:hidden!important;
    white-space:nowrap!important;
    position:static!important;
    transform:none!important;
  }
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{
    opacity:1!important;
    max-width:200px!important;
    width:auto!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle{display:none!important;}
  .rp-prof-sidebar:not(.mobile-open) a{
    display:flex!important;
    width:52px!important;
    height:52px!important;
    min-height:52px!important;
    margin:2px auto!important;
    padding:0!important;
    justify-content:center!important;
    gap:0!important;
    font-size:0!important;
    border:0!important;
    background:transparent!important;
    color:#344054!important;
  }
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) a{
    width:100%!important;
    height:40px!important;
    min-height:40px!important;
    margin:1px 0!important;
    padding:0 12px!important;
    justify-content:flex-start!important;
    gap:10px!important;
    font-size:13px!important;
  }
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-nav-label{
    opacity:1!important;
    max-width:190px!important;
    width:auto!important;
    display:inline-block!important;
    font-size:13px!important;
    font-weight:400!important;
  }
}

@media (max-width:760px){
  .rp-prof-panel,
  .rp-prof-panel.rp-sidebar-expanded{
    width:calc(100vw - 8px)!important;
    max-width:calc(100vw - 8px)!important;
    margin:0 auto!important;
    transform:none!important;
    border-radius:18px!important;
    overflow:hidden!important;
  }
  .rp-prof-sidebar:not(.mobile-open),
  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open){
    width:100%!important;
    max-width:none!important;
    min-width:0!important;
    height:92px!important;
    min-height:92px!important;
    margin:0!important;
    padding:12px 18px!important;
    border-radius:0!important;
    border:0!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    display:block!important;
    position:relative!important;
    overflow:hidden!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand,
  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand{
    display:grid!important;
    grid-template-columns:62px minmax(0,1fr) 44px!important;
    gap:12px!important;
    align-items:center!important;
    justify-items:stretch!important;
    width:100%!important;
    height:68px!important;
    min-height:68px!important;
    margin:0!important;
    padding:0!important;
    position:static!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;
    transform:none!important;
    background:transparent!important;
    overflow:visible!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap,
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo{
    width:62px!important;
    height:62px!important;
    min-width:62px!important;
    border-radius:14px!important;
    align-self:center!important;
    justify-self:start!important;
    position:static!important;
    transform:none!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{
    display:block!important;
    opacity:1!important;
    max-width:100%!important;
    width:auto!important;
    min-width:0!important;
    color:#fff!important;
    font-size:13px!important;
    font-weight:400!important;
    line-height:1.15!important;
    text-align:left!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    margin:0!important;
    padding:0!important;
    position:static!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;
    transform:none!important;
    align-self:center!important;
    justify-self:start!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle{
    display:grid!important;
    place-items:center!important;
    justify-self:end!important;
    align-self:center!important;
    width:44px!important;
    height:44px!important;
    min-width:44px!important;
    min-height:44px!important;
    margin:0!important;
    padding:0!important;
    border:0!important;
    border-radius:10px!important;
    background:transparent!important;
    color:#fff!important;
    font-size:0!important;
    line-height:1!important;
    position:static!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;
    transform:none!important;
    box-shadow:none!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle::before{
    content:'☰'!important;
    font-size:31px!important;
    line-height:1!important;
    font-weight:400!important;
    color:#fff!important;
  }
  .rp-prof-sidebar:not(.mobile-open) a{display:none!important;}

  .rp-prof-sidebar.mobile-open,
  body > .rp-prof-sidebar.mobile-open{
    position:fixed!important;
    inset:0!important;
    z-index:999999!important;
    width:100vw!important;
    max-width:none!important;
    height:100dvh!important;
    min-height:100dvh!important;
    overflow-y:auto!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    padding:calc(12px + env(safe-area-inset-top)) 18px calc(18px + env(safe-area-inset-bottom))!important;
    border:0!important;
    border-radius:0!important;
    display:block!important;
  }
  .rp-prof-sidebar.mobile-open .rp-prof-brand,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand{
    display:grid!important;
    grid-template-columns:72px minmax(0,1fr) 42px!important;
    gap:12px!important;
    align-items:center!important;
    width:100%!important;
    height:72px!important;
    min-height:72px!important;
    margin:0 0 8px!important;
    padding:0 0 8px!important;
    border-bottom:1px solid rgba(255,255,255,.18)!important;
    overflow:visible!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    position:static!important;
    transform:none!important;
  }
  .rp-prof-sidebar.mobile-open .rp-brand-logo-wrap,
  .rp-prof-sidebar.mobile-open .rp-brand-logo,
  body > .rp-prof-sidebar.mobile-open .rp-brand-logo-wrap,
  body > .rp-prof-sidebar.mobile-open .rp-brand-logo{
    width:66px!important;
    height:66px!important;
    min-width:66px!important;
    border-radius:14px!important;
    justify-self:start!important;
    align-self:center!important;
    object-fit:contain!important;
  }
  .rp-prof-sidebar.mobile-open .rp-prof-brand strong,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand strong{
    display:block!important;
    opacity:1!important;
    color:#fff!important;
    font-size:13px!important;
    font-weight:400!important;
    line-height:1.15!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    max-width:100%!important;
    width:auto!important;
    min-width:0!important;
    margin:0!important;
    padding:0!important;
    position:static!important;
    transform:none!important;
    justify-self:start!important;
    align-self:center!important;
  }
  .rp-prof-sidebar.mobile-open .rp-sidebar-toggle,
  body > .rp-prof-sidebar.mobile-open .rp-sidebar-toggle{
    display:grid!important;
    width:42px!important;
    height:42px!important;
    min-width:42px!important;
    min-height:42px!important;
    margin:0!important;
    padding:0!important;
    border:0!important;
    border-radius:10px!important;
    background:transparent!important;
    color:#fff!important;
    place-items:center!important;
    justify-self:end!important;
    align-self:center!important;
    position:static!important;
    transform:none!important;
    font-size:0!important;
  }
  .rp-prof-sidebar.mobile-open .rp-sidebar-toggle::before,
  body > .rp-prof-sidebar.mobile-open .rp-sidebar-toggle::before{
    content:'×'!important;
    color:#fff!important;
    font-size:38px!important;
    line-height:1!important;
    font-weight:300!important;
  }
  .rp-prof-sidebar.mobile-open a,
  body > .rp-prof-sidebar.mobile-open a{
    display:flex!important;
    width:100%!important;
    height:38px!important;
    min-height:38px!important;
    margin:3px 0!important;
    padding:0 12px!important;
    border-radius:11px!important;
    gap:9px!important;
    align-items:center!important;
    justify-content:flex-start!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    border:1px solid rgba(255,255,255,.18)!important;
    color:#fff!important;
    box-shadow:none!important;
    text-decoration:none!important;
    overflow:hidden!important;
  }
  .rp-prof-sidebar.mobile-open a.active,
  .rp-prof-sidebar.mobile-open a:hover,
  body > .rp-prof-sidebar.mobile-open a.active,
  body > .rp-prof-sidebar.mobile-open a:hover{
    background:#0B8FB4!important;
    border-color:#0B8FB4!important;
    color:#fff!important;
  }
  .rp-prof-sidebar.mobile-open .rp-nav-label,
  body > .rp-prof-sidebar.mobile-open .rp-nav-label{
    display:inline-block!important;
    opacity:1!important;
    width:auto!important;
    max-width:none!important;
    color:#fff!important;
    font-size:12px!important;
    line-height:1!important;
    font-weight:400!important;
    white-space:nowrap!important;
  }
}


/* v1002 - Corrección definitiva: menú móvil centrado, hamburguesa al margen y sin precarga fea en PC */
@media (min-width:761px){
  .rp-prof-panel,
  .rp-prof-panel.rp-sidebar-expanded{
    display:grid!important;
    grid-template-columns:var(--rp-sidebar-closed) minmax(0,1fr)!important;
    width:min(1280px, calc(100vw - 32px))!important;
    max-width:min(1280px, calc(100vw - 32px))!important;
    min-height:calc(100vh - 80px)!important;
    margin-left:50%!important;
    margin-right:0!important;
    transform:translateX(-50%)!important;
    border-radius:18px!important;
    overflow:hidden!important;
    background:linear-gradient(135deg,#ffffff 0%,#fbfcfe 48%,#f4f6f9 100%)!important;
  }
  .rp-prof-panel.rp-sidebar-expanded{grid-template-columns:var(--rp-sidebar-open) minmax(0,1fr)!important;}
  .rp-prof-sidebar,
  .rp-prof-sidebar:not(.mobile-open),
  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open){
    position:relative!important;
    width:var(--rp-sidebar-closed)!important;
    max-width:none!important;
    min-width:0!important;
    height:auto!important;
    min-height:0!important;
    margin:0!important;
    padding:18px 10px!important;
    border-radius:0!important;
    background:#fff!important;
    border-right:1px solid var(--rp-border)!important;
    display:flex!important;
    flex-direction:column!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:8px!important;
    overflow:hidden!important;
    box-shadow:none!important;
  }
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open){
    width:var(--rp-sidebar-open)!important;
    padding:18px 16px!important;
    align-items:stretch!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand,
  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    width:100%!important;
    height:58px!important;
    min-height:58px!important;
    margin:0 0 18px!important;
    padding:0!important;
    gap:12px!important;
    overflow:hidden!important;
    background:transparent!important;
    border:0!important;
    position:relative!important;
    transform:none!important;
  }
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand{justify-content:flex-start!important;}
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap,
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo{
    width:50px!important;
    height:50px!important;
    min-width:50px!important;
    border-radius:12px!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{
    color:var(--rp-text)!important;
    font-size:16px!important;
    line-height:1.2!important;
    font-weight:450!important;
    opacity:0!important;
    max-width:0!important;
    width:0!important;
    overflow:hidden!important;
    white-space:nowrap!important;
    position:static!important;
    transform:none!important;
  }
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{
    opacity:1!important;
    max-width:200px!important;
    width:auto!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle{display:none!important;}
}
@media (max-width:760px){
  .rp-prof-panel,
  .rp-prof-panel.rp-sidebar-expanded{
    display:block!important;
    width:calc(100vw - 8px)!important;
    max-width:calc(100vw - 8px)!important;
    margin:0 auto!important;
    transform:none!important;
    border-radius:18px!important;
    overflow:hidden!important;
    background:linear-gradient(135deg,#ffffff 0%,#fbfcfe 48%,#f4f6f9 100%)!important;
  }
  .rp-prof-sidebar:not(.mobile-open),
  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open){
    width:100%!important;
    max-width:none!important;
    min-width:0!important;
    height:92px!important;
    min-height:92px!important;
    margin:0!important;
    padding:12px 18px!important;
    border-radius:0!important;
    border:0!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    display:block!important;
    position:relative!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand,
  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand{
    display:block!important;
    width:100%!important;
    height:68px!important;
    min-height:68px!important;
    margin:0!important;
    padding:0!important;
    position:relative!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;
    transform:none!important;
    background:transparent!important;
    overflow:visible!important;
    box-sizing:border-box!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap,
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo{
    position:absolute!important;
    left:0!important;
    top:50%!important;
    transform:translateY(-50%)!important;
    width:62px!important;
    height:62px!important;
    min-width:62px!important;
    min-height:62px!important;
    border-radius:14px!important;
    margin:0!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{
    display:block!important;
    opacity:1!important;
    width:auto!important;
    max-width:calc(100% - 132px)!important;
    color:#fff!important;
    font-size:13px!important;
    font-weight:400!important;
    line-height:1.15!important;
    text-align:center!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    margin:0!important;
    padding:0!important;
    position:absolute!important;
    left:50%!important;
    top:50%!important;
    transform:translate(-50%,-50%)!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle{
    display:grid!important;
    place-items:center!important;
    width:44px!important;
    height:44px!important;
    min-width:44px!important;
    min-height:44px!important;
    margin:0!important;
    padding:0!important;
    border:0!important;
    border-radius:10px!important;
    background:transparent!important;
    color:#fff!important;
    font-size:0!important;
    line-height:1!important;
    position:absolute!important;
    right:0!important;
    top:50%!important;
    transform:translateY(-50%)!important;
    box-shadow:none!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle::before{
    content:'☰'!important;
    font-size:31px!important;
    line-height:1!important;
    font-weight:400!important;
    color:#fff!important;
  }
  .rp-prof-sidebar:not(.mobile-open) a{display:none!important;}

  .rp-prof-sidebar.mobile-open,
  body > .rp-prof-sidebar.mobile-open{
    position:fixed!important;
    inset:0!important;
    z-index:999999!important;
    width:100vw!important;
    max-width:none!important;
    height:100dvh!important;
    min-height:100dvh!important;
    overflow-y:auto!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    padding:calc(12px + env(safe-area-inset-top)) 18px calc(18px + env(safe-area-inset-bottom))!important;
    border:0!important;
    border-radius:0!important;
    display:block!important;
    box-sizing:border-box!important;
  }
  .rp-prof-sidebar.mobile-open .rp-prof-brand,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand{
    display:block!important;
    width:100%!important;
    height:72px!important;
    min-height:72px!important;
    margin:0 0 8px!important;
    padding:0 0 8px!important;
    border-bottom:1px solid rgba(255,255,255,.18)!important;
    overflow:visible!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    position:relative!important;
    transform:none!important;
    box-sizing:border-box!important;
  }
  .rp-prof-sidebar.mobile-open .rp-brand-logo-wrap,
  .rp-prof-sidebar.mobile-open .rp-brand-logo,
  body > .rp-prof-sidebar.mobile-open .rp-brand-logo-wrap,
  body > .rp-prof-sidebar.mobile-open .rp-brand-logo{
    position:absolute!important;
    left:0!important;
    top:50%!important;
    transform:translateY(-50%)!important;
    width:66px!important;
    height:66px!important;
    min-width:66px!important;
    min-height:66px!important;
    border-radius:14px!important;
    object-fit:contain!important;
    margin:0!important;
  }
  .rp-prof-sidebar.mobile-open .rp-prof-brand strong,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand strong{
    display:block!important;
    opacity:1!important;
    color:#fff!important;
    font-size:13px!important;
    font-weight:400!important;
    line-height:1.15!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    max-width:calc(100% - 126px)!important;
    width:auto!important;
    margin:0!important;
    padding:0!important;
    position:absolute!important;
    left:78px!important;
    top:50%!important;
    transform:translateY(-50%)!important;
    text-align:left!important;
  }
  .rp-prof-sidebar.mobile-open .rp-sidebar-toggle,
  body > .rp-prof-sidebar.mobile-open .rp-sidebar-toggle{
    display:grid!important;
    width:42px!important;
    height:42px!important;
    min-width:42px!important;
    min-height:42px!important;
    margin:0!important;
    padding:0!important;
    border:0!important;
    border-radius:10px!important;
    background:transparent!important;
    color:#fff!important;
    place-items:center!important;
    position:absolute!important;
    right:0!important;
    top:50%!important;
    transform:translateY(-50%)!important;
    font-size:0!important;
  }
  .rp-prof-sidebar.mobile-open .rp-sidebar-toggle::before,
  body > .rp-prof-sidebar.mobile-open .rp-sidebar-toggle::before{
    content:'×'!important;
    color:#fff!important;
    font-size:38px!important;
    line-height:1!important;
    font-weight:300!important;
  }
  .rp-prof-sidebar.mobile-open a,
  body > .rp-prof-sidebar.mobile-open a{
    display:flex!important;
    width:100%!important;
    height:38px!important;
    min-height:38px!important;
    margin:3px 0!important;
    padding:0 12px!important;
    border-radius:11px!important;
    gap:9px!important;
    align-items:center!important;
    justify-content:flex-start!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    border:1px solid rgba(255,255,255,.18)!important;
    color:#fff!important;
    box-shadow:none!important;
    text-decoration:none!important;
    overflow:hidden!important;
    font-size:12px!important;
    font-weight:400!important;
  }
  .rp-prof-sidebar.mobile-open a.active,
  .rp-prof-sidebar.mobile-open a:hover,
  body > .rp-prof-sidebar.mobile-open a.active,
  body > .rp-prof-sidebar.mobile-open a:hover{
    background:#0B8FB4!important;
    border-color:#0B8FB4!important;
    color:#fff!important;
  }
  .rp-prof-sidebar.mobile-open .rp-nav-label,
  body > .rp-prof-sidebar.mobile-open .rp-nav-label{
    display:inline-block!important;
    opacity:1!important;
    width:auto!important;
    max-width:none!important;
    color:#fff!important;
    font-size:12px!important;
    line-height:1!important;
    font-weight:400!important;
    white-space:nowrap!important;
  }
  .rp-prof-sidebar.mobile-open .rp-nav-icon,
  body > .rp-prof-sidebar.mobile-open .rp-nav-icon{
    width:17px!important;
    height:17px!important;
    min-width:17px!important;
    flex:0 0 17px!important;
    color:#fff!important;
  }
  .rp-prof-sidebar.mobile-open .rp-nav-icon svg,
  .rp-prof-sidebar.mobile-open a svg,
  body > .rp-prof-sidebar.mobile-open .rp-nav-icon svg,
  body > .rp-prof-sidebar.mobile-open a svg{
    width:17px!important;
    height:17px!important;
    min-width:17px!important;
    min-height:17px!important;
    stroke:#fff!important;
    fill:none!important;
    stroke-width:1.65!important;
  }
}

/* v1003 - RedPsico menu definitivo: sidebar azul PC, mobile alineado y sin precarga vieja */
.rp-prof-panel{
  background:linear-gradient(135deg,#ffffff 0%,#fbfcfe 50%,#f4f6f9 100%)!important;
}
.rp-prof-main,
.rp-prof-section{background:transparent!important;}
.rp-kpis div,.rp-card,.rp-list-card,.rp-patient-card,.rp-table-card,.rp-calendar-shell,.rp-detail-card,.rp-detail-hero,.rp-modal-box{background:rgba(255,255,255,.94)!important;}

@media (min-width:761px){
  .rp-prof-panel,
  .rp-prof-panel.rp-sidebar-expanded{
    display:grid!important;
    grid-template-columns:78px minmax(0,1fr)!important;
    width:min(1280px, calc(100vw - 32px))!important;
    max-width:min(1280px, calc(100vw - 32px))!important;
    min-height:calc(100vh - 80px)!important;
    margin:24px auto!important;
    transform:none!important;
    border-radius:18px!important;
    overflow:hidden!important;
    background:linear-gradient(135deg,#ffffff 0%,#fbfcfe 50%,#f4f6f9 100%)!important;
  }
  .rp-prof-panel.rp-sidebar-expanded{grid-template-columns:280px minmax(0,1fr)!important;}
  .rp-prof-sidebar,
  .rp-prof-sidebar:not(.mobile-open),
  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open){
    position:relative!important;
    top:auto!important;left:auto!important;right:auto!important;
    width:78px!important;max-width:none!important;min-width:78px!important;
    height:auto!important;min-height:0!important;
    margin:0!important;padding:18px 10px!important;
    border-radius:0!important;border:0!important;border-right:1px solid rgba(255,255,255,.12)!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;color:#fff!important;
    display:flex!important;flex-direction:column!important;align-items:center!important;justify-content:flex-start!important;
    gap:8px!important;overflow:hidden!important;box-shadow:none!important;
  }
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open){
    width:280px!important;min-width:280px!important;padding:18px 16px!important;align-items:stretch!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand,
  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand{
    display:flex!important;align-items:center!important;justify-content:center!important;
    width:100%!important;height:58px!important;min-height:58px!important;
    margin:0 0 18px!important;padding:0!important;gap:12px!important;
    overflow:hidden!important;background:transparent!important;border:0!important;box-shadow:none!important;
    position:relative!important;transform:none!important;
  }
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand{justify-content:flex-start!important;}
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap{
    width:50px!important;height:50px!important;min-width:50px!important;min-height:50px!important;border-radius:12px!important;background:#fff!important;display:flex!important;align-items:center!important;justify-content:center!important;overflow:hidden!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo,
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap img{
    width:42px!important;height:42px!important;min-width:42px!important;min-height:42px!important;object-fit:contain!important;margin:auto!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{
    color:#fff!important;font-size:14px!important;line-height:1.2!important;font-weight:450!important;
    opacity:0!important;max-width:0!important;width:0!important;overflow:hidden!important;white-space:nowrap!important;position:static!important;transform:none!important;
  }
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{opacity:1!important;max-width:190px!important;width:auto!important;}
  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle{display:none!important;}
  .rp-prof-sidebar:not(.mobile-open) a{
    display:flex!important;width:52px!important;height:52px!important;min-height:52px!important;margin:2px auto!important;padding:0!important;border-radius:16px!important;justify-content:center!important;align-items:center!important;gap:0!important;font-size:0!important;border:0!important;background:transparent!important;color:rgba(255,255,255,.80)!important;box-shadow:none!important;text-decoration:none!important;overflow:hidden!important;
  }
  .rp-prof-sidebar:not(.mobile-open) a.active,.rp-prof-sidebar:not(.mobile-open) a:hover{background:#0B8FB4!important;color:#fff!important;}
  .rp-prof-sidebar:not(.mobile-open) .rp-nav-label{opacity:0!important;max-width:0!important;width:0!important;overflow:hidden!important;font-size:0!important;}
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) a{
    width:100%!important;height:40px!important;min-height:40px!important;margin:1px 0!important;padding:0 12px!important;justify-content:flex-start!important;gap:10px!important;font-size:13px!important;border-radius:12px!important;
  }
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-nav-label{opacity:1!important;max-width:190px!important;width:auto!important;display:inline-block!important;font-size:13px!important;font-weight:400!important;color:#fff!important;}
  .rp-prof-sidebar:not(.mobile-open) .rp-nav-icon svg,.rp-prof-sidebar:not(.mobile-open) a svg{stroke:currentColor!important;fill:none!important;width:18px!important;height:18px!important;}
}

@media (max-width:760px){
  .rp-prof-panel,
  .rp-prof-panel.rp-sidebar-expanded{
    display:block!important;width:calc(100vw - 8px)!important;max-width:calc(100vw - 8px)!important;margin:0 auto!important;transform:none!important;border-radius:18px!important;overflow:hidden!important;background:linear-gradient(135deg,#ffffff 0%,#fbfcfe 50%,#f4f6f9 100%)!important;
  }
  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open),
  .rp-prof-sidebar:not(.mobile-open){
    width:100%!important;max-width:none!important;min-width:0!important;height:92px!important;min-height:92px!important;margin:0!important;padding:12px 18px!important;border-radius:0!important;border:0!important;background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;display:block!important;position:relative!important;overflow:hidden!important;box-sizing:border-box!important;color:#fff!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand,
  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand{
    display:grid!important;grid-template-columns:62px 1fr 44px!important;gap:12px!important;align-items:center!important;width:100%!important;height:68px!important;min-height:68px!important;margin:0!important;padding:0!important;background:transparent!important;position:relative!important;overflow:visible!important;box-sizing:border-box!important;transform:none!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap{
    grid-column:1!important;justify-self:start!important;align-self:center!important;position:static!important;transform:none!important;width:62px!important;height:62px!important;min-width:62px!important;min-height:62px!important;border-radius:14px!important;background:#fff!important;display:flex!important;align-items:center!important;justify-content:center!important;overflow:hidden!important;margin:0!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo,
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap img{
    width:48px!important;height:48px!important;min-width:48px!important;min-height:48px!important;object-fit:contain!important;margin:auto!important;position:static!important;transform:none!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{
    grid-column:2!important;justify-self:center!important;align-self:center!important;display:block!important;opacity:1!important;color:#fff!important;font-size:13px!important;font-weight:400!important;line-height:1.15!important;text-align:center!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;max-width:100%!important;width:auto!important;min-width:0!important;margin:0!important;padding:0!important;position:static!important;transform:none!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle{
    grid-column:3!important;justify-self:end!important;align-self:center!important;display:grid!important;place-items:center!important;width:44px!important;height:44px!important;min-width:44px!important;min-height:44px!important;margin:0!important;padding:0!important;border:0!important;border-radius:10px!important;background:transparent!important;color:#fff!important;font-size:0!important;line-height:1!important;position:static!important;transform:none!important;box-shadow:none!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle::before{content:'☰'!important;font-size:31px!important;line-height:1!important;font-weight:400!important;color:#fff!important;}
  .rp-prof-sidebar:not(.mobile-open) a{display:none!important;}

  .rp-prof-sidebar.mobile-open,body > .rp-prof-sidebar.mobile-open{
    position:fixed!important;inset:0!important;z-index:999999!important;width:100vw!important;max-width:none!important;height:100dvh!important;min-height:100dvh!important;overflow-y:auto!important;background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;padding:calc(12px + env(safe-area-inset-top)) 18px calc(18px + env(safe-area-inset-bottom))!important;border:0!important;border-radius:0!important;display:block!important;box-sizing:border-box!important;color:#fff!important;
  }
  .rp-prof-sidebar.mobile-open .rp-prof-brand,body > .rp-prof-sidebar.mobile-open .rp-prof-brand{
    display:grid!important;grid-template-columns:72px 1fr 42px!important;gap:12px!important;align-items:center!important;width:100%!important;height:72px!important;min-height:72px!important;margin:0 0 8px!important;padding:0 0 8px!important;border-bottom:1px solid rgba(255,255,255,.18)!important;background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;position:relative!important;overflow:visible!important;box-sizing:border-box!important;transform:none!important;
  }
  .rp-prof-sidebar.mobile-open .rp-brand-logo-wrap,body > .rp-prof-sidebar.mobile-open .rp-brand-logo-wrap{
    grid-column:1!important;justify-self:start!important;align-self:center!important;position:static!important;transform:none!important;width:66px!important;height:66px!important;min-width:66px!important;min-height:66px!important;border-radius:14px!important;background:#fff!important;display:flex!important;align-items:center!important;justify-content:center!important;overflow:hidden!important;margin:0!important;
  }
  .rp-prof-sidebar.mobile-open .rp-brand-logo,.rp-prof-sidebar.mobile-open .rp-brand-logo-wrap img,body > .rp-prof-sidebar.mobile-open .rp-brand-logo,body > .rp-prof-sidebar.mobile-open .rp-brand-logo-wrap img{
    width:50px!important;height:50px!important;min-width:50px!important;min-height:50px!important;object-fit:contain!important;margin:auto!important;position:static!important;transform:none!important;
  }
  .rp-prof-sidebar.mobile-open .rp-prof-brand strong,body > .rp-prof-sidebar.mobile-open .rp-prof-brand strong{
    grid-column:2!important;justify-self:start!important;align-self:center!important;display:block!important;opacity:1!important;color:#fff!important;font-size:13px!important;font-weight:400!important;line-height:1.15!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;max-width:100%!important;width:auto!important;min-width:0!important;margin:0!important;padding:0!important;position:static!important;transform:none!important;text-align:left!important;
  }
  .rp-prof-sidebar.mobile-open .rp-sidebar-toggle,body > .rp-prof-sidebar.mobile-open .rp-sidebar-toggle{
    grid-column:3!important;justify-self:end!important;align-self:center!important;display:grid!important;width:42px!important;height:42px!important;min-width:42px!important;min-height:42px!important;margin:0!important;padding:0!important;border:0!important;border-radius:10px!important;background:transparent!important;color:#fff!important;place-items:center!important;position:static!important;transform:none!important;font-size:0!important;
  }
  .rp-prof-sidebar.mobile-open .rp-sidebar-toggle::before,body > .rp-prof-sidebar.mobile-open .rp-sidebar-toggle::before{content:'×'!important;color:#fff!important;font-size:38px!important;line-height:1!important;font-weight:300!important;}
  .rp-prof-sidebar.mobile-open a,body > .rp-prof-sidebar.mobile-open a{
    display:flex!important;width:100%!important;height:38px!important;min-height:38px!important;margin:3px 0!important;padding:0 12px!important;border-radius:11px!important;gap:9px!important;align-items:center!important;justify-content:flex-start!important;background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;border:1px solid rgba(255,255,255,.18)!important;color:#fff!important;box-shadow:none!important;text-decoration:none!important;overflow:hidden!important;font-size:12px!important;font-weight:400!important;
  }
  .rp-prof-sidebar.mobile-open a.active,.rp-prof-sidebar.mobile-open a:hover,body > .rp-prof-sidebar.mobile-open a.active,body > .rp-prof-sidebar.mobile-open a:hover{background:#0B8FB4!important;border-color:#0B8FB4!important;color:#fff!important;}
  .rp-prof-sidebar.mobile-open .rp-nav-label,body > .rp-prof-sidebar.mobile-open .rp-nav-label{display:inline-block!important;opacity:1!important;width:auto!important;max-width:none!important;color:#fff!important;font-size:12px!important;line-height:1!important;font-weight:400!important;white-space:nowrap!important;}
  .rp-prof-sidebar.mobile-open .rp-nav-icon,body > .rp-prof-sidebar.mobile-open .rp-nav-icon{width:17px!important;height:17px!important;min-width:17px!important;flex:0 0 17px!important;color:#fff!important;}
  .rp-prof-sidebar.mobile-open .rp-nav-icon svg,.rp-prof-sidebar.mobile-open a svg,body > .rp-prof-sidebar.mobile-open .rp-nav-icon svg,body > .rp-prof-sidebar.mobile-open a svg{width:17px!important;height:17px!important;min-width:17px!important;min-height:17px!important;stroke:#fff!important;fill:none!important;stroke-width:1.65!important;}
}

/* v1004 - Ajustes finales pedidos: PC centrado, menú móvil alineado y disponibilidad sin cuadros extra */
@media (min-width:761px){
  .rp-prof-panel,
  .rp-prof-panel.rp-sidebar-expanded{
    width:calc(100vw - 48px)!important;
    max-width:1280px!important;
    margin-left:auto!important;
    margin-right:auto!important;
    transform:none!important;
  }
  .rp-prof-main{
    min-width:0!important;
    overflow:hidden!important;
  }
}

@media (max-width:760px){
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand,
  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand{
    grid-template-columns:62px minmax(0,1fr) 44px!important;
    align-items:center!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong,
  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{
    font-size:18px!important;
    line-height:1.15!important;
    font-weight:400!important;
    align-self:center!important;
    transform:translateY(4px)!important;
    text-align:center!important;
    justify-self:center!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle,
  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle{
    justify-self:end!important;
    margin-left:auto!important;
    right:auto!important;
  }
}

.rp-prof-panel .rp-unavailable-day-picker{
  background:rgba(255,255,255,.08)!important;
  border:1px solid rgba(255,255,255,.14)!important;
  border-radius:14px!important;
  padding:14px!important;
}
.rp-prof-panel .rp-unavailable-day-checks{
  display:flex!important;
  flex-wrap:wrap!important;
  gap:10px 16px!important;
  align-items:center!important;
}
.rp-prof-panel .rp-unavailable-day-checks label{
  background:transparent!important;
  border:0!important;
  box-shadow:none!important;
  border-radius:0!important;
  padding:0!important;
  min-height:0!important;
  color:#fff!important;
  font-size:13px!important;
  font-weight:400!important;
}
.rp-prof-panel .rp-unavailable-day-checks label:hover{
  background:transparent!important;
}
.rp-prof-panel .rp-unavailable-day-checks input{
  width:16px!important;
  height:16px!important;
  min-width:16px!important;
  min-height:16px!important;
  margin:0!important;
  accent-color:#5ec7d7!important;
}

/* v1005 - Ajuste quirúrgico final: centrar layout PC y bajar solo título móvil */
@media (min-width:761px){
  html body .rp-prof-panel,
  html body .rp-prof-panel.rp-sidebar-expanded{
    width:calc(100vw - 32px)!important;
    max-width:none!important;
    box-sizing:border-box!important;
    position:relative!important;
    left:50%!important;
    right:auto!important;
    margin-left:calc(-50vw + 16px)!important;
    margin-right:0!important;
    transform:none!important;
  }
  html body .rp-prof-main{
    width:100%!important;
    max-width:none!important;
    min-width:0!important;
    box-sizing:border-box!important;
    overflow-x:hidden!important;
  }
}

@media (max-width:760px){
  html body .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong,
  html body .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{
    transform:translateY(9px)!important;
    padding-top:0!important;
    margin-top:0!important;
  }
}

/* v1006 - Disponibilidad: limpiar cuadros internos y historial con filtros/paginación */
.rp-prof-panel .rp-unavailable-day-picker{
  background:transparent!important;
  border:0!important;
  box-shadow:none!important;
  border-radius:0!important;
  padding:0!important;
  margin:12px 0 18px!important;
}
.rp-prof-panel .rp-unavailable-day-picker>strong{
  font-weight:450!important;
  font-size:15px!important;
  margin-bottom:12px!important;
}
.rp-prof-panel .rp-unavailable-day-checks{
  padding:0!important;
  gap:14px 22px!important;
}
.rp-prof-panel .rp-unavailable-day-checks label{
  background:transparent!important;
  border:0!important;
  box-shadow:none!important;
  padding:0!important;
  border-radius:0!important;
  font-weight:400!important;
}
.rp-prof-panel .rp-unavailable-day{
  background:transparent!important;
  border:1px solid rgba(255,255,255,.14)!important;
  box-shadow:none!important;
}
.rp-prof-panel .rp-unavailable-row{
  background:transparent!important;
  border:0!important;
  box-shadow:none!important;
  border-radius:0!important;
  padding:8px 0!important;
}
.rp-prof-panel .rp-unavailable-row input,
.rp-prof-panel .rp-unavailable-row select{
  border-radius:10px!important;
}
.rp-prof-panel .rp-session-history-status-filters{
  display:flex!important;
  flex-wrap:wrap!important;
  gap:8px!important;
  margin-top:8px!important;
}
.rp-prof-panel .rp-session-history-status-filters button,
.rp-prof-panel .rp-history-pagination button{
  border:1px solid #d7e0ea!important;
  background:#fff!important;
  color:#2f3b4d!important;
  border-radius:999px!important;
  padding:7px 12px!important;
  font-size:13px!important;
  font-weight:450!important;
  cursor:pointer!important;
}
.rp-prof-panel .rp-session-history-status-filters button.is-active{
  background:#123263!important;
  border-color:#123263!important;
  color:#fff!important;
}
.rp-prof-panel .rp-history-pagination{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  margin:12px 0 2px;
  font-size:13px;
  color:#637083;
}
.rp-prof-panel .rp-history-pagination button:disabled{
  opacity:.45!important;
  cursor:not-allowed!important;
}
@media(max-width:760px){
  .rp-prof-panel .rp-session-history-status-filters{gap:6px!important;}
  .rp-prof-panel .rp-session-history-status-filters button,
  .rp-prof-panel .rp-history-pagination button{font-size:12px!important;padding:6px 10px!important;}
  .rp-prof-panel .rp-history-pagination{flex-wrap:wrap!important;}
  .rp-prof-panel .rp-unavailable-day-checks{gap:10px 16px!important;}
}

/* v1007 - Historial sesiones: chips de estados alineados y paginación real */
.rp-prof-panel .rp-session-history-card .rp-session-history-toolbar{
  align-items:center!important;
}
.rp-prof-panel .rp-session-history-card .rp-session-history-filters,
.rp-prof-panel .rp-session-history-card .rp-session-history-status-filters{
  display:flex!important;
  flex-wrap:wrap!important;
  align-items:center!important;
  gap:6px!important;
  margin:0 0 8px!important;
}
.rp-prof-panel .rp-session-history-card .rp-session-history-filters button,
.rp-prof-panel .rp-session-history-card .rp-session-history-status-filters button{
  height:24px!important;
  min-height:24px!important;
  max-height:24px!important;
  padding:0 9px!important;
  font-size:11px!important;
  font-weight:400!important;
  line-height:22px!important;
  border-radius:999px!important;
  border:1px solid #D7DEE8!important;
  background:#fff!important;
  color:#344054!important;
  box-shadow:none!important;
  white-space:nowrap!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
}
.rp-prof-panel .rp-session-history-card .rp-session-history-filters button.is-active,
.rp-prof-panel .rp-session-history-card .rp-session-history-status-filters button.is-active{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  border-color:#102A56!important;
  color:#fff!important;
}
.rp-prof-panel .rp-session-history-card tr[hidden],
.rp-prof-panel .rp-cancel-history-card tr[hidden],
.rp-prof-panel .rp-session-history-card tr.rp-session-hidden-by-filter{
  display:none!important;
}
.rp-prof-panel .rp-history-pagination{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  margin:14px 0 2px;
}
.rp-prof-panel .rp-history-pagination button{
  height:28px!important;
  min-height:28px!important;
  padding:0 12px!important;
  font-size:12px!important;
  font-weight:400!important;
  border-radius:999px!important;
  border:1px solid #D7DEE8!important;
  background:#fff!important;
  color:#344054!important;
}
.rp-prof-panel .rp-history-pagination button:disabled{
  opacity:.45!important;
}
@media(max-width:768px){
  .rp-prof-panel .rp-session-history-card .rp-session-history-filters button,
  .rp-prof-panel .rp-session-history-card .rp-session-history-status-filters button{
    height:30px!important;
    min-height:30px!important;
    max-height:30px!important;
    padding:0 11px!important;
    font-size:12px!important;
    line-height:28px!important;
  }
}


/* RP final: precarga sin pantalla blanca; el layout crítico se imprime en wp_head */
html .rp-prof-panel{opacity:1!important;}

/* RP final: filtros Desde/Hasta en Historial de pagos/deuda */
.rp-prof-panel .rp-payment-date-filters{
  display:flex!important;
  align-items:flex-end!important;
  justify-content:flex-start!important;
  gap:10px!important;
  flex-wrap:wrap!important;
  margin:4px 0 12px!important;
}
.rp-prof-panel .rp-payment-date-filters label{
  display:flex!important;
  flex-direction:column!important;
  gap:5px!important;
  color:#253142!important;
  font-size:12px!important;
  font-weight:450!important;
  margin:0!important;
}
.rp-prof-panel .rp-payment-date-filters input[type="date"]{
  min-height:36px!important;
  width:150px!important;
  max-width:100%!important;
  border:1px solid #d8e1ec!important;
  border-radius:12px!important;
  padding:7px 10px!important;
  background:#fff!important;
  color:#253142!important;
  box-shadow:none!important;
  box-sizing:border-box!important;
  font-size:13px!important;
  font-weight:400!important;
}
.rp-prof-panel .rp-payment-date-clear{
  min-height:36px!important;
  border:1px solid #d8e1ec!important;
  background:#fff!important;
  color:#475569!important;
  border-radius:12px!important;
  padding:7px 13px!important;
  font-size:13px!important;
  font-weight:400!important;
  cursor:pointer!important;
}
@media(max-width:760px){
  .rp-prof-panel .rp-payment-date-filters{
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:9px!important;
  }
  .rp-prof-panel .rp-payment-date-filters input[type="date"]{
    width:100%!important;
  }
  .rp-prof-panel .rp-payment-date-clear{
    justify-self:start!important;
  }
}


/* v374 safe: corrección visual sin render standalone */
@media (min-width:761px){
  .rp-prof-panel .rp-prof-sidebar:not(.mobile-open) a.active,
  .rp-prof-panel .rp-prof-sidebar:not(.mobile-open) a:hover{
    background:rgba(255,255,255,.18)!important;
    border-color:#123A73!important;
    color:#fff!important;
  }
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{
    display:inline-block!important;
    opacity:1!important;
    visibility:visible!important;
    color:#fff!important;
    font-size:15px!important;
    font-weight:500!important;
    white-space:nowrap!important;
    max-width:180px!important;
  }
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap{
    margin:0!important;
  }
  .rp-prof-panel:not(.rp-sidebar-expanded) .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap{
    margin-left:auto!important;
    margin-right:auto!important;
    left:auto!important;
    right:auto!important;
    transform:none!important;
  }
}


/* v374.1 - PC: quitar hamburguesa del menú abierto/cerrado sin afectar móvil */
@media (min-width:761px){
  .rp-prof-sidebar .rp-sidebar-toggle,
  .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle{
    display:none!important;
    visibility:hidden!important;
    width:0!important;
    min-width:0!important;
    height:0!important;
    min-height:0!important;
    margin:0!important;
    padding:0!important;
    overflow:hidden!important;
  }
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand{
    display:flex!important;
    justify-content:flex-start!important;
  }
}

/* v375 - Overlay de creación/actualización de turnos y bloqueo de transición */
.rp-saving-appointment-overlay{position:fixed;inset:0;z-index:2147483000;display:flex;align-items:center;justify-content:center;background:rgba(248,250,252,.82);backdrop-filter:blur(7px);opacity:0;pointer-events:auto;transition:opacity .18s ease}.rp-saving-appointment-overlay.show{opacity:1}.rp-saving-appointment-card{width:min(360px,calc(100vw - 34px));background:#fff;border:1px solid rgba(16,42,86,.14);border-radius:18px;padding:24px 22px;text-align:center;box-shadow:0 24px 70px rgba(16,42,86,.16);color:#102A56}.rp-saving-appointment-icon{width:56px;height:56px;margin:0 auto 12px;border-radius:18px;background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%);color:#fff;display:flex;align-items:center;justify-content:center}.rp-saving-appointment-icon svg{width:30px;height:30px}.rp-saving-appointment-card h3{margin:0 0 6px;font-size:16px;font-weight:500;color:#102A56}.rp-saving-appointment-card p{margin:0 auto 16px;max-width:285px;font-size:12px;font-weight:400;line-height:1.45;color:#526070}.rp-saving-appointment-spinner{display:block;width:28px;height:28px;margin:0 auto;border-radius:999px;border:2px solid rgba(16,42,86,.16);border-top-color:#102A56;animation:rpSavingAppointmentSpin .78s linear infinite}@keyframes rpSavingAppointmentSpin{to{transform:rotate(360deg)}}.rp-is-submitting-appointment button[type="submit"],.rp-is-submitting-appointment .rp-btn{cursor:wait!important;opacity:.74!important}.rp-prof-panel .rp-prof-section:not(.active){display:none!important}.rp-prof-panel .rp-prof-section.active{display:block!important}

/* v376: cuando vuelve de guardar turno con rp_patient, el servidor ya abre la ficha.
   Esto evita el parpadeo de la lista de pacientes antes de que termine de iniciar el JS. */
.rp-prof-panel.rp-has-initial-patient .rp-patients-list-view:not(.hidden){display:none!important;}
.rp-prof-panel.rp-has-initial-patient .rp-patient-detail-screen.active{display:block!important;}


/* RedPsico v378 - Listado general de pacientes: centrado fino de Contacto y Acciones */
.rp-prof-panel #pacientes .rp-patients-head{
  align-items:flex-start!important;
}
.rp-prof-panel #pacientes .rp-patient-create-btn{
  margin-top:2px!important;
}
.rp-prof-panel #pacientes table.rp-patient-table th,
.rp-prof-panel #pacientes table.rp-patient-table td{
  vertical-align:middle!important;
}
.rp-prof-panel #pacientes table.rp-patient-table th:nth-child(3),
.rp-prof-panel #pacientes table.rp-patient-table td:nth-child(3){
  text-align:center!important;
}
.rp-prof-panel #pacientes table.rp-patient-table td:nth-child(3){
  padding-left:8px!important;
  padding-right:8px!important;
}
.rp-prof-panel #pacientes table.rp-patient-table td:nth-child(3) small{
  display:block!important;
  text-align:center!important;
  margin-left:auto!important;
  margin-right:auto!important;
  max-width:100%!important;
}
.rp-prof-panel #pacientes table.rp-patient-table th:nth-child(5),
.rp-prof-panel #pacientes table.rp-patient-table td:nth-child(5),
.rp-prof-panel #pacientes table.rp-patient-table th:nth-child(6),
.rp-prof-panel #pacientes table.rp-patient-table td:nth-child(6),
.rp-prof-panel #pacientes table.rp-patient-table th:nth-child(7),
.rp-prof-panel #pacientes table.rp-patient-table td:nth-child(7),
.rp-prof-panel #pacientes table.rp-patient-table th:nth-child(8),
.rp-prof-panel #pacientes table.rp-patient-table td:nth-child(8),
.rp-prof-panel #pacientes table.rp-patient-table th:nth-child(9),
.rp-prof-panel #pacientes table.rp-patient-table td:nth-child(9),
.rp-prof-panel #pacientes table.rp-patient-table th:nth-child(10),
.rp-prof-panel #pacientes table.rp-patient-table td:nth-child(10){
  text-align:center!important;
}
.rp-prof-panel #pacientes table.rp-patient-table td:nth-child(10){
  padding-left:6px!important;
  padding-right:6px!important;
}
.rp-prof-panel #pacientes .rp-patient-open-btn{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  text-align:center!important;
  margin-left:auto!important;
  margin-right:auto!important;
}
.rp-prof-panel #pacientes .rp-patient-open-btn .rp-btn-svg{
  margin-right:4px!important;
}
.rp-prof-panel #pacientes .rp-patient-status{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:5px!important;
  margin-left:auto!important;
  margin-right:auto!important;
  text-align:center!important;
}
.rp-prof-panel #pacientes .rp-patient-status::before{
  flex:0 0 auto!important;
  margin:0!important;
}
.rp-prof-panel #pacientes .rp-patient-sort-controls{
  justify-content:center!important;
}
@media (min-width:981px){
  .rp-prof-panel #pacientes table.rp-patient-table th:nth-child(3),
  .rp-prof-panel #pacientes table.rp-patient-table td:nth-child(3){width:18.5%!important;}
  .rp-prof-panel #pacientes table.rp-patient-table th:nth-child(10),
  .rp-prof-panel #pacientes table.rp-patient-table td:nth-child(10){width:10%!important;}
}

/* v384: disponibilidad con horario independiente por día */
.rp-prof-panel .rp-workdays-hours label{display:flex;align-items:center;gap:7px;flex-wrap:wrap;padding:9px 10px;border:1px solid #dbe3ef;border-radius:10px;background:#fff;margin:6px 0;}
.rp-prof-panel .rp-workdays-hours input[type="time"]{max-width:118px;min-height:34px;font-size:12px;}
.rp-prof-panel .rp-workdays-hours small{font-size:12px;font-weight:400;color:#53657d;}

/* v392 - Fix pantalla apagada después de guardar: no dejar overlays/clases de envío pegados */
.rp-prof-panel,
.rp-prof-main,
[data-rp-panel]{opacity:1!important;filter:none!important;}
body.rp-panel-dimmed .rp-prof-panel,
html.rp-panel-dimmed .rp-prof-panel,
body.is-saving .rp-prof-panel,
html.is-saving .rp-prof-panel,
body.rp-saving .rp-prof-panel,
html.rp-saving .rp-prof-panel{opacity:1!important;filter:none!important;pointer-events:auto!important;}
.rp-is-submitting-appointment:not(:has(.is-loading)) button[type="submit"],
.rp-is-submitting:not(:has(.is-loading)) button[type="submit"]{opacity:1!important;cursor:pointer!important;}

/* v393 - Historia clínica paciente: evitar que los campos tapen los botones y mantener acciones visibles */
.rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-card-wide,
.rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-form{
  overflow:visible!important;
  position:relative!important;
}
.rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-form{
  display:grid!important;
  grid-template-columns:1fr!important;
  align-items:start!important;
  gap:14px!important;
}
.rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-form label{
  grid-column:1/-1!important;
  position:relative!important;
  z-index:1!important;
  margin:0!important;
  overflow:visible!important;
}
.rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-form textarea,
.rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-form input[type="date"]{
  display:block!important;
  position:relative!important;
  z-index:1!important;
  width:100%!important;
  max-width:100%!important;
  box-sizing:border-box!important;
  float:none!important;
}
.rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-form .rp-clinical-history-actions{
  grid-column:1/-1!important;
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:14px!important;
  flex-wrap:wrap!important;
  position:relative!important;
  z-index:20!important;
  width:100%!important;
  clear:both!important;
  margin:18px 0 0!important;
  padding:10px 0 0!important;
  background:#fff!important;
  pointer-events:auto!important;
}
.rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-actions .rp-btn{
  position:relative!important;
  z-index:21!important;
  pointer-events:auto!important;
  opacity:1!important;
  visibility:visible!important;
}
.rp-prof-panel #pacientes .rp-clinical-history-table-wrap{
  overflow-x:auto!important;
  overflow-y:visible!important;
}
.rp-prof-panel #pacientes table.rp-clinical-history-table{
  table-layout:fixed!important;
  min-width:760px!important;
}
.rp-prof-panel #pacientes table.rp-clinical-history-table th:nth-child(4),
.rp-prof-panel #pacientes table.rp-clinical-history-table td:nth-child(4){
  width:255px!important;
  max-width:255px!important;
}
.rp-prof-panel #pacientes .rp-clinical-row-actions{
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:6px!important;
  flex-wrap:wrap!important;
  white-space:normal!important;
  overflow:visible!important;
  position:relative!important;
  z-index:10!important;
}
.rp-prof-panel #pacientes .rp-clinical-row-actions > .rp-mini-action{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:auto!important;
  max-width:100%!important;
  min-width:0!important;
  height:30px!important;
  min-height:30px!important;
  padding:6px 8px!important;
  opacity:1!important;
  visibility:visible!important;
  pointer-events:auto!important;
}
@media(max-width:900px){
  .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-form .rp-clinical-history-actions .rp-btn{width:100%!important;}
  .rp-prof-panel #pacientes table.rp-clinical-history-table{min-width:680px!important;}
  .rp-prof-panel #pacientes table.rp-clinical-history-table th:nth-child(4),
  .rp-prof-panel #pacientes table.rp-clinical-history-table td:nth-child(4){width:220px!important;max-width:220px!important;}
}


/* v394 - Historia clínica en ficha de paciente: tabla estable, columnas legibles y acciones sin superposición */
.rp-prof-panel #pacientes .rp-clinical-patient-history-list,
.rp-prof-panel #pacientes .rp-clinical-dropdown,
.rp-prof-panel #pacientes .rp-clinical-dropdown-body,
.rp-prof-panel #pacientes .rp-clinical-history-table-wrap{
  position:relative!important;
  overflow:visible!important;
  width:100%!important;
  max-width:100%!important;
  box-sizing:border-box!important;
}
.rp-prof-panel #pacientes .rp-clinical-history-table-wrap{
  overflow-x:auto!important;
  overflow-y:visible!important;
  padding-bottom:4px!important;
}
.rp-prof-panel #pacientes table.rp-clinical-history-table{
  width:100%!important;
  min-width:960px!important;
  table-layout:fixed!important;
  border-collapse:separate!important;
  border-spacing:0!important;
}
.rp-prof-panel #pacientes table.rp-clinical-history-table th,
.rp-prof-panel #pacientes table.rp-clinical-history-table td{
  box-sizing:border-box!important;
  vertical-align:middle!important;
  overflow:visible!important;
  white-space:normal!important;
  word-break:normal!important;
  overflow-wrap:anywhere!important;
  line-height:1.25!important;
}
.rp-prof-panel #pacientes table.rp-clinical-history-table th:nth-child(1),
.rp-prof-panel #pacientes table.rp-clinical-history-table td:nth-child(1){
  width:118px!important;
  min-width:118px!important;
  max-width:118px!important;
  white-space:nowrap!important;
  text-align:left!important;
}
.rp-prof-panel #pacientes table.rp-clinical-history-table th:nth-child(2),
.rp-prof-panel #pacientes table.rp-clinical-history-table td:nth-child(2){
  width:88px!important;
  min-width:88px!important;
  max-width:88px!important;
  white-space:nowrap!important;
  text-align:left!important;
}
.rp-prof-panel #pacientes table.rp-clinical-history-table th:nth-child(3),
.rp-prof-panel #pacientes table.rp-clinical-history-table td:nth-child(3){
  width:auto!important;
  min-width:260px!important;
  text-align:left!important;
}
.rp-prof-panel #pacientes table.rp-clinical-history-table th:nth-child(4),
.rp-prof-panel #pacientes table.rp-clinical-history-table td:nth-child(4){
  width:360px!important;
  min-width:360px!important;
  max-width:360px!important;
  text-align:left!important;
}
.rp-prof-panel #pacientes table.rp-clinical-history-table thead th{
  padding:13px 14px!important;
  font-size:13px!important;
  letter-spacing:.02em!important;
  text-transform:uppercase!important;
  white-space:nowrap!important;
}
.rp-prof-panel #pacientes table.rp-clinical-history-table thead th:first-child{border-top-left-radius:14px!important;}
.rp-prof-panel #pacientes table.rp-clinical-history-table thead th:last-child{border-top-right-radius:14px!important;}
.rp-prof-panel #pacientes table.rp-clinical-history-table tbody td{
  padding:12px 14px!important;
}
.rp-prof-panel #pacientes .rp-clinical-row-actions{
  display:flex!important;
  align-items:center!important;
  justify-content:flex-start!important;
  gap:8px!important;
  flex-wrap:nowrap!important;
  white-space:nowrap!important;
  overflow:visible!important;
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  position:relative!important;
  z-index:5!important;
}
.rp-prof-panel #pacientes .rp-clinical-row-actions > .rp-mini-action,
.rp-prof-panel #pacientes .rp-clinical-row-actions > button.rp-mini-action{
  flex:0 0 auto!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:6px!important;
  width:auto!important;
  min-width:auto!important;
  max-width:none!important;
  height:32px!important;
  min-height:32px!important;
  padding:7px 10px!important;
  font-size:12px!important;
  line-height:1!important;
  background:#fff!important;
  color:#102A56!important;
  border:1px solid rgba(16,42,86,.22)!important;
  border-radius:10px!important;
  box-shadow:none!important;
  opacity:1!important;
  visibility:visible!important;
  pointer-events:auto!important;
  transform:none!important;
}
.rp-prof-panel #pacientes .rp-clinical-row-actions > .rp-history-edit-modal{
  flex:0 0 0!important;
}
.rp-prof-panel #pacientes .rp-clinical-row-actions svg{
  width:14px!important;
  height:14px!important;
  flex:0 0 14px!important;
  stroke:#102A56!important;
}
@media(max-width:900px){
  .rp-prof-panel #pacientes table.rp-clinical-history-table{min-width:820px!important;}
  .rp-prof-panel #pacientes table.rp-clinical-history-table th:nth-child(4),
  .rp-prof-panel #pacientes table.rp-clinical-history-table td:nth-child(4){width:330px!important;min-width:330px!important;max-width:330px!important;}
  .rp-prof-panel #pacientes .rp-clinical-row-actions{gap:6px!important;}
  .rp-prof-panel #pacientes .rp-clinical-row-actions > .rp-mini-action{font-size:11.5px!important;padding:6px 8px!important;}
}


/* v395 - asegurar clic real sobre tarjetas de pacientes en Historias Clínicas */
.rp-prof-panel .rp-history-patient-card{position:relative;z-index:2;pointer-events:auto!important;}
.rp-prof-panel .rp-history-patient-grid{position:relative;z-index:1;pointer-events:auto!important;}
.rp-prof-panel .rp-history-detail-screen.active{display:block!important;}
.rp-prof-panel .rp-history-list-view.hidden{display:none!important;}

/* v396 - Fix visual de selects en panel azul: opciones legibles sobre fondo blanco */
.rp-prof-panel select,
.rp-prof-panel select:focus,
.rp-prof-panel select:hover,
.rp-prof-panel select option,
.rp-prof-panel select optgroup{
  background:#ffffff!important;
  color:#1f2937!important;
  -webkit-text-fill-color:#1f2937!important;
}
.rp-prof-panel select option:checked,
.rp-prof-panel select option:hover{
  color:#1f2937!important;
  -webkit-text-fill-color:#1f2937!important;
}
.rp-prof-panel .rp-unavailable-box select,
.rp-prof-panel .rp-unavailable-box select:focus,
.rp-prof-panel .rp-unavailable-box select:hover,
.rp-prof-panel .rp-unavailable-box select option,
.rp-prof-panel .rp-unavailable-box select optgroup,
.rp-prof-panel .rp-unavailable-row select,
.rp-prof-panel .rp-unavailable-row select:focus,
.rp-prof-panel .rp-unavailable-row select:hover,
.rp-prof-panel .rp-unavailable-row select option,
.rp-prof-panel .rp-unavailable-row select optgroup{
  background:#ffffff!important;
  color:#1f2937!important;
  -webkit-text-fill-color:#1f2937!important;
}
.rp-prof-panel .rp-unavailable-box select option:checked,
.rp-prof-panel .rp-unavailable-box select option:hover,
.rp-prof-panel .rp-unavailable-row select option:checked,
.rp-prof-panel .rp-unavailable-row select option:hover{
  color:#1f2937!important;
  -webkit-text-fill-color:#1f2937!important;
}


/* v398 - aviso de conflicto de período en popup, sin globo inline */
.rp-period-popup-backdrop{position:fixed!important;inset:0!important;background:rgba(15,23,42,.34)!important;z-index:999999!important;display:flex!important;align-items:center!important;justify-content:center!important;padding:18px!important}
.rp-period-popup{width:min(430px,94vw)!important;background:#fff!important;border:1px solid #fed7aa!important;border-radius:18px!important;box-shadow:0 18px 50px rgba(15,23,42,.22)!important;padding:22px 22px 20px!important;position:relative!important;text-align:center!important;color:#102A56!important;font-family:inherit!important}
.rp-period-popup-x{position:absolute!important;top:10px!important;right:12px!important;width:32px!important;height:32px!important;border:0!important;background:#f8fafc!important;color:#102A56!important;border-radius:999px!important;font-size:22px!important;line-height:30px!important;cursor:pointer!important}
.rp-period-popup-icon{width:42px!important;height:42px!important;margin:0 auto 10px!important;border-radius:999px!important;background:#fff7ed!important;border:1px solid #fed7aa!important;color:#9a3412!important;display:flex!important;align-items:center!important;justify-content:center!important;font-weight:700!important;font-size:20px!important}
.rp-period-popup-title{font-size:18px!important;font-weight:600!important;margin-bottom:8px!important;color:#102A56!important}
.rp-period-popup-text{font-size:14px!important;line-height:1.45!important;color:#334155!important;font-weight:400!important}


/* v400 - Aviso de disponibilidad del calendario: texto simplificado y fondo verde sin borde */
.rp-prof-panel .rp-patient-calendar-picker .rp-day-availability-card.is-on,
.rp-prof-panel .rp-vbz-calendar-wrap .rp-day-availability-card.is-on,
.rp-patient-detail-screen .rp-day-availability-card.is-on,
.rp-day-availability-card.is-on{
  background:#ECFDF5!important;
  color:#14532D!important;
  border:0!important;
  box-shadow:none!important;
}
.rp-day-availability-card.is-on p,
.rp-day-availability-card.is-on strong{
  color:inherit!important;
}


/* v401: guía visual al seleccionar día: siguiente paso Hora exacta */
.rp-patient-schedule-card.is-time-field-attention .rp-patient-appointment-form input[name="appointment_time"]{
  border:2px solid #facc15!important;
  background:#fffbeb!important;
  box-shadow:0 0 0 5px rgba(250,204,21,.18)!important;
  border-radius:999px!important;
  animation:rpYellowGuidePulse 1.6s ease-in-out infinite!important;
}
.rp-patient-schedule-card.is-time-field-attention .rp-patient-appointment-form label:has(input[name="appointment_time"]){
  position:relative!important;
}
.rp-patient-schedule-card.is-time-field-attention .rp-patient-appointment-form label:has(input[name="appointment_time"])::after{
  content:'Ahora cargá el horario';
  display:inline-flex!important;
  margin-top:6px!important;
  padding:4px 9px!important;
  width:max-content!important;
  border-radius:999px!important;
  background:#facc15!important;
  color:#713f12!important;
  font-size:11px!important;
  font-weight:700!important;
}

/* v403: quitar carga visual en Agenda del paciente sin alterar valores enviados */
.rp-patient-appointment-form .rp-agenda-hidden-field{
  display:none !important;
}

/* v406 - Paciente: historial de sesiones/cancelaciones solo en Ficha */
.rp-prof-panel .rp-patient-detail-screen.rp-patient-subpage-mode > .rp-patient-history-stack{
  display:none !important;
}
.rp-prof-panel .rp-patient-detail-screen:not(.rp-patient-subpage-mode) > .rp-patient-history-stack{
  display:block !important;
}

/* v410 - resumen compacto del plan terapéutico en ficha del paciente */
.rp-patient-detail-screen .rp-detail-side{
  display:flex!important;
  flex-direction:column!important;
  align-items:flex-end!important;
  gap:10px!important;
  min-width:0!important;
}
.rp-patient-detail-screen .rp-patient-plan-summary{
  width:100%!important;
  max-width:360px!important;
  display:grid!important;
  grid-template-columns:repeat(2,minmax(0,1fr))!important;
  gap:5px 12px!important;
  justify-content:end!important;
  color:#475569!important;
  font-size:12px!important;
  line-height:1.35!important;
  font-weight:400!important;
}
.rp-patient-detail-screen .rp-patient-plan-summary div{
  display:flex!important;
  align-items:center!important;
  gap:5px!important;
  min-width:0!important;
  font-size:12px!important;
  line-height:1.35!important;
  font-weight:400!important;
  color:#475569!important;
  white-space:nowrap!important;
}
.rp-patient-detail-screen .rp-patient-plan-summary .rp-line-svg{
  width:14px!important;
  height:14px!important;
  flex:0 0 14px!important;
  color:#102A56!important;
  stroke:currentColor!important;
  fill:none!important;
}
.rp-patient-detail-screen .rp-patient-plan-summary span{
  font-size:12px!important;
  font-weight:400!important;
  color:#64748B!important;
}
.rp-patient-detail-screen .rp-patient-plan-summary strong{
  min-width:0!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  color:#102A56!important;
  font-size:12px!important;
  font-weight:400!important;
}
@media(max-width:900px){
  .rp-patient-detail-screen .rp-detail-side{
    align-items:stretch!important;
    margin-top:12px!important;
  }
  .rp-patient-detail-screen .rp-patient-plan-summary{
    max-width:none!important;
    grid-template-columns:1fr!important;
  }
  .rp-patient-detail-screen .rp-patient-plan-summary div{
    white-space:normal!important;
  }
}


/* v411 - resumen debajo de botones y suspender en negro */
.rp-patient-detail-screen .rp-detail-actions .rp-btn-warning{
  color:#111827!important;
}
.rp-patient-detail-screen .rp-detail-actions .rp-btn-warning svg{
  color:#111827!important;
  stroke:#111827!important;
}
.rp-patient-detail-screen .rp-detail-side .rp-detail-actions{
  order:1!important;
}
.rp-patient-detail-screen .rp-detail-side .rp-patient-plan-summary{
  order:2!important;
  margin-top:2px!important;
}

/* v412: ocultar título redundante y compactar cabecera de ficha */
.rp-patient-detail-screen .rp-detail-topbar > span{
  display:none!important;
}
.rp-patient-detail-screen .rp-detail-topbar{
  justify-content:flex-start!important;
  margin-bottom:8px!important;
}
.rp-patient-detail-screen .rp-detail-hero{
  margin-top:0!important;
}

/* v413: compactar cabecera real de ficha; quitar hueco superior sobre datos del paciente */
.rp-patient-detail-screen:not(.rp-patient-subpage-mode) .rp-detail-hero{
  display:grid!important;
  grid-template-columns:minmax(0,1fr) auto!important;
  align-items:start!important;
  align-content:start!important;
  gap:12px 18px!important;
  padding:12px 16px!important;
  min-height:0!important;
  height:auto!important;
  margin-top:0!important;
  margin-bottom:12px!important;
}
.rp-patient-detail-screen:not(.rp-patient-subpage-mode) .rp-detail-hero > div:first-child{
  order:0!important;
  align-self:start!important;
  margin:0!important;
  padding:0!important;
}
.rp-patient-detail-screen:not(.rp-patient-subpage-mode) .rp-detail-side{
  order:0!important;
  align-self:start!important;
  margin:0!important;
  padding:0!important;
}
.rp-patient-detail-screen:not(.rp-patient-subpage-mode) .rp-detail-topbar{
  margin-bottom:8px!important;
}
.rp-patient-detail-screen:not(.rp-patient-subpage-mode) .rp-detail-hero small,
.rp-patient-detail-screen:not(.rp-patient-subpage-mode) .rp-detail-hero h1,
.rp-patient-detail-screen:not(.rp-patient-subpage-mode) .rp-detail-hero p{
  margin-top:0!important;
}
@media(max-width:900px){
  .rp-patient-detail-screen:not(.rp-patient-subpage-mode) .rp-detail-hero{
    display:block!important;
    padding:12px 14px!important;
  }
  .rp-patient-detail-screen:not(.rp-patient-subpage-mode) .rp-detail-side{
    margin-top:12px!important;
  }
}

/* v414: mostrar Meses solo cuando Repetición es Mismo día y horario */
.rp-repeat-months-field[hidden]{display:none!important;}


/* v417 - Móvil: Horario más chico sin encimar Modalidad y sin deformar emergencia */
@media (max-width: 760px){
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form.rp-form-grid.rp-compact-form{
    grid-template-columns:minmax(0,38%) minmax(0,1fr)!important;
    column-gap:16px!important;
    row-gap:10px!important;
    align-items:end!important;
  }
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form label:has(input[name="appointment_time"]){
    grid-column:1 / 2!important;
    min-width:0!important;
    width:100%!important;
  }
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form label:has(select[name="modality"]){
    grid-column:2 / 3!important;
    min-width:0!important;
    width:100%!important;
  }
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form input[name="appointment_time"]{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    box-sizing:border-box!important;
    font-size:15px!important;
    text-align:center!important;
  }
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form select[name="modality"]{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    box-sizing:border-box!important;
  }
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form label.rp-emergency-switch{
    grid-column:1 / -1!important;
    width:auto!important;
    max-width:250px!important;
    min-width:0!important;
    justify-self:start!important;
    box-sizing:border-box!important;
  }
}

/* v418 - Móvil: campo Horario más chico y sin empujar Modalidad */
@media (max-width: 760px){
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form.rp-form-grid.rp-compact-form{
    grid-template-columns:132px minmax(0,1fr)!important;
    column-gap:8px!important;
    row-gap:10px!important;
    align-items:end!important;
  }
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form label:has(input[name="appointment_time"]){
    grid-column:1 / 2!important;
    width:132px!important;
    max-width:132px!important;
    min-width:0!important;
  }
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form label:has(select[name="modality"]){
    grid-column:2 / 3!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
  }
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form input[name="appointment_time"]{
    -webkit-appearance:none!important;
    appearance:none!important;
    display:block!important;
    width:132px!important;
    max-width:132px!important;
    min-width:0!important;
    box-sizing:border-box!important;
    padding-left:8px!important;
    padding-right:8px!important;
    font-size:15px!important;
    line-height:1.15!important;
    text-align:center!important;
  }
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form select[name="modality"]{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
    padding-left:10px!important;
    padding-right:28px!important;
    font-size:15px!important;
  }
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form label.rp-emergency-switch{
    grid-column:1 / -1!important;
    width:auto!important;
    max-width:100%!important;
    min-width:0!important;
    justify-self:start!important;
    box-sizing:border-box!important;
  }
}


/* Mobile tweak: narrower schedule time field */
@media (max-width:768px){
.agenda-paciente .rp-time-wrap,
.agenda-paciente .campo-horario,
.agenda-paciente .field-horario{
  flex:0 0 35%!important;
  width:35%!important;
  max-width:35%!important;
  min-width:0!important;
}
.agenda-paciente input[type="time"]{
  min-width:0!important;
  width:100%!important;
  padding-left:8px!important;
  padding-right:8px!important;
}
.agenda-paciente .campo-modalidad,
.agenda-paciente .field-modalidad{
  flex:0 0 65%!important;
  width:65%!important;
  max-width:65%!important;
}
}

/* v420 - Mobile: calendario paciente ancho real y números en negro */
@media (max-width: 760px){
  .rp-patient-schedule-card .rp-vbz-calendar-wrap,
  .rp-patient-calendar-below .rp-vbz-calendar-wrap{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
    overflow:hidden!important;
    padding:12px!important;
  }
  .rp-patient-schedule-card .rp-calendar-toolbar,
  .rp-patient-calendar-below .rp-calendar-toolbar{
    display:grid!important;
    grid-template-columns:44px minmax(0,1fr) 44px!important;
    gap:8px!important;
    align-items:center!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
  }
  .rp-patient-schedule-card .rp-calendar-toolbar > div,
  .rp-patient-calendar-below .rp-calendar-toolbar > div{
    min-width:0!important;
    text-align:center!important;
  }
  .rp-patient-schedule-card .rp-cal-nav,
  .rp-patient-calendar-below .rp-cal-nav{
    width:44px!important;
    height:44px!important;
    min-width:44px!important;
    max-width:44px!important;
    box-sizing:border-box!important;
  }
  .rp-patient-calendar-grid.rp-admin-calendar,
  .rp-patient-calendar-grid{
    display:grid!important;
    grid-template-columns:repeat(7,minmax(0,1fr))!important;
    gap:4px!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
    overflow:hidden!important;
  }
  .rp-patient-calendar-grid .rp-day-cell{
    min-width:0!important;
    width:auto!important;
    max-width:100%!important;
    box-sizing:border-box!important;
    padding:6px!important;
  }
  .rp-calendar-weekdays,
  .rp-patient-calendar-weekdays{
    display:grid!important;
    grid-template-columns:repeat(7,minmax(0,1fr))!important;
    gap:4px!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
  }
  .rp-calendar-weekdays span,
  .rp-patient-calendar-weekdays span,
  .rp-patient-calendar-grid .rp-day-cell strong,
  .rp-patient-calendar-grid .rp-day-cell.is-past strong,
  .rp-patient-calendar-grid .rp-day-cell.is-blocked strong{
    color:#111827!important;
  }
}

/* v420 - PC/móvil: números del calendario del paciente en negro */
.rp-patient-calendar-grid .rp-day-cell strong,
.rp-patient-calendar-grid .rp-day-cell.is-past strong,
.rp-patient-calendar-grid .rp-day-cell.is-blocked strong{
  color:#111827!important;
}


/* v421 - FIX real móvil agenda paciente: hora negra + calendario 7 columnas sin recorte */
@media (max-width: 760px){
  /* Fila Horario / Modalidad sin encimar y sin depender de :has */
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form.rp-form-grid.rp-compact-form{
    display:grid!important;
    grid-template-columns:minmax(0,122px) minmax(0,1fr)!important;
    column-gap:16px!important;
    row-gap:10px!important;
    align-items:end!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
  }
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form .rp-appointment-time-label,
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form label:has(input[name="appointment_time"]){
    grid-column:1 / 2!important;
    width:122px!important;
    max-width:122px!important;
    min-width:0!important;
    box-sizing:border-box!important;
  }
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form .rp-appointment-modality-label,
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form label:has(select[name="modality"]){
    grid-column:2 / 3!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
  }
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form input[name="appointment_time"]{
    -webkit-appearance:none!important;
    appearance:none!important;
    width:122px!important;
    max-width:122px!important;
    min-width:0!important;
    box-sizing:border-box!important;
    padding-left:8px!important;
    padding-right:8px!important;
    text-align:center!important;
    color:#111827!important;
    -webkit-text-fill-color:#111827!important;
    caret-color:#111827!important;
    font-size:15px!important;
  }
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form input[name="appointment_time"]::-webkit-datetime-edit,
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form input[name="appointment_time"]::-webkit-datetime-edit-fields-wrapper,
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form input[name="appointment_time"]::-webkit-datetime-edit-hour-field,
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form input[name="appointment_time"]::-webkit-datetime-edit-minute-field,
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form input[name="appointment_time"]::-webkit-datetime-edit-ampm-field,
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form input[name="appointment_time"]::-webkit-datetime-edit-text{
    color:#111827!important;
    -webkit-text-fill-color:#111827!important;
  }
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form select[name="modality"]{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
  }
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-appointment-form label.rp-emergency-switch{
    grid-column:1 / -1!important;
    width:auto!important;
    max-width:100%!important;
    min-width:0!important;
    justify-self:start!important;
    box-sizing:border-box!important;
  }

  /* Calendario: ocupar el ancho real del contenedor, sin desplazamiento ni columna cortada */
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap,
  .rp-prof-panel .rp-patient-calendar-below .rp-vbz-calendar-wrap{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
    padding:10px 8px!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap *,
  .rp-prof-panel .rp-patient-calendar-below .rp-vbz-calendar-wrap *{
    box-sizing:border-box!important;
    min-width:0!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker .rp-calendar-toolbar,
  .rp-prof-panel .rp-patient-calendar-below .rp-calendar-toolbar{
    display:grid!important;
    grid-template-columns:48px minmax(0,1fr) 48px!important;
    gap:6px!important;
    align-items:center!important;
    width:100%!important;
    max-width:100%!important;
    margin-bottom:10px!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker .rp-calendar-toolbar > div,
  .rp-prof-panel .rp-patient-calendar-below .rp-calendar-toolbar > div{
    text-align:center!important;
    min-width:0!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker .rp-cal-nav,
  .rp-prof-panel .rp-patient-calendar-below .rp-cal-nav{
    width:48px!important;
    height:48px!important;
    min-width:48px!important;
    max-width:48px!important;
    padding:0!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker .rp-calendar-weekdays,
  .rp-prof-panel .rp-patient-calendar-below .rp-calendar-weekdays{
    display:grid!important;
    grid-template-columns:repeat(7,minmax(0,1fr))!important;
    gap:4px!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker .rp-calendar-weekdays span,
  .rp-prof-panel .rp-patient-calendar-below .rp-calendar-weekdays span{
    text-align:center!important;
    color:#111827!important;
    -webkit-text-fill-color:#111827!important;
    font-size:12px!important;
    padding:0!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker .rp-patient-calendar-grid,
  .rp-prof-panel .rp-patient-calendar-picker .rp-admin-calendar.rp-patient-calendar-grid,
  .rp-prof-panel .rp-patient-calendar-below .rp-patient-calendar-grid,
  .rp-prof-panel .rp-patient-calendar-below .rp-admin-calendar.rp-patient-calendar-grid{
    display:grid!important;
    grid-template-columns:repeat(7,minmax(0,1fr))!important;
    gap:4px!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    overflow:hidden!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker .rp-day-cell,
  .rp-prof-panel .rp-patient-calendar-picker button.rp-day-cell,
  .rp-prof-panel .rp-patient-calendar-below .rp-day-cell,
  .rp-prof-panel .rp-patient-calendar-below button.rp-day-cell{
    width:auto!important;
    max-width:100%!important;
    min-width:0!important;
    padding:4px 3px!important;
    border-radius:10px!important;
    min-height:78px!important;
    overflow:hidden!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker .rp-day-cell strong,
  .rp-prof-panel .rp-patient-calendar-picker .rp-day-cell .rp-day-number,
  .rp-prof-panel .rp-patient-calendar-below .rp-day-cell strong,
  .rp-prof-panel .rp-patient-calendar-below .rp-day-cell .rp-day-number{
    color:#111827!important;
    -webkit-text-fill-color:#111827!important;
    background:transparent!important;
    font-size:12px!important;
    line-height:1.1!important;
    padding:0!important;
    margin:0 0 4px 0!important;
    width:auto!important;
    min-width:0!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.is-selected strong,
  .rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.selected strong,
  .rp-prof-panel .rp-patient-calendar-picker .rp-day-cell.preview-selected strong,
  .rp-prof-panel .rp-patient-calendar-below .rp-day-cell.is-selected strong,
  .rp-prof-panel .rp-patient-calendar-below .rp-day-cell.selected strong,
  .rp-prof-panel .rp-patient-calendar-below .rp-day-cell.preview-selected strong{
    color:#fff!important;
    -webkit-text-fill-color:#fff!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    padding:2px 4px!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker .rp-day-cell em,
  .rp-prof-panel .rp-patient-calendar-picker .rp-day-cell small,
  .rp-prof-panel .rp-patient-calendar-picker .rp-day-cell span:not(.rp-day-availability-dot),
  .rp-prof-panel .rp-patient-calendar-picker .rp-turno-bubble,
  .rp-prof-panel .rp-patient-calendar-below .rp-day-cell em,
  .rp-prof-panel .rp-patient-calendar-below .rp-day-cell small,
  .rp-prof-panel .rp-patient-calendar-below .rp-day-cell span:not(.rp-day-availability-dot),
  .rp-prof-panel .rp-patient-calendar-below .rp-turno-bubble{
    display:block!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    padding:3px 1px!important;
    margin:3px 0 0!important;
    font-size:10px!important;
    line-height:1.05!important;
    text-align:center!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker .rp-day-availability-dot,
  .rp-prof-panel .rp-patient-calendar-below .rp-day-availability-dot{
    width:9px!important;
    height:9px!important;
    top:5px!important;
    right:5px!important;
    min-width:9px!important;
  }
}


/* RP Psico v4.23 - calendario paciente móvil: restaurar scroll horizontal real y alinear cabecera */
@media (max-width:760px){
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap{
    overflow-x:auto!important;
    overflow-y:visible!important;
    -webkit-overflow-scrolling:touch!important;
    max-width:100%!important;
    width:100%!important;
    padding:10px!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar,
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month{
    width:620px!important;
    min-width:620px!important;
    max-width:none!important;
    box-sizing:border-box!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar{
    display:grid!important;
    grid-template-columns:54px minmax(0,1fr) 54px!important;
    gap:8px!important;
    align-items:center!important;
    margin:0 0 12px!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-cal-nav,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-cal-nav{
    width:54px!important;
    min-width:54px!important;
    max-width:54px!important;
    height:54px!important;
    padding:0!important;
    flex:0 0 54px!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-weekdays,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-weekdays,
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-admin-calendar.rp-patient-calendar-grid,
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-patient-calendar-grid,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-admin-calendar.rp-patient-calendar-grid,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-patient-calendar-grid{
    width:100%!important;
    min-width:0!important;
    max-width:none!important;
    display:grid!important;
    grid-template-columns:repeat(7,minmax(0,1fr))!important;
    gap:8px!important;
    overflow:visible!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell,
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap button.rp-day-cell,
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-patient-date-pick,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap button.rp-day-cell,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-patient-date-pick{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    min-height:108px!important;
    padding:8px!important;
    border-radius:12px!important;
    overflow:hidden!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-weekdays span,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-weekdays span{
    color:#111827!important;
    -webkit-text-fill-color:#111827!important;
  }
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell strong,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell strong{
    color:#111827!important;
    -webkit-text-fill-color:#111827!important;
  }
}

/* v424 mobile calendar header alignment */
@media (max-width:760px){
.rp-calendar-shell{overflow-x:auto!important;-webkit-overflow-scrolling:touch;}
.rp-calendar-inner{min-width:680px!important;}
.rp-calendar-header,.rp-calendar-month-header{display:grid!important;grid-template-columns:72px 1fr 72px!important;align-items:center!important;min-width:680px!important;}
.rp-calendar-weekdays{display:grid!important;grid-template-columns:repeat(7,1fr)!important;min-width:680px!important;}
.rp-calendar-grid{min-width:680px!important;}
}


/* RP Psico v4.25 - mobile calendario paciente: cabecera fija, grilla con scroll horizontal */
@media (max-width:760px){
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap{overflow-x:hidden!important;overflow-y:visible!important;width:100%!important;max-width:100%!important;min-width:0!important;}
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar{width:100%!important;min-width:0!important;max-width:100%!important;display:grid!important;grid-template-columns:58px minmax(0,1fr) 58px!important;gap:8px!important;align-items:center!important;}
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar > div,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar > div{min-width:0!important;overflow:hidden!important;text-align:center!important;}
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month{width:100%!important;max-width:100%!important;min-width:0!important;overflow-x:auto!important;overflow-y:visible!important;-webkit-overflow-scrolling:touch!important;}
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month .rp-calendar-weekdays,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month .rp-calendar-weekdays,
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month .rp-patient-calendar-grid,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month .rp-patient-calendar-grid{width:620px!important;min-width:620px!important;max-width:none!important;display:grid!important;grid-template-columns:repeat(7,minmax(0,1fr))!important;gap:8px!important;}
}



/* v427 AUDITORÍA FINAL - calendario móvil alineado.
   La cabecera del mes queda fija al ancho visible. La fila L-M-X-J-V-S-D
   y la grilla comparten EXACTAMENTE la misma grilla de 7 columnas.
   Se elimina el desfase provocado por reglas anteriores con anchos mezclados. */
@media (max-width:760px){
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap{
--rp-mobile-cal-cell:78px;
--rp-mobile-cal-gap:8px;
--rp-mobile-cal-width:594px;
width:100%!important;
max-width:100%!important;
min-width:0!important;
overflow-x:hidden!important;
overflow-y:visible!important;
padding:10px!important;
box-sizing:border-box!important;
    }
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap *,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap *{
box-sizing:border-box!important;
    }
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar{
width:100%!important;
max-width:100%!important;
min-width:0!important;
display:grid!important;
grid-template-columns:58px minmax(0,1fr) 58px!important;
gap:8px!important;
align-items:center!important;
margin:0 0 12px!important;
    }
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar > div,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar > div{
min-width:0!important;
width:auto!important;
text-align:center!important;
overflow:hidden!important;
    }
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-cal-current-title,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-cal-current-title{
display:block!important;
width:100%!important;
max-width:100%!important;
white-space:nowrap!important;
overflow:hidden!important;
text-overflow:ellipsis!important;
color:#111827!important;
-webkit-text-fill-color:#111827!important;
    }
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar span,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar span{
display:block!important;
width:100%!important;
max-width:100%!important;
white-space:normal!important;
overflow:hidden!important;
    }
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-cal-nav,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-cal-nav{
width:58px!important;
min-width:58px!important;
max-width:58px!important;
height:58px!important;
padding:0!important;
flex:0 0 58px!important;
    }
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month{
width:100%!important;
max-width:100%!important;
min-width:0!important;
overflow-x:auto!important;
overflow-y:visible!important;
-webkit-overflow-scrolling:touch!important;
padding:0!important;
margin:0!important;
box-sizing:border-box!important;
    }
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month .rp-calendar-weekdays,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month .rp-calendar-weekdays,
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month .rp-patient-calendar-grid,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month .rp-patient-calendar-grid,
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month .rp-admin-calendar.rp-patient-calendar-grid,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month .rp-admin-calendar.rp-patient-calendar-grid{
width:var(--rp-mobile-cal-width)!important;
min-width:var(--rp-mobile-cal-width)!important;
max-width:var(--rp-mobile-cal-width)!important;
display:grid!important;
grid-template-columns:repeat(7, var(--rp-mobile-cal-cell))!important;
gap:var(--rp-mobile-cal-gap)!important;
padding:0!important;
margin-left:0!important;
margin-right:0!important;
box-sizing:border-box!important;
justify-content:start!important;
align-items:stretch!important;
    }
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month .rp-calendar-weekdays,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month .rp-calendar-weekdays{
margin-top:0!important;
margin-bottom:8px!important;
    }
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-weekdays span,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-weekdays span{
width:var(--rp-mobile-cal-cell)!important;
min-width:var(--rp-mobile-cal-cell)!important;
max-width:var(--rp-mobile-cal-cell)!important;
display:flex!important;
justify-content:center!important;
align-items:center!important;
text-align:center!important;
padding:0!important;
margin:0!important;
color:#111827!important;
-webkit-text-fill-color:#111827!important;
    }
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell,
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap button.rp-day-cell,
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-patient-date-pick,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap button.rp-day-cell,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-patient-date-pick,
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-empty,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-empty{
width:var(--rp-mobile-cal-cell)!important;
min-width:var(--rp-mobile-cal-cell)!important;
max-width:var(--rp-mobile-cal-cell)!important;
min-height:108px!important;
padding:8px!important;
border-radius:12px!important;
overflow:hidden!important;
margin:0!important;
    }
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-empty,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-empty{
visibility:hidden!important;
display:block!important;
    }
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell strong,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell strong,
    .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell .rp-day-number,
    .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-day-cell .rp-day-number{
color:#111827!important;
-webkit-text-fill-color:#111827!important;
    }
}


/* v428 - móvil: quitar el cuadro exterior que engloba el calendario del paciente.
   Solo limpia el contenedor visual exterior; no cambia la grilla, navegación ni lógica. */
@media (max-width:760px){
  .rp-prof-panel .rp-patient-calendar-picker.rp-vbz-calendar-wrap,
  .rp-patient-calendar-picker.rp-vbz-calendar-wrap{
    background:transparent!important;
    border:0!important;
    box-shadow:none!important;
    border-radius:0!important;
    padding:0!important;
  }
}


/* v429 - móvil: eliminar REALMENTE el cuadro exterior del calendario.
   No toca la lógica ni la grilla: solo quita borde/fondo/sombra del contenedor visual. */
@media (max-width:760px){
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-calendar-picker,
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-calendar-picker.rp-vbz-calendar-wrap,
  .rp-prof-panel .rp-patient-schedule-card .rp-vbz-calendar-wrap,
  .rp-patient-schedule-card .rp-patient-calendar-picker,
  .rp-patient-schedule-card .rp-patient-calendar-picker.rp-vbz-calendar-wrap,
  .rp-patient-schedule-card .rp-vbz-calendar-wrap{
    background:transparent!important;
    background-color:transparent!important;
    border:none!important;
    border-color:transparent!important;
    outline:none!important;
    box-shadow:none!important;
    border-radius:0!important;
  }

  .rp-prof-panel .rp-patient-schedule-card .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar,
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month,
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-weekdays,
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-patient-calendar-grid,
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-admin-calendar,
  .rp-patient-schedule-card .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-toolbar,
  .rp-patient-schedule-card .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month,
  .rp-patient-schedule-card .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-weekdays,
  .rp-patient-schedule-card .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-patient-calendar-grid,
  .rp-patient-schedule-card .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-admin-calendar{
    background:transparent!important;
    background-color:transparent!important;
    border:none!important;
    border-color:transparent!important;
    outline:none!important;
    box-shadow:none!important;
  }

  .rp-prof-panel .rp-patient-schedule-card .rp-patient-calendar-picker.rp-vbz-calendar-wrap::before,
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-calendar-picker.rp-vbz-calendar-wrap::after,
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month::before,
  .rp-prof-panel .rp-patient-schedule-card .rp-patient-calendar-picker.rp-vbz-calendar-wrap .rp-calendar-month::after{
    display:none!important;
    content:none!important;
    border:0!important;
    box-shadow:none!important;
  }
}

/* v433 - responsive móvil consolidado.
   Limpieza de reglas acumuladas v430-v432: no toca lógica ni anchos internos de cards.
   Controla solo el margen exterior útil del panel en móvil. */
@media (max-width:760px){
  html, body{
    max-width:100vw!important;
    overflow-x:hidden!important;
  }

  body:has(.rp-prof-panel) .site,
  body:has(.rp-prof-panel) .site-content,
  body:has(.rp-prof-panel) .content-area,
  body:has(.rp-prof-panel) .entry-content,
  body:has(.rp-prof-panel) .wp-block-post-content,
  body:has(.rp-prof-panel) .container,
  body:has(.rp-prof-panel) .main-page-wrapper,
  body:has(.rp-prof-panel) .elementor,
  body:has(.rp-prof-panel) .elementor-section,
  body:has(.rp-prof-panel) .elementor-container,
  body:has(.rp-prof-panel) .elementor-column,
  body:has(.rp-prof-panel) .elementor-widget-wrap,
  body:has(.rp-prof-panel) .elementor-widget-container{
    width:100vw!important;
    max-width:100vw!important;
    margin-left:0!important;
    margin-right:0!important;
    padding-left:0!important;
    padding-right:0!important;
  }

  .rp-prof-panel,
  .rp-prof-panel.rp-sidebar-expanded{
    width:100vw!important;
    max-width:100vw!important;
    margin:0!important;
    transform:none!important;
    border-left:0!important;
    border-right:0!important;
    border-radius:0!important;
  }

  .rp-prof-main{
    padding-left:6px!important;
    padding-right:6px!important;
    padding-top:10px!important;
    width:100%!important;
    max-width:100%!important;
    box-sizing:border-box!important;
  }

  .rp-prof-section,
  .rp-patients-list-view,
  .rp-patient-detail-screen,
  .rp-dashboard-section,
  .rp-config-section{
    width:100%!important;
    max-width:100%!important;
    margin-left:0!important;
    margin-right:0!important;
  }
}

@media (max-width:420px){
  .rp-prof-main{
    padding-left:5px!important;
    padding-right:5px!important;
  }
}


/* v435 - móvil: corregir ancho real sin desplazamiento lateral.
   Reemplaza el intento de full-bleed que podía correr el panel.
   El panel queda centrado, casi a ancho completo, con solo 6px de gris total.
*/
@media (max-width:760px){
  html, body{
    width:100%!important;
    max-width:100%!important;
    overflow-x:hidden!important;
  }

  body:has(.rp-prof-panel) .site,
  body:has(.rp-prof-panel) .site-content,
  body:has(.rp-prof-panel) .content-area,
  body:has(.rp-prof-panel) .entry-content,
  body:has(.rp-prof-panel) .wp-block-post-content,
  body:has(.rp-prof-panel) .container,
  body:has(.rp-prof-panel) .main-page-wrapper,
  body:has(.rp-prof-panel) .elementor,
  body:has(.rp-prof-panel) .elementor-section,
  body:has(.rp-prof-panel) .elementor-container,
  body:has(.rp-prof-panel) .elementor-column,
  body:has(.rp-prof-panel) .elementor-widget-wrap,
  body:has(.rp-prof-panel) .elementor-widget-container{
    max-width:none!important;
    margin-left:0!important;
    margin-right:0!important;
    padding-left:0!important;
    padding-right:0!important;
  }

  .rp-prof-panel,
  .rp-prof-panel.rp-sidebar-expanded{
    position:relative!important;
    left:auto!important;
    right:auto!important;
    transform:none!important;
    width:calc(100vw - 6px)!important;
    max-width:calc(100vw - 6px)!important;
    margin-left:auto!important;
    margin-right:auto!important;
    border-left:0!important;
    border-right:0!important;
    border-radius:0!important;
    overflow:visible!important;
  }

  .rp-prof-main{
    padding-left:6px!important;
    padding-right:6px!important;
    width:100%!important;
    max-width:100%!important;
  }
}


/* v436 - corrección real de margen exterior móvil.
   El margen amarillo marcado venía de reglas móviles antiguas que fijaban el panel en 100vw-44px y max-width:420px.
   Esta regla final deja el wrapper principal casi a pantalla completa sin desplazarlo lateralmente. */
@media (max-width:760px){
  .rp-prof-panel,
  .rp-prof-panel.rp-sidebar-expanded{
    width:calc(100vw - 8px)!important;
    max-width:calc(100vw - 8px)!important;
    margin-left:auto!important;
    margin-right:auto!important;
    left:auto!important;
    right:auto!important;
    transform:none!important;
    box-sizing:border-box!important;
  }
  .rp-prof-main{
    padding-left:6px!important;
    padding-right:6px!important;
    box-sizing:border-box!important;
  }
}

/* v439 - MOBILE: margen lateral real mínimo del contenido principal.
   Ajuste quirúrgico: no toca lógica, no usa 100vw, no desplaza el panel.
   Reduce el padding que separaba las cards del borde del panel en móvil. */
@media (max-width:760px){
  html, body{
    overflow-x:hidden!important;
  }

  html body .rp-prof-panel,
  html body .rp-prof-panel.rp-sidebar-expanded{
    position:relative!important;
    left:auto!important;
    right:auto!important;
    transform:none!important;
    width:calc(100% - 8px)!important;
    max-width:calc(100% - 8px)!important;
    margin-left:auto!important;
    margin-right:auto!important;
    box-sizing:border-box!important;
  }

  html body .rp-prof-main{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
    padding-left:3px!important;
    padding-right:3px!important;
    padding-top:8px!important;
    padding-bottom:10px!important;
    margin-left:0!important;
    margin-right:0!important;
    overflow:visible!important;
  }

  html body .rp-prof-section,
  html body .rp-patients-list-view,
  html body .rp-patient-detail-screen,
  html body .rp-dashboard-section,
  html body .rp-config-section,
  html body .rp-history-list-view,
  html body .rp-history-detail-screen{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    margin-left:0!important;
    margin-right:0!important;
    padding-left:0!important;
    padding-right:0!important;
    box-sizing:border-box!important;
  }

  html body .rp-card,
  html body .rp-list-card,
  html body .rp-patient-card,
  html body .rp-table-card,
  html body .rp-calendar-shell,
  html body .rp-detail-card,
  html body .rp-detail-hero,
  html body .rp-next-dashboard-card,
  html body .rp-dashboard-notifications-card,
  html body .rp-patient-detail-screen > .rp-card,
  html body .rp-patient-detail-screen > .rp-detail-hero,
  html body #pacientes .rp-patient-detail-screen .rp-detail-hero,
  html body #pacientes .rp-patient-detail-screen .rp-patient-detail-card,
  html body #pacientes .rp-patient-detail-screen .rp-patient-card{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    margin-left:0!important;
    margin-right:0!important;
    box-sizing:border-box!important;
  }
}

/* v440 - Mobile: Historial de pagos / deuda en tarjetas para evitar textos pisados */
@media (max-width: 760px){
  .rp-prof-panel .rp-payments-quick-card .rp-payment-table-scroll{
    width:100% !important;
    max-width:100% !important;
    overflow-x:visible !important;
    overflow-y:visible !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-quick-table-head-select{
    display:none !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable{
    display:grid !important;
    grid-template-columns:30px minmax(0,1fr) !important;
    width:100% !important;
    min-width:0 !important;
    max-width:100% !important;
    box-sizing:border-box !important;
    gap:6px 10px !important;
    margin:0 0 10px !important;
    padding:12px !important;
    border:1px solid #e3ebf3 !important;
    border-radius:14px !important;
    background:#fff !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > span,
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > em,
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > div{
    min-height:0 !important;
    height:auto !important;
    padding:0 !important;
    border:0 !important;
    box-sizing:border-box !important;
    color:#1f2937 !important;
    font-size:13px !important;
    font-weight:400 !important;
    line-height:1.35 !important;
    text-align:left !important;
    justify-content:flex-start !important;
    align-items:flex-start !important;
    white-space:normal !important;
    overflow:visible !important;
    word-break:normal !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > .rp-payment-select{
    grid-column:1 !important;
    grid-row:1 !important;
    display:flex !important;
    align-items:flex-start !important;
    justify-content:center !important;
    padding-top:2px !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > span:nth-child(2){
    grid-column:2 !important;
    grid-row:1 !important;
    display:flex !important;
    flex-direction:column !important;
    gap:2px !important;
    font-weight:500 !important;
    color:#102A56 !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > span:nth-child(2) small{
    display:block !important;
    margin:0 !important;
    color:#667085 !important;
    font-size:12px !important;
    font-weight:400 !important;
    line-height:1.25 !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-modality,
  .rp-prof-panel .rp-payments-quick-card .rp-payment-attendance,
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > em,
  .rp-prof-panel .rp-payments-quick-card .rp-payment-actions{
    grid-column:1 / -1 !important;
    display:flex !important;
    width:100% !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-modality::before{
    content:'Modalidad: ' !important;
    font-weight:500 !important;
    color:#102A56 !important;
    margin-right:4px !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-attendance::before{
    content:'Asistencia: ' !important;
    font-weight:500 !important;
    color:#102A56 !important;
    margin-right:4px !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > em::before{
    content:'Estado / importe: ' !important;
    font-style:normal !important;
    font-weight:500 !important;
    color:#102A56 !important;
    margin-right:4px !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-row-selectable > em{
    font-style:normal !important;
    white-space:normal !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-actions{
    gap:8px !important;
    flex-wrap:wrap !important;
    margin-top:4px !important;
    justify-content:flex-start !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-actions form{
    margin:0 !important;
    display:inline-flex !important;
    flex:0 0 auto !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-actions .rp-mini-action{
    min-height:30px !important;
    height:30px !important;
    padding:0 9px !important;
    font-size:11.5px !important;
    border-radius:9px !important;
    white-space:nowrap !important;
  }
}

/* v441 - Mobile: alinear filtros Desde/Hasta dentro del contenedor de Historial de pagos */
@media (max-width: 760px){
  .rp-prof-panel .rp-payments-quick-card .rp-payment-date-filters{
    display:grid !important;
    grid-template-columns:1fr !important;
    gap:10px !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    margin:10px 0 12px !important;
    padding:0 !important;
    box-sizing:border-box !important;
    overflow:visible !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-date-filters label{
    display:flex !important;
    flex-direction:column !important;
    align-items:stretch !important;
    gap:6px !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    margin:0 !important;
    padding:0 !important;
    box-sizing:border-box !important;
    font-size:13px !important;
    font-weight:400 !important;
    color:#1f2937 !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-date-filters input[type="date"]{
    display:block !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    height:42px !important;
    margin:0 !important;
    box-sizing:border-box !important;
  }
  .rp-prof-panel .rp-payments-quick-card .rp-payment-date-clear{
    width:max-content !important;
    max-width:100% !important;
    margin:0 !important;
    box-sizing:border-box !important;
  }
}

/* v442 - Historial de pagos: filtros Desde/Hasta compactos y dentro del contenedor en móvil */
@media (max-width: 760px){
  html body .rp-prof-panel .rp-payments-quick-card{
    overflow:hidden !important;
  }
  html body .rp-prof-panel .rp-payments-quick-card .rp-payment-date-filters,
  html body .rp-prof-panel .rp-payment-detail-screen .rp-payment-date-filters,
  html body [data-rp-payment-date-filters]{
    display:grid !important;
    grid-template-columns:1fr !important;
    gap:8px !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    margin:10px 0 10px !important;
    padding:0 !important;
    box-sizing:border-box !important;
    overflow:hidden !important;
  }
  html body .rp-prof-panel .rp-payments-quick-card .rp-payment-date-filters label,
  html body .rp-prof-panel .rp-payment-detail-screen .rp-payment-date-filters label,
  html body [data-rp-payment-date-filters] label{
    display:block !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    margin:0 !important;
    padding:0 !important;
    box-sizing:border-box !important;
    overflow:hidden !important;
    font-size:13px !important;
    line-height:1.25 !important;
    font-weight:400 !important;
    color:#1f2937 !important;
  }
  html body .rp-prof-panel .rp-payments-quick-card .rp-payment-date-filters input[type="date"],
  html body .rp-prof-panel .rp-payment-detail-screen .rp-payment-date-filters input[type="date"],
  html body [data-rp-payment-date-filters] input[type="date"]{
    display:block !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    height:38px !important;
    min-height:38px !important;
    max-height:38px !important;
    margin:5px 0 0 !important;
    padding:7px 10px !important;
    box-sizing:border-box !important;
    border:1px solid #d8e1ec !important;
    border-radius:10px !important;
    background:#fff !important;
    font-size:13px !important;
    line-height:1 !important;
    color:#102A56 !important;
    -webkit-appearance:none !important;
    appearance:none !important;
  }
  html body .rp-prof-panel .rp-payments-quick-card .rp-payment-date-filters input[type="date"]::-webkit-date-and-time-value,
  html body .rp-prof-panel .rp-payment-detail-screen .rp-payment-date-filters input[type="date"]::-webkit-date-and-time-value,
  html body [data-rp-payment-date-filters] input[type="date"]::-webkit-date-and-time-value{
    min-height:0 !important;
    line-height:22px !important;
    text-align:left !important;
    padding:0 !important;
    margin:0 !important;
  }
  html body .rp-prof-panel .rp-payments-quick-card .rp-payment-date-clear,
  html body .rp-prof-panel .rp-payment-detail-screen .rp-payment-date-clear,
  html body [data-payment-date-clear]{
    width:auto !important;
    max-width:100% !important;
    min-height:34px !important;
    height:34px !important;
    margin:2px 0 0 !important;
    padding:0 12px !important;
    border-radius:10px !important;
    font-size:13px !important;
    line-height:1 !important;
    box-sizing:border-box !important;
    align-self:flex-start !important;
  }
}

/* v443 - Mobile: Historias clínicas dentro del paciente sin desfasajes */
@media (max-width: 760px){
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-card-wide,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-card,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-history-search-card,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-patient-history-list,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-dropdown,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-dropdown-body{
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    box-sizing:border-box !important;
    overflow:hidden !important;
  }

  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-card-wide,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-history-search-card{
    padding-left:14px !important;
    padding-right:14px !important;
  }

  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-title,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-list-title{
    display:flex !important;
    align-items:center !important;
    gap:10px !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    box-sizing:border-box !important;
    white-space:normal !important;
    overflow-wrap:anywhere !important;
  }

  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-form,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-table-filters,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-history-edit-form{
    display:grid !important;
    grid-template-columns:1fr !important;
    gap:12px !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    margin-left:0 !important;
    margin-right:0 !important;
    padding-left:0 !important;
    padding-right:0 !important;
    box-sizing:border-box !important;
    overflow:hidden !important;
  }

  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-form label,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-table-filters label,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-history-edit-form label{
    display:block !important;
    grid-column:1 / -1 !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    margin:0 !important;
    padding:0 !important;
    box-sizing:border-box !important;
    overflow:hidden !important;
  }

  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-form input,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-form textarea,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-table-filters input,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-history-edit-form input,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-history-edit-form textarea{
    display:block !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    margin:6px 0 0 !important;
    box-sizing:border-box !important;
    float:none !important;
    position:relative !important;
    left:auto !important;
    right:auto !important;
  }

  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-form input[type="date"],
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-table-filters input[type="date"],
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-history-edit-form input[type="date"]{
    height:40px !important;
    min-height:40px !important;
    max-height:40px !important;
    padding:7px 10px !important;
    border-radius:10px !important;
    font-size:13px !important;
    line-height:1 !important;
    -webkit-appearance:none !important;
    appearance:none !important;
  }

  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-form textarea,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-history-edit-form textarea{
    min-height:128px !important;
    padding:10px !important;
    border-radius:12px !important;
  }

  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-actions,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-history-edit-modal-actions{
    display:grid !important;
    grid-template-columns:1fr !important;
    gap:10px !important;
    width:100% !important;
    max-width:100% !important;
    margin:10px 0 0 !important;
    padding:0 !important;
    box-sizing:border-box !important;
  }
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-actions .rp-btn,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-history-edit-modal-actions .rp-btn,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-dropdown-toggle,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen [data-rp-clinical-filter-clear]{
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    box-sizing:border-box !important;
  }

  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-table-wrap{
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    overflow-x:auto !important;
    overflow-y:hidden !important;
    -webkit-overflow-scrolling:touch !important;
    box-sizing:border-box !important;
    padding:0 !important;
    margin-top:12px !important;
  }
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table{
    width:max-content !important;
    min-width:620px !important;
    max-width:none !important;
    table-layout:fixed !important;
    margin:0 !important;
  }
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table th,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table td{
    padding:10px 12px !important;
    font-size:13px !important;
    line-height:1.25 !important;
    box-sizing:border-box !important;
    white-space:normal !important;
    overflow-wrap:anywhere !important;
  }
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table th:nth-child(1),
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table td:nth-child(1){
    width:110px !important; min-width:110px !important; max-width:110px !important;
  }
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table th:nth-child(2),
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table td:nth-child(2){
    width:82px !important; min-width:82px !important; max-width:82px !important;
  }
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table th:nth-child(3),
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table td:nth-child(3){
    width:210px !important; min-width:210px !important; max-width:210px !important;
  }
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table th:nth-child(4),
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table td:nth-child(4){
    width:218px !important; min-width:218px !important; max-width:218px !important;
  }
}

/* v444 - Mobile: Historias clínicas acciones sin desfasaje */
@media (max-width: 760px){
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-history-table-wrap{
    width:100% !important;
    max-width:100% !important;
    overflow-x:auto !important;
    overflow-y:hidden !important;
    -webkit-overflow-scrolling:touch !important;
    box-sizing:border-box !important;
    padding:0 !important;
  }

  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table{
    min-width:560px !important;
    width:560px !important;
    max-width:none !important;
    table-layout:fixed !important;
    border-collapse:separate !important;
    border-spacing:0 !important;
  }

  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table th,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table td{
    box-sizing:border-box !important;
    overflow:hidden !important;
    vertical-align:top !important;
  }

  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table th:nth-child(1),
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table td:nth-child(1){
    width:92px !important; min-width:92px !important; max-width:92px !important;
  }
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table th:nth-child(2),
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table td:nth-child(2){
    width:70px !important; min-width:70px !important; max-width:70px !important;
  }
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table th:nth-child(3),
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table td:nth-child(3){
    width:190px !important; min-width:190px !important; max-width:190px !important;
  }
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table th:nth-child(4),
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen table.rp-clinical-history-table td:nth-child(4){
    width:208px !important; min-width:208px !important; max-width:208px !important;
  }

  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-row-actions{
    display:grid !important;
    grid-template-columns:1fr !important;
    gap:8px !important;
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    overflow:visible !important;
    white-space:normal !important;
    align-items:stretch !important;
    justify-content:stretch !important;
    box-sizing:border-box !important;
  }

  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-row-actions > .rp-mini-action,
  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-row-actions > button.rp-mini-action{
    width:100% !important;
    max-width:100% !important;
    min-width:0 !important;
    height:34px !important;
    min-height:34px !important;
    padding:7px 10px !important;
    display:inline-flex !important;
    align-items:center !important;
    justify-content:center !important;
    gap:6px !important;
    white-space:nowrap !important;
    box-sizing:border-box !important;
  }

  html body .rp-prof-panel #pacientes .rp-patient-detail-screen .rp-clinical-row-actions > .rp-history-edit-modal{
    width:auto !important;
    max-width:none !important;
    min-width:0 !important;
  }
}

/* v445 - Historia clínica: detalle en popup móvil */
.rp-clinical-mobile-detail-modal[hidden]{display:none!important;}
@media (max-width: 768px){
  html.rp-clinical-mobile-detail-open,
  html.rp-clinical-mobile-detail-open body{overflow:hidden!important;}
  .rp-clinical-mobile-detail-modal{
    position:fixed!important;
    inset:0!important;
    z-index:999999!important;
    display:flex!important;
    align-items:flex-end!important;
    justify-content:center!important;
    font-family:inherit!important;
  }
  .rp-clinical-mobile-detail-backdrop{
    position:absolute!important;
    inset:0!important;
    background:rgba(15,23,42,.52)!important;
    backdrop-filter:blur(2px)!important;
  }
  .rp-clinical-mobile-detail-dialog{
    position:relative!important;
    width:100%!important;
    max-width:100%!important;
    max-height:88vh!important;
    background:#fff!important;
    border-radius:24px 24px 0 0!important;
    border:1px solid #dbe4ee!important;
    box-shadow:0 -14px 40px rgba(16,42,86,.18)!important;
    overflow:hidden!important;
    display:flex!important;
    flex-direction:column!important;
  }
  .rp-clinical-mobile-detail-head{
    display:flex!important;
    align-items:flex-start!important;
    justify-content:space-between!important;
    gap:14px!important;
    padding:18px 18px 14px!important;
    border-bottom:1px solid #edf2f7!important;
    background:#fff!important;
  }
  .rp-clinical-mobile-detail-head h3{
    margin:0!important;
    color:#102a56!important;
    font-size:22px!important;
    line-height:1.15!important;
    font-weight:400!important;
  }
  .rp-clinical-mobile-detail-head p{
    margin:6px 0 0!important;
    color:#64748b!important;
    font-size:13px!important;
    line-height:1.35!important;
    font-weight:400!important;
  }
  .rp-clinical-mobile-detail-close{
    width:38px!important;
    height:38px!important;
    border:1px solid #dbe4ee!important;
    border-radius:14px!important;
    background:#fff!important;
    color:#102a56!important;
    font-size:28px!important;
    line-height:1!important;
    font-weight:400!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    padding:0!important;
  }
  .rp-clinical-mobile-detail-body{
    padding:16px 18px 22px!important;
    overflow:auto!important;
    -webkit-overflow-scrolling:touch!important;
  }
  .rp-clinical-mobile-detail-body .rp-clinical-detail-box,
  .rp-clinical-mobile-detail-body .rp-clinical-detail-box-popup{
    margin:0!important;
    padding:0!important;
    border:0!important;
    background:transparent!important;
    box-shadow:none!important;
  }
  .rp-clinical-mobile-detail-body .rp-clinical-detail-grid{
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:14px!important;
  }
  .rp-clinical-mobile-detail-body .rp-clinical-detail-grid > div{
    padding:14px!important;
    border:1px solid #e3eaf2!important;
    border-radius:16px!important;
    background:#fff!important;
  }
  .rp-clinical-mobile-detail-body h4{
    margin:0 0 8px!important;
    color:#102a56!important;
    font-size:14px!important;
    line-height:1.25!important;
    font-weight:400!important;
  }
  .rp-clinical-mobile-detail-body p{
    margin:0!important;
    color:#1f2937!important;
    font-size:15px!important;
    line-height:1.5!important;
    font-weight:400!important;
    white-space:normal!important;
    word-break:break-word!important;
  }
}

/* v446 - móvil: botones superiores de ficha en dos filas alineadas y compactas */
@media (max-width: 760px){
  .rp-patient-detail-screen .rp-detail-side .rp-detail-actions{
    display:grid!important;
    grid-template-columns:minmax(0,1fr) minmax(0,1fr)!important;
    gap:8px!important;
    align-items:stretch!important;
    justify-content:stretch!important;
    width:100%!important;
    max-width:100%!important;
    overflow:visible!important;
    margin:0 0 10px 0!important;
    padding:0!important;
  }
  .rp-patient-detail-screen .rp-detail-actions .rp-patient-header-tabs{
    grid-column:1 / -1!important;
    display:grid!important;
    grid-template-columns:.72fr 1.38fr 1.24fr!important;
    gap:6px!important;
    width:100%!important;
    max-width:100%!important;
    margin:0!important;
    padding:0!important;
    overflow:visible!important;
  }
  .rp-patient-detail-screen .rp-patient-header-tabs .rp-patient-tab-btn{
    width:100%!important;
    min-width:0!important;
    height:38px!important;
    min-height:38px!important;
    padding:0 6px!important;
    border-radius:12px!important;
    font-size:11px!important;
    line-height:1!important;
    font-weight:500!important;
    gap:5px!important;
    justify-content:center!important;
    white-space:nowrap!important;
    overflow:hidden!important;
  }
  .rp-patient-detail-screen .rp-patient-header-tabs .rp-patient-tab-btn svg{
    width:14px!important;
    height:14px!important;
    flex:0 0 14px!important;
  }
  .rp-patient-detail-screen .rp-patient-header-tabs .rp-patient-tab-btn span{
    min-width:0!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    white-space:nowrap!important;
  }
  .rp-patient-detail-screen .rp-detail-actions > form.rp-suspend-patient-form,
  .rp-patient-detail-screen .rp-detail-actions > form.rp-activate-patient-form,
  .rp-patient-detail-screen .rp-detail-actions > form.rp-delete-patient-form{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    margin:0!important;
    display:flex!important;
    grid-column:auto!important;
  }
  .rp-patient-detail-screen .rp-detail-actions > form.rp-suspend-patient-form button,
  .rp-patient-detail-screen .rp-detail-actions > form.rp-activate-patient-form button,
  .rp-patient-detail-screen .rp-detail-actions > form.rp-delete-patient-form button{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    height:40px!important;
    min-height:40px!important;
    padding:0 7px!important;
    border-radius:12px!important;
    font-size:11.5px!important;
    line-height:1!important;
    font-weight:600!important;
    gap:5px!important;
    justify-content:center!important;
    white-space:nowrap!important;
  }
  .rp-patient-detail-screen .rp-detail-actions > form.rp-suspend-patient-form button svg,
  .rp-patient-detail-screen .rp-detail-actions > form.rp-activate-patient-form button svg,
  .rp-patient-detail-screen .rp-detail-actions > form.rp-delete-patient-form button svg{
    width:14px!important;
    height:14px!important;
    flex:0 0 14px!important;
  }
}


/* v448 - Ficha paciente: historiales cerrados por defecto y filtros Desde/Hasta compactos en móvil */
.rp-prof-panel .rp-session-history-card:not([open]) > .rp-history-body,
.rp-prof-panel .rp-cancel-history-card:not([open]) > .rp-history-body{
  display:none!important;
}
.rp-prof-panel .rp-session-history-card:not([open]) .rp-chevron-svg,
.rp-prof-panel .rp-cancel-history-card:not([open]) .rp-chevron-svg{
  transform:none!important;
}
@media (max-width: 768px){
  .rp-prof-panel .rp-session-history-card > .rp-history-summary,
  .rp-prof-panel .rp-cancel-history-card > .rp-history-summary{
    min-height:46px!important;
    padding:12px 14px!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-history-body{
    padding:12px!important;
    overflow:hidden!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-toolbar{
    display:flex!important;
    flex-direction:column!important;
    gap:9px!important;
    width:100%!important;
    max-width:100%!important;
    overflow:hidden!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-filters,
  .rp-prof-panel .rp-session-history-card .rp-session-history-status-filters{
    display:flex!important;
    flex-wrap:wrap!important;
    gap:7px!important;
    width:100%!important;
    max-width:100%!important;
    margin:0!important;
    overflow:visible!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-filters button,
  .rp-prof-panel .rp-session-history-card .rp-session-history-status-filters button{
    min-height:34px!important;
    height:34px!important;
    padding:0 12px!important;
    font-size:12px!important;
    line-height:1!important;
    border-radius:999px!important;
    white-space:nowrap!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters{
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:8px!important;
    width:100%!important;
    max-width:100%!important;
    padding:0!important;
    margin:2px 0 0!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters label{
    display:flex!important;
    flex-direction:column!important;
    gap:5px!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    margin:0!important;
    padding:0!important;
    overflow:hidden!important;
    color:#1f2937!important;
    font-size:12px!important;
    line-height:1.15!important;
    font-weight:600!important;
    box-sizing:border-box!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters input[type="date"]{
    display:block!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    inline-size:100%!important;
    max-inline-size:100%!important;
    height:38px!important;
    min-height:38px!important;
    line-height:38px!important;
    margin:0!important;
    padding:0 8px!important;
    border:1px solid #d7dee8!important;
    border-radius:10px!important;
    background:#fff!important;
    color:#102a56!important;
    font-size:13px!important;
    font-weight:400!important;
    box-sizing:border-box!important;
    -webkit-appearance:none!important;
    appearance:none!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters input[type="date"]::-webkit-date-and-time-value{
    text-align:left!important;
    min-width:0!important;
    width:100%!important;
    padding:0!important;
    margin:0!important;
    line-height:38px!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters input[type="date"]::-webkit-calendar-picker-indicator{
    width:16px!important;
    height:16px!important;
    padding:0!important;
    margin:0!important;
  }
  .rp-prof-panel .rp-session-history-card .rp-session-history-date-filters button[data-rp-session-clear-dates]{
    grid-column:1 / -1!important;
    justify-self:start!important;
    width:auto!important;
    min-width:0!important;
    max-width:100%!important;
    height:34px!important;
    min-height:34px!important;
    padding:0 13px!important;
    margin:0!important;
    border-radius:10px!important;
    font-size:12px!important;
    line-height:1!important;
    box-sizing:border-box!important;
  }
}

/* v449 - Popups contador / alarma / cierre de sesión con estilo RedPsico */
.rp-session-floating{
  background:#fff!important;
  border:1px solid #dbe4ef!important;
  border-radius:18px!important;
  box-shadow:0 22px 60px rgba(16,42,86,.18)!important;
  color:#102A56!important;
  padding:16px!important;
}
.rp-session-floating-head span{
  display:inline-flex!important;align-items:center!important;gap:7px!important;
  background:#f5f8fc!important;color:#102A56!important;border:1px solid #dbe4ef!important;
  border-radius:999px!important;padding:6px 10px!important;font-size:12px!important;font-weight:400!important;
}
.rp-session-floating-head span svg,
.rp-session-floating-actions svg,
.rp-session-history-btn svg,
.rp-session-alarm-box svg,
.rp-dashboard-payment-box svg,
.rp-dashboard-payment-actions svg{
  width:17px!important;height:17px!important;display:inline-block!important;flex:0 0 17px!important;
  fill:none!important;stroke:currentColor!important;stroke-width:1.8!important;stroke-linecap:round!important;stroke-linejoin:round!important;
}
.rp-session-floating-head button{
  color:#102A56!important;background:transparent!important;border:0!important;font-weight:400!important;
}
.rp-session-floating strong[data-rp-session-float-time],
.rp-session-floating strong{
  color:#102A56!important;font-weight:400!important;font-size:34px!important;
}
.rp-session-floating-meta p,
.rp-session-floating-patient-row p{
  color:#475569!important;font-size:14px!important;font-weight:400!important;margin:0 0 10px!important;
}
.rp-session-history-btn{
  width:100%!important;justify-content:center!important;margin:8px 0 12px!important;
  border:1px solid #dbe4ef!important;background:#fff!important;color:#102A56!important;
  border-radius:12px!important;min-height:42px!important;font-size:13px!important;font-weight:400!important;
}
.rp-session-floating-actions{display:grid!important;grid-template-columns:1fr 1fr!important;gap:10px!important;justify-content:stretch!important}
.rp-session-floating .rp-session-floating-actions .rp-btn,
.rp-session-floating .rp-session-floating-actions button{
  display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:8px!important;
  min-height:44px!important;border-radius:12px!important;font-weight:400!important;font-size:13px!important;box-shadow:none!important;
}
.rp-session-floating .rp-session-floating-actions [data-rp-session-hide-btn]{
  background:#fff!important;color:#102A56!important;border:1px solid #102A56!important;
}
.rp-session-floating .rp-session-floating-actions [data-rp-session-finish]{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;color:#fff!important;border:1px solid #102A56!important;
}
@media(max-width:640px){
  .rp-session-floating{left:10px!important;right:10px!important;bottom:12px!important;width:auto!important}
  .rp-session-floating-actions{grid-template-columns:1fr!important}
}

.rp-session-alarm-box{
  background:#fff!important;border:1px solid #dbe4ef!important;border-radius:18px!important;
  box-shadow:0 22px 60px rgba(16,42,86,.20)!important;color:#102A56!important;padding:16px!important;
}
.rp-session-alarm-box strong{
  color:#102A56!important;font-size:16px!important;font-weight:400!important;display:flex!important;align-items:center!important;gap:8px!important;
}
.rp-session-alarm-box p{color:#475569!important;font-size:14px!important;font-weight:400!important}
.rp-session-alarm-box .rp-session-alarm-stop{
  display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:8px!important;
  min-height:42px!important;border-radius:12px!important;background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;color:#fff!important;
  border:1px solid #102A56!important;font-weight:400!important;box-shadow:none!important;
}
@media(max-width:640px){.rp-session-alarm-box{left:10px!important;right:10px!important;width:auto!important}.rp-session-alarm-box .rp-session-alarm-stop{width:100%!important}}

.rp-dashboard-payment-modal{background:rgba(15,23,42,.48)!important;backdrop-filter:blur(3px)!important}
.rp-dashboard-payment-box{
  border-radius:18px!important;border:1px solid #dbe4ef!important;box-shadow:0 24px 70px rgba(16,42,86,.22)!important;color:#102A56!important;
}
.rp-dashboard-payment-box small{
  display:inline-flex!important;align-items:center!important;gap:7px!important;background:#f5f8fc!important;color:#102A56!important;
  border:1px solid #dbe4ef!important;border-radius:999px!important;font-size:12px!important;font-weight:400!important;
}
.rp-dashboard-payment-box h3{color:#102A56!important;font-weight:400!important}
.rp-dashboard-payment-box p{color:#475569!important;font-weight:400!important}
.rp-dashboard-payment-close{color:#102A56!important}
.rp-dashboard-payment-actions .rp-btn{
  display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:8px!important;
  min-height:42px!important;border-radius:12px!important;font-weight:400!important;box-shadow:none!important;
}
.rp-dashboard-payment-actions [data-rp-pay-noshow],
.rp-dashboard-payment-actions [data-rp-pay-unpaid]{
  background:#fff!important;color:#102A56!important;border:1px solid #102A56!important;
}
.rp-dashboard-payment-actions [data-rp-pay-yes]{
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;color:#fff!important;border:1px solid #102A56!important;
}
@media(max-width:640px){.rp-dashboard-payment-actions{display:grid!important;grid-template-columns:1fr!important;gap:10px!important}.rp-dashboard-payment-actions .rp-btn{width:100%!important}}

/* v452 - Calendario general móvil compacto estilo app: 7 columnas visibles sin scroll horizontal */
@media (max-width: 768px){
  .rp-prof-panel #calendario-general .rp-general-month-card{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    overflow:visible!important;
    padding:14px 10px 12px!important;
    border-radius:16px!important;
    box-sizing:border-box!important;
  }
  .rp-prof-panel #calendario-general .rp-general-month-card .rp-calendar-title{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    display:grid!important;
    grid-template-columns:38px minmax(0,1fr) 38px!important;
    gap:8px!important;
    align-items:center!important;
    margin:0 0 10px!important;
  }
  .rp-prof-panel #calendario-general .rp-general-month-card .rp-calendar-title .rp-btn,
  .rp-prof-panel #calendario-general .rp-general-month-card .rp-calendar-title a{
    width:38px!important;
    height:38px!important;
    min-width:38px!important;
    min-height:38px!important;
    padding:0!important;
    border-radius:12px!important;
    font-size:22px!important;
    line-height:1!important;
  }
  .rp-prof-panel #calendario-general .rp-general-month-card .rp-calendar-title strong{
    font-size:24px!important;
    line-height:1.05!important;
    text-align:center!important;
    display:block!important;
    margin:0!important;
    white-space:nowrap!important;
  }
  .rp-prof-panel #calendario-general .rp-general-month-card .rp-calendar-title span{
    display:none!important;
  }
  .rp-prof-panel #calendario-general .rp-calendar-weekdays{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    display:grid!important;
    grid-template-columns:repeat(7,minmax(0,1fr))!important;
    gap:3px!important;
    margin:0 0 6px!important;
    overflow:visible!important;
  }
  .rp-prof-panel #calendario-general .rp-calendar-weekdays span{
    width:auto!important;
    min-width:0!important;
    max-width:none!important;
    display:block!important;
    text-align:center!important;
    font-size:11px!important;
    line-height:1!important;
    font-weight:700!important;
    color:#101828!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid.rp-admin-calendar{
    width:100%!important;
    min-width:0!important;
    max-width:100%!important;
    display:grid!important;
    grid-template-columns:repeat(7,minmax(0,1fr))!important;
    gap:3px!important;
    overflow:visible!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-empty{
    display:block!important;
    visibility:hidden!important;
    width:auto!important;
    min-width:0!important;
    max-width:none!important;
    min-height:46px!important;
    height:46px!important;
    padding:0!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell{
    width:auto!important;
    min-width:0!important;
    max-width:none!important;
    min-height:46px!important;
    height:46px!important;
    padding:4px 2px!important;
    border-radius:9px!important;
    display:flex!important;
    flex-direction:column!important;
    align-items:center!important;
    justify-content:flex-start!important;
    gap:2px!important;
    overflow:hidden!important;
    text-align:center!important;
    box-sizing:border-box!important;
    background:#fff!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell strong{
    font-size:15px!important;
    line-height:18px!important;
    margin:0!important;
    padding:0!important;
    color:#101828!important;
    font-weight:700!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell span,
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell em{
    display:none!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell::after{
    content:"";
    display:block;
    width:5px;
    height:5px;
    border-radius:999px;
    margin-top:1px;
    background:transparent;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell.is-free::after{
    background:#22c55e!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell.has-patients::after{
    background:#0ea5e9!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell.has-blocks::after,
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell.is-blocked::after{
    background:#f97316!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell.selected{
    border-color:#0b78aa!important;
    box-shadow:0 0 0 2px rgba(11,120,170,.14)!important;
    background:#f8fcff!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell.is-blocked{
    opacity:.68!important;
    background:#f8fafc!important;
  }
}

/* v453 - Calendario general: líneas compactas por turno y vista diaria por hora */
.rp-general-month-lines{
  display:flex;
  flex-direction:column;
  gap:3px;
  margin-top:8px;
  min-width:0;
}
.rp-general-month-lines .rp-month-line,
.rp-general-month-lines .rp-more{
  display:block;
  width:100%;
  max-width:100%;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  border-radius:8px;
  padding:3px 6px;
  background:#eaf7ff;
  color:#0b4365;
  font-size:11px;
  line-height:1.15;
  font-weight:400;
  border:1px solid rgba(30,142,196,.18);
}
.rp-general-month-lines .rp-month-line.is-block{
  background:#fff4ec;
  color:#8f3a12;
  border-color:rgba(210,100,34,.22);
}
.rp-general-month-lines .rp-more{
  background:#f3f6fa;
  color:#64748b;
  border-color:#e4eaf2;
}
.rp-general-day-timeline{
  border:1px solid #e6edf5;
  border-radius:18px;
  overflow:hidden;
  background:#fff;
  margin-top:10px;
}
.rp-timeline-hour-row{
  display:grid;
  grid-template-columns:78px minmax(0,1fr);
  min-height:54px;
  border-bottom:1px solid #eef3f8;
}
.rp-timeline-hour-row:last-child{border-bottom:0;}
.rp-timeline-hour{
  padding:14px 12px;
  color:#64748b;
  font-size:14px;
  font-weight:400;
  border-right:1px solid #eef3f8;
  background:#fbfdff;
}
.rp-timeline-items{
  padding:8px 10px;
  display:flex;
  flex-direction:column;
  gap:7px;
  min-width:0;
}
.rp-timeline-empty{
  color:#a3adba;
  font-size:13px;
  line-height:36px;
  font-weight:400;
}
.rp-timeline-item{
  border:1px solid #cfe8f5;
  background:#eefaff;
  border-radius:12px;
  padding:8px 10px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  min-width:0;
}
.rp-timeline-item strong{
  color:#0b2b5b;
  font-size:14px;
  line-height:1.2;
  font-weight:600;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.rp-timeline-item span{
  color:#64748b;
  font-size:12px;
  font-weight:400;
  white-space:nowrap;
}
.rp-timeline-item.is-block{
  background:#fff7ed;
  border-color:#fed7aa;
}
.rp-timeline-item.is-block strong{color:#8a3a0c;}
.rp-timeline-item .rp-general-block-actions{
  display:flex;
  gap:6px;
  flex-wrap:wrap;
}
@media(max-width:720px){
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell{
    min-height:76px !important;
    padding:7px 5px !important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell strong{
    font-size:17px !important;
    margin-bottom:3px !important;
  }
  .rp-general-month-lines{gap:2px;margin-top:4px;}
  .rp-general-month-lines .rp-month-line,
  .rp-general-month-lines .rp-more{
    font-size:9.5px;
    padding:2px 4px;
    border-radius:6px;
  }
  .rp-timeline-hour-row{
    grid-template-columns:54px minmax(0,1fr);
    min-height:48px;
  }
  .rp-timeline-hour{
    padding:12px 7px;
    font-size:12px;
  }
  .rp-timeline-items{padding:7px;gap:6px;}
  .rp-timeline-item{
    border-radius:10px;
    padding:7px 8px;
    display:block;
  }
  .rp-timeline-item strong{
    display:block;
    font-size:13px;
  }
  .rp-timeline-item span{
    display:block;
    margin-top:2px;
    font-size:11px;
  }
  .rp-timeline-empty{
    font-size:12px;
    line-height:32px;
  }
}

/* v454 - Calendario general: en vista mensual mostrar pacientes/bloqueos por línea, no puntos genéricos. */
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-general-month-lines{
  display:flex!important;
  flex-direction:column!important;
  gap:3px!important;
  margin-top:6px!important;
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  overflow:hidden!important;
}
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-general-month-lines .rp-month-line,
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-general-month-lines .rp-more{
  display:block!important;
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  white-space:nowrap!important;
  border-radius:7px!important;
  padding:2px 5px!important;
  background:#eaf7ff!important;
  color:#0b4365!important;
  -webkit-text-fill-color:#0b4365!important;
  border:1px solid rgba(30,142,196,.18)!important;
  font-size:10.5px!important;
  line-height:1.15!important;
  font-weight:400!important;
  text-align:left!important;
}
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-general-month-lines .rp-month-line.is-block{
  background:#fff4ec!important;
  color:#8f3a12!important;
  -webkit-text-fill-color:#8f3a12!important;
  border-color:rgba(210,100,34,.22)!important;
}
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-general-month-lines .rp-more{
  background:#f3f6fa!important;
  color:#64748b!important;
  -webkit-text-fill-color:#64748b!important;
  border-color:#e4eaf2!important;
  text-align:center!important;
}
@media(max-width:760px){
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell{
    min-height:78px!important;
    padding:5px 3px!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell strong{
    font-size:16px!important;
    margin-bottom:2px!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-general-month-lines{
    gap:2px!important;
    margin-top:3px!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-general-month-lines .rp-month-line,
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-general-month-lines .rp-more{
    font-size:8.5px!important;
    line-height:1.05!important;
    padding:2px 3px!important;
    border-radius:5px!important;
  }
}

/* v456 - Calendario general mensual: texto limpio por línea, sin chips ni puntos.
   Muestra únicamente nombre/apellido del paciente o referencia del bloqueo,
   respetando el orden cronológico generado en PHP. */
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell::after{
  display:none!important;
  content:none!important;
}
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-general-month-lines{
  display:flex!important;
  flex-direction:column!important;
  align-items:stretch!important;
  justify-content:flex-start!important;
  gap:1px!important;
  margin-top:2px!important;
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  overflow:hidden!important;
}
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-general-month-lines .rp-month-line,
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-general-month-lines .rp-more{
  display:block!important;
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  padding:0!important;
  margin:0!important;
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
  box-shadow:none!important;
  color:#0f172a!important;
  -webkit-text-fill-color:#0f172a!important;
  font-weight:400!important;
  font-size:10px!important;
  line-height:1.05!important;
  text-align:left!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:clip!important;
}
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-general-month-lines .rp-month-line.is-block{
  color:#8a3a0c!important;
  -webkit-text-fill-color:#8a3a0c!important;
}
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-general-month-lines .rp-more{
  color:#64748b!important;
  -webkit-text-fill-color:#64748b!important;
}
@media(max-width:760px){
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell{
    min-height:78px!important;
    padding:5px 2px!important;
    gap:1px!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell strong{
    font-size:15px!important;
    line-height:17px!important;
    margin:0 0 2px!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-general-month-lines{
    gap:1px!important;
    margin-top:1px!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-general-month-lines .rp-month-line,
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-general-month-lines .rp-more{
    font-size:7.2px!important;
    line-height:1.05!important;
    letter-spacing:-.15px!important;
  }
}


/* v457 - Calendario general interactivo: timeline y popups */
.rp-general-day-timeline .rp-timeline-items{
  min-width:0;
}
.rp-timeline-open{
  width:100%;
  border:0;
  background:transparent;
  padding:0;
  margin:0;
  text-align:left;
  color:inherit;
  cursor:pointer;
  display:block;
}
.rp-timeline-open strong,
.rp-timeline-open span{
  display:block;
}
.rp-timeline-item{
  border-left:3px solid #22c55e;
}
.rp-timeline-item.rp-freq-quincenal{border-left-color:#f97316}
.rp-timeline-item.rp-freq-mensual{border-left-color:#eab308}
.rp-timeline-item.rp-freq-rotativa{border-left-color:#d946ef}
.rp-timeline-item.is-block{border-left-color:#f59e0b}
.rp-timeline-add-empty{
  min-height:42px;
  width:100%;
  border:1px dashed #cbd5e1;
  background:#fff;
  color:#0f2f57;
  border-radius:12px;
  display:flex;
  align-items:center;
  justify-content:center;
  cursor:pointer;
}
.rp-timeline-add-empty svg{
  width:18px;
  height:18px;
}
.rp-timeline-add-empty:hover{
  border-color:#0f2f57;
  background:#f8fafc;
}
.rp-agenda-popup-layer[hidden]{display:none!important}
.rp-agenda-popup-layer{
  position:fixed;
  inset:0;
  z-index:999999;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:18px;
}
.rp-agenda-popup-backdrop{
  position:absolute;
  inset:0;
  background:rgba(15,23,42,.46);
  backdrop-filter:blur(3px);
}
.rp-agenda-popup-card{
  position:relative;
  z-index:1;
  width:min(480px, calc(100vw - 24px));
  max-height:min(82vh, 680px);
  overflow:auto;
  background:#fff;
  border:1px solid #e2e8f0;
  border-radius:22px;
  padding:18px;
  box-shadow:0 20px 60px rgba(15,23,42,.22);
}
.rp-agenda-popup-x{
  position:absolute;
  top:10px;
  right:10px;
  width:34px;
  height:34px;
  border-radius:999px;
  border:1px solid #e2e8f0;
  background:#fff;
  color:#0f172a;
  font-size:22px;
  line-height:1;
  cursor:pointer;
}
.rp-agenda-popup-head{
  display:flex;
  align-items:center;
  gap:12px;
  padding-right:34px;
  margin-bottom:14px;
}
.rp-agenda-popup-mainicon{
  width:42px;
  height:42px;
  border-radius:14px;
  background:#eef6ff;
  color:#0f2f57;
  display:flex;
  align-items:center;
  justify-content:center;
  flex:0 0 auto;
}
.rp-agenda-popup-head.is-block .rp-agenda-popup-mainicon{
  background:#fff7ed;
  color:#c2410c;
}
.rp-agenda-popup-head h3{
  margin:0;
  color:#0f172a;
  font-size:18px;
  font-weight:700;
  line-height:1.2;
}
.rp-agenda-popup-head p{
  margin:3px 0 0;
  color:#64748b;
  font-size:13px;
  font-weight:400;
}
.rp-agenda-popup-svg{
  width:18px;
  height:18px;
  flex:0 0 auto;
}
.rp-agenda-popup-frequency{
  display:inline-flex;
  align-items:center;
  gap:7px;
  border-radius:999px;
  padding:7px 11px;
  margin-bottom:14px;
  font-size:13px;
  font-weight:600;
}
.rp-agenda-popup-frequency.is-semanal{background:#ecfdf5;color:#15803d}
.rp-agenda-popup-frequency.is-quincenal{background:#fff7ed;color:#c2410c}
.rp-agenda-popup-frequency.is-mensual{background:#fef9c3;color:#854d0e}
.rp-agenda-popup-frequency.is-rotativa{background:#fdf4ff;color:#a21caf}
.rp-agenda-popup-info{
  display:grid;
  gap:9px;
  margin:2px 0 16px;
}
.rp-agenda-popup-info > div{
  display:grid;
  grid-template-columns:20px minmax(70px,.6fr) minmax(0,1fr);
  gap:8px;
  align-items:center;
  padding:9px 10px;
  border:1px solid #e2e8f0;
  background:#f8fafc;
  border-radius:14px;
  color:#0f2f57;
}
.rp-agenda-popup-info span{
  color:#64748b;
  font-size:12px;
  font-weight:400;
}
.rp-agenda-popup-info strong{
  color:#0f172a;
  font-size:13px;
  font-weight:600;
  text-align:right;
  overflow-wrap:anywhere;
}
.rp-agenda-popup-actions{
  display:flex;
  gap:9px;
  flex-wrap:wrap;
  margin-top:8px;
}
.rp-agenda-popup-action{
  flex:1 1 160px;
  justify-content:center;
  gap:7px;
}
.rp-agenda-popup-action svg{
  width:17px;
  height:17px;
}
.rp-agenda-popup-note{
  margin:0 0 12px;
  border:1px solid #fde68a;
  background:#fffbeb;
  color:#92400e;
  border-radius:14px;
  padding:10px 12px;
  font-size:13px;
  font-weight:400;
}
.rp-agenda-empty-options{
  display:grid;
  gap:10px;
}
.rp-agenda-empty-option{
  border:1px solid #dbe4ef;
  border-radius:16px;
  background:#fff;
  color:#0f2f57;
  display:flex;
  align-items:center;
  gap:10px;
  padding:14px;
  font-size:14px;
  font-weight:600;
  cursor:pointer;
  text-align:left;
}
.rp-agenda-empty-option:hover{
  background:#f8fafc;
  border-color:#0f2f57;
}
html.rp-agenda-popup-open body{
  overflow:hidden;
}
@media (max-width: 768px){
  .rp-agenda-popup-layer{
    align-items:flex-end;
    padding:10px;
  }
  .rp-agenda-popup-card{
    width:100%;
    max-height:88vh;
    border-radius:22px 22px 16px 16px;
    padding:16px;
  }
  .rp-agenda-popup-info > div{
    grid-template-columns:20px 82px minmax(0,1fr);
  }
  .rp-agenda-popup-actions{
    flex-direction:column;
  }
  .rp-agenda-popup-action{
    width:100%;
    flex-basis:auto;
  }
  .rp-timeline-add-empty{
    min-height:38px;
  }
}

/* v458 - Calendario general: formulario de bloqueo dentro del popup, no fijo en la página */
.rp-general-block-form-template[hidden],
.rp-general-block-form[hidden]{
  display:none!important;
}
.rp-general-block-form-popup{
  margin:0!important;
  padding:0!important;
  border:0!important;
}
.rp-general-block-form-popup .rp-agenda-block-popup-form{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:12px;
  margin-top:10px;
}
.rp-general-block-form-popup .rp-agenda-block-popup-form label{
  display:flex;
  flex-direction:column;
  gap:7px;
  font-size:13px;
  font-weight:600;
  color:#16233a;
}
.rp-general-block-form-popup .rp-agenda-block-popup-form label.full,
.rp-general-block-form-popup .rp-agenda-block-popup-form .full{
  grid-column:1 / -1;
}
.rp-general-block-form-popup .rp-agenda-block-popup-form input,
.rp-general-block-form-popup .rp-agenda-block-popup-form select{
  width:100%;
  min-width:0;
  height:46px;
  border:1px solid #dbe4ef;
  border-radius:14px;
  background:#fff;
  color:#0f172a;
  padding:0 13px;
  font-size:15px;
  font-weight:500;
  box-sizing:border-box;
}
.rp-general-block-form-popup .rp-agenda-block-actions{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  margin-top:2px;
}
.rp-general-block-form-popup .rp-agenda-block-actions .rp-btn{
  justify-content:center;
}
@media(max-width:768px){
  .rp-general-block-form-popup .rp-agenda-block-popup-form{
    grid-template-columns:1fr;
    gap:10px;
  }
  .rp-general-block-form-popup .rp-agenda-block-popup-form input,
  .rp-general-block-form-popup .rp-agenda-block-popup-form select{
    height:44px;
    font-size:14px;
  }
}

/* v459 - Calendario general: etapa 1 visual + popup espacio libre */
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell{
  background:#fff!important;
  border-color:#e5eaf2!important;
  color:#102a56!important;
}
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell.is-non-work{
  background:#f5f6f8!important;
  color:#7a8494!important;
}
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell.is-blocked:not(.is-non-work){
  background:#fff!important;
  border-color:#e5eaf2!important;
}
.rp-month-no-work{
  display:block!important;
  font-size:11px!important;
  line-height:1.15!important;
  font-weight:400!important;
  color:#8a94a6!important;
  margin-top:4px!important;
  white-space:nowrap!important;
}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line{
  background:transparent!important;
  border:0!important;
  border-radius:0!important;
  padding:0 0 0 7px!important;
  color:#102a56!important;
  font-size:11px!important;
  font-weight:400!important;
  line-height:1.25!important;
  display:block!important;
  position:relative!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  max-width:100%!important;
}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line:before{
  content:'';
  position:absolute;
  left:0;
  top:.42em;
  width:4px;
  height:4px;
  border-radius:50%;
  background:#2D802D;
}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-quincenal:before{background:#f59e0b!important}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-mensual:before{background:#facc15!important}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-rotativa:before{background:#d946ef!important}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.is-block:before{background:#334155!important}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.is-block{
  color:#1f2937!important;
}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-more{
  background:transparent!important;
  border:0!important;
  padding:0!important;
  font-size:10.5px!important;
  color:#667085!important;
}
.rp-agenda-popup-head p{
  font-weight:400!important;
}
@media(max-width:760px){
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell{
    min-height:74px!important;
  }
  .rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line,
  .rp-month-no-work{
    font-size:10px!important;
  }
}

/* v460 - Calendario general: eventos con fondo llamativo y texto negro, sin puntitos */
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell{
  background:#fff!important;
}
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell.is-non-work{
  background:#f3f4f6!important;
  border-color:#e5e7eb!important;
}
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell.is-non-work .rp-month-no-work{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:100%!important;
  max-width:100%!important;
  padding:2px 3px!important;
  border-radius:5px!important;
  background:#e5e7eb!important;
  color:#374151!important;
  -webkit-text-fill-color:#374151!important;
  font-size:9px!important;
  line-height:1.05!important;
  font-weight:500!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
}
.rp-prof-panel #calendario-general .rp-general-month-lines{
  gap:2px!important;
  margin-top:3px!important;
}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line,
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-more{
  display:block!important;
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  padding:2px 4px!important;
  margin:0!important;
  border:0!important;
  border-radius:5px!important;
  box-shadow:none!important;
  color:#111827!important;
  -webkit-text-fill-color:#111827!important;
  font-weight:500!important;
  font-size:9.5px!important;
  line-height:1.12!important;
  text-align:left!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  letter-spacing:-.05px!important;
}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line:before{
  display:none!important;
  content:none!important;
}
/* Frecuencias */
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-semanal,
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-diaria{
  background:#43d17c!important;
}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-quincenal{
  background:#ff9f2e!important;
}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-mensual{
  background:#ffe45c!important;
}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-rotativa,
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-libre{
  background:#f35adf!important;
}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-emergency,
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-emergencia{
  background:#ff3b3b!important;
  color:#111827!important;
  -webkit-text-fill-color:#111827!important;
}
/* Bloqueo profesional: rosa */
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.is-block{
  background:#ff9ad5!important;
  color:#111827!important;
  -webkit-text-fill-color:#111827!important;
}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-more{
  background:#e5e7eb!important;
  color:#374151!important;
  -webkit-text-fill-color:#374151!important;
  text-align:center!important;
}
@media(max-width:760px){
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell{
    min-height:76px!important;
    padding:5px 3px!important;
  }
  .rp-prof-panel #calendario-general .rp-general-month-lines{
    gap:2px!important;
    margin-top:2px!important;
  }
  .rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line,
  .rp-prof-panel #calendario-general .rp-general-month-lines .rp-more{
    font-size:7.8px!important;
    line-height:1.05!important;
    padding:2px 2px!important;
    border-radius:4px!important;
    font-weight:600!important;
  }
}

/* v461 - Calendario general: bandas de color reales por tipo/frecuencia */
.rp-prof-panel #calendario-general .rp-general-month-lines{
  display:flex!important;
  flex-direction:column!important;
  gap:2px!important;
  width:100%!important;
  overflow:hidden!important;
}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line{
  display:block!important;
  width:100%!important;
  max-width:100%!important;
  min-height:14px!important;
  padding:2px 4px!important;
  border-radius:5px!important;
  border:0!important;
  box-shadow:none!important;
  color:#111827!important;
  -webkit-text-fill-color:#111827!important;
  font-weight:600!important;
  line-height:1.12!important;
  text-align:left!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line:before{display:none!important;content:none!important;}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-semanal,
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-diaria{background:#43d17c!important;}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-quincenal{background:#ff9f2e!important;}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-mensual{background:#ffe45c!important;}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-rotativa,
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-libre{background:#f35adf!important;}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-emergency,
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-emergencia{background:#ff3b3b!important;}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.is-block{background:#ff9ad5!important;}
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell.is-non-work{background:#f3f4f6!important;}
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell.is-non-work .rp-month-no-work{background:#e5e7eb!important;color:#374151!important;-webkit-text-fill-color:#374151!important;}
@media(max-width:760px){
  .rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line{font-size:7.7px!important;padding:2px 2px!important;border-radius:4px!important;}
}

/* v462 - blindaje final calendario general: bandas visibles, no puntos */
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line,
#calendario-general .rp-general-month-lines .rp-month-line{
  display:block!important;
  width:100%!important;
  box-sizing:border-box!important;
  margin:0 0 2px 0!important;
  padding:2px 4px!important;
  border-radius:5px!important;
  color:#111827!important;
  -webkit-text-fill-color:#111827!important;
  font-weight:700!important;
  line-height:1.12!important;
  text-align:left!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  border:0!important;
  box-shadow:none!important;
}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line::before,
#calendario-general .rp-general-month-lines .rp-month-line::before{display:none!important;content:none!important;}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-semanal,
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-diaria,
#calendario-general .rp-general-month-lines .rp-month-line.rp-freq-semanal,
#calendario-general .rp-general-month-lines .rp-month-line.rp-freq-diaria{background-color:#43d17c!important;background-image:none!important;}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-quincenal,
#calendario-general .rp-general-month-lines .rp-month-line.rp-freq-quincenal{background-color:#ff9f2e!important;background-image:none!important;}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-mensual,
#calendario-general .rp-general-month-lines .rp-month-line.rp-freq-mensual{background-color:#ffe45c!important;background-image:none!important;}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-rotativa,
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-libre,
#calendario-general .rp-general-month-lines .rp-month-line.rp-freq-rotativa,
#calendario-general .rp-general-month-lines .rp-month-line.rp-freq-libre{background-color:#f35adf!important;background-image:none!important;}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-emergency,
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.rp-freq-emergencia,
#calendario-general .rp-general-month-lines .rp-month-line.rp-freq-emergency,
#calendario-general .rp-general-month-lines .rp-month-line.rp-freq-emergencia{background-color:#ff3b3b!important;background-image:none!important;}
.rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line.is-block,
#calendario-general .rp-general-month-lines .rp-month-line.is-block{background-color:#ff9ad5!important;background-image:none!important;}
@media(max-width:760px){
  .rp-prof-panel #calendario-general .rp-general-month-lines .rp-month-line,
  #calendario-general .rp-general-month-lines .rp-month-line{font-size:7.8px!important;padding:2px!important;border-radius:4px!important;}
}

/* v463 - Calendario general: el detalle por horario usa el mismo color de frecuencia en todo el globo */
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item,
#calendario-general .rp-general-day-timeline .rp-timeline-item{
  border-left:0!important;
  border-width:1px!important;
  border-style:solid!important;
  color:#111827!important;
  -webkit-text-fill-color:#111827!important;
  background-image:none!important;
  box-shadow:none!important;
}
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item strong,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item span,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-open,
#calendario-general .rp-general-day-timeline .rp-timeline-item strong,
#calendario-general .rp-general-day-timeline .rp-timeline-item span,
#calendario-general .rp-general-day-timeline .rp-timeline-open{
  color:#111827!important;
  -webkit-text-fill-color:#111827!important;
}
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-semanal,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-diaria,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-semanal,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-diaria{
  background-color:#43d17c!important;
  border-color:#22c55e!important;
}
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-quincenal,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-quincenal{
  background-color:#ff9f2e!important;
  border-color:#f97316!important;
}
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-mensual,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-mensual{
  background-color:#ffe45c!important;
  border-color:#eab308!important;
}
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-rotativa,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-libre,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-rotativa,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-libre{
  background-color:#f35adf!important;
  border-color:#d946ef!important;
}
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergency,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergencia,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergency,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergencia{
  background-color:#ff3b3b!important;
  border-color:#dc2626!important;
}
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.is-block,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-block,
#calendario-general .rp-general-day-timeline .rp-timeline-item.is-block,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-block{
  background-color:#ff9ad5!important;
  border-color:#ec4899!important;
}
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.is-block strong,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.is-block span,
#calendario-general .rp-general-day-timeline .rp-timeline-item.is-block strong,
#calendario-general .rp-general-day-timeline .rp-timeline-item.is-block span{
  color:#111827!important;
  -webkit-text-fill-color:#111827!important;
}


/* v464 - Calendario general: blindaje definitivo de hover/touch y popup sin textos blancos */
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item,
#calendario-general .rp-general-day-timeline .rp-timeline-item{
  position:relative!important;
  overflow:hidden!important;
  background-image:none!important;
  box-shadow:none!important;
  opacity:1!important;
}
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item:hover,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item:focus-within,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item:active,
#calendario-general .rp-general-day-timeline .rp-timeline-item:hover,
#calendario-general .rp-general-day-timeline .rp-timeline-item:focus-within,
#calendario-general .rp-general-day-timeline .rp-timeline-item:active{
  transform:none!important;
  filter:none!important;
  box-shadow:none!important;
  background-image:none!important;
  opacity:1!important;
}
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-open,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-open:hover,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-open:focus,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-open:focus-visible,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-open:active,
#calendario-general .rp-general-day-timeline .rp-timeline-open,
#calendario-general .rp-general-day-timeline .rp-timeline-open:hover,
#calendario-general .rp-general-day-timeline .rp-timeline-open:focus,
#calendario-general .rp-general-day-timeline .rp-timeline-open:focus-visible,
#calendario-general .rp-general-day-timeline .rp-timeline-open:active{
  width:100%!important;
  display:block!important;
  background:transparent!important;
  background-color:transparent!important;
  background-image:none!important;
  border:0!important;
  outline:0!important;
  box-shadow:none!important;
  color:#111827!important;
  -webkit-text-fill-color:#111827!important;
  text-decoration:none!important;
  opacity:1!important;
  transform:none!important;
  filter:none!important;
}
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-open strong,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-open span,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-open:hover strong,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-open:hover span,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-open:focus strong,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-open:focus span,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-open:active strong,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-open:active span,
#calendario-general .rp-general-day-timeline .rp-timeline-open strong,
#calendario-general .rp-general-day-timeline .rp-timeline-open span,
#calendario-general .rp-general-day-timeline .rp-timeline-open:hover strong,
#calendario-general .rp-general-day-timeline .rp-timeline-open:hover span,
#calendario-general .rp-general-day-timeline .rp-timeline-open:focus strong,
#calendario-general .rp-general-day-timeline .rp-timeline-open:focus span,
#calendario-general .rp-general-day-timeline .rp-timeline-open:active strong,
#calendario-general .rp-general-day-timeline .rp-timeline-open:active span{
  color:#111827!important;
  -webkit-text-fill-color:#111827!important;
  opacity:1!important;
  text-shadow:none!important;
}
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-semanal,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-semanal:hover,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-semanal:focus-within,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-semanal:active,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-diaria,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-diaria:hover,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-diaria:focus-within,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-diaria:active,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-semanal,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-semanal:hover,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-semanal:focus-within,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-semanal:active,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-diaria,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-diaria:hover,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-diaria:focus-within,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-diaria:active{background-color:#43d17c!important;border-color:#22c55e!important;}
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-quincenal,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-quincenal:hover,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-quincenal:focus-within,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-quincenal:active,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-quincenal,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-quincenal:hover,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-quincenal:focus-within,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-quincenal:active{background-color:#ff9f2e!important;border-color:#f97316!important;}
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-mensual,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-mensual:hover,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-mensual:focus-within,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-mensual:active,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-mensual,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-mensual:hover,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-mensual:focus-within,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-mensual:active{background-color:#ffe45c!important;border-color:#eab308!important;}
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-rotativa,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-rotativa:hover,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-rotativa:focus-within,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-rotativa:active,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-libre,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-libre:hover,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-libre:focus-within,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-libre:active,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-rotativa,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-rotativa:hover,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-rotativa:focus-within,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-rotativa:active,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-libre,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-libre:hover,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-libre:focus-within,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-libre:active{background-color:#f35adf!important;border-color:#d946ef!important;}
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergency,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergency:hover,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergency:focus-within,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergency:active,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergencia,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergencia:hover,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergencia:focus-within,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergencia:active,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergency,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergency:hover,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergency:focus-within,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergency:active,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergencia,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergencia:hover,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergencia:focus-within,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-emergencia:active{background-color:#ff3b3b!important;border-color:#dc2626!important;}
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.is-block,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.is-block:hover,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.is-block:focus-within,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.is-block:active,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-block,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-block:hover,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-block:focus-within,
.rp-prof-panel #calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-block:active,
#calendario-general .rp-general-day-timeline .rp-timeline-item.is-block,
#calendario-general .rp-general-day-timeline .rp-timeline-item.is-block:hover,
#calendario-general .rp-general-day-timeline .rp-timeline-item.is-block:focus-within,
#calendario-general .rp-general-day-timeline .rp-timeline-item.is-block:active,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-block,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-block:hover,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-block:focus-within,
#calendario-general .rp-general-day-timeline .rp-timeline-item.rp-freq-block:active{background-color:#ff9ad5!important;border-color:#ec4899!important;}
.rp-agenda-popup-card .rp-agenda-empty-option,
.rp-agenda-popup-card .rp-agenda-empty-option:hover,
.rp-agenda-popup-card .rp-agenda-empty-option:focus,
.rp-agenda-popup-card .rp-agenda-empty-option:active{
  background:#ffffff!important;
  background-color:#ffffff!important;
  background-image:none!important;
  border:1px solid #dbe4ef!important;
  color:#0f2f57!important;
  -webkit-text-fill-color:#0f2f57!important;
  opacity:1!important;
  filter:none!important;
  box-shadow:none!important;
  outline:0!important;
}
.rp-agenda-popup-card .rp-agenda-empty-option:hover,
.rp-agenda-popup-card .rp-agenda-empty-option:focus,
.rp-agenda-popup-card .rp-agenda-empty-option:active{
  border-color:#0f2f57!important;
  background:#f8fafc!important;
}
.rp-agenda-popup-card .rp-agenda-empty-option span,
.rp-agenda-popup-card .rp-agenda-empty-option svg,
.rp-agenda-popup-card .rp-agenda-empty-option:hover span,
.rp-agenda-popup-card .rp-agenda-empty-option:hover svg,
.rp-agenda-popup-card .rp-agenda-empty-option:focus span,
.rp-agenda-popup-card .rp-agenda-empty-option:focus svg,
.rp-agenda-popup-card .rp-agenda-empty-option:active span,
.rp-agenda-popup-card .rp-agenda-empty-option:active svg{
  color:#0f2f57!important;
  -webkit-text-fill-color:#0f2f57!important;
  stroke:currentColor!important;
  opacity:1!important;
  visibility:visible!important;
  display:inline-flex!important;
}

/* v465 calendario general: alta rápida paciente desde + y bloqueo sin fecha visible */
.rp-agenda-popup-card .rp-gc-block-date-field{display:none!important}
.rp-gc-patient-search-label{position:relative!important}
.rp-gc-patient-results{position:absolute;left:0;right:0;top:calc(100% - 2px);z-index:30;background:#fff;border:1px solid #dbe4ee;border-radius:14px;box-shadow:0 12px 28px rgba(15,23,42,.12);padding:6px;max-height:240px;overflow:auto}
.rp-gc-patient-result{width:100%;display:flex;align-items:flex-start;justify-content:space-between;gap:10px;text-align:left;border:0!important;background:#fff!important;color:#0f172a!important;border-radius:11px!important;padding:10px 11px!important;cursor:pointer;font-weight:400!important}
.rp-gc-patient-result:hover,.rp-gc-patient-result:focus{background:#f1f7ff!important;color:#0f172a!important;outline:none!important}
.rp-gc-patient-result strong{font-weight:700;color:#0f172a!important}
.rp-gc-patient-result span{font-size:12px;color:#64748b!important;white-space:nowrap}
.rp-gc-patient-picked{display:flex;flex-wrap:wrap;gap:8px;padding:10px 12px;border:1px solid #dbeafe;border-radius:14px;background:#f8fbff;color:#0f172a;font-size:13px}
.rp-gc-patient-picked span{display:inline-flex;gap:4px;align-items:center;color:#334155}
.rp-gc-frequency-warning{border:1px solid #fed7aa;border-radius:14px;background:#fff7ed;color:#7c2d12;padding:12px;line-height:1.35}
.rp-gc-frequency-warning strong{color:#7c2d12!important}
.rp-gc-frequency-options{display:flex;gap:8px;flex-wrap:wrap;margin-top:10px}
.rp-gc-appointment-actions{display:flex;gap:10px;justify-content:flex-end;flex-wrap:wrap}
.rp-field-error{border-color:#ef4444!important;box-shadow:0 0 0 3px rgba(239,68,68,.12)!important}
@media(max-width:640px){.rp-gc-patient-result{display:block}.rp-gc-patient-result span{display:block;margin-top:4px}.rp-gc-appointment-actions .rp-btn{width:100%;justify-content:center}.rp-gc-frequency-options .rp-btn{width:100%;justify-content:center}}

/* v468 - alta rápida: aviso de frecuencia integrado a estética RedPsico */
.rp-agenda-popup-card .rp-emergency-switch{display:none!important}
.rp-agenda-popup-card .rp-gc-frequency-warning.rp-gc-frequency-card{
  position:relative!important;
  display:block!important;
  margin-top:12px!important;
  padding:14px 14px 14px 18px!important;
  border:1px solid #dbe4ee!important;
  border-left:5px solid #1d4ed8!important;
  border-radius:18px!important;
  background:#ffffff!important;
  color:#0f172a!important;
  box-shadow:none!important;
  line-height:1.35!important;
  overflow:hidden!important;
}
.rp-agenda-popup-card .rp-gc-frequency-warning.rp-gc-frequency-card[hidden]{display:none!important}
.rp-agenda-popup-card .rp-gc-frequency-warning.rp-gc-frequency-card.is-semanal{border-left-color:#22c55e!important}
.rp-agenda-popup-card .rp-gc-frequency-warning.rp-gc-frequency-card.is-quincenal{border-left-color:#f97316!important}
.rp-agenda-popup-card .rp-gc-frequency-warning.rp-gc-frequency-card.is-mensual{border-left-color:#eab308!important}
.rp-agenda-popup-card .rp-gc-frequency-warning.rp-gc-frequency-card.is-rotativa{border-left-color:#d946ef!important}
.rp-agenda-popup-card .rp-gc-frequency-warning.rp-gc-frequency-card.is-emergency,
.rp-agenda-popup-card .rp-gc-frequency-warning.rp-gc-frequency-card.rp-gc-mode-emergency{border-left-color:#ef4444!important}
.rp-agenda-popup-card .rp-gc-warning-head{display:flex!important;align-items:flex-start!important;gap:11px!important;margin:0!important;color:#0f172a!important}
.rp-agenda-popup-card .rp-gc-warning-icon{width:34px!important;height:34px!important;min-width:34px!important;border-radius:12px!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;background:#f1f7ff!important;color:#0f2f57!important}
.rp-agenda-popup-card .rp-gc-warning-icon svg{width:19px!important;height:19px!important;display:block!important;fill:none!important;stroke:currentColor!important;stroke-width:1.8!important;stroke-linecap:round!important;stroke-linejoin:round!important}
.rp-agenda-popup-card .rp-gc-frequency-card.is-semanal .rp-gc-warning-icon{background:#ecfdf3!important;color:#16a34a!important}
.rp-agenda-popup-card .rp-gc-frequency-card.is-quincenal .rp-gc-warning-icon{background:#fff7ed!important;color:#ea580c!important}
.rp-agenda-popup-card .rp-gc-frequency-card.is-mensual .rp-gc-warning-icon{background:#fefce8!important;color:#a16207!important}
.rp-agenda-popup-card .rp-gc-frequency-card.is-rotativa .rp-gc-warning-icon{background:#fdf4ff!important;color:#c026d3!important}
.rp-agenda-popup-card .rp-gc-mode-emergency .rp-gc-warning-icon{background:#fef2f2!important;color:#dc2626!important}
.rp-agenda-popup-card .rp-gc-warning-head strong{display:block!important;color:#0f172a!important;font-size:14px!important;font-weight:700!important;letter-spacing:-.01em!important;margin:0 0 3px!important}
.rp-agenda-popup-card .rp-gc-warning-head small{display:block!important;color:#64748b!important;font-size:12.5px!important;font-weight:400!important;line-height:1.35!important;margin:0!important}
.rp-agenda-popup-card .rp-gc-warning-pill{display:inline-flex!important;align-items:center!important;margin:12px 0 0 45px!important;padding:5px 10px!important;border-radius:999px!important;background:#f8fafc!important;border:1px solid #e2e8f0!important;color:#334155!important;font-size:12px!important;font-weight:600!important}
.rp-agenda-popup-card .rp-gc-frequency-card.is-semanal .rp-gc-warning-pill{background:#ecfdf3!important;border-color:#bbf7d0!important;color:#166534!important}
.rp-agenda-popup-card .rp-gc-frequency-card.is-quincenal .rp-gc-warning-pill{background:#fff7ed!important;border-color:#fed7aa!important;color:#9a3412!important}
.rp-agenda-popup-card .rp-gc-frequency-card.is-mensual .rp-gc-warning-pill{background:#fefce8!important;border-color:#fde68a!important;color:#854d0e!important}
.rp-agenda-popup-card .rp-gc-frequency-card.is-rotativa .rp-gc-warning-pill{background:#fdf4ff!important;border-color:#f5d0fe!important;color:#86198f!important}
.rp-agenda-popup-card .rp-gc-frequency-options{display:flex!important;gap:9px!important;flex-wrap:wrap!important;margin:12px 0 0 45px!important}
.rp-agenda-popup-card .rp-gc-action-btn,
.rp-agenda-popup-card .rp-gc-action-btn:hover,
.rp-agenda-popup-card .rp-gc-action-btn:focus,
.rp-agenda-popup-card .rp-gc-action-btn:active{
  min-height:38px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:8px!important;
  border-radius:13px!important;
  padding:9px 13px!important;
  font-size:13px!important;
  font-weight:600!important;
  line-height:1!important;
  text-decoration:none!important;
  cursor:pointer!important;
  box-shadow:none!important;
  outline:none!important;
  opacity:1!important;
  filter:none!important;
  transition:background .15s ease,border-color .15s ease,transform .15s ease!important;
}
.rp-agenda-popup-card .rp-gc-action-btn:active{transform:translateY(1px)!important}
.rp-agenda-popup-card .rp-gc-action-btn svg{width:17px!important;height:17px!important;fill:none!important;stroke:currentColor!important;stroke-width:1.8!important;stroke-linecap:round!important;stroke-linejoin:round!important}
.rp-agenda-popup-card .rp-gc-action-reprogram,
.rp-agenda-popup-card .rp-gc-action-reprogram:hover,
.rp-agenda-popup-card .rp-gc-action-reprogram:focus,
.rp-agenda-popup-card .rp-gc-action-reprogram:active{background:#ffffff!important;border:1px solid #0f2f57!important;color:#0f2f57!important;-webkit-text-fill-color:#0f2f57!important}
.rp-agenda-popup-card .rp-gc-action-reprogram:hover,
.rp-agenda-popup-card .rp-gc-action-reprogram:focus{background:#f1f7ff!important}
.rp-agenda-popup-card .rp-gc-action-emergency,
.rp-agenda-popup-card .rp-gc-action-emergency:hover,
.rp-agenda-popup-card .rp-gc-action-emergency:focus,
.rp-agenda-popup-card .rp-gc-action-emergency:active{background:#ffd24d!important;border:1px solid #f2b600!important;color:#0f172a!important;-webkit-text-fill-color:#0f172a!important}
.rp-agenda-popup-card .rp-gc-action-emergency:hover,
.rp-agenda-popup-card .rp-gc-action-emergency:focus{background:#ffc928!important}
.rp-agenda-popup-card .rp-gc-mode-card .rp-gc-warning-head small{font-size:13px!important;color:#475569!important}
.rp-agenda-popup-card .rp-gc-mode-reprogram{border-left-color:#0f2f57!important;background:#f8fbff!important}
.rp-agenda-popup-card .rp-gc-mode-reprogram .rp-gc-warning-icon{background:#eaf2ff!important;color:#0f2f57!important}
.rp-agenda-popup-card .rp-gc-mode-emergency{background:#fffaf0!important}
@media(max-width:640px){
  .rp-agenda-popup-card .rp-gc-frequency-warning.rp-gc-frequency-card{padding:13px 12px 13px 15px!important;border-radius:16px!important}
  .rp-agenda-popup-card .rp-gc-warning-pill,
  .rp-agenda-popup-card .rp-gc-frequency-options{margin-left:0!important}
  .rp-agenda-popup-card .rp-gc-frequency-options{display:grid!important;grid-template-columns:1fr!important}
  .rp-agenda-popup-card .rp-gc-action-btn{width:100%!important;min-height:42px!important}
}


/* v469 - popup alta rápida: card completa, sin monto visible, botones RedPsico */
.rp-agenda-popup-card .rp-agenda-appointment-popup-form > .rp-gc-frequency-warning{
  grid-column:1 / -1!important;
  width:100%!important;
  max-width:none!important;
}
.rp-agenda-popup-card input[data-rp-gc-emergency][hidden]{display:none!important}
.rp-agenda-popup-card .rp-gc-frequency-warning.rp-gc-frequency-card{
  width:100%!important;
  margin:12px 0 2px!important;
  padding:16px 16px 16px 20px!important;
}
.rp-agenda-popup-card .rp-gc-warning-head{
  display:grid!important;
  grid-template-columns:36px 1fr!important;
  align-items:start!important;
}
.rp-agenda-popup-card .rp-gc-warning-pill{
  margin:12px 0 0 47px!important;
}
.rp-agenda-popup-card .rp-gc-frequency-options{
  margin:14px 0 0 47px!important;
  display:grid!important;
  grid-template-columns:repeat(2,minmax(0,1fr))!important;
  gap:10px!important;
}
.rp-agenda-popup-card .rp-gc-action-btn{
  width:100%!important;
  min-height:44px!important;
  padding:10px 13px!important;
  white-space:normal!important;
  line-height:1.15!important;
}
.rp-agenda-popup-card .rp-gc-action-btn span{
  display:inline!important;
  color:inherit!important;
  -webkit-text-fill-color:inherit!important;
}
.rp-agenda-popup-card .rp-gc-appointment-actions{
  grid-column:1 / -1!important;
  display:flex!important;
  justify-content:flex-end!important;
  align-items:center!important;
  gap:10px!important;
  margin-top:8px!important;
}
.rp-agenda-popup-card .rp-gc-appointment-actions .rp-btn{
  min-height:44px!important;
  border-radius:14px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:8px!important;
  font-weight:600!important;
  box-shadow:none!important;
}
.rp-agenda-popup-card .rp-gc-appointment-actions .rp-btn-svg,
.rp-agenda-popup-card .rp-gc-appointment-actions .rp-btn-svg svg{
  width:17px!important;
  height:17px!important;
  min-width:17px!important;
  display:inline-flex!important;
}
.rp-agenda-popup-card .rp-gc-save-no-notify,
.rp-agenda-popup-card .rp-gc-save-no-notify:hover,
.rp-agenda-popup-card .rp-gc-save-no-notify:focus,
.rp-agenda-popup-card .rp-gc-save-no-notify:active{
  background:#ffffff!important;
  border:1px solid #0f2f57!important;
  color:#0f2f57!important;
  -webkit-text-fill-color:#0f2f57!important;
}
.rp-agenda-popup-card .rp-gc-save-no-notify:hover,
.rp-agenda-popup-card .rp-gc-save-no-notify:focus{background:#f1f7ff!important}
.rp-agenda-popup-card .rp-gc-save-notify,
.rp-agenda-popup-card .rp-gc-save-notify:hover,
.rp-agenda-popup-card .rp-gc-save-notify:focus,
.rp-agenda-popup-card .rp-gc-save-notify:active{
  background:#0f2f57!important;
  border:1px solid #0f2f57!important;
  color:#ffffff!important;
  -webkit-text-fill-color:#ffffff!important;
}
.rp-agenda-popup-card .rp-gc-save-notify:hover,
.rp-agenda-popup-card .rp-gc-save-notify:focus{background:#123b6d!important}
.rp-agenda-popup-card .rp-gc-appointment-actions svg{
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.45!important;
}
@media(max-width:640px){
  .rp-agenda-popup-card .rp-gc-warning-pill{margin-left:0!important}
  .rp-agenda-popup-card .rp-gc-frequency-options{margin-left:0!important;grid-template-columns:1fr!important}
  .rp-agenda-popup-card .rp-gc-appointment-actions{display:grid!important;grid-template-columns:1fr!important}
  .rp-agenda-popup-card .rp-gc-appointment-actions .rp-btn{width:100%!important}
}

/* v470 - modal calendario: fondo bloqueado, solo scrollea el contenido del popup */
html.rp-agenda-popup-open,
html.rp-agenda-popup-open body{
  overflow:hidden !important;
  overscroll-behavior:none !important;
  touch-action:none;
}
html.rp-agenda-popup-open .rp-agenda-popup-layer{
  overscroll-behavior:contain;
  touch-action:none;
}
html.rp-agenda-popup-open .rp-agenda-popup-card,
html.rp-agenda-popup-open [data-rp-agenda-popup-body]{
  overscroll-behavior:contain;
  -webkit-overflow-scrolling:touch;
  touch-action:auto;
}


/* v471 - iPhone/Safari: evitar zoom automático al tocar campos del popup */
@media(max-width:760px){
  .rp-agenda-popup-layer,
  .rp-agenda-popup-card,
  .rp-agenda-popup-card *{
    -webkit-text-size-adjust:100%!important;
    text-size-adjust:100%!important;
  }
  .rp-agenda-popup-card{
    max-width:calc(100vw - 18px)!important;
    width:calc(100vw - 18px)!important;
    overflow-x:hidden!important;
    touch-action:manipulation!important;
  }
  .rp-agenda-popup-card input,
  .rp-agenda-popup-card select,
  .rp-agenda-popup-card textarea,
  .rp-agenda-popup-card button{
    font-size:16px!important;
    line-height:1.25!important;
  }
  .rp-agenda-popup-card input[type="time"],
  .rp-agenda-popup-card input[type="date"],
  .rp-agenda-popup-card input[type="number"],
  .rp-agenda-popup-card input[type="text"],
  .rp-agenda-popup-card input[type="search"],
  .rp-agenda-popup-card select{
    min-height:48px!important;
  }
  .rp-agenda-popup-card .rp-gc-warning-head{
    grid-template-columns:34px minmax(0,1fr)!important;
  }
  .rp-agenda-popup-card .rp-gc-warning-head > div,
  .rp-agenda-popup-card .rp-gc-warning-head strong,
  .rp-agenda-popup-card .rp-gc-warning-head small{
    min-width:0!important;
    max-width:100%!important;
    white-space:normal!important;
    overflow-wrap:anywhere!important;
  }
}


/* v472 - alta rápida móvil: formulario alineado, sin desbordes ni campos desparejos */
@media (max-width:760px){
  .rp-agenda-popup-layer{
    align-items:stretch!important;
    justify-content:center!important;
    padding:0!important;
    overflow:hidden!important;
  }
  .rp-agenda-popup-card{
    width:100vw!important;
    max-width:100vw!important;
    height:100dvh!important;
    max-height:100dvh!important;
    margin:0!important;
    border-radius:0!important;
    overflow:hidden!important;
    display:flex!important;
    flex-direction:column!important;
    background:#ffffff!important;
  }
  .rp-agenda-popup-card .rp-agenda-popup-body,
  .rp-agenda-popup-card [data-rp-agenda-popup-body]{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    flex:1 1 auto!important;
    overflow-y:auto!important;
    overflow-x:hidden!important;
    padding:20px 16px calc(92px + env(safe-area-inset-bottom,0px))!important;
    box-sizing:border-box!important;
  }
  .rp-agenda-popup-card .rp-agenda-popup-x{
    top:18px!important;
    right:16px!important;
    width:44px!important;
    height:44px!important;
    border-radius:18px!important;
    z-index:8!important;
  }
  .rp-agenda-popup-card .rp-agenda-popup-head{
    display:grid!important;
    grid-template-columns:54px minmax(0,1fr)!important;
    gap:14px!important;
    align-items:center!important;
    padding-right:54px!important;
    margin:0 0 18px!important;
  }
  .rp-agenda-popup-card .rp-agenda-popup-mainicon{
    width:54px!important;
    height:54px!important;
    min-width:54px!important;
    border-radius:16px!important;
  }
  .rp-agenda-popup-card .rp-agenda-popup-head h3{
    font-size:19px!important;
    line-height:1.15!important;
    margin:0 0 5px!important;
    max-width:100%!important;
    white-space:normal!important;
  }
  .rp-agenda-popup-card .rp-agenda-popup-head p{
    font-size:15.5px!important;
    line-height:1.35!important;
    margin:0!important;
    color:#64748b!important;
  }
  .rp-agenda-popup-card .rp-form-grid.rp-agenda-appointment-popup-form{
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:14px!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
  }
  .rp-agenda-popup-card .rp-form-grid.rp-agenda-appointment-popup-form > *,
  .rp-agenda-popup-card .rp-form-grid.rp-agenda-appointment-popup-form > label,
  .rp-agenda-popup-card .rp-form-grid.rp-agenda-appointment-popup-form > .full{
    grid-column:1 / -1!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
  }
  .rp-agenda-popup-card .rp-agenda-appointment-popup-form label{
    display:block!important;
    margin:0!important;
    font-size:15.5px!important;
    line-height:1.25!important;
    font-weight:600!important;
    color:#0f172a!important;
  }
  .rp-agenda-popup-card .rp-agenda-appointment-popup-form input,
  .rp-agenda-popup-card .rp-agenda-appointment-popup-form select,
  .rp-agenda-popup-card .rp-agenda-appointment-popup-form textarea{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    height:54px!important;
    min-height:54px!important;
    margin-top:8px!important;
    padding:0 16px!important;
    box-sizing:border-box!important;
    border:1px solid #dbe4ee!important;
    border-radius:15px!important;
    background:#ffffff!important;
    color:#0f172a!important;
    -webkit-text-fill-color:#0f172a!important;
    font-size:16px!important;
    font-weight:600!important;
    line-height:1.2!important;
    text-align:left!important;
    box-shadow:none!important;
    appearance:auto!important;
  }
  .rp-agenda-popup-card .rp-agenda-appointment-popup-form input[type="time"]{
    text-align:left!important;
    justify-content:flex-start!important;
  }
  .rp-agenda-popup-card .rp-agenda-appointment-popup-form input[readonly],
  .rp-agenda-popup-card .rp-agenda-appointment-popup-form input:disabled{
    background:#f8fafc!important;
    opacity:1!important;
  }
  .rp-agenda-popup-card .rp-gc-patient-picked{
    display:block!important;
    padding:14px 16px!important;
    border-radius:16px!important;
    background:#f8fbff!important;
    border:1px solid #dbeafe!important;
    font-size:15px!important;
    line-height:1.55!important;
  }
  .rp-agenda-popup-card .rp-gc-patient-picked span{
    display:inline!important;
    margin-right:6px!important;
  }
  .rp-agenda-popup-card .rp-gc-frequency-warning.rp-gc-frequency-card{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    margin:4px 0 0!important;
    padding:14px 14px 14px 16px!important;
    border-radius:18px!important;
    border-left-width:5px!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
  }
  .rp-agenda-popup-card .rp-gc-warning-head{
    display:grid!important;
    grid-template-columns:42px minmax(0,1fr)!important;
    gap:12px!important;
    align-items:start!important;
    width:100%!important;
  }
  .rp-agenda-popup-card .rp-gc-warning-icon{
    width:42px!important;
    height:42px!important;
    min-width:42px!important;
    border-radius:15px!important;
  }
  .rp-agenda-popup-card .rp-gc-warning-icon svg{
    width:21px!important;
    height:21px!important;
  }
  .rp-agenda-popup-card .rp-gc-warning-head > div{
    min-width:0!important;
    max-width:100%!important;
    overflow:hidden!important;
  }
  .rp-agenda-popup-card .rp-gc-warning-head strong{
    display:block!important;
    max-width:100%!important;
    white-space:normal!important;
    overflow-wrap:normal!important;
    word-break:normal!important;
    font-size:18px!important;
    line-height:1.18!important;
    font-weight:700!important;
    color:#0f172a!important;
  }
  .rp-agenda-popup-card .rp-gc-warning-head small{
    display:block!important;
    max-width:100%!important;
    white-space:normal!important;
    overflow-wrap:normal!important;
    word-break:normal!important;
    font-size:15px!important;
    line-height:1.35!important;
    color:#64748b!important;
    margin-top:5px!important;
  }
  .rp-agenda-popup-card .rp-gc-warning-pill{
    margin:14px 0 0 54px!important;
    padding:8px 14px!important;
    font-size:14px!important;
  }
  .rp-agenda-popup-card .rp-gc-frequency-options{
    margin:14px 0 0!important;
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:10px!important;
    width:100%!important;
  }
  .rp-agenda-popup-card .rp-gc-action-btn{
    width:100%!important;
    min-height:50px!important;
    border-radius:16px!important;
    padding:13px 14px!important;
    font-size:16px!important;
    line-height:1.15!important;
    white-space:normal!important;
  }
  .rp-agenda-popup-card .rp-gc-action-btn span{
    display:inline!important;
    white-space:normal!important;
  }
  .rp-agenda-popup-card .rp-gc-action-btn svg{
    width:20px!important;
    height:20px!important;
  }
  .rp-agenda-popup-card .rp-gc-appointment-actions{
    position:sticky!important;
    bottom:0!important;
    z-index:7!important;
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:10px!important;
    width:100%!important;
    margin:2px 0 0!important;
    padding:12px 0 0!important;
    background:linear-gradient(to bottom,rgba(255,255,255,0),#fff 22%,#fff 100%)!important;
  }
  .rp-agenda-popup-card .rp-gc-appointment-actions .rp-btn{
    width:100%!important;
    min-height:50px!important;
    border-radius:16px!important;
    font-size:16px!important;
    line-height:1.15!important;
    margin:0!important;
  }
}

/* v473 - popup móvil alta rápida: acciones al final real y campos sin desborde */
@media (max-width:760px){
  .rp-agenda-popup-card .rp-agenda-popup-body,
  .rp-agenda-popup-card [data-rp-agenda-popup-body]{
    padding:20px 16px calc(24px + env(safe-area-inset-bottom,0px))!important;
    overflow-x:hidden!important;
  }
  .rp-agenda-popup-card .rp-form-grid.rp-agenda-appointment-popup-form{
    display:flex!important;
    flex-direction:column!important;
    gap:14px!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
  }
  .rp-agenda-popup-card .rp-form-grid.rp-agenda-appointment-popup-form > *,
  .rp-agenda-popup-card .rp-form-grid.rp-agenda-appointment-popup-form > label,
  .rp-agenda-popup-card .rp-form-grid.rp-agenda-appointment-popup-form > .full{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
  }
  .rp-agenda-popup-card .rp-agenda-appointment-popup-form input,
  .rp-agenda-popup-card .rp-agenda-appointment-popup-form select,
  .rp-agenda-popup-card .rp-agenda-appointment-popup-form textarea{
    display:block!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
    margin-left:0!important;
    margin-right:0!important;
  }
  .rp-agenda-popup-card .rp-agenda-appointment-popup-form input[type="time"]{
    display:block!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    box-sizing:border-box!important;
    padding-left:16px!important;
    padding-right:16px!important;
    appearance:none!important;
    -webkit-appearance:none!important;
    text-align:left!important;
  }
  .rp-agenda-popup-card .rp-gc-frequency-warning.rp-gc-frequency-card{
    order:90!important;
  }
  .rp-agenda-popup-card .rp-gc-appointment-actions{
    order:100!important;
    position:static!important;
    bottom:auto!important;
    z-index:auto!important;
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:10px!important;
    width:100%!important;
    margin:4px 0 0!important;
    padding:0!important;
    background:transparent!important;
    box-shadow:none!important;
  }
  .rp-agenda-popup-card .rp-gc-appointment-actions .rp-btn{
    width:100%!important;
    max-width:100%!important;
    min-height:52px!important;
    border-radius:16px!important;
  }
}


/* v474 - popup móvil: horario centrado, ficha paciente limpia y duración integrada */
.rp-agenda-popup-card .rp-gc-duration-field{
  display:none!important;
}
.rp-agenda-popup-card .rp-gc-patient-picked{
  background:#ffffff!important;
  border:0!important;
  box-shadow:none!important;
  padding:2px 0 0!important;
  border-radius:0!important;
  color:#0f172a!important;
}
.rp-agenda-popup-card .rp-gc-patient-picked span{
  color:#334155!important;
}
.rp-agenda-popup-card .rp-gc-patient-picked b{
  color:#0f172a!important;
  font-weight:700!important;
}
@media (max-width:760px){
  .rp-agenda-popup-card .rp-gc-patient-picked{
    display:block!important;
    background:#ffffff!important;
    border:0!important;
    padding:0!important;
    margin:-2px 0 2px!important;
    line-height:1.45!important;
    font-size:15.5px!important;
  }
  .rp-agenda-popup-card .rp-gc-patient-picked span{
    display:inline!important;
    margin:0 7px 0 0!important;
    white-space:normal!important;
  }
  .rp-agenda-popup-card .rp-gc-patient-picked span:first-child{
    display:block!important;
    margin:0 0 2px!important;
    font-size:16px!important;
  }
  .rp-agenda-popup-card .rp-agenda-appointment-popup-form input[type="time"][data-rp-gc-appointment-time]{
    height:56px!important;
    min-height:56px!important;
    line-height:56px!important;
    padding-top:10px!important;
    padding-bottom:0!important;
    font-size:16px!important;
    text-align:left!important;
    vertical-align:middle!important;
  }
  .rp-agenda-popup-card .rp-agenda-appointment-popup-form input[type="time"][data-rp-gc-appointment-time]::-webkit-date-and-time-value{
    min-height:56px!important;
    height:56px!important;
    line-height:56px!important;
    text-align:left!important;
  }
}

/* v475 - ajuste fino popup móvil: ocultar duración real y centrar horario en iOS */
.rp-agenda-popup-card .rp-agenda-appointment-popup-form .rp-gc-duration-field,
.rp-agenda-popup-card .rp-agenda-appointment-popup-form label.rp-gc-duration-field{
  display:none!important;
  visibility:hidden!important;
  height:0!important;
  min-height:0!important;
  max-height:0!important;
  margin:0!important;
  padding:0!important;
  overflow:hidden!important;
  pointer-events:none!important;
}
.rp-agenda-popup-card .rp-agenda-appointment-popup-form input[type="hidden"][data-rp-gc-duration]{
  display:none!important;
}
@media (max-width:760px){
  .rp-agenda-popup-card .rp-agenda-appointment-popup-form input[type="time"][data-rp-gc-appointment-time]{
    height:56px!important;
    min-height:56px!important;
    max-height:56px!important;
    line-height:normal!important;
    padding:0 16px!important;
    margin:0!important;
    display:block!important;
    box-sizing:border-box!important;
    font-size:16px!important;
    font-weight:700!important;
    text-align:left!important;
    appearance:none!important;
    -webkit-appearance:none!important;
  }
  .rp-agenda-popup-card .rp-agenda-appointment-popup-form input[type="time"][data-rp-gc-appointment-time]::-webkit-date-and-time-value{
    min-height:56px!important;
    height:56px!important;
    line-height:56px!important;
    padding:0!important;
    margin:0!important;
    text-align:left!important;
  }
  .rp-agenda-popup-card .rp-agenda-appointment-popup-form input[type="time"][data-rp-gc-appointment-time]::-webkit-datetime-edit,
  .rp-agenda-popup-card .rp-agenda-appointment-popup-form input[type="time"][data-rp-gc-appointment-time]::-webkit-datetime-edit-fields-wrapper{
    height:56px!important;
    min-height:56px!important;
    line-height:56px!important;
    padding:0!important;
    margin:0!important;
    display:flex!important;
    align-items:center!important;
  }
}


/* v477 limpio - descanso gris en agenda interactiva */
.rp-timeline-item.is-rest{
  background:#f3f4f6!important;
  border-color:#d1d5db!important;
  border-left-color:#9ca3af!important;
}
.rp-timeline-item.is-rest strong{
  color:#374151!important;
}
.rp-timeline-item.is-rest span{
  color:#6b7280!important;
}
.rp-timeline-rest{
  cursor:default!important;
}


/* v481 - alinear todos los campos de hora en popups móviles y desktop */
.rp-agenda-popup-card .rp-agenda-block-popup-form,
.rp-agenda-popup-card .rp-general-block-form-popup .rp-form-grid,
.rp-agenda-popup-card .rp-agenda-appointment-popup-form{
  width:100%!important;
  max-width:100%!important;
  box-sizing:border-box!important;
}
.rp-agenda-popup-card .rp-agenda-block-popup-form label,
.rp-agenda-popup-card .rp-agenda-appointment-popup-form label{
  box-sizing:border-box!important;
  min-width:0!important;
}
.rp-agenda-popup-card .rp-agenda-block-popup-form input,
.rp-agenda-popup-card .rp-agenda-block-popup-form select,
.rp-agenda-popup-card .rp-agenda-block-popup-form textarea,
.rp-agenda-popup-card .rp-agenda-appointment-popup-form input,
.rp-agenda-popup-card .rp-agenda-appointment-popup-form select,
.rp-agenda-popup-card .rp-agenda-appointment-popup-form textarea{
  width:100%!important;
  max-width:100%!important;
  box-sizing:border-box!important;
}
.rp-agenda-popup-card input[type="time"]{
  height:54px!important;
  min-height:54px!important;
  max-height:54px!important;
  padding:0 16px!important;
  line-height:54px!important;
  display:block!important;
  box-sizing:border-box!important;
  font-size:16px!important;
  font-weight:700!important;
  text-align:left!important;
  vertical-align:middle!important;
  -webkit-appearance:none!important;
  appearance:none!important;
}
.rp-agenda-popup-card input[type="time"]::-webkit-date-and-time-value{
  height:54px!important;
  min-height:54px!important;
  line-height:54px!important;
  padding:0!important;
  margin:0!important;
  text-align:left!important;
}
.rp-agenda-popup-card input[type="time"]::-webkit-datetime-edit,
.rp-agenda-popup-card input[type="time"]::-webkit-datetime-edit-fields-wrapper{
  height:54px!important;
  min-height:54px!important;
  line-height:54px!important;
  padding:0!important;
  margin:0!important;
  display:flex!important;
  align-items:center!important;
}
@media (max-width:760px){
  .rp-agenda-popup-card .rp-agenda-block-popup-form{
    display:flex!important;
    flex-direction:column!important;
    gap:14px!important;
    width:100%!important;
    max-width:100%!important;
  }
  .rp-agenda-popup-card .rp-agenda-block-popup-form > *,
  .rp-agenda-popup-card .rp-agenda-block-popup-form > label,
  .rp-agenda-popup-card .rp-agenda-block-popup-form > .full{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    grid-column:1 / -1!important;
    box-sizing:border-box!important;
  }
  .rp-agenda-popup-card .rp-agenda-block-popup-form label{
    display:block!important;
    margin:0!important;
    font-size:15.5px!important;
    line-height:1.25!important;
    font-weight:600!important;
    color:#0f172a!important;
  }
  .rp-agenda-popup-card .rp-agenda-block-popup-form input,
  .rp-agenda-popup-card .rp-agenda-block-popup-form select,
  .rp-agenda-popup-card .rp-agenda-block-popup-form textarea{
    height:54px!important;
    min-height:54px!important;
    margin-top:8px!important;
    padding:0 16px!important;
    border:1px solid #dbe4ee!important;
    border-radius:15px!important;
    background:#ffffff!important;
    color:#0f172a!important;
    -webkit-text-fill-color:#0f172a!important;
    font-size:16px!important;
    font-weight:600!important;
    line-height:54px!important;
    box-shadow:none!important;
  }
  .rp-agenda-popup-card .rp-agenda-block-popup-form input[type="time"]{
    line-height:54px!important;
    text-align:left!important;
  }
  .rp-agenda-popup-card .rp-agenda-block-actions,
  .rp-agenda-popup-card .rp-agenda-block-actions .rp-btn,
  .rp-agenda-popup-card .rp-general-block-submit{
    width:100%!important;
    max-width:100%!important;
    min-height:52px!important;
    border-radius:16px!important;
  }
}

/* v482 - Actividad adicional: normalización visual real de campos en móvil */
@media (max-width:760px){
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form{
    display:flex!important;
    flex-direction:column!important;
    gap:18px!important;
    width:100%!important;
    max-width:100%!important;
    overflow:hidden!important;
  }
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form > label,
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form > .full,
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form .rp-agenda-block-actions{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    margin:0!important;
    padding:0!important;
    grid-column:1 / -1!important;
    box-sizing:border-box!important;
  }
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form label{
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
    gap:8px!important;
    font-size:15.5px!important;
    line-height:1.25!important;
    font-weight:650!important;
    color:#0f172a!important;
  }
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form input,
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form select,
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form textarea{
    display:block!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    height:60px!important;
    min-height:60px!important;
    max-height:60px!important;
    margin:0!important;
    padding:0 18px!important;
    box-sizing:border-box!important;
    border:1px solid #dbe4ee!important;
    border-top:1px solid #dbe4ee!important;
    border-right:1px solid #dbe4ee!important;
    border-bottom:1px solid #dbe4ee!important;
    border-left:1px solid #dbe4ee!important;
    border-radius:16px!important;
    outline:none!important;
    box-shadow:none!important;
    background:#fff!important;
    color:#0f172a!important;
    -webkit-text-fill-color:#0f172a!important;
    font-size:16px!important;
    font-weight:650!important;
    line-height:60px!important;
    vertical-align:middle!important;
  }
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form select{
    appearance:auto!important;
    -webkit-appearance:menulist!important;
    padding-right:44px!important;
  }
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form input[type="time"],
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form input[type="date"]{
    -webkit-appearance:none!important;
    appearance:none!important;
    text-align:left!important;
    line-height:normal!important;
    padding-top:0!important;
    padding-bottom:0!important;
    background-image:none!important;
  }
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form input[type="time"]::-webkit-date-and-time-value,
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form input[type="date"]::-webkit-date-and-time-value{
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    width:100%!important;
    height:60px!important;
    min-height:60px!important;
    margin:0!important;
    padding:0!important;
    line-height:60px!important;
    text-align:left!important;
  }
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form input[type="time"]::-webkit-datetime-edit,
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form input[type="time"]::-webkit-datetime-edit-fields-wrapper,
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form input[type="date"]::-webkit-datetime-edit,
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form input[type="date"]::-webkit-datetime-edit-fields-wrapper{
    display:flex!important;
    align-items:center!important;
    height:60px!important;
    min-height:60px!important;
    padding:0!important;
    margin:0!important;
    line-height:60px!important;
  }
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form input[type="time"]::-webkit-calendar-picker-indicator,
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form input[type="date"]::-webkit-calendar-picker-indicator{
    margin:0!important;
    padding:0!important;
    opacity:.75!important;
  }
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form input::placeholder{
    color:#9aa3af!important;
    -webkit-text-fill-color:#9aa3af!important;
    opacity:1!important;
  }
  html body .rp-agenda-popup-card .rp-agenda-block-actions,
  html body .rp-agenda-popup-card .rp-agenda-block-actions .rp-btn,
  html body .rp-agenda-popup-card .rp-general-block-submit{
    width:100%!important;
    max-width:100%!important;
  }
}

/* v483: popup global de carga del panel profesional */
.rp-submit-overlay{position:fixed;inset:0;z-index:2147483001;display:flex;align-items:center;justify-content:center;background:rgba(248,250,252,.84);backdrop-filter:blur(8px);opacity:0;pointer-events:auto;transition:opacity .18s ease}.rp-submit-overlay.show{opacity:1}.rp-submit-card{width:min(370px,calc(100vw - 34px));background:#fff;border:1px solid rgba(16,42,86,.14);border-radius:22px;padding:26px 22px;text-align:center;box-shadow:0 24px 70px rgba(16,42,86,.16);color:#102A56}.rp-submit-icon{width:58px;height:58px;margin:0 auto 13px;border-radius:20px;background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%);color:#fff;display:flex;align-items:center;justify-content:center}.rp-submit-icon svg{width:31px;height:31px}.rp-submit-card h3{margin:0 0 7px;font-size:18px;font-weight:700;color:#0f172a;line-height:1.15}.rp-submit-card p{margin:0 auto 17px;max-width:290px;font-size:13px;font-weight:400;line-height:1.45;color:#64748b}.rp-submit-spinner{display:block;width:30px;height:30px;margin:0 auto;border-radius:999px;border:2px solid rgba(16,42,86,.16);border-top-color:#102A56;animation:rpSubmitSpin .78s linear infinite}@keyframes rpSubmitSpin{to{transform:rotate(360deg)}}.rp-is-submitting button[type="submit"],.rp-is-submitting input[type="submit"]{cursor:wait!important;opacity:.78!important}html.rp-submit-loading,body.rp-submit-loading{overflow:hidden!important;touch-action:none!important}
@media(max-width:760px){.rp-submit-card{width:calc(100vw - 44px);border-radius:24px;padding:28px 20px}.rp-submit-card h3{font-size:20px}.rp-submit-card p{font-size:14px}}

/* v484 PWA Descargar app - Panel Profesional */
.rp-pwa-section .rp-pwa-head{display:flex;gap:18px;align-items:center}
.rp-pwa-logo{width:78px;height:78px;border-radius:20px;background:#fff;display:flex;align-items:center;justify-content:center;border:1px solid #e5edf7;box-shadow:0 10px 26px rgba(16,42,86,.08);flex:0 0 78px;overflow:hidden}
.rp-pwa-logo img{width:64px;height:64px;object-fit:contain;display:block}
.rp-pwa-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;margin-top:18px}
.rp-pwa-card{border:1px solid #dce8f5!important;border-radius:20px!important;background:#fff!important;padding:22px!important;box-sizing:border-box!important}
.rp-pwa-card h2{margin:0 0 10px!important;color:#102A56!important;font-size:22px!important;line-height:1.15!important;font-weight:700!important}
.rp-pwa-card p{color:#667085!important;font-size:15px!important;line-height:1.45!important;margin:0 0 14px!important}
.rp-pwa-device-badge{display:inline-flex;align-items:center;justify-content:center;padding:8px 12px;border-radius:999px;background:#eef6ff;color:#102A56;font-weight:700;font-size:13px;margin-bottom:14px;border:1px solid #d8eaff}
.rp-pwa-device-badge.is-installed{background:#eafaf0;color:#167a35;border-color:#bcecca}
.rp-pwa-install-btn{display:inline-flex!important;align-items:center!important;gap:9px!important;margin:8px 0 12px!important;background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;border-color:#102A56!important;color:#fff!important;border-radius:15px!important;padding:13px 18px!important;font-weight:700!important}
.rp-pwa-install-btn[hidden]{display:none!important}
.rp-pwa-steps{margin:10px 0 0!important;padding:0 0 0 20px!important;color:#1f2937!important}
.rp-pwa-steps li{margin:9px 0!important;line-height:1.45!important;color:#344054!important;font-size:15px!important}
.rp-pwa-card.is-current-device{border-color:#0B8FB4!important;box-shadow:0 0 0 3px rgba(11,143,180,.10)!important}
@media(max-width:760px){
  .rp-pwa-section .rp-pwa-head{align-items:flex-start;gap:14px}
  .rp-pwa-logo{width:62px;height:62px;border-radius:16px;flex-basis:62px}
  .rp-pwa-logo img{width:52px;height:52px}
  .rp-pwa-grid{grid-template-columns:1fr;gap:12px;margin-top:14px}
  .rp-pwa-card{padding:18px!important;border-radius:18px!important}
  .rp-pwa-card h2{font-size:20px!important}
  .rp-pwa-steps li{font-size:14px!important}
}

/* v486 - bloquear guardado si hay sesión existente hasta elegir reprogramación o emergencia */
.rp-frequency-action-required{
  border:1px solid rgba(185,28,28,.18);
  background:#fff7f5;
  color:#991b1b;
  border-radius:16px;
  padding:14px 16px;
  display:flex;
  flex-direction:column;
  gap:4px;
  font-size:14px;
  line-height:1.35;
}
.rp-frequency-action-required strong{font-weight:700;color:#7f1d1d;}
.rp-frequency-action-required span{color:#9f2a21;}
.rp-appointment-actions[hidden]{display:none!important;}


/* v487 - ocultar acciones de guardado hasta elegir reprogramar o emergencia */
.rp-appointment-actions.rp-actions-locked-by-conflict,
.rp-appointment-actions.rp-actions-locked-by-conflict[hidden]{display:none!important;visibility:hidden!important;height:0!important;margin:0!important;padding:0!important;overflow:hidden!important;}
.rp-frequency-action-required[hidden]{display:none!important;}

/* v488 - no mostrar guardado en popup agenda hasta elegir acción */
.rp-gc-appointment-actions[hidden],
.rp-gc-appointment-actions.rp-actions-locked-by-conflict,
.rp-gc-appointment-actions.rp-actions-locked-by-conflict[hidden]{display:none!important;visibility:hidden!important;height:0!important;margin:0!important;padding:0!important;overflow:hidden!important;}

/* v489 - Agenda interactiva: leyenda de colores debajo del calendario */
.rp-prof-panel #calendario-general .rp-agenda-color-legend{
  margin:14px 0 0!important;
  padding:14px 14px 13px!important;
  border:1px solid #e5edf6!important;
  border-radius:16px!important;
  background:#fff!important;
  box-sizing:border-box!important;
  width:100%!important;
}
.rp-prof-panel #calendario-general .rp-agenda-color-legend>strong{
  display:block!important;
  margin:0 0 10px!important;
  color:#0f172a!important;
  font-size:14px!important;
  line-height:1.2!important;
  font-weight:700!important;
}
.rp-prof-panel #calendario-general .rp-agenda-color-legend-items{
  display:flex!important;
  flex-wrap:wrap!important;
  align-items:center!important;
  gap:9px!important;
}
.rp-prof-panel #calendario-general .rp-agenda-color-ref{
  display:inline-flex!important;
  align-items:center!important;
  gap:7px!important;
  min-height:30px!important;
  padding:6px 10px!important;
  border:1px solid #e5edf6!important;
  border-radius:999px!important;
  background:#f8fafc!important;
  color:#263448!important;
  font-size:13px!important;
  line-height:1!important;
  font-weight:600!important;
  white-space:nowrap!important;
  box-sizing:border-box!important;
}
.rp-prof-panel #calendario-general .rp-agenda-color-ref i{
  display:inline-block!important;
  width:12px!important;
  height:12px!important;
  min-width:12px!important;
  border-radius:4px!important;
  box-shadow:inset 0 0 0 1px rgba(15,23,42,.10)!important;
}
.rp-prof-panel #calendario-general .rp-agenda-color-ref.is-weekly i{background:#43d17c!important;}
.rp-prof-panel #calendario-general .rp-agenda-color-ref.is-biweekly i{background:#ff9f2e!important;}
.rp-prof-panel #calendario-general .rp-agenda-color-ref.is-monthly i{background:#ffe45c!important;}
.rp-prof-panel #calendario-general .rp-agenda-color-ref.is-rotating i{background:#f35adf!important;}
.rp-prof-panel #calendario-general .rp-agenda-color-ref.is-emergency i{background:#ff3b3b!important;}
.rp-prof-panel #calendario-general .rp-agenda-color-ref.is-extra i{background:#ff9ad5!important;}
.rp-prof-panel #calendario-general .rp-agenda-color-ref.is-rest i{background:#e5e7eb!important;}
@media(max-width:760px){
  .rp-prof-panel #calendario-general .rp-agenda-color-legend{padding:12px!important;border-radius:14px!important;margin-top:12px!important;}
  .rp-prof-panel #calendario-general .rp-agenda-color-legend-items{gap:7px!important;}
  .rp-prof-panel #calendario-general .rp-agenda-color-ref{font-size:12px!important;padding:6px 9px!important;min-height:28px!important;}
}


/* v491 - Agenda interactiva: estado del día discreto */
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-month-day-head{
  display:flex!important;
  align-items:center!important;
  gap:5px!important;
  width:100%!important;
  max-width:100%!important;
  min-width:0!important;
  margin:0 0 7px 0!important;
}
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-month-day-head strong{
  display:inline-flex!important;
  margin:0!important;
  flex:0 0 auto!important;
  line-height:1!important;
}
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-month-day-status{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  max-width:calc(100% - 34px)!important;
  min-width:0!important;
  min-height:18px!important;
  height:18px!important;
  padding:0 7px!important;
  border-radius:999px!important;
  font-size:10.5px!important;
  font-weight:400!important;
  line-height:1!important;
  white-space:nowrap!important;
  overflow:hidden!important;
  text-overflow:ellipsis!important;
  margin:0!important;
  border:0!important;
  box-shadow:none!important;
  color:#222!important;
  -webkit-text-fill-color:#222!important;
}
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-month-day-status.is-available{
  background:rgba(67,209,124,.12)!important;
  color:#222!important;
  -webkit-text-fill-color:#222!important;
}
.rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-month-day-status.is-complete{
  background:rgba(239,68,68,.12)!important;
  color:#222!important;
  -webkit-text-fill-color:#222!important;
}
@media(max-width:760px){
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-month-day-head{
    gap:3px!important;
    margin-bottom:4px!important;
  }
  .rp-prof-panel #calendario-general .rp-general-calendar-grid .rp-day-cell .rp-month-day-status{
    display:inline-flex!important;
    min-height:14px!important;
    height:14px!important;
    padding:0 4px!important;
    font-size:7px!important;
    font-weight:400!important;
    max-width:calc(100% - 18px)!important;
    border:0!important;
    color:#222!important;
    -webkit-text-fill-color:#222!important;
  }
}


/* v494 - Historial de sesiones: turnos próximos primero y atendidos separados */
.rp-session-history-table tbody tr.rp-session-attended-first td{
  border-top:18px solid #f7f9fc !important;
}
.rp-session-history-table tbody tr.rp-session-attended-first td:first-child{
  position:relative;
}
.rp-session-history-table tbody tr.rp-session-attended-first td:first-child:before{
  content:'Sesiones atendidas';
  position:absolute;
  top:-16px;
  left:12px;
  font-size:12px;
  line-height:14px;
  font-weight:400;
  color:#6b7280;
  white-space:nowrap;
}
@media (max-width: 720px){
  .rp-session-history-table tbody tr.rp-session-attended-first td{
    border-top:22px solid #f7f9fc !important;
  }
  .rp-session-history-table tbody tr.rp-session-attended-first td:first-child:before{
    top:-19px;
    left:10px;
  }
}

/* v504 - RedPsico: modernización visual SaaS (solo CSS, sin cambios de lógica) */
.rp-prof-panel{
  --rp-blue:#102A56!important;
  --rp-blue-2:#163B72!important;
  --rp-red:#D9343A!important;
  --rp-red-2:#B91F2D!important;
  --rp-soft-blue:#EFF6FF!important;
  --rp-soft-red:#FFF1F2!important;
  --rp-line:#E6ECF5!important;
  --rp-text:#111827!important;
  --rp-muted:#5F6B7A!important;
  background:
    radial-gradient(circle at 8% 0%, rgba(16,42,86,.085), transparent 34%),
    radial-gradient(circle at 98% 100%, rgba(217,52,58,.075), transparent 38%),
    linear-gradient(135deg, #FFFFFF 0%, #F8FBFF 48%, #FFF8F8 100%)!important;
  color:var(--rp-text)!important;
}

.rp-prof-main{
  background:
    radial-gradient(circle at 0% 0%, rgba(16,42,86,.055), transparent 30%),
    radial-gradient(circle at 100% 100%, rgba(217,52,58,.045), transparent 34%),
    transparent!important;
}

.rp-prof-sidebar,
.rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar{
  background:
    linear-gradient(160deg, rgba(16,42,86,1) 0%, rgba(15,49,95,1) 58%, rgba(11,28,60,1) 100%)!important;
  color:#fff!important;
  border-right:1px solid rgba(255,255,255,.10)!important;
  box-shadow:8px 0 28px rgba(16,42,86,.12)!important;
  position:relative!important;
  overflow:hidden!important;
}

.rp-prof-sidebar::before{
  content:""!important;
  position:absolute!important;
  inset:0!important;
  pointer-events:none!important;
  background:
    radial-gradient(circle at 0% 8%, rgba(217,52,58,.28), transparent 22%),
    linear-gradient(135deg, transparent 0%, transparent 46%, rgba(255,255,255,.045) 46.5%, transparent 48%),
    linear-gradient(135deg, transparent 0%, transparent 70%, rgba(217,52,58,.12) 70.5%, transparent 72%)!important;
  opacity:.95!important;
}

.rp-prof-sidebar > *,
.rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar > *{
  position:relative!important;
  z-index:1!important;
}

.rp-prof-brand{
  border-bottom:1px solid rgba(255,255,255,.10)!important;
  padding-bottom:14px!important;
}

.rp-prof-brand .rp-brand-logo-wrap{
  background:rgba(255,255,255,.10)!important;
  border:1px solid rgba(255,255,255,.20)!important;
  box-shadow:none!important;
}

.rp-prof-brand strong{
  color:#fff!important;
  font-weight:600!important;
  letter-spacing:-.01em!important;
}

.rp-prof-sidebar a,
.rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar a{
  color:rgba(255,255,255,.82)!important;
  background:transparent!important;
  border:1px solid transparent!important;
  border-radius:12px!important;
  font-weight:450!important;
  transition:background .18s ease, color .18s ease, border-color .18s ease, transform .18s ease!important;
}

.rp-prof-sidebar a svg,
.rp-nav-icon svg,
.rp-prof-sidebar .rp-nav-icon svg{
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.8!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
}

.rp-prof-sidebar a.active,
.rp-prof-sidebar a:hover,
.rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar a.active,
.rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar a:hover{
  background:rgba(255,255,255,.12)!important;
  border-color:rgba(255,255,255,.16)!important;
  color:#fff!important;
  transform:translateX(2px)!important;
}

.rp-prof-sidebar a.active{
  box-shadow:inset 4px 0 0 var(--rp-red)!important;
}

.rp-prof-head{
  padding:8px 0 4px!important;
}
.rp-prof-head h1,
.rp-page-title{
  color:var(--rp-blue)!important;
  font-weight:650!important;
  letter-spacing:-.025em!important;
}
.rp-prof-head p{
  color:var(--rp-muted)!important;
  font-weight:400!important;
}

.rp-card,
.rp-list-card,
.rp-table-card,
.rp-patient-card,
.rp-calendar-shell,
.rp-detail-card,
.rp-kpis div,
.rp-next-card,
.rp-next-dashboard-card,
.rp-dashboard-notifications-card,
.rp-public-profile-card,
.rp-public-profile-settings,
.rp-public-status-card{
  background:rgba(255,255,255,.92)!important;
  border:1px solid var(--rp-line)!important;
  border-radius:18px!important;
  box-shadow:0 12px 34px rgba(16,42,86,.055)!important;
  backdrop-filter:saturate(120%) blur(4px)!important;
}

.rp-card:hover,
.rp-list-card:hover,
.rp-table-card:hover,
.rp-patient-card:hover,
.rp-calendar-shell:hover,
.rp-detail-card:hover{
  border-color:rgba(16,42,86,.18)!important;
}

.rp-btn,
button.rp-btn,
a.rp-btn,
.rp-btn-primary,
.rp-public-profile-actions .rp-btn:first-child{
  background:linear-gradient(135deg, var(--rp-red), var(--rp-red-2))!important;
  color:#fff!important;
  border:1px solid rgba(185,31,45,.25)!important;
  border-radius:12px!important;
  box-shadow:none!important;
  font-weight:550!important;
}

.rp-btn:hover,
button.rp-btn:hover,
a.rp-btn:hover,
.rp-btn-primary:hover{
  transform:translateY(-1px)!important;
  filter:saturate(1.05)!important;
}

.rp-btn-light,
.rp-btn-secondary,
.rp-public-profile-actions .rp-btn:not(:first-child){
  background:#fff!important;
  color:var(--rp-blue)!important;
  border:1px solid rgba(16,42,86,.22)!important;
  border-radius:12px!important;
  box-shadow:none!important;
}

.rp-form-grid input,
.rp-form-grid select,
.rp-form-grid textarea,
.rp-prof-panel input[type="text"],
.rp-prof-panel input[type="email"],
.rp-prof-panel input[type="number"],
.rp-prof-panel input[type="tel"],
.rp-prof-panel input[type="url"],
.rp-prof-panel select,
.rp-prof-panel textarea{
  background:#fff!important;
  border:1px solid #D9E1EC!important;
  border-radius:12px!important;
  color:var(--rp-text)!important;
  box-shadow:none!important;
  transition:border-color .16s ease, box-shadow .16s ease!important;
}

.rp-form-grid input:focus,
.rp-form-grid select:focus,
.rp-form-grid textarea:focus,
.rp-prof-panel input:focus,
.rp-prof-panel select:focus,
.rp-prof-panel textarea:focus{
  border-color:rgba(16,42,86,.42)!important;
  box-shadow:0 0 0 4px rgba(16,42,86,.08)!important;
  outline:none!important;
}

.rp-prof-panel label,
.rp-prof-panel .description,
.rp-prof-panel small,
.rp-prof-panel .hint{
  color:var(--rp-muted)!important;
}

.rp-prof-panel input[type="checkbox"]{
  accent-color:var(--rp-red)!important;
}

.rp-table-card th,
.rp-patient-table th{
  color:var(--rp-blue)!important;
  background:#F7FAFF!important;
}

.rp-table-card td,
.rp-patient-table td{
  border-color:#EDF2F7!important;
}

/* Perfil público: retoque visual sin alterar funcionamiento */
#perfil-publico .rp-card,
.rp-prof-section#perfil-publico .rp-card,
.rp-public-profile-card,
.rp-public-profile-settings{
  position:relative!important;
  overflow:hidden!important;
}
#perfil-publico .rp-card::before,
.rp-prof-section#perfil-publico .rp-card::before,
.rp-public-profile-card::before,
.rp-public-profile-settings::before{
  content:""!important;
  position:absolute!important;
  top:0!important;
  left:0!important;
  right:0!important;
  height:4px!important;
  background:linear-gradient(90deg, var(--rp-blue), var(--rp-red))!important;
}

@media(max-width:760px){
  .rp-prof-sidebar,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar{
    background:linear-gradient(160deg, #102A56 0%, #123566 75%, #0B1C3C 100%)!important;
  }
  .rp-prof-main{
    background:
      radial-gradient(circle at top left, rgba(16,42,86,.06), transparent 42%),
      radial-gradient(circle at bottom right, rgba(217,52,58,.045), transparent 46%),
      #fff!important;
  }
  .rp-card,
  .rp-list-card,
  .rp-table-card,
  .rp-patient-card,
  .rp-calendar-shell,
  .rp-detail-card{
    border-radius:16px!important;
    box-shadow:0 8px 24px rgba(16,42,86,.05)!important;
  }
}

/* v505 - RedPsico: mismo efecto azul/rojo del menú en bloques azul pleno (solo CSS) */
.rp-prof-panel{
  --rp-menu-gradient:
    radial-gradient(circle at 0% 8%, rgba(217,52,58,.24), transparent 24%),
    linear-gradient(135deg, transparent 0%, transparent 48%, rgba(255,255,255,.055) 48.5%, transparent 50%),
    linear-gradient(145deg, rgba(16,42,86,1) 0%, rgba(18,53,102,1) 58%, rgba(11,28,60,1) 100%)!important;
}

/* Barras/acordeones/cabeceras que antes quedaban azul pleno */
.rp-prof-panel .rp-detail-accordion-head,
.rp-prof-panel .rp-history-accordion > summary,
.rp-prof-panel .rp-history-accordion summary,
.rp-prof-panel .rp-accordion-head,
.rp-prof-panel .rp-accordion-title,
.rp-prof-panel .rp-card-head,
.rp-prof-panel .rp-section-head,
.rp-prof-panel .rp-table-card thead th,
.rp-prof-panel .rp-patient-table thead th,
.rp-prof-panel table.rp-table thead th,
.rp-prof-panel .rp-table thead th,
.rp-prof-panel .rp-panel-dark,
.rp-prof-panel .rp-blue-panel,
.rp-prof-panel .rp-dark-panel,
.rp-prof-panel .rp-unavailable-card,
.rp-prof-panel .rp-no-available-card,
.rp-prof-panel .rp-calendar-block-dark,
.rp-prof-panel .rp-config-accordion > summary,
.rp-prof-panel .rp-settings-accordion > summary,
.rp-prof-panel details.rp-config-card > summary,
.rp-prof-panel details.rp-settings-card > summary,
.rp-prof-panel .rp-public-dark-card,
.rp-prof-panel .rp-ticket-table thead th,
.rp-prof-panel .rp-mora-table thead th,
.rp-prof-panel .rp-invoice-table thead th,
.rp-prof-panel .rp-payment-table thead th,
.rp-prof-panel .rp-debt-table thead th,
.rp-prof-panel .rp-session-history-table thead th{
  background:var(--rp-menu-gradient)!important;
  color:#fff!important;
  border-color:rgba(255,255,255,.12)!important;
  box-shadow:none!important;
}

/* Textos e iconos dentro de bloques oscuros */
.rp-prof-panel .rp-detail-accordion-head *,
.rp-prof-panel .rp-history-accordion > summary *,
.rp-prof-panel .rp-history-accordion summary *,
.rp-prof-panel .rp-accordion-head *,
.rp-prof-panel .rp-section-head *,
.rp-prof-panel .rp-panel-dark *,
.rp-prof-panel .rp-blue-panel *,
.rp-prof-panel .rp-dark-panel *,
.rp-prof-panel .rp-unavailable-card *,
.rp-prof-panel .rp-no-available-card *,
.rp-prof-panel .rp-calendar-block-dark *,
.rp-prof-panel .rp-public-dark-card *{
  color:#fff!important;
}
.rp-prof-panel .rp-detail-accordion-head svg,
.rp-prof-panel .rp-history-accordion summary svg,
.rp-prof-panel .rp-accordion-head svg,
.rp-prof-panel .rp-section-head svg,
.rp-prof-panel .rp-panel-dark svg,
.rp-prof-panel .rp-blue-panel svg,
.rp-prof-panel .rp-dark-panel svg,
.rp-prof-panel .rp-unavailable-card svg,
.rp-prof-panel .rp-no-available-card svg,
.rp-prof-panel .rp-calendar-block-dark svg,
.rp-prof-panel .rp-public-dark-card svg{
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.8!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
}

/* Paneles grandes con fondo oscuro: conservar aire interno y borde moderno */
.rp-prof-panel .rp-panel-dark,
.rp-prof-panel .rp-blue-panel,
.rp-prof-panel .rp-dark-panel,
.rp-prof-panel .rp-unavailable-card,
.rp-prof-panel .rp-no-available-card,
.rp-prof-panel .rp-calendar-block-dark,
.rp-prof-panel .rp-public-dark-card{
  border-radius:18px!important;
  border:1px solid rgba(255,255,255,.12)!important;
  box-shadow:0 14px 32px rgba(16,42,86,.10)!important;
  overflow:hidden!important;
}

/* Botones sobre fondos oscuros */
.rp-prof-panel .rp-panel-dark .rp-btn,
.rp-prof-panel .rp-blue-panel .rp-btn,
.rp-prof-panel .rp-dark-panel .rp-btn,
.rp-prof-panel .rp-unavailable-card .rp-btn,
.rp-prof-panel .rp-no-available-card .rp-btn,
.rp-prof-panel .rp-calendar-block-dark .rp-btn,
.rp-prof-panel .rp-public-dark-card .rp-btn{
  background:rgba(255,255,255,.10)!important;
  border:1px solid rgba(255,255,255,.22)!important;
  color:#fff!important;
}

/* Tablas: cabecera con efecto del menú, cuerpo claro */
.rp-prof-panel .rp-table-card thead th,
.rp-prof-panel .rp-patient-table thead th,
.rp-prof-panel table.rp-table thead th,
.rp-prof-panel .rp-ticket-table thead th,
.rp-prof-panel .rp-mora-table thead th,
.rp-prof-panel .rp-invoice-table thead th,
.rp-prof-panel .rp-payment-table thead th,
.rp-prof-panel .rp-debt-table thead th,
.rp-prof-panel .rp-session-history-table thead th{
  font-weight:500!important;
  letter-spacing:.01em!important;
}

/* Checks dentro de paneles oscuros: borde blanco fino y acento rojo */
.rp-prof-panel .rp-panel-dark input[type="checkbox"],
.rp-prof-panel .rp-blue-panel input[type="checkbox"],
.rp-prof-panel .rp-dark-panel input[type="checkbox"],
.rp-prof-panel .rp-unavailable-card input[type="checkbox"],
.rp-prof-panel .rp-no-available-card input[type="checkbox"],
.rp-prof-panel .rp-calendar-block-dark input[type="checkbox"],
.rp-prof-panel .rp-public-dark-card input[type="checkbox"]{
  accent-color:var(--rp-red)!important;
  border-color:rgba(255,255,255,.72)!important;
}

/* v506 - RedPsico: botones/acordeones cerrados igual a /administracion/ (solo CSS) */
.rp-prof-panel{
  --rp-admin-like-gradient:
    radial-gradient(circle at 12% 8%, rgba(255,255,255,.10), transparent 22%),
    radial-gradient(circle at 95% 12%, rgba(224,58,70,.28), transparent 28%),
    linear-gradient(145deg,#102A56 0%,#0d234b 58%,#07172f 100%)!important;
}

/* Acordeones cerrados de Configuración y bloques plegables generales */
.rp-prof-panel details:not([open]) > summary,
.rp-prof-panel .rp-config-card:not([open]) > summary,
.rp-prof-panel .rp-settings-card:not([open]) > summary,
.rp-prof-panel .rp-config-accordion:not([open]) > summary,
.rp-prof-panel .rp-settings-accordion:not([open]) > summary,
.rp-prof-panel .rp-history-accordion:not([open]) > summary,
.rp-prof-panel .rp-detail-card:not([open]) > summary.rp-history-summary,
.rp-prof-panel .rp-accordion:not([open]) > summary,
.rp-prof-panel .rp-collapsible:not([open]) > summary{
  background:var(--rp-admin-like-gradient)!important;
  color:#fff!important;
  border:1px solid rgba(255,255,255,.12)!important;
  border-radius:16px!important;
  box-shadow:none!important;
  min-height:58px!important;
  padding:16px 18px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  gap:14px!important;
  font-weight:500!important;
  letter-spacing:.01em!important;
  list-style:none!important;
  cursor:pointer!important;
}

.rp-prof-panel details:not([open]) > summary::-webkit-details-marker,
.rp-prof-panel .rp-config-card:not([open]) > summary::-webkit-details-marker,
.rp-prof-panel .rp-settings-card:not([open]) > summary::-webkit-details-marker,
.rp-prof-panel .rp-config-accordion:not([open]) > summary::-webkit-details-marker,
.rp-prof-panel .rp-settings-accordion:not([open]) > summary::-webkit-details-marker,
.rp-prof-panel .rp-history-accordion:not([open]) > summary::-webkit-details-marker{
  display:none!important;
}

.rp-prof-panel details:not([open]) > summary *,
.rp-prof-panel .rp-config-card:not([open]) > summary *,
.rp-prof-panel .rp-settings-card:not([open]) > summary *,
.rp-prof-panel .rp-config-accordion:not([open]) > summary *,
.rp-prof-panel .rp-settings-accordion:not([open]) > summary *,
.rp-prof-panel .rp-history-accordion:not([open]) > summary *{
  color:#fff!important;
}

.rp-prof-panel details:not([open]) > summary svg,
.rp-prof-panel .rp-config-card:not([open]) > summary svg,
.rp-prof-panel .rp-settings-card:not([open]) > summary svg,
.rp-prof-panel .rp-config-accordion:not([open]) > summary svg,
.rp-prof-panel .rp-settings-accordion:not([open]) > summary svg,
.rp-prof-panel .rp-history-accordion:not([open]) > summary svg{
  width:21px!important;
  height:21px!important;
  fill:none!important;
  stroke:#fff!important;
  stroke-width:1.65!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
  opacity:.96!important;
}

/* Contenedor del acordeón cerrado: sin card blanca pesada, igual al look de /administracion/ */
.rp-prof-panel details.rp-config-card:not([open]),
.rp-prof-panel details.rp-settings-card:not([open]),
.rp-prof-panel details.rp-config-accordion:not([open]),
.rp-prof-panel details.rp-settings-accordion:not([open]),
.rp-prof-panel details.rp-history-accordion:not([open]){
  background:transparent!important;
  border:0!important;
  border-radius:16px!important;
  padding:0!important;
  margin-bottom:12px!important;
  box-shadow:none!important;
  overflow:visible!important;
}

/* Hover igual que admin, con barra roja interna */
.rp-prof-panel details:not([open]) > summary:hover,
.rp-prof-panel .rp-config-card:not([open]) > summary:hover,
.rp-prof-panel .rp-settings-card:not([open]) > summary:hover,
.rp-prof-panel .rp-config-accordion:not([open]) > summary:hover,
.rp-prof-panel .rp-settings-accordion:not([open]) > summary:hover,
.rp-prof-panel .rp-history-accordion:not([open]) > summary:hover{
  transform:translateY(-1px)!important;
  box-shadow:inset 4px 0 0 var(--rp-red), 0 8px 22px rgba(16,42,86,.08)!important;
  transition:transform .18s ease, box-shadow .18s ease!important;
}

/* Flecha / chevron de los cerrados */
.rp-prof-panel details:not([open]) > summary::after,
.rp-prof-panel .rp-config-card:not([open]) > summary::after,
.rp-prof-panel .rp-settings-card:not([open]) > summary::after,
.rp-prof-panel .rp-config-accordion:not([open]) > summary::after,
.rp-prof-panel .rp-settings-accordion:not([open]) > summary::after{
  content:"⌄"!important;
  color:#fff!important;
  font-size:18px!important;
  line-height:1!important;
  opacity:.9!important;
  margin-left:auto!important;
}
.rp-prof-panel details:not([open]) > summary .rp-chevron-svg,
.rp-prof-panel .rp-history-accordion:not([open]) > summary .rp-chevron-svg{
  margin-left:auto!important;
}

@media(max-width:760px){
  .rp-prof-panel details:not([open]) > summary,
  .rp-prof-panel .rp-config-card:not([open]) > summary,
  .rp-prof-panel .rp-settings-card:not([open]) > summary,
  .rp-prof-panel .rp-config-accordion:not([open]) > summary,
  .rp-prof-panel .rp-settings-accordion:not([open]) > summary,
  .rp-prof-panel .rp-history-accordion:not([open]) > summary{
    min-height:54px!important;
    padding:14px 15px!important;
    border-radius:14px!important;
  }
}

/* v507 - FIX REAL: botones/acordeones cerrados igual que /administracion/ */
.rp-prof-panel .rp-config-accordion-wrap{
  gap:12px!important;
}
.rp-prof-panel details.rp-config-accordion,
.rp-prof-panel details.rp-detail-accordion,
.rp-prof-panel details.rp-history-accordion{
  background:transparent!important;
  border:0!important;
  box-shadow:none!important;
  overflow:visible!important;
  border-radius:18px!important;
}
.rp-prof-panel details.rp-config-accordion > summary,
.rp-prof-panel details.rp-detail-accordion > summary,
.rp-prof-panel details.rp-history-accordion > summary,
.rp-prof-panel .rp-config-accordion > summary,
.rp-prof-panel .rp-detail-accordion > summary,
.rp-prof-panel .rp-history-summary{
  position:relative!important;
  display:flex!important;
  align-items:center!important;
  gap:12px!important;
  width:100%!important;
  min-height:58px!important;
  padding:15px 18px 15px 20px!important;
  box-sizing:border-box!important;
  list-style:none!important;
  cursor:pointer!important;
  border-radius:18px!important;
  border:1px solid rgba(255,255,255,.12)!important;
  color:#fff!important;
  background:
    radial-gradient(circle at 92% 8%, rgba(217,52,58,.42) 0%, rgba(217,52,58,.16) 28%, transparent 52%),
    linear-gradient(135deg, #102A56 0%, #123569 48%, #0D2247 100%)!important;
  box-shadow:none!important;
  font-size:15px!important;
  font-weight:500!important;
  line-height:1.2!important;
  letter-spacing:.01em!important;
  overflow:hidden!important;
  transform:none!important;
}
.rp-prof-panel details.rp-config-accordion > summary::before,
.rp-prof-panel details.rp-detail-accordion > summary::before,
.rp-prof-panel details.rp-history-accordion > summary::before,
.rp-prof-panel .rp-history-summary::before{
  content:""!important;
  position:absolute!important;
  left:0!important;
  top:12px!important;
  bottom:12px!important;
  width:4px!important;
  border-radius:0 8px 8px 0!important;
  background:#D9343A!important;
  opacity:.92!important;
}
.rp-prof-panel details.rp-config-accordion > summary:hover,
.rp-prof-panel details.rp-detail-accordion > summary:hover,
.rp-prof-panel details.rp-history-accordion > summary:hover,
.rp-prof-panel .rp-history-summary:hover{
  filter:brightness(1.04)!important;
  transform:translateY(-1px)!important;
}
.rp-prof-panel details.rp-config-accordion > summary::-webkit-details-marker,
.rp-prof-panel details.rp-detail-accordion > summary::-webkit-details-marker,
.rp-prof-panel details.rp-history-accordion > summary::-webkit-details-marker{
  display:none!important;
}
.rp-prof-panel details.rp-config-accordion > summary *,
.rp-prof-panel details.rp-detail-accordion > summary *,
.rp-prof-panel details.rp-history-accordion > summary *,
.rp-prof-panel .rp-history-summary *{
  color:#fff!important;
  fill:none!important;
}
.rp-prof-panel details.rp-config-accordion > summary svg,
.rp-prof-panel details.rp-detail-accordion > summary svg,
.rp-prof-panel details.rp-history-accordion > summary svg,
.rp-prof-panel .rp-history-summary svg{
  width:21px!important;
  height:21px!important;
  color:#fff!important;
  stroke:#fff!important;
  fill:none!important;
  stroke-width:1.65!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
  opacity:.96!important;
}
.rp-prof-panel .rp-config-accordion-icon{
  width:30px!important;
  height:30px!important;
  flex:0 0 30px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  border-radius:10px!important;
  background:rgba(255,255,255,.10)!important;
  color:#fff!important;
}
.rp-prof-panel .rp-config-accordion-caret,
.rp-prof-panel .rp-chevron-svg{
  margin-left:auto!important;
  color:#fff!important;
  opacity:.95!important;
}
.rp-prof-panel details.rp-config-accordion[open] > summary,
.rp-prof-panel details.rp-detail-accordion[open] > summary,
.rp-prof-panel details.rp-history-accordion[open] > summary{
  border-bottom-left-radius:0!important;
  border-bottom-right-radius:0!important;
}
.rp-prof-panel .rp-config-accordion-body,
.rp-prof-panel .rp-detail-accordion-body,
.rp-prof-panel .rp-history-body{
  background:#fff!important;
  border:1px solid rgba(16,42,86,.12)!important;
  border-top:0!important;
  border-bottom-left-radius:18px!important;
  border-bottom-right-radius:18px!important;
  box-shadow:none!important;
}
@media(max-width:760px){
  .rp-prof-panel details.rp-config-accordion > summary,
  .rp-prof-panel details.rp-detail-accordion > summary,
  .rp-prof-panel details.rp-history-accordion > summary,
  .rp-prof-panel .rp-history-summary{
    min-height:54px!important;
    padding:14px 15px 14px 18px!important;
    border-radius:16px!important;
    font-size:14px!important;
  }
}

/* RedPsico v508 - menú lateral profesional igual al estilo de Administración */
.rp-prof-panel{
  --rp-admin-menu-blue:#102A56!important;
  --rp-admin-menu-blue-2:#0b224a!important;
  --rp-admin-menu-red:#d83a42!important;
}
.rp-prof-panel .rp-prof-sidebar{
  background:
    radial-gradient(circle at 18% 8%, rgba(216,58,66,.32), transparent 26%),
    radial-gradient(circle at 92% 90%, rgba(14,112,190,.30), transparent 34%),
    linear-gradient(180deg, #14245c 0%, #102A56 46%, #061b3c 100%)!important;
  border-right:0!important;
  padding:18px 12px!important;
  gap:12px!important;
  box-shadow:10px 0 30px rgba(6,27,60,.14)!important;
  overflow:hidden!important;
  position:relative!important;
}
.rp-prof-panel .rp-prof-sidebar:before{
  content:""!important;
  position:absolute!important;
  inset:0!important;
  pointer-events:none!important;
  background:
    linear-gradient(135deg, rgba(255,255,255,.08), transparent 34%),
    repeating-linear-gradient(135deg, rgba(255,255,255,.035) 0 1px, transparent 1px 11px)!important;
  opacity:.85!important;
}
.rp-prof-panel .rp-prof-sidebar > *{
  position:relative!important;
  z-index:1!important;
}
.rp-prof-panel .rp-prof-brand{
  height:74px!important;
  margin:0 0 16px!important;
  justify-content:center!important;
}
.rp-prof-panel.rp-sidebar-expanded .rp-prof-brand{
  justify-content:flex-start!important;
}
.rp-prof-panel .rp-prof-brand .rp-brand-logo-wrap{
  width:58px!important;
  height:58px!important;
  min-width:58px!important;
  border-radius:20px!important;
  background:rgba(255,255,255,.94)!important;
  border:1px solid rgba(255,255,255,.45)!important;
  box-shadow:0 12px 26px rgba(0,0,0,.18)!important;
}
.rp-prof-panel .rp-prof-brand .rp-brand-logo{
  width:52px!important;
  height:52px!important;
  border-radius:16px!important;
}
.rp-prof-panel .rp-prof-brand strong{
  color:#fff!important;
  font-weight:600!important;
}
.rp-prof-panel .rp-prof-sidebar a{
  width:58px!important;
  height:58px!important;
  min-height:58px!important;
  margin:0 auto!important;
  border-radius:22px!important;
  color:rgba(255,255,255,.88)!important;
  background:rgba(255,255,255,.055)!important;
  border:1px solid rgba(255,255,255,.11)!important;
  box-shadow:inset 0 1px 0 rgba(255,255,255,.08)!important;
  transition:background .18s ease, color .18s ease, transform .18s ease, border-color .18s ease, box-shadow .18s ease, width .22s ease, padding .22s ease!important;
  position:relative!important;
  overflow:hidden!important;
}
.rp-prof-panel .rp-prof-sidebar a:before{
  content:""!important;
  display:block!important;
  position:absolute!important;
  left:0!important;
  top:12px!important;
  bottom:12px!important;
  width:0!important;
  border-radius:0 999px 999px 0!important;
  background:#d83a42!important;
  opacity:0!important;
  transition:width .18s ease, opacity .18s ease!important;
}
.rp-prof-panel .rp-prof-sidebar a:hover,
.rp-prof-panel .rp-prof-sidebar a.active{
  color:#fff!important;
  background:rgba(255,255,255,.14)!important;
  border-color:rgba(255,255,255,.20)!important;
  transform:translateY(-1px)!important;
  box-shadow:0 12px 26px rgba(0,0,0,.16), inset 0 1px 0 rgba(255,255,255,.12)!important;
}
.rp-prof-panel .rp-prof-sidebar a.active{
  background:linear-gradient(135deg, rgba(255,255,255,.18), rgba(255,255,255,.08))!important;
  box-shadow:0 14px 28px rgba(0,0,0,.18), -8px 0 22px rgba(216,58,66,.26), inset 0 1px 0 rgba(255,255,255,.16)!important;
}
.rp-prof-panel .rp-prof-sidebar a.active:before,
.rp-prof-panel .rp-prof-sidebar a:hover:before{
  width:5px!important;
  opacity:1!important;
}
.rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar a{
  width:100%!important;
  height:46px!important;
  min-height:46px!important;
  margin:0!important;
  border-radius:16px!important;
  padding:0 14px!important;
  justify-content:flex-start!important;
  gap:12px!important;
  font-size:13px!important;
}
.rp-prof-panel .rp-nav-icon{
  color:currentColor!important;
  width:24px!important;
  min-width:24px!important;
  flex:0 0 24px!important;
}
.rp-prof-panel .rp-nav-icon svg,
.rp-prof-panel .rp-prof-sidebar a svg{
  width:21px!important;
  height:21px!important;
  min-width:21px!important;
  min-height:21px!important;
  fill:none!important;
  stroke:currentColor!important;
  stroke-width:1.65!important;
  stroke-linecap:round!important;
  stroke-linejoin:round!important;
}
.rp-prof-panel .rp-nav-label{
  color:inherit!important;
  font-weight:500!important;
}
.rp-prof-panel.rp-sidebar-expanded .rp-nav-label{
  opacity:1!important;
  width:auto!important;
  max-width:200px!important;
}

@media(max-width:760px){
  .rp-prof-panel .rp-prof-sidebar,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar{
    width:100%!important;
    max-width:none!important;
    border-radius:0!important;
    padding:12px!important;
    gap:8px!important;
    overflow:visible!important;
  }
  .rp-prof-panel .rp-prof-brand{
    height:58px!important;
    margin:0!important;
    justify-content:flex-start!important;
  }
  .rp-prof-panel .rp-prof-brand .rp-brand-logo-wrap{
    width:48px!important;height:48px!important;min-width:48px!important;border-radius:16px!important;
  }
  .rp-prof-panel .rp-prof-brand .rp-brand-logo{width:44px!important;height:44px!important}
  .rp-prof-panel .rp-sidebar-toggle{
    background:rgba(255,255,255,.13)!important;
    color:#fff!important;
    border:1px solid rgba(255,255,255,.16)!important;
  }
  .rp-prof-panel .rp-prof-sidebar a,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar a,
  .rp-prof-panel .rp-prof-sidebar.mobile-open a{
    width:100%!important;
    height:48px!important;
    min-height:48px!important;
    margin:0!important;
    border-radius:16px!important;
    padding:0 14px!important;
    justify-content:flex-start!important;
    gap:12px!important;
    font-size:14px!important;
  }
}


/* v509 - Agenda interactiva móvil: popup full screen real, sin recorte y con scroll interno.
   Solo afecta la capa del popup de calendario general; no toca lógica ni otros modales. */
@media (max-width: 760px){
  html.rp-agenda-popup-open,
  html.rp-agenda-popup-open body{
    overflow:hidden!important;
    width:100%!important;
    max-width:100%!important;
    overscroll-behavior:none!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]),
  body > .rp-agenda-popup-layer:not([hidden]){
    position:fixed!important;
    inset:0!important;
    left:0!important;
    right:0!important;
    top:0!important;
    bottom:0!important;
    width:100vw!important;
    max-width:100vw!important;
    height:100dvh!important;
    max-height:100dvh!important;
    min-height:100dvh!important;
    z-index:2147483000!important;
    display:flex!important;
    align-items:stretch!important;
    justify-content:stretch!important;
    padding:0!important;
    margin:0!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
    background:#fff!important;
    transform:none!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-backdrop{
    display:none!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-card,
  body > .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-card{
    position:relative!important;
    inset:auto!important;
    display:flex!important;
    flex-direction:column!important;
    width:100vw!important;
    max-width:100vw!important;
    min-width:100vw!important;
    height:100dvh!important;
    max-height:100dvh!important;
    min-height:100dvh!important;
    margin:0!important;
    padding:0!important;
    border:0!important;
    border-radius:0!important;
    box-shadow:none!important;
    overflow:hidden!important;
    background:
      radial-gradient(circle at top left, rgba(16,42,86,.05), transparent 42%),
      radial-gradient(circle at bottom right, rgba(220,38,38,.035), transparent 38%),
      #ffffff!important;
    box-sizing:border-box!important;
    transform:none!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-body,
  html body .rp-agenda-popup-layer:not([hidden]) [data-rp-agenda-popup-body]{
    display:block!important;
    flex:1 1 auto!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    height:auto!important;
    max-height:none!important;
    overflow-y:auto!important;
    overflow-x:hidden!important;
    -webkit-overflow-scrolling:touch!important;
    padding:18px 16px calc(140px + env(safe-area-inset-bottom,0px))!important;
    margin:0!important;
    box-sizing:border-box!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-x{
    position:fixed!important;
    top:calc(12px + env(safe-area-inset-top,0px))!important;
    right:14px!important;
    z-index:2147483002!important;
    width:44px!important;
    height:44px!important;
    min-width:44px!important;
    border-radius:16px!important;
    border:1px solid #dbe4ee!important;
    background:#ffffff!important;
    color:#0f172a!important;
    font-size:24px!important;
    line-height:1!important;
    box-shadow:0 8px 20px rgba(16,42,86,.08)!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-head{
    display:grid!important;
    grid-template-columns:58px minmax(0,1fr)!important;
    gap:14px!important;
    align-items:center!important;
    width:100%!important;
    max-width:100%!important;
    padding:14px 58px 18px 0!important;
    margin:0 0 12px!important;
    box-sizing:border-box!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-mainicon{
    width:58px!important;
    height:58px!important;
    min-width:58px!important;
    border-radius:18px!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-head h3{
    font-size:24px!important;
    line-height:1.08!important;
    margin:0 0 6px!important;
    max-width:100%!important;
    white-space:normal!important;
    overflow-wrap:normal!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-head p{
    font-size:17px!important;
    line-height:1.35!important;
    margin:0!important;
    color:#64748b!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-appointment-popup-form,
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-block-popup-form{
    display:flex!important;
    flex-direction:column!important;
    gap:16px!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    overflow:visible!important;
    box-sizing:border-box!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-appointment-popup-form > *,
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-block-popup-form > *,
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-appointment-popup-form > label,
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-block-popup-form > label,
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-appointment-popup-form > .full,
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-block-popup-form > .full{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    grid-column:1 / -1!important;
    box-sizing:border-box!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]) .rp-gc-appointment-actions,
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-block-actions{
    display:flex!important;
    flex-direction:column!important;
    gap:12px!important;
    width:100%!important;
    padding-bottom:20px!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]) .rp-gc-appointment-actions .rp-btn,
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-block-actions .rp-btn,
  html body .rp-agenda-popup-layer:not([hidden]) .rp-general-block-submit{
    width:100%!important;
    min-height:56px!important;
    border-radius:18px!important;
    font-size:16px!important;
  }
}

/* v510 - Agenda interactiva PC/notebook: popup centrado real, sin quedar trabado abajo.
   Solo CSS; no toca lógica ni eventos. */
@media (min-width: 761px){
  html.rp-agenda-popup-open,
  html.rp-agenda-popup-open body{
    overflow:hidden!important;
    overscroll-behavior:none!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]),
  body > .rp-agenda-popup-layer:not([hidden]){
    position:fixed!important;
    inset:0!important;
    width:100vw!important;
    height:100dvh!important;
    min-height:100dvh!important;
    max-height:100dvh!important;
    z-index:2147483000!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    padding:28px 28px!important;
    margin:0!important;
    overflow:hidden!important;
    box-sizing:border-box!important;
    transform:none!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-backdrop{
    position:absolute!important;
    inset:0!important;
    display:block!important;
    background:rgba(15,23,42,.52)!important;
    backdrop-filter:blur(3px)!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-card{
    position:relative!important;
    inset:auto!important;
    top:auto!important;
    right:auto!important;
    bottom:auto!important;
    left:auto!important;
    width:min(520px, calc(100vw - 72px))!important;
    max-width:min(520px, calc(100vw - 72px))!important;
    min-width:0!important;
    height:auto!important;
    min-height:0!important;
    max-height:calc(100dvh - 80px)!important;
    margin:0 auto!important;
    padding:18px!important;
    border-radius:22px!important;
    overflow-y:auto!important;
    overflow-x:hidden!important;
    -webkit-overflow-scrolling:touch!important;
    box-sizing:border-box!important;
    transform:none!important;
    background:#ffffff!important;
    box-shadow:0 22px 70px rgba(15,23,42,.24)!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-body,
  html body .rp-agenda-popup-layer:not([hidden]) [data-rp-agenda-popup-body]{
    max-height:none!important;
    overflow:visible!important;
    padding-bottom:18px!important;
  }
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-x{
    position:absolute!important;
    top:12px!important;
    right:12px!important;
    z-index:3!important;
  }
}

/* v511 - Agenda interactiva: botón Guardar actividad visible en popups.
   Solo estética: corrige fondo/texto/icono del submit que quedaba blanco sobre blanco. */
html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-block-popup-form .rp-agenda-block-actions .rp-general-block-submit,
html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-block-popup-form .rp-general-block-submit,
html body .rp-agenda-popup-card .rp-agenda-block-popup-form .rp-general-block-submit,
html body .rp-agenda-popup-card .rp-general-block-submit{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:10px!important;
  width:auto!important;
  min-width:210px!important;
  min-height:52px!important;
  padding:13px 22px!important;
  border-radius:16px!important;
  border:1px solid #102A56!important;
  background:linear-gradient(135deg,#102A56 0%,#0b2148 72%,#163769 100%)!important;
  color:#ffffff!important;
  -webkit-text-fill-color:#ffffff!important;
  opacity:1!important;
  visibility:visible!important;
  box-shadow:0 12px 26px rgba(16,42,86,.18)!important;
  font-size:15px!important;
  font-weight:700!important;
  line-height:1.1!important;
  text-decoration:none!important;
}
html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-block-popup-form .rp-general-block-submit:hover,
html body .rp-agenda-popup-card .rp-general-block-submit:hover{
  background:linear-gradient(135deg,#173866 0%,#102A56 72%,#c43145 155%)!important;
  color:#ffffff!important;
  -webkit-text-fill-color:#ffffff!important;
  transform:translateY(-1px)!important;
  box-shadow:0 15px 30px rgba(16,42,86,.22)!important;
}
html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-block-popup-form .rp-general-block-submit svg,
html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-block-popup-form .rp-general-block-submit .rp-btn-svg,
html body .rp-agenda-popup-card .rp-general-block-submit svg,
html body .rp-agenda-popup-card .rp-general-block-submit .rp-btn-svg{
  color:#ffffff!important;
  stroke:#ffffff!important;
  fill:none!important;
  opacity:1!important;
  -webkit-text-fill-color:#ffffff!important;
}
@media (max-width:760px){
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-block-popup-form .rp-agenda-block-actions .rp-general-block-submit,
  html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-block-popup-form .rp-general-block-submit,
  html body .rp-agenda-popup-card .rp-agenda-block-popup-form .rp-general-block-submit,
  html body .rp-agenda-popup-card .rp-general-block-submit{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    min-height:58px!important;
    border-radius:18px!important;
    font-size:16px!important;
    margin-top:2px!important;
  }
}

/* v512 - Facturacion: layout alineado, botones equilibrados y eliminar comprobantes */
#facturacion .rp-billing-head-modern{
  align-items:flex-start!important;
  gap:18px!important;
}
#facturacion .rp-billing-top-actions{
  display:flex!important;
  flex-wrap:wrap!important;
  align-items:center!important;
  justify-content:flex-end!important;
  gap:10px!important;
}
#facturacion .rp-billing-top-actions .rp-btn,
#facturacion .rp-billing-top-actions button,
#facturacion .rp-billing-top-actions input[type="submit"]{
  min-height:42px!important;
  border-radius:13px!important;
  font-weight:650!important;
}
#facturacion .rp-billing-top-actions .rp-btn-light,
#facturacion .rp-billing-top-actions .rp-print-scope,
#facturacion .rp-billing-clear-btn,
#facturacion .rp-invoice-draft-btn{
  background:#fff!important;
  color:#102A56!important;
  border:1.5px solid rgba(16,42,86,.18)!important;
  box-shadow:none!important;
}
#facturacion .rp-billing-top-actions .rp-btn:not(.rp-btn-light),
#facturacion .rp-billing-top-actions input[type="submit"]{
  background:linear-gradient(135deg,#102A56 0%,#143b78 58%,#b9243a 160%)!important;
  color:#fff!important;
  border:0!important;
}
#facturacion .rp-billing-table-card{
  border-radius:22px!important;
  border:1px solid rgba(16,42,86,.10)!important;
  background:linear-gradient(145deg,rgba(255,255,255,.98),rgba(248,251,255,.96))!important;
  overflow:hidden!important;
}
#facturacion .rp-billing-tools-modern{
  display:grid!important;
  grid-template-columns:minmax(0,1.45fr) minmax(220px,.85fr) auto!important;
  gap:14px!important;
  align-items:end!important;
  padding:16px!important;
  margin:0 0 18px!important;
  border:1px solid rgba(16,42,86,.10)!important;
  border-radius:18px!important;
  background:radial-gradient(circle at top left,rgba(16,42,86,.05),transparent 45%),radial-gradient(circle at bottom right,rgba(217,35,55,.045),transparent 45%),#fff!important;
}
#facturacion .rp-billing-filter-form{
  display:grid!important;
  grid-template-columns:minmax(170px,.55fr) minmax(210px,1fr) auto!important;
  gap:12px!important;
  align-items:end!important;
  margin:0!important;
  width:100%!important;
}
#facturacion .rp-billing-filter-form label,
#facturacion .rp-billing-search-label{
  display:flex!important;
  flex-direction:column!important;
  gap:7px!important;
  margin:0!important;
  font-weight:650!important;
  color:#102A56!important;
}
#facturacion .rp-billing-filter-form label span,
#facturacion .rp-billing-search-label span{
  font-size:12px!important;
  line-height:1.2!important;
  letter-spacing:.01em!important;
  color:#64748b!important;
  font-weight:650!important;
}
#facturacion .rp-billing-filter-form input[type="month"],
#facturacion .rp-billing-filter-form select,
#facturacion .rp-billing-search-label input{
  width:100%!important;
  min-height:46px!important;
  height:46px!important;
  padding:0 14px!important;
  border:1.5px solid rgba(16,42,86,.14)!important;
  border-radius:14px!important;
  background:#fff!important;
  color:#101828!important;
  font-size:14px!important;
  font-weight:600!important;
  box-shadow:0 1px 0 rgba(16,42,86,.03)!important;
  opacity:1!important;
  visibility:visible!important;
  -webkit-appearance:auto!important;
  appearance:auto!important;
}
#facturacion .rp-billing-filter-form input[type="month"]::-webkit-calendar-picker-indicator{
  opacity:1!important;
  filter:none!important;
}
#facturacion .rp-billing-filter-actions{
  display:flex!important;
  gap:8px!important;
  align-items:center!important;
}
#facturacion .rp-billing-filter-btn{
  min-height:46px!important;
  padding:0 18px!important;
  border:0!important;
  background:linear-gradient(135deg,#102A56,#143b78)!important;
  color:#fff!important;
  border-radius:14px!important;
}
#facturacion .rp-billing-clear-btn{
  min-height:46px!important;
  padding:0 16px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  border-radius:14px!important;
}
#facturacion .rp-billing-total-pill{
  min-height:46px!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  padding:0 16px!important;
  border-radius:999px!important;
  background:rgba(16,42,86,.055)!important;
  border:1px solid rgba(16,42,86,.10)!important;
  color:#102A56!important;
  font-weight:750!important;
  white-space:nowrap!important;
}
#facturacion .rp-invoices-table-modern thead th{
  background:linear-gradient(135deg,#102A56 0%,#17396d 70%,#b9243a 165%)!important;
  color:#fff!important;
  font-weight:650!important;
}
#facturacion .rp-invoice-actions-stack{
  display:flex!important;
  flex-direction:column!important;
  align-items:flex-start!important;
  gap:8px!important;
}
#facturacion .rp-invoice-actions-stack form{
  margin:0!important;
  width:100%!important;
}
#facturacion .rp-invoice-primary-btn{
  background:linear-gradient(135deg,#102A56,#143b78)!important;
  color:#fff!important;
  border:0!important;
  border-radius:12px!important;
  box-shadow:none!important;
}
#facturacion .rp-invoice-delete-btn{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:7px!important;
  min-height:34px!important;
  padding:8px 11px!important;
  border-radius:10px!important;
  background:#fff!important;
  color:#c92a3d!important;
  border:1.5px solid rgba(201,42,61,.28)!important;
  font-size:12px!important;
  font-weight:700!important;
  cursor:pointer!important;
  text-decoration:none!important;
}
#facturacion .rp-invoice-delete-btn svg,
#facturacion .rp-invoice-delete-btn .rp-btn-svg{
  color:#c92a3d!important;
  stroke:#c92a3d!important;
}
#facturacion .rp-invoice-draft-btn{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:7px!important;
  min-height:34px!important;
  padding:8px 11px!important;
  border-radius:10px!important;
  font-size:12px!important;
  font-weight:700!important;
  text-decoration:none!important;
}
#facturacion .rp-invoice-number-label{
  display:block!important;
  color:#102A56!important;
  font-weight:750!important;
  margin-bottom:2px!important;
}
@media (max-width: 900px){
  #facturacion .rp-billing-head-modern{
    display:flex!important;
    flex-direction:column!important;
  }
  #facturacion .rp-billing-top-actions{
    width:100%!important;
    display:grid!important;
    grid-template-columns:1fr!important;
  }
  #facturacion .rp-billing-top-actions .rp-btn,
  #facturacion .rp-billing-top-actions button,
  #facturacion .rp-billing-top-actions input[type="submit"]{
    width:100%!important;
    justify-content:center!important;
  }
  #facturacion .rp-billing-tools-modern{
    grid-template-columns:1fr!important;
    gap:12px!important;
    padding:14px!important;
    overflow:visible!important;
  }
  #facturacion .rp-billing-filter-form{
    grid-template-columns:1fr!important;
    gap:10px!important;
  }
  #facturacion .rp-billing-filter-actions{
    display:grid!important;
    grid-template-columns:1fr 1fr!important;
    gap:10px!important;
  }
  #facturacion .rp-billing-search-label,
  #facturacion .rp-billing-total-pill{
    width:100%!important;
  }
  #facturacion .rp-billing-table-card{
    padding:18px!important;
    margin-left:0!important;
    margin-right:0!important;
  }
}
@media (max-width: 640px){
  #facturacion .rp-prof-head h1,
  #facturacion .rp-title-with-icon{
    font-size:27px!important;
    line-height:1.08!important;
  }
  #facturacion .rp-billing-filter-actions{
    grid-template-columns:1fr!important;
  }
  #facturacion .rp-billing-filter-form input[type="month"],
  #facturacion .rp-billing-filter-form select,
  #facturacion .rp-billing-search-label input{
    min-height:50px!important;
    height:50px!important;
    font-size:16px!important;
  }
  #facturacion .rp-responsive-table{
    overflow-x:auto!important;
    -webkit-overflow-scrolling:touch!important;
  }
  #facturacion .rp-invoices-table-modern{
    min-width:680px!important;
  }
  #facturacion .rp-invoice-actions-stack{
    min-width:145px!important;
  }
}


/* v513 - Facturación móvil real: ancho correcto, filtros alineados y acciones visibles */
#facturacion,
#facturacion *{box-sizing:border-box!important;}
#facturacion{max-width:100%!important;overflow-x:hidden!important;}
#facturacion .rp-billing-table-card{width:100%!important;max-width:100%!important;overflow:hidden!important;}
#facturacion .rp-billing-tools-modern{width:100%!important;max-width:100%!important;}
#facturacion .rp-billing-filter-form,
#facturacion .rp-billing-filter-form label,
#facturacion .rp-billing-search-label{min-width:0!important;max-width:100%!important;}
#facturacion .rp-billing-filter-form input[type="month"],
#facturacion .rp-billing-filter-form select,
#facturacion .rp-billing-search-label input{max-width:100%!important;overflow:hidden!important;text-overflow:ellipsis!important;}
#facturacion .rp-billing-clear-btn{color:#102A56!important;text-align:center!important;font-weight:750!important;}
#facturacion .rp-responsive-table{width:100%!important;max-width:100%!important;overflow-x:auto!important;overflow-y:hidden!important;-webkit-overflow-scrolling:touch!important;display:block!important;border-radius:16px!important;}
#facturacion .rp-responsive-table table{border-collapse:separate!important;border-spacing:0!important;}
#facturacion .rp-invoice-delete-btn{background:#fff!important;color:#c92a3d!important;border:1.5px solid rgba(201,42,61,.38)!important;opacity:1!important;visibility:visible!important;}
#facturacion .rp-invoice-delete-btn .rp-btn-svg,
#facturacion .rp-invoice-delete-btn svg{color:#c92a3d!important;stroke:#c92a3d!important;}

@media (max-width: 720px){
  #facturacion{padding-left:0!important;padding-right:0!important;}
  #facturacion .rp-prof-head{padding-left:16px!important;padding-right:16px!important;}
  #facturacion .rp-billing-head-modern{gap:12px!important;}
  #facturacion .rp-billing-top-actions{display:grid!important;grid-template-columns:1fr!important;gap:10px!important;width:100%!important;padding:0 16px!important;}
  #facturacion .rp-billing-top-actions .rp-btn,
  #facturacion .rp-billing-top-actions button,
  #facturacion .rp-billing-top-actions input[type="submit"]{width:100%!important;max-width:100%!important;min-height:48px!important;border-radius:16px!important;font-size:15px!important;}
  #facturacion .rp-billing-table-card{padding:14px!important;margin:14px 12px!important;width:calc(100% - 24px)!important;max-width:calc(100% - 24px)!important;border-radius:22px!important;}
  #facturacion .rp-billing-tools-modern{display:flex!important;flex-direction:column!important;gap:12px!important;padding:14px!important;margin:0 0 18px!important;width:100%!important;max-width:100%!important;border-radius:20px!important;}
  #facturacion .rp-billing-filter-form{display:flex!important;flex-direction:column!important;gap:12px!important;width:100%!important;max-width:100%!important;}
  #facturacion .rp-billing-filter-actions{display:grid!important;grid-template-columns:1fr!important;gap:10px!important;width:100%!important;}
  #facturacion .rp-billing-filter-btn,
  #facturacion .rp-billing-clear-btn{width:100%!important;height:52px!important;min-height:52px!important;border-radius:16px!important;justify-content:center!important;align-items:center!important;display:flex!important;padding:0 16px!important;font-size:16px!important;line-height:1!important;}
  #facturacion .rp-billing-clear-btn{background:#fff!important;border:1.5px solid rgba(16,42,86,.18)!important;color:#102A56!important;}
  #facturacion .rp-billing-search-label{width:100%!important;display:flex!important;}
  #facturacion .rp-billing-total-pill{width:100%!important;min-height:48px!important;justify-content:flex-start!important;padding:0 16px!important;border-radius:18px!important;}
  #facturacion .rp-billing-filter-form input[type="month"],
  #facturacion .rp-billing-filter-form select,
  #facturacion .rp-billing-search-label input{width:100%!important;max-width:100%!important;height:54px!important;min-height:54px!important;border-radius:17px!important;font-size:16px!important;padding-left:16px!important;padding-right:16px!important;}
  #facturacion .rp-billing-table-card h2{font-size:22px!important;line-height:1.15!important;margin:22px 0 12px!important;}
  #facturacion .rp-responsive-table{margin:0!important;width:100%!important;max-width:100%!important;overflow-x:auto!important;border:1px solid rgba(16,42,86,.08)!important;background:#fff!important;}
  #facturacion .rp-invoices-table-modern{min-width:640px!important;width:640px!important;max-width:none!important;font-size:13px!important;}
  #facturacion .rp-invoices-table-modern th,
  #facturacion .rp-invoices-table-modern td{padding:12px 14px!important;white-space:normal!important;}
  #facturacion .rp-invoices-table-modern th{font-size:12px!important;line-height:1.2!important;}
  #facturacion .rp-invoices-table-modern td strong{font-size:13px!important;}
  #facturacion .rp-invoices-table-modern small{font-size:11px!important;}
  #facturacion .rp-invoice-actions-stack{min-width:150px!important;width:150px!important;gap:8px!important;}
  #facturacion .rp-invoice-actions-stack .rp-btn,
  #facturacion .rp-invoice-actions-stack .rp-mini-action,
  #facturacion .rp-invoice-delete-btn{width:100%!important;max-width:100%!important;justify-content:center!important;text-align:center!important;white-space:normal!important;line-height:1.15!important;}
}

@media (max-width: 420px){
  #facturacion .rp-billing-table-card{margin-left:10px!important;margin-right:10px!important;width:calc(100% - 20px)!important;max-width:calc(100% - 20px)!important;padding:12px!important;}
  #facturacion .rp-billing-tools-modern{padding:12px!important;}
  #facturacion .rp-invoices-table-modern{min-width:600px!important;width:600px!important;}
  #facturacion .rp-invoice-actions-stack{min-width:135px!important;width:135px!important;}
}

/* v514 - Facturación: micro-ajustes móviles de alineación real */
@media (max-width: 700px){
  #facturacion .rp-billing-tools-modern{
    overflow:hidden!important;
  }
  #facturacion .rp-billing-filter-form label{
    width:100%!important;
    display:flex!important;
    flex-direction:column!important;
    align-items:stretch!important;
    gap:7px!important;
    margin:0!important;
  }
  #facturacion .rp-billing-filter-form label span,
  #facturacion .rp-billing-search-label span{
    display:block!important;
    width:100%!important;
    text-align:left!important;
    margin:0!important;
    padding:0!important;
    line-height:1.25!important;
  }
  #facturacion .rp-billing-filter-form input[type="month"]{
    display:block!important;
    box-sizing:border-box!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    margin:0!important;
    padding:0 14px!important;
    text-align:center!important;
    text-align-last:center!important;
    appearance:none!important;
    -webkit-appearance:none!important;
    overflow:hidden!important;
  }
  #facturacion .rp-billing-filter-form input[type="month"]::-webkit-date-and-time-value{
    text-align:center!important;
    margin:0!important;
    padding:0!important;
    width:100%!important;
  }
  #facturacion .rp-billing-filter-form input[type="month"]::-webkit-calendar-picker-indicator{
    position:absolute!important;
    right:14px!important;
    margin:0!important;
    opacity:.65!important;
  }
  #facturacion .rp-billing-clear-btn{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    text-align:center!important;
    line-height:52px!important;
    padding-top:0!important;
    padding-bottom:0!important;
  }
  #facturacion .rp-billing-total-pill{
    display:flex!important;
    align-items:center!important;
    justify-content:flex-start!important;
    line-height:1!important;
    padding-top:0!important;
    padding-bottom:0!important;
  }
  #facturacion .rp-billing-total-pill strong,
  #facturacion .rp-billing-total-pill span{
    line-height:1!important;
    display:inline-flex!important;
    align-items:center!important;
  }
  #facturacion .rp-responsive-table{
    padding:0!important;
    margin-left:0!important;
    margin-right:0!important;
    border-radius:18px!important;
    overflow-x:auto!important;
    overflow-y:hidden!important;
  }
  #facturacion .rp-responsive-table table{
    margin:0!important;
    transform:none!important;
  }
  #facturacion .rp-invoices-table-modern th:first-child,
  #facturacion .rp-invoices-table-modern td:first-child{
    padding-left:18px!important;
    min-width:120px!important;
  }
  #facturacion .rp-invoices-table-modern th{
    vertical-align:middle!important;
  }
}


/* v501 - Branding RedPsico: logo blanco sin recuadro en panel profesional */
.rp-prof-brand .rp-brand-logo-wrap,
.rp-prof-panel .rp-prof-brand .rp-brand-logo-wrap,
.rp-prof-sidebar .rp-brand-logo-wrap,
body > .rp-prof-sidebar .rp-brand-logo-wrap{
  background:transparent!important;
  border:0!important;
  box-shadow:none!important;
  border-radius:0!important;
  overflow:visible!important;
}
.rp-prof-brand .rp-brand-logo,
.rp-prof-panel .rp-prof-brand .rp-brand-logo,
.rp-prof-sidebar .rp-brand-logo,
.rp-prof-sidebar .rp-brand-logo-wrap img,
body > .rp-prof-sidebar .rp-brand-logo,
body > .rp-prof-sidebar .rp-brand-logo-wrap img{
  object-fit:contain!important;
  border-radius:0!important;
  background:transparent!important;
  box-shadow:none!important;
}
.rp-login-logo{background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;border:0!important;box-shadow:none!important;}
.rp-pwa-logo{background:linear-gradient(135deg,#102A56 0%,#0B4F8A 62%,#B83A3F 100%)!important;border:0!important;box-shadow:none!important;}


/* v-logo-blanco-fix: panel profesional sin recuadro blanco en logo */
.rp-prof-brand .rp-brand-logo-wrap,
.rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap,
.rp-prof-panel > .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap,
.rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap,
.rp-prof-sidebar.mobile-open .rp-brand-logo-wrap,
body > .rp-prof-sidebar.mobile-open .rp-brand-logo-wrap{
  background:transparent!important;
  border:0!important;
  box-shadow:none!important;
  border-radius:0!important;
  overflow:visible!important;
}
.rp-prof-brand .rp-brand-logo,
.rp-prof-brand .rp-brand-logo-wrap img,
.rp-prof-sidebar:not(.mobile-open) .rp-brand-logo,
.rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap img,
.rp-prof-sidebar.mobile-open .rp-brand-logo,
.rp-prof-sidebar.mobile-open .rp-brand-logo-wrap img,
body > .rp-prof-sidebar.mobile-open .rp-brand-logo,
body > .rp-prof-sidebar.mobile-open .rp-brand-logo-wrap img{
  background:transparent!important;
  border:0!important;
  box-shadow:none!important;
  border-radius:0!important;
  object-fit:contain!important;
}


/* vLogoFinal - quitar recuadro blanco del logo en PC y móvil */
.rp-prof-brand .rp-brand-logo-wrap,
.rp-prof-panel .rp-prof-brand .rp-brand-logo-wrap,
body > .rp-prof-sidebar .rp-prof-brand .rp-brand-logo-wrap,
body > .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo-wrap{
  background:transparent!important;
  border:0!important;
  box-shadow:none!important;
  border-radius:0!important;
  overflow:visible!important;
}
.rp-prof-brand .rp-brand-logo,
.rp-prof-panel .rp-prof-brand .rp-brand-logo,
body > .rp-prof-sidebar .rp-prof-brand .rp-brand-logo,
body > .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo{
  background:transparent!important;
  border:0!important;
  box-shadow:none!important;
  border-radius:0!important;
  object-fit:contain!important;
}
@media(max-width:760px){
  body > .rp-prof-sidebar.mobile-open{
    background:linear-gradient(135deg,#102A56 0%,#0B376D 72%,#5A1F3E 100%)!important;
    color:#fff!important;
  }
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand{
    background:transparent!important;
    border-bottom:1px solid rgba(255,255,255,.20)!important;
  }
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo-wrap{
    width:78px!important;
    height:58px!important;
    min-width:78px!important;
  }
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand .rp-brand-logo{
    width:78px!important;
    height:auto!important;
    max-height:58px!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand .rp-brand-logo-wrap,
  .rp-prof-panel .rp-prof-brand .rp-brand-logo-wrap{
    background:transparent!important;
  }
}


/* v-logo-mobile-final-real: panel profesional móvil */
@media (max-width:760px){
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap,
  .rp-prof-panel > .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap,
  .rp-prof-sidebar.mobile-open .rp-brand-logo-wrap,
  body > .rp-prof-sidebar.mobile-open .rp-brand-logo-wrap{
    background:transparent!important;
    border:0!important;
    box-shadow:none!important;
    border-radius:0!important;
    overflow:visible!important;
  }
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo,
  .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap img,
  .rp-prof-sidebar.mobile-open .rp-brand-logo,
  .rp-prof-sidebar.mobile-open .rp-brand-logo-wrap img,
  body > .rp-prof-sidebar.mobile-open .rp-brand-logo,
  body > .rp-prof-sidebar.mobile-open .rp-brand-logo-wrap img{
    background:transparent!important;
    border:0!important;
    box-shadow:none!important;
    object-fit:contain!important;
  }
  .rp-prof-sidebar.mobile-open .rp-prof-brand,
  body > .rp-prof-sidebar.mobile-open .rp-prof-brand{
    background:transparent!important;
  }
}

/* v2.10.22 final real logo no box */
.rp-prof-brand .rp-brand-logo-wrap,.rp-prof-panel .rp-prof-brand .rp-brand-logo-wrap,.rp-prof-sidebar .rp-prof-brand .rp-brand-logo-wrap{background:transparent!important;background-color:transparent!important;background-image:none!important;border:0!important;box-shadow:none!important;outline:0!important;border-radius:0!important;padding:0!important;overflow:visible!important;width:96px!important;min-width:96px!important;height:62px!important;min-height:62px!important}.rp-prof-brand .rp-brand-logo,.rp-prof-sidebar .rp-prof-brand .rp-brand-logo-wrap img{background:transparent!important;border:0!important;box-shadow:none!important;border-radius:0!important;padding:0!important;width:96px!important;max-width:96px!important;height:auto!important;max-height:62px!important;object-fit:contain!important}
@media(max-width:760px){.rp-prof-panel:not(.rp-sidebar-expanded) .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand .rp-brand-logo-wrap{width:96px!important;min-width:96px!important;height:62px!important}.rp-prof-panel:not(.rp-sidebar-expanded) .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand .rp-brand-logo{width:96px!important;max-width:96px!important;height:auto!important;max-height:62px!important}}


/* v-logo-sidebar-chico-final: fuerza logo chico en sidebar profesional y evita versión grande/cortada */
@media (min-width:761px){
  .rp-prof-panel .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand{
    height:58px!important;
    min-height:58px!important;
    max-height:58px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    overflow:visible!important;
    padding:0!important;
  }
  .rp-prof-panel .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap,
  .rp-prof-panel .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand .rp-brand-logo-wrap,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand .rp-brand-logo-wrap{
    width:42px!important;
    height:42px!important;
    min-width:42px!important;
    max-width:42px!important;
    min-height:42px!important;
    max-height:42px!important;
    flex:0 0 42px!important;
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    background:transparent!important;
    border:0!important;
    border-radius:0!important;
    box-shadow:none!important;
    overflow:visible!important;
    margin:0 auto!important;
    padding:0!important;
  }
  .rp-prof-panel .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo,
  .rp-prof-panel .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap img,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap img{
    width:34px!important;
    height:34px!important;
    min-width:34px!important;
    max-width:34px!important;
    min-height:34px!important;
    max-height:34px!important;
    object-fit:contain!important;
    object-position:center!important;
    display:block!important;
    border-radius:0!important;
    margin:0 auto!important;
    padding:0!important;
    transform:none!important;
  }
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{
    display:none!important;
  }
}


/* v366.90 - Correcciones quirúrgicas: tour interactivo, administración mobile y dashboard sin cortes */
.rp-tour-card,
.rp-tour-card *{
  -webkit-text-fill-color:initial!important;
}
.rp-tour-actions .rp-tour-skip,
.rp-tour-actions .rp-tour-skip span{
  color:#102A56!important;
  background:#F3F7FB!important;
  border:1px solid #DCE6F2!important;
}
.rp-tour-actions .rp-tour-next,
.rp-tour-actions .rp-tour-next span,
.rp-tour-actions .rp-tour-next svg{
  color:#fff!important;
  -webkit-text-fill-color:#fff!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  border-color:#102A56!important;
  fill:none!important;
  stroke:currentColor!important;
}
.rp-tour-focus{
  position:relative!important;
  z-index:999998!important;
  outline:3px solid rgba(16,42,86,.45)!important;
  outline-offset:5px!important;
  box-shadow:0 0 0 7px rgba(16,42,86,.10)!important;
  border-radius:12px!important;
}
.rp-tour-pointer{
  position:fixed!important;
  z-index:1000000!important;
  display:inline-flex!important;
  align-items:center!important;
  gap:7px!important;
  padding:7px 10px!important;
  border-radius:999px!important;
  background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
  color:#fff!important;
  font-size:12px!important;
  font-weight:500!important;
  box-shadow:0 10px 28px rgba(16,42,86,.25)!important;
  pointer-events:none!important;
}
.rp-tour-pointer span{
  width:9px!important;
  height:9px!important;
  border-radius:999px!important;
  background:#fff!important;
  display:inline-block!important;
  animation:rpTourPulse 1s infinite ease-in-out!important;
}
@keyframes rpTourPulse{0%,100%{transform:scale(.8);opacity:.6}50%{transform:scale(1.35);opacity:1}}

.rp-prof-panel #inicio,
.rp-prof-panel .rp-dashboard-head,
.rp-prof-panel .rp-dashboard-title-row,
.rp-prof-panel .rp-next-dashboard-card,
.rp-prof-panel .rp-next-dashboard-card *,
.rp-prof-panel .rp-dashboard-kpis,
.rp-prof-panel .rp-dashboard-notifications-card{
  overflow:visible!important;
  max-height:none!important;
  white-space:normal!important;
  text-overflow:clip!important;
}
.rp-prof-panel .rp-dashboard-title-copy,
.rp-prof-panel .rp-dashboard-title-copy h1,
.rp-prof-panel .rp-dashboard-title-copy p,
.rp-prof-panel .rp-next-dashboard-card h2,
.rp-prof-panel .rp-next-dashboard-card p{
  overflow:visible!important;
  display:block!important;
  -webkit-line-clamp:unset!important;
  line-clamp:unset!important;
  word-break:normal!important;
}

body[class*="administracion"] .rp-kpi-grid,
body[class*="administracion"] .rp-plan-grid,
body[class*="administracion"] .rp-pricing-grid,
body[class*="administracion"] .rp-subscription-grid,
body[class*="administracion"] .rp-dashboard-kpis,
body[class*="administracion"] .rp-admin-plan-grid,
body[class*="administracion"] .rpmp-plan-grid,
body[class*="administracion"] .redpsico-plan-grid,
body.page .rp-kpi-grid[style*="repeat(4"],
body.page .rp-plan-grid,
body.page .rp-pricing-grid{
  min-width:0!important;
}
@media(max-width:760px){
  body[class*="administracion"] .rp-kpi-grid,
  body[class*="administracion"] .rp-plan-grid,
  body[class*="administracion"] .rp-pricing-grid,
  body[class*="administracion"] .rp-subscription-grid,
  body[class*="administracion"] .rp-admin-plan-grid,
  body[class*="administracion"] .rpmp-plan-grid,
  body[class*="administracion"] .redpsico-plan-grid,
  body.page .rp-kpi-grid[style*="repeat(4"],
  body.page .rp-plan-grid,
  body.page .rp-pricing-grid{
    display:grid!important;
    grid-template-columns:1fr!important;
    gap:12px!important;
    width:100%!important;
  }
  body[class*="administracion"] .rp-card,
  body[class*="administracion"] .rp-config-card,
  body[class*="administracion"] .rp-plan-card,
  body[class*="administracion"] .rp-pricing-card,
  body[class*="administracion"] .rp-admin-plan-card,
  body[class*="administracion"] .rpmp-plan-card,
  body[class*="administracion"] .redpsico-plan-card{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    padding:14px!important;
    border-radius:12px!important;
    overflow:visible!important;
  }
  body[class*="administracion"] .rp-form-grid,
  body[class*="administracion"] .rp-compact-form{
    grid-template-columns:1fr!important;
  }
  body[class*="administracion"] table{
    min-width:720px!important;
  }
  body[class*="administracion"] .rp-responsive-table{
    overflow-x:auto!important;
    -webkit-overflow-scrolling:touch!important;
  }
  .rp-tour-layer{bottom:12px!important;left:10px!important;right:10px!important;width:auto!important;}
  .rp-tour-actions{flex-wrap:wrap!important;justify-content:stretch!important;}
  .rp-tour-actions .rp-btn{flex:1 1 auto!important;min-width:128px!important;}
  .rp-tour-pointer{display:none!important;}
}

/* v331 - Mobile: campana Dashboard dentro del borde derecho */
@media (max-width: 720px){
  #inicio .rp-dashboard-title-row{
    overflow:visible!important;
    padding-right:12px!important;
    box-sizing:border-box!important;
  }
  #inicio .rp-dashboard-bell{
    position:relative!important;
    flex:0 0 auto!important;
    margin-right:16px!important;
    transform:translateX(-4px)!important;
    overflow:visible!important;
  }
  #inicio .rp-dashboard-bell-count{
    right:-6px!important;
    top:-8px!important;
    min-width:21px!important;
    height:21px!important;
    padding:0 5px!important;
    line-height:17px!important;
  }
}

/* ==========================================================
   RedPsico - Fondo general estilo SaaS (blindado)
   Solo afecta la hoja/fondo principal del panel profesional.
   No toca lógica, tarjetas, formularios ni navegación.
   ========================================================== */
.rp-prof-panel{
  --rp-bg:#f4f7ff!important;
  background:
    radial-gradient(circle at 88% 12%, rgba(123,145,255,.28) 0, rgba(123,145,255,.14) 22%, transparent 46%),
    radial-gradient(circle at 8% 92%, rgba(11,120,170,.16) 0, rgba(11,120,170,.08) 24%, transparent 48%),
    linear-gradient(135deg,#fbfcff 0%,#f3f7ff 42%,#edf3ff 100%)!important;
  position:relative!important;
  isolation:isolate!important;
}
.rp-prof-panel::before{
  content:""!important;
  position:absolute!important;
  inset:0!important;
  pointer-events:none!important;
  z-index:0!important;
  opacity:.62!important;
  background:
    radial-gradient(circle at 96% 28%, rgba(16,42,86,.08) 0 1.2px, transparent 1.4px),
    radial-gradient(circle at 4% 82%, rgba(16,42,86,.06) 0 1.1px, transparent 1.35px);
  background-size:18px 18px,20px 20px!important;
  mask-image:linear-gradient(90deg, transparent 0%, #000 10%, #000 90%, transparent 100%)!important;
}
.rp-prof-panel::after{
  content:""!important;
  position:absolute!important;
  inset:-18% -8% -18% -8%!important;
  pointer-events:none!important;
  z-index:0!important;
  opacity:.42!important;
  background:
    repeating-radial-gradient(circle at 100% 48%, transparent 0 42px, rgba(16,42,86,.13) 43px, transparent 44px),
    repeating-radial-gradient(circle at 0% 100%, transparent 0 52px, rgba(11,120,170,.09) 53px, transparent 54px)!important;
}
.rp-prof-sidebar,
.rp-prof-main{
  position:relative!important;
  z-index:1!important;
}
.rp-prof-main{
  background:transparent!important;
}
.rp-card,
.rp-list-card,
.rp-patient-card,
.rp-table-card,
.rp-calendar-shell,
.rp-detail-card,
.rp-detail-hero,
.rp-kpis div{
  background:rgba(255,255,255,.94)!important;
}
@media(max-width:760px){
  .rp-prof-panel{
    background:
      radial-gradient(circle at 92% 8%, rgba(123,145,255,.20) 0, rgba(123,145,255,.10) 24%, transparent 46%),
      radial-gradient(circle at 0% 96%, rgba(11,120,170,.12) 0, rgba(11,120,170,.06) 28%, transparent 50%),
      linear-gradient(135deg,#fbfcff 0%,#f4f7ff 48%,#eef4ff 100%)!important;
  }
  .rp-prof-panel::before{opacity:.36!important;background-size:22px 22px,24px 24px!important;}
  .rp-prof-panel::after{opacity:.26!important;inset:-28% -28% -18% -28%!important;}
}

/* v333 - Restaurar menú móvil sobre el nuevo fondo SaaS
   El fondo decorativo no puede tapar ni desplazar el header/menu móvil. */
@media (max-width: 980px){
  .rp-prof-panel,
  .rp-prof-panel.rp-sidebar-expanded{
    overflow:visible!important;
  }
  .rp-prof-panel::before,
  .rp-prof-panel::after{
    z-index:0!important;
    pointer-events:none!important;
  }
  .rp-prof-panel > *{
    position:relative!important;
    z-index:2!important;
  }
  .rp-prof-sidebar,
  .rp-prof-panel .rp-prof-sidebar,
  .rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar{
    display:flex!important;
    position:sticky!important;
    top:0!important;
    z-index:9999!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    color:#fff!important;
    visibility:visible!important;
    opacity:1!important;
    transform:none!important;
    pointer-events:auto!important;
  }
  .rp-prof-sidebar .rp-prof-brand{
    display:flex!important;
    align-items:center!important;
    width:100%!important;
    visibility:visible!important;
    opacity:1!important;
  }
  .rp-prof-sidebar .rp-sidebar-toggle,
  .rp-prof-panel .rp-sidebar-toggle{
    display:inline-flex!important;
    visibility:visible!important;
    opacity:1!important;
    margin-left:auto!important;
    color:#fff!important;
    z-index:10000!important;
  }
  .rp-prof-sidebar:not(.mobile-open) a{
    display:none!important;
  }
  .rp-prof-sidebar.mobile-open a{
    display:flex!important;
  }
}

/* v334 - FIX REAL menú móvil: el fondo SaaS no puede ocultar el header */
@media (max-width:760px){
  html body .rp-prof-panel,
  html body .rp-prof-panel.rp-sidebar-expanded{
    display:block!important;
    width:calc(100vw - 8px)!important;
    max-width:calc(100vw - 8px)!important;
    margin:0 auto!important;
    padding:0!important;
    overflow:visible!important;
    border-radius:18px!important;
    position:relative!important;
  }
  html body .rp-prof-panel > aside.rp-prof-sidebar:not(.mobile-open),
  html body aside.rp-prof-sidebar:not(.mobile-open){
    display:block!important;
    visibility:visible!important;
    opacity:1!important;
    position:relative!important;
    top:auto!important;
    left:auto!important;
    right:auto!important;
    bottom:auto!important;
    transform:none!important;
    z-index:99999!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    height:96px!important;
    min-height:96px!important;
    max-height:none!important;
    margin:0!important;
    padding:12px 18px!important;
    box-sizing:border-box!important;
    border:0!important;
    border-radius:18px 18px 0 0!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    color:#fff!important;
    overflow:hidden!important;
    pointer-events:auto!important;
  }
  html body .rp-prof-panel > aside.rp-prof-sidebar:not(.mobile-open) .rp-prof-brand,
  html body aside.rp-prof-sidebar:not(.mobile-open) .rp-prof-brand{
    display:grid!important;
    grid-template-columns:72px minmax(0,1fr) 48px!important;
    align-items:center!important;
    gap:10px!important;
    width:100%!important;
    height:72px!important;
    min-height:72px!important;
    max-height:72px!important;
    margin:0!important;
    padding:0 0 10px!important;
    border-bottom:1px solid rgba(255,255,255,.14)!important;
    background:transparent!important;
    overflow:visible!important;
    position:relative!important;
    transform:none!important;
  }
  html body aside.rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap,
  html body aside.rp-prof-sidebar:not(.mobile-open) .rp-brand-logo-wrap img,
  html body aside.rp-prof-sidebar:not(.mobile-open) .rp-brand-logo{
    display:block!important;
    grid-column:1!important;
    justify-self:start!important;
    align-self:center!important;
    width:66px!important;
    max-width:66px!important;
    min-width:66px!important;
    height:66px!important;
    max-height:66px!important;
    min-height:66px!important;
    object-fit:contain!important;
    background:transparent!important;
    border:0!important;
    box-shadow:none!important;
    border-radius:0!important;
    margin:0!important;
    padding:0!important;
    position:static!important;
    transform:none!important;
    opacity:1!important;
    visibility:visible!important;
  }
  html body aside.rp-prof-sidebar:not(.mobile-open) .rp-prof-brand strong{
    display:block!important;
    grid-column:2!important;
    justify-self:center!important;
    align-self:center!important;
    opacity:1!important;
    visibility:visible!important;
    width:auto!important;
    max-width:100%!important;
    min-width:0!important;
    margin:0!important;
    padding:0!important;
    color:#fff!important;
    font-size:18px!important;
    line-height:1.1!important;
    font-weight:400!important;
    text-align:center!important;
    white-space:nowrap!important;
    overflow:hidden!important;
    text-overflow:ellipsis!important;
    position:static!important;
    transform:none!important;
  }
  html body aside.rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle{
    display:grid!important;
    grid-column:3!important;
    justify-self:end!important;
    align-self:center!important;
    place-items:center!important;
    visibility:visible!important;
    opacity:1!important;
    width:48px!important;
    height:48px!important;
    min-width:48px!important;
    min-height:48px!important;
    margin:0!important;
    padding:0!important;
    border:0!important;
    border-radius:10px!important;
    background:transparent!important;
    color:#fff!important;
    box-shadow:none!important;
    position:static!important;
    transform:none!important;
    cursor:pointer!important;
    pointer-events:auto!important;
    font-size:0!important;
    line-height:1!important;
  }
  html body aside.rp-prof-sidebar:not(.mobile-open) .rp-sidebar-toggle::before{
    content:'☰'!important;
    display:block!important;
    color:#fff!important;
    font-size:31px!important;
    line-height:1!important;
    font-weight:400!important;
  }
  html body aside.rp-prof-sidebar:not(.mobile-open) a{display:none!important;}
  html body .rp-prof-main{
    position:relative!important;
    z-index:2!important;
    padding-top:18px!important;
  }
  html body aside.rp-prof-sidebar.mobile-open,
  html body .rp-prof-panel > aside.rp-prof-sidebar.mobile-open{
    display:block!important;
    visibility:visible!important;
    opacity:1!important;
    position:fixed!important;
    inset:0!important;
    z-index:999999!important;
    width:100vw!important;
    max-width:none!important;
    height:100dvh!important;
    min-height:100dvh!important;
    padding:calc(12px + env(safe-area-inset-top)) 18px calc(18px + env(safe-area-inset-bottom))!important;
    background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;
    color:#fff!important;
    overflow-y:auto!important;
    border:0!important;
    border-radius:0!important;
  }
  html body aside.rp-prof-sidebar.mobile-open a{display:flex!important;}
}

/* v335 - Mobile frame fix: encuadre + sin rebote horizontal
   Mantiene el fondo SaaS, pero evita que el pseudo-fondo y el ancho 100vw
   generen desplazamiento/rebote lateral en iPhone. No toca lógica. */
@media (max-width:760px){
  html,
  body{
    max-width:100%!important;
    overflow-x:hidden!important;
  }
  html body .rp-prof-panel,
  html body .rp-prof-panel.rp-sidebar-expanded{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    margin:0!important;
    padding:0!important;
    box-sizing:border-box!important;
    overflow-x:hidden!important;
    overflow-y:visible!important;
    overscroll-behavior-x:none!important;
    border-radius:18px!important;
  }
  html body .rp-prof-panel::before,
  html body .rp-prof-panel::after{
    inset:0!important;
    width:100%!important;
    max-width:100%!important;
    overflow:hidden!important;
    transform:none!important;
  }
  html body .rp-prof-main{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    margin:0!important;
    padding-left:0!important;
    padding-right:0!important;
    box-sizing:border-box!important;
    overflow-x:hidden!important;
  }
  html body .rp-prof-content,
  html body .rp-dashboard,
  html body .rp-section,
  html body .rp-card,
  html body .rp-list-card,
  html body .rp-table-card,
  html body .rp-calendar-shell,
  html body .rp-detail-card,
  html body .rp-detail-hero{
    max-width:100%!important;
    box-sizing:border-box!important;
  }
  html body .rp-prof-panel > aside.rp-prof-sidebar:not(.mobile-open),
  html body aside.rp-prof-sidebar:not(.mobile-open){
    width:100%!important;
    max-width:100%!important;
    left:0!important;
    right:0!important;
    box-sizing:border-box!important;
    overflow:hidden!important;
  }
  html body aside.rp-prof-sidebar.mobile-open,
  html body .rp-prof-panel > aside.rp-prof-sidebar.mobile-open{
    overflow-x:hidden!important;
    overscroll-behavior:contain!important;
  }
}

/* v338 - AJUSTE QUIRURGICO: centrado real mobile sin tocar scroll/menu/logica
   Base: v335 que mantenia el scroll correcto. Solo compensa el wrapper unos px
   hacia la izquierda porque el contenedor del tema/iOS lo estaba dejando corrido. */
@media (max-width:760px){
  html, body{
    overflow-x:hidden!important;
    max-width:100%!important;
  }
  html body .rp-prof-panel,
  html body .rp-prof-panel.rp-sidebar-expanded{
    position:relative!important;
    left:-10px!important;
    right:auto!important;
    transform:none!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    margin-top:0!important;
    margin-bottom:0!important;
    margin-left:0!important;
    margin-right:0!important;
    padding:0!important;
    box-sizing:border-box!important;
    overflow-x:hidden!important;
    overscroll-behavior-x:none!important;
  }
  html body .rp-prof-main,
  html body .rp-prof-content{
    position:relative!important;
    left:0!important;
    right:auto!important;
    transform:none!important;
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    margin-left:0!important;
    margin-right:0!important;
    box-sizing:border-box!important;
    overflow-x:hidden!important;
  }
  html body .rp-prof-panel > aside.rp-prof-sidebar:not(.mobile-open),
  html body aside.rp-prof-sidebar:not(.mobile-open){
    left:0!important;
    right:auto!important;
    transform:none!important;
    width:100%!important;
    max-width:100%!important;
    box-sizing:border-box!important;
  }
}

/* v343 - Agenda interactiva: acciones visibles en detalle de turno y actividad bloqueada.
   Corrección quirúrgica: solo afecta botones dentro del popup de agenda. */
html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-actions{
  display:flex!important;
  flex-direction:column!important;
  gap:12px!important;
  width:100%!important;
  max-width:100%!important;
  margin-top:18px!important;
  box-sizing:border-box!important;
}
html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-actions .rp-agenda-popup-action,
html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-actions a.rp-agenda-popup-action,
html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-actions button.rp-agenda-popup-action{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:10px!important;
  width:100%!important;
  min-height:56px!important;
  padding:13px 18px!important;
  border-radius:18px!important;
  box-sizing:border-box!important;
  font-size:16px!important;
  font-weight:800!important;
  line-height:1.15!important;
  opacity:1!important;
  visibility:visible!important;
  text-decoration:none!important;
  text-indent:0!important;
  overflow:visible!important;
}
html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-actions .rp-btn-light.rp-agenda-popup-action,
html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-actions a.rp-btn-light.rp-agenda-popup-action{
  background:#ffffff!important;
  background-color:#ffffff!important;
  border:2px solid #102A56!important;
  color:#102A56!important;
  -webkit-text-fill-color:#102A56!important;
}
html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-actions .rp-btn-danger.rp-agenda-popup-action,
html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-actions button.rp-btn-danger.rp-agenda-popup-action{
  background:#c92520!important;
  background-color:#c92520!important;
  border:2px solid #c92520!important;
  color:#ffffff!important;
  -webkit-text-fill-color:#ffffff!important;
}
html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-actions .rp-agenda-popup-action span{
  display:inline!important;
  color:inherit!important;
  -webkit-text-fill-color:inherit!important;
  opacity:1!important;
  visibility:visible!important;
  font:inherit!important;
  line-height:inherit!important;
}
html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-actions .rp-agenda-popup-action svg,
html body .rp-agenda-popup-layer:not([hidden]) .rp-agenda-popup-actions .rp-agenda-popup-action .rp-agenda-popup-svg{
  width:22px!important;
  height:22px!important;
  min-width:22px!important;
  display:inline-block!important;
  opacity:1!important;
  visibility:visible!important;
  color:inherit!important;
  stroke:currentColor!important;
  fill:none!important;
}

/* v344 - ajuste quirurgico: contador proximo paciente sin borde y fondo degrade suave */
.rp-prof-panel #inicio .rp-next-dashboard-card .rp-next-countdown,
.rp-prof-panel #inicio .rp-next-countdown{
  border:0!important;
  background:linear-gradient(135deg,#EAF4FF 0%,#F6FAFF 45%,#FFFFFF 100%)!important;
  background-image:linear-gradient(135deg,#EAF4FF 0%,#F6FAFF 45%,#FFFFFF 100%)!important;
  box-shadow:none!important;
}


/* PuenteSalud v361: definición canónica del menú profesional */
.rp-prof-sidebar,
.rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar,
.rp-prof-sidebar.mobile-open,
body>.rp-prof-sidebar.mobile-open{background:linear-gradient(180deg,#E53935 0%,#E23B57 42%,#D92E72 72%,#6A4CFF 100%)!important;background-color:#E53935!important;color:#fff!important}
.rp-prof-sidebar a,.rp-prof-sidebar .rp-nav-icon,.rp-prof-sidebar .rp-nav-label,.rp-prof-sidebar .rp-prof-brand strong{color:#fff!important;-webkit-text-fill-color:#fff!important}
.rp-prof-sidebar a svg,.rp-prof-sidebar .rp-nav-icon svg{stroke:#fff!important;fill:none!important}
.rp-prof-sidebar a.active,.rp-prof-sidebar a:hover,.rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar a.active,.rp-prof-panel.rp-sidebar-expanded .rp-prof-sidebar a:hover{background:rgba(255,255,255,.18)!important;color:#fff!important;box-shadow:none!important}
.rp-prof-sidebar .rp-brand-logo-wrap,.rp-prof-sidebar .rp-brand-logo-wrap *{background:transparent!important;border:0!important;box-shadow:none!important}


/* PuenteSalud v364: ajuste final y único del número del contador */
html body .rp-prof-panel #inicio .rp-next-dashboard-card .rp-next-countdown strong[data-rp-countdown-value],
html body .rp-prof-panel #inicio .rp-next-countdown strong[data-rp-countdown-value]{
  color:#111827!important;
  -webkit-text-fill-color:#111827!important;
}
