/* ==========================================================================
   Stellenangebote – Ausgabe

   Grundsatz wie im Child-Theme: KEINE font-family. Schriftarten kommen
   ausschliesslich aus Uncode (Theme Options). Hier stehen nur Groesse,
   Laufweite, Abstaende und Linien.

   Farben laufen ueber currentColor (passt sich hellen und dunklen Sektionen
   von selbst an) und ueber die Tokens der Palette: --pgs-rule, --pgs-moss.
   Trennung durch Haarlinien und Weissraum, nie durch Kaesten und Schatten.
   ========================================================================== */

.tsa-jobs,
.tsa-job-single {
  --tsa-rule:   var(--pgs-rule, #C6CDBC);
  --tsa-accent: var(--pgs-moss, #435331);
  --tsa-tint:   rgba(67, 83, 49, .07);
  --tsa-radius: 8px;
  --tsa-sticky-top: 140px;
  --tsa-ease:   cubic-bezier(.22, .61, .36, 1);

  color: inherit;
}

.tsa-jobs *,
.tsa-jobs *::before,
.tsa-jobs *::after,
.tsa-job-single *,
.tsa-job-single *::before,
.tsa-job-single *::after { box-sizing: border-box; }

.tsa-sr {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/* --------------------------------------------------------------- Kopfzeile */

.tsa-jobs__head { margin-bottom: 42px; }

/* Kleine Zeile darueber: nur Laufweite und Groesse, Schrift aus dem Theme */
.tsa-jobs__eyebrow {
  font-size: .78em;
  letter-spacing: .16em;
  text-transform: uppercase;
  opacity: .62;
  margin: 0 0 .9em;
}

/* Die Ueberschrift bleibt bewusst ungestylt – sie erbt h2 aus dem Theme */
.tsa-jobs__heading { margin: 0; }

/* ------------------------------------------------------------------- Liste */

/* Uncode setzt Listen im Textkontext auf disc mit Einzug – hier bewusst
   mit hoeherer Spezifitaet zurueckgenommen. */
.tsa-jobs .tsa-jobs__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.tsa-jobs .tsa-jobs__list > li::before,
.tsa-jobs .tsa-jobs__list > li::marker { content: none; }

.tsa-job {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px 48px;
  padding: 30px 0;
  border-bottom: 1px solid var(--tsa-rule);
}

.tsa-jobs--liste .tsa-jobs__list > .tsa-job:first-child {
  border-top: 1px solid var(--tsa-rule);
}

.tsa-job__body { flex: 1 1 24rem; }

/* Erbt h3 aus dem Theme, nur die Groesse wird auf Listenmass gebracht */
.tsa-job__title {
  font-size: 1.35em;
  line-height: 1.25;
  margin: 0 0 .45em;
}

.tsa-jobs .tsa-job__title a {
  color: inherit;
  text-decoration: none;
  background-image: linear-gradient(currentColor, currentColor);
  background-size: 0 1px;
  background-position: 0 100%;
  background-repeat: no-repeat;
  transition: background-size .45s var(--tsa-ease);
}

.tsa-jobs .tsa-job:hover .tsa-job__title a,
.tsa-jobs .tsa-job__title a:focus-visible { background-size: 100% 1px; }

/* Eckdaten – klein, einzeilig, durch schmale Punkte getrennt */

.tsa-jobs .tsa-job__meta {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  margin: 0 0 .55em;
  padding: 0;
  font-size: .8em;
  letter-spacing: .1em;
  text-transform: uppercase;
  opacity: .62;
}

.tsa-jobs .tsa-job__meta-item {
  margin: 0;
  padding: 0;
  display: inline;
}

.tsa-jobs .tsa-job__meta-item::marker { content: none; }

.tsa-jobs .tsa-job__meta-item + .tsa-job__meta-item::before {
  content: "·";
  margin: 0 .7em;
  opacity: .6;
}

.tsa-job__teaser {
  margin: 0;
  max-width: 62ch;
}

/* Link – Textlink mit gezeichnetem Pfeil, kein Kasten */

.tsa-job__more {
  flex: 0 0 auto;
  margin: 0;
}

.tsa-jobs .tsa-job__link {
  font-size: .88em;
  font-weight: 600;
  letter-spacing: .04em;
  color: var(--tsa-accent);
  text-decoration: none;
  white-space: nowrap;
}

.tsa-jobs .tsa-job__link::after {
  content: "→";
  display: inline-block;
  margin-left: .55em;
  transition: transform .45s var(--tsa-ease);
}

.tsa-jobs .tsa-job:hover .tsa-job__link::after { transform: translateX(4px); }

/* ------------------------------------------------------------------ Raster */

.tsa-jobs--raster .tsa-jobs__list {
  display: grid;
  grid-template-columns: repeat(var(--tsa-cols, 2), minmax(0, 1fr));
  column-gap: 48px;
  border-top: 1px solid var(--tsa-rule);
}

.tsa-jobs--raster .tsa-job {
  display: block;
  padding: 28px 0;
}

.tsa-jobs--raster .tsa-job__more { margin-top: 1em; }

/* --------------------------------------------------------- Leerer Zustand */

.tsa-empty {
  margin: 0;
  font-size: .82em;
  letter-spacing: .1em;
  text-transform: uppercase;
  opacity: .62;
  padding: 26px 0;
  border-top: 1px solid var(--tsa-rule);
}

/* -------------------------------------------------------------- Detailseite */

/* Erbt h1 aus dem Theme – hier nur der Abstand zu den Eckdaten */
.tsa-job-single__title { margin: 0 0 .7em; }

/* Eckdaten als Piktogramm-Kacheln – Raster und Form kommen aus dem Theme
   (.data-fields / .data-field-icon--rounded), hier nur Flaeche und Abstaende. */
.tsa-facts { margin: 0 0 2.8rem; }

.tsa-job-single .data-field-icon--rounded {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--tsa-tint);
  color: var(--tsa-accent);
}

.tsa-job-single .data-field-label {
  opacity: .55;
  font-size: .82em;
}

.tsa-facts .data-field { min-width: 0; }

/* Uncode setzt fuer zwei Spalten auf dem Telefon repeat(21, 1fr) – ein
   Tippfehler im Theme, hier gerade gerueckt. */
@media (max-width: 569px) {
  .tsa-job-single .data-fields.data-fields--columns-mobile-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Zwischenueberschriften erben h3 aus dem Theme */
.tsa-job-single__description h3 {
  font-size: 1.25em;
  margin: 2.2rem 0 .7rem;
}

.tsa-job-single .tsa-job-single__description ul {
  margin: 0 0 1.2rem;
  padding: 0;
  list-style: none;
}

.tsa-job-single .tsa-job-single__description li::marker { content: none; }

.tsa-job-single .tsa-job-single__description li {
  position: relative;
  padding-left: 1.4em;
  margin-bottom: .45em;
}

.tsa-job-single .tsa-job-single__description li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .72em;
  width: .7em;
  height: 1px;
  background: var(--tsa-accent);
  opacity: .8;
}

/* --------------------------------------------------- Spalten der Detailseite */

.tsa-single__columns {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(260px, 1fr);
  gap: 56px;
}

/* Kein align-items: start – die Spalte muss sich ueber die ganze Zeilenhoehe
   strecken, sonst hat der Kasten darin keinen Weg zum Mitwandern. */

.tsa-single__columns--einspaltig { display: block; }

/* Rasterkinder haben eine Mindestbreite in Hoehe ihres min-content – das hier
   nimmt sie zurueck, damit breiter Inhalt nicht das Layout aufdrueckt. */
.tsa-single__main,
.tsa-single__aside { min-width: 0; }

/* -------------------------------------------------------- Bewerbungsblock */

/* Wie bei den Fahrzeugen eine abgesetzte Flaeche – die einzige Stelle, an der
   bewusst kein Haarlinien-Prinzip gilt, damit der Kasten traegt. Farbe kommt
   ueber .style-color-pgsgrnd-bg aus der Palette. */
.tsa-contact {
  position: sticky;
  top: var(--tsa-sticky-top, 140px);
  padding: 34px 30px;
  border-radius: var(--tsa-radius);
}

.tsa-contact__title { margin: 0 0 .6em; font-size: 1.15em; }

.tsa-contact__intro {
  margin: 0 0 1.4em;
  font-size: .9em;
  opacity: .75;
}

.tsa-job-single .tsa-checklist {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: .9em;
}

.tsa-job-single .tsa-checklist li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 0 0 .55em;
  padding: 0;
}

.tsa-job-single .tsa-checklist li::marker { content: none; }

.tsa-checklist .tsa-icon {
  flex: 0 0 auto;
  margin-top: .28em;
  color: var(--tsa-accent);
}

.tsa-contact hr.separator-extra {
  margin: 22px 0;
  border: 0;
  border-top: 1px solid var(--tsa-rule);
}

.tsa-contact__name { margin: 0 0 .2em; font-weight: 600; }

.tsa-contact__role {
  margin: 0 0 .7em;
  font-size: .82em;
  opacity: .62;
}

.tsa-contact__phone { margin: 0 0 1.4em; font-size: 1.05em; }

.tsa-job-single .tsa-contact__phone a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid var(--tsa-rule);
}

/* Die Schaltflaeche traegt die Theme-Klassen, hier nur die volle Breite */
.tsa-job-single .tsa-contact__btn {
  display: block;
  width: 100%;
  text-align: center;
}

.tsa-job-single .tsa-contact__mail {
  display: block;
  margin-top: 14px;
  font-size: .76em;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: inherit;
  opacity: .55;
  text-decoration: none;
  word-break: break-word;
}

.tsa-job-single .tsa-contact__mail:hover { opacity: .85; }

.tsa-notice--expired {
  margin: 0 0 2rem;
  padding: 0 0 1.2rem;
  border-bottom: 1px solid var(--tsa-rule);
  font-size: .78em;
  letter-spacing: .1em;
  text-transform: uppercase;
  opacity: .75;
}

/* ------------------------------------- Der Bewerbungsblock bleibt stehen */

/* Uncode setzt .box-wrapper auf overflow: hidden. Damit wird der Wrapper zum
   Scroll-Container fuer alles darin – ein sticky-Element richtet sich dann
   nach ihm statt nach dem Fenster und klebt nie.

   Einfach auf visible stellen geht nicht: das hidden verdeckt rund 3 px
   Ueberhang der Theme-Container, sonst bekommt die Seite einen waagerechten
   Rollbalken. "clip" klippt genauso, erzeugt aber keinen Scroll-Container –
   damit stimmt beides. Versteht ein Browser clip nicht, bleibt es bei hidden:
   der Kasten scrollt dann einfach mit, nichts geht kaputt.

   Gleiche Loesung wie auf den Fahrzeugseiten. Der Griff bleibt so eng wie
   moeglich: nur auf Stellenseiten und nur dort, wo es die zweispaltige
   Ansicht ueberhaupt gibt. */
@media (min-width: 1200px) {
  body.single-stellenangebot .box-wrapper { overflow: clip; }
}

/* ------------------------------------ Vor-/Zurueck-Navigation des Themes */

/* Uncode legt die Navigation auf eine graue Flaeche (.row-navigation-light).
   Auf den Stellenseiten stattdessen eine Haarlinie – wie im Rest der Seite. */
body.single-stellenangebot .row-container.row-navigation {
  background: transparent;
  border-top: 1px solid var(--pgs-rule, #C6CDBC);
}

/* ------------------------------------------- Dunkler Sektionshintergrund */

/* Auf dunklem Grund traegt die Textfarbe der Sektion: Linien und Akzent
   leiten sich davon ab, damit nichts gegen das Theme laeuft. */
.style-dark .tsa-jobs,
.style-dark .tsa-job-single,
.tsa-jobs--dark {
  --tsa-rule:   rgba(255, 255, 255, .18);
  --tsa-accent: currentColor;
}

/* Der Kasten bringt seine eigene helle Flaeche aus der Palette mit und bleibt
   deshalb auch in einer dunklen Sektion hell – Text und Linien darin ebenso. */
.style-dark .tsa-contact,
.tsa-jobs--dark .tsa-contact {
  --tsa-rule:   var(--pgs-rule, #C6CDBC);
  --tsa-accent: var(--pgs-moss, #435331);

  color: var(--pgs-ink, #171A14);
}

/* --------------------------------------------------------------- Responsive */

@media (max-width: 1199px) {
  /* Zu schmal, um mitzuwandern – der Kasten laeuft ab hier normal mit. */
  .tsa-contact { position: static; }
}

@media (max-width: 959px) {
  .tsa-single__columns {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .tsa-contact { padding: 28px 22px; }

  .tsa-job {
    display: block;
    padding: 24px 0;
  }

  .tsa-job__more { margin-top: .9em; }

  .tsa-jobs--raster .tsa-jobs__list { grid-template-columns: 1fr; }

}

@media (prefers-reduced-motion: reduce) {
  .tsa-jobs .tsa-job__title a,
  .tsa-jobs .tsa-job__link::after,
  .tsa-job-single .tsa-contact__btn { transition: none; }

  .tsa-jobs .tsa-job:hover .tsa-job__link::after { transform: none; }
}
