html, body {
  overflow-y: visible;
}
body {
  font-family: arial;
  font-size: 12px;
  padding: 0;
  margin: 0;
  min-width: 100px;
  min-height: 100px;
}
input {
  background: #fff;
  border: solid 1px rgba(0, 0, 0, 0.1);
  border-radius: 0;
  padding: 0 5px;
  margin: 1px;
  height: 28px;
}
input[type=button] {
  cursor: pointer;
}
input:focus{
  border-color: rgba(0, 0, 0, 0.2);
}
input:active{
  border-color: rgba(0, 0, 0, 0.3);
}

#menu {
  position: absolute;
  right: 5px;
  top: 5px;
  z-index: 3;
}
#menu div[data-role=button] {
  width: 34px;
  height: 34px;
  position: relative;
  cursor: pointer;
}
#menu div[data-role=button][data-toggle=open],
#menu div[data-role=button]:hover {
  background-color: rgba(0, 0, 0, 0.1);
}
#menu div[data-role=button]:active {
  background-color: rgba(0, 0, 0, 0.2);
}
#menu div[data-role=button]:before {
  content: '\e804';
  font-size: 180%;
  line-height: 30px;
  transform: rotate(90deg);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  width: 100%;
  height: 100%;
}
#menu ul {
  width: 160px;
  background-color: #fff;
  border: solid 1px rgba(0, 0, 0, 0.1);
  list-style-type: none;
  padding: 0;
  margin: 0;
  text-align: left;
}
#menu div[data-role=button][data-toggle=close] + ul {
  display: none;
}
#menu hr {
  border-style: dotted;
  border-width: 1px 0 0 0;
  margin: 2px 3px;
  border-color: rgba(0,0,0,0.3);
}
#menu li {
  padding: 5px;
  cursor: pointer;
}
#menu li:before {
  font-size: 120%;
}
#menu li[data-role="done"]:before {
  color: green;
}
#menu li[data-role="error"]:before {
  color: red;
}
#menu li:hover {
  background-color: rgba(0, 0, 0, 0.1);
}
#menu li:active {
  background-color: rgba(0, 0, 0, 0.2);
}
body[data-developer=false] li[data-role=developer],
body[data-helper=false] li[data-role=helper] {
  display: none;
}

#toolbar {
  display: flex;
  height: 40px;
  width: calc(100% - 10px);
  padding: 5px;
}
#toolbar input[type=search] {
  width: 40%;
  max-width: calc(100% - 40px);
  min-width: 100px;
  height: 30px;
  border: solid 1px rgba(0, 0, 0, 0.1);
  outline: 0;
  padding: 0 30px 0 5px;
  background: url('icons/search.png') center right no-repeat;
  background-size: contain;
  transition: width 0.5s;
}
@media (min-width: 500px){
  #toolbar input[type=search] {
    max-width: 300px;
  }
}
#toolbar input[type=search]:focus {
  border-color: rgba(0, 0, 0, 0.2);
  width: 80%;
}

#no-active {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  font-size: 120%;
  position: absolute;
  left: 0;
  top: 0;
  z-index: -1;
}
@media (max-height: 300px) {
  #no-active {
    display: none;
  }
}
.item:not([data-id="-1"]) ~ #no-active {
  display: none;
}

.item {
  display: flex;
  align-items: center;
  height: 60px;
  border: 1px solid rgba(0, 0, 0, 0.1);
  margin: 5px;
  width: calc(100% - 10px);
}
.item[data-filtered=true] {
  opacity: 0.1;
  pointer-events: none;
}
.item[data-id="-1"] {
  display: none;
}
.item>span {
  font-size: 300%;
}
.item>span:before {
  content: '\e805';
}
.item>div {
  width: 100%;
  height: 100%;
  display: inline-flex;
  flex-direction: column;
  flex: 1;
  margin: 0 5px;
}
.item div[data-type=overal] {
  height: 12px;
  margin-top: 3px;
  background-color: rgba(0, 0, 0, 0.2);
}
.item div[data-type=overal]>div {
  height: 100%;
  width: 0%;
  background-color: green;
}

.item div[data-type=partial] {
  height: 4px;
  margin-bottom: 3px;
  background-color: rgba(0, 0, 0, 0.1);
  position: relative;
}
.item div[data-type=partial]>div {
  height: 100%;
  background-color: red;
  position: absolute;
}
item[data-type=error] div[data-type=partial]>div,
item[data-type=done] div[data-type=partial]>div {
  display: none;
}
/* done */
.item[data-type=done]>span:before {
  color: green;
  content: '\e808';
}
.item[data-type=done] div[data-type=overal] {
  background-color: green;
}
/* pause */
.item[data-type=pause]>span:before {
  color: #EAC500;
  content: '\e800';
}
.item[data-type=pause] div[data-type=overal] div {
  background-color: #EAC500;
}
/* error */
.item[data-type=error]>span:before {
  color: red;
  content: '\e802';
}
.item[data-type=error] div[data-type=overal] {
  background-color: red;
}
.item[data-type=error] div[data-type=overal]>div {
  background-color: transparent;
}

.item:not([data-type=pause]) i[data-cmd=modify],
.item:not([data-type=pause]) i[data-cmd=cancel],
.item[data-type=new] i[data-cmd=pause],
.item[data-type=new] i[data-cmd=cancel],
.item[data-type=head] i[data-cmd=pause],
.item[data-type=head] i[data-cmd=cancel] {
  opacity: 0.3;
  cursor: not-allowed;
  pointer-events: none;
}
.item[data-type=error] i[data-cmd=cancel],
.item[data-type=done] i[data-cmd=cancel],
.item[data-type=error] i[data-cmd=pause],
.item[data-type=done] i[data-cmd=pause] {
  display: none;
}
.item i[data-cmd=open],
.item i[data-cmd=use-native],
.item i[data-cmd=native],
.item i[data-cmd=trash] {
  display: none;
}
body[data-open=true] .item[data-type=done] i[data-cmd=open],
.item[data-type=error] i[data-cmd=use-native],
.item[data-type=error] i[data-cmd=native],
.item[data-type=error] i[data-cmd=trash],
.item[data-type=done] i[data-cmd=trash] {
  display: block;
}
/* name */
.item [data-type=top] {
  display: flex;
  flex: 1;
}
.item [data-type=bottom] {
  white-space: nowrap;
  height: 16px;
  display: flex;
  align-items: center;
}

.item [data-type=name] {
  display: flex;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  flex: 1;
  align-items: center;
}
/* buttons */
.item i {
  display: block;
  width: 40px;
  height: 16px;
  background-color: rgba(0, 0, 0, 0.1);
  text-align: center;
  font-size: 80%;
  cursor: pointer;
  margin-left: 4px;

}
.item i:active {
  background-color: rgba(0, 0, 0, 0.2);
}
.item i:before {
  line-height: 16px;
}
.item i[data-cmd=pause]:before {
  content: '\e800';
}
.item[data-type=pause] i[data-cmd=pause]:before {
  content: '\e803';
}
.item i[data-cmd=cancel]:before {
  content: '\e801';
}
.item i[data-cmd=info]:before {
  content: '\e806';
}
.item i[data-cmd=trash]:before {
  content: '\e802';
}
.item i[data-cmd=native]:before {
  content: '\e805';
}
.item i[data-cmd=use-native]:before {
  content: '\e814';
}
.item i[data-cmd=modify]:before {
  content: '\e809';
}
.item i[data-cmd=open]:before {
  content: '\e80d';
}
/* add */
#add {
  position: fixed;
  display: flex;
  align-items: center;
  justify-content: center;
  right: 30px;
  bottom: 30px;
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background-color: #fff;
  border: solid 1px rgba(0, 0, 0, 0.1);
  opacity: 0.5;
  font-size: 300%;
  cursor: pointer;
}
#add:hover {
  opacity: 0.6;
}
#add:active {
  opacity: 1;
  border-color: rgba(0, 0, 0, 0.2);
}
#add:before {
  content: '\e80c';
}
@media (max-height: 200px) {
  #add {
    display: none;
  }
}
/* loader & confirm */
#loader,
#confirm {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: visibility 0s linear 0.2s, opacity 0.2s ease-in-out;
}
#confirm[data-visible=false],
#loader[data-visible=false] {
  opacity: 0;
  visibility: hidden;
}
#confirm[data-visible=true],
#loader[data-visible=true] {
  transition-delay: 0s;
  visibility: visible;
  opacity: 1;
}
#loader iframe {
  width: 80%;
  height: 80%;
  background-color: #fff;
  border: none;
}
@media (max-width: 600px) {
  #loader iframe {
    width: 90%;
  }
}
#confirm>div {
  border: solid 3px #ddd;
  width: 80%;
  max-width: 400px;
  height: 100px;
  background: #fff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 10px;
}
#confirm>div>span {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
#confirm>div>div {
  flex: 1;
  display: flex;
  flex-direction: row-reverse;
}
/* animation */
.animated {
  animation-duration: 1s;
  animation-fill-mode: both;
}
