:root {
  --bg: #0d0d0d;
  --surface: #121212;
  --border: #262626;
  --text: #e5e5e5;
  --text-dim: #a3a3a3;
  --text-muted: #737373;
  --accent: #10b981;
  --link: #e5e5e5;
  --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
  --font-sans: -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", Roboto, sans-serif;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #fafafa;
    --surface: #ffffff;
    --border: #e5e5e5;
    --text: #171717;
    --text-dim: #404040;
    --text-muted: #737373;
    --accent: #059669;
    --link: #171717;
  }
}

*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.shell {
  max-width: 820px;
  margin: 0 auto;
  padding: 2rem 1.25rem 4rem;
}

/* Top Terminal Bar */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  padding-bottom: 1rem;
  margin-bottom: 2rem;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}

.topbar-path {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.prompt {
  color: var(--accent);
  font-weight: 600;
  user-select: none;
}

.domain {
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
}

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

.node {
  color: var(--text-dim);
}

.topbar-nav {
  display: flex;
  gap: 1rem;
}

.topbar-nav a {
  color: var(--text-muted);
  text-decoration: none;
}

.topbar-nav a:hover {
  color: var(--text);
}

/* Plain Component Blocks */
main {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.block {
  background: var(--surface);
  border: 1px solid var(--border);
  padding: 1.5rem;
}

.cmd-line {
  font-size: 12px;
  color: var(--text-muted);
  padding-bottom: 0.85rem;
  margin-bottom: 1.1rem;
  border-bottom: 1px dashed var(--border);
}

/* Hero Layout */
.hero-layout {
  display: grid;
  grid-template-columns: 1fr 160px;
  gap: 1.75rem;
  align-items: start;
}

h1 {
  font-size: 1.65rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0 0 0.25rem 0;
  color: var(--text);
}

.role-line {
  margin: 0 0 1rem 0;
  color: var(--text-dim);
  font-size: 14px;
}

.role-line a {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.summary {
  margin: 0 0 1.25rem 0;
  color: var(--text-dim);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.65;
}

.link-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.link-row a {
  display: inline-block;
  padding: 0.3rem 0.65rem;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  text-decoration: none;
  font-size: 12px;
}

.link-row a:hover {
  border-color: var(--text-muted);
}

.avatar-box {
  margin: 0;
  border: 1px solid var(--border);
  padding: 0.4rem;
  background: var(--bg);
}

.avatar-box img {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  object-position: center top;
  display: block;
  filter: grayscale(15%);
}

.avatar-box figcaption {
  margin-top: 0.4rem;
  font-size: 11px;
  color: var(--text-muted);
  text-align: center;
}

/* Key-Value Table */
.kv-table {
  margin: 0;
  display: grid;
  grid-template-columns: 1fr;
}

.kv-row {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 1rem;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}

.kv-row:first-child {
  padding-top: 0;
}

.kv-row:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

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

.kv-row dd {
  margin: 0;
  color: var(--text);
}

.kv-row a {
  color: var(--text);
  text-underline-offset: 3px;
}

/* Headings & Prose */
h2 {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 1rem 0;
  text-transform: none;
}

p {
  margin: 0 0 1rem 0;
  color: var(--text-dim);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.7;
}

p:last-child {
  margin-bottom: 0;
}

strong {
  color: var(--text);
  font-weight: 600;
}

/* Career Log List */
.log-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.log-list li {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}

.log-list li:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.log-key {
  font-size: 12px;
  color: var(--accent);
}

.log-body strong {
  display: block;
  font-family: var(--font-mono);
  font-size: 13.5px;
  margin-bottom: 0.25rem;
}

.log-body p {
  font-size: 14px;
  margin: 0;
}

/* Footer */
.footer {
  margin-top: 2.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  font-size: 12px;
  color: var(--text-muted);
}

.footer a {
  color: var(--text-dim);
  text-decoration: none;
}

.footer a:hover {
  color: var(--text);
  text-decoration: underline;
}

.footer-links {
  display: flex;
  gap: 1rem;
}

.ok {
  color: var(--accent);
}

/* Responsive */
@media (max-width: 640px) {
  .hero-layout {
    grid-template-columns: 1fr;
  }

  .avatar-box {
    max-width: 160px;
  }

  .kv-row,
  .log-list li {
    grid-template-columns: 1fr;
    gap: 0.2rem;
  }
}
