/* The gallery page (the "Client page · cleaner" boards, approved 2026-10-20): the app's own parts on
   white. A slim bar with ODD01 in the middle, the banner and the title centred under it, photos at
   their own shape, and one photo at a time over a frosted page. Blue only for hearts and picks. */
:root {
  color-scheme: light;
  --ink: #1a1a1a; --ink-2: #404040; --mute: #737373; --faint: #a3a3a3;
  --tint: rgba(20, 20, 40, .035); --tint-2: rgba(20, 20, 40, .055); --tint-3: rgba(20, 20, 40, .08);
  --hover: rgba(20, 20, 40, .045); --on: rgba(20, 20, 40, .06); --rule: rgba(20, 20, 40, .07);
  --blue: #2563eb; --blue-ink: #1d4ed8; --blue-soft: #eff4ff;
  --amber: #d97706; --amber-ink: #92400e; --amber-soft: #fdf5e7; --red-ink: #b91c1c;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, sans-serif;
  --disp: -apple-system, BlinkMacSystemFont, "SF Pro Display", system-ui, sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, monospace;
  --lift: 0 1px 3px rgba(20, 20, 40, .16);
}
* { box-sizing: border-box; }
html, body { margin: 0; background: #fff; color: var(--ink); font-family: var(--sans); font-size: 13.5px; line-height: 20px;
  letter-spacing: -.005em; -webkit-font-smoothing: antialiased; -webkit-text-size-adjust: 100%; }
button { font: inherit; color: inherit; border: 0; background: none; padding: 0; cursor: pointer; }
a { color: inherit; }
[hidden] { display: none !important; }
.quiet { color: var(--mute); font-size: 13.5px; }
.center { text-align: center; padding: 48px 16px; }
.money { font-family: var(--mono); font-variant-numeric: tabular-nums; letter-spacing: -.02em; }

/* The bar: ODD01 in the middle, the picks or downloads at the right (the count at the left on a phone) */
.top { position: sticky; top: 0; z-index: 5; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  height: 56px; padding: 0 24px; background: rgba(255, 255, 255, .96); }
.top .mark { display: flex; color: var(--ink); }
.top .mark svg { width: 72px; height: auto; display: block; }
.top .start, .top .end { display: flex; align-items: center; gap: 10px; min-width: 0; position: relative; }
.top .end { justify-content: flex-end; }
.top .line { position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--tint-2); }
.top .line i { display: block; height: 100%; width: 0; background: var(--blue); transition: width .2s ease-out; }
.picks { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 10px; border-radius: 14px; background: var(--tint);
  font-size: 13px; color: var(--ink); font-variant-numeric: tabular-nums; white-space: nowrap; }
.picks svg { color: var(--blue); }
.picks span { color: var(--mute); }
.picks.over { background: var(--amber-soft); color: var(--amber-ink); }
.picks.over span { color: var(--amber-ink); }

/* Buttons: soft tints, never white or outlined */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 28px; padding: 0 11px; border-radius: 8px;
  background: var(--tint); font-size: 13px; white-space: nowrap; text-decoration: none; }
.btn:hover { background: var(--tint-2); }
.btn:active { background: var(--tint-3); }
.btn.pri { background: var(--tint-2); font-weight: 500; }
.btn.pri:hover, .btn.pri:active { background: var(--tint-3); }
.btn:disabled { opacity: .45; cursor: default; }
.btn svg { flex-shrink: 0; }
.menu { position: absolute; right: 0; top: 36px; z-index: 6; width: 250px; padding: 6px; border-radius: 12px; background: #fff;
  box-shadow: 0 0 0 1px rgba(20,20,40,.08), 0 16px 40px rgba(20,20,40,.12), 0 2px 6px rgba(20,20,40,.05); }
.menu button { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; width: 100%; padding: 8px 10px; border-radius: 8px; text-align: left; }
.menu button:hover { background: var(--hover); }
.menu button span { font-size: 12px; color: var(--mute); }

/* The page: one centred column */
main { max-width: 1040px; margin: 0 auto; padding: 0 24px; }
.cover { position: relative; margin-top: 12px; aspect-ratio: 5 / 2; border-radius: 12px; overflow: hidden; background: var(--tint-2); }
.cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.hero { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 30px 0 22px; text-align: center; }
.hero h1 { margin: 0; font-family: var(--disp); font-size: 34px; line-height: 40px; font-weight: 400; letter-spacing: -.02em; }
.hero .meta { font-size: 14px; color: var(--mute); font-variant-numeric: tabular-nums; }
.hero .hint { margin-top: 4px; font-size: 13px; color: var(--faint); font-variant-numeric: tabular-nums; }
.hero .hint + .hint { margin-top: 0; }
.hero .hint.over { color: var(--amber-ink); }
.panel { max-width: 560px; margin: 0 auto 22px; display: flex; flex-direction: column; gap: 10px; padding: 14px 16px 16px; border-radius: 14px; background: var(--tint); }
.panel .h { display: flex; align-items: center; gap: 10px; font-size: 13.5px; }
.panel .well { width: 24px; height: 24px; border-radius: 7px; display: flex; align-items: center; justify-content: center; flex-shrink: 0;
  background: rgba(217,119,6,.11); color: var(--amber-ink); }
.panel .amt { display: flex; align-items: baseline; gap: 10px; }
.panel .amt b { font-weight: 400; font-size: 22px; }
.panel .amt span, .panel .fine { font-size: 12.5px; color: var(--mute); }
.panel p { margin: 0; font-size: 13.5px; line-height: 20px; color: var(--ink-2); }
.panel .row { display: flex; flex-wrap: wrap; gap: 6px; }

/* Tabs: the app's tab strip, centred; it scrolls sideways when it doesn't fit */
.tabs { display: flex; gap: 2px; padding: 0 0 18px; overflow-x: auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs > :first-child { margin-left: auto; }
.tabs > :last-child { margin-right: auto; }
.tabs button { flex: none; display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 10px; border-radius: 8px; font-size: 13px; color: var(--mute); }
.tabs button:hover { background: var(--hover); color: var(--ink); }
.tabs button[aria-pressed="true"] { background: var(--on); color: var(--ink); }
.count { min-width: 20px; height: 17px; padding: 0 6px; border-radius: 9px; background: var(--tint-2); color: var(--mute); font-size: 11px; font-weight: 600;
  display: inline-flex; align-items: center; justify-content: center; font-variant-numeric: tabular-nums; }

/* Photos at their own shape, three across (two on a phone) */
.photos { columns: 3; column-gap: 10px; }
.photo { position: relative; break-inside: avoid; margin: 0 0 10px; border-radius: 8px; overflow: hidden; background: var(--tint); }
.photo > button.open { display: block; width: 100%; cursor: zoom-in; }
.photo img { display: block; width: 100%; height: auto; }
.photo .file { aspect-ratio: 3 / 2; display: flex; align-items: center; justify-content: center; padding: 12px; font-size: 12px; color: var(--mute); text-align: center; }
.photo .heart, .photo .dl { position: absolute; width: 32px; height: 32px; border-radius: 16px; background: rgba(255,255,255,.94);
  box-shadow: var(--lift); display: flex; align-items: center; justify-content: center; color: var(--ink-2); }
.photo .heart { right: 8px; bottom: 8px; }
.photo .heart[aria-pressed="true"] { color: var(--blue); }
.photo .dl { right: 8px; top: 8px; opacity: 0; transition: opacity .12s; }
.photo:hover .dl, .photo .dl:focus-visible { opacity: 1; transition: none; }
.photo .note { position: absolute; left: 8px; bottom: 8px; height: 20px; padding: 0 7px; border-radius: 10px; background: rgba(255,255,255,.94);
  font-size: 11px; display: flex; align-items: center; gap: 4px; color: var(--ink-2); pointer-events: none; }

/* The access code */
.code { max-width: 360px; margin: 64px auto 0; display: flex; flex-direction: column; gap: 12px; text-align: center; }
.code h1 { margin: 0; font-family: var(--disp); font-size: 26px; line-height: 32px; font-weight: 400; letter-spacing: -.02em; }
.code input, .compose input { height: 40px; padding: 0 12px; border-radius: 10px; border: 0; background: var(--tint); font: inherit; font-size: 16px; color: var(--ink); }
.code input { text-align: center; }
.code input:focus, .compose input:focus { outline: none; background: #fff; box-shadow: 0 0 0 1px var(--blue), 0 0 0 4px rgba(37,99,235,.12); }
.code .err { color: var(--red-ink); font-size: 13px; min-height: 20px; }

.foot { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 56px 0 48px; font-size: 12px; color: var(--faint); }
.foot svg { color: var(--mute); }
.foot a { color: var(--mute); text-decoration: none; }
.toast { position: fixed; left: 50%; bottom: calc(28px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 20; padding: 8px 14px;
  border-radius: 10px; background: var(--ink); color: #fff; font-size: 13px; white-space: nowrap; }
.viewer:not([hidden]) ~ .toast { bottom: calc(112px + env(safe-area-inset-bottom)); }

/* One photo at a time, over the page frosted */
.viewer { position: fixed; inset: 0; z-index: 10; background: rgba(246, 246, 248, .74);
  -webkit-backdrop-filter: blur(28px) saturate(1.1); backdrop-filter: blur(28px) saturate(1.1); }
.viewer .vtop { position: absolute; left: 0; right: 0; top: 0; height: 64px; padding: 0 24px; display: flex; align-items: center; justify-content: space-between; }
.viewer .vn { font-size: 13.5px; color: var(--ink); font-variant-numeric: tabular-nums; }
.viewer .vn span { color: var(--mute); }
.viewer .vx { width: 36px; height: 36px; border-radius: 18px; background: var(--tint-2); display: flex; align-items: center; justify-content: center; }
.viewer .vx:hover { background: var(--tint-3); }
.viewer .stage { position: absolute; top: 72px; bottom: 96px; left: 120px; right: 120px; display: flex; align-items: center; justify-content: center; }
.viewer .stage img { max-width: 100%; max-height: 100%; width: auto; height: auto; border-radius: 8px; box-shadow: 0 24px 60px rgba(20,20,40,.16); user-select: none; -webkit-user-drag: none; }
.viewer .stage .file { padding: 40px; border-radius: 12px; background: #fff; color: var(--mute); }
.viewer .arrow { position: absolute; top: 50%; margin-top: -28px; width: 56px; height: 56px; border-radius: 28px; background: rgba(255,255,255,.94);
  box-shadow: 0 2px 10px rgba(20,20,40,.12); display: flex; align-items: center; justify-content: center; color: var(--ink); }
.viewer .arrow:hover { background: #fff; }
.viewer .arrow.prev { left: 40px; }
.viewer .arrow.next { right: 40px; }
.viewer .vbar { position: absolute; left: 50%; bottom: 28px; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 8px;
  width: min(560px, calc(100% - 32px)); }
.viewer .tools { display: flex; align-items: center; gap: 8px; }
.viewer .vbtn { display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 14px; border-radius: 18px; background: rgba(255,255,255,.94);
  box-shadow: 0 1px 3px rgba(20,20,40,.10); font-size: 13px; white-space: nowrap; }
.viewer .vbtn svg { color: var(--ink-2); }
.viewer .vbtn[aria-pressed="true"] { background: var(--blue-soft); color: var(--blue-ink); }
.viewer .vbtn[aria-pressed="true"] svg { color: var(--blue); }
.viewer .vcount { margin-left: 10px; font-size: 13px; color: var(--mute); font-variant-numeric: tabular-nums; white-space: nowrap; }
.viewer .notes { display: flex; flex-direction: column; align-items: center; gap: 4px; max-width: 100%; }
.viewer .notes div { max-width: 100%; padding: 6px 12px; border-radius: 14px; background: rgba(255,255,255,.94); box-shadow: 0 1px 3px rgba(20,20,40,.08);
  font-size: 13px; color: var(--ink-2); overflow-wrap: anywhere; }
.compose { display: flex; align-items: center; gap: 8px; width: 100%; padding: 8px; border-radius: 16px; background: #fff; box-shadow: 0 10px 30px rgba(20,20,40,.14); }
.compose .hb { flex: none; width: 40px; height: 40px; border-radius: 20px; background: var(--tint); color: var(--ink-2); display: flex; align-items: center; justify-content: center; }
.compose .hb[aria-pressed="true"] { background: var(--blue-soft); color: var(--blue); }
.compose input { flex: 1; min-width: 0; font-size: 15px; }
.compose .btn { height: 40px; padding: 0 14px; border-radius: 10px; font-size: 14px; }

@media (max-width: 640px) {
  .top { height: 52px; padding: 0 12px 0 16px; }
  .top .mark svg { width: 58px; }
  .top .btn { height: 30px; }
  main { padding: 0; }
  .cover { margin: 6px 12px 0; aspect-ratio: 6 / 5; }
  .hero { gap: 4px; padding: 20px 24px 14px; }
  .hero h1 { font-size: 26px; line-height: 31px; }
  .hero .meta { font-size: 12px; line-height: 17px; }
  .hero .hint { margin-top: 2px; font-size: 11.5px; line-height: 16px; }
  .panel { margin: 0 12px 16px; }
  .tabs { padding: 0 10px 12px; }
  .photos { columns: 2; column-gap: 6px; padding: 0 12px; }
  .photo { margin-bottom: 6px; border-radius: 6px; }
  .photo .dl { display: none; }
  .viewer .vtop { height: 52px; padding: 0 12px 0 16px; }
  .viewer .vx { width: 34px; height: 34px; }
  .viewer .stage { top: 60px; bottom: 84px; left: 12px; right: 12px; }
  .viewer .arrow { width: 44px; height: 44px; margin-top: -22px; }
  .viewer .arrow.prev { left: 20px; }
  .viewer .arrow.next { right: 20px; }
  .viewer .vbar { bottom: calc(14px + env(safe-area-inset-bottom)); width: calc(100% - 24px); }
}
