/* ==========================================================================
   AAPKA DOST - LIVING PLANT & BOTANICAL METAPHOR STYLES
   Visualizing streak progression, growth stages, wilting, and recovery
   ========================================================================== */

.plant-svg {
  transition: transform var(--transition-smooth);
}

/* Plant Pot & Soil Base */
.plant-pot {
  fill: #854d0e;
  stroke: #583101;
  stroke-width: 2;
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.4));
}

.plant-pot-rim {
  fill: #a16207;
  stroke: #583101;
  stroke-width: 2;
}

.plant-soil {
  fill: #3f2e18;
}

/* Main Stems */
.plant-stem {
  fill: none;
  stroke: #22c55e;
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: stroke 0.6s ease, transform 0.6s ease;
  transform-origin: bottom center;
}

/* Leaves */
.plant-leaf {
  fill: #4ade80;
  stroke: #16a34a;
  stroke-width: 1.5;
  transform-origin: center center;
  transition: fill 0.8s ease, stroke 0.8s ease, transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.plant-leaf:hover {
  fill: #86efac;
  cursor: pointer;
}

/* Flowers & Blossoms (Higher streak stages) */
.plant-flower-petal {
  fill: #f472b6;
  stroke: #db2777;
  stroke-width: 1.5;
  transition: transform 0.5s ease;
}

.plant-flower-core {
  fill: #fde047;
  stroke: #ca8a04;
  stroke-width: 1;
}

/* ----------------- Living Sway Animation ----------------- */
.plant-canvas-wrapper:hover .plant-svg {
  animation: plant-sway 2.5s infinite ease-in-out;
}

.plant-living-sway {
  animation: gentle-breeze 6s infinite ease-in-out;
  transform-origin: 120px 200px;
}

@keyframes gentle-breeze {
  0%, 100% { transform: rotate(0deg); }
  25% { transform: rotate(1.5deg) skewX(0.5deg); }
  75% { transform: rotate(-1.5deg) skewX(-0.5deg); }
}

@keyframes plant-sway {
  0%, 100% { transform: rotate(0deg); }
  50% { transform: rotate(3deg); }
}

/* ----------------- Wilt / Thirst State (Missed Day) ----------------- */
.plant-canvas-wrapper.is-wilted .plant-stem {
  stroke: #92753a !important;
  transform: rotate(6deg) scaleY(0.92);
}

.plant-canvas-wrapper.is-wilted .plant-leaf {
  fill: #b39b56 !important;
  stroke: #7c642b !important;
  transform: rotate(20deg) translateY(4px);
}

.plant-canvas-wrapper.is-wilted .plant-flower-petal {
  fill: #cca2b0 !important;
  stroke: #875c69 !important;
  transform: scale(0.7) translateY(6px);
}

/* ----------------- Sprouting / Growth Bloom Animation ----------------- */
@keyframes sprout-pop {
  0% { transform: scale(0); opacity: 0; }
  70% { transform: scale(1.2); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}

.new-leaf-bloom {
  animation: sprout-pop 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

/* ----------------- Water Droplet Animation ----------------- */
.water-drop {
  position: absolute;
  width: 8px;
  height: 12px;
  background: #38bdf8;
  border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
  pointer-events: none;
  opacity: 0.9;
  box-shadow: 0 0 6px rgba(56, 189, 248, 0.6);
  animation: water-fall 0.7s ease-in forwards;
}

@keyframes water-fall {
  0% { transform: translateY(-30px) scale(0.6); opacity: 0; }
  40% { opacity: 1; }
  90% { transform: translateY(50px) scale(1); opacity: 0.9; }
  100% { transform: translateY(55px) scale(1.6); opacity: 0; }
}

/* Recovery Shimmer */
.plant-recovery-shimmer {
  animation: recovery-glow 1.2s ease-out;
}

@keyframes recovery-glow {
  0% { filter: drop-shadow(0 0 0px var(--brand-green)); }
  50% { filter: drop-shadow(0 0 20px rgba(52, 211, 153, 0.8)); transform: scale(1.08); }
  100% { filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.3)); transform: scale(1); }
}

/* Reduced Motion Overrides */
@media (prefers-reduced-motion: reduce) {
  .plant-living-sway,
  .plant-canvas-wrapper:hover .plant-svg,
  .new-leaf-bloom,
  .water-drop,
  .plant-recovery-shimmer {
    animation: none !important;
    transition: none !important;
  }
}
