/* Loyalty plugin — structural styles. Colours come from the active theme's tokens. */
.ly-earn, .ly-card, .ly-account {
    --ly-primary: var(--color-theme-primary, var(--theme-primary, #4f46e5));
    --ly-on-primary: var(--color-theme-on-primary, var(--theme-on-primary, #fff));
    --ly-text: var(--color-theme-text, var(--theme-text, #18181b));
    --ly-muted: var(--color-theme-muted, var(--theme-text-muted, #71717a));
    --ly-border: var(--color-theme-border, var(--theme-border, #e4e4e7));
    --ly-surface: var(--color-theme-surface, var(--theme-surface, #fff));
    --ly-title-font: var(--font-title, inherit);
    color: var(--ly-text);
}
.ly-earn { display: flex; align-items: center; gap: .5rem; margin: .75rem 0 0; font-size: .875rem; color: var(--ly-text); }
.ly-earn strong { color: var(--ly-primary); }
.ly-icon { width: 1.125rem; height: 1.125rem; flex: none; color: var(--ly-primary); }
.ly-card { display: flex; flex-direction: column; gap: .5rem; border: 1px solid var(--ly-border); border-radius: 1rem; background: var(--ly-surface); padding: 1.25rem; text-align: left; font-size: .875rem; }
.ly-card *, .ly-card *::before, .ly-card *::after { box-sizing: border-box; }
.ly-cart { margin-top: 1rem; }
.ly-cart:empty { display: none; }
.ly-dashboard { flex-direction: row; align-items: center; justify-content: space-between; margin-top: 1.5rem; text-decoration: none; transition: border-color .2s; }
.ly-dashboard:hover { border-color: var(--ly-primary); }
.ly-dashboard > span:first-child { display: flex; flex-direction: column; }
.ly-row { display: flex; align-items: center; gap: .5rem; margin: 0; }
.ly-row strong { color: var(--ly-primary); }
.ly-between { justify-content: space-between; }
.ly-label { font-size: .75rem; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--ly-muted); }
.ly-title { font-family: var(--ly-title-font); font-size: 1.125rem; font-weight: 600; color: var(--ly-text); }
.ly-balance { font-family: var(--ly-title-font); font-size: 2rem; font-weight: 700; line-height: 1.1; color: var(--ly-primary); }
.ly-balance small { font-size: .875rem; font-weight: 500; color: var(--ly-muted); }
.ly-muted { color: var(--ly-muted); margin: 0; }
.ly-small { font-size: .75rem; }
.ly-warning { color: #b45309; font-weight: 600; }
.ly-error { color: #dc2626; font-size: .75rem; margin: 0; }
.ly-link { background: none; border: 0; padding: 0; cursor: pointer; color: var(--ly-primary); font-weight: 600; text-align: left; text-decoration: underline; text-underline-offset: 2px; }
.ly-applied { display: flex; align-items: center; justify-content: space-between; gap: .75rem; border-radius: .75rem; background: color-mix(in srgb, var(--ly-primary) 10%, transparent); padding: .625rem .75rem; color: var(--ly-text); }
.ly-form { display: flex; gap: .5rem; }
.ly-input { min-width: 0; flex: 1; border: 1px solid var(--ly-border); border-radius: .625rem; background: var(--ly-surface); padding: .5rem .75rem; color: var(--ly-text); font-size: .875rem; }
.ly-input:focus { outline: 2px solid var(--ly-primary); outline-offset: 1px; }
.ly-button { flex: none; border: 0; border-radius: .625rem; background: var(--ly-primary); padding: .5rem 1rem; color: var(--ly-on-primary); font-weight: 600; font-size: .875rem; cursor: pointer; }
.ly-button:disabled { opacity: .6; }
.ly-grid { display: grid; gap: 1rem; }
@media (min-width: 768px) { .ly-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } .ly-grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.ly-hero { background: color-mix(in srgb, var(--ly-primary) 8%, var(--ly-surface)); }
.ly-progress { height: .5rem; overflow: hidden; border-radius: 999px; background: var(--ly-border); }
.ly-progress span { display: block; height: 100%; border-radius: 999px; background: var(--ly-primary); }
.ly-list { margin: 0; padding-left: 1.125rem; list-style: disc; display: grid; gap: .25rem; }
.ly-table-wrap { overflow-x: auto; }
.ly-table { width: 100%; border-collapse: collapse; font-size: .875rem; }
.ly-table th { padding: .5rem; border-bottom: 1px solid var(--ly-border); text-align: left; font-size: .75rem; font-weight: 600; text-transform: uppercase; color: var(--ly-muted); }
.ly-table td { padding: .625rem .5rem; border-bottom: 1px solid var(--ly-border); vertical-align: top; }
.ly-table td .ly-small { display: block; }
.ly-right { text-align: right !important; white-space: nowrap; }
.ly-plus { color: #15803d; font-weight: 600; }
.ly-minus { color: #b91c1c; font-weight: 600; }
.ly-account { display: grid; gap: 1.5rem; }
.ly-pagination { margin-top: 1rem; }
