/* Ajuste final del hero y la identidad visual. */
header > div {
  min-height: 4.5rem;
  height: auto;
  padding-top: 0.45rem;
  padding-bottom: 0.45rem;
}

header a[aria-label*="Inicio"] img {
  width: 205px;
  max-width: 44vw;
}

@media (min-width: 1024px) {
  header > div {
    min-height: 5.75rem;
  }

  header a[aria-label*="Inicio"] img {
    width: 270px;
    max-width: 24vw;
  }

  #top > div {
    min-height: 820px;
  }

  #top .home-hero-image {
    inset: 0;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
    object-position: center center;
    transform: none;
    z-index: 1;
    -webkit-mask-image: none;
    mask-image: none;
  }

  #top .home-hero-image + div {
    z-index: 0;
  }

  #top h2 {
    max-width: 100%;
    overflow: visible;
    font-size: clamp(3.5rem, 4.5vw, 5.35rem);
    line-height: 0.96;
  }

  #metricas {
    padding-top: 7rem;
  }
}

#temas > div {
  display: flex;
  flex-direction: column;
}

#temas > div > [class~="mt-10"] {
  order: -1;
  margin-top: 0;
  margin-bottom: 3.5rem;
}

.speaker-event-card {
  margin-top: 1.25rem;
  border: 1px solid color-mix(in oklab, var(--primary) 48%, transparent);
  border-radius: 1.5rem;
  padding: clamp(1.5rem, 3vw, 2rem);
  background:
    radial-gradient(circle at 92% 10%, color-mix(in oklab, var(--primary) 24%, transparent), transparent 42%),
    color-mix(in oklab, var(--card) 88%, transparent);
}

.speaker-event-card h3 {
  margin: 0 0 0.75rem;
  font-family: "Space Grotesk", sans-serif;
  font-size: clamp(1.65rem, 3vw, 2.35rem);
}

.speaker-event-card p {
  margin: 0;
  max-width: 56rem;
  color: var(--muted-foreground);
  line-height: 1.7;
}

.speaker-event-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.35rem;
}

.speaker-event-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.85rem;
  padding: 0.75rem 1.35rem;
  border: 1px solid color-mix(in oklab, var(--primary) 60%, transparent);
  border-radius: 999px;
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 600;
}

.speaker-event-actions a:last-child {
  border-color: transparent;
  background: var(--primary);
  color: var(--primary-foreground);
}

@media (max-width: 640px) {
  .speaker-event-actions {
    flex-direction: column;
  }

  .speaker-event-actions a {
    width: 100%;
  }
}

@media (min-width: 1280px) {
  header a[aria-label*="Inicio"] img {
    width: 300px;
  }
}

/* Menú desplegable de servicios. */
.services-menu {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 3rem;
}

.services-trigger {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  transition: color 180ms ease;
}

.services-trigger span {
  color: var(--primary);
  font-size: 0.8rem;
  transition: transform 180ms ease;
}

.services-submenu {
  position: absolute;
  z-index: 80;
  top: calc(100% - 0.2rem);
  left: 50%;
  width: 18.5rem;
  padding: 0.6rem;
  border: 1px solid var(--border);
  border-radius: 1rem;
  background: color-mix(in oklab, var(--background) 94%, transparent);
  box-shadow: 0 1.25rem 3.5rem rgba(0, 0, 0, 0.48);
  backdrop-filter: blur(18px);
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, 0.6rem);
  transition: opacity 180ms ease, transform 180ms ease, visibility 180ms ease;
}

.services-menu:hover .services-submenu,
.services-menu:focus-within .services-submenu {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}

.services-menu:hover .services-trigger,
.services-menu:focus-within .services-trigger {
  color: var(--foreground);
}

.services-menu:hover .services-trigger span,
.services-menu:focus-within .services-trigger span {
  transform: rotate(180deg);
}

.services-submenu a {
  display: block;
  padding: 0.72rem 0.85rem;
  border-radius: 0.7rem;
  color: var(--muted-foreground);
  line-height: 1.3;
  white-space: normal;
  transition: color 160ms ease, background-color 160ms ease;
}

.services-submenu a:hover,
.services-submenu a:focus-visible {
  color: var(--foreground);
  background: color-mix(in oklab, var(--primary) 14%, transparent);
  outline: none;
}

/* Identidad profesional colocada debajo del foco ejecutivo del hero. */
.hero-identity {
  margin-top: 2rem;
  padding-top: 1.35rem;
  border-top: 1px solid color-mix(in oklab, var(--border) 72%, transparent);
}

.hero-identity-role {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-top: 0.8rem;
  color: var(--muted-foreground);
  font-size: clamp(0.875rem, 1.2vw, 1.1rem);
  line-height: 1.65;
}

/* Servicios en formato vertical: cuatro columnas, dos en tablet y una en móvil. */
.services-vertical-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.25rem;
  align-items: stretch;
}

.service-vertical-card,
.services-vertical-grid .speaker-event-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 31rem;
  margin: 0;
  padding: clamp(1.5rem, 2vw, 2rem);
  border: 1px solid color-mix(in oklab, var(--primary) 34%, var(--border));
  border-radius: 1.5rem;
  background: linear-gradient(155deg, color-mix(in oklab, var(--primary) 11%, var(--card)), var(--card) 58%, color-mix(in oklab, var(--background) 90%, transparent));
  box-shadow: 0 1.25rem 3rem rgba(0, 0, 0, 0.18);
}

.service-card-kicker {
  margin: 0 0 1.5rem;
  color: var(--primary);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.service-vertical-card h3,
.services-vertical-grid .speaker-event-card h3 {
  margin: 0 0 1.2rem;
  font-family: var(--font-display, inherit);
  font-size: clamp(1.55rem, 2vw, 2rem);
  line-height: 1.08;
}

.service-vertical-card > p:not(.service-card-kicker),
.services-vertical-grid .speaker-event-card > p:not(.service-card-kicker) {
  margin: 0;
  color: var(--muted-foreground);
  font-size: 0.95rem;
  line-height: 1.75;
}

.service-card-actions {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  margin-top: auto;
  padding-top: 2rem;
}

.service-card-actions a {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 3rem;
  padding: 0.8rem 1rem;
  border: 1px solid color-mix(in oklab, var(--primary) 62%, transparent);
  border-radius: 999px;
  color: var(--foreground);
  text-align: center;
  text-decoration: none;
  font-size: 0.82rem;
  font-weight: 650;
  line-height: 1.25;
  transition: background-color 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.service-card-actions a:last-child {
  border-color: transparent;
  background: var(--primary);
  color: var(--primary-foreground);
}

.service-card-actions a:hover,
.service-card-actions a:focus-visible {
  transform: translateY(-2px);
}

@media (max-width: 1100px) {
  .services-vertical-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .services-vertical-grid {
    grid-template-columns: 1fr;
  }

  .service-vertical-card,
  .services-vertical-grid .speaker-event-card {
    min-height: 27rem;
  }
}


/* === HERO V14 — fullscreen desktop + centered mobile copy === */
#top {
  background: #050609;
}

#top > div {
  min-height: 100svh;
}

#top .home-hero-image {
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: center center;
  transform: none;
  z-index: 1;
  -webkit-mask-image: none;
  mask-image: none;
}

#top .hero-overlay {
  z-index: 2;
  background: linear-gradient(90deg, rgba(2,3,6,.03) 0%, rgba(2,3,6,.06) 43%, rgba(2,3,6,.36) 57%, rgba(2,3,6,.88) 74%, rgba(2,3,6,.98) 100%);
}

#top > div > .relative.z-10 {
  min-height: 100svh;
  display: grid;
  align-items: center;
}

#top .hero-copy {
  position: relative;
  z-index: 3;
}

#top .hero-identity {
  margin-top: 1.65rem;
  padding-top: 1.2rem;
}

#metricas {
  position: relative;
  z-index: 5;
  margin-top: 0 !important;
}

@media (min-width: 1024px) {
  #top {
    padding-top: 0 !important;
  }

  #top > div {
    min-height: 100vh;
    min-height: 100svh;
  }

  #top > div > .relative.z-10 {
    min-height: 100vh;
    min-height: 100svh;
    padding-top: 7.5rem;
    padding-bottom: 4rem;
  }

  #top .home-hero-image {
    object-position: center center;
  }

  #top .hero-copy {
    align-self: center;
    text-align: left;
    max-width: 620px;
    margin-left: auto;
  }

  #top h2 {
    margin-top: 0;
    font-size: clamp(3.6rem, 4.7vw, 5.7rem);
    line-height: .94;
  }

  #metricas {
    padding-top: 5rem;
  }
}

@media (max-width: 1023px) {
  #top > div {
    min-height: 100svh;
    align-items: stretch;
  }

  #top .home-hero-image {
    object-position: 32% center;
  }

  #top .hero-overlay {
    background:
      linear-gradient(to bottom, rgba(3,4,7,.16) 0%, rgba(3,4,7,.46) 30%, rgba(3,4,7,.84) 58%, rgba(3,4,7,.98) 100%),
      linear-gradient(to right, rgba(3,4,7,.2), rgba(3,4,7,.52));
  }

  #top > div > .relative.z-10 {
    min-height: 100svh;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-top: 7.5rem;
    padding-bottom: 3.25rem;
  }

  #top .hero-copy {
    width: min(100%, 43rem);
    margin-inline: auto;
    padding-top: 0;
    text-align: center;
  }

  #top .hero-copy h2 {
    margin-top: 0;
    font-size: clamp(2.6rem, 10.5vw, 4.75rem);
    line-height: .96;
  }

  #top .hero-copy p {
    margin-left: auto;
    margin-right: auto;
  }

  #top .hero-copy > p:nth-of-type(3) {
    display: block;
    width: fit-content;
    max-width: 34rem;
    border-left: 0;
    border-top: 2px solid var(--primary);
    padding-left: 0;
    padding-top: .9rem;
  }

  #top .hero-identity {
    max-width: 36rem;
    margin-left: auto;
    margin-right: auto;
  }

  #top .hero-identity-role {
    justify-content: center;
    text-align: center;
  }

  #top .hero-identity-role > span:first-child {
    display: none;
  }

  #metricas {
    padding-top: 3.25rem;
  }
}

@media (max-width: 640px) {
  #top > div > .relative.z-10 {
    padding-left: 1.15rem;
    padding-right: 1.15rem;
    padding-top: 6.75rem;
    padding-bottom: 2.5rem;
  }

  #top .hero-copy h2 {
    font-size: clamp(2.45rem, 12vw, 3.65rem);
  }

  #top .hero-copy > p {
    font-size: .93rem;
    line-height: 1.55;
  }

  #top .hero-copy > p:nth-of-type(3) {
    font-size: .78rem;
    line-height: 1.5;
    letter-spacing: .065em;
  }

  #top .hero-identity {
    margin-top: 1.2rem;
    padding-top: 1rem;
  }

  #top .hero-identity h1 {
    font-size: 1.55rem;
  }

  #top .hero-identity-role {
    margin-top: .55rem;
    font-size: .82rem;
    line-height: 1.5;
  }
}

/* === SERVICES V15: 3 portrait cards, equal CTA prominence === */
.services-v15-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.services-v15-grid .service-vertical-card {
  min-height: 36rem;
}
.services-v15-grid .service-card-actions a,
.services-v15-grid .service-card-actions a:last-child {
  border-color: transparent;
  background: linear-gradient(90deg, #4f65ff 0%, #b84fe8 100%);
  color: #fff;
  box-shadow: 0 10px 30px rgba(103, 80, 255, 0.18);
}
.services-v15-grid .service-card-actions a:hover,
.services-v15-grid .service-card-actions a:focus-visible {
  filter: brightness(1.08);
}
@media (max-width: 980px) {
  .services-v15-grid { grid-template-columns: 1fr; }
  .services-v15-grid .service-vertical-card { min-height: auto; }
}
