@import url('https://fonts.googleapis.com/css2?family=Dancing+Script:wght@400;700&display=swap');

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  height: 100%;
  font-family: 'Dancing Script', cursive;
  background: #fff;
  color: #333;
}

/* Nav */
nav {
  position: sticky;
  top: 0;
  z-index: 10;
  background: #fff;
  border-bottom: 1px solid #e0d8cf;
  padding: 0.6rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  font-size: 1.3rem;
  font-weight: 700;
  color: #333;
  text-decoration: none;
  white-space: nowrap;
}

.nav-brand:hover {
  color: #8b6f5e;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 2rem;
}

nav a {
  text-decoration: none;
  color: #333;
  font-size: 1.25rem;
  font-weight: 700;
  transition: color 0.2s;
}

nav a:hover {
  color: #8b6f5e;
}

nav a.active {
  color: #8b6f5e;
  border-bottom: 2px solid #8b6f5e;
  padding-bottom: 2px;
}

/* Burger - hidden on desktop */
.burger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  flex-direction: column;
  gap: 5px;
}

.burger span {
  display: block;
  width: 24px;
  height: 2px;
  background: #333;
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s;
}

/* Burger animation when open */
.burger[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.burger[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.burger[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Main content */
main {
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 1rem;
}

.home-container {
  position: relative;
  max-height: calc(100vh - 60px);
  width: auto;
  display: flex;
  justify-content: center;
}

.home-container img {
  max-height: calc(100vh - 60px);
  max-width: 100%;
  height: auto;
  width: auto;
  object-fit: contain;
}

.details-container {
  position: relative;
  max-height: calc(100vh - 60px);
  width: auto;
  display: flex;
  justify-content: center;
}

.details-container img {
  max-height: calc(100vh - 60px);
  max-width: 100%;
  height: auto;
  width: auto;
  object-fit: contain;
}

.gift-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 2rem 1rem;
  max-width: 600px;
  width: 100%;
}

.gift-message {
  font-weight: 400;
  font-size: 1.15rem;
  line-height: 1.7;
  text-align: center;
  color: #555;
  margin-bottom: 2rem;
}

.gift-message p {
  margin-bottom: 1rem;
}

.gift-message p:last-child {
  margin-bottom: 0;
}

.gift-photo {
  width: 100%;
  max-width: 400px;
  border-radius: 8px;
  margin: 1rem 0;
}

.gift-donate-btn {
  display: inline-block;
  background: #ad29b6;
  color: #fff;
  font-family: 'Dancing Script', cursive;
  font-size: 1.4rem;
  font-weight: 700;
  padding: 0.9rem 2.5rem;
  border-radius: 6px;
  text-decoration: none;
  transition: background 0.2s;
}

.gift-donate-btn:hover {
  background: #8a1f91;
}

/* RSVP */
.rsvp-container {
  max-width: 600px;
  width: 100%;
  padding: 2rem 1rem;
}

.rsvp-form,
.rsvp-summary {
  font-weight: 400;
  font-size: 1.15rem;
  line-height: 1.7;
  color: #555;
}

.rsvp-attendance {
  border: none;
  margin-bottom: 1.5rem;
}

.rsvp-attendance legend {
  font-size: 1.5rem;
  font-weight: 700;
  color: #333;
  margin-bottom: 1rem;
  text-align: center;
  width: 100%;
}

.rsvp-radio {
  display: block;
  padding: 0.7rem 1rem;
  margin-bottom: 0.5rem;
  border: 1px solid #e0d8cf;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.2s;
  text-align: center;
}

.rsvp-radio:hover {
  background: #faf8f5;
}

.rsvp-radio input {
  margin-right: 0.5rem;
  accent-color: #8b6f5e;
}

.rsvp-radio input:checked + span {
  color: #333;
  font-weight: 700;
}

.rsvp-guests {
  margin-bottom: 1.5rem;
}

.rsvp-guest {
  border: 1px solid #e0d8cf;
  border-radius: 6px;
  padding: 1rem;
  margin-bottom: 1rem;
}

.rsvp-guest h3 {
  font-size: 1.2rem;
  color: #333;
  margin-bottom: 0.8rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.rsvp-guest label {
  display: block;
  margin-bottom: 0.8rem;
  color: #777;
  font-size: 1rem;
}

.rsvp-input {
  display: block;
  width: 100%;
  margin-top: 0.3rem;
  padding: 0.5rem 0.7rem;
  font-family: 'Dancing Script', cursive;
  font-size: 1.1rem;
  border: 1px solid #e0d8cf;
  border-radius: 4px;
  color: #333;
}

.rsvp-input:focus {
  outline: none;
  border-color: #8b6f5e;
}

.rsvp-textarea {
  resize: vertical;
  min-height: 60px;
}

.rsvp-add-btn {
  background: none;
  border: 1px dashed #ccc;
  border-radius: 6px;
  padding: 0.6rem 1rem;
  font-family: 'Dancing Script', cursive;
  font-size: 1.1rem;
  color: #8b6f5e;
  cursor: pointer;
  width: 100%;
  transition: background 0.2s;
}

.rsvp-add-btn:hover {
  background: #faf8f5;
}

.rsvp-remove-btn {
  background: none;
  border: none;
  font-family: 'Dancing Script', cursive;
  font-size: 0.95rem;
  color: #c66;
  cursor: pointer;
  padding: 0;
}

.rsvp-remove-btn:hover {
  text-decoration: underline;
}

.rsvp-submit-btn {
  display: block;
  width: 100%;
  background: #8b6f5e;
  color: #fff;
  font-family: 'Dancing Script', cursive;
  font-size: 1.3rem;
  font-weight: 700;
  padding: 0.8rem;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.2s;
}

.rsvp-submit-btn:hover {
  background: #74594a;
}

.rsvp-summary {
  text-align: center;
}

.rsvp-summary h2 {
  font-size: 1.6rem;
  color: #333;
  margin-bottom: 1rem;
}

.rsvp-summary h3 {
  font-size: 1.2rem;
  color: #333;
  margin: 1rem 0 0.5rem;
}

.rsvp-summary-guest {
  padding: 0.5rem 0;
  border-bottom: 1px solid #f0ece7;
}

.rsvp-summary-actions {
  margin-top: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.rsvp-forget-btn {
  background: none;
  border: none;
  font-family: 'Dancing Script', cursive;
  font-size: 1rem;
  color: #999;
  cursor: pointer;
  text-decoration: underline;
}

.rsvp-forget-btn:hover {
  color: #c66;
}

/* RSVP Modal */
.rsvp-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 100;
  padding: 1rem;
}

.rsvp-modal[hidden] {
  display: none;
}

.rsvp-modal-content {
  background: #fff;
  border-radius: 10px;
  padding: 2rem;
  max-width: 500px;
  width: 100%;
  max-height: 80vh;
  overflow-y: auto;
  text-align: center;
  font-weight: 400;
  font-size: 1.15rem;
  line-height: 1.7;
  color: #555;
}

.rsvp-modal-content h2 {
  font-size: 1.6rem;
  color: #333;
  margin-bottom: 1rem;
}

.rsvp-modal-content h3 {
  font-size: 1.2rem;
  color: #333;
  margin: 1rem 0 0.5rem;
}

.rsvp-modal-content .rsvp-submit-btn {
  margin-top: 1.5rem;
}

/* Map */
main:has(.map-container) {
  padding: 0;
  display: block;
}

.map-container {
  width: 100%;
  height: calc(100vh - 52px);
}

/* Coming soon page */
.coming-soon {
  font-size: 2rem;
  font-weight: 400;
  color: #555;
  text-align: center;
  padding: 4rem 1rem;
}

/* Clickable overlay for JustGiving link */
.details-container .link-overlay {
  position: absolute;
  /* Positioned over the "www.justgiving.com/page/pamelaparker" text */
  top: 77.5%;
  left: 16%;
  width: 68%;
  height: 2.8%;
  cursor: pointer;
  z-index: 2;
}

.details-container .link-overlay:hover {
  background: rgba(139, 111, 94, 0.08);
  border-radius: 4px;
}

/* Mobile */
@media (max-width: 768px) {
  .burger {
    display: flex;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: #fff;
    border-bottom: 1px solid #e0d8cf;
    flex-direction: column;
    padding: 1rem 1.5rem;
    gap: 1rem;
    min-width: 200px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    font-size: 1.1rem;
  }

  main {
    padding: 0;
  }

  .home-container {
    max-height: none;
    width: 100%;
  }

  .home-container img {
    max-height: none;
    width: 100%;
    height: auto;
  }

  .details-container {
    max-height: none;
    width: 100%;
  }

  .details-container img {
    max-height: none;
    width: 100%;
    height: auto;
  }
}
