:root {
  --ink: #262626;
  --muted: #666;
  --paper: #f7f7f4;
  --panel: #fff;
  --frame: #353535;
  --line: #c9c9c3;
  --orange: #b7461f;
  --blue: #3178b8;
  --green: #4f7b47;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background:
    repeating-linear-gradient(0deg, rgba(255,255,255,.018) 0, rgba(255,255,255,.018) 1px, transparent 1px, transparent 4px),
    repeating-linear-gradient(90deg, rgba(255,255,255,.012) 0, rgba(255,255,255,.012) 1px, transparent 1px, transparent 4px),
    #171817;
  font: 12px/1.55 Verdana, Tahoma, Arial, sans-serif;
}

a { color: #245f92; }
a:hover { color: #d9531e; }
button, input { font: inherit; }
.skip-link { position: fixed; top: -50px; left: 12px; z-index: 20; padding: 7px 10px; background: white; border: 1px solid #222; }
.skip-link:focus { top: 12px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

.site-shell { width: 960px; max-width: calc(100% - 20px); margin: 0 auto; }
.masthead {
  min-height: 106px;
  display: grid;
  grid-template-columns: auto 1fr 265px;
  align-items: center;
  gap: 22px;
  color: white;
  border-bottom: 1px solid #070707;
}
.wordmark {
  color: #f5f5f5;
  text-decoration: none;
  font: 38px/1 "Trebuchet MS", Arial, sans-serif;
  letter-spacing: -3px;
  text-shadow: 0 2px 0 #000, 0 0 12px rgba(255,255,255,.18);
  white-space: nowrap;
}
.wordmark em { font: italic 40px/1 Georgia, serif; }
.site-nav { display: flex; justify-content: center; gap: 5px; }
.site-nav a {
  padding: 8px 11px;
  color: #d9d9d9;
  text-decoration: none;
  font-weight: bold;
  text-shadow: 0 -1px #000;
  border: 1px solid transparent;
}
.site-nav a:hover, .site-nav a:focus-visible {
  color: white;
  border-color: #4b4b4b;
  border-radius: 3px;
  background: linear-gradient(#515151, #282828 52%, #1b1b1b 53%, #303030);
}
.site-nav .language-link { padding-inline: 7px; color: #9fc8e8; font: bold 10px/1.4 Verdana, sans-serif; }
.site-nav .language-link.is-current { color: white; border-color: #5d5d5d; border-radius: 3px; background: #252525; box-shadow: inset 0 1px #555; }
.site-search { display: flex; height: 31px; }
.site-search input {
  min-width: 0;
  width: 200px;
  padding: 6px 8px;
  color: #555;
  background: linear-gradient(#ddd, #fff 7px);
  border: 1px solid #777;
  border-right: 0;
  box-shadow: inset 0 1px 2px rgba(0,0,0,.18);
}
.site-search button, .button {
  padding: 6px 13px;
  border: 1px solid #1c5485;
  border-radius: 2px;
  color: white;
  background: linear-gradient(#65a5dd 0, #3e8bca 48%, #2f76b5 50%, #245f9b 100%);
  box-shadow: inset 0 1px rgba(255,255,255,.45), 0 1px 2px rgba(0,0,0,.28);
  text-decoration: none;
  font-weight: bold;
  text-shadow: 0 -1px #164b78;
  cursor: pointer;
}
.site-search button:hover, .button:hover { color: white; filter: brightness(1.08); }
.button-secondary {
  color: #3d3d3d;
  border-color: #96968f;
  background: linear-gradient(#fff 0, #eee 48%, #deded9 50%, #f1f1ed 100%);
  box-shadow: inset 0 1px white, 0 1px 2px rgba(0,0,0,.2);
  text-shadow: 0 1px white;
}
.button-secondary:hover { color: #222; }
.menu-toggle { display: none; padding: 6px 10px; color: white; border: 1px solid #666; background: linear-gradient(#555, #222); }

.layout { display: grid; grid-template-columns: 640px 310px; gap: 10px; align-items: start; padding-top: 10px; }
.main-column, .sidebar { display: grid; gap: 10px; }
.card {
  background: var(--panel);
  border: 1px solid #888;
  box-shadow: 0 0 0 5px var(--frame), 0 3px 8px rgba(0,0,0,.55), inset 0 1px white;
}
.main-column > .card, .main-column section > .card { margin: 5px; }
.sidebar > .card { margin: 5px; }
.eyebrow, .section-heading span {
  color: #666;
  text-transform: uppercase;
  letter-spacing: .08em;
  font: bold 10px/1.2 "Courier New", monospace;
}

.hero-card {
  min-height: 342px;
  padding: 30px 32px 27px;
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #fff 0, #fff 70%, #f1f0e9 100%);
}
.hero-card::after {
  content: "</>";
  position: absolute;
  right: -15px;
  bottom: -42px;
  color: #ecebe5;
  font: bold 112px/1 "Courier New", monospace;
  letter-spacing: -18px;
  transform: rotate(-8deg);
  pointer-events: none;
}
h1, h2, h3, h4, p { margin-top: 0; }
h1 {
  max-width: 560px;
  margin: 14px 0 18px;
  color: #202020;
  font: bold 36px/.98 "Trebuchet MS", Arial, sans-serif;
  letter-spacing: -2.5px;
  text-shadow: 0 1px white;
  position: relative;
  z-index: 1;
}
h1 span, .prose-card h2 span { color: var(--orange); font-family: Georgia, serif; font-weight: normal; font-style: italic; }
h1 span a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.hero-copy { max-width: 510px; color: #555; font-size: 13px; position: relative; z-index: 1; }
.hero-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 14px; margin-top: 23px; position: relative; z-index: 1; }
.text-link { font-size: 11px; }

.section-heading {
  margin: 5px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  color: #eee;
  border: 1px solid #101010;
  border-radius: 2px;
  background: linear-gradient(#4b4b4b, #292929 49%, #202020 50%, #333);
  box-shadow: inset 0 1px #666, 0 2px 4px rgba(0,0,0,.35);
  text-shadow: 0 -1px #000;
}
.section-heading span { color: #b9b9b9; }
.section-heading h2 { margin: 3px 0 0; font: bold 22px/1 "Trebuchet MS", Arial, sans-serif; letter-spacing: -1px; }
.section-heading p { max-width: 245px; margin: 0; color: #bbb; text-align: right; font-size: 10px; }
.project-list { display: grid; gap: 10px; }
.search-status {
  margin: 0;
  padding: 9px 12px;
  color: #444;
  border: 1px solid #aaa;
  background: #f4f4ef;
  font: bold 10px "Courier New", monospace;
}
.project[hidden], .search-status[hidden] { display: none; }
.project { display: grid; grid-template-columns: 55px 1fr; padding: 23px 25px 21px 18px; }
.project-number { color: var(--orange); font: bold 13px "Courier New", monospace; }
.project-meta { display: flex; align-items: center; justify-content: space-between; color: #666; font: bold 10px "Courier New", monospace; }
.badge {
  padding: 2px 7px;
  color: #365d32;
  border: 1px solid #86a680;
  border-radius: 9px;
  background: linear-gradient(#f5fff3, #cfe5ca);
  text-transform: uppercase;
  box-shadow: inset 0 1px white;
}
.badge-blue { color: #275d84; border-color: #8bb3ce; background: linear-gradient(#f4fbff, #cfe5f2); }
.badge-gray { color: #555; border-color: #aaa; background: linear-gradient(#fff, #ddd); }
.project h3 { margin: 10px 0 6px; font: bold 24px/1 "Trebuchet MS", Arial, sans-serif; letter-spacing: -1px; }
.project h3 a { color: #222; text-decoration: none; }
.project h3 a:hover { color: var(--orange); text-decoration: underline; }
.project p { color: #555; }
.tag-list { display: flex; flex-wrap: wrap; gap: 5px; margin: 15px 0; padding: 0; list-style: none; }
.tag-list li {
  padding: 3px 7px;
  border: 1px solid #bbb;
  border-radius: 2px;
  background: linear-gradient(#fff, #e3e3df);
  box-shadow: inset 0 1px white;
  font: bold 9px "Courier New", monospace;
}
.metric { display: flex; justify-content: space-between; padding-top: 11px; border-top: 1px dotted #aaa; color: #666; text-transform: uppercase; font: bold 9px "Courier New", monospace; }
.metric strong { color: #333; }

.prose-card, .timeline-card { padding: 30px 32px; }
.prose-card h2, .timeline-card > h2 { margin: 12px 0 18px; font: bold 31px/1 "Trebuchet MS", Arial, sans-serif; letter-spacing: -1.5px; }
.prose-card .lead { font-size: 14px; font-weight: bold; }
.prose-card > p { max-width: 550px; color: #555; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); margin: 25px 0 0; border: 1px solid #aaa; background: #f3f3ef; box-shadow: inset 0 1px white; }
.stats div { padding: 14px; border-right: 1px solid #bbb; }
.stats div:last-child { border-right: 0; }
.stats dt { color: #333; font: bold 25px/1 "Trebuchet MS", Arial, sans-serif; }
.stats dd { margin: 4px 0 0; color: #666; text-transform: uppercase; font: bold 9px "Courier New", monospace; }
.timeline { margin: 24px 0 0; padding: 0; list-style: none; border-top: 3px double #444; }
.timeline > li { display: grid; grid-template-columns: 105px 1fr; gap: 16px; padding: 18px 0; border-bottom: 1px dotted #aaa; }
.timeline time { color: #c64f25; font: bold 10px "Courier New", monospace; }
.timeline h3 { margin-bottom: 5px; font-size: 14px; }
.timeline p { margin-bottom: 0; color: #666; font-size: 11px; }
.experience-products { display: grid; gap: 8px; margin-top: 14px; }
.experience-products section { padding: 12px; border: 1px solid #c6c6c0; border-left: 4px solid var(--orange); background: linear-gradient(#fafaf8, #efefea); box-shadow: inset 0 1px white; }
.experience-products h4 { margin: 0 0 5px; font-size: 12px; }
.experience-products section p { font-size: 10px; }
.experience-products span { display: block; margin-top: 8px; color: #666; font: bold 8px/1.5 "Courier New", monospace; }

.profile-card { padding: 15px; }
.portrait { height: 218px; position: relative; overflow: hidden; border: 1px solid #999; background: #ddd; padding: 4px; box-shadow: inset 0 0 0 1px white; }
.portrait::before { content: ""; position: absolute; z-index: 1; inset: 4px; opacity: .25; pointer-events: none; background-image: repeating-linear-gradient(0deg, transparent, transparent 3px, rgba(0,0,0,.16) 3px, rgba(0,0,0,.16) 4px); }
.portrait img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center 43%; filter: saturate(.78) contrast(1.04); }
.profile-card h2 { margin: 15px 0 6px; font: bold 24px/.94 "Trebuchet MS", Arial, sans-serif; letter-spacing: -1px; }
.profile-card p { margin-bottom: 2px; color: #666; font-size: 10px; }
.side-section { padding: 14px; }
.side-section > h2 { margin-bottom: 11px; padding: 8px 10px; color: white; border: 1px solid #151515; background: linear-gradient(#505050, #282828 50%, #202020 51%, #333); text-shadow: 0 -1px black; font: bold 16px/1 "Trebuchet MS", Arial, sans-serif; }
.spec-list { margin: 0; padding: 0; list-style: none; }
.spec-list li { display: flex; justify-content: space-between; gap: 8px; padding: 7px 3px; border-bottom: 1px dotted #aaa; font-size: 10px; }
.spec-list li span { color: #666; text-transform: uppercase; font-family: "Courier New", monospace; }
.spec-list b { text-align: right; }
.philosophy blockquote { margin: 14px 4px 16px; color: #444; font: italic 17px/1.25 Georgia, serif; }
.philosophy ul { margin: 0; padding: 0; list-style: none; }
.philosophy li { display: grid; gap: 2px; padding: 8px 3px; border-top: 1px dotted #aaa; }
.philosophy li b { color: #c64f25; font: bold 9px "Courier New", monospace; }
.philosophy li span { color: #666; font-size: 10px; }
.links-card { background: #f1f1ed; }
.profile-links { display: grid; }
.profile-links a { padding: 8px 4px; border-bottom: 1px dotted #aaa; font-size: 10px; font-weight: bold; }
.profile-links a:first-child { display: grid; gap: 2px; margin-bottom: 8px; text-decoration: none; }
.profile-links a:first-child span { color: #666; text-transform: uppercase; font: bold 9px "Courier New", monospace; }
.profile-links a:first-child b { text-decoration: underline; overflow-wrap: anywhere; }
.profile-links a:last-child { border-bottom: 0; }

footer { min-height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 0 5px; color: #858585; font: 9px "Courier New", monospace; text-shadow: 0 1px black; }
footer a { color: #b9b9b9; }
:focus-visible { outline: 2px dotted #ffb13b; outline-offset: 2px; }

@media (max-width: 980px) {
  .site-shell { width: 740px; }
  .masthead { grid-template-columns: auto 1fr; padding: 15px 0; }
  .site-nav { justify-content: flex-end; }
  .site-search { grid-column: 1 / -1; }
  .site-search input { flex: 1; width: auto; }
  .layout { grid-template-columns: 1fr; }
  .sidebar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .links-card { grid-column: 1 / -1; }
}

@media (max-width: 620px) {
  .site-shell { width: calc(100% - 14px); max-width: none; }
  .masthead { min-height: 0; gap: 12px; }
  .wordmark { font-size: 30px; }
  .wordmark em { font-size: 31px; }
  .menu-toggle { display: block; justify-self: end; }
  .site-nav { display: none; grid-column: 1 / -1; padding: 6px; border: 1px solid #555; background: #202020; }
  .site-nav.is-open { display: flex; flex-direction: column; align-items: stretch; }
  .site-nav a { padding: 7px 9px; }
  .hero-card { min-height: 0; padding: 25px 20px 28px; }
  h1 { font-size: clamp(29px, 8.5vw, 38px); }
  .hero-copy { font-size: 12px; }
  .hero-actions { align-items: flex-start; flex-direction: column; }
  .section-heading { align-items: flex-start; flex-direction: column; }
  .section-heading p { text-align: left; }
  .project { grid-template-columns: 1fr; padding: 21px 19px; }
  .project-number { margin-bottom: 9px; }
  .project-meta { align-items: flex-start; gap: 8px; }
  .prose-card, .timeline-card { padding: 25px 20px; }
  .prose-card h2, .timeline-card > h2 { font-size: 27px; }
  .stats { grid-template-columns: 1fr; }
  .stats div { border-right: 0; border-bottom: 1px solid #bbb; }
  .stats div:last-child { border-bottom: 0; }
  .timeline > li { grid-template-columns: 1fr; gap: 6px; }
  .sidebar { grid-template-columns: 1fr; }
  .links-card { grid-column: auto; }
  footer { align-items: flex-start; flex-direction: column; padding: 22px 5px; }
}

@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
