@import url(font.css);
@import url(animation.css);

/* ==================== 
   全域變量定義
   ==================== */

:root {
  /* 色調 */
  --clr-sun-moon:#f4f4f4;
  --clr-main: #0a0c24; /* 主色調：深紫色 */
  --clr-auxiliary: #8881c7; /* 輔助色：淺紫色 */
  --clr-black: #333333;
  --clr-darkblack: #000000;
  --clr-white: #f4f4f4;
  --clr-brightwhite: #ffffff;
  --clr-grey: #a5a5a5;
  --clr-darkgrey: #747474;
  --clr-gold: #cfb53b;
  --clr-darkgold: #ad9f76;
  --clr-blue: #4682b4;
  --clr-lightblue: #4299e1;
  --clr-blackblue: #40676c;
  --clr-green: #00c725;
  --clr-darkgreen: #15932d;

  /* 鏈接 */
  --clr-a: #f9f9f9;
  --clr-a-hover: #0056b3;
  --clr-a-current: #007bff;
  --clr-a-actived: #007bff;
  --clr-a-disabled: #007bff;
  --clr-a-border: #ddd;

  /* 按鈕 */
  --clr-btn: #007bff;
  --clr-btn-hover: #0056b3;
  --clr-btn-border: #ddd;

  /* 邊框陰影 */
  --clr-borderline: #e2e8f0;
  --clr-inputbg: #f8fafc;
  --clr-white-shadow: rgba(0, 0, 0, 0.2); /* 白色陰影 */
  --clr-black-shadow: rgba(255, 255, 255, 0.5); /* 黑色陰影 */

  /* 水雲鄉 */
  --clr-shadow: #260234; /* 紫黑色 */
  --clr-Liuguang1: #f76f87; /* 流光配色 */
  --clr-Liuguang2: #6a94d4; /* 流光配色 */
  --clr-Liuguang3: #fff673; /* 流光配色 */
  --clr-seal: rgba(241, 27, 27, 0.84); /* 印章：紅色 */
  
  /* 特殊 */
  --clr-menu-background:rgba(255, 255, 255, 0.8);
  --clr-quote:rgba(0, 0, 0, 0.1);
  --clr-album-back-link: #f0f8ff;
  --bgimg-h1:url(/.common/images/svg/articles/symbols/circle.svg);  
  --bgimg-h2:url(/.common/images/svg/articles/symbols/arrow-circle.svg);
  --bgimg-h3:url(/.common/images/svg/articles/symbols/circle-line.svg);

  /* 字體大小 */
  --fs-Small: 12px;
  --fs-Normal: 16px;
  --fs-Big: 20px;
  --fs-Bigger: 30px;
  --fs-Large: 45px;
  --fs-Huge: 100px;
}

[data-theme="dark"] {	
  /* 色調 */
  --clr-sun-moon:#ad9f76;
  --clr-main: #0a0c24; /* 主色調：深紫色 */
  --clr-auxiliary: #8881c7; /* 輔助色：淺紫色 */
  --clr-black: #f4f4f4;
  --clr-darkblack: #ffffff;
  --clr-white: #333333;
  --clr-brightwhite: #616161;
  --clr-grey: #f0efef;
  --clr-darkgrey: #d7d7d7;
  --clr-gold: #cfb53b;
  --clr-darkgold: #ad9f76;
  --clr-blue: #4682b4;
  --clr-lightblue: #4299e1;
  --clr-blackblue: #8dd9e3;
  --clr-green: #00c725;
  --clr-darkgreen: #15932d;

  /* 鏈接 */
  --clr-a: #f9f9f9;
  --clr-a-hover: #0056b3;
  --clr-a-current: #007bff;
  --clr-a-actived: #007bff;
  --clr-a-disabled: #007bff;
  --clr-a-border: #ddd;

  /* 按鈕 */
  --clr-btn: #007bff;
  --clr-btn-hover: #0056b3;
  --clr-btn-border: #ddd;

  /* 邊框陰影 */
  --clr-borderline: #e2e8f0;
  --clr-inputbg: #f8fafc;
  --clr-white-shadow: rgba(0, 0, 0, 0.2); /* 白色陰影 */
  --clr-black-shadow: rgba(255, 255, 255, 0.5); /* 黑色陰影 */

  /* 水雲鄉 */
  --clr-shadow: #260234; /* 紫黑色 */
  --clr-Liuguang1: #f76f87; /* 流光配色 */
  --clr-Liuguang2: #6a94d4; /* 流光配色 */
  --clr-Liuguang3: #fff673; /* 流光配色 */
  --clr-seal: rgba(241, 27, 27, 0.84); /* 印章：紅色 */
  
  /* 特殊 */
  --clr-menu-background:rgba(0, 0, 0, 0.6);
  --clr-quote:rgba(255, 255, 255, 0.1);
  --clr-album-back-link: #424a50ba;
  --bgimg-h1:url(/.common/images/svg/articles/symbols/circle-for-black.svg);  
  --bgimg-h2:url(/.common/images/svg/articles/symbols/arrow-circle-for-black.svg);
  --bgimg-h3:url(/.common/images/svg/articles/symbols/circle-line-for-black.svg);
}

/* ==================== 
   基礎樣式
   ==================== */

*,
::after,
::before {
  box-sizing: border-box;
}
::-webkit-scrollbar {
  display: none;
}
html {
scroll-padding-top: 80px;
}
body {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
  background-color: var(--clr-white);
  font-family: Fuhao, sans-serif;
}
a {
  text-decoration: none;
}
h1 {
  margin: 10px 0;
  font-size: var(--fs-Big);
  font-weight: 800;
  font-family: Fuhao, Heiti, sans-serif;
  color:var(--clr-black);
}
p {
  -webkit-hyphens: auto;
  -moz-hyphens: auto;
  hyphens: auto;
  word-spacing: -0.05em;
  margin-top: 0;
  margin-bottom: 1rem;
}
.nocopy,
header {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}
.clearfix::after {
  content: "";
  display: table;
  clear: both;
}

/* FontAwesome圖標 */
i {
  margin-right: 5px;
}

/* ==================== 
   手機端菜單樣式
   ==================== */

.mobile-bar {
  position: fixed;
  left: 40px;
  top: 20px;
  z-index: 1002;
}
@media (min-width: 768px) {
  .mobile-bar {
    display: none;
  }
}

/* 菜單按鈕（放在語言切換條中） */
#menu-open {
  cursor: pointer;
}
@media (min-width: 768px) {
  #menu-open {
    display: none;
  }
}

/* 菜單容器 */
#menu {
  display: none;
  position: fixed;
  left: 0;
  top: 0;
  padding: 20px 0;
  width: 50%;
  min-width: 300px;
  height: 100%;
  font-size: var(--fs-Normal);
  transform: translateX(-100%);
  transition: transform 0.5s ease;
  background-color: var(--clr-menu-background);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 0 15px var(--clr-quote);
}
#menu.open {
  transform: translateX(0);
}
body.menu-open {
	overflow: hidden;
	width: 100%;
	height: 100%;
}

/* 菜單背景遮罩 */
		.menu-backdrop {
			position: fixed;
			top: 0;
			left: 0;
			width: 100%;
			height: 100%;
			background: rgba(0, 0, 0, 0.1);
			backdrop-filter: blur(5px);
			-webkit-backdrop-filter: blur(5px);
			z-index: 1001;
			display: none;
			opacity: 0;
			transition: opacity 0.3s ease;
		}
		
		.menu-backdrop.active {
			display: block;
			opacity: 1;
		}

/* 菜單選項 */
.menu-nav {
  display: flex;
  flex-direction: column;
  margin: 20px 0 0 0;
  justify-content: center;
}
.menu-nav-item {
  padding: 5px 30px;
  font-family: Daohang, serif;
  color: var(--clr-blue);
}
.menu-nav-item i {
  margin-right: 20px;
}
.menu-nav-item a {
  color: var(--clr-blue);
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
  position: relative;
  display: inline-block;
}
.menu-nav-item a:hover {
  color: var(--clr-lightblue);
  text-shadow: 2px 2px 6px rgba(0, 0, 0, 0.5);
  transform: translateY(-2px);
}
.menu-nav-item a::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--clr-lightblue);
  transition: width 0.3s ease;
}
.menu-nav-item a:hover::after {
  width: 100%;
}

/* 菜單選項右側 */
.menu-nav-item-end {
  float: right;
}
.menu-nav-item-end-img {
	position:absolute;
    bottom: 60px;
    right: 40px;
    width: 60px;
    height: 60px;
}

/* 菜單底部 */
.menu-bottom {
  position: absolute;
  bottom: 20px;
  right: 30px;
  padding-left: 10px;
  color: var(--clr-darkgrey);
  font-family: Shiju-Kai, serif;
  font-size: var(--fs-Normal);
  border-top: 0.75px solid var(--clr-darkgrey);
}
.menu-bottom img {
  position: relative;
  top: -2.5px;
  width: 16px;
  height: 16px;
  margin-left: 5px;
}

/* ==================== 
   微信模態框樣式
   ==================== */

.weixin-modal {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
}
.weixin-modal-content {
  background-color: #fff;
  margin: 15% auto;
  padding: 10px 20px 20px 20px;
  border-radius: 8px;
  width: 260px;
  text-align: center;
  position: relative;
}
.qr-image {
  width: 220px;
  height: 220px;
  display: block;
  margin: 0 auto 10px;
}
.qr-text {
  color: #666;
  font-size: 14px;
  margin: 0;
}
.close {
  color: #aaa;
  float: right;
  font-size: 30px;
  font-weight: bold;
  cursor: pointer;
}
.close:hover {
  color: #555;
}

/* ==================== 
   頭部樣式
   ==================== */

header {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 20px 0;
  width:100%;
  background: linear-gradient(135deg, var(--clr-main), #314152e0);
  border-bottom: 2px solid var(--clr-darkgold);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
@media (max-width: 768px) {
  header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: #0a0c24c4;
    z-index: 1000;
    transition: transform 0.3s ease-in-out;
    transform: translateY(0);
    will-change: transform;
  }
}

/* 頭部菜單、名稱、語言欄 */
.language-selector {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 25px;
}
.language-selector img {
  width: 24px;
  height: 24px;
}
.language-site-name {
  width: calc(100% - 134px);
  padding-left: 36px;
  text-align: center;
}
.language-site-name a{
  font-size: var(--fs-Big);
  font-family: Shiju-Zhuan, Shiju-Kai, Heiti, sans-serif;
  color: var(--clr-darkgold);
  font-weight: bolder;
}
@media (min-width: 768px) {
  .language-site-name {
    display: none;
  }
}

/* 語言選擇 */
.select-wrapper {
  display: flex;
  justify-content: center;
  align-items: center;
}
.selected-language,
.language-option {
  display: flex;
  align-items: center;
  justify-content: space-evenly;
  width: 60px;
  cursor: pointer;
}
.selected-language {
  padding: 5px 15px 5px 5px;
  border: 1px solid #7d7d7db0;
  border-radius: 5px;
  background-color: transparent;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}
.selected-language:hover {
  border-color: #8881c799;
}
.selected-language img,
.language-option img {
  width: 16px;
  height: 16px;
}
.selected-language span,
.language-option span {
  font-size: var(--fs-Small);
  color: white;
}
.selected-language::after {
  content: "";
  position: absolute;
  right: 31px;
  top: 34px;
  width: 0;
  height: 0;
  border-left: 3px solid transparent;
  border-right: 3px solid transparent;
  border-top: 3px solid #7f8c8d;
  transition: transform 0.3s ease;
}
.language-options {
  position: absolute;
  top: 51px;
  right: 25px;
  background-color: #2c3e5099;
  border-radius: 5px;
  box-shadow: 0 3px 7px rgba(0, 0, 0, 0.1);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 100;
}
.language-option {
  padding: 5px;
  transition: background 0.2s ease;
}
.language-option:hover {
  background-color: #8881c799;
}
.select-wrapper.active .language-options {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.select-wrapper.active .selected-language::after {
  transform: translateY(-50%) rotate(180deg);
}

/* 明暗切換按鈕 */
.theme-toggle {
    position: fixed;
    top: 25px;
    right: 125px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
	background-color: transparent;
    color: var(--clr-sun-moon);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    transition: all 0.3s ease;
    font-size: var(--fs-Small);
    cursor: pointer;
}

.theme-toggle:hover {
    transform: scale(1.1);
    background: #3c9aa9;
}

.theme-toggle i {
    font-size: 16px;
    margin: 0;
}
@media (max-width: 768px) {
  .theme-toggle {
    position: fixed;
    top: 23px;
    left: 60px;
  }
}

/* 繁簡切換按鈕 */
#t-s {
  position: absolute;
  right: 90px;
  top: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
}
#t-s button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background-color: transparent;
  font-size: var(--fs-Small);
  font-family: Fanjian;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}
#t-s button[data-mode="traditional"] {
  color: #f4f4f499;
  border: 1px solid #57897e99;
}
#t-s button[data-mode="simple"] {
  color: #cfb53be8;
  border: 1px solid #f11b1be8;
}

/* 網頁頭部內容 */
.container-nav {
  display: flex;
  padding: 20px 0;
  justify-content: space-between;
}
@media (max-width: 768px) {
  .container-nav {
    display: none;
  }
}

/* 水雲鄉-流光效果 */
.branding {
  margin: 0;
  padding: 0 60px;
  overflow: hidden;
}
.branding h1 {
  margin: 10px 0;
  height: 65px;
  color: white;
  font: Normal var(--fs-Large) Shuiyunxiang;
  text-shadow: 0 0 1px black, 1px 1px 3px var(--clr-shadow);
}
.branding span {
  position: relative;
  top: 8px;
  margin: 0 0 0 5px;
  padding: 0;
  color: var(--clr-seal);
}

/* 導航條 */
nav {
  display: flex;
  align-items: flex-end;
  margin: 0;
  padding: 0;
  font-family: Daohang, "Huiwen-mincho", serif;
  font-size: 16px;
}
nav ul {
  margin: 0 20px 0 0;
  padding: 0;
  list-style: none;
}
nav li {
  margin: 0 10px;
  padding: 0;
  display: inline;
}
nav a {
  color: white;
}
nav a:hover {
  color: var(--clr-auxiliary);
}
.current {
  color: var(--clr-auxiliary);
}

/* ==================== 
   主容器樣式
   ==================== */

.main-container {
  display: flex;
  flex: 1;
  width: 100%;
}
@media (max-width: 768px) {
  .main-container {
    flex-direction: column;
    margin-top: 72px;
    min-height: calc(100vh - 72px);
  }
}

/* ==================== 
   首頁樣式
   ==================== */

#index-container {
}

/* ==================== 
   首頁-側邊欄樣式
   ==================== */

.index-sidebar {
  width: 360px;
  flex-shrink: 0;
  padding: 20px;
  border-right: 1px solid #a5a5a554;
}
@media (max-width: 768px) {
  .index-sidebar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid #a5a5a554;
  }
}

/* 頭像 */
.avatar-container {
  text-align: center !important;
  margin-bottom: 1.5rem !important;
}
.avatar {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  border: 3px solid var(--clr-brightwhite);
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
}
@media (max-width: 768px) {
  .index-sidebar .avatar {
    display: none;
  }
}

/* 社交鏈接 */
.social-links {
  text-align: center !important;
  margin-bottom: 1.5rem !important;
}
.social-links a {
  position: relative;
  display: inline-block;
  margin: 0 5px;
  color: var(--clr-black);
  font-size: var(--fs-Big);
}
@media (max-width: 768px) {
  .index-sidebar .social-links {
    display: none;
  }
}
.social-tooltip {
  visibility: hidden;
  width: max-content;
  background-color: var(--clr-main);
  color: white;
  text-align: center;
  border-radius: 4px;
  padding: 6px 12px;
  position: absolute;
  z-index: 999;
  bottom: 110%;
  left: 50%;
  transform: translateX(-50%);
  opacity: 0;
  transition: opacity 0.3s;
  font: var(--fs-Small) Heiti;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  pointer-events: none;
}
.social-links a:hover .social-tooltip {
  visibility: visible;
  opacity: 0.75;
}
.social-tooltip::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 50%;
  margin-left: -5px;
  border-width: 5px;
  border-style: solid;
  border-color: var(--clr-main) transparent transparent transparent;
}

/* 雜言雜語 */
.mind {
  position: relative;
  width: 100%;
  margin: 0 0 20px 0;
  padding: 20px;
  border: 1px dotted var(--clr-grey);
  border-radius: 0.375rem;
  color:var(--clr-black);
  font-family: Fuhao, "LXGW Neo ZhiSong", Songti, serif;
}
.mind p {
	max-height: 75px;
	overflow-y: auto;
}
.mind_img{
	width:auto;
	height:18px;
}
@media (max-width: 768px) {
  .mind {
    width: calc(100% - 20px);
    margin: 0 10px 20px 10px;
  }
  .index-sidebar .mind {
    display: none;
  }
}
.mind::before {
  content: "\201C";
  font-size: 80px;
  color:var(--clr-quote);
  position: absolute;
  left: -20px;
  top: -23px;
  font-family: Fuhao, Songti, serif;
  line-height: 1;
  z-index: -2;
}
.mind-timestamp {
  position: absolute;
  bottom: 5px;
  right: 10px;
  color: var(--clr-grey);
  font-size: 0.9em;
}

/* 手機端網站標題 */
.site-name {
  display: none;
  margin: 0 0 40px 0;
  padding: 10px 0;
  text-align: center;
}
.site-name::before {
  content: "";
  position: absolute;
  top: 180px;
  left: calc(50% + 20px);
  transform: translateX(-50%);
  width: 20px;
  height: 20px;
  background-image: url(/.common/images/svg/index/title/seal.svg);
  background-size: 100% 100%;
  background-repeat: no-repeat;
}
.site-name::after {
  z-index: -1;
  content: "";
  position: absolute;
  top: 100px;
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 40px);
  height: 120px;
  border-radius: 0.375rem;
  background-image: url(/.common/images/svg/index/title/sun.svg),
    url(/.common/images/svg/index/title/snow-1.svg),
    url(/.common/images/svg/index/title/snow-1.svg),
    url(/.common/images/svg/index/title/snow-2.svg),
    url(/.common/images/svg/index/title/snow-2.svg),
    url(/.common/images/svg/index/title/mountain.svg),
    linear-gradient(135deg, transparent, #4c8276);
  background-size: 80px 80px, 20px 20px, 15px 15px, 5px 5px, 7px 7px, 100px auto,
    auto 200px;
  background-position: -35px -35px, calc(50% + 110px) 34px,
    calc(50% + 65px) 55px, calc(50% + 90px) 25px, calc(50% + 102px) 58px,
    calc(50% + 100px) 64px, 0 0;
  background-repeat: no-repeat, no-repeat, no-repeat, no-repeat, no-repeat,
    no-repeat;
}
.site-name h1 {
  margin: 0;
  transform: translateX(-50px);
  font-family: Shuiyunxiang, serif;
  font-size: var(--fs-Large);
  font-weight: Normal;
  line-height: inherit;
}
@media (max-width: 768px) {
  .site-name {
    display: block;
  }
}
.gradient {
  background: linear-gradient(
    135deg,
    #db8c9a,
    #db8c9a,
    #4c8276,
    #4c8276,
    #f4f3ec,
    #4c8276,
    #4c8276,
    #db8c9a,
    #db8c9a
  );
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  text-fill-color: transparent;
  animation: rainbow 8s linear infinite;
}
@keyframes rainbow {
  0% {
    background-position: 0% center;
  }
  100% {
    background-position: 200% center;
  }
}

/* 文章列表 */
.index-sidebar h1 {
  text-align: center;
}
.index-sidebar .list-group {
  font-size: var(--fs-Normal);
  border:none;
  box-shadow: 0 10px 30px var(--clr-quote);
}
.list-group-item {
  font-family: Fuhao, "LXGW Neo ZhiSong", Songti, serif;
  background-color:var(--clr-white);
  color:var(--clr-black);  
  border:none;
  border-bottom: 1px dotted #a5a5a540;
}
.list-group-item:hover{
	background-color: var(--clr-brightwhite);
}
.list-group-item i {
  margin: 0 10px 0 0;
}
.index_to_articles {
  background-color: var(--clr-darkgrey);
  display: flex;
  justify-content: flex-end;
  align-items: center;
  font-size: var(--fs-Normal);
}
.index_to_articles:hover {
  background-color: var(--clr-darkgrey);
}
.index_to_articles a {
  color: var(--clr-white);
  cursor: pointer;
}
.index_to_articles a:hover {
  color: var(--clr-gold);
}
.index_to_articles i {
  color: var(--clr-white);
  margin: 0 10px;
}

/* 熱搜列表 */
.selector {
  position: relative;
  display: flex;
  justify-content: space-between;
  width: 50%;
  margin: 10px auto;
  padding: 4px;
  border: 1px solid var(--clr-grey);
  border-radius: 8px;
}
.selector-btn {
  width: 50%;
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
  z-index: 1;
  border: none;
  background: transparent;
  color: var(--clr-black);
}
.selector-btn.active {
  color: var(--clr-white);
}
.slider {
  position: absolute;
  height: calc(100% - 8px);
  width: calc(50% - 4px);
  background: var(--clr-lightblue);
  border-radius: 6px;
  transition: all 0.3s ease;
}
.slider.weibo {
  transform: translateX(0);
}
.slider.baidu {
  transform: translateX(100%);
}
.platform-content {
  display: none;
  animation: fadeIn 0.3s ease;
}
.platform-content.active {
  display: block;
}
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* ==================== 
   首頁-主內容區樣式
   ==================== */

.index-main-content {
  flex: 1;
  padding: 20px;
  min-width: 0;
  background: var(--clr-brightwhite);
}

.index-main-content section {
  margin: 0 0 30px 0;
}

@media (max-width: 768px) {
  .index-main-content {
    width: 100%;
  }
}

/* 相冊樣式 */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 25px;
  padding: 20px;
}
.gallery-item {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
  transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
  aspect-ratio: 1;
}
.gallery-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}
.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.gallery-item:hover img {
  transform: scale(1.05);
}
.gallery-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 15px;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
  color: white;
  transform: translateY(100%);
  transition: transform 0.3s ease;
  font-family: Fuhao, "LXGW Neo ZhiSong", Songti, serif;
  font-size: var(--fs-Small);
}
.gallery-item:hover .gallery-caption {
  transform: translateY(0);
  color: white;
}
@media (max-width: 768px) {
  .gallery {
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 15px;
    padding: 15px;
  }
  .gallery-caption-photo-date {
    display: none;
  }
}
@media (max-width: 480px) {
  .gallery {
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 12px;
    padding: 10px;
  }
}
.stack-container {
  position: relative;
  display: block;
  cursor: pointer;
  transition: transform 0.3s ease;
  width: 100%;
  height: 100%;
  margin: 0 auto;
  aspect-ratio: 3/2;
}
.stack-container:hover {
  transform: scale(1.05);
  z-index: 2;
}
.stack-container img {
  position: absolute;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: 3px solid white;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
  transform: rotate(var(--rotate));
  transition: all 0.3s ease;
}
.stack-container img:nth-child(1) {
  position: relative;
  z-index: 1;
}
.stack-container img:nth-child(2) {
  top: 5%;
  left: 5%;
  z-index: 0;
}
.stack-container img:nth-child(3) {
  top: 10%;
  left: -5%;
  z-index: -1;
}
.counter {
  position: absolute;
  bottom: 15px;
  right: 15px;
  background: rgba(255, 255, 255, 0.9);
  padding: 8px 12px;
  border-radius: 20px;
  font-weight: bold;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  z-index: 2;
  font-family: Fuhao, sans-serif;
  font-size: var(--fs-Small);
}

/* Fancybox 自定義標題樣式 */
.fancybox-caption {
  padding: 20px;
  background: rgba(0, 0, 0, 0.7);
  color: #fff;
  line-height: 1.5;
}
.fancybox-caption__title {
  font-size: 16px;
  margin-bottom: 8px;
  text-align: center;
  font-family: Fuhao, Heiti, sans-serif;
}
.fancybox-caption__location,
.fancybox-caption__date {
  font-size: 14px;
  opacity: 0.9;
  margin-top: 5px;
  text-align: center;
  font-family: Fuhao, "LXGW Neo ZhiSong", Songti, serif;
}
.fancybox-caption__location i,
.fancybox-caption__date i {
  margin-right: 5px;
  width: 15px;
  text-align: center;
}
@media (max-width: 480px) {
  .fancybox-caption__title {
    text-align: left;
  }
  .fancybox-caption__location,
  .fancybox-caption__date {
    text-align: left;
  }
}

/* ==================== 
   留言表單样式
   ==================== */

/* 留言板 */
.form-container {
  width: 100%;
}
.form-group {
  text-align: center;
  margin-bottom: 25px;
  font-size: var(--fs-Normal);
}
.form-control {
  padding: 12px;
  border: 1px solid var(--clr-borderline);
  border-radius: 8px;
  font-size: var(--fs-Small);
  transition: all 0.3s ease;
  background: var(--clr-white);
  color:var(--clr-black);
}
.form-control::placeholder {
	color:var(--clr-grey);
}
.form-control:focus {
  outline: none;
  border-color: var(--clr-lightblue);
  box-shadow: 0 0 0 2px rgba(66, 153, 225, 0.2);
  background: var(--clr-brightwhite);
}

/* 表情 */
.emoji-toggle-container {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 10;
}
.toggle-emoji-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, #b38fd9 0%, #2575fc 100%);
  color: white;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease;
}
.toggle-emoji-btn:hover {
  transform: scale(1.1) rotate(10deg);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  background: linear-gradient(135deg, #2575fc 0%, #b38fd9 100%);
}
.toggle-emoji-btn i {
  margin: 0;
  padding: 0;
  font-size: 18px;
  transition: transform 0.3s ease;
}
.toggle-emoji-btn:hover i {
  transform: scale(1.2);
}
#message {
  padding-right: 50px !important;
}
.emoji-set-switcher {
  display: flex;
  margin-bottom: 10px;
  border-bottom: 1px solid #eee;
  padding-bottom: 8px;
}
.emoji-set-btn {
  background: #f5f5f5;
  border: 1px solid #ddd;
  border-radius: 4px;
  padding: 4px 8px;
  margin-right: 5px;
  cursor: pointer;
  font-size: 12px;
}
.emoji-set-btn img {
  width: 24px;
  height: 24px;
}
.emoji-set-btn.active {
  background: #4caf50;
  color: white;
  border-color: #388e3c;
}
.emoji-selector {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(40px, 1fr));
  justify-content: center;
  justify-items: center;
  gap: 5px;
  max-height: 170px;
  overflow-y: auto;
  border: 1px solid #eee;
  border-radius: 8px;
  padding: 5px;
  margin-bottom: 10px;
}
.emoji-thumb {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 40px;
  height: 40px;
  padding: 2px;
  cursor: pointer;
  border: 1px solid rgba(51, 48, 0, 0.2);
  border-radius: 4px;
  transition: all 0.2s ease;
}
.emoji-thumb img {
  max-width: 100%;
  max-height: 100%;
  cursor: pointer;
  transition: transform 0.2s;
}
.emoji-thumb img:hover {
  transform: scale(1.2);
}

/* 驗證碼 */
.captcha-group {
  display: flex;
  gap: 0.6rem;
  align-items: center;
}
.captcha-img {
  vertical-align: middle;
  height: 40px;
  border: 1px solid var(--clr-borderline);
  border-radius: 5px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s;
  cursor: pointer;
}
.captcha-img:hover {
  transform: translateY(-1px);
}

/* 發送按鈕 */
.submit-btn {
  position: relative;
  left: calc(100% - 100px);
  width: 80px;
  margin: 0 0 12px 0;
  padding: 8px;
  background: var(--clr-lightblue);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: var(--fs-Normal);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.submit-btn:hover {
  background: var(--clr-blackblue);
  transform: translateY(-1px);
  box-shadow: 0 2px 3px rgba(0, 0, 0, 0.1);
}

/* 最新留言 */
.message {
  position: relative;
  border: 1px solid #ddd;
  padding: 15px 10px;
  margin: 15px 0 0 0;
  border-radius: 5px;
  transition: margin-left 0.3s ease;
  border-left: 2px solid #eee;
}
.message-header {
    position: relative;
    display: flex;
    align-items: center;
    margin: 0 10px 10px 10px;
    justify-content: space-between;
}
.message-avatar {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  object-fit: cover;
  margin-right:10px;
  background:white;
}
.message-info {
  flex: 1;
  padding-bottom: 5px;
  border-bottom: 1px dotted #ddd;
}
.message-belong-to{
	display:flex;
	justify-content: flex-start;
	flex-wrap: wrap;
	align-items: center;
	margin-right:58px;
	gap:5px;
	line-height:1em;
}
.message-flag {
  width: 1.33rem;
  height: 1rem;
  border: 1px solid #eee;
  object-fit: cover;
}
.message-location {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 3px;
  font-size: 0.85rem;
  font-family: Fuhao, "LXGW Neo ZhiSong", Songti, serif;
  color: var(--clr-darkgrey);
}
.message-content {
  margin: 0 10px;
  font-family: "LXGW Neo ZhiSong", Songti, serif;
  vertical-align: middle;
  overflow: hidden;
  color:var(--clr-black);
}
.message-content .emoji {
  width: auto;
  height: 1.6em;
  vertical-align: middle;
  margin: 0 2px;
}
.message-footer {
  display: flex;
  justify-content: flex-end;
  padding: 15px 10px 10px 10px;
}
.message-date {
  font-size: 0.85rem;
  font-family: Fuhao, "LXGW Neo ZhiSong", Songti, serif;
  color: var(--clr-darkgrey);
  text-align: right;
  width: 100%;
}
.reply-btn-container-header {
	position:absolute;
	top:11px;
	right:11px;
}
.reply-btn {
  background: #f0f0f0;
  border: 1px solid #ddd;
  border-radius: 3px;
  padding: 3px 6px;
  font-size: 12px;
  cursor: pointer;
  color: #666;
  min-width:24px;
}
.reply-btn:hover {
  background: #e0e0e0;
}
.reply-notice {
  background: #f9f9f9;
  border-left: 3px solid #4caf50;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px;
  margin: 15px 0;
  font-size: 0.9em;
}
.reply-notice p {
  margin: 0;
  padding: 0;
}

/* 取消回覆按钮样式 */
.cancel-reply-btn {
  background: none;
  border: none;
  color: #f44336;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  transition: background-color 0.3s;
}
.cancel-reply-btn:hover {
  background-color: rgba(244, 67, 54, 0.1);
}
.cancel-reply-btn i {
  margin: 0;
  padding: 0;
}

/* 留言狀態提醒 */
.custom-alert {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 9999;
  background: white;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  padding: 15px 20px;
  transform: translateX(100%);
  transition: transform 0.3s ease;
  max-width: 400px;
}
.custom-alert.show {
  transform: translateX(0);
}
.custom-alert-success {
  border-left: 4px solid #4caf50;
}
.custom-alert-error {
  border-left: 4px solid #f44336;
}
.alert-content {
  display: flex;
  align-items: center;
  gap: 10px;
}
.alert-content i {
  font-size: 20px;
}
.custom-alert-success .alert-content i {
  color: #4caf50;
}
.custom-alert-error .alert-content i {
  color: #f44336;
}
.alert-content span {
  flex: 1;
  color: #333;
}
.alert-close {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  width: 20px;
  height: 20px;
}
.custom-alert-success .alert-close i,
.custom-alert-error .alert-close i {
  color: #999;
}
.alert-close i:hover {
  color: #666;
}

/* 分頁導航 */
.pagination-container {
  display: flex;
  align-content: center;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 20px 0;
  font-size: var(--fs-Small);
}
.pagination-item {
  display: flex;
  align-content: center;
  align-items: center;
  justify-content: center;
  padding: 4px 6px;
  height: 28px;
  border: 1px solid #ddd;
  border-radius: 3px;
  text-decoration: none;
  color: var(--clr-black);
  transition: all 0.2s;
}
.pagination-item i {
  margin: 0 auto;
  padding: 0 5px;
}
.pagination-item:hover {
  background: var(--clr-a-hover);
  color: var(--clr-white);
}
.pagination-item.current {
  background: var(--clr-a-current);
  color: var(--clr-white);
  border-color: var(--clr-a-current);
}
/* 省略號點 */
.pagination-ellipsis {
  padding: 0 4px;
  color: var(--clr-black);
}
/* 跳轉按鈕 */
.pagination-jump {
  margin-left: 8px;
  display: flex;
  align-content: center;
  align-items: center;
  justify-content: center;
  gap: 2px;
  font-size: var(--fs-Small);
  color: var(--clr-black);
}
.pagination-jump input {
  text-align: center;
  width: 48px;
  height: 28px;
  padding: 2px 4px;
  border: 1px solid #ddd;
  border-radius: 3px;
  color: var(--clr-black);
  background-color:var(--clr-white);
}
.pagination-jump button {
  width: 50px;
  height: 28px;
  margin: 0 0 0 0.25em;
  padding: 2px 4px;
  background: var(--clr-a-current);
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}
.pagination-jump button:hover {
  background: var(--clr-a-hover);
}

/* 加載錯誤消息 */
.error-msg {
  color: #dc3545;
  text-align: center;
  padding: 15px;
}

/* ==================== 
   底部樣式
   ==================== */

footer {
  position: relative;
  bottom: 0;
  padding: 10px;
  width:100%;
  text-align: center;
  background: var(--clr-main);
  color: var(--clr-white);
}
footer div {
  font-family: Fuhao, Georgia, "Huiwen-mincho", serif;
  font-size: var(--fs-Small);
  color: var(--clr-darkgrey);
}
footer a {
  text-decoration: none;
  color: var(--clr-darkgrey);
}
footer a:hover {
  color: var(--clr-a-hover);
}

/* 底部詩句 */
.poem {
  margin: 0 0 10px 0;
  text-align: center;
  font-size: var(--fs-Big);
  font-family: Shiju-Bo, Shiju-Kai, "Huiwen-mincho", serif;
  color: var(--clr-darkgold);
  text-shadow: 0 0 1px black, 1px 1px 3px var(--clr-shadow);
}
@media (max-width: 768px) {
  .poem {
    font-size: var(--fs-Normal);
  }
}

/* 底部網站信息 */
.site-info,
.site-info a {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px;
  font-family: Fuhao, Georgia, "Huiwen-mincho", serif;
  font-weight: Normal;
}
.site-info i {
  margin: 0;
}

/* 蟲洞 */
.wormhole {
  margin-left: 5px;
  display: flex;
  justify-content: center;
  align-items: center;
}
.container-wormhole {
  font-size: var(--fs-Small);
  color: lime;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: change-color 5s linear infinite;
  transform: scale(0.03);
  transform-origin: center;
  white-space: nowrap;
}
@keyframes change-color {
  to {
    filter: hue-rotate(1turn);
  }
}
.container-wormhole span {
  position: absolute;
  --diameter: calc(5em + (var(--n) - 1) * 3em);
  width: var(--diameter);
  height: var(--diameter);
  border-style: solid;
  border-width: 1em 1em 0 0;
  border-color: currentColor transparent;
  border-radius: 50%;
  animation: rotating linear infinite;
  animation-duration: calc(5s / (9 - var(--n) + 1));
}
@keyframes rotating {
  to {
    transform: rotate(1turn);
  }
}
.container-wormhole span:nth-child(1) {
  --n: 1;
}
.container-wormhole span:nth-child(2) {
  --n: 2;
}
.container-wormhole span:nth-child(3) {
  --n: 3;
}
.container-wormhole span:nth-child(4) {
  --n: 4;
}
.container-wormhole span:nth-child(5) {
  --n: 5;
}
.container-wormhole span:nth-child(6) {
  --n: 6;
}
.container-wormhole span:nth-child(7) {
  --n: 7;
}
.container-wormhole span:nth-child(8) {
  --n: 8;
}
.container-wormhole span:nth-child(9) {
  --n: 9;
}

/* ==================== 
   音樂頁面样式
   ==================== */

#music-container {
  margin: 50px auto;
  width: 80%;
  max-width: 400px;
  min-height: calc(100vh - 393px);
}
@media (max-width: 768px) {
  #music-container {
    margin: calc((100vh - 440px) / 2) auto;
    min-height: 350px;
  }
}

/* ==================== 
   鄉人頁面樣式
   ==================== */

#about-container {
  display: flex;
  flex-direction: column;
  margin: 0 auto;
  width: 80%;
  max-width: 1000px;
  line-height: 1.8;
}
@media (max-width: 768px) {
  #about-container {
    margin-top: 72px;
    width: 95%;
  }
}

/* 簡歷下載 */
.resume {
  display: flex;
  justify-content: flex-end;
  margin: 20px 0 0 0;
}
.resume-container {
  padding: 3px 8px;
  border: 1px solid var(--clr-darkgold);
  border-radius: 5px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}
.resume-container:hover {
  border-color: var(--clr-btn-hover);
}
.resume-container a {
  color: var(--clr-darkgrey);
  font-size: var(--fs-Small);
}

/* 文章標題 */
.article-title {
  position: relative;
  margin: 20px 0;
  padding: 10px 25px;
  color: white;
  font: bold var(--fs-Big) Heiti;
  text-shadow: 1px 1px 2px var(--clr-white-shadow);
  background-clip: padding-box;
}
.article-title::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-top-left-radius: 25px;
  border-bottom-left-radius: 25px;
  /* 調整背景順序，先 SVG 後漸變 */
  background-image: linear-gradient(to right, var(--clr-main), transparent),
    url(../images/svg/articles/plants/bamboo.svg);
  /* 設置 SVG 的寬度自動並居左，漸變覆蓋剩餘部分 */
  background-size: 100% 100%, auto 100%;
  background-position: left, right;
  background-repeat: no-repeat;
}
.article-title a {
  text-decoration: none;
  color: white;
}

/* 文章內容 */
.article-content {
  position: relative;
  overflow: hidden;
  width: 100%;
  padding: 0 32px;
  color: var(--clr-black);
  font-family: Fuhao, "LXGW Neo ZhiSong", Songti, serif;
  font-size: var(--fs-Normal);
}

/* 文章圖片 */
.article-image {
  float: right;
  display: flex;
  flex-direction: column;
  margin: 0 0 16px 30px;
  width: 50%;
  max-width: 450px;
}
@media (max-width: 768px) {
  .article-image {
    float: none;
    width: 100%;
	max-width: 300px;
    margin: 20px auto;
  }
}
.article-image-container {
  width: 100%;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: all 0.4s ease;
  transform: perspective(1000px) rotateX(0) rotateY(0);
}
.article-image-container:hover {
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
  transform: perspective(1000px) rotateX(1deg) rotateY(1deg);
}
.article-image-container:hover img {
  transform: scale(1.2);
}
.article-image-container img {
  width: 100%;
  height: auto;
  transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  border: 1px solid rgba(0, 0, 0, 0.05);
}

/* 圖片標籤 */
.article-image-caption {
  position: relative;
  margin: 16px 0 0 0;
  padding: 0 10px;
  text-align: center;
  font-family: Fuhao, Heiti, sans-serif;
  font-size: var(--fs-Small);
  color: var(--clr-darkgreen);
}
.article-image-caption a {
  margin: 0;
  padding: 0;
  position: relative;
  display: inline-block;
}
.article-image-caption a .article-image-caption-icon {
  margin: 0 0 0 5px;
  color: var(--clr-seal);
}
.article-image-caption a .article-image-caption-tip {
  visibility: hidden;
  width: max-content;
  max-width: 200px;
  background-color: var(--clr-main);
  color: white;
  text-align: center;
  border-radius: 4px;
  padding: 6px 8px;
  position: absolute;
  z-index: 999;
  bottom: 100%;
  left: 50%;
  transform: translateX(calc(-75% + 2.5px));
  opacity: 0;
  transition: opacity 0.3s;
  font-size: var(--fs-Small);
  font-family: Fuhao, "LXGW Neo ZhiSong", Songti, serif;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  line-height:1.2em;
  pointer-events: none;
  margin-bottom: 8px;
}
.article-image-caption a:hover .article-image-caption-tip {
  visibility: visible;
  opacity: 0.75;
}
.article-image-caption a .article-image-caption-tip::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 75%;
  margin-left: -5px;
  border-width: 5px;
  border-style: solid;
  border-color: var(--clr-main) transparent transparent transparent;
}

/* 圖片特效 */
.grayPic {
  filter: grayscale(50%);
}
.img-flip-horizontal {
  transform: scaleX(-1);
}
.img-flip-vertical {
  transform: scaleY(-1);
}
.img-flip-both {
  transform: scaleX(-1) scaleY(-1);
}

/* 教育背景&工作經歷&聯絡方式 */
.education-item,
.work-item,
.contact-item {
  display: flex;
  align-items: center;
  flex-direction: row-reverse;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 32px;
  overflow: hidden;
  font-family: Fuhao, "LXGW Neo ZhiSong", Songti, serif;
}
.contact-item {
  margin-bottom: 60px;
}
.education-item div,
.work-item div,
.contact-item div {
  width: 100%;
}
.education-item h1,
.work-item h1 {
  margin: 10px 0;
  color: var(--clr-blue);
  font-family: Fuhao, Heiti, sans-serif;
  font-size: var(--fs-Big);
}
.education-item p,
.work-item p,
.contact-item p {
  margin: 10px 0;
}

/* 校徽佈局 */
.education-item-logo {
  width: 120px;
  height: 120px;
  margin: 16px 0 0 0;
  background-color:#f4f4f4;
  border-radius:50%;
}
@media (max-width: 768px) {
  .education-item,
  .work-item,
  .contact-item {
    display: flex;
    flex-direction: row-reverse;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
  }
  .contact-item {
    margin-bottom: 60px;
  }
  .education-item-logo {
    width: 25%;
    height: 25%;
    max-width: 200px;
    min-width: 80px;
  }
}
@media (max-width: 480px) {
  .education-item,
  .work-item,
  .contact-item {
    display: flex;
    flex-direction: column;
    gap: 0;
    align-items: flex-start;
  }
}

/* ==================== 
   項目頁面樣式
   ==================== */

#projects-container {
  display: flex;
  flex-direction: column;
  margin: 50px auto;
  width: calc(100% - 64px);
  max-width: 800px;
}
@media (max-width: 768px) {
  #projects-container {
    margin-top: 120px;
  }
}
.projects {
  margin-bottom: 50px;
}
.project-title {
  text-align: left;
  margin: 0 0 30px 0;
  padding: 5px 0 5px 10px;
  border-left: 4px solid #2196f3;
  font-size: var(--fs-Big);
}
.app-grid {
  display: grid;
  grid-template-columns: repeat(6, 80px);
  gap: 30px;
  padding: 0 20px;
  justify-content: space-around;
  transition: all 0.3s ease;
}
.app-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  text-align: center;
}
.app-caption {
  font-size: 12px;
  color: #666;
  width: 100px;
  line-height: 1.4;
  transition: color 0.3s ease;
}
.app-item:hover .app-caption {
  color: #2196f3;
}
@media (max-width: 768px) {
  .app-grid {
    grid-template-columns: repeat(4, 80px);
  }
}
@media (max-width: 480px) {
  .app-grid {
    grid-template-columns: repeat(3, 80px);
  }
}
.app-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  overflow: hidden;
  text-decoration: none;
  transition: transform 0.3s ease;
  background-color: var(--clr-brightwhite);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}
.app-icon:hover {
  transform: scale(1.1);
}
.app-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
i.universal-access {
  color: var(--clr-darkgreen);
  margin: 0 5px;
}
i.universal-access:hover {
  color: var(--clr-green);
}
i.lock-open {
  color: var(--clr-darkgrey);
  margin: 0 5px;
}
i.lock-open:hover {
  color: var(--clr-grey);
}
i.locked {
  color: var(--clr-darkgold);
  margin: 0 5px;
}
i.locked:hover {
  color: var(--clr-gold);
}
.under-construction {
	position: absolute;
    transform: translate(-70px, 6px);
    width: 60px;
	height: 60px;
}

/* ==================== 
   相冊頁面樣式
   ==================== */

#gallery-container {
  display: block;
  margin: 50px auto;
  width: 100%;
  max-width: 1200px;
}
@media (max-width: 768px) {
  #gallery-container {
    margin-top: 120px;
  }
}

/* 相冊列表 */
.gallery-title {
  text-align: center;
  margin: 20px 0;
  font-size: var(--fs-Bigger);
}
.album-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 4fr));
  gap: 24px;
  padding: 20px;
  max-width: 1400px;
  margin: 0 auto;
}
.album-item {
  display: block;
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  background: #fff;
  color: var(--clr-lightblue);
  text-decoration: none;
}
.album-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 20px rgba(0, 0, 0, 0.15);
  color: #ef3a3a;
}
.album-item::after {
  content: "";
  position: absolute;
  top: 10px;
  right: 10px;
  width: 20px;
  height: 20px;
  background-image: url(/.common/images/svg/index/title/seal.svg);
  background-size: 20px 20px;
  background-repeat: no-repeat;
}
.album-cover {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}
.album-item:hover .album-cover {
  transform: scale(1.07);
}
.album-info {
  padding: 10px;
  background: var(--clr-brightwhite);
  text-align: center;
  border-top: 5px solid #2fa544;
}
.album-info h3 {
  margin: 5px 0 15px 0;
  font-size: 18px;
  font-weight: 600;
  font-family: Heiti, sans-serif;
}
.album-info p {
  margin: 0;
  padding-top: 5px;
  font-size: 14px;
  color: var(--clr-darkgrey);
  font-family: Fuhao, "LXGW Neo ZhiSong", Songti, serif;
}
.album-info p::before {
  content: "";
  position: absolute;
  bottom: 32.5px;
  left: 0;
  width: 100%;
  height: 5px;
  background-image: radial-gradient(circle, #0a0c24 0.5px, transparent 0.5px);
  background-size: 2px 100%;
  background-repeat: round;
  background-position: left center;
}
.album-info p::after {
  content: "";
  position: absolute;
  bottom: 25px;
  left: 10%;
  width: 20px;
  height: 20px;
  background-image: url(/.common/images/svg/index/title/bow-1.svg);
  background-size: 20px 20px;
  background-repeat: no-repeat;
}
.album-info i {
  margin: 0 0 0 5px;
}
@media (max-width: 768px) {
  .album-grid {
    grid-template-columns: repeat(auto-fill, minmax(200px, 3fr));
    gap: 16px;
    padding: 16px;
  }
  .album-cover {
    height: 150px;
  }
}
@media (max-width: 480px) {
  .album-grid {
    grid-template-columns: repeat(auto-fill, minmax(150px, 2fr));
    gap: 12px;
  }
  .album-info h3 {
    font-size: var(--fs-Normal);
  }
  .album-info p {
    font-size: var(--fs-Small);
  }
}

/* 返回按鈕 */
.back-link {
  display: inline-block;
  padding: 10px 20px;
  margin: 0 0 10px 20px;
  background: var(--clr-album-back-link);
  color: var(--clr-blackblue);
  border: 1px solid var(--clr-blackblue);
  border-radius: 20px;
  transition: all 0.3s ease;
  font-size: var(--fs-Small);
  font-family: Fuhao, Heiti, sans-serif;
}
.back-link:hover {
  background: var(--clr-blackblue);
  color: var(--clr-white);
  border-color: transparent;
}

/* 照片卡片 */
.photo-card {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  background: var(--clr-brightwhite);
}
.photo-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 20px rgba(0, 0, 0, 0.15);
}
.photo-card::after {
  content: "";
  position: absolute;
  top: 10px;
  right: 10px;
  width: 20px;
  height: 20px;
  background-image: url(/.common/images/svg/index/title/seal.svg);
  background-size: 20px 20px;
  background-repeat: no-repeat;
}
.gallery-photo {
  display: block;
  text-decoration: none;
  color: inherit;
}
.photo-content {
  position: relative;
  overflow: hidden;
}
.photo-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}
.photo-card:hover .photo-image {
  transform: scale(1.07);
}
.photo-meta {
  padding: 16px;
  background: var(--clr-brightwhite);
}
.photo-location,
.photo-date,
.photo-title {
  display: flex;
  align-items: center;
  margin: 3px 0;
  font-size: var(--fs-Small);
  color: var(--clr-black);
}
.photo-location {
  font-weight: bold;
  font-family: Fuhao, Heiti, sans-serif;
}
.photo-date,
.photo-title {
  font-family: Fuhao, "LXGW Neo ZhiSong", Songti, serif;
}
.photo-location i,
.photo-date i,
.photo-title i {
  margin-right: 5px;
  width: 16px;
  text-align: center;
  font-size: var(--fs-Small);
  color: var(--clr-black);
}
@media (max-width: 768px) {
  .photo-image {
    height: 150px;
  }
  .photo-meta {
    padding: 10px;
  }
}
@media (max-width: 480px) {
  .photo-location,
  .photo-date,
  .photo-title {
    font-size: var(--fs-Small);
  }
}

/* ==================== 
   文章頁面樣式
   ==================== */

#articles-container {
  display: flex;
  flex-direction: column;
  margin: 0 auto;
  line-height: 1.8;
}
#article{
	width:80%;
	max-width:1000px;
  margin: 0 auto;
}
@media (max-width: 768px) {
  #articles-container {
    margin-top: 72px;
    width: 100%;
  }
  #article{
	width:95%;
}
}

/* 搜索條 */
#search {
  margin: 0 auto;
  margin-top: 2em;
  text-align: right;
  width: 80%;
  max-width: 1000px;
}
@media (max-width: 768px) {
  #search{
	width:95%;
  }
}
#search select[name="type"] {
  height: 30px;
  padding: 0 5px;
  border: 1px solid var(--clr-darkgrey);
  border-radius: 2px;
  font: var(--fs-Small) Heiti;
  background:var(--clr-white);
  color:var(--clr-black);
}
#search input[type="text"] {
  height: 30px;
  padding: 0 10px;
  border: 1px solid var(--clr-darkgrey);
  border-radius: 2px;
  font: var(--fs-Small) Heiti;
  background:var(--clr-white);
  color:var(--clr-black);
}
#search input::placeholder{
	color:var(--clr-grey);
}
@media (max-width: 768px) {
  #search select[name="type"] {
    max-width: 100px;
	overflow:hidden;
  }
  #search input[type="text"] {
	max-width:120px;
	overflow:hidden;
}
}
#search button {
  height: 30px;
  padding: 0 10px;
  background: var(--clr-darkgrey);
  border: 1px solid var(--clr-darkgrey);
  border-radius: 2px;
  color: var(--clr-white);
  font: var(--fs-Small) Heiti;
  background-image: linear-gradient(
    to right,
    rgba(255, 255, 255, 0.2) 0%,
    rgba(255, 255, 255, 0.1) 20%,
    rgba(255, 255, 255, 0.3) 40%,
    rgba(255, 255, 255, 0.1) 60%,
    rgba(255, 255, 255, 0.2) 80%,
    rgba(255, 255, 255, 0.3) 100%
  );
}
#search button:hover {
  background: #3837378c;
  cursor: pointer;
  background-image: linear-gradient(
    to right,
    rgba(255, 255, 255, 0.2) 0%,
    rgba(255, 255, 255, 0.1) 20%,
    rgba(255, 255, 255, 0.3) 40%,
    rgba(255, 255, 255, 0.1) 60%,
    rgba(255, 255, 255, 0.2) 80%,
    rgba(255, 255, 255, 0.3) 100%
  );
}

/* 文本目錄為空 */
.article-error {
  margin: 0;
  padding: 0;
  text-align: center;
  color: var(--clr-seal);
}

/* 作者 */
.article-author {
  position: relative;
  overflow: hidden;
  padding: 10px 32px;
  text-indent: 2em;
  color: var(--clr-black);
  font-family: Fuhao, "LXGW Neo ZhiSong", Songti, serif;
  font-weight: Normal;
  background-image: url(../images/svg/articles/author/brush.svg);
  background-size: auto 100%;
  background-position: 32px;
  background-repeat: no-repeat;
}
.article-author::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 32px;
  right: calc(50% - 32px);
  height: 1px;
  background-image: linear-gradient(to right, var(--clr-darkgold), transparent);
}

/* 文章功能選項 */
.article-functions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 10px 10px 32px 10px;
}
.article-functions i {
}
.article-functions a {
  color: #66699988;
  transition: color 0.3s;
}
.article-functions a:hover {
  color: #666999;
}

/* 分享彈窗樣式 */
.share-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(5px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  overflow-y: auto;
}
.share-modal.active {
  opacity: 1;
  visibility: visible;
}
.modal-content {
  background: rgba(30, 30, 40, 0.98);
  border-radius: 16px;
  padding: 30px 20px;
  width: 95%;
  max-width: 400px;
  max-height: 90vh;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
  transform: translateY(-50px);
  transition: transform 0.4s ease;
  position: relative;
  overflow-y: auto;
}
.share-modal.active .modal-content {
  transform: translateY(0);
}
.close-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 1rem;
  z-index: 10;
}
.close-btn i {
  margin: 0;
}
.close-btn:hover {
  background: rgba(255, 255, 255, 0.25);
}
.modal-title {
  font-size: 1.5rem;
  margin-bottom: 20px;
  text-align: center;
  color: var(--clr-auxiliary);
  padding: 0 10px;
}
.share-options {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.share-option {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 15px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
}
.share-option:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: translateY(-3px);
}
.share-icon {
  font-size: 1.8rem;
  margin-bottom: 8px;
}
.share-label {
  font-size: 0.8rem;
  color: #e0e0f0;
}
.url-copy {
  margin-top: 20px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 8px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
}
.url-input {
  flex: 1;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 12px 15px;
  color: #fff;
  font-size: 0.85rem;
  margin-bottom: 10px;
  width: 100%;
  box-sizing: border-box;
}
.copy-btn {
  background: var(--clr-btn);
  color: white;
  border: none;
  padding: 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 0.9rem;
  width: 100%;
}
.copy-btn:hover {
  background: var(--clr-btn-hover);
}
.notification {
  position: fixed;
  top: 15px;
  right: 15px;
  left: 15px;
  background: rgba(46, 204, 113, 0.95);
  color: white;
  padding: 12px 20px;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  transform: translateY(-100px);
  transition: transform 0.4s ease;
  z-index: 2000;
  text-align: center;
  max-width: 90vw;
  margin: 0 auto;
}
.notification.show {
  transform: translateY(0);
}
@media (max-width: 768px) {
  .modal-content {
    padding: 25px 15px;
    max-width: 360px;
  }
  .modal-title {
    font-size: 1.4rem;
    margin-bottom: 15px;
  }
  .share-options {
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
  }
  .share-option {
    padding: 12px 6px;
  }
  .share-icon {
    font-size: 1.6rem;
  }
  .share-label {
    font-size: 0.75rem;
  }
}
@media (max-width: 480px) {
  .modal-content {
    padding: 20px 12px;
    border-radius: 14px;
    width: 80%;
    max-width: 80vw;
  }
  .close-btn {
    top: 8px;
    right: 8px;
    width: 32px;
    height: 32px;
    font-size: 0.9rem;
  }
  .modal-title {
    font-size: 1.3rem;
    margin-bottom: 12px;
  }
  .share-options {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }
  .share-option {
    padding: 10px 5px;
    border-radius: 10px;
  }
  .share-icon {
    font-size: 1.5rem;
    margin-bottom: 6px;
  }
  .share-label {
    font-size: 0.7rem;
  }
  .url-copy {
    margin-top: 15px;
    padding: 10px;
  }
  .url-input {
    padding: 10px 12px;
    font-size: 0.8rem;
  }
  .copy-btn {
    padding: 10px;
    font-size: 0.85rem;
  }
  .notification {
    padding: 10px 15px;
    font-size: 0.9rem;
  }
}
@media (max-width: 360px) {
  .share-options {
    grid-template-columns: repeat(2, 1fr);
    gap: 6px;
  }
  .share-option {
    padding: 8px 4px;
  }
  .share-icon {
    font-size: 1.4rem;
  }
  .share-label {
    font-size: 0.65rem;
  }
}

/* 文章段落樣式 */
.article-p{
  text-indent: 32px;
}
@media (max-width: 768px) {
	.article-p{
	  text-indent: 0;
	}
}
.article-h1,
.article-h2,
.article-h3 {
  margin: 16px 0;
  padding-left: 0;
  font-weight: bold;
}
.article-h1 {
  position: relative;
  padding:0;
  text-indent:28px;
  font-size: var(--fs-Big);
  font-family: Fuhao, Heiti, sans-serif;
  color: var(--clr-darkblack);
}
.article-h1::after {
	content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 20px;
    height: 20px;
    background-image: var(--bgimg-h1);
    background-size: 100% 100%;
    background-repeat: no-repeat;
}
.article-h2 {
  position: relative;
  padding:0;
  text-indent:28px;
  font-size: var(--fs-Normal);
  color: var(--clr-darkblack);
}
.article-h2::after {
	content: "";
    position: absolute;
    top: -2px;
    left: 0;
    width: 20px;
    height: 20px;
    background-image: var(--bgimg-h2);
	background-size: 100% 100%;
	background-repeat: no-repeat;
}
.article-h3 {
  position: relative;
  padding:0;
  text-indent:28px;
  font-size: var(--fs-Normal);
  color: var(--clr-darkblack);
}
.article-h3::after {
	content: "";
    position: absolute;
	top: 0px;
    left: 2px;
    width: 16px;
    height: 16px;
    background-image: var(--bgimg-h3);
	background-size: 100% 100%;
	background-repeat: no-repeat;
}
.article-quote {
  margin-left: 0;
  padding-left: 12px;
  border-left: 2px solid var(--clr-grey);
}
.article-content hr {
  border: 0;
  opacity: 0.45;
  height: 16px;
  margin: 32px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 12' fill='%233498db'%3E%3Cpath d='M0,6 L24,6' stroke='%233498db' stroke-width='2' stroke-dasharray='5,5'/%3E%3Ccircle cx='12' cy='6' r='4' fill='%23e74c3c'/%3E%3C/svg%3E")
    center/24px 12px repeat-x;
}
.article-content table {
  margin: 0 auto;
}
.article-content th,
.article-content td {
  padding: 0 10px;
}
.article-content tbody {
  border-top: 1px solid #333;
  border-bottom: 1px solid #333;
}
.article-ol, .article-ul {
  margin: 16px 0;
  padding: 24px 36px 24px 36px;
  border:1px solid var(--clr-grey);
  border-radius:12px;
  display: block;
  overflow: auto;
}
.article-ol p, .article-ul p{
  margin:0;
  padding: 0;
  text-indent: 0;
  text-align:1.5;
}
.footnote-ref {
  padding: 1px 4px;
  border-radius: 10px;
  background-color: #e64d4d;
  color: var(--clr-white);
}
.footnote-backref {
  color: #7292ad;
}
.footnotes {
	width:100%;
  font-size: var(--fs-Small);
  overflow: auto;
}

/* 文章插入的圖片、音樂、視頻樣式 */
.netease {
  padding-left: 24px;
}
.bilibili {
  padding:0 32px;
}
.aplayer-div {
  margin: 16px 32px;
  width: calc(100% + 5px);
  transform: translateX(-5px);
}
@media (max-width: 768px) {
  .password-prompt {
    margin: 32px;
  }
  .netease {
    padding-left: 0;
    transform: translateX(-10px);
  }
  .bilibili {
  padding:0;
}
  .aplayer-div {
    margin: 16px 0;
  }
}
/* 數學公式放大後的背景和邊框 */
#MathJax_Zoom {
	background-color:var(--clr-white) !important;
	border: 1px solid var(--clr-black) !important;
}

/* 代碼&代碼塊 */
code{
	margin:0 5px;
	padding:5px 10px;
	background:var(--clr-black);
	border-radius:10px;
	color:var(--clr-white);
	font-family:Heiti, sans-serif;
}
pre{
	padding:10px;
	background:var(--clr-black);
	border-radius:10px;
}
pre code{
	margin:0;
	padding:0;
	background:var(--clr-black);
	color:var(--clr-white);
	font-family:Heiti, sans-serif;
}

/* 標籤 */
.tags {
  clear: both;
  padding: 32px;
  text-align: left;
  font: var(--fs-Small) Heiti;
}
.tags a {
  padding: 5px 12px;
  color: white;
  text-shadow: 1px 1px 2px var(--clr-white-shadow);
  border-radius: 5px;
  background-color: var(--clr-lightblue);
}
.tags a:hover {
  background-color: var(--clr-blackblue);
}

/* 文章時間 */
.article-time {
  display: flex;
  justify-content: space-between;
  position: relative;
  margin: 32px;
  padding: 8px 0;
  font-size: var(--fs-Small);
  font-family: Fuhao, Heiti, sans-serif;
  font-weight: Normal;
  color: var(--clr-darkgrey);
}
.article-time::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 50%;
  height: 1px;
  background-image: linear-gradient(to left, var(--clr-darkgold), transparent);
}
.article-time a {
  color: var(--clr-darkgrey);
}

/* 評論按鈕 */
.comment-button-container {
  padding: 0;
}
.comment-button {
  padding: 8px 10px;
  background: var(--clr-white);
  border: 1px solid #ddd;
  border-radius: 5px;
  color: var(--clr-darkgrey);
  text-decoration: none;
  font-family: Fuhao, Heiti, sans-serif;
  font-size: var(--fs-Small);
}
.comment-button:hover {
  background: var(--clr-brightwhite);
}

/* 加密文章 */
.password-prompt {
  width: calc(100% - 96px);
  margin: 32px auto;
  margin-left: 64px;
  padding: 20px;
  text-align: center;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  background-color: var(--clr-white);
  color:var(--clr-black);
  font-family: Fuhao, "LXGW Neo ZhiSong", Songti, serif;
}
@media (max-width: 768px) {
  .password-prompt {
    width: calc(100% - 64px);
    margin: 32px auto;
  }
}
.password-prompt form {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}
.password-prompt input[type="password"] {
  padding: 8px 12px;
  border: 1px solid #ddd;
  border-radius: 4px;
  width: 100%;
  max-width: 250px;
  background-color: var(--clr-brightwhite);
}
.password-prompt button {
  padding: 4px 12px;
  background-color: var(--clr-a-current);
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
}

/* 相邻文章导航 */
.adjacent-articles {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 40px 32px 20px 32px;
    padding: 20px 0;
    border-top: 1px solid var(--clr-borderline);
    border-bottom: 1px solid var(--clr-borderline);
}

.adjacent-prev,
.adjacent-next {
    display: flex;
    flex-direction: column;
    max-width: 45%;
}

.adjacent-label {
    font-size: var(--fs-Small);
    color: var(--clr-darkgrey);
    margin-bottom: 8px;
    font-family: Fuhao, Heiti, sans-serif;
}

.adjacent-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: var(--clr-black);
    transition: color 0.3s ease;
    font-family: Fuhao, "LXGW Neo ZhiSong", Songti, serif;
}

.adjacent-link:hover {
    color: var(--clr-blue);
}

.adjacent-title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    line-height: 1.4;
}

.adjacent-prev .adjacent-link {
    text-align: left;
}

.adjacent-next .adjacent-link {
    text-align: right;
    flex-direction: row;
}

.adjacent-prev i,
.adjacent-next i {
    margin: 0 10px;
    font-size: var(--fs-Small);
    color: var(--clr-darkgrey);
}

@media (max-width: 768px) {
    .adjacent-articles {
        flex-direction: column;
        gap: 20px;
        margin: 30px 16px 15px 16px;
    }
    
    .adjacent-prev,
    .adjacent-next {
        max-width: 100%;
        width: 100%;
    }
    
    .adjacent-next .adjacent-link {
        justify-content: flex-end;
    flex-direction: row-reverse;
}
}

/* 留言板 */
#guestbook {
  padding: 20px 10%;
  background: var(--clr-brightwhite);
  border-top: 1px dotted var(--clr-darkgold);
}
#guestbook section{
	max-width:1000px;
	margin:0 auto;
}
#guestbook {
    padding: 20px 5%;
}
@media (max-width: 480px) {
  #guestbook {
    padding: 20px;
  }
}

/* pdfBox樣式 */
.pdf-modal {
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background-color: rgba(0, 0, 0, 0.95);
	z-index: 10000;
	display: flex;
	justify-content: center;
	align-items: center;
	opacity: 0;
	visibility: hidden;
	transition: opacity 0.3s ease, visibility 0.3s ease;
}
.pdf-modal.active {
	opacity: 1;
	visibility: visible;
}
.pdf-modal-content {
	position: relative;
	width: 100%;
	height: 100%;
	background-color: #2c3e50;
	overflow: hidden;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}
.pdf-modal-iframe {
	width: 100%;
	height: 100%;
	border: none;
	background: white;
}
.pdf-modal-close-button {
	position: absolute;
    top: 60px;
    right: 40px;
    width: 40px;
    height: 40px;
    background-color: rgb(0 0 0 / 15%);
    backdrop-filter: blur(10px);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    z-index: 10001;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s ease;
	font-size: var(--fs-Big);
}
.pdf-modal-close-button:hover {
	background-color: rgba(255, 82, 82, 0.9);
	transform: scale(1.1);
}
.pdf-modal-close-button i{
	margin:0;
}

/* PDF加载指示器 */
.pdf-loading {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	color: white;
	text-align: center;
	z-index: 10002;
}
.pdf-loading-spinner {
	font-size: 3rem;
	margin-bottom: 20px;
	animation: spin 1.2s linear infinite;
}
@keyframes spin {
	0% { transform: rotate(0deg); }
	100% { transform: rotate(360deg); }
}
.pdf-loading p {
	font-size: var(--fs-Big);
	opacity: 0.9;
}
@media (max-width: 768px) {
	.pdf-modal-close-button {
		top: 54px;
		right: 16px;
		width: 30px;
		height: 30px;
		font-size: var(--fs-Normal);
	}
}

/* 文章歸檔 */
.archive-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 20px;
  font-family: Fuhao, "Cambria", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  color: #333;
}
.archive-year {
  position: relative;
  margin-top: 50px;
  border-bottom: 1px solid var(--clr-darkgold);
  color: var(--clr-black);
  font-size: var(--fs-Big);
}
.archive-count {
  position: absolute;
  right: 40px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1rem;
}
.archive-year-group {
  margin-bottom: 30px;
}
.archive-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.archive-item {
  display: flex;
  align-items: center;
  padding: 12px;
  border-bottom: 1px dashed var(--clr-grey);
  transition: background-color 0.2s ease;
}
.archive-item:hover {
  background:var(--clr-brightwhite);
}
.archive-date {
  flex: 0 0 80px;
  font-size: 0.8rem;
  color: #777;
}
.archive-title {
  flex: 1;
  font-size: 1rem;
  font-family: Fuhao, "LXGW Neo ZhiSong", Songti, serif;
  text-decoration: none;
  color: var(--clr-darkgrey);
  transition: color 0.2s ease;
}
.archive-title:hover {
  color: #3498db;
  text-decoration: underline;
}
@media (max-width: 768px) {
  .archive-container {
    padding: 15px;
  }
  .archive-year {
  font-size: var(--fs-Big);
  }
  .archive-item {
    flex-direction: column;
    align-items: flex-start;
  }
  .archive-date {
    margin-bottom: 5px;
    flex: 0;
  }
}
.toggle-year {
	cursor: pointer;
	position: relative;
	padding-right: 40px !important;
	transition: all 0.3s ease;
}
.toggle-icon {
	position: absolute;
	right: 5px;
	top: 50%;
	transform: translateY(-50%);
	transition: transform 0.3s ease;
	font-size: var(--fs-Big);
	color: #666;
}
.archive-year-group.collapsed .archive-list {
	display: none;
}
.archive-year-group.expanded .archive-list {
	display: block;
}
 
.archive-year-group.collapsed .toggle-icon {
        transform: translateY(-50%) rotate(0deg);
}
    
.archive-year-group.expanded .toggle-icon {
        transform: translateY(-50%) rotate(0deg);
    }

/* 搜索結果頁 */
.search-status {
  margin: 2rem 0;
  padding: 2rem;
  background: #5883a74f;
  border-radius: 20px;
}
.search-status p{
  font-family: Fuhao, "LXGW Neo ZhiSong", Songti, serif;
  color:var(--clr-black);
}
.no-results {
  padding: 2rem;
  text-align: center;
}
.no-results img {
  width: 100%;
  max-height: 200px;
}
.no-results a {
  color: var(--clr-btn);
}
.no-results a:hover {
  color: var(--clr-btn-hover);
}

/* 標籤雲朵 */
.cloud {
  position: relative;
  top: 0%;
  left: calc(100% - 180px);
  width: 120px;
  height: 48px;
  background: white;
  border-radius: 75px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  display: flex;
  justify-content: center;
  align-items: center;
  animation: float 3s ease-in-out infinite;
}
.cloud::before,
.cloud::after {
  content: "";
  position: absolute;
  background: white;
  border-radius: 50%;
  z-index: 0;
}
.cloud::before {
  width: 60px;
  height: 60px;
  top: -30px;
  left: 18px;
}
.cloud::after {
  width: 72px;
  height: 72px;
  top: -36px;
  right: 18px;
}
.cloud a {
  position: relative;
  z-index: 1;
  width:100px;
  margin:0 auto;
  text-align:center;
  font-size: 16px;
  color: grey;
  text-decoration: none;
  font-family: Fuhao, Kaiti, sans-serif;
}
@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-12px);
  }
}
@media (max-width: 768px) {
  .cloud {
    position: relative;
    top: 0%;
    left: calc(100% - 120px);
  }
}
@media (max-width: 480px) {
  .cloud {
    position: relative;
    top: 0%;
    left: calc(100% - 100px);
  }
}

/* 標籤雲 */
.cloud-title,
.year-title {
  margin: 60px 0 0 0;
  text-align: center;
}
.cloud-subtitle,
.year-subtitle {
  margin: 0;
  text-align: center;
  font-size: var(--fs-Normal);
  font-family: Fuhao, Heiti;
  color: var(--clr-darkgrey);
}
.cloud-container {
  text-align: center;
  padding: 2rem;
  line-height: 2.5;
  word-break: keep-all;
}
.cloud-tag {
  display: inline-block;
  margin: 0 0.5rem;
  transition: all 0.3s ease;
  text-decoration: none;
  text-shadow: 1px 1px 2px var(--clr-white-shadow);
  opacity: 0.9;
  font-family: Fuhao, "寒蝉全圆体", Kaiti, serif;
  font-weight: Normal;
}
.cloud-tag:hover {
  transform: scale(1.15);
  opacity: 1;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}
.no-tags {
  text-align: center;
  color: #999;
  padding: 2rem;
}