﻿@import url('design-tokens-css/semantic-tokens.css');

/* Primary Dialog Button */
.btn-dialog-primary-ds {
    background: var(--mds-color-brand-bay-blue-1000) !important;
    color: var(--mds-color-utility-base-white) !important;
    border: 2px solid var(--mds-color-brand-bay-blue-1000) !important;
    line-height: 120%;
}

.btn-popup {
    font: var(--mds-text-body-bold);
    padding: 10px 20px;
    border-radius: 8px;
    border: 2px solid transparent;
    cursor: pointer;
    /*width: 140px;*/
}
    /* Hover */
    .btn-dialog-primary-ds:hover {
        background: var(--mds-color-brand-bay-blue-1000) !important;
        border-color: var(--mds-color-brand-bay-blue-1000) !important;
        color: var(--mds-color-utility-base-white);
    }

    /* Active */
    .btn-dialog-primary-ds:active {
        opacity: 0.9;
    }

    /* Focus */
    .btn-dialog-primary-ds:focus {
        outline: 2px solid var(--mds-color-utility-focus-blue-600) !important;
        outline-offset: 2px;
    }

    /* Disabled */
    .btn-dialog-primary-ds:disabled {
        background: var(--mds-color-brand-gray-200);
        border-color: var(--mds-color-brand-gray-200);
        color: var(--mds-color-brand-gray-700);
        cursor: not-allowed;
    }


/* Secondary Dialog Button */
.btn-dialog-secondary-ds {
    background: var(--mds-color-brand-gray-100) !important;
    color: var(--mds-color-brand-bay-blue-1000) !important;
    border: 2px solid var(--mds-color-brand-bay-blue-1000) !important;
    line-height: 120%;
}

    /* Hover */
    .btn-dialog-secondary-ds:hover {
        background: var(--mds-color-brand-bay-blue-1000) !important;
        border-color: var(--mds-color-brand-bay-blue-1000) !important;
        color: var(--mds-color-utility-base-white) !important;
    }

    /* Active */
    .btn-dialog-secondary-ds:active {
        opacity: 0.9;
    }

    /* Focus */
    .btn-dialog-secondary-ds:focus {
        outline: 2px solid var(--mds-color-utility-focus-blue-600) !important;
        outline-offset: 2px;
    }

    /* Disabled */
    .btn-dialog-secondary-ds:disabled {
        background: var(--mds-color-brand-gray-100) !important;
        border-color: var(--mds-color-brand-gray-700);
        color: var(--mds-color-brand-gray-700);
        cursor: not-allowed;
    }

.form-actions-dialog {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-top: 8px;
}

.modal-dialog-close {
    position: absolute;
    top: 12px;
    right: 12px;
    cursor: pointer;
}

    .modal-dialog-close:focus {
        outline: none;
        box-shadow: 0 0 0 1px var(--mds-color-utility-base-white), 0 0 0 3px var(--mds-color-utility-focus-blue-600);
    }

.modal-icon {
    display: flex;
    justify-content: center;
}

.alert-icon-ds {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: var(--mds-color-brand-bay-blue-1000);
    padding: 18px;
}

    .alert-icon-ds img {
        width: 24px;
        height: 24px;
    }

    .alert-icon-ds svg {
        width: 24px;
        height: 24px;
        flex-shrink: 0;
    }

.modal-dialog {
    width: 560px;
    max-width: 90vw;
    margin: auto;
}

.modal-content {
    padding: 20px;
    border-radius: 8px;
}

.modal-title {
    font-weight: 600;
    font-size: 16px;
}

.modal-body {
    font-size: 14px;
    color: #333;
    line-height: 1.5;
}

#globalAlertModal {
    z-index: 2000; /* higher than any other modal */
}

.modal-backdrop.global-alert-backdrop {
    z-index: 1999; /* just below the alert modal */
}

/* ── Global Alert & Confirm Modal Backdrop ── */
#globalAlertModal.modal.show ~ .modal-backdrop,
#globalConfirmModal.modal.show ~ .modal-backdrop {
    background-color: #000000 !important;
    opacity: 0.6 !important;
}

/* ── Extend edge to edge ── */
#globalAlertModal .modal-backdrop,
#globalConfirmModal .modal-backdrop {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    z-index: 1040 !important;
}