/* Products list (front/products/list) + "load more" box. Classes start with "pl-" so the site theme can not override them. */
.pl {
    --pl-ink: #111111;
    --pl-muted: #7c828c;
    --pl-line: #ececec;
    --pl-accent: #fe7e00;
    --pl-accent-soft: #fff4e8;
    background: #f7f7f8; color: var(--pl-ink); padding: 18px 0 40px; font-size: 14px; line-height: 1.5;
}
.pl *, .pl *::before, .pl *::after { box-sizing: border-box; }
.pl a { text-decoration: none !important; }
.pl-container { width: 100%; max-width: 1440px; margin: 0 auto; padding: 0 12px; }
@media (min-width: 992px) { .pl-container { padding: 0 20px; } .pl { padding: 24px 0 56px; } }

.pl-crumbs { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--pl-muted); margin-bottom: 10px; }
.pl .pl-crumbs a { color: var(--pl-muted) !important; }
.pl .pl-crumbs a:hover { color: var(--pl-accent) !important; }
.pl-crumbs [aria-current] { color: var(--pl-ink); font-weight: 600; }

.pl-head { display: flex; flex-direction: column; gap: 12px; margin-bottom: 16px; }
.pl .pl-head h1 { margin: 0 !important; font-size: 22px; font-weight: 800; color: var(--pl-ink) !important; line-height: 1.4; }
.pl-tools { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }

/* filter pills */
.pl-filters { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; flex: 1 1 100%; padding-bottom: 2px; }
.pl-filters::-webkit-scrollbar { display: none; }
.pl .pl-filters a {
    flex: none; padding: 8px 18px; border-radius: 22px; border: 1.5px solid var(--pl-line); background: #fff;
    color: var(--pl-ink) !important; font-size: 14px; font-weight: 700; white-space: nowrap; transition: border-color .2s, background .2s, color .2s;
}
.pl .pl-filters a:hover { border-color: var(--pl-accent); color: var(--pl-accent) !important; }
.pl .pl-filters a.is-active { background: var(--pl-accent); border-color: var(--pl-accent); color: #fff !important; }

/* sort dropdown */
.pl-sort { position: relative; margin-inline-start: auto; }
.pl .pl-sort__btn {
    display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 14px; margin: 0; border-radius: 12px; cursor: pointer;
    border: 1.5px solid var(--pl-line); background: #fff; color: var(--pl-ink); font: inherit; font-size: 13px; white-space: nowrap;
}
.pl .pl-sort__btn:hover, .pl-sort.is-open .pl-sort__btn { border-color: var(--pl-accent); }
.pl-sort__btn svg { width: 18px; height: 18px; color: var(--pl-accent); }
.pl-sort__label { color: var(--pl-muted); }
.pl-sort__btn strong { font-weight: 700; }
.pl-sort__menu {
    position: absolute; top: calc(100% + 6px); inset-inline-end: 0; z-index: 50; min-width: 220px; list-style: none; margin: 0; padding: 6px;
    background: #fff; border-radius: 14px; box-shadow: 0 18px 40px rgba(17, 17, 17, .14);
    opacity: 0; visibility: hidden; transform: translateY(6px); transition: opacity .15s, transform .15s, visibility .15s;
}
.pl-sort.is-open .pl-sort__menu { opacity: 1; visibility: visible; transform: none; }
.pl .pl-sort__menu a { display: block; padding: 10px 12px; border-radius: 10px; color: var(--pl-ink) !important; font-size: 14px; font-weight: 600; }
.pl .pl-sort__menu a:hover { background: #f5f5f7; }
.pl .pl-sort__menu a.is-active { background: var(--pl-accent-soft); color: var(--pl-accent) !important; }

/* grid */
.pl-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.pl-grid__item { min-width: 0; }
@media (min-width: 768px) { .pl-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; } }
@media (min-width: 992px) {
    .pl-head { flex-direction: row; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
    .pl .pl-head h1 { font-size: 26px; }
    .pl-tools { flex-wrap: nowrap; }
    .pl-filters { flex: none; }
    .pl-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
}
@media (min-width: 1280px) { .pl-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); } }

/* load more */
.pl-more { --pl-accent: #fe7e00; --pl-muted: #7c828c; display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 26px 0 6px; min-height: 90px; }
.pl-more .pl-more__btn {
    display: inline-flex; align-items: center; justify-content: center; height: 44px; padding: 0 28px; border-radius: 22px;
    border: 1.5px solid var(--pl-accent); background: #fff; color: var(--pl-accent) !important; font-weight: 700; transition: background .2s, color .2s;
}
.pl-more .pl-more__btn:hover { background: var(--pl-accent); color: #fff !important; }
.pl-more__spinner { display: none; width: 30px; height: 30px; border-radius: 50%; border: 3px solid #ffe2c4; border-top-color: var(--pl-accent); animation: pl-spin .7s linear infinite; }
.pl-more.is-loading .pl-more__spinner { display: block; }
.pl-more.is-loading .pl-more__btn { pointer-events: none; border-color: transparent; background: none; }
.pl-more.is-error .pl-more__btn { border-color: #e5484d; color: #e5484d !important; }
.pl-more .pl-more__end { margin: 0 !important; color: var(--pl-muted) !important; font-size: 13px; }
@keyframes pl-spin { to { transform: rotate(360deg); } }

/* empty */
.pl-empty { text-align: center; padding: 50px 16px; background: #fff; border-radius: 20px; }
.pl-empty svg { width: 60px; height: 60px; color: var(--pl-accent); margin-bottom: 10px; }
.pl .pl-empty h2 { margin: 0 0 6px !important; font-size: 19px; font-weight: 800; color: var(--pl-ink) !important; }
.pl .pl-empty p { margin: 0 0 16px !important; color: var(--pl-muted) !important; }
.pl .pl-empty a { display: inline-block; padding: 10px 26px; border-radius: 22px; background: var(--pl-accent); color: #fff !important; font-weight: 700; }

@media (max-width: 575.98px) {
    .pl .pl-filters a { padding: 7px 15px; font-size: 13px; }
    .pl .pl-sort__btn { height: 36px; padding: 0 10px; }
    .pl-sort__label { display: none; }
}
