/* TRANSPORTNA VOZILA — NASLOVNA */

body:has(#homeSearch) {
    background: #101820;
}

body:has(#homeSearch) .search-section {
    background: linear-gradient(135deg,#101820,#203247);
    padding: 70px 20px 90px;
    min-height: auto;
}

body:has(#homeSearch) .search-section .bg-overlay {
    display: none;
}

body:has(#homeSearch) .search-section h1 {
    color: #fff;
    font-size: clamp(36px,4vw,60px);
    font-weight: 800;
    line-height: 1.1;
}

body:has(#homeSearch) .search-section p {
    color: #b8c6d5;
    font-size: 17px;
}

body:has(#homeSearch) .hero-promo,
body:has(#homeSearch) .home-top-tabs,
body:has(#homeSearch) .category-links-home,
body:has(#homeSearch) #partsTabsWrap {
    display: none !important;
}

body:has(#homeSearch) .glass-form-container--hero {
    max-width: 1200px;
    margin: 35px auto 0;
    padding: 28px;
    background: #1833251c;
    border: 1px solid #304253;
    border-radius: 20px;
    box-shadow: 0 25px 70px rgba(0,0,0,.3);
}

body:has(#homeSearch) #homeSearch {
    display: flex;
    flex-direction: column;
    gap: 22px;
}

body:has(#homeSearch) #transportTabsWrap {
    order: -2;
    display: block !important;
}

body:has(#homeSearch) .home-search-compact {
    order: -1;
    width: 100%;
}

body:has(#homeSearch) #aoTransportTabsHome {
    display: grid;
    grid-template-columns: repeat(5,minmax(0,1fr));
    gap: 10px;
}

body:has(#homeSearch) #aoTransportTabsHome .ao-transport-tab {
    width: 100%;
    min-width: 0;
    padding: 15px 10px;
    background: #243647;
    border: 1px solid #40566b;
    border-radius: 12px;
    color: #fff;
}

body:has(#homeSearch) #aoTransportTabsHome .ao-transport-tab.active {
    background: #3b3028;
    border-color: #ff7918;
    outline: 0;
}

body:has(#homeSearch) #aoTransportTabsHome .ao-transport-label {
    color: #fff;
}

body:has(#homeSearch) #aoTransportTabsHome .ao-transport-sub,
body:has(#homeSearch) .ao-help-note {
    color: #a9b8c7;
}

body:has(#homeSearch) .home-search-row {
    display: grid;
    grid-template-columns: repeat(4,minmax(0,1fr));
    gap: 12px;
    margin-bottom: 12px;
}

body:has(#homeSearch) .home-search-col {
    width: 100%;
    min-width: 0;
    max-width: none;
    padding: 0;
}

body:has(#homeSearch) #homeSearch .form-control,
body:has(#homeSearch) #homeSearch .select2-selection {
    width: 100%;
    min-height: 50px;
    background: #101e2b;
    color: #e8eef5;
    border: 1px solid #405267;
    border-radius: 9px;
}

body:has(#homeSearch) #homeSearch .select2-container {
    width: 100% !important;
}

body:has(#homeSearch) #homeSearch .home-search-btn {
    width: 100%;
    min-height: 50px;
    background: #ff7918;
    color: #111820;
    border: none;
    border-radius: 9px;
    font-weight: 800;
}

body:has(#homeSearch) .home-search-actions {
    order: 1;
    text-align: center;
}

body:has(#homeSearch) .front-results {
    background: #101820;
    padding: 60px 0 100px;
}

body:has(#homeSearch) .section-kicker {
    color: #ff7918;
    font-weight: 800;
    letter-spacing: .12em;
}

body:has(#homeSearch) .section-heading {
    color: #fff;
    font-size: 28px;
    font-weight: 800;
}

body:has(#homeSearch) .fp-grid {
    display: grid;
    grid-template-columns: repeat(3,minmax(0,1fr));
    gap: 22px;
}

body:has(#homeSearch) .fp-card {
    overflow: hidden;
    background: #1b2937;
    border: 1px solid #304355;
    border-radius: 16px;
    box-shadow: none;
}

body:has(#homeSearch) .fp-photo img {
    width: 100%;
    height: 230px;
    object-fit: cover;
}

body:has(#homeSearch) .fp-body {
    padding: 20px;
}

body:has(#homeSearch) .fp-title a {
    color: #fff;
    font-size: 18px;
    font-weight: 800;
}

body:has(#homeSearch) .fp-price {
    color: #ff7918;
    font-size: 22px;
    font-weight: 800;
}

body:has(#homeSearch) .fp-meta,
body:has(#homeSearch) .fp-foot {
    color: #aebdcb;
}

@media(max-width:991px) {
    body:has(#homeSearch) #aoTransportTabsHome {
        grid-template-columns: repeat(3,minmax(0,1fr));
    }

    body:has(#homeSearch) .home-search-row,
    body:has(#homeSearch) .fp-grid {
        grid-template-columns: repeat(2,minmax(0,1fr));
    }
}

@media(max-width:575px) {
    body:has(#homeSearch) .search-section {
        padding: 40px 12px;
    }

    body:has(#homeSearch) .glass-form-container--hero {
        padding: 16px;
    }

    body:has(#homeSearch) #aoTransportTabsHome {
        grid-template-columns: repeat(2,minmax(0,1fr));
    }

    body:has(#homeSearch) .home-search-row,
    body:has(#homeSearch) .fp-grid {
        grid-template-columns: 1fr;
    }
}

/* Pozadinska fotografija naslovne */
body:has(#homeSearch) .search-section {
    background-image:
        linear-gradient(
            90deg,
            rgba(9, 19, 31, .84) 0%,
            rgba(12, 26, 43, .72) 50%,
            rgba(9, 19, 31, .88) 100%
        ),
        url('/frontend/images/transport-hero.webp');

    background-size: cover;
    background-position: center 45%;
    background-repeat: no-repeat;
    background-color: #101820;
}

@media (max-width: 767px) {
    body:has(#homeSearch) .search-section {
        background-position: center center;
    }
}

/* OGLASI — SVETLIJI DIZAJN, 4 KOLONE */
body:has(#homeSearch) .front-results {
    background: #edf1f5;
    padding: 55px 0 85px;
}

body:has(#homeSearch) .front-results > .container {
    max-width: 1440px;
    width: 94%;
}

body:has(#homeSearch) .section-heading {
    color: #17283b;
    font-size: 27px;
}

body:has(#homeSearch) .section-sub {
    color: #697b8c;
}

body:has(#homeSearch) .section-kicker {
    color: #e46b13;
    font-size: 12px;
}

body:has(#homeSearch) .fp-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
}

body:has(#homeSearch) .fp-card {
    background: #ffffff;
    border: 1px solid #dce3eb;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 6px 22px rgba(20, 35, 55, .06);
    transition: transform .2s ease, box-shadow .2s ease;
}

body:has(#homeSearch) .fp-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 15px 35px rgba(20, 35, 55, .13);
}

body:has(#homeSearch) .fp-photo img {
    width: 100%;
    height: 205px;
    object-fit: cover;
}

body:has(#homeSearch) .fp-body {
    padding: 17px;
}

body:has(#homeSearch) .fp-title a {
    color: #17283b;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.4;
}

body:has(#homeSearch) .fp-price {
    color: #e66e13;
    font-size: 20px;
    font-weight: 800;
}

body:has(#homeSearch) .fp-type {
    color: #64748b;
}

body:has(#homeSearch) .fp-meta,
body:has(#homeSearch) .fp-foot {
    color: #64748b;
    font-size: 12px;
}

body:has(#homeSearch) .fp-brand a {
    color: #2563a6;
}

@media (max-width: 1100px) {
    body:has(#homeSearch) .fp-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    body:has(#homeSearch) .fp-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 480px) {
    body:has(#homeSearch) .fp-grid {
        grid-template-columns: 1fr;
    }
}

/* TRANSPORTNA VOZILA — PREMIUM KARTICE OGLASA */

body:has(#homeSearch) .fp-card {
    display: flex;
    flex-direction: column;
    background: #fff;
    border: 1px solid #dce4ec;
    border-radius: 17px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(20,35,55,.07);
}

body:has(#homeSearch) .fp-photo {
    position: relative;
    overflow: hidden;
    background: #e9eef3;
}

body:has(#homeSearch) .fp-photo > a img {
    display: block;
    width: 100%;
    height: 210px;
    object-fit: cover;
    transition: transform .35s ease;
}

body:has(#homeSearch) .fp-card:hover .fp-photo > a img {
    transform: scale(1.045);
}

/* Marka — umesto običnog plavog linka */
body:has(#homeSearch) .fp-brand {
    position: absolute;
    left: 12px;
    bottom: 12px;
    z-index: 2;
    background: rgba(15,25,37,.88);
    border: 1px solid rgba(255,255,255,.16);
    border-radius: 8px;
    padding: 6px 12px;
    backdrop-filter: blur(8px);
}

body:has(#homeSearch) .fp-brand a {
    color: #fff !important;
    font-size: 12px;
    font-weight: 800;
    text-decoration: none;
    letter-spacing: .02em;
}

/* Sadržaj */
body:has(#homeSearch) .fp-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    gap: 11px;
    padding: 18px;
}

body:has(#homeSearch) .fp-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
}

/* Stanje vozila */
body:has(#homeSearch) .fp-type {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    padding: 5px 10px;
    background: #edf4fa;
    border: 1px solid #d9e6f1;
    border-radius: 7px;
    color: #36516b;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .06em;
}

/* Cena */
body:has(#homeSearch) .fp-price {
    color: #e96d0b;
    font-size: 19px;
    font-weight: 900;
    line-height: 1.2;
}

/* Naziv vozila */
body:has(#homeSearch) .fp-title {
    min-height: 48px;
}

body:has(#homeSearch) .fp-title a {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    color: #182b40 !important;
    font-size: 16px;
    font-weight: 800;
    line-height: 1.45;
    text-decoration: none;
}

body:has(#homeSearch) .fp-title a:hover {
    color: #e96d0b !important;
}

/* Tehnički podaci */
body:has(#homeSearch) .fp-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

body:has(#homeSearch) .fp-meta span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 9px;
    background: #f2f5f8;
    border: 1px solid #e7edf2;
    border-radius: 7px;
    color: #52667a;
    font-size: 11px;
    font-weight: 600;
}

body:has(#homeSearch) .fp-meta i {
    color: #e96d0b;
}

/* Lokacija i vreme */
body:has(#homeSearch) .fp-foot {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px solid #e8edf2;
    color: #738396;
    font-size: 11px;
}

body:has(#homeSearch) .fp-foot i {
    color: #e96d0b;
}

@media (max-width: 575px) {
    body:has(#homeSearch) .fp-body {
        padding: 15px;
    }

    body:has(#homeSearch) .fp-photo > a img {
        height: 220px;
    }
}
