body {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 100vh;
  padding: 2rem 1rem;
  font-family: sans-serif;
}

h1,
h2 {
  text-align: center;
  width: 100%;
  margin-bottom: 1rem;
}

.task1-container,
.task2-container {
  display: flex;
  gap: 3rem;
  width: 90%;
  max-width: 1000px;
  margin-bottom: 2rem;
}

.task1-container {
  justify-content: center;
}

.task2-container {
  flex-direction: column;
  align-items: center;
}

form {
  display: flex;
  flex-direction: column;
  width: 20rem;
  padding: 1rem;
  border: 1px solid #ccc;
  border-radius: 5px;
}

form label {
  margin-top: 0.8rem;
  font-weight: bold;
}

input[type="text"] {
  padding: 0.3rem;
  border: 1px solid #aaa;
  border-radius: 3px;
}

#submit-btn {
  margin-top: 1.5rem;
  padding: 0.5rem 1rem;
  background-color: #4461c0;
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}

table {
  border-collapse: collapse;
  width: 100%;
  max-width: 400px;
}
th,
td {
  border: 1px solid black;
  padding: 10px;
  text-align: center;
}

#input-color {
  width: 100%;
  max-width: 400px;
  height: 40px;
  margin-top: 1rem;
}

.error {
  border: 2px solid red !important;
  background-color: #ffe6e6;
}

.output {
  width: 20rem;
  padding: 1rem;
  border: 1px dashed #0056b3;
  border-radius: 5px;
}
