/* theme-corp.css — 门户主题「企业版」（D-112 / B8.3）。
   override 层：加载于 portal.css 之后，只写差异；信息架构与 DOM 不变。
   视觉基准 = docs/portal-redesign-corp.html（传统企业版原型）：
   企业深蓝 + 品牌金点缀 / 深蓝通栏导航 + 金色下划线 hover / 大留白方正大气 /
   540px 通栏 hero 最深遮罩 + 金色 CTA / 金线栏目标题 / 金 dash 列表 / 深蓝金顶 footer。
   布局骨架（3 列网格 + 首块跨行 / hero 通栏 / 卡片化）与 modern 同构，令牌与气质不同。
   D-113 还原度整改：hero 通栏破格 + 首页去面包屑 + 品牌区 logo 横排 + 备案底栏 + 防溢出。 */

:root {
  --portal-primary: #1d4a94;        /* 企业蓝（亮） */
  --portal-primary-dark: #0c2349;   /* 企业蓝（深） */
  --portal-text: #3b4454;
  --portal-muted: #707a8a;
  --portal-border: #e1e6ee;
  --portal-bg: #f5f7fa;
  --portal-link: #1d4a94;
  --tc-gold: #c9a15a;               /* 品牌金·点缀 */
  --tc-gold-dark: #a8823f;
  --tc-grad: linear-gradient(135deg, #0c2349 0%, #1d4a94 100%);
  --tc-radius: 10px;
  --tc-shadow-sm: 0 1px 2px rgba(12, 35, 73, .05);
  --tc-shadow: 0 8px 26px rgba(12, 35, 73, .1);
  --tc-shadow-lg: 0 24px 52px rgba(12, 35, 73, .16);
  --tc-ease: cubic-bezier(.22, .61, .36, 1);
}

body.portal { font-size: 16px; line-height: 1.75; -webkit-font-smoothing: antialiased; }

/* ============ Header：金边徽标 + 方正搜索 ============ */
.portal-header { position: sticky; top: 0; z-index: 50; }
.header-inner { height: auto; min-height: 100px; padding: 20px 16px; }
/* 品牌区还原原型：徽标/首字徽章居左、站名/副标题右侧两行叠排（结构在 portal.css base 层）；
   真实 logo 中性化（不加渐变底/金边装饰）。站名色精确对齐原型 --corp（#0f2b5b）。 */
.brand-name { font-size: 28px; font-weight: 800; color: #0f2b5b; letter-spacing: 2px; }
.brand-slogan { color: var(--tc-gold-dark); letter-spacing: 4px; margin-top: 5px; }
.brand-logo { border-radius: 8px; height: 58px; }
/* 无 logo 首字徽章（D-114）：corp 皮肤 = 企业蓝渐变底 + 金边金字（原型同款） */
.brand-monogram { width: 54px; height: 54px; border-radius: 8px; background: var(--tc-grad); border: 1.5px solid var(--tc-gold); color: var(--tc-gold); font-size: 24px; }
.search-box { border: 1.5px solid var(--portal-border); border-radius: 6px; overflow: hidden; background: var(--portal-bg); }
.search-box input { border: 0; background: transparent; padding: 10px 16px; }
.search-box input:focus { border-color: transparent; }
.search-box:focus-within { border-color: var(--portal-primary); box-shadow: 0 0 0 4px rgba(29, 74, 148, .1); }
.search-box button { background: var(--portal-primary-dark); border-radius: 4px; margin: 3px; padding: 8px 16px; }
.search-box button:hover { background: var(--portal-primary); }

/* ============ 主导航：深蓝通栏 + 金色下划线动效 ============ */
.portal-nav { background: var(--portal-primary-dark); border-top: 1px solid rgba(201, 161, 90, .35); }
.nav-item > a { color: rgba(255, 255, 255, .92); font-weight: 500; padding: 0 24px; height: 54px; display: flex; align-items: center; }
.nav-item > a::after {
  content: ""; position: absolute; left: 24px; right: 24px; bottom: 0; height: 3px;
  background: var(--tc-gold); transform: scaleX(0); transform-origin: center; transition: transform .25s var(--tc-ease);
}
.nav-item > a:hover { background: rgba(255, 255, 255, .06); }
.nav-item > a:hover::after { transform: scaleX(1); }
.nav-item > a.active { color: #fff; }
.nav-item > a.active::after { transform: scaleX(1); }
.nav-sub { border-radius: 6px; border: 0; border-top: 3px solid var(--tc-gold); box-shadow: var(--tc-shadow); padding: 6px; min-width: 190px; }
.nav-sub li a { border-radius: 4px; transition: background .15s, color .15s; }
.nav-sub li a:hover { background: var(--portal-bg); color: var(--portal-primary); }

/* ============ Hero：540px 通栏 + 最深遮罩 + 金色 CTA ============ */
/* 通栏破格（D-113）：carousel 挣脱 .container 全宽、紧贴导航（还原原型 hero 形态） */
html { overflow-x: hidden; overflow-x: clip; }
/* 首页隐藏面包屑：原型首页无「当前位置」条 */
.portal-main:has(> .container.home) > .breadcrumb { display: none; }
.carousel { height: 540px; margin: 0 0 64px; border-radius: 0; background: #0a1830; }
.home > .carousel { width: 100vw; margin-top: 0; margin-left: calc(50% - 50vw); margin-right: calc(50% - 50vw); }
.carousel-slide::after {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(90deg, rgba(10, 24, 48, .88) 0%, rgba(10, 24, 48, .55) 50%, rgba(10, 24, 48, .18) 100%);
}
.carousel-slide img { height: 100%; }
.carousel-slide figcaption {
  top: 0; bottom: auto; left: 0; right: 0; height: 100%; z-index: 2; background: none;
  display: flex; flex-direction: column; justify-content: center; gap: 22px;
  /* 水平内边距与实际容器（1200px + 16px padding）对齐：标题文字与下方区块左缘齐平 */
  padding: 24px max(16px, calc((100% - 1200px) / 2 + 16px)); max-width: none;
}
.carousel-title {
  font-size: clamp(26px, 3.4vw, 42px); font-weight: 800; color: #fff; line-height: 1.35;
  letter-spacing: 2px; max-width: 820px; text-shadow: 0 2px 18px rgba(0, 0, 0, .4);
}
/* D-113：删除原「双金线 eyebrow」装饰——原型 eyebrow 为「金线+文字+金线」，门户无该文字数据，
   两根悬空横线语义不明（用户反馈）；hero 收敛为 遮罩+标题+CTA。 */
.carousel-cta {
  display: inline-flex; align-items: center; gap: 8px; width: fit-content;
  background: var(--tc-gold); color: var(--portal-primary-dark); font-weight: 600; font-size: 15px;
  padding: 13px 30px; border-radius: 6px; transition: transform .2s, box-shadow .2s;
}
.carousel-cta:hover { transform: translateY(-2px); box-shadow: 0 12px 26px rgba(201, 161, 90, .35); color: var(--portal-primary-dark); }
.carousel-dots { bottom: 28px; }
.carousel-dot { width: 30px; height: 3px; border-radius: 0; transition: background .3s; }
.carousel-dot.active { background: var(--tc-gold); }

/* ============ 首页区块：3 列网格 + 首块（形态A）放大跨行 + 金线标题 ============ */
.home-blocks { grid-template-columns: repeat(3, 1fr); gap: 26px; margin: 0 0 52px; }
.home-blocks > .home-block:first-child { grid-column: 1 / 3; grid-row: 1 / 3; }
.home-blocks > .home-block:nth-child(2) { grid-column: 3; grid-row: 1 / 3; }
.home-block {
  border-radius: var(--tc-radius); padding: 24px 26px; border: 1px solid var(--portal-border);
  box-shadow: var(--tc-shadow-sm); transition: transform .25s var(--tc-ease), box-shadow .25s var(--tc-ease);
}
.home-block:hover { transform: translateY(-4px); box-shadow: var(--tc-shadow-lg); }
.home-block .block-head { border-bottom: 1.5px solid var(--portal-bg); position: relative; }
.home-block .block-head::after { content: ""; position: absolute; bottom: -1.5px; left: 0; width: 48px; height: 1.5px; background: var(--tc-gold); }
.home-block .block-head h2 { font-size: 19px; color: var(--portal-primary-dark); font-weight: 700; letter-spacing: 1.5px; }
.home-block .more:hover { color: var(--tc-gold-dark); }

/* 形态 A：头条 + 列表（D-115：cover 为不缩放圆角裁切窗口，裁住 img hover 缩放溢出） */
.block-form-a { display: flex; flex-direction: column; gap: 18px; }
.block-headline-cover { display: block; height: 300px; border-radius: var(--tc-radius); overflow: hidden; }
.block-headline-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--tc-ease); }
.block-headline:hover img { transform: scale(1.05); }
.block-headline h3 { font-size: 20px; color: #141b28; margin: 14px 0 6px; line-height: 1.55; }
.block-headline p { font-size: 14px; line-height: 1.75; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.block-list li { padding: 11px 0; border-bottom: 1px dashed var(--portal-border); transition: padding-left .2s; }
.block-list li:hover { padding-left: 6px; }
.block-list li a { color: var(--portal-text); font-size: 15px; }
.block-list li a:hover { color: var(--portal-primary); text-decoration: none; }
.block-list .date::before { /* 金 dash bullet */ content: ""; display: inline-block; width: 14px; height: 2px; background: var(--tc-gold); margin-right: 8px; vertical-align: 3px; }

/* 图库：首图 feature 跨 2×2（原型层级） */
.gallery-grid { gap: 18px; }
.home .gallery-grid > .gallery-item:first-child { grid-column: span 2; grid-row: span 2; }
.gallery-item { position: relative; border: 0; border-radius: var(--tc-radius); overflow: hidden; box-shadow: var(--tc-shadow-sm); aspect-ratio: 4 / 3; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--tc-ease); }
.gallery-item:hover img { transform: scale(1.08); }
.gallery-item span {
  position: absolute; inset: 0; display: flex; align-items: flex-end; justify-content: center;
  padding: 16px; color: #fff; font-weight: 600; font-size: 15px;
  background: linear-gradient(transparent 55%, rgba(10, 24, 48, .85)); opacity: 0; transition: opacity .3s;
}
.gallery-item:hover span { opacity: 1; }

/* ============ 内页共享：金线页题 / 卡片 / 分页 ============ */
.breadcrumb { background: transparent; border-bottom: 0; }
.page-title { border-bottom: 1.5px solid var(--portal-border); position: relative; padding: 30px 0 16px; }
.page-title::after { content: ""; position: absolute; bottom: -1.5px; left: 0; width: 64px; height: 3px; background: var(--tc-gold); border-radius: 2px; }
.page-title h1 { font-size: 27px; color: var(--portal-primary-dark); font-weight: 800; letter-spacing: 2px; }
.article-item { padding: 20px 0; }
.article-item + .article-item { border-top: 1px dashed var(--portal-border); }
.article-cover img { border-radius: 8px; }
.article-body h3 a { color: #141b28; }
.article-item:hover .article-body h3 a { color: var(--portal-primary); }
.article-detail { border-radius: var(--tc-radius); padding: 32px; box-shadow: var(--tc-shadow-sm); border-top: 3px solid var(--tc-gold); }
.article-detail h1 { font-size: 29px; font-weight: 800; color: #141b28; }
.article-content { padding: 20px 0; }
.article-content h2, .article-content h3 { color: var(--portal-primary-dark); margin-top: 1.4em; letter-spacing: .5px; }
.article-content img { border-radius: 8px; margin: 12px auto; }
.article-content p { margin: .8em 0; }
.page-link { border-radius: 6px; }
.page-link.current { background: var(--tc-grad); border-color: transparent; box-shadow: 0 4px 12px rgba(12, 35, 73, .25); }
.empty-state { border-radius: var(--tc-radius); box-shadow: var(--tc-shadow-sm); }
.error-box h1 { font-size: 56px; }
.search-page .article-body em { background: rgba(201, 161, 90, .2); color: var(--tc-gold-dark); border-radius: 3px; padding: 0 3px; }

/* ============ Footer：深蓝 + 金顶线 ============ */
.portal-footer { background: #0c1e3c; margin-top: 72px; border-top: 3px solid var(--tc-gold); overflow-wrap: break-word; }
/* 列自适应（无友链时 2 列不留空位）+ 备案列升格全宽底栏；min-width:0 + overflow-wrap
   兜底超长内容（ICP/邮箱/URL 连续串）不撑破列、不横向溢出。 */
.footer-inner { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 28px 40px; padding: 36px 16px 28px; }
.footer-col { min-width: 0; }
.footer-record { grid-column: 1 / -1; border-top: 1px solid rgba(255, 255, 255, .08); padding-top: 20px; }
.footer-title { color: #fff; letter-spacing: 1px; }
.footer-contact p, .footer-record p { font-size: 13.5px; line-height: 2; }
.footer-links-list a:hover { color: #fff; padding-left: 4px; }

/* ============ 响应式 ============ */
@media (max-width: 1024px) {
  .home-blocks { grid-template-columns: repeat(2, 1fr); }
  .home-blocks > .home-block:first-child,
  .home-blocks > .home-block:nth-child(2) { grid-column: auto; grid-row: auto; }
  .home .gallery-grid > .gallery-item:first-child { grid-column: span 2; grid-row: auto; }
}
@media (max-width: 768px) {
  .carousel { height: 400px; }
  .carousel-title { font-size: 24px; letter-spacing: 1px; }
  .carousel-slide figcaption { padding: 20px; gap: 14px; }
  .carousel-cta { padding: 10px 22px; font-size: 14px; }
  .home-blocks { grid-template-columns: 1fr; }
  .block-headline-cover { height: 200px; }
  .header-inner { height: auto; padding: 14px 16px; flex-wrap: wrap; }
  .search-box { width: 100%; order: 3; }
  .gallery-grid { grid-template-columns: 1fr 1fr; }
}
