/* PRODUCT-162: composition consumes Mobile V1 tokens and shared card slots. */
.reference-page {
    min-width: 0;
}

.dashboard-performance {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--space-5);
}

.dashboard-ranking-list,
.dashboard-home .dashboard-ledger-list {
    display: grid;
    gap: 0;
    margin: 0;
    padding: var(--space-2) var(--space-3);
    border: var(--border-subtle);
    border-radius: var(--radius-surface);
    background: rgb(var(--theme-surface-ink-rgb, 5 6 18) / 86%);
    box-shadow: var(--shadow-surface);
    list-style: none;
}

.dashboard-ranking-row {
    display: grid;
    grid-template-columns: 24px 32px minmax(0, 1fr) auto;
    align-items: center;
    gap: var(--space-2);
    min-height: 64px;
    padding: var(--space-2) 0;
    border-bottom: var(--border-subtle);
    font: 500 0.85rem/1.4 var(--font-body);
}

.dashboard-ranking-row:last-child {
    border-bottom: 0;
}

.dashboard-ranking-row__rank {
    color: var(--color-primary);
    font-weight: 800;
}

.dashboard-ranking-row__identity {
    overflow-wrap: anywhere;
}

.dashboard-ranking-row img {
    object-fit: contain;
}

.dashboard-ranking-row strong {
    text-align: right;
    white-space: nowrap;
}

.dashboard-ranking-row small {
    display: block;
    font: 500 0.62rem/1.4 var(--font-body);
    color: var(--color-muted);
}

.dashboard-ranking-row.is-current {
    color: #df9cff;
    box-shadow: inset 0 0 0 1px var(--color-secondary);
    border-radius: var(--radius-control);
    padding-inline: var(--space-2);
}

.dashboard-home #dashboard-game>.match-market-card {
    width: var(--market-card-width, 100%);
    max-width: 100%;
}

.dashboard-home .dashboard-stats--strip {
    grid-template-columns: repeat(auto-fit, minmax(0, 1fr));
}

.dashboard-home .dashboard-stats--strip article {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-content: center;
    gap: var(--space-1) var(--space-2);
}

.dashboard-home .dashboard-stats--strip .dashboard-stat__label {
    grid-column: 1 / -1;
}

.dashboard-home .dashboard-stats--strip strong {
    min-width: 0;
    overflow-wrap: anywhere;
}

@media (max-width: 960px) {
    body.arcade-page .reference-page {
        display: grid;
        gap: var(--mobile-section-gap);
    }

    body.arcade-page .reference-page>.app-page-hero {
        min-height: 0;
        margin: 0;
        padding-block: var(--space-3) var(--space-1);
        justify-items: start;
        text-align: left;
    }

    body.arcade-page .reference-page .app-page-hero h1 {
        font-size: clamp(2.5rem, 10.8vw, 4.2rem);
        line-height: 1.1;
        text-shadow: 0 0 16px rgb(var(--theme-accent-decor-rgb, 168 95 247) / 70%);
    }

    body.arcade-page .reference-page .app-page-hero .dashboard-purpose {
        font: 700 1rem/1.35 var(--font-body);
        color: var(--color-secondary);
    }
:is(body.arcade-page .reference-page .app-page-hero .dashboard-purpose):where(p) { font-size: calc(1rem + 3px); }

    body.arcade-page .reference-page .app-page-hero .lede {
        font-size: 0.82rem;
    }
:is(body.arcade-page .reference-page .app-page-hero .lede):where(p) { font-size: calc(0.82rem + 3px); }

    .reference-page .navigation-section {
        margin: 0;
        min-width: 0;
    }

    .reference-page .markets-section-header {
        border: 0;
        margin-bottom: var(--space-2);
        gap: var(--space-2);
    }

    body.arcade-page .reference-page .markets-section-header h2 {
        font: 800 clamp(0.95rem, 4.3vw, 1.2rem)/1.3 var(--font-body);
        text-transform: uppercase;
        letter-spacing: 0;
        overflow-wrap: anywhere;
    }

    .reference-page .markets-section-header__icon {
        font: 700 1.4rem/1 var(--font-body);
        color: var(--color-primary);
    }

    .reference-page .markets-section-header__action {
        font: 500 0.75rem/1.3 var(--font-body);
        color: #edccff;
    }

    .reference-page .markets-section-header__action::after {
        content: '›';
        margin-left: var(--space-2);
        font-size: 1.3rem;
    }

    .dashboard-home .dashboard-stats--strip {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(0, 1fr));
        gap: 0;
        margin: 0;
        padding: var(--space-3) var(--space-1);
        border: var(--border-structural);
        border-radius: var(--radius-surface);
        background: rgb(var(--theme-surface-ink-rgb, 5 6 18) / 87%);
        box-shadow: var(--shadow-selected);
    }

    .arcade-page .dashboard-home .dashboard-stats--strip article {
        padding: var(--space-1) var(--space-2);
        border: 0;
        border-right: var(--border-subtle);
        background: transparent;
        box-shadow: none;
        gap: var(--space-1);
        text-align: center;
    }

    .arcade-page .dashboard-home .dashboard-stats--strip article:last-child {
        border: 0;
    }

    .dashboard-home .dashboard-stats--strip .dashboard-stat__icon {
        width: auto;
        height: auto;
        font: 700 1.1rem/1 var(--font-body);
        color: var(--color-primary);
    }

    .arcade-page .dashboard-home .dashboard-stats--strip strong {
        font: 800 clamp(0.88rem, 4vw, 1.2rem)/1.2 var(--font-body);
    }

    .dashboard-home .dashboard-stats--strip .dashboard-stat__label {
        font: 500 0.62rem/1.35 var(--font-body);
        text-transform: none;
    }

    .reference-page .markets-rail {
        gap: var(--mobile-card-gap);
        padding-block: var(--space-1) var(--space-3);
        scroll-snap-type: x proximity;
    }

    :is(.reference-page, .guest-home-page) .markets-rail> :is(.featured-market-card, .generic-market-mini-card),
    .dashboard-home .dashboard-season-rail .featured-market-card {
        flex: 0 0 78%;
        min-width: 0;
        max-width: 340px;
        border: var(--border-structural);
        border-radius: var(--radius-surface);
        box-shadow: var(--shadow-surface);
    }

    :is(.reference-page, .guest-home-page) .markets-rail> :is(.featured-market-card, .generic-market-mini-card):only-child {
        flex-basis: 100%;
        max-width: none;
    }

    .reference-page .markets-rail>.featured-market-card.is-priority {
        border: var(--border-reward);
        box-shadow: var(--shadow-reward);
    }

    :is(.reference-page, .guest-home-page) :is(.featured-market-card, .generic-market-mini-card) {
        min-height: 255px;
        background: rgb(var(--theme-surface-ink-rgb, 5 6 18) / 92%);
    }

    :is(.reference-page, .guest-home-page) :is(.featured-market-card__background, .generic-market-mini-card__background) {
        opacity: 0.75;
    }

    :is(.reference-page, .guest-home-page) :is(.featured-market-card__content, .generic-market-mini-card__content) {
        display: flex;
        flex-direction: column;
        gap: var(--space-2);
        padding: var(--space-4);
        min-width: 0;
        background: linear-gradient(90deg, rgb(var(--theme-surface-ink-rgb, 5 6 18) / 82%), rgb(var(--theme-surface-ink-rgb, 5 6 18) / 28%));
    }

    :is(.reference-page, .guest-home-page) :is(.featured-market-card, .generic-market-mini-card) h3 {
        max-width: 100%;
        margin: 0;
        font: 850 1.05rem/1.2 var(--font-body);
        text-wrap: balance;
        overflow-wrap: anywhere;
    }

    :is(.reference-page, .guest-home-page) :is(.featured-market-card__subtitle, .generic-market-mini-card__subtitle) {
        display: none;
    }

    :is(.reference-page, .guest-home-page) :is(.featured-market-card__reward, .generic-market-mini-card__reward) {
        margin: var(--space-2) 0 0;
    }

    :is(.reference-page, .guest-home-page) :is(.featured-market-card__reward-copy, .generic-market-mini-card__reward-copy) strong {
        font: 800 1.25rem/1.2 var(--font-body);
    }

    :is(.reference-page, .guest-home-page) :is(.featured-market-card__reward-copy, .generic-market-mini-card__reward-copy) small {
        font: 500 0.64rem/1.4 var(--font-body);
    }

    .reference-page .status-pill {
        font: 500 0.7rem/1.3 var(--font-body);
        padding: 4px 9px;
    }

    .reference-page .markets-deadline {
        font: 500 0.68rem/1.4 var(--font-body);
        margin-block: auto var(--space-1);
    }
:is(.reference-page .markets-deadline):where(p) { font-size: calc(0.68rem + 3px); }

    :is(.reference-page, .guest-home-page) :is(.featured-market-card .market-action, .generic-market-mini-card__primary) {
        min-height: var(--tap-target);
        font: 800 0.86rem/1.25 var(--font-body);
        border: var(--card-cta-outline, var(--border-structural));
        border-radius: var(--radius-control);
        background: var(--card-cta-background, rgb(var(--theme-surface-ink-rgb, 5 6 18) / 88%));
        color: var(--card-cta-color, var(--color-text));
        padding: var(--space-2);
    }

    .reference-page .featured-market-card.is-priority .market-action {
        background: linear-gradient(#ffe681, #f0b220);
        border-color: var(--color-primary);
        color: #171008;
        box-shadow: var(--shadow-reward);
    }

    :is(.reference-page, .guest-home-page) .generic-market-mini-card__primary--disabled {
        color: var(--color-muted);
        opacity: 0.7;
    }

    .reference-page .markets-filters {
        margin: 0;
        gap: var(--space-2);
    }

    .reference-page .markets-filters a {
        min-height: var(--tap-target);
        border-radius: var(--radius-control);
        border: var(--border-subtle);
        font: 700 0.8rem/1.3 var(--font-body);
    }

    .reference-page .markets-filters a.is-active {
        border-color: var(--color-secondary);
        box-shadow: var(--shadow-selected);
    }

    .dashboard-performance {
        grid-template-columns: minmax(0, 1fr);
        gap: var(--mobile-section-gap);
    }

    .dashboard-home .dashboard-ledger-row {
        grid-template-columns: 28px minmax(0, 1fr) auto;
        padding: var(--space-3) 0;
        border: 0;
        border-bottom: var(--border-subtle);
        border-radius: 0;
        background: transparent;
        box-shadow: none;
    }

    .dashboard-home .dashboard-ledger-row:last-child {
        border-bottom: 0;
    }

    .dashboard-home .dashboard-ledger-row__amount strong {
        font: 800 1.05rem/1.3 var(--font-body);
    }

    .dashboard-home .dashboard-ledger-row__icon {
        width: 26px;
        height: 26px;
    }

    .dashboard-home .dashboard-ledger-row__amount {
        min-width: 0;
    }

    .reference-page .empty-state {
        padding: var(--space-4);
        border: var(--border-subtle);
        border-radius: var(--radius-surface);
        font: 500 0.85rem/1.5 var(--font-body);
        background: rgb(var(--theme-surface-ink-rgb, 5 6 18) / 80%);
    }
:is(.reference-page .empty-state):where(p) { font-size: calc(0.85rem + 3px); }
}

@media (min-width: 640px) and (max-width: 960px) {
    .dashboard-performance {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    :is(.reference-page, .guest-home-page) .markets-rail> :is(.featured-market-card, .generic-market-mini-card),
    .dashboard-home .dashboard-season-rail .featured-market-card {
        flex-basis: 42%;
    }
}

.reference-page :is(.match-market-card__pick, .match-market-card__primary, .match-market-card__secondary) {
    min-height: var(--tap-target);
}

@media (max-width: 960px) {
    body.arcade-page .markets-page>.app-page-hero {
        justify-items: center;
        text-align: center;
    }

    .reference-page #catalog-featured .featured-market-card:first-child:has(.market-action) {
        border: var(--border-reward);
        box-shadow: var(--shadow-reward);
    }

    .reference-page #catalog-featured .featured-market-card .market-action {
        background: linear-gradient(#ffe681, #f0b220);
        color: #171008;
        border-color: var(--color-primary);
    }
}

.reference-page .markets-load-more {
    min-height: var(--tap-target);
}

/* Override the legacy blanket arcade font on dense UI text, not on other pages. */
body.arcade-page .reference-page :is(p, span, strong, small, a, button, time) {
    font-family: var(--font-body);
}

body.arcade-page .reference-page .dashboard-hero .lede {
    display: block;
}

@media (max-width: 960px) {
    body.arcade-page :is(.reference-page, .guest-home-page) :is(.featured-market-card, .generic-market-mini-card) {
        padding: 0;
    }

    body.arcade-page :is(.reference-page, .guest-home-page) :is(.featured-market-card__content, .generic-market-mini-card__content) {
        width: 100%;
        min-height: 255px;
    }

    body.arcade-page :is(.reference-page, .guest-home-page) :is(.featured-market-card, .generic-market-mini-card) h3 {
        font-size: 1.05rem;
        line-height: 1.2;
        white-space: normal;
        text-shadow: none;
    }

    body.arcade-page .reference-page .featured-market-card .market-action {
        width: 100%;
    }

    body.arcade-page .reference-page .markets-deadline span {
        min-width: 0;
    }

    body.arcade-page .reference-page .markets-section-header {
        margin-block: 0;
    }
}

:is(.reference-page, .guest-home-page) :is(.market-action, .generic-market-mini-card__primary) {
    min-height: var(--tap-target);
}

/* Honor progressive filtering and lazy controls despite legacy display rules. */
.reference-page [hidden],
.standings-page [hidden] {
    display: none !important;
}

/* Status metrics share identical rows; icons never determine the text position. */
.arcade-page .dashboard-home .dashboard-stats--strip article {
    grid-template-rows: 2rem auto;
    align-items: center;
    align-content: center;
}

.arcade-page .dashboard-home .dashboard-stats--strip strong {
    color: var(--color-text);
    text-shadow: none;
    white-space: nowrap;
    overflow-wrap: normal;
}

.dashboard-home .dashboard-stats--strip .dashboard-stat__label {
    white-space: nowrap;
    align-self: start;
}

@media (max-width: 960px) {
    .arcade-page .dashboard-home .dashboard-stats--strip article {
        padding-inline: clamp(3px, 1vw, 8px);
    }

    .dashboard-home .dashboard-stats--strip .dashboard-stat__label {
        font-size: clamp(0.5rem, 2.5vw, 0.62rem);
        letter-spacing: 0;
    }
}

/* Center each icon/copy group, with the label aligned beneath its value. */
.arcade-page .dashboard-home .dashboard-stats--strip article {
    grid-template-columns: max-content max-content;
    justify-content: center;
    text-align: left;
}

.arcade-page .dashboard-home .dashboard-stats--strip strong {
    justify-self: start;
}

.dashboard-home .dashboard-stats--strip .dashboard-stat__label {
    grid-column: 2;
}

.dashboard-home .dashboard-stats--strip [data-dashboard-metric="open"] .dashboard-stat__label {
    grid-column: 1 / -1;
}

@media (max-width: 960px) {
    .arcade-page .dashboard-home .dashboard-stats--strip article {
        column-gap: clamp(2px, 0.7vw, 6px);
    }

    .dashboard-home .dashboard-stats--strip .dashboard-stat__label {
        font-size: clamp(0.46rem, 2.3vw, 0.62rem);
    }

    .dashboard-home .dashboard-stats--strip .dashboard-stat__icon {
        font-size: clamp(0.65rem, 3.5vw, 1.1rem);
    }
}

/* Home Game size trial: keep these two controls together for visual tuning. */
.dashboard-home #dashboard-game {
    --home-game-logo-size: 72px;
    --home-game-vs-size: 1.25rem;
}

.dashboard-home #dashboard-game :is(.match-market-card__team, .match-market-card__selected-team) img {
    width: var(--home-game-logo-size);
    height: var(--home-game-logo-size);
    max-width: 100%;
    object-fit: contain;
}

.dashboard-home #dashboard-game .match-market-card__versus {
    font-size: var(--home-game-vs-size);
}

/* Give enlarged Home logos their own room above the team abbreviations. */
.dashboard-home #dashboard-game .match-market-card__content {
    grid-template-rows: 24px minmax(108px, auto) minmax(42px, auto) minmax(18px, auto);
}

.dashboard-home #dashboard-game :is(.match-market-card__team, .match-market-card__selected-team) {
    gap: 8px;
    align-content: start;
}

.dashboard-home #dashboard-game .match-market-card__time {
    color: var(--color-text);
    font-size: 0.8rem;
}

.dashboard-home #dashboard-game .match-market-card__status-zone:has(.match-market-card__status-placeholder) {
    display: none;
}

.dashboard-home #dashboard-game .match-market-card__content:has(.match-market-card__status-placeholder) {
    grid-template-rows: 24px minmax(108px, auto) minmax(42px, auto) minmax(18px, auto);
}

/* Desktop: reuse the approved mobile arena on every page, including Profile. */
@media (min-width: 961px) {
    body.arcade-page {
        background: var(--color-bg-deep) url('/images/backgrounds/mobile/background-arena-main.webp') center / 100% 100% no-repeat fixed;
    }
}

/* Shared desktop page headers follow the approved mobile composition. */
@media (min-width: 961px) {
    body.arcade-page .app-page-hero {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
        justify-items: start;
        text-align: left;
        gap: var(--space-2);
        min-height: 0;
        padding: var(--space-3) 0;
        border: 0;
        background: transparent !important;
        box-shadow: none;
    }

    body.arcade-page .app-page-hero::before,
    body.arcade-page .app-page-hero::after,
    body.arcade-page .app-page-hero .app-page-hero__decoration {
        display: none;
    }

    body.arcade-page .app-page-hero>* {
        order: 0;
        grid-column: 1;
        margin: 0;
        text-align: left;
    }
}

@media (min-width: 961px) {
    body.arcade-page .app-page-hero :is(h1, .lede, .ds-text-muted, .heading-subtitle, .ds-kicker) {
        text-align: left;
    }
}

@media (max-width: 960px) {
    body.arcade-page .app-topbar .app-topbar__login {
        font-size: 0.45rem;
        padding-inline: 6px;
        white-space: nowrap;
    }
}

/* One primary state action; public sharing remains a quiet text link. */
body.arcade-page .featured-market-card .featured-market-card__share-link {
    display: inline-flex;
    align-items: center;
    align-self: flex-start;
    min-height: var(--tap-target);
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
    color: var(--color-muted);
    font: 500 0.75rem/1.4 var(--font-body);
    text-transform: none;
    text-decoration: underline;
    text-underline-offset: 3px;
}

body.arcade-page .featured-market-card .featured-market-card__share-link:hover {
    color: var(--color-text);
}

body.arcade-page .featured-market-card .featured-market-card__share-link:focus-visible {
    outline: 2px solid var(--color-secondary);
    outline-offset: 3px;
}

/* Shared featured-card slots retain their geometry when optional data is absent. */
body.arcade-page .featured-market-card .featured-market-card__content {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: 40px 26px 56px 44px 32px 44px minmax(44px, auto);
    align-content: start;
    gap: 5px;
    width: 100%;
    min-width: 0;
}

body.arcade-page .featured-market-card .featured-market-card__content>* {
    min-width: 0;
    margin: 0;
}

body.arcade-page .featured-market-card .featured-market-card__content h3 {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    max-width: 100%;
    font: 800 1.05rem/20px var(--font-body);
    white-space: normal;
    overflow-wrap: anywhere;
    text-wrap: pretty;
}

body.arcade-page .featured-market-card .featured-market-card__meta-row {
    flex-wrap: nowrap;
    align-items: center;
}

body.arcade-page .featured-market-card .status-pill {
    min-height: 26px;
    padding: 4px 11px;
    border: 1px solid var(--color-border-strong);
    border-radius: 999px;
    background: var(--color-panel-strong);
    color: #debaff;
    font: 600 0.75rem/1.2 var(--font-body);
    text-transform: none;
    box-shadow: none;
}

body.arcade-page .featured-market-card .featured-market-card__players {
    display: flex;
    flex-wrap: wrap;
    align-content: flex-start;
    align-items: flex-start;
    gap: 4px;
}

body.arcade-page .featured-market-card :is(.featured-market-card__player, .featured-market-card__player-more) {
    flex: 0 1 auto;
    width: max-content;
    max-width: calc((100% - 4px) / 2);
    height: 26px;
    min-height: 26px;
}

body.arcade-page .featured-market-card .featured-market-card__player {
    gap: 4px;
    padding: 2px 5px 2px 2px;
}

body.arcade-page .featured-market-card .featured-market-card__player-more {
    padding: 2px 5px;
}

body.arcade-page .featured-market-card :is(.featured-market-card__reward-slot, .featured-market-card__date-slot) {
    display: flex;
    align-items: center;
}

body.arcade-page .featured-market-card :is(.featured-market-card__reward, .markets-deadline) {
    margin: 0;
}

body.arcade-page .featured-market-card .featured-market-card__reward small {
    white-space: normal;
}

body.arcade-page .featured-market-card :is(.featured-market-card__share-slot, .featured-market-card__action-slot) {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    text-align: center;
}

body.arcade-page .featured-market-card .featured-market-card__share-link {
    justify-content: center;
    align-self: center;
    text-align: center;
}

body.arcade-page .featured-market-card .market-action {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    min-height: 44px;
    margin: 0;
    text-align: center;
}

body.arcade-page .featured-market-card :is(.featured-market-card__player img, .featured-market-card__player > span) {
    width: 20px;
    height: 20px;
}

/* Reward information is shared by every playable market-card variant. */
.market-card-reward {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 3px 5px;
    margin: 0;
    color: var(--color-text);
    font-size: 0.65rem;
    line-height: 1.3;
}
:is(.market-card-reward):where(p) { font-size: calc(0.65rem + 3px); }

.market-card-reward strong {
    color: var(--color-gold, #ffd45a);
}

.market-card-reward .mvp-coin-icon {
    width: 18px;
    height: 18px;
}

.match-market-card__content:has(.market-card-reward) {
    grid-template-rows: 18px 62px minmax(22px, auto) 42px 18px;
}

.match-market-card__status-zone:has(.market-card-reward) {
    gap: 4px;
}

/* PRODUCT-163: cool periwinkle edges with a fine reflective rim. */
body.arcade-page .reference-page .navigation-market-card {
    --card-edge-color: var(--card-edge-neutral, #76b8eb);
    border-color: var(--card-edge-color);
    box-shadow: var(--card-edge-shadow, 0 0 12px rgb(150 155 216 / 18%), inset 0 0 0 1px rgb(212 225 249 / 12%));
}

body.arcade-page .reference-page .navigation-market-card:is(.market-mini-card--state-saved, .match-market-card--state-saved) {
    --card-edge-color: var(--card-edge-neutral, #76b8eb);
}

body.arcade-page .reference-page .featured-market-card.is-priority,
body.arcade-page .reference-page #catalog-featured .featured-market-card:first-child:has(.market-action) {
    --card-edge-color: var(--card-edge-priority, #eac674);
    border-color: var(--card-edge-color);
    box-shadow: var(--card-edge-shadow, 0 0 12px rgb(234 198 116 / 20%), inset 0 0 0 1px rgb(255 237 182 / 18%));
}

body.arcade-page .reference-page .navigation-market-card::after,
html body.arcade-page .awards-landing .market-card::after,
html body.arcade-page .option-pick:is([data-market-type="award_winner"], [data-market-type="stat_leader"], [data-market-type="champion"]) .option-pick__candidate:not(.match-team-surface):not(:has(:checked))::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 2;
    padding: 1px;
    border-radius: inherit;
    background: linear-gradient(125deg,
            rgb(230 246 255 / 75%) 0%,
            rgb(204 216 255 / 35%) 14%,
            transparent 32% 60%,
            rgb(213 231 248 / 48%) 79%,
            transparent 96%);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
    pointer-events: none;
}

/* Compact illustrated Season cards: same rail width as Game cards. */
body.arcade-page :is(.reference-page, .guest-home-page) .markets-rail>.market-image-compact {
    flex: 0 0 var(--markets-rail-card);
    max-width: none;
    min-height: var(--compact-card-height, 198px);
    padding: 0;
}

body.arcade-page .market-image-compact .generic-market-mini-card__content {
    width: 72%;
    min-height: 194px;
    padding: 12px;
    gap: 5px;
    background: none;
}

body.arcade-page .market-image-compact.generic-market-mini-card--with-image .generic-market-mini-card__background {
    opacity: 1;
    background: linear-gradient(90deg, rgb(var(--theme-surface-ink-rgb, 5 6 18) / 94%) 0%, rgb(var(--theme-surface-ink-rgb, 5 6 18) / 78%) 43%, rgb(var(--theme-surface-ink-rgb, 5 6 18) / 8%) 100%),
        var(--generic-card-image) center / cover no-repeat;
}

body.arcade-page .market-image-compact h3 {
    font-size: .9rem;
}

body.arcade-page .market-image-compact .generic-market-mini-card__subtitle {
    display: none;
}

body.arcade-page .market-image-compact .generic-market-mini-card__reward {
    margin: 0;
}

body.arcade-page .market-image-compact .generic-market-mini-card__primary {
    min-height: 32px;
    padding: 6px;
    margin-top: auto;
    font-size: .65rem;
}

body.arcade-page .market-image-compact.generic-market-mini-card--no-image .generic-market-mini-card__content {
    width: 100%;
}

body.arcade-page .market-image-compact .generic-market-mini-card__players {
    flex-wrap: wrap;
    gap: 3px;
}
/* Only the two Match preview rails get an end-of-rail navigation card. */
.match-rail-view-all {
    min-height: var(--compact-card-height, 198px);
    display: grid;
    place-content: center;
    gap: 12px;
    padding: 20px;
    color: var(--color-text);
    text-align: center;
    text-decoration: none;
}
.match-rail-view-all > span { font-size: 2rem; color: var(--color-primary); }
.match-schedule-list { list-style: none; padding: 0; display: grid; gap: 10px; }
.match-schedule-list > li {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    padding: 16px;
    border: 1px solid var(--color-border-strong);
    border-radius: var(--radius-surface);
    background: var(--color-panel-strong);
}
.match-schedule-list > li strong { flex: 1 1 200px; }
.match-schedule-list a { padding: 10px; }

/* Default card edges are light blue; team palettes and selection stay independent. */
html body.arcade-page .navigation-market-card,
html body.arcade-page .market-card,
html body.arcade-page .option-pick__candidate:not(.match-team-surface):not(:has(:checked)) {
    --card-edge-color: var(--card-edge-neutral, #76b8eb);
    border-color: var(--card-edge-color);
}

/* Awards and champions share the featured gold halo and reflective rim. */
html body.arcade-page .navigation-market-card:is([data-market-type="award_winner"], [data-market-type="stat_leader"], [data-market-type="champion"], .featured-market-card--awards, .generic-market-mini-card--awards),
html body.arcade-page .awards-landing .market-card,
html body.arcade-page .option-pick:is([data-market-type="award_winner"], [data-market-type="stat_leader"], [data-market-type="champion"]) .option-pick__candidate:not(.match-team-surface):not(:has(:checked)) {
    --card-edge-color: var(--card-edge-priority, #eac674);
    position: relative;
    border-color: var(--card-edge-color) !important;
    box-shadow: var(--card-edge-shadow, 0 0 12px rgb(234 198 116 / 20%), inset 0 0 0 1px rgb(255 237 182 / 18%));
}

.match-schedule-page { --markets-rail-card: clamp(286px, 38vw, 460px); }
.match-schedule-day { margin-block: var(--space-5); min-width: 0; }
@media (max-width: 960px) {
    .match-schedule-page { --markets-rail-card: min(84vw, 420px); }
}

/* Not yet playable: muted artwork and a dark veil, without disabling detail links. */
html body.arcade-page :is(.navigation-market-card[data-market-state="upcoming"], .market-card[data-award-state="upcoming"]) {
    filter: saturate(0.2);
    box-shadow: inset 0 0 0 100vmax rgb(var(--theme-surface-ink-rgb, 5 6 18) / 18%);
}
html body.arcade-page .navigation-market-card[data-market-state="upcoming"] :is(.market-mini-card__background, .featured-market-card__background) {
    filter: grayscale(0.85) brightness(0.55);
}
html body.arcade-page .navigation-market-card[data-market-state="upcoming"] :is(.match-market-card__team img, .featured-market-card__art, .generic-market-mini-card__art) {
    filter: grayscale(0.85) brightness(0.7);
}

/* Owner-approved shared hero copy alignment on every viewport. */
html body.arcade-page .app-page-hero {
    text-align: left;
    justify-items: start;
}
html body.arcade-page .app-page-hero :is(h1, h2, p, .heading-subtitle, .heading-description, .ds-kicker, .lede) {
    text-align: left;
}

html body.arcade-page .app-page-hero :is(.heading-subtitle, .heading-description, .lede, .ds-text-muted, .ds-kicker, .dashboard-purpose) {
    text-align: left;
    justify-self: start;
    margin-inline: 0;
}

/* Reuse the Season team-title compact format in the dashboard rail. */
body.arcade-page .dashboard-season-rail > .market-image-compact {
    flex: 0 0 var(--markets-rail-card, clamp(286px, 38vw, 460px));
    max-width: none;
    min-height: var(--compact-card-height, 198px);
    padding: 0;
}
@media (max-width: 960px) {
    body.arcade-page .dashboard-season-rail > .market-image-compact {
        flex-basis: var(--markets-rail-card, min(84vw, 420px));
    }
}

/* Compact cards keep the Season reference height rather than stretching to peers. */
body.arcade-page .markets-rail > .market-image-compact {
    align-self: flex-start;
}
@media (max-width: 960px) {
    body.arcade-page .guest-home-page .market-image-compact .status-pill {
        font: 500 0.7rem/1.3 var(--font-body);
        padding: 4px 9px;
    }
    body.arcade-page .guest-home-page .market-image-compact .markets-deadline {
        font: 500 0.68rem/1.4 var(--font-body);
        margin-block: auto var(--space-1);
    }
:is(body.arcade-page .guest-home-page .market-image-compact .markets-deadline):where(p) { font-size: calc(0.68rem + 3px); }
}

/* All non-Match compact Market cards share the Season reference treatment. */
html body.arcade-page .market-image-compact {
    min-height: var(--compact-card-height, 198px);
    padding: 0;
    align-self: start;
}
@media (max-width: 960px) {
    html body.arcade-page .market-image-compact h3 {
        font: 850 .9rem/1.2 var(--font-body);
        text-shadow: none;
    }
    html body.arcade-page .market-image-compact .generic-market-mini-card__reward-copy strong {
        font: 800 1.25rem/1.2 var(--font-body);
    }
    html body.arcade-page .market-image-compact .generic-market-mini-card__reward-copy small {
        font: 500 .64rem/1.4 var(--font-body);
    }
    html body.arcade-page .market-image-compact .status-pill {
        font: 500 .7rem/1.3 var(--font-body);
        padding: 4px 9px;
    }
    html body.arcade-page .market-image-compact .markets-deadline {
        font: 500 .68rem/1.4 var(--font-body);
        margin-block: auto var(--space-1);
    }
:is(html body.arcade-page .market-image-compact .markets-deadline):where(p) { font-size: calc(.68rem + 3px); }
    html body.arcade-page .market-image-compact .generic-market-mini-card__primary {
        font: 800 .65rem/1.25 var(--font-body);
        border: var(--card-cta-outline, var(--border-structural));
        border-radius: var(--radius-control);
        background: var(--card-cta-background, rgb(var(--theme-surface-ink-rgb, 5 6 18) / 88%));
        color: var(--card-cta-color, var(--color-text));
    }
}

/* Candidate previews stay compact instead of adding one row per player. */
html body.arcade-page .market-image-compact .generic-market-mini-card__players {
    display: flex;
    flex-wrap: nowrap;
    gap: 4px;
    max-width: 100%;
    overflow-x: auto;
    scrollbar-width: thin;
}
html body.arcade-page .market-image-compact :is(.generic-market-mini-card__player, .generic-market-mini-card__player-more) {
    flex: 0 0 auto;
}

/* Shared rectangular non-Match card: only the title spans the artwork. */
html body.arcade-page .market-image-compact:not(.match-market-card):not(.featured-market-card) {
    height: var(--compact-card-height, 180px);
    min-height: var(--compact-card-height, 180px);
    max-height: var(--compact-card-height, 180px);
    padding: 0;
    box-sizing: border-box;
}
html body.arcade-page .market-image-compact:not(.match-market-card):not(.featured-market-card) .generic-market-mini-card__content {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: var(--compact-card-rows, 20px minmax(0, 1fr) 40px 20px 32px);
    width: 100%;
    height: var(--compact-content-height, 100%);
    min-height: 0;
    padding: var(--compact-card-padding, 12px 12px 6px);
    gap: var(--card-gap, 6px);
    box-sizing: border-box;
}
html body.arcade-page .market-image-compact:not(.match-market-card):not(.featured-market-card) h3 {
    grid-row: 1;
    display: block;
    width: 100%;
    margin: 0;
    font: var(--compact-card-title, 850 .65rem/20px var(--font-body));
    text-align: left;
    white-space: var(--compact-title-white-space, nowrap);
    overflow: hidden;
    text-overflow: ellipsis;
    text-wrap: var(--compact-title-wrap, nowrap);
}
html body.arcade-page .market-image-compact:not(.match-market-card):not(.featured-market-card) .generic-market-mini-card__content > :not(h3) {
    width: 72%;
    min-width: 0;
    max-width: 72%;
    box-sizing: border-box;
}
html body.arcade-page .market-image-compact:not(.match-market-card):not(.featured-market-card) .generic-market-mini-card__reward {
    grid-row: 3;
    align-self: end;
    margin: 0;
}
html body.arcade-page .market-image-compact:not(.match-market-card):not(.featured-market-card) .markets-deadline {
    grid-row: 4;
    align-self: center;
    margin: 0;
    padding-top: 0;
    font-size: .6rem;
}
:is(html body.arcade-page .market-image-compact:not(.match-market-card):not(.featured-market-card) .markets-deadline):where(p) { font-size: calc(.6rem + 3px); }
html body.arcade-page .market-image-compact:not(.match-market-card):not(.featured-market-card) .generic-market-mini-card__primary {
    grid-row: 5;
    height: var(--compact-action-size, 32px);
    min-height: var(--compact-action-size, 32px);
    margin: 0;
    padding: 4px;
    font-size: var(--compact-action-font-size, .6rem);
    line-height: 1.2;
}

html body.arcade-page .market-image-compact h3 a {
    font: inherit;
    letter-spacing: inherit;
    text-shadow: inherit;
}

html body.arcade-page .market-image-compact .generic-market-mini-card__share { position: absolute; right: 8px; bottom: 6px; z-index: 3; display: grid; place-items: center; width: var(--compact-action-size, 32px); height: var(--compact-action-size, 32px); border: 1px solid var(--color-border); border-radius: 8px; background: var(--color-bg-deep); color: var(--color-text); text-decoration: none; }

/* Dashboard uses the same card component and rail sizing as the catalogue. */
.dashboard-home .dashboard-season-rail {
    --markets-rail-card: clamp(286px, 38vw, 460px);
}
@media (max-width: 960px) {
    .dashboard-home .dashboard-season-rail {
        --markets-rail-card: min(84vw, 420px);
    }
}
