/* ===================================
   CSS RESET & BASE STYLES
   =================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  /* Color Palette */
  --primary-blue: #1a4fff;
  --dark-gray: #2f3237;
  --orange: #ff7f2a;
  --red: #cc1e2c;
  --white: #ffffff;

  /* Typography */
  --font-primary: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

body {
  font-family: var(--font-primary);
  color: var(--dark-gray);
  line-height: 1.6;
  overflow-x: hidden;
}

/* ===================================
   NAVIGATION BAR
   ================================== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  transition: all 0.3s ease;
  background-color: transparent;
}

.navbar.scrolled {
  background-color: var(--dark-gray); /* Home page: transparent to dark gray on scroll */
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3); /* */
}

.navbar.navbar-solid {
  background-color: var(--dark-gray); /* Other pages: solid dark gray background by default */
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3); /* */
}

.nav-container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 1rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  flex-shrink: 0;
  text-decoration: none;
  display: block;
  transition: opacity 0.3s ease;
}

.nav-logo:hover {
  opacity: 0.8;
}

.logo-img {
  height: 40px;
  width: auto;
  display: block;
}

.nav-spacer {
  width: 60px;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 5rem;
  align-items: center;
  margin-left: auto;
}

.nav-item {
  position: relative;
}

.nav-link {
  text-decoration: none;
  color: var(--white); /* All navigation links are white by default (already was, confirming) */
  font-size: 1rem;
  font-weight: 500;
  transition: color 0.3s ease;
  position: relative;
  padding: 0.5rem 0;
}

.navbar.scrolled .nav-link,
.navbar.navbar-solid .nav-link {
  color: var(--white); /* Keep links white even on scrolled or solid navbar */
}

.nav-link:hover {
  color: var(--orange);
}

.nav-link.active::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--orange);
}

/* Improved mobile menu toggle - proper hamburger icon styling */
.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  z-index: 1001;
  position: relative;
  width: 40px;
  height: 40px;
}

.hamburger-icon {
  display: block;
  width: 28px;
  height: 3px;
  background-color: var(--white);
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  transition: all 0.25s ease;
  border-radius: 2px;
}

.hamburger-icon::before,
.hamburger-icon::after {
  content: "";
  position: absolute;
  width: 28px;
  height: 3px;
  background-color: var(--white);
  transition: all 0.25s ease;
  left: 0;
  border-radius: 2px;
}

.hamburger-icon::before {
  top: -9px;
}

.hamburger-icon::after {
  top: 9px;
}

.navbar.scrolled .hamburger-icon,
.navbar.scrolled .hamburger-icon::before,
.navbar.scrolled .hamburger-icon::after,
.navbar.navbar-solid .hamburger-icon,
.navbar.navbar-solid .hamburger-icon::before,
.navbar.navbar-solid .hamburger-icon::after {
  background-color: var(--white); /* Hamburger icon stays white on all navbar states */
}

/* Hamburger to X animation - proper ✕ icon */
.mobile-menu-toggle.active .hamburger-icon {
  background-color: transparent;
}

.mobile-menu-toggle.active .hamburger-icon::before {
  transform: rotate(45deg);
  top: 0;
  background-color: var(--white);
}

.mobile-menu-toggle.active .hamburger-icon::after {
  transform: rotate(-45deg);
  top: 0;
  background-color: var(--white);
}

/* ===================================
   HERO SECTION
   =================================== */
/* Hero must cover 100vh with NO gaps - using cover, not contain */
.hero {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
  display: flex;
  align-items: flex-start; /* Changed from center to flex-start for custom positioning */
  justify-content: center;
}

.hero-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(47, 50, 55, 0.7) 0%, rgba(26, 79, 255, 0.3) 100%);
  z-index: 2;
}

/* Adjusted positioning to be 30% lower from original center position */
.hero-content {
  position: relative;
  z-index: 3;
  text-align: center;
  color: var(--white);
  max-width: 900px;
  padding: 2rem;
  margin-top: 40vh; /* Positioned 40% from top - moderately lower than center */
}

.hero-slide {
  display: none;
  opacity: 0;
  transition: opacity 0.4s ease-in-out;
}

.hero-slide.active {
  display: block;
  opacity: 1;
  animation: fadeIn 0.4s ease-in-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Typography sizes reduced by 20% for better proportion */
.hero-title {
  font-size: 2.4rem;
  font-weight: 700;
  margin-bottom: 1rem;
  line-height: 1.2;
  text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.3);
}

.hero-description {
  font-size: 1.1rem;
  margin-bottom: 1.8rem;
  line-height: 1.6;
  font-weight: 300;
  text-shadow: 1px 1px 5px rgba(0, 0, 0, 0.3);
}

.hero-button {
  background-color: var(--orange);
  color: var(--white);
  border: none;
  padding: 0.75rem 1.8rem;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(26, 79, 255, 0.3);
}

.hero-button:hover {
  background-color: var(--primary-blue);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 127, 42, 0.4);
}

.hero-button:active {
  transform: translateY(0);
}

.carousel-indicators {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 3rem;
}

.indicator {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  transition: all 0.3s ease;
  border: 2px solid transparent;
}

.indicator:hover {
  background-color: rgba(255, 255, 255, 0.6);
  transform: scale(1.1);
}

.indicator.active {
  background-color: var(--orange);
  border-color: var(--white);
  transform: scale(1.2);
}

/* Animation placeholder classes for future implementation */
.animation-turbine,
.animation-solar,
.animation-screen {
  position: absolute;
  pointer-events: none;
  z-index: 2;
}

/* ===================================
   LIGHTNING CURSOR EFFECT
   =================================== */
/* Replaced basic line effect with professional electric particle system */
.lightning-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9999;
  overflow: hidden;
}

.lightning-particle {
  position: absolute;
  pointer-events: none;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(174, 217, 255, 1) 0%, rgba(26, 79, 255, 0.8) 50%, transparent 100%);
  box-shadow: 0 0 8px rgba(174, 217, 255, 0.9), 0 0 16px rgba(26, 79, 255, 0.6), 0 0 24px rgba(26, 79, 255, 0.3);
  opacity: 0;
  animation: particleFloat 1.2s ease-out forwards;
}

@keyframes particleFloat {
  0% {
    opacity: 1;
    transform: translate(0, 0) scale(1);
  }
  100% {
    opacity: 0;
    transform: translate(var(--tx), var(--ty)) scale(0.3);
  }
}

.lightning-spark {
  position: absolute;
  pointer-events: none;
  width: 2px;
  border-radius: 50%;
  background: linear-gradient(180deg, rgba(174, 217, 255, 1) 0%, rgba(26, 79, 255, 0.4) 100%);
  box-shadow: 0 0 6px rgba(174, 217, 255, 1), 0 0 12px rgba(26, 79, 255, 0.7);
  opacity: 0;
  animation: sparkFade 0.8s ease-out forwards;
  transform-origin: top center;
}

@keyframes sparkFade {
  0% {
    opacity: 1;
    height: 20px;
    filter: blur(0px);
  }
  50% {
    opacity: 0.6;
    height: 25px;
    filter: blur(0.5px);
  }
  100% {
    opacity: 0;
    height: 15px;
    filter: blur(1px);
  }
}

.lightning-glow {
  position: absolute;
  pointer-events: none;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(26, 79, 255, 0.15) 0%, rgba(174, 217, 255, 0.1) 40%, transparent 70%);
  opacity: 0;
  animation: glowPulse 0.6s ease-out forwards;
  transform: translate(-50%, -50%);
}

@keyframes glowPulse {
  0% {
    opacity: 0.8;
    transform: translate(-50%, -50%) scale(0.5);
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(1.2);
  }
}

/* Disable lightning effect on mobile for performance */
@media screen and (max-width: 768px) {
  .lightning-container {
    display: none;
  }
}

/* ===================================
   PAGE CONTENT (for other pages)
   =================================== */
.page-content {
  padding-top: 120px;
  min-height: 100vh;
}

.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 2rem;
}

/* ===================================
   SERVICES SECTION
   =================================== */
.services-section {
  padding: 120px 0;
  background-color: #f8f9fa;
}

.service-item {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
  margin-bottom: 120px;
  opacity: 0;
  transform: translateX(0);
  transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.service-item:last-child {
  margin-bottom: 0;
}

/* Slide-in animations */
.service-item.slide-from-right.animate-in {
  animation: slideInFromRight 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.service-item.slide-from-left.animate-in {
  animation: slideInFromLeft 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes slideInFromRight {
  from {
    opacity: 0;
    transform: translateX(100px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInFromLeft {
  from {
    opacity: 0;
    transform: translateX(-100px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.service-content {
  padding: 40px;
}

.service-year {
  display: inline-block;
  background-color: var(--primary-blue);
  color: var(--white);
  padding: 8px 20px;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 20px;
  opacity: 0;
  animation: fadeInUp 0.6s ease-out 0.2s forwards;
}

.service-title {
  font-size: 2.2rem;
  color: var(--dark-gray);
  margin-bottom: 30px;
  line-height: 1.3;
  font-weight: 700;
  opacity: 0;
  animation: fadeInUp 0.6s ease-out 0.3s forwards;
}

.service-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.service-list-item {
  padding: 15px 0;
  padding-left: 30px;
  position: relative;
  font-size: 1.05rem;
  color: var(--dark-gray);
  border-bottom: 1px solid rgba(47, 50, 55, 0.1);
  opacity: 0;
  transform: translateY(20px);
}

.animate-in .service-list-item {
  animation: fadeInUp 0.4s ease-out forwards;
}

.service-list-item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 8px;
  height: 8px;
  background-color: var(--orange);
  border-radius: 50%;
}

.service-list-item:hover {
  color: var(--primary-blue);
  padding-left: 35px;
  transition: all 0.3s ease;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.service-image {
  padding: 20px;
}

.image-placeholder {
  width: 100%;
  aspect-ratio: 4 / 3;
  background: linear-gradient(135deg, #e0e7ff 0%, #c7d2fe 100%);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 40px rgba(26, 79, 255, 0.15);
  transition: all 0.4s ease;
  position: relative;
  overflow: hidden;
}

.image-placeholder::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transform: rotate(45deg);
  animation: shimmer 3s infinite;
}

@keyframes shimmer {
  0% {
    transform: translateX(-100%) translateY(-100%) rotate(45deg);
  }
  100% {
    transform: translateX(100%) translateY(100%) rotate(45deg);
  }
}

.image-placeholder span {
  font-size: 1.2rem;
  color: var(--primary-blue);
  font-weight: 600;
  z-index: 1;
}

.service-item:hover .image-placeholder {
  transform: scale(1.02);
  box-shadow: 0 15px 50px rgba(26, 79, 255, 0.25);
}

/* Responsive design for services section */
@media screen and (max-width: 968px) {
  .service-item {
    grid-template-columns: 1fr;
    gap: 40px;
    margin-bottom: 80px;
  }

  .service-title {
    font-size: 1.8rem;
  }

  .service-content {
    padding: 20px;
  }

  .service-list-item {
    font-size: 1rem;
  }

  /* On mobile, both sections slide from center */
  .service-item.slide-from-right.animate-in,
  .service-item.slide-from-left.animate-in {
    animation: slideInFromCenter 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
  }

  @keyframes slideInFromCenter {
    from {
      opacity: 0;
      transform: translateY(30px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
}

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

  .service-item {
    margin-bottom: 60px;
  }

  .service-title {
    font-size: 1.6rem;
    margin-bottom: 20px;
  }

  .service-list-item {
    font-size: 0.95rem;
    padding: 12px 0 12px 25px;
  }

  .image-placeholder span {
    font-size: 1rem;
  }
}

/* ===================================
   RESPONSIVE DESIGN
   =================================== */
@media screen and (max-width: 768px) {
  /* Mobile navbar - logo 120px minimum, hamburger properly aligned */
  .mobile-menu-toggle {
    display: block;
  }

  .logo-img {
    height: 50px;
    min-width: 120px;
  }

  .nav-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background-color: var(--dark-gray);
    flex-direction: column;
    justify-content: flex-start;
    padding-top: 80px;
    gap: 0;
    transition: right 0.25s ease;
    box-shadow: -2px 0 10px rgba(0, 0, 0, 0.2);
  }

  .nav-menu.active {
    right: 0;
  }

  .nav-item {
    width: 100%;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .nav-link {
    display: block;
    padding: 1.2rem 2rem;
    color: var(--white);
  }

  .nav-container {
    padding: 1rem 1.5rem;
  }

  .nav-spacer {
    display: none;
  }

  /* Adjusted mobile positioning proportionally */
  .hero-content {
    margin-top: 35vh;
    padding: 1.5rem;
  }

  .hero-title {
    font-size: 1.8rem;
  }

  .hero-description {
    font-size: 0.95rem;
  }

  .hero-button {
    padding: 0.75rem 1.8rem;
    font-size: 0.95rem;
  }

  .carousel-indicators {
    margin-top: 2rem;
    gap: 10px;
  }

  .indicator {
    width: 10px;
    height: 10px;
  }
}

@media screen and (max-width: 480px) {
  .logo-img {
    height: 45px;
    min-width: 110px;
  }

  .nav-menu {
    width: 100%;
  }

  /* Adjusted small screen positioning */
  .hero-content {
    padding: 1rem;
    margin-top: 30vh;
  }

  .hero-title {
    font-size: 1.5rem;
  }

  .hero-description {
    font-size: 0.85rem;
    margin-bottom: 1.5rem;
  }

  .hero-button {
    padding: 0.7rem 1.5rem;
    font-size: 0.9rem;
  }

  .carousel-indicators {
    gap: 8px;
    margin-top: 1.5rem;
  }

  .indicator {
    width: 8px;
    height: 8px;
  }
}
