/* Shared shell for the hand-authored home and contact pages. */

html {
  scroll-behavior: smooth;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--pb-bg-raised);
  color: var(--pb-fg-body);
  font-family: var(--pb-font-body);
  font-size: var(--pb-text-md);
  line-height: var(--pb-leading-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

a {
  color: inherit;
}

::selection {
  background: var(--pb-paper-300);
  color: var(--pb-fg);
}

a:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--pb-accent);
  outline-offset: 4px;
}

.site-nav {
  position: relative;
  z-index: 10;
  display: flex;
  min-height: 88px;
  align-items: center;
  justify-content: space-between;
  padding: 20px max(24px, calc((100% - var(--pb-page-max)) / 2 + var(--pb-page-pad)));
  border-bottom: 1px solid var(--pb-rule);
  background: var(--pb-bg-raised);
}

.site-nav__mark {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}

.site-nav__mark img {
  width: 152px;
  height: auto;
  transform: rotate(1.5deg);
}

.site-nav__links {
  display: flex;
  align-items: center;
  gap: 26px;
}

.site-nav__links a,
.site-nav__menu a {
  color: var(--pb-fg-muted);
  font-family: var(--pb-font-display);
  font-size: 17px;
  text-decoration: none;
  transition: color 160ms ease;
}

.site-nav__links a[aria-current="page"] {
  color: var(--pb-fg);
  text-decoration: underline;
  text-decoration-color: color-mix(in srgb, var(--pb-accent) 55%, transparent);
  text-decoration-thickness: 1px;
  text-underline-offset: 5px;
}

.site-nav__links a:hover,
.site-nav__menu a:hover {
  color: var(--pb-accent);
}

.site-nav__menu {
  display: none;
}

.site-nav__menu summary {
  width: 34px;
  height: 34px;
  padding: 7px 4px;
  cursor: pointer;
  list-style: none;
}

.site-nav__menu summary::-webkit-details-marker {
  display: none;
}

.site-nav__menu summary::before,
.site-nav__menu summary::after {
  content: "";
  display: block;
  width: 23px;
  height: 1px;
  margin: 5px auto;
  background: var(--pb-fg-muted);
  box-shadow: 0 6px 0 var(--pb-fg-muted);
}

.site-nav__menu summary::after {
  display: none;
}

.site-nav__menu[open] summary::before {
  margin-top: 9px;
  transform: rotate(45deg);
  box-shadow: none;
}

.site-nav__menu[open] summary::after {
  display: block;
  margin-top: -6px;
  transform: rotate(-45deg);
}

.site-nav__menu-panel {
  position: absolute;
  top: 79px;
  right: 0;
  left: 0;
  display: grid;
  gap: 0;
  padding: 12px 24px 20px;
  border-bottom: 1px solid var(--pb-rule);
  background: var(--pb-bg-raised);
}

.site-nav__menu-panel a {
  padding: 10px 0;
}

.home-main h1,
.home-main h2,
.home-main h3,
.home-main p {
  margin-top: 0;
}

.project-kicker {
  margin-bottom: 12px;
  color: var(--pb-fg-muted);
  font-size: var(--pb-text-sm);
  font-weight: 400;
  letter-spacing: 0.0em;
  line-height: 1.4;
}

.project-title {
  margin-bottom: 14px;
  color: var(--pb-fg-body);
  font-family: var(--pb-font-display);
  font-size: clamp(30px, 2.65vw, 36px);
  font-weight: 400;
  line-height: 1.2;
}

.project-title a {
  text-decoration: none;
  transition: color 180ms ease;
}

.project-copy {
  max-width: 52ch;
  margin-bottom: 20px;
  color: var(--pb-fg-muted);
  font-size: 16px;
  line-height: 1.6;
}

.project-link {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 9px 17px;
  border-radius: 6px;
  background: var(--pb-bg-recessed);
  color: var(--pb-accent-strong);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.project-link:hover {
  background: var(--pb-paper-300);
  box-shadow: 0 5px 14px rgba(41, 40, 36, 0.08);
  transform: translateY(-1px);

}

.feature-grid {
  display: grid;
  grid-template-columns: 1.04fr 0.96fr;
}

.feature-primary {
  display: grid;
  grid-template-columns: minmax(0, 490px);
  align-content: start;
  justify-content: end;
  min-width: 0;
  padding: 76px clamp(40px, 6.25vw, 80px) 72px;
  background: var(--pb-technical);
  color: #fff;
}

.feature-primary .project-kicker,
.feature-primary .project-title,
.feature-primary .project-copy {
  color: #fff;
}

.feature-primary .project-kicker {
  color: rgba(255, 255, 255, 0.82);
}

.feature-primary .project-title {
  max-width: none;
  margin-bottom: 30px;
  font-size: clamp(42px, 3.75vw, 48px);
  line-height: 1.04;
}

.feature-primary__media {
  display: block;
  margin-bottom: 24px;
  overflow: hidden;
  border-radius: 14px;
  background: #dce1e5;
  box-shadow: var(--pb-shadow-media);
}

.feature-primary__media video {
  width: 100%;
  aspect-ratio: 1.91 / 1;
  object-fit: cover;
  transition: transform 360ms cubic-bezier(0.2, 0.7, 0.2, 1);
}

.feature-primary .project-copy {
  max-width: 470px;
}

.feature-primary .project-link {
  justify-self: start;
  background: rgba(55, 64, 85, 0.72);
  color: #fff;
}

.feature-primary .project-link:hover {
  background: rgba(55, 64, 85, 0.9);
}

.feature-secondary {
  display: grid;
  align-content: center;
  gap: 36px;
  padding: 76px clamp(40px, 6vw, 78px);
  background: var(--pb-bg);
}

.feature-secondary .project-card + .project-card {
  padding-top: 36px;
  border-top: 1px solid var(--pb-rule);
}

.project-card {
  max-width: 470px;
}

.project-card .project-title a,
.work-grid .project-title a {
  transition: color 180ms ease;
}

.work-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  padding: 96px max(40px, calc((100% - var(--pb-page-max)) / 2 + var(--pb-page-pad)));
  border-top: 1px solid var(--pb-rule);
  background: var(--pb-bg-raised);
}

.work-grid .project-card {
  max-width: 545px;
}

.work-grid .project-link {
  min-height: 0;
  padding: 0;
  border-radius: 0;
  background: transparent;
}

.work-grid .project-link:hover {
  background: transparent;
  box-shadow: 0 5px 14px rgba(41, 40, 36, 0.00);
  transform: translateY(0px);
}


.about {
  display: grid;
  grid-template-columns: 220px minmax(0, 520px);
  justify-content: center;
  align-items: start;
  gap: 64px;
  padding: 104px var(--pb-page-pad);
  border-top: 1px solid var(--pb-rule);
  background: var(--pb-bg-raised);
}

.about img {
  width: 220px;
  height: 220px;
  border-radius: var(--pb-radius-media);
  object-fit: cover;
  box-shadow: var(--pb-shadow-media);
}

.about h2 {
  margin-bottom: 16px;
  color: var(--pb-fg-body);
  font-family: var(--pb-font-display);
  font-size: clamp(38px, 3.5vw, 48px);
  font-weight: 400;
  line-height: 1.2;
}

.about p {
  margin-bottom: 18px;
  color: var(--pb-fg-muted);
  font-size: 17px;
  line-height: 1.65;
}

.about a {
  color: var(--pb-accent-strong);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: color 160ms ease, transform 160ms ease;
}

.results {
  padding: 88px var(--pb-page-pad) 96px;
  background: var(--pb-bg);
}

.results__inner,
.new-work__inner,
.site-footer__inner {
  width: 100%;
  max-width: 1095px;
  margin: 0 auto;
}

.section-label {
  margin-bottom: 36px;
  color: var(--pb-fg-muted);
  font-size: var(--pb-text-xs);
  font-weight: 600;
  letter-spacing: var(--pb-tracking-label);
  text-transform: uppercase;
}

.results__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}

.result {
  min-width: 0;
  padding: 10px 28px 20px;
}

.result:first-child {
  padding-left: 0;
}

.result + .result {
  border-left: 1px solid var(--pb-rule);
}

.result__number {
  margin-bottom: 8px;
  color: var(--pb-fg);
  font-family: var(--pb-font-display);
  font-size: clamp(34px, 3.4vw, 38px);
  font-variant-numeric: lining-nums;
  line-height: 1.12;
  white-space: nowrap;
}

.result:first-child .result__number {
  font-size: clamp(32px, 2.9vw, 38px);
}

.result__copy {
  margin-bottom: 12px;
  color: var(--pb-fg-muted);
  font-size: 14px;
  line-height: 1.6;
}

.result__label,
.new-work__label,
.site-footer__legal {
  color: var(--pb-fg-muted);
  font-family: var(--pb-font-mono);
  font-size: 11px;
  letter-spacing: var(--pb-tracking-label);
  text-transform: uppercase;
}

.new-work {
  padding: 88px var(--pb-page-pad) 104px;
  background: var(--pb-bg);
  border-top: 1px solid var(--pb-rule);
}

.new-work__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
}

.new-work__card {
  padding-top: 20px;
  border-top: 1px solid var(--pb-rule-strong);
  color: inherit;
  text-decoration: none;
  transition: border-color 180ms ease, transform 180ms ease;
}

.new-work__card h3 {
  margin: 8px 0;
  color: var(--pb-fg);
  font-family: var(--pb-font-display);
  font-size: clamp(34px, 3vw, 42px);
  font-weight: 400;
  line-height: 1.12;
}

.new-work__card h3::after {
  content: "";
  color: var(--pb-accent);
  display: inline-block;
  transition: transform 180ms ease;
}

.new-work__card p {
  margin-bottom: 0;
  color: var(--pb-fg-muted);
  max-width: 52ch;
  font-size: 14px;
  line-height: 1.6;
}

.new-work__card:hover h3 {
  color: var(--pb-accent);
}

.new-work__card:hover {
  border-color: var(--pb-accent);
  transform: translateY(-2px);
}

.new-work__card:hover h3::after {
  transform: translateX(4px);
}

.site-footer {
  padding: 0 var(--pb-page-pad);
  background: var(--pb-bg-recessed);
}

.site-footer__cols {
  display: grid;
  grid-template-columns: repeat(3, minmax(140px, 220px));
  gap: 32px;
  padding: 56px 0 40px;
  border-top: 1px solid var(--pb-rule);
}

.site-footer h2 {
  margin: 0 0 12px;
  color: var(--pb-fg-muted);
  font-family: var(--pb-font-display);
  font-size: 24px;
  font-weight: 400;
}

.site-footer ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-footer li {
  margin-bottom: 8px;
}

.site-footer a {
  color: var(--pb-fg-body);
  font-size: 14px;
  text-decoration: none;
  transition: color 160ms ease;
}

.site-footer a:hover {
  color: var(--pb-accent);
}

.site-footer__legal {
  padding: 18px 0 48px;
  border-top: 1px solid var(--pb-rule);
}

.contact-main {
  width: min(100% - 48px, 720px);
  min-height: calc(100vh - 88px);
  margin: 0 auto;
  padding: 112px 0 128px;
}

.page-eyebrow {
  margin: 0 0 16px;
  color: var(--pb-accent);
  font-size: var(--pb-text-xs);
  font-weight: 400;
  letter-spacing: 0.015em;
}

.contact-main h1 {
  margin: 0 0 32px;
  color: var(--pb-fg);
  font-family: var(--pb-font-display);
  font-size: clamp(54px, 6vw, 76px);
  font-weight: 400;
  line-height: 1.1;
}

.contact-main p {
  margin: 0;
  color: var(--pb-fg-muted);
  font-size: 18px;
  line-height: 1.7;
}

.contact-main .page-eyebrow {
  font-size: var(--pb-text-xs);
  line-height: 1.4;
}

.contact-main a {
  color: var(--pb-accent);
  font-weight: 600;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: color 160ms ease, text-underline-offset 160ms ease;
}

@media (hover: hover) and (pointer: fine) {
  .feature-primary .project-title a:hover {
    color: rgba(255, 255, 255, 0.82);
  }

  .feature-primary__media:hover video {
    transform: scale(1.012);
  }

  .project-card:hover .project-title a,
  .work-grid .project-card:hover .project-title a {
    color: var(--pb-accent);
  }

  .about a:hover {
    color: var(--pb-accent);
    transform: translateX(2px);
  }

  .contact-main a:hover {
    color: var(--pb-accent-strong);
    text-underline-offset: 5px;
  }
}

@media (max-width: 900px) {
  .feature-grid,
  .work-grid {
    grid-template-columns: 1fr;
  }

  .feature-primary,
  .feature-secondary,
  .work-grid {
    padding-right: var(--pb-page-pad);
    padding-left: var(--pb-page-pad);
  }

  .feature-secondary {
    gap: 27px;
  }

  .feature-secondary .project-card + .project-card {
    padding-top: 27px;
  }

  .project-card,
  .work-grid .project-card {
    max-width: none;
  }

  .results__grid {
    grid-template-columns: 1fr 1fr;
  }

  .result {
    border-bottom: 1px solid var(--pb-rule);
  }

  .result:nth-child(odd) {
    padding-left: 0;
    border-left: 0;
  }

  .result:nth-last-child(-n + 2) {
    border-bottom: 0;
  }
}

@media (max-width: 600px) {
  .site-nav {
    min-height: 74px;
    padding: 18px 20px;
  }

  .site-nav__mark img {
    width: clamp(112px, 34vw, 136px);
  }

  .site-nav__links {
    display: flex;
    gap: clamp(10px, 3vw, 17px);
  }

  .site-nav__links a {
    font-size: clamp(13px, 4vw, 16px);
  }

  .site-nav__menu {
    display: none;
  }

  .site-nav__menu-panel {
    top: 75px;
  }

  .feature-primary,
  .feature-secondary,
  .work-grid,
  .about,
  .results,
  .new-work {
    padding-right: 24px;
    padding-left: 24px;
  }

  .feature-primary {
    padding-top: 40px;
    padding-bottom: 38px;
  }

  .feature-primary .project-kicker {
    font-size: var(--pb-text-xs);
    line-height: 1.45;
  }

  .feature-primary .project-title {
    margin-bottom: 28px;
    max-width: 14ch;
    font-family: var(--pb-font-display);
    font-size: clamp(38px, 11vw, 46px);
    font-weight: 400;
    line-height: 1.12;
  }

  .feature-primary__media {
    margin-bottom: 20px;
  }

  .feature-secondary {
    padding-top: 54px;
    padding-bottom: 58px;
  }

  .work-grid {
    gap: 58px;
    padding-top: 58px;
    padding-bottom: 62px;
  }

  .project-title {
    font-size: 34px;
  }

  .about {
    grid-template-columns: 1fr;
    gap: 28px;
    padding-top: 58px;
    padding-bottom: 66px;
  }

  .about img {
    width: min(100%, 260px);
    height: min(calc(100vw - 48px), 260px);
  }

  .results__grid,
  .new-work__grid,
  .site-footer__cols {
    grid-template-columns: 1fr;
  }

  .result,
  .result:first-child,
  .result:nth-child(odd) {
    padding: 18px 0;
    border-bottom: 1px solid var(--pb-rule);
    border-left: 0;
  }

  .result:nth-last-child(-n + 2) {
    border-bottom: 1px solid var(--pb-rule);
  }

  .result:last-child {
    border-bottom: 0;
  }

  .result__number {
    font-size: 42px;
  }

  .new-work__grid {
    gap: 42px;
  }

  .site-footer__cols {
    gap: 28px;
  }

  .contact-main {
    width: min(100% - 48px, 575px);
    min-height: calc(100vh - 74px);
    padding-top: 64px;
  }

  .contact-main h1 {
    margin-bottom: 24px;
    font-size: 52px;
  }

  .contact-main p {
    font-size: 17px;
  }
}

@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;
  }
}
