@font-face {
    font-family: 'Constantia-Bold';
    src: url('./constantia-font/CONSTANB.TTF');
}
@font-face {
    font-family: 'Constantia';
    src: url('./constantia-font/CONSTAN.TTF');
}

body {
    position:relative;
    font-family: 'Constantia';
    display: flex;
    justify-content: space-evenly;
    margin: 0;
    background-image: linear-gradient(to right, lightgray, calc(50% - 900px), white, white, white, calc(50% + 900px), lightgray);
}

.adspace {
    outline: 1px dashed gray;
}

#comic-info {
    p {
        margin-left: 2%;
    }
}

#vote {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    aspect-ratio: 2/1;
    width: calc(100% - 4px);
}

#vote h1 {
    margin: 0;
    text-align: center;
}

.left {
    margin-right: 1%;
}

.right {
    margin-left: 1%;
}

#centerlined {
    position:relative;
    justify-content: space-evenly;
    max-width: 924px;
    padding: 8px;
    display: flex;
    flex-direction: column;
}

h1,h2,h3,h4,h5,str{
    font-family: 'Constantia-Bold';
    font-weight: normal;
}




#about {
    font-size: 0.75em;
    scrollbar-color: rgb(230, 220, 205) rgb(180, 166, 148);
    background-color: rgb(230, 220, 205);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: justify;
    div {
        width: calc(70%);
        background-color: rgb(204, 190, 175);
        h2 {
            background-color: rgb(180, 166, 148);
            padding: 2px 2%;
            text-align: right;
            margin: 0;
        }
        p {
            padding: 0 2% 0;
        }
    }
    max-height: 800px;
}

.info {
    text-decoration: underline;
    cursor: help;
}

#banner {
    position:relative;
    display:flex;
    flex-direction:column;
    align-items:center;
    justify-content:flex-start;
    aspect-ratio: 260/40;
    background-image: 
        url('/img/gfx/main-box-ends.png'),
        url('/img/gfx/main-box-ends.png'),
        url('/img/gfx/main-box-mid.png');
    background-repeat:
        no-repeat,
        no-repeat,
        space;
    background-position:
        top,
        bottom,
        center;
    background-size:
        100% auto,
        100% auto,
        100% calc(100% - 100% * 3 / 922);
}

#banner-title {
    width: calc(600% / 42);
    aspect-ratio: 281 / 74;
    max-width: 144px;
    margin-top: -1%;
}

main {
    position:relative;
    
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    max-width: 908px;
    
    padding: 0 2%;
}

.stack {
    margin-top: 1%;
}

aside .stack {
    margin-top: 7%;
    
    .box-bar {
        background
    }
}



#comic-nav,.bg0 {
    background-color: #8bb6b5;
}

#comic-dets {
    margin: 1% 0;
    margin-bottom:calc( -1% - 2px);
    z-index:2;
}

nav,#comic-dets,#bottom-side,.article,.holder,.bg1 {
    background-color: #AAD1D0;
}

.bg2 {
    background-color: #D9EDEC;
}

.fit-max {
    width: 100%;
}

#news-box {
    z-index:1;
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    aspect-ratio: 3/2;
    position: relative;
}

#l-news-backing,#r-news-backing {
    position: absolute;
    height: inherit;
}

#l-news-backing {
    left: 0;
}

#r-news-backing {
    right: 0;
}

#news {
    background-color: lightcyan;
    background-color: rgb(217, 237, 236);
    width: 76%;
    aspect-ratio: 4/3;
    font-size: 110%;
    .article {
        margin: 18px 10px;
        h3 {
            font-family:'Constantia-Bold';
            font-weight: normal;
            margin: 8px 0;
            font-size: inherit;
        }
        p {
            font-size: 70%;
        }
        border: 2px solid black;
        padding: 8px;
    }
}

article,#comic-dets,#news,#about,.box {
    border: 2px solid black;
}

#comic-nav {
    border-style:inset;
    border-color: #0003;
}

.padded {
    padding: 8px;
}

.fill {
    height: 100%;
}

#comic-nav {
    margin-bottom: 0;
    display: flex;
    flex-direction: row;
    justify-content: space-evenly;
    padding: 4px;
}

article {
    background-color: white;
    border: 2px solid black;
    padding: 10px;
    width: 70%;
    min-height: calc(900px);
    max-width: 696px;
}

#votebox {
    position:relative;
    aspect-ratio: 133 / 286;
    width: 100%;
    background-image: url('/img/gfx/vote-link-holder.png');
    background-size:100% auto;
    a {
        position: absolute;
        left: 50%;
        top: 50%;
        transform: translate(-50%,-50%);
        display: flex;
        aspect-ratio: 129 / 282;
        width: calc(100% * 129 / 133);
        
        
    }
    div {
        display: flex;
        margin: 2px;
        outline: 1px solid white;
        text-decoration: none;
        height: 80%;
        width: calc(100% - 4px);
        position: absolute;
        bottom: 0;
        
        align-items: center;
        justify-content: center;
        p {
            display: inline-block;
            text-align: center;
            vertical-align: middle;
        }
    }
}

nav,.box-bar,#votebox {
    background-color: #0000;
    img {
        width:100%;
    }
}

@property --bw {
  syntax: "<number>";
  inherits: true;
  initial-value: clamp(); 
}

.end-box {
    min-height:calc(width * 286 / 133);
}

.box-bar {
    position:relative;
    background-image: 
        url('/img/gfx/side-block-ends.png'),
        url('/img/gfx/side-block-ends.png'),
        url('/img/gfx/side-block-mid.png');
    background-repeat:
        no-repeat,
        no-repeat,
        space;
    background-position:
        top,
        bottom,
        center;
    background-size:
        100% auto,
        100% auto,
        100% calc(100% - 100% * 3 / 922);
    .top,.end {
        width:inherit;
        position:absolute;
    }
    .top {
        top:0;
    }
    .end {
        bottom:0;
    }
    
    height:100%;
}

nav {
    user-select:none;
    background-image: url('/img/gfx/vote-link-holder.png');
    background-size:100% auto;
    div {
        position: relative;
        color: black;
        text-decoration: none;
        z-index: 1;
        width:100%;
        display: flex;
        justify-content: center;
        align-items: center;
        
    }
    
    a {
        position: absolute;
        color: black;
        text-decoration: none;
        z-index: 1;
        width:90%;
        display: flex;
        justify-content: center;
        align-items: center;
    }
}

.mid {
    font-family: 'Constantia';
}

.top,.end {
    font-family: 'Constantia-Bold';
}



aside {
    display: flex;
    flex-direction: column;
    width: calc(100%);
    max-width: 15%;
}

aside {
    
    position:relative;
    
    .pillar {
        
        z-index:-1;
        height:calc(103%);
        width:calc(100% * 117 / 133);
        position:absolute;
        
        left:50%;
        transform:translate(-50%, -1%);
        background-image: url('/img/gfx/pillar-bit.png');
        background-size:100%;
    }
}

#comic {
    max-width: 580px;
    width: calc(100%);
    aspect-ratio: auto;
}

#characters {
    background-color: #BFE3DC;
    padding-top:0;
    padding-bottom:0;
    text-align: justify;
    .holder {
        border: 2px solid #778A7B;
        border-width: 0 1px 1px;
        .character-bio,h2,h3 {
            border: inherit;
            border-width: 1px 0 0 0;
        }
    }
    h2 {
        background-color: rgba(10,70,60,0.25);
    }
    .palette {
        background-color: #6EE67B;
    }
    h2,h3 {
        padding: 1% 0;
        text-align: center;
        margin: 0;
    }
    .character-bio {
        float: center;
        text-align: justify;
        font-size: 90%;
        height: fit-content;
        padding: 2%;
        
        .middle-div {
            display: flex;
            flex-direction: row;
            div {
                width: 50%;
            }
        }
        
        
        .name {
            margin-top: -0.4%;
        }
        
    }
}

.character-portrait {
    float:left;
    border: 1px solid black;
    width: 22%;
    aspect-ratio: 2 / 3;
    margin: 0 1% 1%;
}

.palette {
    float:left;
    margin-right: 1%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 10px;
    padding: 1px;
    .swatch {
        float: left;
        aspect-ratio: 1;
        height: calc(80%);
        border: 0.5px solid black;
        margin: 1px;
    }
    .swatch.dark {
        border-color: whitesmoke;
    }
}

#archive {
    font-size: 80%;
    width: calc(100% - 16px);
    display: flex;
    flex-direction: column;
    align-items: center;
}

#archive-container {
    width: 80%;
}

#archive,#news,#about,#characters {
    overflow-y: scroll;
}

details.chapterHead {
    summary {
        font-family: 'Constantia-Bold';
    }
    div {
        font-family: 'Constantia';
        margin-left: 2%;
    }
}

details.chapterHead > summary {
    display: block;
}

details.chapterHead > summary > sum::after {
    display: inline-block;
    content: '▸';
}

sum {
    cursor: pointer;
    user-select: none;
}

details.chapterHead[open] > summary > sum::after {
    transform: rotate(90deg);
}

details.chapterHead::before {
    
}

details.chapterHead[open] {
    span {
        display: none;
    }
    a {
        div {
            float: left;
            max-width: 10%;
            background-color: #A0C9B3;
            padding: 4px;
            text-align: center;
            aspect-ratio: 2 / 3;
            img {
                aspect-ratio: auto;
                max-height: 90%;
                max-width: 100%;
            }
        }
    }
}

.nav-btn {
    position: relative;
    color: black;
    text-decoration: none;
    z-index: 1;
    height: 8.2%;
    margin: 2px 0;
    display: flex;
    justify-content: center;
    align-items: center;
}

.ends {
    font-family: 'Constantia-Bold';
}

div#bg {
    position:absolute;
    left:50%;
    transform:translate(-50%,0);
    width:80%;
    height:105%;
    background-color:darkslategray;
    z-index: -2;
    padding-bottom: 1%;
    margin:-1% 0;
}

.donate:hover,.nav-btn:hover,.contact:hover {
    cursor: pointer;
}

.insoft {
    border-style:inset;
    border-color: #0003;
}

.forums {
    color: dimgray;
}

#comic-holder {
    height: fit-content;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
}

#page-inf {
    text-align: center;
    width: calc(100%);
    height: 18px;
    padding: 7px 0;
}

footer {
    text-align: center;
    margin-top: 0;
    padding: 8px;
    border: 2px solid black;
    p {
        margin: 4px;
        color: dimgray;
        user-select: none;
        font-size: 90%;
    }
}

#banner, #comic-dets, #news-box, footer, #sub-main {
    width:calc(100%);
    transform:translate(0,0);
    padding: 0%;
}

#sub-main, footer {
    border: 0;
    margin-top: 1%;
    background-image: 
        url('/img/gfx/main-box-ends.png'),
        url('/img/gfx/main-box-ends.png'),
        url('/img/gfx/main-box-mid.png');
    background-repeat:
        no-repeat,
        no-repeat,
        space;
    background-position:
        top,
        bottom,
        center;
    background-size:
        100% auto,
        100% auto,
        100% calc(100% - 100% * 3 / 922);
}

footer {
    padding: 1% 0;
}

@media screen and (max-width: 927px) {
    article {
        min-height: 97.0vw;
    }
    #banner {
         font-size: calc(1.75vw);
    }
    #about,#characters {
        height: 97.0vw;
        max-height: 97.0vw;
    }
    #page-inf {
        height: 5%;
    }
    body {
        font-size: calc(2vw - 14%);
    }
    .character-bio {
        min-height: 15vw;
    }
    .character-portrait {
        width: auto;
        height: 15vw;
    }
    .palette {
        height: calc(1.0vw);
        padding: 0.2%;
    }
}

