/* Boot Screen Styles */
.boot-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: #000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.5s ease-out;
}

/* Loading Container */
.loading-container {
    text-align: center;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 600px;
}

.windows-logo {
    margin-bottom: 0px; /* Sin margen para pegar la barra al logo */
}

.windows-logo img {
    width: 450px; /* Aumentar el tamaño del logo considerablemente */
    height: auto;
    object-fit: contain;
    margin-bottom: 30px; /* Ajustar el margen inferior de la imagen del logo */
    filter: drop-shadow(0 0 30px rgba(255,255,255,0.4));
}

.windows-logo h1 {
    color: #fff;
    font-family: 'Arial', sans-serif;
    font-size: 80px; /* Ajustar tamaño de fuente del título principal */
    margin: 0;
    font-weight: normal;
    letter-spacing: -2px;
    text-shadow: 3px 3px 6px rgba(0,0,0,0.7);
}

.windows-logo h1 .xp {
    color: #FF6B35;
    font-size: 55px; /* Ajustar tamaño de fuente del "XP" */
    vertical-align: super;
    margin-left: -5px;
    font-weight: bold;
}

.tagline {
    color: #ddd;
    font-size: 18px;
    font-family: 'Arial', sans-serif;
    margin-top: 5px; /* Reducir el margen superior del tagline */
    letter-spacing: 1px;
    text-transform: capitalize;
}

/* Loading Bar - Windows XP Style */
.loading-bar-container {
    width: 300px;
    height: 20px;
    margin: 0 auto;
    border: 2px solid #868686;
    border-radius: 4px;
    background: #000;
    padding: 2px;
    box-shadow: inset 0 0 3px rgba(0,0,0,0.8);
}

.loading-bar {
    height: 100%;
    display: flex;
    gap: 2px; /* Keep existing gap */
    padding: 0 2px; /* Keep existing padding */
    justify-content: flex-start; /* New: Align blocks to the start */
    overflow: hidden; /* New: Hide overflowing content */
}

.loading-block {
    width: 15px; /* Modified: Fixed width for square appearance */
    height: 100%;
    background: #316AC5;
    opacity: 1; /* Modified: Always visible */
    animation: xp-loading-slide 2s linear infinite; /* Modified: New animation */
}

@keyframes xp-loading-slide {
    0% {
        transform: translateX(-100%); /* Start off-screen to the left */
    }
    100% {
        transform: translateX(calc(300px + 100%)); /* Move across the 300px container + its own width */
    }
}

/* Apply animation delays to each block using nth-child selectors */
.loading-block:nth-child(1) {
    animation-delay: 0s;
}
.loading-block:nth-child(2) {
    animation-delay: 0.2s; /* Adjust delay for chasing effect */
}
.loading-block:nth-child(3) {
    animation-delay: 0.4s; /* Adjust delay for chasing effect */
}

/* Boot Footer */
.boot-bottom-left {
    position: absolute;
    bottom: 30px; /* Ajustar la posición del texto inferior izquierdo */
    left: 30px;
    color: #888;
    font-family: 'Arial', sans-serif;
    font-size: 14px;
    line-height: 1.4;
}

.boot-bottom-left span {
    display: block;
}

.boot-bottom-right {
    position: absolute;
    bottom: 30px; /* Ajustar la posición del texto inferior derecho */
    right: 30px;
    color: #fff;
    font-family: 'Arial', sans-serif;
}

.boot-wordmark {
    font-size: 36px;
    font-weight: bold;
    font-style: italic;
    opacity: 0.8;
}

/* Boot Fadeout Overlay */
.boot-fadeout-overlay-style {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
    z-index: 9998;
    transition: opacity 0.5s;
}

/* Login Screen Styles */
#login-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 9997;
    overflow: hidden;
}

.login-screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent;
    z-index: 1;
}

.login-screen-initial-display {
    opacity: 1;
    transition: opacity 0.5s;
}

.login-screen-inner {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

/* Pattern overlay - more subtle */
.login-screen::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 100%;
    background-image: radial-gradient(circle, rgba(255,255,255,0.05) 1px, transparent 1px);
    background-size: 15px 15px;
    pointer-events: none;
}

/* Gradient overlay */
.login-screen::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(to bottom, transparent 0%, rgba(15, 59, 217, 0.3) 100%);
    pointer-events: none;
}

.login-screen-center {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 1400px;
    padding: 0 80px 80px 80px; /* Ajustar el padding inferior para subir un poco más el contenido central */
    gap: 50px; /* Espacio entre el logo y el perfil de usuario */
    z-index: 1;
    position: relative;
}

.left {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0px; /* Reducir aún más el espacio entre logo y texto */
}

.custom-logo {
    width: 280px; /* Reducir aún más el tamaño del logo */
    height: auto;
    margin: 0;
    filter: drop-shadow(2px 2px 4px rgba(0,0,0,0.3));
}

.left-text {
    color: white;
    font-family: 'Tahoma', sans-serif;
    font-size: 16px;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
    max-width: 500px;
    margin-top: 10px; /* Añadir un pequeño margen superior para separar del logo */
    text-align: center; /* Asegurar centrado */
}

.login-instruction-name {
    font-weight: bold;
}

.brand-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.login-brand {
    margin: 0;
    text-align: left;
}

.login-brand h1 {
    font-family: 'Tahoma', sans-serif;
    font-size: 72px;
    color: white;
    margin: 0 0 10px 0;
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    letter-spacing: -3px;
}

.login-brand .xp-text {
    color: #FF6B35;
    font-weight: bold;
    font-style: italic;
    font-size: 84px;
}

.brand-subtitle {
    font-family: 'Tahoma', sans-serif;
    font-size: 18px;
    color: rgba(255,255,255,0.9);
    margin: 0;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
}

.login-separator {
    display: none;
}

.right {
    cursor: pointer;
    /* Eliminamos el posicionamiento absoluto para que flexbox lo maneje */
}

.back-gradient {
    background: rgba(255,255,255,0.15);
    padding: 12px 20px;
    border-radius: 5px;
    border: 1px solid rgba(255,255,255,0.3);
    backdrop-filter: blur(15px);
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.2s ease;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.back-gradient:hover {
    background: rgba(255,255,255,0.25);
    border-color: rgba(255,255,255,0.5);
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
    transform: translateY(-2px);
}

.user img {
    width: 48px;
    height: 48px;
    border-radius: 3px;
    border: 2px solid rgba(255,255,255,0.4);
    background: white;
    padding: 2px;
}

.text-wrap {
    text-align: left;
}

.name {
    font-size: 16px;
    font-weight: bold;
    color: white;
    font-family: 'Tahoma', sans-serif;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
    margin-bottom: 2px;
}

.user-title {
    font-size: 11px;
    color: rgba(255,255,255,0.7);
    font-family: 'Tahoma', sans-serif;
}

/* Turn off section */
.turn-off {
    position: absolute;
    bottom: 15px; /* Mover más abajo */
    left: 30px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: white;
    font-size: 11px;
    font-family: 'Tahoma', sans-serif;
    opacity: 0.8;
    cursor: pointer;
}

.turn-off:hover {
    opacity: 1;
}

#shutdown-icon {
    width: 16px;
    height: 16px;
}

.shutdown-text {
    text-decoration: underline;
}

/* Right bottom text */
.right-bottom {
    position: absolute;
    bottom: 15px; /* Mover más abajo */
    right: 30px;
    color: white;
    font-size: 11px;
    font-family: 'Tahoma', sans-serif;
    opacity: 0.9;
    text-align: right;
    line-height: 1.4;
}

.desktop-bottom-detail {
    display: block;
}

.mobile-bottom-detail {
    display: none;
}

/* Welcome Message */
.welcome-message {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    z-index: 2;
}

.welcome-message-initial-hidden {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s;
}

.welcome-image-fallback {
    font-size: 72px;
    color: white;
    font-family: 'Tahoma', sans-serif;
    font-weight: bold;
    font-style: italic;
    text-shadow: 3px 3px 6px rgba(0,0,0,0.5);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .login-screen-center {
        flex-direction: column;
        gap: 40px;
    }
    
    .login-separator {
        display: block;
        width: 200px;
        border: none;
        border-top: 1px solid rgba(255,255,255,0.3);
        margin: 20px 0;
    }
    
    .desktop-bottom-detail {
        display: none;
    }
    
    .mobile-bottom-detail {
        display: block;
    }
    
    .left-text {
        display: none;
    }
    
    .boot-wordmark {
        font-size: 24px;
    }
    
    .windows-logo h1 {
        font-size: 48px;
    }
    
    .windows-logo h1 .xp {
        font-size: 32px;
    }
}

/* Log off Dialog */
.logoff-dialog-hidden {
    display: none;
}

#logoff-dialog-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logoff-dialog {
    position: relative;
    display: inline-block;
}

.logoff-dialog-background {
    display: block;
    width: 400px;
    height: auto;
    max-width: 400px;
}

.logoff-dialog-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 0;
}

.logoff-dialog-header-text {
    color: white;
    font-size: 14px;
    font-weight: bold;
    font-family: 'Tahoma', sans-serif;
    text-align: left;
    padding: 12px 12px 8px 12px;
    margin-top: 0;
}

.logoff-dialog-button-container {
    display: flex;
    gap: 60px;
    justify-content: center;
    align-items: center;
    flex: 1;
    padding: 20px 0;
}

.logoff-dialog-button {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 15px;
    cursor: pointer;
    border-radius: 4px;
    transition: background 0.2s;
    background: transparent;
    border: 1px solid transparent;
    min-width: 100px;
}

.logoff-dialog-button:hover {
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.4);
}

.logoff-dialog-button img {
    width: 48px;
    height: 48px;
}

.logoff-dialog-button span {
    font-size: 12px;
    text-align: center;
    color: #000;
    font-family: 'Tahoma', sans-serif;
    font-weight: normal;
}

#logoff-cancel-btn {
    padding: 6px 20px;
    font-size: 11px;
    background: #E1E1E1;
    border: 1px solid #ADADAD;
    border-radius: 3px;
    cursor: pointer;
    font-family: 'Tahoma', sans-serif;
    color: #000;
    margin: 0 20px 20px 0;
    align-self: flex-end;
}

#logoff-cancel-btn:hover {
    background: #EFEFEF;
    border-color: #0054E3;
}

/* Shutdown Window Styles */
.shutdown-window-hidden {
    display: none;
}

#shutdown-window-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
}

.shutdown-window {
    display: flex;
    align-items: center;
    justify-content: center;
}

.shutdown-image {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
}

/* Logoff Window Styles */
.logoff-window-hidden {
    display: none;
}

#logoff-window-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logoff-window {
    display: flex;
    align-items: center;
    justify-content: center;
}

.logoff-image {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
}
