/*
  services.css - Unique, modern enhancements for the Services page
  - Glassmorphism, gradients, advanced animations, and premium UI
  - Fully responsive and dark mode ready
*/

/* Glassy, floating service cards with flip and neon glow on hover */
.services-wrapper .service-card {
  background: rgba(255,255,255,0.18);
  box-shadow: 0 8px 32px rgba(0,51,102,0.18), 0 1.5px 8px rgba(230,103,34,0.08);
  border-radius: 1.5rem;
  border: 1.5px solid rgba(255,255,255,0.25);
  backdrop-filter: blur(18px);
  position: relative;
  overflow: visible;
  transition: box-shadow 0.4s, transform 0.4s, border-color 0.3s;
  will-change: transform, box-shadow;
  perspective: 1200px;
}
.services-wrapper .service-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 1.5rem;
  pointer-events: none;
  box-shadow: 0 0 32px 8px var(--accent, #E67E22);
  opacity: 0;
  transition: opacity 0.4s;
  z-index: 2;
}
.services-wrapper .service-card:hover {
  transform: translateY(-12px) scale(1.04) rotateY(8deg);
  box-shadow: 0 16px 48px rgba(0,51,102,0.22), 0 2px 16px rgba(230,103,34,0.12);
  border-color: var(--accent, #E67E22);
}
.services-wrapper .service-card:hover::after {
  opacity: 0.18;
}
/* Card flip animation on hover */
.services-wrapper .service-card .card-content {
  transition: transform 0.7s cubic-bezier(.4,0,.2,1);
  transform-style: preserve-3d;
}
.services-wrapper .service-card:hover .card-content {
  transform: rotateY(8deg) scale(1.03);
}
/* Neon animated border on active card */
.services-wrapper .service-card.active {
  box-shadow: 0 0 0 4px var(--accent, #E67E22), 0 16px 48px rgba(0,51,102,0.22);
  animation: neon-glow 1.5s infinite alternate;
}
@keyframes neon-glow {
  from { box-shadow: 0 0 0 4px var(--accent, #E67E22), 0 16px 48px rgba(0,51,102,0.22); }
  to { box-shadow: 0 0 0 8px #fff176, 0 16px 48px rgba(0,51,102,0.22); }
}
/* Floating animation for cards */
.services-wrapper .service-card {
  animation: floatCard 5s ease-in-out infinite alternate;
  animation-delay: calc(var(--i, 0) * 0.2s);
}
@keyframes floatCard {
  0% { transform: translateY(0) scale(1); }
  100% { transform: translateY(-10px) scale(1.02); }
}
/* Staggered fade/slide-in for cards */
.services-wrapper .service-card {
  opacity: 0;
  transform: translateY(40px) scale(0.98);
  animation: cardIn 1.1s cubic-bezier(.4,0,.2,1) forwards;
  animation-delay: calc(var(--i, 0) * 0.18s + 0.2s);
}
@keyframes cardIn {
  to { opacity: 1; transform: translateY(0) scale(1); }
}
/* Unique category button with animated gradient border */
.service-categories .category-btn {
  border: 2.5px solid transparent;
  background: rgba(255,255,255,0.12);
  color: var(--primary, #003366);
  font-weight: 700;
  border-radius: 2.5rem;
  position: relative;
  overflow: hidden;
  z-index: 1;
  box-shadow: 0 2px 12px rgba(0,51,102,0.07);
  transition: color 0.3s, box-shadow 0.3s, border-color 0.3s;
}
.service-categories .category-btn::before {
  content: '';
  position: absolute;
  inset: -2px;
  border-radius: 2.5rem;
  background: linear-gradient(90deg, #003366, #E67E22, #003366);
  background-size: 200% 200%;
  z-index: -1;
  opacity: 0.7;
  transition: opacity 0.3s;
  animation: gradientBorder 3s linear infinite;
}
@keyframes gradientBorder {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}
.service-categories .category-btn:hover,
.service-categories .category-btn.active {
  color: #fff;
  border-color: var(--accent, #E67E22);
  box-shadow: 0 4px 18px rgba(230,103,34,0.13);
}
.service-categories .category-btn:hover::before,
.service-categories .category-btn.active::before {
  opacity: 1;
}
.service-categories .category-btn.active {
  background: #fff;
  color: #003366;
  border-color: var(--accent, #E67E22);
  box-shadow: 0 4px 18px rgba(230,103,34,0.13);
  z-index: 2;
}
.service-categories .category-btn.active::before {
  opacity: 1;
}
/* Section backgrounds with animated gradient overlay */
.services-hero, .services-grid {
  position: relative;
  z-index: 1;
}
.services-hero::after, .services-grid::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(120deg, #003366 0%, #E67E22 100%);
  opacity: 0.08;
  pointer-events: none;
  animation: bgMove 12s linear infinite alternate;
}
@keyframes bgMove {
  0% { background-position: 0% 0%; }
  100% { background-position: 100% 100%; }
}
/* Services grid spacing */
.services-grid {
  background: linear-gradient(120deg, #f8fafc 0%, #e6f0fa 100%);
  padding: 3.5rem 0 2.5rem 0;
  min-height: 100vh;
}
.services-wrapper {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  align-items: stretch;
  gap: 3.5rem 2.5rem;
  max-width: 1100px;
  margin: 0 auto;
  justify-content: center;
}
@media (max-width: 900px) {
  .services-wrapper {
    grid-template-columns: 1fr;
    gap: 2.2rem;
    max-width: 98vw;
    padding: 0 1rem;
  }
  .services-grid {
    padding: 2.5rem 0;
  }
  .card-content {
    padding: 2rem 1.5rem;
    min-height: 280px;
  }
  .service-card h3 {
    font-size: 1.2rem;
  }
  .service-card p {
    font-size: 1rem;
  }
}
@media (max-width: 600px) {
  html, body {
    overflow-x: hidden;
  }
  .container,
  .services-grid,
  .pricing-grid,
  .pricing-comparison {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100vw;
    max-width: 100vw;
    padding: 0;
    margin: 0;
    box-sizing: border-box;
  }
  .services-wrapper {
    width: 100%;
    max-width: 100vw;
    padding: 0;
    margin: 0 auto;
    grid-template-columns: 1fr;
    gap: 0.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  .service-card,
  .pricing-card {
    width: 100%;
    max-width: 400px;
    margin: 0 0 1rem 0;
    box-sizing: border-box;
    border-radius: 1rem;
  }
  .card-content {
    padding: 0.7rem 0.1rem 0.6rem 0.1rem;
    width: 100%;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .services-hero h1,
  .pricing-comparison h2 {
    font-size: 1.2rem;
    word-break: normal;
    white-space: normal;
    text-align: center;
    line-height: 1.2;
  }
  .pricing-comparison p {
    text-align: center;
    font-size: 0.98rem;
    margin-bottom: 1rem;
  }
  .pricing-grid {
    display: block;
    flex-direction: unset;
    align-items: unset;
  }
  .pricing-card {
    width: 100%;
    max-width: 400px;
    margin: 0 auto 1rem auto;
    padding: 1.2rem 1.2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    border-radius: 1rem;
    box-sizing: border-box;
  }
  .pricing-features {
    width: 100%;
    text-align: left;
    padding-left: 1.2rem;
    margin: 0.8rem 0;
    box-sizing: border-box;
  }
  .pricing-features li {
    text-align: left;
    margin-bottom: 0.5rem;
    font-size: 0.98rem;
    word-break: break-word;
  }
  #navbar .container {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    height: 60px;
    padding: 0 1rem;
  }
  .logo {
    display: flex;
    align-items: center;
    font-size: 1.3rem;
    font-weight: bold;
  }
  .menu-btn {
    display: block;
    font-size: 2rem;
    margin-left: auto;
  }
  .popular-badge {
    position: static !important;
    display: block !important;
    margin: 0 auto 0.5rem auto !important;
    width: max-content !important;
    text-align: center !important;
    font-size: 0.95rem !important;
    left: unset !important;
    top: unset !important;
    transform: none !important;
  }
  .pricing-toggle {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: 0.7rem;
    margin: 1.2rem 0 0.5rem 0;
    width: 100%;
    position: relative;
  }
  .pricing-toggle > span {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 1.05rem;
  }
  .pricing-toggle .save-badge {
    display: block;
    margin: 0.2rem 0 0 0;
    font-size: 0.8rem;
    padding: 0.18rem 0.7rem;
    border-radius: 0.9rem;
    width: auto;
    min-width: 60px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(230,103,34,0.08);
  }
  .pricing-comparison h2 {
    margin-bottom: 0.2rem;
  }
  .pricing-comparison p {
    margin-top: 1.2rem;
  }
}
@media (min-width: 1200px) {
  .services-wrapper {
    grid-template-columns: repeat(3, 1fr);
    gap: 2.5rem;
    max-width: 1200px;
  }
  .card-content {
    padding: 2.5rem;
  }
}
.services-wrapper .service-card {
  margin: 0;
  border-radius: 2.2rem;
  box-shadow: 0 12px 40px rgba(0,51,102,0.13), 0 2px 16px rgba(230,103,34,0.10);
  background: rgba(255,255,255,0.22);
  transition: box-shadow 0.5s, transform 0.5s, border-color 0.3s;
  position: relative;
  overflow: visible;
  height: 100%;
  min-height: 100%;
  display: flex;
  flex-direction: column;
}
.services-wrapper .service-card:not(:nth-child(-n+2)) {
  box-shadow: 0 24px 48px -16px rgba(0,51,102,0.10), 0 2px 16px rgba(230,103,34,0.10);
}
.services-wrapper .service-card:hover {
  transform: translateY(-18px) scale(1.045) rotateY(6deg);
  box-shadow: 0 24px 64px 0 rgba(230,103,34,0.18), 0 8px 32px rgba(0,51,102,0.18);
  border-color: #E67E22;
}
.card-content {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  height: 100%;
  min-height: 100%;
  padding: 2.7rem 2.3rem 2.3rem 2.3rem;
  overflow-y: auto;
}
.icon-wrapper {
  margin-bottom: 1.1rem;
}
.stat-badge {
  margin-bottom: 1.1rem;
}
.service-card h3 {
  margin-bottom: 0.7rem;
}
.service-card p {
  margin-bottom: 0.5rem;
}
.service-features {
  margin-bottom: 1.1rem;
  margin-top: 0.5rem;
}
.testimonial-reveal {
  font-size: 0.97rem;
  padding: 0.7rem 1rem;
  margin-top: 0.7rem;
  min-height: unset;
  max-width: 95%;
  box-shadow: 0 2px 8px rgba(0,51,102,0.07);
}
/* Dark mode enhancements */
body.dark .services-wrapper .service-card {
  background: rgba(35,39,43,0.85);
  border-color: #23272b;
  box-shadow: 0 8px 32px rgba(0,0,0,0.28);
}
body.dark .services-wrapper .service-card.active {
  box-shadow: 0 0 0 4px #E67E22, 0 16px 48px rgba(0,0,0,0.22);
}
body.dark .service-categories .category-btn {
  background: #23272b;
  color: #fff;
}
body.dark .service-categories .category-btn.active,
body.dark .service-categories .category-btn:hover {
  color: #fff;
  border-color: #E67E22;
}
/* Service card heading and main text color for clarity */
.services-wrapper .service-card h3 {
  color: #003366;
  font-weight: 700;
  margin-bottom: 0.5rem;
}
.services-wrapper .service-card p {
  color: #222b3a;
  font-size: 1.08rem;
  margin-bottom: 0.5rem;
}
.services-wrapper .service-card .client-value {
  color: #E67E22;
  font-size: 1.01rem;
  font-weight: 600;
  margin-bottom: 0.7rem;
}
/* Feature tags: bold, brand color, pill style */
.services-wrapper .service-features span {
  color: #003366;
  background: #e6f0fa;
  font-weight: 600;
  border-radius: 2rem;
  padding: 0.4rem 1.1rem;
  margin-right: 0.3rem;
  margin-bottom: 0.2rem;
  display: inline-block;
  font-size: 0.98rem;
  letter-spacing: 0.01em;
  box-shadow: 0 1px 4px rgba(0,51,102,0.07);
  transition: background 0.2s, color 0.2s;
}
.services-wrapper .service-features span:hover {
  background: #003366;
  color: #fff;
}
/* Dark mode adjustments */
body.dark .services-wrapper .service-card h3,
body.dark .services-wrapper .service-features span {
  color: #fff;
}
body.dark .services-wrapper .service-features span {
  background: #003366;
}
body.dark .services-wrapper .service-card .client-value {
  color: #ffb366;
}
/* Stat badge for service cards */
.stat-badge {
  position: absolute;
  top: 1.1rem;
  right: 1.1rem;
  background: linear-gradient(90deg, #E67E22 60%, #003366 100%);
  color: #fff;
  font-weight: 700;
  font-size: 0.98rem;
  padding: 0.38rem 1.1rem;
  border-radius: 2rem;
  box-shadow: 0 2px 8px rgba(230,103,34,0.13);
  z-index: 3;
  letter-spacing: 0.01em;
  pointer-events: none;
}
body.dark .stat-badge {
  background: linear-gradient(90deg, #003366 60%, #E67E22 100%);
  color: #fff;
}
/* Testimonial reveal on card hover */
.testimonial-reveal {
  opacity: 0;
  pointer-events: none;
  position: absolute;
  left: 1.5rem;
  right: 1.5rem;
  bottom: 1.2rem;
  background: rgba(255,255,255,0.97);
  color: #003366;
  border-radius: 1rem;
  box-shadow: 0 4px 24px rgba(0,51,102,0.10);
  padding: 1rem 1.2rem;
  font-size: 1.01rem;
  font-style: italic;
  font-weight: 500;
  transform: translateY(20px);
  transition: opacity 0.4s, transform 0.4s;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 0.7rem;
}
.service-card:hover .testimonial-reveal {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}
body.dark .testimonial-reveal {
  background: #23272b;
  color: #fff;
}
/* Why Choose Us section */
.why-choose-us {
  margin: 5rem 0 3rem;
  padding: 3rem 0 2rem;
  background: rgba(255,255,255,0.18);
  border-radius: 2rem;
  box-shadow: 0 8px 32px rgba(0,51,102,0.10);
  backdrop-filter: blur(12px);
  text-align: center;
  position: relative;
}
.why-choose-us h2 {
  color: #003366;
  font-size: 2.2rem;
  margin-bottom: 2rem;
  font-weight: 800;
}
.reasons-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: center;
}
.reason {
  background: rgba(230,103,34,0.08);
  color: #003366;
  font-weight: 600;
  font-size: 1.08rem;
  border-radius: 1.2rem;
  padding: 1.1rem 2rem;
  min-width: 220px;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  box-shadow: 0 2px 12px rgba(0,51,102,0.07);
  transition: background 0.2s, color 0.2s;
}
.reason i {
  font-size: 1.5rem;
  color: #E67E22;
}
body.dark .why-choose-us {
  background: rgba(35,39,43,0.85);
}
body.dark .why-choose-us h2,
body.dark .reason {
  color: #fff;
}
body.dark .reason {
  background: #003366;
}
/* Staggered animation for feature tags */
.services-wrapper .service-features span {
  opacity: 0;
  transform: translateY(12px);
  animation: featureIn 0.6s cubic-bezier(.4,0,.2,1) forwards;
}
.services-wrapper .service-features span:nth-child(1) { animation-delay: 0.1s; }
.services-wrapper .service-features span:nth-child(2) { animation-delay: 0.25s; }
.services-wrapper .service-features span:nth-child(3) { animation-delay: 0.4s; }
@keyframes featureIn {
  to { opacity: 1; transform: translateY(0); }
}
/* Ripple effect for .btn-secondary */
.btn-secondary {
  position: relative;
  overflow: hidden;
}
.btn-secondary:active::after {
  content: '';
  position: absolute;
  left: 50%; top: 50%;
  width: 0; height: 0;
  background: rgba(230,103,34,0.18);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  animation: ripple 0.5s linear;
  z-index: 2;
}
@keyframes ripple {
  to {
    width: 220%; height: 220%; opacity: 0;
  }
}
.we-solve {
  display: block;
  max-width: 90%;
  min-width: 220px;
  margin: 0.7rem auto;
  text-align: center;
  background: linear-gradient(90deg, #e6f0fa 60%, #fff 100%);
  color: #E67E22;
  font-weight: 700;
  font-size: 1.08rem;
  border-radius: 1.5rem;
  padding: 0.38rem 1.5rem;
  letter-spacing: 0.01em;
  box-shadow: 0 1px 4px rgba(230,103,34,0.07);
}
body.dark .we-solve {
  background: linear-gradient(90deg, #003366 60%, #23272b 100%);
  color: #ffb366;
}
