
body {

    font: 18px Helvetica, Arial, sans-serif;
	line-height: 1.5;
    overflow: hidden;

}

.grid-container {
    display: grid;
    /* See eeg-dipole-2d.css for why the floors are written as minmax(). Unlike the 2D
       figures, the renderer here cannot hold a fixed 500px: 500 + colourbar + gaps already
       exceeds the narrowest desktop frame before the controls get a single pixel, so this
       track shrinks and #renderer follows it. That is safe because the render loop calls
       resizeCanvasToDisplaySize() every frame, which re-reads the canvas's CSS size and
       updates both renderer.setSize() and camera.aspect. */
    grid-template-columns: minmax(120px, 1.5fr) minmax(260px, 3.5fr) auto;
    grid-gap: 20px;
    /* border: 1px solid green; */
    width: 95%;
    height: 500px;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

#controls {

    /* Floor lives on the grid track above; a larger one here would overflow that track. */
    min-width: 0;

}

canvas { 

    width: 100%; 
    height: 100%; 
    
}

.slider-container {
    display: inline;
    margin-bottom: 10px;
}

.slider-label {
    /* flex: 1; */
    margin-right: 10px;
    margin-top: 10px;
}

.slider-obj {

    margin-top: 4px;
    /* flex: 4; */

}

.slider-container {
    display: inline;
    margin-bottom: 10px;
}

.radio-container {

    margin-top: 15px;

}

.radio-container fieldset.ui-controlgroup {
  display: inline;
  width: 80%;
}

.radio-container fieldset.ui-controlgroup .ui-controlgroup-item {
  flex: 1; /* each button takes equal share of the width */
}

.radio-container label.ui-button {
  width: 100%;
  box-sizing: border-box;
  text-align: left;
}

.button-container {

    margin-top: 15px;

}

#renderer {

    /* border: 1px solid blue; */
    height: 400px;
    width: 100%;
    max-width: 500px;

}

#colorbar-container {
  display: flex;
  align-items: stretch;
  gap: 8px;
  height: 60%;
  margin-top: 20px;
}

#colorbar-labels {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  font-family: sans-serif;
  font-size: 12px;
  min-width: 60px;
}

#colorbar-canvas {
    width: 30px;
}
