﻿/* Tam ekran overlay stilini ayarla */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.5);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    flex-direction: column;
    touch-action: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

.loader {
    width: 40px;
    height: 20px;
    background: currentColor;
    border-radius: 50% 50% 0 0;
    position: relative;
    display: block;
    margin: 40px auto 0;
    box-sizing: border-box;
    animation: animloader 4s linear infinite, colorCycle 5s linear infinite;
    color: red;
    will-change: transform, box-shadow;
    transform: translateZ(0);
}

    .loader::after {
        content: '';
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
        width: 24px;
        height: 24px;
        border-radius: 50%;
        background: currentColor;
        top: -30px;
        box-sizing: border-box;
        animation: animloader1 4s linear infinite;
    }

.loading-strong {
    font-size: 14px;
    color: white;
    max-width: 250px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-align: center;
    margin-top: 20px;
    margin-left: -10px;
}

.containerLoading {
    padding: 20px;
}

@keyframes colorCycle {
    0% {
        color: red;
    }

    25% {
        color: orange;
    }

    50% {
        color: limegreen;
    }

    75% {
        color: dodgerblue;
    }

    100% {
        color: red;
    }
}

@keyframes animloader {
    0% {
        box-shadow: 0 0 0 -2px, 0 0 0 -2px, 0 0 0 -5px, 0 0 0 -5px;
    }

    20% {
        box-shadow: 40px -1px 0 -2px, 0 0 0 -2px, 40px -1px 0 -5px, 0 0 0 -5px;
    }

    40% {
        box-shadow: 40px -1px 0 -2px, -40px -1px 0 -2px, 40px -1px 0 -5px, -40px -1px 0 -5px;
    }

    60% {
        box-shadow: 40px -1px 0 -2px, -40px -1px 0 -2px, 23px -29px 0 -5px, -40px -1px 0 -5px;
    }

    80%, 95% {
        box-shadow: 40px -1px 0 -2px, -40px -1px 0 -2px, 23px -29px 0 -5px, -23px -29px 0 -5px;
    }

    100% {
        box-shadow: 40px -1px 0 -2px rgba(255, 255, 255, 0), -40px -1px 0 -2px rgba(255, 255, 255, 0), 23px -29px 0 -5px rgba(255, 255, 255, 0), -23px -29px 0 -5px rgba(255, 255, 255, 0);
    }
}

@keyframes animloader1 {
    0% {
        box-shadow: 0 0 0 -2px, 0 0 0 -2px, 0 0 0 -5px, 0 0 0 -5px;
    }

    20% {
        box-shadow: 40px 2px 0 -2px, 0 0 0 -2px, 40px 2px 0 -5px, 0 0 0 -5px;
    }

    40% {
        box-shadow: 40px 2px 0 -2px, -40px 2px 0 -2px, 40px 2px 0 -5px, -40px 2px 0 -5px;
    }

    60% {
        box-shadow: 40px 2px 0 -2px, -40px 2px 0 -2px, 23px -23px 0 -5px, -40px 2px 0 -5px;
    }

    80%, 95% {
        box-shadow: 40px 2px 0 -2px, -40px 2px 0 -2px, 23px -23px 0 -5px, -23px -23px 0 -5px;
    }

    100% {
        box-shadow: 40px 2px 0 -2px rgba(255, 255, 255, 0), -40px 2px 0 -2px rgba(255, 255, 255, 0), 23px -23px 0 -5px rgba(255, 255, 255, 0), -23px -23px 0 -5px rgba(255, 255, 255, 0);
    }
}

/* Mobile optimizasyon */
@media (max-width: 480px) {
    .loader {
        width: 32px;
        height: 16px;
        margin: 30px auto 0;
    }

        .loader::after {
            width: 20px;
            height: 20px;
            top: -26px;
        }

    .loading-strong {
        font-size: 12px;
        max-width: 200px;
    }
}
