/* =============================================================================
   LOADING OVERLAY STYLES
   ============================================================================= */

/* Full-screen loading overlay */
.loading-pane {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: #000;  /* Dark background matching the site theme */
    z-index: 99999;  /* Highest z-index to cover everything */
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s ease-out, visibility 0.5s ease-out;
}

/* Loading pane hidden state */
.loading-pane.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* Content container */
.loading-content {
    text-align: center;
    max-width: 600px; /* Increased to accommodate console */
    width: 90%;
    display: flex;
    flex-direction: column;
    align-items: center; /* Center all children horizontally */
}

/* Loading logo */
.loading-logo {
    margin-bottom: 40px;
    animation: pulse 1.5s ease-in-out infinite;
}

.loading-logo-img {
    width: 200px;
    height: auto;
    /* No filter - use original SVG colors */
}

/* Logo pulse animation */
@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 0.8;
    }
    50% {
        transform: scale(1.05);
        opacity: 1;
    }
}

/* Progress bar container */
.loading-progress-container {
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 20px;
    position: relative;
}

/* Progress bar */
.loading-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #c2d500, #8faa00);  /* Novio brand colors */
    border-radius: 2px;
    width: 0%;
    transition: width 0.1s ease;
    box-shadow: 0 0 10px rgba(194, 213, 0, 0.5);
}

/* Loading text */
.loading-text {
    color: rgba(255, 255, 255, 0.6);
    font-family: 'Orbitron', sans-serif;
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

/* Light theme support */
body.light-theme .loading-pane {
    background: #e0e0e0;  /* Light gray background */
}

/* Light theme logo uses its original colors */
body.light-theme .loading-logo-img {
    filter: none;
}

body.light-theme .loading-progress-container {
    background: rgba(0, 0, 0, 0.1);
}

body.light-theme .loading-text {
    color: rgba(0, 0, 0, 0.6);
}

/* Loading console wrapper */
.loading-console-wrapper {
    margin-top: 30px;
    width: 100%; /* Same width as progress bar container */
    position: relative;
    text-align: left; /* Reset text alignment for console content */
}

/* Loading console panel */
.loading-console {
    height: 35px; /* Reduced from 200px to 25px (1/8 of original size) */
    background: transparent; /* Remove background */
    overflow-y: auto;
    font-family: 'Courier New', monospace;
    font-size: 11px;
    color: #808080; /* Medium gray for both themes */
    /* Hide scrollbar */
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
}

/* Hide scrollbar for webkit browsers */
.loading-console::-webkit-scrollbar {
    display: none;
}

.loading-console-content {
    white-space: pre-wrap;
    word-wrap: break-word;
}

.loading-console-content .console-line {
    margin-bottom: 2px;
    line-height: 1.3;
}

.loading-console-content .console-success {
    color: inherit; /* Use parent color (medium gray) */
}

.loading-console-content .console-error {
    color: inherit; /* Use parent color (medium gray) */
}

.loading-console-content .console-info {
    color: inherit; /* Use parent color (medium gray) */
}

.loading-console-content .console-warn {
    color: inherit; /* Use parent color (medium gray) */
}

/* Fade overlay div positioned above the console */
.loading-console-fade {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    /* This makes it exactly the same size and position as the console */
    background: linear-gradient(
        transparent 0%,
        black 100%
    ); /* Fade from 0-70%, solid red from 70-100% */
    pointer-events: none;
    z-index: 10;
}

/* Light theme console */
body.light-theme .loading-console {
    color: #808080; /* Same medium gray for light theme */
}

/* Light theme console text colors */
body.light-theme .loading-console-content .console-success {
    color: inherit; /* Use parent color (medium gray) */
}

body.light-theme .loading-console-content .console-error {
    color: inherit; /* Use parent color (medium gray) */
}

body.light-theme .loading-console-content .console-info {
    color: inherit; /* Use parent color (medium gray) */
}

body.light-theme .loading-console-content .console-warn {
    color: inherit; /* Use parent color (medium gray) */
}

/* Light theme fade overlay - fade to light gray */
body.light-theme .loading-console-fade {
    background: linear-gradient(
        transparent 0%,
        #E0E0E0 100%
    ); /* Fade from 0-70%, solid red from 70-100% */
}