:root {
    --bg-color: #0f172a;
    --panel-bg: rgba(30, 41, 59, 0.7);
    --panel-border: rgba(255, 255, 255, 0.1);
    --primary: #3b82f6;
    --primary-hover: #2563eb;
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --danger: #ef4444;
    --danger-hover: #dc2626;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body, html {
    height: 100%;
    width: 100%;
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    background-image: 
        radial-gradient(at 0% 0%, rgba(59, 130, 246, 0.15) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(139, 92, 246, 0.15) 0px, transparent 50%);
    color: var(--text-main);
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Glassmorphism utility */
.glass-panel {
    background: var(--panel-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--panel-border);
    border-radius: 16px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

#login-container {
    width: 100%;
    max-width: 420px;
    padding: 40px;
    z-index: 10;
    transition: opacity 0.5s ease, transform 0.5s ease;
}

#login-container.hidden {
    opacity: 0;
    pointer-events: none;
    transform: scale(0.95);
    position: absolute;
}

.logo-area {
    text-align: center;
    margin-bottom: 32px;
    position: relative;
}

.glow-orb {
    position: absolute;
    width: 60px;
    height: 60px;
    background: var(--primary);
    filter: blur(30px);
    border-radius: 50%;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0.5;
    z-index: -1;
}

.logo-area h1 {
    font-size: 28px;
    font-weight: 700;
    letter-spacing: -0.5px;
    margin-bottom: 4px;
}

.logo-area p {
    color: var(--text-muted);
    font-size: 14px;
}

.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.input-group input {
    width: 100%;
    padding: 12px 16px;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    color: var(--text-main);
    font-family: inherit;
    font-size: 15px;
    outline: none;
    transition: all 0.2s;
}

.input-group input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.25);
}

button {
    width: 100%;
    padding: 14px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 8px;
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

button:hover {
    background: var(--primary-hover);
}

button:active {
    transform: scale(0.98);
}

#error-message {
    margin-top: 20px;
    padding: 12px;
    background: rgba(239, 68, 68, 0.1);
    border-left: 4px solid var(--danger);
    border-radius: 4px;
    color: #fca5a5;
    font-size: 13px;
    text-align: center;
}

.hidden {
    display: none !important;
}

/* Loader */
.loader {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Display Area */
#display {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    background: #000;
}

/* Toolbar */
#toolbar {
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    padding: 10px 20px;
    z-index: 100;
    display: flex;
    gap: 10px;
    border-radius: 30px;
}

#toolbar button {
    background: var(--danger);
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 13px;
    width: auto;
}

#toolbar button:hover {
    background: var(--danger-hover);
}

#hide-toolbar-btn {
    background: transparent !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    padding: 8px 12px !important;
    border-radius: 50% !important;
    color: var(--text-muted);
}

#hide-toolbar-btn:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    color: white;
}

#show-toolbar-btn {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 100;
    padding: 10px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--panel-bg);
    font-size: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--text-muted);
}

#show-toolbar-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
}
