:root {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: #eef2f5;
  color: #17212b;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
}

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

button {
  border: 1px solid #b8c3cc;
  background: #fff;
  color: #17212b;
  border-radius: 6px;
  padding: 9px 12px;
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

button.primary {
  width: 100%;
  border-color: #0b6b57;
  background: #0b6b57;
  color: #fff;
  font-weight: 650;
}

button.attention:not(:disabled) {
  border-color: #0b6b57;
  background: #0b6b57;
  color: #fff;
  font-weight: 750;
}

button.danger {
  border-color: #b42318;
  background: #b42318;
  color: #fff;
  font-weight: 750;
}

.shell {
  max-width: 1440px;
  margin: 0 auto;
  padding: 24px;
}

.toolbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  font-size: 24px;
  line-height: 1.25;
}

h2 {
  font-size: 18px;
  line-height: 1.35;
  margin-top: 8px;
}

h3 {
  font-size: 15px;
}

.toolbar p,
.muted,
.detail {
  color: #5f6f7a;
}

.toolbar-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.workspace {
  display: grid;
  grid-template-columns: minmax(360px, 0.82fr) minmax(460px, 1.18fr);
  gap: 16px;
  align-items: start;
}

.panel {
  background: #fff;
  border: 1px solid #d8e0e6;
  border-radius: 8px;
  padding: 16px;
  box-shadow: 0 1px 2px rgba(20, 30, 40, 0.05);
}

.grid {
  display: grid;
  gap: 12px;
}

.grid.two {
  grid-template-columns: 1fr 160px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 12px;
}

.action-field button {
  width: 100%;
  min-height: 40px;
}

.action-field button.attention {
  min-height: 44px;
}

.label-row,
.status-head,
.subpanel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

label {
  font-size: 13px;
  color: #40515e;
  font-weight: 650;
}

.check-row {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 40px;
  margin: 0 0 4px;
}

.check-row input {
  width: 18px;
  min-height: 18px;
}

.field-hint {
  margin: 0 0 12px;
  color: #71808c;
  font-size: 12px;
}

input,
select,
textarea {
  width: 100%;
  min-height: 40px;
  border: 1px solid #c6d0d8;
  border-radius: 6px;
  padding: 9px 10px;
  background: #fff;
  color: #17212b;
}

input:disabled,
button:disabled {
  background: #eef2f5;
  color: #8a98a3;
}

textarea {
  min-height: 150px;
  resize: vertical;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  line-height: 1.45;
}

.status-panel {
  min-height: 560px;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  border-radius: 999px;
  padding: 4px 10px;
  background: #e5f4ee;
  color: #0b6b57;
  font-size: 12px;
  font-weight: 700;
}

.progress {
  width: 100%;
  height: 8px;
  background: #e6edf2;
  border-radius: 999px;
  overflow: hidden;
  margin: 16px 0 12px;
}

.progress span {
  display: block;
  width: 0%;
  height: 100%;
  background: #0b6b57;
  transition: width 160ms ease;
}

.subpanel {
  margin-top: 16px;
  border: 1px solid #d8e0e6;
  border-radius: 8px;
  padding: 12px;
  background: #f8fafb;
}

iframe {
  width: 100%;
  height: 430px;
  border: 1px solid #c6d0d8;
  border-radius: 6px;
  background: #fff;
  margin-top: 12px;
}

.inline-action {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  margin-top: 16px;
}

pre {
  max-height: 420px;
  overflow: auto;
  margin: 12px 0 0;
  padding: 12px;
  border: 1px solid #d8e0e6;
  border-radius: 6px;
  background: #101820;
  color: #d7f7ee;
  font-size: 12px;
  line-height: 1.45;
  white-space: pre-wrap;
  word-break: break-word;
}

.success-panel {
  margin-top: 16px;
}

.table-wrap {
  overflow: auto;
  margin-top: 12px;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 980px;
}

th,
td {
  border-bottom: 1px solid #e3e9ee;
  padding: 10px 8px;
  text-align: left;
  font-size: 13px;
  vertical-align: middle;
}

th {
  color: #40515e;
  font-weight: 750;
  background: #f8fafb;
}

td.summary {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color: #40515e;
}

td.meta {
  max-width: 240px;
  color: #40515e;
  word-break: break-all;
}

td button {
  padding: 6px 9px;
  margin-right: 4px;
}

.hidden {
  display: none !important;
}

@media (max-width: 980px) {
  .shell {
    padding: 14px;
  }

  .toolbar,
  .workspace {
    display: block;
  }

  .toolbar-actions {
    justify-content: flex-start;
    margin-top: 12px;
  }

  .status-panel {
    margin-top: 16px;
  }

  .grid.two {
    grid-template-columns: 1fr;
  }

  .inline-action {
    grid-template-columns: 1fr;
  }
}
