:root {
    color-scheme: dark;
    --header-height: 3.5rem;
    --footer-height: 3.25rem;
    --gutter: clamp(1rem, 4vw, 4rem);
    --content-width: 84rem;
    --wide-inset: max(0px, calc((100% - var(--content-width)) / 2 - var(--gutter)));
    --background: #101719;
    --text: #f6f8f5;
    --muted-text: #dae3e3;
    --focus: #b9eaa5;
    background: var(--background);
    color: var(--text);
    font-family: system-ui, sans-serif;
    scroll-padding-top: var(--header-height);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    line-height: 1.55;
}

a {
    color: inherit;
}

a:focus-visible {
    outline: 2px solid var(--focus);
    outline-offset: 4px;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
}

.skip-link {
    position: fixed;
    z-index: 5;
    inset: .5rem auto auto .5rem;
    padding: .6rem 1rem;
    border-radius: .25rem;
    background: var(--background);
    transform: translateY(-150%);
}

.skip-link:focus {
    transform: none;
}

.site-header {
    container-type: inline-size;
    position: sticky;
    z-index: 3;
    top: 0;
    display: flex;
    justify-content: space-between;
    gap: .5rem;
    min-height: var(--header-height);
    padding-inline: calc(var(--gutter) + var(--wide-inset));
    border-bottom: 1px solid #ffffff1a;
    background: #101719;
}

.studio-link {
    display: inline-flex;
    flex: none;
    align-items: center;
    align-self: center;
    gap: .65rem;
    min-width: 2.75rem;
    min-height: 2.75rem;
    border-radius: .35rem;
    font-size: .9375rem;
    font-weight: 700;
    letter-spacing: .11em;
    text-decoration: none;
}

.studio-link img {
    display: block;
    width: 2.625rem;
    height: 2.625rem;
    border-radius: inherit;
}

.site-nav {
    display: flex;
    justify-content: flex-end;
}

.site-nav a {
    display: inline-grid;
    min-height: 2.75rem;
    place-items: center;
    padding-inline: clamp(1rem, 1.8vw, 1.5rem);
    color: var(--muted-text);
    font-size: .9375rem;
    font-weight: 550;
    text-decoration: none;
    white-space: nowrap;
}

.nav-game-logo {
    display: block;
    width: 5.25rem;
    height: auto;
}

.nav-game-logo--hostile {
    width: 7rem;
}

.site-nav a:hover {
    background: #1a2324;
    color: var(--text);
}

.site-nav a[aria-current="page"] {
    background: #243130;
    color: var(--text);
}

.site-nav a:focus-visible {
    outline-offset: -3px;
}

.site-nav .home-link,
.site-nav .contact-link {
    min-width: 2.75rem;
}

.home-icon,
.contact-icon {
    width: 1.05rem;
    height: 1.05rem;
    background: currentColor;
}

.home-icon {
    mask: url("media/home-outline.svg") center / contain no-repeat;
}

.contact-icon {
    mask: url("media/contact-outline.svg") center / contain no-repeat;
}

.hostile-theme {
    --stage: #14242e;
    --accent: #e0edf5;
    --accent-ink: #122430;
}

.minimal-theme {
    --stage: #102b2e;
    --accent: #a5ede0;
    --accent-ink: #102c2c;
}

.cinema {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    background: var(--stage);
}

.cinema::after {
    content: "";
    position: absolute;
    z-index: -1;
    inset: 0;
    background: var(--scrim);
    pointer-events: none;
}

.background-video {
    position: absolute;
    z-index: -2;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
}

.home-stage {
    --panel-width: 56%;
    --panel-padding: max(0px, calc(100% - var(--panel-width) - var(--content-width) / 2));
    position: relative;
    min-height: max(19rem, calc(100svh - var(--header-height) - var(--footer-height)));
    background: #172024;
}

.home-stage::after {
    content: "";
    position: absolute;
    z-index: 1;
    inset: 0;
    clip-path: polygon(55.92% 0, 56.08% 0, 44.08% 100%, 43.92% 100%);
    background: #d9e7e965;
    pointer-events: none;
}

.game-link {
    --scrim: radial-gradient(ellipse at center, #07101680, #07101626 70%),
        linear-gradient(180deg, #0610181a, #0610182e 42%, #061018ad 100%);
    position: absolute;
    inset-block: 0;
    display: grid;
    width: var(--panel-width);
    place-items: center;
    text-decoration: none;
}

.game-link--hostile {
    left: 0;
    padding-inline-start: var(--panel-padding);
    clip-path: polygon(0 0, 100% 0, 78.571% 100%, 0 100%);
}

.game-link--minimal {
    right: 0;
    padding-inline-end: var(--panel-padding);
    clip-path: polygon(21.429% 0, 100% 0, 100% 100%, 0 100%);
}

.game-link-content {
    display: grid;
    justify-items: center;
    gap: 1.1rem;
    width: min(76%, 32rem);
    translate: -5% 0;
}

.game-link--minimal .game-link-content {
    translate: 5% 0;
}

.game-logo {
    display: grid;
    align-content: center;
    justify-items: center;
    width: min(100%, 34rem);
    margin: 0;
    filter: drop-shadow(0 3px 12px #050b10b0);
}

.game-logo img {
    display: block;
    width: 100%;
    height: auto;
}

.game-logo--minimal {
    width: min(83%, 26rem);
}

.game-link .game-logo {
    min-height: clamp(6.25rem, 14vw, 10rem);
}

.game-status {
    color: var(--muted-text);
    font-size: .9375rem;
    font-weight: 550;
    text-align: center;
    text-shadow: 0 2px 10px #050a0e;
}

.game-link-action {
    padding: .55rem 1.15rem;
    border: 1px solid #f6f8f58c;
    border-radius: 2rem;
    background: #0d161bbd;
    color: var(--text);
    font-size: .9375rem;
    font-weight: 600;
}

.game-link:hover .game-link-action,
.game-link:focus-visible .game-link-action {
    border-color: var(--accent);
    background: var(--accent);
    color: var(--accent-ink);
}

.game-link:focus-visible .game-link-action {
    outline: 2px solid var(--focus);
    outline-offset: 4px;
}

.game-hero {
    --scrim: radial-gradient(ellipse at center, #060d167a, #060d1600 75%),
        linear-gradient(180deg, #060d161f 5%, #060d1652 40%, #060d16d6 100%);
    display: grid;
    min-height: clamp(30rem, 78svh, 56rem);
    place-items: center;
    padding: 3rem var(--gutter);
    text-align: center;
}

.game-hero-content {
    display: grid;
    justify-items: center;
    gap: 1.3rem;
    width: min(100%, 42rem);
}

.game-hero p {
    max-width: 38ch;
    margin: 0;
    font-size: clamp(1.0625rem, 1.6vw, 1.25rem);
    text-shadow: 0 2px 10px #050a0e;
    text-wrap: pretty;
}

.game-hero .game-facts {
    max-width: none;
    color: var(--muted-text);
    font-size: .9375rem;
}

.game-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: .65rem;
}

.game-action-drawer {
    position: absolute;
    inset-block-start: 100%;
    inset-inline: 0;
    overflow: hidden;
}

.game-action-drawer[inert] {
    pointer-events: none;
}

.game-actions--floating {
    gap: .5rem;
    padding: .25rem var(--gutter);
    border-block: 1px solid #ffffff24;
    background: #1b2529;
    text-align: center;
    transform: translateY(-100%);
}

.game-action-drawer:not([inert]) .game-actions--floating {
    transform: translateY(0);
}

.steam-link,
.press-primary,
.game-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2.75rem;
    padding: .65rem 1.15rem;
    border: 1px solid;
    border-radius: .35rem;
    font: inherit;
    font-weight: 700;
    text-decoration: none;
}

.steam-link,
.press-primary {
    border-color: var(--accent);
    background: var(--accent);
    color: var(--accent-ink);
}

.steam-link:hover,
.press-primary:hover {
    background: var(--accent-ink);
    color: var(--accent);
}

.game-secondary {
    border-color: #f6f8f550;
    background: #0d161bdf;
    color: var(--muted-text);
}

a.game-secondary {
    color: var(--text);
}

a.game-secondary:hover {
    border-color: var(--accent);
}

.game-actions--floating > * {
    min-height: 1.75rem;
    padding: .15rem .65rem;
    font-size: .875rem;
    line-height: 1.25;
}

.game-actions--floating a:focus-visible {
    outline-offset: 1px;
}

.feature {
    --scrim-width: calc(100% - 2 * var(--wide-inset));
    --scrim: linear-gradient(var(--scrim-angle, 90deg), #081217f5,
        #081217de calc(var(--wide-inset) + .24 * var(--scrim-width)),
        #081217ad calc(var(--wide-inset) + .34 * var(--scrim-width)),
        #08121715 calc(var(--wide-inset) + .63 * var(--scrim-width)));
    display: grid;
    align-items: center;
    min-height: clamp(26rem, 68svh, 52rem);
    padding-inline: var(--wide-inset);
    border-top: 1px solid #f5f8fa26;
}

.feature:nth-child(even) {
    --scrim-angle: 270deg;
    justify-items: end;
}

.minimal-theme .feature .background-video {
    object-position: center 15%;
}

.feature-copy {
    width: 33.333%;
    padding: 2.5rem var(--gutter);
}

.feature-copy h2 {
    margin: 0 0 .85rem;
    font-size: clamp(2rem, 3.6vw, 3.75rem);
    font-weight: 700;
    line-height: 1.06;
    letter-spacing: -.045em;
    text-wrap: balance;
}

.feature-copy p {
    max-width: 36ch;
    margin: 0;
    color: var(--muted-text);
    font-size: clamp(1rem, 1.15vw, 1.1875rem);
    text-wrap: pretty;
}

.game-closing {
    display: grid;
    place-items: center;
    padding: clamp(2.5rem, 6vw, 5rem) var(--gutter);
    border-top: 1px solid #ffffff1a;
    background: var(--stage);
}

.game-closing .steam-link {
    width: min(100%, 22rem);
    min-height: 3.75rem;
    font-size: clamp(1.125rem, 1.7vw, 1.375rem);
}

.contact {
    max-width: 47rem;
    margin-inline: auto;
    padding: clamp(1.5rem, 5vw, 4.5rem) var(--gutter);
}

.contact iframe {
    display: block;
    width: 100%;
    height: 43rem;
    margin-top: 1.25rem;
    border: 0;
    border-radius: .5rem;
    background: #f2ebfc;
    color-scheme: light;
}

.contact p {
    margin: 1rem 0 0;
}

.contact-privacy {
    color: var(--muted-text);
}

.contact a {
    text-underline-offset: .2em;
}

.press-page {
    width: min(var(--content-width), calc(100% - 2 * var(--gutter)));
    min-height: calc(100svh - var(--header-height) - var(--footer-height));
    margin-inline: auto;
    padding-block: clamp(2rem, 5vw, 4.5rem);
}

.press-heading {
    display: grid;
    justify-items: start;
    gap: .85rem;
}

.press-title {
    margin: 0;
    font-size: clamp(2.5rem, 5vw, 4.25rem);
    line-height: 1.05;
    letter-spacing: -.045em;
}

.press-heading p {
    max-width: 58ch;
    margin: 0;
    color: var(--muted-text);
}

.press-heading .game-logo {
    max-width: 28rem;
}

.press-link,
.site-footer a {
    text-underline-offset: .2em;
}

.press-games,
.press-details {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(1rem, 3vw, 2rem);
}

.press-games {
    margin-top: clamp(1.5rem, 4vw, 2.75rem);
}

.press-card,
.press-gallery a {
    overflow: hidden;
    border: 1px solid #ffffff20;
    border-radius: .45rem;
    background: #172225;
}

.press-card img,
.press-gallery img {
    display: block;
    width: 100%;
    height: auto;
}

.press-card-copy,
.press-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
}

.press-card-copy {
    justify-content: space-between;
    gap: 1rem;
    padding: clamp(1rem, 2vw, 1.5rem);
}

.press-card-copy h2,
.press-details ul {
    margin: 0;
}

.press-actions {
    gap: .6rem;
}

.press-heading .press-actions a:is([download], [href^="https://youtu.be/"], [href^="https://store.steampowered.com/"])::before {
    content: "";
    flex: 0 0 1rem;
    height: 1rem;
    margin-inline-end: .5rem;
    background: currentColor;
    mask: var(--press-action-icon, url("media/download.svg")) center / contain no-repeat;
}

.press-heading .press-actions a[href^="https://youtu.be/"] {
    --press-action-icon: url("media/archive-youtube.svg");
}

.press-heading .press-actions a[href^="https://store.steampowered.com/"] {
    --press-action-icon: url("media/steam.svg");
}

.press-section {
    margin-top: clamp(2rem, 5vw, 4rem);
    padding-top: clamp(1.25rem, 3vw, 2rem);
    border-top: 1px solid #ffffff24;
}

.press-section h2 {
    margin: 0 0 .85rem;
    font-size: clamp(1.35rem, 2.4vw, 1.85rem);
    line-height: 1.2;
}

.press-facts {
    display: grid;
    grid-template-columns: max-content minmax(0, 1fr);
    gap: .5rem 1.15rem;
    margin: 0;
}

.press-facts dt {
    font-weight: 650;
}

.press-facts dd,
.press-details ul {
    color: var(--muted-text);
}

.press-facts dd {
    margin: 0;
}

.press-history p {
    margin: 0 0 .8rem;
    color: var(--muted-text);
}

.press-archive dd {
    display: grid;
    justify-items: start;
    gap: .35rem;
}

.press-archive a {
    display: grid;
    grid-template-columns: 1rem minmax(0, 1fr);
    gap: .5rem;
}

.press-archive a::before {
    content: "";
    width: 1rem;
    height: 1rem;
    margin-block-start: .25rem;
    background: currentColor;
    mask: var(--archive-icon, url("media/archive-link.svg")) center / contain no-repeat;
}

.press-archive a[href^="https://youtu.be/"],
.press-archive a[href^="https://www.youtube.com/"] {
    --archive-icon: url("media/archive-youtube.svg");
}

.press-archive a[href^="https://drive.google.com/"] {
    --archive-icon: url("media/archive-drive.svg");
}

.press-archive small {
    padding-inline-start: 1.5rem;
    font-size: .875rem;
    font-style: italic;
}

.press-details li + li {
    margin-top: .4rem;
}

.press-gallery {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

.press-gallery a:hover {
    border-color: var(--accent);
}

.site-footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: .3rem 1rem;
    min-height: var(--footer-height);
    padding: .65rem var(--gutter);
    border-top: 1px solid #ffffff1a;
    background: var(--background);
    color: var(--muted-text);
    font-size: .875rem;
    text-align: center;
}

@media (prefers-reduced-motion: no-preference) {
    .game-actions--floating {
        transition: transform 240ms ease-in-out;
    }

    .site-nav a,
    .steam-link,
    .press-primary,
    .game-secondary,
    .game-link-action {
        transition: background-color 160ms, color 160ms, border-color 160ms;
    }

    .game-link .background-video,
    .game-link .game-logo {
        transition: transform 360ms ease-out;
    }

    .game-link:focus-visible .background-video {
        transform: scale(1.04);
    }

    .game-link:focus-visible .game-logo {
        transform: scale(1.08);
    }
}

@media (prefers-reduced-motion: no-preference) and (hover: hover) {
    .game-link:hover .background-video {
        transform: scale(1.04);
    }

    .game-link:hover .game-logo {
        transform: scale(1.08);
    }
}

@media (orientation: portrait) {
    .home-stage {
        min-height: max(32rem, calc(100svh - var(--header-height) - var(--footer-height)));
    }

    .home-stage::after {
        clip-path: polygon(0 52.88%, 100% 46.88%, 100% 47.12%, 0 53.12%);
    }

    .game-link {
        inset-inline: 0;
        width: 100%;
        height: 53%;
        padding-inline: 0;
    }

    .game-link--hostile {
        inset-block: 0 auto;
        clip-path: polygon(0 0, 100% 0, 100% 88.679%, 0 100%);
    }

    .game-link--minimal {
        inset-block: auto 0;
        clip-path: polygon(0 11.321%, 100% 0, 100% 100%, 0 100%);
    }

    .game-link-content {
        translate: 0 -5%;
        width: min(80%, 25rem);
    }

    .game-link--minimal .game-link-content {
        translate: 0 5%;
    }
}

@media (max-width: 46rem) {
    :root {
        --header-height: 3rem;
        --gutter: 1rem;
    }

    .site-header {
        padding-inline: .65rem;
    }

    .studio-link img {
        width: 2.25rem;
        height: 2.25rem;
    }

    .site-nav a {
        padding-inline: clamp(.4375rem, 2.5cqw, .65rem);
        font-size: .875rem;
    }

    .nav-game-logo {
        width: clamp(3.5rem, 16cqw, 4.75rem);
    }

    .nav-game-logo--hostile {
        width: clamp(4.75rem, 21cqw, 6.25rem);
    }

    .game-hero {
        min-height: clamp(27rem, 75svh, 40rem);
    }

    .feature,
    .feature:nth-child(even) {
        --scrim: linear-gradient(0deg, #081217f7, #081217e6 22%, #08121775 48%, #0812170d 69%);
        align-items: end;
        justify-items: start;
        min-height: clamp(27rem, 68svh, 38rem);
    }

    .feature-copy {
        width: min(88%, 30rem);
        padding: 1.65rem var(--gutter) 2.25rem;
    }

    .contact iframe {
        height: 45rem;
    }

    .press-games,
    .press-details {
        grid-template-columns: 1fr;
    }

    .press-gallery {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 32rem) {
    .game-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .game-actions .steam-link {
        grid-column: 1 / -1;
    }

    .game-actions--floating {
        grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr) minmax(0, .85fr);
        gap: .35rem;
    }

    .game-actions--floating .steam-link {
        grid-column: auto;
    }

    .game-actions--floating > * {
        padding-inline: .4rem;
    }

    .press-gallery {
        grid-template-columns: 1fr;
    }
}

@container (max-width: 30.25rem) {
    .studio-link span,
    .site-nav .home-link {
        display: none;
    }
}
