:root {
    --bg-main: #0a0a0c;
    --bg-secondary: #111114;
    --bg-tertiary: #19191e;
    --bg-elevated: #222228;
    --border-subtle: rgba(255, 255, 255, 0.06);
    --border-default: rgba(255, 255, 255, 0.09);
    --border-hover: rgba(255, 255, 255, 0.14);

    --clr-primary: #10b981;
    --clr-primary-strong: #047857;
    --clr-success: #34d399;
    --clr-danger: #f87171;
    --clr-warning: #fbbf24;
    --clr-info: #60a5fa;

    --txt-main: #f4f4f5;
    --txt-dim: #a1a1aa;
    --txt-muted: #71717a;

    --sidebar-w: 236px;
    --radius-xl: 30px;
    --radius-lg: 20px;
    --radius-md: 14px;

    --shadow-soft: 0 22px 44px rgba(0, 0, 0, 0.42);
    --shadow-glow: 0 0 22px rgba(16, 185, 129, 0.24);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    border-color: var(--border-subtle);
}

html,
body {
    width: 100%;
    height: 100%;
}

body {
    background:
        radial-gradient(980px 440px at 84% -12%, rgba(16, 185, 129, 0.12), transparent 55%),
        radial-gradient(880px 320px at 12% -10%, rgba(255, 255, 255, 0.025), transparent 56%),
        var(--bg-main);
    color: var(--txt-main);
    font-family: 'Satoshi', 'Geist', sans-serif;
    font-feature-settings: "rlig" 1, "calt" 1;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow: hidden;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background-color: #27272a;
    border-radius: 9999px;
}

::-webkit-scrollbar-thumb:hover {
    background-color: #3f3f46;
}

::selection {
    background-color: rgba(16, 185, 129, 0.2);
    color: #a9fffe;
}

.layout {
    display: flex;
    height: 100vh;
    min-height: 100vh;
}

.sidebar {
    width: var(--sidebar-w) !important;
    height: 100vh;
    background: linear-gradient(180deg, rgba(10, 10, 12, 0.92) 0%, rgba(10, 10, 13, 0.84) 100%) !important;
    border-right: 1px solid var(--border-subtle) !important;
    display: flex;
    flex-direction: column;
    padding: 16px 0 14px !important;
    z-index: 10;
}

.logo-area {
    padding: 0 20px !important;
    margin: 6px 0 18px !important;
}

.logo-title {
    font-family: 'Outfit', sans-serif !important;
    font-weight: 800 !important;
    letter-spacing: -0.02em !important;
    font-size: 34px !important;
    line-height: 1 !important;
    color: #fff !important;
    background: none !important;
    -webkit-text-fill-color: unset !important;
}

.nav-group {
    padding: 0 10px !important;
}

.nav-link {
    min-height: 44px;
    margin-bottom: 6px;
    border-radius: var(--radius-md);
    padding: 11px 14px !important;
    color: #71717a;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    border: 1px solid transparent;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: all 0.2s ease;
    user-select: none;
}

.nav-link:hover {
    color: #d4d4d8;
    background: rgba(255, 255, 255, 0.03);
    border-color: var(--border-subtle);
}

.nav-link.active {
    color: #34d399;
    background: rgba(16, 185, 129, 0.10);
    border-color: rgba(16, 185, 129, 0.26);
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.03) inset;
}

.nav-link.active::before {
    content: "";
    position: absolute;
    left: -10px;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 22px;
    border-radius: 999px;
    background: #10b981;
}

.nav-icon {
    font-size: 17px;
    line-height: 1;
    color: #52525b;
    transition: color 0.2s ease;
}

.nav-label {
    line-height: 1;
}

.nav-link:hover .nav-icon {
    color: #d4d4d8;
}

.nav-link.active .nav-icon {
    color: #34d399;
}

.main-content {
    flex: 1;
    height: 100vh;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 32px 38px 36px !important;
    background:
        radial-gradient(980px 400px at 65% -8%, rgba(16, 185, 129, 0.085), transparent 62%),
        transparent;
}

.section-view {
    display: none;
    animation: viewFadeIn 0.3s ease;
}

.section-view.active {
    display: block;
}

.analytics-sub {
    display: none;
    animation: viewFadeIn 0.25s ease;
}

.analytics-sub.active {
    display: block;
}

@keyframes viewFadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

h2,
.font-display {
    font-family: 'Outfit', sans-serif !important;
    font-size: 40px !important;
    font-weight: 800 !important;
    line-height: 1.02;
    letter-spacing: -0.03em;
    color: #fff;
    margin-bottom: 6px;
}

.subtitle {
    color: #71717a !important;
    font-size: 14px !important;
    font-weight: 500;
    margin-bottom: 22px !important;
}

.dash-topbar {
    margin-bottom: 24px !important;
}

.home-shell {
    display: grid;
    grid-template-columns: minmax(0, 1.85fr) minmax(320px, 1fr);
    gap: 22px;
}

.home-main-col {
    display: flex;
    flex-direction: column;
    gap: 22px;
}

.home-hero {
    padding: 34px !important;
    min-height: 400px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.home-hero-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
}

.home-hero-icon {
    width: 58px;
    height: 58px;
    border-radius: 16px;
    background: rgba(16, 185, 129, 0.10);
    border: 1px solid rgba(16, 185, 129, 0.23);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.home-hero-icon i {
    color: #34d399;
    font-size: 24px;
}

.home-hero-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
}

.home-status-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 12px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(0, 0, 0, 0.25);
    color: #c4c4c7;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.3px;
    text-transform: uppercase;
}

.home-status-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #10b981;
    box-shadow: 0 0 10px rgba(16, 185, 129, 0.75);
    animation: pulseOnline 2s ease infinite;
}

@keyframes pulseOnline {
    0% {
        transform: scale(1);
        opacity: 0.75;
    }

    50% {
        transform: scale(1.25);
        opacity: 1;
    }

    100% {
        transform: scale(1);
        opacity: 0.75;
    }
}

.home-changelog-btn {
    font-size: 11px !important;
    padding: 10px 18px !important;
    border-color: rgba(16, 185, 129, 0.30) !important;
    color: #34d399 !important;
}

.home-hero-body {
    margin-top: 36px;
}

.home-kicker {
    margin: 0 0 14px;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: #6b7280;
}

.home-kpi-row {
    display: flex;
    align-items: flex-end;
    gap: 16px;
    margin-bottom: 16px;
}

.home-kpi-value {
    font-family: 'Outfit', sans-serif;
    font-size: clamp(60px, 8vw, 110px);
    line-height: 0.9;
    font-weight: 900;
    letter-spacing: -0.05em;
    color: #fff;
}

.home-kpi-trend {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 800;
    color: #34d399;
    margin-bottom: 14px;
}

.home-kpi-description {
    max-width: 660px;
    color: #71717a;
    font-size: 22px;
    line-height: 1.45;
    letter-spacing: -0.01em;
}

.home-metric-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
}

.home-mini-card {
    padding: 26px !important;
    min-height: 170px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.home-mini-head {
    display: flex;
    align-items: center;
    gap: 12px;
}

.home-mini-icon {
    width: 30px;
    height: 30px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #34d399;
    background: rgba(16, 185, 129, 0.10);
    border: 1px solid rgba(16, 185, 129, 0.22);
}

.home-mini-icon.danger {
    color: #f87171;
    background: rgba(248, 113, 113, 0.10);
    border-color: rgba(248, 113, 113, 0.24);
}

.home-mini-icon i {
    font-size: 16px;
}

.home-mini-label {
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #71717a;
}

.home-mini-value {
    font-family: 'Outfit', sans-serif;
    font-size: clamp(38px, 4vw, 52px);
    font-weight: 900;
    line-height: 1;
    letter-spacing: -0.03em;
    color: #fff;
}

.home-feed {
    padding: 26px !important;
    min-height: 592px;
    display: flex;
    flex-direction: column;
}

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

.home-feed-header h3 {
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 2.6px;
    text-transform: uppercase;
    color: #6b7280;
}

.home-feed-link {
    border: 0;
    background: transparent;
    color: #34d399;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    cursor: pointer;
}

.home-feed-link:hover {
    color: #6ee7b7;
}

.home-feed-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow-y: auto;
    padding-right: 2px;
}

.home-feed-list::-webkit-scrollbar {
    width: 5px;
}

.tactical-item {
    border-radius: 16px;
    padding: 13px 14px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    background: linear-gradient(90deg, rgba(255, 255, 255, 0.015), rgba(255, 255, 255, 0.01));
    transition: border-color 0.2s ease, background 0.2s ease;
}

.tactical-item:hover {
    border-color: rgba(16, 185, 129, 0.22);
    background: linear-gradient(90deg, rgba(16, 185, 129, 0.08), rgba(255, 255, 255, 0.01));
}

.tactical-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.tactical-tag {
    display: inline-flex;
    align-items: center;
    padding: 4px 9px;
    border-radius: 999px;
    font-size: 9px;
    font-weight: 900;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.tactical-tag.sys {
    color: #a1a1aa;
    background: rgba(113, 113, 122, 0.24);
}

.tactical-tag.net {
    color: #6ee7b7;
    background: rgba(16, 185, 129, 0.18);
}

.tactical-tag.sec {
    color: #fda4af;
    background: rgba(248, 113, 113, 0.18);
}

.tactical-tag.auth {
    color: #7dd3fc;
    background: rgba(14, 165, 233, 0.18);
}

.tactical-time {
    font-size: 11px;
    color: #52525b;
    font-family: 'JetBrains Mono', ui-monospace, monospace;
}

.tactical-msg {
    font-size: 13px;
    color: #d4d4d8;
    line-height: 1.45;
}

.tactical-empty {
    font-size: 12px;
    color: #71717a;
    padding: 14px 2px;
}

.surface,
.surface-liquid,
.metric-card {
    background: rgba(24, 24, 27, 0.42) !important;
    border: 1px solid var(--border-default) !important;
    border-radius: var(--radius-xl) !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05), var(--shadow-soft);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

.surface {
    padding: 24px !important;
    margin-bottom: 22px !important;
}

.surface-liquid {
    background: rgba(24, 24, 27, 0.36) !important;
}

.metric-card {
    padding: 24px !important;
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.metric-card:hover {
    transform: translateY(-2px);
    border-color: var(--border-hover) !important;
}

.metric-label,
.info-label,
.label {
    font-size: 10px !important;
    font-weight: 700 !important;
    color: #6b7280 !important;
    letter-spacing: 1.6px !important;
    text-transform: uppercase;
}

.metric-value {
    display: block;
    margin-top: 8px;
    font-family: 'Outfit', sans-serif;
    font-size: 34px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.03em;
    color: #fff;
}

.metric-value.indigo {
    color: var(--clr-primary);
}

.metric-value.emerald {
    color: var(--clr-success);
}

.modern-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
}

.modern-table th {
    text-align: left;
    padding: 12px;
    font-size: 10px;
    font-weight: 800;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 1.6px;
    border-bottom: 1px solid var(--border-subtle);
    white-space: nowrap;
    background: rgba(16, 16, 19, 0.92);
}

.modern-table td {
    padding: 12px;
    font-size: 12px;
    color: #a1a1aa;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.modern-table tr:hover td {
    background: rgba(255, 255, 255, 0.02);
    color: #e4e4e7;
}

.modern-table code,
.mono,
.val.mono {
    font-family: 'JetBrains Mono', monospace;
}

.col-select {
    width: 3%;
}

.col-key {
    width: 26%;
}

.col-game {
    width: 10%;
}

.col-plan {
    width: 10%;
}

.col-created {
    width: 12%;
}

.col-expires {
    width: 12%;
}

.col-uses {
    width: 7%;
}

.col-status {
    width: 9%;
}

.col-actions {
    width: 11%;
}

.cell-select {
    text-align: center;
}

.badge {
    display: inline-block;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    vertical-align: middle;
    border-radius: 8px !important;
    padding: 5px 10px !important;
    font-size: 9px !important;
    font-weight: 800 !important;
    letter-spacing: 1px !important;
    border: 1px solid transparent;
}

.plan-basic,
.badge-basic {
    background: rgba(113, 113, 122, 0.15);
    color: #a1a1aa;
    border-color: rgba(113, 113, 122, 0.3);
}

.plan-pro,
.badge-pro {
    background: rgba(16, 185, 129, 0.14);
    color: #34d399;
    border-color: rgba(16, 185, 129, 0.30);
}

.plan-supreme {
    background: rgba(251, 191, 36, 0.14);
    color: #fbbf24;
    border-color: rgba(251, 191, 36, 0.3);
}

.plan-trial {
    background: rgba(161, 161, 170, 0.12);
    color: #a1a1aa;
    border-color: rgba(161, 161, 170, 0.25);
}

.plan-lifetime {
    background: rgba(52, 211, 153, 0.12);
    color: #34d399;
    border-color: rgba(52, 211, 153, 0.25);
}

.btn,
.action-btn,
.filter-pill,
.nav-link {
    position: relative;
    overflow: hidden;
}

.btn {
    border: 1px solid transparent;
    border-radius: 12px !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    padding: 11px 18px !important;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn:active,
.action-btn:active,
.filter-pill:active {
    transform: translateY(1px) scale(0.98);
}

.btn-primary {
    background: var(--clr-primary) !important;
    color: #03130d !important;
    border-color: rgba(16, 185, 129, 0.45) !important;
    box-shadow: 0 0 0 1px rgba(16, 185, 129, 0.3) inset, 0 8px 26px rgba(16, 185, 129, 0.22);
}

.btn-primary:hover {
    filter: brightness(1.06);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.03) !important;
    color: #d4d4d8 !important;
    border-color: var(--border-default) !important;
}

.btn-secondary:hover {
    border-color: var(--border-hover) !important;
    background: rgba(255, 255, 255, 0.05) !important;
}

.btn-danger {
    background: rgba(248, 113, 113, 0.11) !important;
    color: #fca5a5 !important;
    border-color: rgba(248, 113, 113, 0.35) !important;
}

.btn-danger:hover {
    background: rgba(248, 113, 113, 0.16) !important;
}

.btn-ghost {
    background: transparent !important;
    color: var(--txt-dim);
    border-color: transparent !important;
}

.btn-ghost:hover {
    color: #fff !important;
    background: rgba(255, 255, 255, 0.05) !important;
}

.btn-row {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.filter-bar {
    display: flex;
    gap: 8px;
    margin-bottom: 18px;
    flex-wrap: wrap;
}

.filter-pill {
    border: 1px solid var(--border-default) !important;
    border-radius: 12px !important;
    background: rgba(255, 255, 255, 0.02) !important;
    color: #71717a !important;
    padding: 8px 14px !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    cursor: pointer;
    transition: all 0.2s ease;
}

.filter-pill:hover {
    color: #d4d4d8 !important;
    border-color: var(--border-hover) !important;
}

.filter-pill.active {
    color: #0a0a0c !important;
    border-color: #ffffff !important;
    background: #ffffff !important;
}

.smart-view-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 14px;
}

.view-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 34px;
}

.view-pill .view-label {
    white-space: nowrap;
}

.view-pill .view-count {
    min-width: 22px;
    height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(255, 255, 255, 0.05);
    color: #a1a1aa;
    font-size: 10px;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.view-pill.active .view-count {
    border-color: rgba(10, 10, 12, 0.2);
    background: rgba(10, 10, 12, 0.1);
    color: #0a0a0c;
}

.license-toolbar-grid {
    display: grid;
    grid-template-columns: minmax(240px, 1.7fr) repeat(4, minmax(130px, 1fr)) auto auto;
    gap: 10px;
    align-items: center;
    margin-bottom: 12px;
}

.smart-search {
    min-width: 220px;
}

.facet-select {
    min-height: 42px;
    font-size: 12px !important;
    font-weight: 700 !important;
}

.facet-clear-btn,
.new-license-btn {
    min-height: 42px;
    white-space: nowrap;
}

.bulk-action-bar {
    display: none;
    position: sticky;
    top: 6px;
    z-index: 8;
    margin-bottom: 12px;
    padding: 10px 12px;
    border-radius: 14px;
    border: 1px solid rgba(16, 185, 129, 0.24);
    background: linear-gradient(90deg, rgba(16, 185, 129, 0.12), rgba(255, 255, 255, 0.02));
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.bulk-action-bar.active {
    display: flex;
}

.bulk-meta {
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1.1px;
    text-transform: uppercase;
    color: #a7f3d0;
    white-space: nowrap;
}

.bulk-meta span {
    color: #ffffff;
}

.bulk-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.bulk-actions .btn {
    min-height: 34px;
    padding: 8px 12px !important;
    font-size: 11px !important;
}

.row-check {
    width: 14px;
    height: 14px;
    accent-color: #10b981;
    cursor: pointer;
}

.license-id-main {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.copy-key-btn {
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 4px;
    color: var(--txt-muted);
    display: flex;
    flex: 0 0 auto;
}

.license-id-primary {
    color: #fff;
    font-family: 'Outfit', 'Satoshi', sans-serif;
    font-size: 13px;
    font-weight: 800;
    line-height: 1.25;
    letter-spacing: -0.01em;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.license-id-secondary {
    margin-left: 26px;
    margin-top: 4px;
    color: var(--txt-muted);
    font-size: 10px;
    font-family: 'JetBrains Mono', ui-monospace, monospace;
    letter-spacing: 0.02em;
}

.unlabeled-tag {
    font-size: 9px;
    font-weight: 800;
    letter-spacing: 1px;
    color: #fbbf24;
    border: 1px solid rgba(251, 191, 36, 0.35);
    background: rgba(251, 191, 36, 0.12);
    border-radius: 999px;
    padding: 2px 6px;
    flex: 0 0 auto;
}

.game-pill {
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1px;
    background: rgba(255, 255, 255, 0.03);
    padding: 4px 8px;
    border-radius: 6px;
    border: 1px solid var(--border-default);
}

.action-btn {
    background: rgba(255, 255, 255, 0.03) !important;
    border: 1px solid var(--border-default) !important;
    color: var(--txt-dim) !important;
    border-radius: 9px !important;
    padding: 8px 12px !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    cursor: pointer;
    transition: all 0.2s ease;
}

.action-btn:hover {
    color: #fff !important;
    border-color: var(--border-hover) !important;
}

input,
select,
textarea,
.custom-input,
.search-bar {
    width: 100%;
    background: #121216 !important;
    border: 1px solid var(--border-default) !important;
    color: #e4e4e7 !important;
    border-radius: 12px !important;
    outline: none;
    padding: 12px 14px !important;
    transition: all 0.2s ease;
    font-size: 14px !important;
    font-family: 'Satoshi', 'Geist', sans-serif !important;
}

.search-bar {
    font-family: 'JetBrains Mono', monospace !important;
}

input:focus,
select:focus,
textarea:focus,
.custom-input:focus,
.search-bar:focus {
    border-color: rgba(16, 185, 129, 0.5) !important;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.12) !important;
    background: #141419 !important;
}

::placeholder {
    color: #6b7280;
}

.custom-select-wrapper {
    position: relative;
    width: 100%;
    display: block;
}

.custom-select-wrapper > select {
    display: none !important;
}

.custom-select {
    background: #121216 !important;
    border: 1px solid var(--border-default) !important;
    border-radius: 12px !important;
    color: #e4e4e7 !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    padding: 12px 38px 12px 14px !important;
    cursor: pointer !important;
    position: relative;
}

.custom-select::after {
    content: "";
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    width: 10px;
    height: 10px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2371717a' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14 2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    transition: transform 0.2s ease;
}

.custom-select-wrapper.open .custom-select::after {
    transform: translateY(-50%) rotate(180deg);
}

.custom-select-options {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    z-index: 9999;
    background: #111216;
    border: 1px solid var(--border-default);
    border-radius: 12px;
    padding: 6px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: all 0.18s ease;
    max-height: 240px;
    overflow-y: auto;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05), var(--shadow-soft);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

.custom-select-wrapper.open .custom-select-options {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.custom-select-option {
    padding: 10px 12px;
    border-radius: 9px;
    color: #a1a1aa;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s ease;
}

.custom-select-option:hover {
    color: #fff;
    background: rgba(16, 185, 129, 0.08);
}

.custom-select-option.selected {
    color: #34d399;
    background: rgba(16, 185, 129, 0.13);
}

.chart-container {
    width: 100%;
    height: 320px;
    margin-top: 14px;
}

#globeViz,
#globeViz canvas {
    width: 100% !important;
    height: 100% !important;
    border-radius: var(--radius-lg);
}

.pagination-ctrl {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 14px;
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px solid var(--border-subtle);
}

.page-info {
    font-size: 10px;
    color: #6b7280;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.btn-pagination {
    width: 34px;
    height: 34px;
    border-radius: 8px;
    border: 1px solid var(--border-default);
    background: rgba(255, 255, 255, 0.03);
    color: #e4e4e7;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-pagination:hover:not(:disabled) {
    border-color: var(--border-hover);
    background: rgba(255, 255, 255, 0.07);
    transform: translateY(-1px);
}

.btn-pagination:disabled {
    opacity: 0.28;
    cursor: not-allowed;
}

/* Modal system */
.glass-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.78);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 1000;
}

.modal-content {
    background: #0f1014 !important;
    border: 1px solid var(--border-default) !important;
    border-radius: 20px !important;
    color: var(--txt-main);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.55);
}

.create-key-modal {
    width: min(720px, calc(100vw - 30px)) !important;
    max-height: calc(100vh - 14px);
    overflow-y: auto;
    padding: 30px 32px !important;
    display: flex;
    flex-direction: column;
    gap: 14px;
    position: relative;
    border-color: rgba(255, 255, 255, 0.12) !important;
    background:
        linear-gradient(180deg, rgba(18, 22, 30, 0.98), rgba(13, 16, 23, 0.98)),
        radial-gradient(85% 90% at 0% 0%, rgba(60, 98, 170, 0.08), transparent 62%),
        radial-gradient(90% 95% at 100% 100%, rgba(22, 138, 96, 0.08), transparent 64%),
        #0e1016 !important;
}

.create-key-modal::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.create-key-modal h2 {
    margin-bottom: 2px;
    line-height: 0.92;
    font-size: clamp(46px, 6vw, 64px) !important;
    letter-spacing: -0.045em;
    text-shadow: none;
}

.create-key-subtitle {
    margin-bottom: 8px !important;
    color: #8a90a2 !important;
    font-size: 13px !important;
    letter-spacing: 0.01em;
}

.create-key-row {
    display: flex;
    gap: 12px;
    align-items: center;
}

.create-key-helper {
    font-size: 12px;
    color: #747e95;
    margin-top: -4px;
    margin-bottom: 2px;
}

.create-key-helper span {
    color: #a3c2ff;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.alias-validation-msg {
    margin-top: -2px;
    margin-bottom: 2px;
    font-size: 11px;
    color: #71717a;
}

.alias-validation-msg.is-ok {
    color: #34d399;
}

.alias-validation-msg.is-error {
    color: #f87171;
}

.create-key-name-input {
    text-transform: uppercase;
    font-family: 'Orbitron', 'Outfit', sans-serif !important;
    letter-spacing: 0.02em;
}

.create-key-random-btn {
    min-width: 146px;
    flex: 0 0 146px;
    letter-spacing: 0.02em;
    border-color: rgba(255, 255, 255, 0.12) !important;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02)) !important;
}

.create-key-section {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.024), rgba(255, 255, 255, 0.012));
    border: 1px solid rgba(255, 255, 255, 0.10);
    border-radius: 18px;
    padding: 18px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.02);
    transition: border-color 0.2s ease, background 0.2s ease;
}

.create-key-section:hover {
    border-color: rgba(255, 255, 255, 0.14);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), rgba(255, 255, 255, 0.014));
}

.create-key-section-title {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
    color: #8b93a6 !important;
    letter-spacing: 2px !important;
}

.create-key-section-title::before {
    content: "";
    width: 6px;
    height: 6px;
    border-radius: 999px;
    background: rgba(96, 165, 250, 0.7);
    box-shadow: none;
}

.create-key-grid {
    display: grid;
    gap: 12px;
}

.create-key-grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.create-key-duration-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.create-key-expiry {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 12px;
    border-radius: 999px;
    font-size: 13px;
    color: #f5c760;
    font-weight: 700;
    text-align: right;
    border: 1px solid rgba(245, 199, 96, 0.26);
    background: rgba(245, 199, 96, 0.10);
}

.create-key-grid-duration {
    grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
}

.create-key-duration-input {
    text-align: center;
    font-weight: 700;
}

.create-key-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-top: 4px;
}

.create-key-modal .custom-input,
.create-key-modal .custom-select,
.create-key-modal .btn {
    min-height: 50px;
}

.create-key-modal .custom-input,
.create-key-modal .custom-select {
    border-color: rgba(255, 255, 255, 0.13) !important;
    background: linear-gradient(180deg, rgba(20, 23, 32, 0.98), rgba(15, 18, 26, 0.98)) !important;
}

.create-key-modal .custom-input:focus,
.create-key-modal .custom-select-wrapper.open .custom-select {
    border-color: rgba(16, 185, 129, 0.46) !important;
    box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.10) !important;
    background: linear-gradient(180deg, rgba(24, 28, 38, 0.98), rgba(18, 22, 31, 0.98)) !important;
}

.create-key-modal .custom-input.input-valid {
    border-color: rgba(52, 211, 153, 0.44) !important;
    box-shadow: 0 0 0 2px rgba(52, 211, 153, 0.08) !important;
}

.create-key-modal .custom-input.input-invalid {
    border-color: rgba(248, 113, 113, 0.50) !important;
    box-shadow: 0 0 0 2px rgba(248, 113, 113, 0.09) !important;
}

.create-key-modal .create-key-actions .btn {
    font-size: 14px !important;
    letter-spacing: 0.01em;
}

.create-key-modal .create-key-actions .btn-secondary {
    border-color: rgba(255, 255, 255, 0.12) !important;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.018)) !important;
}

.create-key-modal .create-key-actions .btn-primary {
    border-color: rgba(16, 185, 129, 0.45) !important;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

.modal-header-strip {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 12px;
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-subtle);
    background: rgba(255, 255, 255, 0.02);
}

.modal-text {
    color: var(--txt-dim);
    line-height: 1.55;
}

.info-box {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.val {
    color: #e4e4e7;
    font-weight: 700;
}

.info-card-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin: 0 0 12px;
}

.info-card,
.lic-sec-card {
    background: rgba(255, 255, 255, 0.02) !important;
    border: 1px solid var(--border-subtle) !important;
    border-radius: 12px !important;
    padding: 14px !important;
    min-width: 0;
}

.lic-details-body,
.sec-details-body {
    max-height: calc(100vh - 250px);
    overflow-y: auto;
}

.lic-sec-grid,
.sec-main-grid,
.sec-summary-grid {
    gap: 12px !important;
}

.frozen-glow {
    border-color: #38bdf8 !important;
    box-shadow: 0 0 0 1px rgba(56, 189, 248, 0.3), 0 0 26px rgba(56, 189, 248, 0.15) !important;
}

.frozen-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1px;
    border-radius: 999px;
    padding: 4px 10px;
    color: #022b38;
    background: #38bdf8;
    box-shadow: 0 0 14px rgba(56, 189, 248, 0.45);
}

.modal-content.frozen-state {
    border-color: rgba(56, 189, 248, 0.45) !important;
    box-shadow: 0 0 0 1px rgba(56, 189, 248, 0.28), 0 18px 50px rgba(0, 0, 0, 0.6);
}

/* Login */
.login-screen {
    background:
        radial-gradient(760px 320px at 50% 0%, rgba(16, 185, 129, 0.10), transparent 58%),
        var(--bg-main) !important;
}

.login-screen .modal-content {
    width: min(460px, calc(100vw - 32px));
    padding: 30px !important;
    border-radius: 20px !important;
}

.login-screen .logo-title {
    font-size: 28px !important;
}

/* FX */
.toast-container {
    position: fixed;
    right: 20px;
    bottom: 20px;
    z-index: 99999;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.toast {
    min-width: 300px;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 10px;
    background: #111216;
    border: 1px solid var(--border-default);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05), var(--shadow-soft);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    animation: toastSlideIn 0.3s ease;
}

.toast.success {
    border-left: 3px solid var(--clr-success);
}

.toast.error {
    border-left: 3px solid var(--clr-danger);
}

.toast.info {
    border-left: 3px solid var(--clr-primary);
}

.toast-msg {
    color: #e4e4e7;
    font-size: 12px;
    font-weight: 700;
}

@keyframes toastSlideIn {
    from {
        opacity: 0;
        transform: translateX(20px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes toastFadeOut {
    to {
        opacity: 0;
        transform: translateX(12px);
    }
}

.ripple {
    position: absolute;
    border-radius: 999px;
    transform: scale(0);
    animation: ripple 0.55s cubic-bezier(0, 0, 0.2, 1);
    background: rgba(255, 255, 255, 0.28);
    pointer-events: none;
}

@keyframes ripple {
    to {
        transform: scale(4);
        opacity: 0;
    }
}

#top-progress-bar {
    position: fixed;
    top: 0;
    left: 0;
    height: 2px;
    width: 0%;
    z-index: 100001;
    opacity: 0;
    background: linear-gradient(90deg, #10b981, #6ee7b7);
    box-shadow: var(--shadow-glow);
    transition: width 0.25s ease, opacity 0.25s ease;
}

#top-progress-bar.active {
    opacity: 1;
}

.btn-loading {
    position: relative;
    pointer-events: none;
    opacity: 0.72;
}

.btn-loading::after {
    content: "";
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.35);
    border-top-color: #fff;
    display: inline-block;
    margin-left: 8px;
    vertical-align: middle;
    animation: spin 0.7s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.shake {
    animation: shake 0.38s ease;
}

@keyframes shake {
    0%,
    100% {
        transform: translateX(0);
    }

    25% {
        transform: translateX(-5px);
    }

    75% {
        transform: translateX(5px);
    }
}

/* Mobile + tablet */
@media (max-width: 1200px) {
    .main-content {
        padding: 20px 20px 24px !important;
    }

    h2,
    .font-display {
        font-size: 32px !important;
    }

    .surface {
        padding: 18px !important;
    }
}

@media (max-width: 980px) {
    body {
        overflow: auto;
    }

    .layout {
        flex-direction: column;
        height: auto;
        min-height: 100vh;
    }

    .sidebar {
        width: 100% !important;
        height: auto;
        border-right: 0 !important;
        border-bottom: 1px solid var(--border-subtle) !important;
        padding: 10px !important;
    }

    .logo-area {
        margin: 0 0 10px !important;
        padding: 0 6px !important;
    }

    .logo-title {
        font-size: 28px !important;
    }

    .nav-group {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 6px;
        padding: 0 !important;
    }

    .nav-link {
        margin: 0;
        justify-content: center;
        text-align: center;
        padding: 9px 6px !important;
        font-size: 12px;
        gap: 6px;
    }

    .nav-icon {
        font-size: 15px;
    }

    .nav-label {
        font-size: 11px;
    }

    .main-content {
        padding: 14px 12px 18px !important;
    }

    .home-shell {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .home-main-col {
        gap: 14px;
    }

    .home-hero {
        min-height: 300px;
        padding: 20px !important;
    }

    .home-hero-top {
        flex-direction: column;
        align-items: flex-start;
    }

    .home-hero-actions {
        align-items: flex-start;
        width: 100%;
    }

    .home-kpi-value {
        font-size: clamp(44px, 12vw, 72px);
    }

    .home-kpi-description {
        font-size: 15px;
    }

    .home-metric-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .home-feed {
        min-height: 0;
        padding: 18px !important;
    }

    .table-header {
        flex-direction: column;
        align-items: stretch !important;
        gap: 10px !important;
    }

    .license-toolbar-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .smart-search {
        grid-column: 1 / -1;
    }

    .new-license-btn {
        grid-column: 2;
    }

    .facet-clear-btn {
        grid-column: 1;
    }

    .bulk-action-bar {
        flex-direction: column;
        align-items: flex-start;
    }

    .bulk-actions {
        width: 100%;
        justify-content: flex-start;
    }

    .search-bar {
        width: 100% !important;
        min-width: 0 !important;
        max-width: none !important;
    }

    .modern-table {
        font-size: 11px;
    }

    .modern-table th,
    .modern-table td {
        padding: 9px;
    }

    .col-select {
        width: 6%;
    }

    .col-key {
        width: 30%;
    }

    .col-actions {
        width: 15%;
    }

    .info-card-grid,
    .lic-sec-grid,
    .sec-main-grid,
    .sec-summary-grid {
        grid-template-columns: 1fr !important;
    }

    .toast-container {
        right: 10px;
        left: 10px;
        bottom: 10px;
    }

    .toast {
        min-width: 0;
        width: 100%;
    }

    .create-key-modal {
        padding: 18px !important;
        gap: 10px;
    }

    .create-key-grid-2 {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .license-toolbar-grid {
        grid-template-columns: 1fr;
    }

    .facet-clear-btn,
    .new-license-btn {
        grid-column: auto;
    }

    .smart-view-bar {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .bulk-actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
        width: 100%;
    }

    .bulk-actions .btn {
        width: 100%;
    }

    .create-key-modal {
        padding: 16px !important;
    }

    .create-key-keyrow {
        flex-direction: column;
    }

    .create-key-random-btn {
        width: 100%;
        min-width: 0;
        flex: 1 1 auto;
    }

    .create-key-grid-duration,
    .create-key-actions {
        grid-template-columns: 1fr;
    }

    .create-key-duration-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .create-key-expiry {
        text-align: left;
    }

    .btn {
        padding: 10px 14px !important;
        font-size: 11px !important;
    }

    h2,
    .font-display {
        font-size: 27px !important;
    }

    .modal-content {
        width: calc(100vw - 20px) !important;
        max-height: calc(100vh - 20px);
        overflow-y: auto;
    }
}
