/* ========================================
   PETOTELBUL - ANIMATIONS & TRANSITIONS
   ======================================== */

/* ===== BASE TRANSITIONS ===== */
* {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== HOVER EFFECTS ===== */
.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.hover-scale {
    transition: transform 0.3s ease;
}

.hover-scale:hover {
    transform: scale(1.05);
}

.hover-glow {
    transition: box-shadow 0.3s ease;
}

.hover-glow:hover {
    box-shadow: 0 0 30px rgba(255, 107, 53, 0.4);
}

.hover-rotate {
    transition: transform 0.3s ease;
}

.hover-rotate:hover {
    transform: rotate(5deg);
}

/* ===== BUTTON ANIMATIONS ===== */
.btn-animated {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.btn-animated::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.btn-animated:hover::before {
    left: 100%;
}

.btn-bounce {
    transition: transform 0.2s ease;
}

.btn-bounce:active {
    transform: scale(0.95);
}

.btn-pulse {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* ===== CARD ANIMATIONS ===== */
.card-fade-in {
    animation: fadeInUp 0.6s ease forwards;
    opacity: 0;
    transform: translateY(30px);
}

.card-fade-in:nth-child(1) { animation-delay: 0.1s; }
.card-fade-in:nth-child(2) { animation-delay: 0.2s; }
.card-fade-in:nth-child(3) { animation-delay: 0.3s; }
.card-fade-in:nth-child(4) { animation-delay: 0.4s; }
.card-fade-in:nth-child(5) { animation-delay: 0.5s; }
.card-fade-in:nth-child(6) { animation-delay: 0.6s; }

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.card-slide-in {
    animation: slideInRight 0.6s ease forwards;
    opacity: 0;
    transform: translateX(50px);
}

@keyframes slideInRight {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.card-zoom-in {
    animation: zoomIn 0.5s ease forwards;
    opacity: 0;
    transform: scale(0.8);
}

@keyframes zoomIn {
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ===== FORM ANIMATIONS ===== */
.form-field-focus {
    transition: all 0.3s ease;
}

.form-field-focus:focus {
    transform: scale(1.02);
    box-shadow: 0 0 20px rgba(255, 107, 53, 0.3);
}

.input-shake {
    animation: shake 0.5s ease-in-out;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

.input-success {
    animation: successPulse 0.6s ease;
}

@keyframes successPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); box-shadow: 0 0 20px rgba(16, 185, 129, 0.5); }
    100% { transform: scale(1); }
}

/* ===== NAVIGATION ANIMATIONS ===== */
.nav-link-slide {
    position: relative;
    overflow: hidden;
}

.nav-link-slide::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #ff6b35, #f7931e);
    transition: width 0.3s ease;
}

.nav-link-slide:hover::after {
    width: 100%;
}

.mobile-menu-slide {
    animation: slideDown 0.3s ease forwards;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== MODAL ANIMATIONS ===== */
.modal-backdrop {
    animation: fadeIn 0.3s ease forwards;
}

.modal-content {
    animation: modalSlideIn 0.3s ease forwards;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* ===== LOADING ANIMATIONS ===== */
.skeleton-shimmer {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200px 100%;
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0% { background-position: -200px 0; }
    100% { background-position: calc(200px + 100%) 0; }
}

.loading-dots {
    display: inline-flex;
    gap: 4px;
}

.loading-dots span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: currentColor;
    animation: dotsBounce 1.4s ease-in-out infinite both;
}

.loading-dots span:nth-child(1) { animation-delay: -0.32s; }
.loading-dots span:nth-child(2) { animation-delay: -0.16s; }

@keyframes dotsBounce {
    0%, 80%, 100% {
        transform: scale(0);
    }
    40% {
        transform: scale(1);
    }
}

/* ===== STATUS ANIMATIONS ===== */
.status-badge {
    transition: all 0.3s ease;
}

.status-badge:hover {
    transform: scale(1.1);
}

.status-pending {
    animation: statusPulse 2s infinite;
}

@keyframes statusPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* ===== SCROLL ANIMATIONS ===== */
.scroll-reveal {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.8s ease;
}

.scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

.scroll-reveal-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: all 0.8s ease;
}

.scroll-reveal-left.revealed {
    opacity: 1;
    transform: translateX(0);
}

.scroll-reveal-right {
    opacity: 0;
    transform: translateX(50px);
    transition: all 0.8s ease;
}

.scroll-reveal-right.revealed {
    opacity: 1;
    transform: translateX(0);
}

/* ===== FLOATING ANIMATIONS ===== */
.float {
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

.float-slow {
    animation: floatSlow 4s ease-in-out infinite;
}

@keyframes floatSlow {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-15px); }
}

/* ===== ROTATION ANIMATIONS ===== */
.rotate-slow {
    animation: rotateSlow 10s linear infinite;
}

@keyframes rotateSlow {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.rotate-reverse {
    animation: rotateReverse 8s linear infinite;
}

@keyframes rotateReverse {
    from { transform: rotate(360deg); }
    to { transform: rotate(0deg); }
}

/* ===== GRADIENT ANIMATIONS ===== */
.gradient-shift {
    background: linear-gradient(-45deg, #ff6b35, #f7931e, #ff8c42, #e67a3a);
    background-size: 400% 400%;
    animation: gradientShift 3s ease infinite;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* ===== BOUNCE ANIMATIONS ===== */
.bounce-in {
    animation: bounceIn 0.8s ease forwards;
}

@keyframes bounceIn {
    0% {
        opacity: 0;
        transform: scale(0.3);
    }
    50% {
        opacity: 1;
        transform: scale(1.05);
    }
    70% {
        transform: scale(0.9);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

.bounce-in-delay {
    animation: bounceIn 0.8s ease forwards;
    animation-delay: 0.2s;
    opacity: 0;
}

/* ===== SLIDE ANIMATIONS ===== */
.slide-in-left {
    animation: slideInLeft 0.6s ease forwards;
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.slide-in-right {
    animation: slideInRight 0.6s ease forwards;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(100px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* ===== FADE ANIMATIONS ===== */
.fade-in {
    animation: fadeIn 0.6s ease forwards;
}

.fade-in-delay {
    animation: fadeIn 0.6s ease forwards;
    animation-delay: 0.3s;
    opacity: 0;
}

.fade-in-slow {
    animation: fadeIn 1s ease forwards;
}

/* ===== SCALE ANIMATIONS ===== */
.scale-in {
    animation: scaleIn 0.5s ease forwards;
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.5);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.scale-in-center {
    animation: scaleInCenter 0.6s ease forwards;
}

@keyframes scaleInCenter {
    from {
        opacity: 0;
        transform: scale(0.8) translate(-50%, -50%);
    }
    to {
        opacity: 1;
        transform: scale(1) translate(-50%, -50%);
    }
}

/* ===== RIPPLE EFFECT ===== */
.ripple {
    position: relative;
    overflow: hidden;
}

.ripple::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.ripple:active::before {
    width: 300px;
    height: 300px;
}

/* ===== GLASSMORPHISM ANIMATIONS ===== */
.glass-hover {
    transition: all 0.3s ease;
}

.glass-hover:hover {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* ===== RESPONSIVE ANIMATIONS ===== */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ===== DARK MODE ANIMATIONS ===== */
.dark .skeleton-shimmer {
    background: linear-gradient(90deg, #374151 25%, #4b5563 50%, #374151 75%);
    background-size: 200px 100%;
}

/* ===== PERFORMANCE OPTIMIZATIONS ===== */
.gpu-accelerated {
    transform: translateZ(0);
    will-change: transform;
}

.animation-paused {
    animation-play-state: paused;
}

.animation-running {
    animation-play-state: running;
}
