:root {
    --tile-size: calc(100vw / 6);
}

.home .page-banner {
    width: 100vw;
    height: 100vh;
}

.tiled-banner-wrapper {
    display: grid;
    grid-template-columns: repeat(var(--tiles-per-row), 1fr);
    grid-template-rows: repeat(var(--tiles-per-row), 1fr);
    height: 100vh;
    width: 100vw;
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100dvh;
    background-color: #575756;
    overflow: hidden;
}

.tiled-banner-wrapper:after {
    content: "";
    display: block;
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    background: #000;
    opacity: 0.25;
}

.banner-tile {
    width: 100%;
    perspective: 1000px;
    background-color: transparent;
    position: relative;
    padding-bottom: 0;
    grid-column: span 1;
}

.banner-tile .item-content-wrapper {
    position: relative;
    width: 100%;
    height: 0;
    padding-bottom: 100%;
    transition: transform 2s ease-in-out;
    transform-style: preserve-3d;
    background-color: transparent;
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    transform: rotateY(var(--rotation-angle));
}

.banner-tile .item-content-wrapper [class*="face-"] {
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    -o-backface-visibility: hidden;
    -moz-backface-visibility: hidden;
    -ms-backface-visibility: hidden;
    overflow: hidden;
    background: 0 0 / 100vw 100vh no-repeat;
    background-position-x: calc(-1 * var(--tile-size) * var(--bg-pos-y));
    background-position-y: calc(-1 * var(--tile-size) * var(--bg-pos-x));
    background-image: var(--bg);
}

.banner-tile .item-content-wrapper .face-a {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 101%;
    z-index: 1;
}
.banner-tile .item-content-wrapper .face-b {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 101%;
    position: absolute;
    top: 0;
    right: 0;
    transform: rotateY(180deg);
    text-align: left;
}
