/* blog_ha15 — inspired by Z-BlogPHP theme ha15 */
:root {
  --primary: #0188fb;
  --text: #333;
  --muted: #999;
  --bg: #f6f8f9;
  --card: #fff;
  --line: #eee;
  --wrap: 1400px;
}
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font: 14px/1.7 "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", Tahoma, Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
}
a { color: var(--primary); text-decoration: none; transition: color .15s linear; }
a:hover { color: #006fd1; }
img { max-width: 100%; height: auto; border: 0; vertical-align: middle; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4 { margin: 0; font-weight: 500; }

.wrapper { background: var(--bg); min-height: 100vh; }
.wrap { width: min(92%, var(--wrap)); margin: 0 auto; }

/* header */
.header {
  background: #fff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, .06);
  position: sticky;
  top: 0;
  z-index: 50;
}
.head-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 70px;
  gap: 16px;
}
.header .logo {
  display: flex;
  align-items: center;
  height: 70px;
  flex-shrink: 0;
}
.header .logo img {
  height: 48px;
  width: auto;
  max-width: 220px;
  object-fit: contain;
}
.header .name a {
  font-size: 26px;
  color: #222;
  font-weight: 600;
  letter-spacing: .02em;
}
.menu ul { display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: center; }
.menu a { color: #333; font-size: 15px; padding: 8px 0; display: inline-block; }
.menu a:hover, .menu a.active { color: var(--primary); }
.menuico {
  display: none;
  width: 28px; height: 22px;
  cursor: pointer;
  flex-direction: column;
  justify-content: space-between;
}
.menuico span { display: block; height: 2px; background: #333; border-radius: 1px; }

/* banner */
.banner {
  margin-bottom: 28px;
  padding: 88px 18px 78px;
  color: #fff;
  text-align: center;
  background: #3a7bd5 center/cover no-repeat;
  position: relative;
}
.banner::before {
  content: "";
  position: absolute; inset: 0;
  background: rgba(0, 0, 0, .28);
}
.banner .wrap { position: relative; z-index: 1; }
.banner h2 {
  margin: 0;
  font-size: clamp(22px, 4vw, 36px);
  text-shadow: 0 1px 6px rgba(0, 0, 0, .35);
}
.banner h2::after {
  content: "";
  display: block;
  width: 40px; height: 2px;
  background: #fff;
  margin: 18px auto 0;
  opacity: .85;
}
.banner.thin { padding: 56px 18px 48px; }
.banner-desc { margin: 12px 0 0; opacity: .9; font-size: 14px; }

/* layout */
.layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 28px;
  align-items: start;
  padding-bottom: 40px;
}
.content { min-width: 0; }
.block, .block-panel, .post-single {
  background: var(--card);
  border-radius: 4px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, .06);
}

/* posts */
.post {
  padding: 28px 30px;
  border-bottom: 1px solid var(--line);
}
.post:last-child { border-bottom: 0; }
.post h2 { font-size: 22px; line-height: 1.4; margin-bottom: 10px; }
.post h2 a { color: #222; }
.post h2 a:hover { color: var(--primary); }
.post .info {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 14px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
}
.post .info .cate { color: var(--primary); }
.postimg { margin: 0 0 14px; overflow: hidden; border-radius: 3px; }
.postimg img { width: 100%; max-height: 320px; object-fit: cover; display: block; }
.intro {
  color: #666;
  font-size: 14px;
  line-height: 1.8;
  margin-bottom: 16px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.readmore {
  display: inline-block;
  padding: 8px 18px;
  border: 1px solid var(--primary);
  color: var(--primary);
  border-radius: 3px;
  font-size: 13px;
}
.readmore:hover { background: var(--primary); color: #fff; }
.readmore.ghost { border-color: #ccc; color: #666; margin-left: 8px; }
.readmore.ghost:hover { background: #666; color: #fff; border-color: #666; }

.post-single { padding: 32px 36px 40px; }
.post-title { font-size: 28px; line-height: 1.35; margin: 8px 0 14px; color: #222; }
.crumb { font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.crumb a { color: var(--muted); }
.crumb a:hover { color: var(--primary); }
.post-body { margin-top: 22px; font-size: 15px; line-height: 1.9; color: #444; }
.rich-body h2, .rich-body h3 { margin: 1.4em 0 .6em; color: #222; }
.rich-body p { margin: 0 0 1em; }
.rich-body img { border-radius: 3px; margin: 8px 0; }
.rich-body pre, .rich-body code {
  font-family: Consolas, "Courier New", monospace;
  background: #f5f7fa;
}
.rich-body pre {
  padding: 14px 16px;
  overflow: auto;
  border-radius: 4px;
  border: 1px solid #e8ecf0;
}
.rich-body a { border-bottom: 1px dashed rgba(1, 136, 251, .35); }

/* sidebar */
.sidebar .widget {
  background: var(--card);
  box-shadow: 0 1px 2px rgba(0, 0, 0, .06);
  border-radius: 4px;
  margin-bottom: 20px;
  overflow: hidden;
}
.widget-title {
  margin: 0;
  padding: 14px 18px;
  font-size: 15px;
  border-bottom: 1px solid var(--line);
  position: relative;
}
.widget-title::before {
  content: "";
  position: absolute;
  left: 0; top: 14px; bottom: 14px;
  width: 3px;
  background: var(--primary);
  border-radius: 0 2px 2px 0;
}
.widget-list { padding: 8px 0; }
.widget-list li a {
  display: block;
  padding: 10px 18px;
  color: #444;
  border-bottom: 1px dashed #f0f0f0;
}
.widget-list li:last-child a { border-bottom: 0; }
.widget-list li a:hover, .widget-list li a.active { color: var(--primary); background: #f8fbff; }
.widget-list li.child a { padding-left: 28px; font-size: 13px; color: #666; }

/* pager */
.pager, .pagebar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  padding: 22px 0 8px;
}
.pager a, .pager span, .pagebar a, .pagebar span {
  min-width: 36px;
  height: 36px;
  line-height: 36px;
  text-align: center;
  padding: 0 10px;
  background: #fff;
  border: 1px solid #e5e5e5;
  border-radius: 3px;
  color: #555;
}
.pager a:hover, .pagebar a:hover,
.pager .current, .pager .active, .pagebar .current {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

/* footer */
.friend-links {
  margin-bottom: 16px;
  text-align: left;
  color: #666;
  font-size: 13px;
}
.friend-links strong { margin-right: 8px; color: #444; }
.link-list {
  display: inline;
  list-style: none;
  margin: 0;
  padding: 0;
}
.link-list .link-item {
  display: inline;
  margin-right: 12px;
}
.link-list a { color: #666; }
.link-list a:hover { color: var(--primary); }
.footer .copy { margin: 0 0 6px; }
.footer a { color: #666; }
.footer a:hover { color: var(--primary); }
.powered { margin: 0; color: #bbb; font-size: 12px; }

/* misc */
.error-404 {
  text-align: center;
  background: #fff;
  margin: 40px 0;
  padding: 60px 24px;
  border-radius: 4px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, .06);
}
.error-code {
  font-size: 72px;
  font-weight: 700;
  color: var(--primary);
  line-height: 1;
  margin-bottom: 12px;
}
.sitemap-wrap { padding: 28px 32px; margin: 0 0 20px; }
.sitemap-xml-link { text-align: center; padding-bottom: 40px; color: #888; }

@media (max-width: 900px) {
  .layout { grid-template-columns: 1fr; }
  .menuico { display: flex; }
  .menu {
    display: none;
    position: absolute;
    left: 0; right: 0; top: 70px;
    background: #fff;
    box-shadow: 0 8px 16px rgba(0, 0, 0, .08);
    padding: 12px 4%;
  }
  .nav-toggle:checked ~ .menu { display: block; }
  .menu ul { flex-direction: column; align-items: flex-start; }
  .header { position: relative; }
  .post, .post-single { padding: 22px 18px; }
  .banner { padding: 64px 16px 56px; }
}
