/* 501st HOLO UI Style based off the HOLOGRAPHIC INTERFACE STYLES */
/* Currently Work In Progress */


/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    /* scroll-behavior: smooth; - Removed to prevent conflict with Lenis */
}

body {
    font-family: 'Inter', sans-serif;
    background: #0A0A1A;
    color: #ffffff;
    overflow-x: hidden;
    position: relative;
}

/* ===== HOLOGRAPHIC CURSOR ===== */
.holo-cursor {
    position: fixed;
    width: 20px;
    height: 20px;
    border: 2px solid #00D4FF;
    border-radius: 50%;
    pointer-events: none;
    z-index: 9999;
    mix-blend-mode: difference;
    transition: all 0.1s ease;
    transform: translate(-50%, -50%);
}

.holo-cursor-trail {
    position: fixed;
    width: 8px;
    height: 8px;
    background: #00D4FF;
    border-radius: 50%;
    pointer-events: none;
    z-index: 9998;
    opacity: 0.6;
    transition: all 0.2s ease;
    transform: translate(-50%, -50%);
}

/* ===== MATRIX RAIN BACKGROUND ===== */
.matrix-rain {
    background: linear-gradient(180deg, transparent 0%, rgba(0, 212, 255, 0.03) 50%, transparent 100%);
    animation: matrix 20s linear infinite;
}

.matrix-rain::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 20% 20%, rgba(0, 212, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(124, 58, 237, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 60%, rgba(245, 158, 11, 0.05) 0%, transparent 50%);
    animation: float 8s ease-in-out infinite;
}

/* ===== HOLOGRAPHIC GRID ===== */
.holo-grid {
    background-image: 
        linear-gradient(rgba(0, 212, 255, 0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 212, 255, 0.1) 1px, transparent 1px);
    background-size: 50px 50px;
    opacity: 0.3;
    animation: grid-pulse 4s ease-in-out infinite;
}

@keyframes grid-pulse {
    0%, 100% { opacity: 0.1; }
    50% { opacity: 0.3; }
}

/* ===== SCANNING LINE ===== */
.scan-line {
    box-shadow: 0 0 20px #00D4FF, 0 0 40px #00D4FF;
}

/* ===== LOADING SCREEN ===== */
.loading-screen {
    backdrop-filter: blur(10px);
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.loading-screen.hidden {
    opacity: 0;
    visibility: hidden;
}

.loading-progress {
    animation: loading 3s ease-in-out forwards;
}

@keyframes loading {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(0); }
}

.loading-shape {
    stroke-dasharray: 200;
    stroke-dashoffset: 200;
    animation: draw 2s ease-in-out infinite;
}

@keyframes draw {
    0% { stroke-dashoffset: 200; }
    50% { stroke-dashoffset: 0; }
    100% { stroke-dashoffset: -200; }
}

/* ===== NAVIGATION ===== */
.holo-glass {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 212, 255, 0.2);
}

.nav-link {
    color: rgba(255, 255, 255, 0.8);
    transition: all 0.3s ease;
    font-weight: 500;
}

.nav-link:hover {
    color: #00D4FF;
}

.holo-button {
    background: linear-gradient(135deg, #00D4FF, #7C3AED);
    color: #0A0A1A;
    border: none;
    transition: all 0.3s ease;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.holo-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 212, 255, 0.3);
}

.holo-button-outline {
    background: transparent;
    border: 2px solid rgba(0, 212, 255, 0.5);
    color: #00D4FF;
    transition: all 0.3s ease;
}

.holo-button-outline:hover {
    background: rgba(0, 212, 255, 0.1);
    border-color: #00D4FF;
}

/* ===== MOBILE MENU ===== */
.mobile-menu.active {
    opacity: 1;
    pointer-events: all;
}

/* ===== HOLOGRAPHIC TEXT EFFECTS ===== */
.holo-text {
    position: relative;
    text-shadow: 0 0 10px rgba(0, 212, 255, 0.5);
}

.holo-text::before {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    animation: shimmer 3s infinite;
    -webkit-background-clip: text;
    background-clip: text;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* ===== TYPING TEXT EFFECT ===== */
.typing-text {
    overflow: hidden;
    border-right: 2px solid #00D4FF;
    white-space: nowrap;
    animation: typing 3s steps(40, end), blink-caret 0.75s step-end infinite;
}

@keyframes typing {
    from { width: 0; }
    to { width: 100%; }
}

@keyframes blink-caret {
    from, to { border-color: transparent; }
    50% { border-color: #00D4FF; }
}

/* ===== HOLOGRAPHIC CARDS ===== */
.holo-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(0, 212, 255, 0.2);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.holo-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.5s ease;
}

.holo-card:hover::before {
    left: 100%;
}

.holo-card:hover {
    border-color: rgba(0, 212, 255, 0.5);
    box-shadow: 0 10px 40px rgba(0, 212, 255, 0.2);
    transform: translateY(-5px);
}

/* ===== FEATURE CARDS ===== */
.holo-feature-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(0, 212, 255, 0.2);
    transition: all 0.3s ease;
}

.holo-feature-card:hover {
    transform: scale(1.02);
    border-color: rgba(0, 212, 255, 0.5);
    box-shadow: 0 20px 60px rgba(0, 212, 255, 0.2);
}

/* ===== SOCIAL LINKS ===== */
.holo-social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(0, 212, 255, 0.3);
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.7);
    transition: all 0.3s ease;
    text-decoration: none;
}

.holo-social-link:hover {
    background: rgba(0, 212, 255, 0.1);
    border-color: #00D4FF;
    color: #00D4FF;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 212, 255, 0.3);
}

/* ===== TERMINAL STYLES ===== */
.holo-terminal {
    background: rgba(10, 10, 26, 0.8);
    border: 1px solid rgba(0, 212, 255, 0.3);
    font-family: 'JetBrains Mono', monospace;
    position: relative;
    overflow: hidden;
}

.holo-terminal::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, #00D4FF, transparent);
    animation: scan-line 2s linear infinite;
}

@keyframes scan-line {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* ===== COUNTER ANIMATION ===== */
.counter {
    font-variant-numeric: tabular-nums;
}

/* ===== BUTTON STYLES ===== */
.holo-button-primary {
    background: linear-gradient(135deg, #00D4FF, #7C3AED);
    color: #0A0A1A;
    border: none;
    transition: all 0.3s ease;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

.holo-button-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(0, 212, 255, 0.4);
}

.holo-button-outline {
    background: transparent;
    border: 2px solid #00D4FF;
    color: #00D4FF;
    transition: all 0.3s ease;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

.holo-button-outline:hover {
    background: #00D4FF;
    color: #0A0A1A;
    box-shadow: 0 10px 30px rgba(0, 212, 255, 0.3);
}

/* ===== 3D HOLOGRAPHIC BACKGROUND ===== */
.holo-3d-bg {
    background: 
        radial-gradient(ellipse at top, rgba(0, 212, 255, 0.1) 0%, transparent 70%),
        radial-gradient(ellipse at bottom, rgba(124, 58, 237, 0.1) 0%, transparent 70%);
    animation: holo-shift 8s ease-in-out infinite;
}

@keyframes holo-shift {
    0%, 100% { 
        background: 
            radial-gradient(ellipse at top, rgba(0, 212, 255, 0.1) 0%, transparent 70%),
            radial-gradient(ellipse at bottom, rgba(124, 58, 237, 0.1) 0%, transparent 70%);
    }
    50% { 
        background: 
            radial-gradient(ellipse at top, rgba(124, 58, 237, 0.1) 0%, transparent 70%),
            radial-gradient(ellipse at bottom, rgba(0, 212, 255, 0.1) 0%, transparent 70%);
    }
}

/* ===== FLOATING PARTICLES ===== */
.floating-particles {
    background-image: 
        radial-gradient(2px 2px at 20px 30px, rgba(0, 212, 255, 0.3), transparent),
        radial-gradient(2px 2px at 40px 70px, rgba(124, 58, 237, 0.3), transparent),
        radial-gradient(1px 1px at 90px 40px, rgba(245, 158, 11, 0.3), transparent),
        radial-gradient(1px 1px at 130px 80px, rgba(16, 185, 129, 0.3), transparent);
    background-repeat: repeat;
    background-size: 150px 100px;
    animation: float-particles 20s linear infinite;
}

@keyframes float-particles {
    0% { transform: translateY(0px); }
    100% { transform: translateY(-100px); }
}

/* ===== GLITCH EFFECTS ===== */
.glitch-text {
    position: relative;
    color: #ffffff;
    font-weight: 900;
}

.glitch-text::before,
.glitch-text::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.glitch-text::before {
    animation: glitch-1 0.5s infinite;
    color: #00D4FF;
    z-index: -1;
}

.glitch-text::after {
    animation: glitch-2 0.5s infinite;
    color: #7C3AED;
    z-index: -2;
}

@keyframes glitch-1 {
    0%, 14%, 15%, 49%, 50%, 99%, 100% {
        transform: translate(0);
    }
    15%, 49% {
        transform: translate(-2px, 2px);
    }
}

@keyframes glitch-2 {
    0%, 20%, 21%, 62%, 63%, 99%, 100% {
        transform: translate(0);
    }
    21%, 62% {
        transform: translate(2px, -2px);
    }
}

/* ===== SCROLL ANIMATIONS ===== */
@keyframes scroll {
    0% { transform: translateY(-100%); }
    100% { transform: translateY(100%); }
}

.animate-scroll {
    animation: scroll 2s ease-in-out infinite;
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    .holo-cursor,
    .holo-cursor-trail {
        display: none;
    }
    
    .scan-line {
        display: none;
    }
    
    .matrix-rain {
        opacity: 0.5;
    }
    
    .holo-grid {
        background-size: 25px 25px;
        opacity: 0.2;
    }
    
    .floating-particles {
        opacity: 0.3;
    }
}

/* ===== ACCESSIBILITY ===== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .typing-text {
        animation: none;
        border-right: none;
    }
    
    .matrix-rain,
    .floating-particles,
    .scan-line {
        display: none;
    }
}

/* ===== CUSTOM SCROLLBAR ===== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #00D4FF, #7C3AED);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #7C3AED, #00D4FF);
}

/* ===== SELECTION STYLES ===== */
::selection {
    background: rgba(0, 212, 255, 0.3);
    color: #ffffff;
}

::-moz-selection {
    background: rgba(0, 212, 255, 0.3);
    color: #ffffff;
}

/* ===== FOCUS STYLES ===== */
*:focus {
    outline: 2px solid #00D4FF;
    outline-offset: 2px;
}

/* ===== PRINT STYLES ===== */
@media print {
    .matrix-rain,
    .holo-grid,
    .scan-line,
    .floating-particles,
    .holo-cursor,
    .holo-cursor-trail {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
    
    .holo-card,
    .holo-feature-card {
        border: 1px solid #ccc !important;
        background: white !important;
    }
}