.img_card {
  padding: 0.8rem;
  background: #fafafa;
  box-sizing: border-box;
  border-radius: 0.8rem;
  border: 1px solid rgba(208, 206, 206, 0.3) !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  transition: all 0.23s linear;
  margin-bottom: 0.6rem;
  position: relative;
}

/* 相册头部信息 */
.album-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 0.6rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid rgba(208, 206, 206, 0.15);
}

.avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 14px;
  color: white;
  flex-shrink: 0;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  position: relative;
}

.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  display: block;
}

.avatar span {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: inherit;
}

/* 确保头像不会有图片的悬停效果 */
.avatar img {
  cursor: default !important;
  transition: none !important;
}

.avatar img:hover {
  transform: none !important;
  box-shadow: none !important;
}

.avatar.boy {
  background: linear-gradient(135deg, #4ba8ff, #0066cc);
}

.avatar.girl {
  background: linear-gradient(135deg, #ff84b3, #e91e63);
}

.avatar.neutral {
  background: linear-gradient(135deg, #94a3b8, #64748b);
}

.author-info {
  flex: 1;
  min-width: 0;
}

.author-name {
  font-weight: 600;
  font-size: 0.9rem;
  color: #333;
  margin-bottom: 1px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.post-time {
  font-size: 0.75rem;
  color: #999;
  font-weight: 400;
}

/* 图片容器 */
.image-container {
  margin: 0;
  position: relative;
}

.love_img img {
  width: 100%;
  border-radius: 0.6rem;
  object-fit: cover;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  margin: 0;
  aspect-ratio: 1 / 1 !important;
}

/* 多图自动紧凑网格布局 */
.image-grid {
  display: grid;
  gap: 3px;
  width: 100%;
  margin: 0;
  grid-auto-rows: minmax(50px, auto);
}

/* 根据图片数量自动调整网格布局 */
.image-grid[data-count="1"] {
  grid-template-columns: 1fr;
  grid-template-rows: 1fr;
}

.image-grid[data-count="2"] {
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr;
}

.image-grid[data-count="3"] {
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: 1fr;
}

.image-grid[data-count="4"] {
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
}

.image-grid[data-count="5"] {
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: 1fr 1fr;
}

.image-grid[data-count="6"] {
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: 1fr 1fr;
}

.image-grid[data-count="7"] {
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: 1fr 1fr 1fr;
}

.image-grid[data-count="8"] {
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: 1fr 1fr 1fr;
}

.image-grid[data-count="9"] {
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: 1fr 1fr 1fr;
}

/* 10张以上图片使用瀑布流布局 */
.image-grid[data-count="10"] {
  grid-template-columns: repeat(3, 1fr);
  grid-auto-rows: minmax(60px, auto);
}

.grid-item {
  position: relative;
  border-radius: 6px;
  overflow: hidden;
  background: #f5f5f5;
  min-height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* 单图特殊处理 */
.image-grid[data-count="1"] .grid-item {
  aspect-ratio: 1;
  min-height: 200px;
}

/* 2-3张图片时保持正方形 */
.image-grid[data-count="2"] .grid-item,
.image-grid[data-count="3"] .grid-item {
  aspect-ratio: 1;
  min-height: 80px;
}

/* 4张以上图片紧凑布局 */
.image-grid[data-count="4"] .grid-item,
.image-grid[data-count="5"] .grid-item,
.image-grid[data-count="6"] .grid-item,
.image-grid[data-count="7"] .grid-item,
.image-grid[data-count="8"] .grid-item,
.image-grid[data-count="9"] .grid-item {
  aspect-ratio: 1;
  min-height: 60px;
}

.grid-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 6px;
  margin: 0;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

.grid-item:hover img {
  transform: scale(1.02);
}

/* 更多图片指示器 */
.more-indicator {
  background: rgba(0, 0, 0, 0.7);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.3s ease;
  border-radius: 6px;
  position: relative;
  overflow: hidden;
}

.more-indicator::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s ease;
}

.more-indicator:hover {
  background: rgba(0, 0, 0, 0.8);
  transform: scale(1.05);
}

.more-indicator:hover::before {
  left: 100%;
}

.more-indicator span {
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
  position: relative;
  z-index: 1;
}

.img_card:hover {
  cursor: pointer;
  cursor: url(../cur/hover.cur), pointer;
  background: #494949;
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.love_img img {
  transition: all 0.23s linear;
}

.img_card:hover.love_img .image-container img {
  transform: translateY(-5px);
}

.img_card:active {
  background: #494949;
}

.img_card:hover .image-container img,
.img_card:hover .grid-item img {
  box-shadow: 0 2px 10px #3b3b3bad;
}

.img_card:hover .words span {
  color: #e2e2e2;
}

.img_card:hover .author-name {
  color: #e2e2e2;
}

.img_card:hover .post-time {
  color: #ccc;
}

.img_card:hover .post-date i {
  color: #ccc;
}

/* 标题样式 - 在图片上方 */
.words {
  margin-bottom: 0.5rem;
  padding-bottom: 0.4rem;
  border-bottom: 1px solid rgba(208, 206, 206, 0.15);
}

.words span {
  font-family: 'Noto Serif SC', serif;
  font-weight: 500;
  font-size: 1rem;
  color: #333;
  letter-spacing: 0.3px;
  line-height: 1.3em;
  display: block;
  word-wrap: break-word;
  white-space: normal;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

/* 日期样式 - 在图片下方 */
.post-date {
  margin-top: 0.5rem;
  text-align: right;
  padding-top: 0.4rem;
  border-top: 1px solid rgba(208, 206, 206, 0.15);
}

.post-date i {
  display: inline-block;
  font-style: normal;
  font-family: 'Noto Serif SC', serif;
  font-weight: 400;
  color: #999;
  font-size: 0.8rem;
  letter-spacing: 0.5px;
}

.spl-button,
.spl-description,
.spl-title {
  margin-bottom: 20px;
  font-family: 'Noto Serif SC', serif;
  font-weight: 400;
}

.photo-item {
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.photo-item.show {
  opacity: 1;
  transform: translateY(0);
}

.load-more {
  text-align: center;
  margin-top: 60px;
}


/* 加载动画 */
.loading {
  text-align: center;
  color: #7f8c8d;
  font-size: 1rem;
  display: flex;
  justify-content: center;
  align-items: center;
  font-family: 'Noto Serif SC', serif;

}

.loading::after {
  content: '';
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2px solid #ecf0f1;
  border-top: 2px solid #3498db;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-left: 10px;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* 页面渐入效果 */
.fade-in {
  animation: fadeIn 1s ease-out;
}

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



.lg-btn-alt {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  color: #ffffff;
  background-color: #000000;
  border-style: solid;
  border-width: 1px;
  border-color: rgb(255 255 255);
  border-radius: 40px;
  padding: .6rem 2rem;
  transform: translate(0, 0) rotate(0deg);
  transition: 0.2s;
  cursor: pointer;
  box-shadow: rgba(100, 100, 111, 0.2) 0px 7px 29px 0px;
  font-family: 'Noto Serif SC', serif;
  font-weight: bold;
}

.lg-btn-alt:hover {
color: #516d91;
background-color: #E5EDF5;
box-shadow: -2px -1px 8px 0px #ffffff,
            2px 1px 8px 0px rgb(95 157 231 / 48%);
}

.lg-btn-alt:active {
box-shadow: none;
}

.lg-btn-alt:disabled,
.lg-btn-alt.disabled {
color: #3f3f3f;
background-color: #e0e0e0;
border-color: #ccc;
cursor: not-allowed;
box-shadow: none;
opacity: 0.8;
pointer-events: none;
}

.lg-btn-alt .icon{
width: 16px;
height: 16px;
}

/* 响应式设计 */
@media (max-width: 768px) {
  .img_card {
    padding: 0.7rem;
    margin-bottom: 0.5rem;
  }
  
  .love_img img,
  .image-grid {
    width: 100%;
  }
  
  .album-header {
    gap: 6px;
    margin-bottom: 0.5rem;
  }
  
  .avatar {
    width: 28px;
    height: 28px;
    font-size: 12px;
  }
  
  .avatar img {
    width: 100%;
    height: 100%;
  }
  
  .author-name {
    font-size: 0.85rem;
  }
  
  .post-time {
    font-size: 0.7rem;
  }
  
  .words span {
    font-size: 0.95rem;
  }
  
  .post-date i {
    font-size: 0.75rem;
  }
  
  .gallery {
    gap: 0.3rem;
    padding: 0 0.6rem;
    max-width: 100%;
  }
  
  /* 平板端紧凑布局调整 */
  .image-grid[data-count="4"],
  .image-grid[data-count="5"],
  .image-grid[data-count="6"] {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(3, 1fr);
  }
  
  .image-grid[data-count="7"],
  .image-grid[data-count="8"],
  .image-grid[data-count="9"] {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(4, 1fr);
  }
  
  .image-grid {
    gap: 2px;
  }
  
  .grid-item {
    min-height: 50px;
  }
}

@media (max-width: 480px) {
  .img_card {
    padding: 0.6rem;
    border-radius: 0.6rem;
    margin-bottom: 0.4rem;
  }
  
  .love_img img,
  .image-grid {
    width: 100%;
  }
  
  .album-header {
    gap: 5px;
    margin-bottom: 0.4rem;
  }
  
  .avatar {
    width: 26px;
    height: 26px;
    font-size: 11px;
  }
  
  .avatar img {
    width: 100%;
    height: 100%;
  }
  
  .author-name {
    font-size: 0.8rem;
  }
  
  .post-time {
    font-size: 0.65rem;
  }
  
  .words span {
    font-size: 0.9rem;
  }
  
  .post-date i {
    font-size: 0.7rem;
  }
  
  .gallery {
    gap: 0.25rem;
    padding: 0 0.5rem;
    max-width: 100%;
  }
  
  /* 手机端更紧凑的布局 */
  .image-grid[data-count="3"],
  .image-grid[data-count="4"],
  .image-grid[data-count="5"],
  .image-grid[data-count="6"] {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(3, 1fr);
  }
  
  .image-grid[data-count="7"],
  .image-grid[data-count="8"],
  .image-grid[data-count="9"] {
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: repeat(4, 1fr);
  }
  
  .image-grid {
    gap: 1px;
  }
  
  .grid-item {
    border-radius: 3px;
    min-height: 45px;
  }
  
  .grid-item img {
    border-radius: 3px;
  }
  
  /* 单图在手机端保持合适大小 */
  .image-grid[data-count="1"] .grid-item {
    min-height: 150px;
  }
}

/* 图片懒加载效果 */
.love_img img[loading="lazy"] {
  opacity: 1;
  transition: opacity 0.3s ease;
}

.love_img img:not([loading="lazy"]) {
  opacity: 1;
}

/* 加载状态优化 */
.loading {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  border-radius: 8px;
  padding: 1rem 2rem;
  margin: 2rem auto;
  max-width: 200px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* 相册卡片动画优化 */
.photo-item {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.photo-item.show {
  opacity: 1;
  transform: translateY(0);
}

/* 紧凑布局优化 */
.gallery {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  max-width: 700px;
  margin: 0 auto;
  padding: 0 0.8rem;
}

/* 图片网格整体优化 */
.image-grid {
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* 单图优化 */
.love_img img {
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* 网格项优化 */
.grid-item {
  transition: all 0.3s ease;
}

.grid-item:hover {
  z-index: 2;
  transform: scale(1.02);
}

/* 图片加载状态 */
.grid-item img {
  transition: opacity 0.3s ease;
}

.grid-item img[loading="lazy"] {
  opacity: 1;
}

.grid-item img:not([loading="lazy"]) {
  opacity: 1;
}

/* 图片点击预览效果 */
.grid-item img,
.love_img img {
  cursor: pointer;
  transition: all 0.3s ease;
}

.grid-item img:hover,
.image-container img:hover {
  transform: scale(1.02);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

