/* =========================================
   TARKEA — Custom Styles
   Tailwind handles layout/spacing/color utilities.
   This file covers: animations, patterns, custom
   components that Tailwind can't express inline.
   ========================================= */

/* --- CSS Custom Properties --------------- */
:root {
  --ease-out-expo:  cubic-bezier(0.16, 1, 0.3, 1);
  --ease-out-quart: cubic-bezier(0.25, 1, 0.5, 1);
}

/* --- Base -------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }

/* --- Hero grid background pattern -------- */
.hero-grid {
  background-image:
    linear-gradient(rgba(108,149,170,.12) 1px, transparent 1px),
    linear-gradient(90deg, rgba(108,149,170,.12) 1px, transparent 1px);
  background-size: 64px 64px;
}

/* Diagonal slice between sections */
.clip-diagonal {
  clip-path: polygon(0 0, 100% 0, 100% 90%, 0 100%);
}
.clip-diagonal-bottom {
  clip-path: polygon(0 5%, 100% 0, 100% 100%, 0 100%);
}

/* --- Navbar ------------------------------ */
#navbar {
  background: transparent;
  transition: background 0.4s ease, box-shadow 0.4s ease;
}
#navbar.scrolled {
  background: rgba(5, 36, 56, 0.97);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 2px 24px rgba(0,0,0,.25);
}
#navbar.solid {
  background: #052438;
  box-shadow: 0 2px 24px rgba(0,0,0,.2);
}

/* Nav link underline hover */
.nav-link {
  position: relative;
  padding-bottom: 2px;
}
.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0;
  width: 0; height: 1.5px;
  background: #d4d469;
  transition: width .4s var(--ease-out-expo);
}
.nav-link:hover::after { width: 100%; }

/* Mobile menu slide */
#mobileMenu {
  max-height: 0;
  overflow: hidden;
  transition: max-height .4s ease;
}
#mobileMenu.open { max-height: 400px; }

/* --- Scroll Reveal ------------------------ */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  filter: blur(5px);
  transition: opacity .7s var(--ease-out-quart), transform .7s var(--ease-out-quart), filter .7s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}
.reveal-left {
  opacity: 0;
  transform: translateX(-28px);
  filter: blur(4px);
  transition: opacity .7s var(--ease-out-quart), transform .7s var(--ease-out-quart), filter .7s ease;
}
.reveal-left.visible { opacity: 1; transform: translateX(0); filter: blur(0); }
.reveal-right {
  opacity: 0;
  transform: translateX(28px);
  filter: blur(4px);
  transition: opacity .7s var(--ease-out-quart), transform .7s var(--ease-out-quart), filter .7s ease;
}
.reveal-right.visible { opacity: 1; transform: translateX(0); filter: blur(0); }

/* Stagger delays (set via inline style or these classes) */
.delay-1 { transition-delay: .1s; }
.delay-2 { transition-delay: .2s; }
.delay-3 { transition-delay: .3s; }
.delay-4 { transition-delay: .4s; }
.delay-5 { transition-delay: .5s; }

/* --- Scroll arrow bounce ------------------ */
.scroll-arrow { animation: bounce-down 2.4s ease-in-out infinite; }
@keyframes bounce-down {
  0%, 100% { transform: translateY(0); opacity: .6; }
  50%       { transform: translateY(10px); opacity: 1; }
}

/* --- Hero pulse badge -------------------- */
.pulse-dot {
  position: relative;
  display: inline-block;
}
.pulse-dot::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: #d4d469;
  animation: pulse-ring 2s ease-out infinite;
}
@keyframes pulse-ring {
  0%   { transform: scale(1); opacity: .8; }
  100% { transform: scale(2.8); opacity: 0; }
}

/* --- Hero entrance ------------------------ */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(40px); filter: blur(6px); }
  to   { opacity: 1; transform: translateY(0);    filter: blur(0);   }
}

/* --- Marquee ------------------------------ */
@keyframes marqueeScroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

/* --- Shimmer sweep ------------------------ */
@keyframes shimmerSweep {
  from { transform: translateX(-200%) skewX(-15deg); }
  to   { transform: translateX(280%)  skewX(-15deg); }
}

/* --- Timeline (Método Tarkea) ------------ */
.timeline-track {
  position: relative;
}
.timeline-track::before {
  content: '';
  position: absolute;
  top: 40px; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg,
    transparent 0%,
    #12566d 10%,
    #6c95aa 50%,
    #12566d 90%,
    transparent 100%);
}
@media (max-width: 767px) {
  .timeline-track::before { display: none; }
}

.timeline-step {
  position: relative;
  z-index: 1;
}
.timeline-number {
  width: 80px; height: 80px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  background: #052438;
  border: 2px solid #12566d;
  font-family: 'Poppins', sans-serif;
  font-weight: 700;
  font-size: 1.5rem;
  color: #d4d469;
  transition: background .3s ease, border-color .3s ease, transform .3s ease;
}
.timeline-step:hover .timeline-number {
  background: #12566d;
  border-color: #d4d469;
  transform: scale(1.08);
}

/* --- Service Cards ----------------------- */
.service-card {
  transition: transform .45s var(--ease-out-expo), box-shadow .45s ease, border-color .35s ease;
  border: 1px solid rgba(108,149,170,.15);
}
.service-card:hover {
  transform: translateY(-8px);
  box-shadow:
    0 2px 4px rgba(0,0,0,0.04),
    0 8px 16px -4px rgba(0,0,0,0.10),
    0 24px 48px -12px rgba(5,36,56,0.22),
    0 0 0 1px rgba(212,212,105,.2);
  border-color: rgba(212,212,105,.4);
}

/* Audience cards (large) */
.audience-card {
  position: relative;
  overflow: hidden;
  transition: transform .4s ease, box-shadow .4s ease;
}
.audience-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(18,86,109,.4) 0%, rgba(5,36,56,.9) 100%);
  transition: opacity .4s ease;
}
.audience-card:hover { transform: translateY(-6px); box-shadow: 0 32px 64px rgba(0,0,0,.4); }
.audience-card:hover::before { opacity: .7; }

/* Subtle lime line on audience card hover */
.audience-card::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0;
  width: 0; height: 3px;
  background: #d4d469;
  transition: width .4s ease;
}
.audience-card:hover::after { width: 100%; }

/* --- Fear section items ------------------ */
.fear-item {
  border-left: 3px solid transparent;
  padding-left: 1.25rem;
  transition: border-color .3s ease, background .3s ease;
}
.fear-item:hover {
  border-color: #d4d469;
  background: rgba(212,212,105,.04);
}

/* --- CTA Button Effects ------------------ */
.btn-lime {
  position: relative;
  overflow: hidden;
  transition: transform .3s var(--ease-out-expo), box-shadow .3s ease;
}
.btn-lime::after {
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  left: 0;
  width: 50%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,.28), transparent);
  transform: translateX(-200%) skewX(-15deg);
  pointer-events: none;
}
.btn-lime:hover { transform: translateY(-3px); box-shadow: 0 14px 36px rgba(212,212,105,.35); }
.btn-lime:hover::after { animation: shimmerSweep .55s ease-out forwards; }

.btn-outline {
  transition: background .25s ease, color .25s ease, transform .25s ease;
}
.btn-outline:hover {
  background: rgba(255,255,255,.1);
  transform: translateY(-2px);
}

/* --- FAQ Accordion ----------------------- */
.faq-item { border-bottom: 1px solid rgba(108,149,170,.15); }
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height .45s ease, padding .3s ease;
}
.faq-answer.open { max-height: 400px; padding-bottom: 1.25rem; }

.faq-icon {
  flex-shrink: 0;
  width: 28px; height: 28px;
  border-radius: 50%;
  border: 1.5px solid rgba(108,149,170,.4);
  display: flex; align-items: center; justify-content: center;
  transition: background .3s ease, border-color .3s ease, transform .3s ease;
}
.faq-item.open .faq-icon {
  background: #d4d469;
  border-color: #d4d469;
  transform: rotate(45deg);
}

/* --- Form inputs ------------------------- */
.form-input {
  background: rgba(255,255,255,.06);
  border: 1.5px solid rgba(108,149,170,.25);
  border-radius: 10px;
  color: #fff;
  transition: border-color .3s ease, background .3s ease;
  width: 100%;
  padding: .875rem 1.125rem;
  font-family: 'Lato', sans-serif;
  font-size: .9375rem;
}
.form-input::placeholder { color: rgba(255,255,255,.35); }
.form-input:focus {
  outline: none;
  border-color: #d4d469;
  background: rgba(255,255,255,.1);
}

/* --- Stats bar counters ------------------ */
.stat-number {
  font-family: 'Poppins', sans-serif;
  font-weight: 800;
  font-size: clamp(2.5rem, 5vw, 4rem);
  line-height: 1;
  color: #d4d469;
}

/* --- WhatsApp floating button ------------ */
.whatsapp-float {
  position: fixed;
  bottom: 28px; right: 28px;
  z-index: 100;
  width: 60px; height: 60px;
  border-radius: 50%;
  background: #25D366;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 24px rgba(37,211,102,.45);
  transition: transform .3s ease, box-shadow .3s ease;
}
.whatsapp-float:hover {
  transform: scale(1.1) translateY(-3px);
  box-shadow: 0 14px 32px rgba(37,211,102,.55);
}

/* --- Footer ------------------------------ */
.footer-link {
  color: rgba(255,255,255,.55);
  transition: color .25s ease;
}
.footer-link:hover { color: #d4d469; }

/* --- Page hero (subpages) ---------------- */
.page-hero {
  background: linear-gradient(135deg, #052438 0%, #12566d 60%, #052438 100%);
  position: relative;
  overflow: hidden;
}
.page-hero::before {
  content: '';
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(108,149,170,.1) 1px, transparent 1px),
    linear-gradient(90deg, rgba(108,149,170,.1) 1px, transparent 1px);
  background-size: 48px 48px;
}

/* --- Marquee ticker ---------------------- */
.marquee-wrapper {
  overflow: hidden;
  position: relative;
}
.marquee-wrapper::before,
.marquee-wrapper::after {
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  width: 64px;
  z-index: 2;
  pointer-events: none;
}
.marquee-wrapper::before { left: 0;  background: linear-gradient(to right, #12566d, transparent); }
.marquee-wrapper::after  { right: 0; background: linear-gradient(to left,  #12566d, transparent); }

.marquee-track {
  display: flex;
  align-items: center;
  width: max-content;
  animation: marqueeScroll 32s linear infinite;
}
.marquee-wrapper:hover .marquee-track { animation-play-state: paused; }

/* --- Glass utility ----------------------- */
.glass-card {
  background: rgba(255,255,255,0.06);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255,255,255,0.12);
}

/* --- Section divider --------------------- */
.section-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, rgba(108,149,170,.35) 50%, transparent 100%);
  margin: 0 auto;
  max-width: 600px;
}

/* --- Audience card transition ------------ */
.audience-card {
  transition: transform .4s var(--ease-out-expo), box-shadow .4s ease;
}

/* --- Scrollbar (optional cosmetic) ------- */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: #052438; }
::-webkit-scrollbar-thumb { background: #12566d; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #6c95aa; }
