.mainflex {
    width: 1050px;
}

.comicview {
    background-color: var(--black);
    background-image: var(--gradientbg);
    height: 750px;
    width: 800px;
    float: left;
    border-style: solid;
    border-width: 1px;
    border-color: var(--purple);
    border-radius: 10px;
    overflow-y: auto;
}

.comicview h1 {
    margin-left: 30px;
    margin-bottom: 0px;
    margin-top: 20px;
    font-size: 48px;
}

.comicview h2 {
    margin-top: 10px;
    margin-left: 60px;
    margin-bottom: 15px;
    text-decoration: underline;
}

.sidebar {
    height: 750px;
    width: 248px;
    float: right;
}

.sidebar ul {list-style-type: none}

.sidebar li {
    display: block;
    width: 220px;
    height: 60px;
    background-color: var(--black);
    background-image: var(--gradientbg);
    border-color: var(--purple);
    border-width: 1px;
    border-style: solid;
    margin: auto;
    text-align: center;
    font-size: 20px;
    border-radius: 7px;
    margin-bottom: 20px;
}

.page {
    width: 500px;
    display: none;
    margin: auto;
    cursor: pointer;
}

.pagearrows {
    text-align: center;
}

.pagearrows img {
    height: 25px;
    position: absolute;
    cursor: pointer;
}

.pagearrows img:nth-of-type(1) {
   transform: translate(-63px, -4px) rotate(180deg);
}

.pagearrows img:nth-of-type(2) {
   transform: translate(36px, -36px); 
}

.bottomnav {
    display: flex;
    justify-content: space-between;
}

.bottomnav a {
    margin-left: 50px;
    margin-right: 50px;
}

.bottomnav div {
    width: 220px;
    height: 70px;
}

.nav_hidden {
    visibility: hidden;
}

#prev {background: url("/res/asset/comic/nextprevious.png") 0px 70px;}
#prev:hover {background: url("/res/asset/comic/nextprevious.png") 220px 70px;}

#next {background: url("/res/asset/comic/nextprevious.png") 0px 0px;}
#next:hover {background: url("/res/asset/comic/nextprevious.png") 220px 0px;}

.chibis {
    display: flex;
    position: absolute;
    transform: translateX(-15px);
    z-index: 5;
}

.chibis div {
    width: 125px;
    height: 171px;
    background-size: 250px !important;
    margin-right: 60px;
}

#chibi-spinach {background: url("/res/asset/comic/sidebarchibi.png") 0px 0px;}
#chibi-spinach:hover {background: url("/res/asset/comic/sidebarchibi.png") 125px 0px;}

#chibi-soup {background: url("/res/asset/comic/sidebarchibi.png") 0px 171px;}
#chibi-soup:hover {background: url("/res/asset/comic/sidebarchibi.png") 125px 171px;}

.archive div {
    width: 130px;
    height: 130px;
    text-align: center;
    margin-bottom: 15px;
}

.archive p {
    margin: 0px;
    margin-top: 8px;
}

.archive {
    display: flex;
    width: 95%;
    margin-left: 70px;
    flex-wrap: wrap;
}

#random {
    cursor: pointer;
    text-decoration: underline;
}

#random:hover {text-decoration: none;}

main > p {
    margin-left: 50px;
    margin-right: 130px;
}

.col > h3 {
    padding-top: 30px;
    margin-bottom: 0px;
    text-align: center;
}

.col > p {
    margin-top: 10px;
}

.col {
    width: 250px;
    height: 250px;
}

.col img {
    display: block;
    margin: auto;
}

.charinfo {
    display: flex;
    flex-direction: column;
    margin: auto;
    width: 500px;
}

.row {
    display: flex;
}

.noscript {
    display: none;
    position: fixed;
    width: 100%;
    height: 100%;
    background-color: var(--black);
    background-image: url("../bg/checker.png");
    background-size: 100px;
    background-repeat: repeat;
    animation: slide 5s linear infinite;
    z-index: 100;
    left: 0px;
    top: 0px;
}

.noscript div {
    width: 600px;
    height: 500px;
    text-align: center;
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
}

/* mobile */
@media screen and (max-width: 850px) {
    .mainflex {
        width: 100%;
    }
    
    .comicview, .sidebar {
        margin: 0px;
        overflow: hidden;
        float: none;
        transform: none;
        left: auto;
        width: 100%;
    }
    
    h1, h2 {margin-left: 10px !important;}
    
    .comicview {
        width: 100%;
        height: auto;
    }
    
    .bottomnav {
        width: 100%;
        justify-content: auto;
    }
    
    .nav_hidden {
        display: none;
    }
    
    .bottomnav a {margin: 0px;}
    #next {transform: translateX(-20px);}
    .pagearrows {margin-top: 15px;}
    
    .pagearrows p {
        font-size: 32px;
        margin: 10px;
    }
    
    .pagearrows img {
        height: 30px;
        transform: translate(-100px, -4px) rotate(180deg) !important;
    }
    
    .pagearrows img:nth-of-type(2) {
        transform: translate(70px, -46px) !important;
    }
    
    .page {
        width: 98%;
    }
    
    nav {height: auto !important;}
    .sidebar ul {padding: 0px}
    .chibis div {margin-left: 10px; margin-right: 10px;}
    .chibis {
        left: 50%;
        transform: translateX(-52%);
    }
    
    .archive {
        margin-left: 30px;
    }
    
    .noscript div {
        width: 100% !important;
    }
    
    /* about page */
    .comicview > p {margin-right: 5%;}
    .comicview > p, .comicview > h1, .comicview > h2 {
        margin-left: 5% !important;
    }
    
    .row {
        width: 100%;
        justify-content: space-evenly;
    }
    
    .charinfo {width: 100%;}
    .col {width: 40%;}
}

@media screen and (max-width: 400px) {
    .bottomnav {
        display: block;
        margin: auto;
        width: 220px;
    }
}

@media screen and (max-width: 1079px) and (min-width: 851px) {
    .mainflex {
        width: 100% !important;
    }
    
    .comicview {
        width: 70%;
        margin: 0px;
        margin-bottom: 10px;
    }
    
    .sidebar {
        width: 29%;
        margin: 0px;
    }
    
    .sidebar ul {
        padding: 0px;
    }
    
    .chibis div:nth-of-type(2) {
        margin: 0px;
    }
}