/* NoutMariaz custom styles */
.safe-area-bottom { padding-bottom: env(safe-area-inset-bottom, 0px); }

/* Heart animation */
@keyframes heart-pop {
    0% { transform: scale(1); }
    30% { transform: scale(1.3); }
    60% { transform: scale(0.9); }
    100% { transform: scale(1); }
}
.heart-pop { animation: heart-pop 0.4s ease-out; }

/* Double-tap heart overlay */
@keyframes heart-float {
    0% { opacity: 1; transform: scale(0) translate(-50%, -50%); }
    15% { opacity: 1; transform: scale(1.2) translate(-50%, -50%); }
    30% { opacity: 1; transform: scale(1) translate(-50%, -50%); }
    80% { opacity: 1; transform: scale(1) translate(-50%, -50%); }
    100% { opacity: 0; transform: scale(1.4) translate(-50%, -50%); }
}
.heart-float { animation: heart-float 0.8s ease-out forwards; }

/* Story ring gradient */
.story-ring {
    background: conic-gradient(from 0deg, #f472b6, #ec4899, #db2777, #f472b6);
    padding: 2.5px;
}
.story-ring-seen {
    background: #d1d5db;
    padding: 2.5px;
}

/* Upload progress */
.upload-progress-bar {
    transition: width 0.3s ease;
}

/* Carousel */
.carousel-container { scroll-snap-type: x mandatory; }
.carousel-slide { scroll-snap-align: start; }

/* Infinite scroll loading */
@keyframes pulse-dots {
    0%, 80%, 100% { opacity: 0.3; }
    40% { opacity: 1; }
}
.loading-dot { animation: pulse-dots 1.4s infinite both; }
.loading-dot:nth-child(2) { animation-delay: 0.2s; }
.loading-dot:nth-child(3) { animation-delay: 0.4s; }

/* Fade in for new posts */
@keyframes fade-in-up {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}
.fade-in-up { animation: fade-in-up 0.3s ease-out; }

/* ─── Audio Player ─── */

/* Waveform bars base */
.audio-bar { min-width: 3px; transform-origin: bottom; }

/* Active bars subtle pulse */
@keyframes bar-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: .75; }
}
.audio-bar-active { animation: bar-pulse 1.2s ease-in-out infinite; }
.audio-bar-active:nth-child(odd) { animation-delay: .15s; }
.audio-bar-active:nth-child(3n) { animation-delay: .3s; }

/* Loading ring pulse on play button */
@keyframes pulse-ring {
    0% { box-shadow: 0 0 0 0 rgba(236,72,153,.4); }
    70% { box-shadow: 0 0 0 10px rgba(236,72,153,0); }
    100% { box-shadow: 0 0 0 0 rgba(236,72,153,0); }
}
.audio-pulse-ring { animation: pulse-ring 1.5s ease-out infinite; }

/* Equalizer bars animation */
@keyframes eq-bar-1 { 0%,100% { height: 30%; } 50% { height: 100%; } }
@keyframes eq-bar-2 { 0%,100% { height: 60%; } 50% { height: 20%; } }
@keyframes eq-bar-3 { 0%,100% { height: 40%; } 50% { height: 90%; } }
@keyframes eq-bar-4 { 0%,100% { height: 80%; } 50% { height: 40%; } }

.audio-eq-bar:nth-child(1) { animation: eq-bar-1 .8s ease-in-out infinite; }
.audio-eq-bar:nth-child(2) { animation: eq-bar-2 .6s ease-in-out infinite; }
.audio-eq-bar:nth-child(3) { animation: eq-bar-3 .7s ease-in-out infinite; }
.audio-eq-bar:nth-child(4) { animation: eq-bar-4 .5s ease-in-out infinite; }
