/* animations.css - Плавные анимации для всего приложения */

/* Плавные переходы для всех элементов */
* {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

/* Улучшенные анимации для модальных окон */
.modal {
    transition: opacity 0.3s ease, visibility 0.3s ease !important;
    animation: fadeIn 0.3s ease-out;
}

.modal-content {
    animation: slideIn 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    transform-origin: center center;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        visibility: hidden;
    }
    to {
        opacity: 1;
        visibility: visible;
    }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Анимации для карточек */
.menu-card, .member-item, .calendar-event, .featured-card {
    animation: cardAppear 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    animation-fill-mode: both;
}

.menu-card:nth-child(1) { animation-delay: 0.1s; }
.menu-card:nth-child(2) { animation-delay: 0.15s; }
.menu-card:nth-child(3) { animation-delay: 0.2s; }
.menu-card:nth-child(4) { animation-delay: 0.25s; }
.menu-card:nth-child(5) { animation-delay: 0.3s; }
.menu-card:nth-child(6) { animation-delay: 0.35s; }

@keyframes cardAppear {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Плавное появление элементов списка */
.member-item {
    animation: memberSlideIn 0.4s ease-out;
    animation-fill-mode: both;
}

.member-item:nth-child(1) { animation-delay: 0.05s; }
.member-item:nth-child(2) { animation-delay: 0.1s; }
.member-item:nth-child(3) { animation-delay: 0.15s; }
.member-item:nth-child(4) { animation-delay: 0.2s; }
.member-item:nth-child(5) { animation-delay: 0.25s; }
.member-item:nth-child(6) { animation-delay: 0.3s; }
.member-item:nth-child(7) { animation-delay: 0.35s; }
.member-item:nth-child(8) { animation-delay: 0.4s; }

@keyframes memberSlideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Анимации кнопок */
button, .btn, .pagination-btn, .menu-card {
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

button:hover, .btn:hover:not(:disabled), .menu-card:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15) !important;
}

button:active, .btn:active:not(:disabled) {
    transform: translateY(0) scale(0.98);
    transition-duration: 0.1s !important;
}

/* Плавный скролл */
html {
    scroll-behavior: smooth;
}

.members-list, .calendar-events {
    scroll-behavior: smooth;
}

/* Анимация загрузки */
.loading-spinner {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Анимация пульсации для важных элементов */
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.pulse {
    animation: pulse 2s infinite;
}

/* Плавное появление текста */
.text-appear {
    animation: textReveal 0.8s ease-out;
}

@keyframes textReveal {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Эффект параллакса для прокрутки */
.parallax {
    transition: transform 0.3s ease-out;
}
