:root {
    --primary: #4f46e5;
    --primary-hover: #4338ca;
    --primary-light: #eef2ff;
    --secondary: #0f172a;
    --sidebar-bg: #0f172a;
    --sidebar-hover: #1e293b;
    --sidebar-active: #312e81;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --bg-page: #f8fafc;
    --card-bg: #ffffff;
    --border-color: #e2e8f0;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --info: #0ea5e9;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--bg-page);
    color: var(--text-main);
    min-height: 100vh;
}

/* Sidebar Styling */
#sidebar {
    min-width: 260px;
    max-width: 260px;
    background-color: var(--sidebar-bg);
    min-height: 100vh;
    color: #cbd5e1;
    transition: all 0.3s;
}

#sidebar .nav-link {
    color: #94a3b8;
    padding: 0.75rem 1.25rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    border-radius: 8px;
    margin: 2px 10px;
    transition: all 0.2s ease-in-out;
}

#sidebar .nav-link i {
    font-size: 1.15rem;
    margin-right: 0.75rem;
    width: 20px;
    text-align: center;
}

#sidebar .nav-link:hover {
    color: #f8fafc;
    background-color: var(--sidebar-hover);
}

#sidebar .nav-link.active {
    color: #ffffff;
    background-color: var(--primary);
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.35);
}

/* Brand Header in Sidebar */
.sidebar-brand {
    padding: 1.25rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-brand img {
    height: 38px;
    width: 38px;
    border-radius: 8px;
    object-fit: cover;
}

.sidebar-brand .brand-text {
    font-size: 1.05rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    color: #ffffff;
}

/* Cards & Content */
.card {
    border: 1px solid var(--border-color);
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
    background-color: var(--card-bg);
}

.card-header {
    background-color: transparent;
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 1.25rem;
    font-weight: 600;
}

/* Metric / Stat Cards */
.stat-card {
    border-radius: 12px;
    padding: 1.25rem;
    background: #ffffff;
    border: 1px solid var(--border-color);
    transition: transform 0.2s, box-shadow 0.2s;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
}

.stat-icon {
    width: 46px;
    height: 46px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
}

.stat-label {
    font-size: 0.825rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
}

.stat-value {
    font-size: 1.65rem;
    font-weight: 700;
    color: var(--text-main);
    line-height: 1.2;
}

/* Table Design */
.table th {
    font-size: 0.775rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    background-color: #f8fafc;
    border-bottom: 1px solid var(--border-color);
    padding: 0.75rem 1rem;
}

.table td {
    padding: 0.85rem 1rem;
    vertical-align: middle;
    border-bottom: 1px solid #f1f5f9;
    font-size: 0.9rem;
}

/* Status Badges */
.badge-status {
    padding: 0.35rem 0.65rem;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 50px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.badge-status-completed {
    background-color: #dcfce7;
    color: #15803d;
}

.badge-status-started {
    background-color: #e0f2fe;
    color: #0369a1;
}

.badge-status-terminated {
    background-color: #fee2e2;
    color: #b91c1c;
}

.badge-status-quotafull {
    background-color: #fef3c7;
    color: #b45309;
}

.badge-status-security {
    background-color: #f3e8ff;
    color: #7e22ce;
}

/* Links & Copy Buttons */
.link-box {
    background-color: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 0.5rem 0.75rem;
    font-family: SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
    font-size: 0.85rem;
    word-break: break-all;
}

.btn-copy {
    border-radius: 6px;
    padding: 0.35rem 0.75rem;
    font-size: 0.8rem;
    font-weight: 600;
}

/* Guest / Setup / Public Layout */
.guest-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    background: radial-gradient(circle at top, #1e1b4b 0%, #0f172a 100%);
}

.guest-card {
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25);
    max-width: 520px;
    width: 100%;
    padding: 2.5rem;
}
