/* Gabriel & Livia wedding invitation. Tuscan summer. Mobile first, wide layout from 900px. */
:root {
  --linen: #F7F0E3;
  --linen-2: #F1E4CE;
  --terra: #B8603E;
  --terra-d: #9A4A2C;
  --olive: #6B7440;
  --olive-d: #4B5430;
  --ochre: #C99A3B;
  --ochre-d: #8F6A1C;
  --ink: #3B2A20;
  --ink-2: #5F4B3E;
  --clay: #EBCFBD;
  --clay-l: #F2DECF;
  --paper-img: url('/assets/img/paper.jpg');
  --lining: url('/assets/img/lining.jpg');
  --f-display: 'Fraunces', 'Iowan Old Style', Georgia, serif;
  --f-ui: 'Manrope', 'Helvetica Neue', Arial, sans-serif;
  --f-script: 'Italianno', 'Snell Roundhand', cursive;
  --ease: cubic-bezier(.22, .8, .24, 1);
  --pad: 24px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
html.locked, html.locked body { overflow: hidden; height: 100%; }
body {
  font-variant-numeric: lining-nums;
  margin: 0; background: var(--linen); color: var(--ink);
  font-family: var(--f-ui); font-weight: 400; font-size: 16px; line-height: 1.7;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
i { font-style: italic; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--terra); outline-offset: 3px; border-radius: 4px; }
button { font: inherit; color: inherit; }

/* ================= ENVELOPE ================= */
.env {
  position: fixed; inset: 0; z-index: 100; overflow: hidden; cursor: pointer;
  perspective: 1800px; perspective-origin: 50% 20%;
  background: #E8D6B8 var(--paper-img) center / cover;
  -webkit-tap-highlight-color: transparent;
}
.env::after { content: ""; position: absolute; inset: 0; z-index: 9; pointer-events: none; box-shadow: inset 0 0 150px rgba(150, 90, 40, .28); }
.env__back {
  position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(180deg, rgba(30,36,14,.4), transparent 45%), var(--lining) 0 0 / 520px auto;
  transition: opacity .7s ease;
}

.env__card {
  position: absolute; z-index: 2; left: 9%; right: 9%; top: 7%; bottom: 9%;
  background: #FAF4E6 var(--paper-img) center / cover;
  box-shadow: 0 10px 40px rgba(30,25,10,.4);
  transform: translateY(78%);
  transition: transform 1.1s var(--ease), left .9s var(--ease), right .9s var(--ease), top .9s var(--ease), bottom .9s var(--ease), box-shadow .9s ease;
  display: grid; place-items: center; padding: 14px;
}
.env__card::before { content: ""; position: absolute; inset: 0; background: rgba(250, 244, 230, .62); }
.env__card-frame {
  position: relative; width: 100%; height: 100%; border: 1px solid var(--terra); outline: 1px solid rgba(201,154,59,.6); outline-offset: -7px;
  display: grid; place-content: center; justify-items: center; gap: 12px; text-align: center;
  transition: opacity .5s ease;
}
.env__card-lemon { width: 44px; height: 44px; }
.env__card-eyebrow { font-size: .72rem; font-weight: 600; letter-spacing: .4em; text-transform: uppercase; color: var(--terra-d); padding-left: .4em; }
.env__card-mono { font-family: var(--f-display); font-style: italic; font-weight: 300; font-size: clamp(4.2rem, 19vw, 6.4rem); line-height: 1; color: var(--ink); font-variation-settings: "SOFT" 100; }
.env__card-mono i { font-family: var(--f-script); color: var(--terra); font-weight: 400; font-size: .85em; padding: 0 .08em; }
.env__card-date { font-family: var(--f-display); font-size: 1.1rem; letter-spacing: .1em; color: var(--ink); padding-left: .1em; }
.env__card-place { font-size: .68rem; font-weight: 600; letter-spacing: .3em; text-transform: uppercase; color: var(--olive-d); padding-left: .3em; }

.env__piece {
  position: absolute; inset: 0; z-index: 3;
  background: #E9D8BA var(--paper-img) center / cover;
  transition: transform .95s cubic-bezier(.55, 0, .6, 1), opacity .6s ease;
}
.env__piece--l { clip-path: polygon(0 0, 50% 52%, 0 100%); }
.env__piece--r { clip-path: polygon(100% 0, 50% 52%, 100% 100%); }
.env__piece--b { clip-path: polygon(0 100%, 50% 52%, 100% 100%); }
.env__piece::after { content: ""; position: absolute; inset: 0; pointer-events: none; }
.env__piece--l::after { background: linear-gradient(90deg, rgba(255,250,235,.28), transparent 45%, rgba(110,60,25,.2) 100%); }
.env__piece--r::after { background: linear-gradient(270deg, rgba(255,250,235,.06), rgba(110,60,25,.1) 50%, rgba(110,60,25,.3) 100%); }
.env__piece--b::after { background: radial-gradient(ellipse 85% 62% at 50% 52%, rgba(110,60,25,.3), transparent 70%), linear-gradient(0deg, rgba(255,250,235,.25), transparent 55%); }

/* airmail edge: terracotta and olive stripes around the envelope */
.env__piece::before, .env__flap-front::before {
  content: ""; position: absolute; inset: 0; padding: 11px; pointer-events: none; z-index: 1;
  background: repeating-linear-gradient(-45deg, var(--terra) 0 16px, transparent 16px 26px, var(--olive) 26px 42px, transparent 42px 52px);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0); mask-composite: exclude;
  opacity: .92;
}

.env__stamp { position: absolute; z-index: 2; right: 9%; top: 27%; width: 52px; height: auto; transform: rotate(4deg); filter: drop-shadow(0 2px 3px rgba(60,35,15,.35)); }
.env__postmark { position: absolute; z-index: 2; right: 12%; top: 33%; width: 88px; height: auto; transform: rotate(-10deg); mix-blend-mode: multiply; }
.env__to { position: absolute; z-index: 2; left: 0; right: 0; top: 83%; margin: 0; text-align: center; font-family: var(--f-script); font-size: clamp(1.9rem, 8vw, 2.5rem); line-height: 1.1; color: rgba(59,42,32,.78); padding: 0 12%; }

.env__creases { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 4; pointer-events: none; transition: opacity .5s ease; }
.c-dark { stroke: rgba(120, 80, 45, .26); stroke-width: 1; }
.c-light { stroke: rgba(255, 252, 240, .6); stroke-width: .8; }

.env__flap-shadow { position: absolute; z-index: 4; left: 0; right: 0; top: 0; height: 52%; filter: blur(9px); transform: translateY(10px); pointer-events: none; transition: opacity .4s ease; }
.env__flap-shadow i { position: absolute; inset: 0; clip-path: polygon(0 0, 100% 0, 50% 100%); background: rgba(80, 45, 20, .5); }
.env__flap {
  position: absolute; z-index: 5; left: 0; right: 0; top: 0; height: 52%;
  transform-origin: 50% 0; transform-style: preserve-3d;
  transition: transform 1.25s cubic-bezier(.5, .05, .25, 1);
}
.env__flap-front, .env__flap-back { position: absolute; inset: 0; clip-path: polygon(0 0, 100% 0, 50% 100%); backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.env__flap-front {
  background: linear-gradient(180deg, rgba(255,250,235,.32), rgba(120,70,30,.14)), #EDDDC0 var(--paper-img) center top / cover;
}
.env__flap-back { transform: rotateX(180deg); background: linear-gradient(0deg, rgba(30,36,14,.3), transparent), var(--lining) 0 0 / 520px auto; }

.env__top {
  position: absolute; z-index: 6; top: 8.5%; left: 0; right: 0; text-align: center; margin: 0;
  font-family: var(--f-display); font-style: italic; font-weight: 400; font-size: clamp(1.25rem, 5.4vw, 1.8rem); letter-spacing: .06em; color: rgba(59, 42, 32, .7);
  font-variation-settings: "SOFT" 100; transition: opacity .5s ease;
}
.env__top i { font-family: var(--f-script); font-size: 1.15em; color: var(--terra); padding: 0 .1em; }

.env__seal {
  position: absolute; z-index: 7; left: 50%; top: 52%; width: 148px; padding: 0; border: 0; background: none; cursor: pointer;
  transform: translate(-50%, -50%); -webkit-tap-highlight-color: transparent;
  transition: transform .9s var(--ease), opacity .6s ease, filter .6s ease;
}
.env__seal img { width: 100%; height: auto; filter: drop-shadow(0 7px 7px rgba(60, 30, 12, .45)); }
.env__seal:focus-visible { outline-offset: 6px; border-radius: 50%; outline-color: var(--ink); }
.env__pulse {
  position: absolute; left: 50%; top: 50%; width: 112px; height: 112px; margin: -56px 0 0 -56px; border-radius: 50%;
  border: 1.5px solid rgba(255,244,220,.9); animation: pulse 2.8s ease-out infinite; pointer-events: none;
}
.env__hint {
  position: absolute; z-index: 6; left: 0; right: 0; top: 71%; margin: 0; text-align: center;
  font-size: .68rem; font-weight: 700; letter-spacing: .26em; text-transform: uppercase; color: rgba(59, 42, 32, .85); padding-left: .26em;
  animation: breathe 3.2s ease-in-out infinite; transition: opacity .4s ease;
}

/* envelope choreography */
.env.is-breaking .env__seal { transform: translate(-50%, -50%) scale(1.28) rotate(-6deg); opacity: 0; filter: blur(3px); }
.env.is-breaking .env__hint, .env.is-breaking .env__pulse { opacity: 0; animation: none; }
.env.is-flap .env__flap { transform: rotateX(180deg); }
.env.is-flap .env__top, .env.is-flap .env__flap-shadow { opacity: 0; }
.env.is-flap .env__creases .c-light { opacity: 0; }
.env.is-card .env__card { transform: translateY(0); }
.env.is-out .env__piece--l { transform: translateX(-105%); }
.env.is-out .env__piece--r { transform: translateX(105%); }
.env.is-out .env__piece--b { transform: translateY(105%); }
.env.is-out .env__creases, .env.is-out .env__flap, .env.is-out .env__flap-shadow { opacity: 0; transition: opacity .4s ease; }
.env.is-out .env__card { box-shadow: 0 18px 50px rgba(20, 25, 8, .5); }
.env.is-zoom .env__card { z-index: 8; left: 0; right: 0; top: 0; bottom: 0; box-shadow: none; transform: translateY(0); transition-duration: 1.1s; }
.env.is-zoom .env__card-frame { opacity: 0; transition: opacity .9s ease .2s; }
.env.is-zoom .env__back { opacity: 0; }
.env.is-gone { opacity: 0; transition: opacity .9s ease; pointer-events: none; }

@keyframes pulse { 0% { transform: scale(.85); opacity: .9; } 100% { transform: scale(1.75); opacity: 0; } }
@keyframes breathe { 0%, 100% { opacity: .6; } 50% { opacity: 1; } }

/* ================= INVITE ================= */
.invite { position: relative; overflow: hidden; background: var(--linen); }
.invite > * { position: relative; z-index: 1; }

.eyebrow { margin: 0 0 18px; font-size: .72rem; font-weight: 700; letter-spacing: .34em; text-transform: uppercase; color: var(--terra-d); padding-left: .34em; line-height: 2; }
.script { margin: 0 0 4px; font-family: var(--f-script); font-size: clamp(2.2rem, 8.4vw, 3rem); color: var(--terra); line-height: 1.2; }
.h2 { text-wrap: balance; margin: 0 0 14px; font-family: var(--f-display); font-weight: 400; font-style: italic; font-variation-settings: "SOFT" 100; font-size: clamp(2rem, 8.4vw, 2.8rem); line-height: 1.12; color: var(--ink); }
.body { margin: 0 auto 22px; max-width: 34em; color: var(--ink-2); font-size: 1rem; }
.body strong { font-weight: 600; color: var(--ink); }

/* progress: a lemon rolls along the top edge as you scroll */
.progress { position: fixed; z-index: 50; left: 0; right: 0; top: 0; height: 26px; pointer-events: none; opacity: 0; transition: opacity .8s ease 1.2s; }
.opened .progress { opacity: 1; }
.progress i { position: absolute; left: 0; top: 0; height: 3px; width: calc(var(--p, 0) * 100%); background: linear-gradient(90deg, var(--olive), var(--ochre) 60%, var(--terra)); }
.progress svg { position: absolute; top: -1px; left: calc((100% - 24px) * var(--p, 0)); width: 24px; height: 24px; transform: rotate(calc(var(--p, 0) * 2400deg)); filter: drop-shadow(0 2px 2px rgba(59,42,32,.25)); }

/* string lights between sections */
.lights { position: absolute; z-index: 3; left: 0; right: 0; top: 0; height: 56px; overflow: hidden; pointer-events: none; }
.lights svg { position: absolute; left: 50%; top: 0; width: 1920px; height: 56px; max-width: none; transform: translateX(-50%); }
.lights .wire { fill: none; stroke: rgba(59,42,32,.5); stroke-width: 1.2; }
.lights .cap { fill: rgba(59,42,32,.65); }
.lights .bulb { fill: #FFE9A6; animation: twinkle 4.2s ease-in-out infinite; animation-delay: var(--t, 0s); }
.lights .halo { fill: #F3C85A; opacity: .35; animation: twinkle 4.2s ease-in-out infinite; animation-delay: var(--t, 0s); }
@keyframes twinkle { 0%, 100% { opacity: 1; } 50% { opacity: .55; } }
.lights .halo { animation-name: haloPulse; }
@keyframes haloPulse { 0%, 100% { opacity: .38; } 50% { opacity: .14; } }

/* ---- hero ---- */
.hero { position: relative; min-height: 100vh; min-height: 100svh; display: flex; align-items: center; justify-content: center; text-align: center; padding: 270px 18px 225px;
  background: radial-gradient(70% 36% at 50% 25%, rgba(240, 190, 85, .34), transparent 72%), linear-gradient(180deg, #FAF4E6 0%, #F6EBD6 50%, #EFD9BE 100%); }
.hero__garland { position: absolute; left: 50%; top: -1.6%; width: 178%; transform: translateX(-50%); z-index: 3; pointer-events: none; transform-origin: 50% 0; }
.hero__garland img { width: 100%; height: auto; }
.hero__lantern { position: absolute; left: 50%; top: 0; width: clamp(92px, 27vw, 120px); height: auto; transform: translateX(-50%); z-index: 2; transform-origin: 50% 0; pointer-events: none; filter: drop-shadow(0 16px 20px rgba(150,100,30,.28)); }
.hero__table { position: absolute; left: 50%; bottom: -8px; width: 104%; max-width: none; height: auto; transform: translateX(-50%); z-index: 3; pointer-events: none; }
.hero__body { position: relative; z-index: 4; width: 100%; max-width: 520px; }
.hero__eyebrow { margin-bottom: 20px; }

.names { margin: 0; font-family: var(--f-display); font-style: italic; font-weight: 300; font-variation-settings: "SOFT" 100; font-size: clamp(3.6rem, 18.4vw, 5.2rem); letter-spacing: -.01em; line-height: 1.02; color: var(--ink); display: grid; justify-items: center; }
.names__a { display: block; }
.names__g { transform: translateX(-12%); }
.names__l2 { display: flex; align-items: baseline; justify-content: center; gap: .14em; transform: translateX(9%); }
.names__a i { display: inline-block; font-style: italic; }
.names__amp { display: block; font-family: var(--f-script); font-style: normal; font-weight: 400; letter-spacing: 0; font-size: 1.05em; line-height: 1; color: var(--terra); transform: translateY(.04em); }
.hero__date { margin: 24px 0 4px; display: grid; justify-items: center; gap: 4px; font-family: var(--f-display); font-size: 1.4rem; letter-spacing: .12em; color: var(--ink); }
.hero__date svg { width: 30px; height: 30px; }
.hero__date time { padding-left: .12em; }
.hero__place { margin: 0; font-size: .68rem; font-weight: 700; letter-spacing: .26em; text-transform: uppercase; color: var(--terra-d); padding-left: .26em; }


/* hero entrance (starts when the envelope opens) */
.hero__garland, .hero__table, .hero__lantern { opacity: 0; }
.hero__eyebrow, .hero__date, .hero__place { opacity: 0; }
.names__a i, .names__amp { opacity: 0; }
.opened .hero__garland { animation: dropIn 1.6s var(--ease) .1s both, breeze 9s ease-in-out 2s infinite alternate; }
.opened .hero__table { animation: tableIn 1.8s var(--ease) .3s both; }
.opened .hero__lantern { animation: lampIn 1.9s var(--ease) .2s both, sway 7s ease-in-out 2.2s infinite alternate; }
.opened .hero__eyebrow { animation: fadeUp 1.2s var(--ease) .9s both; }
.opened .names__a i { animation: letterIn 1.1s var(--ease) calc(1.2s + var(--n) * .08s) both; }
.opened .names__amp { animation: fadeUp 1.2s var(--ease) 1.9s both; }
.opened .hero__date { animation: fadeUp 1.2s var(--ease) 2.3s both; }
.opened .hero__place { animation: fadeUp 1.2s var(--ease) 2.5s both; }
@keyframes dropIn { from { opacity: 0; transform: translate(-50%, -46px); } to { opacity: 1; transform: translate(-50%, 0); } }
@keyframes tableIn { from { opacity: 0; transform: translate(-50%, 60px); } to { opacity: 1; transform: translate(-50%, 0); } }
@keyframes lampIn { from { opacity: 0; transform: translate(-50%, -80px); } to { opacity: 1; transform: translate(-50%, 0); } }
@keyframes sway { from { transform: translateX(-50%) rotate(-2.2deg); } to { transform: translateX(-50%) rotate(2.2deg); } }
@keyframes breeze { from { transform: translateX(-50%) rotate(-.3deg); } to { transform: translateX(-50%) rotate(.3deg); } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes letterIn { from { opacity: 0; transform: translateY(14px) scale(.96); filter: blur(5px); } to { opacity: 1; transform: none; filter: none; } }

/* ---- sections ---- */
.sec { padding: 108px var(--pad) 84px; text-align: center; position: relative; }
.sec--together { background: var(--linen); padding-top: 96px; }
.sec--date { background: var(--clay-l); }
.sec--venue { background: var(--olive-d); color: var(--linen); }
.sec--day { background: var(--linen); }
.sec--dress { background: var(--clay); }
.sec--stay { background: var(--linen); }
.sec--there { background: var(--linen-2); }
.sec--rsvp { background: var(--clay-l); }
.sec--together > .lights { display: none; }

.guest { margin: 0 auto 18px; font-family: var(--f-script); font-size: clamp(2.2rem, 8.4vw, 3rem); color: var(--olive-d); line-height: 1.2; }
.lead { margin: 6px auto 22px; max-width: 14em; font-family: var(--f-display); font-style: italic; font-weight: 300; font-variation-settings: "SOFT" 100; font-size: clamp(2.3rem, 10vw, 3.3rem); line-height: 1.08; color: var(--ink); }
.lead i { font-family: var(--f-script); font-style: normal; color: var(--terra); font-size: 1.1em; padding: 0 .1em; }
.lead span { display: block; margin-top: 20px; font-family: var(--f-ui); font-style: normal; font-weight: 400; font-size: 1.02rem; line-height: 1.6; color: var(--ink-2); max-width: 22em; margin-inline: auto; font-variation-settings: normal; }
.sprig { margin: 0 auto 22px; width: 96px; }
.sprig svg { width: 100%; height: 30px; }

.split { display: grid; gap: 8px; }
.split__text { display: block; }

/* calendar: a wall-calendar page with the day circled */
.cal { margin: 8px auto 30px; width: min(100%, 320px); background: #FFFBF1; border-radius: 4px; box-shadow: 0 18px 36px rgba(110, 60, 30, .16), 0 2px 0 rgba(184, 96, 62, .2); overflow: hidden; transform: rotate(-1.2deg); }
.cal__m { margin: 0; padding: 14px 10px 12px; background: var(--terra); color: var(--linen); font-family: var(--f-display); font-style: italic; font-size: 1.4rem; font-weight: 400; letter-spacing: .04em; }
.cal__g { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; padding: 12px 14px 16px; font-size: .9rem; }
.cal__g span { aspect-ratio: 1; display: grid; place-items: center; color: var(--ink-2); position: relative; }
.cal__g .dw { font-size: .62rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--terra-d); aspect-ratio: auto; padding: 2px 0 6px; }
.cal__g .on { color: var(--ink); font-weight: 700; }
.cal__g .on::before { content: ""; position: absolute; inset: -4px -3px; border: 2px solid var(--terra); border-radius: 52% 46% 55% 44% / 48% 56% 44% 52%; transform: rotate(-8deg); }
.cal__g .on::after { content: ""; position: absolute; inset: -7px -6px -2px -5px; border: 1px solid rgba(184, 96, 62, .55); border-radius: 46% 54% 44% 56% / 55% 45% 55% 45%; transform: rotate(7deg); }

.count { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; max-width: 360px; margin: 6px auto 32px; }
.count div { padding: 10px 0 8px; background: #FFFBF1; border-top: 3px solid var(--ochre); border-radius: 3px; box-shadow: 0 8px 18px rgba(110, 60, 30, .1); }
.count b { display: block; font-family: var(--f-display); font-weight: 400; font-size: 2.1rem; line-height: 1.1; color: var(--terra-d); font-variant-numeric: lining-nums tabular-nums; }
.count span { font-size: .58rem; font-weight: 700; letter-spacing: .22em; text-transform: uppercase; color: var(--ink-2); padding-left: .22em; }

.actions { display: grid; gap: 14px; justify-items: center; margin-top: 8px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 54px; padding: 0 30px; border-radius: 6px; border: 0; background: var(--terra-d); color: var(--linen); font-family: var(--f-ui); font-size: .76rem; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; text-decoration: none; cursor: pointer; position: relative;
  box-shadow: inset 0 0 0 4px var(--terra-d), inset 0 0 0 5px rgba(247,240,227,.45), 0 10px 22px rgba(154, 74, 44, .3); transition: background .3s ease, color .3s ease, transform .3s var(--ease), box-shadow .3s ease; }
.btn svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.btn:hover { background: var(--ink); transform: translateY(-2px); box-shadow: inset 0 0 0 4px var(--ink), inset 0 0 0 5px rgba(247,240,227,.45), 0 12px 24px rgba(59, 42, 32, .3); }
.btn:active { transform: translateY(0); }
.btn--ghost { background: transparent; color: var(--terra-d); box-shadow: inset 0 0 0 1.5px var(--terra-d), inset 0 0 0 5px transparent; }
.btn--ghost:hover { background: var(--terra-d); color: var(--linen); box-shadow: inset 0 0 0 4px var(--terra-d), inset 0 0 0 5px rgba(247,240,227,.45); }
.btn--light { background: var(--linen); color: var(--olive-d); box-shadow: inset 0 0 0 4px var(--linen), inset 0 0 0 5px rgba(75,84,48,.4), 0 10px 22px rgba(0,0,0,.25); }
.btn--light:hover { background: var(--ochre); color: var(--ink); box-shadow: inset 0 0 0 4px var(--ochre), inset 0 0 0 5px rgba(59,42,32,.4); }
.link { background: none; border: 0; padding: 6px 2px; cursor: pointer; font-size: .88rem; color: var(--ink-2); text-decoration: underline; text-decoration-color: var(--terra); text-underline-offset: 4px; transition: color .25s ease; }
.link:hover { color: var(--terra-d); }

/* venue: the watercolor as a taped postcard */
.sec--venue .eyebrow { color: #F2CF8F; }
.sec--venue .h2 { color: var(--linen); }
.sec--venue .body { color: rgba(247,240,227,.86); }
.sec--venue .addr { color: var(--linen); }
.sec--venue :focus-visible { outline-color: var(--ochre); }
.sec--venue::before { content: ""; position: absolute; inset: 0; background: var(--lining) 0 0 / 520px auto; opacity: .1; pointer-events: none; }
.sec--venue > *:not(.lights) { position: relative; }
.postcard { position: relative; width: min(82%, 300px); margin: 12px auto 40px; padding: 11px 11px 38px; background: #FFFBF1; border-radius: 3px; transform: rotate(-2.4deg); box-shadow: 0 26px 46px rgba(0,0,0,.4); }
.postcard img { width: 100%; height: auto; aspect-ratio: 900 / 1205; object-fit: cover; }
.postcard figcaption { position: absolute; left: 0; right: 0; bottom: 8px; text-align: center; font-family: var(--f-script); font-size: 1.6rem; line-height: 1.2; color: var(--ink-2); }
.tape { position: absolute; z-index: 2; width: 74px; height: 24px; background: rgba(201,154,59,.62); box-shadow: 0 1px 2px rgba(0,0,0,.2); }
.tape--a { top: -11px; left: -20px; transform: rotate(-38deg); }
.tape--b { top: -11px; right: -20px; transform: rotate(38deg); }
.addr { font-style: normal; margin: 0 0 18px; font-family: var(--f-display); font-size: 1.3rem; font-style: italic; color: var(--ink); line-height: 1.45; }

/* schedule: a trattoria menu card */
.menu { position: relative; margin: 30px auto 0; max-width: 460px; padding: 34px 26px 26px; background: #FFFBF1; border: 1px solid rgba(184,96,62,.5); outline: 1px solid rgba(201,154,59,.55); outline-offset: -8px; box-shadow: 0 24px 44px rgba(110, 60, 30, .12); }
.menu::before { content: ""; position: absolute; top: -17px; left: 50%; width: 34px; height: 34px; transform: translateX(-50%); background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32"><path d="M17.5 7.2c.2-3 2.3-5 5.6-5.4.2 3.3-1.8 5.3-5.6 5.4Z" fill="%236B7440"/><path d="M2.2 17.2 6 15.8C6.8 10.4 11.2 7.4 16.2 7.4S25.4 10.4 26 15.8l3.8 1.4-3.8 1.4C25.4 24 21.2 27 16.2 27S6.8 24 6 18.6Z" fill="%23E7BD3C"/></svg>') center / contain no-repeat; }
.menu__list { list-style: none; margin: 0; padding: 0; text-align: left; }
.menu__list li { padding: 12px 0 14px; }
.menu__list li + li { border-top: 1px solid rgba(201,154,59,.28); }
.menu__row { display: flex; align-items: baseline; gap: 10px; }
.menu__row h3 { margin: 0; font-family: var(--f-display); font-style: italic; font-weight: 400; font-size: 1.45rem; line-height: 1.25; color: var(--ink); font-variation-settings: "SOFT" 100; }
.dots { flex: 1; min-width: 14px; border-bottom: 2px dotted var(--ochre); transform: translateY(-5px); }
.menu__row time { font-size: .8rem; font-weight: 700; letter-spacing: .08em; color: var(--terra-d); white-space: nowrap; }
.menu__list p { margin: 0; font-size: .92rem; color: var(--ink-2); }

/* dress code: paint chips */
.chips { list-style: none; margin: 30px auto 34px; padding: 0 4px; display: flex; flex-wrap: wrap; justify-content: center; gap: 16px 12px; max-width: 460px; }
.chips li { width: 86px; background: #FFFBF1; padding: 7px 7px 9px; font-size: .6rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--ink); text-align: left; box-shadow: 0 10px 18px rgba(110, 60, 30, .16); border-radius: 2px; }
.chips li:nth-child(odd) { transform: rotate(-2.5deg); } .chips li:nth-child(even) { transform: rotate(2deg) translateY(4px); }
.chips span { display: block; height: 70px; background: var(--c); margin-bottom: 8px; box-shadow: inset 0 0 0 1px rgba(59,42,32,.1); }
.chips b { display: block; font-size: .56rem; font-weight: 600; letter-spacing: .14em; color: var(--ink-2); margin-bottom: 1px; }

/* stay */
.hotels { display: grid; gap: 16px; max-width: 460px; margin: 30px auto 0; text-align: left; }
.hotel { position: relative; padding: 22px 22px 22px 26px; background: #FFFBF1; border-radius: 4px; box-shadow: 0 14px 28px rgba(110, 60, 30, .1); border-left: 6px solid var(--olive); }
.hotel:nth-child(2) { border-left-color: var(--ochre); } .hotel:nth-child(3) { border-left-color: var(--terra); }
.hotel::before { content: ""; position: absolute; right: -9px; top: 50%; width: 18px; height: 18px; margin-top: -9px; border-radius: 50%; background: var(--linen); box-shadow: inset 2px 0 3px rgba(110,60,30,.12); }
.hotel__tag { margin: 0 0 4px; font-size: .64rem; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; color: var(--terra-d); }
.hotel h3 { margin: 0 0 6px; font-family: var(--f-display); font-style: italic; font-weight: 400; font-size: 1.5rem; line-height: 1.2; color: var(--ink); font-variation-settings: "SOFT" 100; }
.hotel p:last-child { margin: 0; font-size: .94rem; color: var(--ink-2); }

/* getting there */
.routes { display: grid; gap: 16px; max-width: 460px; margin: 30px auto 0; }
.route { padding: 26px 24px 24px; background: rgba(255,251,241,.7); border: 1px solid rgba(143,106,28,.35); border-radius: 4px; }
.route svg { width: 34px; height: 34px; margin: 0 auto 10px; fill: none; stroke: var(--terra-d); stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.route h3 { margin: 0 0 6px; font-family: var(--f-display); font-style: italic; font-weight: 400; font-size: 1.5rem; color: var(--ink); font-variation-settings: "SOFT" 100; }
.route p { margin: 0; font-size: .95rem; color: var(--ink-2); }
.shuttle { max-width: 460px; margin: 16px auto 0; padding: 30px 24px 28px; background: var(--terra-d); color: var(--linen); border-radius: 4px; position: relative; box-shadow: 0 20px 36px rgba(154, 74, 44, .28); }
.shuttle::before { content: ""; position: absolute; inset: 7px; border: 1px dashed rgba(247,240,227,.5); border-radius: 2px; pointer-events: none; }
.shuttle__k { margin: 0; font-size: .7rem; font-weight: 700; letter-spacing: .32em; text-transform: uppercase; color: #FBE3B8; padding-left: .32em; }
.shuttle__t { margin: 2px 0 8px; font-family: var(--f-display); font-style: italic; font-weight: 300; font-size: 3.4rem; line-height: 1.1; font-variation-settings: "SOFT" 100; }
.shuttle__d { margin: 0 auto; max-width: 28em; font-size: .94rem; color: rgba(247,240,227,.92); }

/* rsvp */
.rsvp { margin: 30px auto 0; max-width: 460px; text-align: left; padding: 34px 24px 26px; background: #FFFBF1; border-radius: 4px; box-shadow: 0 22px 42px rgba(110, 60, 30, .14); position: relative; overflow: hidden; }
.rsvp::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 9px; background: repeating-linear-gradient(-45deg, var(--terra) 0 14px, transparent 14px 22px, var(--olive) 22px 36px, transparent 36px 44px); }
.field { display: block; margin-bottom: 18px; }
.field span { display: block; margin-bottom: 6px; font-size: .66rem; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; color: var(--ink-2); }
.field em { font-style: normal; text-transform: none; letter-spacing: .03em; font-weight: 500; }
.field input, .field select { width: 100%; min-height: 52px; padding: 10px 14px; font: inherit; font-size: 1rem; font-weight: 500; color: var(--ink); background: #FFFFFF; border: 1px solid #D8C4A8; border-radius: 4px; appearance: none; -webkit-appearance: none; transition: border-color .25s ease, box-shadow .25s ease; }
.field select { background-image: linear-gradient(45deg, transparent 50%, var(--terra) 50%), linear-gradient(135deg, var(--terra) 50%, transparent 50%); background-position: calc(100% - 20px) 23px, calc(100% - 15px) 23px; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 36px; }
.field input::placeholder { color: #75624F; font-weight: 400; }
.field input:focus, .field select:focus { outline: none; border-color: var(--terra); box-shadow: 0 0 0 3px rgba(184,96,62,.25); }
.form-error { margin: -4px 0 14px; font-size: .9rem; font-weight: 600; color: #A23A1E; }
.rsvp__btns { display: grid; gap: 12px; margin-top: 8px; }
.rsvp__btns .btn { width: 100%; padding: 0 14px; }
.rsvp__via { margin: 14px 0 0; display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 0 4px; text-align: center; font-size: .88rem; color: var(--ink-2); }
.rsvp__via .link { min-height: 48px; padding: 0 6px; }
.rsvp__via .link { font-size: inherit; }
.rsvp__via .link[aria-pressed="true"] { color: var(--ink); font-weight: 700; }
.contact { margin-top: 44px; }
.contact .eyebrow { margin-bottom: 6px; }
.phone { display: inline-block; font-family: var(--f-display); font-style: italic; font-size: 2.2rem; font-weight: 400; color: var(--terra-d); text-decoration: none; padding: 6px; font-variation-settings: "SOFT" 100; }
.phone:hover { color: var(--ink); }
.contact__who { margin: 2px 0 0; font-size: .92rem; color: var(--ink-2); }

/* footer */
.foot { padding: 84px var(--pad) 60px; text-align: center; background: var(--ink); color: var(--linen); }
.foot__lemon { width: 46px; height: 46px; margin: 0 auto 12px; }
.foot .script { color: #E9B766; font-size: 2.4rem; margin-bottom: 4px; }
.foot__names { margin: 0 0 8px; font-family: var(--f-display); font-style: italic; font-weight: 300; font-size: 2.8rem; line-height: 1.1; font-variation-settings: "SOFT" 100; }
.foot__names i { font-family: var(--f-script); font-size: 1.1em; color: #E9B766; padding: 0 .08em; }
.foot__tag { margin: 0 0 28px; font-size: .78rem; font-weight: 600; letter-spacing: .28em; color: rgba(247,240,227,.78); padding-left: .28em; }
.foot__top { display: inline-block; font-size: .7rem; font-weight: 700; letter-spacing: .28em; text-transform: uppercase; color: rgba(247,240,227,.85); text-decoration: none; border-bottom: 1px solid #E9B766; padding: 8px 0 6px; }
.foot__top:hover { color: #fff; }
.foot :focus-visible { outline-color: #E9B766; }

/* scroll reveal */
.js .rv { opacity: 0; transform: translateY(18px); transition: opacity .9s ease, transform .9s var(--ease); transition-delay: var(--d, 0s); }
.js .rv.in { opacity: 1; transform: none; }
.js .cal.rv { transform: translateY(18px) rotate(-1.2deg); } .js .cal.rv.in { transform: rotate(-1.2deg); }
.js .postcard.rv { transform: translateY(18px) rotate(-2.4deg); } .js .postcard.rv.in { transform: rotate(-2.4deg); }

/* ================= WIDE (desktop & tablet landscape) ================= */
@media (min-width: 900px) {
  :root { --pad: 56px; }
  body { font-size: 17px; }
  .eyebrow { font-size: .76rem; }
  .btn { min-height: 58px; padding: 0 38px; }

  .env__seal { width: 196px; }
  .env__pulse { width: 148px; height: 148px; margin: -74px 0 0 -74px; }
  .env__card { left: 30%; right: 30%; top: 9%; bottom: 8%; }
  .env__card-mono { font-size: 7rem; }
  .env__card-lemon { width: 56px; height: 56px; }
  .env__top { font-size: 2.2rem; top: 9%; }
  .env__hint { font-size: .8rem; top: 66%; }
  .env__stamp { width: 84px; right: 7%; top: 22%; }
  .env__postmark { width: 140px; right: 10%; top: 29%; }
  .env__to { font-size: 3.2rem; top: 80%; }
  .env__piece::before, .env__flap-front::before { padding: 16px; }

  .hero { padding: 312px 40px 250px; }
  .hero__garland { width: 94%; top: -1%; }
  .hero__lantern { width: clamp(108px, 8.4vw, 130px); }
  .hero__table { width: clamp(440px, 34vw, 540px); bottom: -10px; }
  .hero__body { max-width: 1100px; }
  .names { white-space: nowrap; font-size: clamp(4.4rem, 7.2vw, 7rem); display: flex; justify-content: center; align-items: baseline; gap: .2em; }
  .names__g, .names__l2 { transform: none; }
  .names__l2 { display: contents; }
  .names__amp { font-size: 1em; }
  .hero__eyebrow { font-size: .84rem; margin-bottom: 22px; }
  .hero__date { margin-top: 22px; font-size: 1.5rem; }
  .hero__place { font-size: .8rem; }

  .sec { padding: 132px var(--pad) 100px; }
  .sec > .split { max-width: 1040px; }
  .sec > .lights { max-width: none; margin: 0; }
  .script { font-size: 3.4rem; }
  .h2 { font-size: 3.2rem; }
  .lead { font-size: 4.4rem; max-width: 12em; }
  .lead span { font-size: 1.15rem; max-width: 30em; }
  .body { font-size: 1.08rem; }

  .split { grid-template-columns: 1fr 1fr; align-items: center; gap: 80px; text-align: left; margin-top: 28px; }
  .split .cal { margin: 0 0 0 auto; width: min(100%, 400px); }
  .split .cal__g { font-size: 1.02rem; padding: 16px 20px 22px; }
  .split .cal__m { font-size: 1.7rem; padding: 18px 10px 16px; }
  .split .body { margin-left: 0; }
  .split .count { margin-left: 0; margin-right: auto; max-width: 440px; }
  .split .actions { justify-items: start; }
  .split--venue .postcard { margin: 12px 0 12px auto; width: min(100%, 360px); }
  .split--venue .split__text .h2 { font-size: 3.6rem; }
  .split--rsvp { align-items: start; }
  .split--rsvp .rsvp { margin: 0 0 0 auto; width: 100%; }
  .split--rsvp .contact { margin: 0; text-align: left; align-self: center; }
  .split--rsvp .phone { font-size: 2.8rem; padding-left: 0; }
  .sec--venue .eyebrow, .sec--date .eyebrow, .sec--date .h2 { text-align: center; }

  .menu { max-width: 600px; padding: 44px 44px 34px; }
  .menu__row h3 { font-size: 1.8rem; }
  .menu__row time { font-size: .9rem; }
  .menu__list p { font-size: 1rem; }
  .chips { max-width: 720px; gap: 24px 28px; }
  .chips li { width: 116px; font-size: .7rem; padding: 9px 9px 12px; }
  .chips span { height: 96px; }
  .chips b { font-size: .62rem; }
  .hotels { grid-template-columns: repeat(3, 1fr); max-width: 1040px; gap: 22px; }
  .hotel { padding: 28px 24px 26px; border-left: 0; border-top: 6px solid var(--olive); }
  .hotel:nth-child(2) { border-top-color: var(--ochre); } .hotel:nth-child(3) { border-top-color: var(--terra); }
  .hotel::before { display: none; }
  .routes { grid-template-columns: 1fr 1fr; max-width: 900px; gap: 24px; }
  .shuttle { max-width: 900px; padding: 40px 40px 36px; }
  .shuttle__t { font-size: 4.6rem; }
  .shuttle__d { font-size: 1.02rem; }
  .rsvp__btns { grid-template-columns: 1fr 1fr; }
  .count b { font-size: 2.6rem; }
  .foot { padding: 110px var(--pad) 80px; }
  .foot__names { font-size: 4rem; }
}

@media (min-width: 900px) and (max-height: 800px) {
  .hero { padding-top: 312px; padding-bottom: 250px; }
}

/* very small phones */
@media (max-width: 359px) {
  :root { --pad: 18px; }
  .btn { padding: 0 18px; letter-spacing: .12em; }
  .chips li { width: 80px; font-size: .56rem; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .js .rv { opacity: 1; transform: none; }
  .js .cal.rv { transform: rotate(-1.2deg); } .js .postcard.rv { transform: rotate(-2.4deg); }
  .opened .hero__garland, .opened .hero__table, .opened .hero__lantern, .opened .hero__eyebrow, .opened .names__a i, .opened .names__amp, .opened .hero__date, .opened .hero__place { opacity: 1; }
  .opened .hero__garland, .opened .hero__table, .opened .hero__lantern { transform: translateX(-50%); }
}
