/* =========================================================
   Navo — a lacquered music box painted with roses rests on blush
   silk; on the tap its lid opens, a tiny bride and groom turn,
   and rose-gold light blooms out of it, opening on a rose garden
   terrace with a turquoise fountain. Weddings.
   Built on shared/base.css; this sheet is the look.
   ========================================================= */

:root {
  --bg: #fdf4f0;
  --ink: #3e2329;
  --ink-soft: #85636a;
  --accent: #bf6878;
  --accent-deep: #8c3d51;
  --accent-soft: #f9e1e4;
  --gold: #c69c55;
  --gold-soft: #f3e3c2;
  --teal: #4f9e98;
  --line: rgba(140, 61, 81, 0.13);
  --line-strong: rgba(140, 61, 81, 0.28);
  --surface: #fffaf8;
  --on-accent: #fff8f5;
  --shadow: 140 70 80;
  --glow: rgba(255, 248, 244, 0.95);
  --intro-bg: #f2d9d2;

  --display: "Playfair", Georgia, serif;
  --body: "Cormorant Garamond", Georgia, serif;
  --label: "Montserrat", "Helvetica Neue", sans-serif;

  --open-default: url("/styles/navo/media/open-poster.jpg");
  --amb-poster: url("/styles/navo/media/amb-poster.jpg");
  --close-poster: url("/styles/navo/media/close-poster.jpg");
  --dissolve: 2s;
  --pulse: rgba(255, 246, 236, 0.95);
  --pulse-glow: rgba(214, 150, 110, 0.5);
  --glint: rgba(255, 226, 170, 0.95);

  /* a quaver, a pair of beamed notes, and a rose petal */
  --note: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 28'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='1' y2='1'%3E%3Cstop offset='0' stop-color='%23f6dc9c'/%3E%3Cstop offset='1' stop-color='%23b88638'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cellipse cx='6.5' cy='22.5' rx='5.5' ry='4' transform='rotate(-22 6.5 22.5)' fill='url(%23g)'/%3E%3Cpath d='M11 22V2c2 3 7 4 7 10-1-3-4-4-5.4-4.4V22Z' fill='url(%23g)'/%3E%3C/svg%3E");
  --notes: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 28'%3E%3Cdefs%3E%3ClinearGradient id='g' x1='0' y1='0' x2='1' y2='1'%3E%3Cstop offset='0' stop-color='%23f6dc9c'/%3E%3Cstop offset='1' stop-color='%23b88638'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cellipse cx='6' cy='23' rx='5' ry='3.7' transform='rotate(-22 6 23)' fill='url(%23g)'/%3E%3Cellipse cx='22' cy='20' rx='5' ry='3.7' transform='rotate(-22 22 20)' fill='url(%23g)'/%3E%3Cpath d='M10 23V6l16-4v17h-1.6V6.2L11.6 9.4V23Z' fill='url(%23g)'/%3E%3C/svg%3E");
  --petal: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 34'%3E%3Cdefs%3E%3CradialGradient id='g' cx='.5' cy='.85' r='.9'%3E%3Cstop offset='0' stop-color='%23e98ea0'/%3E%3Cstop offset='.55' stop-color='%23f7c6cf'/%3E%3Cstop offset='1' stop-color='%23fff0f2'/%3E%3C/radialGradient%3E%3C/defs%3E%3Cpath d='M15 33C6 28 1 20 2 12 3 5 8 1 12 2c1 2 5 2 6 0 4-1 9 3 10 10 1 8-4 16-13 21Z' fill='url(%23g)'/%3E%3C/svg%3E");
}

body {
  font-variant-numeric: lining-nums;
  font-size: 20.5px;
  background:
    radial-gradient(ellipse 140% 50% at 50% 0%, rgba(240, 190, 170, 0.18), transparent 70%),
    radial-gradient(ellipse 100% 40% at 0% 60%, rgba(198, 156, 85, 0.07), transparent 70%),
    var(--bg);
}

.label {
  font-weight: 600;
  font-size: 10.5px;
  letter-spacing: 0.28em;
}

/* ---------- Opening ---------- */

.intro__kicker {
  color: var(--accent-deep);
  text-shadow: 0 0 12px rgba(255, 245, 240, 0.95), 0 0 3px rgba(255, 245, 240, 0.9);
}

.intro__to {
  font-style: italic;
  font-weight: 400;
  font-size: clamp(30px, 8.6vw, 40px);
  color: var(--accent-deep);
  text-shadow: 0 0 18px rgba(255, 248, 244, 1), 0 0 6px rgba(255, 248, 244, 0.9);
}

.intro__hint {
  letter-spacing: 0.16em;
  background: rgba(255, 248, 244, 0.8);
  color: var(--accent-deep);
}

.intro__tap {
  border-color: var(--gold);
}

.intro__tap::after {
  background: var(--accent);
}

/* ---------- Hero ---------- */

.hero__veil {
  background:
    radial-gradient(ellipse 100% 30% at 50% 24%, rgba(255, 246, 240, 0.6), rgba(255, 246, 240, 0) 74%),
    linear-gradient(to bottom, rgba(253, 244, 240, 0) 84%, rgba(253, 244, 240, 0.8) 95%, var(--bg) 100%);
}

.hero__text {
  top: max(9%, calc(env(safe-area-inset-top) + 58px));
  padding: 0 20px;
}

.hero__kicker {
  margin: 0 0 8px;
  font-family: var(--label);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.44em;
  text-transform: uppercase;
  color: var(--accent-deep);
  text-shadow: 0 0 12px var(--glow), 0 0 4px var(--glow);
}

.names {
  position: relative;
  margin: 0;
  font-weight: 400;
  line-height: 1;
}

.name {
  display: block;
  white-space: nowrap;
  font-family: var(--display);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(60px, 18vw, 80px);
  line-height: 1.1;
  color: var(--accent-deep);
  text-shadow: 0 0 22px var(--glow), 0 0 7px var(--glow);
}

.names__amp {
  display: block;
  margin: 0;
  font-family: var(--body);
  font-style: italic;
  font-weight: 500;
  font-size: clamp(26px, 7.4vw, 32px);
  line-height: 1.1;
  color: #a5733a;
  text-shadow: 0 0 12px var(--glow), 0 0 4px var(--glow);
}

.hero__date {
  position: absolute;
  left: 50%;
  bottom: max(98px, calc(env(safe-area-inset-bottom) + 86px));
  translate: -50% 0;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 22px;
  border-radius: 999px;
  background: rgba(255, 249, 246, 0.9);
  border: 1px solid var(--line-strong);
  white-space: nowrap;
  font-style: italic;
  font-weight: 500;
  font-size: 21px;
  color: var(--ink);
  box-shadow: 0 12px 26px -14px rgb(var(--shadow) / 0.7);
}

/* a little note between the date and the weekday */
.hero__date i {
  width: 11px;
  height: 15px;
  background: var(--note) center / contain no-repeat;
  animation: bob 1.6s ease-in-out infinite;
}

@keyframes bob {
  0%, 100% { transform: translateY(1px) rotate(-6deg); }
  50% { transform: translateY(-3px) rotate(6deg); }
}

.cue {
  color: var(--accent-deep);
}

.hero.is-in .hero__kicker {
  animation: rise 1.8s var(--ease) 0.4s both;
}

/* each letter hops up like a note on a stave, in a gold shimmer (shared/joy.js splits them) */
.hero.is-in .name,
.hero.is-in .names__amp {
  animation: none;
  opacity: 1;
}

.hero .name .ch {
  opacity: 0;
}

.hero.is-in .name .ch {
  animation: chime 1.1s cubic-bezier(0.34, 1.56, 0.64, 1) calc(var(--start) + var(--i) * 110ms) both;
}

.name--one {
  --start: 0.7s;
}

.name--two {
  --start: 1.9s;
}

.hero.is-in .names__amp {
  animation: fade 1.4s var(--ease-soft) 1.5s both;
}

.hero.is-in .hero__date {
  animation: rise 1.8s var(--ease) 3.2s both;
}

.hero {
  --cue-d: 4s;
}

@keyframes chime {
  0% {
    opacity: 0;
    transform: translateY(26px) scale(0.7);
    color: #e6bd6e;
  }
  50% {
    opacity: 1;
    color: #d39a4f;
  }
  100% {
    opacity: 1;
    transform: none;
    color: var(--accent-deep);
  }
}

/* ---------- Golden notes floating up past the page ---------- */

.notes {
  position: fixed;
  inset: 0;
  z-index: 30;
  pointer-events: none;
  overflow: hidden;
  opacity: 0;
  transition: opacity 3s var(--ease-soft);
}

body.is-open .notes {
  opacity: 1;
}

.notes i {
  position: absolute;
  bottom: -40px;
  left: var(--x);
  width: var(--s);
  height: calc(var(--s) * 1.4);
  background: var(--note) center / contain no-repeat;
  filter: drop-shadow(0 0 6px rgba(255, 220, 160, 0.8));
  opacity: 0.85;
  will-change: transform, opacity;
  animation: drift-up var(--d) ease-in-out var(--delay) infinite;
}

.notes i:nth-child(even) {
  width: calc(var(--s) * 1.4);
  background-image: var(--notes);
}

.notes i:nth-child(1) { --x: 8%; --s: 16px; --d: 17s; --delay: -3s; --sway: 40px; }
.notes i:nth-child(2) { --x: 26%; --s: 14px; --d: 21s; --delay: -11s; --sway: -30px; }
.notes i:nth-child(3) { --x: 48%; --s: 12px; --d: 15s; --delay: -7s; --sway: 26px; }
.notes i:nth-child(4) { --x: 68%; --s: 15px; --d: 19s; --delay: -16s; --sway: -40px; }
.notes i:nth-child(5) { --x: 86%; --s: 13px; --d: 16s; --delay: -1s; --sway: 30px; }
.notes i:nth-child(6) { --x: 38%; --s: 11px; --d: 23s; --delay: -19s; --sway: -24px; }

@keyframes drift-up {
  0% { transform: translate3d(0, 0, 0) rotate(-10deg); opacity: 0; }
  10% { opacity: 0.85; }
  30% { transform: translate3d(var(--sway), -32vh, 0) rotate(12deg); }
  60% { transform: translate3d(calc(var(--sway) * -0.6), -66vh, 0) rotate(-8deg); }
  85% { opacity: 0.7; }
  100% { transform: translate3d(var(--sway), -112vh, 0) rotate(10deg); opacity: 0; }
}

/* ---------- Bursts (shared/joy.js) ---------- */

.joy-note {
  width: 13px;
  height: 18px;
  background: var(--note) center / contain no-repeat;
  filter: drop-shadow(0 0 4px rgba(255, 220, 160, 0.9));
}

.joy-note.is-pair {
  width: 19px;
  background-image: var(--notes);
}

.joy-petal {
  width: 12px;
  height: 14px;
  background: var(--petal) center / contain no-repeat;
}

/* ---------- Sections ---------- */

.title {
  font-family: var(--display);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(38px, 11vw, 50px);
  color: var(--accent-deep);
}

.divider {
  width: min(82%, 310px);
  margin-top: 12px;
}

.corner {
  width: min(42vw, 180px);
}

.section:has(> .corner) {
  padding-top: 186px;
}

/* things rise with a small bounce, like a note landing on its line */
[data-reveal] {
  transform: translateY(30px) scale(0.96);
  transition:
    opacity 1.2s var(--ease),
    transform 1.4s cubic-bezier(0.34, 1.45, 0.64, 1);
}

.invite__greet {
  font-family: var(--display);
  font-style: italic;
  font-size: clamp(28px, 8vw, 34px);
  color: var(--accent-deep);
}

.invite__text {
  font-size: 21.5px;
  line-height: 1.55;
}

.invite .divider {
  margin: 0 auto 28px;
}

.parents__names {
  font-style: italic;
  font-size: 21.5px;
}

.invite__quote {
  font-family: var(--display);
  font-style: italic;
  font-size: 25px;
  color: #a5733a;
}

/* ---------- Date: the day on a turning golden music disc ---------- */

.bigdate {
  gap: 10px;
  margin-bottom: 6px;
}

.bigdate__month {
  font-family: var(--label);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.38em;
  text-transform: uppercase;
  color: var(--accent);
}

.disc {
  position: relative;
  display: grid;
  place-items: center;
  width: 196px;
  height: 196px;
  margin-top: 8px;
}

/* grooves and pins, like the comb disc inside a music box */
.disc__ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background:
    radial-gradient(circle, transparent 0 55%, rgba(255, 255, 255, 0.35) 56% 57%, transparent 58% 64%, rgba(255, 255, 255, 0.3) 65% 66%, transparent 67%),
    repeating-conic-gradient(from 0deg, #f7e2b4 0 3deg, #d8b06a 3deg 6deg),
    var(--gold);
  -webkit-mask: radial-gradient(circle, transparent 0 46%, #000 47%);
  mask: radial-gradient(circle, transparent 0 46%, #000 47%);
  box-shadow: 0 18px 30px -16px rgb(var(--shadow) / 0.8);
  animation: spin 24s linear infinite;
}

/* the pins */
.disc__ring::after {
  content: "";
  position: absolute;
  inset: 8px;
  border-radius: 50%;
  border: 3px dotted rgba(140, 61, 81, 0.55);
}

@keyframes spin {
  to {
    rotate: 360deg;
  }
}

/* a little note going round the rim */
.disc__note {
  position: absolute;
  inset: -16px;
  animation: spin 9s linear infinite reverse;
}

.disc__note::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;
  width: 16px;
  height: 22px;
  margin-left: -8px;
  background: var(--note) center / contain no-repeat;
  filter: drop-shadow(0 0 5px rgba(255, 210, 140, 0.9));
}

.bigdate__day {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 104px;
  height: 104px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff, #fbe9e6 70%, #f3d2d0);
  box-shadow: inset 0 0 0 2px rgba(198, 156, 85, 0.6), 0 6px 14px -6px rgb(var(--shadow) / 0.6);
  font-family: var(--display);
  font-style: italic;
  font-size: 58px;
  font-weight: 400;
  line-height: 1;
  color: var(--accent-deep);
}

/* when the date comes into view the disc winds up, like a key being turned */
.bigdate.is-in .disc__ring {
  animation:
    windup 2.2s cubic-bezier(0.2, 0.8, 0.2, 1) 0.3s both,
    spin 24s linear 2.5s infinite;
}

@keyframes windup {
  from {
    rotate: -540deg;
    scale: 0.7;
  }
  to {
    rotate: 0deg;
    scale: 1;
  }
}

.bigdate__side {
  font-style: italic;
  font-size: 22px;
  color: var(--ink-soft);
}

.bigdate__meta {
  margin: 0 0 30px;
  font-style: italic;
  font-size: 22px;
}

.cal {
  border-radius: 20px;
}

.cal__d.is-day {
  color: #fff;
}

.cal__d.is-day::before {
  background: radial-gradient(circle at 35% 30%, #d98b99, var(--accent) 55%, var(--accent-deep));
  box-shadow: 0 0 0 4px var(--accent-soft), 0 8px 16px -6px rgb(var(--shadow) / 0.6);
  animation: heartbeat 2.4s ease-in-out infinite;
}

@keyframes heartbeat {
  0%, 60%, 100% { transform: scale(1); }
  20% { transform: scale(1.14); }
  35% { transform: scale(1.02); }
  45% { transform: scale(1.1); }
}

.cd__num {
  display: inline-block;
  font-family: var(--display);
  font-style: italic;
  font-weight: 400;
  color: var(--accent-deep);
}

.cd__past {
  font-family: var(--display);
  font-style: italic;
  color: var(--accent-deep);
}

/* ---------- Buttons ---------- */

.btn {
  font-family: var(--label);
  font-weight: 600;
  letter-spacing: 0.14em;
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.btn:active {
  transform: scale(0.95);
}

.btn--solid {
  background: linear-gradient(135deg, #d4848f, var(--accent-deep));
  box-shadow: 0 14px 26px -14px rgb(var(--shadow) / 0.9);
}

/* ---------- Program: gold rings that ring in one by one ---------- */

.tl__time {
  font-family: var(--display);
  font-style: italic;
  font-size: 19px;
  color: var(--accent-deep);
}

.tl__ico {
  background: #fff;
  border: 1.5px solid var(--gold);
  color: var(--accent-deep);
  box-shadow: 0 0 0 4px var(--gold-soft);
}

.tl.is-in .tl__ico {
  animation: ring 0.9s ease-in-out 0.4s;
}

@keyframes ring {
  0%, 100% { rotate: 0deg; }
  20% { rotate: -16deg; }
  40% { rotate: 12deg; }
  60% { rotate: -8deg; }
  80% { rotate: 4deg; }
}

.tl::before {
  background: repeating-linear-gradient(var(--gold) 0 3px, transparent 3px 9px);
  opacity: 0.6;
}

.tl__title {
  font-weight: 600;
}

.tl__note {
  font-style: italic;
}

.detail__ico {
  background: #fff;
  border: 1.5px solid var(--gold);
  color: var(--accent-deep);
}

.detail__title {
  font-weight: 600;
}

/* ---------- Venue ---------- */

.venue__name {
  font-family: var(--display);
  font-style: italic;
  font-weight: 400;
  color: var(--accent-deep);
}

/* ---------- Gifts: rose, cream-gold and turquoise lacquer cards ---------- */

.ccard {
  color: #fff8f5;
  border: 1px solid rgba(255, 230, 200, 0.55);
  background: linear-gradient(135deg, #cf7f8d, #8c3d51);
}

/* a fine gold filigree band, like the rim of the music box */
.ccard::before {
  content: "";
  position: absolute;
  inset: 7px;
  border-radius: 12px;
  border: 1px solid rgba(255, 228, 180, 0.55);
  pointer-events: none;
}

.ccard--humo {
  background: linear-gradient(135deg, #d8b071, #9a7234);
}

.ccard--visa {
  background: linear-gradient(135deg, #5fb0a9, #2f726d);
}

/* ---------- Answer ---------- */

.sent__art {
  width: 140px;
}

.sent__title {
  font-family: var(--display);
  font-style: italic;
  color: var(--accent-deep);
}

/* ---------- Closing ---------- */

.closing__veil {
  background:
    linear-gradient(to bottom, var(--bg) 0%, rgba(253, 244, 240, 0.55) 7%, rgba(253, 244, 240, 0) 20%),
    radial-gradient(ellipse 90% 18% at 50% 21%, rgba(60, 30, 70, 0.45), transparent 76%),
    linear-gradient(to top, var(--bg) 0%, rgba(253, 244, 240, 0) 14%);
}

.closing__text {
  top: 15%;
}

.closing__wait {
  font-family: var(--display);
  font-style: italic;
  font-size: clamp(44px, 13vw, 60px);
  color: #fff6f0;
  text-shadow: 0 2px 18px rgba(50, 20, 50, 0.8);
}

.closing__names {
  font-family: var(--label);
  color: #ffdcbf;
  text-shadow: 0 1px 10px rgba(50, 20, 50, 0.85);
}

.closing__amp {
  font-family: var(--body);
  font-style: italic;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: none;
}

.footer__art {
  width: 120px;
}

.footer__sign {
  font-style: italic;
}

/* ---------- Small and wide screens ---------- */

@media (max-height: 700px) and (max-aspect-ratio: 3/4) {
  .hero__text {
    top: max(6%, calc(env(safe-area-inset-top) + 58px));
  }

  .name {
    font-size: clamp(50px, 15vw, 64px);
  }
}

@media (min-aspect-ratio: 3/4) {
  .name {
    font-size: min(80px, 8.4vh);
  }
}

@media (prefers-reduced-motion: reduce) {
  .notes,
  .disc__note {
    display: none;
  }

  .hero.is-in .name .ch,
  .hero .name .ch {
    animation: none;
    opacity: 1;
  }

  .hero__date i,
  .disc__ring,
  .bigdate.is-in .disc__ring,
  .cal__d.is-day::before,
  .tl.is-in .tl__ico {
    animation: none !important;
  }
}
