@media all and (orientation: portrait) {
    :root {
        /*        --green: rgb(30, 93, 72);*/
        /*        --green: rgb(45, 223, 156);*/
        /*        --duck-green: rgb(21, 131, 110);*/
        /*        --orange: rgb(241, 99, 74);*/
        /*        --purple: rgb(145, 93, 251);*/
        /*        --grey: #d8d8d8;*/

        --small-content-size: 12px;
        /*        --small-content-size: 2vw;*/
        --medium-content-size: 3.5vw;
        --content-size: 4vw;
        --big-content-size: 5vw;

        /*
        --small-content-size: 2vh;
        --content-size: 2.5vh;
        --big-content-size: 3vh;
        */

        --small-margin: 2vh;
        --margin: 2.5vh;
        --big-margin: 5vh;
    }

    p {
        font-size: var(--content-size) !important;
    }

    .hidden {
        display: none !important;
    }

    a:not(header a) {
        text-decoration: underline;
        text-underline-position: under;
        color: inherit;
    }
    header a{
        text-decoration: none;
    }

    #content {
        margin-top: 16vh;
    }

    .purple {
        color: var(--purple) !important;
    }

    .duck-green {
        color: var(--duck-green) !important;
    }

    .padding {
        padding: var(--margin);
    }

    html,
    body {
        font-family: 'NYTFRegular', 'NYTFBold', 'NYTFItalic', 'CN' !important;
        font-size: var(--content-size);
        background-color: var(--white);
        margin: 0;
    }

    h1 {
        font-size: var(--big-content-size);
        margin-block-start: 0;
        margin-block-end: 0;
        font-weight: normal;
    }

    h2 {
        font-size: var(--big-content-size);
        margin-block-start: 0;
        margin-block-end: 0;
        font-weight: normal;
    }


    .bloc {
        border-radius: 40px;
        padding: 0 var(--margin);
        height: calc(50% - var(--small-margin));
        flex-direction: column;
        justify-content: space-between;
    }

    li.active:not(.navbar li:first-of-type) {
        filter: drop-shadow(0px 0px 0.25px yellow);
    }

    li.active > .home {
        /*    padding-right: var(--big-margin);*/
    }

    h1:not(.home h1, .title h1, h1.word) {
        /*
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
        */
        /*    position: relative;*/
        /*        height: -webkit-fill-available;*/
        height: auto;
        background-color: greenyellow;
        color: var(--duck-green);
        padding: 0 var(--margin);

        -webkit-mask-image:
            radial-gradient(circle at top left, transparent 0, transparent 10px, black 11px),
            radial-gradient(circle at top right, transparent 0, transparent 10px, black 11px),
            radial-gradient(circle at bottom left, transparent 0, transparent 10px, black 11px),
            radial-gradient(circle at bottom right, transparent 0, transparent 10px, black 11px);
        -webkit-mask-position: top left, top right, bottom left, bottom right;
        -webkit-mask-repeat: no-repeat;
        -webkit-mask-size: 50% 50%;

        mask-image:
            radial-gradient(circle at top left, transparent 0, transparent 10px, black 11px),
            radial-gradient(circle at top right, transparent 0, transparent 10px, black 11px),
            radial-gradient(circle at bottom left, transparent 0, transparent 10px, black 11px),
            radial-gradient(circle at bottom right, transparent 0, transparent 10px, black 11px);
        mask-position: top left, top right, bottom left, bottom right;
        mask-repeat: no-repeat;
        mask-size: 50% 50%;
    }

    /*
    h1:not(.home h1) .word{
    margin-right: calc(var(--small-content-size)/2);
}
    h1:not(.home h1) .word:nth-of-type(1n){
    padding: calc(var(--small-content-size)/2) 0;
}
    h1:not(.home h1) .word:nth-of-type(2n){
    padding: calc(var(--small-content-size)/2) 0;
}
    h1:not(.home h1) .word:nth-of-type(3n){
    padding: calc(var(--small-content-size)/2) 0;
}
    */

    .flex {
        display: flex;
    }

    li {
        display: inline-flex;
        padding-right: var(--big-margin);
    }

    li:last-of-type {
        padding-right: 0;
    }

    header li {
        padding-right: 0;
        font-size: var(--big-content-size);
        margin: 0 0 var(--small-content-size) 0;
        width: 100%;
    }

    ul,
    ol,
    li {
        list-style-type: none;
        margin-block-start: 0;
        margin-block-end: 0;
        margin-inline-start: 0px;
        margin-inline-end: 0px;
        padding-inline-start: 0;
    }

    ol {
        display: flex;
        flex-direction: column;
        align-items: center;
        counter-reset: my-counter;
    }

    ol li {
        padding-right: 0 !important;
        padding: calc(var(--small-margin) / 2);
    }

    ol li:before {
        counter-increment: my-counter 1;
        content: counter(my-counter) ".";
        margin-right: var(--small-margin);
    }

    ol li a {
        text-decoration: none;
        color: black;
    }

    ol li a:hover {
        text-decoration: underline;
    }

    body {
        counter-reset: image-counter;
    }

    .image-description {
        color: var(--orange);
        font-size: var(--content-size);
    }

    .image-description:before {
        counter-increment: image-counter 1;
        content: "fig. "counter(image-counter);
        margin-right: var(--big-margin);
    }

    header {
        position: fixed;
        top: 0;
        overflow: hidden;
        width: calc(100vw - (var(--big-margin) * 2));
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        padding: var(--margin);
        height: auto;
        margin: var(--margin);
        border-radius: 40px;
        /*        background-color: var(--white);*/
        /* glass blur */
        background: rgba(255, 255, 255, 0.6);
        box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
        backdrop-filter: blur(40px);
        -webkit-backdrop-filter: blur(40px);
        /* */

        /*        background: red;*/
        z-index: 1000;

        /*        filter: drop-shadow(0px 0px 2000px rgba(240,240,240,0));*/
        /*        filter: drop-shadow(0px 0px 2000px black);*/
        /*        box-shadow: 0px 0px 200px rgb(200, 200, 200);*/
        transition: 1s all ease-in-out !important;
    }

    header.open {
        transition: .5s all ease-in-out;
        /*        filter: drop-shadow(0px 0px 2000px var(--purple));*/
        box-shadow: 0px 0px 200px var(--purple);
    }

    .navbar {
        display: flex;
        flex-direction: column;
    }

    .navbar li:not(.menu li):not(.extra li) {
        margin-bottom: 0;
    }

    .navbar.menu,
    .navbar.extra {
        display: none;
    }

    .navbar.menu {
        margin-top: var(--margin);
    }

    .extra {
        margin-top: var(--big-margin);
    }

    .navbar li a {
        width: 100%;
        display: flex;
        justify-content: center;
    }

    .nav {
        color: var(--orange);
    }

    .home {
        color: var(--green);
        justify-content: flex-start !important;
        flex: 1;
    }

    .home .word:last-of-type {
        color: black;
    }

    .home .word:nth-of-type(1n) {
        padding: var(--small-content-size) 0;
        padding-bottom: 0 !important;
    }

    .home .word:nth-of-type(2n) {
        padding: var(--content-size) 0;
        padding-bottom: 0 !important;
    }

    .home .word:nth-of-type(3n) {
        padding: var(--content-size) 0;
        padding-bottom: 0 !important;
    }

    .home .word:nth-of-type(4n) {
        padding: 0;
    }

    .mobile-nav {
        display: block;
        justify-content: flex-end !important;
        flex: 0;
    }

    .menu {
        margin-left: 0;
        flex: unset;
    }


    .nav-btn-container {
        line-height: 0;
        width: calc(6px + calc(0.3vw + 0.3vh)* 10);
        margin-right: calc(calc(6px + calc(0.3vw + 0.3vh)* .5)* -.5);
        margin-bottom: calc(calc(6px + calc(0.3vw + 0.3vh)* .5)* -1);
        margin-top: calc(calc(6px + calc(0.3vw + 0.3vh)* .5)* -1);
        display: flex;
        align-content: center;
        align-items: center;
        justify-content: center;
    }

    .line {
        fill: black;
        stroke: black;
        stroke-width: 6px;
        stroke-linecap: round;
        stroke-linejoin: round;
        transform-origin: 50%;
        transition: stroke-dasharray 500ms 200ms, stroke-dashoffset 500ms 200ms, transform 500ms 200ms;
    }

    .burger{
        width: 15vw;
        height: 15vw;
    }
    .burger .x {
        transition: transform 400ms;
    }

    .burger .line {
        transform-origin: 50%;
        transition: transform 400ms 100ms;
    }

    .active.burger .line {
        transition: transform 400ms;
    }

    .active.burger .line1 {
        transform: translateX(22px) translateY(-3px) rotate(-45deg) scale(.9);
    }

    .active.burger .line2 {
        transform: translateX(-22px) translateY(-3px) rotate(45deg) scale(.9);
    }

    .active.burger .line3 {
        transform: translateY(0px) rotate(45deg) scale(.9);
    }

    .active.burger .line4 {
        transform: translateY(0px) rotate(-45deg) scale(.9);
    }

    .active.burger .line5 {
        transform: translateX(22px) translateY(3px) rotate(45deg) scale(.9);
    }

    .active.burger .line6 {
        transform: translateX(-22px) translateY(3px) rotate(-45deg) scale(.9);
    }

    .active.burger .x {
        transition: transform 400ms 100ms;
        transform: scale(1);
    }

    .word {
        width: auto;
        position: relative;
        float: left;
    }

    .word:nth-of-type(1n) {
        padding: var(--small-content-size) 0;
    }

    .word:nth-of-type(2n) {
        padding: var(--content-size) 0;
    }

    .word:nth-of-type(3n) {
        padding: 0;
    }


    .button {
        border-radius: 40px;
        color: white;
        background-color: black;
        padding: calc(var(--small-margin)/2) var(--small-margin);
    }

    #typo-nav, #bottomnav{
        pointer-events: all;
    }
    #bottomnav {
        /*    flex: 1;*/
        position: relative;
        /*        position: absolute;*/
        width: 100%;
        /*        width: calc(100% - var(--big-margin));*/
        bottom: 0;
        padding: var(--margin);
        justify-content: space-between;
        flex-direction: column;
        text-align: center;
    }
    #bottomnav a {
        white-space: nowrap;
        margin-left: var(--margin);
        margin-right: var(--margin);
    }
    #info-container{
        margin-top: var(--small-margin);
    }
    #info-container a{
        margin-right: var(--margin);
    }


    .tags {
        margin-bottom: var(--small-margin);
    }

    .tags a {
        margin-right: var(--small-margin);
        color: black;
    }



    .typeface .detail {
        margin: var(--margin) 0;
        justify-content: space-between;
    }

    .typeface .detail * {
        width: 33%;
    }

    .typeface .detail h2 {
        margin-top: 0;
        text-align: left;
    }

    .typeface .detail .year {
        margin-top: 0;
        text-align: right;
    }

    .typeface .detail,
    .typeface .type-more {
        font-family: 'NYTFRegular', 'NYTFBold', 'NYTFItalic' !important;
    }

    .type-container {
        flex: 1;
        width: -webkit-fill-available;
        overflow: hidden;
    }

    .type-more {
        /*    flex: 1;*/
        width: 100%;
        bottom: 0;
        margin: var(--small-margin) 0;
        justify-content: space-between;
    }

    .type-more .button {
        padding: calc(var(--small-margin)/2) var(--big-margin);
    }

    .specimen {
        display: grid;
        grid-template-columns: 1.5fr 0.5fr;
        grid-template-rows: 1fr 1fr 1fr;
        gap: var(--small-margin) var(--small-margin);
        grid-template-areas:
            "first-img scnd-img"
            "first-img third-img"
            "first-img fourth-img";
    }

    .specimen-image:nth-child(1n) {
        grid-area: first-img;
    }

    .specimen-image:nth-child(2n) {
        grid-area: scnd-img;
    }

    .specimen-image:nth-child(3n) {
        grid-area: third-img;
    }

    .specimen-image:nth-child(4n) {
        grid-area: fourth-img;
    }

    .specimen-image {
        overflow: hidden;
        /*    background-color: black;*/
    }

    .specimen-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .specimen,
    .try-it,
    .in-use {
        position: relative;
        /*    background-color: aliceblue;*/
        width: 100%;
        height: 100%;
    }



    .try-it {
        font-size: 12vw;
        text-align: left;
        vertical-align: middle;
        display: flex;
        align-items: flex-end;
        overflow: hidden;
        overflow-y: scroll;
    }

    .try-it:focus {
        outline: none;
    }





    .in-use {
        display: grid;
        grid-template-columns: 1.5fr 0.5fr;
        grid-template-rows: 1fr 1fr 1fr;
        gap: var(--small-margin) var(--small-margin);
        grid-template-areas:
            "first-img scnd-img"
            "first-img third-img"
            "first-img fourth-img";
    }

    .in-use-image:nth-child(1n) {
        grid-area: first-img;
    }

    .in-use-image:nth-child(2n) {
        grid-area: scnd-img;
    }

    .in-use-image:nth-child(3n) {
        grid-area: third-img;
    }

    .in-use-image:nth-child(4n) {
        grid-area: fourth-img;
    }

    .in-use-image {
        overflow: hidden;
        /*    background-color: black;*/
    }

    .in-use-image img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

    .specimen-image:nth-child(2n),
    .specimen-image:nth-child(3n),
    .specimen-image:nth-child(5n),
    .in-use-image:nth-child(2n),
    .in-use-image:nth-child(3n),
    .in-use-image:nth-child(4n) {
        cursor: pointer;
    }






    .section {
        margin-bottom: calc(var(--big-margin) + var(--margin));
    }

    .section h2 {
        font-size: 5vh;
        margin: var(--small-margin) 0;
    }


    .info-content{
        max-height:  calc(100dvh - (var(--big-margin) * 5) - var(--small-margin));
    }

}
