:root {
  --bg: #f6f9ff;
  --paper: #ffffff;
  --paper-soft: #f8fbff;
  --ink: #111827;
  --muted: #5f6b7a;
  --line: #dfe7f2;
  --blue: #1d5fd7;
  --blue-2: #67d7e7;
  --cyan-soft: #dcfbff;
  --shadow: 0 24px 70px rgba(30, 74, 130, 0.12);
  --radius: 28px;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Inter", "PingFang SC", "Microsoft YaHei", "Noto Sans SC", Arial, sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 84% 10%, rgba(100, 215, 231, 0.22), transparent 34%),
    radial-gradient(circle at 8% 18%, rgba(29, 95, 215, 0.09), transparent 32%),
    linear-gradient(180deg, #ffffff 0%, var(--bg) 62%, #ffffff 100%);
  overflow-x: hidden;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(20px);
  background: rgba(255, 255, 255, 0.82);
  border-bottom: 1px solid rgba(223, 231, 242, 0.8);
}

.nav {
  max-width: 1180px;
  margin: 0 auto;
  padding: 18px 24px;
  display: flex;
  align-items: center;
  gap: 28px;
}

.brand {
  display: flex;
  align-items: center;
  min-width: 180px;
}

.brand strong {
  display: block;
  font-size: 16px;
}

.brand span {
  display: block;
  margin-top: 2px;
  font-size: 12px;
  color: var(--muted);
}

.nav-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  flex: 1;
}

.nav-links a {
  padding: 12px 20px;
  border-radius: 999px;
  color: #3b4656;
  font-weight: 800;
  font-size: 16px;
  white-space: nowrap;
}

.nav-links a.active {
  background: #070b12;
  color: #ffffff;
}

.nav-actions {
  display: flex;
  gap: 10px;
  align-items: center;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-weight: 800;
  font-size: 14px;
  cursor: pointer;
  background: #ffffff;
}

.button.primary {
  color: #ffffff;
  background: #070b12;
  border-color: #070b12;
  box-shadow: 0 16px 34px rgba(7, 11, 18, 0.18);
}

.button.blue {
  color: #073066;
  background: linear-gradient(135deg, #e7fbff, #e9f1ff);
  border-color: #cde5f6;
}

.page {
  max-width: 1180px;
  margin: 0 auto;
  padding: 22px 24px 52px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  grid-template-areas:
    "intro profile"
    "contact profile"
    "facts facts";
  gap: 14px 44px;
  align-items: stretch;
  min-height: 0;
  padding: 22px;
  border: 1px solid rgba(203, 223, 241, 0.7);
  border-radius: 30px;
  background:
    linear-gradient(135deg, rgba(242, 249, 255, 0.72), rgba(231, 249, 252, 0.58)),
    rgba(255, 255, 255, 0.5);
}

.hero-intro {
  grid-area: intro;
  display: grid;
  align-content: end;
  justify-items: start;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: 999px;
  background: #eef8ff;
  color: #164b8f;
  font-size: 15px;
  font-weight: 800;
}

.hero h1 {
  margin: 8px 0 8px;
  font-size: clamp(52px, 7vw, 82px);
  line-height: 0.95;
  letter-spacing: 0;
  text-wrap: balance;
}

.hero h2 {
  margin: 0;
  max-width: 820px;
  font-size: clamp(28px, 3.2vw, 40px);
  line-height: 1.08;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

.hero-copy {
  max-width: 720px;
  margin: 18px 0 0;
  color: #344154;
  font-size: 18px;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.hero-copy strong {
  color: #101827;
  font-weight: 900;
}

.hero-facts {
  grid-area: facts;
  display: grid;
  grid-template-columns: 1.04fr 1.42fr 1.46fr;
  gap: 12px;
  margin-top: 0;
}

.hero-contact-strip {
  grid-area: contact;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 0;
}

.hero-contact-strip div {
  min-width: 0;
  min-height: 78px;
  padding: 15px 18px;
  border: 1px solid rgba(13, 99, 200, 0.28);
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(232, 248, 255, 0.94), rgba(255, 255, 255, 0.96));
  box-shadow: 0 12px 30px rgba(13, 99, 200, 0.08);
}

.hero-facts div {
  min-width: 0;
  min-height: 72px;
  padding: 13px 14px;
  border: 1px solid rgba(203, 223, 241, 0.95);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.7);
}

.hero-facts span,
.hero-contact-strip span {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.hero-facts strong,
.hero-contact-strip strong {
  display: block;
  color: #111827;
  font-size: 14px;
  line-height: 1.45;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hero-contact-strip strong {
  color: #062f5f;
  font-size: 16px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 30px 0;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  background: #ffffff;
  border: 1px solid var(--line);
  color: #344154;
  font-size: 13px;
  font-weight: 800;
  max-width: 100%;
  min-width: 0;
  overflow-wrap: anywhere;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero .cta-row {
  margin-top: 22px;
}

.profile-card {
  grid-area: profile;
  align-self: stretch;
  display: grid;
  align-content: center;
  min-height: 360px;
  padding: 18px;
  border-radius: 34px;
  border: 1px solid rgba(211, 225, 241, 0.95);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(243, 249, 255, 0.92)),
    radial-gradient(circle at 80% 0%, rgba(103, 215, 231, 0.22), transparent 40%);
  box-shadow: 0 20px 52px rgba(30, 74, 130, 0.13);
}

.photo-frame {
  width: 132px;
  margin: 0 auto 18px;
  padding: 6px;
  border-radius: 22px;
  background: #ffffff;
  border: 1px solid #d8e7f4;
  box-shadow: 0 16px 38px rgba(44, 96, 145, 0.14);
}

.photo-frame img {
  width: 100%;
  display: block;
  border-radius: 16px;
}

.profile-card h3 {
  margin: 0;
  text-align: center;
  font-size: 21px;
}

.profile-card p {
  margin: 8px 0 0;
  text-align: center;
  color: var(--muted);
  line-height: 1.35;
  font-size: 14px;
}

.profile-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 22px;
}

.profile-actions .button {
  min-height: 40px;
  padding: 0 12px;
  font-size: 13px;
}

.quick-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.project-jump-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.project-jump-card {
  min-height: 98px;
  padding: 15px 16px;
  border-radius: 20px;
  background: #ffffff;
  border: 1px solid var(--line);
  box-shadow: 0 18px 48px rgba(30, 74, 130, 0.08);
  color: inherit;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.project-jump-card:hover {
  transform: translateY(-3px);
  border-color: #b7d9ef;
  box-shadow: 0 22px 58px rgba(30, 74, 130, 0.12);
}

.project-jump-card span {
  display: block;
  width: fit-content;
  margin-bottom: 8px;
  padding: 4px 9px;
  border-radius: 999px;
  background: #eef7ff;
  color: #174a87;
  font-size: 13px;
  font-weight: 800;
}

.project-jump-card h3 {
  margin: 0;
  font-size: 19px;
  letter-spacing: 0;
}

.project-jump-card p {
  min-height: 28px;
  margin: 5px 0 5px;
  font-size: 14px;
  color: var(--muted);
  line-height: 1.45;
}

.project-jump-card strong {
  display: inline-flex;
  width: fit-content;
  padding: 5px 9px;
  border-radius: 999px;
  background: #f2f8ff;
  color: #174a87;
  font-size: 12px;
  font-weight: 800;
}

.section {
  margin-top: 74px;
}

.hero + .section {
  margin-top: 26px;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 12px;
}

.section h2 {
  margin: 0;
  font-size: clamp(28px, 3.2vw, 40px);
  letter-spacing: 0;
}

.section-head p {
  max-width: 560px;
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.project-grid {
  display: grid;
  gap: 18px;
}

.project-card {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  gap: 22px;
  padding: 26px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid var(--line);
  box-shadow: 0 18px 55px rgba(30, 74, 130, 0.08);
}

.project-no {
  width: 72px;
  height: 72px;
  border-radius: 24px;
  display: grid;
  place-items: center;
  color: #ffffff;
  font-size: 24px;
  font-weight: 900;
  background: linear-gradient(135deg, var(--blue), #16bdd2);
}

.project-card h3 {
  margin: 0;
  font-size: 25px;
  letter-spacing: 0;
}

.project-card p {
  margin: 12px 0 0;
  color: #425064;
  line-height: 1.75;
  overflow-wrap: anywhere;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.meta {
  padding: 7px 10px;
  border-radius: 999px;
  background: #eef7ff;
  color: #174a87;
  font-size: 12px;
  font-weight: 800;
}

.meta-highlight {
  color: #ffffff;
  background: #070b12;
  border: 1px solid #070b12;
  box-shadow: 0 10px 24px rgba(7, 11, 18, 0.18);
}

.meta-link {
  text-decoration: none;
  background: #e5f7ff;
  border: 1px solid #bee7ff;
}

.meta-link:hover {
  color: #ffffff;
  background: var(--blue);
  border-color: var(--blue);
}

.experience-strip {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
}

.strip-card {
  padding: 20px;
  min-height: 156px;
  border-radius: 24px;
  background: #ffffff;
  border: 1px solid var(--line);
}

.strip-card h3 {
  margin: 0 0 12px;
  font-size: 18px;
}

.strip-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
  font-size: 14px;
}

.job-match {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 16px 20px;
  border-radius: 24px;
  background: linear-gradient(135deg, #ffffff, #e9fbff);
  border: 1px solid #cbe8f5;
  box-shadow: 0 20px 54px rgba(29, 95, 215, 0.1);
}

.section.job-match {
  margin-top: 18px;
}

.job-match h3 {
  margin: 0;
  font-size: 22px;
}

.job-match p {
  margin: 8px 0 0;
  color: var(--muted);
  line-height: 1.6;
}

.page-title {
  padding: 58px 0 30px;
}

.page-title h1 {
  margin: 0;
  font-size: clamp(36px, 5.4vw, 64px);
  line-height: 1.05;
  letter-spacing: 0;
  text-wrap: balance;
}

.page-title p {
  max-width: 760px;
  margin: 22px 0 0;
  color: #344154;
  font-size: 19px;
  line-height: 1.8;
}

.module-page .page-title {
  padding: 42px 0 26px;
}

.module-page .page-title h1 {
  max-width: 980px;
  font-size: clamp(32px, 4.6vw, 56px);
  line-height: 1.08;
  letter-spacing: 0;
}

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.panel {
  padding: 28px;
  border-radius: var(--radius);
  background: #ffffff;
  border: 1px solid var(--line);
  box-shadow: 0 18px 55px rgba(30, 74, 130, 0.07);
}

.panel h2,
.panel h3 {
  margin-top: 0;
}

.panel p,
.panel li {
  color: #3d4b5f;
  line-height: 1.76;
}

.award-proof-list {
  display: grid;
  gap: 12px;
}

.award-proof-item {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px 14px;
  align-items: center;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.76);
  color: inherit;
  text-align: left;
  cursor: pointer;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.award-proof-item:hover {
  transform: translateY(-2px);
  border-color: #9dd8ff;
  box-shadow: 0 18px 42px rgba(25, 89, 150, 0.12);
}

.award-proof-item span {
  color: var(--blue);
  font-size: 12px;
  font-weight: 900;
}

.award-proof-item strong {
  grid-column: 1 / 2;
  color: #111827;
  font-size: 16px;
  line-height: 1.45;
}

.award-proof-item em {
  grid-column: 2 / 3;
  grid-row: 1 / span 2;
  align-self: center;
  font-style: normal;
  color: #174a87;
  font-size: 13px;
  font-weight: 900;
}

.timeline {
  display: grid;
  gap: 16px;
}

.timeline-item {
  padding: 22px;
  border-radius: 24px;
  background: #ffffff;
  border: 1px solid var(--line);
}

.timeline-item time {
  color: var(--blue);
  font-weight: 900;
}

.timeline-item h3 {
  margin: 8px 0 6px;
  font-size: 22px;
}

.education-overview {
  margin-top: 26px;
}

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

.education-card {
  display: flex;
  min-height: 172px;
  flex-direction: column;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 18px 48px rgba(31, 61, 92, 0.07);
}

.education-card.primary {
  background: linear-gradient(135deg, #ffffff 0%, #edf8ff 100%);
}

.education-card time {
  color: var(--blue);
  font-weight: 900;
}

.education-card h3 {
  margin: 10px 0 8px;
  font-size: 22px;
  line-height: 1.25;
}

.education-card p {
  max-width: 96%;
  margin: 0;
  color: #3d4b5f;
  line-height: 1.75;
}

.research-block {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.research-block h2 {
  margin: 0 0 16px;
  font-size: 28px;
}

.research-facts {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.research-facts div {
  min-height: 118px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
}

.research-facts span {
  display: block;
  margin-bottom: 10px;
  color: var(--muted);
  font-weight: 800;
}

.research-facts strong {
  color: #111827;
  font-size: 17px;
  line-height: 1.55;
}

.projects-workspace {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.project-side-nav {
  position: sticky;
  top: 104px;
  display: grid;
  gap: 10px;
  padding: 14px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.84);
  border: 1px solid var(--line);
  box-shadow: 0 18px 48px rgba(30, 74, 130, 0.08);
}

.project-side-nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 14px;
  border-radius: 16px;
  color: #344154;
  font-weight: 900;
  text-decoration: none;
}

.project-side-nav a span {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 999px;
  background: #eef7ff;
  color: #174a87;
  font-size: 12px;
}

.project-side-nav a.active {
  color: #ffffff;
  background: #070b12;
}

.project-side-nav a.active span {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
}

.project-panel {
  display: none;
}

.project-panel.active {
  display: block;
}

.detail-project {
  margin-bottom: 24px;
  padding: 30px;
  border-radius: 34px;
  background: #ffffff;
  border: 1px solid var(--line);
  box-shadow: 0 18px 55px rgba(30, 74, 130, 0.08);
  scroll-margin-top: 110px;
}

details[id] {
  scroll-margin-top: 110px;
}

.detail-project h2 {
  margin: 0;
  font-size: clamp(28px, 4vw, 44px);
  letter-spacing: 0;
  text-wrap: balance;
}

.project-title-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
}

.module-start-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 16px;
  border-radius: 999px;
  color: #ffffff;
  background: #070b12;
  font-size: 14px;
  font-weight: 900;
  text-decoration: none;
  box-shadow: 0 14px 32px rgba(7, 11, 18, 0.16);
  white-space: nowrap;
}

.module-start-link::after {
  content: " ->";
}

.module-start-link:hover {
  background: #0d63c8;
}

.project-summary {
  display: grid;
  grid-template-columns: 1fr;
  gap: 26px;
  margin-top: 20px;
}

.project-summary p {
  margin: 0 0 12px;
  color: #243247;
  font-size: 17px;
  line-height: 1.78;
}

.project-summary p:last-child {
  margin-bottom: 0;
}

.diagram-placeholder {
  width: 100%;
  padding: 18px;
  border-radius: 26px;
  background: #ffffff;
  border: 1px solid #d7e5f2;
}

.diagram-placeholder h3 {
  margin: 0 0 14px;
}

.project-overview-figure {
  position: relative;
  margin: 0;
  padding: 18px;
  border: 1px solid #d7e5f2;
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 14px 34px rgba(30, 74, 130, 0.1);
}

.project-figure-stack {
  display: grid;
  gap: 18px;
}

.project-overview-figure img {
  display: block;
  width: 100%;
  max-height: 760px;
  object-fit: contain;
  border-radius: 12px;
  background: #f8fbff;
}

.detail-project .project-summary {
  grid-template-columns: minmax(0, 1fr);
}

.detail-project .diagram-placeholder {
  grid-column: 1 / -1;
}

.detail-project .project-overview-figure {
  width: 100%;
}

.project-overview-figure figcaption {
  margin-top: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.figure-action-link {
  position: absolute;
  right: 30px;
  bottom: 30px;
  z-index: 3;
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border-radius: 999px;
  color: #ffffff;
  background: #070b12;
  border: 1px solid rgba(255, 255, 255, 0.76);
  box-shadow: 0 16px 36px rgba(7, 11, 18, 0.2);
  font-size: 14px;
  font-weight: 900;
  text-decoration: none;
}

.figure-action-link::after {
  content: " ->";
}

.figure-action-link:hover {
  background: #0d63c8;
}

.diagram-hotspot {
  position: absolute;
  z-index: 2;
  transform: translate(-50%, -50%);
  display: grid;
  width: 24px;
  height: 24px;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 2px solid rgba(255, 255, 255, 0.96);
  border-radius: 999px;
  color: transparent;
  background: #0d63c8;
  box-shadow: 0 0 0 5px rgba(13, 99, 200, 0.14), 0 10px 24px rgba(13, 99, 200, 0.2);
  font-size: 0;
  font-weight: 900;
  line-height: 1;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  opacity: 0.88;
  transition: opacity 0.16s ease, background 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease, transform 0.16s ease;
}

.diagram-hotspot::before {
  content: attr(aria-label);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 10px);
  width: max-content;
  max-width: 220px;
  padding: 8px 11px;
  border: 1px solid rgba(13, 99, 200, 0.35);
  border-radius: 999px;
  color: #063b78;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 12px 28px rgba(13, 99, 200, 0.16);
  font-size: 13px;
  line-height: 1.2;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 6px);
  transition: opacity 0.16s ease, transform 0.16s ease;
}

.diagram-hotspot::after {
  content: "+";
  display: grid;
  width: 100%;
  height: 100%;
  place-items: center;
  color: #ffffff;
  font-size: 16px;
  line-height: 1;
}

.diagram-hotspot:hover,
.diagram-hotspot:focus-visible {
  color: #ffffff;
  opacity: 1;
  background: #073b78;
  border-color: #ffffff;
  box-shadow: 0 12px 28px rgba(13, 99, 200, 0.18);
  transform: translate(-50%, -50%) scale(1.12);
}

.diagram-hotspot:hover::before,
.diagram-hotspot:focus-visible::before {
  opacity: 1;
  transform: translate(-50%, 0);
}

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

.diagram-node {
  display: grid;
  gap: 6px;
  min-height: 84px;
  padding: 14px;
  border: 1px solid #d3e6f5;
  border-radius: 16px;
  color: #132238;
  background: #ffffff;
  text-decoration: none;
  box-shadow: 0 12px 28px rgba(31, 83, 130, 0.08);
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.diagram-node:hover {
  transform: translateY(-2px);
  border-color: #7fc7f2;
  box-shadow: 0 18px 36px rgba(27, 103, 174, 0.16);
}

.diagram-node span {
  color: var(--blue);
  font-size: 12px;
  font-weight: 900;
}

.diagram-node strong {
  font-size: 15px;
  line-height: 1.35;
}

.diagram-node.accent {
  color: #ffffff;
  background: linear-gradient(135deg, #0d63c8, #16b6d8);
  border-color: transparent;
}

.diagram-node.accent span {
  color: rgba(255, 255, 255, 0.78);
}

.diagram-arrow {
  display: none;
}

.project-visual {
  display: block;
  width: 100%;
  border-radius: 18px;
  border: 1px solid #d7e5f2;
  box-shadow: 0 14px 34px rgba(30, 74, 130, 0.1);
}

.visual-caption {
  margin: 12px 4px 0;
  color: #425064;
  font-size: 13px;
  line-height: 1.55;
}

.flow {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.flow span {
  padding: 10px 12px;
  border-radius: 14px;
  background: #ffffff;
  border: 1px solid #cfe0ef;
  font-size: 13px;
  font-weight: 800;
}

.module-list {
  display: grid;
  gap: 12px;
  margin-top: 20px;
}

.module-card-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.module-card-grid.compact {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

#quadrature .module-card-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

#cdr .module-card-grid {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

#cdr .module-entry-card {
  min-height: 166px;
  padding: 16px;
}

#cdr .module-entry-card strong {
  font-size: 17px;
}

#cdr .module-entry-card p {
  font-size: 13px;
}

.module-entry-card {
  display: grid;
  align-content: start;
  min-height: 178px;
  padding: 18px;
  border: 1px solid #d7e5f2;
  border-radius: 20px;
  color: #132238;
  background: #ffffff;
  text-decoration: none;
  box-shadow: 0 14px 34px rgba(30, 74, 130, 0.08);
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.module-entry-card:hover {
  transform: translateY(-3px);
  border-color: #7fc7f2;
  box-shadow: 0 20px 44px rgba(27, 103, 174, 0.14);
}

.module-entry-card span {
  width: fit-content;
  margin-bottom: 18px;
  padding: 6px 10px;
  border-radius: 999px;
  color: #0b5faf;
  background: #edf8ff;
  font-size: 12px;
  font-weight: 900;
}

.module-entry-card strong {
  margin-bottom: 8px;
  font-size: 18px;
  line-height: 1.3;
}

.module-entry-card p {
  margin: 0;
  color: #536176;
  font-size: 14px;
  line-height: 1.58;
}

.module-entry-card em {
  display: none;
}

.module-entry-card strong::after {
  content: " ->";
  color: #075fad;
}

details {
  border: 1px solid var(--line);
  border-radius: 20px;
  background: #fbfdff;
  overflow: hidden;
}

summary {
  padding: 18px 20px;
  cursor: pointer;
  font-weight: 900;
}

.detail-body {
  padding: 0 20px 20px;
  color: #3d4b5f;
  line-height: 1.76;
}

.detail-body ul {
  margin-bottom: 0;
}

.module-detail-link {
  display: inline-flex;
  margin-top: 16px;
  padding: 10px 13px;
  border: 1px solid #bee7ff;
  border-radius: 999px;
  color: #174a87;
  background: #e5f7ff;
  font-size: 13px;
  font-weight: 900;
  text-decoration: none;
}

.module-detail-link:hover {
  color: #ffffff;
  background: var(--blue);
  border-color: var(--blue);
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.skill-card {
  padding: 24px;
  border-radius: var(--radius);
  background: #ffffff;
  border: 1px solid var(--line);
}

.skill-card h2 {
  margin-top: 0;
}

.skill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.skill-roadmap {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.skill-stage {
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 18px 48px rgba(31, 61, 92, 0.07);
}

.skill-stage:has(.skill-proof-strip) {
  border-color: rgba(13, 99, 200, 0.24);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(243, 250, 255, 0.9)),
    radial-gradient(circle at 100% 0%, rgba(103, 215, 231, 0.16), transparent 44%);
}

.skill-stage > span {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 999px;
  color: #0b4f9f;
  background: #e8f6ff;
  font-weight: 900;
  font-size: 13px;
}

.skill-stage h2 {
  margin: 16px 0 8px;
  font-size: 22px;
}

.skill-stage p {
  min-height: 118px;
  margin: 0 0 14px;
  color: #3d4b5f;
  line-height: 1.68;
}

.skill-proof-strip {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
  margin: -2px 0 16px;
  padding: 10px;
  border: 1px solid #cfe3f5;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.72);
}

.skill-proof-strip span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  min-height: 28px;
  padding: 0 9px;
  border-radius: 999px;
  color: #073066;
  background: #e7f5ff;
  border: 1px solid #bdddf4;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.skill-proof-strip.instrument span {
  color: #053f4c;
  background: #e5fbff;
  border-color: #ade9f2;
}

.skill-chain {
  position: relative;
  display: grid;
  gap: 12px;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.skill-chain::before {
  content: "";
  position: absolute;
  top: 12px;
  bottom: 12px;
  left: 7px;
  width: 1px;
  background: #cfe0ef;
}

.skill-chain li {
  position: relative;
  display: grid;
  gap: 4px;
  padding-left: 24px;
}

.skill-chain li::before {
  content: "";
  position: absolute;
  top: 6px;
  left: 2px;
  width: 11px;
  height: 11px;
  border-radius: 999px;
  background: #ffffff;
  border: 3px solid #1598d3;
  box-shadow: 0 0 0 4px #eff8ff;
}

.skill-chain strong {
  color: #111827;
  font-size: 14px;
  line-height: 1.35;
}

.skill-chain span {
  color: #536175;
  font-size: 13px;
  line-height: 1.5;
}

.ability-ladder {
  display: grid;
  gap: 14px;
}

.ability-ladder article {
  display: grid;
  grid-template-columns: 150px 180px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
  padding: 20px 22px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.86);
}

.ability-ladder span {
  color: var(--blue);
  font-weight: 900;
}

.ability-ladder h3 {
  margin: 0;
  font-size: 21px;
}

.ability-ladder p {
  margin: 0;
  color: #3d4b5f;
  line-height: 1.72;
}

.module-layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
  margin-top: 28px;
}

.module-side {
  position: sticky;
  top: 104px;
  display: grid;
  gap: 14px;
}

.module-toc {
  display: grid;
  gap: 10px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.84);
  box-shadow: 0 18px 48px rgba(30, 74, 130, 0.08);
}

.module-toc h2 {
  margin: 4px 6px 8px;
  font-size: 17px;
}

.toc-group {
  display: grid;
  gap: 6px;
}

.module-toc a {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 9px;
  align-items: center;
  padding: 11px 12px;
  border-radius: 14px;
  color: #344154;
  font-size: 13px;
  font-weight: 900;
  line-height: 1.35;
  text-decoration: none;
}

.module-toc a.active {
  color: #ffffff;
  background: #070b12;
}

.module-toc a span {
  display: grid;
  min-width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 999px;
  color: #0b5faf;
  background: #edf8ff;
  font-size: 11px;
}

.module-toc a.active span {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.18);
}

.module-toc a strong {
  min-width: 0;
}

.toc-children {
  display: grid;
  gap: 4px;
  margin-left: 18px;
  padding-left: 12px;
  border-left: 1px solid #d7e5f2;
}

.module-toc .toc-child {
  grid-template-columns: 54px minmax(0, 1fr);
  padding: 8px 10px;
  color: #536176;
  font-size: 12px;
  background: #f7fbff;
}

.module-content {
  display: grid;
  gap: 18px;
}

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

.module-gallery figure {
  margin: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: #ffffff;
  box-shadow: 0 18px 44px rgba(31, 61, 92, 0.08);
}

.module-gallery.count-1 {
  grid-template-columns: 1fr;
}

.module-gallery.count-1 figure {
  max-width: 860px;
}

.module-gallery.count-3 figure:first-child {
  grid-column: span 2;
}

.module-gallery img,
.module-gallery video {
  display: block;
  width: 100%;
  max-height: 560px;
  object-fit: contain;
  border-radius: 14px;
  border: 1px solid #d7e5f2;
  background: #f8fbff;
}

.module-gallery video {
  aspect-ratio: 16 / 9;
  background: #050b12;
}

.module-gallery-link {
  display: block;
  border-radius: 14px;
  text-decoration: none;
}

.module-gallery.linked-gallery figure {
  transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.module-gallery.linked-gallery figure:hover {
  transform: translateY(-3px);
  border-color: #7fc7f2;
  box-shadow: 0 22px 50px rgba(27, 103, 174, 0.14);
}

.module-gallery.linked-gallery figcaption {
  color: #075fad;
}

.module-gallery.linked-gallery figcaption::after {
  content: " ->";
}

.module-gallery.count-1 img,
.module-gallery.count-1 video {
  max-height: 720px;
}

.module-gallery.module-cdr-test {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: stretch;
}

.module-gallery.module-cdr-test figure {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  min-height: 310px;
}

.module-gallery.module-cdr-test img {
  width: 100%;
  height: 260px;
  max-height: none;
  object-fit: contain;
  object-position: center;
}

.module-gallery.module-cdr-andor {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding-bottom: 8px;
  scroll-snap-type: x proximity;
}

.module-gallery.module-cdr-andor figure {
  flex: 0 0 min(520px, 82vw);
  scroll-snap-align: start;
}

.module-gallery.module-cdr-andor img {
  height: 360px;
  max-height: none;
  object-fit: contain;
}

.module-gallery.module-cdr-loop figure:nth-child(3) {
  grid-column: span 2;
}

.module-gallery.module-cdr-loop figure:nth-child(4) {
  grid-column: span 2;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
}

.module-gallery.module-cdr-loop figure:nth-child(4) img {
  height: 108px;
  max-height: none;
  object-fit: contain;
  background: #f4f9ff;
}

.module-gallery.module-cdr-loop figure:nth-child(4) figcaption {
  margin-top: 0;
  white-space: nowrap;
}

.module-gallery figcaption {
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
}

.module-copy {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.9);
}

.module-copy h2 {
  margin: 0 0 12px;
  font-size: 24px;
}

.module-copy p,
.module-copy li {
  color: #3d4b5f;
  font-size: 16px;
  line-height: 1.78;
}

.module-copy p:last-child,
.module-copy ul {
  margin-bottom: 0;
}

.module-point-list {
  display: grid;
  gap: 10px;
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
}

.module-point-list li {
  position: relative;
  padding: 12px 14px 12px 38px;
  border: 1px solid #d7e5f2;
  border-radius: 16px;
  background: #f8fbff;
}

.module-point-list li::before {
  content: "";
  position: absolute;
  left: 16px;
  top: 20px;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #0d63c8;
  box-shadow: 0 0 0 5px rgba(13, 99, 200, 0.1);
}

.module-children[hidden] {
  display: none;
}

.module-child-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.module-child-card {
  display: grid;
  gap: 8px;
  padding: 16px;
  border: 1px solid #d7e5f2;
  border-radius: 18px;
  color: #132238;
  background: #ffffff;
  text-decoration: none;
}

.module-child-card span {
  color: var(--blue);
  font-weight: 900;
  font-size: 12px;
}

.module-child-card strong {
  font-size: 17px;
}

.module-child-card p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}

.workbench-launch {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 20px;
  border: 1px solid #d7e5f2;
  border-radius: 22px;
  background:
    linear-gradient(135deg, #ffffff, #e9fbff),
    radial-gradient(circle at 100% 0%, rgba(103, 215, 231, 0.18), transparent 36%);
  box-shadow: 0 18px 48px rgba(30, 74, 130, 0.08);
}

.workbench-launch-copy {
  display: grid;
  gap: 8px;
}

.workbench-launch-copy span {
  width: fit-content;
  padding: 6px 10px;
  border-radius: 999px;
  color: #0b5faf;
  background: #edf8ff;
  font-size: 12px;
  font-weight: 900;
}

.workbench-launch-copy strong {
  color: #111827;
  font-size: 22px;
  line-height: 1.25;
}

.workbench-launch-copy p {
  max-width: 720px;
  margin: 0;
  color: #3d4b5f;
  line-height: 1.68;
}

.workbench-command-list {
  display: grid;
  gap: 8px;
  margin-top: 6px;
}

.workbench-command-list code {
  display: block;
  width: fit-content;
  max-width: 100%;
  padding: 9px 12px;
  border: 1px solid #d7e5f2;
  border-radius: 14px;
  color: #073066;
  background: rgba(255, 255, 255, 0.86);
  font-family: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
  font-size: 13px;
  line-height: 1.55;
  white-space: normal;
  overflow-wrap: anywhere;
}

.workbench-action-stack {
  display: grid;
  gap: 10px;
  min-width: 160px;
}

.workbench-frame-shell {
  overflow: hidden;
  margin-top: 18px;
  border: 1px solid #d7e5f2;
  border-radius: 24px;
  background: #ffffff;
  box-shadow: 0 18px 48px rgba(30, 74, 130, 0.08);
}

.workbench-frame {
  display: block;
  width: 100%;
  height: min(940px, 82vh);
  min-height: 680px;
  border: 0;
  background: #f8fbff;
}

.workbench-module-page .page-title {
  padding-bottom: 12px;
}

.workbench-module-page .module-layout {
  display: block;
  margin-top: 16px;
}

.workbench-module-page .module-side {
  display: none;
}

.workbench-module-page .module-content {
  display: block;
}

.module-extra.workbench-inline {
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.workbench-inline-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  margin-bottom: 14px;
  padding: 14px;
  border: 1px solid #d7e5f2;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 16px 42px rgba(30, 74, 130, 0.08);
}

.workbench-inline-toolbar span {
  display: block;
  margin-bottom: 4px;
  color: #0b5faf;
  font-size: 12px;
  font-weight: 900;
}

.workbench-inline-toolbar strong {
  display: block;
  color: #111827;
  font-size: 20px;
  line-height: 1.25;
}

.workbench-inline-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: flex-end;
}

.workbench-command-drawer {
  overflow: visible;
  border-radius: 999px;
  background: #ffffff;
}

.workbench-command-drawer summary {
  min-height: 44px;
  padding: 12px 18px;
  border-radius: 999px;
  color: #073066;
  background: linear-gradient(135deg, #e7fbff, #e9f1ff);
  border: 1px solid #cde5f6;
  font-size: 14px;
}

.workbench-command-drawer[open] {
  width: min(520px, 100%);
  border-radius: 18px;
}

.workbench-command-drawer[open] summary {
  border-radius: 18px 18px 0 0;
}

.workbench-command-drawer[open] .workbench-command-list {
  padding: 12px;
  border: 1px solid #cde5f6;
  border-top: 0;
  border-radius: 0 0 18px 18px;
  background: #ffffff;
}

.workbench-inline .workbench-frame-shell {
  margin-top: 0;
  border-radius: 18px;
}

.workbench-inline .workbench-frame {
  height: calc(100vh - 224px);
  min-height: 760px;
}

.site-footer {
  margin-top: 72px;
  padding: 26px 0 0;
  border-top: 1px solid var(--line);
  color: var(--muted);
  display: flex;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(15, 23, 42, 0.3);
}

.modal.open {
  display: flex;
}

.modal-card {
  width: min(720px, 100%);
  border-radius: 30px;
  background: #ffffff;
  padding: 28px;
  box-shadow: 0 40px 100px rgba(15, 23, 42, 0.25);
}

.modal-card h2 {
  margin-top: 0;
}

.proof-modal-card {
  width: min(780px, 100%);
}

.proof-viewer {
  min-height: 220px;
  display: grid;
  place-items: center;
  padding: 28px;
  border: 1px dashed #bdd9ee;
  border-radius: 20px;
  background: #f6fbff;
  text-align: center;
}

.proof-viewer p {
  max-width: 460px;
  margin: 10px auto 0;
  color: var(--muted);
  line-height: 1.7;
}

.proof-viewer img {
  max-width: 100%;
  max-height: 70vh;
  border-radius: 14px;
  border: 1px solid var(--line);
}

.match-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.match-grid div {
  padding: 14px;
  border-radius: 16px;
  background: #f5f9ff;
  border: 1px solid var(--line);
}

@media (max-width: 960px) {
  .nav {
    flex-wrap: wrap;
  }

  .brand {
    min-width: auto;
  }

  .nav-links {
    order: 3;
    width: 100%;
    justify-content: flex-start;
    overflow-x: auto;
  }

  .hero,
  .projects-workspace,
  .project-summary,
  .module-layout,
  .education-card-grid,
  .skill-roadmap,
  .two-col {
    grid-template-columns: 1fr;
  }

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

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

  .architecture-diagram,
  .module-gallery,
  .module-child-grid,
  .project-title-row,
  .workbench-launch,
  .workbench-inline-toolbar,
  .ability-ladder article {
    grid-template-columns: 1fr;
  }

  .module-side {
    position: static;
  }

  .module-gallery.count-3 figure:first-child {
    grid-column: auto;
  }

  .research-facts {
    grid-template-columns: repeat(2, 1fr);
  }

  .project-side-nav {
    position: static;
    display: flex;
    overflow-x: auto;
  }

  .project-side-nav a {
    white-space: nowrap;
  }

  .hero {
    min-height: auto;
  }

  .profile-card {
    max-width: 360px;
  }

  .project-jump-grid,
  .experience-strip,
  .module-card-grid,
  #quadrature .module-card-grid,
  #cdr .module-card-grid,
  .skills-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .page {
    padding: 26px 16px 56px;
  }

  .nav {
    padding: 14px 16px;
  }

  .nav-actions {
    width: 100%;
  }

  .nav-actions .button {
    flex: 1;
  }

  .hero h1 {
    font-size: 64px;
  }

  .hero h2 {
    font-size: 32px;
    line-height: 1.15;
  }

  .tag {
    white-space: normal;
  }

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

  .project-jump-grid,
  .experience-strip,
  .module-card-grid,
  #quadrature .module-card-grid,
  #cdr .module-card-grid,
  .skills-grid,
  .hero-facts,
  .hero-contact-strip,
  .research-facts,
  .match-grid {
    grid-template-columns: 1fr;
  }

  .project-card {
    grid-template-columns: 1fr;
  }

  .job-match {
    grid-template-columns: 1fr;
  }

  .workbench-action-stack {
    min-width: 0;
  }

  .workbench-inline-actions {
    justify-content: stretch;
  }

  .workbench-inline-actions .button,
  .workbench-command-drawer {
    width: 100%;
  }

  .workbench-frame {
    height: 760px;
    min-height: 620px;
  }
}
