/* Turismo Majagual — layout, héroes, cards */

.eg-visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.eg-btn {
  border-radius: 999px;
  letter-spacing: 0.01em;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.eg-btn--solid {
  background: var(--eg-primary);
  border-color: var(--eg-primary);
  color: #fff;
}

.eg-btn--solid:hover {
  background: color-mix(in srgb, var(--eg-primary) 82%, #0a2a28);
  border-color: color-mix(in srgb, var(--eg-primary) 82%, #0a2a28);
  color: #fff;
  text-decoration: none;
  transform: translateY(-1px);
}

.eg-btn--ghost {
  background: color-mix(in srgb, #fff 18%, transparent);
  border-color: color-mix(in srgb, #fff 55%, transparent);
  color: #fff;
}

.eg-btn--ghost:hover {
  background: color-mix(in srgb, #fff 28%, transparent);
  text-decoration: none;
}

.egt-scheme-light .eg-btn--ghost {
  background: transparent;
  border-color: color-mix(in srgb, var(--eg-heading) 22%, transparent);
  color: var(--eg-heading);
}

.eg-hero .eg-btn--ghost,
.eg-cta-band .eg-btn--ghost {
  background: color-mix(in srgb, #fff 18%, transparent);
  border-color: color-mix(in srgb, #fff 55%, transparent);
  color: #fff;
}

.eg-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

/* Hero portada */
.eg-hero {
  position: relative;
  height: 680px;
  min-height: 680px;
  max-height: 680px;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  color: #fff;
}

.eg-hero__slides,
.eg-hero__slide,
.eg-hero__media,
.eg-page-hero__media {
  position: absolute;
  inset: 0;
}

.eg-hero__media,
.eg-page-hero__media,
.eg-hero__slide {
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--eg-primary) 55%, #143028) 0%, color-mix(in srgb, var(--eg-secondary) 50%, #143028) 100%);
  background-size: cover;
  background-position: center;
}

.eg-hero__slide {
  opacity: 0;
  transform: scale(1.06);
  transition: opacity 0.5s ease;
  z-index: 0;
}

.eg-hero__slide.is-active {
  opacity: 1;
  transform: scale(1);
  z-index: 1;
  animation: eg-hero-ken 3.4s ease-out forwards;
}

@keyframes eg-hero-ken {
  from {
    transform: scale(1);
  }
  to {
    transform: scale(1.08);
  }
}

.eg-hero__veil,
.eg-page-hero__veil {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}

.eg-hero__veil {
  background:
    linear-gradient(90deg, rgba(10, 28, 26, 0.28) 0%, rgba(10, 28, 26, 0.1) 52%, rgba(10, 28, 26, 0.04) 100%),
    linear-gradient(180deg, rgba(10, 28, 26, 0.04) 0%, rgba(10, 28, 26, 0.26) 100%);
}

.eg-page-hero__veil {
  background:
    linear-gradient(180deg, rgba(10, 28, 26, 0.42) 0%, rgba(10, 28, 26, 0.62) 55%, rgba(10, 28, 26, 0.78) 100%);
}

.eg-hero__inner {
  position: relative;
  z-index: 3;
  width: min(1140px, calc(100% - 48px));
  margin: 0 auto;
  padding: 48px 0 72px;
}

.eg-hero__panel {
  max-width: 34rem;
  padding: 26px 28px 28px;
  border-radius: 22px;
  background: color-mix(in srgb, #0c201e 26%, transparent);
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 18px 40px rgba(10, 28, 26, 0.12);
  backdrop-filter: blur(8px) saturate(1.15);
  -webkit-backdrop-filter: blur(8px) saturate(1.15);
}

.eg-hero__eyebrow,
.eg-page-hero__eyebrow {
  color: color-mix(in srgb, var(--eg-secondary) 40%, #fff);
}

.eg-hero__title {
  margin: 0 0 14px;
  max-width: 16ch;
  color: #fff;
  font-size: clamp(32px, 4.6vw, 56px);
  font-weight: 700;
  letter-spacing: -0.045em;
  line-height: 1.08;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.28);
}

.eg-hero__lead {
  margin: 0;
  max-width: 38ch;
  color: rgba(255, 255, 255, 0.9);
  font-size: clamp(15px, 1.5vw, 18px);
  line-height: 1.55;
}

.eg-hero__controls {
  position: absolute;
  z-index: 4;
  right: max(24px, calc((100% - 1140px) / 2));
  bottom: 28px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.eg-hero__arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 50%;
  background: color-mix(in srgb, #0c201e 35%, transparent);
  color: #fff;
  cursor: pointer;
}

.eg-hero__arrow:hover {
  background: color-mix(in srgb, var(--eg-primary) 70%, #0c201e);
  border-color: var(--eg-primary);
}

.eg-hero__dots {
  display: flex;
  gap: 8px;
}

.eg-hero__dot {
  width: 9px;
  height: 9px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  cursor: pointer;
}

.eg-hero__dot.is-active {
  background: #fff;
  transform: scale(1.15);
}

/* Hero internas */
.eg-page-hero {
  position: relative;
  min-height: 240px;
  height: 240px;
  display: flex;
  align-items: flex-end;
  padding: 0 !important;
  overflow: hidden;
}

.eg-page-hero__inner {
  position: relative;
  z-index: 3;
  padding: 36px 0 32px;
}

.eg-page-hero .eg-sec__eyebrow,
.eg-page-hero__eyebrow {
  color: #fff !important;
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.35);
}

.eg-page-hero__title {
  margin: 0 0 10px;
  max-width: 20ch;
  color: #fff !important;
  font-size: clamp(26px, 3.4vw, 40px);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.12;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.4);
}

.eg-page-hero__text {
  margin: 0;
  max-width: 46ch;
  color: rgba(255, 255, 255, 0.92) !important;
  font-size: 15px;
  line-height: 1.55;
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.35);
}

/* Stats */
.eg-stats {
  padding: 0 24px !important;
  background: var(--eg-heading);
  color: #fff;
}

.eg-stats__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
}

.eg-stats__item {
  padding: 28px 20px;
  border-left: 1px solid rgba(255, 255, 255, 0.1);
}

.eg-stats__item:first-child {
  border-left: 0;
}

.eg-stats__item strong {
  display: block;
  color: var(--eg-primary);
  font-size: clamp(22px, 2.4vw, 32px);
  font-weight: 700;
  letter-spacing: -0.03em;
}

.eg-stats__item span {
  display: block;
  margin-top: 6px;
  color: rgba(255, 255, 255, 0.7);
  font-size: 13px;
  line-height: 1.4;
}

/* Splits y fotos */
.eg-photo,
.eg-photo__img {
  width: 100%;
  border-radius: 22px;
}

.eg-photo {
  overflow: hidden;
  background: color-mix(in srgb, var(--eg-primary) 16%, #dceee8);
  aspect-ratio: 4 / 3;
}

.eg-photo__img,
.eg-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.eg-authorities__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
}

.eg-authorities__card {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--eg-border);
  border-radius: 22px;
  background: var(--eg-bg-soft);
}

.eg-authorities__photo {
  aspect-ratio: 4 / 3;
  border-radius: 0;
}

.eg-authorities__photo img {
  object-fit: contain;
  border-radius: 0;
}

.eg-authorities__card h3 {
  margin: 0;
  padding: 20px 24px;
  color: var(--eg-heading);
  font-size: 20px;
}

@media (max-width: 640px) {
  .eg-authorities__grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

.eg-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  gap: 48px 56px;
  align-items: center;
}

.eg-split__photo {
  aspect-ratio: 5 / 4;
}

.eg-split-sec .eg-sec__text {
  max-width: none;
}

.eg-split__copy .eg-btn {
  margin-top: 28px;
}

.eg-sec--tint {
  background: color-mix(in srgb, var(--eg-secondary) 7%, var(--eg-bg));
}

.eg-sec__header--center {
  text-align: center;
  margin-inline: auto;
}

.eg-sec__header--center .eg-sec__text {
  margin-inline: auto;
  text-align: center;
}

.eg-sec__header--row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 36px;
}

.eg-sec__header--row .eg-sec__text {
  margin-bottom: 0;
}

.eg-sec__more {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 36px 0 0;
}

/* Cards */
.eg-card-grid,
.eg-route-grid,
.eg-dish-grid,
.eg-plan-grid,
.eg-mission-grid,
.eg-video-grid {
  display: grid;
  gap: 20px;
}

.eg-card-grid--3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.eg-card-grid--4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.eg-info-card,
.eg-photo-card,
.eg-route-card,
.eg-dish-card,
.eg-plan-card,
.eg-mission-card {
  border: 1px solid var(--eg-border);
  border-radius: 22px;
  background: var(--eg-bg-soft);
  overflow: hidden;
  box-shadow: 0 18px 40px color-mix(in srgb, #143028 6%, transparent);
}

.eg-info-card {
  padding: 24px 22px 26px;
}

.eg-info-card h3,
.eg-photo-card h3,
.eg-route-card h3,
.eg-dish-card h3,
.eg-plan-card h3 {
  margin: 0 0 8px;
  color: var(--eg-heading);
  font-size: 18px;
  font-weight: 650;
  letter-spacing: -0.02em;
}

.eg-info-card p,
.eg-photo-card p,
.eg-route-card p,
.eg-dish-card p,
.eg-plan-card p,
.eg-mission-card p {
  margin: 0;
  color: var(--eg-muted);
  font-size: 14px;
  line-height: 1.65;
  text-align: justify;
  hyphens: none;
  -webkit-hyphens: none;
  -ms-hyphens: none;
  word-break: normal;
  overflow-wrap: break-word;
}

.eg-photo-card .eg-photo,
.eg-route-card .eg-photo,
.eg-dish-card .eg-photo,
.eg-plan-card .eg-photo,
.eg-mission-card .eg-photo {
  border-radius: 0;
  aspect-ratio: 16 / 10;
}

.eg-photo-card__body,
.eg-dish-card__body,
.eg-plan-card__body,
.eg-route-card__body,
.eg-mission-card__body {
  padding: 18px 18px 22px;
}

.eg-route-card {
  position: relative;
  display: flex;
  flex-direction: column;
  color: inherit;
  text-decoration: none !important;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.eg-route-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 22px 48px color-mix(in srgb, #143028 12%, transparent);
}

.eg-route-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.eg-route-grid--3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.eg-route-grid--seven {
  grid-template-columns: repeat(12, minmax(0, 1fr));
}

.eg-route-grid--seven > * {
  grid-column: span 3;
}

.eg-route-grid--seven > :nth-child(5) {
  grid-column: 2 / span 3;
}

.eg-route-grid--seven > :nth-child(6) {
  grid-column: 5 / span 3;
}

.eg-route-grid--seven > :nth-child(7) {
  grid-column: 8 / span 3;
}

.eg-route-detail .eg-sec__inner.eg-route-detail__inner {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  width: min(960px, 100%);
  max-width: 960px;
}

.eg-route-detail__kicker,
.eg-route-detail__title {
  width: 100%;
  max-width: none;
  text-align: center;
}

.eg-route-detail__copy {
  width: 100%;
  max-width: none;
}

.eg-route-detail .eg-sec__text {
  width: 100%;
  max-width: none;
  text-align: justify;
}

.eg-route-detail__photo {
  width: 100%;
  max-width: none;
  max-height: none;
  aspect-ratio: 2.4 / 1;
  margin: 20px 0 8px;
}

.eg-route-detail__chips {
  justify-content: center;
  width: 100%;
  margin: 8px 0 0;
}

.eg-route-detail__actions {
  justify-content: center;
  width: 100%;
  margin-top: 28px;
}

.eg-route-card__num {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 1;
  padding: 4px 10px;
  border-radius: 999px;
  background: color-mix(in srgb, #143028 72%, transparent);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.eg-route-card__type {
  margin: 0 0 6px !important;
  color: var(--eg-secondary) !important;
  font-size: 11px !important;
  font-weight: 600;
  letter-spacing: 1.2px;
  text-transform: uppercase;
}

.eg-route-card__stops {
  margin-top: 10px !important;
  color: var(--eg-heading) !important;
  font-size: 12px !important;
}

.eg-mission-grid {
  grid-template-columns: 1fr 1fr;
}

.eg-dish-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.eg-plan-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.eg-cta-band {
  background:
    linear-gradient(120deg, color-mix(in srgb, var(--eg-primary) 88%, #143028), color-mix(in srgb, var(--eg-secondary) 80%, #143028));
  color: #fff;
}

.eg-cta-band .eg-sec__eyebrow,
.eg-cta-band h2,
.eg-cta-band p {
  color: #fff;
}

.eg-cta-band h2 {
  margin: 0 0 10px;
  max-width: 18ch;
  font-size: clamp(28px, 3.4vw, 42px);
  letter-spacing: -0.03em;
}

.eg-cta-band p {
  margin: 0;
  max-width: 46ch;
  color: rgba(255, 255, 255, 0.86);
}

.eg-cta-band__inner {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
}

.eg-cta-band__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.eg-cta-band .eg-btn--solid {
  background: #fff;
  border-color: #fff;
  color: #143028;
}

.eg-video-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.eg-video {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 18px;
  background: #143028;
}

.eg-video iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.eg-meta-list,
.eg-goal-list,
.eg-check-list {
  margin: 18px 0 22px;
  padding: 0;
  list-style: none;
}

.eg-meta-list li,
.eg-goal-list li,
.eg-check-list li {
  position: relative;
  margin: 0 0 12px;
  padding-left: 18px;
  color: var(--eg-muted);
  font-size: 15px;
  line-height: 1.6;
}

.eg-meta-list li::before,
.eg-check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--eg-primary);
}

.eg-goal-list {
  counter-reset: eg-goal;
}

.eg-goal-list li {
  padding-left: 42px;
  counter-increment: eg-goal;
}

.eg-goal-list li::before {
  content: counter(eg-goal, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 0;
  color: var(--eg-secondary);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.04em;
}

.eg-check-list--grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px 28px;
}

.eg-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 8px 0 22px;
}

.eg-chip {
  display: inline-flex;
  padding: 6px 12px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--eg-secondary) 12%, transparent);
  color: var(--eg-heading);
  font-size: 12px;
  font-weight: 600;
}

.eg-wa-float {
  position: fixed;
  right: 22px;
  bottom: 80px;
  z-index: 900;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #25d366;
  color: #fff !important;
  box-shadow: 0 12px 28px rgba(20, 48, 40, 0.22);
  text-decoration: none !important;
}

.eg-wa-float:hover {
  color: #fff !important;
  transform: translateY(-2px);
}

body.eg-nav-open .eg-wa-float {
  opacity: 0;
  pointer-events: none;
}

.eg-contact-sec {
  padding-top: 64px;
}

.eg-contact-sec .egc-contact__header {
  display: none;
}

@media (max-width: 1024px) {
  .eg-card-grid--4,
  .eg-dish-grid,
  .eg-route-grid--3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .eg-video-grid,
  .eg-stats__grid {
    grid-template-columns: 1fr 1fr;
  }

  .eg-stats__item:nth-child(3) {
    border-left: 0;
  }
}

@media (max-width: 900px) {
  .eg-hero {
    height: 560px;
    min-height: 560px;
    max-height: 560px;
  }

  .eg-hero__inner,
  .eg-page-hero__inner {
    width: calc(100% - 40px);
    padding-bottom: 64px;
  }

  .eg-hero__panel {
    padding: 20px 18px 22px;
    border-radius: 18px;
  }

  .eg-hero__controls {
    right: 16px;
    bottom: 16px;
  }

  .eg-split,
  .eg-mission-grid,
  .eg-route-grid:not(.eg-route-grid--seven):not(.eg-route-grid--3),
  .eg-plan-grid,
  .eg-cta-band__inner,
  .eg-check-list--grid,
  .eg-sec__header--row {
    grid-template-columns: 1fr;
    display: flex;
    flex-direction: column;
    align-items: stretch;
  }

  .eg-card-grid--3 {
    grid-template-columns: 1fr;
  }

  .eg-page-hero {
    min-height: 200px;
    height: 200px;
  }

  .eg-route-grid--seven {
    grid-template-columns: 1fr 1fr;
  }

  .eg-route-grid--seven > *,
  .eg-route-grid--seven > :nth-child(n) {
    grid-column: auto;
  }

  .eg-route-detail__photo {
    aspect-ratio: 16 / 8;
  }
}

@media (max-width: 640px) {
  .eg-dish-grid,
  .eg-card-grid--4,
  .eg-video-grid,
  .eg-stats__grid,
  .eg-route-grid--seven,
  .eg-route-grid--3 {
    grid-template-columns: 1fr;
  }

  .eg-stats__item {
    border-left: 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
  }

  .eg-wa-float {
    right: 16px;
    bottom: 72px;
    width: 48px;
    height: 48px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .eg-hero__slide,
  .eg-hero__slide.is-active {
    transition: none;
    animation: none;
    transform: none;
  }

  .eg-route-card,
  .eg-btn,
  .eg-wa-float {
    transition: none;
  }

  .eg-route-card:hover,
  .eg-btn--solid:hover {
    transform: none;
  }
}
