/* -------------------------------------------------- home -------------------------------------------------- */

body.plain {  
    width: 100vw;
    height: 100svh;
    max-height: 100svh;
    overflow: hidden;
    display: grid;
    grid-template-columns: auto;
    grid-template-rows: auto auto 1fr;
    gap: 0px 0px;
    grid-auto-flow: row;
    grid-template-areas:
        "header"
        "nav"
        "main";
}
body.plain *{
    position: relative;
}

body.plain header { grid-area: header; }

body.plain nav { grid-area: nav; height: auto; padding: 0 1vw 1vw 0; width: auto; max-width: unset;}

body.plain nav a{
    font-size: clamp(6svh,7.95vw,15svh);
    line-height: 1.2;
    height: auto !important;
    width: inherit;
}

body.plain nav>ul, body.plain nav#topNav ul { 
    height: 100%; width: 100%; 
    display: flex;
    justify-content: flex-start;
    align-items: flex-start;
    flex-direction: column;
    gap: 0;
}
body.plain nav>ul li a{ writing-mode: initial; height: 100%; display: flex; align-content: center; align-items: center; justify-content: center;}
body.plain nav a.events{
    width: auto;
}    
body.plain nav a.about{
    width: auto;
}

body.plain nav .events.book{
    transform: rotate(0deg);
    transform-origin: right bottom;
    margin-right: 0;
    line-height: 1;
    padding: 0;
    text-align: center;
    position: relative;
    bottom: 0;
    right: unset;
    width: auto;
    height: auto;
    max-height: unset;
}
body.plain nav .about.book{
    transform: rotate(0deg);
    transform-origin: right bottom;
    margin-right: 0;
    line-height: 1;
    padding: 0;
    text-align: center;
    position: relative;
    bottom: 0;
    right: unset;
    width: auto;
    height: auto;
    max-height: unset;
}
body.plain nav .locations.book{
    transform: rotate(0deg);
    transform-origin: right bottom;
    margin-right: 0;
    line-height: 1;
    padding: 0;
    text-align: center;
    position: relative;
    bottom: 0;
    right: unset;
    width: auto;
    height: auto;
    max-height: unset;
    margin-bottom: 0;
}
body.plain nav .book span{ transform: rotate(0deg); text-align: center;}

body.plain main { 
    grid-area: main; 
    height: auto; 
    padding: 0; 
    max-width: 100%;
    width: 100%;
}

body.plain #content{
    height: auto;
    width: auto;
    align-items: flex-end;
    justify-content: flex-end;
    padding: 0;
    width: 100%;
    height: 100%;
}
body.plain #content .event, body.plain #content>a{
    width: auto;
}
body.plain #content .event .book.title, body.plain #content .event .book.date{
    margin: 0;
    margin-right: 0;
    margin-left: 0;
    margin-top: 4svh;
    margin-bottom: 0;
    transform-origin: unset;
    transform: rotate(0deg);
    background: transparent;
    text-align: left;
    width: auto;
    display: inline-block;
    padding: 0;
}
body.plain #content .event h2 {
    font-size: clamp(4svh,4vw,8svh) !important;
    margin: unset; 
    padding: 0;
}
body.plain #content .event .book.title{
    position: relative;
    font-size: clamp(4svh,4vw,8svh) !important;
    line-height: 0.95;
    /*        padding:5vw 3vw 4vw 3vw;*/
    transform-origin: bottom left;
    transform: rotate(0deg);
    margin-bottom: 1vw;
    margin-left: 0;
    height: auto;
    max-height: unset;
    color: var(--color);
}

    body.plain nav li.events{
        order: 1;
    }
    body.plain nav li.locations{
        order: 2;
    }
    body.plain nav li.about{
        order: 3;
    }

    body.plain nav #currentEvent{
        order: 4;
    }
body.plain #content .event{
    cursor: default;
}

body.plain #content .event{
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: flex-end;
}
body.plain #titleCard{
    display: flex !important;
    flex-direction: column-reverse !important;
    align-content: flex-start !important;
    align-items: flex-start !important;
}
body.plain #Newsevent #titleCard{
    flex-direction: column !important;
}
body.plain #titleCard *{
    text-align: left;
}
body.plain #content .event:hover .book{
    color: var(--color) !important;
    background: var(--background) !important;
    cursor: pointer;
    text-decoration: underline;
}

body.plain .events.book, body.plain .about.book, body.plain .locations.book, body.plain{
    background: var(--background);
    color: var(--color);
}

@media all and (max-width: 780px) and (orientation: portrait){
    /* -------------------------------------------------- home -------------------------------------------------- */
    body.plain{
        grid-template-columns: 1fr;
        grid-template-rows: auto 1fr auto;
        gap: 0px 0px;
        grid-auto-flow: row;
        grid-template-areas:
            "header"
            "nav";
        overflow-y: auto;
        min-height: 100svh;
        height: auto;
        max-height: unset;
        padding-bottom: 15svh;
    }
    body.plain header{
        font-size: 18.5vw;
        line-height: 0.9;
        padding:  3svh 2vw 0 2vw;
    }
    body.plain nav{
        height: auto;
        padding: 2vw;
        width: 100%;
        max-width: 100%;
    }
    body.plain nav a.events, body.plain nav a.about{
        width: 100%;
    }
    body.plain nav#topNav ul{
        flex-direction: column;
        gap: 0;
    }
    body.plain nav>ul li{
        justify-content: flex-start;
        margin-bottom: 0svh;
    }
    body.plain nav .events.book a{
        transform: rotate(0deg);
        right: unset;
        width: 100%;
        max-width: 100%;
        background: transparent;
    }
    body.plain nav .about.book a{
        transform: rotate(0deg);
        right: unset;
        width: 100%;
        max-width: 100%;
        background: transparent;
    }
    body.plain nav .events.book a, body.plain nav .about.book a{
        transform-origin: center;
        margin-right: 0vw;
        line-height: 1;
        padding: 0;
        text-align: left;
        height: auto;
        writing-mode: unset;
        font-size: 18.5vw;
        position: relative;
    }
    body.plain #content a:hover{
        text-decoration: none;
    }
    body.plain #content .event:hover .book.date, body.plain #content .event:hover .book.title{
        background: var(--color);
        color: var(--background);
    }

    body.plain nav .book span {
        transform: rotate(0deg);
        text-align: center;
    }

    body.plain main{
        padding: 2vw;
        padding-bottom: 4svh;
        height: auto;
        width: 100%;
        max-width: 100%;
    }

    body.plain #content{
        width: 100%;
        height: auto;
    }
    body.plain #content a{
        width: 100%;
        height: auto;
    }

    body.plain #content .event{
        display: flex;
        flex-direction: column-reverse;
        padding: 0;
        background: transparent;
        height: auto;
        align-items: baseline;
        justify-content: flex-end;
        transform: rotate(0deg);
    }

    body.plain #content .event .book.title, body.plain #content .event .book.date{
        font-size: clamp(4svh,4vw,8svh) !important;
        line-height: 0.95;
        padding: 0;
        transform-origin: center;
        transform: rotate(0deg);
        margin-bottom: 0vw;
        margin-left: 0vw;
        margin-right: 0vw;
        background: transparent;
        height: auto;
        max-height: unset;
    }
    body.plain #content .event .book.title, body.plain #content .event .book.date{
        text-align: left;
    }
}