/* ===== ESTILOS DE VENTANAS ESTILO macOS - LIGHT MODE ===== */
:root {
    --window-bg: rgba(255, 255, 255, 0.92);
    --window-header-bg: rgba(245, 245, 247, 0.85);
    --window-border: rgba(0, 0, 0, 0.08);
    --window-shadow: 0 20px 50px rgba(0, 0, 0, 0.18);
    --accent-blue: #007aff;
    --text-primary: #1d1d1f;
    --text-secondary: #6e6e73;
}

/* Ventana modal */
.window-modal {
    display: none;
    position: fixed;
    background: var(--window-bg);
    backdrop-filter: blur(28px);
    -webkit-backdrop-filter: blur(28px);
    border-radius: 14px;
    box-shadow: var(--window-shadow), 0 0 0 1px var(--window-border);
    overflow: hidden;
    z-index: 5000;
    flex-direction: column;
    min-width: 320px;
    min-height: 220px;
    resize: both;
    
    /* Animaciones */
    opacity: 0;
    transform: translate(-50%, -48%) scale(0.96);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s cubic-bezier(0.0, 0.0, 0.2, 1);
    will-change: transform, opacity;
}

.window-modal[style*="display: flex"] {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

/* Header */
.window-header {
    background: var(--window-header-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    color: var(--text-primary);
    padding: 10px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: grab;
    border-bottom: 1px solid var(--window-border);
    user-select: none;
    min-width: 100%;
    box-sizing: border-box;
}

.window-title {
    font-weight: 500;
    font-size: 13.5px;
    letter-spacing: 0.2px;
    color: var(--text-primary);
}

/* Controles - Botones estilo macOS Light */
.window-controls {
    display: flex;
    gap: 8px;
    align-items: center;
}

.window-button {
    width: 28px;
    height: 28px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 0.9em;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1),
                0 1px 3px rgba(0, 0, 0, 0.15);
}

/* Colores clásicos de botones macOS */
.close-btn     { background: #ff605c; }
.minimize-btn  { background: #ffbd44; }
.maximize-btn  { background: #00ca4e; }
.reload-btn    { background: #8e8e93; color: white; }

.window-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.close-btn:hover     { background: #ff3b30; }
.minimize-btn:hover  { background: #ffb02e; }
.maximize-btn:hover  { background: #00b542; }
.reload-btn:hover    { background: #6e6e73; }

.window-button:active {
    transform: translateY(1px) scale(0.92);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.window-button i {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    font-size: 12px;
    line-height: 1;
}

/* Contenido */
.window-content {
    flex-grow: 1;
    overflow: hidden;
    padding: 0;
    width: 100%;
    height: 100%;
    background: #f8f8f8;
}

.window-content iframe {
    width: 100%;
    height: 100%;
    border: none;
    display: block;
    background: #f8f8f8;
}

/* ===== ANIMACIONES (se mantienen iguales) ===== */
@keyframes minimizeToTaskbar { /* ... mismo código que tenías ... */ }
@keyframes restoreFromTaskbar { /* ... mismo código que tenías ... */ }

/* Ajustes para barra de tareas y maximized */
.window-modal:not(.maximized) {
    max-height: calc(100vh - 50px);
}

.window-modal.maximized {
    height: calc(100vh - 50px) !important;
    top: 0 !important;
    bottom: 50px !important;
}

/* ===== BARRA DE TAREAS - LIGHT MODE ===== */
.taskbar {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 50px;
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(28px);
    -webkit-backdrop-filter: blur(28px);
    border-top: 1px solid rgba(0, 0, 0, 0.08);
    display: flex;
    align-items: center;
    padding: 0 15px;
    box-sizing: border-box;
    z-index: 10000;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.12);
}

.taskbar-item {
    background: rgba(240, 240, 245, 0.85);
    backdrop-filter: blur(12px);
    color: var(--text-primary);
    border: 1px solid rgba(0, 0, 0, 0.1);
    padding: 6px 15px;
    margin-right: 8px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.taskbar-item:hover {
    background: rgba(230, 230, 235, 0.9);
    transform: translateY(-1px);
}

.taskbar-item.active {
    background: rgba(0, 122, 255, 0.12);
    border-color: rgba(0, 122, 255, 0.3);
    box-shadow: 0 0 0 2px rgba(0, 122, 255, 0.15);
}

.taskbar-item.minimized {
    opacity: 0.75;
    filter: grayscale(0.3);
}

.taskbar-item.minimized:hover {
    opacity: 1;
    filter: grayscale(0);
}

/* Loading y demás elementos se mantienen similares */
.loading-overlay {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(8px);
}

.spinner {
    border: 3px solid rgba(0, 0, 0, 0.08);
    border-top: 3px solid #007aff;
}