/**
 * WordPress Loading Screen Styles
 * Sequential Fade Animation
 */

/* ===== CUSTOM PROPERTIES FÜR EINFACHE ANPASSUNG ===== */
:root {
    --loading-primary-color: var(--primary-color);
    --loading-secondary-color: var(--primary-dark);
    --loading-text-color: var(--gray-900);
    --loading-logo-size: 120px;
    --loading-animation-duration: 3s;
}

/* ===== MAIN LOADING SCREEN ===== */
#wp-loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #ffffff;
    background: linear-gradient(135deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
    z-index: 999999;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    transition: opacity 0.5s ease-out, visibility 0.5s ease-out;
}

#wp-loading-screen.loaded {
    opacity: 0;
    visibility: hidden;
}

/* ===== LOADING CONTAINER ===== */
.loading-container {
    text-align: center;
    animation: containerFadeIn 0.8s ease-out;
}

@keyframes containerFadeIn {
    0% {
        opacity: 0;
        transform: translateY(20px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== LOADING LOGO ===== */
.loading-logo {
    width: 120px;
    height: auto;
    fill: #007acc;
    margin-bottom: 20px;
    filter: drop-shadow(0 2px 8px rgba(222, 0, 104, 0.3));
    transition: transform 0.3s ease;
}

.loading-logo:hover {
    transform: scale(1.05);
}

/* ===== SEQUENTIAL FADE ANIMATION ===== */
.fade-animation path {
    animation: fadeInOut 3s ease-in-out infinite;
    opacity: 0.3;
    transform-origin: center;
}

.fade-animation path:nth-child(1) {
    animation-delay: 0s;
}

.fade-animation path:nth-child(2) {
    animation-delay: 0.3s;
}

.fade-animation path:nth-child(3) {
    animation-delay: 0.6s;
}

.fade-animation path:nth-child(4) {
    animation-delay: 0.9s;
}

.fade-animation path:nth-child(5) {
    animation-delay: 1.2s;
}

@keyframes fadeInOut {

    0%,
    80%,
    100% {
        opacity: 0.3;
        transform: scale(1);
    }

    20%,
    60% {
        opacity: 1;
        transform: scale(1.02);
    }
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    .loading-logo {
        width: 80px;
        margin-bottom: 15px;
    }

    .loading-text {
        font-size: 14px;
        margin-top: 15px;
    }

    .loading-progress {
        width: 150px;
        margin-top: 12px;
    }
}

@media (max-width: 480px) {
    .loading-logo {
        width: 60px;
        margin-bottom: 12px;
    }

    .loading-text {
        font-size: 12px;
        margin-top: 12px;
    }

    .loading-progress {
        width: 120px;
        height: 2px;
        margin-top: 10px;
    }
}

/* ===== HIGH DPI SCREENS ===== */
@media (-webkit-min-device-pixel-ratio: 2),
(min-resolution: 2dppx) {
    .loading-logo {
        filter: drop-shadow(0 1px 4px rgba(222, 0, 104, 0.3));
    }
}

.loading-logo {
    fill: var(--loading-primary-color);
    width: var(--loading-logo-size);
}

.fade-animation path {
    animation-duration: var(--loading-animation-duration);
}