/* Sidebar Styles */

.sidebar {
  position: fixed;
  left: 0;
  top: 78px;
  width: 240px;
  height: calc(100vh - 78px);
  background:
    radial-gradient(circle at top, rgba(201, 146, 58, 0.12), transparent 28%),
    linear-gradient(180deg, #0a1628 0%, #0d1b31 100%);
  color: #fff;
  overflow-y: auto;
  box-shadow: 16px 0 40px rgba(7, 15, 28, 0.22);
  border-right: 1px solid rgba(201, 146, 58, 0.14);
}

.sidebar.collapsed {
  margin-left: -240px;
}

.sidebar.open {
  margin-left: 0;
}

.sidebar-logo {
  padding: 20px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-logo-text {
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  margin: 0;
}

.sidebar-logo-subtitle {
  color: rgba(255, 255, 255, 0.75);
  font-size: 13px;
  margin-top: 6px;
}

.sidebar-user {
  margin: 18px;
  padding: 20px 18px;
  border: 1px solid rgba(201, 146, 58, 0.14);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.04);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.sidebar-user-avatar {
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: linear-gradient(135deg, #d8a859 0%, #c9923a 100%);
  color: #0a1628;
  display: grid;
  place-items: center;
  font-weight: 700;
  margin-bottom: 14px;
  box-shadow: 0 12px 24px rgba(201, 146, 58, 0.18);
}

.sidebar-user-info p,
.sidebar-user-info small {
  margin: 0;
  color: rgba(255, 255, 255, 0.88);
  word-break: break-word;
}

.sidebar-user-info p {
  font-size: 15px;
  font-weight: 700;
}

.sidebar-user-info small {
  display: block;
  margin-top: 4px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.58);
}

.sidebar-nav {
  position: static;
  top: auto;
  left: auto;
  right: auto;
  z-index: auto;
  background: transparent;
  border-bottom: none;
  box-shadow: none;
  padding: 4px 12px 20px;
}

.sidebar-section-title {
  padding: 0 12px 12px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(201, 146, 58, 0.72);
}

.sidebar-nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar-nav li {
  margin-bottom: 8px;
}

.sidebar-nav .nav-link {
  display: flex;
  align-items: center;
  padding: 14px 16px;
  color: rgba(255, 255, 255, 0.82);
  text-decoration: none;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  border-radius: 14px;
  border: 1px solid transparent;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.sidebar-nav .nav-link:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(201, 146, 58, 0.16);
  color: #fff;
  transform: translateX(2px);
}

.sidebar-nav .nav-link.active {
  background: linear-gradient(135deg, rgba(201, 146, 58, 0.18) 0%, rgba(201, 146, 58, 0.08) 100%);
  border-color: rgba(201, 146, 58, 0.24);
  color: #ffffff;
  box-shadow: 0 12px 22px rgba(4, 11, 22, 0.18);
}

.sidebar-nav .nav-link i,
.sidebar-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  margin-right: 12px;
  text-align: center;
  opacity: 0.92;
}

.nav-link-group {
  cursor: default;
  margin-bottom: 8px;
}

.nav-sublink-toggle {
  width: 100%;
  border: 0;
  background: rgba(255, 255, 255, 0.04);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  text-align: left;
}

.nav-sublink-toggle span:first-child {
  flex: 1;
}

.sidebar-submenu {
  margin: -2px 0 10px 20px;
  padding-left: 14px;
  border-left: 1px solid rgba(201, 146, 58, 0.18);
}

.sidebar-submenu-nested {
  margin: 8px 0 0 14px;
  padding-left: 12px;
  border-left-color: rgba(255, 255, 255, 0.12);
}

.nav-sublink {
  display: block;
  padding: 10px 14px;
  margin-bottom: 6px;
  border-radius: 12px;
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 600;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.nav-sublink:hover {
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  transform: translateX(2px);
}

.nav-sublink.active {
  background: rgba(201, 146, 58, 0.14);
  color: #fff;
}

.submenu-caret {
  font-size: 1rem;
  line-height: 1;
  transition: transform 0.2s ease;
}

.submenu-caret.open {
  transform: rotate(45deg);
}

@media (max-width: 992px) {
  .sidebar {
    width: 220px;
  }
}

@media (max-width: 768px) {
  .sidebar {
    position: relative;
    width: 100%;
    height: auto;
    top: 0;
    border-right: none;
    box-shadow: none;
  }
}
