.rep-product-card .rep-card-compare { display: flex; align-items: center; justify-content: flex-end; gap: 4px; font-size: 12px; line-height: 16px; min-height: 16px; margin: 0; color: #526681; cursor: pointer; }
.rep-card-compare input { width: 12px; height: 12px; margin: 0; accent-color: #075ff7; }
/* Keep the agreed compact card size while adding the footer control. */
:is(.rep-category-page,.rep-home-products) .rep-product-card:has(.rep-card-compare) .rep-product-card__price { margin-top: 6px; }
:is(.rep-category-page,.rep-home-products) .rep-product-card:has(.rep-card-compare) .rep-product-card__content { padding-bottom: 6px; }
.rep-compare-tray[hidden] { display: none; }
.rep-compare-tray { position: fixed; bottom: 0; left: 0; right: 0; z-index: 900; display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 12px max(16px,calc((100vw - 1400px)/2)); background: #fff; border-top: 1px solid #ccd9eb; box-shadow: 0 -3px 14px #001f3f15; }
.rep-compare-tray [data-compare-selected] { display: flex; gap: 6px; flex: 1; min-width: 160px; overflow-x: auto; }
.rep-compare-tray [data-compare-remove] { background: #f2f6fa; color: #001f3f; border: 1px solid #d8e1ec; font-size: 11px; line-height: 16px; min-height: 32px; padding: 6px 8px; max-width: 170px; flex: 0 0 150px; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.rep-compare-tray > :is(button,a) { min-height: 36px; width: auto; font-size: 13px; padding: 8px 12px; line-height: 20px; }
.rep-compare-tray [data-compare-status] { width: 100%; margin: 0; font-size: 12px; }
.rep-compare-tray [data-compare-status]:empty { display: none; }
.rep-compare-active { padding-bottom: 110px; }
.rep-compare-active .rep-wishlist-notice { bottom: 120px; }
.rep-compare-scroll { position: relative; margin-top: 20px; max-width: 100%; min-width: 0; overflow: auto; isolation: isolate; }
.rep-compare-scroll table { border-collapse: separate; border-spacing: 0; table-layout: fixed; width: max-content; }
.rep-compare-scroll th,.rep-compare-scroll td { width: 264px; min-width: 264px; max-width: 264px; box-sizing: border-box; padding: 12px; border-bottom: 1px solid #d8e1ec; border-right: 1px solid #d8e1ec; text-align: left; vertical-align: top; overflow-wrap: anywhere; font-size: 13px; font-weight: 400; }
.rep-compare-scroll tr > :first-child { position: sticky; left: 0; z-index: 1; width: 150px; min-width: 150px; max-width: 150px; background: #f2f6fa; font-weight: 600; }
.rep-compare-scroll tbody tr:nth-child(even) { background: #f7f9fb; }
.rep-compare-scroll .rep-product-card { width: 240px; }
.rep-compare-scroll th > button { margin-top: 8px; background: transparent; border: 0; color: #526681; font-size: 12px; min-height: 28px; padding: 4px; text-decoration: underline; }
.rep-compare-page > h1,.rep-compare-dialog__header h2 { font-size: 20px; line-height: 28px; font-weight: 700; margin: 0; }
.rep-compare-page > p,.rep-compare-page > label { font-size: 13px; line-height: 20px; }
.rep-compare-scroll th,.rep-compare-scroll td { font-size: 12px; line-height: 18px; }
html.rep-compare-modal-open { overflow: hidden; }
dialog.rep-compare-dialog { box-sizing: border-box; width: min(1400px,calc(100vw - 32px)); max-width: none; max-height: calc(100dvh - 32px); margin: auto; padding: 20px; border: 1px solid #d8e1ec; border-radius: 10px; background: #fff; color: #001f3f; }
dialog.rep-compare-dialog::backdrop { background: #001f3f80; }
.rep-compare-dialog__header { display: flex; align-items: center; justify-content: space-between; gap: 16px; position: sticky; top: -20px; margin: -20px -20px 12px; padding: 14px 20px; background: #fff; border-bottom: 1px solid #d8e1ec; z-index: 3; }
.rep-compare-dialog__header [data-compare-close] { background: #f2f6fa; color: #001f3f; border: 1px solid #d8e1ec; border-radius: 6px; font-size: 13px; line-height: 20px; font-weight: 600; height: 34px; min-height: 34px; width: auto; padding: 6px 12px; white-space: nowrap; }
/* The comparison can live outside WooCommerce page wrappers. Keep rating
   geometry explicit, including the hidden text within Woo's fractional fill. */
.rep-compare-scroll .rep-product-card__rating .star-rating { position: relative; overflow: hidden; font-family: star; font-size: 14px; line-height: 1; width: 5.4em; height: 1em; letter-spacing: normal; }
.rep-compare-scroll .star-rating::before { content: 'sssss'; color: #cbd5e1; position: absolute; top: 0; left: 0; }
.rep-compare-scroll .star-rating > span { position: absolute; overflow: hidden; padding-top: 1.5em; top: 0; left: 0; float: left; }
.rep-compare-scroll .star-rating > span::before { content: 'SSSSS'; position: absolute; top: 0; left: 0; color: #f5bd00; }
.rep-compare-scroll .rep-product-card__rating-summary { font-size: 11px; line-height: 14px; font-weight: 600; }
@media(max-width:600px) {
 .rep-compare-tray [data-compare-selected] { flex-basis: 100%; }
 .rep-compare-scroll tr > :first-child { min-width: 110px; width: 110px; max-width: 110px; }
 .rep-compare-active { padding-bottom: 160px; }
}
