/* ════════════════════════════════════════════════════════════
   kiandezin · v3
   Basisfarbe #511e1d — dunkel, geschmolzen, technisch
   ════════════════════════════════════════════════════════════ */

/* ---------- Display-Schrift für Überschriften ----------
   Nutzt GeomGraphicW03-Bold, wenn lokal installiert oder als
   Datei danebengelegt (GeomGraphicW03-Bold.woff2 / .woff / .otf).
   Sonst greift der geometrische Fallback-Stack.               */
@font-face {
  font-family: 'GeomGraphic';
  src: local('GeomGraphicW03-Bold'),
       local('Geom Graphic W03 Bold'),
       local('GeomGraphic-Bold'),
       local('GeomGraphic Bold'),
       url('GeomGraphicW03-Bold.woff2') format('woff2'),
       url('GeomGraphicW03-Bold.woff')  format('woff'),
       url('GeomGraphicW03-Bold.otf')   format('opentype'),
       url('GeomGraphicW03-Bold.ttf')   format('truetype');
  font-weight: 400 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --brand:      #511e1d;
  --brand-700:  #3d1615;
  --brand-600:  #6b2827;
  --brand-500:  #7c2f2d;
  --brand-400:  #8f3936;
  --brand-300:  #b0524e;
  --brand-200:  #d19792;
  --brand-100:  #efd6d3;

  --bg:         #070505;
  --bg-2:       #0e0909;
  --line:       rgba(176, 82, 78, .14);
  --line-2:     rgba(176, 82, 78, .34);
  --glass:      rgba(16, 9, 9, .58);

  --text:       #f8f1f0;
  --muted:      #b2a09e;
  --dim:        #7e6b69;

  --shell:      1180px;
  --e:          cubic-bezier(.22,.61,.36,1);
  --e-out:      cubic-bezier(.16,1,.3,1);
  --e-in-out:   cubic-bezier(.76,0,.24,1);

  --font-ui:      'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-display: 'GeomGraphic', 'GeomGraphicW03-Bold', 'Poppins', 'Futura', 'Century Gothic', 'Inter', sans-serif;
  --font-mono:    'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --vel: 0;   /* Scroll-Geschwindigkeit, von JS gesetzt */
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}
html.smooth { scroll-behavior: auto; }

body {
  font-family: var(--font-ui);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
body.loading { overflow: hidden; height: 100vh; }

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
::selection { background: var(--brand-400); color: #fff; }

::-webkit-scrollbar { width: 9px; }
::-webkit-scrollbar-track { background: #050303; }
::-webkit-scrollbar-thumb { background: var(--brand); border: 3px solid #050303; }
::-webkit-scrollbar-thumb:hover { background: var(--brand-400); }

kbd {
  font-family: var(--font-mono);
  font-size: .66em;
  line-height: 1;
  padding: 3px 5px;
  border: 1px solid var(--line-2);
  background: rgba(176,82,78,.09);
  color: var(--brand-200);
  border-radius: 3px;
}

/* ════════════════════════════════════════════════════════════
   Display-Typografie
   ════════════════════════════════════════════════════════════ */
.title,
.head-title,
.work-name,
.intro-word,
.lead,
.hero-roles b,
.palette-item-title,
.work-ghost {
  font-family: var(--font-display);
  font-weight: 700;
  font-feature-settings: 'ss01' 1;
}

/* ════════════════════════════════════════════════════════════
   Smooth-Scroll-Container
   ════════════════════════════════════════════════════════════ */
html.smooth #smooth-wrapper {
  position: fixed;
  inset: 0;
  overflow: hidden;
  z-index: 2;
}

/* Einflug: die Seite kommt aus der Tiefe nach vorn */
#smooth-wrapper {
  transform-origin: 50% 46%;
  transform: scale(1.13);
  filter: blur(11px);
  opacity: 0;
  will-change: transform, filter, opacity;
}
body.ready #smooth-wrapper {
  transform: none;
  filter: none;
  opacity: 1;
  transition: transform 1.55s cubic-bezier(.16, 1, .3, 1),
              filter    1.0s  cubic-bezier(.16, 1, .3, 1),
              opacity    .75s ease-out;
}
html.smooth #smooth-content { will-change: transform; }

/* ════════════════════════════════════════════════════════════
   1 · INTRO  ·  Designer-Auftritt statt Terminal
   ════════════════════════════════════════════════════════════ */
.boot {
  position: fixed; inset: 0;
  z-index: 900;
  pointer-events: none;
}
.intro-panel {
  position: absolute;
  left: 0; right: 0;
  height: 50.5%;
  background: #050303;
  transition: transform 1.15s var(--e-in-out);
}
.intro-panel--t { top: 0; }
.intro-panel--b { bottom: 0; }
.boot.out .intro-panel--t { transform: translateY(-101%); }
.boot.out .intro-panel--b { transform: translateY(101%); }

/* ---------- Schnittmarken ---------- */
.crop {
  position: absolute;
  width: 26px; height: 26px;
  border: 0 solid rgba(209,151,146,.34);
  opacity: 0;
  animation: cropIn 1s var(--e-out) .25s forwards;
  transition: opacity .45s var(--e);
}
.boot.out .crop { opacity: 0; }
@keyframes cropIn { to { opacity: 1; } }
.crop--tl { top: 34px; left: 36px;    border-top-width: 1px; border-left-width: 1px; }
.crop--tr { top: 34px; right: 36px;   border-top-width: 1px; border-right-width: 1px; }
.crop--bl { bottom: 34px; left: 36px;  border-bottom-width: 1px; border-left-width: 1px; }
.crop--br { bottom: 34px; right: 36px; border-bottom-width: 1px; border-right-width: 1px; }

.boot-core {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 0;
  transition: opacity .5s var(--e), transform .8s var(--e);
}
.boot.out .boot-core { opacity: 0; transform: scale(.96); }

.intro-logo {
  width: 66px; height: 66px;
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 26px;
  opacity: 0;
  animation: markIn 1.1s var(--e-out) .1s forwards;
}
@keyframes markIn { from { opacity: 0; transform: translateY(10px) scale(.9); } to { opacity: 1; transform: none; } }
.intro-logo img { width: 100%; height: 100%; object-fit: cover; }

.intro-word {
  font-size: clamp(1.9rem, 6vw, 2.9rem);
  letter-spacing: -.045em;
  line-height: 1;
  color: var(--text);
}
.intro-word span {
  display: inline-block;
  opacity: 0;
  transform: translateY(105%);
  animation: introUp .95s var(--e-out) forwards;
}
@keyframes introUp { to { opacity: 1; transform: none; } }

.boot-caption {
  position: relative;
  height: 1.5em;
  margin-top: 12px;
  overflow: hidden;
  font-family: var(--font-mono);
  font-size: .64rem;
  letter-spacing: .34em;
  text-transform: uppercase;
  color: var(--brand-200);
  opacity: 0;
  animation: fadeIn .9s var(--e-out) .9s forwards;
}
.boot-caption span { display: block; white-space: nowrap; }
.boot-caption span.out { animation: capOut .48s var(--e-in-out) forwards; }
.boot-caption span.in  { animation: capIn  .55s var(--e-out) forwards; }
@keyframes capOut { to { transform: translateY(-120%); opacity: 0; } }
@keyframes capIn  { from { transform: translateY(120%); opacity: 0; } to { transform: none; opacity: 1; } }

.boot-rule {
  width: min(64vw, 300px); height: 1px;
  margin: 40px 0 22px;
  background: rgba(176,82,78,.16);
  overflow: hidden;
  opacity: 0;
  animation: fadeIn .8s var(--e-out) .7s forwards;
}
.boot-rule span {
  display: block; height: 100%; width: 0%;
  background: var(--brand-200);
  transition: width .3s linear;
}

.boot-count {
  display: flex;
  align-items: flex-start;
  gap: 3px;
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 8vw, 3.6rem);
  font-weight: 700;
  line-height: .9;
  letter-spacing: -.05em;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  opacity: 0;
  animation: fadeIn .8s var(--e-out) .8s forwards;
}
.boot-count em {
  font-family: var(--font-mono);
  font-style: normal;
  font-size: .26em;
  letter-spacing: .1em;
  color: var(--brand-300);
  margin-top: .35em;
}

/* ---------- Farbleiste, füllt sich mit dem Fortschritt ---------- */
.boot-swatches {
  display: flex;
  gap: 4px;
  margin-top: 34px;
  opacity: 0;
  animation: fadeIn .9s var(--e-out) 1s forwards;
}
.boot-swatches i {
  width: 22px; height: 5px;
  background: rgba(176,82,78,.14);
  transition: background .45s var(--e), transform .45s var(--e-out);
}
.boot-swatches i.on { transform: scaleY(1.6); }

.boot-sign {
  position: absolute;
  left: 50%; bottom: 42px;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: .56rem;
  letter-spacing: .38em;
  text-transform: uppercase;
  color: rgba(126,107,105,.5);
  opacity: 0;
  animation: fadeIn 1s var(--e-out) 1.2s forwards;
  transition: opacity .4s var(--e);
}
.boot.out .boot-sign { opacity: 0; }

@media (max-width: 640px) {
  .crop { width: 18px; height: 18px; }
  .crop--tl, .crop--tr { top: 22px; }
  .crop--bl, .crop--br { bottom: 22px; }
  .crop--tl, .crop--bl { left: 22px; }
  .crop--tr, .crop--br { right: 22px; }
  .boot-swatches i { width: 16px; }
  .boot-sign { letter-spacing: .28em; }
}

/* ════════════════════════════════════════════════════════════
   2 · FIXED LAYER
   ════════════════════════════════════════════════════════════ */
.gl {
  position: fixed; inset: 0;
  width: 100%; height: 100%;
  z-index: 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 1.4s var(--e) .2s;
}
body.ready .gl { opacity: 1; }
html.no-gl .gl { display: none; }

.progress {
  position: fixed; top: 0; left: 0;
  height: 2px; width: 0%;
  z-index: 220;
  background: linear-gradient(90deg, var(--brand-700), var(--brand-300));
  box-shadow: 0 0 14px rgba(176,82,78,.8);
}

.embers {
  position: fixed; inset: 0;
  z-index: 3;
  pointer-events: none;
}

.noise {
  position: fixed; inset: -130%;
  z-index: 210;
  pointer-events: none;
  opacity: .026;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='4'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain .6s steps(3) infinite;
}
@keyframes grain {
  0%   { transform: translate(0,0); }
  33%  { transform: translate(-2%, 2%); }
  66%  { transform: translate(2%, -2%); }
  100% { transform: translate(-1%, -1%); }
}


.vignette {
  position: fixed; inset: 0;
  z-index: 4;
  pointer-events: none;
  background: radial-gradient(136% 96% at 50% 40%, transparent 48%, rgba(0,0,0,.72) 100%);
}

/* ════════════════════════════════════════════════════════════
   5 · COMMAND PALETTE
   ════════════════════════════════════════════════════════════ */
.palette {
  position: fixed; inset: 0;
  z-index: 500;
  display: grid;
  align-items: start;
  justify-items: center;
  padding: clamp(60px, 14vh, 150px) 20px 20px;
  visibility: hidden;
  opacity: 0;
  transition: opacity .3s var(--e), visibility .3s;
}
.palette.open { visibility: visible; opacity: 1; }
.palette-scrim {
  position: absolute; inset: 0;
  background: rgba(4,2,2,.66);
  backdrop-filter: blur(9px) saturate(.7);
}
.palette-box {
  position: relative;
  width: min(100%, 580px);
  background: rgba(13,8,8,.94);
  border: 1px solid var(--line-2);
  box-shadow: 0 50px 120px -40px #000, 0 0 0 1px rgba(0,0,0,.5);
  transform: translateY(-14px) scale(.97);
  opacity: 0;
  transition: transform .42s var(--e-out), opacity .3s var(--e);
}
.palette.open .palette-box { transform: none; opacity: 1; }

.palette-field {
  display: flex; align-items: center; gap: 12px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--line);
  color: var(--brand-300);
}
.palette-field input {
  flex: 1;
  background: none; border: none; outline: none;
  font-family: var(--font-ui);
  font-size: .95rem;
  color: var(--text);
}
.palette-field input::placeholder { color: var(--dim); }

.palette-list {
  list-style: none;
  max-height: min(46vh, 360px);
  overflow-y: auto;
  padding: 8px;
}
.palette-list::-webkit-scrollbar { width: 6px; }
.palette-list::-webkit-scrollbar-thumb { background: var(--brand-700); border: none; }

.palette-item {
  display: flex; align-items: center; gap: 13px;
  padding: 11px 13px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background .16s linear, border-color .16s linear;
}
.palette-item.is-active {
  background: rgba(81,30,29,.34);
  border-color: var(--line-2);
}
.palette-icon {
  display: grid; place-items: center;
  width: 26px; height: 26px;
  flex: none;
  font-family: var(--font-mono);
  font-size: .72rem;
  color: var(--brand-200);
  border: 1px solid var(--line);
  background: rgba(176,82,78,.07);
}
.palette-text { flex: 1; min-width: 0; }
.palette-item-title {
  display: block;
  font-size: .88rem;
  font-weight: 700;
  letter-spacing: -.01em;
  color: var(--text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.palette-item-sub {
  display: block;
  font-size: .72rem;
  color: var(--dim);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.palette-tag {
  font-family: var(--font-mono);
  font-size: .58rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--dim);
  padding: 3px 7px;
  border: 1px solid var(--line);
}
.palette-empty {
  padding: 26px 14px;
  text-align: center;
  font-size: .84rem;
  color: var(--dim);
}
.palette-foot {
  display: flex; align-items: center; gap: 16px;
  padding: 10px 16px;
  border-top: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: .6rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--dim);
}
.palette-foot span { display: flex; align-items: center; gap: 5px; }
.palette-brand { margin-left: auto; color: var(--brand-400); }

/* ════════════════════════════════════════════════════════════
   6 · NAV
   ════════════════════════════════════════════════════════════ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 230;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px clamp(18px, 4vw, 46px);
  background: var(--glass);
  backdrop-filter: blur(18px) saturate(1.2);
  border-bottom: 1px solid var(--line);
  transform: translateY(-102%);
  transition: transform .7s var(--e-out);
}
.nav.show { transform: none; }
.nav-brand {
  display: flex; align-items: center; gap: 11px;
  font-size: .84rem; font-weight: 600; letter-spacing: -.01em;
}
.nav-brand img {
  width: 28px; height: 28px;
  border-radius: 3px;
  object-fit: cover;
  border: 1px solid var(--line-2);
  transition: opacity .5s var(--e);
}
.nav-brand:hover img { opacity: .78; }

.nav-links { display: flex; align-items: center; gap: 6px; }
.nav-link {
  position: relative;
  padding: 8px 14px;
  font-size: .79rem;
  color: var(--muted);
  transition: color .3s var(--e);
}
.nav-link span { display: block; transition: transform .45s var(--e-out); }
.nav-link::after {
  content: '';
  position: absolute;
  left: 14px; right: 14px; bottom: 4px;
  height: 1px;
  background: var(--brand-300);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform .5s var(--e-out);
}
.nav-link:hover { color: var(--text); }
.nav-link:hover span { transform: translateY(-2px); }
.nav-link:hover::after { transform: scaleX(1); transform-origin: left; }

.nav-cta {
  position: relative;
  overflow: hidden;
  margin-left: 6px;
  padding: 10px 18px;
  font-size: .79rem;
  font-weight: 500;
  color: var(--text);
  background: transparent;
  border: 1px solid var(--line-2);
  transition: color .35s var(--e), border-color .35s var(--e);
}
.nav-cta > * { position: relative; z-index: 2; }
.nav-cta::before {
  content: '';
  position: absolute;
  left: var(--mx, 50%); top: var(--my, 50%);
  width: 0; aspect-ratio: 1;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  background: var(--brand);
  transition: width .6s var(--e-out);
}
.nav-cta:hover { border-color: var(--brand); color: #fff; }
.nav-cta:hover::before { width: 320%; }

/* ---------- Side-Rail ---------- */
.rail {
  position: fixed;
  right: clamp(14px, 2.4vw, 30px);
  top: 50%;
  transform: translateY(-50%);
  z-index: 225;
  display: flex;
  flex-direction: column;
  gap: 15px;
  opacity: 0;
  transition: opacity .6s var(--e);
}
.rail.show { opacity: 1; }
.rail-dot {
  position: relative;
  width: 8px; height: 8px;
  border: 1px solid var(--line-2);
  background: transparent;
  cursor: pointer;
  transition: background .35s var(--e), transform .35s var(--e), border-color .35s var(--e);
}
.rail-dot:hover { transform: scale(1.4); border-color: var(--brand-200); }
.rail-dot.is-active { background: var(--brand-300); border-color: var(--brand-300); }
.rail-dot em {
  position: absolute;
  right: 20px; top: 50%;
  transform: translate(6px, -50%);
  font-style: normal;
  font-family: var(--font-mono);
  font-size: .58rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s var(--e), transform .3s var(--e);
}
.rail-dot:hover em { opacity: 1; transform: translate(0, -50%); }

/* ════════════════════════════════════════════════════════════
   7 · HERO
   ════════════════════════════════════════════════════════════ */
.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: 128px 24px 132px;
  overflow: hidden;
}

.stage { position: absolute; inset: 0; z-index: 0; }
.layer { position: absolute; inset: 0; }

.layer--img {
  transform: translate3d(calc(var(--px, 0) * 14px), calc(var(--py, 0) * 14px), 0);
  transition: transform .9s var(--e-out);
}
.art {
  position: absolute;
  inset: -6%;
  width: 112%; height: 112%;
  object-fit: cover;
  object-position: center 34%;
  opacity: .5;
  filter: saturate(.8) contrast(1.1);
  transform: scale(1.04);
  animation: drift 24s ease-in-out infinite alternate;
  -webkit-mask-image:
    linear-gradient(to bottom, #000 0%, #000 34%, rgba(0,0,0,.5) 62%, transparent 92%),
    linear-gradient(to right, transparent 0%, #000 16%, #000 84%, transparent 100%);
  mask-image:
    linear-gradient(to bottom, #000 0%, #000 34%, rgba(0,0,0,.5) 62%, transparent 92%),
    linear-gradient(to right, transparent 0%, #000 16%, #000 84%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-composite: intersect;
}
.art--square { display: none; object-position: center 30%; }
@media (max-aspect-ratio: 1/1) {
  .art--wide   { display: none; }
  .art--square { display: block; }
}
@keyframes drift {
  from { transform: scale(1.04) translate3d(0,0,0); }
  to   { transform: scale(1.12) translate3d(-1.4%, -1.8%, 0); }
}

.layer--veil {
  background:
    radial-gradient(64% 52% at 50% 34%, rgba(81,30,29,.4), transparent 72%),
    linear-gradient(180deg, rgba(7,5,5,.7) 0%, rgba(7,5,5,.16) 34%, rgba(7,5,5,.84) 76%, var(--bg) 100%);
}

.layer--streaks {
  top: auto; height: 52%;
  background: repeating-linear-gradient(90deg,
    rgba(176,82,78,.2) 0px, rgba(176,82,78,.2) 1px, transparent 1px, transparent 8px);
  -webkit-mask-image: radial-gradient(58% 100% at 50% 100%, #000 0%, transparent 78%);
  mask-image: radial-gradient(58% 100% at 50% 100%, #000 0%, transparent 78%);
  opacity: .4;
  animation: shimmer 4.6s ease-in-out infinite alternate;
  transform: translate3d(calc(var(--px, 0) * 26px), 0, 0);
}
@keyframes shimmer { from { opacity: .2; } to { opacity: .52; } }

.layer--grid {
  background-image:
    linear-gradient(rgba(176,82,78,.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(176,82,78,.05) 1px, transparent 1px);
  background-size: 74px 74px;
  -webkit-mask-image: radial-gradient(70% 60% at 50% 45%, #000, transparent 78%);
  mask-image: radial-gradient(70% 60% at 50% 45%, #000, transparent 78%);
  opacity: .5;
}

/* ---------- Hero-Inhalt ---------- */
.hero-body {
  position: relative;
  z-index: 5;
  width: min(100%, var(--shell));
  padding: 0 clamp(20px, 5vw, 48px);
  text-align: left;
  transform: translate3d(calc(var(--px, 0) * -7px), calc(var(--py, 0) * -7px + var(--sy, 0px)), 0);
  transition: transform .6s var(--e-out);
}

.hero-top {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 30px;
}
.hero-tagline {
  display: flex;
  flex-direction: column;
  gap: 5px;
  opacity: 0;
  transform: translateX(-10px);
  transition: opacity .9s var(--e) 1.1s, transform .9s var(--e-out) 1.1s;
}
body.ready .hero-tagline { opacity: 1; transform: none; }
.hero-kicker {
  display: flex; align-items: center; gap: 8px;
  font-family: var(--font-mono);
  font-size: .64rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--brand-200);
}
.live-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: #6fc98b;
  box-shadow: 0 0 0 0 rgba(111,201,139,.6);
  animation: pulse 2.4s infinite;
}
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(111,201,139,.55); }
  70%  { box-shadow: 0 0 0 9px rgba(111,201,139,0); }
  100% { box-shadow: 0 0 0 0 rgba(111,201,139,0); }
}
.hero-coords {
  font-family: var(--font-mono);
  font-size: .6rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--dim);
}

.title {
  display: flex;
  justify-content: flex-start;
  flex-wrap: wrap;
  font-size: clamp(3.4rem, 14vw, 9.6rem);
  font-weight: 800;
  letter-spacing: -.055em;
  line-height: .92;
}
.title .l { display: inline-block; overflow: hidden; padding: 0 .008em; }
.title i {
  display: inline-block;
  font-style: normal;
  transform: translateY(105%);
  color: #f6efee;
  transition: transform .45s var(--e);
}
body.ready .title i {
  animation: letterIn 1.05s var(--e-out) forwards;
  animation-delay: calc(.15s + var(--i) * .055s);
}
@keyframes letterIn { to { transform: none; } }


/* Rollen-Slot */
.hero-roles {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-top: 20px;
  font-size: clamp(1rem, 2.1vw, 1.35rem);
}
.roles-static { color: var(--dim); font-weight: 300; }
.roles-slot {
  position: relative;
  display: inline-block;
  height: 1.5em;
  overflow: hidden;
  vertical-align: bottom;
}
.roles-slot b {
  display: block;
  font-weight: 700;
  letter-spacing: -.02em;
  color: var(--brand-200);
  white-space: nowrap;
}
.roles-slot b.out { animation: roleOut .5s var(--e-in-out) forwards; }
.roles-slot b.in  { animation: roleIn  .55s var(--e-out) forwards; }
@keyframes roleOut { to { transform: translateY(-115%); opacity: 0; } }
@keyframes roleIn  { from { transform: translateY(115%); opacity: 0; } to { transform: none; opacity: 1; } }

.lede {
  margin: 22px 0 0;
  max-width: 34ch;
  font-size: clamp(.98rem, 1.5vw, 1.08rem);
  font-weight: 200;
  color: var(--muted);
}

.hero-actions {
  margin-top: 34px;
  display: flex;
  justify-content: flex-start;
  gap: 12px;
  flex-wrap: wrap;
}

/* ---------- Buttons ---------- */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 14px 24px;
  font-size: .8rem;
  font-weight: 500;
  letter-spacing: .01em;
  overflow: hidden;
  background: transparent;
  border: 1px solid var(--line-2);
  color: var(--text);
  transition: transform .4s var(--e), color .4s var(--e), border-color .4s var(--e);
  will-change: transform;
}
.btn > * { position: relative; z-index: 2; }
/* Fuellung waechst als Kreis aus der Cursorposition */
.btn::before {
  content: '';
  position: absolute;
  left: var(--mx, 50%); top: var(--my, 50%);
  z-index: 1;
  width: 0; aspect-ratio: 1;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  background: var(--brand);
  transition: width .62s var(--e-out);
}
.btn:hover::before,
.btn:focus-visible::before { width: 340%; }

/* duenner Lichtrand, der beim Hover mitwandert */
.btn::after {
  content: '';
  position: absolute; inset: -1px;
  z-index: 3;
  pointer-events: none;
  border: 1px solid transparent;
  background: radial-gradient(120px circle at var(--mx, 50%) var(--my, 50%),
              color-mix(in srgb, var(--brand-200) 55%, transparent), transparent 70%) border-box;
  -webkit-mask: linear-gradient(#000 0 0) padding-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask: linear-gradient(#000 0 0) padding-box, linear-gradient(#000 0 0);
          mask-composite: exclude;
  opacity: 0;
  transition: opacity .4s var(--e);
}
.btn:hover::after { opacity: 1; }

/* Beschriftung wird beim Hover ausgetauscht */
.btn-txt {
  display: inline-grid;
  overflow: hidden;
  line-height: 1.35;
}
.btn-txt i {
  grid-area: 1 / 1;
  font-style: normal;
  white-space: nowrap;
  transition: transform .52s var(--e-out), opacity .34s var(--e);
}
.btn-txt i:nth-child(2) { transform: translateY(115%); opacity: 0; }
.btn:hover .btn-txt i:nth-child(1) { transform: translateY(-115%); opacity: 0; }
.btn:hover .btn-txt i:nth-child(2) { transform: none; opacity: 1; transition-delay: .06s; }

.btn--solid { background: var(--brand); border-color: var(--brand); color: #fdf3f2; }
.btn--solid::before { background: color-mix(in srgb, var(--brand) 64%, #fff); }
.btn--solid:hover { color: #fff; border-color: color-mix(in srgb, var(--brand) 64%, #fff); }
.btn--ghost { color: var(--muted); }
.btn--ghost:hover { color: #fff; border-color: var(--brand-300); }

/* Symbol fliegt raus und kommt von der anderen Seite zurueck */
.btn svg { opacity: .72; transition: opacity .4s var(--e); }
.btn:hover svg { opacity: 1; animation: btnIconX .6s var(--e-out); }
.btn--down:hover svg { animation: btnIconY .6s var(--e-out); }
@keyframes btnIconX {
  0%   { transform: none;               opacity: 1; }
  42%  { transform: translateX(150%);   opacity: 0; }
  43%  { transform: translateX(-150%);  opacity: 0; }
  100% { transform: none;               opacity: 1; }
}
@keyframes btnIconY {
  0%   { transform: none;               opacity: 1; }
  42%  { transform: translateY(150%);   opacity: 0; }
  43%  { transform: translateY(-150%);  opacity: 0; }
  100% { transform: none;               opacity: 1; }
}

/* ---------- Hero-Fuß ---------- */
.hero-foot {
  position: absolute;
  left: 0; right: 0; bottom: 26px;
  z-index: 5;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  padding: 0 clamp(18px, 4vw, 46px);
}
.hero-meta {
  font-family: var(--font-mono);
  font-size: .6rem;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--dim);
  opacity: 0;
}
body.ready .hero-meta { animation: fadeIn 1.2s var(--e-out) 1.5s forwards; }
.cue { display: flex; flex-direction: column; align-items: center; gap: 9px; opacity: 0; }
body.ready .cue { animation: fadeIn 1.2s var(--e-out) 1.35s forwards; }
.cue-rail { position: relative; width: 1px; height: 46px; background: rgba(176,82,78,.24); overflow: hidden; }
.cue-rail i {
  position: absolute; top: -100%; left: 0;
  width: 100%; height: 100%;
  background: linear-gradient(180deg, transparent, var(--brand-200));
  animation: cue 2.1s var(--e-in-out) infinite;
}
@keyframes cue { to { top: 100%; } }
.cue-txt {
  font-family: var(--font-mono);
  font-size: .58rem; letter-spacing: .3em;
  text-transform: uppercase; color: var(--dim);
}
@keyframes fadeIn { to { opacity: 1; } }

@media (max-width: 640px) {
  .hero { padding: 110px 20px 140px; }
  .hero-body { padding: 0 4px; }
  .hero-foot { padding: 0 20px; justify-content: center; }
  .hero-meta { display: none; }
}

/* ════════════════════════════════════════════════════════════
   8 · MARQUEE (scrollgeschwindigkeits-reaktiv)
   ════════════════════════════════════════════════════════════ */
.marquee {
  position: relative;
  z-index: 5;
  overflow: hidden;
  padding: 16px 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: linear-gradient(90deg, rgba(81,30,29,.04), rgba(81,30,29,.14), rgba(81,30,29,.04));
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee-track {
  display: flex; align-items: center; gap: 30px;
  width: max-content;
  will-change: transform;
}
.marquee-track span {
  font-family: var(--font-mono);
  font-size: .72rem; letter-spacing: .26em;
  text-transform: uppercase; color: var(--muted);
  white-space: nowrap;
  transition: color .3s var(--e);
}
.marquee-track span:hover { color: var(--brand-200); }
.marquee-track b { color: var(--brand-400); font-size: .64rem; font-weight: 400; }

/* ════════════════════════════════════════════════════════════
   9 · SECTIONS · HEADS
   ════════════════════════════════════════════════════════════ */
.section { position: relative; z-index: 5; padding: clamp(84px, 12vw, 150px) 0; }
.shell { width: 100%; max-width: var(--shell); margin: 0 auto; padding: 0 clamp(20px, 5vw, 48px); }

.head {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: clamp(38px, 6vw, 62px);
}
.head-num {
  font-family: var(--font-mono);
  font-size: .66rem;
  letter-spacing: .2em;
  color: var(--brand-400);
  font-variant-numeric: tabular-nums;
}
.head-title {
  font-size: clamp(2rem, 5vw, 3.4rem);
  font-weight: 700;
  letter-spacing: -.035em;
  line-height: 1;
  white-space: nowrap;
}
.head-title .w { display: inline-block; overflow: hidden; vertical-align: bottom; }
.head-title .w i {
  display: inline-block; font-style: normal;
  transform: translateY(105%);
  transition: transform .9s var(--e-out);
  transition-delay: calc(var(--wi) * .05s);
}
.head.in .head-title .w i { transform: none; }
.head-line {
  flex: 1; height: 1px;
  background: linear-gradient(90deg, var(--line-2), transparent);
  transform: scaleX(0); transform-origin: left;
  transition: transform 1.3s var(--e-out) .2s;
}
.head.in .head-line { transform: scaleX(1); }
.head-note {
  font-family: var(--font-mono);
  font-size: .64rem; letter-spacing: .18em;
  text-transform: uppercase; color: var(--dim);
  white-space: nowrap;
  opacity: 0;
  transition: opacity .8s var(--e) .6s;
}
.head.in .head-note { opacity: 1; }

@media (max-width: 640px) {
  .head { flex-wrap: wrap; gap: 12px; }
  .head-note { display: none; }
}

/* ════════════════════════════════════════════════════════════
   11 · PROJEKTE
   ════════════════════════════════════════════════════════════ */
.works {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(18px, 2.6vw, 30px);
}

.work {
  position: relative;
  display: flex;
  flex-direction: column;
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 1s var(--e-out), transform 1s var(--e-out);
}
.work.in { opacity: 1; transform: none; }
.work:nth-child(2) { transition-delay: .1s; }
.work:nth-child(3) { transition-delay: .2s; }

/* ---------- Logo-Fläche · rahmenlos, freigestellt, mittig ---------- */
.work-media {
  position: relative;
  display: grid;
  place-items: center start;
  aspect-ratio: 16 / 11;
  padding: 0;
  border: 0;
  background: none;
  outline: none;
  transition: transform .6s var(--e);
  will-change: transform;
  /* weicher Beschnitt, damit vergrößerte Logos nicht in den Text laufen */
  -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 7%, #000 93%, transparent 100%);
  mask-image: linear-gradient(180deg, transparent 0, #000 7%, #000 93%, transparent 100%);
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
}
.work-media:focus-visible { outline: none; }

/* weicher Farbschein hinter dem Logo */
.work-glow {
  position: absolute;
  left: 50%; top: 50%;
  width: 92%; aspect-ratio: 1 / .72;
  transform: translate(-50%, -50%) scale(.82);
  background: radial-gradient(closest-side, color-mix(in srgb, var(--accent) 60%, transparent) 0%, transparent 72%);
  filter: blur(44px);
  opacity: .24;
  pointer-events: none;
  transition: opacity .7s var(--e), transform .9s var(--e-out);
}
.work-media:hover .work-glow,
.work-media:focus-visible .work-glow { opacity: .72; transform: translate(-50%, -50%) scale(1.04); }

.work-shot {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  /* feste Spur, damit height:100% der Kinder eine definite Basis hat */
  grid-template-columns: 100%;
  grid-template-rows: 100%;
  place-items: center center;
}
.work-shot img {
  width: 100%; height: 100%;
  object-fit: contain;
  object-position: center center;
  transform-origin: center center;
  filter: saturate(.6) brightness(.94) drop-shadow(0 16px 30px rgba(0,0,0,.5));
  transform: translate(calc(var(--ink-cx, 0%) * -1 * var(--logo, 1)),
                       calc(var(--ink-cy, 0%) * -1 * var(--logo, 1)))
             scale(var(--logo, 1));
  transition: transform .9s var(--e-out), filter .7s var(--e);
}
.work-media:hover .work-shot img,
.work-media:focus-visible .work-shot img {
  transform: translate(calc(var(--ink-cx, 0%) * -1.05 * var(--logo, 1)),
                       calc(var(--ink-cy, 0%) * -1.05 * var(--logo, 1) - 6px))
             scale(calc(var(--logo, 1) * 1.05));
  filter: saturate(1.08) brightness(1.06) drop-shadow(0 26px 42px rgba(0,0,0,.55));
}

/* ---------- Textteil ---------- */
.work-info { position: relative; padding: 18px 2px 0; }
.work-head { display: flex; align-items: baseline; gap: 11px; flex-wrap: wrap; }
.work-idx {
  font-family: var(--font-mono);
  font-size: .64rem;
  letter-spacing: .22em;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}
.work-name {
  font-size: clamp(1.3rem, 2.3vw, 1.75rem);
  font-weight: 700;
  letter-spacing: -.03em;
  line-height: 1.1;
}
.work-role {
  font-family: var(--font-mono);
  font-size: .62rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--accent);
  padding: 3px 9px;
  border: 1px solid color-mix(in srgb, var(--accent) 34%, transparent);
}
.work-desc {
  margin-top: 11px;
  max-width: 42ch;
  font-size: .9rem;
  font-weight: 300;
  color: var(--muted);
  line-height: 1.6;
}
.work-tags {
  list-style: none;
  display: flex; flex-wrap: wrap; gap: 6px;
  margin-top: 15px;
}
.work-tags li {
  font-family: var(--font-mono);
  font-size: .62rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--dim);
  padding: 4px 9px;
  border: 1px solid var(--line);
  transition: color .35s var(--e), border-color .35s var(--e);
}
.work:hover .work-tags li {
  color: var(--muted);
  border-color: color-mix(in srgb, var(--accent) 30%, transparent);
}

.work-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 18px;
  padding-bottom: 3px;
  font-family: var(--font-mono);
  font-size: .73rem;
  color: var(--muted);
  border-bottom: 1px solid var(--line);
  transition: color .4s var(--e), border-color .4s var(--e), gap .4s var(--e);
}
.work-link:hover {
  color: var(--accent);
  border-color: color-mix(in srgb, var(--accent) 55%, transparent);
  gap: 13px;
}
.work-link svg { transition: transform .4s var(--e); }
.work-link:hover svg { transform: translateX(3px); }

@media (max-width: 1000px) {
  .works { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 34px 26px; }
}
@media (max-width: 680px) {
  .works { grid-template-columns: 1fr; gap: 42px; }
  .work:nth-child(n) { transition-delay: 0s; }
  .work-media { aspect-ratio: 16 / 8; }
}

/* ════════════════════════════════════════════════════════════
   12 · PARTIKEL-PORTRAIT
   ════════════════════════════════════════════════════════════ */
.section--art { padding-top: clamp(30px, 5vw, 60px); }
.portrait {
  position: relative;
  border: 1px solid var(--line);
  background:
    radial-gradient(80% 100% at 50% 0%, rgba(81,30,29,.2), transparent 68%),
    linear-gradient(180deg, rgba(81,30,29,.06), rgba(7,5,5,.4));
  overflow: hidden;
  aspect-ratio: 16 / 9;
  clip-path: inset(0 0 100% 0);
  transition: clip-path 1.3s var(--e-in-out), border-color .5s var(--e);
}
.portrait.in { clip-path: inset(0 0 0 0); }
.portrait:hover { border-color: var(--line-2); }
.portrait canvas { width: 100%; height: 100%; display: block; }

.portrait-corner {
  position: absolute;
  width: 16px; height: 16px;
  border: 1px solid var(--brand-400);
  opacity: .5;
  pointer-events: none;
  transition: opacity .5s var(--e), transform .5s var(--e-out);
}
.portrait-corner--tl { top: 12px; left: 12px;  border-right: 0; border-bottom: 0; }
.portrait-corner--tr { top: 12px; right: 12px; border-left: 0;  border-bottom: 0; }
.portrait-corner--bl { bottom: 12px; left: 12px;  border-right: 0; border-top: 0; }
.portrait-corner--br { bottom: 12px; right: 12px; border-left: 0;  border-top: 0; }
.portrait:hover .portrait-corner { opacity: 1; }
.portrait:hover .portrait-corner--tl { transform: translate(-3px, -3px); }
.portrait:hover .portrait-corner--tr { transform: translate(3px, -3px); }
.portrait:hover .portrait-corner--bl { transform: translate(-3px, 3px); }
.portrait:hover .portrait-corner--br { transform: translate(3px, 3px); }

.portrait-stat {
  position: absolute;
  top: 14px; left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: .58rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--dim);
  pointer-events: none;
}

.portrait-hint {
  position: absolute;
  left: 50%; bottom: 18px;
  transform: translateX(-50%);
  display: flex; align-items: center; gap: 9px;
  padding: 7px 15px;
  font-family: var(--font-mono);
  font-size: .64rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  background: rgba(8,5,5,.62);
  border: 1px solid var(--line);
  backdrop-filter: blur(8px);
  pointer-events: none;
  transition: opacity .5s var(--e);
  text-align: center;
}
.portrait:hover .portrait-hint { opacity: 0; }
.portrait-hint i {
  width: 6px; height: 6px;
  background: var(--brand-300);
  flex: none;
}
.portrait.is-static .portrait-hint,
.portrait.is-static .portrait-stat { display: none; }

@media (max-width: 640px) {
  .portrait { aspect-ratio: 4 / 5; }
  .portrait-hint { font-size: .56rem; max-width: 80%; }
}

/* ════════════════════════════════════════════════════════════
   13 · ÜBER MICH
   ════════════════════════════════════════════════════════════ */
.about {
  display: grid;
  grid-template-columns: minmax(0, .82fr) minmax(0, 1.18fr);
  gap: clamp(28px, 5vw, 60px);
  align-items: start;
}

.frame {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 5;
  border: 1px solid var(--line);
  clip-path: inset(0 0 100% 0);
  transition: clip-path 1.3s var(--e-in-out);
}
.frame.in { clip-path: inset(0 0 0 0); }
.frame-img {
  width: 100%; height: 116%;
  object-fit: cover;
  object-position: center 30%;
  transform: translateY(var(--pv, 0px)) scale(1.02);
  filter: saturate(.8) contrast(1.06);
  transition: transform .3s linear, filter .6s var(--e);
}
.frame:hover .frame-img { filter: saturate(1) contrast(1.12); }
.frame::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(81,30,29,.16), rgba(7,5,5,.6));
  pointer-events: none;
}
.frame figcaption {
  position: absolute;
  left: 18px; bottom: 12px;
  z-index: 2;
  font-family: 'UnifrakturMaguntia', serif;
  font-size: 2.4rem;
  line-height: 1;
  color: rgba(239,214,211,.82);
  text-shadow: 0 6px 26px rgba(0,0,0,.8);
  pointer-events: none;
}

.about-text { padding-top: 4px; }
.lead {
  font-size: clamp(1.3rem, 2.5vw, 1.8rem);
  font-weight: 700;
  letter-spacing: -.025em;
  line-height: 1.3;
  color: var(--text);
}
.lead .w { display: inline-block; overflow: hidden; vertical-align: bottom; }
.lead .w i {
  display: inline-block; font-style: normal;
  transform: translateY(105%);
  transition: transform .95s var(--e-out);
  transition-delay: calc(var(--wi) * .035s);
}
.lead.in .w i { transform: none; }

.body {
  margin-top: 22px;
  max-width: 58ch;
  font-size: .96rem;
  font-weight: 300;
  color: var(--muted);
}

/* ---------- Skill-Balken ---------- */
.skills { list-style: none; margin-top: 34px; display: grid; gap: 13px; max-width: 520px; }
.skill {
  display: grid;
  grid-template-columns: 130px 1fr 48px;
  align-items: center;
  gap: 14px;
}
.skill-name {
  font-family: var(--font-mono);
  font-size: .68rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
}
.skill-bar {
  position: relative;
  height: 2px;
  background: rgba(176,82,78,.13);
  overflow: hidden;
}
.skill-bar i {
  position: absolute; inset: 0;
  transform-origin: left;
  transform: scaleX(0);
  background: linear-gradient(90deg, var(--brand-600), var(--brand-200));
  transition: transform 1.5s var(--e-out);
  transition-delay: calc(var(--d, 0s) + .2s);
}
.skills.in .skill-bar i { transform: scaleX(var(--v)); }
.skill-val {
  font-family: var(--font-mono);
  font-size: .68rem;
  color: var(--brand-200);
  text-align: right;
  font-variant-numeric: tabular-nums;
}
@media (max-width: 520px) {
  .skill { grid-template-columns: 100px 1fr 42px; gap: 10px; }
  .skill-name { font-size: .6rem; }
}

.tags {
  list-style: none;
  display: flex; flex-wrap: wrap; gap: 8px;
  margin-top: 26px;
}
.tags li {
  font-size: .76rem;
  color: var(--muted);
  padding: 7px 15px;
  border: 1px solid var(--line);
  background: transparent;
  transition: border-color .35s var(--e), color .35s var(--e), background .35s var(--e);
}
.tags li:hover { border-color: var(--brand-300); color: var(--text); }

@media (max-width: 900px) {
  .about { grid-template-columns: 1fr; }
  .frame { max-width: 420px; aspect-ratio: 1 / 1; }
  .rail { display: none; }
}

/* ════════════════════════════════════════════════════════════
   14 · FOOTER
   ════════════════════════════════════════════════════════════ */
.footer {
  position: relative;
  z-index: 5;
  padding: 0 clamp(20px, 5vw, 48px) clamp(26px, 3vw, 38px);
}
.footer-inner {
  width: 100%;
  max-width: var(--shell);
  margin: 0 auto;
  border-top: 1px solid var(--line);
  padding-top: clamp(34px, 5vw, 54px);
}

/* ---------- obere Reihe ---------- */
.footer-top {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr));
  gap: clamp(28px, 5vw, 56px);
  align-items: start;
}

.footer-brand { display: flex; align-items: flex-start; gap: 14px; }
.footer-mark {
  width: 42px; height: 42px;
  flex: none;
  overflow: hidden;
  border: 1px solid var(--line-2);
  transition: border-color .4s var(--e), opacity .4s var(--e);
}
.footer-mark img { width: 100%; height: 100%; object-fit: cover; }
.footer-mark:hover { border-color: var(--brand-300); opacity: .85; }

.footer-id { display: flex; flex-direction: column; gap: 5px; padding-top: 1px; }
.footer-name {
  font-family: var(--font-display);
  font-size: 1.12rem;
  font-weight: 700;
  letter-spacing: -.03em;
  line-height: 1;
  color: var(--text);
}
.footer-claim {
  font-size: .8rem;
  font-weight: 300;
  color: var(--dim);
  max-width: 28ch;
}

/* ---------- Linkspalten ---------- */
.footer-col { display: flex; flex-direction: column; gap: 11px; }
.footer-label {
  font-family: var(--font-mono);
  font-size: .58rem;
  letter-spacing: .26em;
  text-transform: uppercase;
  color: var(--brand-400);
  margin-bottom: 3px;
}
.footer-col a {
  position: relative;
  align-self: flex-start;
  font-size: .84rem;
  font-weight: 300;
  color: var(--muted);
  transition: color .3s var(--e);
}
.footer-col a::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: -3px;
  height: 1px;
  background: var(--brand-300);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform .45s var(--e-out);
}
.footer-col a:hover { color: var(--text); }
.footer-col a:hover::after { transform: scaleX(1); transform-origin: left; }

.footer-status {
  display: flex; align-items: center; gap: 8px;
  font-family: var(--font-mono);
  font-size: .62rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--dim);
  margin-top: 2px;
}

/* ---------- untere Reihe ---------- */
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: clamp(40px, 6vw, 70px);
  padding-top: 20px;
  border-top: 1px solid var(--line);
  font-size: .74rem;
  font-weight: 300;
  color: var(--dim);
}
.to-top {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: .74rem;
  color: var(--muted);
  transition: color .3s var(--e), gap .3s var(--e);
}
.to-top svg { transition: transform .4s var(--e-out); }
.to-top:hover { color: var(--text); gap: 11px; }
.to-top:hover svg { transform: translateY(-3px); }

@media (max-width: 860px) {
  .footer-top { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 34px; }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 480px) {
  .footer-top { grid-template-columns: 1fr; gap: 28px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; gap: 12px; }
}

/* ════════════════════════════════════════════════════════════
   15 · REVEAL-UTILITIES
   ════════════════════════════════════════════════════════════ */
[data-anim="fade"] {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .95s var(--e-out), transform .95s var(--e-out);
  transition-delay: var(--d, 0s);
}
[data-anim="fade"].in { opacity: 1; transform: none; }

/* ════════════════════════════════════════════════════════════
   16 · HERO-MARK + FLYING LOGO
   ════════════════════════════════════════════════════════════ */
.hero-mark {
  position: relative;
  width: 74px; height: 74px;
  flex: none;
  border: 1px solid var(--line-2);
  overflow: hidden;
  opacity: 0;
  transition: opacity .5s var(--e);
}
.hero-mark.show { opacity: 1; }
.hero-mark img { border-radius: 0 !important; }
.mark-ring, .mark-halo { display: none; }

.flying-logo {
  position: fixed;
  z-index: 950;
  overflow: hidden;
  border: 1px solid var(--line-2);
  transition: left 1.1s var(--e-in-out), top 1.1s var(--e-in-out),
              width 1.1s var(--e-in-out), height 1.1s var(--e-in-out);
}
.flying-logo img { width: 100%; height: 100%; object-fit: cover; }
.intro-logo, .flying-logo { border-radius: 4px; }

/* ════════════════════════════════════════════════════════════
   17 · THEME-ÜBERNAHME (Hover über Projekt-Banner)
   ════════════════════════════════════════════════════════════ */
.wash {
  position: fixed; inset: 0;
  z-index: 200;
  pointer-events: none;
  background: radial-gradient(130% 100% at 50% 50%, var(--theme, var(--brand)) 0%, var(--theme, var(--brand)) 45%, transparent 88%);
  mix-blend-mode: color;
  opacity: 0;
  transition: opacity .7s var(--e);
}
html.themed .wash { opacity: var(--wash-strength, .55); }

html.themed {
  --brand:     var(--theme);
  --brand-700: color-mix(in srgb, var(--theme) 62%, #000);
  --brand-600: color-mix(in srgb, var(--theme) 80%, #000);
  --brand-500: color-mix(in srgb, var(--theme) 92%, #000);
  --brand-400: color-mix(in srgb, var(--theme) 88%, #fff);
  --brand-300: color-mix(in srgb, var(--theme) 66%, #fff);
  --brand-200: color-mix(in srgb, var(--theme) 42%, #fff);
  --brand-100: color-mix(in srgb, var(--theme) 20%, #fff);
  --line:      color-mix(in srgb, var(--theme) 20%, transparent);
  --line-2:    color-mix(in srgb, var(--theme) 44%, transparent);
}

body, .nav, .marquee, .head-line, .work-tags li, .tags li, .rail-dot,
.frame, .portrait, .portrait-hint, .work-media, .hero-mark,
.progress, .footer-row, .nav-cta, .btn {
  transition-property: background-color, border-color, color, box-shadow, opacity, transform, filter, clip-path;
  transition-duration: .7s;
  transition-timing-function: cubic-bezier(.22,.61,.36,1);
}

/* ════════════════════════════════════════════════════════════
   18 · GRAVITY-MODUS (Easter Egg)
   ════════════════════════════════════════════════════════════ */
.grav-note {
  position: fixed;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  z-index: 460;
  padding: 16px 26px;
  font-family: var(--font-mono);
  font-size: .74rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--text);
  background: rgba(10,6,6,.86);
  border: 1px solid var(--brand-300);
  backdrop-filter: blur(10px);
  pointer-events: none;
  animation: gravNote 2.6s var(--e-out) forwards;
}
@keyframes gravNote {
  0%   { opacity: 0; transform: translate(-50%, -50%) scale(.9); }
  14%  { opacity: 1; transform: translate(-50%, -50%) scale(1); }
  76%  { opacity: 1; }
  100% { opacity: 0; }
}
.grav-body { position: fixed; z-index: 455; pointer-events: none; will-change: transform; }
body.gravity .title i,
body.gravity .tags li,
body.gravity .work-tags li { visibility: hidden; }

/* ════════════════════════════════════════════════════════════
   19 · REDUCED MOTION
   ════════════════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  .embers, .noise, .gl { display: none; }
  .title i, .head-title .w i, .lead .w i { transform: none !important; }
  [data-anim], .work, .frame, .portrait, .skills { opacity: 1 !important; transform: none !important; clip-path: none !important; }
  .head-line { transform: scaleX(1) !important; }
  .hero-meta, .cue, .hero-tagline { opacity: 1 !important; }
  .hero-mark { opacity: 1 !important; }
  .btn:hover svg, .btn--down:hover svg { animation: none !important; }
  .btn-txt i:nth-child(2) { display: none; }
  .skills .skill-bar i { transform: scaleX(var(--v)) !important; }
}

/* ---------- Drittes Projekt: verschlüsselt ---------- */
.work--secret .work-media { cursor: default; }

.secret-mark {
  position: relative;
  display: grid;
  place-items: center;
  height: 100%;
  aspect-ratio: 1;
}
.secret-ring {
  position: absolute;
  inset: 12%;
  border: 1px dashed color-mix(in srgb, var(--accent) 28%, transparent);
  animation: secretSpin 26s linear infinite;
}
.secret-ring::after {
  content: '';
  position: absolute; inset: 16%;
  border: 1px solid color-mix(in srgb, var(--accent) 14%, transparent);
  animation: secretSpin 18s linear infinite reverse;
}
@keyframes secretSpin { to { transform: rotate(360deg); } }

.secret-glyph {
  position: relative;
  font-family: var(--font-display);
  font-size: clamp(3rem, 7vw, 5.4rem);
  font-weight: 800;
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1.5px color-mix(in srgb, var(--accent) 52%, transparent);
  text-shadow: 0 0 40px color-mix(in srgb, var(--accent) 20%, transparent);
  animation: secretFlicker 5.5s steps(1) infinite;
}
@keyframes secretFlicker {
  0%, 88%, 100% { opacity: 1; transform: none; }
  90%  { opacity: .35; transform: translateX(2px); }
  92%  { opacity: 1;   transform: translateX(-2px); }
  94%  { opacity: .5;  transform: none; }
}
.work--secret .work-media:hover .secret-glyph {
  -webkit-text-stroke-color: var(--accent);
}

.secret-stamp {
  position: absolute;
  left: 50%; bottom: 4px;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: .56rem;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--accent) 46%, transparent);
  pointer-events: none;
}

.work-name--secret {
  color: var(--muted);
  display: inline-block;
  min-width: 9ch;
}
.work--secret .work-desc { color: var(--dim); }

/* geschwärzte Tags */
.work-tags li.redacted {
  padding: 0;
  border-color: transparent;
  background: none;
}
.work-tags li.redacted i {
  display: block;
  width: 74px; height: 21px;
  background: repeating-linear-gradient(90deg,
    rgba(178,160,158,.16) 0 6px, rgba(178,160,158,.06) 6px 12px);
  border: 1px solid var(--line);
}
.work-tags li.redacted:nth-of-type(3) i { width: 52px; }

.work-link--locked {
  color: var(--dim);
  border-bottom-style: dashed;
  cursor: default;
}
.work-link--locked svg { opacity: .7; }

/* ════════════════════════════════════════════════════════════
   20 · LEISTUNGEN
   ════════════════════════════════════════════════════════════ */
.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.card {
  position: relative;
  padding: clamp(24px, 3vw, 34px) clamp(20px, 2.4vw, 30px);
  background: rgba(9, 6, 6, .72);
  transition: background .5s var(--e);
}
.card::after {
  content: '';
  position: absolute;
  left: 0; right: 0; top: 0;
  height: 1px;
  background: var(--brand-300);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .6s var(--e-out);
}
.card:hover { background: rgba(81, 30, 29, .13); }
.card:hover::after { transform: scaleX(1); }

.card-num {
  display: block;
  font-family: var(--font-mono);
  font-size: .6rem;
  letter-spacing: .24em;
  color: var(--brand-400);
  margin-bottom: 16px;
}
.card-title {
  font-family: var(--font-display);
  font-size: 1.16rem;
  font-weight: 700;
  letter-spacing: -.025em;
  line-height: 1.15;
  color: var(--text);
}
.card-text {
  margin-top: 10px;
  font-size: .87rem;
  font-weight: 300;
  line-height: 1.62;
  color: var(--muted);
}
.card-list {
  list-style: none;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  display: grid;
  gap: 7px;
}
.card-list li {
  position: relative;
  padding-left: 15px;
  font-size: .78rem;
  font-weight: 300;
  color: var(--dim);
  transition: color .4s var(--e);
}
.card-list li::before {
  content: '';
  position: absolute;
  left: 0; top: .62em;
  width: 5px; height: 1px;
  background: var(--brand-400);
}
.card:hover .card-list li { color: var(--muted); }

@media (max-width: 900px) { .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .cards { grid-template-columns: 1fr; } }

/* ════════════════════════════════════════════════════════════
   21 · ABLAUF
   ════════════════════════════════════════════════════════════ */
.section--flow { padding-top: clamp(20px, 3vw, 40px); }
.flow {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(20px, 3vw, 38px);
  counter-reset: flow;
}
.flow-step {
  position: relative;
  padding-top: 26px;
  border-top: 1px solid var(--line);
}
.flow-step::before {
  content: '';
  position: absolute;
  left: 0; top: -1px;
  width: 26px; height: 1px;
  background: var(--brand-300);
}
.flow-num {
  display: block;
  font-family: var(--font-mono);
  font-size: .6rem;
  letter-spacing: .24em;
  color: var(--brand-400);
  margin-bottom: 12px;
}
.flow-title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -.025em;
  color: var(--text);
}
.flow-text {
  margin-top: 9px;
  font-size: .84rem;
  font-weight: 300;
  line-height: 1.62;
  color: var(--muted);
  max-width: 34ch;
}

@media (max-width: 900px) { .flow { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 30px; } }
@media (max-width: 520px) { .flow { grid-template-columns: 1fr; } }

/* ════════════════════════════════════════════════════════════
   22 · KONTAKT
   ════════════════════════════════════════════════════════════ */
.section--contact { padding-bottom: clamp(60px, 8vw, 100px); }
.contact {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr);
  gap: clamp(34px, 6vw, 78px);
  align-items: start;
}

.contact-lead {
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 3.6vw, 2.6rem);
  font-weight: 700;
  letter-spacing: -.035em;
  line-height: 1.14;
  color: var(--text);
}
.contact-lead .w { display: inline-block; overflow: hidden; vertical-align: bottom; }
.contact-lead .w i {
  display: inline-block; font-style: normal;
  transform: translateY(105%);
  transition: transform .95s var(--e-out);
  transition-delay: calc(var(--wi) * .045s);
}
.contact-lead.in .w i { transform: none; }

.contact-text {
  margin-top: 20px;
  max-width: 54ch;
  font-size: .95rem;
  font-weight: 300;
  line-height: 1.72;
  color: var(--muted);
}
.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}
.contact-actions .btn { font-family: var(--font-ui); cursor: pointer; }
.contact-actions .btn--ghost span { font-family: var(--font-mono); font-size: .78rem; }

/* ---------- Eckdaten ---------- */
.contact-facts {
  border-top: 1px solid var(--line);
  padding-top: 4px;
}
.fact {
  display: grid;
  grid-template-columns: 40% 1fr;
  gap: 14px;
  padding: 15px 0;
  border-bottom: 1px solid var(--line);
}
.fact dt {
  font-family: var(--font-mono);
  font-size: .6rem;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--dim);
  padding-top: 2px;
}
.fact dd {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: .86rem;
  font-weight: 300;
  color: var(--text);
}

@media (max-width: 860px) {
  .contact { grid-template-columns: 1fr; }
  .contact-facts { margin-top: 6px; }
}

/* ---------- Abflug: Intro faehrt auf den Betrachter zu ---------- */
.boot.launch .boot-core {
  animation: coreFly .66s cubic-bezier(.55, 0, .85, .25) forwards;
}
@keyframes coreFly {
  from { transform: scale(1);   filter: blur(0);    opacity: 1; }
  to   { transform: scale(2.7); filter: blur(14px); opacity: 0; }
}

.crop--tl { --fx: -50px; --fy: -50px; }
.crop--tr { --fx:  50px; --fy: -50px; }
.crop--bl { --fx: -50px; --fy:  50px; }
.crop--br { --fx:  50px; --fy:  50px; }
.boot.launch .crop {
  animation: none;
  opacity: 0;
  transform: translate(var(--fx), var(--fy));
  transition: transform .6s cubic-bezier(.55, 0, .85, .25), opacity .45s linear;
}
.boot.launch .boot-sign {
  animation: none;
  opacity: 0;
  transition: opacity .3s linear;
}

/* Lichtblitz im Moment des Durchbruchs */
.flash {
  position: fixed; inset: 0;
  z-index: 880;
  pointer-events: none;
  opacity: 0;
  background: radial-gradient(62% 52% at 50% 46%,
              rgba(255, 242, 240, .8),
              color-mix(in srgb, var(--brand-300) 55%, transparent) 42%,
              transparent 76%);
}
.flash.go { animation: flashOut .9s ease-out forwards; }
@keyframes flashOut {
  0%   { opacity: .85; }
  100% { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  #smooth-wrapper { transform: none !important; filter: none !important; opacity: 1 !important; }
  .boot.launch .boot-core { animation: none; opacity: 0; }
  .flash { display: none; }
}

/* ════════════════════════════════════════════════════════════
   23 · Ton-Schalter
   ════════════════════════════════════════════════════════════ */
.sound {
  position: fixed;
  right: clamp(14px, 3vw, 30px);
  bottom: clamp(14px, 3vw, 26px);
  z-index: 240;
  display: grid;
  place-items: center;
  width: 38px; height: 38px;
  padding: 0;
  background: rgba(8, 5, 5, .5);
  border: 1px solid var(--line);
  backdrop-filter: blur(10px);
  cursor: pointer;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .8s var(--e) 1.9s, transform .8s var(--e-out) 1.9s,
              border-color .3s var(--e), background .3s var(--e);
}
body.ready .sound { opacity: 1; transform: none; }
.sound:hover { border-color: var(--brand-300); background: rgba(81, 30, 29, .34); }

.sound-bars {
  display: flex;
  align-items: center;
  gap: 2px;
  height: 14px;
}
.sound-bars i {
  width: 2px;
  height: 3px;
  background: var(--dim);
  transition: background .3s var(--e);
}
.sound.is-on .sound-bars i {
  background: var(--brand-200);
  animation: bars 1.05s ease-in-out infinite;
}
.sound.is-on .sound-bars i:nth-child(1) { animation-delay: 0s; }
.sound.is-on .sound-bars i:nth-child(2) { animation-delay: .16s; }
.sound.is-on .sound-bars i:nth-child(3) { animation-delay: .32s; }
.sound.is-on .sound-bars i:nth-child(4) { animation-delay: .48s; }
@keyframes bars {
  0%, 100% { height: 3px; }
  50%      { height: 13px; }
}

@media (prefers-reduced-motion: reduce) {
  .sound { opacity: 1 !important; transform: none !important; }
  .sound.is-on .sound-bars i { animation: none; height: 8px; }
}

/* ---------- Ton ist verfuegbar, wartet aber auf einen Klick ---------- */
.sound.is-armed { border-color: var(--line-2); }
.sound.is-armed .sound-bars i { background: var(--brand-300); }
.sound.is-armed::after {
  content: '';
  position: absolute;
  inset: -1px;
  border: 1px solid var(--brand-300);
  opacity: 0;
  animation: soundPing 2.6s ease-out infinite;
  pointer-events: none;
}
@keyframes soundPing {
  0%   { opacity: .55; transform: scale(1); }
  70%  { opacity: 0;   transform: scale(1.35); }
  100% { opacity: 0;   transform: scale(1.35); }
}
@media (prefers-reduced-motion: reduce) {
  .sound.is-armed::after { animation: none; opacity: .4; transform: none; }
}
