﻿.dialog-header {
    margin-bottom: 15px;
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5); /* Grey transparent background */
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.dialog {
    background: white; /* White pop-up background */
    padding: 20px;
    border-radius: 5px;
    min-width: 50%;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    max-height: 80vh;
    height: 70vh;
    display: flex;
    flex-direction: column;
}

.dialog-buttons {
    text-align: right;
}

.validation-message {
    color: #dc3545;
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

/* for the editor */
.ql-toolbar .ql-active {
    background-color: green !important;
    color: red !important;
}

body, html {
    margin: 0;
    padding: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
}

#editor {
    height: 80%; /* 60% of the dialog's height */
    min-height: 200px; /* Optional: set a minimum height */
    border: 1px solid #ccc;
    flex: 1 1 auto; /* Allow it to grow/shrink if needed */
}

.rz-steps .rz-widget-content {
    overflow-x: visible !important;
    overflow-y: visible !important;
}

.ql-snow .ql-tooltip {
    z-index: 99999;
}

/* Formula Editor Centering Fix */
.ql-tooltip[data-mode="formula"] {
    position: fixed !important;
    left: 50% !important;
    top: 50% !important;
    transform: translate(-50%, -50%) !important;
    z-index: 9999 !important;
    width: auto !important;
    min-width: 320px !important;
    max-width: 90vw !important;
    max-height: 90vh !important;
    overflow-y: visible !important; /* Change from auto to visible */
    box-shadow: 0 5px 10px rgba(0,0,0,0.2) !important;
    background-color: white !important;
    padding: 10px !important;
    border-radius: 4px !important;
}


/* Better input field */
/* .ql-tooltip[data-mode="formula"] input[type=text].mathquill4quill-latex-input {
        width: 100% !important;
        padding: 8px !important;
        margin: 8px 0 !important;
        border: 1px solid #ccc !important;
        border-radius: 4px !important;
        } */

/* Operator buttons */
.mathquill4quill-operator-container {
    max-height: 60vh;
    overflow-y: auto;
    padding: 0 5px;
}

/* Category styling */
.mathquill4quill-operator-category {
    font-weight: bold;
    margin-top: 10px;
    margin-bottom: 5px;
    color: #555;
}

/* Button container */
.mathquill4quill-button-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
}

/* Individual buttons */
.mathquill4quill-operator-button {
    margin: 3px !important;
    background: #f5f5f5 !important;
    border: 1px solid #ddd !important;
    border-radius: 4px !important;
    box-shadow: 0 1px 2px rgba(0,0,0,0.1) !important;
    transition: all 0.2s ease !important;
}

    .mathquill4quill-operator-button:hover {
        background: #e9e9e9 !important;
    }
