/* ==============================================
   撑伞人 — 半暖时光（朋友圈广场）
   5Tab / 智能分类 / 差异化编辑器 / 全国地区
   ============================================== */

.hw-page { padding-top: 64px; background: var(--bg); min-height: 100vh; }

/* ===== 分类 Tab 栏 ===== */
.hw-tabs-wrap {
  position: sticky; top: 64px; z-index: 50;
  background: rgba(255,255,255,0.80); backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(57,100,150,0.05);
  padding: 0 24px; overflow-x: auto; -webkit-overflow-scrolling: touch;
}
.hw-tabs {
  display: flex; gap: 0; max-width: 1100px; margin: 0 auto;
}
.hw-tab {
  flex-shrink: 0; padding: 14px 20px; font-size: 14px; font-weight: 500;
  color: var(--gray); cursor: pointer; position: relative;
  transition: color 240ms; border-bottom: 2px solid transparent;
  letter-spacing: 0.5px;
}
.hw-tab::after {
  content: ''; position: absolute; bottom: 0; left: 50%;
  width: 0; height: 2px; border-radius: 1px;
  transform: translateX(-50%); transition: width 320ms var(--ease);
}
.hw-tab:hover { color: var(--charcoal); }
.hw-tab.active { color: var(--charcoal); font-weight: 600; }
.hw-tab.active::after { width: 70%; }

/* Tab 主题色下划线 */
.hw-tab[data-cat="all"]::after      { background: #6297C9; }
.hw-tab[data-cat="daily"]::after    { background: #d4a574; }
.hw-tab[data-cat="playdate"]::after { background: #E69340; }
.hw-tab[data-cat="neighbor"]::after { background: #6297C9; }
.hw-tab[data-cat="skill"]::after    { background: #284B78; }

/* 分类标签小圆点 */
.hw-tab .dot {
  display: inline-block; width: 5px; height: 5px; border-radius: 50%;
  margin-right: 6px; vertical-align: middle; opacity: 0.5;
}
.hw-tab.active .dot { opacity: 1; }
.dot-daily    { background: #d4a574; }
.dot-playdate { background: #E69340; }
.dot-neighbor { background: #6297C9; }
.dot-skill    { background: #284B78; }

/* ===== 筛选栏 ===== */
.hw-filters {
  display: flex; gap: 10px; flex-wrap: wrap; align-items: center;
  padding: 16px 24px; max-width: 1100px; margin: 0 auto;
}
.hw-filters select, .hw-filters input {
  padding: 8px 14px; border-radius: 8px; font-size: 13px; outline: none;
  border: 1px solid rgba(57,100,150,0.10);
  background: rgba(255,255,255,0.55); font-family: inherit; cursor: pointer;
}
.hw-filters select:focus, .hw-filters input:focus { border-color: var(--blue); }
.hw-filters .toggle-label {
  display: flex; align-items: center; gap: 6px; font-size: 12px;
  color: var(--gray); cursor: pointer;
}
.hw-filters .toggle-label input { accent-color: var(--blue); }

/* ===== 帖子信息流 ===== */
.hw-feed { max-width: 1100px; margin: 0 auto; padding: 0 24px 60px; }
.hw-feed .empty-state {
  text-align: center; padding: 80px 24px; color: var(--gray);
}
.hw-feed .empty-state h3 { font-size: 18px; color: var(--charcoal); margin-bottom: 8px; }
.hw-feed .empty-state p { font-size: 13px; margin-bottom: 20px; }
.hw-feed .empty-state .btn { display: inline-block; }

/* ===== 帖子卡片 ===== */
.hw-card {
  background: rgba(255,255,255,0.55); backdrop-filter: blur(6px);
  border: 1px solid rgba(57,100,150,0.04); border-radius: 16px;
  padding: 20px 22px; margin-bottom: 16px;
  transition: transform 320ms var(--ease), box-shadow 320ms var(--ease);
  position: relative; overflow: hidden;
}
.hw-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 24px rgba(57,100,150,0.06);
}
/* 分类标签（左上角） */
.hw-card .cat-badge {
  display: inline-block; padding: 2px 10px; border-radius: 8px;
  font-size: 10px; font-weight: 600; letter-spacing: 0.5px;
  margin-bottom: 10px;
}
.badge-daily    { background: rgba(212,165,116,0.10); color: #b8860b; }
.badge-playdate { background: rgba(230,147,64,0.10); color: #d48030; }
.badge-neighbor { background: rgba(98,151,201,0.10); color: #4a83b5; }
.badge-skill    { background: rgba(40,75,120,0.10); color: #284B78; }

.hw-card-header { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.hw-card-avatar {
  width: 34px; height: 34px; border-radius: 50%;
  background: rgba(57,100,150,0.08); display: flex; align-items: center;
  justify-content: center; font-size: 13px; color: var(--blue); font-weight: 600;
  flex-shrink: 0;
}
.hw-card-user { font-size: 13px; font-weight: 600; color: var(--charcoal); }
.hw-card-meta { font-size: 11px; color: var(--gray); margin-left: auto; display: flex; gap: 8px; }
.hw-card-loc { font-size: 11px; color: var(--blue-light); }

.hw-card-body { margin-bottom: 12px; }
.hw-card-body .title { font-size: 15px; font-weight: 600; margin-bottom: 6px; color: var(--charcoal); }
.hw-card-body .text { font-size: 13px; color: var(--gray); line-height: 1.7; }
.hw-card-body .images {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px;
  margin-top: 10px; max-width: 400px;
}
.hw-card-body .images img {
  width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 10px;
  background: rgba(0,0,0,0.03);
}

/* 活动/互助信息条 */
.hw-card-info {
  display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 10px;
  padding: 10px 14px; border-radius: 10px;
  background: rgba(57,100,150,0.03); font-size: 12px;
}
.hw-card-info span { color: var(--gray); }
.hw-card-info .highlight { color: var(--amber); font-weight: 600; }

.hw-card-actions {
  display: flex; gap: 16px; padding-top: 10px;
  border-top: 1px solid rgba(57,100,150,0.04);
  font-size: 12px; color: var(--gray);
}
.hw-card-actions span { display: flex; align-items: center; gap: 4px; cursor: pointer; }
.hw-card-actions span:hover { color: var(--blue); }

/* 分类专属操作按钮 */
.hw-card-extra { margin-top: 8px; display: flex; gap: 8px; flex-wrap: wrap; }
.hw-card-extra .btn-sm {
  padding: 6px 14px; border-radius: 16px; border: 1px solid rgba(57,100,150,0.12);
  font-size: 11px; cursor: pointer; background: transparent; color: var(--blue);
  transition: all 200ms; font-family: inherit;
}
.hw-card-extra .btn-sm:hover { background: rgba(57,100,150,0.06); border-color: var(--blue); }

/* ===== 发帖按钮（右下悬浮） ===== */
.hw-post-fab {
  position: fixed; bottom: 28px; right: 28px; z-index: 200;
  width: 56px; height: 56px; border-radius: 50%;
  background: linear-gradient(135deg, var(--amber), #F0A050);
  color: #fff; font-size: 24px; border: none; cursor: pointer;
  box-shadow: 0 6px 24px rgba(230,147,64,0.30);
  display: flex; align-items: center; justify-content: center;
  transition: all 320ms;
}
.hw-post-fab:hover { transform: scale(1.08); box-shadow: 0 8px 32px rgba(230,147,64,0.40); }

/* ===== 发帖弹窗 ===== */
.hw-modal-overlay {
  position: fixed; inset: 0; z-index: 300;
  background: rgba(13,17,23,0.40); backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity 320ms;
}
.hw-modal-overlay.open { opacity: 1; pointer-events: auto; }
.hw-modal {
  width: 92%; max-width: 580px; max-height: 88vh; overflow-y: auto;
  padding: 28px; border-radius: 20px;
  background: rgba(255,255,255,0.90); backdrop-filter: blur(16px);
  border: 1px solid rgba(57,100,150,0.06);
  box-shadow: 0 20px 60px rgba(0,0,0,0.12);
  animation: modalIn 320ms var(--ease);
}
@keyframes modalIn { from { opacity:0; transform:translateY(16px) } to { opacity:1; transform:translateY(0) } }

.hw-modal .smart-hint {
  font-size: 12px; color: var(--blue); margin-bottom: 16px;
  padding: 8px 14px; border-radius: 8px; background: rgba(57,100,150,0.04);
  text-align: center;
}
.hw-modal .cat-select {
  display: flex; gap: 8px; margin-bottom: 16px; flex-wrap: wrap;
}
.hw-modal .cat-option {
  padding: 8px 16px; border-radius: 20px; border: 1px solid rgba(57,100,150,0.12);
  font-size: 12px; cursor: pointer; transition: all 200ms; background: transparent;
  color: var(--gray);
}
.hw-modal .cat-option:hover { border-color: var(--blue); color: var(--charcoal); }
.hw-modal .cat-option.selected { background: var(--blue); color: #fff; border-color: var(--blue); }

.hw-modal input[type="text"], .hw-modal textarea {
  width: 100%; padding: 12px 16px; border-radius: 10px; font-size: 14px;
  border: 1px solid rgba(57,100,150,0.10); outline: none; font-family: inherit;
  margin-bottom: 12px; background: rgba(255,255,255,0.60);
}
.hw-modal textarea { min-height: 140px; resize: vertical; }
.hw-modal input:focus, .hw-modal textarea:focus { border-color: var(--blue); }

.hw-modal .field-row {
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 12px;
}
.hw-modal .field-row input, .hw-modal .field-row select {
  padding: 10px 14px; border-radius: 8px; font-size: 13px;
  border: 1px solid rgba(57,100,150,0.10); outline: none; font-family: inherit;
  background: rgba(255,255,255,0.60);
}
.hw-modal .switch-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 8px 0; font-size: 13px; color: var(--charcoal);
}
.hw-modal .notice { font-size: 11px; color: var(--gray); margin-bottom: 12px; padding: 10px 14px; border-radius: 8px; background: rgba(230,147,64,0.05); }

/* ===== 新手引导弹窗 ===== */
.hw-guide-overlay {
  position: fixed; inset: 0; z-index: 350;
  background: rgba(13,17,23,0.50); backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity 320ms;
}
.hw-guide-overlay.open { opacity: 1; pointer-events: auto; }
.hw-guide {
  width: 90%; max-width: 440px; padding: 32px 28px; border-radius: 20px;
  background: rgba(255,255,255,0.92); backdrop-filter: blur(16px);
  border: 1px solid rgba(57,100,150,0.06); text-align: center;
  animation: modalIn 320ms var(--ease);
}
.hw-guide h3 { font-size: 18px; font-weight: 700; margin-bottom: 20px; color: var(--charcoal); }
.hw-guide .guide-item {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px; border-radius: 10px; margin-bottom: 8px;
  background: rgba(57,100,150,0.02); text-align: left;
}
.hw-guide .guide-emoji { font-size: 24px; flex-shrink: 0; }
.hw-guide .guide-text { font-size: 13px; color: var(--charcoal); line-height: 1.6; }
.hw-guide .guide-text strong { color: var(--blue); }

/* ===== 响应式 ===== */
@media (max-width: 768px) {
  .hw-tabs-wrap { padding: 0 12px; }
  .hw-tab { padding: 12px 14px; font-size: 13px; }
  .hw-filters { padding: 12px 16px; flex-direction: column; }
  .hw-feed { padding: 0 16px 80px; }
  .hw-post-fab { bottom: 20px; right: 20px; width: 48px; height: 48px; font-size: 20px; }
  .hw-modal { padding: 20px; }
  .hw-modal .field-row { grid-template-columns: 1fr; }
  .hw-card-body .images { grid-template-columns: repeat(2, 1fr); }
}
