/* ==========================================================================
   Clínica Psicológica Mª del Carmen González Doncel
   Hoja de estilos de la web pública.
   ========================================================================== */

:root {
  --bg: #faf9f6;
  --bg-alt: #eef4f2;
  --card: #ffffff;
  --ink: #403c37;
  --ink-soft: #736c64;
  --line: #e7e3da;
  --brand: #95c4be;
  --brand-2: #cce3e0;
  --brand-deep: #79b6ae;
  --brand-ink: #3d7a72;
  --accent: #b19c8b;
  --accent-soft: #ece1d6;
  --radius: 18px;
  --radius-sm: 12px;
  --hfont: 'Cormorant Garamond', serif;
  --hweight: 600;
  --shadow: 0 24px 60px -34px rgba(70, 105, 100, .5);
  --header-h: 152px;
}

* { box-sizing: border-box; }

/* Las clases .btn-* fijan display, que ganaría al [hidden] del navegador. */
[hidden] { display: none !important; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 128px;
}

body {
  margin: 0;
  font-family: 'Mulish', sans-serif;
  font-variant-numeric: lining-nums;
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection { background: var(--brand); color: #fff; }

img { max-width: 100%; }

/* Ningún enlace va subrayado de serie. Los que no llevan data-noline
   revelan un subrayado animado al pasar el ratón. */
a { text-decoration: none; }

a:not([data-noline]) {
  background-image: linear-gradient(currentColor, currentColor);
  background-repeat: no-repeat;
  background-position: 0 100%;
  background-size: 0% 1px;
  transition: background-size .35s cubic-bezier(.4, 0, .2, 1), color .25s ease;
}
a:not([data-noline]):hover { background-size: 100% 1px; }

:focus-visible {
  outline: 3px solid var(--brand-deep);
  outline-offset: 2px;
  border-radius: 4px;
}

@keyframes floaty {
  0%, 100% { transform: translateY(0) rotate(var(--r, 0deg)); }
  50%      { transform: translateY(-12px) rotate(var(--r, 0deg)); }
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--brand-ink);
  color: #fff;
  padding: 12px 20px;
  border-radius: 0 0 var(--radius-sm) 0;
  font-weight: 700;
}
.skip-link:focus { left: 0; }

/* --------------------------------------------------------------------------
   Cabecera y navegación
   -------------------------------------------------------------------------- */

.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  background: #fff;
  border-bottom: 1px solid var(--line);
  box-shadow: 0 6px 24px -18px rgba(60, 80, 75, .35);
}

.nav {
  max-width: 1240px;
  margin: 0 auto;
  padding: 14px 28px;
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav__logo { display: flex; align-items: center; flex-shrink: 0; }
.nav__logo img { height: 123px; width: auto; display: block; }

.nav__burger {
  display: none;
  margin-left: auto;
  align-items: center;
  justify-content: center;
  width: 46px; height: 46px;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 12px;
  cursor: pointer;
  font-size: 24px;
  color: var(--brand-deep);
  line-height: 1;
  padding: 0;
}

.nav__right {
  display: flex;
  gap: 26px;
  margin-left: auto;
  align-items: center;
}

.nav__links { display: flex; gap: 26px; align-items: center; }
.nav__links a {
  color: var(--ink-soft);
  font-size: 14.5px;
  font-weight: 600;
}
.nav__links a:hover, .nav__links a[aria-current="page"] { color: var(--brand-ink); }

.btn-cta {
  transition: background .3s ease, transform .25s ease, box-shadow .25s ease;
  background: var(--brand-deep);
  color: #fff;
  padding: 11px 22px;
  border-radius: 999px;
  font-size: 14.5px;
  font-weight: 700;
  box-shadow: 0 10px 24px -12px var(--brand-deep);
  display: inline-block;
}
.btn-cta:hover {
  background: linear-gradient(135deg, var(--brand-deep), color-mix(in srgb, var(--brand-deep) 55%, #17423c));
  transform: translateY(-2px);
  color: #fff;
}

.nav__mobile {
  position: absolute;
  top: 100%; left: 0; right: 0;
  background: #fff;
  border-bottom: 1px solid var(--line);
  box-shadow: 0 14px 30px -18px rgba(60, 80, 75, .45);
  display: flex;
  flex-direction: column;
  padding: 8px 18px 18px;
  z-index: 49;
}
.nav__mobile[hidden] { display: none; }
.nav__mobile a {
  color: var(--ink);
  font-size: 16px;
  font-weight: 600;
  padding: 14px 4px;
  border-bottom: 1px solid var(--line);
}
.nav__mobile .btn-cta {
  margin-top: 14px;
  text-align: center;
  padding: 14px;
  font-size: 16px;
  border-bottom: none;
  color: #fff;
}

/* --------------------------------------------------------------------------
   Secciones y tipografía común
   -------------------------------------------------------------------------- */

.section { padding: 90px 28px; }
.section--alt { background: var(--bg-alt); }
.section--bg  { background: var(--bg); }

.wrap      { max-width: 1200px; margin: 0 auto; }
.wrap--md  { max-width: 1100px; margin: 0 auto; }
.wrap--sm  { max-width: 1000px; margin: 0 auto; }
.wrap--xs  { max-width: 900px;  margin: 0 auto; }

.eyebrow {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--brand-deep);
}

h1, h2, h3 { font-family: var(--hfont); font-weight: var(--hweight); }

.h-sec {
  font-family: var(--hfont);
  font-weight: var(--hweight);
  font-size: clamp(32px, 3.8vw, 46px);
  line-height: 1.1;
  margin: 14px 0 0;
  color: var(--ink);
}

.lead {
  font-size: 16.5px;
  line-height: 1.7;
  color: var(--ink-soft);
  text-wrap: pretty;
}

.center { text-align: center; }

/* --------------------------------------------------------------------------
   Justificado. La clase se pone en el propio párrafo, así cada texto se
   controla por separado desde el panel. La partición de palabras evita los
   huecos enormes entre palabras que el justificado produce en castellano.
   -------------------------------------------------------------------------- */

/* Lleva !important a propósito: es una elección explícita del panel y debe
   ganar a reglas más específicas como «.servicios__intro .lead», que fijan
   la alineación por motivos de maquetación. */
.ta-j, .ta-j p, .ta-j li {
  text-align: justify !important;
  text-justify: inter-word;
  hyphens: auto;
}

/* En pantallas estrechas queda mal por fuerza: se desactiva. */
@media (max-width: 560px) {
  .ta-j, .ta-j p, .ta-j li { text-align: left !important; hyphens: none; }
}

.divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin: 36px 0;
}
.divider span { height: 1px; width: 70px; background: var(--brand); }
.divider i { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); display: block; }

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero {
  position: relative;
  padding: 172px 28px 90px;
  overflow: hidden;
}

.hero__deco {
  position: absolute;
  display: block;
  pointer-events: none;
}
.hero__deco--1 { top: 120px; right: 6px;   width: 34px; height: 34px; opacity: .7;  --r: 18deg;  animation: floaty 7s ease-in-out infinite; }
.hero__deco--2 { top: 130px; left: 56%;    width: 24px; height: 24px; opacity: .5;  --r: -22deg; animation: floaty 9s ease-in-out infinite; }
.hero__deco--3 { bottom: 60px; left: 18%;  width: 20px; height: 20px; opacity: .55; --r: 30deg;  animation: floaty 8s ease-in-out infinite; }

.hero__grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  gap: 60px;
  align-items: center;
  position: relative;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--brand-2);
  color: var(--brand-deep);
  padding: 7px 15px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .02em;
}
.badge img { width: 15px; height: 15px; display: inline-block; }

.hero__title {
  font-family: var(--hfont);
  font-weight: var(--hweight);
  font-size: clamp(40px, 5.4vw, 68px);
  line-height: 1.04;
  letter-spacing: -.01em;
  margin: 22px 0 0;
  color: var(--ink);
}
.hero__title em { color: var(--brand-deep); font-style: italic; }

.hero__text {
  font-size: 18px;
  line-height: 1.65;
  color: var(--ink-soft);
  max-width: 480px;
  margin: 22px 0 0;
}

.hero__btns { display: flex; gap: 14px; margin-top: 34px; flex-wrap: wrap; }

.btn-primary {
  transition: background .3s ease, transform .25s ease, box-shadow .25s ease;
  background: var(--brand-deep);
  color: #fff;
  padding: 16px 32px;
  border-radius: 999px;
  font-size: 16px;
  font-weight: 700;
  box-shadow: 0 16px 34px -16px var(--brand-deep);
  display: inline-block;
  border: none;
  cursor: pointer;
  font-family: inherit;
}
.btn-primary:hover {
  background: linear-gradient(135deg, var(--brand-deep), color-mix(in srgb, var(--brand-deep) 55%, #17423c));
  transform: translateY(-2px);
  color: #fff;
}

.btn-ghost {
  transition: background .3s ease, color .3s ease, transform .25s ease;
  border: 1.5px solid var(--brand-deep);
  color: var(--brand-deep);
  padding: 16px 30px;
  border-radius: 999px;
  font-size: 16px;
  font-weight: 700;
  display: inline-block;
  background: transparent;
}
.btn-ghost:hover {
  background: color-mix(in srgb, var(--brand-deep) 55%, #17423c);
  color: #fff;
  transform: translateY(-2px);
}

.hero__stats { display: flex; gap: 30px; margin-top: 42px; flex-wrap: wrap; }
.hero__stats .v {
  font-family: var(--hfont);
  font-weight: 700;
  font-size: 28px;
  color: var(--brand-deep);
}
.hero__stats .l { font-size: 13px; color: var(--ink-soft); }
.hero__stats .sep { width: 1px; background: var(--line); }

.hero__card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) + 10px);
  padding: 54px 48px;
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  justify-content: center;
}
.hero__card img { width: 100%; max-width: 440px; height: auto; display: block; }

/* --------------------------------------------------------------------------
   Sobre mí
   -------------------------------------------------------------------------- */

/* El ancho de la foto se fija desde el panel con la variable --foto-w. */
.two-col {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: var(--foto-w, 238px) 1fr;
  gap: 60px;
  align-items: start;
}

.sobre__photo { position: relative; max-width: var(--foto-w, 238px); }
.sobre__photo img.main {
  width: 100%;
  height: auto;
  display: block;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
.sobre__photo .deco {
  position: absolute;
  top: -18px; right: -14px;
  width: 30px; height: 30px;
  opacity: .85;
  transform: rotate(20deg);
}

.sobre__role {
  font-size: 15px;
  color: var(--accent);
  font-weight: 700;
  margin-top: 8px;
}

.rich { font-size: 16.5px; line-height: 1.7; color: var(--ink-soft); text-wrap: pretty; }
.rich p { margin: 16px 0 0; }
.rich p:first-child { margin-top: 22px; }
.rich strong { color: var(--ink); font-weight: 700; }
.rich h2, .rich h3 { color: var(--ink); margin: 28px 0 0; }
.rich h2 { font-size: 28px; }
.rich h3 { font-size: 22px; }
.rich ul, .rich ol { margin: 16px 0 0; padding-left: 22px; }
.rich li { margin-bottom: 8px; }
.rich a { color: var(--brand-ink); font-weight: 600; }
.rich img { border-radius: var(--radius-sm); height: auto; }
.rich img.img-left   { float: left;  margin: 6px 22px 12px 0; }
.rich img.img-right  { float: right; margin: 6px 0 12px 22px; }
.rich img.img-center { display: block; margin: 18px auto; }
.rich blockquote {
  margin: 22px 0 0;
  padding: 4px 0 4px 22px;
  border-left: 3px solid var(--brand);
  font-family: var(--hfont);
  font-size: 20px;
  font-style: italic;
  color: var(--brand-ink);
}
.rich table { width: 100%; border-collapse: collapse; margin: 20px 0 0; font-size: 15px; }
.rich th, .rich td { border: 1px solid var(--line); padding: 10px 12px; text-align: left; }
.rich th { background: var(--bg-alt); color: var(--ink); font-weight: 700; }
.rich code { background: var(--accent-soft); padding: 2px 6px; border-radius: 5px; font-size: 13.5px; }

.pull-quote {
  font-size: 19px;
  line-height: 1.7;
  color: var(--ink);
  margin: 16px 0 0;
  text-wrap: pretty;
  font-style: italic;
  font-family: var(--hfont);
}

/* --------------------------------------------------------------------------
   Cómo trabajo
   -------------------------------------------------------------------------- */

.proceso__quote {
  font-family: var(--hfont);
  font-size: clamp(20px, 2.2vw, 25px);
  line-height: 1.5;
  font-style: italic;
  color: var(--brand-ink);
  max-width: 760px;
  margin: 30px auto 0;
  text-align: center;
  text-wrap: pretty;
}

.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin: 34px 0 0; }

.escuela {
  border-radius: var(--radius);
  padding: 26px 20px;
  text-align: center;
  transition: transform .25s ease;
  border: 1px solid var(--brand);
  background: var(--card);
}
.escuela:hover { transform: translateY(-4px); }
.escuela:nth-child(2) { background: var(--brand-2); }
.escuela:nth-child(4) {
  background: color-mix(in srgb, var(--accent) 14%, var(--card));
  border-color: color-mix(in srgb, var(--accent) 40%, var(--card));
}
.escuela__n {
  font-family: var(--hfont);
  font-weight: 700;
  font-size: 17.5px;
  line-height: 1.35;
  color: var(--brand-ink);
}
.escuela:nth-child(3) .escuela__n,
.escuela:nth-child(4) .escuela__n { color: var(--accent); }
.escuela__bar {
  width: 26px; height: 2px;
  background: var(--brand-ink);
  opacity: .4;
  margin: 10px auto;
}
.escuela:nth-child(3) .escuela__bar,
.escuela:nth-child(4) .escuela__bar { background: var(--accent); }
.escuela__note { font-size: 13.5px; color: var(--ink-soft); line-height: 1.5; }

.proceso__bottom {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 34px;
  margin-top: 44px;
  align-items: start;
}

.card-deep {
  background: linear-gradient(140deg, var(--brand-ink), color-mix(in srgb, var(--brand-ink) 60%, #17423c));
  border-radius: var(--radius);
  padding: 30px;
  box-shadow: var(--shadow);
}
.card-deep h3 { font-weight: 700; font-size: 23px; color: #fff; margin: 0; }
.card-deep p { font-size: 15.5px; line-height: 1.7; color: #dcece9; margin: 10px 0 0; text-wrap: pretty; }

/* --------------------------------------------------------------------------
   Servicios
   -------------------------------------------------------------------------- */

.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }

.servicios__intro { max-width: 820px; margin: 0 auto; text-align: center; }
.servicios__intro .lead { text-align: left; margin: 22px 0 0; }
.servicios__intro .strong-note {
  font-size: 16.5px;
  line-height: 1.7;
  color: var(--ink);
  font-weight: 700;
  margin: 16px 0 0;
  text-align: left;
}

.servicio {
  border-radius: var(--radius);
  padding: 32px 28px;
  position: relative;
  overflow: hidden;
  transition: transform .25s ease, box-shadow .25s ease;
  background: var(--card);
  border: 1px solid var(--brand);
}
.servicio:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.servicio__top { position: absolute; top: 0; left: 0; right: 0; height: 4px; background: var(--brand-ink); }
.servicio__num {
  font-family: var(--hfont);
  font-weight: 700;
  font-size: 34px;
  line-height: 1;
  color: var(--brand-ink);
  opacity: .5;
}
.servicio h3 {
  font-weight: 700;
  font-size: 23px;
  margin: 14px 0 0;
  color: var(--brand-ink);
}
.servicio p { font-size: 14.5px; line-height: 1.6; color: var(--ink-soft); margin: 10px 0 0; }

/* Variantes cromáticas rotativas (1: claro, 2: menta, 3: arena) */
.servicio.v2 { background: var(--brand-2); }
.servicio.v3 {
  background: color-mix(in srgb, var(--accent) 12%, var(--card));
  border-color: color-mix(in srgb, var(--accent) 38%, var(--card));
}
.servicio.v3 .servicio__top { background: var(--accent); }
.servicio.v3 .servicio__num,
.servicio.v3 h3 { color: var(--accent); }

/* --------------------------------------------------------------------------
   Tarifas
   -------------------------------------------------------------------------- */

.tarifa {
  background: var(--card);
  border: 1px solid var(--brand-deep);
  border-radius: var(--radius);
  padding: 32px 28px;
  position: relative;
  box-shadow: var(--shadow);
}
.tarifa__flag {
  position: absolute;
  top: -12px; left: 50%;
  transform: translateX(-50%);
  background: var(--brand-deep);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 5px 14px;
  border-radius: 999px;
  letter-spacing: .02em;
  white-space: nowrap;
}
.tarifa h3 { font-weight: 700; font-size: 18px; margin: 0; color: var(--ink); font-family: 'Mulish', sans-serif; }
.tarifa__price { display: flex; align-items: baseline; gap: 6px; margin: 14px 0 4px; }
.tarifa__price b {
  font-family: var(--hfont);
  font-weight: 700;
  font-size: 46px;
  color: var(--brand-deep);
}
.tarifa__price span { font-size: 14px; color: var(--ink-soft); }
.tarifa__hr { height: 1px; background: var(--line); margin: 18px 0; }
.tarifa__f { display: flex; gap: 10px; align-items: flex-start; margin-bottom: 11px; }
.tarifa__f img { width: 16px; height: 16px; flex-shrink: 0; margin-top: 2px; display: block; }
.tarifa__f span { font-size: 14.5px; color: var(--ink); line-height: 1.45; }
.tarifa .btn-cta {
  display: block;
  text-align: center;
  margin-top: 22px;
  padding: 13px;
  font-size: 15px;
  border: 1.5px solid var(--brand-deep);
}
.tarifa__note { text-align: center; font-size: 13.5px; color: var(--ink-soft); margin: 24px 0 0; }

/* --------------------------------------------------------------------------
   Preguntas frecuentes
   -------------------------------------------------------------------------- */

.faq__box {
  margin-top: 44px;
  border: 1.5px solid var(--brand);
  border-radius: 20px;
  background: var(--card);
  overflow: hidden;
  display: grid;
  grid-template-columns: 92px 1fr;
  box-shadow: var(--shadow);
}
.faq__side {
  position: relative;
  border-right: 1px solid var(--line);
  background: color-mix(in srgb, var(--brand-2) 26%, var(--card));
}
.faq__side img {
  position: absolute;
  top: 40px; left: 60px;
  transform: translateX(-50%);
  width: 76px; height: 157px;
}
.faq__list { padding: 6px 30px; }
.faq__item + .faq__item { border-top: 1px solid var(--line); }
.faq__q {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  cursor: pointer;
  padding: 22px 0;
  display: flex;
  align-items: center;
  gap: 16px;
  font-family: inherit;
}
.faq__q span { font-weight: 700; font-size: 16.5px; color: var(--ink); flex: 1; }
.faq__q i {
  font-family: var(--hfont);
  font-size: 28px;
  color: var(--brand-deep);
  line-height: 1;
  flex-shrink: 0;
  font-style: normal;
}
.faq__a { margin: 0; padding: 0 0 22px; font-size: 15px; line-height: 1.65; color: var(--ink-soft); }
.faq__a[hidden] { display: none; }

/* --------------------------------------------------------------------------
   Blog
   -------------------------------------------------------------------------- */

.blog__head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}
.blog__more { color: var(--brand-deep); font-weight: 700; font-size: 15px; }

.post-card { display: block; color: inherit; transition: transform .25s ease; }
.post-card:hover { transform: translateY(-6px); }
.post-card__img {
  aspect-ratio: 16 / 10;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: repeating-linear-gradient(135deg, #e8efec 0 14px, #dfe9e5 14px 28px);
  display: flex;
  align-items: center;
  justify-content: center;
}
.post-card__img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.post-card__cat {
  margin-top: 16px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent);
}
.post-card h3 {
  font-family: var(--hfont);
  font-weight: 700;
  font-size: 22px;
  line-height: 1.25;
  margin: 8px 0 0;
  color: var(--ink);
}
.post-card__excerpt { font-size: 14.5px; line-height: 1.6; color: var(--ink-soft); margin: 8px 0 0; }
.post-card__more { font-size: 14px; color: var(--brand-deep); font-weight: 700; margin-top: 12px; }

.post-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 44px; }

.page-head { padding: 172px 28px 40px; text-align: center; }
.page-head .h-sec { margin-top: 10px; }
.page-head .lead { max-width: 660px; margin: 16px auto 0; }

.post-hero {
  max-width: 900px;
  margin: 0 auto 34px;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
}
.post-hero img { width: 100%; height: auto; display: block; }

.post-meta { font-size: 14px; color: var(--ink-soft); margin-top: 12px; }

.post-gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 34px; }
.post-gallery img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  display: block;
}

.back-link { display: inline-block; margin-top: 40px; color: var(--brand-deep); font-weight: 700; }

.empty-note {
  text-align: center;
  color: var(--ink-soft);
  background: var(--card);
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  padding: 50px 24px;
  margin-top: 30px;
}

/* --------------------------------------------------------------------------
   Contacto y formulario
   -------------------------------------------------------------------------- */

.contacto__grid {
  max-width: 1100px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
}

.contacto__title { margin: 14px 0 18px; }
.contacto__intro { font-size: 16px; line-height: 1.65; color: var(--ink-soft); margin: 0 0 26px; }
.contacto__list { display: flex; flex-direction: column; gap: 18px; }
.contacto__row { display: flex; gap: 14px; align-items: flex-start; }
.contacto__row img { width: 40px; height: 40px; flex-shrink: 0; display: block; }
.contacto__row b { font-weight: 700; font-size: 15px; color: var(--ink); display: block; }
.contacto__row a, .contacto__row .txt {
  font-size: 14.5px;
  color: var(--ink-soft);
  line-height: 1.5;
  display: block;
}
.contacto__row a:hover { color: var(--brand-deep); }

.contacto__map {
  margin-top: 24px;
  width: 100%;
  aspect-ratio: 16 / 7;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: block;
}

.form-box {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow);
  align-self: start;
}

.form-label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 6px;
}
.form-label .req { color: #b4544a; }

.form-input, .form-box select, .form-box textarea {
  width: 100%;
  padding: 13px 15px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 15px;
  background: var(--bg);
  color: var(--ink);
  margin-bottom: 16px;
}
.form-box textarea { resize: vertical; margin-bottom: 18px; }
.form-input:focus, .form-box select:focus, .form-box textarea:focus {
  outline: none;
  border-color: var(--brand-deep);
  box-shadow: 0 0 0 3px var(--brand-2);
}
.form-help { font-size: 12.5px; color: var(--ink-soft); margin: -10px 0 14px; }

.form-check {
  display: flex;
  gap: 11px;
  align-items: flex-start;
  margin: 4px 0 18px;
  cursor: pointer;
}
.form-check input {
  width: 18px; height: 18px;
  margin-top: 1px;
  accent-color: var(--brand-ink);
  flex-shrink: 0;
  cursor: pointer;
}
.form-check span { font-size: 13.5px; line-height: 1.5; color: var(--ink-soft); }
.form-check a { color: var(--brand-ink); font-weight: 600; }

.form-submit { width: 100%; padding: 16px; }
.form-foot { font-size: 12px; color: var(--ink-soft); text-align: center; margin: 14px 0 0; line-height: 1.5; }

.form-error {
  font-size: 13.5px;
  color: #8f3f37;
  background: #fbeceb;
  border: 1px solid #f0cdc9;
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  margin: 0 0 18px;
  line-height: 1.5;
}
.form-error ul { margin: 6px 0 0; padding-left: 18px; }

.form-ok { text-align: center; padding: 40px 10px; }
.form-ok img { width: 62px; height: 62px; margin: 0 auto; display: block; }
.form-ok h3 { font-weight: 700; font-size: 26px; margin: 20px 0 8px; color: var(--ink); }
.form-ok p { font-size: 15px; color: var(--ink-soft); line-height: 1.6; margin: 0; }

.hp-field { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }

/* --------------------------------------------------------------------------
   Pie
   -------------------------------------------------------------------------- */

.site-footer { background: #4f857e; color: #eaf3f1; padding: 60px 28px 30px; }

.footer__grid {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 40px;
}
.footer__logo {
  background: #fff;
  display: inline-block;
  padding: 14px 18px;
  border-radius: var(--radius-sm);
}
.footer__logo img { height: 64px; width: auto; display: block; }
.footer__about { font-size: 14.5px; line-height: 1.65; color: #cfe3e0; max-width: 320px; margin: 18px 0 0; }
.footer__h { font-weight: 700; font-size: 14px; margin-bottom: 14px; color: #fff; }
.footer__col { display: flex; flex-direction: column; gap: 9px; font-size: 14.5px; color: #cfe3e0; }
.footer__col a { color: #cfe3e0; font-size: 14.5px; }
.footer__col a:hover { color: #fff; }

.footer__legal {
  max-width: 1200px;
  margin: 36px auto 0;
  padding-top: 22px;
  border-top: 1px solid rgba(255, 255, 255, .18);
  display: flex;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 13px;
  color: #bcd6d2;
}
.footer__legal a { color: #cfe3e0; }
.footer__legal a:hover { color: #fff; }
.footer__cookies {
  background: none;
  border: none;
  color: #cfe3e0;
  font: inherit;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
}
.footer__cookies:hover { color: #fff; }

/* --------------------------------------------------------------------------
   Consentimiento de cookies (CMP)
   -------------------------------------------------------------------------- */

.cmp {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(35, 55, 52, .55);
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 18px;
  backdrop-filter: blur(2px);
}
.cmp[hidden] { display: none; }

.cmp__box {
  background: #fff;
  border-radius: 20px;
  box-shadow: 0 30px 70px -30px rgba(20, 50, 45, .6);
  max-width: 620px;
  width: 100%;
  padding: 30px 30px 26px;
  position: relative;
  max-height: 88vh;
  overflow-y: auto;
}
.cmp__x {
  position: absolute;
  top: 12px; right: 14px;
  background: none;
  border: none;
  font-size: 26px;
  line-height: 1;
  color: var(--ink-soft);
  cursor: pointer;
  padding: 4px 8px;
}
.cmp__h {
  font-family: var(--hfont);
  font-weight: 700;
  font-size: 26px;
  margin: 0 0 10px;
  color: var(--ink);
}
.cmp__txt { font-size: 14.5px; line-height: 1.6; color: var(--ink-soft); margin: 0 0 18px; }

.cmp__prefs { border-top: 1px solid var(--line); margin-bottom: 18px; }
.cmp__prefs[hidden] { display: none; }
.cmp__cat {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}
.cmp__cat-n { font-weight: 700; font-size: 14.5px; color: var(--ink); display: block; }
.cmp__cat-d { font-size: 13px; color: var(--ink-soft); line-height: 1.5; margin-top: 3px; display: block; }
.cmp__always { font-size: 12.5px; color: var(--brand-ink); font-weight: 700; white-space: nowrap; flex-shrink: 0; }
.cmp__sw { width: 20px; height: 20px; accent-color: var(--brand-ink); flex-shrink: 0; margin-top: 2px; cursor: pointer; }

.cmp__btns { display: flex; gap: 10px; flex-wrap: wrap; }
.cmp__btns button { font-size: 14.5px; padding: 12px 22px; }
.btn-sm { padding: 11px 20px !important; font-size: 14px !important; }
.cmp__links { font-size: 12.5px; color: var(--ink-soft); margin: 16px 0 0; }
.cmp__links a { color: var(--brand-ink); font-weight: 600; }

body.cmp-open { overflow: hidden; }

/* --------------------------------------------------------------------------
   Páginas legales
   -------------------------------------------------------------------------- */

.legal { padding: 172px 28px 90px; }
.legal__box { max-width: 860px; margin: 0 auto; }
.legal__updated { font-size: 13.5px; color: var(--ink-soft); margin-top: 10px; }
.legal .rich h2 {
  font-family: var(--hfont);
  font-size: 27px;
  color: var(--brand-ink);
  margin: 40px 0 0;
}
.legal .rich h3 { font-size: 20px; color: var(--ink); margin: 26px 0 0; }
.legal .rich table { font-size: 14px; }

/* --------------------------------------------------------------------------
   Botón volver arriba
   -------------------------------------------------------------------------- */

.to-top {
  position: fixed;
  right: 20px; bottom: 20px;
  width: 46px; height: 46px;
  border-radius: 50%;
  border: none;
  background: var(--brand-deep);
  color: #fff;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: 0 12px 26px -12px rgba(40, 90, 85, .8);
  z-index: 40;
}
.to-top.on { display: flex; }
.to-top svg { width: 20px; height: 20px; }

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 980px) {
  .nav__logo img { height: 84px; }
  .hero__grid,
  .two-col,
  .proceso__bottom,
  .contacto__grid { grid-template-columns: 1fr !important; gap: 40px; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .footer__grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 680px) {
  html { scroll-padding-top: 92px; }
  .nav { padding: 8px 16px; gap: 10px; }
  .nav__logo img { height: 58px; }
  .nav__right { display: none; }
  .nav__burger { display: flex; }
  .section { padding: 60px 18px; }
  .hero { padding: 112px 18px 60px; }
  .page-head, .legal { padding-left: 18px; padding-right: 18px; }
  .page-head { padding-top: 112px; }
  .legal { padding-top: 112px; }
  .grid-3, .grid-4, .post-grid { grid-template-columns: 1fr; }
  .proceso__bottom, .contacto__grid { gap: 30px; }
  .footer__grid { grid-template-columns: 1fr; gap: 24px; }
  .faq__box { grid-template-columns: 54px 1fr; }
  .faq__side img { left: 44px; width: 60px; height: auto; }
  .faq__list { padding: 6px 18px; }
  .site-footer { padding-left: 18px; padding-right: 18px; }
  .form-box { padding: 24px 20px; }
  .cmp { align-items: center; }
  .cmp__box { padding: 24px 20px 20px; }
  .cmp__btns button { flex: 1 1 100%; }
  .post-gallery { grid-template-columns: repeat(2, 1fr); }
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}
