@font-face {
  font-family: "Torus";
  src: url("Torus Regular.otf") format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Torus";
  src: url("Torus Light.otf") format("opentype");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Torus";
  src: url("Torus Bold.otf") format("opentype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --bg: #0f172a;
  --ink: #e2e8f0;
  --muted: #94a3b8;
  --accent: #39C5BB;
  --line: rgba(226, 232, 240, 0.12);
  --accent-line: rgba(57, 197, 187, 0.42);
  --accent-soft: rgba(57, 197, 187, 0.12);
  --bg-hover: rgba(57, 197, 187, 0.14);
  --focus: rgba(57, 197, 187, 0.46);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 50% 0%, rgba(57, 197, 187, 0.052), transparent 30rem),
    var(--bg);
  color: var(--ink);
  font-family:
    "Torus",
    "Microsoft YaHei",
    "PingFang SC",
    "Noto Sans SC",
    sans-serif;
  font-size: 16px;
  line-height: 1.625;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection {
  background: rgba(57, 197, 187, 0.28);
  color: var(--ink);
}

a {
  color: var(--accent);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: rgba(57, 197, 187, 0.44);
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
  transition:
    color 150ms cubic-bezier(0.4, 0, 0.2, 1),
    text-decoration-color 150ms cubic-bezier(0.4, 0, 0.2, 1),
    background-color 150ms cubic-bezier(0.4, 0, 0.2, 1);
}

a:hover {
  color: var(--ink);
  text-decoration-color: var(--accent);
}

button {
  font: inherit;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
  box-shadow: 0 0 0 6px var(--focus);
}

.skip-link {
  position: fixed;
  left: 24px;
  top: 16px;
  z-index: 30;
  transform: translateY(calc(-100% - 32px));
  border-radius: 6px;
  background: var(--accent);
  color: var(--bg);
  font-size: 14px;
  font-weight: 700;
  padding: 8px 12px;
}

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

.language-switch {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 20;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: rgba(15, 23, 42, 0.82);
  color: var(--muted);
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
  padding: 0 12px;
  transition:
    border-color 150ms cubic-bezier(0.4, 0, 0.2, 1),
    background-color 150ms cubic-bezier(0.4, 0, 0.2, 1),
    color 150ms cubic-bezier(0.4, 0, 0.2, 1);
}

.language-switch:hover,
.language-switch:focus-visible {
  border-color: var(--accent-line);
  background: var(--bg-hover);
  color: var(--accent);
}

.page-shell {
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
  padding: 108px 24px 120px;
}

.site-header {
  margin-bottom: 78px;
}

.avatar {
  display: block;
  width: 156px;
  height: 156px;
  margin-inline: auto;
  margin-bottom: 32px;
  border: 1px solid var(--accent-line);
  border-radius: 50%;
  box-shadow:
    0 0 0 6px rgba(57, 197, 187, 0.06),
    0 22px 60px rgba(2, 6, 23, 0.34);
  object-fit: cover;
  object-position: center;
}

h1,
h2,
h3,
p {
  margin: 0;
}

h1 {
  color: var(--ink);
  max-width: 680px;
  font-size: 40px;
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1.12;
}

.hero-greeting {
  margin-inline: auto;
  font-size: 40px;
  font-weight: 400;
  line-height: 1.12;
  text-align: center;
}

.hero-greeting strong {
  color: var(--ink);
  font-weight: 700;
}

.hero-copy strong {
  color: var(--ink);
  font-weight: 700;
}

.wave-hand {
  display: inline-block;
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif;
  margin-right: 0.08em;
  transform-origin: 75% 80%;
  vertical-align: -0.06em;
  will-change: transform;
}

.wave-hand.is-waving {
  animation: wave-hello 820ms ease-in-out 4;
}

.hero-greeting:hover .wave-hand {
  animation: wave-hello-hover 900ms ease-in-out infinite;
}

.wave-hand:hover {
  animation: wave-hello-hover 900ms ease-in-out infinite;
}

.hero-copy {
  display: grid;
  gap: 10px;
  margin-top: 22px;
  max-width: 620px;
  color: var(--ink);
  font-size: 18px;
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1.5;
}

@keyframes wave-hello {
  0%,
  100% {
    transform: rotate(0deg);
  }

  15% {
    transform: rotate(18deg);
  }

  30% {
    transform: rotate(-12deg);
  }

  45% {
    transform: rotate(16deg);
  }

  60% {
    transform: rotate(-8deg);
  }

  75% {
    transform: rotate(8deg);
  }
}

@keyframes wave-hello-hover {
  0%,
  100% {
    transform: rotate(0deg);
  }

  15% {
    transform: rotate(18deg);
  }

  30% {
    transform: rotate(-12deg);
  }

  45% {
    transform: rotate(16deg);
  }

  60% {
    transform: rotate(-8deg);
  }

  75% {
    transform: rotate(8deg);
  }
}

@keyframes wave-hello-reduced {
  0%,
  100% {
    transform: rotate(0deg);
  }

  35% {
    transform: rotate(8deg);
  }

  68% {
    transform: rotate(-5deg);
  }
}

.hero-copy p:last-child {
  color: var(--muted);
  font-weight: 300;
}

.content-section {
  scroll-margin-top: 40px;
  margin-top: 76px;
}

.content-section:first-child {
  margin-top: 0;
}

.section-title {
  display: flex;
  align-items: baseline;
  margin-bottom: 30px;
  color: var(--ink);
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.2;
}

.section-title::before {
  content: "#";
  margin-right: 10px;
  color: var(--accent);
  font-weight: 700;
}

.qa-list {
  display: grid;
  gap: 30px;
}

.qa-item h3,
.project-entry h3 {
  color: var(--ink);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 1.3;
}

.qa-item p,
.project-entry p {
  margin-top: 8px;
  color: var(--muted);
}

.project-note {
  margin-top: 6px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 300;
  line-height: 1.55;
}

.qa-item p + p {
  margin-top: 12px;
}

.project-list {
  display: grid;
  gap: 28px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.project-entry {
  border-top: 1px solid var(--line);
  padding-top: 24px;
  transition: border-color 150ms cubic-bezier(0.4, 0, 0.2, 1);
}

.project-entry:hover {
  border-top-color: var(--accent-line);
}

.project-entry a {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  margin-top: 12px;
}

@media (max-width: 640px) {
  body {
    background:
      radial-gradient(circle at 50% 0%, rgba(57, 197, 187, 0.06), transparent 20rem),
      var(--bg);
  }

  .language-switch {
    top: 16px;
    right: 16px;
  }

  .page-shell {
    padding: 88px 20px 96px;
  }

  .site-header {
    margin-bottom: 64px;
  }

  .avatar {
    width: 130px;
    height: 130px;
    margin-bottom: 28px;
  }

  h1 {
    font-size: 34px;
    line-height: 1.12;
  }

  .hero-greeting {
    font-size: 34px;
  }

  .hero-copy {
    font-size: 17px;
  }

  .content-section {
    margin-top: 64px;
  }

  .section-title {
    margin-bottom: 24px;
  }
}

@media (max-width: 380px) {
  .language-switch {
    right: 14px;
  }

  .page-shell {
    padding: 84px 18px 88px;
  }

  h1 {
    font-size: 32px;
  }

  .hero-greeting {
    font-size: 32px;
  }
}

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

  .wave-hand.is-waving {
    animation: wave-hello-reduced 700ms ease-out 1;
  }

  .hero-greeting:hover .wave-hand {
    animation: wave-hello-reduced 700ms ease-out 1;
  }

  .wave-hand:hover {
    animation: wave-hello-reduced 700ms ease-out 1;
  }
}
