/* Cyan glitch — projede textem, žádná červená */
.glitch-title,
.glitch-pass { position: relative; display: inline-block; }

.glitch-title::after,
.glitch-pass::after {
    content: none !important;
    animation: none !important;
    color: transparent !important;
}

.section-heading.glitch-title::after,
.section-heading.glitch-pass::after {
    content: '' !important;
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 60%;
    height: 2px;
    background: linear-gradient(90deg, var(--cyan), transparent);
    box-shadow: 0 0 10px var(--cyan-dim);
    color: transparent !important;
    clip-path: none !important;
    transform: none !important;
    opacity: 1 !important;
    -webkit-text-fill-color: transparent !important;
    animation: none !important;
}

/* SERVERY: čára doprostřed, mizí na obě strany */
.header-main.glitch-title::after,
.header-main.glitch-pass::after {
    content: '' !important;
    position: absolute;
    left: 50%;
    bottom: -8px;
    width: 72%;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--cyan), transparent);
    box-shadow: 0 0 12px var(--cyan-dim);
    color: transparent !important;
    clip-path: none !important;
    transform: translateX(-50%) !important;
    opacity: 1 !important;
    -webkit-text-fill-color: transparent !important;
    animation: none !important;
}

.glitch-title::before,
.glitch-pass::before {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    font-family: inherit;
    font-size: inherit;
    font-weight: inherit;
    letter-spacing: inherit;
    line-height: inherit;
    text-transform: inherit;
    white-space: pre-line;
    text-shadow: none;
    color: var(--cyan);
    background: none !important;
    -webkit-background-clip: border-box !important;
    background-clip: border-box !important;
    -webkit-text-fill-color: var(--cyan) !important;
    pointer-events: none;
    animation-name: inqer-glitch-pass;
    animation-duration: var(--glitch-dur, 5.5s);
    animation-timing-function: linear;
    animation-delay: var(--glitch-delay, 0s);
    animation-iteration-count: infinite;
    animation-fill-mode: both;
}

@keyframes inqer-glitch-pass {
    0%, 76%, 100% {
        clip-path: inset(0 0 100% 0);
        opacity: 0;
        transform: translateX(0);
    }
    80% {
        clip-path: inset(0 0 65% 0);
        opacity: 0.95;
        transform: translateX(-0.08em);
    }
    84% {
        clip-path: inset(20% 0 40% 0);
        opacity: 1;
        transform: translateX(0.1em);
    }
    88% {
        clip-path: inset(45% 0 20% 0);
        opacity: 0.95;
        transform: translateX(-0.07em);
    }
    92% {
        clip-path: inset(70% 0 0 0);
        opacity: 0.75;
        transform: translateX(0.05em);
    }
}

@media (prefers-reduced-motion: reduce) {
    .glitch-title::before,
    .glitch-pass::before { animation: none; opacity: 0; }
}
