/* Geral */
* {
  padding: 0;
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  color: #666;
  box-sizing: border-box;
}

body {
  background-image: url("../images/mnm.jpg");
  background-size: cover;
  background-repeat: no-repeat;
  background-attachment: fixed;
}

button {
  background-color: #fdfdfd;
  color: #303147;
  border: 2px solid #303147;
  padding: 0.3rem 0.6rem;
  font-size: 1rem;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: 0.4s;
}

button:hover {
  background-color: #303147;
  color: #fff;
}

button:hover > i {
  color: #fff;
}

button i {
  color: #303147;
  font-weight: bold;
  pointer-events: none;
}

input,
select {
  padding: 0.2rem 0.5rem;
  border: 2px solid #37373789;
}

.hide {
  display: none;
}

.container {
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Todo Header*/
.todo-container {
  max-width: 450px;
  margin: 3rem auto;
  background-color: #fdfdfd;
  padding: 1.5rem;
  border-radius: 15px;
}

.todo-container header {
  text-align: center;
  padding: 0 1rem 1rem;
  border-bottom: 1px solid #ccc;
}

/* To-do form*/
#todo-form,
#edit-form {
  padding: 1rem;
  border-bottom: 1px solid #ccc;
}

#todo-form p,
#edit-form p {
  margin-bottom: 0.5rem;
  text-align: center;
}

.form-control {
  display: flex;
  justify-content: center;
}

.form-control input {
  margin-right: 0.3rem;
}

#cancel-edit-btn {
  margin-top: 1rem;
  display: flex;
  justify-content: center;
}

/* Todo toolbar */
#toolbar {
  padding: 1rem;
  border-bottom: 1px solid #ccc;
  display: flex;
}

#toolbar h4 {
  margin-bottom: 0.5rem;
}

#search {
  border-right: 1px solid #ddd;
  padding-right: 1rem;
  margin-right: 1rem;
  width: 65%;
  display: flex;
  flex-direction: column;
}

#search form {
  display: flex;
}

#search input {
  width: 100%;
  margin-right: 0.3rem;
}

#filter {
  width: 35%;
  display: flex;
  flex-direction: column;
}

#filter select {
  flex: 1;
}

/* todo list */
.todo {
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 1rem;
  border-bottom: 1px solid #ddd;
  transition: 0.3s;
}

.todo h3 {
  flex: 1;
  font-size: 0.9rem;
}

.todo button {
  margin-left: 0.4rem;
}

.done {
  background-color: #4e476d;
}

.done h3 {
  color: #fff;
  text-decoration: line-through;
  font-style: italic;
}

@media (max-width: 578px) {
  .todo-container {
    margin-inline: 1rem;
  }

  button {
    padding: 0.1rem 0.3rem;
  }

  .todo h3 {
    font-size: 1.2rem;
  }
}
