/* COLOURS */
:root {
  --main-bg-color: #fff;
  --base-text-color: #333;
  --light-text-color: #888;
}

/* Basic Style */
body {
  background: var(--main-bg-color);
  color: #333;
  font-family: sans-serif;
  margin: 40px;
}

.primary {
  color: var(--base-text-color);
  font-weight: bold;
  width: 265px;
}

.hide {
  display: none !important;
}

.overlay {
  text-align: center;
}

#notificationContainer {
  position: fixed;
  display: grid;
  grid-template-columns: 100vw;
  top: 0;
  left: 0;
}

#notification {
  text-align: center;
  color: #666666;
  background-color: white;
  padding: 5px;
  width: 300px;
  justify-self: center;
  align-self: center;
  border-bottom: 2px solid yellowgreen;
  box-shadow: 0px 4px 10px 3px lightgrey;
}

.fade-in {
  animation: fadeIn ease 1s;
  -webkit-animation: fadeIn ease 1s;
  -moz-animation: fadeIn ease 1s;
  -o-animation: fadeIn ease 1s;
  -ms-animation: fadeIn ease 1s;
}
@keyframes fadeIn {
  0% {
    opacity:0;
  }
  100% {
    opacity:1;
  }
}

.fade-out {
  animation: fadeOut ease 2s;
  -webkit-animation: fadeOut ease 2s;
  -moz-animation: fadeOut ease 2s;
  -o-animation: fadeOut ease 2s;
  -ms-animation: fadeOut ease 2s;
}
@keyframes fadeOut {
  0% {
    opacity:1;
  }
  100% {
    opacity:0;
  }
}

#login-main h1 {
  margin-top: 10%;
  color: var(--base-text-color);
}

#login-main input {
  width: 200px;
}

#login-main label {
  text-align: left;
}

#login button {
  margin-top: 10px;
  margin-bottom: 10px;
}

.button-box {
  clear: both;
}

.container {
  display: block;
  width: 100%;
}

ul {
  margin: 0;
  padding: 0;
}

li * {
  float: left;
}

li,
h3 {
  clear: both;
  list-style: none;
}

.separator {
  background-color: #eee;
  padding: 20px;
  font-weight: bold;
  font-size: 20px;
}

button {
  background: none;
  border: 0px;
  color: var(--light-text-color);
  font-size: 15px;
  margin: 0;
  padding: 10px;
  font-family: sans-serif;
  cursor: pointer;
  text-decoration: underline;
}

button:hover {
  color: var(--base-text-color);
}

/* Heading */
h1 {
  color: var(--base-text-color);
}

h3 {
  color: var(--base-text-color);
  font-weight: 700;
  font-size: 15px;
  border-bottom: 2px solid var(--base-text-color);
  padding: 30px 0 10px;
  margin: 0;
  text-transform: uppercase;
}

label {
  display: inline-block;
  margin-top: 20px;
  vertical-align: top;
}

label input,
label select {
  display: block;
  margin-top: 10px;
}

input {
  width: 140px;
  margin: 0;
  font-size: 16px;
  line-height: 16px;
  height: 16px;
  padding: 10px;
  border: 1px solid #ddd;
  background: var(--main-bg-color);
  border-radius: 6px;
  font-family: sans-serif;
  color: var(--light-text-color);
}

input:focus {
  color: var(--base-text-color);
}

/* New Expense */

button#add-new-expense:hover {
  color: #0FC57C;
}

/* Expense list */
li {
  overflow: hidden;
  padding: 20px 0;
  border-bottom: 1px solid #eee;
}

li>label {
  font-size: 16px;
  line-height: 36px;
  width: 140px;
  padding: 0 0 0 11px;
  margin-top: 0px;
  white-space: nowrap;
}

li>input,
li>select {
  width: 140px;
  margin-right: 4px;
}

li>button.delete:hover {
  color: #CF2323;
}

/* Edit Expense */
ul li input,
ul li select {
  display: none;
}

ul li.editMode input,
ul li.editMode select {
  display: block;
}

ul li.editMode label {
  display: none;
}

select {
  width: 140px;
  margin: 0;
  font-size: 16px;
  padding: 8px;
  border: 1px solid #ddd;
  background: var(--main-bg-color);
  border-radius: 6px;
  font-family: sans-serif;
  color: var(--light-text-color);
  background: transparent;
  background-image: url("data:image/svg+xml;utf8,<svg fill='black' height='24' viewBox='0 0 24 24' width='24' xmlns='http://www.w3.org/2000/svg'><path d='M7 10l5 5 5-5z'/><path d='M0 0h24v24H0z' fill='none'/></svg>");
  background-repeat: no-repeat;
  background-position-x: 100%;
  background-position-y: 5px;
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
}

#overlay {
  background-color: rgb(1, 1, 1, 50%);
  height: 100%;
  width: 100%;
  position: fixed;
  top: 0;
  left: 0;
}

#loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid rgba(255, 255, 255, .3);
  border-radius: 50%;
  border-top-color: #333;
  animation: spin 1s ease-in-out infinite;
  -webkit-animation: spin 1s ease-in-out infinite;
  background-color: #459CE7;
  position: fixed;
  right: 5px;
  bottom: 5px;
}

@keyframes spin {
  to {
    -webkit-transform: rotate(360deg);
  }
}

@-webkit-keyframes spin {
  to {
    -webkit-transform: rotate(360deg);
  }
}

@media (max-width: 767px) and (orientation:portrait) {
label, li label {
  width: 100%;
}
input, input.primary, select, li input, li input.primary, li select {
  width: 100%;
  height: 36px;
  box-sizing: border-box;
}

li input, li input.primary, li select {
  margin-top: 20px;
}

.button-box button {
  width: 100%;
  border: 1px solid grey;
  margin-top: 20px;
  border-radius: 5px;
}

.button-box {
  width: 100%;
}
}
