/*
 * Heidenheim.info – Service-Seite 0.1.198
 * Eigenständige Suche, kompakte/homogene Hauptkacheln und Ergebnis-Teaser.
 */

/* Suche bewusst NICHT mehr mit .hi-service-search klassifizieren.
   Dadurch greifen die historischen CI-Regeln mit >input/>button nicht mehr. */
body:not(.home) .hi-service-portal .hi-service-finder{
  display:grid!important;
  grid-template-columns:minmax(0,1fr) 180px 112px!important;
  gap:7px!important;
  align-items:stretch!important;
  width:min(720px,calc(100% - 32px))!important;
  max-width:720px!important;
  margin:18px auto 0!important;
  padding:6px!important;
  box-sizing:border-box!important;
  border:1px solid rgba(207,220,222,.95)!important;
  border-radius:17px!important;
  background:rgba(255,255,255,.96)!important;
  box-shadow:0 10px 28px rgba(18,49,72,.12)!important;
}
body:not(.home) .hi-service-portal .hi-service-finder>:is(.hi-service-finder__query,.hi-service-finder__municipality,.hi-service-finder__submit){
  display:block!important;
  min-width:0!important;
  width:100%!important;
  margin:0!important;
  padding:0!important;
}
body:not(.home) .hi-service-portal .hi-service-finder :is(input:not([type="hidden"]),select,button){
  display:block!important;
  width:100%!important;
  min-width:0!important;
  max-width:none!important;
  height:42px!important;
  min-height:42px!important;
  margin:0!important;
  box-sizing:border-box!important;
  border-radius:11px!important;
  font:inherit!important;
}
body:not(.home) .hi-service-portal .hi-service-finder :is(input:not([type="hidden"]),select){
  padding:0 11px!important;
  border:1px solid #cbd8db!important;
  background:#fff!important;
  color:#26383d!important;
  box-shadow:none!important;
}
body:not(.home) .hi-service-portal .hi-service-finder button{
  padding:0 12px!important;
  border:0!important;
  background:#16844a!important;
  color:#fff!important;
  font-weight:850!important;
  white-space:nowrap!important;
  cursor:pointer!important;
}
body:not(.home) .hi-service-portal .hi-service-finder button:hover,
body:not(.home) .hi-service-portal .hi-service-finder button:focus-visible{
  background:#126c3d!important;
}

/* Hauptkacheln: dichter, gleiche Breite/Höhe, zweite Reihe sauber zentriert. */
body:not(.home) .hi-service-portal .hi-service-navigation{
  width:100%!important;
  margin:24px 0 0!important;
}
body:not(.home) .hi-service-portal .hi-service-navigation__head{
  margin:0 auto 13px!important;
}
body:not(.home) .hi-service-portal .hi-service-topic-grid--compact327{
  display:flex!important;
  flex-flow:row wrap!important;
  justify-content:center!important;
  align-items:stretch!important;
  gap:12px!important;
  width:min(1120px,100%)!important;
  max-width:1120px!important;
  margin:0 auto!important;
  padding:0!important;
}
body:not(.home) .hi-service-portal .hi-service-topic-grid--compact327>.hi-service-topic{
  flex:0 0 calc((100% - 36px)/4)!important;
  width:calc((100% - 36px)/4)!important;
  max-width:calc((100% - 36px)/4)!important;
  min-width:0!important;
  min-height:86px!important;
  height:auto!important;
  margin:0!important;
  padding:13px 14px!important;
  box-sizing:border-box!important;
  align-self:stretch!important;
  grid-template-columns:40px minmax(0,1fr) 18px!important;
  column-gap:10px!important;
  row-gap:2px!important;
  border-radius:15px!important;
}
body:not(.home) .hi-service-portal .hi-service-topic-grid--compact327>.hi-service-topic::before{
  width:36px!important;
  height:36px!important;
  font-size:16px!important;
}
body:not(.home) .hi-service-portal .hi-service-topic-grid--compact327>.hi-service-topic::after{
  font-size:17px!important;
}
body:not(.home) .hi-service-portal .hi-service-topic-grid--compact327 .hi-service-topic__title{
  font-size:.92rem!important;
  line-height:1.18!important;
}
body:not(.home) .hi-service-portal .hi-service-topic-grid--compact327 .hi-service-topic__meta{
  font-size:.69rem!important;
  line-height:1.16!important;
}

/* Untergruppen bleiben erhalten, rücken aber optisch näher an die Hauptauswahl. */
body:not(.home) .hi-service-portal .hi-service-subgroups{
  width:min(1120px,100%)!important;
  max-width:1120px!important;
  margin:20px auto 26px!important;
}

/* Ergebnis-Teaser wie auf den anderen Verzeichnis-Seiten. */
body:not(.home) .hi-service-portal .hi-service-directory-section--preview{
  width:100%!important;
  margin-top:24px!important;
}
body:not(.home) .hi-service-portal .hi-service-directory-section--preview>.hi-service-portal__eyebrow,
body:not(.home) .hi-service-portal .hi-service-directory-section--preview>h2{
  text-align:center!important;
}
body:not(.home) .hi-service-portal .hi-service-directory-section--preview .hi-service-directory{
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  gap:14px!important;
  width:100%!important;
  max-width:none!important;
  margin:18px 0 0!important;
}
body:not(.home) .hi-service-portal .hi-service-directory-section--preview .hi-service-directory-card{
  min-width:0!important;
  height:100%!important;
}
body:not(.home) .hi-service-portal .hi-service-directory-section--preview .hi-directory-more{
  margin:22px 0 0!important;
  text-align:center!important;
}
body:not(.home) .hi-service-portal .hi-service-directory-section--preview .hi-directory-more__button{
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  min-height:44px!important;
  padding:.7rem 1.2rem!important;
  border:0!important;
  border-radius:999px!important;
  background:#0b7a75!important;
  color:#fff!important;
  font-weight:850!important;
  text-decoration:none!important;
}
body:not(.home) .hi-service-portal .hi-service-directory-section--preview .hi-directory-more__button:hover,
body:not(.home) .hi-service-portal .hi-service-directory-section--preview .hi-directory-more__button:focus-visible{
  background:#086762!important;
}

@media (max-width:980px){
  body:not(.home) .hi-service-portal .hi-service-topic-grid--compact327>.hi-service-topic{
    flex-basis:calc((100% - 12px)/2)!important;
    width:calc((100% - 12px)/2)!important;
    max-width:calc((100% - 12px)/2)!important;
  }
  body:not(.home) .hi-service-portal .hi-service-directory-section--preview .hi-service-directory{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
  }
}
@media (max-width:820px){
  body:not(.home) .hi-service-portal .hi-service-finder{
    grid-template-columns:1fr!important;
    width:min(620px,calc(100% - 24px))!important;
  }
  body:not(.home) .hi-service-portal .hi-service-finder :is(input:not([type="hidden"]),select,button){
    height:46px!important;
    min-height:46px!important;
  }
}
@media (max-width:560px){
  body:not(.home) .hi-service-portal .hi-service-topic-grid--compact327>.hi-service-topic{
    flex-basis:100%!important;
    width:100%!important;
    max-width:100%!important;
  }
  body:not(.home) .hi-service-portal .hi-service-directory-section--preview .hi-service-directory{
    grid-template-columns:1fr!important;
  }
}
