/* =========================================================
   Ortiz Inmobiliaria — Propuesta de rediseño
   Estética de inmobiliaria seria y de confianza: azul marino,
   grises cálidos y un acento bronce puntual. Tipografía firme
   (Archivo) para titulares, sobria (Inter) para el cuerpo.
   Sin animaciones juguetonas, radios de borde pequeños.
   ========================================================= */

:root {
  /* Marca */
  --navy-900: #0c1e37;
  --navy-800: #122b4d;
  --navy-700: #1c3a63;
  --navy-500: #35578a;
  --navy-100: #e7ecf3;

  --gold: #a9812f;
  --gold-light: #c9a25c;

  /* Neutros */
  --ink: #1b2430;
  --ink-soft: #5b6470;
  --line: #dde2e8;
  --bg: #ffffff;
  --bg-soft: #f4f6f9;
  --bg-dark: #0a1830;
  --white: #ffffff;

  --radius: 8px;
  --radius-lg: 12px;
  --shadow-sm: 0 4px 16px rgba(12, 30, 55, .07);
  --shadow: 0 14px 34px rgba(12, 30, 55, .14);
  --shadow-lg: 0 24px 60px rgba(12, 30, 55, .22);

  --maxw: 1180px;
  --ease: cubic-bezier(.2, .7, .2, 1);

  --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-display: 'Archivo', 'Inter', system-ui, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; scroll-padding-top: 88px; overflow-x: hidden; }

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.14; font-weight: 700; letter-spacing: -.01em; }

.wrap { width: min(100% - 40px, var(--maxw)); margin-inline: auto; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-display); font-weight: 700; font-size: .78rem;
  letter-spacing: .14em; text-transform: uppercase;
  color: var(--gold);
}
.eyebrow::before { content: ''; width: 24px; height: 2px; background: var(--gold); }

.section { padding: clamp(56px, 8vw, 104px) 0; }
.section-head { max-width: 640px; margin-bottom: 46px; }
.section-head.center { margin-inline: auto; text-align: center; }
.section-head.center .eyebrow { justify-content: center; }
.section-head.center .eyebrow::before { display: none; }
.section-head.center .eyebrow::after { content: ''; width: 24px; height: 2px; background: var(--gold); }
.section-head h2 { font-size: clamp(1.85rem, 3.8vw, 2.7rem); margin: 14px 0 12px; }
.section-head p { color: var(--ink-soft); font-size: 1.03rem; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-display); font-weight: 700; font-size: .95rem;
  padding: 13px 26px; border-radius: var(--radius);
  cursor: pointer; border: 1.5px solid transparent; transition: background .22s var(--ease), color .22s, border-color .22s, transform .22s var(--ease);
  white-space: nowrap; letter-spacing: .01em;
}
.btn-primary { background: var(--navy-800); color: #fff; }
.btn-primary:hover { background: var(--navy-900); transform: translateY(-2px); }
.btn-gold { background: var(--gold); color: #fff; }
.btn-gold:hover { background: #93701f; transform: translateY(-2px); }
.btn-wa { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-wa:hover { border-color: #25D366; color: #1a8f47; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--navy-500); color: var(--navy-800); }
.btn svg { width: 18px; height: 18px; flex-shrink: 0; }

/* ---------- Header ---------- */
.header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  padding: 18px 0; background: rgba(255,255,255,.97); backdrop-filter: blur(10px);
  box-shadow: 0 2px 18px rgba(12,30,55,.06);
  transition: padding .3s var(--ease), box-shadow .3s;
}
.header.scrolled { padding: 11px 0; box-shadow: 0 6px 22px rgba(12,30,55,.1); }

.header .nav { position: relative; z-index: 5; }

.nav { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand img { height: 34px; width: auto; display: block; }

.nav-links { display: flex; align-items: center; gap: 26px; font-weight: 600; font-size: .92rem; }
.nav-links > a { color: var(--ink); transition: color .2s; position: relative; }
.nav-links > a:hover { color: var(--navy-800); }

.nav-cta { display: flex; align-items: center; gap: 10px; }
.burger { display: none; position: relative; background: none; border: 0; width: 28px; height: 28px; cursor: pointer; color: var(--navy-900); }
.burger svg { position: absolute; inset: 0; margin: auto; width: 100%; height: 100%; transition: opacity .2s; }
.burger .icon-close { opacity: 0; }
.header.menu-open .burger .icon-menu { opacity: 0; }
.header.menu-open .burger .icon-close { opacity: 1; }

/* El panel exterior es el que anima max-height: sin padding propio, porque el
   padding no se comprime por debajo de max-height y dejaría una barra visible
   tapando la cabecera incluso "cerrado". El padding real vive en .mobile-menu-inner.
   z-index por debajo de .header .nav (5) para que la marca y la hamburguesa
   (que también cierra el menú) queden siempre visibles y pulsables encima. */
.mobile-menu {
  display: none;
  position: fixed; left: 0; right: 0; top: 0; z-index: 2;
  background: var(--bg-dark); box-shadow: var(--shadow-lg);
  max-height: 0; overflow: hidden;
  transition: max-height .4s var(--ease);
}
.mobile-menu.open { max-height: 100vh; overflow-y: auto; }
.mobile-menu-inner { display: flex; flex-direction: column; gap: 2px; padding: 92px 24px 26px; }
.mm-link { padding: 14px 6px; border-bottom: 1px solid rgba(255,255,255,.1); font-weight: 600; color: rgba(255,255,255,.9); font-size: .96rem; }
.mm-cta { justify-content: center; margin-top: 16px; }

@media (max-width: 900px) {
  .nav-links { display: none; }
  .nav-cta .btn-ghost { display: none; }
  .burger { display: block; }
  .mobile-menu { display: flex; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 92vh; display: flex; align-items: center;
  padding-top: 110px;
  background:
    linear-gradient(180deg, rgba(9,20,38,.72) 0%, rgba(9,20,38,.8) 55%, rgba(9,20,38,.94) 100%),
    url('img/edificio-torrejon.jpg') center 30% / cover no-repeat;
}
.hero-inner { color: #fff; max-width: 700px; position: relative; z-index: 1; }
.hero .eyebrow { color: var(--gold-light); }
.hero .eyebrow::before { background: var(--gold-light); }
.hero h1 { font-size: clamp(2.1rem, 5.2vw, 3.6rem); margin: 20px 0 18px; font-weight: 800; }
.hero h1 em { font-style: normal; color: var(--gold-light); }
.hero .lead { font-size: 1.12rem; color: rgba(255,255,255,.86); max-width: 540px; margin-bottom: 30px; font-weight: 400; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 34px; }
.hero .btn-ghost { color: #fff; border-color: rgba(255,255,255,.4); }
.hero .btn-ghost:hover { border-color: var(--gold-light); color: var(--gold-light); }

.hero-badges { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-badge {
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.18);
  border-radius: var(--radius); padding: 12px 18px; display: flex; align-items: center; gap: 12px;
  backdrop-filter: blur(6px);
}
.hero-badge .num { font-family: var(--font-display); font-weight: 800; font-size: 1.3rem; color: var(--gold-light); line-height: 1; }
.hero-badge small { display: block; color: rgba(255,255,255,.78); font-size: .76rem; margin-top: 2px; }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s var(--ease), transform .6s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.d1 { transition-delay: .07s; }
.d2 { transition-delay: .14s; }
.d3 { transition-delay: .21s; }
.d4 { transition-delay: .28s; }

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; }
}

/* ---------- Franja de zonas ---------- */
.strip { background: var(--navy-900); color: #fff; padding: 16px 0; }
.strip-inner { display: flex; flex-wrap: wrap; gap: 10px 28px; justify-content: center; align-items: center; }
.strip-label { font-family: var(--font-display); font-weight: 700; font-size: .78rem; text-transform: uppercase; letter-spacing: .1em; color: var(--gold-light); }
.strip-zones { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.strip-zones span { font-size: .92rem; color: rgba(255,255,255,.85); }

/* ---------- Quiénes somos ---------- */
.about-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }
.about-photo { border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); aspect-ratio: 4/5; }
.about-photo img { width: 100%; height: 100%; object-fit: cover; }
.about-photo-caption { font-size: .76rem; color: var(--ink-soft); margin-top: 10px; text-align: center; }
.about-text .section-head { margin-bottom: 26px; }
.about-text > p { color: var(--ink-soft); margin-bottom: 24px; font-size: 1.02rem; }
.trait-list { display: flex; flex-direction: column; gap: 0; border-top: 1px solid var(--line); }
.trait { display: flex; gap: 18px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.trait .num { font-family: var(--font-display); font-size: 1.05rem; color: var(--gold); font-weight: 700; flex-shrink: 0; width: 26px; }
.trait h4 { font-size: 1rem; margin-bottom: 4px; }
.trait p { color: var(--ink-soft); font-size: .92rem; }
@media (max-width: 880px) { .about-grid { grid-template-columns: 1fr; gap: 32px; } .about-photo { aspect-ratio: 16/9; } }

.zones { background: var(--bg-soft); }

/* ---------- Servicios ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 28px 24px; transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--navy-100); }
.card .ico {
  width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center;
  background: var(--navy-100); color: var(--navy-800); margin-bottom: 16px;
}
.card .ico svg { width: 22px; height: 22px; }
.card h3 { font-size: 1.06rem; margin-bottom: 8px; }
.card p { color: var(--ink-soft); font-size: .92rem; }
.card .badge-colegiado {
  display: inline-flex; align-items: center; gap: 6px; margin-top: 12px;
  font-size: .72rem; font-weight: 700; letter-spacing: .04em; text-transform: uppercase;
  color: var(--gold); background: #fbf4e6; padding: 5px 10px; border-radius: 999px;
}

/* ---------- Tipos de inmueble ---------- */
.type-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 18px; }
.type-card { position: relative; border-radius: var(--radius-lg); overflow: hidden; aspect-ratio: 4/3; box-shadow: var(--shadow-sm); }
.type-card img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.type-card:hover img { transform: scale(1.05); }
.type-card-label {
  position: absolute; inset: auto 0 0 0; padding: 18px;
  background: linear-gradient(180deg, transparent, rgba(9,20,38,.92));
  color: #fff;
}
.type-card-label span { display: block; font-size: .7rem; text-transform: uppercase; letter-spacing: .1em; color: var(--gold-light); margin-bottom: 3px; font-weight: 700; }
.type-card-label h3 { font-size: 1.06rem; color: #fff; }
.type-note { text-align: center; margin-top: 28px; color: var(--ink-soft); font-size: .92rem; }

/* ---------- Administración de fincas ---------- */
.admin-block { background: var(--navy-900); border-radius: var(--radius-lg); padding: clamp(32px, 5vw, 56px); color: #fff; position: relative; overflow: hidden; }
.admin-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
.admin-badge {
  display: inline-flex; align-items: center; gap: 8px; margin-bottom: 16px;
  font-size: .75rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
  color: var(--navy-900); background: var(--gold-light); padding: 7px 14px; border-radius: 999px;
}
.admin-block h2 { color: #fff; font-size: clamp(1.7rem, 3.4vw, 2.3rem); margin-bottom: 14px; }
.admin-block p { color: rgba(255,255,255,.78); margin-bottom: 20px; }
.admin-list { list-style: none; display: grid; gap: 12px; }
.admin-list li { display: flex; gap: 10px; align-items: flex-start; color: rgba(255,255,255,.9); font-size: .95rem; }
.admin-list li::before { content: '✓'; color: var(--gold-light); font-weight: 700; flex-shrink: 0; }
@media (max-width: 820px) { .admin-grid { grid-template-columns: 1fr; gap: 24px; } }

/* ---------- Stats ---------- */
.stats { background: var(--bg-soft); border-radius: var(--radius-lg); padding: 42px 28px; border: 1px solid var(--line); }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; text-align: center; }
.stat { border-right: 1px solid var(--line); }
.stat:last-child { border-right: 0; }
.stats .num { font-family: var(--font-display); font-size: clamp(1.8rem, 3.4vw, 2.4rem); font-weight: 800; color: var(--navy-800); }
.stats .lbl { color: var(--ink-soft); font-size: .84rem; margin-top: 6px; }
@media (max-width: 720px) { .stats-grid { grid-template-columns: repeat(2, 1fr); } .stat { border-right: 0; border-bottom: 1px solid var(--line); padding-bottom: 16px; } }

/* ---------- Zonas de cobertura ---------- */
.coverage-grid { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.coverage-chip {
  font-family: var(--font-display); font-weight: 600; font-size: .95rem;
  background: #fff; border: 1.5px solid var(--line); border-radius: var(--radius);
  padding: 11px 20px; display: inline-flex; align-items: center; gap: 8px;
}
.coverage-chip.main { border-color: var(--gold); color: var(--navy-900); background: #fbf6ec; }

/* ---------- Contacto ---------- */
.contact-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: 36px; align-items: stretch; }
.contact-card {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: clamp(28px, 4vw, 42px);
}
.contact-card .eyebrow { margin-bottom: 14px; }
.contact-card h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); margin-bottom: 12px; }
.contact-card > p { color: var(--ink-soft); margin-bottom: 22px; }
.contact-office { margin-bottom: 22px; padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.contact-office:last-of-type { border-bottom: 0; margin-bottom: 0; padding-bottom: 0; }
.contact-office h4 { font-size: .82rem; text-transform: uppercase; letter-spacing: .08em; color: var(--gold); margin-bottom: 10px; }
.contact-line { display: flex; align-items: center; gap: 12px; padding: 7px 0; }
.contact-line .ico { width: 34px; height: 34px; border-radius: 9px; background: var(--navy-100); color: var(--navy-800); display: grid; place-items: center; flex-shrink: 0; }
.contact-line .ico svg { width: 16px; height: 16px; }
.contact-line small { display: block; color: var(--ink-soft); font-size: .74rem; }
.contact-line b { font-size: .96rem; font-weight: 600; }
.contact-actions { display: flex; gap: 12px; margin: 24px 0 20px; flex-wrap: wrap; }
.socials { display: flex; gap: 12px; }
.socials a { width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line); display: flex; align-items: center; justify-content: center; color: var(--navy-800); transition: background .2s, color .2s, border-color .2s; }
.socials a:hover { background: var(--navy-800); color: #fff; border-color: var(--navy-800); }
.socials svg { width: 17px; height: 17px; }

.map-stack { display: grid; gap: 14px; }
.map-card { border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); min-height: 150px; }
.map-card iframe { width: 100%; height: 100%; border: 0; min-height: 150px; display: block; }

@media (max-width: 900px) { .contact-grid { grid-template-columns: 1fr; } }

/* ---------- CTA final ---------- */
/* Ilustración enmarcada de la Plaza Mayor de Torrejón con la firma
   "J. Fernández Ortiz" que ya cuelga en su oficina: un fondo con marca
   propia real, no una textura genérica. */
.cta-final {
  background:
    linear-gradient(rgba(10,24,48,.93), rgba(10,24,48,.93)),
    url('img/ilustracion-torrejon.jpg') center / cover no-repeat;
}
.cta-box { text-align: center; color: #fff; }
.cta-box .eyebrow { justify-content: center; }
.cta-box .eyebrow::after { content: ''; width: 24px; height: 2px; background: var(--gold); }
.cta-box h2 { color: #fff; font-size: clamp(1.7rem, 3.4vw, 2.4rem); margin: 14px 0; font-weight: 700; }
.cta-box p { color: rgba(255,255,255,.7); max-width: 520px; margin: 0 auto 26px; }
.cta-box .btn-ghost { color: #fff; border-color: rgba(255,255,255,.35); }
.cta-box .btn-ghost:hover { border-color: var(--gold-light); color: var(--gold-light); }

/* ---------- Footer ---------- */
.footer { background: var(--navy-900); color: rgba(255,255,255,.68); padding: 50px 0 26px; }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 36px; margin-bottom: 36px; }
.footer .brand img { filter: brightness(0) invert(1); }
.footer h5 { color: #fff; font-family: var(--font-display); font-size: .86rem; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 14px; font-weight: 700; }
.footer ul { list-style: none; display: flex; flex-direction: column; gap: 9px; }
.footer p { font-size: .88rem; max-width: 32ch; margin-top: 12px; }
.footer a:hover { color: var(--gold-light); }
.footer-bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.1); font-size: .8rem; }
@media (max-width: 720px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------- Llamar flotante ---------- */
/* El negocio no publica un número de WhatsApp Business verificado (solo
   teléfono fijo y móvil de contacto), así que el botón flotante persistente
   es de llamada directa (tel:), el único canal 100% garantizado hoy mismo. */
.call-float {
  position: fixed; right: 22px; bottom: 22px; z-index: 90;
  width: 54px; height: 54px; border-radius: 50%; background: var(--navy-800); color: #fff;
  display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow);
  border: 1.5px solid rgba(255,255,255,.2); transition: transform .25s var(--ease), background .25s;
}
.call-float:hover { transform: scale(1.06); background: var(--navy-900); }
.call-float svg { width: 24px; height: 24px; }

@media (max-width: 720px) {
  .hero { padding-top: 96px; }
}
