/* 
 * JotaCDigital - Custom Styles
 * Estilos adicionais e overrides
 */

/* Additional animations */
@keyframes glitch {
    0% {
        text-shadow: 0.05em 0 0 rgba(0, 243, 255, 0.75),
                    -0.05em -0.025em 0 rgba(191, 0, 255, 0.75);
    }
    14% {
        text-shadow: 0.05em 0 0 rgba(0, 243, 255, 0.75),
                    -0.05em -0.025em 0 rgba(191, 0, 255, 0.75);
    }
    15% {
        text-shadow: -0.05em -0.025em 0 rgba(0, 243, 255, 0.75),
                    0.05em 0.025em 0 rgba(191, 0, 255, 0.75);
    }
    49% {
        text-shadow: -0.05em -0.025em 0 rgba(0, 243, 255, 0.75),
                    0.05em 0.025em 0 rgba(191, 0, 255, 0.75);
    }
    50% {
        text-shadow: 0.05em 0.025em 0 rgba(0, 243, 255, 0.75),
                    -0.05em -0.05em 0 rgba(191, 0, 255, 0.75);
    }
    99% {
        text-shadow: 0.05em 0.025em 0 rgba(0, 243, 255, 0.75),
                    -0.05em -0.05em 0 rgba(191, 0, 255, 0.75);
    }
    100% {
        text-shadow: -0.05em 0 0 rgba(0, 243, 255, 0.75),
                    -0.025em -0.05em 0 rgba(191, 0, 255, 0.75);
    }
}

/* Particle effect for background */
.particle {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
}

/* Loading spinner */
.loader {
    border: 3px solid rgba(0, 243, 255, 0.1);
    border-top: 3px solid var(--neon-blue);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Tooltip */
.tooltip {
    position: relative;
    display: inline-block;
}

.tooltip .tooltiptext {
    visibility: hidden;
    background-color: rgba(0, 243, 255, 0.9);
    color: #000;
    text-align: center;
    border-radius: 6px;
    padding: 5px 10px;
    position: absolute;
    z-index: 1;
    bottom: 125%;
    left: 50%;
    margin-left: -60px;
    opacity: 0;
    transition: opacity 0.3s;
    font-size: 12px;
}

.tooltip:hover .tooltiptext {
    visibility: visible;
    opacity: 1;
}

/* Custom checkbox */
.custom-checkbox {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.custom-checkbox input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255, 255, 255, 0.1);
    transition: 0.4s;
    border-radius: 24px;
    border: 1px solid var(--neon-blue);
}

.slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 4px;
    bottom: 3px;
    background: linear-gradient(135deg, var(--neon-blue), var(--neon-purple));
    transition: 0.4s;
    border-radius: 50%;
}

input:checked + .slider {
    background: linear-gradient(135deg, var(--neon-blue), var(--neon-purple));
}

input:checked + .slider:before {
    transform: translateX(26px);
}

/* Ripple effect */
.ripple {
    position: relative;
    overflow: hidden;
}

.ripple:after {
    content: "";
    display: block;
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    pointer-events: none;
    background-image: radial-gradient(circle, var(--neon-blue) 10%, transparent 10.01%);
    background-repeat: no-repeat;
    background-position: 50%;
    transform: scale(10, 10);
    opacity: 0;
    transition: transform 0.5s, opacity 1s;
}

.ripple:active:after {
    transform: scale(0, 0);
    opacity: 0.3;
    transition: 0s;
}

/* Print styles */
@media print {
    .header-glass,
    .chat-widget,
    .cyber-grid {
        display: none !important;
    }
}

/* Accessibility improvements */
.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;
}

/* Focus styles for accessibility */
a:focus,
button:focus,
input:focus,
textarea:focus {
    outline: 2px solid var(--neon-blue);
    outline-offset: 2px;
}

/* Reduce motion for users who prefer it */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
