body {
  background-color: #f5f5f5;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}
.main-header {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  padding: 20px 30px;
  margin: -15px -15px 20px -15px;
  border-radius: 0;
}
.main-header h2 {
  margin: 0;
  font-weight: 600;
}
.main-header p {
  margin: 5px 0 0 0;
  opacity: 0.9;
  font-size: 14px;
}
.panel-section {
  background: white;
  border-radius: 8px;
  padding: 20px;
  margin-bottom: 20px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.08);
  border: 1px solid #e9ecef;
}
.panel-section h4 {
  margin-top: 0;
  margin-bottom: 15px;
  color: #495057;
  font-weight: 600;
  padding-bottom: 10px;
  border-bottom: 2px solid #e9ecef;
}
.panel-section h5 {
  margin-top: 15px;
  margin-bottom: 10px;
  color: #6c757d;
  font-weight: 500;
}
.btn-primary {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  border: none;
  border-radius: 6px;
  padding: 10px 20px;
  font-weight: 500;
  transition: transform 0.2s, box-shadow 0.2s;
}
.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
  background: linear-gradient(135deg, #5a6fd6 0%, #6a4190 100%);
}
.btn-success {
  background: linear-gradient(135deg, #56ab2f 0%, #a8e063 100%);
  border: none;
  border-radius: 6px;
  padding: 10px 20px;
  font-weight: 500;
}
.btn-info {
  background: linear-gradient(135deg, #36d1dc 0%, #5b86e5 100%);
  border: none;
  border-radius: 6px;
  padding: 10px 20px;
  font-weight: 500;
}
.btn-secondary {
  background: #6c757d;
  border: none;
  border-radius: 6px;
  padding: 10px 20px;
  font-weight: 500;
}
.nav-tabs {
  border-bottom: 2px solid #e9ecef;
  margin-bottom: 20px;
}
.nav-tabs .nav-link {
  border: none;
  color: #6c757d;
  padding: 12px 24px;
  font-weight: 500;
  border-radius: 0;
  margin-bottom: -2px;
}
.nav-tabs .nav-link:hover {
  border: none;
  color: #667eea;
}
.nav-tabs .nav-link.active {
  color: #667eea;
  border-bottom: 3px solid #667eea;
  background: transparent;
}
.form-control {
  border-radius: 6px;
  border: 1px solid #ced4da;
  padding: 10px 12px;
}
.form-control:focus {
  border-color: #667eea;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.15);
}
.status-alert {
  padding: 15px 20px;
  border-radius: 8px;
  margin-bottom: 20px;
}
.status-success {
  background-color: #d4edda;
  border: 1px solid #c3e6cb;
  color: #155724;
}
.status-info {
  background-color: #d1ecf1;
  border: 1px solid #bee5eb;
  color: #0c5460;
}
.status-warning {
  background-color: #fff3cd;
  border: 1px solid #ffeeba;
  color: #856404;
}
.dataTables_wrapper {
  padding: 10px 0;
}
table.dataTable {
  border-collapse: collapse !important;
}
table.dataTable thead th {
  background: #f8f9fa;
  border-bottom: 2px solid #dee2e6 !important;
  font-weight: 600;
  color: #495057;
}
table.dataTable tbody td {
  border-top: 1px solid #e9ecef;
  padding: 12px 10px;
}
table.dataTable tbody tr:hover {
  background-color: #f8f9fa;
}
.plot-container {
  display: inline-block;
  margin: 10px;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  padding: 15px;
  background-color: #fff;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
  vertical-align: top;
  position: relative;
  width: 320px;
  max-width: 100%;
}
.plot-container img {
  max-width: 300px;
  width: 100%;
  height: auto;
  border-radius: 4px;
  display: block;
}
.plot-container p {
  margin: 10px 0 0 0;
  text-align: center;
  font-weight: 500;
  color: #495057;
  font-size: 14px;
}
.expand-icon {
  position: absolute;
  top: 8px;
  right: 8px;
  background: rgba(102, 126, 234, 0.9);
  color: white;
  border: none;
  border-radius: 4px;
  padding: 5px 8px;
  cursor: pointer;
  font-size: 14px;
  transition: background 0.2s, transform 0.2s;
  z-index: 10;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.expand-icon:hover {
  background: rgba(102, 126, 234, 1);
  transform: scale(1.1);
}
.expand-icon:focus {
  outline: none;
  box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.4);
}
.plot-modal {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0,0,0,0.8);
  justify-content: center;
  align-items: center;
  overflow: auto;
}
.plot-modal.active {
  display: flex;
}
.plot-modal-content {
  max-width: 90%;
  max-height: 90%;
  background: white;
  border-radius: 8px;
  padding: 20px;
  position: relative;
  margin: auto;
}
.plot-modal-content img {
  max-width: 100%;
  max-height: 80vh;
  height: auto;
  border-radius: 4px;
  display: block;
}
.plot-modal-close {
  position: absolute;
  top: -15px;
  right: -15px;
  background: #dc3545;
  color: white;
  border: none;
  border-radius: 50%;
  width: 30px;
  height: 30px;
  font-size: 18px;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
}
.plot-modal-close:hover {
  background: #c82333;
}
.progress {
  height: 24px;
  border-radius: 12px;
  background-color: #e9ecef;
  overflow: hidden;
}
.progress-bar {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  line-height: 24px;
  font-weight: 500;
}
.sidebar-panel {
  background: white;
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.08);
  border: 1px solid #e9ecef;
  height: 100%;
}
.divider {
  height: 1px;
  background: #e9ecef;
  margin: 20px 0;
}
.object-checkbox-group {
  max-height: 200px;
  overflow-y: auto;
  padding: 10px;
  background: #f8f9fa;
  border-radius: 6px;
  border: 1px solid #e9ecef;
}
.well {
  background: #f8f9fa;
  border: 1px solid #e9ecef;
  border-radius: 8px;
  padding: 15px;
  margin-bottom: 15px;
}
.download-btn-group .btn {
  margin-right: 10px;
  margin-bottom: 10px;
}
