/* 主内容区样式 */
main {
    padding: 15px 0 30px;
    min-height: calc(100vh - 100px);
}

/* 页面标题样式 */
.page-header {
    margin-bottom: 20px;
    padding: 15px;
    background: linear-gradient(to right, var(--primary-color), var(--accent-color));
    border-radius: 8px;
    color: var(--white);
    box-shadow: 0 4px 12px rgba(139, 69, 19, 0.2);
}

.page-header h1 {
    font-size: 2.2rem;
    margin-bottom: 8px;
}

.page-header p {
    font-size: 1.4rem;
    opacity: 0.9;
}

/* 微博表单样式 */
.weibo-form {
    background: var(--white);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 25px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: var(--primary-color);
}

.form-group input[type="text"],
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--secondary-color);
    border-radius: 4px;
    font-family: inherit;
    font-size: 1.4rem;
    transition: border-color 0.3s ease;
}

.form-group input[type="text"]:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
}

.form-group textarea {
    min-height: 120px;
    resize: vertical;
}

.submit-btn {
    background: var(--primary-color);
    color: var(--white);
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    font-size: 1.4rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: block;
    width: 100%;
}

.submit-btn:hover {
    background: var(--primary-light);
}

.submit-btn:disabled {
    background: var(--text-light);
    cursor: not-allowed;
}

/* 图片上传选项样式 */
.image-upload-options {
    margin-bottom: 15px;
}

.upload-tabs {
    display: flex;
    margin-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.tab-btn {
    padding: 8px 15px;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 14px;
    color: #666;
    border-bottom: 2px solid transparent;
}

.tab-btn.active {
    color: #8B5A2B;
    border-bottom-color: #8B5A2B;
    font-weight: bold;
}

.tab-content {
    padding: 10px 0;
}

.url-input-group {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

#image-url {
    width: 70%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.url-validate-btn {
    padding: 8px 15px;
    background-color: #8B5A2B;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    margin-left: 10px;
}

.url-validate-btn:hover {
    background-color: #1565c0;
}

.image-upload-options .file-upload {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: #8B4513;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    font-size: 14px;
}

.image-upload-options .file-upload i,
.image-upload-options .file-upload {
    color: white;
}

.image-upload-options .file-upload:hover {
    background: #A0522D;
    transform: translateY(-1px);
}

#preview {
    margin-top: 10px;
}

.weibo-image {
    max-width: 100%;
    max-height: 200px;
    border-radius: 4px;
    margin-top: 10px;
}

.loading-placeholder {
    padding: 10px;
    background: #f5f5f5;
    border-radius: 4px;
    text-align: center;
    color: var(--text-light);
}

.error-message {
    display: block;
    margin-top: 5px;
    font-size: 1.2rem;
}

/* 微博列表样式 */
.weibo-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.weibo-item {
    background: var(--white);
    border-radius: 8px;
    padding: 15px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    transition: all 0.3s ease;
    animation: fadeIn 0.4s ease forwards;
}

.weibo-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

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

.weibo-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(45deg, var(--primary-color), var(--accent-color));
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.8rem;
    margin-right: 10px;
}

.weibo-author {
    font-weight: bold;
    color: var(--primary-color);
}

.weibo-time {
    margin-left: auto;
    font-size: 1.2rem;
    color: var(--text-light);
}

.weibo-content {
    margin-bottom: 10px;
    line-height: 1.6;
}

.weibo-image-container {
    margin: 10px 0;
}

.weibo-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 1.2rem;
    color: var(--text-light);
}

.weibo-actions {
    display: flex;
    gap: 15px;
}

.weibo-action {
    cursor: pointer;
    transition: color 0.3s ease;
}

.weibo-action:hover {
    color: var(--primary-color);
}

.truncate-text {
    display: inline-block;
    max-width: 1em;
    overflow: hidden;
    text-overflow: clip;
    white-space: nowrap;
}

/* 动画效果 */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.weibo-item:nth-child(2) { animation-delay: 0.05s; }
.weibo-item:nth-child(3) { animation-delay: 0.1s; }
.weibo-item:nth-child(4) { animation-delay: 0.15s; }
.weibo-item:nth-child(5) { animation-delay: 0.2s; }
.weibo-item:nth-child(6) { animation-delay: 0.25s; }

/* 响应式设计 */
@media screen and (max-width: 768px) {
    .image-upload-options {
        display: flex;
        flex-direction: column;
    }
    
    .url-input-group {
        flex-direction: column;
    }
    
    #image-url {
        width: 100%;
        margin-bottom: 10px;
    }
    
    .url-validate-btn {
        width: 100%;
        margin-left: 0;
        padding: 10px;
    }
    
    .upload-tabs {
        flex-wrap: wrap;
    }
    
    .tab-btn {
        padding: 10px;
        font-size: 14px;
    }
}