/*
Theme Name:   Nexus Agency
Description:  Premium digital agency child theme for Hello Elementor
Author:       Nexus Digital Agency
Template:     hello-elementor
Version:      1.0.0
Text Domain:  nexus-agency
*/

/* =============================================
   NEXUS AGENCY — WordPress Theme CSS
   Extends Hello Elementor (parent theme)
   All variables and base styles below are
   automatically loaded by WordPress via
   functions.php enqueue_scripts().
   ============================================= */

:root {
  --bg-0: #05050a;
  --bg-1: #0c0c18;
  --bg-2: #12121f;
  --bg-3: #1a1a2e;
  --surface: rgba(255,255,255,0.03);
  --surface-hover: rgba(255,255,255,0.07);
  --border: rgba(255,255,255,0.06);
  --border-hover: rgba(255,255,255,0.15);
  --accent-violet: #7c3aed;
  --accent-violet-light: #a78bfa;
  --accent-cyan: #06b6d4;
  --accent-rose: #f43f5e;
  --accent-amber: #f59e0b;
  --grad-primary: linear-gradient(135deg, #7c3aed 0%, #06b6d4 100%);
  --grad-hero: linear-gradient(135deg, #0f0c29 0%, #302b63 50%, #24243e 100%);
  --text-0: #ffffff;
  --text-1: rgba(255,255,255,0.75);
  --text-2: rgba(255,255,255,0.45);
  --text-3: rgba(255,255,255,0.25);
  --font-display: 'Syne', sans-serif;
  --font-body: 'DM Sans', sans-serif;
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 40px;
  --transition: 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-fast: 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

[data-theme="light"] {
  --bg-0: #f8f7ff;
  --bg-1: #ffffff;
  --bg-2: #f1f0fc;
  --bg-3: #e8e6f8;
  --surface: rgba(0,0,0,0.03);
  --border: rgba(0,0,0,0.08);
  --text-0: #0f0c29;
  --text-1: rgba(15,12,41,0.75);
  --text-2: rgba(15,12,41,0.45);
  --text-3: rgba(15,12,41,0.25);
}

/* ---- Global resets ---- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scrollbar-width: thin;
  scrollbar-color: var(--accent-violet) transparent;
}
html::-webkit-scrollbar { width: 4px; }
html::-webkit-scrollbar-thumb { background: var(--accent-violet); border-radius: 2px; }

body {
  font-family: var(--font-body);
  background-color: var(--bg-0);
  color: var(--text-0);
  cursor: none;           /* hidden because JS custom cursor runs */
  overflow-x: hidden;
  transition: background-color 0.4s, color 0.4s;
}

/* ----- Custom Cursor ----- */
#cursor-dot {
  position: fixed;
  width: 8px; height: 8px;
  background: #ffffff;
  border-radius: 50%;
  pointer-events: none;
  z-index: 10001;
  transform: translate(-50%, -50%);
  will-change: left, top;
  opacity: 0;
  mix-blend-mode: difference;
  transition: width 0.2s, height 0.2s, background 0.2s;
}
#cursor-ring {
  position: fixed;
  width: 40px; height: 40px;
  border: 1.5px solid rgba(255,255,255,0.55);
  border-radius: 50%;
  pointer-events: none;
  z-index: 10000;
  transform: translate(-50%, -50%);
  will-change: left, top;
  opacity: 0;
  transition: width 0.25s, height 0.25s, border-color 0.25s;
}
#cursor-ring.hover { width: 60px; height: 60px; border-color: var(--accent-violet-light); }
#cursor-dot.visible, #cursor-ring.visible { opacity: 1; }

@media (max-width: 768px) {
  body { cursor: auto; }
  #cursor-dot, #cursor-ring { display: none; }
}

/* ----- Progress Bar ----- */
#nexus-progress {
  position: fixed; top: 0; left: 0; height: 2px;
  background: var(--grad-primary); z-index: 99999;
  width: 0%; transition: width 0.2s linear;
}

/* ----- Noise texture overlay ----- */
body::before {
  content: '';
  position: fixed; inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none; z-index: 9998; opacity: 0.35;
}

/* ----- Typography ----- */
h1,h2,h3,h4,h5,h6 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--text-0);
}
p { color: var(--text-1); }
a { text-decoration: none; color: inherit; }

.text-gradient {
  background: var(--grad-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ----- Buttons ----- */
.nexus-btn {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-body); font-size: 0.95rem; font-weight: 500;
  padding: 14px 28px; border-radius: var(--radius-xl);
  border: none; cursor: none;
  position: relative; overflow: hidden;
  transition: var(--transition);
  text-decoration: none;
}
.nexus-btn::before {
  content: '';
  position: absolute; inset: 0;
  background: rgba(255,255,255,0.1);
  transform: scaleX(0); transform-origin: left;
  transition: transform var(--transition);
}
.nexus-btn:hover::before { transform: scaleX(1); }
.nexus-btn-primary {
  background: var(--grad-primary); color: white;
  box-shadow: 0 8px 30px rgba(124,58,237,0.4);
}
.nexus-btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 40px rgba(124,58,237,0.6); }
.nexus-btn-ghost {
  background: var(--surface); color: var(--text-0);
  border: 1px solid var(--border-hover); backdrop-filter: blur(12px);
}
.nexus-btn-ghost:hover { border-color: var(--accent-violet); transform: translateY(-2px); }

/* ----- Scroll reveal ----- */
.nexus-reveal {
  opacity: 0;
  transform: translateY(40px);
}
.nexus-reveal.revealed {
  opacity: 1; transform: translateY(0);
  transition: opacity 0.7s cubic-bezier(0.16,1,0.3,1), transform 0.7s cubic-bezier(0.16,1,0.3,1);
}

/* ----- Elementor section overrides ----- */
.elementor-section { position: relative; }
.e-con, .elementor-container { max-width: 1280px; }

/* Elementor global kit overrides */
.elementor-kit-1 body {
  --e-global-color-primary: #7c3aed;
  --e-global-color-secondary: #06b6d4;
  --e-global-color-text: rgba(255,255,255,0.75);
  --e-global-color-accent: #a78bfa;
  --e-global-typography-primary-font-family: 'Syne';
  --e-global-typography-secondary-font-family: 'DM Sans';
}

/* ----- Glass card mixin (use as Elementor custom class) ----- */
.nexus-glass {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: var(--radius-lg);
}

/* ----- Service cards ----- */
.nexus-service-card {
  background: var(--bg-1);
  border: 1px solid var(--border);
  padding: 2.5rem;
  position: relative; overflow: hidden;
  transition: var(--transition);
  cursor: none;
}
.nexus-service-card:hover {
  border-color: rgba(124,58,237,0.3);
  transform: translateY(-4px);
  box-shadow: 0 30px 80px rgba(0,0,0,0.4);
}
.nexus-service-icon {
  width: 52px; height: 52px;
  border-radius: var(--radius-sm);
  background: rgba(124,58,237,0.12);
  border: 1px solid rgba(124,58,237,0.25);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem; margin-bottom: 1.5rem;
  transition: var(--transition);
}
.nexus-service-card:hover .nexus-service-icon {
  transform: scale(1.05) rotate(-3deg);
  background: rgba(124,58,237,0.25);
}

/* ----- Portfolio ----- */
.nexus-portfolio-item {
  border-radius: var(--radius-md);
  overflow: hidden; position: relative;
  cursor: none;
}
.nexus-portfolio-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(5,5,10,0.9) 0%, transparent 60%);
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 1.5rem;
  opacity: 0; transition: opacity var(--transition);
}
.nexus-portfolio-item:hover .nexus-portfolio-overlay { opacity: 1; }
.nexus-portfolio-item img { transition: transform 0.6s cubic-bezier(0.16,1,0.3,1); }
.nexus-portfolio-item:hover img { transform: scale(1.06); }

/* ----- Testimonials strip ----- */
.nexus-testimonial-card {
  background: var(--bg-1);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  transition: var(--transition);
}
.nexus-testimonial-card:hover {
  border-color: rgba(124,58,237,0.3);
  transform: translateY(-4px);
}

/* ----- Chatbot ----- */
#nexus-chat-trigger {
  position: fixed; bottom: 2rem; right: 2rem;
  width: 56px; height: 56px; border-radius: 50%;
  background: var(--grad-primary);
  box-shadow: 0 8px 30px rgba(124,58,237,0.5);
  display: flex; align-items: center; justify-content: center;
  z-index: 900; cursor: none; border: none; font-size: 1.3rem;
  transition: var(--transition);
}
#nexus-chat-trigger:hover { transform: scale(1.1) rotate(5deg); }

#nexus-chat-window {
  position: fixed; bottom: 6rem; right: 2rem;
  width: 360px; border-radius: var(--radius-lg);
  background: var(--bg-1); border: 1px solid var(--border);
  box-shadow: 0 30px 80px rgba(0,0,0,0.5); z-index: 900;
  overflow: hidden;
  transform: translateY(20px) scale(0.95); opacity: 0;
  pointer-events: none; transition: var(--transition);
}
#nexus-chat-window.open {
  transform: translateY(0) scale(1); opacity: 1;
  pointer-events: all;
}

/* ----- Navbar ----- */
#nexus-navbar {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 1000; padding: 24px 0;
  transition: padding 0.4s, background 0.4s, backdrop-filter 0.4s, border-color 0.4s;
  border-bottom: 1px solid transparent;
}
#nexus-navbar.scrolled {
  padding: 14px 0;
  background: rgba(5,5,10,0.8);
  backdrop-filter: blur(24px);
  border-bottom-color: var(--border);
}
[data-theme="light"] #nexus-navbar.scrolled {
  background: rgba(248,247,255,0.88);
}

/* ----- Eyebrow label ----- */
.nexus-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-body); font-size: 0.75rem; font-weight: 500;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--accent-violet-light); margin-bottom: 1.5rem;
}
.nexus-eyebrow::before {
  content: ''; width: 24px; height: 1px; background: var(--accent-violet-light);
}

/* ----- Marquee ----- */
.nexus-marquee-track {
  display: flex; gap: 4rem; align-items: center;
  animation: nexusMarquee 22s linear infinite;
  white-space: nowrap;
}
.nexus-marquee-track:hover { animation-play-state: paused; }
@keyframes nexusMarquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* ----- Floating orbs ----- */
@keyframes nexusFloat {
  0%,100% { transform: translate(0,0) scale(1); }
  33% { transform: translate(20px,-30px) scale(1.05); }
  66% { transform: translate(-15px,20px) scale(0.97); }
}
.nexus-orb { border-radius: 50%; filter: blur(70px); animation: nexusFloat 8s ease-in-out infinite; }

/* ----- Form styles ----- */
.nexus-form-input {
  width: 100%; padding: 12px 16px;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius-sm); color: var(--text-0);
  font-family: var(--font-body); font-size: 0.9rem;
  transition: var(--transition-fast); outline: none;
}
.nexus-form-input:focus {
  border-color: var(--accent-violet);
  box-shadow: 0 0 0 3px rgba(124,58,237,0.12);
}
.nexus-form-input.error { border-color: var(--accent-rose); }

/* ---- Blog cards ---- */
.nexus-blog-card { cursor: none; }
.nexus-blog-card .thumb img { transition: transform 0.5s cubic-bezier(0.16,1,0.3,1); }
.nexus-blog-card:hover .thumb img { transform: scale(1.05); }
.nexus-blog-card:hover h3, .nexus-blog-card:hover h4 { color: var(--accent-violet-light); }

/* ---- Filter buttons ---- */
.nexus-filter-btn {
  padding: 8px 20px; border-radius: 100px;
  border: 1px solid var(--border); background: transparent;
  color: var(--text-2); font-family: var(--font-body); font-size: 0.85rem;
  cursor: none; transition: var(--transition-fast);
}
.nexus-filter-btn:hover, .nexus-filter-btn.active {
  background: var(--accent-violet); border-color: var(--accent-violet); color: white;
}

/* ---- Lottie placeholder ---- */
.nexus-lottie-wrap { display: flex; align-items: center; justify-content: center; }
