@import url('https://fonts.googleapis.com/css2?family=Allura&family=Amatic+SC:wght@400;700&family=Cinzel:wght@400;600;700&family=Cormorant+Garamond:wght@400;600;700&family=Dancing+Script:wght@400;600;700&family=Great+Vibes&family=Libre+Baskerville:wght@400;700&family=Lora:wght@400;600;700&family=Merriweather:wght@400;700&family=Montserrat:wght@400;600;700&family=Pacifico&family=Playfair+Display:wght@400;600;700&family=Poppins:wght@400;600;700&family=Raleway:wght@400;600;700&display=swap');
:root {
  --primary: #2e3a2f;
  --accent: #9b7d6a;
  --light: #f4f1ed;
  --dark: #1f1f1f;
  --title-font: "Georgia", "Times New Roman", serif;
  --title-size: clamp(2rem, 5vw, 3.5rem);
  --title-color: #1f1f1f;
  --button-font: "Georgia", "Times New Roman", serif;
}

* {
  box-sizing: border-box;
}

.hidden {
  display: none;
}

body {
  margin: 0;
  font-family: "Georgia", "Times New Roman", serif;
  background: var(--light);
  color: var(--dark);
  overflow-x: hidden;
}

#app {
  width: 100%;
}

.page-shell {
  display: grid;
  grid-template-columns: clamp(200px, 22vw, 560px) minmax(0, 1fr) clamp(200px, 22vw, 560px);
  min-height: 100vh;
  width: 100%;
}

.center-column {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.hero {
  position: relative;
  min-height: clamp(360px, 60vh, 960px);
  background: linear-gradient(120deg, #cbb5a4, #e9d9cc);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.title-in-banner {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
  min-width: 0;
  padding: 0 12px;
  transition: opacity 0.2s ease-out;
}

.title-in-banner.title-loading {
  opacity: 0;
  pointer-events: none;
}

#pageTitle {
  margin: 0;
  font-size: var(--title-size, clamp(1.25rem, 3vw, 2rem));
  font-family: var(--title-font, var(--button-font, "Georgia", "Times New Roman", serif));
  color: var(--title-color, var(--button-text, #1f1f1f));
  text-align: center;
  letter-spacing: 1px;
  font-weight: 600;
}

.title-text.hidden {
  display: none;
}

.title-image {
  max-width: 100%;
  max-height: 48px;
  width: auto;
  height: auto;
  object-fit: contain;
}

.admin-toggle {
  border: 1px solid rgba(0, 0, 0, 0.2);
  background-color: var(--button-bg, rgba(255, 255, 255, 0.8));
  background-image: var(--button-bg-image, none);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: var(--button-text, var(--dark));
  font-family: var(--button-font, "Georgia", "Times New Roman", serif);
  padding: 8px 16px;
  border-radius: 999px;
  cursor: pointer;
  position: absolute;
  top: 16px;
  right: 16px;
}

.tabs {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background-color: var(--button-bg, white);
  background-image: var(--button-bg-image, none);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  position: sticky;
  top: 0;
  z-index: 2;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.tabs-with-title {
  flex-wrap: wrap;
}

.tabs-with-title .title-in-banner {
  flex: none;
  flex-basis: 100%;
  width: 100%;
  margin-bottom: 8px;
}

.tab-button {
  border: none;
  background-color: var(--button-bg, var(--light));
  background-image: var(--button-bg-image, none);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: var(--button-text, var(--dark));
  font-family: var(--button-font, "Georgia", "Times New Roman", serif);
  font-size: 1.05rem;
  padding: 12px 20px;
  border-radius: 999px;
  cursor: pointer;
  font-weight: 600;
}

.tab-button.active {
  background-color: var(--button-bg, var(--primary));
  color: var(--button-text, white);
  filter: brightness(0.95);
}

main {
  flex: 1;
  padding: 24px 24px 48px;
}

.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

.side-banner {
  background: #d4c4b9;
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  min-height: 100vh;
  border-radius: 0;
}

.home-content {
  background: white;
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.08);
}

.home-content.full-width {
  width: 100%;
}

.location-content {
  display: grid;
  gap: 16px;
}

.location-text {
  margin: 0;
  white-space: pre-line;
  line-height: 1.6;
}

.location-text.muted {
  color: #6b5d52;
}

.location-image-wrapper {
  display: flex;
  justify-content: center;
}

.location-image {
  max-width: 100%;
  max-height: 480px;
  border-radius: 12px;
  object-fit: contain;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
}

.intro-text {
  font-size: 1.1rem;
  margin-top: 0;
}

.admin-panel {
  margin-top: 24px;
  padding: 18px;
  border-radius: 12px;
  background: #faf7f3;
  border: 1px solid #e0d4c8;
}

.admin-panel.hidden {
  display: none;
}

.admin-section {
  margin-bottom: 28px;
  padding-bottom: 24px;
  border-bottom: 1px solid #e5d8cc;
}

.admin-section:last-of-type {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.admin-section-title {
  margin: 0 0 4px;
  font-size: 1rem;
  font-weight: 700;
  color: var(--dark, #1f1f1f);
}

.admin-section-desc {
  margin: 0 0 14px;
  font-size: 0.85rem;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

input[type="text"],
input[type="color"],
input[type="number"],
select,
textarea {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid #d7c9bd;
  font-family: inherit;
  font-size: 1rem;
}

textarea {
  resize: vertical;
}

.primary {
  background-color: var(--button-bg, var(--primary));
  background-image: var(--button-bg-image, none);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: var(--button-text, white);
  font-family: var(--button-font, "Georgia", "Times New Roman", serif);
  font-size: 1.05rem;
  border: none;
  padding: 12px 20px;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
}

.host-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 12px;
  margin-bottom: 12px;
}

@media (max-width: 600px) {
  .host-row {
    grid-template-columns: 1fr;
  }
}

.divider {
  height: 1px;
  background: #e5d8cc;
  margin: 24px 0;
}

.hint {
  font-size: 0.9rem;
  color: #6b5d52;
}

.hint small,
small.hint {
  font-size: 0.85rem;
}

.section-header {
  margin-bottom: 18px;
}

.rsvp-section {
  padding-top: 0;
}

.rsvp-instructions {
  margin-bottom: 20px;
  padding: 16px 18px;
  background: rgba(0, 0, 0, 0.03);
  border-radius: 10px;
  border-left: 4px solid var(--primary, #6b7f5c);
}

.rsvp-instructions p {
  margin: 0 0 8px 0;
  line-height: 1.5;
}

.rsvp-instructions p:last-of-type {
  margin-bottom: 16px;
}

.rsvp-search-field {
  margin-top: 4px;
}

.rsvp-search-field label {
  display: block;
  margin-bottom: 6px;
  font-weight: 600;
  font-size: 0.95rem;
}

.rsvp-search-field input {
  width: 100%;
  max-width: 320px;
  padding: 10px 14px;
  font-size: 1rem;
  border: 1px solid rgba(0, 0, 0, 0.15);
  border-radius: 8px;
}

.list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.list li {
  background: white;
  padding: 12px 16px;
  border-radius: 12px;
  margin-bottom: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.wishlist-item {
  display: flex;
  align-items: center;
  gap: 16px;
  justify-content: space-between;
}

.wishlist-text {
  flex: 1;
}

.wishlist-action {
  display: flex;
}

.notice {
  background: #fff1c6;
  padding: 12px 16px;
  border-radius: 12px;
  margin-bottom: 16px;
  border: 1px solid #f2d89a;
}

.notice.hidden {
  display: none;
}

.notice--host-contact {
  background: #f8f4ef;
  border-color: #e5d8cc;
  padding: 16px;
}

.host-contact-title {
  margin: 0 0 6px;
  font-weight: 700;
  font-size: 1rem;
  color: var(--dark, #1f1f1f);
}

.host-contact-intro {
  margin: 0 0 14px;
  font-size: 0.9rem;
  color: #5c524a;
  line-height: 1.4;
}

.host-contact-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.host-contact-person {
  padding: 12px 14px;
  background: white;
  border-radius: 10px;
  margin-bottom: 10px;
  border: 1px solid #e5d8cc;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.host-contact-person:last-child {
  margin-bottom: 0;
}

.host-contact-name {
  display: block;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--dark, #1f1f1f);
  margin-bottom: 6px;
}

.host-contact-details {
  display: block;
  font-size: 0.9rem;
  color: #5c524a;
  line-height: 1.5;
}

.host-contact-details a {
  color: var(--primary, #2e3a2f);
  text-decoration: none;
}

.host-contact-details a:hover {
  text-decoration: underline;
}

.host-contact-empty {
  font-size: 0.9rem;
  color: #5c524a;
  margin: 0;
}

.guest-list {
  display: grid;
  gap: 12px;
}

.guest-list-hint {
  color: var(--muted, #666);
  padding: 20px 16px;
  text-align: center;
  font-size: 0.95rem;
}

.guest-card {
  background: white;
  padding: 16px;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.guest-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--dark);
}

.guest-actions {
  display: flex;
  justify-content: flex-end;
}

.guest-status {
  font-size: 0.9rem;
  color: #6b5d52;
}

.checkbox-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 5;
  padding: 24px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.modal.hidden {
  display: none;
}

.modal-card {
  background: white;
  border-radius: 16px;
  padding: 24px;
  width: 100%;
  max-width: 520px;
  max-height: calc(100vh - 48px);
  overflow-y: auto;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.2);
  -webkit-overflow-scrolling: touch;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.icon-button {
  border: none;
  background: none;
  font-size: 1.2rem;
  cursor: pointer;
}

.modal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 16px;
}

.modal-text {
  margin: 0 0 16px;
}

.checkbox-row {
  display: flex;
  gap: 10px;
  align-items: center;
}

.secondary {
  background-color: var(--button-bg, #e7ddd3);
  background-image: var(--button-bg-image, none);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: var(--button-text, var(--dark));
  font-family: var(--button-font, "Georgia", "Times New Roman", serif);
  font-size: 1.05rem;
  border: none;
  padding: 12px 20px;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
}

.danger {
  background-color: var(--button-bg, #b24b3a);
  background-image: var(--button-bg-image, none);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  color: var(--button-text, white);
  font-family: var(--button-font, "Georgia", "Times New Roman", serif);
  font-size: 1.05rem;
  border: none;
  padding: 12px 20px;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 600;
}

.danger[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
}

.danger.hidden {
  display: none;
}

@media (max-width: 900px) {
  .side-banner {
    display: none;
  }

  .page-shell {
    grid-template-columns: 1fr;
  }

  .tabs {
    justify-content: flex-start;
    overflow-x: auto;
    padding: 12px 12px;
  }

  .tab-button {
    flex: 0 0 auto;
  }

  main {
    padding: 18px 16px 36px;
  }
}

@media (max-width: 600px) {
  .hero {
    min-height: 45vh;
  }

  #pageTitle {
    font-size: clamp(1.1rem, 4vw, 1.5rem);
  }

  .title-in-banner {
    padding: 0 8px;
  }

  .tab-button {
    padding: 10px 14px;
    font-size: 0.95rem;
  }

  .home-content {
    padding: 18px;
  }

  .admin-toggle {
    top: 12px;
    right: 12px;
  }

  .modal-card {
    max-width: 100%;
    padding: 18px;
  }
}
