:root {
  color-scheme: light;
  --ink: #352a32;
  --rose: #a44363;
}
* { box-sizing: border-box; }
html { min-height: 100%; }
body {
  margin: 0;
  background: #fff;
  color: var(--ink);
  font-family: "Inter", system-ui, sans-serif;
  letter-spacing: 0;
}
.love-page { width: 100%; }
.opening {
  position: relative;
  display: grid;
  place-items: center;
  height: min(64svh, 580px);
  min-height: 280px;
  overflow: hidden;
  isolation: isolate;
  color: #fff;
  text-align: center;
}
.floral-background {
  position: absolute;
  inset: -30px;
  z-index: -2;
  background: linear-gradient(rgba(51, 17, 34, .25), rgba(51, 17, 34, .4)),
    url("./assets/romantic-flowers.png") center 48% / cover no-repeat;
  animation: floral-drift 14s ease-in-out infinite alternate;
}
.opening-content {
  width: 100%;
  padding: 28px;
  text-shadow: 0 2px 18px rgba(35, 9, 24, .4);
  animation: arrive 1.2s cubic-bezier(.2, .7, .2, 1) both;
}
.eyebrow {
  margin: 0 0 18px;
  font-size: .75rem;
  font-weight: 500;
  letter-spacing: 0;
  text-transform: uppercase;
}
h1 {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 6rem;
  font-weight: 500;
  line-height: 1.1;
  overflow-wrap: anywhere;
}
.opening-rule {
  display: block;
  width: 60px;
  height: 1px;
  margin: 28px auto 0;
  background: rgba(255, 255, 255, .8);
  animation: rule-arrive 1.2s .4s both;
}
.letter {
  position: relative;
  background: #fff;
  padding: 56px 28px 72px;
}
.letter-inner { width: min(620px, 100%); margin: auto; }
.message {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.5rem;
  font-weight: 500;
  line-height: 1.7;
  overflow-wrap: anywhere;
}
.message p { margin: 0 0 32px; }
.message p:first-child {
  color: var(--rose);
  font-size: 1.875rem;
  line-height: 1.45;
  padding-bottom: 32px;
  border-bottom: 1px solid #eedee4;
}
.message p:last-child {
  margin-bottom: 0;
  color: var(--rose);
  font-style: italic;
}
.signature {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 40px;
  color: #855f70;
  font-size: .8rem;
  line-height: 1.5;
}
.line { flex: 0 0 40px; height: 1px; background: #bc8193; }
.clue {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid #eedee4;
  text-align: center;
}
.clue-link {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  max-width: 100%;
  min-height: 48px;
  padding: 14px 24px;
  border: 1px solid var(--rose);
  border-radius: 4px;
  background: var(--rose);
  color: #fff;
  font-size: .875rem;
  font-weight: 500;
  line-height: 1.5;
  text-decoration: none;
  transition: background .2s ease, transform .2s ease, box-shadow .2s ease;
}
.clue-link:hover {
  background: #87324f;
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(164, 67, 99, .18);
}
.clue-link:focus-visible {
  outline: 3px solid #87324f;
  outline-offset: 4px;
}
.instagram-link {
  background: transparent;
  color: var(--rose);
}
.instagram-link:hover {
  background: #f9eef2;
}
.reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 5;
  width: 100%;
  height: 3px;
  background: #c56687;
  transform: scaleX(0);
  transform-origin: left;
  pointer-events: none;
}
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .85s ease, transform .85s cubic-bezier(.2, .7, .2, 1);
}
.reveal.is-visible { opacity: 1; transform: none; }
.petals {
  position: absolute;
  inset: 0 0 auto;
  height: min(64svh, 580px);
  min-height: 280px;
  z-index: 2;
  overflow: hidden;
  pointer-events: none;
}
.petals i {
  position: absolute;
  top: -40px;
  left: var(--left);
  width: 16px;
  height: 24px;
  border-radius: 80% 0 80% 20%;
  background: #f2c1d1;
  opacity: 0;
  animation: petal-fall var(--duration) var(--delay) linear infinite;
}
.petals i:nth-child(1) { --left: 5%; --duration: 10s; --delay: -7s; }
.petals i:nth-child(2) { --left: 18%; --duration: 13s; --delay: -10s; }
.petals i:nth-child(3) { --left: 30%; --duration: 11s; --delay: -3s; }
.petals i:nth-child(4) { --left: 42%; --duration: 15s; --delay: -12s; }
.petals i:nth-child(5) { --left: 64%; --duration: 12s; --delay: -9s; }
.petals i:nth-child(6) { --left: 77%; --duration: 10s; --delay: -5s; }
.petals i:nth-child(7) { --left: 88%; --duration: 14s; --delay: -11s; }
.petals i:nth-child(8) { --left: 96%; --duration: 11s; --delay: -4s; }
@keyframes arrive {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: none; }
}
@keyframes rule-arrive {
  from { transform: scaleX(0); }
  to { transform: scaleX(1); }
}
@keyframes floral-drift {
  from { transform: translate3d(-8px, -4px, 0) scale(1); }
  to { transform: translate3d(8px, 4px, 0) scale(1.07); }
}
@keyframes petal-fall {
  0% { opacity: 0; transform: translate3d(0, 0, 0) rotate(0); }
  10%, 85% { opacity: .8; }
  50% { transform: translate3d(-45px, 34svh, 0) rotate(140deg); }
  100% { opacity: 0; transform: translate3d(45px, 75svh, 0) rotate(280deg); }
}
@media (max-width: 620px) {
  .opening, .petals { height: 54svh; min-height: 240px; }
  h1 { font-size: 4rem; }
  .eyebrow { font-size: .6875rem; }
  .letter { padding: 36px 28px 48px; }
  .message { font-size: 1.25rem; }
  .message p:first-child { font-size: 1.5rem; padding-bottom: 24px; }
  .signature { gap: 12px; font-size: .75rem; }
  .line { flex-basis: 28px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
  .petals { display: none; }
}
