/* Harvest (Thanksgiving): built from the Canva layout. Sizes are design pixels (the design is
   735 px wide), scaled to the screen with --p (1 design pixel). */
.theme-harvest {
  --p: calc(min(100vw, 480px) / 735);
  --rust: #a74e2e;
  --cream: #f9ecd7;
  --ink: #a0563c;
  --ink-dark: #7a3420;
  --light: #fbe6d6;
  --label: #f6d8c4;
  --gold: #f6c071;
  --script: "Fleur De Leah", "Pinyon Script", cursive;
  --venue: "Fleur De Leah", "Pinyon Script", cursive;
  --body: "EB Garamond", Georgia, serif;
  background: #6f2c15;
  color: var(--ink);
  font-family: var(--body);
}
.hv { max-width: 480px; margin: 0 auto; background: var(--rust); overflow: hidden; position: relative; }
.hv img { display: block; max-width: none; }

/* Absolute placement in design pixels */
.hv-blk { position: relative; }
.hv-abs { position: absolute; left: calc(var(--p) * var(--x)); top: calc(var(--p) * var(--y)); width: calc(var(--p) * var(--w)); }
.hv-t { margin: 0; text-align: center; font-size: calc(var(--p) * var(--fs)); line-height: calc(var(--p) * var(--lh)); font-weight: 400; }
.hv-t--caps { text-transform: uppercase; letter-spacing: .04em; }
.hv-t--caps b { font-weight: 400; }
.hv-t--sc { font-variant: small-caps; letter-spacing: .06em; }
.hv-t--script { font-family: var(--script); }
.hv-t--venue { font-family: var(--venue); color: var(--ink-dark); }
.hv-t--party { font-family: "Tinos", "Times New Roman", serif; text-transform: uppercase; color: var(--ink-dark); }
.hv-link { display: block; color: inherit; text-decoration: none; }
.hv-link:hover { text-decoration: underline; text-underline-offset: 4px; }

/* 1. Cover (video) */
.hv-cover { position: relative; aspect-ratio: 896 / 1920; background: var(--rust); }
.hv-cover__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; background: var(--rust); }
.hv-cover__tap { position: absolute; inset: 0; z-index: 2; border: 0; background: transparent; cursor: pointer; color: #fff; font: 400 calc(var(--p) * 29.6) / 1 var(--body); letter-spacing: .06em; }
.hv-cover__tap span { position: absolute; left: 0; right: 0; bottom: 10%; text-transform: uppercase; text-shadow: 0 1px 3px rgba(60, 20, 5, .7), 0 0 16px rgba(60, 20, 5, .5); animation: hv-pulse 2.4s ease-in-out infinite; }
@keyframes hv-pulse { 50% { opacity: .65; } }
body.is-open .hv-cover__tap { opacity: 0; pointer-events: none; transition: opacity .5s; }
.hv-cover__title { position: absolute; left: 0; right: 0; top: 30%; z-index: 1; text-align: center; color: var(--light); }
.hv-cover__title[hidden] { display: none; }
.hv-cover__eyebrow { margin: 0; font-size: calc(var(--p) * 34); letter-spacing: .05em; text-transform: uppercase; }
.hv-cover__names { margin: calc(var(--p) * 10) 0; font: 400 calc(var(--p) * 92) / 1.15 var(--script); }
.hv-cover__date { margin: 0; font-size: calc(var(--p) * 36); letter-spacing: .05em; }
.hv-cover__date b { font-weight: 400; font-size: 1.6em; }
.hv-cover__date sup { font-size: .5em; }
/* Without the video: a still rust cover with the title (the tap only scrolls on) */
.hv-cover--still { aspect-ratio: 735 / 1300; background: radial-gradient(120% 80% at 50% 40%, #b65a37, var(--rust) 60%, #8a3d22); }

/* 2. Cream paper (countdown to cornucopia, design y 0 to 4128; lace to 4194) */
.hv-cream {
  height: calc(var(--p) * 4160);
  background:
    linear-gradient(to bottom, transparent calc(var(--p) * 4128), var(--rust) 0),
    var(--cream) url("img/paper.webp") top center / 100% auto repeat-y;
}
.hv-cream .hv-t--caps { color: var(--ink); }
.hv-cream [data-countdown] b { font-weight: 400; }
.hv-lace {
  position: absolute; left: 0; right: 0; top: calc(var(--p) * 4126); height: calc(var(--p) * 68); z-index: 2; pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 92 68'%3E%3Cg fill='%23f6dccb'%3E%3Crect width='92' height='16'/%3E%3Cpath d='M2 14h88a44 44 0 0 1-88 0z'/%3E%3Cg%3E%3Ccircle cx='4' cy='24' r='4.5'/%3E%3Ccircle cx='7' cy='35' r='4.5'/%3E%3Ccircle cx='13' cy='45' r='4.5'/%3E%3Ccircle cx='21' cy='53' r='4.5'/%3E%3Ccircle cx='31' cy='58' r='4.5'/%3E%3Ccircle cx='41' cy='60' r='4.5'/%3E%3Ccircle cx='51' cy='60' r='4.5'/%3E%3Ccircle cx='61' cy='58' r='4.5'/%3E%3Ccircle cx='71' cy='53' r='4.5'/%3E%3Ccircle cx='79' cy='45' r='4.5'/%3E%3Ccircle cx='85' cy='35' r='4.5'/%3E%3Ccircle cx='88' cy='24' r='4.5'/%3E%3C/g%3E%3C/g%3E%3Cg fill='%23a8644b'%3E%3Crect x='6' y='6' width='5' height='3.4' rx='1.7'/%3E%3Crect x='14' y='6' width='5' height='3.4' rx='1.7'/%3E%3Crect x='22' y='6' width='5' height='3.4' rx='1.7'/%3E%3Crect x='30' y='6' width='5' height='3.4' rx='1.7'/%3E%3Crect x='38' y='6' width='5' height='3.4' rx='1.7'/%3E%3Crect x='49' y='6' width='5' height='3.4' rx='1.7'/%3E%3Crect x='57' y='6' width='5' height='3.4' rx='1.7'/%3E%3Crect x='65' y='6' width='5' height='3.4' rx='1.7'/%3E%3Crect x='73' y='6' width='5' height='3.4' rx='1.7'/%3E%3Crect x='81' y='6' width='5' height='3.4' rx='1.7'/%3E%3Ccircle cx='0' cy='7.7' r='3'/%3E%3Ccircle cx='46' cy='7.7' r='3'/%3E%3Ccircle cx='92' cy='7.7' r='3'/%3E%3Ccircle cx='46' cy='20' r='3.6'/%3E%3Cpath d='M46 25c2.5 5 2.5 15 0 22c-2.5-7-2.5-17 0-22z'/%3E%3Cpath d='M43 23c-2 7-7 14-13 18c2-7 7-14 13-18z'/%3E%3Cpath d='M49 23c2 7 7 14 13 18c-2-7-7-14-13-18z'/%3E%3Cpath d='M41 20c-6 3-14 5-22 5c6-4 14-6 22-5z'/%3E%3Cpath d='M51 20c6 3 14 5 22 5c-6-4-14-6-22-5z'/%3E%3Ccircle cx='12' cy='27' r='1.8'/%3E%3Ccircle cx='16' cy='38' r='1.8'/%3E%3Ccircle cx='24' cy='47' r='1.8'/%3E%3Ccircle cx='35' cy='52' r='1.8'/%3E%3Ccircle cx='46' cy='54' r='1.8'/%3E%3Ccircle cx='57' cy='52' r='1.8'/%3E%3Ccircle cx='68' cy='47' r='1.8'/%3E%3Ccircle cx='76' cy='38' r='1.8'/%3E%3Ccircle cx='80' cy='27' r='1.8'/%3E%3C/g%3E%3C/svg%3E") left top / calc(var(--p) * 91.875) 100% repeat-x;
}

/* 3. RSVP and the envelope (design y 4160 to 5385) */
.hv-rsvp { height: calc(var(--p) * 1225); background: var(--rust); }
.hv-t--rsvp { color: var(--light); letter-spacing: .04em; }
.hv-t--note { color: var(--light); font-variant: small-caps; letter-spacing: .05em; }
.hv-t--note sup { font-size: .55em; }
.hv-env {
  position: absolute; left: calc(var(--p) * var(--x)); top: calc(var(--p) * var(--y)); width: calc(var(--p) * var(--w));
  height: calc(var(--p) * 360); padding: 0; border: 0; background: transparent; cursor: pointer; color: var(--light); font-family: var(--body);
}
.hv-env img { position: absolute; left: 0; width: 100%; transition: opacity .6s ease, transform .6s ease; }
.hv-env__closed { top: 0; }
.hv-env__open { bottom: 0; opacity: 0; transform: translateY(4%); }
.hv-env__tap { position: absolute; left: -20%; right: -20%; top: calc(var(--p) * 347); color: var(--light); animation: hv-pulse 2.4s ease-in-out infinite; }
.hv-env:hover .hv-env__closed { transform: translateY(-1.5%); }
.hv-env.is-open { cursor: default; }
.hv-env.is-open .hv-env__closed { opacity: 0; }
.hv-env.is-open .hv-env__open { opacity: 1; transform: none; }
.hv-env.is-open .hv-env__tap { opacity: 0; animation: none; transition: opacity .3s; }

/* 4. RSVP form (opens from the envelope) */
.hv-form-wrap { position: relative; background: var(--rust); padding: calc(var(--p) * 6) calc(var(--p) * 49) calc(var(--p) * 12) calc(var(--p) * 51); }
.hv-form-wrap[hidden] { display: none; }
.hv-form-wrap.is-in { animation: hv-in .8s ease both; }
@keyframes hv-in { from { opacity: 0; transform: translateY(calc(var(--p) * -30)); } }
.hv-basket { position: absolute; left: calc(var(--p) * 429); top: calc(var(--p) * 233); width: calc(var(--p) * 305); pointer-events: none; z-index: 0; }
.hv-form { position: relative; z-index: 1; display: block; text-align: left; }
.hv-form .inv-field { display: block; margin: 0; }
.hv-form .inv-field > span, .hv-form .inv-field legend {
  display: block; color: var(--label); font: 400 calc(var(--p) * 33) / calc(var(--p) * 40) var(--body);
  font-variant: small-caps; letter-spacing: .05em; padding: 0; margin: 0 0 calc(var(--p) * 26);
}
.hv-form input:not([type="radio"]), .hv-form select, .hv-form textarea {
  display: block; width: 100%; font: 400 calc(var(--p) * 24) / 1.4 var(--body); letter-spacing: .08em; color: var(--label);
  background: rgba(150, 64, 35, .45); border: 1.5px solid rgba(246, 216, 196, .6); border-radius: 0; padding: calc(var(--p) * 18) calc(var(--p) * 22);
}
.hv-form input:not([type="radio"]) { height: calc(var(--p) * 81); }
.hv-form textarea { height: calc(var(--p) * 188); resize: vertical; }
.hv-form select option { color: #4a1a08; }
.hv-form ::placeholder { color: rgba(246, 216, 196, .55); text-transform: uppercase; }
.hv-form input:focus, .hv-form select:focus, .hv-form textarea:focus { outline: 1px solid var(--label); outline-offset: 0; }
.hv-form > .inv-field + .inv-field, .hv-form > .inv-field + .inv-if-yes, .hv-form > .inv-if-yes + .inv-field, .hv-form .inv-if-yes > .inv-field + .inv-field { margin-top: calc(var(--p) * 58); }
.hv-form .inv-if-yes { display: block; margin-top: calc(var(--p) * 58); }
.hv-form.is-no .inv-if-yes { display: none; }
.hv-form .inv-choice { display: block; border: 0; padding: 0; }
.hv-form .inv-choice legend { margin-bottom: calc(var(--p) * 21); }
.hv-form .inv-choice label {
  display: flex; align-items: center; gap: calc(var(--p) * 14); background: transparent; border: 0; padding: 0; margin: 0; min-height: 0; width: max-content;
  color: rgba(246, 216, 196, .72); font: 400 calc(var(--p) * 31) / calc(var(--p) * 40) var(--body); font-variant: small-caps; letter-spacing: .08em; cursor: pointer;
}
.hv-form .inv-choice input {
  appearance: none; -webkit-appearance: none; flex: none; box-sizing: border-box; margin: 0; padding: 0;
  width: calc(var(--p) * 30); height: calc(var(--p) * 30); border: 1.2px solid var(--label); border-radius: 50%; background: transparent; cursor: pointer;
}
.hv-form .inv-choice input:checked { background: radial-gradient(circle, var(--label) 0 42%, transparent 46%); }
.hv-form .inv-field > span { max-width: calc(var(--p) * 560); }
.hv-form .inv-form__status { margin: 0; color: var(--label); font-size: calc(var(--p) * 26); }
.hv-form .inv-form__status:empty { display: none; }
.hv-form .inv-form__status:not(:empty) { margin-top: calc(var(--p) * 24); }
.hv-send {
  display: flex; align-items: center; justify-content: center; gap: calc(var(--p) * 12); width: 100%; height: calc(var(--p) * 79); margin-top: calc(var(--p) * 66);
  border: 0; border-radius: 0; background: #d1c4b1; color: var(--ink-dark); cursor: pointer;
  font: 400 calc(var(--p) * 24.5) / 1 var(--body); letter-spacing: .06em; text-transform: uppercase;
}
.hv-send svg { width: calc(var(--p) * 32); height: calc(var(--p) * 32); }
.hv-send[disabled] { opacity: .6; }
.hv-reveal { background: transparent; border: 1.5px solid rgba(246, 216, 196, .5); border-radius: 0; color: var(--light); margin-top: calc(var(--p) * 40); }

/* 5. Closing (design y 6821 to 8037) */
.hv-closing { height: calc(var(--p) * 1216); background: var(--rust); }
.hv-t--gold {
  font-family: var(--script); color: var(--gold);
  background: linear-gradient(180deg, #ffd88f 0%, #f3b65c 55%, #e9a54a 100%); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.hv-t--light { color: var(--light); }
.hv-credit { color: rgba(251, 230, 214, .85); font-variant: small-caps; letter-spacing: .05em; z-index: 1; }
.hv-credit a { color: inherit; }
