body{
    container-type: inline-size;
    container-name: main-body; /* optionnel, utile si tu imbriques plusieurs containers */
}
.wrapper:has(.hmtsam-subscription-form){
    border: 1px solid grey;
    border-radius: 5px;
    box-shadow: 0 10px 30px rgba(11, 74, 139, 0.06);
    padding-block: .7rem;
}
.hmtsam-subscription-form{
    min-height: 600px;
    fieldset{
        display: flex!important;
        gap: .7rem;
        flex-wrap: wrap;
        width: 100%;
    }
    div{
        display: flex;
        flex-direction: column;
        flex: 1;
    }
    label{
        padding-left: .3rem;
        margin-block: 1rem;
        display: block;

    }
    label:has(~ input[required])::after{
        content: " ";
        background-color: #538ACC;
        border-radius: 0 .3rem 0 .3rem;
        width: .5rem;
        height: .5rem;
        display: inline-block;
        margin-left: 2px;
        transform: translateY(-.5rem);
    }
    input{
        width: -webkit-fill-available;
        padding: .4rem;
        border-radius: 7px;
        min-height: 1rem;
        border: 1px solid rgb(13 95 195);
        box-shadow: 0px 0px 0px 0px rgba(83,138,204,.1);
        -webkit-box-shadow: 0px 0px 0px 0px rgba(83,138,204,.1);
        transition: all .2s;
        margin-bottom: 1rem;
    }
    .hmtsam-password-strength-meter{
    }
    .hmtsam-password-strength-meter[data-score="0"]{
        color: red;
    }
    .hmtsam-password-strength-meter[data-score="1"]{
        color: #bd4e4e;
    }
    fieldset:has(.hmtsam-password-strength-meter[data-score="0"]) ~ fieldset label,fieldset:has(.hmtsam-password-strength-meter[data-score="1"]) ~ fieldset label{
        color: red;
    }
    .hmtsam-password-strength-meter[data-score="2"]{
        color: #c87633;
        ~ fieldset label{
            color: unset;
        }
    }
    .hmtsam-password-strength-meter[data-score="3"]{
        color: #0d5fc3;
        ~ fieldset label{
            color: unset;
        }
    }
    .hmtsam-password-strength-meter[data-score="4"]{
        color: #20a331;
        ~ fieldset label{
            color: unset;
        }
    }
    div:has(input:user-invalid) > label{
        color: red;
    }
    input:user-invalid{
        background-color: rgb(255 218 218 / 0.6) !important;
    }
    input:invalid{
        background-color: unset;
    }
    input:focus{

        box-shadow: 0px 0px 50px 14px rgba(83,138,204,.2);
            -webkit-box-shadow: 0px 0px 50px 14px rgba(83,138,204,.2);
    }
    .hmtsam-password-strength-meter, div.hmtsam-password-again-label{
        display: flex;
        flex: 1;
        padding-left: .3rem;

    }
    div.hmtsam-password-again-label{
        color: red;
    }
    input[type="submit"]{
        max-width: 300px;
        background-color: white;
        border: #0a7aff solid 1px;
        color: #0a7aff;
        margin-left: auto;
        display: block;
        :hover{
            background-color: #0a7aff;
            color: white;
        }
    }
    input[type="submit"]:hover{
        background-color: #538ACC;
        color: white;
    }
    input[type="email"]{
        flex: 1;
    }
    .hmtsam_cgv_check_container{
        display: flex;
        label{
            display: flex;
            gap: .7rem;
            align-items: center
        }
        input{
            width: fit-content;
        }

    }
    input[type="checkbox"]{
        aspect-ratio: 1;
        width: 1.8rem;
        height: 1.8rem;
        margin-bottom: 0px;
        appearance: none;
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 2px!important;
    }
    input[type="checkbox"]:checked::after{
        content: "";
        background-color: #0a7aff;
        height: 100%;
        width: 100%;
        transform: scale(1);
        transition: transform .12s ease-in-out;
        display: block;
        border-radius: .2rem;
        animation: bubbles .2s;
    }
    input[type="checkbox"]::after{
        content: "";
        background-color: #0a7aff;
        height: 1rem;
        width: 1rem;
        border-radius: 2px;
        transform: scale(0);
        transition: transform .12s ease-in-out;
        display: block;

    }
}
@keyframes bubbles {
    0% {
        opacity: 0;
        transform: scale(0.8);
    }
    65% {
        opacity: 1;
        transform: scale(1.06);
    }
    85% {
        transform: scale(0.98);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }

}
.hmtsam-header-selection{
    display: flex;
    gap: .7rem;
    button{
        background-color: white;
        padding:.4rem;
        min-height: 1rem;
        border: 1px solid rgb(13 95 195);
        color: rgb(13 95 195);
        border-radius: 7px;

    }
    button[data-active]{
        background-color: #538ACC;
        color: white;
        border-color: #538ACC;
    }
    button:nth-of-type(2){

    }
}
.hmtsam-subscription-error[data-show]{
    background-color: #538ACC;
    color: white;
    padding: .7rem;
    width: fit-content;
    max-width: 600px;
    margin: .7rem;
    margin-inline: auto;
    border-radius: 12px;
}
.hmtsam-subscription-error[data-animate]{
    animation: error_showing 0.42s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
}
@keyframes error_showing {
    0%, 100% {
        transform: translateX(0);
    }
    15%, 45%, 75% {
        transform: translateX(-8px);
    }
    30%, 60%, 90% {
        transform: translateX(8px);
    }
}
