  #interactive-pond-demo {
    width: 900px;
    height: 700px;
    margin: 10px auto;
    background: transparent;
    border-radius: 12px;
    position: relative;
    overflow: hidden;
  }

  /* Render container stays the same */
  #interactive-pond-demo #renderContainer {
    position: absolute;
    inset: 0;
    border-radius: 12px;
    top: -100px;
  }

  /* Panel style */
  #interactive-pond-demo .panel {
    position: absolute;
    left: 50%;
    bottom: 100px;
    transform: translateX(-50%);
    width: 90%;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 12px;
    padding: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    color: #fff;
    font-family: Inter, sans-serif;
  }

  /* Headings inside panel */
  #interactive-pond-demo .panel h2 {
    margin: 0 0 8px 0;
    font-size: 16px;
    color: #fff;
  }

  /* Paragraphs inside panel */
  #interactive-pond-demo .panel p {
    margin: 0 0 12px 0;
    color: #ffffff;
    font-size: 13px;
  }

  /* Row layout inside panel */
  #interactive-pond-demo .panel .row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 8px;
  }

  /* Labels */
  #interactive-pond-demo .panel label {
    min-width: 110px;
    color: #ffffff;
    font-size: 13px;
  }

  /* Buttons */
  #interactive-pond-demo .btn {
    background: #6a0dad;
    color: #fff;
    border: none;
    padding: 8px 14px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 13px;
    transition: 0.2s;
  }
  #interactive-pond-demo .btn:hover {
    background: #7b1fc6;
  }
  #interactive-pond-demo .btn:active {
    transform: translateY(1px);
  }

  /* Range sliders */
  #interactive-pond-demo input[type="range"] {
    flex: 1;
    accent-color: #6a0dad;
  }

  #interactive-pond-demo .legend {
    position: absolute;
    left: 18px;
    top: 18px; /* Moved to the top left */
    display: flex;
    flex-direction: row;
    align-items: center;
    height: 16px;
    padding: 0 8px;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 5px;
    gap: 6px;
    font-size: 12px;
    color: #ffffff;
    line-height: 10px;
  }

  #interactive-pond-demo .legend .sw {
    width: 16px;
    height: 14px;
    border-radius: 2px;
    display: inline-block;
    
  }
  #interactive-pond-demo .legend .item {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #ffffff;
  }

  .legend-icon {
    width: 100%;
    height: 100%;
    object-fit: contain;
  }

  .formula {
    font-size: 10px;
    color: #fff;
    padding-left: 2px;
  }


  .legend-icon {
    display: block;
    width: 16px;
    height: 14px;
    object-fit: contain;
  }

  .legend .formula {
    font-size: 10px;
    position: relative;
    bottom: -2px;
  }

  #interactive-pond-demo #infoBox {
    position: absolute;
    right: 18px;
    top: 18px;
    width: 340px;
    max-height: 70vh;
    overflow: auto;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 12px;
    padding: 14px;
    box-shadow: 0 6px 30px rgba(0, 0, 0, 0);
    display: none;
  }

  #interactive-pond-demo #infoBox {
    color: #ffffff;
  }

  @media (max-width: 760px) {
    #interactive-pond-demo .panel {
      width: calc(100% - 36px);
      left: 18px;
      bottom: 12px;
    }
    #interactive-pond-demo #infoBox {
      display: none !important;
    }
  }


.narrative-box-info {
    position: relative;        /* No longer absolute */
    display: block;
    width: 100%;
    max-width: 900px;          /* Limit width for readability */
    margin: 2rem auto;         /* Center horizontally, add space top/bottom */
    background: #ffffff;       /* Solid white */
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05); /* Subtle shadow */
    font-size: 1.1rem;         /* Slightly larger text for main content */
    line-height: 1.6;
    color: #333;
    text-align: left;
  }
  
  .narrative-box-info p {
    margin-bottom: 1.5rem;
  }

  .narrative-box-info p:last-child {
    margin-bottom: 0;
  }
  
  .narrative-box-info strong {
    color: #2c3e50;
    font-weight: 700;
  }

  /* Ensure the simulation container has a defined height
  #interactive-pond-demo {
    position: relative; 
    width: 100%; 
    height: 80vh;
    overflow: hidden;
    border-bottom: 1px solid #eee;]
  } */