/* =========================================================
   Haus Karin Accordion – Porto-sicher / screenshot-nah
   (harte Resets gegen Theme-Button/SVG-Overwrites)
========================================================= */

.hk-acc{
  --hk-blue: #18396C;
  --hk-black: #111111;
  --hk-gray: #707070;
  --hk-green: #308426;
  --hk-border: rgba(24, 57, 108, 0.45);
  --hk-shadow: 0 0.75rem 2rem rgba(17, 17, 17, 0.10);

  --r-24: clamp(1.5rem, 1.5rem, 1.5rem);
  --r-48: clamp(3rem, 3rem, 3rem);

  --pill-h: clamp(3.125rem, 3.125rem, 3.125rem);     /* 50px */
  --pill-pad: clamp(1.75rem, 1.75rem, 1.75rem);      /* 28px */

  --line-h: clamp(0.125rem, 0.125rem, 0.125rem);     /* 2px */
  --gap: clamp(1.25rem, 1.25rem, 1.25rem);           /* 20px */

  --toggle-sz: clamp(3.125rem, 3.125rem, 3.125rem);  /* 50px */
  --toggle-r: clamp(0.875rem, 0.875rem, 0.875rem);   /* 14px */

  font-family: 'source_sans_proregular', system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: clamp(1.0625rem, 1.0625rem, 1.0625rem); /* 17px */
  line-height: 1.35;
  color: var(--hk-black);
}

.hk-acc,
.hk-acc *{
  box-sizing: border-box;
}

.hk-panel{
  margin-block: clamp(1.25rem, 1.25rem, 1.25rem);
}

/* =========================================================
   HEADER: Pill links, Linie rechts, Toggle mittig unter Header
========================================================= */

.hk-panel__header{
  position: relative;
  display: flex;
  align-items: center;
  gap: 0;
  margin: 4rem 0 0 0;
  min-height: var(--pill-h);
}

/* Pill: Auto-Breite (Text) */
.hk-pill{
  display: inline-flex;
  flex: 0 0 auto;
  width: auto;
  white-space: nowrap;
  align-items: center;
  height: var(--pill-h);
  padding-inline: var(--pill-pad);
  border-radius: var(--r-24);
  background: var(--hk-blue);
  color: #ffffff;
  font-weight: normal;
  font-size: clamp(1.3125rem, 1.3125rem, 1.3125rem); /* 21px */
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

/* Linie: komplette Restbreite */
.hk-rule{
  flex: 1 1 auto;
  height: var(--line-h);
  border-radius: 999rem;
  background: var(--hk-blue);
  opacity: 0.9;
}

/* Toggle: mittig unter dem Header */
.hk-toggle{
  position: absolute;
  left: 50%;
  top: 100%;
  transform: translate(-50%, -50%);
  width: var(--toggle-sz);
  height: var(--toggle-sz);
  border-radius: 0 0 var(--toggle-r) var(--toggle-r);
  appearance: none;
  -webkit-appearance: none;
  border: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  background: var(--hk-blue) !important;
  color: #ffffff !important;
  line-height: 1 !important;
  font: inherit !important;
  text-transform: none !important;
  display: grid !important;
  place-items: center !important;
  cursor: pointer;
  box-shadow: 0 0.6rem 1.4rem rgba(17, 17, 17, 0.36);
  z-index: 2;
  transition: filter 200ms ease-in-out;
}

.hk-toggle:hover{
  filter: brightness(1.03);
}

.hk-toggle:focus-visible{
  outline: clamp(0.1875rem, 0.1875rem, 0.1875rem) solid rgba(255, 245, 128, 0.95);
  outline-offset: clamp(0.1875rem, 0.1875rem, 0.1875rem);
}

/* SVG-Icon fix */
.hk-toggle__icon{
  width: clamp(1.8rem, 1.6rem + 0.6vw, 2.6rem);
  height: clamp(1.8rem, 1.6rem + 0.6vw, 2.6rem);
  display: block;
  transition: transform 320ms ease-in-out;
}

.hk-toggle__icon polyline{
  fill: none;
  stroke: #ffffff;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.hk-toggle:hover .hk-toggle__icon polyline{
  stroke: #FFF580;
}

.hk-panel.is-open .hk-toggle__icon{
  transform: rotate(180deg);
}

/* =========================================================
   Body Animation
========================================================= */

.hk-panel__body{
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  border-radius: var(--r-24);
  box-shadow: 0 0.75rem 1.875rem rgba(0, 0, 0, 0.19);
  transform: translateY(-0.25rem);
  transition:
    max-height 420ms ease-in-out,
    opacity 240ms ease-in-out,
    transform 240ms ease-in-out;
}

.hk-panel.is-open .hk-panel__body{
  opacity: 1;
  transform: translateY(0);
}

/* =========================================================
   Weiße Box wie Screenshot
========================================================= */

.hk-box{
  margin-top: clamp(0.6rem, 0.6rem, 0.6rem);
  padding: clamp(1.75rem, 1.75rem, 1.75rem); /* 28px */
  background: #ffffff;
  border: clamp(0.125rem, 0.125rem, 0.125rem) solid var(--hk-border);
  border-radius: var(--r-24);
  overflow: hidden;
  background-clip: padding-box;
}

/* =========================================================
   Cards: 2 Spalten, 2 Reihen
========================================================= */

.hk-cards{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2.25rem, 2.25rem, 2.25rem); /* 36px */
}

@media (max-width: 56.25rem){
  .hk-cards{
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   Card: Bild links, Text rechts – stabil
========================================================= */

.hk-card{
  display: flex;
  align-items: flex-start;
  gap: clamp(1.25rem, 1.05rem + 0.8vw, 1.75rem);
}

.hk-card__media{
  flex: 0 0 auto;
}

.hk-card__content{
  flex: 1 1 auto;
  min-width: 0;
  padding-top: 1rem;
}

.hk-card__img{
  display: block;
  height: clamp(10rem, 9rem + 2vw, 14rem);
  width: auto;
  max-width: 100%;
  object-fit: cover;
  border-radius: var(--r-24);
}

/* Platzhalterbild */
.hk-card__img--ph{
  position: relative;
  overflow: hidden;
  border-radius: var(--r-24);
  background:
    radial-gradient(circle at 40% 32%, rgba(255, 255, 255, 0.85), rgba(255, 255, 255, 0) 55%),
    linear-gradient(135deg, rgba(24, 57, 108, 0.20), rgba(48, 132, 38, 0.10));
}

.hk-card__img--ph::after{
  content: "";
  position: absolute;
  inset:
    clamp(1.8rem, 1.5rem + 0.8vw, 2.6rem)
    clamp(2.6rem, 2rem + 1.5vw, 4rem)
    clamp(2rem, 1.6rem + 0.8vw, 2.8rem)
    clamp(2.6rem, 2rem + 1.5vw, 4rem);
  border-radius: 999rem;
  background: rgba(17, 17, 17, 0.18);
  filter: blur(0.18rem);
}

/* Typografie */
.hk-card__name{
  margin: 0 0 clamp(0.25rem, 0.25rem, 0.25rem) 0;
  color: var(--hk-blue);
  font-family: 'source_sans_prosemibold', Arial, sans-serif;
  font-weight: normal;
  font-size: clamp(1.375rem, 1.375rem, 1.375rem); /* 22px */
  line-height: 1.45;
}

.hk-card__name--black{
  color: var(--hk-black);
}

.hk-card__role{
  margin: 0 0 clamp(0.75rem, 0.75rem, 0.75rem) 0;
  font-size: clamp(0.8rem, 0.75rem + 0.4vw, 1rem);
  font-family: 'Droid-Serif', Times, serif;
  font-weight: normal;
  line-height: 1.35;
}

/* =========================================================
   Meta-Bereich: Icon im Link integriert
========================================================= */

.hk-card__meta{
  font-size: 0.85rem;
  font-family: 'Droid-Serif', Times, serif;
  font-weight: normal;
  line-height: 1.55;
}

.hk-meta__link{
  display: inline-flex;
  align-items: center;
  gap: clamp(0.4rem, 0.35rem + 0.2vw, 0.6rem);
  max-width: 100%;
  color: var(--hk-blue);
  text-decoration: underline;
  text-decoration-thickness: 0.06em;
  text-underline-offset: 0.16em;
  overflow-wrap: anywhere;
  word-break: break-word;
  hyphens: auto;
}

.hk-meta__link + .hk-meta__link{
  margin-top: clamp(0.25rem, 0.2rem + 0.2vw, 0.4rem);
}

.hk-meta__link img{
  width: clamp(0.85rem, 0.8rem + 0.2vw, 0.95rem);
  height: auto;
  flex: 0 0 auto;
  display: block;
  transition: filter 180ms ease-in-out;
}

.hk-meta__link span{
  min-width: 0;
}

.hk-meta__link:hover{
  color: var(--hk-green);
}

.hk-meta__link:hover img{
  filter: brightness(0) saturate(100%) invert(37%) sepia(67%) saturate(796%) hue-rotate(72deg) brightness(92%) contrast(88%);
}

.hk-meta__link:focus-visible{
  outline: 0.125rem solid rgba(48, 132, 38, 0.35);
  outline-offset: 0.125rem;
  border-radius: 0.25rem;
}

/* Rückwärtskompatibilität für altes Markup */
.hk-meta__item{
  display: flex;
  align-items: center;
  gap: clamp(0.4rem, 0.35rem + 0.2vw, 0.6rem);
}

.hk-meta__item + .hk-meta__item{
  margin-top: clamp(0.25rem, 0.2rem + 0.2vw, 0.4rem);
}

.hk-meta__icon{
  width: clamp(0.85rem, 0.8rem + 0.2vw, 0.95rem);
  height: auto;
  flex-shrink: 0;
  display: block;
}

/* Hilfstext */
.hk-muted{
  margin: 0;
  color: var(--hk-gray);
}

/* Visually hidden */
.hk-vh{
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* =========================================================
   Mobile: Card untereinander
========================================================= */

@media (max-width: 36rem){

  .hk-acc{
    --pill-h: clamp(2.6rem, 2.6rem, 2.6rem);
    --pill-pad: clamp(1rem, 1rem, 1rem);
    --toggle-sz: clamp(2.5rem, 2.5rem, 2.5rem);
  }

  .hk-pill{
    font-size: clamp(0.95rem, 0.95rem, 0.95rem);
    letter-spacing: clamp(0.18rem, 0.18rem, 0.18rem);
  }

  .hk-toggle{
    left: auto;
    right: 0;
    top: 100%;
    transform: translateY(-50%);
  }

  .hk-box{
    padding: clamp(1.1rem, 1.1rem, 1.1rem);
  }

  .hk-card{
    flex-direction: column;
    gap: clamp(0.9rem, 0.9rem, 0.9rem);
  }

  .hk-card__media{
    width: 100%;
    display: flex;
    justify-content: center;
  }

  .hk-card__img{
    height: 25rem;
    width: auto;
    max-width: 100%;
  }

  .hk-card__content,
  .hk-card__meta{
    padding-top: 0;
    overflow-wrap: anywhere;
    word-break: break-word;
    hyphens: auto;
  }

  .hk-meta__link{
    display: inline-flex;
    max-width: 100%;
  }
}