:root {
    --bg: linear-gradient(140deg, #f4efe2 0%, #d8f0e7 45%, #c8d9ff 100%);
    --bg-glow-1: rgba(12, 150, 115, 0.16);
    --bg-glow-2: rgba(66, 98, 232, 0.14);
    --panel: rgba(255, 255, 255, 0.76);
    --panel-strong: rgba(255, 255, 255, 0.94);
    --text: #1b2231;
    --muted: #5a6472;
    --accent: #14532d;
    --accent-strong: #0e3f22;
    --accent-soft: #d4f1df;
    --line: rgba(27, 34, 49, 0.14);
    --line-strong: rgba(27, 34, 49, 0.2);
    --shadow: 0 24px 60px rgba(27, 34, 49, 0.16);
    --font-body: "Sora", "Avenir Next", "Segoe UI", sans-serif;
    --font-display: "Fraunces", "Iowan Old Style", "Palatino Linotype", serif;
    --font-code: "IBM Plex Mono", "SFMono-Regular", "Consolas", monospace;
}

* {
    box-sizing: border-box;
}

*::before,
*::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
    font-family: var(--font-body);
    color: var(--text);
    background: var(--bg);
}

body::before,
body::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
}

body::before {
    background:
        radial-gradient(65vw 65vw at 8% 10%, var(--bg-glow-1), transparent 66%),
        radial-gradient(70vw 70vw at 90% 86%, var(--bg-glow-2), transparent 70%);
    z-index: 0;
}

body::after {
    background-image:
        repeating-linear-gradient(
            0deg,
            rgba(255, 255, 255, 0.14),
            rgba(255, 255, 255, 0.14) 1px,
            transparent 1px,
            transparent 4px
        );
    mix-blend-mode: soft-light;
    opacity: 0.45;
    z-index: 0;
}

button,
input {
    font: inherit;
}

button {
    border: 1px solid rgba(10, 62, 34, 0.1);
    border-radius: 999px;
    padding: 0.8rem 1.2rem;
    background: linear-gradient(180deg, #1f7a46 0%, #14532d 100%);
    color: white;
    cursor: pointer;
    transition: transform 160ms ease, opacity 120ms ease, box-shadow 160ms ease, background 140ms ease;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.2),
        0 10px 18px rgba(20, 83, 45, 0.24);
}

button:hover {
    transform: translateY(-2px);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.25),
        0 14px 22px rgba(20, 83, 45, 0.28);
}

button:active {
    transform: translateY(0);
}

button:disabled {
    cursor: not-allowed;
    opacity: 0.5;
    transform: none;
    box-shadow: none;
}

input {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 0.9rem 1rem;
    background: rgba(255, 255, 255, 0.9);
    transition: border-color 140ms ease, box-shadow 140ms ease;
}

input:focus-visible,
button:focus-visible {
    outline: none;
    border-color: rgba(20, 83, 45, 0.48);
    box-shadow: 0 0 0 4px rgba(31, 122, 70, 0.18);
}

.ghost {
    background: rgba(255, 255, 255, 0.72);
    color: var(--text);
    border: 1px solid var(--line);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.ghost:hover {
    background: rgba(255, 255, 255, 0.94);
}

.hidden {
    display: none !important;
}

.shell {
    position: relative;
    z-index: 1;
    max-width: 1120px;
    margin: 0 auto;
    padding: 2rem 1rem 3rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.hero {
    padding: 0.75rem 0 0;
    max-width: 76ch;
}

h1,
h2,
h3 {
    margin: 0;
    line-height: 1.08;
    letter-spacing: -0.02em;
}

h2,
h3 {
    font-family: var(--font-display);
}

.hero h1 {
    max-width: 24ch;
    font-family: var(--font-display);
    font-size: clamp(2.1rem, 4.6vw, 3.6rem);
    line-height: 0.98;
    letter-spacing: -0.04em;
    text-wrap: balance;
    color: #172032;
    background: linear-gradient(130deg, #162437 0%, #14532d 52%, #2b4f8f 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.lede,
.eyebrow,
.message,
.card p,
#status-line,
#vote-feedback,
.mean-line {
    color: var(--muted);
}

.lede {
    max-width: 66ch;
    margin-top: 0.75rem;
}

.mean-line {
    margin: 0.35rem 0 0;
    font-weight: 700;
    color: #205238;
}

.countdown-line {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.45rem 0.8rem;
    border-radius: 999px;
    border: 1px solid rgba(20, 83, 45, 0.14);
    background: rgba(212, 241, 223, 0.7);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
    transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.countdown-line::before {
    content: "";
    width: 0.7rem;
    height: 0.7rem;
    border-radius: 999px;
    background: #1f7a46;
    box-shadow: 0 0 0 0 rgba(31, 122, 70, 0.45);
}

.countdown-line.is-live {
    color: #0e3f22;
    background:
        linear-gradient(135deg, rgba(212, 241, 223, 0.96) 0%, rgba(255, 246, 196, 0.92) 100%);
}

.countdown-line.is-ticking {
    transform: scale(1.03);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.84),
        0 0 0 5px rgba(245, 196, 82, 0.18),
        0 14px 32px rgba(31, 122, 70, 0.2);
}

.countdown-line.is-ticking::before {
    animation: countdown-blink 650ms ease;
}

.eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.2em;
    font-size: 0.72rem;
    margin-bottom: 0.75rem;
    font-weight: 700;
}

.panel {
    background: linear-gradient(160deg, rgba(255, 255, 255, 0.9) 0%, rgba(248, 252, 255, 0.72) 100%);
    border: 1px solid rgba(255, 255, 255, 0.64);
    border-radius: 32px;
    padding: 1.5rem;
    backdrop-filter: blur(16px);
    box-shadow:
        0 30px 70px rgba(27, 34, 49, 0.14),
        inset 0 1px 0 rgba(255, 255, 255, 0.84);
}

.shell.board-active .hero {
    order: 3;
    padding-top: 0;
}

.shell.board-active .hero h1 {
    max-width: 30ch;
    font-size: clamp(1.2rem, 2.1vw, 1.62rem);
    line-height: 1.05;
}

.shell.board-active .hero .lede {
    max-width: 70ch;
    margin-top: 0.5rem;
}

.language-picker {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
}

.lang-button {
    font-size: 0.85rem;
    padding: 0.4rem 0.8rem;
    background: rgba(255, 255, 255, 0.5);
    color: var(--text);
    border: 1px solid var(--line);
    box-shadow: none;
}

.lang-button:hover {
    background: rgba(255, 255, 255, 0.8);
}

.lang-button[aria-pressed="true"] {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
}

.view {
    animation: fade-in 220ms ease;
}

.stack {
    display: grid;
    gap: 0.85rem;
}

.section-head,
.action-row,
.share-actions,
.invite-head {
    display: flex;
    gap: 1rem;
    align-items: center;
    justify-content: space-between;
}

.card-picker-head {
    display: flex;
    gap: 1rem;
    align-items: flex-start;
    justify-content: space-between;
}

.card-picker-toggle {
    flex-shrink: 0;
    width: 2.8rem;
    height: 2.8rem;
}

.card-picker-panel[data-collapsed="true"] {
    align-self: start;
    min-height: 0;
    width: 3.5rem;
    padding: 0.35rem;
    border-radius: 22px;
    justify-self: end;
}

.card-picker-panel[data-collapsed="true"] .card-picker-head {
    flex-direction: row;
    align-items: center;
    justify-content: center;
    margin-bottom: 0;
}

.card-picker-panel[data-collapsed="true"] .card-picker-copy {
    display: none;
}

.board-grid[data-cards-collapsed="true"] {
    grid-template-columns: minmax(0, 1fr) auto;
}

.board-grid[data-cards-collapsed="true"] .card-picker-panel {
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.72),
        0 8px 18px rgba(27, 34, 49, 0.08);
}

.section-head.tight {
    align-items: flex-start;
}

.welcome-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.lobby-grid,
.board-grid {
    display: grid;
    gap: 1rem;
    margin-top: 1.5rem;
}

.lobby-grid {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.board-grid {
    grid-template-columns: 1.25fr 1fr;
    align-items: start;
}

.card {
    background: linear-gradient(155deg, rgba(255, 255, 255, 0.97) 0%, rgba(247, 251, 255, 0.9) 100%);
    border: 1px solid var(--line);
    border-radius: 28px;
    padding: 1.25rem;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.72),
        0 10px 24px rgba(27, 34, 49, 0.08);
    transition: transform 180ms ease, box-shadow 180ms ease;
}

.card:hover {
    transform: translateY(-3px);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.82),
        0 16px 30px rgba(27, 34, 49, 0.13);
}

.noscript-card {
    margin-top: 0.5rem;
}

.share {
    display: grid;
    gap: 1rem;
}

.share.hidden {
    display: none;
}

.pill {
    min-width: 120px;
    padding: 0.8rem 1rem;
    border-radius: 999px;
    background: linear-gradient(180deg, #ddf4e7 0%, #c8eed9 100%);
    color: var(--accent-strong);
    text-align: center;
    font-family: var(--font-code);
    font-weight: 700;
    letter-spacing: 0.16em;
    border: 1px solid rgba(20, 83, 45, 0.18);
}

.qr-block {
    display: grid;
    justify-items: center;
    gap: 0.65rem;
    padding-top: 0.25rem;
}

.share-qr {
    width: min(220px, 100%);
    aspect-ratio: 1;
    border-radius: 24px;
    border: 1px solid var(--line);
    background: white;
    padding: 0.9rem;
    object-fit: contain;
    box-shadow: 0 8px 18px rgba(27, 34, 49, 0.12);
}

.qr-caption {
    margin: 0;
    text-align: center;
}

.icon-button {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
}

.icon-only {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.6rem;
    height: 2.6rem;
    padding: 0;
    border-radius: 999px;
}

.board-menu {
    position: relative;
}

.board-menu-panel {
    position: absolute;
    top: calc(100% + 0.6rem);
    right: 0;
    min-width: 220px;
    display: grid;
    gap: 0.35rem;
    padding: 0.5rem;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: var(--panel-strong);
    box-shadow: var(--shadow);
    z-index: 10;
}

.board-menu-panel.hidden {
    display: none;
}

.menu-entry {
    width: 100%;
    text-align: left;
    background: transparent;
    color: var(--text);
    border-radius: 14px;
    padding: 0.85rem 1rem;
}

.menu-entry:hover {
    background: #f2f5f8;
}

.icon {
    width: 1.2rem;
    height: 1.2rem;
    fill: currentColor;
    flex: 0 0 auto;
}

.players-list {
    position: relative;
    min-height: clamp(560px, 72vh, 690px);
    padding: 10px;
    margin-top: 1rem;
    border-radius: 30px;
    border: 1px solid rgba(27, 34, 49, 0.1);
    background:
        radial-gradient(circle at 50% 24%, rgba(255, 255, 255, 0.38), transparent 44%),
        linear-gradient(180deg, #e9f6f0 0%, #d6ecdf 100%);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.56),
        inset 0 -18px 30px rgba(0, 0, 0, 0.06);
    overflow: visible;
}

.table-surface {
    position: absolute;
    inset: 18% 16%;
    border-radius: 32px;
    overflow: hidden;
    background:
        radial-gradient(circle at 52% 34%, rgba(255, 255, 255, 0.22), transparent 48%),
        linear-gradient(180deg, #2e7555 0%, #1e4f39 100%);
    border: 14px solid #825437;
    box-shadow:
        inset 0 4px 18px rgba(255, 255, 255, 0.12),
        inset 0 -12px 24px rgba(0, 0, 0, 0.22),
        0 18px 30px rgba(27, 34, 49, 0.14);
}

.table-surface::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        repeating-linear-gradient(
            45deg,
            rgba(255, 255, 255, 0.06),
            rgba(255, 255, 255, 0.06) 2px,
            transparent 2px,
            transparent 6px
        );
    opacity: 0.35;
}

.table-surface::after {
    content: "";
    position: absolute;
    inset: 12% 10%;
    border: 2px dashed rgba(255, 255, 255, 0.3);
    border-radius: 22px;
}

.table-label {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: rgba(255, 255, 255, 0.88);
}

.table-label strong,
.seat-name {
    display: block;
}

.table-label strong {
    font-family: var(--font-display);
    font-size: 1.45rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.table-label span {
    font-size: 0.84rem;
    letter-spacing: 0.11em;
    text-transform: uppercase;
}

.table-seat {
    position: absolute;
    width: 164px;
    transform: translate(-50%, -50%);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.players-list[data-animate-entry="true"] .table-seat {
    animation: seat-pop 260ms ease both;
}

.table-seat[data-has-voted="true"] .seat-info {
    border-color: rgba(20, 83, 45, 0.25);
    box-shadow: 0 9px 20px rgba(20, 83, 45, 0.16);
}

.table-seat[data-has-voted="true"] .seat-meta {
    color: #155633;
    font-weight: 700;
}

.table-seat[data-owner="true"] .seat-name {
    color: #114f30;
}

.table-seat.side-top,
.table-seat.side-bottom {
    flex-direction: column;
}

.table-seat.side-top .seat-card {
    order: 2;
}

.table-seat.side-top .seat-info {
    order: 1;
}

.table-seat.side-bottom .seat-card {
    order: 1;
}

.table-seat.side-bottom .seat-info {
    order: 2;
}

.table-seat.side-left {
    flex-direction: row;
}

.table-seat.side-left .seat-info {
    order: 1;
}

.table-seat.side-left .seat-card {
    order: 2;
}

.table-seat.side-right {
    flex-direction: row;
}

.table-seat.side-right .seat-card {
    order: 1;
}

.table-seat.side-right .seat-info {
    order: 2;
}

.seat-card {
    width: 68px;
    aspect-ratio: 3 / 4;
    display: grid;
    place-items: center;
    border-radius: 18px;
    border: 1px solid rgba(27, 34, 49, 0.12);
    background: linear-gradient(180deg, #ffffff 0%, #edf6f0 100%);
    box-shadow: 0 10px 20px rgba(27, 34, 49, 0.18);
    font-size: 1.1rem;
    font-weight: 800;
}

.table-seat[data-has-voted="true"] .seat-card {
    transform: translateY(-2px);
    box-shadow: 0 14px 24px rgba(27, 34, 49, 0.24);
}

.seat-card.hidden-vote {
    color: #f7fbff;
    text-shadow: 0 1px 2px rgba(7, 16, 32, 0.45);
    border-color: rgba(255, 255, 255, 0.34);
    background:
        radial-gradient(circle at 22% 16%, rgba(240, 255, 244, 0.3) 0 18%, transparent 19%),
        repeating-linear-gradient(45deg, rgba(209, 248, 226, 0.22) 0 4px, transparent 4px 10px),
        linear-gradient(165deg, #1f7a46 0%, #14532d 100%);
}

.seat-card.hidden-vote[data-back-pattern="0"] {
    background:
        radial-gradient(circle at 72% 18%, rgba(255, 255, 255, 0.34) 0 18%, transparent 19%),
        repeating-linear-gradient(-45deg, rgba(212, 236, 255, 0.28) 0 4px, transparent 4px 10px),
        linear-gradient(165deg, #2b6ec2 0%, #14487e 100%);
}

.seat-card.hidden-vote[data-back-pattern="1"] {
    background:
        radial-gradient(circle at 22% 16%, rgba(240, 255, 244, 0.3) 0 18%, transparent 19%),
        repeating-linear-gradient(45deg, rgba(209, 248, 226, 0.22) 0 4px, transparent 4px 10px),
        linear-gradient(165deg, #1f7a46 0%, #14532d 100%);
}

.seat-card.hidden-vote[data-back-pattern="2"] {
    background:
        radial-gradient(circle at 70% 18%, rgba(255, 232, 232, 0.28) 0 18%, transparent 19%),
        repeating-linear-gradient(0deg, rgba(255, 204, 204, 0.2) 0 3px, transparent 3px 8px),
        linear-gradient(165deg, #bf2d3a 0%, #7f1622 100%);
}

.seat-card.waiting {
    background: linear-gradient(180deg, #f4f6f8 0%, #e6ebf0 100%);
    color: var(--muted);
}

.seat-card.vote-changed {
    animation: vote-updated 260ms ease;
}

.seat-info {
    width: 116px;
    text-align: center;
    padding: 0.7rem 0.75rem;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(27, 34, 49, 0.1);
    box-shadow: 0 8px 18px rgba(27, 34, 49, 0.11);
    transition: box-shadow 150ms ease, border-color 150ms ease;
}

.seat-name-row {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.35rem;
    flex-wrap: wrap;
}

.seat-name {
    font-weight: 700;
}

.seat-meta {
    font-size: 0.78rem;
    color: var(--muted);
}

.seat-meta-row {
    display: grid;
    justify-items: center;
    gap: 0.35rem;
    margin-top: 0.35rem;
}

.seat-remove-button {
    padding: 0.28rem 0.72rem;
    min-height: 0;
    border-radius: 999px;
    border: 1px solid rgba(165, 51, 39, 0.18);
    background: rgba(255, 247, 245, 0.98);
    color: #8f2d22;
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1.2;
    box-shadow: none;
}

.seat-remove-button:hover:not(:disabled) {
    transform: none;
    background: #ffe9e4;
    box-shadow: 0 6px 14px rgba(143, 45, 34, 0.12);
}

.seat-remove-button:disabled {
    box-shadow: none;
}

.player-sticker {
    display: inline-flex;
    align-items: center;
    padding: 0.18rem 0.5rem;
    border-radius: 999px;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.04em;
}

.player-sticker.lowest {
    background: #d9ecff;
    color: #185ea8;
}

.player-sticker.highest {
    background: #ffe4d6;
    color: #b44a16;
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(76px, 1fr));
    gap: 0.75rem;
    margin-top: 1rem;
}

.card-choice {
    aspect-ratio: 3 / 4;
    border-radius: 22px;
    border: 1px solid var(--line-strong);
    background: linear-gradient(180deg, #ffffff 0%, #eef8f2 100%);
    color: var(--text);
    font-size: 1.35rem;
    font-weight: 700;
    transition: transform 140ms ease, box-shadow 140ms ease, border-color 140ms ease;
}

.card-choice:hover:not(:disabled) {
    transform: translateY(-2px) rotate(-0.8deg);
    border-color: rgba(20, 83, 45, 0.3);
    box-shadow: 0 14px 18px rgba(27, 34, 49, 0.14);
}

.card-choice.selected {
    background: linear-gradient(180deg, #1f7a46 0%, #14532d 100%);
    color: white;
    border-color: rgba(255, 255, 255, 0.4);
    box-shadow:
        0 14px 20px rgba(20, 83, 45, 0.26),
        0 0 0 3px rgba(31, 122, 70, 0.2);
}

.card-choice:disabled {
    opacity: 0.82;
    cursor: default;
}

.card-choice.selected:disabled {
    opacity: 1;
}

.card-choice.vote-changed {
    animation: picked-card 240ms ease;
}

.cards-grid[data-animate-entry="true"] .card-choice {
    animation: card-in 180ms ease both;
}

.cards-grid[data-animate-entry="true"] .card-choice:nth-child(2) {
    animation-delay: 24ms;
}

.cards-grid[data-animate-entry="true"] .card-choice:nth-child(3) {
    animation-delay: 40ms;
}

.cards-grid[data-animate-entry="true"] .card-choice:nth-child(4) {
    animation-delay: 56ms;
}

.cards-grid[data-animate-entry="true"] .card-choice:nth-child(5) {
    animation-delay: 72ms;
}

.cards-grid[data-animate-entry="true"] .card-choice:nth-child(6) {
    animation-delay: 88ms;
}

.cards-grid[data-animate-entry="true"] .card-choice:nth-child(7) {
    animation-delay: 102ms;
}

.cards-grid[data-animate-entry="true"] .card-choice:nth-child(8) {
    animation-delay: 118ms;
}

.message {
    min-height: 1.5rem;
    margin: 1rem 0 0;
    padding: 0.4rem 0.55rem;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.32);
}

.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(165deg, rgba(255, 255, 255, 0.96) 0%, rgba(241, 247, 255, 0.9) 100%);
    padding: 1.25rem 2rem;
    box-shadow: 0 -4px 30px rgba(0, 0, 0, 0.12);
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    border-top: 1px solid var(--line);
    backdrop-filter: blur(20px);
}

.cookie-banner p {
    margin: 0;
    font-size: 0.95rem;
    max-width: 60ch;
    text-align: center;
    color: var(--text);
}

@keyframes fade-in {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes seat-pop {
    from {
        opacity: 0;
        transform: translate(-50%, -46%) scale(0.96);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}

@keyframes card-in {
    from {
        opacity: 0;
        transform: translateY(6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes vote-updated {
    0% {
        filter: brightness(1);
    }
    45% {
        filter: brightness(1.28);
    }
    100% {
        filter: brightness(1);
    }
}

@keyframes picked-card {
    0% {
        transform: translateY(0) scale(1);
    }
    50% {
        transform: translateY(-2px) scale(1.03);
    }
    100% {
        transform: translateY(0) scale(1);
    }
}

@keyframes countdown-blink {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(31, 122, 70, 0.45);
    }
    35% {
        transform: scale(1.45);
        box-shadow: 0 0 0 10px rgba(31, 122, 70, 0);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(31, 122, 70, 0);
    }
}

@media (max-width: 820px) {
    .board-grid {
        grid-template-columns: 1fr;
    }

    .board-grid[data-cards-collapsed="true"] {
        grid-template-columns: 1fr;
    }

    .section-head,
    .action-row,
    .share-actions,
    .invite-head,
    .card-picker-head {
        flex-direction: column;
        align-items: stretch;
    }

    .board-menu-panel {
        left: 0;
        right: auto;
        min-width: 100%;
    }

    .players-list {
        min-height: clamp(760px, 92vh, 980px);
    }

    .table-surface {
        inset: 26% 8%;
    }

    .table-seat {
        width: 124px;
    }

    .table-seat.side-left,
    .table-seat.side-right {
        flex-direction: column;
    }

    .table-seat.side-left .seat-card,
    .table-seat.side-right .seat-card {
        order: 1;
    }

    .table-seat.side-left .seat-info,
    .table-seat.side-right .seat-info {
        order: 2;
    }

    .seat-info {
        width: 100%;
    }

    .shell.board-active .hero h1 {
        max-width: none;
    }

    .card-picker-panel[data-collapsed="true"] {
        width: 3.5rem;
        justify-self: end;
    }

    .card-picker-panel[data-collapsed="true"] .card-picker-toggle {
        width: 2.8rem;
    }

    .cookie-banner {
        padding: 1rem;
        flex-direction: column;
    }

    .cookie-banner p {
        text-align: center;
    }
}

@media (max-width: 480px) {
    .players-list {
        min-height: clamp(720px, 96vh, 920px);
    }

    .table-surface {
        inset: 32% 5%;
    }

    .table-seat {
        width: 110px;
    }

    .hero h1 {
        font-size: clamp(1.8rem, 8vw, 2.4rem);
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 1ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 1ms !important;
        scroll-behavior: auto !important;
    }
}
