/* ============================================================
   Fichas de infoTecnica en conocimiento.php (sitio de producción)
   Autocontenido; pensado para convivir con master.css / dialer.css (Bootstrap 3).
   Se sube al hosting en assets/css/conocimiento.css (lo carga la plantilla).
   ============================================================ */

.it-seccion {
    padding: 40px 0 80px;
    background-color: #f4f6f8;
    position: relative;   /* junto con z-index, tapa el footer fijo (ver .it-cabecera) */
    z-index: 1;
}
/* Backdrop de la navbar (espaciador del tope): también por encima del footer fijo. */
.bg-secciones {
    position: relative;
    z-index: 1;
}

/* Encabezado: la imagen se muestra COMPLETA (sin recorte) y a todo el ancho.
   El contenedor toma la proporción nativa de la imagen (aspect-ratio 1579/270)
   con width:100% + height:auto, así escala proporcionalmente con el ancho del
   viewport: más alto en pantallas anchas, más bajo en angostas. background-size:
   contain evita cualquier recorte; #06172e queda solo como color de respaldo. */
.it-cabecera {
    aspect-ratio: 1579 / 270;
    width: 100%;
    height: auto;
    background-color: #06172e;
    background-image: url(../../uploads/imagenes/conocimientoCabecera.jpg);
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
    position: relative;
    z-index: 1;
    /* El sitio tiene un footer fijo "reveal" (#footer-fixed, position:fixed z-index:0).
       Sin posicionar, ese footer pinta por encima de nuestro contenido y se asoma
       cuando la ventana es baja. position:relative + z-index:1 lo deja por debajo. */
}
.it-lista {
    display: flex;
    flex-direction: column;
    gap: 22px;
}
.it-buscador {
    margin: 0 0 30px;
    padding: 28px 30px 18px;
    border: 1px solid #dce5ef;
    border-radius: 14px;
    background: linear-gradient(135deg, #ffffff 0%, #f4f8fd 100%);
    box-shadow: 0 12px 34px rgba(8, 39, 75, .08);
}
.it-buscador__encabezado {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 30px;
}
.it-buscador__eyebrow {
    display: block;
    margin-bottom: 6px;
    color: #0875d1;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 2.5px;
}
.it-buscador h1 {
    margin: 0 0 6px;
    color: #14263d;
    font-size: 29px;
    line-height: 1.2;
}
.it-buscador p {
    margin: 0;
    color: #677689;
}
.it-buscador__campo {
    position: relative;
    flex: 0 1 520px;
}
.it-buscador__campo > i {
    position: absolute;
    top: 50%;
    left: 15px;
    z-index: 2;
    display: flex;
    width: 28px;
    height: 28px;
    align-items: center;
    justify-content: center;
    color: #0875d1;
    font-size: 20px;
    transform: translateY(-50%);
    pointer-events: none;
}
.it-buscador__campo input {
    width: 100%;
    height: 54px;
    padding: 0 112px 0 60px !important;
    border: 1px solid #cdd9e5;
    border-radius: 9px;
    outline: none;
    background: #fff;
    color: #14263d !important;
    caret-color: #0875d1;
    -webkit-text-fill-color: #14263d;
    font-size: 15px;
    box-shadow: 0 5px 18px rgba(8, 39, 75, .06);
    transition: border-color .2s, box-shadow .2s;
}
.it-buscador__campo input:focus {
    border-color: #0875d1;
    box-shadow: 0 0 0 3px rgba(8, 117, 209, .12);
}
.it-buscador__campo button {
    position: absolute;
    top: 50%;
    right: 9px;
    display: none;
    width: auto;
    height: 36px;
    padding: 0 12px;
    border: 0;
    border-radius: 7px;
    background: #173653;
    color: #fff;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .7px;
    line-height: 36px;
    transform: translateY(-50%);
}
.it-buscador__campo button.is-visible {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.it-buscador__campo button:hover {
    color: #fff;
    background: #0875d1;
}
.it-buscador .it-buscador__estado {
    margin-top: 13px;
    color: #647286;
    font-size: 12px;
    font-weight: 600;
    text-align: right;
}
.it-ficha[hidden] {
    display: none !important;
}
.it-sin-resultados {
    padding: 55px 20px;
    border: 1px dashed #cbd7e3;
    border-radius: 12px;
    background: #fff;
    color: #667589;
    text-align: center;
}
.it-sin-resultados[hidden] {
    display: none;
}
.it-sin-resultados i {
    display: block;
    margin-bottom: 12px;
    color: #0875d1;
    font-size: 42px;
}
.it-sin-resultados h2 {
    margin: 0 0 7px;
    color: #17283e;
    font-size: 22px;
}
.it-sin-resultados p {
    margin: 0;
}
.it-ficha {
    display: flex;
    flex-direction: column;
    gap: 14px;
    background: #fff;
    border: 1px solid #e3e7eb;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 6px 22px rgba(0,0,0,0.09);
    transition: box-shadow .2s ease, transform .2s ease;
}
.it-ficha:hover {
    box-shadow: 0 10px 30px rgba(0,0,0,0.13);
    transform: translateY(-2px);
}
/* Fila superior: imagen (fija) + descripción. Debajo, tags y acciones a ancho completo. */
.it-ficha__top {
    display: flex;
    gap: 22px;
}
.it-ficha__portada {
    flex: 0 0 150px;
}
.it-ficha__portada img {
    width: 100%;
    aspect-ratio: 210 / 297;
    object-fit: cover;
    border-radius: 5px;
    border: 1px solid #e3e7eb;
    display: block;
}
.it-ficha__cuerpo {
    flex: 1 1 auto;
    min-width: 0;
}
.it-ficha__desc {
    font-size: 15px;
    line-height: 1.35;
    color: #4a4f57;
    /* Tope de ~10 líneas con max-height (no height): crece solo lo necesario; si el
       texto es más corto NO reserva espacio, y si se pasa aparece scroll vertical. */
    max-height: 14em;
    overflow-y: auto;
    padding-right: 8px;   /* aire para que el scrollbar no pise el texto */
}
/* Párrafos con separación chica (no un renglón vacío entero) */
.it-ficha__desc p {
    margin: 0 0 0.55em;
}
.it-ficha__desc p:last-child {
    margin-bottom: 0;
}
/* Scrollbar discreta dentro de la descripción */
.it-ficha__desc::-webkit-scrollbar {
    width: 6px;
}
.it-ficha__desc::-webkit-scrollbar-thumb {
    background-color: #c9d1d8;
    border-radius: 3px;
}
.it-ficha__desc::-webkit-scrollbar-track {
    background: transparent;
}
.it-ficha__tags {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}
.it-ficha__tags li {
    background-color: #eef1f4;
    color: #55606b;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 9px;
    border-radius: 20px;
}
.it-ficha__acciones {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    justify-content: center;   /* grupo de links/botón centrado en la ficha */
}
.it-ficha__pdf {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background-color: #ffb100;
    color: #2b2f38;
    font-weight: 700;
    font-size: 14px;
    padding: 9px 18px;
    border-radius: 4px;
    text-decoration: none;
    transition: background-color .2s ease;
}
.it-ficha__pdf:hover {
    background-color: #e89f00;
    color: #2b2f38;
    text-decoration: none;
}
.it-ficha__pdf i {
    font-size: 16px;
}
.it-ficha__rel {
    color: #2f6fb0;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
}
.it-ficha__rel:hover {
    color: #1d4e77;
    text-decoration: underline;
}
.it-vacio {
    color: #6c757d;
    font-style: italic;
}

/* Responsive: apilar imagen y descripción en pantallas chicas */
@media (max-width: 600px) {
    .it-seccion {
        padding-top: 22px;
    }
    .it-buscador {
        padding: 22px 18px 15px;
    }
    .it-buscador__encabezado {
        display: block;
    }
    .it-buscador h1 {
        font-size: 24px;
    }
    .it-buscador__campo {
        margin-top: 18px;
    }
    .it-buscador__campo input {
        height: 52px;
        font-size: 14px;
    }
    .it-buscador .it-buscador__estado {
        text-align: left;
    }
    .it-ficha__top {
        flex-direction: column;
    }
    .it-ficha__portada {
        flex-basis: auto;
        max-width: 180px;
    }
}
