/* Tarjetas móviles para gráficos Plotly por país. */
.bm-chart-card { width: 500px; max-width: 100%; min-width: 0; }
.bm-chart-heading, .bm-chart-series { display: none; }

@media (max-width: 767px) {
  .article-graficos .tab-content { margin: 1rem 0; width: 100%; }
  .article-graficos .tab-pane { min-width: 0; }
  .bm-chart-card {
    width: 100% !important;
    padding: 14px 8px;
    margin: 0 0 20px;
    border: 1px solid #c9dadd;
    border-radius: 14px;
    background: #ffffff;
  }
  .modo-oscuro .bm-chart-card { background: #1c2b35; border-color: #3b515d; }
  .bm-chart-heading {
    display: block;
    margin: 0 8px 12px;
    font-size: 15px;
    line-height: 1.5;
    text-align: left;
    white-space: pre-line;
    overflow-wrap: anywhere;
  }
  .bm-chart-series { display: block; margin: 12px 8px 0; }
  .bm-chart-series[hidden] { display: none; }
  .bm-chart-series summary { padding: 10px 0; cursor: pointer; font-weight: 600; }
  .bm-chart-series-list label {
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 44px;
    padding: 8px 0;
    font-size: 13px;
    line-height: 1.4;
    overflow-wrap: anywhere;
  }
  .bm-chart-series-list input { width: 18px; height: 18px; flex-shrink: 0; accent-color: #0b6170; }
  .bm-chart-swatch { width: 16px; height: 4px; flex-shrink: 0; border-radius: 2px; }
}

.bm-chart-info {
  padding: 12px 16px;
  border-top: 1px solid #c9dadd;
  color: #405461;
  font: 13px/1.6 Arial, sans-serif;
  overflow-wrap: anywhere;
}

.modo-oscuro .bm-chart-info {
  border-color: #3b515d;
  color: #c7d6dc;
}


@media (max-width: 767px) {
  body .article-graficos .bm-chart-card .plotly .gtitle,
  body .article-graficos .bm-chart-card .plotly .g-gtitle,
  body .article-graficos .bm-chart-card .plotly .legend {
    display: none !important;
  }
}