@font-face {
    font-family: "28DaysLater";
    src: url("/fonts/28dayslater.woff2") format("woff2");
    font-display: swap;
}

:root {
    --bg: #0d0c0c;
    --panel: #1a1817;
    --gray: #7c716c;
    --bone: #ece6dc;
    --muted: #b9b0a8;
    --red: #b3191f;
    --gold: #e6c27a;
    --line: #2c2826;
    --max: 1040px;
    --focus: #fff;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    background: var(--bg);
    color: var(--bone);
    font: 17px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--bone); text-decoration-color: var(--red); text-underline-offset: 3px; }
a:hover, a:focus { color: #fff; text-decoration-color: #fff; }

:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 20px; }

.skip {
    position: absolute;
    left: -999px;
}
.skip:focus {
    left: 10px;
    top: 10px;
    background: #fff;
    color: #000;
    padding: 8px 12px;
    z-index: 20;
}

.site-header {
    background: var(--gray);
    box-shadow: 0 2px 6px rgba(0, 0, 0, .5);
    position: sticky;
    top: 0;
    z-index: 5;
}
.site-header .wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 76px;
}
.brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: #1a120f;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
}
.brand img { width: 52px; height: auto; }
.nav, .subnav {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    list-style: none;
    margin: 0;
    padding: 0;
}
.nav a, .nav button {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 8px 14px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 600;
    letter-spacing: .04em;
    text-transform: uppercase;
    font-size: .85rem;
    color: #1a120f;
    background: transparent;
    border: 0;
    cursor: pointer;
    font-family: inherit;
}
.nav form { margin: 0; }
.nav a[aria-current="page"] { background: rgba(0, 0, 0, .35); color: #fff; }
.nav a:hover, .nav button:hover { background: rgba(0, 0, 0, .25); color: #fff; }

.nav-menu > .nav { display: flex; }

.nav-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    margin: 0;
    padding: 0;
    border-radius: 4px;
    list-style: none;
    cursor: pointer;
}

.nav-toggle::-webkit-details-marker { display: none; }

.nav-toggle::marker { content: ""; }

.nav-toggle-bars,
.nav-toggle-bars::before,
.nav-toggle-bars::after {
    display: block;
    width: 22px;
    height: 2px;
    border-radius: 1px;
    background: #1a120f;
}

.nav-toggle-bars { position: relative; }

.nav-toggle-bars::before,
.nav-toggle-bars::after {
    content: "";
    position: absolute;
    left: 0;
}

.nav-toggle-bars::before { top: -7px; }

.nav-toggle-bars::after { top: 7px; }

.nav-menu[open] .nav-toggle-bars { background: transparent; }

.nav-menu[open] .nav-toggle-bars::before { transform: translateY(7px) rotate(45deg); }

.nav-menu[open] .nav-toggle-bars::after { transform: translateY(-7px) rotate(-45deg); }

.subnav { margin: 8px 0 20px; }
.subnav a {
    color: var(--bone);
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    padding: 8px 12px;
    text-decoration: none;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .05em;
    font-size: .85rem;
}
.subnav a[aria-current="page"] { background: var(--panel); border-radius: 4px; }

.display {
    font-family: "28DaysLater", Impact, "Arial Black", sans-serif;
    font-weight: normal;
    letter-spacing: .03em;
    line-height: 1.1;
    margin: 0;
}
.tagline { font-size: 1.15rem; color: var(--muted); margin: .6rem 0 0; }

.hero {
    text-align: center;
    padding: 36px 0 28px;
    background: radial-gradient(ellipse at center top, #2a2624 0%, var(--bg) 70%);
}
.hero img.crest {
    width: min(280px, 70vw);
    margin: 0 auto 20px;
    filter: drop-shadow(0 10px 30px rgba(0, 0, 0, .6));
}
.hero h1 { font-size: clamp(2.2rem, 6vw, 3.6rem); }
.hero-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
}
.hero-actions .btn {
    margin-top: 0;
    min-height: 48px;
    padding: 12px 28px;
}

.page-head { padding-top: 32px; padding-bottom: 8px; }
.lounge-title { display: flex; align-items: center; gap: 14px; }
.lounge-title h1 { margin: 0; }
.lounge-logo, .logo-current, .logo-preview {
    display: block;
    object-fit: contain;
    background: #12100f;
    border: 1px solid var(--line);
    border-radius: 8px;
}
.lounge-logo { width: 72px; height: 72px; flex: none; }
.logo-current, .logo-preview { width: 120px; height: 120px; margin-top: 8px; }
.logo-preview[hidden] { display: none !important; }
input.logo-file { min-height: 44px; padding: 10px; }
.page-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 16px; }
.page-actions .btn { margin-top: 0; }
.page-actions form { margin: 0; }
.page-head h1 { font-size: clamp(1.9rem, 5vw, 3rem); }
.page-head p { color: var(--muted); margin: .5rem 0 0; }

.filters {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
    margin: 20px 0 8px;
    align-items: end;
}
.filters .actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.filters .btn { margin-top: 0; }

label { display: block; font-weight: 700; margin: .85rem 0 .3rem; }
input, select, textarea {
    width: 100%;
    padding: 12px;
    border-radius: 4px;
    border: 1px solid #3a342f;
    background: #12100f;
    color: var(--bone);
    font: inherit;
}
textarea { min-height: 120px; resize: vertical; }
.check { display: flex; gap: 10px; align-items: center; font-weight: 600; }
.check input { width: auto; }

.btn, button.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    margin-top: 12px;
    padding: 10px 18px;
    border: 2px solid var(--red);
    border-radius: 4px;
    background: transparent;
    color: var(--bone);
    text-decoration: none;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .06em;
    cursor: pointer;
    font: inherit;
}
.btn:hover, button.btn:hover { background: var(--red); color: #fff; }
.btn-small { min-height: 40px; margin-top: 0; padding: 6px 12px; font-size: .85rem; }
.btn-quiet { border-color: var(--gray); }

.cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    padding-top: 16px;
    padding-bottom: 48px;
}
.card {
    background: var(--panel);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 18px 18px 20px;
}
.card h2 { margin: 0 0 .35rem; font-size: 1.35rem; }
.card h2 a { text-decoration: none; }
.card h2 a:hover { text-decoration: underline; }
.meta { color: var(--muted); margin: 0 0 .6rem; }
.card p { margin: 0 0 .7rem; }

.star-row { letter-spacing: .08em; white-space: nowrap; }
.star { color: #5c534c; }
.star.on { color: var(--gold); }
.rating-line { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 8px 0; }

.lounge-photo {
    width: min(420px, 100%);
    border-radius: 8px;
    margin: 12px 0;
    border: 1px solid var(--line);
}

.star-options { display: flex; flex-wrap: wrap; gap: 8px; }
.star-options label {
    margin: 0;
    font-weight: 600;
    border: 1px solid var(--line);
    border-radius: 4px;
    padding: 8px 10px;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.star-options input { width: auto; }

.progress-label { font-size: 1.15rem; margin: 0 0 8px; }
.progress {
    height: 14px;
    background: #12100f;
    border: 1px solid var(--line);
    border-radius: 99px;
    overflow: hidden;
}
.progress span {
    display: block;
    height: 100%;
    background: linear-gradient(90deg, #8a1d22, var(--gold));
}

.stamps {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 18px;
    padding: 8px 0 28px;
}
.stamp {
    position: relative;
    overflow: hidden;
    aspect-ratio: 1;
    border-radius: 50%;
    border: 3px dashed #5c534c;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 14px;
    text-decoration: none;
    color: var(--muted);
    background: transparent;
    gap: 4px;
}
.stamp strong { position: relative; z-index: 1; font-size: .95rem; line-height: 1.2; color: inherit; }
.stamp span { position: relative; z-index: 1; font-size: .8rem; }
.stamp > .stamp-logo {
    position: absolute;
    z-index: 0;
    inset: 14%;
    background: var(--logo) center / contain no-repeat;
    opacity: .22;
    pointer-events: none;
}
.stamp.stamped {
    border-style: double;
    border-width: 6px;
    border-color: var(--gold);
    color: var(--bone);
    background: radial-gradient(circle, #2a221c, #14110f 72%);
    box-shadow: inset 0 0 0 3px #3a2a22;
    transform: rotate(-6deg);
}
.stamp:nth-child(2n).stamped { transform: rotate(4deg); }
.stamp:nth-child(3n).stamped { transform: rotate(-2deg); }

.row-cigars {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    margin-left: 8px;
    font-size: .85rem;
    font-weight: 700;
    letter-spacing: .04em;
    white-space: nowrap;
}

.stack { display: grid; gap: 16px; padding-bottom: 48px; }
.review { border-top: 1px solid var(--line); padding-top: 14px; margin-top: 14px; }
.review header { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; }
.review h3 { margin: 0; font-size: 1.05rem; }

.status, .alert {
    margin: 16px auto;
    max-width: var(--max);
    padding: 12px 16px;
    border-radius: 6px;
}
.status { background: #1d2a22; border: 1px solid #3d5c48; }
.alert { background: #2a1616; border: 1px solid var(--red); }
.alert ul { margin: .3rem 0 0; padding-left: 1.2rem; }
.field-error {
    color: #f0c2c2;
    margin: 6px 0 0;
}
.help { color: var(--muted); font-size: .95rem; }
.error { color: #ffd0d0; font-size: .95rem; margin: .2rem 0 0; }
.empty { color: var(--muted); padding: 12px 0 32px; }

.hp {
    position: absolute;
    left: -10000px;
    top: auto;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.pager {
    display: flex;
    gap: 16px;
    align-items: center;
    padding-bottom: 40px;
}

.site-footer {
    background: #000;
    border-top: 3px solid var(--gray);
    padding: 32px 0 20px;
    color: var(--muted);
    font-size: .95rem;
}
.site-footer .cols {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}
.site-footer h2 {
    font-size: .85rem;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: var(--bone);
    margin: 0 0 .5rem;
}
.site-footer p { margin: 0; }
.copyright { text-align: center; font-size: .85rem; margin-top: 28px; color: #c4bbb3; }

.lost { text-align: center; padding-top: 48px; padding-bottom: 72px; }
.lost img { width: 160px; margin: 0 auto 16px; }

.notes { white-space: pre-wrap; }
.feature-fields { border: 0; margin: 1rem 0 0; padding: 0; }
.feature-fields legend { font-weight: 700; margin-bottom: .4rem; }
.checks { display: grid; gap: 8px; }
.feature-list { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 0 0 1rem; padding: 0; }
.chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: 1px solid var(--line);
    background: #12100f;
    border-radius: 999px;
    padding: 6px 12px;
    font-size: .92rem;
    line-height: 1.3;
}
.chip-icon { width: 16px; height: 16px; flex: 0 0 auto; color: var(--gold); }

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
.photo-slot {
    width: 120px;
    height: 120px;
    margin: 8px 0 4px;
    border: 3px double var(--gold);
    display: grid;
    place-items: center;
    overflow: hidden;
    background: #2a1214;
    color: var(--gold);
    font-weight: 800;
    letter-spacing: .08em;
    font-size: 1.6rem;
}
.photo-slot img { width: 100%; height: 100%; object-fit: cover; }

.cigar-log { list-style: none; margin: 0; padding: 0; }
.cigar-log > li { border-top: 1px solid var(--line); padding: 14px 0; }
.cigar-log > li:first-child { border-top: 0; padding-top: 0; }
.cigar-log h3 { margin: 0 0 4px; font-size: 1.15rem; }
.cigar-suggest { position: relative; }
.cigar-suggest-list {
    position: absolute;
    z-index: 6;
    left: 0;
    right: 0;
    top: calc(100% - 4px);
    margin: 0;
    padding: 4px;
    list-style: none;
    background: #12100f;
    border: 1px solid var(--line);
    border-radius: 4px;
    max-height: 240px;
    overflow: auto;
}
.cigar-suggest-list[hidden] { display: none !important; }
.cigar-suggest-list button {
    display: block;
    width: 100%;
    min-height: 44px;
    padding: 8px 10px;
    border: 0;
    border-radius: 4px;
    background: transparent;
    color: var(--bone);
    font: inherit;
    text-align: left;
    cursor: pointer;
}
.cigar-suggest-list button[aria-selected="true"],
.cigar-suggest-list button:hover { background: #2a2624; }
.suggest-heading {
    padding: 8px 10px 2px;
    color: var(--muted);
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
}
.suggest-kind-inline {
    display: inline-block;
    min-width: 3.2rem;
    margin-right: 8px;
    color: var(--gold);
    font-size: .72rem;
    letter-spacing: .04em;
    text-transform: uppercase;
}
.more-details {
    margin: 12px 0;
    border-top: 1px solid var(--line);
    padding-top: 8px;
}
.more-details > summary {
    min-height: 44px;
    display: flex;
    align-items: center;
    cursor: pointer;
    color: var(--gold);
    font-weight: 700;
}
.more-details[open] > summary { margin-bottom: 8px; }
.more-details textarea { min-height: 88px; }

@media (min-width: 700px) {
    .filters { grid-template-columns: 1.3fr .7fr 1fr auto; }
    .checks { grid-template-columns: 1fr 1fr; }
    .filters .actions { padding-top: 1.85rem; }
    .cards { grid-template-columns: 1fr 1fr; }
    .site-footer .cols { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 980px) {
    .site-header { z-index: 8; }

    .site-header .wrap {
        flex-direction: row;
        flex-wrap: nowrap;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        min-height: 64px;
        padding-top: 8px;
        padding-bottom: 8px;
    }

    .brand { justify-content: flex-start; min-width: 0; }

    .brand span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

    .site-header nav { margin-left: auto; flex: 0 0 auto; }

    .nav-toggle { display: inline-flex; }

    .nav-toggle:hover { background: rgba(0, 0, 0, .2); }

    .nav-menu:not([open]) > .nav { display: none; }

    .nav-menu[open] > .nav {
        position: absolute;
        z-index: 2;
        left: 0;
        right: 0;
        top: 100%;
        display: flex;
        flex-direction: column;
        align-items: stretch;
        gap: 4px;
        margin: 0;
        padding: 8px 12px 14px;
        background: #6e6560;
        border-top: 1px solid rgba(26, 18, 15, .35);
        box-shadow: 0 16px 28px rgba(0, 0, 0, .45);
    }

    .nav-menu[open] > .nav a,
    .nav-menu[open] > .nav button {
        width: 100%;
        justify-content: flex-start;
    }
}

@media (min-width: 981px) {
    .site-header nav { margin-left: auto; }

    .nav-menu,
    .nav-menu > .nav {
        display: flex;
        flex-wrap: nowrap;
        min-width: max-content;
    }
}

@media (max-width: 720px) {
    body { font-size: 16px; }

    .lounge-logo { width: 64px; height: 64px; }

    .hero-actions { flex-direction: column; align-items: stretch; }
    .hero-actions .btn {
        display: flex;
        width: 100%;
        min-height: 52px;
        padding: 14px 18px;
    }

    a.btn.stamp-reach {
        position: fixed;
        z-index: 6;
        left: 0;
        right: 0;
        bottom: 0;
        width: auto;
        margin: 0;
        border-width: 2px 0 0;
        border-radius: 0;
        min-height: 52px;
        padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
        background: #1a1817;
    }

    body:has(a.btn.stamp-reach) { padding-bottom: 84px; }
}

.humidor-totals {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 28px;
    margin: 10px 0 0;
}
.humidor-totals strong {
    display: block;
    color: var(--gold);
    font-size: 1.8rem;
    line-height: 1.1;
    font-variant-numeric: tabular-nums;
}
.stick {
    display: grid;
    grid-template-columns: 72px 1fr;
    gap: 12px;
    align-items: start;
}
.stick-photo, .stick-photo-empty {
    width: 72px;
    height: 96px;
    object-fit: cover;
    background: #2a1214;
    border: 1px solid var(--line);
}
.stick-actions { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.stick-actions form, .stick-actions details { margin: 0; }
.stick-actions .btn { margin-top: 0; }
summary.btn { width: fit-content; list-style: none; }
summary.btn::-webkit-details-marker { display: none; }

@media (max-width: 720px) {
    .stick-actions .btn, summary.btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
    .stamp.stamped, .stamp:nth-child(2n).stamped, .stamp:nth-child(3n).stamped { transform: none; }
}

.managed-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 10px 0 0;
    padding: 4px 12px;
    border: 1px solid var(--gold);
    border-radius: 999px;
    color: var(--gold);
    font-size: .8rem;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
}
.managed-badge::before {
    content: "";
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--gold);
    box-shadow: 0 0 0 3px rgba(230, 194, 122, .25);
}

.stat-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin: 12px 0;
}
.stat-grid div {
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 12px;
    background: #12100f;
}
.stat-grid dt {
    color: var(--muted);
    font-size: .8rem;
    letter-spacing: .04em;
    text-transform: uppercase;
}
.stat-grid dd {
    margin: 4px 0 0;
    color: var(--gold);
    font-size: 1.45rem;
    font-weight: 700;
}

.manager-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}
.manager-actions .btn,
.manager-actions form { margin: 0; }

.manager-roster {
    list-style: none;
    margin: 12px 0;
    padding: 0;
}
.manager-roster li {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 16px;
    align-items: center;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid var(--line);
}
.manager-roster form { margin: 0; }
.manager-add { margin-top: 8px; }

.manager-events {
    margin-top: 16px;
    padding-top: 8px;
    border-top: 1px solid var(--line);
}
.card.manager-events { margin-top: 0; padding-top: 18px; border-top: 1px solid var(--line); }
.manager-events-slot {
    min-height: 72px;
    margin-top: 8px;
    border: 1px dashed var(--gold);
    border-radius: 8px;
    background: rgba(230, 194, 122, .06);
}

.period-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 12px 0 4px;
}
.period-tabs a {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    padding: 0 14px;
    border: 1px solid var(--line);
    border-radius: 4px;
    text-decoration: none;
    color: var(--bone);
}
.period-tabs a[aria-current="page"] {
    border-color: var(--gold);
    color: var(--gold);
}

.standings {
    list-style: none;
    margin: 12px 0;
    padding: 0;
}
.standings li {
    display: grid;
    grid-template-columns: 2.2rem 40px 1fr auto;
    gap: 10px;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid var(--line);
}
.standing-rank {
    color: var(--gold);
    font-weight: 700;
    font-size: 1.15rem;
}
.standing-who {
    display: flex;
    flex-direction: column;
    min-width: 0;
}
.standing-who strong { word-break: break-word; }
.standing-who a.standing-link { font-weight: 700; }
a.avatar {
    text-decoration: none;
    color: var(--gold);
}
.visitors li {
    grid-template-columns: 40px 1fr auto;
}
.standing-score {
    color: var(--bone);
    text-align: right;
}
.avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    display: grid;
    place-items: center;
    background: #2a2422;
    color: var(--gold);
    font-weight: 700;
    border: 1px solid var(--line);
}
.avatar img {
    width: 40px;
    height: 40px;
    object-fit: cover;
    display: block;
}
.your-rank {
    margin: 8px 0 0;
    padding: 10px 12px;
    border-radius: 6px;
    background: #12100f;
    border: 1px solid var(--line);
}
.countdown {
    color: var(--gold);
    font-size: 1.25rem;
    margin: .4rem 0 0;
}
.state {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 99px;
    border: 1px solid var(--line);
    text-transform: uppercase;
    letter-spacing: .04em;
    font-size: .75rem;
}
.state-active { border-color: var(--gold); color: var(--gold); }
.state-ended { color: var(--muted); }
.contest-banner {
    width: 100%;
    max-height: 280px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid var(--line);
    margin: 0 0 16px;
}

@media (max-width: 720px) {
    .stat-grid { grid-template-columns: 1fr 1fr; }
    .manager-actions .btn,
    .manager-roster .btn { width: 100%; }
    .manager-roster li { align-items: stretch; }
    .standings li {
        grid-template-columns: 2rem 40px 1fr;
        grid-template-areas:
            "rank avatar who"
            "score score score";
    }
    .standing-rank { grid-area: rank; }
    .avatar { grid-area: avatar; }
    .standing-who { grid-area: who; }
    .standing-score { grid-area: score; text-align: left; }
    .visitors li {
        grid-template-columns: 40px 1fr;
        grid-template-areas:
            "avatar who"
            "score score";
    }
    .period-tabs a { flex: 1 1 auto; justify-content: center; }
}

/* Physical passport request */
.physical-badge {
    display: inline-block; margin: 0 0 .5rem; padding: 3px 12px; border: 1px solid var(--gold, #c9a45c);
    border-radius: 999px; color: var(--gold, #c9a45c); font-size: .85rem; letter-spacing: .08em; text-transform: uppercase;
}
.physical-page > * { max-width: 760px; width: 100%; }
.physical-points { margin: 0 0 .8rem; padding-left: 1.2rem; display: grid; gap: 6px; }
.physical-grid { display: grid; gap: 0 16px; }
.physical-qty { max-width: 8rem; }
.physical-address { border: 0; padding: 0; margin: 12px 0 0; min-width: 0; }
.physical-address legend { font-weight: 700; padding: 0; margin-bottom: 4px; }
.physical-actions { margin: .8rem 0 0; }
.book-request header h2 { margin: 0 0 .2rem; }
.book-request-fields { display: grid; gap: 8px; margin: 0; }
.book-request-fields div { display: grid; grid-template-columns: 7rem 1fr; gap: 12px; }
.book-request-fields dt { color: var(--muted); }
.book-request-fields dd { margin: 0; overflow-wrap: anywhere; }
@media (min-width: 640px) {
    .physical-grid { grid-template-columns: 1fr 1fr; }
    .physical-grid-3 { grid-template-columns: 2fr 1fr 1fr; }
}
@media (max-width: 639px) {
    .book-request-fields div { grid-template-columns: 1fr; gap: 0; }
}

/* Member lounge photos */
.photos-page > * { max-width: 900px; width: 100%; }
.photo-grid { list-style: none; margin: .4rem 0 1rem; padding: 0; display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.photo-tile { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.photo-tile p { margin: 0; }
.photo-thumb { display: block; aspect-ratio: 1; overflow: hidden; border-radius: 8px; border: 1px solid var(--line); background: #000; }
.photo-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .2s ease; }
.photo-thumb:hover img, .photo-thumb:focus-visible img { transform: scale(1.03); }
.photo-caption { overflow-wrap: anywhere; font-size: .95rem; }
.photo-date { font-size: .85rem; }
.photo-badge {
    align-self: flex-start; padding: 2px 10px; border-radius: 999px; border: 1px solid var(--gray);
    font-size: .75rem; letter-spacing: .06em; text-transform: uppercase; color: var(--muted);
}
.photo-badge-approved { border-color: #3d5c48; color: #9fd3ae; }
.photo-badge-pending { border-color: var(--gold); color: var(--gold); }
.photo-badge-hidden, .photo-badge-rejected { border-color: var(--red); color: #f0a3a6; }
.photo-note { font-size: .85rem; }
.photo-edit { display: grid; gap: 6px; }
.photo-edit input[name="caption"] { margin: 0; }
.photo-edit .check { font-size: .9rem; font-weight: 500; }
.photo-edit .btn, .photo-tile form .btn { margin-top: 0; }
.photo-mod { display: flex; flex-wrap: wrap; gap: 6px; }
.photo-flag { color: #f0a3a6; font-weight: 700; font-size: .9rem; }
.photo-reasons { margin: 0; padding-left: 1.1rem; font-size: .85rem; color: var(--muted); }
.photo-report summary { cursor: pointer; color: var(--muted); font-size: .85rem; }
.photo-reported { font-size: .85rem; }
.photo-share-check { margin-top: 12px; }
.photo-limit { margin-top: .6rem; font-size: .85rem; }
.photo-modes { border: 0; padding: 0; margin: 0 0 .6rem; display: grid; gap: 10px; }
.photo-mode { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border: 1px solid var(--line); border-radius: 8px; font-weight: 400; cursor: pointer; }
.photo-mode input { width: auto; margin-top: 5px; }
.photo-mode:has(input:checked) { border-color: var(--gold); background: rgba(230, 194, 122, .06); }
.photo-lightbox { max-width: min(96vw, 1100px); max-height: 94vh; padding: 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); color: var(--bone); }
.photo-lightbox::backdrop { background: rgba(0, 0, 0, .82); }
.photo-lightbox img { max-width: 100%; max-height: 78vh; margin: 0 auto; object-fit: contain; }
.photo-lightbox p { margin: .4rem 0 0; }
.photo-lightbox-credit { color: var(--muted); font-size: .9rem; }
.photo-lightbox-close { display: flex; justify-content: flex-end; margin-bottom: 8px; }
@media (max-width: 480px) {
    .photo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
}
