@layer components {
    .action-button {
        display: inline-block;
        font-weight: 400;
        color: #212529;
        text-align: center;
        vertical-align: middle;
        user-select: none;
        background-color: transparent;
        border: 1px solid transparent;
        padding: 0.375rem 0.75rem;
        font-size: 1rem;
        line-height: 1.5;
        border-radius: 0.25rem;
        transition: color 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
    }

    @media (prefers-reduced-motion: reduce) {
        .action-button {
            transition: none;
        }
    }

    .action-button:hover {
        color: #212529;
        text-decoration: none;
    }

    .action-button:focus,
    .action-button.focus {
        outline: 0;
        box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
    }

    .action-button.disabled,
    .action-button:disabled {
        opacity: 0.65;
    }

    .action-button:not(:disabled):not(.disabled) {
        cursor: pointer;
    }

    a.action-button.disabled,
    fieldset:disabled a.action-button {
        pointer-events: none;
    }

    .action-button--primary {
        color: #fff;
        background-color: #007bff;
        border-color: #007bff;
    }

    .action-button--primary:hover {
        color: #fff;
        background-color: #0069d9;
        border-color: #0062cc;
    }

    .action-button--primary:focus,
    .action-button--primary.focus {
        color: #fff;
        background-color: #0069d9;
        border-color: #0062cc;
        box-shadow: 0 0 0 0.2rem rgba(38, 143, 255, 0.5);
    }

    .action-button--primary.disabled,
    .action-button--primary:disabled {
        color: #fff;
        background-color: #007bff;
        border-color: #007bff;
    }

    .action-button--primary:not(:disabled):not(.disabled):active,
    .action-button--primary:not(:disabled):not(.disabled).active {
        color: #fff;
        background-color: #0062cc;
        border-color: #005cbf;
    }

    .action-button--primary:not(:disabled):not(.disabled):active:focus,
    .action-button--primary:not(:disabled):not(.disabled).active:focus {
        box-shadow: 0 0 0 0.2rem rgba(38, 143, 255, 0.5);
    }

    .action-button--success {
        color: #fff;
        background-color: #28a745;
        border-color: #28a745;
    }

    .action-button--success:hover {
        color: #fff;
        background-color: #218838;
        border-color: #1e7e34;
    }

    .action-button--success:focus,
    .action-button--success.focus {
        color: #fff;
        background-color: #218838;
        border-color: #1e7e34;
        box-shadow: 0 0 0 0.2rem rgba(72, 180, 97, 0.5);
    }

    .action-button--success.disabled,
    .action-button--success:disabled {
        color: #fff;
        background-color: #28a745;
        border-color: #28a745;
    }

    .action-button--success:not(:disabled):not(.disabled):active,
    .action-button--success:not(:disabled):not(.disabled).active {
        color: #fff;
        background-color: #1e7e34;
        border-color: #1c7430;
    }

    .action-button--success:not(:disabled):not(.disabled):active:focus,
    .action-button--success:not(:disabled):not(.disabled).active:focus {
        box-shadow: 0 0 0 0.2rem rgba(72, 180, 97, 0.5);
    }

    .action-button--warning {
        color: #212529;
        background-color: #ffc107;
        border-color: #ffc107;
    }

    .action-button--warning:hover {
        color: #212529;
        background-color: #e0a800;
        border-color: #d39e00;
    }

    .action-button--warning:focus,
    .action-button--warning.focus {
        color: #212529;
        background-color: #e0a800;
        border-color: #d39e00;
        box-shadow: 0 0 0 0.2rem rgba(222, 170, 12, 0.5);
    }

    .action-button--warning.disabled,
    .action-button--warning:disabled {
        color: #212529;
        background-color: #ffc107;
        border-color: #ffc107;
    }

    .action-button--warning:not(:disabled):not(.disabled):active,
    .action-button--warning:not(:disabled):not(.disabled).active {
        color: #212529;
        background-color: #d39e00;
        border-color: #c69500;
    }

    .action-button--warning:not(:disabled):not(.disabled):active:focus,
    .action-button--warning:not(:disabled):not(.disabled).active:focus {
        box-shadow: 0 0 0 0.2rem rgba(222, 170, 12, 0.5);
    }

    .action-button--outline-primary {
        color: #007bff;
        border-color: #007bff;
    }

    .action-button--outline-primary:hover {
        color: #fff;
        background-color: #007bff;
        border-color: #007bff;
    }

    .action-button--outline-primary:focus,
    .action-button--outline-primary.focus {
        box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.5);
    }

    .action-button--outline-primary.disabled,
    .action-button--outline-primary:disabled {
        color: #007bff;
        background-color: transparent;
    }

    .action-button--outline-primary:not(:disabled):not(.disabled):active,
    .action-button--outline-primary:not(:disabled):not(.disabled).active {
        color: #fff;
        background-color: #007bff;
        border-color: #007bff;
    }

    .action-button--outline-primary:not(:disabled):not(.disabled):active:focus,
    .action-button--outline-primary:not(:disabled):not(.disabled).active:focus {
        box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.5);
    }

    .action-button--outline-secondary {
        color: #6c757d;
        border-color: #6c757d;
    }

    .action-button--outline-secondary:hover,
    .dropdown[open] > .action-button--outline-secondary {
        color: #fff;
        background-color: #6c757d;
        border-color: #6c757d;
    }

    .action-button--outline-secondary:focus,
    .action-button--outline-secondary.focus {
        box-shadow: 0 0 0 0.2rem rgba(108, 117, 125, 0.5);
    }

    .action-button--outline-secondary.disabled,
    .action-button--outline-secondary:disabled {
        color: #6c757d;
        background-color: transparent;
    }

    .action-button--outline-secondary:not(:disabled):not(.disabled):active,
    .action-button--outline-secondary:not(:disabled):not(.disabled).active {
        color: #fff;
        background-color: #6c757d;
        border-color: #6c757d;
    }

    .action-button--outline-secondary:not(:disabled):not(.disabled):active:focus,
    .action-button--outline-secondary:not(:disabled):not(.disabled).active:focus {
        box-shadow: 0 0 0 0.2rem rgba(108, 117, 125, 0.5);
    }

    .action-button--outline-danger {
        color: #dc3545;
        border-color: #dc3545;
    }

    .action-button--outline-danger:hover {
        color: #fff;
        background-color: #dc3545;
        border-color: #dc3545;
    }

    .action-button--outline-danger:focus,
    .action-button--outline-danger.focus {
        box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.5);
    }

    .action-button--outline-danger.disabled,
    .action-button--outline-danger:disabled {
        color: #dc3545;
        background-color: transparent;
    }

    .action-button--outline-danger:not(:disabled):not(.disabled):active,
    .action-button--outline-danger:not(:disabled):not(.disabled).active {
        color: #fff;
        background-color: #dc3545;
        border-color: #dc3545;
    }

    .action-button--outline-danger:not(:disabled):not(.disabled):active:focus,
    .action-button--outline-danger:not(:disabled):not(.disabled).active:focus {
        box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.5);
    }

    .action-button--outline-dark {
        color: #343a40;
        border-color: #343a40;
    }

    .action-button--outline-dark:hover {
        color: #fff;
        background-color: #343a40;
        border-color: #343a40;
    }

    .action-button--outline-dark:focus,
    .action-button--outline-dark.focus {
        box-shadow: 0 0 0 0.2rem rgba(52, 58, 64, 0.5);
    }

    .action-button--outline-dark.disabled,
    .action-button--outline-dark:disabled {
        color: #343a40;
        background-color: transparent;
    }

    .action-button--outline-dark:not(:disabled):not(.disabled):active,
    .action-button--outline-dark:not(:disabled):not(.disabled).active {
        color: #fff;
        background-color: #343a40;
        border-color: #343a40;
    }

    .action-button--outline-dark:not(:disabled):not(.disabled):active:focus,
    .action-button--outline-dark:not(:disabled):not(.disabled).active:focus {
        box-shadow: 0 0 0 0.2rem rgba(52, 58, 64, 0.5);
    }

    .action-button--large {
        padding: 0.5rem 1rem;
        font-size: 1.25rem;
        line-height: 1.5;
        border-radius: 0.3rem;
    }

    .action-button--small {
        padding: 0.25rem 0.5rem;
        font-size: 0.875rem;
        line-height: 1.5;
        border-radius: 0.2rem;
    }

    .action-button--block {
        display: block;
        width: 100%;
    }

    .action-button--block + .action-button--block {
        margin-top: 0.5rem;
    }

    input[type="submit"].action-button--block,
    input[type="reset"].action-button--block,
    input[type="button"].action-button--block {
        width: 100%;
    }

    .button-group {
        position: relative;
        display: inline-flex;
        vertical-align: middle;
    }

    .button-group > .action-button {
        position: relative;
        flex: 1 1 auto;
    }

    .button-group > .action-button:hover {
        z-index: 1;
    }

    .button-group > .action-button:focus,
    .button-group > .action-button:active,
    .button-group > .action-button.active {
        z-index: 1;
    }

    .button-group > .action-button:not(:first-child),
    .button-group > .button-group:not(:first-child) {
        margin-left: -1px;
    }

    .button-group > .action-button:not(:last-child),
    .button-group > .button-group:not(:last-child) > .action-button {
        border-top-right-radius: 0;
        border-bottom-right-radius: 0;
    }

    .button-group > .action-button:not(:first-child),
    .button-group > .button-group:not(:first-child) > .action-button {
        border-top-left-radius: 0;
        border-bottom-left-radius: 0;
    }

    @media print {
        a:not(.action-button) {
            text-decoration: underline;
        }
    }

    .button {
        border: 2px solid;
        padding: 0.5rem;
        display: inline-block;
        font-family: var(--font-heading);
        font-weight: 700;
        font-size: 0.6875em;
        text-transform: uppercase;
    }

    .button .icon-pdf {
        vertical-align: middle;
        position: relative;
        top: -2px;
        margin-right: 0.5rem;
    }

    a.button-black {
        color: inherit;
    }

    a.button-black:hover {
        text-decoration: none;
        background-color: #fff;
    }

    .button-outline {
        background: #fff;
        color: var(--theme-color-main-dark);
        border-color: var(--theme-color-main-dark);
    }

    .button-outline:hover {
        background: var(--theme-color-main-dark);
        color: #fff;
    }

    .action-button:focus {
        box-shadow: none !important;
    }

    .button-group .action-button {
        border-radius: 0;
    }

    .action-button--outline-dark {
        color: var(--theme-color-dark-prev);
        border-color: var(--theme-color-dark-prev);
    }

    .action-button--outline-dark:hover,
    .action-button--outline-dark:not(:disabled):not(.disabled):active,
    .action-button--outline-dark:not(:disabled):not(.disabled).active {
        color: #fff;
        background-color: var(--theme-color-dark-prev);
    }
}
