@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&family=Righteous&display=swap');

/* ===== 基础变量 ===== */
:root {
  --bg: #fdfbf7;
  --bg-alt: #f5f5f5;
  --ink: #1a1a1a;
  --ink-light: #4a4a4a;
  --ink-muted: #7a7a7a;
  --border: #d8d4cc;
  --border-light: #e8e4dc;
  --accent: #1a1a1a;
  --accent-hover: #3a3a3a;
  --radius: 4px;
  --aside-width: 220px;
  --sidebar-width: 200px;
  --max-content: 780px;
  --font-body: 'Poppins', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  --font-heading: 'Righteous', 'PingFang SC', sans-serif;
}

/* ===== 纸质纹理伪元素 ===== */
html::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='200' height='200' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E");
  opacity: 0.04;
}

/* ===== 重置 ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: auto; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.7;
  min-height: 100vh;
  display: flex;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
a:hover { color: var(--accent-hover); }
ul { list-style: none; }
button { cursor: pointer; font-family: inherit; }

/* ===== 屏幕阅读器专用 ===== */
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

/* ===== 侧边导航（aside > nav > ul > li > a） ===== */
.site-nav-aside {
  position: fixed;
  left: 0; top: 0; bottom: 0;
  width: var(--aside-width);
  background: var(--bg-alt);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  padding: 24px 0;
  z-index: 100;
  overflow-y: auto;
}

.brand-mark {
  padding: 0 20px 20px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 16px;
}

.brand-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px; height: 36px;
  background: var(--ink);
  color: var(--bg);
  font-family: var(--font-heading);
  font-size: 1.1rem;
  border-radius: var(--radius);
  font-weight: 700;
}

.site-nav-aside nav ul {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 0 12px;
}

.site-nav-aside nav ul li a {
  display: block;
  padding: 10px 12px;
  font-size: 0.82rem;
  font-weight: 500;
  text-decoration: none;
  border-radius: var(--radius);
  color: var(--ink-light);
  line-height: 1.4;
  min-height: 40px;
  display: flex;
  align-items: center;
  transition: none;
}

.site-nav-aside nav ul li a:hover,
.site-nav-aside nav ul li a[aria-current="page"] {
  background: var(--border-light);
  color: var(--ink);
  font-weight: 600;
}

.nav-cta {
  margin-top: auto;
  padding: 20px 12px 0;
  border-top: 1px solid var(--border);
}

/* ===== 主内容区 ===== */
.page-wrap {
  margin-left: var(--aside-width);
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* ===== 顶部 header ===== */
.site-header {
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 80;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 32px;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
}

.header-logo { height: 32px; width: auto; }

.header-brand-text {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-decoration: none;
  color: var(--ink);
}
.header-brand a { text-decoration: none; }

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 8px 12px;
  font-size: 1.2rem;
  min-height: 40px;
  min-width: 40px;
  color: var(--ink);
}

.mobile-nav { display: none; }
.mobile-nav ul {
  display: flex;
  flex-direction: column;
  padding: 12px 24px;
  border-top: 1px solid var(--border);
  gap: 4px;
}
.mobile-nav ul li a {
  display: block;
  padding: 10px 12px;
  text-decoration: none;
  font-size: 0.9rem;
  border-radius: var(--radius);
  min-height: 44px;
  display: flex;
  align-items: center;
}
.mobile-nav ul li a:hover { background: var(--bg-alt); }

/* ===== 粘性锚点条 ===== */
.sticky-anchor-bar {
  display: flex;
  gap: 0;
  border-bottom: 1px solid var(--border);
  background: var(--bg-alt);
  padding: 0 32px;
  position: sticky;
  top: 57px;
  z-index: 70;
}

.sticky-anchor-bar a {
  display: inline-flex;
  align-items: center;
  padding: 10px 16px;
  font-size: 0.8rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--ink-muted);
  border-bottom: 2px solid transparent;
  min-height: 40px;
}
.sticky-anchor-bar a:hover {
  color: var(--ink);
  border-bottom-color: var(--ink);
}

/* ===== main ===== */
main {
  flex: 1;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  padding: 0 32px 48px;
}

/* ===== article 基础 ===== */
article {
  margin-bottom: 48px;
  padding-top: 32px;
}

/* ===== 标题 ===== */
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  line-height: 1.3;
  color: var(--ink);
}
h1 { font-size: clamp(1.5rem, 4vw, 2.2rem); margin-bottom: 16px; }
h2 { font-size: clamp(1.1rem, 2.5vw, 1.4rem); margin-bottom: 12px; }
h3 { font-size: 1rem; margin-bottom: 10px; font-weight: 600; }

hr {
  border: none;
  border-top: 1px solid var(--border);
  margin-bottom: 24px;
}

/* ===== HERO（首页） ===== */
.hero-section {
  min-height: 45vh;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 32px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 0;
  padding: 40px 0;
  flex-direction: row-reverse;
  position: relative;
}

.hero-figure {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.hero-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 80px; height: 80px;
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  font-size: 2rem;
  font-family: var(--font-heading);
  background: var(--bg-alt);
}

.hero-badge {
  display: inline-block;
  background: var(--ink);
  color: var(--bg);
  font-size: 0.7rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 2px;
  letter-spacing: 0.08em;
}

.hero-aside {
  text-align: right;
  max-width: 520px;
}

.hero-eyebrow {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--ink-muted);
  text-transform: uppercase;
  margin-bottom: 12px;
}

.hero-h1 { font-size: clamp(1.6rem, 4.5vw, 2.6rem); margin-bottom: 16px; }

.hero-sub {
  font-size: 0.95rem;
  color: var(--ink-light);
  margin-bottom: 24px;
  line-height: 1.7;
}

.hero-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  flex-wrap: wrap;
}

/* ===== 按钮 ===== */
.btn-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--ink);
  color: var(--bg);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 10px 20px;
  border-radius: var(--radius);
  min-height: 40px;
  letter-spacing: 0.03em;
}
.btn-cta:hover { background: var(--accent-hover); color: var(--bg); }

.btn-outline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  color: var(--ink);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 10px 20px;
  border: 1px solid var(--ink);
  border-radius: var(--radius);
  min-height: 40px;
}
.btn-outline:hover { background: var(--bg-alt); }

/* ===== content-section 带 aside 侧边栏 ===== */
.content-section,
.entries-section,
.entry-content-section,
.entry-nav-section,
.about-content-section,
.about-links-section,
.privacy-content-section,
.default-content-section,
.tag-main-section,
.tag-entries-section,
.recent-section,
.related-section {
  display: grid;
  grid-template-columns: 1fr var(--sidebar-width);
  grid-template-rows: auto auto 1fr;
  gap: 0 32px;
}

.content-section h2,
.entries-section h2,
.entry-content-section h2,
.entry-nav-section h2,
.about-content-section h2,
.about-links-section h2,
.privacy-content-section h2,
.default-content-section h2,
.tag-main-section h1,
.tag-main-section h2,
.tag-entries-section h2,
.recent-section h2,
.related-section h2 {
  grid-column: 1 / -1;
}

.content-section > hr,
.entries-section > hr,
.entry-content-section > hr,
.entry-nav-section > hr,
.about-content-section > hr,
.about-links-section > hr,
.privacy-content-section > hr,
.default-content-section > hr,
.tag-main-section > hr,
.tag-entries-section > hr,
.recent-section > hr,
.related-section > hr {
  grid-column: 1 / -1;
}

.page-content-body,
.article-body,
.privacy-body {
  grid-column: 1;
  font-size: 1rem;
  line-height: 1.8;
  color: var(--ink);
}

.page-content-body h2,
.page-content-body h3 {
  margin-top: 28px;
  margin-bottom: 10px;
}

.page-content-body p { margin-bottom: 16px; }
.page-content-body ul, .page-content-body ol {
  padding-left: 20px;
  margin-bottom: 16px;
  list-style: disc;
}
.page-content-body ol { list-style: decimal; }

/* ===== 侧边 aside ===== */
.content-aside,
.sidebar-related,
.sidebar-tags,
.sidebar-cats,
.sidebar-legal,
.sidebar-default {
  grid-column: 2;
  grid-row: 3;
  padding: 16px;
  background: var(--bg-alt);
  border: 1px solid var(--border-light);
  border-radius: var(--radius);
  align-self: start;
  position: sticky;
  top: 100px;
}

.content-aside h3,
.sidebar-related h3,
.sidebar-tags h3,
.sidebar-cats h3,
.sidebar-legal h3,
.sidebar-default h3 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink-muted);
  margin-bottom: 10px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border);
}

.sidebar-related ul,
.sidebar-cats ul,
.sidebar-legal ul,
.sidebar-default ul {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 16px;
}

.sidebar-related ul li a,
.sidebar-cats ul li a,
.sidebar-legal ul li a,
.sidebar-default ul li a {
  display: block;
  font-size: 0.82rem;
  padding: 4px 0;
  text-decoration: none;
  color: var(--ink-light);
  border-bottom: 1px solid var(--border-light);
}
.sidebar-related ul li a:hover,
.sidebar-cats ul li a:hover,
.sidebar-legal ul li a:hover,
.sidebar-default ul li a:hover {
  color: var(--ink);
}

.related-list li a { font-size: 0.82rem; }

/* ===== 标签药丸 ===== */
.tag-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 2px;
  font-size: 0.75rem;
  font-weight: 500;
  text-decoration: none;
  color: var(--ink-light);
  min-height: 28px;
}
.tag-pill:hover, .tag-pill--active {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}

/* ===== 分类卡片网格 ===== */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
  grid-column: 1 / -1;
  margin-top: 16px;
}

.cat-card {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.cat-card__link {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 20px;
  text-decoration: none;
  height: 100%;
}
.cat-card__link:hover { background: var(--border-light); }

.cat-card__title {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 700;
  color: var(--ink);
  line-height: 1.3;
}

.cat-card__meta {
  font-size: 0.72rem;
  color: var(--ink-muted);
  font-weight: 600;
  letter-spacing: 0.05em;
}

.cat-card__desc {
  font-size: 0.82rem;
  color: var(--ink-light);
  line-height: 1.5;
  flex: 1;
}

.cat-card__arrow {
  font-size: 0.9rem;
  color: var(--ink-muted);
  margin-top: 8px;
}

/* ===== 条目卡片 ===== */
.entry-card {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.entry-card__link {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 16px;
  text-decoration: none;
}
.entry-card__link:hover { background: var(--border-light); }

.entry-card__title {
  font-family: var(--font-heading);
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--ink);
}

.entry-card__desc {
  font-size: 0.8rem;
  color: var(--ink-light);
  line-height: 1.5;
}

.entry-card__date {
  font-size: 0.72rem;
  color: var(--ink-muted);
}

.entry-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
  grid-column: 1 / -1;
}

.entry-cards-mobile { display: none; }

/* ===== 表格 ===== */
.table-figure {
  grid-column: 1 / -1;
  overflow-x: auto;
}

.entry-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
}

.entry-table th {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  padding: 10px 14px;
  text-align: left;
  font-weight: 600;
  font-size: 0.78rem;
  letter-spacing: 0.05em;
  color: var(--ink-muted);
}

.entry-table td {
  border: 1px solid var(--border-light);
  padding: 10px 14px;
  vertical-align: top;
  line-height: 1.5;
}

.entry-table tbody tr:nth-child(even) td { background: var(--bg-alt); }
.entry-table tbody tr:hover td { background: var(--border-light); }

.entry-table a {
  text-decoration: none;
  font-weight: 500;
  color: var(--ink);
}
.entry-table a:hover { text-decoration: underline; }

.entry-date, .entry-list__date { font-size: 0.78rem; color: var(--ink-muted); white-space: nowrap; }

.full-table .entry-desc { font-size: 0.82rem; color: var(--ink-light); }

/* ===== 页面 hero 小尺寸（category/entry/about/privacy） ===== */
.page-hero-section,
.entry-header-section,
.about-header-section,
.privacy-header-section,
.tag-header-section,
.default-header-section {
  display: flex;
  align-items: flex-start;
  gap: 24px;
  padding: 32px 0 0;
  margin-bottom: 0;
  border-bottom: 1px solid var(--border);
  padding-bottom: 24px;
}

.page-hero-aside,
.entry-meta-aside,
.about-intro-aside,
.privacy-intro-aside,
.default-intro-aside {
  flex: 1;
}

.page-hero-figure,
.entry-hero-figure,
.about-figure,
.privacy-figure,
.tag-header-figure,
.default-figure {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.cat-count-badge,
.about-icon,
.privacy-icon,
.tag-icon,
.default-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px; height: 64px;
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 700;
  background: var(--bg-alt);
  color: var(--ink);
}

.entry-hero-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 80px; height: 80px;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  font-size: 2rem;
  color: var(--ink-muted);
  background: var(--bg-alt);
}

.hero-img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid var(--border);
}

.page-eyebrow {
  display: block;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  color: var(--ink-muted);
  text-transform: uppercase;
  margin-bottom: 10px;
}

.page-desc {
  font-size: 0.95rem;
  color: var(--ink-light);
  line-height: 1.7;
  margin-top: 10px;
}

.page-meta, .entry-meta-row {
  font-size: 0.78rem;
  color: var(--ink-muted);
  margin-top: 10px;
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.entry-desc { font-size: 0.9rem; color: var(--ink-light); margin-top: 8px; }
.entry-h1 { margin-bottom: 8px; }

/* ===== 面包屑 ===== */
.breadcrumb {
  font-size: 0.78rem;
  color: var(--ink-muted);
  margin-bottom: 16px;
  grid-column: 1 / -1;
}
.breadcrumb a { color: var(--ink-muted); }
.breadcrumb a:hover { color: var(--ink); }

/* ===== tag 页 ===== */
.tag-header-section {
  flex-direction: row-reverse;
  justify-content: space-between;
}

.tag-filter-aside {
  flex: 0 0 auto;
  max-width: 280px;
}
.tag-filter-aside h3 {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink-muted);
  margin-bottom: 10px;
}

.tag-h1 { margin-bottom: 12px; }

/* ===== 近期/相关 figure ===== */
.recent-section .table-figure,
.tag-entries-section .table-figure {
  grid-column: 1 / -1;
}

.related-figure,
.about-links-figure {
  grid-column: 1 / -1;
}

/* ===== 页脚（footer > article×n） ===== */
.site-footer {
  background: var(--bg-alt);
  border-top: 2px solid var(--ink);
  padding: 40px 32px 0;
  display: grid;
  grid-template-columns: 1fr 1fr 1.2fr;
  grid-template-rows: auto auto;
  gap: 32px 40px;
  max-width: 100%;
}

.footer-nav-section,
.footer-tags-section,
.footer-contact-section {
  /* direct children sections of footer */
}

.footer-section-title {
  font-family: var(--font-heading);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--ink-muted);
  margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

.footer-nav-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.footer-nav-list li a {
  font-size: 0.82rem;
  text-decoration: none;
  color: var(--ink-light);
  display: block;
  padding: 4px 0;
  min-height: 32px;
  display: flex;
  align-items: center;
}
.footer-nav-list li a:hover { color: var(--ink); }

.footer-tags { display: flex; flex-wrap: wrap; gap: 8px; }

.footer-desc { font-size: 0.82rem; color: var(--ink-light); margin-bottom: 14px; line-height: 1.6; }

.subscribe-form {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.sub-input {
  flex: 1;
  min-width: 160px;
  padding: 9px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg);
  font-family: inherit;
  font-size: 0.82rem;
  color: var(--ink);
  min-height: 40px;
}
.sub-input:focus { outline: 2px solid var(--ink); outline-offset: 1px; }

.sub-btn {
  padding: 9px 18px;
  background: var(--ink);
  color: var(--bg);
  border: none;
  border-radius: var(--radius);
  font-size: 0.82rem;
  font-weight: 600;
  min-height: 40px;
}
.sub-btn:hover { background: var(--accent-hover); }

.footer-bottom {
  grid-column: 1 / -1;
  text-align: center;
  padding: 20px 0;
  border-top: 1px solid var(--border);
  font-size: 0.78rem;
  color: var(--ink-muted);
  line-height: 2;
}

.footer-links a {
  color: var(--ink-muted);
  margin: 0 4px;
}
.footer-links a:hover { color: var(--ink); }

/* ===== stagger 动画（prefers-reduced-motion 关闭） ===== */
@media (prefers-reduced-motion: no-preference) {
  .cat-card {
    animation: fadeUp 0.3s ease both;
  }
  .cat-card:nth-child(1) { animation-delay: 0.05s; }
  .cat-card:nth-child(2) { animation-delay: 0.10s; }
  .cat-card:nth-child(3) { animation-delay: 0.15s; }
  .cat-card:nth-child(4) { animation-delay: 0.20s; }
  .cat-card:nth-child(5) { animation-delay: 0.25s; }
  .cat-card:nth-child(6) { animation-delay: 0.30s; }

  .entry-card {
    animation: fadeUp 0.3s ease both;
  }
  .entry-card:nth-child(1) { animation-delay: 0.04s; }
  .entry-card:nth-child(2) { animation-delay: 0.08s; }
  .entry-card:nth-child(3) { animation-delay: 0.12s; }
  .entry-card:nth-child(4) { animation-delay: 0.16s; }

  @keyframes fadeUp {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }
}

/* ===== 响应式 ===== */
@media (max-width: 1024px) {
  .site-nav-aside { display: none; }
  .page-wrap { margin-left: 0; }
  .nav-toggle { display: flex; align-items: center; justify-content: center; }
  .mobile-nav:not([hidden]) { display: block; }

  .site-footer {
    grid-template-columns: 1fr 1fr;
  }
  .footer-contact-section { grid-column: 1 / -1; }
}

@media (max-width: 768px) {
  main { padding: 0 16px 32px; }
  .header-inner { padding: 10px 16px; }
  .sticky-anchor-bar { padding: 0 16px; overflow-x: auto; white-space: nowrap; }

  .hero-section {
    flex-direction: column;
    align-items: flex-start;
    min-height: auto;
    padding: 24px 0;
  }
  .hero-aside { text-align: left; max-width: 100%; }
  .hero-actions { justify-content: flex-start; }

  .content-section,
  .entries-section,
  .entry-content-section,
  .entry-nav-section,
  .about-content-section,
  .about-links-section,
  .privacy-content-section,
  .default-content-section,
  .tag-main-section,
  .tag-entries-section,
  .recent-section,
  .related-section {
    grid-template-columns: 1fr;
  }

  .content-aside,
  .sidebar-related,
  .sidebar-tags,
  .sidebar-cats,
  .sidebar-legal,
  .sidebar-default {
    grid-column: 1;
    grid-row: auto;
    position: static;
  }

  .page-content-body,
  .article-body,
  .privacy-body {
    grid-column: 1;
  }

  .page-hero-section,
  .entry-header-section,
  .about-header-section,
  .privacy-header-section,
  .tag-header-section,
  .default-header-section {
    flex-direction: column;
  }

  .tag-header-section { flex-direction: column; }
  .tag-filter-aside { max-width: 100%; }

  .site-footer {
    grid-template-columns: 1fr;
    padding: 24px 16px 0;
    gap: 24px;
  }
  .footer-contact-section { grid-column: 1; }

  .entry-cards-mobile { display: block; }
  .entry-cards-mobile .entry-cards-grid { grid-template-columns: 1fr; }
  .table-figure .full-table { display: none; }
}

@media (max-width: 480px) {
  h1 { font-size: 1.4rem; }
  h2 { font-size: 1.1rem; }

  .cat-grid { grid-template-columns: 1fr; }
  .entry-cards-grid { grid-template-columns: 1fr; }

  .hero-icon { width: 56px; height: 56px; font-size: 1.5rem; }

  .subscribe-form { flex-direction: column; }
  .sub-input { min-width: 100%; }
}
