@charset "UTF-8";
/*!
 * (c) 2026 1vdh.com · OneNav-Child | All Rights Reserved
 *
 * 审美层（ochild-aesthetic.css）
 * ------------------------------------------------------------
 * 只做「视觉语汇统一」：色彩层次、边缘、投影、排印、焦点态、滚动条。
 * 不改任何尺寸、栅格、间距、DOM 结构，也不覆盖站点自定义的主题色与圆角。
 *
 * 【为什么用 :root:root / html body 这样加特异度的写法】
 * 父主题 main.min.css 在本文件之后输出（子主题 enqueue 无法改变父主题输出顺序），
 * 若用普通 :root，父主题的 :root 令牌会覆盖本文件 → 整层失效。
 * 提高特异性比相同选择器后声明优先，因此无论加载顺序都能生效。
 *
 * 【不覆盖的令牌】
 * --theme-color / --theme-color-rgb / --hover-color / --focus-shadow-color：
 *   由后台「主题设置」内联输出，站点主色（当前青蓝 #00d0ff）必须由用户掌控。
 * --main-radius / --main-max-width / --main-aside-basis-width：
 *   由后台设置内联输出（当前圆角 15px、宽 1600px），属布局参数，本层不触碰。
 *
 * 回退：删除 functions.php 中 enqueue 句柄 ochild-aesthetic 一行即可。
 */

/* ============ 一、亮色令牌 · 冷白纸面（与青蓝主色同调） ============ */
:root:root {
  /* 面：三档亮度递进（页面略深 → 卡片纯白 → 悬浮浅灰），拉开层次 */
  --body-bg-color: #dee5ea;
  --main-bg-color: #ffffff;
  --muted-bg-color-l: #f4f7f9;
  --muted-bg-color: #e4eaef;
  --muted-bg-a-color: rgba(18, 26, 34, 0.06);

  /* 墨：三级文字层次（均满足正文 4.5:1、弱信息 3:1） */
  --main-color: #1c2126;
  --muted-color: #6e757d;
  --muted-color2: #4e565d;
  --muted-color3: #a4adb5;

  /* 边与影：1px 发丝描边嵌进阴影，全站边缘同厚度；投影冷灰低饱和 */
  --border-color: rgba(18, 26, 34, 0.10);
  --main-shadow: 0 1px 2px rgba(15, 26, 36, 0.05), 0 10px 26px -16px rgba(15, 26, 36, 0.24), inset 0 0 0 1px rgba(18, 26, 34, 0.06);
  --muted-shadow: rgba(15, 26, 36, 0.06);

  /* 毛玻璃层：与纸面同色系，避免灰白脱节 */
  --main-blur-bg-color: rgba(246, 249, 251, 0.78);
  --main-blur-bg-color2: rgba(246, 249, 251, 0.88);
  --main-blur-bg-color3: rgba(246, 249, 251, 0.62);
  --muted-blur-bg-color: rgba(228, 234, 239, 0.62);

  /* 点色派生：跟随后台主色，不写死色值 */
  --theme-color-bg: rgba(var(--theme-color-rgb), 0.06);
  --main-radius-bg: #8e969e;
}

/* ============ 二、暗色令牌 · 静夜（青蓝主色在暗底更亮眼） ============ */
:root:root.io-black-mode,
html body.io-black-mode {
  --body-bg-color: #0f1216;
  --main-bg-color: #1a1e23;
  --muted-bg-color-l: #161a1e;
  --muted-bg-color: #232830;
  --muted-bg-a-color: rgba(255, 255, 255, 0.06);

  --main-color: #c6cbd2;
  --muted-color: #9aa1aa;
  --muted-color2: #c2c8d0;
  --muted-color3: #767e87;

  /* 暗色以「高光描边」替代投影 */
  --border-color: rgba(255, 255, 255, 0.12);
  --main-shadow: 0 0 0 1px rgba(255, 255, 255, 0.05), 0 10px 26px -18px rgba(0, 0, 0, 0.9);
  --muted-shadow: rgba(0, 0, 0, 0.26);

  --main-blur-bg-color: rgba(18, 21, 25, 0.74);
  --main-blur-bg-color2: rgba(18, 21, 25, 0.86);
  --main-blur-bg-color3: rgba(18, 21, 25, 0.58);
  --muted-blur-bg-color: rgba(35, 40, 48, 0.6);

  --main-radius-bg: #3a4149;
}

/* ============ 三、排印层（提高特异性以压过 main.min.css） ============ */
html body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  /* 中文正文行高：略松，长列表更透气 */
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
}

html body {
  background-image: linear-gradient(180deg, #e4eaef 0%, #d8e0e6 100%);
}

html.io-black-mode body,
html body.io-black-mode {
  background-image: linear-gradient(180deg, #12151a 0%, #0e1114 100%);
}

html h1, html h2, html h3, html h4, html h5, html h6,
html .h1, html .h2, html .h3, html .h4, html .h5, html .h6,
html .card-title, html .url-card-title, html .sidebar-title, html .panel-title {
  letter-spacing: -0.01em;
}

html h1, html h2, html .h1, html .h2 {
  letter-spacing: -0.016em;
}

/* 均衡断行只给长文标题；短标题不参与，避免被 text-wrap 简写改写行模式 */
html .entry-title, html .post-title, html .article-title, html .page-title,
html .single-title, html .archive-title {
  text-wrap: balance;
}

/* 卡片分类标题保持父主题的单行行为 */
html .tab-title, html .card-head h2 {
  white-space: nowrap;
  text-wrap: nowrap;
}

html p, html .card-text, html .desc {
  text-wrap: pretty;
}

html hr {
  border-top-color: var(--border-color);
}

/* ============ 四、质感层 ============ */
/* 选中态：跟随后台主色 */
html ::selection {
  background: rgba(var(--theme-color-rgb), 0.16);
  color: inherit;
}

/* 滚动条：细、无凹槽、悬停加深 */
html * {
  scrollbar-width: thin;
  scrollbar-color: var(--muted-bg-color) transparent;
}

html ::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

html ::-webkit-scrollbar-track {
  background: transparent;
}

html ::-webkit-scrollbar-thumb {
  background-color: var(--muted-bg-color);
  background-clip: content-box;
  border: 3px solid transparent;
  border-radius: 999px;
}

html ::-webkit-scrollbar-thumb:hover {
  background-color: var(--muted-color3);
}

/* 键盘焦点：一圈主题色，鼠标点击不出现 */
html :focus-visible {
  outline: 2px solid var(--focus-color);
  outline-offset: 2px;
}

/* 统一缓动曲线：只替换曲线，时长与属性沿用父主题 */
html a[href], html button, html .btn, html [js-href], html .url-card, html .sidebar-card {
  transition-timing-function: cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* 图片边缘：跟随后台圆角设置，避免直角图硬切卡片 */
html .url-card img,
html .card img,
html .sidebar-card img {
  border-radius: calc(var(--main-radius) - 8px);
}

@media (prefers-reduced-motion: reduce) {
  html *, html *::before, html *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
/* ============ 六、卡片与容器归一（插件/父主题硬编码色收口） ============ */
html body article.posts-item,
html body .posts-item,
html body .sites-item {
  border: 1px solid var(--border-color);
  box-shadow: var(--main-shadow);
}
html body .card,
html body .panel.card {
  background-color: var(--main-bg-color);
  border-color: var(--border-color);
  box-shadow: var(--main-shadow);
}
html body .card,
html body .panel {
  border-radius: var(--main-radius);
}
html body .tab-content {
  border-radius: var(--main-radius);
}

/* 暗色下父主题/子主题旧补丁用的是 .io-black-mode 前缀，需同级别压过 */
html.io-black-mode body article.posts-item,
html.io-black-mode body .posts-item,
html.io-black-mode body .sites-item {
  border-color: var(--border-color);
}
html.io-black-mode body .card,
html.io-black-mode body .panel.card {
  background-color: var(--main-bg-color);
  border-color: var(--border-color);
}

/* ============ 七、收录投稿页：取消叠压，双卡并排 ============ */
/* 父主题用 170px 右内边距 + -150px 负边距做"玻璃卡压蓝卡"的叠压效果，
   导致蓝卡右侧 150px 被半透明卡盖住、右上/右下露出碎块。现改为并排、顶部对齐。 */
@media (min-width: 992px) {
  html body .contribute-header .contribute-title {
    flex: 0 0 400px;
    width: 400px;
    min-width: 400px;
  }

  html body .contribute-header .contribute-title .modal-header-bg {
    margin-top: 0;
    padding-right: 20px;
  }

  html body .contribute-header .contribute-body {
    flex: 1 1 auto;
    min-width: 0;
    margin-top: 0;
    margin-left: 16px;
  }
}

/* 条目图标（网址/文章）父主题为 absolute 上浮贴纸，压在卡片上沿并遮住色条开头；
   改为色条左端内侧垂直居中，不再悬空 */
@media (min-width: 992px) {
  html body .contribute-header .contribute-item .item-title i {
    top: 50%;
    left: 8px;
    padding: 3px;
    transform: translateY(-50%);
  }

  html body .contribute-header .contribute-item.active .item-title i {
    top: 50%;
    left: 8px;
    transform: translateY(-50%) scale(1.15);
  }
}
