/*
 * This file contains CSS used by the model simulation page, it includes:
 * - code related to the model selection bar
 * - code related to the model simulation iframe
 *
 * It *does not* include code related to
 * - widgets, which lives in widgets.css
 * - widget theming,         netlogoweb.css
 * - loading spinner,        spinner.css
 * - code tab syntax,        netlogo-syntax.css
 */

.tortoise {
  display: flex;
  flex-direction: column;
  align-items: center;
  overflow: hidden;
}

.model-selection-bar {
  align-items: center;
  display: flex;
  justify-content: space-between;
  flex-direction: row;
  flex: 1;
  padding: 5px;
  margin: 0 0 10px 0;
  font-size: medium;
}

.model-selection-bar > div {
  padding: 0 15px;
}

iframe {
  flex: 0 3 auto;
}

.model-list {
  width: 300px;
  display: inline-block;
}

.model-list-disabled-message {
  text-align: left;
  padding: 10px 10px;
  font-size: smaller;
}

.model-box {
  max-width: 100%;
  min-height: 300px;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  box-shadow: 0px 0px 15px 1px #cccccc;
  border-radius: 10px;
  /* I have unkind things to say about Safari/iOS -- Jason B. (5/1/16) */
}

.model-container {
  min-width: 600px;
  min-height: 600px;
  border: 0;
  background-color: white;
  display: inline-block;
  overflow: hidden;
  min-width: calc(100vw - 120px);
  height: calc(100vh - 185px);
  /* In chrome, border-radius lets content bleed through on the corners
   * despite overflow: hidden, which looks awful with the loading animation.
   * This mask fixes that.
   * Found here: http://stackoverflow.com/a/10296258/145080
   * Bryan H. (7/25/15)
   **/
  -webkit-mask-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAIAAACQd1PeAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAA5JREFUeNpiYGBgAAgwAAAEAAGbA+oJAAAAAElFTkSuQmCC);
}

.chosen-container .chosen-results li {
  padding-bottom: 7px;
  padding-top:    7px;
}

.chosen-container .chosen-results li.not_compiling.dev, .chosen-container .chosen-results li.compiling.dev, .chosen-container .chosen-results li.unknown.dev {
  background-repeat: no-repeat;
  background-size: 25px 25px;
  background-position: 3px 2px;
  padding-left:   35px;
}

.chosen-container-single .chosen-single span {
  direction: rtl;
  /* Due to a bug in Chrome, we can't clip left and use ellipses:
     https://code.google.com/p/chromium/issues/detail?id=171659
     BCH 8/6/2015 */
  text-overflow: clip;
  text-align: left;
}

li.not_compiling.dev {
  background-image: url('/assets/images/x.png') !important;
}

li.compiling.dev {
  background-image: url('/assets/images/check.png') !important;
}

li.unknown.dev {
  background-image: url('/assets/images/caution.png') !important;
}
