/* ==========================================================================
   VIJAY INDUSTRIES - GLOBAL STYLESHEET
   Aesthetics: Minimal, Premium, Industrial, Modern (Tesla / Apple / Nothing)
   ========================================================================== */

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

:root {
  /* Colors */
  --color-steel-grey: #6B7280;
  --color-dark-graphite: #1F2937;
  --color-rust-brown: #8B5E3C;
  --color-iron-black: #111827;
  --color-white: #FFFFFF;
  --color-light-steel: #E5E7EB;

  /* Fonts */
  --font-heading: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

  /* Default Theme: Light (Clean & Modern) */
  --bg-primary: #FCFCFD;
  --bg-secondary: #F3F4F6;
  --bg-tertiary: var(--color-light-steel);
  --bg-translucent: rgba(252, 252, 253, 0.9);
  --bg-glass: rgba(229, 231, 235, 0.4);
  --border-glass: rgba(0, 0, 0, 0.08);

  --text-primary: var(--color-iron-black);
  --text-secondary: var(--color-dark-graphite);
  --text-muted: var(--color-steel-grey);
  
  --accent: var(--color-rust-brown);
  --accent-hover: #734B2E;
  --accent-rgb: 139, 94, 60;
  
  --border-color: #E5E7EB;
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 8px 30px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.12);

  /* Layout */
  --header-height: 80px;
  --container-width: 1400px;
  --transition-smooth: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-fast: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Dark Theme Variables */
body.dark-theme {
  --bg-primary: var(--color-iron-black);
  --bg-secondary: var(--color-dark-graphite);
  --bg-tertiary: #1A222F;
  --bg-translucent: rgba(17, 24, 39, 0.85);
  --bg-glass: rgba(31, 41, 55, 0.4);
  --border-glass: rgba(255, 255, 255, 0.08);

  --text-primary: var(--color-white);
  --text-secondary: var(--color-light-steel);
  --text-muted: var(--color-steel-grey);
  
  --accent: var(--color-rust-brown);
  --accent-hover: #A2724E;
  
  --border-color: #2D3748;
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 8px 30px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 20px 40px rgba(0, 0, 0, 0.5);
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  transition: background-color 0.5s ease, color 0.5s ease;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: var(--text-primary);
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition-fast);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button, input, textarea, select {
  font-family: inherit;
  font-size: inherit;
  background: none;
  border: none;
  color: inherit;
}

ul {
  list-style: none;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: var(--bg-primary);
}
::-webkit-scrollbar-thumb {
  background: var(--bg-secondary);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--accent);
}

/* Loader Screen */
#preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--color-iron-black);
  z-index: 9999;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.6s;
}

.loader-logo {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  color: var(--color-white);
  margin-bottom: 20px;
  opacity: 0;
  transform: translateY(20px);
  animation: loaderTextReveal 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.loader-logo span {
  color: var(--accent);
}

.loader-bar-container {
  width: 200px;
  height: 2px;
  background-color: rgba(255, 255, 255, 0.1);
  overflow: hidden;
  position: relative;
}

.loader-bar {
  width: 0%;
  height: 100%;
  background-color: var(--accent);
  position: absolute;
  top: 0;
  left: 0;
  animation: loaderProgress 1.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Page Transition Overlay */
.page-transition-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--bg-primary);
  z-index: 9998;
  transform: translateY(100%);
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  pointer-events: none;
}

.page-transition-overlay.active {
  transform: translateY(0);
}

/* Layout Utilities */
.container {
  width: 100%;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 40px;
}

@media (max-width: 768px) {
  .container {
    padding: 0 20px;
  }
}

.section {
  padding: 120px 0;
  position: relative;
}

@media (max-width: 768px) {
  .section {
    padding: 80px 0;
  }
}

.text-center {
  text-align: center;
}

.accent-text {
  color: var(--accent);
}

/* Premium Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 16px 36px;
  font-family: var(--font-heading);
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  border-radius: 0; /* Minimal, industrial box look */
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: var(--transition-smooth);
}

.btn-primary {
  background-color: var(--accent);
  color: var(--color-white);
  border: 1px solid var(--accent);
}

.btn-primary::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: 0.5s;
}

.btn-primary:hover {
  background-color: var(--accent-hover);
  border-color: var(--accent-hover);
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(139, 94, 60, 0.3);
}

.btn-primary:hover::before {
  left: 100%;
}

.btn-secondary {
  background-color: transparent;
  color: var(--text-primary);
  border: 1px solid var(--text-primary);
}

.btn-secondary:hover {
  background-color: var(--text-primary);
  color: var(--bg-primary);
  transform: translateY(-2px);
}

.btn-outline-accent {
  background-color: transparent;
  color: var(--accent);
  border: 1px solid var(--accent);
}

.btn-outline-accent:hover {
  background-color: var(--accent);
  color: var(--color-white);
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(139, 94, 60, 0.2);
}

/* Header / Navbar */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: var(--header-height);
  z-index: 1000;
  transition: var(--transition-smooth);
  border-bottom: 1px solid transparent;
}

.header.scrolled {
  background-color: var(--bg-translucent);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  height: 70px;
  border-bottom: 1px solid var(--border-glass);
  box-shadow: var(--shadow-sm);
}

.header .container {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 100%;
}

.logo img {
  height: 40px;
  width: auto;
  object-fit: contain;
  transition: var(--transition-smooth);
}

.header.scrolled .logo img {
  height: 35px;
}

.logo-text {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  color: var(--text-primary);
  line-height: 1;
}

.logo-text span {
  color: var(--accent);
  font-weight: 300;
  font-size: 0.9rem;
  display: block;
  letter-spacing: 0.15em;
  margin-top: 2px;
}

/* Nav Menu */
.nav-menu {
  display: flex;
  align-items: center;
  gap: 32px;
  height: 100%;
}

.nav-link {
  font-family: var(--font-heading);
  font-weight: 500;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-secondary);
  position: relative;
  padding: 10px 0;
  height: 100%;
  display: flex;
  align-items: center;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--accent);
  transition: var(--transition-fast);
}

.nav-link:hover, .nav-link.active {
  color: var(--text-primary);
}

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

/* Mega Menu */
.has-megamenu {
  position: static;
}

.megamenu {
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  background-color: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  opacity: 0;
  visibility: hidden;
  transform: translateY(15px);
  transition: var(--transition-smooth);
  padding: 40px 0;
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
}

.has-megamenu:hover .megamenu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.header.scrolled .has-megamenu:hover .megamenu {
  top: 100%;
}

.megamenu-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr 1fr;
  gap: 40px;
}

.megamenu-brand-panel {
  border-right: 1px solid var(--border-color);
  padding-right: 40px;
}

.megamenu-brand-panel h3 {
  font-size: 1.5rem;
  margin-bottom: 12px;
}

.megamenu-brand-panel p {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.megamenu-col h4 {
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  margin-bottom: 20px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 8px;
}

.megamenu-links li {
  margin-bottom: 12px;
}

.megamenu-links a {
  font-size: 0.9rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 8px;
}

.megamenu-links a:hover {
  color: var(--accent);
  transform: translateX(5px);
}

/* Theme Toggle & Hamburger */
.header-actions {
  display: flex;
  align-items: center;
  gap: 20px;
}

.theme-toggle {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-primary);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-fast);
  background-color: var(--bg-glass);
  border: 1px solid var(--border-glass);
}

.theme-toggle:hover {
  background-color: var(--accent);
  color: var(--color-white);
}

.theme-toggle svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.theme-toggle .sun-icon {
  display: none;
}

body.dark-theme .theme-toggle .moon-icon {
  display: none;
}

body.dark-theme .theme-toggle .sun-icon {
  display: block;
}

/* Mobile Toggle Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 24px;
  height: 16px;
  cursor: pointer;
  background: none;
  border: none;
  z-index: 1001;
}

.hamburger span {
  display: block;
  width: 100%;
  height: 2px;
  background-color: var(--text-primary);
  transition: var(--transition-fast);
}

/* Mobile Nav Menu Show/Hide */
@media (max-width: 1024px) {
  .hamburger {
    display: flex;
  }
  
  .nav-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 320px;
    height: 100vh;
    background-color: var(--bg-secondary);
    flex-direction: column;
    align-items: flex-start;
    padding: 100px 40px;
    gap: 24px;
    box-shadow: var(--shadow-lg);
    transition: var(--transition-smooth);
    z-index: 1000;
    overflow-y: auto;
  }
  
  .nav-menu.active {
    right: 0;
  }
  
  .nav-link {
    width: 100%;
    height: auto;
    padding: 8px 0;
    font-size: 1.1rem;
  }
  
  .has-megamenu {
    width: 100%;
  }
  
  .has-megamenu:hover .megamenu {
    display: none; /* Hide standard mega menu on mobile */
  }

  .megamenu-mobile-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
  }

  .mobile-megamenu-active .megamenu {
    display: block;
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
    background: transparent;
    border: none;
    padding: 10px 0 0 15px;
    width: 100%;
  }
  
  .mobile-megamenu-active .megamenu-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  
  .megamenu-brand-panel {
    display: none;
  }
  
  .hamburger.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }
  
  .hamburger.active span:nth-child(2) {
    opacity: 0;
  }
  
  .hamburger.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }
}

/* Global Footer */
.footer {
  background-color: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 80px 0 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1.2fr;
  gap: 40px;
  margin-bottom: 60px;
}

@media (max-width: 1024px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 640px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

.footer-logo-col h3 {
  font-size: 1.6rem;
  font-weight: 800;
  margin-bottom: 16px;
  letter-spacing: 0.05em;
}

.footer-logo-col h3 span {
  color: var(--accent);
}

.footer-logo-col p {
  color: var(--text-muted);
  font-size: 0.9rem;
  line-height: 1.6;
  margin-bottom: 24px;
}

.social-links {
  display: flex;
  gap: 12px;
}

.social-link {
  width: 40px;
  height: 40px;
  border-radius: 0; /* Minimal square aesthetic */
  background-color: var(--bg-primary);
  border: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-fast);
}

.social-link:hover {
  background-color: var(--accent);
  color: var(--color-white);
  border-color: var(--accent);
  transform: translateY(-3px);
}

.social-link svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

.footer-col h4 {
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-primary);
  margin-bottom: 24px;
  position: relative;
  padding-bottom: 8px;
}

.footer-col h4::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 30px;
  height: 2px;
  background-color: var(--accent);
}

.footer-links li {
  margin-bottom: 12px;
}

.footer-links a {
  font-size: 0.9rem;
  color: var(--text-secondary);
  display: inline-block;
}

.footer-links a:hover {
  color: var(--accent);
  transform: translateX(4px);
}

.contact-info-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 16px;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.contact-info-list svg {
  width: 16px;
  height: 16px;
  fill: var(--accent);
  flex-shrink: 0;
  margin-top: 4px;
}

.footer-bottom {
  border-top: 1px solid var(--border-color);
  padding-top: 30px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
  color: var(--text-muted);
}

@media (max-width: 768px) {
  .footer-bottom {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }
}

.footer-bottom-links {
  display: flex;
  gap: 24px;
}

.footer-bottom-links a:hover {
  color: var(--text-primary);
}

/* Back to Top Button */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: -60px; /* Hidden initially */
  width: 45px;
  height: 45px;
  background-color: var(--accent);
  color: var(--color-white);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 99;
  transition: var(--transition-smooth);
  box-shadow: var(--shadow-md);
}

.back-to-top.show {
  right: 30px;
}

.back-to-top:hover {
  background-color: var(--accent-hover);
  transform: translateY(-3px);
}

.back-to-top svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

/* Animations (Intersection Observer & CSS Keyframes) */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

.reveal-left {
  opacity: 0;
  transform: translateX(-40px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-left.revealed {
  opacity: 1;
  transform: translateX(0);
}

.reveal-right {
  opacity: 0;
  transform: translateX(40px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-right.revealed {
  opacity: 1;
  transform: translateX(0);
}

.stagger-item {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.stagger-container.revealed .stagger-item {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger delay generations */
.stagger-container.revealed .stagger-item:nth-child(1) { transition-delay: 0.1s; }
.stagger-container.revealed .stagger-item:nth-child(2) { transition-delay: 0.2s; }
.stagger-container.revealed .stagger-item:nth-child(3) { transition-delay: 0.3s; }
.stagger-container.revealed .stagger-item:nth-child(4) { transition-delay: 0.4s; }
.stagger-container.revealed .stagger-item:nth-child(5) { transition-delay: 0.5s; }
.stagger-container.revealed .stagger-item:nth-child(6) { transition-delay: 0.6s; }

@keyframes loaderTextReveal {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes loaderProgress {
  to {
    width: 100%;
  }
}

/* ==========================================================================
   8. Custom Pop-up / Modals (Privacy, Terms & Submission)
   ========================================================================== */
.custom-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(17, 24, 39, 0.75); /* dark premium overlay */
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.4s;
  padding: 20px;
}

.custom-modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.custom-modal-container {
  background-color: var(--bg-secondary);
  border: 1px solid var(--border-glass);
  width: 100%;
  max-width: 700px;
  max-height: 80vh;
  position: relative;
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  transform: translateY(30px) scale(0.95);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  padding: 40px;
}

@media (max-width: 640px) {
  .custom-modal-container {
    padding: 35px 20px 30px;
  }
}

.custom-modal-overlay.active .custom-modal-container {
  transform: translateY(0) scale(1);
}

.custom-modal-close {
  position: absolute;
  top: 15px;
  right: 20px;
  font-size: 2rem;
  font-weight: 300;
  cursor: pointer;
  line-height: 1;
  color: var(--text-muted);
  transition: var(--transition-fast);
  background: none;
  border: none;
  padding: 5px;
}

.custom-modal-close:hover {
  color: var(--accent);
}

.custom-modal-content {
  overflow-y: auto;
  padding-right: 15px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.custom-modal-content h2 {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-primary);
  border-bottom: 2px solid var(--accent);
  padding-bottom: 10px;
}

.custom-modal-content h3 {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 600;
  margin-top: 15px;
  margin-bottom: 5px;
  text-transform: uppercase;
  color: var(--text-primary);
}

.custom-modal-content p, .custom-modal-content ul {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

.custom-modal-content ul {
  list-style: square;
  padding-left: 20px;
  margin-top: 5px;
}

.custom-modal-content li {
  margin-bottom: 8px;
}

/* Custom Scrollbar for Modal content */
.custom-modal-content::-webkit-scrollbar {
  width: 6px;
}
.custom-modal-content::-webkit-scrollbar-track {
  background: transparent;
}
.custom-modal-content::-webkit-scrollbar-thumb {
  background: var(--border-color);
}
.custom-modal-content::-webkit-scrollbar-thumb:hover {
  background: var(--accent);
}

/* Modal Actions for Fallback/Success Dialogs */
.modal-actions {
  display: flex;
  gap: 15px;
  margin-top: 15px;
  flex-wrap: wrap;
  width: 100%;
}

.modal-actions .btn {
  flex: 1;
  min-width: 160px;
}



