@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Fira+Code:wght@400;500&display=swap');

:root {
  /* Color Palette - Deep Space & Cyber Neon */
  --bg-color: #050505;
  --surface-color: rgba(20, 20, 25, 0.7);
  --surface-border: rgba(255, 255, 255, 0.08);
  
  --primary-glow: #00FF87; /* Emerald/Neon Green */
  --secondary-glow: #00BFA5; /* Deep Mint Green */
  --text-main: #f8f9fa;
  --text-muted: #a0aab2;
  
  --glass-blur: blur(16px);
  --glass-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);

  --font-sans: 'Inter', sans-serif;
  --font-mono: 'Fira Code', monospace;
}

html {
  max-width: 100vw;
}

body {
  background-color: var(--bg-color);
  color: var(--text-main);
  font-family: var(--font-sans);
  overflow-x: hidden;
  max-width: 100vw;
  margin: 0;
  /* Subdued grid background */
  background-image: 
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 50px 50px;
}

/* ==========================================================================
   Typography & Glow Effects
   ========================================================================== */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  letter-spacing: -0.03em;
}

.text-gradient {
  background: linear-gradient(90deg, var(--primary-glow), var(--secondary-glow));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.glow-text {
  text-shadow: 0 0 20px rgba(0, 255, 135, 0.4);
}

/* ==========================================================================
   Glassmorphism UI
   ========================================================================== */
.glass-panel {
  background: var(--surface-color);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--surface-border);
  box-shadow: var(--glass-shadow);
  border-radius: 16px;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.glass-panel:hover {
  transform: translateY(-5px);
  border-color: rgba(0, 255, 135, 0.3);
  box-shadow: 0 10px 40px rgba(0, 255, 135, 0.15);
}

.premium-nav {
  background: rgba(5, 5, 5, 0.6) !important;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 50px;
  margin: 20px auto;
  max-width: 1100px;
  right: 0;
  left: 0;
  transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  padding: 10px 20px;
}

.premium-nav.navbar-shrink {
  margin-top: 10px;
  background: rgba(5, 5, 5, 0.9) !important;
  box-shadow: 0 5px 20px rgba(0, 255, 135, 0.15);
  max-width: 1000px;
  padding: 8px 20px;
}

/* Nav Link Hover Micro-animations */
.premium-nav .nav-link {
  position: relative;
  color: var(--text-main) !important;
  font-weight: 500;
  padding: 8px 16px !important;
  transition: color 0.3s ease;
}

.premium-nav .nav-link:hover {
  color: var(--primary-glow) !important;
}

.premium-nav .nav-link::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: 0;
  left: 50%;
  background-color: var(--primary-glow);
  transition: all 0.3s ease;
  transform: translateX(-50%);
  box-shadow: 0 0 10px var(--primary-glow);
}

.premium-nav .nav-link:hover::after,
.premium-nav .nav-link.active::after {
  width: 70%;
}

@media (max-width: 991.98px) {
    .premium-nav {
    border-radius: 16px;
    margin: 10px;
    max-width: calc(100% - 20px);
  }
  .premium-nav .navbar-collapse {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 15px;
    background: rgba(10, 10, 15, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--surface-border);
    border-radius: 16px;
    padding: 15px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    z-index: 1050;
  }
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn-cyber {
  background: transparent;
  color: var(--primary-glow);
  border: 1px solid var(--primary-glow);
  padding: 10px 24px;
  border-radius: 8px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  font-size: 0.85rem;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  text-decoration: none;
  display: inline-block;
}

.btn-cyber:hover {
  background: var(--primary-glow);
  color: #000;
  box-shadow: 0 0 20px rgba(0, 255, 135, 0.4);
}

.btn-cyber-purple {
  border-color: var(--secondary-glow);
  color: var(--secondary-glow);
}
.btn-cyber-purple:hover {
  background: var(--secondary-glow);
  color: #fff;
  box-shadow: 0 0 20px rgba(0, 191, 165, 0.4);
}

/* ==========================================================================
   Sections & Layout
   ========================================================================== */
.cyber-section {
  padding: 100px 0;
  position: relative;
}

.section-title {
  font-size: 2.5rem;
  margin-bottom: 3rem;
  position: relative;
  display: inline-block;
}
.section-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 0;
  width: 50%;
  height: 3px;
  background: linear-gradient(90deg, var(--primary-glow), transparent);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero-cyber {
  height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.hero-cyber::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(0,255,135,0.15) 0%, rgba(0,191,165,0.1) 40%, rgba(0,0,0,0) 70%);
  transform: translate(-50%, -50%);
  z-index: -1;
  pointer-events: none;
}

.hero-title {
  font-size: clamp(3rem, 6vw, 5.5rem);
  line-height: 1.1;
  margin-bottom: 1.5rem;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--text-muted);
  font-weight: 300;
  max-width: 600px;
}

/* ==========================================================================
   Terminal / Code Block
   ========================================================================== */
.terminal-window {
  background: #111;
  border-radius: 12px;
  border: 1px solid var(--surface-border);
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0,0,0,0.5);
}
.terminal-header {
  background: #1a1a1a;
  padding: 10px 15px;
  display: flex;
  gap: 8px;
  border-bottom: 1px solid #333;
}
.terminal-btn {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}
.tb-close { background: #ff5f56; }
.tb-min { background: #ffbd2e; }
.tb-max { background: #27c93f; }

.terminal-body {
  padding: 20px;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: #0f0;
  line-height: 1.6;
}

/* ==========================================================================
   Animations (AOS alternative)
   ========================================================================== */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}
.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* Nav Links overrides */
.navbar-dark .navbar-nav .nav-link {
  color: var(--text-main);
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.3s ease;
}
.navbar-dark .navbar-nav .nav-link:hover {
  color: var(--primary-glow);
}

/* Global Text Visibility Reset */
body, .glass-panel, .card-body, .table {
  color: #ffffff !important;
}
h1, h2, h3, h4, h5, h6, p, span, div, label, li, td, th {
  color: inherit;
}
.text-muted, .text-white-50 {
  color: #ced4da !important; /* Lighter gray for excellent contrast on dark backgrounds */
}
.text-gradient {
  color: transparent !important;
}

.premium-nav .nav-link::after {
  content: '';
  position: absolute;
  width: 0;
  height: 2px;
  bottom: 0;
  left: 50%;
  background-color: var(--primary-glow);
  transition: all 0.3s ease;
  transform: translateX(-50%);
  box-shadow: 0 0 10px var(--primary-glow);
}

.premium-nav .nav-link:hover::after,
.premium-nav .nav-link.active::after {
  width: 70%;
}

@media (max-width: 991.98px) {
    .premium-nav {
    border-radius: 16px;
    margin: 10px;
    max-width: calc(100% - 20px);
  }
  .premium-nav .navbar-collapse {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 15px;
    background: rgba(10, 10, 15, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--surface-border);
    border-radius: 16px;
    padding: 15px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    z-index: 1050;
  }
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn-cyber {
  background: transparent;
  color: var(--primary-glow);
  border: 1px solid var(--primary-glow);
  padding: 10px 24px;
  border-radius: 8px;
  font-weight: 600;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  font-size: 0.85rem;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  text-decoration: none;
  display: inline-block;
}

.btn-cyber:hover {
  background: var(--primary-glow);
  color: #000;
  box-shadow: 0 0 20px rgba(0, 255, 135, 0.4);
}

.btn-cyber-purple {
  border-color: var(--secondary-glow);
  color: var(--secondary-glow);
}
.btn-cyber-purple:hover {
  background: var(--secondary-glow);
  color: #fff;
  box-shadow: 0 0 20px rgba(0, 191, 165, 0.4);
}

/* ==========================================================================
   Sections & Layout
   ========================================================================== */
.cyber-section {
  padding: 100px 0;
  position: relative;
}

.section-title {
  font-size: 2.5rem;
  margin-bottom: 3rem;
  position: relative;
  display: inline-block;
}
.section-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 0;
  width: 50%;
  height: 3px;
  background: linear-gradient(90deg, var(--primary-glow), transparent);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero-cyber {
  height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.hero-cyber::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(0,255,135,0.15) 0%, rgba(0,191,165,0.1) 40%, rgba(0,0,0,0) 70%);
  transform: translate(-50%, -50%);
  z-index: -1;
  pointer-events: none;
}

.hero-title {
  font-size: clamp(3rem, 6vw, 5.5rem);
  line-height: 1.1;
  margin-bottom: 1.5rem;
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--text-muted);
  font-weight: 300;
  max-width: 600px;
}

/* ==========================================================================
   Terminal / Code Block
   ========================================================================== */
.terminal-window {
  background: #111;
  border-radius: 12px;
  border: 1px solid var(--surface-border);
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0,0,0,0.5);
}
.terminal-header {
  background: #1a1a1a;
  padding: 10px 15px;
  display: flex;
  gap: 8px;
  border-bottom: 1px solid #333;
}
.terminal-btn {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}
.tb-close { background: #ff5f56; }
.tb-min { background: #ffbd2e; }
.tb-max { background: #27c93f; }

.terminal-body {
  padding: 20px;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: #0f0;
  line-height: 1.6;
}

/* ==========================================================================
   Animations (AOS alternative)
   ========================================================================== */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}
.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* Nav Links overrides */
.navbar-dark .navbar-nav .nav-link {
  color: var(--text-main);
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.3s ease;
}
.navbar-dark .navbar-nav .nav-link:hover {
  color: var(--primary-glow);
}

/* Global Text Visibility Reset */
body, .glass-panel, .card-body, .table {
  color: #ffffff !important;
}
h1, h2, h3, h4, h5, h6, p, span, div, label, li, td, th {
  color: inherit;
}
.text-muted, .text-white-50 {
  color: #ced4da !important; /* Lighter gray for excellent contrast on dark backgrounds */
}
.text-gradient {
  color: transparent !important;
}



/* ==========================================================================
   Responsive Typography for Small Screens
   ========================================================================== */
@media (max-width: 768px) {
  .navbar-brand {
    font-size: 0.95rem !important;
  }
  
  /* Drastically reduce text sizes */
  .hero-title {
    font-size: clamp(1.4rem, 4vw, 1.8rem) !important;
  }
  .hero-subtitle {
    font-size: 0.75rem !important;
  }
  .section-title {
    font-size: 1.3rem !important;
  }
  body, p, .text-muted, .text-white-50 {
    font-size: 0.8rem !important;
  }
  h2 {
    font-size: 1.2rem !important;
  }
  h3 {
    font-size: 1.1rem !important;
  }
  h4 {
    font-size: 1rem !important;
  }
  h5 {
    font-size: 0.9rem !important;
  }
  .btn-cyber {
    font-size: 0.65rem !important;
    padding: 6px 12px !important;
  }
  .glass-panel {
    padding: 1rem !important;
  }
}



/* ==========================================================================
   Form Input Placeholders
   ========================================================================== */
::placeholder {
  color: #a0aab2 !important;
  opacity: 1 !important; /* Firefox requires this to override default opacity */
}
::-webkit-input-placeholder {
  color: #a0aab2 !important;
}
:-ms-input-placeholder {
  color: #a0aab2 !important;
}


/* ==========================================================================
   Ticker Banners for Small Screens (Double Direction)
   ========================================================================== */
.ticker-wrap, .ticker-wrap-reverse {
  width: 100%;
  overflow: hidden;
  background: rgba(10, 10, 15, 0.75);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border-bottom: 1px solid rgba(0, 255, 135, 0.2);
  box-shadow: 0 4px 15px rgba(0, 255, 135, 0.08);
  padding: 8px 0;
  z-index: 1000;
  position: relative;
}

.ticker-wrap {
  margin-top: 130px; /* Decalage - space between navigation bar and first banner */
  margin-bottom: 6px; /* Small space between the two banners */
}

.ticker-wrap-reverse {
  margin-bottom: 25px; /* Decalage - space below the second banner */
}

.ticker, .ticker-reverse {
  display: inline-flex;
  white-space: nowrap;
}

.ticker {
  animation: ticker-animation 30s linear infinite;
}

.ticker-reverse {
  animation: ticker-animation-reverse 30s linear infinite;
}

.ticker-wrap:hover .ticker,
.ticker-wrap-reverse:hover .ticker-reverse {
  animation-play-state: paused;
}

.ticker-item {
  display: inline-block;
  padding: 0 3rem;
  font-size: 0.8rem;
  color: var(--text-muted) !important;
  font-weight: 500;
  letter-spacing: 0.5px;
  text-decoration: none !important;
  transition: color 0.3s ease, text-shadow 0.3s ease;
}

.ticker-item:hover {
  color: #ffffff !important;
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

.text-primary-glow {
  color: var(--primary-glow) !important;
  text-shadow: 0 0 8px rgba(0, 255, 135, 0.4);
}

.text-secondary-glow {
  color: var(--secondary-glow) !important;
  text-shadow: 0 0 8px rgba(0, 191, 165, 0.4);
}

@keyframes ticker-animation {
  0% {
    transform: translate3d(100vw, 0, 0);
  }
  100% {
    transform: translate3d(-100%, 0, 0);
  }
}

@keyframes ticker-animation-reverse {
  0% {
    transform: translate3d(-100%, 0, 0);
  }
  100% {
    transform: translate3d(100vw, 0, 0);
  }
}

/* Adjust Hero Section on mobile to shift it upwards and give space for tickers */
@media (max-width: 991.98px) {
  .hero-cyber {
    align-items: flex-start !important;
    padding-top: 100px !important;
    min-height: 70vh !important;
    height: auto !important;
  }
}


/* ==========================================================================
   Back to Top Button
   ========================================================================== */
.back-to-top-btn {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: rgba(10, 10, 15, 0.8);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--primary-glow);
  color: var(--primary-glow);
  box-shadow: 0 0 15px rgba(0, 255, 135, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  cursor: pointer;
  z-index: 9999;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s ease, visibility 0.4s ease, transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
  transform: translateY(20px);
}

.back-to-top-btn.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top-btn:hover {
  background: var(--primary-glow);
  color: #000;
  box-shadow: 0 0 25px var(--primary-glow);
  transform: translateY(-5px) scale(1.05);
}



