:root {
  --ink: #0a0b0b;
  --ink-2: #121413;
  --paper: #f0eee7;
  --muted: #a7aaa4;
  --line: rgba(240, 238, 231, 0.18);
  --lime: #d9ff57;
  --red: #f0523d;
  --cyan: #6fd4c7;
  --max: 1440px;
  --page: clamp(24px, 4vw, 64px);
  --radius: 6px;
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  background: var(--ink);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-width: 320px;
  overflow-x: hidden;
  color: var(--paper);
  background: var(--ink);
  font-family: Arial, "Microsoft YaHei", "PingFang SC", sans-serif;
  letter-spacing: 0;
  -webkit-font-smoothing: antialiased;
}

body.modal-open { overflow: hidden; }

a { color: inherit; text-decoration: none; }
button { font: inherit; }
img { display: block; max-width: 100%; }

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

::selection { color: var(--ink); background: var(--lime); }

.eyebrow,
.section-index {
  margin: 0;
  color: var(--lime);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.4;
  text-transform: uppercase;
}

/* Visual entry */
.entry-body { overflow: hidden; }

.entry-screen {
  --mx: 0px;
  --my: 0px;
  position: relative;
  min-height: 100svh;
  min-height: 100dvh;
  overflow: hidden;
  cursor: pointer;
  isolation: isolate;
  outline: 0;
  background: #151315;
}

.entry-art,
.entry-art > img,
.entry-slices,
.entry-noise {
  position: absolute;
  inset: 0;
}

.entry-art > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: translate3d(var(--mx), var(--my), 0) scale(1.035);
  transition: transform 220ms ease-out;
}

.entry-art::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(5, 5, 7, 0.72) 0%, rgba(5, 5, 7, 0.12) 50%, rgba(5, 5, 7, 0.54) 100%);
}

.entry-slices {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  z-index: 2;
}

.entry-slices span {
  border-right: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.012);
  transform-origin: 50% 0;
  transition: transform 700ms cubic-bezier(.76, 0, .24, 1), background 250ms ease;
}

.entry-slices span:nth-child(2n) { background: rgba(7, 9, 11, 0.08); }
.entry-screen:hover .entry-slices span:nth-child(2) { transform: translateY(5px); }
.entry-screen:hover .entry-slices span:nth-child(4) { transform: translateY(-5px); }

.entry-noise {
  z-index: 3;
  opacity: 0.2;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.32'/%3E%3C/svg%3E");
}

.entry-header,
.entry-footer,
.entry-copy {
  position: absolute;
  z-index: 5;
}

.entry-header {
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding: calc(28px + env(safe-area-inset-top)) calc(var(--page) + env(safe-area-inset-right)) 28px calc(var(--page) + env(safe-area-inset-left));
}

.entry-mark,
.site-logo {
  font-size: 21px;
  font-weight: 900;
  line-height: 1;
}

.entry-mark span,
.site-logo span { color: var(--lime); }

.entry-meta {
  font-size: 10px;
  font-weight: 700;
  line-height: 1.55;
  text-align: right;
}

.entry-copy {
  left: calc(var(--page) + env(safe-area-inset-left));
  bottom: 22vh;
}

.entry-copy h1 {
  margin: 16px 0 0;
  max-width: 760px;
  font-size: clamp(56px, 8.5rem, 136px);
  line-height: 0.86;
}

.entry-copy h1 em,
.portfolio-hero h1 em,
.section-heading h2 em,
.about-copy h2 em,
.contact-section h2 em {
  color: var(--lime);
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
}

.entry-footer {
  right: calc(var(--page) + env(safe-area-inset-right));
  bottom: calc(28px + env(safe-area-inset-bottom));
  left: calc(var(--page) + env(safe-area-inset-left));
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  font-size: 10px;
  font-weight: 700;
}

.entry-footer p { margin: 0; }
.entry-index { text-align: right; }

.enter-button {
  display: inline-flex;
  align-items: center;
  gap: 22px;
  min-height: 52px;
  padding: 6px 7px 6px 22px;
  color: var(--ink);
  border: 0;
  border-radius: 999px;
  background: var(--lime);
  cursor: pointer;
  font-weight: 800;
}

.enter-arrow {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 50%;
  background: var(--ink);
  color: var(--paper);
  transition: transform 180ms ease;
}

.enter-button:hover .enter-arrow { transform: rotate(45deg); }

.entry-screen.is-leaving .entry-slices span:nth-child(odd) { transform: scaleY(0); }
.entry-screen.is-leaving .entry-slices span:nth-child(even) { transform: scaleY(1.12); background: var(--ink); }
.entry-screen.is-leaving .entry-copy,
.entry-screen.is-leaving .entry-header,
.entry-screen.is-leaving .entry-footer { opacity: 0; transition: opacity 300ms ease; }

/* Shared navigation */
.site-header {
  position: fixed;
  z-index: 50;
  top: 0;
  left: 0;
  right: 0;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  min-height: calc(72px + env(safe-area-inset-top));
  padding: env(safe-area-inset-top) calc(var(--page) + env(safe-area-inset-right)) 0 calc(var(--page) + env(safe-area-inset-left));
  border-bottom: 1px solid transparent;
  transition: background 220ms ease, border-color 220ms ease;
}

.site-header.is-scrolled {
  border-color: var(--line);
  background: rgba(10, 11, 11, 0.88);
  backdrop-filter: blur(16px);
}

.desktop-nav { display: flex; gap: 34px; }

.desktop-nav a {
  position: relative;
  font-size: 13px;
  font-weight: 700;
}

.desktop-nav a::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: -7px;
  left: 0;
  height: 2px;
  background: var(--lime);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 180ms ease;
}

.desktop-nav a:hover::after { transform: scaleX(1); transform-origin: left; }

.availability {
  justify-self: end;
  font-size: 10px;
  font-weight: 800;
}

.availability i {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 8px;
  border-radius: 50%;
  background: var(--lime);
  box-shadow: 0 0 0 4px rgba(217, 255, 87, 0.12);
}

.menu-button,
.mobile-nav { display: none; }

/* Hero */
.portfolio-hero {
  position: relative;
  min-height: 88svh;
  min-height: 88dvh;
  overflow: hidden;
  isolation: isolate;
}

.hero-image,
.hero-shade {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero-image { object-fit: cover; object-position: center; transform: scale(1.015); }

.hero-shade {
  z-index: 1;
  background: linear-gradient(90deg, rgba(5, 5, 7, 0.95) 0%, rgba(5, 5, 7, 0.65) 34%, rgba(5, 5, 7, 0.08) 72%), linear-gradient(0deg, rgba(5, 5, 7, 0.7), transparent 45%);
}

.hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: min(720px, 68vw);
  min-height: 88svh;
  min-height: 88dvh;
  padding: calc(110px + env(safe-area-inset-top)) calc(var(--page) + env(safe-area-inset-right)) 100px calc(var(--page) + env(safe-area-inset-left));
}

.portfolio-hero h1 {
  margin: 22px 0 24px;
  font-size: clamp(54px, 6.8rem, 108px);
  line-height: 0.98;
}

.portfolio-hero h1 em { display: inline-block; }

.hero-intro {
  max-width: 580px;
  margin: 0;
  color: rgba(240, 238, 231, 0.82);
  font-size: 17px;
  line-height: 1.75;
}

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

.button {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  min-height: 50px;
  padding: 0 20px;
  border: 1px solid rgba(240, 238, 231, 0.42);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
  transition: color 180ms ease, background 180ms ease, border-color 180ms ease;
}

.button-primary { color: var(--ink); border-color: var(--lime); background: var(--lime); }
.button-primary:hover { background: var(--paper); border-color: var(--paper); }
.button-ghost:hover { color: var(--ink); background: var(--paper); border-color: var(--paper); }

.hero-foot {
  position: absolute;
  z-index: 2;
  right: calc(var(--page) + env(safe-area-inset-right));
  bottom: calc(26px + env(safe-area-inset-bottom));
  left: calc(var(--page) + env(safe-area-inset-left));
  display: flex;
  justify-content: space-between;
  color: rgba(240, 238, 231, 0.72);
  font-size: 9px;
  font-weight: 700;
}

.capability-strip {
  overflow: hidden;
  padding: 20px 0;
  color: var(--ink);
  background: var(--lime);
  font-size: 15px;
  font-weight: 900;
  white-space: nowrap;
}

.capability-strip div {
  display: flex;
  width: max-content;
  gap: 28px;
  animation: marquee 24s linear infinite;
}

.capability-strip b { color: var(--red); }

@keyframes marquee { to { transform: translateX(-30%); } }

/* Sections */
.section {
  width: min(100%, var(--max));
  margin: 0 auto;
  padding: 140px var(--page);
  scroll-margin-top: 70px;
}

.section-heading {
  display: grid;
  grid-template-columns: 1fr 2fr 1fr;
  gap: 40px;
  align-items: end;
  margin-bottom: 66px;
}

.section-heading h2,
.about-copy h2 {
  margin: 0;
  font-size: clamp(42px, 5rem, 80px);
  line-height: 1.04;
}

.section-heading > p:last-child {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.75;
}

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

.project-card {
  position: relative;
  min-height: 0;
  overflow: hidden;
  padding: 0 0 96px;
  color: var(--paper);
  text-align: left;
  border: 0;
  border-radius: var(--radius);
  background: var(--ink-2);
  cursor: pointer;
  isolation: isolate;
  aspect-ratio: 16 / 11.5;
}

.project-card-wide { grid-column: 1 / -1; min-height: 0; aspect-ratio: 16 / 10.1; }
.project-card-logo { grid-column: 1 / -1; min-height: 0; aspect-ratio: 16 / 10.1; }

.project-card img,
.project-scrim {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  width: 100%;
}

.project-card img {
  height: calc(100% - 96px);
  object-fit: contain;
  object-position: center;
  background: #050606;
}

.project-card-wide img { object-position: center; }

.project-scrim {
  display: none;
}

.project-topline,
.project-info,
.project-open { position: absolute; z-index: 2; }

.project-topline {
  top: 16px;
  right: 24px;
  left: 24px;
  display: flex;
  justify-content: space-between;
  font-style: normal;
  font-size: 10px;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.9);
}

.project-topline b { color: var(--lime); font-size: 16px; }
.project-topline i { font-style: normal; font-weight: 700; }

.project-info { right: 90px; bottom: 28px; left: 28px; }

.project-info strong {
  display: block;
  margin-bottom: 8px;
  font-size: 30px;
}

.project-info small { color: rgba(240, 238, 231, 0.72); font-size: 12px; }

.project-open {
  right: 26px;
  bottom: 28px;
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border-radius: 50%;
  color: var(--ink);
  background: var(--lime);
  font-size: 22px;
  transition: transform 220ms ease, background 220ms ease;
}

.project-card:hover .project-open { transform: rotate(45deg); background: var(--paper); }

/* About */
.about-section {
  display: grid;
  grid-template-columns: 0.82fr 1.18fr;
  gap: 5vw;
  border-top: 1px solid var(--line);
}

.about-portrait { align-self: stretch; }

.portrait-frame {
  position: sticky;
  top: 110px;
  aspect-ratio: 2 / 3;
  overflow: hidden;
  border-radius: var(--radius);
  background: #deddd9;
}

.portrait-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.portrait-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 62%, rgba(10, 11, 11, 0.72));
}

.portrait-frame span {
  position: absolute;
  z-index: 1;
  bottom: 18px;
  left: 20px;
  font-size: 10px;
  font-weight: 800;
}

.about-copy { padding-top: 18px; }
.about-copy h2 { margin: 22px 0 36px; }

.about-copy > p:not(.section-index) {
  margin: 0 0 20px;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.82;
}

.about-copy .about-lead { color: var(--paper); font-size: 20px; }

.contact-inline {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  margin-top: 34px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  font-size: 12px;
  font-weight: 700;
}

.contact-inline a:hover { color: var(--lime); }

.stats {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: 76px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.stats div { min-height: 190px; padding: 34px 24px; border-right: 1px solid var(--line); }
.stats div:last-child { border-right: 0; }

.stats strong { font-size: 64px; line-height: 1; }
.stats sup { color: var(--lime); font-size: 22px; font-weight: 900; }
.stats span { display: block; margin-top: 22px; color: var(--muted); font-size: 12px; }

.experience-list { grid-column: 1 / -1; margin-top: 70px; }

.experience-list article {
  display: grid;
  grid-template-columns: 0.7fr 1fr 1.6fr;
  gap: 36px;
  padding: 28px 0;
  border-top: 1px solid var(--line);
}

.experience-list article:last-child { border-bottom: 1px solid var(--line); }
.experience-list time { color: var(--lime); font-size: 12px; font-weight: 800; }
.experience-list h3 { margin: 0 0 7px; font-size: 18px; }
.experience-list div p,
.experience-list article > p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.7; }

/* Strengths */
.strengths-section { background: var(--ink); color: var(--paper); }
.strengths-section .section-index { color: var(--lime); }
.strengths-section .section-heading h2 em { color: var(--lime); }

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

.strength-card {
  min-height: 360px;
  padding: 34px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.strength-card > span { color: var(--red); font-size: 12px; font-weight: 900; }
.strength-card h3 { margin: 60px 0 18px; font-size: 30px; }
.strength-card p { max-width: 520px; margin: 0; color: var(--muted); font-size: 16px; line-height: 1.75; }
.strength-card small { display: block; margin-top: 48px; font-size: 9px; font-weight: 800; }

.tool-line {
  display: grid;
  grid-template-columns: 1fr 3fr;
  gap: 30px;
  margin-top: 54px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
  font-size: 12px;
}

.tool-line span { color: var(--red); font-weight: 900; }
.tool-line p { margin: 0; font-weight: 700; }

/* Contact */
.contact-section {
  min-height: 92svh;
  min-height: 92dvh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 42px calc(var(--page) + env(safe-area-inset-right)) calc(34px + env(safe-area-inset-bottom)) calc(var(--page) + env(safe-area-inset-left));
  color: var(--ink);
  background: var(--lime);
  scroll-margin-top: 70px;
}

.contact-topline,
.contact-bottom {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  font-size: 10px;
  font-weight: 900;
}

.contact-section h2 {
  margin: auto 0 40px;
  max-width: 1160px;
  font-size: clamp(56px, 7.2rem, 116px);
  line-height: 0.98;
}

.contact-section h2 em { color: var(--ink); }

.contact-email {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 0;
  border-top: 2px solid var(--ink);
  border-bottom: 2px solid var(--ink);
  font-size: clamp(25px, 3.2rem, 52px);
  font-weight: 900;
}

.contact-email span { transition: transform 200ms ease; }
.contact-email:hover span { transform: rotate(45deg); }

/* Contact page */
.contact-page {
  min-height: 100svh;
  min-height: 100dvh;
  background:
    radial-gradient(circle at 78% 18%, rgba(111, 212, 199, 0.10), transparent 26%),
    var(--ink);
}

.contact-page .site-header { position: absolute; }

.contact-main {
  width: min(100%, var(--max));
  min-height: 100svh;
  min-height: 100dvh;
  margin: 0 auto;
  padding: calc(150px + env(safe-area-inset-top)) calc(var(--page) + env(safe-area-inset-right)) calc(70px + env(safe-area-inset-bottom)) calc(var(--page) + env(safe-area-inset-left));
}

.contact-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
  gap: clamp(36px, 8vw, 130px);
  align-items: end;
  min-height: 430px;
  padding-bottom: 72px;
  border-bottom: 1px solid var(--line);
}

.contact-hero h1 {
  max-width: 760px;
  margin: 22px 0 0;
  font-size: clamp(58px, 8vw, 122px);
  line-height: 0.92;
}

.contact-hero h1 em { color: var(--lime); font-family: Georgia, "Times New Roman", serif; font-weight: 400; }
.contact-hero-copy { max-width: 430px; color: var(--muted); font-size: 16px; line-height: 1.8; }

.contact-identity {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 22px;
  align-items: center;
  margin-top: 52px;
}

.contact-identity img {
  width: 112px;
  height: 146px;
  object-fit: cover;
  object-position: center 22%;
  border-radius: var(--radius);
}

.contact-identity strong { display: block; font-size: 24px; }
.contact-identity span { display: block; margin-top: 7px; color: var(--muted); font-size: 12px; }

.contact-details {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  margin-top: 72px;
  background: var(--line);
}

.contact-detail {
  min-height: 180px;
  padding: 28px;
  background: var(--ink-2);
}

.contact-detail-label { display: block; color: var(--lime); font-size: 10px; font-weight: 800; }
.contact-detail-value { display: block; margin-top: 36px; font-size: clamp(18px, 2vw, 28px); font-weight: 800; overflow-wrap: anywhere; }
.contact-detail-note { display: block; margin-top: 10px; color: var(--muted); font-size: 12px; }

.copy-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 18px;
  padding: 8px 11px;
  color: var(--paper);
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  cursor: pointer;
  font-size: 11px;
}

.copy-button:hover { color: var(--ink); border-color: var(--lime); background: var(--lime); }
.copy-button.is-copied { color: var(--ink); border-color: var(--lime); background: var(--lime); }

.contact-page-footer {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  margin-top: 34px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  line-height: 1.6;
}

.contact-page-footer a { color: var(--paper); }
.contact-page-footer a:hover { color: var(--lime); }

.contact-bottom { margin-top: 48px; }
.contact-bottom p { margin: 0; line-height: 1.6; }

.back-top {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border: 1px solid var(--ink);
  border-radius: 50%;
  font-size: 20px;
}

/* Dialog */
.project-dialog {
  width: min(1120px, calc(100% - 28px));
  max-height: calc(100svh - 28px);
  padding: 0;
  color: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--ink-2);
  -webkit-overflow-scrolling: touch;
}

.project-dialog::backdrop { background: rgba(0, 0, 0, 0.84); backdrop-filter: blur(8px); }
.dialog-shell { position: relative; padding: 64px; }

.dialog-close {
  position: sticky;
  z-index: 4;
  top: 0;
  float: right;
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  color: var(--paper);
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(10, 11, 11, 0.76);
  cursor: pointer;
  font-size: 28px;
  line-height: 1;
}

.dialog-head { max-width: 760px; margin-bottom: 42px; }
.dialog-head > p:first-child { color: var(--lime); font-size: 11px; font-weight: 900; }
.dialog-head h2 { margin: 18px 0; font-size: 48px; }
.dialog-head > p:not(:first-child) { color: var(--muted); font-size: 16px; line-height: 1.75; }
.dialog-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.dialog-tags span { padding: 8px 11px; border: 1px solid var(--line); border-radius: 999px; font-size: 10px; font-weight: 800; }
.dialog-gallery { display: grid; gap: 14px; }
.dialog-gallery img { width: 100%; border-radius: 3px; }

/* Reveal */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 650ms ease, transform 650ms ease; }
.reveal.is-visible { opacity: 1; transform: none; }

@media (max-width: 1099px) {
  .site-header { grid-template-columns: 1fr auto; }
  .desktop-nav,
  .availability { display: none; }
  .menu-button {
    position: absolute;
    top: 10px;
    right: calc(var(--page) + env(safe-area-inset-right));
    display: grid;
    justify-self: end;
    width: 42px;
    height: 42px;
    place-content: center;
    gap: 6px;
    padding: 0;
    color: var(--paper);
    border: 1px solid var(--line);
    border-radius: 50%;
    background: rgba(10, 11, 11, 0.5);
  }
  .menu-button span { width: 17px; height: 1px; background: currentColor; transition: transform 180ms ease; }
  .menu-button[aria-expanded="true"] span:first-child { transform: translateY(3.5px) rotate(45deg); }
  .menu-button[aria-expanded="true"] span:last-child { transform: translateY(-3.5px) rotate(-45deg); }
  .mobile-nav {
    position: absolute;
    top: 70px;
    right: calc(var(--page) + env(safe-area-inset-right));
    display: grid;
    min-width: 190px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(10, 11, 11, 0.96);
    transform: translateY(-8px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 180ms ease, transform 180ms ease;
  }
  .mobile-nav.is-open { opacity: 1; transform: none; pointer-events: auto; }
  .mobile-nav a { padding: 13px 10px; border-bottom: 1px solid var(--line); font-size: 14px; }
  .mobile-nav a:last-child { border-bottom: 0; }
  .hero-content { width: min(760px, 82vw); }
  .section-heading { grid-template-columns: 1fr 2fr; }
  .section-heading > p:last-child { grid-column: 2; }
  .project-card { min-height: 0; }
  .project-card-wide { min-height: 0; }
  .experience-list article { grid-template-columns: 0.7fr 1fr 1.4fr; }
}

@media (max-width: 767px) {
  :root { --page: 18px; }
  .entry-header { padding-top: 20px; }
  .entry-meta { font-size: 9px; }
  .entry-copy { bottom: 25vh; }
  .entry-copy h1 { font-size: 58px; }
  .entry-footer { grid-template-columns: 1fr auto; bottom: 18px; }
  .entry-footer > p:first-child { display: none; }
  .entry-index { order: -1; text-align: left; }
  .entry-art > img { object-position: 58% center; }

  .site-header { min-height: 62px; }
  .mobile-nav { top: 60px; }
  .portfolio-hero { min-height: 90svh; }
  .portfolio-hero { min-height: 90dvh; }
  .hero-image { object-position: 58% center; }
  .hero-shade { background: linear-gradient(0deg, rgba(5, 5, 7, 0.97) 0%, rgba(5, 5, 7, 0.62) 56%, rgba(5, 5, 7, 0.18) 100%); }
  .hero-content { justify-content: flex-end; width: 100%; min-height: 90svh; min-height: 90dvh; padding: calc(100px + env(safe-area-inset-top)) calc(var(--page) + env(safe-area-inset-right)) calc(88px + env(safe-area-inset-bottom)) calc(var(--page) + env(safe-area-inset-left)); }
  .portfolio-hero h1 { margin-top: 16px; font-size: 48px; line-height: 1.02; }
  .hero-intro { font-size: 15px; line-height: 1.65; }
  .hero-intro { max-width: calc(100vw - 36px); overflow-wrap: anywhere; }
  .hero-foot span:last-child { display: none; }
  .hero-actions { gap: 8px; }
  .button { gap: 16px; min-height: 46px; padding: 0 16px; font-size: 12px; }
  .hero-foot { bottom: 18px; font-size: 8px; }
  .hero-foot span:first-child { display: none; }
  .hero-foot { justify-content: flex-end; }

  .section { padding: 88px var(--page); }
  .section-heading { display: block; margin-bottom: 36px; }
  .section-heading h2,
  .about-copy h2 { margin: 18px 0 20px; font-size: 43px; }
  .section-heading > p:last-child { max-width: 500px; }
  .project-grid { grid-template-columns: 1fr; gap: 12px; }
  .project-card,
  .project-card-wide,
  .project-card-logo { grid-column: auto; min-height: 0; aspect-ratio: 16 / 13.5; }
  .project-card img { object-position: center; }
  .project-info { right: 76px; bottom: 22px; left: 20px; }
  .project-info strong { font-size: 24px; }
  .project-open { right: 18px; bottom: 20px; width: 42px; height: 42px; }

  .about-section { display: block; }
  .portrait-frame { position: relative; top: auto; }
  .about-copy { padding-top: 60px; }
  .about-copy .about-lead { font-size: 18px; }
  .contact-inline { display: grid; }
  .stats { grid-template-columns: repeat(2, 1fr); margin-top: 56px; }
  .stats div { min-height: 145px; padding: 26px 18px; border-bottom: 1px solid var(--line); }
  .stats div:nth-child(2) { border-right: 0; }
  .stats strong { font-size: 50px; }
  .experience-list { margin-top: 52px; }
  .experience-list article { grid-template-columns: 1fr; gap: 12px; padding: 24px 0; }

  .strength-grid { grid-template-columns: 1fr; }
  .strength-card { min-height: 300px; padding: 28px 22px; }
  .strength-card h3 { margin-top: 42px; font-size: 26px; }
  .strength-card small { margin-top: 34px; }
  .tool-line { grid-template-columns: 1fr; gap: 12px; }
  .tool-line p { line-height: 1.7; }

  .contact-section { min-height: 84svh; padding-top: 28px; }
  .contact-section { min-height: 84dvh; }
  .contact-section h2 { font-size: 50px; }
  .contact-email { padding: 22px 0; font-size: 23px; }
  .contact-bottom p:first-child { display: none; }
  .dialog-shell { padding: 54px 18px 24px; }
  .dialog-head h2 { font-size: 38px; }

  .contact-main { padding-top: 110px; }
  .contact-hero { display: block; min-height: 0; padding-bottom: 48px; }
  .contact-hero h1 { font-size: 58px; }
  .contact-hero-copy { margin-top: 28px; font-size: 15px; }
  .contact-identity { margin-top: 34px; }
  .contact-details { grid-template-columns: 1fr; margin-top: 44px; }
  .contact-detail { min-height: 150px; padding: 22px; }
  .contact-detail-value { margin-top: 24px; }
  .contact-page-footer { display: grid; }
}

@media (max-width: 430px) {
  .entry-copy h1 { font-size: 49px; }
  .enter-button { min-height: 48px; padding-left: 18px; }
  .portfolio-hero h1 { font-size: 41px; }
  .hero-actions { align-items: stretch; flex-direction: column; }
  .button { width: 100%; }
  .section-heading h2,
  .about-copy h2 { font-size: 38px; }
  .project-info small { display: none; }
  .contact-section h2 { font-size: 43px; }
  .contact-email { font-size: 19px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  .reveal { opacity: 1; transform: none; }
}
