/* ── SoloCM Blog — Higan/Cactus Style ── */

:root {
  --bg: #F5F0EB;
  --text: #363533;
  --meta: #666666;
  --meta-light: #999999;
  --link: #2BBC8A;
  --tag: #D44375;
  --border: #E5E0DA;
  --code-bg: #EDE8E3;
  --card-hover: #EFEAE4;
  --font-mono: 'IBM Plex Mono', 'Menlo', 'Meslo LG', 'Cascadia Code', monospace;
  --font-sans: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
}

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

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-mono);
  line-height: 1.7;
  min-height: 100vh;
}

/* ── Layout ── */
.container {
  max-width: 680px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ── Header ── */
.site-header {
  padding: 48px 0 24px;
  text-align: center;
}

.avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: var(--link);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 16px;
  user-select: none;
}

.site-title {
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--text);
  text-decoration: none;
  display: block;
}
.site-title:hover { color: var(--link); }

.site-nav {
  margin-top: 12px;
  display: flex;
  justify-content: center;
  gap: 24px;
}

.site-nav a {
  font-size: 13px;
  font-weight: 500;
  color: var(--meta);
  text-decoration: none;
  transition: color 0.15s;
}
.site-nav a:hover,
.site-nav a.active { color: var(--link); }

/* ── About ── */
.about {
  padding: 0 0 24px;
}

.about p {
  font-size: 13px;
  color: var(--meta);
  line-height: 1.8;
}

/* ── Social ── */
.social {
  padding: 0 0 32px;
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 11px;
}

.social-label {
  color: var(--meta-light);
  font-weight: 400;
  margin-right: 4px;
}

.social a {
  color: var(--meta);
  font-weight: 500;
  text-decoration: none;
  transition: color 0.15s;
}
.social a:hover { color: var(--link); }

/* ── Divider ── */
.divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 0;
}

/* ── Writing Section ── */
.writing {
  padding: 24px 0;
}

.writing-title {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--text);
  margin-bottom: 16px;
  text-transform: uppercase;
}

.post-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.post-item {
  display: flex;
  align-items: baseline;
  gap: 12px;
  padding: 4px 0;
  flex-wrap: wrap;
}

.post-date {
  font-size: 12px;
  color: var(--meta-light);
  white-space: nowrap;
  min-width: 80px;
}

.post-cat {
  font-size: 11px;
  font-weight: 500;
  color: var(--tag);
  text-decoration: none;
  white-space: nowrap;
}
.post-cat:hover { text-decoration: underline; }

.post-title {
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  transition: color 0.15s;
}
.post-title:hover { color: var(--link); }

/* ── Pagination ── */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 16px 0 0;
  font-size: 11px;
}

.pagination a {
  color: var(--meta-light);
  text-decoration: none;
  transition: color 0.15s;
}
.pagination a:hover { color: var(--link); }

.page-num {
  font-weight: 500;
  color: var(--text);
}

/* ── Footer ── */
.site-footer {
  padding: 24px 0 48px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  color: var(--meta-light);
}

.site-footer a {
  color: var(--meta-light);
  text-decoration: none;
  transition: color 0.15s;
}
.site-footer a:hover { color: var(--link); }

/* ── Post Content ── */
.post-header {
  padding: 32px 0 8px;
}

.post-header h1 {
  font-size: 22px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.4;
  letter-spacing: 0.5px;
}

.post-meta {
  padding: 8px 0 24px;
  font-size: 12px;
  color: var(--meta-light);
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
}

.post-meta .post-cat {
  font-size: 11px;
}

.post-tags {
  display: flex;
  gap: 8px;
  padding: 0 0 24px;
}

.post-tags a {
  font-size: 10px;
  color: var(--meta);
  text-decoration: none;
  padding: 2px 8px;
  border: 1px solid var(--border);
  border-radius: 3px;
  transition: all 0.15s;
}
.post-tags a:hover {
  color: var(--link);
  border-color: var(--link);
}

.post-body {
  padding: 0 0 48px;
  font-size: 14px;
  line-height: 1.9;
}

.post-body h2 {
  font-size: 18px;
  font-weight: 700;
  margin: 36px 0 12px;
  color: var(--text);
}

.post-body h3 {
  font-size: 15px;
  font-weight: 600;
  margin: 28px 0 10px;
  color: var(--text);
}

.post-body p {
  margin-bottom: 16px;
}

.post-body ul, .post-body ol {
  margin: 0 0 16px 24px;
}

.post-body li {
  margin-bottom: 6px;
}

.post-body a {
  color: var(--link);
  text-decoration: none;
  border-bottom: 1px solid var(--link);
}
.post-body a:hover { opacity: 0.8; }

.post-body code {
  background: var(--code-bg);
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 13px;
}

.post-body pre {
  background: var(--code-bg);
  padding: 16px 20px;
  border-radius: 4px;
  overflow-x: auto;
  margin-bottom: 16px;
  font-size: 13px;
  line-height: 1.6;
}

.post-body pre code {
  background: none;
  padding: 0;
}

.post-body blockquote {
  border-left: 3px solid var(--link);
  padding-left: 16px;
  margin: 0 0 16px;
  color: var(--meta);
  font-style: italic;
}

.post-body img {
  max-width: 100%;
  border-radius: 4px;
}

.post-nav {
  display: flex;
  justify-content: space-between;
  padding: 24px 0 48px;
  font-size: 12px;
}

.post-nav a {
  color: var(--meta);
  text-decoration: none;
  transition: color 0.15s;
}
.post-nav a:hover { color: var(--link); }

/* ── About Page ── */
.page-title {
  font-size: 22px;
  font-weight: 700;
  padding: 32px 0 8px;
  color: var(--text);
}

.page-body {
  padding: 0 0 48px;
  font-size: 14px;
  line-height: 1.9;
}

.page-body p {
  margin-bottom: 16px;
}

/* ── Responsive ── */
@media (max-width: 720px) {
  .container { padding: 0 20px; }
  .site-header { padding: 32px 0 20px; }
  .post-item { flex-direction: column; gap: 2px; }
  .post-date { min-width: unset; }
  .site-footer { flex-direction: column; gap: 8px; text-align: center; }
  .post-nav { flex-direction: column; gap: 8px; }
}
