:root {
  --scroll-offset: 72px;
  --navy: #081225;
  --navy-soft: #0d1d38;
  --ink: #0b1830;
  --muted: #5c6980;
  --line: #dfe6ee;
  --paper: #ffffff;
  --paper-soft: #f5f8fb;
  --cyan: #11c5dd;
  --cyan-dark: #087d96;
  --violet: #6d70e8;
  /* Static fallbacks first, then fluid values for modern engines */
  --page-inline: 24px;
  --page-inline: clamp(20px, 5vw, 104px);
  --section-block: 64px;
  --section-block: clamp(56px, 7vw, 92px);
  --title-hero: 40px;
  --title-hero: clamp(34px, 3.35vw, 50px);
  --title-section: 36px;
  --title-section: clamp(28px, 3vw, 42px);
  --safe-top: 0px;
  --safe-right: 0px;
  --safe-bottom: 0px;
  --safe-left: 0px;
}

@supports (padding: constant(safe-area-inset-top)) {
  :root {
    --safe-top: constant(safe-area-inset-top);
    --safe-right: constant(safe-area-inset-right);
    --safe-bottom: constant(safe-area-inset-bottom);
    --safe-left: constant(safe-area-inset-left);
  }
}

@supports (padding: env(safe-area-inset-top)) {
  :root {
    --safe-top: env(safe-area-inset-top, 0px);
    --safe-right: env(safe-area-inset-right, 0px);
    --safe-bottom: env(safe-area-inset-bottom, 0px);
    --safe-left: env(safe-area-inset-left, 0px);
  }
}

* {
  box-sizing: border-box;
}

html {
  color-scheme: light;
  scroll-padding-top: calc(var(--scroll-offset) + var(--safe-top));
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

@supports (scroll-behavior: smooth) {
  html {
    scroll-behavior: smooth;
  }
}

body {
  margin: 0;
  overflow-x: hidden;
  background: var(--paper);
  color: var(--ink);
  font-family:
    Inter,
    "SF Pro Display",
    "PingFang SC",
    "Hiragino Sans GB",
    "Microsoft YaHei",
    "Noto Sans SC",
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Roboto,
    Helvetica,
    Arial,
    sans-serif;
  line-height: 1.65;
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: rgba(17, 197, 221, 0.18);
}

img,
svg,
video {
  max-width: 100%;
}

img {
  height: auto;
  border-style: none;
  vertical-align: middle;
}

a:focus-visible,
button:focus-visible,
.button:focus-visible,
.lang-toggle:focus-visible,
.nav-menu-toggle:focus-visible,
.contact-link:focus-visible,
.project-link:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
}

a:focus:not(:focus-visible),
button:focus:not(:focus-visible),
.button:focus:not(:focus-visible),
.lang-toggle:focus:not(:focus-visible),
.nav-menu-toggle:focus:not(:focus-visible),
.contact-link:focus:not(:focus-visible),
.project-link:focus:not(:focus-visible) {
  outline: none;
}

a {
  color: inherit;
}

.site-shell {
  min-height: 100vh;
  overflow: hidden;
  background: var(--paper);
}

.site-nav {
  position: fixed;
  z-index: 50;
  top: 0;
  right: 0;
  left: 0;
  display: flex;
  gap: clamp(16px, 2.2vw, 36px);
  align-items: center;
  justify-content: space-between;
  min-height: calc(72px + var(--safe-top));
  padding-top: var(--safe-top);
  padding-right: max(var(--safe-right), clamp(18px, 6vw, 104px));
  padding-bottom: 0;
  padding-left: max(var(--safe-left), clamp(18px, 6vw, 104px));
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  color: #fff;
  background: rgba(8, 18, 37, 0.62);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
  transition:
    min-height 0.25s ease,
    background 0.25s ease,
    border-color 0.25s ease,
    box-shadow 0.25s ease;
}

.site-nav.scrolled {
  min-height: calc(64px + var(--safe-top));
  border-bottom-color: rgba(255, 255, 255, 0.08);
  background: rgba(8, 18, 37, 0.92);
  box-shadow: 0 1px 0 rgba(2, 8, 20, 0.14);
}

.brand {
  display: inline-flex;
  align-items: center;
  color: #fff;
  font-size: 15px;
  font-weight: 750;
  text-decoration: none;
}

.site-nav-links {
  display: flex;
  margin-left: auto;
  align-items: center;
  gap: clamp(12px, 1.7vw, 26px);
  color: rgba(255, 255, 255, 0.65);
  font-size: 13px;
}

.nav-menu-heading {
  display: none;
}

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

.site-nav-links a {
  text-decoration: none;
  transition: color 0.2s;
}

.site-nav-links a:hover {
  color: #fff;
}

.site-nav-links > a[aria-current="location"] {
  color: #fff;
}

@media (min-width: 901px) {
  .site-nav-links > a {
    position: relative;
    padding: 8px 0;
  }

  .site-nav-links > a::after {
    position: absolute;
    right: 0;
    bottom: 3px;
    left: 0;
    height: 2px;
    background: var(--cyan);
    content: "";
    transform: scaleX(0);
    transform-origin: center;
    transition: transform 0.2s ease;
  }

  .site-nav-links > a[aria-current="location"]::after {
    transform: scaleX(1);
  }
}

.nav-menu-toggle {
  display: none;
  width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 6px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: #fff;
  cursor: pointer;
}

.nav-menu-toggle span {
  width: 18px;
  height: 1px;
  background: currentColor;
  transition:
    transform 0.2s ease,
    opacity 0.2s ease;
}

.site-nav.menu-open .nav-menu-toggle span:first-child {
  transform: translateY(7px) rotate(45deg);
}

.site-nav.menu-open .nav-menu-toggle span:nth-child(2) {
  opacity: 0;
}

.site-nav.menu-open .nav-menu-toggle span:last-child {
  transform: translateY(-7px) rotate(-45deg);
}

.lang-toggle {
  min-width: 48px;
  min-height: 34px;
  padding: 6px 9px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  color: #fff;
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}

.hero {
  position: relative;
  display: grid;
  min-height: 720px;
  min-height: max(680px, 100svh);
  min-height: max(680px, 100dvh);
  grid-template-columns: minmax(0, 1.08fr) minmax(240px, 0.55fr);
  gap: 36px;
  gap: clamp(28px, 4vw, 72px);
  align-items: center;
  padding: calc(104px + var(--safe-top)) max(var(--page-inline), var(--safe-right))
    48px max(var(--page-inline), var(--safe-left));
  overflow: hidden;
  background-color: var(--navy);
  background-image:
    linear-gradient(rgba(85, 119, 162, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(85, 119, 162, 0.08) 1px, transparent 1px);
  background-size: 56px 56px;
  color: #fff;
}

.hero::after {
  position: absolute;
  right: -15%;
  bottom: -60%;
  width: 70%;
  height: 100%;
  border: 1px solid rgba(17, 197, 221, 0.12);
  border-radius: 50%;
  content: "";
  pointer-events: none;
}

.hero-copy,
.hero-portrait {
  position: relative;
  z-index: 1;
}

.hero-copy {
  min-width: 0;
  max-width: 760px;
}

.eyebrow {
  display: flex;
  gap: 10px;
  align-items: center;
  margin: 0 0 18px;
  color: var(--cyan);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.eyebrow span {
  flex: 0 0 30px;
  width: 30px;
  height: 1px;
  background: currentColor;
}

.eyebrow b {
  line-height: 1.5;
}

.hero-name {
  display: flex;
  gap: 11px;
  align-items: baseline;
  margin: 0 0 14px;
  color: rgba(255, 255, 255, 0.54);
  font-size: 15px;
  letter-spacing: 0.03em;
}

.hero-name strong {
  color: #fff;
  font-size: 19px;
}

.hero h1,
.section h2,
.contact-section h2 {
  margin: 0;
  font-weight: 720;
  letter-spacing: -0.035em;
  line-height: 1.16;
}

.hero h1 {
  max-width: 720px;
  font-size: var(--title-hero);
}

.hero-title-desktop,
.hero-title-mobile {
  display: block;
}

.hero-title-mobile {
  display: none;
}

.hero h1 i {
  color: var(--cyan);
  font-style: normal;
}

.section h2 strong,
.contact-section h2 strong {
  color: var(--cyan-dark);
  font-style: normal;
}

.work-section h2 strong {
  color: var(--cyan);
}

.work-section h2 .hxva-value-expansion {
  display: block;
  max-width: 760px;
  margin: 10px 0 8px;
  color: rgba(225, 235, 246, 0.76);
  font-size: clamp(11px, 0.9vw, 14px);
  font-weight: 650;
  letter-spacing: 0.025em;
  line-height: 1.55;
  text-wrap: balance;
}

.hero-summary {
  max-width: 650px;
  margin: 18px 0 0;
  color: rgba(229, 239, 248, 0.7);
  font-size: clamp(15px, 1.18vw, 17px);
  line-height: 1.68;
}

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

.button {
  display: inline-flex;
  min-height: 48px;
  gap: 16px;
  align-items: center;
  justify-content: center;
  padding: 0 20px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  touch-action: manipulation;
  transition:
    transform 0.2s,
    border-color 0.2s,
    background 0.2s;
}

.button:hover,
.featured-project:hover {
  transform: none;
}

@media (hover: hover) and (pointer: fine) {
  .button:hover,
  .featured-project:hover,
  .capability-grid article:hover {
    transform: translateY(-3px);
  }
}

.button-primary {
  border: 1px solid var(--cyan);
  background: var(--cyan);
  color: var(--navy);
}

.button-primary b {
  font-size: 18px;
}

.button-secondary {
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff;
  background: rgba(255, 255, 255, 0.035);
}

.button-secondary:hover {
  border-color: rgba(255, 255, 255, 0.38);
  background: rgba(255, 255, 255, 0.07);
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 15px;
}

.hero-tags span {
  padding: 7px 10px;
  border: 1px solid rgba(17, 197, 221, 0.2);
  border-radius: 999px;
  color: rgba(214, 246, 250, 0.74);
  background: rgba(17, 197, 221, 0.06);
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.04em;
}

.hero-portrait {
  width: clamp(244px, 22vw, 320px);
  margin: 0;
  justify-self: end;
}

.portrait-frame {
  position: relative;
  overflow: hidden;
  height: 0;
  padding-bottom: 125%;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 24px 24px 8px 8px;
  background: #0e65a2;
  box-shadow: 0 35px 80px rgba(0, 0, 0, 0.38);
}

@supports (aspect-ratio: 4 / 5) {
  .portrait-frame {
    height: auto;
    padding-bottom: 0;
    aspect-ratio: 4 / 5;
  }
}

.portrait-frame::before {
  position: absolute;
  z-index: 2;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  background:
    linear-gradient(180deg, transparent 54%, rgba(8, 18, 37, 0.32) 78%, rgba(8, 18, 37, 0.92) 100%),
    linear-gradient(90deg, rgba(8, 18, 37, 0.16), transparent 30%, transparent 70%, rgba(8, 18, 37, 0.12));
  content: "";
  pointer-events: none;
}

.portrait-frame img {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: 68% 32%;
  -webkit-filter: saturate(0.82) contrast(1.04);
  filter: saturate(0.82) contrast(1.04);
  -webkit-transform: scale(1.16);
  transform: scale(1.16);
}

.portrait-grid {
  position: absolute;
  z-index: 3;
  right: 22px;
  bottom: 22px;
  width: 72px;
  height: 72px;
  border-right: 1px solid rgba(17, 197, 221, 0.55);
  border-bottom: 1px solid rgba(17, 197, 221, 0.55);
}

.hero-portrait figcaption {
  display: grid;
  grid-template-columns: 1fr;
  gap: 6px;
  padding: 14px 3px 0;
}

.hero-portrait figcaption span {
  color: rgba(255, 255, 255, 0.38);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-portrait figcaption strong {
  color: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  font-weight: 550;
  line-height: 1.65;
}

.proof-strip {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin: -1px 0 0;
  border-top: 1px solid rgba(8, 18, 37, 0.06);
  border-bottom: 1px solid var(--line);
  background: var(--paper-soft);
}

.proof-strip div {
  position: relative;
  display: grid;
  min-height: 104px;
  min-width: 0;
  grid-template-columns: auto minmax(0, 1fr);
  gap: clamp(14px, 1.8vw, 24px);
  align-items: center;
  padding: 22px clamp(24px, 4vw, 60px);
  border-right: 1px solid var(--line);
}

.proof-strip div::before {
  position: absolute;
  top: -1px;
  left: clamp(24px, 4vw, 60px);
  width: 34px;
  height: 2px;
  background: var(--cyan-dark);
  content: "";
}

.proof-strip div:last-child {
  border-right: 0;
}

.proof-strip strong {
  display: block;
  margin: 0;
  color: var(--navy);
  font-size: clamp(28px, 2.8vw, 40px);
  font-weight: 780;
  letter-spacing: -0.055em;
  line-height: 1;
}

.proof-strip span {
  min-width: 0;
  max-width: 190px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 560;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.section,
.work-section,
.contact-section {
  scroll-margin-top: calc(var(--scroll-offset) + var(--safe-top));
}

.section {
  display: grid;
  grid-template-columns: minmax(120px, 0.18fr) minmax(0, 1fr);
  gap: clamp(24px, 4vw, 64px);
  padding: var(--section-block) max(var(--page-inline), var(--safe-right))
    var(--section-block) max(var(--page-inline), var(--safe-left));
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}

.section-label {
  padding-top: 7px;
  color: var(--cyan-dark);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.section h2,
.contact-section h2 {
  max-width: 820px;
  color: var(--ink);
  font-size: var(--title-section);
}

.profile-grid,
.focus-header,
.work-intro,
.experience-heading {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(22px, 3.5vw, 46px);
}

.profile-grid {
  max-width: 960px;
  margin-top: 28px;
}

.profile-grid p,
.focus-header > p,
.work-intro > p,
.experience-heading > p,
.contact-copy p {
  margin: 0;
  color: var(--muted);
  font-size: clamp(15px, 1.18vw, 16px);
  line-height: 1.82;
}

.focus-section {
  background: var(--paper-soft);
}

.focus-header,
.work-intro,
.experience-heading {
  align-items: start;
}

.capability-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 40px;
  border-top: 1px solid #ccd7e3;
  border-left: 1px solid #ccd7e3;
}

.capability-grid article {
  min-height: 184px;
  padding: 24px;
  border-right: 1px solid #ccd7e3;
  border-bottom: 1px solid #ccd7e3;
  background: rgba(255, 255, 255, 0.58);
  transition:
    background 0.2s,
    transform 0.2s;
}

.capability-grid article:hover {
  z-index: 1;
  background: #fff;
}

.capability-grid span {
  color: var(--cyan-dark);
  font-size: 12px;
  font-weight: 750;
}

.capability-grid h3 {
  margin: 30px 0 10px;
  color: var(--ink);
  font-size: clamp(20px, 1.75vw, 23px);
  letter-spacing: -0.03em;
}

.capability-grid p {
  max-width: 390px;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.8;
}

.skill-atlas {
  margin-top: 44px;
  padding-top: 22px;
  border-top: 1px solid #ccd7e3;
}

.skill-atlas-title {
  margin: 0 0 20px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

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

.skill-columns article {
  padding: 23px;
  border: 1px solid #d5dee8;
  border-radius: 15px;
  background: #fff;
}

.skill-columns h3 {
  margin: 0 0 20px;
  color: var(--ink);
  font-size: 18px;
  letter-spacing: -0.03em;
}

.skill-columns ul {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.skill-columns li {
  position: relative;
  padding-left: 15px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.skill-columns li::before {
  position: absolute;
  top: 0.75em;
  left: 0;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--cyan);
  content: "";
}

.experience-section {
  background: #fff;
}

.experience-heading {
  margin-bottom: 40px;
}

.experience-layout {
  display: block;
}

.timeline {
  border-top: 1px solid var(--line);
}

.timeline-item {
  position: relative;
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 36px;
  padding: 26px 0 28px;
  border-bottom: 1px solid var(--line);
}

.timeline-meta {
  position: relative;
  padding-right: 25px;
  color: #69778d;
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 0.08em;
}

.timeline-meta i {
  position: absolute;
  top: 4px;
  right: 0;
  width: 9px;
  height: 9px;
  border: 2px solid #aab8c8;
  border-radius: 50%;
  background: #fff;
}

.timeline-item.current .timeline-meta {
  color: var(--cyan-dark);
}

.timeline-item.current .timeline-meta i {
  border-color: var(--cyan);
  background: var(--cyan);
  box-shadow: 0 0 0 5px rgba(17, 197, 221, 0.12);
}

.timeline-body {
  padding-left: 3px;
}

.company-line {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  align-items: baseline;
  margin: 0 0 10px;
}

.company-line strong,
.company-line a {
  color: var(--cyan-dark);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-decoration: none;
  text-transform: uppercase;
}

.company-line span {
  color: #7b8798;
  font-size: 12px;
}

.timeline-body h3 {
  margin: 0 0 13px;
  color: var(--ink);
  font-size: 25px;
  letter-spacing: -0.035em;
}

.timeline-body > p:last-of-type {
  max-width: 760px;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.85;
}

.timeline-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 18px;
}

.timeline-tags span {
  padding: 5px 9px;
  border-radius: 5px;
  color: #496074;
  background: #edf4f7;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.education-item {
  padding-bottom: 30px;
}

.work-section {
  padding-top: var(--section-block);
  padding-bottom: var(--section-block);
  padding-right: max(var(--page-inline), var(--safe-right));
  padding-left: max(var(--page-inline), var(--safe-left));
  color: #fff;
  background-color: var(--navy);
  background-image:
    linear-gradient(rgba(85, 119, 162, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(85, 119, 162, 0.07) 1px, transparent 1px);
  background-size: 56px 56px;
}

.work-section .section-label {
  color: var(--cyan);
}

.work-section h2 {
  color: #fff;
  font-size: clamp(26px, 3vw, 38px);
}

.work-intro {
  align-items: start;
  margin-bottom: 22px;
}

.work-intro > p {
  color: rgba(225, 235, 246, 0.62);
}

.featured-project {
  display: block;
  padding: clamp(24px, 2.5vw, 32px) clamp(24px, 3vw, 36px);
  border: 1px solid rgba(17, 197, 221, 0.38);
  border-radius: 20px;
  background: linear-gradient(125deg, #0d203e, #10314c 62%, #0b4150);
  box-shadow: 0 28px 70px rgba(0, 0, 0, 0.28);
  color: #fff;
  text-decoration: none;
  transition:
    transform 0.25s,
    border-color 0.25s,
    box-shadow 0.25s;
}

.featured-project:hover {
  border-color: var(--cyan);
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.34);
}

.project-topline {
  display: flex;
  justify-content: flex-start;
  gap: 20px;
  color: rgba(139, 239, 250, 0.78);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
}

.project-summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: clamp(24px, 4vw, 76px);
  align-items: center;
  padding: 38px 0 31px;
}

.project-brand {
  width: clamp(142px, 17vw, 208px);
  margin-bottom: 20px;
}

.project-brand img {
  display: block;
  width: 100%;
  height: auto;
}

.project-copy h3 {
  max-width: 560px;
  margin: 0;
  font-size: clamp(22px, 2.4vw, 34px);
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.project-description {
  max-width: 570px;
  margin: 17px 0 0;
  color: rgba(235, 242, 250, 0.68);
  font-size: 14px;
  line-height: 1.72;
}

.project-capabilities {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: 1px solid rgba(139, 239, 250, 0.16);
  border-left: 1px solid rgba(139, 239, 250, 0.16);
}

.project-capabilities span {
  display: flex;
  min-height: 66px;
  gap: 10px;
  align-items: center;
  padding: 13px 16px;
  border-right: 1px solid rgba(139, 239, 250, 0.16);
  border-bottom: 1px solid rgba(139, 239, 250, 0.16);
  color: rgba(236, 247, 252, 0.8);
  background: rgba(255, 255, 255, 0.025);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.4;
}

.project-capabilities span::before {
  width: 6px;
  height: 6px;
  flex: 0 0 6px;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 16px rgba(17, 197, 221, 0.56);
  content: "";
}

.project-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-top: 18px;
  border-top: 1px solid rgba(139, 239, 250, 0.16);
}

.project-footer > span {
  color: rgba(225, 235, 246, 0.52);
  font-size: 11px;
  letter-spacing: 0.04em;
}

.project-demo-note {
  max-width: 620px;
  letter-spacing: 0;
  line-height: 1.55;
  text-transform: none;
}

.project-actions {
  display: flex;
  flex: none;
  align-items: center;
  gap: 9px;
}

.project-link {
  display: inline-flex;
  min-width: 126px;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border: 1px solid rgba(139, 239, 250, 0.24);
  border-radius: 999px;
  color: rgba(236, 247, 252, 0.88);
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 0.045em;
  text-decoration: none;
  text-transform: uppercase;
  transition:
    border-color 0.2s,
    color 0.2s,
    background 0.2s;
}

.project-link span {
  color: inherit;
  font: inherit;
  letter-spacing: inherit;
}

.project-link-primary {
  border-color: var(--cyan);
  background: var(--cyan);
  color: var(--navy);
}

.project-link:hover {
  border-color: var(--cyan);
  color: #fff;
  background: rgba(17, 197, 221, 0.12);
}

.project-link-primary:hover {
  color: var(--navy);
  background: #66e8f6;
}

.contact-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(28px, 4vw, 48px);
  padding: var(--section-block) max(var(--page-inline), var(--safe-right))
    calc(var(--section-block) + var(--safe-bottom)) max(var(--page-inline), var(--safe-left));
  background: #eef7f9;
  color: var(--ink);
}

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

.contact-copy {
  align-self: start;
  width: min(100%, 640px);
  justify-self: end;
}

.contact-copy p {
  color: var(--muted);
}

.contact-links {
  display: grid;
  gap: 12px;
  margin-top: 27px;
}

.contact-link {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 16px 18px;
  border: 1px solid rgba(7, 93, 115, 0.16);
  border-radius: 15px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.48);
  text-decoration: none;
  transition:
    border-color 0.2s,
    background 0.2s;
}

.contact-link:hover {
  border-color: rgba(7, 93, 115, 0.38);
  background: rgba(255, 255, 255, 0.86);
}

.contact-icon {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 12px;
  color: #fff;
  background: var(--navy);
}

.contact-icon svg {
  width: 21px;
  height: 21px;
  fill: currentColor;
}

.email-link .contact-icon svg {
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.contact-link-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.contact-link-copy small {
  color: var(--cyan-dark);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.14em;
}

.contact-link-copy strong {
  overflow: hidden;
  color: var(--ink);
  font-size: clamp(15px, 1.45vw, 19px);
  font-weight: 750;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.contact-link-arrow {
  color: var(--cyan-dark);
  font-size: 20px;
  transition: transform 0.2s;
}

.contact-link:hover .contact-link-arrow {
  transform: translate(2px, -2px);
}

.site-footer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 16px;
  padding: clamp(18px, 2vw, 24px) max(var(--page-inline), var(--safe-right))
    calc(clamp(18px, 2vw, 24px) + var(--safe-bottom)) max(var(--page-inline), var(--safe-left));
  background: #061020;
  color: #fff;
}

.footer-safety {
  display: grid;
  max-width: 680px;
  gap: 4px;
}

.footer-safety strong {
  color: rgba(255, 255, 255, 0.82);
  font-size: 12px;
  font-weight: 760;
}

.footer-safety span {
  color: rgba(255, 255, 255, 0.56);
  font-size: 12px;
  line-height: 1.55;
}

.footer-policy-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}

.site-footer a {
  color: rgba(255, 255, 255, 0.65);
  font-size: 13px;
  text-decoration: none;
}

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

@media (max-width: 1100px) {
  :root {
    --page-inline: clamp(22px, 4vw, 52px);
    --section-block: clamp(52px, 6vw, 76px);
    --title-hero: clamp(32px, 3.8vw, 44px);
    --title-section: clamp(27px, 3vw, 38px);
  }

  .hero {
    grid-template-columns: minmax(0, 1.08fr) minmax(220px, 0.48fr);
    gap: clamp(24px, 3vw, 40px);
  }

  .hero-portrait {
    width: min(100%, 286px);
  }

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

  .project-summary {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .project-capabilities {
    max-width: 720px;
  }
}

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

  .capability-grid article {
    min-height: 190px;
    padding: 22px;
  }
}

@media (max-width: 900px) {
  :root {
    --scroll-offset: 60px;
    --page-inline: clamp(18px, 4.8vw, 32px);
    --section-block: clamp(48px, 7vw, 64px);
    --title-hero: clamp(29px, 5.4vw, 37px);
    --title-section: clamp(24px, 4.8vw, 32px);
  }

  .site-nav {
    min-height: calc(64px + var(--safe-top));
    padding-right: max(16px, var(--safe-right));
    padding-left: max(16px, var(--safe-left));
    background: rgba(8, 18, 37, 0.92);
  }

  .site-nav.scrolled {
    min-height: calc(60px + var(--safe-top));
  }

  .nav-actions {
    margin-left: auto;
    gap: 8px;
  }

  .lang-toggle {
    min-width: 56px;
    min-height: 40px;
    padding: 0 12px;
    border-color: rgba(17, 197, 221, 0.36);
    color: var(--cyan);
    background: rgba(17, 197, 221, 0.08);
    font-weight: 750;
  }

  .nav-menu-toggle {
    display: inline-flex;
    min-width: 44px;
    min-height: 44px;
  }

  .site-nav-links {
    position: fixed;
    top: calc(var(--safe-top) + 64px + 8px);
    right: max(10px, var(--safe-right));
    left: max(10px, var(--safe-left));
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-height: calc(100vh - 84px - var(--safe-top));
    max-height: calc(100dvh - 84px - var(--safe-top));
    gap: 4px;
    padding: 16px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 22px;
    background:
      linear-gradient(135deg, rgba(17, 197, 221, 0.08), transparent 42%),
      rgba(8, 18, 37, 0.98);
    box-shadow: 0 26px 80px rgba(0, 0, 0, 0.42);
    opacity: 0;
    transform: translateY(-12px) scale(0.985);
    transform-origin: top right;
    visibility: hidden;
    pointer-events: none;
    transition:
      opacity 0.2s ease,
      transform 0.2s ease,
      visibility 0.2s ease;
  }

  .site-nav.scrolled .site-nav-links {
    top: calc(var(--safe-top) + 60px + 8px);
  }

  .site-nav.menu-open .site-nav-links {
    opacity: 1;
    transform: translateY(0) scale(1);
    visibility: visible;
    pointer-events: auto;
  }

  .nav-menu-heading {
    display: block;
    grid-column: 1 / -1;
    margin: 0 0 8px;
    padding: 3px 12px 11px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.09);
    color: var(--cyan);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.16em;
    text-transform: uppercase;
  }

  .site-nav-links a {
    display: grid;
    min-height: 48px;
    grid-template-columns: 1fr auto;
    gap: 12px;
    align-items: center;
    padding: 0 14px;
    border-radius: 12px;
    color: rgba(255, 255, 255, 0.78);
    font-size: 14px;
    font-weight: 650;
  }

  .site-nav-links a::after {
    color: rgba(255, 255, 255, 0.34);
    content: "↘";
    font-size: 13px;
  }

  .site-nav-links a:hover {
    background: rgba(255, 255, 255, 0.06);
  }

  .site-nav-links a:focus-visible {
    background: rgba(255, 255, 255, 0.06);
  }

  .site-nav-links a[aria-current="location"] {
    background: rgba(17, 197, 221, 0.1);
  }

  .site-nav-links a[aria-current="location"]::after {
    color: var(--cyan);
    content: "●";
    font-size: 8px;
  }

  body.nav-menu-open {
    overflow: hidden;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr);
    gap: 30px;
    min-height: auto;
    align-items: center;
    padding-top: calc(96px + var(--safe-top));
    padding-bottom: max(52px, var(--safe-bottom));
    padding-right: max(var(--page-inline), var(--safe-right));
    padding-left: max(var(--page-inline), var(--safe-left));
  }

  .hero h1 {
    max-width: 700px;
    font-size: var(--title-hero);
  }

  .hero-portrait {
    width: min(44vw, 248px);
    margin: 0 auto;
    justify-self: center;
  }

  .section {
    grid-template-columns: 1fr;
    padding-top: var(--section-block);
    padding-bottom: var(--section-block);
    padding-right: max(var(--page-inline), var(--safe-right));
    padding-left: max(var(--page-inline), var(--safe-left));
  }

  .section-label {
    margin-bottom: 4px;
  }

  .profile-grid,
  .focus-header,
  .work-intro,
  .experience-heading,
  .contact-section {
    grid-template-columns: 1fr;
  }

  .capability-grid,
  .skill-columns {
    grid-template-columns: 1fr;
    margin-top: 28px;
  }

  .skill-atlas {
    margin-top: 32px;
  }

  .experience-heading {
    margin-bottom: 28px;
  }

  .timeline-item {
    grid-template-columns: 1fr;
    gap: 12px;
    padding: 22px 0 24px;
  }

  .timeline-meta {
    padding-right: 0;
    padding-left: 24px;
  }

  .timeline-meta i {
    right: auto;
    left: 0;
  }

  .work-section {
    padding-top: var(--section-block);
    padding-bottom: var(--section-block);
  }

  .project-summary {
    grid-template-columns: 1fr;
    gap: 22px;
    padding: 24px 0 20px;
  }

  .project-capabilities {
    max-width: none;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .contact-section {
    gap: 28px;
    padding-top: var(--section-block);
    padding-bottom: calc(var(--section-block) + var(--safe-bottom));
    padding-right: max(var(--page-inline), var(--safe-right));
    padding-left: max(var(--page-inline), var(--safe-left));
  }

}

/* Tablets stay visually balanced instead of becoming oversized phones. */
@media (min-width: 680px) and (max-width: 900px) {
  :root {
    --page-inline: clamp(24px, 4vw, 40px);
    --title-hero: clamp(29px, 4vw, 36px);
    --title-section: clamp(26px, 3.4vw, 34px);
  }

  .hero {
    grid-template-columns: minmax(0, 1fr) 220px;
    gap: clamp(22px, 3.5vw, 34px);
    padding-top: calc(96px + var(--safe-top));
    padding-bottom: 48px;
  }

  .hero-summary {
    font-size: 14px;
    line-height: 1.65;
  }

  .hero-actions {
    gap: 9px;
  }

  .button {
    min-height: 44px;
    padding: 0 16px;
    font-size: 12px;
  }

  .hero-portrait {
    width: min(31vw, 238px);
    margin: 0;
    justify-self: end;
  }

  .hero-portrait figcaption strong {
    font-size: 11px;
  }

  .profile-grid,
  .capability-grid,
  .skill-columns {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .contact-section {
    grid-template-columns: 1fr 1fr;
  }

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

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

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .button:hover,
  .featured-project:hover,
  .capability-grid article:hover {
    transform: none;
  }

  .hero-copy,
  .hero-portrait,
  .section,
  .contact-section,
  .featured-project {
    animation: none;
  }
}

@media (prefers-reduced-motion: no-preference) {
  .hero-copy,
  .hero-portrait {
    animation: section-rise 0.48s ease both;
  }

  .hero-portrait {
    animation-delay: 0.06s;
  }
}

@keyframes section-rise {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

@media (max-width: 600px) {
  :root {
    --title-hero: clamp(27px, 7.2vw, 32px);
    --title-section: clamp(23px, 6.2vw, 29px);
    --section-block: clamp(44px, 10vw, 56px);
    --page-inline: 16px;
  }

  .site-nav-links {
    right: max(8px, var(--safe-right));
    left: max(8px, var(--safe-left));
    padding: 14px;
    border-radius: 18px;
  }

  .site-nav-links a {
    min-height: 46px;
    padding: 0 12px;
    font-size: 13px;
  }

  .hero {
    gap: 22px;
    padding-top: calc(82px + var(--safe-top));
    padding-bottom: max(38px, var(--safe-bottom));
  }

  .eyebrow {
    gap: 8px;
    margin-bottom: 11px;
    font-size: 9px;
    letter-spacing: 0.08em;
  }

  .eyebrow span {
    flex-basis: 21px;
    width: 21px;
  }

  .hero-name {
    gap: 8px;
    margin-bottom: 10px;
    font-size: 13px;
  }

  .hero-name strong {
    font-size: 17px;
  }

  .hero h1 {
    max-width: 390px;
    font-size: var(--title-hero);
    letter-spacing: -0.03em;
    line-height: 1.14;
  }

  .hero-title-desktop {
    display: none;
  }

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

  .hero-summary {
    max-width: 390px;
    margin-top: 13px;
    font-size: 14px;
    line-height: 1.65;
  }

  .hero-actions {
    display: grid;
    gap: 9px;
    margin-top: 17px;
  }

  .button {
    width: 100%;
    min-height: 46px;
    padding: 0 17px;
    font-size: 13px;
  }

  .hero-tags {
    display: flex;
    width: calc(100% + 32px);
    flex-wrap: nowrap;
    gap: 8px;
    margin: 12px -16px 0;
    padding: 0 16px 4px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .hero-tags::-webkit-scrollbar {
    display: none;
  }

  .hero-tags span {
    flex: 0 0 auto;
    min-height: 0;
    padding: 7px 10px;
    font-size: 10px;
    line-height: 1.3;
    white-space: nowrap;
  }

  .hero-portrait figcaption {
    grid-template-columns: 1fr;
    gap: 5px;
    align-self: center;
    padding: 0;
  }

  .hero-portrait {
    display: grid;
    width: 100%;
    max-width: 100%;
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 14px;
    align-items: center;
    margin: 2px 0 0;
    justify-self: stretch;
  }

  .portrait-frame {
    width: 92px;
    border-radius: 15px 15px 6px 6px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.34);
  }

  .portrait-grid {
    right: 12px;
    bottom: 12px;
    width: 40px;
    height: 40px;
  }

  .hero-portrait figcaption span {
    display: none;
  }

  .hero-portrait figcaption strong {
    max-width: 220px;
    font-size: 11px;
    line-height: 1.55;
  }

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

  .proof-strip div {
    min-height: 98px;
    grid-template-columns: 1fr;
    gap: 7px;
    align-content: center;
    align-items: start;
    padding: 14px 10px;
    border-right: 1px solid var(--line);
    border-bottom: 0;
  }

  .proof-strip div::before {
    left: 10px;
    width: 24px;
  }

  .proof-strip div:last-child {
    border-right: 0;
  }

  .proof-strip strong {
    margin-bottom: 5px;
    font-size: 21px;
  }

  .proof-strip span {
    display: block;
    max-width: 120px;
    font-size: 10px;
    line-height: 1.35;
  }

  .section,
  .contact-section,
  .work-section {
    padding-right: max(16px, var(--safe-right));
    padding-left: max(16px, var(--safe-left));
  }

  .section h2,
  .contact-section h2 {
    font-size: var(--title-section);
  }

  .profile-grid,
  .focus-header,
  .work-intro,
  .experience-heading {
    gap: 16px;
  }

  .profile-grid {
    margin-top: 22px;
  }

  .profile-grid p,
  .focus-header > p,
  .work-intro > p,
  .experience-heading > p,
  .contact-copy p {
    font-size: 14px;
    line-height: 1.75;
  }

  .capability-grid {
    gap: 12px;
    border-top: 0;
    border-left: 0;
  }

  .capability-grid article {
    display: grid;
    min-height: 0;
    grid-template-columns: 32px minmax(0, 1fr);
    gap: 8px 12px;
    padding: 18px;
    border: 1px solid #d5dee8;
    border-radius: 14px;
  }

  .capability-grid span {
    grid-row: 1 / span 2;
    padding-top: 2px;
  }

  .capability-grid h3 {
    grid-column: 2;
    margin: 0;
    font-size: 18px;
    line-height: 1.3;
  }

  .capability-grid p {
    grid-column: 2;
    font-size: 13px;
    line-height: 1.65;
  }

  .skill-atlas {
    margin-top: 30px;
    padding-top: 18px;
  }

  .skill-atlas-title {
    margin-bottom: 14px;
  }

  .skill-columns {
    gap: 12px;
  }

  .skill-columns article {
    padding: 18px;
  }

  .skill-columns h3 {
    margin-bottom: 14px;
    font-size: 17px;
  }

  .skill-columns ul {
    gap: 9px;
  }

  .timeline-item {
    gap: 10px;
    padding: 20px 0 22px;
  }

  .timeline-body h3 {
    margin-bottom: 10px;
    font-size: 21px;
  }

  .timeline-body > p:last-of-type {
    line-height: 1.72;
  }

  .project-topline {
    gap: 8px;
    flex-direction: column;
  }

  .featured-project {
    padding: 19px 17px;
    border-radius: 16px;
  }

  .project-copy h3 {
    font-size: clamp(20px, 5.8vw, 26px);
  }

  .project-description {
    font-size: 13px;
    line-height: 1.65;
  }

  .project-capabilities span {
    min-height: 54px;
    padding: 10px;
    font-size: 10px;
  }

  .project-footer {
    align-items: flex-start;
    flex-direction: column;
    gap: 13px;
  }

  .project-actions {
    display: grid;
    width: 100%;
    grid-template-columns: 1fr 1fr;
  }

  .project-link {
    min-height: 42px;
    padding: 0 10px;
    font-size: 10px;
  }

  .contact-link {
    grid-template-columns: 40px minmax(0, 1fr) auto;
    gap: 12px;
    padding: 14px 14px;
  }

  .contact-link-copy strong {
    font-size: 14px;
  }

  .site-footer {
    align-items: flex-start;
    grid-template-columns: 1fr;
    gap: 10px;
    padding-top: 16px;
    padding-bottom: calc(16px + var(--safe-bottom));
  }

  .footer-policy-links {
    justify-content: flex-start;
  }
}

@media (max-height: 820px) and (min-width: 901px) {
  :root {
    --title-hero: clamp(28px, 3.2vw, 42px);
    --section-block: clamp(48px, 6vh, 72px);
  }

  .hero {
    gap: clamp(20px, 2.5vw, 40px);
    padding-top: calc(72px + var(--safe-top));
    padding-bottom: 28px;
  }

  .eyebrow {
    margin-bottom: 12px;
  }

  .hero-name {
    margin-bottom: 8px;
  }

  .hero h1 {
    max-width: 680px;
    font-size: var(--title-hero);
  }

  .hero-summary {
    max-width: 600px;
    margin-top: 12px;
    font-size: clamp(14px, 1.15vw, 16px);
    line-height: 1.58;
  }

  .hero-actions {
    margin-top: 16px;
  }

  .button {
    min-height: 44px;
  }

  .hero-tags {
    margin-top: 10px;
  }

  .hero-tags span {
    padding: 5px 9px;
  }

  .hero-portrait {
    width: clamp(220px, 22vw, 280px);
  }

  .hero-portrait figcaption {
    gap: 6px;
    padding-top: 8px;
  }
}

/* Short landscape: phones on their side, Nest Hub, fold cover — don't force a full-screen hero */
@media (max-height: 640px) and (orientation: landscape) {
  :root {
    --section-block: 40px;
    --title-hero: clamp(22px, 4.5vh, 30px);
    --title-section: clamp(20px, 4.2vh, 28px);
  }

  .hero {
    grid-template-columns: minmax(0, 1.2fr) minmax(140px, 0.45fr);
    gap: 16px;
    min-height: auto;
    overflow: visible;
    padding-top: calc(76px + var(--safe-top));
    padding-bottom: 12px;
  }

  .hero-portrait {
    width: min(28vw, 160px);
    margin: 0;
    justify-self: end;
  }

  .hero-tags {
    display: none;
  }

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

  .proof-strip div {
    min-height: 64px;
    padding: 10px 12px;
  }

  .section,
  .work-section,
  .contact-section {
    padding-top: var(--section-block);
    padding-bottom: var(--section-block);
  }
}

@media print {
  .site-nav,
  .nav-menu-toggle,
  .hero-actions,
  .hero-tags,
  .lang-toggle {
    display: none !important;
  }

  body {
    background: #fff;
    color: #000;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .hero,
  .section,
  .work-section,
  .contact-section,
  .site-footer {
    min-height: 0 !important;
    padding: 18px 0 !important;
    background: #fff !important;
    color: #000 !important;
    box-shadow: none !important;
  }

  a[href]::after {
    content: " (" attr(href) ")";
    font-size: 11px;
    color: #555;
  }

  a[href^="#"]::after,
  a[href^="mailto:"]::after,
  a[href^="tel:"]::after {
    content: "";
  }
}

.footer-filings {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px 16px;
  font-size: 11px;
  line-height: 1.6;
}

.footer-filings a {
  color: inherit;
  font-size: inherit;
  font-weight: 400;
  text-decoration: none;
  white-space: nowrap;
}

.police-filing {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.police-filing img {
  flex: 0 0 14px;
  width: 14px;
  height: 16px;
  object-fit: contain;
}

.footer-details {
  display: grid;
  gap: 8px;
}

.footer-details .footer-filings {
  justify-content: flex-end;
  color: rgba(255, 255, 255, 0.56);
}

@media (max-width: 600px) {
  .footer-details .footer-filings {
    justify-content: flex-start;
  }
}
