/*
 * NEXA POINT GROUP — Themes
 * Premium visual effects: glassmorphism, glowing edges, hero overlays,
 * gradient borders, spotlight effects, and dark-mode-specific decorations.
 * Applied on top of the token system — never hardcode colours here.
 */

/* ══════════════════════════════════════════════════════
   GLASSMORPHISM CARDS
   Used sparingly on high-impact pages (Home, Services, About)
   ══════════════════════════════════════════════════════ */
.glass {
  background: var(--color-surface-overlay);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-2xl);
}

[data-theme="dark"] .glass {
  background: rgba(12, 22, 48, 0.75);
  border-color: rgba(33, 151, 241, 0.12);
}

.glass--light {
  background: rgba(255, 255, 255, 0.60);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.30);
}

.glass--dark {
  background: rgba(6, 12, 30, 0.80);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(33, 151, 241, 0.15);
}

/* ══════════════════════════════════════════════════════
   GRADIENT BORDER CARDS
   ══════════════════════════════════════════════════════ */
.gradient-border {
  position: relative;
  border-radius: var(--radius-2xl);
  padding: 1px;
  background: var(--gradient-brand);
}

.gradient-border__inner {
  background: var(--color-surface);
  border-radius: calc(var(--radius-2xl) - 1px);
  padding: var(--space-8);
  height: 100%;
}

/* ══════════════════════════════════════════════════════
   HERO SECTION THEMES
   ══════════════════════════════════════════════════════ */
.hero-dark {
  background: var(--color-bg);
  position: relative;
  overflow: hidden;
}

/* Primary radial glow behind the hero content */
.hero-dark::before {
  content: '';
  position: absolute;
  top: -20%;
  left: 50%;
  transform: translateX(-50%);
  width: 80vw;
  height: 80vw;
  max-width: 900px;
  max-height: 900px;
  background: radial-gradient(ellipse at center, rgba(33,151,241,0.12) 0%, transparent 65%);
  pointer-events: none;
  z-index: 0;
}

/* Secondary accent glow bottom-left */
.hero-dark::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: -10%;
  width: 50vw;
  height: 50vw;
  max-width: 600px;
  max-height: 600px;
  background: radial-gradient(ellipse at center, rgba(0,27,239,0.08) 0%, transparent 65%);
  pointer-events: none;
  z-index: 0;
}

/* ──── Dark-mode amplified hero glows ──── */
[data-theme="dark"] .hero-dark::before {
  background: radial-gradient(ellipse at center, rgba(33,151,241,0.18) 0%, transparent 65%);
}

[data-theme="dark"] .hero-dark::after {
  background: radial-gradient(ellipse at center, rgba(0,27,239,0.14) 0%, transparent 65%);
}

/* ── Gradient hero (full-bleed blue) ── */
.hero-gradient {
  background: var(--gradient-hero);
  position: relative;
  overflow: hidden;
}

.hero-gradient::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.04) 1px, transparent 1px);
  background-size: 60px 60px;
  pointer-events: none;
}

/* ══════════════════════════════════════════════════════
   SPOTLIGHT EFFECT (follows cursor on hero — JS adds position)
   ══════════════════════════════════════════════════════ */
.spotlight {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background: radial-gradient(
    600px circle at var(--mouse-x, 50%) var(--mouse-y, 50%),
    rgba(33, 151, 241, 0.07),
    transparent 60%
  );
  transition: background 0.1s ease;
}

[data-theme="dark"] .spotlight {
  background: radial-gradient(
    600px circle at var(--mouse-x, 50%) var(--mouse-y, 50%),
    rgba(33, 151, 241, 0.12),
    transparent 60%
  );
}

/* ══════════════════════════════════════════════════════
   SECTION BACKGROUNDS
   ══════════════════════════════════════════════════════ */
.section-bg--alt {
  background: var(--color-bg-alt);
}

.section-bg--surface {
  background: var(--color-surface);
}

.section-bg--gradient {
  background: linear-gradient(
    180deg,
    var(--color-bg) 0%,
    var(--color-bg-alt) 100%
  );
}

/* Dark-mode accent section */
.section-bg--dark-accent {
  background: var(--color-bg);
  position: relative;
  overflow: hidden;
}

.section-bg--dark-accent::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 120%;
  height: 120%;
  background: radial-gradient(ellipse at center, rgba(33,151,241,0.06) 0%, transparent 60%);
  pointer-events: none;
}

/* ══════════════════════════════════════════════════════
   GLOWING ICON CONTAINERS
   ══════════════════════════════════════════════════════ */
.icon-glow {
  position: relative;
  display: inline-flex;
}

.icon-glow::before {
  content: '';
  position: absolute;
  inset: -8px;
  border-radius: inherit;
  background: var(--color-accent-subtle);
  filter: blur(12px);
  opacity: 0;
  transition: opacity var(--transition-base);
  pointer-events: none;
}

.icon-glow:hover::before {
  opacity: 1;
}

/* ══════════════════════════════════════════════════════
   ANIMATED GRADIENT BORDER BUTTON
   ══════════════════════════════════════════════════════ */
.btn-gradient-border {
  position: relative;
  border-radius: var(--radius-full);
  padding: 2px;
  background: var(--gradient-brand);
  display: inline-block;
  text-decoration: none;
}

.btn-gradient-border__inner {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: 0.72em 1.7em;
  background: var(--color-surface);
  border-radius: var(--radius-full);
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  color: var(--color-accent);
  transition: background var(--transition-fast), color var(--transition-fast);
  white-space: nowrap;
}

.btn-gradient-border:hover .btn-gradient-border__inner {
  background: transparent;
  color: #fff;
}

/* ══════════════════════════════════════════════════════
   DARK-MODE CARD ENHANCEMENTS
   ══════════════════════════════════════════════════════ */
[data-theme="dark"] .card,
[data-theme="dark"] .service-card {
  background: var(--color-surface);
  border-color: var(--color-border);
}

[data-theme="dark"] .card:hover,
[data-theme="dark"] .service-card:hover {
  background: var(--color-surface-raised);
  border-color: rgba(33, 151, 241, 0.30);
  box-shadow:
    var(--shadow-lg),
    0 0 40px rgba(33, 151, 241, 0.08);
}

/* ══════════════════════════════════════════════════════
   THEME TOGGLE BUTTON
   ══════════════════════════════════════════════════════ */
.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  color: var(--color-text-muted);
  cursor: pointer;
  transition:
    background var(--transition-fast),
    border-color var(--transition-fast),
    color var(--transition-fast),
    transform var(--transition-fast);
}

.theme-toggle:hover {
  background: var(--color-accent-subtle);
  border-color: var(--color-accent);
  color: var(--color-accent);
  transform: rotate(12deg);
}

.theme-toggle svg {
  width: 18px;
  height: 18px;
  transition: transform var(--transition-base);
}

/* Show/hide icons based on theme */
.theme-toggle .icon-sun  { display: none; }
.theme-toggle .icon-moon { display: block; }

[data-theme="dark"] .theme-toggle .icon-sun  { display: block; }
[data-theme="dark"] .theme-toggle .icon-moon { display: none; }

/* ══════════════════════════════════════════════════════
   NOISE / TEXTURE OVERLAY
   Applied to hero sections for subtle premium texture
   ══════════════════════════════════════════════════════ */
.noise-overlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.025;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 128px 128px;
}

[data-theme="dark"] .noise-overlay {
  opacity: 0.04;
}

/* ══════════════════════════════════════════════════════
   FLOATING OPERATION LAYER CARDS (hero visual)
   ══════════════════════════════════════════════════════ */
.op-card {
  background: var(--color-surface-overlay);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-xl);
  padding: var(--space-4) var(--space-5);
  display: flex;
  align-items: center;
  gap: var(--space-3);
  box-shadow: var(--shadow-lg);
  min-width: 180px;
  pointer-events: none;
}

[data-theme="dark"] .op-card {
  background: rgba(12, 22, 48, 0.85);
  border-color: rgba(33,151,241,0.18);
}

.op-card__dot {
  width: 10px;
  height: 10px;
  border-radius: var(--radius-full);
  background: var(--gradient-brand);
  flex-shrink: 0;
  animation: glowPulse 2s ease-in-out infinite;
}

.op-card__label {
  font-size: var(--text-xs);
  font-weight: var(--weight-semibold);
  color: var(--color-text);
  white-space: nowrap;
}

.op-card__sub {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
}

/* ══════════════════════════════════════════════════════
   HERO GRID BACKGROUND
   Subtle animated dot grid — gives hero depth without
   distracting from the copy.
   ══════════════════════════════════════════════════════ */
.grid-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image:
    radial-gradient(circle, rgba(0, 27, 239, 0.12) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 40%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 40%, transparent 100%);
  animation: gridPulse 8s ease-in-out infinite;
}

[data-theme="dark"] .grid-bg {
  background-image:
    radial-gradient(circle, rgba(33, 151, 241, 0.18) 1px, transparent 1px);
}

/* ══════════════════════════════════════════════════════
   SECTION GRADIENT ACCENT — subtle top-edge gradient line
   ══════════════════════════════════════════════════════ */
.section-accent-top {
  position: relative;
}

.section-accent-top::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60%;
  height: 1px;
  background: var(--gradient-brand);
  opacity: 0.35;
  pointer-events: none;
}

/* ══════════════════════════════════════════════════════
   STATS SECTION VISUAL TREATMENT
   Adds a centered ambient glow under the numbers
   ══════════════════════════════════════════════════════ */
.stats-glow {
  position: relative;
}

.stats-glow::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 70%;
  height: 200%;
  background: radial-gradient(ellipse at center, var(--color-accent-glow) 0%, transparent 65%);
  pointer-events: none;
  z-index: 0;
}

.stats-glow > * {
  position: relative;
  z-index: 1;
}

/* ══════════════════════════════════════════════════════
   TRUST STRIP — MARQUEE SCROLL
   Infinite horizontal scroll when logos exceed viewport
   ══════════════════════════════════════════════════════ */
.trust-strip__track {
  display: flex;
  align-items: center;
  gap: var(--space-12);
  animation: marquee 28s linear infinite;
  width: max-content;
}

.trust-strip__track:hover {
  animation-play-state: paused;
}

@keyframes marquee {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}

@media (prefers-reduced-motion: reduce) {
  .trust-strip__track {
    animation: none;
  }
}

/* ══════════════════════════════════════════════════════
   HERO VISUAL COMPOSITION — right column depth layer
   Adds a faint radial glow behind the floating cards
   ══════════════════════════════════════════════════════ */
.hero__visual-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 320px;
  height: 320px;
  background: radial-gradient(circle, rgba(33,151,241,0.10) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

[data-theme="dark"] .hero__visual-glow {
  background: radial-gradient(circle, rgba(33,151,241,0.18) 0%, transparent 70%);
}

/* ══════════════════════════════════════════════════════
   DARK MODE — stronger section contrast
   ══════════════════════════════════════════════════════ */
[data-theme="dark"] .section-bg--alt {
  background: var(--color-bg-alt);
  border-top: 1px solid var(--color-border-subtle);
  border-bottom: 1px solid var(--color-border-subtle);
}

[data-theme="dark"] .section-bg--surface {
  background: var(--color-surface);
  border-top: 1px solid var(--color-border-subtle);
  border-bottom: 1px solid var(--color-border-subtle);
}

/* ══════════════════════════════════════════════════════
   CARD ACCENT LINE — top gradient edge on card hover
   ══════════════════════════════════════════════════════ */
.card--feature {
  overflow: hidden;
}

.card--feature::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--gradient-brand);
  opacity: 0;
  transition: opacity var(--transition-base);
}

.card--feature:hover::after {
  opacity: 1;
}

/* ══════════════════════════════════════════════════════
   SKIP LINK (accessibility)
   ══════════════════════════════════════════════════════ */
.skip-link {
  position: absolute;
  top: -100%;
  left: var(--space-4);
  background: var(--color-accent);
  color: #fff;
  padding: var(--space-2) var(--space-4);
  border-radius: 0 0 var(--radius-md) var(--radius-md);
  font-size: var(--text-sm);
  font-weight: var(--weight-semibold);
  text-decoration: none;
  z-index: var(--z-max);
  transition: top var(--transition-fast);
}

.skip-link:focus {
  top: 0;
}
