Files
resume/css/base.css
T
wonder bc3d703b04
Deploy Resume / deploy (push) Failing after 3m5s
CI 构建期自动生成 PDF:微软雅黑渲染 + 站点托管下载
- 新增 scripts/pdf.mjs:构建期 Chromium 渲染 4 份 PDF(printBackground 保留蓝色底色)
- 微软雅黑字库(msyh.ttc/msyhbd.ttc)随仓库分发,构建阶段 fc-match 自检;最终镜像保持干净 nginx(无 Chromium/字体/Node)
- Dockerfile 加 pdf 中间阶段;deploy.yml 加部署后 PDF 链接验证
- 导航卡片与简历页页脚加「下载 PDF」入口
- 排版对齐 v19/soe-v3 参考稿:@page 页边距 57/55/70px,私企 1 页饱满收口、国企 2 页宽松排版
  (迭代求解缩放比例,测量版面宽度与 page.pdf 缩放语义一致)
- 页数目标写入变体清单 pdf.pages
2026-11-03 13:16:55 +08:00

489 lines
8.2 KiB
CSS
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
/* css/base.css —— 所有简历共享的布局与组件(字号由主题变量控制) */
:root {
/* 字号基准(私企主题为默认值,国企主题整体放大) */
--fs-body: 12px;
--fs-name: 28px;
--fs-contact: 12px;
--fs-section: 14px;
--fs-edu-school: 14px;
--fs-badge: 10px;
--fs-meta: 13px;
--fs-items: 13px;
--fs-honor: 13px;
--fs-honor-badge: 12px;
--fs-exp-company: 14px;
--fs-exp-position: 12px;
--fs-intro: 11px;
--fs-intro-label: 10px;
--fs-proj-name: 14px;
--fs-proj-role: 12px;
--fs-proj-link: 12px;
--fs-proj-tag: 10px;
--fs-proj-intro: 13px;
--fs-proj-work-title: 13px;
}
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family: "Microsoft YaHei", Arial, sans-serif;
background: #ffffff;
color: #222222;
line-height: 1.4;
font-size: var(--fs-body);
}
.page {
width: 794px;
min-height: 1123px;
margin: 0 auto;
padding: 12px 22px;
background: #ffffff;
}
/* Header */
.header {
margin-bottom: 8px;
}
.name {
font-size: var(--fs-name);
font-weight: 800;
color: #222222;
margin-bottom: 3px;
letter-spacing: 1px;
}
.contact-info {
font-size: var(--fs-contact);
color: #222;
line-height: 1.45;
}
.contact-line {
display: flex;
align-items: center;
gap: 18px;
margin-bottom: 1px;
}
.contact-item {
display: flex;
align-items: center;
}
.intent-item {
white-space: nowrap;
margin-right: 8px;
}
.intent-item:last-child {
margin-right: 0;
}
.intent-num {
color: #4478DF;
}
.website-line {
display: flex;
align-items: center;
flex-wrap: wrap;
margin-top: 1px;
}
.link-item {
white-space: nowrap;
margin-right: 12px;
}
.link-url {
color: #4478DF;
text-decoration: none;
}
/* Section */
.section {
margin-bottom: 6px;
}
.section-title {
font-size: var(--fs-section);
font-weight: 700;
color: #4478DF;
padding: 3px 10px;
border-left: 3px solid #4478DF;
background-color: #EEF3FF;
margin-bottom: 4px;
line-height: 1.3;
}
/* Education */
.edu-header {
display: flex;
justify-content: space-between;
align-items: baseline;
margin-bottom: 3px;
}
.edu-school {
font-size: var(--fs-edu-school);
font-weight: 700;
color: #222;
}
.edu-badge {
display: inline-block;
font-size: var(--fs-badge);
color: #4478DF;
border: 1px solid #4478DF;
border-radius: 4px;
padding: 1px 5px;
margin-left: 6px;
vertical-align: middle;
line-height: 1.4;
}
.edu-major {
font-size: var(--fs-meta);
color: #888;
margin-left: 10px;
}
.edu-degree {
font-size: var(--fs-meta);
color: #888;
margin-left: 10px;
}
.edu-date {
font-size: var(--fs-meta);
color: #888;
white-space: nowrap;
}
/* Honors(共用条目样式;两列布局见 theme-private) */
.honor-item {
display: flex;
align-items: baseline;
flex-wrap: wrap;
margin-bottom: 2px;
font-size: var(--fs-honor);
line-height: 1.45;
}
.honor-content {
color: #222;
flex: 1;
min-width: 0;
}
.honor-name {
color: #222;
}
.honor-badge {
display: inline-block;
min-width: 52px;
text-align: right;
margin-left: 4px;
font-size: var(--fs-honor-badge);
color: #888;
white-space: nowrap;
}
/* Experience */
.exp-header {
display: flex;
align-items: baseline;
margin-bottom: 1px;
}
.exp-gap {
margin-top: 10px;
}
.exp-company {
font-size: var(--fs-exp-company);
font-weight: 700;
color: #222;
}
.exp-date {
font-size: var(--fs-meta);
color: #888;
white-space: nowrap;
margin-left: 12px;
}
.exp-position {
font-size: var(--fs-exp-position);
color: #888;
flex: 1;
margin-left: 10px;
}
.exp-items {
margin-left: 12px;
font-size: var(--fs-items);
color: #252525;
line-height: 1.45;
}
.exp-items li {
list-style-type: disc;
margin-left: 6px;
margin-bottom: 0px;
}
/* 单位简介 / 项目简介(蓝灰色引用框) */
.exp-intro {
margin: 3px 0 4px 12px;
padding: 2px 8px;
font-size: var(--fs-intro);
line-height: 1.5;
color: #656464;
background: #F5F7FB;
border-left: 2px solid #B9C9EC;
border-radius: 2px;
}
.exp-intro-label {
display: inline-block;
font-size: var(--fs-intro-label);
font-weight: 700;
color: #4478DF;
margin-right: 6px;
white-space: nowrap;
}
/* Project */
.proj-header {
display: flex;
justify-content: space-between;
align-items: baseline;
margin-bottom: 1px;
}
.proj-title-line {
display: flex;
align-items: baseline;
gap: 8px;
}
.proj-name {
font-size: var(--fs-proj-name);
font-weight: 700;
color: #222;
}
.proj-role {
font-size: var(--fs-proj-role);
color: #888;
}
.proj-date {
font-size: var(--fs-meta);
color: #888;
white-space: nowrap;
}
.proj-link-line {
display: flex;
justify-content: space-between;
align-items: center;
font-size: var(--fs-proj-link);
margin-bottom: 2px;
}
.proj-tags {
display: flex;
gap: 4px;
flex-wrap: wrap;
}
.proj-tag {
display: inline-block;
font-size: var(--fs-proj-tag);
color: #4478DF;
border: 1px solid #4478DF;
border-radius: 3px;
padding: 0px 4px;
line-height: 1.4;
}
.tag-gap {
margin-right: 4px;
}
.proj-link {
color: #4478DF;
text-decoration: none;
}
.proj-work-title {
font-size: var(--fs-proj-work-title);
font-weight: 700;
color: #222;
margin-bottom: 2px;
}
.proj-work-items {
margin-left: 12px;
font-size: var(--fs-items);
color: #252525;
line-height: 1.45;
}
.proj-work-items li {
list-style-type: decimal;
margin-left: 12px;
margin-bottom: 0px;
}
/* Skills / 通用列表 */
.skill-items {
margin-left: 12px;
font-size: var(--fs-items);
color: #252525;
line-height: 1.45;
}
.skill-items li {
list-style-type: disc;
margin-left: 6px;
margin-bottom: 0px;
}
/* SVG Icons */
.svg-icon {
width: 14px;
height: 14px;
fill: #4478DF;
vertical-align: middle;
margin-right: 5px;
flex-shrink: 0;
}
/* Company Logo */
.company-logo {
height: 16px;
vertical-align: middle;
margin-left: 4px;
}
.company-logo.small {
height: 10px;
}
.company-logo.icpc {
height: 22px;
}
.company-logo.hust {
height: 22px;
}
.company-logo.qiniu {
height: 14px;
}
.company-logo.bilibili {
height: 13px;
}
.company-logo.lark {
height: 20px;
}
/* 版本切换悬浮入口(仅屏幕显示,打印隐藏) */
.version-switch {
position: fixed;
top: 14px;
right: 14px;
z-index: 99;
padding: 7px 16px;
background: #4478DF;
color: #fff;
font-size: 13px;
text-decoration: none;
border-radius: 18px;
box-shadow: 0 2px 10px rgba(68, 120, 223, 0.35);
opacity: 0.92;
}
.version-switch:hover {
opacity: 1;
text-decoration: none;
}
/* 页脚(仅屏幕显示,打印隐藏) */
.page-footer {
display: flex;
gap: 16px;
align-items: center;
margin-top: 10px;
padding-top: 6px;
border-top: 1px dashed #d5d5d5;
font-size: 11px;
color: #999;
}
.page-footer a {
color: #4478DF;
text-decoration: none;
}
.footer-hint {
margin-left: auto;
}
/* Print:保留底色、条目不跨页截断、隐藏页脚与悬浮入口
页边距参考 v19/soe-v3 简历:左右 57px、上 55px、下 70px(@page 几何,不随缩放变化) */
@media print {
@page {
size: A4;
margin: 55px 57px 70px 57px;
}
* {
-webkit-print-color-adjust: exact !important;
print-color-adjust: exact !important;
color-adjust: exact !important;
}
/* 内容流宽度 = 纸面内容区(680px),由 PDF 缩放收进目标页数 */
.page {
width: 100%;
min-height: 0;
padding: 0;
}
.section-title,
.edu-header,
.exp-header,
.proj-header,
.proj-work-title {
break-after: avoid;
}
.honor-item,
.campus-line,
.proj-intro,
.exp-intro,
.exp-items li,
.proj-work-items li,
.skill-items li {
break-inside: avoid;
}
.page-footer,
.version-switch {
display: none !important;
}
}