/* 基础样式重置 */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* 导航栏样式修正 */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: white;
    padding: 15px 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar-title {
    font-size: 20px;
    font-weight: bold;
    color: #00a1d6;
}

.post-btn {
    background: #00a1d6;
    color: white;
    border: none;
    padding: 8px 20px;
    border-radius: 20px;
    cursor: pointer;
    transition: opacity 0.3s;
}

.post-btn:hover {
    opacity: 0.9;
}

/* 主体内容修正 */
body {
    font-family: "Microsoft YaHei", sans-serif;
    max-width: 800px;
    margin: 0 auto;
    padding: 70px 15px 15px;
    background-color: #f0f2f5;
}

/* 留言容器修正 */
.message-container {
    background: white;
    border-radius: 12px;
    box-shadow: 0 3px 6px rgba(0,0,0,0.1);
    margin: 15px 0;
    padding: 15px;
    transition: transform 0.2s;
}

.message-container:hover {
    transform: translateY(-2px);
}

.message-header {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
}

.avatar {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    margin-right: 12px;
    border: 2px solid #e5e7eb;
}

.user-info {
    flex-grow: 1;
}

.nickname {
    font-weight: 600;
    color: #1a1a1a;
    margin-right: 8px;
}

.meta-info {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 4px;
}

.time {
    color: #666;
    font-size: 12px;
}

.location {
    color: #666;
    font-size: 12px;
    background: #f5f5f5;
    padding: 2px 6px;
    border-radius: 4px;
}

.message-content {
    margin: 10px 0;
    color: #333;
    line-height: 1.6;
    font-size: 15px;
}

/* 表单弹窗修正 */
.post-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 2000;
}

.message-form {
    background: white;
    padding: 25px;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    position: relative;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from { 
        transform: translateY(-20px); 
        opacity: 0; 
    }
    to { 
        transform: translateY(0); 
        opacity: 1; 
    }
}

/* 表单元素修正 */
input, textarea {
    width: 100%;
    padding: 10px;
    margin: 8px 0;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    transition: border-color 0.3s;
}

input:focus, textarea:focus {
    border-color: #00a1d6;
    outline: none;
}

/* 多媒体内容修正 */
.preview-container {
    margin: 10px 0;
}

.preview-image {
    max-width: 200px;
    border-radius: 8px;
    cursor: zoom-in;
    margin: 5px 0;
}

.bilibili-video {
    width: 100%;
    max-width: 560px;
    height: 315px;
    border: none;
    border-radius: 8px;
    margin: 10px 0;
}

/* 图片查看模态框修正 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    z-index: 3000;
    justify-content: center;
    align-items: center;
}

.modal-content {
    max-width: 90%;
    max-height: 90%;
    border-radius: 8px;
}
/* 按钮样式修正 */
button {
    background: #00a1d6;
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    transition: opacity 0.3s;
}

button:hover {
    opacity: 0.9;
}

/* 移动端适配修正 */
@media (max-width: 600px) {
    body {
        padding: 70px 10px 10px;
    }

    .message-container {
        padding: 12px;
    }

    .avatar {
        width: 40px;
        height: 40px;
    }

    .bilibili-video {
        height: 200px;
    }

    input, textarea {
        font-size: 14px;
    }
}