/* =========================================================
   UPCOMING SEARCH
   Design based on the supplied reference
   ========================================================= */


/* =========================================================
   FONT
   ========================================================= */

@font-face {
    font-family: "Isidora";

    src: url("./assets/fonts/isidora-light.woff")
        format("woff");

    font-weight: 300;
    font-style: normal;

    font-display: swap;
}


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

.dev1-cbox-past-search {
    width: 100%;

    box-sizing: border-box;

    margin: 0;

    padding: 6px 16px 14px;

    background: #f7f4ef;

    font-family: "Isidora", sans-serif;
}


/* =========================================================
   MAIN OUTER FRAME
   ========================================================= */

.dev1-cbox-past-search__form {
    width: 100%;

    box-sizing: border-box;

    min-height: 82px;

    display: flex;
    align-items: center;

    gap: 13px;

    padding: 5px;

    background: #ffffff;

    border: 2px solid #cdb5dc;

    border-radius: 30px 0 30px 0;

    box-shadow:
        0 12px 28px rgba(72, 39, 87, 0.12);

    overflow: hidden;
}


/* =========================================================
   SEARCH AREA
   ========================================================= */

.dev1-cbox-past-search__search-field {
    position: relative;

    flex: 1 1 auto;

    min-width: 0;

    height: 66px;

    display: flex;
    align-items: center;

    padding: 0 18px;

    background: #f4eff7;

    border: 1px solid #d6c4df;

    border-radius: 30px 0 30px 0;

    overflow: hidden;
}


/* Purple left line */

.dev1-cbox-past-search__search-field::before {
    content: "";

    position: absolute;

    top: 0;
    bottom: 0;
    left: 0;

    width: 5px;

    background: #67308e;
}


/* =========================================================
   SEARCH ICON
   ========================================================= */

.dev1-cbox-past-search__search-icon {
    flex: 0 0 auto;

    width: 22px;

    margin-right: 13px;

    color: #67308e;

    font-family: Arial, Helvetica, sans-serif;

    font-size: 24px;

    line-height: 1;

    transform: rotate(-20deg);
}


/* =========================================================
   SEARCH INPUT
   ========================================================= */

.dev1-cbox-past-search__input {
    width: 100%;

    min-width: 0;

    height: 100%;

    margin: 0;

    padding: 0;

    border: 0;

    outline: 0;

    background: transparent;

    color: #302738;

    font-family: "Isidora", sans-serif;

    font-size: 18px;

    font-weight: 300;

    line-height: 1;
}


.dev1-cbox-past-search__input::placeholder {
    color: #5d5661;

    opacity: 1;
}


/* =========================================================
   DATE AREA
   ========================================================= */

.dev1-cbox-past-search__date-field {
    position: relative;

    flex: 0 0 285px;

    height: 66px;

    display: flex;
    align-items: center;

    padding: 0 17px;

    background: #f4eff7;

    border: 1px solid #d6c4df;

    border-radius: 30px 0 30px 0;

    overflow: hidden;
}


/* =========================================================
   DATE ICON
   ========================================================= */

.dev1-cbox-past-search__calendar-icon {
    flex: 0 0 auto;

    margin-right: 13px;

    color: #67308e;

    font-family: Arial, Helvetica, sans-serif;

    font-size: 19px;

    line-height: 1;
}


/* =========================================================
   DATE PLACEHOLDER
   ========================================================= */

.dev1-cbox-past-search__date-placeholder {
    position: relative;

    z-index: 1;

    color: #3c3540;

    font-family: "Isidora", sans-serif;

    font-size: 17px;

    font-weight: 300;

    line-height: 1;

    white-space: nowrap;

    pointer-events: none;
}


/* =========================================================
   DATE INPUT
   ========================================================= */

.dev1-cbox-past-search__date-input {
    position: absolute;

    inset: 0;

    z-index: 3;

    width: 100%;

    height: 100%;

    margin: 0;

    padding: 0 15px;

    border: 0;

    outline: 0;

    background: transparent;

    cursor: pointer;

    opacity: 0;
}


/* =========================================================
   CALENDAR RIGHT ICON
   ========================================================= */

.dev1-cbox-past-search__date-icon {
    position: absolute;

    top: 50%;
    right: 17px;

    z-index: 2;

    color: #5d5860;

    font-family: Arial, Helvetica, sans-serif;

    font-size: 19px;

    line-height: 1;

    transform: translateY(-50%);

    pointer-events: none;
}


/* =========================================================
   SEARCH BUTTON
   ========================================================= */

.dev1-cbox-past-search__button {
    flex: 0 0 230px;

    height: 66px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin: 0;

    padding: 0;

    border: 0;

    border-radius: 30px 0 30px 0;

    outline: none;

    background: #67308f;

    color: #ffffff;

    font-family: "Isidora", sans-serif;

    font-size: 16px;

    font-weight: 300;

    line-height: 1;

    cursor: pointer;

    transition:
        background-color 0.2s ease,
        transform 0.2s ease;
}


.dev1-cbox-past-search__button:hover {
    background: #5b287e;
}


.dev1-cbox-past-search__button:active {
    transform: scale(0.99);
}


/* =========================================================
   FOCUS
   ========================================================= */

.dev1-cbox-past-search__search-field:focus-within,
.dev1-cbox-past-search__date-field:focus-within {
    border-color: #b993cc;
}


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

@media (min-width: 1500px) {

    .dev1-cbox-past-search {
        padding-left: 10px;
        padding-right: 10px;
    }


    .dev1-cbox-past-search__form {
        min-height: 82px;

        gap: 10px;

        padding: 5px 7px;

        border-radius: 30px 0 30px 0;
    }


    .dev1-cbox-past-search__search-field,
    .dev1-cbox-past-search__date-field,
    .dev1-cbox-past-search__button {
        height: 66px;
    }


    .dev1-cbox-past-search__date-field {
        flex-basis: 285px;
    }


    .dev1-cbox-past-search__button {
        flex-basis: 230px;
    }
}


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

@media (max-width: 1200px) {

    .dev1-cbox-past-search__form {
        min-height: 80px;

        gap: 9px;

        padding: 5px 6px;

        border-radius: 27px 0 27px 0;
    }


    .dev1-cbox-past-search__search-field,
    .dev1-cbox-past-search__date-field,
    .dev1-cbox-past-search__button {
        height: 64px;
    }


    .dev1-cbox-past-search__date-field {
        flex-basis: 255px;
    }


    .dev1-cbox-past-search__button {
        flex-basis: 205px;

        border-radius: 27px 0 27px 0;
    }


    .dev1-cbox-past-search__input {
        font-size: 17px;
    }


    .dev1-cbox-past-search__date-placeholder {
        font-size: 16px;
    }
}


/* =========================================================
   TABLET
   ========================================================= */

@media (max-width: 900px) {

    .dev1-cbox-past-search {
        padding:
            4px
            10px
            8px;
    }


    .dev1-cbox-past-search__form {
        min-height: 76px;

        gap: 8px;

        padding: 5px;

        border-radius: 25px 0 25px 0;
    }


    .dev1-cbox-past-search__search-field,
    .dev1-cbox-past-search__date-field,
    .dev1-cbox-past-search__button {
        height: 62px;
    }


    .dev1-cbox-past-search__date-field {
        flex-basis: 220px;
    }


    .dev1-cbox-past-search__button {
        flex-basis: 175px;

        border-radius: 25px 0 25px 0;

        font-size: 14px;
    }


    .dev1-cbox-past-search__input {
        font-size: 15px;
    }


    .dev1-cbox-past-search__date-placeholder {
        font-size: 14px;
    }


    .dev1-cbox-past-search__search-icon {
        margin-right: 10px;

        font-size: 22px;
    }
}


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

@media (max-width: 680px) {

    .dev1-cbox-past-search {
        padding:
            6px
            10px
            9px;
    }


    .dev1-cbox-past-search__form {
        min-height: 0;

        display: grid;

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

        gap: 8px;

        padding: 6px;

        border-radius: 21px 0 21px 0;
    }


    .dev1-cbox-past-search__search-field {
        grid-column: 1 / -1;

        width: 100%;

        height: 54px;

        border-radius: 21px 0 21px 0;
    }


    .dev1-cbox-past-search__date-field {
        width: 100%;

        height: 54px;

        flex-basis: auto;

        border-radius: 21px 0 21px 0;
    }


    .dev1-cbox-past-search__button {
        width: 100%;

        height: 54px;

        flex-basis: auto;

        border-radius: 21px 0 21px 0;

        font-size: 12px;
    }


    .dev1-cbox-past-search__input {
        font-size: 14px;
    }


    .dev1-cbox-past-search__date-placeholder {
        font-size: 12px;
    }


    .dev1-cbox-past-search__search-icon {
        width: 19px;

        margin-right: 8px;

        font-size: 21px;
    }


    .dev1-cbox-past-search__calendar-icon {
        margin-right: 8px;

        font-size: 17px;
    }


    .dev1-cbox-past-search__date-icon {
        right: 12px;

        font-size: 17px;
    }
}


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

@media (max-width: 420px) {

    .dev1-cbox-past-search {
        padding:
            6px
            8px
            8px;
    }


    .dev1-cbox-past-search__form {
        grid-template-columns: 1fr;

        gap: 7px;

        padding: 5px;

        border-radius: 19px 0 19px 0;
    }


    .dev1-cbox-past-search__search-field {
        grid-column: auto;

        height: 52px;
    }


    .dev1-cbox-past-search__date-field {
        height: 52px;
    }


    .dev1-cbox-past-search__button {
        height: 52px;

        border-radius: 19px 0 19px 0;
    }


    .dev1-cbox-past-search__input {
        font-size: 13px;
    }


    .dev1-cbox-past-search__date-placeholder {
        font-size: 11px;
    }


    .dev1-cbox-past-search__button {
        font-size: 12px;
    }
}


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

@media (max-width: 340px) {

    .dev1-cbox-past-search {
        padding:
            5px
            6px
            7px;
    }


    .dev1-cbox-past-search__form {
        gap: 6px;

        padding: 4px;

        border-radius: 17px 0 17px 0;
    }


    .dev1-cbox-past-search__search-field,
    .dev1-cbox-past-search__date-field,
    .dev1-cbox-past-search__button {
        height: 50px;
    }


    .dev1-cbox-past-search__input {
        font-size: 12px;
    }


    .dev1-cbox-past-search__date-placeholder {
        font-size: 10px;
    }


    .dev1-cbox-past-search__button {
        font-size: 11px;
    }
}
