* { margin: 0; padding: 0; box-sizing: border-box; }
html { overflow-x: hidden; }
body {
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', system-ui, sans-serif;
    background: #000; color: #fff;
    min-height: 100vh; min-height: 100dvh;
    -webkit-font-smoothing: antialiased;
}
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.2); border-radius: 3px; }

.header {
    display: flex; align-items: center; justify-content: space-between;
    padding: 10px 20px;
    background: rgba(28,28,30,0.72);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border-bottom: 0.5px solid rgba(255,255,255,0.1);
    flex-wrap: wrap; gap: 6px;
    position: sticky; top: 0; z-index: 100;
}
.header h1 { font-size: 1.1em; font-weight: 600; letter-spacing: -0.02em; }
.header-right { display: flex; align-items: center; gap: 8px; }
.auto-refresh {
    font-size: 0.7em; color: #8e8e93;
    font-family: 'SF Mono', 'Menlo', monospace;
}
.refresh-btn {
    width: 32px; height: 32px; border-radius: 50%;
    border: 1.5px solid rgba(255,255,255,0.15);
    background: rgba(255,255,255,0.08); color: #8e8e93;
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    font-size: 0.8em; transition: all 0.2s;
}
.refresh-btn:hover { background: rgba(255,255,255,0.15); color: #fff; }
.refresh-btn:active { transform: scale(0.9); }
.refresh-btn.spinning { animation: spin 0.8s linear; }
@keyframes spin { to { transform: rotate(360deg); } }

.container { padding: 16px; max-width: 1400px; margin: 0 auto; }

/* Board Cards Grid */
.board-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px; margin-bottom: 16px;
}
@media (max-width: 900px) { .board-grid { grid-template-columns: 1fr; } }

.board-card {
    background: rgba(28,28,30,0.72);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border: 0.5px solid rgba(255,255,255,0.1);
    border-radius: 12px; padding: 16px;
    transition: border-color 0.3s;
}
.board-card.online { border-color: rgba(48,209,88,0.3); }
.board-card.offline { opacity: 0.5; }

.card-header {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 12px;
}
.card-title { font-size: 0.95em; font-weight: 600; }
.status-dot {
    width: 8px; height: 8px; border-radius: 50%;
    display: inline-block; margin-right: 6px;
}
.status-dot.on { background: #30d158; box-shadow: 0 0 6px rgba(48,209,88,0.5); }
.status-dot.off { background: #636366; }
.card-subtitle {
    font-size: 0.7em; color: #8e8e93;
    font-family: 'SF Mono', 'Menlo', monospace;
}

/* Sections */
.section-label {
    font-size: 0.75em; color: #636366; text-transform: uppercase;
    letter-spacing: 0.05em; margin: 10px 0 6px; padding-top: 8px;
    border-top: 0.5px solid rgba(255,255,255,0.06);
}

/* GPIO Toggle Buttons */
.gpio-row { display: flex; flex-wrap: wrap; gap: 6px; }
.gpio-btn {
    width: 36px; height: 36px; border-radius: 50%;
    border: 1.5px solid rgba(255,255,255,0.15);
    background: rgba(255,255,255,0.06); color: #8e8e93;
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    font-size: 0.65em; font-weight: 600; transition: all 0.2s;
    position: relative;
}
.gpio-btn:hover { background: rgba(255,255,255,0.12); }
.gpio-btn:active { transform: scale(0.9); }
.gpio-btn.on { border-color: var(--btn-color, #30d158); color: var(--btn-color, #30d158); background: var(--btn-bg, rgba(48,209,88,0.15)); }
.gpio-btn[data-dev="ir"] { --btn-color: #ff453a; --btn-bg: rgba(255,69,58,0.15); }
.gpio-btn[data-dev="led"] { --btn-color: #ff9f0a; --btn-bg: rgba(255,159,10,0.15); }
.gpio-btn[data-dev="irled"] { --btn-color: #ff453a; --btn-bg: rgba(255,69,58,0.15); }
.gpio-btn[data-dev="osd"] { --btn-color: #0a84ff; --btn-bg: rgba(10,132,255,0.15); }
.gpio-btn[data-dev="tof"] { --btn-color: #30d158; --btn-bg: rgba(48,209,88,0.15); }

/* Sliders */
.slider-row { display: flex; align-items: center; gap: 8px; margin: 4px 0; }
.slider-label { font-size: 0.72em; color: #8e8e93; width: 55px; }
.slider-val {
    font-size: 0.72em; color: #fff; width: 28px; text-align: right;
    font-family: 'SF Mono', 'Menlo', monospace;
}
input[type="range"] {
    -webkit-appearance: none; appearance: none;
    flex: 1; height: 4px; border-radius: 2px;
    background: rgba(255,255,255,0.15); outline: none;
}
input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none; width: 14px; height: 14px;
    border-radius: 50%; background: #fff; cursor: pointer;
    box-shadow: 0 1px 4px rgba(0,0,0,0.4);
}

/* Encoding Dropdowns */
.encoding-row { display: flex; gap: 6px; flex-wrap: wrap; }
.enc-select {
    background: rgba(255,255,255,0.08); color: #fff;
    border: 1px solid rgba(255,255,255,0.15); border-radius: 8px;
    padding: 4px 8px; font-size: 0.7em;
    font-family: 'SF Mono', 'Menlo', monospace;
}
.enc-select option { background: #1c1c1e; color: #fff; }

/* System Info */
.sys-row {
    display: flex; justify-content: space-between;
    font-size: 0.7em; margin: 2px 0;
    font-family: 'SF Mono', 'Menlo', monospace;
}
.sys-label { color: #8e8e93; }
.sys-val { color: #fff; }

/* Card Actions */
.card-actions { display: flex; gap: 6px; margin-top: 10px; }
.action-btn {
    flex: 1; padding: 6px; border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.12);
    background: rgba(255,255,255,0.06); color: #8e8e93;
    font-size: 0.7em; cursor: pointer; text-align: center;
    transition: all 0.2s; text-decoration: none;
}
.action-btn:hover { background: rgba(255,255,255,0.12); color: #fff; }
.action-btn.danger:hover { background: rgba(255,69,58,0.15); color: #ff453a; border-color: rgba(255,69,58,0.3); }

/* Deploy Panel */
.deploy-panel {
    background: rgba(28,28,30,0.72);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border: 0.5px solid rgba(255,255,255,0.1);
    border-radius: 12px; padding: 16px; margin-bottom: 16px;
}
.deploy-title { font-size: 0.9em; font-weight: 600; margin-bottom: 12px; }

.drop-zone {
    border: 2px dashed rgba(255,255,255,0.15); border-radius: 10px;
    padding: 24px; text-align: center; color: #636366;
    font-size: 0.8em; cursor: pointer; transition: all 0.3s;
    margin-bottom: 12px;
}
.drop-zone:hover, .drop-zone.dragover {
    border-color: #0a84ff; color: #0a84ff; background: rgba(10,132,255,0.05);
}
.drop-zone input[type="file"] { display: none; }

.file-info {
    font-size: 0.7em; color: #8e8e93;
    font-family: 'SF Mono', 'Menlo', monospace;
    margin-bottom: 8px; line-height: 1.6;
}
.file-info .hash { color: #636366; }

.deploy-config { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 12px; }
.target-select {
    background: rgba(255,255,255,0.08); color: #fff;
    border: 1px solid rgba(255,255,255,0.15); border-radius: 8px;
    padding: 6px 10px; font-size: 0.75em; flex: 1; min-width: 200px;
}
.target-select option { background: #1c1c1e; }

.board-checks { display: flex; gap: 12px; }
.board-check { display: flex; align-items: center; gap: 4px; font-size: 0.75em; cursor: pointer; }
.board-check input { accent-color: #0a84ff; }

.deploy-btn {
    padding: 8px 20px; border-radius: 8px; border: none;
    background: #0a84ff; color: #fff; font-size: 0.8em; font-weight: 600;
    cursor: pointer; transition: all 0.2s;
}
.deploy-btn:hover { background: #0070e0; }
.deploy-btn:disabled { opacity: 0.4; cursor: not-allowed; }
.deploy-btn.flash-btn { background: #ff453a; }
.deploy-btn.flash-btn:hover { background: #e03e35; }

.deploy-mode-toggle {
    display: flex; gap: 0; margin-bottom: 12px; border-radius: 8px; overflow: hidden;
    border: 1px solid rgba(255,255,255,0.15);
}
.deploy-mode-toggle button {
    flex: 1; padding: 6px 12px; border: none; background: transparent;
    color: #8e8e93; font-size: 0.75em; font-weight: 600; cursor: pointer;
    transition: all 0.2s;
}
.deploy-mode-toggle button.active {
    background: rgba(10,132,255,0.2); color: #0a84ff;
}
.deploy-mode-toggle button.active.flash-mode {
    background: rgba(255,69,58,0.2); color: #ff453a;
}
.deploy-mode-toggle #modeOta.active {
    background: rgba(48,209,88,0.2); color: #30d158;
}
.flash-warning {
    font-size: 0.7em; color: #ff9f0a; background: rgba(255,159,10,0.1);
    border: 1px solid rgba(255,159,10,0.2); border-radius: 8px;
    padding: 8px 10px; margin-bottom: 10px; line-height: 1.5;
}
.flash-board-select { display: flex; gap: 10px; margin-bottom: 10px; }
.flash-board-radio { display: flex; align-items: center; gap: 4px; font-size: 0.75em; cursor: pointer; }
.flash-board-radio input { accent-color: #ff453a; }

/* Progress Bars */
.progress-list { margin-top: 12px; }
.progress-item { margin-bottom: 8px; }
.progress-label { font-size: 0.7em; color: #8e8e93; margin-bottom: 3px; }
.progress-bar {
    height: 6px; border-radius: 3px;
    background: rgba(255,255,255,0.1); overflow: hidden;
}
.progress-fill {
    height: 100%; border-radius: 3px;
    background: #0a84ff; transition: width 0.3s;
}
.progress-fill.error { background: #ff453a; }
.progress-fill.complete { background: #30d158; }
.progress-msg {
    font-size: 0.65em; color: #636366;
    font-family: 'SF Mono', 'Menlo', monospace;
    margin-top: 2px;
}

/* Activity Log */
.log-panel {
    background: rgba(28,28,30,0.72);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border: 0.5px solid rgba(255,255,255,0.1);
    border-radius: 12px; padding: 16px;
}
.log-title { font-size: 0.9em; font-weight: 600; margin-bottom: 8px; }
.log-entries {
    max-height: 200px; overflow-y: auto;
    font-size: 0.72em; color: #8e8e93;
    font-family: 'SF Mono', 'Menlo', monospace;
    line-height: 1.5;
}
.log-entry .log-time { color: #636366; }
.log-entry .log-board { color: #0a84ff; }
.log-entry .log-ok { color: #30d158; }
.log-entry .log-err { color: #ff453a; }

/* Log Tabs */
.log-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; flex-wrap: wrap; gap: 6px; }
.log-tabs { display: flex; gap: 0; border-radius: 6px; overflow: hidden; border: 1px solid rgba(255,255,255,0.12); }
.log-tab {
    padding: 4px 10px; border: none; background: transparent;
    color: #8e8e93; font-size: 0.7em; font-weight: 600; cursor: pointer;
    transition: all 0.2s;
}
.log-tab.active { background: rgba(10,132,255,0.2); color: #0a84ff; }
.log-date-select {
    background: rgba(255,255,255,0.08); color: #fff;
    border: 1px solid rgba(255,255,255,0.15); border-radius: 6px;
    padding: 3px 6px; font-size: 0.65em;
    font-family: 'SF Mono', 'Menlo', monospace;
}
.log-date-select option { background: #1c1c1e; color: #fff; }

/* LIVE Badge */
.live-badge {
    font-size: 0.55em; font-weight: 700; color: #30d158;
    background: rgba(48,209,88,0.15); padding: 2px 6px;
    border-radius: 4px; margin-left: 6px;
    animation: livePulse 2s ease-in-out infinite;
    display: none;
}
.live-badge.show { display: inline; }
@keyframes livePulse { 50% { opacity: 0.5; } }

/* Collapsible */
.collapsible { cursor: pointer; user-select: none; }
.collapsible::after { content: ' +'; color: #636366; font-size: 0.8em; }
.collapsible.open::after { content: ' -'; }
.collapse-body { display: none; }
.collapse-body.open { display: block; }

/* Network Section */
.net-row {
    display: flex; justify-content: space-between; align-items: center;
    font-size: 0.7em; margin: 3px 0;
    font-family: 'SF Mono', 'Menlo', monospace;
}
.net-iface {
    font-weight: 600; padding: 1px 5px; border-radius: 3px;
    font-size: 0.85em;
}
.net-iface.up { background: rgba(48,209,88,0.15); color: #30d158; }
.net-iface.down { background: rgba(99,99,102,0.15); color: #636366; }
.net-detail { color: #8e8e93; }
.net-toggle-row { display: flex; gap: 4px; align-items: center; margin: 4px 0; }
.net-toggle-label { font-size: 0.72em; color: #8e8e93; width: 65px; }
.net-toggle-btn {
    padding: 2px 10px; border-radius: 5px;
    border: 1px solid rgba(255,255,255,0.12);
    background: rgba(255,255,255,0.06); color: #636366;
    font-size: 0.72em; font-weight: 600; cursor: pointer;
    transition: all 0.2s;
}
.net-toggle-btn:hover { background: rgba(255,255,255,0.12); }
.net-toggle-btn.active { border-color: #0a84ff; color: #0a84ff; background: rgba(10,132,255,0.15); }
.net-toggle-btn.disabled { opacity: 0.3; cursor: not-allowed; pointer-events: none; }

/* License Panel */
.license-panel {
    background: rgba(28,28,30,0.72);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border: 0.5px solid rgba(255,255,255,0.1);
    border-radius: 12px; padding: 16px; margin-bottom: 16px;
}
.license-title { font-size: 0.9em; font-weight: 600; margin-bottom: 12px; }
.license-board-cards { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.license-board-card {
    flex: 1; min-width: 120px; padding: 10px 14px;
    border-radius: 10px; cursor: pointer;
    border: 1.5px solid rgba(255,255,255,0.1);
    background: rgba(255,255,255,0.04);
    transition: all 0.2s;
}
.license-board-card:hover { border-color: rgba(255,255,255,0.2); background: rgba(255,255,255,0.08); }
.license-board-card.selected { border-color: #0a84ff; background: rgba(10,132,255,0.1); }
.license-board-name { font-size: 0.8em; font-weight: 600; margin-bottom: 4px; }
.license-board-tier {
    font-size: 0.65em; font-weight: 700; padding: 1px 6px;
    border-radius: 4px; display: inline-block; margin-bottom: 4px;
}
.license-board-tier.pro { background: rgba(48,209,88,0.15); color: #30d158; }
.license-board-tier.standard { background: rgba(10,132,255,0.15); color: #0a84ff; }
.license-board-tier.basic { background: rgba(99,99,102,0.15); color: #636366; }
.license-board-ip {
    font-size: 0.65em; color: #8e8e93;
    font-family: 'SF Mono','Menlo',monospace;
}
.license-detail {
    border-top: 0.5px solid rgba(255,255,255,0.06);
    padding-top: 12px; margin-top: 4px;
}
.license-detail-header {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 8px;
}
.license-detail-title { font-size: 0.85em; font-weight: 600; }
.license-mono {
    font-family: 'SF Mono','Menlo',monospace; font-size: 0.9em;
    word-break: break-all;
}
.license-textarea {
    width: 100%; background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12); border-radius: 8px;
    color: #fff; padding: 8px; font-size: 0.7em;
    font-family: 'SF Mono','Menlo',monospace;
    resize: vertical; line-height: 1.5;
}
.license-textarea:focus { border-color: #0a84ff; outline: none; }
.license-code-input {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12); border-radius: 6px;
    color: #fff; padding: 4px 8px; font-size: 0.7em;
    font-family: 'SF Mono','Menlo',monospace;
}
.license-code-input:focus { border-color: #0a84ff; outline: none; }
.license-codes-list {
    max-height: 150px; overflow-y: auto;
    font-size: 0.72em; font-family: 'SF Mono','Menlo',monospace;
    color: #8e8e93; line-height: 1.6;
}
.license-code-row {
    display: flex; justify-content: space-between; align-items: center;
    padding: 3px 0; border-bottom: 0.5px solid rgba(255,255,255,0.04);
}
.license-code-val { color: #fff; }
.license-code-tier { font-weight: 600; }
.license-code-used { color: #ff453a; }
.license-code-avail { color: #30d158; }
.license-audit-list {
    max-height: 200px; overflow-y: auto;
    font-size: 0.72em; font-family: 'SF Mono','Menlo',monospace;
    color: #8e8e93; line-height: 1.5;
}
.license-audit-row { padding: 2px 0; border-bottom: 0.5px solid rgba(255,255,255,0.04); }
.license-audit-time { color: #636366; }
.license-audit-action { color: #0a84ff; }
.license-codes-section {
    border-top: 0.5px solid rgba(255,255,255,0.06);
    padding-top: 4px;
}

/* BIT Panel */
.bit-panel {
    background: rgba(28,28,30,0.72);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border: 0.5px solid rgba(255,255,255,0.1);
    border-radius: 12px; padding: 16px; margin-bottom: 16px;
}
.bit-title { font-size: 0.9em; font-weight: 600; margin-bottom: 12px; }
.bit-header { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; flex-wrap: wrap; }
.bit-start-btn {
    padding: 6px 16px; border-radius: 8px; border: none;
    background: #30d158; color: #fff; font-size: 0.8em; font-weight: 600;
    cursor: pointer; transition: all 0.2s;
}
.bit-start-btn:hover { background: #28b84e; }
.bit-start-btn:disabled { opacity: 0.4; cursor: not-allowed; }
.bit-progress-bar {
    height: 8px; border-radius: 4px; background: rgba(255,255,255,0.1);
    overflow: hidden; margin-bottom: 8px;
}
.bit-progress-fill {
    height: 100%; border-radius: 4px; background: #30d158;
    transition: width 0.3s;
}
.bit-progress-text {
    font-size: 0.7em; color: #8e8e93; margin-bottom: 6px;
    font-family: 'SF Mono', 'Menlo', monospace;
}
.bit-results {
    max-height: 300px; overflow-y: auto;
    font-size: 0.72em; font-family: 'SF Mono', 'Menlo', monospace;
    line-height: 1.6;
}
.bit-item { display: flex; align-items: center; gap: 6px; padding: 1px 0; }
.bit-icon { width: 16px; text-align: center; }
.bit-icon.pass { color: #30d158; }
.bit-icon.fail { color: #ff453a; }
.bit-icon.running { color: #0a84ff; }
.bit-icon.pending { color: #636366; }
.bit-name { color: #fff; flex: 1; }
.bit-detail { color: #636366; max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bit-time { color: #636366; width: 45px; text-align: right; }
.bit-summary {
    display: flex; gap: 16px; font-size: 0.75em; margin-top: 8px;
    font-family: 'SF Mono', 'Menlo', monospace;
}
.bit-summary .pass-count { color: #30d158; }
.bit-summary .fail-count { color: #ff453a; }
.bit-summary .skip-count { color: #636366; }

/* ── Monitor Panel ── */
.monitor-panel {
    background: rgba(28,28,30,0.72);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border: 0.5px solid rgba(255,255,255,0.1);
    border-radius: 12px; padding: 16px; margin-bottom: 16px;
}
.monitor-header {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 12px; flex-wrap: wrap; gap: 8px;
}
.monitor-title { font-weight: 600; font-size: 1em; }
.monitor-search input {
    background: #2c2c2e; border: 1px solid #38383a; border-radius: 8px;
    color: #fff; padding: 6px 10px; font-size: 0.75em; width: 200px;
}
.monitor-cards {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 10px; margin-bottom: 16px;
}
.monitor-card {
    background: #2c2c2e; border-radius: 10px; padding: 12px;
    border-left: 3px solid #636366;
}
.monitor-card.online { border-left-color: #30d158; }
.monitor-card.offline { border-left-color: #ff453a; }
.monitor-card-header {
    display: flex; align-items: center; gap: 6px; margin-bottom: 6px;
    font-size: 0.85em;
}
.monitor-card-header .status-dot {
    width: 8px; height: 8px; border-radius: 50%;
    display: inline-block; flex-shrink: 0;
}
.monitor-card-header .status-dot.on { background: #30d158; }
.monitor-card-header .status-dot.off { background: #ff453a; }
.monitor-card-metrics {
    display: flex; flex-wrap: wrap; gap: 6px;
    font-size: 0.7em; color: #8e8e93;
}
.monitor-card-metrics span { white-space: nowrap; }
.monitor-chart-section { margin: 16px 0; }
.chart-controls {
    display: flex; gap: 8px; margin-bottom: 8px; align-items: center;
}
.anomaly-timeline { margin-top: 12px; }
.anomaly-list { max-height: 250px; overflow-y: auto; }
.anomaly-item {
    display: flex; gap: 8px; align-items: center; padding: 6px 0;
    border-bottom: 1px solid #2c2c2e; font-size: 0.75em;
}
.anomaly-item .anomaly-dot {
    width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0;
}
.anomaly-item.critical .anomaly-dot { background: #ff453a; }
.anomaly-item.warning .anomaly-dot { background: #ff9f0a; }
.anomaly-item .anomaly-time { color: #8e8e93; min-width: 50px; }

/* ── CS Inspect Panel ── */
.inspect-panel {
    background: rgba(28,28,30,0.72);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border: 0.5px solid rgba(255,255,255,0.1);
    border-radius: 12px; padding: 16px; margin-bottom: 16px;
}
.inspect-header {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 12px;
}
.inspect-title { font-weight: 600; font-size: 1em; }
.inspect-actions {
    display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 12px;
}
.inspect-cmd-row {
    display: flex; gap: 8px; align-items: center; margin-bottom: 8px;
    flex-wrap: wrap;
}
.inspect-input {
    background: #2c2c2e; border: 1px solid #38383a; border-radius: 8px;
    color: #fff; padding: 6px 10px; font-size: 0.75em; flex: 1; min-width: 120px;
}
.inspect-output {
    background: #000; border-radius: 8px; padding: 10px; margin-top: 8px;
    font-family: 'SF Mono', 'Menlo', monospace; font-size: 0.7em;
    color: #30d158; overflow-x: auto; max-height: 300px; overflow-y: auto;
    white-space: pre-wrap; word-break: break-all;
}
.inspect-log-btns { display: flex; gap: 6px; flex-wrap: wrap; }
.action-btn.danger {
    background: rgba(255,69,58,0.15); color: #ff453a; border-color: #ff453a;
}

/* ── Main Tab Navigation ── */
.main-tabs {
    display: flex; gap: 2px; padding: 3px;
    background: rgba(118,118,128,0.24); position: sticky; top: 52px;
    z-index: 99; max-width: 1400px; margin: 8px auto 0; border-radius: 8px;
}
.main-tab {
    flex: 1; padding: 7px 0; border: none; border-radius: 6px;
    background: transparent; color: #8e8e93; cursor: pointer;
    font-size: 0.78em; font-weight: 600; transition: all 0.2s;
}
.main-tab.active {
    background: #636366; color: #fff;
    box-shadow: 0 1px 3px rgba(0,0,0,0.3);
}
.main-tab-pane { display: none; }
.main-tab-pane.active { display: block; }

/* ── Toast Notifications ── */
.toast-container {
    position: fixed; top: 60px; left: 50%; transform: translateX(-50%);
    z-index: 10000; display: flex; flex-direction: column; gap: 8px; pointer-events: none;
}
.toast {
    padding: 10px 20px; border-radius: 10px; font-size: 0.8em; font-weight: 500;
    backdrop-filter: saturate(180%) blur(20px); box-shadow: 0 4px 12px rgba(0,0,0,0.4);
    animation: toastIn 0.3s ease-out; pointer-events: auto; max-width: 90vw;
}
.toast.success { background: rgba(48,209,88,0.9); color: #fff; }
.toast.error { background: rgba(255,69,58,0.9); color: #fff; }
.toast.info { background: rgba(10,132,255,0.9); color: #fff; }
.toast.fadeout { animation: toastOut 0.3s forwards; }
@keyframes toastIn { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }
@keyframes toastOut { from { opacity: 1; } to { opacity: 0; transform: translateY(-10px); } }

/* ── Modal ── */
.modal-overlay {
    display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.7);
    z-index: 9999; align-items: center; justify-content: center;
}
.modal-overlay.open { display: flex; }
.modal-box {
    background: rgba(28,28,30,0.95); backdrop-filter: saturate(180%) blur(20px);
    border: 0.5px solid rgba(255,255,255,0.1); border-radius: 12px;
    padding: 24px; width: 300px; max-width: 90vw;
}
.modal-box h3 { margin: 0 0 16px; color: #fff; font-size: 1em; }
.modal-input {
    width: 100%; padding: 10px 12px; margin-bottom: 8px; border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.15); background: rgba(44,44,46,0.72);
    color: #fff; box-sizing: border-box; font-size: 0.9em;
}
.modal-input:focus { border-color: #0a84ff; outline: none; }
.modal-actions { display: flex; gap: 8px; justify-content: flex-end; }
.modal-msg { color: #ff453a; font-size: 0.85em; margin-bottom: 8px; min-height: 1.2em; }

/* ── Spinner ── */
.spinner {
    display: inline-block; width: 14px; height: 14px;
    border: 2px solid rgba(255,255,255,0.2); border-top-color: #0a84ff;
    border-radius: 50%; animation: spin 0.8s linear infinite;
}
.hidden { display: none !important; }
.header-action-btn { font-size: 0.72em; padding: 5px 10px; margin-left: 4px; }

/* ── Responsive ── */
@media (max-width: 600px) {
    .main-tabs { border-radius: 0; top: 46px; }
    .main-tab { font-size: 0.68em; padding: 6px 0; }
    .board-grid { grid-template-columns: 1fr; }
    .monitor-cards { grid-template-columns: 1fr; }
}
