:root {
  --blush: #fdd5d5;
  --sage: #84a98c;
  --ivory: #fdfaf3;
  --deep-rose: #be185d;
  --gold-leaf: #b08d4a;
  --text: #3c3c3c;
  --bg: #fdfaf3;
}

body {
  margin: 0;
  padding: 0;
  font-family: 'Lora', serif;
  color: var(--text);
  background-color: var(--bg);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.hidden {
  display: none !important;
}

.page-wrapper {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 90vh;
  background-image: url('https://offertabs.s3.amazonaws.com/offer/x9rsin/site/media/69f1185e6ac730.81139851.jpg');
  background-size: cover;
  background-position: center top;
  z-index: 0;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,0) 100%);
  -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,0) 100%);
  opacity: 0.35;
}

.container {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 650px;
  margin: 0 auto;
  padding: 60px 20px 80px;
  flex: 1;
  display: flex;
  flex-direction: column;
  box-sizing: border-box;
}

#rsvp-app {
  flex: 1;
}

/* Header Section */
.header-section {
  text-align: center;
  margin-bottom: 50px;
}

.css-arch {
  position: relative;
  width: 100%;
  max-width: 380px;
  height: 220px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

.arch-line {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}

.arch-content {
  position: relative;
  z-index: 2;
  margin-top: 50px;
}

h1.couple-names {
  font-family: 'Allura', cursive;
  font-size: 4.5rem;
  color: var(--deep-rose);
  margin: 0;
  font-weight: 400;
  line-height: 1;
}

h2.form-title {
  font-family: 'Cormorant', serif;
  font-size: 2rem;
  font-weight: 400;
  color: var(--gold-leaf);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  margin: 30px 0 10px;
}

.ceremony-details {
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--sage);
  margin-bottom: 25px;
}

.reply-by {
  font-family: 'Cormorant', serif;
  font-size: 1.6rem;
  font-style: italic;
  color: var(--deep-rose);
  margin-bottom: 20px;
}

/* Accents */
.accent-branch, .accent-flower {
  position: absolute;
  z-index: 1;
}
.accent-branch.left { bottom: 0; left: -20px; }
.accent-branch.right { bottom: 0; right: -20px; }
.accent-flower.top {
  top: -40px;
  left: 50%;
  transform: translateX(-50%);
}

/* Form Styles */
.rsvp-form {
  background: rgba(253, 250, 243, 0.92);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(176, 141, 74, 0.3);
  box-shadow: 0 25px 50px rgba(0,0,0,0.04);
  padding: 50px 45px;
  border-radius: 12px;
  position: relative;
}

.form-grid {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.input-group label {
  display: block;
  font-family: 'Cormorant', serif;
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--sage);
  margin-bottom: 10px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.input-group input[type="text"],
.input-group input[type="email"],
.input-group textarea {
  width: 100%;
  padding: 14px 16px;
  font-family: 'Lora', serif;
  font-size: 1rem;
  color: var(--text);
  background: #ffffff;
  border: 1px solid rgba(132, 169, 140, 0.4);
  border-radius: 6px;
  transition: all 0.3s ease;
  box-sizing: border-box;
}

.input-group input:focus,
.input-group textarea:focus {
  outline: none;
  border-color: var(--gold-leaf);
  box-shadow: 0 0 0 3px rgba(176, 141, 74, 0.1);
}

.input-group textarea {
  resize: vertical;
  min-height: 80px;
}

/* Custom Checkboxes and Radios */
.radio-group, .checkbox-group {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.radio-group.inline, .checkbox-group.inline {
  flex-direction: row;
  flex-wrap: wrap;
  gap: 20px;
}

.custom-radio, .custom-checkbox {
  display: flex;
  align-items: center;
  cursor: pointer;
  font-size: 1.05rem;
  color: var(--text);
  position: relative;
  padding-left: 32px;
  user-select: none;
}

.custom-radio input, .custom-checkbox input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

.radio-mark, .check-mark {
  position: absolute;
  top: 50%;
  left: 0;
  transform: translateY(-50%);
  height: 22px;
  width: 22px;
  background-color: #ffffff;
  border: 1px solid var(--sage);
  transition: all 0.2s ease;
  box-sizing: border-box;
}

.radio-mark { border-radius: 50%; }
.check-mark { border-radius: 4px; }

.custom-radio:hover .radio-mark,
.custom-checkbox:hover .check-mark {
  border-color: var(--gold-leaf);
}

.custom-radio input:checked ~ .radio-mark,
.custom-checkbox input:checked ~ .check-mark {
  background-color: var(--sage);
  border-color: var(--sage);
}

.radio-mark:after, .check-mark:after {
  content: "";
  position: absolute;
  display: none;
}

.custom-radio input:checked ~ .radio-mark:after,
.custom-checkbox input:checked ~ .check-mark:after {
  display: block;
}

.custom-radio .radio-mark:after {
  top: 6px;
  left: 6px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: white;
}

.custom-checkbox .check-mark:after {
  left: 7px;
  top: 3px;
  width: 4px;
  height: 9px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

/* Button */
.form-actions {
  margin-top: 15px;
}

.submit-btn {
  background: var(--deep-rose);
  color: white;
  border: none;
  width: 100%;
  padding: 16px;
  font-family: 'Cormorant', serif;
  font-size: 1.4rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
}

.submit-btn:hover {
  background: #a81552;
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(190, 24, 93, 0.2);
}

.submit-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.spinner {
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255,255,255,0.3);
  border-radius: 50%;
  border-top-color: #fff;
  animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Messages */
.error-message {
  background: rgba(190, 24, 93, 0.05);
  color: var(--deep-rose);
  padding: 16px;
  border-radius: 6px;
  margin-bottom: 24px;
  font-family: 'Lora', serif;
  text-align: center;
  border: 1px solid rgba(190, 24, 93, 0.2);
}

/* Result Screen */
.result-card {
  background: rgba(253, 250, 243, 0.95);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(176, 141, 74, 0.3);
  box-shadow: 0 25px 50px rgba(0,0,0,0.04);
  padding: 60px 40px;
  border-radius: 12px;
  text-align: center;
}

.monogram {
  position: relative;
  width: 100px;
  height: 100px;
  margin: 0 auto 30px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.heart-svg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.heart-path {
  stroke-dasharray: 260;
  stroke-dashoffset: 260;
  animation: drawHeart 1.5s ease-in-out forwards;
}

@keyframes drawHeart {
  to { stroke-dashoffset: 0; }
}

.monogram-text {
  font-family: 'Allura', cursive;
  font-size: 2.2rem;
  color: var(--gold-leaf);
  position: relative;
  z-index: 1;
  margin-top: -10px;
}

.result-card h2 {
  font-family: 'Cormorant', serif;
  font-size: 2.8rem;
  color: var(--sage);
  margin: 0 0 15px;
  font-weight: 400;
}

.result-message {
  font-size: 1.15rem;
  color: var(--text);
  line-height: 1.6;
}

/* Share Panel */
.share-box {
  margin-top: 40px;
  padding-top: 30px;
  border-top: 1px solid rgba(132, 169, 140, 0.3);
}

.share-box h3 {
  font-family: 'Cormorant', serif;
  font-size: 1.6rem;
  color: var(--sage);
  margin-top: 0;
  margin-bottom: 10px;
  font-weight: 400;
}

.share-input-group {
  display: flex;
  gap: 10px;
  margin-top: 20px;
  max-width: 400px;
  margin-left: auto;
  margin-right: auto;
}

.share-input-group input {
  flex: 1;
  padding: 12px;
  border: 1px solid rgba(132, 169, 140, 0.4);
  border-radius: 6px;
  font-family: 'Lora', serif;
  color: var(--text);
  background: #fff;
}

.share-input-group button {
  padding: 0 24px;
  background: var(--gold-leaf);
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-family: 'Cormorant', serif;
  font-size: 1.1rem;
  font-weight: 600;
  transition: all 0.2s;
}

.share-input-group button:hover {
  background: #9a7a3e;
}

/* Powered By */
#wbx-powered-by-slot {
  margin-top: 30px;
}

/* Mobile */
@media (max-width: 600px) {
  .container {
    padding: 30px 15px 50px;
  }
  
  .css-arch {
    max-width: 100%;
    height: 180px;
  }
  
  .arch-content {
    margin-top: 40px;
  }
  
  h1.couple-names {
    font-size: 3.5rem;
  }
  
  .rsvp-form {
    padding: 35px 25px;
  }
  
  .radio-group.inline, .checkbox-group.inline {
    flex-direction: column;
    gap: 14px;
  }
  
  .result-card {
    padding: 40px 25px;
  }
}