:root {
  --bg: #0f1115;
  --surface: #171a21;
  --surface-2: #1f232c;
  --text: #e7e9ee;
  --text-muted: #9aa3b2;
  --accent: #7aa2ff;
  --accent-2: #b388ff;
  --border: #262b36;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
  --max-width: 760px;
  /* アイコン: 円サイズ・写真のズーム scale（1=等倍、1.15 なら約15%寄り、hugo.toml でも指定可） */
  --avatar-size-header: 32px;
  --avatar-size-hero: 88px;
  --avatar-zoom-header: 1.14;
  --avatar-zoom-hero: 1.1;
  /* 参戦履歴カード（/lives・トップ「最近」共通。ここを変えると一覧の密度がまとめて変わる） */
  --live-card-gap: 6px;
  --live-card-padding-y: 8px;
  --live-card-padding-x: 12px;
  --live-card-radius: 10px;
  --live-card-date-size: 11px;
  --live-card-title-size: 13px;
  --live-card-title-margin-y: 2px;
  --live-card-tour-size: 12px;
  --live-card-tour-margin-bottom: 4px;
  --live-card-meta-size: 12px;
  --live-card-rating-size: 12px;
  --live-card-rating-margin-top: 4px;
  /* トップ「最近のライブ」ブロック全体の余白（任意で調整） */
  --live-recent-block-margin-y: 28px;
  --live-recent-head-margin-bottom: 10px;
  font-family: system-ui, -apple-system, "Segoe UI", "Helvetica Neue",
    "Hiragino Kaku Gothic ProN", "Noto Sans JP", sans-serif;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #fbfbfd;
    --surface: #ffffff;
    --surface-2: #f3f4f8;
    --text: #1a1d24;
    --text-muted: #5c6370;
    --accent: #3d6fe0;
    --accent-2: #7a4dd6;
    --border: #e5e7ee;
    --shadow: 0 4px 18px rgba(20, 25, 40, 0.08);
  }
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  line-height: 1.75;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* Header */
.site-header {
  border-bottom: 1px solid var(--border);
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 10;
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  padding-bottom: 14px;
}

.site-title {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 700;
}

.site-title:hover {
  text-decoration: none;
}

.avatar {
  width: var(--avatar-size-header);
  height: var(--avatar-size-header);
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.04em;
}

.avatar.avatar--photo {
  padding: 0;
  overflow: hidden;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: transparent;
  /* place-items:center だと img がセルいっぱいに伸びず scale が効かない */
  place-items: stretch;
}

.avatar.avatar--photo > .avatar__img {
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  object-fit: cover;
  object-position: center;
  transform: scale(var(--avatar-zoom-header));
  transform-origin: center center;
  border-radius: 50%;
  display: block;
}

.site-nav ul {
  display: flex;
  gap: 18px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav a {
  color: var(--text-muted);
  font-size: 14px;
  padding: 6px 2px;
}

.site-nav a.is-active {
  color: var(--text);
  border-bottom: 2px solid var(--accent);
}

/* Hero (トップページ) */
.hero {
  text-align: center;
  padding: 56px 0 24px;
}

.hero__avatar {
  width: var(--avatar-size-hero);
  height: var(--avatar-size-hero);
  margin: 0 auto 16px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  color: #fff;
  font-size: 36px;
  font-weight: 700;
  box-shadow: var(--shadow);
}

.hero__avatar.hero__avatar--photo {
  padding: 0;
  overflow: hidden;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: transparent;
  box-shadow: var(--shadow);
  place-items: stretch;
}

.hero__avatar.hero__avatar--photo > .avatar__img {
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  object-fit: cover;
  object-position: center;
  transform: scale(var(--avatar-zoom-hero));
  transform-origin: center center;
  border-radius: 50%;
  display: block;
}

.hero__title {
  margin: 0 0 8px;
  font-size: 28px;
  letter-spacing: 0.02em;
}

.hero__lead {
  margin: 0;
  color: var(--text-muted);
}

/* Prose (Markdown 本文) */
.prose {
  padding: 8px 0 32px;
}

.prose h2 {
  margin-top: 2em;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border);
  font-size: 20px;
}

.prose h3 {
  font-size: 17px;
  margin-top: 1.6em;
}

.prose ul,
.prose ol {
  padding-left: 1.3em;
}

.prose code {
  background: var(--surface-2);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.9em;
}

.prose blockquote {
  margin: 1em 0;
  padding: 0.4em 1em;
  border-left: 3px solid var(--accent);
  color: var(--text-muted);
  background: var(--surface-2);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

/* Recent / Live list */
.recent {
  margin: var(--live-recent-block-margin-y) 0 calc(var(--live-recent-block-margin-y) + 8px);
}

.recent__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: var(--live-recent-head-margin-bottom);
}

.recent__head h2 {
  margin: 0;
  font-size: 17px;
}

.recent__more {
  font-size: 13px;
  color: var(--text-muted);
}

.page-head {
  padding: 40px 0 16px;
}

.page-head h1 {
  margin: 0 0 8px;
}

.prose--after-title {
  padding-top: 0;
  padding-bottom: 12px;
}

.gallery-grid {
  list-style: none;
  margin: 8px 0 48px;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
}

.gallery-grid__figure {
  margin: 0;
}

.gallery-grid__link {
  display: block;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow);
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.gallery-grid__link:hover {
  text-decoration: none;
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--accent) 50%, var(--border));
}

.gallery-grid__img {
  width: 100%;
  height: auto;
  vertical-align: middle;
  display: block;
}

.gallery-grid__caption {
  margin: 8px 2px 0;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.4;
}

/* /lives: 参戦履歴 / 参戦予定タブ */
.live-split {
  margin: 8px 0 32px;
}

.live-split__tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 22px;
}

.live-split__tab {
  margin: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 20px 40px;
  min-height: 60px;
  font: inherit;
  font-size: 24px;
  font-weight: 600;
  color: var(--text-muted);
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  cursor: pointer;
  transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.live-split__tab:hover {
  color: var(--text);
  border-color: color-mix(in srgb, var(--accent) 40%, var(--border));
}

.live-split__tab.is-active {
  color: var(--text);
  background: color-mix(in srgb, var(--accent) 18%, var(--surface));
  border-color: color-mix(in srgb, var(--accent) 55%, var(--border));
}

/* /lives: アーティスト絞り込み（チェックボックス） */
.live-split__filter {
  margin: 0 0 20px;
  padding: 0;
  border: none;
  min-width: 0;
}

.live-split__filter-legend {
  padding: 0;
  margin: 0 0 12px;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-muted);
}

.live-split__filter-checks {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  align-items: center;
}

.live-split__filter-check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 10px 14px;
  font: inherit;
  font-size: 16px;
  font-weight: 500;
  color: var(--text);
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 999px;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
  user-select: none;
}

.live-split__filter-check:has(input:focus-visible) {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.live-split__filter-check:has(input:checked) {
  background: color-mix(in srgb, var(--accent) 18%, var(--surface));
  border-color: color-mix(in srgb, var(--accent) 55%, var(--border));
}

.live-split__filter-check:hover {
  border-color: color-mix(in srgb, var(--accent) 40%, var(--border));
}

.live-split__filter-check input {
  width: 1.1em;
  height: 1.1em;
  margin: 0;
  accent-color: var(--accent);
  cursor: pointer;
}

.live-split__filter-check-text {
  line-height: 1.3;
}

.live-list .live-filter-empty {
  grid-column: 1 / -1;
  padding: 1rem 1.25rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 15px;
  list-style: none;
}

.live-split__panel {
  display: none;
}

.live-split__panel.is-active {
  display: block;
}

.live-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--live-card-gap);
}

.live-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--live-card-radius);
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.live-card:hover {
  transform: translateY(-1px);
  border-color: color-mix(in srgb, var(--accent) 60%, var(--border));
}

.live-card a {
  display: block;
  padding: var(--live-card-padding-y) var(--live-card-padding-x);
  color: var(--text);
}

.live-card a:hover {
  text-decoration: none;
}

.live-card__date {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: var(--live-card-date-size);
  color: var(--text-muted);
  letter-spacing: 0.06em;
}

.live-card__title {
  margin: var(--live-card-title-margin-y) 0;
  font-size: var(--live-card-title-size);
  line-height: 1.35;
}

/* ツアー名と会場を同一行（狭い幅では折り返し） */
.live-card__tour-row {
  margin: 0 0 var(--live-card-tour-margin-bottom);
  font-size: var(--live-card-tour-size);
  line-height: 1.4;
  color: var(--text-muted);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.25em 0.5em;
}

.live-card__tour-row .live-card__tour,
.live-card__tour-row .live-card__venue {
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
  color: inherit;
}

.live-card__tour-row .live-card__tour {
  flex: 0 1 auto;
}

.live-card__venue {
  flex: 1 1 auto;
  min-width: 0;
}

.live-card__meta {
  margin: 0;
  color: var(--text-muted);
  font-size: var(--live-card-meta-size);
  line-height: 1.4;
}

.live-card__meta span+span::before {
  content: " · ";
}

.live-card__rating {
  margin: var(--live-card-rating-margin-top) 0 0;
  color: #f5a524;
  letter-spacing: 2px;
  font-size: var(--live-card-rating-size);
}

.empty {
  text-align: center;
  padding: 32px;
  color: var(--text-muted);
  background: var(--surface-2);
  border-radius: var(--radius);
}

/* Single post */
.post {
  padding: 32px 0;
}

.post__back {
  margin: 0 0 16px;
  font-size: 13px;
}

.post__title {
  margin: 0 0 8px;
  font-size: 26px;
  line-height: 1.3;
}

.post__meta {
  margin: 0 0 20px;
  color: var(--text-muted);
  font-size: 13px;
}

.post__facts {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 8px 16px;
  padding: 16px 18px;
  margin: 0 0 24px;
  background: var(--surface-2);
  border-radius: var(--radius);
  font-size: 14px;
}

.post__facts dt {
  color: var(--text-muted);
}

.post__facts dd {
  margin: 0;
}

/* Live extras: setlist / フェスでの見たアーティスト */
.live-extra {
  margin: 0 0 24px;
  padding: 16px 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}

.live-extra__title {
  margin: 0 0 8px;
  font-size: 17px;
  font-weight: 600;
}

.live-extra__lead {
  margin: 0 0 12px;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.5;
}

.live-extra__list {
  margin: 0;
  padding: 0 0 0 1.35em;
  font-size: 14px;
  line-height: 1.65;
}

.live-extra__list--ordered {
  list-style: decimal;
  padding-left: 1.5em;
}

.live-extra__list--plain {
  list-style: disc;
}

.live-extra__list li + li {
  margin-top: 4px;
}

/* ライブ詳細: セットリストは <details> で折りたたみ */
.live-setlist-details {
  margin: 0 0 28px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface-2);
  overflow: hidden;
}

.live-setlist-summary {
  list-style: none;
  margin: 0;
  padding: 14px 18px;
  font-size: 15px;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  user-select: none;
  transition: background 0.15s ease, color 0.15s ease;
}

.live-setlist-summary::-webkit-details-marker {
  display: none;
}

.live-setlist-summary::after {
  content: "（開く）";
  margin-left: 0.5em;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
}

.live-setlist-details[open] .live-setlist-summary::after {
  content: "（閉じる）";
}

.live-setlist-summary:hover {
  background: color-mix(in srgb, var(--accent) 10%, var(--surface-2));
}

.live-setlist-inner {
  padding: 0 18px 18px;
  border-top: 1px solid var(--border);
}

.live-setlist-heading {
  margin: 14px 0 10px;
}

.tags {
  list-style: none;
  padding: 16px 0 0;
  margin: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  border-top: 1px solid var(--border);
}

.tags li {
  font-size: 12px;
  padding: 4px 10px;
  background: var(--surface-2);
  color: var(--text-muted);
  border-radius: 999px;
}

/* Quiz (/quiz) */
.quiz-page__head {
  margin-bottom: 8px;
}

.quiz-page__title {
  margin: 0 0 12px;
  font-size: 26px;
  line-height: 1.3;
}

.quiz-page__intro {
  padding-bottom: 8px;
}

.quiz-card {
  margin-top: 20px;
  padding: 20px 20px 22px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.quiz-card__instructions {
  margin: 0 0 18px;
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.65;
}

.quiz-q {
  margin: 0 0 20px;
  padding: 0;
  border: none;
}

.quiz-q__legend {
  padding: 0;
  margin: 0 0 12px;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.55;
}

.quiz-q__label {
  color: var(--accent);
  font-weight: 700;
  margin-right: 6px;
}

.quiz-q__choices {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.quiz-q__choice {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface-2);
  cursor: pointer;
  font-size: 15px;
  line-height: 1.5;
}

.quiz-q__choice:hover {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--border));
}

.quiz-q__choice input {
  margin: 4px 0 0;
  accent-color: var(--accent);
  flex-shrink: 0;
}

.quiz-q__feedback {
  margin: 10px 0 0;
  font-size: 14px;
  font-weight: 600;
}

.quiz-q__feedback.is-ok {
  color: color-mix(in srgb, #3ecf8e 85%, var(--text));
}

.quiz-q__feedback.is-ng {
  color: color-mix(in srgb, #f08080 90%, var(--text));
}

.quiz-q__explain {
  margin: 8px 0 0;
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.65;
  padding: 10px 12px;
  background: var(--bg);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.quiz-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 8px;
}

.quiz-btn {
  min-width: 8rem;
}

.quiz-summary {
  margin-top: 18px;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  font-size: 15px;
  font-weight: 600;
  background: var(--surface-2);
  border: 1px solid var(--border);
}

.quiz-summary.is-perfect {
  border-color: color-mix(in srgb, var(--accent) 50%, var(--border));
  color: var(--accent);
}

/* Footer */
.site-footer {
  margin-top: 48px;
  padding: 24px 0 40px;
  color: var(--text-muted);
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: 13px;
}

/* ─── /projects/jagged-edge デモ ─── */
.je-app__head .je-app__intro {
  margin-top: 0.5rem;
}

.je-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px 22px;
  margin-bottom: 24px;
  box-shadow: var(--shadow);
}

.je-hint.je-status {
  margin: 12px 0 0;
  font-size: 14px;
  color: var(--text-muted);
}

.je-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
  margin-bottom: 12px;
}

.je-row:last-child {
  margin-bottom: 0;
}

.je-label {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 13px;
  color: var(--text-muted);
  min-width: 0;
}

.je-file {
  font-size: 13px;
  color: var(--text);
}

.je-btn {
  appearance: none;
  border: 1px solid var(--border);
  background: linear-gradient(145deg,
      color-mix(in srgb, var(--accent) 22%, var(--surface)),
      var(--surface-2));
  color: var(--text);
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
}

.je-btn:hover:not(:disabled) {
  border-color: color-mix(in srgb, var(--accent) 55%, var(--border));
}

.je-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.je-btn--ghost {
  background: var(--surface-2);
  font-weight: 500;
}

.je-preview {
  display: grid;
  gap: 20px;
  margin-bottom: 24px;
}

@media (min-width: 680px) {
  .je-preview {
    grid-template-columns: 1fr 1fr;
  }
}

.je-preview__title {
  font-size: 15px;
  margin: 0 0 8px;
}

.je-canvas {
  width: 100%;
  height: auto;
  max-height: 480px;
  object-fit: contain;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface-2);
  display: block;
}

.je-examples-wrap.prose {
  padding-top: 0;
}

.je-examples-wrap.prose > h2:first-child {
  margin-top: 1.25rem;
}

.je-examples-wrap.prose > h3 {
  margin-bottom: 0.65rem;
}

.je-examples--video {
  margin-top: 0;
}

.je-examples__grid {
  display: grid;
  gap: 16px;
}

@media (min-width: 640px) {
  .je-examples__grid {
    grid-template-columns: 1fr 1fr;
  }
}

.je-examples__media {
  min-width: 0;
}

.je-examples__label {
  margin: 0 0 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
}

.je-examples__video {
  width: 100%;
  max-height: 320px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: #000;
  vertical-align: middle;
}

.je-examples--image {
  margin-top: 0;
  margin-bottom: 0;
}

.je-examples__img {
  width: 100%;
  height: auto;
  max-height: 360px;
  object-fit: contain;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface-2);
  display: block;
}

.je-panel .je-progress-wrap {
  margin: 10px 0 12px;
}

.je-progress-wrap {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 10px 12px;
  padding: 12px 14px;
  background: var(--surface-2);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.je-progress-label-main {
  margin: 0;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
}

.je-progress-wrap progress {
  min-width: 0;
  width: 100%;
  height: 10px;
  accent-color: var(--accent);
}

.je-progress-values {
  margin: 0;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  color: var(--text);
  white-space: nowrap;
}

.je-label input[type="number"],
.je-label input[type="text"],
.je-label select {
  padding: 6px 8px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
}