.dashboard-box {
    border: 1px solid #ddd;
    padding: 20px;
    margin-bottom: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    background-color: #f9f9f9;
  }
  
  .dashboard-box-content {
    display: flex;
    flex-direction: column;
    height: 100%;
  }
  
  .dashboard-box-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
  }
  
  .dashboard-box-title {
    margin: 0;
    color: #333;
    font-weight: 600;
    font-size: 1.5em;
  }
  
  .dashboard-info-button {
    background: none;
    border: none;
    color: #007bff;
    font-size: 18px;
    cursor: pointer;
  }
  
  .dashboard-plot-container {
    flex: 1;
    background-color: white;
    border-radius: 5px;
    padding: 15px;
    box-shadow: inset 0 0 5px rgba(0,0,0,0.05);
  }


  .ncontainer {
    border: 1px solid #ddd;
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 5px;
    display: flex;
    flex-direction: column;
    width: 100%;
    box-sizing: border-box;
}

.n-content {
    flex: 1;
    width: 100%;
    max-width: 100%;
}

.custom-container {
  width: 100%;
  background-color: #fcfcfc; /* Light gray background */
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* Bottom shade */
  margin-bottom: 20px;
}


.news-content {
  overflow: hidden; /* Prevent overflow */
  text-overflow: ellipsis; /* Add ellipsis for overflowed text */
  white-space: normal; /* Allow text to wrap */
}

/* Header search layout */
.header-center-row {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 10px;
}

.search-wrap {
  display: flex;
  align-items: center;
  width: 100%;
  max-width: 700px;
  margin: 0 auto;
}

.search-input-wrap {
  flex: 1;
  margin-right: 10px;
  min-width: 0;
}

.search-btn-wrap { flex-shrink: 0; display: flex; align-items: center; }

.search-btn {
  padding: 8px 16px;
  height: 38px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Card titles consistency */
.card .card-title { font-weight: 600; }

/* Improve selectize input look */
.selectize-control.single .selectize-input { border-radius: 6px; min-height: 38px; height: 38px; display: flex; align-items: center; }
.selectize-control .selectize-input input { color: #666; }

/* Mobile responsive tweaks */
@media (max-width: 768px) {
  .search-wrap { max-width: 100%; }
  .search-btn { height: 36px; }
}

html { background-color: #000; }
html[data-bs-theme="light"] { background-color: #fff; }

.theme-toggle-wrap {
  display: flex;
  align-items: center;
  height: 100%;
  padding: 0 10px 0 4px;
}
.navbar .bslib-nav-item {
  display: flex;
  align-items: center;
}
.navbar .bslib-nav-spacer {
  flex: 1 1 auto;
  min-width: 8px;
}
bslib-input-dark-mode {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  color: inherit;
}
html[data-bs-theme="dark"] bslib-input-dark-mode {
  --bs-emphasis-color: #e6e6e6;
  --text-1: #e6e6e6;
  --text-2: #9aa0a6;
  color: #e6e6e6;
}
html[data-bs-theme="light"] bslib-input-dark-mode {
  --bs-emphasis-color: #343a40;
  --text-1: #343a40;
  color: #343a40;
}

.chart-controls {
  margin-top: 10px;
  padding: 5px;
  background-color: #f8f9fa;
  border-radius: 5px;
}

.app-footer-body {
  color: #6c757d;
  font-size: 14px;
  text-align: center;
  border-top: 1px solid #e9ecef;
}

.about-heading {
  border-bottom: 2px solid #3498db;
  padding-bottom: 10px;
}

.news-container {
  border: 1px solid #ddd;
  padding: 15px;
  margin-bottom: 20px;
  border-radius: 5px;
}
.news-container--article { display: flex; }
.news-image {
  flex: 0 0 100px;
  margin-right: 15px;
}
.news-image img {
  width: 100%;
  height: auto;
  border-radius: 5px;
}
.news-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
}
.news-source {
  font-size: 16px;
  color: #1a5f7a;
}
.news-source--press { font-size: 18px; }
.news-date { color: #666; }
.news-title {
  margin-top: 0;
  margin-bottom: 10px;
  color: #333;
}
.news-excerpt {
  margin: 0 0 10px 0;
  color: #555;
}
.news-excerpt--press { margin: 0; }
.news-link {
  color: #1a5f7a;
  text-decoration: none;
  font-weight: bold;
}
.news-link:hover { text-decoration: underline; }

/* AMOLED dark — keep Minty accents (#56CC9D / #78c2ad / #FF7851) */
[data-bs-theme="dark"] {
  --bs-body-bg: #000000;
  --bs-body-color: #e6e6e6;
  --bs-emphasis-color: #ffffff;
  --bs-secondary-color: #9aa0a6;
  --bs-tertiary-color: #9aa0a6;
  --bs-tertiary-bg: #0d0d0d;
  --bs-secondary-bg: #111111;
  --bs-border-color: #222222;
  --bs-border-color-translucent: rgba(255, 255, 255, 0.08);
  --bs-link-color: #56cc9d;
  --bs-link-color-rgb: 86, 204, 157;
  --bs-link-hover-color: #78c2ad;
  --bs-heading-color: #e6e6e6;
  --bs-card-bg: #0d0d0d;
  --bs-card-cap-bg: #0d0d0d;
  --bs-card-border-color: #222222;
  --bs-modal-bg: #0d0d0d;
  --bs-modal-border-color: #222222;
  --bs-dropdown-bg: #0d0d0d;
  --bs-dropdown-link-color: #e6e6e6;
  --bs-dropdown-link-hover-bg: #1a1a1a;
  --bs-dropdown-border-color: #222222;
  color-scheme: dark;
}

html[data-bs-theme="dark"],
[data-bs-theme="dark"] body {
  background-color: #000000 !important;
  color: #e6e6e6;
}

[data-bs-theme="dark"] h1,
[data-bs-theme="dark"] h2,
[data-bs-theme="dark"] h3,
[data-bs-theme="dark"] h4,
[data-bs-theme="dark"] h5,
[data-bs-theme="dark"] h6,
[data-bs-theme="dark"] .card-title,
[data-bs-theme="dark"] .about-heading,
[data-bs-theme="dark"] .about-subhead {
  color: #e6e6e6;
}

[data-bs-theme="dark"] .navbar,
[data-bs-theme="dark"] .navbar.bg-light,
[data-bs-theme="dark"] nav.navbar {
  background-color: #000000 !important;
  border-bottom: 1px solid #222;
}
[data-bs-theme="dark"] .navbar .nav-link {
  color: #e6e6e6 !important;
}
[data-bs-theme="dark"] .navbar .nav-link:hover,
[data-bs-theme="dark"] .navbar .nav-link.active,
[data-bs-theme="dark"] .navbar .nav-link:focus {
  color: #56cc9d !important;
}
[data-bs-theme="dark"] .navbar-brand img {
  filter: invert(1) hue-rotate(180deg);
}

[data-bs-theme="dark"] .card,
[data-bs-theme="dark"] .modal-content,
[data-bs-theme="dark"] .dropdown-menu {
  background-color: #0d0d0d;
  border-color: #222;
  color: #e6e6e6;
}

[data-bs-theme="dark"] .dashboard-box,
[data-bs-theme="dark"] .custom-container,
[data-bs-theme="dark"] .ncontainer,
[data-bs-theme="dark"] .dashboard-plot-container,
[data-bs-theme="dark"] .chart-controls {
  background-color: #0d0d0d;
  border-color: #222;
  box-shadow: none;
}
[data-bs-theme="dark"] .dashboard-box-title {
  color: #e6e6e6;
}
[data-bs-theme="dark"] .dashboard-info-button {
  color: #56cc9d;
}

[data-bs-theme="dark"] .app-footer-body {
  color: #9aa0a6;
  border-top-color: #222;
}

[data-bs-theme="dark"] .news-container {
  border-color: #222;
  background-color: #0d0d0d;
}
[data-bs-theme="dark"] .news-source,
[data-bs-theme="dark"] .news-link {
  color: #56cc9d;
}
[data-bs-theme="dark"] .news-date { color: #9aa0a6; }
[data-bs-theme="dark"] .news-title { color: #e6e6e6; }
[data-bs-theme="dark"] .news-excerpt { color: #b3b3b3; }

[data-bs-theme="dark"] .form-control,
[data-bs-theme="dark"] .form-select,
[data-bs-theme="dark"] textarea.form-control {
  background-color: #0a0a0a;
  color: #e6e6e6;
  border-color: #333;
}
[data-bs-theme="dark"] .form-control:focus,
[data-bs-theme="dark"] .form-select:focus {
  background-color: #0a0a0a;
  color: #e6e6e6;
  border-color: #56cc9d;
  box-shadow: 0 0 0 0.2rem rgba(86, 204, 157, 0.2);
}

[data-bs-theme="dark"] .selectize-input,
[data-bs-theme="dark"] .selectize-control.single .selectize-input {
  background-color: #0a0a0a;
  color: #e6e6e6;
  border-color: #333;
}
[data-bs-theme="dark"] .selectize-control .selectize-input input {
  color: #e6e6e6;
}
[data-bs-theme="dark"] .selectize-dropdown {
  background-color: #0d0d0d;
  color: #e6e6e6;
  border-color: #333;
}
[data-bs-theme="dark"] .selectize-dropdown .active {
  background-color: #1a1a1a;
  color: #56cc9d;
}

[data-bs-theme="dark"] .nav-tabs .nav-link {
  color: #9aa0a6;
}
[data-bs-theme="dark"] .nav-tabs .nav-link.active {
  background-color: #0d0d0d;
  color: #e6e6e6;
  border-color: #222 #222 #0d0d0d;
}
[data-bs-theme="dark"] .nav-tabs {
  border-bottom-color: #222;
}

[data-bs-theme="dark"] .table,
[data-bs-theme="dark"] .shiny-table,
[data-bs-theme="dark"] table.dataTable,
[data-bs-theme="dark"] .table-striped > tbody > tr:nth-of-type(odd) > * {
  --bs-table-bg: transparent;
  --bs-table-striped-bg: #0a0a0a;
  --bs-table-hover-bg: #141414;
  --bs-table-border-color: #222;
  color: #e6e6e6;
  background-color: transparent;
}
[data-bs-theme="dark"] table.dataTable thead th,
[data-bs-theme="dark"] table.dataTable tbody td,
[data-bs-theme="dark"] .table th,
[data-bs-theme="dark"] .table td,
[data-bs-theme="dark"] .shiny-table th,
[data-bs-theme="dark"] .shiny-table td {
  background-color: #000 !important;
  border-color: #222 !important;
  color: #e6e6e6;
}
[data-bs-theme="dark"] table.dataTable.stripe tbody tr.odd td,
[data-bs-theme="dark"] .table-striped tbody tr:nth-of-type(odd) td {
  background-color: #0a0a0a !important;
}
[data-bs-theme="dark"] .dataTables_wrapper .dataTables_length,
[data-bs-theme="dark"] .dataTables_wrapper .dataTables_filter,
[data-bs-theme="dark"] .dataTables_wrapper .dataTables_info,
[data-bs-theme="dark"] .dataTables_wrapper .dataTables_paginate {
  color: #9aa0a6;
}
[data-bs-theme="dark"] .dataTables_wrapper .dataTables_filter input,
[data-bs-theme="dark"] table.dataTable thead input {
  background-color: #0a0a0a;
  color: #e6e6e6;
  border: 1px solid #333;
}

[data-bs-theme="dark"] .well,
[data-bs-theme="dark"] .panel,
[data-bs-theme="dark"] .tab-content {
  background-color: transparent;
  color: #e6e6e6;
}

[data-bs-theme="dark"] .plotly.html-widget,
[data-bs-theme="dark"] .html-widget.plotly,
[data-bs-theme="dark"] .js-plotly-plot,
[data-bs-theme="dark"] .js-plotly-plot .plot-container,
[data-bs-theme="dark"] .js-plotly-plot .svg-container,
[data-bs-theme="dark"] .plot-container.plotly {
  background-color: #000 !important;
}
[data-bs-theme="dark"] .js-plotly-plot .main-svg,
[data-bs-theme="dark"] .js-plotly-plot .bg,
[data-bs-theme="dark"] .js-plotly-plot .bglayer rect {
  fill: #000 !important;
}
[data-bs-theme="dark"] .js-plotly-plot .xtick text,
[data-bs-theme="dark"] .js-plotly-plot .ytick text,
[data-bs-theme="dark"] .js-plotly-plot .xaxislayer-above text,
[data-bs-theme="dark"] .js-plotly-plot .yaxislayer-above text,
[data-bs-theme="dark"] .js-plotly-plot .g-gtitle text,
[data-bs-theme="dark"] .js-plotly-plot .g-xtitle text,
[data-bs-theme="dark"] .js-plotly-plot .g-ytitle text,
[data-bs-theme="dark"] .js-plotly-plot .annotation-text,
[data-bs-theme="dark"] .js-plotly-plot .gtitle,
[data-bs-theme="dark"] .js-plotly-plot .xtitle,
[data-bs-theme="dark"] .js-plotly-plot .ytitle {
  fill: #f2f2f2 !important;
}


