.home-modern-overview {
  background:
    radial-gradient(circle at 8% 10%, rgba(20, 184, 166, 0.12), transparent 28%),
    radial-gradient(circle at 92% 18%, rgba(251, 146, 60, 0.14), transparent 26%),
    linear-gradient(180deg, #f8fffc 0%, #ffffff 74%);
  padding: 54px 0 34px;
  position: relative;
}

.home-modern-community + section {
  display: none;
}

/* Compact second CTA and continuous community gallery. */
.main-content > section[hidden] { display: none !important; }
.home-join-cta { background: #145548; padding: 30px 0; }
.home-join-cta .container { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.home-join-cta h2 { color: #fff; font-size: 30px; line-height: 1.2; margin: 0 0 8px; }
.home-join-cta p { color: #d5eae3; margin: 0; font-size: 16px; }
.home-join-cta a { flex-shrink: 0; gap: 12px; }
.home-gallery-section { padding: 42px 0; overflow: hidden; }
.home-gallery-heading { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 24px; }
.home-gallery-heading h2 { margin: 8px 0 0; font-size: 30px; color: #153e32; }
.home-gallery-heading > a { color: #0f766e; font-weight: 600; }
/* Bootstrap clearfix pseudo-elements must not become flex items. */
.home-join-cta > .container:before,
.home-join-cta > .container:after,
.home-gallery-heading.container:before,
.home-gallery-heading.container:after {
  display: none;
}
.home-join-cta > .container {
  padding-top: 0;
  padding-bottom: 0;
}
.home-gallery-heading.container {
  padding-top: 0;
  padding-bottom: 0;
}
.home-gallery-window { overflow: hidden; }
.home-gallery-track { display: flex; width: max-content; animation: homeGallerySlide 40s linear infinite; }
.home-gallery-group { display: flex; gap: 18px; padding-right: 18px; }
.home-gallery-group a { display: block; width: 300px; flex-shrink: 0; }
.home-gallery-group img { width: 100%; height: 220px; object-fit: cover; border-radius: 18px; display: block; }
.home-gallery-window:hover .home-gallery-track, .home-gallery-window:focus-within .home-gallery-track { animation-play-state: paused; }
@keyframes homeGallerySlide { to { transform: translateX(-50%); } }
@media (max-width: 767px) {
  .home-join-cta .container { flex-direction: column; align-items: flex-start; }
  .home-gallery-heading { flex-direction: column; align-items: flex-start; }
  .home-gallery-group a { width: 250px; }
}
@media (prefers-reduced-motion: reduce) {
  .home-gallery-track { animation: none; }
  .home-gallery-window { overflow-x: auto; }
}

.home-mission-cta {
  background: linear-gradient(rgba(12, 44, 38, 0.82), rgba(12, 44, 38, 0.88)), url('../media/slider2.jpeg') center 45% / cover;
  padding: 48px 0;
  text-align: center;
}

.home-mission-cta h2 {
  color: #ffffff;
  font-size: clamp(26px, 3.4vw, 46px);
  font-weight: 700;
  line-height: 1.2;
  margin: 0 0 18px;
  text-transform: uppercase;
}

.home-mission-cta p {
  color: #ffffff;
  font-size: 19px;
  margin: 0;
}

.home-modern-community {
  background: #f8fffc;
  padding: 32px 0;
}

.home-modern-community .home-secondary-grid {
  margin-top: 0;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  align-items: start;
}

.home-work-card { padding: 28px; }
.home-work-card h2 { color: #102a1f; font-size: 32px; line-height: 1.2; margin: 12px 0 18px; }
.home-work-card p { color: #526273; font-size: 16px; line-height: 1.7; }
.home-work-list { list-style: none; padding: 0; margin: 24px 0; }
.home-work-list li { display: flex; gap: 16px; margin-bottom: 22px; }
.home-work-list i { color: #0f766e; background: #e2f5ed; border-radius: 12px; padding: 14px; align-self: start; }
.home-work-list h3 { margin: 0 0 6px; font-size: 19px; }
.home-work-list p { margin: 0; font-size: 14px; }
.home-modern-chairman .home-chairman-message { margin: 18px 0; font-weight: 400; line-height: 1.7; }
.home-notice-facts-row {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 26px;
  margin-top: 32px;
  align-items: stretch;
}
.home-notice-facts-row .home-info-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin: 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  overflow: visible;
}
.home-info-facts > div {
  background: #ffffff;
  border: 1px solid #dcebe5;
  border-radius: 18px;
  padding: 20px;
  box-shadow: 0 8px 24px rgba(15, 51, 40, 0.05);
}
.home-info-facts > div:nth-child(2),
.home-info-facts > div:nth-child(3) { background: #edf8f3; }
.home-info-facts i { color: #0f766e; font-size: 24px; display: block; margin-bottom: 12px; }
.home-modern-stats.home-info-facts strong { color: #153e32; font-size: 20px; font-weight: 700; }
.home-modern-stats.home-info-facts span { color: #587068; font-size: 13px; line-height: 1.5; }
@media (max-width: 767px) {
  .home-notice-facts-row { grid-template-columns: 1fr; }
  .home-modern-community .home-secondary-grid { grid-template-columns: 1fr; }
  .home-work-card { padding: 12px; }
}

.home-about-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  align-items: center;
  gap: 40px;
}

.home-about-photo {
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.1);
}

.home-about-photo img {
  display: block;
  width: 100%;
  height: 420px;
  object-fit: cover;
}

.home-about-layout .home-modern-intro {
  background: transparent;
  border: 0;
  box-shadow: none;
  padding: 16px 0;
}

.home-about-layout .home-modern-intro:before {
  display: none;
}

.home-secondary-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
  gap: 24px;
  margin-top: 40px;
}

.home-modern-grid {
  display: grid;
  gap: 22px;
  grid-template-columns: minmax(0, 1.35fr) minmax(260px, 0.75fr) minmax(300px, 0.9fr);
}

.home-modern-intro,
.home-modern-card,
.home-modern-stats {
  border: 1px solid rgba(15, 118, 110, 0.1);
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.08);
}

.home-modern-intro {
  background: #ffffff;
  border-radius: 28px;
  overflow: hidden;
  padding: 38px 36px;
  position: relative;
}

.home-modern-intro:before {
  background: linear-gradient(180deg, #0f766e, #f97316);
  border-radius: 999px;
  content: "";
  height: 76%;
  left: 0;
  position: absolute;
  top: 12%;
  width: 6px;
}

.home-modern-kicker,
.home-modern-card__body span,
.home-modern-card__head span {
  color: #0f766e;
  display: inline-block;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.home-modern-intro h2 {
  color: #102a1f;
  font-size: 36px;
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.12;
  margin: 12px 0 16px;
}

.home-modern-intro p {
  color: #526273;
  font-size: 16px;
  line-height: 1.72;
  margin: 0;
  max-width: 760px;
}

.home-modern-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 26px;
}

.home-modern-btn {
  align-items: center;
  border-radius: 999px;
  display: inline-flex;
  font-size: 14px;
  font-weight: 700;
  min-height: 44px;
  padding: 12px 19px;
  text-decoration: none;
  transition: all 0.2s ease;
}

.home-modern-btn:hover,
.home-modern-btn:focus {
  text-decoration: none;
  transform: translateY(-2px);
}

.home-modern-btn--primary {
  background: linear-gradient(135deg, #0f766e, #16a34a);
  box-shadow: 0 14px 26px rgba(15, 118, 110, 0.2);
  color: #ffffff;
}

.home-modern-btn--primary:hover,
.home-modern-btn--primary:focus {
  color: #ffffff;
}

.home-modern-btn--light {
  background: #ecfdf5;
  color: #0f766e;
}

.home-modern-card {
  background: #ffffff;
  border-radius: 24px;
  overflow: hidden;
}

.home-modern-card__image {
  background: #e8f7f2;
  height: 300px;
  overflow: hidden;
}

.home-modern-card__image img {
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.home-modern-card__body {
  padding: 22px;
}

.home-modern-card__body h3 {
  color: #102a1f;
  font-size: 26px;
  font-weight: 800;
  line-height: 1.15;
  margin: 0 0 5px;
}

.home-modern-card__body p {
  color: #64748b;
  font-size: 15px;
  font-weight: 600;
  margin: 0;
}

.home-modern-card__head {
  align-items: center;
  border-bottom: 1px solid rgba(15, 118, 110, 0.1);
  display: flex;
  justify-content: space-between;
  padding: 18px 20px 14px;
}

.home-modern-card__head a {
  color: #dc2626;
  font-size: 13px;
  font-weight: 800;
}

.home-modern-notice-window {
  height: 246px;
  overflow: hidden;
  position: relative;
}

.home-modern-notice-window:before,
.home-modern-notice-window:after {
  content: "";
  height: 34px;
  left: 0;
  pointer-events: none;
  position: absolute;
  right: 0;
  z-index: 2;
}

.home-modern-notice-window:before {
  background: linear-gradient(180deg, #ffffff, rgba(255, 255, 255, 0));
  top: 0;
}

.home-modern-notice-window:after {
  background: linear-gradient(0deg, #ffffff, rgba(255, 255, 255, 0));
  bottom: 0;
}

.home-modern-notice-track {
  animation: homeNoticeScroll 18s linear infinite;
}

.home-modern-notice-window:hover .home-modern-notice-track {
  animation-play-state: paused;
}

.home-modern-news-item {
  border-bottom: 1px solid #edf2f7;
  margin: 0;
  min-height: 82px;
  padding: 16px 20px;
}

.home-modern-news-item:last-child {
  border-bottom: 0;
}

.home-community-notices .home-modern-notice-window {
  height: 300px;
}

.home-community-notices .home-modern-news-item {
  box-sizing: border-box;
  height: 60px;
  min-height: 0;
  padding: 8px 20px;
  border-bottom: 1px solid #edf2f7;
}

.home-community-notices .home-modern-news-item time {
  margin-bottom: 3px;
  line-height: 16px;
}

.home-community-notices .home-modern-news-item h4 {
  line-height: 20px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.home-community-notices .home-modern-notice-window:before,
.home-community-notices .home-modern-notice-window:after {
  height: 8px;
}

.home-community-notices:focus-within .home-modern-notice-track {
  animation-play-state: paused;
}

@media (prefers-reduced-motion: reduce) {
  .home-community-notices .home-modern-notice-track { animation: none; }
  .home-community-notices .home-modern-notice-window { overflow-y: auto; }
}

.home-modern-news-item time {
  color: #64748b;
  display: block;
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 7px;
}

.home-modern-news-item h4 {
  font-size: 15px;
  font-weight: 700;
  line-height: 1.35;
  margin: 0;
}

.home-modern-news-item h4 a {
  color: #102a1f;
}

.home-modern-news-item h4 a:hover,
.home-modern-news-item h4 a:focus {
  color: #0f766e;
  text-decoration: none;
}

@keyframes homeNoticeScroll {
  0% {
    transform: translateY(0);
  }

  100% {
    transform: translateY(-50%);
  }
}

.home-modern-stats {
  background: #0f513f;
  border-radius: 24px;
  display: grid;
  gap: 1px;
  grid-template-columns: repeat(4, 1fr);
  margin-top: 22px;
  overflow: hidden;
}

.home-modern-stats div {
  background: rgba(255, 255, 255, 0.06);
  padding: 22px;
}

.home-modern-stats strong {
  color: #ffffff;
  display: block;
  font-size: 22px;
  font-weight: 800;
}

.home-modern-stats span {
  color: rgba(255, 255, 255, 0.74);
  display: block;
  font-size: 13px;
  margin-top: 4px;
}

#blog {
  background: #ffffff;
  padding: 48px 0 54px;
}

#blog .section-title {
  margin-bottom: 22px;
}

#blog .title {
  color: #102a1f;
  font-size: 34px;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 6px;
  text-transform: none;
}

#blog .double-line-bottom-theme-colored-2 {
  display: none;
}

#blog .post {
  background: #ffffff;
  border: 1px solid rgba(15, 118, 110, 0.1);
  border-radius: 24px;
  box-shadow: 0 18px 42px rgba(15, 23, 42, 0.08);
  overflow: hidden;
}

#blog .post-thumb img {
  height: 230px !important;
  object-fit: cover;
}

#blog .entry-content {
  background: #ffffff;
  padding: 18px !important;
}

#blog .entry-title,
#blog .entry-title a {
  color: #102a1f !important;
  font-size: 18px;
  font-weight: 800;
  line-height: 1.3;
  text-transform: none;
}

#blog .btn-primary {
  background: #0f766e;
  border: 0;
  border-radius: 999px;
  box-shadow: 0 12px 22px rgba(15, 118, 110, 0.18);
  font-weight: 700;
  padding: 10px 16px;
}

@media (max-width: 1199px) {
  .home-modern-grid {
    grid-template-columns: 1fr 1fr;
  }

  .home-modern-intro {
    grid-column: 1 / -1;
  }
}

@media (max-width: 767px) {
  .home-about-layout,
  .home-secondary-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .home-about-photo img {
    height: 300px;
  }

  .home-modern-overview {
    padding: 34px 0 28px;
  }

  .home-modern-grid,
  .home-modern-stats {
    grid-template-columns: 1fr;
  }

  .home-modern-intro {
    padding: 28px 24px;
  }

  .home-modern-intro h2 {
    font-size: 29px;
  }
}
