/* Reset everything to native app feel */
* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Inter', sans-serif; }
body, html { width: 100%; height: 100%; overflow: hidden; background-color: #050505; }

/* LAYER 1: 3D Canvas */
#renderCanvas {
    width: 100%;
    height: 100%;
    touch-action: none;
    outline: none;
}

/* LAYER 2: UI Overlay */
#os-ui-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none; /* Lets clicks pass through the invisible UI layer */
}

/* The 2D App Windows */
.glass-panel {
    background: rgba(20, 20, 20, 0.7);
    backdrop-filter: blur(15px); /* Modern frosted glass effect */
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 30px;
    color: white;
    text-align: center;
    pointer-events: auto; /* Turn clicks back on for the window */
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.glass-panel h2 { margin-bottom: 10px; font-weight: 600; }
.glass-panel p { color: #aaa; margin-bottom: 20px; }
.glass-panel button {
    background: #00ba5d;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
}
.glass-panel button:hover { background: #00964b; }

/* Utility class to hide windows */
.hidden { opacity: 0; transform: scale(0.9); pointer-events: none; }

/* Add these new rules to the bottom of your CSS file */
.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 15px;
    padding-bottom: 10px;
}
.panel-header h2 { margin-bottom: 0; }
.close-btn { background: transparent !important; color: #888 !important; font-size: 1.2rem; padding: 0 !important; }
.close-btn:hover { color: #ff4444 !important; }

.app-window-large {
    width: 90%;
    max-width: 800px;
    height: 80vh; /* Takes up 80% of the screen height */
    display: flex;
    flex-direction: column;
}
.ql-toolbar { background: #f3f4f6; border-radius: 8px 8px 0 0; } /* Styles the editor toolbar */

.os-btn { background: #333; color: white; border: 1px solid #555; padding: 8px 15px; border-radius: 6px; cursor: pointer; transition: 0.2s; }
.os-btn:hover { background: #00ba5d; border-color: #00ba5d; }