@import url('./tokens.css');

/* 全局重置与 Film Noir 排版规范 */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

main {
  flex: 1 0 auto;
  width: 100%;
  display: flex;
  flex-direction: column;
}

/* 经典黑色电影排版：标题全系衬线斜体 */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

::selection {
  background: var(--text-primary);
  color: var(--bg-primary);
}

/* 顶栏导航 (黑色电影硬朗风格) */
.navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 10, 10, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-noir);
  padding: 1rem 2.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  text-decoration: none;
  color: var(--text-primary);
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.4rem;
  font-weight: 800;
  letter-spacing: 0.05em;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

.nav-links a {
  text-decoration: none;
  color: var(--text-muted);
  font-family: var(--font-serif);
  font-size: 0.95rem;
  letter-spacing: 0.03em;
  transition: color 0.3s ease;
  position: relative;
  padding-bottom: 0.25rem;
}

.nav-links a:hover,
.nav-links a.active,
.nav-dropdown:hover > a,
.nav-dropdown.is-open > a {
  color: var(--text-primary);
}

.nav-links a.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--accent-noir-crimson);
}

/* 用户中心下拉菜单系统 (与 nav-links 风格完全一致) */
.nav-dropdown {
  position: relative;
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: #0f0f12;
  border: 1px solid var(--border-noir);
  border-top: 2px solid var(--accent-noir-crimson);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.95);
  list-style: none;
  padding: 0.4rem 0;
  margin: 0;
  margin-top: 4px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(4px);
  transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s ease;
  transition-delay: 0.15s; /* 移出时提供 150ms 防抖/防失焦缓冲 */
  z-index: 1000;
  pointer-events: none;
}

/* 隐形悬停桥接层：无缝覆盖触发词与下拉面板之间的所有空隙，鼠标自然下滑即可接触二级菜单 */
.dropdown-menu::before {
  content: '';
  position: absolute;
  top: -18px;
  left: -12px;
  right: -12px;
  height: 22px;
  background: transparent;
}

.nav-dropdown:hover .dropdown-menu,
.nav-dropdown:focus-within .dropdown-menu,
.nav-dropdown.is-open .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
  transition-delay: 0s; /* 移入时立即可见，无任何延迟 */
}

.dropdown-header-box {
  padding: 0.6rem 1rem 0.65rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 0.35rem;
}

.dropdown-vip-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.78rem !important;
  font-family: var(--font-sans) !important;
  color: var(--accent-noir-crimson) !important;
  background: rgba(225, 29, 72, 0.12);
  border: 1px solid rgba(225, 29, 72, 0.35);
  padding: 0.25rem 0.65rem !important;
  letter-spacing: 0.04em !important;
  font-weight: 700;
  text-transform: uppercase;
}

.dropdown-vip-tag::after {
  display: none !important;
}

.dropdown-quota-tag {
  font-size: 0.75rem;
  font-family: var(--font-sans);
  color: var(--text-muted);
  line-height: 1.5;
}

.dropdown-quota-tag strong {
  color: var(--text-primary);
}

.dropdown-free-tag {
  font-size: 0.75rem;
  font-family: var(--font-sans);
  color: var(--text-faint);
  background: #18181c;
  padding: 0.15rem 0.5rem;
  border: 1px solid var(--border-noir-light);
}

.dropdown-item {
  display: flex !important;
  align-items: center;
  gap: 0.65rem;
  padding: 0.65rem 1.15rem !important;
  color: var(--text-secondary) !important;
  font-family: var(--font-serif) !important;
  font-size: 0.9rem !important;
  text-decoration: none !important;
  transition: all 0.2s ease !important;
  letter-spacing: 0.02em !important;
}

.dropdown-item::after {
  display: none !important;
}

.dropdown-item:hover {
  background: rgba(255, 255, 255, 0.06);
  color: #ffffff !important;
  padding-left: 1.35rem !important;
}

.dropdown-item.active {
  color: #ffffff !important;
  background: rgba(225, 29, 72, 0.08);
}

.dropdown-divider {
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  margin: 0.35rem 0;
}

.dropdown-logout {
  color: #f87171 !important;
}

.dropdown-logout:hover {
  background: rgba(239, 68, 68, 0.12) !important;
  color: #fca5a5 !important;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* 额度状态标签 (Film Noir 工业矩形档案框) */
.quota-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: #111111;
  border: 1px solid var(--border-noir);
  padding: 0.35rem 0.85rem;
  border-radius: 0;
  font-size: 0.8rem;
  color: var(--text-muted);
  letter-spacing: 0.02em;
}

.quota-badge strong {
  color: var(--text-primary);
  font-weight: 700;
}

/* 按钮系统 (Film Noir Component Recipe: 直角、光束扫射、触觉反馈) */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.6rem 1.4rem;
  border-radius: 0;
  font-family: var(--font-serif);
  font-size: 0.88rem;
  letter-spacing: 0.05em;
  text-decoration: none;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  border: 1px solid transparent;
}

/* 光束扫射层 (Light Beam Sweep) */
.btn::after {
  content: '';
  position: absolute;
  top: 0;
  left: -180%;
  width: 50%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transform: skewX(-25deg);
  transition: left 0.7s ease;
  pointer-events: none;
}

.btn:hover::after {
  left: 200%;
}

.btn:active {
  transform: scale(0.98);
}

.btn:focus-visible {
  outline: 2px solid var(--text-muted);
  outline-offset: 2px;
}

/* 主操作按钮：经典黑底白面高对比度 */
.btn-primary,
.btn-amber {
  background: #f5f5f5;
  color: #0a0a0a;
  border-color: #f5f5f5;
  font-weight: 700;
}

.btn-primary:hover,
.btn-amber:hover {
  background: #e0e0e0;
  border-color: #e0e0e0;
  color: #000000;
}

/* 次级/轮廓按钮 */
.btn-glass,
.btn-secondary {
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-primary);
  border: 1px solid var(--border-noir-light);
}

.btn-glass:hover,
.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: #737373;
  color: #ffffff;
}

/* 警示与猩红血线按钮 */
.btn-danger {
  background: var(--accent-noir-crimson);
  color: #ffffff;
  border-color: var(--accent-noir-crimson);
  font-weight: 600;
}

.btn-danger:hover {
  background: var(--accent-noir-crimson-hover);
  border-color: var(--accent-noir-crimson-hover);
}

/* 全幅大图 Hero 区域 (Chiaroscuro 戏剧明暗与百叶窗式投影) */
.hero-bleed {
  position: relative;
  width: 100%;
  min-height: 520px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  background: #000000;
}

/* 首页大横幅自适应视口全景填充 (消除上下黑边与断层) */
.hero-home-banner {
  flex: 1 1 auto;
  min-height: calc(100vh - 72px);
  min-height: calc(100svh - 72px);
  width: 100%;
}

.hero-bg-media,
.hero-bleed img,
.hero-bleed video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.hero-bleed img,
.hero-bg-image {
  z-index: 1;
  filter: grayscale(85%) contrast(125%) brightness(80%);
  animation: noirKenBurns 28s ease-in-out infinite alternate;
}

/* 背景视频：静音循环，初始透明度为 0，缓冲就绪后平滑淡入 */
.hero-bg-video {
  z-index: 1;
  filter: grayscale(85%) contrast(125%) brightness(80%);
  opacity: 0;
  transition: opacity 1s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
}

.hero-bg-video.is-playing {
  opacity: 1;
}

@keyframes noirKenBurns {
  0% { transform: scale(1.0) translate(0, 0); }
  50% { transform: scale(1.05) translate(-1%, -0.5%); }
  100% { transform: scale(1.02) translate(1%, 0.5%); }
}

.hero-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(10, 10, 10, 0.25) 0%,
    rgba(10, 10, 10, 0.65) 50%,
    #0a0a0a 100%
  );
  z-index: 2;
  pointer-events: none;
}

/* 百叶窗光影微弱斜纹效果 */
.hero-scrim::after {
  content: '';
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    -45deg,
    transparent,
    transparent 12px,
    rgba(0, 0, 0, 0.12) 12px,
    rgba(0, 0, 0, 0.12) 24px
  );
  opacity: 0.6;
}

/* 首页全宽主图前描述性文字 (SEO H1 主标题) */
.hero-lead-title {
  position: relative;
  z-index: 3;
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 2rem;
  box-sizing: border-box;
  text-align: left;
}

.hero-lead-badge {
  position: relative;
  display: block;
  width: 100%;
  box-sizing: border-box;
  margin: 0 auto 0 0;
  text-align: left;
  text-indent: 0;
  font-family: var(--font-serif);
  font-style: normal;
  font-size: clamp(0.96rem, 1.55vw, 1.25rem);
  font-weight: 500;
  letter-spacing: 0.025em;
  color: #f8f8f8;
  line-height: 1.75;
  white-space: pre-wrap;
  word-break: break-word;
  overflow-wrap: break-word;
  padding: clamp(0.95rem, 2vw, 1.35rem) clamp(1.15rem, 2.5vw, 1.85rem);
  
  /* 极致通透的暗调磨砂玻璃 (Frosted Glassmorphism) */
  background: rgba(10, 10, 14, 0.28);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-left: 3.5px solid var(--accent-noir-crimson);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5),
              inset 0 1px 0 rgba(255, 255, 255, 0.12),
              inset 0 -1px 0 rgba(0, 0, 0, 0.2);
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.95), 0 1px 2px rgba(0, 0, 0, 0.85);
  transition: background 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.hero-lead-badge:hover {
  background: rgba(14, 14, 18, 0.38);
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.6),
              inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

.hero-content {
  position: relative;
  z-index: 3;
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 1.5rem 2rem 3.5rem;
}

.hero-tag {
  display: inline-block;
  padding: 0.3rem 0.85rem;
  border-radius: 0;
  background: #171717;
  color: var(--text-primary);
  border: 1px solid var(--border-noir-light);
  border-left: 3px solid var(--accent-noir-crimson);
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 1.25rem;
}

.hero-title {
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: 1.25rem;
  max-width: 880px;
  color: #f5f5f5;
  text-shadow: 0 4px 20px rgba(0, 0, 0, 0.9);
}

.hero-desc {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 680px;
  margin-bottom: 2.25rem;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  gap: 1rem;
  align-items: center;
  flex-wrap: wrap;
}

/* 主内容容器 */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 3rem 1.5rem;
}

/* 分类筛选条：上下两行纯净架构 (Film Noir 矩形档案索引设计) */
.category-filter {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  margin-bottom: 2.5rem;
  background: #111111;
  border: 1px solid var(--border-noir);
  border-radius: 0;
  padding: 1.25rem 1.5rem;
}

.category-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  overflow-x: auto;
  padding-bottom: 0.15rem;
}

.category-row-label {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--text-faint);
  min-width: 72px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  text-transform: uppercase;
}

.category-row-primary .category-row-label {
  color: var(--text-primary);
}

.category-row-secondary .category-row-label {
  color: var(--text-muted);
}

.category-pills {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

/* 一级分类胶囊 (Primary Pill) */
.cat-pill {
  padding: 0.45rem 1.15rem;
  border-radius: 0;
  background: #171717;
  border: 1px solid var(--border-noir);
  color: var(--text-muted);
  text-decoration: none;
  font-family: var(--font-serif);
  font-size: 0.88rem;
  letter-spacing: 0.02em;
  white-space: nowrap;
  transition: all 0.25s ease;
}

.cat-pill:hover {
  background: #222222;
  color: var(--text-primary);
  border-color: #444444;
}

.cat-pill.active {
  background: #f5f5f5;
  color: #0a0a0a;
  border-color: #f5f5f5;
  font-weight: 700;
}

/* 二级分类胶囊 (Secondary / Sub Pill) */
.cat-sub-pill {
  padding: 0.32rem 0.9rem;
  border-radius: 0;
  background: #0d0d0d;
  border: 1px dashed var(--border-noir-light);
  color: var(--text-faint);
  text-decoration: none;
  font-size: 0.82rem;
  white-space: nowrap;
  transition: all 0.25s ease;
}

.cat-sub-pill:hover {
  background: #1a1a1a;
  color: var(--text-primary);
  border-color: #555555;
  border-style: solid;
}

.cat-sub-pill.active {
  background: #1f1f1f;
  color: #f5f5f5;
  border-color: var(--accent-noir-crimson);
  border-style: solid;
  font-weight: 600;
}

/* ==========================================================================
   左右两栏分栏布局系统 (左侧 20% / 右侧 80%)
   ========================================================================== */
.container-split-layout {
  width: 100%;
  max-width: 1800px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 5rem 1.5rem;
}

@media (max-width: 767px) {
  .container-split-layout {
    padding: 1.5rem 1rem 3.5rem 1rem;
  }
}

.split-layout {
  display: grid;
  grid-template-columns: 20% calc(80% - 2rem); /* 精确 20% : 80% 比例分栏 */
  gap: 2rem;
  align-items: start;
  width: 100%;
}

/* 移动设备 (手机) 单列流 (<768px) */
@media (max-width: 767px) {
  .split-layout {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
  }
}

/* 左侧栏 (20%)：支持黏性悬浮、紧凑圆角卡片面板 */
.layout-sidebar {
  width: 100%;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
  position: sticky;
  top: 5.5rem;
  max-height: calc(100vh - 6.5rem);
  overflow-y: auto;
  scrollbar-width: thin;
}

@media (max-width: 767px) {
  .layout-sidebar {
    position: static;
    max-height: none;
    overflow-y: visible;
  }
}

/* 左侧侧边栏标题与描述 */
.sidebar-header-box {
  background: rgba(18, 18, 22, 0.75);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 1.4rem 1.25rem;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.35);
}

.sidebar-title {
  font-size: 1.45rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0 0 0.5rem 0;
  color: #ffffff;
  line-height: 1.25;
}

.sidebar-desc {
  font-size: 0.85rem;
  color: var(--text-muted, #8e8e99);
  margin: 0;
  line-height: 1.6;
}

/* 调整放入左侧侧栏后的 .category-filter */
.layout-sidebar .category-filter {
  margin-bottom: 0;
  padding: 1.2rem 1.15rem;
  border-radius: 14px;
  background: rgba(18, 18, 22, 0.75);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.35);
  gap: 1.1rem;
}

.layout-sidebar .category-row {
  flex-wrap: wrap;
  overflow-x: visible;
  gap: 0.4rem;
  padding-bottom: 0;
}

.layout-sidebar .category-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  width: 100%;
}

.layout-sidebar .cat-pill,
.layout-sidebar .cat-sub-pill {
  font-size: 0.75rem;
  padding: 0.3rem 0.65rem;
  border-radius: 8px;
}

/* 调整放入左侧侧栏后的 .waterfall-filter-toolbar */
.layout-sidebar .waterfall-filter-toolbar {
  flex-direction: column;
  align-items: stretch;
  gap: 0.85rem;
  margin-bottom: 0;
  padding: 1.2rem 1.15rem;
  border-radius: 14px;
  background: rgba(18, 18, 22, 0.75);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.35);
}

.layout-sidebar .orientation-filters {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.45rem;
  width: 100%;
}

.layout-sidebar .orientation-pill {
  justify-content: center;
  width: 100%;
  padding: 0.4rem 0.45rem;
  font-size: 0.74rem;
  border-radius: 8px;
}

.layout-sidebar .waterfall-stats-info {
  text-align: center;
  font-size: 0.76rem;
  padding-top: 0.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

/* 右侧内容区 (80%) */
.layout-content {
  width: 100%;
  min-width: 0;
}

/* ==========================================================================
   文章专栏网格系统 (PC/平板 100% 宽度自适应，每行 4 个；手机单列)
   ========================================================================== */
.article-cards-grid {
  display: grid;
  width: 100%;
  grid-template-columns: repeat(4, 1fr); /* PC 和平板 100% 宽度自适应，每行 4 个 */
  gap: 1.25rem;
}

/* 移动设备 (手机) 单列 (<768px) */
@media (max-width: 767px) {
  .article-cards-grid {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }
}

/* 文章封面卡片设计 */
.article-grid-card {
  background: var(--bg-card, #131316);
  border: 1px solid var(--border-noir, rgba(255, 255, 255, 0.08));
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow 0.3s ease,
              border-color 0.3s ease;
  position: relative;
  text-decoration: none;
}

.article-grid-card::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 2rem;
  height: 2px;
  background: var(--accent-noir-crimson, #c41e3a);
  transition: width 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 5;
}

.article-grid-card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow: 0 12px 28px -4px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(196, 30, 58, 0.35);
}

.article-grid-card:hover::before {
  width: 100%;
}

.article-card-cover-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: #0d0d10;
  display: block;
}

.article-card-cover-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.55s cubic-bezier(0.16, 1, 0.3, 1);
}

.article-grid-card:hover .article-card-cover-img {
  transform: scale(1.04);
}

.article-type-pill {
  position: absolute;
  top: 8px;
  right: 8px;
  background: rgba(10, 10, 12, 0.82);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.15);
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 600;
  color: #ececee;
  z-index: 3;
}

.article-card-content {
  padding: 0.95rem 0.85rem 1.15rem 0.85rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.article-card-title {
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.4;
  margin: 0 0 0.45rem 0;
  color: #f2f2f5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: color 0.2s ease;
}

.article-grid-card:hover .article-card-title {
  color: #ffffff;
}

.article-card-title a {
  color: inherit;
  text-decoration: none;
}

.article-card-summary {
  font-size: 0.78rem;
  line-height: 1.55;
  color: #8a8a96;
  margin: 0 0 0.85rem 0;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
}

.article-card-meta-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 0.65rem;
  font-size: 0.72rem;
  color: #70707a;
}

.article-card-views {
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.article-read-btn {
  font-size: 0.72rem;
  color: #ececee;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  text-decoration: none;
  transition: color 0.2s ease, transform 0.2s ease;
}

.article-grid-card:hover .article-read-btn {
  color: #ff334b;
  transform: translateX(2px);
}

/* ==========================================================================
   Pinterest 瀑布流自适应画廊 (Pinterest-Style Adaptive Waterfall Gallery)
   原生完美自适应横屏 (16:9 / 4:3)、竖屏 (9:16 / 3:4) 照片与全动态视频
   ========================================================================== */

/* 1. 画幅与媒体快捷工具条 */
.waterfall-filter-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  padding: 0.75rem 1rem;
  background: rgba(18, 18, 22, 0.6);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  margin-bottom: 2rem;
}

.orientation-filters {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.orientation-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #a0a0aa;
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

.orientation-pill:hover {
  background: rgba(255, 255, 255, 0.06);
  color: #f0f0f5;
  border-color: rgba(255, 255, 255, 0.2);
}

.orientation-pill.active {
  background: #f5f5f7;
  color: #0d0d10;
  border-color: #f5f5f7;
  font-weight: 600;
  box-shadow: 0 2px 10px rgba(255, 255, 255, 0.2);
}

.waterfall-stats-info {
  font-size: 0.82rem;
  color: var(--text-muted, #7e7e8a);
}

.waterfall-stats-info strong {
  color: #f0f0f5;
}

/* 2. 瀑布流容器架构 (纯 CSS 多列 + JS 动态排布双引擎) */
.pinterest-waterfall,
.gallery-grid {
  width: 100%;
  margin-top: 0;
  margin-bottom: 3.5rem;
}

/* 初始降级：纯 CSS 原生多列瀑布流 */
.pinterest-waterfall:not(.has-columns),
.gallery-grid:not(.has-columns) {
  column-count: 3;
  column-gap: 1.25rem;
}

@media (min-width: 1400px) {
  .pinterest-waterfall:not(.has-columns),
  .gallery-grid:not(.has-columns) {
    column-count: 4;
    column-gap: 1.25rem;
  }
}

@media (min-width: 768px) and (max-width: 1099px) {
  .pinterest-waterfall:not(.has-columns),
  .gallery-grid:not(.has-columns) {
    column-count: 2;
    column-gap: 1rem;
  }
}

/* 移动设备如果是手机 (<768px) 则单列 */
@media (max-width: 767px) {
  .pinterest-waterfall:not(.has-columns),
  .gallery-grid:not(.has-columns) {
    column-count: 1;
    column-gap: 0;
  }
  .pinterest-waterfall:not(.has-columns) .photo-card,
  .gallery-grid:not(.has-columns) .photo-card {
    margin-bottom: 1.15rem;
  }
}

.pinterest-waterfall:not(.has-columns) .photo-card,
.gallery-grid:not(.has-columns) .photo-card {
  break-inside: avoid;
  margin-bottom: 1.25rem;
  display: inline-block;
  width: 100%;
}

/* JS 最矮列贪心分配激活状态 (Pinterest 经典水平优先流) */
.pinterest-waterfall.has-columns,
.gallery-grid.has-columns {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
}

@media (min-width: 768px) and (max-width: 1099px) {
  .pinterest-waterfall.has-columns,
  .gallery-grid.has-columns {
    gap: 1rem;
  }
}

/* 移动设备如果是手机 (<768px) 则单列流 */
@media (max-width: 767px) {
  .pinterest-waterfall.has-columns,
  .gallery-grid.has-columns {
    gap: 1.15rem;
    flex-direction: column;
  }
}

.waterfall-column {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  min-width: 0;
}

@media (min-width: 768px) and (max-width: 1099px) {
  .waterfall-column {
    gap: 1rem;
  }
}

@media (max-width: 767px) {
  .waterfall-column {
    gap: 1.15rem;
    width: 100%;
  }
}

/* 3. Pinterest 核心卡片容器 */
.photo-card {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  background: var(--bg-card, #131316);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
  transition: transform 0.32s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow 0.32s ease,
              border-color 0.32s ease,
              opacity 0.25s ease;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  width: 100%;
  break-inside: avoid;
}

/* 电影级暗黑血线动效 (Film Noir Signature) */
.photo-card::before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 2.5rem;
  height: 2px;
  background: var(--accent-noir-crimson, #c41e3a);
  transition: width 0.55s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 10;
}

.photo-card:hover {
  transform: translateY(-5px);
  border-color: rgba(255, 255, 255, 0.22);
  box-shadow: 0 16px 36px -6px rgba(0, 0, 0, 0.75), 0 0 0 1px rgba(196, 30, 58, 0.45);
}

.photo-card:hover::before {
  width: 100%;
}

.photo-card.is-filtered-out {
  display: none !important;
}

/* 4. 封面视觉媒体区 (自适应核心) */
.photo-card-media {
  position: relative;
  width: 100%;
  background: #0d0d10;
  overflow: hidden;
  border-radius: 13px 13px 0 0;
}

.image-container,
.video-container {
  position: relative;
  width: 100%;
  line-height: 0;
}

/* 原生自适应：图片与视频完全按原生比例拉伸宽度，高度随比例自动延展 */
.adaptive-media {
  width: 100%;
  height: auto;
  display: block;
  max-height: 850px;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1), filter 0.6s ease;
}

.photo-card:hover .adaptive-media {
  transform: scale(1.035);
}

/* 视频特殊处理 */
.adaptive-video {
  background: #000;
}

/* 视频动态指示徽章 */
.video-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 0.22rem 0.55rem;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  font-size: 0.7rem;
  color: #ffffff;
  font-weight: 600;
  z-index: 4;
  box-shadow: 0 2px 8px rgba(0,0,0,0.4);
}

.video-badge svg {
  color: #ff334b;
}

/* 顶栏浮动标签 (模型 & VIP) */
.media-top-badges {
  position: absolute;
  top: 10px;
  left: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
  z-index: 4;
}

.badge-pill {
  padding: 0.22rem 0.6rem;
  background: rgba(12, 12, 14, 0.78);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 600;
  color: #ececee;
  letter-spacing: 0.02em;
}

.badge-pill.vip-badge {
  background: rgba(196, 30, 58, 0.88);
  color: #ffffff;
  border-color: rgba(255, 120, 120, 0.4);
}

/* 5. Pinterest 悬浮快捷交互层 */
.media-hover-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(10, 10, 12, 0.85) 0%,
    rgba(10, 10, 12, 0.25) 45%,
    transparent 80%
  );
  opacity: 0;
  transition: opacity 0.25s ease;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 0.85rem;
  z-index: 6;
  pointer-events: none;
}

.photo-card:hover .media-hover-overlay {
  opacity: 1;
  pointer-events: auto;
}

.hover-actions-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.btn-hover-action {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0.4rem 0.8rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  border: none;
  text-decoration: none;
}

.btn-copy-prompt {
  background: #ffffff;
  color: #0d0d10;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
}

.btn-copy-prompt:hover {
  background: #f0f0f0;
  transform: translateY(-1px);
}

.btn-copy-prompt.copied {
  background: #10b981;
  color: #ffffff;
}

.btn-view-detail {
  background: rgba(22, 22, 26, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #e2e2e8;
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-view-detail:hover {
  background: rgba(35, 35, 42, 0.95);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.4);
}

/* 6. 卡片信息底栏 (Pinterest 极简信息流) */
.photo-card-body {
  padding: 0.9rem 1rem 1.15rem 1rem;
  background: var(--bg-card, #131316);
  border-top: 1px solid rgba(255, 255, 255, 0.04);
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

@media (max-width: 599px) {
  .photo-card-body {
    padding: 0.65rem 0.75rem 0.85rem 0.75rem;
  }
}

.photo-card-title {
  font-size: 0.95rem;
  font-weight: 600;
  line-height: 1.4;
  color: #f0f0f3;
  margin: 0;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: -0.01em;
  transition: color 0.2s ease;
}

.photo-card:hover .photo-card-title {
  color: #ffffff;
}

.photo-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.75rem;
  color: #82828c;
}

.meta-tag {
  display: inline-block;
  padding: 0.12rem 0.45rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 4px;
  font-size: 0.7rem;
  color: #a8a8b4;
  max-width: 100px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.meta-stats {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.meta-views {
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.meta-separator {
  color: #555560;
}

.meta-date {
  color: #72727d;
}

/* 7. 复制成功全局 Toast 提示 */
.pinterest-toast {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: rgba(18, 18, 22, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: #ffffff;
  padding: 0.75rem 1.5rem;
  border-radius: 999px;
  border: 1px solid rgba(16, 185, 129, 0.4);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6), 0 0 20px rgba(16, 185, 129, 0.2);
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.88rem;
  font-weight: 500;
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease;
}

.pinterest-toast svg {
  color: #10b981;
}

.pinterest-toast.is-active {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

/* 详情页面 */
.detail-layout {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 2.75rem;
  align-items: start;
}

@media (max-width: 900px) {
  .detail-layout {
    grid-template-columns: 1fr;
  }
}

.media-viewer {
  position: relative;
  border-radius: 0;
  overflow: hidden;
  border: 1px solid var(--border-noir);
  background: #0d0d0d;
}

.media-viewer img {
  width: 100%;
  height: auto;
  display: block;
}

.info-panel {
  background: var(--bg-card);
  border: 1px solid var(--border-noir);
  border-radius: 0;
  padding: 2.25rem;
  position: relative;
}

.info-panel::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--border-noir-light);
}

.copy-box {
  background: #0c0c0c;
  border: 1px solid var(--border-noir);
  border-radius: 0;
  padding: 1.25rem;
  margin: 1.25rem 0;
  position: relative;
}

.copy-box pre {
  white-space: pre-wrap;
  word-break: break-all;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.9rem;
  color: #d4d4d4;
  line-height: 1.7;
}

/* 门禁锁定遮罩卡片 (Gating Cards - Film Noir 权限阻绝档案) */
.gating-card {
  background: #111111;
  border: 1px solid var(--border-noir);
  border-top: 2px solid var(--accent-noir-crimson);
  border-radius: 0;
  padding: 2.75rem 2rem;
  text-align: center;
  margin: 1.75rem 0;
}

.gating-card.amber-vip {
  border-top-color: var(--accent-noir-crimson);
  background: #131313;
}

.gating-icon {
  font-size: 1.5rem;
  margin-bottom: 0.85rem;
  font-family: var(--font-serif);
  letter-spacing: 0.1em;
  color: var(--accent-noir-crimson);
}

.gating-title {
  font-size: 1.45rem;
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.6rem;
}

.gating-desc {
  font-size: 0.95rem;
  color: var(--text-muted);
  max-width: 480px;
  margin: 0 auto 1.75rem;
  line-height: 1.6;
}

/* 表单与交互控制 */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  display: flex;
  justify-content: space-between;
}

.form-input, .form-select, .form-textarea {
  background: #0a0a0a;
  border: 1px solid var(--border-noir-light);
  border-radius: 0;
  padding: 0.75rem 1rem;
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 0.95rem;
  text-transform: none;
  outline: none;
  transition: border-color 0.25s, box-shadow 0.25s;
}

.form-input:focus, .form-select:focus, .form-textarea:focus {
  border-color: #a3a3a3;
  box-shadow: 0 0 0 1px #a3a3a3;
}

.form-input::placeholder, .form-textarea::placeholder {
  color: var(--text-faint);
  font-family: var(--font-sans);
}

/* 页脚 (Film Noir 极简档案底栏) */
.footer {
  margin-top: auto;
  border-top: 1px solid var(--border-noir);
  background: #0a0a0a;
  padding: 3rem 2rem;
  color: var(--text-faint);
  font-size: 0.85rem;
}

/* 闪存消息通知 */
.flash-container {
  max-width: 1200px;
  margin: 1.25rem auto 0;
  padding: 0 1.5rem;
}

.flash-msg {
  padding: 0.85rem 1.4rem;
  border-radius: 0;
  font-size: 0.9rem;
  margin-bottom: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-left: 3px solid;
}

.flash-success {
  background: #141714;
  border-color: #4ade80;
  color: #bbf7d0;
}

.flash-error {
  background: #1c1314;
  border-color: var(--accent-noir-crimson);
  color: #fca5a5;
}

.flash-info {
  background: #14161a;
  border-color: #94a3b8;
  color: #e2e8f0;
}

/* 全局多端响应式适配 (平板、折叠屏与手机浏览防错位) */
@media (max-width: 992px) {
  .navbar {
    padding: 0.75rem 1.5rem;
    flex-wrap: wrap;
    gap: 0.75rem;
  }
  .nav-left {
    gap: 1.25rem !important;
  }
  .nav-links {
    gap: 1.25rem;
  }
  .nav-right {
    gap: 0.5rem;
  }
  .container {
    padding: 2rem 1.25rem;
  }
}

@media (max-width: 768px) {
  .navbar {
    padding: 0.75rem 1rem;
    gap: 0.5rem;
  }
  .nav-left {
    width: 100%;
    justify-content: space-between;
  }
  .nav-links {
    width: 100%;
    order: 3;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding: 0.4rem 0 0.2rem;
    gap: 1.15rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    scrollbar-width: none;
  }
  .nav-links::-webkit-scrollbar {
    display: none;
  }
  .nav-links a {
    white-space: nowrap;
    font-size: 0.9rem;
  }
  .nav-right {
    width: 100%;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 0.4rem;
  }
  .container {
    padding: 1.5rem 1rem;
  }
  .nav-dropdown .dropdown-menu {
    position: fixed;
    top: 54px;
    right: 1rem;
    left: auto;
    min-width: 220px;
    max-width: calc(100vw - 2rem);
    z-index: 9999;
  }

  /* 移动端全景视口自适应自动填充 */
  .hero-bleed,
  .hero-home-banner {
    flex: 1 1 auto;
    min-height: calc(100svh - 96px);
    height: auto;
  }
  .hero-lead-title {
    padding: 0 1.5rem;
  }
  .hero-lead-badge {
    width: 100%;
    font-size: clamp(0.9rem, 2.2vw, 1.1rem);
    line-height: 1.65;
    padding: 0.85rem 1.25rem;
  }
  .hero-content {
    padding: 1.25rem 1.5rem 2.25rem;
  }
  .hero-title {
    font-size: clamp(2rem, 6.8vw, 2.6rem);
    line-height: 1.2;
    margin-bottom: 1rem;
    max-width: 100%;
  }
  .hero-desc {
    font-size: 0.96rem;
    line-height: 1.65;
    margin-bottom: 1.75rem;
    max-width: 100%;
  }
  .hero-actions {
    gap: 0.85rem;
  }
}

@media (max-width: 576px) {
  .nav-brand {
    font-size: 1.25rem;
  }
  .quota-badge {
    font-size: 0.72rem;
    padding: 0.25rem 0.5rem;
  }
  .btn {
    font-size: 0.8rem;
    padding: 0.4rem 0.75rem;
  }
  .container {
    padding: 1.25rem 0.85rem;
  }

  /* 紧凑型手机屏幕优化 (如 iPhone 12/13/14 mini, SE) */
  .hero-bleed,
  .hero-home-banner {
    min-height: calc(100svh - 90px);
  }
  .hero-lead-title {
    padding: 0 1.25rem;
  }
  .hero-lead-badge {
    font-size: 0.85rem;
    line-height: 1.55;
    padding: 0.65rem 0.95rem;
  }
  .hero-content {
    padding: 1rem 1.25rem 1.75rem;
  }
  .hero-tag {
    font-size: 0.68rem;
    padding: 0.25rem 0.65rem;
    margin-bottom: 0.85rem;
  }
  .hero-title {
    font-size: clamp(1.75rem, 6.5vw, 2.2rem);
    line-height: 1.25;
    margin-bottom: 0.85rem;
  }
  .hero-desc {
    font-size: 0.88rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
  }
  .hero-actions {
    gap: 0.65rem;
    width: 100%;
  }
  .hero-actions .btn {
    flex: 1 1 auto;
    text-align: center;
    justify-content: center;
    padding: 0.65rem 1rem;
    font-size: 0.86rem;
  }
}

@media (max-width: 380px) {
  .hero-content {
    padding: 1.75rem 1rem 1.5rem;
  }
  .hero-desc {
    font-size: 0.82rem;
  }
}

/* 施工中页面卡片 (Under Construction Film Noir Style) */
.under-construction-card {
  background: #111111;
  border: 1px solid var(--border-noir);
  border-top: 2px solid var(--accent-noir-crimson);
  border-radius: 0;
  padding: 3.5rem 2.5rem;
  max-width: 620px;
  width: 100%;
  text-align: center;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
  position: relative;
}

.construction-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.85rem;
  background: rgba(220, 38, 38, 0.1);
  border: 1px solid rgba(220, 38, 38, 0.25);
  color: #f87171;
  font-size: 0.75rem;
  font-family: var(--font-mono, monospace);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 2rem;
}

.pulsing-dot {
  width: 7px;
  height: 7px;
  background: #ef4444;
  border-radius: 50%;
  box-shadow: 0 0 8px #ef4444;
  animation: pulse-glow 2s infinite ease-in-out;
}

@keyframes pulse-glow {
  0%, 100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.35;
    transform: scale(0.8);
  }
}

.construction-icon-wrap {
  width: 80px;
  height: 80px;
  margin: 0 auto 1.75rem;
  background: #161616;
  border: 1px solid var(--border-noir-light);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-primary);
  box-shadow: inset 0 0 15px rgba(0, 0, 0, 0.5);
}

.construction-title {
  font-size: 2rem;
  font-family: var(--font-serif);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
}

.construction-line {
  width: 50px;
  height: 1px;
  background: var(--border-noir-light);
  margin: 1.25rem auto;
}

.construction-status {
  font-size: 1rem;
  color: var(--text-muted);
  line-height: 1.7;
  max-width: 440px;
  margin: 0 auto 2rem;
}

.construction-actions {
  display: flex;
  justify-content: center;
  gap: 0.85rem;
  flex-wrap: wrap;
}


