/* ================================================================
   CodeX — Dev Toolbox Platform
   assets/css/layout.css | Structural Layout
   Author: Sabbir Hasan | GitHub: Dark-Devil-king
================================================================ */

/* ===== BACKGROUND DECORATIONS ===== */
.neon-grid-overlay {
  position: fixed; top: 0; left: 0; width: 100%; height: 100%;
  z-index: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(0,245,255,0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0,245,255,0.025) 1px, transparent 1px);
  background-size: 80px 80px;
}
.neon-lines { position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.nl {
  position: absolute; height: 1px;
  background: linear-gradient(90deg, transparent, var(--cyan), transparent);
  opacity: 0; animation: neonLine 8s ease-in-out infinite;
}
.nl-1 { width: 60%; top: 20%; left: -60%; animation-delay: 0s; }
.nl-2 { width: 40%; top: 55%; left: -40%; background: linear-gradient(90deg, transparent, var(--purple), transparent); animation-delay: 2s; }
.nl-3 { width: 70%; top: 75%; left: -70%; background: linear-gradient(90deg, transparent, var(--pink),   transparent); animation-delay: 4s; }
.nl-4 { width: 50%; top: 38%; left: -50%; background: linear-gradient(90deg, transparent, var(--blue),   transparent); animation-delay: 6s; }

#particle-canvas { position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }

/* ===== PRELOADER ===== */
#preloader {
  position: fixed; inset: 0;
  background: var(--bg-primary);
  z-index: 9999;
  display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 24px;
  transition: opacity 0.6s, visibility 0.6s;
}
#preloader.hidden { opacity: 0; visibility: hidden; }
.pl-logo { font-family: 'Orbitron', sans-serif; font-size: clamp(2.5rem,8vw,5rem); font-weight: 900; letter-spacing: 0.1em; }
.pl-logo .C    { color: #fff; font-size: 1.4em; line-height: 1; text-shadow: 0 0 40px rgba(255,255,255,0.5); }
.pl-logo .odeX {
  background: linear-gradient(90deg, var(--cyan), var(--purple), var(--pink));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 30px rgba(0,245,255,0.8));
  animation: neonPulse 2s ease-in-out infinite;
}
.pl-bar-wrap { width: 260px; height: 3px; background: rgba(255,255,255,0.06); border-radius: 99px; overflow: hidden; box-shadow: 0 0 10px rgba(0,245,255,0.2); }
.pl-bar { height: 100%; width: 0%; background: linear-gradient(90deg, var(--cyan), var(--purple)); border-radius: 99px; animation: plBar 2.2s ease forwards; box-shadow: 0 0 15px var(--cyan); }
.pl-text { font-family: 'Share Tech Mono', monospace; font-size: 0.8rem; color: var(--cyan); letter-spacing: 0.2em; animation: blink 1s infinite; }

/* ===== SCROLL PROGRESS ===== */
#scroll-progress {
  position: fixed; top: 0; left: 0; height: 3px;
  background: linear-gradient(90deg, var(--cyan), var(--purple), var(--pink));
  z-index: 9990; width: 0%;
  box-shadow: 0 0 10px var(--cyan), 0 0 20px rgba(0,245,255,0.5);
  transition: width 0.1s;
}

/* ===== CURSOR GLOW ===== */
#cursor-glow {
  position: fixed; width: 400px; height: 400px; border-radius: 50%;
  background: radial-gradient(circle, rgba(0,245,255,0.06) 0%, rgba(176,96,255,0.03) 40%, transparent 70%);
  pointer-events: none; z-index: 1;
  transform: translate(-50%,-50%); transition: transform 0.05s;
}

/* ===== STATUS BAR ===== */
.status-bar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 999;
  background: rgba(3,3,10,0.95); backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(0,245,255,0.08);
  display: flex; align-items: center; gap: 20px; padding: 6px 20px;
  font-family: 'Share Tech Mono', monospace; font-size: 0.68rem; color: var(--text-secondary);
}
.status-bar .dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; margin-right: 5px; animation: pulse 2s infinite; }
.dot.green  { background: var(--green);  box-shadow: 0 0 8px var(--green),  0 0 16px rgba(0,255,136,0.4); }
.dot.cyan   { background: var(--cyan);   box-shadow: 0 0 8px var(--cyan),   0 0 16px rgba(0,245,255,0.4); }
.dot.purple { background: var(--purple); box-shadow: 0 0 8px var(--purple), 0 0 16px rgba(176,96,255,0.4); }
.status-time { margin-left: auto; color: var(--cyan); text-shadow: 0 0 10px rgba(0,245,255,0.5); }

/* ===== NAVBAR ===== */
#navbar {
  position: fixed; top: 29px; left: 0; right: 0; z-index: 998;
  padding: 8px 24px;
  display: flex; align-items: center; justify-content: space-between;
  backdrop-filter: blur(24px);
  background: rgba(3,3,10,0.85);
  border-bottom: 1px solid var(--glass-border);
  transition: transform 0.4s ease, padding 0.3s ease, background 0.3s ease;
}
#navbar::after {
  content: '';
  position: absolute; bottom: 0; left: 0; right: 0; height: 1px;
  background: linear-gradient(90deg, transparent, var(--cyan), var(--purple), transparent);
  opacity: 0.4;
}
#navbar.scrolled { padding: 6px 28px; background: rgba(3,3,10,0.97); }

.nav-logo-group { display: flex; align-items: center; gap: 10px; }
.nav-profile-wrap {
  position: relative; width: 38px; height: 38px; cursor: pointer;
}
.nav-profile-ring {
  position: absolute; inset: -3px; border-radius: 50%;
  border: 2px solid var(--cyan);
  box-shadow: 0 0 12px rgba(0,245,255,0.5);
  animation: pulse 2s infinite;
}
.nav-profile-img { width: 38px; height: 38px; border-radius: 50%; object-fit: cover; position: relative; z-index: 1; }
.nav-profile-tooltip {
  position: absolute; bottom: -32px; left: 50%; transform: translateX(-50%);
  background: rgba(3,3,10,0.95); border: 1px solid var(--glass-border);
  padding: 4px 10px; border-radius: 6px; font-size: 0.7rem; color: var(--cyan);
  white-space: nowrap; opacity: 0; pointer-events: none; transition: opacity var(--transition);
  font-family: 'Share Tech Mono', monospace;
}
.nav-profile-wrap:hover .nav-profile-tooltip { opacity: 1; }

.nav-logo { font-family: 'Orbitron', sans-serif; font-weight: 900; font-size: 1.1rem; letter-spacing: 0.05em; display: flex; align-items: baseline; }
.nav-logo .C-big    { font-size: 1.4rem; color: #fff; line-height: 1; text-shadow: 0 0 30px rgba(255,255,255,0.5); }
.nav-logo .odeX-grad { background: linear-gradient(90deg, var(--cyan), var(--purple)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; filter: drop-shadow(0 0 12px rgba(0,245,255,0.7)); }

.nav-links { display: flex; gap: 4px; }
.nav-links a {
  padding: 7px 14px; border-radius: 8px;
  font-size: 0.82rem; font-weight: 600; letter-spacing: 0.05em;
  color: var(--text-secondary); transition: all var(--transition); position: relative;
}
.nav-links a::after {
  content: ''; position: absolute; bottom: 2px; left: 50%; right: 50%; height: 2px;
  background: linear-gradient(90deg, var(--cyan), var(--purple));
  border-radius: 99px; transition: all var(--transition); box-shadow: 0 0 8px var(--cyan);
}
.nav-links a:hover::after, .nav-links a.active::after { left: 10%; right: 10%; }
.nav-links a:hover, .nav-links a.active { color: var(--cyan); background: rgba(0,245,255,0.07); }

.nav-right { display: flex; align-items: center; gap: 12px; }
.theme-toggle {
  width: 40px; height: 40px; border-radius: 10px;
  border: 1px solid var(--glass-border); background: var(--bg-card);
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem; color: var(--text-secondary); transition: all var(--transition);
}
.theme-toggle:hover { color: var(--cyan); border-color: var(--cyan); box-shadow: var(--glow-cyan); }

.hamburger { display: none; flex-direction: column; gap: 5px; padding: 4px; background: none; }
.hamburger span { display: block; width: 24px; height: 2px; background: var(--text-primary); border-radius: 99px; transition: all var(--transition); }
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ===== MOBILE NAV ===== */
.mobile-nav {
  display: none; position: fixed; top: 0; left: 0; right: 0; bottom: 0; z-index: 997;
  background: rgba(3,3,10,0.98); backdrop-filter: blur(24px);
  padding: 120px 40px 40px; flex-direction: column; gap: 8px;
}
.mobile-nav.open { display: flex; }
.mobile-nav a { font-size: 1.4rem; font-weight: 700; color: var(--text-secondary); padding: 14px 0; border-bottom: 1px solid rgba(0,245,255,0.08); transition: all var(--transition); }
.mobile-nav a:hover { color: var(--cyan); padding-left: 12px; text-shadow: 0 0 20px rgba(0,245,255,0.5); }

/* ===== SECTIONS & CONTAINER ===== */
.section    { position: relative; z-index: 2; padding: 100px 0; }
.container  { max-width: 1180px; margin: 0 auto; padding: 0 24px; }
.section-header { text-align: center; margin-bottom: 64px; }
.section-tag   { font-family: 'Share Tech Mono', monospace; font-size: 0.78rem; color: var(--cyan); letter-spacing: 0.2em; display: block; margin-bottom: 12px; text-shadow: 0 0 12px rgba(0,245,255,0.5); }
.section-title { font-family: 'Orbitron', sans-serif; font-size: clamp(1.8rem,4vw,2.8rem); font-weight: 900; line-height: 1.2; margin-bottom: 16px; }
.section-title span { background: linear-gradient(90deg, var(--cyan), var(--purple)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; filter: drop-shadow(0 0 15px rgba(0,245,255,0.5)); }
.section-sub   { color: var(--text-secondary); font-size: 1rem; }

/* ===== GLASSMORPHISM ===== */
.glass {
  background: var(--bg-card);
  backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
}

/* ===== FLOATING SOCIAL BUTTONS ===== */
.floating-btns {
  position: fixed; right: 20px; bottom: 100px; z-index: 900;
  display: flex; flex-direction: column; gap: 10px;
}
.float-btn {
  width: 46px; height: 46px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; color: #fff; transition: all var(--transition);
  box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}
.float-btn.whatsapp { background: #25D366; }
.float-btn.facebook { background: #1877F2; }
.float-btn.email    { background: linear-gradient(135deg, var(--purple), var(--pink)); }
.float-btn:hover    { transform: translateX(-4px) scale(1.1); box-shadow: 0 6px 20px rgba(0,0,0,0.4); }

/* ===== FOOTER ===== */
footer {
  position: relative; z-index: 2;
  background: rgba(3,3,10,0.98);
  border-top: 1px solid var(--glass-border);
  padding: 40px 24px;
  text-align: center;
}
.footer-neon-line { height: 2px; background: linear-gradient(90deg, transparent, var(--cyan), var(--purple), var(--pink), transparent); margin-bottom: 40px; }
.footer-top { margin-bottom: 24px; }
.footer-logo { font-family: 'Orbitron', sans-serif; font-weight: 900; font-size: 2rem; display: inline-flex; align-items: baseline; margin-bottom: 8px; }
.footer-logo .C    { color: #fff; text-shadow: 0 0 30px rgba(255,255,255,0.4); }
.footer-logo .odeX { background: linear-gradient(90deg, var(--cyan), var(--purple)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.footer-tagline { color: var(--text-secondary); font-size: 0.9rem; margin-bottom: 20px; }
.footer-socials { display: flex; justify-content: center; gap: 16px; }
.footer-socials a {
  width: 44px; height: 44px; border-radius: 50%;
  border: 1px solid var(--glass-border); background: var(--bg-card);
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem; color: var(--text-secondary); transition: all var(--transition);
}
.footer-socials a:hover { color: var(--cyan); border-color: var(--cyan); box-shadow: var(--glow-cyan); transform: translateY(-3px); }
.footer-bottom { font-size: 0.82rem; color: var(--text-dim); }
.footer-bottom span { color: var(--cyan); }
.footer-bottom a { color: var(--cyan); transition: opacity var(--transition); }
.footer-bottom a:hover { opacity: 0.7; }

/* ===== MOBILE BOTTOM NAV ===== */
.bottom-nav {
  display: none;
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 995;
  background: rgba(3,3,10,0.97); backdrop-filter: blur(20px);
  border-top: 1px solid var(--glass-border); padding: 8px 0 12px;
}
.bottom-nav-inner { display: flex; justify-content: space-around; align-items: center; }
.bn-item { display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 6px 16px; color: var(--text-dim); font-size: 0.65rem; font-weight: 600; letter-spacing: 0.05em; transition: all var(--transition); }
.bn-item i { font-size: 1.1rem; }
.bn-item.active, .bn-item:hover { color: var(--cyan); }

/* ===== NOTIFICATION SYSTEM ===== */
.notif-container { position: fixed; top: 80px; right: 20px; z-index: 9998; display: flex; flex-direction: column; gap: 8px; }
.notif {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 18px; border-radius: 10px;
  background: rgba(7,7,26,0.97); backdrop-filter: blur(20px);
  border: 1px solid; font-size: 0.85rem; font-weight: 600;
  animation: fadeSlideDown 0.3s ease; box-shadow: 0 8px 24px rgba(0,0,0,0.4);
  min-width: 220px;
}
.notif.success { border-color: var(--green);  color: var(--green);  box-shadow: 0 0 20px rgba(0,255,136,0.2); }
.notif.error   { border-color: var(--pink);   color: var(--pink);   box-shadow: 0 0 20px rgba(255,61,189,0.2); }
.notif.loading { border-color: var(--cyan);   color: var(--cyan);   box-shadow: 0 0 20px rgba(0,245,255,0.2); }
.notif.out     { opacity: 0; transition: opacity 0.4s; }

/* ===== SCROLL REVEAL ANIMATIONS ===== */
.reveal, .reveal-left, .reveal-right { opacity: 0; transition: opacity 0.8s ease, transform 0.8s ease; }
.reveal       { transform: translateY(30px); }
.reveal-left  { transform: translateX(-40px); }
.reveal-right { transform: translateX(40px); }
.reveal.visible, .reveal-left.visible, .reveal-right.visible { opacity: 1; transform: none; }

/* ===== ANIMATION DELAYS ===== */
.anim-delay-1 { animation-delay: 0.1s; }
.anim-delay-2 { animation-delay: 0.2s; }
.anim-delay-3 { animation-delay: 0.3s; }
.anim-delay-4 { animation-delay: 0.4s; }
.anim-delay-5 { animation-delay: 0.5s; }
