﻿/*!
 * WellFrame Web Library
 *
 * Copyright (©) Wellcode Software owned by Khamis Abuelkomboz
 *
 * ALL RIGHTS RESERVED, see http://wellcode.de
 *
 */
/*
 dialog Box
*/

.dialogbox {
    position: fixed;
    display: grid;
    grid-template-rows: max-content auto max-content;
    overflow: auto;
    top: 0px;
    left: 0px;
    right: 0px;
    bottom: 0px;
    margin: auto; /*center of screen*/
    padding: 10px;
    min-width: 50%;
    max-width: 500px;
    min-height: 200px;
    max-height: 60%;
    border: 1px groove;
    border-radius: 5px;
    background-color: var(--wf-dialog-bgcolor);
}

.bigdialog {
    min-width: unset;
    max-width: unset;
    max-height: unset;
    top: 50px;
}

.bigdialog .docviewer {
    height: calc(100% - 8px);
}

.widedialog {
    min-width: unset;
    max-width: unset;
    top: 50px;
}

#overlay,
.editpage-overlay {
    position: fixed;
    /*z-index: 199; is set using js */
    top: 0px;
    left: 0px;
    height: 100%;
    width: 100%;
    text-align: center;
    background-color: black;
    opacity: 0.10;
}

.askbox {
    background-color: var(--wf-ask-bgcolor);
}

.askbox2 div.dialog-message {
    white-space: pre-wrap;
}

.dialog-header .commands {
    position: absolute;
    right: 0px;
    bottom: 0px;
    display: none;
}

.errorbox {
    background-color: var(--wf-error-bgcolor);
}

.dialog-header {
    position: relative;
    overflow: auto;
}

@media screen and (min-width: 641px) {
    .dialogbox:hover .dialog-header .commands {
        display: block;
    }
}

.dialog-title {
    width: 100%;
}

.dialog-subtitle {
    width: 100%;
}

.dialog-message-div {
    position: relative;
    top: 0px;
    left: 0px;
    width: 100%;
    padding-left: 0px;
    padding-right: 0px;
    padding-top: 10px;
    padding-bottom: 10px;
    overflow: auto;
    min-height: 200px;
}

.dialog-message {
    position: relative;
    width: calc(100% - 10px);
    overflow: auto;
    background-color: white;
    padding: 5px;
    height: calc(100% - 10px);
}

.dialog-commands-div {
    position: relative;
    width: 100%;
}

.dialog-commands {
    position: relative;
    left: 0px;
    right: 0px;
    margin: auto;
    font-size: large;
}

.dialog-ok {
    position: relative;
    font-size: large;
    min-width: 80px;
    margin-right: 5px;
}

/*
    Phone
*/
@media screen and (max-width: 640px) {
    .dialogbox .dialog-header .commands {
        display: block;
    }

    .dialogbox {
        top: 0px;
        left: 0px;
        right: 0px;
        bottom: 0px;
        margin: auto; /*center of screen*/
        padding: 5px;
        min-width: unset;
        max-width: 100%;
        height: auto;
        width: auto;
        min-height: unset;
        max-height: calc(100% - 72px);
        border: 1px groove;
        border-radius: 5px;
        /*background-color: lightslategrey;*/
        /*z-index: 3; is set using js*/
    }


    .dialogbox {
        box-shadow: 0px 0px 30px 10px darkgray;
    }
}
