/*
 * TKA-PDP-TRUSTROW-01 · the trust row under the primary buy button. Added to the <head> by AddTrustRowStylesheet, only while
 * teakea_pdp/trustrow/enabled is on. Plain CSS in its own file (strict CSP, no rebuild of the tracked Tailwind file).
 * Columns follow the number of items shown (data-count on the list, kept up to date for a configurable) and the width of the
 * buy box (container query), so a lone item never sits on its own row (TKA-PDP-HOTFIX-WINDSOR-01, B2):
 *   1 item  one column            2 items  two columns (one in a very narrow box)
 *   3 items one column, three columns from sm (640 px)        4 items  2 x 2, four columns only from md (768 px)
 * Labels wrap over several lines (words are never broken, no automatic hyphens); every item is at least 44 px high.
 */
.tka-trustrow {
    container-type: inline-size;
    margin: 0.5rem 0 0;
}
.tka-trustrow[hidden],
.tka-trustrow__list > li[hidden] {
    display: none;
}
.tka-trustrow__sprite {
    position: absolute;
    width: 0;
    height: 0;
    overflow: hidden;
}
.tka-trustrow__list {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0.125rem 0.75rem;
    list-style: none;
    margin: 0;
    padding: 0;
}
/* one item: one full-width column; two items: two columns (the base rule of a box of 18.75rem and up, below that one column) */
.tka-trustrow__list[data-count="1"] {
    grid-template-columns: minmax(0, 1fr);
}
/* rem, not px: with larger text the box needs more room before a second column fits the longest word */
@container (min-width: 18.75rem) {
    .tka-trustrow__list,
    .tka-trustrow__list[data-count="2"] {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .tka-trustrow__list[data-count="1"] {
        grid-template-columns: minmax(0, 1fr);
    }
    /* three items: one column until three fit side by side, never 2 + 1 */
    .tka-trustrow__list[data-count="3"] {
        grid-template-columns: minmax(0, 1fr);
    }
}
@media (min-width: 640px) {
    @container (min-width: 22rem) {
        .tka-trustrow__list[data-count="3"] {
            grid-template-columns: repeat(3, minmax(0, 1fr));
        }
    }
}
@media (min-width: 768px) {
    @container (min-width: 30rem) {
        .tka-trustrow__list[data-count="4"] {
            grid-template-columns: repeat(4, minmax(0, 1fr));
        }
    }
}
.tka-trustrow__list > li {
    display: flex;
    margin: 0;
    min-width: 0;
}
.tka-trustrow__item {
    flex: 1 1 auto;
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    box-sizing: border-box;
    min-height: 44px;
    padding: 0.65rem 0;
    color: #274638;
    font-size: 0.875rem;
    line-height: 1.35;
    overflow-wrap: normal;
    word-break: normal;
    hyphens: manual;
    text-align: left;
}
a.tka-trustrow__item {
    text-decoration: underline;
    text-decoration-color: #a7b8ad;
    text-underline-offset: 0.19em;
}
a.tka-trustrow__item:hover {
    color: #102d20;
}
a.tka-trustrow__item:focus-visible {
    border-radius: 2px;
    outline: 3px solid #995724;
    outline-offset: 2px;
}
.tka-trustrow__icon {
    flex: 0 0 20px;
    width: 20px;
    height: 20px;
    margin-top: 1px;
}
