﻿/*any component or display used in header*/
.header-details-infocard {
    text-overflow: ellipsis;
    white-space: nowrap;
    overflow: hidden;
    display: block;
    height: var(--height-fill-parent);
    width: var(--weight-fill-parent);
    text-align: left !important;
    color: var(--header-info-card-color);
    font-family: var(--button-font-family);
    font-size: var(--font-size-large);
    font-weight: var(--button-font-weight);
    opacity: 1;
}

.header-info-card-pair div {
    width: var(--weight-fill-parent);
}

/*top component of header without search*/
.header-info-grid {
    display: block;
    margin-bottom: 10px;
    height: 88px;
    max-height: 88px;
    width: var(--weight-fill-parent);
}

/*top component of header with search*/
.header-info-grid-with-search {
    display: flex;
    flex-direction: column;
    margin-bottom: 10px;
    min-height: 75px;
    width: var(--weight-fill-parent);
    box-sizing: border-box;
    flex-shrink: 0;
}

/*top header component with a search bottom*/
.header-info-card-item-with-search-top {
    border-radius: 3px 3px 0px 0px;
}

/*search component with no header*/
.header-info-card-item-with-search-no-header {
    border-radius: 3px;
}

/*adjusting height when search hidden*/
.search-height {
    /*min-height: 180px;*/
}

.search-height-no-header { /*
    min-height: 74px;*/
}

.no-extra-search-height { /*
    min-height: 88px;*/
    margin-bottom: 10px;
}

/*header wrapper component for all child element*/
.header-info-card-item {
    background-color: var(--header-info-card-background-color);
    border: var(--header-info-card-item-border);
    border-radius: var(--header-info-card-item-border-radius);
    opacity: 1;
    padding: 20px 15px;
    max-height: 88px;
    display: flex;
    flex-direction: row;
}
/*search wrapper component for all child element*/
.header-info-card-item-search {
    display: grid;
    /* grid-template-columns: repeat(3, 1fr) auto;  3 equal columns + 1 fixed column for button */
    /* grid-template-columns: repeat(auto-fit, minmax(580px, 1fr)); */
    grid-template-columns: repeat(3, 1fr) 370px;
    gap: 50px;
    align-items: center;
    background-color: var(--header-info-card-background-color);
    border: var(--header-info-card-item-border);
    padding: 20px 15px;
    position: relative;
    min-height: 88px;
    max-height: var(--height-fill-parent);
    width: var(--weight-fill-parent);
    box-sizing: border-box;
}

    .header-info-card-item-search > div:last-child {
        grid-column: 4;
        align-self: start;
        justify-self: end;
    }

        .header-info-card-item-search > div:last-child button {
            position: relative;
            margin: 0;
        }

.header-info-card-item-search-bottom {
    border-radius: 0px 0px 3px 3px;
    border-top: none;
}


/*Header card components*/
/*child compoennt for each element inside header wrapper*/
.header-info-card-pair {
    display: flex;
    flex-direction: column;
    min-width: 100px;
    max-width: var(--weight-fill-parent);
    position: relative;
    border-right: var(--header-grid-item-border);
    margin-right: 25px;
    padding-right: 25px;
}
    .header-info-card-pair.align-right {
        margin-left: auto; /* pushes to right inside a flex container */
        align-self: center; /* optional: vertically center it */
    }

    .header-info-card-pair:last-child {
        border-right: none; /* Remove dividing line for the last item */
        margin-bottom: 0;
    }

    .header-info-card-pair label {
        text-overflow: ellipsis;
        white-space: nowrap;
        overflow: hidden;
        display: block;
        height: var(--height-fill-parent);
        width: var(--weight-fill-parent);
        text-align: left !important;
        color: var(--header-info-card-color);
        font-family: var(--button-font-family);
        font-size: var( --font-size);
        font-weight: var(--font-weight-small);
        opacity: 1;
    }

    .header-info-card-pair div {
        text-overflow: ellipsis;
        white-space: nowrap;
        overflow: hidden;
        display: block;
        height: var(--height-fill-parent);
        width: var(--weight-fill-parent);
        text-align: left !important;
        color: var(--header-info-card-color);
        font-family: var(--button-font-family);
        font-size: var(--font-size-large);
        font-weight: var(--button-font-weight);
        opacity: 1;
    }

/*search wrapper component*/
.header-info-card-item-base-search {
    display: grid;
    background-color: var(--header-info-card-background-color);
    border: var(--header-info-card-item-border);
    border-radius: var(--header-info-card-item-border-radius);
    padding: 20px 15px;
    grid-template-columns: repeat(3, 1fr) 255px;
    width: var(--weight-fill-parent);
    overflow: clip;
    gap: 10px;
    margin-top: 10px;
}

.header-info-card-item-with-search-bottom {
    margin-top: 10px;
}

.search-height {
    /*  min-height: 160px;*/
}

.no-extra-search-height {
    /* min-height: 88px;*/
    margin-bottom: 10px;
}

/*grid item - label and div*/
.header-grid-item {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 30px;
    min-width: 140px;
}

.header-extra-bottom-padding {
    padding-bottom: 10px;
}

.header-grid-item label {
    flex: 1;
    min-width: 140px;
    max-width: 210px;
    white-space: nowrap;
    align-self: center;
    text-align: left;
    font: var(--form-label-content-font);
    color: var(--filter-menu-text-colour);
    letter-spacing: var(--form-label-content-letter-spacing);
}

.header-grid-item div {
    align-self: center;
    max-width: 300px;
    min-width: 240px;
    box-sizing: border-box;
    margin-right: 40px;
    flex: 2;
}


/*clear button on search*/
.button-column-with-three-search-columns {
    display: flex;
    grid-column: 4;
    grid-row: -1;
    transform: translate(116px, -13px);
}

.button-column-with-one-search-columns {
    display: flex;
    grid-column: 4;
    grid-row: -1;
    transform: translate(22px, -13px);
}


/*hide and show search*/
.hide {
    display: none;
}


@media (min-width: 1233px) and (max-width: 1740px) {
    .header-info-card-item-base-search {
        grid-template-columns: repeat(2, minmax(380px, 590px)) 1fr;
    }

    .header-grid-item {
        gap: 30px;
        margin-bottom: 10px;
    }

    .button-column-with-three-search-columns {
        grid-column: span 1 / -1;
        justify-content: end;
        margin-right: 60px;
    }

    .button-column-with-one-search-columns {
        grid-column: span 1 / -1;
        justify-content: end;
        margin-right: -35px;
    }
}

@media (max-width: 1232px) {
    .header-info-card-item-base-search {
        grid-template-columns: 1fr;
    }

    .header-grid-item {
        margin-bottom: 10px;
    }

    .button-column-with-three-search-columns {
        grid-column: span 1 / -1;
        justify-content: end;
        margin-right: 60px;
    }

    .button-column-with-one-search-columns {
        grid-column: span 1 / -1;
        justify-content: end;
        margin-right: -35px;
    }
}
