:root {
  color-scheme: light;
  --paper: #f5f2e9;
  --ink: #252e29;
  --muted: #59625a;
  --line: #53665330;
  --case-red: #b43a30;
  --case-green: #2f624b;
  --case-blue: #2456a6;
  --case-violet: #73558d;
  --case-amber: #986217;
  --sans: 'DM Sans', Arial, sans-serif;
  --serif: 'Libre Caslon Display', Georgia, serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: auto; scroll-padding-top: 24px; }
body {
  margin: 0;
  min-width: 280px;
  background: radial-gradient(ellipse at 92% 0%, #bee5db99, transparent 45%),
    linear-gradient(180deg, #e1eee6 0%, #f5f2e9 33%, #f5f2e9 58%, #d3e8c7 100%);
  color: var(--ink);
  font: 1rem/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--case-blue); text-decoration: none; text-underline-offset: 5px; }
a:focus-visible { outline: 2px solid var(--case-blue); outline-offset: 5px; border-radius: 3px; }
a:hover { text-decoration: underline; }
::selection { color: var(--ink); background: #dce7b8; }
p, h1, h2, h3 { margin: 0; }
.page { width: min(1180px, calc(100% - 96px)); margin: auto; }
.skip-link { position: absolute; left: 20px; top: -100px; z-index: 10; padding: 12px; background: var(--paper); }
.skip-link:focus { top: 10px; }
.masthead { display: flex; align-items: center; justify-content: space-between; gap: 28px; flex-wrap: wrap; padding: 30px 0 28px; }
.masthead .resume-link { text-decoration: none; }
.profile { display: flex; flex-wrap: wrap; align-items: center; gap: 22px; min-width: 0; }
.headshot { width: 176px; height: 208px; flex: 0 0 auto; overflow: hidden; border-radius: 20px; background: #d5d8d3; }
.headshot img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 20%; transform: scale(1.7); transform-origin: 50% 20%; }
.profile-copy { min-width: min(100%, 6.5em); flex: 1 1 auto; }
h1 { font: 700 2.65rem/1.08 var(--serif); letter-spacing: -.025em; overflow-wrap: break-word; }
.identity { color: var(--case-blue); }
.identity:hover { text-decoration-thickness: 1px; }
.header-links { display: flex; align-items: center; justify-content: flex-end; gap: 24px; flex-wrap: wrap; margin-left: auto; }
.masthead nav { display: flex; flex-wrap: wrap; align-items: center; gap: 24px; font-size: .875rem; }
.masthead nav a { padding: 12px 0; }
.masthead .social-nav { gap: 16px; border-left: 1px solid var(--line); padding-left: 22px; }
.masthead .social-link { display: flex; align-items: center; justify-content: center; gap: 9px; min-width: 44px; min-height: 44px; padding: 9px 0; }
.social-link:hover { text-decoration: none; }
.social-token { width: 37px; height: 37px; display: grid; place-items: center; border: 1px solid #74816b; border-radius: 11px; box-shadow: 2px 3px 0 #d4d8c9; background: #e8eddd; transition: transform .2s; }
.substack-token { background: #f5dfc6; border-color: #b78658; box-shadow: 2px 3px 0 #e3c4a3; }
.linkedin-token { background: #dceafa; border-color: #7898b7; box-shadow: 2px 3px 0 #bdcee3; }
.gmail-token { background: #f5e2dd; border-color: #b58980; box-shadow: 2px 3px 0 #e3c7c0; }
.social-token img { width: 21px; height: 21px; }
.social-link:hover .social-token, .social-link:focus-visible .social-token { transform: translateY(-3px); }
.summary { padding: 0 0 28px; max-width: 88ch; font-size: 1.0625rem; line-height: 1.7; }
.summary p + p { margin-top: 12px; color: var(--muted); }
.summary a { color: var(--case-blue); text-decoration: underline; text-decoration-thickness: 1px; }
.summary .bookshelf-invitation { margin-top: 14px; }
.bookshelf-invitation a { display: inline-flex; align-items: center; min-height: 44px; padding: 8px 0; }
.section-heading { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding-top: 22px; margin-bottom: 24px; border-top: 1px solid var(--line); }
.section-heading h2 { font: 700 2rem/1.2 var(--serif); letter-spacing: -.025em; }
#projects-heading { color: var(--case-green); }
#essays-heading { color: var(--case-blue); }
.section-link { color: var(--case-blue); font-size: .875rem; }
.project-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.project, .essay { min-width: 0; background: #faf9f3bd; border: 1px solid #ffffffb3; border-radius: 14px; transition: transform .28s cubic-bezier(.2,.7,.2,1), box-shadow .28s ease, border-color .28s ease; }
.project { display: flex; flex-direction: column; padding: 18px 24px 26px; }
.work-visual { display: flex; align-items: center; justify-content: center; flex: 0 0 auto; height: 324px; margin-bottom: 20px; }
.work-visual > img, .work-visual > .glass-display { width: 200px; max-width: 100%; }
.work-visual > img { display: block; height: auto; transition: transform .2s; }
.work-visual:hover > img, .work-visual:hover > .glass-display { transform: translateY(-4px); }
.work-copy { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.work-meta { display: flex; align-items: baseline; flex-wrap: wrap; justify-content: space-between; gap: 8px 12px; margin-bottom: 13px; font-size: .875rem; color: var(--muted); }
.status { border: 1px solid var(--line); padding: 1px 7px; border-radius: 4px; line-height: 1.5; }
[data-project="iqsaga"] { --title-color: var(--case-red); }
[data-project="looped"] { --title-color: var(--case-green); }
[data-project="gridledger"] { --title-color: var(--case-amber); }
[data-essay="village"] { --title-color: var(--case-blue); }
[data-essay="product"] { --title-color: var(--case-violet); }
h3 { color: var(--title-color); font: 700 2rem/1.08 var(--serif); letter-spacing: -.02em; overflow-wrap: anywhere; }
h3 a { color: inherit; }
.project h3 { min-height: 1.08em; }
h3 a:hover { text-decoration-thickness: 1px; }
.work-copy > p { color: var(--muted); font-size: 1rem; line-height: 1.6; margin: 11px 0 21px; }
.text-link { display: inline-flex; align-items: baseline; align-self: flex-start; flex-wrap: wrap; gap: 9px; max-width: 100%; margin-top: auto; border-bottom: 1px solid currentColor; padding: 4px 0; color: var(--case-blue); font-size: .875rem; font-weight: 650; overflow-wrap: anywhere; }
.text-link:hover { text-decoration: none; border-bottom-width: 2px; padding-bottom: 3px; }
.writing { margin-top: 46px; }
.essay-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.essay { display: grid; grid-template-columns: minmax(130px, 36%) minmax(0, 1fr); gap: 23px; align-items: center; padding: 23px; }
.essay .work-visual { height: auto; margin: 0; }
.essay .work-copy { align-self: stretch; padding: 8px 0; }
.essay .text-link { margin-top: auto; }
.essay .work-copy > p { margin-bottom: 18px; }
.essay h3 { font-size: 1.9rem; min-height: 2.16em; }
/* Original artwork stays independently layered inside each glass case. */
.glass-display { position: relative; width: 100%; aspect-ratio: 989/1591; display: block; overflow: hidden; transition: transform .2s; }
.glass-display .case-photo { display: block; width: 100%; height: auto; }
.glass-display .glass-insert { display: block; position: absolute; object-fit: contain; margin: 0; background: var(--paper); border-radius: 4%; }
.case-village .glass-insert { left: 18%; top: 23.9%; width: 67%; height: 68.8%; }
.case-product .glass-insert { left: 18%; top: 24.2%; width: 66.6%; height: 62%; background: #ec0028; }
.case-gridledger .glass-insert { left: 20.8%; top: 22.1%; width: 63%; height: 72%; padding: 0 4.5%; background: var(--paper); }
.case-looped .glass-insert { left: 20.1%; top: 23.8%; width: 65.2%; height: 69.1%; }
footer { display: flex; justify-content: flex-end; align-items: baseline; flex-wrap: wrap; gap: 12px 24px; padding: 24px 0 30px; margin-top: 44px; border-top: 1px solid var(--line); }
.back-top { font-size: .875rem; color: var(--case-blue); }
@media (max-width: 1050px) {
  .page { width: calc(100% - 56px); }
  .header-links { gap: 22px; }
  .masthead .social-nav { gap: 15px; padding-left: 20px; }
  .social-label { display: none; }
  .masthead nav { gap: 20px; }
  .masthead { gap: 22px; }
  .project-grid, .essay-grid { gap: 16px; }
  .project { padding: 14px 18px 23px; }
  .project h3 { min-height: 2.16em; }
  .work-visual { height: 290px; }
  .work-visual > img, .work-visual > .glass-display { width: 180px; }
  .essay { grid-template-columns: minmax(110px, 34%) minmax(0, 1fr); gap: 17px; padding: 18px; }
  .essay h3 { font-size: 1.75rem; }
}
@media (max-width: 760px) {
  .page { width: calc(100% - 40px); }
  .masthead { padding: 24px 0 20px; gap: 20px; }
  .profile { gap: 17px; }
  .headshot { width: 152px; height: 180px; border-radius: 18px; }
  h1 { font-size: 2.35rem; }
  .header-links { width: 100%; justify-content: space-between; gap: 12px; }
  .masthead .social-nav { border: 0; padding: 0; }
  .summary { font-size: 1rem; padding-bottom: 24px; }
  .social-token { width: 31px; height: 31px; border-radius: 9px; }
  .social-token img { width: 18px; height: 18px; }
  .masthead .social-link { gap: 7px; }
  .project-grid { grid-template-columns: 1fr; }
  .project { display: grid; grid-template-columns: minmax(120px, 35%) minmax(0, 1fr); align-items: center; gap: 24px; padding: 22px; }
  .project .work-visual { height: auto; margin: 0; }
  .project h3 { min-height: 0; }
  .project .work-copy { align-self: stretch; justify-content: center; }
  .project .text-link { margin-top: 0; }
  .essay-grid { grid-template-columns: 1fr; }
  .essay { grid-template-columns: minmax(120px, 35%) minmax(0, 1fr); gap: 24px; padding: 22px; }
  .essay h3 { font-size: 2rem; min-height: 0; }
  .writing { margin-top: 34px; }
}
@media (max-width: 470px) {
  .page { width: calc(100% - 32px); }
  .profile { gap: 16px; }
  .headshot { width: 144px; height: 172px; }
  h1 { font-size: 2.15rem; }
  .header-links { gap: 8px; }
  .masthead nav { gap: 14px; }
  .masthead .social-nav { gap: 5px; }
  .masthead .social-link { font-size: .8125rem; gap: 5px; }
  .social-token { width: 29px; height: 29px; }
  .project, .essay { grid-template-columns: minmax(0, 1fr); gap: 20px; padding: 20px 23px 24px; }
  .project .work-visual, .essay .work-visual { justify-self: center; width: 100%; }
  .work-visual > img, .work-visual > .glass-display { width: 190px; }
  .work-copy > p { margin-bottom: 15px; }
  .essay .work-copy { padding: 0; }
  .section-heading h2 { font-size: 1.9rem; }
}
@media (hover: hover) and (pointer: fine) {
  .project:hover, .essay:hover, .project:focus-within, .essay:focus-within {
    transform: translateY(-9px) scale(1.015);
    box-shadow: 0 18px 36px #2c493222;
    border-color: #ffffff;
  }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .project, .essay, .social-token, .work-visual > img, .work-visual > .glass-display { transform: none !important; }
}
