/* 新闻列表页 — 头条 + 左图右文列表 + 加载更多（仅手机版） */

.list-page {
  padding: 16px;
}

/* ---------- 头条：第一条新闻（大图 + 标题 + 作者日期） ---------- */
.featured {
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 16px;
}

.featured-image {
  display: block;
  width: 100%;
  height: auto;
}

.featured-title {
  font-size: 20px;
  font-weight: 800;
  line-height: 1.35;
  color: #000000;
  padding: 16px 16px 8px;
}

.featured-meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 0 16px 16px;
  font-size: 13px;
}

.featured-author {
  font-weight: 600;
  color: #555555;
}

.featured-date {
  color: #a6a6a6;
}

/* ---------- 新闻列表：左图右文 ---------- */
.news-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.list-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px;
}

.list-thumb {
  flex-shrink: 0;
  width: 96px;
  height: 96px;
  object-fit: cover;
  border-radius: 8px;
  background: #f0f0f0;
}

.list-body {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

/* 标题 — 黑色加粗 */
.list-title {
  font-size: 15px;
  font-weight: 800;
  line-height: 1.35;
  color: #000000;
  margin-bottom: 6px;
}

/* 描述 — 灰色 */
.list-summary {
  font-size: 13px;
  line-height: 1.5;
  color: #8a8a8a;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* 日期 — 灰色小字 */
.list-date {
  font-size: 12px;
  color: #a6a6a6;
  margin-top: auto;
}

/* ---------- 加载更多按钮 ---------- */
.load-more {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  margin-top: 16px;
  padding: 12px;
  background: #ffffff;
  color: var(--accent);
  border: 1px solid var(--accent);
  border-radius: 12px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
}

.load-more:active {
  background: rgba(45, 91, 255, 0.06);
}

/* 加载中状态 */
.load-more.loading {
  color: var(--ink-soft);
  border-color: var(--border);
  cursor: default;
}

.load-more.loading:active {
  background: #ffffff;
}

.spinner {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  border: 2px solid rgba(0, 0, 0, 0.15);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ---------- RTL（阿拉伯语）：文本右对齐 ---------- */
[dir="rtl"] .featured-title,
[dir="rtl"] .featured-meta,
[dir="rtl"] .list-body {
  text-align: right;
}

/* ---------- 加载框 ---------- */
.loading-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.loading-modal[hidden] {
  display: none;
}

.loading-mask {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
}

.loading-card {
  position: relative;
  width: 100%;
  max-width: 320px;
  padding: 28px 24px;
  background: #ffffff;
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.loading-title {
  font-size: 22px;
  font-weight: 800;
  line-height: 1.3;
  color: var(--ink);
  margin-bottom: 16px;
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 4px solid rgba(0, 0, 0, 0.12);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
  margin-bottom: 16px;
}

.loading-text {
  font-size: 14px;
  line-height: 1.6;
  color: var(--ink-soft);
  margin-bottom: 20px;
}

.loading-bar {
  width: 100%;
  height: 6px;
  background: #ececec;
  border-radius: 999px;
  overflow: hidden;
}

.loading-bar-fill {
  height: 100%;
  width: 0%;
  background: var(--accent);
  border-radius: 999px;
}

.loading-percent {
  margin-top: 10px;
  font-size: 13px;
  color: var(--ink-soft);
}
