/* Mobile first: the base rules are the phone layout; the media queries at the
   bottom widen it for tablets and desktops. */

:root {
  --red: #b3122e;
  --red-dark: #7d0a1f;
  --gold: #f2b631;
  --gold-dark: #c98a0b;
  --green: #1d7a3d;
  --green-dark: #135429;
  --cream: #fff7ec;
  --paper: #ffffff;
  --ink: #2b1d17;
  --muted: #6d5a50;
  --line: #f0dfc8;
  --shadow: 0 10px 30px rgba(90, 30, 10, 0.15);
  --radius: 20px;
  color-scheme: light;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html { font-size: 18px; }

body {
  margin: 0;
  font-family: 'Nunito', system-ui, sans-serif;
  color: var(--ink);
  line-height: 1.5;
  background:
    radial-gradient(circle at 10% 0%, rgba(242, 182, 49, 0.18), transparent 40%),
    radial-gradient(circle at 90% 20%, rgba(179, 18, 46, 0.10), transparent 40%),
    var(--cream);
  min-height: 100vh;
  overflow-x: hidden;
}

h1, h2, h3 { font-family: 'Fredoka', 'Nunito', sans-serif; line-height: 1.15; margin: 0; }
img { max-width: 100%; display: block; }
figure { margin: 0; }

/* ---------- buttons ---------- */

.btn {
  font: 700 1.05rem/1.2 'Nunito', sans-serif;
  border: 0;
  border-radius: 999px;
  padding: 0.85em 1.5em;
  min-height: 56px;
  cursor: pointer;
  transition: transform 0.12s, background 0.12s;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4em;
  text-align: center;
}
.btn:active { transform: scale(0.97); }
.btn:focus-visible, .btn-link:focus-visible, a:focus-visible, input:focus-visible { outline: 4px solid var(--gold); outline-offset: 3px; }
.btn-big { font-size: 1.1rem; width: 100%; }
.btn-huge { font-size: 1.25rem; padding: 1em 1.6em; }
.btn-green { background: var(--green); color: #fff; box-shadow: 0 5px 0 var(--green-dark); }
.btn-green:hover { background: #22914a; }
.btn-red { background: var(--red); color: #fff; box-shadow: 0 5px 0 var(--red-dark); }
.btn-gold { background: var(--gold); color: var(--red-dark); box-shadow: 0 6px 0 var(--gold-dark); }
.btn-gold:hover { background: #ffc94d; }
.btn-ghost { background: transparent; color: var(--muted); text-decoration: underline; min-height: 48px; }
.btn[disabled] { opacity: 0.6; cursor: wait; }
.btn-link {
  background: none; border: 0; padding: 0.5em; cursor: pointer; min-height: 44px;
  font: inherit; color: var(--red); text-decoration: underline; font-weight: 700;
}

/* ---------- falling snow & pepernoten ---------- */

.snow, .intro-snow { position: fixed; inset: 0; pointer-events: none; overflow: hidden; z-index: 0; }
.flake { position: absolute; top: -10vh; animation: fall linear infinite; opacity: 0.8; user-select: none; }
@keyframes fall { to { transform: translate(var(--drift, 30px), 115vh) rotate(var(--spin, 360deg)); } }

/* ---------- polaroids (used all over the page) ---------- */

.polaroid {
  background: #fff;
  padding: 7px 7px 26px;
  box-shadow: var(--shadow);
  border-radius: 4px;
  transform: rotate(var(--rot, -4deg));
  animation: sway 6s ease-in-out infinite;
  animation-delay: var(--delay, 0s);
  position: relative;
}
.polaroid img { aspect-ratio: 1; object-fit: cover; width: 100%; }
.polaroid figcaption { position: absolute; bottom: 2px; left: 0; right: 0; text-align: center; font-size: 1rem; }
.polaroid::before {
  content: ''; position: absolute; top: -10px; left: 50%; width: 56px; height: 20px;
  transform: translateX(-50%) rotate(-3deg);
  background: rgba(242, 182, 49, 0.7);
}
@keyframes sway { 50% { transform: rotate(calc(var(--rot, -4deg) * -0.6)) translateY(-5px); } }

/* ---------- intro ---------- */

.intro {
  position: fixed; inset: 0; z-index: 50;
  background: radial-gradient(circle at 50% 30%, #d61f3e 0%, var(--red) 40%, var(--red-dark) 100%);
  color: #fff;
  display: grid; place-items: center;
  text-align: center;
  transition: opacity 0.8s, transform 0.8s;
}
.intro.leaving { opacity: 0; transform: scale(1.06); pointer-events: none; }
.intro-start { position: relative; z-index: 1; padding: 24px 16px; animation: pop 0.7s cubic-bezier(.2, 1.4, .4, 1) both; }
.intro-start h1 { font-size: clamp(2.3rem, 9vw, 4.2rem); text-shadow: 0 4px 0 rgba(0, 0, 0, 0.2); color: var(--gold); }
.intro-start p { font-size: 1.2rem; margin: 0.3em 0 1.4em; }
.intro-mitre { font-size: 4.5rem; animation: bob 2.2s ease-in-out infinite; }
.intro-hint { font-size: 1rem !important; opacity: 0.85; margin-top: 1.2em !important; }

.intro-stage {
  position: relative; z-index: 1;
  width: 100vw; height: 100dvh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 18px; padding: 16px 12px 84px;
}
.scenes { position: relative; width: min(92vw, 62vh, 600px); aspect-ratio: 1; }
.scene {
  position: absolute; inset: 0;
  display: grid; place-items: center;
  opacity: 0; transform: scale(0.6) rotate(-8deg);
  transition: opacity 0.5s, transform 0.7s cubic-bezier(.2, 1.4, .4, 1);
}
.scene.on { opacity: 1; transform: none; }
.scene.off { opacity: 0; transform: scale(1.2) rotate(6deg); }
.photo-frame {
  width: 100%; aspect-ratio: 1;
  border-radius: 50%;
  padding: 10px;
  background: conic-gradient(var(--gold), #fff3c4, var(--gold), #fff3c4, var(--gold));
  box-shadow: 0 0 0 7px rgba(255, 255, 255, 0.2), 0 24px 60px rgba(0, 0, 0, 0.4);
}
.photo-frame img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.scene.on .photo-frame { animation: wiggle 1.4s ease-in-out infinite; }
.finale-photos { position: relative; width: 100%; height: 100%; }
.finale-photos .photo-frame { position: absolute; padding: 7px; }
.finale-photos .photo-frame:nth-child(1) { width: 52%; left: 0; top: 4%; }
.finale-photos .photo-frame:nth-child(2) { width: 58%; left: 21%; top: 30%; z-index: 2; }
.finale-photos .photo-frame:nth-child(3) { width: 52%; right: 0; top: 4%; }
.scene-finale.on .photo-frame:nth-child(1) { animation: jump 0.6s 0s ease-in-out infinite alternate; }
.scene-finale.on .photo-frame:nth-child(2) { animation: jump 0.6s 0.2s ease-in-out infinite alternate; }
.scene-finale.on .photo-frame:nth-child(3) { animation: jump 0.6s 0.4s ease-in-out infinite alternate; }

.lyric {
  margin: 0;
  background: rgba(60, 0, 12, 0.55);
  border-radius: 20px;
  padding: 10px 18px;
  font: 700 clamp(1.7rem, 7.5vw, 2.8rem)/1.25 'Fredoka', sans-serif;
  min-height: 1.25em;
  max-width: 94vw;
}
.word { white-space: nowrap; display: inline-block; margin: 0 0.18em; }
/* Colour only, no growing: a syllable that changes size is hard to read. */
.syl { color: rgba(255, 255, 255, 0.8); transition: color 0.1s; }
.syl.sung { color: var(--gold); text-shadow: 0 2px 0 var(--red-dark), 0 0 18px rgba(242, 182, 49, 0.6); }

.intro-end { display: flex; flex-direction: column; align-items: center; gap: 8px; animation: pop 0.5s cubic-bezier(.2, 1.4, .4, 1) both; }
.intro-end-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 4px; }
.btn-outline { background: transparent; color: #fff; border: 2px solid rgba(255, 255, 255, 0.7); }
.btn-outline:hover { background: rgba(255, 255, 255, 0.15); }

.intro-skip {
  position: absolute; z-index: 2; bottom: 16px; right: 16px;
  background: rgba(255, 255, 255, 0.15); color: #fff;
  border: 2px solid rgba(255, 255, 255, 0.5); border-radius: 999px;
  font: 700 1rem 'Nunito', sans-serif; padding: 0.7em 1.3em; min-height: 48px; cursor: pointer;
}
.intro-skip:hover { background: rgba(255, 255, 255, 0.28); }

@keyframes pop { from { opacity: 0; transform: scale(0.5); } }
@keyframes bob { 50% { transform: translateY(-12px) rotate(-6deg); } }
@keyframes wiggle { 25% { transform: rotate(-3deg) scale(1.02); } 75% { transform: rotate(3deg) scale(1.02); } }
@keyframes jump { to { transform: translateY(-22px) rotate(4deg); } }

/* ---------- page ---------- */

.page { position: relative; z-index: 1; padding: 0 16px; }
main { max-width: 980px; margin: 0 auto; }

/* ---------- hero banner: shared ---------- */

.hero {
  text-align: center;
  margin: 0 -16px;
  padding: 26px 16px 34px;
  background: linear-gradient(160deg, var(--red) 0%, var(--red-dark) 100%);
  color: #fff;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
  border-top: 8px solid var(--gold);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px;
}
.hero::after {
  content: ''; position: absolute; inset: auto 0 0; height: 12px; z-index: 4;
  background: repeating-linear-gradient(90deg, #fff 0 18px, var(--red) 18px 36px);
  opacity: 0.9;
}
.hero-text { position: relative; z-index: 3; }
.hero h1 { font-size: clamp(2.2rem, 10vw, 3.8rem); color: var(--gold); text-shadow: 0 4px 0 rgba(0, 0, 0, 0.25); }
.hero h1 span { display: inline-block; }
.hero-sub { text-wrap: balance; font-size: 1.15rem; margin: 6px 0 0; font-weight: 700; text-shadow: 0 2px 0 rgba(0, 0, 0, 0.2); }
.hero-photos { position: relative; z-index: 1; }
.hero-play {
  margin-top: 12px; min-height: 48px; padding: 0.55em 1.3em; cursor: pointer;
  font: 700 1rem 'Nunito', sans-serif; color: var(--red-dark);
  background: var(--gold); border: 0; border-radius: 999px; box-shadow: 0 4px 0 var(--gold-dark);
}
.hero-play:hover { background: #ffc94d; }
.hero-play:active { transform: translateY(2px); box-shadow: 0 2px 0 var(--gold-dark); }
.hero-photos:empty { display: none; }
.hero .polaroid { padding: 6px 6px 20px; }
.hero .polaroid::before { width: 44px; height: 16px; top: -8px; }
.wide-only { display: none !important; }

.round {
  border-radius: 50%; padding: 5px;
  background: conic-gradient(var(--gold), #fff3c4, var(--gold), #fff3c4, var(--gold));
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.35);
}

/* emoji layer */
.hero-emoji { position: absolute; inset: 0; z-index: 2; pointer-events: none; }
.hero:has(.e-garland) { padding-top: 48px; }
.e-garland { position: absolute; top: 8px; left: 0; right: 0; font-size: 1.2rem; letter-spacing: 0.15em; z-index: 3; }
.e-dot { position: absolute; transform: rotate(var(--rot)); animation: bob 3s ease-in-out infinite; animation-delay: var(--delay); opacity: 0.9; }

/* collage: a big round photo with two polaroids */
.c-wrap { position: relative; width: min(100%, 340px); height: 210px; margin: 0 auto; }
.c-main {
  position: absolute; left: 50%; top: 0; transform: translateX(-50%);
  width: 190px; aspect-ratio: 1; border-radius: 50%; padding: 7px; z-index: 2;
  background: conic-gradient(var(--gold), #fff3c4, var(--gold), #fff3c4, var(--gold));
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.35);
}
.c-main img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.c-side { position: absolute; top: 46px; width: 118px; z-index: 1; }
.c-left { left: 0; }
.c-right { right: 0; }
.hero[data-variant="collage"] .hero-photos-a { width: 100%; }

/* krans: round photos on an ellipse around the title */
.hero[data-variant="krans"] { min-height: 470px; }
.hero[data-variant="krans"] .hero-photos-a { position: absolute; inset: 0; }
.k-photo {
  --s: 78px;
  position: absolute; width: var(--s); height: var(--s);
  margin: calc(var(--s) / -2) 0 0 calc(var(--s) / -2);
  border-radius: 50%; padding: 4px;
  background: conic-gradient(var(--gold), #fff3c4, var(--gold), #fff3c4, var(--gold));
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
  animation: float 4.5s ease-in-out infinite; animation-delay: var(--delay);
}
.k-photo img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
@keyframes float { 50% { transform: translateY(-7px) rotate(3deg); } }
.hero[data-variant="krans"] h1 span { display: block; }

/* muur: rows of polaroids above and below the title */
.hero[data-variant="muur"] { padding: 22px 0 34px; gap: 6px; }
.hero[data-variant="muur"] .hero-photos { display: flex; justify-content: center; width: 112%; }
.hero[data-variant="muur"] .polaroid { width: clamp(84px, 25vw, 170px); margin: 0 -5px; flex: none; }
.hero[data-variant="muur"] .hero-photos-b .polaroid { margin-top: 6px; }

/* film: two strips of polaroids sliding past */
.hero[data-variant="film"] { padding: 18px 0 30px; }
.hero[data-variant="film"] .hero-photos { width: 100%; overflow: hidden; }
.f-track { display: flex; gap: 14px; width: max-content; padding: 12px 0 6px; animation: slide 45s linear infinite; }
.hero-photos-a .f-track { animation-direction: reverse; }
.f-track .polaroid { width: 118px; flex: none; animation: none; }
@keyframes slide { to { transform: translateX(-50%); } }

/* portret: one big photo filling the banner, title on top */
.hero[data-variant="portret"] { min-height: 540px; justify-content: flex-end; padding-bottom: 40px; }
.hero[data-variant="portret"] .hero-photos-a { position: absolute; inset: 0; }
.p-bg { position: absolute; inset: 0; }
.p-bg img { width: 100%; height: 100%; object-fit: cover; }
.p-bg::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(125, 10, 31, 0) 30%, rgba(125, 10, 31, 0.92) 78%); }
.p-small { position: absolute; width: 96px; top: 18px; }
.p-a { left: 14px; }
.p-b { right: 14px; top: 40px; }

/* ---------- how-to ---------- */

.howto {
  background: var(--paper);
  border-radius: var(--radius);
  padding: 0 16px 20px;
  margin: 56px 0 18px;
  box-shadow: var(--shadow);
  border: 3px dashed var(--gold);
  position: relative;
}
.howto-photo { width: min(64%, 250px); margin: -40px auto 14px; }
.howto h2 { font-size: 1.5rem; color: var(--red); margin-bottom: 14px; }
.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 16px; }
.steps li { display: flex; gap: 14px; align-items: center; font-size: 1.05rem; }
.step-nr {
  flex: 0 0 42px; height: 42px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--red); color: #fff; font: 700 1.25rem/1 'Fredoka', sans-serif;
}
.howto-tip { background: #fff4cf; border-left: 6px solid var(--gold); padding: 12px 14px; border-radius: 12px; margin: 18px 0 8px; font-size: 1.05rem; }
.howto-small { color: var(--muted); font-size: 0.92rem; margin: 6px 0 0; }

/* ---------- progress ---------- */

.progress { margin: 26px 0 22px; text-align: center; }
.progress p { font: 600 1.2rem 'Fredoka', sans-serif; margin: 0 0 12px; color: var(--green-dark); }
.progress-track { height: 22px; background: #f3e4cf; border-radius: 999px; position: relative; }
.progress-fill {
  height: 100%; width: 0; min-width: 22px; border-radius: 999px; position: relative;
  background: repeating-linear-gradient(45deg, var(--red) 0 14px, #fff 14px 28px);
  transition: width 0.9s cubic-bezier(.2, 1.2, .4, 1);
}
.sleigh { position: absolute; right: -16px; top: -16px; font-size: 1.9rem; transform: scaleX(-1); }

/* ---------- gift cards ---------- */

.gifts { display: grid; grid-template-columns: minmax(0, 1fr); gap: 22px; margin-bottom: 40px; }
.loading { text-align: center; font-size: 1.2rem; grid-column: 1 / -1; }

.gift {
  background: var(--paper);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  display: flex; flex-direction: column;
  position: relative;
  border: 3px solid transparent;
}
.gift.flash { animation: flash 1.4s ease-out; }
@keyframes flash { 0% { transform: scale(1.04); border-color: var(--gold); } 100% { transform: none; } }

.gift-img { background: #fff; aspect-ratio: 4 / 3; display: grid; place-items: center; padding: 14px; border-bottom: 2px solid var(--line); position: relative; }
.gift-img img { max-height: 100%; object-fit: contain; transition: filter 0.3s, opacity 0.3s; }
.gift-body { padding: 18px 16px 20px; display: flex; flex-direction: column; gap: 12px; flex: 1; }
.gift-brand { color: var(--muted); font-size: 0.85rem; text-transform: uppercase; letter-spacing: 0.08em; font-weight: 800; }
.gift h3 { font-size: 1.4rem; color: var(--red-dark); }
.gift-why { background: #fdf1f3; border-radius: 14px; padding: 12px 14px; margin: 0; font-size: 0.98rem; }
.gift-why strong { display: block; color: var(--red); font-family: 'Fredoka', sans-serif; font-weight: 600; margin-bottom: 2px; }
.shops-note { margin: -2px 0 8px; font-size: 0.82rem; color: var(--muted); }

.shops h4 { margin: 4px 0 6px; font: 600 1.05rem 'Fredoka', sans-serif; }
.shops ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.shop {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 2px 10px;
  padding: 10px 12px; border: 2px solid var(--line); border-radius: 14px;
  text-decoration: none; color: inherit; background: #fffdf9; min-height: 56px;
}
.shop:hover { border-color: var(--gold); background: #fff8e6; }
.shop-name { font-weight: 800; }
.shop-note { grid-column: 1 / -1; font-size: 0.8rem; color: var(--muted); font-weight: 400; line-height: 1.35; }
.shop-right { display: flex; align-items: center; gap: 8px; white-space: nowrap; }
.shop-price { font-weight: 800; font-size: 1.05rem; }
.shop-go { color: var(--red); font-weight: 800; }

.secondhand { background: #eef6ff; border: 2px dashed #6aa6e8; border-radius: 14px; padding: 12px 14px; font-size: 0.95rem; }
.secondhand strong { color: #1d5fa8; }
.secondhand-links { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.secondhand-links a {
  background: #fff; border: 2px solid #6aa6e8; border-radius: 999px; padding: 8px 14px;
  color: #1d5fa8; font-weight: 800; text-decoration: none; min-height: 44px; display: inline-flex; align-items: center;
}

.gift-action { margin-top: auto; padding-top: 6px; }

.gift.taken .gift-img img { filter: grayscale(0.85); opacity: 0.55; }
.ribbon {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%) rotate(-6deg);
  background: var(--red); color: #fff; font: 700 1.15rem 'Fredoka', sans-serif;
  padding: 12px 20px; border-radius: 12px; box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
  text-align: center; max-width: 88%; border: 3px solid var(--gold);
}
.gift.mine .ribbon { background: var(--green); }
.taken-box { background: #f6efe6; border-radius: 14px; padding: 14px 16px; text-align: center; }
.taken-box p { margin: 0 0 4px; }
.gift.mine .taken-box { background: #effaf2; border: 2px solid var(--green); }

/* photos scattered between the gifts */
.photo-break {
  grid-column: 1 / -1;
  display: flex; justify-content: center; align-items: center; gap: 6px;
  padding: 14px 0 8px;
}
.photo-break .polaroid { width: 44%; max-width: 210px; }
.photo-heart { color: var(--red); font-size: 1.6rem; animation: bob 1.8s ease-in-out infinite; }

/* ---------- extras: piggy bank, JBC, poem ---------- */

.extras { margin: 16px 0 30px; }
.extras h2 { font-size: 1.7rem; color: var(--red); text-align: center; }
.extras-sub { text-align: center; color: var(--muted); margin: 6px 0 22px; }
.extras-cards { display: grid; gap: 22px; }
.extra {
  display: flex; flex-direction: column; align-items: center; text-align: center; gap: 12px;
  background: var(--paper); border-radius: var(--radius); box-shadow: var(--shadow);
  padding: 22px 16px; border: 3px solid transparent; position: relative;
}
.extra-piggy { border-color: #f7b6c8; background: linear-gradient(135deg, #fff 60%, #ffe8ef); }
.extra-jbc { border-color: #a9dcb8; background: linear-gradient(135deg, #fff 60%, #e7f7ec); }
.extra-photo { position: absolute; top: -16px; left: 10px; width: 78px; padding: 5px 5px 14px; }
.extra-photo::before { width: 40px; height: 14px; top: -7px; }
.extra-icon { font-size: 3.4rem; line-height: 1; animation: bob 2.6s ease-in-out infinite; }
.extra-jbc .extra-icon { animation-delay: -1.3s; }
.extra-body { display: flex; flex-direction: column; gap: 10px; align-items: center; width: 100%; }
.extra-body p { margin: 0; }
.extra h3 { font-size: 1.4rem; color: var(--red-dark); }
.extra-small { font-size: 0.92rem; color: var(--muted); }
.iban {
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  background: #fff; border: 2px dashed #f08aa7; border-radius: 14px; padding: 12px 14px; width: 100%;
}
.iban-label { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.08em; font-weight: 800; color: var(--muted); }
.iban-nr { font: 700 1.3rem 'Fredoka', monospace; letter-spacing: 0.03em; user-select: all; }
.iban .btn { min-height: 48px; padding: 0.6em 1.2em; }

.poem-photo { width: 150px; margin: 40px auto -26px; z-index: 2; }
.poem {
  margin: 0 auto; max-width: 620px; text-align: center;
  background: #fff4cf; border-radius: var(--radius); padding: 40px 18px 18px;
  font: 500 1.05rem/1.7 'Fredoka', sans-serif; color: var(--red-dark);
  transform: rotate(-1deg); box-shadow: var(--shadow);
}
.poem p { margin: 0; }
.poem footer { margin-top: 8px; font: 700 1rem 'Nunito', sans-serif; color: var(--muted); }
.poem footer::before { content: '— '; }

/* ---------- dialogs ---------- */

.dialog {
  border: 0; border-radius: var(--radius); padding: 0;
  width: min(94vw, 500px); max-height: 92vh;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.4); color: var(--ink);
  overflow-y: auto;
}
@media (max-height: 760px) {
  .dialog-img, .dialog-img img { height: 76px; max-height: 76px; }
}
.dialog::backdrop { background: rgba(60, 10, 20, 0.6); backdrop-filter: blur(3px); }
.dialog form, .dialog-body { padding: 22px 18px 18px; display: flex; flex-direction: column; gap: 12px; }
.dialog-body p { margin: 0; font-size: 1.05rem; }
.dialog h2 { font-size: 1.4rem; color: var(--red-dark); }
.dialog-img { height: 110px; display: grid; place-items: center; }
.dialog-img img { max-height: 110px; object-fit: contain; }
.dialog label { font-weight: 800; font-size: 1.1rem; }
.dialog input { font: 600 1.25rem 'Nunito', sans-serif; padding: 14px 16px; border-radius: 14px; border: 3px solid var(--line); width: 100%; }
.dialog input:focus { border-color: var(--gold); outline: none; }
.warn { background: #fff4cf; border-left: 6px solid var(--gold); padding: 12px 14px; border-radius: 12px; margin: 0; }
.error { background: #fde5e8; color: var(--red-dark); padding: 10px 14px; border-radius: 12px; margin: 0; font-weight: 700; }
.dialog-actions { display: flex; flex-direction: column; gap: 6px; margin-top: 6px; }

/* ---------- toasts & confetti ---------- */

.toasts { position: fixed; z-index: 60; bottom: 16px; left: 50%; transform: translateX(-50%); display: grid; gap: 10px; width: min(92vw, 460px); }
.toast {
  background: var(--ink); color: #fff; padding: 14px 18px; border-radius: 16px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3); font-weight: 700;
  animation: toastIn 0.4s cubic-bezier(.2, 1.4, .4, 1) both;
}
.toast.out { animation: toastOut 0.4s forwards; }
@keyframes toastIn { from { opacity: 0; transform: translateY(30px) scale(0.9); } }
@keyframes toastOut { to { opacity: 0; transform: translateY(20px); } }

.confetti { position: fixed; z-index: 70; pointer-events: none; font-size: 1.6rem; animation: burst 1.6s cubic-bezier(.1, .8, .3, 1) forwards; }
@keyframes burst {
  0% { transform: translate(0, 0) rotate(0); opacity: 1; }
  100% { transform: translate(var(--dx), var(--dy)) rotate(var(--rot)); opacity: 0; }
}

.footer { text-align: center; padding: 10px 0 60px; color: var(--muted); }

/* ---------- design bar (only with ?design) ---------- */

.design-bar {
  position: fixed; z-index: 40; left: 50%; bottom: 10px; transform: translateX(-50%);
  width: max-content; max-width: calc(100vw - 16px);
  display: flex; gap: 10px; align-items: center; overflow-x: auto;
  background: rgba(255, 255, 255, 0.96); border-radius: 18px; padding: 8px 10px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25); font-size: 0.78rem;
}
.d-group { display: flex; align-items: center; gap: 4px; flex: none; }
.d-label { font-weight: 800; color: var(--muted); margin-right: 2px; }
.design-bar button {
  font: 700 0.78rem 'Nunito', sans-serif; border: 2px solid var(--line); background: #fff;
  border-radius: 999px; padding: 6px 10px; cursor: pointer; white-space: nowrap;
}
.design-bar button.on { background: var(--red); border-color: var(--red); color: #fff; }
.has-design-bar .toasts { bottom: 74px; }
.has-design-bar .footer { padding-bottom: 110px; }

/* ---------- tablet and up ---------- */

@media (min-width: 700px) {
  html { font-size: 19px; }
  .page { padding: 0 24px; }
  .hero { margin: 0; border-radius: 0 0 var(--radius) var(--radius); padding: 30px 28px 38px; }
  .c-wrap { width: 460px; height: 270px; }
  .c-main { width: 240px; }
  .c-side { width: 150px; top: 60px; }
  .hero[data-variant="krans"] { min-height: 540px; }
  .k-photo { --s: 118px; }
  .hero[data-variant="muur"] .hero-photos { width: 104%; }
  .f-track .polaroid { width: 160px; }
  .hero[data-variant="portret"] { min-height: 620px; }
  .p-small { width: 140px; }
  .howto { display: grid; grid-template-columns: 1fr 240px; gap: 8px 28px; padding: 26px 28px 24px; margin-top: 30px; }
  .howto-photo { order: 2; width: 100%; margin: -10px -10px 0 0; align-self: start; }
  .howto h2 { font-size: 1.7rem; }
  .step-nr { flex-basis: 46px; height: 46px; }
  .gifts { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 26px; }
  .gift-body { padding: 20px 22px 22px; }
  .photo-break { gap: 26px; padding: 18px 0 10px; }
  .photo-break .polaroid { width: 200px; }
  .extras-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .extra-photo { width: 92px; }
  .poem { font-size: 1.15rem; padding: 44px 26px 22px; }
  .poem-photo { width: 180px; }
}

/* ---------- desktop ---------- */

@media (min-width: 1000px) {
  .wide-only { display: block !important; }
  .hero[data-variant="collage"] { flex-direction: row-reverse; justify-content: space-between; text-align: left; padding: 36px 48px 46px; }
  .hero[data-variant="collage"] .hero-photos-a { width: auto; }
  .hero[data-variant="krans"] { min-height: 560px; }
  .k-photo { --s: 128px; }
  .howto { grid-template-columns: 1fr 300px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  .snow, .intro-snow { display: none; }
}
.taken-name { font-size: 0.92rem; color: var(--muted); }
