@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;700&display=swap');

/* --- GLOBAL RESET --- */
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; outline: none; }
body {
    margin: 0; padding: 0; background-color: #0b0e11; color: white;
    font-family: 'Inter', sans-serif; display: flex; flex-direction: column;
    height: 100vh; overflow: hidden;
}
a { text-decoration: none; color: inherit; }

/* --- LAYOUT GRID --- */
.app-container { display: flex; width: 100%; height: 100%; }

/* --- SIDEBAR (Desktop) --- */
.sidebar {
    width: 260px; background: #161a22; border-right: 1px solid #2a2e39;
    display: flex; flex-direction: column; padding: 25px;
    flex-shrink: 0; 
}
.brand { font-size: 24px; font-weight: bold; color: white; margin-bottom: 40px; display: flex; align-items: center; gap: 10px; }
.brand span { color: #2962ff; }

.nav-link {
    display: flex; align-items: center; gap: 15px; padding: 12px 15px;
    color: #8b90a0; border-radius: 8px; margin-bottom: 5px; transition: 0.2s;
    font-size: 14px; font-weight: 500;
}
.nav-link:hover { background: rgba(255,255,255,0.05); color: white; }
.nav-link.active { background: #2962ff; color: white; }

/* --- MAIN CONTENT AREA --- */
.main-content { 
    flex: 1; overflow-y: auto; padding: 30px; position: relative; 
    background: #0b0e11; width: 100%;
}
.page-title { font-size: 24px; font-weight: bold; margin-bottom: 20px; }

/* --- CARDS & BOXES --- */
.card { background: #161a22; border: 1px solid #2a2e39; border-radius: 16px; padding: 20px; margin-bottom: 20px; }
.card-blue { background: linear-gradient(135deg, #1a237e, #0d47a1); border: none; }

/* --- FORMS & INPUTS --- */
.form-group { margin-bottom: 20px; width: 100%; }
.form-label { display: block; font-size: 12px; color: #888; margin-bottom: 8px; text-transform: uppercase; letter-spacing: 0.5px; }
.form-input, select {
    width: 100%; background: #0b0e11; border: 1px solid #333; color: white;
    padding: 16px; border-radius: 12px; font-size: 15px; 
}
.form-input:focus { border-color: #2962ff; }

/* --- BUTTONS --- */
.btn { width: 100%; padding: 16px; border: none; border-radius: 12px; font-size: 16px; font-weight: bold; cursor: pointer; transition: 0.2s; text-align: center; }
.btn-primary { background: #2962ff; color: white; }
.btn-primary:active { transform: scale(0.98); }
.btn-outline { background: transparent; border: 1px solid #444; color: white; }
.btn-green { background: #00c853; color: white; }
.btn-red { background: #d50000; color: white; }

/* --- AUTH PAGES --- */
.auth-layout {
    width: 100%; min-height: 100vh; display: flex; justify-content: center; align-items: center;
    background: radial-gradient(circle at top, #1a237e 0%, #0b0e11 70%);
    padding: 20px;
}
.auth-box { 
    width: 100%; max-width: 420px; 
    background: #161a22; padding: 40px 30px; border-radius: 20px; 
    text-align: center; border: 1px solid #333; box-shadow: 0 10px 40px rgba(0,0,0,0.6);
}

/* --- MOBILE SPECIFIC FIXES (Hamburger Logic) --- */
.mobile-header { display: none; } 
.menu-overlay { display: none; }
.mobile-nav { display: none; } /* Hiding Bottom Nav */

@media (max-width: 768px) {
    /* 1. RESET BODY */
    body { height: auto; min-height: 100vh; overflow-x: hidden; overflow-y: auto; }
    
    /* 2. LAYOUT */
    .app-container { flex-direction: column; height: 100vh; overflow: hidden; }

    /* 3. MOBILE HEADER (Top Bar) */
    .mobile-header {
        display: flex; align-items: center; justify-content: space-between;
        background: #161a22; padding: 15px 20px;
        border-bottom: 1px solid #2a2e39;
        position: sticky; top: 0; z-index: 50; flex-shrink: 0;
    }
    .burger-btn { font-size: 24px; color: white; cursor: pointer; }
    .mobile-logo { font-weight: bold; font-size: 18px; color: white; }
    .mobile-logo span { color: #2962ff; }

    /* 4. SIDEBAR AS DRAWER */
    .sidebar {
        display: flex !important; /* Force show */
        position: fixed; top: 0; left: -100%; /* Hide off-screen */
        width: 280px; height: 100%; z-index: 1000;
        transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: 5px 0 15px rgba(0,0,0,0.5);
    }
    .sidebar.active { left: 0; /* Slide in */ }

    /* 5. DARK OVERLAY */
    .menu-overlay {
        position: fixed; top: 0; left: 0; width: 100%; height: 100%;
        background: rgba(0,0,0,0.7); z-index: 900;
        backdrop-filter: blur(2px);
        display: none; 
    }
    .menu-overlay.active { display: block; }

    /* 6. AUTH BOX FIXES */
    .auth-layout { align-items: center; padding: 15px; background: #0b0e11; }
    .auth-box {
        width: 100% !important; max-width: 100% !important; 
        padding: 30px 20px !important; background: transparent !important; 
        border: none !important; box-shadow: none !important;
    }
    .form-input { padding: 18px !important; font-size: 16px !important; }

    /* 7. MAIN CONTENT */
    .main-content {
        padding: 15px !important;
        height: calc(100vh - 60px); 
    }
}