/* ESTILOS PARA GESTIÓN DE CLIENTES */
/* Contenedor principal: ancho limitado y centrado para márgenes consistentes */
.container {
    max-width: 1500px;
    margin: 20px auto;
    padding: 0 20px;
    box-sizing: border-box;
}

/* Contenedor de tabla con scroll */
.table-wrapper-scroll {
    height: 500px;
    overflow: auto;
    border: 1px solid var(--color-accent, #007bff);
    border-radius: 4px;
    margin-bottom: 20px;
    position: relative;
}

/* Tabla con ancho fijo */
.table-fixed {
    width: 100%;
    border-collapse: collapse;
    min-width: 0;
}

.table-fixed th,
.table-fixed td {
    box-sizing: border-box;
    min-width: 0;
}

/* Encabezado fijo */
.table-fixed thead {
    position: sticky;
    top: 0;
    z-index: 20;
}

.table-fixed th {
    background-color: var(--color-accent, #007bff);
    color: white;
    padding: 12px 8px;
    text-align: left;
    font-weight: bold;
    border: none;
    position: sticky;
    top: 0;
}

.table-fixed tbody tr {
    border-bottom: 1px solid #dee2e6;
    transition: background-color 0.2s;
}

.table-fixed tbody tr:hover {
    background-color: #e3f2fd;
}

.table-fixed th,
.table-fixed td {
    box-sizing: border-box;
}

.table-fixed td {
    padding: 10px 8px;
    vertical-align: middle;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Anchos fijos para columnas */
.th-id, .td-id { width: 70px; min-width: 70px; max-width: 70px; text-align: center; }
.th-nombre, .td-nombre { width: 260px; min-width: 260px; max-width: 260px; }
.th-telefono, .td-telefono { width: 150px; min-width: 150px; max-width: 150px; }
.th-email, .td-email { width: 220px; min-width: 220px; max-width: 220px; }
.th-direccion, .td-direccion { width: 330px; min-width: 330px; max-width: 330px; }
.th-cuit, .td-cuit { width: 140px; min-width: 140px; max-width: 140px; }
.th-acciones, .td-acciones { 
    width: 200px; 
    min-width: 200px; 
    max-width: 200px; 
    text-align: center;
}

/* En acciones permitir varias líneas para evitar recorte de botones */
.table-fixed .td-acciones {
    white-space: normal;
    overflow: visible;
    text-overflow: unset;
}

/* Mantener visible la columna ID al hacer scroll horizontal */
.table-fixed .th-id,
.table-fixed .td-id {
    position: sticky;
    left: 0;
    z-index: 600;
    background: #ffffff;
    box-shadow: 2px 0 5px rgba(0,0,0,0.05);
}

.table-fixed .th-id {
    background-color: var(--color-accent, #007bff);
    z-index: 610;
}
/* columnas de vehículos */
.th-marca, .td-marca { width: 150px; min-width: 150px; max-width: 150px; }
.th-modelo, .td-modelo { width: 150px; min-width: 150px; max-width: 150px; }
.th-matricula, .td-matricula { width: 120px; min-width: 120px; max-width: 120px; }
.th-anio, .td-anio { width: 80px; min-width: 80px; max-width: 80px; }
.th-cliente, .td-cliente { width: 180px; min-width: 180px; max-width: 180px; }
/* columnas de repuestos */
.th-descripcion, .td-descripcion { width: 250px; min-width: 250px; max-width: 250px; }
.th-precio, .td-precio { width: 100px; min-width: 100px; max-width: 100px; }
.th-stock, .td-stock { width: 70px; min-width: 70px; max-width: 70px; text-align: center; }
.th-valor, .td-valor { width: 120px; min-width: 120px; max-width: 120px; }

/* Botón de acciones en tabla */
.acciones-container {
    display: flex;
    gap: 5px;
    justify-content: center;
    flex-wrap: wrap;
}

.acciones-container .btn {
    padding: 8px 14px;
    font-size: 14px;
    min-width: 80px;
}

.acciones-container form {
    margin: 0;
}

/* Búsqueda */
.search-container {
    margin-bottom: 20px;
    background: white;
    padding: 12px 16px;
    border-radius: 10px;
    border: 1px solid #d3e3fb;
    box-shadow: 0 2px 8px rgba(31, 95, 191, 0.06);
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.search-form {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    margin-bottom: 0;
}

.search-box {
    position: relative;
    width: 100%;
    max-width: 720px;
}

.search-box input {
    width: 100%;
    padding: 7px 12px 7px 34px;
    border: 1.5px solid #a6c4ef;
    border-radius: 20px;
    font-size: 13.5px;
    background: #fafcff;
    color: #16345d;
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.search-box input:focus {
    outline: none;
    border-color: #3d78d0;
    box-shadow: 0 0 0 0.2rem rgba(79, 141, 228, 0.18);
}

.search-icon {
    position: absolute;
    left: 11px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 13px;
    color: #6a9fd8;
    line-height: 1;
    pointer-events: none;
    user-select: none;
}

.btn-buscar {
    padding: 7px 16px;
    background: #1f5fbf;
    color: white;
    border: none;
    border-radius: 20px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.02em;
    transition: background-color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
    box-shadow: 0 2px 6px rgba(31, 95, 191, 0.18);
    white-space: nowrap;
}

.btn-buscar:hover {
    background: #3d78d0;
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(31, 95, 191, 0.22);
}

.btn-limpiar {
    padding: 7px 14px;
    background: #f0f4fa;
    color: #1f5fbf;
    border: 1.5px solid #bfd4f4;
    border-radius: 20px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    transition: background-color 0.25s ease, border-color 0.25s ease, transform 0.25s ease;
    white-space: nowrap;
}

.btn-limpiar:hover {
    background: #dce9fc;
    border-color: #3d78d0;
    transform: translateY(-1px);
}

/* Contador de resultados */
.result-count {
    text-align: center;
    margin-top: 4px;
    color: #6a9fd8;
    font-style: italic;
    font-size: 12.5px;
}

/* Scrollbar personalizada */
.table-wrapper-scroll::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

.table-wrapper-scroll::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.table-wrapper-scroll::-webkit-scrollbar-thumb {
    background: var(--color-accent, #007bff);
    border-radius: 4px;
}

.table-wrapper-scroll::-webkit-scrollbar-thumb:hover {
    background: var(--color-accent-hover, #0056b3);
}

/* Paginación */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin-top: 20px;
}

.pagination .btn {
     padding: 12px;
    background-color: var(--color-accent, #007bff);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    text-decoration: none;
    display: inline-block;
    font-weight: bold;
    transition: all 0.3s ease;
}

.pagination .btn:hover:not(:disabled) {
    background-color: var(--color-accent-hover, #0056b3);
    text-decoration: none;
}

.pagination .btn:disabled {
    background-color: var(--color-secondary, #6c757d);
    cursor: not-allowed;
    opacity: 0.6;
}

.pagination-info {
    color: var(--color-accent, #007bff);
    font-size: 14px;
    margin: 0 10px;
}

.pagination-numbers {
    display: flex;
    gap: 5px;
    margin: 0 10px;
}

.pagination-number {
    padding: 8px 12px;
    background-color: #e9ecef;
    color: var(--color-accent, #007bff);
    border: 1px solid #dee2e6;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    text-decoration: none;
    display: inline-block;
}

.pagination-number:hover {
    background-color: var(--color-accent, #007bff);
    color: white;
    text-decoration: none;
}

.pagination-number.active {
    background-color: var(--color-accent, #007bff);
    color: white;
    font-weight: bold;
}

/* Mensaje cuando no hay resultados */
.no-results {
    text-align: center;
    padding: 40px;
    color: #6c757d;
    font-style: italic;
    font-size: 18px;
}

/* Estilos generales para la página */
h2 {
    color: var(--color-primary, #0a088f);
    margin-bottom: 20px;
    border-bottom: 2px solid var(--color-primary, #0a088f);
    padding-bottom: 10px;
}

h3 {
    color: var(--color-primary, #0a088f);
    font-weight: bold;
    margin-bottom: 15px;
}

.section-header {
    color: var(--color-primary, #0a088f);
    font-weight: bold;
    font-size: 1.2em;
    margin-bottom: 10px;
}





/* Responsive */
@media (max-width: 768px) {
    .search-form {
        flex-direction: column;
    }
    
    .form-row {
        flex-direction: column;
    }
    
    .form-group {
        min-width: 100%;
    }
    
    .pagination {
        flex-wrap: wrap;
    }
    
    .pagination-numbers {
        order: 3;
        width: 100%;
        justify-content: center;
        margin-top: 10px;
    }
}
/* --------------------- */

/* ESTILOS PARA GESTIÓN DE CLIENTES_M */
.container {
    /* Reutiliza la misma configuración de contenedor centralizado */
    max-width: 1200px;
    margin: 20px auto;
    padding: 0 20px;
    position: relative;
    box-sizing: border-box;
}

.qr-header-wrapper {
    display: flex;
    justify-content: flex-end;
}

.qr-header {
    display: inline-block;
    text-align: center;
    background: white;
    padding: 10px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    border: 1px solid #e9ecef;
    position: relative;
}

.qr-container {
    position: relative;
    display: inline-block;
}

/* Estilos móviles profesionales para formularios (alta_cliente) */
.mobile-card {
    max-width: 720px;
    margin: 14px auto;
    background: linear-gradient(180deg,#ffffff 0%, #fbfdff 100%);
    border-radius: 14px;
    padding: 16px;
    box-shadow: 0 8px 30px rgba(15,23,42,0.06);
    border: 1px solid rgba(31,95,191,0.06);
}
.mobile-card h2 { margin: 0 0 10px; font-size: 1.05rem; color: var(--color-primary,#0a088f); }
.mobile-card .muted { color: #6b7280; font-size: 0.95rem; margin-bottom: 8px; }
.form-control {
    width:100%;
    padding:12px 14px;
    border-radius:10px;
    border:1px solid #e1eefc;
    background:#fbfdff;
    font-size:1rem;
    box-sizing:border-box;
    margin-top:6px;
}
.form-group { margin-bottom:12px; }
.form-row { display:flex; gap:10px; flex-wrap:wrap; }
.form-row .form-group { flex:1; min-width:140px; }
.inline-input-button { display:flex; gap:8px; align-items:flex-end; }
.inline-input-button .form-control { flex:1; min-width:0; }
.inline-input-button .btn-sm { flex:0 0 auto; }
.btn { display:inline-flex; align-items:center; justify-content:center; padding:10px 14px; border-radius:10px; border:none; cursor:pointer; font-weight:700; font-size:0.98rem; }
.btn-primary { background:linear-gradient(180deg,#1f5fbf,#1750a8); color:#fff; box-shadow:0 6px 18px rgba(31,95,191,0.14); }
.btn-secondary { background:#f0f4fa; color:#16345d; border:1px solid #d7e6fb; }
.btn-historial {
    background: #2f9e44;
    color: #fff;
    border: 1px solid #28a745;
    width: 34px;
    min-width: 34px;
    height: 34px;
    padding: 0;
    margin: 0;
    line-height: 1;
    border-radius: 8px;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
}
.btn-historial:hover {
    background: #27913d;
}
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background: rgba(0, 0, 0, 0.5);
    align-items: center;
    justify-content: center;
    padding: 20px;
}
.modal.show {
    display: flex;
}
.modal-content {
    background: #ffffff;
    border-radius: 16px;
    padding: 24px;
    width: 100%;
    max-width: 560px;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.15);
    position: relative;
}
.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
}
.modal-header h3 {
    margin: 0;
    font-size: 1.25rem;
}
.close-modal {
    background: transparent;
    border: none;
    color: #1f5fbf;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
}
.form-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 18px;
}
.form-actions-split {
    justify-content: space-between;
    align-items: center;
}
.form-actions-left {
    display: flex;
    align-items: center;
}
.form-actions-right {
    display: flex;
    gap: 10px;
    align-items: center;
}
.alert { background:#fff8e6; border:1px solid #ffe9b8; padding:10px 12px; border-radius:8px; color:#5a4630; margin-bottom:12px; }

@media (max-width:480px) {
    .mobile-card { padding:14px; margin:10px; border-radius:12px; }
    .btn { width:100%; }
    .form-row { flex-direction:column; }
}

/* id_boot visual button shared style */
.id-boot-btn{display:inline-block;padding:10px 14px;border-radius:10px;background:#f0f4fa;color:#16345d;border:1px solid #d7e6fb;box-shadow:0 4px 14px rgba(31,95,191,0.06);font-weight:700;margin-top:8px}

/* Igualar botones en formulación móvil dentro de la tarjeta */
.mobile-card .form-actions {
    display:flex;
    gap:10px;
    margin-top:12px;
}
.mobile-card .form-actions .btn {
    flex:1;
    min-width:0;
}




.qr-img {
    width: 100px;
    height: 100px;
    display: block;
}

.qr-overlay {
    position: absolute;
    top: 5px;
    right: 5px;
    opacity: 0;
    transition: opacity 0.3s;
    z-index: 10;
}

.qr-container:hover .qr-overlay {
    opacity: 1;
}

.qr-caption {
    font-size: 0.8rem;
    color: #6c757d;
    margin-top: 5px !important;
    margin-bottom: 0;
}

.photo-preview {
    padding: 10px;
    background: #f8f9fa;
    border-radius: 4px;
    text-align: center;
    height: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.photo-preview img {
    max-height: 130px;
    max-width: 100%;
    object-fit: contain;
}

.no-photo {
    color: #999;
    position: relative;
}

.photo-full-link {
    display: block;
    text-decoration: none;
    color: inherit;
    position: relative;
}

.photo-full-link:hover {
    opacity: 0.9;
}

.photo-full-size {
    max-height: 180px;
    width: auto;
    object-fit: contain;
}

.contact-info p {
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
    position: relative;
}

.contact-info p:last-child {
    border-bottom: none;
}

.card {
    margin-bottom: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    border: none;
    position: relative;
}

.card-header {
    background-color: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
    font-weight: 600;
    position: relative;
}

/* Normalizar espaciado interno para coincidir con style.css */
.card {
    border-radius: 10px;
    overflow: hidden;
}

.card-header {
    padding: 12px 16px;
}

.card-body {
    padding: 16px;
    background: transparent;
}

.form-group {
    margin-bottom: 15px;
    position: relative;
}

.form-control {
    border-radius: 4px;
    border: 1px solid #ced4da;
    position: relative;
}

.btn {
    border-radius: 4px;
    padding: 8px 14px;
    position: relative;
    font-size: 14px;
    line-height: 1.2;
    min-height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* Botones pequeños: igualar tamaño visual al botón principal */
.btn-sm {
    padding: 8px 14px;
    font-size: 14px;
    min-height: 38px;
}

.alert {
    padding: 12px;
    margin-bottom: 20px;
    border-radius: 4px;
    border: 1px solid transparent;
    position: relative;
}

.alert-success {
    background-color: #d4edda;
    border-color: #c3e6cb;
    color: #155724;
}

.alert-error {
    background-color: #f8d7da;
    border-color: #f5c6cb;
    color: #721c24;
}

.row.mb-4.align-items-center {
    align-items: center !important;
}

.text-end {
    text-align: right !important;
}

/* --------------------- */
/* ESTILOS AGENDA DASHBOARD */
.agenda-layout {
    background: #ffffff;
    border: 1px solid #e3e8f2;
    border-radius: 14px;
    padding: 16px;
    box-shadow: 0 6px 20px rgba(15, 23, 42, 0.06);
    margin-bottom: 24px;
}

.agenda-timeline {
    display: grid;
    grid-template-columns: 78px 1fr;
    gap: 10px;
    min-height: var(--timeline-height);
}

.timeline-labels {
    position: relative;
    height: var(--timeline-height);
}

.timeline-label {
    position: absolute;
    right: 4px;
    transform: translateY(-50%);
    font-size: 12px;
    font-weight: 700;
    color: #5a6780;
}

.timeline-board {
    position: relative;
    height: var(--timeline-height);
    border: 1px solid #d9e3f3;
    border-radius: 12px;
    background: #f9fbff;
    overflow: hidden;
}

.timeline-mecanicos-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(260px, 1fr));
    gap: 12px;
}

.timeline-mecanico-columna {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.timeline-mecanico-header {
    background: #eef4ff;
    border: 1px solid #d4e2fb;
    border-radius: 8px;
    padding: 8px 10px;
    font-weight: 700;
    color: #1f2a44;
    text-align: center;
}

.timeline-board-mecanico {
    height: var(--timeline-height);
}

.timeline-line {
    position: absolute;
    left: 0;
    right: 0;
    border-top: 1px dashed #d3deef;
}

.timeline-empty {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    align-items: center;
    gap: 10px;
    color: #5f6b81;
}

.timeline-empty p {
    margin: 0;
}

.timeline-empty-columna {
    left: 10px;
    right: 10px;
    transform: translateY(-50%);
    justify-content: center;
}

.timeline-card {
    position: absolute;
    background: #ffffff;
    border: 1px solid #cfe0ff;
    border-left: 4px solid #0a88ff;
    border-radius: 10px;
    padding: 10px;
    box-shadow: 0 4px 12px rgba(10, 55, 130, 0.08);
    overflow: auto;
}

.timeline-card h4 {
    font-size: 0.95rem;
}

.timeline-card p {
    margin: 0 0 6px;
    font-size: 13px;
    color: #2a364d;
    white-space: normal;
    overflow: visible;
    text-overflow: unset;
    line-height: 1.3;
}

.timeline-time {
    color: #1f4c93;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 6px;
}

.mecanico-pill {
    display: inline-block;
    margin-left: 8px;
    background: #e7f2ff;
    color: #0a5db3;
    border: 1px solid #c8dffc;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 9px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    vertical-align: middle;
}

.timeline-note {
    background: #f3f7ff;
    border: 1px solid #d8e5ff;
    border-radius: 7px;
    padding: 6px;
}

.timeline-card .agenda-actions {
    gap: 6px;
    margin-top: 8px;
}

.timeline-card .agenda-actions .btn {
    padding: 4px 6px;
    font-size: 11px;
}

.timeline-card-mecanico {
    z-index: 2;
}

.agenda-title-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    padding-bottom: 12px;
    border-bottom: 1px solid #ecf0f7;
}

.agenda-title-row h3 {
    margin: 0;
    color: #1f2a44;
}

.agenda-tools {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.agenda-filter-label {
    font-weight: 700;
    color: #1f2a44;
    font-size: 13px;
}

.agenda-filter-select {
    border: 1px solid #c7d7f5;
    border-radius: 8px;
    padding: 7px 10px;
    background: #fff;
    color: #1f2a44;
    font-weight: 600;
}

.agenda-row {
    display: grid;
    grid-template-columns: 88px 1fr;
    gap: 12px;
    align-items: flex-start;
    padding: 10px;
    border-radius: 10px;
    border: 1px solid #ebeff6;
    margin-bottom: 10px;
    background: #fafbfd;
}

.agenda-row-ocupada {
    border-left: 4px solid #0a88ff;
    background: #f7fbff;
}

.agenda-row-libre {
    border-left: 4px solid #b9c6da;
}

.agenda-hour {
    font-size: 1rem;
    font-weight: 700;
    color: #1f2a44;
    text-align: center;
    background: #eaf2ff;
    border-radius: 8px;
    padding: 10px 8px;
}

.agenda-content {
    display: grid;
    gap: 10px;
    grid-template-columns: repeat(4, minmax(190px, 1fr));
    align-items: stretch;
}

.slot-empty {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #5f6b81;
    min-height: 42px;
    grid-column: 1 / -1;
}

.slot-empty p {
    margin: 0;
}

.slot-badge {
    display: inline-block;
    background: #e8edf5;
    color: #2f3f5b;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
    padding: 4px 10px;
    text-transform: uppercase;
}

.agenda-card {
    background: #ffffff;
    border: 1px solid #dfe6f2;
    border-radius: 10px;
    padding: 12px;
    min-height: 100%;
}

.agenda-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.agenda-card-header h4 {
    margin: 0;
    font-size: 1rem;
    color: #142035;
}

.estado-pill {
    background: #e7f2ff;
    color: #0a5db3;
    border: 1px solid #c8dffc;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 9px;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.agenda-card p {
    margin: 0 0 6px;
    color: #2a364d;
}

.agenda-card p:last-child {
    margin-bottom: 0;
}

.agenda-note {
    background: #f7f8fc;
    border-radius: 8px;
    padding: 8px;
}

.agenda-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

@media (max-width: 768px) {
    .agenda-title-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .agenda-tools {
        width: 100%;
    }

    .agenda-filter-select {
        flex: 1;
        min-width: 180px;
    }

    .agenda-row {
        grid-template-columns: 1fr;
    }

    .agenda-timeline {
        grid-template-columns: 1fr;
    }

    .timeline-labels {
        display: none;
    }

    .timeline-board {
        min-height: 720px;
        overflow: auto;
    }

    .timeline-mecanicos-grid {
        grid-template-columns: 1fr;
    }

    .timeline-card {
        width: calc(100% - 12px) !important;
        left: 6px !important;
    }
}
/* --------------------- */

body:not(.clientes-page) h2 {
    color: #123f85;
    border-bottom-color: #8cb3eb;
}

body:not(.clientes-page) h3,
body:not(.clientes-page) .section-header,
body:not(.clientes-page) .form-group label,
body:not(.clientes-page) .search-icon,
body:not(.clientes-page) .pagination-info,
body:not(.clientes-page) .result-count,
body:not(.clientes-page) .card-header,
body:not(.clientes-page) .agenda-title-row h3,
body:not(.clientes-page) .agenda-card-header h4 {
    color: #1d4f94;
}

body:not(.clientes-page) .search-container,
body:not(.clientes-page) .form-container,
body:not(.clientes-page) .card,
body:not(.clientes-page) .agenda-layout,
body:not(.clientes-page) .login-container {
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid #d3e3fb;
    border-radius: 16px;
    box-shadow: 0 14px 30px rgba(31, 95, 191, 0.08);
}

body:not(.clientes-page) .search-box input,
body:not(.clientes-page) .form-control,
body:not(.clientes-page) .form-group :is(input, select, textarea),
body:not(.clientes-page) .agenda-filter-select {
    border-color: #a6c4ef;
    color: #16345d;
}

body:not(.clientes-page) .search-box input:focus,
body:not(.clientes-page) .form-control:focus,
body:not(.clientes-page) .form-group :is(input, select, textarea):focus,
body:not(.clientes-page) .agenda-filter-select:focus {
    outline: none;
    border-color: #3d78d0;
    box-shadow: 0 0 0 0.22rem rgba(79, 141, 228, 0.2);
}

body:not(.clientes-page) .table-wrapper-scroll {
    border: 1px solid #a7c3ee;
    border-radius: 16px;
    box-shadow: 0 16px 35px rgba(27, 82, 161, 0.08);
    background: rgba(255, 255, 255, 0.96);
}

body:not(.clientes-page) .table-fixed th,
body:not(.clientes-page) .table-fixed .th-id,
body:not(.clientes-page) .table th {
    background: #123f85;
}

body:not(.clientes-page) .table-fixed tbody tr:nth-child(even) {
    background: #f6faff;
}

body:not(.clientes-page) .table-fixed tbody tr:hover,
body:not(.clientes-page) .table tr:hover {
    background: #dcebff;
}

body:not(.clientes-page) .pagination-number {
    background: #edf4ff;
    color: #1f5fbf;
    border-color: #bfd4f4;
}

body:not(.clientes-page) .pagination-number:hover,
body:not(.clientes-page) .pagination-number.active {
    background: #2f74d1;
    color: #ffffff;
    border-color: #2f74d1;
    box-shadow: 0 10px 20px rgba(47, 116, 209, 0.18);
}

body:not(.clientes-page) .date-selector-compact {
    background: #123f85;
}

body:not(.clientes-page) .compact-date-input:hover,
body:not(.clientes-page) .btn-today-compact:hover,
body:not(.clientes-page) .nav-arrow:hover,
body:not(.clientes-page) .timeline-card:hover,
body:not(.clientes-page) .agenda-card:hover {
    background: #f4f9ff;
    color: #2b69c1;
    border-color: #9fc0f0;
    box-shadow: 0 16px 30px rgba(31, 95, 191, 0.14);
}

body:not(.clientes-page) .timeline-board {
    border-color: #d3e3fb;
    background: linear-gradient(180deg, #f8fbff 0%, #eef5ff 100%);
}

body:not(.clientes-page) .timeline-card,
body:not(.clientes-page) .agenda-card {
    border-color: #cfe0ff;
    box-shadow: 0 10px 22px rgba(31, 95, 191, 0.08);
}

body:not(.clientes-page) .timeline-card {
    border-left-color: #2a72cf;
}

body:not(.clientes-page) .timeline-note,
body:not(.clientes-page) .agenda-note,
body:not(.clientes-page) .agenda-hour,
body:not(.clientes-page) .mecanico-pill,
body:not(.clientes-page) .estado-pill,
body:not(.clientes-page) .slot-badge,
body:not(.clientes-page) .stat-value {
    background: #edf5ff;
    color: #17539f;
    border-color: #bfd7fb;
}

/* CHATBOT STYLES */
.chatbot-toggle {
    position: fixed;
    right: 22px;
    bottom: 22px;
    width: 56px;
    height: 56px;
    border: none;
    border-radius: 50%;
    background: linear-gradient(135deg, #184f9c 0%, #2a72cf 100%);
    color: #fff;
    font-size: 22px;
    cursor: pointer;
    box-shadow: 0 14px 28px rgba(31, 95, 191, 0.3);
    transition: background-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
    z-index: 1100;
}

.chatbot-toggle:hover {
    background: linear-gradient(135deg, #2e69c2 0%, #69a5f2 100%);
    box-shadow: 0 18px 34px rgba(31, 95, 191, 0.36);
    transform: translateY(-2px);
}

.chatbot-panel {
    position: fixed;
    right: 22px;
    bottom: 88px;
    width: 340px;
    max-width: calc(100vw - 28px);
    height: 460px;
    background: #fff;
    border: 1px solid #d8e6fb;
    border-radius: 14px;
    box-shadow: 0 22px 44px rgba(22, 56, 106, 0.22);
    display: none;
    flex-direction: column;
    overflow: hidden;
    z-index: 1100;
}

.chatbot-panel.open {
    display: flex;
}

.chatbot-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    background: linear-gradient(135deg, #123f85 0%, #1f5fbf 58%, #4f8de4 100%);
    color: #fff;
    font-weight: 700;
}

.chatbot-close {
    border: none;
    background: transparent;
    color: #fff;
    font-size: 18px;
    cursor: pointer;
    padding: 2px 6px;
    transition: background-color 0.25s ease;
    border-radius: 6px;
}

.chatbot-close:hover {
    background: rgba(255, 255, 255, 0.18);
}

.chatbot-status {
    padding: 6px 12px;
    font-size: 12px;
    background: #f3f8ff;
    border-bottom: 1px solid #e1ecfb;
    color: #264d84;
}

.chatbot-messages {
    flex: 1;
    overflow-y: auto;
    padding: 12px;
    background: #f6faff;
}

.chat-msg {
    max-width: 88%;
    margin-bottom: 8px;
    padding: 9px 10px;
    border-radius: 10px;
    font-size: 13px;
    line-height: 1.35;
    white-space: pre-wrap;
    word-break: break-word;
}

.chat-msg.user {
    margin-left: auto;
    background: #dcebff;
    border: 1px solid #bfd8fb;
    color: #184879;
}

.chat-msg.bot {
    margin-right: auto;
    background: #fff;
    border: 1px solid #d7e6fa;
    color: #1e365b;
}

.chatbot-input {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 8px;
    padding: 10px;
    border-top: 1px solid #e2ecf9;
    background: #fff;
}

.chatbot-input input {
    border: 1px solid #bdd3f3;
    border-radius: 8px;
    padding: 9px 10px;
    font-size: 13px;
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.chatbot-input input:focus {
    outline: none;
    border-color: #4f8de4;
    box-shadow: 0 0 0 0.22rem rgba(79, 141, 228, 0.18);
}

.chatbot-input button {
    border: none;
    border-radius: 8px;
    padding: 0 14px;
    background: linear-gradient(135deg, #184f9c 0%, #2a72cf 100%);
    color: #fff;
    font-weight: 700;
    cursor: pointer;
    transition: background-color 0.25s ease, transform 0.25s ease;
}

.chatbot-input button:hover:not(:disabled) {
    background: linear-gradient(135deg, #2e69c2 0%, #69a5f2 100%);
    transform: translateY(-1px);
}

.chatbot-input button:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

@media (max-width: 768px) {
    .chatbot-panel {
        right: 10px;
        bottom: 80px;
        width: calc(100vw - 20px);
        height: 72vh;
    }
    .chatbot-toggle {
        right: 12px;
        bottom: 12px;
    }
}
}