:root {
  --bg: #0f1115;
  --card: #171b22;
  --text: #e8eaf0;
  --muted: #9aa3b2;
  --accent: #5b8cff;
  --tag: #232a36;
  --border: #262d3a;
}
* { box-sizing: border-box; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font-family: "Hiragino Kaku Gothic ProN", "Noto Sans JP", system-ui, sans-serif;
}
.container { max-width: 1080px; margin: 0 auto; padding: 32px 20px 64px; }
header.top { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; }
header.top a { color: var(--muted); font-size: 14px; }
h1 { margin: 0 0 8px; font-size: 32px; }
.subtitle { color: var(--muted); margin: 0 0 24px; }
#label-buttons { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 24px; }
.filter-btn {
  border: 1px solid var(--border); background: transparent; color: var(--text);
  padding: 8px 14px; border-radius: 999px; cursor: pointer; font-size: 14px;
}
.filter-btn.active, .filter-btn:hover { background: var(--accent); border-color: var(--accent); color: #fff; }
.filter-btn .count { opacity: .7; font-size: 12px; margin-left: 6px; }
#portfolio-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 20px; }
.project-card {
  background: var(--card); border: 1px solid var(--border); border-radius: 14px;
  overflow: hidden; display: flex; flex-direction: column;
}
.slider { position: relative; aspect-ratio: 16/9; background: #000; overflow: hidden; }
.slider img { width: 100%; height: 100%; object-fit: cover; display: none; }
.slider img.visible { display: block; }
.slider button.nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  background: rgba(0,0,0,.5); color: #fff; border: 0; border-radius: 50%;
  width: 32px; height: 32px; cursor: pointer; font-size: 16px;
}
.slider .prev { left: 8px; } .slider .next { right: 8px; }
.slider .dots { position: absolute; bottom: 8px; left: 0; right: 0; display: flex; justify-content: center; gap: 6px; }
.slider .dots span { width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,.4); }
.slider .dots span.on { background: #fff; }
.no-image { display: flex; align-items: center; justify-content: center; height: 100%; color: var(--muted); }
.body { padding: 16px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.body h2 { margin: 0; font-size: 18px; }
.body p.desc { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.7; white-space: pre-wrap; }
.body a.link { color: var(--accent); font-size: 14px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; }
.tag { background: var(--tag); border: 1px solid var(--border); font-size: 12px; padding: 4px 10px; border-radius: 999px; }
.empty, .error { color: var(--muted); padding: 24px; text-align: center; }
