:root {
  --brand-navy: #0b1f3a;
  --brand-navy-dark: #08182e;
  --brand-accent: #9b1c1c;
  --text-primary: #1b1f24;
  --text-muted: #5f6b7a;
  --bg-page: #f6f8fb;
  --bg-card: #ffffff;
  --border-soft: #e3e7ed;
}

* {
  box-sizing: border-box;
}

body {
  background: var(--bg-page);
  color: var(--text-primary);
  font-family: "Georgia", "Times New Roman", serif;
  line-height: 1.6;
  padding-top: 120px;
  /* keep a small default bottom padding; spacer will be inserted dynamically when footer is fixed */
  padding-bottom: 20px;
}

a {
  color: var(--brand-navy);
  text-decoration: none;
}

a:hover,
a:focus {
  color: var(--brand-accent);
  text-decoration: underline;
}

.container {
  max-width: 1100px;
}

.navbar.navbar-inverse {
  background-color: #132742;
  border-color: #0d1c30;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
}

.navbar .nav.azh {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
  padding: 10px 0;
}

.navbar .nav.azh > li {
  margin: 0;
}

.navbar .nav.azh > li > a {
  color: #f3f6fb;
  background: transparent;
  border-radius: 4px;
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.2px;
}

.navbar .nav.azh > li > a:hover,
.navbar .nav.azh > li > a:focus,
.navbar .nav.azh > li.active > a {
  background: #e9eef5;
  color: #132742;
}

.page-header {
  border-bottom: 2px solid var(--border-soft);
  margin: 20px 0 15px;
}

.page-header h1,
.page-header h2,
.page-header h3 {
  color: var(--brand-navy);
  margin-top: 0;
}

p,
li {
  color: var(--text-primary);
  font-size: 16px;
}

.table {
  background: var(--bg-card);
}

.table > thead > tr > th {
  background: #f0f3f7;
  color: var(--text-primary);
}

.footer {
  background: #132742 !important;
  color: #ffffff !important;
  padding: 16px 0;
  /* Default: static footer (appears after content). JS toggles .fixed to pin it to viewport bottom */
  position: relative !important;
  margin-bottom: 0;
  min-height: 60px;
}

/* Ensure all footer text is white, including elements with the .text-muted class */
.footer, 
.footer p, 
.footer .text-muted, 
.footer strong, 
.footer b, 
.footer a,
.footer .container {
  color: #ffffff !important;
}

.footer .container {
  background: transparent !important;
  padding: 10px 15px;
  display: flex;
  align-items: center; /* vertical centering */
  justify-content: center; /* horizontal centering */
  height: 100%;
}

/* Fixed footer variant applied by JS when page content is shorter than viewport */
.footer.fixed {
  position: fixed !important;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  z-index: 9999;
  height: 60px !important;
  min-height: 60px;
}

.hero-title {
  font-size: 34px;
  color: var(--brand-navy);
  letter-spacing: 0.5px;
}

.hero-subtitle {
  font-size: 26px;
  color: var(--brand-accent);
  margin-top: 10px;
}

.hero-intro {
  color: var(--text-muted);
  margin-top: 8px;
}

.hero-logos {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 16px 24px;
}

.hero-logos img {
  max-width: 100%;
  height: auto;
}

@media (max-width: 992px) {
  body {
    padding-top: 37px;
  }
}

@media (max-width: 768px) {
  body {
    padding-top: 32px;
  }

  .navbar .nav.azh {
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
  }

  .navbar .nav.azh > li > a {
    font-size: 16px;
  }

  .hero-title {
    font-size: 26px;
  }

  .hero-subtitle {
    font-size: 20px;
  }

  .table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
}

@media (max-width: 480px) {
  body {
    padding-top: 30px;
  }

  .hero-title {
    font-size: 22px;
  }

  .hero-subtitle {
    font-size: 18px;
  }
}

@media (max-width: 430px) {
  body {
    padding-top: 28px;
  }
}

@media (min-width: 1366px) {
  body {
    padding-top: 60px;
  }

  .navbar .nav.azh {
    flex-wrap: nowrap;
    white-space: nowrap;
    overflow: hidden;
  }

  .navbar .nav.azh > li {
    display: inline-block;
  }

  .navbar .nav.azh > li > a {
    padding-top: 6px;
    padding-bottom: 6px;
  }

  .container {
    max-width: 1280px;
  }
}

/* Remove earlier forced nowrap behavior by overriding for medium screens
   and enable collapse for screens below 992px so the Bootstrap
   toggle appears earlier instead of relying on horizontal scrolling.
*/
@media (max-width: 991px) {
   /* Ensure the toggle button is visible at this breakpoint */
   .navbar .navbar-header .navbar-toggle {
     display: block;
   }

   /* Hide expanded navbar content by default; Bootstrap will add .in when opened */
   .navbar .navbar-collapse {
     display: none !important;
     height: auto;
     visibility: hidden;
   }

   /* When collapse is shown (Bootstrap toggles .in), show it */
   .navbar .navbar-collapse.in {
     display: block !important;
     visibility: visible !important;
   }

   /* When collapsed, make nav items stack vertically */
   .navbar .nav.azh {
     flex-direction: column;
     align-items: stretch;
     gap: 4px;
     white-space: normal;
     overflow: visible;
   }

   .navbar .nav.azh > li > a {
     font-size: 16px;
     padding: 10px 12px;
     display: block !important;
   }
}

@media (min-width: 768px) and (max-width: 991px) {
  /* Show hamburger on the left for tablet/PC widths between 768 and 991px */
  .navbar .navbar-header {
    float: left;
    display: block;
  }

  .navbar .navbar-header .navbar-toggle {
    display: block;
    margin-left: 0;
    -webkit-user-drag: none;
    user-drag: none;
    user-select: none;
    touch-action: manipulation; /* prefer taps, avoid panning gestures on toggle */
  }

  /* Ensure expanded navbar content is hidden by default and only shown when .in is present */
  .navbar .navbar-collapse {
    display: none !important;
    visibility: hidden;
  }

  .navbar .navbar-collapse.in {
    display: block !important;
    visibility: visible !important;
  }

  /* When collapsed, stack items vertically and prevent horizontal scrolling/draggable nav */
  .navbar .nav.azh {
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
    white-space: normal;
    overflow-x: hidden !important; /* no horizontal scroll */
    -webkit-overflow-scrolling: auto;
    touch-action: pan-y; /* allow vertical scroll but prevent horizontal panning */
  }

  /* Prevent any accidental horizontal drag on the whole navbar */
  .navbar {
    overflow-x: hidden;
    -webkit-user-drag: none;
    user-drag: none;
  }

  /* Make sure links are full-width when collapsed for easy clicking */
  .navbar .nav.azh > li > a {
    display: block !important;
    width: 100%;
    padding: 10px 12px;
  }
}