/**
 * Fabric Plexus - Quantum Highlighter CSS
 * Styles for the quantum-inspired code highlighter
 */

/* Main container */
.quantum-code-container {
    position: relative;
    margin: 1.5rem 0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

/* Code highlighting base */
.quantum-code {
    font-family: 'Fira Code', 'JetBrains Mono', 'Consolas', monospace;
    font-size: 14px;
    line-height: 1.5;
    tab-size: 4;
    border-radius: 8px;
    overflow: auto;
}

.quantum-code pre {
    margin: 0;
    padding: 1.25rem 0 1.25rem 3.5rem;
    overflow: auto;
    position: relative;
}

.quantum-code .code-line {
    display: block;
    min-height: 1.5em;
    padding: 0 1.25rem 0 0;
}

/* Line numbers */
.quantum-code .line-numbers {
    position: absolute;
    top: 1.25rem;
    left: 0;
    width: 3rem;
    text-align: right;
    padding-right: 0.75rem;
    user-select: none;
    border-right: 1px solid rgba(255, 255, 255, 0.1);
}

.quantum-code.quantum-light .line-numbers {
    border-right: 1px solid rgba(0, 0, 0, 0.1);
}

.quantum-code .line-numbers span {
    display: block;
    font-size: 12px;
    opacity: 0.6;
    line-height: 1.5;
}

/* Dark theme */
.quantum-code.quantum-dark {
    color: #f8f8f2;
}

.quantum-code.quantum-dark pre {
    background-color: #1a2233;
}

/* Light theme */
.quantum-code.quantum-light {
    color: #24292e;
}

.quantum-code.quantum-light pre {
    background-color: #f5f5f7;
}

/* Token styles with quantum animations */
.quantum-code .token {
    display: inline;
    transition: all 0.3s ease;
    position: relative;
    z-index: 1;
}

/* Hover effect for tokens */
.quantum-code .token:hover {
    animation-duration: 0.5s !important;
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.4);
    transform: scale(1.05);
    z-index: 2;
}

.quantum-code.quantum-light .token:hover {
    text-shadow: 0 0 8px rgba(0, 0, 0, 0.3);
}

/* Quantum pulse animation */
@keyframes quantumPulse {
    0% {
        color: var(--start-color);
    }
    50% {
        color: var(--end-color);
    }
    100% {
        color: var(--start-color);
    }
}

/* Special effects for hover */
.quantum-code .token.function:hover,
.quantum-code .token.keyword:hover {
    font-weight: bold;
}

/* Responsive styles */
@media (max-width: 640px) {
    .quantum-code {
        font-size: 12px;
    }
    
    .quantum-code pre {
        padding-left: 3rem;
    }
    
    .quantum-code .line-numbers {
        width: 2.5rem;
    }
}