body {
    background-color: rgb(233, 233, 233);
}

.module {
    background-color: white;
    padding: 20px;
    margin-bottom: 10px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* 设置按钮容器样式，使其内容居中 */
.button-container {
    text-align: center;
    margin-bottom: 10px;
}


/* 仅对 button-container 下的 button 元素设置样式 */
.button-container button {
    background-color: #dfdfdf; /* 按钮浅色背景 */
    color: #333;
    border: none;
    padding: 3px 6px;
    margin: 0 2px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    
}


.button-container button:hover {
    background-color: #006400; /* 鼠标悬停时深绿色背景 */
    color: white;
}

.button-container button:active {
    background-color: #006400; /* 点击时深绿色背景 */
    color: white;
}

.bg-image {
    background-image: url('../images/bg.jpg');
    background-size: cover;
    background-position: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 1.5rem 0;
    overflow: hidden;
}

.site-logo {
    color: white;
    font-size: 2.5rem;
    /* margin-bottom: 1.5rem; */
    font-weight: bold;
    letter-spacing: 5px;
}
.site-link {
    color: inherit;
    text-decoration: none;
}

.site-intro {
    color: white;
    width: 85%;
    text-align: center;
}

.site-menu {
    background-color: #f8f9fa;
    padding: 1rem 0;
    font-weight: bold;
    letter-spacing: 2px;
}

.site-menu ul {
    list-style-type: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
}

.site-menu li {
    margin: 0 1rem;
}

.site-menu a {
    color: #333;
    text-decoration: none;
    transition: color 0.3s ease;
}

.site-menu a:hover {
    color: #b50303;
}

.article-list {
    margin-top: 0rem;
}

.list-style {
    margin-bottom: 1rem;
    font-weight: bold;
}

.article-list ul {
    list-style-type: none;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
}

.article-list li {
    flex-shrink: 1;
    margin: 0.7rem;
    max-width: 100%;
}

.article-list a {
    color: #333;
    text-decoration: none;
    transition: color 0.3s ease;
    word-wrap: break-word;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    max-height: 4rem;
    word-break: break-all;
    position: relative;
    padding-left: 20px;
}

.article-list li a::before {
    content: "/";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0.3;
}

.article-list a:hover {
    color: #e26600;
}

.article-text p:hover {
    background-color: #006c22;
    border-color: #49a200;
    border-width: 2px;
    color: white;
}
.article-text li {
    color: brown;
    }

.friend-links {
    margin-top: 0rem;
    margin-bottom: 0px;
}

.friend-links a {
    color: #333;
    text-decoration: none;
    margin: 1rem;
    transition: color 0.3s ease;
}

.friend-links a:hover {
    color: #e26600;
}

footer {
    background-color: #000000;
    color: white;
    text-align: center;
    padding: 1.5rem 0;
}

.article-content {
    margin-top: 10px;
}

.article-title {
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 10px;
    text-align: center;
}

.article-date {
    color: #777;
    margin-bottom: 10px;
    text-align: center;
}
.article-date a{
    color: #777;
    text-decoration: none;
}
.article-text {
    margin-bottom: 20px;
    line-height: 2em;
}

.article-nav {
    display: flex;
    justify-content: space-between; /* 使元素在容器中两端对齐 */
    align-items: flex-start; /* 垂直方向顶部对齐 */
    margin-bottom: 20px;
    margin-top: 10px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 600;
}

.nav-item {
    display: flex;
    align-items: baseline; /* 使标签和链接基线对齐 */
}

.nav-label {
    margin-right: 5px; /* 设置标签与链接之间的间距 */
}

.nav-link {
    color: #333;
    text-decoration: none;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: #e26600;
}

/* 关键调整：使用 text-align 控制对齐方式 */
.article-nav > *:first-child {
    text-align: left; /* “上一篇”元素居左显示 */
}

.article-nav > *:last-child {
    text-align: right; /* “下一篇”元素居右显示 */
}

.article-actions {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    justify-content: center; /* 水平居中 */
    align-items: center; /* 垂直居中 */
}

.article-actions button {
    background-color: #f8f9fa;
    border: 1px solid #ddd;
    padding: 10px 20px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    color: black;
}

.article-actions button:hover {
    background-color: #e26600;
    color: white;
}

/* 评论表单样式 */
.comment-form {
    margin-top: 2px;
}

.comment-form label {
    display: inline-block;
    margin-bottom: 5px;
    font-size: 14px;
    margin-right: -8px;
}

.comment-form input {
    width: 180px;
    padding: 6px;
    margin-bottom: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 14px;
    display: inline-block;
}

.comment-form textarea {
    width: 100%;
    padding: 8px;
    margin-bottom: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    resize: vertical;
}

.comment-form button {
    background-color: #e26600;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.comment-form button:hover {
    background-color: #b50303;
}

.comment-user-info{
    font-size: 14px;
    color: #929292;
    margin-bottom: 3px;
    background-color: #ddf4e8;
    border-radius: 5px;
    padding: 8px;
}

/* 分页容器样式 */
.pagination-container {
    text-align: center;
    margin-top: 20px;
    margin-bottom: 20px;
}

/* 分页链接样式 */
.page-number {
    display: inline-block;
    padding: 8px 12px;
    margin: 0 5px;
    background-color: #f4f4f4;
    border: 1px solid #ddd;
    color: #333;
    text-decoration: none;
    border-radius: 3px;
    transition: background-color 0.3s ease;
}

/* 鼠标悬停效果 */
.page-number:hover {
    background-color: #ddd;
}


/* 媒体查询，针对小屏幕设备（如手机） */
@media (max-width: 767px) {
    .article-nav {
        flex-direction: column;
    }

    .article-nav a {
        margin-bottom: 10px;
    }

    .comment-form label,
    .comment-form input {
        width: 100%;
        display: block;
        margin-right: 0;
    }
}