/* Палитра и базовые элементы — те же токены, что в userway: game-bot её сосед
   по команде, панели должны читаться как одна семья инструментов. */
:root {
  --bg: #0f1116;
  --panel: #161922;
  --panel-2: #1d212c;
  --line: #272c39;
  --text: #e6e8ee;
  --muted: #8b93a7;
  --accent: #6d5efc;
  --accent-2: #8b7dff;
  --blocker: #ff5a5a;
  --major: #ffa53d;
  --minor: #4dd4ac;
  --idea: #58a6ff;
  --radius: 12px;
}

* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 14px/1.5 -apple-system, "Segoe UI", Roboto, Inter, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.hidden {
  display: none !important;
}

.muted {
  color: var(--muted);
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

input,
select,
textarea {
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 9px 11px;
  outline: none;
  width: 100%;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent);
}

textarea {
  resize: vertical;
  font-family: inherit;
}

.btn {
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 8px 14px;
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
  color: var(--text);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.btn:hover:not(:disabled) {
  border-color: #3a4157;
  background: #232838;
}

.btn:disabled {
  opacity: 0.45;
  cursor: default;
}

.btn.primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  font-weight: 600;
}

.btn.primary:hover:not(:disabled) {
  background: var(--accent-2);
  border-color: var(--accent-2);
}

.btn.ghost {
  background: transparent;
}

.btn.danger {
  color: var(--blocker);
  border-color: rgba(255, 90, 90, 0.35);
  background: transparent;
}

.btn.danger:hover:not(:disabled) {
  background: rgba(255, 90, 90, 0.12);
  border-color: var(--blocker);
}

.icon {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--muted);
  border-radius: 7px;
  width: 24px;
  height: 24px;
  line-height: 1;
  cursor: pointer;
  padding: 0;
}

.icon:hover:not(:disabled) {
  color: var(--text);
  border-color: var(--accent);
}

/* --- каркас --- */
.app {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.topbar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
  background: var(--panel);
  flex: none;
}

.brand {
  font-weight: 700;
  letter-spacing: -0.3px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 12px var(--accent);
  flex: none;
  display: inline-block;
}

.crumbs {
  color: var(--muted);
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.spacer {
  flex: 1;
}

.main {
  flex: 1;
  overflow-y: auto;
  padding: 18px;
  display: flex;
  flex-direction: column;
}

.view {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 1180px;
  width: 100%;
  margin: 0 auto;
}

/* --- полоса ошибки --- */
.error-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  background: rgba(255, 90, 90, 0.12);
  border-bottom: 1px solid rgba(255, 90, 90, 0.4);
  color: #ffb3b3;
  flex: none;
}

/* --- заголовки секций --- */
.section-head {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-top: 6px;
}

.section-head.mt {
  margin-top: 22px;
}

.section-head h2 {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--muted);
  margin: 0;
  font-weight: 600;
}

/* --- плитка проектов --- */
.tiles {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 12px;
}

.project-card {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px;
  display: grid;
  gap: 6px;
  align-content: start;
  cursor: pointer;
}

/* --- значки проверок на карточке проекта: без текста, только точка с числом --- */
.project-check-badges {
  position: absolute;
  top: 10px;
  right: 10px;
  display: flex;
  gap: 4px;
}

.check-badge {
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 20px;
  font-size: 10.5px;
  font-weight: 700;
  line-height: 18px;
  text-align: center;
}

.check-badge-error {
  background: var(--blocker);
  color: #fff;
}

.check-badge-warning {
  background: var(--major);
  color: #1a1200;
}

.project-card:hover {
  border-color: #3a4157;
}

.project-name {
  font-weight: 600;
  font-size: 15px;
}

.project-pkg {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  font-size: 11.5px;
}

.project-builds {
  font-size: 12.5px;
  margin-top: 2px;
}

.project-actions {
  display: flex;
  gap: 8px;
  margin-top: 6px;
  flex-wrap: wrap;
}

.link-btn {
  background: none;
  border: none;
  padding: 0;
  color: var(--accent-2);
  cursor: pointer;
  font: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.link-btn:hover {
  color: var(--text);
}

/* --- раннеры --- */
.runners {
  display: grid;
  gap: 6px;
}

.runner-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 9px 12px;
  font-size: 13px;
}

.runner-row .dot {
  width: 8px;
  height: 8px;
  box-shadow: none;
}

.dot-on {
  background: var(--minor);
}

.dot-off {
  background: var(--blocker);
}

.runner-name {
  font-weight: 600;
}

.runner-state {
  margin-left: auto;
}

.runner-devices {
  flex-basis: 100%;
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.device-chip {
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 3px 10px;
  font-size: 11.5px;
  color: var(--muted);
}

/* --- лента прогонов --- */
.runs-feed {
  display: grid;
  gap: 8px;
}

.run-row {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 3px solid var(--line);
  border-radius: var(--radius);
  padding: 11px 14px;
  cursor: pointer;
}

.run-row:hover {
  border-color: #3a4157;
}

.run-row.running {
  border-left-color: var(--accent);
}

.run-row.stale {
  border-left-color: var(--major);
}

.run-row.done {
  border-left-color: var(--minor);
}

.run-row.failed {
  border-left-color: var(--blocker);
}

.run-row.stopped {
  border-left-color: var(--muted);
}

.run-row.queued {
  border-left-color: var(--idea);
}

.run-row-stats .queued-reason {
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--idea);
}

.run-row-main {
  min-width: 0;
  flex: 1 1 260px;
  display: grid;
  gap: 2px;
}

.run-row-title {
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Метка проекта в общей ленте — тот же текст, что и раньше был просто заголовком строки,
   но теперь ведёт на страницу проекта. Выглядит как обычный текст, подчёркивание — только
   при наведении, чтобы не пестрить: кликабельность тут не главная функция строки. */
.run-row-project-link {
  display: inline-block;
  max-width: 100%;
  background: none;
  border: none;
  margin: 0;
  padding: 0;
  font: inherit;
  font-weight: inherit;
  color: inherit;
  text-align: left;
  cursor: pointer;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  vertical-align: bottom;
}

.run-row-project-link:hover {
  color: var(--accent-2);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.run-row-device,
.run-row-focus {
  font-size: 12px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.run-row-stats {
  display: flex;
  gap: 14px;
  font-size: 12px;
  flex: none;
}

.run-row-stats span {
  white-space: nowrap;
}

/* Узкое окно: в одну строку название игры, статистика и бейдж не помещаются —
   не мельчим им шрифт, а переносим на отдельные строки. */
@media (max-width: 640px) {
  .run-row {
    flex-wrap: wrap;
  }

  .run-row-main {
    flex-basis: 100%;
  }

  .run-row-title {
    white-space: normal;
  }

  .run-row-stats {
    flex-basis: 100%;
    justify-content: space-between;
  }
}

/* --- статус-бейджи --- */
.status-badge {
  border-radius: 20px;
  padding: 3px 11px;
  font-size: 12px;
  border: 1px solid var(--line);
  background: var(--panel-2);
  color: var(--muted);
  white-space: nowrap;
  flex: none;
}

.status-badge.state-running {
  color: var(--accent-2);
  border-color: var(--accent);
  background: rgba(109, 94, 252, 0.16);
}

.status-badge.state-running::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  margin-right: 6px;
  animation: pulse 1.4s ease-in-out infinite;
}

.status-badge.state-stale {
  color: var(--major);
  border-color: rgba(255, 165, 61, 0.4);
  background: rgba(255, 165, 61, 0.14);
}

.status-badge.state-done {
  color: var(--minor);
  border-color: rgba(77, 212, 172, 0.4);
  background: rgba(77, 212, 172, 0.14);
}

.status-badge.state-failed {
  color: var(--blocker);
  border-color: rgba(255, 90, 90, 0.4);
  background: rgba(255, 90, 90, 0.14);
}

.status-badge.state-stopped {
  color: var(--muted);
}

.status-badge.state-queued {
  color: var(--idea);
  border-color: rgba(88, 166, 255, 0.4);
  background: rgba(88, 166, 255, 0.14);
}

@keyframes pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.25;
  }
}

/* --- карточка прогона --- */
.back-link {
  color: var(--muted);
  text-decoration: none;
  font-size: 13px;
}

.back-link:hover {
  color: var(--text);
}

.run-head {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 4px;
}

.run-title h2 {
  margin: 0 0 2px;
}

.run-head-right {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.run-timer {
  font-variant-numeric: tabular-nums;
  font-size: 15px;
  min-width: 3ch;
}

.run-focus {
  font-size: 13px;
}

.task-details {
  font-size: 13px;
  color: var(--muted);
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 8px 12px;
}

.task-details summary {
  cursor: pointer;
  user-select: none;
}

.task-details .md {
  margin-top: 8px;
}

/* --- прогон в очереди: вместо лога/снимков/находок — объяснение, чего он ждёт --- */
.queued-panel {
  display: none;
  align-items: center;
  gap: 14px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  margin-top: 4px;
}

.queued-icon {
  font-size: 28px;
  flex: none;
}

.queued-text p {
  margin: 4px 0 0;
}

#view-run.is-queued .queued-panel {
  display: flex;
}

#view-run.is-queued .task-details,
#view-run.is-queued .run-grid,
#view-run.is-queued .run-lower {
  display: none;
}

/* --- лог + снимок --- */
.run-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 14px;
  align-items: start;
  margin-top: 4px;
}

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

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.7px;
  color: var(--muted);
  margin-bottom: 8px;
}

.autoscroll {
  display: flex;
  align-items: center;
  gap: 5px;
  text-transform: none;
  letter-spacing: 0;
  cursor: pointer;
}

.autoscroll input {
  width: auto;
}

.log-box {
  background: #0b0d12;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px 12px;
  height: 420px;
  overflow-y: auto;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  font-size: 12.5px;
  line-height: 1.55;
}

.log-line {
  white-space: pre-wrap;
  word-break: break-word;
  color: #c3c9d8;
}

.log-line:not(:last-child) {
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.shot-big {
  background: #000;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  height: 420px;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.shot-big img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  cursor: zoom-in;
}

.shot-strip {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.thumb {
  position: relative;
  width: 88px;
  height: 62px;
  border-radius: 7px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #000;
  cursor: zoom-in;
  flex: none;
}

.thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* --- находки и оракулы --- */
.run-lower {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 14px;
  margin-top: 6px;
}

@media (max-width: 900px) {
  .run-lower {
    grid-template-columns: 1fr;
  }
}

.findings {
  display: grid;
  gap: 10px;
}

.finding {
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 3px solid var(--line);
  border-radius: var(--radius);
  padding: 11px 13px;
  display: grid;
  gap: 6px;
}

.finding.sev-blocker {
  border-left-color: var(--blocker);
}

.finding.sev-major {
  border-left-color: var(--major);
}

.finding.sev-minor {
  border-left-color: var(--minor);
}

.finding.sev-idea {
  border-left-color: var(--idea);
}

.finding-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.finding-title {
  font-weight: 600;
}

.finding-body {
  font-size: 13px;
  color: #c3c9d8;
}

.finding-note {
  font-size: 13px;
  color: #c3c9d8;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 11px 13px;
}

.tag {
  border-radius: 20px;
  padding: 2px 9px;
  font-size: 11px;
  border: 1px solid var(--line);
  background: var(--panel-2);
  color: var(--muted);
  flex: none;
}

.tag.sev-blocker {
  color: var(--blocker);
  border-color: rgba(255, 90, 90, 0.4);
}

.tag.sev-major {
  color: var(--major);
  border-color: rgba(255, 165, 61, 0.4);
}

.tag.sev-minor {
  color: var(--minor);
  border-color: rgba(77, 212, 172, 0.4);
}

.tag.sev-idea {
  color: var(--idea);
  border-color: rgba(88, 166, 255, 0.4);
}

.oracles {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px 13px;
  display: grid;
  gap: 10px;
}

.oracle-row {
  display: grid;
  grid-template-columns: 84px 1fr;
  gap: 10px;
  font-size: 12.5px;
  align-items: start;
}

.oracle-key {
  color: var(--muted);
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: 0.6px;
  padding-top: 2px;
}

.oracle-val ul {
  margin: 0;
  padding-left: 16px;
}

/* --- минимальный рендер markdown (задание, находки) --- */
.md h4,
.md h5,
.finding-body h4,
.finding-body h5 {
  margin: 0 0 4px;
  font-size: 13px;
  color: var(--text);
}

.md p,
.finding-body p {
  margin: 0 0 6px;
}

.md ul,
.finding-body ul {
  margin: 0 0 6px;
  padding-left: 18px;
}

.md code,
.finding-body code {
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 1px 5px;
  font-family: Consolas, Menlo, monospace;
  font-size: 12px;
}

/* --- панель запуска прогона (тот же слайд-ин, что в userway) --- */
.drawer-back {
  position: fixed;
  inset: 0;
  background: rgba(6, 7, 11, 0.62);
  backdrop-filter: blur(2px);
  z-index: 55;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.drawer-back.open {
  opacity: 1;
  visibility: visible;
}

.drawer {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: min(460px, 100vw);
  background: var(--panel);
  border-right: 1px solid var(--line);
  box-shadow: 26px 0 70px rgba(0, 0, 0, 0.55);
  z-index: 60;
  display: flex;
  flex-direction: column;
  transform: translateX(-101%);
  visibility: hidden;
  transition: transform 0.24s cubic-bezier(0.2, 0.8, 0.2, 1), visibility 0.24s;
}

.drawer.open {
  transform: none;
  visibility: visible;
}

.drawer-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  flex: none;
}

.drawer-title {
  font-size: 16px;
  font-weight: 600;
  flex: 1;
}

.drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 18px;
  display: grid;
  gap: 16px;
  align-content: start;
}

.drawer-foot {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 18px;
  border-top: 1px solid var(--line);
  background: var(--panel-2);
  flex: none;
}

.drawer-game {
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 9px 11px;
}

.field {
  display: grid;
  gap: 7px;
}

.field > span {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--muted);
}

.field .hint {
  font-size: 11.5px;
  text-transform: none;
  letter-spacing: 0;
}

.form-error {
  min-height: 18px;
  color: var(--blocker);
  font-size: 13px;
}

/* --- прогресс загрузки APK --- */
.progress-wrap {
  display: grid;
  gap: 6px;
}

.progress-track {
  height: 8px;
  border-radius: 20px;
  background: var(--panel-2);
  border: 1px solid var(--line);
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  width: 0;
  background: var(--accent);
  transition: width 0.15s linear;
}

.progress-text {
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}

/* --- список сборок проекта (в выезжающей панели) --- */
.build-list {
  display: grid;
  gap: 10px;
}

.build-row {
  background: var(--panel-2);
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 10px 12px;
  display: grid;
  gap: 6px;
}

.build-main {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
}

.build-version {
  font-weight: 600;
}

.build-note {
  font-size: 12.5px;
}

.build-meta {
  font-size: 12px;
}

.build-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

/* --- просмотр картинки --- */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.9);
  display: grid;
  place-items: center;
  z-index: 100;
  cursor: zoom-out;
  padding: 24px;
}

.lightbox img {
  max-width: 100%;
  max-height: 100%;
  border-radius: 8px;
}

.toast {
  position: fixed;
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--panel-2);
  border: 1px solid var(--accent);
  padding: 10px 18px;
  border-radius: 10px;
  z-index: 200;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

@media (max-width: 720px) {
  .crumbs,
  #model-note {
    display: none;
  }
}

/* --- страница проекта --------------------------------------------------------------------- */
.proj-head {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 4px;
}

.proj-title h2 {
  margin: 0 0 2px;
}

.proj-pkg {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  font-size: 12px;
  margin-top: 2px;
}

.proj-head-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  flex-wrap: wrap;
}

/* Кнопка «Прогнать», когда в проекте есть error: не блокируем — решение за человеком —
   но приглушаем акцентный фиолетовый на предупреждающий оранжевый, title объясняет почему. */
.btn.primary.btn-risky {
  background: rgba(255, 165, 61, 0.14);
  border-color: rgba(255, 165, 61, 0.45);
  color: var(--major);
}

.btn.primary.btn-risky:hover:not(:disabled) {
  background: rgba(255, 165, 61, 0.22);
  border-color: var(--major);
}

/* --- проверки настройки проекта: сразу под шапкой, до сводки --- */
.proj-checks {
  display: grid;
  gap: 8px;
  margin-top: 2px;
}

.proj-checks-ok {
  margin: 4px 0 0;
}

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

.check-row {
  background: var(--panel);
  border: 1px solid var(--line);
  border-left: 3px solid var(--line);
  border-radius: 9px;
  padding: 9px 12px;
  display: grid;
  gap: 3px;
}

.check-title {
  font-weight: 600;
  font-size: 13px;
}

.check-hint {
  font-size: 12.5px;
}

.check-row.check-error {
  border-left-color: var(--blocker);
}

.check-row.check-error .check-title {
  color: var(--blocker);
}

.check-row.check-warning {
  border-left-color: var(--major);
}

.check-row.check-warning .check-title {
  color: var(--major);
}

.check-row.check-note {
  border-left-color: var(--idea);
}

/* --- предупреждение об отсутствии своего профиля игры --- */
.profile-warning {
  margin: 0 0 8px;
  padding: 8px 11px;
  border: 1px solid rgba(255, 165, 61, 0.4);
  border-radius: 9px;
  background: rgba(255, 165, 61, 0.1);
  color: var(--major);
  font-size: 13px;
}

.proj-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
}

.stat-tile {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px 14px;
  display: grid;
  gap: 4px;
  align-content: start;
}

.stat-tile-wide {
  grid-column: span 2;
}

@media (max-width: 640px) {
  .stat-tile-wide {
    grid-column: span 1;
  }
}

.stat-value {
  font-size: 22px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.stat-label {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.4;
}

.proj-sev-list {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 2px;
}

/* --- список сборок на странице проекта: та же карточка, что в drawer'е сборок,
   плюс выделение самой свежей как «текущей» --- */
.build-row-current {
  border-color: var(--accent);
  background: rgba(109, 94, 252, 0.08);
}

.build-current-tag {
  color: var(--accent-2);
  border-color: rgba(109, 94, 252, 0.4);
}

/* --- вход ------------------------------------------------------------------------------- */
.login {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  background: var(--bg, #0e0f17);
}
.login-card {
  display: grid;
  gap: 12px;
  width: min(360px, calc(100vw - 48px));
  padding: 28px;
  border: 1px solid var(--line, #23253a);
  border-radius: 14px;
  background: var(--panel, #151726);
}
.login-card input {
  padding: 10px 12px;
  border: 1px solid var(--line, #23253a);
  border-radius: 8px;
  background: var(--bg, #0e0f17);
  color: inherit;
  font: inherit;
}
.login-card input:focus {
  outline: none;
  border-color: var(--accent, #6d5efc);
}
.login-err {
  min-height: 18px;
  color: var(--blocker, #ff5a5a);
  font-size: 13px;
}
