/* IMPORTS  --------------------------------------------------------------------------------------------------------------------- */
@font-face {
    font-family: "T-Star-Pro";
    src: url('../assets/content/fonts/Menlo-Regular.woff2') format('woff2'),
        url('../assets/contents/fonts/Menlo-Regular.woff') format('woff'),
        url('../assets/contents/fonts/Menlo-Regular.otf') format('opentype');
    font-weight: 600;
    font-style: normal;
}









/* HTML ------------------------------------------------------------------------------------------------------------------------- */
:root{
    --td-bg-color:#2B2C2C;
    --td-dark-color: #1D1D1E;
    --td-light-color: #272729;

    --td-top-color: #594F7C;
    --td-top-text-color: #959BCE;

    --td-chop-color: #5e8446;
    --td-chop-text-color: #8eb874;

    --td-sop-color: #45739f;
    --td-sop-text-color: #98bbde;
}









/* TYPE ------------------------------------------------------------------------------------------------------------------------- */
ol{
    font-weight: 300;
    font-size: 0.8rem;
    line-height: 1.1rem;
    letter-spacing: 0.5px;

    margin-top: 0.5rem;
    max-width: 60ch;
    -webkit-padding-start: 1rem;
            padding-inline-start: 1rem;
}

ul{
    font-weight: 300;
    font-size: 0.8rem;
    line-height: 1.1rem;
    letter-spacing: 0.5px;

    margin-top: 0.5rem;
    max-width: 60ch;
    -webkit-padding-start: 1rem;
            padding-inline-start: 1rem;

    list-style: none;

    & > li:before{
        content: "_";
        margin: 0 0.3rem 0 -1rem;
    }
}

li::marker{
    text-align: left !important;
}









/* CONTENT  --------------------------------------------------------------------------------------------------------------------- */
article{
    gap: calc(12.5vh - 3rem) 1rem;
}

#first.bento{
    /* position: absolute; */
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -ms-flex-wrap: wrap;
        flex-wrap: wrap;
    -webkit-column-gap: 1rem;
       -moz-column-gap: 1rem;
            column-gap: 1rem;
    row-gap: 1rem;
    width: 150%;
    /* width: calc((2560px - 1rem) / 2 + 440px); */
}

#hidden-divider{
    -ms-grid-column: 1;
    -ms-grid-column-span: 8;
    grid-column: 1 / 9;
    height: 1rem;
}

hr{
    border: none;
    border-top: 3px double var(--type-color);
    color: var(--type-color);
    overflow: visible;
    text-align: center;

    -ms-grid-column: 1;

    -ms-grid-column-span: 8;

    grid-column: 1 / 9;
    height: 1rem;
    width: 100%;
    max-width: calc(var(--in-width) - 3rem);
    
    &::after{
        background: #fff;
        content: '§';
        padding: 0 0.2rem;
        position: relative;
        top: -0.55rem;
    }
}

section.documentation{
    min-height: 50vh;
    -ms-grid-column: 1;
    -ms-grid-column-span: 8;
    grid-column: 1 / 9;

    display: -ms-grid;

    display: grid;
    -ms-grid-columns: 1fr 1rem 1fr 1rem 1fr 1rem 1fr 1rem 1fr 1rem 1fr 1rem 1fr 1rem 1fr;
    grid-template-columns: repeat(8, 1fr);
    gap: 1rem;
    padding: 3rem 0;
}

.docuinfo{
    -ms-grid-row: 1;
    -ms-grid-row-span: 1;
    grid-row: 1 / 2;
    -ms-grid-column: 1;
    -ms-grid-column-span: 4;
    grid-column: 1 / 5;
    width: 100%;
    height: -webkit-fit-content;
    height: -moz-fit-content;
    height: fit-content;
    position: sticky;
    top: 6rem;
    max-width: calc((var(--in-width) / 2) - 1.5rem);
    margin: 0 0 0 auto;

    & > h2{
        margin-top: 0;
    }

    & > h3{
        font-weight: 400;
        font-size: 1rem;
        line-height: 1.3rem;
        letter-spacing: 0.75px;
    }
}

h4{
    font-weight: 500;
    font-size: 0.8rem;
    line-height: 1.1rem;
    letter-spacing: 0.75px;

    margin: 0;
}

p + h4{
    margin-top: 1.5rem;
}

h5{
    font-weight: 400;
    font-size: 0.8rem;
    line-height: 1.1rem;
    letter-spacing: 0.75px;

    margin: 0;
}

p + h5{
    margin-top: 0.75rem;
}

math.outline{
    margin: 0.5rem 0;
}

.maths + h5{
    margin-top: 1.5rem;
}

h5 + p{
    margin-top: 0;
}

.maths{
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -ms-flex-wrap: wrap;
        flex-wrap: wrap;
    gap: 0.5rem;
}

.maths + p{
    margin-top: 1.5rem;
}

.docuviz{
    -ms-grid-column: 5;
    -ms-grid-column-span: 4;
    grid-column: 5 / 9;

    & > .comp-display{
        margin-bottom: 1.5rem;

        &.double{
            display: -webkit-box;
            display: -ms-flexbox;
            display: flex;
            gap: 1rem;
        }
    }

    & hr{
        height: 1px;
        border-top: 1px solid #999;
        margin: 0.75rem auto 0.75rem 0;
        max-width: 50ch;

        &::after{
            background: none;
            content: none;
            padding: none;
            position: none;
            top: 0;
        }
    }

}

.top-text{
    padding: 0.2rem 0.1rem 0 0.15rem;
    background-color: var(--td-top-text-color);
}

.chop-text{
    padding: 0.2rem 0.1rem 0 0.15rem;
    background-color: var(--td-chop-text-color);
}

.sop-text{
    padding: 0.2rem 0.1rem 0 0.15rem;
    background-color: var(--td-sop-text-color);
}









/* TD COMPONENT ----------------------------------------------------------------------------------------------------------------- */
.td-base-comp{
    height: 14.25vh;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
        -ms-flex-direction: column;
            flex-direction: column;
    -webkit-filter: drop-shadow(var(--shadow));
            filter: drop-shadow(var(--shadow));

    &:hover{
        background-color: rgba(0, 0, 0, 0);
    }
}

.td-base-comp.small{
    aspect-ratio: 202 / 164;
}

.td-base-comp.medium{
    aspect-ratio: 384 / 164;
}

.td-base-comp.large{
    aspect-ratio: 422 / 164;
}



.horizontal-bar{
    height: 10px;
    background-color: var(--td-bg-color);

    border-style: outset;
    border-width: 1px;
    border-color: rgba(255, 255, 255, 0.25);
}



.content-bar{
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    height: calc(100% - 39px);
}

.vertical-bar{
    width: 10px;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
        -ms-flex-direction: column;
            flex-direction: column;
}

.vertical-color{
    width: 100%;
    height: 100%;
    background-color: var(--td-bg-color);

    border-width: 1px;
    border-color: rgba(255, 255, 255, 0.25);
}

.vertical-color.left{
    border-style: none none none outset;
}

.vertical-color.right{
    border-style: none outset none none;
}



.connector-container{
    width: 100%;
    height: 41px;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
        -ms-flex-direction: column;
            flex-direction: column;
    -webkit-box-pack: justify;
        -ms-flex-pack: justify;
            justify-content: space-between;

    &.double{
        height: 80px;
    }
}



.connector-color{
    width: 100%;
    height: 18px;
    background-color: var(--td-top-color);

    border-width: 1px;
    border-color: rgba(255, 255, 255, 0.5);

    &.top-left{
        border-style: none none outset outset;
    }

    &.bottom-left{
        border-style: outset none none outset;
    }

    &.top-right{
        border-style: none outset outset none;
    }

    &.bottom-right{
        border-style: outset outset none none;
    }

    &.center{
        height: 12px;
        border-style: outset outset outset none;
    }
}



.connector-space{
    width: 100%;
    height: 5px;
}



.flags-bar{
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
        -ms-flex-direction: column;
            flex-direction: column;
    background-color: var(--td-bg-color);

    border-style: none outset none outset;
    border-width: 1px;
    border-color: rgba(255, 255, 255, 0.25);
}

.td-flag{
    display: block;
    height: 24px;
    width: 24px;
    margin: 0 -1px;

    border-style: none none outset none;
    border-width: 1px;
    border-color: rgba(255, 255, 255, 0.25);
}

.viewer-container{
    width: calc(100% - 1px);
    padding: 5px 8px;
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-pack: center;
        -ms-flex-pack: center;
            justify-content: center;
    background-color: var(--td-dark-color);

    border-style: none outset none none;
    border-width: 1px;
    border-color: rgba(255, 255, 255, 0.25);
}

.viewer{
    height: 100%;

    & > img{
        display: block;
        width: auto;
        height: auto;
        max-width: 100%;
        max-height: 100%;
        object-fit: contain;
    }

    .square{
        aspect-ratio: 1;
    }

    .double{
        aspect-ratio: 2 / 1;
    }

    .triple{
        aspect-ratio: 3 / 1;
    }
}



.hairline{
    height: 1px;
    background-color: var(--td-dark-color);
}

.title-bar{
    height: 18px;
    background-color: var(--td-light-color);
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
}

.title-section{
    width: 100%;
    
    border-style: outset;
    border-width: 1px;
    border-color: rgba(255, 255, 255, 0.5);

    & > p{
        font-family: T-Star-Pro;
        font-style: normal;
        font-size: 12px;
        margin: auto 0 0 4px;
        max-width: auto;
        color: rgba(255, 255, 255, 0.75);
    }
}



.title-divider{
    width: 1px;
    margin: 1px 0;
    background-color: var(--td-light-color);
}

.activate-container{
    width: 18px;

    border-style: outset;
    border-width: 1px;
    border-color: rgba(255, 255, 255, 0.5);
}

.activate-flag{
    height: 100%;
}









/* OTHER    --------------------------------------------------------------------------------------------------------------------- */
.laplacian-kernel{
    width: 30%;
    margin: 1rem 0;
}









/* CHEAT SHEET  ----------------------------------------------------------------------------------------------------------------- */
.notation-category{
    -ms-grid-column: 1;
    -ms-grid-column-span: 8;
    grid-column: 1 / 9;
    padding: 3rem 0;

    & > h3{
        font-weight: 400;
        font-size: 1rem;
        line-height: 1.3rem;
        letter-spacing: 0.75px;
    }
}

.notation-entry {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
    -webkit-box-align: start;
        -ms-flex-align: start;
            align-items: flex-start;
    margin-bottom: 1rem;
}

.notation-symbol {
    font-weight: 300;
    font-size: 0.8rem;
    line-height: 1.1rem;
    letter-spacing: 0.5px;
    margin: 0.5rem 0 0 0;
    
    width: 2rem;
    -ms-flex-negative: 0;
        flex-shrink: 0;
}

.notation-description {
    text-align: left;

    & > math.outline{
        margin: 0.5rem 0;
    }

    & > math.underline{
        margin: 0 0 0.5rem 0;
    }
}

.notation-title {
    font-weight: 400;
    font-size: 0.8rem;
    line-height: 1.1rem;
    letter-spacing: 0.75px;

    margin: 0;
}