@import url('https://fonts.font.im/css?family=Roboto+Slab');
@import url('https://fonts.font.im/css?family=Noto+Sans');

:root {
    --WYX: 49;
}
.monospace {
    font-family: Consolas,monospace;
}
.flex {
    display: flex;
}
header,header > * {
    padding: 0;
    margin: 0;
}
body {
    font-family: 'Noto Sans',sans-serif;
    overflow-x: hidden; 
}
.hamburger {
    display: none;
}
.menu {
    position: fixed;
    top: 0;
    left: -300px;
    width: 300px;
    height: 100vh;
    background: white;
    transition: left 0.3s ease;
    z-index: 90;
}
.menu a {
    color: black;
    font-size: larger;
}
.menu.active {
    left: 0;
}
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(var(--WYX), var(--WYX), var(--WYX), 0.5);
    border-right: solid 1px rgb(var(--WYX), var(--WYX), var(--WYX));
    border-radius: 5px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3 ease;
    z-index: 80;
}
.overlay.active {
    opacity: 1;
    visibility: visible;
}
header {
    align-items: center;
    font-size: 16px;
    width: 100%;
    height: 70px;
    border-bottom: solid 1px rgb(0, 76, 211);
}
header h1 {
    left: 15px;
    opacity: 0;
    animation:slideR 1s ease forwards ;
}
.nav {
    text-decoration: none;
    position: absolute;
    right: 5vw;
    top: 0;
    line-height: 70px;
}
.nav a {
    color: black;
    text-decoration: none;
    margin-right: 4vw;
    opacity: 0;
    transition: 0.3s;
    animation: slideL 1.1s ease forwards;
    animation-delay: calc(.2s*var(--i));
}
.nav a:hover {
    text-decoration: underline;
}
.pageTitle {
    align-items: center;
    opacity: 0;
    animation: slideT 1.1s ease forwards;
}
.pageTitle::before {
    content: '';
    display: block;
    width: 8px;
    height: 8px;
    margin-right: 5px;
    background-color: red;
}
main {
    margin-left: 30px;
    margin-right: 30px;
}
footer {
    font-family: "Roboto slab",serif;
    flex-direction: column;
    align-items: center;
}
footer p {
    color: grey;
    font-size: 12px;
}
footer a {
    color: gray;
    text-decoration: none;
    font-size: 15px;
}
footer a:hover {
    text-decoration: underline;
}
/* 动画 */
@keyframes slideR {
    0% {
        transform: translateX(-100px);
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}
@keyframes slideL {
    0% {
        transform: translateX(100px);
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}
@keyframes slideB {
    0% {
        transform: translateY(-100px);
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}
@keyframes slideT {
    0% {
        transform: translateY(100px);
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}
/* 响应式 */
@media screen and (max-width: 768px) {
    .nav a {
        display: none;
    }
    header {
        justify-content: center;
        align-items: center;
    }
    header h1 {
        display: flex;
        font-size: 25px;
    }
    .hamburger {
        display: block;
        background-color: transparent;
        letter-spacing: 5px;
        line-height: 1.5;
        position: absolute;
        top: 15px;
        left: 20px;
        border: none;
        z-index: 100;
        cursor: pointer;
    }
    .menu {
        padding-top: 50px;
    }
    .menu a {
        display: block;
        margin: 10px 20px;
        text-decoration: none;
        font-size: 18px;
        font-family: 'Roboto slab', serif;
    }
    .menu a:hover {
        text-decoration: underline;
    }
}