:root {
  --primary: #2E3D80;
  --secondary: #ED4D37;
  --dark-bg: #0f172a;
  --dark-card: #111827;
}

body {
  display: flex;
  min-height: 100vh;
  background: #f8fafc;
}

/* Sidebar */
.sidebar {
  width: 250px;
  background: var(--primary);
  color: white;
  position: fixed;
  height: 100%;
  display: flex;
  flex-direction: column;
  z-index: 1000;
  transition: transform .35s ease;
}

.sidebar-header {
  background: white;
  height: 70px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.sidebar-header img {
  width: 45px;
}

.sidebar-menu a {
  color: #e5e7eb;
  padding: 12px 20px;
  display: flex;
  gap: 10px;
  text-decoration: none;
  border-radius: 8px;
  margin: 4px 10px;
  transition: .3s;
}

.sidebar-menu a:hover,
.sidebar-menu a.active {
  background: var(--secondary);
  transform: translateX(5px);
}

.sidebar-footer {
  margin-top: auto;
  padding: 15px;
  display: flex;
  justify-content: space-around;
}

.sidebar-footer i {
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  transition: .3s;
}

.sidebar-footer i:hover {
  background: var(--secondary);
}

/* Main */
.main {
  margin-left: 250px;
  width: 100%;
  display: flex;
  flex-direction: column;
}

.topbar {
  background: white;
  box-shadow: 0 2px 5px rgba(0,0,0,.05);
}

.sidebar-toggle {
  background: var(--primary);
  color: white;
  border-radius: 8px;
}

.sidebar-toggle:hover {
  background: var(--secondary);
}

.balance {
  color: var(--secondary);
  font-weight: 600;
}

.footer {
  height: 50px;
  background: white;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.footer i {
  position: absolute;
  right: 20px;
  cursor: pointer;
  color: var(--secondary);
}

/* Overlay */
.sidebar-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.45);
  backdrop-filter: blur(3px);
  opacity: 0;
  visibility: hidden;
  transition: .35s;
  z-index: 999;
}

.sidebar-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* Mobile */
@media (max-width: 991px) {
  .sidebar {
    transform: translateX(-100%);
  }

  .sidebar.show {
    transform: translateX(0);
  }

  .main {
    margin-left: 0;
  }
}

/* Dark Mode */
.dark-mode {
  background: var(--dark-bg);
  color: #e5e7eb;
}

.dark-mode .sidebar {
  background: var(--dark-bg);
}

.dark-mode .topbar,
.dark-mode .footer,
.dark-mode .card {
  background: var(--dark-card);
  color: #e5e7eb;
}

.no-scroll {
  overflow: hidden;
}
