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

body {
    font-family: "Microsoft YaHei", sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

a {
    text-decoration: none;
    color: #2a7de1;
    transition: color 0.3s;
}

a:hover {
    color: #1c5db9;
}

/* 头部样式 */
header {
    background-color: #fff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
}

header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 15px;
}

.logo h1 {
    font-size: 24px;
    color: #2a7de1;
}

nav ul {
    display: flex;
    list-style: none;
}

nav ul li {
    margin: 0 10px;
}

nav ul li a {
    padding: 4px;
    border-radius: 4px;
}

nav ul li a.active,
nav ul li a:hover {
    background-color: #2a7de1;
    color: #fff;
}

.search-box {
    margin-left: 20px;
}

.search-box input {
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px 0 0 4px;
    width: 200px;
}

.search-box button {
    padding: 8px 15px;
    background-color: #2a7de1;
    color: #fff;
    border: none;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
}

/* 主体内容样式 */
main {
    margin-top: 80px;
    padding: 20px 0;
}

.banner {
    background-color: #e8f0fd;
    padding: 40px 0;
    text-align: center;
    margin-bottom: 30px;
}

.section-title {
    font-size: 24px;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #eee;
    color: #333;
}

/* 小说网格布局 */
.novel-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.novel-item {
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    transition: transform 0.3s;
}

.novel-item:hover {
    transform: translateY(-5px);
}

.novel-cover {
    overflow: hidden;
}

.novel-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.detail-header .novel-cover img {
    width: 20rem;
    height: 100%;
    object-fit: cover;
}
.novel-info {
    padding: 15px;
}

.novel-info h3 {
    margin-bottom: 5px;
}

.novel-info h3 a {
    color: #333;
}

.novel-info .author {
    color: #666;
    font-size: 14px;
    margin-bottom: 8px;
}

.novel-info .description {
    font-size: 14px;
    color: #555;
    margin-bottom: 10px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.tags span {
    background-color: #f0f0f0;
    color: #666;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 12px;
    margin-right: 5px;
}

/* 更新列表样式 */
.update-list {
    list-style: none;
}

.update-list li {
    display: flex;
    background-color: #fff;
    padding: 15px;
    margin-bottom: 10px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.update-time {
    width: 100px;
    color: #666;
    font-weight: bold;
    padding-right: 15px;
}

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

.update-info h3 {
    margin-bottom: 5px;
}

.update-info .author {
    font-size: 14px;
    color: #666;
    margin-bottom: 5px;
}

.update-info .update-chapter {
    font-size: 14px;
    color: #2a7de1;
}

/* 分类过滤样式 */
.category-filter {
    background-color: #fff;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.filter-tags {
    margin-bottom: 10px;
}

.filter-tags span {
    display: inline-block;
    padding: 5px 12px;
    margin-right: 8px;
    background-color: #f0f0f0;
    border-radius: 20px;
    color: #666;
    font-size: 14px;
    cursor: pointer;
}

.filter-tags span.active {
    background-color: #2a7de1;
    color: #fff;
}
.filter-tags span a{
    color: #666;
}
.filter-tags span.active a{
    background-color: #2a7de1;
    color: #fff;
}
.sort-options {
    margin-top: 10px;
}

.sort-options label {
    margin-right: 10px;
}

.sort-options a {
    margin-right: 15px;
    color: #666;
    font-size: 14px;
}

.sort-options a.active {
    color: #2a7de1;
    font-weight: bold;
}

/* 分页样式 */
.pagination, .pager {
    display: flex;
    justify-content: center;
    margin-top: 30px;
    list-style-type: none;
}

.pagination li, .pager li {
    color: #2a7de1;
    padding: 8px 16px;
    text-decoration: none;
    border: 1px solid #ddd;
    margin: 0 4px;
}

.pagination li.active, .pager li.active {
    background-color: #2a7de1;
    color: white;
    border: 1px solid #2a7de1;
}

.pagination li:hover:not(.active), .pager li:hover:not(.active) {
    background-color: #ddd;
}

/* 小说详情页样式 */
.detail-header {
    display: flex;
    background-color: #fff;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.novel-cover {
    flex-shrink: 0;
}

.novel-meta {
    flex-grow: 1;
    padding: 20px
}

.novel-meta h1 {
    margin-bottom: 15px;
}

.novel-meta p {
    margin-bottom: 8px;
    color: #666;
}

.novel-meta .tags {
    margin-top: 10px;
}

.actions {
    margin-top: 20px;
}

.read-btn {
    background-color: #2a7de1;
    color: #fff;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    margin-right: 10px;
}
.read-btn a{
    color: #fff;
}
.bookmark-btn {
    background-color: #f0f0f0;
    color: #666;
    padding: 10px 20px;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
}

.description {
    line-height: 1.8;
    margin-top: 15px;
    color: #555;
}

.chapter-list {
    margin-top: 30px;
    background-color: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.chapter-group {
    margin-bottom: 20px;
}

.chapter-group h3 {
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
    margin-bottom: 10px;
}

.chapter-group ol {
    list-style-position: inside;
    list-style-type: none;
    column-count: 2;
}

.chapter-group li {
    margin-bottom: 8px;
}

.chapter-group li:nth-child(odd) {
    background-color: #f9f9f9;
}

/* 阅读页样式 */
.reading-container {
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.chapter-navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.chapter-title {
    text-align: center;
    margin: 20px 0;
}

.chapter-title h1 {
    font-size: 24px;
    color: #333;
}

.chapter-content {
    line-height: 1.8;
    font-size: 18px;
    color: #333;
    text-indent: 2em;
}

.chapter-content p {
    margin-bottom: 20px;
}

.chapter-navigation.bottom {
    margin-top: 40px;
    border-top: 1px solid #eee;
    padding-top: 20px;
}

.chapter-toc {
    text-align: center;
}

.toc-btn {
    background-color: #f0f0f0;
    color: #666;
    padding: 8px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
}

/* 搜索结果页样式 */
.search-box {
    margin-bottom: 10px;
}

.search-stats {
    color: #666;
    margin-bottom: 20px;
}

.search-filter {
    margin-bottom: 20px;
}

.result-item {
    background-color: #fff;
    padding: 20px;
    margin-bottom: 15px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.result-item h3 {
    margin-bottom: 10px;
}

.result-item h3 a {
    color: #2a7de1;
}

.result-meta {
    color: #666;
    font-size: 14px;
    margin-bottom: 10px;
}

.result-meta span {
    margin-right: 15px;
}

.result-desc {
    line-height: 1.6;
    color: #555;
    margin-bottom: 15px;
}

.read-first {
    display: inline-block;
    background-color: #2a7de1;
    color: #fff;
    padding: 8px 15px;
    border-radius: 4px;
    margin-top: 10px;
}

/* 底部样式 */
footer {
    background-color: #333;
    color: #fff;
    padding: 40px 0 20px;
}

.footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    margin-bottom: 30px;
}

.footer-col {
    width: 100%;
    margin-bottom: 20px;
}

.footer-col h3 {
    margin-bottom: 15px;
    font-size: 18px;
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 8px;
}

.footer-col ul li a {
    color: #ccc;
}

.footer-col ul li a:hover {
    color: #fff;
}

.copyright {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #444;
    color: #999;
    font-size: 14px;
}
.copyright a{
    color: #999;
}
/* 响应式设计 */
@media (max-width: 992px) {
    .detail-header {
        flex-direction: column;
    }
    
    .novel-cover {
        margin-right: 0;
        margin-bottom: 20px;
    }
    .detail-header .novel-cover img{
        width: 100%;
        height: 100%;
        object-fit: cover;  
    }
    .chapter-group ol {
        column-count: 1;
    }
}

@media (max-width: 768px) {
    header .container {
        flex-wrap: wrap;
    }
    
    nav {
        order: 3;
        width: 100%;
       /* margin-top: 15px;*/
    }
    
    nav ul {
        justify-content: center;
    }
    
    .search-box {
        margin-left: 0;
        width: 60%;
        margin-top: 15px;
    }
    
    .search-box input {
        width: 70%;
    }
    
    .footer-col {
        width: 100%;
    }
}