@charset "UTF-8";
/* /assets/css/custom.css */
@font-face {
  font-family: 'HuWenMingChaoTi';
  src: url("../fonts/HuWenMingChaoTi-subset.woff2") format("woff2"), url("../fonts/HuWenMingChaoTi.woff2") format("woff2"), url("../fonts/HuWenMingChaoTi.woff") format("woff");
  font-weight: normal;
  font-style: normal;
  font-display: swap; }

body {
  /* 覆蓋字體 */
  --font-primary: 'HuWenMingChaoTi', Verdana, sans-serif;
  /* 新增：覆蓋主要字體大小 (原默認為 1em) */
  /* 可以試試 1.1em, 1.15em, 1.2em 或 17px, 18px 等 */
  --font-size-primary: 1.15em;
  /* 將這行的值調整到你滿意的大小 */ }

/* center any element with .center-image */
.center-image {
  display: block;
  margin: 0 auto; }

img.img-narrow {
  width: 100%;
  max-width: 420px;
  display: block;
  margin: 1.5rem auto; }

/* 避免日期換行 */
ul.blog-posts li span:first-child {
  white-space: nowrap;
  /* 一行到底 */ }

/* 若仍擠不下，再酌量放寬固定寬度 */
@media (min-width: 640px) {
  ul.blog-posts li span:first-child {
    flex: 0 0 140px; } }

/* ⬇︎手機寬度時，給日期和標題之間加間距 */
@media (max-width: 639px) {
  ul.blog-posts li span:first-child {
    margin-right: 0.5em;
    /* 想大一點就調數值 */ } }

/* 可選：若需調整標題大小，可參考以下示例
   h1 { font-size: 2.2rem; }
   h2 { font-size: 1.8rem; }
*/
/* === Image Lightbox (Click to expand) === */
img:not(.no-zoom) {
  cursor: zoom-in;
  transition: transform 0.2s ease, box-shadow 0.2s ease; }

/* Subtle hover hint (desktop only) */
@media (hover: hover) {
  img:not(.no-zoom):hover {
    transform: scale(1.02);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15); } }

img.no-zoom {
  cursor: default; }

/* Lightbox overlay */
.lightbox-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.9);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  cursor: zoom-out;
  padding: 20px;
  box-sizing: border-box; }

.lightbox-overlay.active {
  opacity: 1;
  visibility: visible; }

.lightbox-overlay img {
  max-width: 95vw;
  max-height: 95vh;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
  transform: scale(0.9);
  transition: transform 0.3s ease;
  cursor: default; }

.lightbox-overlay.active img {
  transform: scale(1); }

/* Close hint */
.lightbox-close {
  position: absolute;
  top: 20px;
  right: 24px;
  color: #fff;
  font-size: 32px;
  font-weight: 300;
  cursor: pointer;
  opacity: 0.7;
  transition: opacity 0.2s ease;
  line-height: 1; }

.lightbox-close:hover {
  opacity: 1; }

/* === Geek Cat Head (Back-to-top) === */
.geek-cat {
  --size: 44px;
  --cat-dark: #1a1a2e;
  --cat-accent: var(--link-color);
  --cat-glow: #00ff88;
  --cat-white: #f0f0f0;
  --progress-deg: 0deg;
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: var(--size);
  height: var(--size);
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.25s ease, transform 0.25s ease;
  z-index: 1000;
  pointer-events: none; }

.geek-cat.show {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto; }

/* Container */
.geek-cat .cat {
  position: relative;
  width: 100%;
  height: 100%;
  font-size: 1px; }

.geek-cat .cat * {
  position: absolute;
  box-sizing: border-box; }

/* Head - slightly angular geek style */
.geek-cat .head {
  width: 40em;
  height: 36em;
  background: var(--cat-dark);
  border-radius: 45% 45% 40% 40%;
  top: 4em;
  left: 50%;
  transform: translateX(-50%);
  box-shadow: 0 0 12px rgba(0, 255, 136, 0.2), inset 0 -2px 4px rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(0, 255, 136, 0.15); }

/* Ears - pointy geek style */
.geek-cat .ear {
  width: 10em;
  height: 14em;
  background: var(--cat-dark);
  clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
  top: -8em;
  border: 1px solid rgba(0, 255, 136, 0.1); }

.geek-cat .ear::after {
  content: '';
  position: absolute;
  width: 5em;
  height: 7em;
  background: linear-gradient(135deg, var(--cat-glow) 0%, transparent 60%);
  clip-path: polygon(50% 20%, 15% 100%, 85% 100%);
  top: 5em;
  left: 2.5em;
  opacity: 0.3; }

.geek-cat .ear-l {
  left: 4em;
  transform: rotate(-8deg); }

.geek-cat .ear-r {
  right: 4em;
  transform: rotate(8deg); }

/* Eyes - glowing terminal style */
.geek-cat .eye {
  width: 10em;
  height: 10em;
  background: #111;
  border-radius: 50%;
  top: 12em;
  border: 1px solid var(--cat-glow);
  box-shadow: 0 0 8px var(--cat-glow), inset 0 0 4px rgba(0, 255, 136, 0.3); }

.geek-cat .eye-l {
  left: 5em; }

.geek-cat .eye-r {
  right: 5em; }

/* Pupil - vertical slit */
.geek-cat .pupil {
  width: 3em;
  height: 7em;
  background: var(--cat-glow);
  border-radius: 40%;
  top: 1.5em;
  left: 3.5em;
  box-shadow: 0 0 6px var(--cat-glow);
  animation: pupilGlow 2s ease-in-out infinite; }

/* Glint */
.geek-cat .glint {
  width: 2em;
  height: 2em;
  background: var(--cat-white);
  border-radius: 50%;
  top: 2em;
  left: 2em;
  opacity: 0.8; }

/* Blink */
.geek-cat.blink .eye {
  height: 2em;
  top: 16em;
  border-radius: 50%; }

.geek-cat.blink .pupil,
.geek-cat.blink .glint {
  opacity: 0; }

/* Nose - small triangle */
.geek-cat .nose {
  width: 4em;
  height: 3em;
  background: #ff6b9d;
  clip-path: polygon(50% 100%, 0% 0%, 100% 0%);
  top: 24em;
  left: 50%;
  transform: translateX(-50%); }

/* Progress ring */
.geek-cat .progress-ring {
  width: calc(100% + 8em);
  height: calc(100% + 8em);
  top: -4em;
  left: -4em;
  border-radius: 50%;
  background: conic-gradient(var(--cat-glow) var(--progress-deg), transparent 0);
  opacity: 0.5;
  z-index: -1;
  mask: radial-gradient(circle, transparent 70%, black 71%);
  -webkit-mask: radial-gradient(circle, transparent 70%, black 71%); }

/* Jump animation */
.geek-cat.jump {
  animation: jump 0.25s ease-out; }

/* Hover glow */
.geek-cat:hover .head {
  box-shadow: 0 0 20px var(--cat-glow), inset 0 -2px 4px rgba(0, 0, 0, 0.3); }

.geek-cat:focus-visible {
  outline: 2px solid var(--cat-glow);
  outline-offset: 4px; }

/* Keyframes */
@keyframes pupilGlow {
  0%,
  100% {
    opacity: 1;
    box-shadow: 0 0 6px var(--cat-glow); }
  50% {
    opacity: 0.7;
    box-shadow: 0 0 12px var(--cat-glow); } }

@keyframes jump {
  0% {
    transform: translateY(0); }
  40% {
    transform: translateY(-10px); }
  100% {
    transform: translateY(0); } }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .kawaii-cat,
  .kawaii-cat .head,
  .kawaii-cat .tail,
  .kawaii-cat .sparkle {
    animation: none;
    transition: none; } }

/* Print hide */
@media print {
  .kawaii-cat {
    display: none !important; } }

.pagination {
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
  align-items: center; }

.pagination a {
  padding: .1rem .4rem;
  text-decoration: none;
  border-radius: .25rem; }

.pagination a.active {
  font-weight: 700;
  text-decoration: underline; }

.pagination .dots {
  opacity: .6; }

@media (max-width: 600px) {
  .pagination a {
    display: none; }
  .pagination a.active,
  .pagination .prev,
  .pagination .next {
    display: inline-block; } }

/* 让图片永不溢出容器 */
.post-content img,
article img {
  max-width: 100%;
  height: auto; }

/* 手机端：除了 Prev/Next/当前，还显示首末页锚点 */
@media (max-width: 600px) {
  .pagination a {
    display: none; }
  .pagination a.active,
  .pagination .prev,
  .pagination .next,
  .pagination a:first-of-type,
  .pagination a:last-of-type {
    /* 末页 */
    display: inline-block; } }

/* === Hide tags sitewide (post pages & lists) === */
.post-tags,
.tags,
.meta-tags,
.post .meta .tags,
.post-meta .tags,
ul.tags,
nav.tags,
.tag-list,
.taxonomies,
.taxonomy--tags,
article .post-meta a[href^="/tags/"] {
  display: none !important; }

/* 若主题有“Tags:”或“标签：”文字标签 */
.post-meta .label-tags,
.meta .label-tags {
  display: none !important; }

/* === Force-hide any tag links anywhere (catch-all) === */
/* Some pages render a bottom "tag cloud" without wrapper classes.
   The rules below nuke any anchor whose href starts with /tags/,
   plus common containers that might hold only tag links. */
a[href^="/tags/"],
a[href*="/tags/"] {
  display: none !important; }

/* If a paragraph/nav/div is composed of only tag links, hide the whole block (modern browsers) */
:where(p, nav, ul, div):has(> a[href^="/tags/"]) {
  display: none !important; }

/* Extra safety for themes using bespoke names */
.tag-cloud,
.tags-cloud,
.taglist,
.tagsline,
.footer-tags {
  display: none !important; }

/* Font is declared at top of file - removed duplicate declaration */
/* 为 TOC 中的嵌套列表（第二级及更深）添加左侧内边距（实现缩进） */
#TableOfContents ul ul {
  padding-left: 20px;
  /* 你可以调整这个值，比如 1.5em 或 25px */ }

/* 可选：为更深层级添加额外缩进 */
/*
  #TableOfContents ul ul ul {
    padding-left: 20px; /* 再增加 20px 缩进 */
/* } */
/* 可选：调整列表项之间的间距 */
#TableOfContents li {
  margin-bottom: 4px;
  /* 调整垂直间距 */ }
