/* ========== 个人站共享样式 (2026-08-11) ========== */

/* --- 顶部滚动进度条 --- */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  background: #0066ff;
  z-index: 100;
  width: 0;
  transition: width 0.1s linear;
}

/* --- 右下角置顶按钮(带进度环) --- */
.back-top {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
  z-index: 90;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: opacity 0.3s, transform 0.3s, visibility 0.3s;
  cursor: pointer;
  border: none;
  padding: 0;
}
.back-top.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.back-top::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: conic-gradient(#0066ff var(--progress, 0%), #e5e7eb 0);
  -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 3px), #000 calc(100% - 3px));
  mask: radial-gradient(farthest-side, transparent calc(100% - 3px), #000 calc(100% - 3px));
}
.back-top .arrow {
  font-size: 15px;
  color: #333;
  line-height: 1;
}

/* --- 瀑布流 --- */
.masonry {
  columns: 4;
  column-gap: 12px;
}
.masonry.compact {
  columns: 5;
}
.masonry.wide {
  columns: 2;
}
.masonry-item {
  break-inside: avoid;
  margin-bottom: 24px;
}
@media (max-width: 1024px) {
  .masonry { columns: 3; }
  .masonry.compact { columns: 4; }
}
@media (max-width: 640px) {
  .masonry { columns: 2; }
  .masonry.compact { columns: 2; }
  .masonry.wide { columns: 1; }
}

/* --- 照片卡片 --- */
.photo-card {
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.06);
  background: #fff;
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}
.photo-card:hover {
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.12);
  transform: translateY(-2px);
}
.photo-card img {
  display: block;
  width: 100%;
  height: auto;
  transition: transform 0.5s ease;
}
.photo-card:hover img {
  transform: scale(1.03);
}
.photo-card .pc-meta {
  padding: 10px 14px 12px;
}
.photo-card .pc-meta .pc-name {
  font-size: 13px;
  color: #111;
  font-weight: 500;
  line-height: 1.4;
}
.photo-card .pc-meta .pc-loc {
  font-size: 12px;
  color: #9ca3af;
  margin-top: 2px;
}

/* --- 筛选 chips --- */
.chip {
  padding: 7px 16px;
  border-radius: 999px;
  font-size: 13px;
  background: #f3f4f6;
  color: #4b5563;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.2s ease;
  white-space: nowrap;
  user-select: none;
}
.chip:hover {
  background: #e5e7eb;
}
.chip.active {
  background: #111;
  color: #fff;
}

/* --- 视图切换分段按钮 --- */
.seg {
  display: inline-flex;
  background: #f3f4f6;
  border-radius: 10px;
  padding: 3px;
  gap: 2px;
}
.seg button {
  padding: 6px 16px;
  font-size: 13px;
  border-radius: 8px;
  color: #6b7280;
  transition: all 0.25s ease;
  border: none;
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  line-height: 1.4;
}
.seg button.active {
  background: #fff;
  color: #111;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}
.seg button:hover:not(.active) {
  color: #111;
}

/* --- 滚动淡入动画 --- */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.fade-in.active {
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  .fade-in {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* --- 灯箱 EXIF 信息 --- */
.lg-sub-html .lg-exif-line {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.75);
  margin-top: 6px;
  letter-spacing: 0.3px;
}
.lg-sub-html h4 {
  font-size: 15px;
}

/* --- 首页精选墙 --- */
.feature-wall .photo-card img {
  min-height: 120px;
}
