﻿:root {
    color-scheme: dark;
    --noctra-bg: #08101f;
    --noctra-bg-alt: #0e1830;
    --noctra-surface: rgba(15, 24, 48, 0.92);
    --noctra-surface-2: rgba(25, 37, 68, 0.94);
    --noctra-surface-3: rgba(34, 49, 86, 0.95);
    --noctra-surface-soft: rgba(255, 255, 255, 0.03);
    --noctra-border: rgba(141, 176, 255, 0.14);
    --noctra-border-strong: rgba(141, 176, 255, 0.22);
    --noctra-text: #edf3ff;
    --noctra-text-soft: #b5c4e5;
    --noctra-text-dim: #8395bc;
    --noctra-accent: #67ddff;
    --noctra-accent-2: #8a78ff;
    --noctra-success: #41d6a4;
    --noctra-warning: #f2b96f;
    --noctra-danger: #ff6f86;
    --noctra-shadow: 0 28px 70px rgba(2, 8, 24, 0.48);
    --noctra-shadow-soft: 0 12px 28px rgba(1, 8, 24, 0.32);
    --noctra-radius-xl: 28px;
    --noctra-radius-lg: 22px;
    --noctra-radius-md: 16px;
    --noctra-radius-sm: 12px;
    --ant-primary-color: #67ddff;
    --ant-primary-color-hover: #83e6ff;
    --ant-primary-color-active: #48d2fb;
    --ant-success-color: #41d6a4;
    --ant-warning-color: #f2b96f;
    --ant-error-color: #ff6f86;
}

html,
body {
    min-height: 100%;
}

html {
    background:
        radial-gradient(circle at top left, rgba(103, 221, 255, 0.14), transparent 24%),
        radial-gradient(circle at 85% 12%, rgba(138, 120, 255, 0.12), transparent 26%),
        linear-gradient(180deg, #0a1326 0%, #08101f 38%, #060c18 100%);
    font-size: 15px;
    text-size-adjust: 100%;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    color: var(--noctra-text);
    font-family: "Segoe UI Variable Text", "Segoe UI", "Trebuchet MS", sans-serif;
    background: transparent;
}

* {
    box-sizing: border-box;
}

a {
    color: var(--noctra-accent);
    text-decoration: none;
}

a:hover {
    color: #9eeaff;
}

strong,
b,
h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--noctra-text);
}

::selection {
    background: rgba(103, 221, 255, 0.22);
    color: var(--noctra-text);
}

#app,
#app > .ant-layout {
    min-height: 100vh;
    background: transparent;
}

.app-shell {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 24px;
    padding: 22px;
    position: relative;
}

.app-shell__backdrop {
    display: none;
}

.app-shell__sidebar {
    position: sticky;
    top: 22px;
    height: calc(100vh - 44px);
    border: 1px solid var(--noctra-border);
    background:
        linear-gradient(180deg, rgba(22, 35, 66, 0.95), rgba(11, 18, 36, 0.96)),
        radial-gradient(circle at 10% 10%, rgba(103, 221, 255, 0.12), transparent 28%);
    border-radius: 30px;
    padding: 22px 18px 18px;
    display: flex;
    flex-direction: column;
    box-shadow: var(--noctra-shadow);
    overflow: hidden;
}

.app-shell__sidebar::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at top left, rgba(138, 120, 255, 0.12), transparent 30%);
    pointer-events: none;
}

.app-shell__brand,
.app-shell__nav,
.app-shell__sidebar-foot {
    position: relative;
    z-index: 1;
}

.app-shell__brand {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 24px;
    padding: 6px 8px 18px;
    border-bottom: 1px solid rgba(141, 176, 255, 0.1);
}

.app-shell__brand-mark {
    width: 54px;
    height: 54px;
    object-fit: contain;
    filter: drop-shadow(0 10px 18px rgba(115, 164, 255, 0.22));
}

.app-shell__brand-name {
    font-size: 1.3rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.app-shell__brand-meta {
    color: var(--noctra-text-dim);
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.22em;
}

.app-shell__nav {
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 1;
}

.app-shell__nav-group {
    margin: 14px 8px 8px;
    color: var(--noctra-text-dim);
    font-size: 0.73rem;
    text-transform: uppercase;
    letter-spacing: 0.22em;
}

.app-shell__nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border-radius: 16px;
    color: var(--noctra-text-soft);
    transition: background-color 0.22s ease, color 0.22s ease, transform 0.22s ease, border-color 0.22s ease;
    border: 1px solid transparent;
}

.app-shell__nav-link .anticon {
    font-size: 1rem;
}

.app-shell__nav-link:hover {
    color: var(--noctra-text);
    transform: translateX(2px);
    border-color: rgba(141, 176, 255, 0.12);
    background: rgba(255, 255, 255, 0.04);
}

.app-shell__nav-link.active {
    color: #ffffff;
    border-color: rgba(95, 223, 255, 0.28);
    background: linear-gradient(90deg, rgba(29, 173, 173, 0.22), rgba(111, 102, 255, 0.16));
    box-shadow: inset 0 0 0 1px rgba(103, 221, 255, 0.1);
}

.app-shell__sidebar-foot {
    display: grid;
    gap: 12px;
    padding-top: 18px;
    border-top: 1px solid rgba(141, 176, 255, 0.1);
}

.app-shell__cluster-pill,
.app-shell__status-chip,
.app-shell__logout {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    min-height: 42px;
    padding: 0 14px;
    border-radius: 999px;
    border: 1px solid rgba(141, 176, 255, 0.14);
    background: rgba(255, 255, 255, 0.03);
    color: var(--noctra-text-soft);
}

.app-shell__logout {
    justify-content: center;
}

.app-shell__logout:hover {
    color: white;
    border-color: rgba(103, 221, 255, 0.22);
    background: rgba(103, 221, 255, 0.08);
}

.app-shell__cluster-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--noctra-success);
    box-shadow: 0 0 0 6px rgba(65, 214, 164, 0.12);
}

.app-shell__workspace {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.app-shell__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 18px;
    padding: 28px 30px;
    border-radius: 30px;
    border: 1px solid var(--noctra-border);
    background:
        radial-gradient(circle at top left, rgba(103, 221, 255, 0.08), transparent 22%),
        radial-gradient(circle at 88% 12%, rgba(138, 120, 255, 0.1), transparent 20%),
        linear-gradient(180deg, rgba(18, 29, 52, 0.92), rgba(12, 19, 36, 0.96));
    box-shadow: var(--noctra-shadow-soft);
}

.app-shell__header-main {
    display: flex;
    align-items: flex-start;
    gap: 18px;
}

.app-shell__menu-toggle {
    width: 46px;
    height: 46px;
    border-radius: 14px;
    border: 1px solid rgba(141, 176, 255, 0.14);
    background: rgba(255, 255, 255, 0.03);
    display: none;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
    padding: 0;
}

.app-shell__menu-toggle span {
    width: 18px;
    height: 2px;
    border-radius: 999px;
    background: var(--noctra-text);
}

.app-shell__eyebrow {
    color: var(--noctra-accent);
    text-transform: uppercase;
    letter-spacing: 0.28em;
    font-size: 0.74rem;
    margin-bottom: 8px;
}

.app-shell__title {
    margin: 0;
    font-size: clamp(1.8rem, 2vw, 2.4rem);
    line-height: 1.05;
}

.app-shell__subtitle {
    margin: 10px 0 0;
    max-width: 700px;
    color: var(--noctra-text-soft);
}

.app-shell__header-meta {
    display: flex;
    align-items: stretch;
    gap: 14px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.app-shell__user-card {
    min-width: 170px;
    padding: 10px 16px;
    border-radius: 18px;
    border: 1px solid rgba(141, 176, 255, 0.14);
    background: rgba(255, 255, 255, 0.03);
}

.app-shell__user-label {
    color: var(--noctra-text-dim);
    font-size: 0.77rem;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    margin-bottom: 6px;
}

.app-shell__user-name {
    font-size: 1rem;
    font-weight: 600;
}

.app-shell__content {
    min-width: 0;
    padding-bottom: 32px;
}

.page-heading {
    margin-bottom: 18px;
}

.page-heading__eyebrow {
    color: var(--noctra-accent);
    font-size: 0.75rem;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    margin-bottom: 10px;
}

.page-heading__title {
    margin: 0;
    font-size: clamp(1.55rem, 1.6vw, 2rem);
}

.page-heading__text {
    margin: 10px 0 0;
    max-width: 860px;
    color: var(--noctra-text-soft);
}

.metric-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    margin-bottom: 18px;
}

.metric-card {
    border: 1px solid var(--noctra-border);
    border-radius: 24px;
    background: linear-gradient(180deg, rgba(20, 31, 57, 0.96), rgba(12, 20, 38, 0.96));
    padding: 22px;
    box-shadow: var(--noctra-shadow-soft);
}

.metric-card__label {
    color: var(--noctra-text-dim);
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    margin-bottom: 12px;
}

.metric-card__value {
    font-size: clamp(1.35rem, 1.5vw, 1.9rem);
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 8px;
}

.metric-card__sub {
    color: var(--noctra-text-soft);
    font-size: 0.92rem;
}

.noctra-surface-block,
.ant-card,
.ant-tabs,
.ant-descriptions-bordered .ant-descriptions-view,
.ant-modal-content,
.ant-drawer-content,
.ant-collapse,
.ant-table,
.ant-table-placeholder,
.ant-select-dropdown,
.ant-dropdown-menu,
.ant-popover-inner,
.ant-alert,
.ant-empty-normal {
    color: var(--noctra-text);
    background: linear-gradient(180deg, rgba(20, 31, 57, 0.96), rgba(12, 20, 38, 0.96)) !important;
    border: 1px solid var(--noctra-border) !important;
    box-shadow: var(--noctra-shadow-soft);
}

.ant-card,
.ant-tabs,
.ant-modal-content,
.ant-collapse,
.ant-popover-inner,
.ant-empty-normal {
    border-radius: 24px !important;
}

.ant-card-head,
.ant-tabs-bar,
.ant-collapse > .ant-collapse-item > .ant-collapse-header,
.ant-modal-header,
.ant-descriptions-bordered .ant-descriptions-item-label,
.ant-descriptions-bordered .ant-descriptions-item-content,
.ant-table-thead > tr > th {
    background: rgba(255, 255, 255, 0.03) !important;
    color: var(--noctra-text) !important;
    border-color: var(--noctra-border) !important;
}

.ant-card-head,
.ant-tabs-bar,
.ant-modal-header,
.ant-collapse > .ant-collapse-item,
.ant-descriptions-bordered .ant-descriptions-row,
.ant-table-thead > tr > th,
.ant-table-tbody > tr > td,
.ant-table-placeholder,
.ant-table-bordered,
.ant-table-bordered table {
    border-color: var(--noctra-border) !important;
}

.ant-card-head-title,
.ant-card-extra,
.ant-tabs-tab,
.ant-modal-title,
.ant-descriptions-item-label,
.ant-descriptions-item-content,
.ant-collapse-header,
.ant-form-item-label > label,
.ant-alert-message,
.ant-alert-description,
.ant-page-header-heading-title,
.ant-page-header-back-button,
.ant-page-header-heading-sub-title {
    color: var(--noctra-text) !important;
}

.ant-card-extra,
.ant-page-header-heading-sub-title,
.ant-table-tbody,
.ant-table-tbody > tr > td,
.ant-form-item,
.ant-empty-description,
.ant-select-dropdown-menu-item,
.ant-dropdown-menu-item,
.ant-popover-inner-content,
.ant-alert-description,
.ant-descriptions-item-content,
.ant-table-placeholder {
    color: var(--noctra-text-soft) !important;
}

.ant-page-header {
    padding: 0 0 18px !important;
}

.ant-page-header-heading {
    border-radius: 24px;
    padding: 24px 26px;
    border: 1px solid var(--noctra-border);
    background: linear-gradient(180deg, rgba(20, 31, 57, 0.96), rgba(12, 20, 38, 0.96));
    box-shadow: var(--noctra-shadow-soft);
}

.ant-page-header-back-button,
.ant-page-header-heading-extra,
.ant-page-header-heading-left,
.ant-page-header-heading-sub-title,
.ant-page-header-heading-title,
.ant-page-header-ghost {
    color: var(--noctra-text) !important;
}

.ant-page-header-heading-extra {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.ant-btn {
    min-height: 42px;
    padding-inline: 16px;
    border-radius: 14px !important;
    border-color: rgba(141, 176, 255, 0.16) !important;
    background: rgba(255, 255, 255, 0.03) !important;
    color: var(--noctra-text) !important;
    box-shadow: none !important;
}

.ant-btn:hover,
.ant-btn:focus {
    border-color: rgba(103, 221, 255, 0.26) !important;
    color: #ffffff !important;
    background: rgba(103, 221, 255, 0.08) !important;
}

.ant-btn-primary {
    background: linear-gradient(135deg, rgba(70, 210, 255, 0.98), rgba(131, 120, 255, 0.92)) !important;
    border-color: transparent !important;
    color: #06101f !important;
    font-weight: 700;
}

.ant-btn-primary:hover,
.ant-btn-primary:focus {
    background: linear-gradient(135deg, rgba(100, 220, 255, 1), rgba(156, 145, 255, 0.96)) !important;
    color: #05101f !important;
}

.ant-btn-dangerous,
.ant-btn[style*="ff4d4f"] {
    color: #ffe8ec !important;
    border-color: rgba(255, 111, 134, 0.4) !important;
    background: rgba(255, 111, 134, 0.1) !important;
}

.ant-btn-dangerous:hover,
.ant-btn[style*="ff4d4f"]:hover {
    background: rgba(255, 111, 134, 0.18) !important;
    border-color: rgba(255, 111, 134, 0.58) !important;
}

.ant-input,
.ant-input-affix-wrapper,
.ant-input-number,
.ant-input-number-input,
.ant-input-group-addon,
.ant-select-selection,
.ant-select-selection--multiple,
.ant-select-dropdown,
.ant-calendar,
.ant-picker,
textarea.ant-input {
    background: rgba(255, 255, 255, 0.035) !important;
    color: var(--noctra-text) !important;
    border-color: rgba(141, 176, 255, 0.14) !important;
    border-radius: 14px !important;
}

.ant-input-number,
.ant-select-selection,
.ant-input,
.ant-input-affix-wrapper {
    min-height: 44px;
}

.ant-input::placeholder,
textarea.ant-input::placeholder {
    color: rgba(181, 196, 229, 0.45) !important;
}

.ant-input:hover,
.ant-input:focus,
textarea.ant-input:hover,
textarea.ant-input:focus,
.ant-input-affix-wrapper:hover,
.ant-input-affix-wrapper-focused,
.ant-input-number:hover,
.ant-input-number-focused,
.ant-select-selection:hover,
.ant-select-open .ant-select-selection {
    border-color: rgba(103, 221, 255, 0.32) !important;
    box-shadow: 0 0 0 3px rgba(103, 221, 255, 0.08) !important;
}

.ant-input-number-handler-wrap,
.ant-input-number-handler {
    background: rgba(255, 255, 255, 0.035) !important;
    border-color: rgba(141, 176, 255, 0.14) !important;
}

.ant-switch {
    background: rgba(255, 255, 255, 0.14) !important;
}

.ant-switch-checked {
    background: linear-gradient(135deg, rgba(70, 210, 255, 0.98), rgba(131, 120, 255, 0.92)) !important;
}

.ant-tag {
    border-radius: 999px !important;
    border: 1px solid rgba(141, 176, 255, 0.18) !important;
    background: rgba(255, 255, 255, 0.04) !important;
    color: var(--noctra-text-soft) !important;
    padding-inline: 10px;
    min-height: 26px;
    display: inline-flex;
    align-items: center;
}

.ant-tag-green {
    background: rgba(65, 214, 164, 0.12) !important;
    border-color: rgba(65, 214, 164, 0.32) !important;
    color: #6af0bf !important;
}

.ant-tag-red {
    background: rgba(255, 111, 134, 0.12) !important;
    border-color: rgba(255, 111, 134, 0.28) !important;
    color: #ff9dad !important;
}

.ant-tag-blue {
    background: rgba(103, 221, 255, 0.1) !important;
    border-color: rgba(103, 221, 255, 0.28) !important;
    color: #9aeaff !important;
}

.ant-tag-orange {
    background: rgba(242, 185, 111, 0.12) !important;
    border-color: rgba(242, 185, 111, 0.28) !important;
    color: #ffd19a !important;
}

.ant-tag-purple {
    background: rgba(138, 120, 255, 0.12) !important;
    border-color: rgba(138, 120, 255, 0.28) !important;
    color: #c4b6ff !important;
}

.ant-table {
    border-radius: 22px !important;
    overflow: hidden;
}

.ant-table-thead > tr > th {
    font-size: 0.76rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--noctra-text-dim) !important;
}

.ant-table-tbody > tr > td {
    background: transparent !important;
}

.ant-table-tbody > tr.ant-table-row:hover > td,
.ant-table-tbody > tr:hover > td {
    background: rgba(255, 255, 255, 0.03) !important;
}

.ant-tabs-tab {
    color: var(--noctra-text-soft) !important;
    padding: 12px 0 !important;
}

.ant-tabs-tab:hover,
.ant-tabs-tab-active,
.ant-tabs-tab-active .ant-tabs-tab-btn,
.ant-tabs-tab:hover .ant-tabs-tab-btn {
    color: white !important;
}

.ant-tabs-ink-bar {
    background: linear-gradient(90deg, var(--noctra-accent), var(--noctra-accent-2)) !important;
    height: 3px !important;
    border-radius: 999px;
}

.ant-modal-mask {
    background: rgba(2, 7, 18, 0.74) !important;
}

.ant-dropdown-menu-item:hover,
.ant-select-dropdown-menu-item:hover,
.ant-select-dropdown-menu-item-active,
.ant-dropdown-menu-item-active {
    background: rgba(103, 221, 255, 0.08) !important;
}

.ant-alert {
    border-radius: 18px !important;
}

.ant-alert-info {
    background: rgba(103, 221, 255, 0.08) !important;
}

.ant-alert-warning {
    background: rgba(242, 185, 111, 0.12) !important;
}

.ant-alert-error {
    background: rgba(255, 111, 134, 0.12) !important;
}

.ant-spin-dot-item,
.ant-badge-status-processing::after,
.ant-badge-status-processing .ant-badge-status-dot,
.ant-progress-bg,
.ant-progress-success-bg {
    background: linear-gradient(90deg, var(--noctra-accent), var(--noctra-accent-2)) !important;
    border-color: rgba(103, 221, 255, 0.3) !important;
}

.ant-badge-status-success {
    background: var(--noctra-success) !important;
}

.ant-descriptions-bordered .ant-descriptions-item-label {
    width: 170px;
    color: var(--noctra-text-dim) !important;
    text-transform: uppercase;
    font-size: 0.76rem;
    letter-spacing: 0.12em;
}

.ant-statistic {
    color: var(--noctra-text);
}

.ant-statistic-content,
.ant-statistic-content-value,
.ant-statistic-content-suffix,
.ant-statistic-title {
    color: inherit !important;
}

.ant-statistic-title {
    color: var(--noctra-text-dim) !important;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 0.78rem;
}

.ant-statistic-content {
    font-size: clamp(1.4rem, 1.5vw, 1.9rem);
    font-weight: 700;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
    gap: 16px;
}

.dashboard-node-list {
    display: grid;
    gap: 10px;
}

.dashboard-node {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto auto;
    gap: 14px;
    align-items: center;
    padding: 14px 16px;
    border: 1px solid rgba(141, 176, 255, 0.1);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.025);
}

.dashboard-node__status {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    box-shadow: 0 0 0 6px rgba(255, 255, 255, 0.05);
}

.dashboard-node__status.is-online {
    background: var(--noctra-success);
    box-shadow: 0 0 0 6px rgba(65, 214, 164, 0.12);
}

.dashboard-node__status.is-offline {
    background: var(--noctra-danger);
    box-shadow: 0 0 0 6px rgba(255, 111, 134, 0.12);
}

.dashboard-node__title {
    font-weight: 600;
    margin-bottom: 4px;
}

.dashboard-node__meta,
.dashboard-node__hint {
    color: var(--noctra-text-dim);
    font-size: 0.88rem;
}

.inbounds-summary,
.nodes-summary,
.settings-summary {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    margin-bottom: 18px;
}

.nodes-list {
    display: grid;
    gap: 14px;
}

.node-card {
    border: 1px solid rgba(141, 176, 255, 0.12);
    border-radius: 24px;
    padding: 18px 20px;
    display: flex;
    gap: 18px;
    justify-content: space-between;
    align-items: flex-start;
    background: rgba(255, 255, 255, 0.025);
}

.node-card__main {
    flex: 1;
    display: grid;
    grid-template-columns: minmax(240px, 1.45fr) repeat(4, minmax(120px, 0.8fr));
    gap: 16px;
    align-items: start;
}

.node-card__identity {
    display: flex;
    gap: 14px;
    align-items: flex-start;
}

.node-card__title {
    color: var(--noctra-text);
}

.node-card__meta,
.node-card__muted,
.node-card__section-label,
.node-card__error {
    color: var(--noctra-text-dim);
}

.node-card__section-label {
    font-size: 0.76rem;
    text-transform: uppercase;
    letter-spacing: 0.14em;
    margin-bottom: 8px;
}

.node-card__actions {
    width: 340px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
}

.inbound-modal-note,
.settings-note {
    color: var(--noctra-text-soft);
}

.login-shell {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 32px;
    background:
        radial-gradient(circle at 18% 18%, rgba(103, 221, 255, 0.14), transparent 24%),
        radial-gradient(circle at 82% 20%, rgba(138, 120, 255, 0.18), transparent 24%),
        linear-gradient(180deg, #08101f 0%, #0b1428 100%);
}

.login-panel {
    width: min(1080px, 100%);
    display: grid;
    grid-template-columns: minmax(0, 0.95fr) minmax(360px, 430px);
    gap: 26px;
}

.login-showcase,
.login-card {
    border: 1px solid var(--noctra-border);
    border-radius: 32px;
    background: linear-gradient(180deg, rgba(20, 31, 57, 0.96), rgba(12, 20, 38, 0.96));
    box-shadow: var(--noctra-shadow);
}

.login-showcase {
    position: relative;
    overflow: hidden;
    padding: 48px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.login-showcase::before {
    content: "";
    position: absolute;
    inset: auto -8% -15% auto;
    width: 340px;
    height: 340px;
    background: radial-gradient(circle, rgba(138, 120, 255, 0.34), transparent 62%);
    filter: blur(12px);
}

.login-showcase::after {
    content: "";
    position: absolute;
    inset: -12% auto auto -8%;
    width: 280px;
    height: 280px;
    background: radial-gradient(circle, rgba(103, 221, 255, 0.22), transparent 64%);
    filter: blur(10px);
}

.login-showcase__brand,
.login-showcase__grid,
.login-card {
    position: relative;
    z-index: 1;
}

.login-showcase__brand {
    display: flex;
    align-items: center;
    gap: 18px;
}

.login-showcase__brand img {
    width: 78px;
    height: 78px;
    object-fit: contain;
}

.login-showcase__eyebrow {
    color: var(--noctra-accent);
    text-transform: uppercase;
    letter-spacing: 0.28em;
    font-size: 0.78rem;
    margin-bottom: 8px;
}

.login-showcase__title {
    font-size: clamp(2rem, 3vw, 3.2rem);
    line-height: 1;
    margin: 0;
}

.login-showcase__text {
    margin: 16px 0 0;
    max-width: 520px;
    color: var(--noctra-text-soft);
    font-size: 1rem;
}

.login-showcase__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.login-showcase__tile {
    padding: 18px;
    border-radius: 22px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(141, 176, 255, 0.1);
}

.login-showcase__tile-title {
    color: var(--noctra-text-dim);
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    margin-bottom: 8px;
}

.login-showcase__tile-value {
    font-size: 1.05rem;
    font-weight: 600;
}

.login-card {
    padding: 36px 34px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.login-card__eyebrow {
    color: var(--noctra-accent);
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.24em;
    margin-bottom: 12px;
}

.login-card__title {
    font-size: 1.8rem;
    margin: 0 0 10px;
}

.login-card__text {
    color: var(--noctra-text-soft);
    margin: 0 0 24px;
}

.login-field {
    margin-bottom: 16px;
}

.login-field label {
    display: block;
    margin-bottom: 8px;
    color: var(--noctra-text-soft);
    font-size: 0.9rem;
}

.login-input {
    width: 100%;
    min-height: 50px;
    border-radius: 16px;
    border: 1px solid rgba(141, 176, 255, 0.14);
    background: rgba(255, 255, 255, 0.04);
    color: var(--noctra-text);
    padding: 0 16px;
    font: inherit;
}

.login-input:focus {
    outline: none;
    border-color: rgba(103, 221, 255, 0.32);
    box-shadow: 0 0 0 3px rgba(103, 221, 255, 0.08);
}

.login-error {
    margin-bottom: 14px;
    padding: 12px 14px;
    border-radius: 16px;
    color: #ffdce3;
    border: 1px solid rgba(255, 111, 134, 0.32);
    background: rgba(255, 111, 134, 0.1);
}

.login-submit {
    width: 100%;
    min-height: 50px;
    border: none;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(70, 210, 255, 0.98), rgba(131, 120, 255, 0.92));
    color: #08101f;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 12px 28px rgba(87, 157, 255, 0.22);
}

.login-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 16px 36px rgba(87, 157, 255, 0.28);
}

#blazor-error-ui {
    color-scheme: dark;
    background: rgba(255, 111, 134, 0.12);
    border-top: 1px solid rgba(255, 111, 134, 0.32);
    color: #ffe8ec;
    bottom: 0;
    display: none;
    left: 0;
    padding: 0.9rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

#blazor-error-ui .reload {
    color: #fff;
    text-decoration: underline;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid rgba(65, 214, 164, 0.58);
}

.invalid {
    outline: 1px solid rgba(255, 111, 134, 0.62);
}

.validation-message {
    color: #ff99a9;
}

@media (max-width: 1280px) {
    .metric-grid,
    .inbounds-summary,
    .nodes-summary,
    .settings-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .node-card {
        flex-direction: column;
    }

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

    .node-card__actions {
        width: 100%;
        justify-content: flex-start;
    }

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

@media (max-width: 960px) {
    .app-shell {
        grid-template-columns: 1fr;
        padding: 14px;
        gap: 14px;
    }

    .app-shell__backdrop.is-visible {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(2, 7, 18, 0.6);
        z-index: 40;
    }

    .app-shell__sidebar {
        position: fixed;
        top: 14px;
        left: 14px;
        bottom: 14px;
        width: min(320px, calc(100vw - 28px));
        height: auto;
        transform: translateX(calc(-100% - 30px));
        transition: transform 0.22s ease;
        z-index: 50;
    }

    .app-shell__sidebar.is-open {
        transform: translateX(0);
    }

    .app-shell__menu-toggle {
        display: inline-flex;
    }

    .app-shell__header {
        padding: 22px 20px;
        flex-direction: column;
        align-items: stretch;
    }

    .app-shell__header-meta {
        justify-content: space-between;
    }

    .login-panel {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 720px) {
    .metric-grid,
    .inbounds-summary,
    .nodes-summary,
    .settings-summary,
    .login-showcase__grid,
    .node-card__main {
        grid-template-columns: 1fr;
    }

    .app-shell__header-main {
        align-items: flex-start;
    }

    .app-shell__title {
        font-size: 1.65rem;
    }

    .ant-card,
    .ant-tabs,
    .ant-modal-content,
    .ant-page-header-heading {
        border-radius: 20px !important;
    }

    .login-showcase,
    .login-card {
        padding: 28px 22px;
    }

    .dashboard-node {
        grid-template-columns: auto minmax(0, 1fr);
    }
}

.inbound-designer {
    display: grid;
    gap: 18px;
}

.inbound-designer__rail {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 12px;
}

.inbound-designer__rail-item {
    border: 1px solid rgba(138, 120, 255, 0.18);
    border-radius: 18px;
    padding: 14px 16px;
    background: linear-gradient(180deg, rgba(16, 25, 45, 0.88), rgba(11, 18, 34, 0.92));
}

.inbound-designer__rail-label {
    color: var(--noctra-text-dim);
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 0.72rem;
    margin-bottom: 10px;
}

.inbound-designer__rail-value {
    color: var(--noctra-text);
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 6px;
}

.inbound-designer__rail-sub {
    color: var(--noctra-text-soft);
    font-size: 0.84rem;
    line-height: 1.45;
}

.inbound-section-card__desc {
    color: var(--noctra-text-soft);
    margin-bottom: 14px;
    line-height: 1.55;
}

.inbound-inline-actions {
    margin-top: 10px;
}

.inbound-inline-hint {
    margin-top: 8px;
    border: 1px solid rgba(103, 221, 255, 0.14);
    border-radius: 14px;
    padding: 10px 12px;
    color: var(--noctra-text-soft);
    background: rgba(8, 18, 34, 0.72);
}

.inbound-inline-hint--muted {
    border-color: rgba(255, 255, 255, 0.08);
}

.inbound-hub {
    display: grid;
    gap: 18px;
}

.inbound-hub__empty {
    border: 1px dashed rgba(141, 176, 255, 0.2);
    border-radius: 18px;
    padding: 22px;
    color: var(--noctra-text-soft);
    background: rgba(8, 18, 34, 0.55);
    line-height: 1.6;
}

.inbound-hub__hero {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: flex-start;
    padding: 18px 20px;
    border: 1px solid rgba(138, 120, 255, 0.16);
    border-radius: 20px;
    background: linear-gradient(180deg, rgba(16, 25, 45, 0.92), rgba(10, 17, 32, 0.94));
}

.inbound-hub__eyebrow {
    color: var(--noctra-text-dim);
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 0.72rem;
    margin-bottom: 10px;
}

.inbound-hub__title {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--noctra-text);
}

.inbound-hub__subtitle {
    margin-top: 6px;
    color: var(--noctra-text-soft);
}

.inbound-hub__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
}

.inbound-hub__toolbar {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: wrap;
    align-items: center;
}

.inbound-hub__filters {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.inbound-hub__filters-meta {
    color: var(--noctra-text-dim);
    font-size: 0.84rem;
    padding-left: 4px;
}

.inbound-hub__bulk-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}

.inbound-hub__metrics {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 12px;
}

.inbound-hub__metric {
    border: 1px solid rgba(103, 221, 255, 0.12);
    border-radius: 18px;
    padding: 16px 18px;
    background: rgba(8, 18, 34, 0.72);
}

.inbound-hub__metric-label {
    color: var(--noctra-text-dim);
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 0.72rem;
}

.inbound-hub__metric-value {
    color: var(--noctra-text);
    font-size: 1.25rem;
    font-weight: 700;
    margin-top: 10px;
}

.inbound-hub__metric-sub {
    color: var(--noctra-text-soft);
    margin-top: 6px;
    line-height: 1.45;
}

.inbound-hub__client-cell {
    display: grid;
    gap: 4px;
}

.inbound-hub__subscriber-cell {
    display: grid;
    gap: 10px;
}

.inbound-hub__subscriber-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
}
.inbound-hub__client-title {
    color: var(--noctra-text);
    font-weight: 600;
}

.inbound-hub__client-sub {
    color: var(--noctra-text-dim);
    font-size: 0.84rem;
}

@media (max-width: 1400px) {
    .inbound-designer__rail {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .inbound-hub__metrics {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 720px) {
    .inbound-designer__rail {
        grid-template-columns: minmax(0, 1fr);
    }

    .inbound-hub__hero {
        flex-direction: column;
    }

    .inbound-hub__meta,
    .inbound-hub__metrics {
        grid-template-columns: minmax(0, 1fr);
        justify-content: flex-start;
    }
}








.inbound-hub__connections-stack {
    display: grid;
    gap: 18px;
}

.inbound-hub__section-title {
    color: var(--noctra-text);
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 10px;
}

/* Inbound Hub design pass: denser operator layout inspired by 3x-ui rhythm */
.inbounds-summary {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 16px;
}

.metric-card {
    min-height: 132px;
    padding: 18px 20px;
    border-radius: 22px;
    background: linear-gradient(180deg, rgba(16, 25, 45, 0.94), rgba(10, 16, 30, 0.96));
    border-color: rgba(103, 221, 255, 0.12);
}

.metric-card__label {
    font-size: 0.7rem;
    letter-spacing: 0.18em;
}

.metric-card__value {
    margin-top: 14px;
    font-size: 2rem;
    line-height: 1;
}

.metric-card__sub {
    margin-top: 10px;
    max-width: 28ch;
}

.inbound-hub--embedded {
    gap: 14px;
    padding: 6px 2px 2px;
}

.inbound-hub__hero {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(320px, 0.9fr);
    gap: 18px;
    align-items: start;
    padding: 16px 18px;
    border-radius: 22px;
    border-color: rgba(103, 221, 255, 0.14);
    background:
        radial-gradient(circle at top left, rgba(103, 221, 255, 0.07), transparent 30%),
        linear-gradient(180deg, rgba(18, 27, 47, 0.96), rgba(9, 15, 30, 0.98));
}

.inbound-hub__subtitle {
    max-width: 56ch;
    line-height: 1.5;
}

.inbound-hub__meta {
    justify-content: flex-start;
    align-content: start;
}

.inbound-hub__toolbar {
    padding: 14px 16px;
    border-radius: 18px;
    border: 1px solid rgba(141, 176, 255, 0.12);
    background: rgba(6, 12, 26, 0.72);
}

.inbound-hub__filters,
.inbound-hub__bulk-actions {
    gap: 8px;
}

.inbound-hub__filters-meta {
    width: 100%;
    padding-left: 0;
    padding-top: 2px;
}

.inbound-hub__metrics {
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 10px;
}

.inbound-hub__metric {
    padding: 12px 14px;
    border-radius: 16px;
    background: rgba(10, 17, 32, 0.82);
}

.inbound-hub__metric-value {
    margin-top: 8px;
    font-size: 1.05rem;
}

.inbound-hub__metric-sub {
    margin-top: 4px;
    font-size: 0.79rem;
}

.inbound-hub__table-head {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 18px;
    padding: 4px 2px 0;
}

.inbound-hub__table-hint,
.inbound-hub__section-sub {
    color: var(--noctra-text-dim);
    font-size: 0.84rem;
    line-height: 1.45;
}

.inbound-hub__section-title {
    margin-bottom: 4px;
}

.inbound-hub .ant-input,
.inbound-hub .ant-input-affix-wrapper,
.inbound-hub .ant-input-number,
.inbound-hub .ant-select:not(.ant-select-customize-input) .ant-select-selector {
    min-height: 38px;
    border-radius: 12px;
    background: rgba(17, 25, 41, 0.96) !important;
    border-color: rgba(141, 176, 255, 0.16) !important;
    color: var(--noctra-text) !important;
    box-shadow: none !important;
}

.inbound-hub .ant-select-selection-placeholder,
.inbound-hub .ant-select-selection-item,
.inbound-hub .ant-select-arrow,
.inbound-hub .ant-input,
.inbound-hub .ant-input-number-input {
    color: var(--noctra-text) !important;
}

.inbound-hub .ant-select-selection-placeholder {
    color: var(--noctra-text-dim) !important;
}

.inbound-hub .ant-select-clear {
    background: transparent;
    color: var(--noctra-text-dim);
}

.inbound-hub .ant-btn {
    min-height: 38px;
    border-radius: 12px;
}

.inbound-hub .ant-btn:not(.ant-btn-primary):not(.ant-btn-dangerous) {
    background: rgba(17, 25, 41, 0.94);
    border-color: rgba(141, 176, 255, 0.14);
    color: var(--noctra-text-soft);
}

.inbound-hub .ant-btn:not(.ant-btn-primary):not(.ant-btn-dangerous):hover,
.inbound-hub .ant-btn:not(.ant-btn-primary):not(.ant-btn-dangerous):focus {
    color: var(--noctra-text);
    border-color: rgba(103, 221, 255, 0.2);
    background: rgba(20, 30, 50, 0.98);
}

.inbound-hub .ant-table {
    border: 1px solid rgba(141, 176, 255, 0.1);
    border-radius: 18px;
    overflow: hidden;
}

.inbound-hub .ant-table-thead > tr > th {
    background: rgba(16, 24, 42, 0.98);
    color: #93a7d3;
    font-size: 0.72rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.inbound-hub .ant-table-tbody > tr > td {
    background: rgba(10, 16, 29, 0.92);
    border-bottom-color: rgba(141, 176, 255, 0.08);
}

.inbound-hub .ant-table-tbody > tr:nth-child(2n) > td {
    background: rgba(13, 20, 36, 0.96);
}

.inbound-hub__client-title {
    font-size: 0.95rem;
}

.inbound-hub__client-sub {
    font-size: 0.8rem;
    line-height: 1.35;
}

.inbound-hub__subscriber-actions {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 8px;
}

.inbound-hub__action-strip,
.inbound-registry__actions {
    gap: 10px;
}

.inbound-hub__action-strip a,
.inbound-registry__actions a {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 10px;
    border-radius: 999px;
    border: 1px solid rgba(141, 176, 255, 0.1);
    background: rgba(255, 255, 255, 0.03);
    color: var(--noctra-text-soft);
    transition: 0.18s ease;
}

.inbound-hub__action-strip a:hover,
.inbound-registry__actions a:hover {
    color: var(--noctra-text);
    border-color: rgba(103, 221, 255, 0.2);
    background: rgba(103, 221, 255, 0.08);
}

.inbound-hub__connections-stack .ant-table,
.inbound-hub__connections-stack .ant-table-tbody > tr > td {
    background: rgba(9, 15, 28, 0.94);
}

@media (max-width: 1500px) {
    .inbound-hub__hero {
        grid-template-columns: 1fr;
    }

    .inbound-hub__metrics {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 1080px) {
    .inbounds-summary {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .inbound-hub__toolbar,
    .inbound-hub__table-head {
        align-items: start;
    }

    .inbound-hub__toolbar,
    .inbound-hub__table-head {
        flex-direction: column;
    }
}

@media (max-width: 760px) {
    .inbounds-summary,
    .inbound-hub__metrics {
        grid-template-columns: minmax(0, 1fr);
    }

    .inbound-hub__subscriber-actions {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* Inbound Hub cleanup pass */
.page-heading__text {
    max-width: 74ch;
    line-height: 1.55;
}

.inbounds-summary {
    gap: 12px;
    margin-bottom: 14px;
}

.metric-card {
    min-height: 116px;
    padding: 18px 20px;
    border-radius: 20px;
}

.metric-card__sub {
    margin-top: 6px;
    max-width: 24ch;
}

.inbound-registry .ant-table-container {
    border-radius: 22px;
    overflow: hidden;
}

.inbound-registry .ant-table-expanded-row > td,
.inbound-registry .ant-table-expanded-row:hover > td {
    padding: 14px 16px 18px !important;
    background: rgba(8, 14, 27, 0.92) !important;
}

.inbound-hub--embedded {
    gap: 12px;
    padding: 4px 0 0;
}

.inbound-hub__hero {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 14px;
    padding: 14px 16px;
    border-radius: 18px;
}

.inbound-hub__hero-main {
    min-width: 0;
}

.inbound-hub__title {
    margin-top: 2px;
    font-size: 1.55rem;
}

.inbound-hub__subtitle {
    max-width: 56ch;
    color: var(--noctra-text-soft);
}

.inbound-hub__meta {
    justify-content: flex-end;
    gap: 8px;
}

.inbound-hub__toolbar {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 14px 16px;
    border-radius: 18px;
    border: 1px solid rgba(141, 176, 255, 0.12);
    background: rgba(5, 11, 22, 0.82);
}

.inbound-hub__toolbar-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.inbound-hub__filters {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.inbound-hub__filters > .ant-input-affix-wrapper,
.inbound-hub__filters > .ant-input {
    flex: 1 1 320px;
    min-width: 260px;
}

.inbound-hub__filters > .ant-select {
    min-width: 154px;
}

.inbound-hub__filters-meta {
    color: var(--noctra-text-dim);
    font-size: 0.82rem;
    line-height: 1.4;
}

.inbound-hub__bulk-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.inbound-hub__metrics {
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 10px;
}

.inbound-hub__metric {
    min-height: 92px;
    padding: 12px 14px;
    border-radius: 16px;
}

.inbound-hub__metric-sub {
    max-width: 18ch;
}

.inbound-hub__table-head {
    align-items: center;
    padding-top: 0;
}

.inbound-hub__clients-table .ant-table-thead > tr > th {
    padding: 12px 12px;
    font-size: 0.68rem;
    letter-spacing: 0.14em;
}

.inbound-hub__clients-table .ant-table-tbody > tr > td {
    padding: 12px;
    vertical-align: top;
}

.inbound-hub__client-cell {
    gap: 4px;
}

.inbound-hub__client-title {
    font-weight: 600;
}

.inbound-hub__subscriber-actions {
    margin-top: 8px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    gap: 8px;
}

.inbound-hub__action-strip,
.inbound-registry__actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.inbound-hub__action-strip a,
.inbound-registry__actions a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 30px;
    padding: 0 10px;
    border-radius: 999px;
    border: 1px solid rgba(141, 176, 255, 0.12);
    background: rgba(255, 255, 255, 0.035);
    color: var(--noctra-text-soft);
    line-height: 1;
}

.inbound-hub__action-strip a:hover,
.inbound-registry__actions a:hover {
    color: var(--noctra-text);
    border-color: rgba(103, 221, 255, 0.24);
    background: rgba(103, 221, 255, 0.08);
}

.inbound-hub__action-link--danger {
    color: #ff9cac !important;
    border-color: rgba(255, 111, 134, 0.22) !important;
    background: rgba(255, 111, 134, 0.08) !important;
}

.inbound-hub__action-link--danger:hover {
    border-color: rgba(255, 111, 134, 0.34) !important;
    background: rgba(255, 111, 134, 0.14) !important;
}

.inbound-hub__empty--table {
    padding: 22px 24px;
    border-radius: 18px;
    border: 1px dashed rgba(141, 176, 255, 0.18);
    background: rgba(7, 13, 25, 0.78);
}

.inbound-hub__empty-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--noctra-text);
}

.inbound-hub__empty-sub {
    margin-top: 6px;
    max-width: 56ch;
    color: var(--noctra-text-dim);
    line-height: 1.5;
}

.ant-select-dropdown,
.ant-picker-dropdown .ant-picker-panel-container,
.ant-popover.ant-popconfirm .ant-popover-inner {
    background: linear-gradient(180deg, rgba(18, 27, 47, 0.98), rgba(10, 16, 30, 0.98)) !important;
    border: 1px solid rgba(141, 176, 255, 0.16) !important;
    box-shadow: 0 24px 80px rgba(2, 6, 16, 0.48) !important;
}

.ant-select-item,
.ant-select-item-option-content,
.ant-select-item-option-state,
.ant-select-item-empty,
.ant-picker-cell,
.ant-picker-header,
.ant-picker-content th,
.ant-picker-content td {
    color: var(--noctra-text-soft) !important;
}

.ant-select-item-option-active:not(.ant-select-item-option-disabled),
.ant-select-item-option-selected:not(.ant-select-item-option-disabled) {
    background: rgba(103, 221, 255, 0.1) !important;
    color: var(--noctra-text) !important;
}

.ant-select-item-option-selected:not(.ant-select-item-option-disabled) .ant-select-item-option-content {
    color: var(--noctra-text) !important;
}

.ant-select:not(.ant-select-disabled):not(.ant-select-customize-input) .ant-select-selector,
.ant-modal .ant-select:not(.ant-select-disabled):not(.ant-select-customize-input) .ant-select-selector,
.ant-modal .ant-picker,
.ant-modal .ant-input,
.ant-modal .ant-input-number,
.ant-modal textarea.ant-input {
    min-height: 42px;
    background: rgba(17, 25, 41, 0.96) !important;
    border-color: rgba(141, 176, 255, 0.16) !important;
    color: var(--noctra-text) !important;
    box-shadow: none !important;
}

.ant-modal .ant-select-selection-placeholder,
.ant-modal .ant-select-selection-item,
.ant-modal .ant-select-arrow,
.ant-modal .ant-picker-input > input,
.ant-modal .ant-picker-suffix,
.ant-modal .ant-picker-clear {
    color: var(--noctra-text) !important;
}

.ant-modal .ant-select-selection-placeholder {
    color: var(--noctra-text-dim) !important;
}

.ant-picker-panel,
.ant-picker-header,
.ant-picker-body,
.ant-picker-content,
.ant-picker-time-panel {
    background: transparent !important;
    border-color: rgba(141, 176, 255, 0.12) !important;
}

.ant-picker-cell-in-view.ant-picker-cell-selected .ant-picker-cell-inner,
.ant-picker-cell-in-view.ant-picker-cell-range-start .ant-picker-cell-inner,
.ant-picker-cell-in-view.ant-picker-cell-range-end .ant-picker-cell-inner {
    background: linear-gradient(135deg, rgba(70, 210, 255, 0.98), rgba(131, 120, 255, 0.92)) !important;
    color: #06101f !important;
}

.ant-picker-cell-in-view.ant-picker-cell-today .ant-picker-cell-inner::before {
    border-color: rgba(103, 221, 255, 0.5) !important;
}

.ant-popover.ant-popconfirm .ant-popover-inner-content {
    padding: 14px 16px !important;
}

.ant-popover.ant-popconfirm .ant-popover-message-title {
    color: var(--noctra-text) !important;
    line-height: 1.45;
}

.ant-popover.ant-popconfirm .ant-popover-message-icon {
    color: #f2b96f !important;
}

.ant-popover.ant-popconfirm .ant-popover-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 12px;
}

.ant-popover.ant-popconfirm .ant-popover-buttons .ant-btn {
    min-height: 38px;
}

.ant-modal .ant-modal-footer {
    border-top: 1px solid rgba(141, 176, 255, 0.12);
    padding: 16px 24px 20px;
}

.ant-descriptions-bordered .ant-descriptions-view table {
    background: transparent !important;
}

@media (max-width: 1500px) {
    .inbound-hub__metrics {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 1080px) {
    .inbound-hub__hero {
        grid-template-columns: minmax(0, 1fr);
    }

    .inbound-hub__toolbar-head {
        align-items: flex-start;
    }
}

@media (max-width: 760px) {
    .inbounds-summary,
    .inbound-hub__metrics {
        grid-template-columns: minmax(0, 1fr);
    }

    .inbound-hub__subscriber-actions {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* Inbound Hub stability + registry chrome */
.inbound-registry .ant-table-row-expand-icon {
    width: 22px !important;
    height: 22px !important;
    border-radius: 8px !important;
    border: 1px solid rgba(141, 176, 255, 0.18) !important;
    background: rgba(255, 255, 255, 0.04) !important;
    color: var(--noctra-text) !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: 0.18s ease;
}

.inbound-registry .ant-table-row-expand-icon:hover {
    border-color: rgba(103, 221, 255, 0.28) !important;
    background: rgba(103, 221, 255, 0.08) !important;
}

.inbound-registry .ant-table-row-expand-icon::before {
    color: inherit !important;
}

.inbound-registry .ant-pagination {
    display: none !important;
}

.inbound-registry .ant-table-expanded-row-fixed {
    width: 100% !important;
}

/* Inbound Hub polish pass */
.inbound-inline-actions {
    margin-top: 10px;
    display: flex;
    min-width: 0;
}

.inbound-inline-actions .ant-space {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
    width: 100%;
}

.inbound-inline-actions .ant-space-item {
    margin-right: 0 !important;
}

.inbound-inline-actions .ant-btn {
    white-space: nowrap;
}

.inbound-section-card .ant-input,
.inbound-section-card .ant-input-affix-wrapper,
.inbound-section-card .ant-input-number,
.inbound-section-card .ant-select:not(.ant-select-customize-input) .ant-select-selector,
.inbound-section-card textarea.ant-input {
    max-width: 100%;
    min-width: 0;
    overflow: hidden;
}

.inbound-section-card .ant-form-item-control-input,
.inbound-section-card .ant-form-item-control-input-content {
    min-width: 0;
}

.inbound-hub__toolbar .ant-btn {
    min-height: 40px;
    padding-inline: 18px;
}

.inbound-hub__toolbar .ant-btn-primary {
    box-shadow: 0 12px 30px rgba(87, 157, 255, 0.18);
}

.inbound-registry .ant-table-row-expand-icon {
    position: relative;
    color: transparent !important;
    font-size: 0 !important;
}

.inbound-registry .ant-table-row-expand-icon::before {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    font-weight: 700;
    line-height: 1;
    color: var(--noctra-text);
}

.inbound-registry .ant-table-row-expand-icon-collapsed::before {
    content: "+";
}

.inbound-registry .ant-table-row-expand-icon-expanded::before {
    content: "−";
}

.inbound-registry .ant-table-row-expand-icon-spaced {
    border-color: transparent !important;
    background: transparent !important;
    box-shadow: none !important;
}

.inbound-registry .ant-table-row-expand-icon-spaced::before {
    content: "";
}

.inbound-registry .ant-pagination,
.inbound-hub__clients-table .ant-pagination {
    display: none !important;
}

/* ── Design refresh: inbounds page (readability pass) ─────── */

/* Expanded row: less padding so hub doesn't balloon */
.inbound-registry .ant-table-expanded-row > td,
.inbound-registry .ant-table-expanded-row:hover > td {
    padding: 6px 10px 10px !important;
}

/* Hub embedded: tighter between sections */
.inbound-hub--embedded {
    gap: 8px;
    padding: 2px 0 0;
}

/* Hero: flatten — remove heavy gradient, smaller text, less padding */
.inbound-hub__hero {
    padding: 10px 14px;
    border-radius: 14px;
    border-color: rgba(103, 221, 255, 0.09);
    background: rgba(11, 17, 32, 0.88);
    gap: 12px;
}

.inbound-hub__eyebrow {
    margin-bottom: 2px;
    font-size: 0.62rem;
    letter-spacing: 0.1em;
    opacity: 0.7;
}

.inbound-hub__title {
    font-size: 1rem;
    margin-top: 1px;
}

.inbound-hub__subtitle {
    margin-top: 2px;
    font-size: 0.82rem;
    color: var(--noctra-text-dim);
}

.inbound-hub__meta {
    gap: 5px;
    justify-content: flex-end;
    align-items: flex-start;
}

/* Smaller tags in hub hero — less visual weight */
.inbound-hub__meta .ant-tag {
    font-size: 0.7rem;
    padding: 1px 7px;
    line-height: 1.8;
    border-radius: 6px;
}

/* Toolbar: compact — less padding, smaller elements */
.inbound-hub__toolbar {
    padding: 10px 12px;
    gap: 8px;
    border-radius: 14px;
    background: rgba(5, 9, 20, 0.65);
    border-color: rgba(141, 176, 255, 0.09);
}

.inbound-hub__toolbar-head {
    gap: 8px;
}

.inbound-hub__filters {
    gap: 6px;
}

.inbound-hub__bulk-actions {
    gap: 6px;
}

.inbound-hub__toolbar .ant-btn {
    min-height: 32px;
    padding-inline: 12px;
    font-size: 0.84rem;
}

.inbound-hub__toolbar .ant-btn-primary {
    box-shadow: none;
}

/* Form controls inside toolbar: compact height */
.inbound-hub .ant-input,
.inbound-hub .ant-input-affix-wrapper,
.inbound-hub .ant-input-number,
.inbound-hub .ant-select:not(.ant-select-customize-input) .ant-select-selector {
    min-height: 32px;
}

/* ── Metrics: flat stat bar instead of 6 separate cards ───── */
.inbound-hub__metrics {
    display: flex;
    grid-template-columns: unset;
    gap: 0;
    background: rgba(6, 11, 22, 0.7);
    border: 1px solid rgba(141, 176, 255, 0.09);
    border-radius: 14px;
    overflow: hidden;
}

.inbound-hub__metric {
    flex: 1;
    min-height: unset;
    padding: 8px 12px;
    border-radius: 0;
    background: transparent;
    border: none;
    border-right: 1px solid rgba(141, 176, 255, 0.08);
}

.inbound-hub__metric:last-child {
    border-right: none;
}

.inbound-hub__metric-label {
    font-size: 0.62rem;
    letter-spacing: 0.1em;
}

.inbound-hub__metric-value {
    margin-top: 4px;
    font-size: 0.95rem;
    font-weight: 700;
}

.inbound-hub__metric-sub {
    margin-top: 2px;
    font-size: 0.7rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    line-height: 1.3;
}

/* Table head: no extra top space */
.inbound-hub__table-head {
    padding-top: 0;
}

.inbound-hub__section-title {
    font-size: 0.86rem;
    font-weight: 600;
}

.inbound-hub__table-hint,
.inbound-hub__section-sub {
    font-size: 0.76rem;
}

/* Clients table: tighter rows */
.inbound-hub__clients-table .ant-table-thead > tr > th {
    padding: 8px 10px;
}

.inbound-hub__clients-table .ant-table-tbody > tr > td {
    padding: 10px;
}

/* Metrics responsive: wrap to 3 columns, then 2, then 1 */
@media (max-width: 1500px) {
    .inbound-hub__metrics {
        flex-wrap: wrap;
    }

    .inbound-hub__metric {
        flex: 1 1 33.33%;
    }

    .inbound-hub__metric:nth-child(-n+3) {
        border-bottom: 1px solid rgba(141, 176, 255, 0.08);
    }

    .inbound-hub__metric:nth-child(3),
    .inbound-hub__metric:nth-child(6) {
        border-right: none;
    }
}

@media (max-width: 760px) {
    .inbound-hub__metrics {
        flex-direction: column;
    }

    .inbound-hub__metric {
        border-right: none;
        border-bottom: 1px solid rgba(141, 176, 255, 0.08);
        flex: 1 1 auto;
    }

    .inbound-hub__metric:last-child {
        border-bottom: none;
    }
}

/* Inbounds 3x-ui direction */
.inbounds-ops {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.page-heading--compact {
    margin: 0;
    padding: 0;
    background: transparent;
    border: none;
    box-shadow: none;
}

.page-heading--compact .page-heading__title {
    margin: 0 0 8px;
    font-size: 2.15rem;
    line-height: 1.08;
}

.page-heading--compact .page-heading__text {
    max-width: 880px;
    margin: 0;
    font-size: 0.95rem;
    color: var(--noctra-text-dim);
}

.inbounds-ops__header {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.inbounds-strip {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0;
    overflow: hidden;
    border-radius: 24px;
    border: 1px solid rgba(95, 114, 160, 0.18);
    background: rgba(7, 10, 18, 0.88);
    box-shadow: 0 24px 60px rgba(1, 4, 10, 0.28);
}

.inbounds-strip__item {
    display: flex;
    gap: 12px;
    min-height: 92px;
    padding: 16px 18px;
    border-right: 1px solid rgba(95, 114, 160, 0.14);
}

.inbounds-strip__item:last-child {
    border-right: none;
}

.inbounds-strip__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    flex: 0 0 36px;
    border-radius: 12px;
    border: 1px solid rgba(103, 221, 255, 0.18);
    background: rgba(18, 28, 50, 0.82);
    color: #7fd7ff;
    font-size: 1rem;
}

.inbounds-strip__body {
    display: flex;
    flex-direction: column;
    gap: 5px;
    min-width: 0;
}

.inbounds-strip__label,
.inbounds-strip__sub {
    font-size: 0.78rem;
    color: var(--noctra-text-dim);
}

.inbounds-strip__value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--noctra-text);
}

.inbound-registry-card > .ant-card {
    border-radius: 26px;
    border: 1px solid rgba(95, 114, 160, 0.18);
    background: rgba(18, 25, 43, 0.84);
    box-shadow: 0 24px 60px rgba(1, 4, 10, 0.24);
}

.inbound-registry-card > .ant-card > .ant-card-body {
    padding: 18px 18px 16px;
}

.inbound-registry__topbar {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    padding: 4px 4px 16px;
}

.inbound-registry__title-block {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.inbound-registry__eyebrow {
    font-size: 0.68rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(151, 182, 241, 0.72);
}

.inbound-registry__title {
    font-size: 1.55rem;
    font-weight: 700;
    color: var(--noctra-text);
}

.inbound-registry__sub {
    font-size: 0.85rem;
    color: var(--noctra-text-dim);
}

.inbound-registry__top-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.inbound-registry__top-actions .ant-btn {
    min-height: 42px;
    padding-inline: 18px;
    border-radius: 14px;
}

.inbound-registry__top-actions .ant-btn-primary {
    box-shadow: 0 12px 30px rgba(87, 157, 255, 0.18);
}

.inbound-registry__filters {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 16px;
    padding: 14px 0 18px;
    border-top: 1px solid rgba(95, 114, 160, 0.16);
    border-bottom: 1px solid rgba(95, 114, 160, 0.12);
}

.inbound-registry__search {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1 1 360px;
    max-width: 520px;
    min-height: 44px;
    padding: 0 14px;
    border-radius: 999px;
    border: 1px solid rgba(95, 114, 160, 0.18);
    background: rgba(8, 12, 21, 0.86);
    color: var(--noctra-text-dim);
}

.inbound-registry__search .ant-input,
.inbound-registry__search .ant-input-affix-wrapper {
    border: none !important;
    background: transparent !important;
    box-shadow: none !important;
    padding: 0 !important;
}

.inbound-registry__search .ant-input {
    color: var(--noctra-text) !important;
}

.inbound-registry__chips {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.inbound-filter-chip {
    min-height: 40px;
    padding: 0 16px;
    border-radius: 999px;
    border: 1px solid rgba(95, 114, 160, 0.18);
    background: rgba(12, 18, 32, 0.82);
    color: var(--noctra-text-dim);
    font-size: 0.83rem;
    font-weight: 600;
    transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
}

.inbound-filter-chip:hover {
    color: var(--noctra-text);
    border-color: rgba(120, 155, 230, 0.4);
    transform: translateY(-1px);
}

.inbound-filter-chip.is-active {
    color: #f5fbff;
    border-color: transparent;
    background: linear-gradient(135deg, #0ca88a, #088f78);
    box-shadow: 0 10px 26px rgba(12, 168, 138, 0.24);
}

.inbound-registry .ant-table,
.inbound-hub__clients-table .ant-table {
    background: transparent;
}

.inbound-registry .ant-table-container,
.inbound-hub__clients-table .ant-table-container {
    overflow: hidden;
    border-radius: 22px;
    border: 1px solid rgba(95, 114, 160, 0.16);
    background: rgba(9, 13, 23, 0.82);
}

.inbound-registry .ant-table-thead > tr > th,
.inbound-hub__clients-table .ant-table-thead > tr > th {
    padding: 14px 14px;
    border-bottom-color: rgba(95, 114, 160, 0.12) !important;
    background: rgba(34, 41, 60, 0.92) !important;
    color: rgba(162, 186, 235, 0.74) !important;
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.inbound-registry .ant-table-tbody > tr > td,
.inbound-hub__clients-table .ant-table-tbody > tr > td {
    padding: 13px 14px;
    border-bottom-color: rgba(95, 114, 160, 0.1) !important;
    vertical-align: middle;
}

.inbound-registry .ant-table-tbody > tr:hover > td,
.inbound-hub__clients-table .ant-table-tbody > tr:hover > td {
    background: rgba(17, 24, 40, 0.78) !important;
}

.registry-row-actions,
.client-row-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.registry-row-action,
.client-row-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    padding: 0;
    border-radius: 11px;
    border: 1px solid rgba(95, 114, 160, 0.18);
    background: rgba(15, 21, 36, 0.94);
    color: var(--noctra-text);
    transition: transform 0.16s ease, border-color 0.16s ease, background 0.16s ease, color 0.16s ease;
}

.registry-row-action:hover,
.client-row-action:hover {
    transform: translateY(-1px);
    color: #ffffff;
    border-color: rgba(120, 155, 230, 0.42);
    background: rgba(31, 40, 63, 0.96);
}

.registry-row-action--danger,
.client-row-action--danger {
    color: #ff8c9d;
    border-color: rgba(235, 92, 123, 0.28);
    background: rgba(70, 20, 33, 0.28);
}

.registry-row-action--danger:hover,
.client-row-action--danger:hover {
    color: #ffd5db;
    border-color: rgba(255, 108, 140, 0.45);
    background: rgba(98, 24, 43, 0.52);
}

.registry-row-action .anticon,
.client-row-action .anticon {
    font-size: 15px;
}

.inbound-registry .ant-table-row-expand-icon {
    width: 22px;
    height: 22px;
    border-radius: 999px;
    border-color: rgba(95, 114, 160, 0.24) !important;
    background: rgba(12, 18, 32, 0.92) !important;
}

.inbound-registry .ant-table-expanded-row > td,
.inbound-registry .ant-table-expanded-row:hover > td {
    padding: 8px 10px 12px !important;
    background: rgba(10, 15, 27, 0.72) !important;
}

.inbound-hub--embedded {
    gap: 10px;
    padding-top: 4px;
}

.inbound-hub__hero {
    padding: 12px 14px;
    border-radius: 20px;
    border: 1px solid rgba(95, 114, 160, 0.14);
    background: rgba(11, 16, 30, 0.84);
}

.inbound-hub__hero-main {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.inbound-hub__title-row {
    display: flex;
    align-items: baseline;
    gap: 10px;
    flex-wrap: wrap;
}

.inbound-hub__title {
    font-size: 1.05rem;
    font-weight: 700;
    color: #f5f8ff;
}

.inbound-hub__subtitle {
    margin-top: 0;
    font-size: 0.84rem;
    color: var(--noctra-text-dim);
}

.inbound-hub__meta {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.inbound-hub__meta .ant-tag {
    border-radius: 999px;
    padding: 2px 10px;
    font-size: 0.72rem;
}

.inbound-hub__toolbar {
    padding: 12px 14px;
    border-radius: 20px;
    border: 1px solid rgba(95, 114, 160, 0.14);
    background: rgba(5, 9, 19, 0.74);
    gap: 10px;
}

.inbound-hub__toolbar-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.inbound-hub__toolbar-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.inbound-hub__toolbar .ant-btn {
    min-height: 38px;
    padding-inline: 14px;
    border-radius: 12px;
}

.inbound-hub__filters {
    display: grid;
    grid-template-columns: minmax(240px, 1.35fr) repeat(3, minmax(148px, auto)) auto;
    gap: 8px;
    align-items: center;
}

.inbound-hub__bulk-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.inbound-hub__filters-meta {
    font-size: 0.78rem;
    color: var(--noctra-text-dim);
}

.inbound-hub__client-title {
    font-size: 0.92rem;
}

.inbound-hub__client-sub {
    margin-top: 3px;
    font-size: 0.78rem;
}

.inbound-hub__client-runtime {
    margin-top: 6px;
    font-size: 0.73rem;
    color: var(--noctra-text-dim);
}

.inbound-hub__traffic-cell {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.inbound-hub__traffic-main {
    font-size: 0.92rem;
    font-weight: 700;
    color: var(--noctra-text);
}

.inbound-hub__traffic-sub {
    font-size: 0.74rem;
    color: var(--noctra-text-dim);
}

.inbound-hub__subscriber-actions {
    margin-top: 8px;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.inbound-hub__subscriber-actions .ant-btn {
    min-height: 34px;
    padding-inline: 12px;
    border-radius: 10px;
}

.inbound-hub__empty--table {
    padding: 24px 28px;
    border: 1px dashed rgba(95, 114, 160, 0.2);
    border-radius: 20px;
    background: rgba(7, 11, 20, 0.54);
}

@media (max-width: 1580px) {
    .inbounds-strip {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .inbound-hub__filters {
        grid-template-columns: minmax(240px, 1fr) repeat(2, minmax(148px, 1fr));
    }
}

@media (max-width: 1120px) {
    .inbound-registry__topbar,
    .inbound-hub__toolbar-head {
        flex-direction: column;
        align-items: stretch;
    }

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

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

@media (max-width: 720px) {
    .page-heading--compact .page-heading__title {
        font-size: 1.7rem;
    }

    .inbounds-strip {
        grid-template-columns: 1fr;
    }

    .inbound-registry__search {
        max-width: none;
    }

    .inbound-hub__filters {
        grid-template-columns: 1fr;
    }
}
