/* ============================================================
   AUREA VIAJES — Hojas de estilo personalizadas
   Paleta: medianoche profundo + dorado + marfil
   ============================================================ */

:root {
  --midnight: #060a13;
  --midnight-2: #0a101d;
  --surface: #0e1526;
  --surface-2: #131c31;
  --gold: #d9a441;
  --gold-light: #f2c879;
  --gold-deep: #b9832a;
  --ivory: #f4eee0;
  --muted: #8b93a7;
  --line: rgba(217, 164, 65, 0.18);
}

* { -webkit-tap-highlight-color: transparent; }

html { scroll-behavior: smooth; }

body {
  background-color: var(--midnight);
  color: var(--ivory);
  font-family: "Plus Jakarta Sans", sans-serif;
  overflow-x: hidden;
}

::selection { background: var(--gold); color: var(--midnight); }

/* ---------- Scrollbar ---------- */
::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--midnight-2); }
::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--gold), var(--gold-deep));
  border-radius: 8px;
  border: 2px solid var(--midnight-2);
}

/* ---------- Tipografía ---------- */
.font-display { font-family: "Playfair Display", serif; }

.text-gold-grad {
  background: linear-gradient(115deg, #f6d894 0%, #d9a441 45%, #f2c879 70%, #b9832a 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  background-size: 200% auto;
  animation: goldShift 6s linear infinite;
}
@keyframes goldShift {
  0% { background-position: 0% center; }
  100% { background-position: 200% center; }
}

/* ---------- Preloader ---------- */
#preloader {
  position: fixed; inset: 0; z-index: 100;
  background: var(--midnight);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  transition: opacity 0.7s ease, visibility 0.7s ease;
}
#preloader.hidden { opacity: 0; visibility: hidden; }
.preloader-ring {
  width: 72px; height: 72px; border-radius: 50%;
  border: 2px solid rgba(217,164,65,.15);
  border-top-color: var(--gold);
  animation: spin 1s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Entrada de página ---------- */
@keyframes pageIn { from { opacity: 0; } to { opacity: 1; } }
.page-enter { animation: pageIn 0.8s ease both; }

/* ---------- Navbar ---------- */
#navbar {
  transition: background 0.45s ease, box-shadow 0.45s ease, padding 0.45s ease, border-color .45s ease;
  border-bottom: 1px solid transparent;
}
#navbar.nav-scrolled {
  background: rgba(6, 10, 19, 0.82);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-bottom-color: var(--line);
  box-shadow: 0 18px 45px -20px rgba(0, 0, 0, 0.75);
}
.nav-link { position: relative; transition: color .3s ease; }
.nav-link::after {
  content: ""; position: absolute; left: 0; bottom: -6px;
  width: 100%; height: 1.5px;
  background: linear-gradient(90deg, var(--gold-light), var(--gold));
  transform: scaleX(0); transform-origin: right;
  transition: transform 0.4s cubic-bezier(.65,.05,.36,1);
}
.nav-link:hover::after, .nav-link.active::after { transform: scaleX(1); transform-origin: left; }
.nav-link.active { color: var(--gold-light); }

/* Menú móvil */
#mobile-menu {
  transition: clip-path .6s cubic-bezier(.77,0,.18,1);
  clip-path: circle(0% at calc(100% - 3rem) 3rem);
}
#mobile-menu.open { clip-path: circle(150% at calc(100% - 3rem) 3rem); }

/* ---------- Hero ---------- */
.hero-bg {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  will-change: transform;
  animation: kenBurns 22s ease-in-out infinite alternate;
}
@keyframes kenBurns {
  from { transform: scale(1) translateY(0); }
  to { transform: scale(1.12) translateY(-1.5%); }
}
.hero-vignette {
  background:
    radial-gradient(ellipse 90% 65% at 50% 32%, transparent 0%, rgba(6,10,19,.35) 62%, rgba(6,10,19,.92) 100%),
    linear-gradient(180deg, rgba(6,10,19,.55) 0%, rgba(6,10,19,.18) 38%, rgba(6,10,19,.96) 100%);
}

.hero-line { overflow: hidden; display: block; }
.hero-line > span {
  display: block;
  transform: translateY(115%);
  animation: lineUp 1.1s cubic-bezier(.19,1,.22,1) forwards;
}
.hero-line:nth-child(1) > span { animation-delay: .25s; }
.hero-line:nth-child(2) > span { animation-delay: .42s; }
.hero-line:nth-child(3) > span { animation-delay: .59s; }
@keyframes lineUp { to { transform: translateY(0); } }

.fade-hero { opacity: 0; animation: fadeHero 1.2s ease forwards; }
.fade-hero.d1 { animation-delay: .9s; }
.fade-hero.d2 { animation-delay: 1.15s; }
.fade-hero.d3 { animation-delay: 1.4s; }
@keyframes fadeHero { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: translateY(0); } }

.scroll-indicator {
  width: 26px; height: 44px;
  border: 1.5px solid rgba(244,238,224,.45);
  border-radius: 20px;
  position: relative;
}
.scroll-indicator::after {
  content: ""; position: absolute; left: 50%; top: 8px;
  width: 4px; height: 9px; margin-left: -2px;
  border-radius: 4px; background: var(--gold-light);
  animation: scrollDot 1.8s ease-in-out infinite;
}
@keyframes scrollDot {
  0% { transform: translateY(0); opacity: 1; }
  70% { transform: translateY(16px); opacity: 0; }
  100% { transform: translateY(0); opacity: 0; }
}

/* Elementos flotantes */
@keyframes floatY {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-16px); }
}
.float-slow { animation: floatY 6s ease-in-out infinite; }
.float-slower { animation: floatY 9s ease-in-out infinite; }

/* ---------- Reveal on scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(46px);
  transition: opacity 0.9s cubic-bezier(.22,.61,.36,1), transform 0.9s cubic-bezier(.22,.61,.36,1);
  transition-delay: var(--d, 0s);
  will-change: opacity, transform;
}
.reveal-left { transform: translateX(-56px); }
.reveal-right { transform: translateX(56px); }
.reveal-scale { transform: scale(.88) translateY(20px); }
.reveal.visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero-bg, .float-slow, .float-slower { animation: none; }
}

/* ---------- Marquee ---------- */
.marquee-track {
  display: flex; width: max-content;
  animation: marquee 30s linear infinite;
}
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ---------- Tarjetas de destino ---------- */
.dest-card {
  position: relative; overflow: hidden; border-radius: 1.4rem;
  transform-style: preserve-3d;
  transition: transform .5s cubic-bezier(.22,.61,.36,1), box-shadow .5s ease;
  box-shadow: 0 24px 50px -22px rgba(0,0,0,.65);
}
.dest-card:hover { box-shadow: 0 34px 70px -20px rgba(217,164,65,.28); }
.dest-card img {
  transition: transform 1.1s cubic-bezier(.22,.61,.36,1), filter .6s ease;
}
.dest-card:hover img { transform: scale(1.12); filter: brightness(1.05); }
.dest-card .card-shine {
  position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(115deg, transparent 30%, rgba(255,244,214,.22) 48%, transparent 62%);
  transform: translateX(-120%);
  transition: transform 1s ease;
}
.dest-card:hover .card-shine { transform: translateX(120%); }
.dest-card .card-arrow {
  transition: transform .45s cubic-bezier(.22,.61,.36,1), background .45s ease;
}
.dest-card:hover .card-arrow { transform: translate(6px, -6px) rotate(0deg); }

/* ---------- Tarjetas de paquetes ---------- */
.pkg-card {
  background: linear-gradient(165deg, var(--surface-2) 0%, var(--surface) 60%);
  border: 1px solid rgba(217,164,65,.14);
  transition: transform .5s cubic-bezier(.22,.61,.36,1), border-color .5s ease, box-shadow .5s ease;
}
.pkg-card:hover {
  transform: translateY(-12px);
  border-color: rgba(217,164,65,.45);
  box-shadow: 0 40px 80px -30px rgba(217,164,65,.35);
}
.pkg-card .pkg-img img { transition: transform 1s cubic-bezier(.22,.61,.36,1); }
.pkg-card:hover .pkg-img img { transform: scale(1.1); }

/* ---------- Tarjetas de ofertas ---------- */
.offer-card {
  position: relative;
  background: linear-gradient(150deg, rgba(19,28,49,.9), rgba(10,16,29,.95));
  border: 1px solid rgba(217,164,65,.16);
  backdrop-filter: blur(8px);
  transition: transform .5s cubic-bezier(.22,.61,.36,1), border-color .4s ease, box-shadow .5s ease;
  overflow: hidden;
}
.offer-card::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  opacity: 0; transition: opacity .5s ease;
}
.offer-card:hover { transform: translateY(-10px); border-color: rgba(217,164,65,.5); box-shadow: 0 30px 60px -25px rgba(0,0,0,.8); }
.offer-card:hover::before { opacity: 1; }

.price-old { position: relative; color: var(--muted); }
.price-old::after {
  content: ""; position: absolute; left: -4px; right: -4px; top: 50%;
  height: 1.5px; background: #e25c5c; transform: rotate(-6deg);
}

/* ---------- Botones ---------- */
.btn-gold {
  position: relative; overflow: hidden;
  background: linear-gradient(115deg, #e7b95b, #d9a441 55%, #c78f2e);
  color: #161006;
  transition: transform .35s ease, box-shadow .35s ease;
  box-shadow: 0 14px 34px -12px rgba(217,164,65,.55);
}
.btn-gold::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(115deg, transparent 35%, rgba(255,255,255,.45) 50%, transparent 65%);
  transform: translateX(-130%);
  transition: transform .8s ease;
}
.btn-gold:hover { transform: translateY(-3px); box-shadow: 0 22px 44px -12px rgba(217,164,65,.7); }
.btn-gold:hover::after { transform: translateX(130%); }

.btn-ghost {
  border: 1px solid rgba(244,238,224,.35);
  transition: all .35s ease;
  backdrop-filter: blur(6px);
}
.btn-ghost:hover { border-color: var(--gold); color: var(--gold-light); background: rgba(217,164,65,.08); transform: translateY(-3px); }

/* ---------- Secciones decorativas ---------- */
.section-tag {
  display: inline-flex; align-items: center; gap: .6rem;
  font-size: .72rem; letter-spacing: .32em; text-transform: uppercase;
  color: var(--gold-light);
}
.section-tag::before, .section-tag.centered::after {
  content: ""; width: 34px; height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold));
}
.section-tag.centered::after { background: linear-gradient(90deg, var(--gold), transparent); }

.ornament-line {
  height: 1px; flex: 1;
  background: linear-gradient(90deg, transparent, rgba(217,164,65,.4), transparent);
}

.glass-panel {
  background: rgba(14, 21, 38, 0.62);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid rgba(217,164,65,.16);
}

/* ---------- Testimonios ---------- */
.testi-slide {
  position: absolute; inset: 0;
  opacity: 0; transform: translateX(60px) scale(.97);
  transition: opacity .7s ease, transform .7s cubic-bezier(.22,.61,.36,1);
  pointer-events: none;
}
.testi-slide.active { opacity: 1; transform: none; pointer-events: auto; }
.testi-slide.exit-left { opacity: 0; transform: translateX(-60px) scale(.97); }
.testi-dot { transition: all .4s ease; }
.testi-dot.active { width: 2.2rem; background: var(--gold); }

@keyframes pulseSoft {
  0%, 100% { box-shadow: 0 0 0 0 rgba(217,164,65,.35); }
  50% { box-shadow: 0 0 0 12px rgba(217,164,65,0); }
}
.pulse-ring { animation: pulseSoft 2.6s ease-in-out infinite; }

/* ---------- Formulario ---------- */
.input-elegant {
  background: rgba(10, 16, 29, .65);
  border: 1px solid rgba(139,147,167,.25);
  transition: border-color .35s ease, box-shadow .35s ease, background .35s ease;
  color: var(--ivory);
}
.input-elegant::placeholder { color: #5d6579; }
.input-elegant:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 4px rgba(217,164,65,.12);
  background: rgba(10, 16, 29, .9);
}
select.input-elegant option { background: var(--surface); color: var(--ivory); }

/* ---------- Toast ---------- */
#toast {
  position: fixed; bottom: 2rem; left: 50%;
  transform: translate(-50%, 140%);
  transition: transform .55s cubic-bezier(.22,.61,.36,1);
  z-index: 90;
}
#toast.show { transform: translate(-50%, 0); }

/* ---------- Volver arriba ---------- */
#back-top {
  position: fixed; right: 1.6rem; bottom: 1.6rem; z-index: 80;
  opacity: 0; visibility: hidden; transform: translateY(18px);
  transition: all .45s ease;
}
#back-top.show { opacity: 1; visibility: visible; transform: none; }
#back-top svg.ring { transform: rotate(-90deg); }
#back-top .ring-fg { transition: stroke-dashoffset .15s linear; }

/* ---------- Filtros destinos ---------- */
.filter-btn {
  border: 1px solid rgba(139,147,167,.3);
  transition: all .35s ease;
}
.filter-btn:hover { border-color: var(--gold); color: var(--gold-light); }
.filter-btn.active {
  background: linear-gradient(115deg, #e7b95b, #c78f2e);
  border-color: transparent; color: #161006;
  box-shadow: 0 10px 26px -10px rgba(217,164,65,.6);
}
.filterable { transition: opacity .45s ease, transform .45s ease; }
.filterable.hide-item { opacity: 0; transform: scale(.9); pointer-events: none; position: absolute; visibility: hidden; }

/* ---------- Footer ---------- */
.footer-link { position: relative; transition: color .3s ease, padding-left .3s ease; }
.footer-link::before {
  content: "→"; position: absolute; left: 0; opacity: 0;
  color: var(--gold); transition: opacity .3s ease;
}
.footer-link:hover { color: var(--gold-light); padding-left: 1.3rem; }
.footer-link:hover::before { opacity: 1; }

.social-icon {
  border: 1px solid rgba(139,147,167,.3);
  transition: all .35s ease;
}
.social-icon:hover {
  border-color: var(--gold); color: var(--gold-light);
  transform: translateY(-4px) rotate(6deg);
  box-shadow: 0 12px 24px -10px rgba(217,164,65,.45);
}

/* ---------- Mapa ---------- */
.map-frame { filter: grayscale(1) invert(.92) contrast(.9) hue-rotate(180deg) saturate(.4); }

/* ---------- Utilidades ---------- */
.divider-gold {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(217,164,65,.5), transparent);
}
.text-stroke {
  -webkit-text-stroke: 1px rgba(217,164,65,.35);
  color: transparent;
}
.badge-shine {
  background: linear-gradient(115deg, rgba(217,164,65,.16), rgba(217,164,65,.05));
  border: 1px solid rgba(217,164,65,.35);
}
.countdown-box {
  background: rgba(6,10,19,.75);
  border: 1px solid rgba(217,164,65,.3);
  backdrop-filter: blur(8px);
}
