/*
 * AI Game Index — the sandbox's dark Playgama.ai look (Playgama/sandbox-games, WDS tokens),
 * pinned to dark as the sandbox pins it. Only the tokens this page uses are copied here; stay
 * within them rather than adding ad-hoc colours.
 */
:root {
    color-scheme: dark;

    --ground: #0d0d0f;
    --color-black: #000000;
    --color-white: #ffffff;
    --color-white-80: rgba(255, 255, 255, 0.8);
    --color-white-60: rgba(255, 255, 255, 0.6);
    --color-white-12: rgba(255, 255, 255, 0.12);
    --color-white-8: rgba(255, 255, 255, 0.08);
    --color-white-4: rgba(255, 255, 255, 0.04);
    --color-purple-400: rgb(151, 71, 255);
    --color-electric-lime: rgb(192, 255, 71);
    --color-carbon-400: rgb(41, 41, 46);
    --color-carbon-purple: rgb(29, 28, 38);

    --space-4: 4px;
    --space-6: 6px;
    --space-8: 8px;
    --space-12: 12px;
    --space-16: 16px;
    --space-20: 20px;
    --space-24: 24px;
    --space-32: 32px;
    --space-48: 48px;
    --space-80: 80px;

    --radius-6: 6px;
    --radius-12: 12px;
    --radius-16: 16px;
    --radius-24: 24px;
    --radius-rounded: 1000px;

    --header-height: 60px;
    --jump-height: 56px;

    /* Nine categorical hues for the carbon card (OKLCH L 0.48–0.67, at least 3:1 on it), three
       of them the vendors' own: Anthropic's clay, OpenAI's green, Google's blue. main.js pins
       each agent and model to one; the pins of each dimension were checked as neighbours under
       colour-vision deficiency (worst ΔE 8.5 by agent, 10.3 by model). Other is a dark neutral,
       below 3:1 on purpose so it steps back; its figures stay readable in the tables. */
    --series-clay: #d4714f;
    --series-green: #10a37f;
    --series-violet: #9a6be0;
    --series-gold: #b98a10;
    --series-blue: #4285f4;
    --series-rose: #d06a8c;
    --series-cyan: #2aa3c4;
    --series-orchid: #b65fc4;
    --series-crimson: #c8456e;
    --series-other: #4a4952;
}

* {
    box-sizing: border-box;
}

html {
    scrollbar-gutter: stable;
}

@media (prefers-reduced-motion: no-preference) {
    html {
        scroll-behavior: smooth;
    }
}

html,
body {
    background: var(--ground);
}

body {
    min-width: 320px;
    min-height: 100dvh;
    margin: 0;
    color: #f7f5fb;
    font-family:
        "DM Sans",
        system-ui,
        -apple-system,
        "Segoe UI",
        Roboto,
        Arial,
        sans-serif;
    font-size: 16px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

[hidden] {
    display: none !important;
}

a {
    color: inherit;
}

/* ------------------------------------------------------------------ header */

.header {
    position: sticky;
    top: 0;
    z-index: 10;
    background: var(--ground);
}

.header__content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: var(--header-height);
    padding: 10px var(--space-12);
}

/* Two links drawn as one logo: the Playgama pill goes to playgama.com, the AI box to the
   sandbox's games. */
.header__brand {
    display: flex;
    flex: none;
}

.header__logo {
    display: block;
    border-radius: var(--radius-6);
}

.header__logo:hover {
    filter: brightness(1.12);
}

.header__logo:focus-visible {
    outline: 2px solid var(--color-purple-400);
    outline-offset: 2px;
}

.header__playgama,
.header__ai {
    display: block;
    height: 40px;
}

.header__playgama {
    width: 137.27px;
}

.header__ai {
    width: 40.3px;
}

.header__actions {
    display: flex;
    flex: none;
    gap: 6px;
}

.pill {
    display: inline-flex;
    align-items: center;
    height: 40px;
    padding: 0 16px;
    border: 0;
    border-radius: var(--radius-rounded);
    font: inherit;
    font-size: 16px;
    font-weight: 510;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
    cursor: pointer;
}

.pill--dark {
    background: var(--color-carbon-400);
    color: var(--color-white);
}

.pill--lime {
    background: var(--color-electric-lime);
    color: var(--color-black);
}

.pill:hover {
    filter: brightness(1.12);
}

.pill:focus-visible {
    outline: 2px solid var(--color-purple-400);
    outline-offset: 2px;
}

/* -------------------------------------------------------------------- page */

.battle {
    display: flex;
    flex-direction: column;
    gap: var(--space-24);
    width: 100%;
    max-width: calc(1120px + 2 * var(--space-24));
    margin: 0 auto;
    padding: var(--space-24) var(--space-24) var(--space-80);
    color: var(--color-white);
}

.battle__head {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-12);
}

/* The title and, on its right, when the data was taken; under it on a narrow screen. */
.battle__top {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: var(--space-12) var(--space-24);
    width: 100%;
}

.battle__meta {
    display: grid;
    gap: var(--space-4);
    margin: 0;
    font-size: 15px;
    line-height: 1.3;
    text-align: right;
}

.battle__updated {
    color: var(--color-white-80);
}

.battle__period {
    color: var(--color-white-60);
}

/* The size of the lead above it: the two lines read as one statement. */
.battle__basis {
    margin: 0;
    color: var(--color-white-80);
    font-size: 22px;
    line-height: 1.35;
}

.battle__basis data {
    color: var(--color-electric-lime);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.battle__title {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0 0.25em;
    margin: 0;
    font-size: clamp(40px, 8vw, 64px);
    font-weight: 700;
    line-height: 1;
    letter-spacing: -0.02em;
}

.battle__title span {
    color: var(--color-electric-lime);
}

.battle__beta {
    align-self: flex-start;
    margin-top: 0.15em;
    padding: var(--space-4) var(--space-12);
    border: 1px solid var(--color-electric-lime);
    border-radius: var(--radius-rounded);
    color: var(--color-electric-lime);
    font-size: 16px;
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.battle__lead {
    max-width: 720px;
    margin: 0;
    color: var(--color-white);
    font-size: 22px;
    line-height: 1.35;
}

.battle__intro {
    max-width: 720px;
    margin: 0;
    color: var(--color-white-80);
    font-size: 17px;
    line-height: 1.55;
}

.battle__intro a,
.about a,
.stay a:not(.pill) {
    color: var(--color-electric-lime);
    text-underline-offset: 3px;
}

/* The anchors stay under the header while the page scrolls; the one being read is marked. */
.jump {
    position: sticky;
    top: var(--header-height);
    z-index: 9;
    display: flex;
    gap: var(--space-6);
    margin: 0 calc(-1 * var(--space-24));
    padding: var(--space-8) var(--space-24);
    overflow-x: auto;
    background: var(--ground);
    scrollbar-width: none;
}

.jump__link {
    display: inline-flex;
    flex: none;
    align-items: center;
    height: 40px;
    padding: 0 var(--space-16);
    border-radius: var(--radius-rounded);
    background: var(--color-white-8);
    color: var(--color-white);
    font-size: 15px;
    font-weight: 500;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
}

.jump__link:hover {
    background: var(--color-white-12);
}

.jump__link[aria-current] {
    background: #d2d2d2;
    color: var(--color-black);
}

.jump__link:focus-visible {
    outline: 2px solid var(--color-purple-400);
    outline-offset: 2px;
}

/* --------------------------------------------------------------- dimension */

.dimension,
.about,
.stay {
    scroll-margin-top: calc(var(--header-height) + var(--jump-height) + var(--space-16));
}

.dimension {
    display: flex;
    flex-direction: column;
    gap: var(--space-16);
    padding-top: var(--space-24);
}

.dimension__head {
    display: grid;
    gap: var(--space-8);
    max-width: 760px;
}

.dimension__title {
    margin: 0;
    color: var(--color-white);
    font-size: clamp(28px, 4vw, 36px);
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.01em;
}

.dimension__lead {
    margin: 0;
    color: var(--color-white-80);
    font-size: 17px;
    line-height: 1.55;
}

.dimension__body {
    display: flex;
    flex-direction: column;
    gap: var(--space-16);
}

.dimension ul,
.dimension ol {
    margin: 0;
    padding: 0;
    list-style: none;
}

.dimension__row {
    display: grid;
    grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr);
    gap: var(--space-16);
}

/* The two cards of a row share its height; their tables start on one line at the bottom. */
.dimension__row .card {
    display: flex;
    flex-direction: column;
}

.dimension__row .data {
    margin-top: auto;
}

.dimension__row .share,
.dimension__row .donut {
    margin-bottom: var(--space-20);
}

.dimension__empty,
.card__empty {
    margin: 0;
    color: var(--color-white-60);
    font-size: 16px;
}

.card {
    min-width: 0;
    padding: var(--space-24);
    border-radius: var(--radius-24);
    background: var(--color-carbon-purple);
}

.card__title {
    margin: 0 0 var(--space-8);
    color: var(--color-white);
    font-size: 22px;
    font-weight: 550;
    line-height: 1.2;
}

.card__hint {
    margin: 0 0 var(--space-20);
    color: var(--color-white-60);
    font-size: 15px;
    line-height: 1.45;
}

.card__note {
    margin: var(--space-16) 0 0;
    color: var(--color-white-60);
    font-size: 14px;
    line-height: 1.45;
}

.dot {
    display: block;
    flex: none;
    width: 12px;
    height: 12px;
    margin-right: var(--space-8);
    border-radius: 3px;
}

/* Pointing at one category fades the others in the share and all-time cards (main.js). */
[data-series] {
    transition: opacity 0.15s ease;
}

.is-faded {
    opacity: 0.22;
}

/* Named through the card so the margin outranks the list reset above. */
.card .legend {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-8) var(--space-20);
    margin-bottom: var(--space-20);
    color: var(--color-white-80);
    font-size: 15px;
    line-height: 1.3;
}

.legend__item {
    display: flex;
    align-items: center;
    cursor: default;
}

.share {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: var(--space-8);
    color: var(--color-white-60);
    font-size: 14px;
    line-height: 1;
}

/* Five labels spread over the plot's height, each centred on its own grid line. */
.share__shares {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    margin: -7px 0;
    font-variant-numeric: tabular-nums;
    text-align: right;
}

.share__plot {
    display: block;
    width: 100%;
    height: 340px;
}

.share__grid {
    stroke: var(--color-white-12);
    stroke-width: 1;
    vector-effect: non-scaling-stroke;
}

.share__band,
.donut__slice {
    stroke: var(--color-carbon-purple);
    stroke-width: 2;
    stroke-linejoin: round;
    vector-effect: non-scaling-stroke;
}

/* A day's strip is there to be pointed at; its guide shows while its tip does. */
.share__column {
    fill: transparent;
}

.share__guide {
    stroke: var(--color-white);
    stroke-width: 1;
    vector-effect: non-scaling-stroke;
    opacity: 0;
    pointer-events: none;
}

.share__mark.is-tipped .share__guide {
    opacity: 0.6;
}

/* The metrics tooltip of the developer cabinet: the same ground, title and rows. Placed by
   main.js beside the pointer; it inherits nothing from the chart it sits in. */
.tip {
    position: fixed;
    z-index: 20;
    min-width: 160px;
    max-width: min(340px, calc(100vw - 2 * var(--space-8)));
    padding: var(--space-12) var(--space-16);
    border-radius: var(--radius-12);
    background: color-mix(in srgb, var(--color-carbon-400) 92%, transparent);
    box-shadow: 0 4px 20px rgb(0 0 0 / 50%);
    backdrop-filter: blur(12px);
    color: var(--color-white);
    font-size: 15px;
    font-weight: 400;
    line-height: 1.35;
    text-align: left;
    overflow-wrap: anywhere;
    pointer-events: none;
}

.tip__title {
    margin: 0 0 var(--space-8);
    color: var(--color-white-60);
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.tip__rows {
    display: grid;
    gap: var(--space-6);
    margin: 0;
}

.tip__row {
    display: flex;
    justify-content: space-between;
    gap: var(--space-16);
}

.tip__row dt {
    display: flex;
    min-width: 0;
    align-items: center;
    color: var(--color-white-80);
}

.tip__row dd {
    margin: 0;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.tip__note {
    display: inline-block;
    min-width: 2.5em;
    margin-left: var(--space-8);
    color: var(--color-white-60);
    font-weight: 400;
    text-align: right;
}

.share__days {
    position: relative;
    grid-column: 2;
    height: 14px;
}

.share__day {
    position: absolute;
    transform: translateX(-50%);
    white-space: nowrap;
}

.share__day--first {
    transform: none;
}

.share__day--last {
    transform: translateX(-100%);
}

.donut {
    display: grid;
    justify-items: center;
    gap: var(--space-20);
}

.donut__chart {
    position: relative;
}

.donut__ring {
    display: block;
    width: 200px;
    height: 200px;
}

.shares {
    display: grid;
    gap: var(--space-8);
    width: 100%;
    font-size: 16px;
}

.shares__row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: var(--space-12);
    align-items: center;
}

.shares__name {
    display: flex;
    align-items: center;
    overflow: hidden;
    color: var(--color-white-80);
    text-overflow: ellipsis;
    white-space: nowrap;
}

.shares__share {
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

.spread {
    display: grid;
    grid-template-columns: 230px minmax(0, 1fr) 160px;
    gap: var(--space-16);
    align-items: center;
}

.spread__rows {
    display: grid;
    gap: var(--space-16);
}

.spread--axis {
    margin-bottom: var(--space-8);
    color: var(--color-white-60);
    font-size: 14px;
}

.spread__ticks {
    position: relative;
    height: 18px;
}

.spread__ticks span {
    position: absolute;
    transform: translateX(-50%);
    white-space: nowrap;
}

.spread__ticks span:first-child {
    transform: none;
}

.spread__ticks span:last-child {
    transform: translateX(-100%);
}

.spread__name {
    display: flex;
    align-items: center;
    min-width: 0;
    color: var(--color-white-80);
    font-size: 16px;
    line-height: 1.3;
}

.spread__track {
    position: relative;
    height: 24px;
}

.spread__track::before {
    position: absolute;
    top: 11px;
    right: 0;
    left: 0;
    height: 1px;
    background: var(--color-white-12);
    content: "";
}

.spread__whisker {
    position: absolute;
    top: 11px;
    height: 2px;
    border-radius: 2px;
}

.spread__box {
    position: absolute;
    top: 5px;
    height: 14px;
    border-radius: var(--radius-6);
}

.spread__median {
    position: absolute;
    top: 1px;
    width: 3px;
    height: 22px;
    margin-left: -1.5px;
    border-radius: 2px;
    background: var(--color-white);
    box-shadow: 0 0 0 2px var(--color-carbon-purple);
}

.spread__value {
    color: var(--color-white-60);
    font-size: 16px;
    font-variant-numeric: tabular-nums;
    text-align: right;
}

.spread__value b {
    margin-right: var(--space-6);
    color: var(--color-white);
    font-weight: 600;
}

.card .key {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-6) var(--space-20);
    margin-top: var(--space-16);
    color: var(--color-white-60);
    font-size: 14px;
}

.key li {
    display: flex;
    align-items: center;
}

.key i {
    display: block;
    flex: none;
    margin-right: var(--space-6);
    background: var(--color-white-60);
}

.key__whisker {
    width: 24px;
    height: 2px;
}

.key__box {
    width: 24px;
    height: 10px;
    border-radius: 5px;
}

.key i.key__median {
    width: 3px;
    height: 16px;
    border-radius: 2px;
    background: var(--color-white);
}

/* -------------------------------------------------------------- table data */

.data {
    margin-top: var(--space-20);
    border-top: 1px solid var(--color-white-12);
}

.data__toggle {
    display: flex;
    align-items: center;
    gap: var(--space-8);
    width: fit-content;
    padding: var(--space-12) 0 0;
    color: var(--color-white-80);
    font-size: 15px;
    font-weight: 500;
    list-style: none;
    cursor: pointer;
}

.data__toggle::-webkit-details-marker {
    display: none;
}

.data__toggle::before {
    width: 8px;
    height: 8px;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(-45deg);
    transition: transform 0.15s ease;
    content: "";
}

.data[open] > .data__toggle::before {
    transform: rotate(45deg);
}

.data__toggle:hover {
    color: var(--color-white);
}

.data__toggle:focus-visible {
    border-radius: var(--radius-6);
    outline: 2px solid var(--color-purple-400);
    outline-offset: 4px;
}

/* A wide table scrolls inside its card rather than the page. */
.data__scroll {
    margin-top: var(--space-12);
    overflow-x: auto;
}

.data__table {
    width: 100%;
    border-collapse: collapse;
    font-size: 15px;
    line-height: 1.3;
    font-variant-numeric: tabular-nums;
}

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

.data__table th,
.data__table td {
    padding: var(--space-8) var(--space-12);
    border-bottom: 1px solid var(--color-white-8);
    text-align: right;
    white-space: nowrap;
}

.data__table th:first-child {
    padding-left: 0;
    text-align: left;
}

/* A long name wraps in its head cell rather than widening the whole column. */
.data__table thead th {
    min-width: 64px;
    max-width: 128px;
    color: var(--color-white-60);
    font-weight: 500;
    vertical-align: bottom;
    white-space: normal;
}

.data__table thead th .dot {
    display: inline-block;
    margin-right: var(--space-6);
}

.data__table tbody th {
    color: var(--color-white-80);
    font-weight: 400;
}

.data__table tbody th .dot {
    display: inline-block;
    vertical-align: -1px;
}

.data__quiet,
.data__folded {
    color: var(--color-white-60);
}

.data__folded {
    display: block;
    max-width: 320px;
    margin-left: 20px;
    font-size: 13px;
    white-space: normal;
}

/* --------------------------------------------------------------- top games */

.tops {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr));
    gap: var(--space-12);
}

.top {
    padding: var(--space-16);
    border: 1px solid var(--color-white-12);
    border-radius: var(--radius-16);
}

.top__title {
    display: flex;
    align-items: flex-start;
    margin: 0 0 var(--space-12);
    font-size: 16px;
    font-weight: 600;
}

.top__title .dot {
    margin-top: 6px;
}

.top__games {
    display: grid;
    gap: var(--space-8);
}

/* A game is one tile and one link: its place, its cover, then its name over its figures. */
.top__link {
    display: grid;
    grid-template-columns: 12px 56px minmax(0, 1fr);
    gap: var(--space-12);
    align-items: center;
    padding: var(--space-8);
    border-radius: var(--radius-16);
    background: var(--color-white-4);
    color: var(--color-white);
    text-decoration: none;
}

.top__link:hover {
    background: var(--color-white-8);
}

.top__link:focus-visible {
    outline: 2px solid var(--color-purple-400);
    outline-offset: 2px;
}

.top__link b {
    color: var(--color-white-60);
    font-size: 14px;
    font-weight: 600;
    text-align: center;
}

.top__cover {
    display: block;
    width: 56px;
    height: 56px;
    border-radius: var(--radius-12);
    background: var(--color-white-8);
    object-fit: cover;
}

.top__copy {
    min-width: 0;
}

.top__name {
    display: block;
    overflow: hidden;
    font-weight: 600;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.top__stats,
.top__empty {
    display: block;
    margin: 0;
    color: var(--color-white-60);
    font-size: 13px;
    font-variant-numeric: tabular-nums;
    line-height: 1.4;
}

/* ------------------------------------- methodology, limitations, faq, next */

.about {
    display: grid;
    gap: var(--space-20);
    padding-top: var(--space-24);
}

.about__list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--space-16);
    margin: 0;
}

.about__item {
    padding: var(--space-20) var(--space-24);
    border-radius: var(--radius-24);
    background: var(--color-carbon-purple);
}

.about__item dt {
    margin-bottom: var(--space-8);
    color: var(--color-white);
    font-size: 18px;
    font-weight: 600;
}

.about__item dd {
    margin: 0;
    color: var(--color-white-80);
    font-size: 16px;
    line-height: 1.55;
}

/* Limitations and the FAQ are one card each, as wide as the methodology grid above them. */
.about__notes {
    display: grid;
    gap: var(--space-12);
    margin: 0;
    padding: var(--space-24) var(--space-32) var(--space-24) var(--space-48);
    border-radius: var(--radius-24);
    background: var(--color-carbon-purple);
    color: var(--color-white-80);
    font-size: 16px;
    line-height: 1.55;
}

.about__notes b {
    color: var(--color-white);
    font-weight: 600;
}

/* The FAQ is the accordion of /wrap in the dark: one card, a rule between questions, a plus
   that turns into a cross. Native <details>, so the answers are in the page for search and
   open without JS; the question stays a heading inside its <summary>. */
.faq {
    display: flex;
    flex-direction: column;
    padding: var(--space-8) var(--space-32);
    border-radius: var(--radius-24);
    background: var(--color-carbon-purple);
}

.faq__item {
    border-bottom: 1px solid var(--color-white-12);
}

.faq__item:last-child {
    border-bottom: 0;
}

.faq__summary {
    display: flex;
    align-items: flex-start;
    gap: var(--space-16);
    padding: var(--space-20) 0;
    list-style: none;
    cursor: pointer;
}

.faq__summary::-webkit-details-marker {
    display: none;
}

.faq__summary:focus-visible {
    border-radius: var(--radius-6);
    outline: 2px solid var(--color-purple-400);
    outline-offset: 4px;
}

.faq__question {
    flex: 1 0 0;
    min-width: 0;
    margin: 0;
    color: var(--color-white);
    font-size: 18px;
    font-weight: 600;
    line-height: 1.35;
}

.faq__toggle {
    position: relative;
    flex: none;
    width: 24px;
    height: 24px;
    transition: transform 0.2s ease;
}

.faq__toggle::before,
.faq__toggle::after {
    position: absolute;
    border-radius: 2px;
    background: var(--color-white-80);
    content: "";
}

.faq__toggle::before {
    top: 4px;
    left: 11px;
    width: 2px;
    height: 16px;
}

.faq__toggle::after {
    top: 11px;
    left: 4px;
    width: 16px;
    height: 2px;
}

.faq__item[open] .faq__toggle {
    transform: rotate(45deg);
}

.faq__answer {
    margin: 0;
    padding: 0 var(--space-48) var(--space-20) 0;
    color: var(--color-white-80);
    font-size: 16px;
    line-height: 1.55;
}

.stay {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: var(--space-16) var(--space-32);
    align-items: center;
    margin-top: var(--space-24);
    padding: var(--space-32);
    border: 1px solid color-mix(in srgb, var(--color-electric-lime) 40%, transparent);
    border-radius: var(--radius-24);
    background: var(--color-carbon-purple);
}

.stay__copy {
    display: grid;
    gap: var(--space-8);
}

.stay__title {
    margin: 0;
    color: var(--color-electric-lime);
    font-size: clamp(28px, 4vw, 36px);
    font-weight: 700;
    line-height: 1.15;
}

.stay__text,
.stay__cta {
    max-width: 620px;
    margin: 0;
    color: var(--color-white-80);
    font-size: 17px;
    line-height: 1.55;
}

.stay__links {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-8);
    margin: 0;
    padding: 0;
    list-style: none;
}

.stay__cta {
    grid-column: 1 / -1;
    max-width: none;
    padding-top: var(--space-16);
    border-top: 1px solid var(--color-white-12);
    color: var(--color-white-60);
}

/* ------------------------------------------------------------------ footer */

.footer {
    border-top: 1px solid var(--color-white-8);
}

.footer__content {
    display: grid;
    gap: var(--space-12);
    max-width: calc(1120px + 2 * var(--space-24));
    margin: 0 auto;
    padding: var(--space-32) var(--space-24) var(--space-48);
    color: var(--color-white-60);
    font-size: 14px;
    line-height: 1.5;
}

.footer__links {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-8) var(--space-24);
    font-size: 15px;
}

.footer__links a {
    color: var(--color-white-80);
    text-decoration: none;
}

.footer__links a:hover,
.footer__press a,
.footer__legal a {
    color: var(--color-white);
}

.footer__links a:focus-visible,
.footer__press a:focus-visible,
.footer__legal a:focus-visible {
    border-radius: var(--radius-6);
    outline: 2px solid var(--color-purple-400);
    outline-offset: 2px;
}

.footer__press,
.footer__legal {
    margin: 0;
}

@media (max-width: 860px) {
    .dimension__row,
    .about__list {
        grid-template-columns: minmax(0, 1fr);
    }

    /* A row is too narrow for name, spread and figure side by side: the name and the figure
       share the first line, the spread takes the second. */
    .spread {
        grid-template-columns: minmax(0, 1fr) auto;
        gap: var(--space-4) var(--space-12);
    }

    .spread__track,
    .spread__ticks {
        grid-row: 2;
        grid-column: 1 / -1;
    }

    .spread--axis span:empty {
        display: none;
    }

    .stay {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 520px) {
    :root {
        --jump-height: 48px;
    }

    .header__playgama,
    .header__ai {
        height: 32px;
    }

    .header__playgama {
        width: 109.82px;
    }

    .header__ai {
        width: 32.24px;
    }

    .pill {
        height: 32px;
        padding: 0 12px;
        font-size: 14px;
    }

    .battle {
        gap: var(--space-16);
        padding: var(--space-20) var(--space-16) var(--space-48);
    }

    .battle__lead,
    .battle__basis {
        font-size: 19px;
    }

    .battle__intro,
    .dimension__lead,
    .stay__text,
    .stay__cta {
        font-size: 16px;
    }

    .battle__beta {
        font-size: 13px;
    }

    .jump {
        margin: 0 calc(-1 * var(--space-16));
        padding: var(--space-8) var(--space-16);
    }

    .jump__link {
        height: 32px;
        padding: 0 var(--space-12);
        font-size: 14px;
    }

    .card,
    .about__item {
        padding: var(--space-16);
        border-radius: var(--radius-16);
    }

    .faq {
        padding: var(--space-4) var(--space-16);
        border-radius: var(--radius-16);
    }

    .about__notes {
        padding: var(--space-16) var(--space-16) var(--space-16) var(--space-32);
        border-radius: var(--radius-16);
    }

    .faq__question {
        font-size: 17px;
    }

    .faq__answer {
        padding-right: 0;
    }

    .battle__meta {
        text-align: left;
    }

    .footer__content {
        padding: var(--space-24) var(--space-16) var(--space-32);
    }

    .stay {
        padding: var(--space-20);
    }

    .share__plot {
        height: 220px;
    }

    /* A phone has room for the two ends of the period only. */
    .share__day:not(.share__day--first, .share__day--last) {
        display: none;
    }
}

/* Below 400px the logo and both links do not fit on one line; the sandbox link stays. Only the
   header's link: Retry and the follow links wear the same pill and must stay reachable. */
@media (max-width: 399px) {
    .header__actions .pill--dark {
        display: none;
    }
}
