/* ==========================================================================
   Tikras Turtas — modern portal skin (v3)
   Clean listing-portal look: blue & white, borderless cards.
   Loaded after theme.css/custom.css; everything is scoped to body.theme-modern.
   ========================================================================== */

:root {
    --tt-blue: #015bbb;
    --tt-blue-dark: #0a4796;
    --tt-blue-soft: #e8f0fb;
    --tt-accent: #015bbb;          /* brand blue: buttons, CTA, highlights */
    --tt-accent-hover: #0a4796;
    --tt-accent-ink: #fff;         /* text on accent */
    --tt-accent-soft: #e8f0fb;     /* light blue tint: prices, promo, badges */
    --tt-accent-soft-ink: #0a4796; /* text on the tint */
    --tt-ink: #1d2126;
    --tt-text: #29323c;
    --tt-muted: #5b6473;
    --tt-faint: #a4aab4;
    --tt-line: #ebecee;
    --tt-line-strong: #d2d6db;
    --tt-bg: #f3f5f7;
    --tt-white: #fff;
    --tt-danger: #d4282b;
    --tt-radius-lg: 16px;
    --tt-radius: 12px;
    --tt-radius-sm: 8px;
    --tt-shadow: 0 8px 24px rgba(29, 33, 38, .08);
    --tt-shadow-sm: 0 2px 8px rgba(29, 33, 38, .06);
    --tt-ease: cubic-bezier(.2, .7, .2, 1);
}

/* ---------- Base ---------------------------------------------------------- */
html:has(body.theme-modern) { scroll-behavior: smooth; }
.theme-modern {
    background: var(--tt-white);
    color: var(--tt-text);
    font-size: 15px;
    line-height: 1.55;
}
.theme-modern a { color: var(--tt-blue); transition: color .15s var(--tt-ease); }
.theme-modern a:hover { color: var(--tt-blue-dark); }
.theme-modern h1, .theme-modern h2, .theme-modern h3, .theme-modern h4 { color: var(--tt-ink); font-weight: 700; }
.theme-modern .container { max-width: 1240px; width: auto; padding-left: 24px; padding-right: 24px; }
@media (max-width: 767px) { .theme-modern .container { padding-left: 16px; padding-right: 16px; } }
.theme-modern ::selection { background: var(--tt-accent); color: var(--tt-accent-ink); }

/* ---------- Top utility bar (language, phone, favourites, login) ---------- */
.theme-modern .header {
    background: var(--tt-accent);
    color: rgba(255, 255, 255, .85);
    border-bottom: 0;
    font-size: 14px;
}
.theme-modern .header__row { min-height: 44px; align-items: center; }
.theme-modern .header a,
.theme-modern .header .dropdown__btn,
.theme-modern .header .auth__nav-btn,
.theme-modern .header .header__span { color: var(--tt-white); }
.theme-modern .header a:hover { color: var(--tt-white); opacity: .85; }
.theme-modern .header .fa,
.theme-modern .header .fa-solid { color: var(--tt-white); font-size: 16px; }
.theme-modern .header .dropdown__btn img { width: 22px; height: auto; border-radius: 3px; margin-right: 4px; }
.theme-modern .header__phone { font-weight: 600; }
.theme-modern .header .badge-num {
    background: var(--tt-white); color: var(--tt-accent);
    font-weight: 700; border-radius: 999px; min-width: 18px; padding: 0 5px;
}
/* "Log in": white outline button on the blue bar */
.theme-modern .auth--header .auth__nav-btn {
    background: transparent;
    color: var(--tt-white);
    border: 1px solid rgba(255, 255, 255, .6);
    border-radius: var(--tt-radius-sm);
    padding: 5px 14px;
    font-weight: 600;
    transition: background .15s, border-color .15s;
}
/* icon and text centred on one line (the theme made the text a padded block) */
.theme-modern .auth--header .auth__nav-btn {
    display: inline-flex; align-items: center; gap: 7px;
    height: 32px; line-height: 1;
}
.theme-modern .auth--header .auth__nav-btn .fa { margin: 0; line-height: 1; font-size: 14px; }
.theme-modern .auth--header .auth__nav-btn .header__span { display: inline; padding: 0; margin: 0; line-height: 1; }
.theme-modern .auth--header .auth__nav-btn:hover { background: var(--tt-white); border-color: var(--tt-white); color: var(--tt-accent); }
.theme-modern .auth--header .auth__nav-btn:hover .fa,
.theme-modern .auth--header .auth__nav-btn:hover .header__span { color: var(--tt-accent); }
/* Dropdown panels opened from the blue bar keep dark text on white */
.theme-modern .header .dropdown__menu a,
.theme-modern .header .dropdown__menu .form__options,
.theme-modern .header .dropdown__menu button.toggle-forms { color: var(--tt-ink); }
.theme-modern .header .dropdown__menu .fa { color: var(--tt-muted); }
.theme-modern .dropdown__menu {
    border: 1px solid var(--tt-line);
    border-radius: var(--tt-radius);
    box-shadow: var(--tt-shadow);
}
/* Header dropdowns (language, login, notifications): white panel, dark items */
.theme-modern .header .dropdown__menu {
    background: var(--tt-white) !important;
    color: var(--tt-text);
    padding: 6px;
}
.theme-modern .header .dropdown__menu ul { margin: 0; padding: 0; }
.theme-modern .header .dropdown__menu:before,
.theme-modern .header .dropdown__menu:after { display: none; }
.theme-modern .header .dropdown__item { list-style: none; }
.theme-modern .header .dropdown__link {
    display: flex; align-items: center; gap: 8px;
    padding: 8px 10px;
    border-radius: var(--tt-radius-sm);
    color: var(--tt-ink) !important;
    background: none;
    font-weight: 500;
    white-space: nowrap;
}
.theme-modern .header .dropdown__link:hover { background: var(--tt-bg) !important; color: var(--tt-ink) !important; text-decoration: none; }
.theme-modern .header .dropdown__link img,
.theme-modern .header .dropdown__link.flag img { width: 22px; height: auto; margin: 0; border-radius: 3px; flex: none; }
.theme-modern .header .dropdown--header .dropdown__link { padding: 8px 10px; }
.theme-modern .header .dropdown--header .dropdown__menu { width: auto !important; min-width: 150px; }
.theme-modern .header .auth__title { color: var(--tt-ink); text-transform: none; }

/* Notifications panel: wider, and every item wraps so the whole message is readable */
.theme-modern #notifications { width: 480px; max-width: calc(100vw - 24px); }
.theme-modern .notification-settings { width: 100%; right: 100%; }
.theme-modern .notification-settings.open { right: 0; }
.theme-modern #notification-container .dropdown__link {
    display: block; white-space: normal; overflow-wrap: anywhere;
    padding: 8px 28px 8px 36px;
    border-radius: 0;
    font-weight: 400; line-height: 1.4;
}
.theme-modern #notification-container .dropdown__link .time { margin-left: 10px; font-size: 12px; }
.theme-modern #notification-container.empty:after { left: calc(50% - 81px); }
.theme-modern #notification-container.loading:after { left: calc(50% - 87px); }

/* Login / password reset panels under the "Log in" button */
.theme-modern .auth--header .auth__nav { position: relative; }
.theme-modern .auth--header .auth__nav-item { position: static; }
.theme-modern .auth--header .dropdown__menu {
    left: auto !important; right: 0 !important; top: calc(100% + 8px) !important;
    width: 320px; max-width: calc(100vw - 32px);
    padding: 22px 22px 18px !important;
    border-radius: var(--tt-radius-lg);
    box-shadow: 0 16px 40px rgba(29, 33, 38, .16);
    text-align: left;
    margin: 0 !important; /* theme.css shifts the reset panel 36px right */
}
.theme-modern .auth--header .auth__title {
    margin: 0 0 16px; padding: 0; border: 0;
    font-size: 18px; font-weight: 700; letter-spacing: 0; line-height: 1.3;
}
.theme-modern .auth--header .form--auth,
.theme-modern .auth--header .form--auth .row { display: block; margin: 0; padding: 0; width: auto; }
.theme-modern .auth--header .form--auth .form-group { width: 100%; margin: 0 0 12px; padding: 0; float: none; }
.theme-modern .auth--header .form--auth .form-control {
    height: 44px; padding: 0 14px; font-size: 15px;
    border-radius: var(--tt-radius-sm) !important;
}
.theme-modern .auth--header .form--auth .in-label { font-size: 14px; color: var(--tt-text); }
.theme-modern .auth--header .form--auth .form__submit {
    display: flex; width: 100%; height: 44px; margin: 4px 0 0; padding: 0 16px;
    font-size: 15px; border-radius: var(--tt-radius-sm);
}
.theme-modern .header .auth--header .form--auth .form__submit .fa { color: var(--tt-accent-ink); font-size: 14px; }
.theme-modern .auth--header .form--auth .form__options {
    margin: 14px 0 0; padding: 0; text-align: center; font-size: 14px; color: var(--tt-muted) !important;
}
.theme-modern .header .auth--header .form--auth .form__options button.toggle-forms {
    padding: 0; border: 0; background: none;
    color: var(--tt-accent) !important; font-weight: 600; text-decoration: none;
}
.theme-modern .header .auth--header .form--auth .form__options button.toggle-forms:hover { text-decoration: underline; }

/* ---------- Main navigation ---------------------------------------------- */
.theme-modern .navbar--header {
    background: var(--tt-white);
    border-bottom: 1px solid var(--tt-line);
    box-shadow: none;
}
.theme-modern .navbar--header.header-fixed { box-shadow: 0 4px 16px rgba(29, 33, 38, .06); }
.theme-modern .navbar__row { margin: 14px 0; display: flex; align-items: center; }
.theme-modern .navbar__brand img.logo { max-height: 46px; width: auto; }
@media (min-width: 768px) {
    .theme-modern .navbar__wrap { margin-left: auto; }
    .theme-modern .navbar__nav { display: flex; align-items: center; gap: 4px; }
    .theme-modern .navbar__item { margin: 0; }
    .theme-modern .navbar__link {
        text-transform: none;
        font-size: 15px;
        font-weight: 500;
        letter-spacing: 0;
        color: var(--tt-text);
        padding: 8px 12px;
        border-radius: var(--tt-radius-sm);
        transition: background .15s, color .15s;
    }
    .theme-modern .navbar__item:hover > .navbar__link,
    .theme-modern .navbar__item.active > .navbar__link { background: var(--tt-bg); color: var(--tt-ink); box-shadow: none; }
    .theme-modern .navbar__item.active > .navbar__link:after,
    .theme-modern .navbar__link:after,
    .theme-modern .navbar__wrap > ul > li > a:before { display: none !important; }
    /* Call-to-action ("Submit an ad") */
    .theme-modern .navbar__item--cta { margin-left: 8px; }
    .theme-modern .navbar__item--cta > .navbar__link,
    .theme-modern .navbar__item--cta:hover > .navbar__link {
        background: var(--tt-accent);
        color: var(--tt-accent-ink);
        font-weight: 600;
        padding: 9px 16px;
    }
    .theme-modern .navbar__item--cta:hover > .navbar__link { background: var(--tt-accent-hover); color: var(--tt-accent-ink); }
    .theme-modern .navbar__dropdown {
        background: var(--tt-white); /* theme.css: solid blue */
        border: 1px solid var(--tt-line);
        border-radius: var(--tt-radius);
        box-shadow: var(--tt-shadow);
        padding: 6px 0;
        min-width: 220px;
        /* no overflow:hidden - it clipped the fly-out "Create" submenu (left: 100%) */
    }
    /* custom.css (>= 992px) floats each list as its own blue box, shifted 100px left and
       wider than the dropdown (long "Useful" article titles): keep it inside the dropdown */
    .theme-modern .navbar__submenu > ul,
    .theme-modern .navbar__wrap > ul > li:hover .navbar__submenu > ul {
        position: static;
        margin: 0;
        border-top: 0;
        background: transparent;
        box-shadow: none;
        transform: none;
        visibility: inherit;
        opacity: 1;
        transition: none;
    }
    .theme-modern .navbar__submenu { background: transparent; }
    .theme-modern .navbar__sublink { white-space: normal; max-width: 340px; line-height: 1.35; }
    .theme-modern .navbar__subnav hr { margin: 6px 0; border-color: var(--tt-line); }
    .theme-modern .navbar__submenu--level {
        background: var(--tt-white);
        border: 1px solid var(--tt-line);
        border-radius: var(--tt-radius);
        box-shadow: var(--tt-shadow);
        min-width: 220px;
        z-index: 2;
    }
    .theme-modern .navbar__sublink { text-transform: none; font-weight: 500; color: var(--tt-text); }
    .theme-modern .navbar__sublink:hover { background: var(--tt-bg); color: var(--tt-ink); }
}

/* ---------- Buttons ------------------------------------------------------- */
.theme-modern .btn-cta,
.theme-modern .form__submit,
.theme-modern .btn-primary {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    background: var(--tt-accent);
    color: var(--tt-accent-ink) !important;
    border: 0;
    border-radius: var(--tt-radius-sm);
    font-weight: 600;
    text-transform: none;
    letter-spacing: 0;
    padding: 11px 22px;
    box-shadow: none;
    transition: background .15s var(--tt-ease), transform .15s var(--tt-ease);
}
.theme-modern .btn-cta:hover,
.theme-modern .form__submit:hover,
.theme-modern .btn-primary:hover { background: var(--tt-accent-hover); text-decoration: none; }
.theme-modern .btn-cta:active,
.theme-modern .form__submit:active { transform: translateY(1px); }
.theme-modern .form__reset,
.theme-modern .btn-default,
.theme-modern .btn--default,
.theme-modern .btn--white {
    background: var(--tt-white);
    color: var(--tt-ink);
    border: 1px solid var(--tt-line-strong);
    border-radius: var(--tt-radius-sm);
    text-transform: none;
    font-weight: 600;
    box-shadow: none;
}
.theme-modern .form__reset:hover,
.theme-modern .btn--default:hover,
.theme-modern .btn--white:hover { border-color: var(--tt-ink); color: var(--tt-ink); }
.theme-modern .btn--default.active,
.theme-modern .btn--white.active { background: var(--tt-accent); border-color: var(--tt-accent); color: var(--tt-accent-ink); }

/* ---------- Form controls ------------------------------------------------- */
.theme-modern .form-control,
.theme-modern .select2-container--default .select2-selection--single,
.theme-modern .select2-container--default .select2-selection--multiple {
    border: 1px solid var(--tt-line-strong);
    border-radius: var(--tt-radius-sm);
    box-shadow: none;
    min-height: 42px;
    transition: border-color .15s, box-shadow .15s;
}
.theme-modern .form-control:focus,
.theme-modern .select2-container--focus .select2-selection {
    border-color: var(--tt-blue);
    box-shadow: 0 0 0 3px var(--tt-blue-soft);
}
.theme-modern .control-label { color: var(--tt-muted); font-weight: 600; font-size: 13px; text-transform: none; }

/* ---------- Chips --------------------------------------------------------- */
.theme-modern .chip {
    display: inline-flex; align-items: center;
    padding: 8px 16px;
    background: var(--tt-bg);
    color: var(--tt-text);
    border-radius: var(--tt-radius-sm);
    font-size: 14px; font-weight: 500;
    white-space: nowrap;
    transition: background .15s, color .15s;
}
.theme-modern .chip:hover { background: var(--tt-line); color: var(--tt-ink); text-decoration: none; }
.theme-modern .chip--sm { padding: 3px 9px; font-size: 12px; border-radius: 6px; }

/* ---------- Home: hero + search ------------------------------------------ */
.theme-modern .home-hero { padding: 36px 0 12px; background: var(--tt-white); }
.theme-modern .home-hero__head {
    display: flex; align-items: flex-end; justify-content: space-between; gap: 16px;
    margin-bottom: 24px;
}
.theme-modern .home-hero__title {
    font-size: clamp(26px, 3.2vw, 38px);
    line-height: 1.15;
    letter-spacing: -0.02em;
    margin: 0;
    max-width: 820px;
}
.theme-modern .home-hero__phone {
    flex: none;
    padding: 9px 14px;
    border: 1px solid var(--tt-line-strong);
    border-radius: var(--tt-radius-sm);
    color: var(--tt-ink);
    font-weight: 600;
}
.theme-modern .home-hero__phone:hover { border-color: var(--tt-ink); text-decoration: none; }
@media (max-width: 767px) { .theme-modern .home-hero__phone { display: none; } }

/* Yellow-framed search panel (home) */
.theme-modern .search-box {
    border: 2px solid var(--tt-accent);
    box-shadow: 0 8px 24px rgba(1, 91, 187, .10);
    border-radius: var(--tt-radius-lg);
    padding: 10px 18px 18px;
    background: var(--tt-white);
}
.theme-modern .search-box #search_form { padding: 0; background: none; box-shadow: none; border: 0; } /* custom.css gave it a 1px blue frame */

/* Compact inline search row (home) */
.theme-modern .quick-search {
    display: flex !important; flex-wrap: wrap; align-items: stretch; gap: 10px;
    padding-top: 6px;
}
.theme-modern .quick-search__field { flex: 1 1 160px; margin: 0; font-weight: normal; }
.theme-modern .quick-search__field--wide { flex-basis: 240px; }
.theme-modern .quick-search .form-control { height: 46px; font-size: 15px; color: var(--tt-ink); background-color: var(--tt-white); }
.theme-modern .quick-search__submit { flex: 0 0 auto; height: 46px; padding: 0 28px; font-size: 15px; }
@media (max-width: 767px) {
    .theme-modern .quick-search__field,
    .theme-modern .quick-search__submit { flex: 1 1 100%; }
}

/* Listings page: same yellow panel, full filters open below the quick row */
.theme-modern .search-box--page { margin: 8px 0 24px; }
.theme-modern .search__more {
    margin-top: 12px;
    padding: 0;
    border: 0; background: none;
    color: var(--tt-blue); font-weight: 600;
    display: inline-flex; align-items: center; gap: 8px;
}
.theme-modern .search__more:hover { color: var(--tt-blue-dark); }
.theme-modern .search__more:after {
    content: "\f077"; font-family: "Font Awesome 7 Free"; font-weight: 900; font-size: 11px;
    transition: transform .2s var(--tt-ease);
}
.theme-modern .search__more.closed:after { transform: rotate(180deg); }
.theme-modern .search-box--page #search_form {
    margin-top: 16px; padding-top: 16px;
    border-top: 1px solid var(--tt-line);
}

/* Property-type selector → flat tabs */
.theme-modern .bx-wrapper { box-shadow: none !important; border: 0 !important; background: none !important; margin-bottom: 8px !important; }
.theme-modern .property-types {
    display: flex; flex-wrap: nowrap; gap: 2px;
    margin: 0 0 8px;
    overflow-x: auto; scrollbar-width: none;
    position: relative; /* offsetParent for scrolling the active tab into view */
}
.theme-modern .property-types::-webkit-scrollbar { display: none; }
.theme-modern .property-type {
    flex: 1 0 auto; white-space: nowrap; /* share the full panel width; never shrink below the label */
    display: flex !important; align-items: center; justify-content: center; gap: 8px;
    padding: 10px 12px;
    border: 0 !important;
    border-bottom: 2px solid transparent !important;
    background: none !important;
    color: var(--tt-muted);
    font-weight: 600;
    text-transform: none;
    cursor: pointer;
    transition: color .15s, border-color .15s;
}
.theme-modern .property-type svg { width: 22px; height: 22px; fill: currentColor; }
/* The garden-community icon is a wide outline drawing: enlarge it to match the solid icons (tabs and footer). */
.theme-modern svg:has(> use[*|href="#svg_garden"]) { transform: scale(1.4); overflow: visible; }
.theme-modern .property-type[data-type="garden"] { gap: 12px; }
.theme-modern .property-type:hover { color: var(--tt-ink); }
.theme-modern .property-type.active { color: var(--tt-accent); border-bottom-color: var(--tt-accent) !important; }
.theme-modern .property-type.active:after,
.theme-modern .property-type.active:before { display: none !important; }
/* Slider arrows: round white buttons with a chevron (replaces the old PNG arrows) */
.theme-modern .bx-wrapper .bx-controls-direction a.bx-prev,
.theme-modern .bx-wrapper .bx-controls-direction a.bx-next {
    width: 32px; height: 32px; margin-top: -16px;
    background-color: var(--tt-white);
    background-image: none;
    border: 1px solid var(--tt-line-strong);
    border-radius: 50%;
    box-shadow: var(--tt-shadow-sm);
    overflow: hidden;
    z-index: 5;
    transition: border-color .15s, box-shadow .15s;
}
.theme-modern .bx-wrapper .bx-controls-direction a.bx-prev { left: -16px; }
.theme-modern .bx-wrapper .bx-controls-direction a.bx-next { right: -16px; }
.theme-modern .bx-wrapper .bx-controls-direction a:hover { border-color: var(--tt-ink); box-shadow: var(--tt-shadow); }
.theme-modern .bx-wrapper .bx-controls-direction a:before {
    position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    text-indent: 0;
    font-family: "Font Awesome 7 Free";
    font-weight: 900;
    font-size: 13px;
    color: var(--tt-ink);
}
.theme-modern .bx-wrapper .bx-controls-direction a.bx-prev:before { content: "\f053"; } /* chevron-left */
.theme-modern .bx-wrapper .bx-controls-direction a.bx-next:before { content: "\f054"; } /* chevron-right */
.theme-modern .bx-wrapper .bx-controls-direction a.disabled { opacity: .35; }

/* Quick filter chips under the search */
.theme-modern .quick-chips {
    display: flex; gap: 10px; flex-wrap: nowrap; overflow-x: auto;
    padding: 14px 0 4px;
    scrollbar-width: none;
}
.theme-modern .quick-chips::-webkit-scrollbar { display: none; }

/* ---------- Section headings --------------------------------------------- */
.theme-modern .widget--landing { padding: 40px 0; background: var(--tt-white); }
.theme-modern .widget--gray { background: var(--tt-white); }
.theme-modern .widget__header.section-head {
    display: flex; align-items: center; justify-content: space-between;
    width: auto; max-width: 1240px; margin: 0 auto 20px; padding: 0 24px;
    text-align: left;
}
.theme-modern .widget__header.section-head:before,
.theme-modern .widget__header.section-head:after { display: none; }
.theme-modern .section-head .widget__title { margin: 0; }
.theme-modern .widget--landing .widget__title,
.theme-modern .site__title {
    text-transform: none;
    text-align: left;
    font-size: clamp(22px, 2.2vw, 28px);
    font-weight: 700;
    letter-spacing: -0.015em;
    color: var(--tt-ink);
}
.theme-modern .widget--landing .widget__title:after { display: none; }
.theme-modern .site__title { margin-top: 24px; }
.theme-modern .widget__headline { text-transform: none; color: var(--tt-muted); }
.theme-modern .section-head__link { font-weight: 600; white-space: nowrap; }
.theme-modern .section-head__link .fa-solid { font-size: 12px; margin-left: 4px; }

/* Line tabs and grid up with the section heading */
.theme-modern .home-listings .tab--properties,
.theme-modern .home-listings .tab-content,
.theme-modern .home-listings .tab-pane,
.theme-modern .home-listings .listing { margin-left: 0; margin-right: 0; padding-left: 0; padding-right: 0; }
.theme-modern .search-box .bx-wrapper { margin: 0 22px 8px !important; }

/* Recent / featured / popular → pill tabs */
.theme-modern .tab--properties .tab__nav { justify-content: flex-start; gap: 8px; margin: 0 0 24px; padding: 0; }
.theme-modern .tab--properties .tab__nav li { margin: 0; }
.theme-modern .tab--properties .tab__nav li > a {
    display: inline-block;
    padding: 8px 16px;
    border-radius: 999px;
    background: var(--tt-bg);
    color: var(--tt-text);
    text-transform: none;
    font-weight: 600;
    border: 0;
}
.theme-modern .tab--properties .tab__nav li.active a { background: var(--tt-accent); color: var(--tt-accent-ink); border: 0; }

/* ---------- Listing grid -------------------------------------------------- */
.theme-modern .listing--th,
.theme-modern .listing--lg-4 {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 28px 24px;
    margin: 0;
}
.theme-modern .listing--th:before,
.theme-modern .listing--th:after,
.theme-modern .listing--lg-4:before,
.theme-modern .listing--lg-4:after { display: none; }
.theme-modern .listing--th .listing__item,
.theme-modern .listing--lg-4 .listing__item {
    float: none; width: auto; padding: 0; margin: 0; min-width: 0;
}
/* All card grids (listings, similar listings, agents, articles): 3 per row, 2 on tablets, 1 on phones */
.theme-modern .listing.listing--th,
.theme-modern .listing.listing--lg-4 { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px 28px; }
@media (max-width: 991px) {
    .theme-modern .listing.listing--th,
    .theme-modern .listing.listing--lg-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 575px) {
    .theme-modern .listing.listing--th,
    .theme-modern .listing.listing--lg-4 { grid-template-columns: 1fr; }
}
.theme-modern .widget--landing > .widget__content { width: auto; max-width: 1240px; margin-left: auto; margin-right: auto; padding-left: 24px; padding-right: 24px; }
@media (max-width: 767px) {
    .theme-modern .listing--th,
    .theme-modern .listing--lg-4 { grid-template-columns: 1fr; gap: 24px; }
    .theme-modern .widget__header.section-head,
    .theme-modern .widget--landing > .widget__content { padding-left: 16px; padding-right: 16px; }
}

/* ---------- Listing card ------------------------------------------------- */
.theme-modern .card {
    background: none;
    border: 0;
    box-shadow: none;
    padding: 0;
    height: 100%;
    display: flex; flex-direction: column;
}
.theme-modern .card__media { position: relative; border-radius: var(--tt-radius); overflow: hidden; background: var(--tt-bg); }
.theme-modern .card__photo { display: block; aspect-ratio: 4 / 3; overflow: hidden; }
.theme-modern .card__photo img {
    width: 100%; height: 100%; object-fit: cover; display: block;
    transition: transform .5s var(--tt-ease);
}
.theme-modern .card:hover .card__photo img { transform: scale(1.04); }
.theme-modern .card__media { transition: box-shadow .3s var(--tt-ease), transform .3s var(--tt-ease); }
.theme-modern .card:hover .card__media { box-shadow: var(--tt-shadow); transform: translateY(-2px); }
.theme-modern .card__photo:before,
.theme-modern .card__photo:after { display: none !important; }
.theme-modern .card__photo { position: relative; }

/* Hover overlay with the listing's key parameters */
.theme-modern .card__hover {
    position: absolute; left: 0; right: 0; bottom: 0;
    display: flex; flex-direction: column; gap: 8px;
    padding: 36px 14px 12px;
    background: linear-gradient(to top, rgba(17, 20, 24, .88) 0%, rgba(17, 20, 24, .7) 60%, rgba(17, 20, 24, 0) 100%);
    color: #fff; font-size: 13px; line-height: 1.3;
    opacity: 0; transform: translateY(12px);
    transition: opacity .25s var(--tt-ease), transform .25s var(--tt-ease);
    pointer-events: none;
}
.theme-modern .card:hover .card__hover,
.theme-modern .card__photo:focus-visible .card__hover { opacity: 1; transform: none; }
.theme-modern .card__hover-head { display: flex; justify-content: space-between; gap: 8px; font-weight: 600; }
.theme-modern .card__hover-date { font-weight: 400; opacity: .85; white-space: nowrap; }
.theme-modern .card__hover-params { display: flex; flex-wrap: wrap; gap: 6px 14px; }
.theme-modern .card__hover-params span { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.theme-modern .card__hover-params svg { width: 16px; height: 16px; fill: #fff; flex: none; }
@media (hover: none) { .theme-modern .card__hover { display: none; } }
.theme-modern .card__staff { transition: opacity .2s; }
.theme-modern .card:hover .card__staff { opacity: 0; pointer-events: none; }

.theme-modern .card__badges {
    position: absolute; left: 10px; top: 10px; right: 10px;
    display: flex; flex-wrap: wrap; gap: 6px;
    pointer-events: none;
}
.theme-modern .card__badge {
    background: rgba(255, 255, 255, .94);
    color: var(--tt-ink);
    font-size: 12px; font-weight: 600;
    padding: 3px 9px;
    border-radius: 6px;
    box-shadow: var(--tt-shadow-sm);
}
.theme-modern .card__badge--hot { background: var(--tt-accent); color: var(--tt-accent-ink); }
.theme-modern .card__badge--hot .fa-solid { color: var(--tt-accent-ink); }
.theme-modern .card__badge--lounge { background: var(--tt-accent-soft); color: var(--tt-accent-soft-ink); }
.theme-modern .card__badge--lounge .fa-solid { color: var(--tt-accent); margin-right: 2px; }
.theme-modern .card__badge--video { background: rgba(17, 17, 17, .78); color: #fff; }
.theme-modern .card__badge--video .fa-solid { color: #fff; margin-right: 3px; }

/* Staff-only status ribbons, kept compact at the bottom of the photo */
.theme-modern .card__staff {
    position: absolute; left: 8px; bottom: 8px; right: 8px; top: auto;
    display: flex; flex-wrap: wrap; gap: 4px;
}
.theme-modern .card__staff .ribbon {
    position: static; margin: 0; float: none;
    font-size: 11px; line-height: 1.4; padding: 3px 8px;
    border-radius: 6px; box-shadow: none;
}
.theme-modern .card__staff .ribbon:before,
.theme-modern .card__staff .ribbon:after { display: none; }

.theme-modern .card__body { padding: 12px 2px 0; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.theme-modern .card__top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.theme-modern .card__price {
    display: inline-block;
    background: var(--tt-accent-soft);
    color: var(--tt-accent-soft-ink);
    font-size: 19px; font-weight: 700;
    letter-spacing: -0.01em;
    line-height: 1.2;
    padding: 3px 8px;
    border-radius: 6px;
    font-variant-numeric: tabular-nums;
}
.theme-modern .card__price small { font-size: 13px; font-weight: 600; margin-left: 1px; }
.theme-modern .card__fav {
    flex: none;
    width: 36px; height: 36px;
    display: inline-flex; align-items: center; justify-content: center;
    border: 0; border-radius: 50%;
    background: none;
    color: var(--tt-ink);
    font-size: 19px;
    cursor: pointer;
    transition: background .15s, color .15s, transform .15s var(--tt-ease);
}
.theme-modern .card__fav:hover { background: var(--tt-bg); }
.theme-modern .card__fav:active { transform: scale(.9); }
.theme-modern .card__fav.active { color: var(--tt-danger); }
.theme-modern .card__meta {
    display: flex; flex-wrap: wrap; align-items: center;
    color: var(--tt-ink); font-weight: 700; font-size: 14px;
}
.theme-modern .card__meta span + span:before {
    content: "";
    display: inline-block; width: 3px; height: 3px; border-radius: 50%;
    background: var(--tt-faint);
    margin: 0 8px; vertical-align: middle;
}
.theme-modern .card__address {
    color: var(--tt-muted); font-size: 14px; background: none;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.theme-modern .card__address:hover { color: var(--tt-blue); text-decoration: none; }
.theme-modern .card__desc {
    margin: 0;
    color: var(--tt-muted); font-size: 13px; line-height: 1.5;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.theme-modern .card__amenities { display: flex; flex-wrap: wrap; gap: 6px; }
.theme-modern .card__footer {
    display: flex; align-items: center; justify-content: space-between;
    margin-top: auto; padding-top: 4px;
    font-size: 12px; color: var(--tt-faint);
}
.theme-modern .card__action { font-weight: 600; font-size: 13px; }
.theme-modern .properties__details .card-id { display: none; }

/* List view: photo left, details right */
.theme-modern .listing--list .listing__item { border: 0; margin-bottom: 20px; }
.theme-modern .properties--list.card { flex-direction: row; gap: 24px; border-bottom: 1px solid var(--tt-line); padding-bottom: 20px; }
.theme-modern .properties--list .card__media { flex: 0 0 340px; max-width: 340px; }
.theme-modern .properties--list .card__body { padding-top: 0; }
.theme-modern .properties--list .card__desc { -webkit-line-clamp: 3; }
@media (max-width: 767px) {
    .theme-modern .properties--list.card { flex-direction: column; }
    .theme-modern .properties--list .card__media { flex-basis: auto; max-width: none; }
}

/* ---------- Promo card ---------------------------------------------------- */
.theme-modern .promo-card {
    display: flex; align-items: center; justify-content: space-between; gap: 24px;
    margin-top: 40px;
    padding: 28px 32px;
    background: var(--tt-accent-soft);
    border-radius: var(--tt-radius-lg);
}
.theme-modern .promo-card__title { margin: 0 0 4px; font-size: 22px; }
.theme-modern .promo-card p { margin: 0; color: var(--tt-muted); }
@media (max-width: 767px) { .theme-modern .promo-card { flex-direction: column; align-items: flex-start; padding: 22px; } }

/* ---------- Values / agents / articles ----------------------------------- */
.theme-modern .section-lead { color: var(--tt-muted); max-width: 760px; margin: -8px 0 20px; }
.theme-modern .values { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.theme-modern .value-card {
    background: var(--tt-bg);
    border-radius: var(--tt-radius-lg);
    padding: 22px;
    transition: transform .2s var(--tt-ease), box-shadow .2s var(--tt-ease);
}
.theme-modern .value-card:hover { transform: translateY(-2px); box-shadow: var(--tt-shadow); background: var(--tt-white); }
.theme-modern .value-card__icon { width: 40px; height: 40px; fill: var(--tt-blue); margin-bottom: 12px; }
.theme-modern .value-card__title { font-size: 17px; margin: 0 0 6px; }
.theme-modern .value-card p { margin: 0; color: var(--tt-muted); font-size: 14px; }

.theme-modern .worker,
.theme-modern .article { border-radius: var(--tt-radius); overflow: hidden; box-shadow: none; border: 1px solid var(--tt-line); background: var(--tt-white); }
.theme-modern .worker:hover,
.theme-modern .article:hover { box-shadow: var(--tt-shadow); }

/* Footer "latest articles": a plain list, not cards */
.theme-modern .article--footer,
.theme-modern .article--footer:hover { border: 0; border-radius: 0; background: none; box-shadow: none; overflow: visible; }
.theme-modern .listing--footer .listing__item { margin: 0; padding: 12px 0; border-bottom: 1px solid var(--tt-line-strong); }
.theme-modern .listing--footer .listing__item:first-of-type { padding-top: 0; }
.theme-modern .listing--footer .listing__item:last-of-type { border-bottom: 0; }
.theme-modern .article--footer .article__details { padding: 0; font-size: 14px; color: var(--tt-muted); }
.theme-modern .article--footer .article__time {
    display: block; margin: 0 0 3px; padding: 0;
    font-size: 12px; font-style: normal; text-transform: none; color: var(--tt-faint);
    background: none; box-shadow: none; position: static;
}
.theme-modern .article--footer .article__item-title {
    font-size: 14px; font-weight: 600; line-height: 1.4; color: var(--tt-ink);
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.theme-modern .article--footer .article__item-title:hover { color: var(--tt-blue); text-decoration: none; }

/* Article cards: equal height in a row, fixed photo frame, button pinned to the bottom */
.theme-modern .listing__item > .article,
.theme-modern .listing__item > .worker { height: 100%; }
.theme-modern .article--grid { display: flex; flex-direction: column; position: relative; }
.theme-modern .article--grid .article__photo { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--tt-bg); }
.theme-modern .article--grid .article__photo-img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--tt-ease); }
.theme-modern .article--grid:hover .article__photo-img { transform: scale(1.04); }
.theme-modern .article--grid .article__time {
    border-radius: var(--tt-radius-sm); background: var(--tt-white); color: var(--tt-ink);
    box-shadow: var(--tt-shadow-sm); text-transform: none;
}
.theme-modern .article--grid .article__details {
    flex: 1; display: flex; flex-direction: column; align-items: flex-start;
    padding: 16px 18px 18px; margin: 0;
}
.theme-modern .article--grid .article__item-title {
    font-size: 17px; font-weight: 700; line-height: 1.3; color: var(--tt-ink); text-transform: none;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.theme-modern .article--grid .article__item-title:hover { color: var(--tt-blue); text-decoration: none; }
.theme-modern .article--grid .article__intro { margin: 8px 0 16px; color: var(--tt-muted); font-size: 14px; }
.theme-modern .article--grid .article__intro p {
    margin: 0;
    display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.theme-modern .article--grid .article__more {
    margin-top: auto;
    padding: 8px 16px;
    border: 1px solid var(--tt-line-strong); border-radius: var(--tt-radius-sm);
    background: var(--tt-white); color: var(--tt-ink);
    font-size: 14px; font-weight: 600; text-transform: none; line-height: 1.2;
    transition: border-color .15s, background .15s;
}
.theme-modern .article--grid .article__more:hover { border-color: var(--tt-ink); background: var(--tt-bg); text-decoration: none; }
.theme-modern .article--grid .article__more + .article__more { margin-top: 8px; }
.theme-modern .article--grid .article__more:before,
.theme-modern .article--grid .article__more:after { display: none; }

/* ---------- Breadcrumbs & page header ------------------------------------ */
.theme-modern .breadcrumbs { background: none; border: 0; padding: 14px 0 0; }
.theme-modern .breadcrumbs__item,
.theme-modern .breadcrumbs__link { border: 0 !important; background: none !important; text-transform: none; font-size: 13px; color: var(--tt-muted); padding-left: 0; }
.theme-modern .breadcrumbs__link:hover { color: var(--tt-blue); }

/* ---------- Search page (filters bar) ------------------------------------ */
.theme-modern .search__header .search__title-btn {
    border: 1px solid var(--tt-line-strong); border-radius: var(--tt-radius-sm);
    background: var(--tt-white); text-transform: none; font-weight: 600; font-size: 16px;
}
.theme-modern .listing__sort,
.theme-modern .site__panel {
    background: var(--tt-bg) !important;
    border-radius: var(--tt-radius);
    color: var(--tt-ink);
}
.theme-modern .site__panel { border-top: 0; padding: 8px 16px; margin-bottom: 20px !important; }
.theme-modern .site__panel .control-label { color: var(--tt-ink); }
.theme-modern .site__panel .select2-container--default .select2-selection--single {
    background: var(--tt-white); border-color: var(--tt-line-strong); min-height: 34px;
}
.theme-modern .site__panel .select2-container--default .select2-selection--single .select2-selection__rendered { color: var(--tt-ink); line-height: 32px; }
.theme-modern .site__panel .select2-container--default .select2-selection--single .select2-selection__arrow b { border-top-color: var(--tt-ink); }
/* theme.css fixes the sort block at 305px: let it grow so "With lounge" stays on the same line */
.theme-modern .listing__sort { width: auto; }
.theme-modern .listing__sort .form-group { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin: 0; }
.theme-modern .listing__sort .form-group > .control-label { margin: 0 4px 0 0; }
.theme-modern .listing__lounge { display: inline-flex; align-items: center; margin-left: 10px; white-space: nowrap; }
.theme-modern .listing__lounge .in-label { margin: 0; font-size: 14px; font-weight: 500; color: var(--tt-ink); cursor: pointer; }
.theme-modern .center { background: var(--tt-white); }
.theme-modern .breadcrumbs ul { border-left: 0; }

/* ---------- Listing detail page ------------------------------------------ */
/* Gallery: fixed-height stage so portrait photos don't stretch the page */
.theme-modern .property__slider { margin-top: 16px; display: flex; flex-direction: column; gap: 10px; }
.theme-modern .property__slider #properties-thumbs { order: 1; border-radius: var(--tt-radius-lg); overflow: hidden; background: var(--tt-bg); }
.theme-modern .property__slider .slider--thumbs { order: 2; }
.theme-modern #properties-thumbs .slick-track { display: flex; align-items: stretch; }
.theme-modern #properties-thumbs .slider__item,
.theme-modern #properties-thumbs .slider__img {
    height: clamp(300px, 62vh, 640px) !important;
    display: flex !important; align-items: center; justify-content: center;
    background: var(--tt-bg);
}
.theme-modern #properties-thumbs .slider__img img,
.theme-modern #properties-thumbs .slider__block > img {
    width: auto; height: auto; max-width: 100%; max-height: 100%;
    object-fit: contain; margin: 0 auto;
}
.theme-modern #properties-thumbs .slider__block > img { display: block; max-height: clamp(300px, 62vh, 640px); }
/* Thumbnail strip: compact, rounded, no zoom jump */
.theme-modern .slider--thumbs .slider__block { padding: 0 40px; }
.theme-modern .slider--thumbs .slider__item { padding: 0 4px; }
.theme-modern .slider--thumbs .slider__item.slick-current { transform: none; }
.theme-modern .slider--thumbs .slider__img {
    height: 84px; border-radius: var(--tt-radius-sm); overflow: hidden; cursor: pointer;
    opacity: .7; transition: opacity .15s; background-color: var(--tt-bg);
}
.theme-modern .slider--thumbs .slider__item.is-selected .slider__img,
.theme-modern .slider--thumbs .slider__img:hover { opacity: 1; box-shadow: 0 0 0 2px var(--tt-accent) inset; }
.theme-modern .slider--thumbs .slider__img img { width: 100%; height: 100%; object-fit: cover; }
.theme-modern .slider--thumbs .slider__control {
    top: 50%; margin-top: -16px; width: 32px; height: 32px;
    background: var(--tt-white); border: 1px solid var(--tt-line-strong); border-radius: 50%;
    color: var(--tt-ink); display: flex; align-items: center; justify-content: center;
}
.theme-modern .slider--thumbs .slider__control .fa { font-size: 18px; }
/* "Show pictures" button (staff view) */
.theme-modern #show_photos { margin-top: 12px !important; }
/* Tighter vertical rhythm in the details */
.theme-modern .property__title { margin-top: 16px; font-size: 28px; }
.theme-modern .property__city { display: block; font-size: 20px; color: var(--tt-muted); font-weight: 500; margin-top: 4px; }
.theme-modern .property__header { margin: 12px 0 0; border: 0; padding: 0; }
.theme-modern .property__subtitle { margin: 28px 0 12px; font-size: 20px; text-transform: none; }
/* Key facts: light tiles */
.theme-modern .property__plan {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px;
    margin-top: 20px;
}
.theme-modern .property__plan:before, .theme-modern .property__plan:after { display: none; }
.theme-modern .property__plan-item {
    display: flex; flex-direction: column; align-items: flex-start;
    width: auto; float: none;
    background: var(--tt-bg); border: 0; border-radius: var(--tt-radius); padding: 14px 16px;
}
.theme-modern .property__plan-icon { margin: 0 0 6px; }
.theme-modern .property__plan-icon svg { width: 22px; height: 22px; fill: var(--tt-blue); }
.theme-modern .property__plan-title { order: 2; padding: 0; color: var(--tt-muted); font-size: 13px; }
.theme-modern .property__plan-value { order: 1; border: 0; padding: 0 0 2px; font-size: 20px; font-weight: 700; color: var(--tt-ink); }
/* Agent card: compact photo beside name and phone */
.theme-modern .worker--details {
    display: flex; gap: 20px; align-items: center;
    border: 1px solid var(--tt-line); border-radius: var(--tt-radius-lg); padding: 20px; box-shadow: none;
}
.theme-modern .worker--details > .clearfix { display: none; }
.theme-modern .worker--details .worker__photo { flex: 0 0 112px; width: 112px; height: 112px; border-radius: 50%; overflow: hidden; float: none; margin: 0; padding: 0; }
.theme-modern .worker--details .worker__photo .item-photo { display: block; width: 100%; height: 100%; padding: 0; }
.theme-modern .worker--details .worker__photo img { width: 100%; height: 100%; object-fit: cover; object-position: center top; }
@media (min-width: 768px) { .theme-modern .worker--details .worker__show { display: none; } }
.theme-modern .worker--details .worker__intro-row { display: flex; align-items: center; gap: 12px; }
.theme-modern .worker--details .worker__descr p { margin: 8px 0 0; color: var(--tt-muted); }
@media (max-width: 575px) { .theme-modern .worker--details { flex-direction: column; align-items: flex-start; } }
.theme-modern .worker--details .worker__intro { flex: 1; float: none; width: auto; padding: 0; }
.theme-modern .worker--details .worker__name { font-size: 22px; margin: 0 0 8px; }
.theme-modern .worker--details .worker__intro-name { border: 0; background: none; }
/* Photo ribbons (detail page) → light pills in the photo corner, like the cards */
.theme-modern .ribbons-right {
    position: absolute; top: 12px; right: 12px; z-index: 3;
    display: flex; flex-direction: column; align-items: flex-end; gap: 6px;
}
.theme-modern .ribbons-right .ribbon {
    position: static; margin: 0;
    background: rgba(255, 255, 255, .94); color: var(--tt-ink);
    opacity: 1; text-transform: none; font-weight: 600; font-size: 13px;
    padding: 4px 10px; border-radius: 6px; box-shadow: var(--tt-shadow-sm);
}
.theme-modern .ribbons-right .ribbon:after { display: none; }
.theme-modern .ribbons-right .ribbon svg { width: 14px; height: 14px; fill: currentColor; vertical-align: -2px; }
.theme-modern .ribbons-right .ribbon.warning { background: var(--tt-accent); color: var(--tt-accent-ink); }
/* Price: only the figure is highlighted (same look as on the cards) */
.theme-modern .property__price {
    display: inline-flex; align-items: baseline; gap: 6px;
    background: none; border: 0; padding: 0; float: left; line-height: 1;
}
.theme-modern .property__price-value {
    display: inline-block;
    background: var(--tt-accent-soft); color: var(--tt-accent-soft-ink);
    font-size: 36px; font-weight: 700; letter-spacing: -0.02em; line-height: 1.15;
    padding: 4px 12px; border-radius: var(--tt-radius-sm);
    font-variant-numeric: tabular-nums;
}
.theme-modern .property__price-label { font-size: 18px; font-weight: 600; color: var(--tt-muted); }
@media (max-width: 767px) { .theme-modern .property__price-value { font-size: 28px; } }
.theme-modern .property__header,
.theme-modern .property__title { text-transform: none; }
.theme-modern .widget--white,
.theme-modern .property__info,
.theme-modern .worker--sidebar { border-radius: var(--tt-radius); border: 1px solid var(--tt-line); box-shadow: none; }

/* ---------- Footer -------------------------------------------------------- */
.theme-modern .footer { background: var(--tt-bg); color: var(--tt-muted); border-top: 1px solid var(--tt-line); }
.theme-modern .footer a { color: var(--tt-text); }
.theme-modern .footer a:hover { color: var(--tt-blue); }
.theme-modern .footer svg { fill: var(--tt-muted); }
.theme-modern .widget--footer .widget__title { color: var(--tt-ink); text-transform: none; font-size: 16px; }
.theme-modern .footer .social__item { color: var(--tt-ink); }
.theme-modern .footer .widget__more,
.theme-modern .widget__more:not(.form__submit) {
    display: inline-flex; align-items: center;
    padding: 8px 16px; margin-top: 8px;
    border: 1px solid var(--tt-line-strong); border-radius: var(--tt-radius-sm);
    background: var(--tt-white); color: var(--tt-ink);
    font-size: 14px; font-weight: 600; text-transform: none; line-height: 1.2;
    overflow: visible;
}
.theme-modern .footer .widget__more:hover,
.theme-modern .widget__more:not(.form__submit):hover { border-color: var(--tt-ink); background: var(--tt-bg); text-decoration: none; }
.theme-modern .footer .widget__more:before,
.theme-modern .footer .widget__more:after { display: none; }
/* Footer texts were light grey for the old dark footer */
.theme-modern .footer .address,
.theme-modern .footer .address *,
.theme-modern .footer address,
.theme-modern .footer .widget_text,
.theme-modern .footer time,
.theme-modern .footer .article__time { color: var(--tt-text); }
.theme-modern .footer__copyright { color: var(--tt-muted); }
.theme-modern .footer .address__main,
.theme-modern .footer .address dt { color: var(--tt-muted); }

/* ---------- Misc ---------------------------------------------------------- */
/* Cookie banner */
.theme-modern .cc-window.cc-floating { border-radius: var(--tt-radius-lg); box-shadow: var(--tt-shadow); max-width: 360px; font-family: inherit; }
.theme-modern .cc-window .cc-btn { border-radius: var(--tt-radius-sm); font-weight: 600; border: 0; }
.theme-modern .cc-window .cc-link { color: var(--tt-white); text-decoration: underline; opacity: 1; }

/* Back-to-top button */
.theme-modern .scrollup {
    width: 44px; height: 44px; left: 20px; bottom: 20px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 50%;
    background: var(--tt-accent);
    color: var(--tt-white);
    box-shadow: var(--tt-shadow);
}
.theme-modern .scrollup:before { font-size: 18px; line-height: 1; color: var(--tt-white); }
.theme-modern .scrollup:hover { background: var(--tt-accent-hover); }
.theme-modern .label-default { background: var(--tt-bg); color: var(--tt-text); border-radius: 6px; font-weight: 500; }
.theme-modern .modal-content { border-radius: var(--tt-radius-lg); border: 0; box-shadow: var(--tt-shadow); }
@media (prefers-reduced-motion: reduce) {
    .theme-modern *, .theme-modern *:before, .theme-modern *:after { transition: none !important; animation: none !important; }
}

/* Street autocomplete in the search filters: street name + "town, district" */
.street-option { display: flex; flex-direction: column; line-height: 1.25; }
.street-option__name { font-weight: 600; }
.street-option__place { font-size: 12px; opacity: .65; }
.select2-results__option--highlighted .street-option__place { opacity: .85; }

/* Multi-selects set up while the filters panel is hidden get a 0px search box, which
   cut the placeholder ("Įveskite gatvės pavadinimą"). With no chips yet, the search box
   is the only item: let it take the full width. */
.theme-modern .select2-selection--multiple .select2-selection__rendered > .select2-search--inline:first-child,
.theme-modern .select2-selection--multiple .select2-selection__rendered > .select2-search--inline:first-child .select2-search__field {
    width: 100% !important;
}
.theme-modern .select2-selection--multiple .select2-search__field::placeholder { text-overflow: ellipsis; }

/* Filters panel: Clear and Search buttons the same size */
.theme-modern .form__buttons { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; }
.theme-modern .form__buttons .form__reset,
.theme-modern .form__buttons .form__submit {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    box-sizing: border-box;
    height: 46px; min-width: 150px; margin: 0;
    padding: 0 24px;
    font-size: 15px; line-height: 1;
    border-width: 1px; border-style: solid;
    text-decoration: none;
}
.theme-modern .form__buttons .form__submit { border-color: var(--tt-accent); }
.theme-modern .form__buttons .form__submit:hover { border-color: var(--tt-accent-hover); }

/* Select2 fields (district, town, street, rooms...) rounded like the inputs:
   custom.css forces .select2-selection { border-radius: 0 !important }. */
.theme-modern .select2-container .select2-selection {
    border-radius: var(--tt-radius-sm) !important;
    box-shadow: none;
}
.theme-modern .select2-container--open.select2-container--below .select2-selection { border-bottom-left-radius: 0 !important; border-bottom-right-radius: 0 !important; }
.theme-modern .select2-container--open.select2-container--above .select2-selection { border-top-left-radius: 0 !important; border-top-right-radius: 0 !important; }
.theme-modern .select2-dropdown { border-color: var(--tt-line-strong); overflow: hidden; }
.theme-modern .select2-dropdown--below { border-radius: 0 0 var(--tt-radius-sm) var(--tt-radius-sm); }
.theme-modern .select2-dropdown--above { border-radius: var(--tt-radius-sm) var(--tt-radius-sm) 0 0; }
.theme-modern .select2-selection--multiple .select2-selection__choice { border-radius: 6px; }

/* Native selects (quick search "Rooms: Any", "District: Any", sort...) rounded too:
   theme.css forces select { border-radius: 0 !important }. */
.theme-modern select,
.theme-modern select.form-control { border-radius: var(--tt-radius-sm) !important; }

/* Rental / contract toggles: checkbox box and the (disabled until ticked) select stay white */
.theme-modern .input-group-addon:has(> .in-checkbox) { background: var(--tt-white); }
.theme-modern .select2-container--disabled .select2-selection { background: var(--tt-white) !important; cursor: default; }
.theme-modern .select2-container--disabled .select2-selection__placeholder,
.theme-modern .select2-container--disabled .select2-search__field::placeholder { color: var(--tt-faint); }
.theme-modern .input-group-addon:has(> .in-checkbox) {
    border: 0; background: none; padding: 0 10px 0 0; width: 1%;
}
.theme-modern .input-group-addon:has(> .in-checkbox) + .select2-container .select2-selection,
.theme-modern .input-group-addon:has(> .in-checkbox) ~ select { border-radius: var(--tt-radius-sm) !important; }

/* Filters panel: one text size for fields and checkbox / radio labels
   (labels were 15px dark, plain inputs 14px, select2 fields 15px). */
.theme-modern #search_form .in-label,
.theme-modern #search_form .form-control,
.theme-modern #search_form .select2-selection,
.theme-modern #search_form .select2-search__field,
.theme-modern #search_form .dateranges span {
    font-size: 14px;
    font-weight: 400;
    color: var(--tt-text);
}
.theme-modern #search_form .in-label { line-height: 22px; }
.theme-modern #search_form .form-control::placeholder,
.theme-modern #search_form .select2-search__field::placeholder { color: var(--tt-faint); }

/* AI search: "describe what you are looking for" above the quick row */
.theme-modern .ai-search { display: flex; gap: 10px; margin: 6px 0 10px; flex-wrap: wrap; }
.theme-modern .ai-search__field { position: relative; flex: 1 1 320px; margin: 0; font-weight: normal; }
.theme-modern .ai-search__icon {
    position: absolute; left: 14px; top: 50%; transform: translateY(-50%);
    color: var(--tt-accent); pointer-events: none;
}
.theme-modern .ai-search__input {
    height: 46px; padding-left: 40px; font-size: 15px; color: var(--tt-ink);
    background: var(--tt-accent-soft); border-color: transparent;
}
.theme-modern .ai-search__input::placeholder { color: var(--tt-muted); text-overflow: ellipsis; }
.theme-modern .ai-search__input:focus { background: var(--tt-white); }
.theme-modern .ai-search__submit { flex: 0 0 auto; height: 46px; padding: 0 22px; font-size: 15px; }
.theme-modern .ai-search__busy { display: none; }
.theme-modern .ai-search.is-busy .ai-search__label { display: none; }
.theme-modern .ai-search.is-busy .ai-search__busy { display: inline; }
.theme-modern .ai-search.is-busy .ai-search__submit i { animation: tt-pulse 1s ease-in-out infinite; }
@keyframes tt-pulse { 50% { opacity: .35; } }
.theme-modern .ai-search__note { margin: -2px 0 10px; font-size: 14px; color: var(--tt-text); }
.theme-modern .ai-search__note i { color: var(--tt-accent); margin-right: 4px; }
.theme-modern .ai-search__note--error i { color: #c0392b; }
@media (max-width: 767px) { .theme-modern .ai-search__submit { flex: 1 1 100%; } }

/* Staff "Auto translate" next to the language tabs of the listing / article forms */
.theme-modern .auto-translate { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 12px; margin: 0 0 10px; }
.theme-modern .auto-translate__btn {
    display: inline-flex; align-items: center; gap: 8px;
    height: 38px; padding: 0 16px;
    font-size: 14px; font-weight: 600;
    color: var(--tt-accent-soft-ink); background: var(--tt-accent-soft);
    border: 1px solid transparent; border-radius: var(--tt-radius-sm);
    cursor: pointer; transition: background .15s, color .15s;
}
.theme-modern .auto-translate__btn:hover { background: var(--tt-accent); color: var(--tt-accent-ink); }
.theme-modern .auto-translate__btn:disabled { cursor: wait; opacity: .8; }
.theme-modern .auto-translate__busy { display: none; }
.theme-modern .auto-translate__btn.is-busy .auto-translate__label { display: none; }
.theme-modern .auto-translate__btn.is-busy .auto-translate__busy { display: inline; }
.theme-modern .auto-translate__btn.is-busy i { animation: tt-pulse 1s ease-in-out infinite; }
.theme-modern .auto-translate__hint { color: var(--tt-muted); font-size: 13px; }

/* Listing videos: edit-page cards (reuse the photo grid) and the player on the listing page */
.theme-modern .listing--videos .video-item video { display: block; width: 100%; aspect-ratio: 16 / 9; background: #000; border-radius: var(--tt-radius-sm); }
.theme-modern .video-help { margin: 0 0 10px; }
/* Videos share the listing gallery with photos */
.theme-modern #properties-thumbs .slider__item--video .slider__img { position: relative; background: #000; }
.theme-modern #properties-thumbs .slider__item--video video { display: block; width: 100%; height: 100%; object-fit: contain; background: #000; }
.theme-modern #properties-thumbs .slider__item--video .is-hidden video { opacity: .6; }
.theme-modern .slider__description--top { top: 0; bottom: auto; padding: 16px 20px 40px; background-image: linear-gradient(to top, transparent 0%, rgba(0, 0, 0, 0.6) 100%); }
.theme-modern .slider--thumbs .slider__item--video .slider__img { position: relative; background: #000; }
.theme-modern .slider--thumbs .slider__item--video video { width: 100%; height: 100%; object-fit: cover; pointer-events: none; display: block; }
.theme-modern .slider__play {
    position: absolute; left: 50%; top: 50%; width: 32px; height: 32px; margin: -16px 0 0 -16px;
    border-radius: 50%; background: rgba(0, 0, 0, .55); color: #fff;
    display: flex; align-items: center; justify-content: center; font-size: 12px; pointer-events: none;
}
.theme-modern .slider__play .fa { margin-left: 2px; }
/* Thumbnail strip no longer wraps around: hide the arrow at either end */
.theme-modern .slider--thumbs .slider__control.slick-disabled { visibility: hidden; }
/* Consultant / user cards: status badge top-left as a pill (the legacy ribbon poked out of the rounded card) */
.theme-modern .worker .ribbons-left {
    position: absolute; top: 12px; left: 12px; z-index: 3;
    display: flex; flex-direction: column; align-items: flex-start; gap: 6px;
}
.theme-modern .worker .ribbons-left .ribbon {
    position: static; margin: 0;
    background: rgba(255, 255, 255, .94); color: var(--tt-ink);
    opacity: 1; text-transform: none; font-weight: 600; font-size: 13px;
    padding: 4px 10px; border-radius: 6px; box-shadow: var(--tt-shadow-sm);
}
.theme-modern .worker .ribbons-left .ribbon:after { display: none; }
.theme-modern .worker .ribbons-left .ribbon svg { width: 14px; height: 14px; fill: currentColor; vertical-align: -2px; }
.theme-modern .worker .ribbons-left .ribbon.success { background: #e6f6ec; color: #1e7a3c; }
/* Admin buttons (remove consultant / activate / delete) sit under the name, clear of the badges */
.theme-modern .worker__manage {
    display: flex; flex-wrap: wrap; justify-content: center; gap: 6px;
    padding: 0 16px 18px; margin-top: -12px;
}
.theme-modern .worker__manage form { display: inline; margin: 0; }
.theme-modern .worker__manage .btn { border-radius: 999px; padding: 3px 10px; }
/* Staff: hold ends within 7 days or is already over */
.theme-modern .card.card--hold-due { box-shadow: 0 0 0 3px #f0ad4e, 0 6px 18px rgba(240, 173, 78, .35); background: #fff8ec; }
.theme-modern .ribbon.ribbon--hold-due { font-weight: 600; animation: tt-pulse 1.6s ease-in-out infinite; }
.theme-modern #objects tbody tr.row--hold-due > td { background: #fff3dc !important; }
.theme-modern #objects tbody tr.row--hold-due > td:first-child { box-shadow: inset 4px 0 0 #f0ad4e; }

/* Admin: location order (/locations/ranks) */
.theme-modern .ranks__picker { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 0 0 18px; }
.theme-modern .ranks__levels .btn input[type=radio] { position: absolute; clip: rect(0, 0, 0, 0); pointer-events: none; }
.theme-modern .ranks__levels .btn.active { background: var(--tt-accent); border-color: var(--tt-accent); color: #fff; box-shadow: none; }
.theme-modern .ranks__select { width: auto; min-width: 220px; max-width: 100%; }
.theme-modern .ranks__empty { color: var(--tt-muted); padding: 24px 0; }
.theme-modern .ranks__columns { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: start; }
@media (max-width: 767px) { .theme-modern .ranks__columns { grid-template-columns: 1fr; } }
.theme-modern .ranks__col { background: var(--tt-white); border: 1px solid var(--tt-line); border-radius: var(--tt-radius); padding: 14px; min-width: 0; }
.theme-modern .ranks__title { margin: 0 0 4px; font-size: 16px; font-weight: 600; }
.theme-modern .ranks__hint { color: var(--tt-muted); font-size: 13px; margin: 0 0 10px; }
.theme-modern .ranks__filter { margin: 6px 0 10px; }
.theme-modern .ranks__list { list-style: none; margin: 0; padding: 0; min-height: 56px; max-height: 65vh; overflow-y: auto; }
.theme-modern .ranks__list--ranked { border: 2px dashed var(--tt-line-strong); border-radius: var(--tt-radius-sm); padding: 4px; }
.theme-modern .ranks__item {
    display: flex; align-items: center; gap: 8px; padding: 6px 8px; margin: 0 0 4px;
    background: var(--tt-white); border: 1px solid var(--tt-line); border-radius: var(--tt-radius-sm);
}
.theme-modern .ranks__item.is-ranked { background: #f2f7fd; border-color: #cfe0f4; }
.theme-modern .ranks__item--placeholder { height: 44px; background: #e6f0fb; border: 1px dashed var(--tt-accent); }
.theme-modern .ranks__item.ui-sortable-helper { box-shadow: 0 8px 20px rgba(0, 0, 0, .15); }
.theme-modern .ranks__handle { cursor: grab; color: var(--tt-muted); padding: 4px 2px; touch-action: none; }
.theme-modern .ranks__number { width: 64px; height: 30px; padding: 2px 6px; text-align: center; flex: 0 0 auto; }
.theme-modern .ranks__name { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.theme-modern .ranks__count { flex: 0 0 auto; background: var(--tt-bg); color: var(--tt-muted); font-weight: 500; }
.theme-modern .ranks__actions { display: flex; gap: 3px; flex: 0 0 auto; }
.theme-modern .ranks__item:not(.is-ranked) .js-up,
.theme-modern .ranks__item:not(.is-ranked) .js-down,
.theme-modern .ranks__item:not(.is-ranked) .js-remove,
.theme-modern .ranks__item.is-ranked .js-add { display: none; }
.theme-modern .ranks__bar {
    position: sticky; bottom: 0; z-index: 5; display: flex; justify-content: flex-end; align-items: center; gap: 10px;
    margin-top: 16px; padding: 12px 0; background: var(--tt-bg);
}
.theme-modern .ranks__dirty { color: #c77700; margin-right: auto; font-weight: 500; }

/* ---------- Announcement popup & advertisement window ---------------------- */
.promo-pop {
    position: fixed; inset: 0; z-index: 10050; display: flex; align-items: center; justify-content: center;
    padding: 20px; background: rgba(15, 20, 28, .62); animation: promo-fade .25s var(--tt-ease);
}
.promo-pop[hidden] { display: none; }
.promo-pop__box { position: relative; max-width: min(720px, 100%); line-height: 0; }
.promo-pop__box img {
    display: block; max-width: 100%; max-height: calc(100vh - 80px); border-radius: var(--tt-radius-lg);
    box-shadow: 0 20px 60px rgba(0, 0, 0, .4); background: var(--tt-white);
}
.promo-pop__close {
    position: absolute; top: -14px; right: -14px; z-index: 1; width: 36px; height: 36px; border: 0; border-radius: 50%;
    background: var(--tt-white); color: var(--tt-ink); font-size: 16px; line-height: 1; box-shadow: var(--tt-shadow); cursor: pointer;
}
.promo-pop__close:hover { background: var(--tt-accent); color: var(--tt-white); }
@media (max-width: 767px) { .promo-pop__close { top: 8px; right: 8px; } }
@keyframes promo-fade { from { opacity: 0; } to { opacity: 1; } }

.promo-ad { position: fixed; left: 0; top: 50%; z-index: 990; transform: translateY(-50%); }
.promo-ad__panel {
    width: min(280px, calc(100vw - 48px)); background: var(--tt-white); border: 1px solid var(--tt-line); border-left: 0;
    border-radius: 0 var(--tt-radius) var(--tt-radius) 0; box-shadow: var(--tt-shadow); overflow: hidden;
    animation: promo-fade .3s var(--tt-ease);
}
.promo-ad__head {
    display: flex; align-items: center; justify-content: space-between; padding: 6px 6px 6px 12px;
    background: var(--tt-accent); color: var(--tt-white);
}
.promo-ad__title { font-size: 13px; font-weight: 600; }
.promo-ad__collapse {
    width: 28px; height: 28px; border: 0; border-radius: 6px; background: rgba(255, 255, 255, .16);
    color: var(--tt-white); font-size: 16px; line-height: 1; cursor: pointer;
}
.promo-ad__collapse:hover { background: rgba(255, 255, 255, .3); }
.promo-ad__slide { display: none; }
.promo-ad__slide.is-current { display: block; animation: promo-fade .4s var(--tt-ease); }
.promo-ad__slide img { display: block; width: 100%; max-height: 60vh; object-fit: contain; }
.promo-ad__caption { padding: 8px 12px; font-size: 13px; font-weight: 500; color: var(--tt-ink); }
.promo-ad__dots { display: flex; justify-content: center; gap: 6px; padding: 8px; }
.promo-ad__dots button { width: 8px; height: 8px; padding: 0; border: 0; border-radius: 50%; background: var(--tt-line-strong); cursor: pointer; }
.promo-ad__dots button.is-current { background: var(--tt-accent); }
.promo-ad__tab {
    display: none; align-items: center; gap: 8px; padding: 12px 7px; border: 0; cursor: pointer;
    border-radius: 0 var(--tt-radius-sm) var(--tt-radius-sm) 0; background: var(--tt-accent); color: var(--tt-white);
    font-size: 13px; font-weight: 600; box-shadow: var(--tt-shadow); writing-mode: vertical-rl;
}
.promo-ad__tab:hover { background: var(--tt-accent-hover); }
.promo-ad.is-collapsed .promo-ad__tab { display: flex; }
.promo-ad.is-collapsed .promo-ad__panel { display: none; }
@media print { .promo-ad, .promo-pop { display: none !important; } }

/* Admin page */
.theme-modern .promos__section { background: var(--tt-white); border: 1px solid var(--tt-line); border-radius: var(--tt-radius); padding: 18px; margin: 0 0 20px; }
.theme-modern .promos__title { margin: 0 0 4px; font-size: 18px; font-weight: 600; }
.theme-modern .promos__hint { color: var(--tt-muted); font-size: 13px; margin: 0 0 14px; }
.theme-modern .promos__form {
    display: flex; flex-wrap: wrap; gap: 10px; align-items: center; padding: 12px; margin: 0 0 16px;
    background: var(--tt-bg); border-radius: var(--tt-radius-sm);
}
.theme-modern .promos__form .form-control { flex: 1 1 200px; width: auto; min-width: 0; }
.theme-modern .promos__check { display: inline-flex; align-items: center; gap: 6px; margin: 0; font-weight: 500; cursor: pointer; }
.theme-modern .promos__check input { margin: 0; }
.theme-modern .promos__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; }
.theme-modern .promos__card { border: 1px solid var(--tt-line); border-radius: var(--tt-radius-sm); overflow: hidden; opacity: .7; }
.theme-modern .promos__card.is-active { opacity: 1; border-color: var(--tt-accent); box-shadow: var(--tt-shadow-sm); }
.theme-modern .promos__thumb { display: block; background: var(--tt-bg); }
.theme-modern .promos__thumb img { display: block; width: 100%; height: 170px; object-fit: contain; }
.theme-modern .promos__state { display: flex; align-items: center; justify-content: space-between; padding: 8px 10px; border-top: 1px solid var(--tt-line); }
.theme-modern .promos__state form { margin: 0; }
.theme-modern .promos__edit { display: grid; gap: 6px; padding: 0 10px 10px; margin: 0; }
.theme-modern .promos__replace { margin: 0; font-size: 12px; font-weight: 500; color: var(--tt-muted); }
.theme-modern .promos__replace input { display: block; max-width: 100%; margin-top: 2px; font-weight: 400; }
.theme-modern .promos__empty { color: var(--tt-muted); margin: 0; }

/* Listings loading: a Material-style circular progress instead of a button state.
   Footer spinner replaces "Load more" while a page loads; a viewport-centred one shows during a category switch. */
.theme-modern .tt-progress { display: none; width: 40px; height: 40px; color: var(--tt-accent); animation: tt-rotate 1.4s linear infinite; }
.theme-modern .tt-progress svg { display: block; width: 100%; height: 100%; }
.theme-modern .tt-progress circle { stroke: currentColor; stroke-linecap: round; stroke-dasharray: 80px, 200px; stroke-dashoffset: 0; animation: tt-dash 1.4s ease-in-out infinite; }
@keyframes tt-rotate { to { transform: rotate(360deg); } }
@keyframes tt-dash {
    0% { stroke-dasharray: 1px, 200px; stroke-dashoffset: 0; }
    50% { stroke-dasharray: 100px, 200px; stroke-dashoffset: -15px; }
    100% { stroke-dasharray: 100px, 200px; stroke-dashoffset: -125px; }
}
.theme-modern .widget__footer .tt-progress { margin: 12px auto 0; }
.theme-modern .widget__footer .widget__more.form__submit { visibility: hidden; height: 1px; margin: 0; padding: 0; border: 0; overflow: hidden; } /* no button: scrolling loads more, the element is only the scroll marker */
.theme-modern .widget__more.loading ~ .tt-progress { display: block; }
.theme-modern .tt-progress--page { position: fixed; z-index: 1000; top: calc(50% - 20px); left: calc(50% - 20px); margin: 0; padding: 6px; box-sizing: content-box; background: #fff; border-radius: 50%; box-shadow: var(--tt-shadow); width: 40px; height: 40px; transform-origin: center; }
.theme-modern .site__main.is-switching .tt-progress--page { display: block; }
.theme-modern .site__main.is-switching .listing { opacity: .5; transition: opacity .15s; }

/* Filters panel expanded: the quick row (rooms / price / district / Search) is redundant, so it steps aside */
.theme-modern .search-box.filters-open #quick_form { display: none !important; }

/* Mobile menu sub-menus (e.g. Language): theme.css draws the links white for its old blue drawer,
   but the modern panel is white, so the names were invisible. Give panel and text explicit colours. */
@media (max-width: 767px) {
    .theme-modern .navbar__dropdown,
    .theme-modern .navbar__dropdown .navbar__submenu,
    .theme-modern .navbar__submenu--level { background: var(--tt-white) !important; }
    .theme-modern .navbar__sublink,
    .theme-modern .navbar__back { color: var(--tt-ink) !important; }
    .theme-modern .navbar__subitem.active > .navbar__sublink,
    .theme-modern .navbar__sublink:hover { color: var(--tt-accent) !important; font-weight: 600; }
    .theme-modern .navbar__subitem { border-bottom-color: var(--tt-line); }
}
