/* ============================================================
   鎶€鏈垎浜?路 涓汉鍗氬 - Vue Amazing UI 椋庢牸
   閲囩敤 --va-* 涓婚浠ょ墝 + 鏄庢殫鍙屼富棰?+ 缁勪欢鍖栧缇?   ============================================================ */

/* ===== 涓婚浠ょ墝锛圠ight 榛樿锛?===== */
:root {
  /* 鍝佺墝涓昏壊锛堜富棰樼瀛愶級 */
  --va-primary-color: #5b8def;
  --va-primary-color-hover: #4a7de0;
  --va-primary-color-active: #3a6dd0;
  --va-primary-color-light: #eaf1fe;

  /* 鑳屾櫙 */
  --va-bg-color: #f5f7fa;
  --va-bg-color-light: #ffffff;
  --va-bg-color-hover: #f0f2f5;

  /* 鏂囧瓧 */
  --va-text-color: #1f2329;
  --va-text-color-regular: #4e5969;
  --va-text-color-secondary: #86909c;
  --va-text-color-tertiary: #c9cdd4;
  --va-text-color-disabled: #e5e6eb;

  /* 杈规 */
  --va-border-color: #e5e6eb;
  --va-border-color-light: #f0f2f5;
  --va-border-color-hover: #c9cdd4;

  /* 闃村奖 */
  --va-shadow-sm: 0 1px 4px rgba(0, 0, 0, 0.06);
  --va-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  --va-shadow-hover: 0 8px 24px rgba(0, 0, 0, 0.12);

  /* 鍦嗚 */
  --va-radius-sm: 4px;
  --va-radius: 8px;
  --va-radius-lg: 12px;
  --va-radius-pill: 999px;

  /* 鍗＄墖 */
  --va-card-bg: #ffffff;
  --va-card-border: #e5e6eb;
  --va-card-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);

  /* 閾炬帴 */
  --va-link-color: #5b8def;
  --va-link-color-hover: #4a7de0;
  --va-link-color-active: #3a6dd0;

  /* 渚ц竟鏍?*/
  --va-sidebar-bg: #ffffff;
  --va-sidebar-border: #f0f2f5;

  /* 椤舵爮 */
  --va-header-bg: rgba(255, 255, 255, 0.85);
  --va-header-backdrop: blur(12px);

  /* Banner */
  --va-banner-bg: linear-gradient(135deg, #1a3a7a 0%, #2e5aa8 100%);

  /* 闂磋窛 */
  --va-spacing-xs: 4px;
  --va-spacing-sm: 8px;
  --va-spacing: 16px;
  --va-spacing-lg: 24px;
  --va-spacing-xl: 32px;

  /* 杩囨浮 */
  --va-transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== 鏆楄壊涓婚 ===== */
[data-theme="dark"] {
  --va-primary-color: #5b8def;
  --va-primary-color-hover: #6b9df0;
  --va-primary-color-light: #1e2a3a;

  --va-bg-color: #17171a;
  --va-bg-color-light: #1f1f23;
  --va-bg-color-hover: #2a2a2e;

  --va-text-color: #e8e8e8;
  --va-text-color-regular: #c0c0c0;
  --va-text-color-secondary: #8a8a8a;
  --va-text-color-tertiary: #5a5a5a;
  --va-text-color-disabled: #3a3a3a;

  --va-border-color: #2e2e32;
  --va-border-color-light: #26262a;
  --va-border-color-hover: #3a3a3e;

  --va-shadow-sm: 0 1px 4px rgba(0, 0, 0, 0.3);
  --va-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  --va-shadow-hover: 0 8px 24px rgba(0, 0, 0, 0.5);

  --va-card-bg: #1f1f23;
  --va-card-border: #2e2e32;
  --va-card-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);

  --va-link-color: #6b9df0;
  --va-link-color-hover: #7aaaf2;
  --va-link-color-active: #5b8def;

  --va-sidebar-bg: #1f1f23;
  --va-sidebar-border: #26262a;

  --va-header-bg: rgba(31, 31, 35, 0.85);
}

/* ===== 鍩虹 ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Helvetica, Arial, sans-serif;
  font-size: 14px;
  line-height: 1.7;
  color: var(--va-text-color);
  background: var(--va-bg-color);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  transition: background 0.3s, color 0.3s;
}

:where(input, textarea, select, button) { font-family: inherit; }

a {
  color: var(--va-link-color);
  text-decoration: none;
  background-color: transparent;
  cursor: pointer;
  transition: color 0.3s;
}
a:hover { color: var(--va-link-color-hover); }
a:active { color: var(--va-link-color-active); }

/* ===== 椤舵爮 ===== */
.top-bar {
  position: sticky; top: 0; z-index: 100;
  background: var(--va-header-bg);
  backdrop-filter: var(--va-header-backdrop);
  -webkit-backdrop-filter: var(--va-header-backdrop);
  border-bottom: 1px solid var(--va-border-color-light);
}
.top-inner {
  max-width: 1200px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 24px; height: 64px;
}
.logo { font-size: 20px; font-weight: 700; color: var(--va-text-color); letter-spacing: 0.5px; }
.logo span { color: var(--va-primary-color); font-weight: 600; }
.top-nav { display: flex; gap: 4px; }
.top-nav a {
  color: var(--va-text-color-regular); font-size: 14px;
  padding: 8px 14px; border-radius: var(--va-radius);
  transition: var(--va-transition);
}
.top-nav a:hover { color: var(--va-primary-color); background: var(--va-primary-color-light); }
.top-actions { display: flex; align-items: center; gap: 10px; }

/* 涓婚鍒囨崲鎸夐挳 */
.theme-toggle {
  width: 36px; height: 36px; border: none; background: none; cursor: pointer;
  border-radius: var(--va-radius); font-size: 18px; color: var(--va-text-color-regular);
  display: flex; align-items: center; justify-content: center;
  transition: var(--va-transition);
}
.theme-toggle:hover { background: var(--va-bg-color-hover); color: var(--va-primary-color); }

.btn-icon {
  background: none; border: none; font-size: 18px; cursor: pointer;
  padding: 8px; border-radius: var(--va-radius);
  color: var(--va-text-color-regular); transition: var(--va-transition);
}
.btn-icon:hover { background: var(--va-bg-color-hover); color: var(--va-primary-color); }

.btn-login {
  padding: 8px 18px; border-radius: var(--va-radius); font-size: 14px;
  background: var(--va-primary-color); color: #fff !important;
  font-weight: 500; transition: var(--va-transition);
}
.btn-login:hover { background: var(--va-primary-color-hover); color: #fff; }

.hamburger {
  display: none; flex-direction: column; justify-content: center; gap: 4px;
  width: 36px; height: 36px; background: none; border: none; cursor: pointer;
  padding: 4px; color: var(--va-text-color-regular);
}
.hamburger span { display: block; width: 20px; height: 2px; background: currentColor; border-radius: 1px; transition: all 0.2s; }
.hamburger.active span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* ===== 甯冨眬 ===== */
.layout {
  max-width: 1200px; margin: 24px auto; padding: 0 24px;
  display: grid; grid-template-columns: 240px 1fr; gap: 24px;
  align-items: start;
}

/* ===== 渚ц竟鏍?===== */
.sidebar { display: flex; flex-direction: column; gap: 16px; position: sticky; top: 88px; }

/* 鍗＄墖缁勪欢 */
.va-card {
  background: var(--va-card-bg);
  border: 1px solid var(--va-card-border);
  border-radius: var(--va-radius-lg);
  box-shadow: var(--va-card-shadow);
  padding: 20px;
  transition: var(--va-transition);
}
.sidebar .va-card { padding: 18px; }

/* 浣滆€呭崱鐗?*/
.author-card { text-align: center; }
.va-avatar {
  width: 64px; height: 64px; border-radius: 50%;
  background: var(--va-primary-color); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 26px; font-weight: 600; margin: 0 auto 12px;
  box-shadow: 0 4px 12px rgba(91, 141, 239, 0.3);
}
.author-card h2 { font-size: 18px; font-weight: 600; margin-bottom: 4px; color: var(--va-text-color); }
.author-bio { font-size: 13px; color: var(--va-text-color-secondary); margin-bottom: 14px; line-height: 1.6; }
.author-links { display: flex; justify-content: center; gap: 12px; }
.author-links a {
  font-size: 13px; color: var(--va-primary-color);
  padding: 4px 12px; border-radius: var(--va-radius-pill);
  background: var(--va-primary-color-light); transition: var(--va-transition);
}
.author-links a:hover { background: var(--va-primary-color); color: #fff; }

/* 渚ц竟鏍忔爣棰?*/
.sidebar-title { font-size: 13px; font-weight: 600; margin-bottom: 12px; color: var(--va-text-color-secondary); letter-spacing: 0.5px; }

/* 瀵艰埅鍒楄〃 */
.nav-list { list-style: none; }
.nav-list li { margin-bottom: 2px; }
.nav-list a {
  display: flex; align-items: center; justify-content: space-between;
  padding: 8px 12px; border-radius: var(--va-radius);
  color: var(--va-text-color-regular); font-size: 14px;
  transition: var(--va-transition);
}
.nav-list a:hover { background: var(--va-bg-color-hover); color: var(--va-primary-color); }
.nav-list a .count {
  font-size: 12px; color: var(--va-text-color-tertiary);
  background: var(--va-bg-color-hover); padding: 1px 8px; border-radius: var(--va-radius-pill);
}

/* 鏍囩浜?*/
.tag-cloud { display: flex; flex-wrap: wrap; gap: 6px; }
.tag-cloud a {
  display: inline-flex; align-items: center;
  padding: 3px 10px; border-radius: var(--va-radius-pill);
  font-size: 12px; color: var(--va-text-color-regular);
  background: var(--va-bg-color-hover); border: 1px solid transparent;
  transition: var(--va-transition);
}
.tag-cloud a:hover {
  color: var(--va-primary-color); background: var(--va-primary-color-light);
  border-color: var(--va-primary-color);
}
.tag-cloud a .count { color: var(--va-text-color-tertiary); margin-left: 4px; }

/* 鎴戠殑绔欑偣鍗＄墖 */
#links-card ul { list-style: none; }
#links-card li { margin-bottom: 8px; }
#links-card a {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 8px 12px; border-radius: var(--va-radius);
  color: var(--va-text-color-regular); font-size: 14px;
  transition: var(--va-transition);
}
#links-card a:hover { background: var(--va-bg-color-hover); color: var(--va-primary-color); }
#links-card a .link-desc { font-size: 12px; color: var(--va-text-color-secondary); display: block; width: 100%; }
.qr-badge {
  font-size: 13px; color: var(--va-primary-color);
  background: var(--va-primary-color-light);
  padding: 0 6px; border-radius: var(--va-radius-sm); line-height: 18px;
}
/* 浜岀淮鐮佹偓鍋滄皵娉?*/
.link-item.has-qr { position: relative; }
.qr-popup {
  display: none; position: absolute; left: 50%; top: 100%;
  transform: translateX(-50%); margin-top: 6px;
  background: var(--va-card-bg); border: 1px solid var(--va-card-border);
  border-radius: var(--va-radius-lg); box-shadow: var(--va-shadow-hover);
  padding: 12px; z-index: 60; text-align: center;
}
.link-item.has-qr:hover .qr-popup,
.link-item.has-qr:focus-within .qr-popup { display: block; }
.qr-popup img { width: 140px; height: 140px; object-fit: contain; display: block; border-radius: var(--va-radius); }
.qr-tip { font-size: 12px; color: var(--va-text-color-secondary); margin-top: 6px; }
/* 鎵嬫満绔細鐐瑰嚮鍒囨崲浜岀淮鐮侊紙鏃?hover锛?*/
@media (hover: none) {
  .link-item.has-qr.qr-open .qr-popup { display: block; }
}

/* ===== 鍐呭鍖?===== */
.main-content { min-width: 0; }
.list-header { margin-bottom: 16px; }
.list-header h1 { font-size: 20px; font-weight: 600; color: var(--va-text-color); }

/* Segmented 绛涢€?*/
.va-segmented {
  display: inline-flex; padding: 3px;
  background: var(--va-bg-color-hover); border-radius: var(--va-radius);
  margin-bottom: 16px;
}
.va-segmented-item {
  padding: 6px 16px; border-radius: var(--va-radius-sm);
  font-size: 13px; color: var(--va-text-color-secondary);
  cursor: pointer; transition: var(--va-transition);
}
.va-segmented-item.active {
  background: var(--va-card-bg); color: var(--va-primary-color);
  box-shadow: var(--va-shadow-sm); font-weight: 500;
}

/* Banner */
.site-banner {
  width: 100%; border-radius: var(--va-radius-lg); overflow: hidden;
  margin-bottom: 20px; box-shadow: var(--va-shadow);
  background: var(--va-banner-bg);
}
.site-banner img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* 鏂囩珷鍒楄〃 */
.articles { display: flex; flex-direction: column; gap: 16px; }

/* 鏂囩珷鍗＄墖锛氬乏鏂囧彸鍥?*/
.article-card {
  background: var(--va-card-bg);
  border: 1px solid var(--va-card-border);
  border-radius: var(--va-radius-lg);
  box-shadow: var(--va-card-shadow);
  padding: 20px;
  transition: var(--va-transition);
  cursor: pointer;
  position: relative;
  overflow: hidden;
  display: flex;
  gap: 20px;
  align-items: stretch;
}
.article-card .card-body {
  flex: 1; min-width: 0;
  display: flex; flex-direction: column;
}
.article-card .card-cover {
  width: 45%; min-width: 220px; max-width: 380px; flex-shrink: 0;
  border-radius: var(--va-radius);
  overflow: hidden;
  background: var(--va-bg-color-hover);
  align-self: stretch;
}
.article-card .card-cover img {
  width: 100%; height: 100%;
  min-height: 150px;
  object-fit: cover; display: block;
  transition: transform 0.4s;
}
.article-card:hover .card-cover img { transform: scale(1.06); }
.article-card::before {
  content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px;
  background: var(--va-primary-color);
  transform: scaleY(0); transform-origin: top;
  transition: transform 0.3s;
}
.article-card:hover {
  box-shadow: var(--va-shadow-hover); transform: translateY(-2px);
  border-color: var(--va-primary-color);
}
.article-card:hover::before { transform: scaleY(1); }
.article-card .card-title {
  font-size: 17px; font-weight: 600; margin-bottom: 10px;
  color: var(--va-text-color); display: block; line-height: 1.5;
  transition: color 0.2s;
}
.article-card:hover .card-title { color: var(--va-primary-color); }
.article-card .card-excerpt {
  font-size: 14px; color: var(--va-text-color-secondary); line-height: 1.7;
  margin-bottom: 16px; display: -webkit-box;
  -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.article-card .card-meta {
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
  font-size: 13px; color: var(--va-text-color-tertiary);
  margin-top: auto;
}
.article-card .card-meta span { display: flex; align-items: center; gap: 4px; }

/* Tag 缁勪欢 */
.va-tag {
  display: inline-flex; align-items: center;
  padding: 2px 10px; border-radius: var(--va-radius-pill);
  font-size: 12px; color: var(--va-text-color-regular);
  background: var(--va-bg-color-hover); border: 1px solid transparent;
  transition: var(--va-transition);
}
.article-card .card-tags .va-tag:hover {
  background: var(--va-primary-color); color: #fff; border-color: var(--va-primary-color);
}

/* 鍒嗙被鏍囩锛堝崱鐗囦笂鐨勶級 */
.category-badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 10px; border-radius: var(--va-radius-pill);
  font-size: 12px; font-weight: 500;
  background: var(--va-primary-color-light); color: var(--va-primary-color);
}

/* ===== 鏂囩珷璇︽儏 ===== */
.article-detail {
  background: var(--va-card-bg);
  border: 1px solid var(--va-card-border);
  border-radius: var(--va-radius-lg);
  box-shadow: var(--va-card-shadow);
  padding: 40px; max-width: 800px; margin: 0 auto;
}
.article-detail h1 { font-size: 26px; margin-bottom: 16px; line-height: 1.5; color: var(--va-text-color); }
.article-detail .detail-meta {
  display: flex; gap: 20px; margin-bottom: 28px;
  padding-bottom: 24px; border-bottom: 1px solid var(--va-border-color-light);
  font-size: 14px; color: var(--va-text-color-secondary); flex-wrap: wrap;
}
.article-detail .detail-content { font-size: 16px; line-height: 1.9; color: var(--va-text-color); }
.article-detail .detail-content h2 { font-size: 22px; margin: 32px 0 16px; color: var(--va-text-color); }
.article-detail .detail-content h3 { font-size: 19px; margin: 24px 0 12px; color: var(--va-text-color); }
.article-detail .detail-content p { margin-bottom: 18px; }
.article-detail .detail-content img { max-width: 100%; border-radius: var(--va-radius); margin: 20px 0; }
.article-detail .detail-content code {
  background: var(--va-bg-color-hover); padding: 2px 6px; border-radius: var(--va-radius-sm);
  font-size: 14px; font-family: 'SF Mono', Monaco, Consolas, monospace;
}
.article-detail .detail-content pre {
  background: var(--va-bg-color-hover); padding: 16px; border-radius: var(--va-radius);
  overflow-x: auto; margin: 20px 0; border: 1px solid var(--va-border-color-light);
}
.article-detail .detail-content pre code { background: none; padding: 0; }
.article-detail .detail-content blockquote {
  border-left: 4px solid var(--va-primary-color); padding: 12px 20px;
  margin: 20px 0; background: var(--va-primary-color-light); border-radius: 0 var(--va-radius) var(--va-radius) 0;
  color: var(--va-text-color-regular);
}
.article-detail .back-link {
  display: inline-flex; align-items: center; gap: 4px;
  margin-bottom: 20px; color: var(--va-primary-color); font-size: 14px;
  padding: 6px 14px; border-radius: var(--va-radius); background: var(--va-primary-color-light);
  transition: var(--va-transition);
}
.article-detail .back-link:hover { background: var(--va-primary-color); color: #fff; }

/* ===== 鍔犺浇/绌虹姸鎬?===== */
.va-empty {
  text-align: center; padding: 60px 20px;
  color: var(--va-text-color-secondary);
}
.va-empty .va-empty-icon { font-size: 48px; margin-bottom: 16px; opacity: 0.6; }
.va-empty .va-empty-text { font-size: 15px; margin-bottom: 8px; }
.va-empty .va-empty-link { color: var(--va-primary-color); font-size: 14px; }

/* Spin 鍔犺浇 */
.va-spin {
  display: inline-block; width: 24px; height: 24px;
  border: 3px solid var(--va-border-color); border-top-color: var(--va-primary-color);
  border-radius: 50%; animation: va-spin 0.8s linear infinite;
}
.loading-block, .loading { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 60px 20px; color: var(--va-text-color-secondary); font-size: 14px; }

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

/* ===== 鎼滅储寮圭獥 ===== */
.search-overlay {
  position: fixed; inset: 0; background: rgba(0, 0, 0, 0.5);
  z-index: 200; display: none; align-items: flex-start; justify-content: center;
  padding-top: 120px;
}
.search-overlay.active { display: flex; }
.search-box {
  background: var(--va-card-bg); border-radius: var(--va-radius-lg);
  width: 90%; max-width: 600px; padding: 24px;
  box-shadow: var(--va-shadow-hover); border: 1px solid var(--va-card-border);
}
.search-box input {
  width: 100%; border: none; outline: none; font-size: 18px;
  background: var(--va-bg-color-hover); color: var(--va-text-color);
  padding: 14px 18px; border-radius: var(--va-radius); margin-bottom: 16px;
}
.search-results { max-height: 400px; overflow-y: auto; }
.search-results .result-item {
  padding: 12px; border-radius: var(--va-radius); cursor: pointer;
  transition: var(--va-transition); border: 1px solid transparent;
}
.search-results .result-item:hover { background: var(--va-bg-color-hover); border-color: var(--va-border-color-light); }
.search-results .result-item .r-title { font-weight: 600; color: var(--va-text-color); margin-bottom: 4px; }
.search-results .result-item .r-excerpt { font-size: 13px; color: var(--va-text-color-secondary); }

/* ===== 鍒嗛〉 ===== */
.pagination { display: flex; justify-content: center; gap: 6px; margin-top: 24px; }
.pagination button {
  min-width: 36px; height: 36px; padding: 0 10px;
  border: 1px solid var(--va-border-color); border-radius: var(--va-radius);
  background: var(--va-card-bg); color: var(--va-text-color-regular);
  cursor: pointer; font-size: 14px; transition: var(--va-transition);
}
.pagination button:hover:not(:disabled) { color: var(--va-primary-color); border-color: var(--va-primary-color); }
.pagination button.active { background: var(--va-primary-color); color: #fff; border-color: var(--va-primary-color); font-weight: 500; }
.pagination button:disabled { opacity: 0.4; cursor: not-allowed; }

/* ===== 鍒嗙被椤?===== */
.category-header { padding: 28px 32px; }
.category-intro { }
.category-badge-large {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 20px; font-weight: 600; color: var(--va-primary-color);
  margin-bottom: 14px;
}
.category-desc {
  font-size: 15px; line-height: 1.8; color: var(--va-text-color-regular);
}
.category-desc h1, .category-desc h2, .category-desc h3 { font-size: 17px; margin: 16px 0 10px; color: var(--va-text-color); }
.category-desc p { margin-bottom: 12px; }
.category-desc code {
  background: var(--va-bg-color-hover); padding: 2px 6px; border-radius: var(--va-radius-sm);
  font-size: 13px; font-family: 'SF Mono', Monaco, Consolas, monospace;
}
.category-desc pre {
  background: var(--va-bg-color-hover); padding: 14px; border-radius: var(--va-radius);
  overflow-x: auto; margin: 14px 0;
}
.category-desc a { color: var(--va-primary-color); }
.category-desc ul { padding-left: 22px; margin: 12px 0; }
.category-desc-empty { color: var(--va-text-color-secondary); font-size: 14px; }
@media (max-width: 768px) {
  .category-header { padding: 20px; }
}

/* ===== 鍥炲埌椤堕儴 ===== */
.va-backtop {
  position: fixed; right: 30px; bottom: 30px;
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--va-primary-color); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; cursor: pointer; box-shadow: var(--va-shadow-hover);
  opacity: 0; visibility: hidden; transition: var(--va-transition);
  z-index: 90; border: none;
}
.va-backtop.show { opacity: 1; visibility: visible; }
.va-backtop:hover { transform: translateY(-4px); background: var(--va-primary-color-hover); }

/* ===== 椤佃剼 ===== */
.site-footer {
  text-align: center; padding: 32px 16px; font-size: 13px;
  color: var(--va-text-color-tertiary); border-top: 1px solid var(--va-border-color-light);
  margin-top: 32px;
}

/* ===== 鎵嬫満绔伄缃?===== */
.sidebar-overlay {
  display: none; position: fixed; inset: 0; background: rgba(0, 0, 0, 0.45);
  z-index: 140;
}
.sidebar-overlay.active { display: block; }

/* ===== 鍝嶅簲寮?===== */
@media (max-width: 1024px) and (min-width: 769px) {
  .layout { grid-template-columns: 200px 1fr; gap: 16px; padding: 0 16px; }
  .sidebar { gap: 12px; }
  .sidebar .va-card { padding: 14px; }
  .article-card { padding: 16px; gap: 14px; }
  .article-card .card-cover { width: 40%; min-width: 180px; max-width: 300px; }
  .article-card .card-cover img { height: 100%; min-height: 120px; }
  .article-detail { padding: 32px; }
  .top-inner { padding: 0 16px; }
}

@media (max-width: 768px) {
  .top-inner { padding: 0 12px; height: 56px; }
  .logo { font-size: 17px; }
  .top-nav { display: none; }
  .btn-login { display: none; }
  .top-actions { gap: 4px; }
  .btn-icon { font-size: 16px; padding: 6px; }
  .hamburger { display: flex; }

  .sidebar {
    position: fixed; top: 0; left: 0; bottom: 0;
    width: 280px; max-width: 85vw;
    background: var(--va-sidebar-bg);
    transform: translateX(-100%); transition: transform 0.3s ease;
    z-index: 150; padding: 20px 16px; overflow-y: auto;
    box-shadow: 4px 0 16px rgba(0, 0, 0, 0.2);
  }
  .sidebar.open { transform: translateX(0); }

  .layout { grid-template-columns: 1fr; padding: 0 12px; margin: 12px auto; }

  .va-avatar { width: 54px; height: 54px; font-size: 22px; }
  .author-card h2 { font-size: 16px; }
  .author-bio { font-size: 12px; }

  .article-card { padding: 0; border-radius: var(--va-radius); gap: 0; flex-direction: column; }
  .article-card::before { display: none; }
  .article-card .card-body { padding: 16px 16px 18px; }
  .article-card .card-cover { width: 100%; min-width: 0; max-width: none; order: -1; border-radius: var(--va-radius) var(--va-radius) 0 0; }
  .article-card .card-cover img { height: 230px; min-height: 230px; }
  .article-card .card-title { font-size: 16px; }
  .article-card .card-excerpt { font-size: 13px; -webkit-line-clamp: 2; }
  .article-card .card-meta { font-size: 12px; gap: 10px; }

  .article-detail { padding: 20px 16px; border-radius: var(--va-radius); }
  .article-detail h1 { font-size: 20px; }
  .article-detail .detail-meta { font-size: 12px; gap: 12px; }
  .article-detail .detail-content { font-size: 15px; line-height: 1.8; }
  .article-detail .detail-content h2 { font-size: 19px; }
  .article-detail .detail-content h3 { font-size: 17px; }
  .article-detail .detail-content pre { padding: 12px; font-size: 13px; overflow-x: auto; -webkit-overflow-scrolling: touch; }

  .tag-cloud a { font-size: 12px; }
  .search-box { padding: 16px; }
  .search-box input { font-size: 16px; }

  .va-backtop { right: 16px; bottom: 16px; width: 40px; height: 40px; font-size: 18px; }
}

@media (max-width: 380px) {
  .logo { font-size: 15px; }
  .article-card .card-cover { width: 100%; }
  .article-card .card-cover img { height: 200px; min-height: 200px; }
  .article-card .card-title { font-size: 15px; }
  .article-card .card-excerpt { -webkit-line-clamp: 2; }
  .article-detail .detail-content { font-size: 14px; }
  .sidebar { width: 260px; }
}

@media (hover: none) and (pointer: coarse) {
  .article-card { -webkit-tap-highlight-color: transparent; }
  .article-card:active { transform: scale(0.98); transition: transform 0.1s; }
  .btn-icon, .hamburger, .nav-list a { -webkit-tap-highlight-color: transparent; }
}

@media (min-width: 1440px) {
  .layout { max-width: 1400px; }
  .top-inner { max-width: 1400px; }
}
