:root {
    /* Color Palette - Minimals/Premium Style */
    --primary-color: #007BFF;
    /* A clean, vibrant blue */
    --primary-dark: #0056b3;
    --secondary-color: #6c757d;
    --success-color: #28a745;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #17a2b8;

    --bg-body: #f4f6f8;
    /* Light gray background for depth */
    --bg-white: #ffffff;
    --bg-sidebar: #1C2536;
    /* Dark sidebar for contrast */

    --text-primary: #121212;
    --text-secondary: #637381;
    --text-sidebar: #9DA4AE;

    --border-color: #e0e0e0;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-card: 0px 5px 22px 0px rgba(0, 0, 0, 0.04), 0px 0px 0px 0.5px rgba(0, 0, 0, 0.03);

    --font-family: 'DM Sans', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    --radius-md: 12px;
    --radius-sm: 8px;

    --transition-speed: 0.3s;
}

/* Reset & Base */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-family);
    background-color: var(--bg-body);
    color: var(--text-primary);
    line-height: 1.6;
    display: flex;
    min-height: 100vh;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color var(--transition-speed);
}

ul {
    list-style: none;
}

/* Layout */
.wrapper {
    display: flex;
    width: 100%;
}

/* Sidebar */
.sidebar {
    width: 280px;
    background-color: var(--bg-sidebar);
    color: var(--bg-white);
    display: flex;
    flex-direction: column;
    padding: 24px 16px;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
    z-index: 100;
}

.sidebar-brand {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 40px;
    padding-left: 16px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--bg-white);
}

.nav-menu {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.nav-item {
    border-radius: var(--radius-sm);
    transition: background-color var(--transition-speed);
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: var(--text-sidebar);
    font-weight: 500;
    font-size: 0.95rem;
}

.nav-link:hover,
.nav-item.active .nav-link {
    background-color: rgba(255, 255, 255, 0.08);
    /* Transparent Overlay */
    color: var(--bg-white);
    border-radius: var(--radius-sm);
}

.nav-link i {
    width: 20px;
    text-align: center;
}

/* Main Content */
.main-content {
    flex: 1;
    margin-left: 280px;
    /* Width of sidebar */
    display: flex;
    flex-direction: column;
}

/* Header */
.top-bar {
    height: 70px;
    background-color: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(6px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 40px;
    position: sticky;
    top: 0;
    z-index: 90;
    border-bottom: 1px solid dashed var(--border-color);
}

.user-menu {
    display: flex;
    gap: 20px;
    align-items: center;
}

.btn-logout {
    font-size: 0.9rem;
    color: var(--danger-color);
    font-weight: 600;
}

/* Page Content */
.content {
    padding: 40px;
    min-height: calc(100vh - 70px);
}

.page-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 24px;
}

/* Cards */
.card {
    background: var(--bg-white);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-card);
    padding: 24px;
    margin-bottom: 24px;
    border: none;
}

/* Forms */
.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.form-control {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 0.95rem;
    transition: all var(--transition-speed);
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.2);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.95rem;
    border: none;
    cursor: pointer;
    transition: all var(--transition-speed);
    gap: 8px;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    box-shadow: var(--shadow-md);
}

.btn-danger {
    background-color: var(--danger-color);
    color: white;
}

.btn-danger:hover {
    background-color: #c82333;
}

/* Tables */
.table-container {
    overflow-x: auto;
}

.table {
    width: 100%;
    border-collapse: collapse;
    width: 100%;
}

.table th,
.table td {
    padding: 16px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.table th {
    background-color: #fafafa;
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.table td {
    color: var(--text-primary);
    font-size: 0.95rem;
}

.table tbody tr:hover {
    background-color: #f9fafb;
}

/* Badges */
.badge {
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 700;
}

.badge-success {
    background-color: rgba(40, 167, 69, 0.1);
    color: var(--success-color);
}

.badge-danger {
    background-color: rgba(220, 53, 69, 0.1);
    color: var(--danger-color);
}

.badge-warning {
    background-color: rgba(255, 193, 7, 0.1);
    color: #B78103;
}

/* Utilities */
.text-right {
    text-align: right;
}

.mb-4 {
    margin-bottom: 24px;
}

.d-flex {
    display: flex;
}

.justify-between {
    justify-content: space-between;
}

.align-center {
    align-items: center;
}

.gap-2 {
    gap: 8px;
}

/* Grid for Dashboard */
.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.stat-card {
    text-align: center;
}

.stat-card h3 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.stat-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Tabs */
.tab-btn {
    padding: 12px 24px;
    border: none;
    background: transparent;
    cursor: pointer;
    font-weight: 500;
    font-size: 1rem;
    color: var(--text-secondary);
    border-bottom: 3px solid transparent;
    transition: all 0.3s;
    font-family: inherit;
}

/* Modals */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.3s;
}

.modal-content {
    background-color: #fefefe;
    margin: 10% auto;
    padding: 20px;
    border: 1px solid #888;
    border-radius: 12px;
    width: 500px;
    max-width: 90%;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.close:hover,
.close:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}

.tab-btn:focus {
    outline: none;
}

.tab-btn.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
    font-weight: 600;
}

.tab-btn:hover {
    color: var(--primary-color);
    background-color: rgba(0, 123, 255, 0.05);
}

.tab-content {
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

font-size: 2rem;
font-weight: 700;
color: var(--primary-color);
}

.stat-card p {
    color: var(--text-secondary);
}