打开/关闭菜单
打开/关闭外观设置菜单
打开/关闭个人菜单
未登录
未登录用户的IP地址会在进行任意编辑后公开展示。

MediaWiki:Citizen.css:修订间差异

MediaWiki界面页面
Rockman留言 | 贡献
创建页面,内容为“这里所有CSS都会加载给Citizen皮肤的用户:​ ---------------------------------------------------------- 1. Infobox 基础样式 ----------------------------------------------------------:​ .infobox { width: 300px; float: right; clear: right; margin: 0 0 1em 1.5em; border-collapse: collapse; border: 1px solid var(--border-color-base, #c8ccd1); border-radius: 8px; overflow: hidden; background: var(--color-surface-1, #fff)…”
 
Rockman留言 | 贡献
无编辑摘要
第1行: 第1行:
/* 这里所有CSS都会加载给Citizen皮肤的用户 */
/* ── 1. 主色调(OKLCH色彩模型) ── */
/* ----------------------------------------------------------
:root {
  1. Infobox 基础样式
    --color-progressive-oklch__h: 301;
  ---------------------------------------------------------- */
    --color-progressive-oklch__c: 0.19;
.infobox {
    --color-progressive-oklch__l: 45%;
  width: 300px;
  float: right;
  clear: right;
  margin: 0 0 1em 1.5em;
  border-collapse: collapse;
  border: 1px solid var(--border-color-base, #c8ccd1);
  border-radius: 8px;
  overflow: hidden;
  background: var(--color-surface-1, #fff);
  font-size: 0.88em;
  line-height: 1.6;
}
}


/* 角色名标题 */
/* ── 2. 浅色模式 Surface 层级 ── */
.infobox > caption {
.skin-theme-clientpref-day {
  background: var(--color-primary, #3366cc);
    --color-surface-0: #F8F6FC;
  color: #fff;
    --color-surface-1: #FFFFFF;
  font-size: 1.25em;
    --color-surface-2: #F3F0FF;
  font-weight: 700;
    --color-surface-3: #EDE9FE;
  padding: 12px 16px;
    --color-base: #2D2640;
  text-align: center;
    --color-emphasized: #1A1033;
  caption-side: top;
    --color-subtle: #7C7394;
}
}


/* 分组标题行 */
/* 自动模式下的浅色兼容 */
.infobox .infobox-header {
@media (prefers-color-scheme: light) {
  background: var(--color-primary, #3366cc);
    .skin-theme-clientpref-os {
  color: #fff;
        --color-surface-0: #F8F6FC;
  text-align: center;
        --color-surface-1: #FFFFFF;
  font-weight: 600;
        --color-surface-2: #F3F0FF;
  font-size: 0.92em;
        --color-surface-3: #EDE9FE;
  padding: 8px 12px;
    }
}
}


/* 图片行 */
/* ── 3. 页面背景纹理 ── */
.infobox .infobox-image {
.citizen-body {
  text-align: center;
    background-image: radial-gradient(ellipse at 30% 0%, rgba(124,58,237,0.05) 0%, transparent 50%), radial-gradient(ellipse at 70% 100%, rgba(245,158,11,0.04) 0%, transparent 50%);
  padding: 0;
    background-attachment: fixed;
  background: var(--color-surface-2, #f8f9fa);
}
}
.infobox .infobox-image img {
 
  max-width: 100%;
/* ── 4. 章节标题左侧色条 ── */
  height: auto;
.citizen-body .mw-heading h2 {
  display: block;
    border-left: 4px solid #7C3AED;
    padding-left: 12px;
    font-weight: 800;
}
}


/* 标签列 */
/* ── 5. Infobox 左侧悬浮 ── */
.infobox th:not(.infobox-header):not(.infobox-image) {
@media (min-width: 1200px) {
  background: color-mix(in srgb, var(--color-primary, #3366cc) 10%, transparent);
    .infobox,
  color: var(--color-primary, #3366cc);
    .portable-infobox,
  font-weight: 600;
    table.infobox {
  padding: 6px 12px;
        float: left;
  text-align: right;
        width: 280px;
  width: 35%;
        margin: 0 20px 16px 0;
  border-bottom: 1px solid var(--border-color-base, #eaecf0);
        position: sticky;
  vertical-align: top;
        top: 80px;
  white-space: nowrap;
        z-index: 10;
        border-radius: 12px;
        overflow: hidden;
        border: 1px solid rgba(124,58,237,0.10);
        box-shadow: 0 2px 12px rgba(0,0,0,0.04);
    }
    .infobox th:first-child,
    .portable-infobox .pi-header {
        background: linear-gradient(135deg, #7C3AED 0%, #F59E0B 100%);
        color: #ffffff;
        font-size: 1.15rem;
        font-weight: 800;
        letter-spacing: 2px;
        padding: 14px;
    }
}
}


/* 数据列 */
/* ── 6. 目录右侧悬浮 ── */
.infobox td {
@media (min-width: 1200px) {
  padding: 6px 12px;
    .citizen-toc {
  border-bottom: 1px solid var(--border-color-base, #eaecf0);
        position: sticky !important;
  vertical-align: top;
        top: 80px;
    }
    .citizen-toc .citizen-toc__top {
        font-weight: 700;
        border-bottom: 1px solid rgba(124,58,237,0.10);
    }
    .citizen-toc__link--active {
        color: #7C3AED !important;
        border-left: 2px solid #7C3AED;
        font-weight: 700;
    }
}
}


/* 境界高亮 */
/* ── 7. 内容卡片化 ── */
.realm-current {
.citizen-body .mw-heading + *,
  color: var(--color-destructive, #d33);
.citizen-body section > p,
  font-weight: 700;
.citizen-body section > table,
.citizen-body section > ul,
.citizen-body section > ol {
    background: #FFFFFF;
    border-radius: 10px;
    padding: 16px 20px;
    margin-bottom: 12px;
    border: 1px solid rgba(124,58,237,0.10);
    box-shadow: 0 1px 4px rgba(0,0,0,0.02);
}
}


/* ----------------------------------------------------------
/* ── 8. 表格样式 ── */
  2. Infobox 移动端适配
.wikitable {
  ---------------------------------------------------------- */
     border-collapse: collapse;
@media (max-width: 720px) {
  .infobox {
     float: none;
     width: 100%;
     width: 100%;
     max-width: 100%;
     border: 1px solid rgba(124,58,237,0.10);
     margin: 0 0 1em 0;
    border-radius: 8px;
  }
     overflow: hidden;
}
}
 
.wikitable th {
/* ----------------------------------------------------------
    background: #F3F0FF;
  3. Navbox 底部导航
    color: #1A1033;
  ---------------------------------------------------------- */
    font-weight: 600;
.navbox {
    padding: 8px 12px;
  width: 100%;
    border-bottom: 2px solid rgba(124,58,237,0.10);
  border-collapse: collapse;
  border: 1px solid var(--border-color-base, #c8ccd1);
  border-radius: 8px;
  overflow: hidden;
  margin-top: 1.5em;
  font-size: 0.88em;
  background: var(--color-surface-1, #fff);
}
}
 
.wikitable td {
.navbox-title {
    padding: 8px 12px;
  background: var(--color-primary, #3366cc);
    border-bottom: 1px solid rgba(124,58,237,0.10);
  color: #fff;
  text-align: center;
  font-weight: 700;
  padding: 8px 14px;
  font-size: 1.05em;
}
}
.navbox-title a { color: #fff; }
.navbox-title a:hover { opacity: 0.85; }


.navbox-group {
/* ── 9. 分类标签样式 ── */
  background: color-mix(in srgb, var(--color-primary, #3366cc) 10%, transparent);
.mw-normal-catlinks a {
  color: var(--color-primary, #3366cc);
    background: #F3F0FF;
  font-weight: 600;
    color: #6D28D9;
  padding: 6px 14px;
    padding: 2px 8px;
  text-align: right;
    border-radius: 4px;
  white-space: nowrap;
    font-size: 0.85rem;
  width: 1%;
    transition: background 0.15s;
  border-bottom: 1px solid var(--border-color-base, #eaecf0);
}
}
 
.mw-normal-catlinks a:hover {
.navbox-list {
    background: #7C3AED;
  padding: 6px 14px;
    color: #fff;
  border-bottom: 1px solid var(--border-color-base, #eaecf0);
  line-height: 2;
}
}


/* ----------------------------------------------------------
/* ── 10. Navbox 底部导航 ── */
  4. 战绩标记
.navbox {
  ---------------------------------------------------------- */
    border: 1px solid rgba(124,58,237,0.10);
.battle-win { color: #14866d; font-weight: 700; }
    border-radius: 10px;
.battle-lose { color: #d33; font-weight: 700; }
    overflow: hidden;
.battle-draw { color: #72777d; font-weight: 700; }
    margin-top: 24px;
 
/* ----------------------------------------------------------
  5. 引用块(角色名言)
  ---------------------------------------------------------- */
blockquote {
  border-left: 3px solid var(--color-primary, #3366cc);
  padding: 0.8em 1.2em;
  margin: 1em 0;
  background: color-mix(in srgb, var(--color-primary, #3366cc) 5%, transparent);
  border-radius: 0 6px 6px 0;
  font-style: italic;
}
}
blockquote cite {
.navbox-title {
  display: block;
    background: linear-gradient(135deg, #7C3AED 0%, #F59E0B 100%);
  margin-top: 0.5em;
    color: #fff;
  font-style: normal;
    font-weight: 700;
  font-size: 0.85em;
    padding: 8px 14px;
  opacity: 0.7;
}
}
 
.navbox-group {
/* ----------------------------------------------------------
    background: #F3F0FF;
  6. 人物关系卡片
    font-weight: 600;
  ---------------------------------------------------------- */
    padding: 6px 12px;
.relation-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 8px;
  margin: 1em 0;
}
.relation-card {
  background: var(--color-surface-2, #f8f9fa);
  border: 1px solid var(--border-color-base, #eaecf0);
  border-radius: 6px;
  padding: 10px 6px;
  text-align: center;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.relation-card:hover {
  border-color: var(--color-primary, #3366cc);
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}
.relation-label {
  font-size: 0.72em;
  opacity: 0.6;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 2px;
}
.relation-name {
  font-weight: 700;
  font-size: 0.9em;
  color: var(--color-primary, #3366cc);
}
}
.relation-name a { color: var(--color-primary, #3366cc); }


/* ----------------------------------------------------------
/* ── 11. 链接悬停效果 ── */
  7. 境界进度条
.citizen-body a:not(.new):hover {
  ---------------------------------------------------------- */
    color: #7C3AED;
.realm-bar {
    text-decoration-color: #C4B5FD;
  width: 100%;
    text-underline-offset: 3px;
  height: 6px;
  background: var(--color-surface-2, #eaecf0);
  border-radius: 100px;
  overflow: hidden;
  margin: 6px 0;
}
.realm-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--color-primary, #3366cc), #7c4dff, #d33);
  border-radius: 100px;
}
}


/* ----------------------------------------------------------
/* ── 12. CJK字体优化 ── */
  8. 分类标签美化
:root {
  ---------------------------------------------------------- */
    --font-family-citizen-base: 'Noto Sans SC';
#catlinks a {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 100px;
  font-size: 0.88em;
  margin: 1px 2px;
  background: color-mix(in srgb, var(--color-primary, #3366cc) 10%, transparent);
  transition: background 0.15s;
}
#catlinks a:hover {
  background: var(--color-primary, #3366cc);
  color: #fff;
  text-decoration: none;
}
 
/* ----------------------------------------------------------
  9. 剧透折叠块
  ---------------------------------------------------------- */
.spoiler-box {
  border: 1px dashed var(--color-destructive, #d33);
  border-radius: 6px;
  margin: 1em 0;
  overflow: hidden;
}
.spoiler-box .mw-collapsible-toggle {
  background: color-mix(in srgb, var(--color-destructive, #d33) 8%, transparent);
  color: var(--color-destructive, #d33);
  padding: 8px 14px;
  font-weight: 600;
  font-size: 0.88em;
  cursor: pointer;
  display: block;
  text-align: center;
}
}

2026年6月3日 (三) 13:22的版本

/* ── 1. 主色调(OKLCH色彩模型) ── */
:root {
    --color-progressive-oklch__h: 301;
    --color-progressive-oklch__c: 0.19;
    --color-progressive-oklch__l: 45%;
}

/* ── 2. 浅色模式 Surface 层级 ── */
.skin-theme-clientpref-day {
    --color-surface-0: #F8F6FC;
    --color-surface-1: #FFFFFF;
    --color-surface-2: #F3F0FF;
    --color-surface-3: #EDE9FE;
    --color-base: #2D2640;
    --color-emphasized: #1A1033;
    --color-subtle: #7C7394;
}

/* 自动模式下的浅色兼容 */
@media (prefers-color-scheme: light) {
    .skin-theme-clientpref-os {
        --color-surface-0: #F8F6FC;
        --color-surface-1: #FFFFFF;
        --color-surface-2: #F3F0FF;
        --color-surface-3: #EDE9FE;
    }
}

/* ── 3. 页面背景纹理 ── */
.citizen-body {
    background-image: radial-gradient(ellipse at 30% 0%, rgba(124,58,237,0.05) 0%, transparent 50%), radial-gradient(ellipse at 70% 100%, rgba(245,158,11,0.04) 0%, transparent 50%);
    background-attachment: fixed;
}

/* ── 4. 章节标题左侧色条 ── */
.citizen-body .mw-heading h2 {
    border-left: 4px solid #7C3AED;
    padding-left: 12px;
    font-weight: 800;
}

/* ── 5. Infobox 左侧悬浮 ── */
@media (min-width: 1200px) {
    .infobox,
    .portable-infobox,
    table.infobox {
        float: left;
        width: 280px;
        margin: 0 20px 16px 0;
        position: sticky;
        top: 80px;
        z-index: 10;
        border-radius: 12px;
        overflow: hidden;
        border: 1px solid rgba(124,58,237,0.10);
        box-shadow: 0 2px 12px rgba(0,0,0,0.04);
    }
    .infobox th:first-child,
    .portable-infobox .pi-header {
        background: linear-gradient(135deg, #7C3AED 0%, #F59E0B 100%);
        color: #ffffff;
        font-size: 1.15rem;
        font-weight: 800;
        letter-spacing: 2px;
        padding: 14px;
    }
}

/* ── 6. 目录右侧悬浮 ── */
@media (min-width: 1200px) {
    .citizen-toc {
        position: sticky !important;
        top: 80px;
    }
    .citizen-toc .citizen-toc__top {
        font-weight: 700;
        border-bottom: 1px solid rgba(124,58,237,0.10);
    }
    .citizen-toc__link--active {
        color: #7C3AED !important;
        border-left: 2px solid #7C3AED;
        font-weight: 700;
    }
}

/* ── 7. 内容卡片化 ── */
.citizen-body .mw-heading + *,
.citizen-body section > p,
.citizen-body section > table,
.citizen-body section > ul,
.citizen-body section > ol {
    background: #FFFFFF;
    border-radius: 10px;
    padding: 16px 20px;
    margin-bottom: 12px;
    border: 1px solid rgba(124,58,237,0.10);
    box-shadow: 0 1px 4px rgba(0,0,0,0.02);
}

/* ── 8. 表格样式 ── */
.wikitable {
    border-collapse: collapse;
    width: 100%;
    border: 1px solid rgba(124,58,237,0.10);
    border-radius: 8px;
    overflow: hidden;
}
.wikitable th {
    background: #F3F0FF;
    color: #1A1033;
    font-weight: 600;
    padding: 8px 12px;
    border-bottom: 2px solid rgba(124,58,237,0.10);
}
.wikitable td {
    padding: 8px 12px;
    border-bottom: 1px solid rgba(124,58,237,0.10);
}

/* ── 9. 分类标签样式 ── */
.mw-normal-catlinks a {
    background: #F3F0FF;
    color: #6D28D9;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.85rem;
    transition: background 0.15s;
}
.mw-normal-catlinks a:hover {
    background: #7C3AED;
    color: #fff;
}

/* ── 10. Navbox 底部导航 ── */
.navbox {
    border: 1px solid rgba(124,58,237,0.10);
    border-radius: 10px;
    overflow: hidden;
    margin-top: 24px;
}
.navbox-title {
    background: linear-gradient(135deg, #7C3AED 0%, #F59E0B 100%);
    color: #fff;
    font-weight: 700;
    padding: 8px 14px;
}
.navbox-group {
    background: #F3F0FF;
    font-weight: 600;
    padding: 6px 12px;
}

/* ── 11. 链接悬停效果 ── */
.citizen-body a:not(.new):hover {
    color: #7C3AED;
    text-decoration-color: #C4B5FD;
    text-underline-offset: 3px;
}

/* ── 12. CJK字体优化 ── */
:root {
    --font-family-citizen-base: 'Noto Sans SC';
}