/* Brilliance Rich Text Editor Custom Styles */
.brilliance-rte-wrapper {
    width: 100%;
    border-radius: 8px;
    overflow: hidden;
}

.brilliance-rte-wrapper .e-richtexteditor {
    border: 1px solid #D2D2D7;
    border-radius: 8px;
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Segoe UI', system-ui, sans-serif;
}

.brilliance-rte-wrapper .e-richtexteditor .e-rte-toolbar {
    background-color: #F5F5F7;
    border-bottom: 1px solid #D2D2D7;
    padding: 8px;
}

.brilliance-rte-wrapper .e-richtexteditor .e-rte-content {
    background-color: #FFFFFF;
    font-size: 14px;
    line-height: 1.6;
    color: #1D1D1F;
}

.brilliance-rte-wrapper .e-richtexteditor .e-rte-content .e-content {
    padding: 16px;
}

.brilliance-rte-wrapper .e-richtexteditor .e-toolbar-item .e-btn {
    border-radius: 6px;
    transition: all 0.2s ease;
}

.brilliance-rte-wrapper .e-richtexteditor .e-toolbar-item .e-btn:hover {
    background-color: #E8E8ED;
}

.brilliance-rte-wrapper .e-richtexteditor .e-toolbar-item .e-btn.e-active {
    background-color: #007AFF;
    color: #FFFFFF;
}

/* Drag and Drop Paragraph Styles */
.brilliance-rte-wrapper .e-richtexteditor .e-rte-content p {
    position: relative;
    padding-left: 24px;
}

.brilliance-rte-wrapper .e-richtexteditor .e-rte-content p:hover::before {
    content: '⋮⋮';
    position: absolute;
    left: 4px;
    top: 50%;
    transform: translateY(-50%);
    color: #86868B;
    font-size: 16px;
    cursor: grab;
    line-height: 1;
}

.brilliance-rte-wrapper .e-richtexteditor .e-rte-content p.dragging {
    opacity: 0.5;
    cursor: grabbing;
}

/* Table Quick Insert Styles */
.brilliance-rte-wrapper .e-richtexteditor .e-rte-content table {
    border-collapse: collapse;
    width: 100%;
    margin: 16px 0;
}

.brilliance-rte-wrapper .e-richtexteditor .e-rte-content table td,
.brilliance-rte-wrapper .e-richtexteditor .e-rte-content table th {
    border: 1px solid #D2D2D7;
    padding: 8px;
}

.brilliance-rte-wrapper .e-richtexteditor .e-rte-content table th {
    background-color: #F5F5F7;
    font-weight: 600;
}

/* Image Upload Styles */
.brilliance-rte-wrapper .e-richtexteditor .e-rte-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 16px 0;
}

.brilliance-rte-wrapper .e-richtexteditor .e-img-caption {
    text-align: center;
    font-size: 12px;
    color: #86868B;
    margin-top: 8px;
}

/* Source Code View Styles */
.brilliance-rte-wrapper .e-richtexteditor .e-rte-content .e-source-content {
    font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, monospace;
    font-size: 13px;
    background-color: #1D1D1F;
    color: #00FF00;
    padding: 16px;
    border-radius: 8px;
    line-height: 1.5;
}

/* Placeholder Styles */
.brilliance-rte-wrapper .e-richtexteditor .e-rte-placeholder {
    color: #86868B;
    font-style: italic;
}

/* Resize Handle Styles */
.brilliance-rte-wrapper .e-richtexteditor .e-rte-resize {
    border: 2px solid #007AFF;
}

/* Fullscreen Mode */
.brilliance-rte-wrapper .e-richtexteditor.e-rte-full-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 9999;
    border-radius: 0;
}

/* Link Styles */
.brilliance-rte-wrapper .e-richtexteditor .e-rte-content a {
    color: #007AFF;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s ease;
}

.brilliance-rte-wrapper .e-richtexteditor .e-rte-content a:hover {
    border-bottom-color: #007AFF;
}

/* List Styles */
.brilliance-rte-wrapper .e-richtexteditor .e-rte-content ul,
.brilliance-rte-wrapper .e-richtexteditor .e-rte-content ol {
    margin: 16px 0;
    padding-left: 32px;
}

.brilliance-rte-wrapper .e-richtexteditor .e-rte-content li {
    margin: 8px 0;
}

/* Code Block Styles */
.brilliance-rte-wrapper .e-richtexteditor .e-rte-content pre {
    background-color: #F5F5F7;
    border: 1px solid #D2D2D7;
    border-radius: 6px;
    padding: 16px;
    overflow-x: auto;
    font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, monospace;
    font-size: 13px;
}

.brilliance-rte-wrapper .e-richtexteditor .e-rte-content code {
    background-color: #F5F5F7;
    border: 1px solid #D2D2D7;
    border-radius: 4px;
    padding: 2px 6px;
    font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, monospace;
    font-size: 13px;
}

/* Blockquote Styles */
.brilliance-rte-wrapper .e-richtexteditor .e-rte-content blockquote {
    border-left: 4px solid #007AFF;
    margin: 16px 0;
    padding-left: 16px;
    color: #515154;
    font-style: italic;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .brilliance-rte-wrapper .e-richtexteditor .e-rte-toolbar {
        flex-wrap: wrap;
    }
    
    .brilliance-rte-wrapper .e-richtexteditor .e-rte-content {
        font-size: 13px;
    }
}
