/* IHBS Homepage Overhaul – structure, splash, sections (2026) */

.skip-link {
  position: absolute;
  left: -9999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
  z-index: 2147483647;
  background: #111820;
  color: #fff;
  padding: 12px 18px;
  border-radius: 8px;
  font-weight: 700;
  text-decoration: none;
}
.skip-link:focus {
  left: 12px;
  top: 12px;
  width: auto;
  height: auto;
  overflow: visible;
}

/* Splash – subtle IHBS gold/blue branding */
#ihbs-splash-final {
  flex-direction: column;
  gap: 22px;
  background: radial-gradient(circle at 50% 38%, #ffffff 0%, #f8f9fb 55%, #eef1f5 100%) !important;
  animation: ihbsSplashFadeOut 0.55s ease 3.75s forwards !important;
}
.ihbs-splash-stage {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
}
.ihbs-splash-logo-wrap {
  position: relative;
  z-index: 2;
}
.ihbs-splash-icons {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: clamp(10px, 2.4vw, 16px);
  width: min(100%, 340px);
  margin: 0 auto;
  pointer-events: none;
}
.ihbs-splash-icon {
  position: relative;
  opacity: 0;
  flex: 0 0 auto;
  animation: ihbsSplashIconIn 0.95s cubic-bezier(0.19, 1, 0.22, 1) forwards;
}
.ihbs-splash-icon-badge {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
  background: linear-gradient(160deg, #ffffff 0%, #f7f9fc 52%, #eef2f7 100%);
  border: 1px solid rgba(201, 162, 39, 0.42);
  box-shadow:
    0 14px 28px rgba(17, 24, 32, 0.14),
    0 2px 0 rgba(255, 255, 255, 0.95) inset,
    0 0 0 1px rgba(255, 255, 255, 0.65) inset;
}
.ihbs-splash-icon-badge::before {
  content: "";
  position: absolute;
  inset: 4px;
  border-radius: 12px;
  background: radial-gradient(circle at 30% 22%, rgba(255, 255, 255, 0.95), transparent 58%);
  pointer-events: none;
}
.ihbs-splash-icon-badge-red {
  border-color: rgba(213, 31, 38, 0.34);
  box-shadow:
    0 14px 28px rgba(17, 24, 32, 0.14),
    0 0 0 1px rgba(213, 31, 38, 0.08),
    0 2px 0 rgba(255, 255, 255, 0.95) inset;
}
.ihbs-splash-icon svg {
  position: relative;
  z-index: 1;
  display: block;
  width: 30px;
  height: 30px;
  filter: drop-shadow(0 2px 4px rgba(17, 24, 32, 0.08));
}
.ihbs-splash-icon-calc {
  animation-delay: 0.15s;
}
.ihbs-splash-icon-house {
  animation-delay: 0.5s;
}
.ihbs-splash-icon-seal {
  animation-delay: 0.85s;
}
.ihbs-splash-icon-doc {
  animation-delay: 1.2s;
}
.ihbs-splash-stars {
  position: absolute;
  inset: -10px -16px -8px -16px;
  pointer-events: none;
}
.ihbs-splash-star {
  position: absolute;
  line-height: 1;
  color: #c9a227;
  text-shadow: 0 0 10px rgba(201, 162, 39, 0.85), 0 0 16px rgba(255, 255, 255, 0.75);
  opacity: 0;
  font-size: 13px;
  animation: ihbsSplashStarBlink 0.4s ease-in-out forwards;
}
.ihbs-splash-star-1 { top: -4px; left: 50%; margin-left: -18px; animation-delay: 2.35s; }
.ihbs-splash-star-2 { top: 10px; left: -2px; animation-delay: 2.75s; }
.ihbs-splash-star-3 { top: 10px; right: -2px; animation-delay: 3.15s; }
#ihbs-splash-logo-final {
  animation: ihbsSplashLogoIn 0.82s cubic-bezier(0.19, 1, 0.22, 1) 1.55s both,
    ihbsSplashLogoPulse 1.4s ease-in-out 2.37s 1 !important;
  transform-origin: center center !important;
}
.ihbs-splash-progress {
  width: min(200px, 52vw);
  height: 3px;
  border-radius: 999px;
  background: rgba(17, 24, 32, 0.08);
  overflow: hidden;
  opacity: 0;
  animation: ihbsSplashProgressShow 0.4s ease 1.6s forwards;
}
.ihbs-splash-progress span {
  display: block;
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, #c9a227 0%, #d51f26 100%);
  animation: ihbsSplashProgressFill 2.4s ease-in-out 1.6s forwards;
}
@keyframes ihbsSplashIconIn {
  0% { opacity: 0; transform: translateY(-32px) scale(0.84); filter: blur(4px); }
  100% { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); }
}
@keyframes ihbsSplashStarBlink {
  0%, 100% { opacity: 0; transform: scale(0.55) rotate(0deg); }
  35%, 65% { opacity: 1; transform: scale(1.18) rotate(8deg); }
}
@keyframes ihbsSplashLogoIn {
  0% { opacity: 0; transform: scale(0.88) translateY(14px); filter: blur(4px); }
  100% { opacity: 1; transform: scale(1) translateY(0); filter: blur(0); }
}
@keyframes ihbsSplashLogoPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.018); }
}
@keyframes ihbsSplashProgressShow {
  to { opacity: 1; }
}
@keyframes ihbsSplashProgressFill {
  to { width: 100%; }
}
@keyframes ihbsSplashFadeOut {
  to { opacity: 0; visibility: hidden; }
}
@media (max-width: 520px) {
  .ihbs-splash-icons { gap: 8px; width: min(100%, 280px); }
  .ihbs-splash-icon-badge { width: 46px; height: 46px; border-radius: 14px; }
  .ihbs-splash-icon svg { width: 26px; height: 26px; }
}
@media (prefers-reduced-motion: reduce) {
  #ihbs-splash-final { animation: ihbsSplashFadeOut 0.01s ease 0.5s forwards !important; }
  #ihbs-splash-logo-final,
  .ihbs-splash-progress,
  .ihbs-splash-progress span,
  .ihbs-splash-icon,
  .ihbs-splash-star { animation: none !important; opacity: 1 !important; transform: none !important; filter: none !important; }
  .ihbs-splash-star { opacity: 0 !important; }
  .ihbs-splash-progress span { width: 100% !important; }
}

/* Section landmarks */
main > section {
  scroll-margin-top: 140px;
}
.section-eyebrow {
  font-weight: 800;
  color: #b21f24;
  letter-spacing: 0.02em;
  margin: 0 0 10px;
  font-size: 14px;
  text-transform: uppercase;
}

/* Hero block */
#hero.home-hero-block .top-hero-image img {
  width: 100%;
  height: auto;
  display: block;
}
#hero.home-hero-block .home-hero-copy {
  margin-top: 0;
}

/* Region */
#region .region-grid {
  display: grid;
  gap: clamp(24px, 4vw, 48px);
}
#region .region-features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 18px 48px;
}
#region .region-features article {
  background: #fff;
  border: 1px solid rgba(17, 24, 32, 0.08);
  border-radius: 18px;
  padding: 20px 18px;
  box-shadow: 0 8px 24px rgba(17, 24, 32, 0.06);
}
#region .region-features strong {
  display: block;
  font-size: 1.05rem;
  margin-bottom: 6px;
  color: #111820;
}
#region .region-features span {
  color: #5f6670;
  font-size: 0.95rem;
  line-height: 1.45;
}

/* Tilgungsrechner CTA */
#tilgungsrechner.ihbs-tilgung-section {
  padding: clamp(40px, 6vw, 72px) 18px;
  background: linear-gradient(180deg, #faf8f5 0%, #fff 100%);
}
#tilgungsrechner .ihbs-tilgung-card {
  max-width: 1180px;
  margin: 0 auto;
  background: #fff;
  border: 1px solid #ead2d2;
  border-radius: 24px;
  padding: clamp(24px, 4vw, 40px);
  box-shadow: 0 14px 40px rgba(17, 24, 32, 0.08);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: center;
}
#tilgungsrechner .ihbs-tilgung-card h2 {
  font-size: clamp(24px, 3.2vw, 36px);
  line-height: 1.12;
  margin: 0 0 10px;
  letter-spacing: -0.03em;
}
#tilgungsrechner .ihbs-tilgung-card p {
  margin: 0;
  color: #5f6670;
  line-height: 1.55;
  max-width: 640px;
}
#tilgungsrechner .ihbs-tilgung-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: stretch;
}
#tilgungsrechner .ihbs-tilgung-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  border-radius: 999px;
  padding: 14px 22px;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}
#tilgungsrechner .ihbs-tilgung-primary {
  background: #c40000;
  color: #fff !important;
  box-shadow: 0 8px 22px rgba(196, 0, 0, 0.22);
}
#tilgungsrechner .ihbs-tilgung-note {
  font-size: 13px;
  color: #888;
  text-align: center;
}

/* Vermietung promos */
#vermietung .mietangebot-promo {
  max-width: 1180px;
  margin: 0 auto 32px;
  padding: 0 18px;
}
#vermietung .mietangebot-promo a.promo-card {
  display: grid;
  grid-template-columns: 180px 1fr auto;
  gap: 18px;
  align-items: center;
  background: #fff;
  border: 2px solid #b21f24;
  border-radius: 24px;
  padding: 16px;
  text-decoration: none;
  color: #111820;
  box-shadow: 0 14px 34px rgba(178, 31, 36, 0.14);
}
#vermietung .mietangebot-promo a.promo-card img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  border-radius: 16px;
}
#vermietung .mietangebot-promo .promo-kicker {
  font-weight: 900;
  color: #b21f24;
  margin-bottom: 4px;
}
#vermietung .mietangebot-promo .promo-cta {
  background: #b21f24;
  color: #fff;
  border-radius: 999px;
  padding: 13px 18px;
  font-weight: 900;
  white-space: nowrap;
}
#vermietung .mietangebot-grid {
  max-width: 1180px;
  margin: 48px auto 0;
  padding: 0 18px;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 26px;
  align-items: center;
}
#vermietung .mietangebot-grid img {
  width: 100%;
  border-radius: 24px;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.16);
}

/* Über uns grouping */
#ueber-uns {
  background: linear-gradient(180deg, #fff 0%, #f7f8fa 100%);
}

/* Kontakt section anchor */
#kontakt.kontakt-section {
  scroll-margin-top: 140px;
}

/* Footer tilgung removed – consolidated in #tilgungsrechner */

@media (max-width: 860px) {
  main > section { scroll-margin-top: 132px; }
  #tilgungsrechner .ihbs-tilgung-card {
    grid-template-columns: 1fr;
    text-align: center;
  }
  #tilgungsrechner .ihbs-tilgung-card p { margin: 0 auto; }
  #vermietung .mietangebot-promo a.promo-card {
    grid-template-columns: 1fr;
  }
  #vermietung .mietangebot-promo .promo-cta { text-align: center; }
  #vermietung .mietangebot-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 430px) {
  main > section { scroll-margin-top: 128px; }
}

/* Mehrsprachigkeit */
.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.lang-switch{display:flex;align-items:center;flex:0 0 auto;margin-left:8px}
.lang-select-wrap{display:inline-flex;align-items:center;gap:6px;background:rgba(255,255,255,.92);padding:6px 10px;border-radius:999px;border:1px solid rgba(17,24,32,.1);box-shadow:0 4px 14px rgba(0,0,0,.08)}
.lang-flag{width:20px;height:14px;object-fit:cover;border-radius:2px;box-shadow:0 0 0 1px rgba(17,24,32,.12);flex-shrink:0;display:block}
.lang-select{
  appearance:none;-webkit-appearance:none;
  border:none;background:transparent;
  font:inherit;font-size:13px;font-weight:750;color:#111820;
  padding:2px 22px 2px 2px;cursor:pointer;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='%23111820' d='M1 1l4 4 4-4'/%3E%3C/svg%3E");
  background-repeat:no-repeat;background-position:right 2px center;
}
.lang-select:focus{outline:2px solid rgba(213,31,38,.35);outline-offset:2px;border-radius:4px}
@media(max-width:980px){.lang-switch{order:2;margin-left:auto}.header .call-top{order:3}}
@media(max-width:740px){.lang-select-wrap{padding:5px 8px}.lang-flag{width:18px;height:13px}.lang-select{font-size:12px;min-width:84px}}
