/* running-text.css */
.paratypewr-container {
    font-family: monospace;
    font-size: 20px;
    line-height: 1.6;
    min-height: 200px;
    padding: 20px;
    background-color: #f9f9f9;
    border-radius: 5px;
    margin: 20px 0;
}

.paratypewr-animation {
    white-space: pre-line;
    font-size: inherit;
    line-height: inherit;
    font-family: inherit;
    min-height: 200px;
    padding: 20px;
    border-radius: 5px;
    margin: 20px 0;
    position: relative;
}

/* Улучшенные стили для эффектов */
.paratypewr-animation.glow-effect {
    background: radial-gradient(ellipse at center, rgba(255,255,255,0.3) 0%, rgba(255,255,255,0) 70%);
}

.paratypewr-animation.vibration-effect span {
    display: inline-block;
    animation: vibration 0.1s infinite;
}

@keyframes vibration {
    0%, 100% { transform: translate(0, 0); }
    25% { transform: translate(-1px, -1px); }
    50% { transform: translate(1px, 1px); }
    75% { transform: translate(-1px, 1px); }
}

.paratypewr-animation.strong-effect span {
    animation: strongVibration 0.1s infinite;
}

@keyframes strongVibration {
    0%, 100% { transform: translate(0, 0) rotate(0deg); }
    25% { transform: translate(-2px, -2px) rotate(-1deg); }
    50% { transform: translate(2px, 2px) rotate(1deg); }
    75% { transform: translate(-2px, 2px) rotate(1deg); }
}

.paratypewr-animation.glow-effect span {
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.8);
    transition: all 0.3s ease;
}

.paratypewr-animation.strong-glow span {
    text-shadow: 0 0 15px rgba(255, 215, 0, 0.9);
}

.paratypewr-container p,
.paratypewr-animation p {
    margin-bottom: 1em;
    line-height: 1.6;
}

.paratypewr-container br,
.paratypewr-animation br {
    display: block;
    content: "";
    margin-bottom: 1em;
}

@keyframes paratypewr-blink {
    50% { opacity: 0; }
}

.paratypewr-cursor {
    display: inline-block;
    width: 2px;
    height: 24px;
    background-color: #000;
    vertical-align: middle;
    animation: paratypewr-blink 0.7s infinite;
    margin-left: 2px;
    position: relative;
    z-index: 10;
    will-change: opacity; /* Оптимизация анимации */
    contain: content;
}

/* Эффект мерцания для курсора */
.paratypewr-cursor::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    animation: pulse 1.5s infinite;
    opacity: 0;
}

@keyframes pulse {
    0% { transform: scale(0.8); opacity: 0; }
    50% { transform: scale(1.2); opacity: 0.4; }
    100% { transform: scale(1.5); opacity: 0; }
}
/* Эффекты вибрации */
@keyframes paratypewr-vibration {
    0%, 100% { transform: translate(0, 0); }
    25% { transform: translate(-1px, -1px); }
    50% { transform: translate(1px, 1px); }
    75% { transform: translate(-1px, 1px); }
}

/* Эффекты свечения */
.paratypewr-glow-subtle .paratypewr-char {
    text-shadow: 0 0 4px rgba(255, 255, 255, 0.4);
}
.paratypewr-glow-medium .paratypewr-char {
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.7);
}
.paratypewr-glow-strong .paratypewr-char {
    text-shadow: 0 0 12px rgba(255, 215, 0, 0.9);
    animation: paratypewr-pulse 1.5s infinite;
}

@keyframes paratypewr-pulse {
    0% { opacity: 0.8; }
    50% { opacity: 1; }
    100% { opacity: 0.8; }
}



/* Киберпанк эффекты */
.paratypewr-cyberpunk {
    position: relative;
    overflow: hidden;
    background: linear-gradient(45deg, #000000, #001122, #000000) !important;
    border: 1px solid #00ff41 !important;
    box-shadow: 0 0 20px rgba(0, 255, 65, 0.3),
                inset 0 0 20px rgba(0, 255, 65, 0.1) !important;
}

.paratypewr-cyberpunk::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(transparent 90%, rgba(0, 255, 65, 0.1) 100%);
    background-size: 100% 4px;
    animation: cyber-rain 0.5s linear infinite;
    pointer-events: none;
    z-index: 1;
    opacity: 0.3;
}

@keyframes cyber-rain {
    0% { background-position: 0 0; }
    100% { background-position: 0 4px; }
}

.paratypewr-cyberpunk .paratypewr-char {
    color: #00ff41 !important;
    text-shadow: 0 0 5px #00ff41,
                 0 0 10px #00ff41,
                 0 0 15px #00ff41 !important;
    position: relative;
}

/* Эффект глитча */
.paratypewr-glitch {
    animation: glitch-effect 2s infinite alternate;
}

@keyframes glitch-effect {
    0%, 100% { transform: translate(0); }
    5% { transform: translate(-2px, 2px); }
    10% { transform: translate(2px, -2px); }
    15% { transform: translate(-2px, -2px); }
    20% { transform: translate(2px, 2px); }
    25% { transform: translate(0); }
}

/* Интенсивность эффектов */
.paratypewr-intensity-subtle::before { opacity: 0.1; }
.paratypewr-intensity-medium::before { opacity: 0.3; }
.paratypewr-intensity-strong::before { opacity: 0.5; }

.paratypewr-intensity-subtle .paratypewr-char {
    text-shadow: 0 0 3px #00ff41 !important;
}
.paratypewr-intensity-medium .paratypewr-char {
    text-shadow: 0 0 7px #00ff41, 0 0 10px #00ff41 !important;
}
.paratypewr-intensity-strong .paratypewr-char {
    text-shadow: 0 0 10px #00ff41, 0 0 15px #00ff41, 0 0 20px #00ff41 !important;
}

/* Специальный курсор для киберпанка */
.paratypewr-cyberpunk .paratypewr-cursor {
    background-color: #00ff41 !important;
    box-shadow: 0 0 10px #00ff41,
                0 0 20px #00ff41 !important;
    animation: cyber-blink 0.7s infinite,
               cyber-pulse 2s infinite !important;
}

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

@keyframes cyber-pulse {
    0%, 100% { box-shadow: 0 0 10px #00ff41, 0 0 20px #00ff41; }
    50% { box-shadow: 0 0 15px #00ff41, 0 0 30px #00ff41; }
}







/* Добавьте в running-text.css */
.paratypewr-effect-switcher {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.9);
    padding: 10px;
    border-radius: 12px;
    display: flex;
    gap: 8px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
}

.paratypewr-effect-switcher:hover {
    background: rgba(0, 0, 0, 0.95);
    transform: translateY(-2px);
}

.effect-btn {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: white;
    padding: 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 18px;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.effect-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.effect-btn.active {
    background: #0073aa;
    box-shadow: 0 0 15px rgba(0, 115, 170, 0.5);
    transform: scale(1.1);
}

.effect-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
}

.paratypewr-effect-switcher.loading {
    opacity: 0.7;
}

.paratypewr-effect-switcher.loading .effect-btn {
    cursor: wait;
}

/* Анимация пульсации для активной кнопки */
.effect-btn.active::after {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border-radius: 10px;
    border: 2px solid #0073aa;
    animation: pulseEffect 2s infinite;
}

@keyframes pulseEffect {
    0% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.05); }
    100% { opacity: 1; transform: scale(1); }
}

/* Адаптивность */
@media (max-width: 768px) {
    .paratypewr-effect-switcher {
        top: 10px;
        right: 10px;
        padding: 8px;
        gap: 6px;
    }

    .effect-btn {
        padding: 10px;
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
}

/* Сообщения */
.paratypewr-message {
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}


