/* 第二版 母狗园站点样式（清新扁平风） */

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

html {
  font-size: 16px;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  background: #f4f7fb;
  color: #222;
  line-height: 1.7;
}

:root {
  --primary: #00a98f;      /* 蓝绿调，清爽专业 */
  --primary-dark: #008874;
  --accent: #ffc857;       /* 柔和黄色，做点缀 */
  --bg-card: #ffffff;
  --border: #e0e4ec;
  --muted: #767b8a;
}

a {
  color: var(--primary-dark);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.layout-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* 顶部区域 */
.topbar {
  background: #ffffff;
  border-bottom: 1px solid var(--border);
}

.topbar-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0.75rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.brand-logo {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: radial-gradient(circle at 30% 30%, #fff, var(--primary));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 700;
  font-size: 0.9rem;
}

.brand-text {
  display: flex;
  flex-direction: column;
}

.brand-text strong {
  font-size: 1.1rem;
  letter-spacing: 0.06em;
}

.brand-text span {
  font-size: 0.8rem;
  color: var(--muted);
}

.nav-main {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.nav-main a {
  font-size: 0.9rem;
  padding: 0.35rem 0.8rem;
  border-radius: 999px;
  border: 1px solid transparent;
  color: #333;
}

.nav-main a:hover {
  border-color: var(--border);
  background: #f4f7fb;
  text-decoration: none;
}

.nav-main a.is-active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

/* 首页 Hero */
.hero {
  background: linear-gradient(130deg, #e3f6f3, #fdf6e4);
  border-bottom: 1px solid var(--border);
}

.hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1.8rem 1rem 1.6rem;
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 1.5rem;
  align-items: center;
}

.hero-title {
  font-size: 1.95rem;
  margin-bottom: 0.4rem;
}

.hero-sub {
  font-size: 0.96rem;
  color: #444;
  margin-bottom: 0.8rem;
}

.hero-keywords {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.hero-chip {
  font-size: 0.8rem;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  background: #ffffff;
  border: 1px dashed rgba(0, 169, 143, 0.35);
  color: var(--primary-dark);
}

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

.btn-main {
  display: inline-block;
  padding: 0.6rem 1.3rem;
  border-radius: 999px;
  background: var(--primary);
  color: #fff;
  font-size: 0.95rem;
  border: none;
  cursor: pointer;
  box-shadow: 0 7px 18px rgba(0, 169, 143, 0.3);
}

.btn-main:hover {
  background: var(--primary-dark);
}

.hero-actions small {
  font-size: 0.8rem;
  color: var(--muted);
}

.hero-visual {
  display: flex;
  justify-content: flex-end;
}

.hero-visual-card {
  width: 100%;
  max-width: 340px;
  background: #ffffff;
  border-radius: 1.4rem;
  padding: 0.8rem 0.8rem 1rem;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.12);
}

.hero-visual-card img {
  width: 100%;
  border-radius: 1.1rem;
  margin-bottom: 0.6rem;
}

.hero-visual-meta {
  font-size: 0.8rem;
  color: var(--muted);
}

.hero-visual-meta strong {
  display: block;
  color: #333;
  margin-bottom: 0.15rem;
}

/* 主内容布局 */
.main {
  flex: 1;
}

.main-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1.6rem 1rem 2.2rem;
  display: grid;
  grid-template-columns: 3fr 1.3fr;
  gap: 1.6rem;
}

.card {
  background: var(--bg-card);
  border-radius: 1rem;
  border: 1px solid var(--border);
  padding: 1.1rem 1.2rem;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.card + .card {
  margin-top: 1rem;
}

.card-title {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.home-body p {
  font-size: 0.95rem;
  margin-bottom: 0.75rem;
  text-indent: 2em;
}

.home-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.9rem;
  margin-top: 0.6rem;
}

.home-feature {
  background: #f8fafc;
  border-radius: 0.75rem;
  padding: 0.7rem 0.8rem;
  border: 1px dashed #d3dae7;
}

.home-feature h3 {
  font-size: 0.95rem;
  margin-bottom: 0.2rem;
}

.home-feature p {
  font-size: 0.82rem;
  color: var(--muted);
  margin: 0;
  text-indent: 0;
}

/* 列表页 */
.section-header {
  margin-bottom: 0.6rem;
}

.section-header p {
  font-size: 0.9rem;
  color: var(--muted);
}

.post-list {
  list-style: none;
}

.post-item {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 0.8rem;
  padding: 0.55rem 0;
  border-bottom: 1px solid #eef1f6;
}

.post-thumb img {
  width: 100%;
  height: 100px;
  object-fit: cover;
  border-radius: 0.7rem;
}

.post-meta {
  font-size: 0.8rem;
  color: var(--muted);
  margin-bottom: 0.1rem;
}

.post-title {
  font-size: 0.98rem;
  margin-bottom: 0.15rem;
}

.post-title a {
  color: #222;
  text-decoration: none;
}

.post-title a:hover {
  color: var(--primary-dark);
  text-decoration: underline;
}

.post-desc {
  font-size: 0.85rem;
  color: #4b4f5f;
}

/* 文章页 */
.article-title {
  font-size: 1.45rem;
  margin-bottom: 0.35rem;
}

.article-meta {
  font-size: 0.8rem;
  color: var(--muted);
  margin-bottom: 0.6rem;
}

.article-cover {
  margin-bottom: 0.9rem;
}

.article-cover img {
  width: 100%;
  border-radius: 0.9rem;
}

.article-content p {
  font-size: 0.95rem;
  margin-bottom: 0.8rem;
  text-indent: 2em;
}

.article-content h2 {
  font-size: 1.08rem;
  margin: 0.8rem 0 0.4rem;
}

/* 侧边栏 */
.side-block + .side-block {
  margin-top: 1rem;
}

.side-title {
  font-size: 0.98rem;
  margin-bottom: 0.4rem;
}

.side-list {
  list-style: none;
  font-size: 0.88rem;
}

.side-list li + li {
  margin-top: 0.35rem;
}

.side-list a {
  color: #333;
}

.side-list a:hover {
  color: var(--primary-dark);
}

/* 底部 */
.footer {
  border-top: 1px solid var(--border);
  background: #ffffff;
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0.9rem 1rem 1.2rem;
  font-size: 0.8rem;
  color: var(--muted);
  text-align: center;
}

/* 响应式 */
@media (max-width: 960px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }
  .hero-visual {
    justify-content: center;
  }
  .main-inner {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  html {
    font-size: 15px;
  }
  .topbar-inner {
    flex-direction: column;
    align-items: flex-start;
  }
  .nav-main {
    width: 100%;
  }
  .post-item {
    grid-template-columns: 1fr;
  }
  .post-thumb img {
    height: 160px;
  }
  .home-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 480px) {
  .home-grid {
    grid-template-columns: 1fr;
  }
}

