.fm-workspace {
  min-height: 100vh;
  overflow-x: hidden;
  background: #09090b;
  color: #f5f3ef;
}

.fm-workspace .shell { display: flex; min-height: 100vh; }
.fm-workspace .sidebar { z-index: 100; }
.fm-workspace .sidebar-menu { display: flex; min-height: 0; flex: 1; flex-direction: column; }
.fm-workspace .fm-system-links { margin-top: auto; }
.fm-workspace .sidebar-menu .nav-btn { text-decoration: none; }
.fm-workspace .sidebar-menu .nav-btn svg,
.fm-workspace .dashboard-topbar svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.fm-beta-label,
.fm-top-beta {
  display: inline-flex;
  align-items: center;
  min-height: 18px;
  margin-left: 7px;
  padding: 0 6px;
  border: 1px solid rgba(242, 138, 60, .24);
  border-radius: 3px;
  color: #f28a3c;
  font: 750 7px/1 Outfit, Manrope, sans-serif;
  letter-spacing: .1em;
}

.fm-sidebar-count {
  margin-left: auto;
  padding: 3px 6px;
  border-radius: 99px;
  background: rgba(255, 255, 255, .06);
  color: #aaa;
  font-size: 8px;
}

.fm-workspace .dashboard-body { min-width: 0; flex: 1; }
.fm-workspace .dashboard-topbar { position: sticky; top: 0; z-index: 50; }
.fm-workspace .topbar-left,
.fm-workspace .topbar-right { display: flex; align-items: center; gap: 9px; }
.fm-workspace .topbar-icon-btn { display: grid; place-items: center; text-decoration: none; }
.fm-workspace .topbar-icon-btn:disabled { opacity: .42; cursor: wait; }
.fm-workspace .topbar-icon-btn.is-loading svg { animation: fm-spin .85s linear infinite; }
@keyframes fm-spin { to { transform: rotate(360deg); } }
.fm-top-popover-wrap { position: relative; }
.fm-top-dot { position: absolute; top: -5px; right: -5px; min-width: 16px; height: 16px; display: grid; place-items: center; padding: 0 4px; border-radius: 9px; background: #ef6a62; color: #fff; font: 800 8px/1 Manrope,sans-serif; }
.fm-top-dot[hidden] { display: none !important; }
.fm-top-popover { position: absolute; z-index: 80; top: calc(100% + 10px); right: 0; width: 320px; max-height: 410px; overflow: auto; padding: 10px; border: 1px solid rgba(255,255,255,.08); border-radius: 6px; background: #141418; box-shadow: 0 22px 65px rgba(0,0,0,.55); }
.fm-top-popover[hidden] { display: none; }
.fm-top-popover-head { display: flex; align-items: center; justify-content: space-between; padding: 7px 7px 12px; border-bottom: 1px solid rgba(255,255,255,.06); }
.fm-top-popover-head strong { font-size: 12px; }.fm-top-popover-head span { color: #777780; font-size: 9px; }
.fm-health-row { display: grid; grid-template-columns: 8px 1fr; align-items: start; gap: 9px; padding: 9px 7px; }.fm-health-row>i { width: 6px; height: 6px; margin-top: 4px; border-radius: 50%; background: #72d897; }.fm-health-row.fail>i { background: #ef6a62; }.fm-health-row b,.fm-health-row small { display: block; }.fm-health-row b { color: #ddd; font-size: 10px; }.fm-health-row small { overflow: hidden; margin-top: 3px; color: #65656d; font-size: 8px; text-overflow: ellipsis; white-space: nowrap; }
.fm-top-account {
  overflow: hidden;
  max-width: 180px;
  color: rgba(255, 255, 255, .52);
  font: 650 11px/1 Manrope, sans-serif;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.fm-workspace .dashboard-content { width: 100%; max-width: none; }
.fm-workspace .dashboard-content > section#home.page.active { display: block !important; width: 100%; max-width: none; }
.fm-workspace .fm-main {
  min-height: auto;
  margin: 0;
  padding: 4px 0 60px;
}
.fm-workspace .fm-topbar { margin-top: 26px; }
.fm-workspace .fm-monitor-grid { align-items: stretch; }
.fm-workspace .fm-stats-panel,
.fm-workspace .fm-tuning-panel { height: auto; }
.fm-workspace .fm-source-groups { align-items: start; }
.fm-workspace .fm-source-column { min-width: 0; }
.fm-workspace .fm-source-column h4 { min-height: 20px; }
.fm-workspace .fm-source-column.is-telegram { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; }
.fm-workspace .fm-source-column.is-telegram h4 { grid-column: 1 / -1; margin-bottom: 0; }
.fm-workspace .fm-orders-layout { height: calc(100dvh - 318px); min-height: 540px; }
.fm-workspace .fm-orders-list { min-height: 0; }
.fm-workspace .fm-order-detail { top: 88px; height: 100%; }
.fm-live.busy i { background: #f28a3c; animation-duration: .8s; }
.fm-guide-overlay { position: fixed; z-index: 90000; inset: 0; display: grid; place-items: center; padding: 18px; background: rgba(0,0,0,.78); backdrop-filter: blur(8px); }.fm-guide-overlay[hidden] { display: none; }.fm-guide-panel { position: relative; width: min(560px,100%); padding: 30px; border: 1px solid rgba(242,138,60,.22); border-radius: 8px; background: #121216; box-shadow: 0 30px 90px rgba(0,0,0,.65); }.fm-guide-panel>button { position: absolute; top: 14px; right: 14px; width: 34px; height: 34px; border: 1px solid rgba(255,255,255,.08); border-radius: 4px; background: #1a1a1f; color: #aaa; font-size: 20px; cursor: pointer; }.fm-guide-panel>span { color: #f28a3c; font: 800 8px/1 Manrope,sans-serif; letter-spacing: .14em; }.fm-guide-panel h2 { margin: 8px 0 24px; font: 700 26px/1.1 Onest,sans-serif; }.fm-guide-panel ol { display: grid; gap: 9px; margin: 0; padding: 0; list-style: none; counter-reset: guide; }.fm-guide-panel li { counter-increment: guide; display: grid; grid-template-columns: 34px 1fr; gap: 11px; padding: 13px; border: 1px solid rgba(255,255,255,.06); border-radius: 5px; background: #0e0e12; }.fm-guide-panel li:before { content: '0' counter(guide); grid-row: 1/3; color: #f28a3c; font: 800 10px/1.4 Manrope,sans-serif; }.fm-guide-panel li b,.fm-guide-panel li small { grid-column: 2; }.fm-guide-panel li b { font-size: 12px; }.fm-guide-panel li small { color: #74747c; font-size: 9px; }

@media (max-width: 820px) {
  .fm-workspace .sidebar {
    position: fixed !important;
    top: 0 !important;
    bottom: 0 !important;
    left: 0 !important;
    width: min(310px, 86vw) !important;
    height: 100dvh !important;
    transform: translateX(-105%);
    transition: transform .2s ease;
  }
  body.fm-workspace.mobile-menu-open .sidebar { transform: translateX(0) !important; }
  .fm-workspace .mobile-nav-backdrop { display: none; }
  .fm-workspace.mobile-menu-open .mobile-nav-backdrop { display: block; }
  .fm-workspace .dashboard-body { width: 100%; margin-left: 0; }
  .fm-workspace .dashboard-content { padding: 14px 12px 45px !important; }
  .fm-top-account { display: none; }
  .fm-workspace .fm-topbar { margin-top: 14px; }
  .fm-workspace .fm-source-column.is-telegram { grid-template-columns: 1fr; }
  .fm-workspace .fm-orders-layout { height: auto; min-height: 0; }
  .fm-workspace .fm-order-detail { height: auto; }
}
