/* Faggioli Propiedades — sitio por slides */

:root {
  --bg: #0f0f10;
  --bg-2: #171719;
  --paper: #faf7f2;
  --paper-2: #f2ebe0;
  --ink: #161616;
  --muted: #6d6862;
  --line: rgba(255, 255, 255, .12);
  --line-dark: #e5ddd0;
  --red: #d4161d;
  --red-dark: #a80f15;
  --wa: #25d366;
  --radius: 18px;
  --max: 1180px;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

* { box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  scroll-snap-type: y proximity;
  background: var(--bg);
}
body {
  margin: 0;
  font-family: "Inter", system-ui, sans-serif;
  color: var(--paper);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { font-weight: 800; letter-spacing: -.025em; line-height: 1.05; margin: 0 0 .5em; }
h1 { font-size: clamp(2.6rem, 6.4vw, 5.4rem); }
h2 { font-size: clamp(2rem, 4.2vw, 3.4rem); }
h3 { font-size: 1.35rem; letter-spacing: -.01em; }
h1 em { font-style: normal; color: var(--red); }
.wrap { max-width: var(--max); margin: 0 auto; padding: 0 22px; }

/* ---------- Slides ---------- */
.slide {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  padding: 110px 0 90px;
  scroll-snap-align: start;
  overflow: hidden;
}
.slide > .wrap { width: 100%; }

#servicios, #propiedades, #historia, #contacto {
  background: var(--paper);
  color: var(--ink);
}
#servicios { background: var(--paper); }
#propiedades { background: var(--paper-2); }
#historia { background: var(--paper); }
#contacto { background: var(--paper-2); }

/* Revelado al entrar al slide */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .8s var(--ease), transform .8s var(--ease);
  transition-delay: var(--d, 0ms);
}
.reveal.in { opacity: 1; transform: none; }

/* Barra de progreso */
.progress {
  position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 30;
}
.progress span {
  display: block; height: 100%; width: 100%;
  background: var(--red);
  transform-origin: 0 50%;
  transform: scaleX(0);
}

/* Indicador lateral de slides */
.slide-dots {
  position: fixed; right: 22px; top: 50%; transform: translateY(-50%);
  z-index: 25; display: flex; flex-direction: column; gap: 14px;
}
.slide-dots a {
  display: flex; align-items: center; justify-content: flex-end; gap: 10px;
  text-decoration: none; color: var(--paper); font-size: .72rem; font-weight: 600;
  letter-spacing: .12em; text-transform: uppercase; opacity: .55;
  transition: opacity .3s;
}
.slide-dots a::after {
  content: ""; width: 9px; height: 9px; border-radius: 50%;
  border: 1.5px solid currentColor; transition: background .3s, transform .3s;
}
.slide-dots a span { opacity: 0; transform: translateX(6px); transition: .3s var(--ease); }
.slide-dots a:hover { opacity: 1; }
.slide-dots a:hover span, .slide-dots a.active span { opacity: 1; transform: none; }
.slide-dots a.active { opacity: 1; }
.slide-dots a.active::after { background: var(--red); border-color: var(--red); transform: scale(1.25); }
.slide-dots.on-light a { color: var(--ink); }

/* ---------- Marca ---------- */
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.brand svg { width: 40px; height: 40px; flex: none; }
.brand .words { display: flex; flex-direction: column; line-height: 1; }
.brand .name { font-family: "Montserrat", sans-serif; font-style: italic; font-weight: 800; font-size: 1.5rem; color: var(--red); letter-spacing: -.01em; }
.brand .sub { font-size: .6rem; font-weight: 700; letter-spacing: .22em; color: var(--paper); align-self: flex-end; margin-top: 2px; }

/* ---------- Header ---------- */
.topbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 20;
  transition: background .4s, backdrop-filter .4s, border-color .4s;
  border-bottom: 1px solid transparent;
}
.topbar.scrolled {
  background: rgba(15, 15, 16, .86);
  backdrop-filter: blur(10px);
  border-bottom-color: var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 76px; gap: 16px; position: relative; }
.nav ul { display: flex; gap: 30px; list-style: none; margin: 0; padding: 0; }
.nav ul a { text-decoration: none; color: var(--paper); opacity: .8; font-weight: 500; font-size: .95rem; }
.nav ul a:hover { opacity: 1; color: var(--red); }
.nav-actions { display: flex; align-items: center; gap: 10px; }
.nav-toggle {
  display: none; width: 42px; height: 42px; border-radius: 12px; border: 1px solid var(--line);
  background: rgba(255,255,255,.06); cursor: pointer; align-items: center; justify-content: center; padding: 0;
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
  display: block; width: 20px; height: 2px; background: var(--paper); position: relative; transition: transform .2s, opacity .2s;
}
.nav-toggle span::before, .nav-toggle span::after { content: ""; position: absolute; left: 0; }
.nav-toggle span::before { top: -6px; }
.nav-toggle span::after { top: 6px; }
.nav-toggle[aria-expanded="true"] span { background: transparent; }
.nav-toggle[aria-expanded="true"] span::before { top: 0; transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] span::after { top: 0; transform: rotate(-45deg); }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 26px; border-radius: 999px; cursor: pointer;
  background: var(--red); color: #fff; text-decoration: none; font: inherit; font-weight: 700;
  border: 2px solid var(--red); transition: transform .2s var(--ease), background .2s, box-shadow .2s;
  box-shadow: 0 10px 30px -10px rgba(212, 22, 29, .6);
}
.btn:hover { transform: translateY(-2px); background: var(--red-dark); border-color: var(--red-dark); }
.btn-sm { padding: 10px 18px; font-size: .9rem; box-shadow: none; }
.btn.ghost { background: transparent; box-shadow: none; border-color: rgba(255,255,255,.7); color: #fff; }
.btn.ghost:hover { background: #fff; color: var(--ink); border-color: #fff; }
.btn.ghost-dark { background: transparent; color: var(--ink); border-color: var(--ink); box-shadow: none; }
.btn.ghost-dark:hover { background: var(--ink); color: #fff; border-color: var(--ink); }
.btn-wa {
  margin-top: auto; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 18px; border-radius: 999px; background: var(--wa); color: #fff; font-weight: 700; text-decoration: none;
  transition: transform .2s var(--ease), background .2s;
}
.btn-wa:hover { background: #1ebe5a; transform: translateY(-2px); }

.eyebrow { color: var(--red); font-weight: 700; letter-spacing: .18em; text-transform: uppercase; font-size: .76rem; margin: 0 0 14px; }
.lead { font-size: 1.12rem; color: var(--muted); max-width: 60ch; }
.slide.hero .lead, #propiedades .lead { color: rgba(255,255,255,.78); }
#propiedades .lead { color: var(--muted); }
.rule { width: 64px; height: 3px; background: var(--red); border: 0; margin: 22px 0; }

/* ---------- Hero ---------- */
.hero { background: var(--bg); color: #fff; }
.hero-bg { position: absolute; inset: 0; }
.hero-bg img {
  width: 100%; height: 100%; object-fit: cover;
  transform: scale(1.08); animation: drift 22s var(--ease) infinite alternate;
  filter: saturate(.85) contrast(1.05);
}
.hero-bg::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(15,15,16,.94) 0%, rgba(15,15,16,.7) 45%, rgba(15,15,16,.35) 100%),
    linear-gradient(0deg, rgba(15,15,16,.9) 0%, transparent 40%);
}
@keyframes drift { to { transform: scale(1.02) translate3d(-1%, 0, 0); } }
.hero-content { position: relative; z-index: 1; }
.hero h1 { max-width: 13ch; }
.hero .actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 34px; }
.scroll-hint {
  position: absolute; left: 50%; bottom: 26px; transform: translateX(-50%); z-index: 1;
  width: 44px; height: 44px; border-radius: 50%; border: 1px solid rgba(255,255,255,.4);
  display: grid; place-items: center; text-decoration: none; color: #fff;
  animation: bob 2.2s ease-in-out infinite;
}
@keyframes bob { 50% { transform: translate(-50%, 6px); } }

/* ---------- Servicios ---------- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 48px; }
.card {
  background: #fff; border: 1px solid var(--line-dark); border-radius: var(--radius);
  padding: 32px 28px; display: flex; flex-direction: column;
  transition: transform .35s var(--ease), box-shadow .35s var(--ease);
}
.card:hover { transform: translateY(-6px); box-shadow: 0 30px 60px -30px rgba(0,0,0,.25); }
.card .icon {
  width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center;
  background: var(--red); color: #fff; margin-bottom: 20px;
}
.card p { color: var(--muted); margin: 0 0 22px; }
.card .tel { font-weight: 700; margin: -10px 0 18px; font-size: .95rem; }

/* ---------- Propiedades ---------- */
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 28px; flex-wrap: wrap; }
.filters { display: flex; gap: 10px; flex-wrap: wrap; margin: 36px 0 24px; }
.chip {
  border: 1px solid var(--ink); background: transparent; color: var(--ink); border-radius: 999px;
  padding: 8px 18px; font: inherit; font-size: .9rem; font-weight: 600; cursor: pointer;
  transition: background .2s, color .2s;
}
.chip .n { opacity: .55; margin-left: 4px; font-weight: 500; }
.chip[aria-selected="true"], .chip:hover { background: var(--ink); color: #fff; }
.listings {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 22px;
}
.listing {
  background: #fff; border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column;
  border: 1px solid var(--line-dark); transition: transform .35s var(--ease), box-shadow .35s var(--ease);
}
.listing:hover { transform: translateY(-5px); box-shadow: 0 28px 50px -28px rgba(0,0,0,.35); }
.listing .ph { position: relative; aspect-ratio: 4 / 3; background: var(--ink); overflow: hidden; }
.listing .ph img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.listing:hover .ph img { transform: scale(1.05); }
.listing .tag {
  position: absolute; left: 12px; top: 12px; background: var(--red); color: #fff;
  font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  padding: 5px 10px; border-radius: 999px;
}
.listing .body { padding: 18px 20px 20px; display: flex; flex-direction: column; flex: 1; }
.listing .price { font-size: 1.5rem; font-weight: 800; letter-spacing: -.02em; margin: 0; }
.listing .exp { font-size: .85rem; color: var(--muted); margin: 0 0 10px; }
.listing .feat { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: .88rem; font-weight: 600; margin: 4px 0 12px; }
.listing .addr { font-weight: 700; font-size: .98rem; margin: 0; }
.listing .barrio { color: var(--muted); font-size: .9rem; margin: 0 0 10px; }
.listing .desc {
  font-size: .86rem; color: var(--muted); margin: 0 0 16px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.listing .acts { margin-top: auto; display: flex; gap: 8px; }
.listing .acts .btn { flex: 1; padding: 11px 14px; font-size: .9rem; box-shadow: none; }
.listing .acts .btn-zp { flex: 1; padding: 11px 14px; font-size: .9rem; background: transparent; color: var(--ink); border-color: var(--line-dark); box-shadow: none; }
.listing .acts .btn-zp:hover { background: var(--ink); color: #fff; border-color: var(--ink); }
.listing.hide { display: none; }
.listing-note { font-size: .82rem; color: var(--muted); margin-top: 22px; }

/* ---------- Historia ---------- */
.history { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.motto { font-family: "Montserrat", sans-serif; font-style: italic; font-weight: 800; font-size: 1.4rem; line-height: 1.4; margin: 0 0 10px; color: var(--ink); }
.motto small { display: block; font-family: "Inter", sans-serif; font-style: normal; font-size: .72rem; letter-spacing: .24em; text-transform: uppercase; color: var(--muted); margin-top: 8px; }
.history-photos { border-radius: var(--radius); overflow: hidden; box-shadow: 0 30px 60px -30px rgba(0,0,0,.4); }
.history-photos img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4 / 5; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 64px; }
.stat { border-top: 3px solid var(--red); padding-top: 18px; }
.stat strong { display: block; font-size: clamp(2rem, 4vw, 3rem); font-weight: 800; letter-spacing: -.03em; line-height: 1.05; }
.stat span { color: var(--muted); }

/* ---------- Contacto ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: 44px; margin-top: 44px; }
.contact-list { list-style: none; padding: 0; margin: 0 0 26px; }
.contact-list li { padding: 14px 0; border-bottom: 1px solid var(--line-dark); }
.contact-list b { display: block; font-size: .74rem; text-transform: uppercase; letter-spacing: .12em; color: var(--muted); font-weight: 700; }
.contact-list a { text-decoration: none; font-weight: 600; }
.contact-list .wa-link { display: inline-flex; align-items: center; gap: 6px; color: #128c4a; }
.horario { display: block; }
form#contact-form {
  background: #fff; border: 1px solid var(--line-dark); border-radius: var(--radius); padding: 30px; display: grid; gap: 16px; align-content: start;
}
.hp-field { position: absolute; width: 1px; height: 1px; overflow: hidden; opacity: 0; left: -9999px; }
label { font-size: .9rem; font-weight: 600; display: grid; gap: 6px; }
input, select, textarea {
  font: inherit; padding: 13px 15px; border-radius: 12px; border: 1px solid var(--line-dark); background: var(--paper); color: var(--ink);
}
input:focus, select:focus, textarea:focus { outline: 2px solid var(--red); outline-offset: 1px; }
textarea { min-height: 110px; resize: vertical; }
.map { margin-top: 44px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line-dark); }
.map iframe { width: 100%; height: 320px; border: 0; display: block; }
.map-placeholder { height: 320px; display: flex; align-items: center; justify-content: center; text-align: center; padding: 0 30px; background: var(--paper-2); }
.map-placeholder p { color: var(--muted); font-size: .92rem; max-width: 46ch; }
.map-placeholder a { color: var(--red); font-weight: 600; }

/* ---------- Banner de cookies ---------- */
.cookie-banner {
  position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 60;
  max-width: 560px; margin: 0 auto;
  background: #0a0a0b; color: rgba(255,255,255,.92);
  border-radius: var(--radius); padding: 18px 22px;
  display: flex; flex-wrap: wrap; align-items: center; gap: 14px;
  box-shadow: 0 12px 30px rgba(0,0,0,.25);
}
.cookie-banner p { margin: 0; font-size: .88rem; flex: 1 1 220px; }
.cookie-banner p a { text-decoration: underline; }
.cookie-banner[hidden] { display: none; }
.cookie-actions { display: flex; gap: 10px; flex: 0 0 auto; }
.cookie-actions .btn-sm { padding: 9px 16px; font-size: .82rem; }

/* ---------- Footer ---------- */
footer { background: #0a0a0b; color: rgba(255,255,255,.7); padding: 42px 0; font-size: .9rem; }
.footer-grid { display: flex; justify-content: space-between; align-items: center; gap: 20px; flex-wrap: wrap; }
footer a { color: inherit; }
.footer-grid .credit { font-size: .76rem; opacity: .55; flex-basis: 100%; text-align: center; order: 99; }
@media (max-width: 640px) {
  .footer-grid { flex-direction: column; align-items: center; text-align: center; gap: 14px; }
}

/* ---------- Flotante WhatsApp ---------- */
.wa {
  position: fixed; right: 20px; bottom: 20px; z-index: 22;
  width: 58px; height: 58px; border-radius: 50%; background: var(--wa); color: #fff;
  display: grid; place-items: center; box-shadow: 0 10px 28px rgba(0,0,0,.35);
  transition: transform .2s var(--ease);
}
.wa:hover { transform: scale(1.06); }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .listings { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 900px) {
  .history, .contact-grid { grid-template-columns: 1fr; gap: 36px; }
  .cards { grid-template-columns: 1fr; }
  .listings { grid-template-columns: repeat(2, 1fr); }
  .slide-dots { display: none; }
  .nav-toggle { display: flex; }
  .nav ul {
    display: flex; flex-direction: column; gap: 0; position: absolute; left: 0; right: 0; top: 76px;
    background: var(--bg); border-bottom: 1px solid var(--line); padding: 6px 22px 16px;
    max-height: 0; overflow: hidden; transition: max-height .3s ease;
  }
  .nav.open ul { max-height: 340px; }
  .nav ul li { border-top: 1px solid var(--line); }
  .nav ul li:first-child { border-top: 0; }
  .nav ul a { display: block; padding: 14px 2px; opacity: 1; }
}
@media (max-width: 640px) {
  .slide { min-height: auto; padding: 96px 0 72px; }
  .slide.hero { min-height: 100svh; }
  .listings { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr; gap: 18px; }
  .nav-actions .btn-sm { display: none; }
  .brand .name { font-size: 1.3rem; }
  .brand svg { width: 34px; height: 34px; }
  form#contact-form { padding: 22px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero-bg img, .scroll-hint { animation: none; }
}

/* ---------- Página de propuesta (propuesta.html) ---------- */
body.doc-page { background: var(--paper); color: var(--ink); }
body.doc-page .topbar { background: rgba(15, 15, 16, .92); }
.doc { padding-top: 130px; padding-bottom: 90px; max-width: 860px; }
.doc h1 { font-size: clamp(2rem, 4.5vw, 3rem); }
.doc-sec { margin-top: 44px; }
.doc-sec h2 { font-size: 1.6rem; }
.doc-sec p, .doc-sec li { color: #2b2825; }
.doc-sec ol, .doc-sec ul { padding-left: 22px; }
.doc-sec li { margin-bottom: 10px; }
.table-wrap { overflow-x: auto; }
.doc table { width: 100%; border-collapse: collapse; background: #fff; border-radius: var(--radius); overflow: hidden; }
.doc th, .doc td { text-align: left; padding: 14px 16px; border-bottom: 1px solid var(--line-dark); font-size: .95rem; }
.doc th { background: var(--paper-2); font-weight: 700; }
body.doc-page footer { margin-top: 40px; }
.benefits { list-style: none; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.benefits li { background: #fff; border: 1px solid var(--line-dark); border-radius: var(--radius); padding: 18px 20px; margin: 0; }
@media (max-width: 640px) { .benefits { grid-template-columns: 1fr; } }
@media (max-width: 640px) {
  .doc th, .doc td { padding: 12px 10px; font-size: .86rem; }
  .doc td:nth-child(2), .doc th:nth-child(2) { white-space: nowrap; }
}

/* ---------- Logo del cliente (imagen completa) ---------- */
.brand-img { display: inline-flex; align-items: center; }
.brand-img .logo-cliente { height: 84px; width: auto; display: block; border-radius: 6px; }
.nav { height: 100px; }
footer .brand-img .logo-cliente { height: 64px; }

/* Mobile: sin el "Caballito · Desde 1965" de la portada y el texto de la portada sube */
@media (max-width: 640px) {
  .slide.hero { align-items: flex-start; padding-top: 118px; }
  .brand-img .logo-cliente { height: 46px; }
  .nav { height: 76px; }
}
