* {
    margin: 0;
    padding: 0;
    font-family: sans-serif;
    box-sizing: border-box;
}

body {
    background-color: black;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
}

main {
    width: 100%;
    max-width: 500px;
    padding: 20px;
    border-radius: 10px;
    color: white;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

main > div > h1 {
    text-align: center;
}

main > div {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-bottom: 5px;
}

main > div > input {
    background-color: #0b0b0b;
    border: none;
    border-radius: 5px;
    padding: 10px;
    color: white;
}

main > div > input:focus {
    outline: none;
    box-shadow: 0px 0px 3px darkgray;
}

main > div > button {
    background-color: #1b1b1b;
    border: none;
    border-radius: 5px;
    font-weight: bold;
    color: white;
    padding: 10px;
    cursor: pointer;
    transition: all 0.05s ease;
}

main > div > button:hover {
    background-color: #2c2c2c;
}

main > div > button:active {
    scale: 99%;
    background-color: #3e3e3e;
}

main > ul {
    display: flex;
    flex-direction: column;
    list-style: none;
    gap: 10px;
    padding: 10px 0;
}

.task {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    background-color: #1a1a1a;
    border-radius: 5px;
}

.checkbox {
    transform: scale(1.2);
    accent-color: #4caf50;
}

.taskSpan {
    flex: 1;
    font-size: 1rem;
    text-wrap: wrap;
    word-wrap: break-word;
    word-break: break-all;
}

.taskSpan.completed {
    text-decoration: line-through;
    color: gray;
}

.editInput {
    flex: 1;
    display: none;
    padding: 5px;
    border-radius: 5px;
    border: none;
    background-color: #2a2a2a;
    color: white;
}

.saveButton,
.cancelButton {
    display: none;
}

.editButton,
.saveButton,
.cancelButton,
.deleteButton {
    background-color: #333;
    border: none;
    border-radius: 4px;
    padding: 5px 10px;
    color: white;
    cursor: pointer;
    transition: background-color 0.1s;
}

.cancelButton,
.deleteButton {
    background-color: #ff0000;
}

.editButton:hover,
.saveButton:hover,
.cancelButton:hover,
.deleteButton:hover {
    background-color: #555;
}

.cancelButton:hover,
.deleteButton:hover {
    background-color: #ff4444;
}