.demo-machine [hidden] {
  display: none !important;
}

.demo-machine {
  min-height: min(70vh, 680px);
  display: grid;
  place-items: center;
  padding: 32px 20px;
  box-sizing: border-box;
}

.demo-card {
  width: min(680px, 100%);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 16px;
}

.demo-instruction,
.demo-label,
.demo-updating-label {
  text-align: center;
  font-weight: 600;
}

.demo-path,
.demo-textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid #cbd5e1;
  border-radius: 10px;
  box-sizing: border-box;
  resize: vertical;
  font: inherit;
  line-height: 1.5;
  background: #ffffff;
  color: #0f172a;
}

.demo-summary {
  min-height: 280px;
}

.demo-primary-button,
.demo-secondary-button {
  min-width: 110px;
  padding: 10px 18px;
  border-radius: 8px;
  border: 1px solid transparent;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.demo-primary-button {
  align-self: center;
  background: #2563eb;
  color: #ffffff;
}

.demo-primary-button:disabled {
  cursor: not-allowed;
  opacity: 0.6;
}

.demo-secondary-button {
  background: #ffffff;
  color: #334155;
  border-color: #cbd5e1;
}

.demo-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
}

.demo-actions .demo-primary-button {
  align-self: auto;
}

.demo-status {
  min-height: 1.4em;
  text-align: center;
  color: #b91c1c;
}

.demo-stream-status,
.demo-updating-view {
  align-items: center;
  justify-content: center;
}

.demo-stream-status {
  display: flex;
  gap: 10px;
  color: #475569;
}

.demo-updating-view {
  text-align: center;
}

.demo-spinner {
  width: 22px;
  height: 22px;
  border: 3px solid #cbd5e1;
  border-top-color: #2563eb;
  border-radius: 50%;
  animation: demo-spin 0.8s linear infinite;
}

.demo-spinner-large {
  width: 46px;
  height: 46px;
  border-width: 5px;
}

.demo-progress-track {
  width: min(520px, 100%);
  height: 12px;
  overflow: hidden;
  border-radius: 999px;
  background: #e2e8f0;
}

.demo-progress-fill {
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: #2563eb;
  transition: width 180ms linear;
}

.demo-progress-text {
  font-variant-numeric: tabular-nums;
  color: #475569;
}

.demo-input-container {
  display: flex;
  gap: 8px;
  align-items: center;
}

@keyframes demo-spin {
  to {
    transform: rotate(360deg);
  }
}
