:root {
    --bg-page: #f3f4f8;
    --bg-panel: #ffffff;
    --bg-soft: #f8fafc;
    --bg-muted: #f8f7fc;

    --text-main: #1f2937;
    --text-soft: #6b7280;
    --text-muted: #4b5563;

    --border: #e5e7eb;
    --border-soft: #ececf2;

    --primary: #5b21b6;
    --primary-hover: #4c1d95;
    --primary-ring: rgba(109, 40, 217, 0.15);

    --shadow-panel: 0 10px 30px rgba(0, 0, 0, 0.06);
    --shadow-soft: 0 1px 2px rgba(0, 0, 0, 0.08);
    --shadow-toast: 0 10px 30px rgba(0, 0, 0, 0.18);

    --radius-panel: 18px;
    --radius-card: 14px;
    --radius-input: 12px;
    --radius-pill: 999px;

    --success-bg: #16a34a;
    --error-bg: #dc2626;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Arial, sans-serif;
    background: var(--bg-page);
    color: var(--text-main);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    max-width: 1200px;
    width: 92%;
    margin: 28px auto 40px;
}
/* =========================
   HEADER GLOBAL
========================= */

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: #ffffff;
    border-bottom: 1px solid #e5e7eb;
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
}

.site-header .container {
    width: min(1320px, 92%);
    margin: 0 auto;
}

.site-header__inner {
    min-height: 58px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding-top: 0.2rem;
    padding-bottom: 0.2rem;
}

.site-brand {
    display: flex;
    flex-direction: column;
    gap: 0.05rem;
}

.site-brand__title {
    font-size: 1.05rem;
    font-weight: 700;
    color: #111827;
    line-height: 1;
}

.site-brand__subtitle {
    font-size: 0.8rem;
    color: #6b7280;
    line-height: 1.1;
}

.site-header__actions {
    justify-content: flex-end;
    gap: 6px;
    min-width: 0;
    flex-wrap: nowrap;
}

.site-link {
    text-decoration: none;
    color: #475569;
    padding: 0.55rem 0.95rem;
    border-radius: 10px;
    font-weight: 700;
    font-size: 0.92rem;
    transition: 0.2s ease;
}

.site-link:hover {
    background: #f3f4f6;
    color: #111827;
}

.site-link.is-active {
    background: #111827;
    color: #fff;
}

/* =========================
   PANEL BASE
========================= */

.panel {
    background: var(--bg-panel);
    border-radius: var(--radius-panel);
    padding: 22px;
    box-shadow: var(--shadow-panel);
    margin-bottom: 24px;
}

/* =========================
   HERO
========================= */

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 24px;
}

.page-header h1 {
    margin: 0 0 8px;
    font-size: 32px;
    line-height: 1.1;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.page-header p {
    margin: 0;
    color: var(--text-soft);
    font-size: 15px;
    line-height: 1.4;
}

.dashboard-hero {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
    padding: 28px;
    background: linear-gradient(135deg, #ffffff 0%, #f7f4ff 100%);
    border: 1px solid var(--border-soft);
}

.dashboard-hero__content h1 {
    margin: 8px 0 10px;
    font-size: 34px;
    font-weight: 800;
    letter-spacing: -0.03em;
}

.dashboard-hero__content p {
    margin: 0;
    max-width: 680px;
    color: var(--text-soft);
    font-size: 15px;
    line-height: 1.5;
}

.dashboard-label {
    display: inline-block;
    padding: 7px 12px;
    border-radius: var(--radius-pill);
    background: #ede9fe;
    color: #5b21b6;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-transform: uppercase;
}

.dashboard-hero__actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-shrink: 0;
}

/* =========================
   STATS
========================= */

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
    margin-bottom: 24px;
}

.stat-card {
    background: #ffffff;
    border-radius: 18px;
    padding: 20px;
    box-shadow: var(--shadow-panel);
    border: 1px solid var(--border-soft);
}

.stat-card__label {
    display: inline-block;
    margin-bottom: 10px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-soft);
}

.stat-card strong {
    display: block;
    font-size: 30px;
    line-height: 1;
    margin-bottom: 8px;
    letter-spacing: -0.03em;
    color: var(--text-main);
}

.stat-card small {
    color: var(--text-soft);
    font-size: 13px;
    line-height: 1.4;
}

/* =========================
   HEADERS
========================= */

.table-header,
.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    margin-bottom: 18px;
}

.table-header h2,
.modal-header h2,
.form-section h3,
.detail-section h3 {
    margin: 0;
}

.table-header h2 {
    font-size: 22px;
    font-weight: 800;
    letter-spacing: -0.02em;
}

#totalRecords {
    color: var(--text-muted);
    font-weight: 600;
}

/* =========================
   FORMS / INPUTS
========================= */

.form-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.field-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.field-group-full {
    grid-column: 1 / -1;
}

label,
.field-group label {
    font-weight: 500;
    font-size: 12px;
    color: var(--text-soft);
}

input,
select,
textarea {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #d1d5db;
    border-radius: var(--radius-input);
    font-size: 14px;
    background: #fff;
    color: var(--text-main);
    transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.field-group input,
.field-group select {
    height: 38px;
    padding: 6px 10px;
    font-size: 14px;
}

input[type="date"],
input[type="month"] {
    padding: 5px 8px;
}

textarea {
    resize: vertical;
    min-height: 96px;
}

input::placeholder,
textarea::placeholder {
    color: #9ca3af;
}

input:hover,
select:hover,
textarea:hover {
    border-color: #c7cdd8;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: #8b5cf6;
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.12);
}

/* =========================
   INPUT ICON
========================= */

.input-icon {
    position: relative;
}

.input-icon input {
    width: 100%;
    padding-left: 34px;
}

.input-icon__icon {
    position: absolute;
    left: 10px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 14px;
    opacity: 0.6;
}

/* =========================
   BUTTONS
========================= */

.btn-primary,
.btn-secondary,
.btn-close,
.btn-action {
    border: none;
    cursor: pointer;
    font-weight: 700;
    transition: all 0.18s ease;
}

.btn-primary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: var(--primary);
    color: white;
    padding: 12px 18px;
    border-radius: 12px;
    box-shadow: 0 6px 16px rgba(91, 33, 182, 0.18);
}

.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-secondary {
    background: #eef0f4;
    color: #1f2937;
    padding: 12px 18px;
    border-radius: 12px;
}

.btn-secondary:hover {
    background: #e2e8f0;
    color: #111827;
    transform: translateY(-1px);
}

.btn-close {
    width: 42px;
    height: 42px;
    font-size: 24px;
    border-radius: 12px;
    background: #f3f4f6;
    color: #111827;
    flex-shrink: 0;
}

.btn-close:hover {
    background: #e5e7eb;
    color: #111827;
    transform: scale(1.05);
}

.actions-group {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.btn-action {
    border-radius: 10px;
    padding: 8px 12px;
    font-size: 13px;
}

.btn-view {
    background: #e0e7ff;
    color: #3730a3;
}

.btn-view:hover {
    background: #c7d2fe;
}

.detail-actions-top {
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn-edit {
    background: #dbeafe;
    color: #1d4ed8;
}

.btn-edit:hover {
    background: #bfdbfe;
    color: #1e3a8a;
}

.btn-delete {
    background: #fee2e2;
    color: #b91c1c;
}

.btn-delete:hover {
    background: #fecaca;
    color: #991b1b;
}

/* =========================================================
   TABLA DE REGISTROS - DISEÑO ADAPTABLE
========================================================= */

.table-panel {
    overflow: visible;
}

.table-header-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    flex-wrap: wrap;
}

.page-size-control {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: #475467;
    font-size: 12px;
    font-weight: 700;
}

.page-size-control select {
    width: 72px;
    height: 36px;
    padding: 5px 28px 5px 10px;
    border-color: #d8dee8;
    background-color: #fff;
}

.table-scroll-top {
    width: 100%;
    height: 15px;
    margin-bottom: 7px;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: thin;
    scrollbar-color: #98a2b3 #eef1f5;
}

.table-scroll-top > div {
    height: 1px;
}

.table-scroll-top::-webkit-scrollbar {
    height: 10px;
}

.table-scroll-top::-webkit-scrollbar-track {
    background: #eef1f5;
    border-radius: 999px;
}

.table-scroll-top::-webkit-scrollbar-thumb {
    background: #98a2b3;
    border-radius: 999px;
}


/* CONTENEDOR */

.table-panel .table-wrapper {
    width: 100%;
    overflow-x: auto;
    overflow-y: hidden;

    border: 1px solid #e8ecf1;
    border-radius: 14px;

    background: #ffffff;

    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 transparent;
}

.table-panel .table-wrapper::-webkit-scrollbar {
    height: 7px;
}

.table-panel .table-wrapper::-webkit-scrollbar-track {
    background: transparent;
}

.table-panel .table-wrapper::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 999px;
}


/* =========================================================
   TABLA
========================================================= */

.table-panel .records-table {
    width: 100%;

    /* IMPORTANTE:
       Ya no obligamos a que siempre mida 1100px */
    min-width: 100%;

    border-collapse: separate;
    border-spacing: 0;

    background: #ffffff;
}


/* CELDAS */

.table-panel .records-table th,
.table-panel .records-table td {
    padding: 13px 14px;

    text-align: left;
    vertical-align: middle;

    border-bottom: 1px solid #edf0f4;

    color: #344054;

    font-size: 13px;
    line-height: 1.35;
}


/* =========================================================
   CABECERA
========================================================= */

.table-panel .records-table th {
    position: sticky;
    top: 0;
    z-index: 2;

    background: #f8f7fc;

    color: #475467;

    font-size: 11px;
    font-weight: 800;

    letter-spacing: 0.015em;

    white-space: nowrap;
}


/* =========================================================
   FILAS
========================================================= */

.table-panel .records-table tbody tr {
    background: #ffffff;

    transition:
        background 0.15s ease,
        box-shadow 0.15s ease;
}

.table-panel .records-table tbody tr:hover {
    background: #faf9fc;
}


/* Elimina línea de la última fila */

.table-panel .records-table tbody tr:last-child td {
    border-bottom: 0;
}


/* =========================================================
   COLUMNAS DE TABLA - POR NOMBRE, NO POR POSICIÓN
========================================================= */

/* FECHA CONTACTO */
.table-panel .records-table th[data-column="fecha_contacto"],
.table-panel .records-table td[data-column="fecha_contacto"] {
    width: 112px;
    min-width: 112px;
    white-space: nowrap;
}

/* PACIENTE */
.table-panel .records-table th[data-column="paciente"],
.table-panel .records-table td[data-column="paciente"] {
    min-width: 170px;
}

.table-panel .records-table td[data-column="paciente"] {
    color: #172033;
    font-weight: 700;
}

/* TELÉFONO */
.table-panel .records-table th[data-column="telefono"],
.table-panel .records-table td[data-column="telefono"] {
    width: 125px;
    min-width: 125px;
    white-space: nowrap;
}

/* DNI */
.table-panel .records-table th[data-column="dni"],
.table-panel .records-table td[data-column="dni"] {
    width: 100px;
    min-width: 100px;
    white-space: nowrap;
}

/* CANAL */
.table-panel .records-table th[data-column="canal"],
.table-panel .records-table td[data-column="canal"] {
    min-width: 115px;
}

/* TIPO DE ATENCIÓN */
.table-panel .records-table th[data-column="tipo_atencion"],
.table-panel .records-table td[data-column="tipo_atencion"] {
    min-width: 135px;
    max-width: 175px;
}

/* SERVICIO */
.table-panel .records-table th[data-column="servicio"],
.table-panel .records-table td[data-column="servicio"] {
    min-width: 130px;
    max-width: 170px;
}

/* DETALLE CONSULTA */
.table-panel .records-table th[data-column="detalle_consulta"],
.table-panel .records-table td[data-column="detalle_consulta"] {
    min-width: 170px;
    max-width: 230px;
}

/* STATUS */
.table-panel .records-table th[data-column="status_cita"],
.table-panel .records-table td[data-column="status_cita"] {
    min-width: 125px;
    white-space: nowrap;
}

/* FECHA CITA */
.table-panel .records-table th[data-column="fecha_cita"],
.table-panel .records-table td[data-column="fecha_cita"] {
    width: 110px;
    min-width: 110px;
    white-space: nowrap;
}

/* ACCIONES */
.table-panel .records-table th[data-column="acciones"],
.table-panel .records-table td[data-column="acciones"] {
    width: 82px;
    min-width: 82px;
    text-align: center;
    white-space: nowrap;
}

.table-panel .records-table .actions-group {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    flex-wrap: nowrap;
}

.table-panel .records-table .btn-view {
    min-width: 54px;
    padding: 7px 11px;
    font-size: 11px;
    font-weight: 750;
    border-radius: 8px;
}


/* =========================================================
   BADGES
========================================================= */

.table-panel .records-table .badge,
.table-panel .records-table .canal-badge,
.table-panel .records-table .servicio-badge {
    display: inline-flex;

    align-items: center;
    justify-content: center;

    min-height: 25px;

    padding: 5px 9px;

    white-space: nowrap;

    font-size: 11px;
}


/* =========================================================
   SIN REGISTROS
========================================================= */

.table-panel .empty-row td {
    padding: 36px 16px;

    text-align: center;

    color: #667085;

    font-size: 13px;
}


/* =========================================================
   COLUMNAS OCULTAS
========================================================= */

.table-panel .records-table .column-hidden {
    display: none !important;
}


/* =========================================================
   RESPONSIVE
========================================================= */

@media (max-width: 760px) {

    .table-panel .records-table {
        width: max-content;
        min-width: 100%;
    }

    .table-panel .records-table th,
    .table-panel .records-table td {
        padding: 12px 11px;
    }
}

/* =========================
   MODALS
========================= */

.modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.modal.hidden {
    display: none;
}


.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.35);
    backdrop-filter: blur(2px);
    z-index: 1;
}

.modal-dialog {
    position: relative;
    z-index: 2;
    width: min(720px, 100%);
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.18);
    overflow: hidden;
}

.modal-content {
    position: relative;
    width: min(1100px, 94%);
    max-height: 90vh;
    overflow-y: auto;
    margin: 32px auto;
    background: white;
    border-radius: 20px;
    padding: 24px;
    z-index: 2;
    box-shadow: 0 18px 50px rgba(15, 23, 42, 0.18);
}

.form-layout {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.form-section {
    border: 1px solid var(--border-soft);
    border-radius: 16px;
    padding: 20px;
    background: #fff;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.hidden {
    display: none;
}

/* =========================
   DETAIL
========================= */

.detail-layout {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.detail-section {
    border: 1px solid var(--border-soft);
    border-radius: 16px;
    padding: 18px;
    background: #fff;
}

.detail-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px 18px;
}

.detail-item {
    background: #f9fafb;
    border-radius: 12px;
    padding: 12px 14px;
    min-height: 60px;
}

.detail-item strong {
    display: block;
    font-size: 12px;
    color: var(--text-soft);
    margin-bottom: 6px;
    font-weight: 700;
}

/* =========================
   BADGES STATUS
========================= */

.badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
}

.badge-primary {
    background: #ede9fe;
    color: #5b21b6;
}

.badge-success {
    background: #dcfce7;
    color: #166534;
}

.badge-neutral {
    background: #e5e7eb;
    color: #374151;
}

.badge-confirmado {
    background: #d1fae5;
    color: #065f46;
}

.badge-no-confirmado {
    background: #e9d5ff;
    color: #6b21a8;
}

.badge-cancelo {
    background: #fecaca;
    color: #991b1b;
}

.badge-reprogramo {
    background: #dbeafe;
    color: #1e3a8a;
}

.badge-por-confirmar {
    background: #fef3c7;
    color: #92400e;
}

.badge-no-asistio {
    background: #fed7aa;
    color: #9a3412;
}

/* =========================
   BADGES CANAL
========================= */

.canal-badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: var(--radius-pill);
    font-size: 12px;
    font-weight: 600;
    line-height: 1;
    box-shadow: var(--shadow-soft);
}

.canal-default {
    background: #e5e7eb;
    color: #374151;
}

.canal-redes {
    background: #dbeafe;
    color: #1d4ed8;
}

.canal-web {
    background: #fecaca;
    color: #b91c1c;
}

.canal-whatsapp {
    background: #d9f99d;
    color: #166534;
}

.canal-fachada {
    background: #e9d5ff;
    color: #6b21a8;
}

.canal-referido {
    background: #cfeff7;
    color: #155e75;
}

.canal-seguimiento {
    background: #fde68a;
    color: #92400e;
}

.canal-interno {
    background: #fed7aa;
    color: #9a3412;
}

/* =========================
   QUICK DATE FILTER
========================= */

.quick-dates {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 6px;
}

.quick-btn {
    padding: 6px 10px;
    border-radius: 8px;
    border: 1px solid #e5e7eb;
    background: #f9fafb;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.quick-btn.active {
    background: #5b21b6;
    color: white;
    border-color: #5b21b6;
}

.quick-btn:hover {
    background: #ede9fe;
    color: #5b21b6;
    border-color: #ddd6fe;
}

.quick-btn.clear:hover {
    background: #fee2e2;
    color: #b91c1c;
}

.date-range {
    display: flex;
    align-items: center;
    gap: 6px;
}

.date-separator {
    font-weight: bold;
    color: #6b7280;
}

/* =========================================================
   FILTROS - DISEÑO FUNCIONAL
========================================================= */

.filters-shell {
    padding: 16px 18px;
}


/* CABECERA */

.filters-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;

    padding: 10px 12px;

    background: #f8fafc;

    border: 1px solid #e5e7eb;
    border-radius: 13px;
}

.filters-toolbar__left {
    display: flex;
    align-items: center;
    gap: 12px;

    min-width: 0;
}


/* BOTÓN FILTROS */

.filters-toggle-btn {
    flex-shrink: 0;

    min-width: 100px;
    min-height: 38px;

    padding: 8px 15px;

    background: #f4f3ff;
    color: #5925dc;

    border: 1px solid #d9d6fe;
    border-radius: 10px;

    font-size: 13px;
    font-weight: 700;
}

.filters-toggle-btn:hover {
    background: #ebe9fe;
    color: #4a1fb8;
}


/* RESUMEN */

.filters-summary {
    display: inline-flex;
    align-items: center;

    min-height: 34px;

    padding: 6px 11px;

    background: #ffffff;

    border: 1px solid #e4e7ec;
    border-radius: 9px;

    color: #667085;

    font-size: 12px;
    font-weight: 500;

    line-height: 1.3;

    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}


/* LIMPIAR GENERAL */

.filters-clear-btn {
    flex-shrink: 0;

    min-height: 38px;

    padding: 8px 14px;

    background: #ffffff;

    border: 1px dashed #cfd8e3;
    border-radius: 10px;

    color: #64748b;

    font-size: 12px;
    font-weight: 700;
}

.filters-clear-btn:hover {
    background: #fff1f2;

    border-color: #fda4af;

    color: #9f1239;
}


/* PANEL */

.filters-panel {
    margin-top: 14px;
    padding-top: 16px;

    border-top: 1px solid #e5e7eb;
}

.filters-panel.hidden {
    display: none;
}


/* =========================================================
   FILA PRINCIPAL
========================================================= */

.filters-main-grid {
    display: grid;

    grid-template-columns:
        minmax(260px, 1.7fr)
        minmax(150px, 0.85fr)
        minmax(170px, 0.9fr)
        minmax(170px, 0.9fr);

    gap: 14px 18px;

    align-items: end;
}


/* =========================================================
   SEGUNDA FILA
========================================================= */

.filters-secondary-grid {
    display: grid;

    grid-template-columns:
        minmax(170px, 0.9fr)
        minmax(290px, 1.45fr)
        minmax(155px, 0.8fr)
        minmax(155px, 0.8fr);

    gap: 14px 18px;

    align-items: end;

    margin-top: 16px;

    padding-top: 16px;

    border-top: 1px solid #eef2f6;
}


/* LABELS */

.filters-panel .field-group {
    gap: 6px;
}

.filters-panel .field-group label {
    color: #475467;

    font-size: 11px;
    font-weight: 700;
}


/* INPUTS / SELECTS */

.filters-panel input,
.filters-panel select {
    height: 40px;

    padding: 0 11px;

    border: 1px solid #d0d5dd;
    border-radius: 10px;

    background: #ffffff;

    color: #344054;

    font-size: 13px;
}

.filters-panel input:hover,
.filters-panel select:hover {
    border-color: #98a2b3;
}

.filters-panel input:focus,
.filters-panel select:focus {
    border-color: #8b1023;

    box-shadow:
        0 0 0 3px rgba(139, 16, 35, 0.09);
}


/* BUSCADOR */

.filters-panel .input-icon {
    position: relative;
}

.filters-panel .input-icon input {
    padding-left: 36px;
}

.filters-panel .input-icon__icon {
    left: 11px;

    font-size: 13px;

    opacity: 0.55;
}


/* =========================================================
   FECHAS RÁPIDAS
========================================================= */

.filters-panel .quick-dates {
    display: flex;
    align-items: center;

    gap: 6px;

    margin: 0;

    min-height: 40px;
}

.filters-panel .quick-btn {
    min-height: 32px;

    padding: 6px 10px;

    background: #ffffff;

    border: 1px solid #d0d5dd;
    border-radius: 8px;

    color: #475467;

    font-size: 11px;
    font-weight: 700;

    white-space: nowrap;
}

.filters-panel .quick-btn:hover {
    background: #f4f3ff;

    border-color: #d9d6fe;

    color: #5925dc;
}

.filters-panel .quick-btn.active {
    background: #8b1023;

    border-color: #8b1023;

    color: #ffffff;
}


/* Ya no usamos el antiguo separador de fechas */

.date-range,
.date-separator {
    display: none;
}


/* =========================================================
   RESPONSIVE
========================================================= */

@media (max-width: 1100px) {

    .filters-main-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }

    .filters-secondary-grid {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }

    .filter-search {
        grid-column: 1 / -1;
    }
}


@media (max-width: 640px) {

    .filters-shell {
        padding: 14px;
    }

    .filters-toolbar {
        align-items: stretch;
    }

    .filters-toolbar__left {
        flex: 1;

        flex-wrap: wrap;
    }

    .filters-summary {
        max-width: 100%;
    }

    .filters-main-grid,
    .filters-secondary-grid {
        grid-template-columns: 1fr;
    }

    .filter-search {
        grid-column: auto;
    }

    .filters-panel .quick-dates {
        flex-wrap: wrap;
    }

    .filters-clear-btn {
        align-self: flex-start;
    }
}

/* =========================
   TOAST
========================= */

.toast {
    position: fixed;
    top: 20px;
    left: 50%;
    min-width: 280px;
    max-width: 420px;
    padding: 14px 18px;
    border-radius: 14px;
    color: white;
    font-weight: 700;
    box-shadow: var(--shadow-toast);
    z-index: 2000;
    text-align: center;
    transform: translate(-50%, -10px);
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.toast:not(.hidden) {
    transform: translate(-50%, 0);
    opacity: 1;
}

.toast-success {
    background: var(--success-bg);
}

.toast-error {
    background: var(--error-bg);
}

.toast.hidden {
    display: none;
}

/* =========================
   RESPONSIVE
========================= */

@media (max-width: 1100px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .dashboard-hero {
        flex-direction: column;
        align-items: flex-start;
    }

    .dashboard-hero__actions {
        width: 100%;
        justify-content: flex-start;
    }
}

@media (max-width: 960px) {
    .filters-grid,
    .form-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 640px) {
    .page-header,
    .table-header,
    .modal-header,
    .form-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .filters-grid,
    .form-grid,
    .detail-grid,
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .modal-content {
        margin: 16px auto;
        padding: 18px;
    }

    .dashboard-hero {
        padding: 22px;
    }

    .dashboard-hero__content h1 {
        font-size: 28px;
    }

    .detail-actions-top {
        flex-wrap: wrap;
        justify-content: flex-start;
    }

    .toast {
        width: calc(100% - 24px);
        min-width: unset;
        max-width: unset;
    }

    .site-header__inner {
        flex-direction: column;
        align-items: flex-start;
        padding-top: 0.8rem;
        padding-bottom: 0.8rem;
    }

    .site-header__actions {
        width: 100%;
        flex-wrap: wrap;
    }
}

.table-actions button {
    min-width: 70px;
}

.btn-danger {
    background: #ef4444;
    color: white;
}

.input-error {
    border-color: #dc2626 !important;
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.12) !important;
}

.field-error {
    margin-top: 4px;
    font-size: 12px;
    color: #b91c1c;
    font-weight: 600;
}

.export-dropdown {
    position: relative;
}

.export-trigger {
    background: transparent;
    border: none;
    color: #475569;
    font-weight: 600;
    font-size: 0.92rem;
    padding: 0.55rem 0.95rem;
    border-radius: 10px;
    opacity: 0.8;
}

.export-trigger:hover {
    opacity: 1;
    background: #f3f4f6;
    color: #111827;
}

.export-menu {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 6px;
    min-width: 190px;
    z-index: 1000;
    box-shadow: 0 10px 25px rgba(15, 23, 42, 0.12);
}

.export-menu button {
    width: 100%;
    padding: 10px 12px;
    background: transparent;
    border: none;
    border-radius: 8px;
    text-align: left;
    cursor: pointer;
    font-weight: 600;
    color: #374151;
}

.export-menu button:hover {
    background: #f3f4f6;
}

.export-trigger-disabled {
    opacity: 0.4;
    cursor: not-allowed;
    pointer-events: none;
}

.export-trigger-disabled::after {
    font-size: 0.75rem;
    opacity: 0.6;
}
/* ===== Auth / roles ===== */
.user-menu {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding-left: 8px;
    border-left: 1px solid rgba(148, 163, 184, .35);
}

.user-menu__badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    background: rgba(139, 16, 35, .1);
    color: #8b1023;
    font-weight: 900;
    font-size: 12px;
    white-space: nowrap;
}

.user-menu__name {
    max-width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #475569;
    font-size: 13px;
    font-weight: 800;
}

.site-link--logout {
    background: #fff1f2 !important;
    color: #be123c !important;
}

.auth-denied-panel {
    max-width: 720px;
    margin: 40px auto;
}

@media (max-width: 980px) {
    .site-header__inner,
    .site-header__actions {
        align-items: flex-start;
    }

    .user-menu {
        width: 100%;
        border-left: 0;
        padding-left: 0;
        padding-top: 8px;
        border-top: 1px solid rgba(148, 163, 184, .35);
    }
}

.exportacion-form h3 { margin-top: 0; }
.checkbox-card {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 46px;
    padding: 12px 14px;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    background: #fff;
    font-weight: 800;
    color: #334155;
}
.checkbox-card input { width: 18px; height: 18px; }

/* ===== Header limpio por roles - Fase 20 ===== */
.site-header .container {
    width: min(1520px, 96%);
}

.site-header__inner {
    min-height: 70px;
    display: grid;
    grid-template-columns: minmax(150px, 210px) 1fr;
    align-items: center;
    gap: 18px;
}

.site-brand {
    text-decoration: none;
    min-width: 0;
}

.site-header__right {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 14px;
    min-width: 0;
}

.site-header__actions {
    justify-content: flex-end;
    gap: 6px;
    min-width: 0;
}

.site-link {
    padding: 0.52rem 0.8rem;
    font-size: 0.88rem;
    white-space: nowrap;
}

.user-menu {
    flex: 0 0 auto;
    min-height: 38px;
    padding-left: 12px;
    gap: 8px;
}

.user-menu__role,
.user-menu__badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    padding: 0 10px;
    border-radius: 999px;
    background: rgba(139, 16, 35, .1);
    color: #8b1023;
    font-weight: 900;
    font-size: 12px;
    white-space: nowrap;
}

.user-menu__username,
.user-menu__name {
    max-width: 118px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #475569;
    font-size: 13px;
    font-weight: 800;
}

.readonly-notice {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    border-radius: 14px;
    background: #eff6ff;
    color: #1d4ed8;
    font-weight: 800;
    font-size: 13px;
}

@media (max-width: 1180px) {
    .site-header__inner {
        grid-template-columns: 1fr;
        align-items: start;
        padding: 10px 0;
    }

    .site-header__right {
        width: 100%;
        align-items: flex-start;
        justify-content: flex-start;
        flex-direction: column;
        gap: 10px;
    }

    .site-header__actions {
        width: 100%;
        justify-content: flex-start;
    }

    .user-menu {
        width: auto;
        border-left: 0;
        padding-left: 0;
        padding-top: 0;
        border-top: 0;
    }
}

/* =========================================================
   HEADER DESKTOP - AJUSTE FINAL
========================================================= */

@media (min-width: 1181px) {

    .site-header .container {
        width: min(1560px, 97%);
    }

    .site-header__inner {
        display: grid;
        grid-template-columns: 190px minmax(0, 1fr);
        align-items: center;
        gap: 16px;
        min-height: 64px;
    }

    .site-header__right {
        width: 100%;
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: flex-end;
        gap: 12px;
        min-width: 0;
    }

    .site-header__actions {
        display: flex;
        align-items: center;
        justify-content: flex-end;
        flex-wrap: nowrap !important;
        gap: 3px;
        min-width: 0;
        width: auto;
    }

    .site-header__actions .site-link {
        flex: 0 0 auto;
        padding: 0.48rem 0.65rem;
        font-size: 0.82rem;
        white-space: nowrap;
    }

    .user-menu {
        flex: 0 0 auto;
        display: flex;
        align-items: center;
        flex-direction: row;
        gap: 6px;
        padding-left: 10px;
    }
}

/* =========================================================
   MENÚ AGRUPADO / DROPDOWNS
========================================================= */

.nav-dropdown {
    position: relative;
    flex: 0 0 auto;
}

.nav-dropdown__trigger {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: none;
    background: transparent;
    cursor: pointer;
    font-family: inherit;
}

.nav-dropdown__arrow {
    font-size: 9px;
    opacity: 0.65;
    transition: transform 0.18s ease;
}

.nav-dropdown__menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 190px;
    padding: 7px;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 14px 35px rgba(15, 23, 42, 0.12);

    opacity: 0;
    visibility: hidden;
    transform: translateY(-4px);
    pointer-events: none;

    transition:
        opacity 0.16s ease,
        transform 0.16s ease,
        visibility 0.16s ease;

    z-index: 1500;
}

.nav-dropdown:hover .nav-dropdown__menu,
.nav-dropdown:focus-within .nav-dropdown__menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.nav-dropdown:hover .nav-dropdown__arrow,
.nav-dropdown:focus-within .nav-dropdown__arrow {
    transform: rotate(180deg);
}

.nav-dropdown__item {
    display: block;
    width: 100%;
    padding: 10px 12px;
    border-radius: 9px;

    text-decoration: none;
    color: #475569;
    font-size: 13px;
    font-weight: 700;
    white-space: nowrap;

    transition:
        background 0.16s ease,
        color 0.16s ease;
}

.nav-dropdown__item:hover {
    background: #f3f4f6;
    color: #111827;
}

.nav-dropdown__item.is-active {
    background: #111827;
    color: #ffffff;
}

/* Evita que el dropdown quede cortado */
.site-header,
.site-header__inner,
.site-header__right,
.site-header__actions {
    overflow: visible;
}

/* =========================
   RESPONSIVE DEL MENÚ
========================= */

@media (max-width: 1180px) {
    .site-header__actions {
        display: flex;
        flex-wrap: wrap;
        gap: 6px;
    }

    .nav-dropdown__menu {
        left: 0;
        right: auto;
    }
}

@media (max-width: 640px) {
    .nav-dropdown {
        width: 100%;
    }

    .nav-dropdown__trigger {
        width: 100%;
        justify-content: space-between;
    }

    .nav-dropdown__menu {
        position: static;
        width: 100%;
        min-width: 0;
        margin-top: 5px;

        opacity: 1;
        visibility: visible;
        transform: none;
        pointer-events: auto;

        display: none;
        box-shadow: none;
        border-radius: 10px;
        background: #f8fafc;
    }

    .nav-dropdown:hover .nav-dropdown__menu,
    .nav-dropdown:focus-within .nav-dropdown__menu {
        display: block;
    }

    .nav-dropdown__item {
        padding: 10px 12px;
    }
}

/* =========================================================
   USUARIOS - GESTIÓN DE CUENTAS
========================================================= */

.users-grid {
    display: grid;
    grid-template-columns: minmax(300px, 360px) minmax(0, 1fr);
    gap: 22px;
    align-items: start;
}

.user-form-card,
.users-list-card {
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 22px;
    box-shadow: var(--shadow-panel);
    padding: 22px;
}

.user-form-card h2,
.users-list-card h2 {
    margin: 0 0 8px;
    font-size: 22px;
    color: #172033;
}

.user-form-card p,
.users-list-card p {
    margin: 0 0 18px;
    color: #64748b;
    line-height: 1.5;
}

.user-admin-form {
    display: grid;
    gap: 14px;
}

.user-admin-form .field-group {
    gap: 7px;
}

.user-admin-form input,
.user-admin-form select {
    width: 100%;
    height: 44px;
    border: 1px solid #dbe3ef;
    border-radius: 13px;
    padding: 0 13px;
    font: inherit;
    outline: none;
}

.user-admin-form input:focus,
.user-admin-form select:focus {
    border-color: #8b5cf6;
    box-shadow: 0 0 0 4px rgba(139, 92, 246, .12);
}

.account-type-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 11px 13px;
    border: 1px solid #e8eaf0;
    border-radius: 13px;
    background: #f8fafc;
}

.account-type-info span {
    color: #64748b;
    font-size: 12px;
    font-weight: 700;
}

.account-type-info strong {
    color: #111827;
    font-size: 13px;
}

.account-management-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.account-management-actions .btn-primary,
.account-management-actions .btn-secondary {
    min-height: 40px;
}

.users-list-card .table-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
}

.users-list-card .table-header h2 {
    margin-bottom: 6px;
}

.users-list-card .table-header p {
    margin: 0;
    max-width: 760px;
}

.users-table {
    min-width: 0;
    width: 100%;
    table-layout: fixed;
}

.users-table th:nth-child(1),
.users-table td:nth-child(1) {
    width: 14%;
}

.users-table th:nth-child(2),
.users-table td:nth-child(2) {
    width: 12%;
}

.users-table th:nth-child(3),
.users-table td:nth-child(3) {
    width: 13%;
}

.users-table th:nth-child(4),
.users-table td:nth-child(4) {
    width: 12%;
}

.users-table th:nth-child(5),
.users-table td:nth-child(5) {
    width: 18%;
}

.users-table th:nth-child(6),
.users-table td:nth-child(6) {
    width: 31%;
}

.users-table td:nth-child(4) {
    white-space: nowrap;
}

.users-list-card .table-wrapper {
    overflow-x: hidden;
}

.users-table th {
    white-space: nowrap;
}

.users-table td {
    vertical-align: middle;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 27px;
    white-space: nowrap;
    padding: 5px 10px;
    border-radius: var(--radius-pill);
    font-size: 12px;
    font-weight: 800;
}

.status-active {
    background: #ecfdf3;
    color: #027a48;
    border: 1px solid #abefc6;
}

.status-inactive {
    background: #fef3f2;
    color: #b42318;
    border: 1px solid #fecdca;
}

.table-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(100px, 1fr));
    gap: 8px;
    align-items: stretch;
}

.table-actions .btn-table,
.table-actions .account-protected-badge {
    width: 100%;
    justify-content: center;
    text-align: center;
}

.btn-table {
    min-width: auto;
    appearance: none;
    border: 1px solid #d0d5dd;
    background: #ffffff;
    color: #344054;
    border-radius: 9px;
    padding: 8px 10px;
    min-height: 34px;
    font-family: inherit;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    transition:
        background .16s ease,
        border-color .16s ease,
        color .16s ease,
        transform .16s ease,
        box-shadow .16s ease;
    box-sizing: border-box;
}

.btn-table:hover {
    background: #f9fafb;
    border-color: #98a2b3;
    transform: translateY(-1px);
}

.btn-table:active {
    transform: translateY(0);
}

.btn-table:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px var(--primary-ring);
}

.btn-danger-soft {
    background: #fff5f5;
    color: #c1153a;
    border-color: #fecdd6;
}

.btn-danger-soft:hover {
    background: #ffe4e8;
    color: #a30d32;
    border-color: #fda4b4;
}

.btn-success-soft {
    background: #ecfdf3;
    color: #027a48;
    border-color: #abefc6;
}

.btn-success-soft:hover {
    background: #d1fadf;
    border-color: #75e0a7;
}

.account-protected-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    padding: 6px 10px;
    border-radius: 9px;
    background: #f4f3ff;
    color: #5925dc;
    border: 1px solid #d9d6fe;
    font-size: 12px;
    font-weight: 800;
    box-sizing: border-box;
}

#refreshUsersBtn {
    flex-shrink: 0;
    min-height: 40px;
    padding: 10px 16px;
}

/* =========================================================
   PANEL DE PERMISOS
========================================================= */

.permissions-panel {
    margin-top: 24px;
}

.permissions-header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 20px;
}

.permissions-header h2 {
    margin: 8px 0 6px;
    font-size: 24px;
    font-weight: 800;
    color: #172033;
}

.permissions-header p {
    margin: 0;
    color: #64748b;
    line-height: 1.5;
}

.permissions-account-selector {
    width: min(300px, 100%);
    flex: 0 0 auto;
}

.permissions-account-selector label {
    display: block;
    margin-bottom: 7px;
    font-size: 12px;
    font-weight: 700;
    color: #64748b;
}

.permissions-account-selector select {
    width: 100%;
    height: 44px;
    border: 1px solid #dbe3ef;
    border-radius: 13px;
    background: #fff;
    padding: 0 12px;
    font-weight: 700;
    color: #334155;
}

.permissions-empty {
    padding: 28px;
    border: 1px dashed #d7deea;
    border-radius: 16px;
    background: #f8fafc;
    color: #64748b;
    text-align: center;
    font-weight: 700;
}

.permissions-content {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.permissions-account-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 14px 16px;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    background: #fafafa;
}

.permissions-account-info > div {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.permissions-account-info strong {
    color: #111827;
    font-size: 15px;
}

.permissions-account-info span {
    color: #64748b;
    font-size: 12px;
    font-weight: 700;
}

.permissions-groups {
    display: grid;
    gap: 12px;
}

.permissions-group {
    overflow: hidden;
    border: 1px solid #e5e7eb;
    border-radius: 15px;
    background: #ffffff;
}

.permissions-group__header {
    width: 100%;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 13px 16px;
    border: 0;
    background: #f8fafc;
    color: #1f2937;
    font-family: inherit;
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
    text-align: left;
}

.permissions-group__header:hover {
    background: #f3f4f6;
}

.permissions-group__chevron {
    color: #64748b;
    font-size: 13px;
    transition: transform .18s ease;
}

.permissions-group.collapsed .permissions-group__chevron {
    transform: rotate(-90deg);
}

.permissions-group__body {
    padding: 8px 14px 14px;
}

.permissions-group.collapsed .permissions-group__body {
    display: none;
}

.permission-row {
    display: grid;
    grid-template-columns: minmax(220px, 1fr) 105px 115px;
    align-items: center;
    gap: 12px;
    min-height: 52px;
    padding: 10px 8px;
    border-bottom: 1px solid #eef2f7;
}

.permission-row:last-child {
    border-bottom: 0;
}

.permission-row__module {
    min-width: 0;
}

.permission-row__module strong {
    display: block;
    color: #1f2937;
    font-size: 14px;
}

.permission-check {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    color: #475569;
    font-size: 12px;
    font-weight: 700;
}

.permission-check input {
    width: 18px;
    height: 18px;
    margin: 0;
    accent-color: var(--primary);
    cursor: pointer;
}

.permission-check input:disabled {
    cursor: not-allowed;
    opacity: .5;
}

.permissions-actions {
    display: flex;
    justify-content: flex-end;
    padding-top: 4px;
}

.permissions-actions .btn-primary {
    min-width: 170px;
}

/* =========================================================
   RESPONSIVE - USUARIOS Y PERMISOS
========================================================= */

@media (max-width: 1100px) {
    .users-grid {
        grid-template-columns: 1fr;
    }

    .users-list-card .table-wrapper {
        overflow-x: auto;
    }
}

@media (max-width: 760px) {
    .users-list-card .table-header,
    .permissions-header {
        flex-direction: column;
        align-items: stretch;
    }

    .permissions-account-selector {
        width: 100%;
    }

    .permissions-account-info {
        flex-direction: column;
        align-items: flex-start;
    }

    .permission-row {
        grid-template-columns: minmax(0, 1fr) 72px 82px;
        gap: 8px;
    }

    #refreshUsersBtn {
        width: 100%;
    }
}

@media (max-width: 520px) {
    .account-management-actions {
        flex-direction: column;
    }

    .account-management-actions .btn-primary,
    .account-management-actions .btn-secondary {
        width: 100%;
    }

    .permission-row {
        grid-template-columns: minmax(0, 1fr) 58px 72px;
        padding-left: 2px;
        padding-right: 2px;
    }

    .permission-row__module strong {
        font-size: 13px;
    }

    .permission-check {
        gap: 4px;
        font-size: 11px;
    }
}

.last-access {
    display: inline-flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 3px;
    line-height: 1.2;
    white-space: nowrap;
}

.last-access > span {
    display: block;
    font-size: 13px;
    color: #1f2937;
    white-space: nowrap;
}

.last-access > small {
    display: block;
    font-size: 12px;
    color: #64748b;
    white-space: nowrap;
}

/* =========================================================
   NUEVO REGISTRO - BLOQUES IPHCI + USO DIARIO
========================================================= */

#formModal .modal-content {
    width: min(1020px, 94%);
    max-height: 92vh;
    margin: 20px auto;
    padding: 0;
    overflow-y: auto;
    background: #f8fafc;
    border-radius: 20px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.18);
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 transparent;
}

#formModal .modal-header {
    position: sticky;
    top: 0;
    z-index: 6;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin: 0;
    padding: 20px 24px;
    background: rgba(255, 255, 255, 0.98);
    border-bottom: 1px solid #e5e7eb;
    backdrop-filter: blur(8px);
}

#formModal .modal-header h2 {
    margin: 0 0 5px;
    font-size: 24px;
    line-height: 1.15;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: #172033;
}

#formModal .modal-header p {
    margin: 0;
    font-size: 13px;
    line-height: 1.45;
    color: #64748b;
}

#formModal .form-layout {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 20px 22px 0;
}

#formModal .form-section {
    position: relative;
    padding: 20px 22px 22px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.035);
    overflow: hidden;
}

#formModal .form-section::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: 4px;
    background: #8b1023;
}

#formModal .form-section--patient {
    border-color: #ead6da;
    background: linear-gradient(180deg, #fffafb 0%, #ffffff 35%);
}

#formModal .form-section--patient::before {
    background: #8b1023;
}

#formModal .form-section--patient .form-section__eyebrow {
    color: #8b1023;
}

#formModal .form-section--attention {
    border-color: #dbe7f5;
    background: linear-gradient(180deg, #f8fbff 0%, #ffffff 35%);
}

#formModal .form-section--attention::before {
    background: #315b8a;
}

#formModal .form-section--attention .form-section__eyebrow {
    color: #315b8a;
}

#formModal .form-section--appointment {
    border-color: #e5dce0;
    background: linear-gradient(180deg, #fcf9fa 0%, #ffffff 35%);
}

#formModal .form-section--appointment::before {
    background: #68101f;
}

#formModal .form-section--appointment .form-section__eyebrow {
    color: #68101f;
}

#formModal #conveniosSection {
    border-color: #eadfd4;
    background: linear-gradient(180deg, #fffaf5 0%, #ffffff 35%);
}

#formModal #conveniosSection::before {
    background: #9a5a24;
}

#formModal .form-section__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin: 0 0 17px;
    padding: 0 0 13px;
    border-bottom: 1px solid #e9edf2;
}

#formModal .form-section__header h3 {
    margin: 0;
    font-size: 17px;
    line-height: 1.25;
    font-weight: 800;
    color: #172033;
}

#formModal .form-section__header p {
    margin: 4px 0 0;
    max-width: 720px;
    font-size: 12px;
    line-height: 1.45;
    color: #64748b;
}

#formModal .form-section__eyebrow {
    display: block;
    margin-bottom: 5px;
    padding: 0;
    background: transparent;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

#formModal .form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px 22px;
}

#formModal .field-group-full {
    grid-column: 1 / -1;
}

#formModal .field-group {
    display: flex;
    flex-direction: column;
    gap: 7px;
    min-width: 0;
}

#formModal .field-group label {
    margin: 0;
    font-size: 12px;
    font-weight: 700;
    color: #334155;
}

#formModal .field-group input,
#formModal .field-group select,
#formModal .field-group textarea {
    width: 100%;
    border: 1px solid #cfd8e3;
    border-radius: 11px;
    background: #ffffff;
    color: #101828;
    font-family: inherit;
    font-size: 13px;
    outline: none;
    transition:
        border-color 0.16s ease,
        box-shadow 0.16s ease,
        background 0.16s ease;
}

#formModal .field-group input,
#formModal .field-group select {
    height: 43px;
    padding: 0 12px;
}

#formModal .field-group textarea {
    min-height: 92px;
    padding: 11px 12px;
    resize: vertical;
    line-height: 1.45;
}

#formModal .field-group input:hover,
#formModal .field-group select:hover,
#formModal .field-group textarea:hover {
    border-color: #a8b4c3;
}

#formModal .field-group input:focus,
#formModal .field-group select:focus,
#formModal .field-group textarea:focus {
    border-color: #8b1023;
    box-shadow: 0 0 0 3px rgba(139, 16, 35, 0.10);
}

#formModal input::placeholder,
#formModal textarea::placeholder {
    color: #94a3b8;
}

/* Campos dinámicos: deben permanecer ocultos hasta que el JS quite .hidden */
#formModal .field-group.hidden {
    display: none !important;
}

#formModal #nombreReferidoGroup:not(.hidden),
#formModal #doctorCitaGroup:not(.hidden) {
    animation: formFieldReveal 0.18s ease;
}

@keyframes formFieldReveal {
    from {
        opacity: 0;
        transform: translateY(-4px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

#formModal .form-actions {
    position: sticky;
    bottom: 0;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    margin: 2px -22px 0;
    padding: 15px 22px;
    background: rgba(255, 255, 255, 0.98);
    border-top: 1px solid #e5e7eb;
    backdrop-filter: blur(8px);
}

#formModal .form-actions .btn-primary,
#formModal .form-actions .btn-secondary {
    min-height: 42px;
    padding: 0 18px;
    border-radius: 10px;
}

#formModal .form-actions .btn-secondary {
    background: #ffffff;
    color: #334155;
    border: 1px solid #cfd8e3;
}

#formModal .form-actions .btn-secondary:hover {
    background: #f8fafc;
    border-color: #a8b4c3;
}

#formModal .form-actions .btn-primary {
    min-width: 145px;
    background: #8b1023;
    box-shadow: 0 6px 16px rgba(139, 16, 35, 0.18);
}

#formModal .form-actions .btn-primary:hover {
    background: #68101f;
}

#formModal .modal-content::-webkit-scrollbar {
    width: 7px;
}

#formModal .modal-content::-webkit-scrollbar-track {
    background: transparent;
}

#formModal .modal-content::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 999px;
}

@media (max-width: 760px) {
    #formModal .modal-content {
        width: min(720px, 96%);
    }

    #formModal .modal-header {
        padding: 18px 20px;
    }

    #formModal .form-layout {
        padding: 18px 18px 0;
        gap: 14px;
    }

    #formModal .form-section {
        padding: 18px 18px 20px;
    }

    #formModal .form-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    #formModal .form-actions {
        margin: 0 -18px;
        padding: 14px 18px;
    }
}

@media (max-width: 520px) {
    #formModal {
        padding: 8px;
    }

    #formModal .modal-content {
        width: 100%;
        max-height: 95vh;
        margin: 0;
        border-radius: 16px;
    }

    #formModal .modal-header {
        padding: 16px;
    }

    #formModal .modal-header h2 {
        font-size: 21px;
    }

    #formModal .form-layout {
        padding: 14px 14px 0;
        gap: 12px;
    }

    #formModal .form-section {
        padding: 16px 15px 18px;
        border-radius: 14px;
    }

    #formModal .form-section__header {
        margin-bottom: 14px;
        padding-bottom: 11px;
    }

    #formModal .form-grid {
        grid-template-columns: 1fr;
        gap: 13px;
    }

    #formModal .form-actions {
        margin: 0 -14px;
        padding: 13px 14px;
        flex-direction: column-reverse;
    }

    #formModal .form-actions .btn-primary,
    #formModal .form-actions .btn-secondary {
        width: 100%;
    }
}

/* =========================================================
   SELECTOR DE COLUMNAS - DISEÑO FINAL
========================================================= */

.filters-toolbar__left {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
    flex-wrap: wrap;
}

.columns-control {
    position: relative;
    flex-shrink: 0;
}

.columns-toggle-btn {
    min-width: 104px;
    height: 40px;
    padding: 0 16px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    background: #ffffff;
    color: #344054;

    border: 1px solid #d0d5dd;
    border-radius: 12px;

    font-family: inherit;
    font-size: 13px;
    font-weight: 700;

    cursor: pointer;

    transition:
        background 0.18s ease,
        border-color 0.18s ease,
        color 0.18s ease,
        box-shadow 0.18s ease,
        transform 0.18s ease;
}

.columns-toggle-btn:hover {
    background: #f8fafc;
    border-color: #b8c0cc;
    transform: translateY(-1px);
}

.columns-toggle-btn:active {
    transform: translateY(0);
}

.columns-toggle-btn[aria-expanded="true"] {
    color: #8b1023;
    background: #fffafb;
    border-color: #8b1023;
    box-shadow: 0 0 0 3px rgba(139, 16, 35, 0.08);
}

/* PANEL */

.columns-menu {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    z-index: 200;

    width: 340px;
    padding: 12px;

    background: #ffffff;

    border: 1px solid #e4e7ec;
    border-radius: 16px;

    box-shadow:
        0 18px 45px rgba(16, 24, 40, 0.14),
        0 2px 8px rgba(16, 24, 40, 0.04);

    animation: columnsMenuIn 0.16s ease;
}

.columns-menu.hidden {
    display: none;
}

@keyframes columnsMenuIn {
    from {
        opacity: 0;
        transform: translateY(-5px) scale(0.99);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* CABECERA */

.columns-menu__header {
    padding: 7px 8px 12px;

    border-bottom: 1px solid #eef2f6;
}

.columns-menu__header strong {
    display: block;
    margin-bottom: 3px;

    color: #101828;

    font-size: 14px;
    font-weight: 800;
}

.columns-menu__header small {
    display: block;

    color: #98a2b3;

    font-size: 11px;
    font-weight: 500;
    line-height: 1.4;
}

/* OPCIONES - DOBLE COLUMNA */

.columns-menu__options {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;

    padding: 12px 0;

    max-height: none;
    overflow: visible;
}

/* CADA OPCIÓN */

.column-option {
    position: relative;

    display: flex;
    align-items: center;

    min-height: 52px;
    padding: 9px 48px 9px 11px;

    background: #ffffff;

    border: 1px solid #edf0f4;
    border-radius: 12px;

    color: #344054;

    font-size: 12px;
    font-weight: 700;
    line-height: 1.25;

    cursor: pointer;
    user-select: none;

    transition:
        background 0.15s ease,
        border-color 0.15s ease,
        box-shadow 0.15s ease,
        transform 0.15s ease;
}

.column-option:hover {
    background: #f8fafc;
    border-color: #d8dee8;
    transform: translateY(-1px);
}

.column-option:has(input[type="checkbox"]:checked) {
    background: #fffafb;
    border-color: #ead6da;
}

/* TOGGLE */

.column-option input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;

    position: absolute;
    right: 10px;
    top: 50%;

    transform: translateY(-50%);

    width: 34px;
    height: 20px;
    margin: 0;

    background: #e4e7ec;

    border: 1px solid #d0d5dd;
    border-radius: 999px;

    cursor: pointer;

    transition:
        background 0.18s ease,
        border-color 0.18s ease,
        box-shadow 0.18s ease;
}

.column-option input[type="checkbox"]::after {
    content: "";

    position: absolute;

    top: 50%;
    left: 2px;

    width: 14px;
    height: 14px;

    background: #ffffff;
    border-radius: 50%;

    box-shadow: 0 1px 3px rgba(16, 24, 40, 0.20);

    transform: translateY(-50%);

    transition: transform 0.18s ease;
}

.column-option input[type="checkbox"]:hover {
    border-color: #b8c0cc;
}

.column-option input[type="checkbox"]:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px rgba(139, 16, 35, 0.10);
}

.column-option input[type="checkbox"]:checked {
    background: #8b1023;
    border-color: #8b1023;
}

.column-option input[type="checkbox"]:checked::after {
    transform: translate(14px, -50%);
}

/* FOOTER */

.columns-menu__footer {
    padding: 10px 7px 3px;

    border-top: 1px solid #eef2f6;
}

.columns-reset-btn {
    width: 100%;
    min-height: 36px;
    padding: 0 12px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    background: #f8fafc;
    color: #667085;

    border: 1px solid #e4e7ec;
    border-radius: 10px;

    font-family: inherit;
    font-size: 11px;
    font-weight: 700;

    cursor: pointer;

    transition:
        background 0.15s ease,
        border-color 0.15s ease,
        color 0.15s ease;
}

.columns-reset-btn:hover {
    background: #fff1f2;
    border-color: #fbcfd6;
    color: #8b1023;
}

/* COLUMNAS OCULTAS EN LA TABLA */

.records-table .column-hidden {
    display: none !important;
}

/* RESPONSIVE */

@media (max-width: 760px) {
    .columns-menu {
        width: min(340px, calc(100vw - 32px));
    }
}

@media (max-width: 520px) {
    .columns-menu {
        width: min(320px, calc(100vw - 24px));
        padding: 10px;
    }

    .columns-menu__options {
        grid-template-columns: 1fr;
        gap: 6px;
    }

    .column-option {
        min-height: 46px;
    }
}

/* =========================================================
   DETALLE CONSULTA - COMPACTO + TEXTO COMPLETO EN HOVER
========================================================= */

.table-panel .records-table .cell-detail {
    min-width: 170px;
    max-width: 230px;
}

.table-panel .records-table .cell-detail__text {
    display: block;

    width: 100%;
    max-width: 220px;

    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;

    color: #667085;

    cursor: help;
}

/* =========================================================
   DETALLE DEL REGISTRO - MISMO LENGUAJE QUE NUEVO REGISTRO
========================================================= */

#detailModal .modal-content {
    width: min(1040px, 94%);
    max-height: 92vh;

    padding: 0;

    background: #f8fafc;

    border-radius: 20px;

    overflow-y: auto;

    box-shadow:
        0 24px 60px rgba(15, 23, 42, 0.20);
}


/* CABECERA DEL MODAL */

#detailModal .modal-header {
    position: sticky;
    top: 0;

    z-index: 5;

    margin: 0;

    padding: 20px 24px;

    background: rgba(255, 255, 255, 0.98);

    border-bottom: 1px solid #e5e7eb;

    backdrop-filter: blur(8px);
}

#detailModal .modal-header h2 {
    margin: 0 0 5px;

    color: #172033;

    font-size: 24px;
    font-weight: 800;
    letter-spacing: -0.02em;
}

#detailModal .modal-header p {
    margin: 0;

    color: #64748b;

    font-size: 13px;
}


/* CONTENIDO */

#detailModal .detail-layout,
#detailModal #detailContent {
    display: flex;
    flex-direction: column;

    gap: 16px;

    padding: 20px 22px 22px;
}


/* =========================================================
   BLOQUES
========================================================= */

#detailModal .detail-section {
    position: relative;

    margin: 0;

    padding: 20px 22px 22px;

    background: #ffffff;

    border: 1px solid #e2e8f0;
    border-radius: 16px;

    box-shadow:
        0 2px 8px rgba(15, 23, 42, 0.035);

    overflow: hidden;
}


/* BARRA LATERAL */

#detailModal .detail-section::before {
    content: "";

    position: absolute;

    top: 0;
    bottom: 0;
    left: 0;

    width: 4px;

    background: #8b1023;
}


/* =========================================================
   PACIENTE
========================================================= */

#detailModal .detail-section--patient {
    border-color: #ead6da;

    background:
        linear-gradient(
            180deg,
            #fffafb 0%,
            #ffffff 35%
        );
}

#detailModal .detail-section--patient::before {
    background: #8b1023;
}

#detailModal .detail-section--patient
.detail-section__eyebrow {
    color: #8b1023;
}


/* =========================================================
   ATENCIÓN
========================================================= */

#detailModal .detail-section--attention {
    border-color: #dbe7f5;

    background:
        linear-gradient(
            180deg,
            #f8fbff 0%,
            #ffffff 35%
        );
}

#detailModal .detail-section--attention::before {
    background: #315b8a;
}

#detailModal .detail-section--attention
.detail-section__eyebrow {
    color: #315b8a;
}


/* =========================================================
   CITA
========================================================= */

#detailModal .detail-section--appointment {
    border-color: #e5dce0;

    background:
        linear-gradient(
            180deg,
            #fcf9fa 0%,
            #ffffff 35%
        );
}

#detailModal .detail-section--appointment::before {
    background: #68101f;
}

#detailModal .detail-section--appointment
.detail-section__eyebrow {
    color: #68101f;
}


/* =========================================================
   CONVENIO
========================================================= */

#detailModal .detail-section--agreement {
    border-color: #eadfd4;

    background:
        linear-gradient(
            180deg,
            #fffaf5 0%,
            #ffffff 35%
        );
}

#detailModal .detail-section--agreement::before {
    background: #9a5a24;
}

#detailModal .detail-section--agreement
.detail-section__eyebrow {
    color: #9a5a24;
}


/* =========================================================
   CABECERA DE CADA BLOQUE
========================================================= */

#detailModal .detail-section__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;

    gap: 16px;

    margin-bottom: 17px;

    padding-bottom: 13px;

    border-bottom: 1px solid #e9edf2;
}

#detailModal .detail-section__header h3 {
    margin: 0;

    color: #172033;

    font-size: 17px;
    font-weight: 800;
}

#detailModal .detail-section__eyebrow {
    display: block;

    margin-bottom: 5px;

    font-size: 10px;
    font-weight: 800;

    letter-spacing: 0.08em;

    text-transform: uppercase;
}


/* =========================================================
   GRID
========================================================= */

#detailModal .detail-grid {
    display: grid;

    grid-template-columns:
        repeat(2, minmax(0, 1fr));

    gap: 14px 18px;
}


/* =========================================================
   CAMPOS
========================================================= */

#detailModal .detail-item {
    min-height: 66px;

    padding: 12px 14px;

    background: #f8fafc;

    border: 1px solid #eef2f6;
    border-radius: 12px;
}

#detailModal .detail-item strong {
    display: block;

    margin-bottom: 5px;

    color: #667085;

    font-size: 11px;
    font-weight: 700;
}

#detailModal .detail-item span {
    display: block;

    color: #172033;

    font-size: 14px;
    font-weight: 500;

    line-height: 1.4;

    overflow-wrap: anywhere;
}

#detailModal .detail-item--full {
    grid-column: 1 / -1;
}


/* HOVER MUY SUAVE */

#detailModal .detail-item {
    transition:
        background 0.15s ease,
        border-color 0.15s ease;
}

#detailModal .detail-item:hover {
    background: #ffffff;

    border-color: #dbe2ea;
}


/* =========================================================
   SCROLL
========================================================= */

#detailModal .modal-content {
    scrollbar-width: thin;
    scrollbar-color: #cbd5e1 transparent;
}

#detailModal .modal-content::-webkit-scrollbar {
    width: 7px;
}

#detailModal .modal-content::-webkit-scrollbar-track {
    background: transparent;
}

#detailModal .modal-content::-webkit-scrollbar-thumb {
    background: #cbd5e1;

    border-radius: 999px;
}


/* =========================================================
   RESPONSIVE
========================================================= */

@media (max-width: 760px) {

    #detailModal .modal-content {
        width: min(720px, 96%);
    }

    #detailModal .modal-header {
        padding: 18px 20px;
    }

    #detailModal #detailContent {
        padding: 18px;
        gap: 14px;
    }

    #detailModal .detail-section {
        padding: 18px;
    }

    #detailModal .detail-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    #detailModal .detail-item--full {
        grid-column: auto;
    }
}


@media (max-width: 520px) {

    #detailModal {
        padding: 8px;
    }

    #detailModal .modal-content {
        width: 100%;
        max-height: 95vh;

        margin: 0;

        border-radius: 16px;
    }

    #detailModal .modal-header {
        padding: 16px;
    }

    #detailModal .modal-header h2 {
        font-size: 21px;
    }

    #detailModal #detailContent {
        padding: 14px;
        gap: 12px;
    }

    #detailModal .detail-section {
        padding: 16px 15px 18px;

        border-radius: 14px;
    }
}

/* =========================================================
   SERVICIO - BADGES VISUALES
========================================================= */

.servicio-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 26px;
    padding: 5px 11px;

    border: 1px solid transparent;
    border-radius: 999px;

    font-size: 11px;
    font-weight: 700;
    line-height: 1;

    white-space: nowrap;
    text-decoration: none;

    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05);
}

/* Consulta — azul suave */
.servicio-consulta {
    background: #dbeafe;
    color: #1e40af;
    border-color: #bfdbfe;
}

/* Ecografía — morado suave */
.servicio-ecografia {
    background: #ede9fe;
    color: #5b21b6;
    border-color: #ddd6fe;
}

/* Laboratorio — celeste suave */
.servicio-laboratorio {
    background: #cffafe;
    color: #155e75;
    border-color: #a5f3fc;
}

/* Vitaminas — amarillo suave */
.servicio-vitaminas {
    background: #fef3c7;
    color: #92400e;
    border-color: #fde68a;
}

/* 2da opinión — terracota suave */
.servicio-2da-opinion {
    background: #ffedd5;
    color: #9a3412;
    border-color: #fed7aa;
}

/* Perdido — rojo suave */
.servicio-perdido {
    background: #fee2e2;
    color: #991b1b;
    border-color: #fecaca;
}

/* Alquiler — rosado suave */
.servicio-alquiler {
    background: #fce7f3;
    color: #9d174d;
    border-color: #fbcfe8;
}

/* Paquete Ads — índigo suave */
.servicio-paquete-ads {
    background: #e0e7ff;
    color: #4338ca;
    border-color: #c7d2fe;
}

.table-panel .records-table th[data-column="acciones"],
.table-panel .records-table td[data-column="acciones"] {
    position: sticky;
    right: 0;
    z-index: 3;
    background: #ffffff;
    box-shadow: -8px 0 12px -12px rgba(15, 23, 42, 0.55);
}

.table-panel .records-table th[data-column="acciones"] {
    z-index: 5;
    background: #f8f7fc;
}

.table-panel .records-table tbody tr:hover td[data-column="acciones"] {
    background: #faf9fc;
}

.table-pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding-top: 16px;
    color: #667085;
    font-size: 12px;
    font-weight: 650;
}

.pagination-actions,
.pagination-pages {
    display: flex;
    align-items: center;
    gap: 6px;
}

.pagination-btn {
    min-width: 36px;
    height: 36px;
    padding: 0 12px;
    border: 1px solid #dfe3eb;
    border-radius: 9px;
    background: #fff;
    color: #344054;
    font-family: inherit;
    font-size: 12px;
    font-weight: 750;
    cursor: pointer;
}

.pagination-btn:hover:not(:disabled) {
    border-color: #8b5cf6;
    color: #5b21b6;
}

.pagination-btn.is-active {
    border-color: #5b21b6;
    background: #5b21b6;
    color: #fff;
}

.pagination-btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.field-hint {
    display: block;
    color: #7c8799;
    font-size: 11px;
    line-height: 1.35;
}

.doctor-autocomplete {
    position: relative;
    width: 100%;
}

#formModal .form-section--attention,
#formModal .form-section--appointment {
    overflow: visible;
}

.doctor-autocomplete__results {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    z-index: 40;
    max-height: 224px;
    overflow-y: auto;
    padding: 5px;
    border: 1px solid #d9deea;
    border-radius: 11px;
    background: #fff;
    box-shadow: 0 14px 30px rgba(15, 23, 42, 0.16);
}

.doctor-autocomplete__option {
    display: block;
    width: 100%;
    padding: 10px 11px;
    border: 0;
    border-radius: 8px;
    background: transparent;
    color: #172033;
    font-family: inherit;
    font-size: 13px;
    font-weight: 650;
    text-align: left;
    cursor: pointer;
}

.doctor-autocomplete__option:hover,
.doctor-autocomplete__option:focus {
    outline: none;
    background: #f4f0ff;
    color: #5b21b6;
}

.doctor-autocomplete__empty {
    display: block;
    padding: 11px;
    color: #667085;
    font-size: 12px;
}

@media (max-width: 760px) {
    .table-header-actions,
    .table-pagination {
        width: 100%;
        align-items: stretch;
        flex-direction: column;
    }

    .table-header-actions {
        justify-content: flex-start;
    }

    .page-size-control {
        justify-content: space-between;
    }

    .pagination-actions {
        justify-content: space-between;
    }

    .pagination-pages {
        overflow-x: auto;
    }
}
