/* GEA TravelDesign — bloco "Roteiro exemplo"
   Estilos isolados (prefixo gea-rx). Não altera nenhuma regra do site. */

.gea-rx {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: hsl(var(--navy));
  color: hsl(var(--cream));
}
.gea-rx::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(60% 50% at 88% 8%, hsl(var(--gold) / 0.14), transparent 70%),
    radial-gradient(55% 45% at 4% 96%, hsl(var(--navy-light) / 0.55), transparent 70%);
}

/* Revelação ao rolar (só arma se o JS rodou) */
.gea-rx.is-armed [data-rx-reveal] {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
.gea-rx.is-armed [data-rx-reveal].is-in {
  opacity: 1;
  transform: none;
}
.gea-rx.is-armed [data-rx-reveal="2"] { transition-delay: 0.15s; }

/* Cabeçalho */
.gea-rx__head {
  max-width: 48rem;
  margin: 0 auto 3.5rem;
  text-align: center;
}
.gea-rx__label {
  color: hsl(var(--accent));
  font-weight: 500;
  font-size: 0.875rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.gea-rx__title {
  margin: 0.75rem 0 1.5rem;
  font-family: "Playfair Display", Georgia, serif;
  font-weight: 700;
  font-size: 1.875rem;
  line-height: 1.2;
  text-wrap: balance;
  color: hsl(var(--cream));
}
@media (min-width: 768px) { .gea-rx__title { font-size: 2.25rem; } }
@media (min-width: 1024px) { .gea-rx__title { font-size: 3rem; } }
.gea-rx__gold {
  background: var(--gradient-gold);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
.gea-rx__lead {
  margin: 0;
  font-size: 1.125rem;
  line-height: 1.6;
  color: hsl(var(--cream) / 0.72);
}

/* Grade principal: visualizador centralizado, nota e botão abaixo */
.gea-rx__grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: minmax(0, 1fr);
  max-width: 36rem;
  margin: 0 auto;
}
.gea-rx__side { min-width: 0; text-align: center; }

/* Visualizador */
.gea-rx__viewer { min-width: 0; }
.gea-rx__stage {
  position: relative;
  padding: 14px;
  border-radius: 16px;
  background: hsl(var(--cream) / 0.05);
  border: 1px solid hsl(var(--gold) / 0.28);
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, 0.6);
  outline-offset: 4px;
  touch-action: pan-y;
}
.gea-rx__page {
  position: relative;
  aspect-ratio: 595 / 841;
  border-radius: 6px;
  overflow: hidden;
  background: hsl(var(--navy));
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
}
.gea-rx__img,
.gea-rx-lb__img {
  display: block;
  -webkit-user-drag: none;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
}
.gea-rx__img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: opacity 0.25s ease;
}
.gea-rx__img.is-swapping { opacity: 0; }
.gea-rx__shield {
  position: absolute;
  inset: 0;
  cursor: zoom-in;
}
.gea-rx__expand {
  position: absolute;
  top: 26px;
  right: 26px;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  height: 2.25rem;
  padding: 0 0.9rem;
  border-radius: 999px;
  border: 1px solid hsl(var(--gold) / 0.6);
  background: hsl(var(--navy) / 0.88);
  color: hsl(var(--cream));
  font: inherit;
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  transition: background 0.2s ease, transform 0.2s ease;
}
.gea-rx__expand:hover { background: hsl(var(--navy-light)); transform: scale(1.04); }

.gea-rx__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 1rem;
}
.gea-rx__nav,
.gea-rx-lb__btn {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 999px;
  border: 1px solid hsl(var(--gold) / 0.55);
  background: transparent;
  color: hsl(var(--cream));
  cursor: pointer;
  transition: background 0.2s ease, opacity 0.2s ease, transform 0.2s ease;
}
.gea-rx__nav:hover:not(:disabled),
.gea-rx-lb__btn:hover:not(:disabled) { background: hsl(var(--gold) / 0.18); transform: scale(1.06); }
.gea-rx__nav:disabled,
.gea-rx-lb__btn:disabled { opacity: 0.3; cursor: default; }
.gea-rx__nav svg, .gea-rx-lb__btn svg { width: 1.25rem; height: 1.25rem; }
.gea-rx__meta { min-width: 0; text-align: center; }
.gea-rx__count {
  display: block;
  font-weight: 600;
  font-size: 0.95rem;
  color: hsl(var(--cream));
}
.gea-rx__ptitle {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.8rem;
  color: hsl(var(--cream) / 0.6);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.gea-rx__thumbs {
  position: relative;
  display: flex;
  gap: 6px;
  margin-top: 0.75rem;
  padding: 4px 2px 10px;
  overflow-x: auto;
  scrollbar-width: thin;
  scrollbar-color: hsl(var(--gold) / 0.4) transparent;
}
.gea-rx__thumb {
  flex: 0 0 auto;
  width: 44px;
  padding: 0;
  border: 2px solid transparent;
  border-radius: 4px;
  background: #f8f8f8;
  overflow: hidden;
  cursor: pointer;
  opacity: 0.75;
  transition: opacity 0.2s ease, border-color 0.2s ease;
}
.gea-rx__thumb:hover { opacity: 0.9; }
.gea-rx__thumb[aria-current="true"] { opacity: 1; border-color: hsl(var(--gold)); }
.gea-rx__thumb img { display: block; width: 100%; height: auto; pointer-events: none; -webkit-user-drag: none; }

.gea-rx__note {
  margin: 0 auto 1.5rem;
  max-width: 30rem;
  font-size: 0.95rem;
  line-height: 1.6;
  color: hsl(var(--cream) / 0.65);
}
.gea-rx__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  height: 2.75rem;
  padding: 0 2rem;
  border-radius: 0.375rem;
  background: linear-gradient(90deg, hsl(var(--gold)), hsl(var(--gold-dark)));
  color: hsl(var(--primary));
  font-weight: 600;
  font-size: 0.875rem;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: var(--shadow-gold);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.gea-rx__cta:hover { transform: scale(1.05); box-shadow: var(--shadow-medium); }
.gea-rx__cta svg { width: 1rem; height: 1rem; }
@media (max-width: 479px) {
  .gea-rx__cta { width: 100%; }
}

/* Foco visível */
.gea-rx button:focus-visible,
.gea-rx a:focus-visible,
.gea-rx__stage:focus-visible,
.gea-rx-lb button:focus-visible {
  outline: 2px solid hsl(var(--gold));
  outline-offset: 3px;
}

/* ---------- Leitor ampliado ---------- */
.gea-rx-lb {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  flex-direction: column;
  background: #08101e;
  color: hsl(var(--cream));
  opacity: 0;
  transition: opacity 0.2s ease;
}
.gea-rx-lb[hidden] { display: none; }
.gea-rx-lb.is-open { opacity: 1; }
.gea-rx-lb__top,
.gea-rx-lb__bottom {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.6rem 1rem;
}
.gea-rx-lb__top { border-bottom: 1px solid hsl(var(--cream) / 0.1); }
.gea-rx-lb__bottom { border-top: 1px solid hsl(var(--cream) / 0.1); }
.gea-rx-lb__title {
  min-width: 0;
  font-family: "Playfair Display", Georgia, serif;
  font-weight: 700;
  font-size: 1rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.gea-rx-lb__tools { display: flex; gap: 0.5rem; flex: 0 0 auto; }
.gea-rx-lb__zoom { width: auto; padding: 0 1rem; font: inherit; font-size: 0.85rem; font-weight: 600; }
.gea-rx-lb__stage {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  padding: 1rem;
  -webkit-overflow-scrolling: touch;
}
.gea-rx-lb__stage.is-zoomed { cursor: grab; }
.gea-rx-lb__stage.is-grabbing { cursor: grabbing; }
.gea-rx-lb__img {
  margin: 0 auto;
  max-width: none;
  height: auto;
  background: #f8f8f8;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
  transition: opacity 0.2s ease;
  pointer-events: none;
}
.gea-rx-lb__img.is-swapping { opacity: 0; }
.gea-rx-lb__count { font-weight: 600; font-size: 0.95rem; text-align: center; }

@media (prefers-reduced-motion: reduce) {
  .gea-rx.is-armed [data-rx-reveal] { transition: none; opacity: 1; transform: none; }
  .gea-rx__img, .gea-rx-lb, .gea-rx-lb__img, .gea-rx__cta, .gea-rx__expand { transition: none; }
}
