/* LA MOTORS: lo propio del sitio sobre el kit (system.css + layout.css).
   Negro, grafito y plata; un solo acento (la plata del boton principal). */

/* ---------------------------------------------------------------- tipografia propia (sin saltos al cargar) */
@font-face {
  font-family: "Outfit"; font-style: normal; font-weight: 400 600; font-display: swap;
  src: url("fonts/outfit-latin.woff2") format("woff2");
}
/* respaldo con las medidas de Outfit: si la fuente tarda, el texto ocupa casi lo mismo y no brinca */
@font-face {
  font-family: "Outfit Fallback"; src: local("Arial"), local("Helvetica Neue"), local("Helvetica");
  size-adjust: 98%; ascent-override: 102.04%; descent-override: 26.53%; line-gap-override: 0%;   /* medido de los archivos (fontkit), no a ojo */
}

/* ---------------------------------------------------------------- base oscura (marca del cliente) */
:root { color-scheme: dark; --graphite: #1c1d21; --steel: #c8ccd1; }
html[data-type="place"] { --r-lg: 4px; --r-md: 4px; --r-sm: 2px; --r-btn: 2px; }
.nav { background: var(--p-bg); }

/* secciones que crecen con su contenido (el inventario, las resenas y la ficha cambian de largo) */
main > section.section--auto { height: auto; min-height: calc(var(--h, 1) * 100svh); }
main > section.section--auto > .wrap { height: auto; }

/* ---------------------------------------------------------------- logo */
.logo { display: block; width: auto; max-width: none; }
.nav__logo .logo--nav { height: 46px; }
@media (max-width: 639px) { .nav__logo .logo--nav { height: 38px; } }
.logo--foot { height: 52px; }

/* ---------------------------------------------------------------- hero */
.hero--brand h1 { font-size: clamp(34px, 1.5vw + 30px, 52px); line-height: 1.06; max-width: none; text-wrap: balance; }   /* el lema en 3 lineas a 1440 */
.hero--brand .t-lead { margin-top: var(--s-5); max-width: 46ch; color: var(--ink); }
.hero--brand .btn-row { margin-top: var(--s-6); }
/* la foto del hero: vertical en compu (llena la columna), recorte horizontal en celular */
.hero-photo { align-self: stretch; min-height: 0; overflow: hidden; border-radius: var(--r-lg); background: var(--graphite); }
.hero-photo picture { display: contents; }
.hero-photo .frame__img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 56%; display: block; }
@media (max-width: 1023px) { .hero-photo { width: 100%; } }
/* foto de portada con su propia forma (p. ej. cuadrada): el marco toma esa proporcion y la foto sale completa */
.hero-split > .hero-photo--forma { align-self: center; aspect-ratio: var(--hero-ar); width: 100%; height: auto; }
@media (max-width: 1023px) { .hero-split > .hero-photo--forma { flex: 0 0 auto; min-height: 0; } }
@media (max-width: 639px) { .hero-split > .hero-photo--forma { aspect-ratio: var(--hero-ar-cel); width: calc(100% + 2 * var(--gut, 24px)); } }
@media (max-width: 639px) {
  .hero--brand .hero-text { gap: var(--s-5); }
  .hero-photo { order: -1; flex: 0 0 auto; aspect-ratio: var(--hero-ar-cel, 3 / 2); height: auto; min-height: 0; margin-inline: calc(-1 * var(--gut, 24px)); width: calc(100% + 2 * var(--gut, 24px)); border-radius: 0; }
  .hero--brand h1 { font-size: 34px; }
}

/* ---------------------------------------------------------------- inventario */
.inv__note { color: var(--muted); max-width: 52ch; margin-top: var(--s-3); }
.filters { display: flex; flex-wrap: wrap; gap: var(--s-4) var(--s-7); margin-bottom: var(--s-7); }
.filters[hidden] { display: none; }
.filters__group { display: flex; flex-wrap: wrap; gap: var(--s-2); }
.chip {
  display: inline-flex; align-items: center; gap: var(--s-2); min-height: 44px; padding: 0 var(--s-5);
  border: 1px solid var(--line-strong); border-radius: 999px; background: transparent; color: var(--ink);
  font: 500 15px/1 var(--font-text); cursor: pointer;
  transition: background-color var(--m-out, 120ms) var(--ease), border-color var(--m-out, 120ms) var(--ease), color var(--m-out, 120ms) var(--ease);
}
.chip:hover { border-color: var(--ink); }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.chip__n { font-variant-numeric: tabular-nums; color: inherit; opacity: .64; }

.units { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-5); }
@media (max-width: 1023px) { .units { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 639px)  { .units { grid-template-columns: 1fr; gap: var(--s-4); } }
.unit-li[hidden] { display: none; }
.unit-li { display: flex; }
.card.unit { flex: 1; padding: 0; gap: 0; overflow: hidden; background: var(--p-surface); color: var(--ink); text-decoration: none; }
.unit__photo { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: var(--graphite); }
.unit__photo > img { display: block; width: 100%; height: 100%; object-fit: cover; }
.unit__body { display: flex; flex-direction: column; gap: var(--s-2); padding: var(--s-5); flex: 1; }
.unit__meta { display: flex; gap: var(--s-3); font-size: var(--t-label); font-weight: 500; color: var(--muted); }
.unit__meta > span + span::before { content: "·"; margin-right: var(--s-3); }
.unit__state { color: var(--ink); }
.is-sold .unit__state, .ficha .unit__state:only-child { color: var(--muted); }
.unit__name { font: 500 var(--t-card)/1.3 var(--font-text); letter-spacing: -0.01em; margin: 0; }
.unit__line { display: flex; justify-content: space-between; align-items: baseline; gap: var(--s-4); color: var(--muted); font-variant-numeric: tabular-nums; }
.unit__price { color: var(--ink); font: var(--display-weight) 24px/1.2 var(--font-display); letter-spacing: -0.01em; }
.is-sold .unit__price { color: var(--muted); }
.unit__more { margin-top: auto; padding-top: var(--s-3); align-self: flex-start; }
.chips { list-style: none; margin: var(--s-1) 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: var(--s-2); }
.chips li { font-size: 14px; padding: 4px 10px; border: 1px solid var(--line); border-radius: 999px; color: var(--ink); }
.units__empty { padding: var(--s-8) 0; display: grid; gap: var(--s-3); justify-items: start; color: var(--muted); }
.units__empty[hidden] { display: none; }

/* marcador sin foto: gris oscuro con el logo */
.ph { position: absolute; inset: 0; display: grid; place-items: center; background: var(--graphite); }
.ph__logo { width: 30%; max-width: 160px; height: auto; opacity: .55; }

/* sello VENDIDO */
.stamp {
  position: absolute; z-index: 2; left: 50%; top: 50%; translate: -50% -50%; rotate: -8deg;
  padding: 6px 18px 5px; border: 3px solid #e9ebee; border-radius: 4px; color: #f2f3f5;
  background: #0b0b0c; font: 600 26px/1 var(--font-display); letter-spacing: .18em; white-space: nowrap;
  padding-right: calc(18px - .18em);
  pointer-events: none;
}
.stamp--lg { font-size: clamp(30px, 4vw, 48px); border-width: 4px; padding: 10px calc(26px - .18em) 8px 26px; }
.is-sold .unit__photo > img { filter: grayscale(.35) brightness(.8); }

/* ---------------------------------------------------------------- resenas */
.quotes { columns: 3; column-gap: var(--s-5); }
@media (max-width: 1023px) { .quotes { columns: 2; } }
@media (max-width: 639px)  { .quotes { columns: 1; } }
.quote { margin: 0 0 var(--s-5); break-inside: avoid; display: flex; flex-direction: column; gap: var(--s-5); padding: var(--s-6); background: var(--bg); border: 1px solid var(--line); border-radius: var(--r-lg); }
.quote blockquote { margin: 0; }
.quote blockquote p { font: var(--display-weight) 20px/1.45 var(--font-display); letter-spacing: -0.005em; color: var(--ink); }
.quote figcaption { margin-top: auto; display: grid; gap: var(--s-1); font-size: var(--t-body); }
.quote__name { font-weight: 500; font-style: italic; }
.quote figcaption .link { color: var(--muted); justify-self: start; }

/* ---------------------------------------------------------------- nosotros (momento word-highlight) */
#nosotros .mo-wh__text { font-size: clamp(28px, 2.6vw + 16px, 52px); line-height: 1.16; max-width: 22ch; margin-top: var(--s-6); }
#nosotros .wrap { display: flex; flex-direction: column; justify-content: center; }

/* ---------------------------------------------------------------- contacto */
.contact .type-moment { font: var(--display-weight) clamp(40px, 7vw, 112px)/1.02 var(--font-display); letter-spacing: -0.03em; margin-top: var(--s-6); color: var(--ink); }
.contact__line { margin-top: var(--s-4); font-size: 20px; line-height: 1.5; color: var(--muted); }
.contact__line .link { color: var(--ink); font-variant-numeric: tabular-nums; white-space: nowrap; }
.contact .btn-row { margin-top: var(--s-7); }
.footer__row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s-6); padding-top: var(--s-6); border-top: 1px solid var(--line); }
.footer .redes, .redes { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: var(--s-2) var(--s-6); }
.social { display: inline-flex; align-items: center; gap: var(--s-2); min-height: 44px; font-weight: 500; color: var(--ink); }
.social svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.social:hover { color: var(--steel); }
.footer--visit .footer__legal { color: var(--muted); font-size: var(--t-small); }

/* ---------------------------------------------------------------- ficha */
.ficha__crumb { margin-bottom: var(--s-6); }
.ficha__crumb .link { display: inline-flex; align-items: center; min-height: 44px; }
.ficha__grid { align-items: start; row-gap: var(--s-7); }
.ficha__name { font: var(--display-weight) clamp(32px, 2vw + 20px, 48px)/1.08 var(--font-display); letter-spacing: var(--display-tracking); margin-top: var(--s-3); }
.ficha__line { display: flex; align-items: baseline; gap: var(--s-5); margin-top: var(--s-4); color: var(--muted); font-size: 20px; font-variant-numeric: tabular-nums; }
.ficha__price { color: var(--ink); font: var(--display-weight) clamp(28px, 1.4vw + 18px, 38px)/1.1 var(--font-display); letter-spacing: -0.02em; }
.ficha__desc { margin-top: var(--s-5); font-size: 20px; line-height: 1.5; color: var(--ink); max-width: 46ch; }
.ficha__sub { font: 500 var(--t-label)/1.3 var(--font-text); letter-spacing: 0; color: var(--muted); margin: var(--s-7) 0 var(--s-3); }
.ficha__rows { list-style: none; margin: 0; padding: 0; }
.ficha__rows li { padding: var(--s-3) 0; border-bottom: 1px solid var(--line); }
.ficha__info .btn-row { margin-top: var(--s-7); }
.ficha__hint { margin-top: var(--s-3); color: var(--muted); font-size: var(--t-small); }
.ficha__sold { margin-top: var(--s-6); font-size: 20px; }
.ficha__back { margin-top: var(--s-6); }
.ficha .quote { background: var(--p-surface); }
.ficha__media { min-width: 0; }

/* galeria deslizable: el dedo desliza; en compu, flechas y teclado */
.gallery { position: relative; border-radius: var(--r-lg); overflow: hidden; background: var(--graphite); }
.gallery__track {
  display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth;
  overscroll-behavior-x: contain; scrollbar-width: none; aspect-ratio: 3 / 4;
  max-height: calc(100svh - var(--nav, 72px) - 120px); width: 100%;
}
.gallery__track::-webkit-scrollbar { display: none; }
.gallery__track:focus-visible { outline-offset: -3px; }
.gallery__slide { position: relative; flex: 0 0 100%; scroll-snap-align: start; scroll-snap-stop: always; }
.gallery__slide > img { width: 100%; height: 100%; object-fit: contain; display: block; }
.gallery__bar {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 3; display: flex; align-items: center; justify-content: space-between;
  padding: var(--s-3);
}
.gallery__btn {
  width: 44px; height: 44px; display: grid; place-items: center; border-radius: 999px; border: 1px solid rgba(255,255,255,.25);
  background: rgba(11, 11, 12, .72); color: #f2f3f5; cursor: pointer;
}
.gallery__btn svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.gallery__btn:hover { background: rgba(11, 11, 12, .9); }
.gallery__btn:disabled { opacity: .35; cursor: default; }
.gallery__count { padding: 6px 12px; border-radius: 999px; background: rgba(11, 11, 12, .72); color: #f2f3f5; font-size: var(--t-small); font-variant-numeric: tabular-nums; }
@media (max-width: 1023px) { .ficha__grid > .span-6 { grid-column: 1 / -1; } }
@media (max-width: 639px) {
  .ficha__media { margin-inline: calc(-1 * var(--gut, 24px)); }
  .gallery { border-radius: 0; }
  .gallery__track { max-height: none; }
  .ficha__info .btn { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { .gallery__track { scroll-behavior: auto; } }
.is-sold .ph__logo, .gallery:has(.stamp) .ph__logo { display: none; }


/* compu ancha: resenas en 4 columnas, caben en una pantalla */
@media (min-width: 1280px) { .quotes { columns: 4; column-gap: var(--s-5); } .quote { padding: var(--s-5); gap: var(--s-4); margin-bottom: var(--s-4); } .quote blockquote p { font-size: 18px; line-height: 1.4; } .quote figcaption { gap: 0; } }

/* Etiqueta de la unidad real en la foto del hero */
.hero-photo { position: relative; }
.hero-photo::after { content: ""; position: absolute; inset: 55% 0 0 0; background: linear-gradient(to top, rgba(8,8,9,.82), rgba(8,8,9,0)); pointer-events: none; z-index: 1; }
.hero-photo > .hero-tag { position: absolute; max-width: none; left: 16px; right: 16px; bottom: 16px; z-index: 2; display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 2px 16px; padding: 14px 16px; border: 1px solid rgba(255,255,255,.14); border-radius: var(--r-md, 10px); background: rgba(12,12,13,.55); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); color: #f2f2f2; text-decoration: none; transition: border-color .2s ease, background .2s ease; }
.hero-tag:hover, .hero-tag:focus-visible { border-color: rgba(255,255,255,.35); background: rgba(12,12,13,.7); }
.hero-tag__state { grid-column: 1; font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: rgba(242,242,242,.62); }
.hero-tag__name { grid-column: 1; font-size: 17px; font-weight: 500; line-height: 1.25; }
.hero-tag__price { grid-column: 2; grid-row: 1 / span 2; display: inline-flex; align-items: center; gap: 8px; font-size: 17px; font-weight: 500; white-space: nowrap; }
.hero-tag .m-arrow { width: 12px; height: 12px; fill: none; stroke: currentColor; stroke-width: 1.5; }
@media (max-width: 639px) { .hero-photo > .hero-tag { left: 12px; right: 12px; bottom: 12px; padding: 12px 14px; } .hero-tag__name, .hero-tag__price { font-size: 15px; } }
