/* ==========================================================
   pages/index.css — Página Home
   Isa Criativa | isacriativa.com.br

   Depende de: css/base.css
   ========================================================== */

/* 1. BOTÕES & SECTION TITLE
   ========================================================== */
.section-title {
  text-align: center;
  font-size: var(--fs-3xl);
  color: var(--primary-dark);
  margin-bottom: var(--space-12);
}

.cta-btn {
  display: inline-block;
  padding: var(--space-4) var(--space-10);
  border-radius: var(--radius-xl);
  text-decoration: none;
  font-weight: 700;
  font-size: var(--fs-sm);
  text-align: center;
  transition:
    transform var(--transition-fast),
    box-shadow var(--transition-fast);
}

.primary-btn {
  background-color: var(--primary-dark);
  color: var(--color-white);
  box-shadow: 0 var(--space-1) var(--space-5) var(--shadow-primary-sm);
}

.primary-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px var(--space-8) var(--shadow-primary-md);
}

.secondary-btn {
  background-color: var(--color-white);
  color: var(--primary-dark);
  box-shadow: 0 var(--space-1) var(--space-5) var(--shadow-dark-md);
}

.secondary-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px var(--space-8) var(--shadow-dark-lg);
}

/* 2. NAV DA HOME (hamburger + nav-list)
   ========================================================== */
.nav-list {
  list-style: none;
  display: flex;
  gap: var(--space-8);
}

.nav-link {
  text-decoration: none;
  color: var(--text-dark);
  font-weight: 600;
  transition: color var(--transition-speed);
  position: relative;
}

.nav-link::after {
  content: "";
  position: absolute;
  bottom: -3px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--primary-dark);
  border-radius: 2px;
  transition: width var(--transition-normal) ease;
}

.nav-link:hover {
  color: var(--primary-dark);
}
.nav-link:hover::after {
  width: 100%;
}

.hamburger {
  display: none;
  cursor: pointer;
  background: none;
  border: none;
  padding: var(--space-1);
  border-radius: var(--radius-sm);
}

.hamburger:focus-visible {
  outline: 2px solid var(--primary-dark);
  outline-offset: 2px;
}

.bar {
  display: block;
  width: var(--bar-width);
  height: var(--bar-height);
  margin: 5px auto;
  background-color: var(--primary-dark);
  transition:
    transform var(--transition-speed) ease-in-out,
    opacity var(--transition-speed) ease-in-out;
}

/* 3. HERO
   ========================================================== */
#hero {
  padding: 0;
  background: linear-gradient(
    135deg,
    var(--color-bg-hero-start) 0%,
    var(--color-bg-hero-mid) 60%,
    var(--color-bg-hero-end) 100%
  );
  overflow: hidden;
  margin-top: var(--header-height);
  min-height: calc(100vh - var(--header-height));
  display: flex;
  align-items: stretch;
  position: relative;
}

.hero-blob {
  display: none; /* Ativado via media query no desktop */
  pointer-events: none;
  position: absolute;
  z-index: var(--z-base);
}

.hero-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  width: 100%;
  max-width: 100%;
  margin: 0;
  padding: 0 0.5em;
  min-height: calc(100vh - var(--header-height));
  position: relative;
  z-index: var(--z-above);
}

.hero-text {
  display: flex;
  flex-direction: column;
  gap: var(--space-7);
  padding: var(--space-12) var(--space-10) var(--space-14);
}

.hero-text h1 {
  font-size: var(--fs-2xl);
  line-height: 1.2;
  margin-bottom: var(--space-1);
}
.hero-title-main {
  display: block;
  color: var(--text-dark);
  font-weight: 800;
}
.hero-title-accent {
  display: block;
  color: var(--primary-dark);
  font-weight: 800;
  font-size: var(--fs-xl);
}

.hero-subtitle {
  font-size: var(--fs-md);
  font-weight: 700;
  color: var(--text-dark);
  margin: 0;
  line-height: 1.6;
}

.hero-desc {
  font-size: var(--fs-xs);
  color: var(--text-light);
  margin: 0;
  line-height: 1.8;
}

.hero-tagline {
  font-size: var(--fs-xs);
  font-weight: 700;
  color: var(--primary-dark);
  margin: var(--space-1) 0 var(--space-2);
}

/* 4. PROVA SOCIAL — Ticker infinito
   ========================================================== */
#prova-social {
  background-color: var(--color-white);
  padding: var(--space-16) 0;
  overflow: hidden;
}

.prova-social-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--space-8);
}

.prova-social-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  text-align: center;
  background-color: var(--bg-gray);
  border: 1px solid var(--shadow-dark-xs);
  border-radius: var(--radius-lg);
  padding: var(--space-11) var(--space-8);
  transition: transform var(--transition-speed);
}

.prova-social-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px var(--space-8) var(--shadow-dark-sm);
}

.ps-icon {
  color: var(--primary-dark);
  opacity: 1;
  margin-bottom: var(--space-2);
  flex-shrink: 0;
}
.ps-numero {
  font-size: var(--fs-3xl);
  font-weight: 800;
  color: var(--primary-dark);
  line-height: 1.1;
}
.ps-label {
  font-size: var(--fs-md);
  color: var(--text-light);
  line-height: 1.4;
  max-width: 130px;
}

.prova-social-card.reveal:nth-child(1) {
  animation-delay: 0ms;
}
.prova-social-card.reveal:nth-child(2) {
  animation-delay: 100ms;
}
.prova-social-card.reveal:nth-child(3) {
  animation-delay: 200ms;
}
.prova-social-card.reveal:nth-child(4) {
  animation-delay: 300ms;
}
.prova-social-card.reveal:nth-child(5) {
  animation-delay: 400ms;
}
.prova-social-card.reveal:nth-child(6) {
  animation-delay: 500ms;
}

/* 5. BENEFÍCIOS
   ========================================================== */
#beneficios {
  padding: var(--space-16) 0;
  background-color: var(--color-white);
}

.benefits-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-11);
}

.benefit-card {
  text-align: center;
  padding: var(--space-11) var(--space-8);
  background-color: var(--bg-gray);
  border-radius: var(--radius-lg);
  border: 1px solid var(--shadow-dark-xs);
  transition: transform var(--transition-speed);
}

.benefit-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 10px var(--space-8) var(--shadow-dark-sm);
}

.benefit-card i {
  font-size: var(--fs-icon-sm);
  color: var(--primary-dark);
  margin-bottom: var(--space-5);
}
.benefit-card h3 {
  margin-bottom: var(--space-3);
}

/* 5. GALERIA
   ========================================================== */
#galeria {
  padding: var(--space-16) 0;
  background-color: var(--bg-gray);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(250px, 100%), 1fr));
  gap: var(--space-8);
}

.gallery-item {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
}

.gallery-btn {
  display: block;
  width: 100%;
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
}

.gallery-btn:focus-visible {
  outline: 3px solid var(--primary-dark);
  outline-offset: 3px;
}

.gallery-img {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
  transition: transform var(--transition-slow) ease;
}

.gallery-overlay {
  position: absolute;
  inset: 0;
  background: var(--color-primary-overlay);
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  transition: opacity var(--transition-speed);
}

.gallery-overlay span {
  color: var(--color-white);
  font-weight: 700;
  font-size: var(--fs-base);
  transform: translateY(var(--overlay-translate-y));
  transition: transform var(--transition-speed);
}

.gallery-item:hover img {
  transform: scale(1.1);
}
.gallery-item:hover .gallery-overlay {
  opacity: 1;
}
.gallery-item:hover .gallery-overlay span {
  transform: translateY(0);
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  z-index: var(--z-modal);
  inset: 0;
  background-color: var(--shadow-dark-overlay);
  justify-content: center;
  align-items: center;
  padding: var(--space-14) var(--space-6) var(--space-6);
}

.modal.is-open {
  display: flex;
}

.modal-content {
  display: block;
  width: 100%;
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
  border-radius: var(--radius-md);
  animation: zoom var(--transition-normal);
}

.close-modal {
  position: absolute;
  top: var(--space-11);
  right: var(--space-12);
  color: var(--color-off-white);
  font-size: var(--fs-close);
  font-weight: 700;
  cursor: pointer;
  background: none;
  border: none;
  line-height: 1;
  padding: var(--space-1) var(--space-2);
  border-radius: var(--radius-sm);
}

.close-modal:hover {
  color: var(--color-white);
}
.close-modal:focus-visible {
  outline: 2px solid var(--color-white);
  outline-offset: 2px;
}

/* Galeria Swiper (mobile) */
.gallery-swiper-wrapper {
  overflow: hidden;
}

.gallery-swiper {
  display: none;
  padding-bottom: var(--space-12) !important;
  overflow: hidden;
}

.gallery-swiper .swiper-slide {
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.gallery-swiper .swiper-slide-active {
  z-index: var(--z-raised);
}

.gallery-swiper .gallery-btn {
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: block;
  width: 100%;
}

.gallery-swiper .gallery-img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
  border-radius: var(--radius-lg);
}

.gallery-swiper-pagination {
  display: none;
  text-align: center;
  padding: var(--space-2) 0 0;
}

.gallery-swiper-pagination .swiper-pagination-bullet {
  display: inline-block;
  width: var(--bullet-size);
  height: var(--bullet-size);
  margin: 0 var(--space-1);
  background: var(--primary-dark);
  opacity: 0.35;
  border-radius: var(--radius-full);
  transition:
    opacity var(--transition-speed),
    transform var(--transition-speed);
}

.gallery-swiper-pagination .swiper-pagination-bullet-active {
  opacity: 1;
  transform: scale(1.3);
}

.swiper-hint {
  display: none;
  text-align: center;
  font-size: var(--fs-sm);
  color: var(--primary-dark);
  opacity: 0.6;
  margin-top: 6px;
  letter-spacing: 0.03em;
}

/* 6. COMO FUNCIONA
   ========================================================== */
#como-funciona {
  padding: var(--space-16) 0;
  background-color: var(--color-white);
}

.steps-container {
  display: flex;
  flex-direction: column;
  gap: var(--space-11);
  align-items: center;
  list-style: none;
  padding: 0;
}

.step {
  text-align: center;
  max-width: 300px;
}

.step-number {
  width: var(--step-icon-size);
  height: var(--step-icon-size);
  background-color: var(--accent-color);
  color: var(--color-white);
  font-size: var(--fs-lg);
  font-weight: 700;
  display: flex;
  justify-content: center;
  align-items: center;
  border-radius: var(--radius-full);
  margin: 0 auto var(--space-5);
}

/* 7. INSTAGRAM CTA
   ========================================================== */
#instagram-cta {
  padding: var(--space-16) 0;
  background: var(--gradient-brand);
  text-align: center;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.instagram-cta-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-8);
}

.instagram-cta-icon {
  font-size: var(--fs-icon-lg);
  color: var(--color-white);
  -webkit-text-fill-color: var(--color-white);
  line-height: 1;
}

#instagram-cta h2 {
  font-size: var(--fs-2xl);
  color: var(--color-white);
  margin: 0;
}

#instagram-cta p {
  font-size: var(--fs-sm);
  color: var(--color-white-85);
  max-width: 560px;
  line-height: 1.7;
  margin: 0;
}

.instagram-btn {
  background: var(--color-white);
  color: var(--color-instagram-pink);
  box-shadow: 0 var(--space-1) var(--space-8) var(--shadow-dark-xl);
  font-size: var(--fs-xs);
  display: inline-flex;
  align-items: center;
  gap: var(--space-3);
  margin-top: var(--space-2);
  font-weight: 700;
}

.instagram-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 var(--space-2) var(--space-10) var(--shadow-dark-2xl);
  background: var(--color-instagram-btn-hover);
}

/* 8. DEPOIMENTOS
   ========================================================== */
#depoimentos {
  padding: var(--space-16) 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--gradient-brand);
  color: var(--color-white);
}

#depoimentos .section-title {
  color: var(--color-white);
}

.carousel-container {
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
}

.testimonial {
  display: none;
  animation: fade var(--transition-xslow);
}
.testimonial.active {
  display: block;
}

.testimonial p {
  font-size: var(--fs-base);
  font-style: italic;
  margin-bottom: var(--space-8);
  color: var(--color-white);
}

.testimonial h4,
.testimonial-author {
  color: var(--color-white);
  font-weight: 700;
}

.carousel-dots {
  margin-top: var(--space-8);
}

.dot {
  display: inline-block;
  width: var(--dot-size);
  height: var(--dot-size);
  margin: 0 5px;
  padding: 0;
  background-color: var(--color-white-50);
  border: none;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: background-color var(--transition-speed);
}

.dot.active,
.dot:hover {
  background-color: var(--color-white);
}
.dot:focus-visible {
  outline: 2px solid var(--color-white);
  outline-offset: 3px;
}

/* 9. CTA FINAL
   ========================================================== */
#cta-final {
  padding: var(--space-17) 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background: var(--color-white);
}

.cta-final-content h2 {
  font-size: var(--fs-2xl);
  color: var(--primary-dark);
  margin-bottom: var(--space-5);
}
.cta-final-content p {
  color: var(--text-light);
  margin-bottom: var(--space-11);
  font-size: var(--fs-base);
}

/* 11. ANIMAÇÕES
   ========================================================== */
@keyframes morphHero {
  0% {
    border-radius: 62% 38% 46% 54% / 60% 44% 56% 40%;
  }
  33% {
    border-radius: 44% 56% 58% 42% / 48% 62% 38% 52%;
  }
  66% {
    border-radius: 55% 45% 38% 62% / 52% 36% 64% 48%;
  }
  100% {
    border-radius: 48% 52% 62% 38% / 56% 50% 50% 44%;
  }
}

@keyframes morphHeroTop {
  0% {
    border-radius: 0 0 62% 38% / 0 0 60% 80%;
  }
  33% {
    border-radius: 0 0 44% 56% / 0 0 78% 62%;
  }
  66% {
    border-radius: 0 0 55% 45% / 0 0 64% 76%;
  }
  100% {
    border-radius: 0 0 48% 52% / 0 0 72% 68%;
  }
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-12px);
  }
}

@keyframes zoom {
  from {
    transform: scale(0);
  }
  to {
    transform: scale(1);
  }
}

@keyframes fade {
  from {
    opacity: 0.4;
  }
  to {
    opacity: 1;
  }
}

/* 12. RESPONSIVO
   ========================================================== */

/* Tablet e acima (≥ 768px) */
@media (min-width: 768px) {
  .benefits-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .steps-container {
    flex-direction: row;
    justify-content: space-around;
    align-items: flex-start;
  }

  .gallery-swiper {
    display: none !important;
  }
  .gallery-grid {
    display: grid;
  }
}

/* Tablet (768px – 1023px) */
@media (min-width: 768px) and (max-width: 1023px) {
  .hero-text {
    padding: var(--space-14) var(--space-12) var(--space-15);
  }
  .hero-text h1 {
    font-size: 2.6rem;
  }
  .hero-text p {
    font-size: var(--fs-md);
  }
  .section-title {
    font-size: var(--fs-2xl);
  }

  #galeria,
  #como-funciona,
  #depoimentos,
  #instagram-cta,
  #cta-final {
    padding: var(--space-15) var(--space-12);
  }

  #instagram-cta p,
  .cta-final-content p {
    font-size: var(--fs-md);
  }

  #instagram-cta h2,
  .cta-final-content h2 {
    font-size: var(--fs-2xl);
  }

  .depoimento-texto {
    font-size: var(--fs-sm);
  }
}

/* Desktop (≥ 1024px) */
@media (min-width: 1024px) {
  #hero {
    min-height: calc(100vh - var(--header-height));
    display: flex;
    align-items: stretch;
  }

  .hero-blob {
    display: block;
    position: absolute;
    top: -30%;
    left: -5%;
    width: 110%;
    height: 75%;
    background: linear-gradient(
      145deg,
      var(--primary-deeper) 0%,
      var(--primary-dark) 40%,
      var(--primary-vivid) 75%,
      var(--primary-color) 100%
    );
    border-radius: 0 0 50% 50% / 0 0 80% 80%;
    opacity: var(--blob-opacity-outer);
    animation: morphHeroTop 12s ease-in-out infinite alternate;
    z-index: var(--z-base);
  }

  .hero-blob::after {
    content: "";
    position: absolute;
    top: 8%;
    left: 3%;
    width: 94%;
    height: 85%;
    background: linear-gradient(
      135deg,
      var(--primary-dark) 0%,
      var(--primary-deep-alt) 60%,
      var(--primary-color) 100%
    );
    border-radius: 0 0 52% 48% / 0 0 75% 75%;
    opacity: var(--blob-opacity-inner);
    animation: morphHeroTop 9s ease-in-out infinite alternate-reverse;
  }

  .hero-container {
    text-align: center;
    align-items: center;
    justify-content: center;
    padding: 0 var(--space-9);
    min-height: calc(100vh - var(--header-height));
  }

  .hero-text {
    max-width: 640px;
    justify-content: center;
    align-items: center;
    padding: var(--space-14) 0;
    gap: var(--space-6);
    position: relative;
    z-index: var(--z-above);
  }

  .hero-text h1 {
    font-size: 3.2rem;
  }

  .benefits-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* Mobile (< 1024px) */
@media (max-width: 1023px) {
  .hero-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - var(--header-height));
  }

  .hero-text {
    width: 100%;
    text-align: center;
    align-items: center;
    padding: var(--space-12) var(--space-9) var(--space-13);
  }

  .hero-text h1 {
    font-size: var(--fs-2xl);
  }
}

/* Mobile (< 768px) */
@media (max-width: 767px) {
  .hamburger {
    display: block;
  }

  .hamburger.active .bar:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }
  .hamburger.active .bar:nth-child(2) {
    opacity: 0;
  }
  .hamburger.active .bar:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }

  .nav-list {
    position: fixed;
    left: -100%;
    top: var(--header-height);
    flex-direction: column;
    background-color: var(--color-white);
    width: 100%;
    text-align: center;
    transition: left var(--transition-speed);
    box-shadow: 0 var(--space-3) var(--space-3) var(--shadow-dark-md);
    padding: var(--space-8) 0;
  }

  .nav-list.active {
    left: 0;
  }
  .nav-item {
    margin: var(--space-5) 0;
  }

  .gallery-swiper {
    display: block;
  }
  .gallery-swiper-pagination {
    display: block;
  }
  .gallery-grid {
    display: none;
  }
  .swiper-hint {
    display: block;
  }

  #galeria {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
  }

  .ps-icon {
    width: 36px;
    height: 36px;
  }
  .ps-numero {
    font-size: var(--fs-2xl);
  }
  .ps-label {
    font-size: var(--fs-md);
  }
}

/* 13. ACESSIBILIDADE
   ========================================================== */
@media (prefers-reduced-motion: reduce) {
  .hero-blob,
  .hero-blob::after {
    animation: none;
  }

  .modal-content,
  .testimonial {
    animation: none;
  }
}
