/* Text Rotator Animation Styles */
.text-rotator {
    display: inline-block;
    position: relative;
    width: max-content;
    min-width: 200px;
    /* Fallback untuk browser lama */
    min-height: 1.5em;
    vertical-align: bottom;
    white-space: nowrap;
}

/* Responsive untuk mobile */
@media (max-width: 768px) {
    .text-rotator {
        width: max-content;
        min-width: 180px;
    }
}

.text-rotator-word {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
    animation: textRotate 8s infinite;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.text-rotator-word:nth-child(1) {
    animation-delay: 0s;
}

.text-rotator-word:nth-child(2) {
    animation-delay: 2s;
}

.text-rotator-word:nth-child(3) {
    animation-delay: 4s;
}

.text-rotator-word:nth-child(4) {
    animation-delay: 6s;
}

@keyframes textRotate {

    0%,
    20% {
        opacity: 1;
        transform: translateY(0);
    }

    25%,
    100% {
        opacity: 0;
        transform: translateY(-100%);
    }
}