.dc-trends {
  --dc-bar: #357565;
  --dc-plan: #93612f;
  --dc-grid: #dbe4dc;
  --dc-height: clamp(104px, 13vw, 154px);
  min-width: 0;
  padding: clamp(15px, 2vw, 26px);
  border: 1px solid var(--line);
  border-radius: var(--round, 12px);
  background: var(--panel, white);
  color: var(--ink);
}
.dc-trends-head, .dc-detail-head, .dc-trend-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.dc-trends-heading h3 {
  margin: 0;
  font: 500 clamp(23px,2.5vw,31px)/1.15 var(--display);
  letter-spacing: -.03em;
}
[dir=rtl] .dc-trends-heading h3 {font-family: var(--sans); letter-spacing: 0}
.dc-trends-dates, .dc-trends-legend, .dc-trend-note, .dc-trend-coverage,
.dc-detail-head p, .dc-trend-empty, .dc-source-title small {color: var(--muted)}
.dc-trends-dates {display: inline-block; margin-block-start: 4px; font-size: 12px}
.dc-trends-range, .dc-trends-streams, .dc-trends-metrics {display: flex; align-items: center; flex-wrap: wrap}
.dc-trends-range {border: 1px solid var(--line); border-radius: 8px; padding: 2px; gap: 2px; background: #f6f7f3}
.dc-trends button {cursor: pointer}
.dc-trends :is(.dc-range-choice,.dc-stream-choice,.dc-metric-choice) {
  border: 0;
  border-radius: 6px;
  color: #48605d;
  background: transparent;
  font-size: 13px;
  font-weight: 580;
  padding: 7px 12px;
}
.dc-trends :is(.dc-range-choice,.dc-metric-choice):hover {background: #e8eeea}
.dc-trends .dc-range-choice[aria-pressed=true] {background: #fff; color: var(--ink); box-shadow: 0 1px 4px #182f342c}
.dc-trends-streams {gap: 5px; margin-block: 19px 11px; border-block-end: 1px solid var(--line); padding-block-end: 10px}
.dc-trends .dc-stream-choice {display: inline-flex; align-items: center; gap: 6px; padding: 8px 13px}
.dc-trends .dc-stream-choice:hover {background: #eaf1ea}
.dc-trends .dc-stream-choice[aria-pressed=true] {background: #193f40; color: #fff}
.dc-trends-metrics {gap: 5px}
.dc-trends .dc-metric-choice {padding: 5px 9px; font-size: 12px}
.dc-trends .dc-metric-choice[aria-pressed=true] {color: #235d50; background: #e5f0e9}
.dc-trend-summary {margin-block: 16px 10px; align-items: end}
.dc-trend-stat {display: grid; gap: 2px}
.dc-trend-stat-title,.dc-trend-coverage {font-size: 12px}
.dc-trend-stat-title {color: #546966; font-weight: 550}
.dc-trend-value {font: 540 clamp(22px,2.5vw,31px)/1.1 var(--sans); font-variant-numeric: tabular-nums}
.dc-trend-value small {margin-inline-start: 4px; font-size: 14px; color: #516a66; font-weight: 500}
.dc-trend-coverage {display: grid; text-align: end; gap: 3px; font-variant-numeric: tabular-nums}
.dc-trend-coverage small {font-size: 11px}
.dc-trends-chart {display: grid; grid-template-columns: max-content minmax(0,1fr); gap: 9px; padding-block-start: 7px}
.dc-trend-axis {height: var(--dc-height); display: flex; justify-content: space-between; flex-direction: column; font-size: 10px; color: #627572; text-align: end; line-height: 1}
.dc-trends-days {
  position: relative;
  grid-column: 2;
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(var(--dc-days), minmax(0, 1fr));
  isolation: isolate;
}
.dc-trends-days::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset-block-start: 0;
  inset-inline: 0;
  height: var(--dc-height);
  background: linear-gradient(to bottom, var(--dc-grid) 0 1px, transparent 1px calc(50% - .5px), var(--dc-grid) calc(50% - .5px) calc(50% + .5px), transparent calc(50% + .5px) calc(100% - 1px), var(--dc-grid) calc(100% - 1px));
}
.dc-trends .dc-trend-day {
  display: grid;
  grid-template-rows: var(--dc-height) 22px;
  justify-items: center;
  padding: 0;
  margin: 0;
  min-width: 0;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: #566c66;
  position: relative;
}
.dc-trend-day:hover {box-shadow: inset 0 0 0 1px #c5d4c8}
.dc-trends .dc-trend-day[aria-pressed=true] {background: #e0ece580}
.dc-trend-stack {position: relative; display: block; width: min(56%,38px); min-width: 3px; height: 100%}
.dc-trend-bar,.dc-trend-zero,.dc-trend-marker,.dc-trend-gap {position: absolute}
.dc-trend-bar {inset-inline: 0; bottom: 0; min-height: 1px; background: var(--dc-bar); border-radius: 3px 3px 0 0}
.dc-trend-zero {bottom: -2px; inset-inline: 0; margin: auto; width: 6px; height: 6px; background: #fff; border: 2px solid var(--dc-bar); border-radius: 50%}
.dc-trend-marker {inset-inline: -17%; height: 0; border-block-start: 2px dashed var(--dc-plan); transform: translateY(1px)}
.dc-trend-gap {bottom: 2px; inset-inline: 0; text-align: center; color: #788981; line-height: 1}
.dc-trend-axis-day {padding-block-start: 4px; font-size: 11px; line-height: 1.5; font-variant-numeric: tabular-nums}
.dc-trends-legend {display:flex; align-items:center; gap: 5px 16px; flex-wrap:wrap; margin-block-start: 8px; font-size: 11px}
.dc-trends-legend span {display: inline-flex; align-items: center; gap: 6px}
.dc-actual-key {width: 10px; height: 10px; background: var(--dc-bar); border-radius: 2px}
.dc-plan-key {width: 16px; height: 0; border-block-start: 2px dashed var(--dc-plan)}
.dc-gap-key {font-style: normal; font-weight: 650}
.dc-trend-note {margin: 5px 0 0; font-size: 12px}
.dc-trends-detail {margin-block-start: 16px; border-block-start: 1px solid var(--line); padding-block-start: 13px; min-width: 0}
.dc-detail-head {align-items: start}
.dc-detail-head h4,.dc-detail-head p {margin: 0}
.dc-detail-head h4 {font-size: 15px; line-height:1.3}
.dc-trends-source-date {display:flex; flex-wrap:wrap; align-items:center; gap:6px 10px}
.dc-trends-source-date select {background:var(--panel); color:var(--ink); border:1px solid var(--line-strong); border-radius:5px; max-width:100%; padding:4px; font-size:12px}
.dc-detail-head p {margin-block: 4px 6px; font-size: 12px; font-variant-numeric: tabular-nums}
.dc-detail-head .btn {min-height: 32px; font-size: 12px; padding: 5px 8px}
.dc-trend-empty {font-size: 13px; margin: 6px 0}
.dc-trends .dc-trend-source {
  width: 100%;
  display: grid;
  grid-template-columns: auto minmax(0,1fr) auto auto;
  gap: 8px;
  align-items: center;
  padding: 8px 9px;
  margin-block-start: 3px;
  text-align: start;
  background: #f6f8f4;
  color: var(--ink);
  border: 1px solid transparent;
  border-radius: 6px;
}
.dc-trends button.dc-trend-source:hover {border-color: var(--line-strong); background: #f1f5ee}
.dc-source-title {display: grid; gap: 1px; min-width: 0; overflow-wrap: anywhere}
.dc-source-title strong {font-size: 13px; font-weight: 610; line-height: 1.35}
.dc-source-title small,.dc-source-value {font-size: 11px}
.dc-source-value {color: #2b564b; font-weight: 600; text-align: end; font-variant-numeric: tabular-nums}
[dir=rtl] .dc-trend-source > svg:last-child {transform: scaleX(-1)}
.dc-trends button:focus-visible {position: relative; z-index: 1; outline: 2px solid #0a6758; outline-offset: 2px}
@media(max-width: 560px) {
  .dc-trends {padding: 14px}
  .dc-trends-head {gap: 9px}
  .dc-trends-streams {gap: 3px; margin-block-start: 14px}
  .dc-trends .dc-stream-choice {padding: 7px 8px}
  .dc-trends-chart {gap: 6px}
  .dc-trend-summary {align-items:start}
  .dc-trend-coverage {text-align: start}
}
@media(max-width: 370px) {
  .dc-trends .dc-stream-choice {font-size: 12px; padding: 5px 6px}
  .dc-stream-choice svg {display:none}
  .dc-source-value {max-width: 78px}
}
@media(prefers-contrast: more) {
  .dc-trends {--dc-grid: #778781; --dc-bar: #205746; --dc-plan: #804915}
  .dc-trends .dc-trend-day[aria-pressed=true] {outline: 1px solid var(--ink)}
}
