/* YesCosta: mapa, listado y contacto (yescosta.es) */
.ycf, .ycf-grid, .ycf-contact { --ycf-navy:#0f2a4a; --ycf-accent:#e0a526; --ycf-line:#e3e8ef; --ycf-muted:#5d6b7c; --ycf-bg:#f6f8fb; font-size:15px; color:#1c2733; }
.ycf *, .ycf-grid *, .ycf-contact * { box-sizing:border-box; }

/* filters */
.ycf-filters { display:grid; grid-template-columns:repeat(7, minmax(0,1fr)) auto; gap:10px; align-items:end; padding:14px; background:#fff; border:1px solid var(--ycf-line); border-radius:12px; }
.ycf-filters label { display:flex; flex-direction:column; gap:4px; min-width:0; }
.ycf-filters label > span { font-size:11px; font-weight:700; letter-spacing:.04em; text-transform:uppercase; color:var(--ycf-muted); }
.ycf-filters select { width:100%; min-height:42px; border:1px solid var(--ycf-line); border-radius:8px; padding:6px 10px; background:#fff; font-size:14px; color:inherit; }
.ycf-reset { min-height:42px; border:1px solid var(--ycf-line); background:#fff; border-radius:8px; padding:0 14px; cursor:pointer; color:var(--ycf-navy); font-weight:600; white-space:nowrap; }

.ycf-filter-toggle { display:none; }
.ycf-bar { display:flex; align-items:center; gap:16px; flex-wrap:wrap; margin:14px 0 10px; }
.ycf-count { font-size:17px; color:var(--ycf-navy); }
.ycf-bounds { display:flex; gap:6px; align-items:center; color:var(--ycf-muted); font-size:14px; cursor:pointer; }
.ycf-switch { margin-left:auto; display:none; border:1px solid var(--ycf-line); border-radius:999px; overflow:hidden; }
.ycf-switch button { border:0; background:#fff; padding:8px 18px; font-weight:600; cursor:pointer; color:var(--ycf-navy); }
.ycf-switch button.is-on { background:var(--ycf-navy); color:#fff; }

/* map + list */
.ycf-body { display:block; }
.ycf-has-map .ycf-body { display:grid; grid-template-columns:minmax(0,1.15fr) minmax(0,1fr); gap:16px; }
.ycf-has-map .ycf-list { height:var(--ycf-h, 680px); overflow:auto; padding-right:4px; }
.ycf-map { height:var(--ycf-h, 680px); border-radius:12px; border:1px solid var(--ycf-line); position:sticky; top:20px; z-index:1; }
.ycf-cards { display:grid; grid-template-columns:repeat(auto-fill, minmax(240px, 1fr)); gap:16px; }
.ycf-view-lista .ycf-cards { grid-template-columns:repeat(auto-fill, minmax(260px, 1fr)); }
.ycf-more { display:block; margin:18px auto 6px; min-height:44px; padding:0 26px; border-radius:999px; border:0; background:var(--ycf-navy); color:#fff; font-weight:600; cursor:pointer; }
.ycf-empty { grid-column:1/-1; padding:30px; text-align:center; color:var(--ycf-muted); background:var(--ycf-bg); border-radius:12px; }

/* card (list, grid, popup) */
.ycf-grid { display:grid; grid-template-columns:repeat(auto-fill, minmax(260px, 1fr)); gap:20px; }
.ycf-card { display:flex; flex-direction:column; background:#fff; border:1px solid var(--ycf-line); border-radius:12px; overflow:hidden; color:inherit !important; text-decoration:none !important; transition:box-shadow .2s, transform .2s; }
.ycf-card:hover { box-shadow:0 10px 26px rgba(15,42,74,.12); transform:translateY(-2px); }
.ycf-img { position:relative; display:block; aspect-ratio:4/3; background:var(--ycf-bg) center/48px no-repeat; overflow:hidden; }
.ycf-img img { width:100%; height:100%; object-fit:cover; display:block; }
.ycf-tag { position:absolute; left:10px; top:10px; font-style:normal; font-size:12px; font-weight:700; padding:4px 10px; border-radius:999px; background:#fff; color:var(--ycf-navy); }
.ycf-tag-obra-nueva { background:var(--ycf-accent); color:#1c1300; }
.ycf-info { display:flex; flex-direction:column; gap:4px; padding:12px 14px 14px; }
.ycf-info b { font-size:19px; color:var(--ycf-navy); }
.ycf-t { font-size:14px; line-height:1.35; color:#33414f; }
.ycf-facts { display:flex; gap:12px; flex-wrap:wrap; margin-top:4px; }
.ycf-facts i { font-style:normal; font-size:13px; color:var(--ycf-muted); }
.ycf-pop .ycf-card { border:0; box-shadow:none; transform:none; }
.leaflet-popup-content { margin:0; width:240px !important; }
.leaflet-popup-content-wrapper { padding:0; overflow:hidden; border-radius:12px; }

/* contact */
.ycf-contact form { display:grid; gap:14px; }
.ycf-contact .ycf-row { display:grid; grid-template-columns:1fr 1fr; gap:14px; }
.ycf-contact label { display:flex; flex-direction:column; gap:6px; }
.ycf-contact label > span { font-size:13px; font-weight:600; color:#33414f; }
.ycf-contact input[type=text], .ycf-contact input[type=email], .ycf-contact input[type=tel], .ycf-contact textarea { width:100%; border:1px solid var(--ycf-line); border-radius:8px; padding:11px 12px; font:inherit; background:#fff; }
.ycf-contact .ycf-consent { flex-direction:row; align-items:flex-start; gap:8px; }
.ycf-contact .ycf-consent span { font-weight:400; }
.ycf-contact .ycf-legal { font-size:12px; color:var(--ycf-muted); margin:0; }
.ycf-contact button { justify-self:start; min-height:46px; padding:0 30px; border:0; border-radius:999px; background:var(--ycf-navy); color:#fff; font-weight:700; cursor:pointer; }
.ycf-ok, .ycf-err { padding:12px 16px; border-radius:8px; }
.ycf-ok { background:#e8f6ee; color:#135c32; }
.ycf-err { background:#fdecea; color:#8a1c12; }
.ycf-hp { position:absolute !important; left:-9999px !important; }

@media (max-width:1100px) {
  .ycf-filters { grid-template-columns:repeat(4, minmax(0,1fr)); }
}
@media (max-width:860px) {
  .ycf-filters { grid-template-columns:repeat(2, minmax(0,1fr)); display:none; }
  .ycf-filters-open .ycf-filters { display:grid; }
  .ycf-filter-toggle { display:block; width:100%; min-height:46px; border:1px solid var(--ycf-line); background:#fff; border-radius:10px; font-weight:700; color:var(--ycf-navy); cursor:pointer; margin-bottom:10px; }
  .ycf-filter-toggle::before { content:'☰  '; }
  .ycf-filters-open .ycf-filter-toggle { margin-bottom:10px; }
  .ycf-switch { display:flex; }
  .ycf-has-map .ycf-body { display:block; }
  .ycf-has-map .ycf-list { height:auto; overflow:visible; }
  .ycf-map { height:70vh; position:relative; top:0; }
  .ycf-mobile-map .ycf-list { display:none; }
  .ycf-has-map:not(.ycf-mobile-map) .ycf-map { display:none; }
  .ycf-bounds { display:none; }
  .ycf-contact .ycf-row { grid-template-columns:1fr; }
}
