/* ---------- Fonts (self-hosted, Fontsource) ---------- */
@font-face {
  font-family: 'Montserrat';
  font-style: normal;
  font-display: swap;
  font-weight: 400;
  src: url('../fonts/montserrat-latin-400-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Montserrat';
  font-style: normal;
  font-display: swap;
  font-weight: 400;
  src: url('../fonts/montserrat-latin-ext-400-normal.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Montserrat';
  font-style: normal;
  font-display: swap;
  font-weight: 600;
  src: url('../fonts/montserrat-latin-600-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Montserrat';
  font-style: normal;
  font-display: swap;
  font-weight: 600;
  src: url('../fonts/montserrat-latin-ext-600-normal.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Montserrat';
  font-style: normal;
  font-display: swap;
  font-weight: 700;
  src: url('../fonts/montserrat-latin-700-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Montserrat';
  font-style: normal;
  font-display: swap;
  font-weight: 700;
  src: url('../fonts/montserrat-latin-ext-700-normal.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Montserrat';
  font-style: normal;
  font-display: swap;
  font-weight: 800;
  src: url('../fonts/montserrat-latin-800-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Montserrat';
  font-style: normal;
  font-display: swap;
  font-weight: 800;
  src: url('../fonts/montserrat-latin-ext-800-normal.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Zilla Slab';
  font-style: normal;
  font-display: swap;
  font-weight: 700;
  src: url('../fonts/zilla-slab-latin-700-normal.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Zilla Slab';
  font-style: normal;
  font-display: swap;
  font-weight: 700;
  src: url('../fonts/zilla-slab-latin-ext-700-normal.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ---------- Base ---------- */
:root {
  --bg: #121212;
  --text: #eee;
  --muted: #888;
  --font-body: 'Montserrat', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  --font-display: 'Zilla Slab', Georgia, serif;
  --max-width: 1600px;
  --side: 5%;
}

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

html {
  background-color: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.4;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

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

/* ---------- Layout shell ---------- */
.site-container {
  position: relative;
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
}

.site-content {
  margin-left: var(--side);
  margin-right: var(--side);
  width: 90%;
}

/* ---------- Header ---------- */
.site-header {
  position: relative;
}

.site-header::after {
  content: '';
  display: table;
  clear: both;
}

.logo-container {
  float: right;
  width: 50%;
}

.logo-wrap {
  float: left;
  width: 100%;
  padding-top: 85px;
}

.logo-link {
  display: inline-block;
  width: 50px;
}

.logo-img {
  display: block;
  width: 50px;
  height: auto;
}

.nav-container {
  float: left;
  width: 50%;
}

.nav-container nav {
  float: right;
  padding-top: 80px;
  text-align: right;
}

.nav-line {
  line-height: 28px;
}

.nav-link {
  font-family: var(--font-body);
  font-size: 14px;
  font-style: normal;
  font-weight: 600;
  line-height: 28px;
  text-transform: uppercase;
  color: var(--muted);
  transition: color 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--text);
}

.gallery-title {
  margin-right: 10px;
}

.page-title {
  padding: 0 10px;
}

.social {
  display: inline-block;
  width: 30px;
  height: 24px;
  margin-left: 10px;
  vertical-align: middle;
  color: var(--text);
}

.social svg {
  display: block;
  width: 30px;
  height: 24px;
  fill: currentColor;
}

.hamburger {
  display: none;
}

/* ---------- Gallery ---------- */
.project-covers {
  display: flex;
  flex-wrap: wrap;
  padding-top: 40px;
}

.project-cover {
  position: relative;
  display: block;
  width: 25%;
  overflow: hidden;
}

.cover-image {
  position: relative;
  width: 100%;
  aspect-ratio: 1.2785;
  overflow: hidden;
  background-color: #1a1a1a;
}

.cover-image picture,
.cover-image img {
  width: 100%;
  height: 100%;
}

.cover-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cover-image::after {
  content: '';
  position: absolute;
  inset: 0;
  background-color: #000;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.project-cover:hover .cover-image::after,
.project-cover:focus-visible .cover-image::after {
  opacity: 0.5;
}

.details-wrap {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s ease;
}

.project-cover:hover .details-wrap,
.project-cover:focus-visible .details-wrap {
  opacity: 1;
}

.details-inner {
  padding: 7% 8% 0;
}

.details-inner .title {
  color: #fff;
  font-family: var(--font-body);
  font-size: 20px;
  font-weight: 700;
  line-height: 34px;
}

/* ---------- Project page ---------- */
.page-header {
  float: left;
  width: 100%;
  max-width: 800px;
  padding: 29px 0 55px;
}

.page-header .title {
  margin: 0;
  color: var(--text);
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 23px;
  font-weight: 700;
  line-height: 70px;
}

.page-header .description {
  margin: 0;
  color: var(--muted);
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 28px;
  white-space: pre-line;
  word-wrap: break-word;
}

.page-content {
  clear: both;
}

.page-content::after {
  content: '';
  display: table;
  clear: both;
}

/* ---------- Modules ---------- */
.module {
  clear: both;
  word-break: break-word;
}

.module-image {
  margin: 0 auto 30px;
  max-width: 100%;
}

.module-image.align-left {
  margin-left: 0;
  margin-right: auto;
  float: left;
}

.module-image.align-right {
  margin-left: auto;
  margin-right: 0;
  float: right;
}

.module-image.align-center {
  margin-left: auto;
  margin-right: auto;
}

.module-img {
  display: block;
  width: 100%;
  height: auto;
}

.module-caption {
  color: var(--muted);
  font-size: 13px;
  line-height: 19px;
  padding-top: 11px;
}

.module-text {
  margin: 0 auto;
  max-width: 800px;
  padding: 20px 0 40px;
}

.module-text,
.module-text div,
.module-text p {
  color: var(--muted);
  font-family: var(--font-body);
  font-size: 20px;
  font-weight: 400;
  line-height: 28px;
}

.module-text div,
.module-text p {
  padding-bottom: 20px;
}

.module-text .caption,
.module-text .caption div,
.module-text .caption p {
  font-size: 13px;
  line-height: 19px;
  padding-bottom: 0;
}

.module-text a {
  color: inherit;
  text-decoration: underline;
}

.module-text a:hover {
  filter: brightness(70%) saturate(120%) hue-rotate(5deg);
}

.module-embed {
  margin: 0 auto;
  width: 100%;
}

.embed-dimensions {
  margin: 0 auto;
  max-width: 1920px;
}

.embed-ratio {
  position: relative;
  height: 0;
  overflow: hidden;
}

.embed-ratio iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.video-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 20px;
  background-color: #1a1a1a;
  color: var(--muted);
  font-size: 14px;
  text-align: center;
}

.video-placeholder p {
  margin: 0;
}

.video-placeholder a {
  color: var(--text);
  text-decoration: underline;
}

.module-row {
  display: flex;
  gap: 8px;
}

.module-row.valign-center {
  align-items: center;
}

.module-row.valign-bottom {
  align-items: flex-end;
}

.row-child {
  flex: 1 1 0;
  min-width: 0;
}

.module-media-collection {
  padding-bottom: 40px;
}

.media-grid {
  column-count: 3;
  column-gap: 8px;
}

.media-item {
  break-inside: avoid;
  margin-bottom: 8px;
}

.media-img {
  display: block;
  width: 100%;
  height: auto;
}

.media-caption {
  color: var(--muted);
  font-size: 13px;
  line-height: 19px;
  padding: 8px 4px 0;
}

.module-caption-container {
  margin: 0 auto;
  max-width: 800px;
  width: 100%;
}

/* ---------- Info page ---------- */
.info-page .page-content {
  padding-top: 20px;
}

/* ---------- Back to top / 404 ---------- */
.back-to-top {
  display: block;
  padding: 60px 0;
  text-align: center;
}

.back-to-top a {
  color: var(--muted);
  font-size: 14px;
  line-height: 20px;
}

.back-to-top .arrow {
  display: inline-block;
  margin-right: 10px;
}

.not-found {
  padding: 80px 5%;
  text-align: center;
}

.not-found h1 {
  font-size: 48px;
  margin: 0 0 20px;
}

.not-found a {
  text-decoration: underline;
}

/* ---------- Responsive nav overlay ---------- */
.responsive-nav {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--bg);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s ease, visibility 0s linear 0.2s;
}

.show-responsive-nav .responsive-nav {
  opacity: 1;
  visibility: visible;
  transition: opacity 0.2s ease, visibility 0s linear 0s;
}

.responsive-nav nav {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
  text-align: center;
}

.responsive-nav .nav-link {
  font-size: 22px;
  line-height: 32px;
}

.responsive-nav .social {
  margin-left: 0;
}

.close-responsive-button {
  position: absolute;
  top: 30px;
  right: 30px;
  width: 30px;
  height: 30px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.close-responsive-button::before,
.close-responsive-button::after {
  content: '';
  position: absolute;
  top: 14px;
  left: 2px;
  width: 26px;
  height: 2px;
  background-color: #fff;
}

.close-responsive-button::before {
  transform: rotate(45deg);
}

.close-responsive-button::after {
  transform: rotate(-45deg);
}

/* ---------- Breakpoints ---------- */
@media (max-width: 932px) {
  .site-content {
    margin: 0;
    width: 100%;
  }

  .site-header {
    min-height: 110px;
  }

  .logo-container {
    float: none;
    width: 100%;
    padding: 30px 20px 0;
  }

  .logo-wrap {
    float: none;
    width: auto;
    padding-top: 0;
  }

  .logo-link {
    width: auto;
  }

  .logo-img {
    width: auto;
    height: 60px;
  }

  .nav-container {
    display: none;
  }

  .hamburger {
    position: absolute;
    top: 48px;
    right: 20px;
    display: block;
    width: 24px;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
  }

  .hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    margin-bottom: 4px;
    background-color: #fff;
  }

  .hamburger span:last-child {
    margin-bottom: 0;
  }

  .project-cover {
    width: 50%;
  }

  .project-covers {
    padding-top: 20px;
  }

  .page-header {
    padding: 16px 5% 25px;
  }

  .module-row {
    display: block;
  }

  .row-child {
    flex: none;
  }

  .media-grid {
    column-count: 2;
  }
}

@media (max-width: 540px) {
  .project-cover {
    width: 100%;
  }

  .project-covers {
    padding-top: 18px;
  }

  .page-header .title {
    font-size: 32px;
    line-height: 32px;
  }

  .page-header .description {
    font-size: 14px;
    line-height: 20px;
  }

  .module-text,
  .module-text div,
  .module-text p {
    font-size: 14px;
    line-height: 24px;
  }

  .media-grid {
    column-count: 1;
  }
}
