/* Elegant Loading Screen Design */
/* ============================== */

.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #00CED1 0%, #20B2AA 100%) !important;
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.6s ease, visibility 0.6s ease;
}

.loading-screen.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* Simple Animated Background */
.loading-bg-animation {
    position: absolute;
    width: 200%;
    height: 200%;
    top: -50%;
    left: -50%;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E") repeat;
    animation: float-bg 20s linear infinite;
}

@keyframes float-bg {
    from { transform: translate(0, 0); }
    to { transform: translate(30px, 30px); }
}

/* Main Loading Container */
.loading-content {
    position: relative;
    z-index: 10;
    text-align: center;
    max-width: 400px;
    padding: 40px;
}

/* Elegant Logo Animation */
.loading-logo {
    margin-bottom: 40px;
    animation: logo-entrance 1s ease-out;
}

@keyframes logo-entrance {
    from {
        opacity: 0;
        transform: scale(0.7) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.loading-logo-circle {
    width: 120px;
    height: 120px;
    margin: 0 auto;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
}

.loading-logo-circle::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent 30%, rgba(255, 255, 255, 0.5) 50%, transparent 70%);
    animation: shine 2s infinite;
}

@keyframes shine {
    from { transform: translateX(-100%) translateY(-100%); }
    to { transform: translateX(100%) translateY(100%); }
}

.loading-logo-icon {
    font-size: 50px;
    background: linear-gradient(135deg, #00CED1, #20B2AA);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    z-index: 1;
    position: relative;
}

/* Doctor Name */
.loading-doctor-name {
    margin-bottom: 30px;
    animation: fade-in 1s 0.3s both;
}

@keyframes fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

.loading-doctor-name h1 {
    color: white;
    font-size: 2rem;
    font-weight: 700;
    margin: 0 0 5px 0;
    letter-spacing: 1px;
}

.loading-doctor-name p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1rem;
    margin: 0;
    letter-spacing: 2px;
    text-transform: uppercase;
}

/* Simple Progress Bar */
.loading-progress-elegant {
    width: 250px;
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    overflow: hidden;
    margin: 0 auto 20px;
    animation: fade-in 1s 0.5s both;
}

.loading-bar {
    height: 100%;
    background: white;
    border-radius: 10px;
    animation: progress 2.5s ease-out forwards;
    position: relative;
    overflow: hidden;
}

.loading-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(255, 255, 255, 0.5), 
        transparent
    );
    animation: shimmer 1s infinite;
}

@keyframes progress {
    from { width: 0%; }
    to { width: 100%; }
}

@keyframes shimmer {
    from { transform: translateX(-100%); }
    to { transform: translateX(100%); }
}

/* Loading Text */
.loading-text-elegant {
    animation: fade-in 1s 0.7s both;
}

.loading-text-elegant p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.95rem;
    margin: 0;
    letter-spacing: 1px;
}

/* Animated Dots */
.loading-dots {
    display: inline-flex;
    gap: 5px;
}

.loading-dots span {
    width: 8px;
    height: 8px;
    background: white;
    border-radius: 50%;
    animation: dot-bounce 1.4s ease-in-out infinite;
}

.loading-dots span:nth-child(1) { animation-delay: 0s; }
.loading-dots span:nth-child(2) { animation-delay: 0.2s; }
.loading-dots span:nth-child(3) { animation-delay: 0.4s; }

@keyframes dot-bounce {
    0%, 80%, 100% {
        transform: scale(0.8);
        opacity: 0.5;
    }
    40% {
        transform: scale(1.2);
        opacity: 1;
    }
}

/* Floating Particles */
.particles {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
}

.particle:nth-child(1) {
    top: 10%;
    left: 20%;
    animation: float-particle 15s infinite;
}

.particle:nth-child(2) {
    top: 20%;
    left: 80%;
    animation: float-particle 20s infinite;
    animation-delay: 2s;
}

.particle:nth-child(3) {
    top: 60%;
    left: 10%;
    animation: float-particle 18s infinite;
    animation-delay: 4s;
}

.particle:nth-child(4) {
    top: 80%;
    left: 70%;
    animation: float-particle 22s infinite;
    animation-delay: 1s;
}

.particle:nth-child(5) {
    top: 40%;
    left: 50%;
    animation: float-particle 17s infinite;
    animation-delay: 3s;
}

@keyframes float-particle {
    0%, 100% {
        transform: translateY(0) translateX(0);
        opacity: 0;
    }
    10% {
        opacity: 0.5;
    }
    90% {
        opacity: 0.5;
    }
    50% {
        transform: translateY(-100px) translateX(50px);
    }
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .loading-content {
        padding: 30px;
    }
    
    .loading-doctor-name h1 {
        font-size: 1.5rem;
    }
    
    .loading-logo-circle {
        width: 100px;
        height: 100px;
    }
    
    .loading-logo-icon {
        font-size: 40px;
    }
    
    .loading-progress-elegant {
        width: 200px;
    }
}

@media (max-width: 480px) {
    .loading-doctor-name h1 {
        font-size: 1.3rem;
    }
    
    .loading-doctor-name p {
        font-size: 0.85rem;
    }
}