@import url('https://fonts.googleapis.com/css2?family=Barlow+Condensed:wght@600;700;800&family=Barlow:wght@400;500;600;700;800&display=swap');


:root {
    color-scheme: light;

    --bg: #f6f3ec;
    --panel: #ffffff;
    --panel-light: #f0ece3;
    --line: #ddd6c9;
    --muted: #6f6a61;
    --white: #26221d;
    --orange: #e58a3a;
    --orange-dark: #fffaf4;
    --mint: #4fa995;
    --radius: 14px;

    --display: 'Barlow Condensed', 'Arial Narrow', Impact, sans-serif;
    --font: 'Barlow', Arial, sans-serif;
}


* {
    box-sizing: border-box;
}


html {
    scroll-behavior: smooth;
    scroll-padding-top: 24px;
}


body {
    margin: 0;
    background: var(--bg);
    color: var(--white);
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.5;
}


body:before {
    content: '';
    position: absolute;
    inset: 80px 0 auto;
    height: 880px;

    background:
        radial-gradient(
            ellipse at 49% 34%,
            #34556a40,
            transparent 53%
        ),
        linear-gradient(
            115deg,
            transparent 60%,
            #6b81a406 60%,
            #6b81a406 75%,
            transparent 75%
        );

    pointer-events: none;
    z-index: -1;
}


a {
    color: inherit;
    text-decoration: none;
}


button,
input,
select,
textarea {
    font: inherit;
}


button,
a,
input,
textarea,
select {
    -webkit-tap-highlight-color: transparent;

    transition:
        background .18s,
        color .18s,
        border-color .18s,
        transform .18s;
}


button {
    cursor: pointer;
}


button:disabled {
    cursor: not-allowed;
}


button:disabled:not(.selected) {
    opacity: .88;
}


a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 3px solid var(--orange);
    outline-offset: 5px;
}


a:hover {
    color: var(--orange);
}


h1,
h2,
h3,
p {
    margin: 0;
}


h1,
h2,
h3 {
    line-height: 1.15;
}


h2 {
    font-size: 23px;
    font-weight: 700;
}


p {
    color: var(--muted);
}


.icon {
    width: 21px;
    height: 21px;
    flex-shrink: 0;
    vertical-align: middle;
}


.wrap {
    max-width: 1392px;
    padding-inline: 48px;
    margin-inline: auto;
}


/* =========================
   HEADER
   ========================= */

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


.header-inner {
    max-width: 1510px;
    margin: auto;
    padding: 0 40px;
    min-height: 88px;

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 28px;
}


.brand {
    display: flex;
    align-items: center;
    gap: 11px;

    font-size: 25px;
    font-weight: 700;
    letter-spacing: -.8px;
    white-space: nowrap;
}


.brand-mark {
    display: grid;
    place-items: center;

    width: 38px;
    height: 38px;

    color: var(--orange);
}


.brand-mark .icon {
    width: 32px;
    height: 32px;
    stroke-width: 2;
}


.brand-number {
    color: var(--orange);
    font-weight: 800;
}


.brand small {
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0;
    color: var(--muted);
    margin-left: 3px;
}


.header nav {
    display: flex;
    align-self: stretch;
    gap: 26px;
}


.header nav a {
    display: flex;
    align-items: center;
    gap: 9px;

    position: relative;

    font-size: 15px;
    font-weight: 600;
    color: var(--muted);
    white-space: nowrap;
}


.header nav a:hover,
.header nav a[aria-current] {
    color: var(--white);
}


.header nav a[aria-current]:after {
    content: '';

    height: 3px;
    background: var(--orange);

    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
}


.header nav a[aria-current] .icon {
    color: var(--orange);
}


.auth-nav {
    display: flex;
    gap: 23px;
    align-items: center;

    font-size: 14px;
    font-weight: 600;
}


/* =========================
   BUTTONS
   ========================= */

.button {
    display: inline-flex;
    gap: 14px;
    align-items: center;
    justify-content: center;

    border: 1px solid transparent;
    padding: 13px 20px;
    border-radius: 7px;

    font-size: 15px;
    font-weight: 700;
    line-height: 1.5;

    color: var(--orange-dark);
    background: var(--orange);
    white-space: nowrap;
}


.button:hover {
    color: #211910;
    background: #ffc28b;
    transform: translateY(-1px);
}


.button.secondary {
    background: #2b3748;
    border-color: #3c495c;
    color: var(--white);
}


.button.secondary:hover {
    background: #35455b;
}


.button.compact {
    padding: 10px 16px;
    font-size: 14px;
}


.button.compact .icon {
    display: none;
}


.button.primary .icon {
    width: 18px;
}


/* =========================
   GENERAL LABELS
   ========================= */

.eyebrow,
.section-label {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1.7px;
    color: var(--muted);
}


/* =========================
   LOBBY
   ========================= */

.lobby {
    padding-top: 28px;
}


.lobby-top {
    display: flex;
    justify-content: space-between;
    align-items: center;

    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1.8px;

    margin-bottom: 26px;
}


.lobby-top .eyebrow {
    margin-right: 8px;
}


.preview-tag {
    font-size: 12px;
    letter-spacing: 1.3px;
    color: #a8b8ca;

    padding: 4px 8px;

    border: 1px solid #384559;
    border-radius: 4px;
}


.lobby-grid {
    display: grid;
    grid-template-columns:
        minmax(210px, 1fr)
        minmax(330px, 470px)
        minmax(235px, 1fr);

    gap: 38px;
    align-items: start;
}


.left-rail,
.right-rail {
    display: flex;
    flex-direction: column;
    gap: 20px;

    padding-top: 36px;
}


.panel {
    background:
        linear-gradient(
            135deg,
            #202b3a,
            #192330
        );

    border: 1px solid var(--line);
    border-radius: var(--radius);
}


/* =========================
   WELCOME PANEL
   ========================= */

.welcome {
    padding: 25px 23px 20px;
    text-align: center;
}


.guest-avatar {
    margin: 0 auto 26px;

    width: 68px;
    height: 68px;

    position: relative;

    display: grid;
    place-items: center;

    border: 1px solid #4d6077;
    border-radius: 22px;

    background: #314054;
    box-shadow: 0 0 0 5px #253142;
}


.guest-avatar > .icon {
    width: 31px;
    height: 31px;
    color: #d9e2ed;
}


.guest-avatar > span {
    position: absolute;
    bottom: -10px;

    font-size: 12px;
    letter-spacing: 1.4px;

    background: #50627b;

    border: 3px solid #202b3a;
    border-radius: 6px;

    padding: 1px 9px;
}


.welcome h2 {
    font-size: 25px;
    margin-bottom: 13px;
}


.welcome p {
    font-size: 14px;
    line-height: 1.6;
}


.guest-line {
    display: flex;
    justify-content: space-between;

    font-size: 12px;

    margin-top: 24px;
    padding-block: 14px;

    border-top: 1px solid var(--line);

    color: var(--muted);
}


.guest-line strong {
    color: #dee6f2;
    font-weight: 500;
}


.welcome .button {
    font-size: 14px;
    width: 100%;
    padding: 11px;
}


.welcome small {
    font-size: 12px;
    display: block;
    margin-top: 12px;
    color: var(--muted);
}


/* =========================
   CHALLENGE CARD
   ========================= */

.challenge-card {
    padding: 23px;

    position: relative;
    overflow: hidden;

    background:
        linear-gradient(
            125deg,
            #353126,
            #252827 70%
        );

    border: 1px solid #665542;
    border-radius: var(--radius);
}


.challenge-card:after {
    content: '2048';

    position: absolute;
    right: -6px;
    top: 45px;

    font-family: var(--display);
    font-weight: 800;
    font-size: 106px;

    transform: rotate(-14deg);

    color: #e4ad6020;
    pointer-events: none;
}


.challenge-card .eyebrow {
    font-size: 12px;
    color: #e3c79e;
}


.challenge-symbol {
    margin: 18px 0 12px;
    color: var(--orange);
}


.challenge-symbol .icon {
    width: 29px;
    height: 29px;
}


.challenge-card h2 {
    font-family: var(--display);
    font-size: 33px;
    line-height: 1.05;

    position: relative;
    z-index: 1;

    margin-bottom: 13px;
}


.challenge-card p {
    font-size: 13px;
    color: #c0bab0;
}


.text-link {
    display: flex;
    justify-content: space-between;

    color: var(--orange);
    font-size: 13px;
    font-weight: 600;

    margin-top: 22px;
}


/* =========================
   GAME STAGE
   ========================= */

.game-stage {
    width: 100%;
    max-width: 470px;
    margin: auto;
}


.game-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;

    margin-bottom: 21px;
}


.game-heading .eyebrow {
    font-size: 12px;
    letter-spacing: 2px;
}


.game-heading h1,
.game-heading h2 {
    font-family: var(--display);
    font-size: 82px;
    font-weight: 800;

    line-height: 1;
    letter-spacing: -1.5px;
}


.game-heading h1 span,
.game-heading h2 span {
    color: var(--orange);
}


.game-heading p {
    font-size: 14px;
    margin-top: 8px;
}


.mode-pill {
    border: 1px solid #3f5163;

    display: flex;
    align-items: center;
    gap: 7px;

    padding: 7px 11px;

    border-radius: 5px;

    color: #c8d7e5;
    background: #233140;

    font-size: 12px;
    letter-spacing: 1px;
}


.mode-pill .icon {
    width: 13px;
    height: 13px;
}


/* =========================
   SCOREBOARD
   ========================= */

.scoreboard {
    display: flex;
    gap: 9px;
    margin-bottom: 13px;
}


.scoreboard > div {
    background: #223040;
    border: 1px solid #3a495b;
    border-radius: 8px;

    flex: 1;

    padding: 9px 13px;
}


.scoreboard > div:nth-child(2) {
    background: #2d302e;
    border-color: #5b5344;
}


.scoreboard span {
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 1.4px;
    color: #b4c0cd;

    display: flex;
    align-items: center;
    gap: 4px;
}


.scoreboard span .icon {
    width: 11px;
    height: 11px;
    color: var(--orange);
}


.scoreboard strong {
    font-size: 23px;
    font-weight: 700;
    line-height: 1.3;

    display: block;

    font-variant-numeric: tabular-nums;
}


.scoreboard > div:nth-child(2) strong {
    color: #ffca8e;
}


.icon-button {
    background: #263343;

    border: 1px solid #3a495b;
    border-radius: 8px;

    color: var(--muted);

    width: 44px;
}


/* =========================
   GAME BOARD
   ========================= */

.board {
    background: #344354;

    border: 1px solid #526174;

    box-shadow:
        0 16px 60px #0004,
        0 0 55px #b7d5ff0b,
        inset 0 1px 0 #71829544;

    padding: 12px;

    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 11px;

    border-radius: 15px;
    aspect-ratio: 1;
}


.tile {
    border-radius: 9px;

    display: grid;
    place-items: center;

    font-family: var(--display);
    font-size: 43px;
    font-weight: 700;

    color: #354453;

    box-shadow:
        inset 0 2px 0 #ffffff38,
        0 4px 0 #18232b55;

    line-height: 1;

    background: #cfd8df;
}


.tile-0 {
    background: #293646;
    box-shadow: inset 0 2px 3px #0002;
}


.tile-2 {
    background: #dce3e8;
}


.tile-4 {
    background: #c7d6dc;
}


.tile-8 {
    background: #9fc8cd;
}


.tile-16 {
    background: #80b9b8;
}


.tile-32 {
    background: #72a9b1;
}


.tile-64 {
    background: #edbd88;
    color: #513c2d;
}


.tile-128 {
    background: #f6a967;
    color: #563724;
}


.tile-256 {
    background: #f69558;
    color: #592f22;
}


.tile-512 {
    background: #f58155;
    color: #fff5e9;
}


.tile-1024 {
    background: #fbc368;
    color: #51381e;

    box-shadow:
        inset 0 2px 0 #ffe3a9,
        0 4px 0 #bd823f,
        0 0 24px #f9bb5a26;
}


/* =========================
   GAME ACTIONS
   ========================= */

.game-actions {
    display: flex;
    align-items: center;
    gap: 20px;

    margin-top: 20px;
}


.game-actions .button {
    flex: 1;

    box-shadow: 0 4px 0 #ae743e;

    font-size: 16px;

    flex-direction: row-reverse;
}


.game-actions > a {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    font-size: 13px;

    padding: 12px 3px;

    color: #b7c5d6;

    flex: .7;
}


.controls-hint {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 11px;

    margin-top: 25px;

    color: var(--muted);
    font-size: 12px;
}


.keys {
    display: flex;
    gap: 3px;
}


kbd {
    font-family: Arial, sans-serif;

    background: #273343;

    border: 1px solid #425166;
    border-bottom-width: 3px;
    border-radius: 4px;

    display: inline-grid;
    place-items: center;

    width: 20px;
    height: 22px;

    font-size: 12px;
    color: #cbd4e1;
}


.controls-hint i {
    font-style: normal;
    margin-inline: 5px;
}


.data-note {
    font-size: 12px;
    color: #a1b0c1;
    line-height: 1.5;
}


.centered {
    text-align: center;
    margin-top: 11px;
}


/* =========================
   LEADERBOARD PANEL
   ========================= */

.leaders {
    padding: 22px 21px 0;
}


.panel-heading {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}


.panel-heading h2 {
    display: flex;
    gap: 9px;
    align-items: center;

    font-size: 17px;
    font-weight: 600;
}


.panel-heading h2 .icon {
    color: var(--orange);
    width: 19px;
}


.panel-heading > .eyebrow {
    font-size: 12px;
    letter-spacing: 1px;
}


.small {
    font-size: 12px;
    margin-top: 10px;
}


.leader-list {
    list-style: none;

    margin: 20px 0 12px;
    padding: 0;
}


.leader-list li {
    display: flex;
    gap: 11px;
    align-items: center;

    padding: 13px 0;

    border-top: 1px solid #35415288;
}


.rank {
    width: 16px;
    font-size: 12px;
    color: #8e9fb4;
}


.rank .icon {
    width: 16px;
}


.rank0 {
    color: var(--orange);
}


.rank1 {
    color: #d0dce8;
}


.rank2 {
    color: #d09f83;
}


.avatar {
    display: inline-grid;
    place-items: center;

    width: 37px;
    height: 37px;

    border-radius: 11px;

    background: #55667e;
    color: #eaf4ff;

    border: 1px solid #7c90aa;

    font-size: 12px;
    font-weight: 700;

    flex-shrink: 0;
}


.av1 {
    background: #715c48;
    color: #ffe0b6;
    border-color: #907456;
}


.av2 {
    background: #535372;
    color: #e4ddff;
    border-color: #797193;
}


.av3 {
    background: #3c6664;
    color: #c3f0e5;
    border-color: #5c8179;
}


.av4 {
    background: #714f59;
    color: #ffd1d7;
    border-color: #976977;
}


.leader-list a {
    display: flex;
    flex-direction: column;
    min-width: 0;
}


.leader-list strong {
    font-size: 13px;
    font-weight: 600;
    overflow-wrap: anywhere;
}


.leader-list a > span {
    font-size: 12px;
    color: #9eacbe;
    font-variant-numeric: tabular-nums;
}


.leader-list small {
    font-size: 12px;
    color: #8492a7;
}


.panel-link {
    border-top: 1px solid var(--line);

    display: flex;
    align-items: center;
    justify-content: space-between;

    margin-top: 17px;
    padding: 16px 0;

    font-size: 13px;
    font-weight: 500;
}


.panel-link .icon {
    width: 16px;
}


/* =========================
   PROGRESS PANEL
   ========================= */

.progress-panel {
    padding: 21px;
}


.progress-panel .panel-heading > .icon {
    width: 15px;
    color: #9cabc0;
}


.mini-milestones {
    display: flex;
    gap: 8px;

    margin: 21px 0 16px;
}


.mini-milestones span {
    display: grid;
    place-items: center;

    background: #2a3544;

    border: 1px solid #425063;
    border-radius: 7px;

    aspect-ratio: 1;
    flex: 1;

    font-family: var(--display);
    font-weight: 600;
    font-size: 19px;

    color: #b8c5d3;
}


.mini-milestones span:last-child {
    border: 1px dashed #59606b;
    background: transparent;
    color: #a89982;
}


.progress-panel p {
    font-size: 13px;
}


.progress-panel > a {
    font-size: 12px;

    display: flex;
    justify-content: space-between;
    align-items: center;

    color: var(--orange);

    margin-top: 18px;
}


.progress-panel > a .icon {
    width: 16px;
}


/* =========================
   LOBBY BOTTOM
   ========================= */

.lobby-bottom {
    display: flex;
    align-items: center;
    gap: 20px;

    padding: 22px 0;

    border-top: 1px solid var(--line);

    margin-top: 34px;
}


.lobby-bottom > span {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1.5px;

    color: #90a2b7;
}


.lobby-bottom p {
    font-size: 14px;
}


.lobby-bottom strong {
    color: var(--orange);
}


.lobby-bottom > a {
    margin-left: auto;

    font-size: 12px;
    color: #b9c7d7;

    display: flex;
    align-items: center;
    gap: 13px;
}


.lobby-bottom .icon {
    width: 15px;
}


/* =========================
   QUICK LINKS
   ========================= */

.quick-links {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;

    margin-top: 18px;
    margin-bottom: 76px;
}


.quick-links > a {
    display: flex;
    align-items: center;

    padding: 22px 19px;

    border: 1px solid var(--line);
    border-radius: 11px;

    gap: 14px;

    background: #192332;
}


.quick-links > a:hover {
    border-color: #66748a;
    background: #202d3f;
}


.quick-links .eyebrow {
    font-size: 12px;
    letter-spacing: 1.3px;
}


.quick-links h2 {
    font-size: 17px;
    margin: 5px 0 7px;
}


.quick-links p {
    font-size: 12px;
}


.quick-links > a > .icon {
    width: 16px;
    color: #8fa0b5;
    margin-left: auto;
}


.quick-icon {
    width: 42px;
    height: 42px;

    display: grid;
    place-items: center;

    background: #29404a;
    color: #a5d2d2;

    border-radius: 10px;

    flex-shrink: 0;
}


.quick-icon.amber {
    background: #46392e;
    color: #ebbd86;
}


.quick-icon.violet {
    background: #39374d;
    color: #bcb2dc;
}


/* =========================
   RETAINED CONTENT
   ========================= */

.retained {
    border-top: 1px solid var(--line);

    padding-top: 46px;
    padding-bottom: 66px;
}


.section-label {
    margin-bottom: 30px;
}


.reading-layout {
    display: grid;
    grid-template-columns: 260px minmax(0, 780px);
    gap: 75px;
    justify-content: space-between;
}


.reading-layout aside {
    align-self: start;

    position: sticky;
    top: 28px;
}


.reading-layout aside h2 {
    font-family: var(--display);
    font-size: 40px;
    line-height: 1.08;

    margin: 17px 0;
}


.reading-layout aside p {
    font-size: 14px;
    line-height: 1.8;
}


.reading-layout aside > a {
    display: flex;
    align-items: center;
    gap: 13px;

    margin-top: 22px;

    font-size: 14px;
    color: var(--orange);
}


.reading-layout aside > a.button {
    color: #201b16;
}


.reading-layout aside nav {
    display: flex;
    flex-direction: column;
    gap: 20px;

    border-top: 1px solid var(--line);

    padding-top: 28px;
    margin-top: 28px;
}


.reading-layout aside nav a {
    display: flex;
    justify-content: space-between;

    color: var(--muted);
    font-size: 14px;
}


/* =========================
   PROSE
   ========================= */

.prose {
    font-size: 16px;
    line-height: 1.85;
    color: #b7c4d3;
}


.prose p {
    margin: 0 0 21px;
    color: inherit;
}


.prose h2 {
    font-size: 26px;

    margin: 38px 0 18px;

    color: var(--white);
    line-height: 1.3;
}


.prose h2:first-child {
    margin-top: 0;
}


.prose h3 {
    color: var(--white);
    font-size: 20px;
    margin: 27px 0 14px;
}


.prose h4 {
    font-size: 17px;
    margin: 22px 0 12px;
}


.prose a {
    color: var(--orange);
    text-underline-offset: 3px;
    text-decoration: underline;
}


.prose strong {
    color: #2b2721;
    font-weight: 700;
}


.prose ul,
.prose ol {
    padding-left: 21px;
    margin-block: 18px 26px;
}


.prose li {
    margin: 7px 0;
}


.prose hr {
    border: 0;
    border-top: 1px solid var(--line);

    margin: 33px 0;
}


.prose table {
    margin: 24px 0;
    width: 100%;
}


.prose [id] {
    scroll-margin-top: 25px;
}


.prose br + br {
    display: none;
}


.prose img {
    max-width: 100%;
    height: auto;
}


.prose blockquote {
    border-left: 3px solid var(--orange);

    padding-left: 22px;
    margin: 22px 0;
}


/* =========================
   FOOTER
   ========================= */

footer {
    border-top: 1px solid var(--line);

    background: #101721;

    padding:
        35px
        max(40px, calc((100vw - 1296px) / 2))
        24px;

    font-size: 13px;
}


.footer-top {
    display: flex;
    align-items: center;
    gap: 30px;

    padding-bottom: 30px;

    border-bottom: 1px solid var(--line);
}


.footer-top > span {
    font-size: 13px;
    color: var(--muted);
}


.footer-top > a:last-child {
    margin-left: auto;

    display: flex;
    align-items: center;
    gap: 12px;

    font-size: 12px;
}


.footer-top .brand {
    font-size: 22px;
}


.footer-links {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
    padding: 30px 0;
}


.footer-links > div {
    display: flex;
    flex-direction: column;
    gap: 9px;

    color: var(--muted);
}


.footer-links b {
    color: #e5eaf1;
    font-size: 13px;

    margin-bottom: 5px;
}


.footer-bottom {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: center;

    border-top: 1px solid var(--line);

    padding-top: 23px;

    color: #a0adc0;
    font-size: 12px;
}


.footer-bottom > div {
    display: flex;
    gap: 20px;
}


.prototype {
    color: #a7a58f;
}


/* =========================
   GENERAL PAGE LAYOUT
   ========================= */

.page-section {
    padding-top: 45px;
    padding-bottom: 74px;
}


.page-heading {
    margin-bottom: 40px;
    max-width: 920px;
}


.breadcrumb {
    display: block;

    color: var(--muted);
    font-size: 12px;

    margin-bottom: 37px;
}


.page-heading > .eyebrow {
    display: block;

    color: var(--orange);

    margin-bottom: 16px;
}


.page-heading h1 {
    font-family: var(--display);
    font-size: 64px;
    font-weight: 700;

    line-height: 1.04;
    letter-spacing: -.6px;

    max-width: 950px;
}


.page-heading > p {
    margin-top: 18px;
    font-size: 17px;
}


/* =========================
   PODIUM
   ========================= */

.podium {
    display: grid;
    grid-template-columns: 1fr 1.15fr 1fr;
    align-items: end;
    gap: 20px;

    margin-top: 65px;
    margin-bottom: 36px;
}


.podium-card {
    text-align: center;

    border: 1px solid var(--line);

    background:
        linear-gradient(
            150deg,
            #27364a,
            #1a2432
        );

    border-radius: 15px;

    padding: 28px 18px;

    display: flex;
    align-items: center;
    flex-direction: column;
}


.podium-card.place-0 {
    background:
        linear-gradient(
            150deg,
            #454032,
            #242a2d
        );

    border-color: #826344;

    padding-top: 38px;
    padding-bottom: 38px;

    box-shadow: 0 -8px 60px #ddac6308;
}


.podium-card > .eyebrow {
    font-size: 12px;
    color: var(--orange);
}


.podium-card .avatar {
    height: 64px;
    width: 64px;

    font-size: 19px;

    border-radius: 20px;

    margin: 22px 0 15px;
}


.podium-card h2 {
    font-size: 24px;
}


.podium-card strong {
    font-family: var(--display);
    font-size: 42px;
    color: var(--orange);

    margin-top: 12px;
}


.podium-card > span:last-child {
    font-size: 12px;
    color: var(--muted);
}


/* =========================
   RANKINGS
   ========================= */

.rankings {
    overflow: hidden;
}


.ranking-toolbar {
    padding: 25px 28px;

    display: flex;
    justify-content: space-between;
    gap: 20px;
    align-items: center;
}


.ranking-toolbar h2 {
    font-size: 21px;
}


.ranking-toolbar h2 .icon {
    color: var(--orange);
    margin-right: 8px;
}


.tabs {
    display: flex;
    gap: 4px;
}


.tabs button {
    border: 0;

    background: transparent;

    color: var(--muted);
    font-size: 13px;

    border-radius: 5px;

    padding: 8px 14px;

    white-space: nowrap;
}


.tabs button.selected {
    background: #3b4552;
    color: var(--white);
}


.filter-row {
    display: flex;
    align-items: center;
    gap: 20px;

    border-block: 1px solid var(--line);

    padding: 14px 28px;

    font-size: 12px;
    color: var(--muted);
}


.filter-row .data-note {
    margin-left: auto;
}


.table-scroll {
    overflow-x: auto;
}


table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 14px;
}


th {
    font-size: 12px;
    letter-spacing: .6px;
    text-transform: uppercase;
    font-weight: 600;

    color: var(--muted);

    background: #14202b66;
}


th,
td {
    padding: 19px 26px;
    border-bottom: 1px solid var(--line);
}


td a {
    display: flex;
    align-items: center;
    gap: 13px;

    font-weight: 600;
}


td.score-cell {
    color: var(--orange);
    font-weight: 600;
}


.table-note {
    padding: 18px 28px;
}


/* =========================
   JOIN BANNER
   ========================= */

.join-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;

    padding: 32px;
    margin-top: 30px;

    border: 1px solid #594c3d;
    border-radius: 12px;

    background:
        linear-gradient(
            100deg,
            #302d27,
            #1d2832
        );
}


.join-banner h2 {
    font-family: var(--display);
    font-size: 32px;

    margin-bottom: 8px;
}


.join-banner p {
    font-size: 14px;
}


/* =========================
   AUTH LAYOUT
   ========================= */

.auth-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 120px;

    padding-top: 70px;
    padding-bottom: 75px;

    max-width: 1220px;

    align-items: start;
}


.auth-story {
    padding-top: 48px;
}


.auth-story > .eyebrow {
    color: var(--orange);
}


.auth-story h1 {
    font-family: var(--display);
    font-size: 78px;

    line-height: .97;
    letter-spacing: -1px;

    margin: 26px 0;
}


.auth-story h1 span {
    display: block;
    color: var(--orange);

    margin-top: 9px;
}


.auth-story > p {
    max-width: 350px;
    line-height: 1.8;
}


.identity-tiles {
    display: flex;
    gap: 12px;

    transform: rotate(-6deg);

    margin: 50px 0;

    width: 100%;
}


.identity-tiles > span {
    background: #a4c5cd;
    color: #2d4552;

    border-radius: 11px;

    box-shadow: 0 5px 0 #546c79;

    aspect-ratio: 1;
    width: 25%;

    display: grid;
    place-items: center;

    font-family: var(--display);
    font-weight: 700;
    font-size: 34px;
}


.identity-tiles > span:nth-child(2) {
    background: #f0b37e;
    color: #553820;

    transform: translateY(-13px);
}


.identity-tiles > span:nth-child(3) {
    background: #ef925e;
    color: #fff;

    transform: translateY(-6px);
}


.identity-tiles > span:nth-child(4) {
    background: #fac76f;
    color: #52381d;

    transform: translateY(-23px);
}


.auth-benefits {
    display: grid;
    gap: 20px;

    color: #c5d0de;
    font-size: 14px;
}


.auth-benefits .icon {
    margin-right: 12px;

    color: var(--orange);

    width: 19px;
}


/* =========================
   FORMS
   ========================= */

.form-panel {
    padding: 30px 34px;
}


.form-tabs {
    display: flex;
    gap: 26px;

    border-bottom: 1px solid var(--line);

    margin-bottom: 29px;
}


.form-tabs a {
    padding: 0 0 15px;

    font-size: 14px;
    color: var(--muted);
}


.form-tabs a[aria-current] {
    color: var(--orange);
    border-bottom: 2px solid var(--orange);
}


.form-panel > h2 {
    font-size: 29px;
    margin-bottom: 9px;
}


.form-panel > p {
    font-size: 14px;
    margin-bottom: 25px;
}


.field {
    display: flex;
    flex-direction: column;
    gap: 8px;

    font-size: 13px;
    font-weight: 500;
    color: #e0e6ef;

    margin-bottom: 20px;
}


.field input,
.field textarea,
.field select {
    width: 100%;
    min-width: 0;

    background: #121d2a;

    border: 1px solid #3c4b60;
    border-radius: 7px;

    padding: 12px 13px;

    color: var(--white);
    font-size: 14px;
}


.field input::placeholder,
.field textarea::placeholder {
    color: #8a9bae;
}


.field input:focus,
.field textarea:focus {
    border-color: var(--orange);
}


.field textarea {
    resize: vertical;
}


.checkbox {
    display: flex;
    align-items: center;
    gap: 9px;

    font-size: 12px;
    color: var(--muted);

    margin: 17px 0;

    line-height: 1.6;
}


.checkbox input {
    accent-color: var(--orange);

    width: 16px;
    height: 16px;

    flex-shrink: 0;

    margin: 0;
}


.checkbox a,
.form-options > a {
    color: var(--orange);
}


.form-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;

    font-size: 12px;

    margin-top: -4px;
    margin-bottom: 10px;
}


.form-panel form > .button {
    width: 100%;
    margin-top: 7px;
}


.form-note {
    font-size: 12px;
    text-align: center;

    margin-top: 18px;

    line-height: 1.6;
}


.form-note .icon {
    width: 12px;
    height: 12px;

    margin-right: 4px;
}


.form-switch {
    border-top: 1px solid var(--line);

    margin-top: 25px;
    padding-top: 22px;

    font-size: 12px;
    text-align: center;

    color: var(--muted);
}


.form-switch a {
    color: var(--orange);
    margin-left: 4px;
}


/* =========================
   AVATAR SELECTION
   ========================= */

.avatar-selection {
    padding: 0;
    border: 0;

    display: flex;
    gap: 13px;

    margin: 24px 0;
}


.avatar-selection legend {
    font-size: 13px;
    margin-bottom: 12px;
}


.avatar-selection label {
    position: relative;
    cursor: pointer;
}


.avatar-selection input {
    position: absolute;
    opacity: 0;
}


.avatar-selection span {
    display: grid;
    place-items: center;

    width: 48px;
    height: 48px;

    background: #334359;

    border-radius: 12px;
    border: 2px solid transparent;
}


.avatar-selection input:checked + span {
    border-color: var(--orange);
    background: #4b4034;
    color: var(--orange);
}


.avatar-selection input:focus-visible + span {
    outline: 3px solid var(--orange);
    outline-offset: 4px;
}


.narrow {
    max-width: 700px;
}


.preserved-account {
    padding-bottom: 70px;
}


/* =========================
   PROFILE
   ========================= */

.profile-banner {
    display: flex;
    align-items: center;

    padding: 32px;
    gap: 25px;

    margin-bottom: 25px;
}


.profile-banner > .avatar {
    width: 86px;
    height: 86px;

    font-size: 26px;

    border-radius: 25px;
}


.profile-banner h2 {
    font-family: var(--display);
    font-size: 40px;

    margin-top: 8px;

    overflow-wrap: anywhere;
}


.profile-banner p {
    font-size: 13px;
    margin-top: 9px;
}


.profile-banner p > span {
    margin-inline: 10px;
}


.profile-banner > .button {
    margin-left: auto;
}


.profile-banner .eyebrow {
    font-size: 12px;
}


/* =========================
   STATS
   ========================= */

.stat-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;

    margin-bottom: 28px;
}


.stat-card {
    padding: 24px;

    display: grid;
    grid-template-columns: 1fr auto;
}


.stat-card > .icon {
    grid-column: 2;
    grid-row: 1;

    color: var(--orange);
}


.stat-card > span {
    font-size: 13px;

    grid-column: 1;
    grid-row: 1;

    color: var(--muted);
}


.stat-card > strong {
    font-family: var(--display);
    font-size: 43px;

    margin-top: 10px;
}


.profile-columns {
    display: grid;
    grid-template-columns: 1.6fr 1fr;
    gap: 26px;
}


/* =========================
   ACTIVITY
   ========================= */

.activity .panel-heading {
    padding: 25px;
}


.activity th,
.activity td {
    padding: 17px 23px;
    font-size: 12px;
}


.activity h3 {
    font-size: 15px;
    margin: 26px 26px 10px;
}


.chart {
    height: 170px;

    display: flex;
    gap: 16px;

    margin: 10px 26px 30px;

    align-items: end;

    border-bottom: 1px solid var(--line);

    background:
        repeating-linear-gradient(
            to top,
            transparent 0,
            transparent 39px,
            #8091a011 39px,
            #8091a011 40px
        );
}


.chart > div {
    height: 100%;
    flex: 1;

    display: flex;
    flex-direction: column;
    justify-content: end;
    align-items: center;

    position: relative;
}


.chart span {
    width: 100%;
    max-width: 40px;

    background: #668c9c;

    border-radius: 5px 5px 0 0;
}


.chart > div:last-child span {
    background: var(--orange);
}


.chart small {
    position: absolute;
    bottom: -23px;

    font-size: 12px;
    color: var(--muted);
}


/* =========================
   ACHIEVEMENTS
   ========================= */

.achievement-preview {
    padding: 25px;
}


.milestone-row {
    display: flex;
    align-items: center;
    gap: 14px;

    border-bottom: 1px solid var(--line);

    padding: 19px 0;
}


.milestone-row strong {
    font-size: 14px;
}


.milestone-row small {
    display: block;

    color: var(--muted);
    font-size: 12px;

    margin-top: 4px;
}


.milestone-row > .icon {
    margin-left: auto;

    width: 15px;
    color: #a3c6b2;
}


.badge-tile {
    width: 50px;
    aspect-ratio: 1;

    border: 1px solid #6e8996;

    background: #314956;
    color: #b7d8df;

    display: grid;
    place-items: center;

    border-radius: 10px;

    font-family: var(--display);
    font-size: 22px;
    font-weight: 600;

    flex-shrink: 0;
}


.badge-1 {
    background: #415953;
    color: #c0e0cd;
    border-color: #6a8e7d;
}


.badge-2 {
    background: #5c4934;
    color: #f4cc91;
    border-color: #9b774b;
}


.badge-3 {
    background: #745232;
    color: #ffd995;
    border-color: #b2874e;
}


.badge-4 {
    background: #663e36;
    color: #fab9a0;
    border-color: #ab6b55;
}


.badge-5 {
    background: #514066;
    color: #d8bdef;
    border-color: #8968a7;
}


.milestone-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}


.milestone-card {
    padding: 28px;
}


.milestone-card > .eyebrow {
    font-size: 12px;
}


.milestone-card > .badge-tile {
    width: 85px;

    font-size: 36px;

    margin: 26px 0;

    border-radius: 19px;
}


.milestone-card h2 {
    font-size: 24px;
    margin-bottom: 14px;
}


.milestone-card p {
    font-size: 14px;
    line-height: 1.8;
    min-height: 75px;
}


.milestone-status {
    display: flex;
    gap: 9px;
    align-items: center;

    font-size: 12px;

    border-top: 1px solid var(--line);

    padding-top: 20px;
    margin-top: 20px;

    color: var(--muted);
}


.milestone-status .icon {
    width: 14px;
}


/* =========================
   CHALLENGE HERO
   ========================= */

.challenge-hero {
    padding: 50px;

    display: flex;
    align-items: center;
    justify-content: space-between;

    background:
        linear-gradient(
            120deg,
            #31312b,
            #1e2c38
        );

    border-color: #5b5141;
}


.challenge-hero h2 {
    font-family: var(--display);
    font-size: 64px;
    line-height: 1.05;

    margin: 20px 0;
}


.challenge-hero h2 span {
    color: var(--orange);
}


.challenge-hero p {
    font-size: 15px;
    line-height: 1.8;
}


.challenge-hero .button {
    margin-top: 25px;
}


.challenge-hero .data-note {
    font-size: 12px;
    margin-top: 16px;
}


.champion-emblem {
    border: 1px solid #89714e;

    width: 260px;
    aspect-ratio: 1;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    border-radius: 40px;

    background: #d5a0570b;

    transform: rotate(5deg);

    box-shadow: 0 0 0 15px #e8b76c05;

    flex-shrink: 0;
}


.champion-emblem > .icon {
    width: 70px;
    height: 70px;

    color: var(--orange);

    margin-bottom: 15px;
}


.champion-emblem > span {
    font-size: 12px;
    letter-spacing: 3px;

    color: var(--orange);
}


.champion-emblem > strong {
    font-family: var(--display);
    font-size: 67px;
    line-height: 1.2;
}


/* =========================
   CONTENT PAGES
   ========================= */

.content-page .page-heading h1 {
    font-size: 58px;
    line-height: 1.1;
}


.content-page .reading-layout {
    margin-top: 55px;
}


/* =========================
   404
   ========================= */

.not-found {
    padding-block: 90px 100px;
    text-align: center;
}


.error-tiles {
    display: flex;
    gap: 18px;
    justify-content: center;

    margin: 40px 0;
}


.error-tiles > span {
    font-family: var(--display);
    font-size: 95px;
    font-weight: 700;

    border-radius: 20px;

    background: #f6b770;
    color: #5a3d24;

    width: 135px;
    aspect-ratio: 1;

    box-shadow: 0 8px 0 #926d48;

    display: grid;
    place-items: center;

    transform: rotate(-6deg);
}


.error-tiles > span:nth-child(2) {
    background: #263646;
    color: #8f9dae;

    transform: rotate(6deg);

    box-shadow: 0 8px 0 #1c2936;
}


.error-tiles > span:nth-child(3) {
    transform: rotate(-3deg);
}


.not-found h1 {
    font-family: var(--display);
    font-size: 51px;

    margin-top: 45px;
}


.not-found p {
    margin: 18px 0 28px;
}


.embed-board {
    max-width: 470px;
    margin: auto;
}


/* =========================
   ACCESSIBILITY
   ========================= */

.skip {
    position: fixed;
    left: 20px;
    top: -100px;

    z-index: 100;

    background: var(--orange);
    color: #171e27;

    padding: 12px 20px;

    border-radius: 6px;
}


.skip:focus {
    top: 15px;
}


.sr-only {
    position: absolute;

    width: 1px;
    height: 1px;

    padding: 0;

    overflow: hidden;

    clip: rect(0, 0, 0, 0);

    white-space: nowrap;

    border: 0;
}


/* =========================
   FORM VALIDATION
   ========================= */

.field input[aria-invalid=true],
.field textarea[aria-invalid=true] {
    border-color: #f3a295;
    background: #33262a;
}


.field .field-error {
    color: #f3a295;
    font-size: 13px;
}


.field .field-help {
    color: var(--muted);
    font-size: 13px;
}


/* =========================
   GRID/FLEX SAFETY
   ========================= */

.profile-columns > *,
.stat-grid > *,
.reading-layout > *,
.milestone-grid > * {
    min-width: 0;
}


/* =========================
   LARGE DESKTOP
   ========================= */

@media (min-width: 1500px) {

    .lobby-grid {
        gap: 49px;
    }

    .lobby {
        padding-top: 33px;
    }

    .left-rail,
    .right-rail {
        padding-top: 41px;
    }

    .lobby-bottom {
        margin-top: 42px;
    }

}


/* =========================
   TABLET / SMALL DESKTOP
   ========================= */

@media (max-width: 1180px) {

    .header-inner {
        padding-inline: 24px;
        gap: 20px;
    }

    .header nav {
        gap: 18px;
    }

    .header nav a {
        font-size: 13px;
    }

    .header nav a .icon {
        display: none;
    }

    .auth-nav {
        gap: 16px;
    }

    .wrap {
        padding-inline: 30px;
    }

    .lobby-grid {
        gap: 24px;

        grid-template-columns:
            minmax(185px, 1fr)
            minmax(310px, 430px)
            minmax(200px, 1fr);
    }

    .welcome,
    .leaders,
    .progress-panel {
        padding-inline: 17px;
    }

    .leader-list li {
        gap: 8px;
    }

    .leader-list .avatar {
        width: 30px;
        height: 30px;

        font-size: 12px;

        border-radius: 8px;
    }

    .leader-list strong {
        font-size: 12px;
    }

    .panel-heading h2 {
        font-size: 15px;
    }

    .panel-heading > .eyebrow {
        display: none;
    }

    .quick-links {
        gap: 12px;
    }

    .quick-links > a {
        padding: 18px 14px;
        gap: 10px;
    }

    .quick-links p {
        font-size: 12px;
    }

    .quick-links h2 {
        font-size: 15px;
    }

    .quick-icon {
        width: 33px;
        height: 33px;
    }

    .auth-layout {
        gap: 65px;
    }

    .reading-layout {
        gap: 45px;
        grid-template-columns: 220px minmax(0, 1fr);
    }

    .champion-emblem {
        width: 220px;
    }

    .tile {
        font-size: 38px;
    }

    .form-panel {
        padding: 28px;
    }

    .footer-bottom {
        flex-wrap: wrap;
    }

}


/* =========================
   TABLET / MOBILE NAV
   ========================= */

@media (max-width: 980px) {

    .header-inner {
        flex-wrap: wrap;

        padding-top: 18px;

        gap: 14px;

        min-height: 100px;
    }

    .header nav {
        order: 3;

        width: 100%;
        height: 48px;

        justify-content: center;

        gap: 42px;
    }

    .header nav a {
        font-size: 14px;
    }

    .header nav a .icon {
        display: block;
        width: 17px;
    }

    .auth-nav {
        margin-left: auto;
    }

    .lobby-grid {
        grid-template-columns:
            minmax(310px, 1.4fr)
            minmax(220px, 1fr);

        gap: 30px;
    }

    .left-rail {
        display: none;
    }

    .game-stage {
        max-width: 470px;
    }

    .right-rail {
        padding-top: 24px;
    }

    .lobby-bottom > span {
        display: none;
    }

    .quick-links {
        grid-template-columns: 1fr 1fr;
    }

    .quick-links > a:last-child {
        grid-column: 1 / -1;
    }

    .quick-links p {
        font-size: 12px;
    }

    .quick-links h2 {
        font-size: 17px;
    }

    .quick-links .eyebrow {
        font-size: 12px;
    }

    .auth-layout {
        gap: 40px;
    }

    .auth-story h1 {
        font-size: 65px;
    }

    .reading-layout {
        grid-template-columns: 185px minmax(0, 1fr);
        gap: 35px;
    }

    .podium-card h2 {
        font-size: 20px;
    }

    .podium-card strong {
        font-size: 35px;
    }

    .profile-columns {
        grid-template-columns: 1fr;
    }

    .profile-banner .eyebrow {
        font-size: 12px;
    }

    .milestone-grid {
        grid-template-columns: 1fr 1fr;
    }

    .ranking-toolbar {
        flex-wrap: wrap;
    }

    .filter-row {
        flex-wrap: wrap;
    }

    .filter-row .data-note {
        margin-left: 0;
    }

    .challenge-hero {
        padding: 35px;
        gap: 25px;
    }

    .challenge-hero h2 {
        font-size: 53px;
    }

    .champion-emblem {
        width: 170px;
    }

    .champion-emblem > strong {
        font-size: 52px;
    }

    .champion-emblem > .icon {
        width: 50px;
        height: 50px;
    }

    .champion-emblem > span {
        font-size: 12px;
    }

    .profile-banner {
        flex-wrap: wrap;
    }

    .stat-card {
        padding: 20px;
    }

    .footer-top > span {
        display: none;
    }

}


/* =========================
   MOBILE
   ========================= */

@media (max-width: 650px) {

    .wrap {
        padding-inline: 20px;
    }

    .header-inner {
        padding-inline: 18px;
    }

    .brand {
        font-size: 23px;
        gap: 5px;
    }

    .brand-mark {
        width: 31px;
    }

    .brand-mark .icon {
        width: 27px;
    }

    .brand small {
        font-size: 12px;
    }

    .auth-nav {
        gap: 14px;
        font-size: 12px;
    }

    .auth-nav .button {
        padding: 8px 10px;
        font-size: 12px;
    }

    .header nav {
        gap: 0;
        justify-content: space-between;
        overflow: auto;
        height: 47px;
    }

    .header nav a {
        font-size: 12px;
        gap: 5px;
    }

    .header nav a .icon {
        width: 15px;
    }

    .lobby {
        padding-top: 21px;
    }

    .lobby-top {
        margin-bottom: 21px;
        font-size: 12px;
    }

    .lobby-top .eyebrow {
        font-size: 12px;
    }

    .preview-tag {
        font-size: 12px;
    }

    .lobby-grid {
        display: flex;
        flex-direction: column;
        gap: 28px;
    }

    .game-stage {
        order: 0;
        max-width: 440px;
    }

    .game-heading {
        margin-bottom: 18px;
    }

    .game-heading h1,
    .game-heading h2 {
        font-size: 76px;
    }

    .game-heading .eyebrow {
        font-size: 12px;
        letter-spacing: 1.3px;
    }

    .game-heading p {
        font-size: 13px;
    }

    .mode-pill {
        font-size: 12px;
    }

    .board {
        padding: 10px;
        gap: 9px;
        border-radius: 13px;
    }

    .tile {
        font-size: 38px;
        border-radius: 7px;
    }

    .scoreboard > div {
        padding: 9px 10px;
    }

    .scoreboard strong {
        font-size: 22px;
    }

    .scoreboard span {
        font-size: 12px;
    }

    .scoreboard .icon-button {
        width: 38px;
    }

    .controls-hint {
        font-size: 12px;
        gap: 8px;
    }

    .game-actions {
        gap: 15px;
    }

    .game-actions .button {
        padding-block: 12px;
    }

    .right-rail {
        order: 1;

        display: grid;
        grid-template-columns: 1fr;

        width: 100%;

        padding-top: 0;
        gap: 18px;
    }

    .leaders {
        padding: 22px 22px 0;
    }

    .panel-heading h2 {
        font-size: 18px;
    }

    .panel-heading > .eyebrow {
        display: block;
        font-size: 12px;
    }

    .leader-list {
        margin: 16px 0 10px;
    }

    .leader-list li {
        gap: 13px;
        padding: 11px 0;
    }

    .leader-list .avatar {
        width: 36px;
        height: 36px;

        font-size: 12px;
    }

    .leader-list a {
        flex: 1;

        flex-direction: row;
        justify-content: space-between;
        align-items: center;

        gap: 10px;
    }

    .leader-list strong {
        font-size: 14px;
    }

    .leader-list a > span {
        font-size: 13px;
    }

    .progress-panel {
        padding: 22px;
    }

    .mini-milestones {
        max-width: 280px;
    }

    .mini-milestones span {
        font-size: 23px;
    }

    .lobby-bottom {
        margin-top: 26px;

        flex-wrap: wrap;
        gap: 12px;

        padding-block: 22px;
    }

    .lobby-bottom > a {
        margin-left: 0;
    }

    .lobby-bottom p {
        width: 100%;
        font-size: 16px;
    }

    .quick-links {
        grid-template-columns: 1fr;
        gap: 12px;

        margin-top: 8px;
        margin-bottom: 40px;
    }

    .quick-links > a:last-child {
        grid-column: auto;
    }

    .quick-links > a {
        padding: 21px 19px;
    }

    .quick-icon {
        width: 42px;
        height: 42px;
    }

    .quick-links h2 {
        font-size: 18px;
    }

    .quick-links p {
        font-size: 13px;
    }

    .reading-layout {
        display: block;
    }

    .reading-layout aside {
        position: static;

        border-bottom: 1px solid var(--line);

        padding-bottom: 25px;
        margin-bottom: 30px;
    }

    .reading-layout aside h2 br,
    .reading-layout aside p br {
        display: none;
    }

    .reading-layout aside h2 {
        font-size: 36px;
    }

    .reading-layout aside nav {
        gap: 14px;
    }

    .retained {
        padding-top: 30px;
        padding-bottom: 40px;
    }

    .prose {
        font-size: 16px;
        line-height: 1.8;
    }

    .prose h2 {
        font-size: 24px;
    }

    .section-label {
        margin-bottom: 10px;
    }

    .page-section {
        padding-top: 28px;
        padding-bottom: 40px;
    }

    .breadcrumb {
        margin-bottom: 25px;
    }

    .page-heading {
        margin-bottom: 28px;
    }

    .page-heading h1,
    .content-page .page-heading h1 {
        font-size: 47px;
    }

    .page-heading > p {
        font-size: 16px;
    }

    .auth-layout {
        display: flex;
        flex-direction: column;

        padding-top: 35px;
        padding-bottom: 35px;

        gap: 25px;
    }

    .auth-story {
        padding-top: 0;
        width: 100%;
    }

    .auth-story h1 {
        font-size: 55px;
        line-height: 1.03;
        margin: 18px 0;
    }

    .auth-story h1 br {
        display: none;
    }

    .auth-story h1 span {
        margin-top: 0;
    }

    .auth-story p {
        max-width: 100%;
        font-size: 14px;
    }

    .identity-tiles,
    .auth-benefits {
        display: none;
    }

    .form-panel {
        padding: 25px;
        width: 100%;
    }

    .form-panel > .h2 {
        font-size: 26px;
    }

    .auth-layout .form-panel {
        max-width: 470px;
        margin: auto;
    }

    .field {
        font-size: 14px;
    }

    .field input,
    .field textarea,
    .field select {
        font-size: 16px;
    }

    .checkbox {
        font-size: 13px;
    }

    .form-switch {
        font-size: 13px;
    }

    .form-options {
        font-size: 12px;
    }

    .podium {
        gap: 9px;
        margin-top: 35px;
    }

    .podium-card {
        padding: 18px 7px;
        border-radius: 10px;
    }

    .podium-card.place-0 {
        padding: 27px 7px;
    }

    .podium-card > .eyebrow {
        font-size: 12px;
        letter-spacing: .8px;
    }

    .podium-card .avatar {
        width: 45px;
        height: 45px;

        font-size: 14px;

        border-radius: 14px;

        margin: 15px 0 12px;
    }

    .podium-card h2 {
        font-size: 13px;
        overflow-wrap: anywhere;
        max-width: 100%;
    }

    .podium-card strong {
        font-size: 25px;
        letter-spacing: -.5px;
    }

    .podium-card > span:last-child {
        font-size: 12px;
        line-height: 1.4;
    }

    .ranking-toolbar {
        padding: 20px;
        gap: 17px;
    }

    .ranking-toolbar .tabs {
        width: 100%;
        overflow: auto;
    }

    .tabs button {
        font-size: 12px;
        padding: 7px 10px;
    }

    .filter-row {
        padding: 15px 20px;
        gap: 9px;
    }

    .filter-row > span:first-child {
        width: 100%;
    }

    th,
    td {
        padding: 16px 18px;
        white-space: nowrap;
    }

    table {
        font-size: 13px;
    }

    .join-banner {
        padding: 25px;

        flex-direction: column;
        align-items: start;
        gap: 23px;
    }

    .join-banner h2 {
        font-size: 30px;
    }

    .profile-banner {
        padding: 23px;
        gap: 18px;
    }

    .profile-banner > .avatar {
        width: 62px;
        height: 62px;

        border-radius: 18px;

        font-size: 20px;
    }

    .profile-banner > div {
        flex: 1;
        min-width: 160px;
    }

    .profile-banner h2 {
        font-size: 31px;
    }

    .profile-banner .eyebrow {
        font-size: 12px;
        letter-spacing: 1px;
    }

    .profile-banner p {
        font-size: 12px;
    }

    .profile-banner > .button {
        margin-left: 0;
        width: 100%;
        font-size: 14px;
    }

    .stat-grid {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
    }

    .stat-card {
        padding: 18px;
    }

    .stat-card > span {
        font-size: 12px;
    }

    .stat-card > .icon {
        width: 17px;
    }

    .stat-card > strong {
        font-size: 38px;
    }

    .profile-columns {
        gap: 18px;
    }

    .activity .panel-heading,
    .achievement-preview {
        padding: 20px;
    }

    .activity .panel-heading .eyebrow {
        font-size: 12px;
    }

    .activity td,
    .activity th {
        padding: 16px 19px;
    }

    .milestone-grid {
        gap: 14px;
    }

    .milestone-card {
        padding: 21px;
    }

    .milestone-card > .badge-tile {
        width: 65px;

        font-size: 30px;

        margin-block: 21px;
    }

    .milestone-card h2 {
        font-size: 20px;
    }

    .milestone-card p {
        font-size: 13px;
        min-height: 120px;
        line-height: 1.7;
    }

    .milestone-status {
        font-size: 12px;
        align-items: start;
    }

    .challenge-hero {
        padding: 27px;
        display: block;
    }

    .challenge-hero h2 {
        font-size: 49px;
    }

    .challenge-hero p {
        font-size: 14px;
    }

    .champion-emblem {
        display: none;
    }

    .not-found {
        padding-block: 70px;
    }

    .error-tiles {
        gap: 13px;
    }

    .error-tiles > span {
        width: 88px;

        font-size: 66px;

        border-radius: 13px;
    }

    .not-found h1 {
        font-size: 42px;
    }

    .not-found p {
        font-size: 15px;
    }

    footer {
        padding: 28px 20px;
    }

    .footer-top {
        gap: 16px;
    }

    .footer-top .brand {
        font-size: 20px;
    }

    .footer-top > a:last-child {
        font-size: 12px;
        gap: 5px;
    }

    .footer-links {
        grid-template-columns: 1fr 1fr;
        gap: 28px 22px;

        font-size: 12px;
    }

    .footer-bottom {
        flex-direction: column;
        align-items: start;

        gap: 14px;

        font-size: 12px;
    }

    .content-page .reading-layout {
        margin-top: 30px;
    }

}


/* =========================
   SMALL MOBILE FIXES
   ========================= */

@media (max-width: 650px) {

    .activity .panel-heading {
        flex-wrap: wrap;
    }

    .activity .table-scroll {
        max-width: 100%;
    }

    .auth-story h1 br:after {
        content: ' ';
    }

}


/* =========================
   VERY SMALL MOBILE
   ========================= */

@media (max-width: 380px) {

    .podium,
    .milestone-grid {
        grid-template-columns: 1fr;
    }

    .podium .place-0 {
        order: -1;
    }

    .podium-card h2 {
        font-size: 21px;
    }

    .podium-card strong {
        font-size: 35px;
    }

    .podium-card .avatar {
        width: 55px;
        height: 55px;
    }

    .milestone-card p {
        min-height: 0;
    }

    .tile {
        font-size: 32px;
    }

    .game-heading h1 {
        font-size: 66px;
    }

    .scoreboard {
        gap: 5px;
    }

    .scoreboard > div {
        padding-inline: 7px;
    }

    .scoreboard strong {
        font-size: 20px;
    }

    .controls-hint {
        flex-wrap: wrap;
    }

    .mode-pill {
        padding: 6px;
    }

    .header nav a {
        font-size: 12px;
    }

    .header nav a .icon {
        display: none;
    }

}


/* =========================
   REDUCED MOTION
   ========================= */

@media (prefers-reduced-motion: reduce) {

    html {
        scroll-behavior: auto;
    }

    * {
        transition: none !important;
        animation: none !important;
    }

}

/* =========================================================
   2048 STATISTICS
   ========================================================= */

.statistics-hero {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    margin-bottom: 22px;
}

.statistic-feature {
    position: relative;
    padding: 28px;
    overflow: hidden;
}

.statistic-feature .eyebrow {
    display: block;
    margin-bottom: 14px;
}

.statistic-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin-bottom: 22px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.035);
}

.statistic-icon .icon {
    width: 22px;
    height: 22px;
}

.statistic-big {
    display: block;
    margin-bottom: 6px;
    font-family: "Barlow Condensed", sans-serif;
    font-size: clamp(2.8rem, 5vw, 4.8rem);
    font-weight: 800;
    line-height: 0.95;
    letter-spacing: -0.035em;
    color: var(--white);
}

.statistic-feature > p {
    margin: 0 0 18px;
    color: var(--muted);
}

.statistics-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
    gap: 22px;
    margin-bottom: 22px;
}

.statistics-panel {
    padding: 28px;
}

.statistics-panel .panel-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 28px;
}

.statistics-panel .panel-heading h2 {
    margin: 5px 0 0;
}

.statistics-panel .panel-heading > .icon {
    flex: 0 0 auto;
    width: 28px;
    height: 28px;
    color: var(--orange);
}


/* COUNTRY BREAKDOWN */

.country-breakdown {
    display: grid;
    grid-template-columns: minmax(180px, 250px) 1fr;
    align-items: center;
    gap: 38px;
}

.country-chart {
    position: relative;
    width: min(100%, 240px);
    aspect-ratio: 1;
    margin-inline: auto;
    border-radius: 50%;
    background:
        conic-gradient(
            var(--orange) 0 38%,
            var(--mint) 38% 62%,
            #8fa8d8 62% 76%,
            #c795dc 76% 85%,
            #e2c876 85% 91%,
            #566478 91% 100%
        );
}

.country-chart::after {
    content: "";
    position: absolute;
    inset: 26%;
    border-radius: 50%;
    background: var(--panel);
    box-shadow: 0 0 0 1px var(--line);
}

.country-chart-centre {
    position: absolute;
    z-index: 1;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

.country-chart-centre strong {
    font-family: "Barlow Condensed", sans-serif;
    font-size: 2rem;
    line-height: 1;
    color: var(--white);
}

.country-chart-centre span {
    margin-top: 5px;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--muted);
}

.statistics-legend {
    display: grid;
    gap: 10px;
}

.statistics-legend > div {
    display: grid;
    grid-template-columns: 11px minmax(0, 1fr) auto;
    align-items: center;
    gap: 10px;
    padding: 9px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.statistics-legend > div:last-child {
    border-bottom: 0;
}

.statistics-legend strong {
    font-weight: 600;
}

.statistics-legend > div > span:last-child {
    color: var(--muted);
}

.legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.country-a {
    background: var(--orange);
}

.country-b {
    background: var(--mint);
}

.country-c {
    background: #8fa8d8;
}

.country-d {
    background: #c795dc;
}

.country-e {
    background: #e2c876;
}

.country-f {
    background: #566478;
}


/* DEVICE BREAKDOWN */

.device-breakdown {
    display: grid;
    gap: 25px;
}

.device-row {
    display: grid;
    gap: 10px;
}

.device-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
}

.device-label > span {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 600;
}

.device-label .icon {
    width: 19px;
    height: 19px;
    color: var(--muted);
}

.device-label strong {
    font-family: "Barlow Condensed", sans-serif;
    font-size: 1.35rem;
}

.device-meter {
    height: 10px;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.07);
}

.device-meter span {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: var(--orange);
}

.device-total {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 30px;
    padding: 18px 0;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}

.device-total span {
    color: var(--muted);
}

.device-total strong {
    font-family: "Barlow Condensed", sans-serif;
    font-size: 1.6rem;
}


/* TOTAL STATISTICS */

.statistics-totals {
    margin-bottom: 22px;
}

.statistics-totals .stat-card small {
    display: block;
    margin-top: 6px;
    color: var(--muted);
    font-size: 0.78rem;
}


/* SITEWIDE RECORD */

.statistics-record {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 40px;
    padding: 32px;
    margin-bottom: 20px;
}

.statistics-record h2 {
    margin: 6px 0 10px;
}

.statistics-record p {
    max-width: 650px;
    margin: 0;
    color: var(--muted);
}

.record-tile {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 150px;
    aspect-ratio: 1;
    border-radius: 18px;
    background: var(--orange);
    color: var(--orange-dark);
    font-family: "Barlow Condensed", sans-serif;
    font-size: 2.25rem;
    font-weight: 800;
    letter-spacing: -0.04em;
    box-shadow:
        inset 0 0 0 1px rgba(255, 255, 255, 0.18),
        0 18px 40px rgba(0, 0, 0, 0.2);
}


/* RESPONSIVE */

@media (max-width: 980px) {

    .statistics-hero {
        grid-template-columns: 1fr;
    }

    .statistics-grid {
        grid-template-columns: 1fr;
    }

    .country-breakdown {
        grid-template-columns: 1fr;
    }

    .country-chart {
        width: 220px;
    }

}


@media (max-width: 650px) {

    .statistic-feature,
    .statistics-panel {
        padding: 22px;
    }

    .statistics-record {
        grid-template-columns: 1fr;
        padding: 24px;
    }

    .record-tile {
        width: 120px;
    }

    .country-chart {
        width: 190px;
    }

}

.form-error {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 0 0 20px;
    padding: 13px 15px;
    border: 1px solid rgba(255, 120, 120, 0.35);
    border-radius: 10px;
    background: rgba(255, 90, 90, 0.08);
    font-size: 0.9rem;
    line-height: 1.45;
}

.form-error .icon {
    flex: 0 0 auto;
    width: 19px;
    height: 19px;
    margin-top: 1px;
}

.leader-toggle {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
    margin: 16px 0 18px;
    padding: 4px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.025);
}

.leader-toggle a {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 36px;
    padding: 7px 10px;
    border-radius: 7px;
    color: var(--muted);
    font-family: "Barlow Condensed", sans-serif;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-decoration: none;
    text-transform: uppercase;
    transition:
        background 0.15s ease,
        color 0.15s ease;
}

.leader-toggle a:hover {
    color: var(--white);
}

.leader-toggle a.active {
    background: var(--orange);
    color: var(--orange-dark);
}

.leaderboard-table .numeric-column {
    text-align: center;
}


/* =========================================================
   FRONT PAGE ANIMATED 2048 HERO
   ========================================================= */

.front-hero {
    position: relative;
    overflow: hidden;
}


/* ---------------------------------------------------------
   CLICKABLE BOARD
   --------------------------------------------------------- */

.front-hero-board-link {
    position: relative;
    display: block;
    color: inherit;
    text-decoration: none;
    outline: none;
}

.front-hero-board-link:focus-visible {
    outline: 2px solid var(--orange);
    outline-offset: 6px;
}


/* ---------------------------------------------------------
   BOARD
   --------------------------------------------------------- */

.front-demo-board {
    --demo-gap: 10px;
    --demo-padding: 10px;

    position: relative;

    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    grid-template-rows: repeat(4, minmax(0, 1fr));

    gap: var(--demo-gap);

    width: 100%;
    aspect-ratio: 1;

    padding: var(--demo-padding);

    overflow: hidden;

    isolation: isolate;

    border-radius: 16px;

    background: rgba(8, 13, 20, 0.62);

    transition:
        opacity 480ms ease,
        filter 250ms ease;
}


/* ---------------------------------------------------------
   BACKGROUND CELLS
   --------------------------------------------------------- */

.front-demo-cell {
    min-width: 0;
    min-height: 0;

    border-radius: 10px;

    background: rgba(255, 255, 255, 0.055);

    box-shadow:
        inset 0 0 0 1px
        rgba(255, 255, 255, 0.025);
}


/* ---------------------------------------------------------
   TILE LAYER
   --------------------------------------------------------- */

.front-demo-tiles {
    position: absolute;

    inset: var(--demo-padding);

    z-index: 2;

    pointer-events: none;
}


/* ---------------------------------------------------------
   TILES
   --------------------------------------------------------- */

.front-demo-tile {
    position: absolute;

    top: 0;
    left: 0;

    width: calc(
        (100% - 3 * var(--demo-gap)) / 4
    );

    height: calc(
        (100% - 3 * var(--demo-gap)) / 4
    );

    display: flex;
    align-items: center;
    justify-content: center;

    margin: 0;

    transform-origin: center center;

    transition:
        transform 340ms cubic-bezier(0.22, 0.8, 0.3, 1),
        opacity 240ms ease,
        filter 240ms ease;

    will-change: transform, opacity;
}


/* ---------------------------------------------------------
   MERGE ANIMATION
   --------------------------------------------------------- */

.front-demo-tile.is-merge {
    animation:
        frontDemoMerge
        280ms
        ease-out;
}

@keyframes frontDemoMerge {

    0% {
        scale: 1;
        filter: brightness(1);
    }

    40% {
        scale: 1.13;
        filter: brightness(1.28);
    }

    75% {
        scale: 0.98;
    }

    100% {
        scale: 1;
        filter: brightness(1);
    }

}


/* ---------------------------------------------------------
   HIGH-VALUE MERGE GLOW
   --------------------------------------------------------- */

.front-demo-tile.tile-256.is-merge,
.front-demo-tile.tile-512.is-merge,
.front-demo-tile.tile-1024.is-merge,
.front-demo-tile.tile-2048.is-merge {
    animation:
        frontDemoBigMerge
        280ms
        ease-out;
}

@keyframes frontDemoBigMerge {

    0% {
        scale: 1;
        filter: brightness(1);
        box-shadow: none;
    }

    40% {
        scale: 1.15;
        filter: brightness(1.4);

        box-shadow:
            0 0 0 2px rgba(255, 255, 255, 0.18),
            0 0 35px rgba(255, 179, 108, 0.45);
    }

    100% {
        scale: 1;
        filter: brightness(1);
        box-shadow: none;
    }

}


/* ---------------------------------------------------------
   CLEAR OTHER TILES
   --------------------------------------------------------- */

.front-demo-board.is-clearing
.front-demo-tile:not(.is-winner) {
    opacity: 0;

    scale: 0.4;

    filter: blur(5px);

    pointer-events: none;
}


/* ---------------------------------------------------------
   WINNING TILE
   --------------------------------------------------------- */

.front-demo-tile.is-winner {
    z-index: 10;

    filter:
        brightness(1.15)
        drop-shadow(0 0 18px rgba(255, 179, 108, 0.35));
}


/* ---------------------------------------------------------
   MOVE THE WINNER TO CENTRE
   --------------------------------------------------------- */

.front-demo-tile.is-centred {
    z-index: 20;

    transition:
        transform 450ms cubic-bezier(0.16, 1, 0.3, 1),
        opacity 520ms ease,
        filter 520ms ease;
}


/* ---------------------------------------------------------
   EXPLOSION
   --------------------------------------------------------- */

.front-demo-tile.is-exploding {
    opacity: 0;

    filter:
        brightness(2)
        blur(7px);

    transition:
        transform 520ms cubic-bezier(0.2, 0.8, 0.2, 1),
        opacity 520ms ease,
        filter 520ms ease;
}


/* ---------------------------------------------------------
   EXPLOSION BURST
   --------------------------------------------------------- */

.front-demo-burst {
    position: absolute;

    top: 50%;
    left: 50%;

    z-index: 15;

    width: 45%;
    aspect-ratio: 1;

    border-radius: 50%;

    pointer-events: none;

    opacity: 0;

    transform:
        translate(-50%, -50%)
        scale(0.15);

    background:
        radial-gradient(
            circle,
            rgba(255, 255, 255, 1) 0%,
            rgba(255, 226, 154, 0.95) 14%,
            rgba(255, 179, 108, 0.7) 32%,
            rgba(255, 179, 108, 0.18) 60%,
            transparent 75%
        );
}


/*
 * The burst starts when the JS adds is-exploding
 * to the board.
 */

.front-demo-board.is-exploding
.front-demo-burst {
    animation:
        frontDemoExplosion
        520ms
        ease-out
        forwards;
}


@keyframes frontDemoExplosion {

    0% {
        opacity: 0.9;

        transform:
            translate(-50%, -50%)
            scale(0.15);
    }

    35% {
        opacity: 1;

        transform:
            translate(-50%, -50%)
            scale(1.5);
    }

    100% {
        opacity: 0;

        transform:
            translate(-50%, -50%)
            scale(4);
    }

}


/* ---------------------------------------------------------
   BOARD FLASH
   --------------------------------------------------------- */

.front-demo-board.is-exploding {
    animation:
        frontDemoBoardFlash
        520ms
        ease-out;
}


@keyframes frontDemoBoardFlash {

    0% {
        filter: brightness(1);
    }

    25% {
        filter: brightness(1.8);
    }

    100% {
        filter: brightness(1);
    }

}


/* ---------------------------------------------------------
   RESET
   --------------------------------------------------------- */

.front-demo-board.is-resetting {
    opacity: 0;
}


/* ---------------------------------------------------------
   PLAY OVERLAY
   --------------------------------------------------------- */

.front-hero-overlay {
    position: absolute;

    inset: 0;

    z-index: 30;

    display: flex;
    align-items: center;
    justify-content: center;

    gap: 10px;

    opacity: 0;

    border-radius: 16px;

    background: rgba(16, 23, 33, 0.46);

    backdrop-filter: blur(1.5px);

    color: var(--white);

    font-family:
        "Barlow Condensed",
        sans-serif;

    font-size: 1rem;
    font-weight: 700;

    letter-spacing: 0.08em;
    text-transform: uppercase;

    transition: opacity 200ms ease;
}

.front-hero-overlay .icon {
    width: 18px;
    height: 18px;
}

.front-hero-board-link:hover
.front-hero-overlay,
.front-hero-board-link:focus-visible
.front-hero-overlay {
    opacity: 1;
}


/* ---------------------------------------------------------
   CAPTION
   --------------------------------------------------------- */

.front-hero-caption {
    margin: 14px 0 0;

    text-align: center;

    font-family:
        "Barlow Condensed",
        sans-serif;

    font-size: 0.8rem;
    font-weight: 600;

    letter-spacing: 0.12em;
    text-transform: uppercase;

    color: var(--muted);
}


/* ---------------------------------------------------------
   MOBILE
   --------------------------------------------------------- */

@media (max-width: 650px) {

    .front-demo-board {
        --demo-gap: 7px;
        --demo-padding: 7px;
    }

    .front-hero-overlay {
        opacity: 1;

        align-items: flex-end;

        padding-bottom: 18px;

        background:
            linear-gradient(
                to top,
                rgba(16, 23, 33, 0.72),
                rgba(16, 23, 33, 0) 45%
            );

        backdrop-filter: none;
    }

}

/* ---------------------------------------------------------
   SPAWN ANIMATION
   --------------------------------------------------------- */

.front-demo-tile.is-spawn {
    animation:
        frontDemoSpawn
        180ms
        ease-out;
}

@keyframes frontDemoSpawn {

    0% {
        opacity: 0;
        scale: 0.35;
        filter: brightness(1.2);
    }

    65% {
        opacity: 1;
        scale: 1.08;
        filter: brightness(1.35);
    }

    100% {
        opacity: 1;
        scale: 1;
        filter: brightness(1);
    }

}


/* ---------------------------------------------------------
   REDUCED MOTION
   --------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {

    .front-demo-tile,
    .front-demo-board,
    .front-demo-burst {
        animation: none !important;
        transition: none !important;
    }

}


/* =========================================================
   ACCOUNT SETTINGS
   ========================================================= */

.settings-panel {
    overflow: hidden;
}

/* Wider page: remove the old .narrow wrapper and any fixed form-panel cap. */
.wrap.page-section.settings-page {
    width: min(100% - 32px, 1180px);
    max-width: 1180px;
    margin-inline: auto;
    box-sizing: border-box;
}
.settings-page .settings-panel {
    width: 100%;
    max-width: none;
    min-width: 0;
    box-sizing: border-box;
    padding: clamp(20px, 3vw, 42px);
}
.settings-page .settings-panel form {
    display: block;
    width: 100%;
    max-width: none;
    min-width: 0;
}
.settings-page .settings-section { width: 100%; min-width: 0; }

/* Active, owned avatar selection. Four across on desktop. */
.settings-page .settings-avatar-selection {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
    padding: 0;
    margin: 24px 0;
    min-width: 0;
    border: 0;
}
.settings-page .settings-avatar-selection legend {
    margin-bottom: 15px;
    padding: 0;
    font-weight: 700;
}
.settings-page .settings-avatar-option {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    min-width: 0;
    text-align: center;
    cursor: pointer;
}
.settings-page .settings-avatar-option input[type="radio"] {
    position: absolute;
    top: 10px;
    left: 10px;
    width: 1px;
    height: 1px;
    opacity: 0;
}
.settings-page .settings-avatar-image {
    display: block;
    width: 100%;
    aspect-ratio: 1 / 1;
    box-sizing: border-box;
    overflow: hidden;
    padding: 5px;
    border-radius: 16px;
    border: 3px solid transparent;
    background: #334359;
    transition: border-color .15s ease, background .15s ease;
}
.settings-page .settings-avatar-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 10px;
}
.settings-page .settings-avatar-option small {
    display: block;
    max-width: 100%;
    line-height: 1.4;
    color: var(--muted);
    overflow-wrap: anywhere;
}
.settings-page .settings-avatar-option input:checked + .settings-avatar-image {
    border-color: var(--orange, #ffb36c);
    background: #4b4034;
    box-shadow: 0 0 0 2px rgba(255,179,108,.2);
}
.settings-page .settings-avatar-option input:checked ~ small {
    font-weight: 700;
    color: var(--orange, #ffb36c);
}
.settings-page .settings-avatar-option input:focus-visible + .settings-avatar-image {
    outline: 3px solid var(--orange, #ffb36c);
    outline-offset: 3px;
}
@media (max-width: 700px) {
    .wrap.page-section.settings-page { width: min(100% - 24px, 1180px); }
    .settings-page .settings-avatar-selection {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 12px;
    }
}
@media (prefers-reduced-motion: reduce) {
    .settings-page .settings-avatar-image { transition: none; }
}



/* ---------------------------------------------------------
   SECTIONS
   --------------------------------------------------------- */

.settings-section {
    padding: 0 0 32px;
    margin: 0 0 32px;

    border-bottom: 1px solid var(--line);
}

.settings-section:last-of-type {
    border-bottom: 0;
    margin-bottom: 0;
}

.settings-section-heading {
    display: flex;
    align-items: flex-start;
    gap: 14px;

    margin-bottom: 25px;
}

.settings-section-heading h2 {
    margin: 0 0 5px;

    font-family:
        "Barlow Condensed",
        sans-serif;

    font-size: 1.4rem;
    font-weight: 700;

    color: var(--white);
}

.settings-section-heading p {
    margin: 0;

    font-size: 0.88rem;
    line-height: 1.5;

    color: var(--muted);
}

.settings-section-icon {
    flex: 0 0 44px;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 44px;
    height: 44px;

    border: 1px solid var(--line);
    border-radius: 12px;

    background: rgba(255, 179, 108, 0.07);

    color: var(--orange);
}

.settings-section-icon .icon {
    width: 21px;
    height: 21px;
}


/* ---------------------------------------------------------
   FIELDS
   --------------------------------------------------------- */

.settings-panel .field {
    display: flex;
    flex-direction: column;
    align-items: stretch;

    gap: 8px;

    margin-bottom: 22px;
}

.settings-panel .field:last-child {
    margin-bottom: 0;
}

.settings-panel .field input,
.settings-panel .field textarea,
.settings-panel .field select {
    width: 100%;
    max-width: 100%;

    box-sizing: border-box;
}

.settings-panel .field textarea {
    min-height: 112px;
    resize: vertical;
}

.settings-panel .field small {
    display: block;

    font-size: 0.78rem;
    font-weight: 400;
    line-height: 1.55;

    color: var(--muted);
}

.settings-panel .field input[readonly] {
    opacity: 0.7;
    cursor: not-allowed;
}

.settings-panel .field select {
    min-height: 46px;

    padding: 11px 14px;

    border: 1px solid var(--line);
    border-radius: 9px;

    background: var(--panel-light);
    color: var(--white);

    font: inherit;
}

.settings-panel .field select:focus-visible {
    outline: 2px solid var(--orange);
    outline-offset: 2px;
}

.settings-country-input {
    text-transform: uppercase;
}


/* ---------------------------------------------------------
   TOGGLE ROWS
   --------------------------------------------------------- */

.settings-toggle-row {
    position: relative;

    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 20px;

    min-height: 72px;

    padding: 15px 0;

    cursor: pointer;

    border-bottom: 1px solid var(--line);
}

.settings-toggle-row:last-child {
    border-bottom: 0;
}

.settings-toggle-copy {
    display: flex;
    flex-direction: column;

    gap: 5px;

    flex: 1;
    min-width: 0;
}

.settings-toggle-copy strong {
    font-size: 0.95rem;
    font-weight: 600;

    color: var(--white);
}

.settings-toggle-copy small {
    max-width: 440px;

    font-size: 0.78rem;
    line-height: 1.5;

    color: var(--muted);
}


/* ---------------------------------------------------------
   VISUALLY HIDDEN CHECKBOX
   --------------------------------------------------------- */

.settings-toggle-row input[type="checkbox"] {
    position: absolute;

    right: 0;
    top: 50%;

    width: 46px;
    height: 26px;

    margin: 0;

    transform: translateY(-50%);

    opacity: 0;

    cursor: pointer;

    z-index: 2;
}


/* ---------------------------------------------------------
   SWITCH
   --------------------------------------------------------- */

.settings-switch {
    position: relative;

    flex: 0 0 46px;

    width: 46px;
    height: 26px;

    border: 1px solid var(--line);
    border-radius: 999px;

    background: #384455;

    transition:
        background 180ms ease,
        border-color 180ms ease;
}

.settings-switch::after {
    content: "";

    position: absolute;

    top: 3px;
    left: 3px;

    width: 18px;
    height: 18px;

    border-radius: 50%;

    background: #dce3ec;

    box-shadow:
        0 1px 3px rgba(0, 0, 0, 0.25);

    transition:
        transform 180ms ease,
        background 180ms ease;
}


/* ---------------------------------------------------------
   CHECKED SWITCH
   --------------------------------------------------------- */

.settings-toggle-row input:checked
+ .settings-switch {
    background: var(--orange);
    border-color: var(--orange);
}

.settings-toggle-row input:checked
+ .settings-switch::after {
    transform: translateX(20px);

    background: var(--orange-dark);
}


/* ---------------------------------------------------------
   KEYBOARD FOCUS
   --------------------------------------------------------- */

.settings-toggle-row input:focus-visible
+ .settings-switch {
    outline: 2px solid var(--orange);
    outline-offset: 4px;
}


/* ---------------------------------------------------------
   DISABLED SETTINGS
   --------------------------------------------------------- */

.settings-toggle-row.settings-disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.settings-toggle-row.settings-disabled input {
    cursor: not-allowed;
}


/* ---------------------------------------------------------
   SAVE ROW
   --------------------------------------------------------- */

.settings-save-row {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 24px;

    padding-top: 5px;
}

.settings-save-row > div {
    display: flex;
    flex-direction: column;

    gap: 5px;
}

.settings-save-row strong {
    font-size: 0.95rem;
    color: var(--white);
}

.settings-save-row small {
    font-size: 0.8rem;
    line-height: 1.5;

    color: var(--muted);
}

.settings-save-row .button {
    flex-shrink: 0;
}


/* ---------------------------------------------------------
   SUCCESS AND ERROR MESSAGES
   --------------------------------------------------------- */

.settings-message {
    margin-bottom: 22px;
    padding: 18px 22px;

    font-size: 0.9rem;
    line-height: 1.6;
}

.settings-success {
    border: 1px solid rgba(154, 215, 197, 0.45);

    background: rgba(154, 215, 197, 0.08);

    color: var(--mint);
}

.settings-error {
    border: 1px solid rgba(255, 130, 130, 0.45);

    background: rgba(255, 130, 130, 0.08);

    color: #ffb0b0;
}

.settings-error strong {
    color: #ffd1d1;
}

.settings-error ul {
    margin: 10px 0 0;
    padding-left: 20px;
}

.settings-error li + li {
    margin-top: 4px;
}


/* ---------------------------------------------------------
   MOBILE
   --------------------------------------------------------- */

@media (max-width: 650px) {

    .settings-section-heading {
        gap: 12px;
    }

    .settings-section-heading h2 {
        font-size: 1.25rem;
    }

    .settings-section-icon {
        flex-basis: 38px;

        width: 38px;
        height: 38px;
    }

    .settings-toggle-row {
        gap: 14px;
    }

    .settings-save-row {
        flex-direction: column;
        align-items: stretch;
    }

    .settings-save-row .button {
        width: 100%;
        justify-content: center;
    }

}


/* ---------------------------------------------------------
   REDUCED MOTION
   --------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {

    .settings-switch,
    .settings-switch::after {
        transition: none;
    }

}


/* =========================================================
   STATISTICS — TILE MERGE BREAKDOWN
   ========================================================= */

.merge-statistics {
    margin-top: 24px;
}

.merge-intro {
    margin: 0 0 24px;

    max-width: 680px;

    font-size: 0.92rem;
    line-height: 1.65;

    color: var(--muted);
}


/* ---------------------------------------------------------
   TILE GRID
   --------------------------------------------------------- */

.merge-grid {
    display: grid;

    grid-template-columns:
        repeat(5, minmax(0, 1fr));

    gap: 12px;

    margin: 0 0 22px;
}


/* ---------------------------------------------------------
   INDIVIDUAL TILE CARD
   --------------------------------------------------------- */

.merge-card {
    display: flex;
    flex-direction: column;
    align-items: center;

    gap: 7px;

    min-width: 0;

    padding: 15px 8px;

    border: 1px solid var(--line);
    border-radius: 12px;

    background:
        rgba(255, 255, 255, 0.025);

    text-align: center;
}


/* ---------------------------------------------------------
   TILE VALUE
   --------------------------------------------------------- */

.merge-card-tile {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 68px;
    height: 68px;

    max-width: 100%;

    margin-bottom: 5px;

    border-radius: 9px;

    font-family:
        "Barlow Condensed",
        sans-serif;

    font-size: 1.35rem;
    font-weight: 800;

    letter-spacing: -0.02em;
    line-height: 1;
}


/* ---------------------------------------------------------
   COUNT
   --------------------------------------------------------- */

.merge-card strong {
    max-width: 100%;

    overflow-wrap: anywhere;

    font-family:
        "Barlow Condensed",
        sans-serif;

    font-size: 1.45rem;
    font-weight: 700;

    line-height: 1.15;

    color: var(--white);
}


/* ---------------------------------------------------------
   LABEL
   --------------------------------------------------------- */

.merge-card small {
    font-size: 0.72rem;

    line-height: 1.3;

    color: var(--muted);
}


/* ---------------------------------------------------------
   TABLET
   --------------------------------------------------------- */

@media (max-width: 900px) {

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

}


/* ---------------------------------------------------------
   MOBILE
   --------------------------------------------------------- */

@media (max-width: 650px) {

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

        gap: 10px;
    }

    .merge-card {
        padding: 13px 8px;
    }

    .merge-card-tile {
        width: 60px;
        height: 60px;

        font-size: 1.2rem;
    }

    .merge-card strong {
        font-size: 1.3rem;
    }

}

.avatar-selection label span img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: inherit;
}

.avatar-selection label {
    cursor: pointer;
}

/* Include AFTER the existing site styles. Scoped so the login layout is unchanged. */
.auth-layout.registration-layout {
    width: 100%;
    max-width: 1440px;
    box-sizing: border-box;
    grid-template-columns: minmax(260px, .75fr) minmax(0, 1.65fr);
    gap: clamp(28px, 4vw, 72px);
    align-items: start;
}
.registration-layout .registration-form-panel {
    min-width: 0;
    width: 100%;
    max-width: none;
    box-sizing: border-box;
    padding: clamp(22px, 3vw, 42px);
}
.registration-layout .avatar-selection {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin: 22px 0 30px;
    padding: 0;
    border: 0;
    min-width: 0;
}
.registration-layout .avatar-selection legend {
    padding: 0;
    margin-bottom: 14px;
    font-weight: 700;
}
.registration-layout .avatar-selection label {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 0;
    gap: 9px;
    cursor: pointer;
    text-align: center;
}
.registration-layout .avatar-selection label > input[type="radio"] {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}
.registration-layout .avatar-selection label > span {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    box-sizing: border-box;
    padding: 4px;
    border: 3px solid transparent;
    border-radius: 15px;
    background: #334359;
    transition: border-color .15s ease, transform .15s ease;
}
.registration-layout .avatar-selection label > span img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 9px;
}
.registration-layout .avatar-selection label > small {
    display: block;
    max-width: 100%;
    font-size: 13px;
    line-height: 1.35;
    overflow-wrap: anywhere;
    color: var(--muted);
}
.registration-layout .avatar-selection input:checked + span {
    border-color: var(--orange);
    background: #4b4034;
    box-shadow: 0 0 0 2px rgba(255,179,108,.18);
}
.registration-layout .avatar-selection input:focus-visible + span {
    outline: 3px solid var(--orange);
    outline-offset: 4px;
}
.registration-layout .avatar-selection input:checked ~ small {
    color: var(--orange);
    font-weight: 700;
}
.registration-layout .registration-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 20px;
}
.registration-layout .registration-fields .field { min-width: 0; }
.registration-layout .registration-fields .field--wide { grid-column: 1 / -1; }
.registration-layout .registration-errors {
    padding: 15px 18px;
    border: 1px solid #ff8a8a;
    border-radius: 10px;
    color: #ffd1d1;
    margin: 15px 0;
    line-height: 1.5;
}
.registration-layout .registration-errors ul { margin-bottom: 0; padding-left: 19px; }
.registration-layout .registration-consent { margin: 16px 0; }
.registration-layout .registration-consent input { flex: 0 0 auto; }
.registration-layout .registration-honeypot { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
@media (max-width: 1080px) {
    .auth-layout.registration-layout { grid-template-columns: 1fr; gap: 26px; }
    .registration-layout .auth-story { padding-top: 0; }
    .registration-layout .registration-form-panel { max-width: 850px; margin-inline: auto; }
}
@media (max-width: 650px) {
    .registration-layout .registration-form-panel { max-width: none; }
    .registration-layout .avatar-selection { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
    .registration-layout .registration-fields { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
    .registration-layout .avatar-selection label > span { transition: none; }
}
/* Play2048 achievement page — append to the END of /new-version/styles.css */
.pa-page { --pa-gold:#e9b75a; --pa-line:rgba(255,255,255,.13); --pa-muted:#aab9d0; }
.pa-page *, .pa-page *::before, .pa-page *::after { box-sizing:border-box; }
.pa-page .page-heading { margin-bottom:26px; }
.pa-page .page-heading p { max-width:740px; }
.pa-hero { display:grid; grid-template-columns:minmax(0,1fr) 200px; align-items:center; gap:24px; padding:clamp(24px,4vw,44px); overflow:hidden; position:relative; background:linear-gradient(110deg,#18294b 0%,#213b62 56%,#51402d 100%); border:1px solid rgba(233,183,90,.3); }
.pa-hero::after { content:""; position:absolute; width:260px; height:260px; border-radius:50%; right:-95px; top:-125px; background:rgba(233,183,90,.10); pointer-events:none; }
.pa-hero-copy { position:relative; z-index:1; }
.pa-kicker { display:inline-block; color:#f2cb82; letter-spacing:.17em; font-size:.72rem; font-weight:800; margin-bottom:12px; }
.pa-hero h2 { font-size:clamp(1.65rem,3vw,2.5rem); line-height:1.12; margin:0 0 12px; color:#fff; }
.pa-hero p { max-width:590px; line-height:1.7; color:#d6e2f1; margin:0 0 20px; }
.pa-hero-actions { display:flex; flex-wrap:wrap; gap:10px; }
.pa-hero-emblem { justify-self:center; width:170px; height:170px; display:flex; flex-direction:column; align-items:center; justify-content:center; border-radius:32px; background:linear-gradient(145deg,#fbe4a9,#d59b35); transform:rotate(7deg); box-shadow:0 19px 48px rgba(0,0,0,.27),inset 0 3px 2px rgba(255,255,255,.45); color:#382819; }
.pa-hero-emblem span { font-weight:950; letter-spacing:-.065em; font-size:3.25rem; }
.pa-hero-emblem small { font-size:.62rem; font-weight:900; letter-spacing:.16em; }
.pa-summary { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:14px; margin:18px 0 40px; }
.pa-summary-card { padding:19px; min-width:0; display:flex; flex-direction:column; gap:10px; }
.pa-summary-card>span { color:var(--pa-muted); font-size:.83rem; font-weight:650; }
.pa-summary-card strong { display:block; font-size:clamp(1.55rem,2.8vw,2.2rem); line-height:1.15; font-variant-numeric:tabular-nums; }
.pa-summary-card strong small { font-size:.9rem; font-weight:500; color:var(--pa-muted); }
.pa-summary-card>small { font-size:.78rem; color:var(--pa-muted); }
.pa-meter { height:8px; background:rgba(127,147,177,.25); border-radius:100px; overflow:hidden; }
.pa-meter>span { display:block; height:100%; border-radius:inherit; background:linear-gradient(90deg,#e5aa48,#f3d893); }
.pa-guest-note { display:flex; gap:12px; align-items:center; padding:17px 20px; margin:18px 0 38px; }
.pa-guest-note>span { font-size:1.65rem; color:var(--pa-gold); }
.pa-guest-note p { margin:0; line-height:1.6; }
.pa-section-heading { display:flex; align-items:end; justify-content:space-between; flex-wrap:wrap; gap:16px; margin-bottom:17px; }
.pa-section-heading h2 { margin:5px 0 0; font-size:clamp(1.35rem,2.5vw,1.9rem); }
.pa-result-count { color:var(--pa-muted); font-size:.82rem; font-weight:700; }
.pa-category-tabs, .pa-status-tabs { display:flex; align-items:center; flex-wrap:wrap; gap:8px; margin-bottom:14px; }
.pa-category-tabs>a, .pa-status-tabs>a { display:inline-flex; align-items:center; gap:7px; color:inherit; text-decoration:none; padding:10px 13px; border:1px solid var(--pa-line); background:rgba(105,129,169,.08); border-radius:12px; font-size:.86rem; font-weight:650; transition:background .15s,border-color .15s; }
.pa-category-tabs>a:hover, .pa-status-tabs>a:hover { background:rgba(233,183,90,.13); border-color:rgba(233,183,90,.5); }
.pa-category-tabs>a.is-selected, .pa-status-tabs>a.is-selected { background:rgba(233,183,90,.17); border-color:#caa05c; color:inherit; }
.pa-category-tabs>a span { color:#e9b75a; font-size:1rem; }
.pa-status-tabs { padding-bottom:10px; margin-bottom:15px; }
.pa-status-tabs>a { padding:7px 13px; font-size:.79rem; }
.pa-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:16px; margin-bottom:28px; }
.pa-card { position:relative; min-width:0; display:flex; flex-direction:column; padding:22px; overflow:hidden; border:1px solid var(--pa-line); }
.pa-card-earned { border-color:rgba(233,183,90,.38); }
.pa-card-locked { opacity:.9; }
.pa-card-head { display:flex; align-items:start; justify-content:space-between; gap:8px; margin-bottom:16px; }
.pa-card-symbol { display:grid; place-items:center; width:58px; height:58px; font-size:1.8rem; border-radius:17px; background:rgba(233,183,90,.16); border:1px solid rgba(233,183,90,.24); color:#f3c873; }
.pa-cat-consistency .pa-card-symbol { background:rgba(77,152,208,.15); border-color:rgba(77,152,208,.28); color:#85c9ed; }
.pa-cat-persistence .pa-card-symbol { background:rgba(153,111,216,.15); border-color:rgba(153,111,216,.25); color:#d4b5ff; }
.pa-cat-score .pa-card-symbol { background:rgba(55,183,140,.14); border-color:rgba(55,183,140,.25); color:#75e3b9; }
.pa-cat-merges .pa-card-symbol { background:rgba(235,132,86,.15); border-color:rgba(235,132,86,.25); color:#ffb68b; }
.pa-card-state { white-space:nowrap; padding:6px 8px; border:1px solid var(--pa-line); border-radius:100px; color:var(--pa-muted); font-size:.7rem; font-weight:800; }
.pa-card-state.pa-state-earned { color:#f2d392; border-color:rgba(233,183,90,.4); background:rgba(233,183,90,.1); }
.pa-card-body { flex:1; }
.pa-card-category { color:var(--pa-gold); text-transform:uppercase; letter-spacing:.12em; font-size:.65rem; font-weight:800; }
.pa-card-body h3 { margin:7px 0 10px; font-size:1.25rem; line-height:1.2; }
.pa-card-body p { margin:0 0 23px; color:var(--pa-muted); line-height:1.55; font-size:.87rem; }
.pa-card-progress { border-top:1px solid var(--pa-line); padding-top:15px; }
.pa-card-count { display:flex; align-items:baseline; justify-content:space-between; gap:8px; margin-bottom:12px; }
.pa-card-count>span { color:var(--pa-muted); font-size:.76rem; }
.pa-card-count>strong { font-variant-numeric:tabular-nums; font-size:1.35rem; }
.pa-progress-label { display:flex; justify-content:space-between; gap:10px; align-items:baseline; margin-bottom:8px; color:var(--pa-muted); font-size:.72rem; }
.pa-progress-label>strong { white-space:nowrap; font-size:.75rem; color:inherit; font-variant-numeric:tabular-nums; }
.pa-card-progress>.pa-meter { height:7px; }
.pa-complete-note { font-size:.79rem; font-weight:750; color:#edc776; margin:8px 0; }
.pa-tier-list { display:flex; flex-wrap:wrap; gap:6px; margin-top:15px; }
.pa-tier { border:1px solid var(--pa-line); background:rgba(127,147,177,.08); border-radius:8px; font-size:.69rem; padding:6px 8px; color:var(--pa-muted); }
.pa-tier-earned { color:#f5d48b; background:rgba(233,183,90,.12); border-color:rgba(233,183,90,.4); }
.pa-card-footer { font-size:.72rem; color:var(--pa-muted); margin-top:17px; padding-top:12px; border-top:1px solid var(--pa-line); }
.pa-card-guest { margin-top:auto; }
.pa-empty,.pa-message { padding:28px; margin:20px 0; }
.pa-empty h3,.pa-message h2 { margin-top:0; }
.pa-info { padding:24px; display:flex; align-items:start; gap:16px; margin:18px 0 28px; }
.pa-info-icon { display:grid; place-items:center; flex:0 0 42px; height:42px; border-radius:12px; color:#f2c777; background:rgba(233,183,90,.12); font-size:1.4rem; }
.pa-info h2 { margin:0 0 8px; font-size:1.1rem; }
.pa-info p { margin:0 0 8px; line-height:1.6; color:var(--pa-muted); font-size:.85rem; }
.pa-info p:last-child { margin-bottom:0; }
@media (max-width:1080px) { .pa-grid { grid-template-columns:repeat(2,minmax(0,1fr)); } .pa-summary { grid-template-columns:repeat(2,minmax(0,1fr)); } }
@media (max-width:660px) { .pa-hero { grid-template-columns:1fr; } .pa-hero-emblem { display:none; } .pa-grid { grid-template-columns:1fr; } .pa-category-tabs { flex-wrap:nowrap; overflow-x:auto; padding-bottom:9px; scrollbar-width:thin; } .pa-category-tabs>a { white-space:nowrap; } .pa-info { padding:18px; } }
@media (max-width:390px) { .pa-summary { grid-template-columns:1fr; } .pa-card { padding:18px; } }
@media (prefers-reduced-motion:reduce) { .pa-page *, .pa-page *::before, .pa-page *::after { transition:none!important; } }


/* =========================================================
   PLAY2048 LIGHT THEME — 2026-10
   ========================================================= */
:root {
    color-scheme: light;
    --bg: #f6f3ec;
    --panel: #ffffff;
    --panel-light: #f0ece3;
    --line: #ddd6c9;
    --muted: #6f6a61;
    --white: #26221d;
    --orange: #e58a3a;
    --orange-dark: #fffaf4;
    --mint: #4fa995;
}

body { background:#f6f3ec; color:#26221d; }
body:before {
    background:
        radial-gradient(ellipse at 49% 28%, rgba(229,138,58,.11), transparent 52%),
        linear-gradient(115deg, transparent 60%, rgba(79,169,149,.025) 60%, rgba(79,169,149,.025) 75%, transparent 75%);
}

.header { background:rgba(255,253,248,.96); border-bottom-color:#ddd6c9; box-shadow:0 1px 0 rgba(56,45,31,.03); }
.header nav a { color:#716b62; }
.header nav a:hover,.header nav a[aria-current] { color:#26221d; }

.button { box-shadow:0 4px 12px rgba(133,79,29,.10); }
.button:hover { color:#2b1b0d; background:#f0a15c; }
.button.secondary { background:#fff; border-color:#d7cfc1; color:#2d2923; box-shadow:none; }
.button.secondary:hover { background:#f3eee5; border-color:#c8beae; }

.panel { background:#fff; border-color:#ddd6c9; box-shadow:0 9px 28px rgba(76,61,43,.045); }
.guest-avatar { background:#f0ece3; border-color:#d4ccbe; box-shadow:0 0 0 5px #faf8f3; }
.guest-avatar > .icon { color:#514b43; }
.guest-avatar > span { background:#e6dfd4; color:#4b453e; border-color:#fff; }
.guest-line strong { color:#3c3832; }

.challenge-card { background:linear-gradient(125deg,#fff7e9,#f4ede2 72%); border-color:#e3c89e; }
.challenge-card:after { color:rgba(201,130,53,.08); }
.challenge-card .eyebrow { color:#9a6a31; }
.challenge-card p { color:#746b60; }

.mode-pill { border-color:#d7d0c4; color:#5e5951; background:#f5f1e9; }
.scoreboard > div { background:#fff; border-color:#ddd6c9; }
.scoreboard > div:nth-child(2) { background:#fff8ee; border-color:#ead3b4; }
.scoreboard span { color:#746f67; }
.scoreboard > div:nth-child(2) strong { color:#a96022; }
.icon-button { background:#fff; border-color:#d8d0c3; color:#625d55; }
.icon-button:hover { background:#f1ece4; }
.board { box-shadow:0 18px 42px rgba(61,53,44,.12), inset 0 1px 0 rgba(255,255,255,.6); }
.controls-hint,kbd { color:#625d55; }

.leader-list li { border-color:#e2dcd1; }
.panel-link { border-color:#e2dcd1; }
.mini-milestones span { background:#f4f0e8; border-color:#dfd7ca; }
.lobby-bottom { border-color:#ddd6c9; }

.quick-links > a { background:#fff; border-color:#ddd6c9; box-shadow:0 8px 24px rgba(76,61,43,.035); }
.quick-links > a:hover { background:#fffaf4; border-color:#d9b990; }
.quick-links > a > .icon { color:#847c71; }
.quick-icon { background:#e9f5f1; color:#347e70; }
.quick-icon.amber { background:#fff0df; color:#a66428; }
.quick-icon.violet { background:#f1ebf7; color:#775b8b; }

.retained { border-top-color:#ddd6c9; }
.prose { color:#544f48; }
.prose h2,.prose h3,.prose h4,.reading-layout aside h2 { color:#26221d; }
.prose a,.reading-layout aside > a { color:#b86524; }
.prose hr { border-color:#dfd8cc; }
.prose blockquote { background:#fff; border-color:#dfd8cc; }

footer { background:#eee9df; border-top-color:#d7cfc2; }
.footer-top,.footer-bottom,.footer-links > div { border-color:#d8d0c3; }
.footer-links b { color:#39342e; }
.footer-links a,.footer-bottom { color:#6b655d; }

.page-heading h1 { color:#25211c; }
.page-heading > p { color:#6f6960; }

.podium-card { background:linear-gradient(145deg,#fff,#f5f0e7); border-color:#dcd4c7; box-shadow:0 12px 30px rgba(77,61,42,.055); }
.podium-card.place-0 { background:linear-gradient(145deg,#fff9ef,#f7ead5); border-color:#e5c58f; box-shadow:0 16px 35px rgba(145,91,34,.09); }
.podium-card h2,.podium-card strong { color:#29251f; }
.podium-card > span:last-child { color:#766f65; }
.rankings { background:#fff; }
.tabs button,.tabs a { border-color:#d8d1c5; background:#f6f2eb; color:#5e5951; }
.tabs button:hover,.tabs a:hover { background:#eee7dc; color:#27231e; }
.tabs button.selected,.tabs a.selected { background:#e58a3a; border-color:#e58a3a; color:#2a190b; }
.filter-row { border-color:#e2dcd2; }
table { color:#3c3832; }
th { background:#f4f0e8; color:#716b62; border-color:#ddd6c9; }
td { border-color:#e5dfd5; }
tbody tr:hover { background:#fcf8f2; }
.join-banner { background:linear-gradient(120deg,#fff7e9,#edf6f2); border-color:#ddd2c1; }

.auth-story h1,.auth-story h2 { color:#29251f; }
.auth-benefits { color:#625d55; }
.form-panel { background:#fff; }
.form-tabs { background:#f1ece4; border-color:#ddd5c9; }
.form-tabs a { color:#6c665e; }
.form-tabs a[aria-current] { background:#fff; color:#2c2822; box-shadow:0 2px 8px rgba(65,52,37,.07); }
.field { color:#454038; }
.field input,.field textarea,.field select { background:#fff; border-color:#cec6ba; color:#29251f; color-scheme:light; }
.field input::placeholder,.field textarea::placeholder { color:#9a9389; }
.checkbox { color:#6f6961; }
.avatar-selection span { background:#f3eee6; border-color:#d9d1c4; }
.avatar-selection input:checked + span { background:#fff4e7; border-color:#e58a3a; }
.form-error { background:#fff0ef; border-color:#e5aca7; color:#7c2f2a; }

.profile-banner { background:linear-gradient(135deg,#fff,#f3eee6); border-color:#dcd4c8; }
.stat-card { background:#fff; border-color:#ddd6c9; }
.chart { background:#faf7f1; }
.achievement-preview,.activity { background:#fff; }
.milestone-row { border-color:#e1dacf; }

.challenge-hero { background:linear-gradient(120deg,#fff6e6,#f1ece4); border-color:#e3ccaa; }
.challenge-hero p { color:#6b645b; }
.champion-emblem { box-shadow:0 15px 35px rgba(113,76,32,.13); }

.not-found { background:#fff; border-color:#ddd6c9; }

.statistic-icon { background:#f6f2eb; border-color:#ddd6c9; }
.statistics-legend > div { border-color:#e4ddd2; }
.country-chart::after { background:#fff; border-color:#ddd6c9; }
.device-meter { background:#e9e3da; }
.record-tile { box-shadow:inset 0 0 0 1px rgba(255,255,255,.4),0 15px 30px rgba(132,77,29,.14); }
.leader-toggle { background:#f0ebe3; border-color:#d8d0c3; }
.leader-toggle a { color:#6c665e; }
.leader-toggle a:hover { color:#2b2721; }

.settings-page .settings-panel { background:#fff; border-color:#ddd6c9; }
.settings-page .settings-avatar-image { background:#f4efe7; border-color:#d7cfc2; }
.settings-page .settings-avatar-option input:checked + .settings-avatar-image { border-color:#e58a3a; box-shadow:0 0 0 3px rgba(229,138,58,.13); }
.registration-layout .avatar-selection label > span { background:#f5f1ea; border-color:#d8d0c3; }
.registration-layout .avatar-selection input:checked + span { background:#fff5e8; border-color:#e58a3a; }

.pa-page { --pa-line:rgba(87,72,51,.16); --pa-muted:#716a60; }
.pa-hero { background:linear-gradient(110deg,#fff9ef 0%,#f4eee4 58%,#f8ecd8 100%); border-color:rgba(198,137,52,.36); }
.pa-hero::after { background:rgba(207,146,59,.12); }
.pa-kicker { color:#a96e1f; }
.pa-hero h2 { color:#2b261f; }
.pa-hero p { color:#665f56; }
.pa-summary-card,.pa-card,.pa-guest-note,.pa-info,.pa-empty,.pa-message { background:#fff; }
.pa-category-tabs>a,.pa-status-tabs>a,.pa-tier { background:rgba(141,111,70,.06); }
.pa-cat-consistency .pa-card-symbol { background:#edf5f3; border-color:#c8ddd7; color:#357d70; }
.pa-cat-persistence .pa-card-symbol { background:#f3eef7; border-color:#dfd1e9; color:#75558b; }
.pa-cat-score .pa-card-symbol { background:#eaf6ef; border-color:#c8e2d3; color:#337a58; }
.pa-cat-merges .pa-card-symbol { background:#fff0e8; border-color:#efd2c3; color:#aa5c36; }
