:root {
  --bg: #0a0a0a;
  --bg-soft: #121110;
  --panel: rgba(255, 255, 255, 0.055);
  --panel-strong: rgba(255, 255, 255, 0.09);
  --line: rgba(255, 255, 255, 0.16);
  --line-soft: rgba(255, 255, 255, 0.09);
  --text: #f6f4ef;
  --muted: rgba(246, 244, 239, 0.68);
  --muted-2: rgba(246, 244, 239, 0.48);
  --accent: #c27a3a;
  --accent-2: #ffb56b;
  --radius: 28px;
  --pad: clamp(1.25rem, 4vw, 4.5rem);
  --max: 1540px;
  --font: "Satoshi", "Space Grotesk", "Neue Montreal", Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono: "SF Mono", "Roboto Mono", ui-monospace, Menlo, Consolas, monospace;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background: var(--bg);
}

body {
  min-width: 320px;
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at 22% 0%, rgba(194, 122, 58, 0.15), transparent 34rem),
    radial-gradient(circle at 96% 12%, rgba(255, 255, 255, 0.08), transparent 30rem),
    var(--bg);
  font-family: var(--font);
  line-height: 1.5;
  text-rendering: geometricPrecision;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.22;
  background-image:
    radial-gradient(circle at 20% 30%, rgba(255,255,255,0.55) 0 0.5px, transparent 0.75px),
    radial-gradient(circle at 80% 70%, rgba(255,255,255,0.35) 0 0.5px, transparent 0.75px);
  background-size: 11px 11px, 17px 17px;
  mix-blend-mode: screen;
}

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

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

button,
a {
  -webkit-tap-highlight-color: transparent;
}

::selection {
  color: #0a0a0a;
  background: var(--accent-2);
}

.skip-link {
  position: fixed;
  top: 1rem;
  left: 1rem;
  z-index: 100;
  transform: translateY(-160%);
  padding: 0.75rem 1rem;
  color: var(--bg);
  background: var(--text);
  border-radius: 999px;
  transition: transform 180ms ease;
}

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

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: clamp(0.95rem, 2.2vw, 1.6rem) var(--pad);
  color: var(--text);
  transition: background 220ms ease, border-color 220ms ease, backdrop-filter 220ms ease;
  border-bottom: 1px solid transparent;
}

.site-header.is-scrolled {
  border-bottom-color: var(--line-soft);
  background: rgba(10, 10, 10, 0.68);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.8rem;
  min-width: 0;
  font-size: clamp(0.82rem, 1.2vw, 0.96rem);
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.brand img {
  width: 2.15rem;
  height: 2.15rem;
  object-fit: contain;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 3vw, 2.75rem);
  color: rgba(246, 244, 239, 0.72);
  font-size: clamp(0.78rem, 1vw, 0.9rem);
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.main-nav a {
  position: relative;
  transition: color 180ms ease;
}

.main-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -0.42rem;
  width: 100%;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 180ms ease;
}

.main-nav a:hover,
.main-nav a:focus-visible {
  color: var(--text);
}

.main-nav a:hover::after,
.main-nav a:focus-visible::after {
  transform: scaleX(1);
  transform-origin: left;
}

.hero {
  position: relative;
  display: grid;
  align-items: end;
  min-height: 100svh;
  overflow: hidden;
  isolation: isolate;
  padding: clamp(7rem, 11vw, 10rem) var(--pad) clamp(2rem, 5vw, 4rem);
}

.hero__image {
  position: absolute;
  inset: 0;
  z-index: -3;
  background-image: url("assets/hero-bar-wide.webp");
  background-size: cover;
  background-position: 58% 50%;
  transform: scale(1.02);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  background:
    linear-gradient(90deg, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.58) 42%, rgba(0,0,0,0.28) 100%),
    linear-gradient(180deg, rgba(0,0,0,0.64) 0%, rgba(0,0,0,0.16) 42%, rgba(0,0,0,0.92) 100%);
}

.hero__grain {
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: 0.22;
  background-image:
    radial-gradient(circle at 32% 18%, rgba(255,255,255,0.75) 0 0.6px, transparent 1px),
    radial-gradient(circle at 76% 80%, rgba(255,255,255,0.55) 0 0.5px, transparent 1px);
  background-size: 9px 9px, 13px 13px;
}

.hero__content {
  width: min(100%, 1180px);
  padding-top: 10vh;
}

.eyebrow {
  margin: 0 0 clamp(0.8rem, 1.8vw, 1.2rem);
  color: var(--accent-2);
  font-family: var(--mono);
  font-size: clamp(0.72rem, 1vw, 0.86rem);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero h1,
.section h2,
.project-card h3 {
  margin: 0;
  line-height: 0.86;
  letter-spacing: -0.075em;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 11ch;
  font-size: clamp(5rem, 14vw, 15.8rem);
  font-weight: 950;
}

.hero__claim {
  margin: clamp(1.1rem, 2vw, 1.65rem) 0 0;
  color: var(--text);
  font-size: clamp(1rem, 2.2vw, 2.2rem);
  font-weight: 850;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.hero__lead {
  max-width: 680px;
  margin: clamp(1rem, 2vw, 1.45rem) 0 0;
  color: rgba(246, 244, 239, 0.78);
  font-size: clamp(1.04rem, 1.6vw, 1.45rem);
}

.hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: clamp(1.35rem, 2vw, 2rem);
}

.hero__meta span,
.project-card__tags span {
  display: inline-flex;
  align-items: center;
  min-height: 2.25rem;
  padding: 0.55rem 0.85rem;
  color: rgba(246, 244, 239, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.055);
  backdrop-filter: blur(12px);
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.scroll-cue {
  position: absolute;
  right: var(--pad);
  bottom: clamp(1.5rem, 4vw, 3rem);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  width: clamp(4.8rem, 8vw, 6.5rem);
  height: clamp(4.8rem, 8vw, 6.5rem);
  color: #0a0a0a;
  background: var(--accent-2);
  border-radius: 50%;
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  box-shadow: 0 1.5rem 5rem rgba(255, 181, 107, 0.22);
  transition: transform 180ms ease, background 180ms ease;
}

.scroll-cue:hover,
.scroll-cue:focus-visible {
  transform: translateY(-0.25rem);
  background: #ffd09b;
}

.scroll-cue svg {
  width: 1.05rem;
  height: 1.05rem;
}

.section {
  position: relative;
  width: min(100%, var(--max));
  margin: 0 auto;
  padding: clamp(5rem, 10vw, 10rem) var(--pad);
}

.section__number {
  color: var(--muted-2);
  font-family: var(--mono);
  font-size: clamp(1rem, 1.2vw, 1.2rem);
  letter-spacing: 0.14em;
}

.intro {
  display: grid;
  grid-template-columns: minmax(4rem, 18rem) minmax(0, 1fr);
  gap: clamp(2rem, 6vw, 8rem);
  border-top: 1px solid var(--line-soft);
}

.intro__text {
  max-width: 920px;
}

.intro h2,
.section__head h2,
.profile h2,
.principles h2,
.contact h2 {
  font-size: clamp(3.6rem, 10vw, 11.5rem);
  font-weight: 950;
}

.intro p:not(.eyebrow),
.profile p:not(.eyebrow),
.contact p:not(.eyebrow) {
  max-width: 800px;
  color: var(--muted);
  font-size: clamp(1.08rem, 1.6vw, 1.45rem);
}

.projects {
  padding-top: clamp(3rem, 6vw, 7rem);
}

.section__head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: clamp(2.5rem, 5vw, 5rem);
  border-bottom: 1px solid var(--line);
  padding-bottom: clamp(1.25rem, 2vw, 1.85rem);
}

.section__head h2 {
  letter-spacing: -0.085em;
}

.project-card {
  display: grid;
  grid-template-columns: clamp(3rem, 7vw, 8rem) minmax(0, 1fr) minmax(12rem, 20rem);
  gap: clamp(1.25rem, 4vw, 4.25rem);
  padding: clamp(2.1rem, 4.6vw, 5.2rem) 0;
  border-bottom: 1px solid var(--line-soft);
  transition: border-color 180ms ease, transform 180ms ease, background 180ms ease;
}

.project-card:first-of-type {
  border-top: 1px solid var(--line-soft);
}

.project-card:hover {
  border-color: rgba(255, 181, 107, 0.38);
  background: linear-gradient(90deg, rgba(255, 181, 107, 0.04), transparent 62%);
}

.project-card__index {
  color: var(--muted-2);
  font-family: var(--mono);
  font-size: clamp(0.82rem, 1vw, 1rem);
  letter-spacing: 0.14em;
}

.project-card__type {
  margin: 0 0 0.85rem;
  color: var(--accent-2);
  font-family: var(--mono);
  font-size: clamp(0.72rem, 0.9vw, 0.84rem);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.project-card h3 {
  font-size: clamp(2.9rem, 7vw, 8.4rem);
  font-weight: 950;
}

.project-card p:not(.project-card__type) {
  max-width: 760px;
  margin: clamp(0.85rem, 1.5vw, 1.2rem) 0 0;
  color: var(--muted);
  font-size: clamp(1.02rem, 1.35vw, 1.32rem);
}

.project-card__tags {
  display: flex;
  align-content: flex-start;
  align-items: flex-start;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 0.55rem;
  padding-top: 2rem;
}

.project-card--accent h3 {
  color: var(--accent-2);
}

.profile {
  display: grid;
  grid-template-columns: minmax(18rem, 0.86fr) minmax(0, 1fr);
  gap: clamp(2rem, 5vw, 6rem);
  align-items: center;
  border-top: 1px solid var(--line-soft);
}

.profile__media {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: 0 2rem 6rem rgba(0, 0, 0, 0.24);
}

.profile__media::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(0,0,0,0.04), rgba(0,0,0,0.45));
}

.profile__media img {
  width: 100%;
  height: min(65vw, 760px);
  min-height: 480px;
  object-fit: cover;
  object-position: 58% 50%;
  filter: saturate(0.92) contrast(1.05);
}

.profile h2 {
  margin: 0 0 clamp(1.2rem, 2vw, 2rem);
  letter-spacing: -0.08em;
}

.profile p {
  margin-top: 1rem;
}

.principles {
  padding-top: clamp(3rem, 6vw, 7rem);
}

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

.principle {
  min-height: 18rem;
  padding: clamp(1.35rem, 2.4vw, 2.3rem);
  border: 1px solid var(--line-soft);
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--panel), rgba(255,255,255,0.025));
}

.principle span {
  color: var(--accent-2);
  font-family: var(--mono);
  font-size: 0.82rem;
  letter-spacing: 0.15em;
}

.principle h3 {
  margin: clamp(2.4rem, 5vw, 4.6rem) 0 0.85rem;
  font-size: clamp(1.7rem, 2.8vw, 3rem);
  line-height: 0.95;
  letter-spacing: -0.04em;
  text-transform: uppercase;
}

.principle p {
  margin: 0;
  color: var(--muted);
  font-size: clamp(0.98rem, 1.1vw, 1.12rem);
}

.contact {
  min-height: 72svh;
  display: grid;
  align-items: center;
  border-top: 1px solid var(--line-soft);
}

.contact__inner {
  max-width: 1180px;
}

.contact h2 {
  margin: 0;
  letter-spacing: -0.085em;
}

.contact p:not(.eyebrow) {
  margin-top: clamp(1.5rem, 2.5vw, 2.5rem);
  color: var(--text);
  font-weight: 850;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.site-footer {
  width: min(100%, var(--max));
  margin: 0 auto;
  padding: clamp(1.4rem, 3vw, 2.4rem) var(--pad) clamp(2rem, 4vw, 3rem);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  color: var(--muted-2);
  border-top: 1px solid var(--line-soft);
  font-size: 0.92rem;
}

.brand--footer {
  color: var(--text);
  font-size: 0.82rem;
}

.brand--footer img {
  width: 1.75rem;
  height: 1.75rem;
}

.js .reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 700ms ease, transform 700ms cubic-bezier(.2,.8,.2,1);
}

.js .reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 1100px) {
  .project-card {
    grid-template-columns: clamp(3rem, 7vw, 5rem) minmax(0, 1fr);
  }

  .project-card__tags {
    grid-column: 2;
    justify-content: flex-start;
    padding-top: 0.2rem;
  }

  .profile,
  .principles__grid {
    grid-template-columns: 1fr;
  }

  .profile__media img {
    height: 64vw;
    min-height: 360px;
  }
}

@media (max-width: 760px) {
  :root {
    --radius: 20px;
  }

  .site-header {
    align-items: flex-start;
  }

  .brand span {
    display: none;
  }

  .main-nav {
    gap: 0.9rem;
    font-size: 0.68rem;
    letter-spacing: 0.1em;
  }

  .hero {
    min-height: 100svh;
    padding-top: 7rem;
  }

  .hero__image {
    background-position: 58% 50%;
  }

  .hero::before {
    background:
      linear-gradient(90deg, rgba(0,0,0,0.92) 0%, rgba(0,0,0,0.7) 50%, rgba(0,0,0,0.42) 100%),
      linear-gradient(180deg, rgba(0,0,0,0.72) 0%, rgba(0,0,0,0.2) 40%, rgba(0,0,0,0.94) 100%);
  }

  .hero h1 {
    font-size: clamp(4.2rem, 21vw, 7.4rem);
    letter-spacing: -0.09em;
  }

  .hero__claim {
    max-width: 14rem;
    line-height: 1.05;
  }

  .scroll-cue {
    right: var(--pad);
    width: 4.7rem;
    height: 4.7rem;
  }

  .scroll-cue span {
    display: none;
  }

  .intro,
  .project-card {
    grid-template-columns: 1fr;
  }

  .intro h2,
  .section__head h2,
  .profile h2,
  .principles h2,
  .contact h2 {
    font-size: clamp(3.2rem, 16vw, 6rem);
  }

  .section__head {
    display: block;
  }

  .project-card {
    gap: 0.4rem;
    padding: 2.7rem 0;
  }

  .project-card h3 {
    overflow-wrap: anywhere;
    font-size: clamp(2.7rem, 14vw, 5.2rem);
  }

  .project-card__tags {
    grid-column: auto;
  }

  .project-card__tags span,
  .hero__meta span {
    min-height: 2rem;
    padding: 0.48rem 0.72rem;
    font-size: 0.65rem;
  }

  .principle {
    min-height: auto;
  }

  .site-footer {
    align-items: flex-start;
    flex-direction: column;
  }
}

@media (max-width: 430px) {
  .main-nav a[href="#kontakt"] {
    display: none;
  }

  .hero__lead {
    max-width: 20rem;
  }
}

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

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

  .js .reveal {
    opacity: 1;
    transform: none;
  }
}

/* V2: Stabilisierung nach Mobile- und Fullpage-Screenshot-Test */
html,
body {
  overflow-x: clip;
}

@supports not (overflow: clip) {
  html,
  body {
    overflow-x: hidden;
  }
}

/* Inhalte bleiben auch bei Fullpage-Screenshots und ohne JavaScript sichtbar. */
.js .reveal {
  opacity: 1;
  transform: none;
  transition: none;
}

.project-card h3,
.intro h2,
.section__head h2,
.profile h2,
.principles h2,
.contact h2 {
  max-width: 100%;
  text-wrap: balance;
}

.project-card__main,
.intro__text,
.profile__copy,
.contact__inner,
.section__head {
  min-width: 0;
}

@media (max-width: 760px) {
  .hero {
    padding-bottom: 7.8rem;
  }

  .scroll-cue {
    bottom: 1.15rem;
    right: clamp(1rem, 5vw, 1.35rem);
    width: 4.35rem;
    height: 4.35rem;
  }

  .hero h1 {
    font-size: clamp(4rem, 19.6vw, 7rem);
  }

  .intro h2,
  .section__head h2,
  .profile h2,
  .principles h2,
  .contact h2 {
    font-size: clamp(3rem, 13.2vw, 5.35rem);
    letter-spacing: -0.07em;
    overflow-wrap: normal;
    word-break: normal;
  }

  .project-card h3 {
    font-size: clamp(2.65rem, 12.2vw, 4.65rem);
    letter-spacing: -0.065em;
    overflow-wrap: normal;
    word-break: normal;
  }

  .contact {
    min-height: auto;
  }
}

@media (max-width: 430px) {
  .hero h1 {
    font-size: clamp(3.85rem, 18.8vw, 6.4rem);
  }

  .intro h2,
  .section__head h2,
  .profile h2,
  .principles h2,
  .contact h2 {
    font-size: clamp(2.85rem, 12.6vw, 4.7rem);
  }

  .project-card h3 {
    font-size: clamp(2.45rem, 11.6vw, 4.05rem);
  }

  .hero__meta {
    max-width: calc(100% - 4.8rem);
  }
}

/* V4: Soft Stacked Cards.
   Deutlich schwächer als V3: kleinerer Sticky-Bereich, weniger Höhe,
   keine Filter-Animationen und nur minimale GSAP-Transformationen auf großen Desktop-Screens. */
.projects--stacked {
  overflow: visible;
}

.project-stack {
  position: relative;
  display: grid;
  gap: clamp(0.75rem, 1.45vw, 1.15rem);
  padding-bottom: clamp(3.5rem, 7vw, 7rem);
}

.project-stack .project-card {
  position: relative;
  isolation: isolate;
  min-height: clamp(24rem, 48svh, 38rem);
  align-items: end;
  overflow: hidden;
  padding: clamp(2rem, 4.4vw, 5rem);
  border: 1px solid var(--line-soft);
  border-radius: clamp(20px, 2.4vw, 34px);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.082), rgba(255, 255, 255, 0.03) 58%, rgba(194, 122, 58, 0.055)),
    rgba(12, 12, 12, 0.88);
  box-shadow: 0 1.6rem 4.6rem rgba(0, 0, 0, 0.25);
  transform-origin: center top;
  backface-visibility: hidden;
}

.project-stack .project-card:first-of-type {
  border-top: 1px solid var(--line-soft);
}

.project-stack .project-card::before,
.project-stack .project-card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}

.project-stack .project-card::before {
  background:
    radial-gradient(circle at 84% 12%, rgba(255, 181, 107, 0.12), transparent 18rem),
    radial-gradient(circle at 14% 86%, rgba(255, 255, 255, 0.055), transparent 20rem);
  opacity: 0.74;
}

.project-stack .project-card::after {
  opacity: 0.075;
  background-image:
    radial-gradient(circle at 20% 30%, rgba(255,255,255,0.62) 0 0.5px, transparent 0.75px),
    radial-gradient(circle at 80% 70%, rgba(255,255,255,0.34) 0 0.5px, transparent 0.75px);
  background-size: 12px 12px, 18px 18px;
  mix-blend-mode: screen;
}

.project-stack .project-card:hover {
  border-color: rgba(255, 181, 107, 0.32);
  background:
    linear-gradient(135deg, rgba(255, 181, 107, 0.075), rgba(255, 255, 255, 0.035) 58%, rgba(255, 181, 107, 0.045)),
    rgba(12, 12, 12, 0.91);
}

.project-stack .project-card__main {
  max-width: 920px;
}

.project-stack .project-card h3 {
  font-size: clamp(3rem, 7.25vw, 8.5rem);
}

.project-stack .project-card p:not(.project-card__type) {
  max-width: 790px;
}

.project-stack .project-card__tags {
  align-self: start;
  padding-top: 0;
}

@media (min-width: 1100px) and (pointer: fine) {
  .project-stack .project-card {
    position: sticky;
    top: clamp(5rem, 10svh, 7rem);
  }
}

@media (max-width: 1099px) {
  .project-stack {
    gap: 0;
    padding-bottom: 0;
  }

  .project-stack .project-card {
    min-height: auto;
    padding: 2.7rem 0;
    border-right: 0;
    border-left: 0;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
  }

  .project-stack .project-card::before,
  .project-stack .project-card::after {
    display: none;
  }

  .project-stack .project-card:hover {
    background: linear-gradient(90deg, rgba(255, 181, 107, 0.04), transparent 62%);
  }
}
