@import url("tokens.css");

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  margin: 0;
  min-width: 0;
  overflow-x: hidden;
  font-family: var(--font-family-primary);
  background: var(--page-bg);
  color: var(--page-text);
  -webkit-font-smoothing: antialiased;
}

html.page-transition-enabled body {
  opacity: 0;
  transform: translateY(0.875rem);
  transition: opacity 0.42s ease, transform 0.42s cubic-bezier(0.16, 1, 0.3, 1);
}

html.page-transition-enabled::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 9999;
  pointer-events: none;
  background: var(--page-bg);
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.42s ease, transform 0.42s cubic-bezier(0.16, 1, 0.3, 1);
}

html.page-transition-ready body {
  opacity: 1;
  transform: translateY(0);
}

html.page-transition-ready::before {
  opacity: 0;
  transform: translateY(-1rem);
}

html.page-transition-leaving body {
  opacity: 0;
  transform: translateY(-0.875rem);
}

html.page-transition-leaving::before {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  html.page-transition-enabled body,
  html.page-transition-enabled::before {
    transition: none;
  }
}

/* ---------- Scroll reveal ---------- */
.reveal-on-scroll {
  opacity: 0;
  transform: translate3d(0, 2.5rem, 0);
  transition:
    opacity 0.72s ease,
    transform 0.72s cubic-bezier(0.16, 1, 0.3, 1);
  transition-delay: var(--reveal-delay, 0ms);
  will-change: opacity, transform;
}

.reveal-on-scroll[data-reveal-direction="left"] {
  transform: translate3d(-2.5rem, 0, 0);
}

.reveal-on-scroll[data-reveal-direction="right"] {
  transform: translate3d(2.5rem, 0, 0);
}

.reveal-on-scroll[data-reveal-direction="scale"] {
  transform: translate3d(0, 1.5rem, 0) scale(0.96);
}

.reveal-on-scroll.is-visible {
  opacity: 1;
  transform: translate3d(0, 0, 0) scale(1);
}

@media (prefers-reduced-motion: reduce) {
  .reveal-on-scroll {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: none;
  cursor: pointer;
}

/* ---------- Layout ---------- */
.shell {
  padding: 0 max(1.5rem, calc((100vw - var(--container-max)) / 2));
}

.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 clamp(1rem, 4vw, var(--space-container-pad));
}

.section {
  border-bottom: var(--stroke-weight-1) solid var(--border-subtle);
}

.section--flush-top {
  border-top: var(--stroke-weight-1) solid var(--border-subtle);
}

/* ---------- Nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  padding: 1.5rem 0 1.5625rem;
  border-bottom: var(--stroke-weight-1) solid var(--color-black-0);
  background: color-mix(in srgb, var(--page-bg) 75%, transparent);
  backdrop-filter: blur(0.75rem);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(0.75rem, 3vw, 1.5rem);
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 clamp(1rem, 4vw, var(--space-container-pad));
}

.nav__burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 0.375rem;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0.625rem;
  margin: 0;
  border-radius: var(--radius-pill);
  border: var(--stroke-weight-1) solid var(--color-white-12);
  background: transparent;
  cursor: pointer;
  flex-shrink: 0;
}

.nav__burger-line {
  display: block;
  height: 0.125rem;
  width: 100%;
  border-radius: 0.0625rem;
  background: var(--color-satin-linen);
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.nav.nav--open .nav__burger-line:nth-child(1) {
  transform: translateY(0.5rem) rotate(45deg);
}

.nav.nav--open .nav__burger-line:nth-child(2) {
  opacity: 0;
}

.nav.nav--open .nav__burger-line:nth-child(3) {
  transform: translateY(-0.5rem) rotate(-45deg);
}

.brand {
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: -0.0095rem;
  color: var(--text-strong);
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 0.4938rem;
}

.nav__link {
  padding: 0.4375rem 0.875rem;
  border-radius: var(--radius-pill);
  font-weight: 500;
  font-size: var(--font-size-nav-link);
  letter-spacing: var(--letter-spacing-link);
  color: var(--text-muted);
}

.nav__link:hover {
  color: var(--text-strong);
}

.nav__actions {
  display: flex;
  align-items: center;
  gap: 0.9994rem;
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3.125rem;
  height: 2.25rem;
  padding: 0.5rem 0.9375rem;
  border-radius: var(--radius-pill);
  border: var(--stroke-weight-1) solid var(--color-white-12);
}

.icon-btn img {
  width: 1.25rem;
  height: 1.25rem;
}

.btn-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 2.3125rem;
  padding: 0.625rem 1.1875rem;
  border-radius: var(--radius-pill);
  background: var(--color-daisy-bush);
  border: var(--stroke-weight-1) solid var(--color-white-12);
  font-weight: 700;
  font-size: var(--font-size-nav-link);
  letter-spacing: var(--letter-spacing-cta);
  text-transform: uppercase;
  color: var(--color-white);
}

.btn-cta:hover {
  filter: brightness(1.06);
}

/* ---------- Hero ---------- */
.hero {
  padding: 8rem 0 17.7369rem;
}

.hero__grid-top {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: var(--space-l);
  align-items: start;
}

.hero__title {
  position: relative;
  min-height: 24.8125rem;
}

.hero__title-inner {
  position: absolute;
  left: -0.0206rem;
  top: 50%;
  transform: translateY(-50%);
  width: min(47.5625rem, 100%);
}

.hero__title-line {
  margin: 0;
  font-size: 6rem;
  line-height: 6rem;
  letter-spacing: var(--letter-spacing-tight-hero);
  font-weight: 700;
  color: var(--text-strong);
}

.hero__title-line--muted {
  font-weight: 300;
  color: var(--hero-muted-word);
}

.hero__title-line .accent {
  color: var(--accent-readable);
}

.hero__title-line .bot {
  color: var(--accent-readable);
}

.dot {
color: var(--color-clay-creek);
}

.hero__avatar-wrap {
  display: flex;
  justify-content: center;
  padding-top: 1rem;
}

.avatar-ring {
  position: relative;
  width: 21rem;
  height: 21rem;
  max-width: 100%;
  border-radius: var(--radius-full);
  background: var(--color-grey-10);
  border: var(--stroke-weight-1) solid var(--color-white-12);
  padding: 0.0625rem;
  overflow: hidden;
}

.avatar-ring__stack {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  overflow: hidden;
}

.avatar-ring__stack img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 125.16%;
  object-fit: cover;
  object-position: top center;
}

.avatar-ring__stack img.layer-2 {
  height: 133.4%;
  top: -7.78%;
}

.avatar-ring::after {
  content: "";
  position: absolute;
  inset: -0.5rem;
  border-radius: 10.9375rem;
  border: var(--stroke-weight-1) solid var(--color-daisy-bush-25);
  pointer-events: none;
}

.hero__grid-bottom {
  /*display: grid;*/
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  margin-top: var(--space-m);
  align-items: end;
}

.hero__lede {
  font-size: var(--font-size-body);
  line-height: var(--line-height-body);
  font-weight: 400;
  color: var(--text-muted);
  max-width: 35.5rem;
}

.hero__lede p {
  margin: 0 0 0.5rem;
}

.hero__actions {
  display: flex;
  justify-content: flex-end;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.4375rem;
  height: 2.4375rem;
  padding: 0.6875rem 1.375rem;
  border-radius: var(--radius-pill);
  background: var(--color-daisy-bush);
  font-weight: 600;
  font-size: 0.8188rem;
  letter-spacing: 0.1148rem;
  text-transform: uppercase;
  color: var(--color-white);
}

.btn-primary img {
  width: 0.875rem;
  height: 0.875rem;
  rotate: 225deg;
}

/* ---------- Section label & headings ---------- */
.section-label {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  gap: var(--space-xs);
  width: fit-content;
  max-width: 100%;
  padding: 0.4375rem 0.9375rem;
  border-radius: var(--radius-pill);
  border: var(--stroke-weight-1) solid var(--color-white-12);
}

.section-label__dot {
  width: 0.3125rem;
  height: 0.3125rem;
  border-radius: var(--radius-dot);
  background: var(--accent-readable);
}

.section-label__text {
  font-weight: 600;
  font-size: var(--font-size-label);
  letter-spacing: var(--letter-spacing-upper);
  text-transform: uppercase;
  color: var(--text-muted);
}

.h2 {
  margin: 0;
  font-weight: 700;
  font-size: 3.2rem;
  line-height: 3.52rem;
  letter-spacing: var(--letter-spacing-h2);
  color: var(--text-strong);
}

.h3 {
  margin: 0;
  font-weight: 700;
  font-size: 1.4rem;
  line-height: 1.4rem;
  letter-spacing: -0.028rem;
  color: var(--text-strong);
}

/* ---------- About ---------- */
.about {
  padding: var(--space-section-y) 0 6.3125rem;
}

.about__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xl);
  margin-top: var(--space-m);
}

.quote {
  margin: 0;
  padding-left: 1.75rem;
  border-left: var(--stroke-weight-2) solid var(--color-daisy-bush);
  font-weight: 300;
  font-size: var(--font-size-quote);
  line-height: var(--line-height-quote);
  color: var(--text-strong);
}

.body-col p {
  margin: 0 0 1rem;
  font-size: var(--font-size-body-lg);
  line-height: var(--line-height-body-lg);
  color: var(--text-muted);
}

.body-col {
  padding-top: 1rem;
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  padding-top: 2.5625rem;
  border-top: var(--stroke-weight-1) solid var(--border-subtle);
}

.stat__num {
  margin: 0;
  font-weight: 800;
  font-size: 2.6rem;
  line-height: 2.6rem;
  letter-spacing: var(--letter-spacing-stat);
  color: var(--text-strong);
}

.stat__num .accent {
  color: var(--accent-readable);
}

.stat__num--sm {
  font-size: 2rem;
  letter-spacing: -0.08rem;
}

.stat__label {
  margin: 0.375rem 0 0;
  font-size: var(--font-size-small);
  line-height: var(--line-height-small);
  color: var(--text-muted);
}

.meta-list {
  margin-top: 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.meta-row {
  display: flex;
  align-items: center;
  gap: var(--space-s);
  padding: 0.875rem 0 0.9375rem;
  border-bottom: var(--stroke-weight-1) solid var(--border-subtle);
  font-size: 0.8813rem;
  color: var(--text-muted);
}

.meta-row:last-child {
  border-bottom: none;
}

.meta-row img {
  width: 0.9375rem;
  height: 0.9375rem;
  flex-shrink: 0;
}

/* ---------- Services ---------- */
.services {
  padding: var(--space-section-y) 0;
}

.services__head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--space-m);
}

.section-head-block {
  display: flex;
  flex-direction: column;
  gap: 3.75rem;
}

.service-list {
  margin-top: 4rem;
}

@media (min-width: 56.25rem) {
  .services .section-head-block {
    max-width: 34.5625rem;
  }
}

.service-item {
  border-top: var(--stroke-weight-1) solid var(--border-subtle);
  padding-bottom: 0;
}

.service-item:last-child {
  border-bottom: var(--stroke-weight-1) solid var(--border-subtle);
}

.service-item__heading {
  margin: 0;
  font: inherit;
}

.service-item__trigger {
  display: grid;
  grid-template-columns: 1.75rem 1fr 3rem;
  gap: 1.5rem;
  align-items: center;
  width: 100%;
  min-height: 6.1875rem;
  padding: 0.75rem 0;
  border: none;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
  border-radius: 0.5rem;
}

.service-item__trigger:focus-visible {
  outline: 0.125rem solid var(--color-daisy-bush);
  outline-offset: 0.25rem;
}

.service-item__idx {
  font-weight: 600;
  font-size: 0.9375rem;
  color: var(--accent-readable);
}

.service-item__title {
  margin: 0;
  font-weight: 600;
  font-size: 2.1875rem;
  line-height: 2.1875rem;
  color: var(--color-satin-linen-70);
}

.service-item__icon {
  width: 3rem;
  height: 3rem;
  border-radius: 62.4375rem;
  border: var(--stroke-weight-1) solid var(--color-white-12);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  pointer-events: none;
  background-color: var(--color-haiti);
  transition: transform 0.3s ease;
}

.service-item__icon svg {
  width: 1.25rem;
  height: 1.25rem;
  stroke: var(--text-strong);
  color: var(--text-strong);
  transition: transform 0.3s ease;
}

.service-item.is-open .service-item__icon {
  transform: rotate(45deg);
  background-color: var(--color-daisy-bush);
}

.service-item__panel {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.35s ease;
}

.service-item.is-open .service-item__panel {
  grid-template-rows: 1fr;
}

@media (prefers-reduced-motion: reduce) {
  .service-item__panel {
    transition: none;
  }

  .service-item__icon svg {
    transition: none;
  }
}

.service-item__panel > .service-item__body {
  overflow: hidden;
  min-height: 0;
}

.service-item__body {
  gap: 3rem;
  padding: 0 0 1.5rem 3.25rem;
}

.service-item__copy {
  font-size: var(--font-size-body);
  line-height: var(--line-height-body);
  color: var(--text-muted);
}

.service-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.5rem;
}

.tag {
  padding: 0.25rem 0.6875rem;
  border-radius: 62.4375rem;
  background: rgba(86, 40, 143, 0.15);
  border: var(--stroke-weight-1) solid var(--color-white-12);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--accent-readable);
}

/* ---------- AI Workflow ---------- */
.ai-stack {
  padding: var(--space-section-y) 0;
}

.ai-stack__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--space-m);
  margin-bottom: 4rem;
}

.ai-stack__head .section-head-block {
  max-width: 42rem;
}

.ai-stack__sub {
  max-width: 24rem;
  margin: 0;
  font-size: var(--font-size-body);
  line-height: var(--line-height-body);
  text-align: right;
  color: var(--text-muted);
}

.ai-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.5rem;
}

.ai-card {
  min-height: 11rem;
  padding: 2rem;
  border-radius: 0.5rem;
  border: var(--stroke-weight-1) solid var(--border-subtle);
  background: var(--surface-elevated);
  transition: border-color 0.25s ease, transform 0.25s ease;
}

.ai-card:hover {
  transform: translateY(-0.25rem);
  border-color: var(--color-white-12);
}

.ai-card__title {
  margin: 0 0 0.75rem;
  font-weight: 600;
  font-size: 1.25rem;
  line-height: 1.5rem;
  color: var(--text-strong);
}

.ai-card__desc {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.5rem;
  color: var(--text-muted);
}

/* ---------- Portfolio ---------- */
.portfolio {
  padding: var(--space-section-y) 0;
}

.portfolio__head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: var(--space-m);
  flex-wrap: wrap;
}

.portfolio__head .section-head-block {
  max-width: 21.75rem;
}

.link-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4375rem;
  height: 2.5625rem;
  padding: 0.75rem 1.4375rem;
  border-radius: var(--radius-pill);
  border: var(--stroke-weight-1) solid var(--color-white-12);
  font-weight: 600;
  font-size: 0.8188rem;
  letter-spacing: 0.1148rem;
  text-transform: uppercase;
  color: var(--text-strong);
}

.link-btn img {
  width: 0.875rem;
  height: 0.875rem;
}

.case {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1.5rem, 4vw, 4rem);
  align-items: center;
  padding: clamp(2.5rem, 6vw, 4.5rem) 0 0;
  min-height: 0;
}

.case--flip .case__visual {
  order: 2;
}

.case--flip .case__copy {
  order: 1;
}

.case__eyebrow {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  margin-bottom: 0.75rem;
}

.case__eyebrow-line {
  width: 1rem;
  height: 0.0625rem;
  background: var(--color-dusty-gray);
}

.case__eyebrow-text {
  font-size: var(--font-size-label);
  letter-spacing: 0.08rem;
  text-transform: uppercase;
  color: var(--text-muted);
}

.case__desc {
  margin-top: 0.75rem;
  font-size: var(--font-size-body);
  line-height: var(--line-height-body);
  color: var(--text-muted);
}

.case__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.5rem;
}

.case__tag {
  padding: 0.25rem 0.6875rem;
  border-radius: 62.4375rem;
  background: rgba(86, 40, 143, 0.15);
  border: var(--stroke-weight-1) solid var(--color-white-12);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--accent-readable);
}

.case__locale {
  display: inline-flex;
  margin-top: 1rem;
  padding: 0.3125rem 0.8125rem;
  border-radius: 62.4375rem;
  border: var(--stroke-weight-1) solid var(--color-white-12);
  font-size: var(--font-size-label);
  color: var(--text-muted);
}

.case__cta {
  margin-top: 1.5rem;
}

.carousel {
  position: relative;
  border-radius: 0.75rem;
  overflow: hidden;
  background: var(--color-grey-10);
}

.carousel__viewport {
  aspect-ratio: 560 / 420;
  overflow: hidden;
}

.carousel__slides {
  display: flex;
  height: 100%;
  transition: transform 0.35s ease;
  will-change: transform;
}

.carousel__slide {
  flex: 0 0 100%;
  height: 100%;
}

.carousel__slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
}

.carousel__nav {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 0.875rem;
  pointer-events: none;
}

.carousel__btn {
  pointer-events: auto;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 62.4375rem;
  background: rgba(17, 8, 29, 0.55);
  border: var(--stroke-weight-1) solid var(--color-white-12);
  color: var(--color-white);
  font-size: 1.125rem;
  line-height: 1.125rem;
}

.carousel__dots {
  position: absolute;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  display: flex;
  justify-content: center;
  gap: 0.625rem;
}

.carousel__dot {
  width: 0.4375rem;
  height: 0.4375rem;
  border-radius: 62.4375rem;
  background: var(--color-white-12);
  border: none;
  padding: 0;
  cursor: pointer;
}

.carousel__dot.is-active {
  background: var(--color-white);
}

.carousel--single .carousel__nav,
.carousel--single .carousel__dots {
  display: none;
}

/* ---------- Experience ---------- */
.experience {
  padding: var(--space-section-y) 0;
}

.experience__head {
  display: grid;
  grid-template-columns: 1fr 21.25rem;
  gap: var(--space-m);
  align-items: end;
}

.experience__aside {
  font-size: 0.95rem;
  line-height: 1.5rem;
  color: var(--text-muted);
  text-align: right;
  padding-bottom: 0.5rem;
}

.job {
  display: grid;
  grid-template-columns: 12.5rem 1fr;
  gap: 3rem;
  padding: 2.5rem 0;
  border-top: var(--stroke-weight-1) solid var(--border-subtle);
}

.job:last-child {
  border-bottom: 0;
}

.job__dates {
  font-size: 1rem;
  line-height: 1rem;
  color: var(--text-strong);
}

.badge {
  display: inline-flex;
  margin-top: 0.75rem;
  padding: 0.25rem 0.6875rem;
  border-radius: 999rem;
  border: var(--stroke-weight-1) solid var(--color-white-12);
  font-size: 0.875rem;
  color: var(--text-muted);
  background-color: var(--color-bg-badge);
}

.job__body p {
  margin: 0 0 0.5rem;
  font-size: var(--font-size-body);
  line-height: var(--line-height-body);
  color: var(--text-muted);
}

.job__company {
  font-size: 0.8813rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.job__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4375rem;
  margin-top: 1rem;
}

.job__tags span {
  padding: 0.25rem 0.6875rem;
  border-radius: 62.4375rem;
  background: rgba(86, 40, 143, 0.15);
  border: var(--stroke-weight-1) solid var(--color-white-12);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--accent-readable);
}

/* ---------- Contact ---------- */
.contact {
  padding: var(--space-section-y) 0;
}

.contact__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xl);
  margin-top: var(--space-m);
}

.contact__title {
  margin: 0;
  font-weight: 700;
  font-size: 3.2rem;
  line-height: 3.5rem;
  letter-spacing: var(--letter-spacing-h2);
  color: var(--text-strong);
}

.contact__lede {
  margin-top: 1.5rem;
  font-size: var(--font-size-body-lg);
  line-height: var(--line-height-body-lg);
  color: var(--text-muted);
}

.contact__email {
  display: inline-block;
  margin-top: 1.5rem;
  font-weight: 700;
  font-size: 1.375rem;
  color: var(--text-strong);
}

.contact__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.625rem;
  margin-top: 1.5rem;
  flex-direction: column;
}

.contact-meta {
  border-top: var(--stroke-weight-1) solid var(--border-subtle);
}

.contact-row {
  display: grid;
  grid-template-columns: 5rem 1fr;
  gap: 0.875rem;
  padding: 1.125rem 0;
  border-bottom: var(--stroke-weight-1) solid var(--border-subtle);
  font-size: 0.875rem;
}

.contact-row__label {
  color: var(--text-muted);
  text-transform: capitalize;
}

.contact-row__value {
  color: var(--text-muted);
}

.social-block {
  margin-top: 2.5rem;
}

.social-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.125rem 0;
  border-top: var(--stroke-weight-1) solid var(--border-subtle);
  font-size: 0.8813rem;
}

.social-row:last-child {
  border-bottom: var(--stroke-weight-1) solid var(--border-subtle);
}

.social-row a {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  color: var(--text-muted);
}

.social-row img {
  width: 1rem;
  height: 1rem;
}

.social-row a {
  padding: 16px;
}

/* ---------- Footer ---------- */
.footer {
  padding: 2.5rem 0;
  border-top: var(--stroke-weight-1) solid var(--border-subtle);
}

.footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-m);
  flex-wrap: wrap;
}

.footer__name {
  font-weight: 700;
  font-size: 0.9375rem;
  color: var(--text-strong);
}

.footer__role {
  margin-top: 0.25rem;
  font-size: 1rem;
  color: var(--text-muted);
}

.footer__copy {
  font-size: 1rem;
  color: var(--text-muted);
}

.backtotop {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9375rem;
  color: var(--accent-readable);
}

.backtotop__arrow {
  width: 0.8125rem;
  height: 0.8125rem;
  border-right: 0.125rem solid currentColor;
  border-bottom: 0.125rem solid currentColor;
  transform: rotate(-135deg);
}

/* ---------- Background noise layer ---------- */
.bg-noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: var(--opacity-grid);
  z-index: -1;
}

.bg-noise img {
  width: 12.5rem;
  height: 12.5rem;
}

/* ---------- Project case study page ---------- */
.project-page {
  padding-top: 2rem;
}

.project-hero {
  padding: 7rem 0 4.5rem;
}

.project-back {
  margin-bottom: 2rem;
}

.project-hero__title {
  max-width: 56rem;
  margin: 3rem 0 0;
  font-weight: 700;
  font-size: clamp(3rem, 8vw, 5.5rem);
  line-height: 0.98;
  letter-spacing: -0.22rem;
  color: var(--text-strong);
}

.project-hero__lede {
  max-width: 42rem;
  margin: 2rem 0 0;
  font-size: 1.1rem;
  line-height: 1.8rem;
  color: var(--text-muted);
}

.project-hero__tags {
  margin-top: 2rem;
}

.project-media {
  padding: 4rem 0;
}

.project-figure {
  margin: 0;
  overflow: hidden;
  border-radius: 0.75rem;
  border: var(--stroke-weight-1) solid var(--border-subtle);
  background: var(--surface-elevated);
}

.project-figure img {
  width: 100%;
  height: auto;
  object-fit: contain;
}

.project-figure--hero img {
  aspect-ratio: 16 / 9;
  object-fit: cover;
  object-position: top;
}

.project-meta {
  padding: 0;
}

.project-meta__grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 2rem;
  margin: 0;
  padding: 2rem 0;
  border-top: var(--stroke-weight-1) solid var(--border-subtle);
  border-bottom: var(--stroke-weight-1) solid var(--border-subtle);
}

.project-meta__grid dt {
  margin-bottom: 0.5rem;
  font-size: var(--font-size-label);
  font-weight: 700;
  letter-spacing: var(--letter-spacing-upper);
  text-transform: uppercase;
  color: var(--accent-readable);
}

.project-meta__grid dd {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.35rem;
  color: var(--text-strong);
}

.project-section {
  padding: var(--space-section-y) 0;
}

.project-split {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(2rem, 6vw, 5rem);
  align-items: start;
}

.project-eyebrow {
  display: block;
  margin-bottom: 1rem;
  color: var(--accent-readable);
}

.project-copy {
  margin: 1.25rem 0 0;
  max-width: 44rem;
  font-size: var(--font-size-body);
  line-height: var(--line-height-body);
  color: var(--text-muted);
}

.project-impact {
  padding: 6.25rem 0;
}

.project-impact__card {
  overflow: hidden;
  border-radius: 0.75rem;
  border: var(--stroke-weight-1) solid var(--border-subtle);
  background: var(--surface-elevated);
}

.project-impact__intro {
  max-width: 45rem;
  margin: 0 auto;
  padding: 4.5rem 2rem 3.5rem;
  text-align: center;
}

.project-impact__intro .project-copy {
  margin-right: auto;
  margin-left: auto;
}

.project-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 0;
  border-top: var(--stroke-weight-1) solid var(--border-subtle);
}

.project-stats div {
  padding: 2.5rem 1.5rem;
  border-right: var(--stroke-weight-1) solid var(--border-subtle);
  text-align: center;
}

.project-stats div:last-child {
  border-right: 0;
}

.project-stats dt {
  margin-bottom: 0.75rem;
  font-size: var(--font-size-label);
  font-weight: 700;
  letter-spacing: var(--letter-spacing-upper);
  text-transform: uppercase;
  color: var(--accent-readable);
}

.project-stats dd {
  margin: 0;
  font-weight: 800;
  font-size: clamp(2rem, 4vw, 3.75rem);
  line-height: 1;
  letter-spacing: -0.12rem;
  color: var(--text-strong);
}

.project-stats p {
  max-width: 13rem;
  margin: 1rem auto 0;
  font-size: 0.875rem;
  line-height: 1.35rem;
  color: var(--text-muted);
}

.project-narrative {
  display: flex;
  flex-direction: column;
  gap: 8rem;
}

.project-chapter {
  scroll-margin-top: 7rem;
}

.project-chapter__body,
.project-section__intro,
.project-closing {
  max-width: 48rem;
  margin: 0 auto 2.5rem;
}

.project-chapter .project-figure {
  margin-top: 2rem;
}

.project-card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 2.5rem;
}

.project-card {
  padding: 1.5rem;
  border-radius: 0.5rem;
  border: var(--stroke-weight-1) solid var(--border-subtle);
  background: var(--surface-elevated);
}

.project-card p {
  margin: 1rem 0 0;
  font-size: 0.95rem;
  line-height: 1.5rem;
  color: var(--text-muted);
}

.project-showcase {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.project-showcase .project-figure:first-child {
  grid-column: 1 / -1;
}

.project-closing {
  text-align: center;
}

.project-closing .project-copy {
  margin-right: auto;
  margin-left: auto;
}

.project-next {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
  margin-top: 2rem;
}

.project-toc {
  position: fixed;
  top: 8.5rem;
  left: max(1rem, calc((100vw - var(--container-max)) / 2 - 10rem));
  z-index: 80;
  width: 8rem;
  padding: 0.75rem 0;
  color: var(--text-muted);
}

.project-toc__label {
  margin: 0 0 0.75rem;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: var(--letter-spacing-upper);
  text-transform: uppercase;
  color: var(--accent-readable);
}

.project-toc ol {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.project-toc a {
  font-size: 0.75rem;
  line-height: 1.1rem;
  color: var(--text-muted);
}

.project-toc a:hover {
  color: var(--text-strong);
}

/* ---------- Responsive ---------- */
[data-theme="light"] .nav {
  background: color-mix(in srgb, var(--page-bg) 94%, #ffffff);
}

[data-theme="light"] .brand,
[data-theme="light"] .hero__title-line,
[data-theme="light"] .h2,
[data-theme="light"] .h3,
[data-theme="light"] .quote,
[data-theme="light"] .stat__num,
[data-theme="light"] .stat__num--sm,
[data-theme="light"] .service-item__title,
[data-theme="light"] .job__dates,
[data-theme="light"] .contact__title,
[data-theme="light"] .contact__email,
[data-theme="light"] .footer__name {
  color: var(--text-strong);
}

[data-theme="light"] .nav__link:hover,
[data-theme="light"] .link-btn,
[data-theme="light"] .section-label,
[data-theme="light"] .body-col p,
[data-theme="light"] .stat__label,
[data-theme="light"] .meta-row,
[data-theme="light"] .service-item__copy,
[data-theme="light"] .case__eyebrow-text,
[data-theme="light"] .case__desc,
[data-theme="light"] .case__locale,
[data-theme="light"] .ai-stack__sub,
[data-theme="light"] .ai-card__desc,
[data-theme="light"] .project-hero__lede,
[data-theme="light"] .project-copy,
[data-theme="light"] .project-stats p,
[data-theme="light"] .project-card p,
[data-theme="light"] .project-toc,
[data-theme="light"] .project-toc a,
[data-theme="light"] .job__body p,
[data-theme="light"] .job__company,
[data-theme="light"] .contact__lede,
[data-theme="light"] .contact-row__value,
[data-theme="light"] .social-row,
[data-theme="light"] .social-row a,
[data-theme="light"] .footer__role,
[data-theme="light"] .footer__copy {
  color: var(--text-muted);
}

[data-theme="light"] .btn-primary,
[data-theme="light"] .btn-cta {
  color: var(--color-white);
}

[data-theme="light"] .icon-btn,
[data-theme="light"] .btn-cta,
[data-theme="light"] .btn-primary,
[data-theme="light"] .link-btn,
[data-theme="light"] .section-label,
[data-theme="light"] .service-item__icon,
[data-theme="light"] .badge,
[data-theme="light"] .case__tag,
[data-theme="light"] .case__locale,
[data-theme="light"] .ai-card,
[data-theme="light"] .project-figure,
[data-theme="light"] .project-impact__card,
[data-theme="light"] .project-card,
[data-theme="light"] .job__tags span {
  border-color: var(--border-subtle);
}

[data-theme="light"] .nav__burger-line {
  background: var(--text-strong);
}

[data-theme="light"] .avatar-ring,
[data-theme="light"] .carousel,
[data-theme="light"] .ai-card,
[data-theme="light"] .project-figure,
[data-theme="light"] .project-impact__card,
[data-theme="light"] .project-card {
  background: var(--surface-elevated);
}

[data-theme="light"] .service-item__icon {
  background-color: var(--surface-elevated);
}

[data-theme="light"] .service-item__icon svg {
  stroke: var(--color-haiti);
  color: var(--color-haiti);
}

[data-theme="light"] .service-item.is-open .service-item__icon svg {
  stroke: var(--color-white);
  color: var(--color-white);
}

[data-theme="light"] .hero__title-line--muted {
  color: var(--hero-muted-word);
}

[data-theme="light"] .nav__link {
  color: var(--text-muted);
}

[data-theme="light"] .carousel__btn {
  background: rgba(255, 255, 255, 0.65);
  color: var(--color-haiti);
}

@media (max-width: 75rem) {
  .hero {
    padding: clamp(0rem, 12vw, 10rem) 0 clamp(3.5rem, 10vw, 7.5rem);
  }

  .hero__grid-top {
    grid-template-columns: 1fr;
    gap: clamp(1.5rem, 5vw, 3rem);
  }

  .hero__title-inner {
    position: relative;
    left: 0;
    top: 0;
    transform: none;
  }

  .hero__title {
    min-height: 0;
  }

  .hero__title-line {
    font-size: clamp(2.5rem, 8vw, 6rem);
    line-height: clamp(2.625rem, 8.4vw, 6.3rem);
    letter-spacing: clamp(-0.1875rem, -0.5vw, -0.36rem);
  }

  .about__grid,
  .contact__grid {
    grid-template-columns: 1fr;
  }

  .experience__head {
    grid-template-columns: 1fr;
  }

  .experience__aside {
    text-align: left;
    padding-bottom: 0;
  }

  .case {
    gap: clamp(1.5rem, 5vw, 2.5rem);
    padding-top: clamp(2rem, 6vw, 3.5rem);
  }

  .hero__grid-bottom {
    grid-template-columns: 1fr;
    gap: clamp(1.5rem, 4vw, 3rem);
    align-items: stretch;
  }

  .hero__actions {
    justify-content: flex-start;
  }

  .stats {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(0.75rem, 3vw, 1.5rem);
  }

  .portfolio__head {
    align-items: flex-start;
  }

  .project-toc {
    display: none;
  }

  .project-meta__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  /* Mobile navigation drawer */
  .nav {
    z-index: 200;
  }

  .nav__burger {
    display: inline-flex;
    margin-left: 0;
    position: relative;
    z-index: 220;
  }

  .nav__links {
    position: fixed;
    inset: 0;
    z-index: 180;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: clamp(0.5rem, 2vw, 0.875rem);
    margin: 0;
    padding: calc(env(safe-area-inset-top, 0rem) + 5.5rem) clamp(1.25rem, 5vw, 3rem)
      calc(env(safe-area-inset-bottom, 0rem) + 2rem);
    width: 100%;
    max-width: 100%;
    min-height: 100vh;
    min-height: 100dvh;
    background: color-mix(in srgb, var(--page-bg) 86%, transparent);
    backdrop-filter: blur(1rem);
    -webkit-backdrop-filter: blur(1rem);
    opacity: 0;
    transform: translateY(-0.75rem) scale(0.98);
    visibility: hidden;
    transition: opacity 0.3s ease, transform 0.35s ease, visibility 0.35s;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  .nav.nav--open .nav__links {
    opacity: 1;
    transform: translateY(0) scale(1);
    visibility: visible;
  }

  .nav__link {
    width: min(24rem, 100%);
    padding: 1rem 1.25rem;
    border-radius: 0.75rem;
    border: var(--stroke-weight-1) solid var(--border-subtle);
    background: color-mix(in srgb, var(--surface-elevated) 76%, transparent);
    text-align: center;
    font-size: clamp(1.1rem, 4vw, 1.75rem);
  }
}

.nav__overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 170;
  background: rgba(0, 0, 0, 0.103);
  backdrop-filter: blur(0.5rem);
  -webkit-backdrop-filter: blur(0.5rem);
}

body.nav-menu-open .nav__overlay {
  display: block;
}

@media (max-width: 75rem) and (prefers-reduced-motion: reduce) {
  .nav__links {
    transition: none;
  }
}

@media (max-width: 56.25rem) {
  .h2,
  .contact__title {
    font-size: clamp(1.75rem, 7vw, 2.75rem);
    line-height: clamp(1.96rem, 7.84vw, 3.08rem);
    letter-spacing: -0.04rem;
  }

  .quote {
    font-size: clamp(1.375rem, 5vw, 2rem);
    line-height: clamp(1.8563rem, 6.75vw, 2.7rem);
    padding-left: 1.25rem;
  }

  .job {
    grid-template-columns: 1fr;
    gap: 1rem;
    padding: 1.75rem 0;
  }

  .job__dates {
    padding-bottom: 0.75rem;
    border-bottom: var(--stroke-weight-1) solid var(--border-subtle);
  }

  /* Recent Work (portfolio) — ≤56.25rem */
  .portfolio__head {
    flex-direction: column;
    align-items: stretch;
    gap: clamp(1rem, 4vw, 1.5rem);
  }

  .portfolio__head .section-head-block {
    max-width: none;
    width: 100%;
  }

  .portfolio__cta.link-btn {
    align-self: flex-start;
    max-width: 100%;
    min-height: 2.75rem;
    flex-wrap: wrap;
    white-space: normal;
    text-align: center;
    justify-content: center;
    padding-inline: clamp(0.875rem, 4vw, 1.4375rem);
  }

  .case {
    grid-template-columns: 1fr;
    gap: clamp(1.25rem, 5vw, 1.75rem);
    padding-top: clamp(1.5rem, 7vw, 2.5rem);
  }

  .case--flip .case__visual,
  .case--flip .case__copy {
    order: unset;
  }

  .case__visual {
    min-width: 0;
    width: 100%;
  }

  .case__copy {
    min-width: 0;
  }

  .case .h3 {
    font-size: clamp(1.35rem, 5.5vw, 1.75rem);
    line-height: clamp(1.5525rem, 6.325vw, 2.0125rem);
    letter-spacing: -0.03rem;
    word-break: break-word;
    overflow-wrap: anywhere;
  }

  .case__eyebrow {
    flex-wrap: wrap;
    align-items: flex-start;
    row-gap: 0.375rem;
  }

  .case__eyebrow-text {
    font-size: 0.75rem;
    line-height: 1.0125rem;
    flex: 1 1 12rem;
    min-width: 0;
    overflow-wrap: anywhere;
    hyphens: auto;
  }

  .case__desc {
    font-size: clamp(0.9375rem, 3.6vw, 1rem);
    line-height: clamp(1.4531rem, 5.58vw, 1.55rem);
  }

  .project-hero {
    padding: 5rem 0 3.5rem;
  }

  .project-hero__title {
    letter-spacing: -0.12rem;
  }

  .project-split,
  .project-card-grid,
  .project-showcase {
    grid-template-columns: 1fr;
  }

  .project-meta__grid,
  .project-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .project-stats div:nth-child(2n) {
    border-right: 0;
  }

  .project-stats div:nth-child(n + 3) {
    border-top: var(--stroke-weight-1) solid var(--border-subtle);
  }

  .project-narrative {
    gap: 5rem;
  }

  .case__tags {
    gap: 0.375rem;
    margin-top: clamp(1rem, 4vw, 1.5rem);
  }

  .case__tag {
    font-size: 0.8125rem;
    padding: 0.3125rem 0.625rem;
    max-width: 100%;
    overflow-wrap: anywhere;
  }

  .case__cta .btn-primary {
    max-width: 100%;
    flex-wrap: wrap;
    justify-content: center;
    white-space: normal;
    text-align: center;
    min-height: 2.75rem;
    height: auto;
    padding-block: 0.625rem;
    width: 100%;
  }

  .carousel {
    width: 100%;
    max-width: 100%;
  }

  .carousel__viewport {
    aspect-ratio: 4 / 3;
    max-height: min(70vw, 26.25rem);
  }

  .carousel__nav {
    padding: 0 clamp(0.375rem, 2vw, 0.875rem);
  }

  .carousel__dots {
    left: 0.625rem;
    right: 0.625rem;
    bottom: 0.75rem;
    gap: 0.5rem;
    flex-wrap: wrap;
    justify-content: center;
  }

  .avatar-ring {
    width: min(17.5rem, 85vw);
    height: min(17.5rem, 85vw);
  }
}

@media (max-width: 40rem) {
  .about,
  .services,
  .portfolio,
  .experience,
  .contact,
  .project-section,
  .project-impact {
    padding-top: clamp(3rem, 12vw, 4.5rem);
    padding-bottom: clamp(3rem, 12vw, 4.5rem);
  }

  .about {
    padding-bottom: clamp(3.5rem, 14vw, 6.3125rem);
  }

  .section-head-block {
    gap: 1.75rem;
  }

  .project-page {
    padding-top: 0;
  }

  .project-meta__grid,
  .project-stats {
    grid-template-columns: 1fr;
  }

  .project-stats div,
  .project-stats div:nth-child(2n) {
    border-right: 0;
  }

  .project-stats div:nth-child(n + 2) {
    border-top: var(--stroke-weight-1) solid var(--border-subtle);
  }

  .project-impact__intro {
    padding: 3rem 1.5rem 2.5rem;
  }

  .project-media {
    padding: 2.5rem 0;
  }

  .project-next {
    flex-direction: column;
    align-items: stretch;
  }

  .project-next .btn-primary,
  .project-next .link-btn {
    justify-content: center;
    width: 100%;
  }

  .service-list {
    margin-top: 2.5rem;
  }

  .service-item__trigger {
    grid-template-columns: 1.375rem 1fr 2.75rem;
    gap: 0.75rem;
    min-height: 0;
    padding: 0.875rem 0;
    align-items: start;
  }

  .service-item__title {
    font-size: clamp(1.125rem, 4.5vw, 2rem);
    line-height: clamp(1.35rem, 5.4vw, 2.4rem);
    hyphens: auto;
    overflow-wrap: anywhere;
  }

  .service-item__body {
    padding-left: 0;
    padding-bottom: 1.25rem;
  }

  .service-item__icon {
    width: 2.75rem;
    height: 2.75rem;
  }

  .stats {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 1.25rem;
    padding-top: 1.75rem;
  }

  .stat__num,
  .stat__num--sm {
    font-size: clamp(1.75rem, 8vw, 2.6rem);
  }

  .contact__email {
    font-size: clamp(1rem, 4vw, 1.375rem);
    word-break: break-word;
  }

  .contact__actions {
    flex-direction: column;
    align-items: stretch;
  }

  .contact__actions .btn-primary,
  .contact__actions .link-btn {
    justify-content: center;
    width: 100%;
  }

  .social-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.625rem;
  }

  .social-row a {
    max-width: 100%;
    word-break: break-all;
  }

  .footer__inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 1.25rem;
  }

  .carousel__btn {
    width: 2.75rem;
    height: 2.75rem;
  }

  .btn-cta {
    padding: 0.625rem 0.875rem;
    font-size: 0.6875rem;
    letter-spacing: 0.12rem;
  }

  .icon-btn {
    width: 2.75rem;
    height: 2.75rem;
  }
}

@media (max-width: 30rem) {
  .hero__title-line {
    font-size: clamp(2rem, 10vw, 4rem);
  }

  .contact-row {
    grid-template-columns: 1fr;
    gap: 0.375rem;
    padding: 0.875rem 0;
  }

  .contact-row__label {
    font-size: 0.75rem;
  }

  .portfolio__head .portfolio__cta,
  .portfolio__head .link-btn {
    width: 100%;
    justify-content: center;
  }

  .meta-row {
    align-items: flex-start;
    font-size: 0.8125rem;
  }
}

.proj-img {
  width: 200px;
}

.logonav {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 8px;
}

.logonav img {
  width: 32px;
  height: 32px
}

@media (max-width: 56.25rem) {
  .ai-stack__head {
    flex-direction: column;
    align-items: flex-start;
    gap: clamp(1rem, 4vw, 1.5rem);
    margin-bottom: 2.5rem;
  }

  .ai-stack__sub {
    max-width: 100%;
    text-align: left;
  }

  .ai-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
  }

  .ai-card {
    padding: 1.5rem;
  }
}

@media (max-width: 40rem) {
  .ai-stack {
    padding-top: clamp(3rem, 12vw, 4.5rem);
    padding-bottom: clamp(3rem, 12vw, 4.5rem);
  }

  .ai-grid {
    grid-template-columns: 1fr;
  }

  .ai-card {
    min-height: auto;
  }
}
  
