body {
    font-family: 'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
    line-height: 1.6;
    max-width: 40rem;
    margin: 0 auto;
    padding: 2rem 1rem;
}

check-box.disabled {
        opacity: 0.4;
    }

check-box.disabled label {
            cursor: not-allowed;
        }

check-box label {
        font-size: 2rem;
    }

h1 {
    margin-bottom: 1rem;
    border-bottom: 2px solid;
}

ul {
    list-style: none;
    padding: 0;
}

li {
    margin-bottom: 0.5rem;
}
:root {
    --primary-accent: black;
    --primary-highlight: #00bbcb;
}

/**
 * Don't show until JavaScript is ready
 */
check-box:not(:defined) {
    visibility: hidden;
}

check-box {
    display: block;
}

check-box label.checkbox-label {
        display: flex;
        gap: 1em;
        align-items: center;
        grid-template-columns: 1rem auto;
        cursor: pointer;
        width: fit-content;
    }

:is(check-box label.checkbox-label) input {
            border-radius: 0;
        }

:is(check-box label.checkbox-label) span {
            font-size: 1.2rem;
            margin-bottom: 0.2em;
        }

:is(:is(check-box label.checkbox-label):focus,:is(check-box label.checkbox-label):focus-within) input[type="checkbox"] {
                outline-color: var(--primary-accent);
                border-color: var(--primary-accent);
                outline-offset: 2px;
            }

check-box input[type="checkbox"] {
        appearance: none;
        background-color: #fff;
        margin: 0;
        font: inherit;
        color: currentcolor;
        width: 1.15em;
        height: 1.15em;
        border: 2px solid currentcolor;
        transform: translateY(-0.075em);
        position: relative;
        cursor: pointer;
        transition: none;
    }

:is(check-box input[type="checkbox"])::before {
            content: '';
            position: absolute;
            background: var(--primary-accent);
            width: 18%;
            height: 100%;
            top: 50%;
            left: 50%;
            transition: transform 150ms;
            transform-origin: center;
            transform: translate(-50%, -50%) rotate(45deg) scale(0);
        }

:is(check-box input[type="checkbox"])::after {
            content: '';
            position: absolute;
            background: var(--primary-accent);
            width: 18%;
            height: 100%;
            top: 50%;
            left: 50%;
            transition: transform 150ms;
            transform-origin: center;
            transform: translate(-50%, -50%) rotate(-45deg) scale(0);
        }

:is(check-box input[type="checkbox"]):checked::before {
            transform: translate(-50%, -50%) rotate(45deg) scale(1);
        }

:is(check-box input[type="checkbox"]):checked::after {
            transform: translate(-50%, -50%) rotate(-45deg) scale(1);
        }

/* Remove focus ring and border change only when clicking with mouse */

:is(check-box input[type="checkbox"]):focus:not(:focus-visible) {
            outline: none;
            border-color: currentcolor;
        }

/* Keep focus ring for keyboard navigation */

:is(check-box input[type="checkbox"]):focus-visible {
            outline: 2px solid var(--primary-highlight);
            outline-offset: 2px;
        }
