@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700;800;900&display=swap');

:root {
  --mah-cyan: #1693C3;
  --mah-blue: #1F4FA3;
  --mah-violet: #7A2BBE;
  --mah-yellow: #F5B400;

  --mah-ink: #0d244a;
  --mah-muted: #58708f;
  --mah-bg: #f3f9fd;
  --mah-surface: #ffffff;
  --mah-border: #d9e9f5;

  --mf-primary: var(--mah-cyan);
  --mf-secondary: var(--mah-blue);
  --mf-accent: var(--mah-yellow);
  --mf-muted: var(--mah-muted);
  --mf-dark: var(--mah-ink);
}

* {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: 'Montserrat', sans-serif;
  color: var(--mah-ink);
  background:
    radial-gradient(1200px 460px at 8% -12%, rgba(22, 147, 195, 0.12), transparent 60%),
    radial-gradient(900px 360px at 90% -20%, rgba(122, 43, 190, 0.08), transparent 58%),
    var(--mah-bg);
}

h1, h2, h3, h4, h5, h6 {
  color: var(--mah-blue);
  font-weight: 800;
}

.section-title {
  letter-spacing: 0.02em;
}

p, li {
  color: #27486c;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1030;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(10px) saturate(140%);
  -webkit-backdrop-filter: blur(10px) saturate(140%);
  border-bottom: 1px solid rgba(179, 207, 233, 0.65);
  box-shadow: 0 10px 24px rgba(13, 36, 74, 0.08);
}

.site-header::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 1px;
  background: linear-gradient(90deg, rgba(22, 147, 195, 0), rgba(22, 147, 195, 0.5), rgba(22, 147, 195, 0));
  pointer-events: none;
}

.navbar-brand {
  color: var(--mah-cyan) !important;
  font-weight: 800 !important;
  font-size: 1.05rem;
}

.navbar-brand img {
  width: 52px;
  height: 52px;
  object-fit: contain;
}

.navbar {
  min-height: 92px;
}

.navbar .navbar-nav {
  gap: 0.8rem;
}

.navbar .nav-link {
  position: relative;
  color: #0f4f77;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  font-size: 1rem;
  padding: 0.45rem 0.2rem !important;
  border-radius: 0;
  transition: color 0.2s ease;
}

.navbar .nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -0.38rem;
  height: 2px;
  background: var(--mah-cyan);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform 0.2s ease;
}

.navbar .nav-link:hover {
  color: #0a688f;
}

.navbar .nav-link:hover::after,
.navbar .nav-link.active::after {
  transform: scaleX(1);
}

.navbar .nav-link.active {
  color: #0a688f !important;
  background: transparent;
}

.navbar .dropdown-menu {
  border: 1px solid #d8e7f1;
  border-radius: 0.75rem;
  padding: 0.45rem;
  box-shadow: 0 14px 30px rgba(13, 36, 74, 0.12);
}

.navbar .dropdown-item {
  border-radius: 0.55rem;
  font-weight: 600;
  color: #1b3d68;
  padding: 0.48rem 0.68rem;
}

.navbar .dropdown-item:hover {
  background: rgba(22, 147, 195, 0.1);
  color: #0a688f;
}

@media (min-width: 992px) {
  .navbar .dropdown-menu {
    display: block;
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s ease;
    pointer-events: none;
    margin-top: 0.2rem;
  }

  .navbar .dropdown:hover > .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
  }
}

.page-hero {
  background:
    radial-gradient(750px 260px at 4% 0%, rgba(22, 147, 195, 0.17), transparent 65%),
    radial-gradient(720px 240px at 95% 12%, rgba(122, 43, 190, 0.11), transparent 68%),
    linear-gradient(180deg, #e7f5fc 0%, #f8fcff 100%);
  border-bottom: 1px solid var(--mah-border);
}

.hero-img {
  height: 74vh;
  object-fit: cover;
  filter: saturate(1.05) contrast(1.03) brightness(0.72);
}

.carousel-caption h1,
.carousel-caption h2 {
  text-shadow: 0 8px 28px rgba(0, 0, 0, 0.3);
}

.card,
.card-pane,
.card-form,
.don-card,
.sidebar-card,
.post-card,
.value-card,
.event-card,
.member-card {
  border: 1px solid rgba(31, 79, 163, 0.12) !important;
  border-radius: 1rem !important;
  box-shadow: 0 16px 34px rgba(18, 52, 96, 0.08) !important;
  background: var(--mah-surface);
}

.card:hover,
.post-card:hover,
.event-card:hover,
.member-card:hover,
.value-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 38px rgba(18, 52, 96, 0.12) !important;
}

.card-img-top,
.post-card img,
.event-img,
.member-photo {
  object-fit: cover;
}

.btn {
  border-radius: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.btn-primary {
  background: linear-gradient(135deg, var(--mah-cyan), var(--mah-blue));
  border: 0;
  box-shadow: 0 8px 18px rgba(22, 147, 195, 0.28);
}

.btn-primary:hover {
  filter: brightness(0.96);
}

.btn-outline-primary {
  color: var(--mah-blue);
  border-color: rgba(31, 79, 163, 0.42);
}

.btn-outline-primary:hover {
  background: rgba(22, 147, 195, 0.1);
  color: var(--mah-blue);
  border-color: var(--mah-cyan);
}

.badge,
.tag,
.member-role,
.json-badge {
  border-radius: 999px !important;
}

.tag {
  background: rgba(22, 147, 195, 0.12) !important;
  color: #0d4372 !important;
}

.form-control,
.form-select {
  border-radius: 0.78rem;
  border: 1px solid #c9dceb;
}

.form-control:focus,
.form-select:focus {
  border-color: var(--mah-cyan);
  box-shadow: 0 0 0 0.22rem rgba(22, 147, 195, 0.16);
}

.needs-validation .form-control:valid,
.needs-validation .form-select:valid {
  border-color: #26a269;
}

.needs-validation .form-control:invalid,
.needs-validation .form-select:invalid {
  border-color: #dc3545;
}

.partner-strip {
  overflow: hidden;
  position: relative;
}

.partner-track {
  display: flex;
  gap: 54px;
  width: max-content;
  animation: partner-scroll 22s linear infinite;
}

.partner-track img {
  height: 82px;
  transition: 0.25s ease;
}

.partner-track img:hover {
  transform: translateY(-2px);
}

@keyframes partner-scroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.stat .num {
  color: var(--mah-blue);
  font-weight: 900;
}

.site-footer {
  background: transparent;
}

.site-footer .footer-wrap {
  max-width: 1920px;
  margin-inline: auto;
}

.site-footer .footer-shell {
  position: relative;
  border-radius: 1.5rem;
  border: 1px solid rgba(176, 207, 238, 0.5);
  background:
    radial-gradient(780px 280px at 10% 0%, rgba(122, 43, 190, 0.08), transparent 58%),
    radial-gradient(680px 260px at 100% 0%, rgba(22, 147, 195, 0.2), transparent 58%),
    linear-gradient(135deg, #eef3ff 0%, #dff7ff 100%);
  box-shadow: 0 24px 48px rgba(18, 42, 79, 0.15);
  overflow: hidden;
}

.site-footer .footer-shell::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(
      135deg,
      rgba(255, 255, 255, 0.2) 0,
      rgba(255, 255, 255, 0.2) 1px,
      transparent 1px,
      transparent 18px
    );
  pointer-events: none;
}

.site-footer .footer-shell::after {
  content: "";
  position: absolute;
  width: 420px;
  height: 420px;
  right: -120px;
  top: -180px;
  border-radius: 999px;
  background: radial-gradient(circle at center, rgba(22, 147, 195, 0.2), rgba(22, 147, 195, 0));
  filter: blur(8px);
  animation: footerGlow 8s ease-in-out infinite alternate;
  pointer-events: none;
}

@keyframes footerGlow {
  from { transform: translateY(0) scale(1); opacity: 0.85; }
  to { transform: translateY(10px) scale(1.08); opacity: 1; }
}

.site-footer .footer-cta {
  text-align: center;
  padding: 1.2rem 1rem 2rem;
}

.site-footer .footer-cta-title {
  color: #132640;
  font-size: clamp(1.8rem, 3.8vw, 3rem);
  line-height: 1.08;
  font-weight: 800;
  margin-bottom: 0.55rem;
}

.site-footer .footer-cta-text {
  color: #3f5678;
  max-width: 720px;
  margin: 0 auto 1rem;
}

.site-footer .footer-cta-actions {
  display: flex;
  justify-content: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.site-footer .footer-cta-actions .btn {
  border-radius: 999px;
  padding: 0.58rem 1rem;
  font-size: 0.9rem;
}

.site-footer .footer-panel {
  border-radius: 1.2rem;
  border: 1px solid rgba(169, 194, 222, 0.5);
  background: rgba(255, 255, 255, 0.48);
  backdrop-filter: blur(10px) saturate(120%);
  -webkit-backdrop-filter: blur(10px) saturate(120%);
}

.site-footer .footer-title {
  color: #132640;
  font-size: clamp(1.28rem, 2vw, 1.7rem);
  font-weight: 700;
  letter-spacing: 0.01em;
}

.site-footer .footer-lead {
  color: #405b7f;
  font-size: 0.98rem;
  line-height: 1.6;
}

.site-footer .footer-subtitle {
  color: #203a62;
  font-size: 1.05rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.75rem;
}

.site-footer .footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.65rem;
}

.site-footer .footer-links a {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  color: #35567d;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
}

.site-footer .footer-links a:hover {
  color: #0d5f8d;
  text-decoration: underline;
}

.site-footer .footer-socials {
  display: flex;
  gap: 0.72rem;
  flex-wrap: wrap;
}

.site-footer .social-chip {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.58);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border: 1px solid #cfe0f0;
  transition: transform 0.2s ease, background 0.2s ease;
}

.site-footer .social-chip:hover {
  transform: translateY(-2px);
  background: #eef7ff;
}

.site-footer .social-chip img {
  width: 20px;
  height: 20px;
  object-fit: contain;
  display: block;
}

.site-footer .footer-note {
  color: #567395;
  margin-top: 0.8rem;
  font-size: 0.88rem;
}

.site-footer .footer-news {
  display: flex;
  gap: 0.45rem;
  max-width: 360px;
}

.site-footer .footer-news .form-control {
  border-radius: 999px;
  border: 1px solid #ccdced;
  background: #fff;
}

.site-footer .footer-news .btn {
  border-radius: 999px;
  white-space: nowrap;
  padding-inline: 0.9rem;
}

.site-footer .footer-contact li {
  color: #35567d;
  margin-bottom: 0.55rem;
  font-size: 0.95rem;
}

.site-footer .footer-contact i {
  color: #2d72a8;
}

.site-footer .footer-contact .contact-row {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  min-width: 0;
}

.site-footer .footer-contact .contact-row i {
  flex: 0 0 18px;
  line-height: 1.45;
  margin-top: 0.06rem;
}

.site-footer .footer-contact .contact-value {
  display: inline-block;
  line-height: 1.42;
  min-width: 0;
}

.site-footer .footer-contact .contact-email .contact-value {
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.site-footer .footer-contact .contact-phone .contact-value {
  white-space: normal;
}

.site-footer .footer-bottom {
  margin-top: 1.2rem;
  padding-top: 1rem;
  border-top: 1px solid #d2e4f3;
}

.site-footer .footer-bottom small,
.site-footer .footer-bottom a {
  color: #4b6689 !important;
}

.site-footer .footer-bottom a {
  text-decoration: none;
}

.site-footer .footer-bottom a:hover {
  text-decoration: underline;
}

@media (max-width: 768px) {
  .site-footer .footer-shell {
    border-radius: 1rem;
  }

  .site-footer .footer-cta {
    padding-bottom: 1.4rem;
  }

  .site-footer .social-chip {
    width: 38px;
    height: 38px;
  }

  .site-footer .social-chip img {
    width: 18px;
    height: 18px;
  }

  .site-footer .footer-news {
    max-width: none;
  }

}

@media (prefers-reduced-motion: reduce) {
  .site-footer .footer-shell::after {
    animation: none;
  }
}

.back-to-top {
  position: fixed;
  right: 22px;
  bottom: 22px;
  width: 46px;
  height: 46px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--mah-cyan), var(--mah-violet));
  color: #fff;
  display: grid;
  place-items: center;
  text-decoration: none;
  box-shadow: 0 14px 28px rgba(16, 56, 102, 0.26);
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 1050;
}

.back-to-top.show {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.rounded-4 {
  border-radius: 1rem !important;
}

@media (max-width: 992px) {
  .navbar {
    min-height: auto;
  }

  .navbar-brand img {
    width: 42px;
    height: 42px;
  }

  .navbar .navbar-nav {
    gap: 0.25rem;
    padding-top: 0.6rem;
  }

  .navbar .nav-link {
    text-transform: none;
    letter-spacing: 0;
    font-size: 0.98rem;
    padding: 0.55rem 0.5rem !important;
  }

  .navbar .nav-link::after {
    left: 0.5rem;
    right: auto;
    width: 26px;
    bottom: 0.2rem;
  }
}

@media (max-width: 576px) {
  .hero-img {
    height: 60vh;
  }

  .back-to-top {
    right: 14px;
    bottom: 14px;
  }
}
