/* ==================== 基础变量 ==================== */
:root {
  --golden-ratio: 1.618;
  --sidebar-width: 20%;
  --content-width: 50%;
  --spacing-unit: 1rem;
  --color-primary: #c9a96e;
  --color-text: #333;
  --color-text-light: #666;
  --color-bg: #fff;
  --color-bg-light: #f8f8f8;
  --color-bg-sidebar: #fafafa;
  --mobile-bottom-bar-height: 60px;
  --transition: all 0.3s ease;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ==================== 全局两栏布局 ==================== */
.golden-layout-container {
  display: flex;
  min-height: 100vh;
}

/* 左侧固定侧边栏：Logo靠左，取消居中 */
.sidebar-left {
  width: var(--sidebar-width);
  flex: 0 0 var(--sidebar-width);
  background: var(--color-bg-sidebar);
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
}

.sidebar-header {
  text-align: left;
}

.logo-section {
  display: flex;
  justify-content: flex-start;
}

.logo-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--color-text);
}

/* 中间主内容区 */
.sidebar-category-info{
	 padding: 2rem 0;
}
.content-main {
  flex: 1 1 auto;
  width: 100%;
  display: flex;
  justify-content: flex-start;
}

.single-scroll {
  width: 100%;
  padding-top: calc(var(--spacing-unit) * 2);
  padding-bottom: calc(var(--spacing-unit) * 3);
  max-width: unset;
}

/* ==================== Single 文章页 ==================== */
.single-article {
  max-width: 760px;
  margin: 0 auto;
}

.single-article-header {
  margin-bottom: calc(var(--spacing-unit) * 2);
  padding-bottom: calc(var(--spacing-unit) * 1.2);
}

.single-article-title {
  font-size: 2.2rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--color-text);
  margin: 0 0 1rem;
}

.single-article-meta {
  font-size: 0.88rem;
  color: var(--color-text-light);
}

.single-article-meta span {
  margin-right: 1rem;
}

.single-article-thumbnail {
  margin: 0 0 calc(var(--spacing-unit) * 2);
  border-radius: 8px;
  overflow: hidden;
}

.single-article-thumbnail img {
  width: 100%;
  display: block;
}

.single-article-content {
  font-size: 1.08rem;
  line-height: 1.88;
  color: var(--color-text);
}

.single-article-content p {
  margin-bottom: 1.45rem;
}

.single-article-content h2 {
  font-size: 1.5rem;
  margin: 2.2rem 0 1rem;
  font-weight: 600;
}

.single-article-content h3 {
  font-size: 1.28rem;
  margin: 1.8rem 0 0.9rem;
  font-weight: 600;
}

.single-article-content h4 {
  font-size: 1.15rem;
  margin: 1.6rem 0 0.8rem;
  font-weight: 600;
}

.single-article-content blockquote {
  border-left: 3px solid var(--color-primary);
  padding: 0.4rem 0 0.4rem 1.2rem;
  margin: 1.6rem 0;
  color: var(--color-text-light);
}

.single-article-content pre {
  background: var(--color-bg-light);
  padding: 1.2rem;
  border-radius: 6px;
  overflow-x: auto;
  margin: 1.6rem 0;
}

.single-article-content img {
  max-width: 100%;
  height: auto;
  border-radius: 6px;
  margin: 1.3rem 0;
  display: block;
}

.single-tags {
  margin-top: 2.8rem;
  padding-top: 1rem;
  font-size: 0.88rem;
  color: var(--color-text-light);
}

.single-post-nav {
  display: flex;
  justify-content: space-between;
  margin: 2rem 0;
  padding: 1rem 0;
}

.single-post-nav a {
  color: var(--color-primary);
  text-decoration: none;
}

.single-post-nav a:hover {
  text-decoration: underline;
}

.single-page-links {
  margin: 1.5rem 0;
}

/* 相关阅读 */
.single-related {
  max-width: 760px;
  margin: 4rem auto 0;
  padding-top: 2.2rem;
}

.related-title {
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--color-primary);
  margin-bottom: calc(var(--spacing-unit) * 1.4);
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: calc(var(--spacing-unit) * 1.2);
}

.related-card {
  border-radius: 8px;
  overflow: hidden;
  background: var(--color-bg);
  transition: var(--transition);
}

.related-card:hover {
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.07);
}

.related-card-thumb {
  aspect-ratio: 16 / 10;
  overflow: hidden;
}

.related-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.related-card-body {
  padding: calc(var(--spacing-unit) * 0.9);
}

.related-card-title {
  font-size: 0.96rem;
  line-height: 1.42;
  margin: 0 0 0.4rem;
  font-weight: 500;
}

.related-card-title a {
  color: var(--color-text);
  text-decoration: none;
}

.related-card-title a:hover {
  color: var(--color-primary);
}

.related-card-date {
  font-size: 0.78rem;
  color: var(--color-text-light);
}

/* ==================== Category Normal 分类列表页｜3列卡片｜隐藏摘要 ==================== */
.category-header-block {
  max-width: 760px;
  margin: 0 auto calc(var(--spacing-unit) * 2);
  padding-bottom: calc(var(--spacing-unit) * 1.2);
  text-align: center;
}

.category-page-title {
  font-size: 2.2rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--color-text);
  margin: 0 0 1rem;
}

.category-page-desc {
  font-size: 1.08rem;
  line-height: 1.88;
  color: var(--color-text-light);
  max-width: 640px;
  margin: 0 auto;
}

.category-article-list {
  max-width: 100%;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: calc(var(--spacing-unit) * 1.8);
}

.category-list-item {
  display: flex;
  flex-direction: column;
  background: var(--color-bg);
  overflow: hidden;
  transition: var(--transition);
  padding: 0;
  margin: 0;
}

.category-list-item:hover {
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}

.list-thumb-part {
  width: 100%;
  flex: 0 0 auto;
}

.list-thumb-part img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
  border-radius: 0;
}

.list-thumb-placeholder {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--color-bg-light);
  border-radius: 0;
}

.list-text-part {
  flex: 1;
  padding: calc(var(--spacing-unit) * 0.85);
}

.list-meta-date {
  font-size: 0.78rem;
  color: var(--color-text-light);
  margin-bottom: 0.4rem;
}

.list-item-title {
  font-size: 1.2rem;
  margin: 0;
  font-weight: 600;
  line-height: 1.4;
}

.list-item-title a {
  color: var(--color-text);
  text-decoration: none;
}

.list-item-title a:hover {
  color: var(--color-primary);
}

/* 完全隐藏摘要 */
.list-item-excerpt {
  display: none !important;
}

.category-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 4rem 1rem;
  color: var(--color-text-light);
}

.category-pagination {
  max-width: 100%;
  margin: 2.5rem auto 3rem;
  padding: 1rem 0;
  text-align: center;
}

/* ==================== 滚动进度条 ==================== */
.scroll-progress-wrap {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  z-index: 9999;
}

.scroll-progress-bar {
  height: 100%;
  background-color: var(--color-primary);
  width: 0;
}

/* ==================== 响应式 ==================== */
@media (max-width: 1024px) {
  .golden-layout-container {
    flex-direction: column;
  }

  .sidebar-left {
    width: 100%;
    flex: none;
    justify-content: flex-start;
    align-items: flex-start;
  }

  .sidebar-header {
    width: 100%;
    text-align: left;
  }

  .logo-section {
    justify-content: flex-start;
  }

  .content-main {
    justify-content: flex-start;
  }

  .single-scroll {
    max-width: 100%;
    padding: calc(var(--spacing-unit) * 2) calc(var(--spacing-unit) * 1.2);
  }

  .single-article-title {
    font-size: 1.8rem;
  }

  .single-article-content {
    font-size: 1rem;
  }

  .single-post-nav {
    flex-direction: column;
    gap: 0.8rem;
  }

  .related-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .category-page-title {
    font-size: 1.8rem;
  }

  /* 平板端：2列 */
  .category-article-list {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .single-article-title {
    font-size: 1.5rem;
  }

  .related-grid {
    grid-template-columns: 1fr;
  }

  .category-page-title {
    font-size: 1.5rem;
  }

  /* 手机端：1列 */
  .category-article-list {
    grid-template-columns: 1fr;
  }
}