/**
 * jQuery Sticky Table Headers - v3.0.0
 * https://github.com/jpchip/stickytable
 */
.sticky-wrap {
	overflow-x: auto;
	overflow-y: hidden;
	position: relative;
	width: 100%;
}

.sticky-thead {
  opacity: 1 !important;
}

table.sticky-enabled thead {
  visibility: hidden;
}
.sticky-wrap .sticky-thead,
.sticky-wrap .sticky-col,
.sticky-wrap .sticky-intersect {
	opacity: 0;
	position: absolute;
	top: 0;
	left: 0;
	z-index: 9;
	width: auto; /* Prevent table from stretching to full size */
}
	.sticky-wrap .sticky-thead {
		box-shadow: 0 0.25em 0.1em -0.1em rgba(0,0,0,.125);
		z-index: 100;
		width: 100%; /* Force stretch */
	}
	.sticky-wrap .sticky-intersect {
		opacity: 1;
		z-index: 150;

	}
		.sticky-wrap .sticky-intersect th {
			background-color: #666;
			color: #eee;
		}
.sticky-wrap td,
.sticky-wrap th {
	box-sizing: border-box;
}

.sticky-wrap th {
background-color:#FFFFFF;
}

/* assumes container element has set height... */
.sticky-wrap.overflow-y {
	overflow-y: auto;
	max-height:100%;
}

/* Contenedor flexible que permite envolver elementos */
.sticky-search-container {
  display: flex;
  flex-wrap: wrap; /* Permite que se acomode en varias líneas */
  gap: 0.5rem;      /* Espacio entre elementos */
  align-items: center;
  justify-content: space-between;
  width: 100%;
  margin-bottom: 0.5rem;
}

/* Cada grupo de botones o selectores */
.sticky-search-container > div,
.sticky-search-container > input,
.sticky-search-container > select {
  flex: 1 1 auto; /* Se adapta al ancho disponible */
  min-width: 180px; /* No colapsa demasiado */
}

/* Buscador (último elemento) */
.sticky-search-container input.sticky-search {
  max-width: 200px;
  margin-left: auto;
}

/* En pantallas pequeñas, da prioridad al orden vertical */
@media (max-width: 768px) {
  .sticky-search-container {
    flex-direction: column;
    align-items: stretch;
  }

  .sticky-search-container > div,
  .sticky-search-container > input {
    width: 100%;
  }

  .sticky-search-container input.sticky-search {
    margin-left: 0;
    margin-top: 0.5rem;
  }
}

/* ============================================================
   FONDO SÓLIDO PARA LA COLUMNA FIJA
   ============================================================ */

.sticky-col {
    z-index: 900 !important;
    background-color: #fff !important;
}

.sticky-col thead,
.sticky-col tbody {
    background-color: #fff !important;
}

.sticky-col tr {
    background-color: #fff !important;
}

.sticky-col th,
.sticky-col td {
    background-color: #fff !important;
}

/* Hover de la columna fija */
.sticky-col tbody tr.table-hover-active > th,
.sticky-col tbody tr.table-hover-active > td {
    background-color: var(--bs-table-hover-bg) !important;
}

/* Intersección esquina superior izquierda */
/* Esquina superior izquierda: conservar estilo original */
.sticky-intersect {
    z-index: 1060 !important;
    background-color: #000 !important;
}

.sticky-intersect th {
    background-color: #000 !important;
    color: #fff !important;
}