/* Rozmiarówka (/Size) */
.sz {
    --sz-text: #1e1e1e;
    --sz-muted: #6b6b6b;
    --sz-line: #ececec;
    --sz-soft: #f5f4f2;
    --sz-accent: #CD0000;
    padding: 24px 0 64px;
    color: var(--sz-text);
    font-family: 'Gilroy', sans-serif;
}

.sz *,
.sz *::before,
.sz *::after {
    letter-spacing: normal;
}

.sz-head {
    margin-bottom: 24px;
}

.sz .sz-title {
    margin: 0 0 6px;
    color: var(--sz-text);
    font-family: 'Gilroy', sans-serif;
    font-size: 32px;
    font-weight: 700;
    line-height: 1.2;
    text-transform: none;
}

.sz .sz-lead {
    margin: 0;
    color: var(--sz-muted);
    font-size: 15px;
    line-height: 1.5;
}

/* ---------- Kategorie ---------- */
.sz-scopes {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.sz .sz-scope {
    padding: 9px 18px;
    border: 1.5px solid #dcdcdc;
    border-radius: 999px;
    background: #fff;
    color: var(--sz-text);
    font-family: 'Gilroy', sans-serif;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
    cursor: pointer;
    transition: border-color .15s ease, background-color .15s ease, color .15s ease;
}

.sz .sz-scope:hover {
    border-color: var(--sz-text);
}

.sz .sz-scope.is-active {
    border-color: var(--sz-text);
    background: var(--sz-text);
    color: #fff;
}

.sz .sz-scope:focus-visible,
.sz .sz-item:focus-visible {
    outline: 2px solid var(--sz-accent);
    outline-offset: 2px;
}

body.sz-searching .sz-scope.is-active {
    border-color: #dcdcdc;
    background: #fff;
    color: var(--sz-text);
}

/* ---------- Wyszukiwanie ---------- */
.sz-search {
    position: relative;
    max-width: 360px;
    margin-bottom: 20px;
}

.sz-search .fa {
    position: absolute;
    top: 50%;
    left: 12px;
    color: #9a9a9a;
    font-size: 12px;
    transform: translateY(-50%);
    pointer-events: none;
}

.sz #sz-search {
    width: 100%;
    height: 36px;
    padding: 0 12px 0 32px;
    border: 1px solid transparent;
    border-radius: 999px;
    background: var(--sz-soft);
    color: var(--sz-text);
    font-size: 14px;
    font-weight: 500;
    box-shadow: none;
}

.sz #sz-search:focus {
    border-color: #cfcfcf;
    background: #fff;
    outline: none;
}

/* ---------- Rodzaje produktów ---------- */
.sz-panels {
    padding: 20px 24px 8px;
    border-radius: 14px;
    background: var(--sz-soft);
}

.sz-panel[hidden],
.sz-group[hidden],
.sz-items li[hidden],
.sz-empty[hidden] {
    display: none;
}

.sz .sz-panel-title {
    display: none;
    margin: 0 0 10px;
    color: var(--sz-text);
    font-family: 'Gilroy', sans-serif;
    font-size: 16px;
    font-weight: 700;
    text-transform: none;
}

body.sz-searching .sz .sz-panel-title {
    display: block;
}

.sz-groups {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 4px 32px;
}

.sz-group {
    margin-bottom: 16px;
}

.sz .sz-group-title {
    margin: 0 0 8px;
    color: var(--sz-muted);
    font-family: 'Gilroy', sans-serif;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: .08em !important;
    text-transform: uppercase;
}

.sz-items {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.sz .sz-item {
    display: inline-block;
    padding: 6px 12px;
    border: 1px solid #e2e0dc;
    border-radius: 999px;
    background: #fff;
    color: var(--sz-text);
    font-size: 14px;
    font-weight: 500;
    line-height: 1.3;
    text-decoration: none;
    transition: border-color .15s ease, color .15s ease;
}

.sz .sz-item:hover,
.sz .sz-item:focus {
    border-color: var(--sz-text);
    color: var(--sz-text);
    text-decoration: none;
}

.sz .sz-item.is-active {
    border-color: var(--sz-accent);
    background: var(--sz-accent);
    color: #fff;
}

.sz .sz-empty {
    margin: 0 0 16px;
    color: var(--sz-muted);
    font-size: 14px;
}

/* ---------- Tabela ---------- */
.sz-result {
    margin-top: 32px;
    scroll-margin-top: 70px;
}

.sz-result:focus {
    outline: none;
}

.sz .sz-result-path {
    margin: 0 0 4px;
    color: var(--sz-muted);
    font-size: 13px;
    font-weight: 600;
}

.sz .sz-result-title {
    margin: 0 0 16px;
    color: var(--sz-text);
    font-family: 'Gilroy', sans-serif;
    font-size: 24px;
    font-weight: 700;
    text-transform: none;
}

.sz-result-path[hidden],
.sz-result-title[hidden] {
    display: none;
}

.sz-table .row {
    margin-right: 0;
    margin-left: 0;
}

.sz-table .sr-text {
    color: var(--sz-muted);
    font-size: 14px;
}

.sz-table img {
    max-width: 100%;
    height: auto;
}

.sz-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 200px;
    border: 1.5px dashed #dcdcdc;
    border-radius: 14px;
    color: var(--sz-muted);
    text-align: center;
}

.sz-placeholder .fa {
    font-size: 26px;
}

.sz-placeholder p {
    margin: 0;
    font-size: 15px;
}

@media (max-width: 767px) {
    .sz .sz-title {
        font-size: 26px;
    }

    .sz-scopes {
        flex-wrap: nowrap;
        margin: 0 -15px 16px;
        padding: 0 15px;
        overflow-x: auto;
        scrollbar-width: none;
    }

    .sz .sz-scope {
        flex: none;
    }

    .sz-search {
        max-width: none;
    }

    .sz-panels {
        padding: 16px 16px 4px;
    }

    .sz-groups {
        grid-template-columns: minmax(0, 1fr);
    }

    .sz-table {
        overflow-x: auto;
    }
}
