/* 
 * LabXfer - Deep Tech UI/UX
 * Theme: Scientific, Industrial, Modern SaaS
 */

:root {
    --bg-main: #0f172a;       /* Slate 900 */
    --bg-surface: #1e293b;    /* Slate 800 */
    --bg-surface-hover: #334155; /* Slate 700 */
    --text-primary: #f8fafc;  /* Slate 50 */
    --text-secondary: #94a3b8;/* Slate 400 */
    --accent-primary: #06b6d4;/* Cyan 500 */
    --accent-hover: #0891b2;  /* Cyan 600 */
    --border-color: rgba(255, 255, 255, 0.1);
    --sidebar-width: 280px;
    --header-height: 70px;
    --transition-speed: 0.3s;
}

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

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-main);
    color: var(--text-primary);
    display: flex;
    min-height: 100vh;
    overflow-x: hidden;
    /* Add subtle grid background for Deep Tech feel */
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 30px 30px;
}

/* Layout */
.app-container {
    display: flex;
    width: 100%;
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    background: rgba(30, 41, 59, 0.95);
    backdrop-filter: blur(10px);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    transition: transform var(--transition-speed) ease;
    z-index: 1000;
    box-shadow: 4px 0 24px rgba(0,0,0,0.2);
}

.sidebar-header {
    height: var(--header-height);
    display: flex;
    align-items: center;
    padding: 0 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.sidebar-header h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
}

.sidebar-header h1 span {
    color: var(--accent-primary);
}

.sidebar-nav {
    flex: 1;
    padding: 1.5rem 0;
    overflow-y: auto;
}

.nav-section {
    padding: 1.5rem 1.75rem 0.75rem;
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 1px;
}

.nav-item {
    display: flex;
    align-items: center;
    padding: 0.85rem 1.75rem;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all var(--transition-speed) ease;
    gap: 1.25rem;
    font-weight: 500;
    font-size: 0.95rem;
}

.nav-item:hover, .nav-item.active {
    background: linear-gradient(90deg, rgba(6, 182, 212, 0.1) 0%, transparent 100%);
    color: var(--accent-primary);
    border-left: 4px solid var(--accent-primary);
}

.nav-item i {
    font-size: 1.1rem;
    width: 24px;
    text-align: center;
    transition: transform var(--transition-speed) ease;
}

.nav-item:hover i {
    transform: scale(1.1);
}

/* Main Content */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Header */
.top-header {
    height: var(--header-height);
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 2rem;
    position: sticky;
    top: 0;
    z-index: 999;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 1.5rem;
    cursor: pointer;
    transition: color 0.2s ease;
}

.menu-toggle:hover {
    color: var(--accent-primary);
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 1rem;
    cursor: pointer;
}

.user-info {
    text-align: right;
}

.user-name {
    font-size: 0.9rem;
    font-weight: 600;
}

.user-role {
    font-size: 0.75rem;
    color: var(--accent-primary);
}

.avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent-primary), #3b82f6);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    box-shadow: 0 0 15px rgba(6, 182, 212, 0.3);
}

/* Dashboard Content */
.content-area {
    padding: 2.5rem;
    flex: 1;
}

.page-title {
    margin-bottom: 2rem;
    font-size: 1.8rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.page-title i {
    color: var(--accent-primary);
}

/* Cards */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.75rem;
}

.card {
    background: rgba(30, 41, 59, 0.6);
    backdrop-filter: blur(10px);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1.75rem;
    transition: all var(--transition-speed) ease;
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: transparent;
    transition: background 0.3s ease;
}

.card:hover::before {
    background: var(--accent-primary);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.4), 0 0 15px rgba(6, 182, 212, 0.1);
    border-color: rgba(6, 182, 212, 0.3);
}

.card-header {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    margin-bottom: 1.25rem;
}

.card-icon {
    width: 54px;
    height: 54px;
    border-radius: 12px;
    background-color: rgba(6, 182, 212, 0.1);
    color: var(--accent-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    box-shadow: inset 0 0 10px rgba(6, 182, 212, 0.05);
}

.card-title {
    font-size: 1.15rem;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.card-body p {
    color: var(--text-secondary);
    line-height: 1.6;
    font-size: 0.95rem;
}

/* Utilities */
.text-gradient {
    background: linear-gradient(to right, #06b6d4, #3b82f6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Responsive */
@media (max-width: 992px) {
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar.open {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .menu-toggle {
        display: block;
    }
    
    .content-area {
        padding: 1.5rem;
    }
}
