/* "My cashback on this card" on reviews: one panel with the total, a bar per statement and period totals. */
.lp-cb { --lp-cols: 28; padding: clamp(16px, 3vw, 24px); border: 1px solid var(--line); border-radius: 18px; background: var(--surface); }
.lp-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px 24px; }
.lp-total { display: grid; gap: 4px; margin: 0; }
.lp-total-v { font-size: clamp(2rem, 1.5rem + 2.4vw, 2.75rem); font-weight: 700; line-height: 1; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.lp-total-l { font-size: var(--rv-fs-small); color: var(--muted); }
.lp-stats { display: flex; gap: 24px; margin: 0; }
.lp-stats div { display: grid; gap: 2px; }
.lp-stats dt { font-size: var(--rv-fs-caption); color: var(--muted); }
.lp-stats dd { margin: 0; font-size: var(--rv-fs-lead); font-weight: 650; font-variant-numeric: tabular-nums; }

.lp-chart { position: relative; height: 150px; margin-block-start: 28px; border-block-end: 1px solid var(--line); }
.lp-bars { display: grid; grid-template-columns: repeat(var(--lp-cols), minmax(0, 1fr)); align-items: end; gap: 3px; height: 100%; margin: 0; padding: 0; list-style: none; }
.lp-bars li { position: relative; height: var(--h); min-height: 2px; border-radius: 4px 4px 1px 1px; background: var(--rv-brand); opacity: 0.88; cursor: default; outline: none; transform-origin: bottom; transition: opacity 160ms var(--ease, ease); }

.lp-bars:hover li { opacity: 0.4; }
.lp-bars li:hover, .lp-bars li:focus-visible { opacity: 1; }
.lp-bars li:focus-visible { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--focus); }
.lp-tip { position: absolute; z-index: 2; bottom: calc(100% + 8px); left: 50%; translate: -50% 4px; padding: 5px 8px; border-radius: 8px; background: var(--text); color: var(--page); font-size: var(--rv-fs-caption); white-space: nowrap; opacity: 0; pointer-events: none; transition: opacity 140ms var(--ease, ease), translate 140ms var(--ease, ease); }
.lp-tip b { margin-inline-start: 4px; font-weight: 650; font-variant-numeric: tabular-nums; }
.lp-bars li:hover .lp-tip, .lp-bars li:focus .lp-tip { opacity: 1; translate: -50% 0; }
.lp-bars li:nth-child(-n+3) .lp-tip { left: 0; translate: 0 4px; }
.lp-bars li:nth-child(-n+3):hover .lp-tip, .lp-bars li:nth-child(-n+3):focus .lp-tip { translate: 0 0; }
.lp-bars li:nth-last-child(-n+3) .lp-tip { left: auto; right: 0; translate: 0 4px; }
.lp-bars li:nth-last-child(-n+3):hover .lp-tip, .lp-bars li:nth-last-child(-n+3):focus .lp-tip { translate: 0 0; }

.lp-avg { position: absolute; z-index: 1; inset-inline: 0; bottom: var(--h); border-block-start: 1px dashed var(--muted); opacity: 0.7; pointer-events: none; }

.lp-yrs { display: grid; grid-template-columns: repeat(var(--lp-cols), minmax(0, 1fr)); gap: 3px; margin: 10px 0 0; padding: 0; list-style: none; }
.lp-yrs li { grid-column: span var(--n); display: grid; gap: 1px; padding-inline: 6px; border-inline-start: 1px solid var(--line); }
.lp-yrs li:first-child { padding-inline-start: 0; border: 0; }
.lp-yr { font-size: var(--rv-fs-caption); color: var(--muted); }
.lp-yr-v { font-size: var(--rv-fs-small); font-weight: 650; font-variant-numeric: tabular-nums; }
.lp-note { margin-block-start: 10px; font-size: var(--rv-fs-caption); color: var(--muted); }

@media (min-width: 640px) { .lp-chart { height: 180px; } .lp-bars, .lp-yrs { gap: 5px; } }

@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: view()) {
    .lp-bars li { animation: lp-grow linear both; animation-timeline: view(); animation-range: entry 10% cover 35%; }
  }
}
@keyframes lp-grow { from { transform: scaleY(0); } to { transform: scaleY(1); } }

/* Month labels under the bars when every bar sits in one year. */
.lp-mos li { padding-inline: 0; border: 0; text-align: center; }
@media (min-width: 640px) { .lp-few .lp-bars, .lp-few .lp-yrs { gap: 14px; } }

/* HSBC Live+ complimentary benefits: brand tile from HSBC's offer art beside the claim link. */
.lp-perks { display: flex; align-items: center; gap: 18px; margin-block-end: 16px; padding: 14px; border: 1px solid var(--line); border-radius: var(--rv-radius-md); background: var(--surface); }
.lp-perks img { display: block; flex: none; inline-size: 112px; block-size: 112px; border-radius: 16px; background: #0b0508; }
.lp-perks figcaption { font-size: var(--rv-fs-small); line-height: 1.5; color: var(--muted); }
.lp-perks figcaption strong { display: block; margin-block-end: 2px; font-size: 1rem; font-weight: 600; color: var(--text); }
