:root {
    --main-bg: #ffffff;
    --main-accent: #0081cf;
    --text-main: #2d3748;
    --text-muted: #3c3c3c;
    --nav-hover: #f1f5f9;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.04);
    --radius-lg: 16px;
}

body {
    font-family: 'Inter', sans-serif;
    margin: 0;
    background-color: #f8fafc;
}

/* ── LAYOUT ── */
.layout {
    height: 100vh;
    width: 100%;
    display: flex;
    flex-direction: row;
    overflow: hidden;
}

.sidebar {
    width: 260px;
    min-width: 260px;
    background-color: var(--main-bg);
    display: flex;
    flex-direction: column;
    box-shadow: 0.1rem 0 0.5rem rgba(0, 0, 0, 0.05);
    z-index: 10;
    border-right: 1px solid var(--border-color);
}

.main-section {
    height: 100vh;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.main-content {
    background-color: #f0f2f5;
    padding: 24px;
    flex-grow: 1;
    overflow-y: auto;
}

/* ── SIDEBAR ── */
.sidebar-head {
    height: 68px;
    display: flex;
    align-items: center;
    padding: 0 15px;
}

.navbar-brand {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.logo-image {
    width: 182px;
    height: auto;
}

.sidebar-nav-section {
    display: grid;
    grid-template-rows: auto 0fr;
    transition: grid-template-rows 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar-nav-section:hover {
    grid-template-rows: auto 1fr;
    background-color: var(--nav-hover);
}

.sidebar-nav-section > p {
    color: var(--text-muted);
    font-size: 1.20rem;
    padding: 15px 20px;
    margin: 0;
    cursor: pointer;
}

.sidebar-nav-wrapper {
    overflow: hidden;
}

.sidebar-nav {
    list-style: none;
    padding: 0 10px 10px 10px;
    margin: 0;
}

.nav-link {
    color: var(--text-main) !important;
    text-decoration: none;
    font-size: 0.9rem;
    padding: 10px 15px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.2s;
}

.nav-link i {
    color: var(--main-accent);
}

.nav-link:hover {
    background: #e0f2fe;
    color: var(--main-accent) !important;
    transform: translateX(5px);
}

/* ── TOP BAR ── */
.navbar {
    min-height: 68px;
    max-height: 68px;
    padding: 0 24px;
    background: #ffffff;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.navbar-container {
    width: 100%;
}

/* ── MODERN BREADCRUMBS ── */
.breadcrumbs {
    flex: 1;
    min-width: 0;
}

.breadcrumb-modern {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    list-style: none;
    padding: 0;
    margin: 0;
}

.breadcrumb-modern li {
    display: flex;
    align-items: center;
    font-size: 0.875rem;
}

.breadcrumb-modern li + li::before {
    content: "/";
    color: #cbd5e1;
    margin-right: 8px;
    font-weight: 300;
    font-size: 0.9rem;
}

.breadcrumb-modern li a {
    color: #64748b;
    text-decoration: none;
    font-weight: 500;
    padding: 4px 8px;
    border-radius: 6px;
    transition: all 0.15s;
    display: flex;
    align-items: center;
    gap: 4px;
}

.breadcrumb-modern li a i {
    font-size: 0.9rem;
    color: #94a3b8;
}

.breadcrumb-modern li a:hover {
    color: #0f172a;
    background: #f1f5f9;
}

.breadcrumb-modern li.active {
    color: #0f172a;
    font-weight: 600;
    padding: 4px 8px;
    background: #f1f5f9;
    border-radius: 6px;
}

/* ── TOP BAR ACTIONS ── */
.topbar-actions {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
}

.topbar-btn {
    width: 40px;
    height: 40px;
    border-radius: 40px;
    border: none;
    background: transparent;
    color: #475569;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s;
    position: relative;
}

.topbar-btn:hover {
    background: #f1f5f9;
    color: #0f172a;
}

.topbar-btn .notification-dot {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 8px;
    height: 8px;
    background: #ef4444;
    border-radius: 50%;
    border: 2px solid #ffffff;
}

.topbar-divider {
    width: 1px;
    height: 32px;
    background: var(--border-color);
    margin: 0 4px;
}

/* ── PROFILE DROPDOWN ── */
.profile-dropdown {
    position: relative;
}

.profile-widget {
    cursor: pointer;
    border: 1px solid var(--border-color);
    background: #f8fafc;
    transition: all 0.15s;
    user-select: none;
}

.profile-widget:hover {
    background: #f1f5f9;
    border-color: #cbd5e1;
}

.avatar-wrapper {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 2px solid #ffffff;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    flex-shrink: 0;
    overflow: hidden;
}

.avatar-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    background: #e2e8f0;
}

.role-badge {
    font-size: 0.7rem;
    padding: 0.2rem 0.7rem;
    background: #dbeafe;
    color: #2563eb;
    border: 1px solid #bfdbfe;
    font-weight: 500;
}

/* ── DROPDOWN MENU ── */
.dropdown-menu {
    min-width: 200px;
    padding: 0.5rem;
    margin-top: 8px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    box-shadow: 0 10px 40px rgba(0,0,0,0.08);
}

.dropdown-item {
    padding: 0.6rem 1rem;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-main);
    transition: all 0.15s;
}

.dropdown-item:hover {
    background: #f1f5f9;
    color: #0f172a;
}

.dropdown-item.text-danger:hover {
    background: #fef2f2;
    color: #dc2626 !important;
}

.dropdown-item i {
    width: 20px;
    text-align: center;
}

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
    .navbar {
        padding: 0 16px;
    }

    .breadcrumb-modern li {
        font-size: 0.8rem;
    }

    .breadcrumb-modern li a {
        padding: 2px 6px;
    }

    .topbar-actions .topbar-btn:not(.profile-dropdown .topbar-btn) {
        display: none;
    }

    .main-content {
        padding: 16px;
    }
}

@media (max-width: 576px) {
    .profile-widget .text-end {
        display: none !important;
    }

    .breadcrumb-modern li + li::before {
        margin-right: 4px;
    }

    .breadcrumb-modern li a i {
        display: none;
    }
}