/* ============================================================
   OPERACAO CONCURSOS — Animations v5.0
   Tactical identity — HUD elements, scan lines, grid motion
   ============================================================ */

/* ─────────────────────────────────────
   SCROLL REVEAL — Hidden states
   ───────────────────────────────────── */

[data-animate] {
  opacity: 0;
  will-change: opacity, transform;
}

[data-animate="fade-up"] {
  transform: translateY(40px);
  transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1),
              transform 1s cubic-bezier(0.16, 1, 0.3, 1);
  transition-delay: calc(var(--stagger, 0) * 0.15s);
}

[data-animate="fade-in"] {
  transform: none;
  transition: opacity 0.9s ease;
}

/* ─────────────────────────────────────
   ANIMATED STATE — Visible
   ───────────────────────────────────── */

[data-animate].animate-in {
  opacity: 1;
  transform: translateY(0);
}

/* ─────────────────────────────────────
   BUTTON — Hover glow (clean)
   ───────────────────────────────────── */

.btn--primary {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn--primary:hover {
  box-shadow: 0 4px 24px rgba(255, 215, 0, 0.3);
}

.btn--whatsapp:hover {
  box-shadow: 0 4px 24px rgba(37, 211, 102, 0.3);
}

/* ─────────────────────────────────────
   SECTION HEADER — Gold line reveal
   ───────────────────────────────────── */

.section__header::after {
  width: 0;
  transition: width 0.9s cubic-bezier(0.16, 1, 0.3, 1) 0.4s;
}

.section__header.animate-in::after {
  width: 60px;
}

/* ─────────────────────────────────────
   EYEBROW — Clip-reveal left to right (briefing style)
   ───────────────────────────────────── */

.section__eyebrow {
  display: inline-block;
  clip-path: inset(0 100% 0 0);
  transition: clip-path 1.4s cubic-bezier(0.25, 1, 0.5, 1) 0.3s;
}

.section__header.animate-in .section__eyebrow {
  clip-path: inset(0 0% 0 0);
}

/* ─────────────────────────────────────
   SECTION TITLE — Subtle fade-up within header
   ───────────────────────────────────── */

.section__header .section__title {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.8s ease 0.5s, transform 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.5s;
}

.section__header.animate-in .section__title {
  opacity: 1;
  transform: translateY(0);
}

.section__header .section__subtitle {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.8s ease 0.7s, transform 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.7s;
}

.section__header.animate-in .section__subtitle {
  opacity: 1;
  transform: translateY(0);
}

/* ─────────────────────────────────────
   FAQ ITEMS — Sequential reveal on scroll
   ───────────────────────────────────── */

.faq__item {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
  transition-delay: calc(var(--faq-index, 0) * 0.12s);
}

.faq__item.animate-in {
  opacity: 1;
  transform: translateY(0);
}

/* ─────────────────────────────────────
   CARD HOVERS — Subtle lift
   ───────────────────────────────────── */

.testimonial {
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.testimonial:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
  border-color: var(--color-border-strong);
}

/* ─────────────────────────────────────
   CURSO CARD — Clean styles
   ───────────────────────────────────── */

/* ─── GLASSMORPHISM — Dark Glass Cards ─── */

.curso-card {
  display: flex;
  flex-direction: column;
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow 0.4s ease,
              border-color 0.4s ease;
  position: relative;
  z-index: 2;
  text-decoration: none;
  color: var(--color-white);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    inset 0 -1px 0 rgba(0, 0, 0, 0.3);
}

.curso-card::before {
  content: '';
  position: absolute;
  inset: 0;
  filter: url(#glass-noise);
  opacity: 0.03;
  pointer-events: none;
  z-index: 3;
  border-radius: inherit;
}

.curso-card:hover {
  transform: translateY(-6px);
  border-color: rgba(255, 255, 255, 0.15);
  box-shadow:
    0 20px 50px rgba(0, 0, 0, 0.7),
    0 0 40px rgba(255, 215, 0, 0.04),
    inset 0 1px 0 rgba(255, 255, 255, 0.1),
    inset 0 -1px 0 rgba(0, 0, 0, 0.3);
}

.curso-card__image-wrap {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16 / 9;
}

.curso-card__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.curso-card:hover .curso-card__image {
  transform: scale(1.05);
}

.curso-card__body {
  padding: var(--space-6) var(--space-6) var(--space-8);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.curso-card__title {
  font-family: var(--font-heading);
  font-size: var(--text-h4);
  font-weight: var(--weight-bold);
  text-transform: uppercase;
  letter-spacing: var(--tracking-wide);
}

.curso-card__text {
  font-size: var(--text-sm);
  color: var(--color-text-secondary);
  line-height: var(--leading-relaxed);
}

/* ─────────────────────────────────────
   PRICE BOX — Minimal
   ───────────────────────────────────── */

.price-box {
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-color: rgba(255, 255, 255, 0.1);
  transition: box-shadow 0.3s ease, border-color 0.3s ease;
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.price-box:hover {
  box-shadow:
    0 16px 48px rgba(0, 0, 0, 0.6),
    inset 0 1px 0 rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.15);
}

.testimonial {
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow:
    0 8px 32px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

/* ─────────────────────────────────────
   WHATSAPP FLOAT — Clean
   ───────────────────────────────────── */

.whatsapp-float:hover {
  transform: scale(1.08);
}

/* ─────────────────────────────────────
   NAV LINK — Underline slide
   ───────────────────────────────────── */

.nav__link::after {
  transition: width 0.3s ease;
}

/* ─────────────────────────────────────
   DIFF ITEM — Hover
   ───────────────────────────────────── */

.diff-item {
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.diff-item:hover {
  border-color: var(--color-border-strong);
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.4);
}


/* ═════════════════════════════════════
   TACTICAL EFFECTS — HUD Identity
   ═════════════════════════════════════ */

/* ─────────────────────────────────────
   HUD CORNERS — Targeting brackets on sections
   ───────────────────────────────────── */

.section__header--hud {
  position: relative;
  padding: var(--space-6);
}

/* All 4 HUD corners via spans (avoids ::before/::after conflict with gold line) */
.hud-corner--tl,
.hud-corner--tr,
.hud-corner--bl,
.hud-corner--br {
  position: absolute;
  width: 20px;
  height: 20px;
  opacity: 0;
  transition: opacity 0.8s ease 0.6s;
  pointer-events: none;
}

.hud-corner--tl {
  top: 0;
  left: 0;
  border-top: 2px solid var(--color-gold);
  border-left: 2px solid var(--color-gold);
}

.hud-corner--tr {
  top: 0;
  right: 0;
  border-top: 2px solid var(--color-gold);
  border-right: 2px solid var(--color-gold);
}

.hud-corner--bl {
  bottom: 0;
  left: 0;
  border-bottom: 2px solid var(--color-gold);
  border-left: 2px solid var(--color-gold);
}

.hud-corner--br {
  bottom: 0;
  right: 0;
  border-bottom: 2px solid var(--color-gold);
  border-right: 2px solid var(--color-gold);
}

.section__header--hud.animate-in .hud-corner--tl,
.section__header--hud.animate-in .hud-corner--tr,
.section__header--hud.animate-in .hud-corner--bl,
.section__header--hud.animate-in .hud-corner--br {
  opacity: 0.5;
}


/* ─────────────────────────────────────
   TACTICAL SECTION — Base + Ambient light for glass
   ───────────────────────────────────── */

.section--tactical {
  position: relative;
  overflow: hidden;
}

.section--tactical::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 500px 300px at 15% 30%, rgba(255, 215, 0, 0.05) 0%, transparent 70%),
    radial-gradient(ellipse 400px 250px at 80% 65%, rgba(255, 215, 0, 0.04) 0%, transparent 70%);
  animation: glarePulse 6s ease-in-out infinite;
  pointer-events: none;
  z-index: 1;
}

.section--alt.section--tactical::before {
  background:
    radial-gradient(ellipse 450px 280px at 75% 25%, rgba(255, 215, 0, 0.045) 0%, transparent 70%),
    radial-gradient(ellipse 400px 250px at 25% 70%, rgba(255, 215, 0, 0.035) 0%, transparent 70%);
  animation-delay: -3s;
}

@keyframes glarePulse {
  0%, 100% { opacity: 0.4; }
  50% { opacity: 1; }
}

.section--tactical > .container {
  position: relative;
  z-index: 2;
}

/* ─────────────────────────────────────
   SCAN LINE — Horizontal gold sweep
   ───────────────────────────────────── */

@keyframes scanLine {
  0%   { top: -2px; opacity: 0; }
  5%   { opacity: 1; }
  95%  { opacity: 1; }
  100% { top: 100%; opacity: 0; }
}

.section--tactical::after {
  content: '';
  position: absolute;
  left: 0;
  top: -2px;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg,
    transparent 0%,
    rgba(255, 215, 0, 0.05) 10%,
    rgba(255, 215, 0, 0.3) 50%,
    rgba(255, 215, 0, 0.05) 90%,
    transparent 100%
  );
  box-shadow: 0 0 20px rgba(255, 215, 0, 0.15),
              0 0 60px rgba(255, 215, 0, 0.05);
  animation: scanLine 10s linear infinite;
  pointer-events: none;
  z-index: 0;
}

/* ─────────────────────────────────────
   REDUCED MOTION — Disable tactical effects
   ───────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  .section--tactical::after {
    animation: none;
  }
}
