/* PEAK Party – the party pages' components (ny_fest.php, fest*.php, invitation.php). Loaded after app.css
   and the edition's tokens (editions/fest.css); a party type's own theme (assets/css/fest/types/<type>.css) comes on
   top and only changes tokens and art, never the layout. Mobile first; motion only without prefers-reduced-motion. */

:root { --fest-accent: var(--accent); --fest-accent-2: var(--fest-gold); --fest-radius: 20px; }

/* ---------- Sections on the party pages ---------- */

.fest-section { margin: 22px 0; }
.fest-section > h2 { font-size: 1.05rem; margin: 0 0 10px; display: inline-flex; gap: 8px; align-items: center; }

/* Chips */
.fest-type-chip, .fest-phase-chip, .fest-lock-chip, .fest-live-dot, .fest-next-chip, .fest-role-chip, .fest-rsvp-chip {
  display: inline-flex; align-items: center; gap: 4px; padding: 3px 9px; border-radius: 999px;
  font-size: 0.75rem; font-weight: 700; line-height: 1.3; white-space: nowrap;
  background: var(--surface-2); border: 1px solid var(--border); color: var(--text);
}
.fest-type-chip { background: color-mix(in srgb, var(--fest-accent) 16%, var(--surface-2)); }
.fest-lock-chip { color: var(--amber); }
.fest-live-dot { color: #fff; background: #e5484d; border-color: transparent; }
.fest-live-dot::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
@media (prefers-reduced-motion: no-preference) { .fest-live-dot::before { animation: fest-blink 1.4s ease-in-out infinite; } }
@keyframes fest-blink { 50% { opacity: 0.25; } }
.fest-next-chip { color: var(--fest-accent); }
.fest-phase-chip.is-live { color: #fff; background: #e5484d; border-color: transparent; }
.fest-phase-chip.is-cancelled { color: var(--danger); }
.fest-role-chip.is-host { color: var(--fest-gold); }
.fest-role-chip.is-officer { color: var(--fest-cyan); }
.fest-rsvp-chip { font-size: 0.85rem; }
.fest-rsvp-chip.is-yes { color: var(--ok); }
.fest-rsvp-chip.is-maybe { color: var(--amber); }
.fest-rsvp-chip.is-no { color: var(--muted); }

/* ---------- New party: the type grid ---------- */

.fest-type-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
.fest-type-card { display: grid; gap: 6px; align-content: start; color: inherit; text-decoration: none; min-height: 168px; position: relative; overflow: hidden; }
.fest-type-card b { font-family: "Bricolage Grotesque", sans-serif; font-size: 1.1rem; }
.fest-type-emoji { font-size: 2.4rem; line-height: 1.1; }
.fest-type-tag { margin-top: auto; font-size: 0.75rem; font-weight: 700; color: var(--fest-accent); }
.fest-type-card.is-locked .fest-type-tag { color: var(--amber); }
.fest-type-card:hover, .fest-type-card:focus-visible { border-color: color-mix(in srgb, var(--fest-accent) 60%, var(--border)); }
@media (prefers-reduced-motion: no-preference) {
  .fest-type-card { transition: transform 0.15s ease; }
  .fest-type-card:hover .fest-type-emoji { animation: fest-wiggle 0.5s ease-in-out; }
}
@keyframes fest-wiggle { 25% { transform: rotate(-8deg) scale(1.08); } 75% { transform: rotate(6deg) scale(1.08); } }

/* ---------- Forms ---------- */

.fest-form { display: grid; gap: 14px; }
.fest-form h2 { margin: 0; font-size: 1.1rem; }
.fest-form label:not(.check):not(.pick-chip) { display: grid; gap: 6px; font-weight: 600; font-size: 0.9rem; min-width: 0; }
.fest-form-row { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); }
.fest-form-row .grow { grid-column: span 2; }
/* A date field can't shrink below its digits (about 170 px in Chrome): with 130 px columns it ran into the time
   field next to it on a phone. Such rows take a column only when the date fits, else they stack. */
.fest-form-row:has(input[type="date"]) { grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr)); }
.fest-emoji-field input { text-align: center; font-size: 1.2rem; }
.fest-form-type { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin: 0; }
.fest-inline-form { display: grid; gap: 6px; margin-top: 14px; }
.fest-inline-form > label { font-weight: 600; font-size: 0.9rem; }
.fest-inline-row { display: flex; gap: 8px; }
.fest-inline-row input { flex: 1; min-width: 0; }

/* ---------- The party's hero and dashboard ---------- */

.fest-hero { position: relative; margin: 8px 0 18px; padding: 22px 20px; border-radius: var(--fest-radius); overflow: hidden;
  background: linear-gradient(135deg, color-mix(in srgb, var(--fest-accent) 26%, var(--surface)), color-mix(in srgb, var(--fest-accent-2) 14%, var(--surface)));
  border: 1px solid color-mix(in srgb, var(--fest-accent) 30%, var(--border)); }
.fest-hero h1 { margin: 8px 0 6px; font-size: clamp(1.7rem, 6vw, 2.6rem); line-height: 1.05; overflow-wrap: anywhere; }
.fest-hero p { margin: 4px 0; display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.fest-hero .icon { width: 18px; height: 18px; flex: none; }
.fest-hero-top { gap: 8px; }
.fest-hero-when { font-weight: 700; }

.fest-banner { text-align: center; }
.fest-banner h2 { margin: 0 0 6px; }
.fest-banner.is-live { border-color: color-mix(in srgb, #e5484d 50%, var(--border)); }
.fest-banner.is-cancelled { border-color: color-mix(in srgb, var(--danger) 50%, var(--border)); }
.fest-nownext { display: grid; gap: 10px; margin-top: 12px; text-align: left; }
@media (min-width: 560px) { .fest-nownext { grid-template-columns: 1fr 1fr; } }
.fest-nownext p { margin: 0; padding: 12px 14px; border-radius: 14px; background: var(--surface-2); display: grid; gap: 2px; }
.fest-nownext small { color: var(--muted); font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; font-size: 0.72rem; }

.fest-checklist ul { list-style: none; padding: 0; margin: 12px 0 16px; display: grid; gap: 6px; }
.fest-checklist li a { display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 12px; background: var(--surface-2); color: inherit; text-decoration: none; font-weight: 600; }
.fest-checklist li.is-done a { color: var(--muted); }
.fest-checklist li a:hover { background: var(--surface-3); }

/* Countdown */
.fest-countdown { text-align: center; padding: 22px 16px; }
.fest-cd-label { margin: 0 0 10px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: 0.08em; font-size: 0.78rem; }
.fest-cd-units { display: flex; justify-content: center; gap: clamp(8px, 3vw, 18px); margin: 0; }
.fest-cd-unit { display: grid; min-width: 62px; padding: 10px 6px; border-radius: 16px; background: var(--surface-2); border: 1px solid var(--border); }
.fest-cd-unit b { font-family: "Bricolage Grotesque", sans-serif; font-size: clamp(1.8rem, 9vw, 2.8rem); font-weight: 800; line-height: 1; font-variant-numeric: tabular-nums; color: var(--fest-accent); }
.fest-cd-unit small { color: var(--muted); font-weight: 600; font-size: 0.75rem; margin-top: 4px; }
.fest-cd-when { margin: 12px 0 0; font-weight: 600; }
.fest-countdown.is-done .fest-cd-units { display: none; }
.fest-countdown.is-done .fest-cd-label { font-size: 1.4rem; color: var(--text); text-transform: none; letter-spacing: 0; }

/* My answer */
.fest-me { display: grid; gap: 12px; }
.fest-rsvp-q { margin: 0 0 8px; font-weight: 800; font-family: "Bricolage Grotesque", sans-serif; font-size: 1.15rem; }
.fest-rsvp-btns { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.fest-rsvp-btn { flex-direction: column; gap: 2px; padding: 12px 6px; min-height: 64px; background: var(--surface-2); border-color: var(--border); color: var(--text); }
.fest-rsvp-btn span { font-size: 1.4rem; }
.fest-rsvp-btn[aria-pressed="true"] { background: color-mix(in srgb, var(--fest-accent) 26%, var(--surface-2)); border-color: var(--fest-accent); box-shadow: 0 0 0 1px var(--fest-accent); }
@media (prefers-reduced-motion: no-preference) { .fest-rsvp-btn[aria-pressed="true"] span { animation: fest-wiggle 0.6s ease-in-out 1; } }
.fest-plus { display: grid; gap: 8px; }
.fest-plus-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.fest-plus-row input { flex: 1; min-width: 160px; }
.fest-plus-row span { flex: 1; font-weight: 600; }

.fest-grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); margin: 14px 0; }
.fest-stat { display: grid; gap: 2px; color: inherit; text-decoration: none; }
.fest-stat b { font-family: "Bricolage Grotesque", sans-serif; font-size: 2rem; line-height: 1; color: var(--fest-accent); }
.fest-stat span { font-weight: 700; }
.fest-stat.is-missing b { color: var(--amber); }
.fest-text p { margin: 0; overflow-wrap: anywhere; }
.fest-text h2, .fest-tools h2 { font-size: 1.05rem; margin: 0 0 8px; }
.fest-me-diet summary { cursor: pointer; font-weight: 700; }
.fest-me-diet .fest-form { margin-top: 12px; }
.fest-tool-btns { display: flex; gap: 8px; flex-wrap: wrap; }
.fest-tool-btns form { display: contents; }
.fest-leave { text-align: center; margin: 22px 0 8px; }
main > .card, main > form.card, main > section.card { margin-bottom: 14px; }

/* ---------- Guests ---------- */

.fest-invite h2 { margin: 0 0 6px; font-size: 1.1rem; }
.fest-link { display: flex; gap: 8px; margin: 10px 0; }
.fest-link input { flex: 1; min-width: 0; font-size: 0.85rem; }
.fest-guests { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.fest-guest { padding: 12px 14px; }
.fest-guest-main { display: flex; gap: 12px; align-items: center; }
.fest-guest-name { display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: center; min-width: 0; }
.fest-guest-name b { overflow-wrap: anywhere; }
.fest-guest-diet { margin: 8px 0 0; color: var(--muted); }
.fest-guest-tools { margin-top: 8px; }
.fest-guest-tools summary { cursor: pointer; color: var(--muted); font-size: 0.85rem; font-weight: 600; }
.fest-guest-actions { display: grid; gap: 8px; margin-top: 10px; }
.fest-guest-actions form { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.fest-rsvp-set select { width: auto; flex: 1; }

/* ---------- Programme ---------- */

.fest-timeline { list-style: none; margin: 0; padding: 0 0 0 4px; display: grid; gap: 0; }
.fest-tl-item { display: grid; grid-template-columns: 78px 1fr; gap: 12px; position: relative; padding: 0 0 16px; }
.fest-tl-item::before { content: ""; position: absolute; left: 84px; top: 6px; bottom: -6px; width: 2px; background: var(--border); }
.fest-tl-item:last-child::before { display: none; }
.fest-tl-item time { font-weight: 800; font-variant-numeric: tabular-nums; text-align: right; padding-top: 1px; }
.fest-tl-body { position: relative; padding-left: 16px; display: grid; gap: 4px; justify-items: start; }
.fest-tl-body::before { content: ""; position: absolute; left: -4px; top: 5px; width: 12px; height: 12px; border-radius: 50%; background: var(--surface-3); border: 2px solid var(--bg); }
.fest-tl-body p { margin: 0; }
.fest-tl-item.is-now .fest-tl-body::before { background: #e5484d; box-shadow: 0 0 0 4px color-mix(in srgb, #e5484d 30%, transparent); }
.fest-tl-item.is-next .fest-tl-body::before { background: var(--fest-accent); }
.fest-tl-item.is-done { opacity: 0.6; }
.fest-tl-tools { display: flex; gap: 12px; align-items: center; font-size: 0.85rem; }
.fest-tl-tools form { display: inline; }
.fest-empty-emoji { font-size: 2.6rem; margin: 0; }

/* ---------- Bring list ---------- */

.fest-mode fieldset { border: 0; padding: 0; margin: 0 0 10px; }
.fest-mode legend { font-weight: 700; margin-bottom: 8px; }
.fest-mode-opts { display: flex; flex-wrap: wrap; gap: 8px; }
.fest-bring-sum { font-weight: 700; color: var(--ok); }
.fest-bring-sum.is-missing { color: var(--amber); }
.fest-items { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.fest-item { display: grid; grid-template-columns: 1fr auto; gap: 8px 12px; align-items: center; padding: 12px 14px; }
.fest-item-main { display: grid; gap: 2px; min-width: 0; }
.fest-item-main b { overflow-wrap: anywhere; }
.fest-item .fest-tl-tools { grid-column: 1 / -1; }
.fest-item.is-full { opacity: 0.75; }
.fest-item.is-mine { border-color: color-mix(in srgb, var(--ok) 55%, var(--border)); }
.fest-missing { color: var(--amber); font-weight: 700; }
.fest-claim { display: flex; gap: 6px; align-items: center; }
.fest-qty { width: 64px; min-height: 36px; padding: 6px 8px; }

/* ---------- The lock / invitation teaser ---------- */

.fest-lock { text-align: center; display: grid; gap: 6px; justify-items: center; padding: 30px 20px; position: relative; overflow: hidden;
  background: linear-gradient(160deg, color-mix(in srgb, var(--fest-accent) 20%, var(--surface)), var(--surface)); }
.fest-lock h1, .fest-lock h2 { margin: 4px 0; font-size: clamp(1.6rem, 6vw, 2.4rem); overflow-wrap: anywhere; }
.fest-lock p { margin: 0; }
.fest-lock-emoji { font-size: 3.6rem; line-height: 1; }
@media (prefers-reduced-motion: no-preference) { .fest-lock-emoji { animation: fest-float 3.2s ease-in-out infinite; } }
@keyframes fest-float { 50% { transform: translateY(-6px) rotate(-4deg); } }
.fest-lock-when { font-weight: 700; font-size: 1.05rem; }
.fest-lock-why { margin-top: 14px; padding: 14px 16px; border-radius: 16px; background: var(--surface-2); border: 1px dashed color-mix(in srgb, var(--amber) 60%, var(--border)); display: grid; gap: 8px; max-width: 520px; }
.fest-lock-actions { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }
.fest-invite-actions { margin-top: 16px; display: grid; gap: 10px; justify-items: center; }
.fest-invite-actions p { margin: 0; }
.fest-danger { border-color: color-mix(in srgb, var(--danger) 40%, var(--border)); display: grid; gap: 16px; }
.fest-danger h2 { margin: 0; font-size: 1.05rem; }

/* ---------- The party type's look (assets/css/fest/types/<type>.css sets the tokens) ---------- */

.fest-hero h1, .fest-lock h1, .fest-lock h2, .fest-banner h2, .fest-checklist h2, .fest-rsvp-q, .fest-cd-unit b { font-family: var(--fest-font, "Bricolage Grotesque", sans-serif); }
.fest-hero > * { position: relative; z-index: 1; }
.fest-hero { padding-right: max(20px, min(34%, 240px)); }
.fest-hero::after { content: ""; position: absolute; right: 8px; bottom: 0; width: min(32%, 230px); aspect-ratio: 6 / 5; background: var(--fest-art) no-repeat center bottom / contain; pointer-events: none; }
@media (max-width: 560px) {
  .fest-hero { padding-right: 20px; padding-top: 86px; }
  .fest-hero::after { top: 6px; bottom: auto; right: 6px; width: 110px; }
}
.fest-lock::after { content: ""; position: absolute; inset: auto 0 0 auto; width: 46%; max-width: 260px; aspect-ratio: 6 / 5; background: var(--fest-art) no-repeat right bottom / contain; opacity: 0.22; pointer-events: none; }
.fest-lock > * { position: relative; z-index: 1; }
.fest-type-art { position: absolute; right: -6px; bottom: -8px; width: 92px; aspect-ratio: 6 / 5; background: var(--fest-art) no-repeat center / contain; opacity: 0.85; pointer-events: none; }
.fest-type-card > :not(.fest-type-art) { position: relative; z-index: 1; }
.fest-type-card .fest-type-tag { max-width: calc(100% - 70px); }
.fest-form { position: relative; overflow: hidden; }
.fest-form > .fest-type-art { top: 8px; bottom: auto; right: 8px; width: 120px; }
.fest-form > :not(.fest-type-art) { position: relative; z-index: 1; }
@media (max-width: 560px) { .fest-form > .fest-type-art { width: 84px; opacity: 0.6; } }
body[data-fest-type] .page-head h1 { font-family: var(--fest-font, "Bricolage Grotesque", sans-serif); }

/* The easter eggs (assets/js/fest-eggs.js): the hero chip is a button, particles fly, something hides on a card. */
button.fest-type-chip { font: inherit; font-size: 0.75rem; font-weight: 700; cursor: pointer; }
.fest-confetti { position: fixed; z-index: 60; width: 8px; height: 12px; border-radius: 2px; pointer-events: none; animation: fest-burst 1.6s cubic-bezier(0.2, 0.6, 0.4, 1) forwards; }
@keyframes fest-burst { to { transform: translate(var(--dx), var(--dy)) rotate(var(--r)); opacity: 0; } }
.fest-bat { position: fixed; z-index: 60; font-size: 28px; pointer-events: none; animation: fest-bat 2.4s ease-in forwards; }
@keyframes fest-bat { to { transform: translate(var(--dx, 60vw), -70vh) scale(0.6) rotate(12deg); opacity: 0; } }
.card { position: relative; }
.fest-hidden-egg { position: absolute; right: 10px; bottom: 8px; z-index: 2; width: 28px; height: 28px; padding: 0; border: 0; background: none; font-size: 15px; opacity: 0.55; cursor: pointer; }
.fest-hidden-egg:hover, .fest-hidden-egg:focus-visible { opacity: 1; transform: scale(1.3); }

/* The header's party switcher: the party's emoji in front of the name. */
.fest-switch .trip-switch-name span { margin-right: 2px; }
/* A party with many tabs (a julefrokost has eight) doesn't fit with every label on a wide screen: app.css shows such
   a nav as icons next to any switcher (.trip-switch, which this is), so the switcher keeps its name. */
/* It shrinks only when the header is full (760–900 px with many tabs) rather than push the actions off screen. */
@media (min-width: 760px) { .fest-switch { flex: 0 1 260px; min-width: 0; max-width: 260px; } }

/* ---------- The seating plan (fest_bordplan.php, assets/js/fest-seating.js) ---------- */

.seat-tools { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; }
.seat-publish, .seat-auto { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.seat-auto form { display: contents; }
.seat-plan { display: grid; gap: 16px; }
@media (min-width: 900px) { .seat-plan.is-editable { grid-template-columns: 260px 1fr; align-items: start; } .seat-tray { position: sticky; top: 84px; } }
.seat-tray { padding: 14px; border-radius: var(--fest-radius); background: var(--surface); border: 1px dashed color-mix(in srgb, var(--fest-accent) 45%, var(--border)); }
.seat-tray h3 { margin: 0 0 10px; font-size: 0.95rem; }
.seat-tray.is-over { background: color-mix(in srgb, var(--fest-accent) 12%, var(--surface)); }
.seat-tray-chips { display: flex; flex-wrap: wrap; gap: 6px; min-height: 44px; }
.seat-tray-actions { display: flex; gap: 6px; flex-wrap: wrap; margin: 10px 0 0; }
.seat-hint { margin: 8px 0 0; }
/* Round and long tables differ in height – centre them on one line so the boards line up, not the seats. */
.seat-tables { display: flex; flex-wrap: wrap; gap: 26px 22px; justify-content: center; align-items: center; padding: 18px 4px; }

.seat-table { position: relative; margin: 0; width: clamp(210px, calc(var(--n) * 30px), 330px); aspect-ratio: 1; }
.seat-table.is-long { width: clamp(240px, calc(var(--n) * 34px), 560px); aspect-ratio: auto; height: 170px; }
.seat-board { position: absolute; inset: 22%; border-radius: 50%; display: grid; place-content: center; text-align: center; gap: 2px;
  background: radial-gradient(circle at 35% 30%, color-mix(in srgb, var(--fest-accent) 26%, var(--surface-2)), var(--surface-2));
  border: 2px solid color-mix(in srgb, var(--fest-accent) 40%, var(--border)); box-shadow: inset 0 0 0 6px color-mix(in srgb, var(--bg) 40%, transparent); }
.seat-table.is-long .seat-board { inset: 30% 6%; border-radius: 18px; }
.seat-board b { font-family: var(--fest-font, "Bricolage Grotesque", sans-serif); font-size: 1rem; }
.seat-board small { color: var(--muted); font-size: 0.72rem; }
.seat { position: absolute; left: var(--x); top: var(--y); transform: translate(-50%, -50%); width: 64px; display: grid; justify-items: center; }
.seat-empty { width: 40px; height: 40px; border-radius: 50%; border: 2px dashed color-mix(in srgb, var(--muted) 55%, transparent); background: var(--bg);
  color: var(--faint); font: 700 0.78rem/1 "Inter", sans-serif; display: grid; place-items: center; padding: 0; cursor: default; }
button.seat-empty { cursor: pointer; }
.seat-plan.is-picking button.seat-empty { border-color: var(--fest-accent); color: var(--fest-accent); }
.seat.is-over .seat-empty, .seat.is-over .seat-chip { outline: 3px solid var(--fest-accent); outline-offset: 2px; }

.seat-chip { display: inline-grid; justify-items: center; gap: 2px; padding: 3px; border: 0; border-radius: 14px; background: none; color: var(--text); font: inherit; position: relative; }
button.seat-chip { cursor: grab; touch-action: none; -webkit-user-select: none; user-select: none; }
.seat-chip .avatar { box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px color-mix(in srgb, var(--fest-accent) 55%, transparent); }
.seat-name { font-size: 0.72rem; font-weight: 700; max-width: 64px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.seat-pin { position: absolute; top: -4px; right: 2px; font-size: 0.7rem; }
.seat-tray .seat-chip { grid-auto-flow: column; align-items: center; gap: 6px; padding: 4px 10px 4px 4px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border); }
.seat-chip[aria-pressed="true"] { background: color-mix(in srgb, var(--fest-accent) 30%, var(--surface-2)); box-shadow: 0 0 0 2px var(--fest-accent); }
.seat-chip.is-dragging { opacity: 0.35; }
.seat-chip.is-me .avatar, .seat.is-me .avatar { box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px var(--fest-gold, #ffd166); }
.seat-ghost { position: fixed; left: 0; top: 0; z-index: 400; pointer-events: none; display: inline-grid; justify-items: center; padding: 4px; border-radius: 14px;
  background: var(--surface); box-shadow: 0 14px 30px rgba(0, 0, 0, 0.45); }
@media (prefers-reduced-motion: no-preference) {
  .seat .seat-chip { animation: fest-seat-in 0.25s ease-out; }
  .seat-ghost { transform-origin: center; }
}
@keyframes fest-seat-in { from { transform: scale(0.7); opacity: 0.4; } }

.seat-list { display: grid; gap: 8px; }
.seat-list-row { display: grid; grid-template-columns: 1fr minmax(0, 220px) auto; gap: 8px; align-items: center; }
.seat-list-row label { font-weight: 600; }
.seat-table-list { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 8px; }
.seat-table-list li { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.seat-table-edit { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; flex: 1; }
.seat-table-edit input[name="name"] { flex: 1; min-width: 120px; }
.seat-table-edit input[type="number"] { width: 72px; }
.seat-table-edit select { width: auto; }
.seat-rule { display: flex; gap: 10px; align-items: center; justify-content: space-between; padding: 6px 0; border-bottom: 1px solid var(--border); }
.seat-rule-add { margin-top: 10px; align-items: end; }
.fest-form-wrap h2 { margin: 0 0 10px; font-size: 1.05rem; }

/* ---------- Secret missions and polls (fest_missioner.php, app/fest/views.php fest_poll_html()) ---------- */

.fest-mission-teaser { display: grid; grid-template-columns: 44px 1fr; gap: 12px; align-items: center; color: inherit; text-decoration: none; margin: 14px 0;
  background: linear-gradient(110deg, color-mix(in srgb, var(--fest-accent) 18%, var(--surface)), var(--surface) 70%); }
.fest-mission-teaser > span:first-child { font-size: 2rem; text-align: center; }
.fest-mission-teaser > span:last-child { display: grid; gap: 2px; }
.mission-card { border-style: dashed; }
.mission-card summary { cursor: pointer; font-weight: 800; list-style: none; display: flex; gap: 10px; align-items: center; }
.mission-card summary::-webkit-details-marker { display: none; }
.mission-card[open] summary { margin-bottom: 10px; }
.mission-card.is-done { border-color: color-mix(in srgb, var(--ok) 55%, var(--border)); }
.mission-text { font-family: var(--fest-font, "Bricolage Grotesque", sans-serif); font-size: 1.25rem; line-height: 1.3; margin: 0 0 12px; overflow-wrap: anywhere; }
.mission-how ol { margin: 0 0 8px; padding-left: 1.2em; display: grid; gap: 6px; }
.mission-how h2, .fest-tools h2 { margin-top: 0; }
.mission-reveals { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.mission-reveal p { margin: 0 0 4px; }
.mission-reveal.is-done { border-color: color-mix(in srgb, var(--ok) 55%, var(--border)); }
.mission-admin { list-style: none; padding: 0; margin: 0 0 12px; display: grid; gap: 8px; }
.mission-admin li { display: grid; gap: 6px; padding: 10px 0; border-bottom: 1px solid var(--border); }
.mission-admin li form { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.mission-admin select { width: auto; flex: 1; min-width: 140px; }
.mission-admin-text { font-weight: 600; overflow-wrap: anywhere; }
.mission-library { margin: 10px 0; }
.mission-library summary { cursor: pointer; font-weight: 700; color: var(--fest-accent); }
.mission-library ul { list-style: none; padding: 0; margin: 8px 0 0; display: grid; gap: 6px; }
.mission-library li form { justify-content: space-between; }
.mission-library li span { flex: 1; font-size: 0.92rem; }
.mission-time { margin-top: 12px; align-items: end; }
.fest-poll { display: grid; gap: 10px; margin-bottom: 12px; }
.fest-poll-q { margin: 0; font-family: var(--fest-font, "Bricolage Grotesque", sans-serif); font-size: 1.15rem; font-weight: 800; overflow-wrap: anywhere; }
.fest-poll-prize { margin: 0; font-weight: 700; color: var(--fest-gold, var(--accent)); }
.fest-poll-options { display: grid; gap: 6px; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
.fest-poll-option { position: relative; display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 10px 12px; border-radius: 14px; cursor: pointer;
  background: var(--surface-2); border: 1px solid var(--border); overflow: hidden; font-weight: 600; }
.fest-poll-option input { position: absolute; opacity: 0; pointer-events: none; }
.fest-poll-option:has(input:checked) { border-color: var(--fest-accent); box-shadow: 0 0 0 1px var(--fest-accent); background: color-mix(in srgb, var(--fest-accent) 18%, var(--surface-2)); }
.fest-poll-option:has(input:focus-visible) { outline: 2px solid var(--fest-accent); outline-offset: 2px; }
.fest-poll.is-closed .fest-poll-option { cursor: default; }
.fest-poll.is-closed .fest-poll-option::before { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--share); background: color-mix(in srgb, var(--fest-accent) 20%, transparent); }
.fest-poll-option > * { position: relative; }
.fest-poll-option.is-winner { border-color: var(--fest-gold, var(--accent)); }
.fest-poll-option small { color: var(--muted); font-weight: 600; }
.fest-poll-foot { display: flex; gap: 10px; align-items: center; margin: 0; }
@media (prefers-reduced-motion: no-preference) { .fest-poll-option.is-winner { animation: fest-wiggle 0.8s ease-in-out 1; } }

/* ---------- Halloween costumes (fest_kostumer.php) ---------- */

.flash-warn { border-color: color-mix(in srgb, var(--amber) 60%, var(--border)); }
.costume-mine h2 { margin: 0 0 10px; font-size: 1.05rem; }
.costume-current { display: flex; gap: 14px; align-items: center; margin: 0 0 14px; }
.costume-current span { display: grid; gap: 2px; }
.costume-current b { font-family: var(--fest-font, "Bricolage Grotesque", sans-serif); font-size: 1.2rem; }
.costume-picker fieldset { border: 0; margin: 0; padding: 0; }
.costume-grid { display: grid; gap: 8px; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); }
.costume-option { position: relative; display: grid; justify-items: center; gap: 4px; padding: 10px 6px 8px; border-radius: 16px; cursor: pointer; text-align: center;
  background: var(--surface-2); border: 1px solid var(--border); font-weight: 700; font-size: 0.82rem; }
.costume-option input { position: absolute; opacity: 0; pointer-events: none; }
.costume-option:has(input:checked) { border-color: var(--fest-accent); box-shadow: 0 0 0 1px var(--fest-accent); background: color-mix(in srgb, var(--fest-accent) 18%, var(--surface-2)); }
.costume-option:has(input:focus-visible) { outline: 2px solid var(--fest-accent); outline-offset: 2px; }
.costume-taken { color: var(--amber); font-size: 0.7rem; font-weight: 700; }
.costume-text { display: grid; gap: 6px; margin: 12px 0; font-weight: 600; font-size: 0.9rem; }
.costume-actions { margin: 0; }
.costume-gallery { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); }
.costume-card { display: grid; justify-items: center; gap: 4px; text-align: center; padding: 14px 10px; }
.costume-card.is-none { opacity: 0.7; }
.costume-card.is-dup { border-color: color-mix(in srgb, var(--amber) 55%, var(--border)); }
.costume-unknown { font-size: 2.6rem; line-height: 56px; }
.costume-assign { align-items: end; margin-bottom: 12px; }
@media (prefers-reduced-motion: no-preference) {
  .costume-option:hover .costume-icon, .costume-option:has(input:checked) .costume-icon { animation: fest-wiggle 0.6s ease-in-out; }
}

/* ---------- The festival: line-up and my plan (fest_lineup.php) ---------- */

.lineup-days { display: flex; gap: 6px; overflow-x: auto; padding: 2px 2px 10px; margin: 0 0 6px; scroll-snap-type: x mandatory; }
.lineup-days a { flex: none; scroll-snap-align: start; padding: 8px 14px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border);
  color: var(--text); text-decoration: none; font-weight: 700; font-size: 0.88rem; white-space: nowrap; }
.lineup-days a[aria-current="page"] { background: var(--fest-accent); color: var(--accent-ink); border-color: var(--fest-accent); }
.lineup-mine { border-color: color-mix(in srgb, var(--fest-gold, #ffd166) 60%, var(--border)) !important; }
.lineup-now p { border-left: 4px solid var(--stage, var(--fest-accent)); }
.lineup-acts { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.lineup-act { display: grid; grid-template-columns: 56px 1fr auto; gap: 12px; align-items: center; padding: 12px 14px; border-left: 5px solid var(--stage); position: relative; }
.lineup-act.is-mine { background: linear-gradient(100deg, color-mix(in srgb, var(--stage) 16%, var(--surface)), var(--surface) 70%); }
.lineup-act.is-clash { box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--amber) 60%, transparent); }
.lineup-time { display: grid; text-align: center; font-variant-numeric: tabular-nums; }
.lineup-time b { font-size: 1.05rem; }
.lineup-time small { color: var(--muted); font-size: 0.75rem; }
.lineup-body { display: grid; gap: 2px; min-width: 0; }
.lineup-stage { font-size: 0.7rem; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--stage); }
.lineup-name { font-family: var(--fest-font, "Bricolage Grotesque", sans-serif); font-size: 1.08rem; overflow-wrap: anywhere; }
.lineup-crew { color: var(--text); font-weight: 600; font-size: 0.8rem; }
.lineup-star { display: grid; justify-items: center; width: 48px; height: 52px; border-radius: 14px; border: 1px solid var(--border); background: var(--surface-2);
  color: var(--fest-gold, #ffd166); font-size: 1.5rem; line-height: 1; cursor: pointer; padding: 6px 0 4px; }
.lineup-star small { color: var(--muted); font-size: 0.68rem; font-weight: 700; }
.lineup-star[aria-pressed="true"] { background: color-mix(in srgb, var(--fest-gold, #ffd166) 22%, var(--surface-2)); border-color: var(--fest-gold, #ffd166); }
.lineup-del { position: absolute; right: 70px; top: 8px; font-size: 0.75rem; }
.lineup-stages { list-style: none; padding: 0; margin: 0 0 10px; display: flex; flex-wrap: wrap; gap: 8px; }
.lineup-stages li { display: flex; gap: 8px; align-items: center; padding: 6px 12px; border-radius: 999px; background: var(--surface-2); border-left: 5px solid var(--stage); }
.lineup-stages-h { margin-top: 18px !important; }
.fest-inline-row input[type="color"] { width: 54px; padding: 4px; flex: none; }
@media (prefers-reduced-motion: no-preference) { .lineup-star[aria-pressed="true"] { animation: fest-wiggle 0.6s ease-in-out 1; } }

/* ---------- Live mode, the recap, the taste of the themed parties ---------- */

.live-hero h1 { font-size: clamp(1.8rem, 7vw, 2.8rem); }
.live-news { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.live-news li { display: grid; grid-template-columns: 40px 1fr auto; gap: 12px; align-items: center; padding: 12px 14px; }
.live-news-emoji { font-size: 1.7rem; text-align: center; }
.live-news span:nth-child(2) { display: grid; gap: 2px; }
.live-poll-form { margin-top: 14px; }
.live-tv { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--border); }
.live-tv h3 { margin: 0 0 6px; }
.tv-mini { margin: 10px 0; aspect-ratio: 16 / 9; max-width: 320px; border-radius: 14px; display: grid; place-content: center; justify-items: center; gap: 4px; text-align: center;
  background: radial-gradient(circle at 70% 20%, color-mix(in srgb, var(--fest-accent) 35%, transparent), transparent 60%), #0b0716; color: #fff; border: 4px solid #1d1830; box-shadow: 0 10px 24px rgba(0, 0, 0, 0.35); }
.tv-mini b { font-family: var(--fest-font, "Bricolage Grotesque", sans-serif); font-size: 1.2rem; }
.tv-mini span { opacity: 0.7; font-size: 0.8rem; }
.fest-recap { list-style: none; padding: 0; margin: 12px 0 0; display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.fest-recap li { display: grid; padding: 8px 14px; border-radius: 14px; background: var(--surface-2); min-width: 96px; }
.fest-recap b { font-family: var(--fest-font, "Bricolage Grotesque", sans-serif); font-size: 1.2rem; color: var(--fest-accent); }
.fest-recap span { color: var(--muted); font-size: 0.78rem; }
.fest-more { border-style: dashed; }
.fest-more h2 { margin: 0 0 6px; font-size: 1.05rem; }
.fest-more ul { margin: 6px 0 10px; padding-left: 1.2em; color: var(--muted); }
