/* Center the checklist on the screen */
body {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    margin: 0;
    font-family: Arial, sans-serif;
}

/* Style for the container of checklist items */
.checklist {
    display: flex;
    flex-direction: column;
    align-items: flex-start; /* Align text to the left */
}

/* Style for each item */
.item {
    display: flex;
    margin: 10px 0;
    font-size: 18px;
    width: 100%;
    justify-content: space-between;
}

label {
    display: flex;
    align-items: center;
    cursor: pointer;
}

/* Hide the default checkbox */
input[type='checkbox'] {
    display: none;
}

/* Custom checkbox design */
.custom-checkbox {
    width: 20px;
    height: 20px;
    border: 2px solid #16423c;
    border-radius: 4px;
    position: relative;
    transition: all 0.3s ease;
    display: inline-block;
    margin-right: 10px;
}

/* When the checkbox is checked, apply animation and background */
input[type='checkbox']:checked + .custom-checkbox {
    background-color: #6a9c89;
    border-color: #16423c;
    animation: check 0.4s ease forwards;
}

/* Checkmark inside the custom checkbox */
.custom-checkbox::after {
    content: '';
    position: absolute;
    top: 5px;
    left: 5px;
    width: 10px;
    height: 5px;
    border: solid #e9efec;
    border-width: 0 0 2px 2px;
    transform: rotate(-45deg);
    opacity: 0;
    transition: opacity 0.2s ease;
}

/* Show checkmark when checkbox is checked */
input[type='checkbox']:checked + .custom-checkbox::after {
    opacity: 1;
}

/* Animation for checking */
@keyframes check {
    0% {
        transform: scale(0.8);
    }
    50% {
        transform: scale(1.1);
    }
    100% {
        transform: scale(1);
    }
}

.weight {
    min-width: 60px;
    padding: 3px;
    padding-top: 7px;
    padding-bottom: 7px;
    text-align: center;
    margin-left: 20px;
    cursor: pointer;
    background-color: white;
    border: 2px solid #081816;
    border-radius: 5px;
    display: inline;
    box-shadow: none;
}

/* Style for checked items (crossed out) */
.item.checked label {
    color: gray;
    text-decoration: line-through;
}

.item .weight {
    text-decoration: none;
}

.overlay {
    width: 400px;
    height: 400px;
    border-radius: 20px;
    border-color: #e9efec;
    background-color: #6a9c89;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-width: 1px;
    border-style: solid;
    z-index: 1;
    display: none;
}

.overlay button {
    margin: 10px;
    height: 50px;
    width: 100px;
    border-radius: 5px;
}
