
.global-editor-panel {
    position: fixed;
    left: -250px;
    top: 0;
    height: 100vh;
    width: 230px;
    background-color: rgba(26, 71, 42, 0.95);
    border-right: 3px solid #97bc62;
    z-index: 9990;
    transition: left 0.4s ease-in-out;
    display: flex;
    flex-direction: column;
    box-shadow: 5px 0 15px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(5px);
}
.global-editor-panel.open {
    left: 0;
}
.editor-tab-button {
    position: fixed;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 120px;
    background-color: #1a472a;
    border: 2px solid #97bc62;
    border-left: none;
    border-radius: 0 8px 8px 0;
    cursor: pointer;
    z-index: 9980;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 3px 0 10px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
    padding: 0;
}
.editor-tab-button:hover {
    background-color: #2c5f2d;
    box-shadow: 5px 0 15px rgba(0, 0, 0, 0.4);
}
.editor-tab-button::before {
    content: '✎';
    color: #c9e3ac;
    font-size: 24px;
    writing-mode: vertical-rl;
    text-orientation: upright;
    letter-spacing: -5px;
}
.editor-header {
    padding: 15px;
    border-bottom: 2px solid #97bc62;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.editor-header h2 {
    color: #aad576;
    margin: 0;
    font-size: 20px;
    font-weight: normal;
}
.close-editor-btn {
    background: none;
    border: none;
    color: #aad576;
    font-size: 24px;
    cursor: pointer;
    padding: 0 5px;
    line-height: 1;
    box-shadow: none;
}
.close-editor-btn:hover {
    color: #c9e3ac;
    transform: none;
    box-shadow: none;
}
.editor-container {
    width: 100%;
    height: calc(100% - 25px);
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 10;
}
.editor-toolbar {
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow-y: auto;
}
.toolbar-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 15px;
}
.toolbar-group-title {
    color: #c9e3ac;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 5px;
    border-bottom: 1px solid rgba(201, 227, 172, 0.2);
    padding-bottom: 3px;
}
.toolbar-buttons {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}
.toolbar-btn {
    background-color: #1a472a;
    color: #c9e3ac;
    border: none;
    border-radius: 3px;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s ease;
}
.toolbar-btn:hover {
    background-color: #2c5f2d;
    transform: scale(1.05);
}
.toolbar-separator {
    height: 1px;
    background-color: rgba(201, 227, 172, 0.2);
    width: 100%;
    margin: 5px 0;
}
.toolbar-select {
    background-color: #1a472a;
    color: #c9e3ac;
    border: none;
    border-radius: 3px;
    padding: 8px 5px;
    width: 100%;
    margin-bottom: 5px;
    cursor: pointer;
    font-size: 14px;
}
.toolbar-select option {
    background-color: #0f2417;
    color: #c9e3ac;
}
.apply-to-all {
    margin-top: 20px;
    text-align: center;
}
.apply-to-all button {
    background-color: #43a047;
    color: white;
    border: none;
    border-radius: 5px;
    padding: 8px 15px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s ease;
    width: 100%;
}
.apply-to-all button:hover {
    background-color: rgba(76, 175, 80, 0.9);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}
.global-format-indicator {
    position: absolute;
    top: 10px;
    left: 10px;
    background-color: rgba(67, 160, 71, 0.7);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
    z-index: 100;
}
.global-format-indicator.show {
    opacity: 1;
    animation: fadeOut 1.5s forwards 1s;
}
@keyframes fadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}
.rich-editor {
    min-height: 150px;
    background-color: rgba(255, 255, 255, 0.9);
    border-radius: 5px;
    padding: 10px;
    outline: none;
    font-family: 'Garamond', serif;
    color: #0f2417;
    font-size: 18px;
    line-height: 1.5;
    white-space: pre-wrap;
    display: block;
    width: 100%;
    height: 100%;
    overflow-y: auto;
}
.rich-editor:focus {
    box-shadow: 0 0 3px rgba(67, 160, 71, 0.5);
}
.rich-editor::-webkit-scrollbar {
    width: 5px;
}
.rich-editor::-webkit-scrollbar-track {
    background: transparent;
}
.rich-editor::-webkit-scrollbar-thumb {
    background-color: rgba(151, 188, 98, 0.6);
    border-radius: 5px;
}
.rich-editor.empty:before {
    content: attr(placeholder);
    color: rgba(15, 36, 23, 0.6);
    font-style: italic;
    pointer-events: none;
}
.rich-editor ul, .rich-editor ol {
    margin-left: 20px;
    padding-left: 5px;
}
.rich-editor p {
    margin: 0 0 10px 0;
}
.autosave-indicator {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: rgba(67, 160, 71, 0.8);
    color: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 16px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    z-index: 9999;
    animation: popIn 0.3s ease-out;
}
.autosave-indicator.fade-out {
    animation: fadeOut 0.5s ease-out forwards;
}
@keyframes popIn {
    0% { transform: scale(0); opacity: 0; }
    70% { transform: scale(1.2); opacity: 1; }
    100% { transform: scale(1); opacity: 1; }
}
@keyframes fadeOut {
    0% { opacity: 1; }
    100% { opacity: 0; }
}
