/* General Styles */
.table {
  border-collapse: collapse;
  font-size: 15px;
  table-layout: auto;
  width: 100%;
}

.bd-toggle-position {
  z-index: 1500;
}

#main_body {
  margin-left: 20px;
  margin-top: 20px;
  margin-right: 20px;
}
.flag-alert {
    color: red;
    animation: glow 1.5s infinite alternate;
}

@keyframes glow {
    from {
        text-shadow: 0 0 5px red;
    }
    to {
        text-shadow: 0 0 15px red;
    }
}

.error-text {
  color: YELLOW;
  font-weight: bold;
}

.text-align-center {
  text-align: center;
}

.azulado {
  color: #0d6efd;
}
.golden {
  color: #bd991e;
}
.green {
  color: green;
}
.yellow {
  color: yellow;
}
.red {
  color: red;
}
.azul {
  color: #1d65a8;
}

#alertModal {
  z-index: 9999 !important;
}
.bgc-aux {
  background-color: lemonchiffon;
}

.superaux {
  display: inline-block;
  text-align: center;
  border: 2px solid darkgoldenrod;
  padding: 10px;
}
.br15 {
  border-radius: 15px;
}

.mitad {
  width: 50%;
}

.fs10 {
  font-size: 10px;
}
.fs12 {
  font-size: 12px;
}
.fs20 {
  font-size: 20px;
}
.fs30 {
  font-size: 30px;
}

.w121 {
  min-width: 121px;
}

.hp-column {
  display: block;
  align-items: center;
  text-align: center;
}

.makeup-container {
  max-height: 500px;
  overflow-y: auto;
}

.mh520 {
  max-height: 520px;
  overflow-y: auto;
}

.f1 {
  flex: 1;
}

.bcagenda2 {
  background-color: #3599b0;
}

.bgc-white {
  background-color: #f8f9fa;
}

#makeup-container {
  max-height: 500px;
  overflow-y: auto;
}

#TEST-PERCHANGE {
  width: auto;
  text-align: center;
  margin: auto;
  font-size: 13px;
}

.navbar-text {
  font-size: 15px;
  width: 100%;
  text-align: center;
  padding-top: 0px;
  padding-bottom: 0px;
}

#mini-info {
  font-size: 10px;
  width: 100%;
  text-align: center;
}

.width-20 {
  width: 20px;
}
.width-30 {
  width: 30px;
}
.width-50 {
  width: 50px;
}
.width-60 {
  width: 60px;
}
.width-80 {
  width: 80px;
}
.width-100 {
  width: 100px;
}
.width-110 {
  width: 110px;
}
.width-120 {
  width: 120px;
}
.width-130 {
  width: 130px;
}
.width-140 {
  width: 140px;
}
.width-150 {
  width: 150px;
}
.width-180 {
  width: 180px;
}
.width-200 {
  width: 200px;
}
.width-250 {
  width: 250px;
}
.width-300 {
  width: 300px;
}
.width-350 {
  width: 350px;
}
.width-400 {
  width: 400px;
}

.h20 {
  height: 20px;
}

.nav-link {
  font-size: 14px;
}

.mw800 {
  max-width: 800px;
}
.mw1000 {
  max-width: 1000px;
}

.table td,
.table th {
  padding-top: 2px;
  padding-bottom: 2px;
  padding-right: 5px;
  padding-left: 5px;
}

[data-bs-theme="dark"] .navbar-collapse {
  background-color: #2b3035;
}

[data-bs-theme="dark"] .card-body {
  background-color: #212529;
}

[data-bs-theme="light"] .navbar-collapse {
  background-color: #c8dfef;
}

[data-bs-theme="light"] .navbar {
  background-color: #c8dfef !important;
}

[data-bs-theme="light"] body,
.card-body {
  background-color: aliceblue;
}

[data-bs-theme="light"] #tabla-container table {
  --bs-table-bg: aliceblue; /* Alice Blue más oscuro */
  background-color: var(--bs-table-bg);
}

hr {
  margin-top: 0.2em; /* Margen superior */
  margin-bottom: 0.3em; /* Margen inferior */
}

body {
  padding-top: 60px; /* Ajusta según la altura de tu navbar */
}

#btnFiltrar {
  margin-bottom: 10px;
  padding: 10px 15px;
  font-size: 16px;
  width: 100%;
}

/* Base general para las columnas fijas */
.sticky-column:nth-child(1) {
  position: sticky;
  z-index: 1000; /* Asegúrate de que sea menor que el del dropdown */
  left: 0;
  white-space: nowrap;
}

/* Estilo base para las columnas adicionales */
.sticky-column:nth-child(2) {
  position: sticky;
  left: 43px; /* Ajusta según el ancho de la columna 1 */
}

.sticky-column:nth-child(3) {
  position: sticky;
  left: 83px; /* Ajusta según el ancho de las columnas 1 y 2 */
}

.sticky-column:nth-child(4) {
  position: sticky;
  left: 370px; /* Ajusta según el ancho de las columnas 1, 2 y 3 */
}
.sticky-column:nth-child(5) {
  position: sticky;
  left: 430px; /* Ajusta según el ancho de las columnas 1, 2 y 3 */
}

/* Estilo único para la columna "Nombre" */
.nombre-column {
  width: 200px; /* Ajusta el valor según tus necesidades */
  min-width: 300px; /* Para asegurarte de que el ancho no sea menor */
  max-width: 300px; /* Opcional: evita que se expanda más */
  text-align: left; /* Ajusta la alineación del texto si es necesario */
}
/* Estilo único para la columna "Nombre" */
.dia-column {
  min-width: 80px; /* Para asegurarte de que el ancho no sea menor */
  max-width: 80px; /* Opcional: evita que se expanda más */
  text-align: center; /* Ajusta la alineación del texto si es necesario */
  border-width: 0 2px 0px 2px;
  align-items: center;
}

.total-column {
  min-width: 100px; /* Para asegurarte de que el ancho no sea menor */
  max-width: 100px; /* Opcional: evita que se expanda más */
  text-align: center; /* Ajusta la alineación del texto si es necesario */
  border-width: 0 2px 0px 2px;
}

.table-warning {
  background-color: #d39e00 !important; /* Cambia a un tono más oscuro */
}

.table-warning-sombreado {
  background-color: #e0a800 !important; /* Tono más oscuro que el amarillo de Bootstrap */
}

.table-warning-sombreado td {
  opacity: 0.5; /* Reduce la opacidad del texto */
}

.table-warning-sombreado .sticky-column {
  opacity: 1; /* Reduce la opacidad del texto */
  background-color: #7f6518;
  color: rgba(255, 255, 255, 0.7);
}

.table-danger {
  --bs-table-striped-bg: #b6424c !important;
  --bs-table-striped-color: #fff !important;
  --bs-table-bg: #b6424c !important;
  --bs-table-color: #fff !important;
  --bs-table-border: none !important;
  border-color: none;
}

.table-danger-sombreado {
  background-color: #c60909 !important; /* Tono más oscuro que el amarillo de Bootstrap */
  --bs-table-color: #000000 !important;
}

.table-danger-sombreado td {
  opacity: 0.5; /* Reduce la opacidad del texto */
}

.table-danger-sombreado .sticky-column {
  opacity: 1; /* Reduce la opacidad del texto */
  background-color: #641616;
  color: rgba(255, 255, 255, 0.7);
}

/* Aplica solo cuando el tema es "light" */
[data-bs-theme="light"] {
  .table-warning {
    background-color: #d39e00 !important; /* Cambia a un tono más oscuro */
  }

  .table-warning-sombreado {
    background-color: #e0a800 !important; /* Tono más oscuro que el amarillo de Bootstrap */
  }

  .table-warning-sombreado td {
    opacity: 0.5; /* Reduce la opacidad del texto */
  }

  .table-warning-sombreado .sticky-column {
    opacity: 1;
    background-color: #f0d995;
    color: rgba(255, 255, 255, 0.7);
  }

  .table-danger {
    --bs-table-striped-bg: #b6424c !important;
    --bs-table-striped-color: #fff !important;
    --bs-table-bg: #b6424c !important;
    --bs-table-color: #fff !important;
    --bs-table-border: none !important;
    border-color: none;
  }

  .table-danger-sombreado {
    background-color: #c60909 !important;
    --bs-table-color: #000000 !important;
  }

  .table-danger-sombreado td {
    opacity: 0.5;
  }

  .table-danger-sombreado .sticky-column {
    opacity: 1;
    background-color: #de8787;
    color: rgba(255, 255, 255, 0.7);
  }
}

.table-secondary {
  --bs-table-striped-bg: silver !important;
  --bs-table-striped-color: #000000 !important;
  --bs-table-bg: silver !important;
  --bs-table-color: #030303 !important;
  --bs-table-border: none !important;
  border-color: none;
}

#editarModal .form-control,
#editarModal .input-group-text {
  font-size: 14px;
}

#editarModal .input-group-text {
  min-width: 80px;
  display: flex;
}

#editarModal .nav-link {
  font-size: 12px;
}

#Seccion {
  font-size: 16px;
  margin: 0 20px;
  color: #2d669d;
  font-weight: bold;
}

.modal {
  z-index: 1050; /* Valor base de Bootstrap */
}

.modal-backdrop {
  z-index: 1049; /* Asegura que el fondo del modal esté detrás del primero */
}

.modal-superpuesto {
  z-index: 1060; /* Asegura que el nuevo modal esté encima del anterior */
}

.dropdown-menu .dropdown-item:hover {
  background-color: aliceblue;
  color: black;
}

.sort-link {
  font-weight: bold;
  text-decoration: none;
  color: #176dec;
}

#search-collapse .card-body {
  --bs-card-border-color: transparent;
  padding: 0;
}
#search-collapse2 .card-body {
  --bs-card-border-color: transparent;
  padding: 0;
}

#search-form {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-bottom: 10px;
}
#search-form2 {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 15px;
  margin-bottom: 5px;
}

#search-term,
#search-column,
#show-rows {
  border-radius: var(--bs-border-radius);
  font-size: 18px;
  width: 100%;
}

.pagination .current-page {
  padding: var(--bs-pagination-padding-y) var(--bs-pagination-padding-x);
  font-weight: bold;
  font-size: var(--bs-pagination-font-size);
  color: #eeeef1;
  background-color: #0d6efd;
  border: var(--bs-pagination-border-width) solid
    var(--bs-pagination-border-color);
}

#tabla-container {
  overflow-x: auto;
}

.tabla-container th {
  white-space: normal; /* Permite saltos de línea */
  text-align: center; /* Opcional, según el diseño deseado */
  vertical-align: middle;
}

.tabla-container td {
  white-space: normal; /* Permite saltos de línea */
  vertical-align: middle;
}

.table th,
.table td {
  font-size: 12px; /* Agrega espacio interno */
  vertical-align: middle;
  white-space: normal;
}

/* Para pantallas entre 768px y 1200px */
@media (min-width: 768px) and (max-width: 1400px) {
  body {
    padding-top: 60px;
  }

  .sticky-column:nth-child(2) {
    left: 44px; /* Ajuste intermedio */
  }
  .sticky-column:nth-child(3) {
    left: 85px; /* Ajuste intermedio */
  }
  .sticky-column:nth-child(4) {
    left: 190px; /* Ajuste intermedio */
  }
  .sticky-column:nth-child(5) {
    left: 433px; /* Ajuste intermedio */
  }
  #info2 {
    width: 100%;
    text-align: center;
  }

  #Mensaje {
    margin-left: 0px;
    width: 100%;
    text-align: center;
  }

  .nombre-column {
    font-size: larger;
    width: 110px; /* Reduce el ancho para pantallas pequeñas */
    min-width: 110px; /* Ajusta el ancho mínimo */
    max-width: 110px; /* Ajusta el ancho máximo */
  }
}

.f-auto {
  flex: auto;
}

/* Para pantallas mayores a 1200px (escritorios o pantallas grandes) */
@media (min-width: 1200px) {
  .nombre-column {
    font-size: larger;
    width: 220px; /* Aumenta ligeramente el ancho */
    min-width: 300px; /* Mantén un ancho mínimo mayor */
    max-width: 350px; /* Permite un ancho máximo más amplio */
  }

  #tabla-container {
    overflow-x: auto;
  }
}

/* Responsive Adjustments */
@media (max-width: 990px) {
  .table th,
  .table td {
    font-size: 12px;
  }

  body {
    padding-top: 60px;
  }

  #info {
    margin: 0px;
    width: 100%;
    text-align: center;
  }

  #info2 {
    width: 100%;
    text-align: center;
  }

  #search-form {
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
  }

  #search-form2 {
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
  }

  .pagination .page-link,
  .pagination .current-page {
    padding: 5px 10px;
    font-size: 12px;
  }

  .navbar-text {
    font-size: 14px;
    width: 100%;
    text-align: center;
  }

  .nav-link {
    font-size: 15px;
  }

  .navbar .dropdown-menu {
    position: absolute !important;
    left: 0;
    right: auto;
    z-index: 1200; /* Asegura que esté por encima del contenido */
  }
  .navbar-collapse {
    position: absolute !important;
    top: 100%;
    left: 0;
    width: 100%;
    z-index: 1050;
  }

  .navbar > .container-fluid {
    flex-wrap: nowrap;
  }
}

/* Para pantallas menores a 768px */
@media (min-width: 577px) and (max-width: 768px) {
  body {
    padding-top: 60px;
  }

  .sticky-column:nth-child(2) {
    left: 0px; /* Ajusta para columnas más estrechas */
  }
  .sticky-column:nth-child(3) {
    left: 1px; /* Ajusta según el ancho reducido */
  }
  .sticky-column:nth-child(4) {
    left: 100px; /* Ajusta según el ancho reducido */
  }
  .sticky-column:nth-child(5) {
    left: 100px; /* Ajuste intermedio */
  }

  .nombre-column {
    font-size: larger;
    width: 100px; /* Reduce el ancho para pantallas pequeñas */
    min-width: 100px; /* Ajusta el ancho mínimo */
    max-width: 100px; /* Ajusta el ancho máximo */
  }

  .table th,
  .table td {
    font-size: 12px;
  }

  #search-form {
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
  }

  #search-form2 {
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
  }

  .pagination .page-link,
  .pagination .current-page {
    padding: 5px 10px;
    font-size: 12px;
  }

  .navbar-text {
    font-size: 14px;
    width: 100%;
    text-align: center;
  }

  .nav-link {
    font-size: 15px;
  }
}
@media (min-width: 340px) and (max-width: 768px) {
  .sticky-column:nth-child(2) {
    left: 0px; /* Ajusta para columnas más estrechas */
  }
  .sticky-column:nth-child(3) {
    left: 1px; /* Ajusta según el ancho reducido */
    z-index: 1001;
  }
  .sticky-column:nth-child(4) {
    left: 1px; /* Ajusta según el ancho reducido */
  }
  .sticky-column:nth-child(5) {
    left: 1px; /* Ajuste intermedio */
  }
  .nombre-column {
    font-size: larger;
    width: 100px; /* Reduce el ancho para pantallas pequeñas */
    min-width: 130px; /* Ajusta el ancho mínimo */
    max-width: 130px; /* Ajusta el ancho máximo */
  }
}
@media (min-width: 481px) and (max-width: 576px) {
  body {
    padding-top: 100px;
  }

  .pagination {
    font-size: 10px;
  }

  .navbar-text {
    font-size: 12px;
    line-height: 1.2;
    width: 100%;
    text-align: center;
  }

  .nav-link {
    font-size: 15px;
  }

  .navbar .dropdown-menu {
    position: absolute !important;
    left: 0;
    right: auto;
    z-index: 1050; /* Asegura que esté por encima del contenido */
  }

  .navbar-collapse {
    position: absolute !important;
    top: 100%;
    left: 0;
    width: 100%;
    z-index: 1050;
  }

  .navbar > .container-fluid {
    flex-wrap: wrap;
  }
}

@media (max-width: 480px) {
  body {
    padding-top: 110px;
  }

  #search-term,
  #search-column,
  #show-rows {
    font-size: 18px;
    width: 100%;
  }
  #tabla-container td,
  #tabla-container th {
    font-size: 12px;
  }
  #search-form .btn-primary {
    font-size: smaller;
  }

  .navbar-text {
    width: 100%;
    text-align: center;
    font-size: 10px;
  }

  .navbar-toggler-icon {
    width: 20px;
    height: 20px;
    padding: 0px;
  }

  .btn-personalizado {
    font-size: small; /* o el tamaño que necesites */
  }

  .navbar > .container-fluid {
    flex-wrap: wrap;
  }
}
