:root {
  color-scheme: light;
  --paper: #f6f0e8;
  --ink: #111318;
  --muted: #687078;
  --line: rgba(17, 19, 24, 0.13);
  --white: #fffaf2;
  --aqua: #0f7f78;
  --rose: #dd5c64;
  --acid: #c4d34f;
  --blue: #355f9a;
  --shadow: 0 28px 90px rgba(17, 19, 24, 0.16);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(17, 19, 24, 0.04) 1px, transparent 1px),
    linear-gradient(0deg, rgba(17, 19, 24, 0.035) 1px, transparent 1px),
    var(--paper);
  background-size: 44px 44px;
  font-family: Inter, "PingFang SC", "Microsoft YaHei", "Noto Sans SC", system-ui, sans-serif;
}

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

button,
a {
  -webkit-tap-highlight-color: transparent;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 14px clamp(18px, 4vw, 56px);
  border-bottom: 1px solid var(--line);
  background: rgba(246, 240, 232, 0.82);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 850;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: var(--ink);
  font-size: 12px;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: clamp(14px, 3vw, 32px);
  color: var(--muted);
  font-size: 14px;
}

.nav-links a:hover {
  color: var(--ink);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(330px, 0.72fr);
  gap: clamp(34px, 6vw, 88px);
  align-items: center;
  min-height: calc(100svh - 67px);
  padding: clamp(54px, 8vw, 108px) clamp(18px, 5vw, 72px) clamp(42px, 7vw, 84px);
}

.hero-copy {
  max-width: 880px;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--aqua);
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

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

h1 {
  margin-bottom: 16px;
  font-size: clamp(76px, 15vw, 190px);
  line-height: 0.86;
  letter-spacing: 0;
}

.hero-role {
  max-width: 780px;
  margin-bottom: 18px;
  font-size: clamp(26px, 4.3vw, 54px);
  line-height: 1.08;
  font-weight: 850;
}

.hero-text {
  max-width: 790px;
  color: #394249;
  font-size: clamp(16px, 2vw, 19px);
  line-height: 1.9;
}

.hero-actions,
.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  border: 1px solid currentColor;
  border-radius: 999px;
  padding: 0 20px;
  font-size: 14px;
  font-weight: 850;
  transition: transform 180ms ease, background 180ms ease, color 180ms ease;
}

.button:hover {
  transform: translateY(-2px);
}

.primary {
  color: #fff;
  background: var(--ink);
}

.secondary {
  color: var(--ink);
  background: transparent;
}

.light {
  color: var(--ink);
  border-color: #fff;
  background: #fff;
}

.dark {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.55);
}

.portrait-panel {
  position: relative;
  z-index: 0;
  margin: 0;
  min-height: 560px;
}

.portrait-panel img {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 620px;
  object-fit: cover;
  object-position: center top;
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.portrait-orbit {
  position: absolute;
  inset: -34px;
  z-index: -1;
  pointer-events: none;
}

.portrait-orbit::before,
.portrait-orbit::after {
  content: "";
  position: absolute;
  border-radius: 999px;
}

.portrait-orbit::before {
  top: 50%;
  left: 50%;
  width: min(120%, 600px);
  aspect-ratio: 1;
  border: 1px solid rgba(17, 19, 24, 0.13);
  transform: translate(-50%, -50%) rotate(0deg) translateX(42px) rotate(-8deg);
  animation: portrait-orbit 82s linear infinite;
}

.portrait-orbit::after {
  top: 53%;
  left: 57%;
  width: min(106%, 520px);
  aspect-ratio: 1;
  border: 1px solid rgba(15, 127, 120, 0.11);
  transform: translate(-50%, -50%) rotate(0deg) translateX(34px) rotate(18deg);
  animation: portrait-orbit-alt 96s linear infinite;
}

.portrait-orbit span {
  position: absolute;
  display: block;
  animation: portrait-spark 7s ease-in-out infinite;
}

.portrait-orbit span:nth-child(1) {
  top: 28%;
  left: 2%;
  width: 11px;
  height: 11px;
  border-radius: 999px;
  background: rgba(15, 127, 120, 0.48);
  box-shadow: 0 0 18px rgba(15, 127, 120, 0.2);
}

.portrait-orbit span:nth-child(2) {
  right: -2%;
  bottom: 30%;
  width: 16px;
  height: 16px;
  background: rgba(247, 190, 55, 0.6);
  clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%);
  animation-delay: -4s;
}

.portrait-orbit span:nth-child(3) {
  left: 12%;
  bottom: 12%;
  width: 10px;
  height: 10px;
  border-radius: 2px;
  background: rgba(90, 127, 255, 0.42);
  transform: rotate(45deg);
  animation-delay: -5.5s;
}

.portrait-orbit span:nth-child(4) {
  left: 21%;
  top: 8%;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: rgba(17, 19, 24, 0.34);
  animation-delay: -1.2s;
}

.portrait-orbit span:nth-child(5) {
  right: 16%;
  bottom: 6%;
  width: 11px;
  height: 11px;
  background: rgba(15, 127, 120, 0.44);
  clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%);
  animation-delay: -6.4s;
}

.portrait-panel::before,
.portrait-panel::after {
  content: "";
  position: absolute;
  z-index: -1;
  display: none;
}

.portrait-panel::before {
  inset: -18px;
}

.portrait-panel::after {
  inset: 26px -28px -20px 24px;
  border-color: rgba(221, 92, 100, 0.38);
}

.portrait-panel figcaption {
  position: absolute;
  z-index: 2;
  left: 18px;
  right: 18px;
  bottom: 18px;
  display: grid;
  gap: 6px;
  padding: 16px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 8px;
  color: #fff;
  background: rgba(17, 19, 24, 0.62);
  backdrop-filter: blur(16px);
}

.portrait-panel figcaption span {
  color: rgba(255, 255, 255, 0.75);
  line-height: 1.6;
}

@keyframes portrait-orbit {
  from {
    transform: translate(-50%, -50%) rotate(0deg) translateX(42px) rotate(-8deg);
  }

  to {
    transform: translate(-50%, -50%) rotate(360deg) translateX(42px) rotate(-8deg);
  }
}

@keyframes portrait-orbit-alt {
  from {
    transform: translate(-50%, -50%) rotate(0deg) translateX(34px) rotate(18deg);
  }

  to {
    transform: translate(-50%, -50%) rotate(-360deg) translateX(34px) rotate(18deg);
  }
}

@keyframes portrait-float {
  0%,
  100% {
    transform: translate3d(0, 0, 0) rotate(12deg);
  }

  50% {
    transform: translate3d(-8px, 7px, 0) rotate(18deg);
  }
}

@keyframes portrait-spark {
  0%,
  100% {
    opacity: 0.55;
    translate: 0 0;
  }

  50% {
    opacity: 0.86;
    translate: 0 -6px;
  }
}

.signal-strip {
  display: grid;
  grid-template-columns: 1.22fr repeat(4, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 250, 242, 0.7);
}

.signal-strip article {
  min-height: 128px;
  padding: 22px clamp(18px, 4vw, 42px);
  border-right: 1px solid var(--line);
}

.signal-strip span {
  display: block;
  margin-bottom: 10px;
  font-size: clamp(24px, 4vw, 42px);
  font-weight: 900;
}

.signal-strip p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.65;
}

.highlight-signal {
  color: #fff;
  background: var(--ink);
}

.highlight-signal p {
  color: rgba(255, 255, 255, 0.76);
}

.highlight-signal span {
  color: #fff;
}

.section {
  padding: clamp(68px, 9vw, 124px) clamp(18px, 5vw, 72px);
}

.section-heading {
  display: grid;
  grid-template-columns: minmax(160px, 0.26fr) minmax(0, 0.86fr) minmax(260px, 0.5fr);
  gap: 24px;
  align-items: end;
  margin-bottom: 34px;
}

.section-heading h2 {
  margin-bottom: 0;
  font-size: clamp(36px, 7vw, 82px);
  line-height: 1;
  letter-spacing: 0;
}

.section-heading p:last-child {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.75;
}

.works-section {
  background: #fffaf2;
}

.portfolio-block {
  display: grid;
  grid-template-columns: minmax(250px, 0.32fr) minmax(0, 1fr);
  gap: clamp(22px, 4vw, 48px);
  padding: clamp(26px, 4vw, 44px) 0;
  border-top: 1px solid var(--line);
}

.portfolio-block + .portfolio-block {
  margin-top: 28px;
}

.vibe-block {
  border-top-color: rgba(15, 127, 120, 0.3);
}

.portfolio-intro {
  position: sticky;
  top: 92px;
  align-self: start;
}

.portfolio-intro h3 {
  margin-bottom: 14px;
  font-size: clamp(30px, 4.8vw, 58px);
  line-height: 1.02;
}

.portfolio-intro p {
  color: var(--muted);
  line-height: 1.78;
}

.portfolio-intro a {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  margin-top: 8px;
  border: 1px solid var(--ink);
  border-radius: 999px;
  padding: 0 16px;
  font-size: 14px;
  font-weight: 850;
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.portfolio-card {
  display: grid;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.66);
  cursor: pointer;
  text-align: left;
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.portfolio-card:hover {
  box-shadow: 0 18px 52px rgba(17, 19, 24, 0.12);
  transform: translateY(-4px);
}

.portfolio-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  object-position: top center;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.portfolio-card .tag-row,
.portfolio-card strong {
  margin-right: 18px;
  margin-left: 18px;
}

.portfolio-card .tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.portfolio-card .tag-row span {
  display: inline-flex;
  min-height: 26px;
  align-items: center;
  border: 1px solid rgba(15, 127, 120, 0.28);
  border-radius: 999px;
  padding: 0 9px;
  color: var(--aqua);
  font-size: 12px;
  font-weight: 900;
  background: rgba(15, 127, 120, 0.08);
}

.portfolio-card strong {
  margin-top: 8px;
  margin-bottom: 18px;
  font-size: clamp(20px, 2.6vw, 30px);
  line-height: 1.16;
}

.card-title-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 44px;
  gap: 14px;
  align-items: end;
  margin: 8px 18px 18px;
}

.card-title-row strong {
  margin: 0;
}

.card-arrow {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: var(--ink);
  font-size: 22px;
  font-weight: 900;
  line-height: 1;
  transition: transform 180ms ease, background 180ms ease;
}

.link-card:hover .card-arrow {
  background: var(--aqua);
  transform: translate(2px, -2px);
}

.path-section {
  background: #eef3ef;
}

.path-list {
  display: grid;
  gap: 0;
}

.path-list article {
  display: grid;
  grid-template-columns: 180px minmax(0, 0.72fr) minmax(0, 1fr);
  gap: 26px;
  padding: 24px 0;
  border-top: 1px solid rgba(17, 19, 24, 0.13);
}

.path-list time {
  color: var(--aqua);
  font-weight: 900;
}

.path-list h3 {
  margin-bottom: 0;
  font-size: clamp(22px, 3vw, 34px);
  line-height: 1.2;
}

.path-list p {
  margin-bottom: 0;
  color: var(--muted);
  line-height: 1.75;
}

.awards-section {
  background: #f4f1fb;
}

.award-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.award-list article {
  min-height: 168px;
  padding: 22px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  border-top: 4px solid var(--rose);
  background: rgba(255, 255, 255, 0.52);
}

.award-list article:nth-last-child(-n+4) {
  border-top-color: var(--aqua);
}

.award-list article:nth-last-child(-n+2) {
  border-top-color: var(--acid);
}

.award-list time {
  display: inline-flex;
  margin-bottom: 22px;
  color: var(--blue);
  font-size: 13px;
  font-weight: 900;
}

.award-list h3 {
  margin-bottom: 10px;
  font-size: 20px;
  line-height: 1.35;
}

.award-list p {
  margin-bottom: 0;
  color: var(--muted);
}

.guestbook-section {
  background:
    linear-gradient(135deg, rgba(15, 127, 120, 0.08), transparent 42%),
    linear-gradient(315deg, rgba(221, 92, 100, 0.08), transparent 48%),
    #fffaf2;
}

.guestbook-panel {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.62);
  box-shadow: 0 26px 86px rgba(17, 19, 24, 0.08);
}

.guestbook-overview {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 24px;
  align-items: end;
  padding: clamp(22px, 4vw, 34px);
  border-bottom: 1px solid var(--line);
}

.guestbook-overview h3 {
  max-width: 760px;
  margin-bottom: 0;
  font-size: clamp(30px, 5vw, 56px);
  line-height: 1.05;
}

.guestbook-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(86px, 1fr));
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(246, 240, 232, 0.72);
}

.guestbook-stats span {
  display: grid;
  gap: 4px;
  min-height: 76px;
  align-content: center;
  padding: 12px 16px;
  border-right: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
}

.guestbook-stats span:last-child {
  border-right: 0;
}

.guestbook-stats strong {
  color: var(--ink);
  font-size: 26px;
  line-height: 1;
}

.danmaku-stage {
  position: relative;
  overflow: hidden;
  min-height: 220px;
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(90deg, rgba(255, 250, 242, 0.98), rgba(255, 250, 242, 0.2) 16%, rgba(255, 250, 242, 0.2) 84%, rgba(255, 250, 242, 0.98)),
    repeating-linear-gradient(90deg, rgba(17, 19, 24, 0.04) 0 1px, transparent 1px 54px);
}

.danmaku-track {
  position: absolute;
  inset: 0;
}

.danmaku-item {
  position: absolute;
  left: 100%;
  top: var(--lane);
  display: inline-flex;
  min-width: max-content;
  align-items: center;
  gap: 10px;
  border: 1px solid rgba(17, 19, 24, 0.12);
  border-radius: 999px;
  padding: 9px 14px 9px 10px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: 0 10px 36px rgba(17, 19, 24, 0.08);
  animation: danmaku-float var(--speed) linear infinite;
  animation-delay: var(--delay);
  white-space: nowrap;
}

.danmaku-item strong {
  display: inline-flex;
  min-height: 24px;
  align-items: center;
  border-radius: 999px;
  padding: 0 9px;
  color: #fff;
  background: var(--ink);
  font-size: 12px;
}

.danmaku-item em {
  color: var(--aqua);
  font-style: normal;
  font-weight: 900;
}

@keyframes danmaku-float {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(calc(-100vw - 100% - 120px));
  }
}

.guestbook-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  padding: 18px clamp(18px, 4vw, 34px);
}

.guest-action,
.guest-submit {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 18px;
  color: #575b66;
  background: rgba(255, 255, 255, 0.76);
  cursor: pointer;
  font-weight: 900;
  transition: transform 180ms ease, border-color 180ms ease, color 180ms ease, background 180ms ease, box-shadow 180ms ease;
}

.guest-action:hover,
.guest-submit:hover {
  transform: translateY(-2px);
}

.guest-action.is-active {
  border-color: rgba(221, 92, 100, 0.38);
  color: var(--rose);
  background: rgba(221, 92, 100, 0.1);
  box-shadow: 0 12px 34px rgba(221, 92, 100, 0.16);
}

.guest-action.is-active .action-icon {
  animation: icon-pop 320ms cubic-bezier(0.2, 1.4, 0.4, 1);
}

@keyframes icon-pop {
  0% {
    transform: scale(0.8) rotate(-8deg);
  }
  60% {
    transform: scale(1.18) rotate(4deg);
  }
  100% {
    transform: scale(1) rotate(0);
  }
}

.action-icon {
  width: 20px;
  height: 20px;
  object-fit: contain;
  opacity: 0.72;
  filter: grayscale(1) brightness(0.72);
  transition: transform 180ms ease;
}

.guest-action.is-active .action-icon {
  opacity: 1;
  filter: brightness(0) saturate(100%) invert(52%) sepia(33%) saturate(1400%) hue-rotate(310deg) brightness(89%) contrast(95%);
}

.message-form {
  display: grid;
  grid-template-columns: minmax(210px, 0.8fr) minmax(150px, 0.45fr) minmax(250px, 1fr) auto;
  gap: 14px;
  align-items: end;
  padding: 0 clamp(18px, 4vw, 34px) 28px;
}

.message-form[hidden] {
  display: none;
}

.message-form fieldset {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-width: 0;
  margin: 0;
  border: 0;
  padding: 0;
}

.message-form legend,
.field-label span {
  width: 100%;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.message-form label {
  font-weight: 850;
}

.message-form fieldset label {
  display: inline-flex;
  min-height: 36px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 12px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.68);
  cursor: pointer;
}

.message-form input[type="radio"] {
  accent-color: var(--aqua);
  margin-right: 6px;
}

.field-label {
  position: relative;
  display: grid;
  min-width: 0;
}

.field-label input {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 14px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.84);
  font: inherit;
  outline: none;
}

.message-field input {
  padding-right: 62px;
}

.field-label input:focus {
  border-color: rgba(15, 127, 120, 0.56);
  box-shadow: 0 0 0 4px rgba(15, 127, 120, 0.08);
}

.message-field em {
  position: absolute;
  right: 14px;
  bottom: 12px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  font-weight: 900;
}

.guest-submit {
  color: #fff;
  border-color: var(--ink);
  background: var(--ink);
}

.contact-section {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 28px;
  align-items: end;
  padding: clamp(56px, 8vw, 98px) clamp(18px, 5vw, 72px);
  color: #fff;
  background: var(--ink);
}

.contact-section h2 {
  max-width: 980px;
  margin-bottom: 18px;
  font-size: clamp(34px, 6vw, 74px);
  line-height: 1.05;
}

.contact-section p {
  color: rgba(255, 255, 255, 0.74);
}

.contact-section .eyebrow {
  color: var(--acid);
}

.site-footer {
  display: grid;
  gap: 8px;
  padding: 18px clamp(18px, 5vw, 72px) 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  background: var(--ink);
  text-align: center;
}

.site-footer p {
  margin: 0;
  color: rgba(255, 255, 255, 0.46);
  font-size: 13px;
}

.site-footer a {
  color: rgba(255, 255, 255, 0.58);
  font-size: 13px;
  text-decoration: none;
  transition: color 0.2s ease;
}

.site-footer a:hover {
  color: rgba(255, 255, 255, 0.86);
}

.work-dialog {
  width: min(680px, calc(100vw - 36px));
  border: 1px solid rgba(255, 255, 255, 0.38);
  border-radius: 10px;
  padding: 28px;
  color: #fff;
  background: rgba(17, 19, 24, 0.92);
  box-shadow: var(--shadow);
  backdrop-filter: blur(20px);
}

.work-dialog::backdrop {
  background: rgba(17, 19, 24, 0.42);
  backdrop-filter: blur(4px);
}

.dialog-close {
  position: absolute;
  top: 12px;
  right: 14px;
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.36);
  border-radius: 50%;
  color: #fff;
  background: transparent;
  cursor: pointer;
  font-size: 24px;
}

.dialog-source {
  color: rgba(255, 255, 255, 0.68);
  font-weight: 800;
}

.work-dialog h2 {
  margin-bottom: 18px;
  font-size: clamp(30px, 6vw, 54px);
  line-height: 1;
}

.dialog-detail {
  color: rgba(255, 255, 255, 0.74);
  line-height: 1.8;
}

.dialog-link {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  margin-top: 18px;
  border: 1px solid #fff;
  border-radius: 999px;
  padding: 0 18px;
  font-weight: 850;
}

@media (max-width: 1120px) {
  .section-heading,
  .hero,
  .contact-section {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 820px) {
  .site-header {
    align-items: center;
    flex-direction: row;
    padding: 12px 16px;
  }

  .brand {
    gap: 8px;
  }

  .brand-mark {
    width: 34px;
    height: 34px;
  }

  .nav-links {
    flex: 1;
    justify-content: flex-end;
    gap: 16px;
    font-size: 13px;
  }

  .hero {
    min-height: auto;
    gap: 30px;
    padding: 44px 18px 56px;
  }

  h1 {
    margin-bottom: 14px;
    font-size: clamp(62px, 22vw, 118px);
  }

  .hero-role {
    max-width: 620px;
    margin-bottom: 16px;
    font-size: clamp(25px, 8vw, 38px);
    line-height: 1.12;
  }

  .hero-text {
    font-size: 15px;
    line-height: 1.78;
  }

  .portrait-panel {
    width: min(100%, 520px);
    justify-self: center;
    min-height: 430px;
  }

  .portrait-panel img {
    height: 430px;
  }

  .portrait-panel figcaption {
    left: 12px;
    right: 12px;
    bottom: 12px;
    padding: 12px;
  }

  .signal-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .signal-strip article {
    min-height: 106px;
    padding: 18px;
  }

  .signal-strip article:nth-child(2n) {
    border-right: 0;
  }

  .highlight-signal {
    grid-column: 1 / -1;
  }

  .signal-strip span {
    font-size: clamp(22px, 7vw, 31px);
  }

  .signal-strip p {
    font-size: 13px;
    line-height: 1.55;
  }

  .section {
    padding: 64px 18px;
  }

  .section-heading {
    gap: 10px;
    margin-bottom: 28px;
  }

  .section-heading h2 {
    font-size: clamp(44px, 14vw, 68px);
  }

  .section-heading p:last-child {
    font-size: 14px;
  }

  .award-list {
    grid-template-columns: 1fr;
  }

  .portfolio-block,
  .portfolio-grid {
    grid-template-columns: 1fr;
  }

  .portfolio-block {
    gap: 24px;
    padding: 34px 0 46px;
  }

  .portfolio-block + .portfolio-block {
    margin-top: 8px;
  }

  .portfolio-intro {
    position: static;
  }

  .portfolio-intro h3 {
    max-width: 9em;
    font-size: clamp(36px, 12vw, 54px);
  }

  .portfolio-intro p {
    max-width: 34em;
    font-size: 15px;
  }

  .portfolio-intro a {
    min-height: 40px;
  }

  .portfolio-grid {
    gap: 16px;
  }

  .portfolio-card img {
    aspect-ratio: 16 / 10;
  }

  .portfolio-card strong {
    font-size: clamp(24px, 7vw, 33px);
    line-height: 1.13;
  }

  .card-title-row {
    grid-template-columns: minmax(0, 1fr) 42px;
  }

  .card-arrow {
    width: 42px;
    height: 42px;
  }

  .path-list article {
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 26px 0;
  }

  .path-list h3 {
    font-size: clamp(24px, 7vw, 34px);
  }

  .award-list article {
    min-height: 146px;
    padding: 20px;
  }

  .guestbook-overview,
  .message-form {
    grid-template-columns: 1fr;
  }

  .guestbook-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .danmaku-stage {
    min-height: 190px;
  }

  .contact-section {
    grid-template-columns: 1fr;
    gap: 22px;
    padding: 58px 18px 64px;
  }

  .work-dialog {
    padding: 24px 20px;
  }
}

@media (max-width: 520px) {
  .nav-links {
    gap: 12px;
    font-size: 12px;
  }

  .button {
    width: 100%;
  }

  .hero-actions,
  .contact-actions {
    width: 100%;
  }

  .hero {
    padding-top: 36px;
  }

  .hero-actions {
    gap: 10px;
  }

  .portrait-panel,
  .portrait-panel img {
    height: auto;
    min-height: 0;
  }

  .portrait-panel img {
    height: min(112vw, 520px);
    object-position: center 18%;
  }

  .portrait-panel::before {
    inset: -10px;
  }

  .portrait-panel::after {
    inset: 16px -12px -12px 14px;
  }

  .portrait-panel figcaption {
    position: static;
    margin-top: 10px;
    border-color: rgba(17, 19, 24, 0.12);
    color: var(--ink);
    background: rgba(255, 250, 242, 0.9);
    box-shadow: 0 14px 40px rgba(17, 19, 24, 0.08);
  }

  .portrait-panel figcaption span {
    color: var(--muted);
    font-size: 12px;
  }

  .signal-strip {
    grid-template-columns: 1fr;
  }

  .signal-strip article {
    border-right: 0;
  }

  .signal-strip span {
    margin-bottom: 8px;
  }

  .section {
    padding: 56px 16px;
  }

  .portfolio-block {
    padding: 30px 0 42px;
  }

  .portfolio-card .tag-row,
  .portfolio-card strong {
    margin-right: 16px;
    margin-left: 16px;
  }

  .portfolio-card .tag-row {
    margin-top: 16px;
  }

  .card-title-row {
    grid-template-columns: minmax(0, 1fr) 38px;
    gap: 10px;
    margin: 8px 16px 16px;
  }

  .card-arrow {
    width: 38px;
    height: 38px;
    font-size: 20px;
  }

  .award-list h3 {
    font-size: 18px;
  }

  .guestbook-overview {
    padding: 22px 16px;
  }

  .guestbook-stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .guestbook-stats span {
    min-height: 58px;
    padding: 10px 12px;
    border-right: 1px solid var(--line);
    border-bottom: 0;
  }

  .guestbook-stats strong {
    font-size: 24px;
  }

  .guestbook-stats span:last-child {
    border-right: 0;
  }

  .danmaku-stage {
    min-height: 180px;
  }

  .danmaku-item {
    max-width: calc(100vw - 48px);
    padding: 8px 12px 8px 8px;
    font-size: 13px;
    animation-duration: calc(var(--speed) * 0.68);
  }

  .guestbook-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    padding: 16px;
  }

  .guest-action {
    padding: 0 12px;
  }

  .message-form {
    padding: 0 16px 24px;
  }

  .message-form fieldset label {
    flex: 1;
    justify-content: center;
  }

  .work-dialog {
    width: min(100vw - 24px, 680px);
    padding: 22px 18px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .danmaku-item,
  .portrait-orbit::before,
  .portrait-orbit::after,
  .portrait-orbit span {
    animation-play-state: paused;
  }
}
