:root {
  color-scheme: dark;
  --pm2-app-bg: #111418;
  --pm2-canvas-bg: #ffffff;
  --pm2-canvas-line: #e4e8ee;
  --pm2-ink: #f6f8fa;
  --pm2-ink-soft: #c6ccd3;
  --pm2-muted: #88929d;
  --pm2-line: rgba(255, 255, 255, 0.1);
  --pm2-line-strong: rgba(255, 255, 255, 0.16);
  --pm2-accent: #67d98b;
  --pm2-accent-strong: #2fa869;
  --pm2-blue: #70b7ff;
  --pm2-shadow: 0 24px 80px rgba(0, 0, 0, 0.36);
  --pm2-shadow-soft: 0 14px 34px rgba(0, 0, 0, 0.24);
  --pm2-panel-width: 586px;
  --pm2-nav-width: 118px;
}

html,
body {
  width: 100%;
  min-width: 320px;
  min-height: 100%;
  margin: 0;
  overflow: hidden;
  background: var(--pm2-app-bg);
  color: var(--pm2-ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.material-symbols-rounded {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  font-family: "Material Symbols Rounded";
  font-size: 22px;
  font-weight: normal;
  font-style: normal;
  line-height: 1;
  letter-spacing: 0;
  text-transform: none;
  white-space: nowrap;
  direction: ltr;
  -webkit-font-feature-settings: "liga";
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "liga";
}

.pm2-shell {
  position: relative;
  width: 100vw;
  min-height: 100vh;
  background: var(--pm2-app-bg);
  color: var(--pm2-ink);
}

.pm2-stage-grid {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 36px 36px;
}

.pm2-top-panel {
  position: fixed;
  top: 18px;
  right: 18px;
  left: calc(var(--pm2-panel-width) + 42px);
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 72px;
  padding: 12px 14px;
  border: 1px solid var(--pm2-line);
  border-radius: 20px;
  background: rgba(23, 27, 33, 0.94);
  box-shadow: var(--pm2-shadow-soft);
  backdrop-filter: blur(22px);
  transition: left 390ms cubic-bezier(0.2, 0.82, 0.18, 1), background-color 220ms ease, border-color 220ms ease;
}

.pm2-project-title {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 13px;
}

.pm2-project-title > .material-symbols-rounded,
.pm2-brand-mark {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: #23312a;
  color: var(--pm2-accent);
}

.pm2-project-title p,
.pm2-brand-lockup p,
.pm2-screen-heading p {
  margin: 0 0 4px;
  color: var(--pm2-muted);
  font-size: 11px;
  font-weight: 760;
  line-height: 1.15;
  text-transform: uppercase;
}

.pm2-project-title h1,
.pm2-screen-heading h2 {
  overflow: hidden;
  margin: 0;
  color: var(--pm2-ink);
  font-size: 20px;
  font-weight: 760;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pm2-top-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.pm2-icon-button,
.pm2-action-button,
.pm2-feature-item,
.pm2-tool,
.pm2-task-list button {
  border: 0;
  cursor: pointer;
  font: inherit;
  -webkit-tap-highlight-color: transparent;
}

.pm2-icon-button {
  display: inline-grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid var(--pm2-line);
  border-radius: 13px;
  background: #1f242c;
  color: var(--pm2-ink-soft);
  transition: transform 170ms ease, background-color 170ms ease, border-color 170ms ease, color 170ms ease;
}

.pm2-icon-button:hover,
.pm2-tool:hover {
  transform: translateY(-1px);
  border-color: var(--pm2-line-strong);
  background: #28303a;
  color: #fff;
}

.pm2-icon-button:active,
.pm2-action-button:active,
.pm2-feature-item:active,
.pm2-tool:active {
  transform: translateY(1px) scale(0.98);
}

.pm2-top-panel-toggle {
  width: 0;
  margin-right: -18px;
  opacity: 0;
  pointer-events: none;
  transform: translateX(-8px);
  transition: width 250ms ease, margin 250ms ease, opacity 180ms ease, transform 250ms ease;
}

.pm2-action-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 15px;
  gap: 8px;
  border-radius: 13px;
  color: var(--pm2-ink);
  font-weight: 720;
  transition: transform 170ms ease, background-color 170ms ease, box-shadow 170ms ease;
}

.pm2-action-button.secondary {
  border: 1px solid var(--pm2-line);
  background: #242a33;
  color: var(--pm2-ink-soft);
}

.pm2-action-button.primary {
  background: var(--pm2-accent-strong);
  color: #fff;
  box-shadow: 0 12px 28px rgba(47, 168, 105, 0.22);
}

.pm2-action-button:hover {
  transform: translateY(-1px);
}

.pm2-side-panel {
  position: fixed;
  top: 18px;
  bottom: 18px;
  left: 18px;
  z-index: 30;
  display: flex;
  width: var(--pm2-panel-width);
  min-height: 560px;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--pm2-line);
  border-radius: 22px;
  background: rgba(16, 19, 24, 0.96);
  box-shadow: var(--pm2-shadow);
  backdrop-filter: blur(28px);
  transform: translateX(0);
  transition: transform 420ms cubic-bezier(0.2, 0.82, 0.18, 1), opacity 280ms ease, filter 280ms ease;
  will-change: transform;
}

.pm2-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px;
  border-bottom: 1px solid var(--pm2-line);
  background: #15191f;
}

.pm2-brand-lockup {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 12px;
}

.pm2-brand-lockup p {
  color: var(--pm2-ink);
  font-size: 13px;
  text-transform: none;
  white-space: nowrap;
}

.pm2-brand-lockup span:not(.material-symbols-rounded) {
  display: block;
  overflow: hidden;
  color: var(--pm2-muted);
  font-size: 13px;
  font-weight: 620;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pm2-panel-body {
  display: grid;
  min-height: 0;
  flex: 1;
  grid-template-columns: var(--pm2-nav-width) minmax(0, 1fr);
  gap: 14px;
  padding: 14px;
}

.pm2-feature-nav {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 4px;
  padding: 5px 0;
}

.pm2-feature-item {
  display: grid;
  width: 100%;
  min-height: 72px;
  place-items: center;
  gap: 6px;
  border-radius: 14px;
  background: transparent;
  color: var(--pm2-muted);
  transition: transform 170ms ease, color 170ms ease, background-color 170ms ease;
}

.pm2-feature-item:hover {
  transform: translateX(2px);
  background: rgba(255, 255, 255, 0.04);
  color: var(--pm2-ink);
}

.pm2-feature-item .material-symbols-rounded {
  font-size: 25px;
}

.pm2-feature-item span:last-child {
  overflow: hidden;
  max-width: 100%;
  padding: 0 4px;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.1;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pm2-feature-item.is-active {
  background: transparent;
  color: var(--pm2-accent);
}

.pm2-feature-item.is-active::after {
  width: 28px;
  height: 3px;
  border-radius: 999px;
  background: var(--pm2-accent);
  content: "";
}

.pm2-feature-screen {
  display: flex;
  min-width: 0;
  min-height: 0;
  flex-direction: column;
  gap: 14px;
  overflow: auto;
  padding: 16px;
  border: 1px solid var(--pm2-line);
  border-radius: 18px;
  background: #1a1f26;
}

.pm2-screen-heading {
  display: flex;
  align-items: center;
  gap: 12px;
}

.pm2-screen-heading > .material-symbols-rounded {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: #1f3445;
  color: var(--pm2-blue);
}

.pm2-metric-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.pm2-metric-row article {
  min-width: 0;
  padding: 13px;
  border: 1px solid var(--pm2-line);
  border-radius: 14px;
  background: #14191f;
}

.pm2-metric-row span {
  display: block;
  color: var(--pm2-muted);
  font-size: 11px;
  font-weight: 760;
  text-transform: uppercase;
}

.pm2-metric-row strong {
  display: block;
  margin-top: 5px;
  color: var(--pm2-ink);
  font-size: 28px;
  line-height: 1;
}

.pm2-task-list {
  display: grid;
  gap: 8px;
}

.pm2-task-list button {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  min-height: 44px;
  padding: 0 11px;
  gap: 9px;
  border: 1px solid var(--pm2-line);
  border-radius: 12px;
  background: #14191f;
  color: var(--pm2-ink-soft);
  font-size: 13px;
  font-weight: 650;
  text-align: left;
  transition: background-color 170ms ease, color 170ms ease, transform 170ms ease;
}

.pm2-task-list button:hover {
  transform: translateX(2px);
  background: #202630;
  color: var(--pm2-ink);
}

.pm2-canvas-board {
  position: absolute;
  inset: 112px 18px 18px calc(var(--pm2-panel-width) + 42px);
  display: grid;
  overflow: hidden;
  border: 1px solid #dfe4ea;
  border-radius: 22px;
  background:
    linear-gradient(90deg, rgba(31, 45, 61, 0.045) 1px, transparent 1px),
    linear-gradient(rgba(31, 45, 61, 0.045) 1px, transparent 1px),
    var(--pm2-canvas-bg);
  background-size: 28px 28px;
  box-shadow: 0 20px 70px rgba(0, 0, 0, 0.24);
  transition: inset 420ms cubic-bezier(0.2, 0.82, 0.18, 1), border-radius 260ms ease;
}

.pm2-canvas-label {
  position: absolute;
  top: 22px;
  left: 22px;
  z-index: 2;
  display: inline-flex;
  min-height: 34px;
  align-items: center;
  padding: 0 13px;
  border: 1px solid var(--pm2-canvas-line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.86);
  color: #2a3340;
  font-size: 13px;
  font-weight: 760;
  box-shadow: 0 10px 26px rgba(28, 37, 47, 0.08);
}

.pm2-canvas-toolbar {
  position: absolute;
  top: 20px;
  right: 20px;
  z-index: 2;
  display: flex;
  gap: 7px;
  padding: 7px;
  border: 1px solid var(--pm2-canvas-line);
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 12px 28px rgba(28, 37, 47, 0.1);
  backdrop-filter: blur(18px);
}

.pm2-tool {
  display: grid;
  width: 39px;
  height: 39px;
  place-items: center;
  border-radius: 11px;
  background: transparent;
  color: #566273;
  transition: transform 170ms ease, background-color 170ms ease, color 170ms ease;
}

.pm2-tool:hover {
  background: #eef2f6;
  color: #1f2937;
}

.pm2-tool.is-active {
  background: #1f2937;
  color: #fff;
}

.pm2-blazor-surface {
  position: absolute;
  inset: 72px 18px 18px;
  overflow: auto;
  border: 1px solid rgba(31, 45, 61, 0.08);
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.72);
  color: #17202b;
}

.pm2-shell[data-panel-state="closed"] .pm2-side-panel {
  opacity: 0;
  filter: blur(2px);
  transform: translateX(calc((var(--pm2-panel-width) + 34px) * -1));
  pointer-events: none;
}

.pm2-shell[data-panel-state="closed"] .pm2-top-panel {
  left: 18px;
}

.pm2-shell[data-panel-state="closed"] .pm2-top-panel-toggle {
  width: 42px;
  margin-right: 0;
  opacity: 1;
  pointer-events: auto;
  transform: translateX(0);
}

.pm2-shell[data-panel-state="closed"] .pm2-canvas-board {
  left: 18px;
}

@media (max-width: 1120px) {
  :root {
    --pm2-panel-width: min(548px, calc(100vw - 36px));
    --pm2-nav-width: 104px;
  }

  body {
    overflow: auto;
  }

  .pm2-shell {
    min-height: 880px;
  }

  .pm2-top-panel {
    right: 14px;
    left: 14px;
    top: 14px;
  }

  .pm2-side-panel {
    top: 100px;
    bottom: 14px;
    left: 14px;
    width: var(--pm2-panel-width);
    min-height: 0;
  }

  .pm2-canvas-board {
    inset: 224px 14px 18px 14px;
  }

  .pm2-shell[data-panel-state="closed"] .pm2-top-panel,
  .pm2-shell[data-panel-state="closed"] .pm2-canvas-board {
    left: 14px;
  }
}

@media (max-width: 680px) {
  .pm2-top-panel {
    align-items: stretch;
    flex-direction: column;
    gap: 12px;
  }

  .pm2-project-title h1 {
    max-width: 70vw;
    font-size: 18px;
  }

  .pm2-top-actions {
    width: 100%;
    justify-content: space-between;
  }

  .pm2-action-button {
    width: 42px;
    padding: 0;
    font-size: 0;
  }

  .pm2-action-button .material-symbols-rounded {
    font-size: 22px;
  }

  .pm2-panel-body {
    grid-template-columns: 82px minmax(0, 1fr);
    gap: 10px;
    padding: 10px;
  }

  .pm2-feature-item {
    min-height: 62px;
  }

  .pm2-feature-item span:last-child {
    font-size: 10px;
  }

  .pm2-feature-screen {
    padding: 12px;
  }

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

  .pm2-canvas-board {
    top: 246px;
  }

  .pm2-shell[data-panel-state="closed"] .pm2-canvas-board {
    top: 176px;
  }

  .pm2-canvas-toolbar {
    top: auto;
    right: 14px;
    bottom: 14px;
    left: 14px;
    justify-content: space-between;
  }

  .pm2-blazor-surface {
    inset: 72px 12px 72px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 1ms !important;
    animation-duration: 1ms !important;
  }
}
