/* Reset and Basic Styles */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body,
html {
  width: 100%;
  height: 100%;
  font-family: Arial, sans-serif;
  overflow: hidden;
}

/* Layout Styles */
.container {
  display: flex;
  flex-direction: column;
  height: 100%;
}

header {
  background-color: #1e1e1e;
  color: #fff;
  padding: 20px;
  text-align: center;
  flex: 0 0 60px;
  position: relative;
  z-index: 3; /* Above NetworkCanvas and content container */
}

.main {
  display: flex;
  flex: 1;
  position: relative;
}

.content {
  position: relative;
  flex: 1;
  padding: 20px;
  overflow: auto;
  z-index: 2; 
  display: flex;
  align-items: center;
  justify-content: center;
}


#networkCanvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: #000; 
  z-index: 1; 
  pointer-events: none; 
}

.node {
  position: absolute;
  width: 8px; 
  height: 8px;
  background-color: #00ff00;
  border-radius: 50%;
  box-shadow: 0 0 10px #00ff00, 0 0 20px #00ff00, 0 0 30px #00ff00;
  transition: all 0.3s ease;
}

.node.blink {
  animation: blink 1.5s infinite;
}

.node.active {
  background-color: #ff0000; 
  box-shadow: 0 0 10px #ff0000, 0 0 20px #ff0000, 0 0 30px #ff0000;
}

.line {
  position: absolute;
  height: 2px;
  transform-origin: 0 50%;
  opacity: 0.7; 
}

.line.dotted {
  border-top: 2px dotted #00ff00;
}

.line.solid {
  background-color: #00ff00;
}

.line.fade {
  animation: fadeOut 1s forwards;
}

.pulse {
  position: absolute;
  width: 20px;
  height: 20px;
  border: 2px solid #00ff00;
  border-radius: 50%;
  animation: pulse 1s forwards;
  pointer-events: none;
}


.ripple-effect {
  position: absolute;
  width: 20px;
  height: 20px;
  border: 2px solid #00ff00;
  border-radius: 50%;
  animation: ripple 1s forwards;
  transform: translate(-50%, -50%);
  opacity: 0.7;
}




@keyframes pulse {
  0% {
    transform: scale(0.5);
    opacity: 0.7;
  }
  100% {
    transform: scale(2.5);
    opacity: 0;
  }
}


@keyframes blink {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.8;
  }
}


@keyframes fadeOut {
  from {
    opacity: 1;
  }
  to {
    opacity: 0;
  }
}


@keyframes ripple {
  from {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.7;
  }
  to {
    transform: translate(-50%, -50%) scale(2.5);
    opacity: 0;
  }
}


@media (max-width: 768px) {
  .sidebar {
    width: 150px;
    flex: 0 0 150px;
  }
}

@media (max-width: 480px) {
  .sidebar {
    display: none;
  }
  .main {
    flex-direction: column;
  }
  .content-container {
    max-width: 100%;
  }
}

@media (max-width: 1024px) {
  .container {
    flex-direction: column;
  }
  .sidebar {
    width: 140px;
    flex: 0 0 140px;
    padding: 15px;
  }
  .content-container {
    max-width: 95%;
    padding: 20px;
  }
}

@media (max-width: 768px) {
  header {
    padding: 15px;
    font-size: 1.1em;
  }
  .sidebar {
    width: 120px;
    flex: 0 0 120px;
    padding: 10px;
  }
  .sidebar h2 {
    font-size: 1.1em;
  }
  .content-container {
    max-width: 100%;
    padding: 15px;
  }
  .content {
    padding: 10px;
  }
}

@media (max-width: 600px) {
  .main {
    flex-direction: column;
  }
  .sidebar {
    display: none;
  }
  .content-container {
    max-width: 100%;
    padding: 10px;
    border-radius: 0;
    box-shadow: none;
  }
  header {
    font-size: 1em;
    padding: 10px;
  }
}

@media (max-width: 400px) {
  header {
    font-size: 0.95em;
    padding: 8px;
  }
  .content-container {
    padding: 5px;
  }
}

.path-node {
  background-color: #0000ff; 
  box-shadow: 0 0 10px #0000ff, 0 0 20px #0000ff, 0 0 30px #0000ff;
  transition: background-color 0.3s ease, box-shadow 0.3s ease;
}
