:root {
  --bg-main: #0a1324;
  --bg-panel: #101c34;
  --bg-panel-soft: #162544;
  --card-light: #14233f;
  --card-light-2: #101c34;
  --card-dark: #101c34;
  --card-dark-2: #162544;
  --card-glass: rgba(18, 32, 58, 0.88);
  --border-cyan: rgba(56, 189, 248, 0.22);
  --border-gold: rgba(234, 179, 8, 0.3);
  --text-main: #e2e8f0;
  --text-muted: #94a3b8;
  --text-dark: #e2e8f0;
  --text-dark-muted: #94a3b8;
  --text-strong: #f8fafc;
  --label-on-light: #94a3b8;
  --label-on-light-alt: #cbd5e1;
  --subtitle-on-light: #94a3b8;
  --value-on-light: #f8fafc;
  --gold: #eab308;
  --gold-dark: #ca8a04;
  --cyan: #38bdf8;
  --blue: #3b82f6;
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #f87171;
  --tab-inactive-color: #cbd5e1;
  --tab-inactive-bg: var(--bg-panel-soft);
  --tab-inactive-border: rgba(56, 189, 248, 0.16);
  --navy-950: var(--bg-main);
  --navy-900: var(--bg-panel);
  --navy-850: var(--bg-panel-soft);
  --royal: var(--blue);
  --royal-soft: #60a5fa;
  --cyan-soft: rgba(56, 189, 248, 0.16);
  --gold-soft: #fde047;
  --glass: var(--card-light);
  --glass-line: rgba(255, 255, 255, 0.08);
  --ink: #f1f5f9;
  --muted: #94a3b8;
  --sidebar-width: 316px;
  --sidebar-width-collapsed: 92px;
  --topbar-height: 86px;
  --font-primary: "Barlow", "Barlow Semi Condensed", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-heading: var(--font-primary);
  --font-ui: var(--font-primary);
  --bs-body-font-family: var(--font-primary);
  --page-pad: clamp(1rem, 2.5vw, 2rem);
  --section-gap: 1.5rem;
  --card-pad: clamp(1.15rem, 2vw, 1.5rem);
  --filter-gap: 0.75rem;
}

/* Independent Cell Leader Portal */
.cell-portal-shell { display: grid; gap: 1.25rem; padding-bottom: 5rem; width: 100%; max-width: 100%; min-width: 0; box-sizing: border-box; overflow-x: clip; }
.cell-portal-hero { position: relative; overflow: hidden; display: flex; justify-content: space-between; gap: 2rem; padding: clamp(1.4rem, 3vw, 2.4rem); border: 1px solid rgba(85,214,190,.28); border-radius: 24px; background: radial-gradient(circle at 85% 15%, rgba(85,214,190,.18), transparent 32%), linear-gradient(135deg, #0a1730, #102647); box-shadow: 0 22px 60px rgba(2,8,23,.28); width: 100%; max-width: 100%; min-width: 0; box-sizing: border-box; }
.cell-portal-hero h2 { margin: .3rem 0 .4rem; font-family: var(--font-primary); font-weight: 800; font-size: clamp(2rem, 5vw, 3.8rem); color: #fff; }
.cell-portal-hero p { margin: 0; color: #b8c7dc; }
.cell-portal-identity { display: inline-flex; align-items: center; gap: .7rem; margin-top: 1rem; padding: .4rem .75rem; border-radius: 999px; background: rgba(255,255,255,.08); color: #d7e4f4; }
.cell-portal-identity span { color: #55d6be; font-weight: 800; text-transform: uppercase; font-size: .72rem; letter-spacing: .08em; }
.cell-portal-hero-actions { min-width: min(100%, 270px); display: flex; flex-direction: column; align-items: stretch; justify-content: center; gap: .7rem; }
.cell-portal-hero-actions label { color: #b8c7dc; font-size: .78rem; font-weight: 700; }
.cell-portal-filters label { color: #40546d; font-size: .78rem; font-weight: 800; }
.cell-portal-hero-actions select, .cell-portal-filters select { margin-top: .3rem; }
.cell-portal-nav { position: sticky; top: calc(.5rem - var(--page-pad)); z-index: 15; display: flex; gap: .45rem; overflow-x: auto; padding: .65rem; border: 1px solid rgba(148,163,184,.16); border-radius: 16px; background: rgba(7,16,35,.96); box-shadow: 0 12px 28px rgba(2,8,23,.24); backdrop-filter: blur(14px); scrollbar-width: none; }
.cell-portal-nav::-webkit-scrollbar { display: none; }
.cell-portal-nav button { flex: 0 0 auto; border: 0; border-radius: 999px; padding: .55rem .85rem; color: #b8c7dc; background: rgba(148,163,184,.08); font-size: .78rem; font-weight: 800; }
.cell-portal-nav button:hover { color: #061425; background: #55d6be; }
.cell-portal-filters { display: grid; grid-template-columns: repeat(6, minmax(130px, 1fr)); gap: .75rem; padding: 1rem; width: 100%; max-width: 100%; min-width: 0; box-sizing: border-box; }
.cell-portal-section { scroll-margin-top: calc(var(--topbar-height, 72px) + 6rem); width: 100%; max-width: 100%; min-width: 0; box-sizing: border-box; }
.cell-portal-section-title { margin-bottom: 1rem; }
.cell-portal-section-title > div { display: flex; align-items: center; gap: .8rem; }
.cell-portal-section-title h3 { margin: 0; color: #f8fafc; font-size: 1.15rem; }
.cell-portal-section-title p { margin: .2rem 0 0; color: #91a4be; font-size: .85rem; }
.cell-portal-section-icon { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 13px; color: #55d6be; background: rgba(85,214,190,.12); }
.cell-portal-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .8rem; width: 100%; max-width: 100%; min-width: 0; box-sizing: border-box; }
.cell-portal-kpis article { min-height: 126px; display: grid; grid-template-columns: auto 1fr; align-content: center; gap: .35rem .7rem; padding: 1rem; border: 1px solid rgba(148,163,184,.15); border-radius: 18px; background: linear-gradient(145deg, rgba(14,31,58,.9), rgba(8,19,38,.9)); min-width: 0; max-width: 100%; box-sizing: border-box; overflow: hidden; }
.cell-portal-kpis article > i { grid-row: 1 / span 2; align-self: center; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 13px; color: #55d6be; background: rgba(85,214,190,.12); font-size: 1.1rem; }
.cell-portal-kpis article span { color: #91a4be; font-size: .76rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; min-width: 0; overflow-wrap: anywhere; word-break: break-word; }
.cell-portal-kpis article strong { color: #fff; font-size: clamp(1.05rem, 2vw, 1.55rem); line-height: 1.1; overflow-wrap: anywhere; word-break: break-word; min-width: 0; }
.cell-portal-kpis--compact { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.cell-portal-meta { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .75rem; margin-top: .8rem; width: 100%; max-width: 100%; min-width: 0; box-sizing: border-box; }
.cell-portal-meta div { padding: .9rem 1rem; border-left: 3px solid #55d6be; border-radius: 10px; background: rgba(15,31,55,.65); }
.cell-portal-meta span, .cell-portal-meta strong { display: block; }
.cell-portal-meta span { color: #91a4be; font-size: .75rem; }
.cell-portal-meta strong { color: #eaf2ff; margin-top: .2rem; }
.cell-portal-alerts { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: .75rem; }
.cell-portal-alerts article { display: flex; gap: .75rem; padding: 1rem; border-radius: 15px; border: 1px solid rgba(148,163,184,.16); background: rgba(12,26,49,.82); }
.cell-portal-alerts article > i { font-size: 1.15rem; }
.cell-portal-alerts .is-warning > i { color: #ffd166; } .cell-portal-alerts .is-danger > i { color: #ff7b87; } .cell-portal-alerts .is-info > i { color: #4ea8de; } .cell-portal-alerts .is-success > i { color: #55d6be; }
.cell-portal-alerts strong { color: #f8fafc; } .cell-portal-alerts p { margin: .25rem 0 0; color: #91a4be; font-size: .82rem; }
.cell-portal-table-wrap { overflow-x: auto; padding: .5rem; }
.cell-portal-table { min-width: 900px; margin: 0; color: #dbe7f7; }
.cell-portal-table th { color: #91a4be; font-size: .72rem; text-transform: uppercase; letter-spacing: .04em; }
.cell-portal-table td { vertical-align: middle; }
.cell-portal-table td strong, .cell-portal-table td small { display: block; }
.cell-portal-table td small { max-width: 220px; margin-top: .2rem; color: #8295ae; }
.cell-portal-grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 1rem; }
.cell-portal-grid-2 > .panel, .cell-portal-chart-grid > .panel { padding: 1.1rem; }
.cell-portal-grid-2 > .panel .cell-portal-section-title h3,
.cell-portal-chart-grid > .panel .cell-portal-section-title h3 { color: #061329; }
.cell-portal-grid-2 > .panel .cell-portal-section-title p,
.cell-portal-chart-grid > .panel .cell-portal-section-title p { color: #526780; }
.cell-portal-grid-2 > .panel .cell-portal-bar-row,
.cell-portal-chart-grid > .panel .cell-portal-bar-row,
.cell-portal-grid-2 > .panel .cell-portal-legend div,
.cell-portal-chart-grid > .panel .cell-portal-legend div { color: #526780; }
.cell-portal-grid-2 > .panel .cell-portal-bar-row strong,
.cell-portal-chart-grid > .panel .cell-portal-bar-row strong,
.cell-portal-grid-2 > .panel .cell-portal-legend strong,
.cell-portal-chart-grid > .panel .cell-portal-legend strong,
.cell-portal-grid-2 > .panel .cell-portal-ranking strong { color: #10233e; }
.cell-portal-grid-2 > .panel .cell-portal-ranking { border-bottom-color: rgba(71,85,105,.18); }
.cell-portal-activity-grid, .cell-portal-programs { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: .8rem; }
.cell-portal-activity-grid article, .cell-portal-programs article { padding: 1rem; border: 1px solid rgba(148,163,184,.15); border-radius: 16px; background: rgba(11,25,48,.86); }
.cell-portal-activity-grid article > span, .cell-portal-programs article span { color: #55d6be; font-size: .75rem; font-weight: 800; }
.cell-portal-activity-grid h4, .cell-portal-programs h4 { margin: .5rem 0; color: #fff; font-size: 1rem; }
.cell-portal-activity-grid p, .cell-portal-programs p, .cell-portal-programs footer { color: #91a4be; font-size: .82rem; }
.cell-portal-activity-grid article > div, .cell-portal-programs article > div { display: flex; align-items: center; justify-content: space-between; gap: .6rem; }
.cell-portal-programs article > strong { display: block; margin: .65rem 0; color: #dce8f7; font-size: .86rem; }
.cell-portal-chart-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: .8rem; }
.cell-portal-chart-grid h4 { color: #f8fafc; font-size: .95rem; }
.cell-portal-bars { display: grid; gap: .55rem; }
.cell-portal-bar-row { display: grid; grid-template-columns: minmax(75px, .8fr) minmax(100px, 1.5fr) 28px; align-items: center; gap: .55rem; color: #91a4be; font-size: .72rem; }
.cell-portal-bar-row > div { height: 8px; overflow: hidden; border-radius: 99px; background: rgba(148,163,184,.13); }
.cell-portal-bar-row i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #4ea8de, #55d6be); }
.cell-portal-bar-row strong { color: #eaf2ff; }
.cell-portal-donut-wrap { display: grid; grid-template-columns: 110px 1fr; align-items: center; gap: 1rem; }
.cell-portal-donut { position: relative; display: grid; place-items: center; align-content: center; width: 108px; aspect-ratio: 1; border-radius: 50%; }
.cell-portal-donut::after { content: ""; position: absolute; inset: 15px; border-radius: 50%; background: #0d1c35; }
.cell-portal-donut strong, .cell-portal-donut span { position: relative; z-index: 1; } .cell-portal-donut strong { color: #fff; font-size: 1.35rem; } .cell-portal-donut span { color: #91a4be; font-size: .65rem; }
.cell-portal-legend { display: grid; gap: .38rem; }
.cell-portal-legend div { display: grid; grid-template-columns: 9px 1fr auto; align-items: center; gap: .45rem; color: #91a4be; font-size: .72rem; }
.cell-portal-legend i { width: 9px; height: 9px; border-radius: 50%; }
.cell-portal-legend strong { color: #eaf2ff; }
.cell-portal-ranking { display: grid; grid-template-columns: 28px 1fr auto; align-items: center; gap: .55rem; padding: .6rem 0; border-bottom: 1px solid rgba(148,163,184,.1); }
.cell-portal-ranking span { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; color: #061425; background: #55d6be; font-size: .7rem; font-weight: 900; }
.cell-portal-ranking strong { color: #dbe7f7; } .cell-portal-ranking b { color: #ffd166; }
.cell-portal-empty { max-width: 720px; margin: 3rem auto; padding: 3rem; text-align: center; }
.cell-portal-empty > i { font-size: 3rem; color: #55d6be; }

@media (max-width: 1100px) {
  .cell-portal-filters { grid-template-columns: repeat(3, minmax(130px,1fr)); }
  .cell-portal-kpis, .cell-portal-kpis--compact { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .cell-portal-meta, .cell-portal-alerts, .cell-portal-chart-grid, .cell-portal-activity-grid, .cell-portal-programs { grid-template-columns: repeat(2, minmax(0,1fr)); }
}

@media (max-width: 768px) {
  .cell-portal-shell { padding-bottom: 5.5rem; }
  .cell-portal-hero { flex-direction: column; border-radius: 18px; }
  .cell-portal-hero-actions { width: 100%; }
  .cell-portal-nav { top: calc(.35rem - var(--page-pad)); margin-inline: -.25rem; border-radius: 12px; }
  .cell-portal-filters { grid-template-columns: 1fr; }
  .cell-portal-kpis, .cell-portal-kpis--compact, .cell-portal-meta, .cell-portal-alerts, .cell-portal-grid-2, .cell-portal-chart-grid, .cell-portal-activity-grid, .cell-portal-programs { grid-template-columns: 1fr; }
  .cell-portal-kpis article { min-height: 98px; }
  .cell-portal-table-wrap { overflow: visible !important; padding: 0.25rem 0 !important; background: transparent !important; border: 0 !important; box-shadow: none !important; }
  .cell-portal-table { min-width: 0 !important; width: 100% !important; border-collapse: separate !important; border-spacing: 0 0.85rem !important; }
  .cell-portal-table thead { display: none !important; }
  .cell-portal-table tbody, .cell-portal-table tr, .cell-portal-table td { display: block !important; width: 100% !important; }
  .cell-portal-table tr {
    margin-bottom: 1rem !important;
    padding: 1rem 1.15rem !important;
    border: 1px solid rgba(229, 179, 66, 0.25) !important;
    border-radius: 16px !important;
    background: linear-gradient(135deg, rgba(11, 23, 44, 0.96), rgba(16, 33, 62, 0.94)) !important;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.08) !important;
    color: #f8fbff !important;
  }
  .cell-portal-table td {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    gap: 0.75rem !important;
    border: 0 !important;
    padding: 0.45rem 0 !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07) !important;
    text-align: right !important;
    background: transparent !important;
    color: #e2e8f0 !important;
    font-size: 0.88rem;
  }
  .cell-portal-table td:last-child {
    border-bottom: 0 !important;
  }
  .cell-portal-table td::before {
    content: attr(data-label);
    color: #94a3b8 !important;
    text-align: left;
    font-size: 0.74rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    flex-shrink: 0;
  }
  .cell-portal-table td[data-label="Nome"] {
    display: block !important;
    padding-bottom: 0.65rem !important;
    margin-bottom: 0.35rem !important;
    border-bottom: 1px solid rgba(229, 179, 66, 0.22) !important;
    text-align: left !important;
  }
  .cell-portal-table td[data-label="Nome"]::before {
    display: none !important;
  }
  .cell-portal-table td[data-label="Nome"] strong {
    font-size: 1.08rem !important;
    color: #ffffff !important;
    font-weight: 700 !important;
    letter-spacing: 0.01em;
    display: block;
  }
  .cell-portal-table td[data-label="Nome"] small {
    color: #94a3b8 !important;
    font-size: 0.82rem !important;
    margin-top: 0.25rem;
    display: block;
  }
  .cell-portal-table td[data-label="Telefone"] {
    font-family: var(--font-mono, monospace);
    color: #38bdf8 !important;
    font-weight: 600;
  }
  .cell-portal-table td[data-label="Acções"],
  .cell-portal-table td:last-child {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    padding-top: 0.75rem !important;
    margin-top: 0.4rem !important;
    border-top: 1px dashed rgba(255, 255, 255, 0.12) !important;
  }
  .cell-portal-table td[data-label="Acções"]::before,
  .cell-portal-table td:last-child::before {
    display: none !important;
  }
  .cell-portal-table td[data-label="Acções"] .btn-group,
  .cell-portal-table td:last-child .btn-group {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 0.5rem !important;
    width: 100% !important;
  }
  .cell-portal-table td[data-label="Acções"] .btn,
  .cell-portal-table td:last-child .btn,
  .cell-portal-table td:last-child .action-btn {
    flex: 1 1 auto !important;
    min-height: 40px !important;
    min-width: 40px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-radius: 10px !important;
    font-size: 0.95rem !important;
    padding: 0.45rem 0.75rem !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25) !important;
  }
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  color: #f8fbff;
  font-family: var(--font-ui);
  background:
    radial-gradient(circle at top left, rgba(32, 215, 255, 0.16), transparent 32rem),
    radial-gradient(circle at bottom right, rgba(23, 92, 255, 0.18), transparent 34rem),
    linear-gradient(135deg, var(--navy-950), var(--navy-900));
}

body:has(#appView:not(.d-none)) {
  overflow: hidden;
}

h1,
h2,
.login-panel h1,
.ops-topbar h1,
.ops-hero h2,
.panel-title {
  font-family: var(--font-heading);
}

h3,
h4,
h5,
h6,
p,
span,
small,
strong,
label,
button,
input,
select,
textarea,
table,
.ops-brand,
.ops-brand *,
.sidebar-nav,
.sidebar-nav *,
.ops-sidebar,
.ops-sidebar *,
.ops-topbar,
.ops-topbar *,
.metric-card,
.metric-card *,
.record-card,
.record-card *,
.chart-card,
.chart-card *,
.panel,
.panel *,
.ops-modal,
.ops-modal *,
.status-pill,
.filter-bar,
.action-btn,
.form-label {
  font-family: var(--font-ui);
}

.section-title-elegant,
.hero-title,
.page-title {
  font-family: var(--font-heading);
}

.login-panel h1,
.ops-topbar h1,
.ops-hero h2,
.panel-title {
  font-family: var(--font-heading);
}

.eyebrow {
  color: var(--gold-soft);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.btn-ce-gold {
  background: rgba(234, 179, 8, 0.12) !important;
  background-image: none !important;
  color: #facc15 !important;
  border: 1px solid rgba(234, 179, 8, 0.3) !important;
  font-weight: 600;
  box-shadow: none !important;
  transition: all 0.18s ease;
}

.btn-ce-gold:hover {
  background: rgba(234, 179, 8, 0.22) !important;
  border-color: rgba(234, 179, 8, 0.5) !important;
  color: #fef08a !important;
  box-shadow: none !important;
}

.btn-outline-light {
  background: rgba(255, 255, 255, 0.04) !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  color: #cbd5e1 !important;
  box-shadow: none !important;
  transition: all 0.18s ease;
}

.btn-outline-light:hover {
  background: rgba(255, 255, 255, 0.08) !important;
  border-color: rgba(255, 255, 255, 0.22) !important;
  color: #f8fafc !important;
}

.btn-outline-secondary {
  background: rgba(255, 255, 255, 0.03) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  color: #94a3b8 !important;
  box-shadow: none !important;
  transition: all 0.18s ease;
}

.btn-outline-secondary:hover {
  background: rgba(255, 255, 255, 0.07) !important;
  border-color: rgba(255, 255, 255, 0.18) !important;
  color: #e2e8f0 !important;
}

.btn-outline-warning {
  background: rgba(234, 179, 8, 0.08) !important;
  border: 1px solid rgba(234, 179, 8, 0.25) !important;
  color: #facc15 !important;
  box-shadow: none !important;
  transition: all 0.18s ease;
}

.btn-outline-warning:hover {
  background: rgba(234, 179, 8, 0.18) !important;
  border-color: rgba(234, 179, 8, 0.45) !important;
  color: #fef08a !important;
}

.btn-outline-info {
  background: rgba(56, 189, 248, 0.08) !important;
  border: 1px solid rgba(56, 189, 248, 0.25) !important;
  color: #38bdf8 !important;
  box-shadow: none !important;
  transition: all 0.18s ease;
}

.btn-outline-info:hover {
  background: rgba(56, 189, 248, 0.18) !important;
  border-color: rgba(56, 189, 248, 0.45) !important;
  color: #7dd3fc !important;
}

.login-shell {
  min-height: 100vh;
  margin: 0;
  padding: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #060e1a;
  box-sizing: border-box;
  font-family: var(--font-primary);
  color: #ffffff;
}

.login-frame {
  width: 100%;
  max-width: 1400px;
  min-height: calc(100vh - 3rem);
  border: 1px solid rgba(59, 130, 246, 0.25);
  border-radius: 24px;
  position: relative;
  display: flex;
  flex-direction: column;
  background:
    linear-gradient(135deg, rgba(8, 17, 33, 0.88) 0%, rgba(5, 12, 24, 0.94) 100%),
    url("https://embaixada-de-cristo.obiuba.com/assets/web/leadership-team.jpg") center / cover no-repeat;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.65), inset 0 0 0 1px rgba(255, 255, 255, 0.05);
  overflow: hidden;
}

.login-header {
  padding: 2.2rem 3rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  box-sizing: border-box;
}

.login-brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  text-decoration: none;
}

.login-brand-logo {
  height: 58px;
  width: auto;
  max-width: 95px;
  object-fit: contain;
  display: block;
  flex-shrink: 0;
  filter: drop-shadow(0 2px 10px rgba(0, 0, 0, 0.45));
}

.login-brand-text {
  display: flex;
  flex-direction: column;
  color: #ffffff;
  font-size: 0.84rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  line-height: 1.2;
  text-transform: uppercase;
}

.login-header-tag {
  color: #e5b342;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.login-card-container {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem 1.5rem 3rem;
  width: 100%;
  box-sizing: border-box;
}

.login-panel {
  width: 100%;
  max-width: 470px;
  background: #0f1c2e;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 20px;
  padding: 2.2rem 2.8rem 2.4rem;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(255, 255, 255, 0.04);
  position: relative;
  box-sizing: border-box;
}

.login-panel-top {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 0.75rem;
}

.login-panel .dash-lang-switch {
  background: #15253b;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  padding: 3px;
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.login-panel .dash-lang-switch button {
  border: none;
  background: transparent;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.2s ease;
  line-height: 1;
}

.login-panel .dash-lang-switch button.active {
  background: #e5b342;
  color: #0a1424;
  font-weight: 700;
}

.login-gold-bar {
  width: 44px;
  height: 3.5px;
  background: #e5b342;
  border-radius: 3px;
  margin-bottom: 0.85rem;
}

.login-title {
  font-family: var(--font-primary);
  font-size: 2.35rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.15;
  margin: 0 0 0.45rem;
  letter-spacing: -0.02em;
}

.login-subtitle {
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.92rem;
  margin: 0 0 1.8rem;
  line-height: 1.4;
}

.login-form .form-label {
  color: #ffffff;
  font-size: 0.88rem;
  font-weight: 600;
  margin-bottom: 0.45rem;
  display: block;
}

.login-shell .form-control {
  background-color: #152238 !important;
  border: 1px solid #283e5e !important;
  border-radius: 10px !important;
  color: #ffffff !important;
  padding: 0.75rem 1rem !important;
  font-size: 0.95rem !important;
  width: 100%;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.login-shell .form-control::placeholder {
  color: rgba(255, 255, 255, 0.35) !important;
  opacity: 1;
}

.login-shell .form-control:focus {
  border-color: #e5b342 !important;
  box-shadow: 0 0 0 3px rgba(229, 179, 66, 0.2) !important;
  outline: none;
}

.login-password-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.login-password-wrapper .form-control {
  padding-right: 2.8rem !important;
}

.login-password-toggle {
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 2.8rem;
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.45);
  font-size: 1.15rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: color 0.2s;
  padding: 0;
}

.login-password-toggle:hover {
  color: #ffffff;
}

.login-forgot-wrapper {
  display: flex;
  justify-content: flex-end;
  margin-top: 0.45rem;
}

.login-forgot-btn {
  background: transparent;
  border: none;
  color: #e5b342;
  font-size: 0.86rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  padding: 0;
  transition: color 0.2s;
}

.login-forgot-btn:hover {
  color: #f7d070;
  text-decoration: underline;
}

.login-submit-btn {
  background: linear-gradient(135deg, #f7d070 0%, #e5b342 100%);
  border: none;
  border-radius: 10px;
  color: #0a1424;
  font-weight: 700;
  font-size: 1rem;
  padding: 0.88rem 1.5rem;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(229, 179, 66, 0.32);
  transition: all 0.2s ease;
  margin-top: 0.5rem;
}

.login-submit-btn:hover {
  background: linear-gradient(135deg, #fae08f 0%, #f0c355 100%);
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(229, 179, 66, 0.4);
  color: #050a12;
}

.login-submit-btn:active {
  transform: translateY(0);
  box-shadow: 0 3px 10px rgba(229, 179, 66, 0.25);
}

.login-footer-note {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.82rem;
  margin-top: 1.4rem;
  margin-bottom: 0;
  text-align: left;
  line-height: 1.4;
}

@media (max-width: 768px) {
  .login-shell {
    padding: 0.75rem;
  }
  .login-frame {
    border-radius: 16px;
    min-height: calc(100vh - 1.5rem);
  }
  .login-header {
    padding: 1.5rem 1.25rem 0.5rem;
  }
  .login-card-container {
    padding: 1rem 1rem 2rem;
  }
  .login-panel {
    padding: 1.8rem 1.5rem 2rem;
    border-radius: 16px;
  }
  .login-title {
    font-size: 1.95rem;
  }
}

.form-control,
.form-select {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 0.85rem;
  background-color: rgba(255, 255, 255, 0.04);
  color: #e2e8f0;
}

.form-control:focus,
.form-select:focus {
  background-color: #0c1f40;
  border-color: rgba(234, 179, 8, 0.5);
  color: #ffffff;
  box-shadow: 0 0 0 0.22rem rgba(234, 179, 8, 0.15);
}

.dash-lang-switch {
  display: inline-flex;
  gap: 0.24rem;
  padding: 0.2rem;
  border: 1px solid rgba(32, 215, 255, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.dash-lang-switch button {
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: rgba(248, 251, 255, 0.72);
  font-size: 0.72rem;
  font-weight: 900;
  padding: 0.35rem 0.72rem;
}

.dash-lang-switch button.active {
  background: linear-gradient(135deg, var(--gold-soft), var(--gold));
  color: var(--navy-950);
}

.dash-theme-switch {
  display: inline-flex;
  gap: 0.24rem;
  padding: 0.2rem;
  border: 1px solid rgba(32, 215, 255, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.dash-theme-switch .theme-toggle-btn {
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: rgba(248, 251, 255, 0.72);
  font-size: 0.78rem;
  padding: 0.35rem 0.65rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  line-height: 1;
}

.dash-theme-switch .theme-toggle-btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
}

.dash-theme-switch .theme-toggle-btn.active {
  background: linear-gradient(135deg, var(--gold-soft), var(--gold));
  color: var(--navy-950);
  font-weight: 900;
  box-shadow: 0 2px 8px rgba(245, 199, 85, 0.35);
}

.ops-shell {
  min-height: 100vh;
  height: 100vh;
  overflow: hidden;
}

.ops-sidebar {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 30;
  width: var(--sidebar-width);
  height: 100vh;
  padding: 1rem;
  overflow-x: hidden;
  overflow-y: auto;
  scrollbar-width: thin;
  background:
    linear-gradient(180deg, rgba(10, 23, 48, 0.98), rgba(3, 8, 22, 0.98)),
    radial-gradient(circle at top, rgba(32, 215, 255, 0.16), transparent 18rem);
  border-right: 1px solid rgba(32, 215, 255, 0.16);
  transition: width 0.24s ease, transform 0.22s ease;
}

.sidebar-head {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  margin-bottom: 1rem;
}

.sidebar-head .ops-brand {
  flex: 1;
  min-width: 0;
  margin-bottom: 0;
}

.sidebar-collapse-btn {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.2rem;
  height: 2.2rem;
  border: 1px solid rgba(32, 215, 255, 0.24);
  border-radius: 0.75rem;
  color: rgba(248, 251, 255, 0.82);
  background: rgba(255, 255, 255, 0.06);
  transition: border-color 0.18s ease, background 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.sidebar-collapse-btn:hover {
  color: #fff;
  border-color: rgba(241, 216, 140, 0.72);
  background: rgba(32, 215, 255, 0.12);
}

.ops-shell.is-sidebar-collapsed {
  --sidebar-width: var(--sidebar-width-collapsed);
}

.ops-shell.is-sidebar-collapsed .sidebar-collapse-btn i {
  transform: rotate(180deg);
}

.ops-shell.is-sidebar-collapsed .ops-brand span,
.ops-shell.is-sidebar-collapsed .side-user div,
.ops-shell.is-sidebar-collapsed .nav-item-btn span,
.ops-shell.is-sidebar-collapsed .nav-group-toggle span {
  opacity: 0;
  width: 0;
  overflow: hidden;
  white-space: nowrap;
}

.ops-shell.is-sidebar-collapsed .ops-sidebar {
  padding: 0.85rem 0.65rem;
}

.ops-shell.is-sidebar-collapsed .sidebar-head {
  position: relative;
  display: grid;
  place-items: center;
  gap: 0;
  margin-bottom: 1rem;
  padding-top: 0.2rem;
}

.ops-shell.is-sidebar-collapsed .ops-brand {
  width: 3.25rem;
  height: 3.25rem;
  justify-content: center;
  gap: 0;
  padding: 0;
  border-radius: 999px;
  border-color: rgba(241, 216, 140, 0.38);
  background: rgba(255, 255, 255, 0.08);
}

.ops-shell.is-sidebar-collapsed .side-user {
  width: 3.15rem;
  min-height: 3.15rem;
  justify-content: center;
  padding: 0;
  margin: 0 auto 1rem;
  border-radius: 1rem;
}

.ops-shell.is-sidebar-collapsed .nav-item-btn,
.ops-shell.is-sidebar-collapsed .nav-group-toggle {
  width: 3.05rem;
  height: 3.05rem;
  justify-content: center;
  padding: 0;
  margin-inline: auto;
  border-radius: 0.95rem;
}

.ops-shell.is-sidebar-collapsed .nav-group-chevron {
  display: none;
}

.ops-shell.is-sidebar-collapsed .nav-group {
  margin-top: 0.55rem;
}

.ops-shell.is-sidebar-collapsed .nav-group-toggle {
  display: none;
}

.ops-shell.is-sidebar-collapsed .nav-group .nav-group-body {
  grid-template-rows: 1fr;
}

.ops-shell.is-sidebar-collapsed .ops-brand img {
  width: 2.85rem;
  height: 2.85rem;
  padding: 0;
  object-fit: contain;
  background: transparent;
  border-radius: 0;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.45));
}

.ops-shell.is-sidebar-collapsed .sidebar-collapse-btn {
  position: absolute;
  top: 0;
  right: -0.28rem;
  z-index: 2;
  width: 2.15rem;
  height: 2.15rem;
  border-radius: 999px;
  background: rgba(9, 23, 47, 0.96);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.24);
}

.ops-shell.is-sidebar-collapsed .pulse-dot {
  width: 0.72rem;
  height: 0.72rem;
}

.ops-shell.is-sidebar-collapsed .nav-item-btn i:first-child,
.ops-shell.is-sidebar-collapsed .nav-cell-parent > i:first-child,
.ops-shell.is-sidebar-collapsed .nav-cell-area-icon {
  width: auto;
  min-width: 1.15rem;
  margin: 0;
  color: var(--cyan);
  font-size: 1.08rem;
  text-align: center;
}

.ops-shell.is-sidebar-collapsed .nav-item-btn:hover,
.ops-shell.is-sidebar-collapsed .nav-item-btn.active,
.ops-shell.is-sidebar-collapsed .nav-cell-parent:hover,
.ops-shell.is-sidebar-collapsed .nav-cell-parent.active {
  transform: translateY(-1px);
}

.ops-shell.is-sidebar-collapsed .nav-lock-icon {
  position: absolute;
  right: 0.22rem;
  bottom: 0.18rem;
  width: auto;
  font-size: 0.64rem;
}

.ops-main {
  display: flex;
  flex-direction: column;
  min-width: 0;
  height: 100vh;
  margin-left: var(--sidebar-width);
  overflow: hidden;
  transition: margin-left 0.24s ease;
}

.ops-brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.65rem 0.75rem;
  margin-bottom: 0;
  border: 1px solid rgba(215, 174, 75, 0.2);
  border-radius: 1.1rem;
  color: #fff;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.04);
}

.ops-brand:hover {
  border-color: rgba(215, 174, 75, 0.48);
  color: #fff;
}

.ops-brand img {
  width: 78px;
  height: 52px;
  max-width: 82px;
  object-fit: contain;
  padding: 0;
  border-radius: 0;
  background: transparent;
  flex-shrink: 0;
  filter: drop-shadow(0 3px 10px rgba(0, 0, 0, 0.5));
}

.ops-brand small {
  display: block;
  color: var(--cyan);
  font-family: var(--bs-body-font-family);
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.13em;
}

.side-user {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.9rem;
  margin-bottom: 1.1rem;
  border: 1px solid rgba(32, 215, 255, 0.18);
  border-radius: 1rem;
  background: rgba(32, 215, 255, 0.06);
}

.side-user small {
  display: block;
  color: rgba(248, 251, 255, 0.58);
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
}

.pulse-dot {
  width: 0.68rem;
  height: 0.68rem;
  border-radius: 50%;
  background: var(--cyan);
  box-shadow: 0 0 0 7px rgba(32, 215, 255, 0.1), 0 0 22px rgba(32, 215, 255, 0.8);
}

.nav-group {
  margin-top: 0.85rem;
}

.nav-group-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.55rem;
  margin: 0 0 0.45rem;
  padding: 0.45rem 0.65rem;
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 0.75rem;
  color: var(--gold-soft);
  background: rgba(255, 255, 255, 0.025);
  font-family: var(--font-ui);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-align: left;
  transition: border-color 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.nav-group-toggle:hover {
  color: #fff;
  border-color: rgba(32, 215, 255, 0.28);
  background: rgba(32, 215, 255, 0.08);
}

.nav-group-toggle span {
  flex: 1 1 auto;
  text-align: left;
  transition: opacity 0.2s ease, width 0.2s ease;
}

.nav-group-chevron {
  flex: 0 0 auto;
  margin-left: auto;
  font-size: 0.8rem;
  color: var(--cyan);
  opacity: 0.8;
  transition: transform 0.22s ease;
}

.nav-group.is-expanded .nav-group-chevron {
  transform: rotate(180deg);
}

.nav-group-body {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.24s ease;
}

.nav-group.is-expanded .nav-group-body {
  grid-template-rows: 1fr;
}

.nav-group-body-inner {
  overflow: hidden;
}

/* Primary Sidebar Nav Buttons (Both regular buttons and branch parent triggers) */
.nav-item-btn,
.nav-cell-parent {
  width: 100%;
  min-height: 2.85rem;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.75rem;
  margin-bottom: 0.42rem;
  padding: 0.7rem 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 0.85rem;
  color: rgba(248, 251, 255, 0.8);
  background: rgba(255, 255, 255, 0.035);
  font-family: var(--font-ui);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.035em;
  text-align: left;
  text-transform: uppercase;
  transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}

.nav-item-btn > i:first-child,
.nav-item-btn > .bi:first-child,
.nav-cell-parent > i:first-child,
.nav-cell-parent > .bi:first-child {
  width: 1.25rem;
  min-width: 1.25rem;
  flex: 0 0 1.25rem;
  color: var(--cyan);
  font-size: 1.05rem;
  text-align: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.nav-item-btn span,
.nav-cell-parent span {
  flex: 1 1 auto;
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: inherit;
  line-height: 1.25;
}

.nav-item-btn:hover,
.nav-item-btn.active,
.nav-cell-parent:hover,
.nav-cell-branch.has-active .nav-cell-parent {
  transform: translateX(3px);
  color: #fff;
  border-color: rgba(32, 215, 255, 0.42);
  background: linear-gradient(135deg, rgba(23, 92, 255, 0.28), rgba(32, 215, 255, 0.08));
  box-shadow: 0 0 24px rgba(32, 215, 255, 0.08);
}

.nav-cell-branch {
  margin-bottom: 0.42rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.88rem;
  background: rgba(255, 255, 255, 0.02);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.nav-cell-branch.is-expanded.has-active,
.nav-cell-area.is-expanded.has-active {
  border-color: rgba(32, 215, 255, 0.32);
  box-shadow: 0 0 22px rgba(32, 215, 255, 0.08), inset 0 0 0 1px rgba(241, 216, 140, 0.12);
}

.nav-cell-branch > .nav-cell-parent {
  margin-bottom: 0;
  border: 0;
  background: transparent;
}

.nav-cell-chevron,
.nav-cell-area-chevron {
  flex: 0 0 auto;
  margin-left: auto;
  font-size: 0.8rem;
  color: var(--cyan);
  opacity: 0.75;
  transition: transform 0.22s ease, opacity 0.18s ease;
}

.nav-cell-branch.is-expanded .nav-cell-chevron,
.nav-cell-area.is-expanded .nav-cell-area-chevron {
  transform: rotate(180deg);
  opacity: 1;
}

.nav-cell-body,
.nav-cell-area-body {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.24s ease;
}

.nav-cell-branch.is-expanded .nav-cell-body,
.nav-cell-area.is-expanded .nav-cell-area-body {
  grid-template-rows: 1fr;
}

.nav-cell-body-inner,
.nav-cell-area-body-inner {
  overflow: hidden;
}

.nav-cell-area {
  margin: 0 0.45rem 0.45rem;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 0.78rem;
  background: rgba(255, 255, 255, 0.02);
}

.nav-cell-area-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.65rem;
  padding: 0.58rem 0.72rem;
  border: 0;
  background: transparent;
  color: rgba(241, 216, 140, 0.92);
  font-family: var(--font-ui);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-align: left;
  transition: color 0.18s ease, background 0.18s ease;
}

.nav-cell-area-toggle span {
  flex: 1 1 auto;
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.nav-cell-area-icon {
  flex: 0 0 auto;
  color: var(--cyan);
  font-size: 0.95rem;
}

.nav-cell-area-toggle:hover {
  color: #fff;
  background: rgba(32, 215, 255, 0.06);
}

/* Submenu Child Items */
.nav-cell-item {
  width: calc(100% - 0.85rem);
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin: 0 0.42rem 0.35rem;
  padding: 0.58rem 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 0.7rem;
  color: rgba(248, 251, 255, 0.74);
  background: rgba(255, 255, 255, 0.025);
  font-family: var(--font-ui);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.025em;
  text-align: left;
  transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}

.nav-cell-item > i:first-child,
.nav-cell-item > .bi:first-child {
  width: 1.15rem;
  min-width: 1.15rem;
  flex: 0 0 1.15rem;
  text-align: center;
  font-size: 0.95rem;
  color: var(--cyan);
  opacity: 0.9;
}

.nav-cell-item span {
  flex: 1 1 auto;
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.nav-cell-item:hover,
.nav-cell-item.active {
  transform: translateX(3px);
  color: #fff;
  border-color: rgba(32, 215, 255, 0.45);
  background: linear-gradient(135deg, rgba(23, 92, 255, 0.3), rgba(32, 215, 255, 0.1));
  box-shadow: 0 0 18px rgba(32, 215, 255, 0.12);
}

.cell-route-context {
  margin: 0;
  padding: 0.72rem 0.95rem 0.7rem;
  border: 1px solid rgba(32, 215, 255, 0.16);
  border-top: 1px solid rgba(13, 23, 48, 0.08);
  border-radius: 0 0 1rem 1rem;
  background: linear-gradient(135deg, rgba(7, 18, 37, 0.96), rgba(10, 23, 48, 0.92));
  color: rgba(248, 251, 255, 0.78);
  font-family: var(--font-ui);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.cell-route-sep {
  margin: 0 0.35rem;
  color: rgba(241, 216, 140, 0.8);
}

.review-flag {
  display: inline-flex;
  margin-left: 0.35rem;
  color: #f5c451;
  font-size: 0.82rem;
  vertical-align: middle;
}

.cell-filter-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem;
  flex-wrap: wrap;
  padding: 0.82rem 1rem;
  border: 1px solid rgba(32, 215, 255, 0.24);
  border-radius: 0.9rem;
  background: rgba(32, 215, 255, 0.08);
  color: rgba(248, 251, 255, 0.86);
  font-family: var(--font-ui);
  font-size: 0.82rem;
}

.ops-shell.is-sidebar-collapsed .nav-cell-parent span,
.ops-shell.is-sidebar-collapsed .nav-cell-area-toggle span,
.ops-shell.is-sidebar-collapsed .nav-cell-item span,
.ops-shell.is-sidebar-collapsed .nav-cell-chevron,
.ops-shell.is-sidebar-collapsed .nav-cell-area-chevron {
  opacity: 0;
  width: 0;
  overflow: hidden;
}

.ops-shell.is-sidebar-collapsed .nav-cell-branch,
.ops-shell.is-sidebar-collapsed .nav-cell-area {
  width: 3.05rem;
  margin: 0 auto 0.45rem;
  border-radius: 0.95rem;
  background: transparent;
  border-color: rgba(255, 255, 255, 0.06);
}

.ops-shell.is-sidebar-collapsed .nav-cell-parent,
.ops-shell.is-sidebar-collapsed .nav-cell-area-toggle {
  width: 3.05rem;
  height: 3.05rem;
  justify-content: center;
  padding: 0;
  border-radius: 0.95rem;
}

.ops-shell.is-sidebar-collapsed .nav-cell-body,
.ops-shell.is-sidebar-collapsed .nav-cell-area-body {
  grid-template-rows: 1fr;
}

.ops-shell.is-sidebar-collapsed .nav-cell-item {
  position: relative;
  width: 2.62rem;
  height: 2.62rem;
  display: grid;
  place-items: center;
  margin: 0.3rem auto;
  padding: 0;
  border-radius: 0.82rem;
}

.ops-shell.is-sidebar-collapsed .nav-cell-item::before {
  content: "";
  width: 0.46rem;
  height: 0.46rem;
  border-radius: 999px;
  background: var(--cyan);
  box-shadow: 0 0 14px rgba(34, 211, 238, 0.5);
}

.ops-topbar {
  position: relative;
  flex-shrink: 0;
  z-index: 20;
  min-height: var(--topbar-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  padding: 0.85rem 1.5rem;
  border-bottom: 1px solid rgba(32, 215, 255, 0.16);
  background: rgba(6, 17, 34, 0.92);
  backdrop-filter: blur(18px);
}

.topbar-row-primary {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex: 1 1 auto;
  min-width: 0;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-width: 0;
}

.topbar-title-wrap {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}

.topbar-title-wrap h1 {
  margin: 0;
  font-family: var(--font-heading);
  font-size: clamp(1.2rem, 2.5vw, 1.75rem);
  font-weight: 800;
  color: #ffffff;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  line-height: 1.15;
}

.topbar-title-wrap .eyebrow {
  font-size: 0.72rem;
  font-weight: 800;
  color: #fac638;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-top: 0.2rem;
  line-height: 1;
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin-left: auto;
}

.topbar-row-secondary {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-shrink: 0;
}

.icon-btn {
  width: 42px;
  height: 42px;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(32, 215, 255, 0.28);
  border-radius: 12px;
  color: #fff;
  background: rgba(13, 27, 49, 0.85);
  transition: all 0.2s ease;
}

.icon-btn:hover {
  background: rgba(22, 45, 80, 0.95);
  border-color: rgba(32, 215, 255, 0.55);
  color: #fff;
}

.universal-search-btn {
  height: 42px;
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0 0.85rem;
  min-width: 175px;
  max-width: 250px;
  border: 1px solid rgba(32, 215, 255, 0.28);
  border-radius: 12px;
  background: rgba(13, 27, 49, 0.85);
  color: rgba(248, 251, 255, 0.75);
  font-size: 0.84rem;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.universal-search-btn:hover {
  background: rgba(22, 45, 80, 0.95);
  border-color: rgba(32, 215, 255, 0.55);
  color: #ffffff;
}

.universal-search-btn i {
  color: rgba(248, 251, 255, 0.7);
  font-size: 0.95rem;
}

.universal-search-btn .kbd-pill {
  margin-left: auto;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.15rem 0.45rem;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.85);
}

.topbar-site-btn {
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #142a4a;
  border: 1px solid rgba(32, 215, 255, 0.28);
  color: #ffffff !important;
  border-radius: 12px;
  font-weight: 700;
  font-size: 0.92rem;
  text-decoration: none;
  padding: 0 1.1rem;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.topbar-site-btn:hover {
  background: #1c3b66;
  border-color: rgba(32, 215, 255, 0.5);
  color: #ffffff !important;
}

.topbar-logout-btn {
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(234, 179, 8, 0.12);
  border: 1px solid rgba(234, 179, 8, 0.28);
  color: #facc15 !important;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.88rem;
  padding: 0 1.15rem;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.topbar-logout-btn:hover {
  background: rgba(234, 179, 8, 0.22);
  border-color: rgba(234, 179, 8, 0.45);
  color: #ffffff !important;
  box-shadow: 0 4px 14px rgba(234, 179, 8, 0.15);
}

.summary-card-period {
  display: inline-flex !important;
  align-items: center;
  width: fit-content;
  max-width: 100%;
  margin-top: 0.2rem;
  margin-bottom: 0.15rem;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  background: rgba(56, 189, 248, 0.12) !important;
  border: 1px solid rgba(56, 189, 248, 0.28) !important;
  color: #38bdf8 !important;
  font-family: var(--font-primary);
  font-size: 0.65rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.06em;
  line-height: 1.2 !important;
  text-transform: uppercase;
}

.dashboard-overview-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  margin: 1.75rem 0 1rem;
}

.dashboard-overview-label p {
  margin: 0.35rem 0 0;
  color: rgba(226, 232, 240, 0.72);
  font-family: var(--font-ui);
}

.dashboard-period-toolbar {
  display: flex;
  align-items: end;
  gap: 0.55rem;
  padding: 0.75rem;
  border: 1px solid rgba(45, 212, 191, 0.28);
  border-radius: 18px;
  background: rgba(8, 20, 44, 0.72);
  box-shadow: 0 16px 38px rgba(0, 0, 0, 0.16);
}

.dashboard-period-toolbar .form-label {
  margin: 0;
  color: #f7c948;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.7rem;
}

.dashboard-period-toolbar .form-select,
.dashboard-period-toolbar .form-control {
  min-width: 160px;
  border-color: rgba(255, 255, 255, 0.12);
  background-color: rgba(255, 255, 255, 0.04);
  color: #e2e8f0;
}

@media (max-width: 768px) {
  .dashboard-overview-head,
  .dashboard-period-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .dashboard-period-toolbar .form-select,
  .dashboard-period-toolbar .form-control {
    min-width: 100%;
  }
}

.notification-wrap {
  position: relative;
}

.notification-bell {
  position: relative;
  border-color: rgba(245, 199, 85, 0.35);
  background:
    radial-gradient(circle at 50% 0%, rgba(34, 211, 238, 0.2), transparent 70%),
    rgba(255, 255, 255, 0.07);
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.notification-bell:hover,
.notification-bell[aria-expanded="true"] {
  transform: translateY(-1px);
  border-color: rgba(245, 199, 85, 0.8);
  box-shadow: 0 0 28px rgba(34, 211, 238, 0.18), 0 12px 28px rgba(0, 0, 0, 0.28);
}

.notification-badge {
  position: absolute;
  top: -0.35rem;
  right: -0.35rem;
  min-width: 1.35rem;
  height: 1.35rem;
  display: inline-grid;
  place-items: center;
  padding: 0 0.3rem;
  border: 2px solid var(--bg-main);
  border-radius: 999px;
  color: #071225;
  background: linear-gradient(135deg, var(--gold-soft), var(--gold));
  font-size: 0.68rem;
  font-weight: 950;
  box-shadow: 0 0 20px rgba(245, 199, 85, 0.36);
}

.notification-badge.is-urgent {
  color: #fff;
  background: linear-gradient(135deg, #ef4444, #b91c1c);
  box-shadow: 0 0 24px rgba(239, 68, 68, 0.42);
}

.notification-panel {
  position: absolute;
  top: calc(100% + 0.8rem);
  right: 0;
  z-index: 80;
  width: min(92vw, 460px);
  max-height: min(72vh, 680px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(34, 211, 238, 0.24);
  border-radius: 1.15rem;
  background:
    radial-gradient(circle at top right, rgba(34, 211, 238, 0.14), transparent 22rem),
    linear-gradient(135deg, rgba(7, 19, 38, 0.96), rgba(3, 10, 24, 0.94));
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.48), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(18px);
}

.notification-panel-head,
.notification-panel-actions,
.notification-page-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.notification-panel-head {
  padding: 1.1rem 1.15rem 0.85rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.notification-panel-head h2 {
  margin: 0.15rem 0 0;
  font-family: var(--font-heading);
  font-size: 1.35rem;
}

.notification-close {
  flex: 0 0 auto;
}

.notification-filter-row {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.85rem 1.15rem;
  overflow-x: auto;
}

.notification-filter {
  flex: 0 0 auto;
  border: 1px solid rgba(34, 211, 238, 0.22);
  border-radius: 999px;
  padding: 0.4rem 0.7rem;
  color: rgba(248, 251, 255, 0.82);
  background: rgba(255, 255, 255, 0.06);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.notification-filter:hover,
.notification-filter.active {
  color: #071225;
  border-color: rgba(245, 199, 85, 0.9);
  background: linear-gradient(135deg, var(--gold-soft), var(--gold));
}

.notification-list,
.notification-page-list {
  display: grid;
  gap: 0.75rem;
}

.notification-list {
  max-height: 430px;
  overflow-y: auto;
  padding: 0 1.15rem 1rem;
}

.notification-panel-actions {
  padding: 0.95rem 1.15rem 1.1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.notification-item {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 0.85rem;
  padding: 0.95rem;
  border: 1px solid rgba(34, 211, 238, 0.16);
  border-radius: 1rem;
  color: var(--text-dark);
  background: rgba(246, 250, 253, 0.96);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
}

.notification-item.unread {
  border-color: rgba(245, 199, 85, 0.62);
  box-shadow: 0 16px 42px rgba(245, 199, 85, 0.12), 0 12px 30px rgba(0, 0, 0, 0.18);
}

.notification-item.priority-urgent::before,
.notification-item.priority-high::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  border-radius: 1rem 0 0 1rem;
  background: linear-gradient(180deg, #ef4444, var(--gold));
}

.notification-item-icon {
  width: 2.3rem;
  height: 2.3rem;
  display: grid;
  place-items: center;
  border-radius: 0.8rem;
  color: #071225;
  background: linear-gradient(135deg, rgba(34, 211, 238, 0.24), rgba(245, 199, 85, 0.42));
}

.notification-item-body {
  min-width: 0;
}

.notification-item-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.notification-item-top strong {
  color: var(--text-strong);
  font-size: 0.96rem;
}

.notification-item-top span {
  flex: 0 0 auto;
  color: var(--text-dark-muted);
  font-size: 0.72rem;
  font-weight: 800;
}

.notification-item p {
  margin: 0.35rem 0 0.55rem;
  color: var(--text-dark-muted);
  line-height: 1.45;
}

.notification-item-meta,
.notification-item-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.notification-item-meta span {
  border: 1px solid rgba(37, 99, 235, 0.14);
  border-radius: 999px;
  padding: 0.2rem 0.5rem;
  color: #0f2b4c;
  background: rgba(37, 99, 235, 0.08);
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.notification-item-actions {
  margin-top: 0.7rem;
}

.notification-action,
.notification-mark,
.notification-item-open {
  border: 1px solid rgba(37, 99, 235, 0.18);
  border-radius: 999px;
  padding: 0.42rem 0.7rem;
  color: #071225;
  background: rgba(37, 99, 235, 0.08);
  font-size: 0.72rem;
  font-weight: 900;
}

.notification-action {
  border-color: rgba(245, 199, 85, 0.7);
  background: linear-gradient(135deg, var(--gold-soft), var(--gold));
}

.notification-item-open {
  width: 2.1rem;
  height: 2.1rem;
  display: grid;
  place-items: center;
  align-self: center;
  padding: 0;
}

.notification-inbox {
  padding: 1rem;
}

.notification-page-toolbar {
  margin-bottom: 1rem;
  padding-bottom: 0.9rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.notification-page-toolbar .notification-filter-row {
  padding: 0;
}

.ops-content {
  flex: 1;
  min-height: 0;
  min-width: 0;
  max-width: 100%;
  overflow-x: hidden !important;
  overflow-y: auto;
  padding: var(--page-pad);
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
  box-sizing: border-box;
  scrollbar-width: thin;
  scrollbar-color: rgba(148, 163, 184, 0.25) transparent;
}

.ops-content::-webkit-scrollbar {
  width: 5px;
}

.ops-content::-webkit-scrollbar-track {
  background: transparent;
}

.ops-content::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.25);
  border-radius: 999px;
}

.ops-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.6fr);
  gap: 1rem;
  min-height: 310px;
  padding: clamp(1.25rem, 3vw, 2rem);
  margin-bottom: var(--section-gap);
  overflow: hidden;
  color: #FFFFFF;
  border: 1px solid var(--border-cyan);
  border-radius: 1.35rem;
  background:
    linear-gradient(135deg, rgba(3, 10, 25, 0.94), rgba(7, 28, 55, 0.86)),
    url("https://embaixada-de-cristo.obiuba.com/assets/web/hero-service.jpg") center / cover;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.ops-hero::after {
  content: "";
  position: absolute;
  inset: auto -15% -48% 38%;
  height: 260px;
  background: radial-gradient(circle, rgba(32, 215, 255, 0.28), transparent 65%);
  pointer-events: none;
}

.ops-hero h2 {
  max-width: 760px;
  margin: 0.75rem 0 1rem;
  color: #FFFFFF;
  font-family: var(--font-heading);
  font-size: clamp(2rem, 5vw, 4.2rem);
  line-height: 1.05;
  text-shadow: 0 2px 28px rgba(0, 0, 0, 0.38);
}

.ops-hero p {
  max-width: 690px;
  color: #D7E3F5;
  font-size: 1.04rem;
  line-height: 1.55;
}

.ops-hero .eyebrow {
  color: var(--gold);
}

.ops-hero--welcome-line {
  display: flex;
  align-items: center;
  min-height: 54px;
  padding: 0.7rem 1rem;
  margin-bottom: 1.35rem;
  border-radius: 1rem;
  background:
    linear-gradient(90deg, rgba(3, 10, 25, 0.96), rgba(9, 32, 60, 0.88)),
    url("https://embaixada-de-cristo.obiuba.com/assets/web/hero-service.jpg") center 38% / cover;
}

.ops-hero--welcome-line::after {
  inset: auto -10% -120% 55%;
  height: 120px;
}

.ops-hero--welcome-line h2 {
  margin: 0.16rem 0 0;
  max-width: none;
  font-family: var(--font-ui);
  font-size: clamp(0.98rem, 1.5vw, 1.2rem);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: 0;
}

.ops-hero--welcome-line .eyebrow {
  display: block;
  margin-bottom: 0.06rem;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
}

.login-public-action {
  margin-top: 1.25rem;
  padding-top: 1.1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
}

.public-report-shell {
  min-height: 100vh;
  max-width: 100vw;
  padding: clamp(1rem, 4vw, 3rem);
  display: grid;
  place-items: start center;
  overflow-x: hidden;
  background:
    radial-gradient(circle at top left, rgba(34, 211, 238, 0.18), transparent 34rem),
    linear-gradient(145deg, #020817 0%, #07152a 55%, #08204b 100%);
  color: #fff;
  box-sizing: border-box;
}

.public-report-card {
  width: min(100%, 980px);
  max-width: 100%;
  padding: clamp(1.1rem, 3vw, 2rem);
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: 1.35rem;
  background: linear-gradient(145deg, #0f1c34, #0b1528);
  color: #e2e8f0;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
  box-sizing: border-box;
  overflow-x: hidden;
}

.public-report-form .form-control,
.public-report-form .form-select {
  color: #f1f5f9;
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.15);
}

.public-report-form .form-control:focus,
.public-report-form .form-select:focus {
  border-color: #38bdf8;
  box-shadow: 0 0 0 0.2rem rgba(56, 189, 248, 0.2);
}

.public-report-head {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.3rem;
}

.public-report-logo {
  width: 4.2rem;
  height: 4.2rem;
  object-fit: contain;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.25);
}

.public-report-card h1 {
  margin: 0.15rem 0 0.4rem;
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 4vw, 3rem);
}

.public-stepper {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
  margin-bottom: 1.25rem;
}

@media (max-width: 640px) {
  .public-stepper {
    grid-template-columns: 1fr;
    gap: 0.45rem;
  }
}

.public-stepper button {
  min-height: 3.4rem;
  padding: 0.65rem 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 0.95rem;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.04);
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.2s ease-in-out;
  cursor: pointer;
}

.public-stepper button span {
  display: inline-grid;
  place-items: center;
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.2);
  color: #08204b;
  font-weight: 900;
  font-size: 0.88rem;
  flex-shrink: 0;
}

.public-stepper button.active {
  border-color: rgba(215, 174, 75, 0.9);
  background: linear-gradient(135deg, #fef3c7 0%, #fde68a 50%, #f59e0b 100%);
  color: #78350f;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.25);
}

.public-stepper button.active span {
  background: #78350f;
  color: #fff;
}

/* Cell Identity Card */
.cell-identity-card {
  padding: 1.25rem;
  border-radius: 1.1rem;
  background: linear-gradient(145deg, #0b1f3a 0%, #08204b 100%);
  color: #fff;
  border: 1px solid rgba(34, 211, 238, 0.4);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

.cell-identity-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.3rem 0.75rem;
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.18);
  border: 1px solid rgba(34, 211, 238, 0.45);
  color: #38bdf8;
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.75rem;
}

.cell-identity-title {
  font-size: 1.35rem;
  font-weight: 900;
  color: #fff;
  margin-bottom: 0.65rem;
  display: flex;
  align-items: center;
}

.cell-identity-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0.6rem;
  font-size: 0.85rem;
  color: rgba(248, 250, 252, 0.9);
  background: rgba(255, 255, 255, 0.06);
  padding: 0.85rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

/* Section dividers inside steps */
.cell-section-divider {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 1.25rem 0 0.85rem;
  color: #0b1f3a;
}

.cell-section-divider h3 {
  font-size: 1.05rem;
  font-weight: 800;
  margin: 0;
  white-space: nowrap;
}

.cell-section-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: rgba(11, 31, 58, 0.12);
}

/* Stat Cards for Numeric Fields (Step 2) */
.cell-stat-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
  min-height: 110px;
  padding: 0.9rem;
  border-radius: 0.95rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

.cell-stat-card:focus-within,
.cell-stat-card:hover {
  border-color: rgba(56, 189, 248, 0.4);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35);
  transform: translateY(-1px);
}

.cell-stat-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.cell-stat-title-wrap {
  flex: 1;
}

.cell-stat-label {
  display: block;
  font-size: 0.82rem;
  font-weight: 700;
  color: #cbd5e1;
  line-height: 1.25;
}

.cell-stat-hint {
  display: block;
  font-size: 0.7rem;
  color: #94a3b8;
  margin-top: 0.15rem;
}

.cell-stat-tag {
  display: inline-block;
  padding: 0.18rem 0.48rem;
  border-radius: 0.5rem;
  background: rgba(56, 189, 248, 0.12);
  color: #38bdf8;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  flex-shrink: 0;
}

.cell-stat-input-wrap {
  margin-top: auto;
}

.cell-stat-input {
  font-size: 1.25rem !important;
  font-weight: 800 !important;
  text-align: center;
  color: #f8fafc !important;
  background: rgba(255, 255, 255, 0.04) !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  border-radius: 0.65rem !important;
  padding: 0.4rem 0.6rem !important;
}

.cell-stat-input:focus {
  background: rgba(255, 255, 255, 0.08) !important;
  border-color: #38bdf8 !important;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.2) !important;
}

.public-form-step {
  display: none;
  padding: 1.2rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1.15rem;
  background: rgba(255, 255, 255, 0.02);
}

.public-form-step.active {
  display: block;
}

.public-form-step h2 {
  margin-bottom: 1rem;
  font-family: var(--font-heading);
  font-size: 1.55rem;
}

.public-form-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.65rem;
  margin-top: 1.25rem;
}

/* Public form actions */
.public-report-card .btn-outline-light {
  --bs-btn-color: #cbd5e1;
  --bs-btn-border-color: rgba(255, 255, 255, 0.15);
  --bs-btn-hover-bg: rgba(255, 255, 255, 0.08);
  --bs-btn-hover-border-color: rgba(255, 255, 255, 0.3);
  --bs-btn-hover-color: #f8fafc;
  color: #cbd5e1;
  border-color: rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.04);
  font-weight: 700;
}

.public-report-card .btn-outline-cyan {
  color: #38bdf8;
  border-color: rgba(56, 189, 248, 0.35);
  background: rgba(56, 189, 248, 0.08);
  font-weight: 700;
}

.public-report-card .btn-outline-cyan:hover,
.public-report-card .btn-outline-light:hover {
  background: rgba(56, 189, 248, 0.18);
  border-color: rgba(56, 189, 248, 0.55);
  color: #f8fafc;
}

.public-report-card .btn-ce-gold {
  min-height: 2.75rem;
  font-weight: 900;
}

/* Highlight public form submissions in internal list (desktop + mobile cards) */
tr[data-public-cell-report="1"],
tr[data-public-cell-report="1"] > td,
article.data-table-mobile-card[data-public-cell-report="1"] {
  background: rgba(34, 211, 238, 0.1) !important;
  box-shadow: inset 3px 0 0 #22d3ee;
}

tr[data-public-cell-report="1"] td:last-child {
  position: sticky;
  right: 0;
  z-index: 2;
  background: linear-gradient(90deg, rgba(232, 248, 252, 0.15), #e8f8fc 22%);
  box-shadow: -8px 0 12px rgba(7, 21, 42, 0.06);
}

.cell-report-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  min-width: 12rem;
  max-width: 22rem;
}

.badge-finance-pending {
  display: inline-block;
  margin-top: 0.2rem;
  padding: 0.15rem 0.45rem;
  border-radius: 999px;
  background: rgba(217, 119, 6, 0.16);
  color: #92400e;
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.02em;
}

/* Partnerships analytics */
.partnership-arm-grid .partnership-arm-card {
  padding: 1.1rem;
  border: 1px solid rgba(34, 211, 238, 0.22);
}

.partnership-arm-card-head {
  display: flex;
  gap: 0.85rem;
  align-items: flex-start;
  margin-bottom: 0.75rem;
}

.partnership-arm-logo,
.partnership-arm-placeholder {
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 1rem;
  flex-shrink: 0;
  object-fit: cover;
}

.partnership-arm-placeholder {
  display: grid;
  place-items: center;
  gap: 0.1rem;
  background: linear-gradient(145deg, rgba(34, 211, 238, 0.18), rgba(215, 174, 75, 0.22));
  color: #0b1f3a;
  font-weight: 900;
  font-size: 0.75rem;
}

.partnership-arm-placeholder i {
  font-size: 1.1rem;
  color: #0e7490;
}

.partnership-arm-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.55rem;
  margin: 0.85rem 0 0.75rem;
}

.partnership-arm-stats div {
  padding: 0.45rem 0.5rem;
  border-radius: 0.65rem;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid rgba(11, 31, 58, 0.08);
}

.partnership-arm-stats span {
  display: block;
  font-size: 0.65rem;
  font-weight: 800;
  text-transform: uppercase;
  color: #64748b;
}

.partnership-arm-stats strong {
  color: #0b1f3a;
  font-size: 0.9rem;
}

.partnership-goal-bar {
  height: 0.45rem;
  background: rgba(11, 31, 58, 0.08);
  border-radius: 999px;
  overflow: hidden;
}

.partnership-goal-bar .progress-bar {
  background: linear-gradient(90deg, #22d3ee, #d7ad45);
}

.badge-promo {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  background: rgba(220, 38, 38, 0.12);
  color: #b91c1c;
  font-size: 0.72rem;
  font-weight: 900;
}

.partnership-tabs {
  overflow-x: auto;
  flex-wrap: nowrap;
}

@media (max-width: 767.98px) {
  .partnership-arm-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.public-form-alert {
  margin-bottom: 1rem;
  padding: 0.8rem 1rem;
  border: 1px solid rgba(239, 68, 68, 0.3);
  border-radius: 0.85rem;
  color: #f87171;
  background: rgba(239, 68, 68, 0.12);
  font-weight: 700;
}

.public-honeypot {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.public-confirm-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr));
  gap: 0.75rem;
  margin-top: 1.3rem;
}

.public-confirm-grid div {
  padding: 0.9rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.85rem;
  background: rgba(255, 255, 255, 0.03);
  color: #e2e8f0;
}

.public-confirm-grid span {
  display: block;
  color: var(--muted);
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
}

.public-confirm-check {
  padding: 1rem 1rem 1rem 2.75rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.9rem;
  background: rgba(255, 255, 255, 0.03);
  color: #e2e8f0;
  font-weight: 800;
}

.public-report-success h1 {
  color: #0f766e;
}

.public-success-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  background: rgba(16, 185, 129, 0.16);
  color: #047857;
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

@media (max-width: 767.98px) {
  .public-report-head {
    align-items: flex-start;
  }

  .public-stepper {
    grid-template-columns: 1fr 1fr;
  }

  .public-form-actions .btn {
    flex: 1 1 100%;
  }
}

.hero-card {
  align-self: end;
  position: relative;
  z-index: 1;
  padding: 1.25rem;
  border: 1px solid var(--border-cyan);
  border-radius: 1.1rem;
  background: linear-gradient(145deg, rgba(8, 22, 42, 0.72), rgba(9, 32, 60, 0.58));
  backdrop-filter: blur(16px);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.28);
}

.hero-card strong {
  display: block;
  color: var(--gold-soft);
  font-family: var(--font-ui);
  font-weight: 900;
  font-size: 3.2rem;
  line-height: 1;
}

.hero-card span,
.hero-card small {
  color: rgba(248, 251, 255, 0.72);
  font-weight: 800;
}

.panel,
.metric-card,
.chart-card,
.record-card {
  border: 1px solid rgba(56, 189, 248, 0.18);
  border-radius: 1.15rem;
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
  color: var(--text-main);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}

.panel,
.chart-card,
.record-card {
  padding: 1.15rem;
}

.section-panel {
  background: linear-gradient(135deg, rgba(14, 32, 64, 0.94), rgba(8, 23, 46, 0.88));
}

.header-icon {
  width: 46px;
  height: 46px;
  display: grid;
  flex: 0 0 46px;
  place-items: center;
  border-radius: 1rem;
  color: #fff;
  background: linear-gradient(135deg, var(--royal), var(--cyan));
  box-shadow: 0 0 24px rgba(32, 215, 255, 0.28);
}

.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.panel-title {
  margin: 0.2rem 0 0;
  font-family: var(--font-heading);
  color: var(--ink);
  font-size: 1.45rem;
}

.metric-card {
  display: flex;
  align-items: flex-start;
  gap: 0.95rem;
  height: 100%;
  min-height: 110px;
  padding: 1.15rem 1.15rem;
  border-radius: 16px;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.summary-card-body {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-width: 0;
  gap: 0.2rem;
}

.metric-card:hover,
.record-card:hover,
.chart-card:hover {
  transform: translateY(-3px);
  border-color: rgba(32, 215, 255, 0.38);
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.22);
}

.metric-icon {
  width: 44px;
  height: 44px;
  display: grid;
  flex: 0 0 44px;
  place-items: center;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, var(--royal), var(--cyan));
  box-shadow: 0 8px 20px rgba(23, 92, 255, 0.22);
}

.metric-card .metric-label,
.summary-card-label {
  display: block;
  color: #8ea8cc;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  line-height: 1.35;
  margin: 0;
  word-break: break-word;
  opacity: 1;
}

.metric-card .metric-value,
.summary-card-value {
  display: block;
  margin: 0.15rem 0 0.2rem;
  font-family: var(--font-primary);
  font-weight: 800;
  font-size: clamp(1.35rem, 1.8vw, 1.85rem);
  line-height: 1.2;
  color: #ffffff !important;
  word-break: break-word;
  overflow-wrap: break-word;
}

.metric-card .summary-card-hint,
.metric-card .subtitle,
.summary-card-hint {
  display: block;
  font-size: 0.78rem;
  line-height: 1.35;
  color: #8ea8cc;
  margin-top: 0.15rem;
  word-break: break-word;
  opacity: 1;
}

.chart-bars {
  display: grid;
  gap: 0.62rem;
}

.chart-row {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr) 52px;
  align-items: center;
  gap: 0.7rem;
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 800;
}

.chart-track {
  height: 0.72rem;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(13, 23, 48, 0.08);
}

.chart-fill {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--royal), var(--cyan));
  box-shadow: 0 0 18px rgba(32, 215, 255, 0.35);
}

.donut-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(132px, 1fr));
  gap: 0.8rem;
}

.donut-item {
  padding: 0.9rem;
  border-radius: 1rem;
  background: rgba(23, 92, 255, 0.06);
}

.donut-item strong {
  display: block;
  font-size: 1.2rem;
}

.module-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
}

.record-card {
  height: 100%;
}

.record-card h3 {
  font-size: 1.18rem;
  margin: 0.25rem 0 0.75rem;
}

.detail-list {
  display: grid;
  gap: 0.55rem;
}

.detail-list div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  border-bottom: 1px solid rgba(13, 23, 48, 0.08);
  padding-bottom: 0.45rem;
}

.detail-list span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border-radius: 999px;
  padding: 0.24rem 0.65rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  line-height: 1.2;
  white-space: nowrap;
}

.status-pill i {
  font-size: 0.45rem;
  line-height: 1;
}

.status-good,
.status-pill.status-good,
.status-pill.status-green {
  background: rgba(34, 197, 94, 0.14) !important;
  color: #34d399 !important;
  border: 1px solid rgba(34, 197, 94, 0.3) !important;
}
.status-good i,
.status-pill.status-good i,
.status-pill.status-green i {
  color: #4ade80 !important;
  filter: drop-shadow(0 0 4px rgba(74, 222, 128, 0.6));
}

.status-warn,
.status-amber,
.status-pill.status-warn,
.status-pill.status-amber {
  background: rgba(245, 158, 11, 0.14) !important;
  color: #fbbf24 !important;
  border: 1px solid rgba(245, 158, 11, 0.32) !important;
}
.status-warn i,
.status-amber i,
.status-pill.status-warn i,
.status-pill.status-amber i {
  color: #facc15 !important;
  filter: drop-shadow(0 0 4px rgba(250, 204, 21, 0.6));
}

.status-blue,
.status-pill.status-blue {
  background: rgba(59, 130, 246, 0.14) !important;
  color: #60a5fa !important;
  border: 1px solid rgba(59, 130, 246, 0.3) !important;
}
.status-blue i,
.status-pill.status-blue i {
  color: #93c5fd !important;
  filter: drop-shadow(0 0 4px rgba(147, 197, 253, 0.6));
}

.status-cyan,
.status-pill.status-cyan {
  background: rgba(56, 189, 248, 0.14) !important;
  color: #38bdf8 !important;
  border: 1px solid rgba(56, 189, 248, 0.3) !important;
}
.status-cyan i,
.status-pill.status-cyan i {
  color: #7dd3fc !important;
  filter: drop-shadow(0 0 4px rgba(125, 211, 252, 0.6));
}

.status-danger,
.status-pill.status-danger {
  background: rgba(239, 68, 68, 0.14) !important;
  color: #f87171 !important;
  border: 1px solid rgba(239, 68, 68, 0.3) !important;
}
.status-danger i,
.status-pill.status-danger i {
  color: #fca5a5 !important;
  filter: drop-shadow(0 0 4px rgba(252, 165, 165, 0.6));
}

.status-course,
.status-pill.status-course {
  background: rgba(168, 85, 247, 0.14) !important;
  color: #c084fc !important;
  border: 1px solid rgba(168, 85, 247, 0.3) !important;
}
.status-course i,
.status-pill.status-course i {
  color: #d8b4fe !important;
}

.status-orange,
.status-pill.status-orange {
  background: rgba(249, 115, 22, 0.14) !important;
  color: #fb923c !important;
  border: 1px solid rgba(249, 115, 22, 0.3) !important;
}
.status-orange i,
.status-pill.status-orange i {
  color: #fdba74 !important;
}

.status-muted,
.status-pill.status-muted {
  background: rgba(148, 163, 184, 0.1) !important;
  color: #94a3b8 !important;
  border: 1px solid rgba(148, 163, 184, 0.22) !important;
}
.status-muted i,
.status-pill.status-muted i {
  color: #94a3b8 !important;
}

.table {
  --bs-table-bg: transparent;
  vertical-align: middle;
}

.data-table {
  border-radius: 1rem;
}

.table th {
  color: #94a3b8;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.table td {
  color: #cbd5e1;
  padding-top: 0.85rem;
  padding-bottom: 0.85rem;
}

.table tbody tr {
  transition: background 0.15s ease;
}

.table tbody tr:hover {
  background: rgba(56, 189, 248, 0.04);
}

.filter-bar {
  display: grid;
  grid-template-columns: minmax(210px, 1.4fr) repeat(3, minmax(160px, 0.8fr)) auto;
  gap: 0.65rem;
  align-items: center;
}

.action-cluster {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.action-btn {
  border: 1px solid rgba(23, 92, 255, 0.18);
  border-radius: 999px;
  padding: 0.32rem 0.62rem;
  color: #0f338f;
  background: rgba(23, 92, 255, 0.08);
  font-size: 0.72rem;
  font-weight: 900;
  transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}

.action-btn:hover {
  transform: translateY(-1px);
  border-color: rgba(32, 215, 255, 0.48);
  background: rgba(32, 215, 255, 0.14);
}

.action-secondary {
  color: #0e244a;
  border-color: rgba(32, 215, 255, 0.36);
  background: rgba(255, 255, 255, 0.35);
}

.tab-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}

.tab-strip button,
.tab-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 18px;
  line-height: 1;
  border: 1px solid var(--tab-inactive-border);
  border-radius: 999px;
  color: var(--tab-inactive-color);
  background: var(--tab-inactive-bg);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  opacity: 1;
  transition: background 0.16s ease, color 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease;
}

.tab-strip button.active,
.tab-strip button:hover:not(:disabled) {
  color: var(--text-dark);
  border-color: var(--border-gold);
  background: linear-gradient(135deg, var(--gold-soft), var(--gold));
  box-shadow: 0 8px 20px rgba(245, 199, 85, 0.24);
  font-weight: 800;
  opacity: 1;
}

.tab-strip button:disabled,
.tab-strip button.is-disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.module-nav-shell {
  margin-bottom: 1.5rem;
}

.module-nav-sticky {
  position: -webkit-sticky;
  position: sticky;
  top: 0;
  z-index: 18;
  margin: -1.5rem -1.5rem 1.25rem;
  padding: 1.5rem 1.5rem 0.65rem;
  background:
    linear-gradient(180deg, rgba(3, 8, 22, 1) 0%, rgba(3, 8, 22, 0.98) 78%, rgba(3, 8, 22, 0.94) 92%, rgba(3, 8, 22, 0) 100%);
}

.module-nav-collapsed {
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem;
  padding: 0.82rem 1rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1rem;
  background: rgba(13, 23, 42, 0.75);
  box-shadow: none;
  color: #cbd5e1;
}

.module-nav-shell.is-collapsed .module-nav-collapsed {
  display: flex;
}

.module-nav-shell.is-collapsed .module-nav-panel {
  display: none;
}

.module-nav-collapsed-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
}

.module-nav-collapsed-title {
  display: block;
  color: var(--ink);
  font-size: 0.95rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.module-nav-collapsed .eyebrow {
  font-size: 0.62rem;
}

.header-icon-sm {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  font-size: 1rem;
}

.module-nav-panel {
  display: block;
  overflow: hidden;
  border-radius: 1rem;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.24);
}

.module-nav-panel .section-panel {
  border-radius: 1rem 1rem 0 0;
  margin-bottom: 0 !important;
  border-bottom: 0;
}

.module-nav-panel .department-tabs,
.module-nav-panel .tab-strip.module-tab-strip,
.module-nav-panel .module-tabs {
  margin: 0;
  padding: 14px 18px 18px;
  gap: 10px;
  border: 1px solid rgba(32, 215, 255, 0.16);
  border-top: 1px solid rgba(13, 23, 48, 0.08);
  border-radius: 0 0 1rem 1rem;
  background:
    linear-gradient(180deg, rgba(7, 18, 37, 0.98), rgba(3, 8, 22, 0.98));
}

.module-nav-panel .tab-strip.module-tab-strip + .tab-strip.module-tab-strip {
  border-top: 0;
  border-radius: 0;
  padding-top: 0.35rem;
}

.module-nav-panel .tab-strip.module-tab-strip:last-child {
  border-radius: 0 0 1rem 1rem;
}

.module-nav-head-actions {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-shrink: 0;
}

.module-nav-arrow {
  width: 2.4rem;
  height: 2.4rem;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(32, 215, 255, 0.3);
  border-radius: 0.78rem;
  color: var(--cyan);
  background: rgba(255, 255, 255, 0.08);
  transition: border-color 0.18s ease, background 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.section-panel .module-nav-arrow {
  color: var(--royal);
  background: rgba(23, 92, 255, 0.08);
  border-color: rgba(23, 92, 255, 0.22);
}

.module-nav-collapsed .module-nav-arrow {
  color: var(--royal);
  background: rgba(23, 92, 255, 0.1);
  border-color: rgba(23, 92, 255, 0.24);
}

.module-nav-arrow:hover {
  color: #fff;
  border-color: rgba(241, 216, 140, 0.78);
  background: rgba(32, 215, 255, 0.16);
  transform: translateY(-1px);
}

.section-panel .module-nav-arrow:hover,
.module-nav-collapsed .module-nav-arrow:hover {
  color: var(--navy-950);
  background: linear-gradient(135deg, var(--gold-soft), var(--gold));
}

.module-tab-strip,
.module-tabs {
  align-items: center;
}

.department-tabs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  overflow-x: auto;
  scrollbar-width: thin;
}

.department-tabs button {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 18px;
  line-height: 1;
  border: 1px solid rgba(32, 215, 255, 0.24);
  border-radius: 999px;
  color: rgba(248, 251, 255, 0.76);
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.08), rgba(32, 215, 255, 0.05));
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.department-tabs button:hover,
.department-tabs button.active {
  transform: translateY(-2px);
  color: #06101f;
  border-color: rgba(241, 216, 140, 0.82);
  background: linear-gradient(135deg, var(--gold-soft), var(--gold));
  box-shadow: 0 14px 30px rgba(215, 174, 75, 0.2);
}

.advanced-filter {
  grid-template-columns: minmax(190px, 1.2fr) repeat(auto-fit, minmax(150px, 1fr));
}

.step-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
}

.step-row span {
  min-width: 1.6rem;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  padding: 0.16rem 0.38rem;
  color: var(--muted);
  background: rgba(13, 23, 48, 0.08);
  font-size: 0.65rem;
  font-weight: 900;
}

.step-row span.done {
  color: #06101f;
  background: linear-gradient(135deg, var(--cyan), var(--gold-soft));
}

.step-row span.pending,
.foundation-class-steps span.pending {
  color: var(--muted);
  background: rgba(13, 23, 48, 0.08);
}

.foundation-progress-cell {
  min-width: 10rem;
}

.foundation-progress-percent {
  display: block;
  margin-top: 0.2rem;
  color: rgba(248, 251, 255, 0.62);
  font-size: 0.72rem;
  font-weight: 800;
}

.foundation-progress-preview {
  padding: 0.9rem 1rem;
  border: 1px solid rgba(32, 215, 255, 0.16);
  border-radius: 0.9rem;
  background: rgba(255, 255, 255, 0.05);
}

.foundation-progress-copy {
  color: rgba(248, 251, 255, 0.78);
  font-size: 0.86rem;
  font-weight: 700;
}

.foundation-form-section {
  margin: 0.35rem 0 0;
  padding-top: 0.35rem;
  color: var(--gold-soft);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.foundation-class-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.65rem;
}

.foundation-class-toggle {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  margin: 0;
  padding: 0.85rem 0.95rem;
  border: 1px solid rgba(32, 215, 255, 0.18);
  border-radius: 0.85rem;
  background: rgba(255, 255, 255, 0.04);
  cursor: pointer;
  user-select: none;
}

.foundation-class-toggle input {
  width: 1.15rem;
  height: 1.15rem;
  margin: 0;
  accent-color: var(--cyan);
}

.foundation-class-toggle span {
  font-weight: 800;
  color: #fff;
}

.foundation-class-toggle:has(input:checked) {
  border-color: rgba(32, 215, 255, 0.45);
  background: rgba(32, 215, 255, 0.12);
}

.foundation-lesson-chip {
  display: flex;
  min-height: 4.2rem;
  flex-direction: column;
  justify-content: center;
  gap: 0.15rem;
  padding: 0.65rem 0.7rem;
  border: 1px solid rgba(32, 215, 255, 0.18);
  border-radius: 0.85rem;
  background: rgba(13, 23, 48, 0.08);
  color: var(--ink);
  font-family: var(--font-ui);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.foundation-lesson-chip.done {
  border-color: rgba(32, 215, 255, 0.38);
  background: linear-gradient(135deg, rgba(32, 215, 255, 0.2), rgba(255, 210, 89, 0.24));
}

.foundation-lesson-chip.pending {
  color: rgba(9, 22, 45, 0.62);
}

.foundation-lesson-chip small,
.foundation-lesson-chip em {
  display: block;
  color: inherit;
  font-size: 0.66rem;
  font-style: normal;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: none;
}

.foundation-lesson-chip em {
  color: var(--gold);
}

.foundation-compact-progress {
  display: grid;
  gap: 0.35rem;
  min-width: 12rem;
  max-width: 16rem;
}

.foundation-compact-progress .foundation-progress-bar {
  height: 0.45rem;
  margin: 0;
  background: rgba(13, 23, 48, 0.12);
}

.foundation-mini-steps {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  align-items: center;
}

.foundation-mini-steps span {
  width: 1.35rem;
  height: 1.35rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(13, 23, 48, 0.1);
  color: rgba(9, 22, 45, 0.65);
  font-size: 0.68rem;
  font-weight: 900;
}

.foundation-mini-steps span.done {
  background: linear-gradient(135deg, var(--cyan), var(--gold-soft));
  color: #06101f;
}

.foundation-compact-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 0.45rem;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
}

.foundation-compact-meta strong {
  color: var(--ink);
}

.foundation-compact-meta span {
  white-space: nowrap;
}

.foundation-score-entry {
  display: grid;
  grid-template-columns: minmax(4.2rem, 1fr) auto minmax(4.2rem, 1fr);
  gap: 0.35rem;
  align-items: center;
  max-width: 11rem;
}

.foundation-score-entry span {
  color: var(--muted);
  font-weight: 900;
}

.foundation-attachment-field {
  display: grid;
  gap: 0.25rem;
  min-width: 11rem;
}

.foundation-attachment-link {
  display: inline-flex;
  align-items: center;
  max-width: 13rem;
  color: var(--royal);
  font-size: 0.74rem;
  font-weight: 900;
  text-decoration: none;
  overflow-wrap: anywhere;
}

.foundation-attachment-link:hover {
  color: var(--cyan);
  text-decoration: underline;
}

.foundation-student-detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 0.85rem;
}

.foundation-check-graduated input {
  accent-color: var(--gold-soft);
}

.foundation-check-certificate input {
  accent-color: var(--royal);
}

.readonly-user-field {
  display: flex;
  align-items: center;
  min-height: 3rem;
  color: var(--ink);
  background: rgba(239, 249, 255, 0.92);
  border-color: rgba(32, 215, 255, 0.3);
  font-weight: 800;
  cursor: default;
}

@media (max-width: 575.98px) {
  .foundation-class-grid {
    grid-template-columns: 1fr;
  }
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.7rem;
}

.detail-grid div {
  padding: 0.9rem;
  border: 1px solid rgba(32, 215, 255, 0.16);
  border-radius: 0.9rem;
  background: rgba(255, 255, 255, 0.08);
}

.detail-grid div.detail-item-full {
  grid-column: 1 / -1;
}

.detail-grid span,
.timeline span {
  display: block;
  color: rgba(248, 251, 255, 0.58);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.detail-grid strong,
.timeline strong {
  display: block;
  color: #fff;
  overflow-wrap: anywhere;
}

.member-profile { display: grid; gap: 1rem; }
.member-profile-header { display: flex; gap: 0.9rem; align-items: center; padding: 1rem; border: 1px solid rgba(32,215,255,.2); border-radius: 1rem; background: rgba(32,215,255,.06); }
.member-profile-header h3 { margin: 0 0 .35rem; color: #fff; }
.member-profile-avatar { display: inline-grid; place-items: center; width: 3.4rem; height: 3.4rem; flex: 0 0 auto; border-radius: 50%; background: var(--cyan); color: var(--navy); font-weight: 900; }
.member-profile-badges { display: flex; flex-wrap: wrap; gap: .45rem; align-items: center; }
.member-profile-badges > span { padding: .28rem .55rem; border-radius: 999px; background: rgba(255,255,255,.1); color: rgba(248,251,255,.84); font-size: .78rem; }
.member-profile-section { padding-top: .2rem; }
.member-profile-section h6, .member-profile-history summary { margin: 0 0 .55rem; color: var(--gold); font-weight: 900; font-size: .8rem; text-transform: uppercase; letter-spacing: .07em; }
.member-profile-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px,1fr)); gap: .6rem; }
.member-profile-grid > div { padding: .7rem .8rem; border: 1px solid rgba(32,215,255,.14); border-radius: .75rem; background: rgba(255,255,255,.05); }
.member-profile-grid span { display:block; margin-bottom:.2rem; color: rgba(248,251,255,.6); font-size:.7rem; font-weight:800; text-transform:uppercase; letter-spacing:.06em; }
.member-profile-grid strong { color:#fff; overflow-wrap:anywhere; }
.member-profile-history { padding: .8rem; border: 1px solid rgba(255,255,255,.1); border-radius: .85rem; background: rgba(255,255,255,.04); }
.member-profile-history summary { cursor: pointer; }
@media (max-width: 576px) { .member-profile-grid { grid-template-columns: 1fr; } .member-profile-header { align-items: flex-start; } }

.timeline {
  display: grid;
  gap: 0.75rem;
}

.timeline div {
  padding: 0.9rem;
  border-left: 3px solid var(--cyan);
  border-radius: 0.8rem;
  background: rgba(255, 255, 255, 0.08);
}

.timeline p {
  margin: 0.35rem 0 0;
  color: rgba(248, 251, 255, 0.72);
}

.progress {
  height: 0.75rem;
  background: rgba(13, 23, 48, 0.09);
}

.progress-bar {
  background: linear-gradient(90deg, var(--royal), var(--cyan));
}

.ops-modal {
  color: #fff;
  border: 1px solid rgba(32, 215, 255, 0.18);
  border-radius: 1.2rem;
  background: linear-gradient(160deg, rgba(7, 18, 37, 0.98), rgba(10, 23, 48, 0.98));
}

.ops-modal .modal-header,
.ops-modal .modal-footer {
  border-color: rgba(255, 255, 255, 0.12);
}

.ops-modal .form-label {
  color: rgba(248, 251, 255, 0.76);
  font-weight: 800;
}

.empty-state {
  padding: 2rem;
  border: 1px dashed rgba(32, 215, 255, 0.34);
  border-radius: 1rem;
  color: rgba(248, 251, 255, 0.72);
  background: rgba(255, 255, 255, 0.04);
}

.tab-parallax-stage {
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.tab-parallax-bg {
  position: absolute;
  inset: -18% -8% auto;
  height: 260px;
  pointer-events: none;
  z-index: 0;
}

.tab-parallax-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(52px);
  opacity: 0.7;
  animation: tabParallaxDrift 0.72s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.tab-parallax-orb-a {
  width: 220px;
  height: 220px;
  left: 6%;
  top: 0;
  background: radial-gradient(circle, rgba(32, 215, 255, 0.34), transparent 72%);
}

.tab-parallax-orb-b {
  width: 190px;
  height: 190px;
  right: 10%;
  top: 36px;
  background: radial-gradient(circle, rgba(241, 216, 140, 0.26), transparent 72%);
  animation-delay: 0.06s;
}

.tab-parallax-layer {
  position: relative;
  z-index: 1;
}

.tab-parallax-stage[data-parallax-dir="forward"] .tab-parallax-layer.is-entering {
  animation: tabParallaxEnterForward 0.68s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.tab-parallax-stage[data-parallax-dir="back"] .tab-parallax-layer.is-entering {
  animation: tabParallaxEnterBack 0.68s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.tab-parallax-stage[data-parallax-dir="none"] .tab-parallax-layer.is-entering {
  animation: tabParallaxEnterNeutral 0.58s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.tab-parallax-stage[data-parallax-dir="forward"] {
  --parallax-from-x: -44px;
  --parallax-to-x: 28px;
}

.tab-parallax-stage[data-parallax-dir="back"] {
  --parallax-from-x: 44px;
  --parallax-to-x: -28px;
}

.tab-parallax-stage[data-parallax-dir="none"] {
  --parallax-from-x: 0;
  --parallax-to-x: 0;
}

@keyframes tabParallaxEnterForward {
  from {
    opacity: 0.95;
    transform: translate3d(16px, 0, 0);
  }

  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@keyframes tabParallaxEnterBack {
  from {
    opacity: 0.95;
    transform: translate3d(-16px, 0, 0);
  }

  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@keyframes tabParallaxEnterNeutral {
  from {
    opacity: 0.95;
    transform: translate3d(0, 4px, 0);
  }

  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@keyframes tabParallaxDrift {
  from {
    transform: translate3d(var(--parallax-from-x), 8px, 0);
  }

  to {
    transform: translate3d(var(--parallax-to-x), -10px, 0);
  }
}

.panel-parallax-enter {
  animation: panelParallaxPulse 0.62s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes panelParallaxPulse {
  from {
    opacity: 0.55;
    transform: translate3d(0, 18px, 0);
  }

  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@media (prefers-reduced-motion: reduce) {
  .tab-parallax-layer.is-entering,
  .tab-parallax-orb,
  .panel-parallax-enter {
    animation: none !important;
  }
}

.back-to-top {
  position: fixed;
  right: 1.35rem;
  bottom: 1.35rem;
  z-index: 24;
  width: 3rem;
  height: 3rem;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(241, 216, 140, 0.72);
  border-radius: 999px;
  color: var(--navy-950);
  background: linear-gradient(135deg, var(--gold-soft), var(--gold));
  box-shadow: 0 14px 32px rgba(215, 174, 75, 0.28), 0 0 0 6px rgba(215, 174, 75, 0.08);
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s ease, box-shadow 0.18s ease;
}

.back-to-top i {
  font-size: 1.2rem;
  font-weight: 900;
}

.back-to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  color: var(--navy-950);
  border-color: rgba(32, 215, 255, 0.72);
  box-shadow: 0 16px 36px rgba(215, 174, 75, 0.34), 0 0 24px rgba(32, 215, 255, 0.18);
  transform: translateY(-2px);
}

.back-to-top:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 3px;
}

/* Keep the Members pager clear of the fixed scroll-to-top control. */
[data-members-pagination] {
  padding-right: 5.25rem;
  padding-bottom: 0.75rem;
}

@media (max-width: 767.98px) {
  [data-members-pagination] {
    padding-right: 0;
    padding-bottom: 5.5rem;
  }

  [data-members-pagination] > div {
    width: 100%;
    justify-content: flex-start;
  }
}

@media (max-width: 1199.98px) {
  .ops-hero {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 991.98px) {
  .ops-shell {
    height: 100vh;
    height: 100dvh;
    width: 100%;
    max-width: 100vw;
    overflow-x: hidden;
  }

  .ops-main {
    margin-left: 0 !important;
    width: 100% !important;
    max-width: 100vw !important;
    min-width: 0 !important;
    height: 100vh;
    height: 100dvh;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
  }

  .module-nav-sticky {
    margin-inline: -1rem;
    padding-inline: 1rem;
  }

  .ops-sidebar {
    width: min(88vw, 316px);
    transform: translateX(-100%);
  }

  .ops-sidebar.is-open {
    transform: translateX(0);
  }

  .ops-shell.is-sidebar-collapsed {
    --sidebar-width: min(88vw, 316px);
  }

  .panel-head {
    align-items: stretch;
    flex-direction: column;
  }
}

@media (max-width: 575.98px) {
  .login-shell {
    padding: 1rem;
  }

  .ops-content {
    padding: 0.75rem 0.75rem 4.5rem 0.75rem !important;
    overflow-x: hidden !important;
    min-width: 0 !important;
    max-width: 100% !important;
    box-sizing: border-box !important;
  }

  .login-panel,
  .panel,
  .chart-card,
  .record-card {
    padding: 0.85rem;
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
  }

  .chart-row {
    grid-template-columns: 82px minmax(0, 1fr) 38px;
  }
}

@media (max-width: 991.98px) {
  .ops-topbar {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0.75rem;
    padding: 0.75rem 1rem 0.85rem;
    min-height: auto;
    background: #08162b;
    border-bottom: 1px solid rgba(32, 215, 255, 0.16);
    width: 100% !important;
    max-width: 100vw !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
    overflow-x: hidden !important;
  }

  .topbar-row-primary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
    gap: 0.5rem;
  }

  .topbar-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 0;
    flex: 1 1 auto;
  }

  .topbar-left #menuToggle {
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: #0f223d;
    border: 1px solid rgba(56, 189, 248, 0.3);
    color: #ffffff;
    font-size: 1.35rem;
  }

  .topbar-right {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
    margin-left: 0;
  }

  .topbar-right .icon-btn,
  .topbar-right .universal-search-btn {
    width: 44px;
    min-width: 44px;
    height: 44px;
    padding: 0;
    border-radius: 12px;
    background: #0f223d;
    border: 1px solid rgba(56, 189, 248, 0.3);
    color: #ffffff;
    font-size: 1.15rem;
    display: inline-grid;
    place-items: center;
  }

  .topbar-title-wrap {
    min-width: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
  }

  .topbar-title-wrap h1 {
    font-size: clamp(0.86rem, 3.8vw, 1.15rem);
    font-weight: 800;
    font-family: var(--font-heading);
    color: #ffffff;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    line-height: 1.15;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .topbar-title-wrap .eyebrow {
    font-size: 0.68rem;
    font-weight: 800;
    color: #fac638;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-top: 0.15rem;
    line-height: 1;
    display: block;
  }

  .topbar-row-secondary {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
  }

  .topbar-row-secondary #manualRefreshBtn {
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: #0f223d;
    border: 1px solid rgba(56, 189, 248, 0.3);
    color: #ffffff;
    font-size: 1.25rem;
  }

  .topbar-row-secondary .dash-lang-switch,
  .topbar-row-secondary .dash-theme-switch {
    flex: 0 0 auto;
    height: 44px;
    background: #0f223d;
    border: 1px solid rgba(56, 189, 248, 0.3);
    padding: 3px 4px;
    display: inline-flex;
    align-items: center;
  }

  .topbar-row-secondary .dash-lang-switch button,
  .topbar-row-secondary .dash-theme-switch .theme-toggle-btn {
    font-size: 0.85rem;
    font-weight: 800;
    padding: 0.4rem 0.65rem;
    height: 100%;
  }

  .topbar-site-btn {
    flex: 1 1 0;
    height: 44px;
    min-width: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #142a4a;
    border: 1px solid rgba(56, 189, 248, 0.3);
    color: #ffffff !important;
    border-radius: 12px;
    font-weight: 700;
    font-size: 0.95rem;
    text-decoration: none;
    padding: 0 0.5rem;
    white-space: nowrap;
    transition: all 0.2s ease;
  }

  .topbar-site-btn:hover {
    background: #1c3b66;
    border-color: rgba(56, 189, 248, 0.55);
    color: #ffffff !important;
  }

  .topbar-logout-btn {
    flex: 1 1 0;
    height: 40px;
    min-width: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(234, 179, 8, 0.12);
    border: 1px solid rgba(234, 179, 8, 0.28);
    color: #facc15 !important;
    border-radius: 10px;
    font-weight: 700;
    font-size: 0.88rem;
    padding: 0 0.5rem;
    white-space: nowrap;
    transition: all 0.2s ease;
  }

  .topbar-logout-btn:hover {
    background: rgba(234, 179, 8, 0.22);
    border-color: rgba(234, 179, 8, 0.45);
    color: #ffffff !important;
  }
}

@media (max-width: 767.98px) {

  .filter-bar,
  .advanced-filter {
    grid-template-columns: 1fr;
  }

  .data-table table,
  .data-table thead,
  .data-table tbody,
  .data-table th,
  .data-table td,
  .data-table tr {
    display: block;
  }

  .data-table thead {
    display: none;
  }

  .data-table tbody tr {
    margin-bottom: 0.9rem;
    padding: 0.9rem 1rem;
    border: 1px solid rgba(32, 215, 255, 0.18);
    border-radius: 1rem;
    background: rgba(8, 19, 38, 0.9);
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.3);
    color: #f8fbff;
  }

  .data-table td {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.55rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    text-align: right;
    color: #e2e8f0;
  }

  .data-table td::before {
    content: attr(data-label);
    color: #94a3b8;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-align: left;
    text-transform: uppercase;
  }

  .data-table td:last-child {
    border-bottom: 0;
    align-items: flex-start;
  }
}

.churches-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem;
  margin-bottom: 1rem;
}

.churches-view-toggle {
  display: inline-flex;
  gap: 0.35rem;
  padding: 0.28rem;
  border: 1px solid rgba(32, 215, 255, 0.25);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.75);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.3);
}

.churches-view-toggle button {
  border: 0;
  border-radius: 999px;
  padding: 0.48rem 0.82rem;
  color: #cbd5e1;
  background: transparent;
  font-family: var(--font-ui);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  transition: all 0.18s ease;
}

.churches-view-toggle button.active {
  color: #06101f;
  background: linear-gradient(135deg, var(--gold-soft), var(--gold));
  box-shadow: 0 4px 12px rgba(245, 199, 85, 0.3);
}

.churches-view-toggle button:hover:not(.active) {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.12);
}

.churches-filter-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.church-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}

.church-card {
  padding: var(--card-pad);
  border: 1px solid rgba(56, 189, 248, 0.18);
  border-radius: 1rem;
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  color: var(--text-main);
}

.church-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.85rem;
  margin-bottom: 0.85rem;
}

.church-card h3 {
  margin: 0.35rem 0 0;
  color: #ffffff;
  font-family: var(--font-heading);
  font-size: 1.12rem;
  font-weight: 700;
  line-height: 1.3;
}

.church-card-meta {
  display: grid;
  gap: 0.45rem;
  margin: 0.85rem 0 1rem;
  color: #cbd5e1;
  font-family: var(--font-ui);
  font-size: 0.82rem;
}

.church-card-meta div {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
}

.church-card-meta span {
  color: #8ea8cc;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.church-badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.church-drawer-backdrop {
  position: fixed;
  inset: 0;
  z-index: 34;
  background: rgba(3, 8, 22, 0.62);
  backdrop-filter: blur(4px);
}

.church-drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 35;
  display: flex;
  flex-direction: column;
  width: min(100%, 560px);
  height: 100vh;
  height: 100dvh;
  border-left: 1px solid rgba(32, 215, 255, 0.2);
  background: linear-gradient(180deg, rgba(7, 18, 37, 0.99), rgba(10, 23, 48, 0.98));
  box-shadow: -18px 0 48px rgba(0, 0, 0, 0.34);
  transform: translateX(100%);
  transition: transform 0.28s ease;
}

.church-drawer.is-open {
  transform: translateX(0);
}

.church-drawer-head,
.church-drawer-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem;
  padding: 1rem 1.15rem;
  border-color: rgba(255, 255, 255, 0.1);
}

.church-drawer-head {
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.church-drawer-foot {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.church-drawer-title {
  margin: 0.2rem 0 0;
  color: #fff;
  font-family: var(--font-heading);
  font-size: 1.35rem;
}

.church-drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 1rem 1.15rem 1.25rem;
}

.church-detail-grid {
  display: grid;
  gap: 0.72rem;
}

.church-detail-grid > div {
  padding: 0.72rem 0.82rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.82rem;
  background: rgba(255, 255, 255, 0.04);
}

.church-detail-grid span {
  display: block;
  margin-bottom: 0.28rem;
  color: rgba(248, 251, 255, 0.58);
  font-family: var(--font-ui);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.church-detail-grid strong {
  color: #fff;
  font-family: var(--font-ui);
  font-size: 0.9rem;
  font-weight: 700;
  word-break: break-word;
}

.church-select-wrap .relational-church-select {
  margin-bottom: 0.35rem;
}

.church-select-add-btn {
  margin-top: 0.35rem;
  border-color: rgba(215, 174, 75, 0.45);
  color: var(--gold-soft);
}

.church-info-card {
  padding: 0.85rem 0.95rem;
  border: 1px solid rgba(32, 215, 255, 0.18);
  border-radius: 0.85rem;
  background: linear-gradient(135deg, rgba(23, 92, 255, 0.12), rgba(255, 255, 255, 0.04));
}

.church-info-card--empty {
  color: rgba(248, 251, 255, 0.55);
  font-size: 0.85rem;
}

.church-info-card-row {
  display: grid;
  grid-template-columns: minmax(7rem, 34%) 1fr;
  gap: 0.5rem 0.75rem;
  padding: 0.28rem 0;
  align-items: start;
}

.church-info-card-row + .church-info-card-row {
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.church-info-card-row span {
  color: rgba(248, 251, 255, 0.58);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.church-info-card-row strong {
  color: #fff;
  font-size: 0.88rem;
  font-weight: 700;
}

.church-info-card-row--times {
  grid-template-columns: 1fr;
}

.church-info-card-times {
  margin: 0.35rem 0 0;
  padding-left: 1rem;
  color: rgba(248, 251, 255, 0.9);
  font-size: 0.84rem;
}

.church-info-card-times li + li {
  margin-top: 0.2rem;
}

@media (max-width: 767.98px) {
  .church-info-card-row {
    grid-template-columns: 1fr;
    gap: 0.2rem;
  }

  .church-select-wrap,
  .relational-province-select,
  .relational-city-select {
    width: 100%;
  }
}

.church-drawer .form-label {
  color: rgba(248, 251, 255, 0.76);
  font-family: var(--font-ui);
  font-weight: 800;
}

.church-card-services {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 0 0 0.85rem;
}

.church-service-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.36rem 0.72rem;
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 999px;
  background: rgba(14, 165, 233, 0.15);
  color: #38bdf8;
  font-family: var(--font-ui);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.03em;
}

.church-service-times-detail {
  margin-top: 1rem;
  padding: 0.9rem 0.95rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.82rem;
  background: rgba(255, 255, 255, 0.04);
}

.church-service-times-detail-title,
.church-service-times-title {
  margin: 0 0 0.75rem;
  color: #fff;
  font-family: var(--font-ui);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.church-service-times-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.55rem;
}

.church-service-times-list li {
  padding: 0.62rem 0.72rem;
  border: 1px solid rgba(32, 215, 255, 0.16);
  border-radius: 0.72rem;
  background: rgba(32, 215, 255, 0.06);
  color: #fff;
  font-family: var(--font-ui);
  font-size: 0.86rem;
  font-weight: 600;
}

.church-service-empty {
  margin: 0;
  color: rgba(248, 251, 255, 0.58);
  font-family: var(--font-ui);
  font-size: 0.86rem;
}

.church-service-times-editor {
  margin-top: 0.35rem;
  padding: 0.95rem;
  border: 1px solid rgba(32, 215, 255, 0.18);
  border-radius: 0.9rem;
  background: rgba(255, 255, 255, 0.03);
}

.church-service-times-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
}

.church-service-presets {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.church-service-preset-btn {
  min-height: 2.5rem;
  padding: 0.5rem 0.85rem;
  border: 1px solid rgba(32, 215, 255, 0.34);
  border-radius: 999px;
  color: rgba(248, 251, 255, 0.9);
  background: rgba(32, 215, 255, 0.08);
  font-family: var(--font-ui);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.church-service-preset-btn:hover,
.church-service-preset-btn:focus {
  color: #06101f;
  background: linear-gradient(135deg, rgba(32, 215, 255, 0.92), rgba(32, 215, 255, 0.72));
}

.church-service-times-rows {
  display: grid;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
}

.church-service-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.65rem;
  padding: 0.8rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.82rem;
  background: rgba(255, 255, 255, 0.04);
}

.church-service-field {
  min-width: 0;
}

.church-service-active {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.church-service-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  min-height: 2.5rem;
  margin: 0;
  color: rgba(248, 251, 255, 0.88);
  font-family: var(--font-ui);
  font-size: 0.82rem;
  font-weight: 700;
}

.church-service-toggle input {
  width: 1.1rem;
  height: 1.1rem;
  accent-color: var(--cyan);
}

.church-service-remove-wrap {
  display: flex;
  align-items: flex-end;
}

.church-service-remove {
  min-height: 2.5rem;
  width: 100%;
}

.church-service-add-btn {
  min-height: 2.65rem;
  padding: 0.55rem 1rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.church-drawer--form {
  width: min(100%, 620px);
}

.finance-drawer .field-optional,
.church-drawer .field-optional,
.ops-modal .field-optional {
  color: rgba(248, 251, 255, 0.52);
  font-size: 0.78rem;
  font-weight: 600;
}

.finance-detail-section + .finance-detail-section {
  margin-top: 1rem;
}

.finance-detail-title {
  margin: 0 0 0.75rem;
  color: #fff;
  font-family: var(--font-ui);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.finance-verify-summary {
  display: grid;
  gap: 0.55rem;
  padding: 0.85rem;
  border: 1px solid rgba(32, 215, 255, 0.16);
  border-radius: 0.82rem;
  background: rgba(255, 255, 255, 0.04);
}

.finance-verify-summary > div {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  color: #fff;
  font-family: var(--font-ui);
  font-size: 0.86rem;
}

.finance-verify-summary span {
  color: rgba(248, 251, 255, 0.58);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.btn-outline-danger {
  min-height: 2.5rem;
  border: 1px solid rgba(255, 92, 122, 0.55);
  color: #ffb8c5;
  background: rgba(255, 92, 122, 0.08);
  font-family: var(--font-ui);
  font-weight: 800;
}

.btn-outline-danger:hover,
.btn-outline-danger:focus {
  color: #fff;
  background: rgba(220, 53, 69, 0.88);
  border-color: rgba(220, 53, 69, 0.95);
}

.finance-form-section {
  padding: 1rem;
  border: 1px solid rgba(32, 215, 255, 0.14);
  border-radius: 0.9rem;
  background: rgba(255, 255, 255, 0.03);
}

.finance-form-section + .finance-form-section {
  margin-top: 0.25rem;
}

.finance-form-section-title {
  margin: 0 0 0.85rem;
  color: #fff;
  font-family: var(--font-ui);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.finance-linked-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-bottom: 0.75rem;
  padding: 0.38rem 0.68rem;
  border: 1px solid rgba(32, 215, 255, 0.28);
  border-radius: 999px;
  background: rgba(32, 215, 255, 0.1);
  color: #9defff;
  font-family: var(--font-ui);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.finance-contributor-search-wrap {
  position: relative;
  margin-bottom: 0.85rem;
}

.finance-contributor-search {
  min-height: 2.75rem;
}

.finance-suggestion-list {
  position: absolute;
  top: calc(100% + 0.35rem);
  right: 0;
  left: 0;
  z-index: 12;
  display: grid;
  gap: 0.35rem;
  max-height: 18rem;
  overflow-y: auto;
  padding: 0.45rem;
  border: 1px solid rgba(32, 215, 255, 0.24);
  border-radius: 0.82rem;
  background: linear-gradient(180deg, rgba(8, 20, 40, 0.98), rgba(10, 24, 48, 0.98));
  box-shadow: 0 18px 36px rgba(0, 0, 0, 0.34);
}

.finance-suggestion-item,
.finance-suggestion-new,
.finance-suggestion-empty {
  width: 100%;
  min-height: 2.75rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.72rem;
  text-align: left;
}

.finance-suggestion-item {
  padding: 0.65rem 0.75rem;
  color: #fff;
  background: rgba(255, 255, 255, 0.03);
  font-family: var(--font-ui);
}

.finance-suggestion-item.is-active,
.finance-suggestion-item:hover,
.finance-suggestion-item:focus {
  border-color: rgba(32, 215, 255, 0.42);
  background: rgba(32, 215, 255, 0.12);
  outline: none;
}

.finance-suggestion-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  margin-bottom: 0.2rem;
}

.finance-suggestion-top strong {
  font-size: 0.88rem;
}

.finance-suggestion-meta {
  color: rgba(248, 251, 255, 0.72);
  font-size: 0.78rem;
  line-height: 1.35;
}

.finance-source-badge {
  flex-shrink: 0;
  padding: 0.2rem 0.48rem;
  border-radius: 999px;
  background: rgba(212, 175, 55, 0.16);
  color: #f6df9b;
  font-size: 0.64rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.finance-origin-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.finance-origin-public {
  background: rgba(56, 189, 248, 0.12);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.3);
}

.finance-origin-dashboard {
  background: rgba(234, 179, 8, 0.12);
  color: #facc15;
  border: 1px solid rgba(234, 179, 8, 0.3);
}

.finance-origin-imported {
  background: rgba(148, 163, 184, 0.12);
  color: #cbd5e1;
  border: 1px solid rgba(148, 163, 184, 0.25);
}

[data-theme="dark"] .finance-origin-public,
.dark-theme .finance-origin-public {
  background: rgba(14, 165, 233, 0.22);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.45);
}

[data-theme="dark"] .finance-origin-dashboard,
.dark-theme .finance-origin-dashboard {
  background: rgba(245, 158, 11, 0.22);
  color: #fbbf24;
  border: 1px solid rgba(251, 191, 36, 0.45);
}

[data-theme="dark"] .finance-origin-imported,
.dark-theme .finance-origin-imported {
  background: rgba(148, 163, 184, 0.22);
  color: #e2e8f0;
  border: 1px solid rgba(148, 163, 184, 0.45);
}

.finance-partner-actions {
  display: inline-flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 0.35rem;
  white-space: nowrap;
}

.finance-partner-actions .btn {
  padding: 0.25rem 0.5rem;
  font-size: 0.8rem;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  height: 28px;
  transition: all 0.18s ease;
}

.finance-partner-actions .btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.12);
}

.public-submission-lines {
  display: grid;
  gap: 0.75rem;
}

.public-submission-line {
  display: grid;
  gap: 0.45rem;
  padding: 0.85rem 1rem;
  border-radius: 0.85rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.public-submission-line > div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  font-size: 0.86rem;
}

.public-submission-line span {
  color: rgba(248, 251, 255, 0.62);
}

.public-submission-line-actions {
  justify-content: flex-end !important;
}

.public-submission-message {
  margin: 0;
  padding: 0.85rem 1rem;
  border-radius: 0.75rem;
  background: rgba(255, 255, 255, 0.04);
  color: rgba(248, 251, 255, 0.88);
  white-space: pre-wrap;
}

/* Finance reports v2 */
.finance-module-tabs {
  flex-wrap: wrap;
}

.finance-filters-panel {
  display: block;
  width: 100%;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
}

.finance-filters-panel .form-label {
  display: flex;
  align-items: center;
  font-size: 0.78rem;
  margin-bottom: 0.35rem;
  color: #94a3b8;
  font-weight: 600;
  letter-spacing: 0.2px;
}

.finance-filters-panel .form-select,
.finance-filters-panel .form-control {
  width: 100%;
  height: 2.5rem;
  font-size: 0.85rem;
  border-radius: 8px;
  background-color: rgba(255, 255, 255, 0.04) !important;
  color: #e2e8f0 !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  box-shadow: none;
  transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.finance-filters-panel .form-select:focus,
.finance-filters-panel .form-control:focus {
  background-color: #0c1f40 !important;
  border-color: rgba(234, 179, 8, 0.5) !important;
  color: #ffffff !important;
  box-shadow: 0 0 0 3px rgba(234, 179, 8, 0.18) !important;
}

.finance-report-filters {
  display: block;
  width: 100%;
}

.finance-report-stats .summary-card-value,
.finance-report-stats .metric-card strong {
  font-size: clamp(1.1rem, 2vw, 1.35rem);
}

.finance-chart-card .panel-head {
  margin-bottom: 0.75rem;
}

.finance-chart-row .finance-chart-label {
  min-width: 6.5rem;
  max-width: 8.5rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.78rem;
}

.finance-chart-fill {
  background: linear-gradient(90deg, rgba(34, 211, 238, 0.85), rgba(215, 173, 69, 0.9));
}

.finance-chart-empty {
  margin: 0;
  padding: 1.5rem 1rem;
  text-align: center;
  color: var(--subtitle-on-light);
  font-size: 0.88rem;
  opacity: 1;
}

.finance-donut-wrap {
  display: grid;
  grid-template-columns: minmax(8rem, 10rem) minmax(0, 1fr);
  gap: 1rem;
  align-items: center;
  padding: 0.5rem 0.25rem 0.75rem;
}

.finance-donut {
  width: 9.5rem;
  height: 9.5rem;
  border-radius: 50%;
  margin: 0 auto;
  position: relative;
}

.finance-donut-hole {
  position: absolute;
  inset: 22%;
  border-radius: 50%;
  background: #0d1728;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  line-height: 1.1;
}

.finance-donut-hole strong {
  font-size: 0.95rem;
  color: var(--value-on-light);
}

.finance-donut-hole span {
  font-size: 0.62rem;
  color: var(--subtitle-on-light);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 1;
}

.finance-donut-legend {
  display: grid;
  gap: 0.45rem;
}

.finance-donut-legend-item {
  display: grid;
  grid-template-columns: 0.65rem 1fr auto auto;
  gap: 0.45rem;
  align-items: center;
  font-size: 0.76rem;
}

.finance-donut-swatch {
  width: 0.65rem;
  height: 0.65rem;
  border-radius: 999px;
}

.finance-donut-legend-label {
  color: var(--label-on-light-alt);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  opacity: 1;
}

.finance-donut-legend-value {
  color: var(--text-dark-muted);
  font-size: 0.68rem;
}

.finance-chart-mode-toggle {
  margin-left: auto;
}

.finance-contributor-profile {
  padding: 1rem 1.1rem;
  border-radius: 1rem;
}

.finance-contributor-profile-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
}

.finance-contributor-total {
  color: var(--gold, #d7ad45);
  font-size: 1.15rem;
}

.finance-partner-arm-card {
  padding: 1rem;
  border-radius: 1rem;
}

.finance-partner-arm-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.finance-partner-arm-metrics {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  margin-bottom: 0.85rem;
}

.finance-partner-arm-metrics > div {
  padding: 0.55rem 0.65rem;
  border-radius: 0.65rem;
  background: rgba(255, 255, 255, 0.04);
  font-size: 0.8rem;
}

.finance-partner-arm-metrics span {
  display: block;
  color: rgba(248, 251, 255, 0.55);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.finance-growth-badge {
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
  font-size: 0.68rem;
  font-weight: 800;
}

.finance-growth-badge.is-up {
  background: rgba(52, 211, 153, 0.14);
  color: #6ee7b7;
}

.finance-growth-badge.is-down {
  background: rgba(248, 113, 113, 0.14);
  color: #fca5a5;
}

.finance-partner-arm-list {
  display: grid;
  gap: 0.4rem;
}

.finance-partner-chip {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.45rem 0.6rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.55rem;
  background: rgba(255, 255, 255, 0.03);
  color: rgba(248, 251, 255, 0.88);
  font-size: 0.78rem;
  text-align: left;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.finance-partner-chip:hover {
  border-color: rgba(34, 211, 238, 0.35);
  background: rgba(34, 211, 238, 0.08);
}

.finance-export-actions .btn {
  min-width: 10rem;
}

.finance-line-chart {
  padding: 0.5rem 0.25rem 0.75rem;
}

.finance-line-svg {
  width: 100%;
  height: 7.5rem;
  display: block;
}

.finance-line-stroke {
  filter: drop-shadow(0 0 6px rgba(215, 173, 69, 0.35));
}

.finance-line-labels {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(4.5rem, 1fr));
  gap: 0.45rem;
  margin-top: 0.65rem;
}

.finance-line-label {
  font-size: 0.72rem;
  text-align: center;
  color: rgba(248, 251, 255, 0.55);
}

.finance-line-label strong {
  display: block;
  color: #d7ad45;
  font-size: 0.78rem;
}

.finance-hbar-chart {
  display: grid;
  gap: 0.55rem;
  padding: 0.35rem 0;
}

.finance-hbar-row {
  display: grid;
  grid-template-columns: minmax(5rem, 7rem) 1fr auto;
  gap: 0.55rem;
  align-items: center;
}

.finance-hbar-label {
  font-size: 0.76rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: rgba(248, 251, 255, 0.78);
}

.finance-hbar-track {
  height: 0.55rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.finance-hbar-fill {
  height: 100%;
  border-radius: inherit;
}

.finance-hbar-value {
  font-size: 0.76rem;
  color: rgba(248, 251, 255, 0.88);
  min-width: 3.5rem;
  text-align: right;
}

.finance-metric-pill {
  padding: 0.65rem 0.75rem;
  border-radius: 0.75rem;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
  height: 100%;
}

.finance-metric-pill span {
  display: block;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: rgba(248, 251, 255, 0.5);
  margin-bottom: 0.2rem;
}

.finance-metric-pill strong {
  font-size: 0.88rem;
  color: var(--text-dark);
}

.finance-privacy-banner,
.finance-privacy-notice {
  padding: 0.75rem 1rem;
  border-radius: 0.75rem;
  background: rgba(34, 211, 238, 0.12);
  border: 1px solid rgba(34, 211, 238, 0.32);
  color: #044E63;
  font-size: 0.84rem;
  font-weight: 700;
}

.staff-birthday-panel {
  border-radius: 0.85rem;
  padding: 1rem 1.1rem;
}

.staff-birthday-panel h5 {
  color: var(--text-dark, #0f172a);
  font-weight: 700;
}

.staff-birthday-filters .form-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-dark, #0f172a);
}

.staff-birthday-shortlist li:last-child {
  border-bottom: 0 !important;
}

.summary-card--clickable {
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
  border: 1px solid rgba(15, 23, 42, 0.08);
}

.summary-card--clickable:hover,
.summary-card--clickable:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.12);
  border-color: rgba(34, 211, 238, 0.45);
  outline: none;
}

.summary-card--clickable .summary-card-hint {
  color: #0e7490;
  font-weight: 600;
}

.summary-filter-chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 0.65rem;
  padding: 0.65rem 0.85rem;
  margin-bottom: 1rem;
  border-radius: 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.025);
}

.summary-filter-chips-label {
  font-size: 0.82rem;
  font-weight: 700;
  color: #94a3b8;
}

.summary-filter-chip {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.14);
  border: 1px solid rgba(34, 211, 238, 0.32);
  color: #044e63;
  font-size: 0.78rem;
  font-weight: 600;
}

.summary-filter-clear {
  margin-left: auto;
}

.summary-card--clickable:focus-visible {
  outline: 2px solid rgba(212, 175, 55, 0.65);
  outline-offset: 2px;
}

.summary-card[aria-disabled="true"] {
  opacity: 0.65;
  cursor: not-allowed;
}

.staff-birthday-sections {
  display: grid;
  gap: 1rem;
}

.staff-birthday-section {
  border-radius: 0.85rem;
  padding: 1rem 1.1rem;
  border: 1px solid rgba(15, 23, 42, 0.08);
}

.staff-birthday-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
  padding-bottom: 0.65rem;
  border-bottom: 1px solid rgba(34, 211, 238, 0.18);
}

.staff-birthday-section-head h5 {
  color: var(--text-dark, #0f172a);
  font-weight: 700;
}

.staff-birthday-section-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2rem;
  min-height: 2rem;
  padding: 0 0.55rem;
  border-radius: 999px;
  background: rgba(34, 211, 238, 0.16);
  color: #044e63;
  font-size: 0.82rem;
  font-weight: 700;
}

.staff-birthday-cards-grid {
  display: grid;
  gap: 0.85rem;
}

.staff-birthday-card {
  border-radius: 0.8rem;
  padding: 0.95rem 1rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  color: #e2e8f0;
}

.staff-birthday-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.65rem;
}

.staff-birthday-card-name {
  color: #f8fafc;
  font-weight: 700;
  margin-bottom: 0.15rem;
}

.staff-birthday-card-role {
  color: #94a3b8;
  font-size: 0.84rem;
}

.staff-birthday-card-meta {
  display: grid;
  gap: 0.35rem;
  font-size: 0.84rem;
  color: #94a3b8;
  margin-bottom: 0.75rem;
}

.staff-birthday-card-meta strong {
  color: #f1f5f9;
}

.staff-birthday-today-badge {
  font-size: 1.35rem;
  line-height: 1;
}

.staff-birthday-link {
  color: #38bdf8 !important;
  text-decoration: none;
}

.staff-birthday-link:hover {
  color: #7dd3fc !important;
}

.staff-birthday-days {
  color: #38bdf8;
  font-weight: 700;
  font-size: 0.84rem;
}

.staff-birthday-panel--warning {
  border: 1px solid rgba(234, 179, 8, 0.28);
  background: rgba(234, 179, 8, 0.12);
  color: #facc15;
  font-weight: 600;
}

.staff-missing-dob-badge {
  display: inline-flex;
  align-items: center;
  margin-left: 0.35rem;
  padding: 0.1rem 0.45rem;
  border-radius: 999px;
  background: rgba(234, 179, 8, 0.14);
  border: 1px solid rgba(234, 179, 8, 0.3);
  color: #facc15;
  font-size: 0.72rem;
  font-weight: 700;
  white-space: nowrap;
}

.staff-birthday-modal-body .staff-birthday-cards-grid {
  margin-top: 0.25rem;
}

@media (max-width: 767.98px) {
  .staff-birthday-filters {
    padding: 0.85rem !important;
  }

  .staff-birthday-card-actions .action-cluster {
    flex-wrap: wrap;
  }
}

.finance-segment-tabs {
  flex-wrap: wrap;
}

.finance-highlight-card {
  padding: 0.85rem 0.9rem;
  border-radius: 1rem;
  min-height: 6.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.finance-highlight-icon {
  font-size: 1.1rem;
  margin-bottom: 0.15rem;
}

.finance-highlight-card strong {
  font-size: 0.95rem;
  line-height: 1.2;
}

.finance-highlight-card small {
  color: rgba(248, 251, 255, 0.5);
  font-size: 0.68rem;
}

.finance-tone-gold .finance-highlight-icon { color: #d7ad45; }
.finance-tone-cyan .finance-highlight-icon { color: #22d3ee; }
.finance-tone-green .finance-highlight-icon { color: #34d399; }
.finance-tone-amber .finance-highlight-icon { color: #fbbf24; }

.finance-partner-actions .btn {
  padding: 0.2rem 0.45rem;
}

.finance-status-badge.badge-verified,
.badge.finance-status-badge.badge-verified {
  background: rgba(52, 211, 153, 0.16);
  color: #6ee7b7;
}

.finance-status-badge.badge-pending {
  background: rgba(251, 191, 36, 0.16);
  color: #fcd34d;
}

.finance-status-badge.badge-rejected {
  background: rgba(248, 113, 113, 0.16);
  color: #fca5a5;
}

/* Reports hub & domain reports framework */
.reports-hub {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.reports-hub-main,
.reports-hub-requisitions {
  border: 1px solid rgba(34, 211, 238, 0.12);
  background: linear-gradient(145deg, rgba(11, 31, 63, 0.92), rgba(15, 42, 78, 0.88));
}

.reports-hub-tabs .tab-button {
  color: rgba(226, 232, 240, 0.72);
  border-color: rgba(148, 163, 184, 0.2);
}

.reports-hub-tabs .tab-button:hover,
.reports-hub-tabs .tab-button:focus-visible {
  color: #22d3ee;
  border-color: rgba(34, 211, 238, 0.45);
  box-shadow: 0 0 0 2px rgba(34, 211, 238, 0.15);
}

.reports-hub-tabs .tab-button.active {
  color: #0b1f3f;
  background: linear-gradient(135deg, #d7ad45, #f0cc6a);
  border-color: #d7ad45;
  font-weight: 600;
}

.reports-hub-executive .summary-card,
.reports-hub-executive .metric-card {
  border: 1px solid rgba(56, 189, 248, 0.18);
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
  color: #f8fafc;
}

.reports-hub-executive .summary-card .metric-label,
.reports-hub-executive .metric-card .metric-label {
  color: #8ea8cc;
}

.reports-hub-executive .summary-card .metric-value,
.reports-hub-executive .metric-card .metric-value {
  color: #ffffff;
}

.reports-hub-executive .summary-card:hover,
.reports-hub-executive .metric-card:hover {
  border-color: rgba(56, 189, 248, 0.5);
  box-shadow: 0 0 0 2px rgba(56, 189, 248, 0.15);
}

.reports-hub-panel .domain-reports-panel .glass-panel,
.reports-hub-requisitions .glass-panel {
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
  color: #f8fafc;
  border: 1px solid rgba(56, 189, 248, 0.18);
}

.reports-hub-panel .domain-reports-panel .panel-title,
.reports-hub-requisitions .panel-title {
  color: #ffffff;
}

.reports-hub-panel .domain-reports-panel .text-secondary,
.reports-hub-requisitions .text-secondary {
  color: #8ea8cc !important;
}

.domain-reports-panel .panel-title {
  color: #ffffff;
}

.domain-report-filters .form-label {
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #8ea8cc;
}

.domain-report-filters .form-select,
.domain-report-filters .form-control {
  background: #071328;
  border-color: rgba(56, 189, 248, 0.28);
  color: #ffffff;
}

.domain-report-filters .form-select:focus,
.domain-report-filters .form-control:focus {
  border-color: #38bdf8;
  box-shadow: 0 0 0 2px rgba(56, 189, 248, 0.2);
  color: #ffffff;
}

.domain-report-cards .summary-card,
.domain-report-cards .metric-card {
  min-height: 5.75rem;
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
  color: #f8fafc;
  border: 1px solid rgba(56, 189, 248, 0.18);
}

.domain-report-cards .metric-label {
  color: #8ea8cc;
}

.domain-report-cards .metric-value {
  color: #ffffff;
}

.domain-reports-panel .finance-chart-card {
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
  color: #f8fafc;
}

.domain-reports-panel .finance-chart-card .panel-title,
.domain-reports-panel .finance-chart-empty {
  color: #0b1f3f;
}

.domain-reports-panel .finance-hbar-label {
  color: #334155;
}

.domain-reports-panel .finance-hbar-value {
  color: #0b1f3f;
  font-weight: 600;
}

.domain-reports-panel .finance-donut-legend {
  color: #334155;
}

.domain-report-export .btn {
  min-height: 2.55rem;
}

@media (max-width: 767.98px) {
  .reports-hub-tabs {
    flex-wrap: wrap;
    gap: 0.35rem;
  }

  .reports-hub-tabs .tab-button {
    flex: 1 1 calc(50% - 0.35rem);
    min-width: 8.5rem;
    font-size: 0.78rem;
  }

  .domain-report-filters > [class*="col-"] {
    width: 100%;
  }

  .domain-report-export {
    flex-direction: column;
  }

  .domain-report-export .btn {
    width: 100%;
  }

  .reports-hub-executive > [class*="col-"] {
    width: 100%;
  }
}

@media print {
  .reports-hub-tabs,
  .domain-report-filters,
  .domain-report-export,
  .requisition-report-filters,
  .requisition-report-export {
    display: none !important;
  }
}

/* Requisition reports */
.requisition-reports-panel .panel-title {
  color: #f8fafc;
}

.requisition-report-filters .form-label {
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(226, 232, 240, 0.72);
}

.requisition-report-cards .summary-card,
.requisition-report-cards .metric-card {
  min-height: 5.75rem;
}

.requisition-report-export .btn {
  min-height: 2.55rem;
  padding-inline: 1rem;
}

.requisition-reports-compact .finance-chart-card {
  min-height: 16rem;
}

@media print {
  .ops-sidebar,
  .ops-topbar,
  .finance-module-tabs,
  .requisition-report-filters,
  .requisition-report-export,
  .summary-filter-chips {
    display: none !important;
  }

  .requisition-reports-panel,
  .requisition-reports-compact {
    break-inside: avoid;
  }
}

@media (max-width: 767.98px) {
  .requisition-report-filters > [class*="col-"] {
    width: 100%;
  }

  .requisition-report-cards > [class*="col-"] {
    width: 100%;
  }

  .requisition-report-export {
    flex-direction: column;
  }

  .requisition-report-export .btn {
    width: 100%;
  }

  .finance-donut-wrap {
    grid-template-columns: 1fr;
  }

  .finance-report-filters {
    grid-template-columns: 1fr;
  }

  .finance-hbar-row {
    grid-template-columns: 1fr;
    gap: 0.25rem;
  }

  .finance-hbar-value {
    text-align: left;
  }
}

.finance-suggestion-list mark {
  padding: 0;
  color: #9defff;
  background: transparent;
  font-weight: 800;
}

.finance-suggestion-new {
  padding: 0.7rem 0.8rem;
  color: #f6df9b;
  background: rgba(212, 175, 55, 0.08);
  font-family: var(--font-ui);
  font-size: 0.8rem;
  font-weight: 800;
}

.finance-suggestion-empty {
  padding: 0.7rem 0.8rem;
  color: rgba(248, 251, 255, 0.62);
  background: transparent;
  font-family: var(--font-ui);
  font-size: 0.82rem;
}

.finance-duplicate-warning {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  margin-bottom: 0.85rem;
  padding: 0.75rem 0.85rem;
  border: 1px solid rgba(255, 193, 7, 0.28);
  border-radius: 0.78rem;
  background: rgba(255, 193, 7, 0.08);
}

.finance-duplicate-copy {
  display: grid;
  gap: 0.2rem;
  color: #ffe6a7;
  font-family: var(--font-ui);
  font-size: 0.82rem;
}

.finance-duplicate-copy strong {
  font-size: 0.72rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.finance-duplicate-btn {
  min-height: 2.75rem;
  border: 1px solid rgba(32, 215, 255, 0.34);
  color: #9defff;
  background: rgba(32, 215, 255, 0.1);
  font-weight: 800;
}

.finance-save-contributor {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  min-height: 2.75rem;
  color: rgba(248, 251, 255, 0.86);
  font-family: var(--font-ui);
  font-weight: 600;
}

.ops-modal .modal-footer .btn,
.ops-modal .finance-suggestion-item,
.ops-modal .finance-suggestion-new,
.ops-modal .finance-duplicate-btn,
.ops-modal .finance-contributor-search,
.ops-modal .finance-save-contributor {
  min-height: 2.75rem;
}

@media (max-width: 767.98px) {
  .finance-form-section .col-md-6 {
    flex: 0 0 100%;
    max-width: 100%;
  }

  .finance-suggestion-list {
    position: static;
    margin-top: 0.45rem;
    max-height: none;
  }

  .finance-duplicate-warning {
    flex-direction: column;
    align-items: stretch;
  }

  .finance-duplicate-btn {
    width: 100%;
  }
}

@media (max-width: 1199.98px) {
  .churches-filter-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 767.98px) {
  .churches-filter-grid {
    grid-template-columns: 1fr 1fr;
  }

  .church-drawer,
  .church-drawer--form {
    width: 100%;
    max-width: 100%;
  }

  .church-service-row {
    grid-template-columns: 1fr;
  }

  .church-service-presets {
    width: 100%;
  }

  .church-service-preset-btn,
  .church-service-add-btn,
  .church-service-remove {
    width: 100%;
  }
}

@media (max-width: 575.98px) {
  .churches-filter-grid {
    grid-template-columns: 1fr;
  }
}

/* ─── Global UI System v2 ─── */
.page-shell {
  display: grid;
  gap: 1.25rem;
}

.module-hero-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  flex-wrap: wrap;
  padding: var(--card-pad);
  margin-bottom: 0.25rem;
  color: var(--text-main);
  border: 1px solid rgba(56, 189, 248, 0.2);
  border-radius: 1.25rem;
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.module-hero-card:hover {
  transform: translateY(-2px);
  border-color: rgba(56, 189, 248, 0.4);
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.3), 0 0 32px rgba(32, 215, 255, 0.12);
}

.module-hero-card--compact {
  margin-bottom: 0;
  border-radius: 1rem 1rem 0 0;
}

.module-hero-card-body {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-width: 0;
  flex: 1;
}

.module-hero-card-icon {
  width: 54px;
  height: 54px;
  display: grid;
  flex: 0 0 54px;
  place-items: center;
  border-radius: 1.1rem;
  color: #fff;
  font-size: 1.35rem;
  background: linear-gradient(135deg, var(--royal), var(--cyan));
  box-shadow: 0 14px 32px rgba(23, 92, 255, 0.28);
}

.module-hero-card-title {
  margin: 0.2rem 0 0;
  font-family: var(--font-heading);
  color: var(--ink);
  font-size: clamp(1.35rem, 2.8vw, 1.85rem);
  line-height: 1.1;
}

.module-hero-card-subtitle {
  margin: 0.35rem 0 0;
  color: var(--muted);
  font-size: 0.92rem;
  max-width: 56ch;
}

.module-hero-card-actions {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  flex-wrap: wrap;
}

.summary-card {
  position: relative;
  overflow: hidden;
}

.summary-card::after {
  content: "";
  position: absolute;
  inset: auto -20% -55% 45%;
  height: 120px;
  background: radial-gradient(circle, rgba(32, 215, 255, 0.12), transparent 68%);
  pointer-events: none;
}

.summary-card-label {
  display: block;
  color: #8ea8cc;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  line-height: 1.35;
  margin: 0;
  word-break: break-word;
  opacity: 1;
}

.summary-card-value {
  display: block;
  margin: 0.15rem 0 0.2rem;
  font-family: var(--font-primary);
  font-size: clamp(1.35rem, 1.8vw, 1.85rem);
  line-height: 1.2;
  color: #ffffff !important;
  font-weight: 800;
  word-break: break-word;
  overflow-wrap: break-word;
}

.summary-card-hint {
  display: block;
  color: #8ea8cc;
  font-size: 0.78rem;
  line-height: 1.35;
  margin-top: 0.15rem;
  word-break: break-word;
  opacity: 1;
}

.filter-toolbar {
  display: grid;
  grid-template-columns: minmax(220px, 1.5fr) repeat(auto-fit, minmax(150px, 1fr)) auto;
  gap: var(--filter-gap);
  align-items: center;
  padding: 0.9rem 1rem;
  margin-bottom: 1rem;
  color: var(--text-main);
  border: 1px solid rgba(56, 189, 248, 0.2);
  border-radius: 1rem;
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.2);
}

.filter-toolbar-search {
  position: relative;
}

.filter-toolbar-search i {
  position: absolute;
  left: 0.85rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted);
  pointer-events: none;
}

.filter-toolbar-search .form-control {
  padding-left: 2.35rem;
}

.filter-toolbar-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  justify-content: flex-end;
}

.view-toggle {
  display: inline-flex;
  gap: 0.3rem;
  padding: 0.22rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.03);
  box-shadow: none;
}

.view-toggle-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-height: 2.2rem;
  padding: 0.35rem 0.75rem;
  border: 0;
  border-radius: 999px;
  color: #94a3b8;
  background: transparent;
  font-size: 0.76rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  transition: all 0.18s ease;
}

.view-toggle-btn.active {
  color: #facc15;
  background: rgba(234, 179, 8, 0.14);
  border: 1px solid rgba(234, 179, 8, 0.3);
  box-shadow: none;
}

.view-toggle-btn:hover:not(.active) {
  color: #e2e8f0;
  background: rgba(255, 255, 255, 0.06);
}

.glass-panel {
  border: 1px solid rgba(32, 215, 255, 0.14);
  border-radius: 1.15rem;
  background: var(--glass);
  box-shadow: 0 20px 54px rgba(0, 0, 0, 0.14);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.glass-panel:hover {
  border-color: rgba(32, 215, 255, 0.3);
}

.data-card {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  padding: 1.1rem 1.15rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.data-card:hover {
  transform: translateY(-4px);
  border-color: rgba(32, 215, 255, 0.42);
  box-shadow: 0 26px 64px rgba(0, 0, 0, 0.18), 0 0 28px rgba(32, 215, 255, 0.1);
}

.data-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.data-card-title {
  margin: 0.15rem 0 0;
  font-size: 1.12rem;
  color: var(--ink);
}

.data-card-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  justify-content: flex-end;
}

.data-card-meta {
  display: grid;
  gap: 0.5rem;
}

.data-card-meta-row {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  padding-bottom: 0.42rem;
  border-bottom: 1px solid rgba(13, 23, 48, 0.07);
  font-size: 0.84rem;
}

.data-card-meta-row span {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.data-card-meta-row i {
  color: var(--royal);
}

.data-card-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.data-card-pill {
  padding: 0.28rem 0.62rem;
  border-radius: 999px;
  color: #0f338f;
  background: rgba(23, 92, 255, 0.1);
  font-size: 0.72rem;
  font-weight: 800;
}

.data-card-foot {
  margin-top: auto;
  padding-top: 0.35rem;
  border-top: 1px solid rgba(13, 23, 48, 0.08);
}

.data-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 1rem;
}

.data-table-wrap {
  padding: 0.35rem 0.35rem 0.65rem;
}

.data-table-desktop tbody tr {
  border-bottom: 1px solid rgba(13, 23, 48, 0.06);
}

.data-table-empty {
  padding: 0 !important;
  border: 0 !important;
}

.data-table-mobile {
  display: none;
  gap: 0.85rem;
}

.data-table-mobile-card {
  padding: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1rem;
  background: rgba(13, 23, 42, 0.75);
  box-shadow: none;
}

.data-table-mobile-row {
  display: grid;
  grid-template-columns: minmax(110px, 38%) 1fr;
  gap: 0.55rem;
  padding: 0.42rem 0;
  border-bottom: 1px solid rgba(13, 23, 48, 0.06);
  font-size: 0.86rem;
}

.data-table-mobile-row span {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.data-table-mobile-actions {
  margin-top: 0.65rem;
}

.status-badge {
  letter-spacing: 0.04em;
}

.status-pill.status-cyan {
  background: rgba(32, 215, 255, 0.16);
  color: #0a6f86;
}

.status-pill.status-orange {
  background: rgba(253, 126, 20, 0.14);
  color: #9a4d04;
}

.action-btn--primary {
  border-color: rgba(215, 174, 75, 0.55) !important;
  color: var(--navy-950) !important;
  background: linear-gradient(135deg, var(--gold-soft), var(--gold)) !important;
}

.action-btn--danger {
  border-color: rgba(220, 53, 69, 0.28) !important;
  color: #a01828 !important;
  background: rgba(220, 53, 69, 0.1) !important;
}

.action-btn--success {
  border-color: rgba(25, 135, 84, 0.28) !important;
  color: #0f6843 !important;
  background: rgba(25, 135, 84, 0.12) !important;
}

.btn-touch,
.action-btn,
.filter-toolbar .btn,
.module-hero-card .btn,
.data-card-foot .action-btn {
  min-height: 2.75rem;
}

.ui-empty-state {
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 0.55rem;
  padding: 2rem 1.25rem;
  border: 1px dashed rgba(32, 215, 255, 0.28);
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.55);
}

.ui-empty-state--compact {
  padding: 1rem;
}

.empty-state-icon {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border-radius: 1rem;
  color: var(--royal);
  background: rgba(23, 92, 255, 0.1);
  font-size: 1.35rem;
}

.empty-state-title {
  margin: 0;
  color: var(--ink);
  font-family: var(--font-heading);
  font-size: 1.1rem;
}

.empty-state-desc {
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
  max-width: 36ch;
}

.form-section {
  margin-bottom: 0.35rem;
}

.form-section-head {
  margin-bottom: 0.75rem;
}

.form-section-title {
  margin: 0;
  color: rgba(248, 251, 255, 0.92);
  font-size: 0.95rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.form-section-desc {
  margin: 0.35rem 0 0;
  color: rgba(248, 251, 255, 0.58);
  font-size: 0.82rem;
}

.kanban-board {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 0.85rem;
  margin-bottom: 1.25rem;
}

.kanban-column {
  display: flex;
  flex-direction: column;
  min-height: 220px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1rem;
  background: rgba(13, 23, 42, 0.65);
  box-shadow: none;
}

.kanban-column-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.75rem 0.85rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.kanban-column-head h4 {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #f1f5f9;
}

.kanban-count {
  min-width: 1.65rem;
  padding: 0.15rem 0.45rem;
  border-radius: 999px;
  text-align: center;
  color: #0f338f;
  background: rgba(23, 92, 255, 0.12);
  font-size: 0.72rem;
  font-weight: 900;
}

.kanban-column-body {
  display: grid;
  gap: 0.65rem;
  padding: 0.75rem;
  align-content: start;
}

.kanban-column--pending .kanban-column-head { border-top: 3px solid #d7ae4b; }
.kanban-column--contacted .kanban-column-head { border-top: 3px solid var(--royal); }
.kanban-column--closed .kanban-column-head { border-top: 3px solid #6c757d; }
.kanban-column--success .kanban-column-head { border-top: 3px solid #198754; }

/* Click-to-call link styles */
a[href^="tel:"] {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  color: #38bdf8;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.15s ease, opacity 0.15s ease, transform 0.15s ease;
  min-height: 24px;
}
a[href^="tel:"]:hover,
a[href^="tel:"]:focus {
  color: #7dd3fc;
  text-decoration: underline;
}
[data-theme="light"] a[href^="tel:"],
.theme-light a[href^="tel:"] {
  color: #0284c7;
}
[data-theme="light"] a[href^="tel:"]:hover,
.theme-light a[href^="tel:"]:focus {
  color: #0369a1;
}

/* Follow-up Kanban tabs & isolation */
.followup-kanban-tabs {
  display: flex;
  gap: 0.45rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  margin-bottom: 0.85rem;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}
.followup-kanban-tabs::-webkit-scrollbar {
  height: 4px;
}
.followup-kanban-tabs::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.2);
  border-radius: 4px;
}
.followup-kanban-tabs .btn {
  white-space: nowrap;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  font-size: 0.78rem;
  padding: 0.35rem 0.65rem;
  border-radius: 9999px;
  font-weight: 600;
}
.kanban-board--isolated .kanban-board {
  grid-template-columns: 1fr;
}
.kanban-board--isolated .kanban-column {
  min-height: auto;
}
.kanban-board--isolated .kanban-column-body {
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}
@media (max-width: 576px) {
  .kanban-board--isolated .kanban-column-body {
    grid-template-columns: 1fr;
  }
}

.module-tab-strip button,
.department-tabs button {
  transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

.module-tab-strip button.active,
.department-tabs button.active {
  box-shadow: 0 10px 24px rgba(215, 174, 75, 0.24);
}

.ops-modal,
.church-drawer,
.finance-drawer {
  backdrop-filter: blur(10px);
}

.ops-modal .modal-content {
  border: 1px solid rgba(32, 215, 255, 0.22);
  box-shadow: 0 32px 90px rgba(0, 0, 0, 0.45), 0 0 40px rgba(32, 215, 255, 0.08);
}

.ops-modal .modal-footer,
.church-drawer-foot,
.finance-drawer-foot {
  position: sticky;
  bottom: 0;
  z-index: 2;
  background: linear-gradient(180deg, rgba(7, 18, 37, 0.72), rgba(7, 18, 37, 0.96));
  backdrop-filter: blur(12px);
}

.foundation-progress-bar .progress-bar {
  background: linear-gradient(90deg, var(--royal), var(--cyan));
  box-shadow: 0 0 16px rgba(32, 215, 255, 0.35);
  transition: width 0.35s ease;
}

.churches-toolbar,
.churches-filter-grid {
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1rem;
  background: rgba(13, 23, 42, 0.65);
  box-shadow: none;
}

.churches-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
  padding: 0.85rem 1rem;
  margin-bottom: 0.85rem;
}

.churches-filter-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 0.7rem;
  padding: 0.9rem 1rem;
  margin-bottom: 1rem;
}

.church-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1rem;
}

.section-panel {
  border: 0;
  padding: 0;
  background: transparent;
  box-shadow: none;
}

@media (max-width: 991.98px) {
  .filter-toolbar {
    grid-template-columns: 1fr 1fr;
  }

  .filter-toolbar-search {
    grid-column: 1 / -1;
  }

  .filter-toolbar-actions {
    grid-column: 1 / -1;
    justify-content: stretch;
  }

  .filter-toolbar-actions .btn {
    flex: 1;
  }
}

@media (max-width: 767.98px) {
  .ops-content {
    padding: 1rem;
  }

  .module-hero-card {
    flex-direction: column;
    align-items: stretch;
  }

  .module-hero-card-actions {
    width: 100%;
  }

  .module-hero-card-actions .btn {
    flex: 1;
  }

  .filter-toolbar {
    grid-template-columns: 1fr;
  }

  .data-table-desktop {
    display: none;
  }

  .data-table-mobile {
    display: grid;
  }

  .kanban-board {
    grid-template-columns: 1fr;
  }

  .ops-hero {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .modal-dialog {
    margin: 0;
    max-width: 100%;
    height: 100%;
  }

  .ops-modal {
    min-height: 100vh;
    border-radius: 0;
  }
}

/* ============================================================
   Global Contrast & Legibility v3
   ============================================================ */

/* Dark surfaces: light text */
.ops-sidebar,
.ops-topbar,
.church-drawer,
.finance-drawer,
.ops-hero,
.ops-hero--command,
.card-dark,
.card-glass-dark {
  color: var(--text-main);
}

/* Light surfaces: dark text — never white on pale cards */
.panel,
.metric-card,
.chart-card,
.record-card,
.data-card,
.module-hero-card,
.filter-toolbar,
.glass-panel,
.data-table-wrap,
.data-table-mobile-card,
.kanban-column,
.churches-toolbar,
.churches-filter-grid,
.ui-empty-state,
.church-card,
.summary-card {
  color: #f8fafc;
}

.module-hero-card .eyebrow,
.church-card .eyebrow,
.data-card .eyebrow,
.panel .eyebrow {
  color: var(--gold);
}

.module-hero-card-title,
.panel-title,
.data-card-title,
.church-card h3 {
  color: #ffffff;
}

.module-hero-card-subtitle,
.metric-card small,
.metric-card span,
.data-card-meta-row span,
.church-card-meta span {
  color: #8ea8cc;
}

.metric-card strong,
.data-card-meta-row strong,
.church-card-meta strong {
  color: #ffffff;
}

/* Dashboard command hero — always dark regardless of shared classes */
.ops-hero.ops-hero--command,
section.ops-hero {
  color: #FFFFFF;
}

.ops-hero.ops-hero--command h2,
.ops-hero.ops-hero--command .panel-title {
  color: #FFFFFF;
}

.ops-hero.ops-hero--command p,
.ops-hero.ops-hero--command .module-hero-card-subtitle {
  color: #D7E3F5;
}

.ops-hero.ops-hero--command .eyebrow {
  color: var(--gold);
}

/* Surface card utilities */
.card-light,
.card-light-premium {
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
  color: var(--text-main);
  border: 1px solid rgba(56, 189, 248, 0.18);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}

.card-light:hover,
.card-light-premium:hover,
.metric-card:hover,
.data-card:hover,
.church-card:hover {
  border-color: rgba(56, 189, 248, 0.38);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.28), 0 0 24px rgba(56, 189, 248, 0.1);
}

/* Dark glass card utility */
.card-dark,
.card-glass-dark {
  background: linear-gradient(145deg, rgba(7, 19, 38, 0.96), rgba(9, 32, 60, 0.86));
  border: 1px solid rgba(34, 211, 238, 0.22);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.28);
}

/* Buttons */
.btn-ce-gold {
  --bs-btn-bg: var(--gold);
  --bs-btn-border-color: var(--border-gold);
  --bs-btn-color: #08172e;
  --bs-btn-hover-bg: #F8D97A;
  --bs-btn-hover-border-color: #F8D97A;
  --bs-btn-hover-color: #08172e;
  background: linear-gradient(135deg, rgba(245, 199, 85, 0.25), rgba(217, 119, 6, 0.38));
  color: #fde68a;
  border: 1px solid rgba(245, 199, 85, 0.55);
  font-weight: 800;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
  transition: all 0.18s ease;
}

.btn-ce-gold:hover {
  background: linear-gradient(135deg, rgba(245, 199, 85, 0.38), rgba(217, 119, 6, 0.5));
  border-color: rgba(245, 199, 85, 0.8);
  color: #ffffff;
  box-shadow: 0 6px 20px rgba(245, 199, 85, 0.25);
  transform: translateY(-1px);
}

.btn-outline-cyan {
  --bs-btn-color: #38bdf8;
  --bs-btn-border-color: rgba(56, 189, 248, 0.45);
  --bs-btn-hover-color: #ffffff;
  --bs-btn-hover-bg: rgba(14, 165, 233, 0.2);
  --bs-btn-hover-border-color: #38bdf8;
  color: #38bdf8;
  border-color: rgba(56, 189, 248, 0.45);
  background: rgba(14, 165, 233, 0.1);
  font-weight: 800;
}

.btn-outline-cyan:hover {
  background: rgba(14, 165, 233, 0.22);
  border-color: #38bdf8;
  color: #ffffff;
}

.btn-outline-success {
  --bs-btn-color: #4ade80;
  --bs-btn-border-color: rgba(74, 222, 128, 0.45);
  --bs-btn-hover-color: #ffffff;
  --bs-btn-hover-bg: rgba(34, 197, 94, 0.2);
  --bs-btn-hover-border-color: #4ade80;
  color: #4ade80;
  border-color: rgba(74, 222, 128, 0.45);
  background: rgba(34, 197, 94, 0.1);
  font-weight: 800;
}

.btn-outline-success:hover {
  background: rgba(34, 197, 94, 0.22);
  border-color: #4ade80;
  color: #ffffff;
}

.btn-outline-secondary {
  --bs-btn-color: #cbd5e1;
  --bs-btn-border-color: rgba(255, 255, 255, 0.2);
  --bs-btn-hover-color: #ffffff;
  --bs-btn-hover-bg: rgba(255, 255, 255, 0.12);
  --bs-btn-hover-border-color: rgba(255, 255, 255, 0.4);
  color: #cbd5e1;
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.06);
  font-weight: 700;
}

.btn-outline-secondary:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.45);
  color: #ffffff;
}

.btn-outline-gold {
  --bs-btn-color: #fbbf24;
  --bs-btn-border-color: rgba(245, 199, 85, 0.45);
  --bs-btn-hover-color: #ffffff;
  --bs-btn-hover-bg: rgba(245, 199, 85, 0.2);
  --bs-btn-hover-border-color: #fbbf24;
  color: #fbbf24;
  border-color: rgba(245, 199, 85, 0.45);
  background: rgba(245, 199, 85, 0.1);
  font-weight: 800;
}

.btn-outline-gold:hover {
  background: rgba(245, 199, 85, 0.22);
  border-color: #fbbf24;
  color: #ffffff;
}

/* Cell Portal Quick Actions 4-Grid */
.cell-portal-quick-actions {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.85rem;
  margin: 1.25rem 0 1.5rem 0;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
}
.cell-quick-action-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: space-between;
  padding: 1.15rem 1.25rem;
  border-radius: 14px;
  background: linear-gradient(145deg, rgba(17, 34, 64, 0.9) 0%, rgba(10, 20, 40, 0.96) 100%);
  border: 1px solid rgba(245, 199, 85, 0.28);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
  cursor: pointer;
  text-decoration: none !important;
  transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
  min-height: 125px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  box-sizing: border-box;
  text-align: left;
}
.cell-quick-action-card > div {
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
}
.cell-quick-action-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}
.cell-quick-action-card.action-gold {
  border-color: rgba(245, 199, 85, 0.38);
}
.cell-quick-action-card.action-gold:hover {
  border-color: rgba(245, 199, 85, 0.75);
  box-shadow: 0 8px 24px rgba(245, 199, 85, 0.18);
}
.cell-quick-action-card.action-cyan {
  border-color: rgba(56, 189, 248, 0.38);
}
.cell-quick-action-card.action-cyan:hover {
  border-color: rgba(56, 189, 248, 0.75);
  box-shadow: 0 8px 24px rgba(56, 189, 248, 0.18);
}
.cell-quick-action-card.action-emerald {
  border-color: rgba(52, 211, 153, 0.38);
}
.cell-quick-action-card.action-emerald:hover {
  border-color: rgba(52, 211, 153, 0.75);
  box-shadow: 0 8px 24px rgba(52, 211, 153, 0.18);
}
.cell-quick-action-card.action-amber {
  border-color: rgba(251, 146, 60, 0.38);
}
.cell-quick-action-card.action-amber:hover {
  border-color: rgba(251, 146, 60, 0.75);
  box-shadow: 0 8px 24px rgba(251, 146, 60, 0.18);
}
.cell-quick-action-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  margin-bottom: 0.75rem;
  flex-shrink: 0;
}
.action-gold .cell-quick-action-icon { background: rgba(245, 199, 85, 0.16); color: #facc15; }
.action-cyan .cell-quick-action-icon { background: rgba(56, 189, 248, 0.16); color: #38bdf8; }
.action-emerald .cell-quick-action-icon { background: rgba(52, 211, 153, 0.16); color: #34d399; }
.action-amber .cell-quick-action-icon { background: rgba(251, 146, 60, 0.16); color: #fb923c; }
.cell-quick-action-title {
  font-size: 0.96rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 0.25rem;
  line-height: 1.25;
  display: block;
  min-width: 0;
  word-break: break-word;
  overflow-wrap: anywhere;
}
.cell-quick-action-desc {
  font-size: 0.76rem;
  color: #94a3b8;
  line-height: 1.35;
  display: block;
  min-width: 0;
  word-break: break-word;
  overflow-wrap: anywhere;
}

[data-theme="light"] .cell-quick-action-card,
.theme-light .cell-quick-action-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}
[data-theme="light"] .cell-quick-action-title,
.theme-light .cell-quick-action-title {
  color: #0f172a;
}
[data-theme="light"] .cell-quick-action-desc,
.theme-light .cell-quick-action-desc {
  color: #64748b;
}

@media (max-width: 991px) {
  .cell-portal-quick-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.65rem;
    margin: 0.85rem 0 1.15rem 0;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
}
@media (max-width: 576px) {
  .cell-portal-quick-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.45rem;
    margin: 0.65rem 0 0.85rem 0;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }
  .cell-quick-action-card {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: flex-start !important;
    gap: 0.5rem !important;
    padding: 0.6rem 0.65rem !important;
    min-height: 60px !important;
    border-radius: 12px !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }
  .cell-quick-action-icon {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    font-size: 1.1rem !important;
    margin-bottom: 0 !important;
    border-radius: 8px !important;
    flex-shrink: 0 !important;
  }
  .cell-quick-action-card > div:last-child {
    min-width: 0 !important;
    flex: 1 1 auto !important;
    overflow: hidden !important;
  }
  .cell-quick-action-title {
    font-size: 0.78rem !important;
    margin-bottom: 0.1rem !important;
    line-height: 1.15 !important;
    font-weight: 700 !important;
    white-space: normal !important;
    overflow-wrap: break-word !important;
    word-break: break-word !important;
  }
  .cell-quick-action-desc {
    font-size: 0.64rem !important;
    line-height: 1.15 !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    overflow: hidden !important;
    overflow-wrap: break-word !important;
    word-break: break-word !important;
  }
}
@media (max-width: 375px) {
  .cell-portal-quick-actions {
    gap: 0.35rem;
  }
  .cell-quick-action-card {
    padding: 0.45rem 0.5rem !important;
    gap: 0.4rem !important;
    min-height: 56px !important;
  }
  .cell-quick-action-icon {
    width: 28px !important;
    height: 28px !important;
    min-width: 28px !important;
    font-size: 0.95rem !important;
  }
  .cell-quick-action-title {
    font-size: 0.74rem !important;
  }
  .cell-quick-action-desc {
    font-size: 0.6rem !important;
  }
}

/* Cell Portal Hero Actions — Dark Sleek Buttons */
.cell-portal-hero-actions .btn-ce-gold,
.cell-portal-shell button[data-open-member-candidate] {
  background: linear-gradient(135deg, rgba(245, 199, 85, 0.22), rgba(217, 119, 6, 0.35)) !important;
  border: 1px solid rgba(245, 199, 85, 0.5) !important;
  color: #fde68a !important;
  font-weight: 700 !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25) !important;
  backdrop-filter: blur(8px);
}

.cell-portal-hero-actions .btn-ce-gold:hover,
.cell-portal-shell button[data-open-member-candidate]:hover {
  background: linear-gradient(135deg, rgba(245, 199, 85, 0.35), rgba(217, 119, 6, 0.48)) !important;
  border-color: rgba(245, 199, 85, 0.75) !important;
  color: #ffffff !important;
  box-shadow: 0 6px 18px rgba(245, 199, 85, 0.25) !important;
  transform: translateY(-1px);
}

.cell-portal-hero-actions .btn-outline-gold {
  background: rgba(14, 28, 54, 0.75) !important;
  border: 1px solid rgba(245, 199, 85, 0.35) !important;
  color: #fbbf24 !important;
  backdrop-filter: blur(8px);
}

.cell-portal-hero-actions .btn-outline-gold:hover {
  background: rgba(245, 199, 85, 0.18) !important;
  border-color: rgba(245, 199, 85, 0.65) !important;
  color: #ffffff !important;
}

.cell-portal-hero-actions .btn-outline-cyan {
  background: rgba(14, 28, 54, 0.75) !important;
  border: 1px solid rgba(56, 189, 248, 0.35) !important;
  color: #38bdf8 !important;
  backdrop-filter: blur(8px);
}

.cell-portal-hero-actions .btn-outline-cyan:hover {
  background: rgba(56, 189, 248, 0.18) !important;
  border-color: rgba(56, 189, 248, 0.65) !important;
  color: #ffffff !important;
}

/* Light surface button text visibility safety net */
.light-surface .btn-outline-light,
#content .glass-panel .btn-outline-light,
#content .panel .btn-outline-light,
.data-table-wrap .btn-outline-light,
.notification-inbox .btn-outline-light,
.light-surface .btn-outline-glass,
#content .glass-panel .btn-outline-glass,
#content .panel .btn-outline-glass,
.data-table-wrap .btn-outline-glass {
  --bs-btn-color: #1e293b;
  --bs-btn-border-color: rgba(34, 211, 238, 0.45);
  --bs-btn-hover-bg: rgba(34, 211, 238, 0.12);
  --bs-btn-hover-border-color: rgba(34, 211, 238, 0.85);
  --bs-btn-hover-color: #0f172a;
  color: #1e293b !important;
  border-color: rgba(34, 211, 238, 0.45);
  background: rgba(255, 255, 255, 0.75);
}

.action-btn--ghost,
.action-btn.action-btn--ghost {
  color: #1D4ED8;
  border-color: rgba(37, 99, 235, 0.22);
  background: rgba(37, 99, 235, 0.06);
}

/* Tables — elegant, sleek dark slate table design */
.data-table-wrap,
.glass-panel.data-table-wrap,
#content .data-table-wrap {
  padding: 0 !important;
  background: rgba(13, 23, 42, 0.8) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: 14px !important;
  overflow: hidden !important;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25) !important;
  margin-bottom: 1.5rem;
}

.table-responsive.data-table {
  margin-bottom: 0 !important;
  border-radius: 14px !important;
  overflow-x: auto;
}

.table.data-table-desktop,
.data-table table {
  margin-bottom: 0 !important;
  border-collapse: separate;
  border-spacing: 0;
  width: 100%;
}

.table thead th,
.data-table-desktop thead th,
.data-table thead th,
#content .data-table thead th {
  background: #0b1528 !important;
  color: #94a3b8 !important;
  font-size: 0.72rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.06em !important;
  text-transform: uppercase !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
  padding: 0.85rem 1rem !important;
  white-space: nowrap !important;
  vertical-align: middle !important;
}

.table tbody td,
.data-table-desktop tbody td,
.data-table tbody td,
#content .data-table tbody td {
  color: #cbd5e1 !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
  padding: 0.8rem 1rem !important;
  font-size: 0.84rem !important;
  vertical-align: middle !important;
  background: transparent !important;
}

.table tbody tr,
.data-table-desktop tbody tr,
.data-table tbody tr,
#content .data-table tbody tr {
  transition: background 0.15s ease;
}

.table tbody tr:hover,
.data-table-desktop tbody tr:hover,
.data-table tbody tr:hover,
#content .data-table tbody tr:hover {
  background: rgba(56, 189, 248, 0.04) !important;
}

.table tbody tr:last-child td,
.data-table-desktop tbody tr:last-child td,
.data-table tbody tr:last-child td {
  border-bottom: 0 !important;
}

.eyebrow,
.church-card-type,
.church-card .eyebrow,
.data-card .eyebrow,
.data-card-titles .eyebrow,
.module-hero-card .eyebrow,
.panel .eyebrow {
  color: #facc15 !important;
  font-size: 0.72rem !important;
  font-weight: 800 !important;
  letter-spacing: 0.08em !important;
  text-transform: uppercase !important;
  display: inline-block;
  margin-bottom: 0.2rem;
}

/* Filter toolbar inputs */
.filter-toolbar .form-control,
.filter-toolbar .form-select,
.churches-filter-grid .form-control,
.churches-filter-grid .form-select,
.panel .form-control,
.panel .form-select {
  min-height: 2.75rem;
  color: #ffffff !important;
  background-color: #071328 !important;
  border: 1px solid rgba(56, 189, 248, 0.28) !important;
}

.filter-toolbar .form-control::placeholder,
.churches-filter-grid .form-control::placeholder,
.panel .form-control::placeholder {
  color: #8ea8cc !important;
  opacity: 1 !important;
}

.filter-toolbar .form-control:focus,
.filter-toolbar .form-select:focus,
.churches-filter-grid .form-control:focus,
.churches-filter-grid .form-select:focus,
.panel .form-control:focus,
.panel .form-select:focus {
  border-color: #38bdf8 !important;
  box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.25) !important;
  background-color: #071328 !important;
  color: #ffffff !important;
}

/* Church cards — improved hierarchy */
.church-card-type {
  color: var(--gold);
}

.church-card-public {
  color: #8ea8cc;
  font-size: 0.82rem;
  line-height: 1.4;
}

.church-card-meta {
  gap: 0.55rem;
  margin: 0.75rem 0 1rem;
  color: #cbd5e1;
  font-size: 0.86rem;
  line-height: 1.45;
}

.church-card-meta span {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: #8ea8cc;
  font-size: 0.68rem;
}

.church-card-meta span i {
  color: var(--cyan);
  font-size: 0.82rem;
}

.church-card-meta strong {
  text-align: right;
  font-weight: 700;
  color: #ffffff;
}

.church-badge-row {
  flex-shrink: 0;
  align-items: flex-start;
  justify-content: flex-end;
}

.church-card-foot,
.church-card-foot .action-cluster {
  gap: 0.45rem;
}

.church-card-foot .action-btn {
  min-height: 2.5rem;
}

.churches-toolbar,
.churches-filter-grid {
  color: var(--text-main);
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
  border: 1px solid rgba(56, 189, 248, 0.2);
}

/* Status badges — global consistency */
.status-pill.status-cyan {
  background: rgba(34, 211, 238, 0.18);
  color: #38bdf8;
}

.status-pill.status-orange {
  background: rgba(245, 199, 85, 0.22);
  color: #fbbf24;
}

/* Modals & drawers — dark glass with readable inputs */
.ops-modal .form-control,
.ops-modal .form-select,
.church-drawer .form-control,
.church-drawer .form-select,
.finance-drawer .form-control,
.finance-drawer .form-select {
  color: #ffffff !important;
  background-color: #071328 !important;
  border-color: rgba(56, 189, 248, 0.28) !important;
}

.ops-modal .form-label,
.church-drawer .form-label {
  color: var(--text-muted);
}

.ops-modal .modal-title {
  color: var(--text-main);
}

/* Module hero breadcrumb strip (optional) */
.module-hero-card--with-crumb {
  border-radius: 1.25rem 1.25rem 0 0;
  margin-bottom: 0;
}

.module-hero-breadcrumb {
  padding: 0.55rem 1.25rem;
  border: 1px solid rgba(34, 211, 238, 0.14);
  border-top: 0;
  border-radius: 0 0 1rem 1rem;
  background: linear-gradient(145deg, rgba(7, 19, 38, 0.96), rgba(9, 32, 60, 0.86));
  color: var(--text-muted);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
}

/* Page shell spacing */
.page-shell {
  display: flex;
  flex-direction: column;
  gap: var(--section-gap);
}

.page-shell > .row.g-3,
.page-shell > .row.g-4 {
  margin-bottom: 0;
}

/* Typography refinements */
.summary-card-value,
.metric-card strong {
  color: #ffffff;
  font-weight: 900;
  letter-spacing: -0.02em;
}

.summary-card-label,
.metric-card span {
  color: #8ea8cc;
  letter-spacing: 0.1em;
}

/* Kanban & empty states on surfaces */
.kanban-column {
  background: linear-gradient(180deg, #0e2040 0%, #08172e 100%);
  border: 1px solid rgba(56, 189, 248, 0.18);
}

.ui-empty-state {
  background: rgba(13, 30, 56, 0.72);
  color: var(--text-main);
}

.empty-state-desc {
  color: #8ea8cc;
}

/* Data card pills */
.data-card-pill {
  color: #38bdf8;
  background: rgba(34, 211, 238, 0.2);
  border: 1px solid rgba(34, 211, 238, 0.35);
}

/* Prevent Bootstrap utility clashes on cards */
.church-card .text-secondary,
.data-card .text-secondary,
.panel .text-secondary {
  color: #8ea8cc !important;
}

/* Glass panel on dark page background */
.glass-panel {
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
  color: var(--text-main);
  border: 1px solid rgba(56, 189, 248, 0.18);
}

.chart-row {
  color: #cbd5e1;
}

.chart-row strong {
  color: #ffffff;
}

/* ============================================================
   Dashboard Command Center v2
   ============================================================ */

.dashboard-overview-label {
  margin: 0.15rem 0 0.85rem;
}

.dashboard-overview-label .eyebrow {
  color: var(--gold);
}

.dashboard-stats-row,
.summary-cards-row {
  margin-bottom: 1.25rem;
}

.summary-cards-row > [class*="col-"],
.dashboard-stats-row > [class*="col-"] {
  display: flex;
  flex-direction: column;
}

.dashboard-section {
  margin-bottom: var(--section-gap);
  padding: var(--card-pad);
  border: 1px solid rgba(34, 211, 238, 0.22);
  border-radius: 1.25rem;
  background: linear-gradient(145deg, rgba(7, 19, 38, 0.92), rgba(10, 32, 56, 0.86));
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.22);
}

.dashboard-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1.1rem;
  padding-bottom: 0.85rem;
  border-bottom: 1px solid rgba(34, 211, 238, 0.16);
}

.dashboard-section-copy {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  min-width: 0;
}

.dashboard-section-icon {
  width: 46px;
  height: 46px;
  display: grid;
  flex: 0 0 46px;
  place-items: center;
  border-radius: 1rem;
  color: #fff;
  font-size: 1.15rem;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 12px 28px rgba(37, 99, 235, 0.28);
}

.dashboard-section-title {
  margin: 0;
  color: var(--text-main);
  font-family: var(--font-heading);
  font-size: clamp(1.2rem, 2.4vw, 1.55rem);
  line-height: 1.15;
}

.dashboard-section-subtitle {
  margin: 0.3rem 0 0;
  color: var(--text-muted);
  font-size: 0.88rem;
  max-width: 52ch;
}

.dashboard-section-link {
  white-space: nowrap;
}

.dashboard-quick-list {
  display: grid;
  gap: 0.65rem;
}

.dashboard-quick-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 0.75rem;
  align-items: center;
  padding: 0.85rem 1rem;
  border: 1px solid rgba(56, 189, 248, 0.18);
  border-radius: 1rem;
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.2);
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.dashboard-quick-item:hover {
  transform: translateY(-2px);
  border-color: rgba(56, 189, 248, 0.38);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.25);
}

.dashboard-quick-item-title {
  display: block;
  color: #ffffff;
  font-size: 0.95rem;
  font-weight: 800;
}

.dashboard-quick-item-meta {
  display: block;
  margin-top: 0.18rem;
  color: #8ea8cc;
  font-size: 0.78rem;
}

.dashboard-quick-item-badge {
  display: flex;
  justify-content: flex-end;
}

.dashboard-quick-item-actions .action-cluster {
  justify-content: flex-end;
}

.dashboard-side-card {
  padding: 1rem 1.1rem;
}

.dashboard-side-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.dashboard-side-metrics > div {
  padding: 0.85rem 0.95rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.95rem;
  background: rgba(255, 255, 255, 0.03);
  transition: all 0.2s ease;
}

.dashboard-side-metrics > div:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.18);
}

.dashboard-side-metrics span {
  display: block;
  color: #94a3b8;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.dashboard-side-metrics strong {
  display: block;
  margin-top: 0.25rem;
  color: #f8fafc;
  font-size: 1.45rem;
  font-weight: 800;
  line-height: 1;
}

.donut-item {
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  transition: all 0.2s ease;
}

.donut-item:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.18);
}

.donut-item span {
  display: block;
  color: #94a3b8;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.donut-item strong {
  color: #f8fafc;
  font-size: 1.35rem;
  font-weight: 800;
}

@media (max-width: 767.98px) {
  .dashboard-quick-item {
    grid-template-columns: 1fr;
  }

  .dashboard-quick-item-badge,
  .dashboard-quick-item-actions {
    justify-content: flex-start;
  }

  .dashboard-section-head {
    align-items: flex-start;
  }

  .dashboard-section-link {
    width: 100%;
  }
}

/* View toggle on light toolbar / light surface */
.light-surface .view-toggle,
.view-toggle.light-surface {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: none;
}

.light-surface .view-toggle-btn,
.view-toggle.light-surface .view-toggle-btn {
  color: #94a3b8;
}

.light-surface .view-toggle-btn.active,
.view-toggle.light-surface .view-toggle-btn.active {
  color: #facc15;
  background: rgba(234, 179, 8, 0.14);
  border: 1px solid rgba(234, 179, 8, 0.3);
  box-shadow: none;
}

.light-surface .view-toggle-btn:hover:not(.active),
.view-toggle.light-surface .view-toggle-btn:hover:not(.active) {
  color: #e2e8f0;
  background: rgba(255, 255, 255, 0.06);
}

/* ============================================================
   Modules v3 — sections, modals, tabs, contrast audit
   ============================================================ */

.module-section,
.dashboard-section {
  margin-bottom: var(--section-gap);
  padding: var(--card-pad);
  border: 1px solid rgba(34, 211, 238, 0.22);
  border-radius: 1.25rem;
  background: linear-gradient(145deg, rgba(7, 19, 38, 0.92), rgba(10, 32, 56, 0.86));
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.22);
}

.module-section-body .panel,
.module-section-body .glass-panel {
  margin-bottom: 0;
}

.module-section-link,
.dashboard-section-link {
  white-space: nowrap;
}

/* Modals — premium dark glass */
.ops-modal-shell .modal-backdrop {
  backdrop-filter: blur(6px);
}

.ops-modal-dialog {
  margin: 1.25rem auto;
}

.ops-modal {
  display: flex;
  flex-direction: column;
  max-height: calc(100vh - 2.5rem);
  color: var(--text-main);
  border: 1px solid rgba(34, 211, 238, 0.24);
  border-radius: 1.25rem;
  background: linear-gradient(160deg, rgba(7, 19, 38, 0.98), rgba(9, 32, 60, 0.96));
  box-shadow: 0 32px 90px rgba(0, 0, 0, 0.48), 0 0 40px rgba(34, 211, 238, 0.08);
  overflow: hidden;
}

.ops-modal-header {
  flex-shrink: 0;
  padding: 1.1rem 1.35rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.ops-modal-header .eyebrow {
  color: var(--gold);
}

.ops-modal-header .modal-title {
  margin-top: 0.2rem;
  color: var(--text-main);
  font-family: var(--font-heading);
  font-size: 1.35rem;
}

.ops-modal-close {
  width: 2.5rem;
  height: 2.5rem;
  border: 1px solid rgba(34, 211, 238, 0.28);
  border-radius: 0.85rem;
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.06);
}

.ops-modal-close:hover {
  color: var(--text-main);
  border-color: var(--border-cyan);
  background: rgba(34, 211, 238, 0.14);
}

.ops-modal-body {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 1.25rem 1.35rem 1rem;
  -webkit-overflow-scrolling: touch;
}

.ops-modal-footer {
  flex-shrink: 0;
  position: sticky;
  bottom: 0;
  z-index: 3;
  display: flex;
  gap: 0.65rem;
  justify-content: flex-end;
  padding: 0.95rem 1.35rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  background: linear-gradient(180deg, rgba(7, 19, 38, 0.82), rgba(7, 19, 38, 0.98));
  backdrop-filter: blur(12px);
}

.ops-modal .form-control,
.ops-modal .form-select,
.church-drawer .form-control,
.church-drawer .form-select,
.finance-drawer .form-control,
.finance-drawer .form-select {
  min-height: 2.75rem;
  color: var(--text-dark);
  background-color: var(--card-light);
  border-color: rgba(34, 211, 238, 0.28);
}

.ops-modal .form-label,
.church-drawer .form-label,
.finance-drawer .form-label {
  color: var(--text-muted);
  font-weight: 800;
}

.ops-modal .form-hint,
.church-drawer .form-hint,
.finance-drawer .form-hint,
.form-hint {
  color: var(--text-muted);
  font-size: 0.8rem;
  line-height: 1.45;
}

.ops-modal strong,
.church-drawer strong,
.finance-drawer strong {
  color: var(--text-main);
}

.media-assignment-form {
  padding: 1rem;
  border: 1px solid rgba(34, 211, 238, 0.22);
  border-radius: 1.1rem;
  background:
    radial-gradient(circle at top right, rgba(34, 211, 238, 0.14), transparent 34%),
    linear-gradient(135deg, rgba(10, 31, 61, 0.84), rgba(7, 19, 38, 0.92));
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.22);
}

.media-assignment-picker {
  height: 100%;
  padding: 0.85rem;
  border: 1px solid rgba(255, 211, 105, 0.2);
  border-radius: 0.9rem;
  background: rgba(255, 255, 255, 0.055);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.media-assignment-picker:hover {
  border-color: rgba(34, 211, 238, 0.42);
  box-shadow: 0 0 0 1px rgba(34, 211, 238, 0.08), 0 14px 34px rgba(34, 211, 238, 0.08);
  transform: translateY(-1px);
}

.media-assignment-picker .mini-chip {
  color: #08213d;
  background: linear-gradient(135deg, var(--gold), var(--gold-soft));
  border-color: rgba(255, 211, 105, 0.38);
}

.media-schedule-view {
  display: grid;
  gap: 1rem;
}

.media-schedule-view-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem;
  border: 1px solid rgba(34, 211, 238, 0.22);
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.06);
}

.media-schedule-view-head h3 {
  margin: 0.1rem 0 0;
  color: var(--text-main);
  font-family: var(--font-heading);
}

.media-schedule-view-head p {
  margin: 0.3rem 0 0;
  color: var(--text-muted);
}

.media-schedule-assignment-table {
  overflow: hidden;
  border: 1px solid rgba(34, 211, 238, 0.2);
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.055);
}

.media-schedule-assignment-head,
.media-schedule-assignment-row {
  display: grid;
  grid-template-columns: minmax(170px, 1.2fr) minmax(170px, 1.2fr) minmax(120px, 0.8fr) minmax(160px, 1fr);
  gap: 0.75rem;
  align-items: center;
  padding: 0.85rem 1rem;
}

.media-schedule-assignment-head {
  color: rgba(248, 251, 255, 0.68);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: rgba(34, 211, 238, 0.08);
}

.media-schedule-assignment-row + .media-schedule-assignment-row {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.media-schedule-assignment-row strong,
.media-schedule-assignment-row .assignment-role {
  color: var(--text-main);
}

.media-schedule-assignment-row span:last-child {
  color: var(--text-muted);
}

.btn-outline-glass {
  --bs-btn-color: var(--text-main);
  --bs-btn-border-color: rgba(255, 255, 255, 0.28);
  --bs-btn-hover-color: var(--text-main);
  --bs-btn-hover-bg: rgba(255, 255, 255, 0.1);
  --bs-btn-hover-border-color: var(--border-cyan);
  color: var(--text-main);
  border-color: rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.04);
  font-weight: 800;
}

/* Drawers */
.church-drawer,
.finance-drawer {
  display: flex;
  flex-direction: column;
}

.church-drawer-body,
.finance-drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 1rem 1.15rem 1.25rem;
  -webkit-overflow-scrolling: touch;
}

.church-drawer-foot,
.finance-drawer-foot {
  flex-shrink: 0;
  position: sticky;
  bottom: 0;
  z-index: 2;
  display: flex;
  gap: 0.55rem;
  justify-content: flex-end;
  padding: 0.95rem 1.15rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  background: linear-gradient(180deg, rgba(7, 19, 38, 0.82), rgba(7, 19, 38, 0.98));
  backdrop-filter: blur(12px);
}

.church-drawer .icon-btn,
.finance-drawer .icon-btn {
  border: 1px solid rgba(34, 211, 238, 0.28);
  border-radius: 0.85rem;
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.06);
}

/* Module nav & tabs refinement */
.module-nav-panel {
  border: 1px solid rgba(34, 211, 238, 0.14);
  background: linear-gradient(180deg, rgba(7, 19, 38, 0.35), rgba(3, 10, 25, 0.2));
}

.module-nav-panel .department-tabs,
.module-nav-panel .tab-strip.module-tab-strip {
  gap: 0.5rem;
  border-color: rgba(34, 211, 238, 0.18);
  background: linear-gradient(180deg, rgba(7, 19, 38, 0.98), rgba(3, 10, 25, 0.98));
  box-shadow: inset 0 1px 0 rgba(34, 211, 238, 0.08);
}

.module-nav-panel .department-tabs {
  scrollbar-color: rgba(34, 211, 238, 0.35) transparent;
}

.module-nav-panel .department-tabs button,
.module-nav-panel .tab-strip.module-tab-strip button {
  min-height: 2.65rem;
  color: #E6EEF8;
  border-color: rgba(34, 211, 238, 0.25);
  background: rgba(255, 255, 255, 0.08);
  opacity: 1;
}

.module-nav-panel .department-tabs button:hover,
.module-nav-panel .department-tabs button.active,
.module-nav-panel .tab-strip.module-tab-strip button:hover,
.module-nav-panel .tab-strip.module-tab-strip button.active {
  color: var(--text-dark);
  border-color: var(--border-gold);
  background: linear-gradient(135deg, var(--gold-soft), var(--gold));
  box-shadow: 0 10px 24px rgba(245, 199, 85, 0.22);
}

.cell-route-context {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem;
  padding: 0.55rem 0.95rem 0.65rem;
  color: var(--text-muted);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-top: 1px solid rgba(34, 211, 238, 0.1);
  background: linear-gradient(180deg, rgba(3, 10, 25, 0.92), rgba(7, 19, 38, 0.88));
}

.cell-route-context .eyebrow {
  color: var(--gold);
  font-size: 0.62rem;
}

.cell-route-sep {
  color: rgba(34, 211, 238, 0.55);
}

.module-nav-collapsed .eyebrow {
  color: var(--gold-dark);
}

/* Contrast audit — surfaces */
.panel .text-secondary,
.glass-panel .text-secondary,
.record-card .text-secondary,
.data-card .text-secondary,
.chart-card .text-secondary,
.metric-card .text-secondary {
  color: #8ea8cc !important;
}

.panel .progress,
.glass-panel .progress,
.record-card .progress {
  background: rgba(255, 255, 255, 0.08);
}

.panel small.text-secondary,
.glass-panel small.text-secondary {
  color: #8ea8cc !important;
}

.empty-state:not(.ui-empty-state) {
  color: #8ea8cc;
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
  border-color: rgba(56, 189, 248, 0.22);
}

#content .empty-state.ui-empty-state {
  color: var(--text-dark);
}

.step-row span {
  color: var(--text-dark-muted);
}

.step-row span.done {
  color: #047857;
  font-weight: 800;
}

.finance-form-section,
.form-section {
  padding: 0.85rem 0.95rem;
  margin-bottom: 0.65rem;
  border: 1px solid rgba(34, 211, 238, 0.14);
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.04);
}

.ops-modal .finance-form-section,
.church-drawer .finance-form-section {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(34, 211, 238, 0.16);
}

@media (max-width: 767.98px) {
  .ops-modal-dialog {
    margin: 0;
    max-width: 100%;
    min-height: 100%;
  }

  .ops-modal-shell .modal-dialog {
    height: 100%;
  }

  .ops-modal {
    min-height: 100vh;
    min-height: 100dvh;
    max-height: none;
    border-radius: 0;
  }

  .ops-modal-footer .btn,
  .church-drawer-foot .btn,
  .finance-drawer-foot .btn {
    flex: 1;
  }

  .module-section-head,
  .dashboard-section-head {
    align-items: flex-start;
  }

  .module-section-link,
  .dashboard-section-link {
    width: 100%;
  }

  .church-drawer,
  .finance-drawer {
    width: 100%;
    max-width: 100%;
  }

  .department-tabs {
    padding-bottom: 0.35rem;
  }
}

/* RBAC — locked sidebar modules */
.nav-item-btn.is-locked {
  opacity: 0.45;
  cursor: not-allowed;
  position: relative;
}

.nav-item-btn.is-locked:hover,
.nav-item-btn.is-locked:focus {
  background: transparent;
  color: inherit;
}

.nav-item-btn.is-locked .nav-lock-icon {
  margin-left: auto;
  font-size: 0.72rem;
  color: var(--ce-gold, #d4a853);
  opacity: 0.9;
}

.nav-item-btn.is-locked span {
  flex: 1;
}

.requisitions-module-tabs,
.staff-hr-module-tabs {
  flex-wrap: wrap;
}

.access-denied-panel {
  max-width: 560px;
  margin: 2rem auto;
}

.access-denied-icon {
  font-size: 3rem;
  color: var(--ce-cyan, #5eead4);
  opacity: 0.85;
}

/* ============================================================
   Global Contrast System v4 — light/dark surfaces & components
   ============================================================ */

.light-surface,
.surface-light {
  --tab-inactive-color: #E6EEF8;
  --tab-inactive-bg: rgba(255, 255, 255, 0.08);
  --tab-inactive-border: rgba(56, 189, 248, 0.25);
  color: var(--text-main, #f8fafc);
}

#content .glass-panel,
#content .panel:not(.ops-hero):not(.ops-modal),
#content .chart-card,
#content .metric-card,
#content .summary-card,
#content .record-card,
#content .data-card,
#content .module-hero-card,
#content .data-table-wrap,
#content .filter-toolbar,
#content .churches-toolbar,
#content .churches-filter-grid {
  --tab-inactive-color: #E6EEF8;
  --tab-inactive-bg: rgba(255, 255, 255, 0.08);
  --tab-inactive-border: rgba(56, 189, 248, 0.25);
  color: var(--text-main);
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
  border: 1px solid rgba(56, 189, 248, 0.18);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}

.dark-surface,
.surface-dark,
.ops-hero,
.ops-modal,
.church-drawer,
.finance-drawer,
.module-nav-panel,
.dashboard-section,
.module-section {
  --tab-inactive-color: #E6EEF8;
  --tab-inactive-bg: rgba(255, 255, 255, 0.08);
  --tab-inactive-border: rgba(56, 189, 248, 0.25);
  color: var(--text-main);
}

.light-surface .muted,
.light-surface .card-subtitle,
.light-surface .chart-label,
.light-surface .meta-text,
.light-surface .text-secondary,
.surface-light .muted {
  color: #8ea8cc !important;
}

#content .glass-panel .text-secondary,
#content .chart-card .text-secondary,
#content .panel .text-secondary {
  color: #8ea8cc !important;
}

.dark-surface .muted,
.dark-surface .card-subtitle,
.dark-surface .chart-label,
.dark-surface .meta-text,
.dark-surface .text-secondary,
.surface-dark .muted {
  color: #8ea8cc !important;
}

.light-surface .panel-title,
.light-surface h3,
.light-surface strong {
  color: #ffffff;
}

#content .chart-card .panel-title,
#content .glass-panel .panel-title,
#content .panel .panel-title {
  color: #ffffff;
}

.light-surface .eyebrow {
  color: var(--gold, #f59e0b);
}

#content .module-hero-card .eyebrow,
#content .data-card .eyebrow {
  color: var(--gold);
}

/* Charts on cards — finance & dashboard */
#content .chart-card .finance-hbar-label,
#content .chart-card .finance-hbar-value,
#content .glass-panel .finance-hbar-label,
#content .glass-panel .finance-hbar-value,
#content .chart-card .finance-chart-label,
#content .chart-card .finance-chart-value,
#content .chart-card .finance-line-label,
#content .chart-card .finance-line-label span,
#content .chart-card .chart-row span,
#content .chart-card .chart-row strong {
  color: #ffffff;
}

#content .chart-card .finance-line-label strong {
  color: var(--gold);
}

#content .chart-card .finance-chart-empty,
#content .glass-panel .finance-chart-empty {
  color: #8ea8cc;
}

#content .chart-card .finance-hbar-track,
#content .glass-panel .finance-hbar-track {
  background: rgba(255, 255, 255, 0.08);
}

#content .chart-card .finance-donut-hole {
  background: #08172e;
}

#content .chart-card .finance-donut-hole strong {
  color: #ffffff;
}

#content .chart-card .finance-donut-hole span,
#content .chart-card .finance-donut-legend-label {
  color: #8ea8cc;
}

#content .chart-card .finance-donut-legend-value {
  color: #cbd5e1;
}

#content .chart-card .finance-partner-chip {
  color: #38bdf8;
  background: rgba(14, 165, 233, 0.12);
  border-color: rgba(56, 189, 248, 0.28);
}

#content .chart-card .finance-partner-chip:hover {
  background: rgba(56, 189, 248, 0.22);
  border-color: rgba(56, 189, 248, 0.48);
}

#content .chart-card .finance-metric-pill,
#content .glass-panel .finance-metric-pill {
  background: rgba(14, 32, 64, 0.92);
  border-color: rgba(56, 189, 248, 0.25);
}

#content .chart-card .finance-metric-pill span,
#content .glass-panel .finance-metric-pill span {
  color: #8ea8cc;
}

#content .chart-card .finance-metric-pill strong,
#content .glass-panel .finance-metric-pill strong {
  color: #ffffff;
}

#content .chart-card .finance-partner-arm-metrics span {
  color: #8ea8cc;
}

#content .chart-card .finance-partner-arm-metrics > div {
  background: rgba(14, 32, 64, 0.88);
  color: #ffffff;
}

#content .chart-card .panel-title .text-info,
#content .glass-panel .panel-title .text-info {
  color: #38bdf8 !important;
}

/* Summary / metric cards */
#content .summary-card,
#content .metric-card {
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
  border: 1px solid rgba(56, 189, 248, 0.18);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}

#content .summary-card-label,
#content .metric-card span {
  color: #8ea8cc;
}

#content .summary-card-value,
#content .metric-card strong {
  color: #ffffff;
}

#content .summary-card-hint,
#content .metric-card small {
  color: #8ea8cc;
}

/* Data tables */
#content .data-table-wrap {
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
}

#content .data-table-mobile-card {
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
  color: var(--text-main);
  border: 1px solid rgba(56, 189, 248, 0.16);
}

#content .data-table-mobile-row span {
  color: #8ea8cc;
}

/* Filter inputs — dark field with crisp white text */
.filter-toolbar .form-control,
.filter-toolbar .form-select,
.churches-filter-grid .form-control,
.churches-filter-grid .form-select,
.finance-report-filters .form-control,
.finance-report-filters .form-select,
#content .form-control,
#content .form-select {
  color: #ffffff !important;
  background-color: #071328 !important;
  border-color: rgba(56, 189, 248, 0.28) !important;
}

.filter-toolbar .form-control::placeholder,
.churches-filter-grid .form-control::placeholder,
.finance-report-filters .form-control::placeholder,
#content .form-control::placeholder {
  color: #8ea8cc !important;
  opacity: 1 !important;
}

/* Action buttons on light and dark surfaces — low-contrast translucent slate styling */
#content .action-btn,
.action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.28rem 0.68rem;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.18s ease;
  color: #cbd5e1;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

#content .action-btn:hover,
.action-btn:hover {
  transform: translateY(-1px);
  color: #f8fafc;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.22);
  box-shadow: none;
}

.action-btn--view {
  color: #38bdf8 !important;
  background: rgba(56, 189, 248, 0.1) !important;
  border: 1px solid rgba(56, 189, 248, 0.28) !important;
}
.action-btn--view:hover {
  background: rgba(56, 189, 248, 0.2) !important;
  border-color: rgba(56, 189, 248, 0.45) !important;
  color: #7dd3fc !important;
}

.action-btn--edit {
  color: #facc15 !important;
  background: rgba(234, 179, 8, 0.1) !important;
  border: 1px solid rgba(234, 179, 8, 0.28) !important;
}
.action-btn--edit:hover {
  background: rgba(234, 179, 8, 0.2) !important;
  border-color: rgba(234, 179, 8, 0.45) !important;
  color: #fde047 !important;
}

.action-btn--success,
.action-btn--verify {
  color: #4ade80 !important;
  background: rgba(34, 197, 94, 0.1) !important;
  border: 1px solid rgba(34, 197, 94, 0.28) !important;
}
.action-btn--success:hover,
.action-btn--verify:hover {
  background: rgba(34, 197, 94, 0.2) !important;
  border-color: rgba(34, 197, 94, 0.45) !important;
  color: #86efac !important;
}

.action-btn--danger,
.action-btn--reject {
  color: #f87171 !important;
  background: rgba(239, 68, 68, 0.1) !important;
  border: 1px solid rgba(239, 68, 68, 0.28) !important;
}
.action-btn--danger:hover,
.action-btn--reject:hover {
  background: rgba(239, 68, 68, 0.2) !important;
  border-color: rgba(239, 68, 68, 0.45) !important;
  color: #fca5a5 !important;
}

.action-btn--status {
  color: #c084fc !important;
  background: rgba(168, 85, 247, 0.1) !important;
  border: 1px solid rgba(168, 85, 247, 0.28) !important;
}
.action-btn--status:hover {
  background: rgba(168, 85, 247, 0.2) !important;
  border-color: rgba(168, 85, 247, 0.45) !important;
  color: #d8b4fe !important;
}

.action-btn--gold,
.action-btn--export {
  color: #facc15 !important;
  background: rgba(234, 179, 8, 0.1) !important;
  border: 1px solid rgba(234, 179, 8, 0.28) !important;
}
.action-btn--gold:hover,
.action-btn--export:hover {
  background: rgba(234, 179, 8, 0.2) !important;
  border-color: rgba(234, 179, 8, 0.45) !important;
  color: #fde047 !important;
}

/* Foundation School — primary action strip (always visible above filters) */
.foundation-action-bar {
  display: flex !important;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: center;
  padding: 0.85rem 1rem;
  margin-bottom: 1rem;
  border: 1px solid rgba(215, 174, 75, 0.35);
  border-radius: 1rem;
  background: linear-gradient(135deg, rgba(215, 174, 75, 0.14), rgba(34, 211, 238, 0.1));
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.08);
}

.foundation-action-bar .foundation-action-btn {
  min-height: 2.75rem;
  font-weight: 800;
  white-space: nowrap;
}

#panel-foundation-classes .foundation-action-bar,
#panel-foundation-lessons .foundation-action-bar {
  position: relative;
  z-index: 2;
}

/* Status badges — styled with vibrant semantic tones above */

/* Locked sidebar — legible */
.nav-item-btn.is-locked {
  opacity: 0.55;
}

/* Focus accessibility */
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
.action-btn:focus-visible,
.nav-item-btn:focus-visible,
.tab-strip button:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 2px;
}

/* Dark glass cards inside page (partner highlights etc.) */
.card-dark-premium,
.finance-partner-arm-card.card-glass-dark {
  color: var(--text-main);
  background: linear-gradient(145deg, rgba(7, 19, 38, 0.96), rgba(9, 32, 60, 0.86));
  border: 1px solid rgba(34, 211, 238, 0.22);
}

.card-dark-premium .finance-partner-arm-metrics span,
.card-glass-dark .finance-partner-arm-metrics span {
  color: var(--text-muted);
}

.card-dark-premium .finance-partner-arm-metrics strong,
.card-glass-dark .finance-partner-arm-metrics strong {
  color: var(--text-main);
}

/* Module tabs inside light panels */
.finance-module-tabs,
.requisitions-module-tabs,
.staff-hr-module-tabs,
#content .glass-panel .tab-strip {
  gap: 0.45rem;
}

/* Empty states */
#content .ui-empty-state,
#content .empty-state {
  color: var(--text-dark);
}

#content .empty-state-desc,
#content .ui-empty-state p {
  color: var(--text-dark-muted);
}

/* Dark variant — module hero cards */
.module-hero-card.dark-surface,
.module-hero-card.surface-dark {
  color: var(--text-main);
  background: linear-gradient(145deg, rgba(7, 19, 38, 0.96), rgba(9, 32, 60, 0.86));
  border: 1px solid rgba(34, 211, 238, 0.22);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.28);
}

.module-hero-card.dark-surface .module-hero-card-title,
.module-hero-card.surface-dark .module-hero-card-title {
  color: #FFFFFF;
}

.module-hero-card.dark-surface .module-hero-card-subtitle,
.module-hero-card.surface-dark .module-hero-card-subtitle {
  color: #D7E3F5;
}

.module-hero-card.dark-surface .eyebrow,
.module-hero-card.surface-dark .eyebrow {
  color: var(--gold);
}

/* Tabs inside glass panels (Finanças, etc.) */
#content .glass-panel .tab-strip button,
#content .glass-panel .finance-module-tabs button {
  color: #f8fafc;
  background: rgba(13, 30, 56, 0.85);
  border: 1px solid rgba(56, 189, 248, 0.25);
  opacity: 1;
}

#content .glass-panel .tab-strip button.active,
#content .glass-panel .tab-strip button:hover:not(:disabled),
#content .glass-panel .finance-module-tabs button.active,
#content .glass-panel .finance-module-tabs button:hover:not(:disabled) {
  color: #0f172a;
  border-color: var(--border-gold);
  background: linear-gradient(135deg, var(--gold-soft), var(--gold));
  box-shadow: 0 8px 20px rgba(245, 199, 85, 0.24);
}

/* Chart mode / segment toggles */
.finance-chart-mode-toggle,
.finance-segment-tabs {
  display: inline-flex;
  gap: 0.3rem;
  padding: 0.22rem;
  border: 1px solid rgba(56, 189, 248, 0.25);
  border-radius: 999px;
  background: rgba(7, 19, 40, 0.85);
}

.finance-chart-mode-toggle button,
.finance-segment-tabs button {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  min-height: 2.75rem;
  padding: 0.45rem 0.85rem;
  border: 0;
  border-radius: 999px;
  color: #8ea8cc;
  background: transparent;
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  transition: background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}

.finance-chart-mode-toggle button.active,
.finance-chart-mode-toggle button:hover,
.finance-segment-tabs button.active,
.finance-segment-tabs button:hover {
  color: #0f172a;
  background: linear-gradient(135deg, var(--gold-soft), var(--gold));
  box-shadow: 0 8px 20px rgba(215, 174, 75, 0.22);
}

/* Church cards — stronger titles */
.church-card.light-surface h3,
.church-card h3 {
  color: #ffffff;
  font-weight: 800;
}

/* Locked tabs */
.tab-strip button.is-locked::before,
.tab-strip button:disabled .bi-lock {
  margin-right: 0.25rem;
}

/* ============================================================
   Global Contrast System v5 — surfaces
   ============================================================ */

.light-surface,
.surface-light {
  color: #f8fafc;
}

.light-surface h1,
.light-surface h2,
.light-surface h3,
.light-surface .card-title,
.light-surface .chart-title,
.light-surface .panel-title,
.light-surface .data-card-title,
.surface-light h1,
.surface-light h2,
.surface-light h3,
.surface-light .panel-title {
  color: #ffffff !important;
  opacity: 1 !important;
}

.light-surface .label,
.light-surface .metric-label,
.light-surface .summary-card-label,
.light-surface .chart-label,
.light-surface .muted,
.light-surface .subtitle,
.light-surface .meta-text,
.light-surface .card-subtitle,
.surface-light .label,
.surface-light .muted,
.surface-light .subtitle {
  color: #8ea8cc !important;
  opacity: 1 !important;
}

.light-surface .summary-card-hint,
.light-surface .subtitle.meta-text {
  color: #8ea8cc !important;
  opacity: 1 !important;
}

.light-surface .chart-value,
.light-surface .bar-value,
.light-surface .amount-value,
.light-surface .metric-value,
.light-surface .summary-card-value,
.light-surface .finance-chart-value,
.light-surface .finance-hbar-value,
.light-surface .chart-row strong,
.surface-light .metric-value,
.surface-light .summary-card-value {
  color: #ffffff !important;
  font-weight: 800 !important;
  opacity: 1 !important;
}

.light-surface .finance-chart-label,
.light-surface .finance-hbar-label,
.light-surface .chart-row span,
.light-surface .finance-donut-legend-label {
  color: #8ea8cc !important;
  opacity: 1 !important;
}

/* Module section cards */
.module-section .summary-card,
.module-section .metric-card,
.module-section .chart-card,
.module-section .glass-panel {
  background: linear-gradient(145deg, #0e2040 0%, #08172e 100%);
  border: 1px solid rgba(56, 189, 248, 0.18);
  color: #f8fafc;
}

.module-section .summary-card .summary-card-label,
.module-section .chart-card .finance-chart-label,
.module-section .chart-card .chart-row span {
  color: #8ea8cc !important;
  opacity: 1 !important;
}

.module-section .summary-card .summary-card-hint {
  color: #8ea8cc !important;
  opacity: 1 !important;
}

.module-section .panel-title,
.module-section .summary-card .summary-card-value,
.module-section .chart-card .finance-chart-value,
.module-section .chart-card .chart-row strong {
  color: #ffffff !important;
  font-weight: 800 !important;
  opacity: 1 !important;
}

.module-section .chart-card .finance-hbar-label {
  color: #8ea8cc !important;
  opacity: 1 !important;
}

.light-surface .finance-chart-empty,
.module-section .chart-card .finance-chart-empty {
  color: #8ea8cc !important;
  opacity: 1 !important;
}

.module-section .chart-card .finance-donut-hole {
  background: #08172e !important;
}

.module-section .chart-card .finance-donut-hole strong {
  color: #ffffff !important;
}

.light-surface .finance-donut-hole span,
.light-surface .finance-donut-legend-value,
.module-section .chart-card .finance-donut-hole span {
  color: #8ea8cc !important;
  opacity: 1 !important;
}

.light-surface .finance-donut-legend-label,
.module-section .chart-card .finance-donut-legend-label {
  color: #cbd5e1 !important;
  opacity: 1 !important;
}

/* Section headers stay light on dark glass shell */
.module-section-title,
.dashboard-section-title {
  color: #FFFFFF;
  opacity: 1;
}

.module-section-subtitle,
.dashboard-section-subtitle {
  color: #D7E3F5;
  opacity: 1;
}

/* Dark-only chart cards (no light-surface) */
.dark-surface .finance-chart-card:not(.light-surface) .finance-chart-empty,
.card-glass-dark .finance-chart-empty {
  color: var(--text-muted);
}

.dark-surface .finance-chart-card:not(.light-surface) .finance-donut-hole {
  background: var(--bg-panel);
}

.dark-surface .finance-chart-card:not(.light-surface) .finance-donut-hole strong {
  color: #FFFFFF;
}

.dark-surface .finance-chart-card:not(.light-surface) .finance-donut-legend-label {
  color: var(--text-muted);
}

/* ============================================================
   Module Tabs v6 — spacing, alignment, content separation
   ============================================================ */

.module-tabs,
.tab-strip.module-tab-strip,
.department-tabs.module-tab-strip,
nav.module-tabs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  padding: 16px 18px 18px;
  margin-bottom: 20px;
}

/* Tabs inside content cards (Finanças, Staff, Requisições, etc.) */
.module-content-card > .module-tabs,
.glass-panel.module-content-card > .module-tabs,
.glass-panel.module-content-card > .tab-strip.module-tab-strip {
  margin-bottom: 20px;
  border-bottom: 1px solid rgba(34, 211, 238, 0.12);
}

.tab-content-panel {
  padding: 0 18px 20px;
}

.module-tabs + .tab-content-panel,
.module-tabs + .module-section,
.module-tabs + .content-section,
.module-tabs + .panel-section,
.tab-strip.module-tab-strip + .tab-content-panel {
  margin-top: 0;
}

/* Sticky module nav — tabs attach to hero; shell provides gap to content */
.module-nav-panel .module-tabs,
.module-nav-panel .tab-strip.module-tab-strip,
.module-nav-panel .department-tabs.module-tab-strip {
  margin-bottom: 0;
  padding: 14px 18px 18px;
}

.module-nav-shell + .row,
.module-nav-shell + .summary-cards-row,
.module-nav-shell + .tab-content-panel,
.module-nav-shell + .module-section {
  margin-top: 0;
}

.tab-button,
.tab-strip .tab-button,
.module-tabs .tab-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 18px;
  line-height: 1;
  white-space: nowrap;
}

.tab-strip button.active,
.tab-strip button:hover:not(:disabled),
.tab-button.active,
.tab-button:hover:not(:disabled) {
  color: var(--text-dark);
}

@media (max-width: 767.98px) {
  .module-tabs,
  .tab-strip.module-tab-strip,
  .department-tabs.module-tab-strip {
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 8px;
    padding: 14px 14px 16px;
    margin-bottom: 16px;
    -webkit-overflow-scrolling: touch;
  }

  .tab-strip button,
  .department-tabs button,
  .tab-button {
    min-height: 40px;
    flex: 0 0 auto;
  }

  .tab-content-panel {
    padding: 0 14px 16px;
  }
}

/* Requisitions — pastoral approval drawer & actions */
.requisition-drawer {
  max-width: 640px;
}

.requisition-drawer-foot {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: flex-end;
}

.requisition-detail-section {
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
}

.requisition-detail-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.requisition-detail-title {
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.75rem;
}

.requisition-pastoral-section {
  background: linear-gradient(145deg, rgba(7, 19, 38, 0.04), rgba(34, 211, 238, 0.06));
  border: 1px solid rgba(34, 211, 238, 0.2);
  border-radius: 12px;
  padding: 1rem;
  margin-top: 0.5rem;
}

.requisition-attachment-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.requisition-attachment-list li {
  padding: 0.45rem 0;
  border-bottom: 1px dashed rgba(148, 163, 184, 0.2);
}

.requisition-attachment-list li:last-child {
  border-bottom: none;
}

.requisition-timeline {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.75rem;
}

.requisition-timeline li {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
}

.requisition-timeline-step {
  flex: 0 0 1.6rem;
  width: 1.6rem;
  height: 1.6rem;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 700;
  color: #0f172a;
  background: linear-gradient(135deg, var(--gold), #f5d67a);
}

.action-btn--approve {
  color: #166534;
  border-color: rgba(34, 197, 94, 0.45);
  background: rgba(34, 197, 94, 0.1);
}

.action-btn--approve:hover {
  background: rgba(34, 197, 94, 0.2);
  color: #14532d;
}

.action-btn--reject {
  color: #b91c1c;
  border-color: rgba(239, 68, 68, 0.4);
  background: rgba(239, 68, 68, 0.08);
}

.action-btn--reject:hover {
  background: rgba(239, 68, 68, 0.16);
  color: #991b1b;
}

.action-btn--return {
  color: #b45309;
  border-color: rgba(245, 158, 11, 0.45);
  background: rgba(245, 158, 11, 0.1);
}

.action-btn--return:hover {
  background: rgba(245, 158, 11, 0.18);
  color: #92400e;
}

.req-btn-approve {
  background: linear-gradient(135deg, var(--gold), #e8c547);
  border-color: transparent;
  color: #0f172a;
  font-weight: 600;
}

.req-btn-reject {
  border-color: rgba(239, 68, 68, 0.5);
  color: #dc2626;
}

.req-btn-return {
  border-color: rgba(245, 158, 11, 0.55);
  color: #d97706;
}

.status-pill.status-cyan {
  color: #0e7490;
  background: rgba(34, 211, 238, 0.14);
  border-color: rgba(34, 211, 238, 0.35);
}

.requisition-finance-section {
  background: linear-gradient(145deg, rgba(245, 158, 11, 0.05), rgba(34, 197, 94, 0.06));
  border: 1px solid rgba(34, 197, 94, 0.18);
  border-radius: 12px;
  padding: 1rem;
}

.finance-approved-req-filters .form-label {
  font-size: 0.78rem;
  font-weight: 600;
}

.cell-accordion-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}

.cell-accordion-search {
  position: relative;
  flex: 1 1 320px;
}

.cell-accordion-search i {
  position: absolute;
  top: 50%;
  left: 0.85rem;
  transform: translateY(-50%);
  color: var(--cyan);
}

.cell-accordion-search .form-control {
  padding-left: 2.35rem;
}

.cell-accordion-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.cell-group-accordion {
  display: grid;
  gap: 0.85rem;
}

.cell-group-item {
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1rem;
  background: rgba(13, 23, 42, 0.75);
  color: #f8fafc;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}

.cell-group-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem;
  cursor: pointer;
  list-style: none;
}

.cell-group-item summary::-webkit-details-marker {
  display: none;
}

.cell-group-title {
  display: grid;
  gap: 0.2rem;
}

.cell-group-title strong {
  color: #ffffff;
  font-size: 1rem;
}

.cell-group-title span,
.cell-group-summary-meta span {
  color: #94a3b8;
  font-size: 0.78rem;
  font-weight: 700;
}

.cell-group-summary-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.5rem;
}

.cell-count-pill,
.cell-mini-metrics span {
  border: 1px solid rgba(56, 189, 248, 0.22);
  border-radius: 999px;
  padding: 0.25rem 0.6rem;
  background: rgba(56, 189, 248, 0.08);
  color: #38bdf8;
}

.cell-group-inner {
  display: grid;
  gap: 0.8rem;
  padding: 0 1rem 1rem;
}

.cell-mini-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.cell-select-empty {
  display: block;
  margin-top: 0.35rem;
  color: #b45309;
  font-size: 0.78rem;
  font-weight: 800;
}

@media (max-width: 767.98px) {
  .media-schedule-view-head,
  .media-schedule-assignment-head,
  .media-schedule-assignment-row {
    grid-template-columns: 1fr;
  }

  .media-schedule-view-head {
    align-items: stretch;
    flex-direction: column;
  }

  .media-schedule-view-head .btn {
    width: 100%;
  }

  .media-schedule-assignment-head {
    display: none;
  }

  .media-schedule-assignment-row {
    gap: 0.35rem;
  }

  .cell-accordion-toolbar,
  .cell-group-item summary {
    align-items: stretch;
    flex-direction: column;
  }

  .cell-group-summary-meta {
    justify-content: flex-start;
  }

  .notification-wrap {
    position: static;
  }

  .notification-panel {
    position: fixed;
    inset: var(--topbar-height) 0 0 0;
    width: auto;
    max-height: none;
    border-right: 0;
    border-left: 0;
    border-bottom: 0;
    border-radius: 1.1rem 1.1rem 0 0;
  }

  .notification-panel-head,
  .notification-panel-actions,
  .notification-page-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .notification-panel-actions .btn,
  .notification-page-toolbar .btn {
    width: 100%;
  }

  .notification-list {
    max-height: none;
  }

  .notification-item {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .notification-item-open {
    grid-column: 2;
    justify-self: flex-end;
  }
}

/* Pagination Footer for Cell Portal (In-Flow Standard Placement) */
.cell-portal-pagination-footer {
  position: static;
  background: rgba(10, 25, 47, 0.85);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 0.75rem 1rem;
  margin-top: 1rem;
  border-radius: 0 0 0.75rem 0.75rem;
  box-shadow: none;
  z-index: 1;
}

/* Keyboard Pill */
.kbd-pill {
  font-family: inherit;
  font-size: 0.7rem;
  padding: 0.15rem 0.4rem;
  border-radius: 0.3rem;
  background: rgba(255, 255, 255, 0.15);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* Dynamic Topbar Breadcrumbs */
.topbar-breadcrumbs {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.6);
  margin-left: 0.75rem;
  align-items: center;
  gap: 0.4rem;
}
.topbar-breadcrumbs a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: color 0.2s ease;
}
.topbar-breadcrumbs a:hover {
  color: var(--gold);
}
.topbar-breadcrumbs span.sep {
  color: rgba(255, 255, 255, 0.3);
}

/* Sticky Floating Batch Action Bar */
.batch-action-bar {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(15, 23, 42, 0.95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(245, 199, 85, 0.4);
  padding: 0.75rem 1.5rem;
  border-radius: 9999px;
  z-index: 1050;
  min-width: 320px;
  animation: batchSlideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes batchSlideUp {
  from { transform: translate(-50%, 100%); opacity: 0; }
  to { transform: translate(-50%, 0); opacity: 1; }
}

/* Audit History Drawer Timeline */
.timeline {
  position: relative;
  padding-left: 1.5rem;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 0.5rem;
  top: 0;
  bottom: 0;
  width: 2px;
  background: rgba(255, 255, 255, 0.1);
}
.timeline-item {
  position: relative;
  margin-bottom: 1.25rem;
}
.timeline-marker {
  position: absolute;
  left: -1.5rem;
  top: 0.25rem;
  width: 0.75rem;
  height: 0.75rem;
  border-radius: 50%;
  background: var(--gold);
  border: 2px solid #0f172a;
}
.timeline-content {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.5rem;
  padding: 0.75rem;
}

/* ALEC Member Autocomplete Suggestions */
.alec-member-suggestions {
  top: 100%;
  left: 0;
  right: 0;
  max-height: 240px;
  overflow-y: auto;
  border-radius: 0.5rem;
  background: #0f172a;
  border: 1px solid rgba(245, 199, 85, 0.4);
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5);
  z-index: 1060;
}
.alec-member-suggestion-item {
  cursor: pointer;
  transition: background 0.15s ease;
}
.alec-member-suggestion-item:hover,
.alec-member-suggestion-item.is-active {
  background: rgba(245, 199, 85, 0.15) !important;
  border-color: var(--gold) !important;
}

/* Manual Data Refresh Animation & Quick Feedback Toast */
@keyframes spin-clockwise {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}
.spin-animation {
  display: inline-block;
  animation: spin-clockwise 0.75s linear infinite;
}

.dash-quick-toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  padding: 10px 18px;
  border-radius: 8px;
  background: rgba(15, 23, 42, 0.95);
  border: 1px solid rgba(245, 199, 85, 0.4);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 600;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5);
  z-index: 10000;
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
}
.dash-quick-toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}
.dash-quick-toast.is-success {
  border-color: rgba(34, 197, 94, 0.5);
  color: #86efac;
}



.foundation-class-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 0.95rem;
  border: 1px solid rgba(56, 189, 248, 0.35);
  border-radius: 0.85rem;
  background: rgba(15, 23, 42, 0.7);
  transition: all 0.2s ease;
}

.foundation-class-item:has(input[type="checkbox"]:checked) {
  border-color: rgba(56, 189, 248, 0.7);
  background: rgba(14, 165, 233, 0.15);
}

.foundation-score-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: #0f172a;
  padding: 0.25rem 0.6rem;
  border-radius: 0.5rem;
  border: 1px solid rgba(56, 189, 248, 0.5);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.foundation-score-badge .score-label {
  font-size: 0.82rem;
  font-weight: 700;
  color: #f1f5f9;
  white-space: nowrap;
}

.foundation-score-badge input[type="number"] {
  width: 58px;
  height: 28px;
  font-weight: 800;
  font-size: 0.95rem;
  background: #1e293b !important;
  color: #38bdf8 !important;
  border: 1px solid #38bdf8 !important;
  border-radius: 4px;
  text-align: center;
}

.foundation-score-badge input[type="number"]::placeholder {
  color: #94a3b8;
  font-size: 0.8rem;
  font-weight: 600;
  opacity: 0.85;
}

.foundation-score-badge .score-max {
  font-size: 0.85rem;
  font-weight: 800;
  color: #38bdf8;
}

/* ==========================================================================
   ALEC (Advanced Leadership Education Course) - Excel-Style Pauta & Reports
   ========================================================================== */

.alec-pauta-container {
  background: var(--bg-panel);
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.alec-nav-pills {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  padding: 0.5rem;
  background: rgba(11, 27, 51, 0.6);
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.alec-nav-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.85rem;
  color: #94a3b8;
  background: transparent;
  border: 1px solid transparent;
  transition: all 0.2s ease;
  cursor: pointer;
}

.alec-nav-btn:hover {
  color: #f8fafc;
  background: rgba(255, 255, 255, 0.06);
}

.alec-nav-btn.active {
  color: #030a18;
  background: linear-gradient(135deg, #f5c755, #eab308);
  border-color: #f5c755;
  box-shadow: 0 4px 12px rgba(245, 199, 85, 0.25);
}

.alec-excel-table-wrap {
  overflow-x: auto;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #071326;
}

.alec-excel-table {
  width: 100%;
  margin-bottom: 0;
  border-collapse: separate;
  border-spacing: 0;
  color: #f1f5f9;
  font-size: 0.84rem;
}

.alec-excel-table th,
.alec-excel-table td {
  padding: 0.55rem 0.65rem;
  vertical-align: middle;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  border-right: 1px solid rgba(255, 255, 255, 0.05);
}

.alec-excel-table th:last-child,
.alec-excel-table td:last-child {
  border-right: none;
}

.alec-excel-table thead tr.super-header th {
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.65rem 0.5rem;
}

.alec-excel-table thead tr.sub-header th {
  font-size: 0.75rem;
  font-weight: 700;
  background: #0b1e3b;
  color: #cbd5e1;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.alec-th-aluno { background: #0e2448 !important; color: #f5c755 !important; }
.alec-th-phase1 { background: #14532d !important; color: #86efac !important; }
.alec-th-phase2 { background: #064e3b !important; color: #6ee7b7 !important; }
.alec-th-media { background: #0c4a6e !important; color: #7dd3fc !important; }
.alec-th-terminou { background: #1e293b !important; color: #4ade80 !important; }
.alec-th-faixa { background: #3b2a04 !important; color: #fde047 !important; }
.alec-th-actions { background: #0f172a !important; color: #94a3b8 !important; }

.alec-excel-table tbody tr:hover {
  background: rgba(34, 211, 238, 0.06) !important;
}

.alec-score-cell {
  text-align: center;
  font-weight: 700;
  font-family: monospace, sans-serif;
  font-size: 0.88rem;
}

.alec-score-val {
  display: inline-block;
  min-width: 24px;
  padding: 2px 4px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.04);
}

.alec-score-high { color: #4ade80; font-weight: 800; }
.alec-score-mid { color: #facc15; font-weight: 700; }
.alec-score-low { color: #f87171; font-weight: 700; }

.alec-badge-sim {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
  font-weight: 800;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  background: rgba(22, 163, 74, 0.2);
  color: #4ade80;
  border: 1px solid rgba(74, 222, 128, 0.4);
}

.alec-badge-nao {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
  font-weight: 800;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  background: rgba(148, 163, 184, 0.1);
  color: #94a3b8;
  border: 1px solid rgba(148, 163, 184, 0.2);
}

/* Report Table Styling (Images 3 & 4) */
.alec-report-table-wrap {
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  overflow: hidden;
  background: #08162c;
}

.alec-report-table {
  width: 100%;
  margin-bottom: 0;
  border-collapse: separate;
  border-spacing: 0;
  color: #f1f5f9;
}

.alec-report-table thead th {
  background: #0e2a52;
  color: #ffffff;
  font-weight: 800;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.75rem 1rem;
  border-bottom: 2px solid #f5c755;
}

.alec-report-table tbody td {
  padding: 0.65rem 1rem;
  vertical-align: middle;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.88rem;
}

.alec-report-table tbody tr:nth-child(even) {
  background: rgba(255, 255, 255, 0.02);
}

.alec-report-table tbody tr:hover {
  background: rgba(245, 199, 85, 0.08) !important;
}

.alec-report-table tfoot td {
  background: #07172f;
  color: #ffffff;
  font-weight: 800;
  font-size: 0.95rem;
  padding: 0.85rem 1rem;
  border-top: 2px solid #f5c755;
}

.alec-report-total-cell {
  background: #0b2244 !important;
  color: #f5c755 !important;
  font-size: 1.05rem !important;
  font-weight: 900 !important;
  text-align: right;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.spin-animation {
  animation: spin 0.8s linear infinite;
  display: inline-block;
}

.dash-quick-toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 1099;
  background: #0f274a;
  color: #ffffff;
  padding: 0.75rem 1.25rem;
  border-radius: 10px;
  font-size: 0.9rem;
  font-weight: 600;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
  border: 1px solid rgba(245, 199, 85, 0.4);
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
  pointer-events: none;
}

.dash-quick-toast.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dash-quick-toast.is-success {
  border-color: #10b981;
  background: #06281e;
  color: #a7f3d0;
}

.dash-quick-toast.is-error {
  border-color: #ef4444;
  background: #331116;
  color: #fecaca;
}

.dash-quick-toast.is-info {
  border-color: #38bdf8;
  background: #08283f;
  color: #bae6fd;
}

/* ==========================================================================
   User Export Suite Styling
   ========================================================================== */
.user-export-modal .modal-content {
  background: linear-gradient(135deg, rgba(8, 20, 44, 0.96) 0%, rgba(13, 33, 68, 0.98) 100%);
  border: 1px solid rgba(245, 199, 85, 0.3) !important;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(20px);
}

.user-export-modal .modal-content {
  background: #0d1527 !important;
  border: 1px solid rgba(212, 175, 55, 0.3) !important;
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.8) !important;
}

.user-export-modal .form-label {
  font-weight: 600;
  letter-spacing: 0.03em;
  color: #cbd5e1 !important;
}

.user-export-modal .form-select,
.user-export-modal .form-control {
  background: #1e293b !important;
  border: 1px solid rgba(255, 255, 255, 0.22) !important;
  color: #f8fafc !important;
  border-radius: 6px;
  font-size: 0.85rem;
}

.user-export-modal .form-select option {
  background: #0f172a;
  color: #f8fafc;
}

.user-export-modal .form-select:focus,
.user-export-modal .form-control:focus {
  background: #1e293b !important;
  border-color: var(--ce-gold, #f5c755) !important;
  color: #ffffff !important;
  box-shadow: 0 0 0 0.25rem rgba(245, 199, 85, 0.25) !important;
}

.user-export-modal .ue-preview-wrapper {
  background: #060b14 !important;
  border: 1px solid rgba(212, 175, 55, 0.25) !important;
  border-radius: 8px;
  max-height: 290px;
  overflow: auto;
}

.user-export-modal #uePreviewTable {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin-bottom: 0;
  font-size: 0.82rem;
  background-color: #060b14 !important;
}

.user-export-modal #uePreviewTable th {
  background: #0f1d36 !important;
  color: #ffd700 !important; /* Vivid Gold */
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 10px 14px !important;
  border-bottom: 2px solid #d4af37 !important;
  position: sticky;
  top: 0;
  z-index: 5;
  white-space: nowrap;
}

.user-export-modal #uePreviewTable tbody tr {
  background-color: #091120 !important;
  transition: background-color 0.15s ease;
}

.user-export-modal #uePreviewTable tbody tr:nth-child(even) {
  background-color: #0f1a30 !important;
}

.user-export-modal #uePreviewTable tbody tr:hover {
  background-color: rgba(212, 175, 55, 0.18) !important;
}

.user-export-modal #uePreviewTable td {
  padding: 8px 14px !important;
  color: #f8fafc !important; /* Ultra-crisp bright white/silver */
  font-size: 0.82rem !important;
  font-weight: 500;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
  vertical-align: middle;
  white-space: nowrap;
}

.user-export-modal #uePreviewTable td .user-name-cell {
  color: #ffffff !important;
  font-weight: 700;
}

.user-export-modal #uePreviewTable td .user-email-cell {
  color: #38bdf8 !important; /* Bright Sky Blue */
}

.user-export-modal #uePreviewTable td .badge {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
}

/* ==========================================================================
   Department / Route Loading Stage (Pulsating LoveWorld Logo & Blurred Glass)
   ========================================================================== */
.dept-loading-stage {
  min-height: calc(100vh - var(--topbar-height, 70px) - 5rem);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2.5rem 1.5rem;
  position: relative;
  overflow: hidden;
  width: 100%;
}

.dept-loading-backdrop {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 40%, rgba(15, 28, 46, 0.6) 0%, rgba(8, 17, 33, 0.92) 100%);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 0;
}

.dept-loading-card {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: rgba(15, 28, 46, 0.82);
  border: 1px solid rgba(229, 179, 66, 0.28);
  border-radius: 24px;
  padding: 2.6rem 3.2rem;
  max-width: 420px;
  width: 100%;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.6), inset 0 0 0 1px rgba(255, 255, 255, 0.06);
  animation: deptCardFadeIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.dept-loading-logo-wrapper {
  position: relative;
  width: 86px;
  height: 86px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.4rem;
}

.dept-loading-logo {
  height: 60px;
  width: auto;
  max-width: 82px;
  object-fit: contain;
  position: relative;
  z-index: 2;
  animation: deptLogoPulse 1.8s ease-in-out infinite;
  filter: drop-shadow(0 4px 16px rgba(229, 179, 66, 0.5));
}

.dept-loading-glow {
  position: absolute;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(229, 179, 66, 0.4) 0%, rgba(32, 215, 255, 0.18) 50%, transparent 72%);
  animation: deptGlowPulse 1.8s ease-in-out infinite;
  z-index: 1;
}

.dept-loading-info {
  width: 100%;
}

.dept-loading-title {
  color: #ffffff;
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 1.1rem;
  letter-spacing: -0.01em;
}

.dept-loading-progress-track {
  width: 100%;
  height: 4px;
  background: rgba(255, 255, 255, 0.09);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 0.85rem;
  position: relative;
}

.dept-loading-progress-bar {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 40%;
  background: linear-gradient(90deg, #e5b342, #ffd875, #20d7ff);
  border-radius: 999px;
  animation: deptProgressSlide 1.3s ease-in-out infinite;
}

.dept-loading-subtitle {
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.82rem;
  margin: 0;
  font-weight: 500;
}

@keyframes deptCardFadeIn {
  from { opacity: 0; transform: translateY(10px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes deptLogoPulse {
  0%, 100% { transform: scale(1); opacity: 0.92; }
  50% { transform: scale(1.09); opacity: 1; filter: drop-shadow(0 6px 22px rgba(229, 179, 66, 0.7)); }
}

@keyframes deptGlowPulse {
  0%, 100% { transform: scale(0.85); opacity: 0.25; }
  50% { transform: scale(1.3); opacity: 0.75; }
}

@keyframes deptProgressSlide {
  0% { left: -40%; }
  100% { left: 100%; }
}

/* ==========================================================================
   Cell Portal Sidebar Navigation & Mobile/Tablet Layout Enhancements
   ========================================================================== */
.nav-cell-portal-area {
  margin-bottom: 0.35rem;
  border-radius: 0.85rem;
  background: rgba(229, 179, 66, 0.03);
  border: 1px solid rgba(229, 179, 66, 0.12);
}

.nav-cell-portal-area.has-active {
  border-color: rgba(229, 179, 66, 0.35);
  background: rgba(229, 179, 66, 0.06);
}

.nav-cell-portal-area {
  margin: 0.35rem 0.25rem 0.55rem;
  border: 1px solid rgba(32, 215, 255, 0.22);
  border-radius: 0.85rem;
  background: rgba(8, 19, 38, 0.85);
  overflow: hidden;
  transition: all 0.24s ease;
}

.nav-cell-portal-area.is-expanded {
  border-color: rgba(229, 179, 66, 0.45);
  background: rgba(10, 24, 48, 0.96);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(229, 179, 66, 0.18);
}

.nav-cell-portal-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  padding: 0.72rem 0.85rem;
  border: none;
  background: transparent;
  color: #f8fbff;
  font-size: 0.86rem;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
  transition: all 0.18s ease;
}

.nav-cell-portal-toggle:hover {
  color: #ffd875;
  background: rgba(229, 179, 66, 0.1);
}

.nav-cell-portal-toggle .nav-cell-area-icon {
  font-size: 1.1rem;
  color: #fac638;
}

.nav-cell-portal-toggle .nav-cell-area-chevron {
  font-size: 0.85rem;
  color: #38bdf8;
  transition: transform 0.24s ease;
}

.nav-cell-portal-area.is-expanded .nav-cell-portal-toggle .nav-cell-area-chevron {
  transform: rotate(180deg);
}

.nav-cell-portal-area .nav-cell-area-body {
  display: none;
}

.nav-cell-portal-area.is-expanded .nav-cell-area-body {
  display: block;
  padding: 0.35rem 0.35rem 0.55rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.nav-cell-portal-subitems {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.nav-cell-section-item {
  display: flex !important;
  align-items: center !important;
  font-size: 0.82rem !important;
  font-weight: 600 !important;
  padding: 0.55rem 0.8rem !important;
  border-radius: 0.7rem !important;
  margin: 0 !important;
  width: 100% !important;
  color: #cbd5e1 !important;
  background: rgba(255, 255, 255, 0.03) !important;
  border: 1px solid rgba(255, 255, 255, 0.05) !important;
  cursor: pointer !important;
  text-decoration: none !important;
  transition: all 0.18s ease !important;
}

.nav-cell-section-item i {
  font-size: 0.95rem !important;
  color: #38bdf8 !important;
  flex: 0 0 20px !important;
}

.nav-cell-section-item:hover,
.nav-cell-section-item.active {
  color: #ffffff !important;
  background: linear-gradient(135deg, rgba(229, 179, 66, 0.22), rgba(32, 215, 255, 0.15)) !important;
  border-color: rgba(229, 179, 66, 0.5) !important;
  transform: translateX(3px) !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25) !important;
}

.nav-cell-section-item.active i {
  color: #ffd875 !important;
}

/* Mobile & Tablet Optimizations for Cell Portal */
@media (max-width: 991px) {
  .cell-portal-hero {
    flex-direction: column;
    align-items: stretch;
    gap: 1.1rem;
    padding: 1.15rem;
  }

  .cell-portal-hero-actions {
    display: flex;
    flex-direction: column;
    width: 100%;
    gap: 0.65rem;
  }

  .cell-portal-hero-actions .btn {
    width: 100%;
    justify-content: center;
    padding: 0.65rem 1rem;
    font-size: 0.88rem;
  }

  .cell-portal-filters {
    padding: 0.85rem;
    gap: 0.65rem;
  }

  .cell-portal-section {
    scroll-margin-top: calc(var(--topbar-height, 60px) + 12px);
  }

  .nav-cell-section-item {
    padding: 0.65rem 0.85rem;
    font-size: 0.8rem;
    min-height: 42px;
  }
}

/* Small Phones (< 576px and < 420px: iPhone 16, iPhone SE, Pixel 9) */
@media (max-width: 576px) {
  .cell-portal-shell {
    padding-top: 0.25rem;
  }

  .cell-portal-hero {
    padding: 0.85rem 0.95rem !important;
    border-radius: 14px !important;
    margin-bottom: 0.65rem !important;
    gap: 0.45rem !important;
  }

  .cell-portal-hero .eyebrow {
    font-size: 0.64rem !important;
    letter-spacing: 0.05em !important;
    margin-bottom: 0.15rem !important;
  }

  .cell-portal-hero h2 {
    font-size: clamp(1.15rem, 4.6vw, 1.4rem) !important;
    margin-bottom: 0.15rem !important;
    line-height: 1.2 !important;
  }

  .cell-portal-hero p {
    font-size: 0.76rem !important;
    margin-bottom: 0.35rem !important;
  }

  .cell-portal-identity {
    padding: 0.2rem 0.5rem !important;
    font-size: 0.72rem !important;
    border-radius: 8px !important;
    gap: 0.35rem !important;
  }

  .cell-portal-hero-actions {
    margin-top: 0.35rem !important;
    gap: 0.4rem !important;
  }

  .cell-portal-hero-actions .btn {
    min-height: 36px !important;
    padding: 0.35rem 0.75rem !important;
    font-size: 0.8rem !important;
    border-radius: 10px !important;
  }

  .cell-portal-section {
    margin-bottom: 1.15rem !important;
  }

  .cell-portal-section-title {
    margin-bottom: 0.55rem !important;
    gap: 0.5rem !important;
  }

  .cell-portal-section-title i {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    font-size: 1rem !important;
    border-radius: 8px !important;
  }

  .cell-portal-section-title h3 {
    font-size: 0.96rem !important;
    margin: 0 !important;
  }

  .cell-portal-section-title p {
    font-size: 0.72rem !important;
    margin: 0 !important;
  }

  .cell-portal-kpis {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 0.45rem !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
  }

  .cell-portal-kpis article {
    padding: 0.55rem 0.65rem !important;
    min-height: 60px !important;
    border-radius: 10px !important;
    gap: 0.15rem 0.45rem !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }

  .cell-portal-kpis article > i {
    font-size: 1rem !important;
    margin-bottom: 0 !important;
    width: 32px !important;
    height: 32px !important;
    border-radius: 8px !important;
  }

  .cell-portal-kpis article span {
    font-size: 0.62rem !important;
    letter-spacing: 0.02em !important;
    line-height: 1.15 !important;
    min-width: 0 !important;
    word-break: break-word !important;
    overflow-wrap: anywhere !important;
  }

  .cell-portal-kpis article strong {
    font-size: clamp(0.92rem, 3.2vw, 1.1rem) !important;
    line-height: 1.15 !important;
    min-width: 0 !important;
    word-break: break-word !important;
    overflow-wrap: anywhere !important;
  }

  .cell-portal-meta {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 0.45rem !important;
    margin-top: 0.55rem !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
  }

  .cell-portal-meta div {
    padding: 0.55rem 0.65rem !important;
    border-radius: 8px !important;
    min-width: 0 !important;
    box-sizing: border-box !important;
    overflow: hidden !important;
  }

  .cell-portal-meta span {
    font-size: 0.66rem !important;
    min-width: 0 !important;
    overflow-wrap: anywhere !important;
  }

  .cell-portal-meta strong {
    font-size: 0.8rem !important;
    margin-top: 0.1rem !important;
    min-width: 0 !important;
    overflow-wrap: anywhere !important;
  }

  /* Compact Topbar for Small Devices */
  .topbar-row-primary {
    gap: 0.35rem !important;
  }

  .topbar-left {
    gap: 0.45rem !important;
  }

  .topbar-left #menuToggle {
    width: 38px !important;
    height: 38px !important;
    min-width: 38px !important;
    font-size: 1.15rem !important;
    border-radius: 10px !important;
  }

  .topbar-right .icon-btn,
  .topbar-right .universal-search-btn {
    width: 38px !important;
    height: 38px !important;
    min-width: 38px !important;
    font-size: 1rem !important;
    border-radius: 10px !important;
  }

  .topbar-title-wrap h1 {
    font-size: clamp(0.78rem, 3.4vw, 0.95rem) !important;
  }

  .topbar-title-wrap .eyebrow {
    font-size: 0.6rem !important;
  }

  .topbar-row-secondary {
    gap: 0.35rem !important;
  }

  .topbar-row-secondary #manualRefreshBtn {
    width: 38px !important;
    height: 38px !important;
    min-width: 38px !important;
    font-size: 1.05rem !important;
    border-radius: 10px !important;
  }

  .topbar-row-secondary .dash-lang-switch,
  .topbar-row-secondary .dash-theme-switch {
    height: 38px !important;
    border-radius: 10px !important;
    padding: 2px 3px !important;
  }

  .topbar-row-secondary .dash-lang-switch button,
  .topbar-row-secondary .dash-theme-switch .theme-toggle-btn {
    font-size: 0.78rem !important;
    padding: 0.25rem 0.45rem !important;
    border-radius: 8px !important;
  }

  .topbar-site-btn,
  .topbar-logout-btn {
    height: 38px !important;
    font-size: 0.8rem !important;
    border-radius: 10px !important;
    padding: 0 0.45rem !important;
  }
}

/* ============================================================================
   ALEC REPORTS & ANALYTICS LUXURY THEME
   ============================================================================ */

.alec-analytical-view {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.alec-module-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  background: rgba(7, 19, 38, 0.9);
  padding: 0.45rem;
  border-radius: 12px;
  border: 1px solid rgba(34, 211, 238, 0.2);
  box-shadow: 0 4px 20px rgba(2, 8, 23, 0.3);
}

.alec-subnav-pill,
.alec-module-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1.1rem;
  font-size: 0.85rem;
  font-weight: 700;
  border-radius: 9px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.03);
  color: #94a3b8;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
}

.alec-subnav-pill:hover,
.alec-module-pill-btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.15);
}

.alec-subnav-pill.active,
.alec-module-pill-btn.active {
  background: linear-gradient(135deg, #f5c755, #d97706) !important;
  color: #040e1e !important;
  border-color: #f5c755 !important;
  font-weight: 800;
  box-shadow: 0 4px 16px rgba(245, 199, 85, 0.35);
}

/* Filter Card */
.alec-filter-card {
  background: linear-gradient(145deg, rgba(11, 27, 51, 0.95), rgba(7, 19, 38, 0.95));
  border: 1px solid rgba(245, 199, 85, 0.25);
  border-radius: 16px;
  padding: 1.25rem;
  box-shadow: 0 10px 30px rgba(2, 8, 23, 0.35);
}

.alec-filter-label {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #f5c755;
  margin-bottom: 0.35rem;
}

.alec-select,
.alec-input {
  background: rgba(3, 10, 24, 0.85) !important;
  color: #f8fafc !important;
  border: 1px solid rgba(148, 163, 184, 0.25) !important;
  border-radius: 8px !important;
  font-size: 0.85rem !important;
  padding: 0.45rem 0.75rem !important;
  transition: all 0.2s ease;
}

.alec-select:focus,
.alec-input:focus {
  border-color: #f5c755 !important;
  box-shadow: 0 0 0 3px rgba(245, 199, 85, 0.2) !important;
  outline: none;
}

/* Executive KPI Grid */
.alec-kpis-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 0.85rem;
  margin-bottom: 1.25rem;
}

@media (max-width: 1400px) {
  .alec-kpis-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .alec-kpis-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 480px) {
  .alec-kpis-grid {
    grid-template-columns: 1fr;
  }
}

.alec-kpi-card {
  background: linear-gradient(145deg, rgba(11, 27, 51, 0.92), rgba(7, 19, 38, 0.92));
  border: 1px solid rgba(34, 211, 238, 0.16);
  border-radius: 16px;
  padding: 1.1rem 1rem;
  box-shadow: 0 8px 24px rgba(2, 8, 23, 0.25);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.alec-kpi-card:hover {
  transform: translateY(-2px);
  border-color: rgba(245, 199, 85, 0.4);
}

.alec-kpi-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-bottom: 0.4rem;
}

.alec-kpi-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  font-size: 1.15rem;
}

.alec-kpi-label {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #94a3b8;
}

.alec-kpi-val {
  font-size: 1.7rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.1;
  margin: 0.25rem 0;
}

.alec-kpi-sub {
  font-size: 0.74rem;
  font-weight: 600;
  color: #94a3b8;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Funnel Card */
.alec-funnel-card {
  background: linear-gradient(145deg, rgba(14, 31, 58, 0.95), rgba(7, 19, 38, 0.95));
  border: 1px solid rgba(34, 211, 238, 0.25);
  border-radius: 18px;
  padding: 1.4rem;
  box-shadow: 0 12px 36px rgba(2, 8, 23, 0.35);
  margin-bottom: 1.25rem;
}

.alec-funnel-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.85rem;
  margin-top: 1rem;
}

@media (max-width: 1100px) {
  .alec-funnel-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 650px) {
  .alec-funnel-grid {
    grid-template-columns: 1fr;
  }
}

.alec-funnel-box {
  background: rgba(3, 10, 24, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  padding: 1.1rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 0.75rem;
  transition: border-color 0.2s;
}

.alec-funnel-box:hover {
  border-color: rgba(245, 199, 85, 0.3);
}

.alec-funnel-box-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.alec-funnel-box-title {
  color: #cbd5e1;
  font-size: 0.78rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.alec-funnel-box-badge {
  font-size: 0.72rem;
  font-weight: 800;
  padding: 0.15rem 0.45rem;
  border-radius: 99px;
}

.alec-funnel-box-num {
  font-size: 1.75rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1;
}

.alec-funnel-box-bar {
  height: 7px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.alec-funnel-box-fill {
  height: 100%;
  border-radius: 99px;
  transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Data Tables Panel */
.alec-data-panel {
  background: linear-gradient(145deg, rgba(11, 27, 51, 0.95), rgba(7, 19, 38, 0.95));
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 18px;
  padding: 1.4rem;
  box-shadow: 0 12px 36px rgba(2, 8, 23, 0.35);
  margin-bottom: 1.5rem;
}

.alec-subtab-nav {
  display: flex;
  gap: 0.45rem;
  flex-wrap: wrap;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding-bottom: 1rem;
  margin-bottom: 1.25rem;
}

.alec-subtab-btn {
  background: rgba(255, 255, 255, 0.03);
  color: #94a3b8;
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 0.5rem 1rem;
  border-radius: 10px;
  font-weight: 700;
  font-size: 0.84rem;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.alec-subtab-btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.18);
}

.alec-subtab-btn.active {
  background: #2563eb !important;
  color: #ffffff !important;
  border-color: #38bdf8 !important;
  font-weight: 800;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.4);
}

.alec-custom-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  color: #f1f5f9;
}

.alec-custom-table thead th {
  background: #08162b;
  color: #f5c755;
  font-size: 0.74rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.85rem 1rem;
  border-bottom: 2px solid rgba(245, 199, 85, 0.3);
  white-space: nowrap;
}

.alec-custom-table tbody tr {
  transition: background 0.15s ease;
}

.alec-custom-table tbody tr:nth-child(even) {
  background: rgba(255, 255, 255, 0.02);
}

.alec-custom-table tbody tr:hover {
  background: rgba(34, 211, 238, 0.08) !important;
}

.alec-custom-table tbody td {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  color: #e2e8f0;
  font-size: 0.88rem;
  vertical-align: middle;
}

/* Orientation buttons */
.alec-orientation-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.85rem;
  font-size: 0.82rem;
  font-weight: 700;
  border-radius: 8px;
  border: 1px solid rgba(148, 163, 184, 0.25);
  background: rgba(3, 10, 24, 0.8);
  color: #cbd5e1;
  cursor: pointer;
  transition: all 0.2s ease;
}

.alec-orientation-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
}

.alec-orientation-btn.active {
  background: #0284c7 !important;
  color: #ffffff !important;
  border-color: #38bdf8 !important;
  box-shadow: 0 2px 10px rgba(2, 132, 199, 0.35);
}

/* Print CSS */
@media print {
  body {
    background: #ffffff !important;
    color: #000000 !important;
    font-size: 11pt !important;
  }
  .sidebar, .topbar, .dash-quick-toast, .view-toggle, .alec-module-pills, .alec-filter-card, .action-cluster, .btn, .alec-subtab-nav {
    display: none !important;
  }
  .alec-data-panel, .alec-funnel-card {
    background: #ffffff !important;
    border: 1px solid #cccccc !important;
    box-shadow: none !important;
    color: #000000 !important;
  }
  .alec-custom-table thead th {
    background: #0f274a !important;
    color: #ffffff !important;
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
  }
  .alec-custom-table tbody td {
    color: #000000 !important;
    border-bottom: 1px solid #dddddd !important;
  }
}

/* ============================================================
   Staff Biometric Attendance Module — Scoped Dark Theme Styling
   Low-contrast translucent slate styling matching Dashboard attendance
   ============================================================ */

.attendance-module-root {
  display: block;
  width: 100%;
  color: #ffffff !important;
}

.attendance-module-root .att-nav-pills {
  display: flex !important;
  flex-wrap: wrap !important;
  gap: 6px !important;
  padding: 6px !important;
  background: rgba(255, 255, 255, 0.02) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: 12px !important;
  box-shadow: none !important;
  list-style: none !important;
  margin-bottom: 1.25rem !important;
}

.attendance-module-root .att-nav-link {
  border: 1px solid transparent !important;
  border-radius: 8px !important;
  padding: 6px 14px !important;
  font-weight: 600 !important;
  font-size: 0.82rem !important;
  color: #94a3b8 !important;
  background: transparent !important;
  transition: all 0.2s ease !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 7px !important;
  cursor: pointer !important;
  text-decoration: none !important;
}

.attendance-module-root .att-nav-link:hover {
  color: #e2e8f0 !important;
  background: rgba(255, 255, 255, 0.05) !important;
  border-color: rgba(255, 255, 255, 0.12) !important;
}

.attendance-module-root .att-nav-link.active {
  background: rgba(234, 179, 8, 0.14) !important;
  color: #facc15 !important;
  font-weight: 600 !important;
  border: 1px solid rgba(234, 179, 8, 0.3) !important;
  box-shadow: none !important;
}

.attendance-module-root .att-kpi-card {
  display: flex !important;
  flex-direction: column !important;
  justify-content: center !important;
  align-items: center !important;
  text-align: center !important;
  gap: 4px !important;
  height: 100% !important;
  padding: 14px 12px !important;
  border-radius: 10px !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  background: rgba(255, 255, 255, 0.03) !important;
  box-shadow: none !important;
  color: #ffffff !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
}

.attendance-module-root .att-kpi-card:hover {
  transform: translateY(-2px) !important;
  background: rgba(255, 255, 255, 0.06) !important;
  border-color: rgba(255, 255, 255, 0.18) !important;
  box-shadow: none !important;
}

.attendance-module-root .att-kpi-card.is-active {
  border: 1px solid rgba(234, 179, 8, 0.4) !important;
  background: rgba(234, 179, 8, 0.08) !important;
  box-shadow: none !important;
}

.attendance-module-root .att-kpi-header {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: 100% !important;
  margin-bottom: 2px !important;
}

.attendance-module-root .att-kpi-icon {
  display: none !important;
}

.attendance-module-root .att-kpi-body {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  text-align: center !important;
  width: 100% !important;
  min-width: 0 !important;
}

.attendance-module-root .att-kpi-label {
  font-size: 0.72rem !important;
  font-weight: 600 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.04em !important;
  color: #94a3b8 !important;
  line-height: 1.2 !important;
  margin-bottom: 4px !important;
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
}

.attendance-module-root .att-kpi-value {
  font-size: 1.55rem !important;
  font-weight: 700 !important;
  line-height: 1.1 !important;
  color: #ffffff !important;
  font-family: var(--font-ui, 'Segoe UI', system-ui) !important;
}

.attendance-module-root .att-kpi-delta {
  font-size: 0.68rem !important;
  font-weight: 600 !important;
  border-radius: 12px !important;
  padding: 2px 8px !important;
  width: fit-content !important;
}

.attendance-module-root .card,
.attendance-module-root .att-card {
  background: rgba(255, 255, 255, 0.025) !important;
  --bs-card-bg: rgba(255, 255, 255, 0.025) !important;
  --bs-card-color: #e2e8f0 !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: 12px !important;
  color: #e2e8f0 !important;
  box-shadow: none !important;
}

.attendance-module-root .att-card-header {
  background: rgba(255, 255, 255, 0.02) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
  padding: 12px 18px !important;
}

.attendance-module-root .table,
.attendance-module-root .att-table {
  --bs-table-bg: transparent !important;
  --bs-table-color: #cbd5e1 !important;
  --bs-table-hover-bg: rgba(56, 189, 248, 0.04) !important;
  --bs-table-hover-color: #e2e8f0 !important;
  --bs-table-striped-bg: transparent !important;
  background-color: transparent !important;
  color: #cbd5e1 !important;
  margin-bottom: 0 !important;
  border-collapse: separate !important;
  border-spacing: 0 !important;
}

.attendance-module-root table > :not(caption) > * > *,
.attendance-module-root .att-table > :not(caption) > * > * {
  background-color: transparent !important;
  box-shadow: none !important;
}

.attendance-module-root .att-table thead th {
  background: #0f192b !important;
  color: #94a3b8 !important;
  font-size: 0.72rem !important;
  font-weight: 600 !important;
  text-transform: uppercase !important;
  letter-spacing: 0.05em !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
  padding: 11px 14px !important;
}

.attendance-module-root .att-table tbody tr {
  background: transparent !important;
  transition: background 0.15s ease !important;
}

.attendance-module-root .att-table tbody tr:hover {
  background: rgba(56, 189, 248, 0.04) !important;
}

.attendance-module-root .att-table tbody td {
  background: transparent !important;
  color: #cbd5e1 !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
  padding: 10px 14px !important;
  vertical-align: middle !important;
}

.attendance-module-root .att-avatar {
  width: 32px !important;
  height: 32px !important;
  border-radius: 50% !important;
  background: rgba(56, 189, 248, 0.08) !important;
  border: 1px solid rgba(56, 189, 248, 0.22) !important;
  color: #7dd3fc !important;
  font-weight: 600 !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 0.8rem !important;
  flex-shrink: 0 !important;
  box-shadow: none !important;
}

.attendance-module-root .att-filter-btn {
  border-radius: 20px !important;
  font-size: 0.76rem !important;
  font-weight: 600 !important;
  padding: 4px 12px !important;
  transition: all 0.15s ease !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  background: rgba(255, 255, 255, 0.03) !important;
  color: #94a3b8 !important;
}

.attendance-module-root .att-filter-btn:hover {
  background: rgba(255, 255, 255, 0.07) !important;
  color: #e2e8f0 !important;
  border-color: rgba(255, 255, 255, 0.18) !important;
}

.attendance-module-root .att-filter-btn.active {
  background: rgba(234, 179, 8, 0.14) !important;
  color: #facc15 !important;
  border-color: rgba(234, 179, 8, 0.35) !important;
  font-weight: 600 !important;
  box-shadow: none !important;
}

.attendance-module-root input.form-control,
.attendance-module-root select.form-select {
  background-color: rgba(255, 255, 255, 0.04) !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  color: #e2e8f0 !important;
}

.attendance-module-root input.form-control:focus,
.attendance-module-root select.form-select:focus {
  background-color: #0c1f40 !important;
  border-color: rgba(234, 179, 8, 0.5) !important;
  box-shadow: 0 0 0 3px rgba(234, 179, 8, 0.18) !important;
  color: #ffffff !important;
}

.attendance-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 0.85rem;
  margin-bottom: 1.25rem;
}

@media (max-width: 575.98px) {
  .attendance-kpi-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.65rem;
  }
}

/* ============================================================
   LIGHT THEME (MODO CLARO) STYLES
   Sidebar stays dark navy; topbar, content, panels, tables,
   cards & inputs become clean white with crisp dark text.
   ============================================================ */

[data-theme="light"],
.theme-light {
  --bg-main: #f8fafc;
  --bg-panel: #ffffff;
  --bg-panel-soft: #f1f5f9;
  --card-light: #ffffff;
  --card-light-2: #f8fafc;
  --card-dark: #ffffff;
  --card-dark-2: #f8fafc;
  --card-glass: rgba(255, 255, 255, 0.9);
  --border-cyan: rgba(14, 165, 233, 0.35);
  --border-gold: rgba(202, 138, 4, 0.45);
  --text-main: #0f172a;
  --text-muted: #64748b;
  --text-dark: #0f172a;
  --text-dark-muted: #64748b;
  --text-strong: #020817;
  --ink: #0f172a;
  --muted: #64748b;
}

[data-theme="light"] .ops-main,
.theme-light .ops-main {
  background: #f8fafc !important;
  color: #0f172a !important;
}

[data-theme="light"] .ops-topbar,
.theme-light .ops-topbar {
  background: #ffffff !important;
  border-bottom: 1px solid #e2e8f0 !important;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.06) !important;
}

[data-theme="light"] .ops-topbar h1,
[data-theme="light"] #pageTitle,
.theme-light .ops-topbar h1,
.theme-light #pageTitle {
  color: #0f172a !important;
}

[data-theme="light"] #sectionLabel,
[data-theme="light"] .topbar-breadcrumbs,
.theme-light #sectionLabel,
.theme-light .topbar-breadcrumbs {
  color: #64748b !important;
}

[data-theme="light"] .universal-search-btn,
.theme-light .universal-search-btn {
  background: #f1f5f9 !important;
  border-color: #cbd5e1 !important;
  color: #334155 !important;
}

[data-theme="light"] .universal-search-btn:hover,
.theme-light .universal-search-btn:hover {
  background: #e2e8f0 !important;
  border-color: #94a3b8 !important;
  color: #0f172a !important;
}

[data-theme="light"] .universal-search-btn kbd,
.theme-light .universal-search-btn kbd {
  background: #e2e8f0 !important;
  color: #475569 !important;
  border: 1px solid #cbd5e1 !important;
}

[data-theme="light"] .icon-btn,
[data-theme="light"] .refresh-btn,
[data-theme="light"] .notification-bell,
.theme-light .icon-btn,
.theme-light .refresh-btn,
.theme-light .notification-bell {
  background: #f1f5f9 !important;
  border-color: #cbd5e1 !important;
  color: #334155 !important;
}

[data-theme="light"] .icon-btn:hover,
.theme-light .icon-btn:hover {
  background: #e2e8f0 !important;
  color: #0f172a !important;
}

[data-theme="light"] .topbar-site-btn,
.theme-light .topbar-site-btn {
  background: #f8fafc !important;
  border-color: #cbd5e1 !important;
  color: #1e293b !important;
}

[data-theme="light"] .dash-lang-switch,
[data-theme="light"] .dash-theme-switch,
.theme-light .dash-lang-switch,
.theme-light .dash-theme-switch {
  background: #f1f5f9 !important;
  border-color: #cbd5e1 !important;
}

[data-theme="light"] .dash-lang-switch button,
[data-theme="light"] .dash-theme-switch .theme-toggle-btn,
.theme-light .dash-lang-switch button,
.theme-light .dash-theme-switch .theme-toggle-btn {
  color: #475569 !important;
}

[data-theme="light"] .dash-lang-switch button.active,
[data-theme="light"] .dash-theme-switch .theme-toggle-btn.active,
.theme-light .dash-lang-switch button.active,
.theme-light .dash-theme-switch .theme-toggle-btn.active {
  background: linear-gradient(135deg, #f59e0b, #d97706) !important;
  color: #ffffff !important;
  box-shadow: 0 2px 6px rgba(217, 119, 6, 0.3) !important;
}

[data-theme="light"] .ops-content,
.theme-light .ops-content {
  background: #f8fafc !important;
  color: #0f172a !important;
}

/* Light Theme Content Panels & Cards */
[data-theme="light"] .panel,
[data-theme="light"] .glass-panel,
[data-theme="light"] .summary-card,
[data-theme="light"] .metric-card,
[data-theme="light"] .ui-table-card,
[data-theme="light"] .dept-card,
[data-theme="light"] .cell-portal-kpis article,
[data-theme="light"] .cell-portal-alerts article,
.theme-light .panel,
.theme-light .glass-panel,
.theme-light .summary-card,
.theme-light .metric-card,
.theme-light .ui-table-card,
.theme-light .dept-card,
.theme-light .cell-portal-kpis article,
.theme-light .cell-portal-alerts article {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  color: #0f172a !important;
  box-shadow: 0 1px 6px rgba(15, 23, 42, 0.05) !important;
}

[data-theme="light"] .cell-portal-hero,
.theme-light .cell-portal-hero {
  background: linear-gradient(135deg, #f8fafc, #edf2f7) !important;
  border: 1px solid #cbd5e1 !important;
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.06) !important;
}

[data-theme="light"] .cell-portal-hero h2,
.theme-light .cell-portal-hero h2 {
  color: #0f172a !important;
}

[data-theme="light"] .cell-portal-hero p,
.theme-light .cell-portal-hero p {
  color: #475569 !important;
}

[data-theme="light"] .cell-portal-nav,
.theme-light .cell-portal-nav {
  background: #ffffff !important;
  border-color: #e2e8f0 !important;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.06) !important;
}

[data-theme="light"] .cell-portal-nav button,
.theme-light .cell-portal-nav button {
  background: #f1f5f9 !important;
  color: #334155 !important;
}

[data-theme="light"] .cell-portal-nav button:hover,
.theme-light .cell-portal-nav button:hover {
  background: #0ea5e9 !important;
  color: #ffffff !important;
}

[data-theme="light"] .cell-portal-meta div,
.theme-light .cell-portal-meta div {
  background: #f8fafc !important;
  border-left: 3px solid #0ea5e9 !important;
  border: 1px solid #e2e8f0 !important;
  border-left-width: 3px !important;
}

[data-theme="light"] .cell-portal-meta strong,
.theme-light .cell-portal-meta strong {
  color: #0f172a !important;
}

[data-theme="light"] .cell-portal-kpis article strong,
.theme-light .cell-portal-kpis article strong {
  color: #0f172a !important;
}

[data-theme="light"] .cell-portal-kpis article span,
.theme-light .cell-portal-kpis article span {
  color: #64748b !important;
}

[data-theme="light"] .panel-head,
[data-theme="light"] .card-header,
.theme-light .panel-head,
.theme-light .card-header {
  border-bottom: 1px solid #e2e8f0 !important;
}

[data-theme="light"] .ops-main h1,
[data-theme="light"] .ops-main h2,
[data-theme="light"] .ops-main h3,
[data-theme="light"] .ops-main h4,
[data-theme="light"] .ops-main h5,
[data-theme="light"] .ops-main h6,
[data-theme="light"] #appView h1,
[data-theme="light"] #appView h2,
[data-theme="light"] #appView h3,
[data-theme="light"] #appView h4,
[data-theme="light"] #appView h5,
[data-theme="light"] #appView h6,
.theme-light .ops-main h1,
.theme-light .ops-main h2,
.theme-light .ops-main h3,
.theme-light .ops-main h4,
.theme-light .ops-main h5,
.theme-light .ops-main h6,
.theme-light #appView h1,
.theme-light #appView h2,
.theme-light #appView h3,
.theme-light #appView h4,
.theme-light #appView h5,
.theme-light #appView h6 {
  color: #0f172a !important;
}

[data-theme="light"] .ops-main .text-secondary,
[data-theme="light"] .ops-main .meta-text,
[data-theme="light"] .ops-main .text-muted,
[data-theme="light"] #appView .text-secondary,
[data-theme="light"] #appView .meta-text,
[data-theme="light"] #appView .text-muted,
.theme-light .ops-main .text-secondary,
.theme-light .ops-main .meta-text,
.theme-light .ops-main .text-muted,
.theme-light #appView .text-secondary,
.theme-light #appView .meta-text,
.theme-light #appView .text-muted {
  color: #64748b !important;
}

/* Light Theme Tables */
[data-theme="light"] .ops-main .table,
[data-theme="light"] .ops-main table,
.theme-light .ops-main .table,
.theme-light .ops-main table {
  --bs-table-bg: transparent !important;
  --bs-table-color: #0f172a !important;
  color: #0f172a !important;
}

[data-theme="light"] .ops-main thead th,
[data-theme="light"] .ops-main .table thead th,
.theme-light .ops-main thead th,
.theme-light .ops-main .table thead th {
  background: #f8fafc !important;
  color: #475569 !important;
  border-bottom: 2px solid #e2e8f0 !important;
  font-weight: 700 !important;
}

[data-theme="light"] .ops-main tbody tr td,
[data-theme="light"] .ops-main .table tbody tr td,
.theme-light .ops-main tbody tr td,
.theme-light .ops-main .table tbody tr td {
  background: #ffffff !important;
  color: #1e293b !important;
  border-bottom: 1px solid #f1f5f9 !important;
}

[data-theme="light"] .ops-main tbody tr:hover td,
[data-theme="light"] .ops-main .table tbody tr:hover td,
.theme-light .ops-main tbody tr:hover td,
.theme-light .ops-main .table tbody tr:hover td {
  background: #f8fafc !important;
}

/* Light Theme Form Controls — Scoped strictly to dashboard main app and modals */
[data-theme="light"] .ops-main .form-control,
[data-theme="light"] .ops-main .form-select,
[data-theme="light"] .ops-main input[type="text"],
[data-theme="light"] .ops-main input[type="search"],
[data-theme="light"] .ops-main input[type="date"],
[data-theme="light"] .ops-main select,
[data-theme="light"] .ops-modal .form-control,
[data-theme="light"] .ops-modal .form-select,
[data-theme="light"] .modal-content .form-control,
[data-theme="light"] .modal-content .form-select,
.theme-light .ops-main .form-control,
.theme-light .ops-main .form-select,
.theme-light .ops-main input[type="text"],
.theme-light .ops-main input[type="search"],
.theme-light .ops-main input[type="date"],
.theme-light .ops-main select,
.theme-light .ops-modal .form-control,
.theme-light .ops-modal .form-select,
.theme-light .modal-content .form-control,
.theme-light .modal-content .form-select {
  background-color: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
  color: #0f172a !important;
}

[data-theme="light"] .ops-main .form-control:focus,
[data-theme="light"] .ops-main .form-select:focus,
[data-theme="light"] .ops-modal .form-control:focus,
[data-theme="light"] .ops-modal .form-select:focus,
.theme-light .ops-main .form-control:focus,
.theme-light .ops-main .form-select:focus,
.theme-light .ops-modal .form-control:focus,
.theme-light .ops-modal .form-select:focus {
  border-color: #2563eb !important;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15) !important;
  background-color: #ffffff !important;
  color: #0f172a !important;
}

[data-theme="light"] .ops-main .input-group-text,
.theme-light .ops-main .input-group-text {
  background: #f1f5f9 !important;
  border: 1px solid #cbd5e1 !important;
  color: #64748b !important;
}

/* Light Theme Buttons */
[data-theme="light"] .btn-outline-secondary,
[data-theme="light"] .btn-outline-light,
.theme-light .btn-outline-secondary,
.theme-light .btn-outline-light {
  background: #ffffff !important;
  border-color: #cbd5e1 !important;
  color: #334155 !important;
}

[data-theme="light"] .btn-outline-secondary:hover,
[data-theme="light"] .btn-outline-light:hover,
.theme-light .btn-outline-secondary:hover,
.theme-light .btn-outline-light:hover {
  background: #f1f5f9 !important;
  border-color: #94a3b8 !important;
  color: #0f172a !important;
}

/* Light Theme Modals & Drawers */
[data-theme="light"] .modal-content,
[data-theme="light"] .church-modal,
[data-theme="light"] .church-drawer,
[data-theme="light"] .notification-panel,
.theme-light .modal-content,
.theme-light .church-modal,
.theme-light .church-drawer,
.theme-light .notification-panel {
  background: #ffffff !important;
  color: #0f172a !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 10px 40px rgba(15, 23, 42, 0.15) !important;
}

[data-theme="light"] .modal-header,
[data-theme="light"] .church-drawer-head,
[data-theme="light"] .notification-panel-head,
.theme-light .modal-header,
.theme-light .church-drawer-head,
.theme-light .notification-panel-head {
  background: #f8fafc !important;
  border-bottom: 1px solid #e2e8f0 !important;
}

[data-theme="light"] .modal-footer,
.theme-light .modal-footer {
  background: #f8fafc !important;
  border-top: 1px solid #e2e8f0 !important;
}

/* Light Theme Attendance Module Specifics */
[data-theme="light"] .attendance-module-root,
.theme-light .attendance-module-root {
  color: #0f172a !important;
}

[data-theme="light"] .attendance-module-root .att-nav-pills,
.theme-light .attendance-module-root .att-nav-pills {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04) !important;
}

[data-theme="light"] .attendance-module-root .att-nav-link,
.theme-light .attendance-module-root .att-nav-link {
  color: #64748b !important;
}

[data-theme="light"] .attendance-module-root .att-nav-link:hover,
.theme-light .attendance-module-root .att-nav-link:hover {
  color: #0f172a !important;
  background: #f1f5f9 !important;
  border-color: #cbd5e1 !important;
}

[data-theme="light"] .attendance-module-root .att-nav-link.active,
.theme-light .attendance-module-root .att-nav-link.active {
  background: #0f172a !important;
  color: #ffffff !important;
  border-color: #0f172a !important;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.2) !important;
}

[data-theme="light"] .attendance-module-root .att-kpi-card,
.theme-light .attendance-module-root .att-kpi-card {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04) !important;
  color: #0f172a !important;
}

[data-theme="light"] .attendance-module-root .att-kpi-card:hover,
.theme-light .attendance-module-root .att-kpi-card:hover {
  border-color: #cbd5e1 !important;
  box-shadow: 0 6px 16px rgba(15, 23, 42, 0.08) !important;
}

[data-theme="light"] .attendance-module-root .att-kpi-card.is-active,
.theme-light .attendance-module-root .att-kpi-card.is-active {
  border: 2px solid #0f172a !important;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.12) !important;
  background: #f8fafc !important;
}

[data-theme="light"] .attendance-module-root .att-kpi-label,
.theme-light .attendance-module-root .att-kpi-label {
  color: #64748b !important;
}

[data-theme="light"] .attendance-module-root .att-kpi-value,
.theme-light .attendance-module-root .att-kpi-value {
  color: #0f172a !important;
}

[data-theme="light"] .attendance-module-root .card,
[data-theme="light"] .attendance-module-root .att-card,
.theme-light .attendance-module-root .card,
.theme-light .attendance-module-root .att-card {
  background: #ffffff !important;
  --bs-card-bg: #ffffff !important;
  --bs-card-color: #0f172a !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04) !important;
  color: #0f172a !important;
}

[data-theme="light"] .attendance-module-root .att-card-header,
.theme-light .attendance-module-root .att-card-header {
  background: #f8fafc !important;
  border-bottom: 1px solid #e2e8f0 !important;
}

[data-theme="light"] .attendance-module-root .att-table thead th,
.theme-light .attendance-module-root .att-table thead th {
  background: #f8fafc !important;
  color: #475569 !important;
  border-bottom: 2px solid #e2e8f0 !important;
}

[data-theme="light"] .attendance-module-root .att-table tbody tr,
.theme-light .attendance-module-root .att-table tbody tr {
  background: transparent !important;
}

[data-theme="light"] .attendance-module-root .att-table tbody tr:hover,
.theme-light .attendance-module-root .att-table tbody tr:hover {
  background: #f8fafc !important;
}

[data-theme="light"] .attendance-module-root .att-table tbody td,
.theme-light .attendance-module-root .att-table tbody td {
  color: #0f172a !important;
  border-bottom: 1px solid #f1f5f9 !important;
}

[data-theme="light"] .attendance-module-root .att-filter-btn,
.theme-light .attendance-module-root .att-filter-btn {
  border: 1px solid #cbd5e1 !important;
  background: #f8fafc !important;
  color: #475569 !important;
}

[data-theme="light"] .attendance-module-root .att-filter-btn:hover,
.theme-light .attendance-module-root .att-filter-btn:hover {
  background: #f1f5f9 !important;
  color: #0f172a !important;
}

[data-theme="light"] .attendance-module-root .att-filter-btn.active,
.theme-light .attendance-module-root .att-filter-btn.active {
  background: #0f172a !important;
  color: #ffffff !important;
  border-color: #0f172a !important;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.15) !important;
}

[data-theme="light"] .attendance-module-root input.form-control,
[data-theme="light"] .attendance-module-root select.form-select,
.theme-light .attendance-module-root input.form-control,
.theme-light .attendance-module-root select.form-select {
  background-color: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
  color: #0f172a !important;
}

[data-theme="light"] .attendance-module-root input.form-control:focus,
[data-theme="light"] .attendance-module-root select.form-select:focus,
.theme-light .attendance-module-root input.form-control:focus,
.theme-light .attendance-module-root select.form-select:focus {
  background-color: #ffffff !important;
  border-color: #2563eb !important;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15) !important;
  color: #0f172a !important;
}

/* ============================================================
   Light Theme Comprehensive System Overrides
   ============================================================ */

/* High-Specificity Surfaces, Panels & Cards in Light Mode */
[data-theme="light"] #content .glass-panel,
[data-theme="light"] #content .panel,
[data-theme="light"] #content .chart-card,
[data-theme="light"] #content .metric-card,
[data-theme="light"] #content .summary-card,
[data-theme="light"] #content .record-card,
[data-theme="light"] #content .data-card,
[data-theme="light"] #content .module-hero-card,
[data-theme="light"] #content .data-table-wrap,
[data-theme="light"] #content .filter-toolbar,
[data-theme="light"] #content .churches-toolbar,
[data-theme="light"] #content .churches-filter-grid,
[data-theme="light"] #content .kpi-card,
[data-theme="light"] .dashboard-section,
[data-theme="light"] .module-section,
[data-theme="light"] .module-hero-card,
[data-theme="light"] .data-card,
[data-theme="light"] .church-card,
[data-theme="light"] .kanban-column,
[data-theme="light"] .alec-filter-card,
[data-theme="light"] .chart-card,
[data-theme="light"] .record-card,
[data-theme="light"] .filter-toolbar,
[data-theme="light"] .churches-toolbar,
[data-theme="light"] .churches-filter-grid,
[data-theme="light"] .dashboard-overview-label,
[data-theme="light"] .light-surface,
[data-theme="light"] .surface-light,
[data-theme="light"] .kpi-card,
.theme-light #content .glass-panel,
.theme-light #content .panel,
.theme-light #content .chart-card,
.theme-light #content .metric-card,
.theme-light #content .summary-card,
.theme-light #content .record-card,
.theme-light #content .data-card,
.theme-light #content .module-hero-card,
.theme-light #content .data-table-wrap,
.theme-light #content .filter-toolbar,
.theme-light #content .churches-toolbar,
.theme-light #content .churches-filter-grid,
.theme-light #content .kpi-card,
.theme-light .dashboard-section,
.theme-light .module-section,
.theme-light .module-hero-card,
.theme-light .data-card,
.theme-light .church-card,
.theme-light .kanban-column,
.theme-light .alec-filter-card,
.theme-light .chart-card,
.theme-light .record-card,
.theme-light .filter-toolbar,
.theme-light .churches-toolbar,
.theme-light .churches-filter-grid,
.theme-light .dashboard-overview-label,
.theme-light .light-surface,
.theme-light .surface-light,
.theme-light .kpi-card {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  color: #0f172a !important;
  box-shadow: 0 1px 6px rgba(15, 23, 42, 0.05) !important;
}

/* Light Mode Hero Wrappers & Header Banners */
[data-theme="light"] .module-nav-panel,
[data-theme="light"] .module-nav-shell,
[data-theme="light"] .ops-hero,
[data-theme="light"] .ops-hero--command,
[data-theme="light"] .ops-hero--welcome-line,
[data-theme="light"] section.ops-hero,
[data-theme="light"] .section-panel,
.theme-light .module-nav-panel,
.theme-light .module-nav-shell,
.theme-light .ops-hero,
.theme-light .ops-hero--command,
.theme-light .ops-hero--welcome-line,
.theme-light section.ops-hero,
.theme-light .section-panel {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  color: #0f172a !important;
  box-shadow: 0 2px 10px rgba(15, 23, 42, 0.05) !important;
}

[data-theme="light"] .ops-hero h2,
[data-theme="light"] .ops-hero.ops-hero--command h2,
[data-theme="light"] .ops-hero--welcome-line h2,
.theme-light .ops-hero h2,
.theme-light .ops-hero.ops-hero--command h2,
.theme-light .ops-hero--welcome-line h2 {
  color: #0f172a !important;
  text-shadow: none !important;
}

[data-theme="light"] .ops-hero p,
[data-theme="light"] .ops-hero.ops-hero--command p,
.theme-light .ops-hero p,
.theme-light .ops-hero.ops-hero--command p {
  color: #64748b !important;
}

[data-theme="light"] .ops-hero .eyebrow,
[data-theme="light"] .ops-hero.ops-hero--command .eyebrow,
.theme-light .ops-hero .eyebrow,
.theme-light .ops-hero.ops-hero--command .eyebrow {
  color: #d97706 !important;
}

/* Module Nav Tabs Container at the bottom of hero */
[data-theme="light"] .module-nav-panel .department-tabs,
[data-theme="light"] .module-nav-panel .tab-strip.module-tab-strip,
[data-theme="light"] .module-nav-panel .module-tabs,
.theme-light .module-nav-panel .department-tabs,
.theme-light .module-nav-panel .tab-strip.module-tab-strip,
.theme-light .module-nav-panel .module-tabs {
  background: #f8fafc !important;
  border: 1px solid #e2e8f0 !important;
  border-top: 1px solid #e2e8f0 !important;
}

[data-theme="light"] .module-nav-panel .department-tabs button,
[data-theme="light"] .module-nav-panel .tab-strip.module-tab-strip button,
.theme-light .module-nav-panel .department-tabs button,
.theme-light .module-nav-panel .tab-strip.module-tab-strip button {
  background: #ffffff !important;
  color: #475569 !important;
  border: 1px solid #cbd5e1 !important;
}

[data-theme="light"] .module-nav-panel .department-tabs button.active,
[data-theme="light"] .module-nav-panel .tab-strip.module-tab-strip button.active,
.theme-light .module-nav-panel .department-tabs button.active,
.theme-light .module-nav-panel .tab-strip.module-tab-strip button.active {
  background: #0f172a !important;
  color: #ffffff !important;
  border-color: #0f172a !important;
}

/* ALEC Subnavigation Pills & Module Tabs */
[data-theme="light"] .alec-module-pills,
[data-theme="light"] .alec-filter-card,
[data-theme="light"] .alec-subtab-nav,
[data-theme="light"] .alec-data-panel,
.theme-light .alec-module-pills,
.theme-light .alec-filter-card,
.theme-light .alec-subtab-nav,
.theme-light .alec-data-panel {
  background: #f1f5f9 !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04) !important;
}

[data-theme="light"] .alec-subnav-pill,
[data-theme="light"] .alec-module-pill-btn,
.theme-light .alec-subnav-pill,
.theme-light .alec-module-pill-btn {
  background: #ffffff !important;
  color: #475569 !important;
  border: 1px solid #cbd5e1 !important;
}

[data-theme="light"] .alec-subnav-pill:hover,
[data-theme="light"] .alec-module-pill-btn:hover,
.theme-light .alec-subnav-pill:hover,
.theme-light .alec-module-pill-btn:hover {
  background: #e2e8f0 !important;
  color: #0f172a !important;
}

[data-theme="light"] .alec-subnav-pill.active,
[data-theme="light"] .alec-module-pill-btn.active,
.theme-light .alec-subnav-pill.active,
.theme-light .alec-module-pill-btn.active {
  background: linear-gradient(135deg, #f59e0b, #d97706) !important;
  color: #ffffff !important;
  border-color: #d97706 !important;
  font-weight: 800 !important;
  box-shadow: 0 2px 8px rgba(217, 119, 6, 0.25) !important;
}

/* Light Theme High-Specificity Form Controls & Inputs */
[data-theme="light"] #content .form-control,
[data-theme="light"] #content .form-select,
[data-theme="light"] .filter-toolbar .form-control,
[data-theme="light"] .filter-toolbar .form-select,
[data-theme="light"] .filter-bar .form-control,
[data-theme="light"] .filter-bar .form-select,
[data-theme="light"] .churches-filter-grid .form-control,
[data-theme="light"] .churches-filter-grid .form-select,
[data-theme="light"] .finance-report-filters .form-control,
[data-theme="light"] .finance-report-filters .form-select,
[data-theme="light"] select,
[data-theme="light"] input:not([type="radio"]):not([type="checkbox"]):not([type="submit"]):not([type="button"]),
[data-theme="light"] .form-select,
[data-theme="light"] .form-control,
.theme-light #content .form-control,
.theme-light #content .form-select,
.theme-light .filter-toolbar .form-control,
.theme-light .filter-toolbar .form-select,
.theme-light .filter-bar .form-control,
.theme-light .filter-bar .form-select,
.theme-light .churches-filter-grid .form-control,
.theme-light .churches-filter-grid .form-select,
.theme-light .finance-report-filters .form-control,
.theme-light .finance-report-filters .form-select,
.theme-light select,
.theme-light input:not([type="radio"]):not([type="checkbox"]):not([type="submit"]):not([type="button"]),
.theme-light .form-select,
.theme-light .form-control {
  background-color: #ffffff !important;
  color: #0f172a !important;
  border: 1px solid #cbd5e1 !important;
}

[data-theme="light"] #content .form-control:focus,
[data-theme="light"] #content .form-select:focus,
[data-theme="light"] .filter-toolbar .form-control:focus,
[data-theme="light"] .filter-toolbar .form-select:focus,
[data-theme="light"] .filter-bar .form-control:focus,
[data-theme="light"] .filter-bar .form-select:focus,
.theme-light #content .form-control:focus,
.theme-light #content .form-select:focus,
.theme-light .filter-toolbar .form-control:focus,
.theme-light .filter-toolbar .form-select:focus,
.theme-light .filter-bar .form-control:focus,
.theme-light .filter-bar .form-select:focus {
  border-color: #2563eb !important;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15) !important;
  background-color: #ffffff !important;
  color: #0f172a !important;
}

[data-theme="light"] select option,
.theme-light select option {
  background-color: #ffffff !important;
  color: #0f172a !important;
}

[data-theme="light"] #content .form-control::placeholder,
[data-theme="light"] .filter-toolbar .form-control::placeholder,
[data-theme="light"] .filter-bar .form-control::placeholder,
.theme-light #content .form-control::placeholder,
.theme-light .filter-toolbar .form-control::placeholder,
.theme-light .filter-bar .form-control::placeholder {
  color: #94a3b8 !important;
  opacity: 1 !important;
}

/* Light Theme Gold, Cyan, and Action Buttons */
[data-theme="light"] .btn-ce-gold,
[data-theme="light"] .btn-gold,
.theme-light .btn-ce-gold,
.theme-light .btn-gold {
  background: linear-gradient(135deg, #f59e0b, #d97706) !important;
  color: #ffffff !important;
  border: 1px solid #d97706 !important;
  font-weight: 700 !important;
  box-shadow: 0 2px 8px rgba(217, 119, 6, 0.25) !important;
  text-shadow: none !important;
}

[data-theme="light"] .btn-ce-gold:hover,
[data-theme="light"] .btn-gold:hover,
.theme-light .btn-ce-gold:hover,
.theme-light .btn-gold:hover {
  background: linear-gradient(135deg, #d97706, #b45309) !important;
  color: #ffffff !important;
  border-color: #b45309 !important;
}

[data-theme="light"] .btn-outline-cyan,
.theme-light .btn-outline-cyan {
  background: #f0f9ff !important;
  border: 1px solid #0284c7 !important;
  color: #0284c7 !important;
  font-weight: 600 !important;
}

[data-theme="light"] .btn-outline-cyan:hover,
.theme-light .btn-outline-cyan:hover {
  background: #0284c7 !important;
  color: #ffffff !important;
  border-color: #0284c7 !important;
}

[data-theme="light"] .btn-outline-primary,
.theme-light .btn-outline-primary {
  background: #ffffff !important;
  border: 1px solid #2563eb !important;
  color: #2563eb !important;
}

[data-theme="light"] .btn-outline-primary:hover,
.theme-light .btn-outline-primary:hover {
  background: #2563eb !important;
  color: #ffffff !important;
}

[data-theme="light"] .btn-primary,
.theme-light .btn-primary {
  background: #2563eb !important;
  border-color: #2563eb !important;
  color: #ffffff !important;
}

/* Light Theme View Toggle (Table / Card) */
[data-theme="light"] .view-toggle,
.theme-light .view-toggle {
  background: #f1f5f9 !important;
  border: 1px solid #cbd5e1 !important;
}

[data-theme="light"] .view-toggle-btn,
.theme-light .view-toggle-btn {
  background: transparent !important;
  color: #64748b !important;
}

[data-theme="light"] .view-toggle-btn.active,
.theme-light .view-toggle-btn.active {
  background: #0f172a !important;
  color: #ffffff !important;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.2) !important;
}

/* Light Theme Titles, Headings and Values */
[data-theme="light"] .dashboard-section-title,
[data-theme="light"] .module-section-title,
[data-theme="light"] .module-hero-card-title,
[data-theme="light"] .panel-title,
[data-theme="light"] .card-title,
[data-theme="light"] .data-card-title,
[data-theme="light"] .summary-card-value,
[data-theme="light"] .metric-value,
[data-theme="light"] .chart-value,
[data-theme="light"] .finance-chart-value,
[data-theme="light"] .finance-hbar-value,
[data-theme="light"] .church-card h3,
[data-theme="light"] .church-card.light-surface h3,
[data-theme="light"] #content .summary-card-value,
[data-theme="light"] #content .metric-card strong,
[data-theme="light"] #content .chart-card .finance-hbar-value,
[data-theme="light"] #content .chart-card .finance-chart-value,
[data-theme="light"] #content .chart-card .chart-row strong,
[data-theme="light"] .church-card-meta strong,
[data-theme="light"] .data-card-meta strong,
[data-theme="light"] .data-card-meta-row strong,
[data-theme="light"] .data-table-mobile-row strong,
[data-theme="light"] .data-table-mobile-row div,
[data-theme="light"] .record-card-meta strong,
[data-theme="light"] .record-card strong,
[data-theme="light"] .data-card strong,
[data-theme="light"] .church-card strong,
[data-theme="light"] #content .church-card-meta strong,
[data-theme="light"] #content .data-card-meta strong,
[data-theme="light"] #content .data-card-meta-row strong,
[data-theme="light"] #content .data-card strong,
[data-theme="light"] #content .church-card strong,
.theme-light .dashboard-section-title,
.theme-light .module-section-title,
.theme-light .module-hero-card-title,
.theme-light .panel-title,
.theme-light .card-title,
.theme-light .data-card-title,
.theme-light .summary-card-value,
.theme-light .metric-value,
.theme-light .chart-value,
.theme-light .finance-chart-value,
.theme-light .finance-hbar-value,
.theme-light .church-card h3,
.theme-light .church-card.light-surface h3,
.theme-light #content .summary-card-value,
.theme-light #content .metric-card strong,
.theme-light #content .chart-card .finance-hbar-value,
.theme-light #content .chart-card .finance-chart-value,
.theme-light #content .chart-card .chart-row strong,
.theme-light .church-card-meta strong,
.theme-light .data-card-meta strong,
.theme-light .data-card-meta-row strong,
.theme-light .data-table-mobile-row strong,
.theme-light .data-table-mobile-row div,
.theme-light .record-card-meta strong,
.theme-light .record-card strong,
.theme-light .data-card strong,
.theme-light .church-card strong,
.theme-light #content .church-card-meta strong,
.theme-light #content .data-card-meta strong,
.theme-light #content .data-card-meta-row strong,
.theme-light #content .data-card strong,
.theme-light #content .church-card strong {
  color: #0f172a !important;
}

/* Light Theme Subtitles, Labels, Muted Text */
[data-theme="light"] .dashboard-section-subtitle,
[data-theme="light"] .module-section-subtitle,
[data-theme="light"] .module-hero-card-subtitle,
[data-theme="light"] .summary-card-label,
[data-theme="light"] .metric-label,
[data-theme="light"] .chart-label,
[data-theme="light"] .muted,
[data-theme="light"] .subtitle,
[data-theme="light"] .meta-text,
[data-theme="light"] .card-subtitle,
[data-theme="light"] .text-secondary,
[data-theme="light"] .text-muted,
[data-theme="light"] .summary-card-hint,
[data-theme="light"] .finance-chart-label,
[data-theme="light"] .finance-hbar-label,
[data-theme="light"] .finance-donut-legend-label,
[data-theme="light"] #content .summary-card-label,
[data-theme="light"] #content .metric-card span,
[data-theme="light"] #content .summary-card-hint,
[data-theme="light"] #content .metric-card small,
[data-theme="light"] #content .chart-card .finance-hbar-label,
[data-theme="light"] #content .chart-card .finance-chart-label,
[data-theme="light"] #content .chart-card .chart-row span,
[data-theme="light"] .church-card-meta span,
[data-theme="light"] .data-card-meta span,
[data-theme="light"] .data-card-meta-row span,
[data-theme="light"] .data-table-mobile-row span,
[data-theme="light"] .church-card-public,
[data-theme="light"] #content .church-card-meta span,
[data-theme="light"] #content .data-card-meta span,
[data-theme="light"] #content .data-card-meta-row span,
.theme-light .dashboard-section-subtitle,
.theme-light .module-section-subtitle,
.theme-light .module-hero-card-subtitle,
.theme-light .summary-card-label,
.theme-light .metric-label,
.theme-light .chart-label,
.theme-light .muted,
.theme-light .subtitle,
.theme-light .meta-text,
.theme-light .card-subtitle,
.theme-light .text-secondary,
.theme-light .text-muted,
.theme-light .summary-card-hint,
.theme-light .finance-chart-label,
.theme-light .finance-hbar-label,
.theme-light .finance-donut-legend-label,
.theme-light #content .summary-card-label,
.theme-light #content .metric-card span,
.theme-light #content .summary-card-hint,
.theme-light #content .metric-card small,
.theme-light #content .chart-card .finance-hbar-label,
.theme-light #content .chart-card .finance-chart-label,
.theme-light #content .chart-card .chart-row span,
.theme-light .church-card-meta span,
.theme-light .data-card-meta span,
.theme-light .data-card-meta-row span,
.theme-light .data-table-mobile-row span,
.theme-light .church-card-public,
.theme-light #content .church-card-meta span,
.theme-light #content .data-card-meta span,
.theme-light #content .data-card-meta-row span {
  color: #475569 !important;
}

[data-theme="light"] .church-card-meta span i,
[data-theme="light"] .data-card-meta-row i,
.theme-light .church-card-meta span i,
.theme-light .data-card-meta-row i {
  color: #0284c7 !important;
}

[data-theme="light"] .church-service-chip,
.theme-light .church-service-chip {
  background: #e0f2fe !important;
  color: #0369a1 !important;
  border: 1px solid #bae6fd !important;
}

[data-theme="light"] .data-card-pill,
.theme-light .data-card-pill {
  background: #f1f5f9 !important;
  color: #334155 !important;
  border: 1px solid #cbd5e1 !important;
}

/* Light Theme Tab Strips */
[data-theme="light"] .tab-strip button,
[data-theme="light"] .nav-tabs button,
[data-theme="light"] .view-toggle button,
[data-theme="light"] .member-subtabs button,
.theme-light .tab-strip button,
.theme-light .nav-tabs button,
.theme-light .view-toggle button,
.theme-light .member-subtabs button {
  background: #f1f5f9 !important;
  color: #475569 !important;
  border: 1px solid #cbd5e1 !important;
}

[data-theme="light"] .tab-strip button.active,
[data-theme="light"] .tab-strip button.is-active,
[data-theme="light"] .nav-tabs button.active,
[data-theme="light"] .view-toggle button.active,
[data-theme="light"] .member-subtabs button.active,
.theme-light .tab-strip button.active,
.theme-light .tab-strip button.is-active,
.theme-light .nav-tabs button.active,
.theme-light .view-toggle button.active,
.theme-light .member-subtabs button.active {
  background: #0f172a !important;
  color: #ffffff !important;
  border-color: #0f172a !important;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.15) !important;
}

/* Action Buttons */
[data-theme="light"] .action-btn,
.theme-light .action-btn {
  background: #f8fafc !important;
  border: 1px solid #cbd5e1 !important;
  color: #334155 !important;
  border-radius: 6px !important;
}

[data-theme="light"] .action-btn:hover,
.theme-light .action-btn:hover {
  background: #e2e8f0 !important;
  color: #0f172a !important;
}

[data-theme="light"] .action-btn.text-warning,
[data-theme="light"] .action-btn--edit,
.theme-light .action-btn.text-warning,
.theme-light .action-btn--edit {
  color: #b45309 !important;
  border-color: #fcd34d !important;
  background: #fffbeb !important;
}

[data-theme="light"] .action-btn.text-success,
[data-theme="light"] .action-btn--success,
[data-theme="light"] .action-btn--approve,
.theme-light .action-btn.text-success,
.theme-light .action-btn--success,
.theme-light .action-btn--approve {
  color: #15803d !important;
  border-color: #86efac !important;
  background: #f0fdf4 !important;
}

[data-theme="light"] .action-btn.text-danger,
[data-theme="light"] .action-btn--danger,
[data-theme="light"] .action-btn--reject,
.theme-light .action-btn.text-danger,
.theme-light .action-btn--danger,
.theme-light .action-btn--reject {
  color: #b91c1c !important;
  border-color: #fca5a5 !important;
  background: #fef2f2 !important;
}

[data-theme="light"] .candidate-merge-btn,
.theme-light .candidate-merge-btn {
  color: #b45309 !important;
  border-color: #f59e0b !important;
  background: #fffbeb !important;
}

/* ALEC Report Table in Light Mode */
[data-theme="light"] .alec-report-table-wrap,
.theme-light .alec-report-table-wrap {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
}

[data-theme="light"] .alec-report-table thead th,
.theme-light .alec-report-table thead th {
  background: #f8fafc !important;
  color: #1e293b !important;
  border-bottom: 2px solid #cbd5e1 !important;
}

[data-theme="light"] .alec-report-table tbody td,
.theme-light .alec-report-table tbody td {
  color: #1e293b !important;
  border-bottom: 1px solid #f1f5f9 !important;
}

[data-theme="light"] .alec-report-table tbody tr:nth-child(even),
.theme-light .alec-report-table tbody tr:nth-child(even) {
  background: #f8fafc !important;
}

[data-theme="light"] .alec-report-table tfoot td,
.theme-light .alec-report-table tfoot td {
  background: #f1f5f9 !important;
  color: #0f172a !important;
  border-top: 2px solid #cbd5e1 !important;
}

[data-theme="light"] .alec-report-total-cell,
.theme-light .alec-report-total-cell {
  background: #fef3c7 !important;
  color: #92400e !important;
}

/* Charts & Donut Holes */
[data-theme="light"] .finance-donut-hole,
.theme-light .finance-donut-hole,
[data-theme="light"] .cell-portal-donut::after,
.theme-light .cell-portal-donut::after {
  background: #ffffff !important;
}

[data-theme="light"] .finance-donut-hole strong,
.theme-light .finance-donut-hole strong {
  color: #0f172a !important;
}

[data-theme="light"] .finance-hbar-track,
.theme-light .finance-hbar-track {
  background: #e2e8f0 !important;
}

/* Candidate Merge button base dark theme styling */
.candidate-merge-btn {
  color: #fcd34d !important;
  border-color: rgba(245, 158, 11, 0.45) !important;
  background: rgba(245, 158, 11, 0.12) !important;
}

.candidate-merge-btn:hover {
  background: rgba(245, 158, 11, 0.25) !important;
  color: #ffffff !important;
}

/* ============================================================
   Login Page Immunity & Absolute Protection
   Preserves the original dark glass login page styling identically
   under all conditions and theme modes.
   ============================================================ */
#loginView,
.login-shell {
  background-color: #060e1a !important;
  color: #ffffff !important;
}

#loginView .login-panel,
.login-shell .login-panel {
  background: #0f1c2e !important;
  border: 1px solid rgba(255, 255, 255, 0.14) !important;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(255, 255, 255, 0.04) !important;
  color: #ffffff !important;
}

#loginView .login-title,
.login-shell .login-title,
#loginView h1,
.login-shell h1 {
  color: #ffffff !important;
  font-family: var(--font-primary) !important;
  font-size: 2.35rem !important;
  font-weight: 800 !important;
}

#loginView .login-subtitle,
.login-shell .login-subtitle {
  color: rgba(255, 255, 255, 0.65) !important;
  font-size: 0.92rem !important;
}

#loginView .login-gold-bar,
.login-shell .login-gold-bar {
  background: #e5b342 !important;
}

#loginView .form-label,
.login-shell .form-label {
  color: #ffffff !important;
  font-size: 0.88rem !important;
  font-weight: 600 !important;
}

#loginView .form-control,
.login-shell .form-control,
#loginView input[type="text"],
#loginView input[type="password"],
.login-shell input[type="text"],
.login-shell input[type="password"] {
  background-color: #152238 !important;
  border: 1px solid #283e5e !important;
  border-radius: 10px !important;
  color: #ffffff !important;
  padding: 0.75rem 1rem !important;
  font-size: 0.95rem !important;
}

#loginView .form-control::placeholder,
.login-shell .form-control::placeholder {
  color: rgba(255, 255, 255, 0.35) !important;
  opacity: 1 !important;
}

#loginView .form-control:focus,
.login-shell .form-control:focus {
  border-color: #e5b342 !important;
  box-shadow: 0 0 0 3px rgba(229, 179, 66, 0.2) !important;
  background-color: #152238 !important;
  color: #ffffff !important;
  outline: none !important;
}

#loginView .login-submit-btn,
.login-shell .login-submit-btn {
  background: linear-gradient(135deg, #f7d070 0%, #e5b342 100%) !important;
  border: none !important;
  border-radius: 10px !important;
  color: #0a1424 !important;
  font-weight: 700 !important;
  box-shadow: 0 6px 20px rgba(229, 179, 66, 0.32) !important;
}

#loginView .login-submit-btn:hover,
.login-shell .login-submit-btn:hover {
  background: linear-gradient(135deg, #fae08f 0%, #f0c355 100%) !important;
  color: #050a12 !important;
}

#loginView .login-forgot-btn,
.login-shell .login-forgot-btn {
  color: #e5b342 !important;
}

#loginView .login-footer-note,
.login-shell .login-footer-note {
  color: rgba(255, 255, 255, 0.5) !important;
}

#loginView .dash-lang-switch,
.login-shell .dash-lang-switch {
  background: #15253b !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
}

#loginView .dash-lang-switch button,
.login-shell .dash-lang-switch button {
  background: transparent !important;
  color: rgba(255, 255, 255, 0.6) !important;
}

#loginView .dash-lang-switch button.active,
.login-shell .dash-lang-switch button.active {
  background: #e5b342 !important;
  color: #0a1424 !important;
}

/* ============================================================
   Attendance & Biometric Tracking: Workflow & Comparison Styles
   ============================================================ */
.bg-gold-subtle-10 {
  background: rgba(212, 175, 55, 0.08) !important;
}

.att-card {
  background: #0f192c;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

[data-theme="light"] .att-card,
.theme-light .att-card {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.06) !important;
  color: #0f172a !important;
}

[data-theme="light"] .att-card-header,
.theme-light .att-card-header {
  background: #f8fafc !important;
  border-bottom: 1px solid #e2e8f0 !important;
}

.att-table thead th {
  background: #111e36 !important;
  color: #94a3b8 !important;
  font-size: 0.72rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.04em !important;
  text-transform: uppercase !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
  padding: 0.65rem 0.75rem !important;
}

.att-table tbody td {
  color: #cbd5e1 !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05) !important;
  padding: 0.7rem 0.75rem !important;
  font-variant-numeric: tabular-nums;
}

.att-table tbody tr {
  transition: background 0.15s ease;
}

.att-table tbody tr:hover {
  background: rgba(56, 189, 248, 0.04) !important;
}

[data-theme="light"] .att-table thead th,
.theme-light .att-table thead th {
  background: #f1f5f9 !important;
  color: #475569 !important;
  border-bottom: 2px solid #cbd5e1 !important;
}

[data-theme="light"] .att-table tbody td,
.theme-light .att-table tbody td {
  color: #1e293b !important;
  border-bottom: 1px solid #f1f5f9 !important;
}

[data-theme="light"] .att-table tbody tr:hover,
.theme-light .att-table tbody tr:hover {
  background: #f8fafc !important;
}

.att-filter-btn {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #94a3b8;
  border-radius: 999px;
  padding: 3px 11px;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.att-filter-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.16);
  color: #e2e8f0;
}

.att-filter-btn.active {
  background: rgba(234, 179, 8, 0.14);
  border-color: rgba(234, 179, 8, 0.4);
  color: #facc15;
  font-weight: 600;
  box-shadow: none;
}

[data-theme="light"] .att-filter-btn,
.theme-light .att-filter-btn {
  background: #f1f5f9 !important;
  border: 1px solid #cbd5e1 !important;
  color: #475569 !important;
}

[data-theme="light"] .att-filter-btn.active,
.theme-light .att-filter-btn.active {
  background: #0f172a !important;
  color: #ffffff !important;
  border-color: #0f172a !important;
}

.att-nav-pills {
  display: flex;
  gap: 0.45rem;
  list-style: none;
  padding: 0.5rem;
  margin: 0;
  overflow-x: auto;
  border-radius: 14px;
  background: #0f192c;
  border: 1px solid rgba(255, 255, 255, 0.08);
  scrollbar-width: none;
}

.att-nav-pills::-webkit-scrollbar {
  display: none;
}

.att-nav-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.9rem;
  border: 1px solid transparent;
  border-radius: 9px;
  color: #94a3b8;
  background: transparent;
  font-size: 0.82rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.att-nav-link:hover {
  color: #e2e8f0;
  background: rgba(255, 255, 255, 0.05);
}

.att-nav-link.active {
  background: rgba(234, 179, 8, 0.14);
  border-color: rgba(234, 179, 8, 0.35);
  color: #facc15;
  font-weight: 600;
  box-shadow: none;
}

[data-theme="light"] .att-nav-pills,
.theme-light .att-nav-pills {
  background: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
}

[data-theme="light"] .att-nav-link,
.theme-light .att-nav-link {
  color: #475569 !important;
}

[data-theme="light"] .att-nav-link.active,
.theme-light .att-nav-link.active {
  background: #0f172a !important;
  color: #ffffff !important;
  border-color: #0f172a !important;
}

.att-row-late {
  background: rgba(248, 113, 113, 0.035) !important;
}

.main-att-executive-card {
  background: linear-gradient(145deg, #0e1a30, #0a1324) !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  border-radius: 18px !important;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.22) !important;
  margin-bottom: 2rem !important;
}

.att-card-clickable {
  cursor: pointer;
  transition: all 0.18s ease;
  background: rgba(255, 255, 255, 0.025) !important;
  border: 1px solid rgba(255, 255, 255, 0.06) !important;
  border-radius: 12px !important;
}

.att-card-clickable:hover {
  transform: translateY(-2px);
  border-color: rgba(234, 179, 8, 0.35) !important;
  background: rgba(255, 255, 255, 0.05) !important;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

[data-theme="light"] .main-att-executive-card,
.theme-light .main-att-executive-card {
  background: #ffffff !important;
  border: 1px solid #cbd5e1 !important;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.08) !important;
}

[data-theme="light"] .att-card-clickable,
.theme-light .att-card-clickable {
  background: #f8fafc !important;
  border-color: #e2e8f0 !important;
}

[data-theme="light"] .att-card-clickable:hover,
.theme-light .att-card-clickable:hover {
  background: #fef9c3 !important;
  border-color: #f59e0b !important;
}

/* Candidate & Action Cluster Buttons */
.candidate-actions-cluster {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  flex-wrap: nowrap;
}

.action-pill-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.28rem 0.65rem;
  min-height: 30px;
  height: 30px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.18s ease;
  border: 1px solid transparent;
  text-decoration: none;
  box-sizing: border-box;
}

.action-pill-btn:hover {
  transform: translateY(-1px);
}

.action-pill-btn--view {
  background: rgba(56, 189, 248, 0.1);
  border-color: rgba(56, 189, 248, 0.3);
  color: #38bdf8;
}

.action-pill-btn--view:hover {
  background: rgba(56, 189, 248, 0.22);
  border-color: rgba(56, 189, 248, 0.55);
  color: #ffffff;
}

.action-pill-btn--approve {
  background: linear-gradient(135deg, #10b981, #059669);
  border-color: rgba(16, 185, 129, 0.5);
  color: #ffffff;
  box-shadow: 0 2px 6px rgba(16, 185, 129, 0.25);
}

.action-pill-btn--approve:hover {
  background: linear-gradient(135deg, #34d399, #10b981);
  border-color: #34d399;
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

.action-pill-btn--submit {
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  border-color: rgba(59, 130, 246, 0.5);
  color: #ffffff;
  box-shadow: 0 2px 6px rgba(59, 130, 246, 0.25);
}

.action-pill-btn--submit:hover {
  background: linear-gradient(135deg, #60a5fa, #3b82f6);
  border-color: #60a5fa;
  color: #ffffff;
}

.action-pill-btn--more {
  background: rgba(148, 163, 184, 0.1);
  border-color: rgba(148, 163, 184, 0.22);
  color: #94a3b8;
  padding: 0.28rem 0.55rem;
}

.action-pill-btn--more:hover,
.action-pill-btn--more[aria-expanded="true"] {
  background: rgba(148, 163, 184, 0.25);
  border-color: rgba(148, 163, 184, 0.5);
  color: #ffffff;
}

/* Candidate Actions Dropdown Menu */
.candidate-actions-dropdown {
  background: #0f1c36 !important;
  border: 1px solid rgba(56, 189, 248, 0.22) !important;
  border-radius: 12px !important;
  box-shadow: 0 12px 32px rgba(2, 8, 23, 0.75) !important;
  padding: 0.35rem 0 !important;
  min-width: 200px !important;
  z-index: 1060 !important;
}

.candidate-actions-dropdown .dropdown-item {
  color: #cbd5e1 !important;
  font-size: 0.8rem !important;
  font-weight: 600 !important;
  padding: 0.45rem 0.9rem !important;
  background: transparent !important;
  border: 0;
  width: 100%;
  text-align: left;
  display: flex !important;
  align-items: center !important;
  gap: 0.5rem !important;
  transition: background 0.15s ease, color 0.15s ease;
}

.candidate-actions-dropdown .dropdown-item:hover,
.candidate-actions-dropdown .dropdown-item:focus {
  background: rgba(56, 189, 248, 0.15) !important;
  color: #ffffff !important;
}

.candidate-actions-dropdown .dropdown-item.text-danger {
  color: #f87171 !important;
}

.candidate-actions-dropdown .dropdown-item.text-danger:hover {
  background: rgba(239, 68, 68, 0.18) !important;
  color: #fca5a5 !important;
}

.candidate-actions-dropdown .dropdown-divider {
  border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
  margin: 0.35rem 0 !important;
}

/* Light theme overrides */
[data-theme="light"] .candidate-actions-dropdown,
.theme-light .candidate-actions-dropdown {
  background: #ffffff !important;
  border: 1px solid #e2e8f0 !important;
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.15) !important;
}

[data-theme="light"] .candidate-actions-dropdown .dropdown-item,
.theme-light .candidate-actions-dropdown .dropdown-item {
  color: #334155 !important;
}

[data-theme="light"] .candidate-actions-dropdown .dropdown-item:hover,
.theme-light .candidate-actions-dropdown .dropdown-item:hover {
  background: #f1f5f9 !important;
  color: #0f172a !important;
}

[data-theme="light"] .candidate-actions-dropdown .dropdown-divider,
.theme-light .candidate-actions-dropdown .dropdown-divider {
  border-top-color: #e2e8f0 !important;
}

[data-theme="light"] .action-pill-btn--view,
.theme-light .action-pill-btn--view {
  background: #e0f2fe;
  border-color: #bae6fd;
  color: #0284c7;
}

[data-theme="light"] .action-pill-btn--more,
.theme-light .action-pill-btn--more {
  background: #f1f5f9;
  border-color: #cbd5e1;
  color: #64748b;
}

/* ============================================================
   Universal Soft Badges & Tonal Utilities (Dark Slate Theme)
   ============================================================ */
.bg-gold-subtle {
  background-color: rgba(234, 179, 8, 0.12) !important;
  color: #facc15 !important;
  border: 1px solid rgba(234, 179, 8, 0.25) !important;
}

.bg-success-subtle {
  background-color: rgba(34, 197, 94, 0.12) !important;
  color: #4ade80 !important;
  border: 1px solid rgba(34, 197, 94, 0.25) !important;
}

.bg-warning-subtle {
  background-color: rgba(234, 179, 8, 0.12) !important;
  color: #facc15 !important;
  border: 1px solid rgba(234, 179, 8, 0.25) !important;
}

.bg-danger-subtle {
  background-color: rgba(239, 68, 68, 0.12) !important;
  color: #f87171 !important;
  border: 1px solid rgba(239, 68, 68, 0.25) !important;
}

.bg-info-subtle {
  background-color: rgba(56, 189, 248, 0.12) !important;
  color: #38bdf8 !important;
  border: 1px solid rgba(56, 189, 248, 0.25) !important;
}

.bg-primary-subtle {
  background-color: rgba(99, 102, 241, 0.12) !important;
  color: #818cf8 !important;
  border: 1px solid rgba(99, 102, 241, 0.25) !important;
}

.bg-secondary-subtle {
  background-color: rgba(148, 163, 184, 0.1) !important;
  color: #94a3b8 !important;
  border: 1px solid rgba(148, 163, 184, 0.2) !important;
}

.text-gold {
  color: #facc15 !important;
}

/* ============================================================
   Redesigned Main Executive Dashboard Styles (Mockup 2026)
   ============================================================ */
.dash-v2-container {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  width: 100%;
}

/* 1. Hero Welcome Banner */
.dash-hero-banner {
  position: relative;
  background: radial-gradient(circle at top right, rgba(30, 58, 138, 0.4) 0%, rgba(15, 23, 42, 0.95) 70%), linear-gradient(135deg, #0b1329 0%, #0f172a 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1.15rem;
  padding: 1.6rem 2rem;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
  overflow: hidden;
}

.dash-hero-banner::before {
  content: "";
  position: absolute;
  top: -50%;
  right: -20%;
  width: 380px;
  height: 380px;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.12) 0%, transparent 70%);
  pointer-events: none;
}

.dash-hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #facc15;
  background: rgba(234, 179, 8, 0.1);
  border: 1px solid rgba(234, 179, 8, 0.25);
  padding: 0.22rem 0.65rem;
  border-radius: 999px;
  margin-bottom: 0.6rem;
}

.dash-hero-title {
  font-size: 1.75rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #f8fafc;
  margin-bottom: 0.35rem;
}

.dash-hero-subtitle {
  font-size: 0.88rem;
  color: #94a3b8;
  margin-bottom: 0;
}

.dash-date-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #e2e8f0;
  padding: 0.45rem 0.95rem;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 500;
  backdrop-filter: blur(10px);
}

/* Sub-Navigation & Filter Bar */
.dash-subnav-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.45rem 0.65rem;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 0.85rem;
  margin-bottom: 1.35rem;
}

/* Dynamic Subtab View Container */
#dash-dynamic-subtab-view {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  width: 100%;
}

.dash-subnav-tabs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
}

.dash-subnav-btn {
  background: transparent;
  border: 1px solid transparent;
  color: #94a3b8;
  font-size: 0.82rem;
  font-weight: 600;
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  transition: all 0.2s ease;
  cursor: pointer;
}

.dash-subnav-btn:hover {
  color: #f1f5f9;
  background: rgba(255, 255, 255, 0.05);
}

.dash-subnav-btn.active {
  color: #0f172a;
  background: #facc15;
  font-weight: 700;
  box-shadow: 0 4px 14px rgba(234, 179, 8, 0.35);
}

.dash-period-select {
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #e2e8f0;
  font-size: 0.8rem;
  padding: 0.38rem 0.85rem;
  border-radius: 0.6rem;
  outline: none;
}

/* 2. Top KPI Metric Cards Grid (Single Row for 8 cards) */
.dash-kpi-grid {
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  gap: 0.55rem;
  margin-bottom: 0.5rem;
}

@media (max-width: 1200px) {
  .dash-kpi-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.6rem;
    margin-bottom: 0.5rem;
  }
}

@media (max-width: 640px) {
  .dash-kpi-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem;
  }
}

.dash-kpi-card {
  position: relative;
  background: linear-gradient(155deg, rgba(15, 23, 42, 0.9) 0%, rgba(30, 41, 59, 0.75) 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.85rem;
  padding: 0.85rem 0.75rem 0.75rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 98px;
  min-width: 0;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  cursor: pointer;
  overflow: hidden;
}

.dash-kpi-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
}

.dash-kpi-card:hover {
  transform: translateY(-3px);
  border-color: rgba(56, 189, 248, 0.4);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.35), 0 0 20px rgba(56, 189, 248, 0.12);
}

.dash-kpi-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.35rem;
  margin-bottom: 0.5rem;
}

.dash-kpi-label {
  font-size: 0.72rem;
  font-weight: 600;
  color: #94a3b8;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-icon-box {
  width: 28px;
  height: 28px;
  border-radius: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  flex-shrink: 0;
}

.dash-icon-box.blue {
  background: rgba(56, 189, 248, 0.15);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.3);
}

.dash-icon-box.rose {
  background: rgba(244, 63, 94, 0.15);
  color: #fb7185;
  border: 1px solid rgba(244, 63, 94, 0.3);
}

.dash-icon-box.cyan {
  background: rgba(6, 182, 212, 0.15);
  color: #22d3ee;
  border: 1px solid rgba(6, 182, 212, 0.3);
}

.dash-icon-box.amber {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.dash-icon-box.emerald {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.dash-icon-box.green {
  background: rgba(34, 197, 94, 0.15);
  color: #4ade80;
  border: 1px solid rgba(34, 197, 94, 0.3);
}

.dash-icon-box.sky {
  background: rgba(14, 165, 233, 0.15);
  color: #38bdf8;
  border: 1px solid rgba(14, 165, 233, 0.3);
}

.dash-icon-box.purple {
  background: rgba(168, 85, 247, 0.15);
  color: #c084fc;
  border: 1px solid rgba(168, 85, 247, 0.3);
}

.dash-kpi-value-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.35rem;
  margin-top: auto;
  min-width: 0;
}

.dash-kpi-value {
  font-size: 1.55rem;
  font-weight: 800;
  color: #f8fafc;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: -0.02em;
}

.dash-kpi-trend {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  font-size: 0.68rem;
  font-weight: 600;
  padding: 0.15rem 0.35rem;
  border-radius: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex-shrink: 0;
}

.dash-kpi-trend.positive {
  color: #34d399;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.2);
}

.dash-kpi-trend.negative {
  color: #f87171;
  background: rgba(239, 68, 68, 0.12);
  border: 1px solid rgba(239, 68, 68, 0.2);
}

.dash-kpi-trend.neutral {
  color: #94a3b8;
  background: rgba(148, 163, 184, 0.1);
  border: 1px solid rgba(148, 163, 184, 0.18);
}

.dash-kpi-sparkline {
  height: 24px;
  width: 58px;
}

/* 3. Analytical Charts Cards */
.dash-card {
  background: linear-gradient(145deg, rgba(15, 23, 42, 0.9) 0%, rgba(30, 41, 59, 0.8) 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 1.15rem;
  padding: 1.35rem 1.5rem;
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.28);
  height: 100%;
  display: flex;
  flex-direction: column;
}

.dash-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.dash-card-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #f8fafc;
  margin: 0;
}

.dash-legend-group {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.85rem;
  font-size: 0.76rem;
  color: #cbd5e1;
}

.dash-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.dash-legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

/* Financial Chart Container & Summary */
.dash-chart-flex {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 300px;
  justify-content: space-between;
}

.dash-chart-summary-bar {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin-top: 1rem;
  padding-top: 0.9rem;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.dash-chart-summary-item {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: 0.55rem;
  padding: 0.5rem 0.75rem;
  text-align: center;
}

.dash-chart-summary-label {
  font-size: 0.68rem;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-bottom: 0.15rem;
}

.dash-chart-summary-val {
  font-size: 0.92rem;
  font-weight: 700;
  color: #f8fafc;
}

/* Donut Chart and List Layout */
.dash-donut-wrap {
  position: relative;
  width: 160px;
  height: 160px;
  margin: 0.25rem auto 1rem;
}

.dash-donut-center {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  pointer-events: none;
}

.dash-donut-center-val {
  font-size: 1.45rem;
  font-weight: 800;
  color: #f8fafc;
  line-height: 1;
}

.dash-donut-center-lbl {
  font-size: 0.68rem;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.dash-church-list {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  width: 100%;
  max-height: 250px;
  overflow-y: auto;
  padding-right: 4px;
}

.dash-church-list::-webkit-scrollbar {
  width: 4px;
}

.dash-church-list::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.02);
}

.dash-church-list::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.15);
  border-radius: 4px;
}

.dash-church-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.42rem 0.65rem;
  border-radius: 0.45rem;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.04);
  font-size: 0.78rem;
  transition: background 0.15s ease;
}

.dash-church-row:hover {
  background: rgba(255, 255, 255, 0.06);
}

/* 4. Resumo por Departamento Mini-Cards */
.dash-dept-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 0.85rem;
}

@media (max-width: 1100px) {
  .dash-dept-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 640px) {
  .dash-dept-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.dash-dept-card {
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 0.85rem;
  padding: 1rem 0.85rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  transition: all 0.2s ease;
  cursor: pointer;
}

.dash-dept-card:hover {
  transform: translateY(-2px);
  border-color: rgba(56, 189, 248, 0.3);
  background: rgba(30, 41, 59, 0.85);
}

.dash-dept-name {
  font-size: 0.78rem;
  font-weight: 600;
  color: #cbd5e1;
}

.dash-dept-stat {
  font-size: 0.95rem;
  font-weight: 800;
  color: #f8fafc;
}

.dash-dept-tag {
  font-size: 0.65rem;
  color: #94a3b8;
  padding: 0.15rem 0.45rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
}

/* 5. Tasks and Events Items */
.dash-task-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 0.9rem;
  border-radius: 0.75rem;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.05);
  transition: background 0.18s ease;
}

.dash-task-item:hover {
  background: rgba(30, 41, 59, 0.7);
}

.dash-task-pill-btn {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #e2e8f0;
  text-decoration: none;
  white-space: nowrap;
}

.dash-task-pill-btn:hover {
  background: rgba(234, 179, 8, 0.15);
  border-color: rgba(234, 179, 8, 0.3);
  color: #facc15;
}

.dash-event-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 0.9rem;
  border-radius: 0.75rem;
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.dash-event-item:hover {
  background: rgba(30, 41, 59, 0.7);
}

.dash-event-badge {
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.22rem 0.55rem;
  border-radius: 0.4rem;
  background: rgba(56, 189, 248, 0.15);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.25);
  white-space: nowrap;
}

