.hero-room-vase {
  --flower-image: url('/assets/flower-apricot-fresh.webp?v=3');
  --vase-foot-y: 79.35%;
  --vase-key-angle: 108deg;
  --vase-dark: #747c80;
  --vase-mid: #c6c7c1;
  --vase-lit: #f4f2eb;
  --vase-core: rgba(24, 28, 34, .18);
  --vase-core-pos: 44% 76%;
  --vase-base-ao: rgba(18, 10, 4, .74);
  --vase-rim: rgba(236, 247, 255, .30);
  --vase-rim-pos: 84% 40%;
  --vase-spec: rgba(245, 251, 255, .28);
  --vase-spec-pos: 60% 68%;
  --vase-bounce: rgba(210, 178, 134, .18);
  --vase-bounce-pos: 26% 78%;
  --vase-filter: brightness(.91) contrast(1.05) saturate(.96);
  --vase-contact: rgba(14, 7, 2, .94);
  --vase-penumbra: rgba(26, 14, 5, .64);
  --vase-cast: rgba(22, 12, 4, .48);
  --vase-cast-left: -6%;
  --vase-cast-right: 12%;
  --vase-contact-x: 56%;
  --vase-cast-x: 34%;

  position: absolute;
  left: 90.2%;
  bottom: calc(100% - var(--vase-foot-y));
  width: 14.4%;
  aspect-ratio: 880 / 920;
  transform: translateX(-50%);
}

.hero-room-vase:hover,
.hero-room-vase:focus-within {
  transform: translateX(-50%) scale(1.03);
}

.hero-room-vase .decor-toolbar {
  bottom: calc(100% - 2px);
}

.hero-room-vase .decor-shadow {
  position: absolute;
  inset: auto var(--vase-cast-right) .2% var(--vase-cast-left);
  height: 8.2%;
  pointer-events: none;
  background:
    radial-gradient(ellipse 20% 34% at var(--vase-contact-x) 74%, var(--vase-contact) 0%, transparent 96%),
    radial-gradient(ellipse 34% 46% at var(--vase-contact-x) 68%, var(--vase-penumbra) 0%, transparent 96%),
    radial-gradient(ellipse 56% 48% at var(--vase-cast-x) 56%, var(--vase-cast) 0%, transparent 96%);
  transform: rotate(5.5deg);
  filter: blur(1px);
}

.hero-room-vase .decor-body {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 13% 24% at var(--vase-spec-pos), var(--vase-spec) 0%, transparent 72%),
    radial-gradient(ellipse 46% 52% at var(--vase-rim-pos), var(--vase-rim) 0%, transparent 66%),
    radial-gradient(ellipse 48% 44% at var(--vase-bounce-pos), var(--vase-bounce) 0%, transparent 72%),
    radial-gradient(ellipse 34% 40% at var(--vase-core-pos), var(--vase-core) 0%, transparent 78%),
    linear-gradient(0deg, var(--vase-base-ao) 0%, rgba(255, 255, 255, 0) 15%),
    linear-gradient(var(--vase-key-angle),
      color-mix(in srgb, var(--vase-dark) var(--vase-grade, 100%), transparent) 0%,
      color-mix(in srgb, var(--vase-mid) var(--vase-grade, 100%), transparent) 54%,
      color-mix(in srgb, var(--vase-lit) var(--vase-grade, 100%), transparent) 100%),
    var(--flower-image) center / 100% 100% no-repeat;
  background-blend-mode: screen, screen, soft-light, multiply, multiply, multiply, normal;
  -webkit-mask: var(--flower-image) center / 100% 100% no-repeat;
  mask: var(--flower-image) center / 100% 100% no-repeat;
  filter: var(--vase-filter) var(--flower-condition-light, brightness(1));
  transform-origin: 50% 94%;
  transition: filter .36s ease;
}

.hero-room-vase:is([data-bouquet="apricot"], [data-bouquet="ruby"], [data-bouquet="lilac"], [data-bouquet="rose"]) {
  --vase-grade: 38%;
}

.flower-turntable {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) 3ch;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  color: #3a4c3d;
  font-size: .85rem;
}

.flower-turntable input {
  width: 100%;
  min-width: 0;
  margin: 0;
  accent-color: #476449;
  cursor: ew-resize;
}

.flower-turntable output {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.hero-room-vase:hover .decor-body,
.hero-room-vase:focus-within .decor-body {
  filter: var(--vase-filter) var(--flower-condition-light, brightness(1)) brightness(1.06);
}

.hero-room-vase[data-condition="thirsty"],
.flower-card[data-condition="thirsty"] {
  --flower-condition-light: saturate(.73) brightness(.92);
}

/* ==========================================================================
   Animated Copper Watering Can & Pouring Water Droplets (.vase-water-fx)
   ========================================================================== */
.vase-water-fx {
  position: absolute;
  inset: -44% -34% 36% -12%;
  z-index: 8;
  pointer-events: none;
  opacity: 0;
}

.hero-room-vase[data-watering="true"] .vase-water-fx {
  opacity: 1;
}

.hero-room-vase[data-watering="true"] .decor-toolbar {
  opacity: 0;
  pointer-events: none;
}

.hero-room-vase[data-watering="true"] .decor-body {
  animation: vase-perk-up 2.4s ease-out both;
}

.water-can-svg {
  position: absolute;
  top: 0;
  right: 2%;
  width: 66%;
  height: auto;
  filter: drop-shadow(-3px 6px 8px rgba(14, 9, 4, .45));
  transform-origin: 62% 52%;
  opacity: 0;
}

.hero-room-vase[data-watering="true"] .water-can-svg {
  animation: water-can-pour 2.4s cubic-bezier(.25, .75, .25, 1) both;
}

.water-drops {
  position: absolute;
  left: 24%;
  top: 34%;
  width: 34%;
  height: 54%;
}

.water-drops i {
  position: absolute;
  width: clamp(3.5px, .38cqw, 7px);
  height: clamp(9px, 1.05cqw, 17px);
  border-radius: 50% 50% 50% 50% / 30% 30% 70% 70%;
  background: linear-gradient(180deg, rgba(226, 248, 255, .95), rgba(145, 215, 246, .75));
  box-shadow: 0 0 6px rgba(190, 238, 255, .75);
  opacity: 0;
}

.water-drops i:nth-child(1) { left: 66%; top: 2%; }
.water-drops i:nth-child(2) { left: 48%; top: 8%; }
.water-drops i:nth-child(3) { left: 78%; top: 10%; }
.water-drops i:nth-child(4) { left: 56%; top: 4%; }
.water-drops i:nth-child(5) { left: 36%; top: 12%; }
.water-drops i:nth-child(6) { left: 72%; top: 6%; }

.hero-room-vase[data-watering="true"] .water-drops i {
  animation: water-drop-fall .58s ease-in 3 both;
}
.hero-room-vase[data-watering="true"] .water-drops i:nth-child(1) { animation-delay: .36s; }
.hero-room-vase[data-watering="true"] .water-drops i:nth-child(2) { animation-delay: .46s; }
.hero-room-vase[data-watering="true"] .water-drops i:nth-child(3) { animation-delay: .54s; }
.hero-room-vase[data-watering="true"] .water-drops i:nth-child(4) { animation-delay: .64s; }
.hero-room-vase[data-watering="true"] .water-drops i:nth-child(5) { animation-delay: .72s; }
.hero-room-vase[data-watering="true"] .water-drops i:nth-child(6) { animation-delay: .80s; }

.water-sparkles {
  position: absolute;
  left: 14%;
  top: 56%;
  width: 56%;
  height: 40%;
}

.water-sparkles i {
  position: absolute;
  width: clamp(6px, .65cqw, 12px);
  height: clamp(6px, .65cqw, 12px);
  border-radius: 50%;
  background: radial-gradient(circle, #fffef2 0%, rgba(194, 242, 255, .82) 48%, transparent 76%);
  opacity: 0;
}

.water-sparkles i:nth-child(1) { left: 22%; top: 44%; }
.water-sparkles i:nth-child(2) { left: 54%; top: 24%; }
.water-sparkles i:nth-child(3) { left: 78%; top: 52%; }
.water-sparkles i:nth-child(4) { left: 42%; top: 66%; }

.hero-room-vase[data-watering="true"] .water-sparkles i {
  animation: water-sparkle 1.2s ease-out both;
}
.hero-room-vase[data-watering="true"] .water-sparkles i:nth-child(1) { animation-delay: .85s; }
.hero-room-vase[data-watering="true"] .water-sparkles i:nth-child(2) { animation-delay: 1.05s; }
.hero-room-vase[data-watering="true"] .water-sparkles i:nth-child(3) { animation-delay: 1.22s; }
.hero-room-vase[data-watering="true"] .water-sparkles i:nth-child(4) { animation-delay: 1.38s; }

@keyframes water-can-pour {
  0% { opacity: 0; transform: translate(26%, -18%) rotate(12deg) scale(.86); }
  16% { opacity: 1; transform: translate(0, 0) rotate(-6deg) scale(1); }
  26% { opacity: 1; transform: translate(-4%, 4%) rotate(-32deg) scale(1); }
  74% { opacity: 1; transform: translate(-6%, 6%) rotate(-35deg) scale(1); }
  88% { opacity: .92; transform: translate(6%, -4%) rotate(-6deg) scale(.96); }
  100% { opacity: 0; transform: translate(24%, -18%) rotate(10deg) scale(.86); }
}

@keyframes water-drop-fall {
  0% { opacity: 0; transform: translate(10px, -6px) rotate(18deg) scale(.7); }
  20% { opacity: .95; }
  82% { opacity: .88; }
  100% { opacity: 0; transform: translate(-18px, 64px) rotate(14deg) scale(1.05); }
}

@keyframes water-sparkle {
  0% { opacity: 0; transform: scale(.3) translateY(6px); }
  38% { opacity: 1; transform: scale(1.25) translateY(-4px); }
  100% { opacity: 0; transform: scale(.5) translateY(-14px); }
}

@keyframes vase-perk-up {
  0%, 48% { transform: scale(1); }
  68% { transform: scale(1.032, 1.045); }
  84% { transform: scale(.995, .992); }
  100% { transform: scale(1); }
}

/* Morning: Misty sunrise glow from upper-right window, cool soft backlit stoneware */
.hero-scene-inside:has(> img:last-of-type[src$="-morning.webp"]) .hero-room-vase {
  --vase-foot-y: 79.25%;
  --vase-key-angle: 112deg;
  --vase-dark: #6b7682;
  --vase-mid: #babdb9;
  --vase-lit: #ecdfd0;
  --vase-core: rgba(24, 30, 42, .22);
  --vase-core-pos: 44% 76%;
  --vase-base-ao: rgba(20, 13, 8, .76);
  --vase-rim: rgba(255, 226, 188, .36);
  --vase-rim-pos: 86% 36%;
  --vase-spec: rgba(255, 240, 218, .26);
  --vase-spec-pos: 60% 68%;
  --vase-bounce: rgba(232, 182, 132, .20);
  --vase-bounce-pos: 26% 76%;
  --vase-filter: brightness(.87) contrast(1.04) saturate(.94);
  --vase-contact: rgba(15, 9, 5, .92);
  --vase-penumbra: rgba(25, 15, 9, .58);
  --vase-cast: rgba(22, 14, 9, .44);
}

/* Noon: Crisp Erhai sky backlighting, authentic kiln-glazed stoneware shading */
.hero-scene-inside:has(> img:last-of-type[src$="-noon.webp"]) .hero-room-vase {
  --vase-foot-y: 79.4%;
  --vase-key-angle: 108deg;
  --vase-dark: #747f86;
  --vase-mid: #c6cac4;
  --vase-lit: #f7f5ee;
  --vase-core: rgba(22, 28, 35, .18);
  --vase-core-pos: 45% 76%;
  --vase-base-ao: rgba(20, 12, 5, .74);
  --vase-rim: rgba(234, 246, 255, .34);
  --vase-rim-pos: 85% 38%;
  --vase-spec: rgba(246, 252, 255, .30);
  --vase-spec-pos: 60% 68%;
  --vase-bounce: rgba(206, 176, 132, .16);
  --vase-bounce-pos: 28% 78%;
  --vase-filter: brightness(.91) contrast(1.05) saturate(.96);
  --vase-contact: rgba(14, 7, 2, .94);
  --vase-penumbra: rgba(26, 14, 5, .62);
  --vase-cast: rgba(22, 12, 4, .48);
}

/* Afternoon: Rich low golden sunset raking across stoneware glaze & garden roses */
.hero-scene-inside:has(> img:last-of-type[src$="-afternoon.webp"]) .hero-room-vase {
  --vase-foot-y: 79.35%;
  --vase-key-angle: 102deg;
  --vase-dark: #695446;
  --vase-mid: #c2aa90;
  --vase-lit: #fbd39a;
  --vase-core: rgba(34, 16, 6, .24);
  --vase-core-pos: 42% 76%;
  --vase-base-ao: rgba(26, 9, 2, .80);
  --vase-rim: rgba(255, 190, 108, .52);
  --vase-rim-pos: 88% 40%;
  --vase-spec: rgba(255, 218, 154, .42);
  --vase-spec-pos: 61% 69%;
  --vase-bounce: rgba(255, 162, 68, .36);
  --vase-bounce-pos: 26% 74%;
  --vase-filter: brightness(.90) contrast(1.08) saturate(1.04) sepia(.12);
  --vase-contact: rgba(26, 8, 2, .95);
  --vase-penumbra: rgba(42, 15, 4, .66);
  --vase-cast: rgba(46, 17, 5, .54);
  --vase-cast-left: -12%;
  --vase-cast-right: 12%;
  --vase-cast-x: 30%;
}

/* Night: Warm amber kettle firelight keying the LEFT side, cool midnight shadow on RIGHT */
.hero-scene-inside:has(> img:last-of-type[src$="-night.webp"]) .hero-room-vase {
  --vase-foot-y: 79.25%;
  --vase-key-angle: 256deg;
  --vase-dark: #384356;
  --vase-mid: #967c66;
  --vase-lit: #f9bc72;
  --vase-core: rgba(12, 16, 26, .30);
  --vase-core-pos: 62% 74%;
  --vase-base-ao: rgba(10, 5, 2, .84);
  --vase-rim: rgba(255, 180, 88, .66);
  --vase-rim-pos: 14% 58%;
  --vase-spec: rgba(255, 208, 128, .48);
  --vase-spec-pos: 37% 70%;
  --vase-bounce: rgba(122, 166, 224, .22);
  --vase-bounce-pos: 88% 28%;
  --vase-filter: brightness(.78) contrast(1.08) saturate(.98) sepia(.08);
  --vase-contact: rgba(8, 4, 1, .95);
  --vase-penumbra: rgba(16, 8, 3, .66);
  --vase-cast: rgba(14, 7, 3, .52);
  --vase-cast-left: 14%;
  --vase-cast-right: -10%;
  --vase-contact-x: 42%;
  --vase-cast-x: 68%;
}

@media (min-width: 761px) {
  .hero { min-height: max(580px, calc(100svh - 83px), 43vw); }
}

@media (max-width: 380px) {
  .hero-room-vase { left: 89.2%; width: 12.6%; }
}

/* Owner Dashboard: Rare Flower Care & Redemption Shop */
.flower-care > p { margin: 0 0 16px; color: var(--muted); }
.flower-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(250px, 100%), 1fr)); gap: 16px; }
.flower-card { display: flex; flex-direction: column; min-width: 0; background: #fcfaf5; border: 1px solid var(--border); border-radius: 10px; overflow: hidden; transition: border-color .25s ease, box-shadow .25s ease; }
.flower-card[data-active="true"] { border-color: #849f77; box-shadow: 0 8px 24px rgba(32, 62, 40, .10); }
.flower-card[data-rarity="legendary"] { border-color: #d6ba80; }
.flower-card-photo { position: relative; height: 196px; display: grid; place-items: center; background: radial-gradient(ellipse at 50% 45%, #fffef9, #eae4d6); }
.flower-card-photo img { display: block; width: 82%; height: 174px; object-fit: contain; filter: var(--flower-condition-light, none); transition: transform .35s ease; }
.flower-card[data-unlocked="false"] .flower-card-photo img { filter: saturate(.76) brightness(.90); }
.flower-card:hover .flower-card-photo img { transform: scale(1.03); }
.flower-card-copy { display: flex; flex-direction: column; flex: 1; gap: 5px; padding: 16px; }
.flower-card-copy p { margin: 0; color: var(--muted); font-size: .88rem; }
.flower-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: auto; padding-top: 12px; }
.flower-actions .button { min-height: 38px; padding: 6px 13px; font-size: .86rem; }

@media (prefers-reduced-motion: reduce) {
  .hero-room-vase[data-watering="true"] .decor-body,
  .hero-room-vase[data-watering="true"] .water-can-svg,
  .hero-room-vase[data-watering="true"] .water-drops i,
  .hero-room-vase[data-watering="true"] .water-sparkles i {
    animation: none;
  }
}
