body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f5f5f5;
    position: relative;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}
.container {
    display: flex;
    flex-direction: column;
    max-width: 1200px;
    width: 100%;
    height: 100vh;
    max-height: 800px;
    margin: 0 auto;
    padding: 20px;
    box-sizing: border-box;
}
.content-wrapper {
    display: flex;
    flex: 1;
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    overflow: hidden;
}
#blur-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    background-color: rgba(255, 255, 255, 0.5);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.3s ease;
}
#sidebar {
    width: 250px;
    background-color: #e8f5e9;
    padding: 20px;
    overflow-y: auto;
    border-radius: 10px 0 0 10px;
    display: flex;
    flex-direction: column;
    max-height: 100%;
}
#notes-list {
    overflow-y: auto;
    flex: 1;
    max-height: calc(100% - 120px);
}
/* 隐藏notes-list滚动条 */
#notes-list::-webkit-scrollbar {
    display: none;
}
/* 隐藏sidebar滚动条 */
#sidebar::-webkit-scrollbar {
    display: none;
}
#main {
    flex: 1;
    overflow-y: auto;
    position: relative;
    display: flex;
    flex-direction: column;
}
/* 隐藏main滚动条 */
#main::-webkit-scrollbar {
    display: none;
}
.main-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background-color: white;
    padding: 20px;
    border-bottom: 1px solid #e9ecef;
}

/* 编辑器容器样式 */
#editor-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: visible;
}

/* 编辑器内容区域样式 */
.editor-content {
    flex: 1;
    display: flex;
    position: relative;
    overflow: auto;
}
.editor-content img {
    width: 100%;
    
}

/* 编辑器页脚样式 */
.editor-footer {
    position: sticky;
    bottom: 0;
    background-color: #f8f9fa;
    border-top: 1px solid #e9ecef;
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
    color: #6c757d;
    z-index: 50;
    margin-top: auto;
}
.search-box {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 5px;
    margin-bottom: 15px;
    box-sizing: border-box;
}
.note-item {
    padding: 10px;
    margin-bottom: 8px;
    background-color: white;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
    border: 2px solid transparent;
}
.note-item:hover {
    background-color: #f0f7f1;
}
.note-item.selected {
    background-color: #d5ecd6;
    border-color: #5a985d;
    box-shadow: 0 2px 8px rgba(33, 150, 243, 0.2);
}
.note-item.selected:hover {
    background-color: #f0f7f1;
}
.note-item .action-icons {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    display: none;
    flex-direction: row;
    gap: 5px;
}
.note-item:hover .action-icons {
    display: flex;
}
.action-icon {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: white;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    transition: all 0.2s;
}
.action-icon:hover {
    transform: scale(1.1);
}
.action-icon.delete {
    color: #ff4444;
}
.action-icon.pin {
    color: #4caf50;
}
mark {
    background-color: #ffeb3b;
    padding: 0 2px;
    border-radius: 2px;
    font-weight: bold;
    color: #333;
}
input[type="password"] {
    width: 100%;
    padding: 8px;
    margin-bottom: 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    box-sizing: border-box;
}
button {
    padding: 8px 16px;
    background-color: #4caf50;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.2s;
}
button:hover {
    background-color: #45a049;
}

.date-display {
    font-weight: 600;
    color: #2e7d32;
    cursor: pointer;
    padding: 5px 10px;
}
.editor {
    width: 100%;
    flex: 1;
    padding: 20px;
    border: none;
    border-radius: 8px;
    resize: none;
    box-sizing: border-box;
    font-family: 'Helvetica Neue', Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    background-color: #fff;
    transition: all 0.3s ease;
    outline: none;
    min-height: 300px;
}

/* 源代码模式按钮样式 */
.source-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border: 1px solid #dee2e6;
    background-color: #fff;
    color: #6c757d;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.2s ease;
    outline: none;
}

.source-btn:hover {
    background-color: #f8f9fa;
    border-color: #adb5bd;
    color: #495057;
}

.source-btn.active {
    background-color: #007bff;
    color: #fff;
    border-color: #007bff;
}

.source-btn svg {
    flex-shrink: 0;
}

/* 分享按钮样式 */
.share-btn {
    background-color: #28a745;
    color: white;
    border: 1px solid #28a745;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s ease;
    text-decoration: none;
    font-family: inherit;
}

.share-btn:hover {
    background-color: #218838;
    border-color: #1e7e34;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(40, 167, 69, 0.2);
}

.share-btn:active {
    transform: translateY(0);
    box-shadow: 0 1px 2px rgba(40, 167, 69, 0.2);
}

.share-btn svg {
    flex-shrink: 0;
    width: 16px;
    height: 16px;
}

/* 分享模态框特定样式 */
#shareModal .modal-content {
    max-width: 500px;
    width: 90%;
}

.share-option {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
    padding: 8px;
    border-radius: 4px;
    transition: background-color 0.2s ease;
}

.share-option:hover {
    background-color: #f8f9fa;
}

.share-option input[type="radio"] {
    margin-right: 10px;
}

.custom-days-input {
    margin-left: 25px;
    margin-top: 5px;
    padding: 6px 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    width: 100px;
    display: none;
}

.share-link-container {
    margin: 15px 0;
}

.share-link-input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background-color: #f8f9fa;
    font-family: monospace;
    font-size: 14px;
    margin-bottom: 10px;
}

.share-buttons {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}


.btn-generate {
    background-color: #007bff;
    color: white;
    border: 1px solid #007bff;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s ease;
}

.btn-generate:hover {
    background-color: #0056b3;
    border-color: #004085;
}

.btn-copy {
    background-color: #6c757d;
    color: white;
    border: 1px solid #6c757d;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.2s ease;
}

.btn-copy:hover {
    background-color: #545b62;
    border-color: #4e555b;
}

.btn-copy:disabled {
    background-color: #e9ecef;
    color: #6c757d;
    border-color: #dee2e6;
    cursor: not-allowed;
}

.error-message {
    color: #dc3545;
    font-size: 14px;
    margin-top: 10px;
    padding: 8px;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
    display: none;
}

.success-message {
    color: #155724;
    font-size: 14px;
    margin-top: 10px;
    padding: 8px;
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 4px;
    display: none;
}

.preview {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    cursor: text;
    transition: all 0.3s ease;
    overflow: auto;
}

.preview:hover {
    background-color: rgba(255, 255, 255, 0.98);
}

.preview h1, .preview h2, .preview h3, .preview h4, .preview h5, .preview h6 {
    margin-top: 24px;
    margin-bottom: 16px;
    font-weight: 600;
    line-height: 1.25;
}

.preview h1 {
    font-size: 2em;
    border-bottom: 1px solid #eaecef;
    padding-bottom: 10px;
}

.preview h2 {
    font-size: 1.5em;
    border-bottom: 1px solid #eaecef;
    padding-bottom: 8px;
}

.preview h3 {
    font-size: 1.25em;
}

.preview p {
    margin-bottom: 16px;
}

.preview code {
    padding: 2px 4px;
    font-size: 85%;
    background-color: rgba(27,31,35,0.05);
    border-radius: 3px;
    font-family: 'Consolas', 'Monaco', monospace;
}

.preview pre {
    padding: 16px;
    overflow: auto;
    font-size: 85%;
    line-height: 1.45;
    background-color: #f6f8fa;
    border-radius: 6px;
    margin-bottom: 16px;
}

.preview pre code {
    background-color: transparent;
    border: 0;
    display: inline;
    line-height: inherit;
    margin: 0;
    max-width: auto;
    overflow: visible;
    padding: 0;
    word-wrap: normal;
}

.preview blockquote {
    padding: 0 1em;
    color: #6a737d;
    border-left: 4px solid #dfe2e5;
    margin: 0 0 16px 0;
}

.preview ul, .preview ol {
    padding-left: 2em;
    margin-bottom: 16px;
}

.preview li {
    margin-bottom: 4px;
}

.preview table {
    border-collapse: collapse;
    margin-bottom: 16px;
    width: 100%;
}

.preview table th, .preview table td {
    padding: 6px 13px;
    border: 1px solid #dfe2e5;
}

.preview table th {
    background-color: #f6f8fa;
    font-weight: 600;
}
/* .editor:focus {
    border-color: #4caf50;
    box-shadow: 0 4px 12px rgba(76,175,80,0.15);
} */
.avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: #4caf50;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    margin-left: 10px;
    font-size: 20px;
}
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    z-index: 1000;
}
.modal-content {
    position: relative;
    background-color: white;
    margin: 8% auto;
    padding: 20px;
    width: 80%;
    max-width: 500px;
    border-radius: 10px;
}
.close {
    position: absolute;
    right: 10px;
    top: 10px;
    font-size: 24px;
    cursor: pointer;
}
.form-group {
    margin-bottom: 15px;
}
.form-group label {
    display: block;
    margin-bottom: 5px;
    color: #666;
}
.form-group input {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 5px;
    box-sizing: border-box;
}

/* 表单行样式 - 用于将多个表单项放在一行 */
.form-row {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

.form-row .form-group {
    flex: 1;
    margin-bottom: 0;
}

/* 按钮组样式 */
.button-group {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid #eee;
}

.button-group button {
    min-width: 100px;
}

/* 响应式设计 - 移动设备上表单行垂直排列 */
@media (max-width: 768px) {
    .form-row {
        flex-direction: column;
        gap: 0;
    }
    
    .form-row .form-group {
        margin-bottom: 15px;
    }
    
    .button-group {
        flex-direction: column;
    }
    
    .button-group button {
        width: 100%;
        margin-left: 0 !important;
    }
}
.weather {
    margin-left: 15px;
    color: #666;
    display: flex;
    align-items: center;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 10px;
        height: auto;
        max-height: none;
    }
    .content-wrapper {
        flex-direction: column;
    }
    #sidebar {
        width: 100%;
        border-radius: 10px 10px 0 0;
        max-height: 200px;
        overflow-y: hidden;
    }
    #notes-list {
        max-height: 120px;
    }
    #main {
        border-radius: 0 0 10px 10px;
    }
    .editor {
        height: calc(100vh - 250px); /* 移动设备上的高度调整，增加高度 */
        min-height: 200px;
        padding: 15px;
        font-size: 15px;
        line-height: 1.5;
    }
    #news-container {
        padding: 0 10px;
        overflow: hidden;
    }

    @media (max-width: 768px) {
        #news-container {
            padding: 0;
            margin: 0 10px;
        }
        .news-item {
            width: 100% !important;
            margin-bottom: 10px;
            padding-bottom: 10px;
        }
    }

    @media (min-width: 769px) and (max-width: 1024px) {
        .news-item {
            width: 100% !important;
            margin-bottom: 15px;
            padding-bottom: 15px;
        }
    }
    .news-item {
        width: 100% !important; /* 在移动设备上显示为单列 */
        margin-bottom: 10px;
        padding-bottom: 10px;
    }
    #news-pagination button {
        padding: 4px 8px;
        font-size: 12px;
        margin-right: 3px;
    }
}
.main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 100%);
    /* margin-bottom: 15px; */
}
.date-display-style {
    font-weight: 600;
    color: #2e7d32;
    cursor: pointer;
}
.weather-style {
    background-color: rgba(255,255,255,0.7);
    padding: 5px 10px;
    border-radius: 20px;
    margin-right: 10px;
}
.avatar-style {
    background: linear-gradient(135deg, #4caf50 0%, #2e7d32 100%);
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}
.news-container-style {
    margin-top: 20px;
    padding: 0 20px;
    max-width: 100%;
    overflow: hidden;
}
.news-source-style {
    cursor: pointer;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 14px;
}
.news-source-all {
    background-color: #4caf50;
    color: white;
}
.news-source-jinritoutiao {
    background-color: #ff4444;
    color: white;
}
.news-source-baidu {
    background-color: #4285f4;
    color: white;
}
.news-source-weibo {
    background-color: #e6a016;
    color: white;
}
.news-list {
    margin-top: 10px;
    overflow: hidden;
}
.news-pagination {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 5px;
    overflow: hidden;
    position: sticky;
    bottom: 0;
    padding: 10px 0;
}
.pagination-button {
    padding: 5px 10px;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    margin-right: 5px;
}
.pagination-button-active {
    background-color: #4caf50;
    color: white;
}
.pagination-button-inactive {
    background-color: #f5f5f5;
    color: #333;
}
.pagination-button-disabled {
    background-color: #f5f5f5;
    color: #aaa;
    cursor: default;
}
.pagination-ellipsis {
    margin: 0 5px;
}