/* ===== Premium Invitation Design ===== */

/* Cover redesign */
.cover {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #fff;
  overflow: hidden;
  padding: 2rem 1.25rem;
  isolation: isolate;
}

.cover-bg-layer {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(165deg, #3d3229 0%, #5c4a3a 40%, #2a231c 100%);
}

.cover.has-photo .cover-bg-layer {
  background-size: cover;
  background-position: center;
}

.cover-bg-layer::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 50% 30%, rgba(201, 168, 108, 0.12) 0%, transparent 55%),
    linear-gradient(to bottom, rgba(0,0,0,0.25) 0%, rgba(0,0,0,0.45) 100%);
}

/* Decorative side trees / florals */
.cover-deco {
  position: absolute;
  z-index: 1;
  pointer-events: none;
  opacity: 0.55;
  color: var(--accent, #C9A86C);
}

.cover-deco svg {
  display: block;
  width: 100%;
  height: auto;
}

.cover-deco-left {
  left: 0;
  bottom: 0;
  width: min(42vw, 280px);
}

.cover-deco-right {
  right: 0;
  bottom: 0;
  width: min(42vw, 280px);
  transform: scaleX(-1);
}

.cover-deco-top-left {
  top: 0;
  left: 0;
  width: min(30vw, 160px);
  opacity: 0.4;
}

.cover-deco-top-right {
  top: 0;
  right: 0;
  width: min(30vw, 160px);
  opacity: 0.4;
  transform: scaleX(-1);
}

/* Cover content */
.cover-content {
  position: relative;
  z-index: 2;
  max-width: 520px;
  width: 100%;
  padding: 1.5rem 1rem;
}

.cover-frame {
  border: 1px solid rgba(201, 168, 108, 0.35);
  padding: 2.5rem 1.75rem;
  position: relative;
  background: rgba(0,0,0,0.15);
  backdrop-filter: blur(2px);
}

.cover-frame::before,
.cover-frame::after {
  content: '';
  position: absolute;
  width: 18px;
  height: 18px;
  border-color: var(--accent, #C9A86C);
  border-style: solid;
}

.cover-frame::before {
  top: -1px;
  left: -1px;
  border-width: 2px 0 0 2px;
}

.cover-frame::after {
  bottom: -1px;
  right: -1px;
  border-width: 0 2px 2px 0;
}

.cover-corner {
  position: absolute;
  width: 18px;
  height: 18px;
  border-color: var(--accent, #C9A86C);
  border-style: solid;
}

.cover-corner.tr {
  top: -1px;
  right: -1px;
  border-width: 2px 2px 0 0;
}

.cover-corner.bl {
  bottom: -1px;
  left: -1px;
  border-width: 0 0 2px 2px;
}

.guest-label {
  font-size: 0.7rem;
  letter-spacing: 4px;
  text-transform: uppercase;
  opacity: 0.8;
  font-weight: 300;
  margin-bottom: 0.4rem;
}

.guest-name {
  font-family: var(--font-heading, 'Playfair Display', serif);
  font-size: clamp(1.35rem, 4vw, 1.75rem);
  font-weight: 500;
  margin-bottom: 1.5rem;
  letter-spacing: 1px;
}

.cover-floral-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin: 1rem 0 1.25rem;
  color: var(--accent, #C9A86C);
}

.cover-floral-divider .line {
  width: 40px;
  height: 1px;
  background: currentColor;
  opacity: 0.7;
}

.cover-floral-divider svg {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

.couple-names {
  font-family: var(--font-heading, 'Playfair Display', serif);
  font-size: clamp(2.6rem, 9vw, 4.2rem);
  font-weight: 400;
  line-height: 1.15;
  letter-spacing: 1px;
  text-shadow: 0 2px 20px rgba(0,0,0,0.25);
}

.couple-and {
  font-family: var(--font-heading, 'Playfair Display', serif);
  font-style: italic;
  font-size: clamp(1.2rem, 3vw, 1.6rem);
  opacity: 0.9;
  margin: 0.35rem 0;
  font-weight: 400;
}

.cover-date {
  font-size: 0.95rem;
  letter-spacing: 3px;
  margin-top: 1.25rem;
  opacity: 0.9;
  font-weight: 300;
}

.open-btn {
  margin-top: 2.25rem;
  padding: 0.9rem 2rem;
  background: rgba(255,255,255,0.12);
  border: 1px solid rgba(255,255,255,0.45);
  color: #fff;
  backdrop-filter: blur(6px);
  border-radius: 50px;
  font-weight: 500;
  letter-spacing: 0.5px;
  transition: all 0.3s;
}

.open-btn:hover {
  background: rgba(255,255,255,0.22);
  border-color: rgba(255,255,255,0.7);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.2);
}

/* ===== Main content premium ===== */
#mainContent {
  position: relative;
  z-index: 60;
}

.section {
  position: relative;
  padding: 4rem 1.5rem;
  max-width: 860px;
  margin: 0 auto;
}

.section-title {
  text-align: center;
  font-size: clamp(1.6rem, 4vw, 2.1rem);
  color: var(--primary);
  margin-bottom: 0.35rem;
  font-weight: 500;
}

.section-ornament {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  margin: 0.75rem auto 2.25rem;
  color: var(--accent);
}

.section-ornament .line {
  width: 36px;
  height: 1px;
  background: currentColor;
  opacity: 0.6;
}

.section-ornament svg {
  width: 18px;
  height: 18px;
}

/* Countdown premium */
.countdown {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.countdown-item {
  background: #fff;
  border-radius: 12px;
  padding: 1.15rem 1.25rem;
  min-width: 78px;
  text-align: center;
  box-shadow: 0 4px 20px rgba(0,0,0,0.06);
  border: 1px solid rgba(139, 115, 85, 0.08);
  position: relative;
  overflow: hidden;
}

.countdown-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent), var(--primary));
}

.countdown-item .num {
  font-family: var(--font-heading);
  font-size: 1.85rem;
  color: var(--primary);
  display: block;
  font-weight: 500;
}

.countdown-item .label {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: #999;
  margin-top: 0.15rem;
}

/* Couple cards */
.couple-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 1rem;
  align-items: center;
}

.couple-amp {
  font-family: var(--font-heading);
  font-size: 2rem;
  color: var(--accent);
  font-style: italic;
  text-align: center;
}

.person {
  text-align: center;
  padding: 1rem 0.5rem;
}

.person-photo-wrap {
  position: relative;
  width: 160px;
  height: 160px;
  margin: 0 auto 1.25rem;
}

.person-photo {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--accent);
  box-shadow: 0 8px 28px rgba(0,0,0,0.1);
  background: #fff;
}

.person-photo-ring {
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 1px solid rgba(201, 168, 108, 0.35);
  pointer-events: none;
}

.person h3 {
  font-size: 1.4rem;
  color: var(--primary);
  margin-bottom: 0.3rem;
  font-weight: 500;
}

.person .parents {
  font-size: 0.85rem;
  color: #888;
  line-height: 1.5;
  margin-top: 0.4rem;
}

/* Story card */
.story-content {
  background: #fff;
  padding: 2.25rem 1.75rem;
  border-radius: 16px;
  box-shadow: 0 4px 24px rgba(0,0,0,0.05);
  text-align: center;
  font-size: 1.05rem;
  line-height: 1.9;
  color: #444;
  border: 1px solid rgba(139, 115, 85, 0.06);
  position: relative;
}

.story-content::before {
  content: '';
  position: absolute;
  top: 12px;
  left: 12px;
  right: 12px;
  bottom: 12px;
  border: 1px solid rgba(201, 168, 108, 0.2);
  border-radius: 10px;
  pointer-events: none;
}

.quote-block {
  text-align: center;
  padding: 1rem 1.5rem 0;
  max-width: 640px;
  margin: 0 auto;
}

.quote-block p {
  font-family: var(--font-heading);
  font-style: italic;
  font-size: clamp(1.15rem, 3vw, 1.4rem);
  color: var(--primary);
  line-height: 1.7;
  opacity: 0.95;
}

.quote-block .quote-mark {
  font-size: 2.5rem;
  color: var(--accent);
  opacity: 0.5;
  line-height: 1;
  display: block;
  margin-bottom: 0.25rem;
}

/* Events */
.events-list {
  display: grid;
  gap: 1.25rem;
}

.event-card {
  background: #fff;
  border-radius: 14px;
  padding: 1.5rem;
  box-shadow: 0 4px 20px rgba(0,0,0,0.05);
  display: flex;
  gap: 1.15rem;
  align-items: flex-start;
  border: 1px solid rgba(139, 115, 85, 0.06);
  transition: transform 0.2s;
}

.event-card:hover {
  transform: translateY(-2px);
}

.event-icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(139,115,85,0.1), rgba(201,168,108,0.15));
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  flex-shrink: 0;
}

.event-icon svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.event-info h4 {
  font-size: 1.2rem;
  color: var(--primary);
  margin-bottom: 0.3rem;
  font-weight: 500;
}

.event-info p {
  color: #888;
  font-size: 0.92rem;
  line-height: 1.5;
}

/* Gallery */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 0.65rem;
}

.gallery-item {
  aspect-ratio: 1;
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
  box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s;
}

.gallery-item:hover img {
  transform: scale(1.06);
}

/* Map */
.map-container {
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 4px 24px rgba(0,0,0,0.08);
  height: 280px;
  border: 1px solid rgba(0,0,0,0.05);
}

.map-container iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

.map-address {
  text-align: center;
  margin-top: 1rem;
  color: #777;
  font-size: 0.95rem;
}

.venue-name {
  text-align: center;
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 0.35rem;
  font-family: var(--font-heading);
}

/* Gift */
.gift-box {
  background: #fff;
  border-radius: 16px;
  padding: 2.25rem 1.75rem;
  box-shadow: 0 4px 24px rgba(0,0,0,0.05);
  text-align: center;
  border: 1px solid rgba(139, 115, 85, 0.06);
}

.gift-box .bank {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--primary);
  margin: 1rem 0 0.25rem;
}

.gift-box .account {
  font-size: 1.35rem;
  letter-spacing: 1.5px;
  margin: 0.5rem 0;
  font-family: 'Courier New', monospace;
  color: #333;
}

/* RSVP */
.rsvp-form {
  background: #fff;
  border-radius: 16px;
  padding: 2rem 1.75rem;
  box-shadow: 0 4px 24px rgba(0,0,0,0.05);
  max-width: 480px;
  margin: 0 auto;
  border: 1px solid rgba(139, 115, 85, 0.06);
}

/* Footer */
.invitation-footer {
  text-align: center;
  padding: 3.5rem 1.5rem;
  background: var(--primary);
  color: #fff;
  position: relative;
  overflow: hidden;
}

.invitation-footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
}

.invitation-footer p {
  opacity: 0.88;
  font-size: 0.95rem;
  max-width: 480px;
  margin: 0 auto;
  line-height: 1.7;
}

.invitation-footer .footer-names {
  margin-top: 1.5rem;
  font-family: var(--font-heading);
  font-size: 1.5rem;
  opacity: 1;
  font-weight: 400;
}

/* Side floral decorations for content */
.section-side-deco {
  display: none;
}

@media (min-width: 1100px) {
  .section-side-deco {
    display: block;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 80px;
    opacity: 0.2;
    color: var(--primary);
    pointer-events: none;
  }
  .section-side-deco.left { left: -100px; }
  .section-side-deco.right { right: -100px; transform: translateY(-50%) scaleX(-1); }
}

/* Mobile refinements */
@media (max-width: 640px) {
  .cover-frame {
    padding: 2rem 1.25rem;
    border-width: 1px;
  }
  .cover-deco-left,
  .cover-deco-right {
    width: min(55vw, 200px);
    opacity: 0.4;
  }
  .cover-deco-top-left,
  .cover-deco-top-right {
    width: min(35vw, 110px);
  }
  .couple-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  .couple-amp {
    display: none;
  }
  .person-photo-wrap {
    width: 140px;
    height: 140px;
  }
  .countdown-item {
    min-width: 64px;
    padding: 0.9rem 0.75rem;
  }
  .countdown-item .num {
    font-size: 1.5rem;
  }
  .section {
    padding: 3rem 1.15rem;
  }
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 641px) and (max-width: 900px) {
  .cover-deco-left,
  .cover-deco-right {
    width: min(38vw, 240px);
  }
}

/* Pattern background subtle */
body.invitation {
  background-color: var(--secondary);
  background-image:
    radial-gradient(circle at 20% 80%, rgba(201, 168, 108, 0.04) 0%, transparent 40%),
    radial-gradient(circle at 80% 20%, rgba(139, 115, 85, 0.04) 0%, transparent 40%);
}

/* Public wishes wall */
.wishes-list {
  display: grid;
  gap: 1rem;
  max-width: 560px;
  margin: 0 auto;
}

.wish-card {
  background: #fff;
  border-radius: 14px;
  padding: 1.25rem 1.35rem;
  box-shadow: 0 4px 20px rgba(0,0,0,0.05);
  border: 1px solid rgba(139, 115, 85, 0.07);
}

.wish-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
  flex-wrap: wrap;
}

.wish-name {
  font-size: 1.05rem;
  color: var(--primary, #5C4A3A);
  font-family: var(--font-heading, serif);
  font-weight: 500;
}

.wish-badge {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.2rem 0.65rem;
  border-radius: 20px;
  letter-spacing: 0.3px;
}

.wish-yes {
  background: #d4edda;
  color: #155724;
}

.wish-no {
  background: #f0f0f0;
  color: #666;
}

.wish-maybe {
  background: #fff3cd;
  color: #856404;
}

.wish-message {
  font-size: 0.95rem;
  color: #555;
  line-height: 1.65;
  margin: 0.4rem 0 0.5rem;
}

.wish-meta {
  font-size: 0.78rem;
  color: #aaa;
}

.wishes-empty {
  text-align: center;
  color: #999;
  padding: 2rem 1rem;
  font-size: 0.95rem;
}

