@import url(/styles/reset.css);

:root{
    --bg: #1e1e1e;
    --nav-bar: #1a1a1a;
    --accent: #964100;
    --accent-bright: #D66200;
    --accent-12: hsla(27, 100%, 42%, 0.12);
    --fixed-01: #2b2b2b;
    --fixed-02: #373737;
    --elevated-surface: rgba(255, 255, 255, 0.06);
    --easing: cubic-bezier(0.175, 0.885, 0.32, 1.000);
    --text-primary: white;
    --text-faded: rgba(255, 255, 255, 0.85);
    --text-invisible: rgba(255, 255, 255, 0.5);
    --h1-size: 72px;
}
body{
    background: var(--bg);
    font-family: Roboto, Inter, Arial, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
    color: var(--text-primary);
    padding: 24px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    gap: 16px;
    user-select: none;
    padding-top: calc(24px + var(--h1-size));
    padding-bottom: calc(24px + 64px);
    min-height: 100svh;
    align-items: center;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}
.material-symbols-outlined {
  font-variation-settings:
  'FILL' 0,
  'wght' 400,
  'GRAD' 0,
  'opsz' 24
}
h1{
    font-family: 'Inter';
    font-style: normal;
}
h2{
    font-family: 'Roboto';
    font-style: normal;
    font-weight: 400;
    font-size: 20px;
}
p.code{
    white-space: pre-wrap;
    overflow-wrap: break-word;
    margin-top: 5px;
    word-break: break-all;
    font-size: 13px;
    font-family: "Lucida Console", monospace !important;
    opacity: 0.8;
}
input[type="checkbox"].switch{
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    width: 52px;
    height: 32px;
    background: var(--elevated-surface);
    box-shadow: inset 0 0 0 2px var(--tinted-accent);
    border-radius: 100px;
    position: relative;
    transition: 0.1s background ease-out,
                0.1s box-shadow ease-out;
    margin: 0px 0px 0px 8px;
}
input[type="checkbox"].switch:checked{
    background: var(--accent);
    box-shadow: inset 0 0 0 0px var(--tinted-accent);
}
input[type="checkbox"].switch::after{
    content: "";
    position: absolute;
    width: 16px;
    height: 16px;
    right: 28px;
    top: 8px;
    background: var(--tinted-accent);
    border-radius: 100px;
    transition: 0.05s width ease-out,
                0.05s height ease-out,
                0.05s right ease-out,
                0.05s top ease-out,
                0.1s background ease-out;
}
input[type="checkbox"].switch:checked::after{
    width: 24px;
    height: 24px;
    right: 4px;
    top: 4px;
    background: white;
}


input[type="radio"]{
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    background: #ffffff00;
    border: 3px solid var(--tinted-accent);
    border-radius: 100px;
    position: relative;
    transition: 0.1s background ease-out,
                0.1s box-shadow ease-out;
    box-sizing: border-box;
}
input[type="radio"]:checked{
    background: #ffffffff;
    border: 4px solid var(--accent);
}

input[type="text"], textarea{
    height: 48px;
    width: 100%;
    background: var(--elevated-surface);
    border: none;
    border-radius: 16px;
    box-sizing: border-box;
    padding: 16px;
    resize: vertical;
    color: var(--text-primary);
    font-family: Roboto;
    font-size: 16px;
    line-height: 1.4;
    font-style: normal;
    font-weight: 400;
    user-select:text;
    white-space: pre-wrap;
}

textarea{
    height: 144px;
}

.lowpad{
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
}

.header > .back{
    display: flex;
    margin: 0;
    padding: 16px 16px 12px 0px;
    box-sizing: border-box;
    font-weight: 400;
    align-self:baseline;
    align-items: center;
}

.header{
    display: flex;
    height: 64px;
    width: 100%;
    padding: 0px 24px;
    top: 0;
    left: 0;
    align-items: center;
    position: fixed;
    z-index: 9;
    background: var(--nav-bar);
    box-sizing: border-box;
    transition: padding 0.5s var(--easing),
                background 0.5s var(--easing);
}

.back{
    width: 100%;
    display: flex;
    max-width: 720px;
    box-sizing: border-box;
}

.header > .logo{
    cursor: pointer;
}

.header.big{
    display: flex;
    height: 96px;
    padding: 0px 32px;
    position: absolute;
    background: var(--bg);
}

.header > .dead{
    display: flex;
    height: 1px;
    width: auto;
    flex: 1;
}

.header > .right{
    display: flex;
    align-items: center;
    gap: 16px;
}

.langswitcher-container{
    position: relative;
}

.langswitcher{
    display: flex;
    align-items: center;
    gap: 0px;
    color: var(--text-primary);
    padding: 8px;
    padding-right: 0px;
    border-radius: 14px;
    cursor: pointer;
    transition: 0.1s ease-out;
    position: relative;
}
body.hasHover .langswitcher-container > .langswitcher:hover{
    background: var(--elevated-surface);
}

.langswitcher-container > .window.hidden{
    transform: scaleY(0);
}

.langswitcher-container > .window{
    position: absolute;
    width: 100%;
    height: auto;
    display: flex;
    flex-direction: column;
    background: var(--fixed-01);
    top: 52px;
    left: 0px;
    padding: 8px;
    align-items: center;
    gap: 0px;
    box-sizing: border-box;
    border-radius: 16px;
    transition: 0.1s ease-out transform;
    transform-origin: top center;
}

.logo > img{
    object-fit: cover;
    object-position: 0% 50%;
    transition: 0.3s width var(--easing);
}
.header > .right{
    transition: 0.3s gap var(--easing);
}

.langswitcher-container > .langswitcher > img{
    transition: 0.3s height var(--easing);
}

.langswitcher-container > .window > img{
    padding: 8px;
    border-radius: 14px;
    transition: 0.1s ease-out background;
}

.langswitcher-container > .window > img:hover{
    background: var(--fixed-02)
}

#copypastas{
    width: 100%;
    max-width: 720px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

body > br{
    content: "";
    height: 1px;
    background: var(--elevated-surface);
    position: static;
    display: block;
}

.card{
    display: flex;
    position: relative;
    padding: 24px;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    border-radius: 24px;
    background: var(--elevated-surface);
    scroll-behavior: smooth;
    width: 100%;
    max-width: 720px;
    box-sizing: border-box;
}

.copypasta{
    display: flex;
    position: relative;
    padding: 24px;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    border-radius: 24px;
    background: var(--elevated-surface);
    scroll-behavior: smooth;
    animation: copypastaFadeIn 0.5s var(--easing);
}

.copypasta.message{
    align-items: center;
    background: none;
}

@keyframes copypastaFadeIn{
    0%{
        transform: scale(0.9) translateY(64px);
        opacity: 0;
    }
    100%{
        transform: scale(1) translateY(0px);
        opacity: 1;
    }
}
.copypasta > .top{
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.copypasta > .top > h2{
    color: var(--text-primary);
    font-family: Inter, Roboto, sans-serif;
    font-size: 24px;
    font-style: normal;
    font-weight: 700;
    line-height: normal;
    letter-spacing: -0.24px;
}
.copypasta > .top > .tags{
    display: flex;
    align-items: flex-start;
    gap: 8px;
}
.copypasta > .buttons{
    display: flex;
    gap: 8px;
}
button.tag{
    border-radius: 28px;
    background: var(--elevated-surface);
    height: 24px;
    padding: 2px 8px;
    font-size: 14px;
    font-weight: 400;
    letter-spacing: -0.14px;
}
p.bodytext{
    color: var(--text-primary);
    font-family: Roboto;
    font-size: 16px;
    line-height: 1.4;
    font-style: normal;
    font-weight: 400;
    user-select:text;
    white-space: pre-wrap;
}
p.bodytext.collapsable{
    padding-bottom: 42px;
    color: white;
    position: relative;
    transition: 0.3s background ease-out;
    overflow: hidden;
}
p.bodytext.collapsable.collapsed{
    max-height: 192px;
    mask-image: linear-gradient(180deg, #FFF 38.02%, rgba(255, 255, 255, 0.50) 71.35%, rgba(255, 255, 255, 0.00) 100%);
    -webkit-mask-image: linear-gradient(180deg, #FFF 38.02%, rgba(255, 255, 255, 0.50) 71.35%, rgba(255, 255, 255, 0.00) 100%);
}
.copypasta > button{
    position: absolute;
    bottom: 72px;
    left: 50%;
    justify-content: center;
    transform: translateX(-50%);
    color: white !important;
    background-clip:border-box;
    -webkit-background-clip:border-box;
    background: none;
    width: max-content;
}
body.hasHover .copypasta > button:hover{
    backdrop-filter: blur(20px) brightness(1.1);
}
.popup > span{
    font-size: 48px;
    margin-bottom: 8px;
    margin-top: 16px;
}
.popup > h3{
    width: 100%;
    text-align: center;
    font-size: 16px;
}
.popup{
    position: fixed;
    top: calc(50% - calc(86px * var(--scale-mult)));
    left: calc(50% - calc(86px * var(--scale-mult)));
    height: calc(172px * var(--scale-mult));
    width: calc(172px * var(--scale-mult));
    background: var(--bg);
    border-radius: 16px;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    box-sizing: border-box;
    padding: 16px;
    transform-origin: center;
    opacity: 0;
    display: none;
    --scale-mult: 1.3;
}
.popup.active{
    display: flex;
    animation: popup 2s ease-out;
    transform-style: preserve-3d;
    --perspective: 500px;
    transform: perspective(var(--perspective)) rotateY(var(--rotateX)) rotateX(var(--rotateY));
}
@keyframes popup{
    0%{
        opacity: 0;
        transform: scale(2);
        filter: blur(10px);
    }
    5%{
        filter: blur(6px);
        opacity: 0.7;
    }
    10%{
        opacity: 1;
        transform: scale(1) perspective(var(--perspective)) rotateY(var(--rotateX)) rotateX(var(--rotateY));
        filter: blur(0px);
    }
    85%{
        opacity: 1;
        transform: scale(1) perspective(var(--perspective)) rotateY(var(--rotateX)) rotateX(var(--rotateY));
        filter: blur(0px);
    }
    90%{
        filter: blur(6px);
        opacity: 0.7;
    }
    100%{
        opacity: 0;
        transform: scale(2);
        filter: blur(10px);
    }
}
button.icon{
    padding: 0px 8px;
    width: 40px;
}
button.secondary{
    background: var(--accent-12);
    color: var(--accent-bright);
}
button:has(span){
    padding: 0px 16px 0px 12px;
}
button{
    display: flex;
    height: 40px;
    padding: 0px 16px;
    align-items: center;
    gap: 8px;
    border-radius: 24px;
    background: var(--accent);
    color: #FFF;
    font-family: Roboto;
    font-size: 16px;
    font-weight: 500;
    line-height: normal;
    letter-spacing: -0.16px;
    border: none;
    cursor: pointer;
    transition: 0.05s backdrop-filter ease-out,
                0.05s filter ease-out;
}
body.hasHover button:hover{
    backdrop-filter: brightness(1.1);
    filter: brightness(1.1);
}
button:active{
    backdrop-filter: brightness(0.9);
    filter: brightness(0.9);
}
textarea{
    resize: none;
}
.card.suggestions{
    height: 304px;
    max-height: 304px;
    overflow: clip;
    box-sizing: border-box;
    padding-block: 0px;
    transition: 0.5s max-height var(--easing), 0.2s opacity;
    .lowpad{
        margin-top: 24px;
    }
}
button.big.suggestion{
    max-width: 90px;
    overflow: clip;
    transition: 0.2s max-width, 0.2s padding, 0.2s margin-left, 0.1s opacity;
}
body.search {
    .card.suggestions{
        max-height: 0px;
        opacity: 0;
    }
    .frontPage.separator{
        margin-top: -24px;
    }
    button.big.suggestion{
        max-width: 0px;
        padding: 0px;
        margin-left: -24px;
        opacity: 0;
    }
}
.header.big > .search-input{
    top: 24px;
}
.search-input{
    display: flex;
    flex-direction: row;
    align-items: center;
    height: 48px;
    background: var(--elevated-surface);
    border: none;
    border-radius: 16px;
    width: 100%;
    max-width: 720px;
    box-sizing: border-box;
    padding-left: 16px;
    user-select:text;
    white-space: pre-wrap;
    outline: solid transparent 16px;
    position: absolute;
    top: 8px;
    box-sizing: border-box;
    left: calc(50vw - 360px);
    z-index: 1;
    transition: 0.1s outline-color, 0s outline-width 0.1s;
    & > input{
        background: transparent;
        width: 100%;
    }
    & > input:focus{
        outline: none;
    }
    & > span.material-symbols-outlined{
        opacity: 0.7;;
    }
}
.search-input:focus-within{
    outline: solid var(--accent) 2px;
    transition: 0.2s outline;
}

.spinner{
    width: 56px;
    height: 40px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: fixed;
    left: calc(50vw - 28px);
    top: calc(50vh - 20px);
    pointer-events: none;
    z-index: 3;
    opacity: 0;
    transform: scale(0.5);
    transition-property: opacity, transform;
    transition-duration: 1s;
    transition-timing-function: var(--easing);
}

@keyframes loadingSpinner{
    0%{
        opacity: 1;
    }
    25%{
        opacity: 0.7;
    }
    75%{
        opacity: 0.7;
    }
    100%{
        opacity: 1;
    }
}

.block{
    height: 4px;
    width: 56px;
    border-radius: 100px;
    background: rgba(255, 255, 255, 0.85);
}

@keyframes block-ani{
    0%{
        width: 56px;
        margin-left: 0px;
        margin-right: 0px;
        opacity: 1;
    }
    10%{
        width: 8px;
        margin-left: 48px;
        margin-right: 0px;
        opacity: 0.7;
    }
    20%{
        width: 56px;
        margin-left: 0px;
        margin-right: 0px;
        opacity: 1;
    }
    30%{
        width: 8px;
        margin-left: 0px;
        margin-right: 48px;
        opacity: 0.5;
    }
    40%{
        width: 8px;
        margin-left: 48px;
        margin-right: 0px;
        opacity: 0.7;
    }
    50%{
        width: 56px;
        margin-left: 0px;
        margin-right: 0px;
        opacity: 1;
    }
    60%{
        width: 56px;
        margin-left: 0px;
        margin-right: 0px;
        opacity: 1;
    }
    70%{
        width: 8px;
        margin-left: 48px;
        margin-right: 0px;
        opacity: 0.7;
    }
    80%{
        width: 56px;
        margin-left: 0px;
        margin-right: 0px;
        opacity: 1;
    }
    90%{
        width: 8px;
        margin-left: 0px;
        margin-right: 48px;
        opacity: 0.5;
    }
    100%{
        width: 56px;
        margin-left: 0px;
        margin-right: 0px;
        opacity: 1;
    }
}

body.loading{
    & .spinner{
        opacity: 1;
        transform: scale(1);
        transition-duration: 0.3s;
        animation: loadingSpinner var(--easing) 2s infinite
    }
    & .block{
        animation: block-ani 4s var(--easing) infinite;
    }
}
@media (max-width: 1232px){
    .search-input{
        max-width: 50vw;
        left: 25vw;
    }
}

@media( max-width: 1024px ){
    .langswitcher-container > .langswitcher > img{
        width: auto;
        aspect-ratio: 3/2;
        height: 24px;
    }
    .header > .right{
        gap: 8px;
    }
    .logo > img{
        width: 66px;
    }
}
@media( max-width: 920px ){
    .header > .right > button.big.suggestion{
        display: none;
    }
    body.search .frontPage.separator{
            margin-top: -32px;
    }
}
@media (max-width: 512px){
    .search-input{
        max-width: calc(100vw - 120px);
        left: 24px;
        & > span.material-symbols-outlined{
            opacity: 0.7;
            scale: 1;
            transition: opacity 0.5s, scale 0.2s;
        }
    }
    .logo > img{
        height: 32px;
        width: 40px;
    }
    .logo{
        margin-left: 14px;
        margin-top: 2px;
        opacity: 0;
        scale: 0;
        transition: opacity 0.5s, scale 0.2s;
    }
    .header{
        padding: 16px !important;
    }
    body:not(.search) > .header:not(:has(.search-input:focus-within)){
        & > .logo{
            opacity: 1;
            scale: 1;
        }
        & > .search-input > span.material-symbols-outlined{
            opacity: 0;
            scale: 0;
        }
    }
}