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

@font-face {
    font-family: 'Minecraft';
    src: url();

    font-weight: normal;
    font-style: normal;
}

.transparent-tabbar .tab-position .tab.active .tab-header .favicon:not(.svg),
.theme-dark .tab-position .tab.active .tab-header .favicon:not(.svg),
.acc-dark.color-behind-tabs-off .tab-position .tab.active .tab-header .favicon:not(.svg) {
    filter: none !important;
}

:root {
    --blurple: #5865f2;
    --blurple-hover: #4752c4;
    --blurple-dim: rgba(88, 101, 242, 0.15);
    --bg-main: #000000;
    --bg-secondary: #0a0a0a;
    --bg-tertiary: #111111;
    --bg-elevated: #171717;
    --bg-modifier-accent: #1e1e1e;
    --bg-modifier-hover: rgba(255, 255, 255, 0.04);
    --bg-modifier-selected: rgba(88, 101, 242, 0.2);
    --text-normal: #c8ccd0;
    --text-muted: #62676e;
    --text-dimmer: #4a4f56;
    --text-header: #f0f2f4;
    --danger: #ed4245;
    --danger-dim: rgba(237, 66, 69, 0.12);
    --success: #23a559;
    --gold: #f0b429;
    --silver: #a8b3c0;
    --bronze: #cd7f32;
    --border-subtle: rgba(255, 255, 255, 0.055);
    --border-medium: rgba(255, 255, 255, 0.09);
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.5);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.6);
    --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.8);
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 14px;
    --radius-xl: 20px;
    --font-ui: 'Inter', sans-serif;
    --font-display: 'Space Grotesk', sans-serif;
}

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 15px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    background: var(--bg-main);
    font-family: var(--font-ui);
    color: var(--text-normal);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    line-height: 1.5;
}

::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 99px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.14);
}

.header {
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-subtle);
    padding: 0 20px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header h1 {
    font-family: var(--font-display);
    font-size: 15px;
    font-weight: 700;
    color: var(--text-header);
    letter-spacing: -0.01em;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.header-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-display);
    font-size: 15px;
    font-weight: 700;
    color: var(--text-header);
}

.live-stats-strip {
    display: flex;
    align-items: center;
    gap: 15px;
    border-left: 1px solid var(--border-subtle);
    padding-left: 15px;
    height: 18px;
}

.live-stat {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 10.5px;
    font-family: var(--font-ui);
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: 0.05em;
}

.live-stat span {
    color: var(--text-normal);
    font-size: 13px;
}

.dot-online {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 8px rgba(35, 165, 89, 0.5);
    flex-shrink: 0;
}

.main {
    flex: 1;
    padding: 36px 24px;
    display: flex;
    justify-content: center;
    align-items: flex-start;
}

.dashboard-container {
    width: 100%;
    max-width: 90%;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.panel {
    width: 100%;
    max-width: 420px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    padding: 40px 32px;
    box-shadow: var(--shadow-lg);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.panel-title {
    font-family: var(--font-display);
    font-size: 22px;
    font-weight: 800;
    color: var(--text-header);
    letter-spacing: -0.03em;
}

.panel-subtitle {
    font-size: 13.5px;
    color: var(--text-muted);
    margin-bottom: 16px;
    line-height: 1.5;
}

button,
.btn,
.action-btn {
    background: var(--blurple);
    color: #fff;
    border: none;
    padding: 9px 18px;
    border-radius: var(--radius-md);
    font-family: var(--font-ui);
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.18s cubic-bezier(0.2, 0, 0.2, 1);
    height: 38px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-decoration: none;
    white-space: nowrap;
    letter-spacing: 0.01em;
}

button:hover,
.btn:hover,
.action-btn:hover {
    background: var(--blurple-hover);
    transform: translateY(-1px);
}

button:active,
.btn:active,
.action-btn:active {
    transform: translateY(0) scale(0.98);
}

.btn.secondary {
    background: var(--bg-elevated);
    border: 1px solid var(--border-medium);
    color: var(--text-normal);
}

.btn.secondary:hover {
    background: var(--bg-modifier-accent);
    border-color: rgba(255, 255, 255, 0.15);
    color: var(--text-header);
}

.dashboard-tabs {
    display: flex;
    gap: 6px;
    margin: 16px 0;
}

.m-tab {
    position: relative;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-subtle);
    color: var(--text-muted);
    padding: 9px 20px;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    flex: 1;
    transition: all 0.18s cubic-bezier(0.2, 0, 0.2, 1);
}

.m-tab.active {
    background: rgba(88, 101, 242, 0.15);
    border-color: rgba(88, 101, 242, 0.3);
    color: #fff;
    box-shadow: 0 2px 10px rgba(88, 101, 242, 0.2);
}

.m-tab:not(.active):hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: var(--border-medium);
    color: var(--text-header);
}

.logout-btn {
    background: transparent;
    border: 1px solid rgba(237, 66, 69, 0.35);
    color: var(--danger);
    height: 32px;
    padding: 0 12px;
    font-size: 12.5px;
    border-radius: var(--radius-sm);
}

.logout-btn:hover {
    background: var(--danger);
    border-color: var(--danger);
    color: #fff;
    transform: translateY(-1px);
}

.status-panel {
    width: 100%;
    background: var(--bg-secondary);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-md);
}

.profile-banner {
    height: 90px;
    background: linear-gradient(135deg, #1a1b4b 0%, #2d1b69 40%, #1a0933 70%, #0d0a1a 100%);
    position: relative;
    overflow: hidden;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
}

.profile-banner::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 30% 50%, rgba(88, 101, 242, 0.25) 0%, transparent 65%),
        radial-gradient(ellipse at 80% 20%, rgba(180, 100, 255, 0.15) 0%, transparent 55%);
}

.profile-content {
    padding: 0 20px 20px;
}

.profile-header {
    display: flex;
    align-items: flex-end;
    margin-top: -42px;
    margin-bottom: 16px;
    position: relative;
    z-index: 1;
}

.avatar {
    width: 84px;
    height: 84px;
    border-radius: 50%;
    background: var(--bg-tertiary);
    border: 5px solid var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-size: 28px;
    font-weight: 800;
    color: var(--text-header);
    margin-right: 16px;
    flex-shrink: 0;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.6);
    overflow: hidden;
}

.avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-header .user-info {
    flex: 1;
    padding-top: 48px;
    min-width: 0;
}

.username-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.username {
    font-family: var(--font-display);
    font-size: 20px;
    font-weight: 800;
    color: var(--text-header);
    letter-spacing: -0.03em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.user-tag {
    font-size: 12.5px;
    color: var(--text-muted);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 4px;
    flex-wrap: wrap;
}

.user-tag+.user-tag {
    margin-top: 3px;
}

#tokenText {
    cursor: copy;
    font-family: 'Menlo', 'Consolas', monospace;
    font-size: 11.5px;
    font-weight: 500;
    color: var(--blurple);
    letter-spacing: 0.02em;
    transition: color 0.15s;
}

#tokenText:hover {
    color: #818cf8;
    text-decoration: underline;
}

#tT {
    cursor: pointer;
    font-family: 'Menlo', 'Consolas', monospace;
    font-size: 11.5px;
    font-weight: 500;
    color: var(--blurple);
    letter-spacing: 0.02em;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    transition: color 0.15s;
}

#tT .tok-secret {
    filter: blur(5px);
    user-select: none;
}

#tT:hover {
    color: #818cf8;
}

.reset-icon-btn {
    background: transparent;
    border: 1px solid var(--border-subtle);
    color: var(--text-dimmer);
    width: 24px;
    height: 24px;
    border-radius: var(--radius-sm);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.2, 0, 0.2, 1);
    padding: 0;
    flex-shrink: 0;
}

.reset-icon-btn svg {
    width: 13px;
    height: 13px;
    transition: transform 0.45s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.reset-icon-btn:hover {
    background: var(--danger-dim);
    border-color: rgba(237, 66, 69, 0.4);
    color: var(--danger);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(237, 66, 69, 0.2);
}

.reset-icon-btn:hover svg {
    transform: rotate(180deg);
}

.reset-icon-btn:active {
    transform: scale(0.92);
}

.stats-row {
    display: flex;
    gap: 1px;
    background: var(--border-subtle);
    border-top: 1px solid var(--border-subtle);
    overflow: hidden;
    border-radius: 0 0 var(--radius-xl) var(--radius-xl);
}

.stat-cell {
    flex: 1;
    padding: 14px 12px;
    background: var(--bg-secondary);
    text-align: center;
}

.stat-cell+.stat-cell {
    border-left: 1px solid var(--border-subtle);
}

.stat-value {
    font-family: var(--font-display);
    font-size: 22px;
    font-weight: 800;
    color: var(--text-header);
    letter-spacing: -0.03em;
    line-height: 1;
}

.stat-label {
    font-size: 10.5px;
    font-weight: 600;
    color: var(--text-muted);

    letter-spacing: 0.08em;
    margin-top: 5px;
}

.search-bar-wrap {
    position: relative;
    margin-bottom: 20px;
    width: 100%;
    max-width: 280px;
    margin-left: auto;
    margin-right: auto;
}

.search-bar-wrap input {
    width: 100%;
    height: 34px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    padding: 0 12px 0 34px;
    color: var(--text-normal);
    font-size: 13px;
    outline: none;
    transition: all 0.2s;
}

.search-bar-wrap input:focus {
    border-color: var(--blurple);
    box-shadow: 0 0 0 3px rgba(88, 101, 242, 0.15);
}

.search-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    pointer-events: none;
}

.clients-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 12px;
    width: 100%;
}

.client-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: all 0.22s cubic-bezier(0.2, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    opacity: 0;
    transform: translateY(14px);
}

.client-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.client-card:hover {
    border-color: var(--border-medium);
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.client-card-header {
    padding: 10px 14px;
    background: var(--bg-tertiary);
    display: flex;
    gap: 10px;
    align-items: center;
    border-bottom: 1px solid var(--border-subtle);
}

.client-avatar {
    width: 42px;
    height: 42px;
    border-radius: var(--radius-md);
    background: var(--bg-elevated);
    overflow: hidden;
    border: 1px solid var(--border-subtle);
    flex-shrink: 0;
}

.client-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.client-card-body {
    padding: 10px 14px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.client-section-title {
    font-size: 10px;
    font-weight: 700;

    letter-spacing: 0.1em;
    color: var(--text-dimmer);
    margin-bottom: 10px;
}

.data-grid {
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1;
}

.data-item {
    background: var(--bg-elevated);
    border-radius: var(--radius-sm);
    padding: 9px 12px;
}

.data-label {
    font-size: 10px;
    font-weight: 700;

    letter-spacing: 0.06em;
    color: var(--text-dimmer);
    margin-bottom: 2px;
}

.data-value {
    font-size: 13px;
    color: var(--text-normal);
    font-weight: 500;
    word-break: break-all;
}

.card-action-btn {
    margin-top: 12px;
    width: 100%;
    height: 34px;
    font-size: 12.5px;
    border-radius: var(--radius-sm);
}

.no-clients-message {
    color: var(--text-muted);
    font-size: 14px;
    text-align: center;
    font-weight: 500;
    width: 100%;
}

.clients-grid:has(.no-clients-message) {
    display: block;
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 52px 24px;
    color: var(--text-dimmer);
    font-size: 13.5px;
    font-weight: 500;
    text-align: center;
    grid-column: 1 / -1;
}

.empty-state svg {
    color: var(--text-dimmer);
    opacity: 0.5;
}

.send-all-btn {
    height: 32px;
    padding: 0 12px;
    font-size: 12.5px;
    border-radius: var(--radius-sm);
    background: var(--bg-elevated);
    border: 1px solid var(--border-medium);
    color: var(--text-normal);
}

.send-all-btn:hover {
    background: var(--bg-modifier-accent);
    color: var(--text-header);
}

.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 2000;
    pointer-events: none;
}

.toast {
    background: var(--bg-elevated);
    color: var(--text-header);
    padding: 13px 18px;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg), inset 0 1px 0 rgba(255, 255, 255, 0.06);
    border-left: 3px solid var(--blurple);
    font-size: 13.5px;
    font-weight: 500;
    animation: toast_slide_in 0.3s cubic-bezier(0.2, 0, 0.2, 1);
    display: flex;
    align-items: center;
    gap: 12px;
    pointer-events: auto;
    min-width: 220px;
    max-width: 360px;
}

.toast.success {
    border-left-color: var(--success);
}

.toast.error {
    border-left-color: var(--danger);
}

.toast.fade-out {
    animation: toast_slide_out 0.3s cubic-bezier(0.2, 0, 0.2, 1) forwards;
}

@keyframes toast_slide_in {
    from {
        transform: translateX(110%);
        opacity: 0;
    }

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

@keyframes toast_slide_out {
    from {
        transform: translateX(0);
        opacity: 1;
    }

    to {
        transform: translateX(110%);
        opacity: 0;
    }
}

.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 20px;
    animation: modal_fade_in 0.18s ease;
}

@keyframes modal_fade_in {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.modal-content {
    background: var(--bg-secondary);
    border: 1px solid var(--border-medium);
    width: 100%;
    max-width: 440px;
    border-radius: var(--radius-xl);
    padding: 28px;
    box-shadow: var(--shadow-lg);
    animation: modal_slide_in 0.22s cubic-bezier(0.2, 0, 0.2, 1);
}

@keyframes modal_slide_in {
    from {
        transform: translateY(16px) scale(0.96);
        opacity: 0;
    }

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

.modal-content h3 {
    font-family: var(--font-display);
    font-size: 18px;
    font-weight: 800;
    color: var(--text-header);
    margin-bottom: 16px;
    letter-spacing: -0.02em;
}

#modal_message {
    margin-bottom: 20px;
    color: var(--text-muted);
    font-size: 13.5px;
    line-height: 1.6;
}

.modal-content textarea {
    width: 100%;
    height: 110px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-md);
    color: var(--text-normal);
    padding: 12px 14px;
    font-family: var(--font-ui);
    font-size: 13.5px;
    resize: none;
    margin-bottom: 18px;
    transition: border-color 0.15s;
    outline: none;
}

.modal-content textarea:focus {
    border-color: var(--blurple);
    box-shadow: 0 0 0 3px rgba(88, 101, 242, 0.15);
}

.modal-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

.modal-btn {
    width: auto;
    height: 36px;
    font-size: 13px;
    border-radius: var(--radius-sm);
}

.modal-btn.cancel {
    background: transparent;
    border: 1px solid var(--border-medium);
    color: var(--text-muted);
}

.modal-btn.cancel:hover {
    background: var(--bg-elevated);
    color: var(--text-header);
    transform: none;
}

.modal-btn.confirm {
    background: var(--blurple);
}

.status-box {
    border-left: 2px solid transparent;
    padding: 5px 8px;
    border-radius: 4px;
}

.status-box.online {
    border-left-color: var(--success);
}

.badge {
    display: inline-flex;
    align-items: center;
    border-radius: 99px;
    padding: 2px 8px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.04em;

}

.badge.online {
    background: rgba(35, 165, 89, 0.18);
    color: #3bba6e;
}

.status-value {
    font-size: 12px;
}

.divider {
    height: 1px;
    background: var(--border-subtle);
    margin: 16px 0;
}

.lb-controls {
    display: flex;
    gap: 12px;
    margin: 16px 0 0;
    flex-wrap: wrap;
    align-items: center;
}

.custom-dropdown {
    position: relative;
    flex: 1;
    min-width: 160px;
}

.dropdown-trigger {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 40px;
    padding: 0 14px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-medium);
    border-radius: var(--radius-md);
    color: var(--text-normal);
    font-family: var(--font-ui);
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.18s ease;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
    user-select: none;
}

.dropdown-trigger:hover {
    border-color: rgba(255, 255, 255, 0.18);
    background: var(--bg-elevated);
    color: var(--text-header);
}

.dropdown-trigger svg {
    width: 16px;
    height: 16px;
    color: var(--text-muted);
    transition: transform 0.22s ease;
    flex-shrink: 0;
}

.custom-dropdown.open .dropdown-trigger {
    border-color: var(--blurple);
    box-shadow: 0 0 0 2px rgba(88, 101, 242, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.custom-dropdown.open .dropdown-trigger svg {
    transform: rotate(180deg);
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    width: 100%;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-medium);
    border-radius: var(--radius-md);
    padding: 5px;
    display: none;
    z-index: 1000;
    box-shadow: var(--shadow-lg);
    animation: dropdown_fade 0.18s cubic-bezier(0.2, 0, 0.2, 1) forwards;
    max-height: 280px;
    overflow-y: auto;
}

.custom-dropdown.open .dropdown-menu {
    display: block;
}

.dropdown-item {
    padding: 9px 11px;
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.13s ease;
}

.dropdown-item:hover {
    background: var(--bg-elevated);
    color: var(--text-normal);
}

.dropdown-item.active {
    background: var(--blurple-dim);
    color: #818cf8;
}

@keyframes dropdown_fade {
    from {
        opacity: 0;
        transform: translateY(-6px);
    }

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

.period-tabs {
    display: flex;
    background: var(--bg-tertiary);
    padding: 3px;
    border-radius: var(--radius-md);
    gap: 2px;
    border: 1px solid var(--border-subtle);
}

.tab-btn {
    padding: 6px 14px;
    border: none;
    background: transparent;
    color: var(--text-muted);
    font-family: var(--font-ui);
    font-size: 12px;
    font-weight: 700;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.18s;
    letter-spacing: 0.02em;
    height: auto;
}

.tab-btn:hover {
    color: var(--text-normal);
    background: rgba(255, 255, 255, 0.05);
    transform: none;
}

.tab-btn.active {
    background: var(--blurple);
    color: #fff;
    box-shadow: 0 2px 8px rgba(88, 101, 242, 0.35);
}

.lb-list,
#leaderboard-body {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.lb-header {
    display: flex;
    align-items: center;
    padding: 0 16px 8px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.1em;

    color: var(--text-dimmer);
}

.lb-row {
    display: flex;
    align-items: center;
    padding: 11px 14px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-md);
    border: 1px solid transparent;
    transition: all 0.18s ease;
    animation: lb_row_fade 0.4s ease both;
    opacity: 0;
    margin-bottom: 10px;
}

@keyframes lb_row_fade {
    from {
        transform: translateY(8px);
        opacity: 0;
    }

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

.lb-row:hover {
    background: var(--bg-elevated);
    border-color: var(--border-subtle);
    transform: scale(1.008);
}

.highlight-me {
    background: var(--bg-elevated) !important;
    border-color: rgba(88, 101, 242, 0.4) !important;
    box-shadow: 0 0 0 1px rgba(88, 101, 242, 0.2);
}

.col-rank {
    width: 56px;
    display: flex;
    justify-content: center;
}

.col-user {
    flex: 1;
    min-width: 0;
}

.col-percentage {
    width: 78px;
    text-align: right;
    font-size: 12px;
    color: var(--text-dimmer);
    font-weight: 500;
}

.col-hits {
    width: 88px;
    text-align: right;
    font-family: var(--font-display);
    font-weight: 800;
    color: var(--text-header);
    font-size: 16px;
    letter-spacing: -0.02em;
}

.rank-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 12px;
}

.rank-1 .rank-badge {
    background: linear-gradient(135deg, #ffd700, #f0a500);
    color: #000;
    box-shadow: 0 2px 10px rgba(255, 215, 0, 0.3);
}

.rank-2 .rank-badge {
    background: linear-gradient(135deg, #c8d6e0, #9bb4c4);
    color: #000;
}

.rank-3 .rank-badge {
    background: linear-gradient(135deg, #cd7f32, #a0622a);
    color: #fff;
}

.rank-normal .rank-badge {
    background: var(--bg-elevated);
    color: var(--text-dimmer);
}

.col-user .user-info {
    display: flex;
    align-items: center;
    gap: 11px;
}

.small-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    object-fit: cover;
    background: var(--bg-elevated);
    border: 1px solid var(--border-subtle);
    flex-shrink: 0;
}

.user-name {
    font-weight: 600;
    font-size: 14px;
    color: var(--text-header);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.spinner {
    width: 28px;
    height: 28px;
    border: 2.5px solid var(--border-subtle);
    border-top-color: var(--blurple);
    border-radius: 50%;
    animation: spin 0.75s linear infinite;
    margin: 0 auto;
}

input {
    width: 100%;
    padding: 10px 12px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius-sm);
    color: var(--text-normal);
    font-family: var(--font-ui);
    font-size: 14px;
    outline: none;
    transition: border-color 0.15s;
}

input:focus {
    border-color: var(--blurple);
    box-shadow: 0 0 0 3px rgba(88, 101, 242, 0.15);
}

.fade-in {
    animation: fade_in 0.3s ease;
}

@keyframes fade_in {
    from {
        opacity: 0;
        transform: translateY(6px);
    }

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

@media (max-width: 768px) {
    .main {
        padding: 20px 14px;
    }

    .clients-grid {
        grid-template-columns: 1fr;
    }

    .profile-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
        margin-top: -30px;
        gap: 10px;
    }

    .username-row {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }

    .profile-header .user-info {
        padding-top: 0;
        width: 100%;
    }

    .avatar {
        margin-right: 0;
    }

    .send-all-btn {
        width: 100%;
    }

    .lb-controls {
        flex-direction: column;
    }

    .custom-dropdown {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .header {
        height: 48px;
        padding: 0 12px;
    }

    .header-logo h1 {
        font-size: 13px;
    }

    .live-stats-strip {
        gap: 8px;
        padding-left: 10px;
    }

    .live-stat {
        font-size: 0;
    }

    .live-stat span {
        font-size: 12px;
        margin-left: 2px;
    }

    .dot-online {
        width: 6px;
        height: 6px;
    }

    .header-actions {
        gap: 4px;
    }

    .logout-btn {
        height: 28px;
        padding: 0 8px;
        font-size: 11.5px;
    }

    .btn.secondary {
        height: 28px;
        padding: 0 10px !important;
        font-size: 11.5px !important;
    }

    .btn.secondary svg {
        display: none;
    }

    .panel {
        padding: 28px 20px;
        border-radius: var(--radius-lg);
    }

    .status-panel {
        border-radius: var(--radius-lg);
    }

    .header h1 {
        font-size: 14px;
    }

    .logout-btn {
        padding: 0 9px;
        font-size: 12px;
    }

    .username {
        font-size: 17px;
    }

    .profile-banner {
        height: 60px !important;
    }

    .avatar {
        width: 70px;
        height: 70px;
        margin-top: -35px;
    }
}

.app-layout {
    display: flex;
    min-height: 100vh;
    width: 100%;
}

.sidebar {
    width: 250px;
    height: 100vh;
    position: sticky;
    top: 0;
    background: #060608;
    border-right: 1px solid var(--border-subtle);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 24px 16px;
    flex-shrink: 0;
    z-index: 101;
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.4);
    transition: width 0.3s cubic-bezier(0.2, 0, 0.2, 1), padding 0.3s cubic-bezier(0.2, 0, 0.2, 1);
    overflow-y: auto;
}

.content-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    padding-bottom: 0;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 8px 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    margin-bottom: 24px;
}

.sidebar-logo {
    width: 34px;
    height: 34px;
    border-radius: 6px;
    object-fit: cover;
    box-shadow: 0 0 10px rgba(88, 101, 242, 0.3);
}

.sidebar-title {
    font-family: var(--font-display);
    font-size: 16px;
    font-weight: 800;
    color: var(--text-header);
    letter-spacing: 0.02em;
    text-transform: lowercase;
}

.sidebar-toggle-btn {
    background: transparent !important;
    border: none !important;
    color: var(--text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    margin-left: auto;
    transition: all 0.2s ease;
    padding: 0;
}
.sidebar-toggle-btn:hover {
    background: var(--bg-modifier-hover) !important;
    color: var(--text-header);
    transform: none !important;
}
.sidebar-toggle-btn svg {
    width: 18px;
    height: 18px;
}

.desktop-nav {
    display: flex;
    flex-direction: column;
    gap: 16px;
    flex: 1;
}

.mobile-nav {
    display: none;
}

.nav-category {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.nav-category-title {
    font-size: 10px;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: 0.12em;
    padding: 4px 14px 6px;
    user-select: none;
    transition: opacity 0.2s ease, height 0.2s ease, padding 0.2s ease;
    white-space: nowrap;
}

.nav-sub-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 14px 8px 24px;
    color: var(--text-muted);
    text-decoration: none;
    border-radius: var(--radius-md);
    font-size: 13px;
    font-weight: 600;
    transition: all 0.2s cubic-bezier(0.2, 0, 0.2, 1);
    border: 1px solid transparent;
}

.nav-sub-item svg {
    width: 16px;
    height: 16px;
    color: var(--text-dimmer);
    transition: color 0.2s, transform 0.2s;
    flex-shrink: 0;
}

.nav-sub-item:hover {
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-header);
}

.nav-sub-item:hover svg {
    color: var(--text-header);
    transform: translateX(1px);
}

.nav-sub-item.active {
    background: rgba(88, 101, 242, 0.12) !important;
    color: #fff !important;
    border: 1px solid rgba(88, 101, 242, 0.2);
}

.nav-sub-item.active svg {
    color: var(--blurple);
}

.nav-sub-item.sys-only-item {
    border: 1px dashed rgba(237, 66, 69, 0.15);
}

.nav-sub-item.sys-only-item.active {
    background: rgba(237, 66, 69, 0.12) !important;
    color: #fff !important;
    border: 1px solid rgba(237, 66, 69, 0.3);
}

.nav-sub-item.sys-only-item.active svg {
    color: var(--danger);
}

.sidebar-collapsed .sidebar {
    width: 70px;
    padding: 24px 10px;
}

.sidebar-collapsed .sidebar-title,
.sidebar-collapsed .nav-category-title,
.sidebar-collapsed .sb-details,
.sidebar-collapsed .sb-logout-btn,
.sidebar-collapsed .nav-sub-item span {
    display: none !important;
}

.sidebar-collapsed .sidebar-brand {
    justify-content: center;
    padding: 0 0 16px;
}

.sidebar-collapsed .sidebar-logo {
    margin-right: 0;
}

.sidebar-collapsed .sidebar-toggle-btn {
    margin-left: 0;
}

.sidebar-collapsed .nav-sub-item {
    padding: 10px 0;
    justify-content: center;
}

.sidebar-collapsed .nav-sub-item svg {
    margin: 0;
    width: 20px;
    height: 20px;
}

.sidebar-collapsed .sidebar-footer {
    justify-content: center;
    padding: 16px 0 0;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    color: var(--text-muted);
    text-decoration: none;
    border-radius: var(--radius-md);
    font-size: 13.5px;
    font-weight: 600;
    transition: all 0.2s cubic-bezier(0.2, 0, 0.2, 1);
}

.nav-item svg {
    width: 18px;
    height: 18px;
    color: var(--text-dimmer);
    transition: color 0.2s;
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-header);
}

.nav-item:hover svg {
    color: var(--text-header);
    transform: translateX(1px);
}

.nav-item.active {
    background: rgba(88, 101, 242, 0.12) !important;
    color: #fff !important;
    border: 1px solid rgba(88, 101, 242, 0.2);
}

.nav-item.active svg {
    color: var(--blurple);
}

.nav-item.sys-only-item {
    border: 1px dashed rgba(237, 66, 69, 0.15);
}

.nav-item.sys-only-item.active {
    background: rgba(237, 66, 69, 0.12) !important;
    color: #fff !important;
    border: 1px solid rgba(237, 66, 69, 0.3);
}

.nav-item.sys-only-item.active svg {
    color: var(--danger);
}

.sidebar-footer {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 16px 8px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.04);
    margin-top: auto;
}

.sb-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-subtle);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 13px;
    color: var(--text-header);
    overflow: hidden;
    flex-shrink: 0;
}

.sb-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.sb-details {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.sb-username {
    font-size: 12.5px;
    font-weight: 700;
    color: var(--text-header);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sb-status {
    font-size: 9.5px;
    font-weight: 600;
    color: var(--success);
    letter-spacing: 0.02em;
    margin-top: 1px;
}

.sb-logout-btn {
    background: transparent;
    border: none;
    color: var(--text-muted);
    width: 30px;
    height: 30px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    padding: 0;
}

.sb-logout-btn svg {
    width: 16px;
    height: 16px;
    transition: transform 0.2s;
}

.sb-logout-btn:hover {
    background: var(--danger-dim);
    color: var(--danger);
}

.sb-logout-btn:hover svg {
    transform: translateX(1px);
}

.mobile-menu-btn {
    display: none;
}

@media (max-width: 900px) {
    .app-layout {
        flex-direction: column;
    }

    .sidebar {
        position: fixed;
        top: 0;
        bottom: 0;
        left: -280px;
        height: 100dvh;
        width: 250px !important;
        z-index: 1001;
        transition: left 0.3s cubic-bezier(0.2, 0, 0.2, 1);
        border-right: 1px solid var(--border-subtle);
        box-shadow: 4px 0 24px rgba(0, 0, 0, 0.4);
        padding: 24px 16px !important;
    }
    .sidebar-collapsed .sidebar-title,
    .sidebar-collapsed .nav-category-title,
    .sidebar-collapsed .nav-sub-item span,
    .sidebar-collapsed .nav-item span {
        display: block !important;
    }

    .sidebar-collapsed .sb-details {
        display: flex !important;
    }

    .sidebar-collapsed .sb-logout-btn {
        display: flex !important;
    }

    .sidebar-collapsed .sidebar-brand,
    .sidebar-collapsed .sidebar-footer {
        justify-content: space-between !important;
        padding: inherit !important;
    }

    body.mobile-sidebar-open {
        overflow: hidden;
    }

    body.mobile-sidebar-open .sidebar {
        left: 0;
    }

    .sidebar-toggle-btn {
        display: none !important;
    }

    .header-actions {
        display: flex;
        align-items: center;
        gap: 12px;
    }

    .mobile-menu-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        background: transparent;
        border: none;
        color: var(--text-normal);
        padding: 6px;
        cursor: pointer;
        border-radius: var(--radius-sm);
        transition: background 0.2s;
    }

    .mobile-menu-btn:active {
        background: var(--bg-modifier-hover);
    }

    .mobile-menu-btn svg {
        width: 24px;
        height: 24px;
    }

    .mobile-backdrop {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.6);
        backdrop-filter: blur(4px);
        z-index: 1000;
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.3s ease;
    }

    body.mobile-sidebar-open .mobile-backdrop {
        opacity: 1;
        pointer-events: auto;
    }

    #mobileLogout {
        display: none !important;
    }
}
@view-transition {
    navigation: auto;
}

#clientsSection, #autojoinerSection, #analysisSection, #xlb, #lbAnalysisSection {
    animation: fade_in 0.3s cubic-bezier(0.2, 0, 0, 1);
}

.content-wrapper, .main {
    animation: page_fade_in 0.4s cubic-bezier(0.2, 0, 0, 1) forwards;
}
@keyframes page_fade_in {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

