:root {
  --ink: #090909;
  --muted: #dedede;
  --page-pad: clamp(1.5rem, 4vw, 3.65rem);
  --content: 1328px;
  --ease: 180ms ease;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: #fff;
  font-family: "Poppins", Arial, sans-serif;
  font-size: 16px;
  font-weight: 300;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

body.menu-open,
body.lightbox-open {
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

button,
summary {
  color: inherit;
  font: inherit;
}

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

.skip-link {
  position: fixed;
  z-index: 1000;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.6rem 0.85rem;
  transform: translateY(-180%);
  background: #fff;
  border: 1px solid #111;
}

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

.site-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.site-header {
  position: relative;
  z-index: 40;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: start;
  min-height: 132px;
  padding: 48px var(--page-pad) 34px;
  background: #fff;
}

.brand {
  grid-column: 2;
  align-self: start;
  font-size: clamp(1.65rem, 2.2vw, 2.2rem);
  font-weight: 500;
  line-height: 1.1;
  text-decoration: none;
  letter-spacing: -0.03em;
}

.desktop-nav {
  grid-column: 1;
  grid-row: 1;
  display: flex;
  align-items: flex-start;
  gap: 1.45rem;
  font-size: 1rem;
}

.desktop-nav > a,
.art-menu > summary {
  text-decoration: none;
  cursor: pointer;
}

.desktop-nav > a.active,
.art-menu.active > summary,
.desktop-nav > a:hover,
.art-menu > summary:hover {
  text-decoration: underline;
  text-underline-offset: 0.5em;
}

.art-menu {
  position: relative;
}

.art-menu > summary {
  list-style: none;
}

.art-menu > summary::-webkit-details-marker {
  display: none;
}

.art-menu[open] .art-popover {
  animation: fade-in 150ms ease both;
}

.art-popover {
  position: absolute;
  top: calc(100% + 1rem);
  left: -1rem;
  min-width: 190px;
  padding: 0.85rem 1rem;
  display: grid;
  gap: 0.35rem;
  background: rgba(255, 255, 255, 0.98);
  border: 1px solid #ececec;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}

.art-popover a {
  padding: 0.2rem 0;
  text-decoration: none;
  white-space: nowrap;
}

.art-popover a:hover,
.art-popover a.active {
  text-decoration: underline;
}

.mobile-toggle,
.mobile-menu {
  display: none;
}

main {
  flex: 1 0 auto;
}

.content-width {
  width: min(calc(100% - (2 * var(--page-pad))), var(--content));
  margin-inline: auto;
}

.page-title {
  margin: 44px 0 100px;
  text-align: center;
  font-size: clamp(2.75rem, 4.3vw, 4rem);
  font-weight: 400;
  line-height: 1.1;
  letter-spacing: -0.035em;
}

.home-main {
  padding: 48px 0 208px;
}

.home-hero {
  width: min(calc(100% - (2 * clamp(2rem, 7.8vw, 7rem))), 1216px);
  aspect-ratio: 1.92 / 1;
  margin: 0 auto;
  object-fit: cover;
}

.home-links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.25rem 2.35rem;
  margin: 96px auto 0;
  padding: 0 var(--page-pad);
}

.home-links a {
  font-size: clamp(1.65rem, 2.5vw, 2.25rem);
  font-weight: 400;
  line-height: 1.45;
  letter-spacing: -0.025em;
  text-transform: uppercase;
}

.index-page {
  min-height: 1000px;
  padding-bottom: 120px;
}

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

.index-card {
  text-decoration: none;
}

.index-card-media {
  overflow: hidden;
  background: #eee;
  aspect-ratio: 1 / 1;
}

.index-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 420ms ease;
}

.index-card:hover img,
.index-card:focus-visible img {
  transform: scale(1.02);
}

.index-card h2 {
  margin: 0.95rem 0 0;
  font-size: 1.22rem;
  font-weight: 400;
  line-height: 1.35;
}

.installations-page .index-card h2,
.videos-page .index-card h2 {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.installations-page .index-card-media {
  aspect-ratio: 1 / 1;
}

.project-page {
  min-height: 1135px;
  padding: 72px 0 0;
}

.project-page .project-title {
  margin: 0 0 18px;
  text-align: center;
  font-size: clamp(2.2rem, 3.4vw, 3rem);
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: -0.035em;
}

.project-gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1.25rem, 3vw, 5.2rem);
  align-items: center;
}

.project-gallery img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.project-copy {
  margin-top: 82px;
  font-size: 1.02rem;
}

.project-copy p {
  margin: 0 0 1.3rem;
}

.project-copy ul {
  margin: -0.45rem 0 1.4rem;
  padding-left: 1.25rem;
}

.project-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.8rem;
}

.project-nav {
  width: min(calc(100% - (2 * var(--page-pad))), var(--content));
  min-height: 170px;
  margin: 130px auto 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.project-nav a {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
}

.project-nav .arrow {
  font-family: Arial, sans-serif;
  font-size: 3rem;
  font-weight: 200;
  line-height: 1;
}

.project-nav .label {
  max-width: 210px;
  font-size: 0.9rem;
  opacity: 0;
  transition: opacity var(--ease);
}

.project-nav a:hover .label,
.project-nav a:focus-visible .label {
  opacity: 1;
}

.media-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 52px 128px;
  width: min(calc(100% - (2 * var(--page-pad))), 1096px);
  margin: 80px auto 0;
}

.media-grid iframe,
.media-grid video {
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 0;
  background: #000;
  object-fit: cover;
}

.gallery-page {
  min-height: 1120px;
  padding: 58px 0 150px;
}

.gallery-page .page-title {
  margin-top: 0;
}

.masonry {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1.5rem, 4.5vw, 4.1rem);
}

.masonry-column {
  display: flex;
  flex-direction: column;
  gap: clamp(1.5rem, 4.5vw, 4.1rem);
}

.masonry-item button,
.art-grid button,
.project-gallery button {
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  cursor: zoom-in;
}

.masonry img,
.art-grid img {
  width: 100%;
  height: auto;
}

.paintings-page {
  min-height: 1320px;
  padding: 58px 0 150px;
}

.paintings-layout {
  display: grid;
  grid-template-columns: 1fr 1.08fr;
  grid-template-rows: auto auto;
  gap: 14px;
}

.paintings-layout .painting:first-child {
  grid-row: 1 / 3;
}

.paintings-layout .painting:first-child img {
  height: 100%;
  object-fit: cover;
}

.paintings-layout .painting:last-child {
  grid-column: 1 / 3;
  width: 54%;
  margin: 0 0 0 auto;
}

.about-page {
  padding: 135px 0 130px;
}

.about-layout {
  display: grid;
  grid-template-columns: minmax(260px, 378px) 1fr;
  gap: clamp(3rem, 5vw, 4.2rem);
  align-items: start;
}

.about-layout img {
  width: 100%;
  aspect-ratio: 0.82 / 1;
  object-fit: cover;
}

.about-copy h1 {
  margin: -0.15rem 0 1.6rem;
  font-size: 2.25rem;
  font-weight: 500;
  letter-spacing: -0.025em;
}

.about-copy p {
  margin: 0 0 1.1rem;
}

.site-footer {
  flex: 0 0 auto;
  min-height: 330px;
  padding: 64px var(--page-pad) 72px;
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-rows: auto 1fr auto;
  background: var(--muted);
}

.footer-brand {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 500;
}

.footer-contact {
  grid-row: 3;
  margin: 0;
  font-style: normal;
}

.footer-contact a {
  display: block;
  width: fit-content;
  text-decoration: none;
}

.footer-contact a:hover {
  text-decoration: underline;
}

.social-links {
  grid-column: 2;
  grid-row: 1 / 4;
  align-self: center;
  display: flex;
  gap: 1.25rem;
}

.social-links a {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
}

.social-links svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.lightbox {
  width: 100vw;
  height: 100vh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 48px;
  border: 0;
  background: rgba(0, 0, 0, 0.92);
}

.lightbox::backdrop {
  background: rgba(0, 0, 0, 0.92);
}

.lightbox-inner {
  width: 100%;
  height: 100%;
  display: grid;
  place-items: center;
}

.lightbox img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.lightbox-close {
  position: fixed;
  z-index: 2;
  top: 20px;
  right: 24px;
  width: 44px;
  height: 44px;
  padding: 0;
  color: #fff;
  background: none;
  border: 0;
  font-size: 2.2rem;
  cursor: pointer;
}

.not-found {
  min-height: 650px;
  display: grid;
  place-items: center;
  text-align: center;
}

@keyframes fade-in {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 900px) {
  :root {
    --page-pad: 1.55rem;
  }

  .site-header {
    min-height: 180px;
    padding: 29px var(--page-pad) 24px;
    align-items: start;
  }

  .desktop-nav {
    display: none;
  }

  .brand {
    font-size: 1.6rem;
    position: relative;
    z-index: 40;
  }

  .mobile-toggle {
    grid-column: 1;
    grid-row: 1;
    display: block;
    width: 38px;
    height: 28px;
    padding: 3px 0;
    background: none;
    border: 0;
    cursor: pointer;
    position: relative;
    z-index: 40;
  }

  .mobile-toggle::before,
  .mobile-toggle::after {
    content: "";
    display: block;
    width: 34px;
    height: 1px;
    margin: 6px 0;
    background: currentColor;
    transition: transform var(--ease);
  }

  .mobile-toggle[aria-expanded="true"]::before {
    transform: translateY(3.5px) rotate(45deg);
  }

  .mobile-toggle[aria-expanded="true"]::after {
    transform: translateY(-3.5px) rotate(-45deg);
  }

  .mobile-menu {
    position: fixed;
    inset: 0;
    z-index: 30;
    padding: 112px 1.6rem 2rem;
    display: grid;
    align-content: start;
    gap: 0.65rem;
    transform: translateX(-100%);
    background: #fff;
    transition: transform 260ms ease;
  }

  .mobile-menu.open {
    transform: translateX(0);
  }

  .mobile-menu a {
    width: fit-content;
    font-size: 1.45rem;
    text-decoration: none;
  }

  .mobile-menu .menu-section {
    margin: 0.7rem 0 0.1rem;
    font-size: 0.95rem;
    font-weight: 500;
    letter-spacing: 0.08em;
  }

  .home-main {
    padding: 0 0 105px;
  }

  .home-hero {
    width: 100%;
    aspect-ratio: 1.27 / 1;
  }

  .home-links {
    max-width: 400px;
    margin-top: 106px;
    gap: 0.05rem 1.1rem;
  }

  .home-links a {
    font-size: clamp(1.5rem, 7vw, 1.85rem);
    line-height: 1.4;
  }

  .page-title {
    margin: 16px 0 64px;
    font-size: clamp(2.5rem, 12vw, 3.5rem);
  }

  .index-page {
    min-height: 750px;
    padding-bottom: 100px;
  }

  .index-grid {
    grid-template-columns: 1fr;
    gap: 2.2rem;
  }

  .index-card h2,
  .installations-page .index-card h2,
  .videos-page .index-card h2 {
    position: static;
    width: auto;
    height: auto;
    overflow: visible;
    clip: auto;
  }

  .project-page {
    min-height: 850px;
    padding-top: 16px;
  }

  .project-page .project-title {
    margin-bottom: 42px;
    font-size: 2.35rem;
  }

  .project-gallery {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .project-copy {
    margin-top: 48px;
  }

  .project-nav {
    min-height: 120px;
    margin-top: 72px;
  }

  .project-nav .label {
    display: none;
  }

  .media-grid {
    grid-template-columns: 1fr;
    gap: 1.2rem;
    margin-top: 22px;
  }

  .gallery-page,
  .paintings-page {
    padding-top: 14px;
  }

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

  .paintings-layout {
    display: block;
  }

  .paintings-layout .painting,
  .paintings-layout .painting:last-child {
    width: 100%;
    margin: 0 0 1rem;
  }

  .about-page {
    padding: 22px 0 90px;
  }

  .about-layout {
    grid-template-columns: 1fr;
    gap: 2.6rem;
  }

  .about-layout img {
    max-width: 540px;
  }

  .site-footer {
    min-height: 295px;
    padding-top: 44px;
    padding-bottom: 48px;
  }

  .social-links {
    gap: 0.85rem;
  }

  .lightbox {
    padding: 56px 14px 20px;
  }
}

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