:root {
  color-scheme: dark;
  --bg: #111418;
  --panel: #191f26;
  --panel-2: #202832;
  --text: #edf2f7;
  --muted: #94a3b8;
  --line: #2d3746;
  --accent: #2dd4bf;
  --danger: #fb7185;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 14px/1.45 system-ui, -apple-system, Segoe UI, sans-serif;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  background: rgba(17, 20, 24, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(10px);
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  font-size: 20px;
  font-weight: 700;
}

h2 {
  font-size: 15px;
  font-weight: 650;
}

p,
.path,
dt {
  color: var(--muted);
}

.layout {
  display: grid;
  gap: 10px;
  padding: 10px;
}

.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
}

.panelHead,
.row,
.accessForm {
  display: flex;
  align-items: center;
  gap: 8px;
}

.panelHead {
  justify-content: space-between;
  margin-bottom: 10px;
}

.badge {
  min-width: 52px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 3px 8px;
  color: var(--accent);
  text-align: center;
}

select,
textarea,
input,
button {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--panel-2);
  color: var(--text);
  font: inherit;
}

select,
input,
button {
  min-height: 38px;
  padding: 0 10px;
}

textarea {
  resize: vertical;
  padding: 10px;
}

button {
  width: auto;
  min-width: 92px;
  cursor: pointer;
}

button.primary {
  width: 100%;
  margin-top: 8px;
  background: var(--accent);
  color: #041414;
  border-color: var(--accent);
  font-weight: 700;
}

.iconBtn {
  min-width: 40px;
  width: 40px;
  font-size: 18px;
}

.path {
  margin-top: 8px;
  word-break: break-word;
}

.statusGrid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
}

.statusGrid div {
  min-width: 0;
  padding: 8px;
  background: var(--panel-2);
  border-radius: 6px;
}

dt,
dd {
  margin: 0;
}

dd {
  overflow-wrap: anywhere;
}

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

.item {
  padding: 9px;
  background: var(--panel-2);
  border-radius: 6px;
  border: 1px solid transparent;
}

.itemTitle {
  font-weight: 650;
}

.itemMeta {
  color: var(--muted);
  font-size: 12px;
  overflow-wrap: anywhere;
}

pre {
  max-height: 360px;
  overflow: auto;
  margin: 0;
  padding: 10px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  background: #0b0f14;
  border-radius: 6px;
  color: #dbeafe;
}

label {
  display: grid;
  gap: 6px;
  margin-top: 8px;
  color: var(--muted);
}

.accessForm {
  align-items: stretch;
  margin-top: 10px;
}

.accessForm input {
  flex: 1 1 auto;
}

.accessForm select,
.accessForm button {
  flex: 0 0 auto;
}

.danger {
  border-color: rgba(251, 113, 133, 0.5);
  color: var(--danger);
}

#toast {
  position: fixed;
  left: 10px;
  right: 10px;
  bottom: 10px;
  display: none;
  padding: 10px 12px;
  border-radius: 8px;
  background: #e2e8f0;
  color: #111418;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}

@media (min-width: 860px) {
  .layout {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: 1180px;
    margin: 0 auto;
  }

  .taskPanel {
    grid-column: span 2;
  }
}
