/* Startseiten-Hero – wird nur in home.html geladen; alle Selektoren mit .st-hero-Präfix */

.st-hero {
  --sth-blue: #044BD9;
  --sth-blue-2: #0487D9;
  --sth-cyan: #0DE6FF;
  --sth-teal: #18c3b2;
  --sth-ink: #0b2a6f;
  --mx: 0;
  --my: 0;

  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: clamp(640px, 94vh, 920px);
  padding: 120px 0 120px;
  color: #fff;
  background: linear-gradient(155deg, #0DE6FF 0%, #0487D9 40%, #044BD9 75%, #0634a8 100%);
}

.st-hero.is-offscreen *,
.st-hero.is-offscreen *::before,
.st-hero.is-offscreen *::after {
  animation-play-state: paused !important;
}

/* ── Hintergrund: Aurora-Blobs + Punktraster ── */
.st-hero__bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}

.st-hero__blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.6;
  transform: translate3d(calc(var(--mx) * -28px), calc(var(--my) * -28px), 0);
  will-change: transform, translate;
}
.st-hero__blob--1 {
  top: -20%;
  left: -12%;
  width: min(46vw, 640px);
  height: min(46vw, 640px);
  background: radial-gradient(circle, #8ff6ff 0%, transparent 65%);
  animation: sth-drift-1 18s ease-in-out infinite alternate;
}
.st-hero__blob--2 {
  top: 10%;
  right: -10%;
  width: min(40vw, 560px);
  height: min(40vw, 560px);
  background: radial-gradient(circle, var(--sth-teal) 0%, transparent 65%);
  animation: sth-drift-2 22s ease-in-out infinite alternate;
}
.st-hero__blob--3 {
  bottom: -28%;
  left: 28%;
  width: min(38vw, 520px);
  height: min(38vw, 520px);
  background: radial-gradient(circle, #7b93ff 0%, transparent 65%);
  animation: sth-drift-3 26s ease-in-out infinite alternate;
}
@keyframes sth-drift-1 { to { translate: 12vw 8vh; } }
@keyframes sth-drift-2 { to { translate: -10vw 12vh; } }
@keyframes sth-drift-3 { to { translate: 8vw -14vh; } }

.st-hero__grid {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, 0.22) 1px, transparent 1.4px);
  background-size: 26px 26px;
  -webkit-mask-image: radial-gradient(ellipse 60% 60% at 72% 45%, #000 0%, transparent 75%);
          mask-image: radial-gradient(ellipse 60% 60% at 72% 45%, #000 0%, transparent 75%);
}

/* ── Layout ── */
.st-hero__inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(2rem, 4vw, 4rem);
}

/* ── Text-Spalte ── */
.st-hero__copy > * {
  animation: sth-rise 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}
.st-hero__copy > :nth-child(1) { animation-delay: 0.05s; }
.st-hero__copy > :nth-child(2) { animation-delay: 0.12s; }
.st-hero__copy > :nth-child(3) { animation-delay: 0.28s; }
.st-hero__copy > :nth-child(4) { animation-delay: 0.42s; }
.st-hero__copy > :nth-child(5) { animation-delay: 0.56s; }

@keyframes sth-rise {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: none; }
}

/* H1 + Lead ohne Opacity-Fade: sofort sichtbar, damit LCP (Core Web Vitals) nicht verzögert wird */
.st-hero__title,
.st-hero__lead { animation-name: sth-slide; }
@keyframes sth-slide {
  from { transform: translateY(16px); }
  to   { transform: none; }
}

.st-hero__badge {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.45rem 1rem 0.45rem 0.8rem;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  -webkit-backdrop-filter: blur(8px);
          backdrop-filter: blur(8px);
  font-size: 0.85rem;
  font-weight: 600;
}

.st-hero__pulse {
  flex-shrink: 0;
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background: #5dffb0;
  animation: sth-pulse 2s ease-out infinite;
}
@keyframes sth-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(93, 255, 176, 0.7); }
  70%  { box-shadow: 0 0 0 0.55rem rgba(93, 255, 176, 0); }
  100% { box-shadow: 0 0 0 0 rgba(93, 255, 176, 0); }
}

.st-hero__title {
  margin: 1.3rem 0 1.1rem;
  color: #fff;
  font-family: "Raleway", sans-serif;
  font-size: clamp(2.1rem, 3.5vw, 3.2rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
}
.st-hero__title span {
  background: linear-gradient(100deg, #ffffff 0%, #b9fbff 25%, #86f3e6 50%, #ffffff 75%, #b9fbff 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
          background-clip: text;
  color: transparent;
  animation: sth-shimmer 7s linear infinite;
}
@keyframes sth-shimmer { to { background-position: -200% center; } }

.st-hero__lead {
  max-width: 36rem;
  margin: 0 0 2rem;
  color: rgba(255, 255, 255, 0.9);
  font-size: clamp(1rem, 1.15vw, 1.12rem);
  line-height: 1.7;
}

/* Buttons */
.st-hero__ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
}

.st-hero__btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.95rem 1.6rem;
  border-radius: 999px;
  font-family: "Raleway", sans-serif;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}
.st-hero__btn svg { transition: transform 0.2s ease; }
.st-hero__btn:hover svg { transform: translateX(3px); }

.st-hero__btn--primary {
  position: relative;
  overflow: hidden;
  background: #fff;
  color: var(--sth-blue);
  box-shadow: 0 12px 30px rgba(3, 30, 110, 0.35);
}
.st-hero__btn--primary:hover,
.st-hero__btn--primary:focus-visible {
  color: var(--sth-blue);
  transform: translateY(-2px);
  box-shadow: 0 16px 36px rgba(3, 30, 110, 0.45);
}
/* Lichtreflex, der regelmäßig über den Haupt-Button läuft */
.st-hero__btn--primary::after {
  content: "";
  position: absolute;
  top: 0;
  left: -60%;
  width: 40%;
  height: 100%;
  background: linear-gradient(100deg, transparent, rgba(4, 135, 217, 0.2), transparent);
  transform: skewX(-20deg);
  animation: sth-shine 4.5s ease-in-out 1.5s infinite;
}
@keyframes sth-shine {
  0%        { left: -60%; }
  30%, 100% { left: 130%; }
}

.st-hero__btn--glass {
  border: 1px solid rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.12);
  -webkit-backdrop-filter: blur(8px);
          backdrop-filter: blur(8px);
  color: #fff;
}
.st-hero__btn--glass:hover,
.st-hero__btn--glass:focus-visible {
  background: rgba(255, 255, 255, 0.22);
  color: #fff;
  transform: translateY(-2px);
}
.st-hero__google {
  display: grid;
  place-items: center;
  width: 1.7rem;
  height: 1.7rem;
  margin: -0.35rem 0;
  border-radius: 50%;
  background: #fff;
}
.st-hero__google svg { display: block; }

/* Vorteile */
.st-hero__perks {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.4rem;
  margin: 1.8rem 0 0;
  padding: 0;
  list-style: none;
  color: rgba(255, 255, 255, 0.92);
  font-size: 0.9rem;
}
.st-hero__perks li {
  display: flex;
  align-items: center;
  gap: 0.45rem;
}
.st-hero__perks li::before {
  content: "";
  width: 1.15rem;
  height: 1.15rem;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 70% no-repeat;
}

/* ── Visual: 3D-Skill-Orbit ── */
.st-hero__visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  perspective: 1100px;
  animation: sth-zoom 1s 0.25s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}
@keyframes sth-zoom {
  from { opacity: 0; transform: scale(0.9); }
  to   { opacity: 1; transform: none; }
}

.st-orbit {
  --size: min(500px, 33vw);
  --tilt: 63deg;
  position: relative;
  width: var(--size);
  height: calc(var(--size) * 0.72);
  transform-style: preserve-3d;
  transform: rotateY(calc(var(--mx) * 10deg)) rotateX(calc(var(--my) * -8deg));
}

.st-orbit__ring {
  position: absolute;
  top: 50%;
  left: 50%;
  width: calc(var(--r) * 2);
  height: calc(var(--r) * 2);
  margin: calc(var(--r) * -1) 0 0 calc(var(--r) * -1);
  border: 1.5px dashed rgba(255, 255, 255, 0.38);
  border-radius: 50%;
  pointer-events: none;
  transform-style: preserve-3d;
  transform: rotateX(var(--tilt));
  animation: sth-spin var(--dur) linear infinite;
}
.st-orbit__ring--outer { --r: calc(var(--size) * 0.5); --dur: 50s; }
.st-orbit__ring--inner {
  --r: calc(var(--size) * 0.36);
  --dur: 24s;
  border-color: rgba(255, 255, 255, 0.2);
  animation-direction: reverse;
}
@keyframes sth-spin {
  from { transform: rotateX(var(--tilt)) rotateZ(0deg); }
  to   { transform: rotateX(var(--tilt)) rotateZ(360deg); }
}

.st-orbit__slot {
  position: absolute;
  top: 50%;
  left: 50%;
  transform-style: preserve-3d;
  transform: rotateZ(var(--a)) translateX(var(--r)) rotateZ(calc(var(--a) * -1));
}

/* Gegenrotation hebt Ring-Drehung + Neigung auf → Chips schauen immer nach vorne */
.st-chip {
  position: absolute;
  top: 0;
  left: 0;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.4rem 0.85rem 0.4rem 0.4rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.96);
  box-shadow: 0 10px 24px rgba(3, 30, 110, 0.28);
  color: var(--sth-ink);
  font-size: 0.85rem;
  font-weight: 700;
  white-space: nowrap;
  transform-origin: 0 0;
  transform: rotateZ(0deg) rotateX(calc(var(--tilt) * -1)) translate(-50%, -50%);
  animation: sth-counter var(--dur) linear infinite;
}
.st-orbit__ring--inner .st-chip { animation-direction: reverse; }

.st-orbit__dot {
  position: absolute;
  top: -5px;
  left: -5px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 12px 3px rgba(141, 246, 255, 0.9);
}
@keyframes sth-counter {
  from { transform: rotateZ(0deg) rotateX(calc(var(--tilt) * -1)) translate(-50%, -50%); }
  to   { transform: rotateZ(-360deg) rotateX(calc(var(--tilt) * -1)) translate(-50%, -50%); }
}

.st-chip b,
.st-chip i {
  display: grid;
  place-items: center;
  width: 1.7rem;
  height: 1.7rem;
  border-radius: 50%;
  font-style: normal;
  line-height: 1;
}
.st-chip b {
  background: linear-gradient(135deg, var(--sth-blue), var(--sth-teal));
  color: #fff;
  font-size: 0.66rem;
  letter-spacing: 0.02em;
}
.st-chip i {
  background: #eef5ff;
  font-size: 0.95rem;
}

/* Zentrale Glas-Karte mit wechselnden Tandem-Ideen */
.st-pair {
  position: absolute;
  top: 50%;
  left: 50%;
  width: min(270px, 62%);
  padding: 1rem 1.2rem 1.15rem;
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 1.4rem;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.3), rgba(255, 255, 255, 0.12));
  -webkit-backdrop-filter: blur(14px);
          backdrop-filter: blur(14px);
  box-shadow: 0 24px 60px rgba(3, 30, 110, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.45);
  text-align: center;
  transform: translate(-50%, -50%) translateZ(0);
  animation: sth-float 6s ease-in-out infinite;
}
@keyframes sth-float {
  0%, 100% { transform: translate(-50%, -50%) translateZ(0); }
  50%      { transform: translate(-50%, calc(-50% - 8px)) translateZ(0); }
}

.st-pair__label {
  display: inline-block;
  margin-bottom: 0.85rem;
  padding: 0.2rem 0.75rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.2);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.st-pair__people {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
}
.st-pair__person {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  min-width: 3.6rem;
}
.st-pair__avatar {
  display: grid;
  place-items: center;
  width: 3.1rem;
  height: 3.1rem;
  border-radius: 50%;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.55), 0 8px 18px rgba(3, 30, 110, 0.3);
  color: #fff;
  font-family: "Raleway", sans-serif;
  font-size: 1.2rem;
  font-weight: 700;
}
.st-pair__avatar--a { background: linear-gradient(135deg, #ff8a65, #f06292); }
.st-pair__avatar--b { background: linear-gradient(135deg, var(--sth-teal), var(--sth-blue)); }
.st-pair__name { font-size: 0.8rem; font-weight: 600; }

.st-pair__link {
  position: relative;
  flex: 1;
  max-width: 4.5rem;
  height: 2px;
  margin-bottom: 1.4rem;
  background: repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.75) 0 6px, transparent 6px 11px);
}
.st-pair__link i {
  position: absolute;
  top: 50%;
  width: 0.5rem;
  height: 0.5rem;
  margin-top: -0.25rem;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 10px #fff;
  animation: sth-dot 2s ease-in-out infinite;
}
.st-pair__link i:nth-child(2) { animation-name: sth-dot-back; animation-delay: -1s; }
@keyframes sth-dot {
  0%       { left: 0; opacity: 0; }
  15%, 85% { opacity: 1; }
  100%     { left: calc(100% - 0.5rem); opacity: 0; }
}
@keyframes sth-dot-back {
  0%       { left: calc(100% - 0.5rem); opacity: 0; }
  15%, 85% { opacity: 1; }
  100%     { left: 0; opacity: 0; }
}

.st-pair__skills {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.9rem;
  padding: 0.45rem 0.95rem;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 8px 18px rgba(3, 30, 110, 0.2);
  color: var(--sth-ink);
  font-size: 0.85rem;
  font-weight: 700;
}
.st-pair__skills svg { flex-shrink: 0; color: var(--sth-teal); }

.st-pair [data-pair] { display: inline-block; }
.st-pair__avatar[data-pair] { display: grid; }
.st-pair.is-swapping [data-pair] { animation: sth-swap 0.5s ease both; }
@keyframes sth-swap {
  0%   { opacity: 1; transform: none; }
  45%  { opacity: 0; transform: translateY(-6px); }
  55%  { opacity: 0; transform: translateY(6px); }
  100% { opacity: 1; transform: none; }
}

/* ── Scroll-Hinweis + Wellen ── */
.st-hero__scroll {
  position: absolute;
  bottom: 78px;
  left: 50%;
  z-index: 3;
  width: 26px;
  height: 42px;
  margin-left: -13px;
  border: 2px solid rgba(255, 255, 255, 0.7);
  border-radius: 14px;
  transition: border-color 0.2s;
}
.st-hero__scroll:hover { border-color: #fff; }
.st-hero__scroll span {
  position: absolute;
  top: 8px;
  left: 50%;
  width: 4px;
  height: 8px;
  margin-left: -2px;
  border-radius: 2px;
  background: #fff;
  animation: sth-scroll 1.8s ease-in-out infinite;
}
@keyframes sth-scroll {
  0%   { opacity: 0; transform: translateY(0); }
  30%  { opacity: 1; }
  100% { opacity: 0; transform: translateY(14px); }
}

.st-hero__waves {
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  z-index: 1;
  line-height: 0;
}

/* ── Zwangs-Dunkelmodus (Samsung Internet u. a.) ──
   Der Browser invertiert helle Flächen; dunkle Flächen + heller Text bleiben unverändert. */
.st-hero.is-forced-dark .st-hero__btn--primary {
  border: 2px solid #8ff6ff;
  background: #06205f;
  box-shadow: 0 0 0 4px rgba(143, 246, 255, 0.18), 0 12px 30px rgba(0, 0, 0, 0.35);
  color: #fff;
}
.st-hero.is-forced-dark .st-hero__btn--primary:hover,
.st-hero.is-forced-dark .st-hero__btn--primary:focus-visible { color: #fff; }
.st-hero.is-forced-dark .st-hero__btn--primary::after { display: none; }
.st-hero.is-forced-dark .st-hero__google { background: #06205f; box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.35); }
.st-hero.is-forced-dark .st-hero__title span {
  background: none;
  color: #8ff6ff;
  animation: none;
}
.st-hero.is-forced-dark .st-chip {
  border: 1px solid rgba(143, 246, 255, 0.45);
  background: #06205f;
  color: #fff;
}
.st-hero.is-forced-dark .st-chip i { background: #0b3a9e; }
.st-hero.is-forced-dark .st-pair__skills {
  border: 1px solid rgba(143, 246, 255, 0.45);
  background: #06205f;
  color: #fff;
}
.st-hero.is-forced-dark .st-pair__skills svg { color: #8ff6ff; }

/* ── Responsive ── */
@media (max-height: 980px) {
  .st-hero__scroll { display: none; }
}

@media (max-width: 991.98px) {
  .st-hero {
    min-height: 0;
    padding: 110px 0 130px;
    text-align: center;
  }
  .st-hero__inner { grid-template-columns: 1fr; }
  .st-hero__copy {
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  .st-hero__lead { margin-right: auto; margin-left: auto; }
  .st-hero__ctas,
  .st-hero__perks { justify-content: center; }
  .st-orbit { --size: min(440px, 74vw); }
  .st-hero__scroll { display: none; }
}

@media (max-width: 575.98px) {
  .st-hero__badge { font-size: 0.75rem; }
  .st-hero__title { font-size: 1.9rem; }
  .st-hero__ctas { width: 100%; }
  .st-hero__btn { justify-content: center; width: 100%; }
  /* flat: Karte liegt per DOM-Reihenfolge immer vor den Chips und bleibt lesbar */
  .st-orbit { --size: 66vw; --tilt: 45deg; height: calc(var(--size) * 0.9); transform-style: flat; }
  /* Nur Icons, damit der Orbit auf schmalen Screens luftig bleibt */
  .st-chip { gap: 0; padding: 0.3rem; font-size: 0; }
  .st-chip b,
  .st-chip i { width: 1.9rem; height: 1.9rem; }
  .st-pair { width: min(290px, 86%); padding: 0.8rem 0.6rem 0.9rem; }
  .st-pair__label { display: none; }
  /* Lange Skill-Namen (z. B. "Programmieren ⇄ Fotografie") müssen in die schmale Karte passen */
  .st-pair__skills {
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.1rem 0.35rem;
    max-width: 100%;
    margin-top: 0.6rem;
    padding: 0.35rem 0.65rem;
    font-size: 0.72rem;
  }
  .st-pair__skills svg { width: 13px; height: 13px; }
  .st-pair__avatar { width: 2.6rem; height: 2.6rem; font-size: 1rem; }
}
