@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,500;0,600;0,700;1,400;1,500;1,600&family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;0,600;1,300;1,400;1,500&display=swap');

:root {
  --cream: #FDF8F0;
  --cream-dark: #F5EDE0;
  --rose-deep: #8B1A2B;
  --rose-mid: #C4445A;
  --rose-light: #E8A0AA;
  --rose-blush: #F5D5DA;
  --leaf-green: #4A7C59;
  --leaf-light: #8BB174;
  --text-dark: #2C2320;
  --text-muted: #6B5E58;
  --text-light: #9B8E87;
  --shadow-soft: 0 2px 20px rgba(44, 35, 32, 0.06);
  --shadow-med: 0 4px 30px rgba(44, 35, 32, 0.1);
}

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

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'Cormorant Garamond', Georgia, serif;
  background: var(--cream);
  color: var(--text-dark);
  line-height: 1.8;
  overflow-x: hidden;
}

/* ===== NAVIGATION ===== */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(253, 248, 240, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(139, 26, 43, 0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
nav.scrolled { box-shadow: 0 2px 20px rgba(44, 35, 32, 0.08); }
nav .nav-inner {
  max-width: 1200px; margin: 0 auto;
  display: flex; align-items: center; justify-content: center;
  padding: 16px 30px;
}
nav .nav-name {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 17px; font-weight: 500;
  color: var(--rose-deep);
  text-decoration: none; letter-spacing: 0.03em;
}
nav .nav-links {
  display: flex; gap: 28px; list-style: none; align-items: center;
  justify-content: center;
}
nav .nav-links a {
  font-size: 15px; color: var(--text-muted);
  text-decoration: none; letter-spacing: 0.06em;
  text-transform: uppercase; font-weight: 500;
  transition: color 0.2s;
  position: relative;
}
nav .nav-links a:hover,
nav .nav-links a.active { color: var(--rose-deep); }
nav .nav-links a.active::after {
  content: ''; position: absolute;
  bottom: -4px; left: 0; right: 0;
  height: 2px; background: var(--rose-mid);
  border-radius: 1px;
}

/* Mobile hamburger */
.hamburger {
  display: none; background: none; border: none; cursor: pointer;
  padding: 4px; color: var(--rose-deep);
}
.hamburger svg { width: 24px; height: 24px; }

@media (max-width: 768px) {
  .hamburger { display: block; }
  nav .nav-links {
    display: none; position: absolute;
    top: 100%; left: 0; right: 0;
    flex-direction: column; gap: 0;
    background: rgba(253, 248, 240, 0.98);
    border-bottom: 1px solid rgba(139, 26, 43, 0.1);
    padding: 10px 0;
  }
  nav .nav-links.open { display: flex; }
  nav .nav-links a {
    padding: 12px 30px; display: block;
    border-bottom: 1px solid rgba(139, 26, 43, 0.05);
  }
}

/* ===== TYPOGRAPHY ===== */
h1, h2, h3, h4 { font-family: 'Playfair Display', Georgia, serif; font-weight: 500; }
h1 { font-size: clamp(36px, 5vw, 72px); line-height: 1.15; color: var(--text-dark); }
h2 { font-size: clamp(28px, 3.5vw, 48px); line-height: 1.2; color: var(--rose-deep); }
h3 { font-size: clamp(22px, 2.5vw, 32px); line-height: 1.3; color: var(--text-dark); }
p { font-size: clamp(17px, 1.2vw, 20px); line-height: 1.9; color: var(--text-muted); }
.script { font-family: 'Playfair Display', Georgia, serif; font-style: italic; }

/* ===== LAYOUT ===== */
.container { max-width: 1200px; margin: 0 auto; padding: 0 30px; }
.narrow { max-width: 800px; }
section { padding: 80px 0; }
section + section { border-top: 1px solid rgba(139, 26, 43, 0.06); }

/* ===== DECORATIVE ELEMENTS ===== */
.divider {
  width: 80px; height: 2px; margin: 24px auto;
  background: linear-gradient(90deg, transparent, var(--rose-mid), transparent);
}
.divider-left {
  width: 60px; height: 2px; margin: 16px 0;
  background: linear-gradient(90deg, var(--rose-mid), transparent);
}

/* Floral corners */
.floral-corner { position: fixed; z-index: 50; pointer-events: none; opacity: 0.4; }
.floral-tl { top: -10px; left: -10px; width: 180px; height: 180px; }
.floral-br { bottom: -10px; right: -10px; width: 180px; height: 180px; transform: rotate(180deg); }
@media (max-width: 768px) {
  .floral-corner { opacity: 0.25; }
  .floral-tl { width: 120px; height: 120px; }
  .floral-br { width: 120px; height: 120px; }
}

/* ===== HERO (Home page) ===== */
.hero {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  text-align: center; padding: 60px 20px 80px;
  position: relative;
}
.hero-content { max-width: 700px; }
.hero .portrait {
  width: clamp(200px, 28vw, 320px); height: clamp(200px, 28vw, 320px);
  border-radius: 50%; object-fit: cover;
  object-position: center 20%;
  border: 4px solid var(--rose-light);
  box-shadow: 0 8px 40px rgba(139, 26, 43, 0.12);
  margin-bottom: 30px;
}
.hero .subtitle {
  font-size: clamp(14px, 1.6vw, 20px);
  text-transform: uppercase; letter-spacing: 0.3em;
  color: var(--text-muted); margin-bottom: 8px;
}
.hero .dates {
  font-size: clamp(16px, 1.8vw, 24px);
  color: var(--text-muted); letter-spacing: 0.12em;
  margin-bottom: 30px;
}
.hero .tagline {
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic; font-size: clamp(18px, 2vw, 26px);
  color: var(--rose-deep); line-height: 1.6;
  max-width: 550px; margin: 0 auto 40px;
}
.hero .scroll-hint {
  font-size: 13px; color: var(--text-light);
  letter-spacing: 0.15em; text-transform: uppercase;
  animation: gentle-bounce 2.5s ease-in-out infinite;
}
@keyframes gentle-bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(6px); }
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-block; padding: 14px 36px;
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 16px; font-weight: 500;
  letter-spacing: 0.12em; text-transform: uppercase;
  text-decoration: none; border-radius: 6px;
  transition: all 0.25s ease; cursor: pointer;
}
.btn-primary {
  background: var(--rose-deep); color: var(--cream);
  border: 2px solid var(--rose-deep);
}
.btn-primary:hover { background: #7A1625; border-color: #7A1625; }
.btn-outline {
  background: transparent; color: var(--rose-deep);
  border: 2px solid rgba(139, 26, 43, 0.25);
}
.btn-outline:hover { border-color: var(--rose-deep); background: rgba(139, 26, 43, 0.04); }

/* ===== CARDS ===== */
.card {
  background: white; border-radius: 8px;
  box-shadow: var(--shadow-soft); padding: 30px;
  border: 1px solid rgba(139, 26, 43, 0.06);
}

/* ===== PHOTO GRID ===== */
.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
}
.photo-grid img {
  width: 100%; aspect-ratio: 1;
  object-fit: cover; border-radius: 4px;
  cursor: pointer; transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.photo-grid img:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-med);
}

/* ===== LIGHTBOX ===== */
.lightbox, .lightbox-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(44, 35, 32, 0.92);
  display: none; align-items: center; justify-content: center;
  cursor: pointer;
}
.lightbox.active, .lightbox-overlay.active { display: flex; }
.lightbox img, .lightbox-overlay .lightbox-img {
  max-width: 90%; max-height: 90%;
  object-fit: contain; border-radius: 4px;
  box-shadow: 0 8px 60px rgba(0, 0, 0, 0.3);
}
.lightbox .close-btn, .lightbox-overlay .lightbox-close {
  position: absolute; top: 20px; right: 20px;
  background: none; border: none; color: rgba(255, 255, 255, 0.7);
  font-size: 32px; cursor: pointer; transition: color 0.2s;
}
.lightbox .close-btn:hover, .lightbox-overlay .lightbox-close:hover { color: white; }
.lightbox-overlay .lightbox-prev,
.lightbox-overlay .lightbox-next {
  position: absolute; top: 50%; transform: translateY(-50%);
  background: none; border: none; color: rgba(255, 255, 255, 0.7);
  font-size: 48px; cursor: pointer; transition: color 0.2s;
  padding: 20px;
}
.lightbox-overlay .lightbox-prev { left: 10px; }
.lightbox-overlay .lightbox-next { right: 10px; }
.lightbox-overlay .lightbox-prev:hover,
.lightbox-overlay .lightbox-next:hover { color: white; }

/* ===== TIMELINE ===== */
.timeline { position: relative; padding: 20px 0; }
.timeline::before {
  content: ''; position: absolute;
  left: 50%; top: 0; bottom: 0;
  width: 2px; background: linear-gradient(to bottom, transparent, var(--rose-light), transparent);
  transform: translateX(-50%);
}
.timeline-item {
  display: flex; align-items: flex-start;
  margin-bottom: 40px; position: relative;
}
.timeline-item:nth-child(odd) { flex-direction: row-reverse; text-align: right; }
.timeline-item .content {
  width: 45%; padding: 20px 30px;
}
.timeline-item .year {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 24px; color: var(--rose-deep);
  margin-bottom: 6px;
}
.timeline-item .dot {
  position: absolute; left: 50%; top: 24px;
  width: 14px; height: 14px; border-radius: 50%;
  background: var(--rose-mid); border: 3px solid var(--cream);
  box-shadow: 0 0 0 2px var(--rose-light);
  transform: translateX(-50%); z-index: 2;
}

@media (max-width: 768px) {
  .timeline::before { left: 20px; }
  .timeline-item,
  .timeline-item:nth-child(odd) { flex-direction: row; text-align: left; }
  .timeline-item .content { width: calc(100% - 50px); margin-left: 50px; }
  .timeline-item .dot { left: 20px; }
}

/* ===== GUESTBOOK / MEMORIES ===== */
.memory-form {
  max-width: 600px; margin: 0 auto 60px;
}
.memory-form .form-group { margin-bottom: 20px; }
.memory-form label {
  display: block; font-size: 14px; font-weight: 500;
  letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--text-muted); margin-bottom: 6px;
}
.memory-form input[type="text"],
.memory-form textarea {
  width: 100%; padding: 12px 16px;
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 17px; color: var(--text-dark);
  background: white; border: 1px solid rgba(139, 26, 43, 0.15);
  border-radius: 6px; transition: border-color 0.2s;
}
.memory-form input:focus,
.memory-form textarea:focus {
  outline: none; border-color: var(--rose-mid);
}
.memory-form textarea { min-height: 120px; resize: vertical; }
.memory-form .file-input-wrap {
  position: relative; display: inline-block;
}
.memory-form input[type="file"] {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 15px; color: var(--text-muted);
}

.memories-list { max-width: 700px; margin: 0 auto; }
.memory-card {
  background: white; border-radius: 8px;
  box-shadow: var(--shadow-soft); padding: 28px;
  border: 1px solid rgba(139, 26, 43, 0.06);
  margin-bottom: 24px;
  transition: box-shadow 0.4s ease;
}
.memory-card.highlight {
  box-shadow: 0 0 0 3px rgba(139, 26, 43, 0.3), var(--shadow-soft);
}
.memory-card .meta {
  display: flex; justify-content: space-between; align-items: baseline;
  margin-bottom: 12px; flex-wrap: wrap; gap: 8px;
}
.memory-card .author {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 20px; color: var(--text-dark);
}
.memory-card .relationship {
  font-size: 14px; color: var(--text-light);
  font-style: italic;
}
.memory-card .date {
  font-size: 13px; color: var(--text-light);
  letter-spacing: 0.05em;
}
.memory-card .message {
  font-size: 18px; line-height: 1.8;
  color: var(--text-muted);
}
.memory-card .memory-photo {
  margin-top: 16px; max-width: 100%;
  border-radius: 6px; box-shadow: var(--shadow-soft);
}

/* ===== DONATION CARDS ===== */
.donation-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px; margin-top: 30px;
}
.donation-card {
  background: white; border-radius: 8px;
  box-shadow: var(--shadow-soft); padding: 30px;
  border: 1px solid rgba(139, 26, 43, 0.06);
  text-align: center;
}
.donation-card h4 {
  font-size: 20px; color: var(--rose-deep); margin-bottom: 10px;
}
.donation-card p {
  font-size: 16px; color: var(--text-muted);
}

/* ===== MOSAIC ===== */
.mosaic-wrap {
  width: 100%; overflow: hidden; border-radius: 8px;
  box-shadow: var(--shadow-med); margin: 40px 0;
}
.mosaic-wrap img { width: 100%; display: block; }

/* ===== FOOTER ===== */
footer {
  background: var(--cream-dark);
  border-top: 1px solid rgba(139, 26, 43, 0.08);
  padding: 40px 30px; text-align: center;
}
footer .container { text-align: center; }
footer .closing, footer .script {
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic; font-size: clamp(16px, 1.6vw, 22px);
  color: var(--rose-deep); max-width: 600px; margin: 0 auto 16px;
  line-height: 1.6; text-align: center;
}
footer .copy, footer p:last-child {
  font-size: 17px; color: var(--text-light);
  letter-spacing: 0.05em; text-align: center;
}

/* Centered blockquote */
blockquote.script {
  text-align: center; max-width: 600px; margin: 0 auto;
  font-size: clamp(18px, 2vw, 26px); color: var(--rose-deep);
  line-height: 1.6;
}

/* ===== FADE-IN ANIMATION ===== */
.fade-in {
  opacity: 0; transform: translateY(20px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
.fade-in.visible { opacity: 1; transform: translateY(0); }

/* ===== PAGE TITLE (inner pages) ===== */
.page-title {
  text-align: center;
  padding-top: 100px;
  padding-bottom: 10px;
}
.page-title h2 {
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic;
  font-weight: 400;
  font-size: clamp(26px, 3vw, 40px);
  color: var(--rose-deep);
  letter-spacing: 0.02em;
  margin-bottom: 0;
}

/* ===== STORY LAYOUT (bio + timeline side-by-side) ===== */
.story-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 60px;
  align-items: start;
}
.story-bio { max-width: 700px; }
.story-timeline {
  position: sticky; top: 100px;
  padding: 30px;
  background: white;
  border-radius: 8px;
  box-shadow: var(--shadow-soft);
  border: 1px solid rgba(139, 26, 43, 0.06);
}
.story-timeline h2 {
  font-size: 22px; margin-bottom: 4px;
}
.timeline-side { margin-top: 20px; }
.tl-item {
  position: relative;
  padding-left: 20px;
  padding-bottom: 18px;
  border-left: 2px solid var(--rose-light);
}
.tl-item:last-child { padding-bottom: 0; border-left-color: transparent; }
.tl-item::before {
  content: '';
  position: absolute; left: -6px; top: 4px;
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--rose-mid);
  border: 2px solid var(--cream);
  box-shadow: 0 0 0 2px var(--rose-light);
}
.tl-year {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 17px; color: var(--rose-deep);
  font-weight: 600; display: block; margin-bottom: 2px;
}
.tl-item p {
  font-size: 14px; line-height: 1.5;
  color: var(--text-muted); margin: 0;
}

@media (max-width: 900px) {
  .story-layout {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .story-timeline {
    position: static;
  }
}

/* ===== DECADE HEADERS ===== */
.decade-header {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 28px; color: var(--rose-deep);
  margin: 50px 0 20px; padding-bottom: 10px;
  border-bottom: 2px solid rgba(139, 26, 43, 0.1);
}
.decade-header:first-of-type { margin-top: 0; }
