html, body {
    overflow-x: auto;
    overflow-y: auto;
    width: auto;
    min-width: 100%;
    height: calc(100 * var(--vh) - var(--scrollbar-width));
    scroll-behavior: auto;
}
main {
    display: flex;
    flex-flow: row;
    height: calc(100 * var(--vh) - var(--scrollbar-width));
    min-height: 630px;
    padding: 100px 0px 100px calc(30 * var(--vw));
    box-sizing: border-box;
    width: auto;
    position: relative;
    gap: 40px;
}
.work-el,
#work-outro {
    flex: 0 0 auto;
    width: auto;
    height: calc(100 * var(--vh) - var(--scrollbar-width) - 200px);
    min-height: 500px;
}
#work-intro {
    width: calc(30 * var(--vw));
    position: fixed;
    height: calc(100 * var(--vh) - var(--scrollbar-width));
    min-height: 630px;
    padding: 100px 40px 100px 40px;
    left: 0px;
    top: 0px;
    background-color: var(--nero);
    box-sizing: border-box;
    display: flex;
    flex-flow: column;
    justify-content: space-between;
    z-index: 5000;
}
#work-intro * {
    text-align: right;
}
#work-intro h1 {
    font-size: 40px;
    line-height: 46px;
    font-weight: 300;
}
#work-intro-extra {
    margin-top: 10px;
}
.work-el picture,
.work-el img {
    display: block;
    float: left;
}
.work-picture-full,
.work-picture-full img {
    width: auto;
    height: 100%;
}
.work-figure .work-picture-full {
    width: 100%;
}
.work-el-image2_16x9 .work-figure {
    height: calc((100% - 40px) / 2);
    aspect-ratio: 16/9;
}
.work-el-image2_1x1 .work-figure {
    height: calc((100% - 40px) / 2);
    aspect-ratio: 1/1;
}
.work-el-image2_16x9 .work-figure img,
.work-el-image2_1x1 .work-figure img {
    width: 100%;
    object-fit: cover;
}
.work-el.work-el-image2_16x9,
.work-el.work-el-image2_1x1 {
    display: flex;
    flex-flow: column;
    gap: 40px;
}
.work-el video {
    display: block;
    float: left;
    height: 100%;
    width: auto;
    max-width: unset;
}
.video-overlay {
    position: absolute;
    inset: 0;
    z-index: 1;
    cursor: pointer;
    height: 100%;
    width: 100%;
    top: 0px;
    left: 0px;
}
.work-el.work-el-testo {
    display: flex;
    width: calc(40 * var(--vw));
}
.work-el.work-el-testo-lungo {
    display: flex;
    width: calc(35 * var(--vw));
    overflow: hidden;
    padding-left: 20px;
    padding-right: 20px;
    align-items: center;
}
.work-el-testo-middle {
    align-items: center;
}
.work-el-testo-bottom {
    align-items: flex-end;
}
#work-testo-overlay {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0px;
    left: 0px;
    background-color: rgba(0,0,0, 0.95);
    z-index: 9996;
}
#work-testo-overlay.hidden,
.work-el-testo_lungo-popup.hidden {
    display: none;
}
.work-el-testo_lungo-popup {
    position: fixed;
    z-index: 9997;
    width: calc(35 * var(--vw));
    min-width: 300px;
    background-color: var(--nero);
    box-shadow: -1px 0px 40px 0px rgba(0,0,0,0.35);
    -webkit-box-shadow: -1px 0px 40px 0px rgba(0,0,0,0.35);
    -moz-box-shadow: -1px 0px 40px 0px rgba(0,0,0,0.35);
    max-height: calc(95 * var(--vh) - var(--scrollbar-width));
    padding: 40px;
    box-sizing: border-box;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    overflow-y: auto;
    overscroll-behavior: contain;
}
.work-el-btn-hide {
    position: absolute;
    height: 40px;
    width: 40px;
    display: block;
    float: left;
    line-height: 40px;
    text-align: center;
    right: 0px;
    top: 0px;
}
.work-el-btn-show,
.work-el-btn-hide {
    color: var(--grigio_link);
    transition: color 0.4s;
    -webkit-transition: color 0.4s;
}
@media only screen and (min-width: 1201px) and (max-width: 10000px) {
    .work-el-btn-show:hover,
    .work-el-btn-hide:hover {
        color: var(--bianco);
        transition: color 0.4s;
        -webkit-transition: color 0.4s;
    }
}

#work-outro {
    display: flex;
    padding: 0px 80px 0px 30px;
    align-items: center;
    box-sizing: border-box;
    width: 480px;
}
#work-outro-category,
#work-dove-quando {
    font-size: 14px;
    line-height: 22px;
    font-weight: 400;
    color: var(--bianco);
}
#work-outro-category {
    font-weight: 700;
}
#work-outro-titolo {
    font-size: 30px;
    line-height: 36px;
    font-style: normal;
    font-weight: 300;
    margin: 5px 0px;
    position: relative;
    color: var(--bianco);
}
#work-outro-titolo .arrow-right-svg {
    height: 20px;
    width: 20px;
    display: block;
    position: absolute;
    left: -25px;
    top: 8px;
}
@media only screen and (min-width:1024px) and (max-width:1279px) {
    main {
        padding: 100px 0px 100px calc(35 * var(--vw));
    }
    #work-intro {
        width: calc(35 * var(--vw));
    }
}
@media only screen and (min-width:1024px) and (max-width:1920px) {
    #work-intro {
        width: calc((50 + (((1920 - (100 * var(--vw-n))) / 896) - 1) * 15) * var(--vw));
    }
    main {
        padding: 100px 0px 100px calc((50 + (((1920 - (100 * var(--vw-n))) / 896) - 1) * 15) * var(--vw));
    }
}
@media only screen and (min-width:1024px) and (max-width:1279px) {
    #work-intro {
        font-size: 12px;
        line-height: 16px;
    }
    #work-intro h1 {
        font-size: 30px;
        line-height: 36px;
    }
}

@media only screen and (min-width:220px) and (max-width:1023px) {
    html, body {
        overflow-x: auto;
        overflow-y: auto;
        width: 100vw;
        min-width: 100%;
        height: auto;
        scroll-behavior: auto;
    }
    main {
        display: block;
        height: auto;
        min-height: 100vh;
        padding: unset;
        box-sizing: border-box;
        width: 100%;
    }
    #work-intro {
        display: block;
        position: static;
        width: 100%;
        min-height: unset;
        height: auto;
        padding: 90px 40px 0px 40px;
        box-sizing: border-box;
    }
    #work-intro-top {
        margin-bottom: 20px;
    }
    #work-intro * {
        text-align: left;
    }
    #work-intro-extra {
        margin-top: 20px;
    }
    .work-el, #work-outro {
        width: 100%;
        height: auto;
        min-height: unset;
        margin-top: 20px;
    }
    .work-el.work-el-testo {
        display: block;
        width: 100%;
        box-sizing: border-box;
        padding: 20px 40px;
    }
    .work-picture-full, .work-picture-full img {
        width: 100%;
        height: auto;
    }
    .work-el.work-el-image2_16x9, .work-el.work-el-image2_1x1 {
        display: block;
    }
    .work-el-image2_16x9 .work-figure,
    .work-el-image2_1x1 .work-figure {
        height: auto;
        width: 100%;
    }
    .work-el-image2_16x9 .work-figure:nth-child(2),
    .work-el.work-el-image2_1x1 .work-figure:nth-child(2) {
        margin-top: 20px;
    }
    #work-outro {
        padding: 40px;
        box-sizing: border-box;
        margin-top: 0px;
    }
    .work-el-testo_lungo-popup {
        width: calc(90 * var(--vw));
    }
    #work-outro a {
        width: 100%;
    }
    .work-el.work-el-testo-lungo {
        width: 100%;
        overflow: auto;
        padding: 0px 40px;
        box-sizing: border-box;
    }
}
