:root {
  /* Palette sampled directly from the LTDA logo */
  --ltda-primary: #2d3691;       /* logo ring / handshake-badge blue */
  --ltda-primary-dark: #1f2568;  /* deeper shade for hover/active states */
  --ltda-accent: #f2b705;        /* road-marking gold */
  --ltda-green: #0e9141;         /* laurel-wreath green */
  --ltda-sky: #5b9bd5;           /* "TOGETHER WE CAN" light blue */
  --ltda-bg: #f5f6f8;
  --ltda-text: #23272b;
  --ltda-topbar-bg: #fff;
  --ltda-topbar-border: #e6e8eb;
  --ltda-chip-hover: #f0f1f3;
  --ltda-passport-bg: #f0f1f3;
  --ltda-passport-border: #c7ccd1;
  --ltda-thead-bg: #eef1ee;
  --ltda-header-h: 56px; /* sidebar logo block height (reduced) */
  --ltda-footer-h: 34px; /* fixed footer bar height */
  /* Gradient built from the logo palette - used for navbar/sidebar/buttons/headers */
  --ltda-gradient: linear-gradient(135deg, var(--ltda-primary) 0%, var(--ltda-primary-dark) 55%, var(--ltda-green) 130%);
  --ltda-gradient-accent: linear-gradient(135deg, var(--ltda-primary) 0%, var(--ltda-sky) 100%);
}
[data-bs-theme="dark"] {
  --ltda-bg: #14181b;
  --ltda-text: #e7e9ea;
  --ltda-topbar-bg: #1b2023;
  --ltda-topbar-border: #2b3236;
  --ltda-chip-hover: #262c30;
  --ltda-passport-bg: #23292c;
  --ltda-passport-border: #3a4247;
  --ltda-thead-bg: #21272a;
}

* {
  font-family: 'Montserrat', 'Segoe UI', Tahoma, Verdana, sans-serif;
}

html {
  font-size: 14px; /* smaller base size sitewide */
}
html, body {
  max-width: 100%;
  overflow-x: hidden; /* safety net: nothing should ever force horizontal page scroll on mobile */
}
body {
  background-color: var(--ltda-bg);
  font-family: 'Montserrat', 'Segoe UI', Tahoma, Verdana, sans-serif;
  color: var(--ltda-text);
  font-size: 0.92rem;
}
img { max-width: 100%; height: auto; }
h1 { font-size: 1.65rem; }
h2 { font-size: 1.4rem; }
h3 { font-size: 1.2rem; }
h4 { font-size: 1.05rem; }
h5 { font-size: 0.98rem; }
h6, .card-header { font-size: 0.9rem; }
.form-label, .form-text, .small, small { font-size: 0.82rem; }
.table { font-size: 0.86rem; }
.btn { font-size: 0.86rem; }

h1, h2, h3, h4, h5, h6, .card-header, .btn {
  font-weight: 600;
  letter-spacing: 0.2px;
}

.ltda-navbar {
  background: var(--ltda-gradient);
  position: sticky;
  top: 0;
  z-index: 1030;
  min-height: 50px;
}
@media (max-width: 991.98px) {
  .ltda-navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1040;
  }
  /* Reserve the space the fixed navbar no longer takes up in normal flow */
  .ltda-layout,
  body > .container.my-4 {
    padding-top: 50px;
  }
}
.navbar-brand {
  color: #f5f6f8 !important;
  font-weight: 700;
  letter-spacing: 0.3px;
}

/* Sidebar logo block (desktop): fixed height (see --ltda-header-h above). */
.ltda-sidebar .navbar-brand {
  height: var(--ltda-header-h);
  box-sizing: border-box;
}

/* Logo mark: rounded white plate behind the badge so it reads cleanly on
   the dark blue navbar/sidebar, in any theme. */
.navbar-brand-logo {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background-color: #fff;
  padding: 3px;
  object-fit: contain;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.15);
  flex-shrink: 0;
}
/* Keep the guest top navbar to one line on very narrow phones: the site
   name truncates instead of wrapping the Login/Register buttons below it. */
@media (max-width: 400px) {
  .ltda-navbar .navbar-brand {
    min-width: 0;
    overflow: hidden;
  }
  .ltda-navbar .navbar-brand span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 34vw;
  }
}

/* ---- Landing page hero: truck + owner illustration with a color overlay ---- */
.ltda-hero {
  position: relative;
  overflow: hidden;
  min-height: 420px;
  display: flex;
  align-items: center;
  padding: 3rem;
  background-image: url('../img/hero-truck.svg');
  background-size: cover;
  background-position: center;
  color: #fff;
}
.ltda-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, rgba(31,37,104,0.92) 0%, rgba(45,54,145,0.78) 40%, rgba(45,54,145,0.35) 75%, rgba(45,54,145,0.15) 100%);
}
.ltda-hero-content {
  position: relative;
  z-index: 1;
  max-width: 620px;
}
.ltda-hero-eyebrow {
  display: inline-block;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 0.78rem;
  font-weight: 700;
  color: #14181b;
  background: var(--ltda-accent);
  padding: 0.3rem 0.8rem;
  border-radius: 30px;
  margin-bottom: 1rem;
}
.ltda-hero-content h1,
.ltda-hero-content p {
  color: #fff;
  text-shadow: 0 1px 3px rgba(0,0,0,0.25);
}
/* Hero headline/body run larger than the rest of the site by default
   (Bootstrap's display-6 / fs-5 utilities) - scale them down to match. */
.ltda-hero-content h1 {
  font-size: 1.7rem;
}
.ltda-hero-content p.fs-5 {
  font-size: 1rem !important;
}
@media (min-width: 768px) {
  .ltda-hero-content h1 {
    font-size: 2rem;
  }
  .ltda-hero-content p.fs-5 {
    font-size: 1.05rem !important;
  }
}
@media (max-width: 767.98px) {
  .ltda-hero { min-height: 340px; padding: 2rem; }
}

/* ---- Landing page feature cards: larger, easier-to-read text ---- */
/* On the index/landing page only: the shared guest-page wrapper normally
   carries its own bottom margin (see header.php's "container my-4"), but
   the cards row now sets its own explicit mb-4 to match the hero's mb-4
   above it - zero out the wrapper's share here so the two gaps (hero-to-
   cards, cards-to-footer) are controlled by one matching value each and
   stay visually equal instead of adding together. */
body.ltda-index-page > .container.my-4 {
  margin-bottom: 0;
}
.ltda-feature-card .card-body h5 {
  font-size: 1.15rem;
  margin-bottom: 0.6rem;
}
.ltda-feature-card .card-body p {
  font-size: 1rem;
  line-height: 1.55;
}
.ltda-feature-card .card-body .badge {
  font-size: 0.85rem;
}

/* Index page footer: same color treatment as the top navbar */
footer.ltda-index-footer {
  background: var(--ltda-gradient);
  border-top: none;
  color: #f5f6f8 !important;
}
.ltda-index-footer a {
  color: #fff;
}

.ltda-hero-phone {
  color: #fff;
  font-weight: 600;
}
.ltda-hero-phone a {
  color: #fff;
  text-decoration: none;
}
.ltda-hero-phone a:hover {
  text-decoration: underline;
}

/* ---- Fixed footer bar (always visible, shows the SACCO name) ---- */
html, body {
  height: 100%;
}
body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  padding-bottom: var(--ltda-footer-h);
}
.ltda-fixed-footer {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  height: var(--ltda-footer-h);
  z-index: 1045;
  background: var(--ltda-gradient);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.3px;
  box-shadow: 0 -2px 10px rgba(0,0,0,0.12);
  overflow-x: hidden;
  overflow-y: visible;
}

/* Little truck that drives the length of the footer at a constant height;
   the site name/copyright text lifts up out of its way as it passes, then
   settles back down once it has gone by. */
.ltda-footer-truck {
  position: absolute;
  bottom: 3px;
  left: -16%;
  width: 66px;
  height: 22px;
  color: #ffffff;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,0.35));
  z-index: 2;
  pointer-events: none;
  animation: ltdaFooterTruckRun 30s linear infinite;
}
/* The wheels spin continuously and independently of the truck's left-to-right
   drive-across-the-footer animation, so they visibly roll as it moves. */
.ltda-footer-truck-wheel {
  transform-box: fill-box;
  transform-origin: center;
  animation: ltdaFooterWheelSpin 0.7s linear infinite;
}
@keyframes ltdaFooterWheelSpin {
  to { transform: rotate(360deg); }
}
.ltda-fixed-footer span {
  position: relative;
  z-index: 1;
  animation: ltdaFooterTextDodge 30s linear infinite;
}
@keyframes ltdaFooterTruckRun {
  0%   { left: -16%; color: #ffffff; z-index: 2; }
  28%  { left: 30%;  color: #ffffff; z-index: 2; }
  34%  { color: #f2b705; z-index: 20; }
  36%  { left: 39%;  color: #f2b705; z-index: 20; }
  50%  { left: 50%;  color: #f2b705; z-index: 20; }
  64%  { left: 61%;  color: #f2b705; z-index: 20; }
  70%  { color: #ffffff; z-index: 2; }
  72%  { left: 70%;  color: #ffffff; z-index: 2; }
  100% { left: 116%; color: #ffffff; z-index: 2; }
}
/* The text lifts clear of the road while the truck is passing through the
   middle of the footer, timed to the same 30s cycle as the truck. */
@keyframes ltdaFooterTextDodge {
  0%   { transform: translateY(0); }
  30%  { transform: translateY(0); }
  36%  { transform: translateY(-30px); }
  50%  { transform: translateY(-30px); }
  64%  { transform: translateY(-30px); }
  70%  { transform: translateY(0); }
  100% { transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  .ltda-footer-truck { animation: none; left: -16%; }
  .ltda-footer-truck-wheel { animation: none; }
  .ltda-fixed-footer span { animation: none; }
}
.ltda-fixed-footer a { color: #fff; text-decoration: underline; }

/* Remove the fixed footer bar on mobile - permanently pinning it eats
   scarce viewport height on small screens and can overlap page content
   or the mobile navbar/offcanvas. It only shows from tablet width up. */
@media (max-width: 767.98px) {
  .ltda-fixed-footer { display: none; }
  body { padding-bottom: 0; }
}

/* Dropdown menus (language switcher, user menu) opened from inside the
   sticky top bar (z-index 1020) must sit above every other fixed/sticky
   layer - the mobile navbar (1040), the fixed footer (1045), and the
   sidebar (1035) - otherwise they visually open "underneath" that chrome
   and clicking an item does nothing because it isn't actually on top. */
.ltda-topbar .dropdown-menu {
  z-index: 1090;
}
/* Only the logged-in dashboard layout has a sidebar to clear - guest/pre-login
   pages have no sidebar, so their footer must stay full width end to end. */
@media (min-width: 992px) {
  .ltda-fixed-footer-auth { left: 235px; }
}

/* ---- Vertical sidebar layout ---- */
.ltda-layout {
  display: flex;
  align-items: stretch;
  min-height: 100vh;
  flex: 1 1 auto;
}
.ltda-sidebar {
  background: var(--ltda-gradient) !important;
  width: 235px;
  flex: 0 0 235px;
  box-shadow: 2px 0 12px rgba(0,0,0,0.12);
}
.ltda-main {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
}
.ltda-main .container-fluid.my-4 {
  flex: 1 1 auto;
}
@media (min-width: 992px) {
  .ltda-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    overflow: hidden;
    z-index: 1035;
  }
  .ltda-main {
    margin-left: 235px;
  }
}

/* Sidebar body: nav list scrolls independently while Logout stays pinned
   to the bottom of the sidebar at all times. */
.ltda-sidebar-body {
  height: 100%;
  overflow: hidden !important; /* override Bootstrap's default offcanvas-body overflow-y:auto */
}
.ltda-nav-scroll {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
}
.ltda-sidebar-footer {
  flex: 0 0 auto;
  padding: 0.6rem 0.9rem 0.9rem;
  border-top: 1px solid rgba(255,255,255,0.25);
}
.ltda-sidebar-footer .nav-link {
  color: #f5f6f8 !important;
  border-radius: 8px;
  padding: 0.65rem 0.9rem;
  display: flex;
  align-items: center;
  font-weight: 500;
  font-size: 0.94rem;
  transition: background-color 0.15s ease, color 0.15s ease;
}
.ltda-sidebar-footer .nav-link:hover {
  background-color: rgba(255,255,255,0.1);
  color: var(--ltda-accent) !important;
}

/* Guest (logged-out) layout also needs to grow so the footer sticks to the bottom */
body > .container.my-4 {
  flex: 1 1 auto;
}

/* ---- Top bar (page title + user menu) shown above content on logged-in pages ---- */
.ltda-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  height: 46px; /* condensed */
  box-sizing: border-box;
  padding: 0 1rem;
  background: var(--ltda-topbar-bg);
  border-bottom: 1px solid var(--ltda-topbar-border);
  position: sticky;
  top: 0;
  z-index: 1020;
}
@media (max-width: 991.98px) {
  /* Docks just below the mobile navbar instead of underneath it */
  .ltda-topbar { top: 50px; }
}
.ltda-topbar .user-chip {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border: none;
  background: transparent;
  padding: 0.3rem 0.6rem;
  border-radius: 30px;
  color: var(--ltda-text);
}
.ltda-topbar .user-chip:hover {
  background: var(--ltda-chip-hover);
}
.ltda-topbar .user-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--ltda-gradient);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.78rem;
  flex: none;
}
.ltda-topbar .user-name {
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--ltda-text);
}
.theme-toggle-btn {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid var(--ltda-topbar-border);
  background: transparent;
  color: var(--ltda-text);
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
}
.theme-toggle-btn:hover {
  background: var(--ltda-chip-hover);
}

.ltda-nav .nav-link {
  color: #f5f6f8 !important;
  border-radius: 8px;
  padding: 0.65rem 0.9rem;
  margin-bottom: 3px;
  display: flex;
  align-items: center;
  font-weight: 500;
  font-size: 0.94rem;
  transition: background-color 0.15s ease, color 0.15s ease, transform 0.1s ease;
}
.ltda-nav .nav-link:hover {
  background-color: rgba(255,255,255,0.1);
  color: var(--ltda-accent) !important;
  transform: translateX(2px);
}
.ltda-nav .nav-link.active {
  background-color: var(--ltda-accent);
  color: #222 !important;
}

/* ---- Cards & general components ---- */
.card {
  border: none;
  border-radius: 14px;
  box-shadow: 0 2px 14px rgba(0,0,0,0.07);
  transition: box-shadow 0.15s ease;
}
.card:hover {
  box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}
.card-header {
  background: var(--ltda-gradient);
  color: #fff;
  border-radius: 14px 14px 0 0 !important;
  font-weight: 600;
  padding: 0.7rem 1.1rem;
}

.btn {
  border-radius: 8px;
  transition: transform 0.08s ease, box-shadow 0.15s ease;
}
.btn:active {
  transform: scale(0.98);
}
.btn-ltda {
  background: var(--ltda-gradient);
  color: #fff;
  border: none;
}
.btn-ltda:hover {
  filter: brightness(1.08);
  color: #fff;
}
.btn-accent {
  background-color: var(--ltda-accent);
  color: #222;
  border: none;
}
.btn-accent:hover {
  color: #222;
  filter: brightness(0.95);
}

.stat-card h2 {
  font-weight: 700;
  color: var(--ltda-primary);
  margin-bottom: 0;
}
a.dash-card.stat-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.stat-card-icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--ltda-gradient);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  margin: 0 auto 0.6rem;
}
.stat-card-label {
  font-size: 0.85rem;
  color: var(--ltda-text-muted, #6c757d);
  margin-bottom: 0.15rem;
}

a.dash-card.feature-card {
  display: flex;
  flex-direction: column;
}
.feature-card-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--ltda-gradient);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  margin-bottom: 0.75rem;
}
.feature-card h5 {
  font-weight: 700;
  margin-bottom: 0.4rem;
}
.feature-card p {
  color: var(--ltda-text-muted, #6c757d);
  flex: 1 1 auto;
}
.feature-card-warning {
  border: 1px solid var(--bs-warning, #f2b705) !important;
}
.feature-card-warning .feature-card-icon {
  background: var(--bs-warning, #f2b705);
  color: #222;
}

/* ---- Clickable dashboard cards (stat cards + feature cards) ---- */
a.dash-card {
  display: block;
  color: inherit;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
a.dash-card:hover,
a.dash-card:focus {
  transform: translateY(-3px);
  box-shadow: 0 8px 26px rgba(0,0,0,0.14);
  color: inherit;
  text-decoration: none;
}
a.dash-card .dash-card-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-weight: 600;
  color: var(--ltda-primary);
}
a.dash-card:hover .dash-card-cta {
  gap: 0.55rem;
}
a.dash-card .dash-card-cta i {
  transition: transform 0.15s ease;
}

.table thead th {
  background-color: var(--ltda-thead-bg);
  font-weight: 600;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  color: #495057;
  border-bottom: 2px solid #dee2e6;
}

.auth-wrapper {
  max-width: 520px;
  margin: 40px auto;
  width: 100%;
}
.auth-wrapper-wide {
  max-width: 760px;
}
/* Login / Register: vertically center the card in the space between the
   navbar and the fixed footer, so the gap above and below it stays equal
   no matter the viewport height. */
.auth-page-container {
  flex: 1 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
}
.auth-page-container .auth-wrapper,
.auth-page-container .auth-wrapper-wide {
  margin: 0 auto;
}

/* ---- Membership badge / ID card ---- */
.member-badge {
  width: 100%;
  max-width: 380px;
  margin: 0 auto;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 8px 28px rgba(0,0,0,0.18);
  font-family: 'Montserrat', sans-serif;
  background: #fff;
}
.member-badge-header {
  background: linear-gradient(135deg, var(--ltda-primary) 0%, var(--ltda-primary-dark) 100%);
  color: #fff;
  padding: 1.1rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.member-badge-header .badge-title {
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.4px;
}
.member-badge-body {
  padding: 1.5rem 1.25rem;
  text-align: center;
}
.member-badge-avatar {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  background: var(--ltda-primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  font-weight: 700;
  margin: 0 auto 0.9rem auto;
  border: 3px solid var(--ltda-accent);
}
.member-badge-name {
  font-weight: 700;
  font-size: 1.15rem;
  margin-bottom: 0.15rem;
}
.member-badge-code {
  display: inline-block;
  background: var(--ltda-accent);
  color: #222;
  font-weight: 700;
  letter-spacing: 1px;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.9rem;
  margin: 0.4rem 0 1rem 0;
}
.member-badge-details {
  text-align: left;
  font-size: 0.88rem;
  border-top: 1px dashed #ccc;
  padding-top: 0.9rem;
}
.member-badge-details div {
  display: flex;
  justify-content: space-between;
  padding: 0.2rem 0;
}
.member-badge-details span:first-child {
  color: #777;
}
.member-badge-details span:last-child {
  font-weight: 600;
}
.member-badge-footer {
  background: #f5f6f8;
  text-align: center;
  padding: 0.6rem;
  font-size: 0.7rem;
  color: #888;
  letter-spacing: 0.5px;
}

/* ---- Passport photo preview (registration) ---- */
.passport-preview-wrap {
  position: relative;
  display: inline-block;
  cursor: pointer;
}
.passport-preview {
  width: 130px;
  height: 130px;
  border-radius: 50%;
  background: var(--ltda-passport-bg);
  border: 3px solid var(--ltda-primary);
  overflow: hidden;
  flex: none;
  font-size: 2.4rem;
  transition: border-color 0.15s ease;
}
.passport-preview-wrap:hover .passport-preview {
  border-color: var(--ltda-accent);
}
.passport-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.passport-preview-edit {
  position: absolute;
  right: 2px;
  bottom: 2px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--ltda-accent);
  color: #222;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 3px solid var(--ltda-topbar-bg);
  font-size: 0.9rem;
  box-shadow: 0 2px 8px rgba(0,0,0,0.22);
}
.doc-status {
  font-size: 0.85rem;
  min-height: 1.2em;
}

/* ---- Section headers used to group long forms (e.g. registration) ---- */
.form-section-title {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--ltda-primary);
  margin: 2rem 0 1.1rem;
  padding-bottom: 0.55rem;
  border-bottom: 1px solid var(--ltda-topbar-border);
}
.form-section-title:first-of-type {
  margin-top: 0;
}

/* ---- Document/ID layout verification badges (profile uploads) ---- */
.doc-verify-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.82rem;
  margin-top: 0.35rem;
}
.doc-verify-badge.ok { color: #146c43; }
.doc-verify-badge.warn { color: #b02a37; }
.doc-verify-badge.pending { color: #6c757d; }
.doc-verify-warning-list {
  font-size: 0.8rem;
  margin: 0.25rem 0 0 0;
  padding-left: 1.1rem;
  color: #b02a37;
}

/* ---- Registration wizard step indicator ---- */
.ltda-wizard-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}
.wizard-step-dot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.2rem;
  color: #8a8f98;
  cursor: default;
}
.wizard-step-dot span {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 2px solid #d8dce1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.8rem;
  transition: all 0.2s ease;
}
.wizard-step-dot small {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}
.wizard-step-dot.active span {
  border-color: var(--ltda-primary);
  background: var(--ltda-gradient);
  color: #fff;
}
.wizard-step-dot.active small,
.wizard-step-dot.done small {
  color: var(--ltda-primary);
  font-weight: 600;
}
.wizard-step-dot.done span {
  border-color: var(--ltda-green);
  background: var(--ltda-green);
  color: #fff;
  cursor: pointer;
}
.wizard-step-line {
  flex: 1 1 auto;
  height: 2px;
  background: #d8dce1;
  max-width: 60px;
}

/* ---- Print styles: used for the membership list and badge ---- */
@media print {
  .no-print, .no-print * {
    display: none !important;
  }
  .ltda-layout, .ltda-main {
    display: block !important;
  }
  .card {
    box-shadow: none !important;
    border: 1px solid #ddd !important;
  }
  body {
    background: #fff !important;
  }
}

/* ---- Page locator (breadcrumb) ---- */
.ltda-breadcrumb {
  font-size: 0.78rem;
  color: #8a8f98;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  white-space: nowrap;
}
.ltda-breadcrumb span,
.ltda-breadcrumb a {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.ltda-breadcrumb a {
  color: #8a8f98;
  text-decoration: none;
  flex: none;
}
.ltda-breadcrumb a:hover {
  color: var(--ltda-primary);
  text-decoration: underline;
}
.ltda-breadcrumb .current {
  color: var(--ltda-text);
  font-weight: 600;
}
@media (max-width: 767.98px) {
  /* Remove the page locator (breadcrumb) entirely on mobile - the sidebar
     offcanvas + page title already make it clear where you are, and the
     topbar is too narrow on phones to spare room for it. */
  .ltda-breadcrumb { display: none; }
}

/* ---- Floating / toast-style flash messages ---- */
.ltda-toast-stack {
  position: fixed;
  top: 64px;
  right: 14px;
  z-index: 1080;
  width: min(92vw, 360px);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
@media (max-width: 991.98px) {
  .ltda-toast-stack { top: 60px; }
}
.ltda-toast-stack .alert {
  box-shadow: 0 8px 24px rgba(0,0,0,0.18);
  font-size: 0.95rem;
  animation: ltda-toast-in 0.25s ease;
  position: relative;
  overflow: hidden;
  padding-bottom: 0.9rem;
}
/* Progress line along the bottom edge of a toast, showing how long is left
   before it auto-closes. Driven by JS setting --ltda-toast-duration and
   toggling .ltda-toast-progress-run to start the shrink animation. */
.ltda-toast-progress {
  position: absolute;
  left: 0;
  bottom: 0;
  height: 3px;
  width: 100%;
  background: currentColor;
  opacity: 0.35;
  transform-origin: left;
}
.ltda-toast-progress-run {
  animation: ltda-toast-progress-shrink linear forwards;
  animation-duration: var(--ltda-toast-duration, 6s);
}
.ltda-toast-progress-paused {
  animation-play-state: paused;
}
@keyframes ltda-toast-progress-shrink {
  from { transform: scaleX(1); }
  to { transform: scaleX(0); }
}
@media (prefers-reduced-motion: reduce) {
  .ltda-toast-progress-run { animation: none; }
}
@keyframes ltda-toast-in {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ---- Sidebar grouped nav (dropdown-style collapsible sections) ---- */
.ltda-nav-group-toggle {
  width: 100%;
  text-align: left;
  background: transparent;
  border: none;
  color: #f5f6f8 !important;
  border-radius: 8px;
  padding: 0.6rem 0.9rem;
  margin-bottom: 3px;
  display: flex;
  align-items: center;
  font-weight: 500;
  font-size: 0.86rem;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  opacity: 0.85;
}
.ltda-nav-group-toggle:hover {
  background-color: rgba(255,255,255,0.1);
  opacity: 1;
}
.ltda-nav-group-toggle .bi-chevron-down {
  margin-left: auto;
  transition: transform 0.2s ease;
  font-size: 0.75rem;
}
.ltda-nav-group-toggle[aria-expanded="true"] .bi-chevron-down {
  transform: rotate(180deg);
}
.ltda-nav-group .nav-link {
  padding-left: 1.6rem;
  font-size: 0.86rem;
}

/* ---- Responsive tables: normal table on desktop, stacked cards on mobile ---- */
@media (max-width: 767.98px) {
  .ltda-responsive-table thead {
    display: none;
  }
  .ltda-responsive-table, .ltda-responsive-table tbody, .ltda-responsive-table tr, .ltda-responsive-table td {
    display: block;
    width: 100%;
  }
  .ltda-responsive-table tr {
    margin-bottom: 0.9rem;
    border: 1px solid var(--ltda-topbar-border);
    border-radius: 12px;
    padding: 0.6rem 0.85rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  }
  .ltda-responsive-table td {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    text-align: right;
    border: none !important;
    padding: 0.35rem 0 !important;
  }
  .ltda-responsive-table td::before {
    content: attr(data-label);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.7rem;
    letter-spacing: 0.3px;
    color: #8a8f98;
    text-align: left;
    flex: none;
  }
  .ltda-responsive-table td:empty,
  .ltda-responsive-table td[data-label=""] {
    display: none;
  }
}

/* ---- List pages: sticky "Add New" action bar above the list ---- */
.ltda-list-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}
