:root {
  --bg: #fdf6ee;
  --bg-warm: #f8e9da;
  --ink: #3a2e2a;
  --ink-soft: #6b5751;
  --accent: #d98e8e;
  --accent-soft: #f1c4be;
  --gold: #c69b6d;
}

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

html, body {
  min-height: 100%;
  background:
    radial-gradient(1200px 700px at 20% -10%, var(--bg-warm), transparent 60%),
    radial-gradient(900px 600px at 100% 100%, #fbe4d6, transparent 55%),
    var(--bg);
  color: var(--ink);
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  font-weight: 300;
  overflow-x: hidden;
}

body { position: relative; }

.page {
  max-width: 720px;
  margin: 0 auto;
  padding: 14vh 28px 12vh;
  position: relative;
  z-index: 2;
}

/* ---------- typography ---------- */
.eyebrow {
  font-size: 0.78rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 1.2rem;
}

.title {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 500;
  font-size: clamp(3rem, 8vw, 5.5rem);
  line-height: 1.05;
  letter-spacing: -0.01em;
  margin-bottom: 1.6rem;
}

.name {
  font-style: italic;
  background: linear-gradient(120deg, var(--accent) 0%, var(--gold) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  position: relative;
}
.name::after {
  content: "";
  position: absolute;
  left: 6%;
  right: 6%;
  bottom: -2px;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent-soft), transparent);
  transform: scaleX(0);
  transform-origin: left;
  animation: underline 1.6s cubic-bezier(.2,.7,.2,1) 1.2s forwards;
}

.lede {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-size: clamp(1.15rem, 2.4vw, 1.45rem);
  color: var(--ink-soft);
  line-height: 1.55;
  max-width: 36ch;
}

.aside {
  margin-top: 0.9rem;
  font-size: 0.82rem;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  opacity: 0.75;
}

/* ---------- counter card ---------- */
.counter-card {
  margin-top: 9vh;
  padding: 2.4rem 2.2rem;
  background: rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border: 1px solid rgba(214, 169, 158, 0.25);
  border-radius: 18px;
  box-shadow: 0 20px 60px -30px rgba(120, 70, 60, 0.25);
}

.counter-label {
  font-size: 0.85rem;
  letter-spacing: 0.18em;
  text-transform: lowercase;
  color: var(--ink-soft);
}

.counter {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  margin: 0.5rem 0 0.9rem;
}

.counter-number {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 500;
  font-size: clamp(3.2rem, 9vw, 5rem);
  line-height: 1;
  background: linear-gradient(120deg, var(--accent), var(--gold));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-variant-numeric: tabular-nums;
}

.counter-unit {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-size: 1.4rem;
  color: var(--ink-soft);
}

.counter-sub {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  color: var(--ink-soft);
  font-size: 1.1rem;
}

.counter-foot {
  margin-top: 0.7rem;
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  opacity: 0.7;
}

/* ---------- rotator ---------- */
.rotator { margin-top: 9vh; }

.rotator-prefix {
  font-size: 0.78rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 0.8rem;
}

.rotator-stage {
  position: relative;
  min-height: 4.5rem;
}

.rotator-line {
  position: absolute;
  inset: 0;
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-size: clamp(1.3rem, 3vw, 1.7rem);
  color: var(--ink);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.9s ease, transform 0.9s ease;
  pointer-events: none;
}

.rotator-line.is-active {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- footer ---------- */
.sig {
  margin-top: 11vh;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  color: var(--ink-soft);
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-size: 1.1rem;
}

.ps {
  margin-top: 1.2rem;
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  opacity: 0.65;
  font-style: italic;
}

.heart {
  color: var(--accent);
  font-size: 1.5rem;
  cursor: pointer;
  transition: transform 0.25s ease;
  display: inline-block;
  user-select: none;
  animation: pulse 2.6s ease-in-out infinite;
}
.heart:hover { transform: scale(1.25) rotate(-6deg); }

/* ---------- petals ---------- */
.petals {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  overflow: hidden;
}

.petal {
  position: absolute;
  width: 14px;
  height: 14px;
  background: radial-gradient(circle at 30% 30%, var(--accent-soft), var(--accent) 80%);
  border-radius: 60% 0 60% 0;
  opacity: 0.55;
  filter: blur(0.3px);
  top: -20px;
  animation: drift 18s linear infinite;
}

.petal:nth-child(1) { left: 8%;  animation-duration: 22s; animation-delay: -3s;  width: 10px; height: 10px; opacity: 0.45; }
.petal:nth-child(2) { left: 20%; animation-duration: 26s; animation-delay: -8s;  width: 16px; height: 16px; }
.petal:nth-child(3) { left: 38%; animation-duration: 19s; animation-delay: -1s;  width: 12px; height: 12px; opacity: 0.5; }
.petal:nth-child(4) { left: 55%; animation-duration: 28s; animation-delay: -12s; width: 14px; height: 14px; }
.petal:nth-child(5) { left: 70%; animation-duration: 21s; animation-delay: -5s;  width: 10px; height: 10px; opacity: 0.4; }
.petal:nth-child(6) { left: 82%; animation-duration: 25s; animation-delay: -14s; width: 14px; height: 14px; }
.petal:nth-child(7) { left: 92%; animation-duration: 23s; animation-delay: -7s;  width: 11px; height: 11px; opacity: 0.45; }

/* click hearts */
.float-heart {
  position: fixed;
  pointer-events: none;
  color: var(--accent);
  font-size: 1.1rem;
  z-index: 5;
  animation: floatUp 1.6s cubic-bezier(.2,.7,.2,1) forwards;
}

/* ---------- reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 1s ease, transform 1s ease;
}
.reveal.is-in {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- keyframes ---------- */
@keyframes drift {
  0%   { transform: translate3d(0, -10vh, 0) rotate(0deg);   }
  50%  { transform: translate3d(40px, 50vh, 0) rotate(180deg); }
  100% { transform: translate3d(-20px, 110vh, 0) rotate(360deg); }
}

@keyframes underline {
  to { transform: scaleX(1); }
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.12); }
}

@keyframes floatUp {
  0%   { opacity: 0; transform: translate(-50%, 0) scale(0.6); }
  20%  { opacity: 1; }
  100% { opacity: 0; transform: translate(-50%, -90px) scale(1.1); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001s !important;
    transition-duration: 0.001s !important;
  }
}

@media (max-width: 540px) {
  .page { padding: 10vh 22px 8vh; }
  .counter-card { padding: 1.8rem 1.5rem; }
}
