/* =========================================================
   Zynx Games — Custom Stylesheet
   Works alongside Tailwind CSS (CDN). Utility classes below
   are written in plain CSS (no @apply) so they run reliably
   with the Tailwind Play CDN build.
   ========================================================= */

:root {
  --zynx-blue: #4f46e5;
  --zynx-purple: #9333ea;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Nunito', ui-sans-serif, system-ui, sans-serif;
}

/* ---------- Scrollbar ---------- */
::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: #05050a; }
::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--zynx-blue), var(--zynx-purple));
  border-radius: 10px;
}

/* ---------- Skip link (accessibility) ---------- */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  background: var(--zynx-blue);
  color: #fff;
  padding: .75rem 1.25rem;
  border-radius: .5rem;
  z-index: 100;
  font-weight: 700;
  transition: top .2s ease;
}
.skip-link:focus { top: 1rem; }

/* ---------- Gradient text ---------- */
.text-gradient {
  background-image: linear-gradient(90deg, #818cf8, #c084fc, #818cf8);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ---------- Hero grid background ---------- */
.bg-hero-grid {
  background-image:
    linear-gradient(rgba(255,255,255,0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.045) 1px, transparent 1px);
  background-size: 46px 46px;
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 40%, transparent 100%);
  mask-image: radial-gradient(ellipse 80% 60% at 50% 0%, #000 40%, transparent 100%);
}

/* ---------- Buttons ---------- */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: .9rem 1.9rem;
  border-radius: 9999px;
  font-weight: 800;
  font-size: .95rem;
  color: #fff;
  background-image: linear-gradient(90deg, var(--zynx-blue), var(--zynx-purple));
  box-shadow: 0 12px 30px -10px rgba(147, 51, 234, .55);
  transition: transform .25s ease, box-shadow .25s ease;
}
.btn-primary:hover { transform: translateY(-2px) scale(1.02); box-shadow: 0 16px 36px -8px rgba(147, 51, 234, .7); }
.btn-primary:active { transform: translateY(0) scale(0.99); }

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: .85rem 1.9rem;
  border-radius: 9999px;
  font-weight: 800;
  font-size: .95rem;
  color: #e2e8f0;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.16);
  backdrop-filter: blur(6px);
  transition: all .25s ease;
}
.btn-secondary:hover { background: rgba(255,255,255,.1); border-color: rgba(255,255,255,.32); transform: translateY(-2px); }

/* ---------- Nav links ---------- */
.nav-link {
  position: relative;
  font-weight: 700;
  font-size: .95rem;
  color: #cbd5e1;
  transition: color .2s ease;
}
.nav-link:hover, .nav-link.active { color: #fff; }
.nav-link::after {
  content: '';
  position: absolute; left: 0; bottom: -6px;
  width: 0; height: 2px;
  background: linear-gradient(90deg, #818cf8, #c084fc);
  transition: width .3s ease;
}
.nav-link:hover::after, .nav-link.active::after { width: 100%; }

.mobile-nav-link {
  display: block;
  padding: .85rem 0;
  font-weight: 700;
  color: #cbd5e1;
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.mobile-nav-link.active { color: #c4b5fd; }

/* ---------- Header scrolled state ---------- */
#site-header { background: transparent; }
#site-header.scrolled {
  background: rgba(5,5,10,.82);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(255,255,255,.08);
  box-shadow: 0 10px 30px -18px rgba(0,0,0,.7);
}

/* ---------- Glass card ---------- */
.glass-card {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

/* ---------- Scroll reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .7s ease, transform .7s ease;
  will-change: opacity, transform;
}
.reveal.in-view { opacity: 1; transform: translateY(0); }
.reveal-delay-1.in-view { transition-delay: .08s; }
.reveal-delay-2.in-view { transition-delay: .16s; }
.reveal-delay-3.in-view { transition-delay: .24s; }
.reveal-delay-4.in-view { transition-delay: .32s; }
.reveal-delay-5.in-view { transition-delay: .4s; }
.reveal-delay-6.in-view { transition-delay: .48s; }

/* ---------- Focus states (accessibility) ---------- */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 2px solid #818cf8;
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- Forms ---------- */
.form-input {
  width: 100%;
  padding: .9rem 1.05rem;
  border-radius: .75rem;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.14);
  color: #f1f5f9;
  font-family: inherit;
  transition: border-color .2s ease, background .2s ease;
}
.form-input::placeholder { color: #64748b; }
.form-input:focus { border-color: #818cf8; background: rgba(255,255,255,.08); outline: none; }

/* ---------- Modal ---------- */
.modal-overlay { background: rgba(2,2,8,.78); backdrop-filter: blur(5px); }

/* ---------- Footer ---------- */
.social-icon {
  display: flex; align-items: center; justify-content: center;
  height: 2.6rem; width: 2.6rem; border-radius: 9999px;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.1);
  color: #cbd5e1;
  transition: all .25s ease;
}
.social-icon:hover {
  background: linear-gradient(135deg, var(--zynx-blue), var(--zynx-purple));
  color: #fff;
  transform: translateY(-3px);
  border-color: transparent;
}
.footer-link { color: #94a3b8; transition: color .2s ease; }
.footer-link:hover { color: #c4b5fd; }

/* ---------- Blob glow shapes ---------- */
.blob {
  position: absolute;
  border-radius: 9999px;
  filter: blur(110px);
  pointer-events: none;
  z-index: -1;
}

/* ---------- Utility: icon badge ---------- */
.icon-badge {
  height: 3.25rem; width: 3.25rem;
  border-radius: 1rem;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, rgba(79,70,229,.25), rgba(147,51,234,.25));
  border: 1px solid rgba(147,51,234,.25);
  color: #c4b5fd;
  font-size: 1.25rem;
}