/* ==========================================================================
   STORE DESTRUCTIVE DIALOGS — address deletion and desktop/mobile account deactivation
   Views: stores/delete_address.php and customers/remove_account_modal.php
   JS: address_modal.js and profile_modal.js (holders appended to body)
   ========================================================================== */

body.address-delete-modal-open {
    overflow: hidden;
}

.address-delete-modal-holder,
body.customers-my_profile-page > .profile-modal-holder,
body.page-profile > .profile-modal-holder {
    position: fixed;
    inset: 0;
    z-index: 10060;
}

.address-delete-modal-holder .bg {
    display: none;
}

.address-delete-modal-holder .address-delete-modal {
    display: none;
    z-index: 1;
}

.address-delete-modal-holder .address-delete-modal,
body.customers-my_profile-page > .profile-modal-holder,
body.page-profile > .profile-modal-holder {
    position: fixed;
    inset: 0;
    padding: 24px 16px;
    overflow-x: hidden;
    overflow-y: auto;
    background: rgba(0, 0, 0, 0.62);
    box-sizing: border-box;
}

.address-delete-modal-holder .address-delete-modal-content,
body.customers-my_profile-page > .profile-modal-holder .profile-modal-content,
body.page-profile > .profile-modal-holder .profile-modal-content {
    width: min(560px, 100%);
    margin: 32px auto;
    background: #ffffff;
    border: 0;
    border-radius: 18px;
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.22);
    overflow: hidden;
}

.address-delete-modal-holder .delete-address-panel {
    display: flex;
    flex-direction: column;
}

.address-delete-modal-holder .delete-address-map-wrap {
    position: relative;
    flex: 0 0 auto;
}

.address-delete-modal-holder #addressDeleteMap,
.address-delete-modal-holder .delete-address-map {
    width: 100%;
    height: 360px;
    min-height: 280px;
    background: #f3f3f3;
}

.address-delete-modal-holder .delete-address-map--empty {
    display: flex;
    align-items: center;
    justify-content: center;
}

.address-delete-modal-holder .delete-address-map__placeholder {
    font-family: Roboto, system-ui, -apple-system, sans-serif;
    font-size: 14px;
    color: #888888;
}

.address-delete-modal-holder .delete-address-close {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: #ffffff;
    color: #1a1a1a;
    font-size: 22px;
    line-height: 1;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18);
    cursor: pointer;
    transition: background-color 0.18s ease, opacity 0.18s ease;
}

.address-delete-modal-holder .delete-address-close:hover {
    background: #f7f7f7;
}

.address-delete-modal-holder .delete-address-close:focus-visible {
    outline: 2px solid #1a1a1a;
    outline-offset: 2px;
}

.address-delete-modal-holder .delete-address-body,
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons,
body.page-profile > .profile-modal-holder .remove-account-reasons {
    flex: 1 1 auto;
    padding: 32px 36px 36px;
    box-sizing: border-box;
}

.address-delete-modal-holder .delete-address-title,
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .title-modal,
body.page-profile > .profile-modal-holder .remove-account-reasons .title-modal {
    margin: 0 0 18px;
    font-family: Roboto, system-ui, -apple-system, sans-serif;
    font-size: 24px;
    font-weight: 700;
    line-height: 1.3;
    color: #1a1a1a;
}

.address-delete-modal-holder .delete-address-text {
    margin: 0 0 28px;
}

.address-delete-modal-holder .delete-address-text p,
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons,
body.page-profile > .profile-modal-holder .remove-account-reasons,
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons #form-remove-account > p,
body.page-profile > .profile-modal-holder .remove-account-reasons #form-remove-account > p,
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .buttons-modal > p,
body.page-profile > .profile-modal-holder .remove-account-reasons .buttons-modal > p {
    margin: 0;
    font-family: Roboto, system-ui, -apple-system, sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.55;
    color: #1a1a1a;
}

.address-delete-modal-holder .delete-address-text strong {
    font-weight: 700;
}

.address-delete-modal-holder .delete-address-actions,
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .buttons-modal,
body.page-profile > .profile-modal-holder .remove-account-reasons .buttons-modal {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 16px;
}

.address-delete-modal-holder .delete-address-btn,
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .confirm-remove-account-btn,
body.page-profile > .profile-modal-holder .remove-account-reasons .confirm-remove-account-btn,
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .btn-close-modal,
body.page-profile > .profile-modal-holder .remove-account-reasons .btn-close-modal {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    margin: 0;
    padding: 13px 32px;
    border: 0;
    border-radius: 10px;
    font-family: Roboto, system-ui, -apple-system, sans-serif;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    white-space: nowrap;
    cursor: pointer;
    transition: background-color 0.18s ease, color 0.18s ease, opacity 0.18s ease;
    -webkit-appearance: none;
    appearance: none;
}

.address-delete-modal-holder .delete-address-btn--confirm {
    background: #fff0ec;
    color: #e33e26;
}

.address-delete-modal-holder .delete-address-btn--confirm:hover {
    background: #ffe4dc;
}

.address-delete-modal-holder .delete-address-btn--cancel,
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .confirm-remove-account-btn,
body.page-profile > .profile-modal-holder .remove-account-reasons .confirm-remove-account-btn {
    background: #e33e26;
    color: #ffffff;
}

.address-delete-modal-holder .delete-address-btn--cancel:hover,
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .confirm-remove-account-btn:hover,
body.page-profile > .profile-modal-holder .remove-account-reasons .confirm-remove-account-btn:hover {
    background: #c93620;
}

.address-delete-modal-holder .delete-address-btn:focus-visible,
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .confirm-remove-account-btn:focus-visible,
body.page-profile > .profile-modal-holder .remove-account-reasons .confirm-remove-account-btn:focus-visible,
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .btn-close-modal:focus-visible,
body.page-profile > .profile-modal-holder .remove-account-reasons .btn-close-modal:focus-visible,
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .remove-account-reason-checbox:focus-visible,
body.page-profile > .profile-modal-holder .remove-account-reasons .remove-account-reason-checbox:focus-visible,
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .remove-account-reason-text:focus-visible,
body.page-profile > .profile-modal-holder .remove-account-reasons .remove-account-reason-text:focus-visible {
    outline: 2px solid #1a1a1a;
    outline-offset: 2px;
}

/* The account form retains its original DOM, serialization and JS lifecycle. */
body.customers-my_profile-page > .profile-modal-holder .profile-modal-content,
body.page-profile > .profile-modal-holder .profile-modal-content,
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .confirm-remove-account-btn,
body.page-profile > .profile-modal-holder .remove-account-reasons .confirm-remove-account-btn,
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .btn-close-modal,
body.page-profile > .profile-modal-holder .remove-account-reasons .btn-close-modal {
    box-sizing: border-box;
}

/* Match the account-page trigger's base type and its desktop override below. */
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .confirm-remove-account-btn,
body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .btn-close-modal {
    font-family: var(--profile-font);
    font-size: 14px;
}

/* Match the mobile profile trigger at every mobile-presentation width. */
body.page-profile > .profile-modal-holder .remove-account-reasons .confirm-remove-account-btn,
body.page-profile > .profile-modal-holder .remove-account-reasons .btn-close-modal {
    font-family: 'Magra', sans-serif;
    font-size: 14px;
}

body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .btn-close-modal,
body.page-profile > .profile-modal-holder .remove-account-reasons .btn-close-modal {
    background: #A6A6A6;
    color: #ffffff;
}

body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .btn-close-modal:hover,
body.page-profile > .profile-modal-holder .remove-account-reasons .btn-close-modal:hover {
    background: #757575;
}

body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons,
body.page-profile > .profile-modal-holder .remove-account-reasons {
    text-align: left;
    overflow-wrap: anywhere;
}

body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .options-modal,
body.page-profile > .profile-modal-holder .remove-account-reasons .options-modal {
    margin: 0;
}

body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons #form-remove-account,
body.page-profile > .profile-modal-holder .remove-account-reasons #form-remove-account {
    display: grid;
    grid-template-columns: 18px minmax(0, 1fr);
    column-gap: 10px;
    row-gap: 10px;
    margin: 0;
}

body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons #form-remove-account > p,
body.page-profile > .profile-modal-holder .remove-account-reasons #form-remove-account > p {
    grid-column: 1 / -1;
    margin-bottom: 2px; /* Together with the row gap: 12px before reasons. */
}

body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons #form-remove-account > br,
body.page-profile > .profile-modal-holder .remove-account-reasons #form-remove-account > br {
    display: none;
}

body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .remove-account-reason-checbox,
body.page-profile > .profile-modal-holder .remove-account-reasons .remove-account-reason-checbox {
    grid-column: 1;
    align-self: start;
    width: 18px;
    height: 18px;
    margin: 3px 0 0;
    accent-color: #e33e26;
    cursor: pointer;
}

body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons #form-remove-account > label,
body.page-profile > .profile-modal-holder .remove-account-reasons #form-remove-account > label {
    grid-column: 2;
    min-width: 0;
    margin: 0;
    cursor: pointer;
}

body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons #form-remove-account > .label-new-reason,
body.page-profile > .profile-modal-holder .remove-account-reasons #form-remove-account > .label-new-reason {
    grid-column: 1 / -1;
    margin-top: 6px; /* Together with the row gap: 16px before other reason. */
}

body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .remove-account-reason-text,
body.page-profile > .profile-modal-holder .remove-account-reasons .remove-account-reason-text {
    grid-column: 1 / -1;
    box-sizing: border-box;
    width: 100%;
    min-width: 0;
    min-height: 44px;
    margin: 0;
    padding: 10px 12px;
    border: 1px solid #d4d4d4;
    border-radius: 8px;
    font: inherit;
    color: inherit;
}

body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .error-msg-remove-account,
body.page-profile > .profile-modal-holder .remove-account-reasons .error-msg-remove-account {
    margin: 0 0 12px;
    font-size: 14px;
    line-height: 1.45;
    color: #c62828;
}

body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .error-msg-remove-account:empty,
body.page-profile > .profile-modal-holder .remove-account-reasons .error-msg-remove-account:empty {
    display: none;
}

body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .buttons-modal,
body.page-profile > .profile-modal-holder .remove-account-reasons .buttons-modal {
    margin-top: 24px;
}

body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .buttons-modal > p,
body.page-profile > .profile-modal-holder .remove-account-reasons .buttons-modal > p {
    flex: 0 0 100%;
    min-width: 0;
    margin: 0; /* The shared action gap supplies 16px before the buttons. */
    font-weight: 500;
}

@media (max-width: 480px) {
    .address-delete-modal-holder .address-delete-modal,
    body.customers-my_profile-page > .profile-modal-holder,
    body.page-profile > .profile-modal-holder {
        padding: 16px 12px;
    }

    .address-delete-modal-holder .address-delete-modal-content,
    body.customers-my_profile-page > .profile-modal-holder .profile-modal-content,
    body.page-profile > .profile-modal-holder .profile-modal-content {
        margin: 24px auto;
        border-radius: 14px;
    }

    .address-delete-modal-holder #addressDeleteMap,
    .address-delete-modal-holder .delete-address-map {
        height: 280px;
    }

    .address-delete-modal-holder .delete-address-body,
    body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons,
    body.page-profile > .profile-modal-holder .remove-account-reasons {
        padding: 24px 22px 28px;
    }

    .address-delete-modal-holder .delete-address-title,
    body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .title-modal,
    body.page-profile > .profile-modal-holder .remove-account-reasons .title-modal {
        font-size: 20px;
    }

    .address-delete-modal-holder .delete-address-text p,
    body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons,
    body.page-profile > .profile-modal-holder .remove-account-reasons,
    body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons #form-remove-account > p,
    body.page-profile > .profile-modal-holder .remove-account-reasons #form-remove-account > p,
    body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .buttons-modal > p,
    body.page-profile > .profile-modal-holder .remove-account-reasons .buttons-modal > p {
        font-size: 15px;
    }

    .address-delete-modal-holder .delete-address-actions,
    body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .buttons-modal,
    body.page-profile > .profile-modal-holder .remove-account-reasons .buttons-modal {
        flex-direction: column;
        align-items: stretch;
    }

    .address-delete-modal-holder .delete-address-btn,
    body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .confirm-remove-account-btn,
    body.page-profile > .profile-modal-holder .remove-account-reasons .confirm-remove-account-btn,
    body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .btn-close-modal,
    body.page-profile > .profile-modal-holder .remove-account-reasons .btn-close-modal {
        width: 100%;
    }

    body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .buttons-modal > p,
    body.page-profile > .profile-modal-holder .remove-account-reasons .buttons-modal > p {
        flex-basis: auto;
    }
}

@media (min-width: 992px) {
    body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .confirm-remove-account-btn,
    body.customers-my_profile-page > .profile-modal-holder .remove-account-reasons .btn-close-modal {
        font-family: 'Magra', sans-serif;
        font-size: 16px;
    }
}
