/* ==========================================================================
   TELNET NETWORK MONITOR - MAIN STYLES & THEME SYSTEM
   ========================================================================== */

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

:root {
    /* FONTS */
    --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-body: 'Outfit', -apple-system, BlinkMacSystemFont, sans-serif;

    /* TELNET LIGHT THEME (DEFAULT) */
    --bg-app: #F7F9FC;
    --bg-card: #ffffff;
    --bg-sidebar: #ffffff;
    --bg-topbar: #ffffff;
    --border-color: rgba(226, 232, 240, 0.6);
    
    --text-primary: #051d38;
    --text-secondary: #051d38;
    --text-muted: #051d38;
    --text-sidebar: #051d38;
    --text-sidebar-active: #ffffff;

    --brand-navy: #051d38;
    --brand-navy-light: #002B49;

/* Override Bootstrap text colors to use Brand Navy */
body { color: var(--brand-navy) !important; }
.text-dark { color: var(--brand-navy) !important; }
.text-secondary { color: var(--brand-navy) !important; }
.text-muted { color: var(--brand-navy) !important; }
    --brand-green: #a2cc27;
    --brand-green-hover: #8fb322;
    --brand-green-bg: rgba(162, 204, 39, 0.1);
    --brand-green-border: rgba(162, 204, 39, 0.3);

    --brand-orange: #d97706;
    --brand-orange-bg: #fef3c7;

    --accent-blue: #2563eb;
    --accent-blue-bg: #eff6ff;
    --accent-amber: #d97706;
    --accent-amber-bg: #fffbeb;
    --accent-red: #dc2626;
    --accent-red-bg: #fef2f2;
    --accent-purple: #7c3aed;
    --accent-purple-bg: #f5f3ff;

    --input-bg: #f1f5f9;
    --input-border: #cbd5e1;
    --shadow-sm: 0 2px 8px rgba(15, 23, 42, 0.04);
    --shadow-md: 0 8px 24px rgba(15, 23, 42, 0.06);
    --shadow-lg: 0 16px 32px rgba(15, 23, 42, 0.08);
}

/* DARK THEME OVERRIDES */
body.dark-mode {
    --bg-app: #090d16;
    --bg-card: #111927;
    --bg-sidebar: #0b111e;
    --bg-topbar: #111927;
    --border-color: #1e293b;

    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --text-sidebar: #94a3b8;
    --text-sidebar-active: #ffffff;

    --brand-navy: #3b82f6;
    --brand-navy-light: #1d4ed8;
    --brand-green: #b2d942;
    --brand-green-hover: #a2cc27;
    --brand-green-bg: rgba(178, 217, 66, 0.12);
    --brand-green-border: rgba(178, 217, 66, 0.25);

    --accent-blue: #60a5fa;
    --accent-blue-bg: rgba(96, 165, 250, 0.12);
    --accent-amber: #fbbf24;
    --accent-amber-bg: rgba(251, 191, 36, 0.12);
    --accent-red: #f87171;
    --accent-red-bg: rgba(248, 113, 113, 0.12);
    --accent-purple: #c084fc;
    --accent-purple-bg: rgba(192, 132, 252, 0.12);

    --input-bg: #1e293b;
    --input-border: #334155;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 12px 30px rgba(0, 0, 0, 0.4);
}

/* BASE RESET */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Outfit', sans-serif !important;
}

* {
    font-family: inherit;
}

i, .bi, [class^="bi-"]::before, [class*=" bi-"]::before {
    font-family: bootstrap-icons !important;
}

body, html {
    margin: 0;
    padding: 0;
    height: 100%;
    overflow: visible;
}

body {
    background-color: var(--bg-app);
    color: var(--text-primary);
    font-size: 14px;
    min-height: 100vh;
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Custom Checkbox Colors */
.form-check-input:checked {
    background-color: var(--brand-navy) !important;
    border-color: var(--brand-navy) !important;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    font-weight: 700;
}

/* APP LAYOUT */
.app-container {
    display: flex;
    height: 100vh;
    width: 100%;
    overflow: visible;
}

/* SIDEBAR */
.sidebar-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: 76px;
    background-color: var(--bg-sidebar);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    transition: width 0.3s ease;
    z-index: 1000;
}
.sidebar-wrapper:hover {
    width: 260px;
}

@media (min-width: 993px) {
    .sidebar-wrapper:hover ~ .main-wrapper {
        margin-left: 260px;
    }
}


.sidebar-header {
    padding: 22px 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-brand-logo {
    max-height: 48px;
    max-width: 100%;
    width: auto;
    object-fit: contain;
}

.sidebar-brand-text {
    font-family: var(--font-heading);
    font-size: 15px;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: 0.5px;
    line-height: 1.1;
}

.sidebar-brand-text span {
    font-size: 10px;
    display: block;
    color: #94a3b8;
    font-weight: 500;
    letter-spacing: 0;
}

.sidebar-nav {
    flex: 1;
    padding: 16px 12px;
    overflow-y: auto;
    -ms-overflow-style: none;  /* IE and Edge */
    scrollbar-width: none;  /* Firefox */
}
.sidebar-nav::-webkit-scrollbar {
    display: none; /* Chrome, Safari and Opera */
}

.nav-section-title {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: #64748b;
    padding: 14px 12px 6px;
}

.rotate-icon {
    transform: rotate(-90deg);
}

.nav-item-link {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 10px 14px;
    color: var(--text-sidebar);
    text-decoration: none;
    font-size: 13.5px;
    font-weight: 500;
    border-radius: 8px;
    margin-bottom: 3px;
    transition: all 0.2s ease;
    cursor: pointer;
}
.sidebar-wrapper:hover .nav-item-link {
    justify-content: flex-start;
}

.nav-item-link:hover {
    color: var(--brand-navy);
    background-color: rgba(0, 0, 0, 0.05);
}

.nav-item-link.active {
    color: #ffffff;
    background-color: var(--brand-green);
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(97, 141, 30, 0.35);
}

.nav-item-link i {
    font-size: 17px;
    width: 22px;
    text-align: center;
}

.sidebar-footer {
    padding: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* MAIN CONTENT CONTAINER */
.main-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    min-height: 0;
    margin-left: 76px;
    height: 100%;
    overflow: visible;
    transition: margin-left 0.3s ease;
}

/* TOPBAR */
.topbar-wrapper {
    background-color: var(--bg-topbar);
    border-bottom: 1px solid var(--border-color);
    padding: 14px 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: var(--shadow-sm);
    z-index: 90;
    flex-shrink: 0;
}

.topbar-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.topbar-title-box h2 {
    font-size: 19px;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0;
}

.topbar-title-box small {
    font-size: 12px;
    color: var(--text-secondary);
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* TOPBAR BUTTONS */
.icon-btn-pill {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background-color: var(--input-bg);
    border: 1px solid var(--input-border);
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.icon-btn-pill:hover {
    color: var(--brand-navy);
    border-color: var(--brand-navy);
    background-color: var(--bg-card);
}

.user-profile-badge {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 14px 6px 8px;
    border-radius: 10px;
    background-color: var(--input-bg);
    border: 1px solid var(--input-border);
    cursor: pointer;
    transition: all 0.2s ease;
}

.user-profile-badge:hover {
    border-color: var(--brand-navy);
}

.avatar-circle-sm {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: linear-gradient(135deg, #618d1e, #051d38);
    color: #ffffff;
    font-size: 12px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* PAGE CONTENT VIEWS */
.content-body {
    padding: 24px 28px;
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    min-height: 0;
}

.page-view {
    display: none;
    animation: fadeIn 0.25s ease-in-out;
}

.page-view.active-view {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}

/* DASHBOARD CARDS & WIDGETS */
.dash-card {
    background-color: var(--bg-card);
    border: none;
    border-radius: 20px;
    padding: 24px;
    box-shadow: var(--shadow-sm);
    margin-bottom: 24px;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: visible;
    min-width: 0;
}

@media (max-width: 768px) {
    .dash-card {
        padding: 12px;
        margin-bottom: 12px;
    }
}

.dash-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.border-accent-red { border-bottom: 4px solid var(--accent-red) !important; }
.border-accent-amber { border-bottom: 4px solid var(--accent-amber) !important; }
.border-accent-green { border-bottom: 4px solid var(--brand-green) !important; }
.border-accent-blue { border-bottom: 4px solid var(--accent-blue) !important; }

.dash-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
}

.dash-card-title {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 8px;
}

/* METRIC STAT CARDS */
.metric-box {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 14px;
    padding: 20px;
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    gap: 16px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.metric-box:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.metric-icon-circle {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
}

.metric-label {
    font-size: 12.5px;
    color: var(--text-secondary);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.metric-value {
    font-family: var(--font-heading);
    font-size: 24px;
    font-weight: 800;
    color: var(--text-primary);
    margin-top: 2px;
}

/* TABLES */
.custom-table-responsive {
    width: 100%;
    overflow-x: visible;
}

@media (max-width: 991.98px) {
    .custom-table-responsive {
        overflow-x: auto;
    }
}

.custom-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13.5px;
}

.custom-table th {
    background-color: var(--input-bg);
    color: var(--text-secondary);
    font-weight: 700;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 12px 16px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.custom-table td {
    padding: 14px 16px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-primary);
}

.custom-table tbody tr:hover {
    background-color: rgba(97, 141, 30, 0.04);
}

/* BADGES & PILLS */
.status-pill {
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11.5px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.status-pill-success {
    background-color: var(--brand-green-bg);
    color: var(--brand-green);
    border: 1px solid var(--brand-green-border);
}

.status-pill-warning {
    background-color: var(--accent-amber-bg);
    color: var(--accent-amber);
    border: 1px solid rgba(245, 158, 11, 0.25);
}

.status-pill-danger {
    background-color: var(--accent-red-bg);
    color: var(--accent-red);
    border: 1px solid rgba(239, 68, 68, 0.25);
}

.status-pill-blue {
    background-color: var(--accent-blue-bg);
    color: var(--accent-blue);
    border: 1px solid rgba(59, 130, 246, 0.25);
}

/* RESPONSIVE & COLLAPSE LOGIC */
.sidebar-brand-text, .nav-section-title, .nav-item-link span, .sidebar-footer span {
    display: none !important;
}

.sidebar-wrapper:hover .sidebar-brand-text,
.sidebar-wrapper:hover .nav-item-link span,
.sidebar-wrapper:hover .sidebar-footer span {
    display: block !important;
}
.sidebar-wrapper:hover .nav-section-title {
    display: flex !important;
}

@media (max-width: 992px) {
    .sidebar-wrapper {
        position: fixed;
        left: -260px;
        width: 260px !important;
        z-index: 1050;
        transition: left 0.3s ease;
    }
    .sidebar-wrapper.mobile-show {
        left: 0;
    }
    .main-wrapper {
        margin-left: 0 !important;
        width: 100%;
    }
    .sidebar-brand-text,
    .nav-section-title,
    .nav-item-link span,
    .sidebar-footer span {
        display: block !important;
    }
    .nav-item-link {
        justify-content: flex-start !important;
    }
}

/* COMPACT DASHBOARD STYLES */
.metric-box-sm {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 12px;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.metric-box-sm:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}
.metric-label-sm {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.metric-value-sm {
    font-family: var(--font-heading);
    font-size: 18px;
    font-weight: 800;
    color: var(--brand-navy);
}
.table-compact th {
    font-size: 12.5px;
    padding: 10px 12px;
    background-color: transparent !important;
    border-bottom: 1px solid var(--border-color) !important;
}
.table-compact td {
    font-size: 14px;
    padding: 10px 12px;
    border-bottom: 1px solid var(--border-color) !important;
}
.status-pill-secondary {
    background-color: rgba(148, 163, 184, 0.1);
    color: #94a3b8;
    border: 1px solid rgba(148, 163, 184, 0.25);
}

/* CUSTOM PAGINATION */
.custom-pagination {
    display: flex;
    gap: 4px;
    align-items: center;
}
.custom-pagination .page-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    padding: 0 10px;
    background-color: #ffffff;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
}
.custom-pagination .page-btn:hover:not(.disabled):not(.active) {
    background-color: #f1f5f9;
}
.custom-pagination .page-btn.active {
    background-color: var(--brand-navy);
    color: #ffffff;
    border-color: var(--brand-navy);
}
.custom-pagination .page-btn.disabled {
    color: #cbd5e1;
    cursor: not-allowed;
    background-color: #ffffff;
}

/* CUSTOM PAGINATION */
.custom-pagination {
    display: flex;
    gap: 4px;
    align-items: center;
}
.custom-pagination .page-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    padding: 0 10px;
    background-color: #ffffff;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 500;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
}
.custom-pagination .page-btn:hover:not(.disabled):not(.active) {
    background-color: #f1f5f9;
}
.custom-pagination .page-btn.active {
    background-color: var(--brand-navy);
    color: #ffffff;
    border-color: var(--brand-navy);
}
.custom-pagination .page-btn.disabled {
    color: #cbd5e1;
    cursor: not-allowed;
    background-color: #ffffff;
}

/* CUSTOM DROPDOWN STYLING */
.dropdown-menu {
    border-radius: 8px;
}
.dropdown-item.active, .dropdown-item:active {
    background-color: var(--brand-navy);
    color: #ffffff;
}
.dropdown-item:hover {
    background-color: #f1f5f9;
}
.custom-dropdown-btn:hover {
    background-color: #f1f5f9;
    border-radius: 4px;
}

/* Custom Dropdown Active and Focus States */
.dropdown-item.active, .dropdown-item:active {
    background-color: var(--brand-navy) !important;
    color: #ffffff !important;
}

/* =========================================================
   GLOBAL BULLETPROOF DROPDOWN OVERFLOW FIX
   Applies to ALL dropdown toggles to guarantee they NEVER overflow 
   and ALWAYS truncate properly, regardless of internal HTML structure.
   ========================================================= */
.dropdown-toggle {
    display: block !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    padding-right: 25px !important;
    position: relative !important;
    text-align: left !important;
}

/* Force the caret to always stay safely inside the right edge */
.dropdown-toggle::after {
    position: absolute !important;
    right: 12px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
}

/* Force any inner wrappers (divs/spans) to truncate and behave as inline-blocks */
.dropdown-toggle > div,
.dropdown-toggle > span {
    display: inline-block !important;
    max-width: calc(100% - 5px) !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
    vertical-align: middle !important;
}

/* Ensure icons stay perfectly aligned */
.dropdown-toggle i {
    vertical-align: middle !important;
}

.dropdown-item.active i, .dropdown-item:active i {
    color: #ffffff !important;
}

/* Make keyboard focus and mouse hover look like active state */
.dropdown-item:focus, .dropdown-item:hover {
    background-color: var(--brand-navy) !important;
    color: #ffffff !important;
    outline: none !important;
    box-shadow: none !important;
}
.dropdown-item:focus i, .dropdown-item:hover i {
    color: #ffffff !important;
}

/* If user focuses/hovers on any item, remove active style from currently selected item so blue color "moves" */
.dropdown-menu:has(.dropdown-item:focus) .dropdown-item.active:not(:focus),
.dropdown-menu:has(.dropdown-item:hover) .dropdown-item.active:not(:hover) {
    background-color: transparent !important;
    color: var(--bs-dropdown-link-color, inherit) !important;
}
.dropdown-menu:has(.dropdown-item:focus) .dropdown-item.active:not(:focus) i,
.dropdown-menu:has(.dropdown-item:hover) .dropdown-item.active:not(:hover) i {
    color: var(--bs-secondary, gray) !important;
}

/* ==========================================================================
   SWEETALERT2 CUSTOMIZATION (PREMIUM LOOK)
   ========================================================================== */
.swal2-popup {
    font-family: 'Poppins', sans-serif !important;
    border-radius: 16px !important;
    padding: 2em !important;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1) !important;
}

.swal2-title {
    font-weight: 600 !important;
    color: var(--brand-navy) !important;
}

.swal2-html-container {
    color: var(--text-secondary) !important;
    font-size: 15px !important;
    font-weight: 400 !important;
}

.swal2-confirm, .swal2-cancel {
    border-radius: 8px !important;
    font-weight: 500 !important;
    padding: 10px 24px !important;
    box-shadow: none !important;
}

.swal2-confirm:focus, .swal2-cancel:focus {
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.1) !important;
}

.swal2-icon {
    border-width: 3px !important;
}

/* Spin Animation for Refresh Buttons */
.bi-spin {
    display: inline-block;
    animation: spin 1s linear infinite;
}
.bi-spin-slow {
    display: inline-block;
    animation: spin 4s linear infinite;
}
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ==========================================================================
   INTERFACE STATUS CARD — PREMIUM STYLING
   ========================================================================== */

/* Card override */
.iface-status-card {
    overflow: visible;
}

/* Header */
.iface-status-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    background: linear-gradient(135deg, var(--bg-card) 0%, rgba(162, 204, 39, 0.04) 100%);
    border-bottom: 1px solid var(--border-color);
}

.iface-header-icon {
    width: 34px;
    height: 34px;
    border-radius: 9px;
    background: linear-gradient(135deg, #051d38, #0d3a6e);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    flex-shrink: 0;
}

body.dark-mode .iface-header-icon {
    background: linear-gradient(135deg, #1e40af, #3b82f6);
}

.iface-header-title {
    font-size: 13px;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
}

.iface-header-sub {
    font-size: 10.5px;
    color: var(--text-muted);
    font-weight: 500;
    opacity: 0.7;
}

/* Live indicator */
.iface-live-dot {
    display: flex;
    align-items: center;
    gap: 6px;
}

.iface-pulse {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: var(--brand-green);
    display: inline-block;
    position: relative;
    animation: ifacePulse 2s ease-in-out infinite;
}

.iface-pulse::after {
    content: '';
    position: absolute;
    top: -3px;
    left: -3px;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 1.5px solid var(--brand-green);
    opacity: 0;
    animation: ifacePulseRing 2s ease-in-out infinite;
}

@keyframes ifacePulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

@keyframes ifacePulseRing {
    0% { transform: scale(0.8); opacity: 0.6; }
    50% { transform: scale(1.4); opacity: 0; }
    100% { transform: scale(0.8); opacity: 0; }
}

.iface-live-text {
    font-size: 9.5px;
    font-weight: 800;
    letter-spacing: 1px;
    color: var(--brand-green);
    text-transform: uppercase;
}

/* Table */
.iface-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 11.5px;
    table-layout: fixed;
}

.iface-table thead th {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    padding: 10px 8px;
    border-bottom: 1px solid var(--border-color);
    background-color: transparent;
    white-space: nowrap;
    opacity: 0.65;
}

.iface-table tbody td {
    padding: 10px 8px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-primary);
    vertical-align: middle;
    font-size: 12px;
}

/* Row hover */
.iface-row {
    transition: background-color 0.15s ease;
}

.iface-row:hover {
    background-color: rgba(162, 204, 39, 0.04);
}

body.dark-mode .iface-row:hover {
    background-color: rgba(178, 217, 66, 0.05);
}

.iface-row:last-child td {
    border-bottom: none;
}

/* Interface name cell */
.iface-name {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 12px;
}

.iface-port-icon {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    background-color: var(--input-bg);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    color: var(--text-muted);
    flex-shrink: 0;
}

/* Status badge */
.iface-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 10.5px;
    font-weight: 700;
    white-space: nowrap;
}

.iface-status-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
}

.iface-status-up {
    background-color: var(--brand-green-bg);
    color: var(--brand-green);
    border: 1px solid var(--brand-green-border);
}

.iface-status-up .iface-status-dot {
    background-color: var(--brand-green);
}

.iface-status-down {
    background-color: var(--accent-red-bg);
    color: var(--accent-red);
    border: 1px solid rgba(239, 68, 68, 0.25);
}

.iface-status-down .iface-status-dot {
    background-color: var(--accent-red);
}

/* Traffic values */
.iface-traffic-val {
    font-weight: 600;
    color: var(--text-primary);
    font-variant-numeric: tabular-nums;
    font-size: 11.5px;
}

.iface-unit {
    font-size: 9px;
    font-weight: 500;
    color: var(--text-muted);
    opacity: 0.6;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* Value states */
.iface-val-ok {
    color: var(--text-muted);
    font-weight: 500;
    opacity: 0.6;
    font-variant-numeric: tabular-nums;
}

.iface-val-warn {
    color: var(--accent-amber);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.iface-val-err {
    color: var(--accent-red);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

/* Custom scrollbar for interface table */
.iface-status-card .custom-table-responsive::-webkit-scrollbar {
    width: 4px;
}

.iface-status-card .custom-table-responsive::-webkit-scrollbar-track {
    background: transparent;
}

.iface-status-card .custom-table-responsive::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 4px;
}

.iface-status-card .custom-table-responsive::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

.nav-item-link {
    position: relative;
}
.nav-badge {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    transition: all 0.3s ease;
}
.sidebar-wrapper:not(:hover) .nav-badge {
    right: 8px;
    top: 10px;
    transform: scale(0.9);
    padding: 3px 6px !important;
}

/* Global Table Header Background */
table thead th,
.table thead th {
    background-color: rgba(5, 29, 56, 0.03) !important;
    border-bottom: 1px solid rgba(5, 29, 56, 0.06) !important;
}
