/* Продвинутые мистические эффекты для Проекта Наталья */

/* Луна на фоне */
.mystical-moon {
    position: fixed;
    width: 300px;
    height: 300px;
    top: 10%;
    right: 5%;
    z-index: 1;
    pointer-events: none;
    opacity: 0.15;
    background: radial-gradient(circle at 30% 30%, 
        rgba(255, 255, 255, 0.3) 0%,
        rgba(212, 175, 55, 0.2) 20%,
        transparent 50%);
    border-radius: 50%;
    filter: blur(20px);
    animation: moon-glow 8s ease-in-out infinite;
}

@keyframes moon-glow {
    0%, 100% {
        opacity: 0.15;
        transform: scale(1);
    }
    50% {
        opacity: 0.25;
        transform: scale(1.1);
    }
}

/* Кристаллы */
.mystical-crystals {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 2;
    pointer-events: none;
    overflow: hidden;
}

.crystal {
    position: absolute;
    width: 40px;
    height: 40px;
    opacity: 0.1;
    background: linear-gradient(135deg, 
        rgba(212, 175, 55, 0.3) 0%,
        rgba(74, 20, 140, 0.2) 50%,
        transparent 100%);
    clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
    animation: crystal-float 12s ease-in-out infinite;
    filter: blur(2px);
}

.crystal:nth-child(1) {
    top: 15%;
    left: 8%;
    animation-delay: 0s;
    transform: rotate(45deg);
}

.crystal:nth-child(2) {
    top: 60%;
    right: 12%;
    animation-delay: 3s;
    transform: rotate(-30deg);
}

.crystal:nth-child(3) {
    bottom: 25%;
    left: 15%;
    animation-delay: 6s;
    transform: rotate(60deg);
}

.crystal:nth-child(4) {
    top: 40%;
    right: 8%;
    animation-delay: 9s;
    transform: rotate(-45deg);
}

@keyframes crystal-float {
    0%, 100% {
        transform: translateY(0) rotate(var(--rotation, 0deg)) scale(1);
        opacity: 0.1;
    }
    25% {
        transform: translateY(-30px) rotate(calc(var(--rotation, 0deg) + 90deg)) scale(1.2);
        opacity: 0.2;
    }
    50% {
        transform: translateY(-60px) rotate(calc(var(--rotation, 0deg) + 180deg)) scale(0.9);
        opacity: 0.15;
    }
    75% {
        transform: translateY(-30px) rotate(calc(var(--rotation, 0deg) + 270deg)) scale(1.1);
        opacity: 0.2;
    }
}

/* Руны и магические символы */
.mystical-runes {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 2;
    pointer-events: none;
    opacity: 0.08;
}

.rune {
    position: absolute;
    font-size: 3rem;
    color: var(--gold);
    font-family: 'Cinzel', serif;
    text-shadow: 0 0 15px var(--text-glow);
    animation: rune-appear 15s ease-in-out infinite;
}

.rune:nth-child(1) {
    top: 20%;
    left: 5%;
    content: 'ᚠ';
    animation-delay: 0s;
}

.rune:nth-child(2) {
    top: 70%;
    right: 8%;
    content: 'ᚢ';
    animation-delay: 5s;
}

.rune:nth-child(3) {
    bottom: 30%;
    left: 10%;
    content: 'ᚦ';
    animation-delay: 10s;
}

@keyframes rune-appear {
    0%, 90%, 100% {
        opacity: 0;
        transform: scale(0.5) rotate(0deg);
    }
    5%, 85% {
        opacity: 0.15;
        transform: scale(1) rotate(360deg);
    }
}

/* Энергетические линии (улучшенные) */
.mystical-energy-lines {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 2;
    pointer-events: none;
    overflow: hidden;
}

.energy-line {
    position: absolute;
    width: 1px;
    height: 200px;
    background: linear-gradient(to bottom,
        transparent 0%,
        rgba(212, 175, 55, 0.3) 20%,
        rgba(212, 175, 55, 0.6) 50%,
        rgba(212, 175, 55, 0.3) 80%,
        transparent 100%);
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.5);
    animation: energy-flow-vertical 4s ease-in-out infinite;
}

.energy-line:nth-child(1) {
    left: 10%;
    animation-delay: 0s;
}

.energy-line:nth-child(2) {
    left: 30%;
    animation-delay: 1s;
}

.energy-line:nth-child(3) {
    left: 50%;
    animation-delay: 2s;
}

.energy-line:nth-child(4) {
    left: 70%;
    animation-delay: 1.5s;
}

.energy-line:nth-child(5) {
    left: 90%;
    animation-delay: 0.5s;
}

@keyframes energy-flow-vertical {
    0% {
        opacity: 0;
        transform: translateY(-200px);
    }
    50% {
        opacity: 1;
    }
    100% {
        opacity: 0;
        transform: translateY(calc(100vh + 200px));
    }
}

/* Мистические градиенты для текста */
.mystical-text-gradient {
    background: linear-gradient(135deg,
        #d4af37 0%,
        #f4e4bc 25%,
        #d4af37 50%,
        #f4e4bc 75%,
        #d4af37 100%);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradient-shift-text 3s ease infinite;
    text-shadow: 0 0 30px rgba(212, 175, 55, 0.5);
}

@keyframes gradient-shift-text {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

/* Улучшенное свечение для карт */
.tarot-card::before {
    content: '';
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    background: linear-gradient(45deg,
        rgba(212, 175, 55, 0.1),
        rgba(74, 20, 140, 0.1),
        rgba(212, 175, 55, 0.1));
    border-radius: 20px;
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s ease;
    filter: blur(10px);
}

.tarot-card:hover::before {
    opacity: 1;
    animation: card-aura 2s ease-in-out infinite;
}

@keyframes card-aura {
    0%, 100% {
        box-shadow: 0 0 20px rgba(212, 175, 55, 0.3);
    }
    50% {
        box-shadow: 0 0 40px rgba(212, 175, 55, 0.6), 0 0 60px rgba(74, 20, 140, 0.4);
    }
}

/* Мистические частицы вокруг элементов */
.mystical-particles {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    pointer-events: none;
    overflow: hidden;
    border-radius: inherit;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--gold);
    border-radius: 50%;
    box-shadow: 0 0 6px var(--gold);
    opacity: 0;
    animation: particle-float 3s ease-in-out infinite;
}

@keyframes particle-float {
    0% {
        opacity: 0;
        transform: translateY(0) scale(0);
    }
    20% {
        opacity: 1;
        transform: translateY(-20px) scale(1);
    }
    80% {
        opacity: 1;
        transform: translateY(-80px) scale(1);
    }
    100% {
        opacity: 0;
        transform: translateY(-100px) scale(0);
    }
}

/* Улучшенные эффекты для кнопок */
.mystical-button {
    position: relative;
    overflow: hidden;
}

.mystical-button::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(212, 175, 55, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.mystical-button:hover::after {
    width: 300px;
    height: 300px;
    animation: button-ripple 0.6s ease-out;
}

@keyframes button-ripple {
    0% {
        opacity: 0.3;
    }
    100% {
        opacity: 0;
    }
}

/* Мистические границы для контейнеров */
.mystical-border {
    position: relative;
    border: 2px solid transparent;
    background: linear-gradient(var(--deep-purple), var(--deep-purple)) padding-box,
                linear-gradient(135deg, var(--gold), var(--mystic-blue), var(--gold)) border-box;
    border-radius: 15px;
}

.mystical-border::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(135deg,
        rgba(212, 175, 55, 0.5),
        rgba(74, 20, 140, 0.5),
        rgba(212, 175, 55, 0.5));
    border-radius: 15px;
    z-index: -1;
    opacity: 0;
    animation: border-glow 3s ease-in-out infinite;
}

@keyframes border-glow {
    0%, 100% {
        opacity: 0.3;
        filter: blur(5px);
    }
    50% {
        opacity: 0.6;
        filter: blur(10px);
    }
}

/* Плавающие магические круги */
.mystical-circles {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 1;
    pointer-events: none;
    overflow: hidden;
}

.mystical-circle {
    position: absolute;
    border: 1px solid rgba(212, 175, 55, 0.2);
    border-radius: 50%;
    animation: circle-expand 8s ease-in-out infinite;
}

.mystical-circle:nth-child(1) {
    width: 200px;
    height: 200px;
    top: 20%;
    left: 15%;
    animation-delay: 0s;
}

.mystical-circle:nth-child(2) {
    width: 150px;
    height: 150px;
    bottom: 25%;
    right: 20%;
    animation-delay: 2s;
}

.mystical-circle:nth-child(3) {
    width: 100px;
    height: 100px;
    top: 60%;
    left: 10%;
    animation-delay: 4s;
}

@keyframes circle-expand {
    0%, 100% {
        transform: scale(1);
        opacity: 0.2;
    }
    50% {
        transform: scale(1.5);
        opacity: 0.4;
    }
}

/* Улучшенные эффекты для текста */
.natalia-message h2,
.reading-intro h2 {
    position: relative;
    display: inline-block;
}

.natalia-message h2::after,
.reading-intro h2::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg,
        transparent,
        var(--gold),
        transparent);
    animation: underline-glow 2s ease-in-out infinite;
}

@keyframes underline-glow {
    0%, 100% {
        box-shadow: 0 0 5px var(--gold);
        opacity: 0.5;
    }
    50% {
        box-shadow: 0 0 15px var(--gold);
        opacity: 1;
    }
}

/* Мистические тени */
.mystical-shadow {
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5),
                0 0 20px rgba(212, 175, 55, 0.2),
                inset 0 0 20px rgba(74, 20, 140, 0.1);
}

/* Пульсирующее свечение для важных элементов */
.mystical-pulse {
    animation: mystical-pulse-glow 2s ease-in-out infinite;
}

@keyframes mystical-pulse-glow {
    0%, 100% {
        box-shadow: 0 0 10px rgba(212, 175, 55, 0.3),
                    0 0 20px rgba(212, 175, 55, 0.2);
    }
    50% {
        box-shadow: 0 0 20px rgba(212, 175, 55, 0.6),
                    0 0 40px rgba(212, 175, 55, 0.4),
                    0 0 60px rgba(74, 20, 140, 0.3);
    }
}

/* Адаптация для мобильных устройств */
@media (max-width: 768px) {
    .mystical-moon {
        width: 200px;
        height: 200px;
        opacity: 0.1;
    }
    
    .crystal {
        width: 30px;
        height: 30px;
        opacity: 0.08;
    }
    
    .rune {
        font-size: 2rem;
        opacity: 0.05;
    }
    
    .mystical-circle {
        opacity: 0.15;
    }
}
