/* Core styles that apply across all pages */
@font-face {
    font-family: 'Phonk Regular';
    src: url('../fonts/Phonk-Regular.otf') format('opentype');
}

@font-face {
    font-family: 'Phonk Contrast';
    src: url('../fonts/Phonk-Contrast.otf') format('opentype');
}

:root {
    /* Default theme (night) */
    --primary-cyan: #00f2ff;
    --bright-cyan: #80ffff;
    --dark-cyan: #00b8cc;
    --glow-cyan: #00f2ff40;
    --background: #0a0a0a;
    --surface: #141414;
    --text: #ffffff;
}

/* Day theme - Darker cyan theme */
[data-theme="day"] {
    --primary-cyan: #00a7b5;    /* Softer cyan */
    --bright-cyan: #00c3d3;     /* Lighter but not harsh */
    --dark-cyan: #008591;       /* Deeper cyan */
    --glow-cyan: #00c3d340;     /* Softer glow */
    --background: #0c2c31;      /* Dark cyan background */
    --surface: #133a40;         /* Slightly lighter surface */
    --text: #e0f5f7;           /* Light cyan-tinted text */
}

body {
    font-family: 'Phonk Regular', sans-serif;
    text-transform: uppercase;
    letter-spacing: 1px;
    background: var(--background);
    color: var(--text);
    margin: 0;
    padding-top: 80px;
    min-height: 100vh;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Global animations */
@keyframes glow {
    from {
        text-shadow: 0 0 5px var(--glow-cyan);
    }
    to {
        text-shadow: 0 0 20px var(--primary-cyan);
    }
}

.glow-text {
    animation: glow 2s ease-in-out infinite alternate;
}

/* Add these new animations */
@keyframes venomSpread {
    0% {
        transform: scale(0);
        opacity: 0;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Liquid blob effect */
@keyframes liquidSpread {
    0% {
        clip-path: polygon(0 0, 0 0, 0 100%, 0% 100%);
    }
    30% {
        clip-path: polygon(0 0, 15% 0, 10% 100%, 0 100%);
    }
    50% {
        clip-path: polygon(0 0, 40% 0, 30% 100%, 0 100%);
    }
    70% {
        clip-path: polygon(0 0, 80% 0, 70% 100%, 0 100%);
    }
    100% {
        clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
    }
}

.theme-blob {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 9999;
    background: var(--background);
    transform-origin: var(--x, 0) var(--y, 0);
    filter: url('#liquid');
}

.theme-blob.active {
    animation: liquidSpread 1.5s cubic-bezier(0.7, 0, 0.3, 1) forwards;
}

/* Add SVG filter for liquid effect */
.liquid-filter {
    position: fixed;
    top: 0;
    left: 0;
    pointer-events: none;
    opacity: 0;
}

/* Ensure smooth color transitions */
body, nav, .cyber-card, .auth-container, .footer-section {
    transition: background-color 0.3s ease;
}

/* Enhanced page transitions */
@keyframes slideInEaseOut {
    0% {
        transform: translate3d(100%, 0, 0);
        opacity: 0;
    }
    70% {
        transform: translate3d(-10%, 0, 0);
        opacity: 1;
    }
    100% {
        transform: translate3d(0, 0, 0);
        opacity: 1;
    }
}

@keyframes slideUpEaseOut {
    0% {
        transform: translate3d(0, 100%, 0);
        opacity: 0;
    }
    70% {
        transform: translate3d(0, -10%, 0);
        opacity: 1;
    }
    100% {
        transform: translate3d(0, 0, 0);
        opacity: 1;
    }
}

@keyframes rotateInScale {
    0% {
        transform: rotate(-10deg) scale(0.95);
        opacity: 0;
    }
    100% {
        transform: rotate(0) scale(1);
        opacity: 1;
    }
}

/* Add page transition container */
.page-transition {
    animation: var(--page-animation, slideInRight) 0.8s ease-out;
}

/* Remove previous animations */
/* Add new liquid color transition */
@keyframes liquidFlow {
    0% {
        clip-path: polygon(-100% 0, -80% 100%, -100% 100%, -100% 0);
    }
    100% {
        clip-path: polygon(-100% 0, 100% 0, 100% 100%, -100% 100%);
    }
}

.theme-wave {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 1;
}

.theme-wave.active {
    animation: liquidFlow 2.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* Ensure elements change color smoothly as wave passes */
/* Remove this line that was disabling all transitions:
*, *::before, *::after {
    transition: none !important;
}
*/

/* Add specific transition rules */
body, nav, .cyber-card, .auth-container, .footer-section {
    transition: background-color 0.3s ease;
}

/* Smooth page transitions */
@keyframes smoothPageIn {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

.page-content {
    animation: smoothPageIn 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Magnifying glass theme transition */
.theme-lens {
    position: fixed;
    pointer-events: none;
    z-index: 9999;
    width: 150px;
    height: 150px;
    border-radius: 50%;
    background: var(--background);
    transform: translate(-50%, -50%);
    box-shadow: 0 0 0 2000px rgba(0, 0, 0, 0.3);
    transition: width 0.3s, height 0.3s;
    backdrop-filter: grayscale(0);
    mix-blend-mode: normal;
}

.theme-lens.active {
    width: 3000px;
    height: 3000px;
    transition: width 1.5s cubic-bezier(0.7, 0, 0.3, 1),
                height 1.5s cubic-bezier(0.7, 0, 0.3, 1);
}

.ripple {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    z-index: 9999;
}

.ripple-circle {
    position: absolute;
    border-radius: 50%;
    animation: rippleEffect 1s cubic-bezier(0.1, 0, 0.3, 1) forwards;
    background: radial-gradient(
        circle,
        var(--background) 0%,
        var(--background) 60%,
        rgba(0, 242, 255, 0.3) 61%,
        transparent 65%,
        transparent 100%
    );
    box-shadow: 0 0 50px var(--primary-cyan);
}

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

/* Add glow effect */
.ripple-glow {
    position: absolute;
    border-radius: 50%;
    background: var(--primary-cyan);
    filter: blur(20px);
    opacity: 0.2;
    animation: glowPulse 0.8s ease-out forwards;
}

@keyframes glowPulse {
    0% {
        transform: scale(0);
        opacity: 0.4;
    }
    40% {
        opacity: 0.2;
    }
    100% {
        transform: scale(3);
        opacity: 0;
    }
}

/* Particle effect */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
    overflow: hidden;
}

@keyframes particle-storm1 {
    0% {
        transform: translate3d(var(--start-x, 0), var(--start-y, 0), 0) rotate(0deg);
    }
    100% {
        transform: translate3d(var(--end-x, 100vw), var(--end-y, 100vh), 0) rotate(360deg);
    }
}

@keyframes particle-storm2 {
    0% {
        transform: translate3d(var(--start-x, 0), var(--start-y, 0), 0) rotate(0deg);
    }
    50% {
        transform: translate3d(var(--mid-x, 50vw), var(--mid-y, 50vh), 0) rotate(180deg);
    }
    100% {
        transform: translate3d(var(--end-x, 100vw), var(--end-y, 100vh), 0) rotate(360deg);
    }
}

@keyframes particle-fade {
    0%, 100% { opacity: 0; }
    20%, 80% { opacity: var(--opacity, 0.4); }
}

.particles span {
    --size: var(--particle-size, 3px);
    position: absolute;
    width: var(--size);
    height: var(--size);
    background: var(--primary-cyan);
    border-radius: 50%;
    box-shadow: 0 0 8px var(--primary-cyan);
    filter: blur(1px);
    animation: 
        particle-storm1 var(--duration, 15s) linear infinite,
        particle-fade var(--duration, 15s) linear infinite;
    top: var(--top, 50%);
    left: var(--left, 50%);
}

/* Create multiple particle variations */
.particles span:nth-child(6n) {
    --particle-size: 2px;
    filter: blur(2px);
    box-shadow: 0 0 12px var(--primary-cyan);
    animation: 
        particle-storm2 var(--duration, 15s) ease-in-out infinite,
        particle-fade var(--duration, 15s) linear infinite;
}

.particles span:nth-child(6n + 1) {
    --particle-size: 4px;
    box-shadow: 0 0 15px var(--primary-cyan);
}

.particles span:nth-child(6n + 2) {
    --particle-size: 5px;
    box-shadow: 0 0 18px var(--primary-cyan);
    animation: 
        particle-storm2 var(--duration, 15s) ease-in-out infinite,
        particle-fade var(--duration, 15s) linear infinite;
}

.particles span:nth-child(6n + 3) {
    --particle-size: 2px;
    filter: blur(2px);
    box-shadow: 0 0 12px var(--primary-cyan);
}

.particles span:nth-child(6n + 4) {
    --particle-size: 3px;
    box-shadow: 0 0 15px var(--primary-cyan);
    animation: 
        particle-storm2 var(--duration, 15s) ease-in-out infinite,
        particle-fade var(--duration, 15s) linear infinite;
}

.particles span:nth-child(6n + 5) {
    --particle-size: 3.5px;
    filter: blur(2px);
    box-shadow: 0 0 20px var(--primary-cyan);
} 