/* Home hero search: one floating pill (field + round submit), so the control
   reads as part of the photo hero instead of a white form block. */

body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    width: 100%;
    min-height: 0;
    margin-top: auto;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: none;
    box-shadow: none;
}

/* Field: the pill. The submit button is laid over its right end in the same grid cell. */
body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__ai-control {
    grid-area: 1 / 1;
    gap: 12px;
    min-height: 60px;
    padding: 0 68px 0 20px;
    border: 1px solid rgba(255, 255, 255, .6);
    border-radius: 999px;
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 16px 38px rgba(4, 12, 18, .32), 0 1px 0 rgba(255, 255, 255, .6) inset;
    transition: box-shadow .2s ease, border-color .2s ease;
}

body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__ai-control:focus-within {
    border-color: transparent;
    box-shadow: 0 16px 38px rgba(4, 12, 18, .32), 0 0 0 3px rgba(255, 122, 56, .75);
}

body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__ai-control > img {
    width: 22px;
    height: 22px;
    flex-basis: 22px;
    opacity: .72;
}

body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__ai-control input {
    height: 28px;
    font-size: 16px;
    font-weight: 600;
}

body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__input-hint {
    display: none;
}

body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__submit {
    grid-area: 1 / 1;
    justify-self: end;
    align-self: center;
    width: 48px;
    height: 48px;
    min-height: 0;
    margin-right: 6px;
    padding: 0;
    border-radius: 50%;
    gap: 0;
    background: linear-gradient(145deg, #ff7f3f 0%, #ff5a14 100%);
    box-shadow: 0 8px 18px rgba(255, 90, 20, .4);
    transition: transform .2s ease, box-shadow .2s ease;
}

body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__submit:hover {
    background: linear-gradient(145deg, #ff7f3f 0%, #ff5a14 100%);
    transform: scale(1.05);
}

body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__submit:active {
    transform: scale(.94);
}

/* Icon-only on phones; the label stays available to screen readers. */
body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__submit-label {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__submit img {
    width: 20px;
    height: 20px;
}

/* Map link under the form. */
body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > .tt-home-hero__buttons {
    margin-top: 14px;
}

@media (min-width: 768px) {
    body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search {
        width: 680px;
        max-width: calc(100vw - 96px);
        margin-top: 26px;
    }

    body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__ai-control {
        min-height: 64px;
        padding-left: 24px;
        padding-right: 200px;
    }

    body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__submit {
        width: auto;
        height: 50px;
        gap: 10px;
        padding: 0 22px;
        border-radius: 999px;
    }

    body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__submit-label {
        position: static;
        width: auto;
        height: auto;
        overflow: visible;
        clip: auto;
        font-size: 15px;
        font-weight: 800;
    }

    body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__submit img {
        width: 17px;
        height: 17px;
    }
}

html[data-theme="dark"] body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__ai-control {
    border-color: rgba(255, 255, 255, .12);
    background: rgba(21, 35, 55, .94);
}

html[data-theme="dark"] body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__ai-control > img {
    opacity: .9;
}

@media (prefers-reduced-motion: reduce) {
    body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__submit,
    body.page-home-redesign .tt-home-v2 .tt-home-hero__copy > form.tt-home-hero__search .tt-route-finder__ai-control {
        transition: none;
    }
}
