/* ================================================================
   TEMA PINK 2 - SAKURA BLOSSOM THEME
   Custom CSS layered on top of Tailwind CSS utility classes.
   Animations, sakura effects, and section-specific overrides.
   ================================================================ */

/* ── Google Fonts ─────────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,600;1,400&family=Cinzel:wght@400;600&family=Noto+Serif+Arabic:wght@400;600&display=swap');

/* ── CSS Custom Properties (Sakura Color Palette) ─────────────── */
:root {
  --sakura-blush:    #fce4ec;
  --sakura-pink:     #f8bbd0;
  --sakura-rose:     #f48fb1;
  --sakura-deep:     #e91e8c;
  --sakura-dark:     #ad1457;
  --sakura-bark:     #795548;
  --sakura-leaf:     #81c784;
  --sakura-mist:     rgba(252, 228, 236, 0.85);
  --white-trans:     rgba(255, 255, 255, 0);
  --text-primary:    #5d2e46;
  --text-secondary:  #9e6375;
}

/* ── Base / Reset ─────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

body {
  font-family: 'Cormorant Garamond', serif;
  background: var(--sakura-blush);
  color: var(--text-primary);
  overflow-x: hidden;
}

/* ── Typography Helpers ───────────────────────────────────────── */
.font-arabic { font-family: 'Noto Serif Arabic', serif; }
.font-cinzel  { font-family: 'Cinzel', serif; }
.font-rancho  { font-family: 'Cormorant Garamond', serif; font-style: italic; }
.font-pt-sans { font-family: 'Cormorant Garamond', serif; }
.text-sakura-dark    { color: var(--text-primary); }
.text-sakura-primary { color: var(--sakura-rose); }

/* ── Sakura Tree Background Gradient ─────────────────────────── */
.sakura-bg {
  background: linear-gradient(
    160deg,
    #fff0f5 0%,
    #fce4ec 30%,
    #ffdde6 60%,
    #fff5f8 100%
  );
}

.sakura-bg-dark {
  background: linear-gradient(
    135deg,
    #f8bbd0 0%,
    #f48fb1 40%,
    #e91e8c20 100%
  );
}

/* ── Glassmorphism Cards ──────────────────────────────────────── */
.glass-card {
  background: rgba(255, 255, 255, 0.65);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(244, 143, 177, 0.3);
  border-radius: 1rem;
  box-shadow: 0 8px 32px rgba(244, 143, 177, 0.15);
}

/* ── Scroll Appear Animations ────────────────────────────────── */
.appear-left  { opacity: 0; transform: translateX(-60px); transition: all 0.8s cubic-bezier(.25,.46,.45,.94); }
.appear-right { opacity: 0; transform: translateX(60px);  transition: all 0.8s cubic-bezier(.25,.46,.45,.94); }
.appear-top   { opacity: 0; transform: translateY(-40px); transition: all 0.8s cubic-bezier(.25,.46,.45,.94); }
.appear-bottom{ opacity: 0; transform: translateY(40px);  transition: all 0.8s cubic-bezier(.25,.46,.45,.94); }
.zoom-in      { opacity: 0; transform: scale(0.85);       transition: all 0.7s cubic-bezier(.25,.46,.45,.94); }

.appear-left.inview,
.appear-right.inview,
.appear-top.inview,
.appear-bottom.inview { opacity: 1; transform: translate(0, 0); }
.zoom-in.inview       { opacity: 1; transform: scale(1); }

/* ── Zoom Animation (opening modal button) ────────────────────── */
.zoom-animation {
  animation: zoomPulse 2s ease-in-out infinite;
}
@keyframes zoomPulse {
  0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(244, 143, 177, 0.5); }
  50%       { transform: scale(1.06); box-shadow: 0 0 0 10px rgba(244, 143, 177, 0); }
}

/* ── Opening Modal ────────────────────────────────────────────── */
.modal {
  transition: opacity 0.5s ease;
  background: linear-gradient(145deg, #fff0f5, #fce4ec, #ffdde6);
}
.modal.opacity-0 { opacity: 0 !important; }
.modal:not(.opacity-0) { opacity: 1 !important; }

.modal-active { overflow: hidden; }

/* ── Wave Dividers ────────────────────────────────────────────── */
.wave img { display: block; width: 100%; }

/* ── Section Sakura Overlay ───────────────────────────────────── */
section { position: relative; }

/* ── Audio/Play Button ────────────────────────────────────────── */
#play-button {
  background: linear-gradient(135deg, var(--sakura-rose), var(--sakura-dark));
  border: 2px solid rgba(255,255,255,0.5);
  cursor: pointer;
}
#play-button:hover { opacity: 0.85; transform: scale(1.05); }

/* ── Bottom Nav ───────────────────────────────────────────────── */
#bottom-nav > div {
  background: linear-gradient(135deg, var(--sakura-rose), #c2185b);
  box-shadow: 0 4px 20px rgba(244, 143, 177, 0.4);
  border: 1px solid rgba(255,255,255,0.25);
}

/* ── Event Cards ──────────────────────────────────────────────── */
.event-card {
  background: rgba(255,255,255,0.7);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(244, 143, 177, 0.4);
  border-radius: 1.5rem;
  box-shadow: 0 6px 24px rgba(244, 143, 177, 0.2);
}

/* ── Countdown Timer ──────────────────────────────────────────── */
#timer .zoom-in {
  background: rgba(255,255,255,0.7);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(244, 143, 177, 0.3);
  border-radius: 0.75rem;
}

/* ── Shimmer Loading ──────────────────────────────────────────── */
#shimmer-comment .animate-pulse div { background: rgba(244, 143, 177, 0.3); }

/* ── Form Inputs ──────────────────────────────────────────────── */
input, select, textarea {
  border-color: rgba(244, 143, 177, 0.4) !important;
  transition: border-color 0.2s;
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--sakura-rose) !important;
  box-shadow: 0 0 0 3px rgba(244, 143, 177, 0.2);
}

/* ── Submit Button ────────────────────────────────────────────── */
button[type="submit"] {
  background: linear-gradient(135deg, var(--sakura-rose), var(--sakura-dark)) !important;
  transition: all 0.2s;
}
button[type="submit"]:hover { opacity: 0.85; transform: translateY(-1px); }

/* ── "Buka Undangan" Button ───────────────────────────────────── */
.modal-close {
  background: linear-gradient(135deg, var(--sakura-rose), var(--sakura-dark)) !important;
  padding: 0.75rem 2rem;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1rem;
  letter-spacing: 0.05em;
  border-radius: 9999px;
  border: 2px solid rgba(255,255,255,0.4);
}

/* ── Decorative Leaf Elements (CSS) ──────────────────────────── */
.leaf-decor, .sakura-petal-decor {
  position: absolute;
  width: 14px;
  height: 20px;
  background: radial-gradient(ellipse at center, #a8d5ba 30%, #81c784 100%);
  border-radius: 0 100% 0 100%;
  opacity: 0.7;
  animation: leafFloat 5s ease-in-out infinite;
  pointer-events: none;
}

@keyframes leafFloat {
  0%   { transform: translateY(0) rotate(0deg); opacity: 0.6; }
  50%  { transform: translateY(-18px) rotate(140deg); opacity: 0.95; }
  100% { transform: translateY(0) rotate(280deg); opacity: 0.6; }
}

/* ── Sakura Tree Silhouette Background ───────────────────────── */
.sakura-tree-bg {
  background-image:
    radial-gradient(ellipse at 10% 20%, rgba(255,183,197,0.3) 0%, transparent 50%),
    radial-gradient(ellipse at 85% 10%, rgba(255,183,197,0.25) 0%, transparent 40%),
    radial-gradient(ellipse at 50% 80%, rgba(248,187,208,0.2) 0%, transparent 60%);
  background-color: var(--sakura-blush);
}

/* ── Prayer Section ───────────────────────────────────────────── */
#pray {
  background: linear-gradient(135deg, #f48fb1, #ec407a, #c2185b);
  color: white;
}

/* ── Closed / Footer Section ──────────────────────────────────── */
#closed {
  background: linear-gradient(135deg, #fce4ec, #f8bbd0);
}

footer {
  background: linear-gradient(
    to bottom,
    var(--sakura-blush),
    var(--sakura-pink)
  );
}

/* ── Responsive adjustments ───────────────────────────────────── */
@media (max-width: 640px) {
  .modal-close { font-size: 0.9rem; padding: 0.6rem 1.5rem; }
}