/* =====================================================================
   Public Dashboard V2 — UX4G Design System based styles
   Built on tokens defined in /public/css/UX4G/variables.css
   Starts from the tabs (header handled elsewhere).
   ===================================================================== */

.ptv2_wrapper {
  background-color: var(--ux4g-bg-secondary-links-50);
  min-height: 100vh;
  font-family: inherit;
  color: var(--ux4g-color-neutral-900);
}

/* ---------------------------------------------------------------------
   Tabs (PUBLIC DASHBOARD / HEATMAP)
   --------------------------------------------------------------------- */
.ptv2_tabs_bar {
  display: flex;
  justify-content: center;
  background-color: var(--ux4g-color-neutral-0);
  padding: var(--ux4g-space-5) var(--ux4g-space-6) 0;
  /* border-bottom: 2px solid var(--ux4g-border-color-primary-default-changed); */
}

.ptv2_tab_btn {
  background: var(--ux4g-color-neutral-100);
  border: 1px solid var(--ux4g-color-neutral-200);
  border-bottom: none;
  border-top-left-radius: var(--ux4g-space-4);
  border-top-right-radius: var(--ux4g-space-4);
  padding: var(--ux4g-space-4) var(--ux4g-space-11);
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.04em;
  color: var(--ux4g-color-neutral-500);
  cursor: pointer;
  transition:
    color 0.2s ease,
    background-color 0.2s ease;
}

.ptv2_tab_btn:hover {
  color: var(--ux4g-text-brand-primary-default-changed);
}

.ptv2_tab_btn.active {
  color: var(--ux4g-text-brand-primary-default-changed);
  background-color: var(--ux4g-color-primary-200-new);
  border-color: var(--ux4g-color-primary-200-new);
}

.ptv2_tab_btn:focus-visible {
  outline: 2px solid var(--ux4g-border-color-neutral-focus);
  outline-offset: 2px;
}

/* ---------------------------------------------------------------------
   Filter bar
   --------------------------------------------------------------------- */
.ptv2_filter_bar {
  background-color: var(--ux4g-color-primary-200-new);
  padding: var(--ux4g-space-6) var(--ux4g-space-8);
}

.ptv2_filter_home {
  display: flex;
  align-items: center;
  gap: var(--ux4g-space-3);
  color: var(--ux4g-color-neutral-900);
  white-space: nowrap;
  padding-top: var(--ux4g-space-6);
}

.ptv2_filter_home i {
  color: var(--ux4g-color-neutral-900);
}

.ptv2_filter_label {
  display: block;
  color: var(--ux4g-color-neutral-700);
  margin-bottom: var(--ux4g-space-2);
}

.ptv2_filter_select {
  width: 100%;
  border: 1px solid var(--ux4g-control-border-default);
  background-color: var(--ux4g-color-neutral-0);
  color: var(--ux4g-color-neutral-900);
}

.ptv2_filter_select:focus-visible {
  outline: 2px solid var(--ux4g-border-color-primary-strong);
  outline-offset: 1px;
}

.ptv2_reset_btn {
  margin-top: var(--ux4g-space-7);
}

/* ---------------------------------------------------------------------
   Cards
   --------------------------------------------------------------------- */
.ptv2_body {
  padding: var(--ux4g-space-8);
  /* contain wide children (grids, charts, hidden hover tooltips) so the
     cards area never pushes the page sideways on mobile. The filter bar
     and its native <select> dropdowns live OUTSIDE this element, so they
     are unaffected. */
  max-width: 100%;
  overflow-x: hidden;
}

/* filter bar: keep its grid row from spilling past the viewport.
   No overflow clipping here so the native <select> dropdowns stay normal. */
.ptv2_filter_bar {
  max-width: 100%;
}

.ptv2_filter_bar .row {
  margin-left: 0;
  margin-right: 0;
}

.ptv2_card {
  background-color: var(--ux4g-color-neutral-0);
  border: 1px solid var(--ux4g-color-neutral-200);
  border-radius: var(--ux4g-space-6);
  padding: var(--ux4g-space-7);
  margin-bottom: var(--ux4g-space-8);
  box-shadow: 0px 4px 16px 0px #2661E020;
}

.ptv2_card_head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: var(--ux4g-space-4);
  margin-bottom: var(--ux4g-space-6);
}

.ptv2_card_title {
  color: var(--ux4g-color-neutral-900);
  margin: 0;
  display: inline-flex;
}

.ptv2_card_subtitle {
  color: var(--ux4g-color-neutral-700);
  margin: var(--ux4g-space-2) 0 0;
}

/* structured meta: separate label + value divs */
.ptv2_card_meta_label {
  color: var(--ux4g-color-neutral-700);
}

.ptv2_card_meta_value {
  color: var(--ux4g-color-neutral-900);
  font-weight: 700 !important;
}

/* trend indicator "▲ x.xx% vs last month" */
.ptv2_trend {
  /* display: inline-flex;
  align-items: center; */
  gap: var(--ux4g-space-1);
  margin-top: var(--ux4g-space-2);
  color: var(--ux4g-color-neutral-700);
  margin-bottom: var(--ux4g-space-5);
  display: block;
}

.ptv2_trend .up {
  color: var(--ux4g-color-green-800);
}

.ptv2_trend .down {
  color: var(--ux4g-color-red-800);
}

/* ---------------------------------------------------------------------
   Highlights row (inline stat chips separated by +)
   --------------------------------------------------------------------- */
.ptv2_highlights {
  display: flex;
  flex-wrap: wrap;
  align-items: stretch;
  gap: var(--ux4g-space-2);
}

.ptv2_highlight_item {
  flex: 1 1 0;
  min-width: 130px;
  text-align: center;
  padding: var(--ux4g-space-5) var(--ux4g-space-6) var(--ux4g-space-4) var(--ux4g-space-6);
  border: 1px solid var(--ux4g-color-neutral-200);
  border-radius: var(--ux4g-space-4);
  background-color: var(--ux4g-color-neutral-50);
}

/* gradient tints per card */
.ptv2_highlight_item.tone-neutral {
  background: radial-gradient(60% 60% at 49.84% 0%, #E7F2FF 0%, var(--ux4g-color-neutral-0) 100%);
}

.ptv2_highlight_item.tone-pink {
  background: radial-gradient(60% 60% at 49.84% 0%, #FFECF6 0%, var(--ux4g-color-neutral-0) 100%);
}

.ptv2_highlight_item.tone-lime {
  background: radial-gradient(60% 60% at 49.84% 0%, #F2FFBF 0%, var(--ux4g-color-neutral-0) 100%);
}

.ptv2_highlight_item.tone-green {
  background: radial-gradient(60% 60% at 49.84% 0%, var(--ux4g-color-green-100) 0%, var(--ux4g-color-neutral-0) 100%);
}

.ptv2_highlight_item.tone-orange {
  background: radial-gradient(60% 60% at 49.84% 0%, var(--ux4g-color-orange-100) 0%, var(--ux4g-color-neutral-0) 100%);
}

.ptv2_highlight_item.tone-red {
  background: radial-gradient(60% 60% at 49.84% 0%, var(--ux4g-color-red-100) 0%, var(--ux4g-color-neutral-0) 100%);
}

.ptv2_highlight_label {
  color: var(--ux4g-color-neutral-700);
  margin: 0 0 var(--ux4g-space-2);
}

.ptv2_highlight_value {
  color: var(--ux4g-color-neutral-900);
  margin: 0;
  gap: var(--ux4g-space-4);
}

.ptv2_highlight_badge {
  font-size: 10px;
  font-weight: 700;
  color: #218721;
  background-color: #D9F2D9;
  border-radius: 10px;
  padding: 2px var(--ux4g-space-3);
}

.ptv2_highlight_sep {
  align-self: center;
  color: var(--ux4g-color-neutral-500);
  font-size: 0.85rem;
}

/* ---------------------------------------------------------------------
   Beneficiary category rows (icon + label + count)
   --------------------------------------------------------------------- */
.ptv2_ben_total_label {
  text-align: center;
  font-size: 0.8rem;
  color: var(--ux4g-color-neutral-500);
  margin: var(--ux4g-space-5) 0 var(--ux4g-space-4);
}

/* Beneficiaries layout: donut (fixed) + cards (fill) — stacks on mobile */
.ptv2_ben_layout {
  display: flex;
  align-items: center;
  gap: var(--ux4g-space-6);
}

.ptv2_ben_donut {
  flex: 0 0 300px;
  max-width: 300px;
}

.ptv2_ben_cards {
  flex: 1 1 auto;
  min-width: 0;
}

/* Growth Monitoring layout: gauge (fixed) + stats (fill) — stacks on mobile */
.ptv2_gm_layout {
  display: flex;
  align-items: center;
  gap: var(--ux4g-space-6);
}

.ptv2_gm_gauge {
  flex: 0 0 350px;
  max-width: 350px;
}

.ptv2_gm_stats {
  flex: 1 1 auto;
  min-width: 0;
}

@media (max-width: 991px) {

  .ptv2_ben_layout,
  .ptv2_gm_layout {
    flex-direction: column;
    align-items: stretch;
  }

  .ptv2_ben_donut,
  .ptv2_gm_gauge {
    flex: none;
    max-width: none;
    margin-bottom: var(--ux4g-space-4);
  }
}

.ptv2_ben_grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--ux4g-space-4);
}

.ptv2_ben_item {
  display: flex;
  align-items: center;
  gap: var(--ux4g-space-4);
  padding: var(--ux4g-space-4) var(--ux4g-space-5);
  border: 1px solid var(--ux4g-color-neutral-200);
  border-radius: var(--ux4g-space-4);
  background-color: var(--ux4g-color-neutral-50);
}

.ptv2_ben_dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex: none;
}

.ptv2_ben_text {
  min-width: 0;
}

.ptv2_ben_label {
  font-size: 0.78rem;
  color: var(--ux4g-color-neutral-700);
  margin: 0;
}

.ptv2_ben_value {
  font-size: 1rem;
  font-weight: 700;
  color: var(--ux4g-color-neutral-900);
  margin: var(--ux4g-space-1) 0 0;
}

/* ---------------------------------------------------------------------
   Beneficiary detail cards (new design)
   --------------------------------------------------------------------- */
.ptv2_ben_children_head {
  text-align: center;
  color: var(--ux4g-color-neutral-900);
  margin: var(--ux4g-space-7) 0 var(--ux4g-space-7);
  position: relative;
}

/* .ptv2_ben_children_head:before {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  width: 450px;
  height: 1px;
  background-color: var(--ux4g-color-neutral-200);
} */

/* .ptv2_ben_children_head::after {
  content: '';
  position: absolute;
  top: 50%;
  right: 0;
  width: 450px;
  height: 1px;
  background-color: var(--ux4g-color-neutral-200);
} */

.ptv2_ben_children_head strong {
  color: var(--ux4g-color-neutral-900);
  margin-left: var(--ux4g-space-2);
}

.ptv2_bcards_row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--ux4g-space-4);
}

.ptv2_bcard {
  border-radius: var(--ux4g-space-4);
  padding: var(--ux4g-space-5);
  background-color: var(--ux4g-color-neutral-100);
  border: 1px solid var(--ux4g-color-neutral-200);

}

.ptv2_bcard_top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--ux4g-space-4);
}

.ptv2_bcard_head {
  display: flex;
  align-items: center;
  gap: var(--ux4g-space-3);
  min-width: 0;
}


.ptv2_bcard_icon_img {
  width: 22px;
  height: 22px;
  object-fit: contain;
  flex: none;
}

.ptv2_bcard_label {
  color: var(--ux4g-color-neutral-900);
  /* display: flex;
  align-items: center; */
}

.ptv2_bcard_value {
  color: var(--ux4g-color-neutral-900);
  white-space: nowrap;
}

/* ---------------------------------------------------------------------
   Info tooltip (dark bubble with pointer) — matches design
   --------------------------------------------------------------------- */
.ptv2_tooltip {
  position: relative;
  display: inline-flex;
  align-items: center;
  margin-left: var(--ux4g-space-2);
  cursor: pointer;
  outline: none;
}

.ptv2_tooltip .ptv2_info_icon {
  color: var(--ux4g-text-brand-primary-default-changed);
  font-size: 0.8rem;
}

.ptv2_tooltip_bubble {
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  background-color: #3a3a3a;
  color: #ffffff;
  font-size: 0.72rem;
  line-height: 1.3;
  font-weight: 400;
  padding: var(--ux4g-space-3) var(--ux4g-space-4);
  border-radius: var(--ux4g-space-3);
  max-width: 260px;
  white-space: normal;
  width: max-content;
  z-index: 60;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.15s ease,
    visibility 0.15s ease;
  box-shadow: 0 4px 12px rgba(23, 23, 23, 0.25);
}

/* pointer arrow */
.ptv2_tooltip_bubble::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: #3a3a3a;
}

.ptv2_tooltip:hover .ptv2_tooltip_bubble,
.ptv2_tooltip:focus .ptv2_tooltip_bubble,
.ptv2_tooltip:focus-within .ptv2_tooltip_bubble {
  opacity: 1;
  visibility: visible;
}

.ptv2_bcard_meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--ux4g-space-4);
  margin-top: var(--ux4g-space-2);
}

.ptv2_bcard_pct {
  color: var(--ux4g-color-neutral-500);
}

/* Boy / Girl split */
.ptv2_bcard_split {
  margin-top: var(--ux4g-space-4);
  border-top: 1px solid var(--ux4g-color-neutral-200);
  padding-top: var(--ux4g-space-4);
}

.ptv2_bcard_split_nums {
  display: flex;
  justify-content: space-between;
  font-size: 0.72rem;
  margin-bottom: var(--ux4g-space-2);
}

.ptv2_bcard_split_boy {
  color: var(--ux4g-color-blue-400);
}

.ptv2_bcard_split_girl {
  color: var(--ux4g-color-pink-400);
}

.ptv2_bcard_split_bar {
  display: flex;
  height: 8px;
  border-radius: 999px;
  overflow: hidden;
  background-color: var(--ux4g-color-neutral-200);
}

.ptv2_bcard_split_fill_boy {
  background-color: var(--ux4g-color-blue-400);
}

.ptv2_bcard_split_fill_girl {
  background-color: var(--ux4g-color-pink-400);
}

.ptv2_bcard_split_legend {
  display: flex;
  justify-content: space-between;
  color: var(--ux4g-color-neutral-700);
  margin-top: var(--ux4g-space-2);
}

.ptv2_bcard_split_leg.boy i {
  color: var(--ux4g-color-blue-400);
}

.ptv2_bcard_split_leg.girl i {
  color: #e8407a;
}

/* Aadhaar / ABHA style row */
.ptv2_ben_footer {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--ux4g-space-4);
  margin-top: var(--ux4g-space-5);
}

.ptv2_ben_footer_item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--ux4g-space-4);
  padding: var(--ux4g-space-4) var(--ux4g-space-5);
  border-radius: var(--ux4g-space-4);
  background-color: var(--ux4g-bg-primary-soft-changed);
}

/* ---------------------------------------------------------------------
   Gauges (circular progress)
   --------------------------------------------------------------------- */
.ptv2_gauge_row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--ux4g-space-5);
  justify-content: space-around;
  align-items: flex-start;
}

.ptv2_gauge {
  text-align: center;
  width: 130px;
}

.ptv2_gauge_ring {
  width: 80px;
  height: 80px;
  margin: 0 auto var(--ux4g-space-3);
}

.ptv2_gauge_label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--ux4g-color-neutral-700);
  margin: 0;
}

.ptv2_gauge_value {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--ux4g-color-neutral-900);
  margin: var(--ux4g-space-1) 0 0;
}

/* ---------------------------------------------------------------------
   Infra gauges (ring -> value -> trend -> label) — matches design
   --------------------------------------------------------------------- */
.ptv2_infra_gauge_row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--ux4g-space-5);
  justify-content: space-around;
  align-items: flex-start;
}

.ptv2_infra_gauge {
  text-align: center;
  flex: 1 1 0;
  min-width: 120px;
  max-width: 160px;
}

.ptv2_infra_gauge_ring {
  width: 113px;
  height: 113px;
  margin: 0 auto var(--ux4g-space-3);
  position: relative;
}

/* dark tooltip (count) shown when hovering the ring stroke.
   The progressbar is NOT dimmed/blurred — only this tooltip appears. */
.ptv2_infra_gauge_tip {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 10px);
  transform: translateX(-50%) translateY(4px);
  display: flex;
  flex-direction: column;
  gap: 2px;
  width: max-content;
  max-width: min(200px, 70vw);
  padding: 8px 12px;
  background-color: #262626;
  color: #ffffff;
  border-radius: 10px;
  box-shadow: 0 6px 18px rgba(23, 23, 23, 0.28);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.15s ease, transform 0.15s ease;
  pointer-events: none;
  z-index: 20;
}

/* little pointer under the tooltip */
.ptv2_infra_gauge_tip::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: #262626;
}

.ptv2_infra_gauge_tip_label {
  font-size: 0.75rem;
  color: #d4d4d4;
  white-space: nowrap;
}

.ptv2_infra_gauge_tip_count {
  color: #ffffff;
  white-space: nowrap;
}

/* reveal on hover/focus of the ring */
.ptv2_infra_gauge_ring:hover .ptv2_infra_gauge_tip,
.ptv2_infra_gauge_ring:focus-within .ptv2_infra_gauge_tip {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.ptv2_infra_gauge_value {
  color: var(--ux4g-color-neutral-900);
  margin: 0;
}

.ptv2_infra_gauge_label {
  color: var(--ux4g-color-neutral-700);
}

/* single large gauge variant (Saksham) */
.ptv2_infra_gauge.is-large {
  max-width: 220px;
}

.ptv2_infra_gauge.is-large .ptv2_infra_gauge_ring {
  width: 130px;
  height: 130px;
}

.ptv2_infra_gauge_value .CircularProgressbar-text {
  font-weight: 700 !important;
}

.ptv2_infra_gauge.is-large .ptv2_infra_gauge_value {
  margin-top: var(--ux4g-space-3);
}

/* ---------------------------------------------------------------------
   Semi (half-circle) gauge — Growth Monitoring
   --------------------------------------------------------------------- */
.ptv2_semi {
  text-align: center;
}

.ptv2_semi_arc {
  position: relative;
  width: 170px;
  margin: 0 auto;
}

.ptv2_semi_center {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  line-height: 1.25;
}

.ptv2_semi_value {
  color: var(--ux4g-color-neutral-900);
}

.ptv2_semi_sub {
  color: var(--ux4g-color-neutral-500);
}

.ptv2_semi_caption {
  color: var(--ux4g-color-neutral-700);
}

.ptv2_semi_trend {}

/* ---------------------------------------------------------------------
   Growth Monitoring stat cards
   --------------------------------------------------------------------- */
.ptv2_gm_grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--ux4g-space-4);
}

/* Growth stat card: centered vertical stack (label+info, %, count, trend) */
.ptv2_gm_stat {
  border-radius: var(--ux4g-space-4);
  padding: var(--ux4g-space-6) var(--ux4g-space-5);
  border: 1px solid transparent;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: var(--ux4g-space-3);
}

.ptv2_gm_stat.tone-warning {
  background-color: #fdf6e3;
}

.ptv2_gm_stat.tone-success {
  background-color: #eef8ee;
}

.ptv2_gm_stat.tone-info {
  background-color: var(--ux4g-bg-primary-soft-changed, #e6efff);
}

.ptv2_gm_stat.tone-pink {
  background-color: #fdeef3;
}

.ptv2_gm_stat_label {
  color: var(--ux4g-color-neutral-700);
  display: inline-flex;
  align-items: center;
  gap: var(--ux4g-space-2);
}

.ptv2_gm_stat_pct {
  color: var(--ux4g-color-neutral-900);
  margin: 0;
}

.ptv2_gm_stat_value {
  color: var(--ux4g-color-neutral-500);
}

@media (max-width: 991px) {
  .ptv2_gm_grid {
    grid-template-columns: 1fr 1fr 1fr;
  }

  .ptv2_ben_children_head:before {
    display: none;
  }

  .ptv2_ben_children_head::after {
    display: none;
  }
}

/* ---------------------------------------------------------------------
   Vertical bar / cylinder chart (AWC Operational, ECCE)
   --------------------------------------------------------------------- */
.ptv2_cyl_row {
  display: flex;
  justify-content: space-around;
  align-items: flex-end;
  gap: var(--ux4g-space-5);
  padding-top: var(--ux4g-space-6);
  min-height: 220px;
}

.ptv2_cyl {
  text-align: center;
  flex: 1;
  max-width: 130px;
}

.ptv2_cyl_bar {
  width: 46px;
  margin: 0 auto var(--ux4g-space-3);
  border-radius: var(--ux4g-space-4);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  color: var(--ux4g-text-white);
  font-size: 0.7rem;
  font-weight: 700;
  padding-top: var(--ux4g-space-3);
  box-shadow: inset 0 -6px 10px rgba(0, 0, 0, 0.08);
}

.ptv2_cyl_label {
  font-size: 0.75rem;
  color: var(--ux4g-color-neutral-700);
  margin: 0;
}

.ptv2_cyl_value {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--ux4g-color-neutral-900);
  margin: var(--ux4g-space-1) 0 0;
}

.ptv2_cyl_pct {
  font-size: 0.72rem;
  color: var(--ux4g-color-neutral-500);
  margin: 0;
}

/* ---------------------------------------------------------------------
   Tube chart (capsule with cap + gradient) — AWC Operational / ECCE
   --------------------------------------------------------------------- */
.ptv2_tube_row {
  display: flex;
  justify-content: space-around;
  align-items: flex-start;
  gap: var(--ux4g-space-5);
  padding-top: var(--ux4g-space-6);
}

.ptv2_tube {
  text-align: center;
  flex: 1;
  max-width: 150px;
  position: relative;
}

/* the outer capsule = the light "cap" background */
.ptv2_tube_track {
  position: relative;
  width: 40px;
  height: 150px;
  margin: 0 auto var(--ux4g-space-4);
  border-radius: 4px;
  background-color: var(--ux4g-color-neutral-200);
  overflow: hidden;
  display: flex;
  align-items: flex-end;
}

.ptv2_tube_fill {
  display: block;
  width: 100%;
  border-radius: 4px;
}

/* dark tooltip (count) shown when hovering the tube fill/track — same look
   as the infra gauge tooltip. Sits above the capsule; it's a sibling of the
   track so the track's overflow clip doesn't affect it. */
.ptv2_tube_tip {
  position: absolute;
  left: 50%;
  top: -6px;
  transform: translate(-50%, -100%) translateY(4px);
  display: flex;
  flex-direction: column;
  gap: 2px;
  width: max-content;
  /* max-width: min(200px, 70vw); */
  padding: 8px 12px;
  background-color: #262626;
  color: #ffffff;
  border-radius: 10px;
  box-shadow: 0 6px 18px rgba(23, 23, 23, 0.28);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.15s ease, transform 0.15s ease;
  pointer-events: none;
  z-index: 20;
}

.ptv2_tube_tip::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: #262626;
}

.ptv2_tube_tip_label {
  font-size: 0.75rem;
  color: #d4d4d4;
  white-space: nowrap;
}

.ptv2_tube_tip_count {
  color: #ffffff;
  white-space: nowrap;
}

/* reveal when hovering the capsule (track); fill is left untouched */
.ptv2_tube_track:hover~.ptv2_tube_tip,
.ptv2_tube_track:focus-within~.ptv2_tube_tip {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, -100%) translateY(0);
}

.ptv2_tube_label {
  color: var(--ux4g-color-neutral-700);
  margin: 0 0 var(--ux4g-space-2);
}

.ptv2_tube_value {
  color: var(--ux4g-color-neutral-900);
  margin: 0;
}

.ptv2_tube_pct {
  color: var(--ux4g-color-neutral-700);
  margin: var(--ux4g-space-2) 0 0;
}

/* ---------------------------------------------------------------------
   Progress bars (nutrition)
   --------------------------------------------------------------------- */
.ptv2_progress_row {
  margin-bottom: var(--ux4g-space-5);
}

.ptv2_progress_head {
  display: flex;
  justify-content: space-between;
  font-size: 0.82rem;
  color: var(--ux4g-color-neutral-700);
  margin-bottom: var(--ux4g-space-2);
}

.ptv2_progress_head strong {
  color: var(--ux4g-color-neutral-900);
}

.ptv2_progress_track {
  height: 10px;
  border-radius: 999px;
  background-color: var(--ux4g-color-neutral-200);
  overflow: hidden;
}

.ptv2_progress_fill {
  height: 100%;
  border-radius: 999px;
  background-color: var(--ux4g-color-primary-800-changed);
}

.ptv2_progress_fill.is-warning {
  background-color: var(--ux4g-color-yellow-600);
}

.ptv2_progress_fill.is-success {
  background-color: var(--ux4g-color-green-600);
}

/* small stat cards inside nutrition */
.ptv2_mini_cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--ux4g-space-3);
  margin: var(--ux4g-space-5) 0;
}

.ptv2_mini_card {
  border: 1px solid var(--ux4g-color-neutral-200);
  border-radius: var(--ux4g-space-4);
  padding: var(--ux4g-space-4);
  text-align: center;
  background-color: var(--ux4g-color-neutral-50);
}

.ptv2_mini_card_label {
  font-size: 0.68rem;
  color: var(--ux4g-color-neutral-500);
  margin: 0 0 var(--ux4g-space-2);
}

.ptv2_mini_card_value {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--ux4g-color-neutral-900);
  margin: 0;
}

/* ---------------------------------------------------------------------
   Supplementary Nutrition Programme (SNP)
   --------------------------------------------------------------------- */
/* distribution progress rows */
/* ---------------------------------------------------------------------
   SNP single-card split layout: distribution rows (left) + flow (right)
   --------------------------------------------------------------------- */
.ptv2_snp_split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--ux4g-space-7);
  align-items: start;
}

.ptv2_snp_split_left {
  min-width: 0;
}

.ptv2_snp_split_right {
  min-width: 0;
}

/* keep the flow cards aligned with the distribution rows (no extra top gap) */
.ptv2_snp_split_right .ptv2_snp_flow {
  margin-top: 0;
}

@media (max-width: 991px) {
  .ptv2_snp_split {
    grid-template-columns: 1fr;
    gap: var(--ux4g-space-5);
  }
}

.ptv2_snp_row {
  margin-bottom: var(--ux4g-space-6);
}

.ptv2_snp_row_head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--ux4g-space-4);
  margin-bottom: var(--ux4g-space-3);
}

.ptv2_snp_row_left {
  display: flex;
  flex-direction: column;
  gap: var(--ux4g-space-1);
}

.ptv2_snp_row_label {
  color: var(--ux4g-color-neutral-900);
}

.ptv2_snp_row_right {
  text-align: right;
}

.ptv2_snp_row_value {
  display: block;
  color: var(--ux4g-color-neutral-900);
}

.ptv2_snp_row_pct {
  display: block;
  color: var(--ux4g-color-neutral-500);
}

.ptv2_snp_track {
  height: 9px;
  border-radius: 999px;
  background-color: var(--ux4g-color-neutral-200);
  overflow: hidden;
}

.ptv2_snp_fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #D0E4FF 0.08%, #76ACFF 99.92%);
  /* blue (Eligible) */
}

.ptv2_snp_fill.is-warning {
  background: linear-gradient(90deg, #E8FF99 0.08%, #D4F24D 99.92%);
  /* yellow-green (>15 days) */
}

.ptv2_snp_fill.is-success {
  background: linear-gradient(90deg, #BEEFBB 0.09%, #44C265 99.91%);
  /* green (>21 days) */
}

/* ---------------------------------------------------------------------
   Home Visit rows (scheduled block + visited block with bar)
   --------------------------------------------------------------------- */
.ptv2_hv_row {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: var(--ux4g-space-5);
  align-items: center;
  border-radius: var(--ux4g-space-4);
  padding: var(--ux4g-space-5);
  margin-bottom: var(--ux4g-space-4);
}

.ptv2_hv_row.tone-info {
  background-color: var(--ux4g-bg-secondary-links-50);
  border: 1px solid var(--ux4g-bg-Colors-Blue-100)
}

.ptv2_hv_row.tone-pink {
  background-color: #fdeef2;
}

.ptv2_hv_left_label {
  color: var(--ux4g-color-neutral-700);
  margin: 0 0 var(--ux4g-space-2);
}

.ptv2_hv_left_value {
  color: var(--ux4g-color-neutral-900);
  margin: 0;
}

.ptv2_hv_right_head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--ux4g-space-4);
}

.ptv2_hv_right_label {
  color: var(--ux4g-color-neutral-900);
}

.ptv2_hv_right_value {
  color: var(--ux4g-color-neutral-900);
}

.ptv2_hv_right_meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--ux4g-space-4);
  margin: var(--ux4g-space-2) 0;
}

.ptv2_hv_right_pct {
  color: var(--ux4g-color-neutral-500);
}

.ptv2_hv_track {
  height: 9px;
  border-radius: 999px;
  background-color: var(--ux4g-color-neutral-200);
  overflow: hidden;
}

.ptv2_hv_fill {
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, #beefbb 5.56%, #44c265 93.89%);
}

/* View All link */
.ptv2_view_all {
  display: block;
  text-align: right;
  color: var(--ux4g-text-brand-primary-default-changed);
  margin: var(--ux4g-space-3) 0;
  text-decoration: none;
}

.ptv2_view_all:hover {
  text-decoration: underline;
}

/* Districts list modal */
.ptv2_modal_backdrop {
  position: fixed;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.8);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1050;
  padding: var(--ux4g-space-6);
}

.ptv2_modal {
  background-color: var(--ux4g-color-neutral-0, #fff);
  border-radius: var(--ux4g-space-6);
  width: 100%;
  max-width: 560px;
  max-height: 80vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 12px 40px rgba(23, 23, 23, 0.25);
}

.ptv2_modal_head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--ux4g-space-6);
  border-bottom: 1px solid var(--ux4g-color-neutral-200);
}

.ptv2_modal_title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--ux4g-color-neutral-900);
  margin: 0;
}

.ptv2_modal_close {
  background: transparent;
  border: none;
  font-size: 1.4rem;
  line-height: 1;
  color: var(--ux4g-color-neutral-500);
  cursor: pointer;
  padding: 0 var(--ux4g-space-2);
}

.ptv2_modal_close:hover {
  color: var(--ux4g-color-neutral-900);
}

.ptv2_modal_summary {
  padding: var(--ux4g-space-5) var(--ux4g-space-6);
  background-color: #EDF3FF;
}

.ptv2_modal_summary_inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--ux4g-color-neutral-800, #262626);
  font-size: 0.85rem;
}

.ptv2_modal_summary strong {
  font-size: 1.05rem;
  color: var(--ux4g-color-neutral-900);
}

.ptv2_modal_table_head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--ux4g-space-4) var(--ux4g-space-6);
  font-size: 12px;
  font-weight: 400;
  color: #7C7B7B;
}

.ptv2_modal_body {
  overflow-y: auto;
}

.view_all_dist_text {
  font-size: 16px;
  font-weight: 700;
  line-height: 20px;
  color: var(--ux4g-color-neutral-900);
}

.ptv2_modal_row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--ux4g-space-4) var(--ux4g-space-6);
  color: var(--ux4g-color-neutral-900);
  background-color: #EDF3FF;
  margin-bottom: var(--ux4g-space-4);
  font-size: 14px;
  font-weight: 400;
}

.ptv2_modal_empty {
  padding: var(--ux4g-space-7);
  text-align: center;
  color: var(--ux4g-color-neutral-500);
  font-size: 0.85rem;
}

@media (max-width: 480px) {
  .ptv2_hv_row {
    grid-template-columns: 1fr;
  }
}

/* flow cards */
.ptv2_snp_flow {
  display: flex;
  align-items: stretch;
  gap: var(--ux4g-space-3);
  margin: var(--ux4g-space-6) 0;
}

.ptv2_snp_flow_card {
  flex: 1;
  text-align: center;
  border-radius: var(--ux4g-space-4);
  padding: var(--ux4g-space-5) var(--ux4g-space-4);
  border: 1px solid transparent;
}

.ptv2_snp_flow_card.tone-info {
  background-color: var(--ux4g-bg-secondary-links-50);
  border: 1px solid var(--ux4g-bg-Colors-Blue-100, #E7F2FF)
}

.ptv2_snp_flow_card.tone-warning {
  background-color: var(--ux4g-color-orange-50);
  border: 1px solid var(--ux4g-color-orange-100, #FFE7BF)
}

.ptv2_snp_flow_card.tone-success {
  background-color: var(--ux4g-color-green-50);
  border: 1px solid var(--ux4g-color-green-100, #DDF8D8)
}

.ptv2_snp_flow_icon {
  font-size: 1.1rem;
  display: inline-flex;
  margin-bottom: var(--ux4g-space-2);
}

.ptv2_snp_flow_card.tone-info .ptv2_snp_flow_icon {
  color: var(--ux4g-text-brand-primary-default-changed, #2661e0);
}

.ptv2_snp_flow_card.tone-warning .ptv2_snp_flow_icon {
  color: #e8935b;
}

.ptv2_snp_flow_card.tone-success .ptv2_snp_flow_icon {
  color: #128937;
}

.ptv2_snp_flow_icon img {
  width: 24px;
  height: 24px;
  object-fit: contain;
}

.ptv2_snp_flow_label {
  color: var(--ux4g-color-neutral-700);
  margin: 0 0 var(--ux4g-space-3);
}

.ptv2_snp_flow_value {
  color: var(--ux4g-color-neutral-900);
  margin: 0 0 var(--ux4g-space-3);
}

.ptv2_snp_flow_pct {
  color: var(--ux4g-color-neutral-500);
  margin: var(--ux4g-space-3) 0;
}

.ptv2_snp_flow_arrow {
  align-self: center;
  color: var(--ux4g-color-neutral-500);
  flex: none;
}

/* trend card (title + toggle + legend) */
.ptv2_trendcard {
  margin-top: var(--ux4g-space-5);
}

.ptv2_trendcard_head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--ux4g-space-4);
  margin-bottom: var(--ux4g-space-3);
}

.ptv2_trendcard_title {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--ux4g-color-neutral-900);
}

.ptv2_trendcard_toggle {
  display: inline-flex;
  gap: var(--ux4g-space-2);
}

.ptv2_range_btn {
  background: transparent;
  border: none;
  color: var(--ux4g-color-neutral-500);
  cursor: pointer;
  padding: var(--ux4g-space-1) var(--ux4g-space-2);
}

.ptv2_range_btn.active {
  color: var(--ux4g-text-brand-primary-default-changed, #2661e0);
}

.ptv2_range_btn:focus-visible {
  outline: 2px solid var(--ux4g-border-color-neutral-focus);
  outline-offset: 2px;
}

.ptv2_trendcard_legend {
  display: flex;
  gap: var(--ux4g-space-5);
  margin-bottom: var(--ux4g-space-3);
}

.ptv2_trendcard_leg {
  display: inline-flex;
  align-items: center;
  gap: var(--ux4g-space-2);
  font-size: 0.72rem;
  color: var(--ux4g-color-neutral-700);
}

.ptv2_trendcard_leg_dot {
  width: 14px;
  height: 4px;
  border-radius: 999px;
  display: inline-block;
}

/* keep the flow cards in one row on tablet/iPad; only stack on phones */
@media (max-width: 575px) {
  .ptv2_snp_flow {
    flex-direction: column;
  }

  .ptv2_snp_flow_arrow {
    transform: rotate(90deg);
  }
}

/* ---------------------------------------------------------------------
   Generic stat blocks (pills w/ colored dot)
   --------------------------------------------------------------------- */
.ptv2_stat_grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: var(--ux4g-space-4);
}

.ptv2_stat {
  border: 1px solid var(--ux4g-color-neutral-200);
  border-radius: var(--ux4g-space-4);
  padding: var(--ux4g-space-4);
  background-color: var(--ux4g-color-neutral-50);
}

.ptv2_stat_label {
  display: flex;
  align-items: center;
  gap: var(--ux4g-space-3);
  font-size: 0.8rem;
  color: var(--ux4g-color-neutral-700);
  margin: 0 0 var(--ux4g-space-2);
}

.ptv2_stat_value {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ux4g-color-neutral-900);
  margin: 0;
}

.ptv2_dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
  flex: none;
}

/* ---------------------------------------------------------------------
   Two-column grid inside a section
   --------------------------------------------------------------------- */
.ptv2_grid_2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: var(--ux4g-space-8);
}

/* Anganwadi Infrastructure (wide) + AWC Operational Status (narrow) side by
   side — wide left, narrower right, matching the design. */
.ptv2_grid_80_20 {
  display: grid;
  grid-template-columns: 1.8fr 1fr;
  gap: var(--ux4g-space-8);
  align-items: stretch;
}

/* let the two cards in this row match heights */
.ptv2_grid_80_20 > .ptv2_card {
  height: 100%;
}

@media (max-width: 992px) {
  .ptv2_grid_80_20 {
    grid-template-columns: 1fr;
  }

  .ptv2_ben_children_head:before {
    display: none;
  }

  .ptv2_ben_children_head::after {
    display: none;
  }
}

.ptv2_section_title {
  color: var(--ux4g-color-neutral-900);
  margin: 0 0 var(--ux4g-space-2);
}

.ptv2_chart_box {
  position: relative;
  width: 100%;
}

/* ---------------------------------------------------------------------
   Convergence rings
   --------------------------------------------------------------------- */
.ptv2_conv_grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--ux4g-space-5);
}

.ptv2_conv_item {
  display: flex;
  align-items: center;
  gap: var(--ux4g-space-6);
  border: 1px solid var(--ux4g-color-neutral-200);
  border-radius: var(--ux4g-space-5);
  padding: var(--ux4g-space-5) var(--ux4g-space-6);
  background-color: var(--ux4g-color-neutral-50);
}

.ptv2_conv_ring {
  width: 76px;
  height: 76px;
  flex: none;
  position: relative;
}

.ptv2_conv_tip {
  position: absolute;
  left: 0;
  bottom: calc(100% + 10px);
  transform: translateY(4px);
  display: flex;
  flex-direction: column;
  gap: 2px;
  width: max-content;
  max-width: 200px;
  padding: 8px 12px;
  background-color: var(--ux4g-color-neutral-800);
  color: var(--ux4g-color-neutral-0);
  border-radius: 10px;
  box-shadow: 0 6px 18px rgba(23, 23, 23, 0.28);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.15s ease, transform 0.15s ease;
  pointer-events: none;
  z-index: 20;
}

/* pointer sits under the ring center (ring is 76px wide → 38px) */
.ptv2_conv_tip::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 38px;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: var(--ux4g-color-neutral-800);
}

.ptv2_conv_tip_label {
  font-size: 0.75rem;
  color: #d4d4d4;
  line-height: 1.5;
}

.ptv2_conv_tip_count {
  color: var(--ux4g-color-neutral-0);
  word-break: break-word;
}

.ptv2_conv_ring:hover .ptv2_conv_tip,
.ptv2_conv_ring:focus-within .ptv2_conv_tip {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.ptv2_conv_text {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--ux4g-space-5);
}

.ptv2_conv_text_left {
  display: flex;
  flex-direction: column;
  gap: var(--ux4g-space-1);
}

.ptv2_conv_label {
  color: var(--ux4g-color-neutral-900);
  margin: 0;
}

.ptv2_conv_value {
  font-weight: 700 !important;
  color: var(--ux4g-color-neutral-900);
  margin: 0;
  white-space: nowrap;
}

/* value + optional sub-line stack, right aligned under the value */
.ptv2_conv_value_wrap {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  text-align: right;
}

.ptv2_conv_subline {
  color: var(--ux4g-color-neutral-500);
  margin: 2px 0 0;
}

@media (max-width: 991px) {
  .ptv2_conv_grid {
    grid-template-columns: 1fr 1fr;
  }


}

/* ---------------------------------------------------------------------
   Responsive tweaks
   --------------------------------------------------------------------- */
@media (max-width: 992px) {
  .ptv2_ben_grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .ptv2_bcards_row {
    grid-template-columns: repeat(2, 1fr);
  }

  .ptv2_mini_cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 991px) {
  .ptv2_body {
    padding: var(--ux4g-space-5);
  }

  .ptv2_highlights {
    flex-direction: column;
  }

  .ptv2_highlight_sep {
    display: none;
  }

  .ptv2_ben_grid {
    grid-template-columns: 1fr;
  }

  .ptv2_bcards_row {
    grid-template-columns: 1fr 1fr 1fr;
  }

  .ptv2_tab_btn {
    padding: var(--ux4g-space-4) var(--ux4g-space-7);
  }

  .ptv2_infra_gauge_row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
  }
}

/* =====================================================================
   RESPONSIVE LAYER (additive) — makes the dashboard work on all devices.
   Only adds rules; does not modify the desktop styles above.
   Breakpoints: 1200 (small desktop), 992 (tablet), 768 (large phone),
   576 (phone), 400 (small phone).
   ===================================================================== */

/* ---- Filter bar: the UX4G sm/md/lg grid classes handle column widths.
   Here we only fix the home-chip padding + reset-button margin when stacked. ---- */
@media (max-width: 1023px) {
  .ptv2_filter_home {
    padding-top: 0;
  }
}

@media (max-width: 576px) {
  .ptv2_filter_bar {
    padding: var(--ux4g-space-5) var(--ux4g-space-5);
  }

  .ptv2_reset_btn {
    margin-top: var(--ux4g-space-4);
  }
}

/* ---- Tabs: allow wrapping & shrink padding on phones ---- */
@media (max-width: 576px) {
  .ptv2_tabs_bar {
    flex-wrap: wrap;
    padding: var(--ux4g-space-4) var(--ux4g-space-4) 0;
  }

  .ptv2_tab_btn {
    padding: var(--ux4g-space-3) var(--ux4g-space-6);
    font-size: 0.82rem;
  }
}

/* ---- Cards: reduce padding on small screens ---- */
@media (max-width: 576px) {
  .ptv2_body {
    padding: var(--ux4g-space-4);
  }

  .ptv2_card {
    padding: var(--ux4g-space-5);
    border-radius: var(--ux4g-space-5);
  }

  .ptv2_card_head {
    margin-bottom: var(--ux4g-space-5);
  }

  /* keep title left and meta from overflowing */
  .ptv2_card_meta {
    text-align: left;
  }
}

/* ---- Highlights: 3 across on tablet, 2 on phone, 1 on small phone ---- */
@media (max-width: 1024px) {
  .ptv2_highlights {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--ux4g-space-3);
  }

  .ptv2_highlight_sep {
    display: none;
  }

  .ptv2_highlight_item {
    min-width: 0;
  }

  .ptv2_ben_children_head:before {
    display: none;
  }

  .ptv2_ben_children_head::after {
    display: none;
  }
}

@media (max-width: 991px) {

  /* existing rule sets .ptv2_highlights to column; override to a 2-col grid instead */
  .ptv2_highlights {
    display: grid;
    flex-direction: initial;
    grid-template-columns: 1fr 1fr 1fr;
  }
}

@media (max-width: 767px) {
  .ptv2_highlights {
    grid-template-columns: 1fr 1fr;
  }

  .ptv2_bcards_row {
    grid-template-columns: 1fr;
  }

  .ptv2_infra_gauge_row {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .ptv2_gm_grid {
    grid-template-columns: 1fr;
  }

  .ptv2_conv_grid {
    grid-template-columns: 1fr;
  }

  .ptv2_ben_children_head:before {
    display: none;
  }

  .ptv2_ben_children_head::after {
    display: none;
  }
}

/* ---- Beneficiary category grids already collapse; ensure footer stacks ---- */
@media (max-width: 576px) {
  .ptv2_ben_footer {
    grid-template-columns: 1fr;
  }

  .ptv2_ben_footer_item {
    flex-wrap: wrap;
  }
}

/* ---- Infra gauges: wrap into rows, keep readable size ---- */
@media (max-width: 991px) {
  .ptv2_infra_gauge {
    flex: 0 0 33.333%;
    max-width: none;
  }
}

@media (max-width: 480px) {
  .ptv2_infra_gauge {
    flex: 0 0 50%;
  }

  .ptv2_infra_gauge_ring {
    width: 78px;
    height: 78px;
  }
}

/* ---- Two-column section grids: stack below tablet ---- */
@media (max-width: 992px) {
  .ptv2_grid_2 {
    grid-template-columns: 1fr;
    gap: var(--ux4g-space-6);
  }
}

/* ---- Tube / cylinder charts: allow horizontal scroll instead of squashing ---- */
@media (max-width: 480px) {

  .ptv2_tube_row,
  .ptv2_cyl_row {
    gap: var(--ux4g-space-4);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    /* padding-top: 72px; */
  }

  .ptv2_tube,
  .ptv2_cyl {
    min-width: 88px;
  }

  /* keep the tooltip inside the row's padded headroom so it is not clipped:
     pin it near the top of the scroll box instead of floating above the
     capsule (which overflow-x:auto would cut off) */
  .ptv2_tube_tip {
    top: var(--ux4g-space-3, 6px);
    bottom: auto;
    transform: translate(-50%, 4px);
  }

  .ptv2_tube_track:hover ~ .ptv2_tube_tip,
  .ptv2_tube_track:focus-within ~ .ptv2_tube_tip {
    transform: translate(-50%, 0);
  }
}

/* ---- Home Visit rows already collapse at 480; tidy value alignment ---- */
@media (max-width: 480px) {
  .ptv2_hv_row {
    gap: var(--ux4g-space-3);
  }
}

/* ---- SNP mini cards: 2-up on phone ---- */
@media (max-width: 576px) {
  .ptv2_mini_cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ---- Trend card header + legend wrap on small screens ---- */
@media (max-width: 576px) {
  .ptv2_trendcard_head {
    flex-wrap: wrap;
    gap: var(--ux4g-space-2);
  }

  .ptv2_trendcard_legend {
    flex-wrap: wrap;
    gap: var(--ux4g-space-3);
  }
}

/* ---- Convergence: single column already at 768; tighten padding on phone ---- */
@media (max-width: 480px) {
  .ptv2_conv_item {
    padding: var(--ux4g-space-4);
    gap: var(--ux4g-space-4);
  }

  .ptv2_conv_text {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--ux4g-space-1);
  }

  .ptv2_conv_value {
    white-space: normal;
  }

  .ptv2_conv_value_wrap {
    align-items: flex-start;
    text-align: left;
  }
}

/* ---- Modal: full-width friendly on phones ---- */
@media (max-width: 576px) {
  .ptv2_modal {
    max-height: 88vh;
  }

  .ptv2_modal_backdrop {
    padding: var(--ux4g-space-4);
  }
}

/* ---- Chart canvases: never overflow their card ---- */
.ptv2_chart_box {
  max-width: 100%;
}

.ptv2_chart_box canvas {
  max-width: 100% !important;
}


/* =====================================================================
   Poshan Abhiyaan — two activity tiles (date range + label + count),
   same card shell as the other sections. Reuses the neutral tile look
   from the convergence items.
   ===================================================================== */
.ptv2_pa_grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--ux4g-space-6);
}

.ptv2_pa_item {
  border: 1px solid var(--ux4g-color-neutral-200);
  border-radius: var(--ux4g-space-5);
  padding: var(--ux4g-space-5) var(--ux4g-space-6);
  background-color: var(--ux4g-color-neutral-50);
}

.ptv2_pa_daterange {
  display: block;
  color: var(--ux4g-color-neutral-500);
  margin-bottom: var(--ux4g-space-3);
}

.ptv2_pa_row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--ux4g-space-5);
}

.ptv2_pa_label {
  color: var(--ux4g-color-neutral-900);
  margin: 0;
}

.ptv2_pa_value {
  color: var(--ux4g-color-neutral-900);
  font-weight: 700 !important;
  margin: 0;
  white-space: nowrap;
}

/* stack the two tiles on small screens */
@media (max-width: 767px) {
  .ptv2_pa_grid {
    grid-template-columns: 1fr;
  }

  .ptv2_pa_row {
    flex-wrap: wrap;
    gap: var(--ux4g-space-2);
  }
}
