:root {
    --primary: #0d624e;
    --primary-dark: #0a4c3d;
    --primary-soft: #e6f0ed;
    --accent: #f26b38;
    --accent-dark: #d95628;
    --ink: #1b2422;
    --muted: #667873;
    --line: #dfe7e4;
    --line-dark: #c7d3cf;
    --surface: #ffffff;
    --surface-soft: #f5f7f7;
    --surface-green: #f0f6f4;
    --danger: #bb3344;
    --success: #167a5c;
    --warning: #a66b13;
    --shadow-sm: 0 3px 10px rgba(18, 50, 43, .08);
    --shadow-md: 0 12px 34px rgba(20, 49, 43, .13);
    --radius-sm: 8px;
    --radius: 12px;
    --radius-lg: 18px;
    --font: Hind, Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font-family: var(--font); color: var(--ink); background: var(--surface); line-height: 1.45; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
img { max-width: 100%; display: block; }
.layout { width: min(1220px, calc(100% - 32px)); margin-inline: auto; }
.muted { color: var(--muted); }
.hide-mobile { display: inline-flex; }

.btn { min-height: 40px; border: 1px solid transparent; border-radius: var(--radius-sm); padding: 0 18px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; font-weight: 600; transition: .18s ease; background: transparent; }
.btn:hover { transform: translateY(-1px); }
.btn-primary { color: #fff; background: var(--accent); box-shadow: 0 4px 12px rgba(242, 107, 56, .25); }
.btn-primary:hover { background: var(--accent-dark); }
.btn-secondary { color: #fff; background: var(--primary); }
.btn-secondary:hover { background: var(--primary-dark); }
.btn-ghost { color: var(--primary); background: #fff; border-color: var(--line-dark); }
.btn-ghost:hover { border-color: var(--primary); background: var(--primary-soft); }
.btn-link { padding-inline: 8px; color: var(--ink); }
.btn-link:hover { color: var(--primary); transform: none; }
.btn-light { background: #fff; color: var(--primary); box-shadow: var(--shadow-sm); }
.btn-full { width: 100%; }
.btn-large { min-height: 48px; }

.eyebrow { display: block; margin-bottom: 6px; color: var(--primary); font-size: 13px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; }
.eyebrow.light { color: #b8e1d5; }

.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.98); border-bottom: 1px solid var(--line); backdrop-filter: blur(14px); }
.header-inner { min-height: 92px; display: flex; align-items: center; gap: 28px; }
.brand { display: inline-flex; align-items: center; gap: 9px; color: var(--primary); font-weight: 800; letter-spacing: -.02em; }
.brand img { flex: 0 0 auto; }
.brand-icon { width: 34px; height: 34px; aspect-ratio: 1 / 1; object-fit: contain; object-position: center; display: block; }
.brand span { font-size: 19px; }
.desktop-nav { display: flex; align-items: center; gap: 8px; }
.desktop-nav a { padding: 10px 12px; border-radius: var(--radius-sm); font-weight: 500; }
.desktop-nav a:hover { background: var(--surface-soft); color: var(--primary); }
.header-actions { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.header-inline-form { margin: 0; }
.mobile-menu-button { display: none; border: 0; background: transparent; font-size: 24px; padding: 7px 9px; }
.mobile-menu { border-top: 1px solid var(--line); background: #fff; padding: 8px 16px 16px; }
.mobile-menu a { display: block; padding: 12px 8px; border-bottom: 1px solid var(--surface-soft); font-weight: 600; }

.flash { margin-top: 14px; margin-bottom: 0; padding: 12px 16px; border-radius: var(--radius-sm); border: 1px solid; font-size: 14px; }
.flash-success { background: #eff9f5; color: #125b47; border-color: #b9dfd2; }
.flash-error { background: #fff1f2; color: #8f2634; border-color: #f0b9c0; }

.hero { min-height: 500px; position: relative; overflow: hidden; background: #365e55; }
.hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-overlay { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(14, 40, 34, .76), rgba(14, 40, 34, .24) 58%, rgba(14, 40, 34, .16)); }
.hero-content { position: relative; z-index: 2; padding-top: 82px; }
.hero h1 { width: min(760px, 100%); color: #fff; font-size: clamp(38px, 5vw, 58px); line-height: 1.04; letter-spacing: -.035em; margin: 0 0 16px; text-shadow: 0 2px 10px rgba(0,0,0,.2); }
.hero-content > p { width: min(640px, 100%); color: rgba(255,255,255,.92); font-size: 19px; margin: 0 0 26px; }
.hero-search { width: min(980px, 100%); background: #fff; border-radius: 16px; box-shadow: var(--shadow-md); overflow: hidden; }
.operation-tabs { display: flex; padding: 0 18px; border-bottom: 1px solid var(--line); }
.operation-tab { min-width: 120px; border: 0; background: #fff; padding: 16px 18px 14px; color: var(--muted); font-weight: 600; border-bottom: 3px solid transparent; }
.operation-tab.active { color: var(--primary); border-bottom-color: var(--primary); }
.search-row { display: grid; grid-template-columns: 210px 1fr 128px; gap: 0; padding: 14px; }
.search-field { min-width: 0; padding: 0 16px; border-right: 1px solid var(--line); }
.search-field span { display: block; color: var(--muted); font-size: 12px; margin-bottom: 3px; }
.search-field select, .search-field input { width: 100%; min-height: 36px; border: 0; outline: 0; color: var(--ink); background: transparent; font-size: 15px; }
.search-submit { margin-left: 12px; min-height: 52px; align-self: center; }

.section-space { padding-top: 54px; padding-bottom: 54px; }
.soft-section { background: var(--surface-soft); }
.section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; margin-bottom: 22px; }
.section-heading.simple { align-items: center; }
.section-heading h2 { margin: 0; font-size: 28px; line-height: 1.16; letter-spacing: -.02em; }
.section-heading > a { color: var(--primary); font-weight: 700; }
.section-heading > a:hover { text-decoration: underline; }
.district-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 18px; }
.district-card { position: relative; min-height: 178px; border-radius: var(--radius-lg); overflow: hidden; border: 1px solid var(--line); background: #ddd; }
.district-card:last-child { grid-column: 2 / span 2; min-height: 145px; }
.district-card img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s ease; }
.district-card::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 35%, rgba(8,34,28,.75)); }
.district-card span { position: absolute; z-index: 2; left: 18px; bottom: 16px; color: #fff; font-size: 20px; font-weight: 700; }
.district-card:hover img { transform: scale(1.035); }
.district-wide { grid-row: span 2; min-height: 341px; }

.property-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 22px; }
.property-card { overflow: hidden; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease; }
.property-card:hover { border-color: #a8bbb5; box-shadow: 0 9px 26px rgba(30, 70, 60, .13); transform: translateY(-2px); }
.property-image-wrap { position: relative; display: block; height: 205px; overflow: hidden; background: #e8eeec; }
.property-image { width: 100%; height: 100%; object-fit: cover; transition: transform .25s ease; }
.property-card:hover .property-image { transform: scale(1.025); }
.badge { position: absolute; left: 12px; top: 12px; padding: 6px 9px; border-radius: 999px; font-size: 12px; font-weight: 700; }
.badge-featured { background: #fff5dd; color: #84550b; }
.favorite-icon { position: absolute; right: 12px; top: 12px; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; background: rgba(255,255,255,.94); box-shadow: var(--shadow-sm); font-size: 22px; color: var(--ink); }
.property-body { padding: 15px 16px 17px; }
.property-kicker { color: var(--muted); font-size: 13px; font-weight: 600; }
.property-title { display: block; margin: 7px 0 8px; min-height: 45px; font-size: 18px; line-height: 1.25; font-weight: 700; }
.property-title:hover { color: var(--primary); }
.property-price { font-size: 23px; font-weight: 800; margin-bottom: 5px; }
.property-location { color: var(--muted); font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.property-features { display: flex; gap: 13px; padding-top: 13px; margin-top: 13px; border-top: 1px solid var(--line); color: #45544f; font-size: 13px; }

.value-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 18px; }
.value-card { display: flex; gap: 14px; min-height: 126px; padding: 20px; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); background: #fff; }
.value-icon { width: 54px; height: 54px; flex: 0 0 54px; display: grid; place-items: center; border-radius: 50%; color: var(--primary); background: var(--primary-soft); font-size: 28px; }
.value-card h3 { margin: 1px 0 5px; font-size: 18px; }
.value-card p { margin: 0; color: var(--muted); font-size: 14px; }
.cta-band { background: var(--primary); color: #fff; }
.cta-inner { min-height: 220px; display: flex; align-items: center; justify-content: space-between; gap: 28px; }
.cta-inner h2 { max-width: 720px; margin: 0; font-size: 32px; }
.cta-inner p { margin-bottom: 0; color: #d8eae5; }

.site-footer { background: #13211e; color: #d9e2df; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 36px; padding-top: 44px; padding-bottom: 38px; }
.brand-footer { color: #fff; margin-bottom: 12px; }
.footer-grid p { max-width: 340px; color: #9eaaa6; }
.footer-grid > div:not(:first-child) { display: flex; flex-direction: column; gap: 9px; }
.footer-grid strong { color: #fff; margin-bottom: 4px; }
.footer-grid a:hover { color: #fff; text-decoration: underline; }
.footer-grid span { color: #9eaaa6; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); padding: 16px 0; color: #8e9b97; font-size: 13px; }

.results-page { background: var(--surface-soft); min-height: 70vh; }
.results-search-bar { background: #fff; border-bottom: 1px solid var(--line); padding: 16px 0; }
.filter-bar { display: grid; grid-template-columns: 160px 190px 1fr 140px 110px; gap: 10px; }
.filter-bar select, .filter-bar input, .filters-panel input, .filters-panel select { width: 100%; min-height: 44px; border: 1px solid var(--line-dark); border-radius: var(--radius-sm); padding: 0 12px; background: #fff; outline: 0; }
.filter-bar select:focus, .filter-bar input:focus, .filters-panel input:focus, .filters-panel select:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(13,98,78,.08); }
.results-layout { display: grid; grid-template-columns: 245px 1fr; gap: 28px; padding-top: 30px; padding-bottom: 60px; }
.filters-panel { align-self: start; position: sticky; top: 94px; padding: 20px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); }
.filters-panel h3 { margin-top: 0; }
.filters-panel form { display: flex; flex-direction: column; gap: 14px; }
.filters-panel label { display: flex; flex-direction: column; gap: 6px; color: var(--muted); font-size: 13px; font-weight: 600; }
.results-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 18px; }
.results-heading h1 { margin: 0; font-size: 27px; }
.view-switch { padding: 4px; background: #fff; border: 1px solid var(--line); border-radius: 10px; display: flex; }
.view-switch button { border: 0; background: transparent; border-radius: 7px; padding: 7px 12px; color: var(--muted); }
.view-switch .active { background: var(--primary-soft); color: var(--primary); font-weight: 700; }
.results-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
.empty-state { min-height: 320px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 40px; border: 1px dashed var(--line-dark); border-radius: var(--radius); background: #fff; }
.empty-state.compact { min-height: 220px; }
.empty-icon { width: 64px; height: 64px; display: grid; place-items: center; border-radius: 50%; background: var(--primary-soft); color: var(--primary); font-size: 30px; }
.empty-state h2 { margin: 14px 0 5px; }
.empty-state p { margin: 0 0 18px; color: var(--muted); }

.breadcrumbs { display: flex; align-items: center; gap: 8px; padding-top: 22px; padding-bottom: 18px; color: var(--muted); font-size: 13px; }
.breadcrumbs a:hover { color: var(--primary); }
.detail-page { background: var(--surface-soft); padding-bottom: 60px; }
.detail-hero-grid { display: grid; grid-template-columns: 1.55fr .85fr; gap: 22px; }
.detail-gallery { min-height: 450px; border-radius: var(--radius-lg); overflow: hidden; background: #dbe5e1; }
.detail-gallery img { width: 100%; height: 100%; min-height: 450px; object-fit: cover; }
.detail-summary { padding: 28px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); }
.detail-summary h1 { margin: 8px 0 12px; font-size: 31px; line-height: 1.16; }
.detail-price { font-size: 34px; font-weight: 800; }
.detail-location { margin: 20px 0; padding-top: 18px; border-top: 1px solid var(--line); color: #40524c; }
.detail-feature-strip { display: grid; grid-template-columns: repeat(2,1fr); gap: 9px; }
.detail-feature-strip div { padding: 13px; border-radius: 10px; background: var(--surface-soft); }
.detail-feature-strip strong { display: block; font-size: 20px; }
.detail-feature-strip span { display: block; color: var(--muted); font-size: 12px; }
.favorite-form { margin-top: 16px; }
.detail-content-grid { display: grid; grid-template-columns: 1fr 360px; gap: 22px; padding-top: 22px; }
.detail-main { display: flex; flex-direction: column; gap: 22px; }
.content-card, .contact-card { padding: 26px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.content-card h2, .contact-card h3 { margin-top: 0; }
.property-description { color: #384742; white-space: pre-line; }
.contact-card { align-self: start; position: sticky; top: 92px; }
.contact-card hr { border: 0; border-top: 1px solid var(--line); margin: 20px 0; }
.map-placeholder { min-height: 230px; display: flex; flex-direction: column; align-items: center; justify-content: center; border-radius: var(--radius); background: linear-gradient(135deg,#edf3f1,#dce9e5); color: var(--muted); }
.map-pin { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 50%; background: #fff; color: var(--primary); box-shadow: var(--shadow-sm); font-size: 22px; margin-bottom: 10px; }
.map-placeholder strong { color: var(--ink); }
.map-placeholder small { margin-top: 8px; }

.stack-form { display: flex; flex-direction: column; gap: 13px; }
.stack-form label, .form-grid label, .form-section-body > label { display: flex; flex-direction: column; gap: 6px; color: #40504b; font-size: 13px; font-weight: 600; }
.stack-form input, .stack-form select, .stack-form textarea, .form-grid input, .form-grid select, .form-section-body > label input, .form-section-body > label textarea { width: 100%; min-height: 44px; border: 1px solid var(--line-dark); border-radius: var(--radius-sm); padding: 10px 12px; color: var(--ink); background: #fff; outline: none; }
.stack-form textarea, .form-section-body > label textarea { resize: vertical; }
.stack-form input:focus, .stack-form select:focus, .stack-form textarea:focus, .form-grid input:focus, .form-grid select:focus, .form-section-body input:focus, .form-section-body textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(13,98,78,.08); }
.stack-form small { color: var(--muted); }
.form-grid { display: grid; gap: 14px; }
.form-grid.two { grid-template-columns: repeat(2,minmax(0,1fr)); }
.form-grid.three { grid-template-columns: repeat(3,minmax(0,1fr)); }
.form-error { padding: 12px 14px; margin-bottom: 14px; color: #8f2634; background: #fff1f2; border: 1px solid #f0b9c0; border-radius: var(--radius-sm); }

.auth-page { min-height: calc(100vh - 68px); background: var(--surface-soft); padding: 44px 16px 70px; }
.auth-shell { width: min(1040px,100%); margin: 0 auto; display: grid; grid-template-columns: 1.05fr .95fr; background: #fff; border-radius: 20px; overflow: hidden; box-shadow: var(--shadow-md); border: 1px solid var(--line); }
.auth-shell.single { display: block; width: min(760px,100%); }
.auth-visual { position: relative; min-height: 620px; background: var(--primary); color: #fff; overflow: hidden; }
.auth-visual img { width: 100%; height: 100%; object-fit: cover; opacity: .86; }
.auth-visual::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 35%, rgba(8,49,39,.88)); }
.auth-visual > div { position: absolute; z-index: 2; left: 34px; right: 34px; bottom: 36px; }
.auth-visual h1 { margin: 0; font-size: 32px; line-height: 1.12; }
.auth-card { padding: 44px 42px; }
.auth-card.wide { padding: 42px 54px; }
.auth-card h1 { margin: 7px 0 8px; font-size: 30px; }
.auth-card > p { color: var(--muted); margin-top: 0; }
.auth-back { display: inline-block; color: var(--muted); margin-bottom: 28px; }
.auth-divider { position: relative; text-align: center; margin: 20px 0; color: var(--muted); font-size: 13px; }
.auth-divider::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; border-top: 1px solid var(--line); }
.auth-divider span { position: relative; background: #fff; padding: 0 10px; }
.demo-box { margin-top: 22px; padding: 13px 14px; display: flex; flex-direction: column; border-radius: var(--radius-sm); background: #fff8e8; border: 1px solid #efdba8; color: #6e571f; font-size: 12px; }
.account-type-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.choice-card { display: flex !important; flex-direction: row !important; align-items: flex-start; gap: 10px !important; border: 1px solid var(--line-dark); border-radius: var(--radius); padding: 14px; cursor: pointer; }
.choice-card input { width: auto !important; min-height: 0 !important; margin-top: 4px; }
.choice-card strong, .choice-card small { display: block; }
.choice-card small { color: var(--muted); margin-top: 2px; }
.auth-foot { text-align: center; margin-top: 18px !important; }
.auth-foot a { color: var(--primary); font-weight: 700; }

.dashboard-page { background: #f3f6f5; min-height: 100vh; }
.dashboard-shell { min-height: 100vh; display: grid; grid-template-columns: 248px minmax(0,1fr); }
.sidebar { position: sticky; top: 0; height: 100vh; padding: 18px 14px; display: flex; flex-direction: column; background: #fff; border-right: 1px solid var(--line); z-index: 40; }
.sidebar-brand { padding: 5px 8px 16px; border-bottom: 1px solid var(--line); }
.sidebar-context { padding: 17px 11px 10px; color: var(--muted); text-transform: uppercase; letter-spacing: .07em; font-size: 11px; font-weight: 700; }
.sidebar-nav { display: flex; flex-direction: column; gap: 4px; }
.sidebar-nav a { display: flex; align-items: center; gap: 11px; padding: 11px 12px; border-radius: 9px; color: #475752; font-weight: 600; font-size: 14px; }
.sidebar-nav a span { width: 22px; text-align: center; font-size: 18px; }
.sidebar-nav a:hover { color: var(--primary); background: var(--surface-soft); }
.sidebar-nav a.active { color: var(--primary); background: var(--primary-soft); }
.sidebar-bottom { margin-top: auto; padding: 12px 10px 2px; border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 7px; color: var(--muted); font-size: 12px; }
.dashboard-main-wrap { min-width: 0; }
.dashboard-topbar { height: 70px; padding: 0 28px; display: flex; align-items: center; background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 30; }
.sidebar-toggle { display: none; border: 0; background: transparent; font-size: 22px; }
.topbar-spacer { flex: 1; }
.user-menu { display: flex; align-items: center; gap: 10px; }
.user-menu > div:nth-child(2) { display: flex; flex-direction: column; }
.user-menu strong { font-size: 13px; }
.user-menu span { color: var(--muted); font-size: 11px; }
.avatar, .activity-avatar { width: 34px; height: 34px; flex: 0 0 34px; display: grid; place-items: center; border-radius: 50%; background: var(--primary-soft); color: var(--primary); font-weight: 800; }
.dashboard-main-wrap > .flash { margin: 14px 28px 0; }
.dashboard-content { padding: 30px 30px 58px; }
.dashboard-heading { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin-bottom: 24px; }
.dashboard-heading h1 { margin: 2px 0 5px; font-size: 30px; letter-spacing: -.025em; }
.dashboard-heading p { margin: 0; color: var(--muted); }
.stats-grid { display: grid; gap: 14px; margin-bottom: 22px; }
.stats-grid.three { grid-template-columns: repeat(3,minmax(0,1fr)); }
.stats-grid.five { grid-template-columns: repeat(5,minmax(0,1fr)); }
.stat-card { min-height: 126px; padding: 19px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 2px 8px rgba(38,68,61,.035); }
.stat-card > span { display: block; color: var(--muted); font-size: 13px; font-weight: 600; }
.stat-card strong { display: block; margin: 6px 0 3px; font-size: 30px; line-height: 1; }
.stat-card .status-word { font-size: 22px; color: var(--success); padding-top: 5px; }
.stat-card small { color: #83918d; }
.dashboard-grid { display: grid; gap: 18px; }
.dashboard-grid.two-one { grid-template-columns: minmax(0,1.7fr) minmax(300px,.8fr); }
.panel-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 2px 8px rgba(38,68,61,.035); }
.panel-heading { padding: 18px 20px 15px; display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; border-bottom: 1px solid var(--line); }
.panel-heading h2 { margin: 0 0 2px; font-size: 18px; }
.panel-heading p { margin: 0; color: var(--muted); font-size: 13px; }
.panel-heading a { color: var(--primary); font-weight: 700; font-size: 13px; }
.table-wrap { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.data-table th { text-align: left; color: #74827e; font-size: 11px; letter-spacing: .04em; text-transform: uppercase; background: #fafbfb; }
.data-table th, .data-table td { padding: 13px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.data-table tr:last-child td { border-bottom: 0; }
.data-table td strong, .data-table td span { display: block; }
.data-table td span { color: var(--muted); font-size: 12px; margin-top: 2px; }
.data-table td a:hover strong { color: var(--primary); }
.status-pill { display: inline-flex !important; width: fit-content; padding: 5px 8px; border-radius: 999px; font-size: 10px !important; font-weight: 800; text-transform: uppercase; letter-spacing: .02em; background: #edf1f0; color: #52625d !important; white-space: nowrap; }
.status-PUBLISHED, .status-ACTIVE, .status-CONTACTED { background: #e9f6f1; color: #14664f !important; }
.status-PENDING_REVIEW, .status-NEW { background: #fff5df; color: #8b5c12 !important; }
.status-REJECTED { background: #fff0f2; color: #a62e40 !important; }
.status-PAUSED { background: #eef0f2; color: #56626a !important; }
.activity-list { padding: 8px 18px 14px; }
.activity-list article { display: flex; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.activity-list article:last-child { border-bottom: 0; }
.activity-list article > div:last-child { min-width: 0; display: flex; flex-direction: column; }
.activity-list strong { font-size: 13px; }
.activity-list span, .activity-list small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); font-size: 11px; }
.panel-card > .btn { margin: 0 18px 18px; width: calc(100% - 36px); }
.table-property { display: flex; align-items: center; gap: 10px; min-width: 270px; }
.table-property img { width: 58px; height: 44px; object-fit: cover; border-radius: 7px; background: #e8eeec; }
.table-property > div { min-width: 0; }
.table-link { color: var(--primary); font-weight: 700; }
.row-actions { display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.row-actions form { margin: 0; }
.tiny-button { border: 1px solid var(--line-dark); border-radius: 6px; padding: 5px 7px; background: #fff; color: #54635f; font-size: 11px; }
.tiny-button.approve { border-color: #96c7b8; color: #14664f; background: #f2faf7; }
.tiny-button.reject { border-color: #e3abb4; color: #9d2b3b; background: #fff5f6; }
.message-cell { max-width: 360px; }
.empty-inline { padding: 24px; color: var(--muted); text-align: center; }

.property-wizard { display: flex; flex-direction: column; gap: 14px; }
.form-section { display: grid; grid-template-columns: 52px 1fr; gap: 18px; padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.form-step { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 50%; background: var(--primary-soft); color: var(--primary); font-size: 18px; font-weight: 800; }
.form-section-body { min-width: 0; }
.form-section-body h2 { margin: 0 0 3px; font-size: 19px; }
.form-section-body > p { margin: 0 0 16px; color: var(--muted); font-size: 13px; }
.form-section-body > label + label, .form-section-body > label + .form-grid, .form-grid + .form-grid { margin-top: 14px; }
.form-note { display: block; margin-top: 10px; color: var(--muted); }
.form-actions { display: flex; justify-content: flex-end; gap: 10px; padding-top: 8px; }
.image-preview-box { margin-top: 12px; min-height: 180px; border: 1px dashed var(--line-dark); border-radius: var(--radius); display: grid; place-items: center; overflow: hidden; color: var(--muted); background: var(--surface-soft); }
.image-preview-box img { width: 100%; max-height: 300px; object-fit: cover; }

.mini-property-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; padding: 18px; }
.mini-property { display: flex; gap: 11px; border: 1px solid var(--line); border-radius: 10px; padding: 10px; }
.mini-property:hover { border-color: var(--primary); }
.mini-property img { width: 110px; height: 82px; object-fit: cover; border-radius: 8px; }
.mini-property div { display: flex; min-width: 0; flex-direction: column; justify-content: center; }
.mini-property strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini-property span { font-weight: 800; margin-top: 4px; }
.mini-property small { color: var(--muted); }
.dashboard-property-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
.settings-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 18px; }
.settings-list { margin: 0; padding: 8px 20px 16px; }
.settings-list div { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.settings-list div:last-child { border-bottom: 0; }
.settings-list dt { color: var(--muted); }
.settings-list dd { margin: 0; font-weight: 700; text-align: right; }
.settings-list code { font-size: 11px; color: var(--primary); }
.check-list { margin: 0; padding: 16px 26px 20px 42px; color: #39524a; }
.check-list li { padding: 5px 0; }
.muted-list { color: var(--muted); }
.error-page { min-height: 100vh; padding: 40px 16px; display: grid; place-items: center; background: var(--surface-soft); }
.error-page .empty-state { width: min(620px,100%); }

@media (max-width: 1100px) {
    .property-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .stats-grid.five { grid-template-columns: repeat(3,minmax(0,1fr)); }
    .dashboard-grid.two-one { grid-template-columns: 1fr; }
    .district-grid { grid-template-columns: 1.4fr 1fr; }
    .district-card:last-child { grid-column: auto; }
    .district-wide { grid-row: span 2; }
    .detail-hero-grid { grid-template-columns: 1.2fr .8fr; }
}

@media (max-width: 900px) {
    .desktop-nav { display: none; }
    .mobile-menu-button { display: block; }
    .hide-mobile { display: none !important; }
    .hero { min-height: 560px; }
    .hero-content { padding-top: 54px; }
    .hero h1 { max-width: 650px; }
    .search-row { grid-template-columns: 1fr 1.5fr; }
    .search-submit { grid-column: span 2; margin: 10px 0 0; }
    .search-field:nth-child(2) { border-right: 0; }
    .value-grid { grid-template-columns: 1fr; }
    .results-layout { grid-template-columns: 1fr; }
    .filters-panel { position: static; }
    .filter-bar { grid-template-columns: repeat(2,1fr); }
    .filter-bar input { grid-column: span 2; }
    .detail-hero-grid, .detail-content-grid { grid-template-columns: 1fr; }
    .detail-gallery, .detail-gallery img { min-height: 350px; }
    .contact-card { position: static; }
    .auth-shell { grid-template-columns: 1fr; }
    .auth-visual { min-height: 330px; }
    .dashboard-shell { grid-template-columns: 1fr; }
    .sidebar { position: fixed; left: 0; transform: translateX(-102%); width: 248px; box-shadow: var(--shadow-md); transition: transform .2s ease; }
    .sidebar.open { transform: translateX(0); }
    .sidebar-toggle { display: block; }
    .dashboard-content { padding: 24px 18px 48px; }
    .dashboard-topbar { padding: 0 18px; }
    .dashboard-main-wrap > .flash { margin-inline: 18px; }
    .dashboard-property-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}

@media (max-width: 700px) {
    .layout { width: min(100% - 24px, 1220px); }
    .header-inner { min-height: 70px; gap: 10px; }
    .brand span { font-size: 16px; }
    .header-actions { gap: 2px; }
    .hero { min-height: 610px; }
    .hero-content { padding-top: 44px; }
    .hero h1 { font-size: 38px; }
    .hero-content > p { font-size: 16px; }
    .operation-tabs { padding-inline: 8px; }
    .operation-tab { flex: 1; min-width: 0; padding-inline: 8px; }
    .search-row { grid-template-columns: 1fr; padding: 10px; }
    .search-field { border-right: 0; border-bottom: 1px solid var(--line); padding: 8px 10px; }
    .search-submit { grid-column: auto; width: 100%; }
    .section-space { padding-top: 38px; padding-bottom: 38px; }
    .section-heading { align-items: flex-start; flex-direction: column; }
    .section-heading h2 { font-size: 24px; }
    .district-grid { grid-template-columns: repeat(2,1fr); gap: 12px; }
    .district-card, .district-wide { min-height: 160px; grid-row: auto; }
    .district-wide { grid-column: span 2; min-height: 220px; }
    .district-card:last-child { grid-column: span 2; }
    .property-grid, .results-grid, .dashboard-property-grid { grid-template-columns: 1fr; }
    .property-image-wrap { height: 218px; }
    .cta-inner { padding: 38px 0; align-items: flex-start; flex-direction: column; }
    .cta-inner h2 { font-size: 27px; }
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 24px; }
    .footer-grid > div:first-child { grid-column: span 2; }
    .filter-bar { grid-template-columns: 1fr; }
    .filter-bar input { grid-column: auto; }
    .results-heading { align-items: flex-start; flex-direction: column; }
    .view-switch { display: none; }
    .detail-summary { padding: 22px 18px; }
    .detail-summary h1 { font-size: 27px; }
    .detail-price { font-size: 30px; }
    .content-card, .contact-card { padding: 20px 17px; }
    .auth-page { padding: 22px 10px 50px; }
    .auth-card, .auth-card.wide { padding: 30px 22px; }
    .auth-visual { display: none; }
    .account-type-grid, .form-grid.two, .form-grid.three { grid-template-columns: 1fr; }
    .dashboard-heading { align-items: flex-start; flex-direction: column; }
    .stats-grid.three, .stats-grid.five { grid-template-columns: 1fr 1fr; }
    .stat-card { min-height: 108px; }
    .user-menu > div:nth-child(2) { display: none; }
    .form-section { grid-template-columns: 1fr; gap: 10px; padding: 18px; }
    .form-step { width: 34px; height: 34px; }
    .mini-property-grid { grid-template-columns: 1fr; }
    .settings-grid { grid-template-columns: 1fr; }
}

@media (max-width: 460px) {
    .stats-grid.three, .stats-grid.five { grid-template-columns: 1fr; }
    .footer-grid { grid-template-columns: 1fr; }
    .footer-grid > div:first-child { grid-column: auto; }
    .district-grid { grid-template-columns: 1fr; }
    .district-wide, .district-card:last-child { grid-column: auto; }
    .detail-feature-strip { grid-template-columns: 1fr 1fr; }
    .user-menu .btn-link { padding-inline: 4px; }
}


/* v1_0_5 · Sistema y diagnóstico administrado */
.diagnostic-panel { margin-top: 18px; }
.diagnostic-panel-heading { align-items: flex-start; gap: 24px; }
.diagnostic-panel-heading form { flex: 0 0 auto; }
.diagnostic-note { margin: 0 20px 18px; padding: 14px 16px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: #f8fbfa; color: var(--muted); }
.diagnostic-note strong { color: var(--ink); }
.diagnostic-note p { margin: 6px 0 0; }
.diagnostic-note a { color: var(--primary); font-weight: 700; text-decoration: underline; }
.database-diagnostic-result { padding: 0 20px 20px; }
.diagnostic-summary { display: flex; align-items: flex-start; justify-content: space-between; gap: 28px; padding: 18px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: #fbfcfc; }
.diagnostic-summary h3 { margin: 2px 0 6px; font-size: 20px; }
.diagnostic-summary p { margin: 0; color: var(--muted); }
.diagnostic-ok { color: var(--primary); }
.diagnostic-warning { color: #9a5a00; }
.diagnostic-status-pair { min-width: 230px; display: grid; grid-template-columns: 1fr auto; gap: 8px 16px; padding: 10px 12px; border-radius: var(--radius-sm); background: #fff; border: 1px solid var(--line); }
.diagnostic-status-pair span { color: var(--muted); }
.diagnostic-details-grid { margin-top: 16px; }
.diagnostic-subcard { border: 1px solid var(--line); border-radius: var(--radius-sm); background: #fff; overflow: hidden; }
.diagnostic-subcard > h3 { margin: 0; padding: 14px 18px; border-bottom: 1px solid var(--line); font-size: 15px; }
.compact-settings-list { padding-bottom: 4px; }
.table-status-list { padding: 8px 18px 14px; }
.table-status-list > div { min-height: 42px; display: flex; align-items: center; justify-content: space-between; gap: 14px; border-bottom: 1px solid var(--line); }
.table-status-list > div:last-child { border-bottom: 0; }
.table-status-list code { color: var(--ink); font-size: 12px; }
@media (max-width: 767px) {
    .diagnostic-panel-heading, .diagnostic-summary { flex-direction: column; }
    .diagnostic-panel-heading form, .diagnostic-panel-heading .btn { width: 100%; }
    .diagnostic-status-pair { width: 100%; min-width: 0; }
}

/* v1_0_6 · UTF-8, contenido público administrable y publicación Super Admin */
.sidebar { overflow: hidden; }
.sidebar-nav { min-height: 0; overflow-y: auto; padding-right: 2px; }
.content-admin-note { display: flex; gap: 10px; align-items: flex-start; padding: 14px 16px; margin-bottom: 16px; border: 1px solid #cfe0db; border-radius: var(--radius-sm); background: #f4faf8; color: #385049; font-size: 13px; }
.content-admin-note strong { color: var(--primary); white-space: nowrap; }
.content-admin-form { display: flex; flex-direction: column; gap: 16px; }
.content-group { padding: 20px; }
.content-group .panel-heading { padding: 0 0 16px; border-bottom: 1px solid var(--line); margin-bottom: 16px; }
.content-fields-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.content-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.content-field > label { color: #40504b; font-size: 13px; font-weight: 700; }
.content-field input, .content-field textarea { width: 100%; border: 1px solid var(--line-dark); border-radius: var(--radius-sm); padding: 10px 12px; color: var(--ink); background: #fff; outline: none; font: inherit; }
.content-field textarea { resize: vertical; min-height: 84px; }
.content-field input:focus, .content-field textarea:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(13,98,78,.08); }
.content-field small { color: var(--muted); line-height: 1.35; }
.content-field-image { grid-column: span 2; }
.content-image-preview { display: flex; align-items: center; gap: 12px; margin-top: 4px; padding: 10px; border: 1px dashed var(--line-dark); border-radius: var(--radius-sm); background: var(--surface-soft); }
.content-image-preview img { width: 120px; height: 72px; object-fit: cover; border-radius: 8px; background: #fff; }
.content-image-preview span { color: var(--muted); font-size: 12px; }
.sticky-form-actions { position: sticky; bottom: 12px; z-index: 5; display: flex; justify-content: flex-end; padding: 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: rgba(255,255,255,.94); box-shadow: var(--shadow-md); backdrop-filter: blur(8px); }
.reset-content-form { margin-top: 14px; display: flex; justify-content: flex-end; }
@media (max-width: 767px) {
    .content-fields-grid { grid-template-columns: 1fr; }
    .content-field-image { grid-column: auto; }
    .content-admin-note { flex-direction: column; }
    .sticky-form-actions { justify-content: stretch; }
    .sticky-form-actions .btn { width: 100%; }
}

/* Carga y optimización automática de imágenes */
.media-uploader { display: grid; grid-template-columns: minmax(160px, 240px) 1fr; gap: 16px; align-items: stretch; padding: 14px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: #fbfcfc; }
.media-preview { min-height: 130px; border: 1px dashed var(--line-dark); border-radius: 10px; background: #eef3f1; overflow: hidden; display: flex; align-items: center; justify-content: center; }
.media-preview img { width: 100%; height: 100%; min-height: 130px; object-fit: cover; display: block; }
.media-preview img[hidden] { display: none; }
.media-uploader-body { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 8px; min-width: 0; }
.media-file-input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.media-file-button { display: inline-flex; align-items: center; justify-content: center; min-height: 40px; padding: 0 16px; border: 1px solid var(--primary); border-radius: 8px; background: #fff; color: var(--primary); font-size: 13px; font-weight: 700; cursor: pointer; transition: background-color .2s ease, color .2s ease; }
.media-file-button:hover { background: var(--light-primary, #eef6f3); }
.media-uploader small { color: var(--muted); line-height: 1.4; }
.media-status { width: 100%; padding: 9px 10px; border-radius: 8px; background: #f2f5f4; color: var(--muted); font-size: 12px; line-height: 1.4; }
.media-status-ok { background: #edf8f3; color: #176a4f; }
.media-status-error { background: #fff0f1; color: #9d2430; }
.property-media-uploader { margin-top: 10px; }
.media-preview-property { min-height: 180px; }
.media-preview-property img { min-height: 180px; }
@media (max-width: 700px) {
    .media-uploader { grid-template-columns: 1fr; }
    .media-preview { min-height: 180px; }
}

/* v1_0_8 · edición de publicaciones desde Super Admin */
.checkbox-field { display: flex; flex-direction: column; gap: 8px; color: #40504b; font-size: 13px; font-weight: 600; }
.checkbox-line { display: flex; align-items: center; gap: 9px; min-height: 44px; padding: 10px 12px; border: 1px solid var(--line-dark); border-radius: var(--radius-sm); background: #fff; font-weight: 500; }
.checkbox-line input[type=checkbox] { width: 18px; height: 18px; min-height: 0; flex: 0 0 auto; accent-color: var(--primary); }
.property-owner-note { margin-top: 14px; padding: 11px 13px; border-radius: var(--radius-sm); background: #f5f8f7; color: var(--muted); font-size: 13px; }
.row-actions .table-link + .table-link { margin-left: 2px; }

/* v1_0_9 · logo de marca: perfil cuadrado y presentación sin deformación */
.content-field-logo .media-uploader { grid-template-columns: 180px 1fr; }
.media-preview-logo { min-height: 160px; aspect-ratio: 1 / 1; background: #fff; }
.media-preview-logo img { width: 128px; height: 128px; min-height: 0; object-fit: contain; object-position: center; }
@media (max-width: 700px) {
    .content-field-logo .media-uploader { grid-template-columns: 1fr; }
    .media-preview-logo { min-height: 180px; aspect-ratio: auto; }
}

/* v1_0_11 · ficha enriquecida, modal de resultados, galería y secciones opcionales */
.property-gallery-uploader { margin-top: 10px; padding: 14px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: #fbfcfc; }
.property-gallery-list { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 10px; margin-bottom: 12px; }
.property-gallery-list:empty { display: none; }
.property-gallery-item { position: relative; aspect-ratio: 3/2; overflow: hidden; border-radius: 10px; border: 1px solid var(--line); background: #eef3f1; }
.property-gallery-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery-remove { position: absolute; top: 7px; right: 7px; width: 30px; height: 30px; border: 0; border-radius: 50%; background: rgba(20,31,28,.82); color: #fff; font-size: 20px; line-height: 1; cursor: pointer; }
.gallery-upload-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.gallery-upload-actions small { width: 100%; color: var(--muted); }
.gallery-upload-actions .media-status { margin-top: 2px; }
.optional-section { background: linear-gradient(180deg,#fff 0,#fbfcfc 100%); }
.optional-section-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; margin-bottom: 16px; }
.optional-section-heading h2 { margin-bottom: 5px; }
.optional-section-heading p { margin: 0; }
.section-toggle { display: inline-flex; align-items: center; gap: 8px; flex: 0 0 auto; padding: 9px 12px; border: 1px solid var(--line-dark); border-radius: 999px; background: #fff; font-size: 12px; font-weight: 800; color: var(--primary); cursor: pointer; }
.section-toggle input { width: 17px; height: 17px; min-height: 0; accent-color: var(--primary); }
.price-history-admin-preview { margin-top: 12px; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.price-history-admin-preview > div { display: flex; justify-content: space-between; gap: 20px; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.price-history-admin-preview > div:last-child { border-bottom: 0; }
.price-history-admin-preview span { color: var(--muted); }

.property-modal-open { overflow: hidden; }
.property-modal-overlay { position: fixed; inset: 0; z-index: 1200; display: none; background: rgba(17,27,24,.58); backdrop-filter: blur(2px); padding: 18px; }
.property-modal-overlay.open { display: flex; align-items: center; justify-content: center; }
.property-modal-panel { position: relative; width: min(1480px,100%); height: min(94vh,980px); overflow-y: auto; overscroll-behavior: contain; background: #fff; border-radius: 16px; box-shadow: 0 28px 80px rgba(0,0,0,.26); }
.property-modal-loading { position: fixed; z-index: 4; top: 50%; left: 50%; transform: translate(-50%,-50%); padding: 14px 18px; border-radius: 12px; background: #fff; color: var(--ink); font-weight: 800; box-shadow: var(--shadow-md); }
.property-modal-fragment { min-height: 100%; background: #fff; }
.property-modal-toolbar { position: sticky; top: 0; z-index: 20; min-height: 58px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 8px 18px; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.96); backdrop-filter: blur(10px); }
.property-modal-back, .property-modal-close, .detail-action-button { border: 0; background: transparent; color: var(--ink); font: inherit; font-weight: 800; cursor: pointer; }
.property-modal-back { padding: 8px 4px; color: var(--primary); }
.property-modal-close { width: 40px; height: 40px; border-radius: 50%; font-size: 26px; }
.property-modal-close:hover { background: #eef3f1; }
.property-modal-toolbar-actions { display: flex; align-items: center; gap: 8px; }
.detail-action-button { min-height: 38px; padding: 0 12px; border: 1px solid var(--line-dark); border-radius: 8px; background: #fff; }
.detail-action-button:hover { border-color: var(--primary); color: var(--primary); }

.property-detail-page-v111 { padding: 18px 0 56px; background: #f7f9f8; }
.detail-standalone-actions { margin-bottom: 10px; }
.detail-back-link { color: var(--primary); font-weight: 800; }
.property-detail-container-v111 { background: #fff; border-radius: 16px; box-shadow: var(--shadow-sm); overflow: visible; }
.property-detail-experience { background: #fff; }
.property-modal-fragment .property-detail-experience { border-radius: 0; box-shadow: none; }
.detail-section-nav { position: sticky; top: 0; z-index: 15; display: flex; gap: 8px; overflow-x: auto; padding: 10px 18px; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.96); backdrop-filter: blur(10px); }
.property-modal-fragment .detail-section-nav { top: 58px; }
.detail-section-nav a { flex: 0 0 auto; padding: 8px 11px; border-radius: 999px; color: #40504b; font-size: 13px; font-weight: 800; }
.detail-section-nav a:hover { background: #eef6f3; color: var(--primary); }

/* v1_0_15 · galería adaptativa en 8 espacios lógicos (4 columnas × 2 filas) */
.property-gallery-stage {
    position: relative;
    display: grid;
    grid-template-columns: repeat(4,minmax(0,1fr));
    grid-template-rows: repeat(2,minmax(0,1fr));
    width: 100%;
    aspect-ratio: 2.2 / 1;
    gap: 6px;
    background: #dbe3e0;
    border-radius: 16px;
    overflow: hidden;
}
.property-gallery-primary, .property-gallery-secondary button {
    position: relative;
    min-width: 0;
    min-height: 0;
    border: 0;
    padding: 0;
    background: #dce5e2;
    overflow: hidden;
    cursor: zoom-in;
}
.property-gallery-primary { grid-column: 1 / 3; grid-row: 1 / 3; }
.property-gallery-primary img, .property-gallery-secondary img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .25s ease; }
.property-gallery-primary:hover img, .property-gallery-secondary button:hover img { transform: scale(1.015); }
.property-gallery-secondary {
    grid-column: 3 / 5;
    grid-row: 1 / 3;
    display: grid;
    grid-template-columns: repeat(2,minmax(0,1fr));
    grid-template-rows: repeat(2,minmax(0,1fr));
    gap: 6px;
    min-width: 0;
    min-height: 0;
}
.property-gallery-secondary-item { width: 100%; height: 100%; }

/* 1 foto: ocupa los 8 espacios. */
.property-gallery-stage.gallery-count-1 .property-gallery-primary { grid-column: 1 / 5; grid-row: 1 / 3; }

/* 2 fotos: 4 espacios para cada una. */
.property-gallery-stage.gallery-count-2 .property-gallery-secondary > :only-child { grid-column: 1 / 3; grid-row: 1 / 3; }

/* 3 fotos: portada 4 espacios; cada secundaria ocupa 2 espacios. */
.property-gallery-stage.gallery-count-3 .property-gallery-secondary > :nth-child(1) { grid-column: 1 / 3; grid-row: 1; }
.property-gallery-stage.gallery-count-3 .property-gallery-secondary > :nth-child(2) { grid-column: 1 / 3; grid-row: 2; }

/* 4 fotos: portada 4 espacios; dos arriba y la tercera completa la fila inferior. */
.property-gallery-stage.gallery-count-4 .property-gallery-secondary > :nth-child(1) { grid-column: 1; grid-row: 1; }
.property-gallery-stage.gallery-count-4 .property-gallery-secondary > :nth-child(2) { grid-column: 2; grid-row: 1; }
.property-gallery-stage.gallery-count-4 .property-gallery-secondary > :nth-child(3) { grid-column: 1 / 3; grid-row: 2; }

/* 5 o más: composición 4+1+1+1+1 como la referencia. */
.property-gallery-stage.gallery-count-5 .property-gallery-secondary > :nth-child(1) { grid-column: 1; grid-row: 1; }
.property-gallery-stage.gallery-count-5 .property-gallery-secondary > :nth-child(2) { grid-column: 2; grid-row: 1; }
.property-gallery-stage.gallery-count-5 .property-gallery-secondary > :nth-child(3) { grid-column: 1; grid-row: 2; }
.property-gallery-stage.gallery-count-5 .property-gallery-secondary > :nth-child(4) { grid-column: 2; grid-row: 2; }

.property-gallery-status { position: absolute; top: 16px; left: 16px; padding: 7px 10px; border-radius: 999px; background: rgba(255,255,255,.93); color: var(--ink); font-size: 12px; font-weight: 900; box-shadow: 0 4px 14px rgba(0,0,0,.12); }
.gallery-see-all { position: absolute; right: 16px; bottom: 16px; z-index: 3; min-height: 40px; padding: 0 14px; border: 1px solid #1c2925; border-radius: 10px; background: rgba(255,255,255,.96); color: var(--ink); font-weight: 900; box-shadow: 0 4px 14px rgba(0,0,0,.12); cursor: pointer; }

.detail-layout-v111 { display: grid; grid-template-columns: minmax(0,1fr) 360px; gap: 32px; width: min(1180px,calc(100% - 36px)); margin: 0 auto; padding: 28px 0 48px; }
.detail-main-v111 { min-width: 0; display: flex; flex-direction: column; gap: 18px; }
.detail-property-summary { padding-bottom: 18px; border-bottom: 1px solid var(--line); }
.detail-summary-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; }
.detail-summary-head h1 { margin: 7px 0 6px; max-width: 760px; font-size: clamp(27px,3vw,38px); line-height: 1.12; }
.detail-price-v111 { margin-top: 5px; color: var(--ink); font-size: clamp(30px,3.4vw,42px); font-weight: 900; letter-spacing: -.04em; }
.detail-price-v111 small { margin-left: 5px; color: var(--muted); font-size: 14px; font-weight: 700; letter-spacing: 0; }
.detail-address { margin: 0; color: var(--muted); }
.detail-inline-actions { display: flex; gap: 8px; }
.detail-feature-strip-v111 { margin-top: 20px; grid-template-columns: repeat(5,minmax(0,1fr)); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.detail-feature-strip-v111 > div { min-width: 0; padding: 14px 12px; border-right: 1px solid var(--line); }
.detail-feature-strip-v111 > div:last-child { border-right: 0; }
.detail-feature-strip-v111 strong { font-size: 18px; }
.detail-feature-strip-v111 span { font-size: 11px; color: var(--muted); }
.detail-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.detail-tags span { padding: 7px 10px; border-radius: 999px; background: #eef6f3; color: #31574c; font-size: 12px; font-weight: 800; }
.detail-section-card { scroll-margin-top: 125px; padding: 24px; border: 1px solid var(--line); border-radius: 14px; background: #fff; }
.detail-section-card h2 { margin: 3px 0 16px; font-size: 24px; }
.detail-section-card h3 { margin: 0 0 8px; font-size: 15px; }
.property-description-v111, .advanced-facts-grid p, .neighborhood-description { white-space: pre-line; line-height: 1.72; color: #34463f; }
.basic-facts-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 10px; margin-top: 20px; }
.basic-facts-grid > div { padding: 12px; border-radius: 10px; background: #f5f8f7; }
.basic-facts-grid span { display: block; margin-bottom: 4px; color: var(--muted); font-size: 11px; }
.basic-facts-grid strong { font-size: 13px; }
.advanced-facts-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.advanced-facts-grid article { padding: 14px; border: 1px solid var(--line); border-radius: 10px; background: #fbfcfc; }
.advanced-facts-grid p { margin: 0; font-size: 13px; }
.detail-section-title { display: flex; justify-content: space-between; gap: 20px; align-items: flex-start; }
.section-visibility-note { padding: 6px 9px; border-radius: 999px; background: #f1f4f3; color: var(--muted); font-size: 10px; font-weight: 800; }
.price-history-list { border-top: 1px solid var(--line); }
.price-history-row { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 14px 2px; border-bottom: 1px solid var(--line); }
.price-history-row > div { display: flex; flex-direction: column; gap: 3px; }
.price-history-row span { color: var(--muted); font-size: 11px; }
.history-price { font-size: 16px; }
.neighborhood-layout { display: grid; grid-template-columns: 1.15fr .85fr; gap: 14px; margin-top: 16px; }
.neighborhood-map-placeholder { min-height: 220px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 5px; border-radius: 12px; background: linear-gradient(145deg,#eaf1ef,#d9e5e1); color: #2c4940; text-align: center; }
.neighborhood-map-placeholder .map-pin { font-size: 30px; }
.neighborhood-map-placeholder small { max-width: 280px; color: var(--muted); }
.nearby-list { padding: 16px; border: 1px solid var(--line); border-radius: 12px; }
.nearby-list > div { display: flex; gap: 8px; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.nearby-list > div:last-child { border-bottom: 0; }
.nearby-list > div span { color: var(--primary); }
.calculator-input-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; }
.calculator-input-grid label { display: flex; flex-direction: column; gap: 6px; color: #40504b; font-size: 12px; font-weight: 700; }
.calculator-input-grid input { width: 100%; min-height: 42px; padding: 9px 10px; border: 1px solid var(--line-dark); border-radius: 8px; font: inherit; }
.calculator-results { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; margin-top: 16px; }
.calculator-results > div { padding: 14px; border-radius: 10px; background: #f5f8f7; }
.calculator-results span { display: block; margin-bottom: 5px; color: var(--muted); font-size: 11px; }
.calculator-results strong { font-size: 18px; }
.calculator-result-primary { background: #e9f5f1 !important; }
.calculator-result-primary strong { color: var(--primary); font-size: 22px; }
.calculator-disclaimer { margin: 14px 0 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.detail-contact-column { min-width: 0; align-self: stretch; position: relative; }
/* v1_0_19 · la tarjeta “Publicado por” acompaña el scroll y permanece visible en desktop. */
.contact-card-sticky {
    position: sticky;
    top: 116px;
    align-self: start;
    z-index: 8;
    max-height: calc(100dvh - 136px);
    overflow-y: auto;
    overscroll-behavior: contain;
}
.property-modal-fragment .contact-card-sticky {
    top: 126px;
    max-height: calc(min(94dvh, 980px) - 146px);
}
.contact-card-sticky::-webkit-scrollbar { width: 7px; }
.contact-card-sticky::-webkit-scrollbar-thumb { background: rgba(52,70,63,.22); border-radius: 999px; }
.similar-property-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.similar-property-card { overflow: hidden; display: grid; grid-template-columns: 120px 1fr; min-height: 100px; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.similar-property-card img { width: 120px; height: 100%; object-fit: cover; }
.similar-property-card > div { min-width: 0; display: flex; flex-direction: column; justify-content: center; gap: 3px; padding: 10px; }
.similar-property-card span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: #354a43; font-size: 12px; }
.similar-property-card small { color: var(--muted); }

.property-photo-lightbox { position: fixed; inset: 0; z-index: 2200; display: grid; place-items: center; padding: 40px 70px; background: rgba(5,10,9,.94); }
.property-photo-lightbox img { max-width: min(1400px,92vw); max-height: 88vh; object-fit: contain; border-radius: 4px; }
.photo-lightbox-close, .photo-lightbox-prev, .photo-lightbox-next { position: fixed; z-index: 2; border: 0; background: rgba(255,255,255,.12); color: #fff; cursor: pointer; }
.photo-lightbox-close { top: 20px; right: 22px; width: 44px; height: 44px; border-radius: 50%; font-size: 28px; }
.photo-lightbox-prev, .photo-lightbox-next { top: 50%; width: 48px; height: 64px; transform: translateY(-50%); border-radius: 8px; font-size: 42px; }
.photo-lightbox-prev { left: 18px; }
.photo-lightbox-next { right: 18px; }
.photo-lightbox-count { position: fixed; left: 50%; bottom: 16px; transform: translateX(-50%); padding: 7px 10px; border-radius: 999px; background: rgba(255,255,255,.12); color: #fff; font-size: 12px; font-weight: 800; }

@media (max-width: 1050px) {
    .detail-layout-v111 { grid-template-columns: 1fr; }
    .detail-contact-column { order: 2; }
    .contact-card-sticky, .property-modal-fragment .contact-card-sticky { position: static; }
    .detail-feature-strip-v111 { grid-template-columns: repeat(3,minmax(0,1fr)); }
    .detail-feature-strip-v111 > div { border-bottom: 1px solid var(--line); }
}

@media (max-width: 760px) {
    .property-gallery-list { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .optional-section-heading { flex-direction: column; gap: 10px; }
    .section-toggle { align-self: flex-start; }
    .property-modal-overlay { padding: 0; }
    .property-modal-panel { width: 100%; height: 100dvh; max-height: none; border-radius: 0; }
    .property-modal-toolbar { min-height: 54px; padding-inline: 12px; }
    .property-modal-fragment .detail-section-nav { top: 54px; }
    .property-gallery-stage { display: block; aspect-ratio: auto; border-radius: 0; background: #dbe3e0; }
    .property-gallery-primary { display: block; width: 100%; aspect-ratio: 4 / 3; min-height: 0; max-height: 72dvh; }
    .property-gallery-secondary { display: none; }
    .gallery-see-all { right: 12px; bottom: 12px; }
    .detail-layout-v111 { width: min(100% - 24px,1180px); gap: 18px; padding-top: 18px; }
    .detail-summary-head { flex-direction: column; gap: 12px; }
    .detail-inline-actions { width: 100%; }
    .detail-action-button { flex: 1; }
    .detail-feature-strip-v111 { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .basic-facts-grid, .advanced-facts-grid, .neighborhood-layout, .calculator-input-grid, .calculator-results, .similar-property-grid { grid-template-columns: 1fr; }
    .detail-section-card { padding: 18px 15px; }
    .similar-property-card { grid-template-columns: 110px 1fr; }
    .similar-property-card img { width: 110px; }
    .property-photo-lightbox { padding: 55px 12px; }
    .photo-lightbox-prev, .photo-lightbox-next { width: 42px; height: 54px; }
}


/* v1_0_18 · branding UbikaNova: logo mostrado 10% más pequeño */
.brand-primary { min-width: 0; flex: 0 0 auto; }
.brand-logo-full { width: 189px; height: 72px; max-width: 100%; object-fit: contain; object-position: left center; display: block; }
.brand-logo-footer { width: 216px; height: auto; max-height: 83px; object-position: left center; }
.sidebar-brand { min-height: 88px; justify-content: center; }
.brand-logo-sidebar { width: 171px; height: auto; max-height: 65px; object-position: center; }
.content-field-brand-logo .media-uploader { grid-template-columns: minmax(280px, 420px) 1fr; }
.media-preview-brand-logo { min-height: 190px; aspect-ratio: 900 / 340; background: #fff; padding: 16px; }
.media-preview-brand-logo img { width: 100%; height: 100%; min-height: 0; object-fit: contain; object-position: center; }
.media-preview-empty { color: var(--muted); font-size: 13px; text-align: center; }
@media (max-width: 900px) {
    .brand-logo-full { width: 158px; height: 59px; }
}
@media (max-width: 700px) {
    .brand-logo-full { width: 135px; height: 51px; }
    .brand-logo-footer { width: 198px; height: auto; max-height: 76px; }
    .content-field-brand-logo .media-uploader { grid-template-columns: 1fr; }
    .media-preview-brand-logo { min-height: 150px; }
}
