.profile-trends { display: grid; gap: 16px; min-width: 0; color: #172b3a; font-family: Arial, sans-serif; }
.profile-trends h2, .profile-trends h3, .profile-trends p { margin: 0; }
.profile-trends-heading h2 { font-size: 18px; margin-bottom: 6px; }
.profile-trends-heading p, .profile-trend-heading p { color: #667587; font-size: 13px; line-height: 1.5; }
.profile-trend-panel { min-width: 0; padding: 20px; border: 1px solid #e3ddeb; border-radius: 10px; background: #fff; }
.profile-trend-heading { display: flex; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; gap: 8px 16px; margin-bottom: 20px; }
.profile-trend-heading h3 { font-size: 16px; margin-bottom: 5px; }
.profile-trend-period { flex-shrink: 0; padding: 5px 9px; border-radius: 6px; background: #f6eef9; color: #510568; font-size: 12px; }
.profile-trend-period:empty { display: none; }
.profile-trend-content { display: grid; grid-template-columns: minmax(0, 1fr) 220px; gap: 20px; }
.profile-trend-canvas { position: relative; height: 280px; min-width: 0; }
.profile-trend-key { min-width: 0; }
.profile-trends .profile-trend-key-heading { display: flex; justify-content: space-between; gap: 8px; font-size: 12px; font-weight: bold; }
.profile-trend-key-heading span { color: #667587; font-weight: normal; }
.profile-trends .profile-trend-hint { margin-top: 5px; color: #667587; font-size: 11px; }
.profile-trend-legend { list-style: none; display: grid; gap: 4px; max-height: 230px; overflow-y: auto; padding: 0 4px 0 0; margin: 12px 0 0; }
.profile-trend-legend button { display: flex; align-items: center; gap: 8px; width: 100%; padding: 8px; border: 1px solid transparent; border-radius: 6px; background: #faf8fc; color: #172b3a; text-align: left; font: inherit; font-size: 12px; cursor: pointer; }
.profile-trend-legend button:hover { border-color: #d7c4e0; background: #f6eef9; }
.profile-trend-legend button:focus-visible { outline: 2px solid #510568; outline-offset: 2px; }
.profile-trend-legend button[aria-pressed="false"] { opacity: .55; }
.profile-trend-legend button[aria-pressed="false"] .profile-trend-label { text-decoration: line-through; }
.profile-trend-swatch { width: 16px; height: 3px; border-radius: 2px; flex-shrink: 0; }
.profile-trend-label { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.profile-trend-legend strong { color: #510568; font-variant-numeric: tabular-nums; }
.profile-trend-empty { padding: 24px 0; color: #667587; font-size: 13px; }
.profile-trends [hidden] { display: none !important; }
@media (max-width: 760px) {
    .profile-trend-panel { padding: 16px; }
    .profile-trend-content { grid-template-columns: minmax(0, 1fr); gap: 16px; }
    .profile-trend-canvas { height: 240px; }
    .profile-trend-legend { grid-template-columns: repeat(2, minmax(0, 1fr)); max-height: 160px; }
}
@media (max-width: 420px) {
    .profile-trend-legend { grid-template-columns: minmax(0, 1fr); }
}
