/* ── NOVA TECHNOLOGY — Global Styles ── */
:root {
  --navy:      #081A39;
  --navy-mid:  #0d2550;
  --navy-light:#122d5e;
  --cyan:      #00C6D4;
  --cyan-dim:  rgba(0,198,212,0.12);
  --cyan-glow: rgba(0,198,212,0.5);
  --cyan-dark: #009aaa;
  --white:     #ffffff;
  --text-muted:rgba(255,255,255,0.5);
  --text-dim:  rgba(255,255,255,0.25);
  --radius:    10px;
  --transition:0.35s cubic-bezier(0.4,0,0.2,1);
}

*,*::before,*::after { margin:0; padding:0; box-sizing:border-box; }

html { scroll-behavior:smooth; font-size:16px; }

body {
  background: var(--navy);
  color: var(--white);
  font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
  overflow-x: hidden;
  line-height: 1.6;
}

/* ── Typography ── */
h1,h2,h3,h4 { line-height:1.15; font-weight:700; }
h1 { font-size: clamp(2.4rem, 6vw, 5.5rem); letter-spacing:-1px; }
h2 { font-size: clamp(1.8rem, 4vw, 3rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.4rem); }
p  { color: var(--text-muted); }

.accent { color: var(--cyan); }
.eyebrow {
  font-size: 0.72rem;
  letter-spacing: 4px;
  text-transform: uppercase;
  color: var(--cyan);
  margin-bottom: 0.8rem;
}
.body-text { max-width: 520px; font-size: 1.05rem; line-height:1.75; }

/* ── Container ── */
.container { max-width: 1200px; margin-inline: auto; padding-inline: 2rem; }

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.8rem 2rem;
  border-radius: 4px;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: all var(--transition);
  white-space: nowrap;
}
.btn-primary {
  background: var(--cyan);
  color: var(--navy);
}
.btn-primary:hover {
  background: #fff;
  box-shadow: 0 0 30px var(--cyan-glow);
  transform: translateY(-2px);
}
.btn-ghost {
  background: transparent;
  color: var(--cyan);
  border: 1px solid var(--cyan);
}
.btn-ghost:hover {
  background: var(--cyan-dim);
  box-shadow: 0 0 20px var(--cyan-glow);
  transform: translateY(-2px);
}
.btn-nav {
  background: var(--cyan);
  color: var(--navy);
  padding: 0.6rem 1.4rem;
  font-size: 0.78rem;
}
.btn-nav:hover { background:#fff; }

/* ── Navbar ── */
#navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: rgba(8,26,57,0.75);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(0,198,212,0.12);
  transition: background var(--transition);
}
#navbar.scrolled { background: rgba(8,26,57,0.97); }

.nav-inner {
  max-width: 1200px;
  margin-inline: auto;
  padding: 1rem 2rem;
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-logo {
  text-decoration: none;
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: 2px;
  flex-shrink: 0;
}
.nav-logo-img {
  height: 38px;
  width: auto;
  display: block;
  object-fit: contain;
  mix-blend-mode: screen;
}
.logo-nova { color: var(--cyan); }
.logo-tech { color: var(--white); }

.nav-links {
  list-style: none;
  display: flex;
  gap: 2rem;
  margin-left: auto;
}
.nav-links a {
  color: rgba(255,255,255,0.65);
  text-decoration: none;
  font-size: 0.82rem;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  transition: color var(--transition);
  position: relative;
}
.nav-links a::after {
  content:'';
  position:absolute;
  bottom:-4px; left:0; right:0;
  height:1px;
  background: var(--cyan);
  transform: scaleX(0);
  transition: transform var(--transition);
}
.nav-links a:hover,
.nav-links a.active { color: var(--cyan); }
.nav-links a:hover::after,
.nav-links a.active::after { transform: scaleX(1); }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  margin-left: auto;
}
.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--cyan);
  transition: all var(--transition);
}
.nav-toggle.open span:nth-child(1) { transform: rotate(45deg) translate(5px,5px); }
.nav-toggle.open span:nth-child(2) { opacity:0; }
.nav-toggle.open span:nth-child(3) { transform: rotate(-45deg) translate(5px,-5px); }

/* ── Footer ── */
#footer {
  background: linear-gradient(180deg, rgba(5,14,30,0.8) 0%, rgba(8,26,57,1) 100%);
  border-top: 1px solid rgba(0,198,212,0.2);
  padding: 5rem 0 0;
  position: relative;
}
#footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--cyan), transparent);
  opacity: 0.5;
}
.footer-inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.5fr;
  gap: 3rem;
  padding-bottom: 3rem;
}
.footer-brand p { 
  font-size: 0.95rem; 
  margin-top: 0.8rem; 
  color: rgba(255,255,255,0.7);
}
.footer-domain { 
  color: var(--cyan) !important; 
  font-size: 0.9rem !important; 
  font-weight: 600;
  margin-top: 0.5rem !important;
}
.footer-logo-img {
  height: 44px;
  width: auto;
  display: block;
  mix-blend-mode: screen;
  margin-bottom: 1rem;
  filter: brightness(1.2) contrast(1.1);
  max-width: 180px;
  object-fit: contain;
}
.footer-links { 
  display: flex; 
  flex-direction: column; 
  gap: 0.8rem; 
}
.footer-links h4 { 
  color: #fff; 
  font-size: 0.85rem; 
  letter-spacing: 2px; 
  text-transform: uppercase; 
  margin-bottom: 0.8rem;
  font-weight: 700;
}
.footer-links a { 
  color: rgba(255,255,255,0.6); 
  text-decoration: none; 
  font-size: 0.9rem; 
  transition: all var(--transition);
  position: relative;
  padding-left: 0;
}
.footer-links a:hover { 
  color: var(--cyan); 
  padding-left: 8px;
}
.footer-links a::before {
  content: '→';
  position: absolute;
  left: -12px;
  opacity: 0;
  transition: all var(--transition);
}
.footer-links a:hover::before {
  opacity: 1;
  left: -4px;
}
.footer-contact h4 { 
  color: #fff; 
  font-size: 0.85rem; 
  letter-spacing: 2px; 
  text-transform: uppercase; 
  margin-bottom: 1rem;
  font-weight: 700;
}
.footer-contact p { 
  font-size: 0.9rem; 
  margin-bottom: 0.6rem;
  color: rgba(255,255,255,0.7);
}
.social-row { 
  display: flex; 
  gap: 0.8rem; 
  margin-top: 1.2rem; 
}
.social-icon {
  width: 40px; 
  height: 40px;
  border: 1.5px solid rgba(0,198,212,0.4);
  border-radius: 50%;
  display: flex; 
  align-items: center; 
  justify-content: center;
  color: var(--cyan);
  text-decoration: none;
  font-size: 0.8rem;
  font-weight: 700;
  transition: all var(--transition);
  background: rgba(0,198,212,0.05);
}
.social-icon:hover {
  background: var(--cyan);
  color: var(--navy);
  border-color: var(--cyan);
  box-shadow: 0 0 20px var(--cyan-glow);
  transform: translateY(-3px);
}
.footer-bottom {
  border-top: 1px solid rgba(0,198,212,0.15);
  padding: 1.5rem 2rem;
  text-align: center;
  background: rgba(0,0,0,0.2);
}
.footer-bottom p { 
  font-size: 0.8rem; 
  color: rgba(255,255,255,0.4);
  letter-spacing: 0.5px;
}

/* ── HUD ── */
#hud {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 500;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  pointer-events: none;
}
#hud span {
  font-size: 0.6rem;
  letter-spacing: 2px;
  color: rgba(0,198,212,0.35);
  text-transform: uppercase;
}

/* ── Progress bar ── */
#progress-bar {
  position: fixed;
  top: 0; left: 0;
  height: 2px;
  background: var(--cyan);
  z-index: 2000;
  width: 0%;
  box-shadow: 0 0 8px var(--cyan);
  transition: width 0.1s linear;
}

/* ── Loading screen ── */
#loading-screen {
  position: fixed;
  inset: 0;
  background: var(--navy);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  transition: opacity 0.5s ease;
  pointer-events: none;
}
#loading-screen.hidden {
  opacity: 0;
}
.loading-content {
  text-align: center;
}
.loading-spinner {
  width: 50px;
  height: 50px;
  border: 3px solid rgba(0,198,212,0.2);
  border-top-color: var(--cyan);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin: 0 auto 20px;
}
.loading-content p {
  color: var(--cyan);
  font-size: 0.9rem;
  letter-spacing: 2px;
  text-transform: uppercase;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ── Section head ── */
.section-head { text-align:center; margin-bottom:3.5rem; }
.section-head p { margin-top:0.8rem; max-width:500px; margin-inline:auto; }

/* ── Reveal animation ── */
.reveal, .rv {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
.reveal.visible, .rv.visible {
  opacity: 1;
  transform: translateY(0);
}

/* scroll-content — visible by default, GSAP animates from 0 if loaded */
.scroll-content { opacity: 1; }

/* ── Page hero (inner pages) ── */
.page-hero {
  min-height: 40vh;
  display: flex;
  align-items: flex-end;
  padding: 8rem 0 4rem;
  position: relative;
  overflow: hidden;
}
.page-hero canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.page-hero-content {
  position: relative;
  z-index: 2;
}
.page-hero h1 { font-size: clamp(2rem, 5vw, 4rem); }

/* ── Responsive ── */
@media (max-width: 900px) {
  .footer-inner { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .nav-links { 
    display:none; 
    position:fixed; 
    top:64px; left:0; right:0;
    background: rgba(8,26,57,0.98);
    flex-direction:column;
    padding:2rem;
    gap:1.5rem;
    border-bottom:1px solid rgba(0,198,212,0.15);
  }
  .nav-links.open { display:flex; }
  .nav-toggle { display:flex; }
  .btn-nav { display:none; }
  .footer-inner { grid-template-columns:1fr; gap:2rem; }
}

/* ══════════════════════════════════════════
   LIGHT THEME
   body.light overrides all dark colors
══════════════════════════════════════════ */
body.light {
  background: #ffffff;
  color: #081A39;
}

/* Typography */
body.light p  { color: rgba(8,26,57,0.65); }
body.light h1,
body.light h2,
body.light h3,
body.light h4 { color: #081A39; }

/* Navbar */
body.light #navbar,
body.light #nav {
  background: rgba(255,255,255,0.88);
  border-bottom-color: rgba(0,198,212,0.2);
}
body.light #navbar.scrolled,
body.light #nav.scrolled {
  background: rgba(255,255,255,0.98);
}
body.light .nav-links a { color: rgba(8,26,57,0.65); }
body.light .nav-links a:hover,
body.light .nav-links a.active,
body.light .nav-links a.act { color: var(--cyan); }
body.light .nav-toggle span { background: #081A39; }

/* Mobile nav dropdown */
body.light .nav-links {
  background: rgba(255,255,255,0.98);
  border-bottom-color: rgba(0,198,212,0.2);
}

/* Buttons */
body.light .btn-primary { background: var(--cyan); color: #fff; }
body.light .btn-primary:hover { background: #081A39; color: #fff; }
body.light .btn-ghost { color: var(--cyan); border-color: var(--cyan); }
body.light .btn-ghost:hover { background: rgba(0,198,212,0.1); }
body.light .btn-nav { background: var(--cyan); color: #fff; }
body.light .btn-nav:hover { background: #081A39; }

/* Cards & panels */
body.light .svc-card,
body.light .prod-card,
body.light .value-card,
body.light .team-card,
body.light .all-svc-item {
  background: #ffffff;
  border-color: rgba(8,26,57,0.1);
  box-shadow: 0 2px 12px rgba(8,26,57,0.06);
}
body.light .svc-card:hover,
body.light .prod-card:hover,
body.light .value-card:hover,
body.light .team-card:hover,
body.light .all-svc-item:hover {
  background: #f0faff;
  border-color: rgba(0,198,212,0.4);
  box-shadow: 0 12px 40px rgba(0,198,212,0.12);
}
body.light .svc-card h3,
body.light .prod-card h3,
body.light .value-card h3,
body.light .team-card h3,
body.light .all-svc-item h3 { color: #081A39; }
body.light .svc-card p,
body.light .prod-card p,
body.light .value-card p,
body.light .team-card p,
body.light .all-svc-item p { color: rgba(8,26,57,0.6); }

/* Service panel */
body.light .svc-panel {
  background: rgba(8,26,57,0.03);
  border-color: rgba(8,26,57,0.1);
}
body.light .svc-panel-text h2 { color: #081A39; }
body.light .svc-panel-text p  { color: rgba(8,26,57,0.65); }
body.light .svc-features li   { color: rgba(8,26,57,0.75); border-bottom-color: rgba(8,26,57,0.06); }
body.light .svc-panel-visual  { background: rgba(0,198,212,0.06); border-color: rgba(0,198,212,0.2); }

/* Sections with dark backgrounds */
body.light #about-sec,
body.light #svc-sec,
body.light #prod-sec,
body.light #stats-sec,
body.light #cta-band,
body.light #about,
body.light #mission,
body.light #values,
body.light #timeline,
body.light #team,
body.light #contact,
body.light #services,
body.light .services-page { background: #f0f6ff; }

/* Keep hero dark so 3D scene is visible */
body.light #hero { background: #081A39 !important; }

body.light #about-sec { background: linear-gradient(135deg,rgba(0,198,212,0.08),#f0f6ff); }

/* About visual box */
body.light .about-vis,
body.light .mission-visual {
  background: rgba(8,26,57,0.04);
  border-color: rgba(8,26,57,0.1);
}

/* Stats */
body.light .stat-item p { color: rgba(8,26,57,0.55); }

/* CTA band */
body.light #cta-band h2 { color: #081A39; }
body.light #cta-band p  { color: rgba(8,26,57,0.6); }

/* Footer */
body.light #footer,
body.light footer {
  background: #081A39;
}
body.light .footer-brand p,
body.light .footer-contact p { color: rgba(255,255,255,0.7); }
body.light .footer-links h4,
body.light .footer-contact h4 { color: #fff; }
body.light .footer-links a { color: rgba(255,255,255,0.6); }
body.light .footer-links a:hover { color: var(--cyan); }
body.light .footer-bottom p { color: rgba(255,255,255,0.4); }

/* Page hero */
body.light .page-hero { background: linear-gradient(135deg, #e8f4ff 0%, #f0faff 100%); }
body.light .page-hero h1 { color: #081A39; }
body.light .page-hero p  { color: rgba(8,26,57,0.65); }

/* HUD */
body.light #hud span { color: rgba(0,198,212,0.5); }

/* Section head */
body.light .section-head p { color: rgba(8,26,57,0.6); }

/* Timeline */
body.light .tl-content h3,
body.light .tlc h3 { color: #081A39; }
body.light .tl-content p,
body.light .tlc p  { color: rgba(8,26,57,0.6); }

/* Contact form */
body.light .fg input,
body.light .fg textarea,
body.light .fg select {
  background: #fff;
  border-color: rgba(8,26,57,0.2);
  color: #081A39;
}
body.light .fg input:focus,
body.light .fg textarea:focus { border-color: var(--cyan); }
body.light .fg label { color: rgba(8,26,57,0.55); }
body.light .cf-wrap,
body.light .contact-form-wrap {
  background: rgba(8,26,57,0.04);
  border-color: rgba(8,26,57,0.1);
}

/* ── Theme Toggle Button ── */
.theme-toggle {
  width: 40px;
  height: 22px;
  border-radius: 11px;
  border: 1.5px solid rgba(0,198,212,0.5);
  background: rgba(0,198,212,0.1);
  cursor: pointer;
  position: relative;
  flex-shrink: 0;
  transition: background var(--transition), border-color var(--transition);
  outline: none;
  padding: 0;
}
.theme-toggle::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--cyan);
  transition: transform var(--transition), background var(--transition);
}
body.light .theme-toggle {
  background: rgba(8,26,57,0.1);
  border-color: rgba(8,26,57,0.3);
}
body.light .theme-toggle::after {
  transform: translateX(18px);
  background: #081A39;
}
.theme-toggle-wrap {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}
.theme-toggle-wrap span {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.5);
  transition: color var(--transition);
  user-select: none;
}
body.light .theme-toggle-wrap span { color: rgba(8,26,57,0.5); }
