/* 监控画面页面 */
.monitor-page {
  display: flex;
  flex-direction: column;
  gap: 24px;
  flex: 1;
}

.monitor-content {
  display: flex;
  gap: 24px;
  flex: 1;
  min-height: 0;
}

.monitor-left {
  flex: 2;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.monitor-right {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-width: 320px;
}

.video-section {
  flex: 1;
}

.video-container {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 20px;
  display: flex;
  flex-direction: column;
}

.detection-card {
  flex: 1;
}

.video-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.video-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

.live-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  background: rgba(255, 82, 82, 0.15);
  border: 1px solid rgba(255, 82, 82, 0.3);
  border-radius: 20px;
  font-size: 11px;
  color: var(--danger);
  font-weight: 600;
}

.live-dot {
  width: 6px;
  height: 6px;
  background: var(--danger);
  border-radius: 50%;
  animation: pulse 1.5s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.2); }
}

.video-wrapper {
  flex: 1;
  background: #000;
  border-radius: 12px;
  overflow: hidden;
  position: relative;
  min-height: 380px;
  aspect-ratio: 16/10;
}

.video-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  color: var(--text-muted);
}

.video-placeholder svg {
  width: 64px;
  height: 64px;
  fill: currentColor;
  opacity: 0.4;
}

video, canvas {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

canvas {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

/* 右侧信息面板 */
.info-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 18px;
}

.info-card-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.info-card-title svg {
  width: 16px;
  height: 16px;
  fill: var(--accent-cyan);
}

.ship-detail-item {
  display: flex;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.ship-detail-item:last-child {
  border-bottom: none;
}

.detail-label {
  font-size: 13px;
  color: var(--text-muted);
}

.detail-value {
  font-size: 13px;
  color: var(--text-primary);
  font-weight: 500;
}

/* 检测结果列表 */
.detection-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 200px;
  overflow-y: auto;
}

.detection-list-full {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-height: calc(100vh - 320px);
  overflow-y: auto;
  padding-right: 8px;
}

.detection-list-full::-webkit-scrollbar {
  width: 6px;
}

.detection-list-full::-webkit-scrollbar-track {
  background: rgba(255,255,255,0.05);
  border-radius: 3px;
}

.detection-list-full::-webkit-scrollbar-thumb {
  background: rgba(0, 180, 216, 0.3);
  border-radius: 3px;
}

.detection-list-full .detection-item {
  padding: 14px 16px;
  background: rgba(0, 180, 216, 0.05);
  border-radius: 10px;
  border: 1px solid rgba(0, 180, 216, 0.1);
  transition: all 0.2s;
}

.detection-list-full .detection-item:hover {
  background: rgba(0, 180, 216, 0.1);
  border-color: rgba(0, 180, 216, 0.25);
}

.detection-list-full .detection-icon {
  width: 38px;
  height: 38px;
}

.detection-list-full .detection-icon svg {
  width: 20px;
  height: 20px;
}

.detection-list-full .detection-name {
  font-size: 15px;
  font-weight: 500;
}

.detection-list-full .detection-time {
  font-size: 12px;
  margin-top: 2px;
}

.detection-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  background: rgba(0, 180, 216, 0.05);
  border-radius: 8px;
  border: 1px solid rgba(0, 180, 216, 0.1);
  position: relative;
}

.detection-icon {
  width: 32px;
  height: 32px;
  background: rgba(0, 180, 216, 0.15);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.detection-icon svg {
  width: 18px;
  height: 18px;
  fill: var(--accent-cyan);
}

.detection-info {
  flex: 1;
}

.detection-name {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
}

.detection-time {
  font-size: 11px;
  color: var(--text-muted);
}

.detection-badge {
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
}

.badge-danger {
  background: rgba(255, 82, 82, 0.15);
  color: var(--danger);
}

.badge-warning {
  background: rgba(255, 179, 0, 0.15);
  color: var(--warning);
}

.badge-success {
  background: rgba(0, 230, 118, 0.15);
  color: var(--success);
}

/* 空状态 */
.empty-state {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  color: var(--text-muted);
  padding: 40px;
}

.empty-state svg {
  width: 80px;
  height: 80px;
  fill: currentColor;
  opacity: 0.3;
}

/* 响应式 */
@media (max-width: 1200px) {
  .video-section {
    grid-template-columns: 1fr;
  }
}

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

@media (max-width: 768px) {
  .sidebar {
    position: fixed;
    left: -280px;
    z-index: 100;
    transition: left 0.3s ease;
  }
  .sidebar.open {
    left: 0;
  }
}
