/* ===== Dark Mode ===== */
body.dark .hero-section {
  color: #e4e4e4; /* softer white text */
}

body.dark .hero-section .overlay {
  background: rgba(0, 0, 0, 0.75); /* slightly darker for better contrast */
}

body.dark .hero-section .btn-primary {
  background: linear-gradient(135deg, #6c5ce7, #00cec9); /* accent gradient */
  border: none;
}

body.dark .hero-section .btn-outline-light {
  border-color: #e4e4e4;
  color: #e4e4e4;
}

body.dark .hero-section .btn-outline-light:hover {
  background: rgba(228, 228, 228, 0.1);
}

.expertise-section {
  position: relative;
  background: linear-gradient(135deg, #0d1117, #161b22);
  overflow: hidden;
  color: #fff;
}

/* Floating background images */
.floating-bg .float-img {
  position: absolute;
  width: 60px;
  opacity: 0.2;
  animation: floatAnim 20s infinite linear;
}
@keyframes floatAnim {
  from { transform: translateY(0); }
  to { transform: translateY(-100vh); }
}

/* Expertise circles */
.expertise-item {
  position: relative;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  overflow: hidden;
  cursor: pointer;
  box-shadow: 0 0 25px rgba(0,0,0,0.4);
  transition: transform 0.4s ease;
}
.expertise-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  transition: transform 0.5s ease;
}
.expertise-item:hover img {
  transform: scale(1.2);
}
.expertise-content {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.65);
  color: #fff;
  border-radius: 50%;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s ease, visibility 0.4s ease;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 1rem;
}
.expertise-item:hover .expertise-content {
  opacity: 1;
  visibility: visible;
}
.expertise-title {
  font-size: 1.25rem;
  font-weight: 700;
}
.expertise-desc {
  font-size: 0.9rem;
  margin-top: 0.5rem;
  color: #ddd;
}

.services-sphere {
  position: relative;
  background: linear-gradient(135deg, #0d1117, #111827, #1f2937);
  overflow: hidden;
  color: #fff;
  min-height: 100vh;
}
.sphere-bg::before {
  content: "";
  position: absolute;
  width: 200%;
  height: 200%;
  top: -50%;
  left: -50%;
  background: radial-gradient(circle, rgba(0,224,255,0.2) 0%, transparent 70%);
  animation: spinBg 20s linear infinite;
}
@keyframes spinBg {
  100% { transform: rotate(360deg); }
}

/* Sphere */
.sphere {
  position: relative;
  width: 500px;
  height: 500px;
  margin: 0 auto;
  perspective: 1200px;
  transform-style: preserve-3d;
  animation: rotateSphere 30s infinite linear;
}
@keyframes rotateSphere {
  from { transform: rotateY(0deg) rotateX(10deg); }
  to { transform: rotateY(360deg) rotateX(10deg); }
}
.sphere.paused { animation-play-state: paused; }

/* Service nodes */
.service-node {
  position: absolute;
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(5px);
  box-shadow: 0 0 20px rgba(0,224,255,0.5);
  overflow: hidden;
  transition: transform 0.5s ease, box-shadow 0.3s ease;
  cursor: pointer;
}
.service-node img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
}

/* Floating card */
.service-card-floating {
  position: absolute;
  bottom: 10%;
  left: 50%;
  transform: translateX(-50%) translateY(50px);
  background: rgba(0,0,0,0.85);
  padding: 1.5rem;
  border-radius: 15px;
  width: 350px;
  max-width: 90%;
  opacity: 0;
  pointer-events: none;
  box-shadow: 0 0 30px rgba(0,224,255,0.6);
  transition: opacity 0.4s ease, transform 0.4s ease;
}
.service-card-floating.active {
  opacity: 1;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}
.service-card-floating h3 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
}
.service-card-floating p {
  font-size: 0.9rem;
  color: #bbb;
  margin-bottom: 1rem;
}
.feature-card {
  background: #fff;
  border-radius: 1rem;
  box-shadow: 0 8px 20px rgba(0,0,0,0.08);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  opacity: 0;
  transform: translateY(40px);
}
.feature-card:hover {
  transform: translateY(-10px) scale(1.03);
  box-shadow: 0 12px 30px rgba(0,183,255,0.2);
}

/* Animate on scroll */
[data-animate="fade-up"].show {
  opacity: 1;
  transform: translateY(0);
  transition: all 0.8s ease var(--delay, 0s);
}

/* Dark mode */
body.dark .feature-card {
  background: #161b22;
  color: #f0f6fc!important;
  border: 1px solid rgba(0,183,255,0.2);
}
body.dark .feature-card:hover {
  box-shadow: 0 12px 30px rgba(0,183,255,0.4);
}

/* Dark mode overrides */
body.dark .feature-card {
  background: #161b22;
  color: #f0f6fc; /* default text color */
  border: 1px solid rgba(0,183,255,0.2);
}

/* Make muted text readable in dark mode */
body.dark .feature-card p,
body.dark .feature-card .text-muted {
  color: #9fb3c8 !important; /* softer light gray-blue */
}

/* Headings inside cards */
body.dark .feature-card h5 {
  color: #ffffff;
  font-weight: 600;
}
.testimonial-card {
  max-width: 700px;
  padding: 2rem;
  background: rgba(255,255,255,0.05);
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,0.1);
  transition: all 0.4s ease;
}
.testimonial-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 0 25px rgba(0, 183, 255, 0.4);
}
.testimonial-text {
  font-size: 1.2rem;
  font-style: italic;
  color: #e5e7eb;
}
.testimonial-name {
  margin-top: 1rem;
  font-weight: 600;
  color: #fff;
}
.testimonial-role {
  font-size: 0.9rem;
  color: #9ca3af;
}
.carousel-control-prev-icon,
.carousel-control-next-icon {
  filter: invert(1) grayscale(100);
}
.services-list{
   background: linear-gradient(135deg, #0d1117, #111827, #1f2937)!important;
}
.services-list .service-item p{
  color: white!important;
}

  .services-list .service-item {
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.1);
    padding: 1.5rem;
    border-radius: 12px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
  }
  .services-list .service-item:hover {
    background: rgba(255,255,255,0.15);
    transform: translateY(-5px);
  }
  .services-list img {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    margin-bottom: 1rem;
    object-fit: cover;
  }

/* Flip Card Styles */
.flip-card {
  perspective: 1000px;
  height: 220px;
}
.flip-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.7s;
  transform-style: preserve-3d;
}
.flip-card:hover .flip-card-inner {
  transform: rotateY(180deg);
}
.flip-card-front, .flip-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  backface-visibility: hidden;
}
.flip-card-front {
  background: linear-gradient(135deg, #0d6efd, #00bfff);
  color: #fff;
  font-weight: bold;
}
.flip-card-back {
  background: #212529;
  color: #fff;
  transform: rotateY(180deg);
  text-align: center;
  border: 1px solid rgba(255,255,255,0.1);
}
body.dark .flip-card-back {
  background: #161b22;
}