/* General */
html, body {
  margin-top: 45;
  padding: 10;
  overflow-x: hidden;
  font-family: 'Inter', sans-serif;
}


.filter label {
    display: flex;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
}

input, select, button {
    padding: 5px;
    font-size: 14px;
}

button.btn {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
}

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

.btn {
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 4px;
    background-color: #007bff;
    color: white;
    white-space: nowrap;
}

.btn-logout {
    background-color: #dc3545;
}

.btn-logout:hover {
    background-color: #b52a38;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    background-color: white;
}

th, td {
    padding: 3px;
    border: 1px solid #ccc;
    text-align: center;
}

th {
    background-color: #f0f0f0;
}

.pagination {
    margin-top: 15px;
    text-align: center;
}

.pagination a {
    margin: 0 4px;
    text-decoration: none;
    padding: 5px 10px;
    background: #007bff;
    color: white;
    border-radius: 4px;
}

.pagination a.active {
    background: #0056b3;
}

.top-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    background: white;
}

th, td {
    border: 1px solid #ccc;
    padding: 1px;
    text-align: center;
}

th {
    background-color: #eee;
}

input[type="text"],
input[type="password"],
input[type="number"],
select {
    width: 90%;
    padding: 5px;
    box-sizing: border-box;
}
.btn-restart {
    background-color: #ff9800;
    color: white;
    border: none;
    outline: none;
    border-radius: 4px;
    padding: 8px 12px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s ease;
}
.btn-restart:hover {
    background-color: #e68900;
}

.btn-update {
    background-color: #007bff;
    color: white;
    border: none;
    outline: none;
    border-radius: 4px;
    padding: 8px 12px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s ease;
}
.btn-update:hover {
    background-color: #0069d9;
}

.btn-history {
    background-color: #6f42c1;
    color: white;
    border: none;
    outline: none;
    border-radius: 4px;
    padding: 8px 12px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s ease;
}
.btn-history:hover {
    background-color: #5936a3;
}

.btns {
    display: inline-block;
    padding: 8px 12px;
    margin: 5px 0;
    background-color: #034f17 !important; /* fuerza color */
    color: white !important;
    border: none;
    border-radius: 4px;
    text-decoration: none;
    font-weight: bold;
    text-align: center;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.btns:hover {
    background-color: #2d7540 !important;
}

/* Botones */
.btn {
    display: inline-block;
    padding: 8px 12px;
    margin: 5px 0;
    background-color: #007bff;
    color: white;
    border-radius: 4px;
    text-decoration: none;
    font-weight: bold;
    text-align: center;
    transition: background-color 0.3s ease;
}

.btn:hover {
    background-color: #0056b3;
}

.btn-danger {
    background-color: #dc3545;
}

.btn-danger:hover {
    background-color: #b52a38;
}

.btn-success {
    background-color: #28a745;
}

.btn-success:hover {
    background-color: #218838;
}

.btn-volver {
    background-color: #eb4034;
    color: white;
}

.btn-volver:hover {
    background-color: #9c3028;
}

.btn-logout {
    background-color: #dc3545;
}

.btn-logout:hover {
    background-color: #b52a38;
}

.topbar {
    display: flex;
	
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    flex-wrap: wrap;
}

.topbar-left {
    flex: 1;
}

.topbar-form {
    display: flex;
    flex-wrap: nowrap; /* fuerza que no se bajen */
    gap: 10px;
    align-items: center;
    justify-content: flex-start;
}

.topbar-form .btn {
    padding: 10px 5px;
    font-size: 14px;
    white-space: nowrap;
    flex: 0 1 auto; /* evita que se expandan o contraigan demasiado */
}

/* Opcional: ajustes móviles */
@media screen and (max-width: 600px) {
    .topbar-form {
        justify-content: center;
        gap: 8px;
    }

    .topbar-form .btn {
        font-size: 13px;
        padding: 5px 10px;
    }
}

.usuario {
    font-weight: bold;
    margin-right: 5px;
    white-space: nowrap;
}

/* Formularios */
form.filter {
    margin-bottom: 20px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

/* Paginación */
.pagination a {
    margin: 0 4px;
    text-decoration: none;
    padding: 5px 10px;
    background: #007bff;
    color: white;
    border-radius: 4px;
}

.pagination a.active {
    background: #0056b3;
}

/* Mensajes */
.mensaje {
    margin: 10px 0;
    font-weight: bold;
    color: green;
    padding: 10px;
    background: #e2e3e5;
    border-left: 5px solid #6c757d;
}

/* Gráfica */
#graficaDesktop {
    max-width: 300px;
    max-height: 500px;
    width: 100%;
    margin: 0 auto;
    display: block;
}

/* Otros */
.top-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 10px;
}

.form-usuario-container {
    display: flex;
    gap: 30px;
    align-items: flex-start;
    flex-wrap: wrap;
    border: 1px solid #ccc;
    padding: 20px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 7px rgba(0,0,0,0.05);
}
.dashboard-contenedor {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
    margin-top: 85px;
}

.tarjeta {
    background-color: white;
    border: 1px solid #ccc;
    border-radius: 8px;
    padding: 5px;
    text-align: center;
    flex: 1 1 300px; /* mínimo 250px por tarjeta */
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    max-width: 300px;
}


.grafica-contenedor {
    position: relative;
    width: 100%;
    max-width: 500px;
    margin: auto;
}

#graficaLlamadas {
    width: 100% !important;
    height: auto !important;
}
/* Para escritorio: tarjetas en fila horizontal */
.tarjetas-container {
    display: flex;
	width: 1920px;
    justify-content: center;
    gap: 20px;
    padding: 1px;
}

/* Responsive */
@media (max-width: 768px) {
    .tarjetas-container {
        flex-direction: column;
        align-items: center;
    }

    .tarjeta {
        max-width: 100%;
        width: 99%;
    }
}


.mensaje {
    padding: 10px 15px;
    margin: 15px auto;
    border-radius: 4px;
    font-weight: bold;
    text-align: center;
    max-width: 600px;
}

.mensaje-error {
    background-color: #f8d7da;
    color: #842029;
    border: 1px solid #f5c2c7;
}

.mensaje-exito {
    background-color: #d1e7dd;
    color: #0f5132;
    border: 1px solid #badbcc;
}
/* Estilo responsive para tabla y gráfica */
@media (max-width: 768px) {
    .tabla-grafica-container {
        display: flex;
        flex-direction: column;
        gap: 20px;
    }

    .tabla-grafica-container table {
        width: 100%;
        font-size: 14px;
        overflow-x: auto;
    }

    .tabla-grafica-container canvas {
        width: 100% !important;
        height: auto !important;
        max-width: 100%;
    }

    .tarjeta {
        padding: 10px;
        box-sizing: border-box;
        margin: 0 auto;
    }

    .toolbar select {
        width: 100%;
    }
}
/* Estilo específico para la página de login */
.login-container {
    max-width: 400px;
    margin: 60px auto;
    background-color: #ffffff;
    padding: 30px 25px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

.login-container h2 {
    text-align: center;
    margin-bottom: 20px;
}

.login-container label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.login-container input[type="text"],
.login-container input[type="password"] {
    width: 100%;
    padding: 10px;
    margin-bottom: 15px;
    border-radius: 4px;
    border: 1px solid #ccc;
}

.login-container input[type="submit"] {
    width: 100%;
    padding: 10px;
    background-color: #007bff;
    border: none;
    color: white;
    border-radius: 4px;
    font-weight: bold;
    cursor: pointer;
}

.login-container input[type="submit"]:hover {
    background-color: #0056b3;
}

/* Responsive */
@media screen and (max-width: 480px) {
    .login-container {
        margin: 30px 15px;
        padding: 20px;
    }
}
/* Mostrar solo en escritorio */
	.tabla-escritorio {
		display: flex;
		width: 90%;
	}

.tabla-movil {
    display: none;
}

/* Mostrar solo en móviles */
@media (max-width: 768px) {
    .tabla-escritorio {
        display: none !important;
    }

    .tabla-movil {
        display: flex !important;
        flex-direction: column;
    }
	

    .tabla-movil table {
        width: 100%;
    }
	.tabla-movil td, .tabla-movil th {
		min-width: 80px;
	}
}
.form-vertical {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 500px;
}

.form-vertical .form-group {
    display: flex;
    flex-direction: column;
}

.form-vertical input,
.form-vertical select,
.form-vertical button {
    padding: 8px;
    font-size: 14px;
    width: 100%;
    box-sizing: border-box;
}

.form-vertical button {
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}
}

.filter {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    flex: 1;
}

.exportar-container {
    display: flex;
    align-items: center;
}

.exportar-container .btn {
    white-space: nowrap;
}


.filter label {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-right: 0px;
    white-space: nowrap;
}

.filter input,
.filter select,
.filter button,
.filter .btn {
    padding: 5px;
    font-size: 14px;
}
/* Estilos generales */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background-color: #757575;
    color: #fff;
    padding: 10px 10px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: nowrap; /* evita saltos de línea */
    box-shadow: 0 5px 5px rgba(0,0,0,0.2);
    z-index: 1000;
    font-family: 'Inter', sans-serif; /* opcional, moderna */
}

.navbar-logo {
    font-weight: bold;
    font-size: 20px;
    margin-right: 20px;
    white-space: nowrap;
}

.navbar-links {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: nowrap;
    overflow-x: auto; /* para que no se rompa en pantallas pequeñas */
}

.navbar-lang-user {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-left: 20px;
    white-space: nowrap;
}

.navbar-toggle {
    display: none; /* ocultamos hamburguesa si no es necesario */
}

/* Responsive */
@media (max-width: 768px) {
  .navbar {
    flex-wrap: wrap;
  }

  .navbar-toggle {
    display: block;
  }

  .navbar-links {
    display: none;
    flex-direction: column;
    width: 100%;
    margin-top: 10px;
  }

  .navbar-links.show {
    display: flex;
  }

  .navbar-links a.btn {
    width: 100%;
    box-sizing: border-box;
    text-align: left;
    margin: 4px 0;
  }

  .navbar-lang-user {
    width: 100%;
    text-align: left;
    margin-top: 10px;
    padding-left: 0;
  }
}
 box-sizing: border-box;
}


/* Botón Exportar al final */
.exportar-container {
    margin-left: auto;
}

/* Espacio al contenido debajo del filtro */
main, .contenido-principal {
    margin-top: 120px; /* Ajustar según altura de navbar + filtros */
}

/* Responsive: filtro en columna en móviles */
@media (max-width: 768px) {
    .filtros-container {
        flex-direction: column;
        align-items: stretch;
    }

    .exportar-container {
        margin-left: 0;
        width: 100%;
    }

    .filtros-container form.filter label {
        flex-direction: column;
        align-items: flex-start;
    }
}

/* Aplicar tipografía moderna */
body {
    font-family: 'Inter', sans-serif;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    background-color: #f5f5f5;
    color: #333;
}

/* Contenedor de filtros */
.filtros-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
    padding: 15px;
    background-color: #fff;
    position: sticky;
    top: 10px;
    z-index: 999;
    border-bottom: 1px solid #ccc;
}

.filter {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: flex-end;
    flex: 1;
}

.filter label {
    display: flex;
    flex-direction: column;
    font-size: 14px;
    min-width: 120px;
}

.filter input, .filter select {
    padding: 5px;
    font-size: 14px;
    border-radius: 4px;
    border: 1px solid #ccc;
}

.exportar-container {
    display: flex;
    align-items: flex-end;
}

.exportar-container .btn {
    padding: 8px 12px;
    background-color: #007bff;
    border-radius: 4px;
    color: white;
    text-decoration: none;
}

/* Tabla */
table {
    width: 97%;
    border-collapse: collapse;
    margin: 20px 0;
    background: white;
}

table th, table td {
    border: 1px solid #ccc;
    padding: 8px;
    text-align: center;
    font-size: 14px;
}

table th {
    background-color: #f0f0f0;
}

/* Responsive tabla */
@media (max-width: 768px) {
    table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }

    .filtros-container {
        flex-direction: column;
        align-items: stretch;
    }

    .filter {
        flex-direction: column;
    }

    .exportar-container {
        justify-content: flex-end;
    }
}

/* Paginación */
.pagination {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    justify-content: center;
    padding: 10px;
}

.pagination a {
    padding: 6px 12px;
    text-decoration: none;
    border: 1px solid #007bff;
    border-radius: 4px;
    color: #007bff;
}

.pagination a.active {
    background-color: #007bff;
    color: white;
}
.fixed-filter {
    position: sticky;
    top: 0px; /* ajusta esto a la altura real de tu navbar */
    background-color: #f9f9f9; /* o el color de fondo que uses */
    z-index: 999;
    padding: 10px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

/* ---Filtro */
.filtro-tarjeta {
    background-color: #fdfdfd;
    border: 1px solid #ddd;
    border-radius: 10px;
    padding: 20px;
    margin: 20px auto;
    max-width: 1000px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    font-family: 'Inter', sans-serif;
}

.filtro-formulario {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: space-between;
}

.filtro-campo {
    flex: 1 1 200px;
    min-width: 200px;
}

.filtro-campo label {
    display: block;
    font-weight: 600;
    margin-bottom: 5px;
}

.filtro-campo input,
.filtro-campo select {
    width: 100%;
    padding: 8px 10px;
    border-radius: 4px;
    border: 1px solid #ccc;
    box-sizing: border-box;
}

.filtro-botones {
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 10px;
}

.filtro-botones .btn {
    padding: 10px 14px;
    background-color: #2e7d32;
    color: white;
    border: none;
    border-radius: 4px;
    text-decoration: none;
    cursor: pointer;
}

.filtro-botones .btn-secundario {
    background-color: #1976d2;
}

.filtro-botones .btn:hover {
    opacity: 0.9;
}

@media (max-width: 768px) {
    .filtro-botones {
        justify-content: center;
    }
}