:root {
  --bg: #f5f5f5;
  --surface: #ffffff;
  --surface-soft: #ececf1;
  --text: #1b1d22;
  --text-muted: #3f4450;
  --line: #d2d5dc;
  --accent: #0d63f3;
  --accent-contrast: #ffffff;
  --focus: #1345a7;
  --radius-lg: 1.6rem;
  --radius-md: 1rem;
  --container-inline: clamp(1.25rem, 4vw, 3rem);
  --section-space: clamp(3.5rem, 8vw, 6rem);
  --content-gap: clamp(1.5rem, 3vw, 2.5rem);
  --space-1: 0.5rem;
  --space-2: 0.75rem;
  --space-3: 1rem;
  --space-4: 1.5rem;
  --space-5: 2rem;
  --space-6: 3rem;
  --space-7: 4rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text-muted);
  font-family: Inter, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.6;
}

img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: inherit;
}

a {
  color: inherit;
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.16em;
  border-radius: 0.5rem;
  padding: 0.22em 0.6em;
  margin: -0.22em -0.6em;
  display: inline-block;
  background-color: transparent;
  transition: background-color 160ms ease;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}

a:hover,
a:focus-visible,
a:active {
  background-color: rgba(0, 0, 0, 0.05);
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

.container {
  width: min(64rem, calc(100% - (2 * var(--container-inline))));
  margin-inline: auto;
}

#main-content,
.site-footer {
  margin-inline: clamp(0.75rem, 2.5vw, 1.75rem);
}

#main-content {
  margin-block-start: var(--space-3);
  margin-block-end: var(--space-4);
}

.site-footer {
  margin-block-end: var(--space-4);
}

.skip-link {
  position: absolute;
  top: 0.25rem;
  left: 0.25rem;
  transform: translateY(-130%);
  z-index: 1000;
  padding: var(--space-2) var(--space-3);
  border-radius: 0.5rem;
  background: var(--accent);
  color: var(--accent-contrast);
  font-weight: 600;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: color-mix(in srgb, var(--bg) 78%, transparent 22%);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid color-mix(in srgb, var(--line) 70%, transparent 30%);
}

.header-inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 4.75rem;
  gap: var(--space-4);
}

.brand {
  display: inline-flex;
  align-items: center;
  line-height: 0;
  text-decoration: none;
  padding-block: clamp(1.1rem, 3.5vw, 1.85rem);
}

.brand-logo {
  display: block;
  height: clamp(1.98rem, 5.04vw, 2.82rem);
  width: auto;
}

.header-actions {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5ch;
  margin: 0;
  padding: 0.6rem 0.95rem;
  border: 1px solid transparent;
  border-radius: 16px;
  background: #373737;
  color: var(--accent-contrast);
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition:
    background-color 160ms ease,
    border-color 160ms ease,
    color 160ms ease,
    transform 120ms ease;
}

a.btn {
  padding: 0.6rem 0.95rem;
}

.btn:hover {
  background: color-mix(in srgb, #373737 88%, white 12%);
}

.btn:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}

.btn:active {
  background: color-mix(in srgb, #373737 94%, black 6%);
  transform: translateY(1px);
}

.btn:disabled,
.btn[aria-disabled="true"] {
  background: var(--line);
  color: var(--text-muted);
  cursor: not-allowed;
  transform: none;
}

.narrative-aside {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-3);
}

.hero-section {
  padding-block: var(--section-space);
}

.hero-grid {
  display: grid;
  gap: var(--content-gap);
}

.hero-grid > div:first-child {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  gap: var(--space-2);
  order: 2;
}

.hero-copy {
  order: 1;
  align-self: end;
  justify-self: center;
  text-align: center;
}

.hero-avatar {
  width: 104px;
  height: 104px;
  border-radius: 50%;
  border: 1px solid #dbdee6;
  object-fit: cover;
  margin-inline: auto;
  margin-bottom: var(--space-2);
}

.eyebrow {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.9rem;
}

h1 {
  margin: 0.25rem 0 0;
  font-size: clamp(2rem, 8vw, 4.25rem);
  line-height: 0.98;
  letter-spacing: -0.02em;
  color: var(--text);
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  list-style: none;
  margin: var(--space-4) 0 0;
  padding: 0;
}

.tag-list li {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.2rem 0.7rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  background: var(--surface);
}

.feature-media {
  padding-bottom: 40px;
}

.media-card,
.gallery-strip,
.gallery-card {
  margin: 0;
  border-radius: var(--radius-md);
  overflow: clip;
  border: 1px solid #dbdee6;
  background: var(--surface-soft);
}

.media-card img {
  aspect-ratio: 16 / 8;
  object-fit: cover;
}

.narrative {
  padding-bottom: 160px;
}

.narrative-grid {
  display: grid;
  gap: var(--content-gap);
}

h2 {
  margin: 0;
  font-size: clamp(1.35rem, 4vw, 2rem);
  line-height: 1.2;
  letter-spacing: -0.01em;
  color: var(--text);
}

h3 {
  color: var(--text);
}

.section-kicker {
  margin: 0 0 var(--content-gap);
  color: #6b7280;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  display: inline-flex;
  align-items: center;
  gap: 0.5ch;
}

.section-kicker::after {
  content: "↘";
  font-size: 0.95em;
  line-height: 1;
  opacity: 0.9;
}

.narrative p {
  margin: 0;
  color: var(--text-muted);
  max-width: 58ch;
}

.gallery-section {
  padding-bottom: var(--section-space);
}

.projects {
  display: grid;
  gap: 160px;
}

.project {
  --project-pad: clamp(2.5rem, 6vw, 3.5rem);
  padding: var(--project-pad);
  border: 1px solid #dbdee6;
  border-radius: var(--radius-lg);
  background: color-mix(in srgb, var(--bg) 65%, white 35%);
  box-shadow: 0 20px 40px rgba(27, 29, 34, 0.08);
}

.project .gallery-strip {
  margin-top: calc(var(--project-pad) * -1);
  margin-inline: calc(var(--project-pad) * -1);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.project .gallery-strip,
.project .gallery-card {
  border-color: transparent;
}

.gallery-strip {
  margin-bottom: var(--content-gap);
}

.gallery-strip img {
  aspect-ratio: 21 / 8;
  object-fit: cover;
}

.project-title {
  margin: 0;
  margin-top: 50px;
}

.project-lede {
  margin: 0 0 var(--space-2);
  font-size: 1.2rem;
  color: var(--text-muted);
}

.pill-list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  list-style: none !important;
  margin: 0 0 var(--space-5);
  margin-top: 8px;
  padding: 0;
}

.pill-list li {
  list-style: none !important;
  margin: 0;
  padding: 0;
}

li.pill {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0.22rem 1rem;
  font-size: 0.75rem;
  color: var(--text-muted);
  background: transparent;
}

.gallery-pair {
  display: grid;
  gap: var(--content-gap);
}

.gallery-card img {
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.image-thumb {
  border: 0;
  padding: 0;
  margin: 0;
  width: 100%;
  background: transparent;
  color: inherit;
  display: block;
  cursor: pointer;
  border-radius: inherit;
}

.image-thumb:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.image-thumb img {
  max-height: clamp(9rem, 18vw, 12rem);
}

.lightbox {
  border: 0;
  padding: 0;
  background: transparent;
  max-width: min(
    92vw,
    calc(
      min(64rem, calc(100vw - (2 * var(--container-inline)))) -
        (2 * clamp(2.5rem, 6vw, 3.5rem))
    )
  );
  max-height: 88vh;
  opacity: 0;
  transform: translateY(8px) scale(0.985);
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

.lightbox::backdrop {
  background: transparent;
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  opacity: 0;
  transition: opacity 180ms ease;
}

.lightbox[data-state="open"] {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.lightbox[data-state="closing"] {
  opacity: 0;
  transform: translateY(10px) scale(0.98);
}

.lightbox[data-state="open"]::backdrop {
  opacity: 1;
}

.lightbox-track {
  display: flex;
  gap: var(--space-3);
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding: 0;
  margin: 0;
  max-height: 88vh;
  scrollbar-width: none;
}

.lightbox-track::-webkit-scrollbar {
  display: none;
}

.lightbox-slide {
  scroll-snap-align: center;
  flex: 0 0 100%;
  display: grid;
  place-items: center;
}

.lightbox-image {
  display: block;
  max-width: 100%;
  max-height: 88vh;
  border-radius: var(--radius-md);
  border: 1px solid rgba(219, 222, 230, 0.65);
  background: var(--surface);
}

.lightbox-nav {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
}

.lightbox-arrow {
  pointer-events: auto;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 3rem;
  height: 3rem;
  border-radius: 999px;
  border: 1px solid rgba(219, 222, 230, 0.65);
  background: rgba(255, 255, 255, 0.82);
  color: var(--text);
  font-size: 2rem;
  line-height: 1;
  display: grid;
  place-items: center;
  cursor: pointer;
  opacity: 0.55;
  transition: opacity 160ms ease, background-color 160ms ease;
}

.lightbox-arrow-left {
  left: 1.1rem;
}

.lightbox-arrow-right {
  right: 1.1rem;
}

.lightbox-arrow:hover,
.lightbox-arrow:focus-visible,
.lightbox-arrow:active {
  background: rgba(255, 255, 255, 0.98);
  opacity: 1;
}

.lightbox-close {
  position: fixed;
  top: 1.1rem;
  right: 1.1rem;
  z-index: 2;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 999px;
  border: 1px solid rgba(219, 222, 230, 0.65);
  background: rgba(255, 255, 255, 0.85);
  color: var(--text);
  font-size: 1.6rem;
  line-height: 1;
  display: grid;
  place-items: center;
  cursor: pointer;
}

.lightbox-close:hover,
.lightbox-close:focus-visible,
.lightbox-close:active {
  background: rgba(255, 255, 255, 0.98);
}

.gallery-strip.muted img {
  opacity: 0.55;
  filter: saturate(80%);
}

.site-footer {
  background: transparent;
}

.footer-inner {
  position: relative;
  min-height: 4.25rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding-block: var(--space-4);
}

.footer-inner::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--line);
}

.footer-brand {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 500;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media (min-width: 48rem) {
  .hero-grid {
    display: flex;
    align-items: stretch;
  }

  .hero-grid > div:first-child {
    flex: 1 1 50%;
    order: initial;
  }

  .hero-copy {
    flex: 1 1 50%;
    order: initial;
    align-self: stretch;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: center;
  }

  .hero-avatar {
    width: calc(clamp(6.5rem, 10vw, 9rem) * 2.5);
    height: 100%;
    border-radius: var(--radius-lg);
    max-height: 100%;
    margin-left: auto;
    margin-right: 0;
    margin-bottom: var(--space-3);
  }

  .narrative-grid {
    display: grid;
  }

  .narrative-grid {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }

  .hero-copy {
    justify-self: end;
    text-align: right;
  }

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

@media (max-width: 47.99rem) {
  .lightbox {
    max-width: 98vw;
    max-height: 92vh;
  }

  .lightbox-image {
    max-height: 92vh;
  }

  .lightbox-track {
    gap: var(--space-1);
  }

  .lightbox-arrow {
    display: none;
  }
}

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

  * {
    transition: none !important;
    animation: none !important;
  }
}
