/* static/css/blog.css */
.blog-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.blog-header {
    text-align: center;
    margin-bottom: 30px;
    border-bottom: 1px solid #eee;
    padding-bottom: 20px;
}

.blog-content {
    display: flex;
    flex-wrap: wrap;
}

.sidebar {
    flex: 0 0 250px;
    padding-right: 30px;
}

.main-content {
    flex: 1;
    min-width: 60%;
}

.post-list {
    list-style: none;
    padding: 0;
}

.post-list li {
    margin-bottom: 10px;
}

.post-list a {
    text-decoration: none;
    color: #06d15b;
}

.post-list a:hover {
    color: #007bff;
}

.post-preview, .post-full {
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.post-meta {
    color: #666;
    font-size: 0.9em;
}

.post-excerpt {
    margin: 15px 0;
}

.read-more {
    display: inline-block;
    padding: 5px 10px;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 3px;
    text-decoration: none;
    color: #495057;
}

.comment {
    border: 1px solid #eee;
    padding: 15px;
    margin-bottom: 15px;
    border-radius: 5px;
}

.comment-meta {
    font-size: 0.9em;
    color: #666;
    margin-bottom: 5px;
}

.comment-form {
    margin-top: 30px;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
}

.form-group input, .form-group textarea {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

button {
    padding: 10px 15px;
    background: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

button:hover {
    background: #0069d9;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .blog-content {
        flex-direction: column;
    }
    
    .sidebar {
        flex: 0 0 100%;
        padding-right: 0;
        margin-bottom: 30px;
    }
}

/* 添加到 static/css/blog.css 或 static/css/style.css */
.attachments {
    margin-top: 30px;
    padding: 20px;
    border: 1px solid #e9ecef;
    border-radius: 5px;
    background: #f8f9fa;
}

.attachment-list {
    margin-top: 15px;
}

.attachment-item {
    display: flex;
    align-items: center;
    padding: 10px;
    margin-bottom: 10px;
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 5px;
}

.attachment-icon {
    font-size: 24px;
    margin-right: 15px;
}

.attachment-info {
    flex: 1;
}

.attachment-info h5 {
    margin: 0 0 5px 0;
    font-size: 16px;
}

.attachment-meta {
    margin: 0;
    font-size: 12px;
    color: #6c757d;
}

.attachment-actions {
    display: flex;
    gap: 5px;
}

.file-icon.pdf {
    color: #e74c3c;
}


.pdf-header {
    padding: 15px;
    background: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
}


.pdf-actions {
    padding: 10px;
    background: #f8f9fa;
    border-top: 1px solid #dee2e6;
    text-align: center;
}

/* 扩大 PDF 预览容器 */
.pdf-preview-container {
    width: 100%; /* 占满父容器宽度 */
    height: 600px; /* 增加高度 */
    margin-bottom: 20px;
    border: 1px solid #ccc; /* 可选：增加边框，方便调试 */
    box-shadow: 0 2px 4px rgba(0,0,0,0.1); /* 可选：美观效果 */
}

/* 使 iframe 自适应容器大小 */
.pdf-preview-iframe {
    width: 100%;
    height: 100%;
    border: none; /* 移除默认边框 */
}

.main-content {
    flex: 1;
    padding: 20px;
    max-width: 100%;
}

.post-content {
    margin-bottom: 40px;
}