/* ===== LOGO PATHS - CHANGE YOUR LOGO FILES HERE ===== */
/* Update these paths to point to your actual logo files:
   - Navigation logo: assets/nav-logo.png
   - Hero logo: assets/hero-logo.png  
   - Footer logo: assets/footer-logo.png
*/

/* ===== HERO LOGO ANIMATION CONTROLS - EASY CUSTOMIZATION ===== */
/* 
  HERO LOGO POSITIONING:
  - Size: Change --hero-logo-size (default: 350px desktop, 250px tablet, 180px mobile)
  - Distance from text: Adjust --hero-text-gap (default: -200px - DECREASE THIS TO BRING CLOSER)
  - Logo container spacing: Modify --hero-logo-mb for additional spacing if needed
  
  HERO LOGO SPACING QUICK ADJUSTMENTS:
  - For LESS space between logo and text: Decrease --hero-text-gap (try -250px, -300px, -350px)
  - For MORE space between logo and text: Increase --hero-text-gap (try -150px, -100px, -50px)
  - For negative spacing (overlap): Use negative values like -200px, -300px
  
  HERO LOGO GLITCH EFFECTS:
  - Glitch frequency: Change hero-logo-glitch animation duration (default: 8s for less frequent)
  - Glitch intensity: Modify translateX values in hero-logo-glitch keyframes
  - Glitch colors: Adjust filter hue-rotate values for color shifts
  - To disable glitch: Remove 'hero-logo-glitch 8s infinite' from .hero-logo animation
  
  HERO LOGO ANIMATION TIMING:
  - Float cycle speed: Change hero-logo-float duration (default: 6s)
  - Entrance speed: Change hero-logo-entrance duration (default: 2s)
  - Float height: Modify translateY values in keyframes (default: -15px to -20px)
  - Scale effects: Adjust scale values in keyframes (default: 1.01 to 1.03)
  
  ADVANCED CUSTOMIZATION:
  - To disable floating: Remove 'hero-logo-float 6s ease-in-out infinite' from .hero-logo animation
  - To make glitch more frequent: Reduce hero-logo-glitch duration (try 3s or 5s)
  - To change entrance blur: Modify filter blur values in hero-logo-entrance
*/

/* ===== COLOR MANAGEMENT - EDIT COLORS HERE ===== */
:root {
  /* Primary Brand Colors */
  --primary-color: #00fff2;      /* Teal - Main brand color */
  --accent-color: #ffC000;       /* Orange - Accent color */
  --background-color: #000000;   /* Dark background */
  --text-primary: #ffffff;       /* Main text color */
  --text-secondary: #cccccc;     /* Secondary text color */
  --text-muted: #666666;         /* Muted text color */

  /* UI Colors */
  --glass-bg: rgba(255, 255, 255, 0.03);      /* Glass morphism background */
  --glass-border: rgba(255, 255, 255, 0.1);   /* Glass morphism border */
  --overlay-dark: rgba(10, 10, 10, 0.8);      /* Dark overlay */
  --overlay-darker: rgba(10, 10, 10, 0.95);   /* Darker overlay */

  /* Animation Colors */
  --glow-primary: rgba(0, 255, 242, 0.5);     /* Primary glow effect */
  --glow-accent: rgba(255, 192, 0, 0.5);      /* Accent glow effect */
  --particle-primary: rgba(0, 255, 242, 0.03);
  --particle-accent: rgba(255, 192, 0, 0.03);

  /* NAV + LOGO (single source of truth) */
  --nav-height: 64px;          /* bar thickness (56—80 typical) */
  --logo-height: 48px;         /* visual logo size */
  --logo-mt: 8px;              /* top margin */
  --logo-mb: 4px;              /* bottom margin */
  --logo-ml: 8px;              /* left margin */
  --logo-mr: 16px;             /* space before nav links */

  /* Hero Logo Variables */
  --hero-logo-size: 350px;     /* Hero logo size */
  --hero-logo-mb: 40px;        /* Hero logo bottom margin */
  --hero-text-gap: -200px;     /* Distance between logo and text - ADJUST THIS FOR SPACING */

  /* Edge frame variables */
  --scroll-progress: 0;         /* 0 to 1, updated by JS */
  --edge-width: 3.5px;         /* Thinner edge */
  --edge-radius: 35px;
  --edge-inset: 10px;
  
  /* ===== ADJUSTABLE EDGE EFFECT SETTINGS ===== */
  /* SEGMENT LENGTH CONTROLS - Adjust these to change line length */
   --primary-start: 68%;         /* Primary segment start position (0-100%) */
  --primary-end: 82%;           /* Primary segment end position (0-100%) */
  --accent-start: 18%;          /* Accent segment start position (0-100%) */
  --accent-end: 32%;            /* Accent segment end position (0-100%) */
  
  
  /* GLOW INTENSITY CONTROLS - Increase these numbers for stronger glow */
  --glow-inner: 7px;           /* Inner glow size */
  --glow-mid: 30px;             /* Mid glow size */
  --glow-outer: 40px;           /* Outer glow size */
  --glow-opacity: 1.0;          /* Glow opacity (0.1 to 1.0) */
}

/* ===== CUSTOM FONTS - ADD YOUR FONT FILES HERE ===== */
@font-face {
  font-family: 'sabresharklaser';
  src: url('assets/fonts/sabresharklaser.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

/* ===== GLOBAL RESET & BASE ===== */
* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Rajdhani', sans-serif;
  background: var(--background-color);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  position: relative;
}

/* ===== ANIMATED BACKGROUND ELEMENTS ===== */
.grid-bg {
  position: fixed; top: 0; left: 0; width: 100%; height: 100%;
  background-image:
    radial-gradient(circle at 25% 25%, transparent 2%, var(--particle-primary) 2%, var(--particle-primary) 3%, transparent 3%),
    radial-gradient(circle at 75% 75%, transparent 2%, var(--particle-accent) 2%, var(--particle-accent) 3%, transparent 3%);
  background-size: 80px 80px;
  animation: grid-move 30s linear infinite;
  z-index: -2;
}
@keyframes grid-move { 0% { transform: translate(0,0); } 100% { transform: translate(80px,80px); } }

/* ===== SHAPES CONTAINER WITH MOBILE CONTAINMENT ===== */
.shapes-container { 
  position: fixed; 
  width: 100%; 
  height: 100%; 
  pointer-events: none; 
  z-index: -1;
  /* Mobile containment fixes */
  max-width: 100vw;
  overflow: clip;
  contain: layout paint;
}

.shape { 
  position: absolute; 
  opacity: 0.15;
  /* Mobile containment for individual shapes */
  will-change: transform;
}

.shape-circle { 
  width: 300px; 
  height: 300px; 
  border: 2px solid var(--primary-color); 
  border-radius: 50%; 
  top: 10%; 
  left: 10%; 
  animation: float-rotate 20s ease-in-out infinite;
}

.shape-triangle { 
  width: 0; 
  height: 0; 
  border-left: 100px solid transparent; 
  border-right: 100px solid transparent; 
  border-bottom: 173px solid var(--glow-accent); 
  top: 60%; 
  right: 15%; 
  animation: float-rotate 25s ease-in-out infinite reverse;
}

.shape-square { 
  width: 100px; 
  height: 100px; 
  background: rgba(255,192,0,0.1); 
  border: 2px solid var(--accent-color); 
  top: 75%; 
  left: 25%; 
  animation: float-rotate 22s ease-in-out infinite; 
}

.shape-hexagon { 
  width: 120px; 
  height: 120px; 
  background: rgba(0,255,242,0.1); 
  clip-path: polygon(30% 0%,70% 0%,100% 30%,100% 70%,70% 100%,30% 100%,0% 70%,0% 30%); 
  top: 30%; 
  right: 30%; 
  animation: float-rotate 18s ease-in-out infinite;
}

@keyframes float-rotate {
  0%,100% { transform: translateY(0) rotate(0) scale(1); }
  25% { transform: translateY(-30px) rotate(90deg) scale(1.1); }
  50% { transform: translateY(20px) rotate(180deg) scale(0.9); }
  75% { transform: translateY(-10px) rotate(270deg) scale(1.05); }
}

/* REMOVED: Gradient overlay that was scroll-based */

/* Scanlines */
.scanlines {
  position: fixed; inset: 0; pointer-events: none;
  background: linear-gradient(transparent 50%, rgba(13,209,194,0.01) 50%);
  background-size: 100% 4px; animation: scanlines 8s linear infinite; z-index: 2;
}
@keyframes scanlines { 0% { transform: translateY(0); } 100% { transform: translateY(10px); } }

/* Particles */
.particle { position: fixed; pointer-events: none; opacity: 0; z-index: 1; }
.particle::before {
  content: ''; position: absolute; width: 2px; height: 2px; background: var(--primary-color);
  box-shadow: 0 0 10px var(--primary-color), 0 0 20px var(--primary-color); animation: float-up 15s linear infinite;
}
@keyframes float-up {
  0%   { transform: translateY(100vh) rotate(0); opacity: 0; }
  10%  { opacity: 1; }
  90%  { opacity: 1; }
  100% { transform: translateY(-100vh) rotate(720deg); opacity: 0; }
}

/* ===== WORKING EDGE FRAME WITH VISIBLE LINES + GLOW ===== */
.edge-frame {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
}

/* PRIMARY GLOWING LINE - VISIBLE + GLOWING */
.edge-frame::before {
  content: "";
  position: absolute;
  inset: calc(var(--edge-inset) + var(--edge-width));
  border: calc(var(--edge-width) * 2) solid transparent;
  border-radius: var(--edge-radius);
  
  /* PRIMARY SEGMENT - SOLID VISIBLE COLOR */
  border-image: 
    conic-gradient(
      from calc(0deg + var(--scroll-progress) * 360deg),
      transparent 0%,
      transparent var(--primary-start),
      var(--primary-color) var(--primary-start),
      var(--primary-color) var(--primary-end),
      transparent var(--primary-end),
      transparent 100%
    ) 1;

  /* GLOW EFFECTS */
  filter: 
    drop-shadow(0 0 var(--glow-inner) var(--primary-color))
    drop-shadow(0 0 var(--glow-outer) rgba(0, 255, 242, 0.6));
}

/* ACCENT GLOWING LINE - VISIBLE + GLOWING */
.edge-frame::after {
  content: "";
  position: absolute;
  inset: calc(var(--edge-inset) + var(--edge-width));
  border: calc(var(--edge-width) * 2) solid transparent;
  border-radius: var(--edge-radius);
  
  /* ACCENT SEGMENT - SOLID VISIBLE COLOR */
  border-image: 
    conic-gradient(
      from calc(0deg + var(--scroll-progress) * 360deg),
      transparent 0%,
      transparent var(--accent-start),
      var(--accent-color) var(--accent-start),
      var(--accent-color) var(--accent-end),
      transparent var(--accent-end),
      transparent 100%
    ) 1;

  /* GLOW EFFECTS */
  filter: 
    drop-shadow(0 0 var(--glow-inner) var(--accent-color))
    drop-shadow(0 0 var(--glow-outer) rgba(255, 192, 0, 0.6));
}

/*
=== HOW TO ADJUST THE EFFECTS ===

MAKING LINES LONGER/SHORTER:
- --primary-start: 60%; --primary-end: 90%; (makes longer primary line)
- --accent-start: 10%; --accent-end: 40%; (makes longer accent line)

MAKING GLOW STRONGER:
- Increase --glow-inner for tight glow (try 20px, 30px, 50px)
- Increase --glow-outer for wide glow (try 80px, 120px, 200px)

MAKING LINES THICKER/THINNER:
- Change --edge-width in the CSS variables (try 4px, 8px, 12px)
*/

/* Removed center glow - keeping only edge-localized effects */

/* Remove all center-filling effects */

/* ===== NAVIGATION (CLEAN, SINGLE DEFINITION) ===== */
#navbar {
  position: fixed; top: 0; width: 100%;
  background: var(--overlay-dark); backdrop-filter: blur(10px);
  z-index: 1000; transition: all 0.3s ease;
  border-bottom: 1px solid rgba(13, 209, 194, 0.1);
  height: var(--nav-height);
}
#navbar.scrolled { background: var(--overlay-darker); /* Removed glow effect */ }

.nav-container {
  max-width: 1200px; margin: 0 auto;
  display: flex; justify-content: space-between; align-items: center;
  height: var(--nav-height);
  padding: 0 2rem;
}

.logo-link { display: flex; align-items: center; text-decoration: none; gap: 10px; height: 100%; }

/* —— The only nav logo sizing rule you need —— */
.logo-link > img {
  height: var(--logo-height);
  width: auto;
  display: block;
  object-fit: contain;
  margin: var(--logo-mt) var(--logo-mr) var(--logo-mb) var(--logo-ml);
}

/* If you ever use an inline SVG instead of PNG */
.logo-link > svg { height: var(--logo-height); width: auto; display: block; margin: var(--logo-mt) var(--logo-mr) var(--logo-mb) var(--logo-ml); }

/* Optional logo text (not used in your HTML) */
.logo-text {
  font-family: 'sabresharklaser', 'Orbitron', monospace;
  font-size: 24px; font-weight: 900;
  background: linear-gradient(45deg, var(--primary-color), var(--accent-color));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  animation: glow 2s ease-in-out infinite; text-shadow: 0 0 30px var(--glow-primary);
}
@keyframes glow { 0%,100% { filter: brightness(1); text-shadow: 0 0 30px var(--glow-primary); } 50% { filter: brightness(1.5); text-shadow: 0 0 40px var(--glow-primary); } }

/* Nav links */
.nav-links { display: flex; list-style: none; gap: 2rem; }
.nav-link {
  color: var(--text-primary); text-decoration: none; font-weight: 500; transition: all 0.3s ease;
  position: relative; padding: 8px 16px; font-family: 'Orbitron', monospace; font-size: 14px;
  text-transform: uppercase; letter-spacing: 1px; opacity: 0.7; white-space: nowrap;
}
.nav-link.active { opacity: 1; color: var(--primary-color); }
.nav-link::before { content: ''; position: absolute; inset: 0; border: 1px solid transparent; transition: all 0.3s ease; }
.nav-link:hover::before, .nav-link.active::before { border-color: var(--primary-color); box-shadow: inset 0 0 10px var(--glow-primary); }
.nav-link::after { content: ''; position: absolute; bottom: 0; left: 0; width: 0; height: 2px; background: linear-gradient(90deg, var(--primary-color), var(--accent-color)); transition: width 0.3s ease; box-shadow: 0 0 10px var(--glow-primary); }
.nav-link:hover::after, .nav-link.active::after { width: 100%; }

.menu-toggle { display: none; flex-direction: column; cursor: pointer; gap: 4px; }
.menu-toggle span { width: 25px; height: 2px; background: var(--primary-color); transition: all 0.3s ease; }
.menu-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.menu-toggle.active span:nth-child(2) { opacity: 0; }
.menu-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* ===== HERO SECTION ===== */
.hero {
  min-height: 100vh; display: flex; flex-direction: column; justify-content: center; align-items: center;
  position: relative; text-align: center; padding: 80px 2rem 20px; width: 100%;
}

/* ===== HERO LOGO - NEW ADDITION ===== */
.hero-logo-container {
  position: relative;
  z-index: 3;
  margin-bottom: var(--hero-logo-mb);
  animation: hero-logo-entrance 2s ease-out;
}

.hero-logo {
  height: var(--hero-logo-size);
  width: auto;
  display: block;
  object-fit: contain;
  animation: hero-logo-float 6s ease-in-out infinite, hero-logo-glitch 8s infinite;
  transition: all 0.3s ease;
}

/* Hero logo animations */
@keyframes hero-logo-entrance {
  0% { 
    opacity: 0; 
    transform: translateY(-50px) scale(0.8); 
    filter: blur(10px); 
  }
  50% { 
    opacity: 0.7; 
    transform: translateY(-10px) scale(1.05); 
  }
  100% { 
    opacity: 1; 
    transform: translateY(0) scale(1); 
    filter: blur(0px); 
  }
}

@keyframes hero-logo-float {
  0%, 100% { 
    transform: translateY(0) scale(1); 
  }
  25% { 
    transform: translateY(-15px) scale(1.02); 
  }
  50% { 
    transform: translateY(-8px) scale(1.01); 
  }
  75% { 
    transform: translateY(-20px) scale(1.03); 
  }
}

/* Hero logo glitch effect - less frequent than text */
@keyframes hero-logo-glitch {
  0%, 90%, 100% { 
    transform: translateX(0) translateY(0);
    filter: hue-rotate(0deg);
  }
  91% { 
    transform: translateX(-2px) translateY(1px);
    filter: hue-rotate(90deg);
  }
  92% { 
    transform: translateX(2px) translateY(-1px);
    filter: hue-rotate(180deg);
  }
  93% { 
    transform: translateX(-1px) translateY(2px);
    filter: hue-rotate(270deg);
  }
  94% { 
    transform: translateX(1px) translateY(-2px);
    filter: hue-rotate(0deg);
  }
  95% { 
    transform: translateX(0) translateY(0);
    filter: hue-rotate(0deg);
  }
}

/* Hover effect for hero logo - no glow */
.hero-logo:hover {
  transform: scale(1.05);
  filter: hue-rotate(30deg);
}

.hero-content { 
  position: relative; z-index: 2; max-width: 1200px; animation: fade-in-up 1s ease-out; flex: 1; display: flex; flex-direction: column; justify-content: center; align-items: center; width: 100%; text-align: center;
  margin-top: var(--hero-text-gap);
}
.text-rotator { position: relative; min-height: 200px; margin-bottom: 20px; display: flex; align-items: center; justify-content: center; width: 100%; text-align: center; overflow: visible; }
.text-set { position: absolute; width: 100%; opacity: 0; display: none; text-align: center; left: 50%; top: 50%; transform: translate(-50%, -50%); min-width: max-content; }
.text-set.active { opacity: 1; display: block; }

.glitch-text {
  font-family: 'Orbitron', monospace; font-size: clamp(2.5rem, 6vw, 4rem); font-weight: 900; margin-bottom: 1rem;
  position: relative; text-transform: uppercase; letter-spacing: 0.1em; text-shadow: 0 0 20px var(--glow-primary);
  color: var(--text-primary); white-space: normal; /* Allow normal wrapping behavior */ overflow: visible;
  width: 100%; display: block;
}

/* REMOVED .word class definition */

.glitch-text::before, .glitch-text::after { 
  content: attr(data-text);
  position: absolute;
  inset: 0;
  width: 100%;
  overflow: visible; /* Allow glow to be visible */
  white-space: nowrap; /* Prevent wrapping on desktop */
  font-family: inherit; /* Ensure same font family */
  font-size: inherit; /* Ensure same font size */
  font-weight: inherit; /* Ensure same font weight */
  line-height: inherit; /* Ensure same line height */
  letter-spacing: inherit; /* Ensure same letter spacing */
  text-transform: inherit; /* Ensure same text transform */
  text-align: inherit; /* Ensure same text alignment */
}
.glitch-text::before { 
  animation: glitch-1 0.5s infinite; 
  color: var(--primary-color); 
  z-index: -1; 
  text-shadow: -2px 0 var(--primary-color);
  transform: translateZ(0); /* Force hardware acceleration and pixel alignment */
  backface-visibility: hidden; /* Prevent sub-pixel rendering issues */
}
.glitch-text::after { 
  animation: glitch-2 0.5s infinite; 
  color: var(--accent-color);  
  z-index: -1; 
  text-shadow: 2px 0 var(--accent-color);
  transform: translateZ(0); /* Force hardware acceleration and pixel alignment */
  backface-visibility: hidden; /* Prevent sub-pixel rendering issues */
}

/* ===== MOBILE HERO TEXT FIXES ===== */
@media (max-width: 768px) {
  /* Fix horizontal overflow first */
  html, body {
    max-width: 100vw;
    overflow-x: hidden;
  }
  
  /* Strengthen shape containment */
  .shapes-container {
    max-width: 100vw;
    overflow: hidden;
    contain: strict;
    position: fixed;
    inset: 0;
  }
  
  /* Ensure shapes stay contained with stronger positioning */
  .shape {
    opacity: 0.08;
    transform-origin: center center;
    position: absolute;
    max-width: 80px; /* Limit max size */
    max-height: 80px;
  }
  
  .shape-circle {
    width: 150px;
    height: 150px;
    max-width: 150px;
    max-height: 150px;
    left: 10%;
    top: 10%;
    transform: scale(0.5);
  }
  
  .shape-triangle {
    transform: scale(0.4);
    right: 15%;
    top: 60%;
    max-width: 60px;
    max-height: 60px;
  }
  
  .shape-square {
    width: 60px;
    height: 60px;
    max-width: 60px;
    max-height: 60px;
    left: 25%;
    top: 75%;
    transform: scale(0.5);
  }
  
  .shape-hexagon {
    width: 80px;
    height: 80px;
    max-width: 80px;
    max-height: 80px;
    right: 30%;
    top: 30%;
    transform: scale(0.5);
  }
  
  /* Fix hero text container to prevent glow clipping */
  .hero {
    padding: 100px 1rem 120px; /* Reduced outer padding */
    max-width: 100vw;
    overflow: visible;
  }
  
  .hero-content {
    max-width: calc(100vw - 2rem); /* Narrower safe container */
    margin-left: auto;
    margin-right: auto;
    padding: 0;
  }
  
  .text-rotator {
    max-width: calc(100vw - 2rem); /* Narrower safe container */
    margin: 0 auto;
    padding: 0;
    overflow: visible;
  }
  
  .text-set {
    max-width: calc(100vw - 2rem); /* Narrower safe container */
    margin: 0 auto;
    position: relative;
    transform: none;
    left: auto;
    top: auto;
    padding: 0;
  }
  
  .glitch-text {
    /* Critical: Allow proper wrapping but prevent mid-word breaks */
    white-space: normal;
    word-break: normal;
    overflow-wrap: anywhere;
    word-wrap: normal;
    hyphens: none;
    text-wrap: wrap;
    
    /* Much narrower container to force wrapping */
    max-width: calc(100vw - 3rem);
    width: 100%;
    margin: 0 auto;
    padding: 0.5rem 1rem;
    box-sizing: border-box;
    
    /* Layout and sizing - smaller font to ensure fitting */
    line-height: 1.2;
    font-size: clamp(1.2rem, 3vw, 1.8rem);
    text-align: center;
    display: block;
    
    /* Simple white glow with contained spread */
    color: #ffffff;
    text-shadow: 
      0 0 15px rgba(255, 255, 255, 0.9), 
      0 0 30px rgba(255, 255, 255, 0.5),
      0 0 45px rgba(255, 255, 255, 0.2);
    animation: mobileTextGlow 3s ease-in-out infinite;
    
    /* Typography adjustments for better wrapping */
    letter-spacing: 0.01em;
    word-spacing: 0.15em;
  }

  /* Apply same narrow wrapping rules to subtitle */
  .subtitle {
    /* Critical: Force word-only wrapping - same as headline */
    white-space: normal;
    word-break: normal;
    overflow-wrap: anywhere;
    word-wrap: normal;
    hyphens: none;
    
    /* Much narrower container to match headline */
    max-width: calc(100vw - 3rem);
    width: 100%;
    margin: 0 auto;
    padding: 0.5rem 1rem;
    box-sizing: border-box;
    
    /* Typography consistency */
    text-align: center;
    display: block;
    line-height: 1.3;
    letter-spacing: 0.01em;
    word-spacing: 0.15em;
    
    /* Preserve existing subtitle styling */
    font-size: clamp(1rem, 2.5vw, 1.3rem);
    color: var(--text-secondary);
    font-weight: 300;
    text-shadow: 0 0 10px rgba(255,255,255,0.3);
  }

  /* Completely disable glitch effects on mobile */
  .glitch-text::before, 
  .glitch-text::after {
    display: none !important;
  }

  /* Remove character animation on mobile */
  .char {
    display: inline;
    animation: none;
    white-space: pre-wrap;
    word-break: keep-all;
  }
}

/* Mobile text glow animation */
@keyframes mobileTextGlow {
  0%, 100% { 
    opacity: 1; 
    text-shadow: 
      0 0 20px rgba(255, 255, 255, 0.8), 
      0 0 40px rgba(255, 255, 255, 0.4),
      0 0 60px rgba(255, 255, 255, 0.2);
  }
  50% { 
    opacity: 0.9; 
    text-shadow: 
      0 0 30px rgba(255, 255, 255, 1), 
      0 0 60px rgba(255, 255, 255, 0.6),
      0 0 90px rgba(255, 255, 255, 0.3);
  }
}

@keyframes glitch-1 {
  0%,100% { clip-path: inset(0 0 0 0); transform: translate3d(0, 0, 0); }
  20% { clip-path: inset(33% 0 33% 0); transform: translate3d(-2px, 0, 0); }
  40% { clip-path: inset(66% 0 0 0); transform: translate3d(2px, 0, 0); }
  60% { clip-path: inset(0 0 66% 0); transform: translate3d(1px, 0, 0); }
  80% { clip-path: inset(25% 0 50% 0); transform: translate3d(-1px, 0, 0); }
}
@keyframes glitch-2 {
  0%,100% { clip-path: inset(0 0 0 0); transform: translate3d(0, 0, 0); }
  20% { clip-path: inset(50% 0 25% 0); transform: translate3d(2px, 0, 0); }
  40% { clip-path: inset(0 0 75% 0); transform: translate3d(-2px, 0, 0); }
  60% { clip-path: inset(75% 0 0 0); transform: translate3d(-1px, 0, 0); }
  80% { clip-path: inset(40% 0 40% 0); transform: translate3d(1px, 0, 0); }
}

.char { display: inline-block; opacity: 0; transform: translateY(50px); animation: charFlyIn 0.5s ease-out forwards; }
@keyframes charFlyIn { to { opacity: 1; transform: translateY(0); } }
.char.out { animation: charFlyOut 0.3s ease-in forwards; }
@keyframes charFlyOut { to { opacity: 0; transform: translateY(-30px) rotateX(90deg); } }

.subtitle { font-size: clamp(1.2rem, 3vw, 1.5rem); color: var(--text-secondary); font-weight: 300; opacity: 0; text-shadow: 0 0 10px rgba(255,255,255,0.3); }
.subtitle.visible { animation: subtitleFade 0.8s ease-out 0.5s forwards; }
@keyframes subtitleFade { to { opacity: 0.6; } }
@keyframes fade-in-up { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }

/* ===== CTA ===== */
.cta-container {
  position: absolute;
  bottom: 90px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
  z-index: 100;
}

.cta-button {
  padding: 1rem 2rem;
  text-decoration: none;
  border-radius: 8px;
  font-weight: 600;
  font-size: 1.1rem;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  display: inline-block;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-family: 'Orbitron', monospace;
  border: none;
  cursor: pointer;
}

/* Primary CTA (as you last approved: solid + pulse + transparent hover) */
.cta-primary {
  background: var(--primary-color);
  color: var(--background-color);
  animation: pulse 2s infinite;
  box-shadow: 0 0 30px var(--glow-primary);
}
.cta-primary:hover {
  background: rgba(0, 255, 242, 0.15);
  color: var(--primary-color);
  transform: translateY(-2px);
  box-shadow: 0 0 40px var(--glow-primary);
}
@keyframes pulse {
  0%,100% { transform: scale(1); box-shadow: 0 0 30px var(--glow-primary); }
  50%     { transform: scale(1.05); box-shadow: 0 0 40px var(--glow-primary); }
}

/* Secondary CTA */
.cta-secondary {
  background: transparent;
  color: var(--accent-color);
  border: 2px solid var(--accent-color);
  box-shadow: inset 0 0 20px var(--glow-accent);
}
.cta-button::before {
  content: '';
  position: absolute; top: 50%; left: 50%; width: 0; height: 0;
  background: rgba(255,255,255,0.2); border-radius: 50%;
  transform: translate(-50%, -50%); transition: width 0.6s, height 0.6s;
}
.cta-button:hover::before { width: 300px; height: 300px; }
.cta-secondary:hover {
  background: var(--glow-accent); color: white; transform: translateY(-2px);
  box-shadow: 0 10px 40px var(--glow-accent), inset 0 0 30px var(--glow-accent);
  border-color: var(--text-primary);
}

/* ===== SECTIONS ===== */
section {
  padding: 5rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
}

.section-title {
  font-family: 'Orbitron', monospace;
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 700;
  text-align: center;
  margin-bottom: 3rem;
  background: linear-gradient(45deg, var(--text-primary), var(--primary-color));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-transform: uppercase;
}

/* ===== FEATURES SECTION ===== */
.features-container { display: grid; grid-template-columns: 300px 1fr; gap: 40px; align-items: start; }
.feature-tabs { background: var(--glass-bg); border: 1px solid rgba(13,209,194,0.2); border-radius: 10px; padding: 20px; backdrop-filter: blur(10px); }
.tab-item { padding: 15px 20px; margin-bottom: 10px; cursor: pointer; border: 1px solid transparent; border-radius: 5px; transition: all 0.3s ease; font-weight: 500; display: flex; align-items: center; gap: 15px; font-size: 1.1rem; }
.tab-item:hover { background: rgba(13,209,194,0.1); border-color: rgba(13,209,194,0.3); }
.tab-item.active { background: linear-gradient(45deg, rgba(13,209,194,0.2), rgba(255,94,0,0.2)); border-color: var(--primary-color); box-shadow: 0 0 20px var(--glow-primary); }
.tab-icon { 
  font-size: 0.9rem; 
  font-family: 'Orbitron', monospace;
  font-weight: 700;
  color: var(--accent-color);
  background: var(--accent-color);
  color: var(--background-color);
  padding: 8px 12px;
  border-radius: 4px;
  text-shadow: none;
  letter-spacing: 1px;
  min-width: 50px;
  text-align: center;
  display: inline-block;
}
.feature-content { background: var(--glass-bg); border: 1px solid rgba(13,209,194,0.2); border-radius: 10px; padding: 40px; backdrop-filter: blur(10px); min-height: 400px; position: relative; }
.content-panel { display: none; animation: fadeIn 0.5s ease; }
.content-panel.active { display: block; }
.content-panel h3 {
  font-family: 'Orbitron', monospace; font-size: 1.8rem; font-weight: 700; margin-bottom: 1rem;
  background: linear-gradient(45deg, var(--text-primary), var(--primary-color)); -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.content-panel p { font-size: 1.1rem; margin-bottom: 1.5rem; color: var(--text-secondary); line-height: 1.8; opacity: 0.8; }
.feature-list { list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1rem; margin-top: 20px; }
.feature-list li { padding: 0.5rem 0 0.5rem 1.5rem; color: var(--text-primary); position: relative; opacity: 0.8; }
.feature-list li::before { 
  content: '▶'; position: absolute; left: 0; color: var(--accent-color); font-size: 0.8rem; 
  text-shadow: 0 0 8px rgba(255, 192, 0, 0.6), 0 0 15px rgba(255, 192, 0, 0.3);
}

/* ===== ABOUT SECTION ===== */
.about-content { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; margin-bottom: 4rem; }
.about-text h2 {
  font-family: 'Orbitron', monospace; font-size: 2rem; font-weight: 700; margin-bottom: 1.5rem;
  background: linear-gradient(45deg, var(--text-primary), var(--primary-color)); -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.about-text p { font-size: 1.1rem; margin-bottom: 1rem; color: var(--text-secondary); line-height: 1.7; opacity: 0.8; }

.about-visual { display: flex; justify-content: center; align-items: center; position: relative; height: 400px; }
.about-graphic { width: 300px; height: 300px; position: relative; animation: float 6s ease-in-out infinite; }
.about-graphic::before, .about-graphic::after { content: ''; position: absolute; border: 2px solid var(--primary-color); border-radius: 10px; box-shadow: 0 0 30px var(--glow-primary); }
.about-graphic::before { width: 100%; height: 100%; animation: rotate 20s linear infinite; }
.about-graphic::after  { width: 80%; height: 80%; top: 10%; left: 10%; border-color: var(--accent-color); animation: rotate 15s linear infinite reverse; box-shadow: 0 0 30px var(--glow-accent); }
.about-graphic-alt { display: flex; gap: 1rem; align-items: center; width: 300px; height: 300px; position: relative; animation: float 6s ease-in-out infinite; justify-content: center; }
.hexagon { position: absolute; width: 100px; height: 100px; background: linear-gradient(45deg, var(--primary-color), var(--accent-color)); opacity: 0.3; clip-path: polygon(30% 0%, 70% 0%, 100% 30%, 100% 70%, 70% 100%, 30% 100%, 0% 70%, 0% 30%); }
.hexagon:nth-child(1) { width: 150px; height: 150px; animation: hexagon-rotate 8s linear infinite; }
.hexagon:nth-child(2) { width: 100px; height: 100px; animation: hexagon-rotate 12s linear infinite reverse; opacity: 0.5; }
.hexagon:nth-child(3) { width: 200px; height: 200px; animation: hexagon-rotate 15s linear infinite; opacity: 0.2; }
@keyframes hexagon-rotate { 0% { transform: rotate(0) scale(1); } 50% { transform: rotate(180deg) scale(1.1); } 100% { transform: rotate(360deg) scale(1); }
}
@keyframes float { 0%,100% { transform: translateY(0); box-shadow: 0 0 30px var(--glow-primary); } 50% { transform: translateY(-20px); box-shadow: 0 10px 40px var(--glow-primary); } }
@keyframes rotate { 0% { transform: rotate(0); } 100% { transform: rotate(360deg); } }

/* ===== CONTACT SECTION ===== */
.contact-container { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; max-width: 1000px; margin: 0 auto; }
.contact-form { background: var(--glass-bg); border: 1px solid rgba(13,209,194,0.2); border-radius: 10px; padding: 40px; backdrop-filter: blur(10px); }
.form-group { margin-bottom: 25px; }
.form-group label { display: block; margin-bottom: 10px; color: var(--primary-color); font-weight: 500; text-transform: uppercase; font-size: 0.9rem; letter-spacing: 1px; }
.form-group input, .form-group textarea {
  width: 100%; padding: 15px; background: rgba(255,255,255,0.05); border: 1px solid rgba(13,209,194,0.3);
  border-radius: 5px; color: var(--text-primary); font-family: 'Rajdhani', sans-serif; font-size: 1rem; transition: all 0.3s ease;
}
.form-group input:focus, .form-group textarea:focus { outline: none; border-color: var(--primary-color); box-shadow: 0 0 20px var(--glow-primary); background: rgba(255,255,255,0.08); }
.form-group textarea { height: 120px; resize: vertical; min-height: 120px; }
.submit-btn {
  width: 100%; padding: 15px; background: var(--primary-color); color: var(--background-color);
  border: none; border-radius: 5px; font-size: 1.1rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px; cursor: pointer; transition: all 0.3s ease; font-family: 'Orbitron', monospace;
  animation: pulse 2s infinite; box-shadow: 0 0 30px var(--glow-primary);
}
.submit-btn:hover { 
  background: rgba(0, 255, 242, 0.15); color: var(--primary-color); transform: translateY(-2px); 
  box-shadow: 0 0 40px var(--glow-primary); 
}

/* ===== CONTACT LINKS ===== */
.contact-link {
  color: var(--primary-color);
  text-decoration: underline;
  text-decoration-color: var(--accent-color);
  text-underline-offset: 3px;
  transition: all 0.3s ease;
  opacity: 0.9;
  font-weight: 500;
}
.contact-link:hover {
  color: var(--accent-color);
  text-shadow: 0 0 10px var(--glow-accent);
  text-decoration-color: var(--primary-color);
  opacity: 1;
  transform: translateY(-1px);
}

.contact-info { padding: 40px; }
.contact-info h3 {
  font-family: 'Orbitron', monospace; font-size: 1.5rem; margin-bottom: 2rem;
  background: linear-gradient(45deg, var(--text-primary), var(--primary-color)); -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.info-item { display: flex; align-items: center; gap: 1rem; margin-bottom: 2rem; padding: 1rem; background: var(--glass-bg); border-radius: 8px; border: 1px solid var(--glass-border); }
.info-icon { 
  width: 50px; height: 50px; 
  background: var(--glass-bg); 
  border: 2px solid var(--accent-color); 
  border-radius: 50%; 
  display: flex; align-items: center; justify-content: center; 
  font-size: 0.8rem; 
  font-family: 'Orbitron', monospace;
  font-weight: 700;
  color: var(--accent-color);
  text-shadow: 0 0 10px var(--glow-accent);
  box-shadow: 0 0 15px rgba(255, 192, 0, 0.2);
  transition: all 0.3s ease;
  letter-spacing: 1px;
}
.info-icon:hover {
  background: var(--accent-color);
  color: var(--background-color);
  box-shadow: 0 0 25px rgba(255, 192, 0, 0.4);
  transform: scale(1.05);
}
.info-details h4 { font-weight: 600; margin-bottom: 0.25rem; color: var(--primary-color); }
.info-details p { color: var(--text-secondary); opacity: 0.8; }

/* ===== MODAL STYLES ===== */
.modal {
  display: none;
  position: fixed;
  z-index: 10000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(10px);
  justify-content: center;
  align-items: center;
}

.modal.show {
  display: flex;
}

.modal-content {
  background: var(--glass-bg);
  border: 1px solid rgba(13, 209, 194, 0.2);
  border-radius: 10px;
  backdrop-filter: blur(20px);
  padding: 40px;
  width: 90%;
  max-width: 800px;
  max-height: 80vh;
  overflow-y: auto;
  position: relative;
  animation: modalSlideIn 0.3s ease-out;
  margin: 0;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: scale(0.9) translateY(-50px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.modal.hide .modal-content {
  animation: modalSlideOut 0.3s ease-in;
}

@keyframes modalSlideOut {
  from {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
  to {
    opacity: 0;
    transform: scale(0.9) translateY(-50px);
  }
}

.modal-content h2 {
  font-family: 'Orbitron', monospace;
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 2rem;
  background: linear-gradient(45deg, var(--text-primary), var(--primary-color));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  text-align: center;
}

.modal-content h3 {
  font-family: 'Orbitron', monospace;
  font-size: 1.3rem;
  font-weight: 600;
  margin-top: 2rem;
  margin-bottom: 1rem;
  color: var(--primary-color);
}

.modal-content p {
  font-size: 1.1rem;
  line-height: 1.7;
  margin-bottom: 1rem;
  color: var(--text-secondary);
  opacity: 0.9;
}

.close {
  color: var(--text-muted);
  float: right;
  font-size: 28px;
  font-weight: bold;
  position: absolute;
  top: 20px;
  right: 30px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.close:hover,
.close:focus {
  color: var(--primary-color);
  text-shadow: 0 0 10px var(--glow-primary);
}

.modal-body {
  margin-top: 1rem;
}

/* ===== FOOTER ===== */
footer { background: rgba(0,0,0,0.8); padding: 2rem; border-top: 1px solid rgba(13,209,194,0.2); }
.footer-content { 
  max-width: 1200px; margin: 0 auto; 
  display: grid; 
  grid-template-columns: 1fr auto 1fr; 
  align-items: center; 
  gap: 2rem; 
}
.footer-logo { 
  grid-column: 2; 
  display: flex; 
  justify-content: center; 
}
.footer-logo-img { height: 60px; width: auto; opacity: 0.8; transition: opacity 0.3s ease; }
.footer-logo-img:hover { opacity: 1; }
.footer-right { 
  grid-column: 3; 
  display: flex; 
  flex-direction: column; 
  align-items: flex-end; 
  gap: 1rem; 
}
.footer-links { display: flex; gap: 2rem; flex-wrap: wrap; justify-content: flex-end; }
.footer-links a { color: var(--primary-color); text-decoration: none; transition: all 0.3s ease; font-weight: 500; cursor: pointer; }
.footer-links a:hover { color: var(--accent-color); text-shadow: 0 0 10px currentColor; }
.copyright { color: var(--text-muted); font-size: 0.9rem; opacity: 0.6; text-align: right; }

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .nav-links {
    display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--overlay-darker);
    flex-direction: column; padding: 2rem; border-top: 1px solid rgba(13,209,194,0.1);
  }
  .nav-links.active { display: flex; }
  .menu-toggle { display: none; } /* Disabled on mobile */
  
  /* Center logo on mobile */
  .nav-container {
    justify-content: center;
  }

  .features-container { grid-template-columns: 1fr; }
  .feature-tabs { display: block; padding: 20px; max-width: 100%; }
  .tab-item { width: 100%; margin-bottom: 10px; }

  .about-content { grid-template-columns: 1fr; text-align: center; }
  
  /* ===== MOBILE CONTACT FORM FIXES ===== */
  .contact-container { 
    grid-template-columns: 1fr; 
    gap: 2rem;
    max-width: 100%;
    margin: 0;
  }
  
  .contact-form { 
    padding: 20px; 
    max-width: 100%;
    width: 100%;
    box-sizing: border-box;
    margin: 0;
    border-radius: 10px;
  }
  
  .contact-form input,
  .contact-form textarea {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    font-size: 16px; /* Prevent zoom on iOS */
    padding: 12px;
    border-radius: 5px;
  }
  
  .contact-form textarea {
    min-height: 100px;
    resize: vertical;
  }
  
  .contact-form .form-group {
    margin-bottom: 1.5rem;
  }
  
  .contact-form .submit-btn {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    padding: 12px;
    font-size: 1rem;
  }
  
  .contact-info {
    padding: 20px;
  }

  .cta-container { flex-direction: column; align-items: center; }
  .cta-button { width: 100%; max-width: 300px; text-align: center; }

  .about-graphic { width: 200px; height: 200px; }

  /* Hero logo responsive sizing */
  :root {
    --hero-logo-size: 250px;
    --hero-text-gap: -120px; /* Moved up significantly for better centering */
  }

  /* Modal responsive */
  .modal-content {
    padding: 30px;
    width: 95%;
    max-height: 85vh;
  }

  /* Footer responsive layout */
  .footer-content { 
    grid-template-columns: 1fr; 
    text-align: center; 
    gap: 1.5rem; 
  }
  .footer-logo { 
    grid-column: 1; 
    order: 1; 
  }
  .footer-right { 
    grid-column: 1; 
    order: 2; 
    align-items: center; 
  }
  .footer-links { justify-content: center; }
  .copyright { text-align: center; }

  /* tighten the nav visually on tablet/phone */
  :root { --nav-height: 58px; --logo-height: 42px; --logo-mt: 6px; --logo-mb: 4px; --logo-ml: 8px; --logo-mr: 12px; }
}

@media (max-width: 480px) {
  .nav-container { padding: 0 1rem; }
  section { padding: 3rem 1rem; }
  .hero { 
    padding: 100px 1rem 120px; /* Maintain safe padding on small phones */
    min-height: 100vh;
  }

  /* Smaller hero logo on phones */
  :root {
    --hero-logo-size: 200px;
    --hero-text-gap: -200px; /* Reduced gap by ~50% for closer spacing */
  }

  /* Modal on mobile */
  .modal-content {
    padding: 20px;
    width: 95%;
    max-height: 90vh;
  }

  .modal-content h2 {
    font-size: 1.5rem;
  }

  /* a bit tighter on small phones */
  :root { --nav-height: 54px; --logo-height: 38px; --logo-mt: 6px; --logo-mb: 4px; --logo-ml: 6px; --logo-mr: 10px; }
  
  /* Ensure no horizontal overflow */
  * {
    max-width: 100%;
    box-sizing: border-box;
  }
  
  /* Extra mobile contact form safety */
  .contact-container {
    padding: 0 1rem;
    max-width: calc(100vw - 2rem);
    margin: 0 auto;
  }
  
  .contact-form {
    padding: 15px;
    max-width: 100%;
    width: 100%;
    box-sizing: border-box;
  }
  
  .contact-form input,
  .contact-form textarea {
    padding: 10px;
    font-size: 16px;
    max-width: 100%;
    width: 100%;
    box-sizing: border-box;
  }
  
  .contact-form .submit-btn {
    padding: 10px;
    font-size: 0.9rem;
    max-width: 100%;
    width: 100%;
    box-sizing: border-box;
  }
  
  /* Ensure edge frame doesn't interfere */
  .edge-frame {
    z-index: 2;
  }
  
  .hero-content {
    position: relative;
    z-index: 15;
  }
  
  .glitch-text {
    position: relative;
    z-index: 20;
  }
  
  /* Ensure CTA buttons don't overlap with edge frame */
  .cta-container {
    z-index: 12;
    bottom: 60px;
  }
}
