/* =========================================================================
   Inmobiliaria Alacant · Demo Escoda Project
   Identidad: marca verde real del cliente + tono cálido, local y humano.
   Titulares en serif (Bitter) para un aire de negocio establecido, no plantilla.
   ========================================================================= */

:root {
  /* Marca del cliente (verde) */
  --verde:        #4f9e34;
  --verde-vivo:   #6cc047;
  --verde-oscuro: #2c6626;
  --verde-noche:  #1a3a1a;

  /* Seguros J.MIR / Occident */
  --rojo:     #e2001a;
  --rojo-osc: #b30016;

  /* Neutros cálidos (papel) */
  --tinta:   #1c241c;
  --gris:    #55605a;
  --gris-cl: #8b938a;
  --linea:   #e7e2d6;
  --fondo:   #fffdf8;
  --fondo-2: #f5f1e7;   /* crema */
  --fondo-3: #edeee4;

  --radio:   14px;
  --radio-s: 10px;
  --radio-l: 22px;
  --sombra:   0 1px 2px rgba(28,36,28,.05), 0 10px 30px rgba(28,36,28,.07);
  --sombra-f: 0 18px 44px rgba(28,36,28,.16);
  --ancho:   1120px;
  --paso:    clamp(3.6rem, 8vw, 6rem);

  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --serif: "Bitter", Georgia, "Times New Roman", serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; -webkit-text-size-adjust: 100%; }
body { font-family: var(--sans); color: var(--tinta); background: var(--fondo); line-height: 1.62; font-size: 16px; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }

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

.contenedor { width: 100%; max-width: var(--ancho); margin-inline: auto; padding-inline: clamp(1.15rem, 4vw, 2.2rem); }
.seccion { padding-block: var(--paso); }
.seccion--crema { background: var(--fondo-2); }

.saltar { position: absolute; left: -999px; top: 0; background: var(--verde-oscuro); color: #fff; padding: .7rem 1rem; border-radius: 0 0 8px 0; z-index: 200; }
.saltar:focus { left: 0; }
:focus-visible { outline: 3px solid var(--verde); outline-offset: 2px; border-radius: 4px; }

/* --------------------------- Tipografía utilidades --------------------------- */
.kicker { font-family: var(--sans); font-weight: 600; font-size: .76rem; letter-spacing: .16em; text-transform: uppercase; color: var(--verde-oscuro); display: inline-flex; align-items: center; gap: .6rem; }
.kicker::before { content: ""; width: 24px; height: 2px; background: var(--verde); border-radius: 2px; }
.plomo { color: var(--gris); }

.cab-seccion { max-width: 620px; margin-bottom: 2.8rem; }
.cab-seccion.centrado { margin-inline: auto; text-align: center; }
.cab-seccion h2 { font-size: clamp(1.85rem, 4.6vw, 2.6rem); margin: .8rem 0 .7rem; }
.cab-seccion p { font-size: 1.06rem; color: var(--gris); }

/* --------------------------- Botones --------------------------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .55rem; font-family: var(--sans); font-weight: 600; font-size: .98rem; padding: .82rem 1.35rem; border-radius: 10px; border: 1.5px solid transparent; transition: transform .14s ease, box-shadow .2s ease, background .2s ease, border-color .2s ease; white-space: nowrap; }
.btn:active { transform: translateY(1px); }
.btn svg { width: 19px; height: 19px; flex: none; }

.btn--wa { background: #1fab53; color: #fff; box-shadow: 0 8px 20px rgba(31,171,83,.28); }
.btn--wa:hover { background: #1c9a4b; box-shadow: 0 10px 24px rgba(31,171,83,.36); }
.btn--primario { background: var(--verde-oscuro); color: #fff; box-shadow: 0 8px 20px rgba(44,102,38,.26); }
.btn--primario:hover { background: #245420; box-shadow: var(--sombra-f); }
.btn--fantasma { background: transparent; color: var(--tinta); border-color: var(--linea); }
.btn--fantasma:hover { border-color: var(--verde); background: rgba(79,158,52,.06); }
.btn--claro { background: #fff; color: var(--verde-oscuro); }
.btn--claro:hover { background: var(--fondo-2); }
.btn--rojo { background: var(--rojo); color: #fff; box-shadow: 0 8px 20px rgba(226,0,26,.24); }
.btn--rojo:hover { background: var(--rojo-osc); box-shadow: 0 10px 26px rgba(226,0,26,.32); }
.btn--lg { padding: .98rem 1.6rem; font-size: 1.04rem; }
.btn--bloque { width: 100%; }

/* --------------------------- Cabecera --------------------------- */
.cabecera { position: sticky; top: 0; z-index: 100; background: rgba(255,253,248,.9); backdrop-filter: saturate(150%) blur(10px); border-bottom: 1px solid var(--linea); }
.cabecera-int { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 64px; }

.marca { display: inline-flex; align-items: center; gap: .58rem; }
.marca-icono { width: 40px; height: 40px; flex: none; border-radius: 10px; background: var(--verde); display: grid; place-items: center; }
.marca-icono svg { width: 25px; height: 25px; }
.marca-texto { display: flex; flex-direction: column; line-height: 1.05; }
.marca-texto small { font-family: var(--sans); font-weight: 500; font-size: .6rem; letter-spacing: .12em; color: var(--verde-oscuro); text-transform: uppercase; }
.marca-texto b { font-family: var(--serif); font-weight: 700; font-size: 1.24rem; letter-spacing: .01em; color: var(--tinta); }
.marca-texto b i { font-style: normal; color: var(--verde); }

.cab-acciones { display: flex; align-items: center; gap: .6rem; }
.idioma { display: inline-flex; background: var(--fondo-3); border-radius: 999px; padding: 3px; gap: 2px; }
.idioma button { border: none; background: transparent; font-family: var(--sans); font-weight: 700; font-size: .76rem; letter-spacing: .04em; color: var(--gris); padding: .34rem .6rem; border-radius: 999px; transition: .18s; }
.idioma button[aria-pressed="true"] { background: #fff; color: var(--verde-oscuro); box-shadow: var(--sombra); }
.cab-tel { display: none; }

/* --------------------------- Cinta demo --------------------------- */
.demo-cinta { background: var(--verde-noche); color: #cfe3c4; text-align: center; font-size: .74rem; letter-spacing: .02em; padding: .48rem 1rem; }
.demo-cinta b { color: #fff; font-weight: 700; letter-spacing: .08em; }

/* --------------------------- HERO --------------------------- */
.hero { position: relative; background: var(--verde-noche); color: #fff; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; background: radial-gradient(130% 90% at 108% -10%, rgba(108,192,71,.22), transparent 55%); pointer-events: none; }
/* silueta de sierra muy sutil, dibujada a línea (guiño al logo, sin cliché de ola) */
.hero::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 130px; background:
  url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 130' preserveAspectRatio='none'%3E%3Cpath d='M0 130 L250 52 L470 104 L700 38 L940 100 L1180 46 L1440 96' fill='none' stroke='%23ffffff' stroke-opacity='0.06' stroke-width='2'/%3E%3C/svg%3E") bottom/cover no-repeat;
  pointer-events: none; }
.hero-int { position: relative; z-index: 2; display: grid; gap: 2.4rem; padding-block: clamp(2.6rem, 7vw, 4.6rem) clamp(3rem, 8vw, 5rem); }
.hero-txt { max-width: 34rem; }
.hero .kicker { color: #a9e08c; }
.hero .kicker::before { background: var(--verde-vivo); }
.hero h1 { color: #fff; font-size: clamp(2.15rem, 6.2vw, 3.35rem); margin: 1rem 0 1.1rem; line-height: 1.1; }
.hero h1 em { font-style: normal; color: var(--verde-vivo); }
.hero-sub { font-size: clamp(1.04rem, 2.4vw, 1.2rem); color: #dbe7d2; line-height: 1.6; margin-bottom: 1.8rem; }
.hero-ctas { display: flex; flex-wrap: wrap; gap: .7rem; }
.hero-nota { display: flex; align-items: center; gap: .6rem; margin-top: 1.7rem; font-size: .92rem; color: #cadcbf; }
.puntos { display: inline-flex; align-items: center; gap: 5px; flex: none; }
.puntos i { width: 9px; height: 9px; border-radius: 50%; display: block; }
.puntos i:first-child { background: var(--verde-vivo); }
.puntos i:last-child { background: var(--rojo); }

/* Foto real enmarcada (nítida: se muestra ~a su tamaño original) */
.hero-foto { position: relative; justify-self: start; max-width: 460px; width: 100%; background: #fff; padding: 10px 10px 12px; border-radius: 12px; box-shadow: 0 22px 50px rgba(0,0,0,.4); transform: rotate(-1deg); }
.hero-foto img { width: 100%; border-radius: 6px; aspect-ratio: 410/293; object-fit: cover; }
.hero-foto figcaption { font-family: var(--sans); font-size: .8rem; color: var(--gris); padding: .55rem .2rem .1rem; display: flex; align-items: center; gap: .4rem; }
.hero-foto figcaption::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--verde); }

/* --------------------------- Franja de refuerzo (plana) --------------------------- */
.franja { background: var(--fondo); border-bottom: 1px solid var(--linea); }
.franja-int { display: grid; grid-template-columns: 1fr; }
.franja-item { display: flex; align-items: center; gap: .7rem; padding: 1.1rem 0; font-size: .96rem; color: var(--tinta); border-bottom: 1px solid var(--linea); }
.franja-item:last-child { border-bottom: none; }
.franja-item svg { width: 20px; height: 20px; color: var(--verde); flex: none; }

/* --------------------------- Servicios --------------------------- */
.rejilla { display: grid; grid-template-columns: 1fr; gap: 1rem; }
.tarjeta { position: relative; background: var(--fondo); border: 1px solid var(--linea); border-radius: var(--radio); padding: 1.7rem 1.5rem 1.5rem; transition: transform .16s ease, box-shadow .2s ease, border-color .2s; }
.tarjeta:hover { transform: translateY(-3px); box-shadow: var(--sombra-f); border-color: rgba(79,158,52,.4); }
.tarjeta-num { position: absolute; top: 1.2rem; right: 1.3rem; font-family: var(--serif); font-size: 1rem; color: var(--gris-cl); }
.tarjeta-ic { color: var(--verde-oscuro); margin-bottom: .9rem; }
.tarjeta-ic svg { width: 30px; height: 30px; }
.tarjeta h3 { font-size: 1.2rem; margin-bottom: .4rem; }
.tarjeta p { color: var(--gris); font-size: .96rem; }
.nota-pie { margin-top: 1.5rem; font-size: .88rem; color: var(--gris-cl); }

/* --------------------------- Propietarios --------------------------- */
.propietarios { background: var(--verde-noche); color: #fff; border-radius: var(--radio-l); padding: clamp(2.1rem, 5vw, 3.4rem); }
.propietarios-int { max-width: 560px; }
.propietarios .kicker { color: #b5e79b; }
.propietarios .kicker::before { background: var(--verde-vivo); }
.propietarios h2 { color: #fff; font-size: clamp(1.6rem, 4vw, 2.25rem); margin: .8rem 0 .8rem; }
.propietarios p { color: #d7eec9; margin-bottom: 1.6rem; }

/* --------------------------- Seguros (bloque J.MIR, rojo/blanco) --------------------------- */
.seguros { display: grid; grid-template-columns: 1fr; gap: 1.8rem; align-items: center; background: #fff; border: 1px solid var(--linea); border-top: 5px solid var(--rojo); border-radius: var(--radio); padding: clamp(1.6rem, 4vw, 2.4rem); box-shadow: var(--sombra); }
.seguros .kicker { color: var(--rojo-osc); }
.seguros .kicker::before { background: var(--rojo); }
.seguros h3 { font-size: clamp(1.4rem, 3.3vw, 1.7rem); margin: .8rem 0 .6rem; }
.seguros p { color: var(--gris); margin-bottom: 1.2rem; }
.jmir-marca { display: inline-flex; align-items: baseline; gap: .5rem; font-family: var(--serif); font-weight: 700; font-size: 1.15rem; color: #111; letter-spacing: .01em; }
.jmir-marca em { font-style: normal; color: var(--rojo); }
.jmir-occ { display: inline-flex; align-items: center; gap: .35rem; margin-top: .5rem; font-family: var(--sans); font-weight: 600; font-size: .82rem; letter-spacing: .03em; color: var(--rojo); text-transform: uppercase; }
.jmir-occ span { width: 13px; height: 13px; background: var(--rojo); border-radius: 3px 3px 3px 0; transform: rotate(-8deg); display: block; }
.seguros-lado { text-align: center; }
.jmir-foto { width: 170px; height: 170px; border-radius: 50%; object-fit: cover; margin: 0 auto .9rem; border: 4px solid #fff; box-shadow: 0 10px 26px rgba(0,0,0,.14), 0 0 0 1px var(--linea); }
.jmir-foto-cap { font-size: .82rem; color: var(--gris); margin-bottom: 1.1rem; }

/* --------------------------- Nosotros (editorial, sin foto) --------------------------- */
.nosotros { max-width: 760px; }
.nosotros h2 { font-size: clamp(1.8rem, 4.4vw, 2.5rem); margin: .8rem 0 1rem; }
.nosotros p { color: var(--gris); font-size: 1.06rem; margin-bottom: 1rem; }
.valores { display: grid; grid-template-columns: 1fr; gap: 1.2rem; margin-top: 2rem; border-top: 1px solid var(--linea); padding-top: 1.8rem; }
.valor { display: flex; gap: .7rem; align-items: flex-start; }
.valor svg { width: 22px; height: 22px; color: var(--verde); flex: none; margin-top: 2px; }
.valor b { font-family: var(--serif); font-size: 1.02rem; display: block; margin-bottom: .1rem; }
.valor span { font-size: .92rem; color: var(--gris); }

/* --------------------------- Contacto --------------------------- */
.contacto { display: grid; grid-template-columns: 1fr; gap: 1.6rem; }
.contacto-datos { background: var(--fondo); border: 1px solid var(--linea); border-radius: var(--radio); padding: 1.6rem; }
.dato { display: flex; gap: .9rem; align-items: flex-start; padding: .95rem 0; border-bottom: 1px solid var(--linea); }
.dato:last-child { border-bottom: none; }
.dato-ic { width: 42px; height: 42px; border-radius: 10px; background: var(--fondo-2); color: var(--verde-oscuro); display: grid; place-items: center; flex: none; }
.dato-ic svg { width: 20px; height: 20px; }
.dato small { display: block; font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--gris-cl); font-weight: 600; margin-bottom: .12rem; }
.dato a, .dato b { font-family: var(--sans); font-weight: 600; font-size: 1.02rem; color: var(--tinta); word-break: break-word; }
.dato a:hover { color: var(--verde-oscuro); }
.dato .apunte { font-family: var(--sans); font-weight: 400; font-size: .82rem; color: var(--gris); display: block; margin-top: .18rem; }
.contacto-ctas { display: flex; flex-direction: column; gap: .7rem; margin-top: 1.1rem; }
.mapa { border: 1px solid var(--linea); border-radius: var(--radio); overflow: hidden; box-shadow: var(--sombra); min-height: 320px; }
.mapa iframe { width: 100%; height: 100%; min-height: 340px; border: 0; display: block; }

/* --------------------------- Pie --------------------------- */
.pie { background: var(--verde-noche); color: #cfe3c4; padding-block: 2.8rem 6.5rem; }
.pie-int { display: grid; gap: 1.6rem; }
.pie .marca-icono { background: var(--verde); }
.pie .marca-texto b { color: #fff; }
.pie .marca-texto b i { color: var(--verde-vivo); }
.pie .marca-texto small { color: #9cc489; }
.pie-nota { font-size: .87rem; color: #9cc489; max-width: 42em; line-height: 1.6; }
.pie-legal { display: flex; flex-wrap: wrap; gap: 1rem; font-size: .82rem; margin-top: 1rem; }
.pie-legal a { color: #cfe3c4; display: inline-flex; align-items: center; gap: .35rem; }
.pie-legal a:hover { color: #fff; }
.pie-escoda { font-size: .85rem; }
.pie-escoda a { color: #fff; font-weight: 600; }
.pie-escoda a:hover { color: var(--verde-vivo); }

/* --------------------------- WhatsApp flotante --------------------------- */
.wa-flota { position: fixed; right: 16px; bottom: 84px; z-index: 90; width: 56px; height: 56px; border-radius: 50%; background: #1fab53; color: #fff; display: grid; place-items: center; box-shadow: 0 10px 28px rgba(31,171,83,.45); transition: transform .16s ease; }
.wa-flota:hover { transform: scale(1.06); }
.wa-flota svg { width: 30px; height: 30px; }

/* --------------------------- Nav inferior móvil --------------------------- */
.nav-movil { position: fixed; left: 0; right: 0; bottom: 0; z-index: 95; background: rgba(255,253,248,.95); backdrop-filter: blur(10px); border-top: 1px solid var(--linea); display: flex; justify-content: space-around; padding: .35rem .3rem calc(.35rem + env(safe-area-inset-bottom)); }
.nav-movil a { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: .66rem; font-weight: 600; color: var(--gris); padding: .3rem .5rem; }
.nav-movil a svg { width: 21px; height: 21px; }
.nav-movil a.on { color: var(--verde-oscuro); }

/* Marcadores demo */
.marca-demo { display: inline-block; font-size: .62rem; letter-spacing: .08em; text-transform: uppercase; font-weight: 700; color: var(--verde-oscuro); background: var(--fondo-3); border-radius: 5px; padding: .1rem .4rem; }

/* --------------------------- Responsive --------------------------- */
@media (min-width: 560px) {
  .contacto-ctas { flex-direction: row; }
  .contacto-ctas .btn { flex: 1; }
  .franja-int { grid-template-columns: repeat(3, 1fr); }
  .franja-item { border-bottom: none; border-right: 1px solid var(--linea); padding: 1.15rem 1.4rem; }
  .franja-item:first-child { padding-left: 0; }
  .franja-item:last-child { border-right: none; }
  .valores { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 720px) {
  .cab-tel { display: inline-flex; }
  .rejilla { grid-template-columns: repeat(2, 1fr); }
  .contacto { grid-template-columns: 1fr 1.1fr; }
  .pie-int { grid-template-columns: 1fr auto; align-items: end; }
  .wa-flota { bottom: 24px; width: 60px; height: 60px; }
  .nav-movil { display: none; }
  html { scroll-padding-top: 88px; }
  .pie { padding-bottom: 2.8rem; }
}

@media (min-width: 860px) {
  .hero-int { grid-template-columns: 1.08fr .92fr; align-items: center; }
  .hero-foto { justify-self: end; }
  .seguros { grid-template-columns: 1.5fr 1fr; }
}

@media (min-width: 980px) {
  .rejilla { grid-template-columns: repeat(3, 1fr); }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; }
  .hero-foto { transform: none; }
}
