body {
  font-family: Arial, sans-serif;
  max-width: 75rem;
  margin: 0 auto;
  padding: 1.25rem;
  background-color: #f5f5f5;
}

h1 {
  text-align: center;
  color: #333;
}

.container {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
}

.controls {
  flex: 0 0 18.75rem;
  background: white;
  padding: 1.25rem;
  border-radius: 0.5rem;
  box-shadow: 0 0.125rem 0.625rem rgba(0, 0, 0, 0.1);
}

.control-group {
  margin-bottom: 1.25rem;
}

.control-group label {
  display: block;
  margin-bottom: 0.3125rem;
  font-weight: bold;
  color: #555;
}

.slider-container {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.input-wrapper {
  position: relative;
  display: inline-block;
}

.unit {
  font-size: 0.6875rem;
  color: #666;
  white-space: nowrap;
  position: absolute;
  right: 0.25rem;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  user-select: none;
}

.slider {
  flex: 1;
}

input.value {
  color: #007bff;
  width: 2.8125rem;
  text-align: right;
  font-weight: bold;
  color: #007bff;
  border: 0.0625rem solid #ddd;
  border-radius: 0.25rem;
  padding-right: 2.5rem;
  font-size: 0.75rem;
  position: relative;
}

input[type='range'] {
  width: 100%;
  height: 0.375rem;
  border-radius: 0.1875rem;
  background: #ddd;
  outline: none;
  -webkit-appearance: none;
}

input[type='range']::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 1.25rem;
  height: 1.25rem;
  border-radius: 50%;
  background: #007bff;
  cursor: pointer;
}

input[type='range']::-moz-range-thumb {
  width: 1.25rem;
  height: 1.25rem;
  border-radius: 50%;
  background: #007bff;
  cursor: pointer;
  border: none;
}

.trajectory-select {
  width: 100%;
  padding: 0.5rem;
  border: 0.0625rem solid #ddd;
  border-radius: 0.25rem;
  font-size: 0.875rem;
  background: white;
}

.control-group.conditional {
  display: none;
}

.plots {
  flex: 1;
  background: white;
  height: 40rem;
  padding: 1.25rem;
  border-radius: 0.5rem;
  box-shadow: 0 0.125rem 0.625rem rgba(0, 0, 0, 0.1);
}

#motion-canvas {
  width: 100%;
  height: 100%;
  border: 0.0625rem solid #ddd;
  border-radius: 0.25rem;
}

.info {
  margin-top: 1.25rem;
  margin-bottom: 1.25rem;
  padding: 0.9375rem;
  background: #e8f4fd;
  border-radius: 0.25rem;
  border-left: 0.25rem solid #007bff;
}

.info h3 {
  margin-top: 0;
  color: #007bff;
}

.info p {
  margin: 0.3125rem 0;
  color: #555;
}

/* Mobile styles */
@media (max-width: 768px) {
  body {
    padding: 0.625rem;
    max-width: none;
    zoom: 75%;
    touch-action: pan-y pinch-zoom;
  }

  .container {
    flex-direction: column;
  }

  .controls {
    flex: none;
    width: 100%;
    padding: 0.625rem;
    margin: 0.3125rem 0;
    box-sizing: border-box;
  }

  .control-group {
    margin-bottom: 0.625rem;
  }

  .value {
    min-width: 3.75rem;
    font-size: 0.875rem;
  }

  .unit {
    font-size: 0.625rem;
    position: absolute;
    right: 0.1875rem;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    user-select: none;
  }

  .plots {
    height: 600px;
    flex: none;
    padding: 0.625rem;
    width: 100%;
    box-sizing: border-box;
  }
}
