/* ============================================
   VibeManager — style.css
   Monotone minimal. Sidebar layout.
   ============================================ */

/* RESET & BASE */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html, body {
    height: 100%;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 14px;
    background: #0a0a0a;
    color: #e8e8e8;
    overflow: hidden;
}

a { cursor: pointer; text-decoration: none; color: inherit; }
button { cursor: pointer; border: none; background: none; font-family: inherit; font-size: inherit; }
textarea, input { font-family: inherit; font-size: inherit; }
.hidden { display: none !important; }

/* SCROLLBARS */
::-webkit-scrollbar { width: 4px; height: 4px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #333; border-radius: 2px; }
::-webkit-scrollbar-thumb:hover { background: #444; }

/* APP LAYOUT */
.app {
    display: flex;
    height: 100vh;
    height: 100dvh;
    overflow: hidden;
}

/* SIDEBAR */
.sidebar {
    width: 220px;
    min-width: 220px;
    background: #111;
    border-right: 1px solid #222;
    display: flex;
    flex-direction: column;
    height: 100%;
    z-index: 50;
    transition: transform 0.25s ease;
}

.sidebar-logo {
    padding: 20px;
    border-bottom: 1px solid #1e1e1e;
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    letter-spacing: -0.5px;
}

.logo-didgit {
    font-weight: 300;
    color: #666;
}

.sidebar-section {
    padding: 16px;
    border-bottom: 1px solid #1e1e1e;
}

.sidebar-section-label {
    font-size: 10px;
    font-weight: 600;
    color: #444;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 8px;
}

/* SITE SWITCHER */
.site-switcher {
    position: relative;
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 6px;
    padding: 8px 10px;
    cursor: pointer;
}

.site-current {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 12px;
    color: #ccc;
}

.site-menu {
    position: absolute;
    top: calc(100% + 5px);
    left: 0;
    right: 0;
    background: #1a1a1a;
    border: 1px solid #2a2a2a;
    border-radius: 6px;
    z-index: 100;
    box-shadow: 0 8px 24px rgba(0,0,0,0.4);
}

/* NAVIGATION */
.sidebar-nav {
    flex: 1;
    padding: 12px;
    overflow-y: auto;
}

.nav-item {
    padding: 10px;
    color: #666;
    border-radius: 6px;
    margin-bottom: 4px;
    cursor: pointer;
    transition: all 0.2s;
}

.nav-item:hover { background: #1a1a1a; color: #ccc; }
.nav-item.active { background: #1e1e1e; color: #fff; }

/* MAIN CONTENT */
.main {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: #0a0a0a;
}

.panel {
    display: none;
    flex-direction: column;
    height: 100%;
}

.panel.active { display: flex; }

.panel-header {
    padding: 24px;
    border-bottom: 1px solid #1a1a1a;
}

.panel-title { font-size: 16px; color: #fff; }
.panel-subtitle { font-size: 12px; color: #555; margin-top: 4px; }

/* CHAT AREA */
.chat-messages {
    flex: 1;
    padding: 24px;
    overflow-y: auto;
}

.chat-input-wrap {
    padding: 16px 24px;
    border-top: 1px solid #1a1a1a;
}

.chat-input-row {
    display: flex;
    background: #111;
    border: 1px solid #222;
    border-radius: 8px;
    padding: 8px;
}

#chat-input {
    flex: 1;
    background: transparent;
    border: none;
    color: #fff;
    resize: none;
    outline: none;
    padding: 8px;
}

.chat-send {
    width: 32px;
    height: 32px;
    background: #fff;
    color: #000;
    border-radius: 6px;
    font-weight: bold;
}

/* TERMINAL & SQL */
.terminal-output, .sql-result {
    flex: 1;
    padding: 20px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 12px;
    background: #0d0d0d;
    overflow-y: auto;
}

.terminal-input-row {
    display: flex;
    padding: 12px 20px;
    background: #111;
    border-top: 1px solid #1a1a1a;
}

.terminal-input {
    flex: 1;
    background: transparent;
    border: none;
    color: #fff;
    outline: none;
    margin: 0 10px;
}

/* BUTTONS */
.btn-primary {
    background: #fff;
    color: #000;
    padding: 8px 18px;
    border-radius: 6px;
    font-weight: 600;
}

/* MOBILE STYLES */
@media (max-width: 768px) {
    .sidebar {
        position: fixed;
        transform: translateX(-100%);
    }
    
    .sidebar.mobile-open { transform: translateX(0); }
    
    .mobile-header {
        display: flex;
        align-items: center;
        padding: 15px;
        background: #111;
        border-bottom: 1px solid #222;
    }
    
    .mobile-nav {
        display: flex;
        position: fixed;
        bottom: 0;
        width: 100%;
        background: #111;
        border-top: 1px solid #222;
        padding: 10px;
        justify-content: space-around;
    }
}