/* Estilo del formulario */
#document-search-form {
    margin-bottom: 20px;
}

#document-search-form input,
#document-search-form select,
#document-search-form button {
    padding: 10px;
    font-size: 16px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

/* Botón Eliminar */
#document-search-form .delete-button {
    background-color: #EC471B; /* Color de fondo */
    color: #fff; /* Color del texto */
    border: none; /* Sin borde */
    cursor: pointer;
    display: flex; /* Para alinear ícono y texto */
    align-items: center; /* Centrar ícono verticalmente */
    justify-content: center; /* Centrar ícono horizontalmente */
}

#document-search-form .delete-button::before {
    content: 'X'; /* Ícono de letra "X" */
    margin-right: 5px; /* Espacio entre el ícono y el texto */
}

/* Botón Biblioteca/Subir */
#document-search-form .upload-button {
    background-color: #29CF12; /* Color de fondo */
    color: #fff; /* Color del texto */
    border: none; /* Sin borde */
    cursor: pointer;
}

/* Estilo de la tabla de resultados */
#document-search-results {
    margin-top: 20px;
}

.document-search-table {
    width: 100%;
    border-collapse: collapse;
}

.document-search-table th,
.document-search-table td {
    border: 1px solid #ddd;
    padding: 8px;
}

.document-search-table th {
    background-color: #f2f2f2;
    text-align: left;
}

.document-search-table td {
    vertical-align: middle;
}

.document-search-table th:nth-of-type(1),
.document-search-table td:nth-of-type(1) {
    width: 8%;
    text-align: center;
}

.document-search-table th:nth-of-type(2),
.document-search-table td:nth-of-type(2) {
    width: 50%;
    text-align: left;
}

.document-search-table th:nth-of-type(3),
.document-search-table td:nth-of-type(3) {
    width: 5%;
    text-align: left;
}

.document-search-table th:nth-of-type(4),
.document-search-table td:nth-of-type(4) {
    width: 5%;
    text-align: center;
}

.document-search-table img {
    max-width: 40px;
}

.document-search-pagination {
    text-align: center;
    margin-top: 20px;
}

.document-search-pagination a,
.document-search-pagination span {
    margin: 0 5px;
    padding: 5px 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-decoration: none;
    color: #0073aa;
    font-size: 16px;
    display: inline-block; /* Asegura que los elementos se alineen en una fila */
}

.document-search-pagination .current-page {
    background-color: #0073aa;
    color: white;
    font-weight: bold;
}

.document-search-total-records {
    margin-top: 10px;
    font-size: 16px;
    text-align: right;
    color: #333;
}

/* Estilos responsivos */
@media (max-width: 768px) {
    .document-search-table thead {
        display: none; /* Ocultar la cabecera en vista responsiva */
    }

    .document-search-table tr {
        display: flex;
        flex-direction: row;
        border: 1px solid #ccc;
        margin-bottom: 5px;
    }

    .document-search-table td {
        display: flex;
        align-items: center;
        border: none;
        padding: 10px;
        width: auto;
        overflow-wrap: break-word; /* Ajustar contenido que se desborda */
    }

    .document-search-table td:nth-of-type(1) {
        width: 8%;
    }

    .document-search-table td:nth-of-type(2) {
        width: 92%;
    }

    .document-manager-file-name {
        min-width: 220px !important;
    }

    .document-search-table td:nth-of-type(3),
    .document-search-table td:nth-of-type(4),
    .document-manager-file-author {
        display: none !important; /* Ocultar las columnas Referencia y Año */
    }

    .document-search-table td img {
        margin-right: 10px;
        max-width: 40px;
    }

    .document-search-table td a {
        text-align: left;
        word-wrap: break-word; /* Ajustar contenido que se desborda */
    }

    .document-search-pagination {
        display: flex;
        flex-wrap: wrap; /* Asegurar que los elementos se envuelvan en filas */
        justify-content: center; /* Centrar los elementos de paginación */
    }

    .document-search-pagination a,
    .document-search-pagination span {
        flex: 1 0 auto; /* Permitir que los elementos se distribuyan uniformemente */
        margin: 5px 2px; /* Ajustar los márgenes para evitar superposiciones */
        padding: 5px;
        font-size: 14px;
    }
}
