/* ==========================================================================
   PAGE VISUALISATIONS (D3.JS DIAGRAMS)
   ========================================================================== */
.vis-container {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  align-items: center;
}

.vis-header {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 1rem auto;
}

.vis-header h2 {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
}

.vis-header p {
  color: var(--light-muted);
  font-size: 1.05rem;
}

.vis-nav-tabs {
  display: inline-flex;
  background-color: #e9ecef;
  padding: 5px;
  border-radius: var(--radius-full);
  gap: 6px;
  margin-bottom: 1.5rem;
}

.vis-tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 20px;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.95rem;
  color: #495057;
  transition: all var(--transition-fast);
}

.vis-tab-btn:hover {
  color: var(--light-text);
}

.vis-tab-btn.active {
  background-color: var(--light-surface);
  color: var(--ciad-green-dark);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.vis-tab-btn img {
  width: 18px;
  height: 18px;
}

.chart-viewport {
  width: 100%;
  max-width: 1200px;
  min-height: 600px;
  background-color: var(--light-surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--light-border);
  box-shadow: var(--shadow-sm);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.chart-viewport svg {
  width: 100%;
  height: auto;
  font-family: var(--font-family);
  user-select: none;
}

.vis-tooltip {
  position: absolute;
  padding: 8px 12px;
  background-color: rgba(30, 30, 30, 0.92);
  color: #ffffff;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.15s ease;
  z-index: 50;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  max-width: 250px;
}

.vis-tooltip strong {
  color: var(--ciad-green);
  display: block;
  margin-bottom: 2px;
}

.vis-instructions {
  margin-top: 1rem;
  font-size: 0.85rem;
  color: var(--light-muted);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
