/* GIVE UP Best of 2026 — matches giveup.bike: black / yellow / hot pink, Poppins */

:root {
    --black: #000;
    --white: #fff;
    --yellow: #F9E826;
    --pink: #ED1E79;
    --pink-dark: #D4145A;
    --muted: rgba(255, 255, 255, 0.65);
    --faint: rgba(255, 255, 255, 0.4);
    --line: rgba(255, 255, 255, 0.2);
    --radius: 6.4px;
}

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

body {
    font-family: 'Poppins', sans-serif;
    font-weight: 300;
    color: var(--white);
    background: var(--black);
    line-height: 1.8;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Page backgrounds — busy collages from giveup.bike, kept behind solid panels.
   A fixed pseudo-element rather than background-attachment: fixed, which iOS ignores. */

body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    background-color: var(--black);
    background-position: center;
    background-size: cover;
}

.bg-people::before { background-image: url('bg/people.jpg'); }
.bg-flyers::before { background-image: url('bg/flyers.jpg'); }
.bg-group::before  { background-image: url('bg/group.jpg'); }
.bg-art::before    { background-image: url('bg/art.jpg'); }
.bg-crabs::before  { background-image: url('bg/crabs.jpg'); }

/* Panels — solid cards that content sits on */

.panel {
    background: rgba(0, 0, 0, 0.92);
    border-radius: 14px;
    padding: 40px;
    margin-bottom: 24px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

.panel:last-child {
    margin-bottom: 0;
}

.panel:has(.auth-page) {
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
}

h1, h2, h3 {
    font-weight: 500;
    line-height: 1.3;
    color: var(--yellow);
}

strong, b {
    font-weight: 500;
}

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

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

/* Nav */

.nav {
    background: var(--black);
    border-bottom: 3px solid var(--pink);
    padding: 16px 0;
}

.nav-inner {
    max-width: 960px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
}

.nav-brand {
    text-decoration: none;
    color: var(--yellow);
    font-weight: 700;
    font-size: 18px;
    letter-spacing: 0.02em;
}

.nav-brand span {
    color: var(--white);
    font-weight: 300;
    margin-left: 4px;
}

.nav-brand:hover {
    color: var(--pink);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 14px;
    font-weight: 400;
}

.nav-links a {
    color: var(--white);
    text-decoration: none;
}

.nav-links a:hover {
    color: var(--yellow);
}

.nav-email {
    color: var(--faint);
    font-size: 13px;
}

/* Container */

.container {
    max-width: 960px;
    margin: 0 auto;
    padding: 40px 20px;
    flex: 1;
    width: 100%;
}

/* Footer */

.footer {
    background: var(--pink);
    color: var(--white);
    padding: 28px 20px;
    text-align: center;
    font-size: 13px;
    font-weight: 400;
}

.footer a {
    color: var(--white);
}

.footer a:hover {
    color: var(--black);
}

.footer-crab {
    width: 40px;
    height: auto;
    margin-bottom: 6px;
    filter: brightness(0) invert(1);
    /* Secret snake trigger (tap ten times): no double-tap zoom, no long-press menu */
    touch-action: manipulation;
    -webkit-touch-callout: none;
    user-select: none;
    -webkit-user-select: none;
}

/* Flash messages */

.flash {
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.4);
    background: var(--yellow);
    color: var(--black);
    border-radius: var(--radius);
    padding: 12px 16px;
    margin-bottom: 24px;
    font-size: 14px;
    font-weight: 400;
}

/* Buttons */

.btn {
    display: inline-block;
    background: var(--yellow);
    color: var(--black);
    border: 2px solid var(--yellow);
    border-radius: var(--radius);
    padding: 12px 32px;
    font-family: 'Poppins', sans-serif;
    font-weight: 500;
    font-size: 15px;
    letter-spacing: 0.02em;
    line-height: 1.2;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.btn:hover {
    background: var(--pink);
    border-color: var(--pink);
    color: var(--white);
}

.btn-outline {
    background: transparent;
    color: var(--yellow);
}

.btn-outline:hover {
    background: var(--yellow);
    border-color: var(--yellow);
    color: var(--black);
}

.btn-sm {
    padding: 6px 14px;
    font-size: 13px;
}

.btn-danger {
    background: transparent;
    border-color: var(--pink);
    color: var(--pink);
}

.btn-danger:hover {
    background: var(--pink);
    color: var(--white);
}

/* Hero */

.hero {
    text-align: center;
}

.hero-logo {
    display: block;
    width: 100%;
    max-width: 440px;
    height: auto;
    margin: 0 auto 24px;
    border-radius: var(--radius);
}

.hero h1 {
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 20px;
}

.phase-badge {
    display: inline-block;
    background: var(--pink);
    color: var(--white);
    border-radius: 999px;
    padding: 6px 22px;
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.02em;
}

.intro {
    max-width: 760px;
    margin: 20px auto 0;
    text-align: left;
    font-size: 14px;
    line-height: 1.55;
}

.intro p {
    margin-bottom: 10px;
}

/* The two lists sit side by side where there's room */
.intro-lists {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 4px 28px;
    margin-bottom: 10px;
}

.intro ul {
    margin: 0 0 0 1.1em;
}

.intro li {
    margin-bottom: 2px;
}

.intro li::marker {
    color: var(--pink);
}

.intro .intro-list-title {
    margin-bottom: 2px;
    font-weight: 500;
}

.intro-signoff {
    font-weight: 500;
    color: var(--yellow);
}

.closed-message {
    margin-top: 16px;
    padding: 14px 18px;
    border: 2px solid var(--yellow);
    border-radius: var(--radius);
    color: var(--yellow);
    font-size: 1.1rem;
    font-weight: 500;
}

.closed-message-form input {
    flex: 1;
    min-width: 200px;
}

/* CTA box */

.cta-box {
    text-align: center;
    margin-top: 32px;
}

.cta-box p {
    margin-bottom: 16px;
    color: var(--muted);
}

/* Categories grid */

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 16px;
}

.category-card {
    display: block;
    background: var(--pink);
    color: var(--white);
    border-radius: var(--radius);
    padding: 24px;
    text-decoration: none;
    transition: background 0.15s, color 0.15s, transform 0.15s;
}

.category-card:hover {
    background: var(--yellow);
    color: var(--black);
    transform: translateY(-2px);
}

.category-card h3 {
    font-size: 1.2rem;
    color: inherit;
    margin-bottom: 6px;
}

.category-card p {
    font-size: 14px;
    font-weight: 400;
    color: inherit;
    opacity: 0.9;
}

.card-top-label {
    margin-top: 10px;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    opacity: 0.75;
}

.card-top {
    margin: 2px 0 0 1.1em;
    font-size: 13px;
    font-weight: 400;
    line-height: 1.45;
}

.card-top li {
    padding-left: 2px;
    overflow-wrap: anywhere;
}

.card-top li::marker {
    font-weight: 500;
    opacity: 0.7;
}

/* Form fields (shared) */

.auth-form input[type="email"],
.nominate-form input[type="text"],
.nominate-form input[type="url"],
.nominate-form textarea,
.admin-form input[type="text"],
.admin-form input[type="number"],
.admin-inline-form input[type="text"],
.admin-inline-form input[type="number"],
.phase-form input[type="number"],
.phase-form select {
    width: 100%;
    padding: 12px 14px;
    background: var(--white);
    color: var(--black);
    border: 2px solid var(--white);
    border-radius: var(--radius);
    font-family: 'Poppins', sans-serif;
    font-size: 16px;
    font-weight: 400;
    outline: none;
}

.auth-form input:focus,
.nominate-form input:focus,
.nominate-form textarea:focus,
.admin-form input:focus,
.admin-inline-form input:focus,
.phase-form select:focus {
    border-color: var(--yellow);
    box-shadow: 0 0 0 3px rgba(249, 232, 38, 0.35);
}

/* Auth page */

.auth-page {
    max-width: 400px;
    margin: 0 auto;
    text-align: center;
}

.auth-page h2 {
    font-size: 2.2rem;
    margin-bottom: 12px;
}

.auth-page p {
    margin-bottom: 24px;
    color: var(--muted);
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.dev-login {
    margin-top: 40px;
    font-size: 14px;
    color: var(--faint);
}

.dev-login summary {
    cursor: pointer;
    margin-bottom: 12px;
}

/* Category page */

.category-page {
    max-width: 700px;
    margin: 0 auto;
}

.back-link {
    display: inline-block;
    margin-bottom: 16px;
    font-size: 14px;
    color: var(--muted);
}

.category-page h2 {
    font-size: 2.2rem;
    margin-bottom: 8px;
}

.category-desc {
    color: var(--muted);
    margin-bottom: 16px;
}

.phase-info {
    font-size: 14px;
    color: var(--faint);
    margin-bottom: 24px;
}

.rate-limit-notice {
    border: 2px solid var(--yellow);
    color: var(--yellow);
    border-radius: var(--radius);
    padding: 12px 16px;
    font-size: 14px;
    font-weight: 400;
    margin-bottom: 24px;
}

.rate-limit-success {
    background: var(--yellow);
    color: var(--black);
}

.rate-limit-success strong {
    display: block;
    font-size: 1.05rem;
}

/* Nominee cards */

.nominees-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 48px;
}

.nominee-card {
    border: 2px solid var(--line);
    border-radius: var(--radius);
    padding: 20px;
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.nominee-winner {
    background: var(--yellow);
    border-color: var(--yellow);
    color: var(--black);
}

.nominee-winner h3,
.nominee-winner .nominee-desc,
.nominee-winner .nominee-reason,
.nominee-winner .vote-count,
.nominee-winner .nom-count,
.nominee-winner a {
    color: var(--black);
}

.nominee-photo {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: var(--radius);
    flex-shrink: 0;
}

.nominee-info {
    flex: 1;
    min-width: 0;
}

.nominee-info h3 {
    font-size: 1.2rem;
    margin-bottom: 4px;
}

.nominee-desc {
    font-size: 14px;
    color: var(--white);
    margin-bottom: 4px;
}

.nominee-reason {
    font-size: 14px;
    color: var(--muted);
    margin-bottom: 4px;
}

.nominee-link {
    font-size: 13px;
}

.nominee-links {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 16px;
    font-size: 13px;
}

.nominee-ig {
    font-weight: 500;
    color: var(--yellow);
    text-decoration: none;
    word-break: break-all;
}

.nominee-ig:hover {
    text-decoration: underline;
}

.nominee-winner .nominee-ig,
.result-winner .nominee-ig {
    color: var(--black);
}

.result-info .nominee-ig {
    margin-left: 8px;
    font-size: 13px;
}

.nominee-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 10px;
    flex-wrap: wrap;
}

.vote-count {
    font-size: 14px;
    font-weight: 500;
    color: var(--yellow);
}

.nom-count {
    font-size: 13px;
    color: var(--faint);
}

.voted-badge {
    font-size: 13px;
    font-weight: 500;
    color: var(--white);
    background: var(--pink);
    border-radius: 999px;
    padding: 4px 12px;
}

/* Nominate form */

.nominate-section {
    border-top: 3px solid var(--pink);
    padding-top: 32px;
}

.nominate-section h3 {
    font-size: 1.6rem;
    margin-bottom: 20px;
}

.nominate-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.nominate-form label {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 14px;
    font-weight: 500;
}

.nominate-form input[type="file"] {
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    color: var(--muted);
}

/* Results page */

.results-page h2 {
    font-size: 2.8rem;
    margin-bottom: 32px;
}

.results-category {
    margin-bottom: 48px;
}

.results-category h3 {
    font-size: 1.6rem;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 3px solid var(--pink);
}

.results-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.result-row {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px 16px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
}

.result-winner {
    background: var(--yellow);
    border-color: var(--yellow);
    color: var(--black);
}

.result-winner .result-desc,
.result-winner .result-noms {
    color: rgba(0, 0, 0, 0.65);
}

.result-rank {
    font-weight: 700;
    font-size: 18px;
    width: 36px;
    flex-shrink: 0;
}

.result-photo {
    width: 48px;
    height: 48px;
    object-fit: cover;
    border-radius: var(--radius);
    flex-shrink: 0;
}

.result-info {
    flex: 1;
    min-width: 0;
}

.result-desc {
    font-size: 14px;
    color: var(--muted);
}

.result-votes {
    text-align: right;
    font-weight: 500;
    flex-shrink: 0;
}

.result-noms {
    font-size: 13px;
    color: var(--faint);
    font-weight: 400;
}

/* Nominees who didn't make the final (results) */

.non-finalists {
    margin-top: 16px;
    padding: 12px 16px;
    border: 1px dashed var(--line);
    border-radius: var(--radius);
}

.non-finalists h4 {
    font-size: 13px;
    font-weight: 500;
    color: var(--muted);
    margin-bottom: 4px;
}

.non-finalists ul {
    list-style: none;
    font-size: 14px;
    color: var(--muted);
}

.non-finalists li {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 2px 0;
}

/* Admin pages */

.admin-page {
    max-width: 800px;
    margin: 0 auto;
}

.admin-page h2 {
    font-size: 2.2rem;
    margin-bottom: 24px;
}

.admin-section {
    margin-bottom: 40px;
}

.admin-section h3 {
    font-size: 1.3rem;
    margin-bottom: 16px;
}

.phase-form {
    display: flex;
    gap: 12px;
    align-items: center;
}

.phase-form select {
    width: auto;
    font-size: 14px;
}

.phase-form label {
    font-size: 14px;
    font-weight: 500;
}

.phase-form .limit-input {
    width: 90px;
    font-size: 14px;
}

/* Stats */

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 12px;
}

.stat-card {
    border: 2px solid var(--line);
    border-radius: var(--radius);
    padding: 20px;
    text-align: center;
}

.stat-number {
    font-size: 2rem;
    font-weight: 500;
    color: var(--yellow);
}

.stat-label {
    font-size: 13px;
    color: var(--muted);
    margin-top: 4px;
}

/* Admin nav */

.admin-nav {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* Admin forms */

.admin-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 500px;
}

.admin-form label {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 14px;
    font-weight: 500;
}

/* Admin cards */

.admin-card {
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 16px;
    margin-bottom: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.admin-card-pending {
    border: 2px solid var(--pink);
    background: rgba(237, 30, 121, 0.12);
}

.admin-inline-form {
    display: flex;
    gap: 8px;
    align-items: center;
    flex: 1;
    flex-wrap: wrap;
}

.admin-inline-form input[type="text"],
.admin-inline-form input[type="number"] {
    width: auto;
    padding: 6px 10px;
    font-size: 14px;
}

.admin-inline-form input[type="text"] {
    flex: 1;
    min-width: 150px;
}

/* Admin nominees */

.nominee-admin-info {
    display: flex;
    gap: 16px;
    flex: 1;
    align-items: flex-start;
}

.admin-nominee-photo {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: var(--radius);
    flex-shrink: 0;
}

.admin-meta {
    font-size: 13px;
    color: var(--faint);
}

.admin-desc {
    font-size: 14px;
    color: var(--white);
    margin: 4px 0;
}

.admin-reason {
    font-size: 14px;
    color: var(--muted);
    margin: 4px 0;
}

.admin-actions {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

/* Admin nominee edit */

.edit-photo {
    display: flex;
    flex-direction: column;
    gap: 8px;
    font-size: 14px;
}

.edit-photo-label {
    font-weight: 500;
}

.edit-photo label {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-weight: 500;
}

.edit-photo .checkbox-label {
    flex-direction: row;
    align-items: center;
    gap: 8px;
    font-weight: 400;
}

.edit-photo input[type="file"] {
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    color: var(--muted);
}

/* Admin nominee merge */

.merge-form {
    display: flex;
    gap: 8px;
    align-items: center;
    width: 100%;
    justify-content: flex-end;
    flex-wrap: wrap;
}

.merge-form select {
    max-width: 100%;
    padding: 6px 10px;
    background: var(--white);
    color: var(--black);
    border: 2px solid var(--white);
    border-radius: var(--radius);
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
}

/* Admin table */

.admin-table {
    width: 100%;
    border-collapse: collapse;
}

.admin-table th,
.admin-table td {
    padding: 10px 14px;
    text-align: left;
    border-bottom: 1px solid var(--line);
    font-size: 14px;
}

.admin-table th {
    font-weight: 500;
    color: var(--yellow);
    border-bottom: 2px solid var(--yellow);
}

/* Empty state */

.empty-state {
    text-align: center;
    color: var(--faint);
    padding: 40px 20px;
    font-size: 14px;
}

/* Responsive */

@media (max-width: 600px) {
    .hero h1 {
        font-size: 2.6rem;
    }

    .nav-brand {
        font-size: 16px;
    }

    .container {
        padding: 20px 12px;
    }

    .panel {
        padding: 28px 18px;
        border-radius: 10px;
    }

    .nominee-card {
        flex-direction: column;
    }

    .nominee-photo {
        width: 100%;
        height: 200px;
    }

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

    .results-page h2 {
        font-size: 2.2rem;
    }

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

    .admin-inline-form {
        flex-direction: column;
        width: 100%;
    }

    .admin-inline-form input[type="text"] {
        width: 100%;
    }

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

/* Secret snake (static/snake.js) */

.snake-open,
.snake-open body {
    overflow: hidden;
}

.snake-overlay {
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: flex-start;
    justify-content: center;
    overflow-y: auto;
    padding: max(16px, env(safe-area-inset-top)) 12px max(16px, env(safe-area-inset-bottom));
}

.snake-box {
    width: 100%;
    max-width: 440px;
    margin: auto 0;
    background: var(--black);
    border: 3px solid var(--pink);
    border-radius: 14px;
    padding: 16px;
    box-shadow: 0 10px 60px rgba(237, 30, 121, 0.35);
}

.snake-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.snake-head h2 {
    font-size: 1.6rem;
    line-height: 1;
    flex: 1;
}

.snake-score {
    font-size: 1.4rem;
    font-weight: 500;
    color: var(--white);
    font-variant-numeric: tabular-nums;
}

.snake-close {
    background: none;
    border: 2px solid var(--line);
    border-radius: var(--radius);
    color: var(--white);
    font-size: 22px;
    line-height: 1;
    width: 40px;
    height: 40px;
    cursor: pointer;
}

.snake-close:hover {
    border-color: var(--pink);
    color: var(--pink);
}

.snake-stage {
    position: relative;
    width: 100%;
    max-width: min(100%, 58vh);
    margin: 0 auto;
    aspect-ratio: 1;
    border: 2px solid var(--yellow);
    border-radius: var(--radius);
    overflow: hidden;
    touch-action: none;
    user-select: none;
    -webkit-user-select: none;
}

.snake-stage canvas {
    display: block;
    width: 100%;
    height: 100%;
}

.snake-msg {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 16px;
    text-align: center;
    background: rgba(0, 0, 0, 0.78);
    font-size: 14px;
}

.snake-msg[hidden] {
    display: none;
}

.snake-big {
    font-size: 2rem;
    font-weight: 500;
    color: var(--yellow);
    line-height: 1.1;
}

.snake-form {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

.snake-form p {
    width: 100%;
    color: var(--pink);
    font-weight: 500;
}

.snake-form input {
    width: 9em;
    padding: 8px 10px;
    border: 2px solid var(--white);
    border-radius: var(--radius);
    font-family: 'Poppins', sans-serif;
    font-size: 18px;
    font-weight: 500;
    letter-spacing: 0.05em;
    text-align: center;
}

.snake-form input:focus {
    outline: none;
    border-color: var(--yellow);
}

.snake-err {
    color: var(--pink);
}

/* D-pad: only on touch screens */

.snake-pad {
    display: none;
    grid-template-columns: repeat(3, 64px);
    grid-template-rows: repeat(2, 56px);
    grid-template-areas: ". up ." "left down right";
    gap: 8px;
    justify-content: center;
    margin-top: 14px;
    touch-action: none;
}

.snake-pad button {
    background: var(--pink);
    color: var(--white);
    border: none;
    border-radius: var(--radius);
    font-size: 20px;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.snake-pad button:active {
    background: var(--yellow);
    color: var(--black);
}

.snake-pad-up { grid-area: up; }
.snake-pad-down { grid-area: down; }
.snake-pad-left { grid-area: left; }
.snake-pad-right { grid-area: right; }

@media (pointer: coarse) {
    .snake-pad {
        display: grid;
    }
}

/* #1 score under the board during play */

.snake-best {
    margin-top: 10px;
    text-align: center;
    font-size: 13px;
    color: var(--muted);
}

.snake-best .snake-points {
    color: var(--yellow);
    font-weight: 500;
}

/* The d-pad's display: grid would otherwise override the hidden attribute */
.snake-pad[hidden],
.snake-board[hidden],
.snake-best[hidden] {
    display: none;
}

/* Leaderboard */

.snake-board {
    margin-top: 16px;
}

.snake-board h3 {
    font-size: 1rem;
    margin-bottom: 6px;
}

.snake-board ol {
    list-style: none;
    counter-reset: rank;
    font-size: 14px;
}

.snake-board li {
    counter-increment: rank;
    display: flex;
    gap: 12px;
    padding: 4px 8px;
    border-radius: 4px;
    font-variant-numeric: tabular-nums;
}

.snake-board li::before {
    content: counter(rank) ".";
    width: 2em;
    color: var(--faint);
}

.snake-board li.snake-empty::before {
    content: none;
}

.snake-board li.snake-empty {
    color: var(--faint);
}

.snake-initials {
    flex: 1;
    font-weight: 500;
}

.snake-points {
    color: var(--yellow);
    font-weight: 500;
}

.snake-me {
    background: var(--yellow);
    color: var(--black);
}

.snake-me::before,
.snake-me .snake-points {
    color: var(--black);
}

/* Secret tetris (static/tetris.js) — reuses the snake window's styles */

.tetris-main {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 12px;
}

.tetris-stage {
    position: relative;
    /* 10 x 20 board: fit the screen's height, and leave room for the side panel on narrow phones */
    height: min(62vh, 520px, calc((100vw - 150px) * 2));
    aspect-ratio: 1 / 2;
    border: 2px solid var(--yellow);
    border-radius: var(--radius);
    overflow: hidden;
    touch-action: none;
    user-select: none;
    -webkit-user-select: none;
}

.tetris-stage canvas {
    display: block;
    width: 100%;
    height: 100%;
}

.tetris-side {
    width: 84px;
    font-size: 13px;
    color: var(--muted);
}

.tetris-side p {
    margin-bottom: 4px;
}

.tetris-label {
    color: var(--yellow);
    font-weight: 500;
}

.tetris-next {
    display: block;
    width: 80px;
    height: 80px;
    margin-bottom: 10px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
}

/* Touch buttons: only on touch screens, hidden after a game like the snake d-pad */
.tetris-pad {
    display: none;
    justify-content: center;
    gap: 8px;
    margin-top: 12px;
    touch-action: none;
}

.tetris-pad button {
    width: 56px;
    height: 52px;
    background: var(--pink);
    color: var(--white);
    border: none;
    border-radius: var(--radius);
    font-size: 20px;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
}

.tetris-pad button:active {
    background: var(--yellow);
    color: var(--black);
}

@media (pointer: coarse) {
    .tetris-pad {
        display: flex;
    }
}

.tetris-pad[hidden] {
    display: none;
}

