/* ============================================
   海外仓PM博客 - 组件样式补充
   ============================================ */

/* --- 移动端菜单按钮 --- */
.mobile-menu-btn {
  display: none;
  width: 32px;
  height: 24px;
  position: relative;
  background: none;
  border: none;
  cursor: pointer;
  z-index: 1001;
}

.mobile-menu-btn span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--accent);
  position: absolute;
  transition: all 0.3s;
}

.mobile-menu-btn span:nth-child(1) { top: 0; }
.mobile-menu-btn span:nth-child(2) { top: 50%; transform: translateY(-50%); }
.mobile-menu-btn span:nth-child(3) { bottom: 0; }

.mobile-menu-btn.open span:nth-child(1) {
  top: 50%;
  transform: translateY(-50%) rotate(45deg);
}

.mobile-menu-btn.open span:nth-child(2) {
  opacity: 0;
}

.mobile-menu-btn.open span:nth-child(3) {
  bottom: 50%;
  transform: translateY(50%) rotate(-45deg);
}

/* --- 移动端菜单面板 --- */
.mobile-nav {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(20, 22, 27, 0.98);
  backdrop-filter: blur(20px);
  z-index: 999;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 32px;
}

.mobile-nav.active {
  display: flex;
}

.mobile-nav a {
  font-family: var(--font-mono);
  font-size: 20px;
  color: var(--grey-light);
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 2px;
  transition: color 0.3s;
}

.mobile-nav a:hover {
  color: var(--accent);
}

@media (max-width: 768px) {
  .mobile-menu-btn {
    display: block;
  }
}

/* --- 回到顶部按钮 --- */
.back-to-top {
  position: fixed;
  bottom: 32px;
  right: 32px;
  width: 44px;
  height: 44px;
  background: var(--bg-card);
  border: 1px solid var(--grey-dark);
  border-radius: var(--radius-sm);
  color: var(--grey-light);
  font-family: var(--font-mono);
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 900;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s;
}

.back-to-top.visible {
  opacity: 1;
  pointer-events: auto;
}

.back-to-top:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}

/* --- 文章卡片分类过渡 --- */
.article-card {
  transition: opacity 0.4s ease, transform 0.4s ease, box-shadow 0.4s, border-color 0.4s;
}

.article-card.filtering-out {
  opacity: 0;
  transform: scale(0.95);
  pointer-events: none;
}

/* --- Hero条形码随机高度 --- */
.hero-barcode span:nth-child(1) { height: 18px; }
.hero-barcode span:nth-child(2) { height: 26px; }
.hero-barcode span:nth-child(3) { height: 14px; }
.hero-barcode span:nth-child(4) { height: 22px; }
.hero-barcode span:nth-child(5) { height: 10px; }
.hero-barcode span:nth-child(6) { height: 28px; }
.hero-barcode span:nth-child(7) { height: 16px; }
.hero-barcode span:nth-child(8) { height: 24px; }
.hero-barcode span:nth-child(9) { height: 12px; }
.hero-barcode span:nth-child(10) { height: 20px; }

.article-card-barcode span:nth-child(1) { height: 8px; }
.article-card-barcode span:nth-child(2) { height: 14px; }
.article-card-barcode span:nth-child(3) { height: 6px; }
.article-card-barcode span:nth-child(4) { height: 12px; }
.article-card-barcode span:nth-child(5) { height: 10px; }
.article-card-barcode span:nth-child(6) { height: 16px; }
.article-card-barcode span:nth-child(7) { height: 8px; }
.article-card-barcode span:nth-child(8) { height: 18px; }
.article-card-barcode span:nth-child(9) { height: 6px; }
.article-card-barcode span:nth-child(10) { height: 14px; }
.article-card-barcode span:nth-child(11) { height: 10px; }
.article-card-barcode span:nth-child(12) { height: 8px; }
.article-card-barcode span:nth-child(13) { height: 16px; }
.article-card-barcode span:nth-child(14) { height: 6px; }
.article-card-barcode span:nth-child(15) { height: 12px; }
.article-card-barcode span:nth-child(16) { height: 10px; }
.article-card-barcode span:nth-child(17) { height: 14px; }
.article-card-barcode span:nth-child(18) { height: 6px; }
.article-card-barcode span:nth-child(19) { height: 18px; }
.article-card-barcode span:nth-child(20) { height: 8px; }

.footer-barcode span:nth-child(1) { height: 10px; }
.footer-barcode span:nth-child(2) { height: 16px; }
.footer-barcode span:nth-child(3) { height: 8px; }
.footer-barcode span:nth-child(4) { height: 20px; }
.footer-barcode span:nth-child(5) { height: 12px; }
.footer-barcode span:nth-child(6) { height: 6px; }
.footer-barcode span:nth-child(7) { height: 14px; }
.footer-barcode span:nth-child(8) { height: 18px; }
.footer-barcode span:nth-child(9) { height: 8px; }
.footer-barcode span:nth-child(10) { height: 12px; }

/* --- 弹窗内滚动条 --- */
.modal-content::-webkit-scrollbar {
  width: 4px;
}

.modal-content::-webkit-scrollbar-track {
  background: transparent;
}

.modal-content::-webkit-scrollbar-thumb {
  background: var(--grey-dark);
  border-radius: 2px;
}

/* --- Section过渡效果 --- */
/* section 默认可见，入场动画由 JS 渐进增强 */
.section.revealed {
  animation: sectionFadeIn 0.8s ease forwards;
}

@keyframes sectionFadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
