:root {
    --bg-dark: #0a0b10;
    --sidebar-bg: #11141d;
    --accent: #00e5ff;
    --accent-glow: rgba(0, 229, 255, 0.2);
    --text-primary: #e0e6ed;
    --text-muted: #8892b0;
    --border: #232936;
    --surface: #1a1f2e;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text-primary);
    height: 100vh;
    overflow: hidden;
}

.app-container {
    display: flex;
    height: 100vh;
}

/* Sidebar */
.sidebar {
    width: 280px;
    background: var(--sidebar-bg);
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
}

.logo {
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid var(--border);
}

.logo h1 {
    font-family: 'Outfit', sans-serif;
    font-size: 1.2rem;
    letter-spacing: 1px;
    color: var(--accent);
}

.file-explorer {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
}

.section-header {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-actions-small {
    display: flex;
    gap: 8px;
}

.header-actions-small button {
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 0.9rem;
    transition: color 0.2s;
}

.header-actions-small button:hover {
    color: var(--accent);
}

.file-list {
    list-style: none;
}

.file-item {
    padding: 10px 12px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.2s ease;
    margin-bottom: 4px;
}

.file-info {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    min-width: 0;
}

.file-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.file-actions {
    display: none;
    gap: 8px;
    flex-shrink: 0;
    margin-left: 10px;
}

.file-item:hover .file-actions {
    display: flex;
}

.action-icon {
    opacity: 0.6;
    transition: opacity 0.2s;
}

.action-icon:hover {
    opacity: 1;
}

.file-item:hover {
    background: var(--surface);
    color: var(--accent);
}

.file-item.active {
    background: var(--accent-glow);
    color: var(--accent);
    border-left: 3px solid var(--accent);
}

.breadcrumb {
    padding: 10px 15px;
    font-size: 0.8rem;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid var(--border);
    cursor: pointer;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.breadcrumb span:hover {
    color: var(--accent);
}

.file-item.folder {
    font-weight: 600;
}

.btn-delete {
    color: #ff4444 !important;
}

.btn-delete:hover {
    filter: brightness(1.2);
    transform: scale(1.1);
}

.agent-status {
    padding: 20px;
    border-top: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.status-indicator.online {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #00ff88;
    box-shadow: 0 0 10px #00ff88;
}

/* Main Content */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: var(--bg-dark);
}

.main-header {
    padding: 20px 30px;
    background: var(--bg-dark);
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.main-header h2 {
    font-size: 1.1rem;
    font-weight: 400;
}

.editor-container {
    flex: 1;
    padding: 30px;
    overflow-y: auto;
}

.file-content {
    padding: 20px;
    background: var(--surface);
    border-radius: 12px;
    min-height: 100%;
    white-space: pre-wrap;
    font-family: 'Courier New', monospace;
    font-size: 0.95rem;
    border: 1px solid var(--border);
    line-height: 1.6;
}

.placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    text-align: center;
}

.layout-resizer {
    height: 4px;
    background: var(--border);
    cursor: row-resize;
    transition: background 0.2s, height 0.2s;
    position: relative;
    z-index: 10;
}

.layout-resizer:hover {
    background: var(--accent);
    height: 6px;
}

/* Command Center */
.command-center {
    height: 300px;
    background: var(--sidebar-bg);
    border-top: 1px solid var(--border);
    display: flex;
    flex-direction: column;
}

.activity-feed {
    flex: 1;
    overflow-y: auto;
    padding: 15px;
    font-family: monospace;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.activity-feed p {
    margin-bottom: 8px;
    white-space: pre-wrap;
    word-break: break-word;
    line-height: 1.4;
}

.input-area {
    padding: 20px;
    display: flex;
    gap: 15px;
    border-top: 1px solid var(--border);
}

input[type="text"] {
    flex: 1;
    background: var(--bg-dark);
    border: 1px solid var(--border);
    padding: 12px 18px;
    border-radius: 10px;
    color: white;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.2s;
}

input[type="text"]:focus {
    border-color: var(--accent);
}

.btn-secondary,
button#send-btn {
    background: var(--accent);
    color: var(--bg-dark);
    border: none;
    padding: 12px 24px;
    border-radius: 10px;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.1s;
}

button#send-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px var(--accent-glow);
}

#zip-tool {
    display: none;
}

.zip-preview {
    background: var(--bg-dark);
    padding: 20px;
    border-radius: 12px;
    border: 1px solid var(--border);
}

.zip-preview h3 {
    margin-bottom: 15px;
    font-size: 1rem;
    color: var(--accent);
}

.zip-preview ul {
    list-style: none;
    max-height: 400px;
    overflow-y: auto;
}

.zip-preview li {
    padding: 8px 0;
    border-bottom: 1px solid var(--border);
    font-size: 0.9rem;
    display: flex;
    justify-content: space-between;
}

.zip-preview .size {
    color: var(--text-muted);
    font-size: 0.8rem;
}

.media-preview {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%;
    width: 100%;
    padding: 20px;
    background: var(--bg-dark);
    border-radius: 12px;
    border: 1px solid var(--border);
}

.media-preview img {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.media-preview audio {
    width: 100%;
    max-width: 500px;
}

.mic-btn {
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text-muted);
    padding: 12px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.2s;
}

.mic-btn:hover {
    color: var(--accent);
    border-color: var(--accent);
}

.mic-btn.recording {
    background: rgba(255, 0, 0, 0.2);
    border-color: #ff4444;
    color: #ff4444;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 68, 68, 0.4);
    }

    70% {
        transform: scale(1.05);
        box-shadow: 0 0 0 10px rgba(255, 68, 68, 0);
    }

    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 68, 68, 0);
    }
}