/* Invitation engine: shared mechanics (themes set the variables and restyle the rest). README → Speed. */
:root {
  --bg: #faf7f2; --paper: #fffdf9; --ink: #1f1d1a; --muted: #6b665e; --line: rgba(0,0,0,.12);
  --accent: #8a6d3b; --accent-ink: #fff; --display: Georgia, serif; --text: system-ui, sans-serif; --script: var(--display);
  --radius: 12px; --maxw: 680px; --gutter: 22px;
  --env: #e9dcc4; --env-dark: #dccaa6; --seal: #8b2f2f; --seal-ink: #f6e7c8;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--text); font-size: 1.0625rem; line-height: 1.6; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img { max-width: 100%; display: block; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3 { margin: 0; font-weight: 400; line-height: 1.1; }
p { margin: 0 0 1em; }
ol, ul { margin: 0; padding: 0; list-style: none; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.hero-t:focus { outline: none; }
html { -webkit-tap-highlight-color: transparent; }   /* no blue flash over the whole opening screen on Android / Messenger */
html.intro-lock, html.intro-lock body { overflow: hidden; height: 100%; }

/* Layout */
.inv { overflow: hidden; }
.s { padding: 72px var(--gutter); }
.s > * { max-width: var(--maxw); margin-left: auto; margin-right: auto; }
.sh { text-align: center; margin-bottom: 32px; }
.sh-k { font-size: .76rem; letter-spacing: .2em; text-transform: uppercase; color: var(--accent); margin-bottom: 10px; }
.sh-t { font-family: var(--display); font-size: clamp(2rem, 8vw, 2.9rem); }

/* Buttons */
.btn-line { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; padding: 10px 20px; border: 1px solid currentColor; border-radius: 999px; background: transparent; text-decoration: none; font-size: .92rem; letter-spacing: .04em; cursor: pointer; transition: background-color .2s, color .2s; }
.btn-line:hover { background: var(--ink); color: var(--bg); border-color: var(--ink); }

/* Intro (default envelope) */
.intro { --intro-ms: 2300; position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; background: var(--bg); cursor: pointer;
  transition: opacity .6s ease 1.7s, visibility 0s linear 2.3s; }
html:not(.js) .intro { display: none; }
.is-opening .intro { opacity: 0; visibility: hidden; }
.intro-stage { display: grid; justify-items: center; gap: 22px; padding: 24px; }
.env { --w: min(330px, 86vw); position: relative; width: var(--w); aspect-ratio: 1.5; perspective: 1000px; margin-top: 40px; }
.env-back { position: absolute; inset: 0; border-radius: 6px; background: var(--env-dark); box-shadow: 0 24px 50px -24px rgba(0,0,0,.5); }
.env-card { position: absolute; left: 6%; right: 6%; top: 6%; bottom: 5%; z-index: 2; background: var(--paper); border-radius: 3px; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: 4px; padding: 18px 12px; text-align: center; transition: transform .9s cubic-bezier(.2,.8,.2,1) .45s; }
.env-for { font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); }
.env-names { font-family: var(--display); font-size: 1.55rem; line-height: 1.1; }
.env-date { font-size: .8rem; color: var(--muted); }
.env-pocket { position: absolute; inset: 0; z-index: 3; border-radius: 6px; pointer-events: none; background: var(--env);
  background-image: linear-gradient(to top right, rgba(0,0,0,.05) 50%, transparent 50%), linear-gradient(to top left, rgba(255,255,255,.06) 50%, transparent 50%);
  background-size: 50.4% 100%; background-position: left bottom, right bottom; background-repeat: no-repeat;
  clip-path: polygon(0 0, 50% 57%, 100% 0, 100% 100%, 0 100%); }
.env-flap { position: absolute; left: 0; right: 0; top: 0; height: 60%; z-index: 4; transform-origin: top; background: var(--env-dark); clip-path: polygon(0 0, 100% 0, 50% 100%);
  transition: transform .6s cubic-bezier(.4,0,.2,1), z-index 0s linear .3s; }
.env-seal { position: absolute; z-index: 5; left: 50%; top: 60%; width: 66px; height: 66px; margin: -33px 0 0 -33px; border: 0; border-radius: 50%; padding: 0; cursor: pointer;
  background: radial-gradient(circle at 34% 30%, color-mix(in srgb, var(--seal) 70%, #fff), var(--seal) 55%, color-mix(in srgb, var(--seal) 70%, #000));
  color: var(--seal-ink); font-family: var(--display); font-size: 1.7rem; box-shadow: inset 0 0 0 4px rgba(255,255,255,.12), 0 6px 14px rgba(0,0,0,.3);
  animation: seal-breathe 2.8s ease-in-out infinite; transition: transform .4s, opacity .4s; }
.env-seal { background-color: var(--seal); }
.intro-hint { font-size: .86rem; letter-spacing: .08em; color: var(--muted); margin: 0; }
@keyframes seal-breathe { 50% { transform: scale(1.06); } }
.is-opening .env-flap { transform: rotateX(180deg); z-index: 1; }
.is-opening .env-seal { opacity: 0; transform: scale(.5); animation: none; }
.is-opening .env-card { animation: env-card-out 1.75s cubic-bezier(.3,.7,.2,1) .35s both; }
.is-opening .env-back, .is-opening .env-pocket { animation: env-away .6s ease-in 1.15s both; }
.is-opening .env-flap { animation: env-fade .45s ease-in 1.15s both; }
/* the card slides all the way out of the envelope, comes to the front, then grows toward the guest while the envelope drops away */
@keyframes env-card-out { 0% { transform: none; z-index: 2; } 45% { transform: translateY(-82%); z-index: 2; } 46% { z-index: 6; } 100% { transform: translateY(-30%) scale(1.22); z-index: 6; box-shadow: 0 30px 60px -20px rgba(0,0,0,.35); } }
@keyframes env-away { to { opacity: 0; transform: translateY(36px); } }
@keyframes env-fade { to { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .is-opening .env-card, .is-opening .env-back, .is-opening .env-pocket, .is-opening .env-flap { animation: none; } }
.is-opening .intro-hint { opacity: 0; transition: opacity .3s; }

/* Reveals (only when JS + motion allowed) */
.rv-on [data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity .9s ease, transform .9s cubic-bezier(.2,.8,.2,1); }
.rv-on [data-reveal].in { opacity: 1; transform: none; }

/* Hero (defaults) */
.s-hero { min-height: 100svh; display: grid; place-items: center; text-align: center; }
.hero-guest { font-style: italic; }
.hero-t { font-family: var(--display); font-size: clamp(3rem, 14vw, 5.5rem); }
.hero-cta { display: inline-flex; min-height: 48px; align-items: center; padding: 12px 28px; margin-top: 18px; border-radius: 999px; background: var(--accent); color: var(--accent-ink); text-decoration: none; letter-spacing: .06em; }

/* Countdown */
.cd { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; text-align: center; }
.cd-u b { display: block; font-family: var(--display); font-weight: 400; font-size: clamp(2rem, 10vw, 3rem); line-height: 1; font-variant-numeric: tabular-nums; }
.cd-u span { font-size: .7rem; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.cd-done { text-align: center; font-family: var(--display); font-size: 1.6rem; }
.cal { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 28px; }

/* Timeline */
.tl-i { display: grid; grid-template-columns: 84px 1fr; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.tl-time { font-variant-numeric: tabular-nums; color: var(--accent); font-size: .92rem; padding-top: 2px; }
.tl-title { display: block; font-weight: 600; }
.tl-text { display: block; color: var(--muted); font-size: .95rem; }

/* Venues */
.vn { display: grid; gap: 16px; }
.vn-c { padding: 24px 20px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); text-align: center; }
.vn-l { font-size: .74rem; letter-spacing: .18em; text-transform: uppercase; color: var(--accent); margin-bottom: 6px; }
.vn-n { font-family: var(--display); font-size: 1.6rem; margin-bottom: 6px; }
.vn-a, .vn-t, .vn-note { color: var(--muted); margin-bottom: 6px; }
.vn-c .btn-line { margin-top: 10px; }

/* People */
.pp-intro { text-align: center; color: var(--muted); }
.pp { display: grid; gap: 28px; }
.pp-h { font-family: var(--display); font-size: 1.35rem; text-align: center; margin-bottom: 10px; }
.pp-l { text-align: center; }
.pp-l li { padding: 3px 0; }

/* Dress code */
.dr-text, .dr-note { text-align: center; }
.dr-note { color: var(--muted); font-size: .95rem; }
.dr-roles { display: grid; gap: 10px; max-width: 520px; margin: 18px auto 6px; }
.dr-roles > div { padding: 10px 14px; border: 1px solid var(--line); border-radius: var(--radius, 12px); text-align: center; }
.dr-roles dt { font-size: .74rem; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); font-weight: 600; }
.dr-roles dd { margin: 3px 0 0; overflow-wrap: anywhere; }
.sw { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px 18px; margin: 18px auto 22px; }
.sw li { display: grid; justify-items: center; gap: 6px; font-size: .78rem; color: var(--muted); }
.sw-dot { width: 46px; height: 46px; border-radius: 50%; background: var(--c); box-shadow: inset 0 0 0 1px rgba(0,0,0,.12); }
.sw-b { display: grid; justify-items: center; gap: 6px; padding: 0; border: 0; background: none; color: inherit; font: inherit; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.sw-b:active .sw-dot { transform: scale(.92); }
.sw-dot { transition: transform .15s; }
.sw-b.is-copied .sw-n { color: var(--accent); }
.sw-hint { text-align: center; font-size: .74rem; color: var(--muted); margin: -12px auto 20px; }
/* Gallery */
.gal { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.gal-i { margin: 0; }
.gal-i img, .gal-ph { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--radius); }
.gal-ph { display: grid; place-items: center; background: linear-gradient(150deg, color-mix(in srgb, var(--accent) 30%, var(--paper)), color-mix(in srgb, var(--accent) 60%, var(--bg))); color: var(--paper); font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; }
.gal-ph { background-color: var(--accent); }
.gal-i figcaption { font-size: .82rem; color: var(--muted); margin-top: 6px; text-align: center; }

/* FAQ */
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; padding: 16px 36px 16px 0; position: relative; font-weight: 600; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 4px; top: 50%; transform: translateY(-50%); font-size: 1.3rem; color: var(--accent); transition: transform .2s; }
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq p { color: var(--muted); }

/* RSVP */
.rs-by { text-align: center; color: var(--muted); }
.rs { display: grid; gap: 16px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px 20px; }
.f { display: grid; gap: 6px; border: 0; margin: 0; padding: 0; min-width: 0; }
.f-l { font-size: .82rem; letter-spacing: .06em; color: var(--muted); padding: 0; }
.f-in { width: 100%; min-height: 48px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); font-size: 1rem; }
textarea.f-in { min-height: 96px; resize: vertical; }
.f-in:focus { border-color: var(--accent); outline: none; box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 22%, transparent); }
.f-choice { display: grid; gap: 8px; }
.ch { position: relative; display: block; cursor: pointer; }
.ch input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.ch span { display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 12px 16px; border: 1px solid var(--line); border-radius: 10px; background: var(--bg); transition: border-color .2s, background-color .2s; }
.ch span::before { content: ""; flex: none; width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid var(--muted); transition: box-shadow .2s, border-color .2s; }
.ch input:checked + span { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 8%, var(--bg)); }
.ch input:checked + span::before { border-color: var(--accent); box-shadow: inset 0 0 0 4px var(--bg), inset 0 0 0 9px var(--accent); }
.ch input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.rs-err { color: #b3261e; margin: 0; font-size: .92rem; }
.rs-btn { min-height: 52px; border: 0; border-radius: 999px; background: var(--accent); color: var(--accent-ink); font-size: 1rem; letter-spacing: .06em; cursor: pointer; transition: transform .15s, opacity .2s; }
.rs-btn:active { transform: translateY(1px); }
.rs-btn.is-busy { opacity: .6; }
.rs-done { text-align: center; padding: 28px 20px; border-radius: var(--radius); background: var(--paper); border: 1px solid var(--line); }
.rs-done:focus { outline: none; }
.rs-done-t { font-family: var(--display); font-size: 2rem; line-height: 1.15; }
.rs-done-p { color: var(--muted); }
.demo-note { text-align: center; font-size: .8rem; color: var(--muted); margin-top: 16px; }

/* Closing */
.s-closing { text-align: center; padding-bottom: 110px; }
.cl-line { font-family: var(--display); font-size: 1.7rem; line-height: 1.25; }
.cl-sign { color: var(--muted); }
.cl-tag { color: var(--accent); letter-spacing: .06em; }

/* Music & demo bar */
.music { position: fixed; z-index: 60; right: 14px; top: calc(14px + env(safe-area-inset-top)); display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--ink) 18%, transparent); background: color-mix(in srgb, var(--paper) 88%, transparent); color: var(--accent); cursor: pointer;
  box-shadow: 0 6px 18px -8px rgba(0, 0, 0, .45); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); transition: transform .2s; }
.music[hidden] { display: none; }
.music:active { transform: scale(.92); }
.music-ic { font-size: 1.15rem; line-height: 1; position: relative; }
.music:not(.is-on) .music-ic::after { content: ""; position: absolute; left: -3px; right: -3px; top: 50%; height: 1.5px; background: currentColor; transform: rotate(-40deg); border-radius: 2px; }
.music-eq { display: none; gap: 2.5px; align-items: flex-end; height: 16px; }
.music.is-on .music-ic { display: none; } .music.is-on .music-eq { display: flex; }
.music-eq i { width: 3px; border-radius: 2px; background: currentColor; animation: music-eq .9s ease-in-out infinite alternate; }
.music-eq i:nth-child(1) { height: 60%; } .music-eq i:nth-child(2) { height: 100%; animation-delay: -.3s; } .music-eq i:nth-child(3) { height: 45%; animation-delay: -.6s; }
@keyframes music-eq { from { transform: scaleY(.35); } to { transform: scaleY(1); } }
.music-eq i { transform-origin: bottom; }
@media (prefers-reduced-motion: reduce) { .music-eq i { animation: none; } }
@keyframes spin { to { transform: rotate(360deg); } }
.demo-bar { position: fixed; z-index: 70; left: 10px; right: 10px; bottom: calc(10px + env(safe-area-inset-bottom)); display: flex; align-items: center; gap: 10px; padding: 8px 8px 8px 16px; border-radius: 999px;
  background: rgba(21,18,43,.9); color: #fff; font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; font-size: .82rem; box-shadow: 0 16px 34px -14px rgba(21,18,43,.6), inset 0 0 0 1px rgba(255,255,255,.08); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
.db-brand { display: inline-flex; align-items: center; gap: 7px; min-width: 40px; min-height: 40px; justify-content: center; font-weight: 700; text-decoration: none; white-space: nowrap; color: #fff; }
.db-brand::before { content: ""; width: 24px; height: 24px; flex: none; background: url("../img/favicon.svg") center / contain no-repeat; }
.db-text { opacity: .7; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.db-cta { background: linear-gradient(115deg, #6b46ff, #b54cf5 48%, #ff6a4d); color: #fff; text-decoration: none; padding: 9px 15px; border-radius: 999px; font-weight: 700; white-space: nowrap; box-shadow: 0 8px 18px -10px rgba(107,70,255,.9); }
.db-close { width: 34px; height: 34px; border: 0; border-radius: 50%; background: rgba(255,255,255,.08); color: #fff; font-size: 1.2rem; cursor: pointer; }
.is-demo .s-closing { padding-bottom: 150px; }
@media (max-width: 360px) { .db-text { display: none; } }
@media (max-width: 479px) { .db-brand span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); } .demo-bar { padding-left: 10px; } }

@media (min-width: 720px) {
  .s { padding: 104px var(--gutter); }
  .vn { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
  .gal { grid-template-columns: repeat(3, 1fr); }
  .demo-bar { left: 50%; right: auto; transform: translateX(-50%); width: min(560px, calc(100% - 20px)); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; transition-delay: 0s !important; }
}
/* keep the closing clear of the demo bar whatever a theme sets */
body.is-demo .inv .s-closing { padding-bottom: 150px; }

/* Palette switcher (demo pages only) */
.db-pal { display: inline-flex; align-items: center; gap: 7px; flex: 1; min-width: 0; min-height: 36px; padding: 6px 12px; border: 1px solid rgba(255,255,255,.22); border-radius: 999px; background: rgba(255,255,255,.06); color: #fff; font: 600 .82rem system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; cursor: pointer; white-space: nowrap; }
.db-swatch { width: 16px; height: 16px; border-radius: 50%; background: conic-gradient(#e0715f 0 25%, #e8c15a 0 50%, #5fa38b 0 75%, #5a7bd6 0); }
.pal-sheet { position: fixed; inset: 0; z-index: 90; display: flex; align-items: flex-end; justify-content: center; background: rgba(10,10,10,.45); }
.pal-panel { width: min(560px, 100%); max-height: 82vh; overflow: auto; padding: 18px 16px calc(16px + env(safe-area-inset-bottom)); border-radius: 24px 24px 0 0; background: #fff; color: #15122b;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; box-shadow: 0 -20px 40px -20px rgba(0,0,0,.4); animation: sheet-up .3s cubic-bezier(.2,.8,.2,1); }
@keyframes sheet-up { from { transform: translateY(40px); opacity: 0; } }
.pal-h { font-weight: 700; font-size: 1.05rem; margin: 0 0 2px; }
.pal-sub { font-size: .85rem; color: #5f5b78; margin: 0 0 14px; }
.pal-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.pal { display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 10px 12px; border: 1.5px solid #e6e3f1; border-radius: 14px; background: #fff; color: inherit; font: 600 .86rem system-ui, sans-serif; text-align: left; cursor: pointer; }
.pal[aria-pressed="true"] { border-color: #6b46ff; box-shadow: 0 0 0 4px rgba(107,70,255,.14); }
.pal-dots { display: inline-flex; flex: none; }
.pal-dots i { width: 18px; height: 18px; border-radius: 50%; margin-right: -5px; box-shadow: 0 0 0 2px #fff, inset 0 0 0 1px rgba(0,0,0,.12); }
.pal-n { margin-left: 4px; line-height: 1.2; }
.pal-grid + .pal-h { margin: 18px 0 10px; }
.lay-pick { display: flex; flex-wrap: wrap; gap: 8px; }
.lay-pick a { display: inline-flex; align-items: center; min-height: 44px; padding: 8px 14px; border: 1.5px solid #e6e3f1; border-radius: 99px; color: inherit; text-decoration: none; font: 600 .86rem system-ui; }
.lay-pick a[aria-current] { border-color: #6b46ff; box-shadow: 0 0 0 4px rgba(107,70,255,.14); }
.pal-cta { display: block; margin: 14px 0 10px; padding: 12px 14px; border-radius: 14px; background: linear-gradient(115deg, #efeaff, #fbeaff 50%, #ffece6); color: #15122b; text-decoration: none; font-size: .88rem; line-height: 1.4; }
.pal-cta b { color: #5530ec; }
.pal-done { width: 100%; min-height: 48px; border: 0; border-radius: 999px; background: linear-gradient(115deg, #6b46ff, #b54cf5 48%, #ff6a4d); color: #fff; font: 600 .95rem system-ui, sans-serif; cursor: pointer; }

/* Client photos & editor preview */
.s-photo { padding-top: 8px; padding-bottom: 8px; }
.cover-photo { margin: 0 auto; max-width: 520px; }
.cover-photo img { display: block; width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--radius); box-shadow: 0 18px 40px -24px rgba(0, 0, 0, .45); }
.preview-bar { position: fixed; left: 0; right: 0; top: 0; z-index: 90; display: flex; gap: 10px; align-items: center; justify-content: center; flex-wrap: wrap; padding: 8px 14px calc(8px); background: #15122b; color: #fff; font: 600 .82rem/1.3 system-ui, sans-serif; text-align: center; }
.preview-bar a { color: #fff; background: linear-gradient(115deg, #6b46ff, #b54cf5 48%, #ff6a4d); padding: 6px 12px; border-radius: 999px; text-decoration: none; }

/* RSVP: find my invitation, headcount, companions, table */
.rs-more { display: grid; gap: 16px; }
.rs-greet { margin: 0; padding: 12px 14px; border-radius: 10px; background: color-mix(in srgb, var(--accent) 10%, var(--bg)); border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent); }
.rs-not { margin: 0; text-align: center; font-size: .9rem; }
.rs-not a { color: inherit; display: inline-block; padding: 8px 0; }
.step { display: flex; align-items: center; gap: 14px; }
.step-b { width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--line); background: var(--bg); color: inherit; font: 400 1.5rem/1 var(--text, inherit); cursor: pointer; touch-action: manipulation; }
.step-b:disabled { opacity: .35; cursor: default; }
.step-b:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.step-n { min-width: 2ch; text-align: center; font-family: var(--display); font-size: 2rem; line-height: 1; font-variant-numeric: tabular-nums; }
.rs-hint { margin: 0; font-size: .85rem; color: var(--muted); }
.rs-comp-list { display: grid; gap: 8px; }
.rs-extra { display: grid; gap: 10px; justify-items: center; margin: 6px 0 14px; }
.rs-extra:empty { display: none; }
.rs-party { margin: 0; color: var(--muted); }
.rs-table { margin: 0; display: grid; gap: 2px; padding: 12px 22px; border: 1px solid currentColor; border-radius: var(--radius); background: transparent; color: inherit; }
.rs-table span { opacity: .75; }
.rs-table span { font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; }
.rs-table b { font-family: var(--display); font-weight: 400; font-size: 1.8rem; line-height: 1.1; }

/* Photo spots (demos show where the client's photos and video go) */
.ph-slot { position: relative; display: grid; place-content: center; justify-items: center; gap: 6px; width: 100%; height: 100%; min-height: 120px; padding: 16px 10px;
  border: 2px dashed color-mix(in srgb, var(--accent) 60%, transparent); border-radius: var(--radius);
  background: repeating-linear-gradient(135deg, color-mix(in srgb, var(--accent) 7%, transparent) 0 12px, transparent 12px 24px), color-mix(in srgb, var(--accent) 9%, var(--paper, var(--bg)));
  color: color-mix(in srgb, var(--accent) 80%, var(--ink)); text-align: center; }
.ph-ic { --ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48' fill='none' stroke='%23000' stroke-width='2.4' stroke-linejoin='round'%3E%3Cpath d='M8 16h7l3-5h12l3 5h7v22H8z'/%3E%3Ccircle cx='24' cy='26' r='7'/%3E%3C/svg%3E"); display: block; width: 40px; height: 40px; opacity: .9; background: currentColor; -webkit-mask: var(--ic) center / contain no-repeat; mask: var(--ic) center / contain no-repeat; }
.ph-l { font-size: .78rem; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; line-height: 1.3; }
.ph-s { font-size: .74rem; opacity: .8; letter-spacing: .02em; }
.ph-slot.is-on-photo { border-color: rgba(255, 255, 255, .75); background: rgba(0, 0, 0, .18); color: #fff; text-shadow: 0 1px 2px rgba(0, 0, 0, .35); }
.gal-i .ph-slot { aspect-ratio: 4 / 5; min-height: 0; height: auto; }
.gal-i .ph-slot .ph-ic { width: 30px; height: 30px; }
.gal-i .ph-slot .ph-l { font-size: .66rem; }
.cover-photo .ph-slot { aspect-ratio: 4 / 5; }
.cover-photo .ph-slot .ph-ic { width: 52px; height: 52px; }
.ph-strip-tag { display: block; margin-top: 6px; font-size: .62rem; letter-spacing: .1em; text-transform: uppercase; text-align: center; opacity: .8; }

/* cover video */
.cover-photo { position: relative; }
.cover-media { display: block; width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: var(--radius); box-shadow: 0 18px 40px -24px rgba(0, 0, 0, .45); background: #000; }
.cover-play { position: absolute; left: 50%; top: 50%; width: 64px; height: 64px; margin: -32px 0 0 -32px; border-radius: 50%; border: 0; background: rgba(0, 0, 0, .55); color: #fff; font-size: 1.4rem; cursor: pointer; }

/* photo/video covers: the demo tag that says the client's own media goes here */
.hero-media-tag { position: absolute; z-index: 3; left: 50%; bottom: 16px; transform: translateX(-50%); max-width: calc(100% - 32px); white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  padding: 8px 14px; border-radius: 999px; border: 1.5px dashed rgba(255,255,255,.75); background: rgba(0,0,0,.4); color: #fff; font: 600 .68rem/1 var(--text); letter-spacing: .08em; text-transform: uppercase; }
.cm-media { pointer-events: none; }
.rs-mailed { font-size: .9rem; opacity: .8; margin: 6px 0 10px; }

/* Photos & video, shared by every design (each design styles its own frames). */
/* a frame holds one .mf-media (photo or video) or, on demos, a .ph-slot; both fill it */
.mf { position: relative; overflow: hidden; }
.mf > .mf-media, .mf > img, .mf > .ph-slot { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border-radius: inherit; margin: 0; min-height: 0; }
.mf > .cover-play { z-index: 3; }
.gal-ph { min-height: 0 !important; height: 100% !important; }
img[data-lb-item] { cursor: zoom-in; }
/* swipe rows (scroll-snap) + dots made by media.js */
.swipe { display: flex; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; -webkit-overflow-scrolling: touch;
  margin-block: 0; margin-inline: max(calc(var(--gutter, 20px) * -1), calc((100% - var(--maxw)) / 2)); padding: 10px calc(var(--gutter, 20px) + 6%) 18px; scroll-padding: 0 calc(var(--gutter, 20px) + 6%); }
.swipe::-webkit-scrollbar { display: none; }
.swipe > * { flex: none; scroll-snap-align: center; }
.swipe-dots, .sl-dots { display: flex; justify-content: center; gap: 7px; margin: 4px auto 0; }
.swipe-dots, .sl-dots { gap: 0; }
.swipe-dots button, .sl-dots button { display: grid; place-items: center; min-width: 24px; height: 24px; padding: 0; border: 0; background: none; color: inherit; cursor: pointer; }
.swipe-dots button::before, .sl-dots button::before { content: ""; width: 7px; height: 7px; border-radius: 99px; background: currentColor; opacity: .25; transition: width .25s, opacity .25s; }
.swipe-dots button.is-on::before, .sl-dots button.is-on::before { width: 20px; opacity: .8; }
.swipe-hint { text-align: center; font-size: .74rem; letter-spacing: .14em; text-transform: uppercase; opacity: .6; margin: 10px auto 0; }
/* full-screen viewer */
.lb { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 56px 12px 64px; background: rgba(8, 8, 12, .94); color: #fff; animation: lb-in .2s ease-out; }
@keyframes lb-in { from { opacity: 0; } }
.lb[hidden] { display: none; }
.lb-f { margin: 0; display: grid; gap: 10px; justify-items: center; max-width: min(960px, 100%); }
.lb-i { max-width: 100%; max-height: calc(100svh - 150px); width: auto; height: auto; object-fit: contain; border-radius: 6px; box-shadow: 0 20px 60px -20px #000; }
.lb-c { font: 500 .92rem/1.4 system-ui, -apple-system, "Segoe UI", sans-serif; text-align: center; opacity: .9; max-width: 34em; }
.lb-k { position: absolute; top: 16px; left: 0; right: 0; margin: 0; text-align: center; font: 600 .8rem system-ui, sans-serif; letter-spacing: .1em; opacity: .7; }
.lb-x, .lb-p, .lb-n { position: absolute; display: grid; place-items: center; width: 46px; height: 46px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .12); color: #fff; font: 400 1.7rem/1 system-ui, sans-serif; cursor: pointer; }
.lb-x { top: 10px; right: 10px; }
.lb-p { left: 8px; top: 50%; margin-top: -23px; } .lb-n { right: 8px; top: 50%; margin-top: -23px; }
html.lb-open { overflow: hidden; }
/* deck of cards */
[data-stack] { position: relative; touch-action: pan-y; cursor: pointer; }
[data-stack] .stk { transition: transform .38s cubic-bezier(.2,.8,.2,1), opacity .38s; }
[data-stack] .stk.is-out { transform: translateX(110%) rotate(14deg) !important; opacity: 0; }
@media (prefers-reduced-motion: reduce) { .lb, [data-stack] .stk { animation: none; transition: none; } }
.cover-frame { border-radius: var(--radius); background: color-mix(in srgb, var(--accent) 18%, var(--paper)); box-shadow: 0 18px 40px -24px rgba(0, 0, 0, .45); }
.gal-f { aspect-ratio: 4 / 5; border-radius: var(--radius); }
/* wide photo behind a tall cover: all of it shows, near the top, on a blurred copy of itself */
.cm-media.cm-fill { object-fit: cover !important; filter: blur(24px) brightness(.72) saturate(1.1); transform: scale(1.2); }
.cm-media.cm-wide { object-fit: contain !important; object-position: 50% 4% !important; }
.f-l small { font-size: max(.78em, 11px); font-weight: 400; opacity: .85; }
/* the couple's film (with sound) */
.film-frame { position: relative; border-radius: var(--radius); overflow: hidden; background: #000; box-shadow: 0 24px 50px -30px rgba(0, 0, 0, .6); }
.film-v { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; background: #000; object-fit: contain; }
.film-note { margin: 12px 0 0; text-align: center; font-size: .82rem; color: var(--muted); }
/* demo photo spots: in small gallery tiles show only the camera icon, so "Your photo" never runs into the caption */
.ph-slot { container-type: inline-size; }
@container (max-width: 118px) { .ph-slot .ph-l { display: none; } }

.credit { padding: 18px var(--gutter) calc(26px + env(safe-area-inset-bottom)); text-align: center; font: 500 .8rem/1.5 system-ui, sans-serif; color: var(--muted); }
.credit p { margin: 0; } .credit a { font-size: .72rem; opacity: .8; }
body.is-demo .credit { padding-bottom: 100px; }
