/* Leistungsseiten (build_seo_services.py, build_leistungen.py): nur, was die Basis nicht hat */

/* Einstieg: Text links, Leistungsrahmen mit 3D-Objekt rechts */
.leistung-kopf {
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr);
  align-items: stretch;
}

.leistung-kopf h1 {
  font-size: clamp(2rem, 1.35rem + 2.4vw, 3.25rem);
  letter-spacing: -0.035em;
  line-height: 1.08;
}

.brotkrumen {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
  color: var(--ink-3);
  font-size: 0.9375rem;
}

.brotkrumen a {
  color: var(--ink-2);
}

.leistung-notiz {
  display: flex;
  flex-direction: column;
  padding: clamp(22px, 3vw, 32px);
  border-radius: var(--r-lg);
  background: var(--tint);
}

.leistung-bild {
  align-self: center;
  margin-bottom: 18px;
}

.leistung-bild.ist-objekt {
  width: clamp(150px, 15vw, 210px);
}

.leistung-bild.ist-icon {
  width: clamp(110px, 10vw, 140px);
}

.leistung-notiz > strong {
  font-size: 1.125rem;
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.35;
}

.leistung-notiz dl {
  display: grid;
  gap: 10px;
  margin: 18px 0 0;
  padding-top: 16px;
  border-top: 1px solid oklch(45% 0.08 165 / 0.18);
}

.leistung-notiz dl > div {
  display: grid;
  grid-template-columns: 8.5rem minmax(0, 1fr);
  gap: 12px;
  font-size: 0.9375rem;
}

.leistung-notiz dt {
  color: var(--ink-2);
}

.leistung-notiz dd {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-weight: 550;
}

.leistung-notiz dd img {
  width: 26px;
  height: 26px;
  border-radius: 50%;
}

.leistung-notiz-preis {
  margin-top: 14px;
  color: var(--ink-2);
  font-size: 0.875rem;
}

.leistung-sprung {
  margin-top: 20px;
}

/* Übersicht /leistungen/: Einstieg ohne Seitenspalte, zwei Wege als Karten */
.kopf-karte.einspaltig {
  grid-template-columns: minmax(0, 1fr);
}

.weg {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.weg-bild {
  width: clamp(140px, 14vw, 190px);
  margin: -8px 0 8px -10px;
}

.weg h2 {
  font-size: clamp(1.875rem, 1.4rem + 1.4vw, 2.5rem);
}

.weg .weg-zeile {
  margin-top: 4px;
  color: var(--green-ink);
  font-weight: 550;
}

.weg-liste {
  display: grid;
  width: 100%;
  margin: 22px 0 28px;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
}

.weg-liste a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 2px;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  font-weight: 550;
  text-decoration: none;
}

.weg-liste a:hover {
  color: var(--green-ink);
}

.weg-liste .icon {
  transition: transform 0.25s var(--ease);
}

.weg-liste a:hover .icon {
  transform: translateX(3px);
}

.weg .btn {
  margin-top: auto;
}

/* Zwei Spalten in einer Karte: Überschrift links, Inhalt rechts */
.zwei-spalten {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: clamp(20px, 4vw, 64px);
  align-items: start;
  padding: clamp(28px, 4vw, 52px);
}

.zwei-spalten h2 {
  font-size: clamp(1.75rem, 1.3rem + 1.4vw, 2.375rem);
}

.zwei-spalten .haken-liste {
  margin-top: 0;
}

.begriffe p {
  margin-top: 14px;
  color: var(--ink-2);
}

.begriffe .chips li {
  background: var(--surface);
}

.begriffe .link-zeile {
  margin-top: 20px;
}

/* Beispielablauf: Kette aus Schritten, die Freigabe hervorgehoben */
.ablaufkarte {
  margin: 0;
}

.ablauf-kette {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: knoten;
}

.ablauf-kette li {
  position: relative;
  display: grid;
  align-content: start;
  gap: 6px;
  padding: 18px 18px 20px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  background: var(--bg);
  counter-increment: knoten;
}

.ablauf-kette li::before {
  content: counter(knoten);
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  margin-bottom: 6px;
  border-radius: 50%;
  background: var(--surface);
  color: var(--green-ink);
  font-size: 0.8125rem;
  font-weight: 600;
  box-shadow: 0 0 0 1px var(--line);
}

.ablauf-kette li.ist-freigabe {
  border-color: var(--green);
  background: var(--tint);
}

.ablauf-kette li.ist-freigabe::before {
  background: var(--green);
  color: oklch(99% 0 0);
  box-shadow: none;
}

.ablauf-kette strong {
  font-weight: 600;
}

.ablauf-kette span {
  color: var(--ink-2);
  font-size: 0.9375rem;
  line-height: 1.45;
}

.ablauf-ausnahme {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  gap: 16px;
  align-items: center;
  margin-top: 16px;
  padding: 18px 20px;
  border: 1.5px dashed var(--line-strong);
  border-radius: var(--r-md);
}

.ablauf-ausnahme img {
  width: 56px;
  height: 56px;
}

.ablauf-ausnahme p {
  color: var(--ink-2);
}

.ablauf-ausnahme strong {
  color: var(--ink);
  font-weight: 600;
}

.ablaufkarte figcaption {
  margin-top: 16px;
  color: var(--ink-3);
  font-size: 0.875rem;
}

/* Entscheidungs- und Kostentabellen */
.tabelle-karte {
  overflow-x: auto;
  padding: 8px clamp(16px, 2.5vw, 28px);
}

.tabelle {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9688rem;
}

.tabelle th,
.tabelle td {
  padding: 16px 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

.tabelle thead th {
  color: var(--ink-3);
  font-size: 0.875rem;
  font-weight: 550;
}

.tabelle tbody tr:last-child th,
.tabelle tbody tr:last-child td {
  border-bottom: 0;
}

.tabelle tbody th {
  font-weight: 600;
}

.tabelle td {
  color: var(--ink-2);
}

.tabelle-link {
  margin-top: 16px;
}

/* Umfang mit Angebotskarte */
.umfang {
  display: grid;
  gap: 16px;
}

.umfang.mit-angebot {
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  align-items: start;
}

.umfang .karte:first-child {
  padding-block: 12px;
}

.angebot h3 {
  font-size: 1.25rem;
}

.angebot p {
  margin-top: 10px;
  color: var(--ink-2);
}

.angebot .angebot-klein {
  color: var(--ink-3);
  font-size: 0.875rem;
}

.angebot .text-link {
  margin-top: 16px;
}

/* Vorgehen: bis zu vier Schritte nebeneinander */
.leistung-schritte {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

/* Weiterführende Leistungen als Karten-Links */
.anschluss {
  display: grid;
  gap: 8px;
  color: var(--ink);
  text-decoration: none;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.anschluss:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lift);
}

.anschluss strong {
  font-size: 1.125rem;
  font-weight: 600;
  letter-spacing: -0.015em;
}

.anschluss span {
  color: var(--ink-2);
}

.anschluss .icon {
  margin-top: 8px;
  transition: transform 0.25s var(--ease);
}

.anschluss:hover .icon {
  transform: translateX(3px);
}

@media (max-width: 1080px) {
  .leistung-kopf,
  .umfang.mit-angebot {
    grid-template-columns: minmax(0, 1fr);
  }
  .leistung-notiz {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    column-gap: 24px;
    align-items: center;
  }
  .leistung-notiz .leistung-bild {
    grid-row: span 2;
    margin-bottom: 0;
  }
  .leistung-notiz dl,
  .leistung-notiz-preis {
    grid-column: 1 / -1;
  }
}

@media (max-width: 860px) {
  .zwei-spalten {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 640px) {
  .leistung-notiz {
    display: flex;
  }
  .leistung-notiz .leistung-bild {
    margin-bottom: 14px;
  }
  .leistung-notiz dl > div {
    grid-template-columns: minmax(0, 1fr);
    gap: 2px;
  }
  .tabelle thead {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
  }
  .tabelle,
  .tabelle tbody,
  .tabelle tr,
  .tabelle th,
  .tabelle td {
    display: block;
  }
  .tabelle tr {
    padding: 14px 0;
    border-bottom: 1px solid var(--line);
  }
  .tabelle tbody tr:last-child {
    border-bottom: 0;
  }
  .tabelle th,
  .tabelle td {
    padding: 4px 0;
    border: 0;
  }
  .tabelle td::before {
    content: attr(data-label);
    display: block;
    color: var(--ink-3);
    font-size: 0.8125rem;
    font-weight: 550;
  }
}
