/*
  Site-specific CSS customisation
*/

.project-checklist[aria-expanded=false] .list-expanded {
  display: none;
}

.project-checklist[aria-expanded=true] .list-collapsed {
  display: none;
}

/* Remove margins and padding from the list */
ul.checklist {
  list-style-type: none;
  margin: 0;
  padding: 0;
}

/* Set all odd list items to a different color (zebra-stripes) */
ul.checklist li:nth-child(odd) {
  background: #f9f9f9;
}

/* Style the list items */
ul.checklist li {
  cursor: pointer;
  position: relative;
  padding: 12px 8px 12px 40px;
  background: #eee;
  font-size: 18px;
  transition: 0.2s;

  /* make the list items unselectable */
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}

/* Darker background-color on hover */
ul.checklist li:hover {
  background: #ddd;
}

/* When clicked on, add a background color and strike out text */
ul.checklist li.checked {
  background: #888;
  color: #fff;
  text-decoration: line-through;
}

/* Add a "checked" mark when clicked on */
ul.checklist li.checked::before {
  content: '';
  position: absolute;
  border-color: #fff;
  border-style: solid;
  border-width: 0 2px 2px 0;
  top: 10px;
  left: 16px;
  transform: rotate(45deg);
  height: 15px;
  width: 7px;
}

.upload-header {
  background-color: rgba(0, 0, 0, .125);
  position: relative;
}

.upload-title {
  margin-right: 40px;
}

.upload-controls {
  position: absolute;
  top: 0;
  right: 0;
  text-align: right;
}

/* The switch - the box around the slider */
.switch {
  position: relative;
  display: inline-block;
  width: 40px;
  height: 24px;
}

/* Hide default HTML checkbox */
.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

/* The slider */
.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  -webkit-transition: .4s;
  transition: .4s;
}

.slider:before {
  position: absolute;
  content: "";
  height: 16px;
  width: 16px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  -webkit-transition: .4s;
  transition: .4s;
}

input:checked+.slider {
  background-color: #2196F3;
}

input:focus+.slider {
  box-shadow: 0 0 1px #2196F3;
}

input:checked+.slider:before {
  -webkit-transform: translateX(16px);
  -ms-transform: translateX(16px);
  transform: translateX(16px);
}

/* Rounded sliders */
.slider.round {
  border-radius: 24px;
}

.slider.round:before {
  border-radius: 50%;
}

/* Products views */
.products-view .btn-toolbar .view {
  /* temporarily hide this until we have more view layouts */
  display: none;
}

.products-group li {
  display: block;
  list-style: none;
}

.products-group .product {
  position: relative;
  box-sizing: border-box;
}

.products-group .product .image {
  display: block;
  overflow: hidden;
  text-decoration: none;
}

.products-group .product .details {
  display: block;
}

.products-group .product .name {
  display: block;
  overflow: hidden;
  word-wrap: break-word;
  font-size: larger;
  font-weight: bolder;
}

.products-group .product .descriotion {
  display: block;
  overflow: hidden;
  word-wrap: break-word;
}

.products-group .product .operations {
  display: block;
}

/* Products list */
.products-view.list .products-group .product {
  width: 100%;
}

.products-view.list .products-group .product>div {
  min-height: 120px;
  overflow: hidden;
  display: flex;
  flex-wrap: nowrap;
}

.products-view.list .products-group .product .image {
  height: 120px;
  width: 120px;
  order: 1;
  min-width: 120px;
  text-align: center;
}

.products-view.list .products-group .product .details {
  vertical-align: top;
  order: 2;
  flex: auto;
}

.products-view.list .products-group .product .operations {
  order: 3;
  min-width: 150px;
}
