body {
  font-family: Arial, sans-serif;
  max-width: 800px;
  margin: 0 auto;
  padding: 20px;
  background-color: #f5f5f5;
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

h1 {
  color: #333;
  margin: 0;
}

.mode-switcher {
  display: flex;
  gap: 10px;
}

.mode-switcher label {
  cursor: pointer;
  padding: 5px 10px;
  border: 1px solid #ccc;
  border-radius: 4px;
  background: white;
}

.mode-switcher input[type="radio"] {
  margin-right: 5px;
}

.simple-mode {
  text-align: center;
  padding: 40px 20px;
}

.simple-buttons {
  display: flex;
  gap: 20px;
  justify-content: center;
  flex-wrap: wrap;
}

.simple-buttons button {
  padding: 15px 30px;
  font-size: 16px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  background: #007bff;
  color: white;
  line-height: 1.2;
}

#simpleShortButton {
  padding: 20px 40px;
  font-size: 20px;
  background: #28a745;
  font-weight: bold;
}

#simpleShortButton:hover:not(:disabled) {
  background: #218838;
}

#simpleShortButton:disabled {
  background: #ccc !important;
  cursor: not-allowed;
}

#simpleLongButton {
  padding: 12px 25px;
  font-size: 14px;
  background: #0b69bb;
}

#simpleLongButton:hover:not(:disabled) {
  background: #1588e0;
}

#simpleLongButton:disabled {
  background: #ccc !important;
  cursor: not-allowed;
}

#simpleStopButton {
  background: #dc3545;
}

#simpleStopButton:hover {
  background: #c82333;
}

.simple-buttons button:disabled {
  background: #ccc !important;
  cursor: not-allowed;
}

.simple-buttons button:hover:not(:disabled) {
  background: #0056b3;
}

.simple-intro-buttons {
  display: flex;
  flex-direction: column;
  gap: 20px;
  align-items: center;
  max-width: 400px;
  margin: 0 auto;
}

.simple-intro-buttons button {
  padding: 20px 30px;
  font-size: 18px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  background: #007bff;
  color: white;
  width: 100%;
  font-weight: bold;
}

.simple-intro-buttons button:hover {
  background: #0056b3;
}

.config-note {
  background: #fff3cd;
  border: 1px solid #ffeaa7;
  color: #856404;
  padding: 10px;
  margin-bottom: 15px;
  border-radius: 4px;
  font-size: 14px;
}

textarea {
  width: 100%;
  padding: 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
  box-sizing: border-box;
  font-family: monospace;
  font-size: 14px;
  resize: vertical;
}

.simple-button-group {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.simple-estimate {
  margin-top: 10px;
  font-size: 16px;
  color: #555;
  font-style: italic;
  max-width: 200px;
}

.status-pane {
  background: #fff;
  border: 2px solid #ddd;
  border-radius: 8px;
  padding: 15px;
  margin-bottom: 20px;
  text-align: center;
}

.status-running {
  border-color: #4CAF50;
  background-color: #e8f5e8;
  color: #2e7d32;
}

.status-running.status-error {
  border-color: #f44336;
  background-color: #ffebee;
  color: #c62828;
}

.status-stopped.status-error {
  border-color: #f44336;
  background-color: #ffebee;
  color: #c62828;
}

.status-stopped {
  border-color: #ccc;
  background-color: #f9f9f9;
  color: #666;
}

.section {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  margin-bottom: 15px;
}

.section-header {
  background: #f8f9fa;
  padding: 12px 15px;
  border-bottom: 1px solid #ddd;
  cursor: pointer;
  font-weight: bold;
}

.section-header:hover {
  background: #e9ecef;
}

.section-content {
  padding: 15px;
}

.section-content.collapsed {
  display: none;
}

.form-group {
  margin-bottom: 15px;
}

.form-group label {
  display: block;
  margin-bottom: 5px;
  font-weight: bold;
}

.form-group input {
  width: 100%;
  padding: 8px;
  border: 1px solid #ddd;
  border-radius: 4px;
  box-sizing: border-box;
}

button {
  background: #587ea7;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 16px;
}

button:hover {
  background: #4190e4;
}

button:disabled {
  background: lightgray;
}

.stats-line {
  font-family: monospace;
  background: #f8f9fa;
  padding: 8px;
  margin: 5px 0;
  border-radius: 4px;
  font-size: 14px;
}

video {
  width: 100%;
  max-width: 640px;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.table-container {
  max-height: 300px;
  overflow-y: auto;
  border: 1px solid #ddd;
  border-radius: 4px;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

th,
td {
  padding: 8px 12px;
  text-align: left;
  border-bottom: 1px solid #ddd;
}

th {
  background: #f8f9fa;
  font-weight: bold;
  position: sticky;
  top: 0;
  z-index: 1;
}

tbody tr:hover {
  background: #f5f5f5;
}

.extra-column {
  display: none;
}

.show-all .extra-column {
  display: table-cell;
}

.experiment-notice {
  background: #fff3cd;
  border: 1px solid #ffeaa7;
  color: #856404;
  padding: 10px;
  margin-bottom: 15px;
  border-radius: 4px;
  text-align: center;
  font-size: 14px;
}

.config-error {
  background: #f8d7da;
  border: 1px solid #f5c6cb;
  color: #721c24;
  padding: 10px;
  margin-bottom: 15px;
  border-radius: 4px;
  font-weight: bold;
}

.quick-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 15px;
}

.quick-button {
  background: #6c757d;
  color: #fff;
  border: none;
  padding: 6px 12px;
  border-radius: 4px;
  cursor: pointer;
  font-size: 12px;
}

.quick-button:hover {
  background: #5a6268;
}

.experiment-estimate {
  font-size: 12px;
  color: #666;
  margin-top: 5px;
  margin-bottom: 15px;
  font-style: italic;
}

.error-entry {
  background-color: #ffebee;
  border-left: 4px solid #f44336;
  padding: 8px 12px;
  margin-bottom: 8px;
  border-radius: 0 4px 4px 0;
  font-family: monospace;
  font-size: 0.9em;
  color: #c62828;
}

#results label {
  margin-bottom: 15px;
  display: block;
}

@media (prefers-color-scheme: dark) {
  body {
    background-color: #1a1a1a;
    color: #e0e0e0;
  }

  h1 {
    color: #e0e0e0;
  }

  .status-pane {
    background: #2d2d2d;
    border-color: #444;
  }

  .status-running {
    border-color: #4CAF50;
    background-color: #1b3d1b;
    color: #81c784;
  }

  .status-stopped {
    border-color: #555;
    background-color: #2d2d2d;
    color: #aaa;
  }

  .section {
    background: #2d2d2d;
    border-color: #444;
  }

  .section-header {
    background: #333;
    border-color: #444;
    color: #e0e0e0;
  }

  .section-header:hover {
    background: #404040;
  }

  .form-group label {
    color: #e0e0e0;
  }

  .form-group input {
    background: #333;
    border-color: #555;
    color: #e0e0e0;
  }

  button {
    background: #0846a3;
  }

  button:hover {
    background: #0b5ed7;
  }

  .stats-line {
    background: #333;
    color: #e0e0e0;
  }

  video {
    border-color: #555;
  }

  .table-container {
    border-color: #444;
  }

  th,
  td {
    border-color: #444;
    color: #e0e0e0;
  }

  th {
    background: #333;
  }

  tbody tr:hover {
    background: #404040;
  }

  .extra-column {
    display: none;
  }

  .show-all .extra-column {
    display: table-cell;
  }

  .experiment-notice {
    background: #333;
    color: #e0e0e0;
  }

  .config-error {
    background: #4d1f1f;
    color: #ffcccb;
  }

  .quick-button {
    background: #555;
    color: #ccc;
  }

  .quick-button:hover {
    background: #666;
  }

  .experiment-estimate {
    color: #999;
  }

  .error-entry {
    background-color: #4d1f1f;
    border-left-color: #f44336;
    color: #ffcccb;
  }

  .mode-switcher label {
    background: #333;
    border-color: #555;
    color: #e0e0e0;
  }

  .simple-estimate {
    color: #ccc;
  }

  .config-note {
    background: #333;
    color: #e0e0e0;
    border-color: #555;
  }

  textarea {
    background: #333;
    border-color: #555;
    color: #e0e0e0;
  }
}