:root {
  --paper: #ffffff;
  --tile: #f4f5f1;
  --ink: #101210;
  --stone: #55594f;
  --stone-2: #3f433a;
  --rule: #dadcd3;
  --rule-strong: #9da295;
  --lime: #c8f03c;
  --lime-ink: #2c3a05;
  --on-dark-muted: #a9aea1;
  --sans: "Inter Tight", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --gutter: clamp(16px, 4vw, 40px);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
a:focus-visible, summary:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
  border-radius: 4px;
}

.wrap { max-width: 1200px; margin: 0 auto; padding: 0 var(--gutter); }

.mono { font-family: var(--mono); }
.label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--stone);
  margin: 0 0 12px;
}

mark {
  background: var(--lime);
  color: var(--ink);
  padding: 0 0.15em;
  border-radius: 4px;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}

/* nav */
.nav { display: flex; justify-content: space-between; align-items: center; padding: 20px 0; font-size: 14px; flex-wrap: wrap; gap: 10px; }
.brand { font-weight: 500; letter-spacing: -0.01em; white-space: nowrap; }
.brand mark { font-size: inherit; padding: 0 4px; margin-left: 1px; border-radius: 3px; }
.nav ul { display: flex; flex-wrap: wrap; justify-content: flex-end; row-gap: 8px; column-gap: 18px; margin: 0; padding: 0; list-style: none; align-items: center; color: var(--stone); }
.nav ul li { white-space: nowrap; }
.nav a:hover { color: var(--ink); }
.pill { background: var(--ink); color: var(--paper) !important; padding: 6px 14px; border-radius: 99px; }
.pill:hover { background: var(--stone-2); }

.eyebrow { font-family: var(--mono); font-size: 12px; color: var(--stone); margin: 0 0 18px; }

/* hero */
.hero { padding: clamp(8px, 2vw, 28px) 0 clamp(28px, 5vw, 48px); }
.hero h1 {
  font-size: clamp(34px, 6.4vw, 64px);
  line-height: 1.04;
  font-weight: 500;
  letter-spacing: -0.035em;
  margin: 0 0 22px;
  max-width: 16em;
}
.hero p.lede { font-size: 17px; color: var(--stone-2); max-width: 34em; margin: 0; }

.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-top: 32px; max-width: 640px; }
.stat { background: var(--tile); border-radius: 12px; padding: 14px 16px; }
.stat .num { display: block; font-size: 24px; font-weight: 500; letter-spacing: -0.01em; }
.stat .lbl { display: block; font-size: 12.5px; color: var(--stone); margin-top: 4px; line-height: 1.35; }

/* sections */
section { padding: clamp(24px, 4vw, 40px) 0; }

/* technology tiles */
.tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.tile {
  background: var(--tile);
  border: 0.5px solid var(--rule);
  border-radius: 14px;
  padding: 18px;
  min-height: 200px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.tile .tag { font-family: var(--mono); font-size: 11px; color: var(--stone); }
.tile h3 { font-size: 19px; font-weight: 500; letter-spacing: -0.015em; line-height: 1.2; margin: 0 0 8px; }
.tile p { font-size: 13px; line-height: 1.5; color: var(--stone); margin: 0; }
.tile.dark { background: var(--ink); border-color: var(--ink); }
.tile.dark .tag { color: var(--lime); }
.tile.dark h3 { color: #fff; }
.tile.dark p { color: var(--on-dark-muted); }
.tile.lime { background: var(--lime); border-color: var(--lime); }
.tile.lime .tag, .tile.lime p { color: var(--lime-ink); }

/* technical skills */
.skill-group { margin-bottom: 20px; }
.skill-group:last-child { margin-bottom: 0; }
.skill-group-label { font-family: var(--mono); font-size: 12px; color: var(--stone); margin: 0 0 10px; }
.chip-row { display: flex; flex-wrap: wrap; gap: 8px; }

.chip {
  font-family: var(--mono);
  font-size: 12px;
  padding: 4px 11px;
  border-radius: 99px;
  border: 0.5px solid transparent;
  white-space: nowrap;
}
.chip-slate { background: #e7edf3; color: #2b4a6b; border-color: #c7d6e3; }
.chip-teal { background: #e3f1ed; color: #1f5c4e; border-color: #bfe0d6; }
.chip-amber { background: #fbf0de; color: #7a5410; border-color: #efd9ae; }
.chip-lime { background: #f3fbd9; color: #47600b; border-color: #d8ed9c; }
.chip-plum { background: #f1e9f5; color: #5b2e6b; border-color: #dfc7e8; }
.chip-coral { background: #fbeae3; color: #92371b; border-color: #f0c3ae; }

/* lists: work + experience */
.rows { border-top: 0.5px solid var(--rule-strong); }
.row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 0.5px solid var(--rule-strong);
}
.row .title { font-size: 20px; font-weight: 500; letter-spacing: -0.015em; }
.row .meta { font-family: var(--mono); font-size: 12px; color: var(--stone); text-align: right; }

.proj-list { border-top: 0.5px solid var(--rule-strong); }
.proj-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 24px;
  padding: 20px 0;
  border-bottom: 0.5px solid var(--rule-strong);
  transition: padding-left 0.2s ease;
}
.proj-row:hover { padding-left: 8px; }
.proj-row .proj-main { max-width: 560px; }
.proj-row .title { display: block; font-size: 20px; font-weight: 500; letter-spacing: -0.015em; margin-bottom: 8px; }
.proj-row .proj-desc { font-size: 14px; line-height: 1.6; color: var(--stone-2); margin: 0 0 10px; }
.proj-row .proj-stack { margin: 0; }
.proj-row .meta { font-family: var(--mono); font-size: 12px; color: var(--stone); text-align: right; white-space: nowrap; padding-top: 3px; }
.proj-row:hover .meta { color: var(--ink); }

.exp-block { padding: 22px 0; border-top: 0.5px solid var(--rule-strong); }
.exp-block:last-child { border-bottom: 0.5px solid var(--rule-strong); }
.exp-block h3 { font-size: 19px; font-weight: 500; margin: 0 0 12px; letter-spacing: -0.01em; }
.exp-list { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 10px; }
.exp-list li { font-size: 14.5px; line-height: 1.6; color: var(--stone-2); padding-left: 16px; position: relative; }
.exp-list li::before { content: ""; position: absolute; left: 0; top: 0.65em; width: 5px; height: 5px; border-radius: 50%; background: var(--rule-strong); }

/* contact + footer */
.contact { padding: clamp(40px, 8vw, 80px) 0; }
.contact h2 { font-size: clamp(30px, 5vw, 52px); line-height: 1.05; font-weight: 500; letter-spacing: -0.03em; margin: 0 0 20px; max-width: 14em; }
.links { display: flex; flex-wrap: wrap; gap: 10px; }
.links a { border: 0.5px solid var(--rule-strong); border-radius: 99px; padding: 8px 16px; font-size: 14px; }
.links a:hover { background: var(--ink); color: var(--paper); border-color: var(--ink); }
footer { border-top: 0.5px solid var(--rule); padding: 20px 0 32px; font-family: var(--mono); font-size: 12px; color: var(--stone); display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

@media (max-width: 900px) {
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stats { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: none; }
}
@media (max-width: 640px) {
  .nav ul li:not(:last-child) { display: none; }
  .tiles { grid-template-columns: 1fr; }
  .tile { min-height: 150px; }
  .row { flex-direction: column; gap: 4px; }
  .row .meta { text-align: left; }
  .proj-row { flex-direction: column; gap: 6px; }
  .proj-row .meta { text-align: left; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .row { transition: none; }
}
