/* Hallmark · genre: editorial · theme: Field Manual (authored direction, requested redesign) · job: hire · shape: 12-column field book, 7/5 hero, ledger index, pinned certificate archive, mapped skills · nav: paper bar, square mark, text links, mode + menu · footer: ink close, two link columns, share · mode: light/dark · copy: owner's supplied narrative and real documents · v2.0.0 */
/* Hallmark · pre-emit critique: P5 H4 E5 S4 R5 V4 · weakest: H, the certificate rail must stay legible at 1280 and not become a gimmick; the pin is bounded and the fallback is a static grid */
/* Hallmark · waive 64 · mono is the material: network annotations, dates, and document numbers are set in Chivo Mono, not as decorative labels */
/* Hallmark · dismissed 58 · the about section carries the owner's supplied narrative; copy is preserved and split, not expanded */
/* Hallmark · dismissed 23 · the Btech figure and MTCNA mark are real credentials, not invented metrics */

/* Masthead */
.masthead {
  position: sticky;
  top: 0;
  z-index: var(--z-nav);
  background: var(--color-paper);
  border-bottom: 1px solid var(--color-rule);
}

.masthead-inner {
  display: flex;
  align-items: center;
  gap: 28px;
  height: var(--nav-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--color-ink);
  text-decoration: none;
  white-space: nowrap;
}

.brand-mark {
  width: 9px;
  height: 9px;
  background: var(--color-accent-bright);
}

.brand-name {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.01em;
}

.nav {
  display: flex;
  align-items: center;
  gap: 26px;
  margin-left: auto;
  font-size: 0.9rem;
}

.nav a {
  position: relative;
  padding-block: 6px;
  color: var(--color-ink-2);
  text-decoration: none;
}

.nav a::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 1px;
  background: var(--color-accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--dur) var(--ease);
}

.nav a:hover,
.nav a.is-active {
  color: var(--color-ink);
}

.nav a:hover::after,
.nav a.is-active::after {
  transform: scaleX(1);
}

.masthead-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Buttons and controls */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid var(--color-ink);
  background: var(--color-ink);
  color: var(--color-paper);
  font-family: var(--font-body);
  font-size: 0.9rem;
  font-weight: 500;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  transition: background-color var(--dur) var(--ease), border-color var(--dur) var(--ease), color var(--dur) var(--ease), transform var(--dur) var(--ease);
}

.button:hover {
  border-color: var(--color-accent);
  background: var(--color-accent);
  color: var(--color-accent-ink);
}

.button:active {
  transform: translateY(1px);
}

.button--small {
  min-height: 38px;
  padding-inline: 14px;
  font-size: 0.84rem;
}

.button--ghost {
  background: transparent;
  color: var(--color-ink);
}

.button--ghost:hover {
  background: var(--color-accent);
  color: var(--color-accent-ink);
}

.button--band {
  border-color: var(--color-band-accent);
  background: var(--color-band-accent);
  color: var(--color-band-accent-ink);
}

.button--band:hover {
  border-color: var(--color-band-ink);
  background: var(--color-band-ink);
  color: var(--color-band);
}

.button--band-ghost {
  border-color: var(--color-band-rule);
  background: transparent;
  color: var(--color-band-ink);
}

.button--band-ghost:hover {
  border-color: var(--color-band-accent);
  background: transparent;
  color: var(--color-band-accent);
}

.icon-button {
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border: 1px solid var(--color-rule);
  color: var(--color-ink);
  transition: border-color var(--dur) var(--ease), color var(--dur) var(--ease);
}

.icon-button:hover {
  border-color: var(--color-ink);
  color: var(--color-accent);
}

.icon-sun {
  display: none;
}

[data-mode="dark"] .icon-moon {
  display: none;
}

[data-mode="dark"] .icon-sun {
  display: block;
}

.menu {
  display: none;
}

.menu-summary {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid var(--color-rule);
  font-size: 0.84rem;
  cursor: pointer;
  list-style: none;
}

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

.menu[open] .menu-summary {
  border-color: var(--color-ink);
}

.menu-panel {
  position: fixed;
  inset: var(--nav-h) 0 0;
  display: flex;
  flex-direction: column;
  padding: 12px var(--gutter) 32px;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: var(--color-paper);
  border-bottom: 1px solid var(--color-ink);
}

.menu-foot {
  margin-top: auto;
  padding-top: 20px;
  border-top: 1px solid var(--color-rule);
}

.menu-foot-label,
.menu-foot-note {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  line-height: 1.5;
  color: var(--color-muted);
}

.menu-foot-email {
  display: block;
  margin: 6px 0;
  overflow-wrap: anywhere;
  font-family: var(--font-display);
  font-size: 1.5rem;
  line-height: 1.1;
  color: var(--color-ink);
  text-decoration: none;
}

.menu-foot-email:hover {
  color: var(--color-accent);
}

.menu-panel nav a {
  padding: 13px 0;
  border-bottom: 1px solid var(--color-rule);
  font-size: 1.05rem;
  text-decoration: none;
}

.menu-panel nav a:last-child {
  border-bottom: 0;
}

/* Hero */
.hero {
  position: relative;
  overflow: clip;
  padding-top: clamp(44px, 6vw, 84px);
}

.hero-grid-bg {
  position: absolute;
  inset: 0;
  background-image: linear-gradient(to right, var(--color-rule) 1px, transparent 1px), linear-gradient(to bottom, var(--color-rule) 1px, transparent 1px);
  background-size: 88px 88px;
  opacity: 0.34;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(to bottom, var(--color-ink), transparent 72%);
  mask-image: linear-gradient(to bottom, var(--color-ink), transparent 72%);
  transform: translate3d(0, calc(var(--hero-shift, 0px) * 0.06), 0);
}

.hero-grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: var(--gap);
  align-items: end;
}

.hero-copy {
  grid-column: 1 / span 7;
  padding-bottom: clamp(28px, 4vw, 56px);
}

.hero-name {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: clamp(22px, 3vw, 38px);
  font-size: 0.88rem;
  color: var(--color-ink-2);
}

.hero-mark {
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  background: var(--color-accent-bright);
}

.hero h1 {
  letter-spacing: -0.032em;
  text-wrap: balance;
}

.hero-lead {
  max-width: 34ch;
  margin-top: 22px;
  font-size: var(--text-lead);
  line-height: 1.45;
  color: var(--color-ink-2);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 30px;
}

.hero-visual {
  grid-column: 9 / span 4;
  align-self: end;
}

.hero-plate {
  position: relative;
  isolation: isolate;
  padding: 13px 13px 0;
  background: var(--color-paper-3);
  border: 1px solid var(--color-rule);
  box-shadow: 16px 16px 0 var(--color-paper-2);
}

.plate-grid {
  position: absolute;
  top: -24px;
  right: -24px;
  z-index: 0;
  width: 150px;
  height: 150px;
  background-image: linear-gradient(to right, var(--color-rule) 1px, transparent 1px), linear-gradient(to bottom, var(--color-rule) 1px, transparent 1px);
  background-size: 22px 22px;
  border-bottom: 1px solid var(--color-rule);
  border-left: 1px solid var(--color-rule);
  opacity: 0.9;
}

.portrait {
  position: relative;
  z-index: 1;
  margin: 0;
}

.portrait img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: center top;
  filter: saturate(0.94) contrast(1.015);
}

.portrait figcaption {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 12px;
  padding: 11px 2px 14px;
  border-top: 1px solid var(--color-rule);
  font-family: var(--font-mono);
  font-size: 0.66rem;
  line-height: 1.4;
  color: var(--color-muted);
}

.portrait-role {
  color: var(--color-ink-2);
}

.hero-card {
  position: absolute;
  bottom: 54px;
  left: -30px;
  z-index: 2;
  display: flex;
  flex-direction: column;
  width: 174px;
  padding: 16px;
  border: 1px solid var(--color-band-rule);
  background: var(--color-band);
  color: var(--color-band-ink);
  box-shadow: 8px 8px 0 var(--color-accent-bright);
}

.hero-card-label {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  line-height: 1.35;
  color: var(--color-band-muted);
}

.hero-card-figure {
  margin-top: 4px;
  font-family: var(--font-display);
  font-size: 3.2rem;
  line-height: 0.9;
  color: var(--color-band-accent);
  font-variant-numeric: tabular-nums;
}

.hero-card-note {
  margin-top: 8px;
  font-size: 0.76rem;
  line-height: 1.35;
}

.hero-vertical {
  position: absolute;
  top: 44px;
  right: -30px;
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  line-height: 1;
  color: var(--color-muted);
  writing-mode: vertical-rl;
}

.hero-facts {
  position: relative;
  margin-top: clamp(44px, 6vw, 76px);
  border-top: 1px solid var(--color-rule);
}

.hero-facts dl {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 0;
}

.hero-facts dl > div {
  padding: 16px 24px 22px;
  border-right: 1px solid var(--color-rule);
}

.hero-facts dl > div:first-child {
  padding-left: 0;
}

.hero-facts dl > div:last-child {
  border-right: 0;
}

.hero-facts dt {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  line-height: 1.4;
  color: var(--color-muted);
}

.hero-facts dd {
  margin: 7px 0 0;
  font-size: 0.95rem;
  line-height: 1.35;
  color: var(--color-ink);
}

/* Shared section furniture */
.section {
  padding-block: var(--section-gap);
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 36px;
  margin-bottom: clamp(36px, 5vw, 68px);
}

.section-head > div:first-child {
  max-width: 760px;
  text-wrap: balance;
}

.section-head .lead {
  margin-top: 14px;
}

.section-note {
  max-width: 30ch;
  margin: 0;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  line-height: 1.55;
  color: var(--color-muted);
  text-align: right;
}

/* Work ledger */
.work-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(260px, 340px);
  gap: clamp(32px, 5vw, 80px);
  align-items: start;
}

.work-main {
  min-width: 0;
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.filter {
  padding: 8px 12px;
  border: 1px solid var(--color-rule);
  color: var(--color-ink-2);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  line-height: 1.2;
  transition: background-color var(--dur) var(--ease), border-color var(--dur) var(--ease), color var(--dur) var(--ease);
}

.filter:hover {
  border-color: var(--color-ink);
  color: var(--color-ink);
}

.filter.is-active {
  border-color: var(--color-ink);
  background: var(--color-ink);
  color: var(--color-paper);
}

.work-list {
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--color-ink);
  list-style: none;
}

.work-item {
  border-bottom: 1px solid var(--color-rule);
}

.work-row {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
  width: 100%;
  padding: 14px 0;
}

.work-thumb {
  display: block;
  width: 92px;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  background: var(--color-paper-2);
}

.work-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 500ms var(--ease);
}

.work-row:hover .work-thumb,
.work-row:focus-visible .work-thumb {
  outline: 1px solid var(--color-accent);
  outline-offset: 2px;
}

.work-copy {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.work-title {
  font-size: 1.08rem;
  font-weight: 500;
  line-height: 1.28;
  letter-spacing: -0.01em;
  color: var(--color-ink);
  transition: color var(--dur) var(--ease);
}

.work-row:hover .work-title {
  color: var(--color-accent);
}

.work-meta {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  line-height: 1.4;
  color: var(--color-muted);
}

.work-open {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  color: var(--color-accent);
  border-bottom: 1px solid transparent;
  transition: border-color var(--dur) var(--ease);
}

.work-row:hover .work-open,
.work-row:focus-visible .work-open {
  border-color: var(--color-accent);
}

.work-preview {
  position: sticky;
  top: calc(var(--nav-h) + 24px);
}

.preview-media {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border: 1px solid var(--color-rule);
  background: var(--color-paper-2);
}

.preview-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: opacity 180ms var(--ease);
}

.preview-media img.is-swapping {
  opacity: 0.3;
}

.preview-cat {
  margin-top: 16px;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  color: var(--color-accent);
}

.preview-title {
  margin-top: 6px;
  font-family: var(--font-display);
  font-size: 1.55rem;
  line-height: 1.06;
}

.preview-note {
  margin-top: 10px;
  font-size: 0.88rem;
  line-height: 1.5;
  color: var(--color-muted);
}

/* Proof archive */
.section--proof {
  padding-block: clamp(56px, 7vw, 92px);
  background: var(--color-paper-2);
  border-block: 1px solid var(--color-rule);
}

.proof-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 36px;
}

.proof-head > div:first-child {
  max-width: 800px;
}

.proof-head .lead {
  margin-top: 14px;
}

.proof-progress {
  display: block;
  width: 180px;
  height: 2px;
  margin-top: 24px;
  overflow: hidden;
  background: var(--color-rule-strong);
}

.proof-progress span {
  display: block;
  width: 100%;
  height: 100%;
  background: var(--color-accent);
  transform: scaleX(0);
  transform-origin: left;
}

/* The certificate archive scrolls horizontally without hijacking page scroll.
   Track width is the sum of the card columns, not the source image pixels. */
.proof-viewport {
  margin-top: clamp(32px, 4vw, 54px);
  /* The section already sits inside .container; avoid adding a second wide gutter. */
  max-width: 100%;
  min-width: 0;
  padding: 0 0 12px;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-padding-inline: 0;
  scroll-snap-type: x proximity;
  scrollbar-width: thin;
  scrollbar-color: var(--color-rule-strong) var(--color-paper-2);
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
}

.proof-viewport::-webkit-scrollbar {
  height: 8px;
}

.proof-viewport::-webkit-scrollbar-track {
  background: var(--color-rule);
}

.proof-viewport::-webkit-scrollbar-thumb {
  background: var(--color-rule-strong);
  border-radius: 999px;
}

.proof-track {
  --proof-card: clamp(260px, 26vw, 340px);
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: var(--proof-card);
  justify-content: start;
  align-items: stretch;
  gap: clamp(16px, 2vw, 28px);
  width: max-content;
  min-width: 0;
  max-width: none;
  margin: 0;
  padding: 0;
  list-style: none;
}

.proof-item {
  width: var(--proof-card);
  max-width: var(--proof-card);
  min-width: 0;
  overflow: hidden;
  scroll-snap-align: start;
}

.proof-card {
  display: flex;
  flex-direction: column;
  width: 100%;
  text-align: left;
}

.proof-media {
  display: block;
  overflow: hidden;
  padding: 10px;
  border: 1px solid var(--color-rule);
  background: var(--color-document);
  box-shadow: 6px 6px 0 var(--color-paper);
  transition: transform var(--dur) var(--ease), border-color var(--dur) var(--ease);
}

.proof-media img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  aspect-ratio: 1.414;
  object-fit: contain;
}

.proof-card:hover .proof-media,
.proof-card:focus-visible .proof-media {
  border-color: var(--color-accent);
  transform: translateY(-4px);
}

.proof-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-top: 14px;
}

.proof-name {
  font-family: var(--font-display);
  font-size: 1.4rem;
  line-height: 1.06;
}

.proof-issuer {
  font-size: 0.82rem;
  line-height: 1.4;
  color: var(--color-ink-2);
}

.proof-id {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  line-height: 1.45;
  color: var(--color-muted);
  overflow-wrap: anywhere;
}

.proof-card--credential {
  justify-content: space-between;
  gap: 24px;
  min-height: 100%;
  padding: clamp(24px, 3vw, 40px);
  border: 1px solid var(--color-band);
  background: var(--color-band);
  color: var(--color-band-ink);
}

.credential-mark {
  font-family: var(--font-display);
  font-size: clamp(3.2rem, 5vw, 5.4rem);
  line-height: 0.86;
  color: var(--color-band-accent);
}

.proof-card--credential .proof-name {
  color: var(--color-band-ink);
}

.proof-card--credential .proof-issuer {
  color: var(--color-band-muted);
}

.proof-note {
  max-width: 32ch;
  font-family: var(--font-mono);
  font-size: 0.64rem;
  line-height: 1.5;
  color: var(--color-band-muted);
}

/* About */
.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(280px, 0.8fr);
  gap: clamp(40px, 6vw, 96px);
  align-items: start;
}

.about-copy {
  min-width: 0;
}

.about-prose {
  max-width: 66ch;
}

.about-prose p {
  margin-top: 20px;
  font-size: 1.05rem;
  line-height: 1.7;
}

.dropcap::first-letter {
  float: left;
  padding-right: 0.08em;
  font-family: var(--font-display);
  font-size: 4.4em;
  line-height: 0.78;
  color: var(--color-accent);
}

.pullquote {
  margin: 40px 0;
  padding: 6px 0 6px 28px;
  border-left: 2px solid var(--color-accent);
}

.pullquote p {
  max-width: 28ch;
  font-family: var(--font-display);
  font-style: italic;
  font-size: clamp(1.5rem, 2vw, 2.1rem);
  line-height: 1.15;
  color: var(--color-ink);
}

.about-aside {
  position: sticky;
  top: calc(var(--nav-h) + 32px);
  padding-top: 20px;
  border-top: 2px solid var(--color-ink);
}

.about-stamp {
  padding: 20px;
  border: 1px solid var(--color-rule);
  background: var(--color-paper-3);
}

.stamp-mark {
  display: block;
  font-family: var(--font-display);
  font-size: 2.6rem;
  line-height: 1;
  color: var(--color-accent);
}

.stamp-note {
  display: block;
  margin-top: 6px;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  line-height: 1.45;
  color: var(--color-muted);
}

.fact-list {
  margin: 24px 0 0;
}

.fact-list > div {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  gap: 12px;
  padding: 10px 0;
  border-bottom: 1px solid var(--color-rule);
}

.fact-list dt {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  line-height: 1.45;
  color: var(--color-muted);
}

.fact-list dd {
  margin: 0;
  font-size: 0.85rem;
  line-height: 1.45;
  color: var(--color-ink-2);
}

/* Skills map */
.section--skills {
  border-top: 1px solid var(--color-rule);
}

.skills-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(300px, 0.75fr);
  gap: clamp(40px, 6vw, 88px);
  align-items: center;
}

.skill-map {
  position: relative;
  aspect-ratio: 600 / 520;
  overflow: hidden;
  border: 1px solid var(--color-rule);
  background: var(--color-paper-3);
}

.map-lines {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  color: var(--color-rule-strong);
}

.map-lines path {
  fill: none;
  stroke: currentColor;
  stroke-width: 1;
  vector-effect: non-scaling-stroke;
  transition: stroke var(--dur) var(--ease), stroke-width var(--dur) var(--ease);
}

.map-lines path.is-active {
  stroke: var(--color-accent);
  stroke-width: 2;
}

.map-center {
  position: absolute;
  top: 50%;
  left: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 104px;
  height: 104px;
  border: 1px solid var(--color-ink);
  background: var(--color-ink);
  color: var(--color-paper);
  transform: translate(-50%, -50%);
}

.map-mark {
  font-family: var(--font-display);
  font-size: 2rem;
  line-height: 1;
}

.map-name {
  margin-top: 3px;
  font-family: var(--font-mono);
  font-size: 0.6rem;
}

.map-node {
  position: absolute;
  top: var(--y);
  left: var(--x);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 8px;
  transform: translate(-50%, -50%);
}

.node-dot {
  width: 14px;
  height: 14px;
  border: 1px solid var(--color-ink);
  background: var(--color-paper-3);
  transition: background-color var(--dur) var(--ease), border-color var(--dur) var(--ease), transform var(--dur) var(--ease);
}

.map-node[aria-pressed="true"] .node-dot {
  border-color: var(--color-accent);
  background: var(--color-accent);
  transform: scale(1.3);
}

.node-label {
  padding: 2px 6px;
  border: 1px solid transparent;
  background: var(--color-paper-3);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  line-height: 1.3;
  color: var(--color-ink);
  transition: border-color var(--dur) var(--ease), color var(--dur) var(--ease);
}

.map-node:hover .node-label,
.map-node[aria-pressed="true"] .node-label {
  border-color: var(--color-rule);
  color: var(--color-accent);
}

.skill-readout {
  min-height: 310px;
  padding-top: 24px;
  border-top: 2px solid var(--color-ink);
}

.skill-panel h3 {
  font-size: clamp(2rem, 2.6vw, 3rem);
}

html.js .skill-panel:not(.is-active) {
  display: none;
}

.skill-panel + .skill-panel {
  margin-top: 32px;
}

.panel-level {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-top: 12px;
  font-size: 1rem;
}

.panel-tools {
  margin-top: 20px;
  font-family: var(--font-mono);
  font-size: 0.76rem;
  line-height: 1.65;
  color: var(--color-ink-2);
}

.panel-evidence {
  max-width: 42ch;
  margin-top: 12px;
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--color-muted);
}

.tool-groups {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--gap);
  margin-top: clamp(48px, 6vw, 80px);
  padding-top: 24px;
  border-top: 1px solid var(--color-rule);
}

.tool-groups h3 {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0;
  color: var(--color-muted);
}

.tool-groups ul {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin: 12px 0 0;
  padding: 0;
  font-size: 0.9rem;
  list-style: none;
}

/* Journal */
.journal-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(300px, 0.75fr);
  gap: clamp(40px, 6vw, 88px);
  align-items: start;
}

.video-frame {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border: 1px solid var(--color-rule);
  background: var(--color-ink);
}

.video-poster {
  position: absolute;
  inset: 0;
  display: block;
}

.video-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.94;
  transition: opacity var(--dur) var(--ease), transform 600ms var(--ease);
}

.video-poster:hover img {
  opacity: 1;
}

.play {
  position: absolute;
  top: 50%;
  left: 50%;
  display: grid;
  width: 64px;
  height: 64px;
  place-items: center;
  border: 1px solid var(--color-ink);
  background: var(--color-paper);
  color: var(--color-ink);
  transform: translate(-50%, -50%);
  transition: background-color var(--dur) var(--ease), border-color var(--dur) var(--ease), color var(--dur) var(--ease);
}

.video-poster:hover .play {
  border-color: var(--color-accent);
  background: var(--color-accent);
<｜begin▁of▁sentence｜>  color: var(--color-accent-ink);
}

.video-frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

.video-meta {
  padding-top: 18px;
}

.video-meta h3 {
  margin-top: 10px;
  font-size: clamp(1.5rem, 2vw, 2.1rem);
}

.video-note {
  max-width: 48ch;
  margin-top: 10px;
  font-size: 0.92rem;
  color: var(--color-muted);
}

.article-list {
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--color-ink);
  list-style: none;
}

.article-list li {
  border-bottom: 1px solid var(--color-rule);
}

.article-list a {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 16px 0;
  text-decoration: none;
}

.article-list time {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  color: var(--color-muted);
}

.article-list span {
  font-size: 0.98rem;
  line-height: 1.35;
  transition: color var(--dur) var(--ease);
}

.article-list a:hover span {
  color: var(--color-accent);
}

.channel-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 32px;
  margin-top: 32px;
  font-size: 0.85rem;
}

.channel-links a {
  text-decoration-color: var(--color-rule-strong);
}

/* Contact */
.section--contact {
  background: var(--color-band);
  color: var(--color-band-ink);
  border-top: 1px solid var(--color-band-rule);
}

.section--contact .lead {
  color: var(--color-band-muted);
}

.section--contact :focus-visible,
.site-footer :focus-visible {
  outline-color: var(--color-band-accent);
}

.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(300px, 0.85fr);
  gap: clamp(48px, 7vw, 104px);
  align-items: start;
}

.contact-copy h2 {
  color: var(--color-band-ink);
  text-wrap: balance;
}

.contact-copy .lead {
  margin-top: 16px;
}

.contact-form {
  margin-top: 40px;
}

.field-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.field {
  margin-bottom: 18px;
}

.field label {
  display: block;
  margin-bottom: 6px;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  color: var(--color-band-muted);
}

.field input,
.field textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--color-band-rule);
  border-radius: 0;
  background: transparent;
  color: var(--color-band-ink);
  transition: border-color var(--dur) var(--ease), background-color var(--dur) var(--ease);
}

.field input:focus,
.field textarea:focus {
  border-color: var(--color-band-accent);
  outline: 1px solid var(--color-band-accent);
  outline-offset: 2px;
}

.field input[aria-invalid="true"],
.field textarea[aria-invalid="true"] {
  border-color: var(--color-band-error);
}

.field textarea {
  min-height: 140px;
  resize: vertical;
}

.honeypot {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.form-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 4px;
}

.form-status {
  margin-top: 14px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  line-height: 1.5;
  color: var(--color-band-accent);
}

.form-status[data-tone="error"] {
  color: var(--color-band-error);
}

.form-status[data-tone="ok"] {
  color: var(--color-band-success);
}

.form-help {
  margin-top: 10px;
  font-size: 0.78rem;
  line-height: 1.5;
  color: var(--color-band-muted);
}

.contact-aside {
  padding-top: 24px;
  border-top: 1px solid var(--color-band-rule);
}

.contact-label {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  color: var(--color-band-muted);
}

.contact-email {
  display: block;
  margin-top: 10px;
  overflow-wrap: anywhere;
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 3vw, 2.7rem);
  line-height: 1.05;
  color: var(--color-band-ink);
  text-decoration: none;
}

.contact-email:hover {
  color: var(--color-band-accent);
}

.contact-list {
  margin: 28px 0 0;
}

.contact-list > div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 0;
  border-bottom: 1px solid var(--color-band-rule);
}

.contact-list dt {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  color: var(--color-band-muted);
}

.contact-list dd {
  margin: 0;
  font-size: 0.86rem;
  text-align: right;
}

.contact-list a {
  color: var(--color-band-ink);
  text-decoration-color: var(--color-band-rule);
}

.contact-list a:hover {
  color: var(--color-band-accent);
}

.contact-cv {
  width: 100%;
  margin-top: 28px;
}

/* Footer */
.site-footer {
  padding-block: 56px 24px;
  background: var(--color-band);
  color: var(--color-band-ink);
  border-top: 1px solid var(--color-band-rule);
}

.footer-top {
  display: flex;
  justify-content: space-between;
  gap: 48px;
  padding-bottom: 40px;
  border-bottom: 1px solid var(--color-band-rule);
}

.footer-wordmark {
  font-family: var(--font-display);
  font-size: clamp(2rem, 3vw, 2.8rem);
  line-height: 1;
}

.footer-line {
  max-width: 36ch;
  margin-top: 10px;
  font-size: 0.84rem;
  line-height: 1.5;
  color: var(--color-band-muted);
}

.footer-nav {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, auto));
  gap: 48px;
}

.footer-label {
  margin-bottom: 10px;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--color-band-muted);
}

.footer-nav nav {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.84rem;
}

.footer-nav a {
  color: var(--color-band-ink);
  text-decoration: none;
}

.footer-nav a:hover {
  color: var(--color-band-accent);
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  padding-top: 20px;
  font-family: var(--font-mono);
  font-size: 0.64rem;
  line-height: 1.5;
  color: var(--color-band-muted);
}

.footer-status:empty {
  display: none;
}

.footer-share,
.footer-top-link {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  color: var(--color-band-ink);
  text-decoration: underline;
  text-decoration-color: var(--color-band-rule);
}

.footer-share:hover,
.footer-top-link:hover {
  color: var(--color-band-accent);
}

/* Dialogs */
.dialog {
  width: min(960px, calc(100% - 32px));
  max-height: 90svh;
  padding: 0;
  border: 1px solid var(--color-ink);
  background: var(--color-paper);
  color: var(--color-ink);
}

.dialog::backdrop {
  background: var(--color-backdrop);
}

.dialog-panel {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  max-height: 90svh;
  overflow: auto;
}

.dialog-media {
  border-right: 1px solid var(--color-rule);
  background: var(--color-document);
}

.dialog-media img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.dialog-media--cert img {
  padding: 16px;
}

.dialog-body {
  padding: clamp(24px, 3vw, 40px);
}

.dialog-close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  padding: 8px 10px;
  border: 1px solid var(--color-ink);
  background: var(--color-paper);
  font-family: var(--font-mono);
  font-size: 0.64rem;
}

.dialog-body h2 {
  margin-top: 8px;
  font-size: clamp(1.8rem, 3vw, 2.6rem);
}

.dialog-desc {
  margin-top: 16px;
  font-size: 0.94rem;
  line-height: 1.6;
  color: var(--color-ink-2);
}

.dialog-facts {
  margin: 24px 0 0;
  border-top: 1px solid var(--color-rule);
}

.dialog-facts > div {
  display: grid;
  grid-template-columns: 80px minmax(0, 1fr);
  gap: 12px;
  padding: 8px 0;
  border-bottom: 1px solid var(--color-rule);
}

.dialog-facts dt {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  color: var(--color-muted);
}

.dialog-facts dd {
  margin: 0;
  font-size: 0.84rem;
  line-height: 1.45;
}

.dialog-links {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 20px;
  font-size: 0.84rem;
}

.dialog-links a {
  color: var(--color-accent);
}

/* Reveal */
html.js.reveal-ready [data-reveal] {
  opacity: 0;
  transform: translateY(16px);
}

html.js.reveal-ready [data-reveal].is-in {
  opacity: 1;
  transform: none;
  transition: opacity 600ms var(--ease), transform 600ms var(--ease);
}

/* Tablet */
@media (max-width: 63.999rem) {
  .nav {
    display: none;
  }

  .menu {
    display: block;
  }

  .hero-copy {
    grid-column: 1 / span 7;
  }

  .hero-visual {
    grid-column: 8 / span 5;
  }

  .work-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .work-preview {
    display: none;
  }

  .about-grid {
    grid-template-columns: 1fr;
  }

  .about-aside {
    position: static;
    max-width: 620px;
  }

  .skills-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .skill-map {
    width: 100%;
    max-width: 680px;
  }

  .skill-readout {
    min-height: 0;
    max-width: 620px;
  }

  .journal-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .contact-grid {
    grid-template-columns: 1fr;
  }

  .proof-track {
    --proof-card: min(62vw, 420px);
  }

  .proof-item {
    width: var(--proof-card);
    max-width: var(--proof-card);
  }

  .dialog-panel {
    grid-template-columns: minmax(0, 1fr);
  }

  .dialog-media {
    border-right: 0;
    border-bottom: 1px solid var(--color-rule);
  }

  .dialog-media img {
    max-height: 38svh;
  }
}

/* Small tablet and phone */
@media (max-width: 47.999rem) {
  .masthead-inner {
    gap: 12px;
  }

  .brand-name {
    font-size: 1.2rem;
  }

  .masthead-actions {
    margin-left: auto;
  }

  .hero-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero-copy,
  .hero-visual {
    grid-column: 1;
  }

  .hero-visual {
    width: 100%;
    max-width: 430px;
    margin-top: 36px;
  }

  .hero-card {
    bottom: 44px;
    left: 12px;
  }

  .hero-vertical {
    display: none;
  }

  .hero-facts dl {
    grid-template-columns: 1fr;
  }

  .hero-facts dl > div {
    padding: 14px 0;
    border-right: 0;
    border-bottom: 1px solid var(--color-rule);
  }

  .hero-facts dl > div:last-child {
    border-bottom: 0;
  }

  .section-head,
  .proof-head {
    flex-direction: column;
    align-items: flex-start;
    gap: 18px;
  }

  .section-note {
    max-width: 40ch;
    text-align: left;
  }

  .proof-track {
    --proof-card: min(78vw, 340px);
  }

  .proof-item {
    width: var(--proof-card);
    max-width: var(--proof-card);
  }

  .work-row {
    grid-template-columns: 64px minmax(0, 1fr);
    gap: 14px;
  }

  .work-thumb {
    width: 64px;
  }

  .work-open {
    display: none;
  }

  .skill-map {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1px;
    aspect-ratio: auto;
    border: 1px solid var(--color-rule);
    background: var(--color-rule);
  }

  .map-lines,
  .map-center {
    display: none;
  }

  .map-node {
    position: static;
    flex-direction: row;
    justify-content: center;
    gap: 10px;
    padding: 26px 12px;
    background: var(--color-paper-3);
    transform: none;
  }

  .map-node[aria-pressed="true"] {
    background: var(--color-accent-soft);
  }

  .tool-groups {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px var(--gap);
  }

  .field-row {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .footer-top {
    flex-direction: column;
  }

  .footer-nav {
    gap: 32px;
  }

  .footer-bottom {
    justify-content: flex-start;
  }
}

@media (max-width: 35.999rem) {
  .button--small {
    display: none;
  }

  .hero-actions .button {
    flex: 1 1 auto;
  }

  .hero-card {
    width: 152px;
    padding: 14px;
  }

  .hero-card-figure {
    font-size: 2.7rem;
  }

  .contact-email {
    font-size: 1.45rem;
  }

  .contact-list > div {
    flex-direction: column;
    gap: 3px;
  }

  .contact-list dd {
    text-align: left;
  }

  .footer-nav {
    grid-template-columns: 1fr;
  }
}
