:root {
    color-scheme: dark;
    --background: #090d10;
    --surface: #10171c;
    --surface-light: #172229;
    --text: #eef3f5;
    --muted: #b4c0c6;
    --line: #30434c;
    --cyan: #13d5ff;
    --green: #87ad54;
    --content: 1100px;
    font-family: Arial, Helvetica, sans-serif;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: var(--background);
    color: var(--text);
    font-size: 17px;
    line-height: 1.6;
}

img {
    display: block;
    max-width: 100%;
}

a {
    color: var(--cyan);
}

a:hover,
a:focus-visible {
    color: #a9efff;
}

.skip-link {
    position: absolute;
    top: -5rem;
    left: 1rem;
    z-index: 100;
    padding: 0.7rem 1rem;
    background: #fff;
    color: #000;
}

.skip-link:focus {
    top: 1rem;
}

.site-header {
    border-bottom: 1px solid var(--line);
    background: #050708;
}

.header-inner,
.intro,
.game-loop,
.detail,
.multiplayer,
.setting,
.start,
.footer-inner {
    width: min(var(--content), calc(100% - 2rem));
    margin-inline: auto;
}

.header-inner {
    min-height: 112px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.brand {
    width: 230px;
    height: 104px;
    overflow: hidden;
}

.brand img {
    width: 230px;
    height: auto;
}

.site-header nav,
footer nav {
    display: flex;
    align-items: center;
    gap: 1.35rem;
}

.site-header nav a,
footer nav a {
    color: var(--text);
    font-size: 0.9rem;
    font-weight: 700;
    text-decoration: none;
}

.play-link {
    min-height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.65rem 1.2rem;
    border: 2px solid var(--cyan);
    background: transparent;
    color: var(--text);
    font-weight: 800;
    text-decoration: none;
}

.play-link:hover,
.play-link:focus-visible {
    background: var(--cyan);
    color: #001015;
}

h1,
h2 {
    line-height: 1.12;
    letter-spacing: -0.025em;
}

h1 {
    max-width: 900px;
    margin: 0;
    font-size: clamp(2.6rem, 5.2vw, 4.8rem);
}

h2 {
    margin: 0 0 1rem;
    font-size: clamp(1.8rem, 3.3vw, 2.8rem);
}

.intro {
    padding-block: clamp(3.5rem, 8vw, 6.5rem);
}

.intro-copy {
    max-width: 820px;
    margin: 1.4rem 0 0;
    color: var(--muted);
    font-size: 1.2rem;
}

.intro-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 1.2rem;
    margin-top: 1.8rem;
}

.map-shot,
.portrait-stage,
.event-shot {
    overflow: hidden;
    margin: 2.8rem 0 0;
    border: 1px solid var(--line);
    background: #030506;
}

.map-shot img,
.event-shot img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    object-position: center;
}

figcaption {
    padding: 0.8rem 1rem;
    border-top: 1px solid var(--line);
    background: var(--surface);
    color: var(--muted);
    font-size: 0.9rem;
}

figcaption strong {
    color: var(--text);
}

.game-loop,
.detail,
.multiplayer,
.setting,
.start {
    padding-block: clamp(3rem, 7vw, 5.5rem);
    border-top: 1px solid var(--line);
}

.game-loop ol {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1.5rem;
    margin: 2rem 0 0;
    padding: 0;
    list-style: none;
    counter-reset: loop;
}

.game-loop li {
    padding-top: 1rem;
    border-top: 3px solid var(--cyan);
    color: var(--muted);
    counter-increment: loop;
}

.game-loop li::before {
    content: "0" counter(loop);
    display: block;
    margin-bottom: 0.4rem;
    color: var(--cyan);
    font-weight: 800;
}

.game-loop li strong {
    color: var(--text);
}

.detail {
    display: grid;
    grid-template-columns: minmax(280px, 0.72fr) minmax(0, 1.28fr);
    align-items: center;
    gap: clamp(2rem, 6vw, 5rem);
}

.detail-copy p,
.multiplayer p,
.setting p,
.start p {
    color: var(--muted);
}

.portrait-stage,
.event-shot {
    margin: 0;
}

.portrait-stage {
    aspect-ratio: 16 / 9;
    display: grid;
    grid-template-rows: minmax(0, 1fr) auto;
    place-items: center;
    background:
        linear-gradient(rgba(3, 8, 12, 0.62), rgba(3, 8, 12, 0.76)),
        url("/bfe/images/world-map-first-look.png") center / cover no-repeat;
}

.portrait-stage img {
    width: 31.640625%;
    height: 100%;
    max-width: none;
    object-fit: contain;
    box-shadow: 0 0 32px #000;
}

.portrait-stage figcaption {
    width: 100%;
}

.event-shot img {
    display: block;
}

.multiplayer {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: clamp(2rem, 7vw, 6rem);
}

.multiplayer ul {
    margin: 0;
    padding-left: 1.2rem;
}

.multiplayer li + li {
    margin-top: 0.55rem;
}

.setting {
    max-width: 760px;
}

.start {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.start h2 {
    margin-bottom: 0.35rem;
}

.start p {
    margin: 0;
}

footer {
    padding-block: 2.5rem;
    border-top: 1px solid var(--line);
    background: #050708;
}

.footer-inner {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 2rem;
}

footer p {
    max-width: 420px;
    margin: 0.4rem 0 0;
    color: var(--muted);
    font-size: 0.88rem;
}

footer nav {
    flex-wrap: wrap;
    justify-content: flex-end;
}

@media (max-width: 820px) {
    .header-inner {
        align-items: flex-start;
        flex-direction: column;
        gap: 0.5rem;
        padding-block: 0.8rem;
    }

    .site-header nav {
        width: 100%;
        flex-wrap: wrap;
    }

    .site-header nav .play-link {
        width: 100%;
    }

    .game-loop ol {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .detail,
    .multiplayer {
        grid-template-columns: 1fr;
    }

    .detail-copy {
        max-width: 720px;
    }

    .footer-inner {
        flex-direction: column;
    }

    footer nav {
        justify-content: flex-start;
    }
}

@media (max-width: 520px) {
    body {
        font-size: 16px;
    }

    .brand {
        width: 190px;
        height: 86px;
    }

    .brand img {
        width: 190px;
    }

    .site-header nav {
        gap: 0.8rem 1rem;
    }

    .intro-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .game-loop ol {
        grid-template-columns: 1fr;
    }

    .portrait-stage,
    .event-shot {
        aspect-ratio: 4 / 5;
    }

    .portrait-stage img {
        width: 70.3125%;
    }

    .event-shot img {
        width: 100%;
        height: 100%;
        aspect-ratio: auto;
        object-fit: cover;
        object-position: center;
    }

    .start {
        align-items: flex-start;
        flex-direction: column;
    }

    .start .play-link {
        width: 100%;
    }
}
