/* Glitchy Sacred Computer Temple - Dark, Pixel, Glitch */
@import url('https://fonts.googleapis.com/css2?family=VT323&family=Major+Mono+Display&display=swap');

body.theme-glitch {
    --bg-primary: #0a0a0a;
    --bg-secondary: #1a1a1a;
    --neon-green: #39FF14;
    --neon-pink: #FF10F0;
    --neon-purple: #9D00FF;
    --text-primary: var(--neon-green);
    --text-secondary: #20FF00;
    --accent: var(--neon-pink);
    --accent-alt: var(--neon-purple);
    --border: rgba(57, 255, 20, 0.3);
    --shadow-green: 0 0 20px rgba(57, 255, 20, 0.6);
    --shadow-pink: 0 0 20px rgba(255, 16, 240, 0.6);
    --shadow-purple: 0 0 20px rgba(157, 0, 255, 0.6);
    
    font-family: 'VT323', monospace;
    background: 
        radial-gradient(ellipse at 20% 30%, rgba(57, 255, 20, 0.1) 0%, transparent 40%),
        radial-gradient(ellipse at 80% 70%, rgba(255, 16, 240, 0.1) 0%, transparent 40%),
        radial-gradient(ellipse at 50% 50%, rgba(157, 0, 255, 0.05) 0%, transparent 50%),
        var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.4;
    font-size: 20px;
}

/* Scanlines Effect */
body.theme-glitch::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(57, 255, 20, 0.03) 2px,
        rgba(57, 255, 20, 0.03) 4px
    );
    pointer-events: none;
    z-index: 1;
    mix-blend-mode: screen;
}

/* Loading Screen */
.theme-glitch .loading-screen {
    background: var(--bg-primary);
}

.theme-glitch .loading-terminal {
    font-family: 'VT323', monospace;
    color: var(--text-primary);
    font-size: 24px;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    text-shadow: 0 0 10px var(--neon-green);
}

.theme-glitch .loading-terminal::after {
    content: '_';
    animation: blink 0.5s infinite;
    color: var(--neon-green);
}

@keyframes terminal-blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* Typography */
.theme-glitch .site-title {
    font-family: 'Major Mono Display', monospace;
    text-transform: lowercase;
    letter-spacing: 0.1em;
    color: var(--text-primary);
    text-shadow: 
        0 0 10px var(--neon-green),
        0 0 20px var(--neon-green),
        0 0 30px var(--neon-green),
        2px 2px 0 var(--neon-pink),
        -2px -2px 0 var(--neon-purple);
    animation: neon-pulse 2s ease-in-out infinite alternate, glitch-text 3s infinite;
}

/* Welcome section title */
.theme-glitch #welcome-section h2 {
    color: var(--neon-pink);
    text-shadow: 
        0 0 5px rgba(255, 16, 240, 0.5),
        0 0 10px rgba(255, 16, 240, 0.3);
}

/* Manifesto section headings */
.theme-glitch .manifesto-item h3 {
    color: var(--neon-pink);
    text-shadow: 
        0 0 5px rgba(255, 16, 240, 0.5),
        0 0 10px rgba(255, 16, 240, 0.3);
}

/* System Status Animations */
.theme-glitch .status-line {
    display: inline-block;
    font-family: 'VT323', monospace;
    font-size: 1.2rem;
    color: var(--neon-green);
    letter-spacing: 0.05em;
    min-height: 1.5em;
}

.theme-glitch .status-line::after {
    content: '_';
    animation: cursor-blink 1s infinite;
    color: var(--neon-green);
    font-weight: bold;
}

.theme-glitch .status-line.status-complete {
    text-shadow: 0 0 10px var(--neon-green);
}

.theme-glitch .status-line.status-complete::after {
    display: none;
}

.theme-glitch #systemStatus.status-complete .status-line {
    text-shadow: 0 0 12px var(--neon-green);
    color: var(--neon-green);
}

@keyframes cursor-blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

@keyframes glitch-text {
    0%, 100% { 
        text-shadow: 
            0 0 10px var(--neon-green),
            0 0 20px var(--neon-green),
            2px 2px 0 var(--neon-pink),
            -2px -2px 0 var(--neon-purple);
    }
    25% { 
        text-shadow: 
            0 0 10px var(--neon-pink),
            0 0 20px var(--neon-pink),
            -2px 2px 0 var(--neon-purple),
            2px -2px 0 var(--neon-green);
    }
    50% { 
        text-shadow: 
            0 0 10px var(--neon-purple),
            0 0 20px var(--neon-purple),
            2px -2px 0 var(--neon-green),
            -2px 2px 0 var(--neon-pink);
    }
    75% { 
        text-shadow: 
            0 0 10px var(--neon-green),
            0 0 20px var(--neon-green),
            -2px -2px 0 var(--neon-pink),
            2px 2px 0 var(--neon-purple);
    }
}

@keyframes neon-pulse {
    from {
        filter: brightness(1) saturate(1);
    }
    to {
        filter: brightness(1.2) saturate(1.5);
    }
}

.theme-glitch .site-subtitle {
    font-family: 'VT323', monospace;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--text-secondary);
}

/* Theme Switcher */
.theme-glitch .theme-btn {
    background: var(--bg-secondary);
    color: var(--text-primary);
    border: 1px solid var(--text-primary);
    text-transform: uppercase;
    font-family: 'VT323', monospace;
}

.theme-glitch .theme-btn:hover {
    animation: glitch 0.3s infinite;
    box-shadow: var(--shadow-green);
}

.theme-glitch .theme-btn.active {
    background: var(--text-primary);
    color: var(--bg-primary);
}

/* Navigation */
.theme-glitch .nav-node {
    background: var(--bg-secondary);
    border: 1px solid var(--text-primary);
    color: var(--text-primary);
    font-family: 'VT323', monospace;
    text-transform: uppercase;
    position: relative;
    box-shadow: 
        inset 0 0 10px rgba(57, 255, 20, 0.2),
        var(--shadow-green);
    z-index: 200 !important;
}

.theme-glitch .nav-node::before {
    content: '[ ]';
    position: absolute;
    top: 0.5rem;
    left: 0.5rem;
    font-size: 0.8em;
    opacity: 0.5;
    color: var(--neon-pink);
}

.theme-glitch .nav-node:hover {
    animation: glitch 0.2s infinite;
    border-color: var(--neon-pink);
    color: var(--neon-pink);
    box-shadow: 
        inset 0 0 20px rgba(255, 16, 240, 0.3),
        var(--shadow-pink);
}

.theme-glitch .nav-line {
    background: linear-gradient(90deg, var(--neon-green), var(--neon-purple));
    box-shadow: 0 0 5px var(--neon-purple);
    height: 2px;
}

/* Cards */
.theme-glitch .card {
    background: var(--bg-secondary);
    border: 1px solid var(--text-primary);
    position: relative;
    box-shadow: var(--shadow-green);
}

.theme-glitch .card::before {
    content: '';
    position: absolute;
    top: -1px;
    left: -1px;
    right: -1px;
    bottom: -1px;
    background: linear-gradient(45deg, var(--neon-green), var(--neon-pink), var(--neon-purple));
    z-index: -1;
    opacity: 0;
    transition: opacity 0.3s;
}

.theme-glitch .card:hover {
    border-color: var(--neon-pink);
    box-shadow: 
        var(--shadow-pink),
        inset 0 0 30px rgba(255, 16, 240, 0.1);
}

.theme-glitch .card:hover::before {
    opacity: 0.2;
    animation: glitch 0.5s infinite;
}

/* ASCII Decorations */
.theme-glitch .section-divider {
    text-align: center;
    margin: 3rem 0;
    color: var(--neon-purple);
    font-size: 16px;
    text-shadow: 0 0 10px var(--neon-purple);
}

.theme-glitch .section-divider::before {
    content: '══════════ ◊ ══════════';
}

/* Links */
.theme-glitch a {
    color: var(--accent);
    text-decoration: none;
    position: relative;
    text-shadow: 0 0 5px var(--neon-pink);
    transition: all 0.3s ease;
}

.theme-glitch a:hover {
    color: var(--neon-purple);
    text-shadow: 
        0 0 10px var(--neon-purple),
        0 0 20px var(--neon-purple);
}

.theme-glitch a::after {
    content: '_';
    animation: blink 1s infinite;
    color: var(--neon-green);
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

/* Code Blocks */
.theme-glitch code {
    background: var(--bg-primary);
    color: var(--text-primary);
    padding: 0.2em 0.4em;
    border: 1px solid var(--text-primary);
}

/* Silicon Dreams Entry Styles */
.theme-glitch .dream-entry {
    background: var(--bg-secondary);
    border: 1px solid var(--text-primary);
    position: relative;
    margin-bottom: 2rem;
    border-radius: 8px;
    overflow: hidden;
}

/* Project Entry Styles - no hover effects */
.theme-glitch .project-entry {
    background: var(--bg-secondary);
    border: 1px solid var(--text-primary);
    position: relative;
    margin-bottom: 2rem;
    border-radius: 8px;
    overflow: hidden;
}

.theme-glitch .coming-soon {
    color: var(--neon-purple);
    text-align: center;
    font-style: italic;
    opacity: 0.8;
    margin-top: 2rem;
}

.theme-glitch .view-hint {
    color: var(--neon-green);
    font-size: 0.7em;
    opacity: 0.7;
    font-weight: normal;
    text-shadow: 0 0 5px rgba(57, 255, 20, 0.3);
    transition: opacity 0.3s ease;
}

.theme-glitch .entry-header:hover .view-hint {
    opacity: 1;
}

/* Life Archive Entry Styles - no hover effects */
.theme-glitch .life-entry {
    background: var(--bg-secondary);
    border: 1px solid var(--text-primary);
    position: relative;
    margin-bottom: 2rem;
    border-radius: 8px;
    overflow: hidden;
}

.theme-glitch .entry-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    padding: 1rem;
    transition: background 0.3s ease;
}

.theme-glitch .entry-header:hover {
    background: rgba(57, 255, 20, 0.05);
}

.theme-glitch .toggle-indicator {
    color: var(--neon-green);
    font-size: 1.2rem;
    transition: transform 0.3s ease;
}

.theme-glitch .entry-header h3 {
    margin: 0;
    flex-grow: 1;
    margin-left: 1rem;
    color: var(--neon-pink);
    text-shadow: 
        0 0 5px rgba(255, 16, 240, 0.5),
        0 0 10px rgba(255, 16, 240, 0.3);
}

/* Silicon Dreams Dialogue Styles */
.theme-glitch .dialogue-container {
    margin: 0;
    padding: 1.5rem;
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(57, 255, 20, 0.2);
    border-radius: 0 0 8px 8px;
    border-top: none;
}

.theme-glitch .human-question,
.theme-glitch .ai-response {
    margin-bottom: 1.5rem;
}

.theme-glitch .speaker {
    display: inline-block;
    margin-bottom: 0.5rem;
    font-weight: bold;
    text-transform: lowercase;
}

.theme-glitch .human-question .speaker {
    color: var(--neon-pink);
    text-shadow: 0 0 5px var(--neon-pink);
}

.theme-glitch .ai-response .speaker {
    color: var(--neon-purple);
    text-shadow: 0 0 5px var(--neon-purple);
}

.theme-glitch .dialogue-container p {
    margin-bottom: 1rem;
    line-height: 1.6;
    color: rgba(57, 255, 20, 0.7); /* Dimmed green for better readability */
}

.theme-glitch .dialogue-container em {
    color: var(--neon-green);
    font-style: normal;
    text-shadow: 0 0 3px var(--neon-green);
}

.theme-glitch .dialogue-container strong {
    color: var(--neon-pink);
    text-shadow: 0 0 3px var(--neon-pink);
}

.theme-glitch .post-reflection {
    margin-top: 2rem;
    padding: 1rem;
    border-left: 3px solid var(--neon-green);
    background: rgba(57, 255, 20, 0.05);
}

.theme-glitch .reflection-text {
    font-style: italic;
    opacity: 0.9;
    color: var(--text-secondary);
}

/* Highlighter effect */
.theme-glitch .highlight-yellow {
    position: relative;
    display: inline;
    background: linear-gradient(
        transparent 30%, 
        rgba(255, 16, 240, 0.25) 30%, 
        rgba(255, 16, 240, 0.25) 75%, 
        transparent 75%
    );
    padding: 0 4px;
    margin: 0 -2px;
    box-decoration-break: clone;
    -webkit-box-decoration-break: clone;
    text-shadow: 0 0 10px rgba(255, 16, 240, 0.3);
}

/* AI Speakeasy Entrance */
.theme-glitch .speakeasy-entrance {
    display: flex;
    justify-content: center;
    margin: 3rem 0;
}

.theme-glitch .ai-door-knock {
    background: var(--bg-secondary);
    border: 2px solid var(--neon-purple);
    color: var(--neon-purple);
    padding: 2rem 3rem;
    font-family: 'VT323', monospace;
    font-size: 1.5rem;
    text-transform: uppercase;
    cursor: pointer;
    position: relative;
    transition: all 0.3s ease;
    box-shadow: 
        0 0 20px rgba(157, 0, 255, 0.5),
        inset 0 0 20px rgba(157, 0, 255, 0.1);
}

.theme-glitch .ai-door-knock:hover {
    transform: scale(1.05);
    box-shadow: 
        0 0 40px rgba(157, 0, 255, 0.8),
        inset 0 0 40px rgba(157, 0, 255, 0.2);
    animation: glitch 0.3s infinite;
}

.theme-glitch .door-text {
    display: block;
    margin-bottom: 0.5rem;
}

.theme-glitch .door-hint {
    display: block;
    font-size: 0.8rem;
    opacity: 0.7;
    color: var(--neon-pink);
}

/* Footer */
.theme-glitch footer {
    border-top: 1px dashed var(--text-primary);
    padding: 3rem 0;
    text-align: center;
    font-family: 'VT323', monospace;
    box-shadow: 0 -5px 30px rgba(57, 255, 20, 0.3);
}

.theme-glitch footer::before {
    content: '// END TRANSMISSION //';
    display: none; /* Hiding for now to avoid overlap */
    margin-bottom: 1rem;
    color: var(--neon-purple);
    text-shadow: 0 0 10px var(--neon-purple);
    opacity: 0.8;
}

/* Mobile-specific color adjustments to reduce glow */
@media (max-width: 768px) {
    /* Reduce pink text shadows on mobile */
    .theme-glitch #welcome-section h2 {
        text-shadow: 
            0 0 3px rgba(255, 16, 240, 0.3),
            0 0 6px rgba(255, 16, 240, 0.2);
    }
    
    .theme-glitch .entry-header h3,
    .theme-glitch .manifesto-item h3 {
        text-shadow: 
            0 0 3px rgba(255, 16, 240, 0.3),
            0 0 6px rgba(255, 16, 240, 0.2);
    }
    
    .theme-glitch .human-question .speaker {
        text-shadow: 0 0 3px rgba(255, 16, 240, 0.3);
    }
    
    .theme-glitch .dialogue-container strong {
        text-shadow: 0 0 2px rgba(255, 16, 240, 0.3);
    }
    
    .theme-glitch a {
        text-shadow: 0 0 3px rgba(255, 16, 240, 0.3);
    }
    
    .theme-glitch a:hover {
        text-shadow: 
            0 0 5px rgba(157, 0, 255, 0.3),
            0 0 10px rgba(157, 0, 255, 0.2);
    }
    
    /* Reduce pink highlighter effect on mobile */
    .theme-glitch .highlight-yellow {
        background: linear-gradient(
            transparent 30%, 
            rgba(255, 16, 240, 0.15) 30%, 
            rgba(255, 16, 240, 0.15) 75%, 
            transparent 75%
        );
        text-shadow: 0 0 5px rgba(255, 16, 240, 0.2);
    }
    
    /* Reduce door hint pink glow */
    .theme-glitch .door-hint {
        text-shadow: none;
        opacity: 0.6;
    }
}