/* Main styles */

/* Base styles */
body {
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    margin: 0;
    padding: 0;
    overflow: hidden;
}

/* Layout */
.container {
    max-width: 100%;
    margin: 0;
    padding: 0;
}

/* Header */
header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 50;
    background-color: var(--bg-primary);
    border-bottom: 1px solid var(--border-color);
}

/* Main content */
main {
    padding-top: 4rem;
    height: calc(100vh - 4rem);
    background-color: var(--bg-secondary);
    overflow: hidden;
}

/* Preview container */
#mermaid-preview {
    width: 100%;
    height: 100%;
    overflow: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.mermaid-svg-container {
    min-width: 100%;
    min-height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.mermaid-svg-container svg {
    max-width: none;
    max-height: none;
    width: auto;
    height: auto;
}

/* Draggable flowchart elements */
.node {
    transition: transform 0.1s ease;
}

.node:hover {
    filter: brightness(1.1);
}

.node:active {
    filter: brightness(0.95);
}

/* Edge animations */
.edgePath {
    transition: d 0.1s ease;
}

/* Editor container */
#code-editor-container {
    position: fixed;
    bottom: 1rem;
    right: 1rem;
    width: 600px;
    border-radius: 0.5rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    z-index: 40;
}

/* Editor header */
#editor-header {
    padding: 0.75rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Editor content */
#editor-content {
    height: 400px;
}

/* Buttons */
button {
    padding: 0.5rem;
    border-radius: 0.375rem;
    transition: all 0.2s ease;
}

button:hover {
    background-color: var(--bg-secondary);
}

/* Export dropdown */
.export-dropdown {
    position: absolute;
    right: 0;
    top: 100%;
    margin-top: 0.5rem;
    background-color: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 0.375rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    display: none;
}

.export-dropdown.show {
    display: block;
}

/* Toast notifications */
.toast {
    position: fixed;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    padding: 0.75rem 1rem;
    border-radius: 0.375rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    z-index: 100;
}

/* Loading spinner */
.loading-spinner {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
} 