/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --neon-cyan: #00ffff;
    --neon-magenta: #ff00ff;
    --neon-yellow: #ffff00;
    --neon-green: #00ff00;
    --dark-bg: #0a0a0a;
    --dark-card: #1a1a1a;
    --text-primary: #ffffff;
    --text-secondary: #cccccc;
}

/* Screen reader only class */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

body {
    font-family: 'Courier New', monospace;
    background-color: var(--dark-bg);
    color: var(--text-primary);
    overflow-x: hidden;
    position: relative;
    min-height: 100vh;
}

/* Animated Background Canvas */
#bg-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

/* Scanlines Effect */
.scanlines {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
    background: repeating-linear-gradient(
        0deg,
        rgba(0, 0, 0, 0.1) 0px,
        rgba(0, 0, 0, 0.1) 1px,
        transparent 1px,
        transparent 2px
    );
    animation: scanline 8s linear infinite;
}

@keyframes scanline {
    0% { transform: translateY(0); }
    100% { transform: translateY(100px); }
}

/* Container */
.container {
    position: relative;
    z-index: 2;
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
.header {
    text-align: center;
    padding: 60px 20px;
    margin-bottom: 40px;
}

.logo-container {
    position: relative;
}

.logo {
    font-size: 5rem;
    font-weight: 900;
    letter-spacing: 0.3rem;
    color: var(--neon-cyan);
    text-shadow: 
        0 0 10px var(--neon-cyan),
        0 0 20px var(--neon-cyan),
        0 0 30px var(--neon-cyan),
        0 0 40px var(--neon-magenta),
        0 0 70px var(--neon-magenta),
        0 0 80px var(--neon-magenta);
    animation: flicker 3s infinite alternate;
}

@keyframes flicker {
    0%, 18%, 22%, 25%, 53%, 57%, 100% {
        text-shadow: 
            0 0 10px var(--neon-cyan),
            0 0 20px var(--neon-cyan),
            0 0 30px var(--neon-cyan),
            0 0 40px var(--neon-magenta),
            0 0 70px var(--neon-magenta),
            0 0 80px var(--neon-magenta);
    }
    20%, 24%, 55% {
        text-shadow: none;
    }
}

/* Glitch Effect */
.glitch {
    position: relative;
}

.glitch::before,
.glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--dark-bg);
}

.glitch::before {
    animation: glitch-anim 2s infinite;
    clip-path: polygon(0 0, 100% 0, 100% 45%, 0 45%);
    transform: translate(-2px, -2px);
    opacity: 0.8;
}

.glitch::after {
    animation: glitch-anim 3s infinite reverse;
    clip-path: polygon(0 80%, 100% 20%, 100% 100%, 0 100%);
    transform: translate(2px, 2px);
    opacity: 0.8;
}

@keyframes glitch-anim {
    0% { clip-path: polygon(0 2%, 100% 2%, 100% 5%, 0 5%); }
    10% { clip-path: polygon(0 15%, 100% 15%, 100% 15%, 0 15%); }
    20% { clip-path: polygon(0 10%, 100% 10%, 100% 20%, 0 20%); }
    30% { clip-path: polygon(0 1%, 100% 1%, 100% 2%, 0 2%); }
    40% { clip-path: polygon(0 33%, 100% 33%, 100% 33%, 0 33%); }
    50% { clip-path: polygon(0 44%, 100% 44%, 100% 44%, 0 44%); }
    60% { clip-path: polygon(0 50%, 100% 50%, 100% 20%, 0 20%); }
    70% { clip-path: polygon(0 70%, 100% 70%, 100% 70%, 0 70%); }
    80% { clip-path: polygon(0 80%, 100% 80%, 100% 80%, 0 80%); }
    90% { clip-path: polygon(0 50%, 100% 50%, 100% 55%, 0 55%); }
    100% { clip-path: polygon(0 70%, 100% 70%, 100% 80%, 0 80%); }
}

.tagline {
    font-size: 1.5rem;
    color: var(--neon-yellow);
    letter-spacing: 0.5rem;
    margin-top: 20px;
    text-shadow: 0 0 10px var(--neon-yellow);
}

/* Main Content */
.main-content {
    padding: 20px;
}

/* Welcome Section */
.welcome-section {
    margin-bottom: 60px;
}

.welcome-box {
    background: linear-gradient(135deg, rgba(0, 255, 255, 0.1), rgba(255, 0, 255, 0.1));
    border: 2px solid var(--neon-cyan);
    border-radius: 10px;
    padding: 40px;
    box-shadow: 
        0 0 20px rgba(0, 255, 255, 0.3),
        inset 0 0 20px rgba(0, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.section-title {
    font-size: 2.5rem;
    color: var(--neon-cyan);
    text-shadow: 0 0 20px var(--neon-cyan);
    margin-bottom: 20px;
    text-align: center;
}

.welcome-text {
    font-size: 1.3rem;
    line-height: 1.8;
    text-align: center;
    color: var(--text-secondary);
}

/* Links Section */
.links-section {
    margin-bottom: 60px;
}

.links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.link-card {
    background: linear-gradient(135deg, rgba(26, 26, 26, 0.9), rgba(10, 10, 10, 0.9));
    border: 2px solid var(--neon-magenta);
    border-radius: 15px;
    padding: 40px 30px;
    text-align: center;
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 0 20px rgba(255, 0, 255, 0.2);
}

.link-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 0, 255, 0.3) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.link-card:hover::before {
    opacity: 1;
}

.link-card:hover {
    transform: translateY(-10px) scale(1.05);
    border-color: var(--neon-cyan);
    box-shadow: 
        0 0 30px rgba(0, 255, 255, 0.5),
        0 10px 40px rgba(255, 0, 255, 0.3);
}

.link-icon {
    font-size: 3rem;
    margin-bottom: 15px;
    filter: drop-shadow(0 0 10px var(--neon-magenta));
}

.link-card h3 {
    font-size: 1.8rem;
    color: var(--neon-cyan);
    margin-bottom: 10px;
    text-shadow: 0 0 10px var(--neon-cyan);
}

.link-card p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* Stats Section */
.stats-section {
    display: flex;
    justify-content: space-around;
    flex-wrap: wrap;
    gap: 30px;
    margin-bottom: 60px;
    padding: 40px 20px;
}

.stat-box {
    text-align: center;
    padding: 30px;
    background: rgba(26, 26, 26, 0.8);
    border: 2px solid var(--neon-green);
    border-radius: 10px;
    min-width: 200px;
    box-shadow: 0 0 20px rgba(0, 255, 0, 0.3);
    transition: all 0.3s ease;
}

.stat-box:hover {
    transform: scale(1.1);
    box-shadow: 0 0 30px rgba(0, 255, 0, 0.5);
}

.stat-number {
    font-size: 3rem;
    font-weight: 900;
    color: var(--neon-green);
    text-shadow: 0 0 20px var(--neon-green);
    margin-bottom: 10px;
}

.stat-label {
    font-size: 1.2rem;
    color: var(--text-secondary);
    letter-spacing: 0.2rem;
}

/* Footer */
.footer {
    text-align: center;
    padding: 40px 20px;
    border-top: 2px solid var(--neon-cyan);
    color: var(--text-secondary);
    background: rgba(10, 10, 10, 0.8);
}

/* Responsive Design */
@media (max-width: 768px) {
    .logo {
        font-size: 3rem;
    }
    
    .tagline {
        font-size: 1rem;
        letter-spacing: 0.3rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .links-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-section {
        flex-direction: column;
        align-items: center;
    }
}

@media (max-width: 480px) {
    .logo {
        font-size: 2rem;
        letter-spacing: 0.2rem;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
    
    .welcome-box {
        padding: 20px;
    }
    
    .welcome-text {
        font-size: 1rem;
    }
}

/* Accessibility: Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    .scanlines {
        animation: none !important;
    }
    
    .logo {
        animation: none !important;
    }
    
    .glitch::before,
    .glitch::after {
        animation: none !important;
    }
    
    .link-card {
        transition: none !important;
    }
    
    .stat-box {
        transition: none !important;
    }
}
