/* Vetiver Trace System - Custom Styles */

:root {
    --sidebar-width: 260px;
    --sidebar-bg: #1a1a2e;
    --primary-green: #198754;
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    background-color: #f8f9fa;
}

/* Sidebar */
#wrapper {
    min-height: 100vh;
}

.sidebar {
    width: var(--sidebar-width);
    min-height: 100vh;
    background: #212529 !important;
    position: fixed;
    top: 0;
    left: 0;
    height: 100%;
    z-index: 100;
    overflow-y: auto;
    transition: width 0.25s ease;
}

.sidebar .nav-link {
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    font-size: 0.875rem;
    transition: background 0.15s;
}

.sidebar .nav-link:hover {
    background: rgba(255,255,255,0.1);
}

.sidebar .nav-link.active {
    background: var(--primary-green);
}

.sidebar .sidebar-header {
    border-bottom: 1px solid rgba(255,255,255,0.1);
    margin-bottom: 0.5rem;
}

#page-content-wrapper {
    margin-left: var(--sidebar-width);
    min-height: 100vh;
    transition: margin-left 0.25s ease;
}

#wrapper.toggled .sidebar {
    width: 0;
    overflow: hidden;
}

#wrapper.toggled #page-content-wrapper {
    margin-left: 0;
}

/* Cards */
.card {
    border-radius: 12px;
}

.card-header {
    border-radius: 12px 12px 0 0 !important;
}

/* Tables */
.table th {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #6c757d;
    font-weight: 600;
}

/* Badges */
.badge {
    font-size: 0.72rem;
    padding: 0.35em 0.65em;
}

/* Navbar */
.navbar {
    box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}

/* Responsive */
@media (max-width: 768px) {
    .sidebar {
        width: 0;
        overflow: hidden;
    }
    #page-content-wrapper {
        margin-left: 0;
    }
    #wrapper.toggled .sidebar {
        width: var(--sidebar-width);
    }
}

/* Traceability chain */
.trace-chain {
    position: relative;
}
.trace-chain::before {
    content: '';
    position: absolute;
    left: 16px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: #dee2e6;
}
