/* ============================================================================
   Our Suppliers (store-list) — modern look, CSS only. Same fonts and colors:
   #3b6bb4 header bar (existing), Comfortaa heading font (existing inline),
   site Sans body, green rating stars untouched. No markup/logic changes.
   Scoped to .accordianarea on this page.
   ============================================================================ */

/* Card container around the whole listing */
.accordianarea .accordion {
    background: #ffffff;
    border: 1px solid #e8ecf1;
    border-radius: 12px;
    overflow: hidden;
    overflow-x: auto; /* small screens: the table scrolls inside the card */
    box-shadow: 0 2px 10px rgba(16, 42, 67, 0.06);
}

    /* "Available Suppliers" bar: same #3b6bb4, finished as a gradient band
       (the same pair the site already uses on modal headers) */
    .accordianarea .accordion > h3 {
        background: linear-gradient(135deg, #3b6bb4, #4d84d7) !important;
        border-bottom: none !important;
        border-radius: 0 !important;
        padding: 13px 18px !important;
        letter-spacing: 0.4px;
    }

    /* Table: collapse the legacy cellspacing gaps */
    .accordianarea .accordion table {
        border-collapse: collapse !important;
        width: 100%;
    }

    /* Header row */
    .accordianarea .accordion .carddetailtableheading {
        background: #f5f7fa;
        color: #1a2b49;
        font-size: 12px;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        padding: 11px 14px;
        border-bottom: 1px solid #e4e9ef;
        white-space: nowrap;
    }

    /* Data rows */
    .accordianarea .accordion table td {
        padding: 12px 14px;
        border-bottom: 1px solid #eef2f5;
        vertical-align: middle;
        font-size: 13.5px;
        color: #333f4d;
        transition: background 0.12s ease;
    }

    .accordianarea .accordion table tr:hover td {
        background: #f0f6fa;
    }

    /* keep the header row itself out of the hover effect */
    .accordianarea .accordion table tr:hover td.carddetailtableheading {
        background: #f5f7fa;
    }

    /* Supplier name link: same #333 base color (inline), just bolder + teal hover */
    .accordianarea .accordion table td a {
        font-weight: 600;
        text-decoration: none;
    }

        .accordianarea .accordion table td a:hover {
            color: #277487 !important;
            text-decoration: none;
        }

    /* Eye link → circular view button */
    .accordianarea .accordion table td[align="center"] a {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 34px;
        height: 34px;
        background: #ffffff;
        border: 1px solid #d8e2f0;
        border-radius: 50%;
        color: #27508e;
        transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
    }

        .accordianarea .accordion table td[align="center"] a i.fa-eye {
            font-size: 15px !important; /* the markup sets 25px inline */
        }

        .accordianarea .accordion table td[align="center"] a:hover {
            background: #27508e;
            color: #ffffff !important;
            box-shadow: 0 4px 10px rgba(39, 80, 142, 0.30);
        }

@media screen and (max-width: 767px) {
    .accordianarea .accordion table {
        min-width: 720px;
    }

    .accordianarea .accordion table td,
    .accordianarea .accordion .carddetailtableheading {
        padding: 9px 10px;
        font-size: 12.5px;
    }
}

/* ---------------------------------------------------------------------------
   v2: rating stars on one line, header band sized to the card, pager styles
   --------------------------------------------------------------------------- */

.accordianarea .accordion table td div[id$="_ratingQuikanou"],
.accordianarea .accordion table td div[id$="_ratingCustomer"] {
    white-space: nowrap;
    font-size: 0;
    line-height: 0;
}

    .accordianarea .accordion table td div[id$="_ratingQuikanou"] > a,
    .accordianarea .accordion table td div[id$="_ratingCustomer"] > a {
        display: inline-block;
        white-space: nowrap;
    }

    .accordianarea .accordion table td div[id$="_ratingQuikanou"] span.StarCss,
    .accordianarea .accordion table td div[id$="_ratingCustomer"] span.StarCss {
        float: none !important; /* markup sets float:left inline */
        display: inline-block;
        vertical-align: top;
    }

/* "Available Suppliers" band: style.css forces min-width:770px on small screens,
   which pushed the band past the table. Size it to the card and keep it in view
   while the table scrolls sideways. */
.accordianarea .accordion > h3 {
    box-sizing: border-box;
    min-width: 0;
    position: -webkit-sticky;
    position: sticky;
    left: 0;
}

/* Pager (same markup as the other listing pages) */
.accordianarea .storelist-pager {
    margin: 16px 0 6px;
    padding: 0;
}

    .accordianarea .storelist-pager > div:first-child {
        margin-bottom: 8px;
        font-size: 12.5px;
        color: #8a949c;
    }

    .accordianarea .storelist-pager table {
        margin: 0 auto;
        border-collapse: separate;
    }

    .accordianarea .storelist-pager td {
        padding: 0 2px;
        vertical-align: middle;
        border: 0;
    }

    /* page numbers */
    .accordianarea .storelist-pager tr.text a {
        display: inline-block;
        min-width: 30px;
        height: 30px;
        padding: 0 9px;
        box-sizing: border-box;
        line-height: 28px;
        text-align: center;
        font-size: 13px;
        color: #27508e;
        background: #ffffff;
        border: 1px solid #d8e2f0;
        border-radius: 15px;
        text-decoration: none;
        transition: background 0.15s ease, color 0.15s ease;
    }

        .accordianarea .storelist-pager tr.text a:hover {
            background: #f0f6fa;
            color: #27508e;
            text-decoration: none;
        }

        /* current page is rendered as <b>n</b> */
        .accordianarea .storelist-pager tr.text a b {
            font-weight: 600;
        }

        .accordianarea .storelist-pager tr.text a:has(> b) {
            background: #27508e;
            border-color: #27508e;
            color: #ffffff;
        }

    /* prev / next image links */
    .accordianarea .storelist-pager a img {
        vertical-align: middle;
        border: 0;
    }

    /* a disabled LinkButton renders as <a> without href (legacy rendering) */
    .accordianarea .storelist-pager a[disabled],
    .accordianarea .storelist-pager td > a:not([href]) {
        opacity: 0.35;
        cursor: default;
    }

/* ---------------------------------------------------------------------------
   v3 (2026-11-23): supplier CARD GRID, like the Review & Rating page.
   The repeater table (header row + one row per supplier, cells: 1 name,
   2 location, 3 country, 4 ethniv rating, 5 customer rating, 6 view link)
   becomes a grid of cards:
        [store icon]
        Supplier name
        (pin) location
        [Grenada]
        ethniv rating      ★★★★★
        Customer rating    ★★★★★
        [ View store -> ]
   CSS only - same links, same rating controls, same pager.
   --------------------------------------------------------------------------- */
.accordianarea .accordion {
    overflow: visible;
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

    .accordianarea .accordion > h3 {
        border-radius: 12px 12px 0 0 !important;
        margin-bottom: 16px !important;
        position: static;
    }

    .accordianarea .accordion > table {
        display: block;
        min-width: 0 !important;
        border: 0;
    }

        .accordianarea .accordion > table > tbody {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
            gap: 16px;
        }

            /* column headings are not needed on cards */
            .accordianarea .accordion > table > tbody > tr:first-child {
                display: none;
            }

            /* the card */
            .accordianarea .accordion > table > tbody > tr {
                display: flex;
                flex-direction: column;
                min-width: 0;
                padding: 16px 16px 14px;
                background: #ffffff;
                border: 1px solid #e3e9ee;
                border-radius: 14px;
                box-shadow: 0 1px 4px rgba(16, 42, 67, 0.06);
                transition: box-shadow 0.15s ease, transform 0.15s ease, border-color 0.15s ease;
            }

                .accordianarea .accordion > table > tbody > tr:hover {
                    transform: translateY(-2px);
                    border-color: #b9dcdc;
                    box-shadow: 0 8px 20px rgba(16, 42, 67, 0.12);
                }

                .accordianarea .accordion > table > tbody > tr > td,
                .accordianarea .accordion > table > tbody > tr:hover > td {
                    display: block;
                    width: auto !important;
                    padding: 0;
                    border: 0;
                    background: none;
                    text-align: left !important;
                }

                /* 1: store icon + name */
                .accordianarea .accordion > table > tbody > tr > td:nth-child(1)::before {
                    content: "";
                    display: block;
                    width: 44px;
                    height: 44px;
                    margin-bottom: 10px;
                    border-radius: 11px;
                    background: #e6f4f4 no-repeat center / 22px 22px url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23008186' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 9l1.5-5h15L21 9'/%3E%3Cpath d='M3 9h18v1.5a2.5 2.5 0 0 1-5 0 2.5 2.5 0 0 1-5 0 2.5 2.5 0 0 1-5 0V9'/%3E%3Cpath d='M5 12.5V20h14v-7.5'/%3E%3Cpath d='M10 20v-4h4v4'/%3E%3C/svg%3E");
                }

                .accordianarea .accordion > table > tbody > tr > td:nth-child(1) a {
                    display: -webkit-box;
                    -webkit-box-orient: vertical;
                    -webkit-line-clamp: 2;
                    overflow: hidden;
                    min-height: 42px;
                    font-size: 15.5px;
                    font-weight: 700;
                    line-height: 21px;
                    color: #1a2b49 !important;
                    overflow-wrap: anywhere;
                }

                /* 2: location */
                .accordianarea .accordion > table > tbody > tr > td:nth-child(2) {
                    position: relative;
                    margin-top: 6px;
                    padding-left: 20px;
                    min-height: 38px;
                    font-size: 13px;
                    line-height: 19px;
                    color: #5b6b7a;
                }

                    .accordianarea .accordion > table > tbody > tr > td:nth-child(2)::before {
                        content: "";
                        position: absolute;
                        left: 0;
                        top: 2px;
                        width: 15px;
                        height: 15px;
                        background: no-repeat center / 15px 15px url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23008186' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 21s-7-6.2-7-11.5a7 7 0 0 1 14 0C19 14.8 12 21 12 21z'/%3E%3Ccircle cx='12' cy='9.5' r='2.5'/%3E%3C/svg%3E");
                    }

                /* 3: country chip */
                .accordianarea .accordion > table > tbody > tr > td:nth-child(3) {
                    align-self: flex-start;
                    margin: 8px 0 10px;
                    padding: 2px 10px;
                    border-radius: 999px;
                    background: #eef3f8;
                    font-size: 11.5px;
                    font-weight: 600;
                    line-height: 18px;
                    color: #27508e;
                }

                /* 4 + 5: ratings with their labels */
                .accordianarea .accordion > table > tbody > tr > td:nth-child(4),
                .accordianarea .accordion > table > tbody > tr > td:nth-child(5) {
                    display: flex;
                    align-items: center;
                    justify-content: space-between;
                    gap: 8px;
                    padding: 7px 0;
                    border-top: 1px solid #eef2f5;
                    font-size: 12px;
                    color: #5b6b7a;
                }

                    .accordianarea .accordion > table > tbody > tr > td:nth-child(4)::before {
                        content: "ethniv rating";
                    }

                    .accordianarea .accordion > table > tbody > tr > td:nth-child(5)::before {
                        content: "Customer rating";
                    }

                    .accordianarea .accordion > table > tbody > tr > td:nth-child(4) span.StarCss,
                    .accordianarea .accordion > table > tbody > tr > td:nth-child(5) span.StarCss {
                        width: 16px !important;
                        height: 16px !important;
                        margin-right: 1px;
                        background-size: 16px 16px;
                    }

                /* 6: the eye link becomes a full-width "View store" button */
                .accordianarea .accordion > table > tbody > tr > td:nth-child(6) {
                    margin-top: auto;
                    padding-top: 12px;
                }

                    .accordianarea .accordion > table > tbody > tr > td:nth-child(6) a {
                        display: flex;
                        align-items: center;
                        justify-content: center;
                        gap: 6px;
                        width: 100%;
                        height: 38px;
                        border: 0;
                        border-radius: 8px;
                        background: linear-gradient(135deg, #3b6bb4, #4d84d7);
                        box-shadow: 0 3px 8px rgba(59, 107, 180, 0.25);
                        font-size: 13px;
                        font-weight: 600;
                        letter-spacing: 0.2px;
                        color: #ffffff !important;
                        text-decoration: none;
                    }

                        .accordianarea .accordion > table > tbody > tr > td:nth-child(6) a i.fa-eye {
                            font-size: 14px !important;
                            color: #ffffff;
                        }

                        .accordianarea .accordion > table > tbody > tr > td:nth-child(6) a::after {
                            content: "View store";
                        }

                        .accordianarea .accordion > table > tbody > tr > td:nth-child(6) a:hover {
                            background: linear-gradient(135deg, #335fa3, #4377c8);
                            box-shadow: 0 5px 12px rgba(59, 107, 180, 0.38);
                        }

/* tablet: the list column is only ~510px wide - two cards still fit */
@media screen and (max-width: 1024px) {
    .accordianarea .accordion > table > tbody {
        grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
        gap: 12px;
    }
}

@media screen and (max-width: 767px) {

    .accordianarea .accordion > table > tbody > tr > td,
    .accordianarea .accordion .carddetailtableheading {
        padding: 0;
    }

    .accordianarea .accordion > table > tbody > tr > td:nth-child(4),
    .accordianarea .accordion > table > tbody > tr > td:nth-child(5) {
        padding: 7px 0;
    }
}

/* 2026-11-23: "Customer rating" shows only when it is above 3 (same rule as the product pages):
   the AJAX Rating control marks filled stars FilledStarCss, so above 3 = the 4th star is filled.
   Otherwise the whole line (label + stars) is hidden. */
.accordianarea .accordion > table > tbody > tr > td:nth-child(5):not(:has(span[id$="_Star_4"].FilledStarCss)) {
    display: none;
}

/* 2026-11-23: fixed number of cards per row, so the 20 suppliers per page always end on a full row
   (20 = 4 x 5 = 5 x 4 = 10 x 2). Replaces the auto-fill columns above. */
.accordianarea .accordion > table > tbody {
    grid-template-columns: repeat(5, minmax(0, 1fr));
}

@media screen and (max-width: 1399px) {
    .accordianarea .accordion > table > tbody {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media screen and (max-width: 1199px) {
    .accordianarea .accordion > table > tbody {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media screen and (max-width: 599px) {
    .accordianarea .accordion > table > tbody {
        grid-template-columns: minmax(0, 1fr);
    }
}
