/* EditorHtml Component Styles */
.editor-html-container {
    border: 2px solid #dee2e6;
    border-radius: 12px;
    overflow: hidden;
    background: #ffffff;
    transition: border-color 0.3s ease;
}

.editor-html-container:focus-within {
    border-color: #667eea;
    box-shadow: 0 0 0 0.2rem rgba(102, 126, 234, 0.25);
}

.editor-html-toolbar {
    background: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
    padding: 8px 12px;
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
}

.editor-html-toolbar-btn {
    background: #ffffff;
    border: 1px solid #ced4da;
    border-radius: 6px;
    padding: 6px 10px;
    cursor: pointer;
    font-size: 14px;
    color: #495057;
    transition: all 0.2s ease;
    min-width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.editor-html-toolbar-btn:hover {
    background: #e9ecef;
    border-color: #adb5bd;
    color: #212529;
}

.editor-html-toolbar-btn:active,
.editor-html-toolbar-btn.active {
    background: #667eea;
    border-color: #667eea;
    color: #ffffff;
}

.editor-html-toolbar-separator {
    width: 1px;
    background: #dee2e6;
    margin: 0 4px;
    align-self: stretch;
}

.editor-html-content {
    min-height: 200px;
    max-height: 500px;
    overflow-y: auto;
    padding: 15px;
    outline: none;
    font-size: 14px;
    line-height: 1.6;
    color: #212529;
}

.editor-html-content:empty:before {
    content: attr(data-placeholder);
    color: #6c757d;
    font-style: italic;
    pointer-events: none;
}

/* Formatted content styles */
.editor-html-content p {
    margin: 0 0 10px 0;
}

.editor-html-content p:last-child {
    margin-bottom: 0;
}

.editor-html-content strong,
.editor-html-content b {
    font-weight: 700;
}

.editor-html-content em,
.editor-html-content i {
    font-style: italic;
}

.editor-html-content u {
    text-decoration: underline;
}

.editor-html-content s,
.editor-html-content strike {
    text-decoration: line-through;
}

.editor-html-content ul,
.editor-html-content ol {
    margin: 10px 0;
    padding-left: 30px;
}

.editor-html-content ul {
    list-style-type: disc;
}

.editor-html-content ol {
    list-style-type: decimal;
}

.editor-html-content li {
    margin: 5px 0;
}

.editor-html-content blockquote {
    margin: 10px 0;
    padding: 10px 20px;
    border-left: 4px solid #667eea;
    background: #f8f9fa;
    font-style: italic;
    color: #495057;
}

/* Scrollbar customization */
.editor-html-content::-webkit-scrollbar {
    width: 8px;
}

.editor-html-content::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.editor-html-content::-webkit-scrollbar-thumb {
    background: #cbd5e0;
    border-radius: 4px;
}

.editor-html-content::-webkit-scrollbar-thumb:hover {
    background: #a0aec0;
}

/* Selection */
.editor-html-content ::selection {
    background: rgba(102, 126, 234, 0.3);
}

/* Theme-Specific Styles */

/* Light Theme */
.theme-indigo-light .editor-html-container {
    background: #ffffff;
    border-color: #dee2e6;
}

.theme-indigo-light .editor-html-toolbar {
    background: #f8f9fa;
    border-bottom-color: #dee2e6;
}

.theme-indigo-light .editor-html-toolbar-btn {
    background: #ffffff;
    border-color: #ced4da;
    color: #495057;
}

.theme-indigo-light .editor-html-toolbar-btn:hover {
    background: #e9ecef;
    border-color: #adb5bd;
    color: #212529;
}

.theme-indigo-light .editor-html-content {
    color: #212529;
}

.theme-indigo-light .editor-html-content:empty:before {
    color: #6c757d;
}

/* Dark Theme */
.theme-indigo-dark .editor-html-container {
    background: rgba(30, 41, 59, 0.8);
    border-color: rgba(139, 92, 246, 0.3);
}

.theme-indigo-dark .editor-html-container:focus-within {
    border-color: rgba(139, 92, 246, 0.6);
    box-shadow: 0 0 0 0.2rem rgba(139, 92, 246, 0.25);
}

.theme-indigo-dark .editor-html-toolbar {
    background: rgba(30, 41, 59, 0.9);
    border-bottom-color: rgba(139, 92, 246, 0.3);
}

.theme-indigo-dark .editor-html-toolbar-btn {
    background: rgba(30, 41, 59, 0.6);
    border-color: rgba(139, 92, 246, 0.3);
    color: #e2e8f0;
}

.theme-indigo-dark .editor-html-toolbar-btn:hover {
    background: rgba(139, 92, 246, 0.2);
    border-color: rgba(139, 92, 246, 0.5);
    color: #ffffff;
}

.theme-indigo-dark .editor-html-toolbar-btn:active,
.theme-indigo-dark .editor-html-toolbar-btn.active {
    background: rgba(139, 92, 246, 0.4);
    border-color: rgba(139, 92, 246, 0.6);
    color: #ffffff;
}

.theme-indigo-dark .editor-html-toolbar-separator {
    background: rgba(139, 92, 246, 0.3);
}

.theme-indigo-dark .editor-html-content {
    color: #e2e8f0;
}

.theme-indigo-dark .editor-html-content[contenteditable="true"]:empty:before {
    color: #94a3b8 !important;
}

.theme-indigo-dark .editor-html-content:empty::before {
    color: #94a3b8 !important;
}

.theme-indigo-dark .editor-html-content blockquote {
    border-left-color: rgba(139, 92, 246, 0.6);
    background: rgba(30, 41, 59, 0.6);
    color: #cbd5e1;
}

.theme-indigo-dark .editor-html-content::-webkit-scrollbar-track {
    background: rgba(30, 41, 59, 0.6);
}

.theme-indigo-dark .editor-html-content::-webkit-scrollbar-thumb {
    background: rgba(139, 92, 246, 0.4);
}

.theme-indigo-dark .editor-html-content::-webkit-scrollbar-thumb:hover {
    background: rgba(139, 92, 246, 0.6);
}

.theme-indigo-dark .editor-html-content ::selection {
    background: rgba(139, 92, 246, 0.4);
}
