@import url('https://googleapis.com');

:root {
    --space-bg: #06060c;
    --panel-bg: rgba(13, 13, 25, 0.85);
    --neon-purple: #9d4edf;
    --neon-cyan: #00f5ff;
    --text-main: #f1f1f7;
    --text-muted: #7e7e9a;
    --border-glow: rgba(157, 78, 223, 0.25);
}

body {
    font-family: 'Rajdhani', sans-serif;
    background-color: var(--space-bg);
    color: var(--text-main);
    margin: 0;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 18px;
}

/* Background Canvas Starfield */
#starfield {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
}

/* Cyber Glass Panel */
.space-panel {
    background: var(--panel-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-glow);
    box-shadow: 0 0 35px rgba(157, 78, 223, 0.15);
    padding: 2.5rem;
    border-radius: 16px;
    width: 100%;
    max-width: 500px;
    box-sizing: border-box;
    z-index: 10;
}

.dir-wide {
    max-width: 900px;
}

h2, h3 {
    font-family: 'Orbitron', sans-serif;
    letter-spacing: 2px;
    margin-top: 0;
    text-shadow: 0 0 10px var(--neon-purple);
}

h2 { text-align: center; color: #fff; }

.error-msg {
    color: #ff4a4a;
    background: rgba(255, 74, 74, 0.1);
    padding: 0.75rem;
    border-radius: 6px;
    border: 1px solid #ff4a4a;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    text-align: center;
}

/* Inputs & Forms */
.input-group {
    margin-bottom: 1.5rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--neon-cyan);
}

input[type="text"], input[type="password"] {
    width: 100%;
    padding: 0.8rem;
    background: rgba(5, 5, 10, 0.8);
    border: 1px solid rgba(157, 78, 223, 0.4);
    color: white;
    border-radius: 6px;
    box-sizing: border-box;
    font-size: 1rem;
    transition: all 0.3s ease;
}

input:focus {
    outline: none;
    border-color: var(--neon-cyan);
    box-shadow: 0 0 12px rgba(0, 245, 255, 0.4);
}

/* Interactive Buttons */
.btn-cosmic {
    font-family: 'Orbitron', sans-serif;
    background: linear-gradient(45deg, var(--neon-purple), #5a189a);
    color: white;
    border: none;
    padding: 0.9rem 1.5rem;
    font-weight: bold;
    letter-spacing: 1px;
    border-radius: 6px;
    cursor: pointer;
    width: 100%;
    box-shadow: 0 4px 15px rgba(157, 78, 223, 0.3);
    transition: all 0.3s ease;
}

.btn-cosmic:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(0, 245, 255, 0.3);
}

/* File Explorer & Folder Trees */
.folder-node {
    margin-left: 1rem;
    border-left: 1px dashed rgba(157, 78, 223, 0.25);
    padding-left: 0.75rem;
}

.folder-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem;
    cursor: pointer;
    user-select: none;
    border-radius: 4px;
    transition: background 0.2s;
}

.folder-header:hover {
    background: rgba(157, 78, 223, 0.1);
}

.folder-icon {
    transition: transform 0.2s ease;
    display: inline-block;
}

.folder-node.collapsed > .folder-contents {
    display: none;
}

.folder-node.collapsed > .folder-header .folder-icon {
    transform: rotate(-90deg);
}

.file-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.6rem;
    margin-left: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.file-item:hover {
    background: rgba(0, 245, 255, 0.05);
}

.action-link {
    color: var(--neon-cyan);
    text-decoration: none;
    font-size: 0.9rem;
    letter-spacing: 0.5px;
}

.action-link:hover {
    text-shadow: 0 0 5px var(--neon-cyan);
}

/* Upload Progress Components */
.progress-container {
    display: none;
    margin-top: 1.5rem;
    background: rgba(0, 0, 0, 0.4);
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid rgba(0, 245, 255, 0.2);
}

.progress-bar-wrapper {
    background: #151525;
    border-radius: 10px;
    height: 12px;
    overflow: hidden;
    margin-top: 0.5rem;
}

.progress-bar {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, var(--neon-purple), var(--neon-cyan));
    box-shadow: 0 0 8px var(--neon-cyan);
    transition: width 0.1s linear;
}
