/*
Theme Name: ZenPress
Theme URI: https://example.com/zenpress
Author: You
Author URI: https://example.com
Description: A clean Typecho theme inspired by the provided reference images (index.png, nr.png). Includes styled Button, Note, Quote, List, and Code Block components.
Version: 1.0.0
*/

/* Base reset and typography */
html { box-sizing: border-box; }
*, *::before, *::after { box-sizing: inherit; }
body {
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen,
    Ubuntu, Cantarell, 'Fira Sans', 'Droid Sans', 'Helvetica Neue', Arial, sans-serif;
  line-height: 1.65;
  color: #1f2937; /* gray-800 */
  background: #f9fafb; /* gray-50 */
}

img { max-width: 100%; height: auto; }
a { color: #2563eb; text-decoration: none; }
a:hover { text-decoration: underline; }

/* Layout */
.zp-container { max-width: 800px; margin: 0 auto; padding: 24px; }
.zp-header { background: #ffffff; border-bottom: 1px solid #e5e7eb; }
.zp-header .zp-container { display: flex; align-items: center; justify-content: space-between; }
.zp-brand { font-weight: 700; font-size: 20px; color: #111827; }
.zp-nav a { margin-left: 16px; color: #374151; }
.zp-main { padding: 24px 0; }
.zp-footer { background: #ffffff; border-top: 1px solid #e5e7eb; color: #6b7280; }

/* Article list */
.zp-post-list { list-style: none; padding: 0; margin: 0; }
.zp-post-item { background: #fff; border: 1px solid #e5e7eb; border-radius: 10px; padding: 20px; margin-bottom: 16px; transition: box-shadow .2s ease; }
.zp-post-item:hover { box-shadow: 0 6px 20px rgba(0,0,0,.06); }
.zp-post-item h2 { margin: 0 0 8px; font-size: 22px; }
.zp-post-meta { color: #6b7280; font-size: 14px; margin-bottom: 8px; }

/* Content */
.zp-article { background: #fff; border: 1px solid #e5e7eb; border-radius: 12px; padding: 28px; }
.zp-article h1 { margin-top: 0; font-size: 28px; }
.zp-article h2 { font-size: 22px; margin-top: 28px; }
.zp-article p { margin: 14px 0; }
.zp-article hr { border: none; border-top: 1px solid #e5e7eb; margin: 28px 0; }

/* Buttons (图1：按钮组件) */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 16px;
  border-radius: 10px;
  border: 1px solid transparent;
  background: #111827;
  color: #fff;
  font-weight: 600;
  transition: transform .05s ease, box-shadow .2s ease, background .2s ease;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 8px 20px rgba(0,0,0,.12); }
.btn:active { transform: translateY(0); box-shadow: 0 2px 8px rgba(0,0,0,.08); }
.btn-primary { background: #2563eb; }
.btn-secondary { background: #6b7280; }
.btn-outline { background: #fff; color: #111827; border-color: #d1d5db; }
.btn-sm { padding: 6px 10px; font-size: 14px; border-radius: 8px; }
.btn-lg { padding: 14px 20px; font-size: 16px; border-radius: 12px; }

/* Note 组件 (图2) */
.note {
  position: relative;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid #e5e7eb;
  background: #f9fafb;
  color: #111827;
}
.note::before {
  content: 'Note';
  position: absolute;
  top: -10px; left: 12px;
  background: #111827; color: #fff;
  padding: 2px 8px; border-radius: 6px; font-size: 12px; font-weight: 700;
}
.note.info { background: #eef2ff; border-color: #c7d2fe; }
.note.info::before { content: 'Info'; background: #3730a3; }
.note.warn { background: #fff7ed; border-color: #fed7aa; }
.note.warn::before { content: 'Warning'; background: #9a3412; }
.note.success { background: #ecfdf5; border-color: #a7f3d0; }
.note.success::before { content: 'Success'; background: #065f46; }

/* 引用 (图3) */
blockquote {
  margin: 18px 0;
  padding: 12px 16px;
  border-left: 4px solid #2563eb;
  background: #f3f4f6;
  color: #374151;
  border-radius: 8px;
}
blockquote p { margin: 0; }

/* 无序列表 (图4) */
.zp-article ul {
  padding-left: 22px;
}
.zp-article ul li {
  margin: 6px 0;
}
.zp-article ul li::marker { color: #2563eb; }

/* 代码块 (nr.png) */
pre, code { font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; }
code { background: #f3f4f6; padding: 2px 6px; border-radius: 6px; }
pre code { background: transparent; padding: 0; }
pre {
  background: #0b1020; /* dark backdrop */
  color: #e5e7eb;
  border-radius: 12px;
  border: 1px solid #111827;
  padding: 16px;
  overflow: auto;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.05);
}
.code-title {
  display: inline-block;
  margin-bottom: 10px;
  font-size: 12px;
  color: #9ca3af;
  background: #111827;
  border: 1px solid #1f2937;
  padding: 4px 10px;
  border-radius: 999px;
}

/* Comments */
.zp-comments { margin-top: 32px; }
.zp-comment { padding: 12px 0; border-bottom: 1px solid #e5e7eb; }
.zp-comment .author { font-weight: 600; }
.zp-comment .meta { color: #6b7280; font-size: 13px; }
.zp-comment-form input, .zp-comment-form textarea {
  width: 100%; padding: 10px 12px; border: 1px solid #d1d5db; border-radius: 10px; background: #fff; margin: 6px 0 12px;
}
.zp-comment-form button { margin-top: 6px; }

/* Utilities */
.mt-1{margin-top:4px}.mt-2{margin-top:8px}.mt-3{margin-top:12px}.mt-4{margin-top:16px}.mt-6{margin-top:24px}.mt-8{margin-top:32px}
.mb-2{margin-bottom:8px}.mb-3{margin-bottom:12px}.mb-4{margin-bottom:16px}.mb-6{margin-bottom:24px}.mb-8{margin-bottom:32px}
.flex{display:flex}.items-center{align-items:center}.justify-between{justify-content:space-between}.gap-2{gap:8px}.gap-3{gap:12px}.gap-4{gap:16px}


