/* === Soft Electric Sidebar Theme === */

/* Layout wrapper */
body {
  display: flex;
  min-height: 100vh;
  background: var(--bg, #f6f7fb);
  color: var(--ink, #111827);
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial;
  overflow-x: hidden;
}

/* Sidebar */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: 240px;
  height: 100vh;
  background: var(--surface, #fff);
  border-right: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 2px 0 8px rgba(0, 0, 0, 0.05);
  transform: translateX(0);
  transition: transform 0.3s ease, box-shadow 0.2s ease;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  padding: 16px;
}

.sidebar h1 {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--primary, #4f46e5);
  margin-bottom: 1rem;
}

/* Sidebar user info */
.sidebar .user-info {
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--ink, #111827);
}

/* Navigation links */
.sidebar nav a,
.sidebar nav .dropbtn {
  display: block;
  color: var(--ink, #111827);
  padding: 8px 10px;
  border-radius: 8px;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  transition: background 0.2s ease;
}

.sidebar nav a:hover,
.sidebar nav .dropbtn:hover {
  background: rgba(79, 70, 229, 0.08);
}

/* Dropdown containers */
.dropdown {
  position: relative;
}
.dropdown-content {
  display: none;
  flex-direction: column;
  padding-left: 10px;
}
.dropdown:hover .dropdown-content {
  display: flex;
}

/* Toggle button */
.toggle-btn {
  position: fixed;
  top: 14px;
  left: 14px;
  background: var(--primary, #4f46e5);
  color: #fff;
  border: none;
  border-radius: 8px;
  width: 40px;
  height: 40px;
  cursor: pointer;
  z-index: 1100;
  font-size: 1.4rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}
.toggle-btn:hover {
  background: #4338ca;
}

/* Main content */
main,
.main {
  flex: 1;
  margin-left: 240px;
  padding: 20px;
  transition: margin-left 0.3s ease;
}

/* === Toggle States === */

/* When sidebar is closed */
.sidebar.open {
  transform: translateX(0);
}

/* Mobile default: sidebar hidden
@media (max-width: 768px) { */
@media (max-width: 700px) {
  .sidebar {
    transform: translateX(-100%);
  }
  .sidebar.open {
    transform: translateX(0);
    box-shadow: 2px 0 12px rgba(0, 0, 0, 0.15);
  }
  main,
  .main {
    margin-left: 0;
  }
  body.sidebar-open main {
    filter: brightness(0.95);
  }
}

/* === Lucide icon adjustments === */
.sidebar i[data-lucide] {
  width: 18px;
  height: 18px;
  vertical-align: middle;
  margin-right: 6px;
  color: var(--primary, #4f46e5);
}

.menu-header {
  padding: 8px 24px;
  font-weight: bold;
  color: #a5b4fc;
  text-transform: uppercase;
  font-size: 0.75rem;
  opacity: 0.9;
}
