/**
 * Phone layout fixes, especially iPhone widths and tap targets.
 */

html {
    -webkit-text-size-adjust: 100%;
}

img,
video,
iframe,
embed,
object {
    max-width: 100%;
}

@supports (padding: max(0px)) {
    body {
        padding-left: env(safe-area-inset-left);
        padding-right: env(safe-area-inset-right);
    }
}

@media (max-width: 991px) {
    html,
    body {
        overflow-x: hidden;
    }

    .banner,
    .parallax {
        background-attachment: scroll !important;
    }

    .header {
        padding: 8px 0 0;
    }

    .navbar-header {
        display: flex !important;
        align-items: center;
        justify-content: space-between;
        width: 100%;
    }

    .navbar-header > * {
        display: block !important;
    }

    .navbar-brand {
        float: none;
        height: auto;
        max-width: calc(100% - 64px);
        padding: 8px 0 !important;
    }

    .navbar-brand img {
        max-height: 58px;
        max-width: 100%;
        width: auto;
        height: auto;
    }

    .navbar-toggle {
        float: none;
        display: inline-flex !important;
        align-items: center;
        justify-content: center;
        min-width: 44px;
        min-height: 44px;
        margin: 0;
        border: 1px solid #d0d0d0;
        border-radius: 8px;
        color: #222;
    }

    .navbar-collapse {
        background: #fff;
        margin-top: 8px;
    }

    .navbar-nav li a {
        min-height: 44px;
        font-size: 17px !important;
    }

    .topbar p {
        margin-bottom: 0;
        font-size: 14px;
        line-height: 1.5;
    }

    .social a {
        min-width: 44px;
        min-height: 44px;
        line-height: 44px;
        text-align: center;
    }
}

@media (max-width: 767px) {
    .container {
        padding-left: 16px;
        padding-right: 16px;
    }

    .section {
        padding: 36px 0;
    }

    .general-title {
        margin-bottom: 28px;
    }

    .general-title h4 {
        font-size: 20px;
        line-height: 1.35;
        letter-spacing: 0;
    }

    .page-title h2 {
        font-size: 22px !important;
        line-height: 1.3;
    }

    .page-title h2 small {
        display: block;
        margin-top: 4px;
        font-size: 14px;
    }

    .title-area,
    .title-area.pull-left,
    .copyright .text-left,
    .copyright .text-right {
        float: none !important;
        text-align: center !important;
        width: 100%;
    }

    .copyright .list-inline {
        padding-left: 0;
        text-align: center;
    }

    .banner {
        min-height: 140px;
    }

    #heroCarousel .item img {
        height: 230px !important;
    }

    #heroCarousel .carousel-caption {
        left: 12px !important;
        right: 12px !important;
        bottom: 28px !important;
        transform: none !important;
        min-width: 0 !important;
        max-width: none !important;
        width: auto !important;
        padding: 8px 10px !important;
        display: block !important;
        box-sizing: border-box;
        text-align: center;
    }

    #heroCarousel .carousel-caption h2,
    #heroCarousel .carousel-caption h2 strong {
        font-size: 16px !important;
        line-height: 1.3 !important;
        white-space: normal !important;
    }

    .services-gallery-section h2 {
        font-size: 26px !important;
    }

    a[href="new.php"].btn,
    a[href="used.php"].btn,
    .whatsnew-button {
        display: block !important;
        width: 100% !important;
        white-space: normal !important;
        font-size: 16px !important;
        padding: 14px 16px !important;
    }

    .manufacturer-item:hover {
        transform: none;
    }

    input,
    select,
    textarea,
    .form-control {
        font-size: 16px !important;
    }

    .footer .widget ul li {
        overflow-wrap: anywhere;
    }

    div.header {
        flex-wrap: wrap;
        gap: 12px;
    }

    div.header h1 {
        font-size: 1.45rem;
        margin: 0;
    }
}
