/* ========================================
   GLONECT Stereoscopic Effects
   ======================================== */

/* Стереоскопический фон */
.stereo-background {
    position: relative;
    perspective: 1000px;
}

.stereo-background img {
    filter: blur(0.5px);
    mix-blend-mode: overlay;
}

/* Third Eye эффект при наведении */
.hero:hover .stereo-background img {
    animation: stereoShift 0.6s ease-out;
}

@keyframes stereoShift {
    0% {
        transform: translateX(0) translateY(0);
        opacity: 0.15;
    }
    50% {
        opacity: 0.25;
    }
    100% {
        transform: translateX(2px) translateY(-2px);
        opacity: 0.15;
    }
}

/* Фрактальные спирали (Фибоначчи) */
.fibonacci-spiral {
    position: absolute;
    opacity: 0.05;
    pointer-events: none;
}

.fibonacci-spiral svg {
    width: 100%;
    height: 100%;
    stroke: var(--primary);
    stroke-width: 1;
    fill: none;
}

/* Сакральная геометрия в фоне */
.sacred-geometry {
    position: absolute;
    opacity: 0.08;
    mix-blend-mode: overlay;
    pointer-events: none;
}

.sacred-geometry.flower {
    animation: floatSlow 8s ease-in-out infinite;
}

.sacred-geometry.metatron {
    animation: rotateSlow 20s linear infinite;
}

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

@keyframes rotateSlow {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* Микро-анимации для доверия */
.trust-marker {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    animation: slideIn 0.6s ease-out backwards;
}

.trust-marker:nth-child(1) { animation-delay: 0s; }
.trust-marker:nth-child(2) { animation-delay: 0.2s; }
.trust-marker:nth-child(3) { animation-delay: 0.4s; }

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

/* Пульсирующие элементы */
.pulse {
    animation: pulse 2s ease-in-out infinite;
}

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

/* Shimmer эффект для загрузки */
.shimmer {
    background: linear-gradient(
        90deg,
        #f0f0f0 25%,
        #e0e0e0 50%,
        #f0f0f0 75%
    );
    background-size: 200% 100%;
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* Гравитационный эффект для карточек */
.card-hover {
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.card-hover:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0, 86, 179, 0.15);
}

/* Волновой эффект для кнопок */
.btn-wave {
    position: relative;
    overflow: hidden;
}

.btn-wave::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transform: translate(-50%, -50%);
    pointer-events: none;
}

.btn-wave:active::before {
    animation: wave 0.6s ease-out;
}

@keyframes wave {
    0% {
        width: 0;
        height: 0;
        opacity: 1;
    }
    100% {
        width: 300px;
        height: 300px;
        opacity: 0;
    }
}

/* Градиентная анимация */
.gradient-animate {
    background: linear-gradient(
        -45deg,
        #0056b3,
        #4caf50,
        #0056b3,
        #4caf50
    );
    background-size: 400% 400%;
    animation: gradient 15s ease infinite;
}

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

/* Мерцание доверия */
.trust-pulse {
    animation: trustPulse 3s ease-in-out infinite;
}

@keyframes trustPulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.05);
        opacity: 0.8;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Стереоскопический текст (3D эффект) */
.stereo-text {
    text-shadow:
        -2px 0 #0056b3,
        2px 0 #4caf50,
        0 0 10px rgba(0, 86, 179, 0.3);
}

/* Параллакс для мобильных */
@media (max-width: 768px) {
    .stereo-background {
        display: none;
    }
    
    .fibonacci-spiral {
        display: none;
    }
    
    .sacred-geometry {
        opacity: 0.03;
    }
}

/* Отключение анимаций для пользователей с prefers-reduced-motion */
@media (prefers-reduced-motion: reduce) {
    .stereo-background img,
    .fibonacci-spiral,
    .sacred-geometry,
    .trust-marker,
    .pulse,
    .shimmer,
    .card-hover,
    .btn-wave::before,
    .gradient-animate,
    .trust-pulse {
        animation: none !important;
        transition: none !important;
    }
}
