/* ============================================
   PROFIT4LIFE — Landing Academia
   Paleta clara con cierre oscuro cinematográfico
   ============================================ */

:root {
  /* Fondos */
  --bg-cream:       #fdfaf2;   /* crema con tinte dorado — fondo principal */
  --bg-white:       #ffffff;   /* blanco puro, alternancia sutil */
  --bg-gray-light:  #f5f5f5;   /* gris claro para placeholders */
  --bg-night:       #1e3a5f;   /* azul noche — RESERVADO para futuras landings
                                  (p.ej. Mastermind). No se usa en Academia como
                                  fondo de sección; solo aparece como acento en
                                  el gradiente del CTA final (--bg-dark-gradient). */
  --bg-night-deep:  #14283f;   /* reservado, no usado en Academia */
  --bg-charcoal:    #242424;   /* gris oscuro premium — footer y textos */
  --bg-dark-gradient: linear-gradient(180deg, #242424 0%, #1e3a5f 100%);

  /* Dorados */
  --gold:           #ecc636;   /* dorado brillante — CTAs, acentos en oscuro */
  --gold-deep:      #c4a129;   /* dorado oscuro — textos sobre claro */
  --gold-dark:      #c9a520;   /* hover */
  --gold-darker:    #a68617;

  /* Textos */
  --text-primary:   #242424;   /* texto principal sobre claro */
  --text-secondary: #5a5a5a;   /* texto secundario sobre claro */
  --text-muted:     #8a8a8a;   /* apagado sobre claro */
  --text-on-dark:   #ffffff;
  --text-muted-on-dark: rgba(255, 255, 255, 0.75);

  /* Bordes y sombras estándar */
  --border-subtle:  rgba(36, 36, 36, 0.08);
  --shadow-soft:    0 2px 8px rgba(36, 36, 36, 0.04),
                    0 8px 24px rgba(36, 36, 36, 0.05);
  --shadow-hover:   0 4px 14px rgba(36, 36, 36, 0.06),
                    0 18px 40px rgba(36, 36, 36, 0.10);

  /* Alias legacy (por compatibilidad con clases Tailwind bg-ink/ink-soft) */
  --ink:            var(--bg-charcoal);
  --white:          #ffffff;
}

* {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--bg-cream);
  color: var(--text-primary);
}

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

/* ============================================
   Botones
   ============================================ */
.btn-gold {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: 1rem 2rem;
  background: var(--gold);
  color: var(--text-primary);
  font-weight: 700;
  font-size: .95rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  border-radius: .75rem;
  box-shadow: 0 10px 30px -8px rgba(236, 198, 54, .45),
              inset 0 1px 0 rgba(255, 255, 255, .35);
  transition: transform .25s ease, box-shadow .25s ease, background-color .25s ease;
  cursor: pointer;
  border: none;
}

.btn-gold:hover {
  background: var(--gold-dark);
  transform: translateY(-2px);
  box-shadow: 0 15px 40px -8px rgba(236, 198, 54, .55),
              inset 0 1px 0 rgba(255, 255, 255, .35);
}

.btn-gold:focus-visible {
  outline: 2px solid var(--text-primary);
  outline-offset: 3px;
}

.btn-gold:active {
  transform: translateY(0);
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  padding: 1rem 2rem;
  background: transparent;
  color: var(--text-on-dark);
  font-weight: 600;
  font-size: .95rem;
  letter-spacing: .05em;
  border-radius: .75rem;
  border: 1px solid rgba(255, 255, 255, .35);
  transition: all .25s ease;
}

.btn-ghost:hover {
  border-color: var(--gold);
  color: var(--gold);
  transform: translateY(-2px);
}

/* Variante grande para CTA final protagonista (un solo botón) */
.btn-gold--lg {
  padding: 1.25rem 2.75rem;
  font-size: 1.05rem;
  letter-spacing: .1em;
  border-radius: .9rem;
}

/* ============================================
   Sección "¿Te identificas?" — fondo blanco
   ============================================ */
.pain-section {
  background: var(--bg-white);
}

.pain-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.5rem 1.75rem;
  background: var(--bg-white);
  border: 1px solid var(--border-subtle);
  border-radius: 0.875rem;
  box-shadow: var(--shadow-soft);
  transition: border-color .3s ease, transform .3s ease, box-shadow .3s ease;
}

.pain-item:hover {
  border-color: rgba(196, 161, 41, 0.35);
  box-shadow: var(--shadow-hover);
  transform: translateY(-2px);
}

.pain-item p {
  color: var(--text-primary);
  line-height: 1.55;
  font-size: 1rem;
}

.pain-item strong {
  color: var(--text-primary);
  font-weight: 700;
}

.pain-icon {
  flex-shrink: 0;
  width: 2.25rem;
  height: 2.25rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(236, 198, 54, 0.15);
  border: 1px solid rgba(236, 198, 54, 0.3);
  border-radius: 9999px;
  color: var(--gold-deep);
}

/* ============================================
   Testimonial shots (capturas de chat, carrusel)
   - Aspect 3/4 (vertical, similar a screenshot de móvil)
   - object-fit: cover + top → prioriza cabecera del chat
   ============================================ */
.testimonial-shot {
  display: block;
  margin: 0;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  border-radius: 14px;
  background: var(--bg-gray-light);
  border: 2px solid rgba(36, 36, 36, 0.15);
  box-shadow: 0 4px 24px rgba(36, 36, 36, 0.10);
  cursor: zoom-in;
  transition: box-shadow .3s ease, border-color .3s ease;
}

.testimonial-shot img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  transition: transform .3s cubic-bezier(0.22, 1, 0.36, 1), filter .3s ease;
}

.testimonial-shot:hover {
  box-shadow: 0 10px 28px rgba(36, 36, 36, 0.12);
  border-color: rgba(196, 161, 41, 0.45);
}

.testimonial-shot:hover img {
  transform: scale(1.02);
  filter: brightness(1.05);
}

.testimonial-shot:focus-visible {
  outline: 2px solid var(--gold-deep);
  outline-offset: 4px;
}

/* ============================================
   Carrusel de resultados
   - Desktop: 3 slides visibles · Tablet: 2 · Mobile: 1
   - Flechas a los lados, dots activos en dorado
   - Swipe táctil en mobile vía JS
   ============================================ */
.results-carousel {
  position: relative;
  padding: 0 3rem;
}

.carousel-viewport {
  overflow: hidden;
  border-radius: 1rem;
}

.carousel-track {
  display: flex;
  transition: transform 500ms cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}

.carousel-slide {
  flex: 0 0 100%;
  padding: 0 0.5rem;
  box-sizing: border-box;
}

@media (min-width: 768px) {
  .carousel-slide { flex: 0 0 50%; }
}

@media (min-width: 1024px) {
  .carousel-slide { flex: 0 0 33.3333%; }
}

.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 2.75rem;
  height: 2.75rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-white);
  border: 1px solid var(--border-subtle);
  border-radius: 9999px;
  color: var(--gold-deep);
  box-shadow: var(--shadow-soft);
  cursor: pointer;
  transition: transform .25s ease, box-shadow .25s ease, color .25s ease, opacity .25s ease;
  z-index: 2;
}

.carousel-arrow:hover:not(:disabled) {
  color: var(--gold-dark);
  box-shadow: var(--shadow-hover);
  transform: translateY(-50%) scale(1.08);
}

.carousel-arrow:disabled {
  opacity: .3;
  cursor: not-allowed;
}

.carousel-arrow--prev { left: 0; }
.carousel-arrow--next { right: 0; }

.carousel-dots {
  display: flex;
  justify-content: center;
  gap: .5rem;
  margin-top: 1.5rem;
}

.carousel-dot {
  width: 8px;
  height: 8px;
  border-radius: 9999px;
  background: rgba(36, 36, 36, 0.15);
  border: none;
  padding: 0;
  cursor: pointer;
  transition: background-color .3s ease, width .3s ease;
}

.carousel-dot:hover {
  background: rgba(36, 36, 36, 0.3);
}

.carousel-dot[aria-current="true"] {
  background: var(--gold);
  width: 24px;
}

@media (max-width: 767px) {
  .results-carousel { padding: 0 2.5rem; }
  .carousel-arrow { width: 2.25rem; height: 2.25rem; }
  /* Con 15 páginas en mobile los dots se compactan */
  .carousel-dots { gap: .375rem; flex-wrap: wrap; max-width: 280px; margin-left: auto; margin-right: auto; }
  .carousel-dot { width: 6px; height: 6px; }
  .carousel-dot[aria-current="true"] { width: 20px; }
}

/* ============================================
   Testimonials — fondo blanco
   ============================================ */
.testimonial {
  padding: 1.75rem;
  background: var(--bg-white);
  border: 1px solid rgba(36, 36, 36, 0.06);
  border-radius: 16px;
  box-shadow: 0 4px 24px rgba(36, 36, 36, 0.06);
  transition: border-color .3s ease, transform .3s ease, box-shadow .3s ease;
}

.testimonial:hover {
  border-color: rgba(196, 161, 41, 0.35);
  transform: translateY(-3px);
  box-shadow: 0 10px 32px rgba(36, 36, 36, 0.10);
}

/* Avatar: ahora es un <img> circular con foto real */
.testimonial-avatar {
  width: 3.5rem;    /* 56px */
  height: 3.5rem;
  flex-shrink: 0;
  border-radius: 50%;
  object-fit: cover;
  object-position: center;
  border: 2px solid rgba(196, 161, 41, 0.3);
  background: var(--bg-gray-light); /* color de espera mientras carga */
}

.testimonial-name {
  color: var(--text-primary);
  font-weight: 700;
  font-size: 1rem;       /* 16px */
  line-height: 1.3;
}

.testimonial-label {
  color: var(--gold-deep);
  font-size: .8125rem;   /* 13px */
  font-weight: 600;
  margin-top: 0.15rem;
}

.testimonial-quote {
  color: var(--text-primary);
  font-size: .975rem;    /* ~15.6px */
  font-style: italic;
  line-height: 1.6;
}

/* ============================================
   Product cards — fondo blanco premium
   ============================================ */
.product-card {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 2rem 1.75rem;
  background: var(--bg-white);
  border: 1px solid var(--border-subtle);
  border-radius: 1.25rem;
  box-shadow: var(--shadow-soft);
  color: var(--text-primary);
  transition: border-color .3s ease, transform .3s ease, box-shadow .3s ease;
}

.product-card:hover {
  border-color: rgba(196, 161, 41, 0.45);
  transform: translateY(-6px);
  box-shadow: 0 20px 50px -15px rgba(236, 198, 54, .25),
              0 4px 12px rgba(36, 36, 36, 0.06);
}

.product-card--featured {
  border: 2px solid var(--gold);
  box-shadow: 0 16px 45px -10px rgba(236, 198, 54, .35),
              var(--shadow-soft);
}

.product-card--featured:hover {
  box-shadow: 0 25px 60px -12px rgba(236, 198, 54, .5),
              0 4px 12px rgba(36, 36, 36, 0.08);
}

.product-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--gold);
  color: var(--text-primary);
  font-size: .7rem;
  font-weight: 800;
  letter-spacing: .12em;
  padding: .4rem .85rem;
  border-radius: 9999px;
  white-space: nowrap;
  box-shadow: 0 8px 20px -4px rgba(236, 198, 54, .45);
}

.product-tag {
  display: inline-block;
  font-size: .7rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--gold-deep);
  background: rgba(236, 198, 54, 0.15);
  border: 1px solid rgba(236, 198, 54, 0.3);
  padding: .3rem .7rem;
  border-radius: 9999px;
  margin-bottom: 1rem;
  width: fit-content;
  font-weight: 600;
}

.product-tag--gold {
  color: var(--text-primary);
  background: var(--gold);
  border-color: var(--gold);
}

.product-card h3 {
  color: var(--text-primary);
}

.product-card > p {
  color: var(--text-secondary);
}

.price {
  margin: .5rem 0 1.5rem;
}

.price-amount {
  display: block;
  font-family: 'Bebas Neue', sans-serif;
  font-size: 3.25rem;
  line-height: 1;
  letter-spacing: .02em;
  color: var(--gold-deep);
}

.price-note {
  display: block;
  font-size: .8rem;
  color: var(--text-secondary);
  margin-top: .25rem;
}

.product-features {
  list-style: none;
  padding: 0;
  margin: 0 0 1.75rem 0;
  flex-grow: 1;
}

.product-features li {
  position: relative;
  padding-left: 1.75rem;
  padding-block: .55rem;
  color: var(--text-primary);
  font-size: .92rem;
  border-bottom: 1px solid var(--border-subtle);
}

.product-features li:last-child {
  border-bottom: none;
}

.product-features li strong {
  color: var(--text-primary);
  font-weight: 700;
}

.product-features li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 1.1rem;
  height: 1.1rem;
  /* check dorado profundo para buen contraste sobre blanco */
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23c4a129' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'><polyline points='20 6 9 17 4 12'/></svg>");
  background-size: contain;
  background-repeat: no-repeat;
}

/* ============================================
   FAQ accordion — fondo blanco sobre cream
   ============================================ */
.faq-item {
  background: var(--bg-white);
  border: 1px solid var(--border-subtle);
  border-radius: .85rem;
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  transition: border-color .3s ease, box-shadow .3s ease;
}

.faq-item[open] {
  border-color: rgba(196, 161, 41, 0.45);
  box-shadow: var(--shadow-hover);
}

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.15rem 1.5rem;
  cursor: pointer;
  font-weight: 600;
  color: var(--text-primary);
  list-style: none;
  user-select: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary:hover {
  color: var(--gold-deep);
}

.faq-plus {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.75rem;
  height: 1.75rem;
  flex-shrink: 0;
  font-size: 1.4rem;
  color: var(--gold-deep);
  transition: transform .3s ease;
  line-height: 1;
}

.faq-item[open] .faq-plus {
  transform: rotate(45deg);
}

.faq-answer {
  padding: 0 1.5rem 1.4rem;
  color: var(--text-secondary);
  line-height: 1.65;
  font-size: .95rem;
}

.faq-answer strong {
  color: var(--text-primary);
}

.faq-answer a {
  color: var(--gold-deep);
  transition: color .25s ease;
}

.faq-answer a:hover {
  color: var(--gold-darker);
}

/* ============================================
   Secciones oscuras — corte directo limpio
   Criterio: los cambios de color ENTRE secciones son
   transiciones duras (sin fade pseudo-elementos).
   El gradiente INTERNO del CTA final (charcoal → azul noche)
   es parte del fondo propio de la sección y se mantiene.
   ============================================ */
.authority-section {
  position: relative;
  background-color: var(--bg-charcoal);
  overflow: hidden;
}

.cta-final-section {
  position: relative;
  background: var(--bg-dark-gradient);
  overflow: hidden;
}

/* ============================================
   Retrato de Emile (sección autoridad)
   - Mobile: max-width 360px centrado, altura auto
   - Desktop (≥1024px): ocupa el ancho de su columna y 500px de alto
   - Glow dorado + drop-shadow para volumen sobre charcoal
   ============================================ */
.emile-photo {
  display: block;
  margin: 0 auto;
  max-width: 360px;
  width: 100%;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow:
    0 0 100px rgba(236, 198, 54, 0.20),
    0 30px 60px rgba(0, 0, 0, 0.4);
  transition: transform .4s cubic-bezier(0.22, 1, 0.36, 1);
  background: transparent;
}

.emile-photo img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
  object-position: center top;
}

@media (min-width: 1024px) {
  .emile-photo {
    max-width: none;
  }
  .emile-photo img {
    height: 500px;
  }
}

/* Hover solo en dispositivos con puntero fino (evita zoom involuntario en touch) */
@media (hover: hover) and (pointer: fine) {
  .emile-photo:hover {
    transform: scale(1.02);
  }
}

/* ============================================
   Reveal on scroll
   ============================================ */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .7s ease, transform .7s ease;
  will-change: opacity, transform;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  html {
    scroll-behavior: auto;
  }
}

/* ============================================
   Animaciones suaves
   ============================================ */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-14px); }
}

.animate-float {
  animation: float 6s ease-in-out infinite;
}

@keyframes bounce-slow {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(4px); }
}

.animate-bounce-slow {
  animation: bounce-slow 2s ease-in-out infinite;
}

/* ============================================
   Focus visible global
   ============================================ */
a:focus-visible,
button:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--gold-deep);
  outline-offset: 3px;
  border-radius: .4rem;
}

/* ============================================
   Lightbox (galería fullscreen de testimonios)
   ============================================ */
body.lightbox-open {
  overflow: hidden;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity .3s cubic-bezier(0.22, 1, 0.36, 1),
              visibility 0s .3s;
}

.lightbox.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition: opacity .3s cubic-bezier(0.22, 1, 0.36, 1);
}

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(36, 36, 36, 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  cursor: zoom-out;
}

.lightbox-stage {
  position: relative;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 90vw;
  max-height: 90vh;
  transform: scale(0.95);
  transition: transform .3s cubic-bezier(0.22, 1, 0.36, 1);
  z-index: 1;
}

.lightbox.is-open .lightbox-stage {
  transform: scale(1);
}

.lightbox-image {
  display: block;
  max-width: 90vw;
  max-height: 90vh;
  width: auto;
  height: auto;
  object-fit: contain;
  border-radius: 14px;
  box-shadow: 0 20px 80px rgba(0, 0, 0, 0.5);
  opacity: 0;
  transition: opacity .2s ease;
}

.lightbox-image.is-loaded {
  opacity: 1;
}

.lightbox-spinner {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 48px;
  height: 48px;
  margin: -24px 0 0 -24px;
  border: 3px solid rgba(236, 198, 54, 0.25);
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: lightbox-spin .8s linear infinite;
  opacity: 0;
  transition: opacity .2s ease;
  pointer-events: none;
}

.lightbox.is-loading .lightbox-spinner {
  opacity: 1;
}

@keyframes lightbox-spin {
  to { transform: rotate(360deg); }
}

.lightbox-close,
.lightbox-arrow {
  position: absolute;
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 9999px;
  color: #ffffff;
  cursor: pointer;
  transition: transform .2s ease, background-color .2s ease, opacity .2s ease;
  z-index: 2;
}

.lightbox-close:hover,
.lightbox-arrow:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.2);
}

.lightbox-close { top: 1.25rem; right: 1.25rem; }
.lightbox-close:hover { transform: scale(1.1); }

.lightbox-arrow:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.lightbox-arrow--prev {
  left: 1.25rem;
  top: 50%;
  transform: translateY(-50%);
}
.lightbox-arrow--next {
  right: 1.25rem;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox-arrow--prev:hover:not(:disabled) { transform: translateY(-50%) scale(1.1); }
.lightbox-arrow--next:hover:not(:disabled) { transform: translateY(-50%) scale(1.1); }

.lightbox-counter {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.875rem;
  letter-spacing: .1em;
  z-index: 2;
  font-weight: 500;
}

.lightbox-close:focus-visible,
.lightbox-arrow:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

@media (max-width: 640px) {
  .lightbox-close { top: .75rem; right: .75rem; width: 40px; height: 40px; }
  .lightbox-arrow { width: 40px; height: 40px; }
  .lightbox-arrow--prev { left: .5rem; }
  .lightbox-arrow--next { right: .5rem; }
  .lightbox-counter { bottom: 1rem; font-size: .8rem; }
  .lightbox-stage, .lightbox-image { max-width: 92vw; max-height: 82vh; }
}

/* ============================================
   Responsive tweaks
   ============================================ */
@media (max-width: 640px) {
  .price-amount { font-size: 2.75rem; }
  .btn-gold, .btn-ghost { padding: .9rem 1.5rem; font-size: .88rem; }
  .btn-gold--lg { padding: 1.05rem 2rem; font-size: .98rem; }
}
