:root {
  --sidebar-width: 60px;
  --sidebar-bg: #002E6D;
  --sidebar-accent: #9ACAEB;
  --sidebar-text: #ffffff;
  --sidebar-hover: rgba(154, 202, 235, 0.2);
  --sidebar-divider: rgba(154, 202, 235, 0.3);
}

.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: var(--sidebar-width);
  height: 100vh;
  background: var(--sidebar-bg);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 0;
  z-index: 1000;
  box-sizing: border-box;
}

.sidebar-logo {
  width: 40px;
  height: 40px;
  margin-bottom: 20px;
  object-fit: contain;
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  flex: 1;
  gap: 4px;
}

.sidebar-nav-main {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  gap: 4px;
}

.sidebar-divider {
  width: 36px;
  height: 1px;
  background: var(--sidebar-divider);
  margin: 12px 0;
}

.sidebar-nav-secondary {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  gap: 4px;
}

.sidebar-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  color: var(--sidebar-text);
  text-decoration: none;
  transition: background 150ms ease, color 150ms ease;
}

.sidebar-link:hover {
  background: var(--sidebar-hover);
  color: var(--sidebar-accent);
}

.sidebar-link.active {
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  position: relative;
}

.sidebar-link.active::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 32px;
  background: var(--sidebar-accent);
  border-radius: 0 4px 4px 0;
}

.sidebar-link svg {
  width: 22px;
  height: 22px;
  stroke-width: 1.5;
}

.sidebar-footer {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.sidebar-logout {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 8px;
  background: transparent;
  border: none;
  color: var(--sidebar-text);
  cursor: pointer;
  transition: background 150ms ease, color 150ms ease;
}

.sidebar-logout:hover {
  background: var(--sidebar-hover);
  color: var(--sidebar-accent);
}

.sidebar-logout svg {
  width: 22px;
  height: 22px;
  stroke-width: 1.5;
}

.sidebar-version {
  font-size: 9px;
  color: var(--sidebar-accent);
  text-align: center;
  line-height: 1.2;
  opacity: 0.7;
}

.sidebar-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--sidebar-accent);
  background: #ffffff;
}

.sidebar-body {
  margin-left: var(--sidebar-width);
}

.sidebar-body main {
  padding: 24px 32px;
  min-height: calc(100vh - 48px);
}

.sidebar-body .container {
  max-width: 100%;
  padding: 24px 32px;
}

@media (max-width: 768px) {
  .sidebar {
    width: 100%;
    height: auto;
    flex-direction: row;
    padding: 8px 12px;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
  }

  .sidebar-logo {
    width: 32px;
    height: 32px;
    margin-bottom: 0;
    margin-right: 12px;
  }

  .sidebar-nav {
    flex-direction: row;
    flex: 1;
    gap: 4px;
  }

  .sidebar-nav-main,
  .sidebar-nav-secondary {
    flex-direction: row;
    gap: 4px;
  }

  .sidebar-divider {
    width: 1px;
    height: 24px;
    margin: 0 8px;
  }

  .sidebar-footer {
    flex-direction: row;
    margin-top: 0;
    margin-left: auto;
  }

  .sidebar-version {
    display: none;
  }

  .sidebar-link,
  .sidebar-logout {
    width: 36px;
    height: 36px;
  }

  .sidebar-link svg,
  .sidebar-logout svg {
    width: 20px;
    height: 20px;
  }

  .sidebar-avatar {
    width: 28px;
    height: 28px;
  }

  .sidebar-body {
    margin-left: 0;
    margin-top: 52px;
  }

  .sidebar-body main {
    padding: 16px;
    min-height: auto;
  }

  .sidebar-body .container {
    padding: 16px;
  }
}
