/* ============================================================
   JUBILEU DA SANTÍSSIMA TRINDADE — Estilos principais
   ============================================================ */

/* ---- Variáveis ---- */
:root {
  --sidebar-width: 240px;
  --sidebar-bg: #1a1f2e;
  --sidebar-hover: rgba(255,255,255,0.08);
  --sidebar-active: rgba(13, 110, 253, 0.25);
  --topbar-h: 56px;
  --primary: #0d6efd;
}

/* ---- Reset base ---- */
body {
  font-family: 'Segoe UI', system-ui, sans-serif;
  background: #f1f4f9;
  min-height: 100vh;
}

/* ---- Sidebar ---- */
.sidebar {
  width: var(--sidebar-width);
  min-height: 100vh;
  background: var(--sidebar-bg);
  flex-shrink: 0;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}

.sidebar-header {
  background: rgba(0,0,0,0.2);
}

.sidebar-logo-area {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.sidebar-logo {
  max-height: 50px;
  max-width: 80px;
  object-fit: contain;
}

/* Menu links */
.sidebar-menu {
  width: 100%;
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #adb5bd;
  text-decoration: none;
  padding: 9px 14px;
  border-radius: 8px;
  font-size: 0.88rem;
  transition: all 0.2s;
  margin-bottom: 2px;
}

.sidebar-link:hover {
  color: #fff;
  background: var(--sidebar-hover);
}

.sidebar-link.active {
  color: #fff;
  background: var(--sidebar-active);
  font-weight: 600;
}

.sidebar-section {
  color: #6c757d !important;
  font-size: 0.7rem;
  letter-spacing: 0.06em;
}

/* ---- Topbar ---- */
.topbar {
  height: var(--topbar-h);
  position: sticky;
  top: 0;
  z-index: 100;
}

/* ---- Content ---- */
#wrapper {
  min-height: 100vh;
}

.content-wrapper {
  min-width: 0;
}

.page-content {
  min-height: calc(100vh - var(--topbar-h));
}

/* ---- Cards de Dashboard ---- */
.card-stat {
  border: none;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  transition: transform 0.2s, box-shadow 0.2s;
}

.card-stat:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0,0,0,0.1);
}

.card-stat .icon-box {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

/* ---- Tabelas ---- */
.table-responsive {
  border-radius: 10px;
  overflow: hidden;
}

.table thead th {
  background: #e9ecef;
  font-weight: 600;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-bottom: 2px solid #dee2e6;
  white-space: nowrap;
}

.table tbody tr:hover {
  background-color: rgba(13, 110, 253, 0.03);
}

/* ---- Botões de ação menores ---- */
.btn-action {
  padding: 3px 10px;
  font-size: 0.78rem;
}

/* ---- Formulários ---- */
.form-card {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  padding: 28px;
}

.form-label {
  font-weight: 500;
  font-size: 0.87rem;
}

/* ---- Badges extras ---- */
.badge {
  font-size: 0.75rem;
  padding: 0.35em 0.7em;
}

/* ---- Login page ---- */
.login-wrapper {
  min-height: 100vh;
  background: linear-gradient(135deg, #1a1f2e 0%, #0d6efd 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.login-card {
  background: #fff;
  border-radius: 16px;
  padding: 40px;
  width: 100%;
  max-width: 420px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.login-logo {
  max-height: 70px;
  max-width: 120px;
  object-fit: contain;
}

/* ---- Responsivo mobile ---- */
@media (max-width: 991.98px) {
  .sidebar {
    display: none !important;
  }
  .topbar {
    display: none !important;
  }
  .page-content {
    padding-top: 16px !important;
  }
}

/* ---- Scrollbar customizada ---- */
.sidebar::-webkit-scrollbar {
  width: 4px;
}
.sidebar::-webkit-scrollbar-track {
  background: transparent;
}
.sidebar::-webkit-scrollbar-thumb {
  background: rgba(255,255,255,0.15);
  border-radius: 4px;
}

/* ---- Print ---- */
@media print {
  .sidebar, .navbar, .topbar, .btn, .no-print { display: none !important; }
  .page-content { padding: 0 !important; }
}
