/* === Reset & Base === */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --gold: #c9a96e;
  --gold-light: #e8d5a8;
  --dark: #1a1a2e;
  --darker: #12121f;
  --cream: #faf6ef;
  --rose: #d4708f;
  --rose-soft: #f2d0dc;
  --text: #2c2c3a;
  --text-light: #6b6b80;
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body: 'Inter', -apple-system, sans-serif;
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--text);
  background: var(--cream);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* === Confetti Canvas === */
#confetti-canvas {
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  pointer-events: none;
  z-index: 1000;
}

/* === Hero === */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: linear-gradient(135deg, var(--dark) 0%, #2d1b3d 50%, var(--darker) 100%);
  color: var(--cream);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  width: 200%;
  height: 200%;
  top: -50%;
  left: -50%;
  background: radial-gradient(ellipse at 30% 50%, rgba(201,169,110,0.08) 0%, transparent 50%),
              radial-gradient(ellipse at 70% 50%, rgba(212,112,143,0.06) 0%, transparent 50%);
  animation: shimmer 8s ease-in-out infinite alternate;
}

@keyframes shimmer {
  0% { transform: translate(0, 0) rotate(0deg); }
  100% { transform: translate(2%, 1%) rotate(1deg); }
}

.hero-content {
  position: relative;
  z-index: 2;
  padding: 2rem;
}

.hero-pre {
  font-family: var(--font-body);
  font-weight: 300;
  font-size: 1rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold-light);
  margin-bottom: 1rem;
  opacity: 0;
  animation: fadeUp 1s 0.3s ease forwards;
}

.hero-name {
  font-family: var(--font-display);
  font-size: clamp(3rem, 10vw, 6rem);
  font-weight: 700;
  letter-spacing: 0.02em;
  background: linear-gradient(135deg, var(--gold-light), var(--gold), var(--rose-soft));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  opacity: 0;
  animation: fadeUp 1s 0.6s ease forwards;
}

.hero-divider {
  width: 60px;
  height: 2px;
  background: var(--gold);
  margin: 1.5rem auto;
  opacity: 0;
  animation: fadeUp 1s 0.9s ease forwards;
}

.hero-sub {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.15rem;
  color: var(--gold-light);
  opacity: 0;
  animation: fadeUp 1s 1.2s ease forwards;
}

.cta-btn {
  margin-top: 2.5rem;
  padding: 0.9rem 2.5rem;
  background: transparent;
  border: 1.5px solid var(--gold);
  color: var(--gold-light);
  font-family: var(--font-body);
  font-size: 0.95rem;
  letter-spacing: 0.15em;
  cursor: pointer;
  transition: all 0.3s ease;
  opacity: 0;
  animation: fadeUp 1s 1.5s ease forwards;
}

.cta-btn:hover {
  background: var(--gold);
  color: var(--dark);
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* === Sections === */
.section {
  padding: 5rem 1.5rem;
}

.container {
  max-width: 680px;
  margin: 0 auto;
}

h2 {
  font-family: var(--font-display);
  font-size: 2rem;
  text-align: center;
  margin-bottom: 0.5rem;
  color: var(--dark);
}

.section-sub, .poem-subtitle {
  text-align: center;
  color: var(--text-light);
  font-size: 0.95rem;
  margin-bottom: 2.5rem;
}

.poem-subtitle {
  font-style: italic;
  font-family: var(--font-display);
}

/* === Poem === */
.poem-section {
  background: var(--cream);
}

.poem {
  font-family: var(--font-display);
  font-size: 1.1rem;
  line-height: 1.9;
  text-align: center;
}

.poem p {
  margin-bottom: 1.8rem;
}

/* === Gallery === */
.gallery-section {
  background: var(--darker);
  color: var(--cream);
}

.gallery-section h2 { color: var(--cream); }
.gallery-section .section-sub { color: var(--gold-light); }

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1rem;
}

.gallery img {
  width: 100%;
  border-radius: 8px;
  aspect-ratio: 1;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.gallery img:hover { transform: scale(1.03); }

.gallery-placeholder {
  grid-column: 1 / -1;
  text-align: center;
  padding: 3rem;
  color: var(--gold-light);
  border: 1.5px dashed rgba(201,169,110,0.3);
  border-radius: 12px;
}

.gallery-placeholder span { font-size: 3rem; display: block; margin-bottom: 1rem; }
.gallery-placeholder p { font-size: 0.95rem; }

/* === Guestbook === */
.guestbook-section {
  background: linear-gradient(180deg, var(--cream) 0%, #f5ede0 100%);
}

.guestbook-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2.5rem;
}

.guestbook-form input,
.guestbook-form textarea {
  font-family: var(--font-body);
  font-size: 1rem;
  padding: 0.9rem 1.2rem;
  border: 1.5px solid #d9d0c3;
  border-radius: 8px;
  background: white;
  color: var(--text);
  transition: border-color 0.2s;
  resize: vertical;
}

.guestbook-form input:focus,
.guestbook-form textarea:focus {
  outline: none;
  border-color: var(--gold);
}

.submit-btn {
  padding: 0.9rem;
  background: var(--dark);
  color: var(--cream);
  border: none;
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 1rem;
  cursor: pointer;
  transition: background 0.3s;
}

.submit-btn:hover { background: #2d1b3d; }

.messages {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.message-card {
  background: white;
  border-radius: 10px;
  padding: 1.2rem 1.5rem;
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
  animation: fadeUp 0.4s ease;
}

.message-card .msg-author {
  font-weight: 500;
  color: var(--dark);
  margin-bottom: 0.3rem;
}

.message-card .msg-text {
  color: var(--text-light);
  line-height: 1.6;
}

.message-card .msg-time {
  font-size: 0.8rem;
  color: #b0a898;
  margin-top: 0.5rem;
}

/* === Footer === */
footer {
  text-align: center;
  padding: 2rem;
  background: var(--darker);
  color: var(--gold-light);
  font-size: 0.85rem;
}

/* === Responsive === */
@media (max-width: 480px) {
  .section { padding: 3.5rem 1.2rem; }
  .poem { font-size: 1rem; }
}
