/* Klicker Photos' one stylesheet (chao, 2026-12-05): white and #76C3D7, Noto Sans; the layout is direction A's (D15).
   #76C3D7 on white is about 2:1, so it is a fill and an accent with dark ink on it; links and small coloured text are
   --link (#1f6b80, 6:1 on white). The font is served with the page (public/fonts, OFL): only latin 400/600/700, no
   other site contacted; other scripts fall back to the system's fonts. */
@font-face { font-family: "Noto Sans"; font-style: normal; font-weight: 400; font-display: swap;
  src: url(/fonts/noto-sans-latin-400-normal.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153,
  U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Noto Sans"; font-style: normal; font-weight: 600; font-display: swap;
  src: url(/fonts/noto-sans-latin-600-normal.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153,
  U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Noto Sans"; font-style: normal; font-weight: 700; font-display: swap;
  src: url(/fonts/noto-sans-latin-700-normal.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153,
  U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
:root {
  --bg: #ffffff; --card: #ffffff; --tint: #f2f9fb; --ink: #1b2a30; --muted: #5a6870; --line: #dcebf0; --field: #b9d3dc;
  --accent: #76c3d7; --accent-dark: #5fb3c9; --accent-soft: #e3f3f8; --link: #1f6b80; --on-accent: #1b2a30;
  --ok: #2f7a4a; --warn-bg: #fdf3dc; --warn: #7a4e0c; --bad: #b0321c; --bad-bg: #fbe3dd;
  --sans: "Noto Sans", system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans CJK SC", sans-serif;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 17px/1.55 var(--sans); }
h1, h2, .mark { font-weight: 700; letter-spacing: -0.015em; }
h1 { font-size: 2rem; line-height: 1.15; margin: 0 0 1rem; }
h2 { font-size: 1.35rem; line-height: 1.25; margin: 0 0 .4rem; }
p { margin: 0 0 .8rem; }
a { color: var(--link); }
.muted { color: var(--muted); }
.hint { color: var(--muted); font-size: .9rem; }
:focus-visible { outline: 3px solid var(--link); outline-offset: 2px; }

/* controls */
label.f { display: block; font-weight: 600; font-size: .95rem; margin: 0 0 .35rem; }
input, select { font: inherit; color: inherit; background: #fff; border: 1px solid var(--field); border-radius: 10px;
  padding: .65rem .8rem; width: 100%; min-height: 2.9rem; }
input:focus, select:focus { border-color: var(--accent); outline: 3px solid var(--accent-soft); outline-offset: 0; }
select { appearance: none; padding-right: 2.4rem; text-overflow: ellipsis;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%235a6870' stroke-width='2'/%3E%3C/svg%3E") no-repeat right .9rem center; }
select:disabled, input:disabled { background-color: #f1f5f7; color: var(--muted); }
button, .button { font: inherit; font-weight: 600; border-radius: 10px; padding: .7rem 1.2rem; border: 1px solid var(--field);
  background: var(--card); color: var(--ink); cursor: pointer; display: inline-block; line-height: 1.3; }
button:hover, .button:hover { border-color: #8fb6c3; }
button.primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
button.primary:hover { background: var(--accent-dark); border-color: var(--accent-dark); }
button:disabled { opacity: .6; cursor: default; }
button.wide { width: 100%; }
button.link { border: 0; background: none; padding: 0; color: var(--link); font-weight: 600; border-radius: 3px; }
button.link:hover { text-decoration: underline; }
.inline { display: flex; gap: .6rem; align-items: end; flex-wrap: wrap; margin: 0 0 1rem; }
.inline > div { flex: 1 1 12rem; }
.inline > div.narrow { flex: 0 1 8rem; }

/* messages */
.loading { text-align: center; color: var(--muted); margin-top: 30vh; }
.error { color: var(--bad); font-weight: 600; margin: .8rem 0 0; }
.error:empty, .note:empty, .toast:empty { display: none; }
.note { background: var(--warn-bg); color: var(--warn); border-radius: 12px; padding: .8rem 1rem; font-weight: 600; }
.toast { position: fixed; left: 50%; bottom: 1.2rem; transform: translateX(-50%); max-width: min(34rem, calc(100% - 2rem));
  margin: 0; background: var(--ink); color: #fff; padding: .7rem 1.1rem; border-radius: 12px;
  box-shadow: 0 6px 20px rgba(15, 40, 50, .25); font-size: .95rem; z-index: 10; }

/* the wordmark: a little stack of prints, in the theme's blues (--mark-a over --mark-b, a print's edge behind) */
.mark { --mark-a: var(--accent); --mark-b: var(--link); --mark-gap: var(--card);
  font-size: 1.3rem; color: var(--ink); white-space: nowrap; }
.mark::before { content: ""; display: inline-block; width: .85em; height: .7em; margin-right: .45em; border-radius: 2px;
  background: linear-gradient(var(--mark-a) 0 50%, var(--mark-b) 50%); box-shadow: 3px -3px 0 -1px var(--mark-gap), 3px -3px 0 0 var(--mark-b);
  transform: rotate(-6deg); }

/* top bar, a band of the theme colour with dark ink: the wordmark (home: the albums), who, Admin (admins), Sign out.
   One line at any width: the address gives way first (hidden on a phone), the two links never wrap. */
.top { background: var(--accent); color: var(--on-accent); }
.top .in { max-width: 960px; margin: 0 auto; padding: 0 1.25rem; }
.top .row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 3.6rem; }
.top .mark { --mark-a: #fff; --mark-b: var(--on-accent); --mark-gap: var(--accent); color: var(--on-accent); flex: none; }
.who { font-size: .92rem; display: flex; gap: 1.1rem; align-items: baseline; min-width: 0; }
.who #who { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.who button, .who a { white-space: nowrap; flex: none; color: var(--on-accent); font-weight: 600; text-decoration: none; }
.who a:hover, .who button:hover { text-decoration: underline; }
.who a[aria-current="page"] { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 4px; }
.top :focus-visible { outline-color: var(--on-accent); }
a.mark { text-decoration: none; }

.col { max-width: 960px; margin: 0 auto; padding: 1.8rem 1.25rem 4rem; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 1.4rem; margin-bottom: 1.25rem;
  box-shadow: 0 1px 2px rgba(15, 40, 50, .05); }

/* sign-in */
.signin-wrap { max-width: 1000px; margin: 0 auto; padding: 2.2rem 1.25rem 3rem; display: grid; gap: 2rem; }
.signin-wrap .card { padding: 1.6rem; margin: 0; }
.signin-wrap .card .primary { margin: 1rem 0 .9rem; }
.signin-wrap .hint { margin: 0; }
.intro .mark { display: block; margin-bottom: 1.4rem; }
.intro h1 { margin-bottom: .7rem; }
.intro p { font-size: 1.08rem; }
.intro .for { font-size: .98rem; color: var(--muted); border-left: 3px solid var(--accent); padding-left: .8rem; }
input.code { font-size: 1.5rem; letter-spacing: .3em; text-align: center; font-variant-numeric: tabular-nums; }
.links { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .6rem; margin: 0; font-size: .95rem; }
.stack { position: relative; height: 150px; margin: 0 0 1.4rem 8px; }
.stack .ph { position: absolute; width: 150px; height: 112px; border: 7px solid #fff; border-bottom-width: 22px; border-radius: 3px;
  box-shadow: 0 6px 16px rgba(15, 40, 50, .18); }
.stack .ph:nth-child(1) { transform: rotate(-7deg); left: 0; top: 14px; }
.stack .ph:nth-child(2) { transform: rotate(4deg); left: 95px; top: 2px; }
.stack .ph:nth-child(3) { transform: rotate(-2deg); left: 185px; top: 20px; }
.p1 { background: radial-gradient(circle at 70% 30%, #ffe8a8 0 8%, transparent 9%), linear-gradient(#8ec5e8 0 45%, #2f7fa8 45% 62%, #e9d3a3 62%); }
.p2 { background: radial-gradient(ellipse at 30% 110%, #2d5a3a 0 45%, transparent 46%), linear-gradient(#f6b26b, #e07a5f 55%, #6b3e5e); }
.p7 { background: radial-gradient(circle at 35% 40%, #e85d4a 0 12%, transparent 13%), radial-gradient(circle at 62% 58%, #f2c14e 0 10%, transparent 11%), linear-gradient(#7fae6b, #4d7d42); }
@media (min-width: 900px) {
  .signin-wrap { grid-template-columns: 1.15fr 1fr; align-items: center; min-height: 100vh; padding-top: 2rem; padding-bottom: 2rem; gap: 4rem; }
  .intro h1 { font-size: 2.6rem; }
  .stack { height: 190px; } .stack .ph { width: 190px; height: 140px; }
  .stack .ph:nth-child(2) { left: 125px; } .stack .ph:nth-child(3) { left: 245px; }
}

/* adding photos */
.drop { border: 2px dashed #9fcfdd; background: var(--tint); border-radius: 14px; text-align: center; padding: 2.2rem 1rem; margin-top: 1.1rem;
  transition: background .15s, border-color .15s; }
/* A touch screen picks photos, a computer drops or chooses a folder (index.html, D51). */
@media not (pointer: coarse) { .on-touch { display: none !important; } }
@media (pointer: coarse) { .on-computer { display: none !important; } }
.drop.over { background: var(--accent-soft); border-color: var(--accent); }
.drop .big { font-size: 1.3rem; font-weight: 700; margin-bottom: .3rem; }
.drop .or { margin: 0; }
.drop .button { margin: .6rem 0 .9rem; }
.drop .hint { margin: 0 auto; max-width: 30rem; }
.drop .icon { width: 52px; height: 40px; margin: 0 auto .9rem; border-radius: 4px; background: var(--accent-soft); position: relative; }
.drop .icon::before { content: ""; position: absolute; left: 6px; top: -7px; width: 20px; height: 9px; border-radius: 3px 3px 0 0; background: var(--accent-soft); }
.drop .icon::after { content: "+"; position: absolute; inset: 0; display: grid; place-items: center; color: var(--link); font: 700 1.6rem/1 var(--sans); }
.summary:empty, #upload-warnings:empty { display: none; }
.summary { margin-top: 1.1rem; }
/* while sending the drop area is hidden: no gap above the summary but the card's own padding */
.drop[hidden] + .summary { margin-top: 0; }
.summary .lead { font-size: 1.1rem; margin-bottom: .4rem; }
.summary .facts { margin: 0 0 .8rem; padding-left: 1.2rem; color: var(--muted); }
#upload-warnings details { background: var(--warn-bg); color: var(--warn); border-radius: 10px; padding: .6rem .9rem; margin: 0 0 .8rem; font-size: .95rem; }
#upload-warnings summary { font-weight: 600; cursor: pointer; }
#upload-warnings details div { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: .82rem; margin-top: .3rem; overflow-wrap: anywhere; }
.progress { height: 10px; background: var(--accent-soft); border-radius: 99px; overflow: hidden; margin: .6rem 0 .2rem; }
.progress span { display: block; height: 100%; width: 0; background: var(--accent); border-radius: 99px; transition: width .3s; }
.progress.complete span { background: var(--ok); }
.send-row { display: flex; flex-wrap: wrap; gap: .5rem 1rem; align-items: center; margin: .6rem 0 0; }
.send-row:has(#send[hidden]):has(#send-status:empty) { display: none; }
#send-status:empty { display: none; }
#send-status.all { color: var(--ok); font-weight: 600; }
.notes { list-style: none; padding: 0; margin: 1.5rem 0 0; font-size: .95rem; color: var(--muted); }
.notes li { padding-left: 1.4rem; position: relative; margin-bottom: .35rem; }
.notes li::before { content: "✓"; position: absolute; left: 0; color: var(--ok); font-weight: 700; }

/* previews: prints with a state badge */
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 1rem; }
.tiles:empty { display: none; }
.tile { margin: 0; background: var(--card); padding: 6px 6px 8px; border-radius: 6px; box-shadow: 0 1px 3px rgba(15, 40, 50, .14); position: relative; }
.tile .sq { aspect-ratio: 1; overflow: hidden; border-radius: 3px; background: #e6f0f3; }
/* a grid tile's picture is a button opening the large view */
.tile button.sq { display: block; width: 100%; padding: 0; border: 0; font: inherit; cursor: zoom-in; }
.tile button.sq:hover img { filter: brightness(1.06); }
.tile img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tile figcaption { padding: .45rem .15rem 0; font-size: .82rem; line-height: 1.35; }
.tile .name { display: block; font-weight: 600; overflow-wrap: anywhere; }
.tile .meta { display: block; color: var(--muted); }
.tile .flag { color: var(--warn); }
.tile .err { display: block; color: var(--bad); }
.tile .state { position: absolute; left: 12px; top: 12px; max-width: calc(100% - 24px);
  font-size: .72rem; font-weight: 700; line-height: 1.3; padding: .15rem .5rem; border-radius: 99px;
  background: rgba(255, 255, 255, .93); color: var(--muted); box-shadow: 0 1px 2px rgba(0, 0, 0, .15); }
.tile .state:empty { display: none; }
.tile.done .state, .tile.already .state { background: var(--ok); color: #fff; }
.tile.already .state::before { content: "✓ "; }
/* a photo sent: a tick alone (upload.ts), its word for screen readers */
.tile.done .state { width: 28px; height: 28px; padding: 0; display: grid; place-items: center; }
.tile.done .state svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.tile.sending .state, .tile.checking .state { background: var(--accent); color: var(--on-accent); }
.tile.failed .state { background: var(--bad); color: #fff; }
.tile.waiting .sq { filter: saturate(.6) brightness(1.04); }

/* the albums and an album's sections: one row each, the count on the right (browse.ts) */
.back { display: inline-block; font-weight: 600; text-decoration: none; margin: 0 0 .6rem; }
.back:hover { text-decoration: underline; }
.list { list-style: none; margin: 0; padding: 0; background: var(--card); border: 1px solid var(--line); border-radius: 14px;
  box-shadow: 0 1px 2px rgba(15, 40, 50, .05); overflow: hidden; }
.list:empty { display: none; }
.list li + li { border-top: 1px solid var(--line); }
.list .row { display: flex; align-items: baseline; gap: 1rem; padding: 1rem 1.25rem; color: var(--ink); text-decoration: none; }
.list .row:hover { background: var(--tint); }
.list .row::after { content: "›"; color: var(--muted); font-size: 1.3rem; line-height: 1; align-self: center; }
.list .name { flex: 1; font-weight: 600; font-size: 1.05rem; overflow-wrap: anywhere; }
.list .count { color: var(--muted); font-size: .95rem; white-space: nowrap; }
.list .empty { padding: 1rem 1.25rem; color: var(--muted); }

/* a section: its name and count, [Upload] on the right, then its photos (album.ts) */
.section-head { display: flex; align-items: flex-start; justify-content: space-between; gap: .6rem 1rem; margin: 0 0 .3rem; }
.section-head h1 { margin: 0; overflow-wrap: anywhere; }
.section-head .count { font-family: var(--sans); font-weight: 400; font-size: 1.1rem; color: var(--muted); white-space: nowrap; }
.section-head .count:not(:empty)::before { content: "– "; }
.section-head button { flex: none; margin-top: .2rem; }
#section #album-help { margin: 0 0 1rem; }
#section .more { text-align: center; margin: 1rem 0 0; }
#section .more:empty { display: none; }

/* the Upload pop-up over the grid (upload.ts): the whole screen on a phone, a wide panel on a computer */
.sheet { border: 0; padding: 0; background: var(--bg); color: var(--ink); width: min(56rem, calc(100vw - 2rem));
  max-height: calc(100vh - 2rem); border-radius: 16px; box-shadow: 0 12px 40px rgba(15, 40, 50, .3); }
.sheet[open] { display: flex; flex-direction: column; }
.sheet::backdrop { background: rgba(27, 42, 48, .5); }
.sheet-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1rem 1.25rem;
  background: var(--card); border-bottom: 1px solid var(--line); }
.sheet-head h2 { margin: 0; font-size: 1.25rem; overflow-wrap: anywhere; }
.sheet-head .close { flex: none; width: 40px; height: 40px; padding: 0; border-radius: 99px; font-size: 1.5rem; line-height: 1; }
.sheet-body { overflow-y: auto; padding: 1.25rem; }
.sheet-body .card { margin-bottom: 1rem; }
.sheet-body .drop { margin-top: 0; }

/* the large view (album.ts): the photo on a dark ground, its name and dates under it, the delete on the right;
   the whole screen on a phone */
.viewer { border: 0; padding: 0; background: #10191d; color: #fff; width: min(70rem, calc(100vw - 2rem));
  max-height: calc(100vh - 2rem); border-radius: 16px; overflow: hidden; box-shadow: 0 12px 40px rgba(0, 0, 0, .45); }
.viewer[open] { display: flex; flex-direction: column; }
.viewer::backdrop { background: rgba(10, 18, 22, .78); }
.viewer-pic { flex: 1 1 auto; min-height: 0; display: grid; place-items: center; padding: 3.2rem 1rem 1rem; }
.viewer-pic img { max-width: 100%; max-height: calc(100vh - 12rem); object-fit: contain; display: block; border-radius: 3px; }
.viewer-pic .plain { display: grid; place-items: center; width: min(28rem, 100%); aspect-ratio: 4 / 3; padding: 1rem;
  border-radius: 6px; background: #22313a; color: #c8d8de; font-weight: 600; overflow-wrap: anywhere; text-align: center; }
.viewer-bar { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem 1.2rem; padding: .9rem 1.25rem 1.1rem;
  background: #fff; color: var(--ink); }
.viewer-info { flex: 1 1 14rem; min-width: 0; }
.viewer-info h2 { font-size: 1.05rem; margin: 0 0 .15rem; overflow-wrap: anywhere; }
.viewer-info p { margin: 0; font-size: .92rem; color: var(--muted); }
.viewer-acts { flex: none; display: flex; align-items: center; }
.icon-btn { width: 44px; height: 44px; padding: 0; display: grid; place-items: center; border-radius: 99px; color: var(--bad); }
.icon-btn:hover { border-color: var(--bad); background: var(--bad-bg); }
.icon-btn svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.confirm { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.confirm span { font-weight: 600; margin-right: .3rem; }
.confirm button { padding: .5rem 1.1rem; }
.viewer-error { flex: 1 0 100%; margin: 0; color: var(--bad); font-weight: 600; font-size: .92rem; }
.viewer-error:empty { display: none; }
.viewer-close { position: absolute; top: .7rem; right: .7rem; width: 40px; height: 40px; padding: 0; border-radius: 99px;
  font-size: 1.5rem; line-height: 1; background: rgba(255, 255, 255, .92); border-color: transparent; color: var(--ink); }

/* the admin page */
.member { display: grid; gap: .5rem; padding: .9rem 0; border-top: 1px solid var(--line); }
.member .head { display: flex; justify-content: space-between; gap: .4rem .8rem; align-items: baseline; flex-wrap: wrap; }
.member .head strong { overflow-wrap: anywhere; }
.member .actions { display: flex; gap: .3rem 1rem; flex-wrap: wrap; }
.pill { font-size: .75rem; font-weight: 700; padding: .1rem .55rem; border-radius: 99px; background: #e9f1f4; color: var(--muted); margin-left: .4rem; white-space: nowrap; }
.pill.off { background: var(--bad-bg); color: var(--bad); }
.service-status { margin: 0 0 1rem; }
.service-status .why { display: block; margin-top: .35rem; color: var(--bad); }
#service-retry-row { margin: 0; }
.member.suspended .open-albums, .member.suspended .find { opacity: .55; }
.open-albums, .found { list-style: none; margin: 0; padding: 0; display: grid; gap: .35rem; }
.open-albums li, .found li { display: flex; align-items: center; justify-content: space-between; gap: .4rem .8rem;
  padding: .45rem .75rem; border-radius: 10px; min-height: 2.6rem; }
.open-albums li span, .found li span { overflow-wrap: anywhere; min-width: 0; }
.open-albums li { background: var(--accent-soft); border: 1px solid var(--accent); font-weight: 600; }
.open-albums li .name::before { content: "✓ "; color: var(--link); }
.open-albums li.gone { background: #fff; border-style: dashed; border-color: var(--field); color: var(--muted); font-weight: 400; }
.open-albums li.gone .name::before { content: ""; }
.open-albums button.link, .found button { flex: none; }
.open-none { margin: 0; }
.find { display: grid; gap: .35rem; max-width: 34rem; }
.find .f { margin: .2rem 0 0; }
.find input { width: 100%; }
.find .hint { margin: 0; }
.find .hint:empty { display: none; }
.found li { border: 1px solid var(--line); background: #fff; }
.found button.add { padding: .35rem 1rem; }
/* "Add an album": a combobox; its dropdown hangs under the box, scrolls inside itself, and fits a phone's width */
.combo { position: relative; }
.combo input { padding-right: 2.6rem; background: #fff no-repeat right .9rem center / .8rem
  url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%231f6b80' stroke-width='2'/%3E%3C/svg%3E"); }
.combo input[aria-expanded="true"] { border-color: var(--accent); }
.drop-panel { position: absolute; left: 0; right: 0; top: 100%; margin-top: .3rem; z-index: 5; background: #fff;
  border: 1px solid var(--field); border-radius: 10px; box-shadow: 0 8px 22px rgba(15, 40, 50, .16);
  max-height: min(18rem, 55vh); overflow-y: auto; overscroll-behavior: contain; }
.drop-panel[hidden] { display: none; }
.drop-panel ul { list-style: none; margin: 0; padding: .3rem 0; }
.drop-panel [role="option"] { padding: .62rem .95rem; cursor: pointer; overflow-wrap: anywhere; }
.drop-panel [role="option"]:hover { background: var(--tint); }
.drop-panel [role="option"][aria-selected="true"] { background: var(--accent-soft); box-shadow: inset 3px 0 0 var(--accent); }
.find .drop-panel .empty { margin: 0; padding: .75rem .95rem; }
/* the admin page's tabs: People, Albums */
.tabs { display: flex; gap: .3rem; margin: -.2rem 0 1.25rem; border-bottom: 1px solid var(--line); }
.tabs a { padding: .55rem 1rem; margin-bottom: -1px; font-weight: 600; color: var(--muted); text-decoration: none;
  border-bottom: 3px solid transparent; }
.tabs a:hover { color: var(--ink); }
.tabs a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--accent); }
/* the Albums tab: a row per album with its on/off switch */
.switches { list-style: none; margin: .9rem 0 0; padding: 0; display: grid; gap: .35rem; }
.switches li { display: flex; align-items: center; justify-content: space-between; gap: .4rem .8rem;
  padding: .45rem .75rem; border-radius: 10px; min-height: 2.9rem; border: 1px solid var(--line); background: #fff; }
.switches li.off { border-style: dashed; border-color: var(--field); color: var(--muted); }
.switches li > .name { display: flex; flex-wrap: wrap; align-items: center; gap: .15rem .5rem; overflow-wrap: anywhere;
  min-width: 0; }
.switches .group { padding: .6rem 0 .1rem; border: 0; background: none; min-height: 0; font-size: .85rem; font-weight: 700;
  color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
#album-switches + .hint { margin: .6rem 0 0; }
#album-switches + .hint:empty { display: none; }
button.switch { flex: none; display: inline-flex; align-items: center; gap: .5rem; padding: .3rem .2rem .3rem .6rem;
  background: none; border: 0; color: var(--muted); font-size: .9rem; font-weight: 600; min-height: 2.4rem; }
button.switch::after { content: ""; width: 2.6rem; height: 1.5rem; border-radius: 99px; background: #cfdde2;
  box-shadow: inset 0 0 0 2px #cfdde2; transition: background .15s;
  background-image: radial-gradient(circle at .75rem 50%, #fff .55rem, transparent .6rem); }
button.switch[aria-checked="true"] { color: var(--link); }
button.switch[aria-checked="true"]::after { background-color: var(--link); box-shadow: inset 0 0 0 2px var(--link);
  background-image: radial-gradient(circle at 1.85rem 50%, #fff .55rem, transparent .6rem); }
button.switch:disabled { opacity: .6; }
.open-albums li.off { background: #fff; border-style: dashed; border-color: var(--field); color: var(--muted); font-weight: 400; }
.open-albums li.off .name { display: flex; flex-wrap: wrap; align-items: center; gap: .15rem .5rem; }
.open-albums li.off .name::before { display: none; }
.open-albums li.off .pill, .switches li.off .pill { margin: 0; }
.grid .empty { grid-column: 1 / -1; margin: 0; padding: 1.6rem 1rem; text-align: center; color: var(--muted);
  border: 2px dashed var(--line); border-radius: 12px; }
.tile .sq.plain { display: grid; place-items: center; padding: .6rem; text-align: center; color: var(--muted);
  font-size: .8rem; font-weight: 600; overflow-wrap: anywhere;
  background: repeating-linear-gradient(135deg, #eef5f7 0 10px, #e6f0f3 10px 20px); }
button.danger { background: var(--bad); border-color: var(--bad); color: #fff; }
button.danger:hover { background: #8e2814; border-color: #8e2814; }
.album-status:empty { display: none; }
.album-status { font-size: .95rem; font-weight: 600; color: var(--ok); }
/* the photo service not answering (or PhotoRelay not reached): the line, and its Try again beside it (trouble.ts) */
.note:has(button.retry), .album-status.down { display: flex; align-items: center; gap: .5rem 1rem; flex-wrap: wrap; }
.album-status.down { background: var(--warn-bg); color: var(--warn); border-radius: 12px; padding: .8rem 1rem; }
.note:has(button.retry) > span, .album-status.down > span { flex: 1 1 14rem; }
button.retry { padding: .45rem 1rem; background: #fff; border-color: currentColor; color: var(--warn); flex: none; }
.loading-photos { color: var(--muted); }

@media (max-width: 500px) {
  body { font-size: 16.5px; }
  h1 { font-size: 1.75rem; }
  .mark { font-size: 1.15rem; }
  .top .in { padding: 0 1rem; }
  .who { font-size: .88rem; gap: 1rem; }
  .who #who { display: none; }
  .card { padding: 1.15rem; }
  .tiles { grid-template-columns: repeat(2, 1fr); gap: .75rem; }
  .sheet { width: 100vw; max-width: 100vw; height: 100dvh; max-height: 100dvh; border-radius: 0; margin: 0; }
  .sheet-body { padding: 1rem; }
  .viewer { width: 100vw; max-width: 100vw; height: 100dvh; max-height: 100dvh; border-radius: 0; margin: 0; }
  .viewer-pic { padding: 3.4rem .5rem .5rem; }
  .viewer-pic img { max-height: calc(100dvh - 11rem); }
  .viewer-bar { padding: .8rem 1rem calc(1rem + env(safe-area-inset-bottom)); }
  .list .row { padding: .9rem 1rem; }
  .section-head .count { display: block; margin-top: .3rem; }
  .section-head .count:not(:empty)::before { content: none; }
}

/* after a drop: the drop area as one line, for another folder */
.drop.compact { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: .3rem .6rem; padding: .8rem 1rem; }
.drop.compact .icon, .drop.compact .hint { display: none; }
.drop.compact .big { font: 600 .95rem/1.3 var(--sans); margin: 0; }
.drop.compact .or { font-size: .95rem; }
.drop.compact .button { margin: 0; padding: .4rem .9rem; font-size: .9rem; }
#send-status.bad { color: var(--bad); font-weight: 600; }
