/* 基础样式 */
body {
    font-family: 'Arial', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f5f5f5;
    color: #333;
}

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

a {
    text-decoration: none;
    color: #333;
}

ul {
    list-style: none;
    margin: 0;
    padding: 0;
}

img {
    max-width: 100%;
    height: auto;
}

/* 导航栏 */
header {
    background-color: #2c3e50;
    color: white;
}

nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 0;
}

.logo {
    font-size: 24px;
    font-weight: bold;
}

.logo a {
    color: white;
}

.menu ul {
    display: flex;
}

.menu ul li {
    margin-right: 20px;
}

.menu ul li a {
    color: white;
    transition: color 0.3s;
}

.menu ul li a:hover {
    color: #3498db;
}

.search {
    display: flex;
    align-items: center;
}

.search input {
    padding: 8px;
    border: none;
    border-radius: 4px 0 0 4px;
}

.search button {
    padding: 8px 15px;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
}

/* 轮播图 */
.slider {
    margin-top: 20px;
    position: relative;
}

.slider-wrapper {
    height: 400px;
    position: relative;
    overflow: hidden;
}

.slide {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s;
}

.slide.active {
    opacity: 1;
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.slide-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 20px;
}

.slide-caption h3 {
    margin: 0;
    font-size: 24px;
}

.slide-caption p {
    margin: 5px 0 0 0;
}

.slider-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    margin: 0 5px;
    cursor: pointer;
}

.dot.active {
    background-color: white;
}

/* 主要内容 */
main {
    margin-top: 30px;
}

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

/* 漫画卡片 */
.comics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 20px;
}

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

.comic-card:hover {
    transform: translateY(-5px);
}

.comic-cover {
    position: relative;
    height: 300px;
}

.comic-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.comic-tag {
    position: absolute;
    top: 10px;
    left: 10px;
    background-color: #e74c3c;
    color: white;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 12px;
}

.comic-info {
    padding: 15px;
}

.comic-title {
    font-size: 18px;
    margin: 0 0 5px 0;
    font-weight: bold;
}

.comic-author {
    font-size: 14px;
    color: #777;
    margin: 0 0 10px 0;
}

.comic-meta {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: #555;
}

/* 最新更新 */
.updates-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.update-item {
    display: flex;
    background-color: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.update-cover {
    width: 120px;
    height: 160px;
}

.update-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.update-info {
    padding: 15px;
    flex: 1;
}

.update-title {
    font-size: 18px;
    margin: 0 0 10px 0;
    font-weight: bold;
}

.update-chapter {
    margin-bottom: 10px;
}

.update-chapter a {
    color: #3498db;
    font-weight: bold;
}

.update-time {
    color: #777;
    font-size: 12px;
    margin-left: 10px;
}

.update-meta {
    display: flex;
    gap: 15px;
    font-size: 14px;
    color: #555;
}

/* 漫画分类 */
.categories-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.category-item {
    position: relative;
    height: 150px;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.category-item img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 1;
}

.category-item span {
    position: relative;
    z-index: 2;
    color: white;
    font-size: 18px;
    font-weight: bold;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.category-item::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.3);
    z-index: 1;
}

/* 排行榜 */
.rank-tabs {
    display: flex;
    margin-bottom: 20px;
}

.tab {
    padding: 10px 20px;
    background-color: #f0f0f0;
    cursor: pointer;
    margin-right: 10px;
    border-radius: 4px;
}

.tab.active {
    background-color: #3498db;
    color: white;
}

.rank-content {
    display: none;
}

.rank-content.active {
    display: block;
}

.rank-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.rank-item {
    display: flex;
    align-items: center;
    background-color: white;
    padding: 10px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.rank-number {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background-color: #e0e0e0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    margin-right: 15px;
}

.rank-number.top3 {
    background-color: #e74c3c;
    color: white;
}

.rank-item img {
    width: 60px;
    height: 80px;
    object-fit: cover;
    margin-right: 15px;
}

.rank-info {
    flex: 1;
}

.rank-info h3 {
    margin: 0;
    font-size: 16px;
}

.rank-info p {
    margin: 5px 0 0 0;
    font-size: 14px;
    color: #777;
}

.rank-stats {
    color: #3498db;
    font-weight: bold;
}

/* 更多按钮 */
.more-btn {
    text-align: center;
    margin-top: 20px;
}

.more-btn a {
    display: inline-block;
    padding: 10px 20px;
    background-color: #3498db;
    color: white;
    border-radius: 4px;
    transition: background-color 0.3s;
}

.more-btn a:hover {
    background-color: #2980b9;
}

/* 页脚 */
footer {
    background-color: #2c3e50;
    color: white;
    margin-top: 50px;
}

.footer-top {
    display: flex;
    padding: 40px 0;
}

.footer-col {
    flex: 1;
    margin-right: 40px;
}

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

.footer-col ul {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

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

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

.social-links {
    display: flex;
    gap: 10px;
}

.social-icon {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background-color: #34495e;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: background-color 0.3s;
}

.social-icon:hover {
    background-color: #3498db;
}

.footer-bottom {
    padding: 20px 0;
    text-align: center;
    border-top: 1px solid #34495e;
}

.footer-bottom p {
    margin: 5px 0;
    font-size: 14px;
    color: #ccc;
}
    