/* Preloader Styles */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #ffffff;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.5s ease-out, visibility 0.5s ease-out;
}

#preloader.fade-out {
    opacity: 0;
    visibility: hidden;
}

.preloader-content {
    text-align: center;
    position: relative;
}

.logo-container {
    position: relative;
    width: 150px;
    height: 150px;
    margin: 0 auto 30px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.logo-container::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 180px;
    height: 180px;
    transform: translate(-50%, -50%);
    border: 3px solid transparent;
    border-top-color: #ff6b35;
    border-right-color: #ff6b35;
    border-radius: 50%;
    animation: spin 1.2s cubic-bezier(0.68, -0.55, 0.265, 1.55) infinite;
}

.logo-container::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 140px;
    height: 140px;
    transform: translate(-50%, -50%);
    border: 3px solid transparent;
    border-bottom-color: #4ecdc4;
    border-left-color: #4ecdc4;
    border-radius: 50%;
    animation: spin-reverse 1s cubic-bezier(0.68, -0.55, 0.265, 1.55) infinite;
}

.preloader-logo {
    width: 100px;
    height: auto;
    position: relative;
    z-index: 1;
    animation: spin-logo 2s linear infinite;
    filter: drop-shadow(0 0 20px rgba(255, 107, 53, 0.2));
}

.loading-text {
    font-family: 'Work Sans', sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: #333333;
    letter-spacing: 2px;
    text-transform: uppercase;
    animation: pulse-text 1.5s ease-in-out infinite;
    margin-top: 20px;
}

@keyframes spin {
    0% {
        transform: translate(-50%, -50%) rotate(0deg);
    }
    100% {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

@keyframes spin-reverse {
    0% {
        transform: translate(-50%, -50%) rotate(360deg);
    }
    100% {
        transform: translate(-50%, -50%) rotate(0deg);
    }
}

@keyframes spin-logo {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

@keyframes pulse-text {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .logo-container {
        width: 120px;
        height: 120px;
    }
    
    .logo-container::before {
        width: 150px;
        height: 150px;
    }
    
    .logo-container::after {
        width: 110px;
        height: 110px;
    }
    
    .preloader-logo {
        width: 80px;
    }
    
    .loading-text {
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .logo-container {
        width: 100px;
        height: 100px;
    }
    
    .logo-container::before {
        width: 130px;
        height: 130px;
    }
    
    .logo-container::after {
        width: 90px;
        height: 90px;
    }
    
    .preloader-logo {
        width: 60px;
    }
    
    .loading-text {
        font-size: 12px;
    }
}

/* Prevent scrolling while preloader is active */
body.preloader-active {
    overflow: hidden;
    height: 100vh;
}
