/*
 * Kundenprojekte auf "Ueber uns" - Rail Operations Dossier.
 * Keine Kartenwand: grosse dokumentarische Bilder, fortlaufender Index und
 * eine offene Projektstrecke. Medien sind im Grundzustand immer sichtbar.
 */

.rt-projekte {
  --rt-pj-red: #e4002b;
  --rt-pj-red-deep: #b40023;
  --rt-pj-ink: #09111b;
  --rt-pj-muted: #4f5b68;
  --rt-pj-paper: #f3f2ee;
  --rt-project-route-progress: 100%;
  position: relative;
  isolation: isolate;
  overflow: hidden;
  color: var(--rt-pj-ink);
  background:
    radial-gradient(62% 48% at 100% 0, rgba(228, 0, 43, .08), transparent 70%),
    linear-gradient(180deg, #fbfaf7 0%, var(--rt-pj-paper) 54%, #ecece8 100%);
  border-top: 1px solid rgba(9, 17, 27, .12);
}

.rt-projekte::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  opacity: .58;
  background-image:
    linear-gradient(rgba(9, 17, 27, .035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(9, 17, 27, .035) 1px, transparent 1px);
  background-position: var(--rt-segment-raster, 0) var(--rt-segment-raster, 0);
  background-size: 76px 76px;
  -webkit-mask-image: linear-gradient(145deg, #000 0, rgba(0, 0, 0, .72) 42%, transparent 78%);
  mask-image: linear-gradient(145deg, #000 0, rgba(0, 0, 0, .72) 42%, transparent 78%);
  pointer-events: none;
}

.rt-projekte__inner {
  width: min(100%, 1500px);
  margin: 0 auto;
  padding: clamp(74px, 7vw, 116px) max(22px, 7vw) clamp(86px, 8vw, 132px);
}

.rt-projekte__intro {
  display: grid;
  grid-template-columns: minmax(300px, .82fr) minmax(470px, 1.18fr);
  align-items: center;
  gap: clamp(42px, 7vw, 112px);
}

.rt-projekte__head {
  position: relative;
  z-index: 2;
  max-width: 650px;
}

.rt-projekte .rt-projekte__kicker {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0 0 20px;
  color: var(--rt-pj-red-deep);
  font-size: 10.5px;
  font-weight: 850;
  line-height: 1.2;
  letter-spacing: .19em;
  text-transform: uppercase;
}

.rt-projekte__kicker > span {
  position: relative;
  width: 38px;
  height: 2px;
  flex: 0 0 auto;
  background: var(--rt-pj-red);
}

.rt-projekte__kicker > span::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 0;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--rt-pj-red);
  box-shadow: 0 0 0 5px rgba(228, 0, 43, .1);
  transform: translateY(-50%);
}

.rt-projekte h2 {
  max-width: 660px;
  margin: 0;
  color: #070d15;
  font-size: clamp(38px, 4.35vw, 68px);
  font-weight: 650;
  line-height: .96;
  letter-spacing: -.056em;
  text-wrap: balance;
}

.rt-projekte .rt-projekte__lead {
  max-width: 610px;
  margin: 28px 0 0;
  color: var(--rt-pj-muted);
  font-size: clamp(14px, 1.15vw, 16.5px);
  line-height: 1.76;
}

.rt-projekte__hero,
.rt-projekte__feldbild,
.rt-projekte__abschlussbild {
  --rt-project-media-sweep: -135%;
  position: relative;
  margin: 0;
  overflow: hidden;
  opacity: 1;
  visibility: visible;
  background: #121a24;
}

.rt-projekte__hero::before,
.rt-projekte__feldbild::before,
.rt-projekte__abschlussbild::before {
  content: "";
  position: absolute;
  z-index: 2;
  inset: 0 auto 0 -22%;
  width: 40%;
  opacity: .5;
  background: linear-gradient(90deg, transparent, rgba(228, 0, 43, .2), rgba(255, 255, 255, .12), transparent);
  transform: translateX(var(--rt-project-media-sweep));
  pointer-events: none;
}

.rt-projekte__hero img,
.rt-projekte__feldbild img,
.rt-projekte__abschlussbild img {
  display: block;
  width: 100%;
  height: 100%;
  opacity: 1;
  visibility: visible;
  object-fit: cover;
}

.rt-projekte__hero {
  height: clamp(430px, 49vw, 630px);
  border: 1px solid rgba(9, 17, 27, .13);
  box-shadow: 0 34px 86px rgba(17, 24, 39, .18);
  clip-path: polygon(0 0, 100% 0, 100% 93%, 91% 100%, 0 100%);
}

.rt-projekte__hero::after {
  content: "RT / 04";
  position: absolute;
  z-index: 2;
  right: 0;
  bottom: 0;
  padding: 12px 18px;
  color: rgba(255, 255, 255, .9);
  background: rgba(7, 11, 17, .78);
  font: 700 9px/1.2 "Space Mono", monospace;
  letter-spacing: .15em;
}

.rt-projekte__hero img {
  object-position: 48% 48%;
}

/* Einsatzfelder: fotografischer Anker links, fortlaufender Index rechts. */
.rt-projekte__felder {
  display: grid;
  grid-template-columns: minmax(430px, 1.08fr) minmax(350px, .92fr);
  align-items: start;
  gap: clamp(46px, 7vw, 112px);
  margin-top: clamp(90px, 9vw, 142px);
}

.rt-projekte__feldbild {
  position: sticky;
  top: 104px;
  height: min(72vh, 760px);
  min-height: 540px;
  box-shadow: 0 30px 76px rgba(17, 24, 39, .17);
}

.rt-projekte__feldbild img {
  object-position: 51% 50%;
}

.rt-projekte h3.rt-projekte__block {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 0 0 20px;
  color: #111923;
  font-size: 10.5px;
  font-weight: 850;
  line-height: 1.3;
  letter-spacing: .18em;
  text-transform: uppercase;
}

.rt-projekte h3.rt-projekte__block::after {
  content: "";
  height: 1px;
  flex: 1 1 auto;
  background: linear-gradient(90deg, rgba(9, 17, 27, .25), transparent);
}

.rt-projekte__bereiche {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: rt-pj-area;
  border-top: 1px solid rgba(9, 17, 27, .18);
}

.rt-projekte__bereich {
  position: relative;
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  column-gap: 18px;
  padding: 24px 0 26px;
  border-bottom: 1px solid rgba(9, 17, 27, .16);
  counter-increment: rt-pj-area;
}

.rt-projekte__bereich::before {
  content: "0" counter(rt-pj-area);
  grid-column: 1;
  grid-row: 1 / span 2;
  color: var(--rt-pj-red-deep);
  font: 800 12px/1 "Space Mono", monospace;
  letter-spacing: .08em;
  transform: translateY(5px);
}

.rt-projekte__bereich::after {
  content: "";
  position: absolute;
  top: -1px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--rt-pj-red);
  transition: width .42s cubic-bezier(.22, 1, .36, 1);
}

.rt-projekte__bereich:hover::after {
  width: 100%;
}

.rt-projekte__bereich h4 {
  grid-column: 2;
  margin: 0;
  color: #0b121b;
  font-size: clamp(18px, 1.6vw, 23px);
  font-weight: 680;
  line-height: 1.14;
  letter-spacing: -.025em;
}

.rt-projekte .rt-projekte__bereich p {
  grid-column: 2;
  max-width: 660px;
  margin: 10px 0 0;
  color: #58636f;
  font-size: 13.5px;
  line-height: 1.7;
}

/* Offene Projektstrecke statt dunkler Kartenbox. */
.rt-projekte .rt-projekte__process-head {
  margin-top: clamp(92px, 10vw, 150px);
}

.rt-projekte__ablauf {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 32px 0 0;
  padding: 30px 0 0;
  list-style: none;
  counter-reset: rt-pj-phase;
  border-top: 1px solid rgba(9, 17, 27, .19);
}

.rt-projekte__ablauf::before,
.rt-projekte__ablauf::after {
  content: "";
  position: absolute;
  top: -2px;
  left: 0;
  height: 3px;
}

.rt-projekte__ablauf::before {
  width: 100%;
  background: rgba(228, 0, 43, .1);
}

.rt-projekte__ablauf::after {
  width: var(--rt-project-route-progress);
  max-width: 100%;
  background: linear-gradient(90deg, #a90020, var(--rt-pj-red), #ff5c77);
  box-shadow: 0 0 22px rgba(228, 0, 43, .28);
}

.rt-projekte__phase {
  position: relative;
  min-height: 210px;
  padding: 6px clamp(24px, 3vw, 44px) 18px 0;
  counter-increment: rt-pj-phase;
}

.rt-projekte__phase + .rt-projekte__phase {
  padding-left: clamp(22px, 2.5vw, 38px);
  border-left: 1px solid rgba(9, 17, 27, .13);
}

.rt-projekte__phase::before {
  content: "0" counter(rt-pj-phase);
  display: block;
  margin-bottom: 34px;
  color: var(--rt-pj-red-deep);
  font: 800 12px/1 "Space Mono", monospace;
  letter-spacing: .1em;
}

.rt-projekte__phase::after {
  content: "";
  position: absolute;
  top: -36px;
  left: 0;
  width: 9px;
  height: 9px;
  border: 2px solid var(--rt-pj-paper);
  border-radius: 50%;
  background: var(--rt-pj-red);
  box-shadow: 0 0 0 5px rgba(228, 0, 43, .12);
}

.rt-projekte__phase + .rt-projekte__phase::after {
  left: clamp(22px, 2.5vw, 38px);
}

.rt-projekte__phase h4 {
  margin: 0;
  color: #0a111a;
  font-size: clamp(18px, 1.55vw, 23px);
  font-weight: 680;
  line-height: 1.15;
  letter-spacing: -.022em;
}

.rt-projekte .rt-projekte__phase p {
  max-width: 270px;
  margin: 12px 0 0;
  color: #5d6773;
  font-size: 13px;
  line-height: 1.66;
}

/* Abschluss als Bildbuehne, nicht als sichtbare Karte. */
.rt-projekte__abschluss {
  position: relative;
  display: grid;
  grid-template-columns: 1fr minmax(360px, .78fr);
  min-height: clamp(520px, 54vw, 700px);
  margin-top: clamp(94px, 10vw, 154px);
  overflow: hidden;
  background: #091019;
  box-shadow: 0 38px 88px rgba(17, 24, 39, .2);
}

.rt-projekte__abschlussbild {
  position: absolute;
  inset: 0;
}

.rt-projekte__abschlussbild::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(5, 9, 14, .08) 0, rgba(5, 9, 14, .18) 42%, rgba(5, 9, 14, .94) 76%, #05090e 100%);
  pointer-events: none;
}

.rt-projekte__abschlussbild img {
  object-position: 42% 50%;
}

.rt-projekte__abschlusscopy {
  position: relative;
  z-index: 3;
  grid-column: 2;
  align-self: center;
  padding: clamp(44px, 6vw, 82px) clamp(32px, 5vw, 74px) clamp(44px, 6vw, 82px) 18px;
  color: #f6f7f9;
}

.rt-projekte__abschlusscopy h3.rt-projekte__block {
  color: #fff;
}

.rt-projekte__abschlusscopy h3.rt-projekte__block::after {
  background: linear-gradient(90deg, rgba(255, 255, 255, .28), transparent);
}

.rt-projekte__staerken {
  margin: 26px 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid rgba(255, 255, 255, .14);
}

.rt-projekte__staerken li {
  position: relative;
  padding: 15px 0 15px 28px;
  color: #c4ccd5;
  border-bottom: 1px solid rgba(255, 255, 255, .1);
  font-size: 13.5px;
  line-height: 1.5;
}

.rt-projekte__staerken li::before {
  content: "";
  position: absolute;
  top: 21px;
  left: 2px;
  width: 11px;
  height: 2px;
  background: var(--rt-pj-red);
  box-shadow: 6px 0 12px rgba(228, 0, 43, .48);
}

.rt-projekte__abschlussaktion {
  margin-top: 28px;
}

.rt-projekte .rt-projekte__abschlusstext {
  margin: 0;
  color: #aab4c0;
  font-size: 13.5px;
  line-height: 1.65;
}

.rt-projekte__cta {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-width: min(100%, 290px);
  margin-top: 20px;
  padding: 15px 17px 15px 19px;
  color: #fff;
  background: var(--rt-pj-red);
  border: 1px solid var(--rt-pj-red);
  font-size: 10.5px;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: .12em;
  text-decoration: none;
  text-transform: uppercase;
  transition: background-color .25s ease, transform .25s ease;
}

.rt-projekte__cta svg {
  width: 21px;
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.55;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform .25s ease;
}

.rt-projekte__cta:hover,
.rt-projekte__cta:focus-visible {
  color: #fff;
  background: #c70026;
  transform: translateY(-2px);
}

.rt-projekte__cta:hover svg,
.rt-projekte__cta:focus-visible svg {
  transform: translateX(4px);
}

.rt-projekte__cta:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
}

@media (max-width: 1040px) {
  .rt-projekte__intro {
    grid-template-columns: .9fr 1.1fr;
    gap: 42px;
  }

  .rt-projekte__hero {
    height: 520px;
  }

  .rt-projekte__felder {
    grid-template-columns: minmax(350px, .9fr) minmax(330px, 1.1fr);
    gap: 44px;
  }

  .rt-projekte__feldbild {
    height: min(65vh, 650px);
    min-height: 500px;
  }

  .rt-projekte__ablauf {
    grid-template-columns: 1fr 1fr;
    row-gap: 38px;
  }

  .rt-projekte__phase:nth-child(3) {
    padding-left: 0;
    border-left: 0;
  }

  .rt-projekte__phase:nth-child(3)::after {
    left: 0;
  }

  .rt-projekte__abschluss {
    grid-template-columns: 1fr minmax(340px, .9fr);
  }
}

@media (max-width: 860px) {
  .rt-projekte__inner {
    padding-inline: 22px;
  }

  .rt-projekte__intro,
  .rt-projekte__felder {
    grid-template-columns: 1fr;
  }

  .rt-projekte__intro {
    gap: 36px;
  }

  .rt-projekte__hero {
    height: min(108vw, 590px);
  }

  .rt-projekte__felder {
    gap: 42px;
    margin-top: 78px;
  }

  .rt-projekte__feldbild {
    position: relative;
    top: auto;
    height: min(112vw, 630px);
    min-height: 420px;
  }

  .rt-projekte__abschluss {
    display: block;
    min-height: 690px;
  }

  .rt-projekte__abschlussbild::after {
    background: linear-gradient(180deg, rgba(5, 9, 14, .04) 0, rgba(5, 9, 14, .15) 34%, rgba(5, 9, 14, .94) 68%, #05090e 100%);
  }

  .rt-projekte__abschlusscopy {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    padding: 42px 24px 34px;
  }
}

@media (max-width: 560px) {
  .rt-projekte__inner {
    padding-top: 66px;
    padding-bottom: 76px;
  }

  .rt-projekte h2 {
    font-size: clamp(37px, 12vw, 50px);
  }

  .rt-projekte__hero {
    height: 470px;
    clip-path: polygon(0 0, 100% 0, 100% 95%, 88% 100%, 0 100%);
  }

  .rt-projekte__hero::after {
    max-width: 76%;
    padding: 10px 12px;
    font-size: 8px;
  }

  .rt-projekte__feldbild {
    height: 485px;
    min-height: 0;
  }

  .rt-projekte__bereich {
    grid-template-columns: 34px minmax(0, 1fr);
    column-gap: 12px;
    padding-block: 22px;
  }

  .rt-projekte__ablauf {
    display: block;
    margin-top: 24px;
    padding: 0 0 0 25px;
    border-top: 0;
    border-left: 1px solid rgba(9, 17, 27, .18);
  }

  .rt-projekte__ablauf::before,
  .rt-projekte__ablauf::after {
    top: 0;
    left: -2px;
    width: 3px;
  }

  .rt-projekte__ablauf::before {
    height: 100%;
  }

  .rt-projekte__ablauf::after {
    width: 3px;
    height: var(--rt-project-route-progress);
    max-height: 100%;
  }

  .rt-projekte__phase,
  .rt-projekte__phase + .rt-projekte__phase,
  .rt-projekte__phase:nth-child(3) {
    min-height: 0;
    padding: 6px 0 34px 18px;
    border-left: 0;
  }

  .rt-projekte__phase::before {
    margin-bottom: 13px;
  }

  .rt-projekte__phase::after,
  .rt-projekte__phase + .rt-projekte__phase::after,
  .rt-projekte__phase:nth-child(3)::after {
    top: 8px;
    left: -31px;
  }

  .rt-projekte__abschluss {
    min-height: 720px;
    margin-top: 82px;
  }

  .rt-projekte__abschlussbild img {
    object-position: 38% 50%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .rt-projekte,
  .rt-projekte__ablauf {
    --rt-project-route-progress: 100% !important;
  }

  .rt-projekte__hero,
  .rt-projekte__feldbild,
  .rt-projekte__abschlussbild,
  .rt-projekte__hero img,
  .rt-projekte__feldbild img,
  .rt-projekte__abschlussbild img {
    transform: none !important;
  }

  .rt-projekte__cta,
  .rt-projekte__cta svg,
  .rt-projekte__bereich::after {
    transition: none;
  }
}
