body {
  min-height: 100dvh;
  background:
    radial-gradient(ellipse 80% 60% at 50% 30%, var(--blush-centre) 0%, transparent 70%),
    linear-gradient(180deg, var(--blush-top), var(--blush-bottom)) fixed;
  color: var(--plum);
  overflow-x: hidden;
}

a {
  color: inherit;
}

.page-roses {
  position: fixed;
  width: clamp(180px, 30vw, 420px);
  pointer-events: none;
  z-index: 0;
}

.page-roses.tr { top: -4px; right: -4px; }
.page-roses.bl { bottom: -4px; left: -4px; transform: rotate(180deg); }

.page-frame {
  position: fixed;
  inset: clamp(10px, 2vw, 24px);
  border: 2px solid var(--gold);
  pointer-events: none;
  z-index: 0;
}

.page-frame::after {
  content: "";
  position: absolute;
  inset: 7px;
  border: 1px solid var(--gold-light);
}

.wrap {
  position: relative;
  z-index: 1;
  width: min(1080px, 100% - 48px);
  margin: 0 auto;
  padding: clamp(56px, 9vh, 96px) 0 80px;
}

/* Nav */
.nav {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: center;
  gap: clamp(18px, 4vw, 44px);
  padding: clamp(36px, 5vh, 52px) 16px 0;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.24em;
}

.nav a {
  color: var(--gold);
  text-decoration: none;
  padding-bottom: 4px;
  border-bottom: 1px solid transparent;
}

.nav a:hover,
.nav a[aria-current] {
  color: var(--wine);
  border-color: var(--gold-light);
}

/* Headings */
.hero {
  text-align: center;
}

.hero .eyebrow {
  font-size: clamp(11px, 1.6vw, 15px);
}

.script-title {
  font-family: var(--script);
  font-weight: normal;
  color: var(--wine);
  line-height: 1.05;
  font-size: clamp(64px, 12vw, 150px);
  margin: 10px 0 0;
}

.page-title {
  font-size: clamp(56px, 9vw, 104px);
}

.flourish {
  display: block;
  width: min(420px, 80%);
  margin: 18px auto 22px;
  color: var(--gold);
}

.verse {
  font-style: italic;
  font-size: clamp(19px, 2.6vw, 28px);
  color: var(--wine);
}

.subtle {
  font-size: clamp(15px, 1.8vw, 18px);
  line-height: 1.6;
}

.reference {
  margin-top: 10px;
  font-size: 12px;
}

/* Home cards */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: clamp(16px, 2.4vw, 28px);
  margin-top: clamp(40px, 7vh, 64px);
}

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 38px 26px 34px;
  text-align: center;
  text-decoration: none;
  background: rgba(252, 245, 242, 0.78);
  border: 1.5px solid var(--gold);
  outline: 1px solid var(--gold-light);
  outline-offset: -8px;
  transition: transform 0.35s ease, box-shadow 0.35s ease, background 0.35s ease;
}

.card:hover {
  transform: translateY(-4px);
  background: rgba(252, 245, 242, 0.95);
  box-shadow: 0 18px 40px -22px rgba(142, 31, 58, 0.45);
}

.card svg {
  width: 54px;
  height: 54px;
  color: var(--gold);
}

.card h2 {
  font-family: var(--script);
  font-weight: normal;
  font-size: 52px;
  line-height: 1;
  color: var(--wine);
}

.card p {
  font-style: italic;
  font-size: 16px;
  line-height: 1.5;
}

.card .go {
  margin-top: 6px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--gold);
}

.venue {
  margin-top: clamp(44px, 7vh, 72px);
  text-align: center;
  font-size: 15px;
  line-height: 1.7;
}

.venue strong {
  display: block;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: #6b2a3a;
}

/* Program */
.program {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(28px, 5vw, 64px);
  margin-top: 46px;
}

.part-label {
  text-align: center;
  font-size: 13px;
  margin-bottom: 18px;
}

.seg {
  text-align: center;
  padding: 18px 0 20px;
}

.seg + .seg {
  border-top: 1px solid rgba(205, 172, 122, 0.55);
}

.seg .time {
  font-size: 11.5px;
}

.seg h3 {
  font-family: var(--script);
  font-weight: normal;
  font-size: 40px;
  line-height: 1.15;
  color: var(--wine);
  margin: 4px 0 6px;
}

.seg p {
  font-size: 16px;
  line-height: 1.55;
}

.seg .it {
  font-style: italic;
}

.seg .label {
  margin-top: 8px;
  font-size: 10.5px;
}

.downloads {
  margin-top: 56px;
  text-align: center;
}

.downloads .eyebrow {
  font-size: 13px;
}

.download-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  margin-top: 20px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 22px;
  border: 1.5px solid var(--gold);
  background: rgba(252, 245, 242, 0.85);
  color: var(--plum);
  font: inherit;
  font-size: 15px;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.25s ease, color 0.25s ease;
}

.btn:hover {
  background: var(--wine);
  border-color: var(--wine);
  color: #fbeee9;
}

.btn.primary {
  background: var(--wine);
  border-color: var(--wine);
  color: #fbeee9;
}

.btn.primary:hover {
  background: #741630;
}

.pages {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 30px;
}

.pages a {
  display: block;
  border: 1px solid var(--gold-light);
  box-shadow: 0 14px 30px -20px rgba(90, 42, 51, 0.5);
  transition: transform 0.3s ease;
}

.pages a:hover {
  transform: translateY(-3px);
}

.pages img {
  display: block;
  width: 100%;
  height: auto;
}

/* Gallery */
.gallery-tools {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 14px;
  margin-top: 30px;
}

.gallery-tools[hidden] {
  display: none;
}

.progress {
  font-style: italic;
  font-size: 15px;
}

.gallery-count {
  margin-top: 28px;
  text-align: center;
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
}

.grid {
  columns: 3 260px;
  column-gap: 16px;
  margin-top: 22px;
}

.pager {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 10px 16px;
  margin: 36px auto 0;
  max-width: 520px;
}

.pager[hidden] {
  display: none;
}

.pager-step,
.pager-nums button {
  font: inherit;
  color: var(--plum);
  background: rgba(252, 245, 242, 0.85);
  border: 1.5px solid var(--gold);
  cursor: pointer;
}

.pager-step {
  width: 52px;
  height: 52px;
  font-size: 28px;
  line-height: 1;
  color: var(--wine);
}

.pager-step:disabled {
  opacity: 0.28;
  cursor: default;
}

.pager-nums {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

.pager-nums button {
  min-width: 40px;
  height: 40px;
  padding: 0 10px;
  font-size: 15px;
}

.pager-nums button[aria-current] {
  background: var(--wine);
  border-color: var(--wine);
  color: #fbeee9;
}

.pager-status {
  grid-column: 1 / -1;
  text-align: center;
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
}

.dock {
  display: none;
}

.grid figure {
  position: relative;
  break-inside: avoid;
  margin: 0 0 16px;
  background: var(--blush-centre);
  border: 1px solid var(--gold-light);
  padding: 7px;
  cursor: zoom-in;
  box-shadow: 0 12px 26px -20px rgba(90, 42, 51, 0.6);
  opacity: 0;
  transform: translateY(10px);
  animation: rise 0.7s ease forwards;
}

.grid img {
  display: block;
  width: 100%;
  height: auto;
  background: var(--blush-bottom);
}

.grid .remove {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 0;
  background: rgba(90, 42, 51, 0.75);
  color: #fff;
  font-size: 16px;
  line-height: 30px;
  cursor: pointer;
}

@keyframes rise {
  to {
    opacity: 1;
    transform: none;
  }
}

.empty {
  margin: 60px auto 0;
  max-width: 520px;
  text-align: center;
  padding: 44px 30px;
  border: 1.5px solid var(--gold);
  outline: 1px solid var(--gold-light);
  outline-offset: -8px;
  background: rgba(252, 245, 242, 0.7);
}

.empty h2 {
  font-family: var(--script);
  font-weight: normal;
  font-size: 48px;
  color: var(--wine);
}

.empty p {
  font-style: italic;
  margin-top: 8px;
  line-height: 1.6;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 10;
  display: grid;
  place-items: center;
  background: rgba(40, 14, 22, 0.92);
}

.lightbox[hidden] {
  display: none;
}

.lightbox img {
  max-width: 92vw;
  max-height: 84vh;
  border: 6px solid var(--blush-centre);
  box-shadow: 0 30px 60px -20px rgba(0, 0, 0, 0.6);
}

.lightbox button,
.lightbox a {
  position: absolute;
  border: 0;
  background: transparent;
  color: #fbeee9;
  font: inherit;
  cursor: pointer;
  text-decoration: none;
}

.lb-close { top: 18px; right: 22px; font-size: 34px; }
.lb-prev, .lb-next { top: 50%; margin-top: -32px; font-size: 54px; padding: 0 18px; }
.lb-prev { left: 6px; }
.lb-next { right: 6px; }
.lb-save {
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 13px;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  border-bottom: 1px solid var(--gold-light) !important;
}

.footer-note {
  margin-top: 64px;
  text-align: center;
  font-size: 13px;
  font-style: italic;
  color: var(--gold);
}

@media (max-width: 760px) {
  .program {
    grid-template-columns: 1fr;
  }

  .pages {
    grid-template-columns: 1fr 1fr;
  }

  .page-roses {
    width: 160px;
    opacity: 0.55;
  }

  .page-frame {
    inset: 8px;
  }

  .wrap {
    width: min(1080px, 100% - 28px);
    padding: 28px 0 108px;
  }

  .nav {
    display: none;
  }

  .hero .eyebrow {
    font-size: 10px;
    letter-spacing: 0.22em;
  }

  .script-title {
    font-size: clamp(52px, 16vw, 86px);
  }

  .page-title {
    font-size: clamp(48px, 14vw, 72px);
  }

  .cards {
    grid-template-columns: 1fr;
    gap: 14px;
    margin-top: 32px;
  }

  .card {
    padding: 22px 18px 20px;
    flex-direction: row;
    text-align: left;
    gap: 16px;
  }

  .card svg {
    width: 40px;
    height: 40px;
    flex: none;
  }

  .card h2 {
    font-size: 36px;
  }

  .card p {
    font-size: 14px;
  }

  .card .go {
    display: none;
  }

  .grid {
    columns: 2;
    column-gap: 10px;
    margin-top: 16px;
  }

  .grid figure {
    margin-bottom: 10px;
    padding: 5px;
  }

  .pager {
    position: sticky;
    bottom: calc(76px + env(safe-area-inset-bottom));
    z-index: 3;
    max-width: none;
    margin: 22px -6px 0;
    padding: 10px 8px 8px;
    background: linear-gradient(180deg, rgba(249, 236, 232, 0), rgba(249, 236, 232, 0.94) 28%, var(--blush-top));
  }

  .pager-step {
    width: 56px;
    height: 56px;
  }

  .pager-nums button {
    min-width: 36px;
    height: 36px;
  }

  .lb-prev, .lb-next {
    font-size: 40px;
  }

  .lightbox img {
    max-width: 96vw;
    max-height: 78vh;
    border-width: 4px;
  }

  .lb-close {
    top: max(10px, env(safe-area-inset-top));
    right: 14px;
  }

  .lb-save {
    bottom: max(16px, env(safe-area-inset-bottom));
  }

  .has-dock .dock {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    position: fixed;
    left: 12px;
    right: 12px;
    bottom: max(10px, env(safe-area-inset-bottom));
    z-index: 4;
    padding: 8px 4px 10px;
    background: rgba(252, 245, 242, 0.94);
    border: 1.5px solid var(--gold);
    outline: 1px solid var(--gold-light);
    outline-offset: -6px;
    backdrop-filter: blur(10px);
  }

  .dock a {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    text-decoration: none;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--gold);
  }

  .dock a[aria-current] {
    color: var(--wine);
  }

  .dock a[aria-current] span {
    border-bottom: 1px solid var(--gold-light);
    padding-bottom: 2px;
  }
}
