/* Full screen overlay */
.overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #fff;
    z-index: 999;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 1;
    transition: opacity 0.8s ease-in-out; /* fade overlay */
}

/* Logo centered */
.loader-logo {
    position: relative;
    z-index: 1000;
}

.loader-logo img {
    max-width: 500px;
    height: auto;
    display: block;
}

/* Responsive logo size for mobile and small screens */
@media (max-width: 768px) {
    .loader-logo img {
        max-width: 300px;
    }
}


/* Bar loader (curtain-style) */
.bar {
    position: absolute;
    width: 10.1vw;
    top: 0;
    bottom: 0;
    background: #F6F5F2;
    transform: scaleX(1);
    transform-origin: center;
    transition: transform 0.8s ease-in-out;
    border-left: 1px solid rgba(255,255,255,0.2);
}

.bar:nth-of-type(1)  { left: 0vw;  }
.bar:nth-of-type(2)  { left: 10vw; }
.bar:nth-of-type(3)  { left: 20vw; }
.bar:nth-of-type(4)  { left: 30vw; }
.bar:nth-of-type(5)  { left: 40vw; }
.bar:nth-of-type(6)  { left: 50vw; }
.bar:nth-of-type(7)  { left: 60vw; }
.bar:nth-of-type(8)  { left: 70vw; }
.bar:nth-of-type(9)  { left: 80vw; }
.bar:nth-of-type(10) { left: 90vw; }

/* Retract bars when overlay gets .open */
.overlay.open .bar {
    transform: scaleX(0);
}

/* Main content hidden until loader finishes */
.content {
    opacity: 0;
    transition: opacity 0.15s ease-in-out;
}

.content.visible {
    opacity: 1;
}
