/**** Modal ============================= */
:root {
    --brand: #0075CF;
    --brand-dark: #0062B8;
}

.show--desktop--warranty {
    display: block;
}

.show--mobile--warranty {
    display: none;
}

.bg-brand {
    background-color: var(--brand);
    color: #fff;
}

.modal-drawer {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .45);
    overflow: hidden;
    opacity: 0;
    pointer-events: none;
    transition: opacity .35s ease;
    z-index: 1050;
}

.modal-drawer.show {
    opacity: 1;
    pointer-events: auto;
}

.modal-drawer .modal-dialog {
    position: absolute;
    top: 0;
    right: 0;
    height: 100%;
    width: 90%;
    max-width: 420px;
    margin: 0;
    transform: translateX(100%);
    transition: transform .35s ease;
    display: flex;
    flex-direction: column;
}

.modal-drawer.show .modal-dialog {
    transform: translateX(0);
}

.modal-drawer .modal-content {
    border: 0;
    border-radius: 0;
    box-shadow: 0 0 18px rgba(0, 0, 0, .5);
    height: 100%;
    display: flex;
    flex-direction: column;
    background-color: white;
    z-index: 999;
}

.brand-gradient {
    background: linear-gradient(135deg, var(--brand), var(--brand-dark));
}

.modal-drawer .modal-header {
    border: 0;
    padding: 1rem 1.25rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    text-align: center;
    color: white;
    font-weight: bold;
}

.modal-drawer .modal-footer {
    border-top: 1px solid #e5e5e5;
    padding: 1rem 1.25rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6%;
}

.modal-drawer .modal-body {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: 1.25rem;
}

.modal-drawer .service-options-group {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: .75rem;
    margin-top: 46px;
}

.modal-drawer .rw-option-tile {
    cursor: pointer;
    transition: transform .15s, box-shadow .15s;
}

.modal-drawer .rw-option-tile:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, .12);
}

.modal-drawer .tile-inner {
    display: block;
    padding: .75rem .5rem;
    border: 2px solid var(--brand);
    border-radius: 10px;
    text-align: center;
    font-weight: 600;
    color: var(--brand);
}

.modal-drawer .rw-option-tile input:checked+.tile-inner {
    background: var(--brand);
    color: #fff !important;
}

.modal-drawer .modal--price input:checked+.tile-inner {
    background: var(--brand);
    color: #fff;
}

/**** BTN CHECKED =========================================== */

.service-type-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.service-option input[type="checkbox"]:checked+.option-content {
    background: #0075CF !important;
    color: #fff !important;
    border-color: #0075CF !important;
}


/** BTNs ===================================================== */
.ensurance_btn,
.installation_btn {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    opacity: 0;
    cursor: pointer;
    z-index: 2;
}


@media screen and (max-width:390px) {

    .option-content {
        justify-content: center;
        gap: 3%;
        font-size: 14px !important;
    }

}


@media screen and (max-width: 600px) {
    .modal-drawer .modal-dialog {
        max-width: none !important;
        width: 100%;
    }

    .show--desktop--warranty {
        display: none;
    }

    .show--mobile--warranty {
        display: block;
    }

    .modal-drawer .service-options-group {
        margin-top: 32px;
    }



    .modal-drawer .modal-footer {
        border-top: 1px solid #e5e5e5;
        padding: 1rem 1.25rem;
        display: flex;
        justify-content: space-between;
        align-items: center;
        width: 100%;
        gap: 1em;
        text-decoration: underline;
    }

    .modal-drawer .modal-header {
        border: 0;
        padding: 1rem 1.25rem;
        display: flex;
        align-items: center;
        justify-content: space-between;
        text-align: center;
        color: #fff;
        font-weight: 700;
        width: 100%;
    }
}


@keyframes shake {
    0% {
        transform: translateX(0);
    }

    20% {
        transform: translateX(-8px);
    }

    40% {
        transform: translateX(8px);
    }

    60% {
        transform: translateX(-8px);
    }

    80% {
        transform: translateX(8px);
    }

    100% {
        transform: translateX(0);
    }
}

.shake {
    animation: shake 0.5s ease;
}

.warranty-error {
    color: #d00;
    font-size: 12px;
    text-align: center;
    margin-top: 0.5rem;
}


.service-option input[type="checkbox"]:checked+.option-content {
    background: var(--brand) !important;
    color: #fff !important;
    border-color: var(--brand) !important;
}



.installation-error {
    color: #d00;
    font-size: 12px;
    text-align: center;
    margin-top: .5rem;
}

@media (max-width: 600px) {
    .modal-drawer .modal-dialog {
        max-width: none !important;
        width: 100%;
    }

    .modal-drawer .service-options-group {
        margin-top: 32px;
    }

    .show--desktop--warranty {
        display: none;
    }

    .show--mobile--warranty {
        display: block;
    }
}

.service--info {
    color: #fff;
    background: var(--brand);
    border-radius: 50%;
    font-size: 16px;
}