@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@200;300&family=Vazirmatn:wght@300;400;500&display=swap');

:root {
  --ivory: #fffefe;
  --paper: #ffffff;
  --blush: #d8b9b2;
  --blush-dark: #aa7f77;
  --blush-pale: #f7eeec;
  --ink: #2f2b2a;
  --muted: #7d7471;
  --line: rgba(170, 127, 119, 0.22);
  --shadow: 0 20px 50px rgba(92, 69, 64, 0.06);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-width: 320px;
  background: #f5f2f1;
  color: var(--ink);
  font-family: "Vazirmatn", Tahoma, sans-serif;
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
}
body.intro-open { overflow: hidden; }

.intro-cover {
  position: fixed;
  z-index: 100;
  inset: 0;
  width: 100%;
  min-height: 100%;
  padding: max(28px, env(safe-area-inset-top)) 24px max(28px, env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  border: 0;
  background: var(--paper);
  color: var(--ink);
  cursor: pointer;
  transition: opacity .65s ease, visibility .65s ease;
}
.hero {
  min-height: auto;
  padding-bottom: 10px;
}

.scroll-cue {
  margin-top: 28px;
}

.photo-section {
  padding-top: 10px;
}
.intro-cover::after { content: ""; position: absolute; width: 44px; height: 1px; margin-top: 150px; background: var(--blush); }
.intro-cover:focus-visible { outline: 2px solid var(--blush-dark); outline-offset: -8px; }
.intro-cover:active { transform: none; }
.intro-cover.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.intro-names { direction: ltr; font-family: Arial, Helvetica, sans-serif; font-size: clamp(43px, 13vw, 72px); font-weight: 300; line-height: 1; letter-spacing: -.07em; }
.intro-hello { color: var(--blush-dark); font-family: "Vazirmatn", sans-serif; font-size: 22px; font-weight: 400; }

.invitation {
  width: min(100%, 520px);
  margin: 0 auto;
  overflow: hidden;
  background: var(--ivory);
  box-shadow: var(--shadow);
}

.section {
  position: relative;
  min-height: 100svh;
  padding: 72px 26px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.hero { padding-top: max(90px, env(safe-area-inset-top)); background: var(--paper); }
.flower-space {
  width: 380px;
  height: 380px;
  margin-bottom: 24px;
}

.flower-space img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transform: scale(1.25);
}
.asset-hint { width: 130px; height: 130px; border: 1px dashed var(--blush); border-radius: 50%; display: grid; place-items: center; color: var(--blush-dark); font-size: 12px; }

.eyebrow { margin: 0 0 24px; color: var(--blush-dark); font-size: 11px; font-weight: 500; letter-spacing: .3em; direction: ltr; }
h1 {
  width: 100%;
  margin: 0;
  display: flex;
  flex-direction: column;
  direction: ltr;

  color: var(--ink);
  font-family: "Montserrat", sans-serif;
  font-size: clamp(72px, 22vw, 112px);
  font-weight: 200;
  line-height: 0.85;
  letter-spacing: 0.01em;
  text-transform: uppercase;
}

h1 i {
  margin: 22px 0 18px;
  color: var(--blush-dark);
  font-family: inherit;
  font-size: 0.36em;
  font-weight: 200;
  font-style: normal;
  letter-spacing: 0;
}
.hairline { width: 54px; height: 1px; margin: 44px 0 30px; background: var(--blush); }
.guest-greeting { margin: 0 0 10px; font-size: 21px; font-weight: 400; }
.intro, .muted { max-width: 350px; margin: 0; color: var(--muted); font-size: 16px; line-height: 2.05; }
.intro {
  width: 100%;
  direction: rtl;
  text-align: right;
}
.scroll-cue { margin-top: 42px; color: var(--blush-dark); font-size: 25px; text-decoration: none; animation: float 1.8s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(6px); } }

.photo-section { min-height: auto; padding: 10px 24px 10px; background: var(--paper); }
.photo-frame { position: relative; width: 100%; aspect-ratio: 4 / 5; overflow: hidden; background: var(--blush-pale); }
.photo-frame::after { content: ""; position: absolute; inset: 12px; border: 1px solid rgba(255,255,255,.6); pointer-events: none; }
.photo-frame img { position: relative; z-index: 2; width: 100%; height: 100%; object-fit: cover; }
.photo-placeholder { position: absolute; inset: 0; display: grid; place-content: center; gap: 8px; color: var(--blush-dark); }
.photo-placeholder span { font-family: Georgia, serif; font-size: 28px; }
.photo-placeholder small { font-size: 12px; direction: ltr; }
.photo-caption { margin: 26px 0 0; color: var(--blush-dark); font-size: 9px; letter-spacing: .24em; direction: ltr; }

.details { min-height: 76svh; }
h2 { margin: 0 0 14px; color: var(--ink); font-family: "Vazirmatn", sans-serif; font-size: clamp(48px, 15vw, 72px); font-weight: 300; line-height: 1.15; letter-spacing: -.04em; }
.event-time { margin: 0; color: var(--blush-dark); font-size: 18px; font-weight: 400; }
.venue-card { width: 100%; margin-top: 42px; padding: 28px 20px; display: grid; gap: 6px; border-block: 1px solid var(--line); }
.venue-card strong { color: var(--ink); font-size: 30px; font-weight: 300; }
.venue-card span:last-child { color: var(--muted); font-size: 15px; }
.venue-label { color: var(--blush-dark); font-size: 12px; }

.story-section { min-height: auto; padding-block: 74px; background: var(--blush-pale); }
.story-kicker { margin: 0 0 30px; color: var(--blush-dark); font-size: 11px; font-weight: 500; letter-spacing: .25em; direction: ltr; }
.story-art { position: relative; width: 100%; min-height: 520px; display: grid; place-items: center; }
.story-art img { position: relative; z-index: 2; width: 100%; height: auto; object-fit: contain; }
.story-placeholder { position: absolute; inset: 0; display: grid; place-content: center; gap: 8px; border: 1px dashed var(--blush); color: var(--blush-dark); }
.story-placeholder span { font-size: 26px; font-weight: 300; }
.story-placeholder small { font-size: 12px; direction: ltr; }

.music-control { position: fixed; z-index: 10; top: max(16px, env(safe-area-inset-top)); left: max(16px, env(safe-area-inset-left)); width: 46px; height: 46px; display: grid; place-items: center; border: 1px solid rgba(170,127,119,.35); border-radius: 50%; background: rgba(255,255,255,.82); color: var(--blush-dark); box-shadow: 0 6px 20px rgba(92,69,64,.08); backdrop-filter: blur(10px); cursor: pointer; font: 22px Georgia, serif; transition: transform .2s, opacity .2s; }
.music-control.is-playing span { animation: pulse 1.4s ease-in-out infinite; }
.music-control:not(.is-playing) { opacity: .55; }
@keyframes pulse { 50% { transform: scale(1.2); } }

.rsvp { min-height: auto; padding-block: 86px; background: var(--paper); }
form { width: 100%; margin-top: 38px; text-align: right; }
fieldset { margin: 0; padding: 0; border: 0; }
legend, .note-field > span { margin-bottom: 14px; color: var(--ink); font-size: 16px; font-weight: 400; }
.attendance-options { display: grid; gap: 10px; }
.attendance-options label { cursor: pointer; }
.attendance-options input { position: absolute; opacity: 0; }
.attendance-options span { min-height: 58px; padding: 14px 16px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 2px; background: white; color: var(--muted); font-size: 15px; transition: .2s ease; }
.attendance-options input:checked + span { border-color: var(--blush-dark); background: var(--blush-dark); color: white; }
.attendance-options input:focus-visible + span { outline: 2px solid var(--blush); outline-offset: 2px; }
.note-field { margin-top: 26px; display: flex; flex-direction: column; }
textarea { width: 100%; resize: vertical; border: 1px solid var(--line); border-radius: 2px; outline: 0; background: white; color: var(--ink); padding: 15px; font: inherit; font-size: 15px; }
textarea:focus { border-color: var(--blush-dark); box-shadow: 0 0 0 3px rgba(216,185,178,.13); }
form > button { width: 100%; min-height: 58px; margin-top: 18px; border: 0; border-radius: 2px; background: var(--ink); color: white; cursor: pointer; font: inherit; font-size: 16px; transition: transform .2s, opacity .2s; }
button:active { transform: scale(.99); }
button:disabled { cursor: wait; opacity: .6; }
.form-message { min-height: 26px; margin: 14px 0 0; color: var(--blush-dark); text-align: center; font-size: 13px; }

.closing-photo-section { padding: 0 24px 72px; background: var(--paper); }
.closing-photo { position: relative; width: 100%; aspect-ratio: 4 / 5; overflow: hidden; background: var(--blush-pale); }
.closing-photo::after { content: ""; position: absolute; z-index: 3; inset: 12px; border: 1px solid rgba(255,255,255,.65); pointer-events: none; }
.closing-photo img { position: relative; z-index: 2; width: 100%; height: 100%; object-fit: cover; }
.closing-placeholder { position: absolute; inset: 0; display: grid; place-content: center; gap: 8px; color: var(--blush-dark); text-align: center; }
.closing-placeholder span { font-size: 28px; font-weight: 300; }
.closing-placeholder small { font-size: 12px; direction: ltr; }

footer { padding: 54px 20px max(48px, env(safe-area-inset-bottom)); display: flex; align-items: baseline; justify-content: center; flex-wrap: wrap; gap: 5px; background: var(--ink); color: var(--ivory); direction: ltr; font-family: Georgia, serif; font-size: 27px; }
footer i { color: var(--blush); font-family: "Great Vibes", cursive; font-size: 28px; }
footer small { flex-basis: 100%; margin-top: 10px; text-align: center; opacity: .7; font-family: "Vazirmatn", sans-serif; font-size: 10px; direction: rtl; }

@media (min-width: 521px) { body { padding-block: 28px; } .invitation { border-radius: 3px; } }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .scroll-cue, .music-control.is-playing span { animation: none; } }
#details-title {
  font-size: 35px;
}
.venue-card .map-link {
  display: inline-block;
  width: fit-content;
  margin: 14px auto 0;
  padding: 8px 16px;

  color: var(--blush-dark);
  background: var(--blush-pale);
  border: 1px solid var(--line);
  border-radius: 30px;

  font-family: "Vazirmatn", sans-serif;
  font-size: 12px;
  font-weight: 400;
  text-decoration: none;
  transition: 0.2s ease;
}

.venue-card .map-link:hover,
.venue-card .map-link:focus {
  color: white;
  background: var(--blush-dark);
  border-color: var(--blush-dark);
  text-decoration: none;
}
#rsvp-title {
  font-size: 24px;
  line-height: 1.4;
}
.name-field {
  margin-top: 0;
  margin-bottom: 26px;
}

.name-field input {
  width: 100%;
  padding: 15px;

  color: var(--ink);
  background: white;
  border: 1px solid var(--line);
  border-radius: 2px;
  outline: none;

  font-family: "Vazirmatn", sans-serif;
  font-size: 15px;
  text-align: right;
}

.name-field input:focus {
  border-color: var(--blush-dark);
  box-shadow: 0 0 0 3px rgba(216, 185, 178, 0.13);
}
