@font-face {
  font-family: "Google Sans Code";
  font-style: normal;
  font-weight: 300 800;
  font-display: swap;
  src: url("fonts/google-sans-code-latin.woff2") format("woff2");
  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: "Google Sans Code";
  font-style: normal;
  font-weight: 300 800;
  font-display: swap;
  src: url("fonts/google-sans-code-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Google Sans Code";
  font-style: normal;
  font-weight: 300 800;
  font-display: swap;
  src: url("fonts/google-sans-code-symbols.woff2") format("woff2");
  unicode-range: U+0001-000C, U+000E-001F, U+007F-009F, U+20DD-20E0, U+20E2-20E4,
    U+2150-218F, U+2190, U+2192, U+2194-2199, U+21AF, U+21E6-21F0, U+21F3,
    U+2218-2219, U+2299, U+22C4-22C6, U+2300-243F, U+2440-244A, U+2460-24FF,
    U+25A0-27BF, U+2800-28FF, U+2921-2922, U+2981, U+29BF, U+29EB, U+2B00-2BFF,
    U+4DC0-4DFF, U+FFF9-FFFB, U+10140-1018E, U+10190-1019C, U+101A0, U+101D0-101FD,
    U+102E0-102FB, U+10E60-10E7E, U+1D2C0-1D2D3, U+1D2E0-1D37F, U+1F000-1F0FF,
    U+1F100-1F1AE, U+1F1E6-1F1FF, U+1F30D-1F30F, U+1F315, U+1F31C, U+1F31E,
    U+1F320-1F32C, U+1F336, U+1F378, U+1F37D, U+1F382, U+1F393-1F39F,
    U+1F3A7-1F3A8, U+1F3AC-1F3AF, U+1F3C2, U+1F3C4-1F3C6, U+1F3CA-1F3CE,
    U+1F3D4-1F3E0, U+1F3ED, U+1F3F1-1F3F3, U+1F3F5-1F3F7, U+1F408, U+1F415,
    U+1F41F, U+1F426, U+1F43F, U+1F441-1F442, U+1F444, U+1F446-1F449,
    U+1F44C-1F44E, U+1F453, U+1F46A, U+1F47D, U+1F4A3, U+1F4B0, U+1F4B3,
    U+1F4B9, U+1F4BB, U+1F4BF, U+1F4C8-1F4CB, U+1F4D6, U+1F4DA, U+1F4DF,
    U+1F4E3-1F4E6, U+1F4EA-1F4ED, U+1F4F7, U+1F4F9-1F4FB, U+1F4FD-1F4FE,
    U+1F503, U+1F507-1F50B, U+1F50D, U+1F512-1F513, U+1F53E-1F54A, U+1F54F-1F5FA,
    U+1F610, U+1F650-1F67F, U+1F687, U+1F68D, U+1F691, U+1F694, U+1F698,
    U+1F6AD, U+1F6B2, U+1F6B9-1F6BA, U+1F6BC, U+1F6C6-1F6CF, U+1F6D3-1F6D7,
    U+1F6E0-1F6EA, U+1F6F0-1F6F3, U+1F6F7-1F6FC, U+1F700-1F80B, U+1F810-1F847,
    U+1F850-1F859, U+1F860-1F887, U+1F890-1F8AD, U+1F8B0-1F8BB, U+1F8C0-1F8C1,
    U+1F8D0-1F8D8, U+1F900-1F90B, U+1F93B, U+1F946, U+1F984, U+1F996, U+1F9E9,
    U+1FA00-1FA6F, U+1FA70-1FA7C, U+1FA80-1FAC6, U+1FAC8, U+1FACC-1FADD,
    U+1FADF-1FAEB, U+1FAEF-1FAFA, U+1FB00-1FBFF;
}

:root {
  --bg: #191717;
  --surface: #211e1c;
  --surface-hover: #262220;
  --line: #2e2a27;
  --line-strong: #3d3733;
  --text: #ede8e2;
  --muted: #a79f97;
  --faint: #918a82;
  --accent: #c15f3c;
  --accent-text: #d98764;
  --error: #e28f6f;

  --font: "Google Sans Code", ui-monospace, SFMono-Regular, Menlo, Consolas,
    "Liberation Mono", monospace;
  --emoji-font: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji",
    "Twemoji Mozilla", sans-serif;

  --page-width: 44rem;
  --gutter: clamp(1.25rem, 5vw, 2rem);
  --ease: cubic-bezier(0.2, 0.65, 0.25, 1);
}

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

html {
  color-scheme: dark;
  scrollbar-color: var(--line-strong) var(--bg);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.65;
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

::selection {
  background: var(--accent);
  color: var(--bg);
}

a {
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 50;
  padding: 0.55rem 0.85rem;
  border: 1px solid var(--line-strong);
  border-radius: 0 0 6px 0;
  background: var(--surface);
  color: var(--text);
  font-size: 0.8rem;
  font-weight: 500;
  text-decoration: none;
  transform: translateY(-120%);
  transition: transform 140ms var(--ease);
}

.skip-link:focus-visible {
  transform: translateY(0);
}

.shell {
  width: 100%;
  max-width: calc(var(--page-width) + var(--gutter) * 2);
  margin: 0 auto;
  padding: clamp(3.25rem, 9vh, 6.5rem) var(--gutter)
    clamp(6rem, 16vh, 9rem);
}

.page-icon {
  display: block;
  width: 52px;
  height: 52px;
  margin: 0 0 1.4rem;
}

.title {
  margin: 0;
  font-size: clamp(2rem, 4.6vw, 2.65rem);
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.2;
  text-wrap: balance;
}

.intro {
  margin: 0.75rem 0 0;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.7;
  text-wrap: pretty;
}

.rule {
  margin: 2rem 0 0.65rem;
  border: 0;
  border-top: 1px solid var(--line);
}

.projects {
  margin: 0;
  padding: 0;
  list-style: none;
}

.project {
  position: relative;
  display: grid;
  grid-template-columns: 1.6rem minmax(0, 1fr) auto;
  grid-template-areas: "emoji body date";
  column-gap: 0.8rem;
  align-items: start;
  padding: 0.8rem 0.7rem;
  margin: 0 -0.7rem;
  border-radius: 7px;
  transition: background-color 120ms var(--ease);
}

.project + .project::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0.7rem;
  right: 0.7rem;
  height: 1px;
  background: var(--line);
}

.project:hover {
  background: var(--surface);
}

.project:focus-within {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.project-emoji {
  grid-area: emoji;
  padding-top: 0.08rem;
  font-family: var(--emoji-font);
  font-size: 1.08rem;
  line-height: 1.55;
  text-align: center;
}

.project-emoji--empty {
  visibility: hidden;
}

.project-body {
  display: flex;
  flex-direction: column;
  gap: 0.18rem;
  min-width: 0;
  grid-area: body;
}

.project-name {
  width: fit-content;
  color: var(--text);
  font-size: 0.98rem;
  font-weight: 500;
  line-height: 1.55;
  text-decoration: underline;
  text-decoration-color: transparent;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.22em;
  transition: color 120ms var(--ease),
    text-decoration-color 120ms var(--ease);
}

/* whole row link */
.project-name::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
}

.project:hover .project-name {
  color: var(--accent-text);
  text-decoration-color: rgba(217, 135, 100, 0.45);
}

.project-name:focus-visible {
  outline: none;
}

.project-desc {
  max-width: 62ch;
  color: var(--muted);
  font-size: 0.85rem;
  line-height: 1.55;
}

.project-date {
  grid-area: date;
  padding-top: 0.22rem;
  color: var(--muted);
  font-size: 0.8rem;
  font-variant-numeric: tabular-nums;
  line-height: 1.55;
  text-align: right;
  white-space: nowrap;
}

.project-date-label {
  color: var(--faint);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.04em;
}

.project-status {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5ch;
  padding: 1rem 0.7rem;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.6;
  list-style: none;
}

.project-status--loading {
  color: var(--faint);
}

.project-status--error {
  color: var(--error);
}

.project-status__retry {
  padding: 0;
  border: 0;
  background: none;
  color: var(--accent-text);
  font: inherit;
  text-decoration: underline;
  text-decoration-color: rgba(217, 135, 100, 0.45);
  text-underline-offset: 0.22em;
  cursor: pointer;
}

.project-status__retry:hover {
  color: var(--text);
}

.home-link {
  position: fixed;
  bottom: max(1rem, env(safe-area-inset-bottom, 0px));
  left: max(1rem, env(safe-area-inset-left, 0px));
  z-index: 20;
  display: inline-flex;
  align-items: center;
  gap: 0.55em;
  min-height: 2.4rem;
  padding: 0.55rem 0.85rem;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--surface);
  color: var(--muted);
  font-family: var(--font);
  font-size: 0.78rem;
  font-weight: 500;
  line-height: 1.2;
  text-decoration: none;
  transition: color 140ms var(--ease), border-color 140ms var(--ease),
    background-color 140ms var(--ease);
}

.home-link:hover {
  border-color: rgba(193, 95, 60, 0.65);
  background: var(--surface-hover);
  color: var(--text);
}

.home-link__arrow {
  display: flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 14px;
  height: 14px;
  color: var(--accent-text);
  transform: translateY(-1px);
  transition: transform 140ms var(--ease);
}

.home-link__arrow svg {
  display: block;
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.home-link:hover .home-link__arrow {
  transform: translate(-2px, -1px);
}

.error-code {
  margin: 0 0 0.4rem;
  color: var(--accent-text);
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  line-height: 1.4;
}

.text-link {
  color: var(--accent-text);
  text-decoration: underline;
  text-decoration-color: rgba(217, 135, 100, 0.45);
  text-underline-offset: 0.22em;
}

.text-link:hover {
  color: var(--text);
}

.copyright {
  position: fixed;
  right: max(1rem, env(safe-area-inset-right, 0px));
  bottom: max(1rem, env(safe-area-inset-bottom, 0px));
  z-index: 20;
  margin: 0;
  color: var(--faint);
  font-family: var(--font);
  font-size: 0.72rem;
  letter-spacing: 0.02em;
  line-height: 1.2;
}

@media (max-width: 560px) {
  .project {
    grid-template-columns: 1.6rem minmax(0, 1fr);
    grid-template-areas:
      "emoji body"
      ". date";
    row-gap: 0.25rem;
    padding: 0.75rem 0.6rem;
    margin: 0 -0.6rem;
  }

  .project + .project::before {
    left: 0.6rem;
    right: 0.6rem;
  }

  .project-date {
    padding-top: 0;
    text-align: left;
  }

  .page-icon {
    width: 46px;
    height: 46px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
