/* ============================================================
   БАНК ХВБ — АНИМАЦИИ
   ============================================================ */

/* ===== FADE-IN ПРИ СКРОЛЛЕ ===== */
.fade-in {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}
.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ===== КАСКАДНОЕ ПОЯВЛЕНИЕ ===== */
.stagger > * {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.stagger.visible > *:nth-child(1) { transition-delay: 0.05s; }
.stagger.visible > *:nth-child(2) { transition-delay: 0.15s; }
.stagger.visible > *:nth-child(3) { transition-delay: 0.25s; }
.stagger.visible > *:nth-child(4) { transition-delay: 0.35s; }
.stagger.visible > *:nth-child(5) { transition-delay: 0.45s; }
.stagger.visible > *:nth-child(6) { transition-delay: 0.55s; }
.stagger.visible > *:nth-child(7) { transition-delay: 0.65s; }
.stagger.visible > *:nth-child(8) { transition-delay: 0.75s; }
.stagger.visible > * {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================================
   ОБЩИЕ KEYFRAMES
   ============================================================ */

@keyframes fadeInUp {
    0% { opacity: 0; transform: translateY(20px); }
    100% { opacity: 1; transform: translateY(0); }
}

@keyframes fadeInDown {
    0% { opacity: 0; transform: translateY(-20px); }
    100% { opacity: 1; transform: translateY(0); }
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-6px); }
}

@keyframes shimmer {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

@keyframes cardGlow {
    0%, 100% { box-shadow: 0 5px 20px rgba(0,0,0,0.3); }
    50% { box-shadow: 0 5px 40px rgba(214,175,106, 0.05); }
}

/* ============================================================
   ПУЛЬСАЦИЯ ЛОГОТИПА
   ============================================================ */

@keyframes logoPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.03); }
}

/* ============================================================
   СВЕЧЕНИЕ КАРТОЧЕК ПОД КУРСОРОМ
   ============================================================ */

.card {
    position: relative;
    overflow: hidden;
}
.card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at var(--x, 50%) var(--y, 50%),
                rgba(214,175,106, 0.15), transparent 60%);
    opacity: 0;
    transition: opacity 0.35s ease;
    pointer-events: none;
    z-index: 2;
}
.card:hover::before { opacity: 1; }

/* ============================================================
   3D-TILT КАРТОЧЕК
   ============================================================ */

.tilt {
    transition: transform 0.3s ease;
}

/* ============================================================
   АНИМАЦИЯ КНОПОК (Ripple-эффект)
   ============================================================ */

.btn {
    position: relative;
    overflow: hidden;
}
.btn::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0; height: 0;
    background: rgba(255, 255, 255, 0.35);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.5s ease, height 0.5s ease;
}
.btn:active::after {
    width: 300px;
    height: 300px;
    transition: 0s;
}

/* ============================================================
   КАСКАДНОЕ ПОЯВЛЕНИЕ КАРТОЧЕК (по классу)
   ============================================================ */

.card-wrapper {
    animation: fadeInUp 0.7s ease forwards;
    opacity: 0;
}
.card-wrapper:nth-child(1)  { animation-delay: 0.1s; }
.card-wrapper:nth-child(2)  { animation-delay: 0.15s; }
.card-wrapper:nth-child(3)  { animation-delay: 0.2s; }
.card-wrapper:nth-child(4)  { animation-delay: 0.25s; }
.card-wrapper:nth-child(5)  { animation-delay: 0.3s; }
.card-wrapper:nth-child(6)  { animation-delay: 0.35s; }
.card-wrapper:nth-child(7)  { animation-delay: 0.4s; }
.card-wrapper:nth-child(8)  { animation-delay: 0.45s; }
.card-wrapper:nth-child(9)  { animation-delay: 0.5s; }
.card-wrapper:nth-child(10) { animation-delay: 0.55s; }
.card-wrapper:nth-child(11) { animation-delay: 0.6s; }
.card-wrapper:nth-child(12) { animation-delay: 0.65s; }

/* ============================================================
   ГРИД-ЭЛЕМЕНТЫ (для банка и казино)
   ============================================================ */

.grid-item {
    animation: fadeInUp 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    opacity: 0;
}
.grid-item:nth-child(1) { animation-delay: 0.1s; }
.grid-item:nth-child(2) { animation-delay: 0.15s; }
.grid-item:nth-child(3) { animation-delay: 0.2s; }
.grid-item:nth-child(4) { animation-delay: 0.25s; }
.grid-item:nth-child(5) { animation-delay: 0.3s; }
.grid-item:nth-child(6) { animation-delay: 0.35s; }
.grid-item:nth-child(7) { animation-delay: 0.4s; }
.grid-item:nth-child(8) { animation-delay: 0.45s; }
.grid-item:nth-child(9) { animation-delay: 0.5s; }

/* ============================================================
   ПАРЯЩИЕ ИКОНКИ
   ============================================================ */

.card .icon,
.stat-icon {
    animation: float 3s ease-in-out infinite;
}

/* ============================================================
   ТОСТ (всплывающее сообщение)
   ============================================================ */

.toast {
    position: fixed;
    bottom: 32px;
    left: 50%;
    transform: translateX(-50%) translateY(80px);
    background: #1b1b1e;
    color: #d6af6a;
    border: 1px solid #d6af6a;
    border-radius: 10px;
    padding: 12px 24px;
    font-size: 15px;
    box-shadow: 0 8px 30px rgba(214,175,106, 0.25), 0 0 40px rgba(214,175,106, 0.15);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.35s ease, opacity 0.35s ease;
    z-index: 200;
}
.toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

/* ============================================================
   МОДАЛЬНОЕ ПОЯВЛЕНИЕ
   ============================================================ */

@keyframes modalPop {
    0% { opacity: 0; transform: scale(0.9) translateY(10px); }
    100% { opacity: 1; transform: scale(1) translateY(0); }
}

/* ============================================================
   ПОДДЕРЖКА УМЕНЬШЕННОЙ АНИМАЦИИ
   ============================================================ */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}