
/* =========================================================
   AGM CATALOGUE
   BRAND THEME
========================================================= */

:root {

    --agm-red: #DA291C;

    --agm-red-dark: #B51F16;

    --agm-red-light: #FFF1F0;

    --agm-dark: #111827;

    --agm-gray: #6B7280;

    --agm-border: #E5E7EB;

    --agm-background: #F4F5F7;

}


/* =========================================================
   RESET
========================================================= */

* {

    box-sizing: border-box;

}


html {

    scroll-behavior: smooth;

}


body {

    margin: 0;

    font-family:
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        Roboto,
        Arial,
        sans-serif;

    background: var(--agm-background);

    color: var(--agm-dark);

}


/* =========================================================
   MAIN CATALOGUE
========================================================= */

.catalogue {

    width: 100%;

    max-width: 900px;

    margin: 0 auto;

    padding:
        0
        16px
        40px;

}


/* =========================================================
   HEADER
========================================================= */

.supplier-header {

    position: relative;

    text-align: center;

    padding:
        34px
        10px
        26px;

}


/* =========================================================
   AGM LOGO
========================================================= */

.logo {

    display: flex;

    justify-content: center;

    margin-bottom: 12px;

}


.logo img {

    display: block;

    max-width: 180px;

    height: auto;

}


/* =========================================================
   SUPPLIER HEADER TEXT
========================================================= */

.supplier-label {

    font-size: 11px;

    font-weight: 800;

    letter-spacing: 1.8px;

    color: var(--agm-red);

    margin-bottom: 7px;

}


.supplier-header h1 {

    margin: 0;

    font-size: 34px;

    line-height: 1.15;

    font-weight: 800;

    color: var(--agm-dark);

}


.supplier-header p {

    margin:
        8px
        0
        0;

    font-size: 14px;

    color: var(--agm-gray);

}


/* =========================================================
   SPREADSHEET BUTTON
========================================================= */

.spreadsheet-button {

    display: inline-flex;

    align-items: center;

    justify-content: center;

    margin-top: 16px;

    padding:
        11px
        18px;

    background:
        var(--agm-red);

    color: #FFFFFF;

    text-decoration: none;

    border-radius: 8px;

    font-size: 13px;

    font-weight: 700;

    transition:
        background 0.2s ease,
        transform 0.2s ease,
        box-shadow 0.2s ease;

}


.spreadsheet-button:hover {

    background:
        var(--agm-red-dark);

    color: #FFFFFF;

    transform:
        translateY(-1px);

    box-shadow:
        0 4px 10px
        rgba(
            218,
            41,
            28,
            0.20
        );

}


/* =========================================================
   SEARCH / FILTER CONTROLS
========================================================= */

.controls {

    position: sticky;

    top: 0;

    z-index: 20;

    padding:
        12px
        0
        14px;

    background:
        rgba(
            244,
            245,
            247,
            0.96
        );

    backdrop-filter:
        blur(10px);

}


/* =========================================================
   SEARCH + SPREADSHEET BUTTON
========================================================= */

.search-row {

    display: grid;

    grid-template-columns:
        minmax(
            0,
            1fr
        )
        auto;

    gap: 8px;

    align-items: center;

}


.search-box {

    min-width: 0;

}


.search-box input {

    width: 100%;

    height: 48px;

    border:
        1px solid
        #D1D5DB;

    border-radius: 12px;

    padding:
        0
        16px;

    font-size: 16px;

    outline: none;

    background: white;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;

}


.search-box input:focus {

    border-color:
        var(--agm-red);

    box-shadow:
        0 0 0 3px
        rgba(
            218,
            41,
            28,
            0.12
        );

}


/* =========================================================
   COMPACT SPREADSHEET BUTTON
========================================================= */

.compact-button {

    height: 48px;

    margin-top: 0;

    padding:
        0
        16px;

    display: inline-flex;

    align-items: center;

    justify-content: center;

    white-space: nowrap;

    flex-shrink: 0;

}


/* =========================================================
   FILTER ROW
========================================================= */

.filter-row {

    display: grid;

    grid-template-columns:
        repeat(
            2,
            minmax(
                0,
                1fr
            )
        );

    gap: 8px;

    margin-top: 8px;

}


/* =========================================================
   SINGLE FILTER
========================================================= */

.filter-row.single-filter {

    grid-template-columns:
        minmax(
            0,
            1fr
        );

}


/* =========================================================
   FILTER SELECT
========================================================= */

.filter-row select {

    width: 100%;

    min-width: 0;

    height: 44px;

    border:
        1px solid
        #D1D5DB;

    border-radius: 10px;

    padding:
        0
        12px;

    font-size: 15px;

    color:
        var(--agm-dark);

    background: white;

    outline: none;

    cursor: pointer;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;

}


.filter-row select:focus {

    border-color:
        var(--agm-red);

    box-shadow:
        0 0 0 3px
        rgba(
            218,
            41,
            28,
            0.12
        );

}


/* =========================================================
   RESULTS
========================================================= */

.results-info {

    font-size: 13px;

    font-weight: 600;

    color:
        var(--agm-gray);

    margin:
        4px
        2px
        12px;

}


/* =========================================================
   PRODUCT LIST
========================================================= */

.product-list {

    display: flex;

    flex-direction: column;

    gap: 12px;

}


/* =========================================================
   PRODUCT CARD
========================================================= */

.product-card {

    position: relative;

    background: white;

    border-radius: 14px;

    padding: 16px;

    border-left:
        4px solid
        var(--agm-red);

    box-shadow:
        0 1px 3px
        rgba(
            0,
            0,
            0,
            0.08
        );

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;

}


.product-card:hover {

    transform:
        translateY(-1px);

    box-shadow:
        0 5px 14px
        rgba(
            0,
            0,
            0,
            0.08
        );

}


/* =========================================================
   PRODUCT CODE
========================================================= */

.product-code {

    font-size: 12px;

    font-weight: 800;

    letter-spacing: 0.3px;

    color:
        var(--agm-red);

    margin-bottom: 5px;

}


/* =========================================================
   PRODUCT TITLE
========================================================= */

.product-title-row {

    display: flex;

    align-items: flex-start;

    justify-content: space-between;

    gap: 10px;

}


.product-name {

    margin: 0;

    font-size: 17px;

    line-height: 1.35;

    font-weight: 750;

    color:
        var(--agm-dark);

}


/* =========================================================
   HOT BUY BADGE
========================================================= */

.hot-buy {

    flex-shrink: 0;

    font-size: 10px;

    font-weight: 800;

    letter-spacing: 0.7px;

    padding:
        5px
        8px;

    border-radius: 6px;

    background:
        var(--agm-red);

    color: white;

}


/* =========================================================
   CATEGORY
========================================================= */

.product-category {

    display: inline-block;

    margin-top: 7px;

    padding:
        4px
        7px;

    font-size: 10px;

    font-weight: 700;

    letter-spacing: 0.3px;

    color:
        var(--agm-red-dark);

    background:
        var(--agm-red-light);

    border-radius: 5px;

}


/* =========================================================
   PRICING TABLE
========================================================= */

.pricing-table {

    display: grid;

    grid-template-columns:
        repeat(
            auto-fit,
            minmax(
                90px,
                1fr
            )
        );

    margin-top: 14px;

    border:
        1px solid
        var(--agm-border);

    border-radius: 10px;

    overflow: hidden;

}


.price-cell {

    min-width: 0;

    padding:
        11px
        8px;

    border-right:
        1px solid
        var(--agm-border);

}


.price-cell:last-child {

    border-right: none;

}


.price-label {

    font-size: 10px;

    font-weight: 800;

    line-height: 1.25;

    letter-spacing: 0.2px;

    color:
        var(--agm-gray);

    word-break: normal;

}


.price-value {

    margin-top: 5px;

    font-size: 15px;

    font-weight: 750;

    white-space: nowrap;

    color:
        var(--agm-dark);

}


/* =========================================================
   DISCOUNT SECTION
========================================================= */

.discount-section {

    margin-top: 12px;

}


.discount-heading {

    display: flex;

    align-items: center;

    gap: 7px;

    margin-bottom: 6px;

    font-size: 11px;

    font-weight: 800;

    letter-spacing: 1px;

    color:
        var(--agm-red);

}


.discount-heading::before {

    content: "";

    width: 4px;

    height: 12px;

    border-radius: 4px;

    background:
        var(--agm-red);

}


.discount-pricing {

    margin-top: 0;

}


.discount-cell {

    text-align: center;

}


.discount-cell .price-label {

    font-size: 9px;

    line-height: 1.3;

}


/* =========================================================
   EMPTY STATE
========================================================= */

.empty-state {

    text-align: center;

    padding:
        50px
        20px;

    color:
        var(--agm-gray);

}


.empty-state strong {

    display: block;

    color:
        var(--agm-dark);

    margin-bottom: 5px;

}


.empty-state span {

    font-size: 14px;

}


.hidden {

    display: none;

}


/* =========================================================
   DESKTOP
========================================================= */

@media (min-width: 700px) {

    .catalogue {

        padding-left: 24px;

        padding-right: 24px;

    }


    .supplier-header {

        padding-top: 46px;

    }


    .supplier-header h1 {

        font-size: 40px;

    }


    /* SEARCH + VIEW */

    .search-row {

        grid-template-columns:
            minmax(
                0,
                1fr
            )
            210px;

        gap: 8px;

    }


    /* FILTERS */

    .filter-row {

        grid-template-columns:
            repeat(
                2,
                minmax(
                    0,
                    1fr
                )
            );

        gap: 8px;

        margin-top: 8px;

    }


    /* CATEGORY ONLY */

    .filter-row.single-filter {

        grid-template-columns:
            1fr;

    }

}


/* =========================================================
   SMALL MOBILE
========================================================= */

@media (max-width: 480px) {

    .catalogue {

        padding-left: 12px;

        padding-right: 12px;

    }


    .supplier-header {

        padding-top: 28px;

    }


    .supplier-header h1 {

        font-size: 30px;

    }


    .logo img {

        max-width: 150px;

    }


    .search-row {

        grid-template-columns:
            minmax(
                0,
                1fr
            )
            auto;

        gap: 6px;

    }


    .compact-button {

        padding:
            0
            12px;

        font-size: 11px;

    }


    .search-box input {

        padding-left: 12px;

        padding-right: 12px;

    }


    .product-card {

        padding: 14px;

    }


    .product-name {

        font-size: 16px;

    }


    .pricing-table {

        grid-template-columns:
            repeat(
                auto-fit,
                minmax(
                    75px,
                    1fr
                )
            );

    }


    .price-cell {

        padding:
            9px
            6px;

    }


    .price-label {

        font-size: 9px;

    }


    .price-value {

        font-size: 14px;

    }

}
