* {
    box-sizing: border-box;
}

body {
    margin: 0 0 -1px;
    min-height: 100vh;
    font-family: Arial, sans-serif;
    background: #0f172a;
    color: #e5e7eb;
}

main {
    width: min(1500px, calc(100vw - 32px));
    margin: 24px auto;
}

.hidden {
    display: none !important;
}

.login-card {
    width: min(420px, calc(100vw - 32px));
    margin: 80px auto;
    background: #111827;
    border: 1px solid #374151;
    border-radius: 14px;
    padding: 24px;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.25);
}

h1 {
    margin: 0 0 8px;
    font-size: 28px;
}

.subtitle {
    margin: 0 0 24px;
    color: #9ca3af;
}

label {
    display: block;
    margin-bottom: 14px;
    color: #cbd5e1;
}

input {
    display: block;
    width: 100%;
    margin-top: 6px;
    padding: 12px;
    border: 1px solid #4b5563;
    border-radius: 8px;
    background: #020617;
    color: #e5e7eb;
    font-size: 15px;
}

button {
    padding: 11px 16px;
    border: 0;
    border-radius: 8px;
    background: #2563eb;
    color: #ffffff;
    font-weight: 700;
    cursor: pointer;
}

button:hover {
    background: #1d4ed8;
}

button.secondary {
    background: #374151;
}

button.secondary:hover {
    background: #4b5563;
}

button.danger {
    background: #b91c1c;
}

button.danger:hover {
    background: #991b1b;
}

.error {
    color: #f87171;
    min-height: 20px;
}

.app-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}

.app-header p {
    margin: 0;
    color: #9ca3af;
}

.tabs {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 16px;
    border-bottom: 1px solid #334155;
}

.tabs-left {
    display: flex;
    gap: 8px;
    align-items: flex-end;
}

.runtime-tab {
    width: fit-content;
    max-width: min(760px, 48vw);
    min-height: 49px;
    padding: 7px 12px;
    display: grid;
    grid-template-columns: max-content minmax(180px, max-content) max-content max-content;
    gap: 14px;
    align-items: center;
    border-radius: 8px 8px 0 0;
    border-bottom: 0;
    font-size: 12px;
    overflow: hidden;
}

.runtime-tab div {
    min-width: 0;
}

.runtime-tab div:nth-child(2) {
    max-width: 280px;
}

.runtime-tab span {
    display: block;
    margin-bottom: 2px;
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    opacity: 0.75;
}

.runtime-tab strong {
    display: block;
    min-width: 0;
    font-size: 13px;
    font-weight: 800;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.runtime-prod {
    background: #14532d;
    border: 2px solid #22c55e;
    color: #dcfce7;
}

.runtime-dev {
    background: #ef7147;
    border: 2px solid #b73104;
    color: #1b1916;
}

.runtime-loading {
    visibility: hidden;
}

.tab {
    border-radius: 8px 8px 0 0;
    background: #1f2937;
    color: #cbd5e1;
}

.tab:hover {
    background: #374151;
}

.tab.active {
    background: #2563eb;
    color: #ffffff;
}

.tab.tab-console-running {
    background: #14532d;
    color: #dcfce7;
}

.tab.tab-console-running:hover {
    background: #166534;
}

.tab.tab-console-running.active {
    background: #22c55e;
    color: #052e16;
}

.tab.tab-console-stopped {
    background: #7f1d1d;
    color: #fee2e2;
}

.tab.tab-console-stopped:hover {
    background: #991b1b;
}

.tab.tab-console-stopped.active {
    background: #ef4444;
    color: #ffffff;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 10px;
    margin-bottom: 16px;
}

.stat-box {
    min-height: 86px;
    padding: 14px;
    background: #111827;
    border: 1px solid #334155;
    border-radius: 12px;
}

.stat-box span {
    display: block;
    min-height: 34px;
    color: #9ca3af;
    font-size: 13px;
}

.stat-box strong {
    display: block;
    margin-top: 8px;
    font-size: 22px;
    color: #ffffff;
}

.console-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 180px;
    gap: 16px;
    height: calc((100vh - 290px) * 0.95);
    min-height: 470px;
}

.console-panel {
    min-height: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
    background: #111827;
    border: 1px solid #334155;
    border-radius: 12px;
    overflow: hidden;
}

#consoleOutput {
    flex: 1;
    min-height: 0;
    width: 100%;
    height: 100%;
    padding: 0;
    background: #020617;
    overflow: hidden;
    position: relative;
}

#consoleOutput .xterm {
    width: 100%;
    height: 100%;
    padding: 8px;
    overflow: hidden;
    box-sizing: border-box;
}

#consoleOutput .xterm-screen,
#consoleOutput .xterm-rows {
    pointer-events: none;
    user-select: none;
}

#consoleOutput .xterm-viewport {
    pointer-events: auto;
    overflow-y: auto !important;
    scrollbar-width: none;
    scrollbar-color: transparent transparent;
}

#consoleOutput.console-scrollbar-visible .xterm-viewport,
#consoleOutput:hover .xterm-viewport {
    scrollbar-width: thin;
    scrollbar-color: #475569 transparent;
}

#consoleOutput .xterm-viewport::-webkit-scrollbar {
    width: 0;
}

#consoleOutput.console-scrollbar-visible .xterm-viewport::-webkit-scrollbar,
#consoleOutput:hover .xterm-viewport::-webkit-scrollbar {
    width: 8px;
}

#consoleOutput .xterm-viewport::-webkit-scrollbar-thumb {
    background: #475569;
    border-radius: 999px;
}

#consoleOutput .xterm-viewport::-webkit-scrollbar-track {
    background: transparent;
}

#commandForm {
    flex-shrink: 0;
    display: flex;
    gap: 8px;
    padding: 12px;
    background: #111827;
    border-top: 1px solid #334155;
}

#commandInput {
    margin: 0;
}

.console-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.console-actions-separator {
    height: 10px;
}

.console-actions button {
    width: 100%;
}

.console-actions .connection-address-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    margin-top: 12px;
    min-height: 58px;
    padding: 9px 8px;
    border: 2px dashed #ef7147;
    border-radius: 10px;
    background: #111827;
    color: #fb923c;
    cursor: pointer;
}

.console-actions .connection-address-card:hover {
    border-color: #fb923c;
    background: #1f2937;
    color: #fdba74;
}

.console-actions .connection-address-card:disabled,
.console-actions .connection-address-card:disabled:hover {
    border-color: #b73104;
    background: #111827;
    color: #ef7147;
    cursor: default;
    opacity: 0.72;
}

.connection-address-card span {
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.connection-address-card strong {
    max-width: 100%;
    font-size: 12px;
    overflow-wrap: anywhere;
    text-align: center;
}

.debug-panel {
    display: flex;
    flex-direction: column;
    gap: 16px;
    height: calc((100vh - 230px) * 0.95);
    min-height: 470px;
}

.debug-observer-tabs {
    display: flex;
    flex-wrap: nowrap;
    gap: 4px;
    margin: 0 0 -1px;
    overflow-x: auto;
    position: relative;
    z-index: 2;
}

.debug-observer-tab {
    width: auto;
    margin: 0;
    padding: 10px 16px;
    border: 1px solid #475569;
    border-radius: 9px 9px 0 0;
    background: #172033;
    color: #cbd5e1;
}

.debug-observer-tab.active {
    border-color: #64748b;
    border-bottom-color: #111827;
    background: #111827;
    color: #ffffff;
}

.debug-observer-content {
    padding: 16px;
    border: 1px solid #64748b;
    border-radius: 0 10px 10px 10px;
    background: #111827;
}

.debug-observer-content[data-debug-observer="packet"] {
    height: calc((100vh - 210px) * 0.95);
    min-height: 500px;
}

.debug-observer-content[data-debug-observer="packet"] .debug-panel {
    height: 100%;
    min-height: 0;
}

.debug-observer-placeholder {
    min-height: 220px;
    padding: 24px;
}

.debug-observer-placeholder h2 {
    margin-top: 0;
}

.cpu-observer-dashboard { display: grid; gap: 14px; max-width: 1500px; margin: 0 auto; }
.cpu-observer-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 18px 20px; border: 1px solid #334155; border-radius: 12px; background: linear-gradient(105deg, #0f1b30, #111827 62%); }
.cpu-observer-header h2, .cpu-observer-header p, .cpu-data-card h3, .cpu-graph-card h3 { margin: 0; }
.cpu-observer-header h2 { margin-top: 3px; font-size: 23px; }
.cpu-observer-header p:not(.cpu-observer-eyebrow) { margin-top: 6px; color: #94a3b8; font-size: 14px; }
.cpu-graph-legend { align-items: center; display: flex; gap: 5px; margin-top: 7px; color: #cbd5e1; font-size: 11px; }
.cpu-graph-legend i { display: inline-block; width: 10px; height: 3px; border-radius: 2px; }
.cpu-graph-legend i.service { background: #60a5fa; }
.cpu-graph-legend i.system { background: #94a3b8; margin-left: 7px; }
.cpu-observer-eyebrow { color: #60a5fa; font-size: 12px; font-weight: 700; letter-spacing: .11em; text-transform: uppercase; }
.cpu-observer-state, .cpu-quality { flex: 0 0 auto; border: 1px solid #475569; border-radius: 999px; padding: 6px 9px; color: #cbd5e1; background: #172033; font-size: 11px; font-weight: 700; letter-spacing: .06em; }
.cpu-observer-state.live { border-color: #166534; color: #bbf7d0; background: #14532d; }
.cpu-incident-controls { display: grid; grid-template-columns: max-content max-content max-content max-content; column-gap: 12px; height: 52px; margin-bottom: 14px; color: #cbd5e1; font-size: 12px; }
.cpu-incident-field, .cpu-incident-apply { align-self: start; display: grid; grid-template-rows: 13px 34px; gap: 5px; height: 52px; }
.cpu-incident-field label { color: #94a3b8; font-size: 11px; font-weight: 700; letter-spacing: .06em; line-height: 13px; text-transform: uppercase; white-space: nowrap; }
.cpu-incident-field span { align-items: center; display: flex; gap: 6px; height: 34px; white-space: nowrap; }
.cpu-incident-controls input[type="number"], .cpu-incident-controls select, .cpu-incident-controls button { box-sizing: border-box; height: 34px; }
.cpu-incident-controls input[type="number"] { width: 72px; }
#cpuIncidentThreshold { position: relative; top: -1px; }
.cpu-incident-apply button { align-items: center; display: flex; padding: 0 16px; }
.cpu-observer-state.unavailable, .cpu-quality { color: #cbd5e1; }
.cpu-metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.cpu-metric-card, .cpu-graph-card, .cpu-data-card { min-width: 0; border: 1px solid #334155; border-radius: 10px; background: #0b1220; }
.cpu-metric-card { height: 144px; overflow: hidden; padding: 14px 15px; }
.cpu-metric-card h3 { margin: 0; color: #94a3b8; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.cpu-metric-card strong { display: block; margin: 8px 0 3px; color: #e2e8f0; font-size: 24px; line-height: 1; }
.cpu-metric-card strong .cpu-service-current, .cpu-metric-card strong .cpu-service-capacity { color: #e2e8f0; display: inline-block; font-size: 24px; font-feature-settings: "tnum"; font-variant-numeric: tabular-nums; letter-spacing: -.04em; text-align: right; width: 7ch; }
.cpu-metric-card strong em { color: #94a3b8; font-style: normal; }
.cpu-service-summary, .cpu-service-overhead { display: block; font-feature-settings: "tnum"; font-variant-numeric: tabular-nums; white-space: pre; }
.cpu-service-overhead { margin-top: 5px; }
.cpu-service-overhead b { color: #cbd5e1; font-weight: 600; }
.cpu-metric-card span, .cpu-section-heading p, .cpu-card-empty { color: #94a3b8; font-size: 12px; }
.cpu-graph-card { position: relative; padding: 15px 16px 12px; overflow: hidden; }
.cpu-section-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
.cpu-section-heading h3, .cpu-data-card > h3 { font-size: 15px; }
.cpu-section-heading p { margin: 4px 0 0; }
.cpu-graph { display: block; width: 100%; height: 150px; border-radius: 6px; background: #020617; }
.cpu-graph-tooltip { position: absolute; z-index: 4; min-width: 142px; padding: 7px 9px; border: 1px solid #475569; border-radius: 6px; background: rgba(11,18,32,.97); color: #e2e8f0; font-size: 11px; line-height: 1.45; font-variant-numeric: tabular-nums; pointer-events: none; white-space: pre; }
.cpu-graph-tooltip-line { white-space: pre; }
.cpu-graph-tooltip-dot { display: inline-block; width: 7px; height: 7px; margin: 0 6px 0 1px; border-radius: 50%; vertical-align: 1px; }
.cpu-empty-graph { position: absolute; top: 95px; right: 26px; margin: 0; color: #94a3b8; font-size: 12px; }
.cpu-data-card { padding: 15px 16px; }
#cpuHotThreadsCard { height: 470px; display: flex; flex-direction: column; }
#cpuHotThreadsCard .cpu-table-scroll { flex: 1; min-height: 0; overflow-y: auto; }
#cpuHotThreadsCard th { position: sticky; top: 0; z-index: 1; background: #0b1220; }
#cpuHotCodeCard.cpu-hot-code-live { height: 470px; display: flex; flex-direction: column; }
#cpuHotCodeCard.cpu-hot-code-live .cpu-table-scroll { flex: 1; min-height: 0; overflow-y: auto; }
#cpuHotCodeCard.cpu-hot-code-live th { position: sticky; top: 0; z-index: 1; background: #0b1220; }
.cpu-jfr-card { height: 500px; display: grid; grid-template-rows: auto auto 28px 38px minmax(0, 1fr); gap: 10px; overflow: hidden; }
.cpu-jfr-controls { display: flex; align-items: start; gap: 12px; min-height: 58px; }
.cpu-jfr-controls label { display: grid; gap: 5px; color: #94a3b8; font-size: 11px; font-weight: 700; letter-spacing: .06em; line-height: 13px; text-transform: uppercase; }
.cpu-jfr-controls select { min-width: 150px; height: 34px; box-sizing: border-box; }
.cpu-jfr-actions { display: grid; grid-template-columns: max-content max-content; grid-template-rows: 13px 34px; gap: 5px 8px; }
.cpu-jfr-actions::before { content: ""; grid-column: 1 / -1; }
.cpu-jfr-actions button { align-items: center; box-sizing: border-box; display: flex; height: 34px; padding: 0 16px; }
.cpu-jfr-help { margin: 0; color: #94a3b8; font-size: 12px; }
.cpu-jfr-progress { display: grid; grid-template-columns: minmax(120px, 330px) 1fr; align-items: center; gap: 10px; color: #cbd5e1; font-size: 12px; font-variant-numeric: tabular-nums; }
#cpuJfrProgressBar { height: 8px; overflow: hidden; border-radius: 99px; background: #1e293b; }
#cpuJfrProgressBar i { display: block; width: 0; height: 100%; background: #60a5fa; transition: width .2s ease; }
.cpu-jfr-profiles { display: flex; min-height: 0; flex-direction: column; border-top: 1px solid #334155; padding-top: 10px; }
.cpu-jfr-profiles-heading { display: flex; align-items: center; justify-content: space-between; min-height: 24px; }
.cpu-jfr-profiles-heading h4 { margin: 0; color: #94a3b8; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; }
.cpu-jfr-profiles-heading span { color: #94a3b8; font-size: 12px; }
#cpuJfrProfileScroll { flex: 1; min-height: 0; overflow-y: auto; }
#cpuJfrProfileScroll th { position: sticky; top: 0; z-index: 1; background: #0b1220; }
#cpuJfrProfileScroll table { min-width: 720px; }
.cpu-jfr-download { padding: 5px 8px; font-size: 12px; }
.cpu-diagnostic-card { height: 560px; display: grid; grid-template-rows: auto 46px 20px minmax(0, 1fr) minmax(0, 1fr); gap: 10px; overflow: hidden; }
.cpu-diagnostic-controls { display: flex; align-items: start; gap: 10px; min-height: 58px; }
.cpu-diagnostic-controls label { display: grid; gap: 5px; color: #94a3b8; font-size: 11px; font-weight: 700; letter-spacing: .06em; line-height: 13px; text-transform: uppercase; }
.cpu-diagnostic-controls select { height: 34px; box-sizing: border-box; }
.cpu-diagnostic-actions { display: grid; grid-template-columns: max-content max-content; grid-template-rows: 13px 34px; gap: 5px 8px; }
.cpu-diagnostic-actions::before { content: ""; grid-column: 1 / -1; }
.cpu-diagnostic-actions button { align-items: center; box-sizing: border-box; display: flex; height: 34px; padding: 0 16px; }
.cpu-diagnostic-details { min-height: 0; display: flex; flex-direction: column; gap: 8px; border-top: 1px solid #334155; padding-top: 8px; }
.cpu-diagnostic-details .cpu-table-scroll { min-height: 0; }
.cpu-diagnostic-details .cpu-jfr-profiles-heading > span { display: flex; align-items: center; gap: 8px; }
.cpu-diagnostic-details .cpu-jfr-profiles-heading button { align-items: center; box-sizing: border-box; display: flex; height: 34px; padding: 0 16px; }
.cpu-data-card > h3 { margin: 0 0 8px; }
.cpu-card-empty { margin: 12px 0 0; }
.cpu-table-scroll { overflow-x: auto; }
.cpu-data-card table { width: 100%; min-width: 650px; border-collapse: collapse; text-align: left; }
.cpu-data-card th { padding: 8px 10px; color: #94a3b8; border-bottom: 1px solid #334155; font-size: 11px; letter-spacing: .06em; text-transform: uppercase; }
.cpu-data-card td { padding: 12px 10px; color: #cbd5e1; font-size: 13px; }
.cpu-data-card td[colspan] { color: #94a3b8; text-align: center; }
.cpu-lower-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.cpu-core-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 8px 14px; }
.cpu-core-row { display: grid; grid-template-columns: 48px minmax(40px, 1fr) 42px; align-items: center; gap: 8px; color: #cbd5e1; font-size: 12px; }
.cpu-core-row strong { text-align: right; font-variant-numeric: tabular-nums; }
.cpu-core-meter { height: 7px; overflow: hidden; border-radius: 999px; background: #1e293b; }
.cpu-core-meter i { display: block; height: 100%; border-radius: inherit; background: #60a5fa; }
.cpu-thread-warning td:nth-child(4) { color: #fbbf24; font-weight: 700; }
.cpu-thread-concern td:nth-child(4) { color: #fb923c; font-weight: 700; }
.cpu-thread-critical td:nth-child(4) { color: #f87171; font-weight: 700; }
.cpu-tick-warning td:last-child { color: #fbbf24; font-weight: 700; }
.cpu-tick-critical td:last-child { color: #f87171; font-weight: 700; }

@media (max-width: 900px) { .cpu-metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .cpu-lower-grid { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .cpu-observer-header { flex-direction: column; } .cpu-metric-grid { grid-template-columns: 1fr; } .cpu-empty-graph { position: static; margin-top: 8px; } }

.ram-history-card { height: 280px; }
.ram-history-card .cpu-graph { height: 224px; }
.ram-legend i.rss { background: #60a5fa; }
.ram-legend i.heap { background: #a78bfa; }
.ram-legend i.after-gc { background: #34d399; }
.ram-legend i.container { background: #f59e0b; }
.ram-legend i { margin-left: 7px; }
.ram-legend i:first-child { margin-left: 0; }
.ram-table-card { min-height: 205px; }
.ram-table-card .cpu-table-scroll { max-height: 300px; overflow-y: auto; }
.ram-table-card th { position: sticky; top: 0; z-index: 1; background: #0b1220; }
.ram-incident-controls { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) max-content; align-items: end; gap: 10px; margin: 12px 0 16px; }
.ram-incident-row { display: grid; grid-template-columns: minmax(80px, 1fr) max-content max-content max-content max-content; align-items: end; gap: 8px; padding: 8px 10px; border: 1px solid #334155; border-radius: 6px; color: #cbd5e1; font-size: 12px; }
.ram-incident-row > strong { align-self: center; }
.ram-incident-field { display: grid; grid-template-rows: 13px 34px; gap: 5px; }
.ram-incident-field label { color: #94a3b8; font-size: 11px; font-weight: 700; letter-spacing: .06em; line-height: 13px; text-transform: uppercase; white-space: nowrap; }
.ram-incident-field > span { display: flex; align-items: center; gap: 5px; height: 34px; white-space: nowrap; }
.ram-incident-row input, .ram-incident-row select, .ram-incident-apply { height: 34px; box-sizing: border-box; }
.ram-incident-row input { width: 104px; }
.ram-incident-capture select { width: 114px; }
.ram-incident-jfr select { width: 70px; }
.ram-incident-state .cpu-quality { display: flex; align-items: center; height: 34px; padding-top: 0; padding-bottom: 0; }
.ram-incident-apply { padding: 0 16px; }
@media (max-width: 900px) { .ram-incident-controls { grid-template-columns: 1fr max-content; } .ram-incident-row { grid-column: 1 / -1; } .ram-incident-apply { grid-column: 2; } }
@media (max-width: 700px) { .ram-incident-controls { grid-template-columns: 1fr; } .ram-incident-row { grid-template-columns: minmax(100px, 1fr) max-content max-content; } .ram-incident-apply { grid-column: auto; justify-self: start; } }

.debug-actions {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.debug-capture-status {
    flex: 1 1 360px;
    min-height: 18px;
    color: #cbd5e1;
    font-size: 13px;
}

.debug-console-component {
    display: flex;
    flex: 1;
    flex-direction: column;
    min-height: 0;
}

.debug-session-tabs {
    display: flex;
    flex: 0 0 auto;
    flex-wrap: nowrap;
    gap: 2px;
    overflow-x: auto;
    overflow-y: hidden;
    margin: 0 0 -1px;
    padding: 0;
    position: relative;
    z-index: 2;
    white-space: nowrap;
    scrollbar-width: thin;
}

.debug-session-tab-pair {
    display: inline-flex;
    flex: 0 0 auto;
    height: 34px;
    margin: 0;
    position: relative;
}

.debug-session-tab-pair button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    height: 34px;
    margin: 0;
    border: 1px solid #334155;
    background: #1e293b;
    color: #aeb9c8;
    line-height: 1;
}

.debug-session-tab-main {
    width: auto;
    max-width: 240px;
    padding: 0 12px;
    overflow: hidden;
    border-right: 0;
    border-radius: 7px 0 0 0;
    text-overflow: ellipsis;
}

.debug-session-tab-download {
    flex: 0 0 34px;
    width: 34px;
    padding: 0;
    border-radius: 0 7px 0 0;
}

.debug-session-tab-download svg {
    width: 15px;
    height: 15px;
    fill: none;
    stroke: currentColor;
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 2;
}

.debug-session-tab-pair button:hover {
    background: #293548;
    color: #ffffff;
}

.debug-session-tab-pair.active {
    z-index: 3;
}

.debug-session-tab-pair.active button,
.debug-session-tab-pair.active button:hover {
    position: relative;
    z-index: 3;
    border-bottom-color: #020617;
    color: #ffffff;
}

.debug-session-tab-pair.all-sessions button {
    border-color: #3b82f6;
    background: #1e40af;
    color: #dbeafe;
}

.debug-session-tab-pair.all-sessions.active button,
.debug-session-tab-pair.all-sessions button:hover {
    background: #2563eb;
}

.debug-session-tab-pair.connected button {
    border-color: #166534;
    background: #14532d;
    color: #dcfce7;
}

.debug-session-tab-pair.connected.active button,
.debug-session-tab-pair.connected button:hover {
    border-color: #4ade80;
    background: #16a34a;
}

.debug-session-tab-pair.offline button {
    border-color: #991b1b;
    background: #7f1d1d;
    color: #fee2e2;
}

.debug-session-tab-pair.offline.active button,
.debug-session-tab-pair.offline button:hover {
    border-color: #f87171;
    background: #dc2626;
}

.debug-session-tab-pair.active button {
    border-bottom-color: #020617;
}

.debug-session-tab-download:disabled,
.debug-session-tab-download:disabled:hover {
    opacity: 0.38;
    cursor: default;
}

.debug-packet-filter-list {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    gap: 18px;
    max-height: 65vh;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 8px;
}

.debug-packet-filter-list label {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    margin-bottom: 0;
    text-align: left;
}

.debug-packet-filter-list input[type="checkbox"] {
    flex: 0 0 auto;
    width: 18px;
    height: 18px;
    margin: 0;
    padding: 0;
}

.debug-packet-filter-list label span {
    flex: 1 1 auto;
    text-align: left;
}

.modal-card.debug-packet-filter-modal-card {
    display: flex;
    flex-direction: column;
    width: min(560px, calc(100vw - 32px));
    overflow: hidden;
}

.debug-packet-filter-toolbar,
.debug-packet-filter-footer {
    display: flex;
    flex: 0 0 auto;
    gap: 8px;
}

.debug-packet-filter-toolbar {
    margin-bottom: 12px;
}

.debug-packet-filter-footer {
    justify-content: flex-end;
}

.debug-packet-filter-toolbar button,
.debug-packet-filter-footer button {
    width: auto;
}

.debug-packet-filter-group h3 {
    margin: 0 0 8px;
    padding-bottom: 5px;
    border-bottom: 1px solid #334155;
    font-size: 14px;
}

.debug-packet-filter-group-packets {
    display: flex;
    flex-direction: column;
    gap: 7px;
}

#debugPacketFilterStatus:empty {
    display: none;
}

#debugPacketOutput {
    flex: 1;
    min-height: 0;
    width: 100%;
    padding: 0;
    background: #020617;
    border: 1px solid #334155;
    border-radius: 0 7px 12px 12px;
    overflow: hidden;
    position: relative;
}

#debugPacketOutput .xterm {
    width: 100%;
    height: 100%;
    padding: 8px;
    overflow: hidden;
    box-sizing: border-box;
}

#debugPacketOutput .xterm-screen,
#debugPacketOutput .xterm-rows {
    pointer-events: none;
    user-select: none;
}

#debugPacketOutput .xterm-viewport {
    pointer-events: auto;
    overflow-y: auto !important;
}

.placeholder {
    padding: 24px;
    background: #111827;
    border: 1px solid #334155;
    border-radius: 12px;
    color: #9ca3af;
}

@media (max-width: 1200px) {
    .stats-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 800px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .console-layout {
        grid-template-columns: 1fr;
    }
}

.pnx-config-panel {
    padding: 16px;
    background: #111827;
    border: 1px solid #334155;
    border-radius: 12px;
}

.pnx-config-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 14px;
}

.pnx-config-header h2 {
    margin: 0 0 4px;
    font-size: 22px;
}

.pnx-config-header p {
    margin: 0;
    color: #9ca3af;
    font-size: 14px;
}

.pnx-config-actions {
    display: flex;
    gap: 8px;
}

.pnx-config-actions button {
    padding: 9px 14px;
}

.pnx-config-notice {
    margin-bottom: 12px;
    padding: 10px 12px;
    border: 1px solid #9a3412;
    border-radius: 8px;
    background: #431407;
    color: #fed7aa;
    font-size: 14px;
}

.pnx-config-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.pnx-config-section {
    padding: 14px 16px;
    background: #020617;
    border: 1px solid #334155;
    border-radius: 12px;
}

.pnx-config-section.full-width {
    grid-column: 1 / -1;
}

.pnx-config-section h3 {
    margin: 0 0 6px;
    font-size: 18px;
}

.pnx-config-section-description {
    margin: 0 0 14px;
    color: #9ca3af;
    font-size: 13px;
    line-height: 1.35;
}

.pnx-config-fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px 12px;
}

.pnx-config-field {
    margin-bottom: 0;
}

.pnx-config-field.full-width {
    grid-column: 1 / -1;
}

.pnx-config-field label {
    margin: 0;
}

.pnx-config-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.pnx-config-key {
    color: #cbd5e1;
    font-size: 14px;
    font-weight: 700;
}

.pnx-config-path {
    color: #64748b;
    font-size: 11px;
}

.pnx-config-field input,
.pnx-config-field textarea {
    display: block;
    width: 100%;
    margin-top: 5px;
    padding: 9px 11px;
    border: 1px solid #4b5563;
    border-radius: 7px;
    background: #020617;
    color: #e5e7eb;
    font-size: 14px;
}

.pnx-config-field input[type="text"],
.pnx-config-field input[type="number"] {
    height: 38px;
}

.pnx-config-field textarea {
    min-height: 90px;
    line-height: 1.35;
    resize: vertical;
}

.pnx-config-checkbox-box {
    height: 38px;
    margin-top: 5px;
    display: flex;
    align-items: center;
    padding: 0 11px;
    border: 1px solid #4b5563;
    border-radius: 7px;
    background: #020617;
}

.pnx-config-checkbox-box input {
    width: auto;
    margin: 0;
    padding: 0;
}

.pnx-config-section.nested {
    margin-top: 12px;
    padding: 12px;
    background: #030712;
}

.pnx-config-section.nested h4 {
    margin: 0 0 6px;
    font-size: 15px;
    color: #e5e7eb;
}

@media (max-width: 1100px) {
    .pnx-config-container {
        grid-template-columns: 1fr;
    }

    .pnx-config-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .pnx-config-fields {
        grid-template-columns: 1fr;
    }
}

.pnx-config-right-info {
    display: flex;
    align-items: center;
    gap: 6px;
}

.pnx-config-info {
    position: relative;
    width: 17px;
    height: 17px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #64748b;
    border-radius: 50%;
    color: #cbd5e1;
    font-size: 11px;
    font-weight: 800;
    cursor: help;
}

.pnx-config-info:hover {
    background: #1f2937;
    color: #ffffff;
    border-color: #94a3b8;
}

.pnx-config-info[data-tooltip]:hover::after {
    content: attr(data-tooltip);
    position: absolute;
    right: 0;
    bottom: 24px;
    width: max-content;
    max-width: 320px;
    padding: 9px 11px;
    background: #020617;
    border: 1px solid #475569;
    border-radius: 8px;
    color: #e5e7eb;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.35;
    white-space: normal;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.35);
    z-index: 100;
}

.pnx-config-info[data-tooltip]:hover::before {
    content: "";
    position: absolute;
    right: 6px;
    bottom: 18px;
    border-width: 6px 6px 0 6px;
    border-style: solid;
    border-color: #475569 transparent transparent transparent;
    z-index: 101;
}

.settings-panel {
    padding: 16px;
    background: #111827;
    border: 1px solid #334155;
    border-radius: 12px;
}

.settings-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 14px;
}

.settings-header h2 {
    margin: 0 0 4px;
    font-size: 22px;
}

.settings-header p {
    margin: 0;
    color: #9ca3af;
    font-size: 14px;
}

.settings-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
    align-items: start;
}

.settings-card {
    padding: 14px 16px;
    background: #020617;
    border: 1px solid #334155;
    border-radius: 12px;
}

.settings-card h3 {
    margin: 0 0 12px;
    font-size: 18px;
}

.settings-card label {
    margin-bottom: 10px;
    font-size: 14px;
}

.settings-card input,
.settings-card textarea,
.settings-card select {
    display: block;
    width: 100%;
    margin-top: 5px;
    padding: 9px 11px;
    border: 1px solid #4b5563;
    border-radius: 7px;
    background: #020617;
    color: #e5e7eb;
    font-size: 14px;
    resize: vertical;
}

.settings-card input[type="number"],
.settings-card input[type="time"],
.settings-card input[type="text"],
.settings-card input[type="password"] {
    height: 38px;
}

.settings-card textarea {
    min-height: 90px;
    line-height: 1.35;
}

#settingBackupIgnoreList {
    min-height: 115px;
}

#settingServiceFlags {
    min-height: 115px;
}

.settings-note {
    margin-top: 12px;
    padding: 10px 12px;
    border: 1px solid #7c2d12;
    border-radius: 8px;
    background: #431407;
    color: #fed7aa;
    font-size: 13px;
    line-height: 1.35;
}

.settings-status {
    margin-top: 12px;
    min-height: 20px;
    color: #86efac;
    font-size: 14px;
}

.repo-settings-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 200px 110px;
    gap: 12px;
    align-items: end;
    margin-bottom: 10px;
}

.repo-settings-row label {
    margin-bottom: 0;
}

.mode-field {
    display: block;
}

.feature-toggle-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 10px;
}

.debug-mode-settings-card {
    width: 100%;
    margin: 4px 0 16px;
    padding: 16px;
    border: 1px solid #4b5563;
    border-radius: 9px;
    background: #020617;
}

.debug-mode-settings-card h4 {
    margin: 0 0 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid #334155;
    font-size: 15px;
}

.debug-observer-toggle-list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px 20px;
}

.debug-observer-toggle-list label {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    margin: 0;
    padding: 3px 0;
    color: #e5e7eb;
}

.debug-observer-toggle-list input {
    flex: 0 0 auto;
    width: auto;
    margin: 0;
    padding: 0;
}

.debug-storage-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px 20px;
}

.debug-storage-field {
    display: grid;
    gap: 5px;
    margin: 0 !important;
}

.debug-storage-field > span {
    font-size: 14px;
}

.debug-storage-control {
    display: flex;
    align-items: center;
    gap: 7px;
}

.debug-storage-control input {
    width: 88px !important;
    margin: 0 !important;
}

.debug-storage-control b {
    color: #9ca3af;
    font-size: 13px;
    font-weight: 600;
}

.debug-observer-separator {
    height: 1px;
    margin: 14px 0 10px;
    background: #334155;
}

@media (max-width: 600px) {
    .debug-storage-grid,
    .debug-observer-toggle-list {
        grid-template-columns: 1fr;
    }
}

.mode-box {
    height: 38px;
    margin-top: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 1px solid #4b5563;
    border-radius: 7px;
    background: #020617;
    color: #e5e7eb;
    font-size: 14px;
    font-weight: 700;
}

.mode-box input {
    width: auto;
    margin: 0;
    padding: 0;
}

#saveSettingsBtn {
    padding: 9px 14px;
    min-width: 120px;
}

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

.user-avatar {
    width: 46px;
    height: 46px;
    padding: 0;
    border-radius: 50%;
    background-color: #002370;
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    color: #ffffff;
    font-weight: 800;
    font-size: 15px;
    border: 3px solid #3d66d7;
    box-shadow: 0 0 0 2px #020617;
    overflow: hidden;
    transform: none;
    transition: background-color 0.15s ease, border-color 0.15s ease;
}

.user-avatar:hover {
    background-color: #1d4ed8;
    background-size: cover;
    transform: none;
}

.profile-settings-row {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 14px;
}

.avatar-edit-box {
    position: relative;
    width: 82px;
    height: 82px;
    flex: 0 0 82px;
    margin: 0;
    cursor: pointer;
}

.avatar-edit-box input {
    display: none;
}

.avatar-edit-box:hover .avatar-edit-overlay {
    opacity: 1;
}

.avatar-edit-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.68);
    color: #ffffff;
    font-size: 13px;
    font-weight: 800;
    opacity: 0;
    transition: opacity 0.15s ease;
    pointer-events: none;
}

.user-avatar-preview {
    width: 82px;
    height: 82px;
    border: 2px solid #334155;
    border-radius: 999px;
    background-color: #334155;
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    color: #e5e7eb;
    font-size: 26px;
    font-weight: 800;
    line-height: 78px;
    text-align: center;
    overflow: hidden;
}

.profile-display-name-box {
    flex: 1;
    min-width: 0;
}

.profile-display-name-box label {
    margin-bottom: 10px;
}

.user-dropdown {
    position: absolute;
    top: 54px;
    right: 0;
    width: 180px;
    padding: 8px;
    background: #020617;
    border: 1px solid #334155;
    border-radius: 10px;
    box-shadow: 0 16px 35px rgba(0, 0, 0, 0.35);
    z-index: 50;
}

.user-dropdown button {
    width: 100%;
    padding: 10px 12px;
    text-align: left;
    background: transparent;
    color: #e5e7eb;
    border-radius: 7px;
}

.user-dropdown button:hover {
    background: #1f2937;
}




.plugin-list-header,
.plugin-row {
    display: grid;
    grid-template-columns: 160px minmax(220px, 1fr) 180px minmax(220px, 1fr) 90px 90px;
    gap: 10px;
    align-items: center;
}

.plugin-list-header {
    margin-bottom: 8px;
    padding: 0 4px;
    color: #94a3b8;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
}

.plugin-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.settings-list-empty-state {
    padding: 14px;
    border: 1px dashed #475569;
    border-radius: 10px;
    color: #94a3b8;
}

.plugin-row {
    padding: 10px;
    background: #020617;
    border: 1px solid #334155;
    border-radius: 10px;
}

.plugin-row input {
    margin: 0;
    height: 38px;
    padding: 9px 11px;
    border: 1px solid #4b5563;
    border-radius: 7px;
    background: #020617;
    color: #e5e7eb;
    font-size: 14px;
}

.plugin-row input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin: 0 auto;
}

.plugin-row button {
    padding: 9px 10px;
}

.resource-pack-list-header,
.resource-pack-row {
    display: grid;
    grid-template-columns: 160px minmax(220px, 1fr) 180px 180px 90px 120px minmax(220px, 1fr) 90px;
    gap: 10px;
    align-items: center;
}

.resource-pack-list-header {
    margin-bottom: 8px;
    padding: 0 4px;
    color: #94a3b8;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
}

.resource-pack-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.resource-pack-row {
    padding: 10px;
    background: #020617;
    border: 1px solid #334155;
    border-radius: 10px;
}

.resource-pack-row input {
    margin: 0;
    height: 38px;
    padding: 9px 11px;
    border: 1px solid #4b5563;
    border-radius: 7px;
    background: #020617;
    color: #e5e7eb;
    font-size: 14px;
}

.resource-pack-row input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin: 0 auto;
}

.resource-pack-key-field {
    display: flex;
    gap: 8px;
    align-items: center;
}

.resource-pack-key-field input {
    min-width: 0;
    flex: 1 1 auto;
}

.resource-pack-key-field button {
    flex: 0 0 auto;
    padding: 9px 10px;
    white-space: nowrap;
}

.resource-pack-row button {
    padding: 9px 10px;
}

@media (max-width: 1100px) {
    .plugin-list-header {
        display: none;
    }

    .plugin-row {
        grid-template-columns: 1fr;
    }

    .resource-pack-list-header {
        display: none;
    }

    .resource-pack-row {
        grid-template-columns: 1fr;
    }

    .resource-pack-key-field {
        flex-direction: column;
        align-items: stretch;
    }
}






@media (max-width: 1000px) {
    .settings-grid {
        grid-template-columns: 1fr;
    }

    .settings-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .tabs {
        align-items: stretch;
        flex-direction: column;
    }

    .tabs-left {
        flex-wrap: wrap;
    }

    .runtime-tab {
        max-width: 100%;
        grid-template-columns: 80px 1fr;
        border-radius: 8px;
        border-bottom-width: 2px;
    }

    .repo-settings-row {
        grid-template-columns: 1fr;
    }

    .feature-toggle-row {
        grid-template-columns: 1fr;
    }

    .debug-observer-toggle-list {
        grid-template-columns: 1fr;
    }

    .mode-box {
        justify-content: flex-start;
        padding-left: 12px;
    }
}
.backups-panel {
    padding: 16px;
    background: #111827;
    border: 1px solid #334155;
    border-radius: 12px;
}

.backups-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 14px;
}

.backups-header h2 {
    margin: 0 0 4px;
    font-size: 22px;
}

.backups-header p {
    margin: 0;
    color: #9ca3af;
    font-size: 14px;
}

.backups-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
}

.backup-upload-form {
    display: flex;
    align-items: center;
    gap: 8px;
}

.backup-upload-form input {
    width: 260px;
    height: 38px;
    margin: 0;
    padding: 8px 10px;
}

.backups-actions button,
.backup-upload-form button {
    height: 38px;
    padding: 9px 14px;
}

.backup-table-wrap {
    overflow-x: auto;
    background: #020617;
    border: 1px solid #334155;
    border-radius: 12px;
}

.backup-table {
    width: 100%;
    border-collapse: collapse;
}

.backup-table th,
.backup-table td {
    padding: 11px 12px;
    border-bottom: 1px solid #1f2937;
    text-align: left;
    font-size: 14px;
}

.backup-table th {
    color: #94a3b8;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    background: #030712;
}

.backup-table tr:last-child td {
    border-bottom: 0;
}

.backup-table a {
    color: #93c5fd;
    font-weight: 700;
    text-decoration: none;
}

.backup-table a:hover {
    text-decoration: underline;
}

.backup-table input[type="radio"] {
    width: auto;
    margin: 0;
    padding: 0;
}

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

.backup-actions-cell button {
    padding: 7px 10px;
    font-size: 12px;
}

@media (max-width: 1000px) {
    .backups-header {
        flex-direction: column;
    }

    .backups-actions,
    .backup-upload-form {
        width: 100%;
        justify-content: flex-start;
    }

    .backup-upload-form input {
        width: min(100%, 320px);
    }
}


.modal {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(2, 6, 23, 0.78);
}

#prodPinModal {
    z-index: 300;
}

.modal-card {
    width: min(920px, calc(100vw - 32px));
    max-height: calc(100vh - 48px);
    overflow: auto;
    padding: 16px;
    background: #111827;
    border: 1px solid #334155;
    border-radius: 12px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}

.modal-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 14px;
}

.modal-header h2 {
    margin: 0 0 4px;
    font-size: 22px;
}

.modal-header p {
    margin: 0;
    color: #9ca3af;
    font-size: 14px;
}

.settings-card.full-width {
    grid-column: 1 / -1;
}

@media (max-width: 980px) {
    .settings-grid {
        grid-template-columns: 1fr;
    }
}

.pin-modal-card {
    width: min(420px, calc(100vw - 32px));
    padding: 16px;
    background: #111827;
    border: 1px solid #334155;
    border-radius: 12px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}

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

#prodPinError {
    min-height: 20px;
    margin-top: 8px;
}

.wide-modal-card {
    width: min(1200px, calc(100vw - 32px));
}

.user-management-create-grid {
    display: grid;
    grid-template-columns: 180px 220px 140px 190px 140px;
    gap: 10px;
    align-items: end;
}

.user-management-create-grid label {
    margin-bottom: 0;
}

.user-management-table-wrap {
    margin-top: 14px;
    overflow: auto;
    border: 1px solid #334155;
    border-radius: 12px;
}

.user-management-row-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.user-management-row-actions button {
    padding: 8px 10px;
}

.user-management-input {
    width: 100%;
    height: 36px;
    margin: 0;
    padding: 8px 10px;
    border: 1px solid #4b5563;
    border-radius: 7px;
    background: #020617;
    color: #e5e7eb;
    font-size: 14px;
}

.user-management-select {
    width: 100%;
    height: 36px;
    margin: 0;
    padding: 8px 10px;
    border: 1px solid #4b5563;
    border-radius: 7px;
    background: #020617;
    color: #e5e7eb;
    font-size: 14px;
}

@media (max-width: 1100px) {
    .user-management-create-grid {
        grid-template-columns: 1fr;
    }
}


.user-menu {
    display: flex;
    align-items: center;
    gap: 10px;
    position: relative;
}

.user-presence-list {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.user-presence-avatar {
    width: 36px;
    height: 36px;
    margin-left: -10px;
    border: 3px solid #3d66d7;
    border-radius: 999px;
    background: #002370;
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    color: #e5e7eb;
    font-size: 13px;
    font-weight: 700;
    line-height: 30px;
    text-align: center;
    overflow: hidden;
    cursor: default;
}

.user-presence-avatar:first-child {
    margin-left: 0;
}

.user-avatar-preview {
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
}

.avatar-settings-row {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 12px;
}

.avatar-upload-label {
    flex: 1;
}

.settings-card.full-width .settings-note {
    margin-bottom: 14px;
}

.generated-password-box {
    margin: 12px 0;
    padding: 12px;
    border: 1px solid #22c55e;
    border-radius: 10px;
    background: rgba(34, 197, 94, 0.08);
    color: #d1fae5;
    font-family: Consolas, "Courier New", monospace;
    word-break: break-all;
}

.generated-password-box strong {
    display: block;
    margin-bottom: 6px;
    color: #86efac;
}

.two-factor-qr {
    display: block;
    width: 180px;
    height: 180px;
    margin: 12px 0;
    padding: 10px;
    border-radius: 12px;
    background: #ffffff;
}

#twoFactorSecret {
    font-family: Consolas, "Courier New", monospace;
    letter-spacing: 0.04em;
}

.settings-note {
    margin-bottom: 14px;
}

.two-factor-status-note {
    margin-bottom: 14px;
}

.two-factor-note {
    margin: 0 0 16px;
}

.two-factor-setup-box {
    margin-top: 14px;
}

.two-factor-setup-layout {
    display: grid;
    grid-template-columns: 180px minmax(0, 1fr);
    gap: 18px;
    align-items: start;
}

.two-factor-qr {
    margin: 0;
}

.two-factor-fields label {
    margin-bottom: 12px;
}

.two-factor-fields button {
    margin-top: 2px;
}

.password-note {
    margin-bottom: 16px;
}

#twoFactorDisableBox button {
    margin-top: 4px;
}

@media (max-width: 700px) {
    .two-factor-setup-layout {
        grid-template-columns: 1fr;
    }
}
