/* Base styles */

:root {
    --red: rgb(219, 4, 4);
    --lred: #E06C75;
    --orange: #D19A66;
    --yellow: #E5C07B;
    --lgreen: #98C379;
    --lblue: #61AFEF;
    --cyan: #56B6C2;
    --dblue: rgb(47, 73, 108);
    --purple: #C678DD;
    --dpurple: #7c39ac;
    --lgrey: #5d6065;
    --dgrey: #272727;
    --black: #000000;
    --white: #e2e2e2;
}

.red {color: var(--red);}
.lred {color: var(--lred);}
.orange {color: var(--orange);}
.yellow {color: var(--yellow);}
.lgreen {color: var(--lgreen);}
.lblue {color: var(--lblue);}
.cyan {color: var(--cyan);}
.dblue {color: var(--dblue);}
.purple {color: var(--purple);}
.dpurple {color: var(--dpurple);}
.lgrey {color: var(--lgrey);}
.white {color: var(--white);}

body, button {
    background-color: var(--black);
    color: var(--white);
    font-family: "Montserrat", sans-serif;
    font-weight: 400;
    font-style: normal;
    font-size: 1.17em;
    margin: 0;
}

/* Basic elements */
a {
    color: inherit;
}

p {
    margin-top: 0;
}

h2 {
    margin: 0;
}

h2 img {
    height: 1.2em;
    vertical-align: middle;
}

.runButton {
    background-color: var(--dgrey);
    border: 0;
    width: 3em;
    height: 2em;
    border-radius: 0.6em;
    animation: mymove 3s infinite;
}

.runButton:hover,
.runButton:focus {
    background-color: var(--dpurple);
}

.tcenter {
    text-align: center;
    line-height: 1.5;
}

.centerblock {
    display: flex;
    flex-direction: column;
    margin: auto;
    padding: 40px;
    max-width: 900px;
}

ul {
    list-style-type: none;
    margin: 0;
    padding: 0;
    overflow: hidden;
    background-color: var(--dgrey);
    font-size: 0.8em;
}

li {
    float: left;
}

li a {
    display: block;
    color: var(--white);
    text-align: center;
    padding: 16px;
    text-decoration: none;
}

li a:hover,
li a:focus {
    background-color: var(--dpurple);
}

.btn-group {
    display: flex;
    justify-content: space-around;
    min-height: 40px;
}

.btn-group button {
    background-color: var(--lgrey);
    color: var(--white);
    cursor: pointer;
    flex: 1;
    font: inherit;
    border: 1px solid var(--black);
    border-radius: 1px;
}

.btn-group button:hover {
    background-color: var(--dpurple);
}

@media screen and (max-width: 500px) {
    .btn-group {
        flex-direction: column;
        align-items: stretch;
    }
    .btn-group button {
        padding: 6px 0;
    }
}

.LR {
    display: flex;
    flex-direction: row;
    gap: 10px;
    margin-bottom: 2em;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin: 0;
    padding: 0;
    margin-bottom: 3em;
}

.LR h2 {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    gap: 10px;
    margin: 0;
}

.LR h2 span {
    display: flex;
    gap: 8px;
    align-items: center;
}

@media screen and (max-width: 600px) {
    .LR h2 {
        flex-direction: column;
        align-items: flex-start;
    }

    .LR h2 span {
        width: 100%;
        justify-content: flex-start;
    }
}

code {
    background: var(--dgrey);
    /* Remove border-left here */
    color: var(--white);
    /* page-break-inside: avoid; */
    font-family: monospace;
    font-size: 15px;
    line-height: 1.6;
    margin: 0;
    padding: 1em;
    display: block;
    position: relative;
    /* for pseudo-element positioning */
    white-space: pre-wrap;
    /* enable word wrapping */
    word-break: break-word;
    /* break long words if needed */
}

code2 {
    background: var(--dgrey);
    border-left: 3px solid var(--lgrey);
    color: var(white);
    font-family: monospace;
    font-size: 15px;
    line-height: 1.6;
    margin-bottom: 1.6em;
    padding: 1em;
    display: block;
    position: relative;
}

/* Add fading border-left using a pseudo-element */
code::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    width: 3px;
    height: 100%;
    z-index: 3;
    background: linear-gradient(to bottom,
            var(--lgrey) 0%,
            var(--black) 100%);
    pointer-events: none;
}

/* Fade out effect at the bottom of code blocks */
code::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 20em;
    pointer-events: none;
    background: linear-gradient(to bottom,
            rgba(0, 0, 0, 0) 0%,
            var(--black) 100%);
    border-bottom-left-radius: inherit;
    border-bottom-right-radius: inherit;
    z-index: 2;
}

footer {
    display: flex;
    justify-content: center;
    padding: 20px;
}

/* Media queries */
@media screen and (max-width: 425px) {
    body {
        font-size: 1em;
    }

    code {
        font-size: 12px;
    }

    code2 {
        font-size: 12px;
    }
}

.blur {
    filter: blur(1px);
    pointer-events: none;
    user-select: none;
    white-space: pre-wrap;
    /* enable word wrapping */
    word-break: break-word;
}