:root{
  --orange:#ff7a00;
  --orange-2:#ff8f2a;
  --orange-soft: rgba(255,122,0,.12);
  --text:#1f2937;
  --muted:#6b7280;
  --border:#e5e7eb;
  --bg:#f5f7fb;
}

* { font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif; }

body{
  background: var(--bg);
  color: var(--text);
}

.app-navbar .navbar-brand{
  gap: 12px;
}

.brand-wrap{
  min-height: 58px;
  text-decoration: none;
  min-width: 0;
}

.brand-logo-wrap{
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 58px;
  min-height: 58px;
  flex-shrink: 0;
}

.brand-copy{
  justify-content: center;
  min-width: 0;
}

.brand-logo-free{
  display: block;
  max-width: 180px;
  max-height: 56px;
  width: auto;
  height: auto;
  object-fit: contain;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.brand-mark{
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display:flex;
  align-items:center;
  justify-content:center;
  box-shadow: 0 8px 18px rgba(0,0,0,.10);
  background: linear-gradient(135deg, var(--orange), #ffb067);
  color: #111827;
  font-weight: 800;
  flex-shrink: 0;
}

.brand-title{
  font-weight: 800;
  letter-spacing: .5px;
  font-size: 13px;
  color: #111827;
}

.brand-subtitle{
  font-size: 11px;
  color: var(--muted);
  font-weight: 700;
}

@media (max-width: 768px){
  .brand-logo-free{
    max-width: 132px;
    max-height: 44px;
  }
}

.nav-link{
  font-weight: 700;
  color: #64748b;
  padding: 10px 10px;
  border-bottom: 3px solid transparent;
}

.nav-link.active{
  color: #111827;
  border-bottom-color: var(--orange);
}

.avatar{
  width: 32px;
  height: 32px;
  border-radius: 999px;
  background: #111827;
  color: #fff;
  display:flex;
  align-items:center;
  justify-content:center;
  font-weight: 800;
}

.page-title{
  font-size: 22px;
  font-weight: 900;
}

.card{
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: 0 8px 20px rgba(31,41,55,.06);
  background: #fff;
}

.kpi-card{
  padding: 18px 16px;
  min-height: 152px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 14px;
}

.kpi-content{
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
}

.kpi-icon{
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--orange-soft);
  display:flex;
  align-items:center;
  justify-content:center;
  font-size: 22px;
  flex-shrink: 0;
}

.kpi-label{
  color: var(--muted);
  font-weight: 700;
  font-size: 13px;
  line-height: 1.25;
  min-height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.kpi-value{
  font-size: 26px;
  font-weight: 900;
  line-height: 1.15;
  color: #111827;
  min-height: 40px;
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
  text-align: center;
}

.kpi-value-suffix{
  font-size: 18px;
  font-weight: 800;
  color: #111827;
}

.panel-card .panel-title{
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  font-weight: 900;
}

.table-custom thead th{
  font-size: 12px;
  color: #64748b;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .04em;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
}

.table-custom tbody td{
  padding: 14px 16px;
  border-bottom: 1px solid #eef2f7;
  vertical-align: middle;
}

.btn-orange{
  background: var(--orange);
  border: 1px solid var(--orange);
  color: #111827;
  font-weight: 900;
}

.btn-orange:hover{
  background: var(--orange-2);
  border-color: var(--orange-2);
  color:#111827;
}

.btn-outline-orange{
  border: 1px solid rgba(255,122,0,.35);
  color: #111827;
  font-weight: 900;
  background: #fff;
}

.btn-outline-orange:hover{
  background: var(--orange-soft);
  border-color: rgba(255,122,0,.55);
  color:#111827;
}

.text-orange{
  color: var(--orange) !important;
}

.legend-item{
  display:flex;
  align-items:center;
  gap:10px;
  padding: 10px 0;
  border-bottom: 1px solid #eef2f7;
  font-weight: 800;
  color: #111827;
}

.legend-item:last-child{
  border-bottom: none;
}

.dot{
  width: 10px;
  height: 10px;
  border-radius: 999px;
  display:inline-block;
}

.dot-orange{ background: var(--orange); }
.dot-yellow{ background: #fbbf24; }
.dot-gray{ background: #cbd5e1; }

.badge{
  font-weight: 900;
  border-radius: 999px;
  padding: 6px 10px;
}

.badge-soft-success{ background: rgba(16,185,129,.15); color:#065f46; }
.badge-soft-warning{ background: rgba(251,191,36,.20); color:#92400e; }
.badge-soft-muted{ background: rgba(148,163,184,.25); color:#334155; }

.alert-row{
  display:flex;
  align-items:center;
  gap:10px;
  padding: 12px;
  border: 1px solid #eef2f7;
  border-radius: 12px;
  background: #fff;
}

.alert-icon{
  font-size: 16px;
}

.move-row{
  border: 1px solid #eef2f7;
  border-radius: 12px;
  padding: 10px 12px;
}

.move-title{
  font-weight: 900;
}

.move-meta{
  font-size: 12px;
  color: #64748b;
  font-weight: 700;
}

.move-details{
  font-size: 13px;
}

.barcode-preview{
  max-width: 100%;
  border-radius: 12px;
  border: 1px solid #eef2f7;
  padding: 10px;
  background: #fff;
}

.progress{
  height: 10px;
  border-radius: 999px;
  background: #eef2f7;
}

.progress-bar{
  background: var(--orange);
  border-radius: 999px;
}

.report-link{
  display:block;
  padding: 10px 12px;
  border: 1px solid #eef2f7;
  border-radius: 12px;
  text-decoration:none;
  color:#111827;
  font-weight: 700;
}

.report-link:hover{
  background: var(--orange-soft);
}

.form-control:focus,
.form-select:focus{
  border-color: rgba(255,122,0,.55);
  box-shadow: 0 0 0 .25rem rgba(255,122,0,.12);
}

.selector-wrap{
  max-width: 1100px;
  padding-top: 48px;
}

.selector-eyebrow{
  display: inline-flex;
  background: var(--orange-soft);
  color: var(--orange);
  padding: 8px 14px;
  border-radius: 999px;
  font-weight: 800;
  margin-bottom: 14px;
}

.selector-title{
  font-size: 34px;
  font-weight: 900;
}

.selector-subtitle{
  color: var(--muted);
  max-width: 760px;
  margin: 0 auto;
}

.church-card{
  width: 100%;
  text-align: left;
  border: 1px solid var(--border);
  border-radius: 22px;
  background: #fff;
  padding: 24px;
  transition: .2s ease;
  box-shadow: 0 12px 28px rgba(31,41,55,.08);
}

.church-card:hover{
  transform: translateY(-2px);
  box-shadow: 0 18px 36px rgba(31,41,55,.12);
  border-color: rgba(255,122,0,.35);
}

.church-card-top{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.church-card-brand{
  display: flex;
  align-items: center;
  justify-content: flex-start;
  min-height: 72px;
  max-width: calc(100% - 110px);
}

.church-card-logo-img,
.church-preview-logo{
  display: block;
  max-width: 220px;
  max-height: 90px;
  width: auto;
  height: auto;
  object-fit: contain;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.church-card-logo-fallback{
  width: 68px;
  height: 68px;
  border-radius: 18px;
  display:flex;
  align-items:center;
  justify-content:center;
  font-weight: 900;
  font-size: 26px;
  background: linear-gradient(135deg, var(--orange), #ffb067);
  color: #111827;
  flex-shrink: 0;
}

.church-badge{
  background: var(--orange-soft);
  color: var(--orange);
  font-weight: 800;
  padding: 8px 14px;
  border-radius: 999px;
  flex-shrink: 0;
}

.church-card-title{
  font-size: 22px;
  font-weight: 900;
  margin-bottom: 8px;
}

.church-card-desc{
  color: var(--muted);
}

.asset-photo{
  width: 100%;
  max-height: 270px;
  object-fit: cover;
  border-radius: 14px;
  border: 1px solid #eef2f7;
}

.asset-photo-placeholder{
  min-height: 220px;
  border-radius: 14px;
  border: 1px dashed #d1d5db;
  background: #f8fafc;
  display:flex;
  align-items:center;
  justify-content:center;
  color: var(--muted);
  font-weight: 700;
}

.list-thumb{
  width: 46px;
  height: 46px;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid #eef2f7;
}

@media (max-width: 991.98px){
  .selector-title{
    font-size: 28px;
  }

  .church-card-logo-img,
  .church-preview-logo{
    max-width: 150px;
    max-height: 70px;
  }
}

.public-page{
  min-height: 100vh;
}

.flash-public{
  max-width: 520px;
}

.login-page{
  min-height: calc(100vh - 32px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 16px;
}

.login-shell{
  width: 100%;
  max-width: 520px;
}

.login-card{
  overflow: hidden;
}

.login-logo{
  display: block;
  max-width: 240px;
  max-height: 120px;
  width: auto;
  height: auto;
  object-fit: contain;
  margin-left: auto;
  margin-right: auto;
}

.login-logo-fallback{
  width: 84px;
  height: 84px;
  border-radius: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  font-size: 32px;
  background: linear-gradient(135deg, var(--orange), #ffb067);
  color: #111827;
}

.login-title{
  font-size: 30px;
}
