dialog {
    width: 90%;
    max-width: 430px;
    max-height: 80vh;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    border: none;
    border-radius: 10px;
    box-shadow: var(--box-shadow);
    outline: none;
    background-color: white;
    margin: 12vh auto auto auto;
    padding: 30px;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1),
    opacity .25s ease-out,
    overlay .3s allow-discrete,
    display .3s allow-discrete;
    opacity: 1;
    transform: translateY(0) scale(1);

    div.head {
        display: flex;
        justify-content: space-between;
        margin-bottom: 20px;

        div {
            text-transform: uppercase;
            font-weight: var(--font-weight-heavy);
            color: var(--color-primary);
        }

        span {
            font-size: 24px;
            line-height: .6;
            color: var(--color-text);
            cursor: pointer;
            transition: .2s;
        }

        span:hover {
            color: var(--color-primary);
        }
    }

    div.body {
        text-align: justify;
        outline: none;

        div.scrollBox {
            max-height: 60vh;
            overflow-x: hidden;
            overflow-y: auto;
            outline: none;
        }
    }

    div.footer {
        display: flex;
        gap: 15px;
        margin-top: 20px;

        button {
            flex: 1;
        }
    }
}

dialog.medium {
    max-width: 650px;
}

dialog.large {
    max-width: 900px;
}

dialog.close {
    div.head {
        div {
            margin-right: 10px;
        }
    }
}

@starting-style {
    dialog[open] {
        opacity: 0;
        transform: translateY(20px) scale(0.9);
    }
}

dialog:not([open]) {
    display: none;
    opacity: 0;
    transform: translateY(-10px) scale(0.96);
}

dialog::backdrop {
    background-color: rgba(43, 45, 66, 0);
    backdrop-filter: blur(0px);
    transition: background-color .3s ease,
    backdrop-filter .3s ease,
    overlay .3s allow-discrete,
    display .3s allow-discrete;
}

dialog[open]::backdrop {
    background-color: rgba(43, 45, 66, 0.3);
    backdrop-filter: blur(4px);
}

@starting-style {
    dialog[open]::backdrop {
        background-color: rgba(43, 45, 66, 0);
        backdrop-filter: blur(0px);
    }
}