/* Pearl paper, champagne details, and warm ink from the family's moon theme. */
:root {
  --ivory:#fffdf7;
  --paper:#fcfaf4;
  --sky:#f1eadf;
  --blue:#806947;
  --blue-deep:#51483c;
  --accent:#987d50;
  --gold:#ac8d52;
  --ink:#514a40;
  --muted:#756f65;
  --bear-muzzle:#fffaf0;
}
body {
  background:radial-gradient(ellipse at 12% 17%,#f3ead68c,transparent 50%),
    radial-gradient(ellipse at 90% 73%,#ece6d77a,transparent 48%),#fffdf8;
  color:var(--ink);
}
.eyebrow { color:#7b7263; }
.button-blue {
  background:linear-gradient(135deg,#94794e,#746044);
  color:#fffdf6;
  box-shadow:0 7px 20px #79613c20,inset 0 1px #ffffff38;
}
.button-blue:hover { background:#705a3c; box-shadow:0 9px 26px #79613c2a; }
.button-outline { background:#fffdf5a6; border-color:#c4b697; color:#65573f; }
.button-outline:hover { background:#f6efdf; }

/* The paper opens out into the same quiet ivory page, without a sliding note. */
.cover {
  background:radial-gradient(ellipse at 50% 41%,#fffef8d9 0,#fbf7edb5 61%,#eae2d293 100%);
  transition:opacity .6s ease,visibility .6s ease;
}
.cover-content { width:min(100%,550px); padding:40px 28px 38px; }
.cover-content::before {
  inset:15px 17px 13px;
  border:1px solid #e7ddc56b;
  border-radius:46% 46% 17px 17px;
  box-shadow:inset 0 0 0 8px #ffffff3d;
}
.cover h1 { color:#62533e; font-size:clamp(2.9rem,6vw,3.6rem); }
.cover h1 em { color:#9b845b; }
.cover-eyebrow { color:#817565; }
.cover-dedication { color:#867866; }
.cover-dedication strong { color:#67553b; }
.cover-footnote,.cover-date { color:#7d7363; }
.cover-spark { color:#b19660; }
.envelope-scene { width:365px; height:284px; margin:22px 0 13px; }
.envelope-glow { background:radial-gradient(ellipse,#fffcf1f2 0,#f5e8cb77 44%,transparent 71%); }
.envelope {
  background:#e0d3b8;
  color:#8c754e;
  transform:rotate(-2deg);
  box-shadow:0 18px 36px #8b714e24,0 1px 1px #fff9e8 inset;
}
.envelope:hover { transform:translateY(-2px) rotate(-2deg); }
.letter,.cover.is-opening .letter {
  background:linear-gradient(150deg,#fffdf7,#f7f0e0);
  transform:none;
  transition:none;
  box-shadow:0 0 1px #aa947b38;
}
.letter>span,.letter>small { color:#8f7c59; }
.envelope-pocket {
  background:linear-gradient(145deg,#f3ebd9,#d8c9ab);
  filter:drop-shadow(0 -1px .5px #ffffff80);
}
.envelope-pocket::after { background:linear-gradient(20deg,#e4d6ba,#fff8e9); }
.envelope-flap {
  background:linear-gradient(165deg,#fff8e8,#e8dabe);
  filter:drop-shadow(0 2px 1px #7c674520);
  transition:transform .65s cubic-bezier(.3,.7,.2,1),z-index .05s .3s;
}
.wax-seal {
  background:radial-gradient(circle at 32% 24%,#f8edcc,#ceba87 75%,#bba170);
  border-color:#eddfb9;
  box-shadow:0 3px 7px #846b3926,inset 0 0 0 3px #bda67950;
}
.wax-seal>span { color:#887047; }
.envelope-caption { color:#8f7953; }
.cover-teddy { width:176px; right:-20px; top:-5px; filter:drop-shadow(0 7px 7px #8f785716); }
.scene-cloud { background:#fffdf5dc; }
.envelope-morph {
  position:fixed;
  left:0;
  top:0;
  z-index:10;
  width:100vw;
  height:100vh;
  height:100dvh;
  display:block;
  opacity:0;
  pointer-events:none;
  border-radius:var(--morph-radius,8px);
  background:radial-gradient(ellipse at 22% 20%,#f5eddc88,transparent 60%),#fffdf8;
  transform-origin:0 0;
  transform:translate3d(var(--morph-x,0px),var(--morph-y,0px),0) scale(var(--morph-scale-x,.7),var(--morph-scale-y,.25));
  box-shadow:0 0 0 1px #fff9ec33,0 20px 70px #8f78571a;
  will-change:transform,opacity;
}
.cover.is-opening .envelope-morph { animation:ivory-page-unfold .9s .35s cubic-bezier(.22,.8,.25,1) forwards; }
.cover.is-opening .cover-content { animation:ivory-envelope-fade 1.2s ease forwards; }
.cover.is-leaving .envelope-morph { transform:translate3d(0,0,0) scale(1); }
@keyframes ivory-page-unfold {
  0% { opacity:0; border-radius:var(--morph-radius,8px); }
  12% { opacity:1; }
  100% { opacity:1; border-radius:0; transform:translate3d(0,0,0) scale(1); box-shadow:none; }
}
@keyframes ivory-envelope-fade {
  0%,30% { opacity:1; }
  100% { opacity:0; }
}

/* No opaque parent canvas: the traveller can sit behind readable foreground. */
#invitation {
  width:min(100%,600px);
  background:transparent;
  border:0;
  border-radius:0;
  box-shadow:none;
  overflow:visible;
}
.site-header { color:#79684e; }
.monogram svg { fill:#ac9367; }
.header-link { border-bottom-color:#c5b99f; }
.hero>.eyebrow { color:#88785f; }
.name-ribbon {
  background:linear-gradient(100deg,#dfd2b8,#fff8e8 47%,#e1d4b8);
  border-top-color:#fff9ec;
  border-bottom-color:#c8b58c;
  box-shadow:0 7px 14px #8b724818;
}
.name-ribbon::before,.name-ribbon::after { background:linear-gradient(#e7dcc5,#cbb98f); }
.name-ribbon h1 { color:#8d7244; text-shadow:0 1px #fffdf7; }
.first-birthday-scene { height:300px; }
.number-halo { background:radial-gradient(ellipse,#f0e5cd7a,transparent 70%); border-color:#cbb9922b; }
.birthday-one {
  left:50%;
  font-size:300px;
  color:#b49a69;
  text-shadow:1px 2px #fbf2db,3px 5px #a9905c16,0 14px 18px #a68b5720;
}
.number-cloud { background:#fffdf7ad; }
.birthday-line { color:#887c69; }
.birthday-line strong { color:#5b4c35; }
.hero-description { color:#a08759; }
.hero-event { color:#62543f; }
.hero-venue { color:#6f5c3e; }
.venue-map-link,.address-map-link {
  color:inherit;
  text-decoration-line:underline;
  text-decoration-color:#b9a378a6;
  text-decoration-thickness:1px;
  text-underline-offset:.25em;
  border-radius:3px;
  padding:3px 0;
}
.venue-map-link:hover,.address-map-link:hover {
  color:#80643b;
  text-decoration-color:currentColor;
}
.venue-map-link:focus-visible,.address-map-link:focus-visible { outline:2px solid #a58b5f; outline-offset:5px; }
.scroll-cue { color:#8a7b63; }
.love-note>p { color:#746e62; }
.love-note h2 em { color:#9c8357; }
.paper-card {
  background:linear-gradient(140deg,#fffdf78a,#fbf6e980);
  border-color:#d4c5a68f;
  box-shadow:0 8px 24px #8f79500c;
}
.paper-card::before { border-color:#dacdb346; }
.paper-star { background:#fffdf8; color:#b79b62; }
.detail-icon { stroke:#ab956e; }
.detail-item h3 { color:#897b65; }
.detail-sub { color:#7d7466; }
.countdown>p { color:#8e7d60; }
.countdown-values span { color:#887960; }
.countdown-values strong { color:#a18a60; }
.wish>p:not(.eyebrow) { color:#7a7062; }
.birthday-cake { filter:none; }
.rsvp {
  background:linear-gradient(180deg,#efe7d676,#faf5e967);
  border-top-color:#d5c4a43d;
  border-bottom-color:#d5c4a43d;
}
.rsvp .eyebrow { color:#917b57; }
.rsvp-form { max-width:460px; }
.rsvp-form input[type="text"],.rsvp-form input[type="number"],.rsvp-form textarea,.rsvp-choice {
  background:#fffef9e8;
  border-color:#c6b99e;
}
.rsvp-form input::placeholder,.rsvp-form textarea::placeholder { color:#8a8173; }
.rsvp-choice:hover { border-color:#a68d60; background:#fffaf0; }
.rsvp-choice:has(input:checked) { background:#eee4cf; border-color:#9a8054; box-shadow:inset 0 0 0 1px #9a8054; }
.closing>p { color:#695a42; }
.closing>p em { color:#a28b5f; }
.signature { color:#81745f; }
.reopen { color:#88734e; border-bottom-color:#bba67d66; }
footer { color:#95866c; }
#motion-toggle {
  background:#fffdf6eb;
  color:#7a694e;
  border-color:#c1ae863d;
  box-shadow:0 3px 18px #79613c0d;
}
#motion-toggle:focus-visible { outline-color:#9a8054; }
.toast { box-shadow:0 8px 30px #806c4220; }

/* Pearl and champagne balloons keep the ambient sky in the reference palette. */
.balloon-body {
  background:radial-gradient(ellipse at 27% 22%,#fff 0%,#fff5 24%,transparent 53%),
    radial-gradient(ellipse at 35% 27%,#fffdf8 0%,#eee6d6 53%,#c9bca3 100%);
  box-shadow:inset -4px -7px 12px #8c795d0f,inset 1px 1px 3px #fffa;
}
.balloon-body::after { background:#ddcfb4; }
.balloon-ivory .balloon-body { background:radial-gradient(ellipse at 30% 22%,#fffef9 0%,#f1ebdc 60%,#d9cdb5 100%); }
.balloon-ivory .balloon-body::after { background:#e6dabe; }
.balloon-gold .balloon-body { background:radial-gradient(ellipse at 30% 22%,#fffae9 0%,#e4d5ad 53%,#c6af7c 100%); }
.balloon-gold .balloon-body::after { background:#d2bd8e; }
.balloon-string path { stroke:#b8a78c; }
.sky-star { color:#ba9e68; }

/* The story uses the full phone width; the bear lives behind it. */
@media (max-width:760px) {
  .journey-ready .love-note,
  .journey-ready .details,
  .journey-ready .wish,
  .journey-ready .rsvp { padding-left:25px; padding-right:25px; }
  .journey-ready .love-note h2 { font-size:1.95rem; }
  .journey-ready .paper-card { padding:36px 21px 28px; }
  .journey-ready .details h2,.journey-ready .wish h2 { font-size:2.25rem; }
  .journey-ready .details-grid { grid-template-columns:1fr 1fr; gap:23px 0; }
  .journey-ready .detail-item { padding:0 7px; }
  .journey-ready .detail-item:first-child { border-right:1px solid #c3b39155; }
  .journey-ready .detail-item:nth-child(2) { border:0; padding:0 7px; }
  .journey-ready .detail-place { padding:23px 0 0; }
  .journey-ready .detail-value { font-size:1.55rem; }
  .journey-ready .detail-place .detail-value { font-size:1.5rem; }
  .journey-ready .countdown-values { gap:16px; }
  .journey-ready .countdown-values span { min-width:63px; flex:0 1 auto; }
  .journey-ready .countdown-values strong { font-size:3rem; }
  .journey-ready .wish-candle { width:230px; max-width:100%; }
  .journey-ready .rsvp h2 { font-size:2.4rem; }
  .journey-ready .rsvp-choices,.journey-ready .rsvp-counts { grid-template-columns:1fr 1fr; gap:11px; }
  .journey-ready .rsvp-choice { min-height:60px; font-size:.9375rem; padding:12px 10px; }
}
@media (max-width:600px) {
  .cover-content { padding:35px 26px 31px; }
  .cover h1 { font-size:2.95rem; }
  .envelope-scene { width:330px; height:263px; margin:19px 0 11px; }
  .cover-teddy { width:161px; right:-15px; top:-4px; }
  .first-birthday-scene { height:286px; }
  .birthday-one { font-size:287px; }
  .name-ribbon { margin-top:30px; }
  .site-header { padding-left:26px; padding-right:26px; }
}
@media (max-width:359px) {
  .cover-content { padding-left:20px; padding-right:20px; }
  .cover h1 { font-size:2.6rem; }
  .envelope-scene { height:236px; }
  .cover-teddy { width:148px; right:-16px; }
  .journey-ready .love-note,.journey-ready .details,.journey-ready .wish,.journey-ready .rsvp { padding-left:20px; padding-right:20px; }
  .journey-ready .paper-card { padding-left:17px; padding-right:17px; }
  .journey-ready .rsvp-choices { grid-template-columns:1fr; }
  .journey-ready .rsvp-counts { grid-template-columns:1fr 1fr; }
  .journey-ready .detail-value { font-size:1.4rem; }
  .journey-ready .countdown-values { gap:10px; }
  .journey-ready .countdown-values strong { font-size:2.8rem; }
}
@media (max-height:720px) {
  .cover-content { padding-top:24px; padding-bottom:23px; }
  .cover h1 { font-size:2.6rem; }
  .envelope-scene { height:225px; margin-top:12px; margin-bottom:6px; }
  .cover-teddy { width:145px; right:-9px; top:-4px; }
}
.motion-paused .cover.is-opening .envelope-morph { animation:none; }
.motion-paused .cover.is-opening .cover-content { animation:none; }
@media (prefers-reduced-motion:reduce) {
  body:not(.motion-running) .cover.is-opening .envelope-morph,
  body:not(.motion-running) .cover.is-opening .cover-content { animation:none; }
}
