/* ==========================================================================
   Home page (board "Startseite A2" and "Startseite Mobile"). LAYOUT FILE.
   Loaded on the page template page-home.php only. Shared pieces (kicker, links,
   chips, carousel controls, rows) live in components.css.
   ========================================================================== */

/* ---------- Section frame ---------- */

.ah-hsection {
  padding-top: var(--ah-section-gap);
  padding-bottom: var(--ah-section-gap);
  background: var(--ah-white);
}

.ah-hsection--beige {
  background: var(--ah-beige);
}

.ah-hsection > .ah-container {
  display: flex;
  flex-direction: column;
  gap: 36px;
}

.ah-hhead {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

.ah-hhead--row {
  flex-direction: row;
  justify-content: space-between;
  align-items: flex-end;
  gap: 48px;
}

.ah-hhead--row > .ah-link,
.ah-hhead--row > .ah-btn {
  flex-shrink: 0;
  white-space: nowrap;
}

.ah-htitle {
  font-size: 44px;
  line-height: 1.12;
  letter-spacing: -1px;
}

.ah-hsub {
  font-size: 26px;
  line-height: 1.25;
  letter-spacing: -0.4px;
}

.ah-hlead {
  max-width: 720px;
  color: var(--ah-grey);
  font-size: 18px;
  line-height: 1.65;
}

.ah-hsplit {
  display: grid;
  gap: 72px;
  align-items: center;
}

.ah-hsplit--cost {
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 64px;
}

.ah-hsplit--zeugnis {
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr);
}

.ah-hsection > .ah-hsplit {
  display: grid;
}

.ah-hsplit__main {
  display: flex;
  flex-direction: column;
  gap: 22px;
  min-width: 0;
}

.ah-hbuttons {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  padding-top: 4px;
}

/* ---------- Hero ---------- */

.ah-hhero {
  background: var(--ah-beige);
}

.ah-hhero__inner {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 72px;
  align-items: center;
  padding-top: 80px;
  padding-bottom: 48px;
}

.ah-hhero__intro {
  display: flex;
  flex-direction: column;
  gap: 26px;
  min-width: 0;
}

.ah-hhero__text {
  max-width: 600px;
  color: var(--ah-grey);
  font-size: 20px;
  line-height: 1.6;
}

.ah-hhero__trust {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  margin: 0;
  padding: 0;
  list-style: none;
  color: var(--ah-grey);
  font-size: 15px;
  font-weight: 700;
}

.ah-hhero__trust li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.ah-hhero__trust svg {
  color: var(--ah-orange-text);
}

.ah-situation {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 32px;
  border-radius: var(--ah-radius-box);
  background: var(--ah-white);
  box-shadow: 0 20px 50px rgba(27, 23, 20, 0.09);
}

.ah-situation__title {
  font-size: 24px;
  line-height: 1.25;
  letter-spacing: 0;
}

.ah-situation__list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.ah-situation__option {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  border: 1px solid var(--ah-line);
  border-radius: 16px;
  background: var(--ah-white);
  color: var(--ah-text);
  text-decoration: none;
  transition: border-color 0.15s, background 0.15s;
}

.ah-situation__option:hover {
  border-color: var(--ah-orange);
  background: var(--ah-peach);
}

.ah-situation__option svg {
  flex-shrink: 0;
  color: var(--ah-orange-text);
}

.ah-situation__text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  line-height: 1.35;
}

.ah-situation__text strong {
  font-size: 17px;
  font-weight: 800;
}

.ah-situation__text span {
  color: var(--ah-grey);
  font-size: 14px;
}

.ah-situation__note {
  padding-top: 4px;
  color: var(--ah-grey);
  font-size: 14px;
  line-height: 1.5;
}

/* ---------- Trust bar ---------- */

.ah-trustbar {
  border-bottom: 1px solid var(--ah-line);
  background: var(--ah-white);
}

.ah-trustbar__inner {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 56px;
  padding-top: 32px;
  padding-bottom: 32px;
}

.ah-trustbar__sep {
  width: 1px;
  align-self: stretch;
  background: var(--ah-input-border);
}

.ah-rating {
  display: flex;
  align-items: center;
  gap: 18px;
  color: var(--ah-text);
  text-decoration: none;
  white-space: nowrap;
}

.ah-rating__body {
  display: flex;
  flex-direction: column;
  gap: 6px;
  line-height: 1.3;
}

.ah-rating__label {
  font-size: 16px;
  font-weight: 800;
}

.ah-rating__score {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 18px;
}

.ah-rating__count {
  color: var(--ah-grey);
  font-size: 14px;
}

.ah-rating__brand {
  display: inline-flex;
  align-items: center;
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.5px;
}

.ah-rating__brand--google span:nth-child(1),
.ah-rating__brand--google span:nth-child(4) { color: var(--ah-google-blue); }
.ah-rating__brand--google span:nth-child(2),
.ah-rating__brand--google span:nth-child(6) { color: var(--ah-google-red); }
.ah-rating__brand--google span:nth-child(3) { color: var(--ah-google-yellow); }
.ah-rating__brand--google span:nth-child(5) { color: var(--ah-google-green); }

.ah-rating__brand--tp {
  gap: 8px;
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -0.3px;
}

.ah-rating__brand--tp .ah-stars__box {
  width: 26px;
  height: 26px;
}

/* Stars: --fill sets how much of a star is coloured (partial last star). */
.ah-stars {
  display: inline-flex;
  gap: 2px;
}

.ah-stars__star {
  display: inline-flex;
  color: var(--ah-star-google);
  -webkit-mask: linear-gradient(90deg, #000 var(--fill, 100%), rgba(0, 0, 0, 0.18) var(--fill, 100%));
  mask: linear-gradient(90deg, #000 var(--fill, 100%), rgba(0, 0, 0, 0.18) var(--fill, 100%));
}

.ah-stars__box {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  background: linear-gradient(90deg, var(--ah-trustpilot) var(--fill, 100%), var(--ah-input-border) var(--fill, 100%));
  color: var(--ah-white);
}

.ah-stars__box svg {
  width: 13px;
  height: 13px;
}

.ah-rating__brand--tp .ah-stars__box svg {
  width: 17px;
  height: 17px;
}

/* ---------- Calculator ---------- */

.ah-hcalc__inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 72px;
  align-items: start;
}

.ah-hsection > .ah-hcalc__inner {
  display: grid;
}

.ah-hcalc__intro {
  display: flex;
  flex-direction: column;
  gap: 22px;
  min-width: 0;
}

.ah-hcalc__example {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.ah-hcalc__caption {
  color: var(--ah-grey);
  font-size: 15px;
  font-weight: 800;
}

.ah-htable {
  width: 100%;
  border-collapse: collapse;
  overflow: hidden;
  border-radius: var(--ah-radius-card);
  background: var(--ah-white);
  box-shadow: 0 10px 30px rgba(27, 23, 20, 0.06);
  font-size: 17px;
}

.ah-htable th {
  padding: 14px 20px;
  background: var(--ah-peach);
  font-weight: 800;
  text-align: left;
}

.ah-htable td {
  padding: 14px 20px;
}

.ah-htable tbody tr + tr td {
  border-top: 1px solid var(--ah-line);
}

.ah-hcalc__links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  font-size: 16px;
}

.ah-calc {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 30px;
  border-radius: var(--ah-radius-box);
  background: var(--ah-white);
  box-shadow: var(--ah-shadow-raised);
}

.ah-calc__field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ah-calc__label {
  font-size: 16px;
  font-weight: 800;
}

.ah-calc__row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.ah-calc__years {
  font-size: 22px;
  font-weight: 800;
}

.ah-calc__input {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 52px;
  padding: 0 16px;
  border: 2px solid var(--ah-input-border);
  border-radius: 14px;
  color: var(--ah-grey);
  font-size: 20px;
  font-weight: 800;
}

.ah-calc__input:focus-within {
  border-color: var(--ah-orange);
}

.ah-calc__input input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ah-text);
  font-size: 20px;
  font-weight: 800;
}

/* Range: orange fill up to the thumb (--pct is set by home.js). */
.ah-range {
  width: 100%;
  height: 28px;
  margin: 0;
  background: transparent;
  -webkit-appearance: none;
  appearance: none;
  cursor: pointer;
}

.ah-range::-webkit-slider-runnable-track {
  height: 8px;
  border-radius: var(--ah-radius-pill);
  background: linear-gradient(90deg, var(--ah-orange) var(--pct, 23%), var(--ah-line) var(--pct, 23%));
}

.ah-range::-moz-range-track {
  height: 8px;
  border-radius: var(--ah-radius-pill);
  background: linear-gradient(90deg, var(--ah-orange) var(--pct, 23%), var(--ah-line) var(--pct, 23%));
}

.ah-range::-webkit-slider-thumb {
  width: 24px;
  height: 24px;
  margin-top: -8px;
  border: 3px solid var(--ah-orange);
  border-radius: 50%;
  background: var(--ah-white);
  -webkit-appearance: none;
  appearance: none;
}

.ah-range::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border: 3px solid var(--ah-orange);
  border-radius: 50%;
  background: var(--ah-white);
}

.ah-calc__check {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
}

.ah-calc__check input {
  width: 22px;
  height: 22px;
  margin: 0;
  accent-color: var(--ah-orange);
}

.ah-calc__result {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 20px;
  border-radius: 18px;
  background: var(--ah-peach);
}

.ah-calc__result-label {
  color: var(--ah-orange-dark);
  font-size: 15px;
  font-weight: 800;
}

.ah-calc__value {
  font-size: 42px;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -1.2px;
}

.ah-calc__value.is-muted {
  color: var(--ah-grey);
}

.ah-calc__formula,
.ah-calc__hint {
  color: var(--ah-grey);
  font-size: 15px;
  line-height: 1.5;
}

.ah-calc__hint {
  padding-top: 6px;
  color: var(--ah-text);
}

.ah-calc__note {
  color: var(--ah-grey);
  font-size: 14px;
  line-height: 1.5;
  text-align: center;
}

/* ---------- At a glance ---------- */

.ah-hfacts__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
}

.ah-fact {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 28px;
  border: 1px solid var(--ah-line);
  border-radius: 22px;
  background: var(--ah-white);
  box-shadow: var(--ah-shadow-card);
}

.ah-fact__label {
  color: var(--ah-orange-text);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.5px;
}

.ah-fact__value {
  font-size: 28px;
  font-weight: 800;
  line-height: 1.15;
}

.ah-fact__text {
  flex-grow: 1;
  color: var(--ah-grey);
  font-size: 16px;
  line-height: 1.6;
}

/* ---------- Top articles ---------- */

.ah-tabs {
  display: flex;
  flex-direction: column;
  gap: 36px;
}

.ah-hposts__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 28px;
}

.ah-tcard {
  display: flex;
  flex-direction: column;
  gap: 16px;
  color: var(--ah-text);
  text-decoration: none;
}

.ah-tcard__image {
  display: block;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  max-width: 100%;
  border-radius: 16px;
  background: var(--ah-image-bg);
}

.ah-tcard__image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}

.ah-tcard:hover .ah-tcard__image img {
  transform: scale(1.03);
}

.ah-tcard__body {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}

.ah-tcard__label {
  color: var(--ah-orange-text);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.ah-tcard__title {
  font-size: 20px;
  font-weight: 800;
  line-height: 1.3;
}

.ah-tcard:hover .ah-tcard__title {
  color: var(--ah-orange-text);
}

.ah-tcard__text {
  color: var(--ah-grey);
  font-size: 15px;
  line-height: 1.55;
}

.ah-tcard__date {
  color: var(--ah-grey);
  font-size: 13px;
}

/* ---------- Calculator list ---------- */

.ah-htools__list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: repeat(var(--rows, 4), auto);
  grid-auto-flow: column;
  column-gap: 72px;
  border-bottom: 1px solid var(--ah-line);
}

.ah-htools__list li:nth-child(n) .ah-row {
  height: 100%;
}

.ah-row.is-disabled {
  color: var(--ah-text);
}

/* ---------- Lawyers ---------- */

.ah-hlawyers__top {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: 72px;
  align-items: start;
}

.ah-hlawyers__text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
}

.ah-hlawyers__text .ah-hlead {
  font-size: 17px;
  line-height: 1.7;
}

.ah-citylist {
  display: grid;
  grid-template-columns: 1fr 1fr;
  column-gap: 40px;
  margin: 0;
  padding: 0;
  border-bottom: 1px solid var(--ah-line);
  list-style: none;
}

.ah-citylist a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 0;
  border-top: 1px solid var(--ah-line);
  color: var(--ah-text);
  font-size: 17px;
  font-weight: 700;
  text-decoration: none;
}

.ah-citylist a:hover {
  color: var(--ah-orange-text);
}

.ah-citylist svg {
  width: 16px;
  height: 16px;
  color: var(--ah-orange-text);
}

.ah-hpartners {
  display: flex;
  flex-direction: column;
  gap: 32px;
  padding-top: 32px;
}

.ah-hpartners__head {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
}

.ah-hpartners__nav {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ah-hpartners__nav .ah-link {
  margin-right: 10px;
}

.ah-hpartners__track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - 3 * 28px) / 4);
  gap: 28px;
  margin: 0;
  padding: 0;
  list-style: none;
}

/* Compact cards (board Startseite_Partner_E, chosen by Timo): photo top aligned,
   name in one line, role max. two lines, city with pin, all cards the same height. */
.ah-partner {
  display: flex;
  min-width: 0;
}

.ah-partner__link {
  display: flex;
  flex: 1;
  align-items: flex-start;
  gap: 16px;
  min-width: 0;
  padding: 20px;
  border: 1px solid var(--ah-line);
  border-radius: var(--ah-radius-card);
  background: var(--ah-white);
  box-shadow: var(--ah-shadow-card);
  color: var(--ah-text);
  text-decoration: none;
}

.ah-partner__link:hover {
  border-color: var(--ah-orange);
}

.ah-partner__photo {
  display: block;
  flex-shrink: 0;
  overflow: hidden;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--ah-image-bg);
}

.ah-partner__photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.ah-partner__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.ah-partner__name {
  overflow: hidden;
  font-size: 17px;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ah-partner__role {
  display: -webkit-box;
  overflow: hidden;
  min-height: calc(2 * 1.45em);
  color: var(--ah-grey);
  font-size: 14px;
  line-height: 1.45;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  line-clamp: 2;
}

.ah-partner__city {
  display: flex;
  align-items: center;
  gap: 5px;
  margin: 2px 0 8px;
  color: var(--ah-grey);
  font-size: 13px;
}

.ah-partner__city svg {
  flex-shrink: 0;
  color: var(--ah-orange-text);
}

.ah-partner__more {
  margin-top: auto;
  color: var(--ah-orange-text);
  font-size: 15px;
  font-weight: 800;
}

.ah-partner__more::after {
  content: " →";
}

/* ---------- Cost coverage ---------- */

.ah-hcost__points {
  gap: 14px;
  font-size: 17px;
}

.ah-hcost__points svg {
  margin-top: 4px;
}

.ah-costcard {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 34px;
  border-radius: var(--ah-radius-box);
  background: var(--ah-white);
  box-shadow: var(--ah-shadow-raised);
}

.ah-costcard__title {
  font-size: 20px;
  font-weight: 800;
}

.ah-costcard__sub,
.ah-costcard__note {
  color: var(--ah-grey);
  font-size: 14px;
  line-height: 1.6;
}

.ah-costcard__compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.ah-costcard__box {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 20px;
  border: 1px solid var(--ah-line);
  border-radius: 18px;
}

.ah-costcard__box--peach {
  border-color: var(--ah-peach);
  background: var(--ah-peach);
}

.ah-costcard__label {
  color: var(--ah-grey);
  font-size: 14px;
  font-weight: 800;
}

.ah-costcard__box--peach .ah-costcard__label {
  color: var(--ah-orange-dark);
}

.ah-costcard__value {
  font-size: 28px;
  font-weight: 800;
  line-height: 1.2;
}

.ah-costcard__text {
  color: var(--ah-grey);
  font-size: 14px;
  line-height: 1.5;
}

/* ---------- Reviews ---------- */

.ah-hreviews__summary {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--ah-grey);
  font-size: 16px;
  white-space: nowrap;
}

.ah-hreviews__summary strong {
  color: var(--ah-text);
}

.ah-hreviews__frame {
  position: relative;
}

.ah-hreviews__track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: calc((100% - 3 * 24px) / 4);
  gap: 24px;
  /* Room for the card shadow inside the scroll box. */
  margin: -6px -6px -24px;
  padding: 6px 6px 30px;
  scroll-padding: 0 6px;
  list-style: none;
}

.ah-review {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 24px;
  border: 1px solid var(--ah-line);
  border-radius: 22px;
  background: var(--ah-white);
  box-shadow: 0 8px 24px rgba(27, 23, 20, 0.06);
}

.ah-review__head {
  display: flex;
  align-items: center;
  gap: 14px;
}

.ah-review__avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--ah-avatar-1);
  color: var(--ah-white);
  font-size: 16px;
  font-weight: 800;
}

.ah-review__avatar--2 { background: var(--ah-avatar-2); }
.ah-review__avatar--3 { background: var(--ah-avatar-3); }
.ah-review__avatar--4 { background: var(--ah-avatar-4); }

.ah-review__who {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  line-height: 1.35;
}

.ah-review__who strong {
  font-size: 17px;
}

.ah-review__who span {
  color: var(--ah-grey);
  font-size: 14px;
}

.ah-review__text {
  display: -webkit-box;
  overflow: hidden;
  font-size: 16px;
  line-height: 1.6;
  -webkit-line-clamp: 5;
  -webkit-box-orient: vertical;
  line-clamp: 5;
}

.ah-review__more {
  align-self: flex-start;
  margin-top: auto;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  font-size: 15px;
  cursor: pointer;
}

/* "Weiterlesen" opens the full review in the card (Timo, 5 Nov 2026). */
.ah-review.is-open .ah-review__text {
  display: block;
  overflow: visible;
  -webkit-line-clamp: unset;
  line-clamp: unset;
}

.ah-roundbtn--float {
  position: absolute;
  top: 50%;
  right: -26px;
  width: 52px;
  height: 52px;
  border: 0;
  box-shadow: 0 6px 20px rgba(27, 23, 20, 0.14);
  transform: translateY(-50%);
}

.ah-hreviews__foot {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
}

/* ---------- Ticker ---------- */

.ah-hticker__lead {
  max-width: 760px;
}

.ah-hticker__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 32px;
  align-items: stretch;
}

.ah-panel {
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-width: 0;
  padding: 28px 32px;
  border: 1px solid var(--ah-line);
  border-radius: var(--ah-radius-box);
  background: var(--ah-white);
  box-shadow: 0 10px 30px rgba(27, 23, 20, 0.06);
}

.ah-panel__head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
}

.ah-panel__title {
  font-size: 19px;
  line-height: 1.3;
  letter-spacing: 0;
}

.ah-panel__meta {
  color: var(--ah-grey);
  font-size: 14px;
}

.ah-hticker__chart {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.ah-bars {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.ah-bars__plot {
  display: flex;
  align-items: flex-end;
  gap: 14px;
  height: 146px;
  border-bottom: 1px solid var(--ah-axis);
}

.ah-bars__col {
  display: flex;
  flex: 1;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  gap: 6px;
}

.ah-bars__bar {
  display: block;
  width: 100%;
  max-width: 44px;
  border-radius: 4px 4px 0 0;
  background: var(--ah-bar);
}

.ah-bars__col.is-current .ah-bars__bar {
  background: var(--ah-orange);
}

.ah-bars__value {
  font-size: 14px;
  font-weight: 800;
  line-height: 1;
}

.ah-bars__labels {
  display: flex;
  gap: 14px;
}

.ah-bars__labels span {
  flex: 1;
  color: var(--ah-grey);
  font-size: 13px;
  font-weight: 600;
  text-align: center;
}

.ah-bars__labels .is-current {
  color: var(--ah-text);
  font-weight: 800;
}

.ah-bars__caption {
  margin-top: -12px;
  color: var(--ah-grey);
  font-size: 13px;
}

.ah-bars__caption strong {
  color: var(--ah-text);
}

.ah-hticker__list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.ah-tickerrow {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr) auto 20px;
  gap: 18px;
  align-items: center;
  padding: 18px 0;
  border-bottom: 1px solid var(--ah-line);
  color: var(--ah-text);
  text-decoration: none;
}

.ah-tickerrow:hover strong {
  color: var(--ah-orange-text);
}

.ah-tickerrow__date {
  color: var(--ah-grey);
  font-size: 14px;
}

.ah-tickerrow__company {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  line-height: 1.3;
}

.ah-tickerrow__company strong {
  font-size: 18px;
}

.ah-tickerrow__company span {
  color: var(--ah-grey);
  font-size: 14px;
}

.ah-tickerrow__jobs {
  max-width: 240px;
  color: var(--ah-orange-text);
  font-size: 16px;
  font-weight: 800;
  line-height: 1.35;
  text-align: right;
}

.ah-tickerrow__chevron {
  display: flex;
  color: var(--ah-orange-text);
}

.ah-hticker__more {
  align-self: center;
  padding: 18px 0 20px;
  font-size: 16px;
}

.ah-hticker__companies {
  gap: 22px;
}

.ah-csearch {
  position: relative;
}

.ah-csearch__field {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 54px;
  padding: 0 16px;
  border: 2px solid var(--ah-input-border);
  border-radius: 14px;
  background: var(--ah-white);
  color: var(--ah-grey);
}

.ah-csearch__field:focus-within {
  border-color: var(--ah-orange);
}

.ah-csearch__field input {
  flex: 1;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ah-text);
  font-size: 17px;
}

.ah-csearch__field input::placeholder {
  color: var(--ah-grey);
  opacity: 0.85;
}

.ah-csearch__results {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  z-index: 5;
  margin: 0;
  padding: 6px;
  border: 1px solid var(--ah-line);
  border-radius: 14px;
  background: var(--ah-white);
  box-shadow: var(--ah-shadow-raised);
  list-style: none;
}

.ah-csearch__results a,
.ah-csearch__results span {
  display: block;
  padding: 10px 12px;
  border-radius: 10px;
  color: var(--ah-text);
  font-size: 16px;
  font-weight: 700;
  text-decoration: none;
}

.ah-csearch__results span {
  color: var(--ah-grey);
  font-weight: 500;
}

.ah-csearch__results a:hover,
.ah-csearch__results a.is-active {
  background: var(--ah-peach);
}

.ah-hticker__frame {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  gap: 16px;
  min-width: 0;
  padding: 26px;
  border-radius: var(--ah-radius-card);
  background: var(--ah-peach);
}

.ah-hticker__cards {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 100%;
  flex-grow: 1;
  gap: 26px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.ah-company {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
}

.ah-company__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.ah-company__kicker {
  color: var(--ah-orange-dark);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 1px;
}

.ah-company__badge {
  padding: 5px 12px;
  border-radius: var(--ah-radius-pill);
  background: var(--ah-white);
  font-size: 13px;
  font-weight: 800;
}

.ah-company__name {
  font-size: 28px;
  font-weight: 800;
  line-height: 1.2;
}

.ah-company__facts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 0;
  padding: 20px;
  border-radius: 16px;
  background: var(--ah-white);
}

.ah-company__facts div {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ah-company__facts dt {
  color: var(--ah-orange-dark);
  font-size: 13px;
  font-weight: 800;
}

.ah-company__facts dd {
  margin: 0;
  font-size: 17px;
  font-weight: 800;
}

.ah-company__text {
  flex-grow: 1;
  color: var(--ah-grey);
  font-size: 16px;
  line-height: 1.6;
}

.ah-company__link {
  font-size: 17px;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.ah-hticker__controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 4px;
}

.ah-hticker__arrows {
  display: flex;
  gap: 10px;
}

.ah-roundbtn--plain {
  width: 40px;
  height: 40px;
  border: 0;
}

/* ---------- Zeugnis-Check ---------- */

.ah-hzeugnis .ah-kicker {
  display: flex;
  align-items: center;
  gap: 12px;
}

.ah-numsteps {
  display: flex;
  flex-direction: column;
  gap: 22px;
  margin: 0;
  padding: 8px 0 0;
  list-style: none;
}

.ah-numsteps li {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.ah-numsteps__n {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--ah-peach);
  color: var(--ah-orange-text);
  font-size: 15px;
  font-weight: 800;
}

.ah-numsteps li > span:last-child {
  display: flex;
  flex-direction: column;
  gap: 2px;
  line-height: 1.45;
}

.ah-numsteps strong {
  font-size: 17px;
}

.ah-numsteps li > span:last-child span {
  color: var(--ah-grey);
  font-size: 15px;
}

.ah-hzeugnis__cta {
  display: flex;
  align-items: center;
  gap: 20px;
  padding-top: 10px;
}

.ah-hzeugnis__note {
  color: var(--ah-grey);
  font-size: 14px;
  line-height: 1.5;
}

.ah-zcard {
  overflow: hidden;
  border: 1px solid var(--ah-line);
  border-radius: var(--ah-radius-box);
  background: var(--ah-white);
  box-shadow: var(--ah-shadow-raised);
}

.ah-zcard__bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 28px;
  border-bottom: 1px solid var(--ah-line);
  background: var(--ah-beige);
  color: var(--ah-grey);
  font-size: 13px;
  font-weight: 700;
}

.ah-zcard__live {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ah-text);
  font-size: 15px;
  font-weight: 800;
}

.ah-zcard__live::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--ah-orange);
}

.ah-zcard__body {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 28px;
}

.ah-zcard__total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 17px;
}

.ah-zcard__grade {
  color: var(--ah-grey);
  font-size: 15px;
}

.ah-zcard__grade b {
  color: var(--ah-grade-4);
  font-size: 22px;
}

.ah-zscale {
  position: relative;
  height: 10px;
  border-radius: var(--ah-radius-pill);
  background: linear-gradient(90deg, var(--ah-grade-1) 0%, var(--ah-grade-2) 28%, var(--ah-grade-3) 52%, var(--ah-grade-4) 76%, var(--ah-grade-5) 100%);
}

.ah-zscale span {
  position: absolute;
  top: 50%;
  left: var(--pos, 50%);
  width: 24px;
  height: 24px;
  border: 3px solid var(--ah-grade-4);
  border-radius: 50%;
  background: var(--ah-white);
  transform: translate(-50%, -50%);
}

.ah-zscale--small {
  height: 4px;
}

.ah-zscale--small span {
  width: 14px;
  height: 14px;
  border-width: 2px;
}

.ah-zscale__labels {
  display: flex;
  justify-content: space-between;
  color: var(--ah-grey);
  font-size: 12px;
}

.ah-zcard__cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  padding-top: 18px;
}

.ah-zcard__caption {
  margin-bottom: 10px;
  color: var(--ah-grey);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 1px;
}

.ah-zpart {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 8px 0 12px;
  border-bottom: 1px solid var(--ah-line);
}

.ah-zpart:last-child {
  border-bottom: 0;
}

.ah-zpart__row {
  display: flex;
  justify-content: space-between;
  font-size: 14px;
  font-weight: 700;
}

.ah-zpart__row b {
  font-size: 13px;
  font-weight: 800;
}

.ah-zpart__row b.is-bad { color: var(--ah-grade-4); }
.ah-zpart__row b.is-mid { color: var(--ah-grade-3-text); }

.ah-zcard__flag {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 6px;
  background: var(--ah-grade-4);
  color: var(--ah-white);
  font-size: 11px;
  font-weight: 800;
}

.ah-zcard__quote {
  margin: 12px 0;
  padding-left: 12px;
  border-left: 2px solid var(--ah-line);
  color: var(--ah-text);
  font-size: 14px;
  font-style: italic;
  line-height: 1.5;
}

.ah-zcard__better {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px;
  border-radius: 12px;
  background: var(--ah-pro-bg);
  color: var(--ah-pro-dark);
  font-size: 14px;
  font-style: italic;
  line-height: 1.5;
}

.ah-zcard__better span {
  color: var(--ah-pro);
  font-size: 11px;
  font-style: normal;
  font-weight: 800;
}

/* ---------- FAQ ---------- */

.ah-hfaq {
  border-top: 1px solid var(--ah-line);
}

.ah-hsection > .ah-hfaq__inner {
  display: grid;
  grid-template-columns: 380px minmax(0, 1fr);
  gap: 80px;
  align-items: start;
}

.ah-hfaq__intro {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 18px;
}

.ah-hfaq__intro .ah-hlead {
  font-size: 17px;
}

/* ==========================================================================
   Tablet: fewer columns before the mobile layout takes over
   ========================================================================== */

@media (max-width: 1180px) and (min-width: 901px) {
  .ah-htitle {
    font-size: 38px;
  }

  .ah-hfacts__grid,
  .ah-hposts__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ah-hpartners__track {
    grid-auto-columns: calc((100% - 2 * 28px) / 3);
  }

  .ah-hreviews__track {
    grid-auto-columns: calc((100% - 2 * 24px) / 3);
  }

  .ah-hticker__grid,
  .ah-hsection > .ah-hfaq__inner {
    grid-template-columns: minmax(0, 1fr);
  }

  .ah-hhero__inner,
  .ah-hsection > .ah-hcalc__inner,
  .ah-hsplit {
    gap: 40px;
  }

  .ah-roundbtn--float {
    right: -12px;
  }
}

/* ==========================================================================
   Mobile (board "Startseite Mobile", 390 px)
   ========================================================================== */

@media (max-width: 900px) {
  .ah-hsection {
    padding-top: var(--ah-section-gap-mobile);
    padding-bottom: var(--ah-section-gap-mobile);
  }

  .ah-hsection > .ah-container {
    gap: 18px;
  }

  .ah-hhead {
    gap: 10px;
  }

  .ah-hhead--row {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .ah-kicker {
    font-size: 13px;
  }

  .ah-htitle {
    font-size: 28px;
    line-height: 1.18;
    letter-spacing: -0.6px;
  }

  .ah-hsub {
    font-size: 17px;
    letter-spacing: 0;
  }

  .ah-hlead {
    font-size: 16px;
    line-height: 1.6;
  }

  .ah-hsplit,
  .ah-hsection > .ah-hsplit,
  .ah-hsplit--cost,
  .ah-hsplit--zeugnis {
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
  }

  .ah-hsplit__main {
    gap: 14px;
  }

  .ah-hbuttons {
    flex-direction: column;
    gap: 12px;
    padding-top: 0;
  }

  /* Hero */
  .ah-hhero__inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
    padding-top: 28px;
    padding-bottom: 24px;
  }

  .ah-hhero__intro {
    gap: 16px;
  }

  .ah-hhero__title {
    font-size: var(--ah-h1-mobile);
    line-height: 1.1;
    letter-spacing: -1px;
  }

  .ah-hhero__text {
    font-size: 16px;
  }

  .ah-hhero__button {
    width: 100%;
  }

  .ah-hhero__trust {
    gap: 8px 16px;
    font-size: 14px;
  }

  .ah-situation {
    gap: 10px;
    padding: 20px;
    box-shadow: 0 12px 30px rgba(27, 23, 20, 0.07);
  }

  .ah-situation__title {
    font-size: 19px;
  }

  .ah-situation__list {
    gap: 10px;
  }

  .ah-situation__option {
    padding: 13px 16px;
    border-radius: 14px;
  }

  .ah-situation__text strong {
    font-size: 16px;
  }

  .ah-situation__text span,
  .ah-situation__note {
    font-size: 13px;
  }

  /* Trust bar: two rows, logo left */
  .ah-trustbar {
    border-bottom: 0;
    background: var(--ah-beige);
  }

  .ah-trustbar__inner {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding-top: 0;
    padding-bottom: 24px;
  }

  .ah-trustbar__sep {
    display: none;
  }

  .ah-rating {
    flex-direction: row-reverse;
    justify-content: space-between;
    padding: 16px 0;
    border-top: 1px solid var(--ah-line);
  }

  .ah-rating:last-child {
    border-bottom: 1px solid var(--ah-line);
  }

  .ah-rating__label {
    display: none;
  }

  .ah-rating__body {
    flex: 0 0 auto;
    width: 200px;
  }

  .ah-rating__brand {
    font-size: 21px;
  }

  .ah-rating__brand--tp {
    font-size: 19px;
  }

  .ah-rating__brand--tp .ah-stars__box {
    width: 22px;
    height: 22px;
  }

  /* Calculator */
  .ah-hsection > .ah-hcalc__inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
  }

  .ah-hcalc__intro {
    gap: 14px;
  }

  .ah-calc {
    gap: 14px;
    padding: 20px;
    border: 1px solid var(--ah-line);
    box-shadow: none;
  }

  .ah-calc__value {
    font-size: 32px;
  }

  .ah-calc__formula,
  .ah-calc__check {
    font-size: 14px;
  }

  .ah-calc__note {
    font-size: 13px;
    text-align: left;
  }

  .ah-hcalc__links {
    flex-direction: column;
    gap: 10px;
    font-size: 15px;
  }

  .ah-hcalc__links .ah-link {
    text-decoration: none;
  }

  /* At a glance: peach band, cards stacked */
  .ah-hfacts {
    background: var(--ah-peach);
  }

  .ah-hfacts__grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }

  .ah-fact {
    gap: 6px;
    padding: 20px;
    border: 0;
    border-radius: var(--ah-radius-card);
  }

  .ah-fact__label {
    font-size: 13px;
  }

  .ah-fact__value {
    font-size: 24px;
  }

  .ah-fact__text {
    font-size: 15px;
  }

  /* Top articles: list with small photo */
  .ah-tabs {
    gap: 18px;
  }

  .ah-hposts__grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
    border-bottom: 1px solid var(--ah-line);
  }

  .ah-tcard {
    flex-direction: row;
    align-items: center;
    gap: 14px;
    padding: 12px 0;
  }

  .ah-tcard + .ah-tcard {
    border-top: 1px solid var(--ah-line);
  }

  .ah-tcard__image {
    flex-shrink: 0;
    width: 64px;
    height: 48px;
    aspect-ratio: auto;
    border-radius: 10px;
  }

  .ah-tcard__title {
    font-size: 15px;
    line-height: 1.4;
  }

  .ah-hposts__all {
    padding-top: 12px;
    text-decoration: none;
  }

  /* Calculator list */
  .ah-htools__list {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: none;
    grid-auto-flow: row;
  }

  /* Lawyers */
  .ah-hlawyers__top {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
  }

  .ah-hlawyers__cities {
    display: flex;
    flex-direction: column;
    gap: 14px;
  }

  .ah-hlawyers__cities .ah-link,
  .ah-hpartners__all {
    text-decoration: none;
  }

  .ah-citylist {
    column-gap: 24px;
  }

  .ah-citylist li:nth-child(n+7) {
    display: none;
  }

  .ah-citylist a {
    padding: 13px 0;
    font-size: 16px;
  }

  .ah-hlawyers__text .ah-hlead {
    font-size: 15px;
  }

  .ah-hpartners {
    gap: 0;
    padding-top: 12px;
  }

  .ah-hpartners__head {
    padding-bottom: 14px;
    border-bottom: 1px solid var(--ah-line);
  }

  .ah-hpartners__track {
    display: flex;
    flex-direction: column;
    gap: 0;
    overflow: visible;
  }

  .ah-hpartners__track li:nth-child(n+5) {
    display: none;
  }

  .ah-partner__link {
    align-items: center;
    gap: 14px;
    padding: 14px 0;
    border: 0;
    border-bottom: 1px solid var(--ah-line);
    border-radius: 0;
    background: none;
    box-shadow: none;
  }

  .ah-partner__photo {
    width: 64px;
    height: 64px;
  }

  .ah-partner__body {
    flex: 1;
    gap: 1px;
  }

  .ah-partner__name {
    font-size: 17px;
  }

  .ah-partner__role {
    min-height: 0;
    font-size: 14px;
    -webkit-line-clamp: 1;
    line-clamp: 1;
  }

  .ah-partner__city {
    margin: 0;
  }

  .ah-partner__more {
    margin: 0;
    font-size: 14px;
  }

  .ah-partner__more::after {
    content: none;
  }

  .ah-partner__chevron {
    display: flex;
    color: var(--ah-orange-text);
  }

  .ah-hpartners__all {
    padding-top: 18px;
  }

  /* Cost coverage */
  .ah-costcard {
    padding: 18px;
    border: 1px solid var(--ah-line);
    box-shadow: none;
  }

  .ah-costcard__compare {
    gap: 0;
  }

  .ah-costcard__box,
  .ah-costcard__box--peach {
    gap: 2px;
    padding: 2px 0;
    border: 0;
    border-radius: 0;
    background: none;
  }

  .ah-costcard__box + .ah-costcard__box {
    padding-left: 16px;
    border-left: 1px solid var(--ah-line);
  }

  .ah-costcard__label {
    font-size: 13px;
    color: var(--ah-text);
  }

  .ah-costcard__box--peach .ah-costcard__label,
  .ah-costcard__box--peach .ah-costcard__value {
    color: var(--ah-orange-text);
  }

  .ah-costcard__value {
    font-size: 24px;
  }

  .ah-costcard__text {
    font-size: 13px;
  }

  /* Reviews: one card plus a peek of the next */
  .ah-hreviews__track {
    grid-auto-columns: 86%;
    gap: 14px;
    margin: 0 calc(-1 * var(--ah-page-margin-mobile)) 0 0;
    padding: 0 var(--ah-page-margin-mobile) 0 0;
    scroll-padding: 0;
  }

  .ah-review {
    gap: 12px;
    padding: 18px;
    box-shadow: none;
  }

  .ah-review__avatar {
    width: 40px;
    height: 40px;
  }

  .ah-review__text {
    font-size: 15px;
    -webkit-line-clamp: 6;
    line-clamp: 6;
  }

  .ah-review__more {
    font-size: 14px;
  }

  .ah-hreviews__foot {
    justify-content: flex-start;
    gap: 14px;
  }

  .ah-hreviews__count {
    color: var(--ah-grey);
    font-size: 13px;
    font-weight: 700;
  }

  .ah-hreviews__arrows {
    display: flex;
    gap: 10px;
    margin-left: auto;
  }

  /* Ticker */
  .ah-hticker__grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }

  .ah-panel {
    gap: 14px;
    padding: 18px;
    box-shadow: none;
  }

  .ah-panel__title {
    font-size: 17px;
  }

  /* Long job numbers ("1.100 bis Ende 2026 (weitere bis 2028)") wrap in their own
     column instead of running into the company name. */
  .ah-tickerrow {
    grid-template-columns: minmax(0, 1fr) minmax(0, 42%);
    grid-template-areas: "company jobs" "date jobs";
    gap: 2px 12px;
    padding: 12px 0;
  }

  .ah-tickerrow__company {
    grid-area: company;
  }

  .ah-tickerrow__company strong {
    font-size: 16px;
  }

  .ah-tickerrow__date {
    grid-area: date;
    font-size: 12px;
  }

  .ah-tickerrow__jobs {
    grid-area: jobs;
    max-width: none;
    font-size: 14px;
  }

  .ah-hticker__more {
    padding: 4px 0 2px;
    font-size: 15px;
  }

  .ah-csearch__field {
    height: 50px;
  }

  .ah-csearch__field input {
    font-size: 16px;
  }

  .ah-csearch__field svg {
    display: none;
  }

  .ah-hticker__frame {
    gap: 12px;
    padding: 16px;
    border-radius: 16px;
  }

  .ah-company {
    gap: 6px;
  }

  .ah-company__kicker {
    font-size: 12px;
    text-transform: uppercase;
  }

  .ah-company__name {
    font-size: 20px;
  }

  .ah-company__text {
    font-size: 14px;
  }

  .ah-company__link {
    font-size: 15px;
    text-decoration: none;
  }

  .ah-hticker__controls {
    justify-content: center;
  }

  /* Zeugnis */
  .ah-zcard {
    box-shadow: none;
  }

  .ah-zcard__body {
    gap: 12px;
    padding: 18px;
  }

  .ah-zcard__cols {
    grid-template-columns: minmax(0, 1fr);
    padding-top: 6px;
  }

  .ah-zcard__quote {
    margin: 0;
    font-size: 13px;
  }

  .ah-hzeugnis__cta {
    flex-direction: column;
    gap: 12px;
    padding-top: 0;
  }

  .ah-hzeugnis__note {
    font-size: 13px;
    text-align: center;
  }

  /* FAQ */
  .ah-hsection > .ah-hfaq__inner {
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;
  }

  .ah-hfaq__intro {
    gap: 10px;
  }

  .ah-hfaq__intro .ah-hlead {
    font-size: 15px;
  }

  .ah-hfaq__intro .ah-htitle {
    font-size: 26px;
  }

}
