/* 左侧菜单 */
.sidebar {
  width: 240px;
  flex-shrink: 0; /* 在 #app-content 的 flex 行中保持菜单宽度，不被压缩 */
  background: linear-gradient(180deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
  border-right: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  box-shadow: 4px 0 30px rgba(0, 0, 0, 0.4);
}

.sidebar-header {
  padding: 20px;
  border-bottom: 1px solid var(--border-color);
  background: linear-gradient(180deg, rgba(0, 180, 216, 0.1) 0%, transparent 100%);
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo-icon {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--accent-blue), var(--accent-cyan));
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.logo-icon svg {
  width: 20px;
  height: 20px;
  fill: var(--bg-deep);
}

.logo-text {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: 1px;
}

.logo-sub {
  font-size: 10px;
  color: var(--text-muted);
  letter-spacing: 1px;
  margin-top: 2px;
}

/* 导航菜单 */
.nav-menu {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 8px 12px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 16px;
  margin-bottom: 8px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.25s ease;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  border: 1px solid transparent;
}

.nav-item:hover {
  background: rgba(0, 180, 216, 0.1);
  color: var(--text-primary);
}

.nav-item.active {
  background: linear-gradient(135deg, rgba(0, 180, 216, 0.2), rgba(0, 180, 216, 0.1));
  color: var(--accent-cyan);
  border-color: rgba(0, 180, 216, 0.3);
}

.nav-item.active .nav-icon {
  color: var(--accent-cyan);
}

.expand-arrow {
  margin-left: auto;
  font-size: 10px;
  transition: transform 0.3s;
  color: rgba(255, 255, 255, 0.5);
}

.expand-arrow.expanded {
  transform: rotate(180deg);
}

.nav-icon {
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.nav-icon svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

/* 舷号列表 */
.ship-list-container {
  padding: 16px 12px;
  flex: 1;
  overflow-y: auto;
}

.ship-list-title {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  padding: 0 8px;
  margin-bottom: 12px;
}

.ship-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.ship-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  border: none;
  background: transparent;
  flex-wrap: wrap;
}

.ship-item:hover {
  background: rgba(0, 180, 216, 0.1);
}

.ship-item.active {
  background: linear-gradient(135deg, rgba(0, 180, 216, 0.2), rgba(0, 120, 180, 0.15));
  box-shadow: 0 0 15px rgba(0, 180, 216, 0.2);
}

.ship-num {
  min-width: 80px;
  height: 34px;
  background: rgba(0, 180, 216, 0.12);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: var(--accent-cyan);
  letter-spacing: 0.5px;
  padding: 0 8px;
}

.ship-item.active .ship-num {
  background: linear-gradient(135deg, var(--accent-blue), var(--accent-cyan));
  color: var(--bg-deep);
  box-shadow: 0 2px 8px var(--accent-glow);
  border-color: transparent;
}

.ship-info {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.ship-code {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.ship-status {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--danger);
}

.ship-status.online {
  background: var(--success);
  box-shadow: 0 0 8px var(--success);
}

.ship-status-indicator {
  font-size: 11px;
  padding: 2px 6px;
  border-radius: 4px;
  font-weight: 500;
}

.ship-status-indicator.status-正常 {
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
}

.ship-status-indicator.status-维修 {
  background: rgba(245, 158, 11, 0.15);
  color: #f59e0b;
}

.ship-status-indicator.status-停用 {
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
}

.ship-item.status-normal {
  border-left: 3px solid #10b981;
}

.ship-item.status-repair {
  border-left: 3px solid #f59e0b;
}

.ship-item.status-disabled {
  border-left: 3px solid #ef4444;
}
