@import url("https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700;800;900&display=swap");

:root {
  color-scheme: light;
  --navy: #16346d;
  --navy-deep: #0d2350;
  --ink: #16346d;
  --muted: #5b6b7d;
  --line: #e3e8ee;
  --paper: #ffffff;
  --soft: #f6f8fa;
  --red: #cb102e;
  --red-deep: #a80d26;
  --blue-soft: #e8edf7;
  --shadow: 0 22px 70px rgba(5, 26, 45, 0.14);
  font-family: Montserrat, Arial, Helvetica, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--soft);
  color: var(--ink);
}

body.menu-open {
  overflow: hidden;
}

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

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
}

.site-header {
  position: fixed;
  z-index: 30;
  top: 22px;
  left: 50%;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  width: min(calc(100% - 48px), 1320px);
  gap: 14px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 999px;
  background: rgba(10, 29, 54, 0.9);
  box-shadow: 0 20px 70px rgba(10, 29, 54, 0.22);
  padding: 8px 10px 8px 16px;
  color: #fff;
  transform: translateX(-50%);
  backdrop-filter: blur(16px);
}

body[data-page="home"] .site-header:not(.is-scrolled) {
  top: 26px;
  border-color: transparent;
  background: transparent;
  box-shadow: none;
  padding: 0;
  backdrop-filter: none;
}

.site-header.is-scrolled {
  top: 14px;
  background: rgba(10, 29, 54, 0.94);
  box-shadow: 0 18px 60px rgba(10, 29, 54, 0.3);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 244px;
}

.brand-logo {
  width: 62px;
  height: 62px;
  object-fit: contain;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.94);
  padding: 3px;
  box-shadow: 0 10px 28px rgba(10, 29, 54, 0.18);
}

body[data-page="home"] .site-header:not(.is-scrolled) .brand-logo {
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 10px 28px rgba(10, 29, 54, 0.12);
  filter: none;
  padding: 3px;
}

.brand-mark {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border: 2px solid currentColor;
  border-radius: 50%;
  font-family: Montserrat, Arial, Helvetica, sans-serif;
  font-size: 1.24rem;
  letter-spacing: 0;
}

.brand-copy strong {
  display: block;
  font-size: 0.96rem;
  font-weight: 800;
  letter-spacing: 0.055em;
  line-height: 1.2;
  text-transform: uppercase;
}

.brand-copy small {
  display: block;
  margin-top: 4px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.61rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

body[data-page="home"] .site-header:not(.is-scrolled) .brand-copy,
body[data-page="home"] .site-header:not(.is-scrolled) .site-nav a,
body[data-page="home"] .site-header:not(.is-scrolled) .language-switcher {
  color: var(--navy);
  text-shadow: 0 1px 16px rgba(255, 255, 255, 0.62);
}

body[data-page="home"] .site-header:not(.is-scrolled) .brand-copy small {
  color: rgba(10, 29, 54, 0.68);
}

body[data-page="home"] .site-header:not(.is-scrolled) .language-switcher::before {
  color: rgba(10, 29, 54, 0.42);
}

body[data-page="home"] .site-header:not(.is-scrolled) .language-switcher select {
  border-color: rgba(10, 29, 54, 0.26);
  background: rgba(255, 255, 255, 0.48);
  color: var(--navy);
}

body[data-page="home"] .site-header:not(.is-scrolled) .language-switcher::after {
  border-color: rgba(10, 29, 54, 0.8);
}

.site-nav {
  display: flex;
  justify-content: center;
  gap: clamp(10px, 1vw, 18px);
}

.site-nav a {
  position: relative;
  color: rgba(255, 255, 255, 0.92);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.045em;
  padding: 10px 0;
  text-transform: uppercase;
  white-space: nowrap;
}

.site-nav a::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 2px;
  background: var(--red);
  content: "";
  opacity: 0;
  transform: scaleX(0.5);
  transition: 160ms ease;
}

.site-nav a:hover::after,
.site-nav a.is-active::after {
  opacity: 1;
  transform: scaleX(1);
}

.mobile-language-row {
  display: none;
}

.header-actions {
  display: flex;
  align-items: center;
  justify-content: end;
  gap: 12px;
}

.header-cta {
  white-space: nowrap;
}

/* Con Rehabilitación el menú tiene siete entradas: en escritorio mediano se oculta el lema de la marca para que quepa */
@media (min-width: 1280px) and (max-width: 1499px) {
  .brand {
    min-width: 0;
  }

  .brand-copy small {
    display: none;
  }

  .brand-copy strong {
    white-space: nowrap;
  }
}

.language {
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.72rem;
  font-weight: 800;
  white-space: nowrap;
}

.language::before {
  margin-right: 7px;
  content: "•";
}

.language-switcher {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.language-switcher::before {
  margin-right: 7px;
  color: rgba(255, 255, 255, 0.78);
  content: "•";
}

.language-switcher select {
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  cursor: pointer;
  font: inherit;
  font-size: 0.72rem;
  font-weight: 800;
  outline: 0;
  padding: 8px 24px 8px 12px;
}

.language-switcher::after {
  position: absolute;
  right: 10px;
  top: 50%;
  width: 6px;
  height: 6px;
  border-right: 2px solid rgba(255, 255, 255, 0.82);
  border-bottom: 2px solid rgba(255, 255, 255, 0.82);
  content: "";
  pointer-events: none;
  transform: translateY(-65%) rotate(45deg);
}

.language-switcher option {
  color: var(--ink);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

.header-cta,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 50px;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 0 22px;
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  gap: 9px;
  transition:
    transform 160ms ease,
    background 160ms ease,
    border-color 160ms ease;
}

.header-cta,
.button.primary {
  background: var(--red);
  color: #fff;
  box-shadow: 0 16px 35px rgba(203, 16, 46, 0.24);
}

.header-cta:hover,
.button.primary:hover {
  background: var(--red-deep);
  transform: translateY(-1px);
}

.button.ghost {
  border-color: rgba(9, 35, 61, 0.38);
  background: rgba(255, 255, 255, 0.58);
  color: var(--ink);
  box-shadow: none;
}

.button.ghost:hover {
  background: #fff;
}

.menu-button {
  display: none;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
  padding: 12px;
}

.menu-button span {
  display: block;
  height: 2px;
  margin: 5px 0;
  border-radius: 999px;
  background: #fff;
}

.hero {
  position: relative;
  display: grid;
  align-items: center;
  min-height: 620px;
  overflow: hidden;
  background: #dce8ef;
  padding: 118px max(48px, calc((100vw - 1240px) / 2)) 46px;
}

.hero-image,
.hero-shade {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero-image {
  object-fit: cover;
  object-position: center;
}

.hero-shade {
  background:
    linear-gradient(180deg, rgba(10, 29, 54, 0.42) 0%, rgba(10, 29, 54, 0.12) 15%, transparent 34%),
    linear-gradient(90deg, rgba(247, 250, 252, 0.98) 0%, rgba(247, 250, 252, 0.82) 31%, rgba(247, 250, 252, 0.16) 56%, rgba(247, 250, 252, 0) 100%),
    linear-gradient(0deg, rgba(255, 255, 255, 0.7), transparent 30%);
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(720px, 100%);
  padding-top: 22px;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2 {
  font-family: Montserrat, Arial, Helvetica, sans-serif;
  font-weight: 700;
  letter-spacing: 0;
}

h1 {
  margin-bottom: 28px;
  color: var(--ink);
  font-size: clamp(2.3rem, 4.1vw, 3.65rem);
  line-height: 1.05;
}

h2 {
  margin-bottom: 18px;
  color: var(--ink);
  font-size: clamp(2rem, 3.7vw, 3.1rem);
  line-height: 1.08;
}

h3 {
  margin-bottom: 9px;
  color: var(--ink);
  font-size: 1rem;
}

p {
  color: var(--muted);
  line-height: 1.75;
}

.hero-content p {
  width: min(440px, 100%);
  color: #22384f;
  font-size: 1.04rem;
}

.red-rule {
  display: block;
  width: 46px;
  height: 2px;
  margin: 0 0 24px;
  background: var(--red);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.feature-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-bottom: 1px solid var(--line);
  background: #fff;
  padding: 0 max(34px, calc((100vw - 1240px) / 2));
}

.feature-strip article {
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 18px;
  min-height: 142px;
  align-items: center;
  border-right: 1px solid var(--line);
  padding: 28px 30px;
}

.feature-strip article:last-child {
  border-right: 0;
}

.icon,
.card-icon {
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  color: var(--navy);
  box-shadow: 0 10px 32px rgba(5, 26, 45, 0.08);
}

.icon {
  width: 58px;
  height: 58px;
  font-size: 1.25rem;
}

.feature-strip h2 {
  margin-bottom: 7px;
  font-family: Montserrat, Arial, Helvetica, sans-serif;
  font-size: 0.86rem;
  font-weight: 900;
  line-height: 1.35;
  text-transform: uppercase;
}

.feature-strip p {
  margin-bottom: 0;
  font-size: 0.84rem;
  line-height: 1.55;
}

.section {
  width: min(calc(100% - 56px), 1240px);
  margin: 0 auto;
  padding: 80px 0;
}

.eyebrow {
  margin-bottom: 18px;
  color: var(--red);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.method {
  display: grid;
  grid-template-columns: minmax(260px, 0.48fr) minmax(620px, 1fr);
  gap: 42px;
  align-items: center;
  border-bottom: 1px solid var(--line);
}

.method-copy p {
  max-width: 420px;
}

.method-copy .strong {
  color: var(--ink);
  font-size: 1.05rem;
  font-weight: 700;
}

.service-map {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    radial-gradient(circle at 50% 48%, rgba(203, 16, 46, 0.08), transparent 28%),
    linear-gradient(180deg, #fff, #f9fbfd);
  box-shadow: 0 22px 60px rgba(10, 29, 54, 0.12);
  padding: clamp(18px, 2.4vw, 30px);
}

.service-map::before {
  position: absolute;
  inset: 76px 12% 112px;
  border: 1px solid rgba(10, 29, 54, 0.1);
  border-radius: 999px;
  content: "";
  pointer-events: none;
}

.service-map-heading {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-bottom: 22px;
  text-align: left;
}

.service-map-heading img {
  width: 58px;
  height: 58px;
  object-fit: contain;
}

.service-map-heading strong,
.service-map-heading span {
  display: block;
}

.service-map-heading strong {
  color: var(--navy);
  font-size: clamp(1.2rem, 2.1vw, 2rem);
  font-weight: 900;
  line-height: 1.05;
  text-transform: uppercase;
}

.service-map-heading span {
  margin-top: 5px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.service-map-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(180px, 1fr) minmax(210px, 0.9fr) minmax(180px, 1fr);
  gap: clamp(14px, 2vw, 24px);
  align-items: center;
}

.service-map-column,
.service-map-center-cards {
  display: grid;
  gap: 12px;
}

.service-map-card {
  position: relative;
  display: grid;
  grid-template-columns: 46px 1fr;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 88px;
  border: 1px solid rgba(10, 29, 54, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  color: var(--ink);
  cursor: pointer;
  padding: 12px;
  text-align: left;
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.service-map-card::after {
  position: absolute;
  top: 50%;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--red);
  box-shadow: 0 0 0 5px rgba(203, 16, 46, 0.08);
  content: "";
  opacity: 0.72;
  transform: translateY(-50%);
}

.service-map-card-left::after {
  right: -5px;
}

.service-map-card-right::after {
  left: -5px;
}

.service-map-card-center::after {
  display: none;
}

.service-map-card:hover,
.service-map-card:focus-visible,
.service-map-card.is-active {
  border-color: rgba(203, 16, 46, 0.55);
  background: #fff;
  box-shadow: 0 18px 36px rgba(10, 29, 54, 0.14);
  transform: translateY(-3px);
}

.service-map-card:focus-visible {
  outline: 3px solid rgba(203, 16, 46, 0.22);
  outline-offset: 3px;
}

.service-map-icon {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border: 1px solid rgba(10, 29, 54, 0.12);
  border-radius: 50%;
  background: #fff;
  color: var(--red);
  font-size: 0.78rem;
  font-weight: 900;
  box-shadow: 0 10px 22px rgba(10, 29, 54, 0.08);
}

.service-map-card-copy strong,
.service-map-card-copy small {
  display: block;
}

.service-map-card-copy strong {
  color: var(--navy);
  font-size: 0.78rem;
  font-weight: 900;
  line-height: 1.25;
  text-transform: uppercase;
}

.service-map-card-copy small {
  margin-top: 5px;
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 600;
  line-height: 1.42;
}

.service-map-core {
  display: grid;
  gap: 14px;
  justify-items: center;
}

.patient-node {
  display: grid;
  width: 150px;
  height: 150px;
  place-items: center;
  border: 2px solid var(--red);
  border-radius: 50%;
  background: #fff;
  color: var(--navy);
  box-shadow: 0 18px 42px rgba(10, 29, 54, 0.12);
  text-align: center;
}

.patient-node span,
.patient-node strong,
.patient-node small {
  display: block;
}

.patient-node span {
  color: var(--red);
  font-size: 1.05rem;
  font-weight: 900;
}

.patient-node strong {
  margin-top: -12px;
  font-size: 1.2rem;
  font-weight: 900;
  text-transform: uppercase;
}

.patient-node small {
  margin-top: -14px;
  color: var(--muted);
  font-size: 0.66rem;
  font-weight: 800;
  text-transform: uppercase;
}

.service-map-selected {
  width: 100%;
  border: 1px solid rgba(10, 29, 54, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  padding: 16px;
  text-align: center;
}

.service-map-selected small {
  color: var(--red);
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.service-map-selected h3 {
  margin: 7px 0;
  font-size: clamp(1rem, 1.5vw, 1.35rem);
  text-transform: none;
}

.service-map-selected p {
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 0.82rem;
}

.service-map-selected a {
  color: var(--red);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.service-map-core.is-pulsing .patient-node {
  animation: servicePulse 420ms ease;
}

.service-map-process {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  align-items: center;
  margin-top: 26px;
  border: 1px solid rgba(10, 29, 54, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
  padding: 18px;
}

.service-map-process strong {
  color: var(--navy);
  font-size: 0.9rem;
  font-weight: 900;
  text-transform: uppercase;
}

.service-map-process p {
  max-width: 620px;
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 0.76rem;
}

.service-map-process ol {
  display: grid;
  grid-template-columns: repeat(5, minmax(86px, 1fr));
  gap: 12px 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.service-map-process li {
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 6px;
  min-width: 0;
  text-align: center;
}

.service-map-process li span {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border: 1px solid rgba(203, 16, 46, 0.28);
  border-radius: 50%;
  color: var(--red);
  font-size: 0.72rem;
  font-weight: 900;
}

.service-map-process li strong {
  max-width: 104px;
  font-size: 0.62rem;
  line-height: 1.16;
  overflow-wrap: anywhere;
}

.service-map-process li small {
  color: var(--muted);
  max-width: 104px;
  font-size: 0.6rem;
  font-weight: 700;
  line-height: 1.22;
  overflow-wrap: anywhere;
}

@keyframes servicePulse {
  0% {
    transform: scale(1);
    box-shadow: 0 18px 42px rgba(10, 29, 54, 0.12);
  }
  45% {
    transform: scale(1.045);
    box-shadow: 0 18px 42px rgba(203, 16, 46, 0.2);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 18px 42px rgba(10, 29, 54, 0.12);
  }
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-top: 18px;
  color: var(--red);
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.orbit {
  position: relative;
  width: min(620px, 100%);
  aspect-ratio: 1.32 / 1;
  margin-left: auto;
}

.orbit::before,
.orbit::after {
  position: absolute;
  inset: 14%;
  border: 1px solid #dce3ea;
  border-radius: 50%;
  content: "";
}

.orbit::after {
  inset: 27%;
}

.orbit-center {
  position: absolute;
  z-index: 2;
  top: 50%;
  left: 50%;
  display: grid;
  width: 138px;
  height: 138px;
  place-items: center;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  font-family: Montserrat, Arial, Helvetica, sans-serif;
  font-size: 2rem;
  transform: translate(-50%, -50%);
}

.orbit-item {
  position: absolute;
  display: grid;
  width: 170px;
  justify-items: center;
  text-align: center;
}

.orbit-item span {
  display: grid;
  width: 64px;
  height: 64px;
  place-items: center;
  margin-bottom: 10px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  color: var(--red);
  font-size: 1.4rem;
  box-shadow: 0 10px 24px rgba(5, 26, 45, 0.08);
}

.orbit-item strong {
  display: block;
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.orbit-item small {
  color: var(--muted);
  font-size: 0.72rem;
}

.item-1 { top: 0; left: 50%; transform: translateX(-50%); }
.item-2 { top: 10%; right: 0; }
.item-3 { top: 40%; right: -2%; }
.item-4 { right: 8%; bottom: 2%; }
.item-5 { bottom: 0; left: 50%; transform: translateX(-50%); }
.item-6 { bottom: 2%; left: 8%; }
.item-7 { top: 40%; left: -2%; }
.item-8 { top: 10%; left: 0; }

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 34px;
}

.section-head h2 {
  max-width: 780px;
  margin-bottom: 0;
  font-size: clamp(1.8rem, 3vw, 2.45rem);
}

.cards-row {
  position: relative;
  display: grid;
  grid-template-columns: 48px repeat(5, minmax(0, 1fr)) 48px;
  gap: 22px;
  align-items: center;
}

.round-control {
  display: grid;
  width: 46px;
  height: 46px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  font-size: 2rem;
}

.specialty-card {
  position: relative;
  overflow: hidden;
  min-height: 340px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 15px 46px rgba(5, 26, 45, 0.08);
  text-align: center;
  transition:
    transform 160ms ease,
    box-shadow 160ms ease,
    border-color 160ms ease;
}

.specialty-card:hover {
  border-color: rgba(216, 17, 53, 0.38);
  box-shadow: 0 24px 66px rgba(5, 26, 45, 0.14);
  transform: translateY(-4px);
}

.specialty-card img {
  width: 100%;
  height: 168px;
  object-fit: cover;
  object-position: center;
}

.card-icon {
  position: relative;
  width: 54px;
  height: 54px;
  margin: -27px auto 14px;
  color: var(--navy);
  font-size: 1.18rem;
}

.specialty-card h3,
.specialty-card p {
  padding-right: 16px;
  padding-left: 16px;
}

.specialty-card p {
  font-size: 0.78rem;
  line-height: 1.65;
}

.service-action {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 2px 16px 20px;
  color: var(--red);
  font-size: 0.76rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.service-action::after {
  content: "->";
}

.center-block {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(320px, 0.75fr);
  gap: 54px;
  align-items: center;
  padding-top: 46px;
}

.center-block img {
  width: 100%;
  min-height: 360px;
  border-radius: 8px;
  box-shadow: var(--shadow);
  object-fit: cover;
}

.page-hero {
  display: grid;
  grid-template-columns: minmax(0, 0.78fr) minmax(360px, 0.8fr);
  gap: 56px;
  align-items: center;
  min-height: 610px;
  background:
    linear-gradient(110deg, var(--navy), var(--navy-deep) 54%, rgba(249, 249, 249, 0.98) 54%),
    var(--navy);
  padding: 142px max(32px, calc((100vw - 1240px) / 2)) 76px;
}

.page-hero-copy {
  color: #fff;
}

.page-hero-copy h1 {
  color: #fff;
  font-size: clamp(2.25rem, 4.8vw, 4.25rem);
}

.page-hero-copy p {
  max-width: 560px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 1.04rem;
}

.page-hero .eyebrow {
  color: #ff8797;
}

.page-hero img {
  width: 100%;
  min-height: 390px;
  max-height: 500px;
  border-radius: 8px;
  box-shadow: var(--shadow);
  object-fit: cover;
}

body[data-page="seguros"] .page-hero img {
  aspect-ratio: 749 / 800;
  min-height: 0;
  max-height: min(560px, 62vh);
  background: #fff;
  object-fit: contain;
  padding: clamp(14px, 2.2vw, 28px);
}

.content-grid-section {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.info-card {
  min-height: 240px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 28px;
  box-shadow: 0 15px 46px rgba(5, 26, 45, 0.06);
}

.legal-detail-section {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  padding-top: 0;
}

.legal-detail-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 28px;
  box-shadow: 0 15px 46px rgba(5, 26, 45, 0.06);
  overflow-wrap: anywhere;
}

.legal-detail-card h2 {
  margin-bottom: 12px;
  font-size: clamp(1.15rem, 1.7vw, 1.45rem);
}

.legal-detail-card p {
  margin-bottom: 0;
}

.info-card span {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  margin-bottom: 42px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 900;
}

.info-card h2 {
  font-family: Montserrat, Arial, Helvetica, sans-serif;
  font-size: 1.15rem;
  font-weight: 900;
  line-height: 1.3;
}

.highlight-band {
  display: grid;
  grid-template-columns: repeat(var(--hl-cols, 4), minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--line);
  padding: 0;
}

.highlight-band div {
  min-height: 132px;
  background: #fff;
  padding: 24px;
}

.highlight-band span {
  display: block;
  margin-bottom: 18px;
  color: var(--red);
  font-size: 0.78rem;
  font-weight: 900;
}

.highlight-band strong {
  display: block;
  color: var(--ink);
  line-height: 1.4;
}

.service-list {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.service-list .specialty-card {
  color: inherit;
}

.related {
  padding-top: 24px;
}

.contact-page {
  display: grid;
  grid-template-columns: 1.1fr 1fr 1fr;
  gap: 18px;
}

.contact-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 30px;
  box-shadow: 0 15px 46px rgba(5, 26, 45, 0.06);
}

.contact-card h2 {
  font-size: clamp(1.6rem, 2.5vw, 2.2rem);
}

.contact-card a {
  display: block;
  margin: 14px 0;
  color: var(--navy);
  font-weight: 900;
}

.main-contact {
  background: var(--navy);
  color: #fff;
}

.main-contact h2,
.main-contact a {
  color: #fff;
}

/* Números dentro de una frase (urgencias): en línea, sin el margen de los enlaces de bloque */
.contact-card p a {
  display: inline;
  margin: 0;
  white-space: nowrap;
}

.main-contact p {
  color: rgba(255, 255, 255, 0.78);
}

.footer {
  overflow: hidden;
  border-top: 4px solid var(--red);
  background:
    radial-gradient(circle at 92% 34%, rgba(255, 255, 255, 0.08), transparent 22%),
    var(--navy-deep);
  color: #fff;
  padding: 36px max(28px, calc((100vw - 1240px) / 2)) 18px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 230px minmax(390px, 1fr) minmax(280px, 340px);
  gap: 34px;
}

.footer .brand-mark {
  margin-bottom: 18px;
}

.footer-logo {
  width: 58px;
  height: 58px;
  margin-bottom: 12px;
  object-fit: contain;
  filter: brightness(0) invert(1);
}

.footer-brand strong {
  display: block;
  margin-bottom: 14px;
  font-size: 0.92rem;
  letter-spacing: 0.08em;
  line-height: 1.35;
  text-transform: uppercase;
}

.footer p,
.footer a,
.footer small {
  color: rgba(255, 255, 255, 0.76);
}

.footer h2 {
  color: #fff;
  font-size: clamp(1.45rem, 2.35vw, 2.05rem);
}

.footer h2 span {
  color: var(--red);
}

.socials,
.contact-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.socials a {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 50%;
  font-size: 0.72rem;
  font-weight: 900;
}

.contact-row {
  margin: 18px 0 26px;
}

.contact-row a {
  min-width: 150px;
  font-size: 0.78rem;
  line-height: 1.6;
  text-transform: uppercase;
}

.contact-row strong {
  color: #fff;
  font-size: 0.82rem;
  text-transform: none;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}

.footer-links nav {
  display: grid;
  gap: 6px;
}

.footer-links strong {
  margin-bottom: 8px;
  font-size: 0.78rem;
  text-transform: uppercase;
}

.footer-links a {
  font-size: 0.82rem;
}

.cookie-settings-link {
  width: fit-content;
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.76);
  cursor: pointer;
  font: inherit;
  font-size: 0.82rem;
  padding: 0;
  text-align: left;
}

.cookie-settings-link:hover,
.cookie-settings-link:focus-visible {
  color: #fff;
  text-decoration: underline;
}

.map-card {
  align-self: start;
}

.map-preview {
  position: relative;
  display: grid;
  min-height: 150px;
  align-content: center;
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.86), rgba(255, 255, 255, 0.74)),
    repeating-linear-gradient(32deg, rgba(10, 29, 54, 0.16) 0 2px, transparent 2px 22px),
    linear-gradient(90deg, #cfe7f1 0 35%, #f2f4ef 35% 62%, #a8d9e9 62%);
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.16);
  color: var(--ink);
  overflow: hidden;
  padding: 20px 22px 20px 70px;
}

.footer .map-preview {
  color: var(--ink);
}

.map-preview span {
  position: absolute;
  left: 28px;
  top: 50%;
  width: 24px;
  height: 24px;
  border-radius: 50% 50% 50% 0;
  background: var(--red);
  box-shadow: 0 8px 22px rgba(203, 16, 46, 0.32);
  transform: translateY(-62%) rotate(-45deg);
}

.map-preview span::after {
  position: absolute;
  inset: 7px;
  border-radius: 50%;
  background: #fff;
  content: "";
}

.map-preview strong {
  position: relative;
  font-size: 0.88rem;
  line-height: 1.35;
}

.map-card-link {
  display: inline-flex;
  margin-top: 12px;
  color: #fff;
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.map-card p {
  margin-top: 14px;
  font-size: 0.82rem;
  text-transform: uppercase;
}

.cookie-consent {
  position: fixed;
  z-index: 60;
  right: 18px;
  bottom: 18px;
  display: grid;
  width: min(calc(100% - 36px), 760px);
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(6, 20, 38, 0.98);
  box-shadow: 0 24px 80px rgba(5, 26, 45, 0.34);
  color: #fff;
  padding: 20px;
}

.cookie-consent h2 {
  margin-bottom: 8px;
  color: #fff;
  font-size: 1.1rem;
}

.cookie-consent p {
  margin-bottom: 8px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.88rem;
}

.cookie-consent a {
  color: #fff;
  font-size: 0.82rem;
  font-weight: 800;
  text-decoration: underline;
}

.cookie-consent-panel {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.cookie-option {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: center;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  padding: 12px;
}

.cookie-option strong,
.cookie-option small {
  display: block;
}

.cookie-option strong {
  color: #fff;
  font-size: 0.86rem;
}

.cookie-option small {
  margin-top: 4px;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.74rem;
  line-height: 1.45;
}

.cookie-option input {
  width: 20px;
  height: 20px;
  accent-color: var(--red);
}

.cookie-consent-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
  align-content: start;
}

.cookie-consent .button {
  min-height: 42px;
  border-radius: 999px;
  font-size: 0.72rem;
  padding: 12px 16px;
}

.cookie-consent .button.light {
  border: 1px solid rgba(255, 255, 255, 0.26);
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.cookie-consent .button.ghost {
  border: 1px solid rgba(255, 255, 255, 0.26);
  background: transparent;
  color: #fff;
}

.copyright {
  display: block;
  margin-top: 28px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding-top: 16px;
  text-align: center;
}

/* Menú de hamburguesa: con siete entradas, el menú de escritorio necesita al menos 1280 px en alemán */
@media (max-width: 1279px) {
  .site-header {
    grid-template-columns: auto auto;
    width: min(calc(100% - 30px), 760px);
  }

  .brand {
    min-width: 0;
  }

  .menu-button {
    display: block;
    justify-self: end;
  }

  .site-nav {
    position: fixed;
    top: 98px;
    left: 18px;
    right: 18px;
    display: none;
    border-radius: 18px;
    background: rgba(10, 29, 54, 0.98);
    padding: 20px;
    box-shadow: var(--shadow);
  }

  .site-nav.is-open {
    display: grid;
    gap: 6px;
  }

  .site-nav a {
    padding: 14px 0;
  }

  .mobile-language-row {
    display: flex;
    gap: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.14);
    margin-top: 10px;
    padding-top: 14px;
  }

  .mobile-language-row button {
    min-width: 48px;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    cursor: pointer;
    font: inherit;
    font-size: 0.76rem;
    font-weight: 800;
    padding: 10px 12px;
  }

  .mobile-language-row button.is-active {
    border-color: transparent;
    background: var(--red);
    box-shadow: 0 10px 24px rgba(216, 0, 50, 0.24);
  }

  .header-actions {
    display: none;
  }
}

@media (max-width: 1120px) {
  .feature-strip {
    grid-template-columns: repeat(2, 1fr);
  }

  .feature-strip article:nth-child(2) {
    border-right: 0;
  }

  .method,
  .center-block,
  .footer-grid,
  .page-hero,
  .contact-page {
    grid-template-columns: 1fr;
  }

  .service-map {
    margin-top: 10px;
  }

  .service-map-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .service-map-core {
    order: -1;
  }

  .service-map-column,
  .service-map-center-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .service-map-card::after,
  .service-map::before {
    display: none;
  }

  .service-map-process {
    grid-template-columns: 1fr;
  }

  .service-map-process ol {
    grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
  }

  .orbit {
    margin: 20px auto 0;
  }

  .cards-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .service-list,
  .content-grid-section,
  .legal-detail-section,
  .highlight-band {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .highlight-band div:last-child:nth-child(odd) {
    grid-column: 1 / -1;
  }

  .round-control {
    display: none;
  }
}

@media (max-width: 720px) {
  .site-header {
    top: 14px;
    width: calc(100% - 24px);
  }

  .brand-mark {
    width: 48px;
    height: 48px;
    font-size: 1rem;
  }

  .brand-logo {
    width: 48px;
    height: 48px;
  }

  .brand-copy strong {
    font-size: 0.78rem;
  }

  .brand-copy small {
    display: none;
  }

  .hero {
    min-height: 680px;
    padding: 118px 22px 44px;
  }

  .hero-image {
    object-position: 62% center;
  }

  .hero-shade {
    background:
      linear-gradient(180deg, rgba(10, 29, 54, 0.42) 0%, rgba(10, 29, 54, 0.1) 18%, transparent 38%),
      linear-gradient(90deg, rgba(247, 250, 252, 0.98), rgba(247, 250, 252, 0.75), rgba(247, 250, 252, 0.18)),
      linear-gradient(0deg, rgba(255, 255, 255, 0.86), transparent 44%);
  }

  h1 {
    font-size: clamp(2.15rem, 11vw, 3.35rem);
  }

  .hero-actions {
    display: grid;
  }

  .feature-strip,
  .cards-row,
  .section-head,
  .footer-links,
  .service-list,
  .content-grid-section,
  .legal-detail-section,
  .highlight-band {
    grid-template-columns: 1fr;
  }

  .feature-strip {
    padding: 0 18px;
  }

  .feature-strip article {
    border-right: 0;
    border-bottom: 1px solid var(--line);
    padding: 24px 0;
  }

  .section {
    width: calc(100% - 36px);
    padding: 62px 0;
  }

  .method {
    gap: 22px;
  }

  .service-map {
    padding: 18px;
  }

  .service-map-heading {
    justify-content: flex-start;
    margin-bottom: 18px;
  }

  .service-map-heading img {
    width: 46px;
    height: 46px;
  }

  .service-map-heading strong {
    font-size: 1rem;
  }

  .service-map-heading span {
    font-size: 0.72rem;
  }

  .service-map-column,
  .service-map-center-cards,
  .service-map-process ol {
    grid-template-columns: 1fr;
  }

  .service-map-card {
    min-height: 82px;
  }

  .patient-node {
    width: 132px;
    height: 132px;
  }

  .service-map-process ol {
    gap: 12px;
  }

  .service-map-process li {
    grid-template-columns: 40px 1fr;
    justify-items: start;
    text-align: left;
  }

  .service-map-process li span {
    grid-row: span 2;
  }

  .orbit {
    display: grid;
    aspect-ratio: auto;
    gap: 12px;
  }

  .orbit::before,
  .orbit::after,
  .orbit-center {
    display: none;
  }

  .orbit-item {
    position: static;
    display: grid;
    width: auto;
    grid-template-columns: 54px 1fr;
    justify-items: start;
    text-align: left;
    transform: none;
  }

  .orbit-item span {
    grid-row: span 2;
    width: 48px;
    height: 48px;
    margin-bottom: 0;
  }

  .section-head {
    display: grid;
    align-items: start;
  }

  .page-hero {
    min-height: auto;
    gap: 28px;
    background: var(--navy);
    padding: 116px 22px 44px;
    overflow: hidden;
  }

  .page-hero-copy,
  .page-hero img {
    width: 100%;
    max-width: calc(100vw - 44px);
    min-width: 0;
  }

  .page-hero img {
    min-height: 260px;
  }

  .footer {
    padding-right: 22px;
    padding-left: 22px;
  }

  .cookie-consent {
    right: 12px;
    bottom: 12px;
    width: calc(100% - 24px);
    grid-template-columns: 1fr;
    max-height: calc(100dvh - 24px);
    overflow: auto;
    padding: 16px;
  }

  .cookie-consent-panel {
    grid-template-columns: 1fr;
  }

  .cookie-consent-actions {
    justify-content: stretch;
  }

  .cookie-consent .button {
    flex: 1 1 100%;
    justify-content: center;
  }
}

/* =========================================================================
   Ronda 21/07: portada amplia, icono de cita y pagina de Equipo.
   Sin CDN, sin fuentes remotas y sin librerias: todo local.
   ========================================================================= */

/* --- Portada tipo viewport ------------------------------------------------ */
.hero {
  min-height: max(620px, min(90vh, 900px));
}

.hero picture {
  position: absolute;
  inset: 0;
  display: block;
}

.hero-image {
  object-position: 60% center;
}

/* Serif elegante unicamente en el titular de la portada. */
.hero-content h1 {
  font-family: Georgia, "Iowan Old Style", "Times New Roman", Times, serif;
  font-weight: 400;
  font-size: clamp(2.2rem, 4.1vw, 3.7rem);
  line-height: 1.1;
  letter-spacing: -0.01em;
  overflow-wrap: break-word;
}

/* --- Icono de cita, local y decorativo ------------------------------------ */
.icon-calendar {
  flex: 0 0 auto;
  width: 17px;
  height: 17px;
  vertical-align: -3px;
}

.header-cta .icon-calendar {
  margin-right: -2px;
}

/* --- Encabezado de pagina sin imagen (Equipo) ----------------------------- */
.page-hero.is-text-only {
  grid-template-columns: minmax(0, 1fr);
  min-height: 0;
  background: linear-gradient(110deg, var(--navy), var(--navy-deep)), var(--navy);
  padding-bottom: 92px;
}

.page-hero.is-text-only .page-hero-copy p {
  max-width: 640px;
}

/* --- Galeria del equipo --------------------------------------------------- */
.team-gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
  margin-top: 8px;
}

.team-card {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 5;
  margin: 0;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--blue-soft);
  box-shadow: 0 18px 46px rgba(5, 26, 45, 0.1);
}

.team-card.is-wide {
  grid-column: span 2;
  aspect-ratio: 8 / 5;
}

.team-card picture {
  display: block;
  width: 100%;
  height: 100%;
}

.team-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.team-note {
  margin: 28px 0 0;
  max-width: 620px;
  color: var(--muted);
  font-size: 0.95rem;
}

@media (max-width: 1120px) {
  .team-gallery {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .team-card.is-wide {
    grid-column: span 2;
  }
}

@media (max-width: 720px) {
  .hero {
    min-height: max(560px, min(88vh, 760px));
  }

  .hero-image {
    object-position: 68% center;
  }

  /* Titular serif legible en movil: evita que las lineas forzadas desborden
     incluso a 320 px, el ancho minimo que declara la hoja de estilos. */
  .hero-content h1 {
    font-size: clamp(1.3rem, 7vw, 2.75rem);
  }

  .page-hero.is-text-only {
    padding-bottom: 64px;
  }

  .team-gallery {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }

  .team-card.is-wide {
    grid-column: span 1;
    aspect-ratio: 4 / 3;
  }
}

/* =========================================================================
   Ronda 25/08 de Ekim: carrusel horizontal de especialidades en la portada
   y aviso de texto provisional. Sin librerias ni dependencias externas.
   ========================================================================= */

.service-carousel {
  position: relative;
  margin-top: 8px;
}

.carousel-track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(268px, 1fr);
  gap: 22px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-left: 2px;
  padding: 4px 2px 18px;
  scrollbar-width: thin;
}

/* Tres tarjetas visibles en escritorio; el resto se alcanza desplazando. */
@media (min-width: 981px) {
  .carousel-track {
    grid-auto-columns: calc((100% - 44px) / 3);
  }
}

.carousel-track:focus-visible {
  outline: 2px solid var(--navy);
  outline-offset: 4px;
}

.carousel-item {
  scroll-snap-align: start;
}

.carousel-arrow {
  position: absolute;
  z-index: 3;
  top: calc(50% - 26px);
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 10px 26px rgba(5, 26, 45, 0.16);
  color: var(--navy);
  cursor: pointer;
  font-size: 1.5rem;
  line-height: 1;
  transition: opacity 160ms ease, transform 160ms ease;
}

.carousel-arrow:hover {
  transform: scale(1.06);
}

.carousel-arrow.is-prev { left: -14px; }
.carousel-arrow.is-next { right: -14px; }

.service-carousel.at-start .carousel-arrow.is-prev,
.service-carousel.at-end .carousel-arrow.is-next {
  opacity: 0;
  pointer-events: none;
}

/* Sin JavaScript las flechas no sirven de nada: el desplazamiento tactil si. */
@media (hover: none) {
  .carousel-arrow { display: none; }
}

.provisional-notice {
  padding-top: 0;
  padding-bottom: 0;
}

.provisional-notice p {
  margin: 0;
  border-left: 3px solid var(--red);
  border-radius: 0 10px 10px 0;
  background: var(--blue-soft);
  padding: 14px 18px;
  color: var(--navy);
  font-size: 0.92rem;
}

@media (max-width: 720px) {
  .carousel-track {
    grid-auto-columns: minmax(240px, 78%);
    gap: 14px;
  }
}

/* =========================================================================
   Ronda 26/08 de Ekim: nombres y cargos en Equipo, y contacto por WhatsApp
   con su simbolo. Iconos en SVG local, sin dependencias.
   ========================================================================= */

.team-card figcaption {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  display: grid;
  gap: 6px;
  background: linear-gradient(0deg, rgba(13, 35, 80, 0.92), rgba(13, 35, 80, 0.72) 62%, transparent);
  padding: 34px 18px 16px;
  color: #fff;
}

.team-card figcaption span {
  display: grid;
}

.team-card figcaption strong {
  font-size: 0.95rem;
  font-weight: 800;
  line-height: 1.25;
}

.team-card figcaption small {
  color: rgba(255, 255, 255, 0.82);
  font-size: 0.78rem;
  letter-spacing: 0.02em;
}

/* La tarjeta ancha lleva dos personas: se reparten en dos columnas. */
.team-card.is-wide figcaption {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.icon-whatsapp {
  flex: 0 0 auto;
  vertical-align: -4px;
}

.whatsapp-link {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
}

@media (max-width: 720px) {
  .team-card.is-wide figcaption {
    grid-template-columns: 1fr;
    gap: 8px;
  }
}

/* =========================================================================
   Ronda 06/09 de Ekim: paginas de especialistas y profesionales.
   Estructura tomada de sus maquetas; azul marino, logotipo y pie de la web.
   Iconos en SVG local, sin dependencias.
   ========================================================================= */

.sp-block {
  padding: 64px max(24px, calc((100vw - 1240px) / 2));
}

.sp-icon {
  display: inline-grid;
  flex: 0 0 auto;
  place-items: center;
  color: var(--navy);
}

.sp-icon svg {
  width: 100%;
  height: 100%;
}

/* --- Cabecera: texto a la izquierda, foto a sangre a la derecha ----------- */
.sp-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  min-height: 660px;
  overflow: hidden;
  background: #fff;
  padding-left: max(32px, calc((100vw - 1240px) / 2));
}

.sp-hero-copy {
  position: relative;
  z-index: 2;
  align-self: center;
  max-width: 580px;
  padding: 150px 40px 96px 0;
}

.sp-badge {
  display: inline-block;
  margin-bottom: 18px;
  border-radius: 999px;
  background: var(--navy);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  padding: 8px 16px;
  text-transform: uppercase;
}

.sp-eyebrow {
  margin: 0 0 18px;
  color: var(--navy);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  line-height: 1.5;
  text-transform: uppercase;
}

.sp-page .sp-title {
  margin: 0 0 22px;
  color: var(--navy-deep);
  font-family: Georgia, "Iowan Old Style", "Times New Roman", Times, serif;
  font-size: clamp(2.2rem, 4vw, 3.6rem);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.01em;
  overflow-wrap: break-word;
}

.sp-title small {
  display: block;
  margin-top: 6px;
  color: var(--navy);
  font-size: 0.6em;
  line-height: 1.2;
}

.sp-rule {
  display: block;
  width: 48px;
  height: 2px;
  margin: 0 0 22px;
  background: var(--navy);
}

.sp-page .sp-lead {
  margin: 0 0 14px;
  color: var(--navy-deep);
  font-size: 1.06rem;
  font-weight: 600;
  line-height: 1.55;
}

.sp-page .sp-text {
  margin: 0 0 26px;
  color: #33475f;
  font-size: 0.98rem;
  line-height: 1.7;
}

.sp-tags {
  display: grid;
  gap: 12px;
  margin: 0 0 28px;
  padding: 0;
  list-style: none;
}

.sp-tags li {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--navy-deep);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.sp-tags .sp-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  padding: 9px;
}

.sp-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.sp-page .sp-note {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 22px 0 0;
  color: #33475f;
  font-size: 0.86rem;
  line-height: 1.5;
}

.sp-note .sp-icon {
  width: 26px;
  height: 26px;
}

.sp-hero-media {
  position: relative;
  min-height: 660px;
  margin: 0;
}

.sp-hero-media picture,
.sp-hero-media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.sp-hero-media img {
  object-fit: cover;
  object-position: var(--focus, 50% 30%);
}

/* Fundido hacia el texto, como en las maquetas. */
.sp-hero-media::before {
  content: "";
  position: absolute;
  z-index: 1;
  top: 0;
  bottom: 0;
  left: 0;
  width: 34%;
  background: linear-gradient(90deg, #fff, rgba(255, 255, 255, 0));
}

.sp-namecard {
  position: absolute;
  z-index: 2;
  right: 28px;
  bottom: 70px;
  display: flex;
  align-items: center;
  gap: 14px;
  max-width: 320px;
  border-radius: 12px;
  background: var(--navy-deep);
  box-shadow: var(--shadow);
  color: #fff;
  padding: 14px 18px;
}

.sp-namecard .sp-icon {
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 50%;
  color: #fff;
  padding: 9px;
}

.sp-namecard strong {
  display: block;
  font-size: 0.96rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.sp-namecard small {
  display: block;
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.8rem;
  line-height: 1.4;
}

/* --- Tira de servicios con iconos, montada sobre la cabecera -------------- */
.sp-features {
  position: relative;
  z-index: 3;
  margin-top: -54px;
  padding-top: 0;
}

.sp-card {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 18px 50px rgba(13, 35, 80, 0.08);
  padding: 36px 18px;
}

.sp-head {
  max-width: 760px;
  margin: 0 auto 30px;
  text-align: center;
}

.sp-page .sp-head h2,
.sp-page .sp-split-copy h2,
.sp-page .sp-process h2,
.sp-page .sp-band h2 {
  margin: 0 0 12px;
  color: var(--navy-deep);
  font-family: Georgia, "Iowan Old Style", "Times New Roman", Times, serif;
  font-size: clamp(1.7rem, 2.8vw, 2.4rem);
  font-weight: 400;
  line-height: 1.15;
}

.sp-page .sp-head p {
  margin: 0;
  color: #33475f;
  line-height: 1.6;
}

.sp-grid {
  display: grid;
  grid-template-columns: repeat(var(--cols, 5), minmax(0, 1fr));
  row-gap: 30px;
}

.sp-feature {
  border-right: 1px solid var(--line);
  padding: 4px 18px;
  text-align: center;
}

/* Sin separador al final de cada fila. Las variables CSS no valen en un
   selector, asi que cada numero de columnas tiene su clase. */
.sp-grid.cols-3 > :nth-child(3n),
.sp-grid.cols-4 > :nth-child(4n),
.sp-grid.cols-5 > :nth-child(5n),
.sp-grid.cols-6 > :nth-child(6n),
.sp-grid > :last-child {
  border-right: 0;
}

.sp-feature .sp-icon {
  width: 50px;
  height: 50px;
  margin-bottom: 14px;
}

.sp-page .sp-feature h3 {
  margin: 0 0 10px;
  color: var(--navy-deep);
  font-size: 0.9rem;
  line-height: 1.3;
}

.sp-page .sp-feature p {
  margin: 0;
  color: var(--muted);
  font-size: 0.84rem;
  line-height: 1.6;
}

/* --- Foto + texto con lista de comprobacion ------------------------------- */
.sp-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 56px;
  align-items: center;
}

.sp-split.is-reversed .sp-split-media {
  order: 2;
}

.sp-split-media {
  overflow: hidden;
  aspect-ratio: 4 / 3;
  margin: 0;
  border-radius: 16px;
  box-shadow: 0 18px 50px rgba(13, 35, 80, 0.1);
}

.sp-split-media picture,
.sp-split-media img {
  display: block;
  width: 100%;
  height: 100%;
}

.sp-split-media img {
  object-fit: cover;
  object-position: var(--focus, 50% 50%);
}

.sp-page .sp-split-copy p {
  margin: 0 0 14px;
  color: #33475f;
  line-height: 1.7;
}

.sp-page .sp-split-copy p.is-strong {
  color: var(--navy-deep);
  font-weight: 700;
}

.sp-split-copy.is-dark {
  border-radius: 16px;
  background: var(--navy-deep);
  padding: 40px 38px;
}

.sp-page .sp-split-copy.is-dark h2,
.sp-page .sp-split-copy.is-dark p {
  color: #fff;
}

.sp-checks {
  display: grid;
  gap: 12px;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.sp-checks li {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  gap: 12px;
  color: var(--navy-deep);
  font-size: 0.94rem;
  line-height: 1.5;
}

.sp-check {
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  margin-top: 2px;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
}

.sp-check svg {
  width: 12px;
  height: 12px;
}

.sp-checks li strong {
  display: block;
  margin-bottom: 2px;
}

.sp-checks li small {
  display: block;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.55;
}

.sp-quote {
  margin: 24px 0 0;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font-family: Georgia, "Iowan Old Style", "Times New Roman", Times, serif;
  font-size: 1.06rem;
  font-style: italic;
  line-height: 1.55;
  padding: 20px 24px;
}

.sp-split-copy .button {
  margin-top: 14px;
}

/* --- Proceso de atencion por pasos ---------------------------------------- */
.sp-process-card {
  border-radius: 18px;
  background: var(--navy-deep);
  padding: 36px 34px;
}

.sp-page .sp-process h2 {
  color: #fff;
}

.sp-process ol {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 24px;
  margin: 26px 0 0;
  padding: 0;
  list-style: none;
}

.sp-num {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  margin-bottom: 14px;
  border-radius: 50%;
  background: #fff;
  color: var(--navy-deep);
  font-weight: 800;
}

.sp-page .sp-process h3 {
  margin: 0 0 8px;
  color: #fff;
  font-size: 0.84rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.sp-page .sp-process p {
  margin: 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.86rem;
  line-height: 1.55;
}

/* --- Banda azul de cita --------------------------------------------------- */
.sp-band-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 26px;
  align-items: center;
  border-radius: 16px;
  background: var(--navy-deep);
  padding: 26px 34px;
}

.sp-band-card > .sp-icon {
  width: 66px;
  height: 66px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  padding: 17px;
}

.sp-page .sp-band h2 {
  margin-bottom: 6px;
  color: #fff;
  font-size: clamp(1.35rem, 2.2vw, 1.8rem);
}

.sp-page .sp-band p {
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  line-height: 1.55;
}

.sp-band-cta {
  display: grid;
  justify-items: center;
  gap: 8px;
}

.sp-band-cta small {
  color: rgba(255, 255, 255, 0.76);
  font-size: 0.8rem;
}

.sp-band .button.light,
.sp-values .button.light {
  border-color: #fff;
  background: #fff;
  box-shadow: none;
  color: var(--navy-deep);
}

/* --- Banda de valores ----------------------------------------------------- */
.sp-values-card {
  border-radius: 16px;
  background: var(--navy-deep);
  padding: 32px 18px;
}

.sp-value {
  border-right: 1px solid rgba(255, 255, 255, 0.14);
  padding: 4px 18px;
  text-align: center;
}

.sp-value:last-child {
  border-right: 0;
}

.sp-value .sp-icon {
  width: 40px;
  height: 40px;
  margin-bottom: 12px;
  color: #fff;
}

.sp-page .sp-value h3 {
  margin: 0 0 6px;
  color: #fff;
  font-size: 0.92rem;
  line-height: 1.3;
}

.sp-page .sp-value p {
  margin: 0;
  color: rgba(255, 255, 255, 0.76);
  font-size: 0.82rem;
  line-height: 1.5;
}


.sp-block + .sp-block {
  padding-top: 0;
}

.sp-split-copy.is-dark .sp-rule {
  background: rgba(255, 255, 255, 0.55);
}

.sp-page .sp-values .sp-head h2 {
  color: #fff;
}

@media (max-width: 1120px) {
  .sp-hero {
    grid-template-columns: minmax(0, 1fr);
    min-height: 0;
    padding-left: 0;
  }

  .sp-hero-media {
    order: -1;
    min-height: 0;
    aspect-ratio: 4 / 3;
  }

  .sp-hero-media::before {
    top: auto;
    right: 0;
    width: auto;
    height: 32%;
    background: linear-gradient(0deg, #fff, rgba(255, 255, 255, 0));
  }

  .sp-hero-copy {
    max-width: none;
    padding: 18px 32px 90px;
  }

  .sp-namecard {
    bottom: 36px;
  }

  .sp-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .sp-feature,
  .sp-value {
    border-right: 0;
  }

  .sp-split {
    grid-template-columns: minmax(0, 1fr);
    gap: 28px;
  }

  .sp-split.is-reversed .sp-split-media {
    order: 0;
  }

  .sp-process ol {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .sp-band-card {
    grid-template-columns: minmax(0, 1fr);
    justify-items: center;
    text-align: center;
  }
}

@media (max-width: 720px) {
  .sp-block {
    padding: 44px 18px;
  }

  .sp-hero-media {
    aspect-ratio: 1 / 1;
  }

  .sp-hero-copy {
    padding: 14px 22px 80px;
  }

  .sp-page .sp-title {
    font-size: clamp(1.9rem, 8.4vw, 2.6rem);
  }

  .sp-namecard {
    right: 14px;
    bottom: 20px;
    left: 14px;
    max-width: none;
  }

  .sp-grid,
  .sp-process ol {
    grid-template-columns: minmax(0, 1fr);
  }

  .sp-card,
  .sp-values-card,
  .sp-process-card {
    padding: 28px 18px;
  }

  .sp-split-copy.is-dark {
    padding: 30px 22px;
  }
}

/* Carta de bienvenida y segunda rejilla de servicios de las fichas */
.sp-letter {
  position: relative;
  z-index: 3;
  margin-top: -54px;
  padding-top: 0;
}

.sp-letter + .sp-features,
.sp-services {
  margin-top: 0;
}

.sp-letter-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(220px, 300px);
  gap: clamp(28px, 4vw, 56px);
  align-items: center;
  padding: clamp(28px, 4vw, 52px);
}

.sp-letter-body {
  max-width: 680px;
}

.sp-page .sp-letter h2 {
  margin: 0 0 12px;
  color: var(--navy-deep);
  font-family: Georgia, "Iowan Old Style", "Times New Roman", Times, serif;
  font-size: clamp(1.45rem, 2.4vw, 2rem);
  font-style: italic;
  font-weight: 400;
  line-height: 1.2;
}

.sp-letter-body p {
  margin: 0 0 1em;
  color: var(--ink);
  line-height: 1.7;
}

.sp-letter-body .sp-signature {
  display: grid;
  gap: 4px;
  margin: 28px 0 0;
}

.sp-signature strong {
  color: var(--navy);
  font-family: Georgia, "Iowan Old Style", "Times New Roman", Times, serif;
  font-size: 1.45rem;
  font-style: italic;
  font-weight: 400;
}

.sp-signature small {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.sp-letter .sp-quote {
  margin: 0;
  background: var(--navy);
}

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

/* El atributo hidden debe ganar a los display de los componentes (panel y botones del aviso de cookies) */
[hidden] {
  display: none !important;
}
