/* Utilities */
.font-screen {
  font-family: "SuisseScreen", sans-serif;
  font-weight: 500;
  font-style: normal;
}

.font-screen-bold {
  font-family: "SuisseScreen", sans-serif;
  font-weight: 700;
  font-style: normal;
}

.font-screen-bold-italic {
  font-family: "SuisseScreen", sans-serif;
  font-weight: 700;
  font-style: italic;
}

.text-large,
.text-large-bold {
  font-size: 2.5rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1.5rem;
}

/* Base */
html {
  overflow-x: clip;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: "SuisseScreen", sans-serif;
  font-weight: 500;
  font-style: normal;
  color: #000;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  background: #fff;
}

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

a,
.hero-link,
.custom-link,
.project-link-text a,
.imprint-content a,
.imprint-text a,
.footer-links .hero-link {
  color: #000;
  text-decoration-color: #000;
  transition: filter 0.25s ease, opacity 0.25s ease;
}

a:hover,
.hero-link:hover,
.custom-link:hover,
.project-link-text a:hover,
.imprint-content a:hover,
.imprint-text a:hover,
.footer-links .hero-link:hover {
  filter: blur(2px);
  opacity: 1;
}

/* Intro */
.intro-section {
  position: relative;
  top: 0;
  left: 0;
  width: 100%;
  height: auto;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4rem;
  overflow: visible;
  background: #fff;
  z-index: 1;
  font-family: "SuisseScreen", sans-serif;
}

.intro-background {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
  background:
    linear-gradient(
      180deg,
      rgba(255, 255, 255, 0.2) 0%,
      rgba(255, 255, 255, 0.06) 38%,
      rgba(255, 255, 255, 0.26) 100%
    );
  background-size: 100% 100%;
  opacity: 1;
}

.intro-pixel-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  pointer-events: none;
  filter: saturate(1.08) contrast(1.12) brightness(0.9);
}

.intro-text {
  position: relative;
  z-index: 2;
  max-width: 1400px;
  text-align: left;
  color: #000;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 500;
  font-style: normal;
}

.intro-text h1 {
  margin: 0 0 2rem 0;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 700;
  font-style: italic;
  font-size: clamp(4rem, 8vw, 7rem);
  line-height: 0.92;
  letter-spacing: -0.04em;
  color: #000;
}

.intro-text p,
.intro-copy,
.intro-copy p {
  font-family: "SuisseScreen", sans-serif;
  font-weight: 500;
  font-style: normal;
  font-size: clamp(1.2rem, 1.9vw, 1.85rem);
  line-height: 1.55;
  color: #000;
}

.intro-copy p {
  margin-bottom: 1rem;
}

.intro-extra-links {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  align-items: center;
  margin-top: 2rem;
}

.intro-copy a {
  font-weight: 700;
  font-style: normal;
  text-decoration: none;
  box-shadow: inset 0 -0.22em 0 rgba(0, 0, 0, 0.16);
  padding: 0 0.12em;
  margin: 0 -0.12em;
  transition:
    color 0.25s ease,
    background-color 0.25s ease,
    box-shadow 0.25s ease,
    filter 0.25s ease,
    opacity 0.25s ease,
    transform 0.25s ease;
}

.intro-copy a:hover,
.intro-copy a:focus-visible {
  filter: none;
  opacity: 1;
  color: #fff;
  box-shadow: inset 0 -1.05em 0 #000;
}

.intro-extra-links a:hover,
.intro-extra-links a:focus-visible {
  transform: none;
}

.hover-trigger {
  position: relative;
  display: inline-block;
  cursor: pointer;
  z-index: 6;
  --hover-shift-x: 0px;
}

.hover-image {
  position: absolute;
  top: 100%;
  left: 50%;
  width: clamp(260px, 28vw, 520px);
  max-height: min(68vh, 36rem);
  height: auto;
  opacity: 0;
  transform: translate(calc(-50% + var(--hover-shift-x)), 18px) scale(0.92) rotate(-1.5deg);
  transform-origin: center top;
  transition:
    opacity 0.42s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.58s cubic-bezier(0.22, 1, 0.36, 1),
    filter 0.42s ease;
  border-radius: 1rem;
  pointer-events: none;
  z-index: 10;
  filter: blur(10px);
  box-shadow: 0 22px 52px rgba(0, 0, 0, 0.16);
}

.hover-trigger:hover .hover-image,
.hover-trigger:focus-visible .hover-image {
  opacity: 1;
  filter: blur(0);
  transform: translate(calc(-50% + var(--hover-shift-x)), 0) scale(1) rotate(0deg);
}

/* Project Scroller
   Reference-based stack geometry: intentionally direct.
   No project-stack-ready gate, no sticky fallback, no PHP x/y offset variables. */
.project-scroller {
  position: relative;
  width: 100vw;
  height: calc(100vh * var(--count-cards));
  min-height: 0;
  padding-bottom: 0;
  background: #fff;

  /*
   * The card inset is part of the stacking geometry.
   * Keep enough separation for 10 cards, but cap the visual depth
   * so later projects remain readable.
   */
  --stack-step-y: clamp(0.95rem, 1.8vh, 1.2rem);
  --stack-step-x: clamp(0.28rem, 0.45vw, 0.42rem);
}

.project-card {
  position: fixed;
  top: 100vh;
  left: 0;
  width: 100%;
  height: 100vh;
  min-height: 0;

  /*
   * IMPORTANT: do not remove the cumulative inset.
   * It is what makes the fixed cards remain visibly stacked.
   */
  padding-top: calc(var(--card-index, 0) * var(--stack-step-y));
  padding-right: calc(var(--card-index, 0) * var(--stack-step-x));
  padding-bottom: 0;
  padding-left: calc(var(--card-index, 0) * var(--stack-step-x));

  background-color: transparent;
}

.project-card-inner {
  height: 100%;
  min-height: 0;
  padding: 2rem;
  display: flex;
  gap: 2.5rem;
  background: var(--project-bg, #ffffff);
  border-radius: 2rem 2rem 0 0;
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
  cursor: pointer;
  transition:
    border-color 0.25s ease,
    box-shadow 0.25s ease;
  overflow: hidden;
}

.project-card-inner:hover {
  border-color: rgba(0, 0, 0, 0.14);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.08);
}

.project-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
  font-family: "SuisseScreen", sans-serif;
}

.project-card-header > div {
  flex-shrink: 0;
}

.project-card-header h2,
.project-card-header h2.text-large {
  margin: 0;
  max-width: 11ch;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 700;
  font-style: normal;
  font-size: clamp(2rem, 2.8vw, 3.2rem);
  line-height: 0.98;
  letter-spacing: -0.03em;
  color: #000;
  overflow-wrap: anywhere;
  text-wrap: balance;
}

.project-card-header span,
.project-card-header span.text-large {
  white-space: nowrap;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 700;
  font-style: normal;
  font-size: clamp(2rem, 2.8vw, 3.2rem);
  line-height: 0.98;
  letter-spacing: -0.03em;
  color: #000;
}

.project-card-description {
  max-width: 33rem;
  margin-top: 0;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 500;
  font-style: normal;
  font-size: 1.05rem;
  line-height: 1.72;
  color: #000;
  padding-bottom: 0.5rem;
}

.project-card-description p {
  margin: 0 0 1.15rem 0;
  hyphens: auto;
  overflow-wrap: anywhere;
}

.project-card-description p:last-child {
  margin-bottom: 0;
}

.project-link-container {
  margin-top: 2rem;
}

.project-link-text {
  margin: 0;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 700;
  font-style: normal;
  font-size: 1rem;
  line-height: 1.45;
  text-decoration: underline;
  text-underline-offset: 0.14em;
  color: #000;
}

/* Slider */
.project-card-slider {
  flex: 4;
  min-width: 52%;
  min-height: 55vh;
  height: calc(100% - 2rem);
  display: flex;
  align-items: center;
  overflow: hidden;
  position: relative;
  border-radius: 1rem;
  align-self: stretch;
  min-height: 0;
  touch-action: pan-y;
}

.slider {
  display: flex;
  width: auto;
  height: auto;
}

.project-card-slider.is-empty .slider {
  width: 100%;
  height: 100%;
}

.project-card-empty-visual {
  position: relative;
  display: grid;
  grid-template-rows: auto 1fr;
  width: 100%;
  min-height: 100%;
  padding: clamp(1rem, 2vw, 1.75rem);
  overflow: hidden;
  border: 1.5px solid currentColor;
  border-radius: 1rem;
  background:
    linear-gradient(135deg, transparent 49.85%, currentColor 50%, transparent 50.15%),
    linear-gradient(45deg, transparent 49.85%, currentColor 50%, transparent 50.15%);
  color: #000;
}

.project-card-empty-kicker.project-lang-block.is-active {
  display: block;
  width: fit-content;
  padding: 0.12rem 0.34rem 0.08rem;
  background: #52f4e8;
  font-size: clamp(0.72rem, 0.2vw + 0.68rem, 0.82rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: 0.02em;
}

.project-card-empty-index {
  align-self: end;
  justify-self: end;
  font-family: "SuisseScreen", sans-serif;
  font-size: clamp(7rem, 17vw, 15rem);
  font-weight: 700;
  line-height: 0.72;
  letter-spacing: -0.09em;
}

.slide {
  width: 100%;
  flex-shrink: 0;
  height: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.25rem;
}

.project-image-trigger {
  display: grid;
  place-items: center;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: zoom-in;
  border-radius: 1rem;
  aspect-ratio: var(--project-media-ratio, auto);
}

.project-image-trigger:focus-visible {
  outline: 2px solid #000;
  outline-offset: 4px;
}

.slide img {
  display: block;
  width: 100%;
  max-width: 100%;
  height: 100%;
  max-height: min(88vh, 920px);
  object-fit: contain;
  border-radius: 1rem;
}

/* Slider Nav */
.project-slider-nav {
  position: absolute;
  top: 50%;
  z-index: 5;
  width: 2.75rem;
  height: 2.75rem;
  margin-top: -1.375rem;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.96);
  color: #000;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
  cursor: pointer;
  transition: background 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.project-slider-nav:hover {
  background: #fff;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);
  transform: scale(1.06);
}

.project-slider-nav:active {
  transform: scale(0.96);
}

.project-slider-nav--prev {
  left: 0.5rem;
}

.project-slider-nav--next {
  right: 0.5rem;
}

.project-slider-nav:focus-visible {
  outline: 2px solid #000;
  outline-offset: 2px;
}

/* Lightbox */
.project-lightbox {
  position: fixed;
  inset: 0;
  z-index: 5000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.project-lightbox[hidden] {
  display: none;
}

.project-lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.project-lightbox-dialog {
  position: relative;
  z-index: 1;
  width: min(92vw, 1200px);
  max-height: calc(100dvh - 4rem);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  grid-template-rows: minmax(0, 1fr) auto;
  align-items: center;
  gap: 1rem;
}

.project-lightbox-close {
  position: absolute;
  top: -0.25rem;
  right: 0;
  z-index: 2;
  padding: 0.75rem 1rem;
  border: 2px solid #000;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  color: #000;
  cursor: pointer;
  touch-action: manipulation;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 700;
  font-style: normal;
  line-height: 1;
  transition: background 0.2s ease, color 0.2s ease;
}

.project-lightbox-close:hover,
.project-lightbox-close:focus-visible {
  background: #000;
  color: #fff;
  filter: none;
}

.project-lightbox-figure {
  grid-column: 2;
  grid-row: 1;
  margin: 0;
  min-width: 0;
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.project-lightbox-image {
  display: block;
  max-width: 100%;
  max-height: calc(100dvh - 9rem);
  width: auto;
  height: auto;
  border-radius: 1.25rem;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.14);
}

.project-lightbox-nav {
  position: relative;
  z-index: 1;
  width: 3rem;
  height: 3rem;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.96);
  color: #000;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
  cursor: pointer;
  transition: background 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.project-lightbox-nav:hover,
.project-lightbox-nav:focus-visible {
  background: #fff;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);
  transform: scale(1.04);
  filter: none;
}

.project-lightbox-nav:disabled {
  opacity: 0.35;
  cursor: default;
  transform: none;
}

.project-lightbox-nav--prev {
  grid-column: 1;
  grid-row: 1;
}

.project-lightbox-nav--next {
  grid-column: 3;
  grid-row: 1;
}

.project-lightbox-meta {
  grid-column: 2;
  grid-row: 2;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  font-family: "SuisseScreen", sans-serif;
  color: #000;
}

.project-lightbox-project,
.project-lightbox-counter {
  margin: 0;
  font-weight: 700;
  font-style: normal;
  font-size: 0.95rem;
  line-height: 1.2;
}

body.project-lightbox-open {
  overflow: hidden;
}

/* Sidepanel */
.project-card a,
.project-card button:not(.project-slider-nav),
.project-card video,
.project-card iframe {
  position: relative;
  z-index: 5;
}

.project-card .project-slider-nav {
  position: absolute;
  z-index: 6;
}

.project-sidepanel {
  position: fixed;
  top: 0;
  right: 0;
  width: 50vw;
  height: 100dvh;
  z-index: 3000;
  background: rgba(255, 255, 255, 0.96);
  border-left: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: -10px 0 30px rgba(0, 0, 0, 0.08);
  transform: translateX(100%);
  transition: transform 0.35s ease;
}

.project-sidepanel.active {
  transform: translateX(0);
}

body.project-sidepanel-open {
  overflow: hidden;
}

body.project-sidepanel-open .footer-links {
  opacity: 1;
  pointer-events: auto;
}

body.project-sidepanel-open .project-sidepanel-scroll {
  padding-bottom: calc(7rem + env(safe-area-inset-bottom));
}

.project-sidepanel-close {
  position: absolute;
  top: 20px;
  right: 20px;
  z-index: 5;
  padding: 10px 18px;
  border: 2px solid #000;
  border-radius: 50px;
  background: rgba(255, 255, 255, 0.92);
  color: #000;
  cursor: pointer;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 700;
  font-style: normal;
  transition: background 0.25s ease, color 0.25s ease, transform 0.2s ease;
}

.project-sidepanel-close:hover {
  background: #000;
  color: #fff;
}

.project-sidepanel-close:active {
  transform: scale(0.97);
}

.project-sidepanel-scroll {
  height: 100dvh;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 96px 48px 64px;
}

.project-sidepanel-inner {
  max-width: 42rem;
  color: #000;
  font-family: "SuisseScreen", sans-serif;
}

.project-sidepanel-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 2rem;
}

.project-sidepanel-header h2 {
  margin: 0;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 700;
  font-style: normal;
  font-size: clamp(2rem, 3vw, 3.4rem);
  line-height: 0.98;
  letter-spacing: -0.03em;
  color: #000;
}

.project-sidepanel-header span {
  white-space: nowrap;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 700;
  font-style: normal;
  font-size: clamp(2rem, 3vw, 3.4rem);
  line-height: 0.98;
  letter-spacing: -0.03em;
  color: #000;
}

.project-sidepanel-copy {
  color: #000;
  font-family: "SuisseScreen", sans-serif;
}

.project-sidepanel-copy .project-card-description {
  max-width: none;
  font-size: 1.08rem;
  line-height: 1.8;
}

.project-sidepanel-copy h1,
.project-sidepanel-copy h2,
.project-sidepanel-copy h3,
.project-sidepanel-copy h4 {
  margin: 2rem 0 1rem;
  color: #000;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 700;
  font-style: normal;
}

.project-sidepanel-copy p,
.project-sidepanel-copy a {
  color: #000;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 500;
  font-style: normal;
  hyphens: auto;
  overflow-wrap: anywhere;
}

.project-side-extra {
  display: none;
}

.project-sidepanel-copy .project-side-extra {
  display: block;
}

.project-side-inline-art {
  float: right;
  clear: right;
  width: min(15rem, 42%);
  margin: 0.35rem 0 1.35rem 1.5rem;
  padding: 0.85rem;
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: 1.15rem;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(246, 246, 246, 0.92));
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.08);
}

.project-side-inline-art img {
  display: block;
  width: 100%;
  height: auto;
}

.project-side-inline-art-stack {
  float: right;
  clear: right;
  width: min(15rem, 42%);
  margin: 0.35rem 0 1.35rem 1.5rem;
}

.project-side-inline-art-stack .project-side-inline-art {
  float: none;
  clear: none;
  width: 100%;
  margin: 0 0 1rem 0;
}

.project-side-inline-art-stack .project-side-inline-art:last-child {
  margin-bottom: 0;
}

.app-link-preview-wrap {
  position: relative;
  display: inline-flex;
  align-items: stretch;
  width: min(100%, 22rem);
  margin-top: 0.35rem;
  vertical-align: top;
}

.app-preview-link {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.95rem;
  width: 100%;
  padding: 0.82rem 1rem 0.9rem;
  border: 1px solid rgba(0, 0, 0, 0.14);
  border-radius: 1.1rem;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(246, 246, 246, 0.94));
  box-shadow:
    0 14px 30px rgba(0, 0, 0, 0.08),
    0 1px 0 rgba(255, 255, 255, 0.7) inset;
  text-decoration: none;
  font-weight: 700 !important;
  line-height: 1.1;
  transition:
    transform 0.32s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.32s ease,
    border-color 0.32s ease,
    background 0.32s ease,
    filter 0.2s ease;
}

.app-preview-link::after {
  content: "↗";
  display: inline-grid;
  place-items: center;
  width: 2.1rem;
  height: 2.1rem;
  border-radius: 999px;
  background: #111;
  color: #fff;
  font-size: 0.98rem;
  line-height: 1;
  box-shadow: 0 10px 18px rgba(0, 0, 0, 0.14);
}

.app-preview-link:hover,
.app-preview-link:focus-visible {
  filter: none !important;
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.96);
  border-color: rgba(0, 0, 0, 0.24);
  box-shadow:
    0 22px 42px rgba(0, 0, 0, 0.13),
    0 1px 0 rgba(255, 255, 255, 0.78) inset;
}

.app-preview-link-copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.28rem;
  min-width: 0;
}

.app-preview-link-label {
  display: block;
  max-width: 100%;
  font-size: 0.98rem;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.01em;
}

.app-preview-link-meta {
  display: block;
  max-width: 100%;
  font-size: 0.72rem;
  line-height: 1.2;
  letter-spacing: 0.01em;
  opacity: 0.62;
}

.app-preview-window {
  position: absolute;
  top: calc(100% + 1rem);
  left: 0;
  width: clamp(18rem, 34vw, 28rem);
  border: 1px solid rgba(0, 0, 0, 0.12);
  border-radius: 1.2rem;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 28px 60px rgba(0, 0, 0, 0.16);
  opacity: 0;
  transform: translateY(16px) scale(0.96) rotate(-1deg);
  transform-origin: top left;
  pointer-events: none;
  z-index: 24;
  transition:
    opacity 0.34s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.42s cubic-bezier(0.22, 1, 0.36, 1),
    filter 0.34s ease;
  filter: blur(10px);
}

.app-link-preview-wrap:hover .app-preview-window,
.app-link-preview-wrap:focus-within .app-preview-window {
  opacity: 1;
  transform: translateY(0) scale(1) rotate(0deg);
  filter: blur(0);
}

.app-preview-window-bar {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 0.72rem 0.9rem;
  background: #111;
  color: #fff;
}

.app-preview-window-dots {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.app-preview-window-dots span {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
}

.app-preview-window-dots span:nth-child(1) {
  background: #ff5f57;
}

.app-preview-window-dots span:nth-child(2) {
  background: #febc2e;
}

.app-preview-window-dots span:nth-child(3) {
  background: #28c840;
}

.app-preview-window-title {
  min-width: 0;
  flex: 1 1 auto;
  font-size: 0.82rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.app-preview-window-pill {
  flex: 0 0 auto;
  padding: 0.2rem 0.5rem;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  font-size: 0.72rem;
  letter-spacing: 0.01em;
  text-transform: uppercase;
}

.app-preview-window-image {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  background: #f5f5f5;
}

.app-preview-window-footer {
  display: block;
  padding: 0.7rem 0.9rem 0.82rem;
  background: rgba(255, 255, 255, 0.92);
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  font-size: 0.78rem;
  line-height: 1.25;
  letter-spacing: -0.01em;
  color: rgba(0, 0, 0, 0.72);
}

/* Videos */
.project-side-videos {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin: 0 0 2rem 0;
}

.project-side-video-wrap {
  width: 100%;
}

.project-side-youtube-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1rem;
  margin: 0 0 2rem 0;
}

.project-side-youtube-grid.has-multiple {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.project-side-youtube-grid.has-featured-first .project-side-video-wrap:first-child {
  grid-column: 1 / -1;
}

.project-sidepanel-video {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 1rem;
  background: #000;
}

.youtube-embed {
  position: relative;
  width: 100%;
  height: 0;
  padding-bottom: 56.25%;
  overflow: hidden;
  border-radius: 1rem;
  background: #000;
}

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

.instagram-embed {
  display: flex;
  justify-content: center;
  margin: 0 0 2rem 0;
}

.project-instagram-embed {
  width: 100% !important;
  max-width: 33rem !important;
  min-width: 16rem !important;
  margin: 0 auto !important;
  border-radius: 1rem !important;
  overflow: hidden !important;
}

@media (max-width: 980px) {
  .project-side-youtube-grid.has-multiple {
    grid-template-columns: minmax(0, 1fr);
  }

  .app-link-preview-wrap {
    display: flex;
    width: 100%;
  }

  .app-preview-link {
    width: 100%;
  }

  .app-preview-window {
    display: none;
  }
}

/* Footer */
.footer-links {
  position: fixed;
  right: clamp(1rem, 2vw, 2rem);
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 1rem;
  z-index: 10;
  font-family: "SuisseScreen", sans-serif;
}

.footer-links .hero-link {
  writing-mode: vertical-rl;
  text-orientation: mixed;
  padding: 1rem;
  border: 2px solid #000;
  border-radius: 50px;
  background: rgba(255, 255, 255, 0.82);
  color: #000;
  text-decoration: none;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 700;
  font-style: normal;
  font-size: 1rem;
  letter-spacing: 0.01em;
}

/* Imprint */
.content-wrapper {
  height: 100%;
  overflow-y: auto;
  padding: 2rem;
}

.impressum {
  max-width: 800px;
  margin: 0 auto;
  padding: 2rem;
  overflow-y: auto;
  color: #000;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 500;
  font-style: normal;
}

.impressum .intro-title,
.intro-title {
  margin-bottom: 2rem;
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  line-height: 0.98;
  letter-spacing: -0.03em;
  color: #000;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 700;
  font-style: normal;
}

.imprint-page {
  min-height: 100vh;
  width: 100%;
  background: #fff;
  background-image: var(--imprint-fallback-image);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  overflow-y: auto;
  position: relative;
  padding: 4rem;
}

.imprint-page.has-animated-background {
  isolation: isolate;
}

.imprint-page .intro-background {
  position: fixed;
  inset: 0;
  z-index: 0;
}

.imprint-content-wrapper {
  max-width: 800px;
  margin: 0 auto;
  padding: 2rem;
  color: #000;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 500;
  font-style: normal;
  position: relative;
  z-index: 2;
}

.imprint-page.has-animated-background .imprint-content-wrapper {
  background: rgba(255, 255, 255, 0.76);
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 1.5rem;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.08);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.imprint-page .footer-links {
  z-index: 3;
}

.imprint-content,
.imprint-text {
  margin-top: 2rem;
  font-size: 1.05rem;
  line-height: 1.7;
  color: #000;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 500;
  font-style: normal;
}

.imprint-content p,
.imprint-text p {
  margin-bottom: 1rem;
}

.imprint-content strong,
.imprint-text strong {
  font-family: "SuisseScreen", sans-serif;
  font-weight: 700;
  font-style: normal;
  color: #000;
}

/* Responsive */
@media (max-width: 768px) {
  .intro-section {
    padding: 2rem 1.25rem;
  }

  .intro-text h1 {
    font-size: clamp(3rem, 13vw, 4.8rem);
    line-height: 0.96;
    margin-bottom: 1.5rem;
  }

  .intro-text p,
  .intro-copy,
  .intro-copy p {
    font-size: 1.1rem;
    line-height: 1.55;
    max-width: 100%;
  }

  .project-card-inner {
    flex-direction: column;
    padding: 1.25rem;
    gap: 1.5rem;
    cursor: pointer;
  }

  .project-card-content,
  .project-card-slider {
    min-width: 100%;
    max-width: none;
  }

  .project-card-content {
    overflow: visible;
    padding-right: 0;
  }

  .project-card-slider {
    flex: 1 1 auto;
    height: auto;
    min-height: 0;
    padding: 0.5rem 0 0;
  }

  .slide img {
    aspect-ratio: 3 / 2;
    width: 100%;
    height: 100%;
    max-height: min(42svh, 24rem);
    object-fit: cover;
  }

  .project-card-header {
    gap: 1rem;
    margin-bottom: 1rem;
  }

  .project-card-header h2.text-large {
    max-width: 100%;
    font-size: 1.85rem;
    line-height: 1.02;
  }

  .project-card-header span,
  .project-card-header span.text-large,
  .project-sidepanel-header span {
    font-size: 1.85rem;
    line-height: 1.02;
    letter-spacing: -0.03em;
  }

  .project-card-description {
    max-width: 100%;
    font-size: 1rem;
    line-height: 1.66;
  }

  .project-link-text {
    font-size: 0.95rem;
  }

  .project-slider-nav {
    width: 2.6rem;
    height: 2.6rem;
    margin-top: -1.3rem;
  }

  .project-slider-nav {
    touch-action: manipulation;
  }

  .project-slider-nav svg {
    width: 22px;
    height: 22px;
  }

  .project-slider-nav--prev {
    left: 0.35rem;
  }

  .project-slider-nav--next {
    right: 0.35rem;
  }

  .project-lightbox {
    padding: 1rem;
  }

  .project-lightbox-dialog {
    width: 100%;
    max-height: calc(100dvh - 2rem);
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto minmax(0, 1fr) auto auto;
    gap: 0.75rem;
  }

  .project-lightbox-close {
    position: relative;
    top: auto;
    right: auto;
    justify-self: end;
  }

  .project-lightbox-figure {
    grid-column: 1;
    grid-row: 2;
  }

  .project-lightbox-image {
    max-height: calc(100dvh - 11rem);
  }

  .project-lightbox-nav {
    width: 2.75rem;
    height: 2.75rem;
  }

  .project-lightbox-nav--prev,
  .project-lightbox-nav--next {
    grid-row: 3;
  }

  .project-lightbox-nav--prev {
    grid-column: 1;
    justify-self: start;
  }

  .project-lightbox-nav--next {
    grid-column: 1;
    justify-self: end;
  }

  .project-lightbox-meta {
    grid-column: 1;
    grid-row: 4;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
  }

  .project-side-inline-art {
    float: none;
    width: min(100%, 16rem);
    margin: 0.75rem 0 1.25rem;
  }

  .project-side-inline-art-stack {
    float: none;
    width: min(100%, 16rem);
    margin: 0.75rem 0 1.25rem;
  }

  .footer-links {
    position: relative;
    right: auto;
    top: auto;
    transform: none;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    padding: 2rem;
    margin-top: 2rem;
    gap: 0.75rem;
  }

  .footer-links .hero-link {
    writing-mode: horizontal-tb;
    text-orientation: mixed;
    padding: 0.6rem 1rem;
    font-size: 0.95rem;
  }

  .project-sidepanel {
    width: 100vw;
  }

  .project-sidepanel-scroll {
    padding: 88px 24px 48px;
  }

  .imprint-page {
    padding: 2rem;
  }

  .imprint-page.has-animated-background .imprint-content-wrapper {
    padding: 1.5rem;
    border-radius: 1.25rem;
  }

  .imprint-content,
  .imprint-text {
    font-size: 1rem;
  }

  .intro-title,
  .impressum .intro-title {
    font-size: 2.5rem;
  }
}

@media (hover: none), (pointer: coarse) {
  .hover-image {
    display: none;
  }

  .project-card-inner:hover {
    transform: none;
  }
}

/* Responsive card contents; the outer stack geometry stays unchanged. */
@media (max-width: 1180px), (hover: none), (pointer: coarse) {
  body {
    overflow-x: clip;
  }

  .intro-section {
    width: 100%;
    padding: clamp(2rem, 6vw, 4rem) clamp(1.25rem, 5vw, 3rem)
      calc(6.5rem + env(safe-area-inset-bottom));
  }

  .intro-text {
    min-height: 0;
  }

  .project-card-inner {
    display: grid;
    grid-template-columns: minmax(18rem, 0.9fr) minmax(0, 1.1fr);
    padding: clamp(1.25rem, 2.5vw, 2rem);
    gap: clamp(1.5rem, 3vw, 2.5rem);
    align-items: start;
    border-radius: clamp(1.25rem, 2.5vw, 2rem);
  }

  .project-card-content {
    width: 100%;
    min-width: 0;
    max-width: none;
    min-height: 0;
    padding-right: 0;
    overflow: visible;
  }

  .project-card-description {
    max-width: 42rem;
  }

  .project-card-slider {
    width: 100%;
    min-width: 0;
    min-height: 0;
    height: auto;
    align-self: start;
    overflow: hidden;
  }

  .slider,
  .slide {
    min-height: 0;
    height: auto;
  }

  .slide img {
    width: 100%;
    height: 100%;
    max-height: min(72svh, 50rem);
    object-fit: contain;
  }

  .project-slider-nav {
    min-width: 2.75rem;
    min-height: 2.75rem;
  }

  .project-sidepanel {
    width: min(100vw, 48rem);
  }

  .project-sidepanel-close {
    top: max(1rem, env(safe-area-inset-top));
    right: max(1rem, env(safe-area-inset-right));
  }

  .project-sidepanel-scroll {
    padding-top: calc(5.5rem + env(safe-area-inset-top));
    padding-right: max(clamp(1.25rem, 4vw, 3rem), env(safe-area-inset-right));
    padding-bottom: calc(3rem + env(safe-area-inset-bottom));
    padding-left: max(clamp(1.25rem, 4vw, 3rem), env(safe-area-inset-left));
  }

  .footer-links {
    position: fixed;
    top: auto;
    right: max(1rem, env(safe-area-inset-right));
    bottom: max(1rem, env(safe-area-inset-bottom));
    left: auto;
    z-index: 4500;
    transform: none;
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
    gap: 0.45rem;
    width: auto;
    margin: 0;
    padding: 0.45rem;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 0.45rem 1.5rem rgba(0, 0, 0, 0.1);
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
  }

  .footer-links .hero-link {
    flex: 0 0 auto;
    padding: 0.72rem 0.85rem;
    writing-mode: horizontal-tb;
    text-orientation: mixed;
    font-size: 0.84rem;
    line-height: 1;
  }

  .language-links {
    order: 0;
    flex: 0 0 auto;
    flex-direction: row;
    align-self: auto;
  }

  .language-link-button {
    min-width: 2.35rem;
    min-height: 2.35rem;
    padding: 0.62rem 0.68rem;
    writing-mode: horizontal-tb;
    text-orientation: mixed;
    font-size: 0.78rem;
  }

  .imprint-page {
    min-height: 100vh;
    min-height: 100svh;
    padding-right: max(clamp(1.25rem, 5vw, 4rem), env(safe-area-inset-right));
    padding-bottom: calc(7rem + env(safe-area-inset-bottom));
    padding-left: max(clamp(1.25rem, 5vw, 4rem), env(safe-area-inset-left));
  }
}

@media (max-width: 900px) {
  .project-card-inner {
    display: flex;
    flex-direction: column;
  }

  .project-card-content,
  .project-card-slider {
    width: 100%;
    max-width: none;
  }

  .project-card-slider {
    padding-top: 0;
  }

  .slide img {
    max-height: min(58svh, 42rem);
  }
}

@media (max-width: 700px) {
  .intro-section {
    min-height: 100vh;
    min-height: 100svh;
    padding-top: max(1.75rem, env(safe-area-inset-top));
    padding-right: max(1.1rem, env(safe-area-inset-right));
    padding-bottom: calc(6.25rem + env(safe-area-inset-bottom));
    padding-left: max(1.1rem, env(safe-area-inset-left));
  }

  .intro-text h1 {
    max-width: 12ch;
    font-size: clamp(2.65rem, 13vw, 4.4rem);
    line-height: 0.94;
  }

  .intro-copy,
  .intro-copy p,
  .intro-text p {
    font-size: clamp(0.98rem, 4vw, 1.08rem);
    line-height: 1.52;
  }

  .project-card-inner {
    min-height: 0;
    padding: clamp(1rem, 4.5vw, 1.3rem);
    gap: 1.25rem;
    border-radius: 1.35rem;
  }

  .project-card-header {
    gap: 0.75rem 1rem;
    margin-bottom: 0.9rem;
  }

  .project-card-header h2,
  .project-card-header h2.text-large,
  .project-card-header span,
  .project-card-header span.text-large {
    font-size: clamp(1.65rem, 7.2vw, 2.15rem);
    line-height: 0.98;
  }

  .project-card-header h2,
  .project-card-header h2.text-large {
    max-width: 100%;
  }

  .project-card-description {
    max-width: none;
    font-size: clamp(0.94rem, 3.7vw, 1rem);
    line-height: 1.58;
  }

  .project-link-container {
    margin-top: 1.25rem;
  }

  .slide img {
    max-height: 52svh;
  }

  .project-sidepanel {
    width: 100vw;
    border-left: 0;
  }

  .project-sidepanel-header {
    flex-wrap: wrap;
    gap: 0.75rem 1rem;
  }

  .project-sidepanel-header h2,
  .project-sidepanel-header span {
    font-size: clamp(1.75rem, 8vw, 2.35rem);
  }

  .project-sidepanel-copy,
  .project-sidepanel-copy p,
  .project-sidepanel-copy li {
    font-size: clamp(0.96rem, 3.7vw, 1.02rem);
    line-height: 1.62;
  }

  .project-sidepanel-scroll {
    padding-top: calc(5rem + env(safe-area-inset-top));
    padding-right: max(1rem, env(safe-area-inset-right));
    padding-bottom: calc(2.5rem + env(safe-area-inset-bottom));
    padding-left: max(1rem, env(safe-area-inset-left));
  }

  .project-side-inline-art,
  .project-side-inline-art-stack {
    width: 100%;
    max-width: 20rem;
  }

  .project-lightbox {
    padding-top: max(0.75rem, env(safe-area-inset-top));
    padding-right: max(0.75rem, env(safe-area-inset-right));
    padding-bottom: max(0.75rem, env(safe-area-inset-bottom));
    padding-left: max(0.75rem, env(safe-area-inset-left));
  }

  .project-lightbox-image {
    max-height: 70svh;
  }

  .footer-links {
    right: max(0.65rem, env(safe-area-inset-right));
    bottom: max(0.65rem, env(safe-area-inset-bottom));
    left: max(0.65rem, env(safe-area-inset-left));
    justify-content: center;
    gap: 0.3rem;
    width: auto;
    max-width: none;
    padding: 0.35rem;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .footer-links::-webkit-scrollbar {
    display: none;
  }

  .footer-links .hero-link {
    min-height: 2.75rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.62rem 0.72rem;
    font-size: clamp(0.72rem, 3.2vw, 0.82rem);
  }

  .language-link-button {
    min-width: 2.75rem;
    min-height: 2.75rem;
    padding: 0.52rem 0.58rem;
    font-size: 0.72rem;
  }

  .imprint-page.has-animated-background .imprint-content-wrapper {
    padding: clamp(1rem, 4vw, 1.5rem);
  }
}

@media (max-width: 390px) {
  .footer-links .hero-link {
    padding-right: 0.56rem;
    padding-left: 0.56rem;
  }

  .language-link-button {
    min-width: 2.75rem;
    padding-right: 0.48rem;
    padding-left: 0.48rem;
  }

  .project-sidepanel-close {
    min-height: 2.75rem;
    padding: 0.6rem 0.8rem;
    font-size: 0.8rem;
  }
}

@media (max-height: 720px) and (min-width: 701px) {
  .intro-section {
    align-items: flex-start;
    min-height: 100vh;
    min-height: 100svh;
    padding-top: max(1.5rem, env(safe-area-inset-top));
    padding-bottom: calc(5.5rem + env(safe-area-inset-bottom));
  }

  .intro-text h1 {
    margin-bottom: 1rem;
    font-size: clamp(2.75rem, 8vh, 4.5rem);
  }

  .intro-copy,
  .intro-copy p,
  .intro-text p {
    font-size: clamp(0.95rem, 2.6vh, 1.15rem);
    line-height: 1.45;
  }

  .project-sidepanel-scroll {
    padding-top: calc(4.75rem + env(safe-area-inset-top));
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

:where(a, button, [tabindex]):focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 3px;
}

/* =========================
   PROJECT TYPOGRAPHY
   Final, shared reading rules for cards and side panels.
   ========================= */

:root {
  --project-title-size: clamp(1.95rem, 2.5vw, 3rem);
  --project-panel-title-size: clamp(2rem, 2.8vw, 3.25rem);
  --project-copy-size: clamp(1rem, 0.35vw + 0.94rem, 1.075rem);
  --project-panel-copy-size: clamp(1rem, 0.28vw + 0.96rem, 1.08rem);
  --project-copy-leading: 1.66;
  --project-panel-leading: 1.7;
  --project-copy-measure: 60ch;
}

.project-card-content,
.project-sidepanel-copy {
  min-width: 0;
}

.project-card-header,
.project-sidepanel-header {
  column-gap: clamp(0.85rem, 1.4vw, 1.4rem);
  row-gap: 0.6rem;
}

.project-card-header .project-title-wrap,
.project-sidepanel-header .project-title-wrap {
  min-width: 0;
  flex: 1 1 12rem;
}

.project-card-header h2,
.project-card-header h2.text-large,
.project-card-header span,
.project-card-header span.text-large {
  font-family: "SuisseScreen", sans-serif;
  font-size: var(--project-title-size);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: -0.035em;
}

.project-card-header h2,
.project-card-header h2.text-large {
  max-width: 12ch;
  text-wrap: balance;
  overflow-wrap: break-word;
}

.project-card-header span,
.project-card-header span.text-large,
.project-sidepanel-header span {
  font-variant-numeric: tabular-nums;
}

.project-card-description,
.project-card-description p,
.project-card-description li {
  font-size: var(--project-copy-size);
  line-height: var(--project-copy-leading);
  letter-spacing: -0.004em;
}

.project-card-description {
  width: 100%;
  max-width: min(100%, var(--project-copy-measure));
  text-wrap: pretty;
  overflow-wrap: break-word;
  hyphens: auto;
}

.project-card-description p {
  margin: 0 0 0.9em;
}

.project-card-description p + p {
  margin-top: 0;
}

.project-card-description p:last-child {
  margin-bottom: 0;
}

.project-card-description ul,
.project-card-description ol,
.project-sidepanel-copy ul,
.project-sidepanel-copy ol {
  padding-left: 1.35em;
}

.project-card-description li + li,
.project-sidepanel-copy li + li {
  margin-top: 0.4em;
}

.project-card-description a,
.project-sidepanel-copy a {
  text-decoration-thickness: 1px;
  text-underline-offset: 0.16em;
}

/* The card carries a short teaser; the complete introduction belongs to the panel. */
.project-sidepanel-intro {
  display: none;
}

.project-sidepanel-facts {
  display: none;
}

.project-sidepanel-copy > .project-sidepanel-facts {
  display: block;
}

.project-sidepanel-copy > .project-sidepanel-intro {
  display: block;
  margin-bottom: clamp(1.8rem, 4vw, 3rem);
}

.project-sidepanel-copy > .project-sidepanel-intro::after {
  display: block;
  width: 100%;
  height: 1px;
  margin-top: clamp(1.5rem, 3vw, 2.25rem);
  background: currentColor;
  opacity: 0.18;
  content: "";
}

.project-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  width: 100%;
  margin: 0 0 clamp(2.25rem, 5vw, 3.5rem);
  padding: 0;
  border-top: 1px solid rgba(0, 0, 0, 0.28);
  border-left: 1px solid rgba(0, 0, 0, 0.28);
}

.project-fact {
  min-width: 0;
  padding: clamp(0.8rem, 2vw, 1.1rem);
  border-right: 1px solid rgba(0, 0, 0, 0.28);
  border-bottom: 1px solid rgba(0, 0, 0, 0.28);
}

.project-fact dt,
.project-fact dd {
  margin: 0;
}

.project-fact-label.project-lang-block.is-active {
  display: inline-block;
  width: fit-content;
  margin-bottom: 0.65rem;
  padding: 0.12rem 0.32rem 0.08rem;
  background: #52f4e8;
  font-size: clamp(0.7rem, 0.15vw + 0.68rem, 0.78rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: 0.025em;
  text-transform: uppercase;
}

.project-fact-value.project-lang-block.is-active {
  display: block;
  font-size: clamp(0.94rem, 0.25vw + 0.9rem, 1.02rem);
  line-height: 1.38;
  letter-spacing: -0.006em;
  overflow-wrap: anywhere;
}

.project-sidepanel-header h2,
.project-sidepanel-header span {
  font-family: "SuisseScreen", sans-serif;
  font-size: var(--project-panel-title-size);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: -0.035em;
}

.project-sidepanel-header h2 {
  max-width: 12ch;
  text-wrap: balance;
  overflow-wrap: break-word;
}

.project-sidepanel-copy,
.project-sidepanel-copy p,
.project-sidepanel-copy li,
.project-sidepanel-copy .project-card-description,
.project-sidepanel-copy .project-card-description p,
.project-sidepanel-copy .project-card-description li {
  font-size: var(--project-panel-copy-size);
  line-height: var(--project-panel-leading);
  letter-spacing: -0.004em;
}

.project-sidepanel-copy,
.project-sidepanel-copy .project-card-description {
  max-width: var(--project-copy-measure);
  text-wrap: pretty;
  overflow-wrap: break-word;
  hyphens: auto;
}

.project-sidepanel-copy h1,
.project-sidepanel-copy h2,
.project-sidepanel-copy h3,
.project-sidepanel-copy h4 {
  margin: 2.2rem 0 0.7rem;
  font-family: "SuisseScreen", sans-serif;
  font-size: clamp(1rem, 0.25vw + 0.96rem, 1.1rem);
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.01em;
  text-transform: none;
}

.project-sidepanel-copy p {
  margin: 0 0 0.95em;
}

.project-sidepanel-copy p:last-child {
  margin-bottom: 0;
}

.project-link-text {
  font-size: clamp(0.9rem, 0.2vw + 0.87rem, 0.98rem);
  line-height: 1.45;
}

@media (max-width: 1180px) {
  :root {
    --project-title-size: clamp(1.85rem, 3.5vw, 2.65rem);
    --project-panel-title-size: clamp(1.9rem, 4vw, 2.8rem);
    --project-copy-size: clamp(1rem, 0.5vw + 0.95rem, 1.06rem);
  }
}

@media (max-width: 700px) {
  :root {
    --project-title-size: clamp(1.65rem, 6.5vw, 2rem);
    --project-panel-title-size: clamp(1.7rem, 6.8vw, 2.1rem);
    --project-copy-size: clamp(1rem, 1.3vw + 0.94rem, 1.04rem);
    --project-panel-copy-size: clamp(1rem, 1.25vw + 0.94rem, 1.04rem);
    --project-copy-leading: 1.62;
    --project-panel-leading: 1.64;
  }

  .project-card-header,
  .project-sidepanel-header {
    column-gap: 0.8rem;
    row-gap: 0.5rem;
  }

  .project-card-header h2,
  .project-card-header h2.text-large,
  .project-sidepanel-header h2 {
    max-width: 11ch;
  }

  .project-card-content {
    scrollbar-gutter: auto;
  }

  .project-sidepanel-copy h1,
  .project-sidepanel-copy h2,
  .project-sidepanel-copy h3,
  .project-sidepanel-copy h4 {
    margin-top: 1.8rem;
    font-size: 1rem;
  }

  .project-sidepanel-copy > .project-sidepanel-intro {
    margin-bottom: 1.6rem;
  }

  .project-facts {
    grid-template-columns: minmax(0, 1fr);
    margin-bottom: 2.25rem;
  }
}

@media (max-width: 390px) {
  :root {
    --project-title-size: clamp(1.5rem, 6.6vw, 1.7rem);
    --project-panel-title-size: clamp(1.55rem, 6.8vw, 1.8rem);
    --project-copy-size: 1rem;
    --project-panel-copy-size: 1rem;
  }
}

/* =========================
   DESKTOP CARD CONTENT
   ========================= */

@media (min-width: 1181px) and (hover: hover) and (pointer: fine) {
  .project-card-inner {
    padding: clamp(1.35rem, 1.7vw, 2rem);
    gap: clamp(1.4rem, 2vw, 2.5rem);
  }

  .project-card-content {
    flex-basis: 40%;
    min-width: min(36%, 25rem);
    max-width: 42%;
  }

  .project-card-slider {
    min-width: 50%;
  }
}

@media (min-width: 1181px) and (max-height: 860px) and (hover: hover) and (pointer: fine) {
  :root {
    --project-title-size: clamp(1.7rem, 2.2vw, 2rem);
    --project-copy-size: 1rem;
    --project-copy-leading: 1.5;
  }

  .project-card-inner {
    padding: clamp(1.05rem, 1.35vw, 1.35rem);
    gap: clamp(1rem, 1.5vw, 1.35rem);
  }

  .project-card-content {
    flex-basis: 47%;
    min-width: 43%;
    max-width: 47%;
    overflow-y: visible;
  }

  .project-card-slider {
    min-width: 46%;
  }

  .project-card-header {
    margin-bottom: 0.8rem;
  }

  .project-card-description p {
    margin-bottom: 0.65em;
  }

  .project-link-container {
    margin-top: 0.9rem;
  }
}

/* =========================
   FINAL INTERACTION LAYER
   Clear project entry points and a calm, accessible panel transition.
   ========================= */

.skip-link {
  position: fixed;
  top: max(0.75rem, env(safe-area-inset-top));
  left: 0.75rem;
  z-index: 10000;
  padding: 0.65rem 0.9rem;
  border: 2px solid #000;
  border-radius: 999px;
  background: #fff;
  color: #000;
  font-family: "SuisseScreen", sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
  transform: translateY(calc(-100% - 1rem));
  transition: transform 0.2s ease;
}

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

.project-open-button {
  display: inline-flex;
  align-items: center;
  align-self: flex-start;
  justify-content: space-between;
  gap: 0.8rem;
  min-height: 2.65rem;
  margin-top: clamp(1.1rem, 2.4vh, 1.75rem);
  padding: 0.58rem 0.85rem 0.54rem;
  border: 1.5px solid currentColor;
  border-radius: 999px;
  background: transparent;
  color: #000;
  cursor: pointer;
  font-family: "SuisseScreen", sans-serif;
  font-size: clamp(0.86rem, 0.2vw + 0.83rem, 0.94rem);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.01em;
  transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.project-open-button svg {
  flex: 0 0 auto;
  transition: transform 0.2s ease;
}

.project-open-button:hover,
.project-open-button:focus-visible {
  background: #000;
  color: #fff;
}

.project-open-button:hover svg,
.project-open-button:focus-visible svg {
  transform: translate(0.14rem, -0.14rem);
}

.project-open-button:active {
  transform: scale(0.98);
}

.project-open-button:focus-visible,
.project-sidepanel-close:focus-visible {
  outline: 3px solid #52f4e8;
  outline-offset: 3px;
}

.project-sidepanel-backdrop {
  position: fixed;
  inset: 0;
  z-index: 2990;
  background: rgba(0, 0, 0, 0.2);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.project-sidepanel-backdrop.active {
  opacity: 1;
  pointer-events: auto;
}

.project-sidepanel {
  width: min(54rem, 58vw);
  background: rgba(255, 255, 255, 0.985);
}

.project-sidepanel-scroll {
  scrollbar-gutter: stable;
  scroll-padding-top: 6rem;
  overscroll-behavior-y: contain;
}

@media (max-width: 1180px) {
  .project-sidepanel {
    width: min(100vw, 48rem);
  }

  .project-card-slider.is-empty {
    min-height: clamp(20rem, 46vw, 30rem);
  }
}

@media (max-width: 700px) {
  .project-open-button {
    min-height: 2.55rem;
    margin-top: 1rem;
    padding-inline: 0.78rem;
  }

  .project-sidepanel-scroll {
    scrollbar-gutter: auto;
  }

  .project-card-slider.is-empty {
    min-height: clamp(13rem, 62vw, 19rem);
  }

  .project-card-empty-visual {
    padding: 0.9rem;
  }

  .project-card-empty-index {
    font-size: clamp(6rem, 33vw, 9rem);
  }
}

@media (max-width: 390px) {
  .project-open-button {
    font-size: 0.84rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .skip-link,
  .project-open-button,
  .project-open-button svg,
  .project-sidepanel,
  .project-sidepanel-backdrop {
    transition-duration: 0.01ms;
  }
}

/* =========================
   CANONICAL COMPONENT SYSTEM
   The final layer keeps cards, media, links and controls visually consistent.
   ========================= */

:root {
  --ui-ink: #0b0b0b;
  --ui-surface: rgba(255, 255, 255, 0.97);
  --ui-surface-muted: rgba(247, 247, 245, 0.96);
  --ui-border: rgba(11, 11, 11, 0.16);
  --ui-border-strong: rgba(11, 11, 11, 0.82);
  --ui-accent: #52f4e8;
  --ui-media-radius: 0.875rem;
  --ui-panel-radius: 1.5rem;
  --ui-control-radius: 999px;
  --ui-shadow: 0 12px 34px rgba(0, 0, 0, 0.08);
  --ui-shadow-raised: 0 18px 44px rgba(0, 0, 0, 0.13);
  --ui-ease: cubic-bezier(0.22, 1, 0.36, 1);
}

.project-card-inner {
  border-color: var(--ui-border);
  border-radius: var(--ui-panel-radius) var(--ui-panel-radius) 0 0;
  box-shadow: var(--ui-shadow);
}

.project-sidepanel {
  border-left: 1px solid var(--ui-border);
  box-shadow: -18px 0 48px rgba(0, 0, 0, 0.12);
}

/* All visual media share one restrained corner treatment. */
.project-card-slider,
.project-image-trigger,
.slide img,
.project-card-empty-visual,
.project-side-inline-art,
.project-side-inline-art img,
.project-sidepanel-video,
.project-side-video-wrap,
.youtube-embed,
.youtube-embed iframe,
.instagram-embed,
.project-instagram-embed,
.project-lightbox-image {
  border-radius: var(--ui-media-radius);
}

.project-card-slider,
.project-image-trigger,
.project-side-video-wrap,
.youtube-embed,
.instagram-embed,
.project-instagram-embed {
  overflow: hidden;
}

.project-side-inline-art {
  border-color: var(--ui-border);
  background: var(--ui-surface-muted);
  box-shadow: var(--ui-shadow);
}

/* Every editorial external link uses the Black Box link-card language. */
.project-external-link-wrap {
  display: inline-flex;
  width: min(100%, 24rem);
  margin: 0.45rem 0;
  vertical-align: top;
}

.project-external-link {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.95rem;
  width: 100%;
  min-height: 4.25rem;
  padding: 0.82rem 0.9rem 0.82rem 1rem;
  border: 1px solid var(--ui-border);
  border-radius: 1rem;
  background: var(--ui-surface);
  box-shadow: var(--ui-shadow);
  color: var(--ui-ink);
  font-weight: 700 !important;
  line-height: 1.15;
  text-decoration: none !important;
  transition:
    transform 0.3s var(--ui-ease),
    border-color 0.3s ease,
    box-shadow 0.3s ease,
    background-color 0.3s ease;
}

.project-external-link::after {
  content: "\2197";
  display: inline-grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  background: var(--ui-ink);
  color: #fff;
  font-size: 1rem;
  line-height: 1;
}

.project-external-link:hover,
.project-external-link:focus-visible {
  filter: none !important;
  transform: translateY(-2px);
  border-color: var(--ui-border-strong);
  background: #fff;
  box-shadow: var(--ui-shadow-raised);
}

.project-external-link-copy {
  display: flex;
  min-width: 0;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.28rem;
}

.project-external-link-label,
.project-external-link-meta {
  display: block;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.project-external-link-label {
  font-size: 0.98rem;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.01em;
}

.project-external-link-meta {
  font-size: 0.72rem;
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: 0.02em;
  opacity: 0.58;
}

/* Retire legacy hover screenshots while preserving old saved content safely. */
.app-preview-window {
  display: none !important;
}

.app-preview-link:hover,
.app-preview-link:focus-visible {
  filter: none !important;
}

/* Shared shape, border and interaction behavior for all interface controls. */
.project-open-button,
.project-sidepanel-close,
.project-lightbox-close,
.project-slider-nav,
.project-lightbox-nav,
.footer-links .hero-link,
.language-links,
.language-link-button {
  font-family: "SuisseScreen", sans-serif;
}

.project-open-button,
.project-sidepanel-close,
.project-lightbox-close,
.project-slider-nav,
.project-lightbox-nav {
  border-color: var(--ui-border-strong);
  background-color: var(--ui-surface);
  color: var(--ui-ink);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.09);
  transition:
    transform 0.22s var(--ui-ease),
    background-color 0.22s ease,
    color 0.22s ease,
    box-shadow 0.22s ease;
}

.project-open-button,
.project-sidepanel-close,
.project-lightbox-close {
  border-radius: var(--ui-control-radius);
}

.project-slider-nav,
.project-lightbox-nav {
  border-radius: 50%;
}

.project-open-button:hover,
.project-open-button:focus-visible,
.project-sidepanel-close:hover,
.project-sidepanel-close:focus-visible,
.project-lightbox-close:hover,
.project-lightbox-close:focus-visible,
.project-slider-nav:hover,
.project-slider-nav:focus-visible,
.project-lightbox-nav:hover,
.project-lightbox-nav:focus-visible {
  filter: none !important;
  background-color: var(--ui-ink);
  color: #fff;
  box-shadow: var(--ui-shadow-raised);
}

.footer-links .hero-link,
.language-links {
  border-color: var(--ui-border-strong);
  background: var(--ui-surface);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

.footer-links .hero-link:hover,
.footer-links .hero-link:focus-visible,
.language-link-button:hover,
.language-link-button:focus-visible {
  filter: none !important;
}

.language-link-button.is-active {
  background: var(--ui-ink);
  color: #fff;
}

/* Card and panel type now use the same optical hierarchy. */
.project-card-description,
.project-card-description p,
.project-card-description li,
.project-sidepanel-copy,
.project-sidepanel-copy p,
.project-sidepanel-copy li {
  color: var(--ui-ink);
  text-wrap: pretty;
}

.project-card-header h2,
.project-card-header h2.text-large,
.project-card-header span,
.project-card-header span.text-large,
.project-sidepanel-header h2,
.project-sidepanel-header span {
  color: var(--ui-ink);
}

@media (max-width: 1180px), (hover: none), (pointer: coarse) {
  .project-card-inner {
    border-radius: var(--ui-panel-radius);
  }
}

@media (max-width: 700px) {
  :root {
    --ui-media-radius: 0.75rem;
    --ui-panel-radius: 1.1rem;
  }

  .project-external-link-wrap {
    width: 100%;
  }

  .project-external-link {
    min-height: 4rem;
    padding: 0.75rem 0.75rem 0.75rem 0.85rem;
  }

  .project-open-button,
  .project-sidepanel-close,
  .project-lightbox-close,
  .project-slider-nav,
  .project-lightbox-nav,
  .footer-links .hero-link,
  .language-link-button {
    min-width: 2.75rem;
    min-height: 2.75rem;
  }
}


/* Slider controls: independent from project stacking. */
.project-card-slider {
  isolation: isolate;
}

.project-card-slider > .project-slider-nav {
  position: absolute;
  z-index: 40;
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.project-card-slider.is-single-slide > .project-slider-nav,
.project-card-slider > .project-slider-nav[hidden] {
  display: none !important;
}




/* =========================================================
   STACK RENDER BUDGET
   The card shell always stays rendered so the stack keeps its exact look.
   Only content that is completely covered / far off-screen is hidden.
   No size, position, z-index or transform geometry is changed.
   ========================================================= */

.project-card.is-stack-lightweight .project-card-content,
.project-card.is-stack-lightweight .project-card-slider {
  visibility: hidden;
  pointer-events: none;
}

/* =========================================================
   DESKTOP INTRO OVERLAY — proven working version
   Desktop only. Mobile/touch is handled by the reference
   sticky system below.
   ========================================================= */
@media (min-width: 1181px) and (hover: hover) and (pointer: fine) {
  .intro-section {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100vh;
    min-height: 100vh;
    overflow-y: auto;
    overflow-x: hidden;
    z-index: 1;
  }

  .project-card {
    z-index: 2;
  }
}

/* Responsive system: readable sticky stacks on tablets and touch devices. */
@media (max-width: 1180px), (hover: none), (pointer: coarse) {
  body {
    overflow-x: clip;
  }

  .intro-section {
    position: relative;
    inset: auto;
    width: 100%;
    height: auto;
    min-height: 100vh;
    min-height: 100svh;
    padding: clamp(2rem, 6vw, 4rem) clamp(1.25rem, 5vw, 3rem)
      calc(6.5rem + env(safe-area-inset-bottom));
    overflow: visible;
  }

  .intro-text {
    min-height: 0;
  }

  .project-scroller {
    width: 100%;
    height: auto;
    padding-bottom: calc(6rem + env(safe-area-inset-bottom));
  }

  .project-card {
    --mobile-stack-step: clamp(0.16rem, 0.45vw, 0.3rem);
    --mobile-stack-offset: calc(
      var(--mobile-stack-step) * var(--card-index, 0)
    );
    position: sticky;
    top: calc(
      max(0.5rem, env(safe-area-inset-top)) + var(--mobile-stack-offset)
    );
    right: auto;
    bottom: auto;
    left: 0;
    width: 100%;
    height: auto;
    padding: clamp(0.7rem, 1.8vw, 1.3rem) clamp(0.75rem, 2.4vw, 1.75rem) 0;
    z-index: calc(10 + var(--card-index, 0));
  }

  .project-card-inner {
    display: grid;
    grid-template-columns: minmax(18rem, 0.9fr) minmax(0, 1.1fr);
    height: auto;
    min-height: 0;
    padding: clamp(1.25rem, 2.5vw, 2rem);
    gap: clamp(1.5rem, 3vw, 2.5rem);
    align-items: start;
    overflow: visible;
    border-radius: clamp(1.25rem, 2.5vw, 2rem);
  }

  .project-card-content {
    width: 100%;
    min-width: 0;
    max-width: none;
    min-height: 0;
    padding-right: 0;
    overflow: visible;
  }

  .project-card-description {
    max-width: 42rem;
  }

  .project-card-slider {
    width: 100%;
    min-width: 0;
    min-height: 0;
    height: auto;
    align-self: start;
    overflow: hidden;
  }

  .slider,
  .slide {
    min-height: 0;
    height: auto;
  }

  .slide img {
    width: 100%;
    height: 100%;
    max-height: min(72svh, 50rem);
    object-fit: contain;
  }

  .project-slider-nav {
    min-width: 2.75rem;
    min-height: 2.75rem;
  }

  .project-sidepanel {
    width: min(100vw, 48rem);
  }

  .project-sidepanel-close {
    top: max(1rem, env(safe-area-inset-top));
    right: max(1rem, env(safe-area-inset-right));
  }

  .project-sidepanel-scroll {
    padding-top: calc(5.5rem + env(safe-area-inset-top));
    padding-right: max(clamp(1.25rem, 4vw, 3rem), env(safe-area-inset-right));
    padding-bottom: calc(3rem + env(safe-area-inset-bottom));
    padding-left: max(clamp(1.25rem, 4vw, 3rem), env(safe-area-inset-left));
  }

  .footer-links {
    position: fixed;
    top: auto;
    right: max(1rem, env(safe-area-inset-right));
    bottom: max(1rem, env(safe-area-inset-bottom));
    left: auto;
    z-index: 4500;
    transform: none;
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
    gap: 0.45rem;
    width: auto;
    margin: 0;
    padding: 0.45rem;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 0.45rem 1.5rem rgba(0, 0, 0, 0.1);
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
  }

  .footer-links .hero-link {
    flex: 0 0 auto;
    padding: 0.72rem 0.85rem;
    writing-mode: horizontal-tb;
    text-orientation: mixed;
    font-size: 0.84rem;
    line-height: 1;
  }

  .language-links {
    order: 0;
    flex: 0 0 auto;
    flex-direction: row;
    align-self: auto;
  }

  .language-link-button {
    min-width: 2.35rem;
    min-height: 2.35rem;
    padding: 0.62rem 0.68rem;
    writing-mode: horizontal-tb;
    text-orientation: mixed;
    font-size: 0.78rem;
  }

  .imprint-page {
    min-height: 100vh;
    min-height: 100svh;
    padding-right: max(clamp(1.25rem, 5vw, 4rem), env(safe-area-inset-right));
    padding-bottom: calc(7rem + env(safe-area-inset-bottom));
    padding-left: max(clamp(1.25rem, 5vw, 4rem), env(safe-area-inset-left));
  }
}

@media (max-width: 900px) {
  .project-card-inner {
    display: flex;
    flex-direction: column;
  }

  .project-card-content,
  .project-card-slider {
    width: 100%;
    max-width: none;
  }

  .project-card-slider {
    padding-top: 0;
  }

  .slide img {
    max-height: min(58svh, 42rem);
  }
}

@media (max-width: 700px) {
  .intro-section {
    min-height: 100vh;
    min-height: 100svh;
    padding-top: max(1.75rem, env(safe-area-inset-top));
    padding-right: max(1.1rem, env(safe-area-inset-right));
    padding-bottom: calc(6.25rem + env(safe-area-inset-bottom));
    padding-left: max(1.1rem, env(safe-area-inset-left));
  }

  .intro-text h1 {
    max-width: 12ch;
    font-size: clamp(2.65rem, 13vw, 4.4rem);
    line-height: 0.94;
  }

  .intro-copy,
  .intro-copy p,
  .intro-text p {
    font-size: clamp(0.98rem, 4vw, 1.08rem);
    line-height: 1.52;
  }

  .project-card {
    padding: 0.65rem 0.65rem 0;
  }

  .project-card-inner {
    min-height: 0;
    padding: clamp(1rem, 4.5vw, 1.3rem);
    gap: 1.25rem;
    border-radius: 1.35rem;
  }

  .project-card-header {
    gap: 0.75rem 1rem;
    margin-bottom: 0.9rem;
  }

  .project-card-header h2,
  .project-card-header h2.text-large,
  .project-card-header span,
  .project-card-header span.text-large {
    font-size: clamp(1.65rem, 7.2vw, 2.15rem);
    line-height: 0.98;
  }

  .project-card-header h2,
  .project-card-header h2.text-large {
    max-width: 100%;
  }

  .project-card-description {
    max-width: none;
    font-size: clamp(0.94rem, 3.7vw, 1rem);
    line-height: 1.58;
  }

  .project-link-container {
    margin-top: 1.25rem;
  }

  .slide img {
    max-height: 52svh;
  }

  .project-sidepanel {
    width: 100vw;
    border-left: 0;
  }

  .project-sidepanel-header {
    flex-wrap: wrap;
    gap: 0.75rem 1rem;
  }

  .project-sidepanel-header h2,
  .project-sidepanel-header span {
    font-size: clamp(1.75rem, 8vw, 2.35rem);
  }

  .project-sidepanel-copy,
  .project-sidepanel-copy p,
  .project-sidepanel-copy li {
    font-size: clamp(0.96rem, 3.7vw, 1.02rem);
    line-height: 1.62;
  }

  .project-sidepanel-scroll {
    padding-top: calc(5rem + env(safe-area-inset-top));
    padding-right: max(1rem, env(safe-area-inset-right));
    padding-bottom: calc(2.5rem + env(safe-area-inset-bottom));
    padding-left: max(1rem, env(safe-area-inset-left));
  }

  .project-side-inline-art,
  .project-side-inline-art-stack {
    width: 100%;
    max-width: 20rem;
  }

  .project-lightbox {
    padding-top: max(0.75rem, env(safe-area-inset-top));
    padding-right: max(0.75rem, env(safe-area-inset-right));
    padding-bottom: max(0.75rem, env(safe-area-inset-bottom));
    padding-left: max(0.75rem, env(safe-area-inset-left));
  }

  .project-lightbox-image {
    max-height: 70svh;
  }

  .footer-links {
    right: max(0.65rem, env(safe-area-inset-right));
    bottom: max(0.65rem, env(safe-area-inset-bottom));
    left: max(0.65rem, env(safe-area-inset-left));
    justify-content: center;
    gap: 0.3rem;
    width: auto;
    max-width: none;
    padding: 0.35rem;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .footer-links::-webkit-scrollbar {
    display: none;
  }

  .footer-links .hero-link {
    min-height: 2.75rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.62rem 0.72rem;
    font-size: clamp(0.72rem, 3.2vw, 0.82rem);
  }

  .language-link-button {
    min-width: 2.75rem;
    min-height: 2.75rem;
    padding: 0.52rem 0.58rem;
    font-size: 0.72rem;
  }

  .imprint-page.has-animated-background .imprint-content-wrapper {
    padding: clamp(1rem, 4vw, 1.5rem);
  }
}

@media (max-width: 390px) {
  .footer-links .hero-link {
    padding-right: 0.56rem;
    padding-left: 0.56rem;
  }

  .language-link-button {
    min-width: 2.75rem;
    padding-right: 0.48rem;
    padding-left: 0.48rem;
  }

  .project-sidepanel-close {
    min-height: 2.75rem;
    padding: 0.6rem 0.8rem;
    font-size: 0.8rem;
  }
}

@media (max-height: 720px) and (min-width: 701px) {
  .intro-section {
    align-items: flex-start;
    min-height: 100vh;
    min-height: 100svh;
    padding-top: max(1.5rem, env(safe-area-inset-top));
    padding-bottom: calc(5.5rem + env(safe-area-inset-bottom));
  }

  .intro-text h1 {
    margin-bottom: 1rem;
    font-size: clamp(2.75rem, 8vh, 4.5rem);
  }

  .intro-copy,
  .intro-copy p,
  .intro-text p {
    font-size: clamp(0.95rem, 2.6vh, 1.15rem);
    line-height: 1.45;
  }

  .project-sidepanel-scroll {
    padding-top: calc(4.75rem + env(safe-area-inset-top));
  }
}

/* =========================================================
   MOBILE INTEGRATION SAFETY
   Desktop's render-budget classes must never hide content
   after a breakpoint/orientation switch to the sticky layout.
   ========================================================= */
@media (max-width: 1180px), (hover: none), (pointer: coarse) {
  .project-card {
    transform: none !important;
  }

  .project-card.is-stack-lightweight .project-card-content,
  .project-card.is-stack-lightweight .project-card-slider {
    visibility: visible;
    pointer-events: auto;
  }
}


/* =========================================================
   MOBILE INTRO OVERLAY + CLEAN END STOP
   Based on the supplied mobile sticky layout.

   Problem visible in the screen recording:
   1. the intro itself scrolls away instead of staying behind card 1;
   2. the final sticky card is pushed upward when the scroller ends.

   This patch changes only those two behaviours.
   ========================================================= */

@media (max-width: 1180px), (hover: none), (pointer: coarse) {
  /*
   * Keep the intro in the viewport while the first project approaches.
   * It still occupies one viewport in normal layout, so there is no
   * JS-controlled mobile viewport animation.
   */
  .intro-section {
    position: sticky;
    top: 0;
    right: auto;
    bottom: auto;
    left: 0;

    width: 100%;
    height: 100svh;
    min-height: 100svh;

    overflow: hidden;
    z-index: 1;
  }

  /*
   * The scroller starts visually at the same place as the intro, but its
   * first card begins one small-viewport-height later.
   *
   * At scroll position 0: only the intro is visible.
   * While scrolling down: card 1 naturally travels upward over the intro.
   */
  .project-scroller {
    position: relative;
    z-index: 2;

    width: 100%;
    height: auto;
    min-height: 0;

    margin-top: -100svh;
    padding-top: 100svh;

    /*
     * Sticky elements are constrained by the bottom of their parent.
     * Give the final project enough tail room so it can settle at its
     * sticky top position instead of being pushed out of the viewport.
     */
    padding-bottom:
      calc(clamp(14rem, 38svh, 24rem) + env(safe-area-inset-bottom));

    background: transparent;
    overflow: visible;
  }

  .project-card {
    /*
     * Keep the supplied reference's natural sticky movement.
     * No GSAP transform is allowed on touch/mobile.
     */
    transform: none !important;
  }

  /*
   * Explicitly keep the final card at the same sticky rhythm as the rest.
   * The extra scroller tail above is what creates its calm end state.
   */
  .project-card:last-child {
    margin-bottom: 0;
  }
}

/*
 * Very short mobile landscapes / browser split views:
 * let the intro itself scroll only if its content physically cannot fit.
 */
@media (max-width: 1180px) and (max-height: 560px),
       (hover: none) and (pointer: coarse) and (max-height: 560px) {
  .intro-section {
    overflow-y: auto;
    overscroll-behavior-y: contain;
  }
}


/* =========================================================
   MOBILE FINAL CARD STOP — real scroll runway
   Padding alone was not sufficient for the final sticky card.
   Add an actual block after the last project so the sticky
   containing block continues for one full mobile viewport.
   ========================================================= */

@media (max-width: 1180px), (hover: none), (pointer: coarse) {
  .project-scroller {
    /* Keep only normal breathing room here. */
    padding-bottom: calc(4rem + env(safe-area-inset-bottom));
  }

  .project-scroller::after {
    content: "";
    display: block;
    width: 100%;
    height: calc(100svh + env(safe-area-inset-bottom));
    pointer-events: none;
  }

  .project-card:last-child {
    margin-bottom: 0;
  }
}


/* =========================================================
   MOBILE FULL-WIDTH CARDS
   Cards span the full viewport width on touch/mobile.
   Inner card padding remains responsible for readable spacing.
   ========================================================= */
@media (max-width: 1180px), (hover: none), (pointer: coarse) {
  .project-card {
    width: 100vw;
    max-width: 100vw;
    margin-left: 0;
    margin-right: 0;
    padding-left: 0;
    padding-right: 0;
  }

  .project-card-inner {
    width: 100%;
    max-width: none;
    border-radius: 1.35rem 1.35rem 0 0;
  }
}

@media (max-width: 700px) {
  .project-card {
    padding-left: 0;
    padding-right: 0;
  }
}


/* =========================================================
   MOBILE FULL-HEIGHT CARDS + FINAL COVER
   Each sticky card fills the usable viewport from its own
   sticky position to the bottom of the screen.

   The final project settles at the base safe-area top instead
   of keeping the accumulated stack offset. This lets it cover
   every previous card completely at the final stop.
   ========================================================= */
@media (max-width: 1180px), (hover: none), (pointer: coarse) {
  .project-card {
    --mobile-stack-base-top: max(0.5rem, env(safe-area-inset-top));
    --mobile-card-visible-height: calc(
      100svh - var(--mobile-stack-base-top) - var(--mobile-stack-offset, 0px)
    );

    min-height: var(--mobile-card-visible-height);
  }

  .project-card-inner {
    min-height: var(--mobile-card-visible-height);
    box-sizing: border-box;
  }

  /*
   * Final card:
   * - snaps to the normal top safe area
   * - fills the rest of the viewport
   * - fully covers Power of Machine Learning and the older stack
   */
  .project-card:last-child {
    --mobile-stack-offset: 0px;
    top: var(--mobile-stack-base-top);
    min-height: calc(100svh - var(--mobile-stack-base-top));
    z-index: 100;
  }

  .project-card:last-child .project-card-inner {
    min-height: calc(100svh - var(--mobile-stack-base-top));
  }
}

/* Very short screens: use dynamic viewport height when available. */
@supports (height: 100dvh) {
  @media (max-width: 1180px), (hover: none), (pointer: coarse) {
    .project-card {
      --mobile-card-visible-height: calc(
        100dvh - var(--mobile-stack-base-top) - var(--mobile-stack-offset, 0px)
      );
    }

    .project-card:last-child,
    .project-card:last-child .project-card-inner {
      min-height: calc(100dvh - var(--mobile-stack-base-top));
    }
  }
}
/* =========================================================
   SUBTLE HOME LEGAL FOOTER
   Keeps the legal link out of the floating control pill.
   It appears naturally after the final project.
   ========================================================= */
.home-legal-footer {
  position: relative;
  z-index: 120;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  width: 100%;
  min-height: 3.5rem;
  padding:
    1rem
    max(1.25rem, env(safe-area-inset-right))
    calc(1.25rem + env(safe-area-inset-bottom))
    max(1.25rem, env(safe-area-inset-left));
  background: #fff;
  font-family: "SuisseScreen", sans-serif;
  font-size: 0.78rem;
  font-weight: 500;
  line-height: 1.2;
}

.home-legal-footer a {
  color: #000;
  text-decoration: none;
  opacity: 0.48;
  transition: opacity 0.2s ease, filter 0.2s ease;
}

.home-legal-footer a:hover,
.home-legal-footer a:focus-visible {
  opacity: 1;
  filter: none;
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

/*
 * On touch/mobile the language + Instagram controls remain fixed
 * at the bottom. Extra room prevents them from covering the legal link.
 */
@media (max-width: 1180px), (hover: none), (pointer: coarse) {
  .home-legal-footer {
    padding-bottom: calc(5rem + env(safe-area-inset-bottom));
    font-size: 0.75rem;
  }
}


/* =========================================================
   DESKTOP FLOATING CONTROLS — keep clear of image navigation
   DE / EN / Instagram sit compactly at bottom-left instead
   of covering the right-hand slider navigation.
   ========================================================= */
@media (min-width: 1181px) and (hover: hover) and (pointer: fine) {
  .footer-links {
    position: fixed;
    top: auto;
    right: auto;
    bottom: 1.25rem;
    left: 1.25rem;
    z-index: 4500;
    transform: none;

    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 0.4rem;

    width: auto;
    margin: 0;
    padding: 0.4rem;

    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 0.4rem 1.25rem rgba(0, 0, 0, 0.08);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
  }

  .footer-links .hero-link {
    flex: 0 0 auto;
    writing-mode: horizontal-tb;
    text-orientation: mixed;
    padding: 0.66rem 0.8rem;
    border-width: 1px;
    font-size: 0.8rem;
    line-height: 1;
  }

  .footer-links .language-links {
    order: 0;
    flex: 0 0 auto;
    flex-direction: row;
    align-items: center;
    align-self: auto;
  }

  .footer-links .language-link-button {
    min-width: 2.2rem;
    min-height: 2.2rem;
    padding: 0.55rem 0.6rem;
    writing-mode: horizontal-tb;
    text-orientation: mixed;
    font-size: 0.74rem;
    line-height: 1;
  }

  /* Pull both navigation buttons slightly into the image. */
  .project-slider-nav--prev {
    left: 1rem;
  }

  .project-slider-nav--next {
    right: 1rem;
  }

  .project-card-slider > .project-slider-nav {
    z-index: 80;
  }
}


/* =========================================================
   DESKTOP CONTROLS — final top-right placement
   Language controls sit as a compact pair in the top-right.
   Instagram stays directly below, away from slider arrows.
   ========================================================= */
@media (min-width: 1181px) and (hover: hover) and (pointer: fine) {
  .footer-links {
    top: 1.25rem;
    right: 1.25rem;
    bottom: auto;
    left: auto;
    transform: none;

    flex-direction: column;
    align-items: flex-end;
    justify-content: flex-start;
    gap: 0.45rem;

    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }

  .footer-links .language-links {
    order: 0;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 0;
    padding: 0.28rem;

    border: 1px solid rgba(0, 0, 0, 0.14);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 0.35rem 1rem rgba(0, 0, 0, 0.07);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
  }

  .footer-links .language-link-button {
    min-width: 2.35rem;
    min-height: 2.35rem;
    padding: 0.55rem 0.65rem;
    border: 0;
    border-radius: 999px;

    writing-mode: horizontal-tb;
    text-orientation: mixed;

    font-size: 0.76rem;
    line-height: 1;
  }

  .footer-links .hero-link {
    order: 1;
    writing-mode: horizontal-tb;
    text-orientation: mixed;

    padding: 0.58rem 0.78rem;
    border: 1px solid rgba(0, 0, 0, 0.14);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 0.35rem 1rem rgba(0, 0, 0, 0.07);

    font-size: 0.72rem;
    line-height: 1;
  }
}


/* =========================================================
   SIDEPANEL SAFETY
   Hide the floating DE / EN / Instagram controls while the
   project sidepanel is open so the close button stays clear.
   ========================================================= */
body.project-sidepanel-open .footer-links {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}



/* =========================================================
   MOBILE MEDIA CORNERS — consistent with desktop
   Every visual surface is clipped by a rounded wrapper.
   This also makes the rounding reliable on iOS/WebKit while
   slider content is translated horizontally.
   ========================================================= */
@media (max-width: 1180px), (hover: none), (pointer: coarse) {
  .project-card-slider,
  .slider,
  .slide,
  .project-image-trigger,
  .slide img,
  .project-card-empty-visual,
  .project-side-inline-art,
  .project-side-inline-art img,
  .project-sidepanel-video,
  .project-side-video-wrap,
  .youtube-embed,
  .youtube-embed iframe,
  .instagram-embed,
  .project-instagram-embed,
  .project-lightbox-image {
    border-radius: var(--ui-media-radius, 0.75rem) !important;
  }

  .project-card-slider,
  .slide,
  .project-image-trigger,
  .project-side-inline-art,
  .project-side-video-wrap,
  .youtube-embed,
  .instagram-embed,
  .project-instagram-embed {
    overflow: hidden !important;
  }

  .project-image-trigger {
    isolation: isolate;
    -webkit-mask-image: -webkit-radial-gradient(white, black);
  }

  .project-image-trigger img,
  .project-side-inline-art img,
  .youtube-embed iframe {
    display: block;
  }

  /* Keep a little visual air around slider media on small screens. */
  .project-card-slider {
    background: transparent;
  }
}


/* =========================================================
   HOME LEGAL FOOTER — styled like the rest of the interface
   ========================================================= */
.home-legal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;

  width: 100%;
  min-height: 5rem;
  padding:
    1.15rem
    max(1.25rem, env(safe-area-inset-right))
    calc(1.25rem + env(safe-area-inset-bottom))
    max(1.25rem, env(safe-area-inset-left));

  background: #fff;
  font-family: "SuisseScreen", sans-serif;
}

.home-legal-footer a {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  min-height: 2.65rem;
  padding: 0.72rem 1rem;

  border: 1px solid var(--ui-border, rgba(0, 0, 0, 0.14));
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--ui-shadow, 0 0.35rem 1rem rgba(0, 0, 0, 0.07));

  color: #000;
  opacity: 1;
  text-decoration: none;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1;

  transition:
    background-color 0.22s ease,
    color 0.22s ease,
    border-color 0.22s ease,
    transform 0.22s ease,
    box-shadow 0.22s ease;
}

.home-legal-footer a::after {
  content: "\2197";
  margin-left: 0.55rem;
  font-size: 0.9em;
}

.home-legal-footer a:hover,
.home-legal-footer a:focus-visible {
  filter: none;
  opacity: 1;
  text-decoration: none;

  background: #000;
  color: #fff;
  border-color: #000;
  transform: translateY(-1px);
  box-shadow: 0 0.55rem 1.4rem rgba(0, 0, 0, 0.12);
}

.home-legal-footer a:focus-visible {
  outline: 2px solid #000;
  outline-offset: 3px;
}

@media (max-width: 1180px), (hover: none), (pointer: coarse) {
  .home-legal-footer {
    justify-content: center;
    min-height: 7.5rem;

    /* Space for the fixed DE / EN / Instagram controls. */
    padding-top: 1rem;
    padding-right: max(1rem, env(safe-area-inset-right));
    padding-bottom: calc(5.25rem + env(safe-area-inset-bottom));
    padding-left: max(1rem, env(safe-area-inset-left));
  }

  .home-legal-footer a {
    min-height: 2.75rem;
    padding: 0.72rem 1rem;
    font-size: 0.76rem;
  }
}



/* =========================================================
   LEGAL FOOTER — no full-width white bar
   Keep only the small Impressum pill visible.
   ========================================================= */
.home-legal-footer {
  background: transparent !important;
  min-height: 0;
}

@media (max-width: 1180px), (hover: none), (pointer: coarse) {
  .home-legal-footer {
    background: transparent !important;
  }
}



/* =========================================================
   EXTERNAL LINK HOVER PREVIEW — restored
   The legacy preview CSS existed already but had been disabled.
   Desktop/fine-pointer only; touch devices keep the normal link card.
   ========================================================= */
@media (min-width: 981px) and (hover: hover) and (pointer: fine) {
  .app-link-preview-wrap {
    position: relative;
    overflow: visible;
  }

  .app-link-preview-wrap .app-preview-window {
    display: block !important;
    z-index: 120;
  }

  .app-preview-window.is-preview-above {
    top: auto;
    bottom: calc(100% + 0.85rem);
    transform: translateY(-14px) scale(0.96) rotate(1deg);
    transform-origin: bottom left;
  }

  .app-preview-window.is-preview-align-right {
    right: 0;
    left: auto;
    transform-origin: top right;
  }

  .app-preview-window.is-preview-above.is-preview-align-right {
    transform-origin: bottom right;
  }

  .app-link-preview-wrap:hover .app-preview-window.is-preview-above,
  .app-link-preview-wrap:focus-within .app-preview-window.is-preview-above {
    transform: translateY(0) scale(1) rotate(0deg);
  }

  .app-preview-window-image {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    border-radius: 0 !important;
  }

  .app-preview-window-footer {
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
  }
}

/* No hover preview on touch/mobile. */
@media (max-width: 980px), (hover: none), (pointer: coarse) {
  .app-preview-window {
    display: none !important;
  }
}



/* =========================================================
   PHOTOGRAPHY PORTFOLIO
   Dedicated editorial photography page.
   ========================================================= */

.photography-page {
  --photo-accent: #52f4e8;
  --photo-black: #111;
  --photo-paper: #f6f4ef;
  --photo-border: rgba(0, 0, 0, 0.14);

  min-height: 100vh;
  background: var(--photo-paper);
  color: var(--photo-black);
  font-family: "SuisseScreen", sans-serif;
}

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

.photo-lang {
  display: none !important;
}

.photo-lang.is-active {
  display: revert !important;
}

.photo-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(26rem, 1.1fr);
  gap: clamp(1.5rem, 4vw, 5rem);
  min-height: 100svh;
  padding:
    max(2rem, env(safe-area-inset-top))
    max(clamp(1.25rem, 4vw, 4rem), env(safe-area-inset-right))
    clamp(4rem, 8vw, 7rem)
    max(clamp(1.25rem, 4vw, 4rem), env(safe-area-inset-left));
  align-items: center;
  overflow: hidden;
}

.photo-hero-copy {
  position: relative;
  z-index: 2;
  max-width: 46rem;
}

.photo-eyebrow {
  display: inline-flex !important;
  width: fit-content;
  margin: 0 0 clamp(1.5rem, 3vw, 2.75rem);
  padding: 0.34rem 0.55rem 0.26rem;
  background: var(--photo-accent);
  font-size: clamp(0.72rem, 0.8vw, 0.9rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: 0.03em;
}

.photo-hero h1 {
  margin: 0;
  font-size: clamp(4.5rem, 10vw, 10.5rem);
  font-weight: 700;
  line-height: 0.82;
  letter-spacing: -0.075em;
}

.photo-services-line {
  margin: clamp(1.35rem, 2vw, 2rem) 0 0;
  font-size: clamp(1.15rem, 2.2vw, 2rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.025em;
}

.photo-hero-text {
  max-width: 40rem;
  margin-top: clamp(1.5rem, 3vw, 2.5rem);
  font-size: clamp(1rem, 1.25vw, 1.25rem);
  line-height: 1.5;
}

.photo-hero-text p,
.photo-service-copy p,
.photo-booking-copy p {
  margin: 0;
}

.photo-availability {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  width: fit-content;
  margin-top: clamp(1.4rem, 3vw, 2.5rem);
  padding: 0.62rem 0.85rem;
  border: 1px solid var(--photo-border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.65);
  font-size: 0.88rem;
  font-weight: 700;
}

.photo-availability-dot {
  width: 0.65rem;
  height: 0.65rem;
  border-radius: 50%;
  background: #25c55b;
  box-shadow: 0 0 0 0.25rem rgba(37, 197, 91, 0.14);
}

.photo-hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.4rem;
  margin-top: clamp(1.5rem, 3vw, 2.5rem);
}

.photo-primary-cta,
.photo-booking-mail {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.8rem;
  min-height: 3.2rem;
  padding: 0.85rem 1.1rem;
  border: 1px solid #111;
  border-radius: 999px;
  background: #111;
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  line-height: 1;
  transition:
    transform 0.22s ease,
    background-color 0.22s ease,
    color 0.22s ease;
}

.photo-primary-cta:hover,
.photo-primary-cta:focus-visible,
.photo-booking-mail:hover,
.photo-booking-mail:focus-visible {
  filter: none;
  transform: translateY(-2px);
  background: var(--photo-accent);
  color: #111;
}

.photo-location {
  margin: 0;
  max-width: 19rem;
  font-size: 0.82rem;
  line-height: 1.3;
  opacity: 0.64;
}

.photo-hero-media {
  position: relative;
  min-height: min(82svh, 56rem);
  overflow: hidden;
  border-radius: clamp(1.3rem, 2.6vw, 2.4rem);
  background: #e7e4de;
  box-shadow: 0 1.5rem 4rem rgba(0, 0, 0, 0.12);
}

.photo-hero-media img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: min(82svh, 56rem);
  object-fit: cover;
}

.photo-empty-hero {
  display: grid;
  place-items: center;
  width: 100%;
  min-height: min(82svh, 56rem);
  background:
    linear-gradient(135deg, transparent 49.9%, rgba(0,0,0,.18) 50%, transparent 50.1%),
    linear-gradient(45deg, transparent 49.9%, rgba(0,0,0,.18) 50%, transparent 50.1%);
  font-size: clamp(1rem, 2vw, 1.5rem);
  font-weight: 700;
}

.photo-scroll-cue {
  position: absolute;
  bottom: max(1.5rem, env(safe-area-inset-bottom));
  left: max(clamp(1.25rem, 4vw, 4rem), env(safe-area-inset-left));
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  color: currentColor;
  text-decoration: none;
  font-size: 0.78rem;
  font-weight: 700;
}

.photo-category-nav {
  position: sticky;
  top: 0;
  z-index: 35;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--photo-border);
  border-bottom: 1px solid var(--photo-border);
  background: rgba(246, 244, 239, 0.88);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
}

.photo-category-nav a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 3.65rem;
  padding: 0.9rem clamp(1rem, 2.8vw, 2.5rem);
  border-right: 1px solid var(--photo-border);
  color: currentColor;
  text-decoration: none;
  font-size: clamp(0.85rem, 1vw, 1rem);
  font-weight: 700;
}

.photo-category-nav a:last-child {
  border-right: 0;
}

.photo-category-nav a:hover,
.photo-category-nav a:focus-visible {
  filter: none;
  background: var(--photo-accent);
}

.photo-category-nav a > span:first-child {
  opacity: 0.45;
  font-size: 0.75rem;
}

.photo-services {
  width: 100%;
}

.photo-service {
  padding:
    clamp(5rem, 9vw, 9rem)
    max(clamp(1.25rem, 4vw, 4rem), env(safe-area-inset-right))
    clamp(5rem, 9vw, 9rem)
    max(clamp(1.25rem, 4vw, 4rem), env(safe-area-inset-left));
  border-bottom: 1px solid var(--photo-border);
  scroll-margin-top: 4rem;
}

.photo-service-header {
  display: grid;
  grid-template-columns: minmax(5rem, 0.25fr) minmax(0, 1fr);
  gap: clamp(1.5rem, 5vw, 5rem);
  margin-bottom: clamp(2rem, 5vw, 4.5rem);
}

.photo-service-index {
  padding-top: 0.55rem;
  font-size: 0.78rem;
  font-weight: 700;
  opacity: 0.48;
}

.photo-service-heading {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(18rem, 0.55fr);
  gap: clamp(2rem, 6vw, 7rem);
  align-items: end;
}

.photo-service h2 {
  margin: 0;
  font-size: clamp(3.5rem, 8vw, 8rem);
  font-weight: 700;
  line-height: 0.86;
  letter-spacing: -0.065em;
}

.photo-service-copy {
  max-width: 34rem;
  padding-bottom: 0.6rem;
  font-size: clamp(1rem, 1.25vw, 1.18rem);
  line-height: 1.5;
}

.photo-gallery {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(0.65rem, 1.4vw, 1.25rem);
}

.photo-gallery-item {
  grid-column: span 4;
  position: relative;
  min-width: 0;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: clamp(0.8rem, 1.6vw, 1.35rem);
  background: #ddd;
  cursor: zoom-in;
}

.photo-gallery-item:nth-child(6n + 1) {
  grid-column: span 8;
}

.photo-gallery-item:nth-child(6n + 4) {
  grid-column: span 5;
}

.photo-gallery-item:nth-child(6n + 5) {
  grid-column: span 7;
}

.photo-gallery-item img {
  display: block;
  width: 100%;
  height: clamp(18rem, 34vw, 34rem);
  object-fit: cover;
  transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
}

.photo-gallery-item:nth-child(6n + 1) img {
  height: clamp(25rem, 52vw, 48rem);
}

.photo-gallery-item:hover img,
.photo-gallery-item:focus-visible img {
  transform: scale(1.018);
}

.photo-gallery-item:focus-visible {
  outline: 3px solid var(--photo-accent);
  outline-offset: 3px;
}

.photo-gallery-empty {
  display: grid;
  place-items: center;
  min-height: 22rem;
  padding: 2rem;
  border: 1px dashed rgba(0, 0, 0, 0.28);
  border-radius: 1.4rem;
  text-align: center;
  background:
    linear-gradient(135deg, transparent 49.9%, rgba(0,0,0,.07) 50%, transparent 50.1%);
}

.photo-gallery-empty > span {
  font-size: clamp(2rem, 5vw, 5rem);
  font-weight: 700;
  letter-spacing: -0.05em;
  opacity: 0.24;
}

.photo-gallery-empty p {
  margin: 1rem 0 0;
  font-size: 0.82rem;
  opacity: 0.55;
}

.photo-booking {
  display: grid;
  grid-template-columns: minmax(8rem, 0.25fr) minmax(0, 1fr);
  gap: clamp(2rem, 6vw, 7rem);
  min-height: 70svh;
  padding:
    clamp(5rem, 10vw, 9rem)
    max(clamp(1.25rem, 4vw, 4rem), env(safe-area-inset-right))
    calc(clamp(7rem, 12vw, 11rem) + env(safe-area-inset-bottom))
    max(clamp(1.25rem, 4vw, 4rem), env(safe-area-inset-left));
  background: #111;
  color: #fff;
  align-items: start;
}

.photo-booking-kicker span {
  display: inline-flex !important;
  width: fit-content;
  padding: 0.34rem 0.55rem 0.26rem;
  background: var(--photo-accent);
  color: #111;
  font-size: 0.78rem;
  font-weight: 700;
}

.photo-booking-main {
  max-width: 72rem;
}

.photo-booking h2 {
  max-width: 9ch;
  margin: 0;
  font-size: clamp(4.2rem, 10vw, 10rem);
  font-weight: 700;
  line-height: 0.84;
  letter-spacing: -0.07em;
}

.photo-booking-copy {
  max-width: 44rem;
  margin-top: clamp(2rem, 4vw, 3.5rem);
  font-size: clamp(1.1rem, 1.8vw, 1.55rem);
  line-height: 1.45;
}

.photo-booking-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.4rem;
  margin-top: clamp(2rem, 4vw, 3.5rem);
}

.photo-booking-actions > a:not(.photo-booking-mail) {
  color: #fff;
  text-decoration: underline;
  text-underline-offset: 0.22em;
  font-weight: 700;
}

.photo-booking-mail {
  background: var(--photo-accent);
  border-color: var(--photo-accent);
  color: #111;
}

.photo-booking-mail:hover,
.photo-booking-mail:focus-visible {
  background: #fff;
  border-color: #fff;
}

/* Photography lightbox */
body.photo-lightbox-open {
  overflow: hidden;
}

.photo-lightbox[hidden] {
  display: none !important;
}

.photo-lightbox {
  position: fixed;
  inset: 0;
  z-index: 9000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
}

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

.photo-lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
}

.photo-lightbox-dialog {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 4rem minmax(0, 1fr) 4rem;
  align-items: center;
  width: 100%;
  height: 100%;
  padding:
    max(1rem, env(safe-area-inset-top))
    max(1rem, env(safe-area-inset-right))
    max(1rem, env(safe-area-inset-bottom))
    max(1rem, env(safe-area-inset-left));
}

.photo-lightbox-dialog figure {
  display: grid;
  place-items: center;
  min-width: 0;
  max-width: min(88vw, 96rem);
  max-height: 92svh;
  margin: 0 auto;
}

.photo-lightbox-image {
  display: block;
  max-width: 100%;
  max-height: 84svh;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 0.8rem;
}

.photo-lightbox-caption {
  margin-top: 0.8rem;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.78rem;
  text-align: center;
}

.photo-lightbox-close,
.photo-lightbox-nav {
  position: relative;
  z-index: 2;
  border: 0;
  background: #fff;
  color: #111;
  cursor: pointer;
  font-family: "SuisseScreen", sans-serif;
  font-weight: 700;
}

.photo-lightbox-close {
  position: absolute;
  top: max(1rem, env(safe-area-inset-top));
  right: max(1rem, env(safe-area-inset-right));
  min-height: 2.7rem;
  padding: 0.72rem 0.9rem;
  border-radius: 999px;
}

.photo-lightbox-nav {
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  font-size: 1.2rem;
}

.photography-footer-links {
  z-index: 5000;
}

/* Make the photography entry on Home slightly more noticeable without
   changing the overall navigation language. */
.photography-home-link {
  border-color: rgba(0, 0, 0, 0.3) !important;
}

@media (max-width: 980px) {
  .photo-hero {
    grid-template-columns: minmax(0, 1fr);
    min-height: auto;
    padding-top: max(5.5rem, env(safe-area-inset-top));
  }

  .photo-hero-copy {
    order: 1;
  }

  .photo-hero-media {
    order: 2;
    min-height: min(70svh, 44rem);
  }

  .photo-hero-media img,
  .photo-empty-hero {
    min-height: min(70svh, 44rem);
  }

  .photo-scroll-cue {
    display: none;
  }

  .photo-service-header,
  .photo-service-heading,
  .photo-booking {
    grid-template-columns: minmax(0, 1fr);
  }

  .photo-service-header {
    gap: 1rem;
  }

  .photo-service-heading {
    gap: 1.5rem;
  }

  .photo-gallery-item,
  .photo-gallery-item:nth-child(6n + 1),
  .photo-gallery-item:nth-child(6n + 4),
  .photo-gallery-item:nth-child(6n + 5) {
    grid-column: span 6;
  }

  .photo-gallery-item img,
  .photo-gallery-item:nth-child(6n + 1) img {
    height: clamp(18rem, 66vw, 36rem);
  }

  .photo-booking {
    min-height: 0;
  }
}

@media (max-width: 700px) {
  .photo-hero {
    gap: 2rem;
    padding-right: max(1rem, env(safe-area-inset-right));
    padding-left: max(1rem, env(safe-area-inset-left));
  }

  .photo-eyebrow {
    margin-bottom: 1.25rem;
    font-size: 0.68rem;
  }

  .photo-hero h1 {
    font-size: clamp(4.2rem, 23vw, 7rem);
  }

  .photo-services-line {
    font-size: 1.18rem;
  }

  .photo-hero-actions {
    align-items: flex-start;
    flex-direction: column;
  }

  .photo-primary-cta {
    width: 100%;
  }

  .photo-hero-media {
    min-height: 58svh;
    border-radius: 1.2rem;
  }

  .photo-hero-media img,
  .photo-empty-hero {
    min-height: 58svh;
  }

  .photo-category-nav {
    grid-template-columns: minmax(0, 1fr);
    position: relative;
  }

  .photo-category-nav a {
    border-right: 0;
    border-bottom: 1px solid var(--photo-border);
  }

  .photo-category-nav a:last-child {
    border-bottom: 0;
  }

  .photo-service {
    padding:
      4.5rem
      max(1rem, env(safe-area-inset-right))
      4.5rem
      max(1rem, env(safe-area-inset-left));
  }

  .photo-service h2 {
    font-size: clamp(3.7rem, 20vw, 6rem);
  }

  .photo-gallery {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.8rem;
  }

  .photo-gallery-item,
  .photo-gallery-item:nth-child(6n + 1),
  .photo-gallery-item:nth-child(6n + 4),
  .photo-gallery-item:nth-child(6n + 5) {
    grid-column: auto;
  }

  .photo-gallery-item img,
  .photo-gallery-item:nth-child(6n + 1) img {
    height: auto;
    max-height: 78svh;
    object-fit: cover;
  }

  .photo-booking {
    padding:
      4.5rem
      max(1rem, env(safe-area-inset-right))
      calc(8rem + env(safe-area-inset-bottom))
      max(1rem, env(safe-area-inset-left));
  }

  .photo-booking h2 {
    font-size: clamp(4rem, 21vw, 6.5rem);
  }

  .photo-booking-actions {
    align-items: flex-start;
    flex-direction: column;
  }

  .photo-booking-mail {
    width: 100%;
    overflow-wrap: anywhere;
  }

  .photo-lightbox-dialog {
    grid-template-columns: 3rem minmax(0, 1fr) 3rem;
    padding: 0.75rem;
  }

  .photo-lightbox-nav {
    width: 2.5rem;
    height: 2.5rem;
  }

  .photo-lightbox-image {
    max-height: 78svh;
  }
}

@media (prefers-reduced-motion: reduce) {
  .photo-gallery-item img,
  .photo-primary-cta,
  .photo-booking-mail,
  .photo-lightbox {
    transition: none !important;
  }
}



/* =====================================================================
   FINAL CONSOLIDATED VISUAL / RESPONSIVE LAYER
   Built on the proven projectScroller(6).css stack.
   IMPORTANT:
   - no project-scroller geometry changes
   - no project-card position/top/height/transform changes
   - no project-card-inner shadows/blur added
   - no ScrollTrigger changes
   ===================================================================== */


/* =====================================================================
   1. LANGUAGE VISIBILITY SAFETY
   Native hidden state wins even if an older selector tries to show it.
   ===================================================================== */

.home-page .intro-copy-stack[hidden],
.home-page .project-lang-block[hidden] {
  display: none !important;
}

.photography-page [data-photo-lang]:not(.is-active) {
  display: none !important;
}


/* =====================================================================
   2. HOME — EDITORIAL HERO, RESPONSIVE WITHOUT CHANGING INTRO GEOMETRY
   Keep the existing fixed desktop / sticky mobile intro behavior.
   ===================================================================== */

.home-page {
  --home-paper: #f6f4ef;
  --home-ink: #111;
  --home-accent: #52f4e8;
  --home-line: rgba(17, 17, 17, 0.16);
}

.home-page .intro-section {
  background: var(--home-paper);
}

/* Subtle full-bleed readability scrim; no visible card, no blur. */
.home-page .intro-section::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(
      90deg,
      rgba(246, 244, 239, 0.30) 0%,
      rgba(246, 244, 239, 0.20) 20%,
      rgba(246, 244, 239, 0.08) 38%,
      rgba(246, 244, 239, 0) 58%
    );
}

.home-page .intro-text {
  position: relative;
  z-index: 2;
  width: min(46rem, 55vw);
  max-width: 46rem;
  margin-right: auto;
  text-align: left;
}

.home-page .intro-copy-stack.is-active h1::before {
  display: inline-flex;
  width: fit-content;
  margin: 0 0 clamp(0.9rem, 1.8vw, 1.35rem);
  padding: 0.32rem 0.5rem 0.26rem;
  background: var(--home-accent);
  color: var(--home-ink);
  font-family: "SuisseScreen", sans-serif;
  font-size: clamp(0.64rem, 0.75vw, 0.8rem);
  font-weight: 700;
  font-style: normal;
  line-height: 1.05;
  letter-spacing: 0.025em;
}

.home-page .intro-copy-stack[data-lang-panel="de"].is-active h1::before {
  content: "[ DESIGN · TECHNOLOGIE · INTERAKTION ]";
}

.home-page .intro-copy-stack[data-lang-panel="en"].is-active h1::before {
  content: "[ DESIGN · TECHNOLOGY · INTERACTION ]";
}

.home-page .intro-text h1 {
  max-width: 9.5ch;
  margin: 0 0 clamp(1rem, 2vh, 1.45rem);
  color: var(--home-ink);
  font-family: "SuisseScreen", sans-serif;
  font-size: clamp(4.5rem, min(7.4vw, 10.5vh), 8rem);
  font-weight: 700;
  font-style: normal;
  line-height: 0.84;
  letter-spacing: -0.065em;
  text-wrap: balance;
}

/* Buttons immediately below title; body copy underneath. */
.home-page .intro-copy {
  display: flex;
  flex-direction: column;
  max-width: 36rem;
}

.home-page .intro-extra-links {
  order: -1;
  position: static !important;
  inset: auto !important;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0 0 clamp(1rem, 2vh, 1.35rem) !important;
}

.home-page .intro-extra-links .hero-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.65rem;
  padding: 0.64rem 0.85rem;
  border: 1px solid var(--home-line);
  border-radius: 999px;
  background: #fff;
  box-shadow: none;
  color: var(--home-ink);
  text-decoration: none;
  font-weight: 700;
  font-style: normal;
  font-size: 0.78rem;
  line-height: 1;
}

.home-page .intro-extra-links .photography-home-link {
  background: var(--home-accent);
  border-color: var(--home-accent) !important;
}

.home-page .intro-extra-links .hero-link:hover,
.home-page .intro-extra-links .hero-link:focus-visible {
  filter: none;
  background: var(--home-ink);
  border-color: var(--home-ink) !important;
  color: #fff;
}

.home-page .intro-copy,
.home-page .intro-copy p,
.home-page .intro-text p {
  max-width: 36rem;
  color: var(--home-ink);
  font-size: clamp(0.98rem, min(1.15vw, 2vh), 1.16rem);
  line-height: 1.48;
  letter-spacing: -0.004em;
}

/* Short desktop windows: fit naturally, never clip at the top/bottom. */
@media (min-width: 1181px) and (hover: hover) and (pointer: fine) and (max-height: 780px) {
  .home-page .intro-text h1 {
    font-size: clamp(3.5rem, min(6.4vw, 8.6vh), 5.8rem);
    margin-bottom: 0.85rem;
  }

  .home-page .intro-copy-stack.is-active h1::before {
    margin-bottom: 0.65rem;
  }

  .home-page .intro-extra-links {
    margin-bottom: 0.8rem !important;
  }

  .home-page .intro-copy,
  .home-page .intro-copy p,
  .home-page .intro-text p {
    font-size: clamp(0.9rem, min(1vw, 1.8vh), 1rem);
    line-height: 1.4;
  }
}

/* Tablet/touch/mobile: preserve the supplied sticky intro system. */
@media (max-width: 1180px), (hover: none), (pointer: coarse) {
  .home-page .intro-section::after {
    background:
      linear-gradient(
        0deg,
        rgba(246, 244, 239, 0.34) 0%,
        rgba(246, 244, 239, 0.16) 34%,
        rgba(246, 244, 239, 0.03) 62%,
        rgba(246, 244, 239, 0) 78%
      );
  }

  .home-page .intro-text {
    width: 100%;
    max-width: 100%;
    margin-right: 0;
  }

  .home-page .intro-text h1 {
    max-width: 9.5ch;
    font-size: clamp(3rem, 13vw, 4.9rem);
    line-height: 0.88;
    margin-bottom: 0.9rem;
  }

  .home-page .intro-copy-stack.is-active h1::before {
    margin-bottom: 0.7rem;
    font-size: clamp(0.56rem, 2.5vw, 0.68rem);
  }

  .home-page .intro-copy {
    max-width: 31rem;
  }

  .home-page .intro-extra-links {
    gap: 0.4rem;
    margin-bottom: 0.85rem !important;
  }

  .home-page .intro-extra-links .hero-link {
    min-height: 2.45rem;
    padding: 0.58rem 0.7rem;
    font-size: 0.7rem;
  }

  .home-page .intro-copy,
  .home-page .intro-copy p,
  .home-page .intro-text p {
    max-width: 31rem;
    font-size: clamp(0.88rem, 3.7vw, 1rem);
    line-height: 1.42;
  }
}

@media (max-width: 700px) and (max-height: 720px) {
  .home-page .intro-text h1 {
    font-size: clamp(2.65rem, 11.8vw, 4rem);
  }

  .home-page .intro-copy,
  .home-page .intro-copy p,
  .home-page .intro-text p {
    font-size: 0.82rem;
    line-height: 1.35;
  }
}


/* =====================================================================
   3. HOME — TOP-RIGHT CONTROLS, SAME ON DESKTOP + MOBILE
   ===================================================================== */

.home-page ~ .footer-links.home-footer-links,
.home-footer-links {
  position: fixed !important;
  top: max(1rem, env(safe-area-inset-top)) !important;
  right: max(1rem, env(safe-area-inset-right)) !important;
  bottom: auto !important;
  left: auto !important;
  z-index: 4500 !important;

  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: flex-end !important;
  gap: 0.32rem !important;

  width: auto !important;
  max-width: calc(100vw - 2rem);
  margin: 0 !important;
  padding: 0 !important;

  transform: none !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  -webkit-backdrop-filter: none !important;
  backdrop-filter: none !important;
}

.home-footer-links .language-links {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  gap: 0 !important;
  width: auto !important;
  margin: 0 !important;
  padding: 0.2rem !important;
  border: 1px solid var(--home-line);
  border-radius: 999px;
  background: #fff;
  box-shadow: none !important;
  -webkit-backdrop-filter: none !important;
  backdrop-filter: none !important;
}

.home-footer-links .language-link-button {
  width: auto !important;
  min-width: 2.1rem !important;
  height: auto !important;
  min-height: 2.1rem !important;
  margin: 0 !important;
  padding: 0.46rem 0.54rem !important;
  border: 0 !important;
  border-radius: 999px !important;
  writing-mode: horizontal-tb !important;
  text-orientation: mixed !important;
  font-size: 0.68rem !important;
  line-height: 1 !important;
}

.home-footer-links .language-link-button.is-active {
  background: #111 !important;
  color: #fff !important;
}

.home-footer-links > .hero-link {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: auto !important;
  min-height: 2.5rem !important;
  margin: 0 !important;
  padding: 0.6rem 0.72rem !important;
  border: 1px solid var(--home-line) !important;
  border-radius: 999px !important;
  background: #fff !important;
  box-shadow: none !important;
  color: #111 !important;
  writing-mode: horizontal-tb !important;
  text-orientation: mixed !important;
  text-decoration: none !important;
  font-size: 0.66rem !important;
  font-weight: 700 !important;
  line-height: 1 !important;
}

.home-footer-links .home-photography-nav {
  background: var(--home-accent) !important;
  border-color: var(--home-accent) !important;
}

.home-footer-links > .hero-link:hover,
.home-footer-links > .hero-link:focus-visible {
  filter: none !important;
  background: #111 !important;
  border-color: #111 !important;
  color: #fff !important;
}

body.project-sidepanel-open .home-footer-links {
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

@media (max-width: 700px), (hover: none), (pointer: coarse) {
  .home-footer-links {
    top: max(0.65rem, env(safe-area-inset-top)) !important;
    right: max(0.65rem, env(safe-area-inset-right)) !important;
    gap: 0.18rem !important;
    max-width: calc(100vw - 1.3rem);
  }

  .home-footer-links .language-links {
    padding: 0.15rem !important;
  }

  .home-footer-links .language-link-button {
    min-width: 1.78rem !important;
    min-height: 1.78rem !important;
    padding: 0.37rem 0.4rem !important;
    font-size: 0.57rem !important;
  }

  .home-footer-links > .hero-link {
    min-height: 2.08rem !important;
    padding: 0.46rem 0.5rem !important;
    font-size: 0.54rem !important;
  }
}


/* =====================================================================
   4. HOME PROJECT COLORS — TRANSPARENT PAPER EFFECT
   Progressive opacity prevents the final stack from becoming muddy.
   Only the custom background variable changes.
   ===================================================================== */

@media (min-width: 1181px) and (hover: hover) and (pointer: fine) {
  .home-page .project-card:nth-child(1)  { --project-bg: #ECE6D8E6 !important; }
  .home-page .project-card:nth-child(2)  { --project-bg: #F0DEE6E6 !important; }
  .home-page .project-card:nth-child(3)  { --project-bg: #E8E0EFE6 !important; }
  .home-page .project-card:nth-child(4)  { --project-bg: #DDE8ECE8 !important; }
  .home-page .project-card:nth-child(5)  { --project-bg: #F0E4D3E8 !important; }
  .home-page .project-card:nth-child(6)  { --project-bg: #EEE5CEEC !important; }
  .home-page .project-card:nth-child(7)  { --project-bg: #F0DDCCEC !important; }
  .home-page .project-card:nth-child(8)  { --project-bg: #E1E4EFF3 !important; }
  .home-page .project-card:nth-child(9)  { --project-bg: #E3EBD8FA !important; }
  .home-page .project-card:nth-child(10) { --project-bg: #EEDFE5FF !important; }
}

/* More opaque on touch/mobile for text legibility. */
@media (max-width: 1180px), (hover: none), (pointer: coarse) {
  .home-page .project-card:nth-child(1)  { --project-bg: #ECE6D8F4 !important; }
  .home-page .project-card:nth-child(2)  { --project-bg: #F0DEE6F4 !important; }
  .home-page .project-card:nth-child(3)  { --project-bg: #E8E0EFF4 !important; }
  .home-page .project-card:nth-child(4)  { --project-bg: #DDE8ECF4 !important; }
  .home-page .project-card:nth-child(5)  { --project-bg: #F0E4D3F4 !important; }
  .home-page .project-card:nth-child(6)  { --project-bg: #EEE5CEF6 !important; }
  .home-page .project-card:nth-child(7)  { --project-bg: #F0DDCCF6 !important; }
  .home-page .project-card:nth-child(8)  { --project-bg: #E1E4EFF8 !important; }
  .home-page .project-card:nth-child(9)  { --project-bg: #E3EBD8FC !important; }
  .home-page .project-card:nth-child(10) { --project-bg: #EEDFE5FF !important; }
}


/* =====================================================================
   5. HOME CTA / SIDEPANEL VISUALS — FLAT, RENDER-SAFE
   No effects on the card shells.
   ===================================================================== */

.home-page .project-open-button {
  border-color: #111;
  background: #111;
  color: #fff;
  box-shadow: none;
}

.home-page .project-open-button:hover,
.home-page .project-open-button:focus-visible {
  filter: none;
  border-color: var(--home-accent);
  background: var(--home-accent);
  color: #111;
  box-shadow: none;
}

.project-sidepanel {
  background: rgba(246, 244, 239, 0.985);
}

.project-sidepanel-close {
  border-color: #111;
  background: #111;
  color: #fff;
  box-shadow: none;
}

.project-sidepanel-close:hover,
.project-sidepanel-close:focus-visible {
  filter: none;
  border-color: #52f4e8;
  background: #52f4e8;
  color: #111;
}

.project-sidepanel-close:focus-visible,
.home-page .project-open-button:focus-visible {
  outline: 2px solid #111;
  outline-offset: 3px;
}


/* =====================================================================
   6. PHOTOGRAPHY — TRUE FULLSCREEN HERO SLIDER
   Multi-image/autoplay lives in photography.php.
   ===================================================================== */

.photography-page [data-photo-lang]:not(.is-active) {
  display: none !important;
}

.photo-hero {
  position: relative;
  display: block;
  width: 100%;
  height: 100vh;
  height: 100svh;
  min-height: 100vh;
  min-height: 100svh;
  padding: 0;
  overflow: hidden;
  background: #111;
}

.photo-hero-media {
  position: absolute !important;
  inset: 0 !important;
  z-index: 0;
  width: 100% !important;
  height: 100% !important;
  min-height: 0 !important;
  max-width: none !important;
  max-height: none !important;
  margin: 0 !important;
  overflow: hidden;
  border-radius: 0 !important;
  background: #111;
  box-shadow: none !important;
  touch-action: pan-y;
  outline: none;
}

.photo-hero-track {
  display: flex;
  width: 100%;
  height: 100%;
  transform: translate3d(0, 0, 0);
  transition: transform 0.62s cubic-bezier(0.22, 1, 0.36, 1);
}

.photo-hero-slide {
  flex: 0 0 100%;
  width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
}

.photo-hero-slide img {
  display: block;
  width: 100% !important;
  height: 100% !important;
  min-height: 0 !important;
  max-height: none !important;
  object-fit: cover !important;
  object-position: center center;
  border-radius: 0 !important;
}

/* Very light support only; the photograph remains visible across the screen. */
.photo-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(
      90deg,
      rgba(246, 244, 239, 0.18) 0%,
      rgba(246, 244, 239, 0.10) 24%,
      rgba(246, 244, 239, 0.03) 42%,
      rgba(246, 244, 239, 0) 58%
    );
}

.photo-hero-copy {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: min(46rem, 55vw);
  height: 100%;
  max-width: none;
  padding:
    max(5.25rem, env(safe-area-inset-top))
    clamp(2rem, 4vw, 4rem)
    max(5rem, env(safe-area-inset-bottom))
    max(clamp(2rem, 4vw, 4rem), env(safe-area-inset-left));
}

.photo-hero h1 {
  font-size: clamp(4.8rem, 9.4vw, 9.5rem);
  line-height: 0.82;
  letter-spacing: -0.075em;
}

.photo-hero-text {
  max-width: 35rem;
}

.photo-availability {
  background: rgba(255, 255, 255, 0.9) !important;
}

.photo-hero-slider-controls {
  position: absolute;
  right: max(1.25rem, env(safe-area-inset-right));
  bottom: max(1.25rem, env(safe-area-inset-bottom));
  z-index: 4;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.photo-hero-slider-nav,
.photo-hero-counter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.7rem;
  border: 1px solid rgba(17, 17, 17, 0.14);
  background: #fff;
  color: #111;
  font-family: "SuisseScreen", sans-serif;
  font-size: 0.7rem;
  font-weight: 700;
  line-height: 1;
}

.photo-hero-slider-nav {
  width: 2.7rem;
  padding: 0;
  border-radius: 50%;
  cursor: pointer;
}

.photo-hero-counter {
  min-width: 4.2rem;
  gap: 0.3rem;
  padding: 0.62rem 0.75rem;
  border-radius: 999px;
  font-variant-numeric: tabular-nums;
}

.photo-hero-slider-nav:hover,
.photo-hero-slider-nav:focus-visible {
  filter: none;
  background: #52f4e8;
  border-color: #52f4e8;
}


/* =====================================================================
   7. PHOTOGRAPHY — NAV SAME HORIZONTAL ARRANGEMENT ON ALL SIZES
   ===================================================================== */

.photography-page .photography-footer-links {
  position: fixed !important;
  top: max(1rem, env(safe-area-inset-top)) !important;
  right: max(1rem, env(safe-area-inset-right)) !important;
  bottom: auto !important;
  left: auto !important;
  z-index: 5000 !important;

  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: flex-end !important;
  gap: 0.32rem !important;

  width: auto !important;
  max-width: calc(100vw - 2rem) !important;
  margin: 0 !important;
  padding: 0 !important;

  transform: none !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  -webkit-backdrop-filter: none !important;
  backdrop-filter: none !important;
}

.photography-page .photography-footer-links .language-links {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  gap: 0 !important;
  width: auto !important;
  margin: 0 !important;
  padding: 0.2rem !important;
  border: 1px solid rgba(17, 17, 17, 0.14) !important;
  border-radius: 999px !important;
  background: #fff !important;
  box-shadow: none !important;
}

.photography-page .photography-footer-links .language-link-button {
  width: auto !important;
  min-width: 2.1rem !important;
  height: auto !important;
  min-height: 2.1rem !important;
  margin: 0 !important;
  padding: 0.46rem 0.54rem !important;
  border: 0 !important;
  border-radius: 999px !important;
  writing-mode: horizontal-tb !important;
  text-orientation: mixed !important;
  font-size: 0.68rem !important;
  line-height: 1 !important;
}

.photography-page .photography-footer-links .language-link-button.is-active {
  background: #111 !important;
  color: #fff !important;
}

.photography-page .photography-footer-links > .hero-link {
  position: static !important;
  inset: auto !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: auto !important;
  min-width: 0 !important;
  min-height: 2.5rem !important;
  margin: 0 !important;
  padding: 0.6rem 0.72rem !important;
  border: 1px solid rgba(17, 17, 17, 0.14) !important;
  border-radius: 999px !important;
  background: #fff !important;
  box-shadow: none !important;
  color: #111 !important;
  writing-mode: horizontal-tb !important;
  text-orientation: mixed !important;
  text-decoration: none !important;
  font-size: 0.66rem !important;
  font-weight: 700 !important;
  line-height: 1 !important;
}

.photography-page .photography-footer-links > .hero-link:hover,
.photography-page .photography-footer-links > .hero-link:focus-visible {
  filter: none !important;
  background: #111 !important;
  border-color: #111 !important;
  color: #fff !important;
}


/* =====================================================================
   8. PHOTOGRAPHY — CATEGORY NAV SAFE AREA
   Desktop reserves a fourth lane for fixed controls.
   ===================================================================== */

@media (min-width: 981px) {
  .photography-page .photo-category-nav {
    grid-template-columns:
      repeat(3, minmax(0, 1fr))
      clamp(16.5rem, 18vw, 19rem);
  }

  .photography-page .photo-category-nav::after {
    content: "";
    display: block;
    grid-column: 4;
    grid-row: 1;
  }

  .photography-page .photo-category-nav a:last-of-type {
    border-right: 1px solid var(--photo-border);
  }
}


/* =====================================================================
   9. PHOTOGRAPHY — RESPONSIVE HERO
   Fullscreen remains fullscreen; only the copy scales/repositions.
   ===================================================================== */

@media (max-width: 980px), (hover: none), (pointer: coarse) {
  .photo-hero {
    display: block;
    height: 100svh;
    min-height: 100svh;
    padding: 0;
  }

  .photo-hero-copy {
    width: min(40rem, 82vw);
    height: 100%;
    max-width: none;
    padding:
      max(5.5rem, calc(env(safe-area-inset-top) + 3.75rem))
      max(1.25rem, env(safe-area-inset-right))
      max(5rem, calc(env(safe-area-inset-bottom) + 3.75rem))
      max(1.25rem, env(safe-area-inset-left));
  }

  .photo-hero::after {
    background:
      linear-gradient(
        90deg,
        rgba(246, 244, 239, 0.16) 0%,
        rgba(246, 244, 239, 0.06) 46%,
        rgba(246, 244, 239, 0) 76%
      );
  }

  .photography-page .photo-category-nav {
    position: relative !important;
    grid-template-columns: minmax(0, 1fr) !important;
    padding-top: calc(3rem + env(safe-area-inset-top));
  }

  .photography-page .photo-category-nav::after {
    content: none !important;
    display: none !important;
  }

  .photography-page .photo-category-nav a:last-of-type {
    border-right: 0;
  }
}

@media (max-width: 700px) {
  .photo-hero-copy {
    justify-content: flex-end;
    width: 100%;
    padding:
      max(5.25rem, calc(env(safe-area-inset-top) + 3.75rem))
      max(1rem, env(safe-area-inset-right))
      max(5.4rem, calc(env(safe-area-inset-bottom) + 4rem))
      max(1rem, env(safe-area-inset-left));
  }

  .photo-hero::after {
    background:
      linear-gradient(
        0deg,
        rgba(246, 244, 239, 0.42) 0%,
        rgba(246, 244, 239, 0.18) 28%,
        rgba(246, 244, 239, 0.04) 52%,
        rgba(246, 244, 239, 0) 74%
      );
  }

  .photo-hero h1 {
    max-width: 100%;
    font-size: clamp(3.2rem, 15.5vw, 5.2rem);
    line-height: 0.86;
    white-space: normal;
  }

  .photo-services-line {
    margin-top: 0.8rem;
    font-size: clamp(0.98rem, 4.8vw, 1.16rem);
  }

  .photo-hero-text {
    margin-top: 0.9rem;
    font-size: clamp(0.86rem, 3.6vw, 0.96rem);
    line-height: 1.4;
  }

  .photo-availability {
    width: fit-content;
    max-width: 100%;
    margin-top: 0.8rem;
    padding: 0.54rem 0.7rem;
    border-radius: 999px;
    font-size: 0.7rem;
  }

  .photo-hero-actions {
    width: 100%;
    margin-top: 0.8rem;
    gap: 0.55rem;
  }

  .photo-primary-cta {
    width: auto;
    min-height: 2.6rem;
    padding: 0.64rem 0.82rem;
    font-size: 0.74rem;
  }

  .photo-location {
    max-width: 20rem;
    font-size: 0.66rem;
  }

  .photo-hero-slider-controls {
    right: max(0.7rem, env(safe-area-inset-right));
    bottom: max(0.7rem, env(safe-area-inset-bottom));
    gap: 0.25rem;
  }

  .photo-hero-slider-nav {
    width: 2.25rem;
    min-height: 2.25rem;
  }

  .photo-hero-counter {
    min-width: 3.55rem;
    min-height: 2.25rem;
    padding: 0.48rem 0.58rem;
    font-size: 0.6rem;
  }

  .photography-page .photography-footer-links {
    top: max(0.65rem, env(safe-area-inset-top)) !important;
    right: max(0.65rem, env(safe-area-inset-right)) !important;
    gap: 0.18rem !important;
    max-width: calc(100vw - 1.3rem) !important;
  }

  .photography-page .photography-footer-links .language-links {
    padding: 0.15rem !important;
  }

  .photography-page .photography-footer-links .language-link-button {
    min-width: 1.78rem !important;
    min-height: 1.78rem !important;
    padding: 0.37rem 0.4rem !important;
    font-size: 0.57rem !important;
  }

  .photography-page .photography-footer-links > .hero-link {
    min-height: 2.08rem !important;
    padding: 0.46rem 0.5rem !important;
    font-size: 0.54rem !important;
  }

  .photography-page .photo-category-nav {
    padding-top: calc(2.8rem + env(safe-area-inset-top));
  }
}

@media (max-width: 700px) and (max-height: 720px) {
  .photo-hero h1 {
    font-size: clamp(2.8rem, 13vw, 4.2rem);
  }

  .photo-hero-text {
    font-size: 0.8rem;
    line-height: 1.34;
  }
}

@supports (height: 100dvh) {
  .photo-hero,
  .photo-hero-media {
    height: 100dvh !important;
    min-height: 100dvh;
  }
}

@media (prefers-reduced-motion: reduce) {
  .photo-hero-track {
    transition: none !important;
  }
}


/* =====================================================================
   10. IMPRINT — SAME EDITORIAL SYSTEM, SCOPED
   ===================================================================== */

.imprint-page {
  --imprint-paper: #f6f4ef;
  --imprint-ink: #111;
  --imprint-accent: #52f4e8;
  --imprint-line: rgba(17, 17, 17, 0.16);

  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 100vh;
  min-height: 100svh;
  overflow: hidden;
  background: var(--imprint-paper);
  color: var(--imprint-ink);
}

.imprint-page::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    linear-gradient(
      90deg,
      rgba(246, 244, 239, 0.34) 0%,
      rgba(246, 244, 239, 0.20) 28%,
      rgba(246, 244, 239, 0.05) 48%,
      rgba(246, 244, 239, 0) 64%
    );
}

.imprint-content-wrapper,
.imprint-page.has-animated-background .imprint-content-wrapper {
  position: relative;
  z-index: 2;
  width: min(56rem, 66vw);
  max-width: none;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
}

.imprint-kicker {
  display: inline-flex;
  width: fit-content;
  margin: 0 0 1.2rem;
  padding: 0.32rem 0.5rem 0.26rem;
  background: var(--imprint-accent);
  font-size: 0.7rem;
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: 0.025em;
}

.imprint-page .intro-title {
  margin: 0;
  font-size: clamp(4.8rem, 9vw, 8.5rem);
  font-weight: 700;
  font-style: normal;
  line-height: 0.84;
  letter-spacing: -0.07em;
}

.imprint-text {
  margin-top: clamp(2rem, 4vw, 3.5rem);
}

.imprint-legal-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  max-width: 50rem;
  border-top: 1px solid var(--imprint-line);
  border-bottom: 1px solid var(--imprint-line);
}

.imprint-legal-block {
  min-width: 0;
  padding: 1.35rem 1.6rem;
}

.imprint-legal-block:first-child {
  padding-left: 0;
  border-right: 1px solid var(--imprint-line);
}

.imprint-legal-block:last-child {
  padding-right: 0;
}

.imprint-legal-label {
  margin: 0 0 0.9rem !important;
  font-size: 0.7rem;
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  opacity: 0.54;
}

.imprint-address {
  margin: 0 !important;
  font-size: clamp(0.98rem, 1.25vw, 1.18rem);
  line-height: 1.55;
}

.imprint-email-link {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  min-height: 2.65rem;
  max-width: 100%;
  padding: 0.66rem 0.86rem;
  border: 1px solid #111;
  border-radius: 999px;
  background: #111;
  color: #fff !important;
  text-decoration: none;
  font-weight: 700;
  line-height: 1;
}

.imprint-email-link:hover,
.imprint-email-link:focus-visible {
  filter: none !important;
  border-color: var(--imprint-accent);
  background: var(--imprint-accent);
  color: #111 !important;
}


/* =====================================================================
   11. IMPRINT NAV — HORIZONTAL TOP RIGHT, RESPONSIVE
   ===================================================================== */

.imprint-page .imprint-footer-links {
  position: fixed !important;
  top: max(1rem, env(safe-area-inset-top)) !important;
  right: max(1rem, env(safe-area-inset-right)) !important;
  bottom: auto !important;
  left: auto !important;
  z-index: 5 !important;

  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  justify-content: flex-end !important;
  gap: 0.32rem !important;

  width: auto !important;
  max-width: calc(100vw - 2rem);
  margin: 0 !important;
  padding: 0 !important;

  transform: none !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.imprint-page .imprint-footer-links > .hero-link {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: auto !important;
  min-height: 2.5rem !important;
  margin: 0 !important;
  padding: 0.6rem 0.72rem !important;
  border: 1px solid rgba(17, 17, 17, 0.14) !important;
  border-radius: 999px !important;
  background: #fff !important;
  box-shadow: none !important;
  color: #111 !important;
  writing-mode: horizontal-tb !important;
  text-orientation: mixed !important;
  text-decoration: none !important;
  font-size: 0.66rem !important;
  font-weight: 700 !important;
  line-height: 1 !important;
}

.imprint-page .imprint-footer-links > .hero-link:hover,
.imprint-page .imprint-footer-links > .hero-link:focus-visible {
  filter: none !important;
  background: #111 !important;
  border-color: #111 !important;
  color: #fff !important;
}

@media (max-width: 700px), (hover: none), (pointer: coarse) {
  .imprint-page {
    align-items: flex-end;
    padding:
      max(5.25rem, calc(env(safe-area-inset-top) + 3.75rem))
      max(1rem, env(safe-area-inset-right))
      max(1.5rem, env(safe-area-inset-bottom))
      max(1rem, env(safe-area-inset-left));
  }

  .imprint-page::after {
    background:
      linear-gradient(
        0deg,
        rgba(246, 244, 239, 0.72) 0%,
        rgba(246, 244, 239, 0.34) 50%,
        rgba(246, 244, 239, 0.04) 80%,
        rgba(246, 244, 239, 0) 100%
      );
  }

  .imprint-content-wrapper,
  .imprint-page.has-animated-background .imprint-content-wrapper {
    width: 100%;
  }

  .imprint-page .intro-title {
    font-size: clamp(3.4rem, 18vw, 5rem);
  }

  .imprint-text {
    margin-top: 1.5rem;
  }

  .imprint-legal-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .imprint-legal-block {
    padding: 0.95rem 0;
  }

  .imprint-legal-block:first-child {
    border-right: 0;
    border-bottom: 1px solid var(--imprint-line);
  }

  .imprint-page .imprint-footer-links {
    top: max(0.65rem, env(safe-area-inset-top)) !important;
    right: max(0.65rem, env(safe-area-inset-right)) !important;
    gap: 0.18rem !important;
    max-width: calc(100vw - 1.3rem);
  }

  .imprint-page .imprint-footer-links > .hero-link {
    min-height: 2.08rem !important;
    padding: 0.46rem 0.5rem !important;
    font-size: 0.54rem !important;
  }
}


/* =====================================================================
   12. LEGAL FOOTER — NO WHITE BAR
   ===================================================================== */

.home-legal-footer {
  background: transparent !important;
  min-height: 0;
}

.home-legal-footer a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.55rem;
  padding: 0.62rem 0.82rem;
  border: 1px solid #111;
  border-radius: 999px;
  background: #111;
  color: #fff;
  opacity: 1;
  text-decoration: none;
  font-weight: 700;
  box-shadow: none;
}

.home-legal-footer a:hover,
.home-legal-footer a:focus-visible {
  filter: none;
  border-color: #52f4e8;
  background: #52f4e8;
  color: #111;
  text-decoration: none;
}



/* =====================================================================
   FINAL ADDITION — MOBILE LEGAL FOOTERS
   Only legal footer presentation; project stack/nav/slider stay untouched.
   ===================================================================== */

.photo-legal-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
  padding:
    1rem
    max(clamp(1.25rem, 4vw, 4rem), env(safe-area-inset-right))
    1rem
    max(clamp(1.25rem, 4vw, 4rem), env(safe-area-inset-left));
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  background: #111;
  color: rgba(255, 255, 255, 0.6);
  font-family: "SuisseScreen", sans-serif;
  font-size: 0.78rem;
  line-height: 1;
}

.photo-legal-footer a {
  color: #fff;
  text-decoration: none;
  font-weight: 700;
}

.photo-legal-footer a:hover,
.photo-legal-footer a:focus-visible {
  filter: none !important;
  opacity: 0.72;
}

@media (max-width: 700px) {
  .home-legal-footer {
    position: relative !important;
    z-index: 210 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    min-height: 3.4rem !important;
    margin: 0 !important;
    padding:
      0.9rem
      max(1rem, env(safe-area-inset-right))
      max(0.9rem, env(safe-area-inset-bottom))
      max(1rem, env(safe-area-inset-left)) !important;
    background: #111 !important;
    color: #fff !important;
  }

  .home-legal-footer a {
    position: static !important;
    inset: auto !important;
    transform: none !important;
    min-height: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: #fff !important;
    font-family: "SuisseScreen", sans-serif !important;
    font-size: 0.76rem !important;
    font-weight: 700 !important;
    line-height: 1 !important;
    text-decoration: none !important;
  }

  .home-legal-footer a::before {
    content: "© Franz Hagen · ";
    color: rgba(255, 255, 255, 0.58);
    font-weight: 500;
  }

  .home-legal-footer a::after {
    content: " ↗";
  }

  .home-legal-footer a:hover,
  .home-legal-footer a:focus-visible {
    transform: none !important;
    filter: none !important;
    opacity: 0.74;
  }

  .photo-legal-footer {
    padding:
      0.9rem
      max(1rem, env(safe-area-inset-right))
      max(0.9rem, env(safe-area-inset-bottom))
      max(1rem, env(safe-area-inset-left));
    font-size: 0.72rem;
  }
}



/* =====================================================================
   RESPONSIVE V2 — MOBILE PHOTOGRAPHY VIEWPORT
   Baseline: portfolio_CORRECT_FINAL_STATE
   Scope: Photography hero sizing only.
   ===================================================================== */

/*
 * iOS Safari:
 * 100dvh grows/shrinks with the browser chrome and can make the hero
 * appear vertically stretched. On phones we deliberately use the
 * stable small viewport instead, so one hero always fits one screen.
 */
@media (max-width: 700px) {
  .photography-page .photo-hero,
  .photography-page .photo-hero-media {
    height: 100svh !important;
    min-height: 100svh !important;
    max-height: 100svh !important;
  }

  .photography-page .photo-hero-copy {
    box-sizing: border-box;
    height: 100svh !important;
    min-height: 0 !important;
    max-height: 100svh !important;

    justify-content: flex-end;

    padding:
      max(4.25rem, calc(env(safe-area-inset-top) + 3.35rem))
      max(1rem, env(safe-area-inset-right))
      max(4.15rem, calc(env(safe-area-inset-bottom) + 3.25rem))
      max(1rem, env(safe-area-inset-left)) !important;
  }

  /* Compact vertical rhythm so the full hero copy fits on normal phones. */
  .photography-page .photo-eyebrow {
    margin-bottom: 0.65rem !important;
  }

  .photography-page .photo-hero h1 {
    font-size: clamp(2.8rem, 12.8vw, 4.15rem) !important;
    line-height: 0.88 !important;
    letter-spacing: -0.06em !important;
  }

  .photography-page .photo-services-line {
    margin-top: 0.55rem !important;
  }

  .photography-page .photo-hero-text {
    margin-top: 0.65rem !important;
  }

  .photography-page .photo-availability {
    margin-top: 0.65rem !important;
  }

  .photography-page .photo-hero-actions {
    margin-top: 0.65rem !important;
  }

  .photography-page .photo-hero-slide img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    object-position: center center;
  }
}

/* Extra protection for short iPhones / landscape-like viewport heights. */
@media (max-width: 700px) and (max-height: 740px) {
  .photography-page .photo-hero-copy {
    padding-top: max(3.8rem, calc(env(safe-area-inset-top) + 3rem)) !important;
    padding-bottom: max(3.5rem, calc(env(safe-area-inset-bottom) + 2.8rem)) !important;
  }

  .photography-page .photo-hero h1 {
    font-size: clamp(2.45rem, 11.2vw, 3.55rem) !important;
  }

  .photography-page .photo-eyebrow,
  .photography-page .photo-services-line,
  .photography-page .photo-hero-text,
  .photography-page .photo-availability,
  .photography-page .photo-hero-actions {
    margin-top: 0.45rem !important;
    margin-bottom: 0 !important;
  }

  .photography-page .photo-primary-cta {
    min-height: 2.35rem !important;
    padding: 0.55rem 0.72rem !important;
  }

  .photography-page .photo-location {
    line-height: 1.25 !important;
  }
}



/* =====================================================================
   RESPONSIVE V3 — PHOTOGRAPHY MOBILE SECTIONS
   Fixes the exact overflow visible on iPhone:
   - category nav is one compact row
   - section headlines always fit viewport
   - reduced excessive vertical whitespace
   - gallery remains full-width
   ===================================================================== */

@media (max-width: 700px) {

  /* ---------------------------------------------------------------
     CATEGORY NAV
     Three compact equal-width cells instead of three huge rows.
     Keep the top reserve for the existing DE/EN/Home/Anfragen controls.
     --------------------------------------------------------------- */
  .photography-page .photo-category-nav {
    position: relative !important;
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;

    width: 100% !important;
    min-width: 0 !important;

    padding-top: calc(3rem + env(safe-area-inset-top)) !important;

    overflow: visible !important;
    border-top: 0;
    border-bottom: 1px solid var(--photo-border);
  }

  .photography-page .photo-category-nav a {
    min-width: 0 !important;
    min-height: 3.15rem !important;

    padding: 0.68rem 0.52rem !important;

    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    justify-content: center !important;
    gap: 0.22rem !important;

    border-right: 1px solid var(--photo-border) !important;
    border-bottom: 0 !important;

    font-size: clamp(0.66rem, 2.8vw, 0.76rem) !important;
    line-height: 1.05 !important;
    text-align: left;
    white-space: normal !important;
  }

  .photography-page .photo-category-nav a:last-child {
    border-right: 0 !important;
  }

  .photography-page .photo-category-nav a > span:first-child {
    margin: 0 !important;
    font-size: 0.56rem !important;
    line-height: 1 !important;
    opacity: 0.46;
  }

  /* ---------------------------------------------------------------
     SERVICE SECTIONS
     --------------------------------------------------------------- */
  .photography-page .photo-service {
    width: 100%;
    max-width: 100%;
    min-width: 0;

    padding:
      2.75rem
      max(1rem, env(safe-area-inset-right))
      3.5rem
      max(1rem, env(safe-area-inset-left)) !important;

    overflow: hidden;
  }

  .photography-page .photo-service-header {
    display: block !important;
    width: 100%;
    min-width: 0;
    margin-bottom: 1.7rem !important;
  }

  .photography-page .photo-service-index {
    margin: 0 0 0.85rem !important;
    padding: 0 !important;
    font-size: 0.72rem !important;
    line-height: 1 !important;
  }

  .photography-page .photo-service-heading {
    display: block !important;
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  /*
   * Critical overflow fix:
   * "Hochzeiten" must fit even at 320px viewport width.
   */
  .photography-page .photo-service h2 {
    display: block;
    width: 100%;
    max-width: 100%;

    margin: 0 !important;

    font-size: clamp(2.65rem, 12vw, 3.75rem) !important;
    line-height: 0.9 !important;
    letter-spacing: -0.055em !important;

    white-space: normal !important;
    overflow-wrap: normal !important;
    word-break: normal !important;
  }

  .photography-page .photo-service-copy {
    width: 100%;
    max-width: 34rem;
    margin-top: 1rem !important;
    padding-bottom: 0 !important;
  }

  /* ---------------------------------------------------------------
     GALLERY
     One clear photographic column on phones.
     --------------------------------------------------------------- */
  .photography-page .photo-gallery {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 0.8rem !important;

    width: 100%;
    min-width: 0;
  }

  .photography-page .photo-gallery-item,
  .photography-page .photo-gallery-item:nth-child(6n + 1),
  .photography-page .photo-gallery-item:nth-child(6n + 4),
  .photography-page .photo-gallery-item:nth-child(6n + 5) {
    grid-column: auto !important;
    width: 100% !important;
    max-width: 100% !important;
  }

  .photography-page .photo-gallery-item img,
  .photography-page .photo-gallery-item:nth-child(6n + 1) img {
    display: block;
    width: 100% !important;
    max-width: 100% !important;

    height: auto !important;
    max-height: none !important;

    object-fit: contain !important;
  }
}

/* Extra-narrow phones */
@media (max-width: 360px) {
  .photography-page .photo-category-nav a {
    padding-inline: 0.4rem !important;
    font-size: 0.62rem !important;
  }

  .photography-page .photo-service h2 {
    font-size: clamp(2.35rem, 11.5vw, 3rem) !important;
  }

  .photography-page .photo-service {
    padding-inline: max(0.85rem, env(safe-area-inset-left)) !important;
  }
}



/* =====================================================================
   RESPONSIVE V4 — MOBILE HERO LINK INTERACTION
   The transparent project-scroller runway visually overlaps the sticky
   intro. Let that transparent area pass touches through to the Hero,
   while every actual project card remains fully interactive.
   ===================================================================== */

@media (max-width: 1180px), (hover: none), (pointer: coarse) {
  .home-page .project-scroller {
    pointer-events: none !important;
  }

  .home-page .project-card,
  .home-page .project-card *,
  .home-page .project-scroller .project-card {
    pointer-events: auto;
  }

  .home-page .intro-extra-links {
    position: relative !important;
    z-index: 5;
    pointer-events: auto !important;
  }

  .home-page .intro-extra-links .hero-link {
    pointer-events: auto !important;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
  }
}



/* =====================================================================
   RESPONSIVE V6 — BETTERPLACE END STATE
   Keep the entire mobile page ending in the final project's color.
   The legal footer is revealed by scrolling, without a white strip.
   ===================================================================== */

@media (max-width: 1180px), (hover: none), (pointer: coarse) {
  /*
   * The existing mobile runway is essential for the sticky final card.
   * We only give it the last project's background so it visually remains
   * part of BETTERPLACE instead of exposing the document background.
   */
  .home-page .project-scroller::after {
    background: var(--last-project-bg, #ead7df) !important;
  }

  /*
   * Prevent the page background from appearing between the last card
   * and the legal footer.
   */
  .home-page,
  .home-page body,
  body:has(.home-page) {
    background: var(--last-project-bg, #ead7df);
  }

  /*
   * The footer is a genuine scroll destination, but visually remains
   * inside the BETTERPLACE color field.
   */
  .home-legal-footer {
    position: relative !important;
    z-index: 210 !important;

    display: flex !important;
    align-items: center !important;
    justify-content: center !important;

    width: 100% !important;
    min-height: 4.25rem !important;
    margin: 0 !important;

    padding:
      1rem
      max(1rem, env(safe-area-inset-right))
      max(1rem, env(safe-area-inset-bottom))
      max(1rem, env(safe-area-inset-left)) !important;

    background: var(--last-project-bg, #ead7df) !important;
    color: #111 !important;

    border: 0 !important;
  }

  .home-legal-footer a {
    position: static !important;
    inset: auto !important;
    transform: none !important;

    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 0.4rem !important;

    min-height: 0 !important;
    padding: 0 !important;

    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;

    color: #111 !important;
    font-family: "SuisseScreen", sans-serif !important;
    font-size: 0.76rem !important;
    font-weight: 700 !important;
    line-height: 1 !important;
    text-decoration: none !important;
    white-space: nowrap !important;
  }

  .home-legal-footer a::before {
    content: "© Franz Hagen · ";
    color: rgba(0, 0, 0, 0.5) !important;
    font-weight: 500;
  }

  .home-legal-footer a::after {
    content: " ↗";
  }

  .home-legal-footer a:hover,
  .home-legal-footer a:focus-visible {
    transform: none !important;
    filter: none !important;
    opacity: 0.68;
  }
}



/* =====================================================================
   RESPONSIVE V8 — SAFE MOBILE FIXES
   Baseline: RESPONSONSIVE V6 (known-good Home layout)
   Desktop footer and desktop stack are intentionally untouched.
   ===================================================================== */

/* ---------------------------------------------------------------------
   1. HOME MOBILE END
   Do NOT paint the whole project-scroller.
   Instead place a Betterplace-coloured layer above the mobile footer.
   It sits below the last sticky card (z-index 100), but above the intro,
   so underlying imagery cannot show through in the end gap.
   --------------------------------------------------------------------- */
@media (max-width: 700px) {
  .home-legal-footer {
    z-index: 90 !important;
    isolation: isolate;
  }

  .home-legal-footer::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 100%;
    height: 100svh;

    background: #FCE7F3;
    pointer-events: none;

    /*
     * The final project card uses z-index: 100.
     * Footer + end-cover sit at 90, therefore the pink cover can hide
     * the underlying intro/image without ever covering BETTERPLACE.
     */
    z-index: -1;
  }
}

/* ---------------------------------------------------------------------
   2. SAME MOBILE FOOTER ON HOME + PHOTOGRAPHY
   Desktop remains exactly as it was in V6.
   --------------------------------------------------------------------- */
@media (max-width: 700px) {
  .home-legal-footer,
  .photo-legal-footer {
    position: relative !important;

    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 1rem !important;

    width: 100% !important;
    min-height: 4.25rem !important;
    margin: 0 !important;

    padding:
      0.95rem
      max(1rem, env(safe-area-inset-right))
      calc(0.95rem + env(safe-area-inset-bottom))
      max(1rem, env(safe-area-inset-left)) !important;

    border: 0 !important;
    border-top: 1px solid rgba(255,255,255,.14) !important;

    background: #111 !important;
    color: #fff !important;

    font-family: "SuisseScreen", sans-serif !important;
    font-size: 0.72rem !important;
    line-height: 1 !important;
  }

  /* Home has only the Impressum link in markup.
     Add the copyright visually so it matches Photography. */
  .home-legal-footer::before {
    content: "© Franz Hagen";
    color: rgba(255,255,255,.58);
    font: inherit;
    font-weight: 500;
    white-space: nowrap;
  }

  .home-legal-footer a,
  .photo-legal-footer a {
    position: static !important;
    inset: auto !important;
    transform: none !important;

    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 0.35rem !important;

    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;

    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;

    color: #fff !important;
    font: inherit !important;
    font-weight: 700 !important;
    text-decoration: none !important;
    white-space: nowrap !important;
  }

  /* Older Home footer rules add an arrow via ::after. Keep exactly
     one arrow and no duplicate pseudo-content. */
  .home-legal-footer a::before {
    content: none !important;
    display: none !important;
  }

  .home-legal-footer a::after {
    content: "↗" !important;
    display: inline !important;
    margin-left: 0.1rem !important;
    font-size: 0.95em !important;
  }

  .photo-legal-footer .photo-legal-copyright {
    color: rgba(255,255,255,.58) !important;
    font: inherit !important;
    font-weight: 500 !important;
    white-space: nowrap;
  }
}

/* ---------------------------------------------------------------------
   3. PHOTOGRAPHY BOOKING HEADLINE
   Override the old oversized 21vw mobile rule.
   --------------------------------------------------------------------- */
@media (max-width: 700px) {
  .photography-page .photo-booking {
    width: 100%;
    min-width: 0;

    padding:
      3.5rem
      max(1rem, env(safe-area-inset-right))
      calc(4.25rem + env(safe-area-inset-bottom))
      max(1rem, env(safe-area-inset-left)) !important;
  }

  .photography-page .photo-booking-main {
    width: 100%;
    max-width: 100% !important;
    min-width: 0;
  }

  .photography-page .photo-booking h2 {
    display: block !important;

    width: 100% !important;
    max-width: 100% !important;

    margin: 0 !important;

    font-size: clamp(2.55rem, 11.5vw, 3.7rem) !important;
    line-height: 0.9 !important;
    letter-spacing: -0.055em !important;

    white-space: normal !important;
    overflow-wrap: normal !important;
    word-break: normal !important;
    text-wrap: balance;
  }

  .photography-page .photo-booking h2 .photo-lang.is-active {
    display: block !important;
    width: 100%;
    max-width: 100%;
  }

  .photography-page .photo-booking-copy {
    width: 100%;
    max-width: 100% !important;
    margin-top: 1.25rem !important;
  }

  .photography-page .photo-booking-actions {
    width: 100%;
    max-width: 100%;
    margin-top: 1.5rem !important;
  }

  .photography-page .photo-booking-mail {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0;
    overflow-wrap: anywhere;
  }
}

@media (max-width: 360px) {
  .photography-page .photo-booking h2 {
    font-size: clamp(2.25rem, 10.8vw, 2.9rem) !important;
  }
}



/* =====================================================================
   RESPONSIVE V9 — PHOTOGRAPHY HERO READABILITY SCRIM
   Matches the Home hero overlay exactly.
   No markup, slider, autoplay or layout changes.
   ===================================================================== */

/* Desktop/tablet: same left-to-right paper scrim as Home. */
.photography-page .photo-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;

  background:
    linear-gradient(
      90deg,
      rgba(246, 244, 239, 0.30) 0%,
      rgba(246, 244, 239, 0.20) 20%,
      rgba(246, 244, 239, 0.08) 38%,
      rgba(246, 244, 239, 0) 58%
    );
}

/* Mobile: same bottom-up scrim as the Home hero, because the text sits
   lower in the image on narrow screens. */
@media (max-width: 700px) {
  .photography-page .photo-hero::after {
    background:
      linear-gradient(
        0deg,
        rgba(246, 244, 239, 0.34) 0%,
        rgba(246, 244, 239, 0.16) 34%,
        rgba(246, 244, 239, 0.03) 62%,
        rgba(246, 244, 239, 0) 78%
      );
  }
}
