/* ---------- gallery page ---------- */

:root {
    --panel: #fbfaf8;
    --panel-line: rgba(17, 17, 17, 0.08);
    --muted: rgba(17, 17, 17, 0.5);
    --tile-shadow: 0 1px 3px rgba(20, 15, 30, 0.18);
    --head: rgba(248, 246, 243, 0.55);
    --head-line: rgba(17, 17, 17, 0.07);
    --tab-text: rgba(17, 17, 17, 0.62);
    --tab-on: rgba(255, 255, 255, 0.9);
    --tab-track: rgba(17, 17, 17, 0.05);
    --head-height: 68px;
    --swap: 0.35s; /* toggle ↔ close button cross-fade */
}

:root[data-theme="dark"] {
    --panel: #0c0b10;
    --panel-line: rgba(241, 239, 236, 0.1);
    --muted: rgba(241, 239, 236, 0.5);
    --tile-shadow: 0 1px 3px rgba(0, 0, 0, 0.45);
    --head: rgba(12, 10, 18, 0.45);
    --head-line: rgba(241, 239, 236, 0.08);
    --tab-text: rgba(241, 239, 236, 0.66);
    --tab-on: rgba(241, 239, 236, 0.16);
    --tab-track: rgba(241, 239, 236, 0.06);
}

/* Arriving from the splash page: the sky carries straight on, and once every
   photo is loaded the wall, the name and the toggle all fade in together */
.gallery-page .wall-plane,
.gallery-page .site-head,
.gallery-page .places,
.gallery-page .credit,
.gallery-page .wall-hint,
.gallery-page .theme-toggle {
    /* Not quite 0, so the browser draws everything before the fade begins */
    opacity: 0.001;
    transition: opacity 1.4s cubic-bezier(0.45, 0, 0.25, 1);
}

.gallery-page .wall-plane {
    will-change: opacity;
}

.gallery-page .theme-toggle {
    animation: none;
}

.gallery-page.is-arrived .wall-plane,
.gallery-page.is-arrived:not(.is-viewing) .site-head,
.gallery-page.is-arrived:not(.is-viewing) .credit,
.gallery-page.is-arrived:not(.is-viewing) .places,
.gallery-page.is-arrived:not(.is-viewing) .wall-hint:not(.is-gone),
.gallery-page.is-arrived:not(.is-viewing) .theme-toggle {
    opacity: 1;
}

/* Once the gallery has arrived, the header, places and toggle step aside and
   come back on the same quick timing as the close button, so they cross-fade */
.gallery-page.is-settled .site-head,
.gallery-page.is-settled .credit,
.gallery-page.is-settled .places,
.gallery-page.is-settled .theme-toggle {
    transition: opacity var(--swap) ease-in-out;
}

/* Closing instantly (going back on a phone): nothing animates for a moment */
.is-instant *,
.is-instant *::before,
.is-instant *::after {
    transition: none !important;
}

/* The theme toggle sits above the wall so it can be clicked */
.gallery-page .theme-toggle {
    z-index: 3;
}

/* Switching tabs: the wall fades out, rearranges, and fades back in */
.gallery-page.is-arrived .wall.is-switching .wall-plane {
    opacity: 0;
    transition-duration: 0.35s;
}

/* Small fixed labels around the wall */
.site-head,
.wall-hint {
    position: fixed;
    z-index: 2;
    margin: 0;
    transition: opacity 0.6s var(--ease);
}

.site-head {
    /* A frosted bar across the top: name on the left, places in the middle,
       the theme toggle on the right (it sits over the bar's right end) */
    top: 0;
    left: 0;
    right: 0;
    min-height: var(--head-height);
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 16px;
    padding: env(safe-area-inset-top, 0px) max(24px, env(safe-area-inset-right, 0px)) 0 max(24px, env(safe-area-inset-left, 0px));
    background: var(--head);
    -webkit-backdrop-filter: blur(22px) saturate(140%);
    backdrop-filter: blur(22px) saturate(140%);
    border-bottom: 1px solid var(--head-line);
}

/* The toggle lines up inside the bar */
.gallery-page .theme-toggle {
    top: calc(env(safe-area-inset-top, 0px) + (var(--head-height) - 40px) / 2);
    right: max(20px, env(safe-area-inset-right, 0px));
}

.site-mark {
    flex: none;
    /* Only the letters are clickable, not the rest of the header's column */
    justify-self: start;
    line-height: 1;
    color: var(--red);
    font-family: 'Vogue', Didot, 'Bodoni 72', serif;
    font-size: 18px;
    letter-spacing: 0.04em;
    text-decoration: none;
}

.wall-hint {
    bottom: max(22px, env(safe-area-inset-bottom));
    color: var(--muted);
    font-size: 13px;
    letter-spacing: 0.02em;
    pointer-events: none;
}

.wall-hint {
    left: max(24px, env(safe-area-inset-left));
}

.wall-hint.is-gone {
    opacity: 0;
}

/* ---------- credit, loading, first-visit hint ---------- */

.gallery-page .credit {
    right: max(24px, env(safe-area-inset-right, 0px));
    transform: none;
    animation: none;
}

/* Loading: a hazy line of slits that shimmer, shown only if the photos take a
   moment (it fades in after a short wait, and away as the wall arrives) */
.loading {
    position: fixed;
    z-index: 2;
    top: 50%;
    left: 50%;
    width: 160px;
    transform: translate(-50%, -50%);
    color: var(--ink);
    opacity: 0;
    pointer-events: none;
    animation: loading-in 0.8s var(--ease) 0.7s forwards;
}

.loading svg {
    display: block;
    width: 100%;
    height: 4px;
    overflow: visible;
    stroke: currentColor;
    stroke-width: 1.2;
    stroke-linecap: round;
}

.loading line {
    opacity: 0.15;
    animation: loading-shimmer 1.6s ease-in-out infinite;
}

.loading line:nth-child(2) { animation-delay: 0.12s; }
.loading line:nth-child(3) { animation-delay: 0.24s; }
.loading line:nth-child(4) { animation-delay: 0.36s; }
.loading line:nth-child(5) { animation-delay: 0.48s; }
.loading line:nth-child(6) { animation-delay: 0.6s; }
.loading line:nth-child(7) { animation-delay: 0.72s; }

@keyframes loading-in {
    to { opacity: 0.7; }
}

@keyframes loading-shimmer {
    0%, 100% { opacity: 0.12; }
    40%      { opacity: 0.9; }
}

.is-arrived .loading {
    animation: none;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s var(--ease), visibility 0s 0.4s;
}

/* First visit on a phone: a frosted note at the bottom, shown once */
.touch-hint {
    position: fixed;
    z-index: 3;
    left: 50%;
    bottom: calc(env(safe-area-inset-bottom, 0px) + 96px);
    margin: 0;
    padding: 12px 18px;
    border: 1px solid var(--head-line);
    border-radius: 999px;
    background: var(--head);
    -webkit-backdrop-filter: blur(22px) saturate(140%);
    backdrop-filter: blur(22px) saturate(140%);
    color: var(--ink);
    font: 14px/1 var(--sans);
    white-space: nowrap;
    opacity: 0;
    transform: translate(-50%, 10px);
    transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
    pointer-events: none;
}

.touch-hint[hidden] {
    display: none;
}

.touch-hint.is-showing {
    opacity: 1;
    transform: translate(-50%, 0);
}

/* ---------- places filter ---------- */

.places {
    /* Sits in the header right after the name, centred on the header's height
       (gallery.js measures where the name ends) */
    position: fixed;
    z-index: 3;
    top: var(--head-centre, 34px);
    left: var(--places-left, 180px);
    /* Centred on the title's capital letters (which sit high in their line),
       not on its line box, so the two read as level */
    transform: translateY(calc(-50% - 2px));
}

.places-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 14px 9px 16px;
    border: 1px solid var(--head-line);
    border-radius: 999px;
    background: var(--head);
    -webkit-backdrop-filter: blur(22px) saturate(140%);
    backdrop-filter: blur(22px) saturate(140%);
    color: var(--ink);
    font: 500 13px/1 var(--sans);
    letter-spacing: 0.01em;
    cursor: pointer;
}

.places-button svg {
    width: 12px;
    height: 12px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-linejoin: round;
    opacity: 0.6;
    transition: transform 0.3s var(--ease);
}

.places-button[aria-expanded="true"] svg {
    transform: rotate(180deg);
}

.places-button:focus-visible,
.places-menu button:focus-visible {
    outline: 2px solid var(--ink);
    outline-offset: 2px;
}

/* The menu: a frosted panel under the button (a sheet from the bottom on phones) */
.places-menu {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    min-width: 180px;
    /* Never taller than the screen; scrolls if there are ever many places */
    max-height: calc(100svh - var(--head-bottom, 68px) - 16px);
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 6px;
    border: 1px solid var(--head-line);
    border-radius: 18px;
    /* More solid than the header, so photos behind never compete with the names */
    background: rgba(16, 14, 22, 0.86);
    -webkit-backdrop-filter: blur(28px) saturate(150%);
    backdrop-filter: blur(28px) saturate(150%);
    box-shadow: 0 20px 50px -20px rgba(0, 0, 0, 0.45);
    opacity: 0;
    transform: translateY(-6px) scale(0.98);
    transform-origin: top left;
    transition: opacity 0.25s var(--ease), transform 0.35s cubic-bezier(0.3, 1.3, 0.5, 1);
}

.places-menu[hidden] {
    display: none;
}

.is-choosing .places-menu {
    opacity: 1;
    transform: none;
}

.places-menu button {
    display: grid;
    grid-template-columns: 1fr;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 11px 12px;
    border: 0;
    border-radius: 12px;
    background: none;
    color: var(--ink);
    font: 14px/1 var(--sans);
    text-align: left;
    cursor: pointer;
    transition: background-color 0.2s var(--ease);
}

.places-menu button[aria-checked="true"] {
    background: var(--tab-on);
}

@media (hover: hover) {
    .places-menu button:hover {
        background: var(--tab-track);
    }

    .places-menu button[aria-checked="true"]:hover {
        background: var(--tab-on);
    }
}

.places-scrim {
    position: fixed;
    inset: 0;
    z-index: 2;
}

.places-scrim[hidden] {
    display: none;
}


/* ---------- the wall ---------- */

.wall {
    /* A real scrolling area: native (full refresh rate) dragging on touch screens
       and trackpads, with the browser's own momentum */
    position: fixed;
    inset: 0;
    z-index: 1;
    overflow: scroll;
    overscroll-behavior: none;
    scrollbar-width: none;
    cursor: grab;
    user-select: none;
    -webkit-user-select: none;
}

.wall::-webkit-scrollbar {
    display: none;
}

.wall.is-dragging {
    cursor: grabbing;
}

.wall-plane {
    position: relative;
}

/* Only the photo itself responds to the mouse, not the empty space around it */
.tile {
    pointer-events: none;
    position: absolute;
    top: 0;
    left: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0;
    border: 0;
    background: none;
    color: inherit;
    font: inherit;
    cursor: inherit;
}

/* On the wall every photo is black and white (a real b&w copy, so the browser
   has nothing to convert); hovering fades the colour version in over it */
.tile-photo {
    position: relative;
    display: block;
    box-shadow: var(--tile-shadow);
    transition: transform 0.5s var(--ease);
    pointer-events: auto;
}

.tile-photo img {
    display: block;
    width: 100%;
    height: 100%;
    -webkit-user-drag: none;
}

/* Photos that are only black and white have no colour version to show */
.tile-photo .tile-colour[hidden] {
    display: none;
}

.tile-colour {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.5s var(--ease);
}

/* Hovering a photo: it lifts slightly and its name appears underneath */
.tile-label {
    position: absolute;
    left: 50%;
    bottom: 4px;
    transform: translate(-50%, 4px);
    padding: 3px 9px;
    border-radius: 999px;
    background: var(--panel);
    color: var(--ink);
    font-size: 11px;
    letter-spacing: 0.02em;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s var(--ease), transform 0.3s var(--ease);
}

@media (hover: hover) {
    .wall:not(.is-dragging) .tile:hover .tile-photo {
        transform: scale(1.03);
    }

    .wall:not(.is-dragging) .tile:hover .tile-colour {
        opacity: 1;
    }

    .wall:not(.is-dragging) .tile:hover .tile-label {
        opacity: 1;
        transform: translate(-50%, 0);
    }
}

.tile:focus-visible {
    outline: none;
}

.tile:focus-visible .tile-photo {
    outline: 2px solid var(--ink);
    outline-offset: 4px;
}

/* The photo being opened stays hidden in the wall while it's in the viewer */
.tile.is-lifted .tile-photo {
    visibility: hidden;
}

/* ---------- the viewer ---------- */

.viewer {
    position: fixed;
    inset: 0;
    z-index: 10;
}

.viewer[hidden] {
    display: none;
}

.viewer-stage {
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: var(--panel-width);
    background: transparent;
}

/* The dark backdrop covers the whole screen, including the strip the details
   panel slides across. Only the backdrop fades; the photo stays solid in flight. */
.viewer::before {
    content: "";
    position: absolute;
    inset: 0;
    background: var(--bg);
    opacity: 0;
    transition: opacity 0.6s var(--ease);
    pointer-events: none;
}

.viewer.is-open::before {
    opacity: 1;
}

.viewer.is-zoomed-in .viewer-stage {
    overflow: hidden;
}

.viewer-img {
    position: absolute;
    display: block;
    max-width: none;
    transform-origin: 0 0;
    cursor: zoom-in;
    -webkit-user-drag: none;
}

.viewer-img.is-flying {
    transition: transform 0.8s cubic-bezier(0.22, 0.8, 0.2, 1), opacity 0.3s var(--ease), filter 0.8s var(--ease);
}

.viewer-img.is-swapping {
    opacity: 0;
    transition: opacity 0.2s var(--ease);
}

/* Clicking the photo zooms into it; the zoomed view follows the mouse */
.viewer-img.is-zoomed {
    cursor: zoom-out;
    transition: transform 0.6s cubic-bezier(0.22, 0.8, 0.2, 1), transform-origin 0.25s linear;
}

.viewer-img.is-unzooming {
    transition: transform 0.5s cubic-bezier(0.22, 0.8, 0.2, 1);
}

.viewer {
    --panel-width: clamp(300px, 28vw, 420px);
}

.viewer-panel {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: var(--panel-width);
    display: flex;
    flex-direction: column;
    gap: 24px;
    padding: 40px 36px 28px;
    background: var(--panel);
    border-left: 1px solid var(--panel-line);
    color: var(--ink);
    transform: translateX(100%);
    opacity: 0;
    /* Leaving: slides and fades at once, finishing before the photo lands */
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.6, 1), opacity 0.4s var(--ease);
}

/* The wall stays visible around the flying photo, so it can land in place */
.viewer:not(.is-open) .viewer-panel {
    pointer-events: none;
}

.viewer.is-open .viewer-panel {
    transform: none;
    opacity: 1;
    transition: transform 0.7s cubic-bezier(0.22, 0.8, 0.2, 1), opacity 0.5s var(--ease);
}

.viewer-close {
    /* Same size, place and circle as the theme toggle, so opening a photo looks
       like the toggle turning into a close button */
    position: absolute;
    z-index: 2;
    top: calc(env(safe-area-inset-top, 0px) + (var(--head-height) - 40px) / 2);
    right: max(20px, env(safe-area-inset-right, 0px));
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    padding: 0;
    border: 1.25px solid var(--toggle-line);
    border-radius: 50%;
    background: var(--toggle-track);
    color: var(--ink);
    cursor: pointer;
    transition: color 0.3s var(--ease), background-color 0.3s var(--ease);
}

.viewer-close svg {
    width: 14px;
    height: 14px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.4;
    stroke-linecap: round;
}

.viewer-close {
    opacity: 0;
    /* Cross-fades with the theme toggle underneath it, on the same timing */
    transition: opacity var(--swap) ease-in-out, color 0.3s var(--ease), background-color 0.3s var(--ease);
}

.viewer.is-open .viewer-close {
    opacity: 1;
}

.viewer-close:hover {
    color: var(--ink);
    background: var(--panel-line);
}

.viewer-close:focus-visible,
.viewer-strip button:focus-visible {
    outline: 2px solid var(--ink);
    outline-offset: 2px;
}

/* Thumbnails of every photo, for jumping between them */
.viewer-strip {
    display: flex;
    gap: 8px;
    margin: 0 -36px;
    padding: 0 36px 4px;
    overflow-x: auto;
    scrollbar-width: none;
}

.viewer-strip::-webkit-scrollbar {
    display: none;
}

.viewer-strip button {
    flex: none;
    width: 56px;
    height: 72px;
    padding: 0;
    border: 0;
    background: none;
    cursor: pointer;
    opacity: 0.45;
    transition: opacity 0.3s var(--ease);
}

.viewer-strip button:hover,
.viewer-strip button[aria-current="true"] {
    opacity: 1;
}

.viewer-strip img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.viewer-heading {
    /* Sits in the middle of the panel; the reel is pinned to the bottom */
    margin: auto 0;
}

.viewer-meta {
    margin: 0 0 14px;
    color: var(--muted);
    font-size: 12px;
    letter-spacing: 0.02em;
}

.viewer-title {
    margin: 0;
    font-family: 'Vogue', Didot, 'Bodoni 72', serif;
    font-size: clamp(30px, 2.8vw, 44px);
    font-weight: normal;
    line-height: 1.05;
    letter-spacing: 0.01em;
    text-wrap: balance;
}

.viewer-foot {
    display: grid;
    gap: 18px;
}

.viewer-specs {
    display: grid;
    gap: 8px;
    margin: 14px 0 0; /* the same gap as between the date and the title */
    font-size: 13px;
}

.viewer-specs div {
    display: grid;
    grid-template-columns: 76px 1fr;
    gap: 12px;
}

.viewer-specs dt {
    color: var(--muted);
}

.viewer-specs dd {
    margin: 0;
    font-variant-numeric: tabular-nums;
}

.viewer-share {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 22px;
    padding: 9px 15px;
    border: 1px solid var(--panel-line);
    border-radius: 999px;
    background: none;
    color: var(--ink);
    font: 500 13px/1 var(--sans);
    cursor: pointer;
    transition: background-color 0.3s var(--ease);
}

.viewer-share svg {
    width: 14px;
    height: 14px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.4;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.viewer-share:focus-visible {
    outline: 2px solid var(--ink);
    outline-offset: 2px;
}

@media (hover: hover) {
    .viewer-share:hover {
        background: var(--panel-line);
    }
}

.viewer-count {
    margin: 0;
    color: var(--muted);
    font-size: 12px;
    font-variant-numeric: tabular-nums;
}

/* Text changes when moving to another photo */
.viewer-panel .is-fading {
    opacity: 0;
    transition: opacity 0.2s var(--ease);
}

.viewer-heading,
.viewer-count {
    transition: opacity 0.4s var(--ease);
}

/* While a photo is open, the labels around the wall step back */
.is-viewing .site-head,
.is-viewing .places,
.is-viewing .credit,
.is-viewing .wall-hint,
.is-viewing .theme-toggle {
    opacity: 0;
    pointer-events: none;
}

/* ---------- phones: photo on top, scroll down for the details ---------- */

/* Phones and upright tablets: the open photo sits on top, details scroll below
   (gallery.js uses the same test, see "stacked") */
@media (orientation: portrait) and (max-width: 1100px) {
    .viewer {
        --panel-width: 0px;
        overflow-y: auto;
        overscroll-behavior: contain;
    }

    /* The backdrop stays put while the photo and details scroll */
    .viewer::before {
        position: fixed;
    }

    .viewer-stage {
        position: relative;
        right: auto;
        width: 100%;
        height: var(--stage-height, 80svh);
        overflow: visible;
        background: none;
    }

    .viewer-img {
        cursor: default;
    }

    /* Up and down scrolls to the details; sideways swipes between photos */
    .viewer-stage {
        touch-action: pan-y;
    }

    .viewer-panel {
        position: relative;
        width: auto;
        min-height: 60svh;
        display: flex;
        flex-direction: column;
        gap: 28px;
        padding: 8px max(20px, env(safe-area-inset-left)) max(40px, env(safe-area-inset-bottom));
        border-left: 0;
        background: var(--bg);
        transform: translateY(24px);
        opacity: 0;
        transition: transform 0.4s var(--ease), opacity 0.35s var(--ease);
    }

    .viewer.is-open .viewer-panel {
        opacity: 1;
        transition: transform 0.7s cubic-bezier(0.22, 0.8, 0.2, 1) 0.15s, opacity 0.5s var(--ease) 0.15s;
    }

    .viewer-heading {
        margin: 0;
    }

    .viewer-strip {
        margin: 0 calc(-1 * max(20px, env(safe-area-inset-left)));
        padding: 0 max(20px, env(safe-area-inset-left)) 6px;
    }

    .viewer-close {
        position: fixed;
        top: calc(env(safe-area-inset-top, 0px) + 14px);
        z-index: 1;
        width: 32px;
        height: 32px;
        border-width: 1px;
    }

    .viewer.is-open .viewer-close {
        opacity: 1;
    }
}

/* Short screens, like a phone on its side: a slimmer header, and a narrower
   details panel that fits the screen without scrolling */
@media (max-height: 560px) and (orientation: landscape) {
    :root {
        --head-height: 52px;
    }

    .site-mark {
        font-size: 16px;
    }



    .places-button {
        padding: 7px 12px 7px 14px;
    }

    .places-menu button {
        padding: 8px 12px;
        font-size: 14px;
    }

    .viewer {
        --panel-width: clamp(250px, 32vw, 320px);
    }

    .viewer-panel {
        gap: 12px;
        padding: 16px max(22px, env(safe-area-inset-right, 0px)) 14px 22px;
        overflow-y: auto;
        overscroll-behavior: contain;
    }

    .viewer-heading {
        margin: auto 0;
        padding-top: 30px; /* clear of the close button */
    }

    .viewer-meta {
        margin-bottom: 8px;
        font-size: 11px;
    }

    .viewer-title {
        font-size: 26px;
    }

    .viewer-specs {
        margin-top: 8px;
        gap: 4px;
        font-size: 12px;
    }

    .viewer-specs div {
        grid-template-columns: 70px 1fr;
    }

    .viewer-share {
        margin-top: 12px;
        padding: 7px 12px;
        font-size: 12px;
    }

    .viewer-foot {
        gap: 8px;
    }

    .viewer-strip {
        margin: 0 -22px;
        padding: 0 22px 2px;
    }

    .viewer-strip button {
        width: 40px;
        height: 52px;
    }

    .viewer-close {
        width: 32px;
        height: 32px;
        top: calc(env(safe-area-inset-top, 0px) + 10px);
        right: max(14px, env(safe-area-inset-right, 0px));
    }
}

/* The shortest screens (smaller phones on their side) */
@media (max-height: 360px) and (orientation: landscape) {
    .viewer-panel {
        gap: 8px;
        padding-top: 12px;
        padding-bottom: 10px;
    }

    .viewer-heading {
        padding-top: 26px;
    }

    .viewer-title {
        font-size: 24px;
    }

    .viewer-specs {
        gap: 2px;
    }

    .viewer-share {
        margin-top: 10px;
    }
}

/* Touch screens have no "drag" to explain; the one-time hint covers it */
@media (hover: none) {
    .wall-hint {
        display: none;
    }
}

@media (max-width: 760px) {


    /* Phones get the same dropdown as computers, with bigger rows to tap */
    .places-menu {
        min-width: min(220px, calc(100vw - var(--places-left, 160px) - 10px));
        border-radius: 20px;
    }

    .places-menu button {
        padding: 14px 14px;
        font-size: 16px;
    }

    .site-mark {
        font-size: 18px;
    }

    /* A slimmer filter pill, so it sits level with the name as one row */
    .places-button {
        gap: 6px;
        padding: 6px 11px 6px 13px;
        font-size: 12px;
    }

    /* Phones: one row: name, then Gallery · About, then the toggle */
    .site-head {
        --head-height: 60px;
        grid-template-columns: auto 1fr;
        gap: 10px;
    }


    .gallery-page .theme-toggle {
        top: calc(env(safe-area-inset-top, 0px) + 14px);
        width: 32px;
        height: 32px;
    }

    .gallery-page .theme-toggle svg {
        width: 32px;
        height: 32px;
    }

    .wall-hint {
        display: none;
    }
}

