@font-face {
  font-family: "Fraunces";
  src: url("fonts/fraunces.woff2") format("woff2");
  font-weight: 600 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Nunito Sans";
  src: url("fonts/nunito-sans.woff2") format("woff2");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

/* Milestones — styles.
   Warm keepsake feel: paper-cream background, deep ink text, terracotta
   accent, serif display headings. Mobile-first; photos big; thumbs first.
   No gradients-on-everything, no emoji — a quiet, printed-album look. */

:root {
  --paper: #faf6ef;
  --paper-deep: #f3ecdf;
  --card: #fffdf9;
  --ink: #2e2620;
  --ink-soft: #6b5d4f;
  --line: #e3d7c3;
  --accent: #c96f4a;
  --accent-deep: #a95636;
  --accent-soft: #f7e3d7;
  --sage: #7d8c6f;
  --gold: #c9a227;
  --danger: #b3402e;
  --radius: 14px;
  --radius-lg: 20px;
  --shadow: 0 2px 10px rgba(46, 38, 32, 0.07), 0 10px 30px rgba(46, 38, 32, 0.05);
  --font-body: "Nunito Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-display: "Fraunces", Georgia, "Iowan Old Style", "Times New Roman", serif;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
}

img { max-width: 100%; display: block; }

a { color: var(--accent-deep); }

/* ---------- Header / nav ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  background: rgba(250, 246, 239, 0.95);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  text-decoration: none;
  color: var(--ink);
}

.brand-mark { width: 30px; height: 30px; }

.brand-name {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0.2px;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.main-nav a, .main-nav button.nav-link {
  color: var(--ink);
  text-decoration: none;
  font-size: 15px;
  padding: 7px 10px;
  border-radius: 999px;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
}

.main-nav a:hover, .main-nav button.nav-link:hover { background: var(--paper-deep); }
.main-nav a.nav-cta { background: var(--accent); color: #fff; font-weight: 600; }
.main-nav a.nav-cta:hover { background: var(--accent-deep); }

.bell-wrap { position: relative; display: inline-flex; }
.bell-badge {
  position: absolute;
  top: 1px;
  right: 2px;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--accent);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
}

/* ---------- Layout ---------- */

.app-main {
  max-width: 880px;
  margin: 0 auto;
  padding: 20px 16px 56px;
  min-height: 62vh;
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 26px 16px 40px;
  text-align: center;
  color: var(--ink-soft);
  font-size: 14px;
}
.footer-small { font-size: 13px; margin-top: 2px; }

.loading-screen { padding: 80px 0; text-align: center; }
.loading-text { font-family: var(--font-display); font-size: 20px; color: var(--ink-soft); }

.page-head { margin: 8px 0 18px; }
.page-title {
  font-family: var(--font-display);
  font-size: 32px;
  line-height: 1.15;
  margin: 0 0 6px;
}
.page-sub { color: var(--ink-soft); margin: 0; max-width: 56ch; }
.section-title {
  font-family: var(--font-display);
  font-size: 22px;
  margin: 30px 0 12px;
}

/* ---------- Buttons & forms ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 11px 20px;
  font-size: 16px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  text-decoration: none;
  background: var(--paper-deep);
  color: var(--ink);
  min-height: 48px;
}
.btn:hover { filter: brightness(0.98); }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-deep); }
.btn-ghost { background: transparent; border-color: var(--line); }
.btn-quiet { background: transparent; color: var(--ink-soft); font-weight: 500; }
.btn-danger { background: transparent; border-color: var(--danger); color: var(--danger); }
.btn-block { width: 100%; }
.btn-small { min-height: 40px; padding: 8px 14px; font-size: 14px; }

.field { margin-bottom: 16px; }
.field label {
  display: block;
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 6px;
}
.field .hint { font-weight: 400; color: var(--ink-soft); font-size: 13px; margin-top: 4px; }
.field input[type="text"],
.field input[type="email"],
.field input[type="password"],
.field input[type="date"],
.field input[type="tel"],
.field select,
.field textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--card);
  font-size: 16px;
  font-family: inherit;
  color: var(--ink);
}
.field textarea { min-height: 92px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: 2px solid var(--accent-soft);
  border-color: var(--accent);
}

.form-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 22px;
  max-width: 520px;
  margin: 0 auto;
}
.form-card.wide { max-width: 640px; }

.form-error {
  background: #fbeae6;
  border: 1px solid #eec5ba;
  color: var(--danger);
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 14px;
  margin-bottom: 14px;
}
.form-note { font-size: 14px; color: var(--ink-soft); text-align: center; margin-top: 14px; }

.link-button {
  background: none; border: none; padding: 0;
  color: var(--accent-deep); font: inherit; cursor: pointer;
  text-decoration: underline;
}

/* ---------- Landing ---------- */

.hero { text-align: center; padding: 34px 0 8px; }
.hero-mark { width: 64px; height: 64px; margin: 0 auto 10px; }
.hero h1 {
  font-family: var(--font-display);
  font-size: 42px;
  line-height: 1.12;
  margin: 0 auto 14px;
  max-width: 16ch;
}
.hero p {
  color: var(--ink-soft);
  font-size: 18px;
  max-width: 52ch;
  margin: 0 auto 22px;
}
.hero-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.hero-small { font-size: 13px; color: var(--ink-soft); margin-top: 12px; }

.steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin: 30px 0 6px;
}
@media (min-width: 640px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 18px;
  box-shadow: var(--shadow);
}
.step-card h3 { font-family: var(--font-display); margin: 0 0 6px; font-size: 19px; }
.step-card p { margin: 0; color: var(--ink-soft); font-size: 15px; }
.step-num {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--accent);
  font-size: 14px;
  letter-spacing: 1px;
  margin-bottom: 6px;
}

.subject-strip {
  display: flex; flex-wrap: wrap; gap: 8px; justify-content: center;
  margin: 22px 0 4px;
}
.subject-chip {
  border: 1px solid var(--line);
  background: var(--card);
  border-radius: 999px;
  padding: 7px 14px;
  font-size: 14px;
  color: var(--ink-soft);
}

/* Pricing (the one place prices appear) */
.pricing-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  margin: 14px 0;
}
@media (min-width: 720px) { .pricing-grid { grid-template-columns: repeat(3, 1fr); } }
.price-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 22px;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
}
.price-card.featured { border-color: var(--accent); border-width: 2px; }
.price-name { font-family: var(--font-display); font-size: 19px; margin: 0 0 4px; }
.price-amount { font-family: var(--font-display); font-size: 34px; margin: 2px 0; }
.price-amount span { font-size: 15px; color: var(--ink-soft); font-family: var(--font-body); }
.price-tag { color: var(--ink-soft); font-size: 14px; margin: 0 0 12px; }
.price-list { margin: 0 0 18px; padding-left: 18px; color: var(--ink-soft); font-size: 15px; }
.price-list li { margin-bottom: 6px; }
.price-card .btn { margin-top: auto; }
.price-badge {
  align-self: flex-start;
  background: var(--accent-soft);
  color: var(--accent-deep);
  font-size: 12px; font-weight: 700;
  border-radius: 999px;
  padding: 3px 10px;
  margin-bottom: 10px;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}

/* ---------- Journey cards ---------- */

.journey-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
@media (min-width: 620px) { .journey-grid { grid-template-columns: 1fr 1fr; } }

.journey-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  text-decoration: none;
  color: var(--ink);
  display: block;
}
.journey-card:hover { border-color: var(--accent); }
.journey-cover {
  aspect-ratio: 16 / 9;
  width: 100%;
  object-fit: cover;
  background: var(--paper-deep);
}
.journey-cover-empty {
  aspect-ratio: 16 / 9;
  display: flex; align-items: center; justify-content: center;
  background: var(--paper-deep);
  font-family: var(--font-display);
  font-size: 22px; color: var(--ink-soft);
  padding: 16px; text-align: center;
}
.journey-card-body { padding: 14px 16px 16px; }
.journey-card-name { font-family: var(--font-display); font-size: 21px; margin: 0; }
.journey-card-meta { color: var(--ink-soft); font-size: 14px; margin: 3px 0 0; }

.empty-card {
  border: 1.5px dashed var(--line);
  border-radius: var(--radius-lg);
  padding: 30px 22px;
  text-align: center;
  color: var(--ink-soft);
  background: transparent;
}
.empty-card h3 { font-family: var(--font-display); color: var(--ink); margin: 0 0 8px; font-size: 21px; }
.empty-card p { margin: 0 auto 16px; max-width: 44ch; }

/* ---------- Timeline ---------- */

.journey-hero { margin-bottom: 6px; }
.journey-hero-cover {
  width: 100%;
  aspect-ratio: 16 / 8;
  object-fit: cover;
  border-radius: var(--radius-lg);
  background: var(--paper-deep);
}
.journey-hero-name {
  font-family: var(--font-display);
  font-size: 36px;
  margin: 14px 0 2px;
  line-height: 1.1;
}
.journey-hero-meta { color: var(--ink-soft); margin: 0 0 12px; }
.journey-actions { display: flex; gap: 8px; flex-wrap: wrap; margin: 12px 0 4px; }

.plan-note {
  display: inline-block;
  background: var(--accent-soft);
  color: var(--accent-deep);
  border-radius: 999px;
  padding: 4px 12px;
  font-size: 13px;
  font-weight: 600;
}

.timeline { margin-top: 18px; display: flex; flex-direction: column; gap: 26px; }
.milestone-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.milestone-media { width: 100%; background: #171310; }
.milestone-media img, .milestone-media video {
  width: 100%;
  max-height: 560px;
  object-fit: contain;
  background: #171310;
}
.milestone-body { padding: 16px 18px 14px; }
.milestone-age {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 4px;
}
.milestone-title { font-family: var(--font-display); font-size: 24px; margin: 0 0 4px; line-height: 1.2; }
.milestone-date { color: var(--ink-soft); font-size: 14px; margin: 0 0 8px; }
.milestone-note { margin: 0 0 10px; white-space: pre-wrap; }
.milestone-foot {
  display: flex; align-items: center; gap: 14px;
  border-top: 1px solid var(--line);
  padding-top: 10px;
}
.heart-btn {
  display: inline-flex; align-items: center; gap: 6px;
  background: none; border: none; cursor: pointer;
  font: inherit; font-size: 15px; color: var(--ink-soft);
  padding: 4px 6px; border-radius: 8px;
}
.heart-btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; }
.heart-btn.loved { color: var(--accent-deep); }
.heart-btn.loved svg { fill: var(--accent); stroke: var(--accent); }
.milestone-delete { margin-left: auto; }

.coming-list { margin: 0; padding-left: 20px; color: var(--ink-soft); }
.coming-list li { margin-bottom: 4px; }

/* ---------- Post form ---------- */

.chip-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 6px; }
.chip {
  border: 1px solid var(--line);
  background: var(--card);
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 15px;
  font-family: inherit;
  cursor: pointer;
  color: var(--ink);
  min-height: 40px;
}
.chip:hover { border-color: var(--accent); }
.chip.selected { background: var(--accent); border-color: var(--accent); color: #fff; }

.media-picker {
  border: 1.5px dashed var(--line);
  border-radius: var(--radius);
  padding: 18px;
  text-align: center;
  background: var(--card);
}
.media-picker p { margin: 0 0 10px; color: var(--ink-soft); }
.media-preview { border-radius: var(--radius); margin: 0 auto 10px; max-height: 300px; }
.media-actions { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }

.posts-left {
  background: var(--accent-soft);
  color: var(--accent-deep);
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 16px;
  text-align: center;
}

/* ---------- Invite / followers ---------- */

.follower-row {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.follower-row:last-child { border-bottom: none; }
.follower-who { flex: 1; min-width: 0; }
.follower-who strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.follower-status { font-size: 13px; color: var(--ink-soft); }
.share-link-box {
  display: flex; gap: 8px; margin-top: 8px;
}
.share-link-box input {
  flex: 1;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--paper);
  font-size: 14px;
  min-width: 0;
}

/* ---------- Notifications ---------- */

.notif-row {
  display: flex; gap: 12px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px 16px;
  margin-bottom: 10px;
  text-decoration: none;
  color: var(--ink);
}
.notif-row.unread { border-color: var(--accent); background: #fff8f2; }
.notif-row p { margin: 0; }
.notif-when { font-size: 13px; color: var(--ink-soft); }
.notif-dot {
  flex: none; width: 9px; height: 9px; border-radius: 999px;
  background: var(--accent); margin-top: 8px;
}
.notif-dot.read { background: var(--line); }

/* ---------- Settings ---------- */

.settings-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 20px 22px;
  margin-bottom: 16px;
}
.settings-card h3 { font-family: var(--font-display); margin: 0 0 8px; font-size: 20px; }
.settings-card p { color: var(--ink-soft); margin: 0 0 12px; font-size: 15px; }
.plan-pill {
  display: inline-block;
  border-radius: 999px;
  padding: 4px 12px;
  font-size: 13px;
  font-weight: 700;
  background: var(--paper-deep);
  color: var(--ink-soft);
}
.plan-pill.paid { background: var(--accent-soft); color: var(--accent-deep); }

/* ---------- Modal / toast ---------- */

.modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(46, 38, 32, 0.5);
  display: flex; align-items: center; justify-content: center;
  padding: 18px;
  z-index: 80;
}
.modal-card {
  background: var(--card);
  border-radius: var(--radius-lg);
  max-width: 440px;
  width: 100%;
  padding: 26px;
  box-shadow: var(--shadow);
  text-align: center;
}
.modal-card h2 { font-family: var(--font-display); margin: 0 0 10px; font-size: 26px; }
.modal-card p { color: var(--ink-soft); margin: 0 0 18px; }
.modal-actions { display: flex; flex-direction: column; gap: 8px; }

.toast-root {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 22px;
  z-index: 90;
  display: flex; flex-direction: column; gap: 8px;
  width: min(92vw, 420px);
}
.toast {
  background: var(--ink);
  color: var(--paper);
  border-radius: 12px;
  padding: 12px 16px;
  font-size: 15px;
  box-shadow: var(--shadow);
  text-align: center;
}

/* Setup / not-configured state */
.setup-card {
  background: #fff8ec;
  border: 1px solid #ecd9ae;
  border-radius: var(--radius-lg);
  padding: 22px;
  margin: 20px auto;
  max-width: 560px;
  text-align: center;
}
.setup-card h2 { font-family: var(--font-display); margin: 0 0 8px; }
.setup-card p { color: var(--ink-soft); margin: 0; font-size: 15px; }

@media (min-width: 720px) {
  .hero h1 { font-size: 54px; }
  .app-main { padding: 28px 20px 64px; }
}
