﻿/* =========================================================
   Recurso Protección Deudores SpA — Hoja de estilos
   Paleta de marca: azul marino #123a5c · turquesa #00a591
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Lora:wght@500;600;700&family=Inter:wght@400;500;600;700&display=swap');

:root {
  /* Marca corporativa / Área Civil */
  --navy-900: #0a1f33;
  --navy-800: #0f2f4a;
  --navy-700: #123a5c;
  --navy-600: #1a4f77;
  --blue-500: #0e6f9d;

  --teal-600: #00806f;
  --teal-500: #00a591;
  --teal-400: #22c0aa;
  --teal-100: #d7f3ee;

  /* Acento del tema activo (se redefine en .theme-familia) */
  --accent-rgb: 0, 165, 145;
  --accent-deep-rgb: 0, 128, 111;
  --accent-2: var(--blue-500);
  --logo: url('../img/logo.png');

  --ink: #1c2733;
  --muted: #5b6b7c;
  --line: #e2e8ee;
  --bg: #ffffff;
  --bg-soft: #f5f8fa;
  --bg-deep: #0f2f4a;

  --radius: 14px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgba(10, 31, 51, .06), 0 4px 12px rgba(10, 31, 51, .06);
  --shadow-md: 0 10px 30px rgba(10, 31, 51, .10);
  --shadow-lg: 0 24px 60px rgba(10, 31, 51, .16);

  --container: 1180px;
  --header-h: 84px;

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

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  overflow-x: hidden; /* evita el scroll lateral que produce el panel del menú móvil cerrado */
}

body {
  margin: 0;
  max-width: 100%;
  font-family: var(--sans);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

body.no-scroll { overflow: hidden; }

img { max-width: 100%; display: block; }

a { color: var(--blue-500); text-decoration: none; }
a:hover { color: var(--teal-600); }

h1, h2, h3, h4 {
  font-family: var(--serif);
  color: var(--navy-800);
  line-height: 1.25;
  margin: 0 0 .6em;
  font-weight: 600;
}

h1 { font-size: clamp(1.9rem, 1.2rem + 2.6vw, 3rem); }
h2 { font-size: clamp(1.5rem, 1.05rem + 1.7vw, 2.25rem); }
h3 { font-size: clamp(1.15rem, 1rem + .6vw, 1.4rem); }

p { margin: 0 0 1.1em; }

ul { margin: 0; padding: 0; }

.container {
  width: min(100% - 2.5rem, var(--container));
  margin-inline: auto;
}

.section { padding: clamp(3.5rem, 7vw, 6rem) 0; }
.section--soft { background: var(--bg-soft); }
.section--deep { background: var(--bg-deep); color: #e7eef4; }
.section--deep h2, .section--deep h3 { color: #fff; }

.section-head { max-width: 720px; margin: 0 auto clamp(2rem, 4vw, 3rem); text-align: center; }
.section-head p { color: var(--muted); margin: 0; font-size: 1.05rem; }
.section--deep .section-head p { color: #b9cbdb; }

.eyebrow {
  display: inline-block;
  font-family: var(--sans);
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--teal-600);
  margin-bottom: .75rem;
}
.section--deep .eyebrow { color: var(--teal-400); }

.rule {
  width: 56px; height: 3px; border-radius: 3px;
  background: linear-gradient(90deg, var(--teal-500), var(--blue-500));
  margin: 0 0 1.4rem;
}
.section-head .rule { margin-inline: auto; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .55rem;
  padding: .85rem 1.6rem;
  border: 1px solid transparent;
  border-radius: 999px;
  font-family: var(--sans);
  font-size: .95rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease, color .18s ease, border-color .18s ease;
  text-align: center;
}
.btn:hover { transform: translateY(-2px); }
.btn svg { width: 18px; height: 18px; flex: none; }

.btn--primary { background: var(--teal-500); color: #fff; box-shadow: 0 8px 20px rgba(var(--accent-rgb), .28); }
.btn--primary:hover { background: var(--teal-600); color: #fff; box-shadow: 0 12px 26px rgba(var(--accent-rgb), .35); }

.btn--navy { background: var(--navy-700); color: #fff; }
.btn--navy:hover { background: var(--navy-800); color: #fff; }

.btn--ghost { background: transparent; color: var(--navy-700); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--teal-500); color: var(--teal-600); background: #fff; }

.btn--light { background: #fff; color: var(--navy-800); }
.btn--light:hover { background: #fff; color: var(--teal-600); }

.btn--outline-light { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .45); }
.btn--outline-light:hover { background: rgba(255, 255, 255, .12); color: #fff; border-color: #fff; }

.btn--block { width: 100%; }

/* ---------- Topbar ---------- */
.topbar {
  background: var(--navy-800);
  color: #cbdae6;
  font-size: .86rem;
}
.topbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 42px;
  padding-block: .35rem;
}
.topbar__list { display: flex; align-items: center; gap: 1.6rem; list-style: none; flex-wrap: wrap; }
.topbar__list li { display: flex; align-items: center; gap: .45rem; }
.topbar a { color: #cbdae6; }
.topbar a:hover { color: #fff; }
.topbar svg { width: 15px; height: 15px; color: var(--teal-400); flex: none; }

.topbar__social { display: flex; align-items: center; gap: .35rem; }
.topbar__social a {
  display: grid; place-items: center;
  width: 30px; height: 30px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .08);
  transition: background .18s ease;
}
.topbar__social a:hover { background: var(--teal-500); }
.topbar__social svg { width: 15px; height: 15px; color: #fff; }

/* ---------- Header ---------- */
.header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow .2s ease;
}
.header.is-stuck { box-shadow: var(--shadow-sm); }

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  min-height: var(--header-h);
}

.brand { display: flex; align-items: center; flex: none; }
.brand img { height: 52px; width: auto; }

/* Navegación desktop */
.nav { margin-left: auto; }
.nav__list { display: flex; align-items: center; gap: .25rem; list-style: none; }

.nav__link {
  display: inline-flex;
  align-items: center;
  gap: .35rem;
  padding: .65rem .9rem;
  border-radius: 8px;
  color: var(--navy-800);
  font-size: .95rem;
  font-weight: 600;
  white-space: nowrap;
  transition: color .18s ease, background .18s ease;
}
.nav__link:hover { color: var(--teal-600); background: var(--bg-soft); }
.nav__link.is-active { color: var(--teal-600); }
.nav__link.is-active::after {
  content: '';
  position: absolute;
}
.nav__item { position: relative; }
.nav__item > .nav__link.is-active {
  box-shadow: inset 0 -2px 0 var(--teal-500);
}
.nav__caret { width: 12px; height: 12px; transition: transform .2s ease; }
.nav__item:hover .nav__caret { transform: rotate(180deg); }

.nav__dropdown {
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  transform: translate(-50%, 8px);
  min-width: 290px;
  padding: .5rem;
  list-style: none;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transition: opacity .18s ease, transform .18s ease, visibility .18s;
}
.nav__item:hover .nav__dropdown,
.nav__item:focus-within .nav__dropdown {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}
.nav__dropdown::before {
  content: '';
  position: absolute;
  inset: -12px 0 auto 0;
  height: 12px;
}
.nav__dropdown a {
  display: block;
  padding: .6rem .8rem;
  border-radius: 8px;
  color: var(--ink);
  font-size: .92rem;
  font-weight: 500;
  border-left: 2px solid transparent;
}
.nav__dropdown a:hover {
  background: var(--bg-soft);
  color: var(--navy-800);
  border-left-color: var(--teal-500);
}

.header__cta { flex: none; }

/* Botón hamburguesa */
.burger {
  display: none;
  width: 46px;
  height: 46px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  padding: 0;
  place-items: center;
}
.burger span {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--navy-800);
  border-radius: 2px;
  transition: transform .25s ease, opacity .2s ease;
}
.burger span + span { margin-top: 5px; }
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Menú móvil ---------- */
.mobile-nav {
  position: fixed;
  inset: 0 0 0 auto;
  width: min(88vw, 380px);
  z-index: 120;
  background: #fff;
  transform: translateX(100%);
  transition: transform .3s cubic-bezier(.4, 0, .2, 1);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
}
.mobile-nav.is-open { transform: translateX(0); }

.mobile-nav__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--line);
}
.mobile-nav__head img { height: 42px; width: auto; }
.mobile-nav__close {
  width: 42px; height: 42px;
  display: grid; place-items: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  color: var(--navy-800);
  font-size: 1.4rem;
  line-height: 1;
}

.mobile-nav__body { padding: .75rem 1rem 1.25rem; flex: 1; }
.mobile-nav__list { list-style: none; }
.mobile-nav__list > li { border-bottom: 1px solid var(--line); }

.mobile-nav__link,
.mobile-acc__trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .5rem;
  width: 100%;
  padding: .95rem .35rem;
  font-family: var(--sans);
  font-size: 1rem;
  font-weight: 600;
  color: var(--navy-800);
  background: none;
  border: 0;
  text-align: left;
  cursor: pointer;
}
.mobile-nav__link.is-active { color: var(--teal-600); }
.mobile-acc__trigger svg { width: 14px; height: 14px; transition: transform .25s ease; color: var(--muted); }
.mobile-acc__trigger[aria-expanded="true"] svg { transform: rotate(180deg); }
.mobile-acc__trigger[aria-expanded="true"] { color: var(--teal-600); }

.mobile-acc__panel {
  max-height: 0;
  overflow: hidden;
  transition: max-height .3s ease;
}
.mobile-acc__panel ul { list-style: none; padding: 0 0 .6rem; }
.mobile-acc__panel a {
  display: block;
  padding: .55rem .35rem .55rem .95rem;
  color: var(--muted);
  font-size: .93rem;
  border-left: 2px solid var(--line);
}
.mobile-acc__panel a:hover { color: var(--teal-600); border-left-color: var(--teal-500); }

.mobile-nav__foot {
  padding: 1.25rem;
  background: var(--bg-soft);
  border-top: 1px solid var(--line);
  display: grid;
  gap: .75rem;
}
.mobile-nav__contact { font-size: .9rem; color: var(--muted); display: grid; gap: .4rem; }
.mobile-nav__contact span { display: flex; align-items: center; gap: .5rem; }
.mobile-nav__contact svg { width: 15px; height: 15px; color: var(--teal-500); flex: none; }

.overlay {
  position: fixed;
  inset: 0;
  z-index: 110;
  background: rgba(10, 31, 51, .55);
  opacity: 0;
  visibility: hidden;
  transition: opacity .3s ease, visibility .3s;
}
.overlay.is-open { opacity: 1; visibility: visible; }

/* ---------- Hero (Inicio) ---------- */
.hero { position: relative; background: var(--navy-900); overflow: hidden; }
.hero__slides { position: absolute; inset: 0; }
.hero__slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  opacity: 0;
  transform: scale(1.06);
  transition: opacity 1.1s ease, transform 6s linear;
}
.hero__slide.is-active { opacity: 1; transform: scale(1); }
.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, rgba(10, 31, 51, .94) 0%, rgba(15, 47, 74, .88) 45%, rgba(var(--accent-deep-rgb), .62) 100%);
}
.hero__inner {
  position: relative;
  z-index: 2;
  padding: clamp(4rem, 9vw, 7.5rem) 0 clamp(3.5rem, 7vw, 6rem);
  max-width: 760px;
}
.hero h1 { color: #fff; margin-bottom: 1rem; }
.hero h1 em { font-style: normal; color: var(--teal-400); }
.hero__lead { color: #cfdde8; font-size: clamp(1rem, .95rem + .35vw, 1.18rem); max-width: 620px; }
.hero__actions { display: flex; flex-wrap: wrap; gap: .85rem; margin-top: 2rem; }
.hero__dots { display: flex; gap: .5rem; margin-top: 2.75rem; }
.hero__dot {
  width: 34px; height: 4px;
  border: 0; padding: 0;
  border-radius: 3px;
  background: rgba(255, 255, 255, .3);
  cursor: pointer;
  transition: background .25s ease, width .25s ease;
}
.hero__dot.is-active { background: var(--teal-400); width: 52px; }

/* ---------- Franja de confianza ---------- */
.trust { background: #fff; border-bottom: 1px solid var(--line); }
.trust__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  margin-top: -3.25rem;
  position: relative;
  z-index: 5;
  box-shadow: var(--shadow-md);
}
.trust__item {
  background: #fff;
  padding: 1.6rem 1.35rem;
  display: flex;
  align-items: flex-start;
  gap: .9rem;
}
.trust__icon {
  flex: none;
  width: 42px; height: 42px;
  border-radius: 10px;
  display: grid; place-items: center;
  background: var(--teal-100);
  color: var(--teal-600);
}
.trust__icon svg { width: 21px; height: 21px; }
.trust__item h3 { font-family: var(--sans); font-size: .98rem; font-weight: 700; margin: 0 0 .2rem; }
.trust__item p { margin: 0; font-size: .87rem; color: var(--muted); line-height: 1.5; }

/* ---------- Áreas de práctica ---------- */
.areas { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.75rem; }
.area {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  transition: box-shadow .25s ease, transform .25s ease;
  display: flex;
  flex-direction: column;
}
.area:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); }
.area__tag {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  align-self: flex-start;
  padding: .35rem .8rem;
  border-radius: 999px;
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}
.area__tag { background: var(--teal-100); color: var(--teal-600); }
.area > p { color: var(--muted); }
.area__list { list-style: none; display: grid; gap: .1rem; margin: .5rem 0 1.5rem; }
.area__list a {
  display: flex;
  align-items: center;
  gap: .65rem;
  padding: .6rem .25rem;
  color: var(--ink);
  font-size: .95rem;
  font-weight: 500;
  border-bottom: 1px dashed var(--line);
  transition: color .18s ease, padding-left .18s ease;
}
.area__list a:hover { color: var(--teal-600); padding-left: .5rem; }
.area__list svg { width: 15px; height: 15px; color: var(--teal-500); flex: none; }
.area .btn { margin-top: auto; align-self: flex-start; }

/* ---------- Tarjetas destacadas ---------- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.75rem; }
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 2rem 1.75rem;
  display: flex;
  flex-direction: column;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: transparent; }
.card--featured {
  border-color: var(--teal-500);
  box-shadow: 0 16px 40px rgba(var(--accent-rgb), .16);
  position: relative;
}
.card--featured::before {
  content: 'Más consultado';
  position: absolute;
  top: -12px; left: 1.75rem;
  padding: .2rem .7rem;
  border-radius: 999px;
  background: var(--teal-500);
  color: #fff;
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.card__icon {
  width: 48px; height: 48px;
  border-radius: 12px;
  display: grid; place-items: center;
  background: var(--navy-700);
  color: #fff;
  margin-bottom: 1.1rem;
}
.card__icon svg { width: 24px; height: 24px; }
.card h3 { margin-bottom: .8rem; }
.card__items { list-style: none; display: grid; gap: .55rem; margin-bottom: 1.75rem; }
.card__items li {
  display: flex;
  align-items: center;
  gap: .6rem;
  font-size: .95rem;
  color: var(--muted);
}
.card__items svg { width: 16px; height: 16px; color: var(--teal-500); flex: none; }
.card .btn { margin-top: auto; }

/* ---------- Bloque "Nosotros" resumen ---------- */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
.split__media { position: relative; }
.split__media img {
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  width: 100%;
  height: 100%;
  max-height: 460px;
  object-fit: cover;
}
.split__badge {
  position: absolute;
  right: -14px;
  bottom: -22px;
  background: var(--teal-500);
  color: #fff;
  border-radius: var(--radius);
  padding: 1.1rem 1.4rem;
  box-shadow: var(--shadow-md);
  max-width: 220px;
}
.split__badge strong { display: block; font-family: var(--serif); font-size: 1.9rem; line-height: 1; }
.split__badge span { font-size: .82rem; opacity: .92; }
.split__body p { color: var(--muted); }
.check-list { list-style: none; display: grid; gap: .7rem; margin: 0 0 1.75rem; }
.check-list li { display: flex; align-items: flex-start; gap: .7rem; color: var(--ink); font-size: .97rem; }
.check-list svg { width: 20px; height: 20px; color: var(--teal-500); flex: none; margin-top: 2px; }

/* ---------- Métricas ---------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; text-align: center; }
.stat { padding: 1.25rem .75rem; border-right: 1px solid rgba(255, 255, 255, .12); }
.stat:last-child { border-right: 0; }
.stat strong {
  display: block;
  font-family: var(--serif);
  font-size: clamp(2rem, 1.4rem + 1.8vw, 2.9rem);
  color: var(--teal-400);
  line-height: 1.1;
}
.stat span { font-size: .9rem; color: #b9cbdb; }

/* ---------- FAQ ---------- */
.faq { max-width: 860px; margin-inline: auto; display: grid; gap: .9rem; }
.faq__item {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  overflow: hidden;
  transition: box-shadow .2s ease, border-color .2s ease;
}
.faq__item.is-open { border-color: var(--teal-500); box-shadow: var(--shadow-sm); }
.faq__trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
  padding: 1.15rem 1.4rem;
  background: none;
  border: 0;
  cursor: pointer;
  text-align: left;
  font-family: var(--serif);
  font-size: 1.03rem;
  font-weight: 600;
  color: var(--navy-800);
}
.faq__trigger:hover { color: var(--teal-600); }
.faq__icon {
  flex: none;
  width: 28px; height: 28px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: var(--bg-soft);
  color: var(--teal-600);
  transition: transform .25s ease, background .25s ease, color .25s ease;
}
.faq__icon svg { width: 14px; height: 14px; }
.faq__item.is-open .faq__icon { background: var(--teal-500); color: #fff; transform: rotate(180deg); }
.faq__panel { max-height: 0; overflow: hidden; transition: max-height .32s ease; }
.faq__panel p {
  margin: 0;
  padding: 0 1.4rem 1.3rem;
  color: var(--muted);
  font-size: .96rem;
  text-align: justify;
}

/* ---------- CTA final ---------- */
.cta-band {
  background: linear-gradient(120deg, var(--navy-800), var(--navy-700) 55%, var(--teal-600));
  color: #fff;
  border-radius: var(--radius);
  padding: clamp(2rem, 5vw, 3.25rem);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
  box-shadow: var(--shadow-md);
}
.cta-band h2 { color: #fff; margin-bottom: .4rem; }
.cta-band p { margin: 0; color: #d6e4ee; }
.cta-band__actions { display: flex; gap: .8rem; flex-wrap: wrap; }

/* ---------- Page hero (subpáginas) ---------- */
.page-hero {
  position: relative;
  background: var(--navy-800);
  color: #fff;
  padding: clamp(2.75rem, 6vw, 4.5rem) 0 clamp(2.5rem, 5vw, 3.5rem);
  overflow: hidden;
}
.page-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(900px 320px at 88% -10%, rgba(var(--accent-rgb), .38), transparent 62%),
    radial-gradient(600px 260px at 10% 120%, rgba(var(--accent-deep-rgb), .45), transparent 60%);
}
.page-hero__inner { position: relative; z-index: 2; max-width: 820px; }
.page-hero h1 { color: #fff; margin-bottom: .5rem; }
.page-hero p { color: #cadaea; margin: 0; max-width: 640px; }

.breadcrumb { list-style: none; display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-bottom: 1rem; font-size: .85rem; }
.breadcrumb li { display: flex; align-items: center; gap: .5rem; color: #9fb8cc; }
.breadcrumb a { color: #cadaea; }
.breadcrumb a:hover { color: var(--teal-400); }
.breadcrumb li::after { content: '/'; color: #5d7a93; }
.breadcrumb li:last-child::after { content: none; }
.breadcrumb li[aria-current] { color: var(--teal-400); font-weight: 600; }

/* ---------- Layout servicio ---------- */
.service-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: clamp(2rem, 4vw, 3.25rem);
  align-items: start;
}
.service-figure { margin: 0 0 2rem; }
.service-figure img {
  width: 100%;
  max-height: 380px;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.prose p { color: #3d4c5a; font-size: 1.03rem; text-align: justify; }
.prose h2 { margin-top: 2.25rem; }
.prose > :first-child { margin-top: 0; }

.highlight {
  border-left: 3px solid var(--teal-500);
  background: var(--bg-soft);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 1.25rem 1.5rem;
  margin: 2rem 0;
}
.highlight p { margin: 0; color: var(--navy-700); font-weight: 500; text-align: left; }

.sidebar { position: sticky; top: calc(var(--header-h) + 20px); display: grid; gap: 1.25rem; }
.sidebar__box {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.6rem;
  box-shadow: var(--shadow-sm);
}
.sidebar__box h3 { font-family: var(--sans); font-size: 1.02rem; font-weight: 700; margin-bottom: 1rem; }
.sidebar__list { list-style: none; display: grid; }
.sidebar__list a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  padding: .7rem 0;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  font-size: .93rem;
  font-weight: 500;
}
.sidebar__list li:last-child a { border-bottom: 0; }
.sidebar__list a:hover { color: var(--teal-600); }
.sidebar__list a.is-current { color: var(--teal-600); font-weight: 700; }
.sidebar__list svg { width: 14px; height: 14px; color: var(--teal-500); flex: none; }

.sidebar__box--cta {
  background: linear-gradient(150deg, var(--navy-800), var(--navy-700));
  border-color: transparent;
  color: #fff;
  text-align: center;
}
.sidebar__box--cta h3 { color: #fff; }
.sidebar__box--cta p { color: #c6d7e4; font-size: .92rem; }
.sidebar__box--cta .btn { width: 100%; }
.sidebar__box--cta .btn + .btn { margin-top: .6rem; }

/* ---------- Contacto ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: clamp(1.75rem, 3.5vw, 2.75rem);
  align-items: start;
}
.form-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.6rem, 3vw, 2.4rem);
  box-shadow: var(--shadow-sm);
}
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.1rem; }
.field { display: grid; gap: .4rem; }
.field--full { grid-column: 1 / -1; }
.field label { font-size: .86rem; font-weight: 600; color: var(--navy-800); }
.field input,
.field textarea {
  width: 100%;
  padding: .8rem 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--bg-soft);
  font-family: var(--sans);
  font-size: .95rem;
  color: var(--ink);
  transition: border-color .18s ease, box-shadow .18s ease, background .18s ease;
}
.field textarea { resize: vertical; min-height: 130px; }
.field input:focus,
.field textarea:focus {
  outline: 0;
  border-color: var(--teal-500);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(var(--accent-rgb), .12);
}
.form-note { font-size: .82rem; color: var(--muted); margin: 1rem 0 0; }

.info-card {
  background: linear-gradient(160deg, var(--navy-800), var(--navy-700));
  color: #fff;
  border-radius: var(--radius);
  padding: clamp(1.6rem, 3vw, 2.2rem);
  box-shadow: var(--shadow-md);
}
.info-card h2 { color: #fff; font-size: 1.5rem; }
.info-card > p { color: #c6d7e4; font-size: .95rem; }
.info-list { list-style: none; display: grid; gap: 1.1rem; margin: 1.75rem 0; }
.info-list li { display: flex; gap: .9rem; align-items: flex-start; }
.info-list__icon {
  flex: none;
  width: 40px; height: 40px;
  border-radius: 10px;
  display: grid; place-items: center;
  background: rgba(255, 255, 255, .1);
  color: var(--teal-400);
}
.info-list__icon svg { width: 19px; height: 19px; }
.info-list strong { display: block; font-size: .82rem; text-transform: uppercase; letter-spacing: .08em; color: #9fb8cc; font-weight: 600; }
.info-list a, .info-list span { color: #fff; font-size: .98rem; }
.info-list a:hover { color: var(--teal-400); }

.map { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); border: 1px solid var(--line); line-height: 0; }
.map iframe { width: 100%; height: 440px; border: 0; display: block; }

/* ---------- Nosotros ---------- */
.values { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.75rem; }
.value {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.9rem 1.6rem;
  transition: transform .25s ease, box-shadow .25s ease;
}
.value:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.value__icon {
  width: 46px; height: 46px;
  border-radius: 12px;
  display: grid; place-items: center;
  background: var(--teal-100);
  color: var(--teal-600);
  margin-bottom: 1rem;
}
.value__icon svg { width: 22px; height: 22px; }
.value h3 { font-family: var(--sans); font-size: 1.05rem; font-weight: 700; }
.value p { margin: 0; color: var(--muted); font-size: .95rem; }

/* ---------- Footer ---------- */
.footer { background: var(--navy-900); color: #a9bccd; padding: clamp(3rem, 6vw, 4.5rem) 0 0; }
.footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.1fr;
  gap: 2.5rem;
  padding-bottom: 3rem;
}
.footer h4 {
  font-family: var(--sans);
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: #fff;
  margin-bottom: 1.2rem;
}
.footer__brand img { height: 54px; width: auto; margin-bottom: 1.2rem; }
.footer__brand p { font-size: .92rem; line-height: 1.7; max-width: 320px; }
.footer__list { list-style: none; display: grid; gap: .65rem; }
.footer__list a { color: #a9bccd; font-size: .93rem; }
.footer__list a:hover { color: var(--teal-400); }
.footer__contact { list-style: none; display: grid; gap: 1rem; }
.footer__contact li { display: flex; gap: .7rem; align-items: flex-start; font-size: .93rem; }
.footer__contact svg { width: 17px; height: 17px; color: var(--teal-400); flex: none; margin-top: 3px; }
.footer__contact a { color: #a9bccd; }
.footer__contact a:hover { color: var(--teal-400); }
.footer__social { display: flex; gap: .5rem; margin-top: 1.4rem; flex-wrap: wrap; }
.footer__social a {
  display: grid; place-items: center;
  width: 38px; height: 38px;
  border-radius: 10px;
  background: rgba(255, 255, 255, .07);
  color: #fff;
  transition: background .2s ease, transform .2s ease;
}
.footer__social a:hover { background: var(--teal-500); transform: translateY(-2px); }
.footer__social svg { width: 17px; height: 17px; }

.footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, .1);
  padding: 1.4rem 0;
  font-size: .85rem;
}
.footer__bottom .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .5rem 1rem;
  flex-wrap: wrap;
}
.footer__bottom p { margin: 0; }
.footer__bottom strong { color: #fff; font-weight: 600; }

/* ---------- Botón flotante WhatsApp ---------- */
.wsp-float {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 90;
  display: flex;
  align-items: center;
  gap: .65rem;
  padding: .7rem 1.1rem .7rem .75rem;
  border-radius: 999px;
  background: #25d366;
  color: #fff;
  font-weight: 600;
  font-size: .92rem;
  box-shadow: 0 12px 28px rgba(37, 211, 102, .4);
  transition: transform .2s ease, box-shadow .2s ease;
}
.wsp-float:hover { color: #fff; transform: translateY(-3px) scale(1.02); box-shadow: 0 16px 34px rgba(37, 211, 102, .5); }
.wsp-float__icon {
  width: 38px; height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .18);
  display: grid; place-items: center;
  flex: none;
}
.wsp-float svg { width: 22px; height: 22px; }
.wsp-float::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 999px;
  border: 2px solid rgba(37, 211, 102, .55);
  animation: pulse 2.4s infinite;
}
@keyframes pulse {
  0%   { transform: scale(1); opacity: .8; }
  70%  { transform: scale(1.16); opacity: 0; }
  100% { transform: scale(1.16); opacity: 0; }
}

/* =========================================================
   Tema Área Familia — lila #daa1d9 y dorado #f7c877 (marca Familia)
   .theme-familia  → tiñe una página completa (subpáginas de Familia)
   .accent-familia → tiñe un bloque suelto dentro de una página civil (Inicio)
   ========================================================= */
.theme-familia,
.accent-familia {
  --navy-900: #3a2140;
  --navy-800: #4c2c55;
  --navy-700: #5f3769;
  --navy-600: #74417f;
  --blue-500: #b3801f;          /* dorado oscuro: enlaces y trazos */

  --teal-600: #85407f;          /* lila oscuro: texto de acento */
  --teal-500: #a3529f;          /* lila medio: botones sobre blanco */
  --teal-400: #daa1d9;          /* lila de marca: sobre fondos oscuros */
  --teal-100: #f6e7f5;          /* lila muy claro: fondos de icono */

  --accent-rgb: 163, 82, 159;
  --accent-deep-rgb: 133, 64, 127;

  --gold: #f7c877;
  --gold-600: #c08a2e;

  --bg-deep: #4c2c55;
  --bg-soft: #faf6fa;
  --line: #ece1ec;
  --shadow-sm: 0 1px 2px rgba(58, 33, 64, .06), 0 4px 12px rgba(58, 33, 64, .07);
  --shadow-md: 0 10px 30px rgba(58, 33, 64, .12);
  --shadow-lg: 0 24px 60px rgba(58, 33, 64, .18);
}

/* Detalles en dorado, el segundo color de la marca Familia */
.theme-familia .split__badge,
.accent-familia .split__badge { background: var(--gold-600); }

.theme-familia .card--featured::before,
.accent-familia.card--featured::before { background: var(--gold-600); }

.theme-familia .topbar a:hover,
.theme-familia .footer__list a:hover,
.theme-familia .footer__contact a:hover { color: var(--gold); }

.theme-familia .hero h1 em,
.theme-familia .stat strong { color: var(--gold); }

.theme-familia .page-hero::before {
  background:
    radial-gradient(900px 320px at 88% -10%, rgba(218, 161, 217, .45), transparent 62%),
    radial-gradient(600px 260px at 10% 120%, rgba(247, 200, 119, .38), transparent 60%);
}

.theme-familia .cta-band {
  background: linear-gradient(120deg, var(--navy-800), var(--navy-700) 50%, #a3529f);
}

/* El logo de Familia tiene más aire alrededor: se compensa la altura */
.theme-familia .brand img { height: 60px; }
.theme-familia .mobile-nav__head img { height: 48px; }
.theme-familia .footer__brand img { height: 64px; }

/* ---------- Animación de entrada ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
}

/* =========================================================
   Responsive
   ========================================================= */
@media (max-width: 1080px) {
  .trust__grid { grid-template-columns: repeat(2, 1fr); }
  .footer__grid { grid-template-columns: 1fr 1fr; gap: 2rem 2.5rem; }
  .service-layout { grid-template-columns: 1fr; }
  .sidebar { position: static; grid-template-columns: 1fr 1fr; display: grid; gap: 1.25rem; }
}

@media (max-width: 940px) {
  .nav, .header__cta { display: none; }
  .burger { display: grid; }
  .header__inner { min-height: 72px; }
  :root { --header-h: 72px; }
  .cards { grid-template-columns: 1fr; }
  .areas { grid-template-columns: 1fr; }
  .values { grid-template-columns: 1fr; }
  .split { grid-template-columns: 1fr; }
  .split__media { order: -1; }
  .split__badge { right: 12px; bottom: -18px; }
  .contact-grid { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); gap: 0; }
  .stat { border-right: 0; border-bottom: 1px solid rgba(255, 255, 255, .12); }
  .stat:nth-child(even) { border-left: 1px solid rgba(255, 255, 255, .12); }
  .stat:nth-last-child(-n+2) { border-bottom: 0; }
}

@media (max-width: 780px) {
  .topbar__inner { justify-content: center; }
  .topbar__list li:not(.topbar__phone) { display: none; }
  .topbar__social { display: none; }
  .cta-band { flex-direction: column; align-items: flex-start; text-align: left; }
  .hero__actions .btn { flex: 1 1 auto; }
}

@media (max-width: 640px) {
  .container { width: min(100% - 2rem, var(--container)); }
  .trust__grid { grid-template-columns: 1fr; margin-top: -2rem; }
  .sidebar { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; }
  .footer__bottom .container { justify-content: center; text-align: center; }
  .brand img { height: 42px; }
  .map iframe { height: 320px; }
  .prose p, .faq__panel p { text-align: left; }

  .wsp-float {
    right: 16px;
    bottom: 16px;
    padding: .55rem;
    gap: 0;
  }
  .wsp-float span { display: none; }
  .wsp-float__icon { width: 44px; height: 44px; background: transparent; }
  .wsp-float svg { width: 28px; height: 28px; }
}
