:root {
  color-scheme: dark;
  --bg: #0d1117;
  --header: #010409;
  --surface: #0d1117;
  --surface-raised: #161b22;
  --surface-soft: #11161d;
  --border: #30363d;
  --border-soft: #21262d;
  --text: #e6edf3;
  --muted: #8b949e;
  --faint: #6e7681;
  --blue: #58a6ff;
  --green: #3fb950;
  --green-2: #26a641;
  --green-soft: rgba(46, 160, 67, .15);
  --orange: #f0883e;
  --shadow: 0 16px 48px rgba(1, 4, 9, .32);
  --sans: "IBM Plex Sans JP", "Yu Gothic UI", sans-serif;
  --mono: "IBM Plex Mono", "BIZ UDPGothic", monospace;
}

:root[data-theme="light"] {
  color-scheme: light;
  --bg: #ffffff;
  --header: #f6f8fa;
  --surface: #ffffff;
  --surface-raised: #f6f8fa;
  --surface-soft: #fbfcfd;
  --border: #d0d7de;
  --border-soft: #d8dee4;
  --text: #1f2328;
  --muted: #636c76;
  --faint: #818b98;
  --blue: #0969da;
  --green: #1f883d;
  --green-2: #1a7f37;
  --green-soft: rgba(31, 136, 61, .12);
  --orange: #bc4c00;
  --shadow: 0 16px 48px rgba(31, 35, 40, .1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  margin: 0;
  min-width: 320px;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 14px;
  line-height: 1.6;
  transition: background-color .25s ease, color .25s ease;
}
button, a { font: inherit; }
a { color: inherit; }
svg { fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; top: -50px; left: 16px; z-index: 100; padding: 8px 12px; border-radius: 6px; background: var(--blue); color: #fff; transition: top .2s; }
.skip-link:focus { top: 8px; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--header);
  border-bottom: 1px solid var(--border-soft);
}
.header-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 64px;
  max-width: 1440px;
  margin: 0 auto;
  padding: 12px 28px;
}
.mark { display: grid; place-items: center; color: var(--text); }
.mark svg { width: 34px; height: 34px; stroke-width: 1.25; }
.repo-path { display: flex; align-items: center; gap: 6px; text-decoration: none; white-space: nowrap; }
.repo-path strong { font-weight: 650; }
.repo-path i {
  display: inline-flex;
  align-items: center;
  height: 20px;
  padding: 0 7px;
  border: 1px solid var(--border);
  border-radius: 99px;
  color: var(--muted);
  font: 600 11px/1 var(--sans);
  font-style: normal;
}
.mascot-lane {
  position: relative;
  align-self: stretch;
  flex: 1 1 140px;
  min-width: 72px;
  overflow: hidden;
  border-bottom: 1px dashed color-mix(in srgb, var(--border) 42%, transparent);
}
.header-mascot {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 38px;
  height: 44px;
  color: var(--text);
  transform-origin: center bottom;
}
.header-mascot[data-direction="-1"] { transform: scaleX(-1); }
.mascot-sprite {
  position: relative;
  top: 4px;
  z-index: 1;
  display: block;
  width: 36px;
  height: 40px;
  overflow: visible;
  animation: mascot-bob .42s steps(2, end) infinite;
}
.mascot-shadow {
  position: absolute;
  bottom: 1px;
  left: 8px;
  width: 24px;
  height: 4px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--text) 18%, transparent);
  filter: blur(1px);
  animation: mascot-shadow-step .42s steps(2, end) infinite;
}
.mascot-face { fill: #f7fbff; stroke: #0a285c; }
.mascot-hair { fill: #0a285c; stroke: #0a285c; }
.mascot-hood { fill: #12366d; stroke: #6f8daf; }
.mascot-pocket { fill: #082658; stroke: none; }
.mascot-pants { fill: none; stroke: #9cb2cb; stroke-width: 4; }
.mascot-shoe { fill: #061d43; stroke: #061d43; }
.mascot-eye { stroke: #0a285c; stroke-width: 2.4; }
.mascot-mouth { stroke: #0a285c; stroke-width: 1.2; }
.mascot-hood-string { stroke: #cddbeb; stroke-width: 1; }
.mascot-arm { fill: #f7fbff; stroke: #6f8daf; stroke-width: 3; }
.mascot-arm-left { animation: mascot-arm-left .84s steps(2, end) infinite; transform-origin: 13px 23px; }
.mascot-arm-right { animation: mascot-arm-right .84s steps(2, end) infinite; transform-origin: 31px 23px; }
.mascot-legs { animation: mascot-walk .42s steps(2, end) infinite; transform-origin: center; }
.header-mascot.is-paused .mascot-sprite,
.header-mascot.is-paused .mascot-shadow,
.header-mascot.is-paused .mascot-arm,
.header-mascot.is-paused .mascot-legs { animation-play-state: paused; }
@keyframes mascot-bob { 50% { transform: translateY(-2px); } }
@keyframes mascot-shadow-step { 50% { opacity: .55; transform: scaleX(.82); } }
@keyframes mascot-walk { 50% { transform: skewX(-7deg); } }
@keyframes mascot-arm-left { 50% { transform: rotate(12deg); } }
@keyframes mascot-arm-right { 50% { transform: rotate(-12deg); } }
.global-nav { display: flex; gap: 4px; }
.global-nav a { padding: 7px 10px; border-radius: 6px; color: var(--muted); text-decoration: none; font-size: 13px; transition: color .2s, background .2s; }
.global-nav a:hover { background: var(--surface-raised); color: var(--text); }
.header-actions { display: flex; align-items: center; gap: 10px; }
.icon-button, .menu-button {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  padding: 0;
  color: var(--muted);
  border: 1px solid var(--border);
  border-radius: 6px;
  background: transparent;
  cursor: pointer;
}
.icon-button:hover { color: var(--text); background: var(--surface-raised); }
.icon-button svg { width: 17px; height: 17px; }
.sun-icon, :root[data-theme="light"] .moon-icon { display: none; }
:root[data-theme="light"] .sun-icon { display: block; }
.header-avatar { width: 30px; height: 30px; overflow: hidden; border-radius: 50%; background: #d9e3f2; }
.header-avatar img { display: block; width: 100%; height: 100%; object-fit: cover; }
.menu-button { display: none; }
.menu-button span { width: 16px; height: 1px; background: currentColor; }

.page-shell {
  display: grid;
  grid-template-columns: 296px minmax(0, 1fr);
  gap: 32px;
  max-width: 1216px;
  margin: 0 auto;
  padding: 32px 0 80px;
}
.profile-column { position: relative; min-width: 0; }
.avatar-wrap { position: relative; border-radius: 50%; }
.avatar-wrap:focus-visible { outline: 2px solid var(--blue); outline-offset: 7px; }
.profile-avatar { display: block; width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; border: 1px solid var(--border); border-radius: 50%; background: #cbd9eb; box-shadow: 0 0 0 4px var(--bg); transform-origin: center; }
.avatar-wrap.is-spinning .profile-avatar { animation: avatar-easter-egg-spin .72s cubic-bezier(.22, .8, .32, 1); will-change: transform; }
@keyframes avatar-easter-egg-spin {
  0% { transform: rotate(0deg) scale(1); }
  48% { transform: rotate(205deg) scale(.92); }
  80% { transform: rotate(350deg) scale(1.035); }
  100% { transform: rotate(360deg) scale(1); }
}
.status {
  position: absolute;
  right: 4px;
  bottom: 24px;
  display: flex;
  align-items: center;
  gap: 0;
  min-width: 38px;
  height: 38px;
  overflow: hidden;
  padding: 0 10px;
  color: var(--muted);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 99px;
  box-shadow: var(--shadow);
  transition: width .25s ease, color .2s;
}
.status span { width: 16px; flex: 0 0 16px; color: var(--green); font: 600 16px var(--mono); }
.status b { max-width: 0; margin-left: 0; overflow: hidden; opacity: 0; white-space: nowrap; font: 500 12px var(--sans); transition: max-width .25s, opacity .2s, margin .25s; }
.status:hover { color: var(--text); }
.status:hover b { max-width: 80px; margin-left: 7px; opacity: 1; }
.profile-column h1 { margin: 18px 0 0; font-size: 24px; line-height: 1.25; letter-spacing: -.02em; }
.handle { margin: 0; color: var(--muted); font-size: 18px; font-weight: 300; }
.bio { margin: 16px 0; font-size: 15px; line-height: 1.7; }
.social-links { display: flex; align-items: center; gap: 4px; }
.profile-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  color: var(--text);
  background: transparent;
  border: 0;
  border-radius: 6px;
  text-align: center;
  text-decoration: none;
}
.profile-button:hover { background: var(--surface-raised); }
.profile-button:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.social-icon { width: 18px; height: 18px; flex: 0 0 auto; fill: currentColor; stroke: none; }
.profile-meta { display: grid; gap: 6px; margin: 18px 0 0; }
.profile-meta div { display: flex; align-items: center; gap: 8px; }
.profile-meta dt { width: 17px; height: 17px; color: var(--muted); }
.profile-meta dt svg { width: 16px; height: 16px; }
.profile-meta dd { margin: 0; color: var(--text); font-size: 13px; }
.profile-meta a { text-decoration: none; }
.profile-meta a:hover { color: var(--blue); text-decoration: underline; }
.profile-rule { height: 1px; margin: 20px 0 16px; background: var(--border-soft); }
.achievement-title { margin-bottom: 10px; font-weight: 600; }
.achievement-list { display: flex; gap: 9px; }
.achievement {
  position: relative;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 1px solid #8250df;
  border-radius: 50%;
  color: #d2a8ff;
  background: radial-gradient(circle at 35% 30%, #322053, #171020 68%);
  font: 600 12px var(--mono);
  box-shadow: inset 0 0 0 3px var(--bg);
}
.achievement.cloud { border-color: #1f6feb; color: #79c0ff; background: radial-gradient(circle at 35% 30%, #102b52, #0d1728 68%); }
.achievement.team { border-color: #238636; color: #7ee787; background: radial-gradient(circle at 35% 30%, #113b21, #0d1f14 68%); }
.achievement::after { content: attr(data-tip); position: absolute; bottom: -30px; left: 50%; z-index: 3; padding: 3px 7px; border-radius: 4px; color: var(--bg); background: var(--text); opacity: 0; pointer-events: none; transform: translate(-50%, -3px); white-space: nowrap; font: 500 10px var(--sans); transition: opacity .15s, transform .15s; }
.achievement:hover::after { opacity: 1; transform: translate(-50%, 0); }

.content-column { min-width: 0; }
.panel { border: 1px solid var(--border); border-radius: 8px; background: var(--surface); overflow: hidden; }
.panel-bar { display: flex; justify-content: space-between; align-items: center; min-height: 44px; padding: 0 16px; border-bottom: 1px solid var(--border); background: var(--surface-raised); color: var(--muted); font: 500 12px var(--mono); }
.panel-bar > span { display: inline-flex; align-items: center; gap: 8px; }
.panel-bar svg { width: 15px; height: 15px; }
.branch i { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 3px var(--green-soft); }
.readme-body { position: relative; padding: clamp(28px, 5vw, 54px); overflow: hidden; }
.readme-body::before {
  content: "</>";
  position: absolute;
  top: 10px;
  right: 25px;
  color: color-mix(in srgb, var(--text) 3%, transparent);
  font: 600 clamp(100px, 18vw, 220px)/1 var(--mono);
  transform: rotate(-8deg);
  pointer-events: none;
}
.terminal-line { position: relative; z-index: 1; color: var(--muted); font: 12px var(--mono); }
.prompt { color: var(--green); margin-right: 7px; }
.terminal-cursor { display: inline-block; width: 7px; height: 1em; margin-left: 5px; vertical-align: -.15em; background: var(--green); animation: blink 1.15s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.eyebrow { position: relative; z-index: 1; margin: 28px 0 12px; color: var(--green); font: 600 11px var(--mono); letter-spacing: .12em; }
.readme h2 { position: relative; z-index: 1; max-width: 700px; margin: 0; font-size: clamp(34px, 5vw, 58px); line-height: 1.22; letter-spacing: -.045em; }
.readme h2 span { color: var(--muted); }
.lead { position: relative; z-index: 1; max-width: 690px; margin: 26px 0 0; color: var(--muted); font-size: 16px; line-height: 2; }
.readme-divider { height: 1px; margin: 40px 0; background: var(--border-soft); }
.readme h3 { margin: 32px 0 16px; font-size: 21px; }
.readme h3 a { margin-right: 7px; color: var(--blue); text-decoration: none; font-weight: 400; }
.about-grid { display: grid; grid-template-columns: 1.25fr .75fr; gap: 32px; align-items: center; }
.about-grid > p { margin: 0; color: var(--muted); line-height: 1.9; }
.about-grid blockquote { position: relative; margin: 0; padding: 20px 20px 20px 24px; border-left: 3px solid var(--green); background: var(--surface-raised); color: var(--text); line-height: 1.8; }
.about-grid blockquote span { position: absolute; top: -12px; right: 12px; color: var(--border); font: 600 64px/1 Georgia, serif; }
.stack-groups { display: grid; gap: 10px; }
.stack-row { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; }
.stack-row strong { width: 58px; color: var(--muted); font: 600 11px var(--mono); text-transform: uppercase; }
.stack-row span, .tag-list span { display: inline-flex; align-items: center; min-height: 26px; padding: 2px 9px; border: 1px solid var(--border); border-radius: 99px; background: var(--surface-raised); color: var(--text); font: 500 11px var(--mono); }
.currently { display: flex; gap: 14px; align-items: flex-start; margin-top: 38px; padding: 17px 20px; border: 1px dashed var(--border); border-radius: 6px; background: var(--surface-soft); }
.live-dot { flex: 0 0 auto; width: 9px; height: 9px; margin-top: 5px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 5px var(--green-soft); }
.currently small { color: var(--muted); font: 600 10px var(--mono); letter-spacing: .1em; }
.currently p { margin: 3px 0 0; font: 12px/1.7 var(--mono); }

.section { margin-top: 36px; }
.section-heading { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin-bottom: 13px; }
.section-heading.compact { margin-bottom: 12px; }
.section-kicker { display: block; margin-bottom: 3px; color: var(--green); font: 600 10px var(--mono); letter-spacing: .1em; }
.section-heading h2 { margin: 0; font-size: 18px; letter-spacing: -.01em; }
.commit-count { color: var(--muted); font: 10px var(--mono); text-align: right; }

.brain-card {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(220px, .8fr);
  min-height: 340px;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: var(--surface);
}
.brain-canvas {
  position: relative;
  min-width: 0;
  min-height: 340px;
  overflow: hidden;
  border-right: 1px solid var(--border);
  background:
    radial-gradient(circle at 50% 50%, color-mix(in srgb, var(--blue) 7%, transparent), transparent 31%),
    linear-gradient(90deg, color-mix(in srgb, var(--border) 28%, transparent) 1px, transparent 1px),
    linear-gradient(color-mix(in srgb, var(--border) 28%, transparent) 1px, transparent 1px),
    var(--surface-soft);
  background-size: auto, 22px 22px, 22px 22px, auto;
}
.brain-canvas::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(ellipse at center, transparent 45%, color-mix(in srgb, var(--surface) 68%, transparent));
}
.map-expand {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 10;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 0;
  color: var(--blue);
  background: color-mix(in srgb, var(--surface-raised) 94%, transparent);
  border: 1px solid color-mix(in srgb, var(--blue) 42%, var(--border));
  border-radius: 7px;
  box-shadow: 0 8px 22px color-mix(in srgb, var(--bg) 48%, transparent);
  text-decoration: none;
  cursor: pointer;
  animation: map-invite 3.6s ease-in-out infinite;
  transition: color .2s, border-color .2s, background .2s, transform .2s;
}
.map-pointer {
  position: absolute;
  top: 52px;
  right: 15px;
  z-index: 9;
  width: 27px;
  height: 36px;
  color: color-mix(in srgb, var(--blue) 82%, var(--text));
  opacity: .74;
  filter: drop-shadow(0 3px 5px color-mix(in srgb, var(--bg) 45%, transparent));
  pointer-events: none;
  transform-origin: 50% 0;
  animation: map-pointer-invite 3.8s ease-in-out 1s infinite;
  transition: opacity .2s;
}
.map-pointer svg { display: block; width: 100%; height: 100%; fill: color-mix(in srgb, var(--surface-raised) 82%, transparent); stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.map-expand:hover + .map-pointer, .map-expand:focus-visible + .map-pointer { opacity: 0; }
@keyframes map-pointer-invite {
  0%, 18%, 36%, 100% { transform: translateY(3px); }
  9%, 27% { transform: translateY(-1px); }
}

.brain-workspace {
  position: fixed;
  inset: 65px 0 0;
  z-index: 19;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  background: var(--bg);
  animation: workspace-enter .28s cubic-bezier(.2, .8, .2, 1) both;
}
.brain-workspace[hidden] { display: none; }
.brain-workspace-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 58px;
  padding: 9px 24px;
  border-bottom: 1px solid var(--border);
  background: color-mix(in srgb, var(--surface-raised) 94%, transparent);
  box-shadow: 0 12px 30px color-mix(in srgb, var(--bg) 55%, transparent);
}
.brain-workspace-bar > div { display: flex; align-items: baseline; gap: 12px; min-width: 0; }
.brain-workspace-bar strong { font: 600 15px var(--mono); white-space: nowrap; }
.brain-workspace-bar small { overflow: hidden; color: var(--muted); font: 10px var(--mono); text-overflow: ellipsis; white-space: nowrap; }
.workspace-signal { display: inline-flex; align-items: center; gap: 6px; color: var(--green); font: 600 9px var(--mono); letter-spacing: .12em; white-space: nowrap; }
.workspace-signal i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; box-shadow: 0 0 9px currentColor; }
.workspace-close {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  padding: 6px 8px 6px 12px;
  color: var(--muted);
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  cursor: pointer;
}
.workspace-close:hover, .workspace-close:focus-visible { color: var(--text); border-color: var(--blue); outline: 0; }
.workspace-close span { font: 600 11px var(--mono); }
.workspace-close kbd { padding: 2px 5px; color: var(--faint); border: 1px solid var(--border); border-radius: 3px; font: 9px var(--mono); }
.workspace-close svg { width: 15px; height: 15px; }
.brain-workspace-frame { position: relative; min-height: 0; background: var(--bg); }
#brain-map-host { position: relative; z-index: 1; display: block; width: 100%; height: 100%; background: var(--bg); }
.workspace-loading { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 14px; color: var(--muted); font: 10px var(--mono); letter-spacing: .14em; }
.workspace-loading[hidden] { display: none; }
.workspace-loading span { width: 28px; height: 28px; border: 1px solid var(--border); border-top-color: var(--blue); border-radius: 50%; animation: workspace-spin .8s linear infinite; }
body.brain-workspace-open { overflow: hidden; }
@keyframes workspace-enter { from { opacity: 0; transform: translateY(12px); } }
@keyframes workspace-spin { to { transform: rotate(360deg); } }
.map-expand::before {
  content: attr(data-label);
  position: absolute;
  top: 50%;
  right: calc(100% + 8px);
  padding: 5px 8px;
  color: var(--text);
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: 4px;
  opacity: 0;
  pointer-events: none;
  transform: translate(4px, -50%);
  transition: opacity .18s, transform .18s;
  white-space: nowrap;
  font: 600 8px var(--mono);
  letter-spacing: .08em;
}
.map-expand:hover, .map-expand:focus-visible { color: var(--text); background: color-mix(in srgb, var(--blue) 12%, var(--surface-raised)); border-color: var(--blue); transform: translateY(-1px); outline: 0; }
.map-expand:hover::before, .map-expand:focus-visible::before { opacity: 1; transform: translate(0, -50%); }
.map-expand svg { width: 18px; height: 18px; stroke-width: 1.7; transition: transform .2s; }
.map-expand:hover svg, .map-expand:focus-visible svg { transform: scale(1.12); }
@keyframes map-invite {
  0%, 66%, 100% { box-shadow: 0 8px 22px color-mix(in srgb, var(--bg) 48%, transparent), 0 0 0 0 transparent; }
  76% { box-shadow: 0 8px 22px color-mix(in srgb, var(--bg) 48%, transparent), 0 0 0 5px color-mix(in srgb, var(--blue) 9%, transparent); }
}
.map-coordinate { position: absolute; top: 12px; right: 58px; left: 14px; z-index: 2; display: flex; justify-content: space-between; color: var(--faint); font: 8px var(--mono); letter-spacing: .08em; }
.map-coordinate span:last-child { color: var(--green); }
.map-coordinate span:last-child::before { content: ""; display: inline-block; width: 5px; height: 5px; margin-right: 6px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 3px var(--green-soft); }
.brain-lines { position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%; overflow: visible; }
.map-edge { fill: none; stroke: color-mix(in srgb, var(--blue) 40%, var(--border)); stroke-width: .32; vector-effect: non-scaling-stroke; }
.secondary-edge { stroke: var(--border); stroke-width: .2; stroke-dasharray: 1.2 1.4; }
.orbit { fill: none; stroke: color-mix(in srgb, var(--green) 22%, transparent); stroke-width: .18; stroke-dasharray: .8 1.5; transform-box: fill-box; transform-origin: center; animation: orbit-turn 28s linear infinite; }
.orbit-wide { stroke: color-mix(in srgb, var(--blue) 16%, transparent); stroke-dasharray: 1.5 2.2; animation-direction: reverse; animation-duration: 38s; }
@keyframes orbit-turn { to { transform: rotate(360deg); } }
.brain-node {
  --node-color: var(--blue);
  position: absolute;
  top: var(--y);
  left: var(--x);
  z-index: 3;
  display: grid;
  place-content: center;
  min-width: 74px;
  min-height: 48px;
  padding: 7px 10px;
  color: var(--text);
  background: color-mix(in srgb, var(--surface-raised) 92%, transparent);
  border: 1px solid color-mix(in srgb, var(--node-color) 48%, var(--border));
  border-radius: 5px;
  box-shadow: 0 7px 24px color-mix(in srgb, var(--bg) 58%, transparent);
  cursor: pointer;
  transform: translate(-50%, -50%);
  transition: border-color .2s, background .2s, box-shadow .2s, transform .2s;
}
.brain-node::before { content: ""; position: absolute; top: -3px; left: -3px; width: 5px; height: 5px; border: 1px solid var(--node-color); background: var(--surface); }
.brain-node b { font: 600 11px/1.2 var(--mono); }
.brain-node small { margin-top: 3px; color: var(--muted); font: 8px/1 var(--mono); text-transform: uppercase; }
.brain-node:hover, .brain-node:focus-visible, .brain-node.active { z-index: 4; border-color: var(--node-color); background: color-mix(in srgb, var(--node-color) 10%, var(--surface-raised)); box-shadow: 0 0 0 3px color-mix(in srgb, var(--node-color) 10%, transparent), 0 10px 28px color-mix(in srgb, var(--bg) 64%, transparent); transform: translate(-50%, -50%) scale(1.06); outline: 0; }
.brain-node.central { --node-color: var(--green); min-width: 88px; min-height: 58px; border-radius: 50%; }
.brain-node.domain { --node-color: #79c0ff; }
.brain-node.interest { --node-color: #d2a8ff; }
.node-pulse { position: absolute; top: 6px; right: 9px; width: 5px; height: 5px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 0 var(--green-soft); animation: node-pulse 2.4s ease-out infinite; }
@keyframes node-pulse { 60%, 100% { box-shadow: 0 0 0 8px transparent; } }
.brain-inspector { position: relative; display: flex; flex-direction: column; min-width: 0; padding: 22px; background: var(--surface-raised); }
.inspector-label { color: var(--muted); font: 9px var(--mono); letter-spacing: .08em; }
.inspector-index { position: absolute; top: 15px; right: 18px; color: color-mix(in srgb, var(--text) 8%, transparent); font: 600 34px/1 var(--mono); }
.brain-inspector h3 { position: relative; margin: 38px 0 6px; font-size: 20px; line-height: 1.3; letter-spacing: -.025em; }
.inspector-type { align-self: flex-start; padding: 2px 7px; border: 1px solid color-mix(in srgb, var(--green) 40%, var(--border)); border-radius: 99px; color: var(--green); font: 8px var(--mono); }
.brain-inspector > p { margin: 18px 0; color: var(--muted); font-size: 12px; line-height: 1.85; }
.inspector-hint { display: flex; align-items: center; gap: 8px; margin-top: auto; padding-top: 14px; border-top: 1px solid var(--border); color: var(--faint); font: 9px var(--mono); }
.inspector-hint kbd { padding: 2px 5px; border: 1px solid var(--border); border-bottom-width: 2px; border-radius: 3px; background: var(--surface); color: var(--muted); font: inherit; }

.timeline { border-top: 1px solid var(--border); }
.timeline-entry { display: grid; grid-template-columns: 32px 1fr; }
.timeline-rail { display: flex; flex-direction: column; align-items: center; }
.timeline-rail > span:last-child { width: 2px; flex: 1; background: var(--border); }
.commit-node { z-index: 1; width: 12px; height: 12px; margin-top: 27px; border: 2px solid var(--muted); border-radius: 50%; background: var(--bg); }
.featured .commit-node { border-color: var(--green); background: var(--green); box-shadow: 0 0 0 5px var(--green-soft); }
.timeline-content { padding: 22px 0 28px 10px; border-bottom: 1px solid var(--border-soft); }
.timeline-date { margin-bottom: 5px; color: var(--muted); font: 10px var(--mono); letter-spacing: .04em; }
.timeline-date span { display: inline-block; margin-left: 7px; padding: 1px 6px; border: 1px solid var(--green); border-radius: 99px; color: var(--green); font-size: 8px; }
.timeline-content h3 { margin: 0; font-size: 16px; }
.timeline-content p { max-width: 760px; margin: 8px 0 12px; color: var(--muted); font-size: 13px; line-height: 1.8; }
.tag-list { display: flex; flex-wrap: wrap; gap: 6px; }
.tag-list span { min-height: 22px; color: var(--blue); background: color-mix(in srgb, var(--blue) 8%, transparent); border-color: color-mix(in srgb, var(--blue) 28%, transparent); font-size: 9px; }
.timeline-details { min-width: 0; border-bottom: 1px solid var(--border-soft); }
.timeline-details summary { position: relative; padding: 22px 0 22px 10px; cursor: pointer; list-style: none; transition: background .2s; }
.timeline-details summary::-webkit-details-marker { display: none; }
.timeline-details summary:hover { background: linear-gradient(90deg, color-mix(in srgb, var(--blue) 5%, transparent), transparent 78%); }
.timeline-details summary:focus-visible { outline: 2px solid var(--blue); outline-offset: -2px; border-radius: 4px; }
.timeline-details summary { display: flex; align-items: center; gap: 12px; min-height: 58px; padding-top: 12px; padding-bottom: 12px; }
.folded-period { flex: 0 0 auto; margin: 0; }
.folded-line { height: 1px; flex: 1; background: repeating-linear-gradient(90deg, var(--border) 0 4px, transparent 4px 8px); }
.fold-control { display: inline-flex; align-items: center; gap: 5px; padding-right: 8px; color: var(--muted); font: 9px var(--mono); white-space: nowrap; }
.fold-control b { display: inline-grid; place-items: center; min-width: 19px; height: 19px; border: 1px solid var(--border); border-radius: 99px; color: var(--text); font-weight: 500; }
.fold-control i { width: 7px; height: 7px; margin-left: 3px; border-right: 1px solid currentColor; border-bottom: 1px solid currentColor; transform: rotate(45deg) translateY(-2px); transition: transform .2s; }
.timeline-details[open] .fold-control i { transform: rotate(225deg) translate(-1px, -1px); }
.timeline-fold-body { margin: 0 0 24px 10px; padding: 4px 18px 18px; border-left: 1px dashed var(--border); background: var(--surface-soft); }
.folded-item { display: grid; grid-template-columns: 28px 1fr; gap: 10px; padding: 15px 0; border-bottom: 1px solid var(--border-soft); }
.folded-item:last-of-type { border-bottom: 0; }
.folded-icon { color: var(--green); font: 9px/1.6 var(--mono); }
.folded-item h4 { margin: 0; font-size: 13px; }
.folded-item p { margin: 5px 0 0; color: var(--muted); font-size: 11px; line-height: 1.75; }
.folded-item .tag-list { margin-top: 10px; }
.origin .timeline-content { border-bottom: 0; }

.footer-cta { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-top: 44px; padding: 24px; border: 1px solid var(--border); border-radius: 7px; background: var(--surface-raised); }
.cta-prompt { font: 12px var(--mono); }
.cta-prompt > span:first-child { color: var(--green); }
.cta-prompt strong { color: var(--blue); font-weight: 400; }
.typed-text { margin-left: 6px; color: var(--text) !important; }
.cta-links { display: flex; gap: 16px; flex: 0 0 auto; }
.cta-links a { display: inline-flex; align-items: center; gap: 5px; color: var(--blue); text-decoration: none; font-size: 12px; font-weight: 600; }
.cta-links a:hover { text-decoration: underline; }
.site-footer { display: flex; justify-content: space-between; max-width: 1216px; margin: 0 auto; padding: 28px 0 40px; border-top: 1px solid var(--border-soft); color: var(--muted); font: 10px var(--mono); }

@media (max-width: 1260px) {
  .page-shell, .site-footer { margin-right: 24px; margin-left: 24px; }
}

@media (max-width: 900px) {
  .header-inner { padding: 10px 16px; }
  .repo-path i { display: none; }
  .menu-button { display: grid; gap: 3px; order: -1; }
  .mark { display: none; }
  .global-nav { position: absolute; top: 58px; right: 16px; left: 16px; display: none; padding: 8px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface-raised); box-shadow: var(--shadow); }
  .global-nav.open { display: grid; }
  .global-nav a { padding: 10px; }
  .header-actions { margin-left: auto; }
  .page-shell { grid-template-columns: 220px minmax(0, 1fr); gap: 24px; margin: 0 20px; }
  .profile-column { margin-top: 0; }
  .status { bottom: 10px; }
  .about-grid { grid-template-columns: 1fr; gap: 18px; }
  .readme-body { padding: 32px; }
  .footer-cta { align-items: flex-start; flex-direction: column; }
  .site-footer { margin: 0 20px; }
}

@media (max-width: 660px) {
  html { scroll-padding-top: 72px; }
  .repo-path span:nth-of-type(2) { display: none; }
  .header-avatar { display: none; }
  .page-shell { display: block; margin: 0 16px; padding-top: 20px; }
  .profile-column { display: grid; grid-template-columns: 88px 1fr; column-gap: 16px; align-items: center; }
  .avatar-wrap { grid-row: 1 / span 3; }
  .status { display: none; }
  .profile-column h1 { margin: 0; font-size: 21px; }
  .handle { font-size: 15px; }
  .bio { margin: 5px 0 0; font-size: 13px; }
  .social-links, .profile-meta, .profile-rule, .achievement-title, .achievement-list { grid-column: 1 / -1; }
  .social-links { margin-top: 16px; }
  .profile-meta { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .profile-meta div:last-child { grid-column: 1 / -1; }
  .profile-rule { margin-bottom: 13px; }
  .content-column { margin-top: 28px; }
  .panel-bar { padding: 0 12px; }
  .branch { display: none !important; }
  .readme-body { padding: 26px 20px; }
  .readme h2 { font-size: 34px; }
  .lead { font-size: 14px; line-height: 1.9; }
  .readme-divider { margin: 30px 0; }
  .readme h3 { font-size: 18px; }
  .stack-row strong { width: 100%; margin-top: 6px; }
  .currently { padding: 14px; }
  .section { margin-top: 32px; }
  .section-heading { align-items: flex-start; }
  .brain-card { grid-template-columns: 1fr; }
  .brain-canvas { min-height: 315px; border-right: 0; border-bottom: 1px solid var(--border); }
  .brain-inspector { min-height: 210px; padding: 18px; }
  .brain-inspector h3 { margin-top: 28px; }
  .brain-node { min-width: 66px; min-height: 44px; padding: 6px 8px; }
  .brain-node.central { min-width: 78px; min-height: 54px; }
  .brain-node b { font-size: 10px; }
  .timeline-entry { grid-template-columns: 24px 1fr; }
  .timeline-content { padding-left: 6px; }
  .timeline-details summary { padding-left: 6px; }
  .timeline-fold-body { margin-left: 6px; padding-right: 12px; }
  .fold-control { padding-right: 3px; }
  .footer-cta { padding: 18px; }
  .cta-prompt { line-height: 1.8; }
  .typed-text { display: block; margin-left: 0; }
  .site-footer { flex-direction: column; gap: 4px; margin: 0 16px; }
  .brain-workspace { inset: 65px 0 0; }
  .brain-workspace-bar { min-height: 52px; padding: 7px 12px; }
  .brain-workspace-bar small, .workspace-close span, .workspace-close kbd { display: none; }
  .workspace-close { padding: 7px; }
}

@media (max-width: 420px) {
  .header-inner { gap: 10px; padding-right: 12px; padding-left: 12px; }
  .repo-path strong { font-size: 0; }
  .repo-path strong::after { content: "shun.dev"; font-size: 13px; }
  .mascot-lane { display: block; min-width: 72px; flex-basis: 72px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

@media print {
  .site-header, .theme-toggle, .footer-cta, .site-footer, .mascot-lane { display: none; }
  .page-shell { grid-template-columns: 210px 1fr; margin: 0; padding: 0; }
  .profile-column { margin-top: 0; }
  .panel, .brain-card { break-inside: avoid; }
}
