.icon { flex: 0 0 auto; }
.button {
  min-height: 38px; border: 1px solid transparent; border-radius: 9px; padding: 0 13px;
  display: inline-flex; align-items: center; justify-content: center; gap: 7px; cursor: pointer;
  font-size: 11.5px; font-weight: 750; white-space: nowrap; transition: transform var(--ease), box-shadow var(--ease), background var(--ease), border-color var(--ease);
}
.button:hover { transform: translateY(-1px); box-shadow: var(--shadow-sm); }
.button:active { transform: translateY(0); }
.button.primary { color: white; background: linear-gradient(135deg,#5b5ce2,#6249ed); box-shadow: 0 7px 16px rgba(91,92,226,.18); }
.button.secondary { color: var(--text-soft); background: white; border-color: var(--border); }
.button.soft { color: var(--primary-strong); background: var(--primary-soft); border-color: #dde0ff; }
.button.ghost { color: var(--text-soft); background: transparent; }
.button.outline-primary { color: var(--primary); background: white; border-color: #cfd1ff; }
.button.success { color: white; background: var(--green); }
.button.warning { color: #8b5612; background: var(--orange-soft); border-color: #f8dcae; }
.button.danger { color: white; background: var(--red); }
.button.danger-outline { color: var(--red); background: white; border-color: #ffb7c0; }
.button.full { width: 100%; margin-top: 7px; }
.button-like { min-height: 38px; border: 1px solid var(--border); border-radius: 9px; padding: 0 34px 0 12px; background: white; color: var(--text-soft); font-size: 11.5px; }
.text-button, .link-button { border: 0; background: none; color: var(--primary); font-size: 11px; font-weight: 720; cursor: pointer; padding: 3px; }
.link-button { width: 100%; display: flex; align-items: center; justify-content: center; gap: 7px; min-height: 39px; border-top: 1px solid var(--border); margin-top: 9px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md); box-shadow: var(--shadow-xs); padding: 14px; min-width: 0; }
.sticky-card { position: sticky; top: calc(var(--topbar-height) + 16px); }
.full-height-card { height: 100%; display: flex; flex-direction: column; }
.panel-header { min-height: 30px; display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.panel-header h2 { display: flex; align-items: center; gap: 7px; margin: 0; color: var(--text); font-size: 13px; letter-spacing: -.015em; }
.panel-header p { margin: 4px 0 0; color: var(--muted); font-size: 10.5px; }
.stats-grid { display: grid; gap: 12px; margin-bottom: 14px; }
.stats-grid.four { grid-template-columns: repeat(4,minmax(0,1fr)); }
.stats-grid.six { grid-template-columns: repeat(6,minmax(0,1fr)); }
.stat-card { min-height: 86px; padding: 13px; border: 1px solid var(--border); border-radius: 12px; background: white; display: flex; align-items: flex-start; gap: 11px; box-shadow: var(--shadow-xs); }
.stat-icon { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; flex: 0 0 auto; }
.stat-icon.primary { color: var(--primary); background: var(--primary-soft); }
.stat-icon.success { color: var(--green); background: var(--green-soft); }
.stat-icon.warning { color: var(--orange); background: var(--orange-soft); }
.stat-icon.danger { color: var(--red); background: var(--red-soft); }
.stat-icon.info { color: var(--blue); background: var(--blue-soft); }
.stat-body { min-width: 0; display: grid; gap: 3px; }
.stat-label { color: var(--text-soft); font-size: 10.5px; font-weight: 650; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stat-body strong { font-size: 22px; line-height: 1; letter-spacing: -.035em; }
.stat-delta, .stat-note { margin-top: 3px; color: var(--muted); font-size: 9.5px; white-space: nowrap; }
.stat-delta.up { color: var(--green); }
.stat-delta.down { color: var(--red); }
.stat-note { color: var(--muted); }
.badge { display: inline-flex; align-items: center; justify-content: center; min-height: 21px; padding: 2px 7px; border-radius: 999px; font-size: 9px; font-weight: 760; white-space: nowrap; }
.badge.success { color: #087a4c; background: var(--green-soft); }
.badge.warning { color: #a26311; background: var(--orange-soft); }
.badge.danger { color: #c53042; background: var(--red-soft); }
.badge.primary { color: #5543c5; background: var(--purple-soft); }
.badge.info { color: #1766bf; background: var(--blue-soft); }
.badge.neutral { color: #586477; background: var(--surface-muted); }
.platform-icon { width: 30px; height: 30px; border-radius: 50%; display: inline-grid; place-items: center; background: var(--platform); color: white; font-size: 10px; font-weight: 850; line-height: 1; flex: 0 0 auto; box-shadow: inset 0 0 0 1px rgba(255,255,255,.16); }
.platform-icon.lg { width: 38px; height: 38px; font-size: 13px; }
.platform-icon.md { width: 29px; height: 29px; }
.platform-icon.sm { width: 22px; height: 22px; font-size: 8px; }
.platform-icon.xs { width: 16px; height: 16px; font-size: 6px; }
.mini-select { min-height: 28px; border: 1px solid var(--border); background: white; border-radius: 7px; color: var(--text-soft); padding: 0 24px 0 8px; font-size: 9.5px; }
.field { display: grid; gap: 6px; margin-top: 11px; }
.field > span, .publish-fields label > span { font-size: 10px; font-weight: 700; color: var(--text-soft); }
.field em { font-style: normal; color: var(--muted); font-weight: 500; }
.field input, .field textarea, .field select, .toolbar input, .toolbar select, .filter-bar select, .filter-bar input, .search-input, .status-select, .reply-actions select, .format-row select, .paired-input input {
  min-height: 38px; border: 1px solid var(--border); border-radius: 8px; background: white; color: var(--text); padding: 8px 10px; outline: 0; font-size: 11px;
}
.field textarea { min-height: 72px; resize: vertical; }
.field input:focus, .field textarea:focus, .field select:focus, .search-input:focus-within, .toolbar input:focus, .toolbar select:focus { border-color: #aeb1f6; box-shadow: 0 0 0 3px rgba(91,92,226,.08); }
.field.compact { margin: 0; }
.field.compact > span { font-size: 9px; }
.search-input { display: flex; align-items: center; gap: 7px; padding: 0 10px; background: white; }
.search-input input { min-width: 0; width: 100%; border: 0; outline: 0; padding: 0; background: transparent; font-size: 11px; }
.search-input.grow { flex: 1; }
.toolbar { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.toolbar.compact { gap: 6px; }
.toolbar.compact input { min-height: 30px; }
.filter-bar { display: flex; align-items: flex-end; gap: 10px; flex-wrap: wrap; margin-bottom: 13px; }
.filter-bar > label { min-width: 140px; display: grid; gap: 5px; }
.filter-bar label span { color: var(--muted); font-size: 9px; font-weight: 680; }
.filter-bar select { width: 100%; min-height: 36px; padding: 0 30px 0 9px; }
.toggle-row { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 42px; cursor: pointer; }
.toggle-row > span:first-child { display: grid; gap: 2px; }
.toggle-row strong { font-size: 10.5px; }
.toggle-row small { font-size: 9px; color: var(--muted); }
.toggle-row input { position: absolute; opacity: 0; pointer-events: none; }
.toggle-control { position: relative; width: 34px; height: 19px; border-radius: 999px; background: #d9deea; flex: 0 0 auto; transition: background var(--ease); }
.toggle-control::after { content: ''; position: absolute; top: 3px; left: 3px; width: 13px; height: 13px; border-radius: 50%; background: white; box-shadow: 0 1px 3px rgba(0,0,0,.15); transition: transform var(--ease); }
.toggle-row input:checked + .toggle-control { background: var(--primary); }
.toggle-row input:checked + .toggle-control::after { transform: translateX(15px); }
.inline-toggle { display: inline-flex; align-items: center; gap: 8px; font-size: 9.5px; color: var(--muted); }
.inline-toggle input { display: none; }
.inline-toggle i { position: relative; width: 30px; height: 17px; border-radius: 999px; background: var(--primary); }
.inline-toggle i::after { content: ''; position: absolute; width: 11px; height: 11px; border-radius: 50%; background: white; top: 3px; right: 3px; }
.progress { display: block; min-width: 66px; height: 5px; border-radius: 99px; background: var(--surface-muted); overflow: hidden; }
.progress-fill { display: block; height: 100%; border-radius: inherit; background: var(--primary); }
.progress-fill.success { background: var(--green); }.progress-fill.warning { background: var(--orange); }.progress-fill.danger { background: var(--red); }
.chart-wrap { min-width: 0; overflow: hidden; }
.chart-wrap svg { width: 100%; height: auto; overflow: visible; }
.chart-grid { stroke: #edf0f6; stroke-width: 1; }
.chart-line { fill: none; stroke: var(--line); stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.chart-line.line-1 { stroke-dasharray: 4 4; }.chart-line.line-2 { stroke-dasharray: 2 4; }
.chart-labels text { fill: #8b95a7; font-size: 8px; }
.chart-legend { display: flex; gap: 15px; margin: -2px 0 5px; color: var(--muted); font-size: 9px; }
.chart-legend span { display: flex; align-items: center; gap: 5px; }
.chart-legend i { width: 13px; height: 2px; background: var(--dot); }
.donut-chart { width: var(--size); flex: 0 0 var(--size); }
.donut-chart svg { width: 100%; }
.donut-value { font-size: 19px; font-weight: 800; fill: var(--text); }
.donut-caption { font-size: 8px; fill: var(--muted); }
.bar-list { display: grid; gap: 9px; }
.bar-row { display: grid; grid-template-columns: minmax(70px,.8fr) minmax(70px,1.3fr) 44px; align-items: center; gap: 8px; font-size: 9.5px; }
.bar-track { height: 6px; border-radius: 99px; background: var(--surface-muted); overflow: hidden; }
.bar-track i { display: block; height: 100%; background: var(--bar); border-radius: inherit; }
.bar-row strong { font-size: 9px; text-align: right; }
.sparkline { width: 54px; height: 20px; }
.heatmap { display: grid; grid-template-columns: repeat(var(--cols),1fr); gap: 3px; }
.heatmap i { aspect-ratio: 1.1; border-radius: 2px; background: color-mix(in srgb, #5b5ce2 calc(var(--heat)*100%), #f0efff); }
.funnel { display: flex; flex-direction: column; align-items: center; gap: 3px; margin: 8px 0; }
.funnel div { min-height: 32px; padding: 0 10px; display: flex; align-items: center; justify-content: space-between; color: #29345b; font-size: 9px; background: linear-gradient(90deg,#e7e6ff,#c5c8ff); clip-path: polygon(7% 0,93% 0,100% 100%,0 100%); }
.funnel div:nth-child(2){background:linear-gradient(90deg,#dcdcff,#b8c0ff)}.funnel div:nth-child(3){background:linear-gradient(90deg,#d1d5ff,#abb6fc)}.funnel div:nth-child(4){background:linear-gradient(90deg,#c5ceff,#9ca9f9)}.funnel div:nth-child(5){background:linear-gradient(90deg,#b7c4ff,#8e9bf2)}
.pill-list, .destination-chips { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.pill { display: inline-flex; padding: 5px 8px; border-radius: 7px; background: var(--surface-muted); color: var(--text-soft); font-size: 9px; }
.divider { height: 1px; background: var(--border); margin: 12px 0; }
.empty-state { min-height: 180px; display: grid; place-items: center; align-content: center; text-align: center; color: var(--muted); }
.empty-state.compact { min-height: 70px; }
.empty-state h3 { margin: 7px 0 3px; color: var(--text); }.empty-state p { margin: 0; font-size: 11px; }
.state-block { min-height: 170px; display: grid; place-items: center; align-content: center; gap: 2px; text-align: center; padding: 22px 16px; color: var(--muted); }
.state-block h3 { margin: 8px 0 3px; color: var(--text); font-size: 12.5px; }
.state-block p { margin: 0; max-width: 460px; font-size: 10px; line-height: 1.6; }
.state-block .state-request-id { margin-top: 5px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 8.5px; color: var(--muted); }
.state-block .state-actions { margin-top: 11px; display: flex; gap: 7px; flex-wrap: wrap; justify-content: center; }
.state-block.error-state { color: var(--muted); }
.skeleton-stack { display: flex; flex-direction: column; gap: 8px; padding: 12px 2px; }
.skeleton-line { display: block; width: 100%; border-radius: 7px; background: linear-gradient(90deg, var(--surface-muted) 25%, var(--surface-subtle) 37%, var(--surface-muted) 63%); background-size: 400% 100%; animation: skeleton-sweep 1.25s ease-in-out infinite; }
@keyframes skeleton-sweep { 0% { background-position: 100% 50%; } 100% { background-position: 0 50%; } }
@media (prefers-reduced-motion: reduce) { .skeleton-line { animation: none; opacity: .7; } }
.sample-notice { margin-bottom: 12px; }
.live-chip { display: inline-flex; align-items: center; gap: 5px; padding: 3px 8px; border-radius: 999px; font-size: 8.5px; font-weight: 700; background: var(--surface-muted); color: var(--text-soft); }
.live-chip.live { background: rgba(18,167,107,.12); color: #0d7d50; }
.live-chip.sample { background: rgba(242,154,46,.14); color: #9a5f08; }
.data-table, .generic-table, .metric-table { min-width: 0; }
.table-row, .generic-table > div, .metric-table > div { display: grid; align-items: center; gap: 10px; border-bottom: 1px solid var(--border); min-height: 48px; padding: 7px 4px; font-size: 9.5px; }
.table-row { width: 100%; text-align: left; border-left: 0; border-right: 0; border-top: 0; background: white; cursor: pointer; }
.table-row:hover, .table-row.selected { background: var(--primary-pale); }
.table-row.selected { box-shadow: inset 3px 0 var(--primary); }
.table-row.head, .generic-table .head, .metric-table .head { min-height: 34px; color: var(--muted); font-weight: 720; background: var(--surface-subtle); }
.table-row small, .generic-table small, .metric-table small { display: block; margin-top: 2px; color: var(--muted); font-size: 8.5px; }
.account-cell { min-width: 0; display: flex; align-items: center; gap: 8px; }
.account-cell > span, .account-cell > div { min-width: 0; }
.account-cell strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.health-cell { display: flex; align-items: center; gap: 6px; }
.table-footer { min-height: 38px; display: flex; align-items: center; justify-content: space-between; gap: 12px; color: var(--muted); font-size: 9.5px; }
.pagination { display: flex; gap: 4px; }
.pagination button { min-width: 27px; height: 27px; border: 1px solid var(--border); border-radius: 7px; background: white; color: var(--muted); cursor: pointer; }
.pagination button.active { color: var(--primary); border-color: #bfc2f9; background: var(--primary-soft); }
.simple-list, .timeline, .check-list, .contact-info, .platform-contact-list, .prior-list, .quick-action-list { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; }
.simple-list > div, .timeline > div, .platform-contact-list > div, .prior-list > div { min-height: 43px; display: flex; align-items: center; gap: 9px; border-bottom: 1px solid var(--border); }
.simple-list span, .timeline span { flex: 1; min-width: 0; }.simple-list strong, .timeline strong { display: block; font-size: 10px; }.simple-list small, .timeline small { display: block; color: var(--muted); font-size: 8.5px; margin-top: 2px; }
.check-list li { min-height: 28px; display: flex; align-items: center; gap: 7px; font-size: 9.5px; color: var(--text-soft); }.check-list .icon { color: var(--green); }
.setting-line { min-height: 45px; display: flex; align-items: center; justify-content: space-between; gap: 10px; border-bottom: 1px solid var(--border); }
.setting-line span { display: grid; gap: 2px; }.setting-line strong { font-size: 10px; }.setting-line small { color: var(--muted); font-size: 8.5px; }
.copy-field { display: flex; align-items: center; border: 1px solid var(--border); border-radius: 8px; overflow: hidden; background: var(--surface-subtle); }
.copy-field input { min-width: 0; flex: 1; border: 0; background: transparent; padding: 9px; font-size: 9px; color: var(--muted); }
.copy-field button { width: 34px; height: 34px; border: 0; background: transparent; display: grid; place-items: center; cursor: pointer; }
.detail-header { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.detail-header h2 { margin: 0; font-size: 13px; }
.detail-tabs { display: flex; border-bottom: 1px solid var(--border); margin: 11px -14px 12px; padding: 0 14px; }
.detail-tabs button { min-height: 35px; padding: 0 12px; border: 0; border-bottom: 2px solid transparent; background: transparent; color: var(--muted); font-size: 10px; cursor: pointer; }
.detail-tabs button.active { color: var(--primary); border-color: var(--primary); }
.meta-list, .mini-dl, .detail-list { display: grid; gap: 0; margin: 0; }
.meta-list > div, .mini-dl > div, .detail-list > div { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; min-height: 31px; padding: 7px 0; border-bottom: 1px solid var(--border); }
.meta-list dt, .mini-dl dt, .detail-list dt { color: var(--muted); font-size: 9px; }.meta-list dd, .mini-dl dd, .detail-list dd { margin: 0; font-size: 9.5px; text-align: right; }
.person-row { min-height: 48px; display: flex; align-items: center; gap: 9px; border-bottom: 1px solid var(--border); }
.person-row > div { flex: 1; display: grid; gap: 2px; }.person-row strong { font-size: 10px; }.person-row span { color: var(--muted); font-size: 8.5px; }
.action-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 7px; margin-top: 11px; }
.button-row { display: flex; gap: 7px; flex-wrap: wrap; margin-top: 11px; }
.toast-stack { position: fixed; z-index: 120; right: 18px; bottom: 18px; width: min(370px,calc(100vw - 30px)); display: grid; gap: 8px; }
.toast { min-height: 66px; display: flex; align-items: center; gap: 10px; padding: 11px; background: white; border: 1px solid var(--border); border-left: 4px solid var(--primary); border-radius: 11px; box-shadow: var(--shadow-lg); animation: toast-in .22s ease-out; }
.toast.success { border-left-color: var(--green); }.toast.warning { border-left-color: var(--orange); }.toast.danger { border-left-color: var(--red); }
.toast-icon { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; color: var(--primary); background: var(--primary-soft); }
.toast.success .toast-icon { color: var(--green); background: var(--green-soft); }.toast.warning .toast-icon { color: var(--orange); background: var(--orange-soft); }.toast.danger .toast-icon { color: var(--red); background: var(--red-soft); }
.toast > div:nth-child(2) { flex: 1; }.toast strong { font-size: 11px; }.toast p { margin: 3px 0 0; color: var(--muted); font-size: 9.5px; }
@keyframes toast-in { from { opacity: 0; transform: translateY(12px); } }
.search-overlay { position: fixed; inset: 0; z-index: 110; background: rgba(17,24,39,.34); backdrop-filter: blur(3px); display: grid; place-items: start center; padding-top: 12vh; }
.command-palette { width: min(620px,92vw); border: 1px solid var(--border); border-radius: 15px; background: white; box-shadow: var(--shadow-lg); overflow: hidden; }
.command-palette > label { height: 54px; padding: 0 15px; display: flex; align-items: center; gap: 10px; border-bottom: 1px solid var(--border); }
.command-palette input { flex: 1; border: 0; outline: 0; font-size: 13px; }
.command-palette kbd, .command-item kbd { color: var(--muted); background: var(--surface-muted); border: 1px solid var(--border); border-radius: 5px; padding: 3px 5px; font-size: 9px; }
.command-section { padding: 8px; }.command-section > span { display: block; padding: 6px 8px; color: var(--muted); font-size: 9px; text-transform: uppercase; letter-spacing: .08em; }
.command-item { min-height: 48px; display: flex; align-items: center; gap: 10px; padding: 7px 9px; border-radius: 8px; }.command-item:hover,.command-item.active { background: var(--primary-soft); color: var(--primary-strong); }
.command-item > span { flex: 1; display: grid; gap: 2px; font-size: 11px; font-weight: 700; }.command-item small { color: var(--muted); font-size: 8.5px; font-weight: 500; }
.command-palette footer { min-height: 35px; display: flex; gap: 16px; align-items: center; padding: 0 13px; background: var(--surface-subtle); border-top: 1px solid var(--border); color: var(--muted); font-size: 8.5px; }
.workspace-popover { left: calc(var(--sidebar-width) + 20px); top: 56px; }.notifications-popover { right: 165px; top: 56px; width: 330px; }.user-popover { right: 14px; top: 56px; width: 230px; }
.popover-title { display: flex; justify-content: space-between; align-items: center; padding: 6px 8px 10px; }
.notification-item { width: 100%; min-height: 58px; padding: 8px; border: 0; border-radius: 8px; background: transparent; display: flex; align-items: center; gap: 9px; text-align: left; cursor: pointer; }.notification-item:hover { background: var(--surface-muted); }
.notification-item > span:nth-child(2) { flex: 1; display: grid; gap: 3px; }.notification-item strong { font-size: 10px; }.notification-item small { color: var(--muted); font-size: 8.5px; }.notification-item time { color: var(--muted); font-size: 8px; }
.user-card { display: flex; gap: 9px; align-items: center; padding: 9px; border-bottom: 1px solid var(--border); margin-bottom: 5px; }.user-card span:last-child { display: grid; gap: 2px; }.user-card strong { font-size: 10px; }.user-card small { color: var(--muted); font-size: 8.5px; }
.popover-item.danger { color: var(--red); }
