/* =========================================================
   Estilos del sitio
   Identidad tomada del logo:
     bordó  #5A2949  (fondo del logo)
     amarillo #F5B901 (barras del logo)
   Motivo gráfico: barras verticales de distinto alto.
   Tipografías: Outfit (títulos) + Inter (texto).
   ========================================================= */

:root {
    --brand: #5A2949;
    --brand-dark: #3F1C33;
    --brand-deep: #2C1324;
    --brand-soft: #F4EDF1;
    --accent: #F5B901;
    --accent-dark: #D9A300;
    --accent-soft: #FFF6D6;

    --ink: #22161E;
    --ink-2: #4B3F47;
    --ink-3: #7A6E76;
    --line: #E6DEE3;
    --bg: #FFFFFF;
    --bg-soft: #FAF7F5;
    --whatsapp: #1FAF55;

    --radius: 12px;
    --radius-sm: 8px;
    --shadow: 0 1px 2px rgba(44, 19, 36, .06), 0 8px 24px rgba(44, 19, 36, .08);
    --shadow-lg: 0 18px 48px rgba(44, 19, 36, .16);
    --header-h: 100px;
    --wrap: 1200px;
    --font: 'Inter', system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;
    --font-head: 'Outfit', 'Inter', system-ui, sans-serif;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; font-family: var(--font); font-size: 16px; line-height: 1.6; color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; }
body.nav-open { overflow: hidden; }
img { max-width: 100%; display: block; }
a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-dark); }
h1, h2, h3 { font-family: var(--font-head); line-height: 1.15; margin: 0 0 .5em; font-weight: 700; letter-spacing: -.01em; }
p { margin: 0 0 1em; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
.ico { width: 1.2em; height: 1.2em; flex: 0 0 auto; }
.container { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
.muted { color: var(--ink-3); }
.skip-link { position: absolute; left: -999px; top: 8px; z-index: 200; background: var(--accent); color: var(--brand-deep); padding: 8px 14px; border-radius: var(--radius-sm); font-weight: 600; }
.skip-link:focus { left: 8px; }

/* ---------- Botones ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5em; min-height: 48px; padding: .7em 1.4em; border: 0; border-radius: 999px; font-family: var(--font-head); font-weight: 600; font-size: 16px; line-height: 1.1; text-align: center; transition: background .15s, color .15s, box-shadow .15s, transform .15s; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); color: #fff; }
.btn-accent { background: var(--accent); color: var(--brand-deep); }
.btn-accent:hover { background: var(--accent-dark); color: var(--brand-deep); }
.btn-outline { background: transparent; color: var(--brand); box-shadow: inset 0 0 0 2px var(--brand); }
.btn-outline:hover { background: var(--brand); color: #fff; }
.btn-ghost { background: #fff; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
.btn-ghost:hover { color: var(--brand); box-shadow: inset 0 0 0 1.5px var(--brand); }
.btn-whatsapp { background: var(--whatsapp); color: #fff; }
.btn-whatsapp:hover { background: #178F45; color: #fff; }
.btn-sm { min-height: 40px; padding: .5em 1.1em; font-size: 15px; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .6; cursor: wait; }

/* ---------- Header ---------- */
.site-header { position: sticky; top: 0; z-index: 100; background: var(--brand); color: #fff; transition: box-shadow .2s; }
.site-header.is-scrolled { box-shadow: 0 6px 24px rgba(44, 19, 36, .25); }
.header-inner { display: flex; align-items: center; gap: 24px; height: var(--header-h); }
/* Logo completo (manual de marca: no se recorta). Su fondo es el mismo bordó del header. */
.brand { flex: 0 0 auto; display: flex; align-items: center; }
.brand img { height: calc(var(--header-h) - 10px); width: auto; }
.main-nav { margin-left: auto; }
.main-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 4px; }
.main-nav a { display: block; padding: 10px 14px; color: rgba(255, 255, 255, .85); font-family: var(--font-head); font-weight: 500; font-size: 16px; border-radius: 999px; transition: background .15s, color .15s; }
.main-nav a:hover { color: #fff; background: rgba(255, 255, 255, .08); }
.main-nav a.is-active { color: var(--accent); }
.nav-mobile-only { display: none; }
.header-actions { display: flex; align-items: center; gap: 10px; }
.header-fav { position: relative; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; color: #fff; }
.header-fav:hover { background: rgba(255, 255, 255, .1); color: var(--accent); }
.header-fav .ico { width: 22px; height: 22px; }
.fav-count { position: absolute; top: 2px; right: 0; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--accent); color: var(--brand-deep); font-size: 11px; font-weight: 700; line-height: 18px; text-align: center; }
.nav-toggle { display: none; width: 44px; height: 44px; border: 0; border-radius: 50%; background: transparent; color: #fff; place-items: center; }
.nav-toggle .ico { width: 26px; height: 26px; }
.nav-toggle-close { display: none; }
.nav-toggle[aria-expanded="true"] .nav-toggle-open { display: none; }
.nav-toggle[aria-expanded="true"] .nav-toggle-close { display: inline; }

/* ---------- Títulos de sección ---------- */
.section { padding: 72px 0; }
.section-tight { padding: 32px 0 72px; }
.section-soft { background: var(--bg-soft); }
.section-dark { background: var(--brand-deep); color: #fff; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 32px; }
.section-title { font-size: clamp(28px, 3.4vw, 40px); margin: 0; color: inherit; }
.section-dark .section-title { color: #fff; }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 10px; font-family: var(--font-head); font-size: 13px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--brand); }
.eyebrow::before { content: ''; width: 4px; height: 16px; background: var(--accent); box-shadow: 7px 4px 0 -1px var(--accent); margin-right: 6px; }
.eyebrow-light { color: var(--accent); }
.link-more { display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-head); font-weight: 600; white-space: nowrap; }
.link-more:hover .ico { transform: translateX(3px); }
.link-more .ico { transition: transform .15s; }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; background: radial-gradient(120% 140% at 100% 0%, #6E3459 0%, var(--brand) 45%, var(--brand-dark) 100%); color: #fff; padding: 88px 0 120px; }
.hero-bars { position: absolute; right: max(0px, calc((100vw - var(--wrap)) / 2)); bottom: 0; height: 88%; width: min(520px, 46vw); display: flex; align-items: flex-end; justify-content: space-between; gap: 8px; opacity: .22; pointer-events: none; }
.hero-bars span { width: var(--w); height: var(--h); background: var(--accent); animation: bar-rise .9s cubic-bezier(.2, .8, .2, 1) both; }
.hero-bars span:nth-child(2n) { animation-delay: .08s; }
.hero-bars span:nth-child(3n) { animation-delay: .16s; }
@keyframes bar-rise { from { transform: scaleY(0); transform-origin: bottom; } to { transform: scaleY(1); transform-origin: bottom; } }
.hero-inner { position: relative; }
.hero-title { font-size: clamp(36px, 6vw, 68px); font-weight: 800; max-width: 820px; margin-bottom: 18px; letter-spacing: -.01em; text-transform: uppercase; line-height: 1.05; }
.hero-title em { font-style: normal; color: var(--accent); }
.hero-lead { font-size: clamp(19px, 2.2vw, 24px); max-width: 560px; color: #fff; margin-bottom: 14px; }
.hero-services { list-style: none; display: flex; flex-wrap: wrap; margin: 0 0 36px; padding: 0; font-size: clamp(14px, 1.6vw, 17px); letter-spacing: .06em; text-transform: uppercase; color: rgba(255, 255, 255, .82); }
.hero-services li + li::before { content: '|'; margin: 0 .6em; color: rgba(255, 255, 255, .45); }

/* Buscador */
.search-box { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) auto; gap: 0; max-width: 920px; background: #fff; color: var(--ink); border-radius: 18px; padding: 8px; box-shadow: var(--shadow-lg); }
.search-field { display: flex; flex-direction: column; justify-content: center; padding: 8px 18px; border-right: 1px solid var(--line); min-width: 0; }
.search-field:nth-child(3) { border-right: 0; }
.search-field label { font-family: var(--font-head); font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
.search-field select { border: 0; background: transparent; padding: 4px 22px 4px 0; font-weight: 500; font-size: 16px; color: var(--ink); appearance: none; -webkit-appearance: none; cursor: pointer; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5l5-5' stroke='%235A2949' stroke-width='1.8' fill='none' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 2px center; }
.search-field select:focus { outline: none; }
.search-field:focus-within { background: var(--bg-soft); border-radius: 10px; }
.search-submit { border-radius: 12px; min-height: 60px; padding: 0 28px; font-size: 17px; }

/* ---------- Operaciones ---------- */
.section-ops { padding: 0; margin-top: -56px; position: relative; z-index: 2; }
.ops-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.op-card { display: flex; align-items: center; gap: 16px; padding: 24px; background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); color: var(--ink); transition: transform .2s, box-shadow .2s; }
.op-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); color: var(--ink); }
.op-icon { display: grid; place-items: center; width: 54px; height: 54px; border-radius: 14px; background: var(--brand-soft); color: var(--brand); flex: 0 0 auto; }
.op-icon .ico { width: 26px; height: 26px; }
.op-card-alt .op-icon { background: var(--accent-soft); color: var(--accent-dark); }
.op-body { display: flex; flex-direction: column; min-width: 0; }
.op-body small { font-family: var(--font-head); font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); }
.op-body strong { font-family: var(--font-head); font-size: 19px; font-weight: 700; }
.op-body span { font-size: 14px; color: var(--ink-3); }
.op-arrow { margin-left: auto; color: var(--brand); transition: transform .2s; }
.op-card:hover .op-arrow { transform: translateX(4px); }

/* ---------- Tarjetas de propiedad ---------- */
.cards-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.property-card { position: relative; display: flex; flex-direction: column; background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); transition: transform .2s, box-shadow .2s; }
.property-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.property-card.is-skeleton { min-height: 380px; background: linear-gradient(100deg, #f3eef1 40%, #faf7f8 50%, #f3eef1 60%) 0 0 / 200% 100%; animation: shimmer 1.3s linear infinite; box-shadow: none; }
@keyframes shimmer { to { background-position: -200% 0; } }
.card-media { position: relative; aspect-ratio: 4 / 3; background: var(--brand-soft); overflow: hidden; }
.card-media > a { display: block; height: 100%; }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.property-card:hover .card-media img { transform: scale(1.04); }
.no-photo { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; height: 100%; color: var(--brand); opacity: .55; font-size: 14px; }
.no-photo .ico { width: 34px; height: 34px; }
.card-badges, .property-badges { position: absolute; top: 12px; left: 12px; display: flex; flex-wrap: wrap; gap: 6px; }
.badge { display: inline-block; padding: 4px 10px; border-radius: 999px; font-family: var(--font-head); font-size: 12px; font-weight: 600; letter-spacing: .03em; line-height: 1.4; }
.badge-op { background: var(--brand); color: #fff; }
.badge-status { background: var(--accent); color: var(--brand-deep); }
.badge-credit { background: #fff; color: var(--brand); }
.fav-btn { position: absolute; top: 10px; right: 10px; display: grid; place-items: center; width: 38px; height: 38px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .92); color: var(--brand); box-shadow: 0 2px 8px rgba(0, 0, 0, .12); transition: transform .15s; }
.fav-btn:hover { transform: scale(1.08); }
.fav-btn.is-on { color: #fff; background: var(--brand); }
.fav-btn.is-on .ico, .tool-btn.is-on .ico { fill: currentColor; }
.card-body { display: flex; flex-direction: column; flex: 1; padding: 18px 20px 20px; }
.card-type { margin: 0 0 4px; font-size: 13px; color: var(--ink-3); }
.card-title { font-size: 18px; margin: 0 0 6px; }
.card-title a { color: var(--ink); }
.card-title a::after { content: ''; position: absolute; inset: 0; } /* toda la tarjeta clickeable */
.card-title a:hover { color: var(--brand); }
.card-loc { display: flex; align-items: center; gap: 5px; margin: 0 0 12px; font-size: 14px; color: var(--ink-2); }
.card-loc .ico { width: 16px; height: 16px; color: var(--brand); }
.card-facts { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 0 0 14px; padding: 12px 0 0; border-top: 1px solid var(--line); font-size: 13px; color: var(--ink-2); }
.card-facts li { display: inline-flex; align-items: center; gap: 5px; }
.card-facts .ico { width: 16px; height: 16px; color: var(--ink-3); }
.card-price { margin: auto 0 0; font-family: var(--font-head); font-size: 22px; font-weight: 700; color: var(--brand); }
.card-price.is-consult { font-size: 17px; color: var(--ink-2); }
.fav-btn, .card-badges { z-index: 2; }

/* ---------- Categorías ---------- */
.category-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.category-card { display: flex; flex-direction: column; gap: 4px; padding: 28px 24px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); color: var(--ink); transition: border-color .2s, transform .2s, box-shadow .2s; }
.category-card:hover { border-color: var(--brand); transform: translateY(-3px); box-shadow: var(--shadow); color: var(--ink); }
.category-icon { display: grid; place-items: center; width: 52px; height: 52px; margin-bottom: 12px; border-radius: 14px; background: var(--brand); color: var(--accent); }
.category-icon .ico { width: 26px; height: 26px; }
.category-card strong { font-family: var(--font-head); font-size: 20px; }
.category-card small { color: var(--ink-3); font-size: 14px; }

/* ---------- Nosotros / mapa ---------- */
.about-split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.about-text .section-title { margin-bottom: 18px; }
.about-text p { color: var(--ink-2); }
.about-text .btn { margin-top: 8px; }
.about-map { position: relative; border-radius: var(--radius); overflow: hidden; aspect-ratio: 4 / 3; box-shadow: var(--shadow); }
.about-map::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 6px; background: var(--accent); z-index: 1; }
.about-map iframe, .property-map iframe, .map-band iframe { width: 100%; height: 100%; border: 0; display: block; }

/* ---------- Contacto (bloque oscuro) ---------- */
.contact-split, .form-split { display: grid; grid-template-columns: 1fr 1.1fr; gap: 56px; align-items: start; }
.contact-intro > p { color: rgba(255, 255, 255, .78); font-size: 17px; margin: 14px 0 28px; }
.contact-card { background: #fff; color: var(--ink); border-radius: 18px; padding: 32px; box-shadow: var(--shadow-lg); }
.section:not(.section-dark) .contact-card { box-shadow: var(--shadow); border: 1px solid var(--line); }

.contact-list { list-style: none; margin: 0 0 24px; padding: 0; display: grid; gap: 16px; }
.contact-list li { display: flex; align-items: center; gap: 14px; }
.contact-ico { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: var(--brand-soft); color: var(--brand); flex: 0 0 auto; }
.contact-list small { display: block; font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
.contact-list a { color: var(--ink); font-weight: 500; word-break: break-word; }
.contact-list a:hover { color: var(--brand); }
.section-dark .contact-ico { background: rgba(255, 255, 255, .08); color: var(--accent); }
.section-dark .contact-list small { color: rgba(255, 255, 255, .55); }
.section-dark .contact-list a { color: #fff; }
.section-dark .contact-list a:hover { color: var(--accent); }

/* ---------- Formularios ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-field { display: flex; flex-direction: column; gap: 6px; }
.form-field-full { grid-column: 1 / -1; }
.form-field label { font-size: 14px; font-weight: 600; color: var(--ink-2); }
.form-field input, .form-field select, .form-field textarea, .filter-field input, .filter-field select {
    width: 100%; min-height: 48px; padding: 10px 14px; border: 1.5px solid var(--line); border-radius: var(--radius-sm); background: #fff; font-size: 16px; transition: border-color .15s, box-shadow .15s;
}
.form-field textarea { resize: vertical; min-height: 110px; }
.form-field input:focus, .form-field select:focus, .form-field textarea:focus, .filter-field input:focus, .filter-field select:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(90, 41, 73, .14); }
.form-note { font-size: 13px; color: var(--ink-3); margin: 14px 0 16px; }
.form-feedback { margin: 14px 0 0; padding: 12px 14px; border-radius: var(--radius-sm); font-size: 15px; }
.form-feedback.is-ok { background: #E8F6EC; color: #17663A; }
.form-feedback.is-error { background: #FDECEC; color: #A12626; }
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Encabezado de página interna ---------- */
.page-hero { position: relative; overflow: hidden; background: var(--brand); color: #fff; padding: 44px 0 48px; }
.page-hero::after { content: ''; position: absolute; right: max(20px, calc((100vw - var(--wrap)) / 2 + 20px)); bottom: 0; width: 220px; height: 100%; opacity: .16; background:
    linear-gradient(var(--accent), var(--accent)) 0 100% / 30px 46% no-repeat,
    linear-gradient(var(--accent), var(--accent)) 42px 100% / 6px 80% no-repeat,
    linear-gradient(var(--accent), var(--accent)) 58px 100% / 36px 92% no-repeat,
    linear-gradient(var(--accent), var(--accent)) 106px 100% / 30px 54% no-repeat,
    linear-gradient(var(--accent), var(--accent)) 148px 100% / 6px 72% no-repeat,
    linear-gradient(var(--accent), var(--accent)) 166px 100% / 26px 64% no-repeat,
    linear-gradient(var(--accent), var(--accent)) 200px 100% / 4px 100% no-repeat; }
.page-hero h1 { font-size: clamp(30px, 4.4vw, 48px); margin: 0 0 6px; position: relative; z-index: 1; }
.page-hero-sub { margin: 0; color: rgba(255, 255, 255, .78); position: relative; z-index: 1; }
.breadcrumb { display: flex; flex-wrap: wrap; gap: 8px; font-size: 14px; margin-bottom: 14px; color: rgba(255, 255, 255, .6); position: relative; z-index: 1; }
.breadcrumb a { color: rgba(255, 255, 255, .85); }
.breadcrumb a:hover { color: var(--accent); }
.property-page .breadcrumb { color: var(--ink-3); margin: 24px 0 16px; }
.property-page .breadcrumb a { color: var(--ink-2); }
.property-page .breadcrumb a:hover { color: var(--brand); }

/* ---------- Barra de filtros ---------- */
.filter-bar { position: sticky; top: var(--header-h); z-index: 50; background: #fff; border-bottom: 1px solid var(--line); box-shadow: 0 6px 18px rgba(44, 19, 36, .05); padding: 14px 0; }
.filter-bar > .container { display: flex; flex-direction: column; gap: 12px; }
.filter-ops { display: flex; flex-wrap: wrap; gap: 6px; }
.filter-ops label { cursor: pointer; }
.filter-ops input { position: absolute; opacity: 0; pointer-events: none; }
.filter-ops span { display: inline-block; padding: 8px 16px; border-radius: 999px; background: var(--bg-soft); border: 1.5px solid var(--line); font-family: var(--font-head); font-weight: 600; font-size: 15px; color: var(--ink-2); transition: all .15s; }
.filter-ops label:hover span { border-color: var(--brand); color: var(--brand); }
.filter-ops input:checked + span { background: var(--brand); border-color: var(--brand); color: #fff; }
.filter-ops input:focus-visible + span { outline: 3px solid var(--accent); outline-offset: 2px; }
.filter-toggle { display: none; }
.filter-fields { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px; }
.filter-field { display: flex; flex-direction: column; gap: 4px; flex: 1 1 150px; min-width: 0; }
.filter-field label { font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); }
.filter-field input, .filter-field select { min-height: 44px; padding: 8px 12px; font-size: 15px; }
.filter-field.is-disabled { opacity: .5; }
.filter-field-price { flex: 1.6 1 220px; }
.price-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.filter-check { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 4px; font-size: 15px; font-weight: 500; cursor: pointer; white-space: nowrap; }
.filter-check input { width: 18px; height: 18px; accent-color: var(--brand); }
.filter-actions { display: flex; gap: 8px; }
.filter-actions .btn { min-height: 44px; }

.results-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 24px; }
.active-filters { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px 6px 14px; border-radius: 999px; background: var(--brand-soft); color: var(--brand); font-size: 14px; font-weight: 500; }
.chip .ico { width: 14px; height: 14px; }
.chip:hover { background: var(--brand); color: #fff; }
.sort { display: inline-flex; align-items: center; gap: 10px; margin-left: auto; font-size: 14px; color: var(--ink-3); }
.sort select { min-height: 40px; padding: 6px 12px; border: 1.5px solid var(--line); border-radius: var(--radius-sm); background: #fff; font-size: 15px; color: var(--ink); }

.pager { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px; margin-top: 44px; }
.pg { display: grid; place-items: center; min-width: 44px; height: 44px; padding: 0 10px; border-radius: 12px; border: 1.5px solid var(--line); background: #fff; color: var(--ink); font-weight: 600; }
.pg:hover { border-color: var(--brand); color: var(--brand); }
.pg.is-current { background: var(--brand); border-color: var(--brand); color: #fff; }
.pg-gap { display: grid; place-items: center; min-width: 24px; color: var(--ink-3); }

.notice { grid-column: 1 / -1; padding: 28px; text-align: center; color: var(--ink-2); background: var(--bg-soft); border-radius: var(--radius); margin: 0; }
.empty-state { grid-column: 1 / -1; max-width: 560px; margin: 0 auto; padding: 48px 20px; text-align: center; }
.empty-state h1, .empty-state h2 { font-size: 28px; }
.empty-state p { color: var(--ink-2); }
.empty-icon { display: inline-grid; place-items: center; width: 72px; height: 72px; margin-bottom: 16px; border-radius: 50%; background: var(--brand-soft); color: var(--brand); }
.empty-icon .ico { width: 32px; height: 32px; }
.empty-actions { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; }

/* ---------- Ficha ---------- */
.gallery { margin-bottom: 32px; }
.gallery-main { position: relative; aspect-ratio: 16 / 9; max-height: 620px; width: 100%; background: var(--brand-deep); border-radius: 18px; overflow: hidden; }
.gallery-main img { width: 100%; height: 100%; object-fit: contain; }
.gallery-main .no-photo { color: #fff; }
.gallery-nav { position: absolute; top: 50%; transform: translateY(-50%); display: grid; place-items: center; width: 48px; height: 48px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .92); color: var(--brand); box-shadow: var(--shadow); }
.gallery-nav:hover { background: var(--accent); color: var(--brand-deep); }
.gallery-prev { left: 16px; }
.gallery-next { right: 16px; }
.gallery-count { position: absolute; right: 16px; bottom: 16px; padding: 4px 12px; border-radius: 999px; background: rgba(0, 0, 0, .55); color: #fff; font-size: 14px; }
.property-badges { top: 16px; left: 16px; }
.gallery-thumbs { display: flex; gap: 8px; margin-top: 10px; overflow-x: auto; scrollbar-width: thin; padding-bottom: 4px; }
.gallery-thumbs button { flex: 0 0 auto; width: 104px; height: 72px; padding: 0; border: 2px solid transparent; border-radius: 10px; overflow: hidden; background: none; opacity: .65; transition: opacity .15s, border-color .15s; }
.gallery-thumbs button.is-active, .gallery-thumbs button:hover { opacity: 1; border-color: var(--accent); }
.gallery-thumbs img { width: 100%; height: 100%; object-fit: cover; }

.property-layout { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 48px; align-items: start; }
.property-type { margin: 0 0 6px; font-size: 14px; color: var(--ink-3); }
.property-head h1 { font-size: clamp(28px, 3.6vw, 40px); margin-bottom: 10px; }
.property-location { display: flex; align-items: center; gap: 6px; color: var(--ink-2); margin: 0; }
.property-location .ico { color: var(--brand); }
.property-facts { list-style: none; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; margin: 28px 0 0; padding: 0; }
.property-facts li { display: flex; align-items: center; gap: 12px; padding: 14px; background: var(--bg-soft); border-radius: var(--radius-sm); }
.property-facts .ico { width: 26px; height: 26px; color: var(--brand); }
.property-facts small { display: block; font-size: 12px; color: var(--ink-3); }
.property-facts strong { font-family: var(--font-head); font-size: 17px; }
.property-section { margin-top: 40px; padding-top: 32px; border-top: 1px solid var(--line); }
.property-section h2 { font-size: 24px; margin-bottom: 16px; }
.property-desc { color: var(--ink-2); line-height: 1.75; }
.feature-list { list-style: none; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px 20px; margin: 0; padding: 0; }
.feature-list li { display: flex; align-items: center; gap: 8px; color: var(--ink-2); }
.feature-list .ico { color: var(--accent-dark); }
.property-map { aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; }

.property-aside { position: sticky; top: calc(var(--header-h) + 20px); display: grid; gap: 20px; }
.price-card { padding: 28px; border-radius: 18px; background: var(--brand); color: #fff; display: grid; gap: 10px; box-shadow: var(--shadow-lg); }
.price-label { margin: 0; font-size: 13px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: rgba(255, 255, 255, .65); }
.price-value { margin: 0 0 10px; font-family: var(--font-head); font-size: 36px; font-weight: 800; color: var(--accent); line-height: 1.1; }
.price-value.is-consult { font-size: 26px; }
.price-card .btn-ghost { background: transparent; color: #fff; box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, .35); }
.price-card .btn-ghost:hover { box-shadow: inset 0 0 0 1.5px var(--accent); color: var(--accent); }
.price-tools { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-top: 6px; padding-top: 14px; border-top: 1px solid rgba(255, 255, 255, .15); }
.tool-btn { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 4px; border: 0; border-radius: var(--radius-sm); background: transparent; color: rgba(255, 255, 255, .85); font-size: 13px; }
.tool-btn:hover, .tool-btn.is-on { background: rgba(255, 255, 255, .08); color: var(--accent); }
.aside-form { padding: 24px; border: 1px solid var(--line); border-radius: 18px; background: #fff; }
.aside-form h2 { font-size: 20px; }
.aside-form .form-grid { grid-template-columns: 1fr; }
.related { padding: 64px 0 80px; }
.related .section-title { margin-bottom: 28px; font-size: 30px; }

/* ---------- Quiénes somos / tasaciones ---------- */
.values-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.value-card { position: relative; padding: 36px 30px; border-radius: 18px; background: #fff; border: 1px solid var(--line); }
.value-card::before { content: ''; position: absolute; left: 30px; top: 0; width: 44px; height: 5px; background: var(--accent); border-radius: 0 0 4px 4px; }
.value-num { display: block; font-family: var(--font-head); font-size: 15px; font-weight: 700; color: var(--brand); opacity: .5; margin-bottom: 10px; }
.value-card h2 { font-size: 24px; }
.value-card p { color: var(--ink-2); margin: 0; }
.steps { list-style: none; counter-reset: step; margin: 24px 0; padding: 0; display: grid; gap: 22px; }
.steps li { counter-increment: step; position: relative; padding-left: 60px; }
.steps li::before { content: counter(step); position: absolute; left: 0; top: 0; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px; background: var(--brand); color: var(--accent); font-family: var(--font-head); font-weight: 700; font-size: 18px; }
.steps strong { display: block; font-family: var(--font-head); font-size: 18px; }
.steps span { color: var(--ink-2); }
.small-title { font-size: 18px; margin-top: 8px; }
.hours { list-style: none; margin: 0; padding: 0; }
.hours li { display: flex; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.map-band { height: 380px; background: var(--bg-soft); }

/* ---------- Footer ---------- */
.site-footer { background: var(--brand); color: rgba(255, 255, 255, .78); padding-top: 64px; font-size: 15px; }
.footer-grid { display: grid; grid-template-columns: 1.1fr 1fr 1.4fr 1fr; gap: 40px; padding-bottom: 48px; }
.footer-logo img { width: 140px; height: auto; margin-bottom: 14px; }
.footer-title { font-size: 16px; color: #fff; margin-bottom: 16px; }
.footer-links { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.site-footer a { color: rgba(255, 255, 255, .85); }
.site-footer a:hover { color: var(--accent); }
.site-footer .contact-list { gap: 12px; }
.site-footer .contact-ico { width: 36px; height: 36px; border-radius: 10px; background: rgba(255, 255, 255, .08); color: var(--accent); }
.site-footer .contact-list small { color: rgba(255, 255, 255, .5); }
.site-footer .contact-list a { color: #fff; font-size: 14px; }
.social-links { display: flex; gap: 8px; margin-top: 16px; }
.social-links a { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: rgba(255, 255, 255, .08); }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .1); padding: 18px 0; font-size: 13px; }
.footer-bottom .container { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; }

/* WhatsApp flotante + toast */
.wa-float { position: fixed; right: 20px; bottom: 20px; z-index: 90; display: grid; place-items: center; width: 58px; height: 58px; border-radius: 50%; background: var(--whatsapp); color: #fff; box-shadow: 0 8px 24px rgba(31, 175, 85, .4); transition: transform .2s; }
.wa-float:hover { transform: scale(1.07); color: #fff; }
.wa-float .ico { width: 30px; height: 30px; }
/* Oculto del todo (visibility) para que no asome fuera de pantalla */
.toast { position: fixed; left: 50%; bottom: 28px; z-index: 120; transform: translate(-50%, calc(100% + 40px)); visibility: hidden; padding: 12px 20px; border-radius: 999px; background: var(--brand-deep); color: #fff; font-size: 15px; box-shadow: var(--shadow-lg); transition: transform .25s, visibility .25s; pointer-events: none; }
.toast.is-on { transform: translate(-50%, 0); visibility: visible; }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
    .cards-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .property-layout { grid-template-columns: minmax(0, 1fr) 340px; gap: 32px; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 920px) {
    :root { --header-h: 80px; }
    .nav-toggle { display: grid; }
    .header-cta span { display: none; }
    .header-cta { width: 42px; padding: 0; }
    .main-nav { position: fixed; inset: var(--header-h) 0 0 0; background: var(--brand); padding: 24px 20px; transform: translateX(100%); visibility: hidden; transition: transform .25s, visibility .25s; overflow-y: auto; }
    .main-nav.is-open { transform: none; visibility: visible; }
    .main-nav ul { flex-direction: column; gap: 4px; }
    .main-nav a { font-size: 22px; padding: 14px 16px; border-radius: 12px; }
    .nav-mobile-only { display: block; }
    .header-actions { margin-left: auto; }

    .search-box { grid-template-columns: 1fr 1fr; gap: 6px; }
    .search-field { border-right: 0; background: var(--bg-soft); border-radius: 10px; }
    .search-field:nth-child(3) { grid-column: 1 / -1; }
    .search-submit { grid-column: 1 / -1; min-height: 54px; }
    .hero-bars { opacity: .12; width: 70vw; }
    .ops-grid, .category-grid { grid-template-columns: 1fr 1fr; }
    .ops-grid .op-card-alt { grid-column: 1 / -1; }
    .cards-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
    .about-split, .contact-split, .form-split { grid-template-columns: 1fr; gap: 36px; }
    .values-grid { grid-template-columns: 1fr; }
    .property-layout { grid-template-columns: 1fr; }
    .property-aside { position: static; }

    .filter-bar { position: static; }
    .filter-toggle { display: inline-flex; align-items: center; gap: 8px; align-self: flex-start; min-height: 42px; padding: 0 16px; border: 1.5px solid var(--line); border-radius: 999px; background: #fff; font-weight: 600; }
    .filter-fields { display: none; }
    .filter-bar.is-open .filter-fields { display: grid; grid-template-columns: 1fr 1fr; }
    .filter-field-price, .filter-actions { grid-column: 1 / -1; }
    .filter-actions .btn { flex: 1; }
}

@media (max-width: 560px) {
    .container { padding: 0 16px; }
    .section { padding: 56px 0; }
    .hero { padding: 56px 0 96px; }
    .hero-lead { font-size: 16px; }
    .search-box { grid-template-columns: 1fr; }
    .ops-grid, .category-grid { grid-template-columns: 1fr; }
    .category-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
    .category-card { padding: 20px 16px; }
    .cards-grid { grid-template-columns: 1fr; }
    .section-head { flex-direction: column; align-items: flex-start; }
    .form-grid { grid-template-columns: 1fr; }
    .contact-card { padding: 22px; }
    .filter-bar.is-open .filter-fields { grid-template-columns: 1fr; }
    .sort { margin-left: 0; }
    .gallery-main { border-radius: 12px; aspect-ratio: 4 / 3; }
    .gallery-nav { width: 40px; height: 40px; }
    .footer-grid { grid-template-columns: 1fr; gap: 32px; }
    .page-hero::after { width: 140px; opacity: .1; }
}

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

/* ---------- Impresión de ficha ---------- */
@media print {
    .site-header, .site-footer, .wa-float, .gallery-nav, .gallery-thumbs, .price-tools, .aside-form, .related, .breadcrumb, .property-map, .btn { display: none !important; }
    .property-layout { grid-template-columns: 1fr; }
    .price-card { background: none; color: #000; box-shadow: none; padding: 0; }
    .price-value { color: #000; }
    .gallery-main { max-height: 360px; background: none; }
}
