/* Spacing */
.p-1 { padding: 4px !important; }
.p-2 { padding: 8px !important; }
.p-3 { padding: 12px !important; }
.m-1 { margin: 4px !important; }
.m-2 { margin: 8px !important; }
.m-3 { margin: 12px !important; }

/* Flex utilities */
.flex { display: flex !important; }
.items-center { align-items: center !important; }
.justify-center { justify-content: center !important; }
.justify-between { justify-content: space-between !important; }
.flex-row { flex-direction: row !important; }
.flex-col { flex-direction: column !important; }

/* Text utilities */
.text-center { text-align: center !important; }
.text-right { text-align: right !important; }
.text-left { text-align: left !important; }
.text-sm { font-size: 12px !important; }
.text-base { font-size: 16px !important; }
.text-lg { font-size: 20px !important; }
.font-bold { font-weight: bold !important; }
.font-normal { font-weight: normal !important; }

/* Color utilities */
.bg-white { background: #fff !important; }
.bg-black { background: #000 !important; }
.bg-blue { background: #0c558a !important; }
.text-white { color: #fff !important; }
.text-blue { color: #0c558a !important; }
.text-gray { color: #888 !important; }

/* Border utilities */
.rounded { border-radius: 4px !important; }
.rounded-full { border-radius: 9999px !important; }
.border { border: 1px solid #ddd !important; }
.border-blue { border: 1px solid #0c558a !important; }

/* Width utilities */
.w-full { width: 100% !important; }
.w-1\/2 { width: 50% !important; }
.w-1\/3 { width: 33.333% !important; }
.w-1\/4 { width: 25% !important; }

/* Height utilities */
.h-full { height: 100% !important; }
.h-1\/2 { height: 50% !important; }
.h-1\/3 { height: 33.333% !important; }
.h-1\/4 { height: 25% !important; }
.h-screen { height: 100vh !important; }

.table-action-btn {
    background: transparent;
    color: #0c558a;
    border: 1px solid #0c558a;
    border-radius: 4px;
    padding: 2px 6px;
    font-size: 18px;
    cursor: pointer;
    transition: color 0.2s, border-color 0.2s, background 0.2s;
}
.table-action-btn:hover {
    background: #e6f0fa;
    color: #09406b;
    border-color: #09406b;
}

* {
  box-sizing: border-box;
}
body {
  font-size:13px;
  font-family: Lato ;
  font-weight: 400;
  background: #eeeeee8f;
  color:#1c2654;
}
table {
  min-width: 100%;
  border-collapse: collapse;
}

table td {
  padding: 3px;
  border-bottom: 1px solid #ddd;
}


table th {
  text-align: left;
}

div {
  padding:10px ;
  word-wrap: break-word;
}

#usershow {
  position: absolute;
  right: 18px;
  top: 14px;
  color: white;
  font-size: 15px;
  border: 1px solid white;
  padding: 4px 12px;
  border-radius: 20px;
}

#console {

    height: 330px;
    width: 900px;
    border: 1px solid #ccc;
    overflow: scroll;
    background: black;
    padding: 15px;
    color: white;

}


button.active {

    border: 1px solid #0c558a;;
    padding: 5px;
    background: #0c558a;;
    color: white;
    width: 100%;
    margin-top: 20px;
    border-radius: 5px;
    cursor:pointer;

}

button.active:hover {
    background: #3a5a7b;
}


button.disactive {

  border: 1px solid #80808024;;
  padding: 5px;
  background: #80808024;;
  color: #808080;
  width: 100%;
  margin-top: 20px;
  border-radius: 5px;
  cursor:pointer;

}


button.small {
  width:150px;
  margin-top: 0px;
}

#leftmenu {
  width: 14%;
  float: left;
  background: white;
  min-height: 400px;
  margin-left: 4px;
  box-shadow: 4px 4px 4px #aaa;
}

#leftmenu select, #leftmenu input {
  max-width: 100%;
  width: 100%;
}

#menu {
  background: #0c558a;;
  color: white;
  padding: 14px 10px;
  /*box-shadow: 4px 4px 4px #aaa;*/
}

a,a:visited {
  color: rgb(0, 105, 194);
}

#menu a {
  text-decoration: none;
  color: white;
  /*border-right: 1px solid white;*/
  padding: 3px 20px 3px 10px;
  display: table-cell;
}

#results {  
  width: 84%;
  float: left;
  background: white;
  min-height: 400px;
  margin-left: 9px;
  box-shadow: 4px 4px 4px #aaa;
}

.cimages {
  padding: 0;
  float: left;
}

#RESULTS,#HISTORY,#CINFO,#LINFO {
  background: white;
  width: 78%;
  float: left;
  margin-left: 10px;
  margin-bottom: 10px;
  padding:20px;
}

#RESULTS a {
  width: 90%;
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

#HISTORY li {
  margin-bottom:5px;
}

h3 {
  margin: 0px;
  margin-bottom: 12px;
}

#CINFO,#LINFO { float:left }

#RESULTS table td:first-child, 
#CINFO table td:first-child,
#LINFO table td:first-child
 {
  width: 160px;
}

.dataTables_wrapper table.fullstate td:nth-child(3),
.dataTables_wrapper table.fullstate th:nth-child(3){
  display:none;
}

#termsDiv {
  position: absolute;
  top: 20px;
  width: 90%;
  max-width: 600px;
  height: 480px;
  background: white;
  padding: 20px;
  margin: 0 auto;
  left: calc( 50% - 300px);
  box-shadow: 3px 3px 3px #333;
}

div.modalcard {
  position: fixed;
  width: 400px;
  z-index: 1000;
  top: 10%;
  left: calc(100% - 500px);
  background: white;
  box-shadow: 3px 3px 10px;
  padding: 10px 0px;
}

.ms-choice > div.icon-caret {
  padding:0px;
}

#histFilters select {
  width:200px;
  float:left;
}

#histFilters div.filters,
#manualTriggers div.filters {
  float:left;
}

#hist {
  min-height: 500px;
}

.deleteIcon {
  width: 16px;
  margin-left:5px;
}


.form-control {
  display: block;
  width: 100%;
  padding: .375rem .75rem;
  line-height: 1.5;
  color: #495057;
  background-color: #fff;
  background-clip: padding-box;
  border: 1px solid #ced4da;
  border-radius: .25rem;
  transition: border-color .15s ease-in-out,box-shadow .15s ease-in-out;
}

.filters label {
  clear: both;
  padding-top:5px;
  display: flex !important;
  align-items: center;
  justify-content: left;
}

.filters label > input {
  margin-top: 0.16rem !important;
}


.dataTables_wrapper .dataTables_paginate .paginate_button.current {
  background: #0c558a;;
  color: white !important;
}

.titlestate {
  font-size: 15px;
  font-weight: bold;
}

.titlestate b {
  font-size: 13px;
}

div.refresher {
  width: 20px;
  height: 20px;
  border-radius: 10px;
  background: gray;
  margin: 0px;
}

div.refreshergreen {
  background: green;
}

div.refresherred {
  background: red;
}

#refreshout {
  width:600px;
  height:100px;
  display:none;
}

table.dataTable tbody th, table.dataTable tbody td {
  padding: 2px 2px;
}


#leftmenu.loginform {
  margin: 0 auto;
  float: none;
  width: 400px;
  min-height: auto;
}

#leftmenu input[type="checkbox"] {
  width: auto;
}

#leftmenu li {
  display: list-item;
  font-size: 10px;
  white-space: nowrap;
}

#leftmenu ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

#statusdiv {
  padding: 0px;
  padding-top: 5px;
  width: 96%;
  max-height: 300px;
  overflow-y: scroll;
  overflow-x: hidden;
}

#addkey {
  position: fixed;
  top: 20%;
  left: calc( 50% - 120px );
  width: 200px;
  background: white;
  z-index: 1000;
  box-shadow: 0px 1px 11px 1px;
}

#addkey label.username {
  margin-bottom: 13px;
}

#addkey,#addEmail {
  display:none;
}

#addEmail {
  position: fixed;
  top: 20%;
  left: calc( 50% - 120px );
  width: 300px;
  background: white;
  z-index: 1000;
  box-shadow: 0px 1px 11px 1px;
}

.activecounts {
  color: #666;
  font-size: 11px;
} 

#filters {
  padding-top: 0;
}

#filters label {
  padding-top: 13px;
  display:inline-block;
}
/***********************************************************************
Stats Section
***********************************************************************/

div.counter {
  float: right;
  margin-right: 5%;
  width: 25%;
  text-align: right;
  font-size: 32px;
  font-weight: bold;
}

.counter span {
  clear: both;
  display: block;
  font-size: 15px;
  color: #888;
}

.observablehq--inspect { display:none }
circle {
  /*fill: #0c558a;;*/
  fill: #70C5EB;
  stroke:none;
}

text {
  fill: white;
  cursor: pointer;
  opacity:0.5;
}

text:hover { fill:black;font-size:14px;font-weight:bold;opacity:1 }

#statsright {
  width: 66%;
  margin-right: 0%;
  background: white;
  float:right;
}

circle:hover {
  opacity: 0.2;
}

.observablehq {
  display: none;
}

.observablehq:first-child {
  display: block;
}

#summaryTable {
  float: left;
  width: 31%;
  background: white;
  margin-left: 2%;
  height: 564px;
  overflow-x: scroll;
}

.countdetail {
  color: #666;
  font-size: 11px;
}


.lictotal,.licactive {
  padding: 0;
  height: 18px;
  background: #0c558a;
  min-width: 5px;
}

.licactive {
  /*background: #53c881;*/
  background: #70C5EB;
  min-width: 3px;
}

.countdetail span {
  font-size: 10px;
  clear: both;
  display: block;
}


.lkdesc {
  font-size: 10px;
  color: #999;
}

#CINFO a, 
#LINFO a {
  text-decoration: none;
  color: #0c558a;;
}


.stars {
  width: 70px;
}

.licbadge {
  color: #0c558a;;
  float: left;
  margin:5px;
  border:1px solid #eee;
  border-radius:14px;
}


.licbadge:hover {
  cursor:pointer;
  border: 1px solid #aaa;
  box-shadow: 1px 1px 3px #ccc;
}


#detailsframe {
  position: fixed;
  top: 70px;
  height: 612px;
  left: 2%;
  width: 95%;
  background: white;
  box-shadow: 3px 3px 10px #333;
  border:5px solid #0c558a;;
}

.closedetails {
  float: right;
  font-weight: bold;
  padding: 5px 10px;
  border: 1px solid #999;
  margin-bottom: 9px;
  cursor:pointer;
}

h1,a,a:visited {
  color:#70C5EB;
}


iframe.stats {
  border:none;
  width:95%;
  height:600px;
}

#menu img {
  width: 30px;
  float: left;
  margin-top: -4px;
  margin-right: 12px;
}


tr:hover td {
  background: #eee;
}


#hist_table_filter {
  clear:both;
}

#hist_table_filter input {
    width: 300px;    
  }


div.modalcard .content {
  padding: 0px 10px;
}

div.modalcard .header {
/*  background: #0c558a;;
  color: white;
  */
  padding: 14px 10px;
  /*box-shadow: 4px 4px 4px #aaa;*/
}


.ms-choice {
  height: 15px;
  border: none;
}

.ms-parent.form-control {
  max-width: 100%;  
}

.form-control > .ms-drop {
  left: 0;
}


.service-usage-cover {
  padding: 0; 
  display: flex; 
  align-items: center; 
  flex-wrap: wrap;
}

.service-usage {
  width: 15%; 
  padding: 0;
}

.header-text{
  width: 70%;
}

.header-text-items{
  float: left; 
  width: 20%;
}

/* ---- Toggle button ---- */

/* The switch - the box around the slider */
.switch {
  position: relative;
  display: inline-block;
  width: 40px;
  height: 24px;
  float: right;
  text-align: right;
}

/* 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: 17px;
  width: 17px;
  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(17px);
  -ms-transform: translateX(17px);
  transform: translateX(17px);
}

/* Rounded sliders */
.slider.round {
  border-radius: 34px;
}

.slider.round:before {
  border-radius: 50%;
}

li{
  padding: 3px 0px
}

.usersTableDetail > div {
  padding: 3px 0px !important;
}

.justifyHeadersDT {
  display: flex; 
  justify-content: space-between; 
  align-items: center; 
  flex-flow: wrap;
}


/* --------------------------------- */

/************************************* 
 * MOBILE SECTION *
 * ***********************************/

@media (max-width: 900px) {
  div#leftmenu,div#leftmenu.loginform,#results,#RESULTS,#HISTORY  {
      width:98%;
      margin-top:10px;
      min-height:20px;
  }

  h1,#usershow {
    display: none;
  }

  #termsDiv {
    top: 20px;
    width: 90%;
    max-width: 90%;
    height: 480px;
    background: white;
    padding: 5px;
    margin: 0 auto;
    left: 5%;
    box-shadow: 3px 3px 3px #333;
  }

  td:first-child a {
    width: 50px;
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  table.dataTable thead > tr > th.sorting, 
  table.dataTable thead > tr > th.sorting_asc, 
  table.dataTable thead > tr > th.sorting_desc, 
  table.dataTable thead > tr > th.sorting_asc_disabled,
   table.dataTable thead > tr > th.sorting_desc_disabled{
    padding:4px;
   }
   
  #refresh {
    margin-top: 16px;
  }

  .dataTables_wrapper table.fullstate td:nth-child(2),
  .dataTables_wrapper table.fullstate th:nth-child(2){
    display:none;
  }

  .dataTables_wrapper table.fullstate td:nth-child(3),
  .dataTables_wrapper table.fullstate th:nth-child(3){
    display:table-cell;
  }

  .dataTables_wrapper table.fullstate th:nth-child(n+6),
  .dataTables_wrapper table.fullstate td:nth-child(n+6){
      display: none;
  }

  .dataTables_wrapper table.state th:nth-child(n+4),
  .dataTables_wrapper table.state td:nth-child(n+4){
      display: none;
  }

  .usernameresults table td:nth-child(2),
  .usernameresults table th:nth-child(2){
      display:none;
  }

  #RESULTS,#HISTORY,#CINFO,#LINFO { width:95% }

  #RESULTS tr,#CINFO tr { display: grid; margin-top:3px; }

  #menu a {
    padding: 0px 5px 4px 5px;
    vertical-align: middle;
  }

  #summaryTable { display:none }
  #statsright{ width:100%!important }
  div.counter {
    margin-right: 17%!important;
  }

  #menu img.logo { 
    margin-top:-7px;
    margin-right: 5px;
   }

  div.modalcard {
    position: absolute;
    width: 90%;
    z-index: 1000;
    top: 10%;
    left: 5%;
    background: white;
    box-shadow: 3px 3px 10px;
    padding: 10px 0px;
  }
  
  iframe.stats {
    height: 360px;
  }
  .service-usage {
    width: 50%; 
    padding: 10px;

  }
  
  .header-text{
    width: 100%;
    display: block;
  }

  #histFilters select {
    width: 100%;
  }
  
  #histFilters > div.filters {
    width: 100%;
    padding: 0px;
  }

  #console {
    height: 330px;
    width: 100%;
    border: 1px solid #ccc;
    overflow: scroll;
    background: black;
    padding: 15px;
    color: white;
  }
  
  .odd, .even { height: 40px } 

  .usersTableDetail {
    display:flex; 
    align-items:center; 
    width:100%
  }

  .usersTableDetail > div {
    padding: 10px !important;
  }

  div.counter {
    margin-right: 2% !important;
    width: 45%;
    text-align: center;
    font-size: 26px;
    font-weight: bold;
  }

  .header-text-items{
    float: left; 
    width: 50%;
  }

  
}

@media (max-width: 400px) {
  iframe.stats {
    height: 280px;
  }
}