/* Root variables for consistent theming */
:root {
  --primary-color: #0047ab; /* cobalt blue */
  --secondary-color: #006fd6; /* lighter cobalt */
  --dark-color: #0a1f44;
  --light-color: #f5f8ff;
  --text-color: #333;
  --max-width: 1200px;
  font-size: 16px;
}

body {
  margin: 0;
  font-family: 'Poppins', sans-serif;
  color: var(--text-color);
  background-color: var(--light-color);
}

/* Utility classes */
.container {
  width: 90%;
  max-width: var(--max-width);
  margin: 0 auto;
}

.section {
  padding: 4rem 0;
}

h1, h2, h3 {
  margin-top: 0;
  color: var(--dark-color);
}

p {
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

a {
  color: var(--primary-color);
  text-decoration: none;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border-radius: 4px;
  font-weight: 600;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.primary-btn {
  background-color: var(--primary-color);
  color: #fff;
}

.primary-btn:hover {
  background-color: var(--secondary-color);
}

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

.secondary-btn:hover {
  background-color: var(--primary-color);
  color: #fff;
}

/* Adjust secondary buttons on dark backgrounds such as hero */
.hero .secondary-btn {
  border-color: #fff;
  color: #fff;
}

.hero .secondary-btn:hover {
  background-color: #fff;
  color: var(--primary-color);
}

/* Navigation */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: rgba(10, 31, 68, 0.8);
  color: #fff;
  z-index: 1000;
  backdrop-filter: blur(8px);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 0;
}

/* Logo container and image */
.logo {
  display: flex;
  align-items: center;
}

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

.nav-links {
  list-style: none;
  display: flex;
  gap: 2rem;
  margin: 0;
}

.nav-links a {
  color: #fff;
  font-weight: 500;
  transition: color 0.3s ease;
}

.nav-links a:hover {
  color: var(--secondary-color);
}

/* Hero section */
.hero {
  position: relative;
  height: 90vh;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  text-align: center;
}

.hero-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
}

/* Floating decorative images behind hero text */
.floating-images {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  overflow: hidden;
  z-index: -1;
}

.floating-images img {
  position: absolute;
  width: 180px;
  height: 120px;
  object-fit: cover;
  opacity: 0.5;
  border-radius: 8px;
}

/* Individual starting positions and animations for each floating image */
.floating-images .img1 {
  top: 15%;
  left: 5%;
  animation: float1 22s ease-in-out infinite;
}

.floating-images .img2 {
  top: 60%;
  left: 80%;
  animation: float2 25s ease-in-out infinite;
}

.floating-images .img3 {
  top: 40%;
  left: 50%;
  animation: float3 20s ease-in-out infinite;
}

@keyframes float1 {
  0% { transform: translate(0, 0) scale(1) rotate(0deg); }
  25% { transform: translate(30px, -20px) scale(1.05) rotate(5deg); }
  50% { transform: translate(-10px, 25px) scale(1) rotate(-3deg); }
  75% { transform: translate(20px, 10px) scale(1.03) rotate(3deg); }
  100% { transform: translate(0, 0) scale(1) rotate(0deg); }
}

@keyframes float2 {
  0% { transform: translate(0, 0) scale(1) rotate(0deg); }
  25% { transform: translate(-25px, -15px) scale(0.95) rotate(-4deg); }
  50% { transform: translate(15px, 25px) scale(1.02) rotate(3deg); }
  75% { transform: translate(-20px, -10px) scale(1) rotate(-2deg); }
  100% { transform: translate(0, 0) scale(1) rotate(0deg); }
}

@keyframes float3 {
  0% { transform: translate(0, 0) scale(1) rotate(0deg); }
  25% { transform: translate(20px, 10px) scale(1.04) rotate(4deg); }
  50% { transform: translate(-15px, -20px) scale(0.97) rotate(-3deg); }
  75% { transform: translate(10px, 15px) scale(1.05) rotate(2deg); }
  100% { transform: translate(0, 0) scale(1) rotate(0deg); }
}

/* Animated hero text */
.animated-title {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: #fff;
  animation: slideDown 1.5s forwards;
}

.animated-subtitle {
  font-size: 1.1rem;
  margin-bottom: 2rem;
  color: #e0e6f1;
  animation: slideUp 1.5s forwards;
  animation-delay: 0.5s;
}

.animated-btn {
  animation: fadeIn 1.5s forwards;
  animation-delay: 1s;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-50px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 27, 66, 0.6);
  z-index: -1;
}

.hero-content {
  max-width: 700px;
  z-index: 1;
}

.hero-content h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: #fff;
}

.hero-content p {
  font-size: 1.1rem;
  margin-bottom: 2rem;
  color: #e0e6f1;
}

/* Hero text animation */
.hero-content h1,
.hero-content p,
.hero-content .btn {
  opacity: 0;
  animation: fadeUp 1s forwards;
}

.hero-content h1 {
  animation-delay: 0.2s;
}

.hero-content p {
  animation-delay: 0.4s;
}

.hero-content .btn {
  animation-delay: 0.6s;
}

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

/* About section */
.about-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  align-items: center;
}

.about-text {
  flex: 1 1 50%;
}

.about-image {
  flex: 1 1 50%;
  text-align: center;
}

.about-image img {
  width: 100%;
  max-width: 500px;
  border-radius: 8px;
}

/* Services */
.service-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.service-card {
  background-color: #fff;
  border-radius: 8px;
  padding: 1.5rem;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);
  text-align: center;
  transition: transform 0.3s ease;
}

.service-card:hover {
  transform: translateY(-8px);
}

.service-card img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  border-radius: 4px;
  margin-bottom: 1rem;
}

.service-card h3 {
  margin-top: 0;
  margin-bottom: 0.5rem;
  font-size: 1.25rem;
  color: var(--primary-color);
}

.service-card p {
  font-size: 0.95rem;
  color: #555;
}

/* CTA */
.cta {
  background-color: var(--primary-color);
  color: #fff;
  text-align: center;
  padding: 3rem 1rem;
  border-radius: 8px;
  margin: 4rem auto;
  max-width: 900px;
}

.cta h2 {
  color: #fff;
  margin-bottom: 0.5rem;
}

.cta p {
  color: #d3e4ff;
  margin-bottom: 1.5rem;
}

/* Features floating images */
/* Add a layer of subtle movement behind the why-choose-us section */
.features {
  position: relative;
  overflow: hidden;
}

/* Container for floating photos */
.features-floating {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: -1;
}

.features-floating img {
  position: absolute;
  width: 200px;
  height: 140px;
  object-fit: cover;
  opacity: 0.35;
  border-radius: 8px;
}

/* individual starting positions and animations for feature floats */
.features-floating .feat-img1 {
  top: 10%;
  left: 5%;
  animation: float4 28s ease-in-out infinite;
}

.features-floating .feat-img2 {
  top: 60%;
  left: 75%;
  animation: float5 32s ease-in-out infinite;
}

.features-floating .feat-img3 {
  top: 35%;
  left: 45%;
  animation: float6 30s ease-in-out infinite;
}

@keyframes float4 {
  0% { transform: translate(0, 0) scale(1) rotate(0deg); }
  20% { transform: translate(30px, -15px) scale(1.08) rotate(3deg); }
  40% { transform: translate(-20px, 30px) scale(0.95) rotate(-4deg); }
  60% { transform: translate(15px, -25px) scale(1.02) rotate(2deg); }
  80% { transform: translate(-10px, 20px) scale(1.05) rotate(-3deg); }
  100% { transform: translate(0, 0) scale(1) rotate(0deg); }
}

@keyframes float5 {
  0% { transform: translate(0, 0) scale(1) rotate(0deg); }
  20% { transform: translate(-35px, 20px) scale(1.07) rotate(-5deg); }
  40% { transform: translate(25px, -25px) scale(0.96) rotate(4deg); }
  60% { transform: translate(-15px, 30px) scale(1.04) rotate(-2deg); }
  80% { transform: translate(20px, -20px) scale(1.02) rotate(3deg); }
  100% { transform: translate(0, 0) scale(1) rotate(0deg); }
}

@keyframes float6 {
  0% { transform: translate(0, 0) scale(1) rotate(0deg); }
  20% { transform: translate(25px, -10px) scale(1.06) rotate(4deg); }
  40% { transform: translate(-15px, 25px) scale(0.94) rotate(-3deg); }
  60% { transform: translate(20px, 15px) scale(1.03) rotate(2deg); }
  80% { transform: translate(-25px, -20px) scale(0.98) rotate(-4deg); }
  100% { transform: translate(0, 0) scale(1) rotate(0deg); }
}

/* Additional animations for feature titles and descriptions */
.feature-title {
  opacity: 0;
  transform: translateY(30px);
  animation: fadeSlideIn 1s forwards;
  animation-delay: 0.3s;
}

.feature-desc {
  opacity: 0;
  transform: translateY(40px);
  animation: fadeSlideIn 1.2s forwards;
  animation-delay: 0.5s;
}

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

/* Gallery/Slideshow */
.gallery .slideshow {
  position: relative;
  width: 100%;
  max-width: 800px;
  margin: 2rem auto;
  overflow: hidden;
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

#slide-img {
  width: 100%;
  height: 450px;
  object-fit: cover;
  transition: opacity 1s ease-in-out;
}

/* Fade-out class for slideshow transitions */
.fade-out {
  opacity: 0;
}

/* Contact */
.contact-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  align-items: flex-start;
}

.contact-text {
  flex: 1 1 40%;
}

.contact-form {
  flex: 1 1 50%;
  background-color: #fff;
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.05);
}

.form-group {
  margin-bottom: 1rem;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-family: inherit;
  font-size: 1rem;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary-color);
}

/* Footer */
.footer {
  background-color: var(--dark-color);
  color: #fff;
  text-align: center;
  padding: 1rem 0;
}

/* Animations */
.animate {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.animate.show {
  opacity: 1;
  transform: translateY(0);
}

/* Responsive styles */
@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  .navbar {
    background-color: var(--dark-color);
  }
  .hero {
    height: 80vh;
  }
  .hero-content h1 {
    font-size: 2rem;
  }
  .about-wrapper {
    flex-direction: column;
  }
  .contact-wrapper {
    flex-direction: column;
  }
  #slide-img {
    height: 300px;
  }
}

/* Features section styling */
.features .feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.feature-card {
  background-color: #fff;
  border-radius: 8px;
  padding: 1.5rem;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);
  text-align: center;
  transition: transform 0.3s ease;
}

.feature-card:hover {
  transform: translateY(-6px);
}

.feature-card img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  border-radius: 4px;
  margin-bottom: 1rem;
}

.feature-card h3 {
  margin-top: 0;
  margin-bottom: 0.5rem;
  font-size: 1.25rem;
  color: var(--primary-color);
}

.feature-card p {
  font-size: 0.95rem;
  color: #555;
}

/* Directional animations for features */
.animate-left, .animate-right {
  opacity: 0;
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.animate-left {
  transform: translateX(-40px);
}

.animate-right {
  transform: translateX(40px);
}

.animate-left.show,
.animate-right.show {
  opacity: 1;
  transform: translateX(0);
}

/* Scale in animation for images and cards */
.animate-zoom {
  opacity: 0;
  transform: scale(0.8);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.animate-zoom.show {
  opacity: 1;
  transform: scale(1);
}