*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: Roboto, sans-serif;
    text-align: center;
    background-color: #181C14;
    display: flex;
    flex-direction: column;
    gap: 2rem;
    padding: 1rem;
}

.heading {
    color: #ECDFCC;
    font-size: 5rem;
    margin: auto;
    margin-top: 0.5rem;
    text-align: center;
}

.sub-heading {
    color: #697565;
    font-size: 1.5rem;
    width: 60%;
    margin: auto;
}

.task-form {
    background-color: #3C3D37;
    border-radius: 5px;
    border: 1px solid #697565;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    font-size: 1rem;
    width: 30%;
    padding: 1.5rem;
    margin: auto;
}

.task-title-input {
    width: 100%;
    background-color: transparent;
    border: none;
    border: 1px solid #697565;
    border-radius: 5px;
    outline: none;
    color: #ECDFCC;
    font-size: 1.2rem;
    padding: 0.5rem;
}

.task-title-input:focus {
    outline: 3px solid #ECDFCC;
    border: 1px solid #697565;
}

.task-title-input::placeholder {
    color: #697565;
}

.task-priority p {
    color: #697565;
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.task-priority {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding-top: 1rem;
}

.task-priority div label {
    color: #697565;
    font-size: 1.2rem;
    cursor: pointer;
}

.task-priority div input[type="radio"] {
    appearance: none;
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border: 2px solid #697565;
    border-radius: 50%;
    cursor: pointer;
    margin-right: 6px;
    vertical-align: middle;
}

.task-priority div input[type="radio"]:checked {
    background-color: #ECDFCC;
    /* fill color */
    border-color: #697565;
    /* border color */
}

.task-priority div {
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
}

.task-priority p {
    margin-bottom: 1rem;
}

.task-form div label {
    color: #697565;
    font-size: 1.2rem;
}

.task-form div input[type="time"] {
    border: none;
    background-color: #3C3D37;
    color: #697565;
    font-size: 1.2rem;
    outline: none;
}

input[type="time"]::-webkit-calendar-picker-indicator {
    display: none;
}

.task-form button {
    background-color: #ECDFCC;
    outline: none;
    border: none;
    color: #181C14;
    font-size: 1.2rem;
    border-radius: 5px;
    padding: 0.5rem;
    margin: auto;
    margin-top: 1rem;
    width: 100%;
    cursor: pointer;
}

.task-form button:hover {
    opacity: 0.85;
}

li {
    font-size: 1.2rem;
    color: #697565;
    background-color: #3C3D37;
    padding: 1rem;
    border-radius: 5px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    height: auto;
    min-height: 8rem;
    width: 15rem;
}

ol {
    display: flex;
    justify-content: center;
    gap: 2rem;
    padding: 2rem;
    flex-wrap: wrap;
}

li div {
    display: flex;
    gap: 1rem;
}

li h3 {
    color: #ECDFCC;
    font-size: 1.1rem;
    margin-bottom: 0.3rem;
}


li button {
    padding: 0.5rem 1rem;
    font-size: 1rem;
    margin-top: auto;
    border-radius: 5px;
    cursor: pointer;
    border: none;
    outline: none;
    background-color: #e74c3c;
    font-weight: 500;
    width: 100%;
}

li button:hover {
    opacity: 0.85;
}

.filters {
    display: flex;
    justify-content: center;
    gap: 1rem;
    padding: 1rem;
    border-radius: 5px;
    width: 90%;
    border: none;
    margin: auto;
}

.all {
    padding: 0.5rem 1rem;
    background-color: #181C14;
    color: #ECDFCC;
    font-size: 1.1rem;
    border-radius: 12px;
    border: 1px solid #ECDFCC;
    cursor: pointer;
}

.all:active {
    background-color: #ECDFCC;
    color: #181C14;
}

.critical {
    padding: 0.5rem 1rem;
    background-color: #181C14;
    color: #e74c3c;
    font-size: 1.1rem;
    border-radius: 12px;
    border: 1px solid #e74c3c;
    cursor: pointer;
}

.critical:active {
    background-color: #e74c3c;
    color: #181C14;
}

.strategic {
    padding: 0.5rem 1rem;
    background-color: #181C14;
    color: #f39c12;
    font-size: 1.1rem;
    border-radius: 12px;
    border: 1px solid #f39c12;
    cursor: pointer;
}

.strategic:active {
    background-color: #f39c12;
    color: #181C14;
}

.minor {
    padding: 0.5rem 1rem;
    background-color: #181C14;
    color: #2ecc71;
    font-size: 1.1rem;
    border-radius: 12px;
    border: 1px solid #2ecc71;
    cursor: pointer;
}

.minor:active {
    background-color: #2ecc71;
    color: #181C14;
}

.empty-msg {
    color: #ECDFCC;
    font-size: 1.1rem;
    text-align: center;
    padding: 1rem;
}

.task-checkbox {
    appearance: none;
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border: 2px solid #697565;
    border-radius: 4px;
    /* square with slight rounding */
    cursor: pointer;
}

.task-checkbox:checked {
    background-color: #ECDFCC;
    border-color: #697565;
}

.task-checkbox {
    appearance: none;
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border: 2px solid #697565;
    border-radius: 4px;
    cursor: pointer;
    position: relative;
    /* needed for ::after to position inside */
}

.task-checkbox:checked {
    background-color: #ECDFCC;
    border-color: #ECDFCC;
}

.task-checkbox:checked::after {
    content: "✓";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #181C14;
    font-size: 12px;
    font-weight: 700;
}

@media(max-width: 768px) {
    .heading {
        font-size: 3rem;
    }

    .sub-heading {
        font-size: 1.1rem;
        width: 100%;
    }

    .task-form {
        width: 90%;
    }

    ol {
        flex-direction: column;
        justify-content: center;
        align-items: center;
        padding: 1rem;
    }

    li {
        width: 90%;
        max-width: 400px;
    }

    .filters {
        gap: 0.7
    }

    .all,
    .critical,
    .strategic,
    .minor {
        font-size: 0.9rem;
    }
}