
:root {
    --spro-green: #76b72a;
    --spro-blue: #3da5ff;
    --spro-blue-dark: #2c82d4;
    --spro-dark: #2f3b45;
}

/* GLOBAL */
body {
    font-family: 'Montserrat', system-ui, -apple-system, "Segoe UI", sans-serif;
    color: black;
}

/* PREHEADER */
.preheader {
    background: #f0f0f0;
    padding: 10px 0;
    font-size: 16px;
}

/* links in preheader — black and no underline only here */
.preheader a,
.preheader a:visited,
.preheader a:active {
    font-size: 18px;
    color: #000;
    text-decoration: none;
}

.preheader a:hover {
    color: #000;
    text-decoration: none;
}

/* HEADER */
.header-main {
    background: #E3E3E3;
    padding: 5px 0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.15);
    position: relative;
    z-index: 10;
}

.header-logo {
    width: auto;
}

.header-logo-text {
    font-weight: 700;
    font-size: 22px;
    line-height: 1.1;
}

.header-logo-text div:last-child {
    font-size: 18px;
}

/* SEARCH MODE CARDS (Продажби/Наеми/Купува/Наема) */
.search-mode-card {
    background: #BDF7A1;
    color: black;
    border: none;
    border-radius: 0.75rem;
    cursor: pointer;
    transition: background .15s ease, transform .1s ease, box-shadow .15s ease;
}

.search-mode-card i,
.search-mode-card span {
    color: black;
}

.search-mode-card:hover {
    background: #94D474;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

.search-mode-card.active {
    background: #94D474;
    box-shadow: 0 0 0 2px rgba(0,0,0,0.2);
}

/* SEARCH FORM CARD */
#search-form.card {
    border-radius: 1rem;
    border: 1px solid rgba(0, 0, 0, 0.06);
    background: #ffffff;
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.25);
}

#search-form .card-body {
    padding: 2rem 2rem 2.25rem;
}

#search-form h2 {
    font-weight: 700;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    padding-bottom: 0.75rem;
    margin-bottom: 1.5rem;
}

/* OFFERS */
.offer-card {
    border-radius: 1rem !important;
    background: #ffffff !important;
    border: 1px solid #000 !important;
    overflow: hidden;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.20);
    transition: box-shadow .15s ease;
}

.offer-card:hover {
    box-shadow: 0 16px 36px rgba(0, 0, 0, 0.28);
    background: #F0F0F0 !important;
}

.offer-card .row.g-0 {
    border-radius: 1rem;
    overflow: hidden;
}

.offer-image {
    width: 100%;
    height: 220px;
    object-fit: cover;
}

.offer-price {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--spro-green);
}

.offer-main-image {
    cursor: zoom-in;
}

/* FOOTER */
.footer-main {
    background: #d5d5d5 !important;
    font-size: 16px;
}

.footer-main p,
.footer-main li,
.footer-main a,
.footer-main h5 {
    font-size: 16px;
}

.footer-logo {
    max-height: 100px;
    width: auto;
}

.footer-banners {
    display: grid;
    grid-template-columns: repeat(2, auto);
    column-gap: 24px;
    row-gap: 12px;
    justify-content: flex-end;
}

.footer-banner {
    max-height: 80px;
    width: auto;
}

/* Button styles */
.btn-primary,
.btn-primary:visited,
.btn-primary:active {
    color: #fff !important;
}

/* Share buttons in offer details */
.offer-details .share-buttons .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.45rem 0.9rem;
    font-size: 14px;
}

.offer-details .share-buttons .btn i {
    margin-right: 0.50rem;
}

/* Links with semi-bold font weight */
.fw-semibold a {
    font-size: 16px;
}

.fw-semibold a:hover {
    color: blue;
}

/* Media queries grouped by breakpoint */

/* MOBILE NAVBAR (< 992px) and related mobile styles */
@media (max-width: 991.98px) {
    .header-logo {
        height: 64px; /* 80px * 0.8 */
    }

    .navbar .spro-nav-list .nav-link {
        background: transparent !important;
        color: #000 !important;
        box-shadow: none;
        border-radius: 0;
        padding: 0.5rem 0;
        margin: 0;
        text-align: left;
        width: 100%;
        border-bottom: 1px solid rgba(0,0,0,0.1);
    }

    .navbar .spro-nav-list .nav-link:last-child {
        border-bottom: none;
    }

    .navbar .spro-nav-list .nav-link.active {
        background: transparent !important;
        color: var(--spro-green) !important;
        font-weight: 700;
    }

    #heroCarousel .ratio-21x9 {
        --bs-aspect-ratio: 70%;
    }

    .section-title {
        font-size: 22px !important;
        font-weight: 700;
    }

    .preheader .preheader-phones {
        font-size: 14px;
        line-height: 1.2;
    }

    .preheader .preheader-phones i {
        font-size: 13px;
    }

    .preheader .preheader-social {
        margin-right: 15px;
    }

    .preheader .preheader-social a {
        margin-right: 10px;
    }

    .preheader .preheader-langs a {
        margin-left: 4px;
    }
}






/* DESKTOP NAVBAR (>= 992px) and desktop-specific styles */
@media (min-width: 992px) {

    .header-logo {
        height: 80px; /* default desktop size */
    }

    .navbar .spro-nav-list .nav-link {
        font-weight: 600;
        font-size: 16px;
        padding-left: 27px !important;
        padding-right: 27px !important;
        padding-top: 0.55rem;
        padding-bottom: 0.55rem;
        border-radius: 15px;
        margin-left: .35rem;
        margin-right: .35rem;
        background: var(--spro-blue);
        color: #fff !important;
        box-shadow: 0 2px 0 rgba(0,0,0,0.15);
        transition: background .15s ease, transform .1s ease, box-shadow .1s ease;
    }

    .navbar .spro-nav-list .nav-link.nav-link-search {
        background: #ffc107;
        color: #000 !important;
        font-size: 18px;
        padding-left: 50px !important;
        padding-right: 50px !important;
        font-weight: 700;
    }

    .navbar .spro-nav-list .nav-link.nav-link-search:hover {
        background: #e0a800;
        box-shadow: 0 3px 0 rgba(0,0,0,0.2);
        transform: translateY(1px);
    }

    .navbar .spro-nav-list .nav-link.nav-link-search.active {
        color: #fff !important;
    }

    .navbar .spro-nav-list .nav-link:hover {
        background: var(--spro-blue-dark);
        transform: translateY(1px);
        box-shadow: 0 1px 0 rgba(0,0,0,0.2);
    }

    .navbar .spro-nav-list .nav-link.active {
        background: var(--spro-green);
    }

    #heroCarousel .ratio-21x9 {
        --bs-aspect-ratio: 70%;
    }

    .section-title {
        font-size: 1.8rem;
        font-weight: 700;
    }

    /* Vertical centering of offer images */
    .offer-card .col-md-4 {
        display: flex;
        align-items: center;
    }

    .offer-card .col-md-4 a {
        display: block;
        width: 100%;
    }

    /* Chessboard effect on home offers */
    .home-offers-list .offer-card {
        max-width: 1150px;
        margin-left: auto;
        margin-right: auto;
    }

    .home-offers-list .offer-card:nth-child(odd) {
        transform: translateX(-30px);
    }

    .home-offers-list .offer-card:nth-child(even) {
        transform: translateX(30px);
    }


   #heroCarousel {
        overflow: hidden;
    }

    #heroCarousel .ratio-21x9 {
        width: 100%;
        height: 650px; /* или конкретна височина, която предпочитате */
        object-fit: cover;
        overflow: hidden;
    }

    #heroCarousel img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }

}



/* --- FINAL REFINED BOXED LAYOUT (DESKTOP ONLY) --- */
@media (min-width: 992px) {

    /* 1. GLOBAL BACKGROUND SETTINGS (Вашите нови изисквания) */
    body {
        /* 1. Слагаме снимката да започва отгоре и да НЕ се повтаря */
        background: url('/img/bgr/bgr_3.jpg') no-repeat top center scroll !important;
        
        /* 2. Задаваме ширина 100% и височина 850px (това покрива header + slider) */
        background-size: 100% 825px !important;
        
        /* 3. Всичко под тези 850px ще бъде бяло */
        #background-color: #ffffff !important;
	background-color: #e9ecef !important;
    }

    /* 2. REMOVE GAPS (Премахваме разстоянията между елементите) */ 
    body .preheader, 
    body .header-main,
    body section.py-3,
    body section.py-4,
    body section.py-5 {
        background-color: transparent !important;
        padding-top: 0 !important;
        padding-bottom: 0 !important;
        margin-top: 0 !important;
        margin-bottom: 0 !important;
        border: none !important;
    }


    body footer.footer-main {
        background-color: transparent !important;
        padding-top: 0 !important;
        padding-bottom: 0 !important;
        margin-top: 0 !important;
        margin-bottom: 0 !important;
        border: none !important;
        }

    /* 3. MERGE CONTAINERS INTO ONE COLUMN */
    .preheader > .container,
    .header-main > .container,
    .header-main + .container, /* The Slider Wrapper (Контейнерът преди секциите) */
    section > .container,
    footer.footer-main > .container,
    footer .container.pt-4 {
        margin: 0 auto !important;
        width: 100%;
        border-radius: 0 !important;
        box-shadow: 0 0 15px rgba(0,0,0,0.15);
        position: relative;
    }

    /* 4. RE-ADD PADDING INSIDE THE BOXES & SET COLORS */

    /* --- GROUP A: TOP SECTIONS (Light Gray #f8f9fa) --- */
    .preheader > .container,
    .header-main > .container,
    .header-main + .container {
        background-color: #EBEBEB !important;
        border-bottom: none !important;
    }

    /* Specific tight padding for header elements */
    .preheader > .container {
        padding-top: 5px !important;
        padding-bottom: 5px !important;
        border-bottom: 2px solid #dee2e6 !important;
    }
    .header-main > .container {
        padding-top: 10px !important;
        padding-bottom: 10px !important;
    }
    /* КОРЕКЦИЯ ТУК: Премахваме големия padding от слайдера за да се залепи плътно към навигацията */
    .header-main + .container { /* Slider Wrapper */
        padding-top: 0 !important; /* Промяна: 10px -> 0 */
        padding-bottom: 25px !important; /* Запазваме отстоянието преди "Най-нови предложения" */
    }

    /* Remove padding from the slider carousel itself */
    #heroCarousel {
        padding-top: 0 !important;
        padding-bottom: 0 !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
        margin-right: -10px;
        margin-left: -10px;
  }

    /* --- GROUP B: CONTENT SECTIONS (White #ffffff) --- */
    section > .container {
        background-color: #ffffff !important;
        padding-top: 30px !important;
        padding-bottom: 30px !important;
    }

    /* --- GROUP C: FOOTER (White #ffffff) --- */
    footer.footer-main > .container {
        background: #d5d5d5; !important;
        padding-top: 40px !important;
        padding-bottom: 20px !important;
    }

    /* Fix for the small copyright text at the very bottom */
    footer .container.pt-4 {
        padding-top: 0 !important;
        padding-bottom: 10px !important;
        background: #d5d5d5; !important;
        margin-top: -1px !important;
    }

footer .container.pt-4 p.text-center {
    padding-top: 10px;
    padding-bottom: 0px !important;
    margin-top: 0 !important; /* Нулираме горното отстояние на параграфа */
    margin-bottom: 0px;
}



}
