/* Eclipse Media Photography guest book. Cream paper, dark ink, serif display type.
   System fonts only: nothing extra to download on reception wifi. */
:root {
  --paper: #f6f1e7;
  --card: #fffdf8;
  --ink: #1f1b16;
  --muted: #6f665a;
  --line: #e2d8c6;
  --accent: #7f6137; /* 5:1 on the paper (was #8a6a3d, 4.4:1) */
  --accent-ink: #fffdf8;
  --ok: #4d6b4a;
  --bad: #9a3b2e;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", ui-serif, Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --radius: 14px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 16px/1.5 var(--sans);
  -webkit-font-smoothing: antialiased;
}
h1, h2 { font-family: var(--serif); font-weight: 500; letter-spacing: 0.005em; margin: 0; text-wrap: balance; }
h1 { font-size: clamp(2rem, 9vw, 3rem); line-height: 1.1; }
h2 { font-size: 1.3rem; }
p { margin: 0; }
img { max-width: 100%; display: block; }
a { color: inherit; }
[hidden] { display: none !important; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; opacity: 0; }

.eyebrow { font-size: 0.72rem; letter-spacing: 0.24em; text-transform: uppercase; color: var(--accent); }
.date { font-family: var(--serif); font-style: italic; color: var(--muted); font-size: 1.05rem; }
.lede { font-family: var(--serif); font-size: 1.15rem; line-height: 1.5; color: var(--ink); text-wrap: pretty; }
.fine { font-size: 0.85rem; color: var(--muted); }
.muted { color: var(--muted); }
.link { background: none; border: 0; padding: 0; font: inherit; color: var(--accent); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.foot { margin-top: 40px; text-align: center; font-size: 0.7rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 0 22px; border-radius: 999px; border: 1px solid transparent;
  font: 600 1rem/1 var(--sans); text-decoration: none; cursor: pointer; user-select: none;
  -webkit-tap-highlight-color: transparent; transition: transform 0.08s ease, background 0.15s ease;
}
.btn:active { transform: scale(0.98); }
.btn.primary { background: var(--ink); color: var(--accent-ink); }
.btn.quiet { background: transparent; color: var(--ink); border-color: var(--line); }
.btn.light { background: #fff; color: var(--ink); }
.btn.big { min-height: 64px; width: 100%; font-size: 1.15rem; box-shadow: 0 10px 24px -12px rgba(31, 27, 22, 0.55); }
.btn.small { min-height: 40px; padding: 0 16px; font-size: 0.9rem; }
.btn[disabled] { opacity: 0.5; cursor: default; }
.btn svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linejoin: round; stroke-linecap: round; }
input:focus-visible + .btn, .btn:focus-visible, .link:focus-visible, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.field { display: block; margin-top: 14px; }
.field > span { display: block; font-size: 0.82rem; font-weight: 600; color: var(--muted); margin-bottom: 6px; }
.field small { font-weight: 400; }
input[type="text"], input[type="email"], input[type="date"], input:not([type]), textarea {
  width: 100%; min-height: 48px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px;
  background: #fff; color: var(--ink); font: 16px/1.4 var(--sans); /* 16px stops iOS zooming */
}
textarea { resize: vertical; }
input:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; }

.bar { height: 8px; border-radius: 99px; background: var(--line); overflow: hidden; margin: 12px 0 10px; }
.bar-fill { height: 100%; width: 0; background: var(--accent); border-radius: 99px; transition: width 0.3s ease; }

.toast {
  position: fixed; left: 50%; bottom: calc(18px + env(safe-area-inset-bottom)); transform: translateX(-50%);
  background: var(--ink); color: var(--accent-ink); padding: 12px 18px; border-radius: 999px; font-size: 0.9rem;
  max-width: calc(100vw - 32px); text-align: center; z-index: 50; box-shadow: 0 8px 24px -8px rgba(0, 0, 0, 0.5);
}

/* ---------------------------------------------------------------- guest */
.guest, .notice, .gallery { max-width: 560px; margin: 0 auto; padding: 0 20px calc(32px + env(safe-area-inset-bottom)); }
.notice { text-align: center; padding-top: 22vh; display: grid; gap: 14px; }

.hero { text-align: center; padding: 44px 0 26px; }
.hero-text { display: grid; gap: 10px; }
.hero.has-image { position: relative; margin: 0 -20px; padding: 0; }
.hero.has-image .hero-img { width: 100%; height: min(36vh, 320px); object-fit: cover; }
.hero.has-image .hero-text {
  position: relative; margin: -56px 20px 0; padding: 22px 16px 20px; background: var(--paper);
  border-radius: var(--radius) var(--radius) 0 0;
}

.start { display: grid; gap: 14px; text-align: center; padding-bottom: 8px; }
.start .lede { margin-bottom: 6px; }
.start .btn.quiet { justify-self: center; border: 0; text-decoration: underline; text-underline-offset: 4px; font-weight: 500; min-height: 44px; }

.progress, .note { margin-top: 18px; }
.progress-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.progress-head strong { font-family: var(--serif); font-weight: 500; font-size: 1.2rem; }
.progress-head span { font-variant-numeric: tabular-nums; color: var(--muted); font-size: 0.9rem; }
.progress.complete { border-color: var(--ok); }
.progress.complete .bar-fill { background: var(--ok); }
.note .btn { margin-top: 16px; width: 100%; }
.note-saved { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; }
.note-saved strong { font-family: var(--serif); font-weight: 500; font-size: 1.15rem; }

.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-top: 18px; }
.tile { position: relative; aspect-ratio: 1; border-radius: 8px; overflow: hidden; background: var(--line); }
.tile-img, .tile-img img { width: 100%; height: 100%; object-fit: cover; }
.tile.waiting .tile-img, .tile.preparing .tile-img { animation: pulse 1.4s ease-in-out infinite; }
.tile:not(.done) .tile-img img { opacity: 0.55; }
.tile-ring { position: absolute; left: 6px; right: 6px; bottom: 6px; height: 4px; border-radius: 4px; background: rgba(255, 255, 255, 0.6); overflow: hidden; }
.tile-ring i { display: block; height: 100%; width: 0; background: var(--ink); transition: width 0.2s linear; }
.tile.done .tile-ring, .tile.failed .tile-ring { display: none; }
.tile.done::after {
  content: "✓"; position: absolute; right: 5px; bottom: 5px; width: 20px; height: 20px; border-radius: 50%;
  background: var(--ok); color: #fff; font-size: 12px; line-height: 20px; text-align: center;
}
.tile-retry {
  position: absolute; inset: 0; width: 100%; border: 0; background: rgba(154, 59, 46, 0.82); color: #fff;
  font: 600 0.8rem var(--sans); cursor: pointer;
}
@keyframes pulse { 50% { opacity: 0.5; } }

/* -------------------------------------------------------------- gallery */
.gallery { max-width: 1100px; }
.gallery-head { text-align: center; padding: 40px 0 22px; display: grid; gap: 8px; }
.gallery-head .btn { justify-self: center; margin-top: 10px; }
.toolbar {
  position: sticky; top: 0; z-index: 5; display: flex; gap: 10px; align-items: center; justify-content: space-between;
  padding: 10px 0; background: var(--paper); border-bottom: 1px solid var(--line); margin-bottom: 14px;
}
.tabs { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; min-width: 0; width: 100%; }
@media (max-width: 520px) { .tabs button { flex: 1; padding: 10px 6px; } }
.tabs button {
  border: 0; background: none; padding: 10px 12px; min-height: 40px; border-radius: 999px; font: 500 0.92rem var(--sans);
  color: var(--muted); cursor: pointer; white-space: nowrap;
}
.tabs button[aria-selected="true"] { background: var(--ink); color: var(--accent-ink); }

.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; }
@media (min-width: 700px) { .grid { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px; } }
.g-tile { position: relative; margin: 0; aspect-ratio: 1; overflow: hidden; border-radius: 6px; background: var(--line); cursor: pointer; }
.g-tile img { width: 100%; height: 100%; object-fit: cover; }
.g-tile.is-hidden img { opacity: 0.35; filter: grayscale(1); }
.g-tile figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 18px 8px 6px; font-size: 0.72rem; color: #fff;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.6)); white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.badge { position: absolute; top: 6px; left: 6px; background: var(--ink); color: #fff; font-size: 0.66rem; padding: 3px 7px; border-radius: 99px; letter-spacing: 0.04em; }
.g-hide {
  position: absolute; right: 5px; top: 5px; min-height: 28px; padding: 0 9px; border: 0; border-radius: 99px;
  background: rgba(255, 253, 248, 0.92); color: var(--ink); font: 600 0.7rem var(--sans); cursor: pointer;
}
.empty { text-align: center; padding: 48px 0; color: var(--muted); }
#more { display: flex; margin: 20px auto 0; }

.messages { display: grid; gap: 10px; max-width: 640px; margin: 0 auto; }
.m-card { display: grid; grid-template-columns: 72px 1fr; gap: 14px; align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; cursor: pointer; }
.m-card img { width: 72px; height: 72px; object-fit: cover; border-radius: 8px; }
.m-card.is-hidden { opacity: 0.55; }
.m-text { font-family: var(--serif); font-size: 1.08rem; line-height: 1.45; white-space: pre-wrap; overflow-wrap: anywhere; }
.m-by { font-size: 0.8rem; color: var(--muted); margin-top: 4px; }

dialog { border: 0; padding: 0; color: inherit; }
dialog::backdrop { background: rgba(20, 17, 13, 0.6); }
.lightbox {
  width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; background: #14110d; color: #f6f1e7;
}
.lightbox[open] { display: grid; grid-template-rows: auto 1fr auto; }
.lb-top, .lb-bottom { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 14px; }
.lb-bottom { align-items: flex-end; padding-bottom: calc(14px + env(safe-area-inset-bottom)); min-height: 76px; }
.lb-btn { background: none; border: 0; color: inherit; font: 500 0.95rem var(--sans); padding: 10px 6px; text-decoration: none; cursor: pointer; }
.lb-pos { font-size: 0.82rem; opacity: 0.7; font-variant-numeric: tabular-nums; }
.lb-stage { position: relative; min-height: 0; display: grid; place-items: center; }
.lb-stage img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; position: absolute; inset: 0; margin: auto; }
.lb-stage img.is-hidden { opacity: 0.4; }
.lb-nav {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 2; width: 44px; height: 64px; border: 0;
  background: rgba(20, 17, 13, 0.45); color: #fff; font-size: 2rem; line-height: 1; cursor: pointer; border-radius: 8px;
}
.lb-nav.prev { left: 6px; } .lb-nav.next { right: 6px; }
.lb-meta { min-width: 0; display: grid; gap: 2px; }
.lb-meta strong { font-family: var(--serif); font-weight: 500; font-size: 1.1rem; }
.lb-meta p { font-family: var(--serif); font-style: italic; max-height: 6.2em; overflow: auto; overflow-wrap: anywhere; white-space: pre-wrap; }
.lb-date { font-size: 0.78rem; opacity: 0.65; }
.lb-bottom .btn { flex: none; }

.sheet { width: min(440px, calc(100vw - 24px)); border-radius: 18px; background: var(--card); padding: 22px; }
.sheet h2 { margin-bottom: 6px; }
.choice { display: flex; gap: 12px; align-items: flex-start; padding: 12px; border: 1px solid var(--line); border-radius: 12px; margin-top: 10px; cursor: pointer; }
.choice input { margin-top: 4px; accent-color: var(--ink); }
.choice small { display: block; color: var(--muted); font-size: 0.82rem; }
.check { display: flex; gap: 10px; align-items: center; margin: 14px 2px 4px; font-size: 0.92rem; }
.check input { width: 18px; height: 18px; accent-color: var(--ink); }
.sheet-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 14px; }

/* ---------------------------------------------------------------- admin */
body.admin { background: #faf7f1; }
.admin-bar { display: flex; align-items: center; justify-content: space-between; padding: 14px 20px; border-bottom: 1px solid var(--line); background: var(--card); }
.admin-brand { font-family: var(--serif); font-size: 1.15rem; text-decoration: none; }
.admin-brand span { color: var(--muted); font-style: italic; }
.admin-main { max-width: 720px; margin: 0 auto; padding: 22px 20px 60px; display: grid; gap: 16px; }
.admin-main h1 { font-size: 1.9rem; }
.pill { display: inline-block; font-size: 0.72rem; padding: 3px 10px; border-radius: 99px; background: var(--line); color: var(--muted); white-space: nowrap; }
.pill.open { background: #dfe9dc; color: var(--ok); }
.pill.closed { background: #efe0dc; color: var(--bad); }
.error { color: var(--bad); font-weight: 600; margin-top: 8px; }
.notice-bar { background: #dfe9dc; color: #2f4a2c; padding: 10px 14px; border-radius: 10px; }
.form .btn { margin-top: 16px; }
.form .fine { margin-top: 12px; }
.prefixed { display: flex; align-items: center; border: 1px solid var(--line); border-radius: 10px; background: #fff; overflow: hidden; }
.prefixed em { font-style: normal; color: var(--muted); padding-left: 12px; white-space: nowrap; font-size: 0.9rem; max-width: 50%; overflow: hidden; text-overflow: ellipsis; }
.prefixed input { border: 0; padding-left: 2px; min-width: 0; }
.event-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.event-list li { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.event-list a { display: grid; text-decoration: none; min-width: 0; }
.event-list strong { font-family: var(--serif); font-weight: 500; font-size: 1.15rem; }
.event-list span { font-size: 0.88rem; }
.qr-card { display: grid; gap: 18px; }
@media (min-width: 560px) { .qr-card { grid-template-columns: 200px 1fr; align-items: center; } }
.qr { width: 200px; max-width: 100%; margin: 0 auto; background: #fff; border-radius: 10px; padding: 6px; border: 1px solid var(--line); }
.qr svg, .card-qr svg { display: block; width: 100%; height: auto; }
.qr-side { display: grid; gap: 10px; min-width: 0; }
.copy-row { overflow-wrap: anywhere; font-size: 0.95rem; }
.copy-row.magic { background: var(--paper); padding: 10px 12px; border-radius: 10px; font-family: ui-monospace, Menlo, monospace; font-size: 0.8rem; margin: 10px 0; }
.btn-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.inline-form { margin: 12px 0; }
.card h2 { margin-bottom: 8px; }
.facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 4px 0 12px; }
.facts div { background: var(--paper); border-radius: 10px; padding: 10px; }
.facts dt { font-size: 0.72rem; color: var(--muted); }
.facts dd { margin: 0; font-family: var(--serif); font-size: 1.3rem; }
.hero-preview { width: 100%; max-height: 220px; object-fit: cover; border-radius: 10px; margin-bottom: 12px; }
.card .btn-row { margin-top: 10px; }

/* ---------------------------------------------------- printable table cards */
body.print-page { background: #d9d4ca; }
.print-bar { display: flex; justify-content: space-between; align-items: center; padding: 12px 20px; }
.sheet-a4 { width: 210mm; height: 297mm; margin: 0 auto 24px; background: #fff; display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; }
.table-card {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3.2mm; text-align: center;
  padding: 10mm; background: var(--paper); outline: 0.2mm dashed #c9bfae; color: var(--ink);
}
.table-card h1 { font-size: 26pt; }
.table-card .eyebrow { font-size: 7.5pt; }
.card-lede { font-family: var(--serif); font-style: italic; font-size: 12pt; }
.card-qr { width: 46mm; padding: 2mm; background: #fff; border-radius: 2mm; margin: 2mm 0; }
.card-url { font-size: 9pt; letter-spacing: 0.02em; overflow-wrap: anywhere; }
.card-fine { font-size: 6.5pt; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted); }
@media screen and (max-width: 820px) { .sheet-a4 { zoom: 0.45; } }
@media print {
  @page { size: A4; margin: 0; }
  body.print-page { background: #fff; }
  .print-bar { display: none; }
  .sheet-a4 { margin: 0; zoom: 1; }
  .table-card { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* Admin: section links and inline inputs on couple pages */
.admin-nav { display: flex; gap: 18px; margin: 0 auto 0 28px; font-size: .92rem; }
.admin-nav a { text-decoration: none; color: var(--muted); }
.admin-nav a:hover { color: inherit; }
.btn-row input:not([type="file"]):not([type="hidden"]), .btn-row select { padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; font: inherit; background: var(--card); min-width: 0; flex: 1 1 160px; }
.event-list li > span:first-child { min-width: 0; }

/* Returning guest: their own photos */
.mine-bar { margin-top: 26px; display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.mine-bar h2 { font-family: var(--serif); font-weight: 500; font-size: 1.25rem; }
.mine-bar + .tiles { margin-top: 10px; }
.tile.mine { cursor: pointer; }
.mine-actions { margin-top: 18px; display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.mine-actions .link { font-size: 0.85rem; color: var(--muted); }
.lb-btn.danger { color: #f0a08c; }

/* Guest sharing: admin switches, couple request */
.pill.ask { background: #f3e6c8; color: #7a5a1c; }
.pill-col { display: grid; gap: 4px; justify-items: end; flex: none; }
.ask-bar { background: #f8efd9; border: 1px solid #e6d3a3; border-radius: 10px; padding: 12px 14px; margin: 12px 0; }
.card .check { align-items: flex-start; }
.card .check input { flex: none; margin-top: 2px; }
.share-line { margin-top: 6px; }
.sheet .choice input[type="checkbox"] { width: 18px; height: 18px; flex: none; }

/* Guest page: what the couple shares with every guest */
.shared { margin-top: 34px; padding-top: 22px; border-top: 1px solid var(--line); display: grid; gap: 8px; }
.shared h2 { font-size: 1.25rem; }
.shared .tabs { margin-top: 4px; }
.shared .tabs button { flex: 1; }
.shared-grid { grid-template-columns: repeat(3, 1fr); margin-top: 6px; }
.shared-tile { border: 0; padding: 0; cursor: pointer; display: block; width: 100%; }
.shared-tile img { width: 100%; height: 100%; object-fit: cover; }
.tile-quote { position: absolute; left: 5px; bottom: 3px; color: #fff; font-size: 0.95rem; text-shadow: 0 1px 3px rgba(0, 0, 0, 0.7); }
.shared .messages { margin: 6px 0 0; max-width: none; }
#shared-more { justify-self: center; margin-top: 10px; }
#share-fine { margin-top: -6px; }

/* Status page */
.alert-bar { background: #efe0dc; color: #6d2a1c; padding: 10px 14px; border-radius: 10px; }
.status-table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.status-table th, .status-table td { text-align: left; padding: 7px 8px 7px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.status-table thead th { font-size: .72rem; font-weight: 500; color: var(--muted); }
.status-table tbody th { font-weight: 500; white-space: nowrap; }
.status-table td.bad, .check-list .bad dd, .status-events .bad dd { color: var(--bad); font-weight: 600; }
.status-events, .problem-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.status-events li { display: grid; gap: 8px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.status-events li:last-child { border-bottom: 0; }
.status-events dl { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 0; }
.status-events dl div { background: var(--paper); border-radius: 10px; padding: 8px 10px; }
.status-events dt, .check-list dt, .problem-detail dt { font-size: .72rem; color: var(--muted); }
.status-events dd, .check-list dd, .problem-detail dd { margin: 0; }
.status-events dd { font-family: var(--serif); font-size: 1.15rem; }
.check-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; margin: 4px 0 12px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 10px; }
.chip { font-size: .78rem; padding: 4px 11px; border-radius: 99px; border: 1px solid var(--line); text-decoration: none; color: inherit; }
.problem { border: 1px solid var(--line); border-radius: 10px; padding: 9px 12px; }
.problem.error { border-color: #e2c3bb; }
.problem summary { cursor: pointer; list-style: none; display: grid; gap: 3px; }
.problem summary::-webkit-details-marker { display: none; }
.problem-msg { overflow-wrap: anywhere; }
.problem-detail { display: grid; gap: 8px; margin: 10px 0 2px; }
.problem-detail pre { margin: 0; font-size: .78rem; white-space: pre-wrap; overflow-wrap: anywhere; background: var(--paper); border-radius: 8px; padding: 8px; }

/* ------------------------------------------- couple dashboard and keepsake */
.center { text-align: center; }
.head-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.head-actions .btn { margin-top: 10px; }
.home-sign { max-width: 440px; margin: 0 auto; padding: 14vh 20px 40px; display: grid; gap: 14px; text-align: center; }
.home-sign .card { text-align: left; display: grid; gap: 12px; }
.home-sign .btn { width: 100%; }
.code-input { font-size: 1.6rem !important; letter-spacing: 0.3em; text-align: center; font-variant-numeric: tabular-nums; }
.home { max-width: 1100px; margin: 0 auto; padding: 0 20px calc(32px + env(safe-area-inset-bottom)); }
.home-head { text-align: center; padding: 34px 0 18px; display: grid; gap: 8px; }
.home-mark { display: block; margin: 0 auto 4px; width: 111px; height: 24px; }
#home-body { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
#home-body > .card, #home-body > .foot { width: 100%; max-width: 560px; margin-left: auto; margin-right: auto; }
.home-card { display: grid; gap: 8px; }
.home-card h2 { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0; }
.home-card h3 { font: 600 0.95rem var(--sans); margin: 10px 0 0; }
.home-card .form { display: grid; gap: 10px; margin-top: 6px; }
.home-card .form .btn { justify-self: start; }
.home-cover { display: block; margin: -18px -18px 6px; border-radius: var(--radius) var(--radius) 0 0; overflow: hidden; aspect-ratio: 16 / 9; background: var(--line); }
.home-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.new-pill { font-family: var(--sans); }
.people { list-style: none; padding: 0; margin: 0; font-size: 0.92rem; display: grid; gap: 2px; }
.center-row { justify-content: center; }
.home-tabs button { flex: none !important; }
.cell { position: relative; aspect-ratio: 1; padding: 0; border: 0; overflow: hidden; border-radius: 6px; background: var(--line); cursor: pointer; }
.cell img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cell-fav { position: absolute; right: 6px; bottom: 4px; color: #fff; font-size: 1rem; text-shadow: 0 1px 3px rgba(0, 0, 0, 0.7); }
.films { display: grid; gap: 18px; max-width: 760px; margin: 0 auto; }
.film { margin: 0; display: grid; gap: 6px; }
.film video { width: 100%; border-radius: 10px; background: #14110d; aspect-ratio: 16 / 9; }
.keepsake { max-width: 560px; }
.keepsake .card { display: grid; gap: 10px; }
.keepsake .btn-row .btn { flex: 1; text-decoration: none; }
.notice .lede > * + * { margin-top: 12px; }

/* Notes without a photo, note actions, delete */
.m-card.no-photo { grid-template-columns: 1fr; cursor: default; }
.m-card img.is-hidden { opacity: 0.35; filter: grayscale(1); }
.m-actions { display: flex; gap: 16px; margin-top: 6px; font-size: 0.82rem; }
.link.danger { color: var(--bad); }
.lb-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; flex: none; }

/* Admin moderation */
.mod-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.mod-grid li { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 8px; display: grid; gap: 6px; align-content: start; }
.mod-grid img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 6px; display: block; }
.mod-grid li.is-hidden img, .mod-notes img.is-hidden { opacity: 0.4; filter: grayscale(1); }
.mod-notes { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.mod-notes li { display: grid; grid-template-columns: auto 1fr; gap: 14px; align-items: start; }
.mod-notes li.is-hidden { opacity: 0.6; }
.mod-notes img { width: 84px; height: 84px; object-fit: cover; border-radius: 8px; }
.btn.danger { color: var(--bad); border-color: #e2c3bb; }
.danger-zone { border-color: #e2c3bb; }

/* Welcome line, prompts, hearts */
.welcome { font-family: var(--serif); font-style: italic; font-size: 1.1rem; color: var(--accent); text-align: center; margin: 0 0 6px; }
.prompts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.prompts .fine { flex-basis: 100%; margin: 0; }
.prompts .chip { background: var(--paper); cursor: pointer; font: inherit; font-size: 0.82rem; text-align: left; }
.tile.loved::after, .g-tile.loved::after { content: "♥"; position: absolute; left: 6px; top: 4px; color: #fff; font-size: 1rem; text-shadow: 0 1px 3px rgba(0, 0, 0, 0.7); }
.loved-line { color: var(--accent); }
.g-search { display: flex; gap: 8px; align-items: center; margin: 0 0 12px; }
.g-search input { min-height: 40px; padding: 8px 12px; }
.g-search select { min-height: 40px; border: 1px solid var(--line); border-radius: 10px; background: #fff; font: inherit; padding: 0 8px; }
.home-more { border-top: 1px solid var(--line); margin-top: 6px; padding-top: 10px; }
.home-more summary { cursor: pointer; font-weight: 600; font-size: 0.92rem; }
.home-more > * + * { margin-top: 10px; }

/* Reception slideshow */
body.show { background: #0d0b09; color: #f6f1e7; margin: 0; overflow: hidden; }
.show-stage { position: fixed; inset: 0; }
.show-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; opacity: 0; transition: opacity 1.2s ease; }
.show-img.on { opacity: 1; }
.show-empty { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; gap: 14px; padding: 40px; }
.show-empty h1 { font-size: clamp(2.4rem, 7vw, 6rem); }
.show-empty .lede { color: #d9cfbd; font-size: clamp(1.1rem, 2.4vw, 2rem); }
.show-caption { position: absolute; left: 3vw; bottom: 3vw; font-family: var(--serif); font-size: clamp(1.1rem, 2.2vw, 2.2rem); text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8); }
.show-qr { position: absolute; right: 2.4vw; bottom: 2.4vw; width: clamp(96px, 11vw, 190px); background: #fff; color: #1f1b16; border-radius: 12px; padding: 8px 8px 4px; text-align: center; }
.show-qr svg { width: 100%; height: auto; display: block; }
.show-qr p { margin: 4px 0 2px; font-size: clamp(0.6rem, 0.9vw, 0.95rem); font-weight: 600; }
.show-full { position: absolute; top: 16px; right: 16px; background: rgba(255, 255, 255, 0.14); color: inherit; border: 0; border-radius: 99px; padding: 8px 14px; font: inherit; cursor: pointer; }

/* Videos and voice messages */
.tile.is-video::before, .g-tile.is-video::before, .cell.is-video::before {
  content: "▶"; position: absolute; right: 6px; bottom: 5px; z-index: 1; color: #fff; font-size: 0.85rem; text-shadow: 0 1px 4px rgba(0, 0, 0, 0.8);
}
.lb-stage video { max-width: 100%; max-height: 100%; position: absolute; inset: 0; margin: auto; background: #000; }
.voice { display: grid; gap: 10px; }
.voice audio, .v-card audio { width: 100%; }
.v-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; display: grid; gap: 6px; }
.day-hour { font: 600 0.95rem var(--sans); margin: 14px 0 0; }
.cell-by { position: absolute; left: 0; right: 0; bottom: 0; padding: 14px 6px 4px; font-size: 0.68rem; color: #fff; background: linear-gradient(transparent, rgba(0, 0, 0, 0.6)); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-align: left; }
a.cell { display: block; }

/* Guest access: QR or passcode */
.access { padding-top: 16vh; }
.passcode-form { text-align: left; display: grid; gap: 12px; margin-top: 10px; }
.passcode-form input { font-size: 1.3rem !important; letter-spacing: 0.08em; text-align: center; }

/* Admin features */
.check.feature { align-items: flex-start; padding: 10px 0; border-bottom: 1px solid var(--line); margin: 0; }
.check.feature small { display: block; margin-top: 2px; }
.plans-table input:not([type="checkbox"]) { width: 100%; min-width: 52px; padding: 6px; border: 1px solid var(--line); border-radius: 6px; font: inherit; font-size: 0.85rem; }
.plans-table { display: block; overflow-x: auto; }
.plan-blurb td { padding-top: 0 !important; }
.admin-nav { flex-wrap: wrap; row-gap: 4px; }

/* Guest page tabs */
.g-tabs {
  position: sticky; top: 0; z-index: 6; display: flex; gap: 4px; margin: 14px -20px 0; padding: 8px 12px;
  background: var(--paper); border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none;
}
.g-tabs::-webkit-scrollbar { display: none; }
.g-tabs button {
  flex: 1 0 auto; min-width: 64px; min-height: 52px; display: grid; justify-items: center; align-content: center; gap: 2px;
  border: 0; border-radius: 12px; background: none; color: var(--muted); font: 500 0.82rem var(--sans); cursor: pointer; position: relative; padding: 4px 8px;
}
.g-tabs button span { font-size: 1.05rem; line-height: 1; }
.g-tabs button[aria-selected="true"] { background: var(--ink); color: var(--accent-ink); }
.g-tabs button[hidden] { display: none; }
.tab-done { position: absolute; top: 4px; right: 6px; font-style: normal; font-size: 0.7rem; color: var(--ok); }
.g-tabs button[aria-selected="true"] .tab-done { color: #b9d7b3; }
.g-panel { display: grid; gap: 14px; padding-top: 18px; }
.g-panel[hidden] { display: none; }
.g-panel > .btn.quiet { justify-self: center; border: 0; text-decoration: underline; text-underline-offset: 4px; font-weight: 500; min-height: 44px; }
.g-panel > .fine { text-align: center; }
.g-panel .progress, .g-panel .note { margin-top: 0; }
.g-panel .mine-bar { margin-top: 8px; }
.g-panel .tiles { margin-top: 0; }
.g-panel .shared { margin-top: 0; border-top: 0; padding-top: 0; }
.nudge { display: grid; gap: 4px; text-align: left; font: inherit; color: inherit; cursor: pointer; border-color: var(--accent); }
.nudge strong { font-family: var(--serif); font-weight: 500; font-size: 1.12rem; }
.nudge-go { color: var(--accent); font-weight: 600; font-size: 0.92rem; margin-top: 4px; }
.sending-pill {
  display: block; width: 100%; margin-top: 8px; padding: 8px 12px; border: 0; border-radius: 99px; background: #e8efe6;
  color: var(--ok); font: 600 0.82rem var(--sans); cursor: pointer;
}
.voice.card { border-top: 1px solid var(--line); margin-top: 0; }
.voice h2 { font-family: var(--serif); font-weight: 500; font-size: 1.2rem; }
.voice .btn-row .btn { flex: 1; }

/* Sign designer */
.signs { max-width: 1000px; margin: 0 auto; padding: 18px 20px 40px; }
.signs-grid { display: grid; gap: 18px; }
@media (min-width: 800px) { .signs-grid { grid-template-columns: 1fr 1fr; align-items: start; } .sign-preview { position: sticky; top: 16px; } }
.sign-frame { background: #fff; box-shadow: 0 8px 26px -14px rgba(31, 27, 22, 0.5); border-radius: 4px; overflow: hidden; max-width: 420px; margin: 0 auto; }
.sign-frame svg { width: 100%; height: auto; display: block; }
.sign-form { display: grid; gap: 4px; }
.sign-templates { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.sign-templates .field-label { font-size: 0.82rem; font-weight: 600; color: var(--muted); margin-bottom: 6px; padding: 0; }
.sign-templates label { display: flex; align-items: center; gap: 6px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 99px; cursor: pointer; font-size: 0.9rem; }
.accent-field input { width: 64px; height: 40px; padding: 2px; }
.sign-downloads { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 14px; }
.sign-downloads .btn { min-height: 46px; font-size: 0.88rem; padding: 0 10px; }

/* Privacy note and documents */
.privacy-note { margin-top: 30px; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--radius); font-size: 0.85rem; color: var(--muted); display: grid; gap: 6px; }
.privacy-note strong { color: var(--ink); }
/* The guest page's languages (self-serve guest books): plain links, each in its own language. */
.lang-switch { margin-top: 24px; }
.lang-switch ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 0 4px; }
.lang-switch a { display: inline-block; padding: 10px 8px; font-size: 0.85rem; color: var(--muted); text-decoration: none; }
.lang-switch a:hover, .lang-switch a:focus-visible { color: var(--ink); text-decoration: underline; }
.lang-switch a[aria-current] { color: var(--ink); font-weight: 600; }
.site-doc { max-width: 680px; margin: 0 auto; padding: 40px 20px 72px; display: grid; gap: 12px; }
.site-doc h1 { font-size: 2.2rem; }
.site-doc h2 { font-size: 1.35rem; margin-top: 18px; }
.site-doc ul { padding-left: 20px; margin: 0; display: grid; gap: 6px; }
.demo-bar { margin: 12px 0 0; padding: 10px 14px; border-radius: 12px; background: #f3e6c8; color: #5d4416; font-size: 0.88rem; text-align: center; }

/* Self-serve: pay bar */
.pay-bar { display: grid; gap: 10px; padding: 12px 14px; border-radius: 12px; background: #f3e6c8; color: #5d4416; font-size: 0.9rem; }
.pay-bar .btn { justify-self: start; }

/* Public site */
body.site { background: var(--paper); }
.site-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 20px; max-width: 1040px; margin: 0 auto; flex-wrap: wrap; }
.site-brand { font-family: var(--serif); font-size: 1.3rem; text-decoration: none; color: var(--ink); }
.site-brand span { color: var(--muted); font-style: italic; font-size: 0.95rem; }
.site-bar nav { display: flex; align-items: center; gap: 16px; font-size: 0.92rem; flex-wrap: wrap; }
.site-bar nav a:not(.btn) { color: var(--muted); text-decoration: none; }
.site { max-width: 1040px; margin: 0 auto; padding: 0 20px 40px; display: grid; gap: 54px; }
.site-narrow { max-width: 560px; gap: 18px; padding-top: 20px; }
.site-hero { text-align: center; padding: 48px 0 0; display: grid; gap: 18px; justify-items: center; }
.site-hero h1 { font-size: clamp(2.1rem, 6vw, 3.4rem); max-width: 18ch; }
.site-hero .lede { max-width: 40rem; }
.site-points { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.site-points div { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.site-points h3 { font-family: var(--serif); font-weight: 500; font-size: 1.15rem; margin: 0 0 6px; }
.site-points p { margin: 0; color: var(--muted); font-size: 0.95rem; }
.site-section { display: grid; gap: 16px; }
.site-section > h2 { text-align: center; font-size: 1.8rem; }
.site-steps { display: grid; gap: 12px; padding-left: 22px; max-width: 42rem; margin: 0 auto; }
.site-plans { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.plan { display: grid; gap: 8px; align-content: start; }
.plan h3 { font-family: var(--serif); font-weight: 500; font-size: 1.3rem; margin: 0; }
.plan-price { font-family: var(--serif); font-size: 2rem; margin: 0; }
.plan ul { padding-left: 18px; margin: 0; font-size: 0.92rem; display: grid; gap: 4px; }
.plan .btn { justify-self: start; margin-top: 6px; }
.site-section details { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 12px 16px; max-width: 46rem; width: 100%; margin: 0 auto; }
.site-section summary { cursor: pointer; font-weight: 600; }
.site-section details p { margin: 8px 0 0; color: var(--muted); }
.site-guides { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; max-width: 46rem; width: 100%; margin: 0 auto; }
.site-guides a { display: grid; gap: 2px; padding: 14px 16px; background: var(--card); border: 1px solid var(--line); border-radius: 12px; text-decoration: none; color: var(--ink); }
/* Kinds of event on the home page: two columns from tablet width. */
.site-kinds { max-width: 56rem; }
@media (min-width: 640px) { .site-kinds { grid-template-columns: 1fr 1fr; } }
.site-apps { margin-top: 8px; }
.site-foot { max-width: 1040px; margin: 0 auto; padding: 24px 20px 40px; border-top: 1px solid var(--line); font-size: 0.85rem; color: var(--muted); display: grid; gap: 4px; }
.site-preview { border-radius: 0; margin: 0; }
.site-doc ol { padding-left: 20px; display: grid; gap: 8px; }
.admin-main { grid-template-columns: minmax(0, 1fr); }
.admin-main > * { min-width: 0; }

/* Plan limit reached: guests can still write (guest page), and the couple's usage line and locked settings (dashboard). */
.full-note { border-color: var(--accent); margin-bottom: 12px; }
.full-note[hidden] { display: none; }
.warn-line { color: var(--accent); font-weight: 600; }
.lock-note { color: var(--muted); }

/* Sign designer: front and back side by side, ten design thumbnails. */
.sign-sides { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; align-items: start; }
.sign-sides figure { margin: 0; }
.sign-sides figure[hidden] { display: none; }
.sign-designs { border: 0; padding: 0; margin: 6px 0 4px; }
.sign-designs .field-label { font-size: 0.82rem; font-weight: 600; color: var(--muted); margin-bottom: 6px; padding: 0; }
.design-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
@media (max-width: 520px) { .design-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.design-pick { display: grid; gap: 4px; cursor: pointer; text-align: center; font-size: 0.72rem; line-height: 1.2; }
.design-pick input { position: absolute; opacity: 0; pointer-events: none; }
.design-thumb { display: block; border-radius: 4px; overflow: hidden; border: 2px solid transparent; box-shadow: 0 2px 8px -4px rgba(31, 27, 22, 0.5); background: #fff; }
.design-thumb svg { width: 100%; height: auto; display: block; }
.design-pick input:checked + .design-thumb { border-color: var(--accent); }
.design-pick input:focus-visible + .design-thumb { outline: 2px solid var(--accent); outline-offset: 2px; }
#back-field[hidden], #marks-row[hidden] { display: none; }
.g-tabs[hidden], .pickers[hidden] { display: none; }
.logo-preview { display: block; max-width: 220px; height: auto; margin: 4px 0 8px; padding: 10px; background: repeating-conic-gradient(#eee 0 25%, #fff 0 50%) 0 0 / 16px 16px; border-radius: 6px; }
.logo-pair { display: flex; flex-wrap: wrap; gap: 10px; }
.logo-preview.dark { background: #151515; }

/* Admin sign-in and Access page */
.admin-login { max-width: 420px; }
.plain-list { list-style: none; padding: 0; margin: 8px 0; }
.plain-list li { padding: 8px 0; border-bottom: 1px solid var(--line, #e6e0d6); }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.row-gap { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
form.inline { display: inline; margin: 0; }

/* ===================================================== Mobile first (phones 360–390 px up)
   Every control is at least 44 px tall, every input is 16 px (iOS does not
   zoom), nothing is wider than the screen, and wide tables become cards. */
body { padding-left: env(safe-area-inset-left); padding-right: env(safe-area-inset-right); overflow-wrap: break-word; }
select, input[type="datetime-local"], input[type="time"], input[type="number"], input[type="search"], input[type="tel"],
input[type="url"], input[type="password"], input[type="month"] {
  width: 100%; max-width: 100%; min-height: 48px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px;
  background: #fff; color: var(--ink); font: 16px/1.3 var(--sans);
}
input[type="file"] { font-size: 16px; min-height: 44px; max-width: 100%; padding: 8px 0; }
input[type="checkbox"], input[type="radio"] { width: 20px; height: 20px; accent-color: var(--ink); }
.btn.small { min-height: 44px; }
.check { min-height: 44px; }
summary { min-height: 44px; display: flex; align-items: center; gap: 8px; cursor: pointer; }
summary::before { content: "▸"; font-size: 0.8em; transition: transform 0.15s ease; }
details[open] > summary::before { transform: rotate(90deg); }
summary::-webkit-details-marker { display: none; }
.problem summary::before { content: none; }
/* Text links and link-buttons keep their look but get a 44 px tap area. */
button.link, .lb-btn { padding-top: 12px; padding-bottom: 12px; margin-top: -12px; margin-bottom: -12px; }
.site-foot a, .site-bar nav a:not(.btn), .site-doc nav a { display: inline-block; padding: 12px 0; margin: -12px 0; }
.site-bar nav a:not(.btn) { padding: 11px 4px; margin: 0; }
.tabs button { min-height: 44px; }
.g-hide { min-height: 32px; }
.g-hide::after { content: ""; position: absolute; inset: -8px; }
.sign-templates label { min-height: 44px; }
.accent-field input { height: 44px; }
.btn-row input:not([type="file"]):not([type="hidden"]):not([type="checkbox"]):not([type="radio"]), .btn-row select { min-height: 44px; font-size: 16px; }
.plans-table input:not([type="checkbox"]) { font-size: 16px; min-height: 40px; }
.g-search { flex-wrap: wrap; }
.g-search input { flex: 1 1 160px; min-width: 0; min-height: 44px; font-size: 16px; }
.g-search select { flex: 1 1 140px; min-width: 0; width: auto; min-height: 44px; }
.facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 520px) { .facts { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.status-events dl { grid-template-columns: repeat(auto-fit, minmax(90px, 1fr)); }
.copy-row, .problem-msg, .status-table td { overflow-wrap: anywhere; }

/* Long forms: the save button stays in reach while the form is on screen. */
.sticky-actions {
  position: sticky; bottom: 0; z-index: 4; margin: 12px -18px -18px; padding: 12px 18px calc(12px + env(safe-area-inset-bottom));
  background: var(--card); border-top: 1px solid var(--line); border-radius: 0 0 var(--radius) var(--radius);
  display: flex; flex-wrap: wrap; gap: 8px;
}
.sticky-actions .btn { margin-top: 0; flex: 1 1 auto; }
.sign-form .sticky-actions { margin: 14px -18px -18px; }
@media (min-width: 800px) { .sticky-actions .btn { flex: 0 0 auto; } }

/* Admin top bar: brand and a Menu button on phones, the links inline on wider screens. */
.admin-bar { position: sticky; top: 0; z-index: 20; gap: 12px; padding: calc(6px + env(safe-area-inset-top)) 16px 6px; min-height: 56px; }
.admin-nav.wide { display: none; }
.admin-menu { position: relative; margin-left: auto; }
.admin-menu summary { min-height: 44px; padding: 0 16px; border: 1px solid var(--line); border-radius: 999px; font-weight: 600; font-size: 0.95rem; }
.admin-menu summary::before { content: "☰"; font-size: 1rem; transform: none !important; }
.admin-menu nav {
  position: absolute; right: 0; top: calc(100% + 8px); min-width: 220px; display: grid; padding: 6px; background: var(--card);
  border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 16px 40px -16px rgba(31, 27, 22, 0.45);
}
.admin-menu nav a, .admin-menu nav button {
  display: flex; align-items: center; min-height: 48px; padding: 0 14px; border-radius: 10px; text-decoration: none; color: var(--ink);
  font: 500 1rem var(--sans); background: none; border: 0; width: 100%; text-align: left; cursor: pointer;
}
.admin-menu nav a[aria-current="page"] { background: var(--paper); font-weight: 600; }
.admin-menu nav form { border-top: 1px solid var(--line); margin-top: 4px; padding-top: 4px; }
.admin-menu nav button { color: var(--muted); }
.admin-main { padding: 18px 16px calc(48px + env(safe-area-inset-bottom)); }
.admin-main h1 { font-size: 1.7rem; }
.card { padding: 16px; }
.sticky-actions { margin-left: -16px; margin-right: -16px; margin-bottom: -16px; padding-left: 16px; padding-right: 16px; }
@media (min-width: 760px) {
  .admin-bar { padding: 14px 20px; }
  .admin-nav.wide { display: flex; }
  .admin-nav.wide a { padding: 10px 2px; }
  .admin-nav.wide a[aria-current="page"] { color: var(--ink); font-weight: 600; }
  .admin-menu { display: none; }
  .admin-main { padding: 22px 20px 60px; }
  .admin-main h1 { font-size: 1.9rem; }
  .card { padding: 18px; }
  .sticky-actions { margin-left: -18px; margin-right: -18px; margin-bottom: -18px; padding-left: 18px; padding-right: 18px; }
}
.event-list li { flex-wrap: wrap; }
.event-list a { flex: 1 1 200px; min-height: 44px; }
.btn-row .btn { flex: 0 1 auto; }
.row-between { flex-wrap: wrap; }

/* Wide tables become stacked cards on phones (cells carry data-label). */
@media (max-width: 640px) {
  .status-table.stack, .status-table.stack tbody, .status-table.stack tr, .status-table.stack td, .status-table.stack tbody th { display: block; width: auto; }
  .status-table.stack thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .status-table.stack tr { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
  .status-table.stack td, .status-table.stack tbody th { border: 0; padding: 0; }
  .status-table.stack tbody th, .status-table.stack td.wide-cell { grid-column: 1 / -1; }
  .status-table.stack tbody th { font-family: var(--serif); font-size: 1.1rem; }
  .status-table.stack td[data-label]::before { content: attr(data-label); display: block; font-size: 0.72rem; color: var(--muted); margin-bottom: 2px; }
  .plans-table.stack { overflow: visible; }
  .plans-table.stack tr:not(.plan-blurb) { border-bottom: 0; padding-bottom: 4px; }
  .plans-table.stack tr.plan-blurb { padding-top: 4px; border-bottom: 2px solid var(--line); margin-bottom: 8px; }
  .plans-table.stack td:has(> input[type="checkbox"]) { display: flex; flex-direction: row-reverse; justify-content: flex-end; align-items: center; gap: 10px; min-height: 44px; }
  .plans-table.stack td:has(> input[type="checkbox"])::before { margin: 0; font-size: 0.9rem; color: var(--ink); }
}

/* Couple dashboard and guest page on phones */
.home-card .btn-row .btn { flex: 1 1 auto; }
.mine-actions .link { padding: 12px 0; margin: -12px 0; }
.sheet { max-height: calc(100dvh - 32px); overflow: auto; }
.lightbox .lb-top { padding-top: calc(10px + env(safe-area-inset-top)); }
.show-full { top: calc(16px + env(safe-area-inset-top)); right: calc(16px + env(safe-area-inset-right)); min-height: 44px; }
.home-cover { margin: -16px -16px 6px; }
@media (min-width: 760px) { .home-cover { margin: -18px -18px 6px; } }
.admin-brand, .site-brand { display: inline-flex; align-items: center; min-height: 44px; }
.plans-table input:not([type="checkbox"]) { min-height: 44px; }
a.link, .status-events a, .site-doc p a, .site-doc li a { padding-top: 12px; padding-bottom: 12px; }
.home-card .link, .privacy-note a { padding-top: 12px; padding-bottom: 12px; }
@media (max-width: 519px) { .event-list .pill-col { justify-items: start; grid-auto-flow: column; justify-content: start; gap: 6px; } }
.sign-downloads { grid-template-columns: 1.4fr 1fr 1fr; }
.sign-downloads.sticky-actions { display: grid; }
.sign-downloads .btn { padding: 0 8px; font-size: 0.88rem; }
.admin-brand, .site-brand { gap: 0.3em; }
.sign-downloads .btn { white-space: nowrap; font-size: 0.85rem; }

/* A picker that cannot take anything more (the guest book is full). */
label.is-disabled { opacity: 0.45; pointer-events: none; }

/* ===================================================================
   Polish (12 Dec release): one spacing and type scale, calm motion,
   sign-in steps, skeletons. Appended last so it wins over older rules.
   =================================================================== */
:root {
  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 24px; --s6: 32px; --s7: 48px;
  --t-xs: 0.75rem; --t-sm: 0.875rem; --t-md: 1rem; --t-lg: 1.15rem; --t-xl: 1.35rem;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --shadow-1: 0 1px 2px rgba(31, 27, 22, 0.06), 0 8px 24px -16px rgba(31, 27, 22, 0.35);
}
h2 { font-size: var(--t-xl); line-height: 1.25; }
h3 { font-size: var(--t-md); line-height: 1.35; margin: 0; }
.fine { font-size: var(--t-sm); line-height: 1.45; }
.card { box-shadow: var(--shadow-1); }
.form { display: grid; gap: var(--s4); grid-template-columns: minmax(0, 1fr); } /* one column that never grows past its card (a wide image or file input stretched it in Safari) */
.field > span:first-child { font-size: var(--t-sm); }

/* Every tap answers at once; nothing bounces. */
.btn { transition: transform 0.12s var(--ease), background-color 0.2s var(--ease), border-color 0.2s var(--ease), opacity 0.2s var(--ease), box-shadow 0.2s var(--ease); }
.btn.primary:hover { background: #3a332b; }
.btn.quiet:hover { border-color: var(--muted); }
.card, .home-card { transition: box-shadow 0.25s var(--ease), opacity 0.25s var(--ease); }
input, select, textarea { transition: border-color 0.15s var(--ease), box-shadow 0.15s var(--ease); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgba(127, 97, 55, 0.18); }

/* Page to page: a soft cross-fade where the browser can (Chrome, Edge, Safari 18.2+). */
@view-transition { navigation: auto; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: 0.22s; animation-timing-function: var(--ease); }
/* Content that appears after a load eases in instead of popping. */
@keyframes rise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
/* Only what is drawn after a load: server-drawn pages paint at once (no delay to first paint). */
#home-body > * { animation: rise 0.32s var(--ease) both; }
#home-body > *:nth-child(2) { animation-delay: 40ms; }
#home-body > *:nth-child(3) { animation-delay: 80ms; }
#home-body > *:nth-child(n+4) { animation-delay: 120ms; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
  @view-transition { navigation: none; }
}

/* Skeletons: the shape of what is coming, so nothing jumps when it lands. */
.skeleton { position: relative; overflow: hidden; background: #ece4d5; border-radius: var(--radius); }
.skeleton::after { content: ""; position: absolute; inset: 0; transform: translateX(-100%); background: linear-gradient(90deg, transparent, rgba(255, 253, 248, 0.6), transparent); animation: shimmer 1.3s infinite; }
@keyframes shimmer { to { transform: translateX(100%); } }
.skeleton-card { height: 220px; margin-bottom: var(--s4); }
.skeleton-card.short { height: 120px; }
.skeleton-line { height: 14px; border-radius: 7px; margin: var(--s2) 0; }

/* ---------------------------------------------------- sign-in steps */
.code-input { font: 600 1.6rem/1 ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0.4em; text-align: center; padding-left: 0.4em; min-height: 60px; }
.code-form.is-sending .btn.primary { position: relative; color: transparent; }
.code-form.is-sending .btn.primary::after { content: ""; position: absolute; width: 20px; height: 20px; border-radius: 50%; border: 2px solid var(--accent-ink); border-right-color: transparent; animation: spin 0.7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.resend-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s3); margin-top: var(--s4); }
.resend-row .btn[disabled] { opacity: 0.6; font-variant-numeric: tabular-nums; }
.field-note { display: block; margin-top: var(--s1); font-size: var(--t-sm); color: var(--muted); min-height: 1.2em; }
.field-note[data-state="ok"] { color: var(--ok); }
.field-note[data-state="bad"] { color: var(--bad); }
.field-error { display: block; margin-top: var(--s1); font-size: var(--t-sm); color: var(--bad); }
input[aria-invalid="true"] { border-color: var(--bad); }
.start-more { border-top: 1px solid var(--line); padding-top: var(--s2); }
.start-more summary { font-size: var(--t-sm); color: var(--muted); cursor: pointer; }
.start-more summary span { color: var(--ink); }
.start-more[open] summary { margin-bottom: var(--s3); }
.plan-pick label:has(input:checked) { border-color: var(--ink); background: var(--card); box-shadow: inset 0 0 0 1px var(--ink); }

/* --------------------------------------------- "you're set up" list */
.setup { border: 1px solid var(--line); }
.setup h2 { margin: var(--s1) 0 var(--s3); }
.setup-bar { height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; margin-bottom: var(--s4); }
.setup-bar span { display: block; height: 100%; background: var(--ok); border-radius: 3px; transition: width 0.5s var(--ease); }
.setup-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s3); }
.setup-list li { display: grid; grid-template-columns: 28px 1fr auto; gap: var(--s3); align-items: center; padding: var(--s3) 0; border-top: 1px solid var(--line); }
.setup-list li:first-child { border-top: 0; }
.setup-tick { width: 28px; height: 28px; border-radius: 50%; border: 1.5px solid var(--line); display: grid; place-items: center; font-size: 0.9rem; color: #fff; transition: background 0.2s var(--ease); }
.setup-list li.done .setup-tick { background: var(--ok); border-color: var(--ok); }
.setup-list li.done strong { color: var(--muted); }
.setup-done { color: var(--ok); }
.setup-hide { margin-top: var(--s3); font-size: var(--t-sm); }
@media (max-width: 420px) {
  .setup-list li { grid-template-columns: 28px 1fr; }
  .setup-list li > :last-child { grid-column: 2; justify-self: start; }
}

/* Optimistic toggles: show the new state at once, dim while it saves. */
.is-saving { opacity: 0.6; pointer-events: none; }

/* Studio logo (owner's PSD): small, never the star. */
.brand-logo { height: 30px; width: auto; display: inline-block; vertical-align: middle; margin-right: 10px; }
.admin-brand { display: inline-flex; align-items: center; }
.login-logo { height: 64px; width: auto; margin: 0 auto 12px; }
.studio-foot { display: flex; flex-direction: column; align-items: center; gap: 6px; margin-top: 40px; }
.studio-foot img { height: 40px; width: auto; opacity: 0.85; }
.studio-foot span { font-size: 0.7rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); }

/* The refund rule, beside every way to pay. */
.refund-line { margin-top: var(--s2); }
.pay-bar .refund-line { flex-basis: 100%; }
.refund-status { padding: var(--s2) var(--s3); border-radius: 10px; border: 1px solid var(--line); }
.refund-status.ok { border-color: var(--ok); }
.refund-status.no { border-color: var(--bad); }

/* Quick start on the dashboard (src/client/home.ts): the QR card, confirm-your-email, choose a plan. */
.qr-card { display: grid; gap: 18px; align-items: center; }
.qr-img { width: 176px; height: 176px; justify-self: center; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 6px; }
@media (min-width: 640px) { .qr-card { grid-template-columns: 176px 1fr; } }
.confirm-card { border-color: var(--accent); }
.inline-code { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; }
.inline-code .field { flex: 1 1 12rem; margin: 0; }
.upgrade-row { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; justify-content: space-between; padding: 14px 0; border-top: 1px solid var(--line); }
.upgrade-row div { display: grid; gap: 2px; flex: 1 1 16rem; }

/* Booth mode on the guest page (?booth=1): the hand-over bar for the next guest. */
.booth-bar { position: sticky; bottom: 0; z-index: 4; display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; justify-content: space-between; margin: 16px -16px 0; padding: 14px 16px calc(14px + env(safe-area-inset-bottom)); background: var(--card); border-top: 1px solid var(--line); box-shadow: 0 -6px 18px rgba(31, 27, 22, .08); }
.booth-bar p { margin: 0; font-weight: 600; }

/* ------------------------------------------- self-serve sign designer (2026-11) */
.sd { max-width: 1140px; margin: 0 auto; padding: 14px 16px 24px; }
.sd [hidden] { display: none !important; }
.sd-back { margin: 0 0 6px; }
.sd-head { margin: 0 0 14px; }
.sd-head h1 { font-size: clamp(1.6rem, 6vw, 2.4rem); }
.sd-grid { display: grid; gap: 16px; }
@media (min-width: 900px) {
  .sd-grid { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); align-items: start; gap: 28px; }
  .sd-stage { position: sticky; top: 16px; }
}
.sd-stage { display: grid; gap: 8px; min-width: 0; }
.sd-frame-wrap { display: grid; place-items: center; background: #ebe6dc; border-radius: 16px; padding: clamp(16px, 5vw, 40px); min-height: 220px; }
.sd-frame { background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08), 0 14px 34px -20px rgba(0, 0, 0, 0.5); max-width: 100%; opacity: 0.35; transition: opacity 0.2s; }
.sd-ready .sd-frame { opacity: 1; }
.sd-frame.round, .sd-thumb.round { border-radius: 50%; }
.sd-frame svg, .sd-thumb svg { display: block; width: 100%; height: 100%; }
.sd-form { display: grid; gap: 12px; min-width: 0; }
.sd-section { border: 0; margin: 0; padding: 14px 16px 16px; background: var(--card); border-radius: 14px; box-shadow: var(--shadow-1); display: grid; gap: 12px; min-width: 0; }
.sd-section legend { float: left; width: 100%; padding: 0; margin: 0 0 2px; font: 600 0.74rem/1.2 var(--sans); letter-spacing: 0.09em; text-transform: uppercase; color: var(--muted); }
.sd-section .field { margin: 0; }
.sd-section .check { margin: 0; }
.sd-gallery { display: grid; grid-auto-flow: column; grid-auto-columns: 96px; gap: 12px; overflow-x: auto; padding: 4px 4px 10px; margin: 0 -4px; scroll-snap-type: x proximity; align-items: end; }
@media (min-width: 900px) { .sd-gallery { grid-auto-flow: row; grid-template-columns: repeat(5, minmax(0, 1fr)); overflow: visible; } }
.sd-pick { display: grid; gap: 6px; cursor: pointer; font-size: 0.74rem; line-height: 1.2; text-align: center; scroll-snap-align: start; position: relative; align-content: end; }
.sd-pick input { position: absolute; opacity: 0; pointer-events: none; }
.sd-thumb { display: block; width: 100%; background: #fff; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1), 0 6px 14px -10px rgba(0, 0, 0, 0.5); outline: 2px solid transparent; outline-offset: 3px; transition: outline-color 0.15s; }
.sd-pick input:checked + .sd-thumb { outline-color: var(--ink); }
.sd-pick input:focus-visible + .sd-thumb { outline-color: var(--accent); }
.sd-pick input:checked ~ .sd-pick-name { font-weight: 600; }
.sd-previous summary { cursor: pointer; font-size: var(--t-sm); color: var(--muted); min-height: 32px; display: flex; align-items: center; }
.sd-previous ul { margin: 6px 0 0; padding-left: 18px; columns: 2; font-size: var(--t-sm); line-height: 1.9; }
.sd-row { display: grid; gap: 8px; }
.sd-label { font-size: var(--t-sm); }
.sd-swatches { display: flex; flex-wrap: wrap; gap: 10px; }
.sd-swatch { width: 38px; height: 38px; border-radius: 50%; border: 1px solid rgba(0, 0, 0, 0.14); background: var(--c); cursor: pointer; padding: 0; position: relative; flex: 0 0 auto; }
.sd-swatch[aria-pressed="true"], .sd-pal:has(input:checked) { box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--ink); }
.sd-custom { background: conic-gradient(#e0533d, #e7b542, #63b36b, #3d8fd1, #8a5cc7, #e0533d); overflow: hidden; }
.sd-custom input { opacity: 0; width: 100%; height: 100%; cursor: pointer; border: 0; padding: 0; }
.sd-pal input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.sd-pal::after { content: ""; position: absolute; inset: 12px; border-radius: 50%; background: var(--i); pointer-events: none; }
.sd-seg { display: flex; flex-wrap: wrap; gap: 6px; }
.sd-seg label { position: relative; }
.sd-seg input { position: absolute; opacity: 0; }
.sd-seg span { display: inline-flex; align-items: center; min-height: 40px; padding: 0 14px; border: 1px solid var(--line); border-radius: 99px; font-size: 0.88rem; cursor: pointer; background: #fff; }
.sd-seg input:checked + span { background: var(--ink); color: var(--accent-ink); border-color: var(--ink); }
.sd-seg input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.sd-photo { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.sd-photo .fine { flex-basis: 100%; margin: 0; }
.sd-file { position: relative; overflow: hidden; }
.sd-file input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.sd-photo-clear { background: none; border: 0; padding: 0; font: inherit; font-size: var(--t-sm); cursor: pointer; }
.sd-downloads { position: sticky; bottom: 0; z-index: 2; display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 8px; margin: 0 -16px; padding: 14px 16px calc(12px + env(safe-area-inset-bottom)); background: linear-gradient(rgba(246, 241, 231, 0), var(--paper) 28%); }
@media (min-width: 900px) { .sd-downloads { margin: 0; padding-left: 0; padding-right: 0; } }
.sd-downloads .btn { min-height: 48px; margin: 0; white-space: nowrap; padding: 0 10px; }
.sd-downloads .btn:disabled { opacity: 0.45; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* ===================================================================
   Guest page (revamp, 16 Nov 2026). One spacing scale (--s1..--s7), one
   centre line, the same treatment on every tab. Appended last so it wins.
   =================================================================== */
.guest { padding: 0 var(--s4) calc(var(--s6) + env(safe-area-inset-bottom)); }
@media (min-width: 400px) { .guest { padding-left: 20px; padding-right: 20px; } }

/* Header: compact without a cover; with one, a fixed-height frame (no jump while it loads). */
.guest .hero { padding: calc(var(--s5) + env(safe-area-inset-top)) 0 var(--s4); text-align: center; }
.guest .hero-text { display: grid; gap: var(--s2); justify-items: center; }
.guest .hero .eyebrow { margin: 0; }
.guest .hero h1 { font-size: clamp(1.9rem, 8.4vw, 2.75rem); line-height: 1.08; }
.guest .hero .date { font-size: 1rem; }
.guest .hero.has-image { margin: 0 calc(-1 * var(--s4)); padding: 0 0 var(--s4); }
@media (min-width: 400px) { .guest .hero.has-image { margin: 0 -20px; } }
.guest .hero-frame { position: relative; height: clamp(150px, 30svh, 300px); overflow: hidden; background: var(--line); }
.guest .hero-frame::after { content: ""; position: absolute; inset: auto 0 0; height: 40%; background: linear-gradient(rgba(246, 241, 231, 0), var(--paper)); pointer-events: none; }
.guest .hero.has-image .hero-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.guest .hero.has-image .hero-text { position: relative; margin: calc(-1 * var(--s5)) var(--s4) 0; padding: 0; background: none; border-radius: 0; }
@media (min-width: 600px) {
  .guest .hero.has-image { margin: var(--s5) 0 0; }
  .guest .hero-frame { height: 300px; border-radius: var(--radius); }
  .guest .hero-frame::after { display: none; }
  .guest .hero.has-image .hero-text { margin-top: var(--s4); }
}

/* Welcome and what to do: one centred column. */
.guest .start { gap: var(--s2); padding: 0; text-align: center; }
.guest .start .lede { margin: 0; font-size: 1.08rem; line-height: 1.45; }
.guest .welcome { margin: 0; font-size: 1.05rem; }

/* Tabs: a segmented control inside the page's width, on a sticky strip of paper (nothing shows around it). */
.guest .g-tabs-wrap { position: sticky; top: 0; z-index: 6; margin: var(--s3) calc(-1 * var(--s4)) 0; padding: var(--s2) var(--s4); background: var(--paper); }
@media (min-width: 400px) { .guest .g-tabs-wrap { margin-left: -20px; margin-right: -20px; padding-left: 20px; padding-right: 20px; } }
.guest .g-tabs-wrap:has(> .g-tabs[hidden]):has(> .sending-pill[hidden]) { display: none; }
.guest .g-tabs {
  position: static; display: flex; gap: var(--s1); margin: 0; padding: var(--s1);
  background: var(--card); border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 6px 14px -12px rgba(31, 27, 22, 0.45);
  overflow-x: auto; scrollbar-width: none;
}
.guest .g-tabs button {
  flex: 1 1 0; min-width: 0; min-height: 48px; padding: var(--s1) var(--s1); border-radius: 12px; gap: 2px;
  font: 500 0.78rem/1.15 var(--sans); white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.guest .g-tabs button svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.guest .tiles:empty { display: none; }
.guest .sending-pill { margin-top: var(--s2); }

/* Every panel: the same gap, everything centred except cards and tiles. */
.guest .g-panel { gap: var(--s4); padding-top: var(--s3); }
.guest .g-tabs-wrap:has(> .g-tabs[hidden]) + .g-panel, .guest .g-tabs-wrap[hidden] + .g-panel { padding-top: var(--s4); }
.guest .g-panel > .fine, .guest .pickers > .fine, .guest #share-fine { text-align: center; margin: 0; }
.guest .pickers { display: grid; gap: var(--s3); }

/* The two ways to add: one group. Primary full width; the camera one the same width, quieter. */
.guest .add-actions { display: grid; gap: var(--s2); }
.guest .add-actions .btn { width: 100%; }
.guest .btn.big { min-height: 60px; font-size: 1.1rem; box-shadow: 0 10px 22px -14px rgba(31, 27, 22, 0.6); }
.guest .btn.second { min-height: 52px; background: var(--card); color: var(--ink); border: 1px solid var(--line); font-weight: 600; font-size: 1rem; }
.guest .btn.second:hover { border-color: var(--muted); }
.guest .btn.second svg { width: 20px; height: 20px; }
input:focus-visible + .btn.second { outline: 2px solid var(--accent); outline-offset: 3px; }

/* Progress, notes, voice, nudges: cards with the same padding and heading size. */
.guest .g-panel .card { padding: var(--s4); }
.guest .progress-head strong, .guest .note h2, .guest .voice h2, .guest .nudge strong, .guest .note-saved strong { font-size: 1.15rem; }
.guest .note form { display: grid; gap: 0; }
.guest .note .field { margin-top: var(--s3); }
.guest .note .btn { margin-top: var(--s4); }
.guest .prompts { margin-top: var(--s3); }
.guest .voice { gap: var(--s3); }
.guest .voice .btn-row { gap: var(--s2); }
.guest .nudge { gap: var(--s1); }
.guest .mine-bar { margin-top: 0; }
.guest .mine-actions { margin-top: 0; }
.guest .full-note { margin: 0; }

/* Shared with everyone, closed and not-yet-open states: the same rhythm. */
.guest .shared { gap: var(--s2); }
.guest > .start + .mine-bar, .guest > .start + .shared { margin-top: var(--s5); }
.guest > .start.status .lede { padding: var(--s4); background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }
.guest .privacy-note { margin-top: var(--s6); padding: var(--s4); gap: var(--s1); }
.guest .lang-switch { margin-top: var(--s5); }
.guest .foot { margin-top: var(--s5); }
.guest .demo-bar { margin-top: var(--s3); }

/* Passcode and "scan the code" pages. */
.access { padding-top: max(12vh, var(--s6)); }
.access h1 { font-size: clamp(1.9rem, 8.4vw, 2.6rem); }
.access .passcode-form { margin-top: var(--s4); gap: var(--s3); }
.access .passcode-form .field { margin-top: 0; }

/* Dashboard: the cover photo control (src/client/home.ts coverSection). */
.cover-section { display: grid; gap: var(--s2); }
.cover-frame { position: relative; display: block; width: 100%; aspect-ratio: 4 / 3; padding: 0; border: 1px solid var(--line); border-radius: 12px; background: #2a251f; overflow: hidden; cursor: crosshair; }
.cover-frame img { width: 100%; height: 100%; object-fit: contain; }
.cover-dot { position: absolute; width: 22px; height: 22px; margin: -11px 0 0 -11px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.45); pointer-events: none; }
.cover-edit { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 12px; }

/* Slideshow before the first photo: the cover, dimmed, behind the name. */
.show-cover { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0.38; }
.show-empty > :not(.show-cover) { position: relative; }
.show-empty .eyebrow { color: #d9c39a; }

/* Host gallery: choosing which waiting photos and notes to approve or reject (src/client/gallery.ts). */
.approve-bar { justify-content: center; margin: 0 0 14px; }
.approve-bar .fine { flex-basis: 100%; text-align: center; }
.g-pick { position: absolute; top: 5px; left: 5px; display: inline-flex; align-items: center; gap: 4px; min-height: 28px; padding: 0 8px 0 6px; border-radius: 99px; background: var(--ink); color: #fff; font: 600 0.68rem var(--sans); cursor: pointer; }
.g-pick input { width: 16px; height: 16px; margin: 0; accent-color: #fff; }
.g-reject { top: 40px; color: var(--bad); }
.m-pick { margin: 0; font-size: 0.82rem; }
