:root {
    --bg: #f3efe4;
    --bg-soft: #e9dfc6;
    --surface: #ffffff;
    --surface-2: #faf6eb;
    --text: #1f1a14;
    --muted: #6b6256;
    --line: #d9cfbc;
    --primary: #bc6f31;
    --primary-dark: #8d4d1d;
    --secondary: #0e6f61;
    --secondary-dark: #0c4f45;
    --danger: #a43c35;
    --gold: #dfbe75;
    --radius-sm: 10px;
    --radius: 16px;
    --radius-lg: 28px;
    --shadow: 0 16px 46px rgba(30, 22, 14, 0.14);
    --shadow-soft: 0 10px 28px rgba(21, 16, 12, 0.09);
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    padding: 0;
}

body {
    font-family: "Noto Sans Georgian", sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at 10% 20%, rgba(180, 106, 47, 0.08), transparent 33%),
        radial-gradient(circle at 88% 4%, rgba(15, 99, 86, 0.11), transparent 28%),
        var(--bg);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    position: relative;
    overflow-x: clip;
}

body::before,
body::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: -2;
}

body::before {
    background:
        radial-gradient(560px circle at 20% 18%, rgba(188, 111, 49, 0.16), transparent 60%),
        radial-gradient(500px circle at 80% 12%, rgba(14, 111, 97, 0.14), transparent 58%),
        radial-gradient(680px circle at 52% 90%, rgba(223, 190, 117, 0.12), transparent 66%);
    animation: meshShift 16s ease-in-out infinite alternate;
}

body::after {
    z-index: -1;
    background-image:
        linear-gradient(to right, rgba(255, 255, 255, 0.06) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(255, 255, 255, 0.06) 1px, transparent 1px);
    background-size: 28px 28px;
    opacity: 0.35;
}

.page-shell {
    position: relative;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    width: min(1200px, 92%);
    margin: 0 auto;
}

.main-content {
    min-height: calc(100vh - 240px);
}

.section {
    padding: 72px 0;
}

.section-compact {
    padding: 54px 0;
}

.section-soft {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(236, 231, 216, 0.55));
}

.section-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 16px;
    margin-bottom: 24px;
}

.section-head h2 {
    margin: 0;
    font: 700 42px/1.05 "Cormorant Garamond", serif;
    letter-spacing: 0.02em;
}

.section-head p,
.section-head a {
    margin: 0;
    color: var(--muted);
    font-weight: 600;
}

.listings-toolbar {
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.toolbar-sort-form {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 4px 10px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface);
}

.toolbar-sort-form label {
    margin: 0;
    font-size: 12px;
    font-weight: 700;
    color: var(--muted);
}

.toolbar-sort-form select {
    min-width: 180px;
    height: 32px;
    padding: 4px 28px 4px 10px;
    border-radius: 999px;
    font-size: 12px;
}

.view-toggle {
    display: inline-flex;
    gap: 6px;
    padding: 4px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface);
}

.view-toggle-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 56px;
    height: 32px;
    border-radius: 999px;
    padding: 0 12px;
    color: var(--muted);
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
    transition: background-color .2s ease, color .2s ease;
}

.view-toggle-btn:hover {
    background: var(--surface-2);
}

.view-toggle-btn.is-active {
    background: linear-gradient(135deg, var(--primary), var(--gold));
    color: #fff;
}

.tabs-head {
    align-items: center;
}

.home-tabs {
    display: inline-flex;
    gap: 8px;
    padding: 6px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: var(--surface);
}

.home-tab-btn {
    border: 0;
    background: transparent;
    color: var(--muted);
    border-radius: 999px;
    padding: 8px 14px;
    font-weight: 700;
    cursor: pointer;
    transition: background-color .2s ease, color .2s ease, transform .2s ease;
}

.home-tab-btn:hover {
    transform: translateY(-1px);
}

.home-tab-btn.is-active {
    background: linear-gradient(135deg, var(--primary), var(--gold));
    color: #fff;
}

.tab-panel {
    display: none;
}

.tab-panel.is-active {
    display: block;
}

.section-inline-link {
    margin-bottom: 14px;
}

.section-inline-link a {
    color: var(--muted);
    font-weight: 700;
    text-decoration: none;
}

.section-inline-link a:hover {
    text-decoration: underline;
}

.eyebrow {
    margin: 0 0 12px;
    color: var(--secondary);
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-size: 12px;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 80;
    backdrop-filter: blur(18px);
    background: rgba(243, 239, 228, 0.82);
    border-bottom: 1px solid rgba(31, 26, 20, 0.08);
    box-shadow: 0 10px 24px rgba(31, 26, 20, 0.06);
}

.nav-wrap {
    min-height: 82px;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 18px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.brand-mark {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    background: linear-gradient(145deg, var(--primary), var(--gold));
    color: #fff;
    font: 700 18px/1 "Cormorant Garamond", serif;
    box-shadow: 0 8px 20px rgba(188, 111, 49, 0.35);
}

.brand strong {
    display: block;
    font: 700 24px/1 "Cormorant Garamond", serif;
}

.brand small {
    display: block;
    color: var(--muted);
    font-size: 11px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.main-nav {
    justify-self: center;
    display: inline-flex;
    align-items: center;
    gap: 22px;
    font-weight: 600;
}

.main-nav a {
    position: relative;
    padding-bottom: 4px;
}

.main-nav a::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 2px;
    transform: scaleX(0);
    transform-origin: left;
    background: linear-gradient(90deg, var(--secondary), var(--gold));
    transition: transform .25s ease;
}

.main-nav a:hover::after,
.main-nav a.active::after {
    transform: scaleX(1);
}

.header-actions {
    display: inline-flex;
    gap: 8px;
}

.header-actions .btn {
    white-space: nowrap;
    flex: 0 0 auto;
}

.category-strip {
    border-top: 1px solid rgba(31, 26, 20, 0.06);
    background: rgba(255, 255, 255, 0.72);
}

.category-strip-inner {
    display: flex;
    align-items: center;
    gap: 8px;
    overflow-x: auto;
    padding: 10px 0;
}

.category-strip-inner a {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 999px;
    padding: 8px 12px;
    font-weight: 600;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: transform .2s ease, box-shadow .2s ease;
}

.category-strip-icon {
    width: 18px;
    height: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--secondary-dark);
}

.category-strip-icon .icon-svg {
    width: 18px;
    height: 18px;
}

.category-strip-inner a:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-soft);
}

.menu-toggle {
    display: none;
    border: 0;
    background: transparent;
    width: 36px;
    height: 36px;
    padding: 0;
}

.menu-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    margin: 5px auto;
    background: var(--text);
}

.hero {
    position: relative;
    overflow: hidden;
    padding: 66px 0 54px;
}

.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(120deg, rgba(255, 255, 255, 0.2), transparent 35%),
        repeating-linear-gradient(130deg, rgba(255, 255, 255, 0.08) 0px, rgba(255, 255, 255, 0.08) 1px, transparent 1px, transparent 18px);
    mix-blend-mode: soft-light;
    pointer-events: none;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.1fr .9fr;
    gap: 34px;
    align-items: start;
}

.hero-content h1 {
    margin: 0;
    font: 700 clamp(40px, 5vw, 68px)/0.98 "Cormorant Garamond", serif;
    letter-spacing: 0.01em;
}

.hero-text {
    margin-top: 18px;
    color: var(--muted);
    max-width: 600px;
    font-size: 17px;
}

.hero-stats {
    margin-top: 24px;
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.hero-stats div {
    min-width: 170px;
    border-radius: 14px;
    border: 1px solid rgba(31, 26, 20, 0.08);
    background: rgba(255, 255, 255, 0.78);
    padding: 12px 14px;
    box-shadow: var(--shadow-soft);
}

.hero-stats strong {
    display: block;
    font-size: 24px;
    line-height: 1;
}

.hero-stats span {
    color: var(--muted);
    font-size: 13px;
}

.hero-search {
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.45);
    border-radius: var(--radius-lg);
    padding: 22px;
    box-shadow: var(--shadow);
    position: relative;
    overflow: hidden;
}

.hero-search::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    border: 1px solid transparent;
    background: linear-gradient(135deg, rgba(14, 111, 97, 0.36), rgba(223, 190, 117, 0.36)) border-box;
    -webkit-mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

.hero-search h2 {
    margin: 0 0 12px;
    font: 700 34px/1 "Cormorant Garamond", serif;
}

.hero-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(1px);
    opacity: .34;
    animation: float 9s ease-in-out infinite;
}

.hero-orb-a {
    right: -90px;
    top: 30px;
    width: 270px;
    height: 270px;
    background: radial-gradient(circle, rgba(180, 106, 47, .55), rgba(180, 106, 47, 0));
}

.hero-orb-b {
    left: -70px;
    bottom: -90px;
    width: 220px;
    height: 220px;
    background: radial-gradient(circle, rgba(15, 99, 86, .45), rgba(15, 99, 86, 0));
    animation-delay: -2s;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.hero-search .form-grid .field > label {
    min-height: 2.6em;
    line-height: 1.25;
    display: flex;
    align-items: flex-end;
}

.hero-auth-cta {
    margin-top: 12px;
    display: flex;
    gap: 8px;
}

.hero-auth-cta .btn {
    flex: 1 1 0;
}

.search-actions-inline {
    display: flex;
    gap: 8px;
}

.field {
    margin-bottom: 12px;
}

.field-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.field-row .field.field-span-2 {
    grid-column: 1 / -1;
}

.field-row.field-row-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

label {
    display: block;
    margin-bottom: 6px;
    font-size: 13px;
    color: var(--muted);
    font-weight: 600;
}

input,
select,
textarea {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: var(--radius-sm);
    padding: 10px 12px;
    font-size: 14px;
    color: var(--text);
    background: var(--surface);
    transition: border-color .2s ease, box-shadow .2s ease;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: rgba(180, 106, 47, .64);
    box-shadow: 0 0 0 3px rgba(180, 106, 47, .12);
}

.location-autocomplete {
    position: relative;
}

.location-autocomplete-results {
    position: absolute;
    top: calc(100% + 6px);
    left: 0;
    right: 0;
    z-index: 24;
    display: grid;
    gap: 4px;
    padding: 8px;
    border: 1px solid rgba(31, 26, 20, 0.1);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 18px 36px rgba(24, 18, 12, 0.14);
    max-height: 280px;
    overflow-y: auto;
}

.location-autocomplete-results[hidden] {
    display: none !important;
}

.location-autocomplete-group + .location-autocomplete-group {
    margin-top: 4px;
    padding-top: 6px;
    border-top: 1px solid rgba(31, 26, 20, 0.08);
}

.location-autocomplete-group-label {
    padding: 4px 12px 6px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--muted);
}

.location-autocomplete-item {
    width: 100%;
    border: 0;
    border-radius: 10px;
    background: transparent;
    padding: 10px 12px;
    text-align: left;
    cursor: pointer;
    display: grid;
    gap: 3px;
    transition: background-color .18s ease;
}

.location-autocomplete-item:hover,
.location-autocomplete-item:focus-visible {
    background: var(--surface-2);
    outline: none;
}

.location-autocomplete-item strong {
    font-size: 14px;
    color: var(--text);
}

.location-autocomplete-item span {
    font-size: 12px;
    color: var(--muted);
}

.field-note {
    display: block;
    margin-top: 6px;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.45;
}

textarea {
    resize: vertical;
}

.btn {
    border: 0;
    border-radius: 999px;
    padding: 10px 16px;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: transform .2s ease, box-shadow .2s ease, background-color .2s ease;
    position: relative;
    overflow: hidden;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--gold));
    color: #fff;
    box-shadow: 0 10px 24px rgba(180, 106, 47, 0.26);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #c5793a, #ebc77e);
}

.btn-primary::after {
    content: "";
    position: absolute;
    top: -40%;
    left: -120%;
    width: 80px;
    height: 180%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.34), transparent);
    transform: rotate(18deg);
    transition: left .45s ease;
}

.btn-primary:hover::after {
    left: 130%;
}

.btn[disabled] {
    opacity: .62;
    cursor: not-allowed;
    transform: none;
}

.btn.is-on[disabled] {
    opacity: 1;
    box-shadow: 0 8px 20px rgba(180, 106, 47, 0.2);
}

.btn-outline {
    border: 1px solid rgba(15, 99, 86, 0.42);
    background: transparent;
    color: var(--secondary);
}

.btn-ghost {
    background: var(--surface);
    border: 1px solid var(--line);
}

.btn-danger {
    background: rgba(164, 60, 53, 0.12);
    border: 1px solid rgba(164, 60, 53, 0.38);
    color: var(--danger);
}

.btn-whatsapp {
    background: linear-gradient(135deg, #25d366, #1ea851);
    border: 1px solid transparent;
    color: #fff;
    box-shadow: 0 10px 22px rgba(37, 211, 102, 0.22);
}

.btn-whatsapp:hover {
    background: linear-gradient(135deg, #22bf5d, #1b9749);
    color: #fff;
}

.btn-sm {
    font-size: 12px;
    padding: 6px 10px;
}

.btn-block {
    width: 100%;
}

.listing-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
}

.listing-grid--list {
    grid-template-columns: 1fr;
}

.listing-grid--list .listing-card {
    display: grid;
    grid-template-columns: minmax(220px, 320px) minmax(0, 1fr);
    align-items: stretch;
}

.listing-grid--list .listing-image-wrap {
    height: 100%;
    min-height: 220px;
}

.listing-grid--list .listing-body {
    padding: 16px 18px;
}

.listing-grid--list .listing-card h3 {
    font-size: 22px;
}


.listing-card {
    background: var(--surface);
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid rgba(31, 26, 20, 0.07);
    box-shadow: var(--shadow-soft);
    transition: box-shadow .28s ease;
    transform-style: preserve-3d;
    will-change: transform;
    position: relative;
}

.favorite-quick-form {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 3;
}

.favorite-quick-btn {
    width: 38px;
    height: 38px;
    border-radius: 999px;
    border: 1px solid rgba(31, 26, 20, 0.18);
    background: rgba(255, 255, 255, 0.95);
    color: #8e7d67;
    font-size: 18px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.14);
    transition: transform .18s ease, background-color .18s ease, color .18s ease, border-color .18s ease;
}

.favorite-quick-btn:hover {
    transform: translateY(-1px);
    color: #c44d4d;
}

.favorite-quick-btn.is-active {
    background: rgba(196, 77, 77, 0.14);
    border-color: rgba(196, 77, 77, 0.46);
    color: #b03d3d;
}

.listing-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(150deg, rgba(223, 190, 117, 0.14), transparent 42%, rgba(14, 111, 97, 0.1));
    opacity: 0;
    transition: opacity .28s ease;
    pointer-events: none;
}

.listing-card:hover {
    box-shadow: 0 18px 44px rgba(31, 26, 20, 0.16);
}

.listing-card:hover::before {
    opacity: 1;
}

.listing-image-wrap {
    display: block;
    height: 210px;
    position: relative;
}

.listing-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .38s ease;
}

.listing-card:hover .listing-image {
    transform: scale(1.05);
}

.listing-badge {
    position: absolute;
    left: 12px;
    top: 12px;
    background: linear-gradient(135deg, var(--secondary), #2a9f87);
    color: #fff;
    border-radius: 999px;
    padding: 6px 10px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.04em;
}

.listing-body {
    padding: 14px;
}

.listing-meta {
    display: flex;
    gap: 8px;
    color: var(--muted);
    font-size: 12px;
    flex-wrap: wrap;
}

.listing-card h3 {
    margin: 8px 0 6px;
    font-size: 19px;
    line-height: 1.3;
}

.listing-location {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
}

.listing-features {
    margin-top: 12px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.listing-features span {
    background: var(--surface-2);
    border: 1px solid rgba(31, 26, 20, 0.06);
    border-radius: 999px;
    padding: 5px 10px;
    font-size: 12px;
}

.listing-footer {
    margin-top: 14px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.listing-footer strong {
    font-size: 20px;
    font-weight: 700;
}

.listing-price-block {
    display: grid;
    gap: 2px;
}

.listing-price-block small {
    font-size: 12px;
    color: var(--muted);
    font-weight: 600;
}

.listing-footer-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.listing-date {
    font-size: 12px;
    color: var(--muted);
}

.link-arrow {
    font-weight: 700;
    color: var(--secondary);
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 12px;
}

.category-card {
    border-radius: 14px;
    border: 1px solid var(--line);
    background:
        radial-gradient(circle at 80% 10%, rgba(223, 190, 117, 0.2), transparent 45%),
        linear-gradient(145deg, #fff, #faf8f3);
    min-height: 110px;
    display: grid;
    place-items: center;
    text-align: center;
    gap: 6px;
    box-shadow: var(--shadow-soft);
    transition: box-shadow .26s ease;
    transform-style: preserve-3d;
}

.category-card:hover {
    box-shadow: 0 16px 36px rgba(24, 18, 12, 0.14);
}

.category-card-icon {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--secondary-dark);
}

.category-card-icon .icon-svg {
    width: 32px;
    height: 32px;
}

.category-card strong {
    font-size: 14px;
}

.layout-listings {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 20px;
}


.filters-panel {
    position: sticky;
    top: 126px;
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid rgba(31, 26, 20, 0.08);
    border-radius: var(--radius);
    padding: 16px;
    max-height: calc(100vh - 160px);
    overflow-y: auto;
    box-shadow: var(--shadow-soft);
}

.filters-panel-head {
    display: none;
}

.filters-panel-close {
    border: 1px solid var(--line);
    background: var(--surface-2);
    color: var(--text);
    width: 36px;
    height: 36px;
    border-radius: 999px;
    cursor: pointer;
    font-weight: 700;
    line-height: 1;
}

.filters-backdrop {
    display: none;
}

.mobile-filters-trigger {
    display: none;
    border: 1px solid var(--line);
    background: var(--surface);
    color: var(--secondary-dark);
    border-radius: 999px;
    padding: 8px 14px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
}

.search-tabs-container {
    border: 1px solid rgba(31, 26, 20, 0.08);
    border-radius: 14px;
    overflow: hidden;
    background: linear-gradient(160deg, rgba(255, 255, 255, 0.97), rgba(250, 245, 232, 0.92));
}

.search-tabs-header {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0;
    background: linear-gradient(180deg, rgba(251, 245, 232, 0.98), rgba(245, 236, 217, 0.95));
    border-bottom: 1px solid rgba(31, 26, 20, 0.12);
}

.search-tab-btn {
    border: 0;
    background: transparent;
    color: var(--secondary-dark);
    padding: 11px 10px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: background-color .2s ease, color .2s ease;
}

.search-tab-btn:hover {
    background: rgba(180, 106, 47, 0.1);
}

.search-tab-btn.is-active {
    background: linear-gradient(135deg, var(--primary), var(--gold));
    color: #fff;
}

.search-tab-content {
    padding: 14px;
}

.advanced-search-form .search-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
}

.advanced-search-form .field {
    margin-bottom: 0;
}

.input-row {
    display: grid;
    gap: 8px;
}

.input-row.input-row-two {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.input-row.input-row-price {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 82px;
}

.input-row.input-row-price input[type="number"],
.input-row.input-row-two input[type="number"] {
    min-width: 0;
    padding-right: 8px;
    font-variant-numeric: tabular-nums;
}

.filters-panel .input-row.input-row-price {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.filters-panel .input-row.input-row-price .currency-select {
    grid-column: 1 / -1;
}

.input-row input[type="number"]::-webkit-outer-spin-button,
.input-row input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.input-row input[type="number"] {
    -moz-appearance: textfield;
    appearance: textfield;
}

.dual-range {
    position: relative;
    margin-top: 10px;
    height: 22px;
}

.dual-range-track {
    position: absolute;
    left: 0;
    right: 0;
    top: 9px;
    height: 4px;
    border-radius: 999px;
    background: rgba(31, 26, 20, 0.12);
    overflow: hidden;
}

.dual-range-track span {
    position: absolute;
    top: 0;
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--primary), var(--gold));
}

.dual-range input[type="range"] {
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    width: 100%;
    margin: 0;
    appearance: none;
    -webkit-appearance: none;
    background: transparent;
    pointer-events: none;
}

.dual-range input[type="range"]::-webkit-slider-runnable-track {
    height: 4px;
    background: transparent;
}

.dual-range input[type="range"]::-moz-range-track {
    height: 4px;
    background: transparent;
}

.dual-range input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid #fff;
    background: var(--secondary);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.22);
    pointer-events: auto;
    cursor: pointer;
    margin-top: -6px;
}

.dual-range input[type="range"]::-moz-range-thumb {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 2px solid #fff;
    background: var(--secondary);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.22);
    pointer-events: auto;
    cursor: pointer;
}

.currency-select {
    min-width: 0;
    padding-left: 8px;
    padding-right: 24px;
    font-size: 13px;
}

.advanced-toggle-container {
    margin-top: 12px;
}

.toggle-advanced-btn {
    width: 100%;
    border: 1px solid var(--line);
    background: var(--surface-2);
    border-radius: 10px;
    padding: 9px 12px;
    font-weight: 700;
    color: var(--secondary-dark);
    cursor: pointer;
    transition: background-color .2s ease, border-color .2s ease;
}

.toggle-advanced-btn:hover {
    border-color: rgba(14, 111, 97, 0.46);
    background: #f6f1e4;
}

.advanced-grid {
    display: none;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px dashed rgba(31, 26, 20, 0.14);
}

.advanced-grid.is-open {
    display: grid;
}

.advanced-grid[hidden] {
    display: none !important;
}

.field-full {
    grid-column: 1 / -1;
}

.filter-checks {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 14px;
}

.search-actions {
    margin-top: 14px;
    display: flex;
    gap: 8px;
}

.search-actions .btn {
    flex: 1 1 0;
}

.checkbox {
    display: inline-flex;
    gap: 8px;
    align-items: center;
    margin-bottom: 8px;
    font-size: 14px;
    color: var(--text);
}

.checkbox input {
    width: 16px;
    height: 16px;
}

.checkbox-group {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

.pagination {
    margin-top: 20px;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.pagination a {
    min-width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border-radius: 10px;
    border: 1px solid var(--line);
    background: var(--surface);
}

.pagination a.active {
    background: var(--secondary);
    border-color: var(--secondary);
    color: #fff;
}

.detail-header {
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid rgba(31, 26, 20, 0.08);
    padding: 22px;
    margin-bottom: 18px;
    display: flex;
    justify-content: space-between;
    gap: 18px;
}

.detail-header h1 {
    margin: 0;
    font: 700 44px/1 "Cormorant Garamond", serif;
}

.detail-breadcrumbs {
    margin: 0 0 8px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 12px;
    color: var(--muted);
}

.detail-breadcrumbs a {
    color: var(--muted);
    text-decoration: none;
    transition: color .2s ease;
}

.detail-breadcrumbs a:hover {
    color: var(--secondary);
}

.detail-location-links {
    margin: 10px 0 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.location-separator {
    color: var(--muted);
    line-height: 1;
}

.location-quick-link {
    display: inline-flex;
    align-items: center;
    min-height: 32px;
    padding: 6px 12px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: var(--surface-2);
    color: var(--text);
    text-decoration: none;
    font-weight: 600;
    transition: border-color 0.2s ease, color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

.location-quick-link:hover {
    border-color: var(--secondary);
    color: var(--secondary);
    background: #fff;
    transform: translateY(-1px);
}

.detail-price-box {
    text-align: right;
}

.detail-price-box strong {
    display: block;
    font-size: 36px;
    line-height: 1;
}

.detail-price-per-m2 {
    display: block;
    margin-top: 4px;
    color: var(--secondary-dark);
    font-size: 14px;
    font-weight: 700;
}

.detail-price-box small {
    color: var(--muted);
}

.detail-layout {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 18px;
    align-items: start;
}

.detail-gallery {
    background: var(--surface);
    border-radius: var(--radius);
    border: 1px solid rgba(31, 26, 20, 0.08);
    padding: 12px;
}

.detail-gallery-main {
    position: relative;
}

.detail-gallery-fullscreen-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
    width: 40px;
    height: 40px;
    border: 1px solid rgba(31, 26, 20, 0.18);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.9);
    color: var(--secondary-dark);
    cursor: pointer;
    font-size: 18px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s ease, transform .15s ease, background-color .2s ease;
}

.detail-gallery-fullscreen-btn:hover {
    background: #fff;
    transform: scale(1.04);
}

.detail-gallery > img {
    width: 100%;
    max-height: 460px;
    object-fit: cover;
    border-radius: 12px;
}

.detail-gallery-main > img {
    width: 100%;
    max-height: 460px;
    object-fit: cover;
    border-radius: 12px;
}

.detail-gallery-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    border: 1px solid rgba(31, 26, 20, 0.18);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.9);
    color: var(--secondary-dark);
    cursor: pointer;
    font-size: 26px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: transform .15s ease, background-color .2s ease, opacity .2s ease;
    opacity: 0;
    pointer-events: none;
}

.detail-gallery-nav:hover {
    background: #fff;
    transform: translateY(-50%) scale(1.04);
}

.detail-gallery-main:hover .detail-gallery-nav,
.detail-gallery-main:focus-within .detail-gallery-nav {
    opacity: 1;
    pointer-events: auto;
}

.detail-gallery-main:hover .detail-gallery-fullscreen-btn,
.detail-gallery-main:focus-within .detail-gallery-fullscreen-btn {
    opacity: 1;
    pointer-events: auto;
}

.detail-gallery-nav.is-prev {
    left: 10px;
}

.detail-gallery-nav.is-next {
    right: 10px;
}

.detail-gallery-lightbox {
    position: fixed;
    inset: 0;
    z-index: 1600;
    background: rgba(12, 10, 8, 0.92);
    display: grid;
    place-items: center;
    padding: 24px;
}

.detail-gallery-lightbox[hidden] {
    display: none !important;
}

.detail-gallery-lightbox-image {
    max-width: min(1280px, 92vw);
    max-height: 84vh;
    object-fit: contain;
    border-radius: 10px;
}

.detail-gallery-lightbox-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 42px;
    height: 42px;
    border: 1px solid rgba(255, 255, 255, 0.34);
    border-radius: 999px;
    background: rgba(20, 20, 20, 0.48);
    color: #fff;
    font-size: 30px;
    line-height: 1;
    cursor: pointer;
}

.detail-gallery-lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 54px;
    height: 54px;
    border: 1px solid rgba(255, 255, 255, 0.34);
    border-radius: 999px;
    background: rgba(20, 20, 20, 0.45);
    color: #fff;
    cursor: pointer;
    font-size: 36px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s ease, transform .15s ease, background-color .2s ease;
}

.detail-gallery-lightbox:hover .detail-gallery-lightbox-nav,
.detail-gallery-lightbox:focus-within .detail-gallery-lightbox-nav {
    opacity: 1;
    pointer-events: auto;
}

.detail-gallery-lightbox-nav.is-prev {
    left: 16px;
}

.detail-gallery-lightbox-nav.is-next {
    right: 16px;
}

.detail-gallery-lightbox-counter {
    position: absolute;
    bottom: 16px;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 999px;
    padding: 7px 12px;
    background: rgba(20, 20, 20, 0.46);
    color: rgba(255, 255, 255, 0.95);
    font-size: 13px;
    font-weight: 700;
}

body.gallery-lightbox-open {
    overflow: hidden;
}

@media (hover: none), (pointer: coarse) {
    .detail-gallery-nav,
    .detail-gallery-fullscreen-btn,
    .detail-gallery-lightbox-nav {
        opacity: 1;
        pointer-events: auto;
    }
}

.detail-gallery-meta {
    margin-top: 8px;
    display: flex;
    justify-content: flex-end;
}

.detail-gallery-counter {
    font-size: 12px;
    font-weight: 700;
    color: var(--muted);
}

.thumb-grid {
    margin-top: 8px;
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 8px;
}

.thumb-btn {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    padding: 0;
    cursor: pointer;
    transition: border-color .2s ease, box-shadow .2s ease;
    width: 112px;
    flex: 0 0 112px;
}

.thumb-btn.is-active {
    border-color: rgba(180, 106, 47, 0.72);
    box-shadow: 0 0 0 2px rgba(180, 106, 47, 0.16);
}

.thumb-btn img {
    width: 100%;
    height: 66px;
    object-fit: cover;
    border-radius: 7px;
}

.detail-card {
    margin-top: 14px;
    background: var(--surface);
    border: 1px solid rgba(31, 26, 20, 0.08);
    border-radius: var(--radius);
    padding: 18px;
}

.detail-card h3 {
    margin: 0 0 10px;
    font: 700 28px/1 "Cormorant Garamond", serif;
}

.detail-map {
    display: block;
    width: 100%;
    height: 320px;
    box-sizing: border-box;
    position: relative;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 12px;
}

.detail-map-frame {
    width: 100%;
    height: 320px;
    border: 1px solid var(--line);
    border-radius: 12px;
    overflow: hidden;
    background: #f3f1eb;
}

.detail-map-embed {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
}

.detail-map .leaflet-tile,
.detail-map .leaflet-marker-icon,
.detail-map .leaflet-marker-shadow,
.detail-map .leaflet-pane > img {
    max-width: none !important;
}

.map-fallback-note {
    width: 100%;
    height: 100%;
    display: grid;
    place-items: center;
    color: var(--muted);
    font-weight: 600;
    background: #f3f1eb;
}

.map-open-link {
    display: inline-flex;
    margin-top: 10px;
    color: var(--secondary);
    font-weight: 700;
    text-decoration: none;
}

.map-open-link:hover {
    text-decoration: underline;
}

.map-empty {
    margin: 0;
    color: var(--muted);
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.feature-grid div {
    padding: 10px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface-2);
}

.feature-grid span {
    display: block;
    color: var(--muted);
    font-size: 12px;
}

.feature-grid strong {
    font-size: 16px;
}

.mortgage-card {
    background:
        linear-gradient(165deg, rgba(255, 255, 255, 0.92), rgba(248, 244, 236, 0.98)),
        radial-gradient(circle at 10% 0%, rgba(14, 111, 97, 0.08), transparent 45%);
}

.mortgage-grid {
    display: grid;
    gap: 10px;
    grid-template-columns: 1fr;
}

.mortgage-field {
    display: grid;
    gap: 6px;
}

.mortgage-field span {
    font-size: 13px;
    color: var(--muted);
}

.mortgage-field input {
    border: 1px solid var(--line);
    border-radius: 10px;
    height: 42px;
    padding: 0 12px;
    font: 600 14px/1 "Noto Sans Georgian", sans-serif;
    background: rgba(255, 255, 255, 0.85);
}

.mortgage-results {
    margin-top: 12px;
    display: grid;
    gap: 8px;
}

.mortgage-results div {
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.78);
}

.mortgage-results span {
    display: block;
    font-size: 12px;
    color: var(--muted);
}

.mortgage-results strong {
    display: block;
    margin-top: 2px;
    font: 700 20px/1.15 "Cormorant Garamond", serif;
    color: var(--secondary-dark);
}

.mortgage-note {
    margin: 10px 0 0;
    color: var(--muted);
    font-size: 12px;
}

.auth-section {
    padding: 70px 0;
}

.auth-wrap {
    display: grid;
    justify-content: center;
}

.auth-card {
    width: min(520px, 100%);
    border-radius: var(--radius-lg);
    background: var(--surface);
    border: 1px solid rgba(31, 26, 20, 0.08);
    box-shadow: var(--shadow);
    padding: 24px;
}

.auth-card-wide {
    width: min(680px, 100%);
}

.auth-card h1 {
    margin: 0;
    font: 700 40px/1 "Cormorant Garamond", serif;
}

.auth-card p {
    color: var(--muted);
}

.auth-tabs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    margin-bottom: 14px;
}

.auth-tab {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    padding: 10px 12px;
    border-radius: 999px;
    border: 1px solid var(--line);
    background: var(--surface-2);
    font-weight: 700;
    color: var(--text);
    text-decoration: none;
    transition: transform .2s ease, box-shadow .2s ease, background-color .2s ease;
}

.auth-tab:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-soft);
}

.auth-tab.active {
    background: linear-gradient(135deg, var(--primary), var(--gold));
    color: #fff;
    border-color: transparent;
}

.auth-hint {
    margin-top: 16px;
    font-size: 14px;
}

.auth-hint a {
    color: var(--secondary);
    font-weight: 700;
}

.auth-social {
    display: flex;
    justify-content: center;
    margin: 20px 0 10px;
}

.auth-divider {
    position: relative;
    margin: 18px 0;
    text-align: center;
}

.auth-divider::before {
    content: "";
    position: absolute;
    inset: 50% 0 auto;
    border-top: 1px solid var(--line);
}

.auth-divider span {
    position: relative;
    display: inline-block;
    padding: 0 12px;
    background: var(--surface);
    color: var(--muted);
    font-size: 13px;
    font-weight: 700;
}

.auth-inline-alert {
    margin: 18px 0;
}

.panel {
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid rgba(31, 26, 20, 0.08);
    padding: 18px;
}

.profile-avatar-row {
    display: grid;
    grid-template-columns: 110px minmax(0, 1fr);
    gap: 14px;
    align-items: start;
    margin-bottom: 14px;
}

.profile-avatar-preview {
    width: 110px;
    height: 110px;
    border-radius: 18px;
    border: 1px solid var(--line);
    object-fit: cover;
    background: var(--surface-2);
}

.contact-avatar {
    width: 64px;
    height: 64px;
    border-radius: 999px;
    border: 1px solid var(--line);
    object-fit: cover;
    background: var(--surface-2);
    margin: 0 0 10px;
}

.checkbox-inline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
    font-size: 13px;
    color: var(--muted);
}

.checkbox-inline input[type="checkbox"] {
    width: auto;
    margin: 0;
}

.panel-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.panel-head h3 {
    margin: 0;
    font-size: 20px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 16px;
}

.stat-card {
    background: linear-gradient(145deg, #fff, #f8f5ea);
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 16px;
    transition: box-shadow .28s ease;
    transform-style: preserve-3d;
}

.stat-card:hover {
    box-shadow: 0 16px 36px rgba(28, 20, 12, 0.14);
}

.stat-card strong {
    display: block;
    font-size: 30px;
    line-height: 1;
}

.stat-card span {
    font-size: 13px;
    color: var(--muted);
}

.dashboard-menu-grid {
    margin-bottom: 16px;
}

.dashboard-menu-card {
    display: block;
}

.dashboard-menu-card span {
    display: block;
    margin-top: 8px;
    font-size: 15px;
    font-weight: 700;
    color: var(--text);
}

.dashboard-menu-card small {
    display: block;
    margin-top: 4px;
    font-size: 12px;
    color: var(--muted);
}

.dashboard-menu-card:hover,
.dashboard-menu-card:focus-visible {
    border-color: rgba(188, 111, 49, 0.42);
}

.dashboard-menu-card:focus-visible {
    outline: 2px solid rgba(188, 111, 49, 0.24);
    outline-offset: 3px;
}

.dashboard-menu-card.is-active {
    border-color: rgba(188, 111, 49, 0.5);
    background: linear-gradient(145deg, #fffaf2, #f4e6d3);
    box-shadow: 0 16px 36px rgba(28, 20, 12, 0.12);
}

.dashboard-menu-card.is-active strong,
.dashboard-menu-card.is-active span {
    color: var(--primary-dark);
}

.dashboard-panel-anchor {
    scroll-margin-top: 120px;
}

.table-wrap.views-focus .data-table {
    box-shadow: var(--shadow-soft);
}

.compact-list {
    display: grid;
    gap: 10px;
}

.compact-item {
    border: 1px solid var(--line);
    border-radius: 12px;
    padding: 12px;
    background: var(--surface-2);
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

.compact-item strong {
    display: block;
}

.compact-item small {
    color: var(--muted);
}

.table-wrap {
    overflow-x: auto;
}

.admin-shell {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 18px;
    align-items: start;
}

.admin-sidebar {
    position: sticky;
    top: 108px;
}

.admin-sidebar-head h3 {
    margin: 4px 0 8px;
    font: 700 30px/1 "Cormorant Garamond", serif;
}

.admin-sidebar-head p {
    margin: 0;
    color: var(--muted);
    font-size: 14px;
}

.admin-sidebar-kicker {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(194, 136, 56, 0.12);
    color: var(--secondary-dark);
    font-weight: 700;
    font-size: 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.admin-nav {
    margin-top: 16px;
    display: grid;
    gap: 8px;
}

.admin-nav-link {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 12px 14px;
    border-radius: 14px;
    border: 1px solid var(--line);
    background: var(--surface-2);
    color: var(--text);
    text-decoration: none;
    transition: transform 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
}

.admin-nav-link strong {
    font-size: 15px;
}

.admin-nav-link small {
    color: var(--muted);
}

.admin-nav-link:hover,
.admin-nav-link.is-active {
    transform: translateY(-1px);
    border-color: rgba(194, 136, 56, 0.36);
    background: #fff;
}

.admin-sidebar-actions {
    margin-top: 16px;
    display: grid;
    gap: 8px;
}

.admin-main {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.admin-head-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.admin-stats-grid {
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.admin-grid-two {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
}

.admin-summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
}

.admin-summary-card {
    padding: 14px 16px;
    border-radius: 14px;
    border: 1px solid var(--line);
    background: var(--surface-2);
}

.admin-summary-card strong {
    display: block;
    font: 700 24px/1 "Cormorant Garamond", serif;
    margin-bottom: 6px;
}

.admin-summary-card span {
    color: var(--muted);
    font-size: 14px;
}

.admin-summary-link {
    margin-top: 6px;
    display: inline-flex;
    align-items: center;
    font-size: 12px;
    font-weight: 700;
    color: var(--secondary);
    text-decoration: none;
}

.admin-summary-link:hover {
    text-decoration: underline;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--surface);
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid rgba(31, 26, 20, 0.08);
}

.table-tools {
    margin-bottom: 12px;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 10px;
}

.table-tools-search {
    flex: 1 1 320px;
}

.table-tools-search label {
    display: block;
    margin-bottom: 6px;
    font-size: 12px;
    font-weight: 700;
    color: var(--muted);
}

.table-tools-search input {
    width: 100%;
}

.data-table th,
.data-table td {
    padding: 14px 12px;
    border-bottom: 1px solid rgba(31, 26, 20, 0.08);
    text-align: left;
    vertical-align: top;
}

.data-table th {
    background: var(--surface-2);
    font-size: 13px;
}

.data-table small {
    display: block;
    color: var(--muted);
}

.admin-users-table {
    table-layout: fixed;
}

.admin-users-table col.col-user {
    width: 20%;
}

.admin-users-table col.col-role {
    width: 8%;
}

.admin-users-table col.col-agency {
    width: 12%;
}

.admin-users-table col.col-contact {
    width: 12%;
}

.admin-users-table col.col-listings,
.admin-users-table col.col-views {
    width: 7%;
}

.admin-users-table col.col-created {
    width: 10%;
}

.admin-users-table col.col-action {
    width: 24%;
}

.admin-users-table th,
.admin-users-table td {
    padding: 10px 8px;
    font-size: 12px;
}

.admin-users-table td strong,
.admin-users-table td small {
    overflow-wrap: anywhere;
    word-break: break-word;
}

.admin-users-table .role-update-form {
    display: grid;
    grid-template-columns: 1fr;
    gap: 6px;
}

.admin-users-table .role-update-form select {
    width: 100%;
    min-width: 0;
    padding: 5px 6px;
}

.admin-users-table .btn.btn-sm {
    width: 100%;
    padding: 5px 8px;
    font-size: 11px;
}

.table-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.status-pill {
    display: inline-flex;
    border-radius: 999px;
    background: rgba(15, 99, 86, .12);
    color: var(--secondary-dark);
    padding: 4px 10px;
    font-size: 12px;
    font-weight: 700;
}

.role-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    padding: 4px 10px;
    border-radius: 999px;
    background: rgba(14, 111, 97, 0.1);
    color: var(--secondary-dark);
    font-size: 12px;
    font-weight: 700;
    text-transform: capitalize;
}

.role-pill.role-admin {
    background: rgba(194, 136, 56, 0.14);
    color: #8a5a12;
}

.role-pill.role-superadmin {
    background: rgba(74, 43, 116, 0.14);
    color: #4a2b74;
}

.role-pill.role-agent {
    background: rgba(14, 111, 97, 0.12);
    color: var(--secondary-dark);
}

.role-pill.role-user,
.role-pill.role-source {
    background: rgba(31, 26, 20, 0.08);
    color: var(--text);
}

.role-update-form {
    display: flex;
    align-items: center;
    gap: 6px;
}

.role-update-form select {
    min-width: 96px;
    padding: 6px 8px;
}

.agency-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.agency-card {
    background: var(--surface);
    border-radius: var(--radius);
    border: 1px solid rgba(31, 26, 20, 0.08);
    padding: 16px;
}

.agency-logo {
    width: 54px;
    height: 54px;
    border-radius: 14px;
    background: var(--surface-2);
    display: grid;
    place-items: center;
    margin-bottom: 10px;
    border: 1px solid var(--line);
}

.agency-logo span {
    font: 700 30px/1 "Cormorant Garamond", serif;
}

.agency-card h3 {
    margin: 0 0 8px;
}

.agency-card p {
    color: var(--muted);
}

.agency-meta {
    margin-top: 10px;
    display: grid;
    gap: 4px;
    font-size: 13px;
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.project-card {
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid rgba(31, 26, 20, 0.08);
    background: var(--surface);
    transition: box-shadow .28s ease;
    transform-style: preserve-3d;
}

.project-card:hover {
    box-shadow: 0 18px 40px rgba(31, 26, 20, 0.16);
}

.project-card img {
    height: 220px;
    width: 100%;
    object-fit: cover;
    transition: transform .38s ease;
}

.project-card:hover img {
    transform: scale(1.06);
}

.project-card > div {
    padding: 14px;
}

.project-card h3 {
    margin: 2px 0 8px;
}

.service-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.service-card {
    border-radius: var(--radius);
    background:
        radial-gradient(circle at 100% 0%, rgba(14, 111, 97, 0.12), transparent 44%),
        var(--surface);
    border: 1px solid rgba(31, 26, 20, 0.08);
    padding: 18px;
    transition: box-shadow .28s ease;
    transform-style: preserve-3d;
}

.service-card:hover {
    box-shadow: 0 16px 34px rgba(30, 22, 14, 0.14);
}

.service-icon {
    width: 42px;
    height: 42px;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--secondary), #2da38d);
    color: #fff;
    display: inline-grid;
    place-items: center;
    margin-bottom: 8px;
}

.service-card h3 {
    margin: 0 0 8px;
}

.service-card p {
    color: var(--muted);
}

.current-images {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 8px;
}

.current-images img {
    border-radius: 10px;
    height: 78px;
    width: 100%;
    object-fit: cover;
    border: 1px solid var(--line);
}

.upload-input-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    border: 0 !important;
}

.upload-dropzone {
    border: 1.5px dashed rgba(31, 26, 20, 0.24);
    border-radius: 14px;
    background: linear-gradient(160deg, rgba(255, 255, 255, 0.94), rgba(249, 245, 235, 0.92));
    padding: 16px;
    text-align: center;
    transition: border-color .2s ease, background-color .2s ease, transform .2s ease;
}

.upload-dropzone p {
    margin: 0 0 10px;
}

.upload-dropzone.is-dragover {
    border-color: var(--secondary);
    background: rgba(14, 111, 97, 0.06);
    transform: translateY(-1px);
}

.upload-preview-head {
    margin-top: 12px;
}

.upload-preview-grid {
    margin-top: 10px;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
}

.upload-preview-item {
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface);
    overflow: hidden;
}

.upload-preview-item img {
    width: 100%;
    height: 110px;
    object-fit: cover;
    display: block;
}

.upload-preview-meta {
    padding: 8px;
    display: grid;
    gap: 6px;
}

.upload-preview-name {
    font-size: 12px;
    line-height: 1.3;
    color: var(--muted);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.upload-preview-actions {
    display: flex;
    gap: 6px;
}

.upload-preview-actions button {
    flex: 1 1 auto;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-2);
    color: var(--text);
    font-size: 11px;
    font-weight: 700;
    padding: 5px 6px;
    cursor: pointer;
}

.upload-preview-actions button:hover {
    background: #fff;
}

.upload-preview-empty {
    border: 1px dashed var(--line);
    border-radius: 12px;
    padding: 14px;
    text-align: center;
    color: var(--muted);
    font-size: 13px;
    background: var(--surface-2);
}

.post-wizard-head {
    margin-bottom: 14px;
}

.post-wizard-steps {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
}

.post-wizard-step {
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface-2);
    color: var(--muted);
    min-height: 42px;
    padding: 8px 10px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: border-color .2s ease, background-color .2s ease, color .2s ease;
}

.post-wizard-step.is-active {
    border-color: rgba(188, 111, 49, 0.46);
    background: linear-gradient(145deg, rgba(188, 111, 49, 0.16), rgba(223, 190, 117, 0.2));
    color: var(--primary-dark);
}

.post-wizard-step.is-done {
    border-color: rgba(14, 111, 97, 0.4);
    color: var(--secondary-dark);
}

.post-wizard-controls {
    margin-top: 14px;
    margin-bottom: 8px;
    display: flex;
    justify-content: space-between;
    gap: 8px;
}

.empty-state,
.empty-note {
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px dashed rgba(31, 26, 20, 0.2);
    padding: 22px;
    text-align: center;
    color: var(--muted);
}

.alert {
    margin-top: 14px;
    border-radius: 12px;
    padding: 10px 14px;
    font-weight: 600;
}

.alert-success {
    background: rgba(15, 99, 86, .12);
    border: 1px solid rgba(15, 99, 86, .3);
    color: var(--secondary-dark);
}

.alert-error {
    background: rgba(164, 60, 53, .12);
    border: 1px solid rgba(164, 60, 53, .36);
    color: #7b2923;
}

.site-footer {
    margin-top: 54px;
    background: linear-gradient(180deg, rgba(249, 244, 232, 0.98), rgba(241, 233, 217, 0.96));
    color: var(--muted);
    padding: 44px 0 14px;
    border-top: 1px solid rgba(31, 26, 20, 0.1);
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 20px;
}

.footer-grid h3,
.footer-grid h4 {
    margin: 0 0 10px;
    color: var(--secondary-dark);
}

.footer-grid a,
.footer-grid p {
    display: block;
    margin: 0 0 7px;
    color: var(--muted);
}

.footer-grid a {
    text-decoration: none;
    transition: color .2s ease, transform .2s ease;
}

.footer-grid a:hover {
    color: var(--secondary);
    transform: translateX(2px);
}

.copyright {
    margin-top: 20px;
    padding-top: 10px;
    border-top: 1px solid rgba(31, 26, 20, 0.1);
}

.reveal {
    opacity: 0;
    transform: translateY(18px) scale(.985);
    transition: opacity .66s ease, transform .66s cubic-bezier(.2, .62, .2, 1);
}

.reveal.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-14px);
    }
}

@keyframes meshShift {
    0% {
        transform: translate3d(0, 0, 0) scale(1);
    }
    50% {
        transform: translate3d(-12px, 8px, 0) scale(1.03);
    }
    100% {
        transform: translate3d(10px, -10px, 0) scale(1.01);
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
    }
}

@media (max-width: 1120px) {
    .hero-grid {
        grid-template-columns: 1fr;
    }

    .listing-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .listing-grid--list {
        grid-template-columns: 1fr;
    }

    .listing-grid--list .listing-card {
        grid-template-columns: 1fr;
    }

    .listing-grid--list .listing-image-wrap {
        min-height: 180px;
    }

    .category-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .layout-listings {
        grid-template-columns: 280px 1fr;
    }

    .detail-layout {
        grid-template-columns: 1fr;
    }

    .detail-sidebar {
        order: -1;
    }

    .stats-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .admin-shell,
    .admin-grid-two {
        grid-template-columns: 1fr;
    }

    .admin-sidebar {
        position: static;
    }

    .service-grid,
    .project-grid,
    .agency-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .footer-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .nav-wrap {
        grid-template-columns: 1fr auto auto;
        gap: 10px;
        min-height: 74px;
    }

    .menu-toggle {
        display: block;
        justify-self: center;
    }

    .main-nav {
        position: absolute;
        left: 4%;
        right: 4%;
        top: 76px;
        background: var(--surface);
        border: 1px solid var(--line);
        border-radius: 14px;
        box-shadow: var(--shadow-soft);
        flex-direction: column;
        padding: 12px;
        display: none;
    }

    .brand strong {
        font-size: 21px;
    }

    .brand small {
        display: none;
    }

    .main-nav.open {
        display: flex;
    }

    .header-actions {
        justify-self: end;
        flex-wrap: wrap;
        justify-content: flex-end;
        gap: 6px;
    }

    .header-actions .btn {
        padding: 8px 10px;
        font-size: 12px;
        line-height: 1.15;
    }

    .layout-listings {
        grid-template-columns: 1fr;
    }

    .filters-panel {
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        top: auto;
        z-index: 101;
        max-height: 82vh;
        border-radius: 18px 18px 0 0;
        transform: translateY(102%);
        transition: transform .28s ease;
        padding-bottom: calc(28px + env(safe-area-inset-bottom, 0px));
        overscroll-behavior: contain;
        touch-action: pan-y;
    }

    .filters-panel[data-open="1"] {
        transform: translateY(0);
    }

    .filters-panel.is-dragging {
        transition: none;
    }

    .filters-panel-head {
        position: sticky;
        top: 0;
        z-index: 2;
        display: flex;
        justify-content: space-between;
        align-items: center;
        background: rgba(255, 255, 255, 0.96);
        border-bottom: 1px solid rgba(31, 26, 20, 0.08);
        margin: -16px -16px 12px;
        padding: 12px 16px;
    }

    .filters-panel-head::before {
        content: "";
        position: absolute;
        top: 6px;
        left: 50%;
        transform: translateX(-50%);
        width: 44px;
        height: 4px;
        border-radius: 999px;
        background: rgba(31, 26, 20, 0.22);
    }

    .filters-panel-head h3 {
        margin: 0;
        font: 700 24px/1 "Cormorant Garamond", serif;
    }

    .filters-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        z-index: 100;
        background: rgba(17, 14, 10, 0.46);
        opacity: 0;
        pointer-events: none;
        transition: opacity .2s ease;
    }

    .filters-backdrop[hidden] {
        display: none !important;
    }

    .filters-backdrop.is-open {
        opacity: 1;
        pointer-events: auto;
    }

    .mobile-filters-trigger {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    body.filters-open {
        overflow: hidden;
    }
}

@media (max-width: 700px) {
    .section {
        padding: 54px 0;
    }

    .section-compact {
        padding: 40px 0;
    }

    .section-head {
        flex-direction: column;
        align-items: flex-start;
    }

    .table-tools {
        flex-direction: column;
        align-items: stretch;
    }

    .section-head h2 {
        font-size: 34px;
    }

    .hero-content h1 {
        font-size: clamp(28px, 8vw, 36px);
        line-height: 1.04;
    }

    .hero {
        padding: 24px 0 18px;
    }

    .hero-search {
        padding: 12px;
        border-radius: 16px;
    }

    .hero-search h2 {
        font-size: 24px;
        margin-bottom: 8px;
    }

    .hero-search .form-grid .field > label {
        min-height: 0;
    }

    .hero-text,
    .hero-stats {
        display: none;
    }

    .hero-search .form-grid {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    /* Keep homepage quick search short on mobile; advanced filters stay in listings page. */
    .hero-search .form-grid .field:nth-child(n+5) {
        display: none;
    }

    .hero-search .field {
        margin-bottom: 8px;
    }

    .hero-orb {
        display: none;
    }

    .form-grid,
    .field-row,
    .field-row.field-row-3,
    .listing-grid,
    .category-grid,
    .service-grid,
    .project-grid,
    .agency-grid,
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .current-images {
        grid-template-columns: repeat(auto-fill, minmax(92px, 1fr));
    }

    .upload-preview-grid {
        grid-template-columns: repeat(auto-fill, minmax(92px, 1fr));
    }

    .thumb-btn {
        width: 92px;
        flex: 0 0 92px;
    }

    .detail-header {
        flex-direction: column;
    }

    .profile-avatar-row {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .profile-avatar-preview {
        width: 84px;
        height: 84px;
    }

    .detail-header h1 {
        font-size: 34px;
        line-height: 1.05;
    }

    .detail-price-box {
        text-align: left;
    }

    .detail-price-box strong {
        font-size: 30px;
    }

    .detail-card {
        padding: 14px;
    }

    .detail-map {
        height: 260px;
    }

    .detail-map-frame {
        height: 260px;
    }

    .feature-grid {
        grid-template-columns: 1fr;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .compact-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .auth-section {
        padding: 46px 0;
    }

    .auth-card {
        padding: 18px;
        border-radius: 20px;
    }

    .auth-card h1 {
        font-size: 34px;
    }

    input,
    select,
    textarea {
        font-size: 16px;
    }

    .hero-auth-cta {
        flex-direction: column;
    }

    .search-actions-inline {
        flex-direction: column;
        gap: 6px;
    }

    .home-tabs {
        width: 100%;
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .home-tab-btn {
        width: 100%;
    }

    .search-tabs-header {
        grid-template-columns: 1fr;
    }

    .search-tab-btn {
        text-align: left;
    }

    .input-row.input-row-price {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .input-row.input-row-price .currency-select {
        grid-column: 1 / -1;
    }

    .filter-checks {
        flex-direction: column;
        gap: 8px;
    }

.search-actions {
    flex-direction: column;
}
}

.cookie-consent {
    position: fixed;
    left: 16px;
    right: 16px;
    bottom: 16px;
    z-index: 120;
}

.cookie-consent[hidden] {
    display: none !important;
}

.cookie-consent__inner {
    margin: 0 auto;
    width: min(860px, 100%);
    background: rgba(26, 21, 16, 0.94);
    color: #f8f5ee;
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 14px;
    padding: 14px 16px;
    box-shadow: 0 14px 36px rgba(0, 0, 0, 0.28);
    backdrop-filter: blur(8px);
}

.cookie-consent__title {
    margin: 0 0 6px;
    font-size: 15px;
    font-weight: 800;
}

.cookie-consent__text {
    margin: 0;
    font-size: 13px;
    line-height: 1.5;
    color: rgba(248, 245, 238, 0.88);
}

.cookie-consent__text a {
    color: #fff;
    text-decoration: underline;
}

.cookie-consent__actions {
    margin-top: 12px;
    display: flex;
    gap: 8px;
    justify-content: flex-end;
}

.cookie-settings-link {
    border: 0;
    background: transparent;
    color: var(--muted);
    font-size: 12px;
    font-weight: 700;
    text-decoration: underline;
    cursor: pointer;
    padding: 0;
}

.cookie-settings-link:hover {
    color: var(--text);
}

@media (max-width: 700px) {
    .cookie-consent__actions {
        flex-direction: column;
    }

    .cookie-consent__actions .btn {
        width: 100%;
    }
}

@media (max-width: 560px) {
    .container {
        width: min(1200px, 95%);
    }

    .nav-wrap {
        grid-template-columns: auto auto auto;
        gap: 8px;
        min-height: 68px;
    }

    .brand {
        gap: 8px;
    }

    .brand strong,
    .brand small {
        display: none;
    }

    .header-actions .btn {
        max-width: none;
        white-space: nowrap;
        text-align: center;
        font-size: 11px;
        padding: 7px 9px;
    }

    .main-nav {
        top: 68px;
    }

    .section-head h2 {
        font-size: 30px;
    }

    .listings-toolbar {
        width: 100%;
        justify-content: space-between;
        flex-wrap: wrap;
        gap: 8px;
    }

    .toolbar-sort-form {
        width: 100%;
        border-radius: 14px;
        justify-content: space-between;
    }

    .toolbar-sort-form select {
        min-width: 0;
        flex: 1 1 auto;
    }

    .listing-image-wrap {
        height: 180px;
    }

    .detail-map {
        height: 220px;
    }

    .detail-map-frame {
        height: 220px;
    }

    .home-tabs {
        grid-template-columns: 1fr;
        border-radius: 14px;
    }

    .post-wizard-steps {
        grid-template-columns: 1fr;
    }

    .input-row.input-row-two,
    .input-row.input-row-price {
        grid-template-columns: 1fr;
    }

    .input-row.input-row-price .currency-select {
        grid-column: auto;
    }
}
