/**
 * 节气文库：版式、手风琴、侧栏与工具条
 */
.library-app.is-hidden {
  display: none;
}

/* —— 页头 —— */
.library-intro {
  margin-bottom: 1.25rem;
}
.library-intro-title {
  font-family: var(--site-font-serif);
  font-size: clamp(1.35rem, 2.5vw, 1.75rem);
  font-weight: 700;
  letter-spacing: 0.06em;
  color: rgb(var(--site-primary-rgb, 22 163 74));
  margin: 0 0 1rem;
}
.dark .library-intro-title {
  color: rgb(52 211 153);
}
.library-intro-lead {
  margin: 0;
  font-size: 0.875rem;
  line-height: 1.55;
  color: rgb(71 85 105);
  max-width: 42rem;
}
.dark .library-intro-lead {
  color: rgb(148 163 184);
}

.library-sync-banner {
  margin-top: 0.75rem;
  padding: 0.65rem 0.85rem;
  font-size: 0.8125rem;
  line-height: 1.5;
  border-radius: 0.5rem;
  border-left: 3px solid rgb(34 197 94);
  background: rgba(240 253 244 / 0.9);
  color: rgb(51 65 85);
}
.dark .library-sync-banner {
  background: rgba(12 74 110 / 0.35);
  color: rgb(203 213 225);
  border-left-color: rgb(56 189 248);
}
.library-sync-banner.is-hidden {
  display: none;
}
.library-sync-banner-btn {
  cursor: pointer;
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  color: rgb(var(--site-primary-rgb, 22 163 74));
  text-decoration: underline;
  text-underline-offset: 2px;
}
.dark .library-sync-banner-btn {
  color: rgb(52 211 153);
}

/* —— 工具条（搜索 + 四季 + 小中大 + AI + 沉浸阅读 同一行，窄屏自动换行） —— */
.library-toolbar {
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
}
.library-toolbar-single {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem 0.85rem;
  width: 100%;
}
.library-toolbar-single .library-search-wrap {
  flex: 1 1 16rem;
  min-width: min(100%, 12rem);
  display: flex;
  gap: 0.5rem;
  align-items: center;
}
.library-toolbar-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem 0.5rem;
  flex: 1 1 auto;
  justify-content: flex-end;
  min-width: min(100%, 14rem);
}
.library-toolbar-divider {
  width: 1px;
  height: 1.25rem;
  background: rgba(148, 163, 184, 0.35);
  flex-shrink: 0;
}
.dark .library-toolbar-divider {
  background: rgba(148, 163, 184, 0.2);
}
.library-toolbar-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-left: auto;
}

.library-input {
  flex: 1;
  min-width: 0;
  border-radius: 0.65rem;
  border: 1px solid rgb(226 232 240);
  padding: 0.5rem 0.75rem;
  font-size: 0.9rem;
}
.dark .library-input {
  border-color: rgb(51 65 85);
  background: rgba(15, 23, 42, 0.55);
  color: rgb(241 245 249);
}

.library-search-submit,
.library-search-clear {
  flex-shrink: 0;
  padding: 0.45rem 0.75rem;
  border-radius: 0.6rem;
  border: 1px solid rgba(22, 93, 255, 0.35);
  background: rgba(22, 93, 255, 0.08);
  cursor: pointer;
  font-size: 0.85rem;
}

.library-season-btn {
  padding: 0.28rem 0.6rem;
  border-radius: 9999px;
  border: 1px solid rgba(148, 163, 184, 0.4);
  background: transparent;
  font-size: 0.75rem;
  cursor: pointer;
  color: inherit;
}
.library-season-btn.is-active {
  background: rgba(22, 93, 255, 0.12);
  border-color: rgba(22, 93, 255, 0.45);
  font-weight: 600;
}

.library-font-btn {
  min-width: 2rem;
  padding: 0.22rem 0.42rem;
  border-radius: 0.35rem;
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
  font-size: 0.75rem;
  color: inherit;
}
.library-font-btn.is-active {
  border-color: rgb(var(--site-primary-rgb, 22 163 74) / 0.45);
  background: rgb(var(--site-primary-rgb, 22 163 74) / 0.1);
}

.library-tool-btn {
  padding: 0.35rem 0.6rem;
  border-radius: 0.55rem;
  border: 1px solid rgba(148, 163, 184, 0.45);
  background: rgba(255, 255, 255, 0.65);
  font-size: 0.78rem;
  cursor: pointer;
  color: inherit;
}
.dark .library-tool-btn {
  background: rgba(15, 23, 42, 0.5);
}
.library-tool-btn--primary {
  border-color: rgb(var(--site-primary-rgb, 22 163 74) / 0.45);
  background: rgb(var(--site-primary-rgb, 22 163 74) / 0.12);
  color: rgb(var(--site-primary-rgb, 22 163 74));
  font-weight: 600;
}
.dark .library-tool-btn--primary {
  color: rgb(52 211 153);
}
.library-tool-btn--ghost {
  border-style: dashed;
  opacity: 0.95;
}
body.library-immersive .library-tool-btn#library-immersive-btn,
#library-immersive-btn[aria-pressed='true'] {
  border-style: solid;
  border-color: rgb(var(--site-primary-rgb, 22 163 74) / 0.55);
  background: rgb(var(--site-primary-rgb, 22 163 74) / 0.16);
}

.library-immersive-exit-fab {
  position: fixed;
  bottom: 5rem;
  right: 1rem;
  z-index: 100;
  padding: 0.5rem 0.85rem;
  border-radius: 9999px;
  border: none;
  background: rgba(15, 23, 42, 0.88);
  color: #fff;
  font-size: 0.8rem;
  cursor: pointer;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

/* —— 节气索引条 —— */
.library-scroll-strip {
  overflow-x: auto;
  white-space: nowrap;
  padding: 0.5rem 0.65rem;
  margin-bottom: 1.25rem;
  scrollbar-width: thin;
}
.library-scroll-item {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-right: 0.35rem;
  padding: 0.4rem 0.75rem;
  border-radius: 9999px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(248, 250, 252, 0.85);
  font-size: 0.8125rem;
  cursor: pointer;
  color: rgb(51 65 85);
  vertical-align: middle;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.dark .library-scroll-item {
  background: rgba(15, 23, 42, 0.55);
  border-color: rgba(148, 163, 184, 0.22);
  color: rgb(203 213 225);
}
.library-scroll-item.is-active {
  border-color: rgb(var(--site-primary-rgb, 22 163 74));
  background: rgb(var(--site-primary-rgb, 22 163 74) / 0.12);
  font-weight: 600;
  color: rgb(var(--site-primary-rgb, 22 163 74));
}
.dark .library-scroll-item.is-active {
  color: rgb(52 211 153);
}
.library-scroll-item.is-fav::after {
  content: '★';
  font-size: 0.65rem;
  opacity: 0.75;
}
.library-idx {
  opacity: 0.55;
  font-size: 0.7rem;
  font-variant-numeric: tabular-nums;
}

/* —— 主栅格：左配图/视频/关联 → 中节气档案 → 右最近浏览等 —— */
.library-main-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 1fr;
  align-items: start;
}
.library-col {
  min-width: 0;
}
@media (min-width: 1024px) {
  .library-main-grid {
    grid-template-columns: minmax(200px, 0.95fr) minmax(0, 1.35fr) minmax(200px, 17.5rem);
  }
  .library-col--left {
    grid-column: 1;
  }
  .library-col--center {
    grid-column: 2;
  }
  .library-col--right {
    grid-column: 3;
  }
}

/* —— 视觉卡 —— */
.library-hero-media {
  position: relative;
}
.library-hero-picture {
  position: relative;
  aspect-ratio: 16 / 9;
  background: rgba(15, 23, 42, 0.35);
}
.library-hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.library-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(15, 23, 42, 0.45), transparent 50%);
  pointer-events: none;
}
.library-hero-caption {
  margin: 0;
  padding: 0.5rem 1rem;
  font-size: 0.75rem;
  line-height: 1.45;
  color: rgb(71 85 105);
}
.dark .library-hero-caption {
  color: rgb(148 163 184);
}

.library-archive-title {
  margin: 0;
  padding: 0.85rem 1rem 0.65rem;
  font-family: var(--site-font-serif);
  font-size: clamp(1.1rem, 2.2vw, 1.35rem);
  font-weight: 700;
  letter-spacing: 0.04em;
  color: rgb(30 41 59);
  border-bottom: 1px solid rgba(148, 163, 184, 0.22);
}
.dark .library-archive-title {
  color: rgb(226 232 240);
  border-bottom-color: rgba(148, 163, 184, 0.12);
}
.library-accordions-wrap {
  overflow: hidden;
}
.library-quick-tags--under-hero {
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  padding-top: 0.75rem;
}
.dark .library-quick-tags--under-hero {
  border-top-color: rgba(148, 163, 184, 0.1);
}
.library-actions-row--under-hero {
  padding-top: 0.35rem;
  margin-top: 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
}
.dark .library-actions-row--under-hero {
  border-bottom-color: rgba(148, 163, 184, 0.12);
}
.library-panel--recent {
  border-color: rgba(22, 93, 255, 0.22);
  background: rgba(22, 93, 255, 0.04);
}
.dark .library-panel--recent {
  border-color: rgba(96, 165, 250, 0.22);
  background: rgba(22, 93, 255, 0.08);
}

.library-quick-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  padding: 0.5rem 1rem 0.35rem;
}
.library-tag {
  display: inline-block;
  padding: 0.25rem 0.55rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  background: rgb(var(--site-primary-rgb, 22 163 74) / 0.1);
  border: 1px solid rgb(var(--site-primary-rgb, 22 163 74) / 0.22);
  color: rgb(var(--site-primary-rgb, 22 163 74));
  cursor: default;
}
.dark .library-tag {
  background: rgb(var(--site-primary-rgb, 22 163 74) / 0.14);
  border-color: rgb(var(--site-primary-rgb, 22 163 74) / 0.28);
  color: rgb(167 243 208);
}

.library-actions-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  padding: 0 1rem 0.75rem;
}
.library-accordions-wrap > .library-actions-row {
  border-bottom: 1px solid rgba(148, 163, 184, 0.15);
}
.dark .library-accordions-wrap > .library-actions-row {
  border-bottom-color: rgba(148, 163, 184, 0.1);
}
.library-stars-wrap {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-width: 6.5rem;
}
.library-rating-hint {
  margin: 0;
  font-size: 0.7rem;
  line-height: 1.35;
  color: rgb(100 116 139);
  max-width: 14rem;
}
.dark .library-rating-hint {
  color: rgb(148 163 184);
}

.library-action-btn {
  padding: 0.4rem 0.75rem;
  border-radius: 0.55rem;
  border: 1px solid rgba(148, 163, 184, 0.45);
  background: rgba(255, 255, 255, 0.7);
  font-size: 0.8125rem;
  cursor: pointer;
  color: inherit;
}
.dark .library-action-btn {
  background: rgba(15, 23, 42, 0.45);
  border-color: rgba(148, 163, 184, 0.25);
}
.library-action-btn--primary {
  border-color: rgb(var(--site-primary-rgb, 22 163 74) / 0.45);
  background: rgb(var(--site-primary-rgb, 22 163 74) / 0.12);
  color: rgb(var(--site-primary-rgb, 22 163 74));
  font-weight: 600;
}
.dark .library-action-btn--primary {
  color: rgb(167 243 208);
}
.library-action-btn--ghost {
  border-style: dashed;
  opacity: 0.92;
}

.library-stars {
  display: inline-flex;
  align-items: center;
  gap: 0.15rem;
}
.library-stars button[data-star] {
  border: none;
  background: transparent;
  padding: 0.1rem;
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  color: rgba(148, 163, 184, 0.55);
}
.library-stars button[data-star].is-on {
  color: rgb(var(--site-primary-rgb, 22 163 74));
}

/* 文库互动按钮：收藏/点赞/保存等，按 aria-pressed 高亮（随季节主色） */
.library-action-btn[aria-pressed='true'] {
  border-color: rgb(var(--site-primary-rgb, 22 163 74) / 0.55);
  background: rgb(var(--site-primary-rgb, 22 163 74) / 0.14);
  color: rgb(var(--site-primary-rgb, 22 163 74));
  font-weight: 650;
}

.dark .library-action-btn[aria-pressed='true'] {
  border-color: rgb(var(--site-primary-rgb, 22 163 74) / 0.45);
  background: rgb(var(--site-primary-rgb, 22 163 74) / 0.18);
  color: rgb(167 243 208);
}
#library-stars.library-stars--guest button[data-star] {
  opacity: 0.72;
}

/* 讲解视频 */
.library-explain-video {
  padding: 0.75rem 1rem 1rem;
  border-top: 1px solid rgba(148, 163, 184, 0.2);
}
.dark .library-explain-video {
  border-top-color: rgba(148, 163, 184, 0.12);
}
.library-explain-video-label {
  margin: 0 0 0.5rem;
  font-size: 0.75rem;
  font-weight: 500;
  color: rgb(71 85 105);
  display: flex;
  align-items: center;
  gap: 0.35rem;
}
.dark .library-explain-video-label {
  color: rgb(148 163 184);
}
.library-explain-video-label .fa-circle-play {
  color: rgb(var(--site-primary-rgb, 22 163 74));
  opacity: 0.9;
}
.dark .library-explain-video-label .fa-circle-play {
  color: rgb(52 211 153);
}
.library-video-wrap {
  position: relative;
}
.library-term-explain-video {
  width: 100%;
  max-height: min(56vh, 480px);
  border-radius: 0.75rem;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: #000;
  object-fit: contain;
}
.library-video-enlarge-btn {
  position: absolute;
  bottom: 0.5rem;
  right: 0.5rem;
  padding: 0.35rem 0.65rem;
  border-radius: 0.45rem;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(15, 23, 42, 0.75);
  color: #f8fafc;
  font-size: 0.75rem;
  cursor: pointer;
}
.library-explain-video-msg {
  margin: 0.5rem 0 0;
  font-size: 0.75rem;
  color: rgb(100 116 139);
}
.library-explain-video-msg.hidden {
  display: none;
}

.library-related-under-media {
  padding: 0.85rem 1rem 1rem;
  border-top: 1px solid rgba(148, 163, 184, 0.2);
}
.dark .library-related-under-media {
  border-top-color: rgba(148, 163, 184, 0.12);
}
.library-related-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}
.library-related-link {
  font-size: 0.8125rem;
  padding: 0.35rem 0.65rem;
  border-radius: 0.45rem;
  border: 1px solid rgba(22, 93, 255, 0.25);
  background: rgba(22, 93, 255, 0.06);
  color: rgb(var(--site-primary-rgb, 22 163 74));
  cursor: pointer;
  text-align: left;
}
.dark .library-related-link {
  color: rgb(52 211 153);
  border-color: rgba(96, 165, 250, 0.3);
  background: rgba(22, 93, 255, 0.08);
}

/* —— 手风琴 —— */
.library-accordions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.library-acc-item {
  border-radius: 0.75rem;
  border: 1px solid rgba(148, 163, 184, 0.28);
  background: rgba(255, 255, 255, 0.72);
  overflow: hidden;
}
.dark .library-acc-item {
  border-color: rgba(148, 163, 184, 0.15);
  background: rgba(15, 23, 42, 0.45);
}
.library-acc-head {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border: none;
  background: transparent;
  font-size: 0.9rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  color: inherit;
}
.library-acc-icon {
  font-size: 0.65rem;
  opacity: 0.65;
  transition: transform 0.2s ease;
}
.library-acc-item.is-open .library-acc-icon {
  transform: rotate(-180deg);
}
.library-acc-panel {
  display: none;
  border-top: 1px solid rgba(148, 163, 184, 0.18);
}
.dark .library-acc-panel {
  border-top-color: rgba(148, 163, 184, 0.1);
}
.library-acc-item.is-open .library-acc-panel {
  display: block;
}
.library-acc-inner {
  padding: 0.85rem 1rem 1rem;
  font-size: 0.9375rem;
  line-height: 1.75;
  color: rgb(51 65 85);
}
.dark .library-acc-inner {
  color: rgb(203 213 225);
}
.library-poem-block + .library-poem-block {
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px dashed rgba(148, 163, 184, 0.35);
}
.library-poem-lines {
  margin-top: 0.5rem;
  white-space: pre-wrap;
  font-family: var(--site-font-serif);
}
.library-ancient-item {
  padding: 0.65rem 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.15);
  font-size: 0.9rem;
  line-height: 1.65;
}
.library-ancient-item:last-child {
  border-bottom: none;
}

/* —— 侧栏 —— */
.library-aside {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.library-panel {
  border-radius: 0.85rem;
  padding: 0.85rem 1rem;
  border: 1px solid rgba(148, 163, 184, 0.22);
  background: rgba(255, 255, 255, 0.78);
  backdrop-filter: blur(8px);
}
.dark .library-panel {
  border-color: rgba(148, 163, 184, 0.14);
  background: rgba(15, 23, 42, 0.55);
}
.library-aside-title {
  margin: 0 0 0.5rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgb(100 116 139);
}
.dark .library-aside-title {
  color: rgb(148 163 184);
}
.library-aside-body {
  font-size: 0.875rem;
  line-height: 1.55;
  color: rgb(51 65 85);
}
.dark .library-aside-body {
  color: rgb(203 213 225);
}
.library-aside-body .library-jump-term,
#library-recent .library-jump-term {
  display: block;
  width: 100%;
  padding: 0.2rem 0;
  border: none;
  background: none;
  text-align: left;
  color: rgb(var(--site-primary-rgb, 22 163 74));
  cursor: pointer;
  font-size: inherit;
}
.dark .library-aside-body .library-jump-term {
  color: rgb(52 211 153);
}
.library-aside-body .library-jump-term:hover {
  text-decoration: underline;
}

.library-panel--notes .library-note-area {
  margin-top: 0.5rem;
}
.library-note-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.5rem;
}
.library-note-list {
  margin-bottom: 0.5rem;
  max-height: 11rem;
  overflow-y: auto;
}
.library-note-item {
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(148, 163, 184, 0.15);
  font-size: 0.8125rem;
}
.library-note-item:last-child {
  border-bottom: none;
}
.library-note-item-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-top: 0.35rem;
  font-size: 0.7rem;
  color: rgb(100 116 139);
}
.library-note-item-del {
  border: none;
  background: none;
  color: rgb(239 68 68);
  cursor: pointer;
  font-size: inherit;
  padding: 0;
}
.library-note-list-empty {
  margin: 0;
  font-size: 0.8125rem;
  color: rgb(100 116 139);
}
.library-note-area {
  width: 100%;
  border-radius: 0.55rem;
  border: 1px solid rgba(148, 163, 184, 0.35);
  padding: 0.5rem 0.65rem;
  font-size: 0.875rem;
  resize: vertical;
  min-height: 4rem;
  background: rgba(255, 255, 255, 0.9);
  color: inherit;
}
.dark .library-note-area {
  border-color: rgba(148, 163, 184, 0.22);
  background: rgba(2, 6, 23, 0.4);
}
.library-note-preview {
  margin-top: 0.5rem;
  padding: 0.65rem;
  border-radius: 0.5rem;
  background: rgba(148, 163, 184, 0.12);
  font-size: 0.875rem;
  line-height: 1.55;
}
.library-note-preview.is-hidden {
  display: none;
}

.library-deco-symbol {
  margin-top: 2rem;
  display: flex;
  justify-content: center;
  opacity: 0.28;
  color: rgb(var(--site-primary-rgb, 22 163 74));
}

/* —— 骨架屏 —— */
.library-skeleton {
  padding: 1rem 0;
}
.library-skel-block {
  border-radius: 0.5rem;
  background: linear-gradient(90deg, rgba(226, 232, 240, 0.6) 25%, rgba(241, 245, 249, 0.9) 50%, rgba(226, 232, 240, 0.6) 75%);
  background-size: 200% 100%;
  animation: library-shimmer 1.2s ease-in-out infinite;
}
.dark .library-skel-block {
  background: linear-gradient(90deg, rgba(51, 65, 85, 0.5) 25%, rgba(71, 85, 105, 0.35) 50%, rgba(51, 65, 85, 0.5) 75%);
  background-size: 200% 100%;
}
@keyframes library-shimmer {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}
.library-skel-line.lg {
  height: 1.5rem;
  margin-bottom: 0.75rem;
  width: 60%;
}
.library-skel-line.md {
  height: 1rem;
  margin-bottom: 0.5rem;
  width: 40%;
}
.library-skel-strip {
  display: flex;
  gap: 0.35rem;
  margin: 0.75rem 0;
}
.library-skel-chip {
  width: 3rem;
  height: 1.5rem;
  border-radius: 9999px;
  background: rgba(226, 232, 240, 0.8);
}
.library-skel-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}
.library-skel-card {
  min-height: 8rem;
  border-radius: 0.75rem;
}
.library-skel-card.tall {
  min-height: 12rem;
}

.library-load-error.is-hidden {
  display: none;
}

/* 正文字号（与 JS 中 library-font-* 一致） */
#site-section-library.library-font-sm .library-acc-inner {
  font-size: 0.875rem;
}
#site-section-library.library-font-lg .library-acc-inner {
  font-size: 1.0625rem;
}

/* 与脚本 classList 一致 */
.is-hidden {
  display: none !important;
}

/* 沉浸阅读：单列；仅顶部配图（只要图），其下为「当前节气」与手风琴正文 */
body.library-immersive header {
  display: none !important;
}
body.library-immersive .library-intro,
body.library-immersive .library-toolbar,
body.library-immersive #library-scroll-strip {
  display: none !important;
}
body.library-immersive .library-col--right {
  display: none !important;
}
body.library-immersive .library-main-grid {
  grid-template-columns: 1fr !important;
  max-width: 42rem;
  margin-left: auto;
  margin-right: auto;
  gap: 1rem;
}
body.library-immersive .library-col--left,
body.library-immersive .library-col--center {
  grid-column: 1;
}
body.library-immersive .library-visual .library-hero-caption,
body.library-immersive .library-visual .library-quick-tags,
body.library-immersive .library-visual .library-actions-row,
body.library-immersive .library-visual .library-explain-video,
body.library-immersive .library-visual .library-related-under-media {
  display: none !important;
}
body.library-immersive #site-section-library {
  max-width: 44rem;
}
body.library-immersive .library-deco-symbol {
  display: none !important;
}
body.library-immersive .floating-orb,
body.library-immersive .particle-fx-slot {
  display: none !important;
}
body.library-immersive footer {
  display: none !important;
}
#library-immersive-exit.is-hidden {
  display: none !important;
}
body.library-immersive #library-immersive-exit {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
}

/* 媒体灯箱 */
.library-media-lightbox {
  position: fixed;
  inset: 0;
  z-index: 130;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  background: rgba(15, 23, 42, 0.82);
  backdrop-filter: blur(8px);
}
.library-media-lightbox.is-hidden {
  display: none !important;
}
.library-media-lightbox-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: transparent;
  cursor: zoom-out;
}
.library-media-lightbox-panel {
  position: relative;
  z-index: 1;
  max-width: min(96vw, 1100px);
  max-height: 92vh;
}
.library-media-lightbox-close {
  position: absolute;
  top: -2.5rem;
  right: 0;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 999px;
  border: 1px solid rgba(248, 250, 252, 0.35);
  background: rgba(15, 23, 42, 0.6);
  color: #f8fafc;
  cursor: pointer;
  z-index: 2;
}
.library-lightbox-img,
.library-lightbox-video {
  max-width: 100%;
  max-height: min(85vh, 720px);
  border-radius: 0.75rem;
  display: block;
  margin: 0 auto;
}
.library-lightbox-video {
  width: 100%;
  background: #000;
}
