/* ===== 朋友圈页面特有样式 ===== */
.friends-page {
  background: #f5f7fa;
}

/* 广告横幅 */
.friends-ad {
  width: 100%;
  background: linear-gradient(135deg, #1a5fb4 0%, #0f3b73 100%);
  min-height: 30vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  color: #fff;
  position: relative;
  overflow: hidden;
  margin-bottom: 10px;
  border-radius: 12px;
}

.friends-ad::before {
  content: "";
  position: absolute;
  bottom: -50px;
  left: 0;
  width: 100%;
  height: 100px;
  background: rgba(255,255,255,0.05);
  border-radius: 50%;
}

.ad-top-title {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}

.ad-line {
  width: 80px;
  height: 2px;
  background: linear-gradient(90deg, transparent, #fff, transparent);
}

.ad-title-text {
  text-align: center;
}

.ad-title-text h2 {
  font-size: clamp(1.2rem, 4vw, 2rem);
  font-weight: 500;
  margin-bottom: 4px;
}

.ad-title-text p {
  font-size: clamp(0.8rem, 2vw, 1rem);
  letter-spacing: 2px;
  opacity: 0.9;
}

.ad-main-title {
  font-size: clamp(2.5rem, 10vw, 5rem);
  font-weight: bold;
  text-shadow: 0 4px 8px rgba(0,0,0,0.2);
  margin-bottom: 30px;
}

.ad-contact {
  font-size: clamp(1rem, 3vw, 1.5rem);
  opacity: 0.9;
}

/* 朋友圈头部统计条 */
.friends-stats-bar {
  background: #fff;
  padding: 12px 16px;
  border-radius: 12px;
  margin: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
  color: #333;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.friends-stats-bar .left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.friends-stats-bar .left i {
  font-size: 18px;
  color: #1677FF;
}

.friends-stats-bar .left span {
  font-weight: 500;
  color: #333;
}

.friends-stats-bar .right {
  color: #1677FF;
  font-weight: 600;
  background: #f0f7ff;
  padding: 4px 12px;
  border-radius: 30px;
  font-size: 14px;
  line-height: 1.5;
  white-space: nowrap;
}

.friends-stats-bar .right span {
  color: #1677FF;
  font-weight: 600;
}

/* ===== 筛选栏：五个按钮在同一行，等宽 ===== */
.filter-bar {
  background: #fff;
  margin: 0 10px 10px 10px;
  padding: 12px;
  border-radius: 12px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
  border: 1px solid #f0f0f0;
}

.filter-category {
  display: flex;
  gap: 8px;
  flex-wrap: nowrap;
  justify-content: space-between;
}

.filter-category .category-btn {
  flex: 1;
  min-width: 0;
  padding: 8px 0;
  background: #f5f5f5;
  border: none;
  border-radius: 20px;
  font-size: 13px;
  color: #666;
  cursor: pointer;
  transition: background 0.2s;
  text-align: center;
  white-space: nowrap;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

.filter-category .category-btn:hover {
  background: #e8e8e8;
}

.filter-category .category-btn:focus,
.filter-category .category-btn:active {
  outline: none;
  box-shadow: none;
}

.filter-category .category-btn.active {
  background: #1677FF;
  color: #fff;
}

.filter-category .category-btn.active:focus,
.filter-category .category-btn.active:active {
  background: #1677FF;
  color: #fff;
}

/* 地区筛选行 */
.filter-region {
  display: flex;
  gap: 8px;
  margin-bottom: 12px;
}

.filter-region select {
  flex: 1;
  padding: 8px 6px;
  border: 1px solid #D0E7FF;
  border-radius: 6px;
  font-size: 14px;
  background: #fff;
  color: #333;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.filter-region select:focus {
  border-color: #d4af37 !important;
  box-shadow: 0 0 0 2px rgba(212, 175, 55, 0.2) !important;
}

/* ===== 朋友圈卡片样式 ===== */
.post-item {
  background: #fff;
  border-radius: 10px;
  padding: 12px;
  margin: 0; /* 卡片之间紧密拼接 */
  position: relative;
  box-shadow: 0 2px 8px rgba(0,0,0,0.03);
}

/* 内部金色边框（伪元素绘制） */
.post-item::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  right: 3px;
  bottom: 3px;
  border: 2px solid #d4af37;
  border-radius: 8px;
  pointer-events: none;
  box-sizing: border-box;
}

/* 头部：左侧用户信息，右侧分类标签区域 */
.post-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 10px;
}

.post-user {
  display: flex;
  align-items: center;
  cursor: pointer;
  flex: 1;
}

.post-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #D0E7FF;
  margin-right: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: bold;
  background-size: cover;
}

.post-name {
  font-size: 16px;
  font-weight: bold;
  margin-bottom: 4px;
}

.post-area {
  font-size: 13px;
  color: #666;
}

/* 右侧标签容器（分类 + 平台客服） */
.post-tags {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
}

/* 分类标签 - 灰色圆角框 */
.post-category {
  font-size: 12px;
  background: #f0f0f0;
  color: #666;
  padding: 4px 10px;
  border-radius: 20px;
  white-space: nowrap;
}

/* 平台客服标签 - 暗金色 */
.top-mark {
  background: #d4af37;
  color: #000;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 12px;
  white-space: nowrap;
}

.post-content {
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 10px;
  color: #666;
}

/* 联系方式 */
.post-contact {
  font-size: 14px;
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 2px;
  flex-wrap: wrap;
}

.contact-label {
  color: #000;
  white-space: nowrap;
}

.contact-number {
  color: #1677FF;
  cursor: pointer;
  text-decoration: underline;
  white-space: nowrap;
}

.post-images {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}

.post-img {
  width: 100px;
  height: 100px;
  border-radius: 8px;
  background: #f0f0f0;
  background-size: cover;
  background-position: center;
  cursor: pointer;
  object-fit: cover;
  display: block;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

/* 底部布局：时间左，点赞右 */
.post-footer {
  display: flex !important;
  justify-content: space-between !important;
  align-items: center;
  margin-top: 8px;
  font-size: 12px;
}

.post-time {
  color: #999;
  white-space: nowrap;
  order: 0;
}

.post-like {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
  border-radius: 16px;
  background: #f5f5f5;
  cursor: pointer;
  user-select: none;
  transition: background 0.2s;
  order: 1;
  outline: none;
  -webkit-tap-highlight-color: transparent;
}

.post-like:hover {
  background: #e8e8e8;
}

.like-icon {
  font-size: 18px;
  color: #999;
  transition: color 0.2s;
}

.like-icon.fa-heart {
  color: #ff4444;
}

.like-count {
  font-size: 14px;
  color: #666;
  min-width: 20px;
  text-align: center;
}

/* 广告轮播样式（移除了 transition，实现无动画切换） */
.friends-ad .carousel-container {
  width: 100%;
  height: 100%;
  min-height: 30vh;
  position: relative;
}

.friends-ad .carousel-slide {
  width: 100%;
  height: 100%;
  min-height: 30vh;
  background-size: cover;
  background-position: center;
  /* 去除过渡动画，实现直接切换 */
  transition: none;
}

.friends-ad .carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  background: rgba(0,0,0,0.4);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 20px;
  z-index: 10;
  transition: background 0.2s;
}

.friends-ad .carousel-arrow:hover {
  background: rgba(0,0,0,0.7);
}

.friends-ad .carousel-arrow.left {
  left: 10px;
}

.friends-ad .carousel-arrow.right {
  right: 10px;
}

.friends-ad .carousel-dots {
  position: absolute;
  bottom: 15px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
  z-index: 10;
}

.friends-ad .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255,255,255,0.5);
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
}

.friends-ad .dot.active {
  background: #d4af37;
  transform: scale(1.2);
}

.friends-ad .dot:hover {
  background: #fff;
}

/* 全局输入框聚焦暗金色边框 */
input:focus,
select:focus,
textarea:focus {
    border-color: #d4af37 !important;
    box-shadow: 0 0 0 2px rgba(212, 175, 55, 0.2) !important;
    outline: none;
}

/* 移除按钮点击高亮，但不影响分类按钮的选中样式 */
button,
.search-box button,
.post-like,
.nav a,
.footer-links .links a {
    outline: none !important;
    -webkit-tap-highlight-color: transparent !important;
    -webkit-tap-highlight-color: rgba(0,0,0,0) !important;
}

button:focus,
button:active,
.search-box button:focus,
.search-box button:active,
.post-like:focus,
.post-like:active,
.nav a:focus,
.nav a:active,
.footer-links .links a:focus,
.footer-links .links a:active {
    outline: none !important;
    box-shadow: none !important;
    background: inherit !important;
}

/* 分类按钮单独处理，确保选中状态不受影响 */
.category-btn {
    outline: none !important;
    -webkit-tap-highlight-color: transparent !important;
    -webkit-tap-highlight-color: rgba(0,0,0,0) !important;
}
.category-btn:focus,
.category-btn:active {
    outline: none !important;
    box-shadow: none !important;
}
.category-btn.active {
    background: #1677FF;
    color: #fff;
}
.category-btn.active:focus,
.category-btn.active:active {
    background: #1677FF;
    color: #fff;
}
.category-btn:not(.active):focus,
.category-btn:not(.active):active {
    background: #f5f5f5;
    color: #666;
}

/* 底部协议链接点击时保持蓝色文字 */
.footer-links .links a:focus,
.footer-links .links a:active {
    color: #1677FF !important;
}