|
|
| (12 intermediate revisions by the same user not shown) |
| Line 2: |
Line 2: |
|
| |
|
|
| |
|
| /*vies130开始端*/ | | /*vies131开始端,首页横幅3张图片轮播*/ |
| /* 首页横幅:贴边填满,去掉四周空白 这个viesz1和下面viesz2是一起的,都是解决增加首页横幅的*/
| |
| body.page-Main_Page .mw-page-title-main { | | body.page-Main_Page .mw-page-title-main { |
| display: block !important; | | display: block !important; |
| color: transparent !important; /* 关键修改:让标题文字Main Page透明,但保留元素和背景 */ | | color: transparent !important; |
| height: 120px; | | height: 120px; |
| margin: 0 -16px; /* 左右贴边:抵消内容区左右 padding,-16px 为示例值 */ | | margin: 0 calc(-16px + 1mm); |
| padding: 0; | | padding: 0; |
| background-image: url("//www.chinaenglish.com/images/HomeBanner.png");
| |
| background-size: cover; /* 关键:填满整个区域,不再留白 */
| |
| background-repeat: no-repeat; | | background-repeat: no-repeat; |
| background-position: center; | | background-position: center, center, center; |
| | background-image: |
| | url("//www.chinaenglish.com/images/HomeBanner1.png"), |
| | url("//www.chinaenglish.com/images/HomeBanner2.png"), |
| | url("//www.chinaenglish.com/images/HomeBanner3.png"); |
| | animation: bannerRotate 9s infinite; |
| } | | } |
| | |
| | @keyframes bannerRotate { |
| | 0%, 30% { background-size: cover, 0 0, 0 0; } /* 只显示第1张 */ |
| | 33.33%, 63.33% { background-size: 0 0, cover, 0 0; } /* 只显示第2张 */ |
| | 66.66%, 96.66% { background-size: 0 0, 0 0, cover; } /* 只显示第3张 */ |
| | 100% { background-size: cover, 0 0, 0 0; } /* 回到第1张 */ |
| | } |
| | |
|
| |
|
| /* 重置标题上层容器的顶部间距,消除图片上方空白,让首页横幅紧靠菜单栏-viesz2 */ | | /* 重置标题上层容器的顶部间距,消除图片上方空白,让首页横幅紧靠菜单栏-viesz2 */ |
| Line 23: |
Line 33: |
| margin-top: 0 !important; | | margin-top: 0 !important; |
| } | | } |
| /*vies130结束端*/ | | |
| | /*vies131结束端*/ |
|
| |
|
|
| |
|
| Line 37: |
Line 48: |
| } | | } |
| /*viesz88结束端*/ | | /*viesz88结束端*/ |
|
| |
|
| |
| /* ============================================================
| |
| 移动端首页样式 — 欧美克制风格
| |
| 核心:中性基底 + 单一品牌强调色
| |
| ============================================================ */
| |
|
| |
| :root {
| |
| /* 中性基底 */
| |
| --canvas-bg: #ffffff;
| |
| --surface-subtle: #f7f8fa; /* 卡片/分隔区域的浅灰底 */
| |
| --text-primary: #111111; /* 近黑,保证可读性 */
| |
| --text-secondary: #5f6368; /* 辅助文字 */
| |
| --border-hairline: #e8eaed; /* 1px 极细分隔线 */
| |
|
| |
| /* 品牌强调色 — 唯一需要你修改的地方 */
| |
| --brand-accent: #2a6ebb; /* ← 替换为你的品牌色 */
| |
| --brand-accent-soft: rgba(42, 110, 187, 0.08); /* 品牌色的8%透明度,用于背景点缀 */
| |
|
| |
| /* 几何与间距 */
| |
| --radius-card: 12px; /* 欧美流行 8–14px 的中等圆角,非大圆角 */
| |
| --spacing-unit: 16px;
| |
| --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.04), 0 1px 2px rgba(0, 0, 0, 0.06);
| |
| }
| |
|
| |
| /* ---------- 画布与排版 ---------- */
| |
| body {
| |
| background: var(--canvas-bg) !important;
| |
| color: var(--text-primary);
| |
| font-size: 16px;
| |
| line-height: 1.65;
| |
| -webkit-font-smoothing: antialiased;
| |
| text-rendering: optimizeLegibility;
| |
| }
| |
|
| |
| .mw-body-content {
| |
| padding: calc(var(--spacing-unit) * 0.75) var(--spacing-unit) calc(var(--spacing-unit) * 2.5);
| |
| }
| |
|
| |
| /* ---------- 标题:强调色只作为“功能性标记”出现 ---------- */
| |
|
| |
| /* 页面主标题:不使用大面积品牌色块,只用一条细的强调色下划线 */
| |
| .mw-body-content h1.firstHeading {
| |
| font-size: 1.55rem;
| |
| font-weight: 650;
| |
| letter-spacing: -0.01em;
| |
| margin: 8px 0 20px;
| |
| padding-bottom: 10px;
| |
| border-bottom: 2px solid var(--brand-accent);
| |
| }
| |
|
| |
| /* 分区标题:强调色仅作为左侧细竖条,极克制 */
| |
| .mw-body-content h2 {
| |
| font-size: 1.2rem;
| |
| font-weight: 600;
| |
| letter-spacing: -0.005em;
| |
| margin: 32px 0 12px;
| |
| padding-left: 10px;
| |
| border-left: 3px solid var(--brand-accent);
| |
| }
| |
|
| |
| /* ---------- 内容区块:浅灰底 + 极细边框,替代重阴影 ---------- */
| |
|
| |
| /* 将首页常见列表/内容块处理为“轻表面”,而非浮动卡片 */
| |
| .mw-body-content ul,
| |
| .mw-body-content .mw-parser-output > div:not(.mw-heading) {
| |
| background: var(--surface-subtle);
| |
| border: 1px solid var(--border-hairline);
| |
| border-radius: var(--radius-card);
| |
| padding: 6px 16px;
| |
| margin: 12px 0;
| |
| box-shadow: var(--shadow-card);
| |
| list-style: none;
| |
| }
| |
|
| |
| .mw-body-content ul li {
| |
| padding: 10px 0;
| |
| border-bottom: 1px solid var(--border-hairline);
| |
| line-height: 1.55;
| |
| }
| |
| .mw-body-content ul li:last-child {
| |
| border-bottom: none;
| |
| }
| |
|
| |
| /* ---------- 链接:品牌色是唯一“有颜色”的文本 ---------- */
| |
| .mw-body-content a {
| |
| color: var(--brand-accent);
| |
| text-decoration: none;
| |
| font-weight: 500;
| |
| -webkit-tap-highlight-color: transparent;
| |
| }
| |
| .mw-body-content a:active {
| |
| opacity: 0.65;
| |
| }
| |
|
| |
| /* 已访问链接不引入第二种强调色,仅降低透明度 */
| |
| .mw-body-content a:visited {
| |
| color: var(--brand-accent);
| |
| opacity: 0.8;
| |
| }
| |
|
| |
| /* ---------- 按钮/输入类元素 ---------- */
| |
| .mw-body-content .mw-ui-button,
| |
| .mw-body-content button,
| |
| .mw-body-content input[type="submit"] {
| |
| min-height: 44px;
| |
| border-radius: 8px;
| |
| font-weight: 600;
| |
| border: none;
| |
| background: var(--brand-accent);
| |
| color: #ffffff;
| |
| padding: 0 20px;
| |
| }
| |
|
| |
| /* 次要按钮:描边风格,避免品牌色泛滥 */
| |
| .mw-body-content .mw-ui-button.mw-ui-quiet,
| |
| .mw-body-content .mw-ui-button.mw-ui-progressive {
| |
| background: transparent;
| |
| color: var(--brand-accent);
| |
| border: 1.5px solid var(--brand-accent);
| |
| }
| |
|
| |
| /* ---------- 图片与媒体 ---------- */
| |
| .mw-body-content img {
| |
| max-width: 100%;
| |
| height: auto;
| |
| border-radius: 8px;
| |
| }
| |
|
| |
| /* ---------- 可选:极淡的品牌色页面顶部氛围(非常克制) ---------- */
| |
| /* 如果你希望页面顶部有一丝品牌感,可以取消注释下面这段。
| |
| 它只在最顶部添加一个几乎不可见的渐变,不会形成“色块”。 */
| |
| /*
| |
| .mw-body {
| |
| background-image: linear-gradient(to bottom, var(--brand-accent-soft), transparent 120px);
| |
| background-repeat: no-repeat;
| |
| }
| |
| */
| |
|
| |
| /* ---------- 小屏收紧 ---------- */
| |
| @media (max-width: 480px) {
| |
| .mw-body-content {
| |
| padding-left: 14px;
| |
| padding-right: 14px;
| |
| }
| |
| .mw-body-content h1.firstHeading {
| |
| font-size: 1.4rem;
| |
| }
| |
| .mw-body-content h2 {
| |
| margin-top: 26px;
| |
| }
| |
| }
| |
/* All CSS here will be loaded for users of the MinervaNeue skin */
/*vies131开始端,首页横幅3张图片轮播*/
body.page-Main_Page .mw-page-title-main {
display: block !important;
color: transparent !important;
height: 120px;
margin: 0 calc(-16px + 1mm);
padding: 0;
background-repeat: no-repeat;
background-position: center, center, center;
background-image:
url("//www.chinaenglish.com/images/HomeBanner1.png"),
url("//www.chinaenglish.com/images/HomeBanner2.png"),
url("//www.chinaenglish.com/images/HomeBanner3.png");
animation: bannerRotate 9s infinite;
}
@keyframes bannerRotate {
0%, 30% { background-size: cover, 0 0, 0 0; } /* 只显示第1张 */
33.33%, 63.33% { background-size: 0 0, cover, 0 0; } /* 只显示第2张 */
66.66%, 96.66% { background-size: 0 0, 0 0, cover; } /* 只显示第3张 */
100% { background-size: cover, 0 0, 0 0; } /* 回到第1张 */
}
/* 重置标题上层容器的顶部间距,消除图片上方空白,让首页横幅紧靠菜单栏-viesz2 */
body.page-Main_Page .mw-body,
body.page-Main_Page .heading-holder,
body.page-Main_Page .page-heading {
padding-top: 0 !important;
margin-top: 0 !important;
}
/*vies131结束端*/
/*viesz88开始端,配合修改移动端左上角边菜单的代码*/
/* 隐藏自定义菜单项的图标占位符,并调整左侧内边距 */
#mw-mf-page-left .custom-custom-menu-item::before {
display: none !important;
}
#mw-mf-page-left .custom-custom-menu-item {
/* 因为没了图标,把左侧的 padding 调小一点,文字就不会显得太靠右 */
padding-left: 16px !important;
}
/*viesz88结束端*/