/*
Theme Name: portal32
Description: 深蓝科技 真正CSS瀑布流三列布局 WordPress主题
Version: 1.0
Author: Custom
*/
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
body {
    font-family: "Microsoft YaHei", "Segoe UI", sans-serif;
    background-color: #f0f6ff;
    color: #232a38;
    line-height: 1.75;
}
a {
    color: #1954c4;
    text-decoration: none;
    transition: color 0.2s;
}
a:hover {
    color: #0f3b8c;
}
img {
    max-width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
}
.container {
    max-width: 1340px;
    margin: 0 auto;
    padding: 0 16px;
}

/* 头部导航 */
.site-header {
    background-color: #0b2447;
    padding: 26px 0;
}
.header-wrap {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.site-logo a {
    font-size: 26px;
    font-weight: 700;
    color: #4096ff;
    text-decoration: none;
}
.site-menu a {
    color: #e6edf7;
    margin-left: 24px;
    font-size: 14px;
}

/* 主体框架：三栏结构 + 中间瀑布流区域 */
.main-wrap {
    display: grid;
    grid-template-columns: 260px 1fr 260px;
    gap: 28px;
    margin: 40px 0;
}

/* ========== 真正 CSS 三列瀑布流 核心代码 ========== */
.waterfall-container {
    /* 开启多列瀑布流 */
    column-count: 3;
    column-gap: 28px;
    column-fill: balance;
}
.waterfall-item {
    /* 防止卡片被列分割 */
    break-inside: avoid;
    -webkit-break-inside: avoid;
    background: #fff;
    padding: 24px;
    border-radius: 12px;
    box-shadow: 0 3px 14px rgba(25, 84, 196, 0.08);
    margin-bottom: 28px;
}
/* =============================================== */

/* 文章内容样式 */
.item-thumb {
    width: 100%;
    margin-bottom: 16px;
}
.item-title {
    font-size: 18px;
    margin-bottom: 10px;
    font-weight: 500;
}
.item-meta {
    font-size: 12px;
    color: #718096;
    margin-bottom: 12px;
}
.item-meta span {
    margin-right: 12px;
}
.item-excerpt {
    font-size: 14px;
    color: #4a5568;
}

/* 面包屑导航 */
.bread-crumb {
    background: #fff;
    padding: 12px 18px;
    border-left: 4px solid #1954c4;
    border-radius: 6px;
    margin-bottom: 28px;
    font-size: 13px;
}

/* 分页 */
.page-nav {
    text-align: center;
    margin: 10px 0 30px;
}
.page-nav a,
.page-nav span {
    display: inline-block;
    padding: 8px 16px;
    border: 1px solid #c9d8f0;
    border-radius: 6px;
    margin: 0 4px;
    font-size: 14px;
}
.page-nav .current {
    background: #1954c4;
    color: #fff;
    border-color: #1954c4;
}

/* 侧边栏通用 */
.sidebar-box {
    background: #fff;
    padding: 24px;
    border-radius: 12px;
    box-shadow: 0 3px 14px rgba(25, 84, 196, 0.08);
}
.widget-block {
    margin-bottom: 30px;
}
.widget-title {
    font-size: 16px;
    padding-bottom: 8px;
    border-bottom: 2px solid #1954c4;
    margin-bottom: 18px;
}
.side-list-item {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
}
.side-thumb {
    width: 52px;
    height: 52px;
    object-fit: cover;
    flex-shrink: 0;
}

/* 文章详情页 */
.single-box {
    background: #fff;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 3px 14px rgba(25, 84, 196, 0.08);
}
.single-title {
    font-size: 28px;
    margin-bottom: 16px;
}
.single-meta {
    font-size: 13px;
    color: #718096;
    margin-bottom: 24px;
}
.single-content {
    font-size: 16px;
    line-height: 2;
    margin-bottom: 30px;
}
.post-prev-next {
    padding: 18px 0;
    border-top: 1px dashed #d0dceb;
    border-bottom: 1px dashed #d0dceb;
    margin-bottom: 30px;
}
.related-list > div {
    padding: 8px 0;
    border-bottom: 1px dotted #e2e8f0;
}

/* 页脚 */
.site-footer {
    background: #0b2447;
    color: #a0b4d8;
    text-align: center;
    padding: 28px 0;
    margin-top: 30px;
    font-size: 13px;
}
.site-footer a {
    color: #7fb3ff;
}

/* 移动端适配：三列瀑布流 → 单列，侧边栏移到正文下方 */
@media (max-width: 1180px) {
    .main-wrap {
        grid-template-columns: 1fr;
    }
    .sidebar-box {
        order: 3;
        margin-top: 20px;
    }
}
@media (max-width: 768px) {
    .waterfall-container {
        column-count: 1;
    }
    .header-wrap {
        flex-direction: column;
        gap: 16px;
    }
}