/* animation */

@keyframes late-fadeout {
    0% {
        filter: none;
    }
    50% {
        filter: none;
    }
    100% {
        filter: opacity(0);
    }
}

/* general */

html {
    font-size: 20px;
}

body, html {
    font-family: roboto mono, consolas, monospace;
    color: white;
}

body {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;

    padding: 5rem 0;
}

#easy-copy {
    cursor: pointer;
    z-index: 1;

    position: fixed;
    top: 20px;
    right: 20px;

    width: 40px;
    height: 40px;
    padding: 10px;
    border-radius: 10px;

    background-color: #c0c0c0b5;
}

#easy-copy:hover {
    background-color: #ffffffb5;
}

#easy-copy:active {
    transform: scale(1.05);
}

#easy-copy img {
    width: 100%;
    height: 100%;
}

#easy-copy p {
    transition: background-color .15s linear;
    filter: opacity(0);

    animation: 2s late-fadeout;
    animation-fill-mode: forwards;

    position: absolute;

    top: 50%;
    left: 0;
    transform: translate(-120%, -50%);

    margin: 0;
}

#matrix {
    z-index: -1;
    position: fixed;

    top: 0;
    left: 0;
    width: 100%;
    height: 100%;

    background-color: #000000;
}

h1, h2 {
    text-align: center;
    font-family: dseg14, consolas, monospace;

    color: #00ff00;
    text-shadow: 0 0 20px;
}

h1 {
    font-size: 48px;
}

@media (max-width: 700px) {
    h1 {
        font-size: 24px;
    }
}

h2 {
    font-size: 24px;
    margin: 1em 0 0 0;
}

body>p {
    margin: 0 30px;
}

h3.category-header {
    position: relative;

    width: 100%;
    margin-bottom: .5em;

    text-align: center;
    font-size: 30px;
}

h3.category-header:after {
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);

    content: "";
    display: block;

    width: 80%;
    height: 3px;

    background-color: #a8ffa35c;
}

/* main div, blocks */

#main {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    gap: 2rem;

    width: 80%;
}

.block-alone, .block {
    border-radius: .4em;
    backdrop-filter: blur(5px);
}

.block-alone:before, .annotation:before {
    border-radius: .4em;
}

.block {
    padding: .5em 2em;
    width: 300px;

    background-color: #cccccc20;
    border: 2px solid #cccccc;

    text-shadow: 0 0 10px;
}

@media (max-width: 700px) {
    .block {
        margin: 0 5%;
    }
}

.block-alone {
    position: relative;
    max-width: 800px;
    margin-bottom: 3rem;

    text-align: justify;
}

.block-alone:before, .annotation:before {
    position: absolute;
    top: 0;
    left: 0;
    transform: translate(.7em, -50%);
    padding: .2em .4em;

    border: 2px solid #000000;
    background-color: #000000;
    text-shadow: 0 0 10px;
}

#disclaimer {
    width: fit-content;
    border-color: #ff5c5c;
    background-color: #ff5c5c20;
}

#disclaimer:before {
    content: "DISCLAIMER";
    border-color: #ff5c5c;
    color: #ff5c5c;
}

#disclaimer p {
    color: #ff5c5c;
}

#explanation {
    width: fit-content;
    border-color: #ffc85c;
    background-color: #ffc85c20;
}

#explanation:before {
    content: "Comment ça marche ?";
    border-color: #ffc85c;
    color: #ffc85c;
}

#explanation p {
    color: #ffc85c;
}

/* confloose list content */

.confloose-list {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;

    width: 100%;
    max-width: 1300px;
}

.confloose-list .block {
    cursor: pointer;

    transition: .3s;
}

.confloose-list .block p:noh(:has(a)) {
    margin: .5rem 0;
    color: #cccccc;
    font-size: .8em;

    pointer-events: none;
}

.confloose-list .block p.title {
    font-size: 1.5rem;
    margin: 1rem 0;
    color: #ffffff;
}

.confloose-list .block:not(.selected):not(:hover) {
    color: #aaaaaa;
    border-color: #aaaaaa;
    background-color: #55555570;
    backdrop-filter: blur(20px);
    filter: saturate(0);
}

.confloose-list .block.selected {
    border-color: #aa3333;
    background-color: #aa333320;
    box-shadow: 0 0 50px #aa3333a0;
}

.confloose-list .block.selected p {
    color: #ffdddd;
}

#command-container {
    width: 100%;
    padding: 10px 5%;
    box-sizing: border-box;

    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;

    background-color: #80808050;
    backdrop-filter: blur(5px);
    border: 2px solid #808080;
    border-width: 2px 0 2px 0;
}

@media (max-width: 700px) {
    #command-container {
        flex-direction: column;
    }
}

input {
    position: relative;
    cursor: pointer;

    display: block;
    margin: 1rem 0;
    padding: 5px;
    border: 2px solid #50705080;
    width: 100%;
    max-width: 300px;

    font-family: sometype, consolas, monospace;
    font-size: 1rem;

    background-color: #000000;
    color: #00cc00;

    overflow: hidden;
}

input:hover {
    border: 2px solid #008000;
}

.block code {
    color: #00cc00;
    font-family: sometype, consolas, monospace;
}

:is(body, #main)>p {
    text-align: center;
}

/* annotations */

.annotation.author-favorite:before {
    content: "Author favorite";
    border-color: #e1c75d;
    color: #e1c75d;
}

.annotation.needs-testing:before {
    content: "Needs testing";
    border-color: #b359cd;
    color: #b359cd;
}

.annotation.in-progress:before {
    content: "Work in progress";
    border-color: #b359cd;
    color: #b359cd;
}

.block.annotation {
    margin-top: 1em;
}

a {
    text-decoration: none;
    color: #00cc00;
}
