
:root {
  --bg: #0f1115;
  --bg-card: #1a1d24;
  --bg-card-hover: #21252e;
  --border: #2a2e38;
  --text: #e8e9ec;
  --text-dim: #9096a3;
  --accent: #ff6b4a;
  --accent-dim: #ff6b4a99;
  --op-bg: #241a17;
}

* { box-sizing: border-box; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: "Hiragino Kaku Gothic ProN", "Yu Gothic", "Meiryo", -apple-system, sans-serif;
  margin: 0;
  line-height: 1.7;
}

header {
  position: sticky; top: 0; z-index: 10;
  background: rgba(15, 17, 21, 0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--border);
  padding: 14px 20px;
}
header a {
  color: var(--text);
  text-decoration: none;
  font-weight: 800;
  font-size: 1.25em;
  letter-spacing: 0.02em;
}
header a::before { content: "🔥 "; }

main { max-width: 720px; margin: 0 auto; padding: 20px 16px 60px; }

.article-card {
  display: flex; gap: 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 12px;
  margin-bottom: 14px;
  transition: background 0.15s ease, transform 0.15s ease;
  text-decoration: none; color: var(--text);
}
.article-card:hover { background: var(--bg-card-hover); transform: translateY(-1px); }
.article-card .thumb { width: 96px; height: 96px; border-radius: 10px; object-fit: cover; flex-shrink: 0; }
.article-card .thumb-placeholder { width: 96px; height: 96px; border-radius: 10px; flex-shrink: 0; background: var(--op-bg); }
.article-card .card-body { min-width: 0; padding: 4px 6px 4px 0; }
.article-card h2 {
  margin: 0 0 6px; font-size: 1.02em; line-height: 1.5;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.article-card .excerpt {
  margin: 0 0 8px; font-size: 0.85em; color: var(--text-dim); line-height: 1.5;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.article-card .meta { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 0.78em; color: var(--text-dim); }

.badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.85em;
  font-weight: 600;
}
.badge-category { background: #2a2e38; color: var(--text-dim); }
.badge-replies { background: var(--accent); color: #1a0f0a; }

.thread-title { font-size: 1.5em; font-weight: 800; margin: 4px 0 10px; line-height: 1.5; }
.thread-meta { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; color: var(--text-dim); font-size: 0.85em; margin-bottom: 24px; }
.thread-meta a { color: var(--accent); }
.back-link { display: inline-block; color: var(--text-dim); text-decoration: none; font-size: 0.9em; margin-bottom: 16px; }
.back-link:hover { color: var(--text); }

.res {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 16px;
  margin-bottom: 10px;
}
.res .res-header { font-size: 0.82em; margin-bottom: 6px; display: flex; gap: 8px; align-items: baseline; }
.res .res-number { color: var(--accent); font-weight: 800; }
.res .res-name { color: #7fd4a8; font-weight: 700; }
.res .res-text { white-space: pre-wrap; word-break: break-word; }
.op {
  border: 2px solid var(--accent);
  background: var(--op-bg);
  padding: 16px 18px;
}
.op .op-badge {
  display: inline-block; background: var(--accent); color: #1a0f0a;
  font-size: 0.75em; font-weight: 800; padding: 2px 8px; border-radius: 999px;
  margin-right: 8px;
}
.op .res-text { font-size: 1.05em; }

.res.highlight { border-left: 3px solid #ff3b3b; background: var(--bg-card); }
.res.highlight .res-text { color: #ff6b6b; font-weight: 700; }

.share-row { display: flex; justify-content: flex-end; margin-bottom: 14px; }
.share-button {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 999px;
  padding: 8px 16px; color: var(--text); text-decoration: none; font-size: 0.85em; font-weight: 600;
  transition: background 0.15s ease;
}
.share-button:hover { background: var(--bg-card-hover); }

.related-section { margin-top: 32px; }
.related-section h3 { font-size: 1.05em; margin-bottom: 12px; color: var(--text-dim); }

.pagination { display: flex; justify-content: space-between; align-items: center; margin-top: 20px; }
.pagination .page-link {
  color: var(--text); text-decoration: none; font-weight: 700; font-size: 0.9em;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 999px;
  padding: 8px 18px;
}
.pagination .page-link:hover { background: var(--bg-card-hover); }
.pagination .page-current { color: var(--text-dim); font-size: 0.85em; }

.link-card {
  display: flex; flex-direction: column;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 10px;
  overflow: hidden; text-decoration: none; color: var(--text); margin-bottom: 14px;
  transition: background 0.15s ease;
}
.link-card:hover { background: var(--bg-card-hover); }
.link-card img { width: 100%; height: 320px; object-fit: cover; display: block; }
.link-card .link-card-body { padding: 12px 16px; }
.link-card .link-card-title { font-size: 0.95em; line-height: 1.5; margin-bottom: 4px;
  overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.link-card .link-card-domain { font-size: 0.78em; color: var(--text-dim); }

footer { text-align: center; color: var(--text-dim); font-size: 0.8em; margin: 40px 0 20px; }
.footer-nav {
  margin-bottom: 8px;
  display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 12px;
}
.footer-nav a { color: var(--text-dim); text-decoration: none; white-space: nowrap; }
.footer-nav a:hover { color: var(--text); }

.static-page h1 { font-size: 1.4em; margin-bottom: 16px; }
.static-page h2 { font-size: 1.1em; margin: 24px 0 8px; }
.static-page p, .static-page li { color: var(--text-dim); }
.static-page a { color: var(--accent); }
.cta-button {
  display: inline-block; margin-top: 12px; padding: 10px 20px;
  background: var(--accent); color: #1a0f0a; border-radius: 999px;
  text-decoration: none; font-weight: 700;
}
