/* CSIMF custom overrides on top of AdminLTE 3 */

.brand-link .brand-image { margin-top: -3px; }

.login-box .card { border-top: 3px solid #007bff; }

.small-box .icon { opacity: .35; }

.dark-mode .card { background-color: #343a40; }

/* Traffic-light indicator badges used across dashboards */
.traffic-green { color: #28a745; }
.traffic-amber { color: #ffc107; }
.traffic-red { color: #dc3545; }

.table td, .table th { vertical-align: middle; }

/* ==========================================================================
   Government identification bar (site-wide - appears above everything,
   including the login page and the authenticated app)
   ========================================================================== */
.csimf-gov-bar {
  background: #0b1f33;
  color: #d7e0e8;
  font-size: .78rem;
  text-align: center;
  padding: .35rem .5rem;
  letter-spacing: .01em;
}

.csimf-gov-bar-inner strong {
  color: #ffffff;
}

.csimf-gov-bar-divider {
  margin: 0 .6rem;
  opacity: .4;
}

.csimf-gov-stripe {
  display: flex;
  height: 4px;
  width: 100%;
}

.csimf-gov-stripe span {
  flex: 1 1 0;
}

.csimf-gov-stripe span:nth-child(1) { background-color: #d21034; } /* Vanuatu red */
.csimf-gov-stripe span:nth-child(2) { background-color: #c9a227; } /* formal gold */
.csimf-gov-stripe span:nth-child(3) { background-color: #007a3d; } /* Vanuatu green */

/* Formal serif treatment for display headings, used sparingly to give the
   public-facing pages an official/government document feel. */
.csimf-gov-serif {
  font-family: Georgia, "Times New Roman", Times, serif;
}

/* ==========================================================================
   Top navigation (two-row horizontal layout, replaces the AdminLTE sidebar)
   ========================================================================== */

body.layout-top-nav .content-wrapper,
body.layout-top-nav .main-footer {
  margin-left: 0;
}

/* Row 1: identity / utility bar */
.csimf-topbar {
  background-color: #4a7fac;
  border-bottom: 1px solid #3a6a92;
  padding: 0 .5rem;
}

.csimf-topbar .nav-link {
  color: #eef4fa;
  font-size: .92rem;
  padding: .55rem .75rem;
}

.csimf-topbar .nav-link:hover,
.csimf-topbar .nav-link:focus {
  color: #ffffff;
  background-color: rgba(255, 255, 255, .12);
}

.csimf-topbar .csimf-identity {
  font-weight: 600;
}

.csimf-topbar .csimf-org-pill {
  font-weight: 600;
  color: #ffffff;
  background-color: rgba(255, 255, 255, .15);
  border-radius: .25rem;
  margin: .35rem 0;
}

.csimf-topbar .csimf-branch-pill {
  border-radius: .25rem;
  margin: .35rem 0;
}

.csimf-topbar .csimf-branch-pill.active {
  background-color: #ffffff;
  color: #2c5a82;
  font-weight: 600;
}

.csimf-topbar .caret {
  display: inline-block;
  width: 0;
  height: 0;
  margin-left: .3em;
  vertical-align: middle;
  border-top: 4px solid;
  border-right: 4px solid transparent;
  border-left: 4px solid transparent;
}

/* Row 2: module menu - wraps to a second line on narrow windows instead of
   ever requiring horizontal scrolling, so every module stays one click away. */
.csimf-mainnav {
  background-color: #1b2531;
  border-bottom: 3px solid #12191f;
}

.csimf-mainnav-list {
  display: flex;
  flex-wrap: wrap;
  list-style: none;
  margin: 0;
  padding: 0;
}

.csimf-mainnav-item {
  position: relative;
  flex: 0 0 auto;
}

.csimf-mainnav-link {
  display: flex;
  align-items: center;
  gap: .3em;
  color: #c3cdd8;
  font-size: .8rem;
  font-weight: 500;
  padding: .5rem .55rem;
  border-right: 1px solid rgba(255, 255, 255, .06);
  white-space: nowrap;
}

.csimf-mainnav-link i {
  font-size: .85rem;
  opacity: .85;
}

.csimf-mainnav-link:hover,
.csimf-mainnav-link:focus {
  color: #ffffff;
  background-color: rgba(255, 255, 255, .08);
  text-decoration: none;
}

.csimf-mainnav-link.active {
  color: #ffffff;
  background-color: #2f6f9e;
}

.csimf-mainnav-link .caret {
  display: inline-block;
  width: 0;
  height: 0;
  margin-left: .25em;
  border-top: 4px solid;
  border-right: 4px solid transparent;
  border-left: 4px solid transparent;
  opacity: .7;
}

.csimf-has-dropdown .dropdown-menu {
  margin-top: 0;
  border-radius: 0;
  font-size: .9rem;
}

/* Below tablet width, drop the text labels and keep icons only so the row
   still fits on one line without scrolling; dropdown carets stay visible. */
@media (max-width: 767.98px) {
  .csimf-mainnav-link span { display: none; }
  .csimf-mainnav-link { padding: .5rem .5rem; }
  .csimf-mainnav-link i { font-size: 1rem; }
}

/* ---------------------------------------------------------------------
   Public landing page ("/", anonymous visitors only) - formal
   government-portal theme: deep navy + formal gold, serif display type,
   an emblem placeholder, and an authorised-use notice.
   --------------------------------------------------------------------- */
.csimf-landing-hero {
  background: linear-gradient(160deg, #08131f 0%, #0b1f33 45%, #143352 100%);
  color: #fff;
  padding: 3.5rem 1.5rem 4.5rem;
  text-align: center;
}

.csimf-landing-emblem {
  width: 72px;
  height: 72px;
  margin: 0 auto 1rem;
  border-radius: 50%;
  border: 2px solid #c9a227;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  color: #c9a227;
  background: rgba(201, 162, 39, .08);
}

.csimf-landing-hero .csimf-landing-shortname {
  font-size: 2.75rem;
  font-weight: 700;
  letter-spacing: .06em;
  margin-bottom: .4rem;
}

.csimf-landing-gold-rule {
  width: 90px;
  height: 3px;
  background: #c9a227;
  margin: 0 auto 1.25rem;
}

.csimf-landing-hero .csimf-landing-fullname {
  font-size: 1.1rem;
  font-weight: 400;
  max-width: 640px;
  margin: 0 auto .5rem;
  opacity: .95;
}

.csimf-landing-hero .csimf-landing-fullname-sub {
  font-size: .92rem;
  font-weight: 300;
  max-width: 620px;
  margin: 0 auto 1.75rem;
  opacity: .78;
  line-height: 1.6;
}

.csimf-landing-hero .csimf-landing-tenant {
  display: inline-block;
  font-size: .8rem;
  letter-spacing: .04em;
  text-transform: uppercase;
  background: rgba(255, 255, 255, .08);
  border: 1px solid rgba(201, 162, 39, .5);
  border-radius: 3px;
  padding: .35rem 1rem;
  margin-bottom: 1.5rem;
}

.csimf-landing-hero .btn-csimf-cta {
  background-color: #c9a227;
  color: #0b1f33;
  font-weight: 700;
  padding: .65rem 2rem;
  border-radius: 3px;
  border: none;
}

.csimf-landing-hero .btn-csimf-cta:hover {
  background-color: #dcb739;
  color: #0b1f33;
}

.csimf-landing-hero .btn-csimf-ghost {
  color: #fff;
  border: 1px solid rgba(255, 255, 255, .5);
  padding: .6rem 1.75rem;
  border-radius: 3px;
  font-weight: 600;
}

.csimf-landing-hero .btn-csimf-ghost:hover {
  background: rgba(255, 255, 255, .1);
  color: #fff;
}

.csimf-landing-notice {
  background: #fbf6e8;
  border-top: 1px solid #e8dcb0;
  border-bottom: 1px solid #e8dcb0;
  padding: 1rem 1rem;
}

.csimf-landing-notice-inner {
  max-width: 900px;
  margin: 0 auto;
  display: flex;
  align-items: flex-start;
  gap: .85rem;
  font-size: .85rem;
  color: #5c4b12;
  line-height: 1.55;
}

.csimf-landing-notice-icon {
  color: #c9a227;
  font-size: 1.15rem;
  margin-top: .1rem;
}

.csimf-landing-stats {
  background: #f4f6f9;
  border-bottom: 1px solid #e2e6ea;
  padding: 2rem 1rem;
}

.csimf-landing-stat {
  text-align: center;
}

.csimf-landing-stat .csimf-landing-stat-value {
  font-size: 2rem;
  font-weight: 700;
  color: #0b1f33;
  line-height: 1.1;
}

.csimf-landing-stat .csimf-landing-stat-label {
  font-size: .8rem;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: #6c757d;
}

.csimf-landing-section {
  padding: 3.5rem 1rem;
}

.csimf-landing-section-title {
  text-align: center;
  font-weight: 700;
  color: #0b1f33;
  margin-bottom: .5rem;
}

.csimf-landing-section-subtitle {
  text-align: center;
  color: #6c757d;
  max-width: 620px;
  margin: 0 auto 2.5rem;
}

.csimf-landing-feature-card {
  background: #fff;
  border: 1px solid #e2e6ea;
  border-top: 3px solid #0b1f33;
  border-radius: 4px;
  padding: 1.5rem;
  height: 100%;
  transition: box-shadow .15s ease, transform .15s ease;
}

.csimf-landing-feature-card:hover {
  box-shadow: 0 .5rem 1rem rgba(0, 0, 0, .08);
  transform: translateY(-2px);
  border-top-color: #c9a227;
}

.csimf-landing-feature-card .csimf-landing-feature-icon {
  width: 46px;
  height: 46px;
  border-radius: 4px;
  background: #eef1f5;
  color: #0b1f33;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  margin-bottom: .9rem;
}

.csimf-landing-feature-card h6 {
  font-weight: 700;
  color: #0b1f33;
  margin-bottom: .35rem;
}

.csimf-landing-feature-card p {
  color: #6c757d;
  font-size: .87rem;
  margin-bottom: 0;
}

.csimf-landing-roles {
  background: #0b1f33;
  color: #fff;
  padding: 3.5rem 1rem;
}

.csimf-landing-roles .csimf-landing-section-title,
.csimf-landing-roles .csimf-landing-section-subtitle {
  color: #fff;
}

.csimf-landing-roles .csimf-landing-section-subtitle {
  opacity: .75;
}

.csimf-landing-role-pill {
  display: inline-block;
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(201, 162, 39, .45);
  border-radius: 3px;
  padding: .45rem 1.1rem;
  margin: .25rem;
  font-size: .85rem;
}

.csimf-landing-cta {
  text-align: center;
  padding: 3.5rem 1rem 2.5rem;
}

.csimf-landing-cta h3 {
  font-weight: 700;
  color: #0b1f33;
}

.csimf-landing-cta .btn-csimf-cta {
  background-color: #0b1f33;
  color: #fff;
  font-weight: 700;
  border: none;
}

.csimf-landing-cta .btn-csimf-cta:hover {
  background-color: #143352;
  color: #fff;
}

.csimf-landing-disclaimer {
  text-align: center;
  font-size: .78rem;
  color: #8a939b;
  max-width: 700px;
  margin: 0 auto 3rem;
  padding: 0 1rem;
  line-height: 1.6;
}

/* ---------------------------------------------------------------------
   Reusable button (used on both the landing page and the login page)
   --------------------------------------------------------------------- */
.btn-csimf-cta {
  background-color: #c9a227;
  color: #0b1f33;
  font-weight: 700;
  border: none;
}

.btn-csimf-cta:hover,
.btn-csimf-cta:focus {
  background-color: #dcb739;
  color: #0b1f33;
}

/* ---------------------------------------------------------------------
   Login page - matches the landing page's government theme
   --------------------------------------------------------------------- */
.csimf-login-page {
  min-height: calc(100vh - 60px);
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(160deg, #08131f 0%, #0b1f33 45%, #143352 100%);
  padding: 3rem 1rem;
  margin: -1rem -15px;
}

.csimf-login-box {
  width: 100%;
  max-width: 400px;
}

.csimf-login-brand {
  text-align: center;
  color: #fff;
  margin-bottom: 1.5rem;
}

.csimf-login-shortname {
  font-size: 2.25rem;
  font-weight: 700;
  letter-spacing: .06em;
}

.csimf-login-gold-rule {
  width: 70px;
  height: 3px;
  background: #c9a227;
  margin: .6rem auto .75rem;
}

.csimf-login-appname {
  font-size: .85rem;
  opacity: .8;
  margin-bottom: 0;
}

.csimf-login-card {
  border: none;
  border-top: 4px solid #c9a227;
  border-radius: 4px;
  box-shadow: 0 .75rem 2rem rgba(0, 0, 0, .25);
}

.csimf-login-msg {
  text-align: center;
  color: #6c757d;
  margin-bottom: 1.25rem;
}

.csimf-login-footnote {
  text-align: center;
  color: rgba(255, 255, 255, .65);
  font-size: .78rem;
  margin: 1.25rem 0 0;
}
