:root {
  color-scheme: light;
  --blue: #65a9ff;
  --blue-deep: #2d70c9;
  --white: #fffdf5;
  --white-shade: #dce8f0;
  --yellow: #ffd95c;
  --yellow-deep: #e2a91d;
  --rose-red: #e51f3f;
  --rose-red-deep: #8f1028;
  --leaf: #2f8b57;
  --leaf-dark: #1d6442;
  --ink: #362332;
  --muted: #745866;
  --paper: rgba(255, 250, 246, 0.88);
  --shadow: rgba(62, 56, 87, 0.22);
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  font-family: Inter, system-ui, sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 15% 12%, rgba(255, 151, 156, 0.42), transparent 26rem),
    radial-gradient(circle at 82% 8%, rgba(244, 201, 93, 0.32), transparent 22rem),
    linear-gradient(180deg, #fff6f4 0%, #f9dfe5 54%, #cbe8d2 100%);
  overflow-x: hidden;
}

.password-screen {
  position: fixed;
  z-index: 30;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 22px;
  background:
    radial-gradient(circle at 20% 18%, rgba(255, 151, 156, 0.42), transparent 22rem),
    radial-gradient(circle at 82% 12%, rgba(244, 201, 93, 0.3), transparent 18rem),
    linear-gradient(180deg, #fff6f4 0%, #f9dfe5 62%, #dff1df 100%);
  transition: opacity 700ms ease, visibility 700ms ease;
}

.password-screen.hide {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

.password-card {
  width: min(520px, 100%);
  padding: clamp(24px, 6vw, 42px);
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 8px;
  background: rgba(255, 250, 246, 0.86);
  box-shadow: 0 24px 70px var(--shadow);
  text-align: center;
  backdrop-filter: blur(14px);
}

.password-kicker {
  margin: 0 0 10px;
  color: #a83d61;
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.password-card h2 {
  margin: 0 0 18px;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(2.1rem, 7vw, 4rem);
  line-height: 0.94;
}

.password-card label {
  display: block;
  margin-bottom: 12px;
  color: #705262;
  font-weight: 700;
}

.password-row {
  display: flex;
  gap: 10px;
}

.password-row input {
  min-width: 0;
  flex: 1;
  height: 48px;
  border: 1px solid rgba(168, 61, 97, 0.24);
  border-radius: 999px;
  padding: 0 18px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.78);
  font: 700 1rem Inter, sans-serif;
  outline: none;
}

.password-row input:focus {
  border-color: #a83d61;
  box-shadow: 0 0 0 4px rgba(168, 61, 97, 0.12);
}

.password-hint,
.password-error {
  margin: 12px 0 0;
  min-height: 20px;
  color: #8c6576;
  font-size: 0.92rem;
}

.password-error {
  color: #b41f45;
  font-weight: 800;
}

.opening-screen {
  position: fixed;
  z-index: 20;
  inset: 0;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 14px;
  padding: 28px;
  color: #3b2635;
  text-align: center;
  background:
    radial-gradient(circle at 28% 24%, rgba(255, 122, 168, 0.34), transparent 18rem),
    radial-gradient(circle at 70% 18%, rgba(255, 217, 92, 0.34), transparent 18rem),
    linear-gradient(180deg, #fff8f5 0%, #eef7ff 48%, #ddf1d9 100%);
  transition: opacity 900ms ease, visibility 900ms ease;
}

.opening-screen.hide {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

.opening-hearts {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.opening-hearts span {
  position: absolute;
  bottom: -40px;
  width: 20px;
  height: 20px;
  background: #ff7aa8;
  opacity: 0.34;
  transform: rotate(45deg);
  animation: floatHeart 5s ease-in-out infinite;
}

.opening-hearts span::before,
.opening-hearts span::after {
  content: "";
  position: absolute;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: inherit;
}

.opening-hearts span::before {
  left: -10px;
}

.opening-hearts span::after {
  top: -10px;
}

.opening-hearts span:nth-child(1) {
  left: 18%;
  animation-delay: -1s;
}

.opening-hearts span:nth-child(2) {
  left: 52%;
  width: 16px;
  height: 16px;
  animation-delay: -2.4s;
}

.opening-hearts span:nth-child(2)::before,
.opening-hearts span:nth-child(2)::after {
  width: 16px;
  height: 16px;
}

.opening-hearts span:nth-child(2)::before {
  left: -8px;
}

.opening-hearts span:nth-child(2)::after {
  top: -8px;
}

.opening-hearts span:nth-child(3) {
  left: 78%;
  animation-delay: -3.2s;
}

.photo-frame {
  position: relative;
  width: min(260px, 68vw);
  aspect-ratio: 1;
  padding: 10px;
  border-radius: 50%;
  background: linear-gradient(135deg, #ffffff, #ffe1ec, #dcecff);
  box-shadow: 0 22px 70px rgba(74, 55, 68, 0.22);
  animation: photoArrive 1200ms ease both;
}

.photo-frame img,
.photo-fallback {
  width: 100%;
  height: 100%;
  border-radius: 50%;
}

.photo-frame img {
  display: block;
  object-fit: cover;
}

.photo-frame img.missing {
  display: none;
}

.photo-fallback {
  display: none;
  place-items: center;
  padding: 28px;
  color: #7b5870;
  background:
    radial-gradient(circle at 35% 30%, rgba(255, 255, 255, 0.86), transparent 5rem),
    linear-gradient(135deg, #ffe4ec, #e5f1ff);
  font-weight: 800;
}

.photo-fallback.show {
  display: grid;
}

.opening-kicker {
  margin: 12px 0 0;
  color: #4078bd;
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.opening-screen h2 {
  max-width: 720px;
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(2.4rem, 8vw, 5.4rem);
  line-height: 0.94;
}

.opening-copy {
  max-width: 440px;
  margin: 0;
  color: #705262;
  font-size: 1.02rem;
  line-height: 1.55;
}

.enter-button {
  min-height: 48px;
  margin-top: 8px;
  padding: 0 24px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, #c93668, #2f6eb8);
  box-shadow: 0 16px 34px rgba(126, 49, 91, 0.24);
  font: 800 0.95rem Inter, sans-serif;
  cursor: pointer;
}

.garden-shell {
  width: min(1120px, 100%);
  min-height: 100vh;
  margin: 0 auto;
  padding: clamp(24px, 5vw, 56px) clamp(16px, 4vw, 40px) 40px;
}

.intro {
  max-width: 760px;
  margin: 0 auto 20px;
  text-align: center;
}

.kicker {
  display: grid;
  justify-items: center;
  gap: 6px;
  margin: 0 0 12px;
  color: #a83d61;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(2.6rem, 8vw, 6rem);
  line-height: 0.92;
  letter-spacing: 0;
}

.subtitle {
  max-width: 610px;
  margin: 18px auto 0;
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.15rem);
  line-height: 1.7;
}

.garden {
  position: relative;
  min-height: clamp(500px, 68vh, 720px);
  margin-top: 14px;
  border-radius: 28px;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.35), rgba(255, 255, 255, 0)),
    radial-gradient(circle at 50% 82%, rgba(52, 136, 83, 0.32), transparent 28rem);
}

.sky-glow {
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(circle at 25% 30%, rgba(255, 255, 255, 0.7) 0 0.18rem, transparent 0.2rem),
    radial-gradient(circle at 74% 26%, rgba(255, 255, 255, 0.62) 0 0.16rem, transparent 0.18rem),
    radial-gradient(circle at 60% 16%, rgba(255, 255, 255, 0.72) 0 0.12rem, transparent 0.14rem);
  animation: twinkle 4s ease-in-out infinite alternate;
}

.message-card {
  position: absolute;
  z-index: 5;
  top: clamp(18px, 5vw, 46px);
  left: 50%;
  width: min(560px, calc(100% - 32px));
  min-height: 136px;
  padding: clamp(20px, 4vw, 30px);
  border: 1px solid rgba(255, 255, 255, 0.78);
  border-radius: 8px;
  background: var(--paper);
  box-shadow: 0 24px 70px var(--shadow);
  text-align: center;
  transform: translateX(-50%);
  backdrop-filter: blur(12px);
}

.message-card.pop {
  animation: notePop 520ms ease both;
}

.message-count {
  display: inline-block;
  margin-bottom: 10px;
  color: #aa3c62;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.message-card p {
  margin: 0;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(1.55rem, 4vw, 2.5rem);
  line-height: 1.1;
}

.flower {
  position: absolute;
  z-index: 3;
  bottom: 28px;
  --scale: 1;
  width: 132px;
  height: 300px;
  border: 0;
  background: transparent;
  cursor: pointer;
  transform-origin: bottom center;
  animation: sway 4.7s ease-in-out infinite;
}

.flower:focus-visible {
  outline: 3px solid #4078bd;
  outline-offset: 8px;
  border-radius: 50%;
}

.flower:hover .bloom,
.flower.active .bloom {
  transform: translateX(-50%) scale(1.13) rotate(5deg);
}

.flower:hover .petal,
.flower.active .petal {
  filter: saturate(1.12) brightness(1.04);
}

.bloom {
  position: absolute;
  z-index: 3;
  left: 50%;
  top: 8px;
  width: 112px;
  height: 112px;
  transform: translateX(-50%);
  transform-origin: center;
  transition: transform 280ms ease;
}

.petal,
.center,
.stem,
.leaf {
  position: absolute;
  display: block;
}

.blue {
  --petal-main: var(--blue);
  --petal-deep: var(--blue-deep);
}

.white {
  --petal-main: var(--white);
  --petal-deep: var(--white-shade);
}

.yellow {
  --petal-main: var(--yellow);
  --petal-deep: var(--yellow-deep);
}

.red {
  --petal-main: var(--rose-red);
  --petal-deep: var(--rose-red-deep);
}

.daisy .petal {
  left: 39px;
  top: 5px;
  width: 34px;
  height: 58px;
  border-radius: 52% 52% 46% 46%;
  background: linear-gradient(180deg, var(--petal-main), var(--petal-deep));
  box-shadow: inset 7px 8px 12px rgba(255, 255, 255, 0.38);
  transform-origin: 50% 52px;
}

.daisy .petal-a { transform: rotate(0deg); }
.daisy .petal-b { transform: rotate(45deg); }
.daisy .petal-c { transform: rotate(90deg); }
.daisy .petal-d { transform: rotate(135deg); }
.daisy .petal-e { transform: rotate(180deg); }
.daisy .petal-f { transform: rotate(225deg); }
.daisy .petal-g { transform: rotate(270deg); }
.daisy .petal-h { transform: rotate(315deg); }

.daisy .center {
  left: 38px;
  top: 38px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff3a7, #f7c84c 48%, #b8772c);
  box-shadow: 0 4px 16px rgba(126, 71, 32, 0.24);
}

.tulip .bloom {
  top: 18px;
}

.tulip .petal {
  width: 54px;
  height: 84px;
  border-radius: 70% 70% 44% 44%;
  background: linear-gradient(155deg, var(--petal-main), var(--petal-deep));
  box-shadow: inset 9px 9px 18px rgba(255, 255, 255, 0.34);
  transform-origin: 50% 88%;
}

.tulip .petal-a {
  left: 29px;
  top: 0;
  z-index: 2;
}

.tulip .petal-b {
  left: 7px;
  top: 17px;
  transform: rotate(-26deg);
}

.tulip .petal-c {
  right: 7px;
  top: 17px;
  transform: rotate(26deg);
}

.tulip .center {
  left: 44px;
  top: 58px;
  width: 24px;
  height: 20px;
  border-radius: 50%;
  background: rgba(123, 84, 34, 0.34);
}

.lily .petal {
  left: 50%;
  top: 50%;
  width: 44px;
  height: 78px;
  border-radius: 70% 70% 46% 46%;
  background: linear-gradient(165deg, var(--petal-main), var(--petal-deep));
  box-shadow: inset 8px 8px 14px rgba(255, 255, 255, 0.55);
  transform-origin: 50% 100%;
}

.lily .petal-a {
  transform: translate(-50%, -100%) rotate(0deg);
}

.lily .petal-b {
  transform: translate(-50%, -100%) rotate(60deg);
}

.lily .petal-c {
  transform: translate(-50%, -100%) rotate(120deg);
}

.lily .petal-d {
  transform: translate(-50%, -100%) rotate(180deg);
}

.lily .petal-e {
  transform: translate(-50%, -100%) rotate(240deg);
}

.lily .petal-f {
  transform: translate(-50%, -100%) rotate(300deg);
}

.lily .center {
  left: 47px;
  top: 47px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #e8b244;
  box-shadow:
    -14px -13px 0 -6px #d58f36,
    14px -13px 0 -6px #d58f36,
    0 16px 0 -6px #d58f36;
}

.lily .stem {
  top: 108px;
}

.rose .bloom {
  top: 22px;
}

.rose .petal {
  width: 58px;
  height: 58px;
  border-radius: 62% 38% 62% 38%;
  background: linear-gradient(145deg, var(--petal-main), var(--petal-deep));
  box-shadow: inset 9px 9px 14px rgba(255, 255, 255, 0.28);
}

.rose .petal-a {
  left: 27px;
  top: 5px;
  transform: rotate(8deg);
}

.rose .petal-b {
  left: 44px;
  top: 28px;
  transform: rotate(82deg);
}

.rose .petal-c {
  left: 27px;
  top: 45px;
  transform: rotate(170deg);
}

.rose .petal-d {
  left: 9px;
  top: 28px;
  transform: rotate(260deg);
}

.rose .petal-e {
  left: 29px;
  top: 26px;
  width: 52px;
  height: 52px;
  border-radius: 50% 42% 50% 42%;
  transform: rotate(42deg);
  background: linear-gradient(135deg, color-mix(in srgb, var(--petal-main), white 10%), var(--petal-deep));
}

.rose .center {
  left: 46px;
  top: 44px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: radial-gradient(circle at 36% 30%, #ff9aaa, var(--petal-main) 48%, var(--petal-deep));
}

.stem {
  z-index: 1;
  left: calc(50% - 4px);
  top: 108px;
  width: 8px;
  height: 188px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--leaf-dark), var(--leaf));
}

.leaf {
  z-index: 2;
  width: 58px;
  height: 28px;
  border-radius: 100% 0 100% 0;
  background: linear-gradient(135deg, #5fc47b, var(--leaf-dark));
}

.leaf-left {
  left: 8px;
  top: 174px;
  transform: rotate(-26deg);
}

.leaf-right {
  right: 8px;
  top: 210px;
  transform: scaleX(-1) rotate(-24deg);
}

.flower-one {
  left: 3%;
  height: 265px;
  animation-delay: -1.8s;
}

.flower-two {
  left: 17%;
  height: 330px;
  animation-delay: -0.6s;
}

.flower-three {
  left: 36%;
  height: 290px;
  animation-delay: -2.5s;
}

.flower-four {
  left: 57%;
  height: 345px;
  animation-delay: -1.1s;
}

.flower-five {
  left: 80%;
  height: 280px;
  animation-delay: -3.2s;
}

.flower-six {
  left: 27%;
  bottom: 8px;
  height: 245px;
  --scale: 0.78;
  animation-delay: -2.9s;
}

.flower-seven {
  left: 68%;
  bottom: 4px;
  height: 252px;
  --scale: 0.74;
  animation-delay: -0.9s;
}

.flower-eight {
  left: 91%;
  bottom: 0;
  height: 238px;
  --scale: 0.66;
  animation-delay: -1.7s;
}

.ground {
  position: absolute;
  inset: auto -6% -52px;
  height: 190px;
  border-radius: 50% 50% 0 0;
  background:
    radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.28), transparent 10rem),
    linear-gradient(180deg, #5faf72, #237448);
}

.final-note {
  display: grid;
  justify-items: center;
  gap: 14px;
  padding: 28px 0 0;
  text-align: center;
}

.love-button {
  min-height: 48px;
  padding: 0 22px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, #2f6eb8, #e6b72f);
  box-shadow: 0 14px 28px rgba(47, 110, 184, 0.22);
  font: 800 0.95rem Inter, sans-serif;
  cursor: pointer;
}

.love-button:hover {
  transform: translateY(-1px);
}

.surprise {
  max-width: 620px;
  margin: 0;
  color: #62434f;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(1.4rem, 3vw, 2rem);
  line-height: 1.2;
}

@keyframes sway {
  0%,
  100% {
    transform: scale(var(--scale)) rotate(-2deg);
  }

  50% {
    transform: scale(var(--scale)) rotate(2.5deg);
  }
}

@keyframes twinkle {
  from {
    opacity: 0.36;
  }

  to {
    opacity: 0.9;
  }
}

@keyframes notePop {
  0% {
    transform: translateX(-50%) translateY(8px) scale(0.96);
    opacity: 0.72;
  }

  100% {
    transform: translateX(-50%) translateY(0) scale(1);
    opacity: 1;
  }
}

@keyframes photoArrive {
  0% {
    opacity: 0;
    transform: translateY(18px) scale(0.9);
  }

  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes floatHeart {
  0% {
    opacity: 0;
    transform: translateY(0) rotate(45deg) scale(0.7);
  }

  18% {
    opacity: 0.34;
  }

  100% {
    opacity: 0;
    transform: translateY(-110vh) rotate(45deg) scale(1.16);
  }
}

@media (max-width: 760px) {
  .garden-shell {
    padding-inline: 12px;
  }

  .garden {
    min-height: 620px;
    border-radius: 18px;
  }

  .message-card {
    top: 16px;
  }

  .password-row {
    display: grid;
  }

  .flower {
    width: 112px;
  }

  .flower-one {
    left: -1%;
    bottom: 16px;
  }

  .flower-two {
    left: 11%;
    bottom: 12px;
  }

  .flower-three {
    left: 34%;
    bottom: 18px;
  }

  .flower-four {
    left: 55%;
    bottom: 14px;
  }

  .flower-five {
    left: 76%;
    bottom: 16px;
  }

  .flower-six {
    left: 22%;
    bottom: -2px;
    --scale: 0.62;
  }

  .flower-seven {
    left: 67%;
    bottom: -6px;
    --scale: 0.6;
  }

  .flower-eight {
    left: 88%;
    bottom: -8px;
    --scale: 0.54;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    scroll-behavior: auto !important;
  }
}
