/*
 * www.yubo.md
 *
 * Layout, palette and interaction design adapted from Brittany Chiang's v4
 * (https://brittanychiang.com, source https://github.com/bchiang7/v4), rewritten as plain CSS.
 *
 * Original work: MIT License, Copyright (c) 2018 Brittany Chiang
 * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and
 * associated documentation files (the "Software"), to deal in the Software without restriction,
 * including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense,
 * and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so,
 * subject to the following conditions: The above copyright notice and this permission notice shall be
 * included in all copies or substantial portions of the Software.
 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
 * LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
 * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
 * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
 * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 *
 * Fonts: Inter and Fira Code, SIL Open Font License 1.1 (see /fonts/).
 * The page uses no JavaScript: the experience tabs are radio inputs styled with :checked.
 */

@font-face {
  font-family: "Inter";
  src: url("/fonts/inter-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329,
    U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Fira Code";
  src: url("/fonts/firacode-latin.woff2") format("woff2");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329,
    U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --dark-navy: #020c1b;
  --navy: #0a192f;
  --light-navy: #112240;
  --lightest-navy: #233554;
  --navy-shadow: rgba(2, 12, 27, 0.7);
  --dark-slate: #495670;
  --slate: #8892b0;
  --light-slate: #a8b2d1;
  --lightest-slate: #ccd6f6;
  --white: #e6f1ff;
  --green: #64ffda;
  --green-tint: rgba(100, 255, 218, 0.1);

  --font-sans: "Inter", -apple-system, "SF Pro Text", system-ui, sans-serif;
  --font-mono: "Fira Code", "SF Mono", ui-monospace, Menlo, monospace;

  --fz-xxs: 12px;
  --fz-xs: 13px;
  --fz-sm: 14px;
  --fz-md: 16px;
  --fz-lg: 17px;
  --fz-xl: 18px;
  --fz-xxl: 21px;
  --fz-heading: 32px;

  --radius: 4px;
  --nav-height: 76px;
  --tab-height: 42px;
  --tab-width: 160px;
  --easing: cubic-bezier(0.645, 0.045, 0.355, 1);
  --transition: all 0.25s cubic-bezier(0.645, 0.045, 0.355, 1);
}

/* ---------- base ---------- */

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-height) + 10px);
  scrollbar-width: thin;
  scrollbar-color: var(--dark-slate) var(--navy);
  -webkit-text-size-adjust: 100%;
}

body {
  position: relative;
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background-color: var(--navy);
  color: var(--slate);
  font-family: var(--font-sans);
  font-size: var(--fz-xl);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection {
  background-color: var(--lightest-navy);
  color: var(--lightest-slate);
}

:focus-visible {
  outline: 2px dashed var(--green);
  outline-offset: 3px;
}

h1,
h2,
h3 {
  margin: 0 0 10px;
  color: var(--lightest-slate);
  font-weight: 600;
  line-height: 1.15;
}

p {
  margin: 0 0 15px;
}

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

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition);
}

a:hover,
a:focus-visible {
  color: var(--green);
}

img,
svg {
  display: block;
  max-width: 100%;
}

ul {
  margin: 0;
  padding: 0;
}

.skip {
  position: absolute;
  top: -100px;
  left: 16px;
  z-index: 99;
  padding: 12px 18px;
  border-radius: var(--radius);
  background: var(--green);
  color: var(--navy);
  font-family: var(--font-mono);
  font-size: var(--fz-sm);
}

.skip:focus-visible {
  top: 16px;
  color: var(--navy);
}

.button {
  display: inline-block;
  padding: 1.25rem 1.75rem;
  border: 1px solid var(--green);
  border-radius: var(--radius);
  background-color: transparent;
  color: var(--green);
  font-family: var(--font-mono);
  font-size: var(--fz-sm);
  line-height: 1;
}

.button:hover,
.button:focus-visible {
  outline: none;
  color: var(--green);
  box-shadow: 4px 4px 0 0 var(--green);
  transform: translate(-5px, -5px);
}

/* ---------- header, side rail ---------- */

.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 11;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--nav-height);
  padding: 0 50px;
  background-color: rgba(10, 25, 47, 0.85);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.logo {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 1.5px solid var(--green);
  border-radius: var(--radius);
  color: var(--green);
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.logo-z {
  position: absolute;
  top: 3px;
  left: 4px;
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 400;
  line-height: 1;
  letter-spacing: 0;
}

.logo:hover,
.logo:focus-visible {
  outline: none;
  box-shadow: 4px 4px 0 0 var(--green);
  transform: translate(-4px, -4px);
}

.nav ol {
  display: flex;
  align-items: center;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: item;
}

.nav li {
  margin: 0 5px;
  counter-increment: item;
  font-family: var(--font-mono);
  font-size: var(--fz-xs);
}

.nav a {
  display: block;
  padding: 10px;
  color: var(--lightest-slate);
}

.nav a::before {
  content: "0" counter(item) ".";
  margin-right: 5px;
  color: var(--green);
  font-size: var(--fz-xxs);
}

.nav a:hover,
.nav a:focus-visible {
  color: var(--green);
}

.rail {
  position: fixed;
  right: 40px;
  bottom: 0;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 40px;
}

.rail::after {
  content: "";
  display: block;
  width: 1px;
  height: 90px;
  background-color: var(--light-slate);
}

.rail a {
  margin: 20px auto;
  padding: 10px;
  color: var(--light-slate);
  font-family: var(--font-mono);
  font-size: var(--fz-xxs);
  line-height: var(--fz-lg);
  letter-spacing: 0.1em;
  writing-mode: vertical-rl;
}

.rail a:hover,
.rail a:focus-visible {
  color: var(--green);
  transform: translateY(-3px);
}

/* ---------- hero ---------- */

.hero-art {
  position: absolute;
  top: 0;
  right: 0;
  z-index: 0;
  width: 62vw;
  max-width: 1500px;
  height: 100vh;
  min-height: 640px;
  max-height: 1100px;
  overflow: hidden;
  pointer-events: none;
}

.hero-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 80% 38%;
}

.hero-art::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, var(--navy) 0%, rgba(10, 25, 47, 0.78) 22%, rgba(10, 25, 47, 0.3) 44%, rgba(10, 25, 47, 0) 62%),
    linear-gradient(0deg, var(--navy) 0%, rgba(10, 25, 47, 0) 30%);
}

main {
  position: relative;
  z-index: 1;
  max-width: 1600px;
  margin: 0 auto;
  padding: 0 150px;
  counter-reset: section;
}

section {
  max-width: 1000px;
  margin: 0 auto;
  padding: 100px 0;
}

.hero {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  min-height: 100vh;
  padding: var(--nav-height) 0 0;
}

.hero-hi {
  margin: 0 0 28px 3px;
  color: var(--green);
  font-family: var(--font-mono);
  font-size: var(--fz-md);
}

.big {
  margin: 0;
  font-size: clamp(40px, 7.4vw, 76px);
  font-weight: 650;
  line-height: 1.08;
  letter-spacing: -0.025em;
}

.hero-sub {
  margin-top: 8px;
  color: var(--slate);
}

.hero .big {
  text-shadow: 0 2px 28px rgba(10, 25, 47, 0.9);
}

.hero-text {
  max-width: 540px;
  margin: 24px 0 0;
  color: var(--slate);
}

.hero-cta {
  margin-top: 50px;
}

@media (prefers-reduced-motion: no-preference) {
  .hero > * {
    animation: fade-up 0.6s var(--easing) both;
  }
  .hero > :nth-child(2) { animation-delay: 0.1s; }
  .hero > :nth-child(3) { animation-delay: 0.2s; }
  .hero > :nth-child(4) { animation-delay: 0.3s; }
  .hero > :nth-child(5) { animation-delay: 0.4s; }
  .hero-art {
    animation: fade-in 1.6s ease-out both;
  }
}

@keyframes fade-up {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: none; }
}

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* ---------- numbered section headings ---------- */

.numbered {
  display: flex;
  align-items: center;
  margin: 10px 0 40px;
  font-size: clamp(26px, 5vw, var(--fz-heading));
  white-space: nowrap;
}

.numbered::before {
  content: "0" counter(section) ".";
  position: relative;
  bottom: 3px;
  margin-right: 10px;
  counter-increment: section;
  color: var(--green);
  font-family: var(--font-mono);
  font-size: clamp(var(--fz-md), 3vw, var(--fz-xl));
  font-weight: 400;
}

.numbered::after {
  content: "";
  display: block;
  position: relative;
  top: 1px;
  width: 300px;
  height: 1px;
  margin-left: 20px;
  background-color: var(--lightest-navy);
}

/* ---------- about ---------- */

.about {
  max-width: 900px;
}

.about-inner {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 50px;
}

.about-text {
  font-size: var(--fz-lg);
  line-height: 1.6;
}

.skills {
  display: grid;
  grid-template-columns: repeat(2, minmax(140px, 200px));
  gap: 0 10px;
  margin-top: 20px;
  list-style: none;
}

.skills li {
  position: relative;
  margin-bottom: 10px;
  padding-left: 20px;
  font-family: var(--font-mono);
  font-size: var(--fz-xs);
}

.skills li::before,
.fancy li::before {
  content: "▹";
  position: absolute;
  left: 0;
  color: var(--green);
}

.about-pic {
  position: relative;
  z-index: 0;
  align-self: start;
  width: 100%;
  max-width: 300px;
}

.about-pic::after {
  content: "";
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: -1;
  width: 100%;
  height: 100%;
  border: 2px solid var(--green);
  border-radius: var(--radius);
  transition: var(--transition);
}

.tile {
  display: grid;
  grid-template-areas:
    "z z"
    "sym sym"
    "name mass";
  grid-template-rows: auto 1fr auto;
  aspect-ratio: 1;
  padding: 20px 22px;
  border-radius: var(--radius);
  background: radial-gradient(120% 90% at 30% 20%, #173158 0%, var(--light-navy) 55%, #0c1b35 100%);
  box-shadow: 0 10px 30px -15px var(--navy-shadow);
  transition: var(--transition);
}

.about-pic:hover .tile {
  transform: translate(-4px, -4px);
}

.about-pic:hover::after {
  transform: translate(4px, 4px);
}

.tile-z {
  grid-area: z;
  color: var(--light-slate);
  font-family: var(--font-mono);
  font-size: 20px;
}

.tile-sym {
  grid-area: sym;
  align-self: center;
  justify-self: center;
  color: var(--green);
  font-size: clamp(88px, 11vw, 128px);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.04em;
  text-shadow: 0 0 42px rgba(100, 255, 218, 0.35);
}

.tile-name,
.tile-mass {
  color: var(--light-slate);
  font-family: var(--font-mono);
  font-size: var(--fz-xs);
}

.tile-name { grid-area: name; }
.tile-mass { grid-area: mass; justify-self: end; }

/* ---------- experience tabs (radio inputs, no script) ---------- */

.jobs {
  max-width: 760px;
}

.tabs {
  position: relative;
  display: flex;
  min-height: 340px;
}

.tab-radio {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.tab-list {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  width: max-content;
}

.tab-list label {
  display: flex;
  align-items: center;
  height: var(--tab-height);
  padding: 0 20px 2px;
  border-left: 2px solid var(--lightest-navy);
  color: var(--slate);
  font-family: var(--font-mono);
  font-size: var(--fz-xs);
  white-space: nowrap;
  cursor: pointer;
  transition: var(--transition);
}

.tab-list label:hover {
  background-color: var(--light-navy);
  color: var(--green);
}

.tab-highlight {
  position: absolute;
  top: 0;
  left: 0;
  width: 2px;
  height: var(--tab-height);
  border-radius: var(--radius);
  background: var(--green);
  transition: transform 0.25s var(--easing) 0.1s;
}

#job-1:checked ~ .tab-list label[for="job-1"],
#job-2:checked ~ .tab-list label[for="job-2"],
#job-3:checked ~ .tab-list label[for="job-3"],
#job-4:checked ~ .tab-list label[for="job-4"],
#job-5:checked ~ .tab-list label[for="job-5"] {
  color: var(--green);
}

#job-1:focus-visible ~ .tab-list label[for="job-1"],
#job-2:focus-visible ~ .tab-list label[for="job-2"],
#job-3:focus-visible ~ .tab-list label[for="job-3"],
#job-4:focus-visible ~ .tab-list label[for="job-4"],
#job-5:focus-visible ~ .tab-list label[for="job-5"] {
  outline: 2px dashed var(--green);
  outline-offset: -2px;
}

#job-2:checked ~ .tab-list .tab-highlight { transform: translateY(calc(1 * var(--tab-height))); }
#job-3:checked ~ .tab-list .tab-highlight { transform: translateY(calc(2 * var(--tab-height))); }
#job-4:checked ~ .tab-list .tab-highlight { transform: translateY(calc(3 * var(--tab-height))); }
#job-5:checked ~ .tab-list .tab-highlight { transform: translateY(calc(4 * var(--tab-height))); }

.tab-panels {
  position: relative;
  width: 100%;
  margin-left: 24px;
}

.tab-panel {
  display: none;
  padding: 8px 5px;
}

#job-1:checked ~ .tab-panels #panel-1,
#job-2:checked ~ .tab-panels #panel-2,
#job-3:checked ~ .tab-panels #panel-3,
#job-4:checked ~ .tab-panels #panel-4,
#job-5:checked ~ .tab-panels #panel-5 {
  display: block;
}

@media (prefers-reduced-motion: no-preference) {
  #job-1:checked ~ .tab-panels #panel-1,
  #job-2:checked ~ .tab-panels #panel-2,
  #job-3:checked ~ .tab-panels #panel-3,
  #job-4:checked ~ .tab-panels #panel-4,
  #job-5:checked ~ .tab-panels #panel-5 {
    animation: fade-up 0.35s var(--easing) both;
  }
}

.tab-panel h3 {
  margin-bottom: 4px;
  font-size: var(--fz-xxl);
  font-weight: 500;
  line-height: 1.35;
}

.company {
  color: var(--green);
}

.range {
  margin-bottom: 25px;
  color: var(--light-slate);
  font-family: var(--font-mono);
  font-size: var(--fz-xs);
}

.fancy {
  list-style: none;
  font-size: var(--fz-md);
  line-height: 1.6;
}

.fancy li {
  position: relative;
  margin-bottom: 12px;
  padding-left: 30px;
}

/* ---------- featured projects ---------- */

.work {
  max-width: 1100px;
}

.featured {
  list-style: none;
}

.project {
  position: relative;
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 10px;
  align-items: center;
}

.project:not(:last-of-type) {
  margin-bottom: 130px;
}

.project-content {
  position: relative;
  z-index: 2;
  grid-column: 1 / 7;
  grid-row: 1 / -1;
}

.project-image {
  position: relative;
  z-index: 1;
  grid-column: 5 / -1;
  grid-row: 1 / -1;
  overflow: hidden;
  border-radius: var(--radius);
  background-color: var(--dark-navy);
  box-shadow: 0 30px 60px -30px rgba(2, 12, 27, 0.9);
}

.project-image img {
  width: 100%;
  height: auto;
  filter: brightness(0.93);
  transition: filter 0.5s var(--easing), transform 0.8s var(--easing);
}

.project:hover .project-image img {
  filter: none;
  transform: scale(1.02);
}

.project:nth-of-type(odd) .project-content {
  grid-column: 7 / -1;
  text-align: right;
}

.project:nth-of-type(odd) .project-image {
  grid-column: 1 / 9;
}

.project-overline {
  margin: 10px 0;
  color: var(--green);
  font-family: var(--font-mono);
  font-size: var(--fz-xs);
}

.project-title {
  margin: 0 0 20px;
  color: var(--lightest-slate);
  font-size: clamp(24px, 5vw, 28px);
}

.project-description {
  position: relative;
  z-index: 2;
  padding: 25px;
  border-radius: var(--radius);
  background-color: var(--light-navy);
  box-shadow: 0 10px 30px -15px var(--navy-shadow);
  color: var(--light-slate);
  font-size: var(--fz-md);
  line-height: 1.6;
}

.project-tech {
  display: flex;
  flex-wrap: wrap;
  margin: 25px 0 10px;
  list-style: none;
}

.project-tech li {
  margin: 0 20px 5px 0;
  color: var(--light-slate);
  font-family: var(--font-mono);
  font-size: var(--fz-xs);
  white-space: nowrap;
}

.project:nth-of-type(odd) .project-tech {
  justify-content: flex-end;
}

.project:nth-of-type(odd) .project-tech li {
  margin: 0 0 5px 20px;
}

.project-links {
  display: flex;
  align-items: center;
  margin: 10px 0 0 -10px;
  color: var(--lightest-slate);
}

.project:nth-of-type(odd) .project-links {
  justify-content: flex-end;
  margin: 10px -10px 0 0;
}

.project-links a {
  padding: 10px;
}

.project-links svg {
  width: 22px;
  height: 22px;
}

/* ---------- education and community ---------- */

.more {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.more-title {
  font-size: clamp(24px, 5vw, var(--fz-heading));
}

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 15px;
  width: 100%;
  margin-top: 46px;
  list-style: none;
}

.card {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 2rem 1.75rem;
  border-radius: var(--radius);
  background-color: var(--light-navy);
  box-shadow: 0 10px 30px -15px var(--navy-shadow);
  transition: var(--transition);
}

@media (prefers-reduced-motion: no-preference) {
  .card:hover {
    transform: translateY(-7px);
    box-shadow: 0 20px 30px -15px var(--navy-shadow);
  }
}

.card-icon {
  width: 40px;
  height: 40px;
  margin-bottom: 30px;
  color: var(--green);
}

.card-title {
  margin: 0 0 10px;
  font-size: var(--fz-xl);
}

.card-text {
  color: var(--light-slate);
  font-size: var(--fz-sm);
  line-height: 1.6;
}

.card-meta {
  margin: auto 0 0;
  padding-top: 20px;
  color: var(--slate);
  font-family: var(--font-mono);
  font-size: var(--fz-xxs);
}

/* ---------- contact, footer ---------- */

.contact {
  max-width: 600px;
  margin: 0 auto 100px;
  text-align: center;
}

.contact-overline {
  margin: 0 0 20px;
  color: var(--green);
  font-family: var(--font-mono);
  font-size: var(--fz-md);
  font-weight: 400;
}

.contact-overline::before {
  content: "0" counter(section) ". ";
  counter-increment: section;
}

.contact-title {
  margin: 0 0 20px;
  color: var(--lightest-slate);
  font-size: clamp(40px, 5vw, 60px);
  font-weight: 650;
  line-height: 1.1;
  letter-spacing: -0.02em;
}

.contact .button {
  margin-top: 50px;
}

.footer {
  padding: 15px 15px 30px;
  color: var(--light-slate);
  font-family: var(--font-mono);
  font-size: var(--fz-xxs);
  text-align: center;
}

.footer p {
  margin: 0;
  padding: 6px;
}

/* ---------- 404 ---------- */

.notfound {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 0 24px;
  text-align: center;
}

.notfound-code {
  margin: 0;
  color: var(--green);
  font-family: var(--font-mono);
  font-size: clamp(100px, 25vw, 200px);
  line-height: 1;
}

.notfound-title {
  margin: 10px 0 0;
  font-size: clamp(30px, 5vw, 50px);
  font-weight: 400;
}

.notfound .button {
  margin-top: 40px;
}

/* ---------- responsive ---------- */

@media (max-width: 1080px) {
  main {
    padding: 0 100px;
  }
  .header {
    padding: 0 40px;
  }
  .rail {
    right: 20px;
  }
  .numbered::after {
    width: 200px;
  }
  .project-content {
    grid-column: 1 / 9;
  }
  .project:nth-of-type(odd) .project-content {
    grid-column: 5 / -1;
  }
  .cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  :root {
    --nav-height: 64px;
  }
  body {
    font-size: var(--fz-lg);
  }
  main {
    padding: 0 28px;
  }
  section {
    padding: 80px 0;
  }
  .header {
    position: absolute;
    padding: 0 22px;
    background-color: transparent;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
  .nav li {
    margin: 0;
    font-size: var(--fz-xxs);
  }
  .nav a {
    padding: 10px 7px;
  }
  .nav a::before {
    display: none;
  }
  .rail {
    display: none;
  }
  .hero-art {
    width: 100%;
    height: 78vh;
    min-height: 0;
  }
  .hero-art img {
    object-position: 78% 40%;
  }
  .hero-art::after {
    background: linear-gradient(0deg, var(--navy) 0%, rgba(10, 25, 47, 0.45) 55%, rgba(10, 25, 47, 0.65) 100%);
  }
  .hero {
    justify-content: flex-end;
    min-height: 92vh;
    padding-bottom: 40px;
  }
  .numbered::after {
    width: 100%;
  }
  .about-inner {
    display: block;
  }
  .about-pic {
    width: 70%;
    margin: 50px auto 0;
  }
  .project,
  .project:nth-of-type(odd) {
    display: flex;
    flex-direction: column;
    align-items: stretch;
  }
  .project:not(:last-of-type) {
    margin-bottom: 70px;
  }
  .project-image {
    order: -1;
    margin-bottom: 22px;
  }
  .project-content,
  .project:nth-of-type(odd) .project-content {
    text-align: left;
  }
  .project-title {
    margin-bottom: 12px;
  }
  .project-description {
    padding: 0;
    background: none;
    box-shadow: none;
  }
  .project-tech,
  .project:nth-of-type(odd) .project-tech {
    justify-content: flex-start;
    margin: 18px 0 6px;
  }
  .project-tech li,
  .project:nth-of-type(odd) .project-tech li {
    margin: 0 14px 5px 0;
  }
  .project-links,
  .project:nth-of-type(odd) .project-links {
    justify-content: flex-start;
    margin: 4px 0 0 -10px;
  }
  .contact {
    margin-bottom: 50px;
  }
}

@media (max-width: 600px) {
  .numbered {
    font-size: 24px;
  }
  .numbered::after {
    margin-left: 10px;
  }
  .tabs {
    display: block;
    min-height: 0;
  }
  .tab-list {
    flex-direction: row;
    width: calc(100% + 56px);
    margin: 0 -28px 30px;
    padding: 0 28px;
    overflow-x: auto;
    scrollbar-width: none;
  }
  .tab-list label {
    flex: 0 0 var(--tab-width);
    justify-content: center;
    padding: 0 12px;
    border-left: 0;
    border-bottom: 2px solid var(--lightest-navy);
  }
  .tab-highlight {
    top: auto;
    bottom: 0;
    left: 28px;
    width: var(--tab-width);
    height: 2px;
  }
  #job-2:checked ~ .tab-list .tab-highlight { transform: translateX(calc(1 * var(--tab-width))); }
  #job-3:checked ~ .tab-list .tab-highlight { transform: translateX(calc(2 * var(--tab-width))); }
  #job-4:checked ~ .tab-list .tab-highlight { transform: translateX(calc(3 * var(--tab-width))); }
  #job-5:checked ~ .tab-list .tab-highlight { transform: translateX(calc(4 * var(--tab-width))); }
  .tab-panels {
    margin-left: 0;
  }
  .cards {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 400px) {
  .numbered {
    white-space: normal;
  }
  .numbered::after {
    display: none;
  }
}

@media (max-width: 480px) {
  main {
    padding: 0 22px;
  }
  .tab-list {
    width: calc(100% + 44px);
    margin: 0 -22px 30px;
    padding: 0 22px;
  }
  .tab-highlight {
    left: 22px;
  }
  .header {
    padding: 0 16px;
  }
  .nav a {
    padding: 10px 5px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
  }
}

/* ---------- print: a clean A4 record of the page ---------- */

@media print {
  @page {
    size: A4;
    margin: 16mm 16mm 18mm;
  }
  :root {
    --green: #0b7a63;
  }
  body {
    background: #fff;
    color: #222;
    font-size: 10.5pt;
  }
  .header,
  .rail,
  .hero-art,
  .skip,
  .hero-cta,
  .tab-list,
  .project-links,
  .contact .button {
    display: none !important;
  }
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    box-shadow: none !important;
    text-shadow: none !important;
  }
  main {
    max-width: none;
    padding: 0;
  }
  section,
  .work,
  .jobs,
  .about {
    max-width: none;
    padding: 14pt 0;
  }
  h1,
  h2,
  h3,
  .project-title,
  .card-title,
  .contact-title {
    color: #000;
  }
  .hero {
    min-height: 0;
    padding: 0 0 6pt;
  }
  .big {
    font-size: 26pt;
  }
  .hero-sub,
  .hero-text,
  .about-text,
  .fancy,
  .project-description,
  .card-text,
  .range,
  .project-tech li,
  .card-meta,
  .footer {
    color: #333;
  }
  .numbered {
    margin-bottom: 14pt;
    font-size: 15pt;
    break-after: avoid;
  }
  .numbered::after {
    background-color: #ccc;
  }
  .about-inner {
    display: block;
  }
  .about-pic {
    display: none;
  }
  .tabs {
    display: block;
    min-height: 0;
  }
  .tab-panels {
    margin: 0;
  }
  .tab-panel {
    display: block !important;
    margin-bottom: 10pt;
    padding: 0;
    break-inside: avoid;
  }
  .tab-panel h3 {
    font-size: 12pt;
  }
  .project,
  .project:nth-of-type(odd) {
    display: grid;
    grid-template-columns: 6.2cm 1fr;
    gap: 14pt;
    align-items: start;
    margin-bottom: 14pt;
    break-inside: avoid;
  }
  .project-image,
  .project:nth-of-type(odd) .project-image {
    grid-column: 1;
    grid-row: 1;
    border: 1px solid #ccc;
  }
  .project-image img,
  .project:hover .project-image img {
    filter: none;
    transform: none;
  }
  .project-content,
  .project:nth-of-type(odd) .project-content {
    grid-column: 2;
    grid-row: 1;
    text-align: left;
  }
  .project-title {
    margin-bottom: 6pt;
    font-size: 13pt;
  }
  .project-description {
    padding: 0;
    background: none;
  }
  .project-tech,
  .project:nth-of-type(odd) .project-tech {
    justify-content: flex-start;
    margin: 6pt 0 0;
  }
  .project-tech li,
  .project:nth-of-type(odd) .project-tech li {
    margin: 0 10pt 2pt 0;
  }
  .more {
    align-items: stretch;
  }
  .more-title {
    font-size: 15pt;
  }
  .cards {
    grid-template-columns: repeat(2, 1fr);
    gap: 8pt;
    margin-top: 10pt;
  }
  .card {
    padding: 10pt;
    border: 1px solid #ccc;
    background: none;
    break-inside: avoid;
  }
  .card-icon {
    display: none;
  }
  .contact {
    margin: 0;
    padding: 10pt 0 0;
    text-align: left;
  }
  .contact-title {
    font-size: 15pt;
  }
  .contact::after {
    content: "ichoyb@gmail.com";
    display: block;
    margin-top: 6pt;
    color: #000;
    font-family: var(--font-mono);
  }
  .footer {
    padding: 14pt 0 0;
    text-align: left;
  }
}
