@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&display=swap');

:root {
    /* Professional Monochrome Core */
    --primary: #000000;
    --primary-hover: #27272A;
    --primary-light: #F4F4F5;
    --primary-border: #E4E4E7;
    --primary-glow: rgba(0, 0, 0, 0.08);

    /* Backgrounds & Clean Surfaces */
    --bg: #F9FAFB;
    --bg-surface: #FFFFFF;
    --bg-subtle: #F4F4F5;
    --border: #E4E4E7;
    --border-subtle: #F4F4F5;

    /* Sidebar - Obsidian Pitch Black */
    --sidebar-bg: #09090B;
    --sidebar-surface: #18181B;
    --sidebar-border: rgba(255, 255, 255, 0.08);
    --sidebar-text: #A1A1AA;
    --sidebar-text-hover: #FFFFFF;
    --sidebar-text-active: #FFFFFF;
    --sidebar-active-bg: #18181B;
    --sidebar-width: 256px;
    --sidebar-width-collapsed: 74px;

    /* High-Contrast Typography */
    --text-primary: #09090B;
    --text-secondary: #52525B;
    --text-muted: #A1A1AA;

    /* Subtle Understated Semantic Accents (Refined, Not Loud) */
    --green: #15803D;
    --green-bg: #F0FDF4;
    --green-border: #BBF7D0;

    --red: #991B1B;
    --red-bg: #FEF2F2;
    --red-border: #FECACA;

    --orange: #B45309;
    --orange-bg: #FFFBEB;
    --orange-border: #FDE68A;

    --blue: #18181B;
    --blue-bg: #F4F4F5;
    --blue-border: #E4E4E7;

    --purple: #18181B;
    --purple-bg: #F4F4F5;
    --purple-border: #E4E4E7;

    --cyan: #27272A;
    --cyan-bg: #F4F4F5;
    --cyan-border: #E4E4E7;

    /* Shadows & Radii */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 14px;
    --radius-xl: 18px;
    --shadow-xs: 0 1px 2px 0 rgba(0, 0, 0, 0.04);
    --shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.06), 0 1px 2px -1px rgba(0, 0, 0, 0.03);
    --shadow-md: 0 4px 12px -2px rgba(0, 0, 0, 0.07), 0 2px 4px -2px rgba(0, 0, 0, 0.03);
    --shadow-lg: 0 12px 24px -4px rgba(0, 0, 0, 0.09), 0 4px 6px -2px rgba(0, 0, 0, 0.04);
    --transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

* { box-sizing: border-box; }

body {
    background: var(--bg);
    color: var(--text-primary);
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 13.5px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

a {
    color: var(--text-primary);
    text-decoration: none;
    transition: var(--transition);
}
a:hover {
    color: var(--primary-hover);
}

/* ---------------- Shell Layout ---------------- */
.app-shell {
    display: flex;
    min-height: 100vh;
    background: var(--bg);
}

.app-sidebar {
    width: var(--sidebar-width);
    background: var(--sidebar-bg);
    color: var(--sidebar-text);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0; left: 0; bottom: 0;
    z-index: 1020;
    transition: width 0.22s cubic-bezier(0.16, 1, 0.3, 1), transform 0.22s ease;
    overflow-y: auto;
    overflow-x: hidden;
    border-right: 1px solid var(--sidebar-border);
}

.app-sidebar::-webkit-scrollbar {
    width: 4px;
}
.app-sidebar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 4px;
}

.app-sidebar.collapsed {
    width: var(--sidebar-width-collapsed);
}
.app-sidebar.collapsed .sidebar-brand-text,
.app-sidebar.collapsed .nav-link span,
.app-sidebar.collapsed .nav-group-title,
.app-sidebar.collapsed .sidebar-user-info,
.app-sidebar.collapsed .sidebar-brand-switch,
.app-sidebar.collapsed .nav-badge {
    display: none !important;
}
.app-sidebar.collapsed .sidebar-nav .nav-link {
    justify-content: center;
    padding: 10px 0;
}
.app-sidebar.collapsed .sidebar-nav .nav-link i {
    font-size: 18px;
    margin: 0;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px 18px;
    font-weight: 700;
    color: #FFFFFF;
    font-size: 15.5px;
    letter-spacing: -0.02em;
    border-bottom: 1px solid var(--sidebar-border);
}
.sidebar-brand-icon {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    background: #18181B;
    border: 1px solid rgba(255, 255, 255, 0.16);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #FFFFFF;
    font-size: 16px;
    flex-shrink: 0;
}
.sidebar-brand-text {
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: -0.02em;
}
.sidebar-collapse-btn {
    margin-left: auto;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--sidebar-text);
    width: 26px;
    height: 26px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}
.sidebar-collapse-btn:hover {
    background: rgba(255, 255, 255, 0.14);
    color: #FFFFFF;
}

.sidebar-brand-switch {
    padding: 12px 14px;
    border-bottom: 1px solid var(--sidebar-border);
}
.sidebar-brand-switch select {
    background: #141416;
    color: #F8FAFC;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: var(--radius-md);
    font-size: 12px;
    font-weight: 500;
    padding: 7px 10px;
    transition: var(--transition);
}
.sidebar-brand-switch select:focus {
    background: #18181B;
    border-color: rgba(255, 255, 255, 0.3);
    outline: none;
    color: #fff;
}

.sidebar-nav {
    flex: 1;
    padding: 8px 10px;
}
.nav-group-title {
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.09em;
    color: #71717A;
    font-weight: 700;
    padding: 14px 10px 5px;
    display: flex;
    align-items: center;
}
.nav-group-title::after {
    content: '';
    flex: 1;
    height: 1px;
    background: rgba(255, 255, 255, 0.06);
    margin-left: 8px;
}

.sidebar-nav .nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--sidebar-text);
    padding: 8px 11px;
    font-size: 13px;
    font-weight: 500;
    border-radius: var(--radius-md);
    margin-bottom: 1px;
    transition: var(--transition);
    position: relative;
    border: 1px solid transparent;
}
.sidebar-nav .nav-link i {
    width: 18px;
    text-align: center;
    font-size: 15px;
    opacity: 0.8;
    transition: var(--transition);
}
.sidebar-nav .nav-link:hover {
    background: rgba(255, 255, 255, 0.06);
    color: #FFFFFF;
}
.sidebar-nav .nav-link:hover i {
    opacity: 1;
    color: #FFFFFF;
}
.sidebar-nav .nav-link.active {
    background: #18181B;
    color: #FFFFFF;
    font-weight: 600;
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
}
.sidebar-nav .nav-link.active i {
    color: #FFFFFF;
    opacity: 1;
}

.sidebar-footer {
    border-top: 1px solid var(--sidebar-border);
    padding: 12px 14px;
    background: #09090B;
}
.sidebar-user {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
    padding: 6px;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
}
.sidebar-user-info .name {
    color: #FFFFFF;
    font-size: 12.5px;
    font-weight: 600;
    line-height: 1.2;
}
.sidebar-user-info .role {
    font-size: 10.5px;
    color: #A1A1AA;
    margin-top: 2px;
}
.sidebar-footer .nav-link {
    padding: 6px 8px;
    border-radius: var(--radius-md);
}

.avatar-circle {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #09090B !important;
    color: #FFFFFF !important;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 12.5px;
    flex-shrink: 0;
    border: 1px solid #27272A;
}
.avatar-sm {
    width: 28px;
    height: 28px;
    font-size: 11.5px;
}

.app-main {
    margin-left: var(--sidebar-width);
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    transition: margin-left 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}
.app-sidebar.collapsed ~ .app-main {
    margin-left: var(--sidebar-width-collapsed);
}

/* ---------------- Topbar ---------------- */
.app-topbar {
    height: 64px;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 0 24px;
    position: sticky;
    top: 0;
    z-index: 1000;
}
.topbar-left {
    display: flex;
    flex-direction: column;
}
.topbar-breadcrumbs {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    color: var(--text-muted);
    font-weight: 500;
    margin-bottom: 1px;
}
.topbar-breadcrumbs a {
    color: var(--text-muted);
}
.topbar-breadcrumbs a:hover {
    color: var(--text-primary);
}
.topbar-title {
    font-size: 17.5px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
    letter-spacing: -0.025em;
    white-space: nowrap;
}
.topbar-toggle {
    background: none;
    border: none;
    font-size: 20px;
    color: var(--text-primary);
    cursor: pointer;
    padding: 4px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
}

.topbar-search {
    position: relative;
    flex: 1;
    max-width: 420px;
    margin-left: 18px;
}
.topbar-search i {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 13.5px;
}
.topbar-search input {
    width: 100%;
    border: 1px solid var(--border);
    background: var(--bg);
    border-radius: 9999px;
    padding: 8px 65px 8px 36px;
    font-size: 13px;
    transition: var(--transition);
}
.topbar-search input:focus {
    background: #FFFFFF;
    border-color: #000000;
    box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.08);
    outline: none;
}
.topbar-search .search-kbd {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 10.5px;
    background: #FFFFFF;
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 2px 6px;
    color: var(--text-muted);
    font-family: inherit;
    font-weight: 600;
    pointer-events: none;
}

.topbar-actions {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* ---------------- Black and White Core & Buttons ---------------- */
::selection {
    background: #000000;
    color: #FFFFFF;
}

a {
    color: #09090B;
    text-decoration: none;
    transition: var(--transition);
}
a:hover {
    color: #000000;
    text-decoration: underline;
}

.btn-primary, .btn-primary-gradient, .btn-dark {
    background: #000000 !important;
    color: #FFFFFF !important;
    border: 1px solid #000000 !important;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1) !important;
    font-weight: 600;
    border-radius: var(--radius-md);
    transition: var(--transition);
}
.btn-primary:hover, .btn-primary:focus, .btn-primary:active,
.btn-primary-gradient:hover, .btn-dark:hover, .btn-dark:focus, .btn-dark:active {
    background: #27272A !important;
    border-color: #27272A !important;
    color: #FFFFFF !important;
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.16) !important;
}

.btn-outline-dark, .btn-outline-secondary, .btn-outline-primary {
    background: #FFFFFF !important;
    color: #18181B !important;
    border: 1px solid #E4E4E7 !important;
    font-weight: 500;
    border-radius: var(--radius-md);
    transition: var(--transition);
}
.btn-outline-dark:hover, .btn-outline-secondary:hover, .btn-outline-primary:hover,
.btn-outline-dark:focus, .btn-outline-secondary:focus {
    background: #F4F4F5 !important;
    color: #000000 !important;
    border-color: #D4D4D8 !important;
}

.form-check-input:checked {
    background-color: #000000 !important;
    border-color: #000000 !important;
}
.form-check-input:focus {
    border-color: #000000;
    box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.1);
}

.badge.bg-primary {
    background-color: #18181B !important;
    color: #FFFFFF !important;
}
.badge.bg-dark {
    background-color: #09090B !important;
    color: #FFFFFF !important;
}

.topbar-icon-btn {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    font-size: 15px;
    position: relative;
    transition: var(--transition);
    cursor: pointer;
}
.topbar-icon-btn:hover {
    background: var(--bg-subtle);
    border-color: #D4D4D8;
}
.topbar-icon-btn .badge-dot {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #000000;
    border: 1.5px solid #FFFFFF;
}

.user-menu-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 3px 10px 3px 3px;
    background: #FFFFFF;
    border: 1px solid var(--border);
    border-radius: 9999px;
    cursor: pointer;
    transition: var(--transition);
}
.user-menu-btn:hover {
    border-color: #D4D4D8;
    background: var(--bg-subtle);
}
.user-menu-name {
    font-size: 12.5px;
    font-weight: 600;
    color: var(--text-primary);
    max-width: 120px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ---------------- Content Area ---------------- */
.app-content {
    padding: 24px 28px;
    flex: 1;
}

/* ---------------- Page Headers ---------------- */
.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 12px;
}
.page-header h2 {
    font-size: 21px;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0;
    letter-spacing: -0.025em;
}
.page-subtitle {
    color: var(--text-secondary);
    font-size: 13px;
    margin-top: 2px;
}

/* ---------------- Cards & Stat Widgets ---------------- */
.card {
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--bg-surface);
    box-shadow: var(--shadow-xs);
    transition: var(--transition);
}

.stat-card {
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 18px 20px;
    height: 100%;
    position: relative;
    box-shadow: var(--shadow-xs);
    transition: var(--transition);
    overflow: hidden;
}
.stat-card:hover {
    box-shadow: var(--shadow-sm);
    transform: translateY(-1px);
    border-color: #D4D4D8;
}
.stat-card .stat-label {
    font-size: 11px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-weight: 700;
    margin-bottom: 6px;
}
.stat-card .stat-value {
    font-size: 24px;
    font-weight: 800;
    color: var(--text-primary);
    letter-spacing: -0.03em;
    line-height: 1.1;
}
.stat-card .stat-sub {
    font-size: 11.5px;
    color: var(--text-secondary);
    margin-top: 5px;
    display: flex;
    align-items: center;
    gap: 4px;
}
.stat-card .stat-icon {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    background: #F4F4F5;
    border: 1px solid var(--border);
    color: #18181B;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}

/* ---------------- Soft Semantic & Monochrome Badges ---------------- */
.bg-soft-green { background: var(--green-bg); color: var(--green); border: 1px solid var(--green-border); }
.bg-soft-red { background: var(--red-bg); color: var(--red); border: 1px solid var(--red-border); }
.bg-soft-orange { background: var(--orange-bg); color: var(--orange); border: 1px solid var(--orange-border); }
.bg-soft-blue { background: #F4F4F5; color: #18181B; border: 1px solid var(--border); }
.bg-soft-purple { background: #F4F4F5; color: #18181B; border: 1px solid var(--border); }
.bg-soft-cyan { background: #F4F4F5; color: #18181B; border: 1px solid var(--border); }

.text-soft-green { color: var(--green) !important; }
.text-soft-red { color: var(--red) !important; }
.text-soft-orange { color: var(--orange) !important; }
.text-soft-blue { color: #18181B !important; }
.text-soft-purple { color: #18181B !important; }

.badge-status {
    font-weight: 600;
    font-size: 11.5px;
    padding: 3.5px 10px;
    border-radius: 9999px;
    text-transform: capitalize;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    line-height: 1.2;
}

/* ---------------- Professional Tables ---------------- */
.table-card {
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xs);
    overflow: hidden;
    margin-bottom: 20px;
}

.table-toolbar {
    display: flex;
    gap: 12px;
    padding: 14px 18px;
    border-bottom: 1px solid var(--border);
    flex-wrap: wrap;
    align-items: center;
    background: #FFFFFF;
}
.table-toolbar .search-box-wrap {
    position: relative;
    min-width: 240px;
    flex: 1;
    max-width: 340px;
}
.table-toolbar .search-box-wrap i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 13px;
}
.table-toolbar .search-box-wrap input {
    padding-left: 34px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background: var(--bg);
    font-size: 13px;
    transition: var(--transition);
}
.table-toolbar .search-box-wrap input:focus {
    background: #fff;
    border-color: #000000;
    box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.08);
}
.table-toolbar .form-select-sm {
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    background-color: var(--bg);
    font-size: 12.5px;
    font-weight: 500;
}

.table-responsive {
    margin: 0;
    overflow-x: auto;
}
.table-card .table {
    margin-bottom: 0;
    width: 100%;
}
.table-card thead th {
    background: #FAFAFA;
    font-size: 11px;
    text-transform: uppercase;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border);
    font-weight: 700;
    letter-spacing: 0.04em;
    white-space: nowrap;
    padding: 12px 18px;
    user-select: none;
}
.table-card thead th.sortable {
    cursor: pointer;
    transition: var(--transition);
}
.table-card thead th.sortable:hover {
    background: #F4F4F5;
    color: #000000;
}
.table-card thead th.sortable i {
    font-size: 11px;
    margin-left: 4px;
    opacity: 0.4;
}
.table-card thead th.sortable.sorted-asc i,
.table-card thead th.sortable.sorted-desc i {
    opacity: 1;
    color: #000000;
}

.table-card tbody td {
    vertical-align: middle;
    font-size: 13px;
    padding: 12px 18px;
    border-bottom: 1px solid var(--border-subtle);
    color: var(--text-primary);
}
.table-card tbody tr {
    transition: background-color 0.12s ease;
}
.table-card tbody tr:hover {
    background: #FAFAFB;
}
.table-card tbody tr:last-child td {
    border-bottom: none;
}

/* ---------------- Unified Pagination ---------------- */
.pagination-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 18px;
    border-top: 1px solid var(--border);
    background: #FFFFFF;
    flex-wrap: wrap;
    gap: 12px;
}
.pagination-info {
    font-size: 12.5px;
    color: var(--text-secondary);
}
.pagination-info span {
    color: #000000;
    font-weight: 600;
}
.pagination-controls {
    display: flex;
    align-items: center;
    gap: 5px;
}
.pagination-controls .btn-page {
    min-width: 30px;
    height: 30px;
    padding: 0 8px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: #FFFFFF;
    color: var(--text-primary);
    font-size: 12px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}
.pagination-controls .btn-page:hover:not(:disabled) {
    background: var(--bg-subtle);
    border-color: #D4D4D8;
}
.pagination-controls .btn-page.active {
    background: #000000;
    color: #FFFFFF;
    border-color: #000000;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}
.pagination-controls .btn-page:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

/* Bootstrap Pagination Monochrome Styling */
.pagination {
    margin-bottom: 0;
    gap: 4px;
}
.pagination .page-item .page-link {
    color: #18181B;
    background: #FFFFFF;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 12.5px;
    font-weight: 600;
    padding: 5px 10px;
    transition: var(--transition);
}
.pagination .page-item:not(.active):not(.disabled) .page-link:hover {
    background: #F4F4F5;
    border-color: #D4D4D8;
    color: #000000;
}
.pagination .page-item.active .page-link {
    background: #000000 !important;
    border-color: #000000 !important;
    color: #FFFFFF !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}
.pagination .page-item.disabled .page-link {
    color: #A1A1AA;
    background: #FAFAFA;
    border-color: var(--border-subtle);
    opacity: 0.6;
}

/* ---------------- Kanban Board ---------------- */
.kanban-board {
    display: flex;
    gap: 16px;
    overflow-x: auto;
    padding-bottom: 14px;
}
.kanban-col {
    flex: 0 0 280px;
    background: #F4F4F5;
    border-radius: var(--radius-lg);
    padding: 12px;
    min-height: 240px;
    border: 1px solid var(--border);
}
.kanban-col-title {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
    padding: 4px 6px 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.kanban-col-title .badge-count {
    background: #FFFFFF;
    padding: 1px 7px;
    border-radius: 9999px;
    font-size: 11px;
    border: 1px solid var(--border);
    color: #000;
    font-weight: 600;
}
.kanban-card {
    background: #FFFFFF;
    border-radius: var(--radius-md);
    padding: 12px 14px;
    margin-bottom: 8px;
    border: 1px solid var(--border);
    box-shadow: var(--shadow-xs);
    cursor: grab;
    font-size: 13px;
    transition: var(--transition);
}
.kanban-card:hover {
    box-shadow: var(--shadow-sm);
    border-color: #000000;
}
.kanban-card .kc-name {
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 3px;
}
.kanban-card .kc-meta {
    font-size: 11.5px;
    color: var(--text-secondary);
}

/* ---------------- Pipeline Funnel ---------------- */
.pipeline-row {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    margin-bottom: 20px;
    padding-bottom: 4px;
}
.pipeline-stage {
    flex: 1;
    min-width: 120px;
    text-align: center;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 16px 10px;
    cursor: pointer;
    box-shadow: var(--shadow-xs);
    transition: var(--transition);
}
.pipeline-stage:hover {
    border-color: #000000;
    box-shadow: var(--shadow-sm);
}
.pipeline-stage.active {
    border-color: #000000;
    background: #F4F4F5;
}
.pipeline-stage .ps-count {
    font-size: 24px;
    font-weight: 800;
    color: var(--text-primary);
}
.pipeline-stage .ps-label {
    font-size: 10.5px;
    color: var(--text-secondary);
    margin-top: 4px;
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 0.04em;
}

/* ---------------- Quick Add Hub ---------------- */
.quick-add-group-title {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-muted);
    font-weight: 700;
    margin-bottom: 10px;
}
.quick-add-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}
.quick-add-item {
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 16px 12px;
    text-align: center;
    color: var(--text-primary);
    font-size: 13px;
    font-weight: 600;
    background: #FFFFFF;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.quick-add-item i {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    background: #F4F4F5;
    border: 1px solid var(--border);
    color: #09090B;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 19px;
    transition: var(--transition);
}
.quick-add-item:hover {
    border-color: #000000;
    box-shadow: var(--shadow-sm);
    color: #000000;
}
.quick-add-item:hover i {
    background: #000000;
    color: #FFFFFF;
    border-color: #000000;
}

/* ---------------- Empty States ---------------- */
.empty-state {
    text-align: center;
    padding: 50px 20px;
    color: var(--text-secondary);
}
.empty-state-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--bg-subtle);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    color: var(--text-primary);
    margin: 0 auto 14px;
}
.empty-state h4 {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 6px;
}
.empty-state p {
    font-size: 13px;
    max-width: 400px;
    margin: 0 auto 16px;
    color: var(--text-secondary);
}

/* ---------------- Forms & Inputs ---------------- */
.form-section {
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 22px;
    margin-bottom: 20px;
    box-shadow: var(--shadow-xs);
}
.form-section-title {
    font-size: 14.5px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 16px;
    padding-bottom: 10px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 8px;
}
.form-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 5px;
}
.form-control, .form-select {
    border-radius: var(--radius-md);
    border: 1px solid var(--border);
    padding: 8.5px 12px;
    font-size: 13px;
    transition: var(--transition);
}
.form-control:focus, .form-select:focus {
    border-color: #000000;
    box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.08);
}

/* ---------------- Detail Tabs ---------------- */
.detail-tabs {
    border-bottom: 1px solid var(--border);
    margin-bottom: 20px;
    gap: 8px;
}
.detail-tabs .nav-link {
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 600;
    border: none;
    padding: 9px 15px;
    border-radius: var(--radius-md) var(--radius-md) 0 0;
    border-bottom: 2px solid transparent;
    transition: var(--transition);
}
.detail-tabs .nav-link:hover {
    color: var(--text-primary);
    background: var(--bg-subtle);
}
.detail-tabs .nav-link.active {
    color: #000000;
    border-bottom: 2px solid #000000;
    background: transparent;
    font-weight: 700;
}

/* ---------------- Auth ---------------- */
.auth-body {
    background: #09090B;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
}
.auth-wrap {
    width: 100%;
    max-width: 440px;
    padding: 24px;
}
.auth-card {
    background: #FFFFFF;
    border-radius: var(--radius-xl);
    padding: 38px 34px;
    box-shadow: 0 20px 40px -15px rgba(0, 0, 0, 0.4);
    border: 1px solid var(--border);
}
.auth-logo {
    width: 54px;
    height: 54px;
    border-radius: var(--radius-md);
    background: #09090B;
    border: 1px solid #27272A;
    color: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin: 0 auto 18px;
}

/* ---------------- Alerts center & items ---------------- */
.alert-item {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    padding: 13px 16px;
    border-bottom: 1px solid var(--border-subtle);
    transition: var(--transition);
}
.alert-item:hover {
    background: #FAFAFA;
}
.alert-item:last-child {
    border-bottom: none;
}
.alert-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-top: 5px;
    flex-shrink: 0;
    background: #09090B;
}
.alert-item .alert-title {
    font-weight: 600;
    font-size: 13px;
    color: var(--text-primary);
}
.alert-item .alert-meta {
    font-size: 11.5px;
    color: var(--text-secondary);
    margin-top: 2px;
}

/* ---------------- Responsive Styles ---------------- */
@media (max-width: 992px) {
    .app-sidebar {
        transform: translateX(-100%);
    }
    .app-sidebar.mobile-open {
        transform: translateX(0);
        box-shadow: 0 0 50px rgba(0, 0, 0, 0.5);
    }
    .app-main {
        margin-left: 0 !important;
    }
    .topbar-search {
        display: none;
    }
    .quick-add-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .app-content {
        padding: 16px 14px;
    }
}
