/* Custom animations – entrance, scroll, hover, micro-interactions */
:root {
  --ease-out-expo: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-in-out: cubic-bezier(0.4, 0, 0.2, 1);
  --color-primary: #FFCD20;
  --color-primary-dark: #1a1a2e;
  --color-primary-hover: #f7c105;
}

/* ----- Yellow/gold palette: #FFCD20, #f7c105, #FCED0A ----- */
.text-\[\#FFCD20\] { color: #FFCD20 !important; }
.text-\[\#f7c105\] { color: #f7c105 !important; }
.text-\[\#FCED0A\] { color: #FCED0A !important; }
.text-\[\#1a1a2e\] { color: #1a1a2e !important; }
.bg-\[\#FFCD20\] { background-color: #FFCD20 !important; }
.bg-\[\#FFCD20\]\/5 { background-color: rgba(255, 205, 32, 0.05) !important; }
.bg-\[\#FFCD20\]\/10 { background-color: rgba(255, 205, 32, 0.1) !important; }
.bg-\[\#FFCD20\]\/15 { background-color: rgba(255, 205, 32, 0.15) !important; }
.bg-\[\#FFCD20\]\/20 { background-color: rgba(255, 205, 32, 0.2) !important; }
.bg-\[\#FFCD20\]\/30 { background-color: rgba(255, 205, 32, 0.3) !important; }
.bg-\[\#f7c105\] { background-color: #f7c105 !important; }
.bg-\[\#FCED0A\] { background-color: #FCED0A !important; }
.bg-\[\#1a1a2e\] { background-color: #1a1a2e !important; }
.bg-\[\#1a1a2e\]\/5 { background-color: rgba(26, 26, 46, 0.05) !important; }
.bg-\[\#1a1a2e\]\/10 { background-color: rgba(26, 26, 46, 0.1) !important; }
.bg-\[\#1a1a2e\]\/95 { background-color: rgba(26, 26, 46, 0.95) !important; }
.border-\[\#FFCD20\]\/20 { border-color: rgba(255, 205, 32, 0.2) !important; }
.border-\[\#FFCD20\]\/30 { border-color: rgba(255, 205, 32, 0.3) !important; }
.border-\[\#FFCD20\]\/50 { border-color: rgba(255, 205, 32, 0.5) !important; }
.border-\[\#FFCD20\]\/60 { border-color: rgba(255, 205, 32, 0.6) !important; }
.border-\[\#1a1a2e\] { border-color: #1a1a2e !important; }
.border-l-\[\#FFCD20\] { border-left-color: #FFCD20 !important; }
.border-t-4.border-\[\#1a1a2e\] { border-top-color: #1a1a2e !important; }
.focus\:ring-\[\#FFCD20\]:focus { --tw-ring-opacity: 0.5; --tw-ring-color: rgb(255 205 32 / var(--tw-ring-opacity)); box-shadow: 0 0 0 calc(2px + 0px) rgb(255 205 32 / 0.5); }
.focus\:ring-\[\#1a1a2e\]:focus { --tw-ring-opacity: 0.5; --tw-ring-color: rgb(26 26 46 / var(--tw-ring-opacity)); box-shadow: 0 0 0 calc(2px + 0px) rgb(26 26 46 / 0.5); }
.hover\:bg-\[\#f7c105\]:hover { background-color: #f7c105 !important; }
.hover\:bg-\[\#FFCD20\]:hover { background-color: #FFCD20 !important; }
.hover\:border-\[\#FFCD20\]\/20:hover { border-color: rgba(255, 205, 32, 0.2) !important; }
.hover\:border-\[\#FFCD20\]\/30:hover { border-color: rgba(255, 205, 32, 0.3) !important; }
.hover\:border-\[\#FFCD20\]\/50:hover { border-color: rgba(255, 205, 32, 0.5) !important; }
.hover\:border-\[\#FFCD20\]\/60:hover { border-color: rgba(255, 205, 32, 0.6) !important; }
.hover\:text-\[\#FFCD20\]:hover { color: #FFCD20 !important; }
.group:hover .group-hover\:bg-\[\#FFCD20\] { background-color: #FFCD20 !important; }
.from-\[\#FFCD20\] { --tw-gradient-from: #FFCD20 var(--tw-gradient-from-position); --tw-gradient-to: rgba(255, 205, 32, 0) var(--tw-gradient-to-position); --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to); }
.to-\[\#f7c105\] { --tw-gradient-to: #f7c105 var(--tw-gradient-to-position); }
.to-\[\#FFCD20\] { --tw-gradient-to: #FFCD20 var(--tw-gradient-to-position); }
.via-\[\#FFCD20\] { --tw-gradient-stops: var(--tw-gradient-from), #FFCD20 var(--tw-gradient-via-position), var(--tw-gradient-to); }
.from-\[\#FFCD20\]\/0 { --tw-gradient-from: rgba(255, 205, 32, 0) var(--tw-gradient-from-position); --tw-gradient-to: rgba(255, 205, 32, 0) var(--tw-gradient-to-position); --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to); }
.from-\[\#FFCD20\]\/20 { --tw-gradient-from: rgba(255, 205, 32, 0.2) var(--tw-gradient-from-position); --tw-gradient-to: rgba(255, 205, 32, 0) var(--tw-gradient-to-position); --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to); }
.to-\[\#FFCD20\]\/5 { --tw-gradient-to: rgba(255, 205, 32, 0.05) var(--tw-gradient-to-position); }
.to-\[\#FFCD20\]\/20 { --tw-gradient-to: rgba(255, 205, 32, 0.2) var(--tw-gradient-to-position); }
.from-\[\#1a1a2e\] { --tw-gradient-from: #1a1a2e var(--tw-gradient-from-position); --tw-gradient-to: rgba(26, 26, 46, 0) var(--tw-gradient-to-position); --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to); }
.to-\[\#1a1a2e\] { --tw-gradient-to: #1a1a2e var(--tw-gradient-to-position); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .brand-marquee-track {
    animation: none !important;
    will-change: auto !important;
  }
}

/* ----- Nav: scroll state + mobile menu ----- */
nav {
  transition: box-shadow 0.3s var(--ease-in-out);
}
nav.nav-scrolled {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}
.nav-mobile-menu {
  display: none;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.3s var(--ease-out-expo), opacity 0.2s ease;
}
nav.nav-mobile-open .nav-mobile-menu {
  display: block;
  max-height: 80vh;
  opacity: 1;
  overflow-y: auto;
}

/* ----- Sticky action buttons: appear after hero (no black + buttons only) ----- */
.sticky-actions {
  opacity: 0;
  transform: translateX(24px);
  pointer-events: none;
  transition: opacity 0.5s var(--ease-spring), transform 0.5s var(--ease-spring), pointer-events 0s 0.5s;
}
.sticky-actions.revealed {
  opacity: 1;
  transform: translateX(0);
  pointer-events: auto;
  transition-delay: 0s;
}
.sticky-actions.revealed a,
.sticky-actions.revealed button {
  transition: transform 0.25s var(--ease-spring), box-shadow 0.25s var(--ease-in-out);
}
.sticky-actions.revealed a:hover,
.sticky-actions.revealed button:hover {
  transform: scale(1.08);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.2);
}

/* ----- Section scroll: fade + slide up when in view ----- */
.has-scroll-animate .section-content {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity 0.7s var(--ease-out-expo), transform 0.7s var(--ease-out-expo);
}
.has-scroll-animate.in-view .section-content {
  opacity: 1;
  transform: translateY(0);
}

.has-scroll-animate .section-content > * {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s var(--ease-out-expo), transform 0.5s var(--ease-out-expo);
}
.has-scroll-animate.in-view .section-content > *:nth-child(1) { transition-delay: 0.05s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content > *:nth-child(2) { transition-delay: 0.12s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content > *:nth-child(3) { transition-delay: 0.19s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content > *:nth-child(4) { transition-delay: 0.26s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content > *:nth-child(5) { transition-delay: 0.33s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content > *:nth-child(6) { transition-delay: 0.4s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content > *:nth-child(n+7) { transition-delay: 0.47s; opacity: 1; transform: translateY(0); }

/* ----- Grid children (logos, cards) ----- */
.has-scroll-animate .section-content .grid > * {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.45s var(--ease-out-expo), transform 0.45s var(--ease-out-expo);
}
.has-scroll-animate.in-view .section-content .grid > *:nth-child(1) { transition-delay: 0.1s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content .grid > *:nth-child(2) { transition-delay: 0.18s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content .grid > *:nth-child(3) { transition-delay: 0.26s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content .grid > *:nth-child(4) { transition-delay: 0.34s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content .grid > *:nth-child(5) { transition-delay: 0.42s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content .grid > *:nth-child(6) { transition-delay: 0.5s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content .grid > *:nth-child(7) { transition-delay: 0.58s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content .grid > *:nth-child(8) { transition-delay: 0.66s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content .grid > *:nth-child(9) { transition-delay: 0.74s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content .grid > *:nth-child(10) { transition-delay: 0.82s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content .grid > *:nth-child(11) { transition-delay: 0.9s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content .grid > *:nth-child(12) { transition-delay: 0.98s; opacity: 1; transform: translateY(0); }
.has-scroll-animate.in-view .section-content .grid > *:nth-child(n+13) { transition-delay: 1.06s; opacity: 1; transform: translateY(0); }

/* ----- Mobile: Portfolio videos – opacity-only animation (no transform) ----- */
/* iOS Safari has a bug: iframes inside elements with transform render blank. Using opacity-only on mobile fixes this. */
@media (max-width: 767px) {
  #portfolio.has-scroll-animate .section-content,
  #portfolio.has-scroll-animate .section-content > *,
  #portfolio.has-scroll-animate .section-content .grid > * {
    transform: none !important;
  }
  #portfolio.has-scroll-animate.in-view .section-content,
  #portfolio.has-scroll-animate.in-view .section-content > *,
  #portfolio.has-scroll-animate.in-view .section-content .grid > * {
    transform: none !important;
  }
}

/* ----- Card / block hover lift (sections with cards) ----- */
.hover-lift {
  transition: transform 0.35s var(--ease-spring), box-shadow 0.35s var(--ease-in-out);
}
.hover-lift:hover {
  transform: translateY(-6px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.12);
}

/* ----- Buttons: subtle scale on hover/active ----- */
.btn-interact {
  transition: transform 0.2s var(--ease-spring), box-shadow 0.2s var(--ease-in-out);
}
.btn-interact:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(255, 205, 32, 0.35);
}
.btn-interact:active {
  transform: translateY(0);
}

/* ----- FAQ accordion ----- */
.faq-item .faq-body {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.35s var(--ease-out-expo);
}
.faq-item.faq-open .faq-body {
  grid-template-rows: 1fr;
}
.faq-item .faq-body-inner {
  overflow: hidden;
}
.faq-item .faq-body-inner > div {
  padding-top: 0;
  transition: padding-top 0.25s var(--ease-out-expo);
}
.faq-item.faq-open .faq-body-inner > div {
  padding-top: 0;
}
/* FAQ: show minus when open, plus when closed */
.faq-icon-wrap {
  position: relative;
}
.faq-icon-wrap .faq-icon-plus,
.faq-icon-wrap .faq-icon-minus {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.faq-item .faq-icon-minus {
  display: none !important;
}
.faq-item.faq-open .faq-icon-plus {
  display: none !important;
}
.faq-item.faq-open .faq-icon-minus {
  display: inline-flex !important;
}

/* ----- Brand logos infinite marquee ----- */
.brand-marquee {
  overflow: hidden;
}
.brand-marquee-track {
  display: flex;
  width: max-content;
  animation: brand-marquee 50s linear infinite;
  will-change: transform;
  backface-visibility: hidden;
}
.brand-marquee-track-reverse {
  animation-direction: reverse;
}
@keyframes brand-marquee {
  0% { transform: translate3d(0, 0, 0); }
  100% { transform: translate3d(-50%, 0, 0); }
}
