/* AnInvite.To: the post office, made modern. Pages are envelope paper and ink; colour arrives as
   stamps. The coral ".to" stamp is the brand; each event's stamp is printed in its own colour.
   Fonts are served from here (no third-party font requests): Bricolage Grotesque for headings,
   Instrument Sans for text, JetBrains Mono for dates, codes and addresses, all SIL Open Font
   License (see fonts/OFL-*.txt). */
@font-face {
  font-family: "Bricolage Grotesque"; font-style: normal; font-weight: 500 800; font-display: swap;
  src: url(fonts/bricolage-latin.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: "Bricolage Grotesque"; font-style: normal; font-weight: 500 800; font-display: swap;
  src: url(fonts/bricolage-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Instrument Sans"; font-style: normal; font-weight: 400 600; font-display: swap;
  src: url(fonts/instrument-sans-latin.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: "Instrument Sans"; font-style: normal; font-weight: 400 600; font-display: swap;
  src: url(fonts/instrument-sans-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "JetBrains Mono"; font-style: normal; font-weight: 500 700; font-display: swap;
  src: url(fonts/jetbrains-mono-latin.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: "JetBrains Mono"; font-style: normal; font-weight: 500 700; font-display: swap;
  src: url(fonts/jetbrains-mono-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  /* --accent, --on-accent and --link are set per page from the event's colour */
  --accent: #ff5a4e;
  --on-accent: #1a1530;
  --link: #1a1530;
  /* the stamps: coral is the brand (the ".to" stamp); postal navy frames stamps and tints notices */
  --coral: #ff5a4e;
  --brand: #1c2c6b;
  --stamp-paper: #fffdf8;
  /* envelope paper and ink */
  --bg: #f6f3ec;
  --card: #fffdf8;
  --ink: #1a1530;
  --ink-2: #4d4760;
  --muted: #655e74;
  --line: #e5ddcd;
  --field: #fffdf8;
  --field-line: #d6ccb8;
  --ok-bg: #e7f2ec;
  --ok-ink: #22684a;
  --err-bg: #fbe6e3;
  --err-ink: #9e2a20;
  --warn-bg: #fbf0dc;
  --warn-ink: #8a5208;
  --radius: 16px;
  --display: "Bricolage Grotesque", ui-sans-serif, system-ui, sans-serif;
  --text: "Instrument Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --brand: #a9b6ff;
    --bg: #12101c;
    --card: #1c1929;
    --ink: #f4f0ff;
    --ink-2: #c3bcd6;
    --muted: #a39cb8;
    --line: #2e2a42;
    --field: #171424;
    --field-line: #3d3856;
    --ok-bg: #173226;
    --ok-ink: #8fdcb4;
    --err-bg: #3a1a18;
    --err-ink: #ffa49b;
    --warn-bg: #352812;
    --warn-ink: #f2bd62;
  }
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.55 var(--text);
}
img { max-width: 100%; }
.wrap { max-width: 720px; margin: 0 auto; padding: 16px; }
/* Dashboards: the main column (guests) and a side column (activity, team, settings) on desktop */
.wrap.dash { max-width: 1180px; }
.dash-grid { display: grid; grid-template-columns: minmax(0, 1.75fr) minmax(0, 1fr); gap: 16px; align-items: start; }
.dash-grid > div { min-width: 0; }
.dash-side .row { grid-template-columns: 1fr; gap: 0; }
.dash-side .stats > div { flex-basis: 34%; }
.dash-side .stats.funnel > div { flex-basis: 26%; }
.dash-links { display: grid; grid-template-columns: 1fr 1fr; gap: 0 20px; }
@media (max-width: 900px) { .dash-grid, .dash-links { grid-template-columns: 1fr; } }
h1, h2, h3 { font-family: var(--display); line-height: 1.08; margin: 0 0 .5em; letter-spacing: -.02em; overflow-wrap: break-word; hyphens: auto; }
h1 { font-size: clamp(2rem, 6vw, 2.6rem); font-weight: 800; letter-spacing: -.035em; }
h2 { font-size: 1.4rem; font-weight: 700; }
h3 { font-size: 1.1rem; font-weight: 700; }
a { color: var(--link); text-underline-offset: 3px; }
p { margin: 0 0 .75em; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.lead { font-size: 1.1rem; color: var(--ink-2); }
/* The small label above a page's title ("Host dashboard · Business event") */
.eyebrow { font: 600 .75rem/1.3 var(--text); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin: 0 0 10px; }
.eyebrow a { color: inherit; }

/* Stamps: perforated paper (the edge is cut with a mask) around a printed area */
.stamp {
  --p: .085em;
  display: inline-block; position: relative; flex: none; vertical-align: middle;
  background: var(--stamp-paper);
  padding: calc(var(--p) * 2.6);
  -webkit-mask:
    radial-gradient(circle, #0000 calc(var(--p) - .5px), #000 var(--p)) calc(var(--p) * -1.25) calc(var(--p) * -1.25) / calc(var(--p) * 2.5) calc(var(--p) * 2.5) round,
    linear-gradient(#000 0 0) center / calc(100% - var(--p) * 2) calc(100% - var(--p) * 2) no-repeat;
          mask:
    radial-gradient(circle, #0000 calc(var(--p) - .5px), #000 var(--p)) calc(var(--p) * -1.25) calc(var(--p) * -1.25) / calc(var(--p) * 2.5) calc(var(--p) * 2.5) round,
    linear-gradient(#000 0 0) center / calc(100% - var(--p) * 2) calc(100% - var(--p) * 2) no-repeat;
}
.stamp-sh { display: inline-block; filter: drop-shadow(0 .05em .08em rgb(20 10 40 / .22)) drop-shadow(0 .18em .35em rgb(20 10 40 / .12)); }
.stamp-print { display: grid; position: relative; }
/* The event's stamp: date and name in typewriter type, framed in the event's colour */
.ev-stamp .stamp-print {
  border: max(1px, .03em) solid var(--stamp-ink, #1c2c6b); color: var(--stamp-ink, #1c2c6b);
  padding: .2em .3em; min-width: 2.7em; height: 1.85em; align-content: center; gap: .12em; letter-spacing: 0; text-align: left;
}
.ev-stamp .d { font: 700 .22em/1 var(--mono); letter-spacing: .04em; }
/* Titles are at most 30 characters (TITLE_MAX), so the stamp grows to show them whole; older,
   longer titles are cut at that width. 1ch is one character of the typewriter type. */
.ev-stamp .n { font: 600 .28em/1.15 var(--mono); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 30ch; }

/* The logo: "aninvite", the coral ".to" stamp, and on an event's pages the event's stamp */
.logo { display: inline-flex; align-items: center; white-space: nowrap; line-height: 1; color: var(--ink); font-size: 1.35rem; }
.logo-w { font: 800 1em/1 var(--display); letter-spacing: -.04em; }
.logo-w span { margin-left: .12em; }
.logo-to { transform: rotate(-6deg); margin-left: .22em; z-index: 1; }
.logo-to .stamp-print { background: var(--coral); color: #fffdf8; width: 1.55em; height: 1.85em; place-items: center; font: 800 .78em/1 var(--display); letter-spacing: -.04em; }
.logo-ev { transform: rotate(5deg) translate(-.3em, .3em); }
/* In the header the event's stamp is read, not just seen: bigger type inside the same stamp */
.site .logo { font-size: 1.5rem; }
.site .logo-ev .stamp-print { height: auto; min-height: 1.85em; padding: .18em .34em; gap: .1em; }
.site .logo-ev .d { font-size: .3em; }
.site .logo-ev .n { font-size: .42em; }
/* Phones: a smaller logo; a 30-character title still fits next to it */
@media (max-width: 480px) { .site .logo { font-size: 1.2rem; } }
@media (prefers-color-scheme: dark) { .stamp-sh { filter: drop-shadow(0 .06em .12em rgb(0 0 0 / .5)); } }

/* The event's address: "aninvite.to/" in front of the editable part */
.path-field { display: flex; align-items: center; border: 1px solid var(--field-line); border-radius: 12px; background: var(--field); padding-left: 14px; font-family: var(--mono); font-size: .9rem; }
.path-field span { color: var(--muted); white-space: nowrap; }
.path-field input[type=text] { border: 0; background: none; padding-left: 0; font-family: var(--mono); font-size: .9rem; min-width: 0; }
.path-field:focus-within { outline: 2px solid var(--ink); outline-offset: 1px; }
.path-field input:focus-visible { outline: none; }

/* The event colour: eight swatches and "other" */
fieldset.swatches { border: 0; padding: 0; margin: 14px 0 0; }
fieldset.swatches legend { font-weight: 600; font-size: .9rem; padding: 0; margin-bottom: 4px; }
fieldset.swatches p { margin: 0 0 8px; }
.swatch-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.swatch { position: relative; margin: 0; cursor: pointer; }
.swatch > input[type=radio] { position: absolute; opacity: 0; width: 1px; height: 1px; }
.swatch > span { display: block; width: 36px; height: 36px; border-radius: 50%; background: var(--sw); box-shadow: inset 0 0 0 1px rgb(0 0 0 / .12); }
.swatch > input:checked + span { box-shadow: 0 0 0 2px var(--card), 0 0 0 4px var(--ink); }
.swatch > input:focus-visible + span { outline: 2px solid var(--ink); outline-offset: 4px; }
.swatch.other { display: inline-flex; align-items: center; gap: 6px; padding: 4px 6px 4px 12px; border: 1.5px solid var(--field-line); border-radius: 999px; }
.swatch.other > span { width: auto; height: auto; border-radius: 0; background: none; box-shadow: none; font-weight: 600; }
.swatch.other > input:checked + span { box-shadow: none; text-decoration: underline; }
.swatch.other:has(input:checked) { border-color: var(--ink); }
.swatch.other input[type=color] { width: 36px; min-height: 0; height: 28px; padding: 0; border: 0; border-radius: 6px; background: none; }

/* Header & footer */
.site { display: flex; align-items: center; padding-top: 22px; padding-bottom: 14px; min-width: 0; }
.site a { text-decoration: none; color: var(--ink); min-width: 0; }
.foot { text-align: center; color: var(--muted); font-size: .875rem; padding: 32px 16px 48px; }
.foot a { color: var(--ink); text-decoration: none; }
.foot .logo { font-size: 1rem; vertical-align: middle; margin-right: .3em; }
.foot .foot-link { display: inline-block; margin-top: 8px; color: var(--muted); text-decoration: underline; }
.prose h2 { margin-top: 1.4em; font-size: 1.2rem; }
.prose ul { padding-left: 1.2em; }
.prose li { margin-bottom: .5em; }

.card {
  --pad: 24px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--pad);
  margin-bottom: 16px;
}
@media (max-width: 480px) { .card { --pad: 18px; } }

/* Invitation hero: a cover in the event's colour (or the host's picture) with the event's stamp
   stuck on its edge, then the invitation itself, set like a letter */
.hero { position: relative; overflow: hidden; padding-top: 0; }
.hero-top { position: relative; margin: 0 calc(var(--pad) * -1) 0; }
.hero .band {
  height: 120px; background-color: var(--accent);
  background-image: radial-gradient(rgb(255 255 255 / .38) 2px, transparent 2.5px), radial-gradient(rgb(255 255 255 / .22) 1.5px, transparent 2px);
  background-size: 26px 26px, 17px 17px; background-position: 0 0, 9px 11px;
}
.hero .band.pinstripe { background-image: repeating-linear-gradient(135deg, rgb(255 255 255 / .12) 0 2px, transparent 2px 14px); }
.theme-elegant .hero .band { background-image: none; }
.theme-garden .hero .band { background-image: repeating-linear-gradient(90deg, rgb(255 255 255 / .22) 0 10px, transparent 10px 18px); }
/* The title is the stamp, stuck in the top right corner as on an envelope, with the
   date printed on it and a postmark struck over its left edge. The paper stays light in dark mode. */
/* The invitation's details sit to its left, like the address; on phones they go below it. */
.title-stamp-wrap { position: relative; z-index: 1; float: right; margin: -96px -6px 14px 22px; }
.title-stamp { display: block; position: relative; max-width: 21rem; transform: rotate(3deg); }
.title-stamp .stamp { display: block; --p: 6px; }
.title-stamp .stamp-print {
  justify-items: center; gap: 2px; min-width: 11rem; padding: 12px 18px 16px; text-align: center;
  border: 2px solid var(--stamp-ink, #1c2c6b); color: #1a1530;
  background: color-mix(in srgb, var(--accent) 7%, var(--stamp-paper));
}
.ts-date { margin: 0; font: 700 .72rem/1 var(--mono); letter-spacing: .16em; color: var(--stamp-ink, #1c2c6b); }
.ts-emoji { margin: 6px 0 0; font-size: 2rem; line-height: 1; }
.hero .title-stamp .stamp-print h1 {
  margin: 6px 0 0; max-width: 14ch; color: #1a1530; font-size: clamp(1.4rem, 4.6vw, 2rem); line-height: 1.05;
  text-wrap: balance; overflow-wrap: anywhere; text-shadow: none;
}
.title-stamp .postmark { position: absolute; top: 50%; left: -48px; width: 84px; height: 84px; transform: translateY(-50%) rotate(-12deg); opacity: .8; }
@media (prefers-color-scheme: dark) { .title-stamp .postmark { color: var(--stamp-ink, #1c2c6b); } }
@media (max-width: 480px) {
  .title-stamp-wrap { float: none; display: flex; justify-content: flex-end; margin: -88px -4px 16px 0; }
  .title-stamp { max-width: 74%; }
  .title-stamp .stamp-print { min-width: 9rem; padding: 10px 12px 14px; }
  .title-stamp .postmark { width: 64px; height: 64px; left: -36px; }
}

.hero .emoji {
  position: relative; display: inline-grid; place-items: center; width: 4.6rem; height: 4.6rem; margin-top: -2.3rem; margin-bottom: 10px;
  font-size: 2.6rem; line-height: 1; border-radius: 50%; background: var(--card); box-shadow: 0 6px 18px rgb(0 0 0 / .16);
}
.hero h1 { margin: 22px 0 .3em; }
.hero .emoji + h1 { margin-top: 0; }
.hero .honoree { color: var(--ink); font-weight: 600; box-shadow: inset 0 -.45em 0 color-mix(in srgb, var(--accent) 45%, transparent); }
.facts { list-style: none; padding: 0; margin: 16px 0 0; text-align: left; display: grid; gap: 10px; }
.facts li { display: flex; gap: 12px; }
.facts .ic { width: 1.5em; text-align: center; flex: none; }

.banner { border-radius: 14px; padding: 12px 16px; margin-bottom: 16px; }
.banner.ok { background: var(--ok-bg); color: var(--ok-ink); }
.banner.err { background: var(--err-bg); color: var(--err-ink); }
.banner.cancel { background: var(--err-bg); color: var(--err-ink); text-align: center; font-weight: 600; }

/* Forms */
form { margin: 0; }
label { display: block; font-weight: 600; font-size: .9rem; margin: 14px 0 6px; }
label.inline { display: inline-flex; align-items: center; gap: 8px; font-weight: 400; margin: 6px 12px 6px 0; }
label.terms-box { display: flex; align-items: flex-start; margin: 16px 0 4px; }
label.terms-box input { margin-top: 4px; }
input[type=text], input[type=email], input[type=url], input[type=number], input[type=tel], input[type=search], input[type=date], input[type=time], input[type=password], input[type=datetime-local], input[type=color], select, textarea {
  width: 100%;
  min-height: 46px;
  padding: 10px 14px;
  border: 1px solid var(--field-line);
  border-radius: 12px;
  background: var(--field);
  color: var(--ink);
  font: inherit;
}
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 2px solid var(--ink); outline-offset: 1px; }
input[type=color] { padding: 4px; height: 46px; }
textarea { min-height: 96px; resize: vertical; }
input[type=checkbox], input[type=radio] { accent-color: var(--ink); width: 18px; height: 18px; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 480px) { .row { grid-template-columns: 1fr; } }
fieldset { border: 1px solid var(--line); border-radius: 14px; margin: 12px 0; padding: 8px 16px 16px; }
legend { font-weight: 600; padding: 0 6px; }

/* Buttons: pills; the main action in Ink, secondary outlined, party-coloured where it's the party's own call */
button, .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  border: 0;
  border-radius: 999px;
  padding: 10px 22px;
  font: inherit;
  font-weight: 600;
  background: var(--ink);
  color: var(--bg);
  cursor: pointer;
  text-decoration: none;
  margin-top: 14px;
}
button:hover, .btn:hover { filter: brightness(1.12); }
.btn.accent, button.accent { background: var(--accent); color: var(--on-accent); }
button.secondary, .btn.secondary { background: transparent; color: var(--ink); border: 1.5px solid var(--ink); }
button.link { background: none; color: var(--link); padding: 0; margin: 0; min-height: 0; font-weight: 400; text-decoration: underline; border-radius: 0; }
/* Phones: small links and link-style buttons get a finger-sized hit area without looking bigger */
@media (pointer: coarse) {
  .foot .foot-link { padding: 10px 4px; margin-top: 0; }
  button.link { min-height: 32px; padding: 4px 0; }
}
button.danger { background: #b42318; color: #fff; }
button:focus-visible, .btn:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }
.inline-form { display: inline; }
.actions { display: flex; gap: 14px; align-items: center; margin-top: 6px; flex-wrap: wrap; }
button:disabled { opacity: .35; cursor: default; }
.hero .btn { margin-top: 18px; }

.rsvp-choices { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 8px; }
.rsvp-choices label { margin: 0; }
@media (max-width: 480px) { .rsvp-choices { grid-template-columns: 1fr 1fr; } .rsvp-choices label:first-child { grid-column: 1 / -1; } }
.rsvp-choices input { position: absolute; opacity: 0; }
.rsvp-choices span {
  display: flex; align-items: center; justify-content: center; min-height: 56px; text-align: center; padding: 10px 6px;
  border: 1.5px solid var(--field-line); border-radius: 14px; font-weight: 600; cursor: pointer; background: var(--field);
}
.rsvp-choices input:checked + span { border-color: var(--ink); background: var(--ink); color: var(--bg); }
.rsvp-choices input:focus-visible + span { outline: 2px solid var(--ink); outline-offset: 2px; }

/* R1: date polls. Each date gets three compact choices that stay in one row on phones. */
.vote-choices, .rsvp-choices.vote-choices { grid-template-columns: repeat(3, 1fr); }
.vote-choices label:first-child { grid-column: auto; }
.vote-choices span { min-height: 44px; font-size: .85rem; padding: 6px 4px; }
.poll-list > li.best { background: color-mix(in srgb, var(--brand) 7%, transparent); margin: 0 -12px; padding: 14px 12px; border-radius: 12px; }
.poll-best { margin: 4px 0 0; font-weight: 600; }
.poll-names { margin: 4px 0 0; }
.poll-count { display: inline-flex; gap: 4px; }
.poll-date-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 8px; margin: 8px 0; }
.poll-date-grid input { margin: 0; }
.poll-link { margin-top: 16px; }

.list { list-style: none; padding: 0; margin: 0; }
.list > li { padding: 14px 0; border-top: 1px solid var(--line); }
.list > li:first-child { border-top: 0; }
.item-head { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; }
.pill { white-space: nowrap; display: inline-block; font-size: .75rem; font-weight: 600; line-height: 1.4; padding: 3px 10px; border-radius: 99px; background: color-mix(in srgb, var(--ink) 8%, transparent); color: var(--ink-2); }
.pill[class*="st-"] { display: inline-flex; align-items: center; gap: 6px; }
.pill[class*="st-"]::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.pill.st-yes { background: var(--ok-bg); color: var(--ok-ink); }
.pill.st-maybe { background: var(--warn-bg); color: var(--warn-ink); }
.pill.st-no { background: var(--err-bg); color: var(--err-ink); }
.pill.st-waitlist { background: color-mix(in srgb, var(--brand) 14%, transparent); color: var(--brand); }
.pill.good { background: var(--ok-bg); color: var(--ok-ink); }
.pill.accent { background: color-mix(in srgb, var(--accent) 22%, var(--card)); color: var(--ink); }

.progress { height: 10px; background: var(--line); border-radius: 99px; overflow: hidden; margin: 8px 0 4px; }
.progress { display: flex; }
.progress > div { height: 100%; background: var(--accent); border-radius: 99px; }
.progress > div.pending {
  border-radius: 0 99px 99px 0;
  background: repeating-linear-gradient(135deg, color-mix(in srgb, var(--accent) 55%, transparent) 0 6px, color-mix(in srgb, var(--accent) 25%, transparent) 6px 12px);
}

/* Group gifts: buyer volunteer form, pay sheet with TWINT and Swiss QR-bill, buyer's checklist */
details.volunteer > summary { list-style: none; display: inline-flex; }
details.volunteer > summary::-webkit-details-marker { display: none; }
details.volunteer[open] > summary { display: none; }
.commit { margin: 8px 0 0; padding-left: 20px; color: var(--ink-2); }
.pay, .buyer-panel { margin-top: 12px; padding: 16px; border-radius: 16px; background: var(--bg); border: 1px solid var(--line); }
.pay h4, .buyer-panel h4 { margin: 0 0 6px; font-family: var(--display); font-size: 1.15rem; }
.pay h5 { margin: 14px 0 0; font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.pay .held { color: var(--ink-2); }
.pay-way label { margin-top: 8px; }
.qrbill { display: grid; grid-template-columns: 168px minmax(0, 1fr); gap: 16px; align-items: start; margin-top: 10px; }
@media (max-width: 480px) { .qrbill { grid-template-columns: 1fr; } }
.qrbill .qr { background: #fff; padding: 8px; border-radius: 10px; border: 1px solid var(--line); max-width: 220px; }
.qrbill .qr svg { display: block; width: 100%; height: auto; }
.qrbill dl { margin: 0; display: grid; gap: 2px 0; }
.qrbill dt { font-weight: 600; margin-top: 6px; }
.qrbill dd { margin: 0; color: var(--ink-2); word-break: break-word; }
.buyer-panel .list > li { align-items: center; }

/* Counts: one ruled strip, like a form's boxes; the numbers big, the words small below.
   The rules are shadows, so a strip that wraps onto two rows is ruled right too. */
.stats { display: flex; flex-wrap: wrap; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--card); }
.stats > div { flex: 1 1 0; min-width: 6.5em; padding: 12px 14px; box-shadow: -1px 0 0 var(--line), 0 -1px 0 var(--line); }
.stats b { display: block; font: 700 1.75rem/1.1 var(--display); letter-spacing: -.03em; font-variant-numeric: tabular-nums; margin-bottom: 2px; }
.stats .small { color: var(--ink-2); }
.stats.five > div { min-width: 8em; }
/* Phones: two counts a row (three for the funnel), never a lone one left over */
@media (max-width: 520px) {
  .stats > div, .stats.five > div { flex: 1 1 50%; min-width: 0; }
  .stats.funnel > div, .stats.three > div { flex-basis: 33.3%; }
  .stats.five > div:last-child { flex-basis: 100%; }
}

.filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 4px 0 8px; }
.filters input[type=search] { flex: 1 1 220px; width: auto; }
.filters select { flex: 0 1 auto; width: auto; }
.list > li[hidden] + li { border-top: 1px solid var(--line); }
.add-guests { margin-top: 12px; }
.add-guests > details { border: 1px solid var(--line); border-radius: 14px; padding: 6px 14px; margin-bottom: 8px; }
.add-guests > details[open] { padding-bottom: 16px; }
details.menu { position: relative; }
details.menu > summary { list-style: none; }
details.menu > summary::-webkit-details-marker { display: none; }
.menu-list { position: absolute; z-index: 5; top: calc(100% + 6px); left: 0; min-width: 260px; display: grid; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 6px; box-shadow: 0 12px 30px rgb(0 0 0 / .25); }
.menu-list a { padding: 10px 12px; border-radius: 10px; text-decoration: none; color: var(--ink); }
.menu-list a:hover, .menu-list a:focus-visible { background: var(--bg); }
/* On a phone the menu opens in place under its button instead of floating off the right edge */
@media (max-width: 560px) { details.menu[open] { flex-basis: 100%; } .menu-list { position: static; margin-top: 6px; min-width: 0; box-shadow: none; } }
.banner.unsent { background: color-mix(in srgb, var(--brand) 18%, var(--card)); margin: 12px 0 0; padding: 4px 16px 14px; }
.pill.bad { background: var(--err-bg); color: var(--err-ink); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.brief-sub { margin: 14px 0 0; font-size: .95rem; color: var(--muted); }
table.data.import td, table.data.import th { white-space: normal; text-align: left; vertical-align: top; }
table.data.import tr.duplicate td, table.data.import tr.error td { color: var(--muted); }
.toolbar { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.toolbar .btn { margin: 0; min-height: 40px; padding: 8px 16px; font-size: .9rem; }
.summary { display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: center; color: var(--ink-2); margin: -4px 0 16px; }
.summary .pill { font-size: .8rem; }
.summary .pill:empty { display: none; }
.copy { display: flex; gap: 8px; align-items: center; }
.copy input { flex: 1; font-family: var(--mono); font-size: .85rem; }
.copy button { margin: 0; }

details > summary { cursor: pointer; font-weight: 600; padding: 4px 0; }
/* Folding parts open on a small chevron rather than the browser's triangle */
details:not(.menu):not(.volunteer) > summary { list-style: none; display: flex; align-items: center; gap: 10px; }
details:not(.menu):not(.volunteer) > summary::-webkit-details-marker { display: none; }
details:not(.menu):not(.volunteer) > summary::before {
  content: ""; flex: none; width: .42em; height: .42em; margin: 0 .15em; border: solid currentColor; border-width: 0 2px 2px 0;
  transform: rotate(-45deg); transition: transform .15s;
}
details[open]:not(.menu):not(.volunteer) > summary::before { transform: rotate(45deg) translate(-.1em, -.1em); }
@media (prefers-reduced-motion: reduce) { details > summary::before { transition: none; } }
.feed li { font-size: .95rem; display: grid; grid-template-columns: 5.4rem minmax(0, 1fr); gap: 2px 12px; padding: 10px 0; }
.feed-t { font: 500 .72rem/1.5 var(--mono); color: var(--muted); padding-top: .2em; }
.feed .unread { font-weight: 600; }
.feed-more { border-top: 1px solid var(--line); padding-top: 8px; }
.feed-more > .list > li:first-child { border-top: 1px solid var(--line); }
.wallet-pass { margin: 4px 0 8px; }
.push { margin-top: 12px; }
.push p:empty { display: none; }

/* Cover picture (E11) */
.hero .cover { display: block; width: 100%; max-width: none; aspect-ratio: 2 / 1; object-fit: cover; background: color-mix(in srgb, var(--accent) 15%, var(--card)); }
.cover-preview { display: block; max-width: 100%; max-height: 220px; border-radius: 12px; margin: 8px 0 12px; }
input[type=file] { display: block; width: 100%; margin: 4px 0 8px; font: inherit; }

/* Page themes (E11): colours still come from --accent, themes add background and type. */
body.theme-confetti {
  background-image:
    radial-gradient(color-mix(in srgb, var(--accent) 40%, transparent) 2.5px, transparent 3px),
    radial-gradient(color-mix(in srgb, #fab005 50%, transparent) 2px, transparent 2.5px),
    radial-gradient(color-mix(in srgb, #4dabf7 45%, transparent) 2px, transparent 2.5px);
  background-size: 41px 41px, 59px 59px, 73px 73px;
  background-position: 0 0, 20px 31px, 45px 12px;
  background-attachment: fixed;
}
.theme-confetti .card { box-shadow: 0 3px 0 color-mix(in srgb, var(--accent) 35%, transparent); }

.theme-elegant h1, .theme-elegant h2, .theme-elegant .lead {
  font-family: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif; font-weight: 400; letter-spacing: .01em;
}
.theme-elegant .hero { border: 1px solid color-mix(in srgb, var(--accent) 55%, var(--line)); outline: 1px solid color-mix(in srgb, var(--accent) 30%, transparent); outline-offset: -8px; }
.theme-elegant .hero .honoree { font-style: italic; box-shadow: none; }

body.theme-garden {
  --radius: 26px;
  background-image: linear-gradient(180deg, color-mix(in srgb, #40c057 14%, var(--bg)) 0, var(--bg) 480px);
  background-repeat: no-repeat;
}

body.theme-night {
  --bg: #0e0c18; --card: #1c1929; --ink: #f4f0ff; --ink-2: #c3bcd6; --muted: #a39cb8; --line: #2e2a42;
  --field: #171424; --field-line: #3d3856; --brand: #a9b6ff;
  --ok-bg: #173226; --ok-ink: #8fdcb4; --err-bg: #3a1a18; --err-ink: #ffa49b;
  color-scheme: dark;
  background-image:
    radial-gradient(rgb(255 255 255 / .55) 1px, transparent 1.5px),
    radial-gradient(rgb(255 255 255 / .3) 1px, transparent 1.5px);
  background-size: 97px 97px, 61px 61px;
  background-position: 0 0, 30px 40px;
  background-attachment: fixed;
}
.theme-night .hero h1 { text-shadow: 0 0 18px color-mix(in srgb, var(--accent) 60%, transparent); }
@media (prefers-color-scheme: dark) { body:not(.theme-night) { --link: var(--ink); } }
body.theme-night { --link: var(--ink); }

/* ---------- Landing page ---------- */
main.wide { display: block; }
.wrap.banners { padding-top: 16px; padding-bottom: 0; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.l-nav { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 18px; padding-bottom: 18px; flex-wrap: wrap; }
.l-nav a:not(.btn) { color: var(--ink); text-decoration: none; }
.l-nav .logo { font-size: 1.6rem; }
.l-nav nav { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.l-nav nav a.lang { padding: 6px 10px; border-radius: 99px; font-size: .875rem; font-weight: 600; color: var(--muted); }
.l-nav nav a.lang[aria-current] { background: var(--card); color: var(--ink); }
.l-nav .btn { margin: 0 0 0 8px; min-height: 42px; padding: 8px 18px; }
@media (max-width: 560px) { .l-nav .btn { display: none; } }

.l-hero { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 48px; align-items: center; padding-top: 24px; padding-bottom: 72px; }
@media (max-width: 860px) { .l-hero { grid-template-columns: 1fr; gap: 32px; padding-bottom: 48px; } }
.l-hero .eyebrow { font-weight: 600; color: var(--muted); margin-bottom: 18px; }
.l-hero h1 { font-size: clamp(2.8rem, 6.4vw, 5rem); line-height: .98; letter-spacing: -.045em; margin-bottom: .35em; }
.l-hero h1 .slot { display: inline-block; font-size: .5em; vertical-align: .3em; margin-left: .14em; transform: rotate(4deg); letter-spacing: 0; line-height: 1; }
.l-hero h1 .slot .ev-stamp .stamp-print { --stamp-ink: var(--brand); min-width: 5.2em; }
.l-hero h1 .slot .n { font-size: .34em; max-width: none; transition: opacity .25s; }
.l-hero h1 .slot .d { transition: opacity .25s; }
.l-hero .lead { font-size: 1.2rem; max-width: 34em; }
.l-hero .actions .btn { margin-top: 10px; min-height: 52px; padding: 12px 26px; }
.l-hero .unlock { margin-top: 20px; max-width: 24em; }
.l-hero .unlock summary { cursor: pointer; color: var(--muted); }
.l-hero .unlock form { margin-top: 12px; }
.l-hero .trust { margin-top: 18px; color: var(--muted); font-size: .9rem; }
.l-photo { position: relative; }
.l-photo img { display: block; width: 100%; aspect-ratio: 4 / 5; max-height: 640px; object-fit: cover; border-radius: 28px; }
.l-photo .float {
  position: absolute; left: -22px; bottom: 28px; max-width: 260px; padding: 16px 18px; border-radius: 18px;
  background: var(--card); color: var(--ink); box-shadow: 0 18px 40px rgb(0 0 0 / .22); text-align: left;
}
.l-photo .float b { display: block; font-family: var(--display); font-size: 1.15rem; line-height: 1.15; margin: 4px 0 8px; }
.l-photo .float .pill { background: var(--accent); color: var(--on-accent); }
@media (max-width: 860px) { .l-photo .float { left: 12px; bottom: 12px; } }

.l-section { padding-top: 72px; padding-bottom: 8px; }
.l-section > h2, .l-section .l-head h2 { font-size: clamp(2rem, 4vw, 3rem); font-weight: 800; letter-spacing: -.035em; max-width: 18em; }
.l-head p { max-width: 40em; color: var(--ink-2); font-size: 1.1rem; }
.l-features { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-top: 28px; }
@media (max-width: 760px) { .l-features { grid-template-columns: 1fr; } }
.l-feature { background: var(--card); border: 1px solid var(--line); border-radius: 24px; overflow: hidden; display: flex; flex-direction: column; }
.l-feature img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.l-feature .txt { padding: 22px 24px 26px; }
.l-feature h3 { font-size: 1.4rem; margin-bottom: .35em; }
.l-feature p { color: var(--ink-2); margin: 0; }
.l-feature.plain { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.l-feature.plain p { color: color-mix(in srgb, var(--bg) 80%, transparent); }
.l-bring { list-style: none; margin: 0; padding: 24px 24px 0; display: grid; gap: 10px; }
.l-bring li {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 12px; padding: 14px 16px; border-radius: 14px;
  background: color-mix(in srgb, var(--bg) 10%, transparent); border: 1px solid color-mix(in srgb, var(--bg) 18%, transparent);
}
.l-bring b { font-weight: 600; }
.l-bring span { color: color-mix(in srgb, var(--bg) 70%, transparent); font-size: .875rem; text-align: right; }
.l-bring em { grid-column: 1 / -1; font-style: normal; font-size: .875rem; font-weight: 600; color: color-mix(in srgb, var(--bg) 88%, transparent); }
.l-feature.plain .txt { margin-top: auto; }

.l-steps { list-style: none; margin: 28px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; counter-reset: step; }
@media (max-width: 760px) { .l-steps { grid-template-columns: 1fr; } }
.l-steps li { counter-increment: step; padding: 24px; border-radius: 20px; border: 1.5px solid var(--ink); }
.l-steps li::before {
  content: counter(step); display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%;
  background: var(--ink); color: var(--bg); font-family: var(--display); font-weight: 700; margin-bottom: 14px;
}
.l-steps h3 { font-size: 1.2rem; }
.l-steps p { margin: 0; color: var(--ink-2); }

.l-band { margin-top: 72px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); border-radius: 28px; overflow: hidden; background: #1c2c6b; color: #fffdf8; }
@media (max-width: 760px) { .l-band { grid-template-columns: 1fr; } }
.l-band img { display: block; width: 100%; height: 100%; min-height: 260px; object-fit: cover; }
.l-band .txt { padding: clamp(28px, 5vw, 48px); display: flex; flex-direction: column; justify-content: center; }
.l-band h2 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); font-weight: 800; letter-spacing: -.03em; }
.l-band p { font-size: 1.05rem; }
.l-band .btn { align-self: flex-start; background: #fffdf8; color: #1a1530; }
.l-band .btn.secondary { background: transparent; color: #fffdf8; border-color: #fffdf8; }

.l-create { padding-top: 72px; }
.l-create .grid { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 40px; align-items: start; }
@media (max-width: 860px) { .l-create .grid { grid-template-columns: 1fr; gap: 16px; } }
.l-create h2 { font-size: clamp(2rem, 4vw, 3rem); font-weight: 800; letter-spacing: -.035em; }
.l-create .card { padding: clamp(20px, 3vw, 32px); }
.l-credit { margin-top: 48px; text-align: center; font-size: .8rem; color: var(--muted); }
.l-credit a { color: inherit; }

/* AnInvite.To for Business: invitation funnel and per-team-member table (B3) */
.stats .share { display: block; font-size: .75rem; line-height: 1.3; color: var(--muted); }
/* A single count (e.g. people coming) is a box of its own, not a full-width bar */
.stats:has(> div:only-child) { display: inline-flex; }
.stats:has(> div:only-child) > div { min-width: 9em; }
.stats.funnel > div { min-width: 5.5em; }
.table-wrap { overflow-x: auto; margin-top: 12px; }
table.data { width: 100%; border-collapse: collapse; font-size: .9rem; }
table.data th, table.data td { padding: 8px 6px; border-bottom: 1px solid var(--line); text-align: right; white-space: nowrap; }
table.data th:first-child, table.data td:first-child { text-align: left; white-space: normal; min-width: 9em; }
table.data td:last-child { white-space: normal; min-width: 8em; }
table.data thead th { font-weight: 600; color: var(--muted); font-size: .8rem; }
table.data td form { margin: 0; }
/* Phones: a "stack" table shows each row as a small card, each cell labelled from data-label */
@media (max-width: 560px) {
  table.data.stack thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  table.data.stack, table.data.stack tbody, table.data.stack tr, table.data.stack th, table.data.stack td { display: block; }
  table.data.stack tr { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px 10px; padding: 12px 0; border-bottom: 1px solid var(--line); }
  table.data.stack th, table.data.stack td { border: 0; padding: 0; text-align: left; white-space: normal; min-width: 0; }
  table.data.stack .full, table.data.stack th[scope="row"] { grid-column: 1 / -1; }
  table.data.stack td:empty { display: none; }
  table.data.stack td[data-label]::before { content: attr(data-label); display: block; font-size: .75rem; color: var(--muted); }
}
.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 brief (B4): one guest per printed page */
.brief dl { display: grid; grid-template-columns: minmax(8em, 30%) 1fr; gap: 6px 12px; margin: 12px 0 0; }
.brief dt { color: var(--muted); font-size: .85rem; }
.brief dd { margin: 0; white-space: pre-line; }
.brief-answers { border-top: 1px solid var(--line); padding-top: 12px; }
@media (max-width: 520px) { .brief dl { grid-template-columns: 1fr; } .brief dd { margin-bottom: 8px; } }
@media print {
  header.site, footer.foot, .no-print, .banner { display: none !important; }
  body { background: #fff; }
  .card.brief { break-after: page; box-shadow: none; border: 0; padding: 0; margin: 0; }
  .card.brief:last-child { break-after: auto; }
}

/* Ticket (B6): the details, and a perforated stub with the QR code to show at the door */
.ticket {
  --notch: 11px;
  position: relative; margin-top: 16px; display: grid; grid-template-columns: minmax(0, 1fr) auto;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); text-align: left;
  box-shadow: 0 10px 24px -18px rgb(26 21 48 / .5);
}
.ticket-main { padding: 18px 20px; display: grid; gap: 6px; align-content: start; min-width: 0; }
.ticket-k { margin: 0; font: 600 .75rem/1 var(--text); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.ticket-ev { font: 700 1.25rem/1.2 var(--display); letter-spacing: -.02em; }
.ticket-facts { display: flex; flex-wrap: wrap; gap: 6px 22px; margin: 6px 0 4px; }
.ticket-facts dt { font-size: .8rem; color: var(--muted); }
.ticket-facts dd { margin: 0; font: 700 1rem/1.3 var(--mono); }
.ticket-in { margin: 4px 0 0; font-weight: 600; color: var(--ok-ink); }
.ticket-stub { padding: 14px 18px; border-left: 2px dashed var(--field-line); display: grid; justify-items: center; align-content: center; gap: 4px; }
/* the two notches where the stub tears off */
.ticket::before, .ticket::after {
  content: ""; position: absolute; width: calc(var(--notch) * 2); height: calc(var(--notch) * 2); border-radius: 50%;
  background: var(--bg); border: 1px solid var(--line); right: var(--stub, 0px);
}
.ticket::before { top: calc(var(--notch) * -1 - 1px); clip-path: inset(50% 0 0 0); }
.ticket::after { bottom: calc(var(--notch) * -1 - 1px); clip-path: inset(0 0 50% 0); }
.ticket { --stub: calc(min(200px, 46vw) + 36px - 12px); }
.ticket-qr svg { width: min(200px, 46vw); height: auto; display: block; background: #fff; padding: 6px; border-radius: 8px; }
.ticket-done { display: grid; place-items: center; width: 120px; height: 120px; border-radius: 50%; background: var(--ok-bg); color: var(--ok-ink); font-size: 3rem; font-weight: 700; }
.ticket { --stub-done: 0; }
.ticket:has(.ticket-done) { --stub: calc(120px + 36px - 12px); }
.ticket-code { font-family: var(--mono); font-size: 1.15rem; font-weight: 700; letter-spacing: .12em; margin: 4px 0 0; }
/* Phones: the stub goes below, torn along a dashed line with notches at the sides */
@media (max-width: 520px) {
  .ticket { grid-template-columns: 1fr; --stub: auto; }
  .ticket-stub { border-left: 0; border-top: 2px dashed var(--field-line); }
  .ticket-qr svg { width: min(220px, 64vw); }
  .ticket::before, .ticket::after { right: auto; top: auto; bottom: var(--stub-at, 0); clip-path: none; }
  .ticket::before { left: calc(var(--notch) * -1 - 1px); clip-path: inset(0 0 0 50%); }
  .ticket::after { right: calc(var(--notch) * -1 - 1px); left: auto; clip-path: inset(0 50% 0 0); }
  .ticket { --stub-at: calc(min(220px, 64vw) + 12px + 28px + 28px - 11px); }
  .ticket:has(.ticket-done) { --stub-at: calc(120px + 28px + 28px + 4px - 11px); }
}

/* The postmark on a confirmed answer; it lands when the answer was just sent */
.answered { display: flex; align-items: center; gap: 14px; }
.answered .lead { margin: 0; }
.postmark { width: 76px; height: 76px; flex: none; color: var(--stamp-ink, #1c2c6b); transform: rotate(-10deg); opacity: .9; }
.postmark .pm-ring { font: 700 7.4px var(--mono); letter-spacing: 1.6px; }
.postmark .pm-date { font: 700 10px var(--mono); }
.postmark .pm-year { font: 700 7px var(--mono); }
.postmark.land { animation: stamp-land .7s cubic-bezier(.2, 1.4, .4, 1) both; }
@keyframes stamp-land { from { transform: scale(1.9) rotate(-35deg); opacity: 0; } to { transform: rotate(-10deg); opacity: .9; } }
@media (prefers-reduced-motion: reduce) { .postmark.land { animation: none; } }
@media (prefers-color-scheme: dark) { .postmark { color: var(--link); } }
.checkin-result { border-radius: 14px; padding: 16px; margin: 12px 0; font-size: 1.25rem; font-weight: 700; text-align: center; }
.checkin-result.ok { background: var(--ok-bg); color: var(--ok-ink); }
.checkin-result.err { background: var(--err-bg); color: var(--err-ink); }
.checkin-result.warn { background: var(--bg); color: var(--ink); border: 2px solid var(--line); }
.checkin video { width: 100%; max-height: 60vh; border-radius: 14px; background: #000; }
.door li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: center; }
.door .who .pill { margin-left: 4px; vertical-align: 1px; }
.door .act { text-align: right; }
.door .act form { margin: 0; }
.door .act button:not(.link) { margin: 0; min-height: 44px; padding: 8px 18px; }
.door .act .pill { display: block; margin-bottom: 4px; }

/* Seating plan (B7): "without a seat" beside a grid of tables; drag and drop with app.js */
.seating { display: grid; grid-template-columns: minmax(240px, 1fr) minmax(0, 2.4fr); gap: 16px; align-items: start; }
.seating .unseated { position: sticky; top: 12px; max-height: calc(100vh - 24px); overflow: auto; margin: 0; }
.tables { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; align-items: start; }
.tables > .card { margin: 0; }
@media (max-width: 760px) { .seating { grid-template-columns: 1fr; } .seating .unseated { position: static; max-height: none; } }
.table-card h3 { margin: 0; }
.table-card.over { border-color: var(--err-ink); }
.meter { height: 6px; background: var(--line); border-radius: 99px; overflow: hidden; margin: 8px 0 10px; }
.meter > div { height: 100%; background: var(--brand); }
.warn { color: var(--err-ink); }
.seat-list > li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 10px; align-items: center; padding: 10px 0; }
.seat-move select { max-width: 9.5em; }
.auto-mix { margin-top: 16px; border-top: 1px solid var(--line); padding-top: 10px; }
.seat-list li[draggable=true] { cursor: grab; }
.seat-list > li > .seat-with { grid-column: 1 / -1; }
.seat-with form { display: flex; gap: 8px; align-items: center; }
.seat-with select { flex: 1; min-width: 0; min-height: 38px; padding: 6px 10px; font-size: .875rem; margin: 6px 0 0; }
.seat-list li.dragging { opacity: .4; }
.seat-move { display: flex; gap: 6px; align-items: center; }
.seat-move select { min-height: 38px; padding: 6px 10px; font-size: .875rem; }
.seat-move button { margin: 0; min-height: 38px; padding: 6px 14px; font-size: .875rem; }
.drop-ok { outline: 2px dashed var(--brand); outline-offset: -2px; }
.drop-full { outline: 2px dashed var(--err-ink); outline-offset: -2px; }

/* Programme on the invitation and the venue sheet */
.programme { margin-top: 18px; border-top: 1px solid var(--line); padding-top: 14px; }
.programme h2, .programme h3 { margin-bottom: 8px; font-size: 1.1rem; }
.programme ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.programme li { display: grid; grid-template-columns: 3.4em 1fr; gap: 12px; }
.programme time { font-variant-numeric: tabular-nums; font-weight: 600; color: var(--ink); }

/* Follow-up (B9) */
.quota-form { display: flex; flex-wrap: wrap; align-items: end; gap: 0 8px; margin-top: 6px; }
.quota-form label { width: 100%; margin: 6px 0 4px; font-size: .8rem; font-weight: 500; color: var(--muted); }
.quota-form input { width: 8em; min-height: 38px; padding: 6px 10px; }
.quota-form button { margin: 0; min-height: 38px; padding: 6px 14px; font-size: .875rem; }
.banner-card { display: flex; flex-wrap: wrap; gap: 8px 20px; align-items: center; justify-content: space-between; background: color-mix(in srgb, var(--brand) 16%, var(--card)); }
.banner-card .lead { margin: 0; font-weight: 600; color: var(--ink); }
.banner-card .btn { margin: 0; }
.fu-group { margin: 28px 0 12px; }
.fu h3 { margin: 0; }
.fu.done { opacity: .78; }
.fu-facts { display: grid; grid-template-columns: minmax(8em, 28%) 1fr; gap: 4px 12px; margin: 12px 0 4px; font-size: .9rem; }
.fu-facts dt { color: var(--muted); }
.fu-facts dd { margin: 0; white-space: pre-line; }
.fu textarea { min-height: 220px; }
.fu-deals { border-top: 1px solid var(--line); margin-top: 12px; padding-top: 8px; }
.fu-deals .list > li { padding: 6px 0; }
@media (max-width: 520px) { .fu-facts { grid-template-columns: 1fr; } }

/* Place cards and name badges: real sizes in mm, shown on screen as paper sheets */
.sheets { display: grid; gap: 16px; justify-content: center; overflow-x: auto; }
.sheet { width: 210mm; height: 297mm; background: #fff; color: #1a1530; box-shadow: 0 6px 24px rgb(0 0 0 / .25); overflow: hidden; }
.sheets-place .sheet { display: grid; grid-template-rows: repeat(3, 99mm); }
.tent { position: relative; display: grid; grid-template-rows: 1fr 1fr; border-bottom: 1px dashed #b8b6ad; }
.tent .face { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 0 12mm; border-bottom: 1px dotted #d8d6cc; }
.tent .face:first-child { transform: rotate(180deg); }
.tent .face:last-of-type { border-bottom: 0; }
.card-name { font-family: var(--display); font-weight: 800; font-size: 26pt; line-height: 1.05; letter-spacing: -.02em; }
.card-company { font-size: 12pt; color: #575b6e; margin-top: 2mm; }
.card-table { position: absolute; right: 6mm; bottom: 4mm; font-size: 8pt; color: #8a8d9e; }
.sheets-badge .sheet { display: grid; grid-template-columns: repeat(2, 90mm); grid-template-rows: repeat(4, 55mm); gap: 6mm 10mm; padding: 24mm 10mm; justify-content: center; }
.badge { border: 1px dashed #b8b6ad; border-radius: 3mm; display: grid; grid-template-rows: 1fr auto; padding: 5mm 6mm 4mm; border-top: 3mm solid var(--accent); }
.badge .face { display: flex; flex-direction: column; justify-content: center; }
.badge .card-name { font-size: 20pt; }
.badge-foot { display: flex; justify-content: space-between; gap: 4mm; font-size: 7pt; color: #8a8d9e; }
@media print {
  @page { size: A4; margin: 0; }
  .sheets { display: block; }
  .sheet { box-shadow: none; break-after: page; }
  .sheet:last-child { break-after: auto; }
  main.wrap:has(.sheets) { max-width: none; padding: 0; }
}

/* Venue sheet (B7) */
.venue dl { display: grid; grid-template-columns: minmax(8em, 25%) 1fr; gap: 6px 12px; margin: 12px 0 8px; }
.venue dt { color: var(--muted); font-size: .85rem; }
.venue dd { margin: 0; }
.venue h3 { margin-top: 20px; }
.tally { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.tally li { background: var(--bg); border-radius: 12px; padding: 8px 14px; }
.tally b { font-family: var(--display); font-size: 1.2rem; margin-right: 4px; }
.venue table.data td, .venue table.data th { white-space: normal; text-align: left; }
@media print {
  .wrap.dash { max-width: none; }
  .seating { display: block; }
  .tables { grid-template-columns: repeat(2, 1fr); }
  .table-card { break-inside: avoid; border: 1px solid #ccc; }
  .seat-move, .table-card details { display: none !important; }
  .card.venue { border: 0; padding: 0; }
}

/* A form field only bots fill in (demo requests) */
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* Invitation: the jump to the answer form, and the guest's next stops after answering */
.hero .hero-answer { margin-top: 18px; }
.next-links { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 12px 0 0; font-weight: 600; }

/* Dashboard header: sharing, and the private link tucked away */
.share-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.share-row > * { margin: 0; }
details.private-link { margin-top: 10px; }
details.private-link > summary { font-size: .9rem; color: var(--muted); }
details.private-link label { font-size: .8rem; color: var(--muted); font-weight: 400; }

/* Check-in: the count stays in view while scrolling; the guests nobody expects come last */
.checkin [data-count] { position: sticky; top: 0; z-index: 2; background: var(--card); padding: 8px 0; margin: 0; }
.door-sep { color: var(--muted); font-weight: 600; font-size: .9rem; }
details.walkin { margin: 4px 0 8px; }

/* "Get ready" checklist on a new business event */
.get-ready .steps { list-style: none; padding: 0; margin: 0; counter-reset: step; }
.get-ready .steps li { display: flex; gap: 12px; align-items: baseline; padding: 8px 0; border-top: 1px solid var(--line); }
.get-ready .steps li:first-child { border-top: 0; }
.get-ready .tick { flex: none; width: 24px; height: 24px; border-radius: 50%; border: 1.5px solid var(--line); display: inline-flex; align-items: center; justify-content: center; font-size: .8rem; font-weight: 700; }
.get-ready li.done .tick { background: var(--ok-bg); color: var(--ok-ink); border-color: transparent; }
.get-ready li.done a { color: var(--muted); }

.invite-note { display: inline-block; margin-top: 4px; font-style: italic; color: var(--ink-2); white-space: pre-line; }

/* Dashboards: working pages in the same paper and ink, a little tighter than the invitation */
.wrap.dash h1 { font-size: clamp(1.9rem, 4.4vw, 2.5rem); }
.wrap.dash h2 { font-size: 1.25rem; }
.summary > span:not(.pill) { font-family: var(--mono); font-size: .85rem; }
/* The settings at the bottom of the side column: one card, ruled into rows */
.folds { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 16px; overflow: hidden; }
.folds:empty { display: none; }
.folds > .card { border: 0; border-radius: 0; margin: 0; padding: 14px 22px; border-top: 1px solid var(--line); }
.folds > .card:first-child { border-top: 0; }
.folds > .card > details > summary { min-height: 32px; }
.list > li > .item-head > b { font-weight: 600; }

/* Admin: the demo events' links, and the tour's slides (side by side, one per screen) */
.demo-links { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 4px 24px; margin: 12px 0 16px; }
.demo-links h3 { margin: 8px 0 4px; font-size: 1rem; }
.demo-links ul { margin: 0; padding-left: 1.1em; }
.tour { display: grid; grid-auto-flow: column; grid-auto-columns: 100%; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; overscroll-behavior-x: contain; }
.tour-slide { scroll-snap-align: start; display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 24px; align-items: center; margin: 0; }
.tour-shot { display: grid; place-items: center; background: var(--bg); border-radius: 12px; padding: 12px; min-height: 0; }
.tour-shot img { display: block; max-width: 100%; max-height: 70vh; height: auto; border-radius: 8px; box-shadow: 0 1px 3px rgb(20 10 40 / .18), 0 8px 24px rgb(20 10 40 / .12); }
.tour-shot.phone img { max-height: 72vh; border-radius: 18px; }
.tour-text h2 { margin-top: 0; }
.tour-nav { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
@media (max-width: 760px) { .tour-slide { grid-template-columns: 1fr; } .tour-shot img { max-height: 60vh; } }

/* The create form starts with what the party is for */
.occasions { border: 0; padding: 0; margin: 0 0 18px; min-width: 0; }
.occasions legend { font: 700 1.05rem/1.3 var(--display); margin-bottom: 10px; padding: 0; }
.occasion-row { display: flex; flex-wrap: wrap; gap: 8px; }
.occasion { display: inline-flex; align-items: center; gap: 8px; padding: 9px 14px; border: 1px solid var(--line); border-radius: 99px; background: var(--card); color: var(--ink); text-decoration: none; font-weight: 600; font-size: .95rem; }
.occasion:hover { border-color: var(--ink); }
.occasion[aria-current] { background: var(--ink); border-color: var(--ink); color: var(--card); }
.occasion .em { font-size: 1.15em; line-height: 1; }
.occasion-hint { margin: 10px 0 0; }

/* R2: posts for the guests' group chat. The preview looks like the message it becomes. */
.post-now { border: 2px solid var(--accent); }
.post-preview { margin: 12px 0; padding: 12px 14px; border-left: 4px solid #25d366; border-radius: 10px; background: color-mix(in srgb, #25d366 8%, transparent); display: grid; gap: 6px; white-space: pre-line; }
.group-posts .item-head { align-items: center; gap: 12px; }
.group-posts .btn { flex: none; }
.small-btn { padding: 6px 14px; min-height: 36px; font-size: .9rem; }
.post-card.cancelled h1 { color: var(--danger, #b42318); }

/* R3/R4/R11/R12: /me, party series, public events and the search */
.own-card { border-style: dashed; text-align: center; }
.own-card .button, .own-card button { margin-top: 4px; }
.book-list li { display: flex; gap: 10px; align-items: baseline; }
.book-list input[type="checkbox"] { flex: none; width: auto; margin: 0; }
.series-pick { display: flex; gap: 8px; align-items: center; margin-top: 6px; }
.series-pick select { width: auto; flex: 1 1 auto; min-width: 0; }
.discover-form .row { display: flex; flex-wrap: wrap; gap: 10px; }
.discover-form .row > div { flex: 1 1 140px; min-width: 0; }
.discover-form details { margin-top: 8px; }
.found-list .found { display: block; }
.found a b { font-size: 1.05rem; }
.found .small { margin-top: 2px; }
.tag-links { display: flex; flex-wrap: wrap; gap: 6px 8px; }
.tag-links a { padding: 4px 10px; border: 1px solid var(--line); border-radius: 999px; text-decoration: none; font-size: .9rem; }
.profile h1, .series-head h1 { margin-bottom: 4px; }
.profile .lead, .series-head .lead { white-space: pre-line; }
.report { margin: 18px 0 8px; color: var(--muted); }
.report summary { cursor: pointer; }
.report form { margin-top: 10px; }
.field-hint { margin: 4px 0 0; }
.talk-actions { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; margin-top: 8px; }
.talk-actions input[type="time"] { width: auto; margin: 0 8px 0 0; }
