/* ==========================================================================
   ADVANCED TECH COMPONENTS & EFFECTS
   ========================================================================== */

/* Cyberpunk Grid Effect */
.cyber-grid {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    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;
    animation: gridMove 20s linear infinite;
    opacity: 0.3;
    z-index: -1;
}

@keyframes gridMove {
    0% { transform: translate(0, 0); }
    100% { transform: translate(50px, 50px); }
}

/* Terminal-style text blocks */
.terminal-block {
    background: rgba(0, 0, 0, 0.8);
    border: 1px solid var(--success-color);
    border-radius: 8px;
    padding: 1rem;
    font-family: var(--font-mono);
    color: var(--success-color);
    margin: 1rem 0;
    position: relative;
    overflow: hidden;
}

.terminal-block::before {
    content: '> ';
    color: var(--primary-color);
    font-weight: bold;
}

.terminal-block::after {
    content: '_';
    animation: blink 1s infinite;
    color: var(--success-color);
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

/* Holographic card effect */
.holo-card {
    background: linear-gradient(45deg, 
        rgba(0, 212, 255, 0.1) 0%,
        rgba(0, 102, 255, 0.1) 25%,
        rgba(255, 107, 53, 0.1) 50%,
        rgba(0, 102, 255, 0.1) 75%,
        rgba(0, 212, 255, 0.1) 100%
    );
    background-size: 400% 400%;
    animation: holoShift 6s ease-in-out infinite;
    border: 1px solid rgba(0, 212, 255, 0.3);
    position: relative;
    overflow: hidden;
}

.holo-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transform: rotate(45deg);
    transition: transform 0.6s;
    pointer-events: none;
}

.holo-card:hover::before {
    transform: rotate(45deg) translate(50%, 50%);
}

@keyframes holoShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Scanning line effect */
.scan-line {
    position: relative;
    overflow: hidden;
}

.scan-line::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--primary-color), transparent);
    animation: scan 3s ease-in-out infinite;
}

@keyframes scan {
    0% { left: -100%; }
    100% { left: 100%; }
}

/* Data stream effect */
.data-stream {
    position: absolute;
    top: 0;
    right: 0;
    width: 200px;
    height: 100%;
    background: linear-gradient(180deg, 
        transparent 0%,
        rgba(0, 212, 255, 0.1) 20%,
        rgba(0, 212, 255, 0.2) 50%,
        rgba(0, 212, 255, 0.1) 80%,
        transparent 100%
    );
    animation: dataFlow 4s ease-in-out infinite;
    opacity: 0.6;
}

@keyframes dataFlow {
    0%, 100% { transform: translateY(-100%); }
    50% { transform: translateY(100%); }
}

/* Circuit board pattern */
.circuit-pattern {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%2300d4ff' fill-opacity='0.1'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.1;
    animation: circuitPulse 8s ease-in-out infinite;
}

@keyframes circuitPulse {
    0%, 100% { opacity: 0.1; }
    50% { opacity: 0.3; }
}

/* Glowing border effect */
.glow-border {
    position: relative;
    border: 1px solid transparent;
    background: linear-gradient(var(--dark-bg), var(--dark-bg)) padding-box,
                linear-gradient(45deg, var(--primary-color), var(--secondary-color)) border-box;
    border-radius: 20px;
}

.glow-border::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    border-radius: 20px;
    z-index: -1;
    filter: blur(10px);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.glow-border:hover::before {
    opacity: 0.7;
}

/* Tech stats counter */
.tech-stats {
    display: flex;
    justify-content: space-around;
    margin: 4rem 0;
    flex-wrap: wrap;
    gap: 2rem;
}

.stat-item {
    text-align: center;
    padding: 1rem;
}

.stat-number {
    font-size: 3rem;
    font-weight: 900;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: block;
    line-height: 1;
}

.stat-label {
    color: var(--gray-text);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 0.5rem;
}

/* Loading animation */
.loading-bar {
    width: 100%;
    height: 4px;
    background: rgba(0, 212, 255, 0.2);
    border-radius: 2px;
    overflow: hidden;
    margin: 1rem 0;
}

.loading-progress {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    border-radius: 2px;
    animation: loading 2s ease-in-out infinite;
}

@keyframes loading {
    0% { width: 0%; }
    50% { width: 100%; }
    100% { width: 0%; }
}

/* Floating action elements */
.floating-tech {
    position: absolute;
    font-family: var(--font-mono);
    color: var(--primary-color);
    font-size: 0.8rem;
    opacity: 0.6;
    animation: floatTech 8s ease-in-out infinite;
    pointer-events: none;
}

@keyframes floatTech {
    0%, 100% { 
        transform: translateY(0px) rotate(0deg);
        opacity: 0.6;
    }
    25% { 
        transform: translateY(-20px) rotate(90deg);
        opacity: 1;
    }
    50% { 
        transform: translateY(-10px) rotate(180deg);
        opacity: 0.8;
    }
    75% { 
        transform: translateY(-30px) rotate(270deg);
        opacity: 1;
    }
}

/* Tech skill badges */
.tech-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
    margin: 2rem 0;
}

.tech-badge {
    background: rgba(0, 212, 255, 0.1);
    border: 1px solid var(--primary-color);
    border-radius: 25px;
    padding: 0.5rem 1rem;
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--primary-color);
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

.tech-badge::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(0, 212, 255, 0.3), transparent);
    transition: left 0.5s;
}

.tech-badge:hover::before {
    left: 100%;
}

.tech-badge:hover {
    background: rgba(0, 212, 255, 0.2);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 212, 255, 0.3);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .tech-stats {
        flex-direction: column;
        gap: 1rem;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    .tech-badges {
        gap: 0.5rem;
    }
    
    .tech-badge {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
    }
}
