.account-performance-panel {
  display: grid;
  gap: 10px;
  padding-bottom: 10px;
}

.account-performance-panel > .panel-heading {
  min-height: 44px;
  margin-bottom: 0;
}

.account-performance-range-controls {
  gap: 5px;
  padding: 0 14px 2px;
}

.account-performance-range-controls .balance-range-button {
  min-height: 29px;
  padding: 0 11px;
  font-size: 10px;
}

.account-performance-panel > .custom-balance-range {
  padding-right: 14px;
  padding-left: 14px;
}

.performance-headline-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 9px;
  padding: 0 14px;
}

.performance-headline-card {
  display: grid;
  min-width: 0;
  min-height: 94px;
  align-content: center;
  gap: 7px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: linear-gradient(145deg, #142119, #101a15 72%);
}

.performance-headline-card > span {
  color: #91a69a;
  font-size: 9px;
  font-weight: 740;
  letter-spacing: .09em;
}

.performance-headline-card > strong {
  overflow: hidden;
  color: #e4eee7;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: clamp(17px, 1.6vw, 22px);
  font-weight: 620;
  letter-spacing: -.04em;
  line-height: 1.15;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.performance-headline-card > strong.positive,
.performance-headline-meta > .positive { color: var(--green); }

.performance-headline-card > strong.negative,
.performance-headline-meta > .negative { color: var(--red); }

.performance-headline-card > small {
  overflow: hidden;
  color: #82938a;
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.performance-headline-meta {
  display: flex;
  min-width: 0;
  flex-wrap: wrap;
  gap: 2px 10px;
}

.performance-headline-meta > small {
  color: #9caea3;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 9px;
  white-space: nowrap;
}

.performance-stat-groups {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
  padding: 0 14px;
}

.performance-stat-group {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(15, 25, 19, .78);
}

.performance-stat-heading {
  display: flex;
  min-height: 42px;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 0 12px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, .018);
}

.performance-stat-heading h3 {
  overflow: hidden;
  margin: 0;
  color: #dce9e0;
  font-size: 11px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.performance-stat-heading > span {
  color: #81958a;
  font-size: 9px;
  white-space: nowrap;
}

.performance-stat-list {
  display: grid;
  padding: 0 12px;
}

.performance-stat-row {
  display: grid;
  min-width: 0;
  min-height: 35px;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid rgba(174, 210, 194, .07);
}

.performance-stat-row:last-child { border-bottom: 0; }

.performance-stat-label {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.performance-stat-label > span {
  overflow: hidden;
  color: #aebdb3;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.performance-stat-label > small {
  overflow: hidden;
  color: #73877b;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.performance-stat-row > strong {
  overflow: hidden;
  color: #e0eae3;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 10px;
  font-weight: 600;
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.performance-stat-row > strong.positive { color: var(--green); }
.performance-stat-row > strong.negative { color: var(--red); }

.performance-note {
  margin: 0 14px;
  color: #819389;
  font-size: 9px;
  line-height: 1.45;
}

@media (max-width: 1050px) {
  .performance-headline-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 720px) {
  .performance-stat-groups { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 600px) {
  .account-performance-panel { gap: 8px; }
  .account-performance-panel > .panel-heading { min-height: 42px; }
  .account-performance-range-controls { padding-right: 9px; padding-left: 9px; }
  .performance-headline-grid,
  .performance-stat-groups { gap: 7px; padding-right: 9px; padding-left: 9px; }
  .performance-headline-card { min-height: 82px; padding: 10px; }
  .performance-headline-card > strong { font-size: 16px; }
  .performance-stat-heading { min-height: 39px; }
  .performance-stat-row { min-height: 36px; }
  .performance-note { margin: 0 9px; }
}
