/*---------Justifing----------*/
section p {
    text-align: left;
    hyphens: auto;
}

@media (min-width: 768px) {
    section p {
        text-align: justify;
        hyphens: auto;
    }
}

/*------------Eqs-------------*/
/* The following code make sure eqs and thier number do not overlap + the eq use the screen width */
.content .math .eqno {
    position: absolute;
    padding-bottom: 12px;
}

.content .math mjx-container[display="true"] {
    overflow-x: auto;
    overflow-y: hidden;
    padding-top: 8px;
    padding-bottom: 8px;
    margin-left: 0.5cm;
    margin-right: 1.25cm;
    
}


/*---------Side-Bar----------*/

/* Change sidebar captions from ALL CAPS to normal case */
.caption-text {
    text-transform: none;
}

/* zero <p> tags margins */
.sidebar-drawer p {
    margin-top: 0px;
    margin-bottom: 0px;
    padding-top: 0px;
    padding-bottom: 0px;
    line-height: 0px;
}

/* Target last caption paragraph inside the sidebar-tree */
.sidebar-tree p.caption:last-of-type {
    border-bottom: 1px solid #e1e4e5; /* The real 1px line */
    margin-top: 0px; /* change this to 15px when you add another category */
    margin-bottom: 0px;
    padding-top: 0px;
    padding-bottom: 0px;
}
body[data-theme="dark"] .sidebar-tree p.caption:last-of-type {
    border-bottom-color: #303335;
}

/* Hide the text inside the last caption */
.sidebar-tree p.caption:last-of-type {
    text-indent: -9999px;
    display: block;
}


.sidebar-drawer {
  flex: 0 0 15rem;       /* Initial size: 15rem */
  flex-shrink: 1;        /* If space is low, shrink */
  text-align: center;
}

.sidebar-brand {
    text-align: center;
    max-width: 100%;
    height: auto;
}

.sidebar-logo-container {
    max-width: 100%;
    height: auto;
    margin-top: 0;
}

.sidebar-logo {
    text-align: center;
    max-width: 85%;
    height: auto;
    margin-bottom: -1.5rem;
}

.sidebar-brand-text {
    text-align: center;
    font-family: 'Montserrat', sans-serif;
    font-size: 1.4rem;       
    font-weight: 700;        /* Make it bold */         
    color: var(--color-foreground-primary);             /* The same color as defined by furo in _colors.scss */ 
}
