/**
 * QFIA 首页样式（cnfia 视觉布局）
 * 主蓝 #005999 / 强调红 #dd3333 / 导航深红 #c31922
 */

:root {
    --c-primary: #005999;
    --c-accent: #dd3333;
    --c-nav: #c31922;
    --c-nav-dark: #a90f17;
    --c-yellow: #f9d423;
    --c-yellow-2: #ffd66b;
    --c-text: #333;
    --c-muted: #888;
    --c-line: #e8e8e8;
    --c-bg: #f3f3f3;
}

/* ==================== 全局 ==================== */
body.cnfia-style {
    background: var(--c-bg);
    color: var(--c-text);
    font: 14px/1.7 "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", Arial, sans-serif;
    margin: 0;
}

body.cnfia-style a {
    color: var(--c-text);
    text-decoration: none;
    transition: color 0.2s;
}

body.cnfia-style a:hover {
    color: var(--c-accent);
}

body.cnfia-style img {
    max-width: 100%;
    height: auto;
    border: 0;
    vertical-align: middle;
}

body.cnfia-style ul,
body.cnfia-style ol {
    list-style: none;
    margin: 0;
    padding: 0;
}

body.cnfia-style .clear::after {
    content: '';
    display: block;
    clear: both;
}

body.cnfia-style .container,
body.cnfia-style .site-content.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 10px;
    box-sizing: border-box;
}

/* ==================== 顶部信息栏 ==================== */
#primary-bar {
    background: #f6f6f6;
    border-bottom: 1px solid #ececec;
    font-size: 12px;
    color: #666;
}

#primary-bar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 32px;
}

#primary-bar #primary-menu {
    display: flex;
    gap: 14px;
}

#primary-bar #primary-menu li a,
#primary-bar #primary-menu li span {
    color: #666;
    font-size: 12px;
}

#primary-bar #primary-menu li a:hover {
    color: var(--c-accent);
}

#primary-bar .top-right {
    display: flex;
    gap: 10px;
    color: #888;
    font-size: 12px;
}

/* ==================== Logo 区 ==================== */
.site-start {
    background: #fff;
    padding: 14px 0;
    border-bottom: 1px solid #f0f0f0;
}

.site-start .container {
    display: flex;
    align-items: center;
    gap: 20px;
}

.site-branding {
    flex: 0 0 auto;
}

#logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

#logo .custom-logo,
#logo img {
    max-height: 64px;
    width: auto;
    display: block;
}

.site-title-text {
    line-height: 1.2;
}

.site-title-text .site-title {
    margin: 0;
    font-size: 28px;
    color: var(--c-nav);
    font-weight: bold;
    letter-spacing: 1px;
}

.site-title-text .site-title a {
    color: inherit;
}

.site-title-text .site-description {
    margin: 4px 0 0;
    font-size: 12px;
    color: #999;
    letter-spacing: 1px;
}

.header-search {
    flex: 1;
    max-width: 360px;
    margin-left: auto;
}

.header-search form {
    display: flex;
    border: 2px solid var(--c-nav);
    border-radius: 2px;
    overflow: hidden;
    background: #fff;
}

.header-search .search-input {
    flex: 1;
    border: 0;
    outline: 0;
    padding: 8px 12px;
    font-size: 13px;
    background: transparent;
}

.header-search .search-submit {
    background: var(--c-nav);
    color: #fff;
    border: 0;
    width: 50px;
    cursor: pointer;
    font-size: 14px;
}

.header-search .search-submit:hover {
    background: var(--c-nav-dark);
}

.header-icons {
    display: flex;
    gap: 12px;
    align-items: center;
}

.header-icons .header-icon {
    position: relative;
    width: 56px;
    text-align: center;
    font-size: 12px;
    color: #666;
    cursor: pointer;
}

.header-icons .header-icon > span {
    display: block;
    padding: 30px 0 0;
    background-repeat: no-repeat;
    background-position: center 2px;
    background-size: 26px 26px;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='26' height='26' viewBox='0 0 24 24' fill='none' stroke='%23c31922' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><rect x='5' y='2' width='14' height='20' rx='2'/><line x1='12' y1='18' x2='12.01' y2='18'/></svg>");
}

.header-icons .header-weixin > span {
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='26' height='26' viewBox='0 0 24 24' fill='none' stroke='%23c31922' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M21 11.5a8.38 8.38 0 0 1-.9 3.8 8.5 8.5 0 0 1-7.6 4.7 8.38 8.38 0 0 1-3.8-.9L3 21l1.9-5.7a8.38 8.38 0 0 1-.9-3.8 8.5 8.5 0 0 1 4.7-7.6 8.38 8.38 0 0 1 3.8-.9h.5a8.48 8.48 0 0 1 8 8v.5z'/></svg>");
}

.header-icons .qrcode-pop {
    display: none;
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;
    background: #fff;
    border: 1px solid #ddd;
    padding: 10px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    width: 140px;
}

.header-icons .qrcode-pop img {
    width: 120px;
    height: 120px;
    display: block;
    margin: 0 auto 6px;
    object-fit: contain;
}

.header-icons .qrcode-pop p {
    margin: 0;
    text-align: center;
    font-size: 12px;
}

.header-icons .header-icon:hover .qrcode-pop {
    display: block;
}

/* ==================== 主导航（红色，两行） ==================== */
.main-nav {
    background: var(--c-nav);
    border-bottom: 3px solid var(--c-nav-dark);
}

.main-nav .container {
    padding: 0;
}

.main-nav .main-menu,
.main-nav ul.main-menu {
    display: flex;
    flex-wrap: wrap;
}

.main-nav .main-menu > li {
    flex: 1 0 10%;
    min-width: 80px;
    text-align: center;
    border-right: 1px solid rgba(255, 255, 255, 0.12);
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.main-nav .main-menu > li:last-child {
    border-right: none;
}

.main-nav .main-menu > li > a {
    display: block;
    color: #fff;
    padding: 11px 6px;
    font-size: 14px;
    line-height: 1.3;
    white-space: nowrap;
}

.main-nav .main-menu > li > a:hover,
.main-nav .main-menu > li.current-menu-item > a {
    background: var(--c-nav-dark);
    color: #fff;
}

/* 移动端菜单触发按钮 */
.mobile-menu-toggle {
    display: none;
    background: var(--c-nav-dark);
    color: #fff;
    border: 0;
    width: 100%;
    padding: 10px;
    font-size: 14px;
    cursor: pointer;
    text-align: left;
    padding-left: 16px;
}

.mobile-menu-toggle::before {
    content: '☰ 全部栏目';
}

/* ==================== 内容区 ==================== */
.site-content {
    padding: 14px 10px 26px;
}

/* ==================== 黄色头条 banner ==================== */
.adwidget {
    margin: 12px 0;
}

.adwidget.header-ad .ad-link {
    display: block;
    width: 100%;
    text-align: center;
    height: 70px;
    line-height: 70px;
    font-size: 26px;
    font-weight: bold;
    letter-spacing: 2px;
    text-decoration: none;
    overflow: hidden;
}

.adwidget.ad-yellow .ad-link {
    background: linear-gradient(180deg, #ffec8b 0%, #ffd54a 50%, #f8b500 100%);
    color: var(--c-accent);
    border: 1px solid #d8a800;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5);
}

.adwidget.ad-yellow-2 .ad-link {
    background: linear-gradient(180deg, #fff7c8 0%, #fee066 100%);
    color: #6b3a00;
    border: 1px solid #c8a000;
}

.adwidget.ad-red .ad-link {
    background: linear-gradient(180deg, #5b1313 0%, #2b0606 100%);
    color: #fff5d6;
    border: 1px solid #3a0808;
}

.adwidget.ad-red .ad-link .ad-text {
    background: linear-gradient(90deg, #fff7d0, #f8e89a);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* ==================== 重要新闻头条区 ==================== */
.home-headline {
    background: #fff;
    border: 1px solid var(--c-line);
    padding: 18px 26px 14px;
    margin-bottom: 14px;
    position: relative;
}

.home-headline .headline-tag {
    position: absolute;
    top: 14px;
    left: 0;
    background: var(--c-accent);
    color: #fff;
    padding: 4px 10px;
    font-size: 12px;
    letter-spacing: 1px;
    line-height: 1.4;
}

.home-headline .headline-title {
    margin: 0 0 8px;
    text-align: center;
    font-size: 26px;
    line-height: 1.3;
    font-weight: bold;
}

.home-headline .headline-title a {
    color: var(--c-accent);
}

.home-headline .headline-title a:hover {
    color: var(--c-nav-dark);
}

.home-headline .sub-titles {
    text-align: center;
    color: #555;
    font-size: 13px;
    line-height: 1.9;
    border-top: 1px dashed #eee;
    padding-top: 8px;
}

.home-headline .sub-titles a {
    color: #555;
    margin: 0 10px;
    display: inline-block;
}

.home-headline .sub-titles a:hover {
    color: var(--c-accent);
}

/* ==================== 大幻灯片 + 小特色（2×2） ==================== */
#featured-content {
    display: grid;
    grid-template-columns: 720px 1fr;
    gap: 12px;
    margin-bottom: 14px;
}

.featured-slider {
    position: relative;
    background: #000;
    height: 408px;
    overflow: hidden;
    border-radius: 0;
    box-shadow: none;
}

.featured-slider .bxslider {
    position: relative;
    width: 100%;
    height: 100%;
}

.featured-slide {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.6s ease-in-out;
}

.featured-slide.active {
    opacity: 1;
    z-index: 2;
}

.featured-slide a.slide-link {
    display: block;
    width: 100%;
    height: 100%;
    color: #fff;
    position: relative;
}

.featured-slide .slide-thumb,
.featured-slide .slide-thumb img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.featured-slide .slide-thumb .thumb-placeholder,
.featured-slide .thumb-placeholder {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #2c5aa0 0%, #c31922 100%);
}

.featured-slide .entry-header {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.55) 60%, transparent 100%);
    padding: 36px 20px 14px;
}

.featured-slide .entry-title {
    margin: 0;
    color: #fff;
    font-size: 18px;
    line-height: 1.4;
    font-weight: bold;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6);
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
}

/* 幻灯片箭头/指示点（slider.js 注入） */
.featured-slider .slider-dots {
    position: absolute;
    bottom: 12px;
    right: 14px;
    z-index: 5;
    display: flex;
    gap: 8px;
}

.featured-slider .slider-dots span {
    width: 9px;
    height: 9px;
    background: rgba(255, 255, 255, 0.55);
    border-radius: 50%;
    cursor: pointer;
}

.featured-slider .slider-dots span.active {
    background: var(--c-accent);
}

.featured-slider .slider-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 36px;
    height: 56px;
    background: rgba(0, 0, 0, 0.4);
    color: #fff;
    border: 0;
    font-size: 26px;
    cursor: pointer;
    z-index: 5;
}

.featured-slider .slider-arrow:hover {
    background: rgba(0, 0, 0, 0.7);
}

.featured-slider .slider-arrow.prev { left: 0; }
.featured-slider .slider-arrow.next { right: 0; }

/* 右侧 2×2 小特色 */
.featured-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(2, 1fr);
    gap: 8px;
    height: 408px;
}

.featured-small {
    position: relative;
    overflow: hidden;
    background: #ddd;
}

.featured-small a {
    display: block;
    width: 100%;
    height: 100%;
    color: #fff;
}

.featured-small .thumbnail-wrap,
.featured-small .thumbnail-wrap img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.featured-small .thumb-placeholder {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #4a7bc8 0%, #2c5aa0 100%);
}

.featured-small .entry-header {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.4) 70%, transparent 100%);
    padding: 18px 10px 8px;
}

.featured-small .entry-title {
    margin: 0;
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
}

.featured-small:hover .entry-header {
    background: linear-gradient(to top, var(--c-accent) 0%, rgba(221, 51, 51, 0.6) 70%, transparent 100%);
}

/* ==================== 黄色滚动资讯条 ==================== */
.news-ribbon {
    display: flex;
    align-items: center;
    height: 44px;
    background: linear-gradient(180deg, #fff7c8 0%, #fed95a 100%);
    border: 1px solid #d4a418;
    overflow: hidden;
    margin-bottom: 14px;
}

.news-ribbon .ribbon-tag {
    flex: 0 0 auto;
    background: var(--c-accent);
    color: #fff;
    height: 100%;
    line-height: 44px;
    padding: 0 16px;
    font-size: 14px;
    font-weight: bold;
    letter-spacing: 1px;
}

.news-ribbon .ribbon-track {
    flex: 1;
    overflow: hidden;
    position: relative;
    height: 44px;
}

.news-ribbon .ribbon-list {
    display: flex;
    gap: 32px;
    white-space: nowrap;
    align-items: center;
    height: 100%;
    padding-left: 16px;
    will-change: transform;
    animation: ribbon-scroll 40s linear infinite;
}

.news-ribbon .ribbon-list:hover {
    animation-play-state: paused;
}

.news-ribbon .ribbon-item {
    color: var(--c-accent);
    font-size: 13px;
    font-weight: 500;
}

.news-ribbon .ribbon-item:hover {
    color: var(--c-nav-dark);
    text-decoration: underline;
}

@keyframes ribbon-scroll {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); }
}

/* ==================== 三栏分块 (primary-block-3) ==================== */
.content-block.primary-block-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin: 14px 0;
}

.primary-block-3 .my-block {
    background: #fff;
    border: 1px solid var(--c-line);
    overflow: hidden;
}

.primary-block-3 .section-heading {
    display: flex;
    align-items: center;
    padding: 10px 14px;
    border-bottom: 2px solid var(--c-accent);
    background: #fff;
    gap: 10px;
}

.primary-block-3 .section-heading h3 {
    margin: 0;
    font-size: 17px;
    font-weight: bold;
    color: var(--c-accent);
    flex: 0 0 auto;
}

.primary-block-3 .section-heading h3 a {
    color: inherit;
}

.primary-block-3 .section-heading .sub-tabs {
    display: flex;
    gap: 8px;
    flex: 1;
    overflow: hidden;
}

.primary-block-3 .section-heading .sub-tabs li a {
    color: #888;
    font-size: 13px;
    white-space: nowrap;
}

.primary-block-3 .section-heading .sub-tabs li a:hover {
    color: var(--c-accent);
}

.primary-block-3 .section-heading .section-more {
    margin-left: auto;
}

.primary-block-3 .section-heading .section-more a {
    color: #999;
    font-size: 12px;
}

.primary-block-3 .section-heading .section-more a:hover {
    color: var(--c-accent);
}

.primary-block-3 .block-content {
    padding: 12px 14px 14px;
}

.primary-block-3 .post-big {
    margin-bottom: 10px;
}

.primary-block-3 .post-big .thumbnail-wrap {
    width: 100%;
    height: 170px;
    overflow: hidden;
    background: #eee;
    margin-bottom: 8px;
    position: relative;
}

.primary-block-3 .post-big .thumbnail-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s;
}

.primary-block-3 .post-big:hover .thumbnail-wrap img {
    transform: scale(1.04);
}

.primary-block-3 .post-big .thumbnail-wrap .thumb-placeholder {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #d8e3f3, #a8c0e0);
}

.primary-block-3 .post-big .entry-title {
    margin: 0;
    font-size: 15px;
    line-height: 1.5;
    font-weight: 600;
    color: #222;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
}

.primary-block-3 .post-big a:hover .entry-title {
    color: var(--c-primary);
}

.primary-block-3 .post-small {
    padding: 7px 0 7px 14px;
    border-bottom: 1px dashed #eee;
    position: relative;
}

.primary-block-3 .post-small::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    width: 4px;
    height: 4px;
    background: var(--c-accent);
    border-radius: 50%;
    transform: translateY(-50%);
}

.primary-block-3 .post-small.last {
    border-bottom: none;
}

.primary-block-3 .post-small .entry-title {
    margin: 0;
    font-size: 13px;
    line-height: 1.6;
    font-weight: normal;
    color: #444;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.primary-block-3 .post-small a:hover .entry-title {
    color: var(--c-accent);
}

/* ==================== 方块栏目 (content-block-square) ==================== */
.content-block-square {
    background: #fff;
    border: 1px solid var(--c-line);
    margin: 14px 0;
}

.content-block-square .section-heading {
    display: flex;
    align-items: center;
    padding: 10px 14px;
    border-bottom: 2px solid var(--c-accent);
    background: #fff;
    gap: 14px;
}

.content-block-square .section-heading h3 {
    margin: 0;
    font-size: 17px;
    color: var(--c-accent);
    font-weight: bold;
}

.content-block-square .section-heading h3 a {
    color: inherit;
}

.content-block-square .section-heading .sub-tabs {
    display: flex;
    gap: 6px;
    flex: 1;
    overflow: hidden;
}

.content-block-square .section-heading .sub-tabs li a {
    color: #555;
    font-size: 13px;
    padding: 3px 10px;
    border-radius: 2px;
    white-space: nowrap;
}

.content-block-square .section-heading .sub-tabs li a:hover {
    color: #fff;
    background: var(--c-accent);
}

.content-block-square .section-heading .section-more {
    margin-left: auto;
}

.content-block-square .section-heading .section-more a {
    color: #999;
    font-size: 12px;
}

.content-block-square .block-loop {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 12px;
    padding: 14px;
}

.content-block-square .square-item {
    background: #f9f9f9;
    border: 1px solid #eee;
    overflow: hidden;
    transition: box-shadow 0.3s;
}

.content-block-square .square-item:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.content-block-square .square-item .thumbnail-wrap {
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: #eee;
    position: relative;
}

.content-block-square .square-item .thumbnail-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.content-block-square .square-item .thumb-placeholder {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #f0e8d0 0%, #d4b88a 100%);
}

.content-block-square .square-item .entry-header {
    padding: 8px 8px;
    background: #fff;
    border-top: 1px solid #efefef;
}

.content-block-square .square-item .entry-title {
    margin: 0;
    font-size: 12px;
    font-weight: normal;
    color: #444;
    text-align: center;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.4;
}

.content-block-square .square-item:hover .entry-title {
    color: var(--c-primary);
}

/* ==================== 优秀品牌（合作伙伴） ==================== */
.footer-partners {
    background: #fff;
    border: 1px solid var(--c-line);
    margin: 14px 0;
    padding: 14px 16px;
}

.footer-partners .partner-title {
    display: flex;
    align-items: center;
    border-bottom: 1px dashed #eee;
    padding-bottom: 8px;
    margin-bottom: 14px;
}

.footer-partners .partner-title h3 {
    margin: 0;
    font-size: 15px;
    color: var(--c-accent);
    font-weight: bold;
    border-left: 4px solid var(--c-accent);
    padding-left: 10px;
}

.footer-partners .partner-title .partner-contact {
    margin-left: auto;
    color: #888;
    font-size: 13px;
}

.footer-partners .partner-title .partner-contact a {
    color: var(--c-primary);
}

.footer-partners .partner-wrap {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 12px;
}

.footer-partners .partner-image {
    text-align: center;
    border: 1px solid #f0f0f0;
    padding: 6px;
    background: #fafafa;
}

.footer-partners .partner-image a {
    display: block;
    width: 100%;
    aspect-ratio: 5 / 3;
    overflow: hidden;
    background: #eee;
    margin-bottom: 6px;
    position: relative;
}

.footer-partners .partner-image a img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.footer-partners .partner-placeholder {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #fff5e0, #f0d4a0);
}

.footer-partners .widget-title {
    font-size: 12px;
    color: #555;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ==================== 友情链接 ==================== */
.friend {
    background: #fff;
    border: 1px solid var(--c-line);
    margin: 14px 0;
    padding: 14px 16px;
}

.friend .friend-title {
    border-bottom: 1px dashed #eee;
    padding-bottom: 8px;
    margin-bottom: 12px;
}

.friend .friend-title h3 {
    margin: 0;
    font-size: 15px;
    color: var(--c-accent);
    font-weight: bold;
    border-left: 4px solid var(--c-accent);
    padding-left: 10px;
}

.friend .friend-link {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 14px;
}

.friend .friend-desc h4 {
    margin: 0 0 6px;
    font-size: 13px;
    color: var(--c-accent);
    font-weight: bold;
    border-bottom: 1px dashed #eee;
    padding-bottom: 5px;
}

.friend .friend-nav {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.friend .friend-nav li a {
    color: #555;
    font-size: 12px;
    line-height: 1.7;
}

.friend .friend-nav li a:hover {
    color: var(--c-primary);
}

/* ==================== 底部 footer ==================== */
.cnfia-footer {
    margin-top: 22px;
    background: #2a2a2a;
    color: #bbb;
    border-top: 4px solid var(--c-nav);
}

.cnfia-footer .footer-content {
    padding: 26px 0 18px;
}

.cnfia-footer .footer-columns {
    display: grid;
    grid-template-columns: 2.4fr 1.2fr 1.6fr;
    gap: 30px;
    align-items: flex-start;
}

.cnfia-footer .footer-col-title {
    margin: 0 0 12px;
    font-size: 15px;
    color: #fff;
    border-bottom: 1px solid #444;
    padding-bottom: 8px;
}

.cnfia-footer .footer-menu {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 0;
}

.cnfia-footer .footer-menu li {
    width: 25%;
}

.cnfia-footer .footer-menu li a {
    color: #bbb;
    font-size: 13px;
    line-height: 1.9;
}

.cnfia-footer .footer-menu li a:hover {
    color: #fff;
}

.cnfia-footer .follow-us {
    display: flex;
    gap: 14px;
}

.cnfia-footer .follow-item {
    text-align: center;
}

.cnfia-footer .follow-item img {
    width: 110px;
    height: 110px;
    background: #fff;
    padding: 4px;
    object-fit: contain;
}

.cnfia-footer .follow-item p {
    margin: 6px 0 0;
    font-size: 12px;
    color: #bbb;
}

.cnfia-footer .footer-col-about p {
    margin: 0;
    font-size: 13px;
    line-height: 1.8;
    color: #aaa;
}

#site-bottom {
    border-top: 1px solid #444;
    padding: 14px 10px;
    font-size: 12px;
    color: #aaa;
}

#site-bottom .bottom {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 10px;
}

#site-bottom .bottom-left {
    flex: 1;
    min-width: 320px;
}

#site-bottom .bottom-left .separator {
    color: #555;
    margin: 0 8px;
}

#site-bottom .bottom-left a {
    color: #bbb;
}

#site-bottom .bottom-left a:hover {
    color: #fff;
}

#site-bottom .site-info {
    text-align: right;
    flex: 1;
    min-width: 320px;
}

#site-bottom .site-info p {
    margin: 0 0 4px;
    line-height: 1.6;
}

.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 20px;
    width: 44px;
    height: 44px;
    background: var(--c-nav);
    color: #fff;
    border-radius: 4px;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 999;
    transition: opacity 0.3s;
    text-align: center;
    line-height: 44px;
    font-size: 22px;
    font-style: normal;
}

.back-to-top.show,
.back-to-top.visible {
    display: flex;
}

.back-to-top:hover {
    background: var(--c-nav-dark);
}

/* ==================== 响应式（≤1280） ==================== */
@media (max-width: 1280px) {
    body.cnfia-style .container,
    body.cnfia-style .site-content.container {
        max-width: 100%;
    }
    #featured-content {
        grid-template-columns: 60% 1fr;
    }
}

/* 平板（≤1024） */
@media (max-width: 1024px) {
    .site-title-text .site-title { font-size: 22px; }
    .header-search { max-width: 280px; }
    #featured-content {
        grid-template-columns: 1fr 1fr;
    }
    .featured-slider, .featured-grid { height: 320px; }
    .content-block.primary-block-3 {
        grid-template-columns: repeat(2, 1fr);
    }
    .content-block-square .block-loop {
        grid-template-columns: repeat(4, 1fr);
    }
    .footer-partners .partner-wrap {
        grid-template-columns: repeat(4, 1fr);
    }
    .friend .friend-link {
        grid-template-columns: repeat(3, 1fr);
    }
    .cnfia-footer .footer-columns {
        grid-template-columns: 1fr 1fr;
    }
    .cnfia-footer .footer-col-about {
        grid-column: 1 / -1;
    }
}

/* 手机（≤767）-- 与第二张截图一致 */
@media (max-width: 767px) {
    body.cnfia-style { font-size: 13px; }

    /* 顶部信息栏简化 */
    #primary-bar { display: none; }

    /* 站点头部紧凑 */
    .site-start { padding: 10px 0; }
    .site-start .container {
        flex-direction: row;
        gap: 8px;
        align-items: center;
        flex-wrap: wrap;
    }
    #logo .custom-logo, #logo img { max-height: 42px; }
    .site-title-text .site-title { font-size: 18px; }
    .site-title-text .site-description { font-size: 11px; }
    .header-search {
        order: 3;
        width: 100%;
        max-width: 100%;
        margin: 0;
    }
    .header-icons { display: none; }

    /* 红色导航：移动端折叠 */
    .main-nav .container { padding: 0; }
    .mobile-menu-toggle { display: block; }
    .main-nav .main-menu {
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
    }
    .main-nav.menu-open .main-menu {
        max-height: 800px;
    }
    .main-nav .main-menu > li {
        flex: 0 0 25%;
        min-width: 0;
        text-align: center;
    }
    .main-nav .main-menu > li > a {
        padding: 10px 4px;
        font-size: 13px;
    }

    /* 内容区 */
    .site-content { padding: 8px 8px 20px; }

    /* 黄色 banner */
    .adwidget.header-ad .ad-link {
        height: 50px;
        line-height: 50px;
        font-size: 16px;
        letter-spacing: 1px;
        padding: 0 10px;
    }

    /* 头条 */
    .home-headline { padding: 14px 14px 12px; }
    .home-headline .headline-tag {
        position: static;
        display: inline-block;
        margin-bottom: 6px;
    }
    .home-headline .headline-title { font-size: 18px; }
    .home-headline .sub-titles { font-size: 12px; }
    .home-headline .sub-titles a { margin: 0 6px; }

    /* 焦点图：单列堆叠 */
    #featured-content {
        grid-template-columns: 1fr;
        gap: 8px;
    }
    .featured-slider {
        height: 220px;
    }
    .featured-slide .entry-title { font-size: 15px; }
    .featured-grid {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: auto;
        height: auto;
    }
    .featured-small {
        aspect-ratio: 4 / 3;
        height: auto;
    }

    /* 滚动资讯条 */
    .news-ribbon { height: 38px; }
    .news-ribbon .ribbon-tag { line-height: 38px; padding: 0 10px; font-size: 13px; }
    .news-ribbon .ribbon-track { height: 38px; }
    .news-ribbon .ribbon-item { font-size: 12px; }

    /* 三栏堆叠为单列 */
    .content-block.primary-block-3 {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    .primary-block-3 .section-heading h3 { font-size: 15px; }
    .primary-block-3 .section-heading .sub-tabs li a { font-size: 12px; }
    .primary-block-3 .post-big .thumbnail-wrap { height: 180px; }

    /* 方块栏目 2 列 */
    .content-block-square .section-heading {
        flex-wrap: wrap;
        gap: 8px;
    }
    .content-block-square .section-heading h3 { font-size: 15px; }
    .content-block-square .section-heading .sub-tabs { flex-wrap: wrap; }
    .content-block-square .section-heading .sub-tabs li a { font-size: 12px; padding: 2px 8px; }
    .content-block-square .block-loop {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
        padding: 10px;
    }

    /* 优秀品牌：3 列 */
    .footer-partners .partner-wrap {
        grid-template-columns: repeat(3, 1fr);
    }

    /* 友情链接：2 列 */
    .friend .friend-link {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    /* 底部三栏 → 单列 */
    .cnfia-footer .footer-content { padding: 18px 0 12px; }
    .cnfia-footer .footer-columns {
        grid-template-columns: 1fr;
        gap: 18px;
    }
    .cnfia-footer .footer-menu li { width: 33.33%; }
    .cnfia-footer .follow-us { justify-content: flex-start; }
    .cnfia-footer .follow-item img { width: 90px; height: 90px; }

    #site-bottom .bottom { flex-direction: column; }
    #site-bottom .site-info { text-align: left; min-width: 0; }
    #site-bottom .bottom-left { min-width: 0; }
}

/* 小屏（≤480） */
@media (max-width: 480px) {
    .featured-slider { height: 180px; }
    .featured-small { aspect-ratio: 16 / 10; }
    .featured-small .entry-title { font-size: 12px; }
    .home-headline .headline-title { font-size: 16px; }
    .footer-partners .partner-wrap { grid-template-columns: repeat(2, 1fr); }
    .friend .friend-link { grid-template-columns: 1fr; }
    .cnfia-footer .footer-menu li { width: 50%; }
}
