/* Make Disciples v3.32 — Custom Theme final isolation repair
   Covers the remaining Black & Gold surfaces visible in Warm Blush and the
   other four Custom Theme Studio palettes without changing Black & Gold. */

/* Destructive-data section: use a restrained theme-aware warning surface. */
body.custom-theme .settings-danger-zone{
  background:color-mix(in srgb,var(--danger) 8%,var(--custom-card))!important;
  color:var(--custom-text)!important;
  border-color:color-mix(in srgb,var(--danger) 42%,var(--custom-line))!important;
  border-radius:var(--custom-radius-card)!important;
  box-shadow:var(--custom-shadow)!important;
}
body.custom-theme .settings-danger-zone::before,
body.custom-theme .settings-danger-zone::after{display:none!important}
body.custom-theme .settings-danger-zone strong{color:var(--danger)!important;text-shadow:none!important}
body.custom-theme .settings-danger-zone span{color:var(--custom-muted)!important;opacity:1!important}
body.custom-theme :is(.action.danger,.history-action.danger,.toolbox-manage-actions button.danger){
  background:var(--danger)!important;
  color:#fff!important;
  border-color:var(--danger)!important;
  text-shadow:none!important;
}
body.custom-theme :is(.action.danger,.history-action.danger,.toolbox-manage-actions button.danger) svg{
  color:currentColor!important;stroke:currentColor!important;
}

/* Teaching Toolbox dropdown and nested management rows. */
body.custom-theme :is(.settings-toolbox-dropdown,.visit-resource-dropdown,.study-lesson-dropdown){
  background:var(--custom-card)!important;
  color:var(--custom-text)!important;
  border-color:var(--custom-line)!important;
  border-radius:var(--custom-radius-control)!important;
  box-shadow:var(--custom-shadow)!important;
}
body.custom-theme :is(.settings-toolbox-dropdown,.visit-resource-dropdown,.study-lesson-dropdown)::before,
body.custom-theme :is(.settings-toolbox-dropdown,.visit-resource-dropdown,.study-lesson-dropdown)::after{display:none!important}
body.custom-theme :is(.settings-toolbox-dropdown,.visit-resource-dropdown,.study-lesson-dropdown)>summary{
  background:color-mix(in srgb,var(--custom-primary) 7%,var(--custom-card))!important;
  color:var(--custom-text)!important;
  border-color:var(--custom-line)!important;
  text-shadow:none!important;
}
body.custom-theme :is(.settings-toolbox-dropdown,.visit-resource-dropdown,.study-lesson-dropdown)[open]>summary{
  background:color-mix(in srgb,var(--custom-primary) 13%,var(--custom-card))!important;
  border-bottom-color:var(--custom-line)!important;
}
body.custom-theme :is(.settings-toolbox-dropdown,.visit-resource-dropdown,.study-lesson-dropdown)>summary svg{
  color:var(--custom-primary)!important;stroke:currentColor!important;
}
body.custom-theme :is(.toolbox-manage-list,.toolbox-type-group){background:transparent!important;color:var(--custom-text)!important}
body.custom-theme .toolbox-manage-row{
  background:var(--custom-card-2)!important;
  color:var(--custom-text)!important;
  border-color:var(--custom-line)!important;
  border-radius:var(--custom-radius-control)!important;
  box-shadow:none!important;
}
body.custom-theme .toolbox-manage-copy strong,
body.custom-theme .toolbox-type-heading{color:var(--custom-text)!important}
body.custom-theme .toolbox-manage-copy span,
body.custom-theme .toolbox-type-heading span{color:var(--custom-muted)!important}
body.custom-theme .toolbox-manage-actions button:not(.danger){
  background:var(--custom-card)!important;
  color:var(--custom-primary)!important;
  border-color:var(--custom-line)!important;
  border-radius:var(--custom-radius-control)!important;
  box-shadow:none!important;
}

/* Service-year chooser and metric cards. */
body.custom-theme .time-year-controls>strong{
  background:var(--custom-card)!important;
  color:var(--custom-text)!important;
  border-color:var(--custom-line)!important;
  border-radius:var(--custom-radius-control)!important;
  box-shadow:var(--custom-shadow)!important;
  text-shadow:none!important;
}
body.custom-theme .metrics-grid .metric{
  background:var(--custom-card)!important;
  color:var(--custom-text)!important;
  border-color:var(--custom-line)!important;
}
body.custom-theme .metrics-grid .metric-icon{
  background:color-mix(in srgb,var(--custom-primary) 10%,var(--custom-card))!important;
  color:var(--custom-primary)!important;
  border-color:var(--custom-line)!important;
  box-shadow:none!important;
}
body.custom-theme .metrics-grid .metric-value{color:var(--custom-primary)!important;text-shadow:none!important}
body.custom-theme .metrics-grid .metric-label{color:var(--custom-text)!important;text-shadow:none!important}

/* Hours-by-month chart. */
body.custom-theme .time-chart-panel{
  background:var(--custom-card)!important;
  color:var(--custom-text)!important;
  border-color:var(--custom-line)!important;
  border-radius:var(--custom-radius-card)!important;
  box-shadow:var(--custom-shadow)!important;
}
body.custom-theme .time-chart-panel::before,
body.custom-theme .time-chart-panel::after{display:none!important}
body.custom-theme .time-chart-panel .section-heading h3{color:var(--custom-text)!important;text-shadow:none!important}
body.custom-theme .time-trend-value,
body.custom-theme .time-trend-column>span{color:var(--custom-muted)!important}
body.custom-theme .time-trend-bar-wrap{border-bottom-color:var(--custom-line)!important}
body.custom-theme .time-trend-bar{
  background:linear-gradient(180deg,var(--custom-primary),var(--custom-secondary))!important;
  border-color:color-mix(in srgb,var(--custom-primary) 62%,var(--custom-line))!important;
  box-shadow:0 0 7px color-mix(in srgb,var(--custom-primary) 18%,transparent)!important;
}

/* Any warning note still carrying Black & Gold's dark danger fill. */
body.custom-theme .settings-warning{
  background:color-mix(in srgb,var(--danger) 8%,var(--custom-card))!important;
  color:var(--custom-text)!important;
  border-color:color-mix(in srgb,var(--danger) 38%,var(--custom-line))!important;
}
body.custom-theme .settings-warning strong{color:var(--danger)!important}

/* Preserve intentionally dark preview swatches inside Appearance only. */
body.custom-theme .appearance-swatch,
body.custom-theme .cts-mini-theme{box-shadow:inherit}
