/* 新趣集网站样式 */

/* 全局样式 */
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

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

.navbar {
    padding: 1rem 0;
}

#logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: #333;
}

.puock-links ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
}

.puock-links li {
    margin-left: 1.5rem;
}

.puock-links a {
    color: #333;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 500;
    transition: color 0.3s ease;
}

.puock-links a:hover {
    color: #409eff;
}

/* 主内容区域 */
#content {
    margin-top: 2rem;
}

/* 文章卡片样式 */
.card {
    border: none;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    overflow: hidden;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

.card-img-top {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.card-body {
    padding: 1.5rem;
}

.card-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: #333;
}

.card-text {
    color: #666;
    margin-bottom: 1rem;
}

.card-footer {
    background-color: #f9f9f9;
    border-top: 1px solid #eee;
    padding: 1rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-footer .meta {
    font-size: 0.875rem;
    color: #999;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .navbar {
        padding: 0.75rem 0;
    }

    #logo {
        font-size: 1.25rem;
    }

    .puock-links li {
        margin-left: 1rem;
    }

    .card-img-top {
        height: 150px;
    }

    .card-body {
        padding: 1.25rem;
    }

    .card-title {
        font-size: 1.125rem;
    }
}

@media (max-width: 576px) {
    .navbar {
        padding: 0.5rem 0;
    }

    #logo {
        font-size: 1.125rem;
    }

    .puock-links li {
        margin-left: 0.75rem;
    }

    .card-img-top {
        height: 120px;
    }

    .card-body {
        padding: 1rem;
    }

    .card-title {
        font-size: 1rem;
    }
}

/* 页脚样式 */
#footer {
    background-color: #333;
    color: #fff;
    padding: 2rem 0;
    margin-top: 3rem;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
}

.footer-column {
    flex: 1;
    min-width: 200px;
    margin-bottom: 1.5rem;
}

.footer-column h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #fff;
}

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

.footer-column li {
    margin-bottom: 0.5rem;
}

.footer-column a {
    color: #ccc;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-column a:hover {
    color: #409eff;
}

.footer-bottom {
    border-top: 1px solid #444;
    margin-top: 2rem;
    padding-top: 1rem;
    text-align: center;
    font-size: 0.875rem;
    color: #999;
}

/* 按钮样式 */
.btn {
    border-radius: 4px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: #409eff;
    border-color: #409eff;
}

.btn-primary:hover {
    background-color: #66b1ff;
    border-color: #66b1ff;
}

.btn-outline-primary {
    border-color: #409eff;
    color: #409eff;
}

.btn-outline-primary:hover {
    background-color: #409eff;
    color: #fff;
}

/* 表单样式 */
.form-control {
    border-radius: 4px;
    border: 1px solid #ddd;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-control:focus {
    border-color: #409eff;
    box-shadow: 0 0 0 0.2rem rgba(64, 158, 255, 0.25);
}

/* 标签样式 */
.badge {
    border-radius: 4px;
    font-weight: 500;
    padding: 0.25rem 0.5rem;
}

.badge-primary {
    background-color: #409eff;
}

.badge-secondary {
    background-color: #909399;
}

.badge-success {
    background-color: #67c23a;
}

.badge-danger {
    background-color: #f56c6c;
}

.badge-warning {
    background-color: #e6a23c;
}

.badge-info {
    background-color: #909399;
}

/* 分页样式 */
.pagination {
    display: flex;
    justify-content: center;
    margin-top: 2rem;
}

.pagination li {
    margin: 0 0.25rem;
}

.pagination a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 4px;
    border: 1px solid #ddd;
    color: #333;
    text-decoration: none;
    transition: all 0.3s ease;
}

.pagination a:hover {
    border-color: #409eff;
    color: #409eff;
}

.pagination .active a {
    background-color: #409eff;
    border-color: #409eff;
    color: #fff;
}

/* 搜索框样式 */
#search {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
}

#search-main {
    background-color: #fff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    max-width: 500px;
    width: 90%;
}

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

.search-input {
    flex: 1;
    margin-right: 0.5rem;
}

.search-start {
    margin-right: 0.5rem;
}

/* 移动端菜单样式 */
#mobile-menu {
    position: fixed;
    top: 0;
    right: 0;
    width: 280px;
    height: 100vh;
    background-color: #fff;
    box-shadow: -2px 0 8px rgba(0, 0, 0, 0.1);
    z-index: 1500;
    transform: translateX(100%);
    transition: transform 0.3s ease;
}

#mobile-menu.active {
    transform: translateX(0);
}

#mobile-menu-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1400;
    display: none;
}

#mobile-menu-backdrop.active {
    display: block;
}

.mobile-menus {
    display: flex;
    align-items: center;
}

.mobile-menu-s {
    cursor: pointer;
}

/* 文章详情页样式 */
.single-post {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    padding: 2rem;
}

.single-post .post-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: #333;
}

.single-post .post-meta {
    font-size: 0.875rem;
    color: #999;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
}

.single-post .post-meta span {
    margin-right: 1rem;
}

.single-post .post-content {
    line-height: 1.8;
    color: #333;
}

.single-post .post-content h2 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-top: 2rem;
    margin-bottom: 1rem;
    color: #333;
}

.single-post .post-content h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    color: #333;
}

.single-post .post-content p {
    margin-bottom: 1rem;
}

.single-post .post-content img {
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    margin: 1rem 0;
}

.single-post .post-content code {
    background-color: #f5f5f5;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.875rem;
}

.single-post .post-content pre {
    background-color: #f5f5f5;
    padding: 1rem;
    border-radius: 4px;
    overflow-x: auto;
    margin: 1rem 0;
}

.single-post .post-content blockquote {
    border-left: 4px solid #409eff;
    padding-left: 1rem;
    margin: 1rem 0;
    color: #666;
}

/* 评论区样式 */
.comments-area {
    margin-top: 3rem;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    padding: 2rem;
}

.comments-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: #333;
}

.comment-form {
    margin-bottom: 2rem;
}

.comment-form input,
.comment-form textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    margin-bottom: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.comment-form input:focus,
.comment-form textarea:focus {
    border-color: #409eff;
    box-shadow: 0 0 0 0.2rem rgba(64, 158, 255, 0.25);
}

.comment-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.comment {
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #eee;
}

.comment:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.comment-author {
    display: flex;
    align-items: center;
    margin-bottom: 0.75rem;
}

.comment-author img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-right: 1rem;
}

.comment-meta {
    font-size: 0.875rem;
    color: #999;
    margin-bottom: 0.75rem;
}

.comment-content {
    color: #333;
    line-height: 1.6;
}

/* 侧边栏样式 */
.sidebar {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.sidebar h3 {
    font-size: 1.125rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: #333;
    border-bottom: 2px solid #409eff;
    padding-bottom: 0.5rem;
}

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

.sidebar li {
    margin-bottom: 0.75rem;
}

.sidebar a {
    color: #333;
    text-decoration: none;
    transition: color 0.3s ease;
}

.sidebar a:hover {
    color: #409eff;
}

/* 分类页面样式 */
.category-page {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    padding: 2rem;
}

.category-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: #333;
    border-bottom: 2px solid #409eff;
    padding-bottom: 0.5rem;
}

/* 标签页面样式 */
.tag-page {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    padding: 2rem;
}

.tag-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: #333;
    border-bottom: 2px solid #409eff;
    padding-bottom: 0.5rem;
}

/* 搜索结果页面样式 */
.search-page {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    padding: 2rem;
}

.search-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: #333;
    border-bottom: 2px solid #409eff;
    padding-bottom: 0.5rem;
}

.search-results {
    margin-top: 2rem;
}

/* 404页面样式 */
.error-404 {
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    padding: 3rem;
    text-align: center;
}

.error-404 h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: #333;
}

.error-404 p {
    font-size: 1.125rem;
    color: #666;
    margin-bottom: 2rem;
}

/* 加载动画 */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #409eff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}
