body,
html {
    margin: 0;
    padding: 0;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #ffffff;
    overflow: hidden;
}

/* Loading screen with centered spinner */
.loading-screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: #ffffff;
    z-index: 100;
    opacity: 1;
    animation: fadeIn 0.3s ease-out forwards;
    transition: all .4s ease-in-out;
    pointer-events: none;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.loading-text {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    font-size: 18px;
    font-weight: 500;
    color: #333333;
    margin-top: 12px;
}

.loading-logo {
    width: 80px;
    height: 80px;
    animation: gentlePulse 2s ease-in-out infinite;
    min-width: 80px;
    min-height: 80px;
    max-width: 80px;
    max-height: 80px;
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

.progress-bar-container {
    position: relative;
    margin-top: 20px;
    width: 160px;
    height: 2px;
    background-color: #f0f0f0;
    overflow: hidden;
    border-radius: 1px;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #0056b3, #007bff, #0056b3);
    width: 40%;
    animation: progressMove 1.5s ease-in-out infinite;
    will-change: transform;
}

@keyframes progressMove {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(350%);
    }
}

@keyframes gentlePulse {
    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.8;
        transform: scale(1.05);
    }
}

@media (prefers-reduced-motion: reduce) {
    .loading-logo {
        animation: none;
    }
    .progress-bar {
        display: none;
    }
    .loading-screen {
        animation: none;
        transition: none;
    }
}

@media (prefers-contrast: high) {
    .loading-text {
        color: #000000;
    }
    .progress-bar {
        background: #000000;
    }
}

.grecaptcha-badge {
    display: none;
}