:root {
  --landing-text: #111;
  --landing-bg: #fff;
  --landing-line: rgba(17, 17, 17, 0.1);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  scroll-behavior: smooth;
}

body {
  background: var(--landing-bg);
  color: var(--landing-text);
  font-family: "Montserrat", Arial, Helvetica, sans-serif;
}

body.lightbox-scroll-locked {
  position: fixed;
  width: 100%;
  overflow: hidden;
  touch-action: none;
}

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

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

button,
input,
textarea,
select {
  font: inherit;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 11px;
  font-weight: 600;
  color: rgba(17, 17, 17, 0.56);
}

.public-test-banner {
  position: fixed;
  top: 16px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  background: rgba(17, 17, 17, 0.92);
  color: #fff;
  border-radius: 999px;
  padding: 10px 16px;
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 24px;
}

.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 32px 24px 40px;
  overflow: hidden;
}

.logo-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin-bottom: 40px;
  position: relative;
}

.svg-logo {
  width: 74vw;
  max-width: 390px;
  height: auto;
  transform: scaleX(-1);
  flex-shrink: 0;
}

path[stroke] {
  stroke-dasharray: 5000;
  stroke-dashoffset: 5000;
  stroke-linecap: round;
  stroke-linejoin: round;
  animation: drawPath 1.5s ease-in-out forwards;
}

#inventar-L-stroke {
  animation-delay: 0.5s;
}

#house-outline-stroke {
  animation-delay: 1.3s;
}

.text-wrapper {
  width: auto;
  overflow: visible;
  display: flex;
  justify-content: center;
}

.logo-text {
  opacity: 0;
  text-align: center;
  white-space: normal;
  padding-bottom: 20px;
}

.text-wrapper.fade-in {
  animation: revealText 1s ease-out forwards;
}

.logo-text.fade-in {
  animation: textFadeIn 1s ease-out forwards;
}

.logo-main-text {
  font-size: 3.5em;
  font-weight: 600;
  margin: 0;
  line-height: 1;
}

.logo-sub-text {
  font-size: 1.3em;
  font-weight: 400;
  margin: 0;
  line-height: 1.1;
  letter-spacing: 0.08em;
}

.contact-section {
  opacity: 0;
  width: 100%;
  padding: 0 25px;
  text-align: center;
  padding-top: 5%;
}

.contact-section.fade-in {
  animation: contactFadeIn 1s ease-out forwards;
}

.contact-container {
  padding-top: 5%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 15px;
  font-size: 1.1rem;
  padding-bottom: 30px;
}

.contact-item {
  display: flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  width: 100%;
}

.contact-item .label {
  font-weight: 600;
  margin-right: 5px;
}

.contact-item a {
  transition: opacity 0.3s;
}

.contact-item a:hover {
  opacity: 0.6;
}

.separator {
  display: none;
  color: #ccc;
  margin: 0 5px;
}

.scroll {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 11px;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  opacity: 0;
  pointer-events: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.scroll span {
  opacity: 0.68;
}

.scroll-line {
  width: 1px;
  height: 56px;
  background: linear-gradient(to bottom, rgba(17, 17, 17, 0.1), rgba(17, 17, 17, 0.7), rgba(17, 17, 17, 0.1));
  position: relative;
  overflow: hidden;
}

.scroll-line::after {
  content: "";
  position: absolute;
  top: -18px;
  left: 50%;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #111;
  transform: translateX(-50%);
  animation: scrollDot 1.7s ease-in-out infinite;
}

.scroll.is-visible {
  animation: scrollFadeIn 0.8s ease-out forwards;
}

.topbar-shell {
  position: fixed;
  top: 16px;
  left: 50%;
  z-index: 50;
  width: min(calc(100% - 32px), 1120px);
  transform: translate(-50%, -16px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.45s ease, transform 0.45s ease;
}

.topbar-shell.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
  pointer-events: auto;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 18px;
  border: 1px solid rgba(17, 17, 17, 0.08);
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(18px);
}

.topbar-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.topbar-brand img {
  width: 68px;
  height: auto;
}

.topbar-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 1;
  justify-content: center;
  min-width: 0;
  flex-wrap: wrap;
}

.topbar-meta a,
.topbar-meta span {
  font-size: 13px;
  white-space: nowrap;
}

.topbar-label {
  font-weight: 600;
  margin-right: 4px;
}

.topbar-divider {
  width: 1px;
  height: 18px;
  background: rgba(17, 17, 17, 0.12);
}

.topbar-actions {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
}

.topbar-projects {
  border: 0;
  border-radius: 999px;
  padding: 11px 16px;
  background: #111;
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}

.topbar-top {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  opacity: 0.62;
}

.topbar-dropdown {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  width: min(320px, calc(100vw - 32px));
  padding: 14px 18px;
  border: 1px solid rgba(17, 17, 17, 0.08);
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.1);
  opacity: 0;
  transform: translateY(-8px);
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.topbar-dropdown.is-open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.topbar-dropdown a {
  display: block;
  padding: 12px 0;
  border-bottom: 1px solid var(--landing-line);
  overflow-wrap: anywhere;
}

.topbar-dropdown a:last-child {
  border-bottom: 0;
}

.projects-section {
  padding-top: 0;
}

.project {
  padding: 92px 0;
  border-top: 1px solid var(--landing-line);
}

.project-tag-filter {
  max-width: 1040px;
  margin: 0 auto;
  padding: 46px 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.project-tag-filter button {
  min-height: 34px;
  padding: 8px 14px;
  border: 1px solid rgba(17, 17, 17, 0.18);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.62);
  color: rgba(17, 17, 17, 0.72);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
}

.project-tag-filter button.is-active,
.project-tag-filter button:hover {
  background: #111;
  border-color: #111;
  color: #fff;
}

.project-shell {
  max-width: 1040px;
  margin: 0 auto;
  display: grid;
  gap: 30px;
  align-items: start;
}

.project-copy {
  max-width: 420px;
}

.project-header {
  margin: 0 0 18px;
}

.project-title {
  font-size: clamp(2.1rem, 4vw, 3.6rem);
  margin: 8px 0 14px;
  line-height: 1;
}

.project-description {
  margin: 0;
  font-size: 17px;
  line-height: 1.75;
  color: rgba(17, 17, 17, 0.82);
}

.project-media {
  display: grid;
  gap: 14px;
  max-width: 100%;
}

.project-media button {
  padding: 0;
  border: 0;
  background: transparent;
  cursor: zoom-in;
  position: relative;
}

.project-media img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  border-radius: 28px;
  border: 1px solid rgba(17, 17, 17, 0.1);
}

.project-media-frame {
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 28px;
  aspect-ratio: 4 / 3;
  background: #f4f1ea;
}

.project-media-frame.is-rotated {
  padding: 20px;
}

.project-media-frame.is-rotated img {
  width: auto;
  max-width: calc(100% - 24px);
  max-height: calc(100% - 24px);
}

.project-media video {
  width: 100%;
  border-radius: 28px;
  border: 1px solid rgba(17, 17, 17, 0.1);
  background: #000;
  object-fit: cover;
}

.video-trigger::after {
  content: "";
  position: absolute;
  inset: 50% auto auto 50%;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: rgba(17, 17, 17, 0.72);
  transform: translate(-50%, -50%);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.22);
}

.video-trigger::before {
  content: "";
  position: absolute;
  inset: 50% auto auto 50%;
  width: 0;
  height: 0;
  border-top: 12px solid transparent;
  border-bottom: 12px solid transparent;
  border-left: 18px solid #fff;
  transform: translate(-32%, -50%);
  z-index: 1;
}

.media-more::before {
  content: attr(data-more-count);
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border-radius: 28px;
  background: rgba(17, 17, 17, 0.42);
  color: #fff;
  font-size: clamp(1.5rem, 3vw, 2.4rem);
  font-weight: 600;
  letter-spacing: 0.08em;
  z-index: 2;
}

.media-more.video-trigger::before {
  content: attr(data-more-count);
  width: auto;
  height: auto;
  border: 0;
  inset: 0;
  display: grid;
  place-items: center;
  border-radius: 28px;
  background: rgba(17, 17, 17, 0.48);
  color: #fff;
  font-size: clamp(1.5rem, 3vw, 2.4rem);
  font-weight: 600;
  letter-spacing: 0.08em;
  transform: none;
  z-index: 3;
}

.media-more.video-trigger::after {
  display: none;
}

.project-media-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.gallery-hidden {
  display: none !important;
}

.project-media-placeholder {
  display: grid;
  place-items: center;
  min-height: 280px;
  padding: 24px;
  border: 1px solid rgba(17, 17, 17, 0.1);
  border-radius: 28px;
  background: linear-gradient(135deg, #f7f4ed, #efebe2);
  color: rgba(17, 17, 17, 0.55);
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-size: 12px;
  text-align: center;
}

.lightbox {
  --lightbox-viewport-width: 100vw;
  --lightbox-viewport-height: 100vh;
  --lightbox-viewport-height: 100svh;
  --lightbox-media-width: calc(100vw - 196px);
  --lightbox-media-height: calc(100vh - 132px);
  --lightbox-media-height: calc(100svh - 132px);
  --lightbox-padding-top: 54px;
  --lightbox-padding-right: 70px;
  --lightbox-padding-bottom: 18px;
  --lightbox-padding-left: 70px;
  position: fixed;
  inset: 0;
  z-index: 120;
  background: rgba(17, 17, 17, 0.92);
  display: grid;
  place-items: center;
  padding: 0;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.25s ease;
  overflow: hidden;
}

.lightbox.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.lightbox-figure {
  position: relative;
  z-index: 1;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: center;
  justify-content: center;
  width: var(--lightbox-viewport-width);
  height: var(--lightbox-viewport-height);
  padding: var(--lightbox-padding-top) var(--lightbox-padding-right) var(--lightbox-padding-bottom) var(--lightbox-padding-left);
  box-sizing: border-box;
}

.lightbox-media {
  position: relative;
  z-index: 1;
  flex: 1 1 auto;
  width: var(--lightbox-media-width);
  height: var(--lightbox-media-height);
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  max-height: 100%;
  box-sizing: border-box;
}

.lightbox-media:not(.is-rotated) img,
.lightbox-media:not(.is-rotated) video {
  max-width: var(--lightbox-media-width);
  max-height: var(--lightbox-media-height);
}

.lightbox-media.is-rotated {
  padding: 0;
}

.lightbox-media.is-rotated img {
  max-width: 100%;
  max-height: 100%;
}

.lightbox img,
.lightbox video {
  display: block;
  position: static;
  margin: 0;
  max-width: var(--lightbox-media-width);
  max-height: var(--lightbox-media-height);
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 24px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.35);
}

.lightbox img {
  pointer-events: none;
}

.lightbox img[hidden],
.lightbox video[hidden] {
  display: none !important;
}

.lightbox video {
  background: #000;
  pointer-events: auto;
}

.lightbox-caption {
  flex: 0 0 auto;
  color: rgba(255, 255, 255, 0.88);
  font-size: 14px;
  line-height: 1.6;
  text-align: center;
  max-width: 780px;
  min-height: 0;
  padding: 8px 14px 10px;
  white-space: pre-wrap;
}

.lightbox-caption:empty {
  display: none;
}

.lightbox-close {
  position: absolute;
  z-index: 3;
  top: 18px;
  right: 18px;
  border: 0;
  border-radius: 999px;
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

.lightbox-nav {
  position: absolute;
  z-index: 3;
  top: 50%;
  transform: translateY(-50%);
  border: 0;
  border-radius: 999px;
  width: 52px;
  height: 52px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  cursor: pointer;
  font-size: 28px;
  line-height: 1;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

.lightbox-prev {
  left: 18px;
}

.lightbox-next {
  right: 18px;
}

.lightbox-nav[disabled] {
  opacity: 0.3;
  cursor: default;
  pointer-events: none;
}

.project.layout-feature-left .project-shell {
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.72fr);
}

.project.layout-feature-right .project-shell {
  grid-template-columns: minmax(320px, 0.72fr) minmax(0, 1.05fr);
}

.project.layout-feature-right .project-copy {
  order: 1;
}

.project.layout-feature-right .project-media {
  order: 2;
}

.project.layout-stacked .project-shell {
  grid-template-columns: minmax(280px, 0.8fr) minmax(0, 0.95fr);
}

.project.layout-stacked .project-media-grid {
  grid-template-columns: 1fr;
}

.project.layout-stacked .project-media img:first-child {
  max-width: 760px;
}

.project.layout-stacked .project-copy {
  padding-top: 18px;
}

.project.layout-centered .project-shell {
  grid-template-columns: 1fr;
  justify-items: center;
  text-align: center;
}

.project.layout-centered .project-copy {
  max-width: 620px;
}

.project.layout-centered .project-media {
  max-width: 760px;
}

.project.layout-centered .project-media-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.projects-soon {
  max-width: 1040px;
  margin: 12px auto 0;
  padding-top: 28px;
  border-top: 1px solid var(--landing-line);
  text-align: center;
  color: rgba(17, 17, 17, 0.62);
}

.grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 32px;
}

@keyframes drawPath {
  to {
    stroke-dashoffset: 0;
  }
}

@keyframes revealText {
  from {
    width: 0;
    opacity: 0;
  }

  to {
    width: 35vw;
    opacity: 1;
  }
}

@keyframes textFadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes contactFadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes scrollFadeIn {
  from {
    opacity: 0;
    transform: translate(-50%, 18px);
  }

  to {
    opacity: 1;
    transform: translate(-50%, 0);
  }
}

@keyframes scrollDot {
  0% {
    top: -18px;
    opacity: 0;
  }

  20% {
    opacity: 1;
  }

  70% {
    opacity: 1;
  }

  100% {
    top: 46px;
    opacity: 0;
  }
}

@media (min-width: 769px) {
  .logo-container {
    flex-direction: row-reverse;
    align-items: flex-end;
    gap: 0;
  }

  .svg-logo {
    width: 45vw;
    max-width: none;
    max-height: 80vh;
  }

  .text-wrapper {
    width: 0;
    max-width: 450px;
    overflow: hidden;
    justify-content: flex-end;
  }

  .logo-text {
    text-align: right;
    white-space: nowrap;
    padding-bottom: 0;
    margin-right: 2vw;
    margin-left: 0;
    opacity: 0;
  }

  .logo-main-text {
    font-size: clamp(3rem, 7vw, 6.1em);
    line-height: 0.9;
  }

  .logo-sub-text {
    font-size: clamp(1rem, 2.2vw, 1.9em);
    line-height: 1;
  }

  .contact-section {
    padding: 0;
    text-align: left;
    width: auto;
  }

  .contact-container {
    flex-direction: row;
    gap: 10px;
    font-size: 0.9rem;
  }

  .contact-item {
    width: auto;
    justify-content: flex-start;
  }

  .separator {
    display: inline;
  }
}

@media (max-width: 900px) {
  .topbar {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .topbar-brand {
    order: 1;
  }

  .topbar-actions {
    order: 2;
    margin-left: auto;
    position: static;
  }

  .topbar-meta {
    order: 3;
    width: 100%;
    justify-content: flex-start;
    gap: 10px;
  }

  .topbar-divider {
    display: none;
  }
}

@media (max-width: 640px) {
  .topbar-shell {
    top: 10px;
    width: min(calc(100% - 20px), 1120px);
  }

  .topbar {
    position: relative;
    padding: 12px 14px;
    border-radius: 20px;
    gap: 12px;
  }

  .topbar-brand img {
    width: 58px;
  }

  .topbar-meta a,
  .topbar-meta span {
    font-size: 12px;
  }

  .topbar-projects {
    padding: 10px 14px;
  }

  .topbar-top {
    display: none;
  }

  .topbar-dropdown {
    left: 0;
    right: 0;
    top: calc(100% + 8px);
    width: auto;
    max-width: none;
    padding: 12px 16px;
    border-radius: 18px;
  }

  .project {
    padding: 56px 0;
  }

  .project-shell,
  .project.layout-feature-left .project-shell,
  .project.layout-feature-right .project-shell,
  .project.layout-stacked .project-shell,
  .project.layout-centered .project-shell {
    grid-template-columns: 1fr;
    text-align: left;
    justify-items: stretch;
  }

  .project-copy {
    max-width: none;
  }

  .project-copy,
  .project-header {
    padding-top: 0;
  }

  .project.layout-feature-right .project-copy,
  .project.layout-feature-right .project-media {
    order: initial;
  }

  .project.layout-centered .project-copy,
  .project.layout-centered .project-media {
    max-width: none;
  }

  .project-media-grid {
    grid-template-columns: 1fr;
  }

  .lightbox {
    --lightbox-media-width: calc(100vw - 28px);
    --lightbox-media-height: calc(100vh - 92px);
    --lightbox-media-height: calc(100svh - 92px);
    --lightbox-media-height: calc(100dvh - 92px);
    --lightbox-padding-top: 58px;
    --lightbox-padding-right: 14px;
    --lightbox-padding-bottom: 20px;
    --lightbox-padding-left: 14px;
  }

  .lightbox-figure {
    width: var(--lightbox-viewport-width);
    height: var(--lightbox-viewport-height);
  }

  .lightbox-close {
    top: max(10px, env(safe-area-inset-top));
    right: max(10px, env(safe-area-inset-right));
    min-width: 44px;
    min-height: 44px;
  }

  .lightbox-nav {
    width: 48px;
    height: 48px;
    background: rgba(17, 17, 17, 0.42);
  }

  .lightbox-prev {
    left: max(10px, env(safe-area-inset-left));
  }

  .lightbox-next {
    right: max(10px, env(safe-area-inset-right));
  }

  .lightbox-caption {
    font-size: 13px;
  }
}
