@font-face {
  font-family: "DM Sans";
  src: url("src/fonts/dm-sans.woff2") format("woff2");
  font-weight: 100 1000;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Instrument Serif";
  src: url("src/fonts/instrument-serif.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #0d0e10;
  --fg: rgba(255, 255, 255, 0.9);
  --soft: rgba(255, 255, 255, 0.67);
  --muted: rgba(255, 255, 255, 0.38);
  --ghost: rgba(255, 255, 255, 0.22);
  --hover: rgba(255, 255, 255, 0.035);
  --blue: #7aa2f7;
  --max-width: 640px;
  --font-sans: "DM Sans", Arial, sans-serif;
  --font-serif: "Instrument Serif", Georgia, serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html.has-custom-cursor,
html.has-custom-cursor * {
  cursor: none;
}

html {
  background: var(--bg);
  color-scheme: dark;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  background: var(--bg);
  color: var(--soft);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.45;
  letter-spacing: -0.012em;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

.hero h1 {
  font: inherit;
}

.cursor-dot {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 9999;
  width: 12px;
  height: 12px;
  border-radius: 999px;
  background: #60a5fa;
  opacity: 0;
  pointer-events: none;
  transform: translate3d(-24px, -24px, 0);
  clip-path: polygon(0% 0%, 100% 0%, 100% 100%, 0% 100%);
  transition: opacity 0.16s ease, clip-path 0.2s ease-out, border-radius 0.2s ease-out;
  will-change: transform;
}

.cursor-dot.is-visible {
  opacity: 0.8;
}

.cursor-dot.is-hovering {
  clip-path: polygon(50% 0%, 100% 50%, 50% 100%, 0% 50%);
  border-radius: 2px;
}

.site-shell {
  isolation: isolate;
  position: relative;
  min-height: 100vh;
  width: 100%;
  background: var(--bg);
  color: #fff;
}

.noise {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.04;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.5 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
  background-size: 200px 200px;
}

.page {
  position: relative;
  z-index: 1;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 4rem 1.5rem 6rem;
}

.hero {
  margin-bottom: 3rem;
}

.compact-hero {
  margin-bottom: 5rem;
}

.hero-title-row {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.site-name {
  color: var(--fg);
  font-family: var(--font-serif);
  font-size: 34px;
  line-height: 1;
  letter-spacing: -0.015em;
}

.location-code {
  display: inline-flex;
  align-items: center;
  gap: 0.38rem;
  color: var(--muted);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  transform: translateY(-3px);
}

.slash,
.muted-separator {
  color: var(--ghost);
}

.education-link {
  display: inline-flex;
  align-items: center;
  gap: 0.62rem;
  color: rgba(255, 255, 255, 0.55);
  font-size: 13px;
  transition: color 0.18s ease;
}

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

.education-dot {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  border-radius: 4px;
  background:
    linear-gradient(135deg, rgba(122, 162, 247, 0.95), rgba(158, 206, 106, 0.85)),
    #1d2430;
  opacity: 0.75;
  transition: opacity 0.18s ease;
}

.education-logo {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  border-radius: 3px;
  object-fit: contain;
  opacity: 0.75;
  transition: opacity 0.18s ease;
}

.education-link:hover .education-dot {
  opacity: 1;
}

.education-link:hover .education-logo {
  opacity: 1;
}

.education-degree {
  color: rgba(255, 255, 255, 0.86);
  font-family: var(--font-serif);
  font-size: 15px;
  font-style: italic;
}

.link-sweep {
  position: relative;
  display: inline-block;
}

.link-sweep::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 1px;
  background: currentColor;
  transition: width 0.2s ease;
}

.link-sweep-host:hover .link-sweep::after,
.info-row:hover .link-sweep::after {
  width: 100%;
}

.intro {
  margin-bottom: 5rem;
}

.intro p {
  max-width: 60ch;
  margin-bottom: 0.65rem;
  color: rgba(255, 255, 255, 0.62);
  font-size: 14px;
}

.intro p:first-child {
  color: rgba(255, 255, 255, 0.88);
}

.section-block {
  margin-bottom: 5rem;
}

.section-title {
  margin-bottom: 1.25rem;
  color: rgba(255, 255, 255, 0.35);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.row-list {
  display: flex;
  flex-direction: column;
  gap: 0.08rem;
}

.info-row {
  position: relative;
  display: flex;
  align-items: baseline;
  gap: 1rem;
  margin: 0 -0.5rem;
  padding: 0.625rem 0.5rem;
  border-radius: 5px;
  color: rgba(255, 255, 255, 0.72);
  transition: background 0.18s ease, color 0.18s ease;
}

.info-row:hover {
  background: var(--hover);
  color: var(--fg);
}

.row-icon {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  align-self: center;
  object-fit: contain;
  border-radius: 3px;
  opacity: 0.72;
  transition: opacity 0.18s ease;
}

.info-row:hover .row-icon {
  opacity: 1;
}

.row-main {
  min-width: 0;
  flex: 1;
}

.row-heading {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.38rem;
  color: rgba(255, 255, 255, 0.85);
  font-size: 14px;
  font-weight: 500;
  transition: color 0.18s ease;
}

.info-row:hover .row-heading {
  color: var(--fg);
}

.at {
  color: rgba(255, 255, 255, 0.3);
  font-family: var(--font-mono);
  font-size: 12px;
  transform: translateY(-1px);
}

.row-subtitle {
  display: block;
  margin-top: 0.1rem;
  color: rgba(255, 255, 255, 0.4);
  font-size: 12px;
  font-weight: 400;
}

.row-year,
.project-index {
  flex: 0 0 auto;
  color: rgba(255, 255, 255, 0.3);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.project-row {
  gap: 1rem;
}

.project-index {
  width: 1rem;
}

.external-arrow {
  flex: 0 0 auto;
  color: rgba(255, 255, 255, 0.25);
  font-size: 14px;
  transition: color 0.18s ease, transform 0.18s ease;
}

.info-row:hover .external-arrow {
  color: var(--blue);
  transform: translate(1px, -1px);
}

.github-section {
  margin-bottom: 6.25rem;
}

.contribution-card {
  width: 100%;
}

.contribution-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.85rem;
  color: rgba(255, 255, 255, 0.35);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.contribution-scroll {
  overflow-x: auto;
  padding-bottom: 0.25rem;
  scrollbar-width: none;
}

.contribution-scroll::-webkit-scrollbar {
  display: none;
}

.contribution-streak {
  display: block;
  width: 100%;
  height: auto;
  opacity: 0.92;
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
}

.footer-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding-top: 2.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.32);
  font-size: 12px;
}

.footer-socials,
.footer-nav {
  display: flex;
  align-items: center;
}

.footer-socials {
  gap: 1.35rem;
}

.footer-socials a,
.footer-nav a,
.footer-row > a {
  display: inline-flex;
  color: rgba(255, 255, 255, 0.38);
  transition: color 0.18s ease;
}

.footer-socials a:hover,
.footer-nav a:hover,
.footer-row > a:hover {
  color: rgba(255, 255, 255, 0.8);
}

@media (prefers-reduced-motion: no-preference) {
  .hero,
  .intro,
  .section-block,
  .footer-row {
    animation: page-rise 0.35s ease-out both;
  }

  .page > :nth-child(1) { animation-delay: 0s; }
  .page > :nth-child(2) { animation-delay: 0.06s; }
  .page > :nth-child(3) { animation-delay: 0.12s; }
  .page > :nth-child(4) { animation-delay: 0.18s; }
  .page > :nth-child(5) { animation-delay: 0.24s; }
  .page > :nth-child(6) { animation-delay: 0.3s; }

  @keyframes page-rise {
    from {
      opacity: 0;
      transform: translate3d(0, 8px, 0);
    }

    to {
      opacity: 1;
      transform: translate3d(0, 0, 0);
    }
  }
}

.footer-socials svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.footer-nav {
  gap: 2rem;
  font-family: var(--font-mono);
  font-size: 11px;
}

.footer-nav span {
  color: rgba(255, 255, 255, 0.28);
}

@media (max-width: 760px) {
  .cursor-dot {
    display: none;
  }

  .page {
    padding: 3rem 1.5rem 5rem;
  }

  .hero-title-row {
    display: block;
  }

  .location-code {
    display: flex;
    margin-top: 0.8rem;
    transform: none;
  }

  .info-row {
    gap: 0.75rem;
  }

  .row-year {
    display: none;
  }

  .footer-socials a {
    padding: 0.75rem;
    margin: -0.75rem;
  }

  .footer-row {
    flex-direction: column;
  }
}

@media (max-width: 420px) {
  .site-name {
    font-size: 28px;
  }

  .page {
    padding: 2.5rem 1.25rem 4rem;
  }

  .intro p {
    font-size: 13px;
  }
}
