/* CorpPolicy — Client Portal CSS (extracted from header.php in E11-2B) */

:root {
            --primary: #6366f1;
            --primary-dark: #4f46e5;
            --primary-light: #818cf8;
            --success: #10b981;
            --warning: #f59e0b;
            --danger: #ef4444;
            --info: #3b82f6;
            --radius: 12px;
            --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
            --nav-height: 68px;
        }
        * { margin:0; padding:0; box-sizing:border-box; }
        body {
            font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
            padding-top: var(--nav-height);
            background: var(--bg-primary, #f0f2f5);
            color: var(--text-primary, #0a0a0f);
            transition: background 0.4s ease, color 0.4s ease;
            min-height: 100vh;
            -webkit-font-smoothing: antialiased;
            -moz-osx-font-smoothing: grayscale;
        }
        
        [data-theme="dark"] {
            --bg-primary: #07070e;
            --bg-secondary: #0e0e18;
            --bg-card: rgba(255,255,255,0.04);
            --bg-hover: rgba(255,255,255,0.06);
            --text-primary: #ffffff;
            --text-secondary: rgba(255,255,255,0.7);
            --text-muted: rgba(255,255,255,0.35);
            --border-color: rgba(255,255,255,0.06);
            --shadow: 0 8px 32px rgba(0,0,0,0.4);
            --nav-bg: rgba(17,24,39,0.98);
            --nav-border: rgba(55,65,81,0.5);
            --nav-text: #9ca3af;
            --nav-hover: #f3f4f6;
            --nav-shadow: 0 4px 30px rgba(0,0,0,0.4);
            --nav-active-bg: rgba(255,255,255,0.06);
        }
        [data-theme="light"] {
            --bg-primary: #f0f2f5;
            --bg-secondary: #e8eaed;
            --bg-card: rgba(255,255,255,0.6);
            --bg-hover: rgba(0,0,0,0.02);
            --text-primary: #0a0a0f;
            --text-secondary: rgba(0,0,0,0.7);
            --text-muted: rgba(0,0,0,0.35);
            --border-color: rgba(0,0,0,0.06);
            --shadow: 0 8px 32px rgba(0,0,0,0.06);
            --nav-bg: rgba(255,255,255,0.98);
            --nav-border: rgba(229,231,235,0.5);
            --nav-text: #6b7280;
            --nav-hover: #1f2937;
            --nav-shadow: 0 4px 30px rgba(0,0,0,0.08);
            --nav-active-bg: rgba(99,102,241,0.04);
        }

/* ==== BLOCK ==== */

.chat-whatsapp {
    display: flex;
    align-items: center;

    width: 100%;

    margin-top: 10px;
    padding: 10px 11px;

    gap: 9px;

    border: 1px solid rgba(37, 211, 102, .20);

    border-radius: 11px;

    background:
        linear-gradient(
            135deg,
            rgba(37, 211, 102, .08),
            rgba(37, 211, 102, .035)
        );

    color: inherit;

    text-decoration: none;

    transition:
        transform .2s ease,
        background .2s ease,
        border-color .2s ease,
        box-shadow .2s ease;
}


.chat-whatsapp:hover {
    transform: translateY(-1px);

    background:
        linear-gradient(
            135deg,
            rgba(37, 211, 102, .14),
            rgba(37, 211, 102, .055)
        );

    border-color:
        rgba(37, 211, 102, .38);

    box-shadow:
        0 7px 18px rgba(37, 211, 102, .10);

    color: inherit;
}


.chat-whatsapp-icon {
    width: 32px;
    height: 32px;

    flex: 0 0 32px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 9px;

    background: #25D366;

    color: #fff;

    font-size: 15px;

    box-shadow:
        0 4px 10px rgba(37, 211, 102, .20);
}


.chat-whatsapp-content {
    min-width: 0;

    display: flex;
    flex-direction: column;

    flex: 1;
}


.chat-whatsapp-content strong {
    font-size: 10px;

    line-height: 1.3;

    font-weight: 700;

    color: #1f2937;
}


.chat-whatsapp-content small {
    margin-top: 2px;

    font-size: 8px;

    line-height: 1.3;

    color: #6b7280;
}


.chat-whatsapp-arrow {
    font-size: 9px;

    color: #25D366;

    transition:
        transform .2s ease;
}


.chat-whatsapp:hover .chat-whatsapp-arrow {
    transform: translateX(3px);
}


.chat-security-note {
    display: flex;
    align-items: center;
    justify-content: center;

    gap: 5px;

    margin-top: 8px;

    font-size: 7px;

    line-height: 1.2;

    color: #94a3b8;
}


.chat-security-note i {
    font-size: 7px;
    color: #64748b;
}


@media (max-width: 480px) {

    .chat-whatsapp {
        padding: 9px 10px;
    }

    .chat-whatsapp-icon {
        width: 30px;
        height: 30px;
        flex-basis: 30px;
    }

    .chat-whatsapp-content strong {
        font-size: 9px;
    }

    .chat-whatsapp-content small {
        font-size: 7px;
    }

}
/* ── Enterprise Navigation ── */
.enterprise-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    background: var(--nav-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--nav-border);
    box-shadow: var(--nav-shadow);
    height: var(--nav-height);
}
.nav-inner {
    height: 100%;
    display: flex;
    align-items: center;
    padding: 0 20px;
    max-width: 1440px;
    margin: 0 auto;
    gap: 0;
}

/* ── Brand ── */
.nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    flex-shrink: 0;
    margin-right: 20px;
}
.brand-logo-img {
    height: 36px;
    width: auto;
    max-height: 36px;
    object-fit: contain;
    display: block;
    transition: var(--transition);
}

.brand-icon {
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 18px;
    box-shadow: 0 4px 12px rgba(99,102,241,0.3);
}
.brand-name {
    font-size: 18px;
    font-weight: 700;
    color: var(--nav-hover);
}
.brand-name span { color: var(--primary); }
.brand-version {
    font-size: 9px;
    color: var(--nav-text);
    background: var(--nav-border);
    padding: 2px 8px;
    border-radius: 10px;
    margin-left: 4px;
}
.brand-badge {
    font-size: 7px;
    padding: 1px 6px;
    border-radius: 10px;
    margin-left: 2px;
    text-transform: uppercase;
    font-weight: 700;
}
.brand-badge.env-development { background: #f59e0b; color: #fff; }
.brand-badge.env-staging { background: #3b82f6; color: #fff; }
.brand-badge.env-production { background: #10b981; color: #fff; }

/* ── Navigation Menu ── */
.nav-menu {
    display: flex;
    align-items: center;
    gap: 2px;
    flex: 1;
    overflow-x: auto;
    scrollbar-width: none;
}
.nav-menu::-webkit-scrollbar { display: none; }

.nav-item {
    padding: 6px 14px;
    border-radius: 8px;
    color: var(--nav-text);
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    border: none;
    background: none;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: var(--transition);
    white-space: nowrap;
    position: relative;
}
.nav-item:hover {
    background: var(--nav-active-bg);
    color: var(--primary);
}
.nav-item.active {
    background: rgba(99,102,241,0.12);
    color: var(--primary);
}
.nav-item.active::after {
    content: '';
    position: absolute;
    bottom: 2px;
    left: 50%;
    transform: translateX(-50%);
    width: 16px;
    height: 2.5px;
    background: var(--primary);
    border-radius: 2px;
}
.nav-item .mega-arrow {
    font-size: 8px;
    margin-left: 2px;
    transition: var(--transition);
}
.nav-item:hover .mega-arrow {
    transform: rotate(180deg);
}

/* ── Mega Menu ── */
.mega-dropdown {
    position: relative;
}
.mega-menu {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    left: 50%;
    transform: translateX(-50%);
    background: var(--nav-bg);
    backdrop-filter: blur(20px);
    border-radius: var(--radius);
    border: 1px solid var(--nav-border);
    box-shadow: 0 20px 60px rgba(0,0,0,0.15);
    padding: 16px 20px;
    min-width: 280px;
    z-index: 99999;
    animation: megaIn 0.25s ease;
}
.mega-dropdown:hover .mega-menu {
    display: block;
}
@keyframes megaIn {
    from { opacity: 0; transform: translateX(-50%) translateY(-12px) scale(0.97); }
    to { opacity: 1; transform: translateX(-50%) translateY(0) scale(1); }
}
.mega-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
}
.mega-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 12px;
    border-radius: 8px;
    text-decoration: none;
    color: var(--nav-text);
    transition: var(--transition);
}
.mega-item:hover {
    background: var(--nav-active-bg);
    color: var(--primary);
}
.mega-icon {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    background: var(--bg-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}
.mega-title {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-primary);
}

/* ── Right Section ── */
.nav-right {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-left: auto;
    flex-shrink: 0;
}

/* ── Search ── */
.nav-search { position: relative; }
.search-trigger {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: 50px;
    border: 1px solid var(--border-color);
    background: var(--bg-primary);
    color: var(--nav-text);
    cursor: pointer;
    transition: var(--transition);
    font-size: 13px;
}
.search-trigger:hover {
    border-color: var(--primary);
    color: var(--primary);
}
.search-shortcut {
    font-size: 9px;
    color: var(--text-muted);
    background: var(--bg-secondary);
    padding: 1px 6px;
    border-radius: 4px;
}
.search-dropdown {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    width: 480px;
    background: var(--nav-bg);
    border-radius: var(--radius);
    border: 1px solid var(--nav-border);
    box-shadow: 0 20px 60px rgba(0,0,0,0.12);
    padding: 12px;
    z-index: 99999;
    animation: fadeDown 0.2s ease;
}
@keyframes fadeDown {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}
.search-input-wrapper {
    display: flex;
    align-items: center;
    gap: 10px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    padding: 0 12px;
    background: var(--bg-primary);
}
.search-input-wrapper i { color: var(--text-muted); }
.search-input-wrapper input {
    flex: 1;
    padding: 10px 0;
    border: none;
    background: none;
    font-size: 14px;
    font-family: inherit;
    color: var(--text-primary);
    outline: none;
}
.search-input-wrapper input::placeholder { color: var(--text-muted); }
.search-close {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 4px;
    font-size: 16px;
}
.search-close:hover { color: var(--text-primary); }
.search-results { max-height: 300px; overflow-y: auto; margin-top: 10px; }
.search-hint {
    text-align: center;
    padding: 12px;
    color: var(--text-muted);
    font-size: 13px;
}
.search-hint i { margin-right: 6px; }
.search-result-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    color: var(--text-primary);
}
.search-result-item:hover { background: var(--nav-active-bg); }
.search-result-item i { color: var(--primary); width: 20px; }
.search-result-item .result-title { font-weight: 500; font-size: 13px; }
.search-result-item .result-desc { font-size: 11px; color: var(--text-muted); }
.search-empty {
    text-align: center;
    padding: 20px;
    color: var(--text-muted);
}

/* ── Quick Create ── */
.nav-quick-create {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: none;
    background: var(--primary);
    color: #fff;
    cursor: pointer;
    transition: var(--transition);
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.nav-quick-create:hover {
    transform: scale(1.05) rotate(90deg);
    box-shadow: 0 4px 15px rgba(99,102,241,0.4);
}

/* ── Profile ── */
.nav-profile {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 3px 10px 3px 3px;
    border-radius: 50px;
    border: none;
    background: none;
    cursor: pointer;
    transition: var(--transition);
}
.nav-profile:hover { background: var(--nav-active-bg); }
.nav-profile .avatar {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 12px;
    position: relative;
    flex-shrink: 0;
}
.online-dot {
    position: absolute;
    bottom: -1px;
    right: -1px;
    width: 10px;
    height: 10px;
    background: var(--success);
    border-radius: 50%;
    border: 2px solid var(--nav-bg);
    animation: pulse-dot 2s ease-in-out infinite;
}
@keyframes pulse-dot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(1.2); }
}
.nav-profile .profile-name {
    font-size: 13px;
    font-weight: 500;
    color: var(--nav-hover);
    white-space: nowrap;
}
.nav-profile i.fa-chevron-down {
    font-size: 10px;
    color: var(--text-muted);
}

/* ── Dropdowns ── */
.nav-dropdown { position: relative; }
.dropdown-content {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    background: var(--nav-bg);
    backdrop-filter: blur(20px);
    min-width: 220px;
    border-radius: var(--radius);
    box-shadow: 0 20px 60px rgba(0,0,0,0.12);
    border: 1px solid var(--nav-border);
    padding: 6px 0;
    z-index: 99999;
    animation: fadeDown 0.2s ease;
}
.dropdown-content.show { display: block; }
.dropdown-content a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 16px;
    color: var(--nav-text);
    text-decoration: none;
    font-size: 13px;
    transition: var(--transition);
}
.dropdown-content a:hover {
    background: var(--nav-active-bg);
    color: var(--primary);
}
.dropdown-content a i { width: 18px; color: var(--text-muted); }
.dropdown-content hr { margin: 4px 12px; border: none; border-top: 1px solid var(--nav-border); }

/* ── Profile Dropdown ── */
.profile-dropdown .dropdown-content { min-width: 260px; }
.profile-header {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 16px;
}
.profile-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--primary-light));
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 20px;
    flex-shrink: 0;
}
.profile-name-text {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 15px;
}
.profile-role-text {
    font-size: 12px;
    color: var(--text-muted);
}
.profile-status {
    font-size: 11px;
    color: var(--success);
    display: flex;
    align-items: center;
    gap: 4px;
}
.profile-code {
    font-size: 10px;
    color: var(--text-muted);
    background: var(--bg-primary);
    padding: 1px 8px;
    border-radius: 10px;
    margin-top: 2px;
}
.online-dot-small {
    width: 6px;
    height: 6px;
    background: var(--success);
    border-radius: 50%;
    display: inline-block;
    animation: pulse-dot 2s ease-in-out infinite;
}
.profile-stats {
    display: flex;
    gap: 16px;
    padding: 8px 16px;
}
.profile-stat {
    text-align: center;
    flex: 1;
}
.profile-stat-value {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}
.profile-stat-label {
    font-size: 9px;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.logout-link { color: var(--danger) !important; }
.logout-link:hover {
    background: rgba(239,68,68,0.08) !important;
    color: #dc2626 !important;
}

/* ── Notification Dropdown ── */
.notif-dropdown .dropdown-content {
    min-width: 340px;
    padding: 0;
}
.notif-header {
    display: flex;
    justify-content: space-between;
    padding: 10px 16px;
    border-bottom: 1px solid var(--nav-border);
    font-weight: 600;
    font-size: 14px;
    color: var(--text-primary);
}
.notif-mark-all {
    font-size: 12px;
    color: var(--primary);
    text-decoration: none;
    cursor: pointer;
}
.notif-list { max-height: 300px; overflow-y: auto; }
.notif-empty {
    padding: 20px;
    text-align: center;
    color: var(--text-muted);
    font-size: 13px;
}
.notif-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 16px;
    border-bottom: 1px solid var(--nav-border);
    cursor: pointer;
    transition: var(--transition);
}
.notif-item:hover { background: var(--nav-active-bg); }
.notif-item.unread { background: rgba(99,102,241,0.06); }
.notif-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(99,102,241,0.08);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 13px;
}
.notif-body { flex: 1; }
.notif-title { font-size: 13px; color: var(--text-primary); }
.notif-time { font-size: 11px; color: var(--text-muted); }
.notif-footer {
    padding: 8px 16px;
    border-top: 1px solid var(--nav-border);
    text-align: center;
}
.notif-footer a { color: var(--primary); text-decoration: none; font-size: 13px; }

/* ── Quick Create Modal ── */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(8px);
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}
.modal-container {
    background: var(--nav-bg);
    border-radius: var(--radius);
    max-width: 460px;
    width: 100%;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    overflow: hidden;
    animation: modalIn 0.3s ease;
}
@keyframes modalIn {
    from { opacity: 0; transform: scale(0.9) translateY(20px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}
.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 20px;
    border-bottom: 1px solid var(--border-color);
}
.modal-header h3 {
    font-size: 17px;
    font-weight: 600;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}
.modal-header h3 i { color: var(--primary); }
.modal-close {
    background: none;
    border: none;
    font-size: 28px;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0 4px;
    transition: var(--transition);
}
.modal-close:hover { color: var(--text-primary); transform: rotate(90deg); }
.modal-body { padding: 16px 20px 20px; }
.quick-create-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}
.quick-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-primary);
    transition: var(--transition);
    border: 1px solid transparent;
}
.quick-item:hover {
    background: var(--nav-active-bg);
    border-color: var(--border-color);
}
.quick-item-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    flex-shrink: 0;
}
.quick-item-title { font-weight: 600; font-size: 13px; }
.quick-item-desc { font-size: 11px; color: var(--text-muted); }

/* ── Chat Widget ── */
.chat-widget {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 99999;
}
.chat-toggle {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    box-shadow: 0 4px 20px rgba(99,102,241,0.4);
    transition: var(--transition);
    position: relative;
}
.chat-toggle:hover { transform: scale(1.05); }
.chat-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: var(--danger);
    color: #fff;
    font-size: 10px;
    font-weight: 600;
    min-width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}
.chat-box {
    display: none;
    position: absolute;
    bottom: 70px;
    right: 0;
    width: 360px;
    height: 460px;
    background: var(--nav-bg);
    border-radius: var(--radius);
    border: 1px solid var(--nav-border);
    box-shadow: 0 20px 60px rgba(0,0,0,0.15);
    overflow: hidden;
    animation: fadeDown 0.3s ease;
}
.chat-box.open { display: flex; flex-direction: column; }
.chat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 16px;
    border-bottom: 1px solid var(--nav-border);
    background: rgba(99,102,241,0.04);
}
.chat-header-info { display: flex; align-items: center; gap: 10px; }
.chat-status-dot.large {
    width: 12px;
    height: 12px;
    background: var(--success);
    border-radius: 50%;
    animation: pulse-dot 2s ease-in-out infinite;
    display: inline-block;
}
.chat-header-title { font-weight: 600; font-size: 14px; color: var(--text-primary); }
.chat-header-status { font-size: 11px; color: var(--text-muted); }
.chat-close {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 20px;
    padding: 4px;
    transition: var(--transition);
}
.chat-close:hover { color: var(--text-primary); }
.chat-messages {
    flex: 1;
    padding: 16px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
    background: var(--bg-primary);
}
.chat-message {
    max-width: 85%;
    animation: fadeDown 0.3s ease;
}
.chat-message.system {
    align-self: flex-start;
    background: var(--bg-card);
    border-radius: 12px 12px 12px 4px;
    padding: 10px 14px;
    border: 1px solid var(--border-color);
}
.chat-message.system .message-content { font-size: 13px; color: var(--text-primary); }
.chat-message.system .message-content i { color: var(--primary); margin-right: 6px; }
.chat-message .message-time { font-size: 10px; color: var(--text-muted); margin-top: 4px; }
.chat-input-area {
    padding: 12px 16px;
    border-top: 1px solid var(--nav-border);
    background: var(--nav-bg);
}
.chat-quick-replies {
    display: flex;
    gap: 6px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}
.quick-reply {
    padding: 4px 12px;
    border-radius: 50px;
    border: 1px solid var(--border-color);
    background: transparent;
    color: var(--text-secondary);
    font-size: 11px;
    cursor: pointer;
    transition: var(--transition);
    font-family: inherit;
}
.quick-reply:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: rgba(99,102,241,0.06);
}
.chat-input-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
}
.chat-input {
    flex: 1;
    padding: 8px 14px;
    border: 1px solid var(--border-color);
    border-radius: 50px;
    font-size: 13px;
    font-family: inherit;
    background: var(--bg-primary);
    color: var(--text-primary);
    outline: none;
    transition: var(--transition);
}
.chat-input:focus { border-color: var(--primary); }
.chat-input::placeholder { color: var(--text-muted); }
.chat-attach, .chat-send {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    font-size: 14px;
}
.chat-attach {
    background: transparent;
    color: var(--text-muted);
}
.chat-attach:hover { color: var(--primary); }
.chat-send {
    background: var(--primary);
    color: #fff;
}
.chat-send:hover { background: var(--primary-dark); transform: scale(1.05); }

/* ── Mobile Toggle ── */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 20px;
    color: var(--nav-text);
    cursor: pointer;
    padding: 4px;
}

/* ── Theme Toggle ── */
.theme-toggle {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: transparent;
    color: var(--nav-text);
    cursor: pointer;
    transition: var(--transition);
    font-size: 15px;
}
.theme-toggle:hover {
    background: var(--nav-active-bg);
    color: var(--primary);
}

/* ── Notifications Button ── */
.nav-notification {
    position: relative;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: transparent;
    color: var(--nav-text);
    cursor: pointer;
    transition: var(--transition);
    font-size: 16px;
}
.nav-notification:hover {
    background: var(--nav-active-bg);
    color: var(--primary);
}
.nav-notification .badge {
    position: absolute;
    top: -2px;
    right: -2px;
    background: var(--danger);
    color: #fff;
    font-size: 10px;
    font-weight: 600;
    min-width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ── Nav Chat Button ── */
.nav-chat {
    position: relative;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    background: transparent;
    color: var(--nav-text);
    cursor: pointer;
    transition: var(--transition);
    font-size: 16px;
}
.nav-chat:hover {
    background: var(--nav-active-bg);
    color: var(--primary);
}
.nav-chat .chat-status-dot {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 10px;
    height: 10px;
    background: var(--success);
    border-radius: 50%;
    border: 2px solid var(--nav-bg);
    animation: pulse-dot 2s ease-in-out infinite;
}

/* ── Responsive ── */
@media (max-width: 1200px) {
    .nav-item { font-size: 12px; padding: 5px 10px; }
    .nav-profile .profile-name { display: none; }
    .search-shortcut { display: none; }
}
@media (max-width: 1024px) {
    .nav-menu { gap: 0; }
    .nav-item { padding: 4px 8px; font-size: 11px; }
    .brand-version { display: none; }
    .nav-search .search-dropdown { width: 320px; right: -120px; }
    .search-trigger { padding: 4px 8px; }
}
@media (max-width: 768px) {
    .nav-toggle { display: block; }
    .nav-menu {
        display: none;
        position: fixed;
        top: var(--nav-height);
        left: 0;
        right: 0;
        background: var(--nav-bg);
        flex-direction: column;
        padding: 12px 16px;
        border-bottom: 1px solid var(--nav-border);
        box-shadow: var(--nav-shadow);
        max-height: 80vh;
        overflow-y: auto;
        z-index: 99999;
        gap: 4px;
    }
    .nav-menu.open { display: flex !important; }
    .nav-item { width: 100%; padding: 10px 14px; font-size: 14px; }
    .nav-item.active::after { display: none; }
    .nav-item .mega-arrow { margin-left: auto; }
    .nav-item:hover .mega-arrow { transform: rotate(180deg); }
    .mega-menu {
        display: none !important;
        position: relative !important;
        top: auto !important;
        left: auto !important;
        transform: none !important;
        min-width: auto !important;
        width: 100% !important;
        box-shadow: none !important;
        border: none !important;
        background: transparent !important;
        padding: 8px 0 !important;
        margin-left: 20px;
    }
    .mega-dropdown:hover .mega-menu { display: none !important; }
    .mega-menu.active { display: block !important; }
    .mega-grid { grid-template-columns: 1fr; }
    .nav-search .search-dropdown { width: 280px; right: -140px; }
    .chat-box { width: 300px; height: 400px; right: -40px; }
    .quick-create-body { grid-template-columns: 1fr; }
    .brand-badge { display: none; }
    .nav-profile .profile-name { display: none; }
}
@media (max-width: 480px) {
    .nav-inner { padding: 0 12px; }
    .brand-name { font-size: 15px; }
    .brand-logo-img {
    height: 36px;
    width: auto;
    max-height: 36px;
    object-fit: contain;
    display: block;
    transition: var(--transition);
}

.brand-icon { width: 30px; height: 30px; font-size: 14px; }
    .nav-right { gap: 2px; }
    .nav-quick-create { width: 30px; height: 30px; font-size: 12px; }
    .nav-notification, .theme-toggle, .nav-chat, .search-trigger { width: 30px; height: 30px; font-size: 13px; }
    .search-trigger { padding: 2px 6px; }
    .chat-box { width: 280px; height: 380px; right: -20px; }
    .chat-toggle { width: 48px; height: 48px; font-size: 20px; }
    .profile-dropdown .dropdown-content { min-width: 220px; right: -20px; }
}

/* ── Dark Theme ── */
[data-theme="dark"] .search-dropdown,
[data-theme="dark"] .dropdown-content,
[data-theme="dark"] .chat-box,
[data-theme="dark"] .modal-container {
    background: #1a1a2e;
    border-color: rgba(255,255,255,0.06);
}
[data-theme="dark"] .search-input-wrapper {
    background: rgba(255,255,255,0.06);
    border-color: rgba(255,255,255,0.08);
}
[data-theme="dark"] .search-input-wrapper input { color: #fff; }
[data-theme="dark"] .chat-messages { background: rgba(255,255,255,0.02); }
[data-theme="dark"] .chat-input { background: rgba(255,255,255,0.06); border-color: rgba(255,255,255,0.08); color: #fff; }
[data-theme="dark"] .quick-reply { border-color: rgba(255,255,255,0.08); color: rgba(255,255,255,0.6); }
[data-theme="dark"] .quick-reply:hover { border-color: var(--primary); color: var(--primary); }