:root {
  --ink: #2f2523;
  --muted: #6f6561;
  --line: rgba(84, 56, 47, 0.12);
  --paper: rgba(255, 251, 247, 0.82);
  --paper-strong: rgba(255, 251, 247, 0.95);
  --blush: #d9b1ad;
  --rose: #b7787e;
  --wine: #7d4955;
  --gold: #caa56a;
  --gold-soft: #ead7b2;
  --success: #2d6f4f;
  --danger: #9d2f39;
  --shadow: 0 26px 70px rgba(55, 31, 27, 0.14);
  --shadow-soft: 0 14px 34px rgba(55, 31, 27, 0.08);
  --radius-xl: 34px;
  --radius-lg: 26px;
  --radius-md: 18px;
  --container: min(1200px, calc(100vw - 32px));
  --hero-image: url("../uploads/Argie+Mhae%20(8).jpg");
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  color-scheme: light;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  color: var(--ink);
  font-family: "Manrope", "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(238, 214, 208, 0.95), transparent 34%),
    radial-gradient(circle at right 12% top 18%, rgba(202, 165, 106, 0.18), transparent 22%),
    radial-gradient(circle at left 15% bottom 20%, rgba(183, 120, 126, 0.18), transparent 30%),
    linear-gradient(180deg, #fcf7f2 0%, #f5ece3 45%, #f1e3d9 100%);
}

body::before,
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

body::before {
  background:
    radial-gradient(circle at 20% 18%, rgba(255, 255, 255, 0.8), transparent 16%),
    radial-gradient(circle at 82% 26%, rgba(255, 255, 255, 0.5), transparent 14%),
    radial-gradient(circle at 32% 72%, rgba(255, 255, 255, 0.35), transparent 14%);
  filter: blur(26px);
}

body::after {
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.08) 1px, transparent 1px);
  background-size: 130px 130px;
  opacity: 0.14;
}

img,
iframe {
  max-width: 100%;
  display: block;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  appearance: none;
  -webkit-appearance: none;
}

.shell {
  position: relative;
  z-index: 1;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  padding-top: env(safe-area-inset-top, 0px);
  background: rgba(250, 243, 236, 0.68);
  border-bottom: 1px solid rgba(84, 56, 47, 0.08);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}

.topbar-inner,
.page {
  width: var(--container);
  margin: 0 auto;
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
}

.brand-mark {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, rgba(183, 120, 126, 0.22), rgba(202, 165, 106, 0.18));
  border: 1px solid rgba(183, 120, 126, 0.2);
  color: var(--wine);
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: 0.06em;
}

.brand-copy {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.brand-copy strong {
  font-size: 0.82rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.brand-copy span {
  color: var(--muted);
  font-size: 0.83rem;
}

.navlinks {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.navlinks a,
.navlinks button,
.button {
  border: 1px solid rgba(84, 56, 47, 0.11);
  border-radius: 999px;
  background: rgba(255, 251, 247, 0.84);
  color: var(--ink);
  text-decoration: none;
  cursor: pointer;
  min-height: 50px;
  padding: 12px 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}

.navlinks a:hover,
.navlinks button:hover,
.button:hover,
.panel-card:hover,
.story-card:hover,
.note-card:hover,
.thumb:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-soft);
  border-color: rgba(183, 120, 126, 0.26);
}

.button-primary {
  background: linear-gradient(135deg, rgba(183, 120, 126, 0.96), rgba(202, 165, 106, 0.96));
  color: #fff9f4;
  border-color: transparent;
}

.button-secondary {
  background: rgba(255, 251, 247, 0.78);
}

.page {
  padding: 28px 0 calc(88px + env(safe-area-inset-bottom, 0px));
}

.hero,
.section,
.panel-card,
.lightbox-panel,
.modal-card {
  border: 1px solid var(--line);
  background: var(--paper);
  box-shadow: var(--shadow);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
  gap: 24px;
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-xl);
  padding: clamp(30px, 5vw, 54px);
  min-height: 560px;
}

.hero::before {
  content: "";
  position: absolute;
  inset: -24% auto auto -14%;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.7), transparent 62%);
}

.hero::after {
  content: "";
  position: absolute;
  right: -8%;
  bottom: -18%;
  width: 360px;
  height: 360px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(183, 120, 126, 0.18), transparent 68%);
  filter: blur(12px);
}

.hero-copy-block,
.hero-side-block {
  position: relative;
  z-index: 1;
}

.hero-side-block {
  display: grid;
  gap: 16px;
}

.hero-kicker,
.section-kicker,
.eyebrow-label,
.veil-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 0.72rem;
  color: var(--wine);
}

.hero-script,
.veil-script {
  margin: 0;
  color: var(--rose);
  font-family: "Great Vibes", cursive;
  font-size: clamp(2rem, 6vw, 3rem);
  line-height: 1.1;
}

.hero-names,
.section h2,
.veil-card h1 {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-weight: 600;
}

.hero-names {
  margin-top: 8px;
  font-size: clamp(3.4rem, 10vw, 6rem);
  line-height: 0.92;
}

.hero-copy,
.muted-copy,
.status-note,
.countdown-date,
.footer p,
.quote-source {
  color: var(--muted);
}

.hero-copy {
  max-width: 62ch;
  margin: 18px 0 0;
  font-size: 1.02rem;
  line-height: 1.85;
}

.hero-actions,
.veil-actions,
.button-row,
.modal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero-actions {
  margin-top: 26px;
}

.highlight-grid,
.story-grid,
.details-grid,
.venue-grid,
.notes-grid,
.directions-grid,
.rsvp-top-grid,
.rsvp-grid,
.gallery-top-grid,
.gallery-grid {
  display: grid;
  gap: 16px;
}

.highlight-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 28px;
}

.highlight-card,
.countdown-card,
.hero-photo-card,
.story-card,
.timeline-card,
.venue-card,
.note-card,
.form-card,
.qr-card,
.rsvp-info-card,
.upload-card,
.gallery-note-card,
.quote-card {
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.highlight-card {
  padding: 16px 18px;
  background: rgba(255, 251, 247, 0.72);
  border: 1px solid rgba(84, 56, 47, 0.08);
}

.highlight-card strong {
  display: block;
  margin-bottom: 6px;
  color: var(--wine);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 0.8rem;
}

.highlight-card span {
  color: var(--muted);
  line-height: 1.7;
}

.panel-card {
  padding: 22px;
}

.countdown-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.countdown-grid div {
  padding: 16px 12px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.64);
  border: 1px solid rgba(84, 56, 47, 0.08);
  text-align: center;
}

.countdown-grid strong {
  display: block;
  color: var(--wine);
  font-size: clamp(1.4rem, 4vw, 2rem);
}

.countdown-grid span {
  font-size: 0.76rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.countdown-date {
  margin: 14px 0 0;
  line-height: 1.7;
}

.hero-photo-card {
  min-height: 320px;
  padding: 0;
  background:
    linear-gradient(180deg, rgba(46, 37, 33, 0.04), rgba(46, 37, 33, 0.16)),
    var(--hero-image) center / cover;
}

.hero-photo-note {
  display: grid;
  gap: 8px;
}

.hero-photo-note .eyebrow-label {
  margin-bottom: 0;
}

.hero-photo-note strong {
  display: block;
  color: var(--wine);
  font-size: 1.16rem;
}

.hero-photo-note p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.section {
  margin-top: 28px;
  border-radius: var(--radius-xl);
  padding: clamp(24px, 4vw, 34px);
}

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 18px;
  flex-wrap: wrap;
  margin-bottom: 22px;
}

.section h2 {
  font-size: clamp(2.4rem, 5vw, 3.4rem);
}

.section-heading > p {
  max-width: 46ch;
  margin: 0;
  color: var(--muted);
  line-height: 1.8;
}

.story-grid {
  grid-template-columns: 1.2fr repeat(3, minmax(0, 1fr));
}

.story-card h3,
.timeline-card h3,
.venue-card h3,
.note-card h3,
.directions-copy-card h3,
.form-card h3,
.qr-card h3,
.rsvp-info-card h3,
.upload-card h3,
.gallery-note-card h3 {
  margin-top: 0;
  margin-bottom: 12px;
  font-size: 1.14rem;
}

.story-card p,
.timeline-card p,
.venue-card p,
.note-card p,
.muted-copy,
.status-note,
.lightbox-header p,
.modal-header p,
.modal-body,
.detail-list li {
  line-height: 1.8;
}

.quote-card {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 28px;
  background: linear-gradient(160deg, rgba(183, 120, 126, 0.14), rgba(202, 165, 106, 0.14));
}

.quote-mark {
  margin: 0;
  color: var(--wine);
  font-family: "Great Vibes", cursive;
  font-size: 4.4rem;
  line-height: 0.6;
}

.quote-text {
  margin: 12px 0 16px;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.55rem;
  line-height: 1.4;
}

.quote-source {
  font-size: 0.92rem;
}

.details-grid,
.venue-grid,
.directions-grid,
.rsvp-top-grid,
.rsvp-grid,
.gallery-top-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.directions-image-card,
.directions-copy-card {
  border-radius: var(--radius-lg);
}

.directions-image-card {
  padding: 0;
  background: linear-gradient(180deg, rgba(9, 8, 10, 0.96), rgba(9, 8, 10, 0.92));
}

.directions-image-frame {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100%;
  padding: 18px;
}

.directions-image {
  width: 100%;
  max-height: 760px;
  object-fit: contain;
  border-radius: 22px;
  background: #060606;
}

.directions-copy-card {
  display: grid;
  align-content: center;
  gap: 16px;
}

.directions-copy-card h3 {
  margin-bottom: 0;
}

.directions-list {
  margin: 0;
}

.directions-actions {
  margin-top: 4px;
}
.notes-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 16px;
}

.detail-list {
  margin: 0;
  padding-left: 18px;
  display: grid;
  gap: 10px;
}

.venue-card iframe {
  width: 100%;
  height: 290px;
  margin-top: 16px;
  border: 0;
  border-radius: 18px;
}

.qr-card {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  align-items: center;
  gap: 18px;
}

.qr-code-box {
  min-height: 220px;
  border-radius: 22px;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(255, 255, 255, 0.64);
  border: 1px solid rgba(84, 56, 47, 0.08);
}

.field-group {
  display: grid;
  gap: 8px;
}

.field-group label {
  color: var(--muted);
  font-size: 0.9rem;
}

input,
select,
textarea {
  width: 100%;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(84, 56, 47, 0.12);
  background: rgba(255, 255, 255, 0.8);
  color: var(--ink);
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

input:focus,
select:focus,
textarea:focus {
  border-color: rgba(183, 120, 126, 0.44);
  box-shadow: 0 0 0 4px rgba(183, 120, 126, 0.12);
  background: rgba(255, 255, 255, 0.98);
}

textarea {
  min-height: 140px;
  resize: vertical;
}

.rsvp-form {
  margin-top: 16px;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.field-span-full {
  grid-column: 1 / -1;
}

.status-note {
  margin: 14px 0 0;
  font-size: 0.9rem;
}

.status-note.ok {
  color: var(--success);
}

.status-note.bad {
  color: var(--danger);
}

.upload-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 12px;
  align-items: end;
}

.upload-button {
  white-space: nowrap;
}

.gallery-grid {
  grid-template-columns: 1fr;
  margin-top: 20px;
}

.gallery-grid > p {
  grid-column: 1 / -1;
  margin: 0;
}

.gallery-page {
  border: 1px solid rgba(84, 56, 47, 0.08);
  border-radius: 28px;
  padding: 18px;
  background: rgba(255, 251, 247, 0.72);
  box-shadow: var(--shadow-soft);
}

.gallery-page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.gallery-page-title {
  margin: 0;
  color: var(--wine);
  font-size: 1.15rem;
}

.gallery-page-count {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(202, 165, 106, 0.16);
  color: var(--wine);
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.gallery-page-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px;
}

.gallery-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 18px;
}

.gallery-pagination-info {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.gallery-pagination-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.gallery-pagination .button[disabled] {
  opacity: 0.52;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.thumb {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid rgba(84, 56, 47, 0.08);
  background: rgba(255, 255, 255, 0.7);
  cursor: zoom-in;
  padding: 0;
  color: inherit;
  aspect-ratio: 4 / 5;
}

.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.thumb::after {
  content: "View";
  position: absolute;
  right: 14px;
  bottom: 14px;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(25, 16, 14, 0.42);
  color: #fff8f4;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.footer {
  text-align: center;
  padding: 36px 0 10px;
}

.footer strong {
  color: var(--wine);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 0.82rem;
}

.footer p {
  margin: 10px 0 0;
}

#petals {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 2;
  opacity: 0.72;
}

.lightbox,
.modal,
.veil {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  z-index: 60;
}

.lightbox.show,
.modal.show,
.veil.show {
  display: flex;
}

.lightbox,
.modal {
  background: rgba(25, 16, 14, 0.7);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

.lightbox-panel,
.modal-card,
.veil-card {
  border-radius: 30px;
}

.lightbox-panel {
  width: min(960px, 100%);
  overflow: hidden;
}

.lightbox-header,
.modal-header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 18px 20px;
  border-bottom: 1px solid rgba(84, 56, 47, 0.08);
}

.lightbox-header p,
.modal-header p {
  margin: 0;
}

.lightbox-image {
  width: 100%;
  max-height: 78vh;
  object-fit: contain;
  background: rgba(246, 234, 226, 0.78);
}

.modal-card {
  width: min(540px, 100%);
}

.modal-body {
  padding: 20px;
}

.veil {
  background:
    radial-gradient(circle at 50% 20%, rgba(255, 255, 255, 0.64), transparent 24%),
    linear-gradient(180deg, rgba(246, 236, 227, 0.98), rgba(239, 224, 213, 0.98));
}

.veil-card {
  width: min(660px, calc(100vw - 36px));
  padding: 34px 28px;
  text-align: center;
  background: rgba(255, 251, 247, 0.78);
  border: 1px solid rgba(84, 56, 47, 0.08);
  box-shadow: 0 34px 100px rgba(53, 32, 28, 0.16);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
}

.veil-card h1 {
  font-size: clamp(3rem, 9vw, 4.8rem);
  line-height: 0.94;
}

.veil-copy {
  max-width: 38ch;
  margin: 16px auto 0;
  color: var(--muted);
  line-height: 1.8;
}

.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.in {
  opacity: 1;
  transform: translateY(0);
}

@supports not ((backdrop-filter: blur(18px)) or (-webkit-backdrop-filter: blur(18px))) {
  .topbar,
  .hero,
  .section,
  .panel-card,
  .lightbox-panel,
  .modal-card,
  .veil-card {
    background: rgba(255, 251, 247, 0.97);
  }
}

@supports not (aspect-ratio: 4 / 5) {
  .thumb {
    height: 320px;
  }
}

@media (max-width: 1080px) {
  .hero,
  .story-grid,
  .details-grid,
  .venue-grid,
  .notes-grid,
  .directions-grid,
  .rsvp-top-grid,
  .rsvp-grid,
  .gallery-top-grid,
  .gallery-grid,
  .highlight-grid,
  .upload-grid,
  .qr-card,
  .form-grid {
    grid-template-columns: 1fr;
  }

  .gallery-page-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .upload-button {
    width: 100%;
  }
}

@media (max-width: 720px) {
  .topbar-inner {
    align-items: start;
    flex-direction: column;
  }

  .navlinks {
    width: 100%;
  }

  .navlinks a,
  .navlinks button,
  .button-row .button,
  .hero-actions .button,
  .veil-actions .button,
  .modal-actions .button {
    width: 100%;
  }

  .countdown-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .gallery-page-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  body::after {
    display: none;
  }

  .page {
    padding: 18px 0 calc(72px + env(safe-area-inset-bottom, 0px));
  }

  .hero,
  .section,
  .panel-card,
  .lightbox-panel,
  .modal-card,
  .veil-card {
    border-radius: 24px;
  }

  .brand {
    width: 100%;
    justify-content: space-between;
  }

  .brand-copy strong {
    letter-spacing: 0.16em;
  }

  .hero {
    padding: 24px 20px;
  }

  .hero-names {
    font-size: clamp(2.8rem, 16vw, 4.2rem);
  }

  .hero-script,
  .veil-script {
    font-size: clamp(1.7rem, 10vw, 2.4rem);
  }

  .hero-kicker,
  .section-kicker,
  .eyebrow-label {
    width: 100%;
    justify-content: center;
  }

  .hero-photo-card {
    min-height: 250px;
  }

  .gallery-page {
    padding: 16px;
  }

  .gallery-page-grid {
    grid-template-columns: 1fr;
  }

  .venue-card iframe {
    height: 240px;
  }

  .lightbox,
  .modal,
  .veil {
    padding: 12px;
  }

  .lightbox-header,
  .modal-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .lightbox-header .button,
  .modal-header .button {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}