/* KLMI site-wide CSS fixes — load after theme stylesheets */

/* Prevent broken global link sizing from affecting layout */
a {
  width: auto;
  max-width: none;
}

/* Event blocks — center content and Register Online button */
.event4,
.event1,
.event2,
.event3 {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.event4 .kivpaynow,
.event1 .kivpaynow,
.event2 .kivpaynow,
.event3 .kivpaynow {
  display: block;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

/* Homepage header navigation */
.landing .navbar {
  flex-wrap: wrap;
  align-items: center;
  height: auto;
  min-height: 6vh;
  background-color: rgba(0, 0, 0, 0.88);
}

.landing .navbar > .container {
  flex: 0 0 auto;
}

.landing .container-12 {
  flex: 1 1 auto;
  flex-wrap: nowrap;
  justify-content: center;
  align-items: center;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.landing .container-12::-webkit-scrollbar {
  display: none;
}

.landing .container-12 .heading-10,
.landing .container-12 .menu_hometxt,
.landing .navbar .home_link,
.landing .navbar .events_link,
.landing .navbar .give_link,
.landing .navbar .sermons_link,
.landing .navbar .location_link,
.landing .navbar .contact_link {
  color: #fff;
}

.landing .heading-10,
.landing .menu_hometxt {
  color: #fff;
  margin-top: 0;
}

.landing .menu-button:empty {
  display: none;
}

/* Google sign-in icon (Font Awesome CDN) */
.text-span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-right: 6px;
}

.text-span .fa-google {
  font-size: 1.05em;
  line-height: 1;
}

.sermons-page .sermonsignin {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
}

/* Navigation */
.container-12 {
  flex-wrap: wrap;
  gap: 4px 8px;
  height: auto;
  min-height: 6vh;
  padding: 4px 12px;
  width: 100%;
}

.navlinkall {
  width: auto;
  flex: 0 1 auto;
  margin-left: 12px;
  margin-right: 12px;
  height: auto;
  min-height: 44px;
}

.container-12 a,
.navlinkall a,
.home_link,
.events_link,
.give_link,
.sermons_link,
.location_link,
.contact_link {
  width: auto;
  text-decoration: none;
  display: inline-block;
}

/* Buttons */
.kivpaynow,
.w-button,
.submit-button {
  width: auto;
  min-width: 160px;
  max-width: 100%;
  text-decoration: none;
}

.submit-button {
  min-width: 120px;
}

/* Address links in locations section */
.churchinfo a.link,
.churchinfo a.link-2 {
  width: auto;
  display: inline;
  text-decoration: underline;
}

/* Social icon blocks */
.link-block-2,
.link-block-3,
.link-block-4,
.w-inline-block img {
  width: auto;
  max-width: 100%;
}

/* Page overflow */
html {
  overflow-x: hidden;
}

body {
  overflow-x: hidden;
}

.body-2 {
  overflow-y: auto;
}

/* Contact section — avoid rigid 100vh clipping on small screens */
.contact {
  height: auto;
  min-height: 100vh;
  padding: 40px 0;
}

/* Remove sermon hacks that leaked from main stylesheet */
.column-99 {
  margin-left: 0;
  border: none;
}

.sermonAudio {
  position: static;
  width: 100%;
  margin: 0;
}

/* Donate / registration sub-sites */
.donatemain,
.regmain {
  min-height: 100vh;
  height: auto;
}

@media screen and (max-width: 767px) {
  .landing .navbar {
    flex-direction: column;
    align-items: stretch;
  }

  .landing .navbar > .container {
    width: 100%;
  }

  .landing .container-12 {
    flex: 1 1 100%;
    width: 100%;
  }

  .landing .brand {
    display: flex !important;
    width: auto;
    height: 44px;
    margin-left: auto;
    margin-right: auto;
  }

  .landing .menu-button {
    display: none;
  }

  .landing .container-12 {
    justify-content: center;
    padding: 6px 8px;
    gap: 0;
  }

  .landing .navlinkall {
    margin-left: 4px;
    margin-right: 4px;
    min-height: 32px;
    flex: 0 0 auto;
  }

  .landing .heading-10,
  .landing .menu_hometxt {
    font-size: 11px;
    white-space: nowrap;
  }

  .container-12 {
    justify-content: center;
    padding: 8px;
  }

  .navlinkall {
    margin-left: 6px;
    margin-right: 6px;
    min-height: 40px;
  }

  .heading-10,
  .menu_hometxt {
    font-size: 14px;
  }

  .kivpaynow,
  .w-button {
    min-width: 140px;
    font-size: 14px;
  }
}
