.creatacaptcha-modal,
.creatacaptcha-modal * {
    padding: 0;
    margin: 0;
    outline: 0;
    box-sizing: border-box;
}

.creatacaptcha-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.75);
    z-index: 99999;
    display: none;
    align-items: center;
    justify-content: center;
    font-family: sans-serif;
    color: #223C78;
}

.creatacaptcha-modal > div {
    position: relative;
    width: 431px;
    padding: 7px;
    margin: 10vh auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: #f2f2f2;
    border-radius: 5px;
    overflow-y: auto;
    max-height: 90%;
    transition: box-shadow .3s;
}

.creatacaptcha-modal p {
    font-size: 22px;
    line-height: 1.3;
    text-align: center;
    width: 100%;
    min-height: 50px;
}

.creatacaptcha-modal p:first-child {
    padding: 10px;
}

.creatacaptcha-modal p:last-child > span {
    line-height: 50px;
}

.creatacaptcha-modal .button {
    width: 125px;
    float: none;
    vertical-align: text-bottom !important;
    background-color: #223C78;
    border-color: #223C78;
    color: #fff;
    font-size: 13px;
    line-height: 30px;
    letter-spacing: 1px;
    cursor: pointer;
    border-radius: 3px;
    transition: opacity .3s, background-color .3s, border-color .3s;
}

.creatacaptcha-modal .button:hover {
    background-color: #33A554;
    border-color: #33A554;
}

.creatacaptcha-modal .creatacaptcha-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 50px;
    padding: 0 5px;
}

.creatacaptcha-modal .creatacaptcha-actions a:hover {
    filter: brightness(1.2);
}

.creatacaptcha-modal .creatacaptcha-actions img {
    width: 125px;
    vertical-align: middle;
}

.creatacaptcha-image-grid {
    display: flex;
    flex-wrap: wrap;
    width: 100%;
    user-select: none;
    justify-content: center;
}

.creatacaptcha-image-grid[data-count="4"] img {
    width: 194px;
    height: 194px;
}

.creatacaptcha-image-grid-item {
    box-shadow: 0 0 1px black;
    margin: 7px;
    border-radius: 5px;
    overflow: hidden;
    cursor: pointer;
    line-height: 0;
    transition: box-shadow .3s, filter .3s;
}

.creatacaptcha-image-grid-item:hover {
    filter: brightness(1.05);
}

.creatacaptcha-modal:not(.creatacaptcha-verified) .creatacaptcha-image-grid-item.creatacaptcha-selected {
    box-shadow: 0 0 0 5px #33A554, 0 0 8px black;
    filter: brightness(1.1);
}

.creatacaptcha-image-grid-item img {
    width: 125px;
    height: 125px;
    pointer-events: none;
    object-fit: cover;
    transition: opacity .5s;
}

.creatacaptcha-spinner {
    position: absolute;
    left: 50%;
    bottom: 21px;
    transform: translateX(-50%);
    width: 20px;
    height: 20px;
    background-image: url('/wp-admin/images/spinner-2x.gif');
    background-size: 20px;
    background-repeat: no-repeat;
    background-position: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity .3s;
}

.creatacaptcha-modal.creatacaptcha-loading .creatacaptcha-image-grid-item {
    pointer-events: none;
}

.creatacaptcha-modal.creatacaptcha-loading .creatacaptcha-spinner {
    opacity: 1;
}

.creatacaptcha-modal.creatacaptcha-loading .button {
    opacity: 0;
    pointer-events: none;
}

.creatacaptcha-modal.creatacaptcha-verified > div {
    box-shadow: inset 0 0 0 5px #33A554;
}

.creatacaptcha-modal.creatacaptcha-verified p:last-child {
    line-height: 50px;
}

.creatacaptcha-modal.creatacaptcha-incorrect > div {
    box-shadow: inset 0 0 0 5px #f40;
}

.creatacaptcha-modal.creatacaptcha-shuffling img {
    opacity: 0;
}

@media (max-width: 440px) or (max-height: 440px) {
    .creatacaptcha-modal {
        zoom: 0.75;
    }
}
