/* --- Toolbar Container --- */

.toolbar.content-wrapper {
    max-height: 54px;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
    text-align: center;
    padding: 12px 12px 0px 12px;
}

.toolbar.content {
    display: flex;
    flex-direction: row;
    align-items: center;

    gap: 6px;
    width: 100%;
}

/* --- Toolbar Container --- */
/* --- Toolbar Button --- */

.toolbar.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    white-space: nowrap;
    overflow: hidden;
    cursor: pointer;
    flex: 0 0 auto;


    height: var(--toolbarButtonMinSize);
    min-width: var(--toolbarButtonMinSize);
    width: max-content;

    padding: 2px;
    border: 0;
    border-radius: var(--toolbarButtonBorderRadius);

    color: var(--toolbarText);
    background: var(--toolbarButtonBackground);

    backdrop-filter: blur(10px) saturate(180%);
    -webkit-backdrop-filter: blur(24px) saturate(180%);

    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.32),
        inset 0 -10px 10px rgba(255, 255, 255, 0.08),
        0 6px 30px rgba(0, 0, 0, 0.15);

    transition:
        background-color var(--primaryInteraction),
        color var(--primaryInteraction),
        transform var(--primaryInteraction);
}

.toolbar.button::before {
    content: "";
    position: absolute;
    inset: 0;
    padding: var(--toolbarButtonBorderWidth);
    border-radius: inherit;
    pointer-events: none;

    background: var(--toolbarButtonBorder);

    -webkit-mask:
        linear-gradient(#000 0 0) content-box,
        linear-gradient(#000 0 0);

    -webkit-mask-composite: xor;
    mask-composite: exclude;
}

.toolbar.button:hover {
    background-color: var(--toolbarButtonBackgroundHover);
    color: var(--toolbarTextFocus);
}

.toolbar.button:active {
    transform: scale(0.975);
}

.toolbar.button:hover .icon {
    background-color: var(--toolbarButtonInsetBackgroundHover);
}

.toolbar.button .icon {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;

    width: 100%;
    height: 100%;
    flex: 0 0 38px;
    border-radius: 99px;

    text-decoration: none;
    color: inherit;

    transition:
        background-color var(--primaryInteraction),
        color var(--primaryInteraction);
}

.toolbar.button .icon svg {
    width: 14px;
    height: 14px;
    flex: 0 0 14px;
}

.toolbar.button .icon .text {
    margin-bottom: -2px;
    font-size: 14px;
    font-weight: 600;
    padding-inline: 14px;
}

.toolbar.location {
    display: inline-flex;
    align-items: center;
    justify-content: flex-start;
    position: relative;
    white-space: nowrap;
    text-align: left;
    cursor: pointer;

    width: 100%;

    padding: 6px 12px;
    gap: 6px;

    font-size: 14px;
    font-weight: 500;

    color: var(--toolbarText);
    appearance: none;
    outline: none;
    border: 0;
    background-color: transparent;
}

.toolbar.location:hover #currentCityState {
    color: var(--toolbarTextFocus);
}

.toolbar.location .icon {
    width: 13px;
    height: 13px;
    color: var(--primaryAccent);
}

.toolbar.location .precise {
    text-decoration: underline;
    color: var(--primaryAccent);
    font-weight: 500;
}

/* Variation Styles */

.toolbar.button.accent {
    color: var(--primaryAccent);
}

.toolbar.button.accent-filled {
    background: var(--primaryAccent);
    color: var(--tintAccent);
}

.toolbar.button.accent-filled:hover .icon {
    background: var(--tintAccent);
    color: var(--primaryAccent);
}

.toolbar.button.warning {
    background: var(--primaryWarning);
    color: var(--tintWarning);
}

.toolbar.button.warning:hover .icon {
    background: var(--tintWarning);
    color: var(--primaryWarning);
}

.toolbar.button.confirm {
    background: var(--primaryConfirm);
    color: var(--tintConfirm);
}

.toolbar.button.confirm:hover .icon {
    background: var(--tintConfirm);
    color: var(--primaryConfirm);
}

/* --- Variation Styles --- */
/* --- Toolbar Button --- */
/* --- Toolbar Input ---  */

.toolbar.input-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    white-space: nowrap;
    overflow: hidden;
    cursor: pointer;

    height: var(--toolbarButtonMinSize);
    min-width: var(--toolbarButtonMinSize);
    width: 100%;

    padding-block: 0px;
    padding-inline: 0px;
    padding: 0px;
    border: 0;
    border-radius: var(--toolbarButtonBorderRadius);
    outline: none;

    color: var(--primaryText);
    background: var(--toolbarButtonBackground);

    backdrop-filter: blur(10px) saturate(180%);
    -webkit-backdrop-filter: blur(24px) saturate(180%);

    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.32),
        inset 0 -10px 10px rgba(255, 255, 255, 0.08),
        0 6px 30px rgba(0, 0, 0, 0.15);

    transition:
        background-color var(--primaryInteraction),
        color var(--primaryInteraction),
        transform var(--primaryInteraction);
}

.toolbar.input-wrapper::before {
    content: "";
    position: absolute;
    inset: 0;
    padding: var(--toolbarButtonBorderWidth);
    border-radius: inherit;
    pointer-events: none;

    background: var(--toolbarButtonBorder);

    -webkit-mask:
        linear-gradient(#000 0 0) content-box,
        linear-gradient(#000 0 0);

    -webkit-mask-composite: xor;
    mask-composite: exclude;
}

.toolbar.input-wrapper:hover {
    background-color: var(--toolbarButtonBackgroundHover);
    color: var(--toolbarTextFocus);
}

.toolbar.input-wrapper svg {
    width: 14px;
    height: 14px;
    min-width: 14px;
    min-height: 14px;
    max-width: 14px;
    max-height: 14px;

    margin-right: -18px;
    padding-left: 18px;

    box-sizing: content-box;
}

.toolbar.input-wrapper .loading-icon {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    cursor: auto;

    width: 38px;
    height: 38px;
}

.toolbar.input-wrapper .loading-icon.is-hidden {
    display: none;
}

.toolbar.input {
    border: none;
    outline: none;

    background-color: transparent;
    color: var(--toolbarTextFocus);

    font-size: 16px;

    height: 100%;
    width: 100%;
    padding: 0px 12px 0px 48px;
    margin-left: -18px;
}

.toolbar.input::placeholder {
    font-size: 14px;
    color: var(--toolbarText);

}

/* --- Toolbar Input --- */
/* --- Toolbar Results ---  */

.toolbar-results.content-wrapper {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;

    position: fixed;
    top: var(--toolbarResultsTop, 66px);
    left: var(--toolbarResultsLeft, 0px);
    width: var(--toolbarResultsWidth, 100vw);
    padding: 12px 12px 0px 12px;
    z-index: 1200;

    max-height: min(var(--toolbarResultsMaxHeight), calc(100vh - var(--toolbarResultsTop, 66px) - 12px));
    max-height: min(var(--toolbarResultsMaxHeight), calc(100dvh - var(--toolbarResultsTop, 66px) - 12px));

    color: var(--toolbarText);
    pointer-events: none;
}

.toolbar-results.content-wrapper > .container {
    display: flex;
    max-height: inherit;
    min-height: 0;
}

.toolbar-results.content-wrapper.is-hidden {
    display: none;
}

.toolbar-results.content {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    position: relative;
    white-space: nowrap;
    overflow: hidden;

    font-size: 14px;
    font-weight: 600;
    padding: 0px;
    width: calc(100% - 96px);
    gap: 6px;
    border: 0;
    border-radius: var(--toolbarResultsBorderRadius);
    max-height: inherit;
    min-height: 0;

    color: var(--primaryText);
    background: var(--toolbarButtonBackground);

    backdrop-filter: blur(10px) saturate(180%);
    -webkit-backdrop-filter: blur(24px) saturate(180%);

    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.32),
        inset 0 -10px 18px rgba(255, 255, 255, 0.08),
        0 8px 30px rgba(0, 0, 0, 0.15);

    transition:
        background-color var(--primaryInteraction),
        color var(--primaryInteraction),
        transform var(--primaryInteraction);

    pointer-events: auto;
}

@media screen and (max-width: 478px) {
    .toolbar-results.content {
        width: 100%
    }
}

.toolbar-results.content::before {
    content: "";
    position: absolute;
    inset: 0;
    padding: var(--toolbarButtonBorderWidth);
    border-radius: inherit;
    pointer-events: none;

    background: var(--toolbarButtonBorder);

    -webkit-mask:
        linear-gradient(#000 0 0) content-box,
        linear-gradient(#000 0 0);

    -webkit-mask-composite: xor;
    mask-composite: exclude;
}

.toolbar-results.title {
    width: 100%;
    padding: 6px 12px;
    text-align: left;
}

.toolbar-results.empty,
.toolbar-results.populated {
    width: 100%;
    max-height: inherit;
    min-height: 0;
}

.toolbar-results.populated.is-hidden {
    display: none;
}

.toolbar-results.populated {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    gap: 6px;
    padding: 6px;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
}

.toolbar-results.populated.is-loading .toolbar-results.title {
    display: none;
}

.toolbar-results.populated.is-loading .toolbar.location {
    display: none;
}

.toolbar-results.empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;

    white-space: wrap;
    text-align: center;

    gap: 6px;
    padding: 12px;

    max-width: 256px;
}

.toolbar-results.empty.is-hidden {
    display: none;
}

.toolbar-results.empty .icon {
    width: 22px;
    height: 22px;
}

.toolbar-results.empty .title {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primaryWarning);
    gap: 6px;
    font-size: 16px;
}

.toolbar-results.empty .subtitle {

    width: 75%;
    gap: 6px;

    font-size: 14px;
    font-weight: 500;

    color: var(--toolbarText);
}

.toolbar-results.empty .subtitle a {
    color: var(--primaryAccent);
    text-decoration: underline;

}

/* --- Toolbar Results ---  */
/* --- Toolbar Products --- */

.toolbar.product.card {
    display: flex;
    flex-direction: row;
    align-items: center;
    width: 100%;
    padding: 12px;
    border: 0;
    border-radius: 14px;
    appearance: none;
    background: var(--toolbarButtonBackground);
    color: inherit;
    font-family: inherit;
    text-align: inherit;
    cursor: pointer;
    transition: var(--primaryInteraction);
}

template.toolbar.product.card {
    display: none;
}

.toolbar.product.card:hover {
    background: var(--toolbarButtonBackgroundHover);
}

.toolbar.product.card.is-skeleton {
    cursor: default;
    pointer-events: none;
    background: color-mix(in srgb, var(--toolbarButtonBackground) 88%, var(--primaryText) 12%);
}

.toolbar.product.card.is-skeleton:hover {
    background: color-mix(in srgb, var(--toolbarButtonBackground) 88%, var(--primaryText) 12%);
}

.toolbar-results.skeleton-block {
    display: block;
    border-radius: 999px;
    background: linear-gradient(100deg,
            color-mix(in srgb, var(--primaryText) 12%, transparent) 0%,
            color-mix(in srgb, var(--primaryText) 24%, transparent) 45%,
            color-mix(in srgb, var(--primaryText) 12%, transparent) 90%);
    background-size: 220% 100%;
    animation: toolbarSkeletonPulse 1.15s ease-in-out infinite;
}

.toolbar.product.card.is-skeleton .skeleton-image {
    width: 48px;
    height: 48px;
    min-width: 48px;
    min-height: 48px;
    max-width: 48px;
    max-height: 48px;
    border-radius: 16px;
    corner-shape: squircle;
}

.toolbar.product.card.is-skeleton .skeleton-title {
    width: min(180px, 72%);
    height: 14px;
    margin-bottom: 8px;
}

.toolbar.product.card.is-skeleton .skeleton-subtitle {
    width: min(132px, 58%);
    height: 12px;
}

.toolbar.product.card.is-skeleton .skeleton-price {
    width: 58px;
    height: 14px;
    margin-bottom: 8px;
}

.toolbar.product.card.is-skeleton .skeleton-distance {
    width: 34px;
    height: 12px;
}

@keyframes toolbarSkeletonPulse {
    0% {
        background-position: 120% 0;
    }

    100% {
        background-position: -120% 0;
    }
}

.toolbar.product.card img {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    width: 48px;
    height: 48px;
    min-width: 48px;
    min-height: 48px;
    max-width: 48px;
    max-height: 48px;
    border-radius: 16px;
    corner-shape: squircle;
    border: 0.5px solid var(--primaryBorder);
}

.toolbar.product.card .details {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    text-align: left;
    margin-left: 12px;
}

.toolbar.product.card .details .title {
    font-size: 14px;
    font-weight: 700;
}

.toolbar.product.card .details .subtitle {
    font-size: 12px;
    font-weight: 500;
    color: var(--secondaryText);
}

.toolbar.product.card .locality {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: center;
    text-align: right;
    white-space: nowrap;
    margin-right: 6px;
}

.toolbar.product.card .locality .title {
    font-size: 14px;
    font-weight: 700;
}

.toolbar.product.card .locality .subtitle {
    font-size: 12px;
    font-weight: 500;
    color: var(--secondaryText);
}

/* --- Toolbar Products --- */
