.mi-toc-fixed {
    position: fixed;
    top: 14rem;         /* Ajustar según tu layout */
    left: 0;         /* Ajustar según tu layout */
    width: 300px;       /* Ajustar según tu layout */
    max-height: calc(90vh - 200px); /* Ajustar según tu layout */
    overflow-y: auto;
    background: #f9f9f9;
    border: 1px solid #ddd;
    padding: 10px;
    font-size: 14px;
    z-index: 5;       /* Para asegurarnos de que se vea por encima de otros elementos */
}

.mi-toc-fixed .mi-toc-title {
    margin-top: 0px;
    font-weight: bold;
}

.mi-toc-fixed h4 {
    margin-top: 0;
    margin-bottom: 0.5em; 
    padding-bottom: 0.3em;
    border-bottom: 1px solid #ddd;
}

.mi-toc-ul {
    /* list-style: none; */
    margin: 0;
    padding-left: 2em;
}

.mi-toc-ul li {
    margin-bottom: 5px;
}
.mi-toc-ul li strong {
    font-weight: 500!important;
}
/* Indentación para H3 */
.h3-indent {
    margin-left: 15px;
    font-size: 13px;
}

/* Resaltar el enlace activo */
.mi-toc-ul li a.active {
    font-weight: bold;
    color: #8b8b8b; /* Rojo bootstrap como ejemplo */
    text-decoration: underline;
}

/* Si el ancho de la ventana es menor de 1320px, cambia a posición relativa */
@media screen and (max-width: 1320px) {
    .mi-toc-fixed {
        position: relative;
        top: auto;
        left: auto;
        margin-bottom: 2.5em;
        width: calc(100% - 20px);
    }
}