#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: #111;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 1;
    transition: opacity 1s ease-in-out, visibility 1s ease-in-out;
    visibility: hidden;
}

#preloader.show {
    visibility: visible; 
}

.preloader-content {
    text-align: center;
    opacity: 0;
    animation: fadeIn 1s forwards;
}

.preloader-image {
    width: 100%;  
    max-width: 400px;
    height: auto;
    max-height: 400px;
    margin-bottom: 20px;
}

#preloader p {
    font-size: 20px;
    color: orange;
    margin-bottom: 20px;
}

.loading-bar-container {
    width: 100%;
    max-width: 300px;
    height: 10px;
    background-color: white;
    border-radius: 5px;
    overflow: hidden;
    margin: 0 auto;
}

.loading-bar {
    height: 100%;
    width: 0%;
    background-color: orange;
    transition: width 2s ease;
    border: solid 2px white;
}

#preloader.fade-out {
    opacity: 0;
    visibility: hidden;
    transition: opacity 1s ease-in-out, visibility 1s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Media query to adjust image size for smaller screens */
@media (max-width: 768px) {
    .preloader-image {
        max-width: 250px;
        max-height: 250px;
    }
}
