/* --- Button Click Cue --- */
:root {
  --primary-color: #606B46;
  --secondary-color: #4a4a4a;
  --background-color: #f4efeb;
  --loader-background-color: #F5F1E8;
  --dark-color: #2c2c2c;
  --text-color: #555;
  --heading-font: 'Playfair Display', serif;
  --alternative-font: 'Parisienne', cursive;
  --body-font: 'Montserrat', sans-serif;
  --transition: all 0.3s ease;
  --border-radius: 8px;
  --loader-accent-color: #2B2B2B;
}

html,
body {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  touch-action: pan-y;
}

a,
button,
img {
  touch-action: pan-y;
}

html.touch-scroll-fix body :not(input):not(textarea):not(select) {
  -webkit-user-select: none;
  user-select: none;
}

html.touch-scroll-fix img {
  -webkit-user-drag: none;
}

body {
  font-family: var(--body-font);
  color: var(--text-color);
  background-color: var(--background-color);
  line-height: 1.8;
}

@media (min-width: 1100px) {
  body {
    background-color: var(--background-color);
    background-image: linear-gradient(rgba(44, 44, 44, 0.18), rgba(44, 44, 44, 0.18)), url('./images/general-bg.jpg');
    background-repeat: no-repeat;
    background-position: center center, center center;
    background-size: cover;
    background-attachment: fixed;
    padding: 18px 0 28px;
  }

  .invitation-shell {
    width: min(34vw, 560px);
    min-width: 600px;
    max-width: 800px;
    margin: 0 auto;
    border-radius: 30px;
    background: var(--background-color);
    box-shadow: 0 22px 50px rgba(0, 0, 0, 0.24);
    overflow: hidden;
  }
}

/* --- Section-anchored decorative flowers --- */
#countdown,
#event-details,
#gallery,
#registry {
  position: relative;
}

#event-details::before,
#event-details::after,
#gallery::before,
#registry::before {
  content: '';
  position: absolute;
  top: 0;
  width: 300px;
  height: 300px;
  background-repeat: no-repeat;
  background-size: contain;
  pointer-events: none;
  z-index: 1100;
  opacity: 0;
  transition: opacity 0.75s ease, transform 0.75s ease;
}

#event-details::before {
  --deco-y: 0%;
  top: 0;
  right: -157px;
  transform: translateY(var(--deco-y)) translateY(18px);
  background-image: url('./images/deco3.png');
}

#event-details::after {
  --deco-y: 0%;
  top: auto;
  bottom: 0;
  left: -30px;
  transform: translateY(18px);
  background-image: url('./images/deco4.png');
}

#gallery::before {
  --deco-y: -100%;
  left: -50px;
  transform: translateY(var(--deco-y)) translateY(18px);
  background-image: url('./images/deco5.png');
}

#registry::before {
  --deco-y: 0%;
  right: -175px;
  transform: translateY(var(--deco-y)) translateY(18px);
  background-image: url('./images/deco6.png');
}

@media (max-width: 767.98px) {
  #event-details::before,
  #event-details::after,
  #gallery::before,
  #registry::before {
    width: clamp(140px, 44vw, 200px);
    height: clamp(140px, 44vw, 200px);
  }

  #event-details::before {
    right: -107px;
  }

  #event-details::after {
    left: -10px;
  }

  #gallery::before {
    left: -30px;
  }

  #registry::before {
    right: -116px;
  }
}

#event-details.deco-visible::before,
#event-details.deco-visible::after,
#gallery.deco-visible::before,
#registry.deco-visible::before {
  opacity: 1;
  transform: translateY(var(--deco-y)) translateY(0);
}

body.loading #event-details::before,
body.loading #event-details::after,
body.loading #gallery::before,
body.loading #registry::before {
  opacity: 0 !important;
}

body.loading {
  overflow: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--heading-font);
  color: var(--secondary-color);
  font-weight: 700;
}

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--secondary-color);
}

.section-title {
  font-size: 3rem;
  font-style: italic;
  color: var(--primary-color);
  margin-bottom: 1rem;
}

.countdown-subtitle {
  font-size: 1.2rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--secondary-color);
  margin-bottom: 1.3rem;
}

.section-subtitle {
  font-size: 1.2rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--secondary-color);
  margin-bottom: 3rem;
}

.btn-primary {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  padding: 12px 30px;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 50px;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(200, 157, 156, 0.4);
}

.btn,
.hero-btn,
.hero-btn-outline,
.btn-primary {
  border-radius: 999px !important;
  position: relative;
  overflow: hidden;
}

@media (max-width: 767.98px) {
  .btn,
  .hero-btn,
  .hero-btn-outline,
  .btn-primary {
    padding-right: 2.35rem;
  }
}

.btn-primary:hover,
.btn-primary:active {
  background-color: #b38a89 !important;
  border-color: #b38a89 !important;
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(200, 157, 156, 0.6);
}

.btn[disabled],
.btn:disabled {
  opacity: 0.62;
  cursor: not-allowed;
  pointer-events: none;
}

/* --- Loader Container --- */
.loader-wrapper {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 9999;
  overflow: hidden;
  pointer-events: auto;
}

.loader-split-left,
.loader-split-right {
  position: absolute;
  top: 0;
  width: 50.5%;
  height: 100%;
  background-color: var(--loader-background-color);
  transition: transform 1.2s cubic-bezier(0.8, 0, 0.2, 1);
  z-index: 9998;
}

.loader-split-left {
  left: 0;
}

.loader-split-right {
  right: 0;
}

/* Class to hide the loader */
.loader-hidden {
  pointer-events: none;
}

.loader-hidden .loader-split-left {
  transform: translateX(-100%);
}

.loader-hidden .loader-split-right {
  transform: translateX(100%);
}

.loader-hidden .loader-content {
  opacity: 0;
  transform: translate(-50%, -50%) scale(0.8);
}

/* --- Heart Animation --- */
.loader-content {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  z-index: 9999;
  transition: opacity 0.5s, transform 0.5s;
}

.drawing-heart {
  width: 300px;
  height: 300px;
  animation: pulse-heart 1.5s 2s ease-in-out infinite;
}

.drawing-heart path {
  fill: none;
  stroke: var(--loader-accent-color);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 200;
  stroke-dashoffset: 200;
  animation: draw-heart-path 2s ease-out forwards;
}

.loader-text {
  font-family: var(--heading-font);
  font-size: 3.5rem;
  font-style: italic;
  color: var(--loader-accent-color);
  margin-top: 20px;
  opacity: 0;
  animation: fade-in-text 1s 1.5s ease-out forwards;
}

/* Keyframes for animations */
@keyframes draw-heart-path {
  to {
      stroke-dashoffset: 0;
  }
}

@keyframes pulse-heart {

  0%,
  100% {
      transform: scale(1);
  }

  50% {
      transform: scale(1.05);
  }
}

@keyframes fade-in-text {
  from {
      opacity: 0;
      transform: translateY(10px);
  }

  to {
      opacity: 1;
      transform: translateY(0);
  }
}

/* --- Hero Section --- */
.hero-section {
  position: relative;
  height: 100vh;
  min-height: 800px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.35) 0%, rgba(0, 0, 0, 0.68) 90%, rgba(0, 0, 0, 0) 100%),
    url('./images/bg1.png') no-repeat center center;
  background-size: cover;
  background-position: center center;
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 2;
  padding: 0 5%;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.pre-title {
  font-size: 1.2rem;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: rgb(255, 255, 255);
  margin-top: 2.5rem;
  margin-bottom: 0;
  display: block;
}

.hero-title {
  font-family: var(--alternative-font);
  font-weight: 500;
  font-style: normal;
  font-size: 6.2rem;
  line-height: 0.8;
  color: rgb(255, 255, 255);
  margin-top: 0;
  margin-bottom: 0;
  letter-spacing: -1.5px;
}

.hero-title span {
  color: rgb(255, 255, 255);
  position: relative;
  display: inline-block;
}

.hero-title span::after {
  content: '';
  position: absolute;
  bottom: 10px;
  left: 0;
  width: 100%;
  height: 12px;
  background-color: rgba(200, 157, 156, 0.3);
  z-index: -1;
}

.hero-text {
  font-size: 1.2rem;
  letter-spacing: 4px;
  text-transform: uppercase;
  font-weight: 400;
  line-height: 1.8;
  color: rgb(255, 255, 255);
  max-width: 500px;
  margin-top: 0;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 0;
}

.hero-btn {
  background-color: transparent;
  border: 2px solid var(--primary-color);
  color: var(--primary-color);
  padding: 1.1rem 3.5rem;
  border-radius: 0;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  font-size: 0.9rem;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.hero-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: var(--primary-color);
  transition: var(--transition);
  z-index: -1;
}

.hero-btn:hover {
  color: white;
}

.hero-btn:hover::before {
  left: 0;
}

.hero-btn-outline {
  background-color: transparent;
  border: 2px solid var(--dark-color);
  color: var(--dark-color);
  padding: 1.1rem 3.5rem;
  border-radius: 0;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  font-size: 0.9rem;
  transition: var(--transition);
}

.hero-btn-outline:hover {
  background-color: var(--dark-color);
  color: white;
}

/* --- Floating Music Player --- */
.floating-music-player {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  z-index: 1200;
  display: flex;
  align-items: center;
}

.music-panel {
  max-width: 0;
  opacity: 0;
  margin-right: 0;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 14px;
  background: rgba(253, 250, 246, 0.92);
  box-shadow: 0 8px 22px rgba(44, 44, 44, 0.14);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  overflow: hidden;
  pointer-events: none;
  transform: translateX(8px);
  transition: max-width 0.28s ease, opacity 0.22s ease, margin-right 0.22s ease, padding 0.22s ease, transform 0.22s ease;
}

.floating-music-player.is-expanded .music-panel {
  max-width: min(290px, 72vw);
  opacity: 1;
  margin-right: 0.55rem;
  padding: 0.45rem 0.6rem;
  border-color: rgba(128, 0, 32, 0.2);
  pointer-events: auto;
  transform: translateX(0);
}

.music-toggle {
  width: 40px;
  height: 40px;
  border: none;
  border-radius: 50%;
  flex-shrink: 0;
  position: relative;
  overflow: visible;
  background: var(--primary-color);
  color: #fff;
  font-size: 0.82rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 14px rgba(128, 0, 32, 0.3);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.music-toggle:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(128, 0, 32, 0.4);
}

.music-toggle:focus-visible {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
}

#musicToggleIcon {
  display: inline-block;
  transform-origin: 50% 50%;
}

.music-toggle.is-playing #musicToggleIcon {
  animation: musicIconSpin 2.4s linear infinite;
}

@keyframes musicIconSpin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

.music-note-particle {
  position: absolute;
  left: 50%;
  bottom: 98%;
  color: rgba(255, 255, 255, 0.95);
  font-size: 0.65rem;
  line-height: 1;
  pointer-events: none;
  opacity: 0;
  transform: translate(-50%, 0) scale(0.75);
  animation: musicNoteFloat 1.05s ease-out forwards;
}

@keyframes musicNoteFloat {
  0% {
    opacity: 0;
    transform: translate(-50%, 0) scale(0.65);
  }

  12% {
    opacity: 1;
  }

  100% {
    opacity: 0;
    transform: translate(calc(-50% + var(--note-drift, 0px)), -78px) scale(1.2);
  }
}

.music-player-content {
  width: min(265px, 62vw);
  text-align: left;
}

.music-label {
  margin: 0;
  font-size: 0.58rem;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: rgba(74, 74, 74, 0.7);
  line-height: 1.1;
}

.music-title {
  margin: 0.1rem 0 0.22rem;
  font-family: var(--heading-font);
  font-style: italic;
  font-size: 0.88rem;
  color: var(--dark-color);
  line-height: 1.15;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.music-progress {
  position: relative;
  width: 100%;
  height: 4px;
  background: rgba(128, 0, 32, 0.15);
  border-radius: 999px;
  overflow: hidden;
  cursor: pointer;
}

.music-progress-fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--primary-color), #aa3a56);
  border-radius: 999px;
}

.music-time {
  margin-top: 0.22rem;
  display: flex;
  justify-content: space-between;
  font-size: 0.66rem;
  color: rgba(74, 74, 74, 0.76);
}

/* --- Countdown Section --- */
.countdown-image-section {
  background: url('images/bg2.jpeg') no-repeat center center;
  background-size: contain;
  position: relative;
  margin-top: 50px;
  min-height: 15vh;
}

.countdown-image-section .overlay-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(244, 239, 235, 0.65);
}

.countdown-section {
  position: relative;
  margin-top: 25px;
}

.countdown-section .section-title {
  color: var(--primary-color);
  font-size: 1.5rem;
  font-style: italic;
  margin-bottom: 0.5rem;
}

.countdown-content {
  position: relative;
  z-index: 1;
}

.countdown-container {
  display: flex;
  gap: 1.5rem;
  margin: 0.5rem 0;
  justify-content: center;
  flex-wrap: wrap;
}

.wedding-date-strip {
  margin-top: 0.45rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.95rem;
}

.wedding-date-strip .date-side {
  min-width: 90px;
  padding: 0.2rem 0.35rem;
  font-family: var(--body-font);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 1.6px;
  text-transform: uppercase;
  color: var(--secondary-color);
  border-top: 1px solid rgba(74, 74, 74, 0.35);
  border-bottom: 1px solid rgba(74, 74, 74, 0.35);
}

.wedding-date-strip .date-day {
  font-family: var(--alternative-font);
  font-size: 4.2rem;
  line-height: 0.9;
  color: var(--dark-color);
}

.countdown-item {
  text-align: center;
}

.countdown-number {
  font-family: var(--heading-font);
  font-size: 2.2rem;
  font-weight: 600;
  color: var(--dark-color);
  line-height: 1;
  margin-bottom: 0.5rem;
}

.countdown-label {
  font-size: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 3px;
  color: var(--secondary-color);
}

/* ========== ANIMATED MOUSE SCROLL ========== */
.mouse-scroll {
  position: absolute;
  bottom: 7.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
}

.mouse {
  width: 30px;
  height: 50px;
  border: 2px solid rgb(255, 255, 255);
  border-radius: 12px;
  position: relative;
  margin: 0 auto;
}

.mouse-wheel {
  width: 4px;
  height: 8px;
  background: rgb(255, 255, 255);
  border-radius: 2px;
  position: absolute;
  top: 8px;
  left: 50%;
  transform: translateX(-50%);
  animation: scrollWheel 2s infinite;
}

@keyframes scrollWheel {
  0% {
      transform: translate(-50%, 0);
      opacity: 1;
  }

  100% {
      transform: translate(-50%, 10px);
      opacity: 0;
  }
}

.scroll-text {
  color: rgb(255, 255, 255);
  font-size: 0.6rem;
  letter-spacing: 2px;
  margin-top: 0.5rem;
  text-align: center;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% {
      opacity: 0.6;
  }

  50% {
      opacity: 1;
  }

  100% {
      opacity: 0.6;
  }
}

/* --- General Section Styling --- */
.section-padding {
  padding: 70px 0;
}

.bg-light-pink {
  background-color: rgb(232, 223, 215);
}

/* --- Our Story Section --- */
.story-img {
  display: block;
  max-width: 100%;
  margin: 0 auto;
}

/* --- Event Details Section --- */
.event-detail-card {
  /* background: #fff; */
  border-radius: var(--border-radius);
  padding: 30px;
  /* box-shadow: 0 5px 25px rgba(0, 0, 0, 0.07); */
  transition: all 0.3s ease;
}

.event-detail-card:hover {
  transform: translateY(-10px);
  /* box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1); */
}

.event-detail-img {
  /* width: 180px; */
  height: 180px;
  /* border-radius: 50%; */
  object-fit: cover;
  margin-bottom: 20px;
  /* border: 5px solid var(--primary-color); */
}

.event-detail-card h3 {
  color: var(--primary-color);
  font-style: italic;
  font-size: 2rem;
}

/* --- Dress Code Section --- */
#dress-code .section-subtitle {
  margin-bottom: 0;
}

#dress-code .dress-layout {
  max-width: 460px;
  margin: 0 auto;
}

#dress-code .dress-hero-image {
  width: min(100%, 260px);
  height: 320px;
  object-fit: contain;
  object-position: center;
  display: block;
  margin: 0 auto 0.9rem;
}

#dress-code .dress-guidelines {
  text-align: center;
  color: var(--secondary-color);
  margin-bottom: 0.9rem;
}

#dress-code .dress-guidelines p {
  margin-bottom: 0.35rem;
}

#dress-code .dress-colors-subtitle {
  margin-top: 0.85rem;
  margin-bottom: 0.6rem;
  font-size: 0.95rem;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--secondary-color);
}

#dress-code .dress-palette {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 14px;
  margin-bottom: 0.85rem;
}

#dress-code .dress-color-dot {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: inline-block;
  border: 2px solid rgba(74, 74, 74, 0.18);
}

#dress-code .dot-green {
  background-color: #2F5D50;
}

#dress-code .dot-burgundy {
  background-color: #6D2E2E;
}

#dress-code .dot-terracotta {
  background-color: #C47A5A;
}

#dress-code .dot-gold {
  background-color: #C9A227;
}

#dress-code .dress-inspire-btn {
  padding: 0.8rem 2.2rem;
}

#dress-code .dress-restriction-note {
  margin: 0;
  font-size: 0.92rem;
  color: var(--secondary-color);
  line-height: 1.5;
}

.dress-references-modal .modal-content {
  border: 1px solid rgba(96, 107, 70, 0.28);
  border-radius: 18px;
  background: rgba(253, 250, 246, 0.97);
  box-shadow: 0 20px 40px rgba(44, 44, 44, 0.22);
  overflow: hidden;
}

.dress-references-modal .modal-header {
  border-bottom: 1px solid rgba(96, 107, 70, 0.18);
  padding: 1rem 1.2rem 0.8rem;
}

.dress-references-kicker {
  margin: 0;
  font-size: 0.64rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(74, 74, 74, 0.7);
}

.dress-references-modal .modal-title {
  font-family: var(--heading-font);
  font-style: italic;
  color: var(--primary-color);
  font-size: 1.7rem;
  margin: 0.15rem 0 0;
}

.dress-references-modal .btn-close {
  opacity: 0.7;
}

.dress-references-modal .btn-close:focus {
  box-shadow: 0 0 0 0.18rem rgba(96, 107, 70, 0.25);
}

.dress-references-modal .modal-body {
  padding: 1rem 1rem 1.2rem;
}

.dress-references-carousel {
  border-radius: 14px;
  overflow: hidden;
  background: #efe9df;
}

.dress-references-carousel .carousel-item {
  height: min(68vh, 560px);
  background: #efe9df;
}

.dress-references-carousel .carousel-item img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
}

.dress-references-modal .carousel-control-prev,
.dress-references-modal .carousel-control-next {
  width: 12%;
}

.dress-references-modal .carousel-control-prev-icon,
.dress-references-modal .carousel-control-next-icon {
  width: 2.1rem;
  height: 2.1rem;
  border-radius: 50%;
  background-color: rgba(44, 44, 44, 0.4);
  background-size: 62% 62%;
}

.dress-references-modal .carousel-indicators {
  margin-bottom: 0.45rem;
}

.dress-references-modal .carousel-indicators [data-bs-target] {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: 0;
  margin: 0 4px;
  background-color: rgba(255, 255, 255, 0.65);
}

.dress-references-modal .carousel-indicators .active {
  background-color: var(--primary-color);
}

@media (max-width: 767.98px) {
  .dress-references-modal .modal-dialog {
    margin: 0.7rem;
  }

  .dress-references-modal .modal-title {
    font-size: 1.4rem;
  }

  .dress-references-carousel .carousel-item img {
    height: 100%;
  }

  .dress-references-carousel .carousel-item {
    height: min(56vh, 420px);
  }
}

@media (max-width: 991.98px) {
  #dress-code .dress-layout {
    max-width: 100%;
    padding: 0 0.45rem;
  }

  #dress-code .dress-hero-image {
    width: min(100%, 220px);
    height: 280px;
  }
}

/* --- Event Timeline Section --- */
.timeline {
  position: relative;
  padding: 0;
  list-style: none;
}

.timeline:before {
  content: '';
  position: absolute;
  top: 26px;
  bottom: 26px;
  left: 50%;
  width: 1px;
  margin-left: -0.5px;
  background: linear-gradient(to bottom, rgba(128, 0, 32, 0.12), rgba(128, 0, 32, 0.42), rgba(128, 0, 32, 0.12));
}

.timeline>li {
  position: relative;
  margin-bottom: 18px;
  min-height: 84px;
}

.timeline>li:before,
.timeline>li:after {
  content: " ";
  display: table;
}

.timeline>li:after {
  clear: both;
}

.timeline>li .timeline-panel {
  position: relative;
  width: calc(50% - 54px);
  padding: 10px 0;
  border: none;
  border-radius: 0;
  background-color: transparent;
  box-shadow: none;
}

.timeline>li .timeline-image {
  position: absolute;
  z-index: 100;
  left: 50%;
  top: 10px;
  width: 44px;
  height: 44px;
  margin-left: -22px;
  border: 2px solid var(--primary-color);
  border-radius: 100%;
  text-align: center;
  background-color: transparent;
  color: var(--primary-color);
  display: flex;
  align-items: center;
  justify-content: center;
}

.timeline>li .timeline-image i {
  font-size: 1rem;
}

.timeline>li:nth-child(odd) .timeline-panel {
  margin-left: calc(50% + 54px);
  margin-right: 0;
  text-align: left;
}

.timeline>li:nth-child(even) .timeline-panel {
  margin-right: calc(50% + 54px);
  margin-left: 0;
  text-align: right;
}

.timeline>li:nth-child(odd) .timeline-image {
  background-color: transparent;
  color: var(--primary-color);
  border-color: var(--primary-color);
}

.timeline>li:nth-child(even) .timeline-image {
  background-color: var(--primary-color);
  color: #fff;
  border-color: var(--primary-color);
}

.container {
  max-width: 100%;
  padding-left: 1rem;
  padding-right: 1rem;
}

#event-details .mb-lg-0 {
  margin-bottom: 3rem !important;
}

.invitation-shell [class*='col-lg-'],
.invitation-shell [class*='col-md-'],
.invitation-shell [class*='col-sm-'] {
  flex: 0 0 100%;
  max-width: 100%;
}

.timeline-heading h4 {
  margin-top: 0;
  color: var(--primary-color);
  font-size: 1.2rem;
  margin-bottom: 0.25rem;
}

.timeline-heading .subheading {
  text-transform: none;
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: rgba(74, 74, 74, 0.88);
  margin: 0;
}

/* --- Gallery Section --- */
.gallery-collage {
  display: grid;
  grid-template-columns: 50% 50%;
  grid-template-rows: minmax(130px, 1fr) minmax(170px, 1fr);
  grid-template-areas:
    "top-left top-right"
    "bottom-left bottom-right";
  gap: 8px;
  max-width: 540px;
  margin: 0 auto;
  min-height: clamp(300px, 62vw, 420px);
}

.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: var(--border-radius);
  margin-bottom: 30px;
  display: block;
  height: 100%;
}

.gallery-collage .gallery-item {
  margin-bottom: 0;
}

.gallery-top-left {
  grid-area: top-left;
}

.gallery-top-right {
  grid-area: top-right;
}

.gallery-bottom-left {
  grid-area: bottom-left;
}

.gallery-bottom-right {
  grid-area: bottom-right;
}

.gallery-collage .gallery-item a {
  display: block;
  height: 100%;
}

.gallery-muted {
  filter: grayscale(88%);
}

.gallery-item img {
  transition: transform 0.4s ease;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery-item:hover img {
  transform: scale(1.1);
}

.gallery-item .overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(96, 107, 70, 0.7);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  opacity: 0;
  transition: opacity 0.4s ease;
  color: #fff;
  padding: 20px;
}

.gallery-item:hover .overlay {
  opacity: 1;
}

.gallery-item .overlay .overlay-content {
  transform: translateY(20px);
  transition: transform 0.4s ease;
}

.gallery-item:hover .overlay .overlay-content {
  transform: translateY(0);
}

.gallery-item .overlay i {
  font-size: 2rem;
  margin-bottom: 10px;
}

.gallery-item .overlay h5 {
  color: #fff;
  font-family: var(--body-font);
  font-weight: 600;
  font-size: 1.1rem;
  margin: 0;
}

@media (max-width: 767.98px) {
  .gallery-collage {
    grid-template-columns: 1fr;
    grid-template-rows: repeat(4, minmax(200px, 1fr));
    grid-template-areas:
      "top-left"
      "top-right"
      "bottom-left"
      "bottom-right";
    min-height: 0;
    max-width: 100%;
  }

  .gallery-collage .gallery-item {
    min-height: 200px;
  }
}

/* --- RSVP Section --- */
.rsvp-section {
  background: url('images/DSC02076.jpg') no-repeat center center fixed;
  background-size: cover;
  position: relative;
}

.rsvp-section .overlay-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(253, 250, 246, 0.65);
}

.rsvp-content {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: center;
}

.rsvp-letter-card {
  width: min(100%, 560px);
  background: rgba(253, 250, 246, 0.96);
  border-radius: 12px;
  box-shadow: 0 14px 35px rgba(44, 44, 44, 0.12);
  padding: 2rem 1.4rem 1.6rem;
  text-align: center;
}

.rsvp-reserved-label {
  margin: 0;
  font-size: 1.2rem;
  color: var(--secondary-color);
}

.rsvp-reserved-name {
  margin: 0.4rem 0 0.1rem;
  color: var(--secondary-color);
  font-size: 2.2rem;
  font-weight: 500;
}

.rsvp-reserved-count {
  margin-bottom: 1.4rem;
  color: var(--secondary-color);
  font-size: 1.4rem;
}

.rsvp-form-title {
  font-family: var(--heading-font);
  font-size: 2.6rem;
  color: var(--secondary-color);
  margin-bottom: 1.1rem;
}

.rsvp-form {
  text-align: left;
}

.rsvp-field-wrap {
  margin-bottom: 0.7rem;
}

.rsvp-input {
  width: 100%;
  border: 1px solid rgba(74, 74, 74, 0.08);
  background: rgba(238, 232, 228, 0.72);
  border-radius: 10px;
  padding: 0.8rem 0.95rem;
  color: var(--secondary-color);
  font-size: 1.05rem;
  font-family: var(--body-font);
}

.rsvp-input::placeholder {
  color: rgba(74, 74, 74, 0.82);
}

.rsvp-input:focus {
  outline: none;
  border-color: rgba(128, 0, 32, 0.28);
  box-shadow: 0 0 0 3px rgba(128, 0, 32, 0.08);
  background: rgba(253, 250, 246, 0.98);
}

.rsvp-textarea {
  resize: vertical;
  min-height: 110px;
}

.rsvp-submit-wrap {
  display: flex;
  justify-content: flex-end;
  margin-top: 0.2rem;
}

.rsvp-submit-btn {
  min-width: 165px;
  justify-content: center;
}

.rsvp-help-text {
  margin: 0.75rem 0 0;
  text-align: center;
  font-size: 0.78rem;
  color: rgba(74, 74, 74, 0.72);
}

.rsvp-form-status {
  min-height: 1.4rem;
  margin-top: 0.45rem;
  text-align: center;
  font-size: 0.9rem;
  color: var(--secondary-color);
}

.rsvp-form-status.is-success {
  color: #2f6b38;
}

.rsvp-form-status.is-error {
  color: #8a2437;
}

.rsvp-feedback-modal .modal-content {
  border: 1px solid rgba(96, 107, 70, 0.28);
  border-radius: 16px;
  background: rgba(253, 250, 246, 0.98);
  box-shadow: 0 18px 36px rgba(44, 44, 44, 0.2);
}

.rsvp-feedback-modal .modal-header {
  border-bottom: 1px solid rgba(96, 107, 70, 0.16);
}

.rsvp-feedback-modal .modal-title {
  font-family: var(--heading-font);
  font-style: italic;
  color: var(--primary-color);
}

.rsvp-feedback-modal .modal-body {
  text-align: center;
  padding: 1.2rem 1.1rem 0.9rem;
}

.rsvp-feedback-modal .modal-footer {
  border-top: 0;
  justify-content: center;
  padding-top: 0.3rem;
  padding-bottom: 1rem;
}

.rsvp-feedback-modal.is-locked .modal-footer,
.rsvp-feedback-modal.is-locked .rsvp-feedback-close {
  display: none !important;
}

.rsvp-feedback-envelope {
  width: min(220px, 64vw);
  height: 132px;
  margin: 0 auto 0.85rem;
  position: relative;
  border-radius: 12px;
  background: linear-gradient(160deg, #f4ece1 0%, #e9dece 100%);
  border: 1px solid rgba(96, 107, 70, 0.2);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.35), 0 8px 22px rgba(44, 44, 44, 0.12);
  overflow: hidden;
}

.rsvp-envelope-paper {
  position: absolute;
  left: 12%;
  right: 12%;
  top: 14px;
  bottom: 18px;
  background: #fffdf8;
  border-radius: 8px;
  border: 1px solid rgba(96, 107, 70, 0.16);
  transform-origin: top center;
}

.rsvp-envelope-flap {
  position: absolute;
  top: -2px;
  left: 0;
  width: 100%;
  height: 78px;
  background: linear-gradient(180deg, #ecdfcd 0%, #deceb9 100%);
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  transform-origin: top center;
}

.rsvp-feedback-envelope.is-sealing .rsvp-envelope-paper {
  animation: rsvpPaperSlide 0.8s ease forwards;
}

.rsvp-feedback-envelope.is-sealing .rsvp-envelope-flap {
  animation: rsvpFlapClose 0.8s ease forwards;
}

.rsvp-feedback-message {
  margin: 0;
  color: var(--secondary-color);
  font-size: 1rem;
}

.rsvp-feedback-message.is-success {
  color: #2f6b38;
}

.rsvp-feedback-message.is-error {
  color: #8a2437;
}

@keyframes rsvpFlapClose {
  0% {
    transform: rotateX(0deg);
  }

  100% {
    transform: rotateX(72deg);
  }
}

@keyframes rsvpPaperSlide {
  0% {
    transform: translateY(0);
    opacity: 1;
  }

  100% {
    transform: translateY(22px) scale(0.98);
    opacity: 0.75;
  }
}

@media (max-width: 767.98px) {
  .rsvp-letter-card {
    border-radius: 10px;
    padding: 1.5rem 1rem 1.3rem;
  }

  .rsvp-reserved-label {
    font-size: 1rem;
  }

  .rsvp-reserved-name {
    font-size: 1.95rem;
  }

  .rsvp-reserved-count {
    font-size: 1.2rem;
    margin-bottom: 1rem;
  }

  .rsvp-form-title {
    font-size: 2.2rem;
  }

  .rsvp-input {
    font-size: 1rem;
    padding: 0.72rem 0.9rem;
  }

  .rsvp-submit-wrap {
    justify-content: center;
  }

  .rsvp-submit-btn {
    width: 100%;
  }
}

/* --- Gift Registry Section --- */
.registry-grid {
  margin-top: 0.4rem;
}

#registry .container > p:first-of-type {
  padding-left: 7rem;
  padding-right: 7rem;
}

@media (max-width: 767.98px) {
  #registry .container > p:first-of-type {
    padding-left: 1rem;
    padding-right: 1rem;
  }
}

.registry-item {
  text-align: center;
}

.registry-image-link {
  display: inline-block;
}

.gift-logo {
  width: min(100%, 175px);
  max-width: 175px;
  filter: grayscale(100%);
  transition: filter 0.3s ease, transform 0.3s ease;
  opacity: 0.7;
}

.gift-logo:hover {
  filter: grayscale(0%);
  opacity: 1;
  transform: translateY(-3px);
}

.registry-title {
  margin-top: 1rem;
  margin-bottom: 0.25rem;
  color: var(--primary-color);
  font-size: 1.35rem;
  font-style: italic;
}

.registry-subtitle {
  max-width: 300px;
  margin: 0 auto;
  font-size: 0.92rem;
  color: var(--secondary-color);
  line-height: 1.55;
}

.registry-btn {
  margin-top: 0.9rem;
  padding: 0.75rem 1.9rem;
}

@media (max-width: 767.98px) {
  .gift-logo {
    width: min(100%, 200px);
    max-width: 200px;
  }

  .registry-title {
    margin-top: 0.85rem;
  }

  .registry-item {
    padding: 0 0.35rem;
  }
}

/* --- Footer --- */
.footer-main {
  background-color: var(--primary-color);
  color: rgba(255, 255, 255, 0.7);
}

.footer-seal-wrap {
  display: flex;
  justify-content: center;
}

.footer-seal-image {
  width: 230px;
  height: 230px;
  object-fit: cover;
}

.footer-main .footer-brand {
  font-family: var(--heading-font);
  font-size: 2rem;
  font-style: italic;
  color: #fff;
  text-decoration: none;
  display: inline-block;
  margin-bottom: 1rem;
}

.footer-main h5 {
  color: #fff;
  font-family: var(--body-font);
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.footer-main .footer-links li {
  padding-bottom: 10px;
}

.footer-main .footer-links a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: all 0.3s ease;
}

.footer-main .footer-links a:hover {
  color: #fff;
  padding-left: 5px;
}

.footer-main .contact-info i {
  color: var(--primary-color);
  margin-right: 10px;
  width: 20px;
}

.footer-main .social-icons-footer a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.1);
  color: #fff;
  text-decoration: none;
  margin-right: 10px;
  transition: all 0.3s ease;
}

.footer-main .social-icons-footer a:hover {
  background-color: var(--primary-color);
  transform: translateY(-3px);
}

.footer-closure-wrap {
  margin-top: 1.6rem;
  line-height: 0;
}

.footer-closure-image {
  display: block;
  width: 100%;
  height: 95px;
  object-fit: cover;
  object-position: center;
  opacity: 0.75;
}

.footer-bottom {
  background-color: #222;
  color: rgba(255, 255, 255, 0.5);
  padding: 20px 0;
  margin-top: 60px;
  font-size: 0.9rem;
}

.footer-bottom a {
  color: var(--primary-color);
  text-decoration: none;
}

.footer-bottom a:hover {
  text-decoration: underline;
}

@media (max-width: 767.98px) {
  .footer-main {
    padding-top: 44px;
  }

  .footer-seal-image {
    width: 108px;
    height: 108px;
  }

  .footer-closure-image {
    height: 72px;
  }
}


/* --- Single responsive strategy: mobile-first base + desktop frame only --- */

@media (hover: none), (pointer: coarse) {
  .btn-primary:hover,
  .btn-primary:active {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
    transform: none;
    box-shadow: 0 4px 15px rgba(200, 157, 156, 0.4);
  }

  .hero-btn:hover {
    color: var(--primary-color);
  }

  .hero-btn:hover::before {
    left: -100%;
  }

  .hero-btn-outline:hover {
    background-color: transparent;
    color: var(--dark-color);
  }

  .music-toggle:hover {
    transform: none;
    box-shadow: 0 6px 14px rgba(128, 0, 32, 0.3);
  }

  .event-detail-card:hover {
    transform: none;
  }

  .gallery-item:hover img {
    transform: none;
  }

  .gallery-item:hover .overlay {
    opacity: 0;
  }

  .gallery-item:hover .overlay .overlay-content {
    transform: translateY(20px);
  }

  .gift-logo:hover {
    filter: grayscale(100%);
    opacity: 0.7;
    transform: none;
  }

  .footer-main .footer-links a:hover {
    color: rgba(255, 255, 255, 0.7);
    padding-left: 0;
  }

  .footer-main .social-icons-footer a:hover {
    background-color: rgba(255, 255, 255, 0.1);
    transform: none;
  }

  .footer-bottom a:hover {
    text-decoration: none;
  }
}