/* style.css */

/* Custom scrollbar for cyber aesthetic */
.cyber-scrollbar::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

.cyber-scrollbar::-webkit-scrollbar-track {
    background: #0f172a;
    /* cyber-base */
}

.cyber-scrollbar::-webkit-scrollbar-thumb {
    background: #334155;
    /* cyber-highlight */
    border-radius: 3px;
}

.cyber-scrollbar::-webkit-scrollbar-thumb:hover {
    background: #06b6d4;
    /* cyber-cyan */
}

/* Neon Box and Glow effects */
.neon-box {
    box-shadow: 0 0 10px rgba(6, 182, 212, 0.2),
        inset 0 0 10px rgba(6, 182, 212, 0.1);
}

.glitch-text {
    text-shadow: 2px 0 #f43f5e, -2px 0 #06b6d4;
    animation: glitch 2s infinite linear alternate-reverse;
}

/* Range Slider Styling (Caesar Rotor) */
.rotor-slider {
    -webkit-appearance: none;
    outline: none;
}

.rotor-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #0f172a;
    border: 2px solid #06b6d4;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(6, 182, 212, 0.8);
    transition: transform 0.1s;
}

.rotor-slider::-webkit-slider-thumb:hover {
    transform: scale(1.2);
    box-shadow: 0 0 15px rgba(6, 182, 212, 1);
}

.rotor-slider::-moz-range-thumb {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #0f172a;
    border: 2px solid #06b6d4;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(6, 182, 212, 0.8);
}

/* Character spans in Frequency Text */
.cipher-char {
    display: inline-block;
    min-width: 1ch;
    transition: all 0.2s ease;
    border-bottom: 2px solid transparent;
    cursor: pointer;
}

.cipher-char:hover {
    color: white;
    background: rgba(16, 185, 129, 0.2);
    /* emerald hover */
}

.cipher-char.highlight {
    background: rgba(16, 185, 129, 0.3);
    border-color: #10b981;
}

.cipher-char.replaced {
    color: #10b981;
    /* emerald */
    font-weight: bold;
    text-shadow: 0 0 8px rgba(16, 185, 129, 0.4);
}

/* Matrix Input Styling */
.matrix-input {
    text-align: center;
    text-transform: uppercase;
}

.matrix-input:focus {
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
    /* emerald glow */
}

/* Bit animation for XOR */
.bit-box {
    width: 28px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #334155;
    background: #1e293b;
    border-radius: 4px;
    transition: all 0.3s;
}

.bit-box.active-1 {
    color: white;
    text-shadow: 0 0 8px currentColor;
    border-color: currentColor;
    background: rgba(255, 255, 255, 0.1);
}

/* Animation Utilities */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.3s ease-out forwards;
}