* {
  box-sizing: border-box;
}

#outer {
  --play-height: 4rem;
  --play-width: 6rem;
  --visual-height: 6.4rem;
}

#messageWrapper {
  top: 2rem;
}

.info.volumeInfo {
  border-top-right-radius: 0;
  border-top-left-radius: 0;
  margin-top: 0;
  padding-top: 1.5rem;
}

.info.loop {
  margin-bottom: 0;
  margin-top: 1.25rem;
}

#sliders {
  width: 100%;
  padding: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}

#tempoSlider, #volumeSlider {
  width: 100%;
  max-width: 40rem;
  height: 2rem;
  margin-bottom: 0.75rem;
  padding: 0 0.5rem 0 0.5rem;

  display: flex;
  flex-direction: row;
}

#volumeSliderV {
  height: 100%;

  /* override .volumeSlider from slider-volume.css */
  width: auto;
  max-width: none;
  min-height: auto;
  max-height: none;
  margin-bottom: 0;
  padding: 0;

  display: flex;
  flex-direction: column;
}

#volumeSlider {
  margin-top: 0.5rem;
}

#tempoSliderV {
  display: flex;
  height: 100%;
  flex-direction: column;
}

#tempoRange, #volumeRange {
  width: 100%;
}

img.volumeIcon {
  pointer-events: none;
  width: 1.2rem;
  height: 1.2rem;
}

#slidersV {
  height: 100%;
  padding: 2rem 0 0.5rem 0.5rem;
  display: none;
  flex-direction: row;
  align-items: center;
}

#controls {
  width: 100%;
  height: calc(100% - 3.25rem - 2.75rem); /* tempo, vol */
  padding: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}

#divisions {
  height: 6rem;
  max-width: 40rem;
  padding: 0 0.5rem 0 0.5rem;

  display: flex;
  flex-wrap: wrap;

  z-index: 2;
}

#divisions.setup {
  height: auto;
  width: 100%;

  flex-direction: column;
}

.divisionW {
  display: flex;
  flex-direction: row;
}

#divisions.setup > .divisionW, #setupTop, #linkTop {
  margin-bottom: 0.6rem;
  width: 100%;
}

#setupTop, #linkTop {
  display: flex;
}

#playButton2, #setupIconTop {
  margin-bottom: 0.5rem;
  max-width: 4rem;
  width: 4rem;
}

#okButton, #okButtonLink {
  margin-bottom: 0.5rem;
  margin-left: auto;
  height: 2rem;
  width: 6rem;
}

#playButton2 {
  margin-right: auto;
}

#setupIconTop {
  margin-left: auto;
  margin-right: auto;
}

.divisionToggle, #setupButton {
  margin: 0.25rem;
  padding: 0.5rem;
  min-width: 2.5rem;
  border: 0.15rem solid var(--color-primary-border);
}

.divisionToggle.selected {
  border: 0.15rem solid var(--color-emphasis-border);
}

#divisions.setup > .divisionW > .divisionToggle {
  margin-left: 0;
}

.divisionSetup {
  width: 100%;

  display: grid;
  grid-template-rows: 1fr;
  grid-template-columns: repeat(11, 1fr);
}

#primaries {
  position: relative;
  max-width: 40rem;
  width: 100%;
  height: var(--visual-height);
  padding: 0 0.5rem 0 0.5rem;

  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  flex-wrap: wrap;
}

#primaries.retracted {
  display: none;
}

#primaries.infoOn {
  height: 12.5rem;
  min-height: 6.4rem;
}

.primaryToggleW {
  width: 3rem;
  height: 3rem;
  margin: 0.1rem;

  display: flex;
  justify-content: center;
  align-items: center;
}

.primaryToggleW.retracted {
  display: none;
}

.primaryToggle {
  margin: 0;
  padding: 0;
  width: 2.2rem;
  height: 2.2rem;
  border: 0.1rem solid var(--color-emphasis-border);
  border-radius: 50%;
}

.primaryToggle.selected {
  width: 3rem;
  height: 3rem;
}

#PlayButton {
  height: var(--play-height);
  width: var(--play-width);

  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 1;
}

#shapesButton {
  width: 2rem;
  max-width: 2rem;
  min-width: 2rem;
  height: 2rem;
  max-height: 2rem;
  min-height: 2rem;
  padding: 0;

  position: absolute;
  bottom: 0.5rem;
  left: 0.5rem;
  z-index: 1;

  display: flex;
}

#shapesI {
  pointer-events: none;
  width: 100%;
}

#visualW {
  position: relative;
  height: calc(100% - 6rem); /* divisions */
  width: 100%;
  padding: 0;

  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
}

#fullscreenButton.retracted,
#linkButton.retracted,
#links.retracted,
#divisions.retracted,
#downloadButton.retracted,
#setupTop.retracted,
#visualW.retracted,
#tempoSlider.retracted,
#volumeSlider.retracted,
#setupButton.retracted,
.divisionSetup.retracted {
  display: none;
}

.wrapper.infoView > #controls {
  height: auto;
}

#visual {
  position: relative;
  width: 100%;
  max-width: 50rem;
  max-height: calc(100% - var(--visual-height));

  display: flex;
}

#visualSVG {
  stroke: var(--color-primary-text);
  max-height: 100%;
  max-width: 100%;
  height: 100%;
  width: 100%;
}

#downloadButton, #linkButton, #fullscreenButton {
  cursor: pointer;
  margin-left: 0.5rem;
}

#linkButton, #fullscreenButton, #downloadButton, #infoButton {
  z-index: 2;
  width: 2rem;
  height: 2rem;

  display: flex;
  align-items: center;
}

.drumToggle {
  width: 100%;
  display: flex;
  align-items: center;
  opacity: 0.5;
  padding: 0;
}

.drumIcon {
  pointer-events: none;
  width: 100%;
  padding: 20%;
}

#infoW {
  position: absolute;
  bottom: 0.5rem;
  left: 0.5rem;
  width: auto;

  max-width: 40rem;
  display: flex;
  justify-content: flex-start;
}

#infoW.on {
  position: static;
  width: 100%;
  margin-top: 0.5rem;
  margin-bottom: 0.5rem;
}

#infoButton {
  padding: 0;
}

#infoButton.on {
  margin: 0;
  width: auto;
  padding: 0 0.4rem 0 0;
}

#infoW.on > #downloadButton {
  width: auto;
}

#linkIcon, #fullscreenIcon, #downloadIcon, #infoIcon, .drumIcon, #playIcon {
  pointer-events: none;
  height: 100%;
  max-width: 100%;
}

#infoIcon {
  padding: 0.3rem;
}

#setupIcon, #setupButton {
  width: 100%;
  max-width: 2.4rem;
  max-height: 2.4rem;
}

#setupButton {
  display: flex;
}

#playIcon, #playButton2, #setupIconTop {
  max-height: 2rem;
}

#hammer {
  margin: 0;
  transform-origin: bottom center;
  transform-box: fill-box;
  stroke: var(--color-emphasis-fill);
  fill: var(--color-emphasis-fill);
}

.loopCircle {
  transform-box: fill-box;
  fill: currentcolor;
  color: inherit;
}

.circleW {
  display: flex;
}

/*
#group2 {
  color: #924563;
  fill-opacity: 1;
}

#group3 {
  color: #f9f871;
  fill-opacity: 1;
}

#group4 {
  color: #b4f3ff;
  fill-opacity: 1;
}

#group5 {
  color: #81bfcb;
  fill-opacity: 1;
}
*/

g {
  z-index: -1;
}

g.primary {
  z-index: auto;
}

#ttButton {
  margin-top: 0.5rem;
}

#howtoEmbed, #donateButton, #multiPloop {
  padding: 0.5rem;
  margin-top: 0.5rem;
  border: 0.12rem solid var(--color-emphasis-border);
}

img.externalIcon {
  margin-left: 0.5rem;
}

#donateButton {
  display: flex;
  justify-content: center;
}

#links {
  width: 100%;
  max-width: 40rem;
  padding: 0 0.5rem 0 0.5rem;

  display: flex;
  flex-wrap: wrap;
  flex-direction: column;
}

.linksLine {
  margin: 0.5rem;
  width: 100%;
  display: flex;
  justify-content: center;
}

.hugTop {
  margin-top: 0;
}

.url {
  font-size: 1.1rem;
  font-weight: bold;
  margin-bottom: 0;
  display: flex;
  width: 100%;
}

#linkEmbedding {
  font-size: 1.1rem;
}

.copy {
  width: 1.1rem;
  margin-top: 0;
  padding: 0;
  border: none;
  display: flex;
}

#hereEmbedding {
  margin-top: 2rem;
}

#linkTop {
  margin-bottom: 2rem;
}

#bottomSpacer {
  height: 100%;
}
