.occasion-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: stretch;
  gap: clamp(22px, 3vw, 40px);
  max-width: 1320px;
  margin: 0 auto;
}

.occasion-gallery figure,
.occasion-gallery figure:nth-child(2) {
  display: flex;
  flex-direction: column;
  min-width: 0;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--page);
}

.occasion-gallery .photo {
  display: block;
  width: 100%;
  overflow: hidden;
}

.occasion-gallery .photo img,
#event-gallery .photo img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  transition: transform 500ms ease;
}

.occasion-gallery .photo:hover img,
.occasion-gallery .photo:focus-visible img {
  transform: scale(1.025);
}

.occasion-gallery figcaption {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  min-height: 58px;
  padding: 18px 20px;
  border-top: 1px solid var(--line);
  font-size: 12px;
  line-height: 1.45;
  letter-spacing: .04em;
}

#anniversary-gallery {
  grid-template-columns: minmax(0, 820px);
  justify-content: center;
}

#anniversary-gallery figure {
  width: 100%;
}

@media (max-width: 700px) {
  .occasion-gallery,
  #anniversary-gallery {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .occasion-gallery figcaption {
    min-height: 54px;
    padding: 16px;
    font-size: 11px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .occasion-gallery .photo img {
    transition: none;
  }
}

/* Events — a full-bleed establishing frame followed by an intimate story. */
#events {
  position: relative;
  overflow: hidden;
  padding: clamp(88px, 9vw, 138px) 0 clamp(100px, 11vw, 160px);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

#events::before {
  content: "";
  position: absolute;
  top: 0;
  right: 7%;
  width: 1px;
  height: 72px;
  background: var(--line);
}

#events .occasion-heading {
  grid-template-columns: minmax(0, 1.4fr) minmax(260px, .6fr);
  align-items: end;
  max-width: 1480px;
  margin: 0 auto clamp(54px, 7vw, 92px);
  padding: 0 7%;
}

#events .occasion-heading h2 {
  font-size: clamp(56px, 6.7vw, 104px);
  line-height: 1.02;
  letter-spacing: -.025em;
}

#events .occasion-heading h2 em {
  color: var(--accent);
  letter-spacing: 0;
  font-kerning: normal;
}

#events .occasion-heading > div:last-child {
  border-top: 1px solid var(--line);
  padding-top: 24px;
}

#event-gallery {
  display: block;
  max-width: none;
  padding: 0;
}

#event-gallery .event-card,
#event-gallery .event-card:nth-child(2) {
  display: block;
  overflow: visible;
  border: 0;
  background: transparent;
  padding: 0;
}

#event-gallery .event-card:nth-child(2) {
  width: min(760px, 55vw);
  margin: clamp(78px, 8vw, 128px) auto 0;
}

#event-gallery .photo {
  position: relative;
  height: auto;
  background: var(--panel);
}

#event-gallery .event-card:first-child .photo {
  aspect-ratio: auto;
}

#event-gallery .event-card:nth-child(2) .photo {
  height: auto;
  aspect-ratio: 4 / 3;
}

#event-gallery .photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: right center;
  transform: scale(1.018);
  filter: saturate(.92) contrast(1.02);
  transition: transform 800ms cubic-bezier(.2,.7,.2,1), filter 500ms ease;
}

#event-gallery .event-card:nth-child(2) .photo img { object-position: right center; }

#event-gallery .event-card:first-child .photo img {
  height: auto;
  aspect-ratio: auto;
  object-position: center;
}

#event-gallery .photo:hover img,
#event-gallery .photo:focus-visible img {
  transform: scale(1.035);
  filter: saturate(1) contrast(1.01);
}

.event-open {
  position: absolute;
  right: 18px;
  bottom: 18px;
  display: inline-flex;
  align-items: center;
  gap: 20px;
  padding: 12px 14px 12px 17px;
  background: rgba(18,19,17,.82);
  color: #f5f2e9;
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
  backdrop-filter: blur(9px);
  transition: background 250ms ease, transform 250ms ease;
}

.event-open b { font-size: 16px; font-weight: 400; }

#event-gallery .photo:hover .event-open,
#event-gallery .photo:focus-visible .event-open {
  background: rgba(18,19,17,.96);
  transform: translateY(-3px);
}

#event-gallery figcaption {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: start;
  gap: 18px;
  min-height: 0;
  padding: 22px 0 0;
  border: 0;
  color: var(--ink);
}

#event-gallery .event-card:first-child figcaption {
  padding-left: 7%;
  padding-right: 7%;
}

.event-index,
.event-type {
  padding-top: 6px;
  color: var(--muted);
  font-size: 9px;
  letter-spacing: .15em;
}

.event-title strong,
.event-title small { display: block; }

.event-title strong {
  font: 400 clamp(20px, 2vw, 30px)/1.1 Georgia, serif;
  letter-spacing: -.025em;
}

.event-title small {
  margin-top: 6px;
  color: var(--muted);
  font-size: 11px;
  letter-spacing: .05em;
}

.event-type { white-space: nowrap; }

@media (max-width: 800px) {
  #events::before { display: none; }
  #events .occasion-heading { grid-template-columns: 1fr; gap: 32px; }
  #events .occasion-heading h2 { font-size: clamp(54px, 12vw, 82px); }
  #events .occasion-heading > div:last-child { max-width: 520px; }
  #event-gallery .event-card:nth-child(2) { width: auto; margin: 64px 7% 0; }
  #event-gallery .photo,
  #event-gallery .event-card:nth-child(2) .photo { height: auto; }
  #event-gallery .event-card:first-child .photo { aspect-ratio: auto; }
  #event-gallery .event-card:nth-child(2) .photo { aspect-ratio: 4 / 3; }
}

@media (max-width: 560px) {
  #events { padding: 66px 0 80px; }
  #events .occasion-heading { padding-left: 6%; padding-right: 6%; }
  #events .occasion-heading { margin-bottom: 42px; }
  #events .occasion-heading h2 { font-size: 50px; }
  #event-gallery .event-card:nth-child(2) { width: auto; margin: 48px 6% 0; }
  #event-gallery .event-card:first-child figcaption { padding-left: 6%; padding-right: 6%; }
  #event-gallery figcaption { grid-template-columns: auto 1fr; }
  .event-type { display: none; }
  .event-open { right: 12px; bottom: 12px; }
}

@media (prefers-reduced-motion: reduce) {
  #event-gallery .photo img,
  .event-open { transition: none; }
}

/* The wedding reception has its own chapter beneath Fashion Fest. */
#event-gallery .celebration-story{margin:clamp(90px,10vw,150px) 7% 0;padding-top:clamp(50px,6vw,84px);border-top:1px solid var(--line)}
.celebration-story-heading{max-width:1120px;margin:0 auto 38px}
.celebration-story-heading .eyebrow{color:var(--muted);font-size:11px;margin-bottom:20px}
.celebration-story-heading h3{font-size:clamp(38px,5vw,68px);font-weight:400;line-height:1.1;letter-spacing:-1.5px}
.celebration-story-heading h3 em{color:var(--accent)}
#event-gallery .celebration-story .event-card{width:100%;max-width:1120px;margin:0 auto}
#event-gallery .celebration-story .photo{aspect-ratio:auto}
#event-gallery .celebration-story .photo img{height:auto;aspect-ratio:auto;transform:none;object-fit:contain}
#event-gallery .celebration-story figcaption{display:none}
@media(max-width:560px){#event-gallery .celebration-story{margin:64px 6% 0;padding-top:40px}.celebration-story-heading{margin-bottom:28px}}

/* A concise event edit: reception first, followed by backstage atmosphere. */
#event-gallery { max-width: 1440px; margin: 0 auto; padding: 0 7%; }
#event-gallery .event-card:first-child { width: 100%; }
#event-gallery .event-card:nth-child(2) { width: min(100%, 960px); margin: 56px auto 0; }
#event-gallery .event-card .photo,
#event-gallery .event-card:nth-child(2) .photo { aspect-ratio: auto; }
#event-gallery .photo img,
#event-gallery .photo:hover img,
#event-gallery .photo:focus-visible img {
 height: auto; aspect-ratio: auto; object-fit: contain; transform: none; filter: none;
}
#event-gallery .event-card:first-child figcaption { padding-left: 0; padding-right: 0; }
#event-gallery figcaption { font-size: 14px; }
.event-index,.event-type { font-size: 12px; }
.event-title small { font-size: 14px; }
@media(max-width:800px) { #event-gallery .event-card:nth-child(2) { width: 100%; margin: 38px 0 0; } }
@media(max-width:560px) { #event-gallery { padding: 0 6%; } }

/* Clean originals: an intimate wedding pair followed by live-event scale. */
#event-gallery { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); align-items: start; gap: 48px 30px; }
#event-gallery .event-card:nth-child(2) { width: 100%; margin: 0; }
#event-gallery .event-card:nth-child(3) { grid-column: 1 / -1; width: min(100%,1120px); margin: 0 auto; }
@media(max-width:800px) {
 #event-gallery { grid-template-columns: 1fr; gap: 38px; }
 #event-gallery .event-card:nth-child(3) { grid-column: 1; }
}

/* Three-photo event slideshow, with original framing preserved. */
.events-slideshow{max-width:1440px;margin:0 auto;padding:0 7%}
#event-gallery{display:grid;grid-template-columns:1fr;gap:0;padding:0;max-width:none;margin:0}
#event-gallery .event-card,#event-gallery .event-card:nth-child(2),#event-gallery .event-card:nth-child(3){grid-area:1/1;width:100%;max-width:none;margin:0;opacity:0;visibility:hidden;pointer-events:none;transition:opacity 650ms ease,visibility 650ms}
#event-gallery .event-card.event-active{opacity:1;visibility:visible;pointer-events:auto}
#event-gallery .event-card .photo,#event-gallery .event-card:first-child .photo,#event-gallery .event-card:nth-child(2) .photo{width:100%;aspect-ratio:3/2;height:auto;background:#111;display:flex;align-items:center;justify-content:center}
#event-gallery .event-card .photo img,#event-gallery .event-card:first-child .photo img{width:100%;height:100%;aspect-ratio:auto;object-fit:contain;transform:none;filter:none}
#event-gallery .event-card figcaption{padding:20px 0;min-height:72px}
.event-slideshow-controls{display:flex;align-items:center;justify-content:space-between;gap:20px;border-top:1px solid var(--line);padding-top:20px}
.event-slide-dots,.event-slide-actions{display:flex;gap:10px;align-items:center}
.event-slideshow-controls button{min-width:44px;min-height:44px;padding:10px 14px;background:transparent;color:var(--ink);border:1px solid var(--line);cursor:pointer;font:13px Arial,sans-serif}
.event-slide-dots button[aria-pressed="true"]{background:var(--ink);color:var(--page);border-color:var(--ink)}
.event-slideshow-controls button:focus-visible{outline:2px solid var(--accent);outline-offset:3px}
.event-slideshow-hint{font-size:11px;line-height:1.6;color:var(--muted);margin-top:18px}
@media(max-width:560px){.events-slideshow{padding:0 6%}.event-slideshow-controls{gap:8px}.event-slide-dots,.event-slide-actions{gap:4px}.event-slideshow-controls button{padding:10px;min-width:40px}#event-gallery .event-card figcaption{min-height:66px}}
@media(prefers-reduced-motion:reduce){#event-gallery .event-card{transition:none}}
