/* Fuente personalizada */
@font-face {
    font-family: 'Roboto1';
    src: url(../fonts/Poppins-Regular.ttf);
}

/* Estilos generales */
body {
    margin: 0;
    padding: 0;
    font-family: 'Roboto1', sans-serif;
    background: #fff;
    color: #222;

    padding-top: 70px; /* Altura del header */

}

/* Encabezado */
header {
    border-bottom: 1px solid #e0e0e0;
    background: #fff;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;

    z-index: 1001; /* Mayor que el z-index de la sidebar */

}

.navbar {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 8px 32px;
    height: 50px;
}

.navbar-panel {
    display: flex;
    justify-content: space-between;
    /* separa los elementos */
    align-items: center;
    /* centra verticalmente */
    padding: 10px 20px;
    height: 50px;
}

.logo-panel img {
    height: 60px;
    width: auto;
    object-fit: contain;
}

.user-profile {
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-list {
    list-style: none;
    display: flex;
    gap: 32px;
    margin: 0;
    padding: 0;
}

.nav-list li a {
    text-decoration: none;
    color: #222;
    font-size: 1.1rem;
    padding: 8px 16px;
    border-radius: 8px;
    transition: background 0.2s;
}

.nav-list li a:hover {
    background: #d3dfe4;
    color: #222;
}

.nav-list li a.active {
    color: #222;
}

/* Contenedor principal */
.main-content {
    display: flex;
    flex-direction: column;
    min-height: 80vh;
    padding-top: 2rem;
    align-items: center;
    justify-content: center;
}

.login-container {
    display: flex;
    width: 100%;
    max-width: 1000px;
    margin: 0 auto;
    background-color: #fff;
    border-radius: 10px;
    overflow: hidden;
}

.login-left,
.login-right {
    flex: 1;
    padding: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-img {
    text-align: center;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-img img {
    width: 100%;
    max-width: 500px;
    height: auto;
    object-fit: contain;
}

.login-form {
    width: 100%;
    max-width: 400px;
}

.login-form h2 {
    text-align: center;
    margin-bottom: 2rem;
    color: #333;
}

.login-logo {
    text-align: center;
    margin-bottom: 1.5rem;
    display: none; /* Oculto por defecto en desktop */
}

.login-logo img {
    max-width: 150px;
    height: auto;
    object-fit: contain;
}

.login-form form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.login-form label {
    font-weight: 500;
    color: #555;
}

.login-form input {
    padding: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
    font-family: 'Roboto1';
}

.login-form button {
    padding: 0.8rem;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.3s;
    font-family: 'Roboto1';
}

.login-form button:hover {
    background-color: #0056b3;
}

/* Pie de página */
footer {
    text-align: center;
    padding: 18px 0 8px 0;
    color: #888;
    font-size: 1rem;
}

/* Hamburger menu styles */
.hamburger {
    display: none;
    cursor: pointer;
    padding: 10px;
}

.hamburger span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: #222;
    margin: 5px 0;
    transition: all 0.3s ease;
}

@media (max-width: 768px) {
    .navbar {
        padding: 12px 16px;
    }

    .hamburger {
        display: block;
    }

    .nav-list {
        display: flex;
        position: absolute;
        top: 70px;
        left: 0;
        width: 100%;
        background: #fff;
        flex-direction: column;
        padding: 20px;
        box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
        z-index: 1000;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.5s ease-in-out, opacity 0.3s ease-in-out;
        opacity: 0;
    }

    .nav-list.active {
        max-height: 500px;
        /* Adjust this value based on your menu height */
        opacity: 1;
    }

    .nav-list li {
        margin: 10px 0;
        opacity: 0;
        transform: translateY(-10px);
        transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out;
    }
    .botones-programar-cita {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px;
    }
    .contenedor-citas {
       width: 95%;
       margin-left: auto;
       margin-right: auto;
       padding: 10px 0;
       
    }
    .contenedor-citas .tabla-pacientes th:nth-child(1),
    .contenedor-citas .tabla-pacientes td:nth-child(1) {
        width: 5%;
    }
    
    .nav-list.active li {
        opacity: 1;
        transform: translateY(0);
    }

    /* Desplique de barra de navegacion*/
    .nav-list.active li:nth-child(1) {
        transition-delay: 0.1s;
    }

    .nav-list.active li:nth-child(2) {
        transition-delay: 0.2s;
    }

    .nav-list.active li:nth-child(3) {
        transition-delay: 0.3s;
    }

    .nav-list.active li:nth-child(4) {
        transition-delay: 0.4s;
    }

    .nav-list.active li:nth-child(5) {
        transition-delay: 0.5s;
    }

    .nav-list li a {
        display: block;
        padding: 10px;
        text-align: center;
    }

    .login-container {
        flex-direction: column;
        max-width: 100%;
        margin: 1rem;
        font-family: 'Roboto1';
    }

    .login-left {
        display: none;
        /* Esconde el logo/imagen en versiones moviles*/
    }

    .login-right {
        padding: 1rem;
    }

    .login-form {
        max-width: 100%;
    }

    .login-form h2 {
        font-size: 1.3rem;
    }
    
    .login-logo {
        display: block; /* Mostrar logo en móviles */
    }
    
    .login-logo img {
        max-width: 100px;
    }

    .login-form input {
        padding: 0.7rem;
    }

    .login-form button {
        padding: 0.7rem;
    }

    .main-content {
        padding-top: 1rem;
    }

    body {
        padding-top: 0; /* Eliminar padding-top en móviles ya que no hay header desktop */
    }

    .desktop-header {
        display: none;
    }
    
    .mobile-logo {
        display: block;
    }

    .sidebar-header {
        display: flex;
    }

    .panel-container {
        flex-direction: column;
    }

    .sidebar {
        position: relative;
        width: 100%;
        height: auto;
        top: 0;
        max-height: 80px;
        transition: max-height 0.3s ease;
        overflow: hidden; /* Evitar scroll cuando está contraído */
    }

    .sidebar.expanded {
        max-height: 100vh;
        width: 100%;
        overflow-y: auto; /* Solo permitir scroll cuando está expandido */
    }

    .toggle-btn {
        display: flex;
    }

    .toggle-btn i {
        transform: rotate(90deg);
    }

    .sidebar.expanded .toggle-btn i {
        transform: rotate(-90deg);
    }

    .menu-item span {
        opacity: 0;
        pointer-events: none;
    }

    .sidebar.expanded .menu-item span {
        opacity: 1;
        pointer-events: auto;
    }

    /* Ajustes para submenús en móvil */
    .submenu {
        max-height: 0;
        overflow: hidden;
        transition: all 0.3s ease;
        background-color: #f8f9fa;
        opacity: 0;
        pointer-events: none;
        padding-left: 0;
    }

    .submenu.active {
        max-height: 500px;
        opacity: 1;
        pointer-events: auto;
        padding-left: 15px;
    }

    .submenu-item {
        padding: 12px 20px 12px 45px;
    }

    .submenu-item a {
        text-decoration: none;
        color: inherit;
        display: block;
        width: 100%;
    }

    .panel-content {
        margin-left: 0;
        padding: 1rem;
    }

    .welcome-panel {
        padding: 1.5rem;
    }

    .welcome-panel h1 {
        font-size: 1.5rem;
    }

    .welcome-panel p {
        font-size: 1rem;
    }

    .sidebar-footer {
        margin-top: 20px;
    }
}  


/* Adicional para dispositivos mas pequeños */
@media (max-width: 480px) {
    .logo span {
        font-size: 1rem;
    }

    .login-container {
        margin: 0.5rem;
    }

    .logo-img img {
        max-width: 150px;
    }

    .login-form h2 {
        font-size: 1.3rem;
    }
}

/* Ajustes para orientación horizontal en móviles */
@media (max-width: 768px) and (orientation: landscape) {
    .quick-access {
        grid-template-columns: repeat(3, 1fr);
    }

    .welcome-panel {
        margin: 0.5rem auto;
        max-width: 90%;
    }
}

/* Estilos del Panel */
.panel-container {
    display: flex;

    min-height: calc(100vh - 70px); /* Ajustar altura considerando solo el header */

    background-color: #f5f6fa;
    position: relative;
}

/* Barra lateral */
.sidebar {
    background-color: #fff;
    color: #222;
    width: 220px;

    height: calc(100vh - 70px);
    /* Ajustar altura considerando solo el header */
    position: fixed;
    left: 0;
    top: 70px;
    /* Altura del header */
    transition: all 0.3s ease;
    overflow-y: auto;
    border-right: 1px solid #e0e0e0;
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.05);

    display: flex;
    flex-direction: column;
    z-index: 1000;
}

.sidebar.expanded {
    width: 250px;
}

/* Encabezado de la barra lateral */
.sidebar-header {
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #e0e0e0;
    white-space: nowrap;

    display: none; /* Oculto por defecto en desktop */

}

.mobile-logo {
    display: none;
}

.mobile-logo span {
    font-weight: bold;
    font-size: 1.3rem;
    line-height: 1.1;
}

/* Botón de alternar */
.toggle-btn {
    background: none;
    border: none;
    color: #222;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 5px;
    transition: color 0.3s;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    display: none;
}

.toggle-btn i {
    transition: transform 0.3s ease;
}

.sidebar.expanded .toggle-btn i {
    transform: rotate(180deg);
}

/* Elementos del menú */
.menu-item {
    padding: 15px 20px;
    display: flex;
    align-items: center;
    cursor: pointer;
    transition: all 0.3s;
    color: #222;
    white-space: nowrap;
    position: relative;
}

.menu-item i {
    width: 30px;
    font-size: 1.2rem;
    text-align: center;
    position: absolute;
    left: 20px;
    transition: transform 0.3s ease;
}

.menu-item span {
    margin-left: 45px;
    opacity: 1;
    transition: opacity 0.2s ease;
    pointer-events: auto;
}

.sidebar.expanded .menu-item span {
    opacity: 1;
    pointer-events: auto;
}

/* Submenús */
.submenu {
    max-height: 0;
    overflow: hidden;
    transition: all 0.3s ease;
    background-color: #f8f9fa;
    opacity: 0;
    pointer-events: none;
    padding-left: 0;
}

.submenu.active {
    max-height: 500px;
    opacity: 1;
    pointer-events: auto;
    padding-left: 15px;
}

.submenu-item {
    padding: 12px 20px 12px 45px;
    cursor: pointer;
    transition: all 0.3s;
    color: #555;
    font-size: 0.95rem;
    position: relative;
}

.submenu-item a {
    text-decoration: none;
    color: inherit;
    display: block;
    width: 100%;
}

.submenu-item:hover {
    background-color: #e9ecef;
    color: #007bff;
}

/* Pie de la barra lateral */
.sidebar-footer {
    margin-top: auto;
    padding-top: 10px;
}

.sidebar-footer .menu-item {
    color: #666;
}

.sidebar-footer .menu-item:hover{
    color: #007bff;
}
.sidebar-footer .fa-headset:hover{
    color: #007bff;
}
.sidebar-footer i{
    color : #db0101
}
.sidebar-footer .fa-sign-out-alt:hover{
    color: #007bff;
}

.sidebar-footer a {
    text-decoration: none;
    color: #666;
}


.sidebar-footer a:hover {
    color: #007bff;
}

/* Contenido del panel */
.panel-content {
    flex: 1;

    padding: 2rem 2rem 2rem 3rem;
    /* Aumentar el padding izquierdo */
    background-color: #f5f6fa;
    margin-left: 240px;
    /* Aumentar el margen izquierdo */

    min-height: calc(100vh - 70px);
    overflow-y: auto;
}

.welcome-panel {
    background-color: #fff;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
}

.welcome-panel h1 {
    color: #333;
    margin-bottom: 1rem;
    font-size: 1.8rem;
}

.welcome-panel p {
    color: #666;
    font-size: 1.1rem;
}

.consultorio-container {
    display: flex;
    flex-direction: row;
    gap: 40px;
    align-items: center;
    justify-content: flex-start;
    max-width: 1400px;
    margin: 0 auto;
    padding-left: 0;
}

/* Estados de la barra lateral */
.sidebar:not(.expanded) .submenu {
    max-height: 0 !important;
    opacity: 0 !important;
    pointer-events: none !important;
    padding-left: 0 !important;
}

.sidebar:not(.expanded) .menu-item.active {
    background-color: transparent;
    color: #222;
}

/* Estilos responsivos */
@media (max-width: 768px) {
    .desktop-header {
        display: none;
    }
    
    body {
        padding-top: 0; /* Eliminar padding-top en móviles ya que no hay header desktop */
    }

    .mobile-logo {
        display: block;
    }

    .sidebar-header {
        display: flex;
    }

    .panel-container {
        flex-direction: column;
    }

    .sidebar {
        position: relative;
        width: 100%;
        height: auto;
        top: 0;
        max-height: 80px;
        transition: max-height 0.3s ease;
        overflow: hidden; /* Evitar scroll cuando está contraído */
    }

    .sidebar.expanded {
        max-height: 100vh;
        width: 100%;
        overflow-y: auto; /* Solo permitir scroll cuando está expandido */
    }

    .toggle-btn {
        display: flex;
    }

    .toggle-btn i {
        transform: rotate(90deg);
    }

    .sidebar.expanded .toggle-btn i {
        transform: rotate(-90deg);
    }

    .menu-item span {
        opacity: 0;
        pointer-events: none;
    }

    .sidebar.expanded .menu-item span {
        opacity: 1;
        pointer-events: auto;
    }

    /* Ajustes para submenús en móvil */
    .submenu {
        max-height: 0;
        overflow: hidden;
        transition: all 0.3s ease;
        background-color: #f8f9fa;
        opacity: 0;
        pointer-events: none;
        padding-left: 0;
    }

    .submenu.active {
        max-height: 500px;
        opacity: 1;
        pointer-events: auto;
        padding-left: 15px;
    }

    .submenu-item {
        padding: 12px 20px 12px 45px;
    }

    .submenu-item a {
        text-decoration: none;
        color: inherit;
        display: block;
        width: 100%;
    }

    .panel-content {
        margin-left: 0;
        padding: 1rem;
    }

    .welcome-panel {
        padding: 1.5rem;
    }

    .welcome-panel h1 {
        font-size: 1.5rem;
    }

    .welcome-panel p {
        font-size: 1rem;
    }

    .sidebar-footer {
        margin-top: 20px;
    }


    /* Estilos responsivos para el consultorio */
    .consultorio-container {
        flex-direction: column;
        gap: 30px;
        padding: 20 10px;
    }

    .calendar-container {
        width: 100%;
        max-width: 400px;
        margin: 0 auto;
    }

    .schedule-table-container {
        width: 100%;
        height: 400px;
        /* Altura menor en móviles */
        overflow-y: auto;
    }
}

/* Formulario del paciente estilos */
.formulario-paciente {
    background-color: #fff;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    margin-top: 2rem; 
    max-width: 550px; 
}


/* --- Estilo para el título "Datos del paciente" --- */
.form-title-patient-data {
    color: #333;
    font-size: 1.8em;
    margin-top: 0; 
    margin-bottom: 15px; 
    padding-bottom: 5px; 
    text-align: left; 
}

.formulario-paciente h2 {
    color: #333;
    margin-bottom: 0.5rem;
    font-size: 1.5rem;
}

/* --- Estilo para la línea divisoria --- */
.form-divider-line {
    border: 0; 
    height: 1px; 
    background-color: rgba(0, 0, 0, 0.15); 
    margin-bottom: 25px; 
}

.formulario-paciente form {
  display: grid;
  grid-template-columns: auto 1fr; 
  gap: 1.5rem 2rem; 
  column-gap: 0.7rem;
  align-items: center;
}

.formulario-paciente form label {
  display: block;
  margin-bottom: 0.3rem;
  font-weight: 600;
  color: #444;
}

.formulario-paciente form input, 
.select-formulario {
  width: 100%;
  padding: 0.5rem;
  border: 1px solid #ccc;
  border-radius: 5px;
  font-size: 1rem;
  box-sizing: border-box;
}

/* Esto es para los imputs de tipo numero que no aparezcan las flechas para sumar o restar */
input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.botones-formulario,
.botones-programar-cita {
    grid-column: 1 / -1;
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    margin-top: 1.5rem;
}

.botones-formulario button, 
.botones-programar-cita button {
    padding: 0.6rem 1.2rem;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.3s ease;
    min-width: 120px;
}

.botones-formulario button:hover, 
.botones-programar-cita button:hover {
    background-color: #0056b3;
}

/* Este es el css para lista de pacientes*/
.contenedor-tabla {
    max-width: 1200px;
    max-height: 400px;
    overflow-x: auto;
    overflow-y: auto;
    margin-top: 2rem;
    /* margin-left: auto;
    margin-right: auto; */
    background-color: #fff;
    border-radius: 2px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.tabla-pacientes {
    width: 100%;
    border-collapse: collapse;
    min-width: 600px;
    cursor: pointer;
}

.tabla-pacientes th,
.tabla-pacientes td {
    padding: 0.35rem 0.50rem;
    border-bottom: 1px solid #ddd;
    text-align: left;
    white-space: nowrap;
}

.tabla-pacientes th {
    position: sticky;
    top: 0;
    z-index: 10;
    background-color: #007bff;
    font-weight: 300;
    color: white;
    border-right: 1px solid #ffffff33;
}

.tabla-pacientes tbody tr:hover {
    background-color: #f2f2f2;
}

.fila-paciente {
    position: relative;
    cursor: pointer;
}

.fila-paciente:hover .popover-acciones {
    display: flex;
    gap: 0.5rem;
}

.contenedor-tabla-botones {
    /* **ESTO ES CLAVE:** Hacemos que este contenedor actúe como un flex container */
    display: flex;
    flex-direction: column; /* Apila los elementos (tabla y botones) verticalmente */
    /* **ESTO ES CLAVE:** Limitar el ancho del contenedor padre a la tabla */
    max-width: 1200px; /* Coincidir con el max-width del .contenedor-tabla */
    width: 100%;
}

/* Estilo para el boton de abajo de Lista de Pacientes (boton Historia Clinica)*/
.historia-clinica-boton, 
.eliminar-cita-boton {
    display: flex;
    justify-content: flex-end;
    width: 100%;
    margin-top: 15px;
    margin-right: 20px;
    gap: 10px;
}

.historia-clinica-boton button, .eliminar-cita-boton button{
    padding: 0.6rem 1.2rem;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    cursor: pointer;
    transition: background-color 0.3s ease;
    min-width: 120px;
}

.historia-clinica-boton button:hover, .eliminar-cita-boton button:hover {
    background-color: #0056b3;
}

/* Estilos para el botón deshabilitado */
#btn-historia-clinica:disabled,
#btn-eliminar-cita:disabled,
#btn-modificar-paciente:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/*Estilos para Programar Citas. Formulario y la tabla con las citas*/
.contenedor-programar-cita {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 2rem;
    align-items: stretch;
}

.formulario-cita {
    background-color: #fff;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    margin-top: 2rem;
    max-width: 600px;
    width: 100%;
    box-sizing: border-box;
}

.formulario-cita form {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 1.5rem 2rem;
    column-gap: 0.7rem;
    align-items: center;
}

.formulario-cita form label {
    display: block;
    margin-bottom: 0.3rem;
    font-weight: 600;
    color: #444;
}

.formulario-cita form input,
.formulario-cita form select {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 1rem;
    box-sizing: border-box;
}

/* Estilo para la fila seleccionada */
.tabla-pacientes tbody tr.fila-seleccionada {
    background-color: #e0f7fa; /* Un azul claro, puedes elegir tu color */
    font-weight: bold; /* Opcional: hacer el texto más negrita */
    border: 1px solid #007bff; /* Un borde para resaltarla */
}

/* Estilos para el botón deshabilitado */
#btn-historia-clinica:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

#btn-eliminar-cita:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}


/* Calendar specific styles - These are critical for the calendar to work */
.calendar-container {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    padding: 24px;
    width: 380px;
    flex-shrink: 0;
    /* Evita que el calendario se encoja */
    margin-left: -60px;
    /* Mueve el calendario más a la izquierda */
    align-self: center;
    /* Centra el calendario verticalmente */
}

.calendar-header {
    text-align: center;
    margin-bottom: 20px;
}

.calendar-title {
    font-size: 18px;
    font-weight: 500;
    color: #333;
    margin-bottom: 12px;
}

.date-picker {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 20px;
}

.date-input {
    border: none;
    background: none;
    font-size: 14px;
    color: #666;
    cursor: pointer;
    padding: 4px;
}

.calendar-icon {
    width: 16px;
    height: 16px;
    color: #666;
}

.month-year-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.month-year {
    font-size: 16px;
    font-weight: 600;
    color: #333;
}

.nav-button {
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    color: #666;
    font-size: 18px;
}

.nav-button:hover {
    color: #333;
}

/* IMPORTANT: These grid styles are essential for the calendar to display properly */
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
}

.day-header {
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    color: #666;
    padding: 8px 4px;
}

/* CRITICAL: These styles are needed for the day cells that are created by JavaScript */
.day-cell {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.2s ease;
    position: relative;
}

.day-cell:hover {
    background-color: #f0f0f0;
}

.day-cell.current-month {
    color: #333;
}

.day-cell.other-month {
    color: #ccc;
}

.day-cell.selected {
    background-color: #1976d2;
    color: white;
}

.day-cell.selected:hover {
    background-color: #1565c0;
}

.day-cell.today {
    background-color: #e3f2fd;
    color: #1976d2;
    font-weight: 600;
}

.consultorio-section {
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

/* Style for the schedule table (simplified) */
.schedule-table-container {
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    padding: 30px;
    flex: 1;
    /* Toma el espacio restante */
    min-width: 0;
    /* Permite que se encoja si es necesario */
    height: 600px;
    /* Altura fija en lugar de min-height */
    width: 100%;
    overflow-y: auto;
    /* Genera scrollbar vertical cuando el contenido excede la altura */
}

.schedule-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.schedule-table th,
.schedule-table td {
    padding: 15px;
    border-bottom: 1px solid #eee;
    text-align: left;
}

.schedule-table th {
    background-color: #007bff;
    color: white;
    font-weight: 600;
    font-size: 16px;
}

.schedule-table td {
    font-size: 14px;
    padding: 20px 15px;
}

.time-col {
    width: 100px;
    font-weight: 600;
    color: #333;
}

/* Estilos para los diferentes estados de consulta */
.schedule-table tr.estado-1 {
    background-color: #fff3cd;
    border-left: 4px solid #ffc107;
}

.schedule-table tr.estado-1:hover {
    background-color: #ffeaa7;
}

.schedule-table tr.estado-2 {
    background-color: #d1ecf1;
    border-left: 4px solid #17a2b8;
}

.schedule-table tr.estado-2:hover {
    background-color: #b8e6f3;
}

.schedule-table tr.estado-3 {
    background-color: #f8d7da;
    border-left: 4px solid #dc3545;
}

.schedule-table tr.estado-3:hover {
    background-color: #f5c6cb;
}

/* Estilos para filas seleccionadas */
.schedule-table tr.seleccionada {
    background-color: #e3f2fd !important;
    border: 2px solid #2196f3 !important;
    box-shadow: 0 2px 8px rgba(33, 150, 243, 0.3);
}

.schedule-table tr.seleccionada:hover {
    background-color: #bbdefb !important;
}
.footer-buttons button {
    width: 150px;
    padding: 10px 20px;
    font-size: 16px;
    margin: 5px;
    border-radius: 5px;
}
.btn-atendido {
    background-color: #b8e6f3;  
}
.btn-pendiente {
    background-color: #ffeaa7;  
}
.btn-cancelado {
    background-color: #f5c6cb;  
}
/* Estilos para botones deshabilitados */
.footer-buttons button:disabled {
    background-color: #6c757d;
    cursor: not-allowed;
    opacity: 0.6;
}

.footer-buttons button:disabled:hover {
    background-color: #6c757d;
}

/* Estilos para botones habilitados */
.footer-buttons button:not(:disabled) {
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.footer-buttons button:not(:disabled):hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

