/*
 * Страница приглашения: «от руки» - бумага, чернила цвета дресс-кода, рукописный шрифт Caveat,
 * рисунки-каракули (php/art.php). Админка использует style.css.
 * Шрифт Caveat - SIL Open Font License 1.1 (public/fonts/OFL-Caveat.txt).
 */
@font-face {
  font-family: 'Caveat';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url(/static/fonts/caveat-cyrillic.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Caveat';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url(/static/fonts/caveat-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;
}

:root {
  /* палитра по умолчанию; на приглашении переопределяется цветами дресс-кода (themeStyle) */
  --wine: #6b1e2e;
  --mocha: #5a3e36;
  --navy: #1e2a44;
  --dusty-blue: #8fa7bf;

  --ink: var(--wine);
  --ink-soft: rgba(107, 30, 46, .35);
  --ink-soft: color-mix(in srgb, var(--ink) 35%, transparent);
  --ink-faint: rgba(107, 30, 46, .08);
  --ink-faint: color-mix(in srgb, var(--ink) 8%, transparent);
  --paper: #f3eee4; /* совпадает с фоном фото жениха и невесты */
  --text: #3a2a27;
  --muted: #76625b;
  --error: #b3261e;
  --hand: 'Caveat', 'Segoe Print', 'Comic Sans MS', cursive;
  /* «нарисованная от руки» рамка */
  --hand-radius: 255px 15px 225px 15px / 15px 225px 15px 255px;
  --ease: cubic-bezier(.28, .11, .32, 1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body.paper {
  margin: 0;
  color: var(--text);
  font-family: var(--hand);
  font-size: 22px;
  line-height: 1.3;
  background-color: var(--paper);
  /* лёгкая фактура бумаги */
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .35 0 0 0 0 .3 0 0 0 0 .25 0 0 0 .1 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  overflow-x: hidden;
}

.svg-defs { position: absolute; width: 0; height: 0; }
a { color: var(--ink); }
p { margin: 0 0 .4em; }

/* чернила с фактурой мелка */
.ink { color: var(--ink); filter: url(#crayon); }
.hand { font-family: var(--hand); }
.title { font-weight: 700; font-size: clamp(46px, 12vw, 66px); line-height: 1; text-align: center; margin: 0 0 18px; }
.lead { font-size: 25px; color: var(--ink); text-align: center; max-width: 30ch; margin: 0 auto 8px; line-height: 1.2; }
.note { font-size: 22px; color: var(--muted); margin: 0 0 6px; }
.doodle { display: block; overflow: visible; color: var(--ink); }

/* ---------- обложка ---------- */
.cover { position: relative; max-width: 560px; margin: 0 auto; padding: 14px 16px 36px; text-align: center; overflow-x: clip; }
.bunting { width: 100%; height: auto; }
.flag { transform-box: fill-box; transform-origin: 50% 0; }
.flag-letter { font-family: var(--hand); font-size: 21px; font-weight: 700; fill: currentColor; stroke: none; }

.names { margin: 6px 0 0; font-weight: 700; font-size: clamp(76px, 22vw, 124px); line-height: .88; }
.names span { display: block; }
.names span:first-child { padding-right: 12%; }
.names span:last-child { padding-left: 14%; }

.roles { display: grid; grid-template-columns: 1fr auto 1fr; align-items: start; margin-top: 18px; }
.role { display: flex; flex-direction: column; align-items: center; color: var(--ink); }
.role .hand { font-size: 28px; letter-spacing: .12em; }
.role-groom { transform: rotate(-9deg); }
.role-bride { transform: rotate(8deg); }
.role .arrow { width: 50px; margin-top: 2px; }
.heart-mid { width: 30px; margin-top: 24px; }

.cover-photo { margin: -6px auto 0; max-width: 480px; }
.cover-photo img { display: block; width: 100%; height: auto; max-height: 70vh; object-fit: contain; }
.cover-hearts { display: flex; justify-content: center; align-items: flex-end; gap: 10px; padding: 18px 0 8px; }
.cover-hearts .h1 { width: 46px; transform: rotate(-12deg); }
.cover-hearts .h2 { width: 86px; }
.cover-hearts .h3 { width: 40px; transform: rotate(14deg); }

.cover .float { position: absolute; width: 30px; }
.cover .f1 { right: 6%; top: 57%; }
.cover .f2 { left: 5%; top: 66%; width: 24px; }

.date-badge { position: relative; width: min(430px, 96%); margin: -10px auto 0; color: var(--ink); }
.date-badge .brush { width: 100%; height: auto; }
.date-badge span {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: clamp(28px, 8vw, 38px);
  font-weight: 700;
}

/* портреты жениха и невесты рядом, чуть внахлёст, под стрелками «жених» / «невеста».
   Края растушёваны, чтобы фон фото сливался с бумагой. */
.cover-pair { display: flex; justify-content: center; align-items: flex-start; margin-top: -4px; }
.pair-photo { margin: 0 -2%; width: 52%; position: relative; }
.pair-groom { transform: rotate(-2deg); z-index: 1; }
.pair-bride { transform: rotate(2deg); margin-top: 14px; }
.cover-pair.single .pair-photo { width: 78%; transform: none; margin-top: 0; }
.pair-photo img {
  display: block;
  width: 100%;
  height: auto;
  -webkit-mask-image: linear-gradient(to right, transparent, #000 8%, #000 92%, transparent), linear-gradient(to bottom, transparent, #000 5%, #000 94%, transparent);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(to right, transparent, #000 8%, #000 92%, transparent), linear-gradient(to bottom, transparent, #000 5%, #000 94%, transparent);
  mask-composite: intersect;
}

/* ---------- блоки ---------- */
.block { position: relative; max-width: 560px; margin: 0 auto; padding: 52px 20px; text-align: center; }

.invited { margin-top: 26px; }
.invited-list { list-style: none; padding: 0; margin: 4px 0 8px; }
.invited-list li { font-size: 32px; font-weight: 700; color: var(--text); line-height: 1.15; }

/* дата «когда» */
.vline { display: block; width: 2px; height: 96px; margin: 0 auto; background: var(--ink); border-radius: 2px; filter: url(#rough); }
.big-date { position: relative; display: flex; flex-direction: column; align-items: center; font-weight: 700; font-size: clamp(96px, 30vw, 150px); line-height: .92; padding: 14px 0; }
.big-date i { font-style: normal; font-size: .35em; line-height: .5; }
.when-note { position: absolute; right: -4px; top: 8px; display: flex; align-items: center; gap: 2px; font-size: 26px; font-weight: 400; transform: rotate(-8deg); filter: none; }
.when-note .pointer { width: 40px; }
.when .side { position: absolute; width: 32px; }
.when .side-left { left: 10%; top: 120px; transform: rotate(-14deg); }
.when .side-right { right: 14%; top: 470px; transform: rotate(12deg); }
.month { margin-top: 22px; }

.calendar { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px 2px; max-width: 380px; margin: 0 auto; color: var(--ink); font-size: 25px; }
.cal-head { font-size: 19px; opacity: .75; text-transform: uppercase; letter-spacing: .04em; }
.cal-day { position: relative; line-height: 1.5; }
.cal-day.is-wedding { font-weight: 700; }
.cal-day .circle-heart { position: absolute; left: 50%; top: 50%; width: 54px; translate: -50% -52%; pointer-events: none; }

/* таймер в рисованной рамке */
.frame { position: relative; padding: 34px 18px 38px; }
.frame::before { content: ''; position: absolute; inset: 0; border: 2.5px solid var(--ink); filter: url(#rough); pointer-events: none; }
.countdown { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin-top: 18px; color: var(--ink); }
.countdown div { display: flex; flex-direction: column; align-items: center; }
.countdown b { font-size: clamp(38px, 11vw, 52px); font-weight: 400; line-height: 1; font-variant-numeric: tabular-nums; }
.countdown span { font-size: 21px; color: var(--ink); }

/* место */
.venue-name { font-size: 32px; font-weight: 700; color: var(--ink); margin-bottom: 2px; }
.venue-address { font-size: 25px; color: var(--ink); }
.polaroid-wrap { position: relative; max-width: 300px; margin: 30px auto 8px; }
.block > .polaroid { max-width: 280px; margin: 10px auto 26px; }
.polaroid.tilt-left { transform: rotate(-2deg); }
.polaroid.tilt-right { transform: rotate(1.5deg); }
.polaroid { margin: 0; padding: 14px 14px 58px; background: #eef0ee; box-shadow: 0 6px 20px rgba(60, 40, 30, .14); transform: rotate(-1.5deg); }
.polaroid img { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; }
.where-note { position: absolute; left: -30px; bottom: -58px; display: flex; flex-direction: column; align-items: flex-start; color: var(--ink); font-size: 28px; transform: rotate(-6deg); }
.where-note .arrow { width: 44px; margin-left: -8px; }

.brush-btn { position: relative; display: block; width: min(360px, 90%); margin: 64px auto 0; color: var(--ink); text-decoration: none; transition: transform .2s var(--ease); }
.brush-btn:hover { transform: rotate(-1deg) scale(1.02); }
.brush-btn .brush { width: 100%; height: auto; }
.brush-btn span { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: #fff; font-size: 34px; font-weight: 700; }
.link-btn { display: inline-block; margin-top: 10px; background: none; border: 0; padding: 4px 8px; color: var(--muted); font-size: 22px; text-decoration: underline dashed; text-underline-offset: 4px; cursor: pointer; }
.link-btn:hover { color: var(--ink); }

/* программа (тайминг) - по центру, время крупно, название под ним */
.schedule { list-style: none; padding: 0; margin: 0 auto; max-width: 420px; }
.schedule li { position: relative; padding: 18px 0 26px; }
.schedule .time { display: block; font-size: 52px; font-weight: 700; line-height: 1; }
.schedule strong { display: block; font-size: 27px; font-weight: 400; color: var(--ink); line-height: 1.1; margin-top: 4px; }
.schedule p { font-size: 22px; color: var(--muted); margin: 2px 0 0; }
.schedule .side-heart { position: absolute; top: 30%; width: 30px; }
.schedule .side-heart.right { right: 0; transform: rotate(12deg); }
.schedule .side-heart.left { left: 0; transform: rotate(-12deg); }

/* дресс-код: кружки внахлёст, коллажи образов */
.swatch-row { display: flex; justify-content: center; margin-top: 22px; }
.swatch { display: block; width: 60px; height: 60px; border-radius: 50%; margin-left: -12px; border: 2px solid var(--paper); box-shadow: 0 0 0 1.5px var(--ink-soft); }
.swatch:first-child { margin-left: 0; }
.swatch-names { font-size: 21px; color: var(--muted); margin-top: 10px; }

.collage-block { margin-top: 44px; }
.collage-title { font-size: 54px; font-weight: 700; margin: 0 0 14px; }
.collage { display: flex; flex-wrap: wrap; justify-content: center; align-items: flex-start; padding: 0 4px 12px; }
.collage figure { margin: 0 -3% -6%; width: 46%; position: relative; z-index: 1; }
.collage figure:nth-child(3n + 1) { transform: translateY(18px) rotate(-2deg); z-index: 2; }
.collage figure:nth-child(3n + 2) { width: 52%; transform: rotate(1.5deg); z-index: 3; }
.collage figure:nth-child(3n) { width: 40%; transform: translateY(-14px) rotate(2.5deg); }
.collage figure:only-child { width: 70%; transform: none; }
.collage .outfit { display: block; width: 100%; height: auto; box-shadow: 0 4px 14px rgba(60, 40, 30, .14); }
.collage.drawn figure { width: 44%; }
.collage.drawn figure:nth-child(3n + 2) { width: 48%; }
.collage img { display: block; width: 100%; height: auto; aspect-ratio: auto 3 / 4; background: #fff; box-shadow: 0 4px 14px rgba(60, 40, 30, .14); }

/* пожелания - слайдер со стрелками */
.notes-slider { display: grid; grid-template-columns: 52px 1fr 52px; align-items: center; gap: 4px; margin: 0 -14px; }
.notes-slider.single { grid-template-columns: 1fr; }
.notes-slider.single .slider-arrow { display: none; }
.notes-track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  overscroll-behavior-x: contain;
}
.notes-track::-webkit-scrollbar { display: none; }
.notes-track:focus-visible { outline: 2px dashed var(--ink); outline-offset: 4px; }
.note-slide { flex: 0 0 100%; scroll-snap-align: center; margin: 0; padding: 0 6px; font-size: 25px; line-height: 1.25; color: var(--ink); }
.slider-arrow { width: 52px; height: 44px; padding: 4px; border: 0; background: none; color: var(--ink); cursor: pointer; transition: opacity .2s; }
.slider-arrow .long-arrow { width: 100%; height: 100%; }
.slider-arrow:disabled { opacity: .25; cursor: default; }
.notes .brush-btn { margin-top: 44px; }

/* ---------- кнопки и форма ---------- */
.btn {
  display: inline-block;
  font-family: var(--hand);
  font-size: 25px;
  font-weight: 700;
  line-height: 1.1;
  color: #fff;
  background: var(--ink);
  border: 2px solid var(--ink);
  border-radius: var(--hand-radius);
  padding: 9px 26px 11px;
  cursor: pointer;
  text-decoration: none;
  transition: transform .15s var(--ease), box-shadow .15s var(--ease);
}
.btn:hover { transform: rotate(-1deg) scale(1.02); }
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .5; cursor: default; }
.btn-ghost { background: transparent; color: var(--ink); }
.btn-large { display: block; width: 100%; font-size: 32px; padding: 12px 20px 14px; margin-top: 8px; }
.btn:focus-visible, a:focus-visible { outline: 2px dashed var(--ink); outline-offset: 4px; }

fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
.person { padding: 0 0 22px; margin-bottom: 22px; border-bottom: 2px dashed var(--ink-soft); }
.person legend { float: left; width: 100%; padding: 0; margin-bottom: 8px; font-size: 32px; font-weight: 700; color: var(--ink); }
.person legend + * { clear: both; }
.plus-one { border-bottom: 0; }

.choice { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.pill { display: inline-flex; align-items: center; cursor: pointer; }
.pill input { position: absolute; opacity: 0; pointer-events: none; }
.pill span { position: relative; display: inline-flex; align-items: center; gap: 12px; font-size: 25px; color: var(--ink); padding: 2px 0; }
/* кружок для «Да / Не смогу», квадратик для напитков - нарисованы от руки */
.pill span::before {
  content: '';
  flex: none;
  width: 22px;
  height: 22px;
  border: 2px solid var(--ink);
  border-radius: 50%;
  background: transparent;
  box-shadow: inset 0 0 0 4px var(--paper);
  transition: background .15s;
}
.pill input[type="checkbox"] + span::before { border-radius: 3px 5px 4px 6px; }
.pill input:checked + span::before { background: var(--ink); }
.pill input:focus-visible + span { outline: 2px dashed var(--ink); outline-offset: 3px; }

.drinks-block, .plus-fields { margin-top: 16px; }
.drinks { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }

.field { display: block; margin: 0 0 14px; }
.field > span, .field-title { display: block; font-size: 24px; color: var(--ink); margin: 0 0 6px; }
input[type="text"] {
  width: 100%;
  font-family: var(--hand);
  font-size: 24px;
  color: var(--text);
  padding: 8px 14px 10px;
  border: 2px solid var(--ink);
  border-radius: 2px;
  background: transparent;
}
input[type="text"]::placeholder { color: var(--ink-soft); }
input[type="text"]:focus { outline: none; border-color: var(--ink); box-shadow: 0 0 0 4px var(--ink-faint); }

.error { color: var(--error); font-size: 23px; margin: 0 0 10px; text-align: center; }

.done {
  position: relative;
  margin-top: 22px;
  padding: 26px 20px;
  background: rgba(255, 255, 255, .6);
  border: 2px solid var(--ink-soft);
  border-radius: var(--hand-radius);
}
.done-title { font-size: 38px; font-weight: 700; line-height: 1.05; margin-bottom: 12px; }
.done-lead { font-size: 23px; color: var(--muted); max-width: 30ch; margin: 0 auto 12px; }
#done-summary p { font-size: 23px; }
.done .btn { margin-top: 12px; }
.done[data-state="none"] .done-title { color: var(--muted); }

/* салют из сердечек после отправки (invite.js) */
.burst { position: absolute; left: 50%; top: 40px; pointer-events: none; }
.burst span { position: absolute; left: 0; top: 0; font-size: 22px; line-height: 1; color: var(--ink); animation: burst 1.3s var(--ease) forwards; }
.burst .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--dusty-blue); }
@keyframes burst {
  from { transform: translate(-50%, -50%) scale(.3); opacity: 1; }
  70% { opacity: 1; }
  to { transform: translate(calc(var(--x) - 50%), calc(var(--y) - 50%)) rotate(var(--r)) scale(1); opacity: 0; }
}

/* контакты */
.contacts { display: flex; flex-direction: column; gap: 16px; align-items: center; }
.contact { display: flex; flex-direction: column; align-items: center; text-decoration: none; }
.contact-name { font-size: 24px; color: var(--muted); }
.contact-phone { font-size: 40px; font-weight: 700; line-height: 1.05; }

.footer { text-align: center; padding: 20px 20px 50px; font-size: 22px; color: var(--muted); display: flex; justify-content: center; align-items: center; gap: 6px; }
.footer .tiny { width: 18px; }

[hidden] { display: none !important; }

/* страницы-сообщения */
body.centered { min-height: 100vh; display: flex; align-items: center; justify-content: center; }
.message { max-width: 480px; padding: 22px; text-align: center; }
.message .heart { width: 44px; margin: 16px auto 0; }

/* ---------- анимации ---------- */
.doodle [pathLength] { stroke-dasharray: 1; stroke-dashoffset: 0; }

@keyframes draw { from { stroke-dashoffset: 1; } to { stroke-dashoffset: 0; } }
@keyframes rise { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
@keyframes sway { from { rotate: -3deg; } to { rotate: 3deg; } }
@keyframes beat { 0%, 100% { scale: 1; } 30% { scale: 1.18; } 60% { scale: .96; } }
@keyframes bob { 0%, 100% { translate: 0 0; } 50% { translate: 0 -6px; } }
@keyframes brush-in { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }

@media (prefers-reduced-motion: no-preference) {
  /* обложка: всё рисуется при загрузке */
  .cover .doodle [pathLength] { animation: draw 1.4s var(--ease) both; animation-delay: calc(var(--d, 0) * 1s); }
  .flag { animation: sway 2.8s ease-in-out infinite alternate; animation-delay: calc(var(--i) * -.35s); }
  .flag-letter { animation: rise .6s var(--ease) both; animation-delay: calc(var(--i) * .07s + .5s); }
  .names span { animation: rise 1s var(--ease) both; }
  .cover-pair { animation: rise 1.1s 1.7s var(--ease) both; }
  .names span:first-child { animation-delay: .9s; }
  .names span:last-child { animation-delay: 1.15s; }
  .roles { animation: rise 1s 1.4s var(--ease) both; }
  .cover-photo { animation: rise 1.1s 1.7s var(--ease) both; }
  .date-badge .brush { animation: brush-in .9s 2s var(--ease) both; }
  .date-badge span { animation: rise .8s 2.5s var(--ease) both; }
  .beat { animation: beat 1.6s 3s ease-in-out infinite; }
  .cover .float { animation: bob 5s ease-in-out infinite; }
  .cover .f2 { animation-delay: -2s; }

  /* блоки проявляются при прокрутке (класс reveal-ready ставит invite.js) */
  .reveal-ready .reveal { opacity: 0; transform: translateY(34px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
  .reveal-ready .reveal.is-visible { opacity: 1; transform: none; }
  .reveal-ready .reveal .doodle [pathLength] { stroke-dashoffset: 1; transition: stroke-dashoffset 1.3s var(--ease) calc(var(--d, 0) * 1s + .3s); }
  .reveal-ready .reveal.is-visible .doodle [pathLength] { stroke-dashoffset: 0; }
  .reveal-ready .reveal .vline { transform: scaleY(0); transform-origin: top; transition: transform 1s var(--ease) .2s; }
  .reveal-ready .reveal.is-visible .vline { transform: none; }
  .reveal-ready .reveal .big-date span, .reveal-ready .reveal .big-date i { opacity: 0; transition: opacity .7s ease; }
  .reveal-ready .reveal.is-visible .big-date span, .reveal-ready .reveal.is-visible .big-date i { opacity: 1; }
  .reveal-ready .reveal.is-visible .big-date > :nth-child(1) { transition-delay: .5s; }
  .reveal-ready .reveal.is-visible .big-date > :nth-child(2) { transition-delay: .7s; }
  .reveal-ready .reveal.is-visible .big-date > :nth-child(3) { transition-delay: .9s; }
  .reveal-ready .reveal.is-visible .big-date > :nth-child(4) { transition-delay: 1.1s; }
  .reveal-ready .reveal.is-visible .big-date > :nth-child(5) { transition-delay: 1.3s; }
  .reveal-ready .reveal.is-visible .big-date > .when-note { transition-delay: 1.6s; }
  .reveal-ready .reveal .schedule li, .reveal-ready .reveal .swatch {
    opacity: 0;
    transform: translateY(12px);
    transition: opacity .6s var(--ease), transform .6s var(--ease);
    transition-delay: calc(var(--i, 0) * 100ms + .25s);
  }
  .reveal-ready .reveal.is-visible .schedule li, .reveal-ready .reveal.is-visible .swatch { opacity: 1; transform: none; }
  /* у фото коллажа свой наклон - проявляем только прозрачностью */
  .reveal-ready .reveal .collage figure { opacity: 0; transition: opacity .8s var(--ease) calc(var(--i, 0) * 120ms + .2s); }
  .reveal-ready .reveal.is-visible .collage figure { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .burst { display: none; }
}

@media (max-width: 400px) {
  .when-note { right: -8px; font-size: 22px; }
}

/* анкета: рамка с кнопкой «Подтвердить», форма раскрывается по нажатию */
.rsvp-intro .deadline { font-size: 44px; font-weight: 700; margin: 6px 0 0; }
.rsvp-intro .brush-btn { margin-top: 26px; background: none; border: 0; padding: 0; font: inherit; cursor: pointer; }
.rsvp-intro .brush-btn[hidden] { display: none; }

/* контакты и завершение */
.contacts-block .side-heart, .final .side-heart { position: absolute; width: 34px; }
.contacts-block .side-heart.right { right: 8%; top: 180px; transform: rotate(12deg); }
.final .side-heart.left { left: 8%; top: 40px; transform: rotate(-12deg); }
.final .side-heart.right { right: 8%; bottom: 150px; transform: rotate(14deg); }
.contact-name { text-transform: uppercase; letter-spacing: .06em; font-size: 26px; color: var(--ink); }
.final-names { display: flex; flex-direction: column; align-items: center; font-size: clamp(52px, 15vw, 72px); font-weight: 700; line-height: .95; margin: 14px 0 24px; }
.final-names span:last-child { padding-left: 12%; }
.wait-note { display: inline-flex; align-items: flex-start; gap: 4px; font-size: 30px; color: var(--ink); transform: rotate(-6deg); margin-top: 6px; }
.wait-note .pointer { width: 44px; transform: rotate(40deg); }

/* анкета поверх страницы */
html.sheet-open, html.sheet-open body { overflow: hidden; }
.sheet {
  position: fixed;
  inset: 0;
  z-index: 100;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  background-color: var(--paper);
  overscroll-behavior: contain;
}
body.paper .sheet { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .35 0 0 0 0 .3 0 0 0 0 .25 0 0 0 .1 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
#rsvp-form { margin-top: 10px; }
.sheet-inner { position: relative; max-width: 560px; margin: 0 auto; padding: 56px 22px 60px; text-align: left; }
.sheet-inner > .title, .sheet-inner > .lead, .sheet-inner > .deadline { text-align: center; }
.sheet-inner > .deadline { font-size: 44px; font-weight: 700; margin: 4px 0 26px; }
.sheet-close { position: absolute; left: 14px; top: 14px; width: 44px; height: 44px; padding: 8px; border: 0; background: none; color: var(--ink); cursor: pointer; }
.sheet-close .cross { width: 100%; height: 100%; }
.submit-brush { width: 100%; margin: 26px auto 0; background: none; border: 0; padding: 0; font: inherit; cursor: pointer; }
.submit-brush:disabled { opacity: .6; cursor: default; }
.sheet .done { text-align: center; }

@media (prefers-reduced-motion: no-preference) {
  .sheet:not([hidden]) { animation: sheet-in .45s var(--ease) both; }
}
@keyframes sheet-in { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: none; } }
