/*
* NisonCo AI Services - Custom Styles
* A modern, professional stylesheet for the NisonCo AI Services website
*/

:root {
  /* Main color scheme - NisonCo Brand Colors */
  /* Primary Colors */
  --primary: #6cc6ac; /* Teal Green */
  --primary-dark: #0e3b7d; /* Navy Blue */
  --primary-light: #a3e0cf; /* Light Teal */
  --secondary: #5f83ff; /* Periwinkle Blue */
  --accent: #7550c8; /* Royal Purple */
  
  /* Secondary Colors */
  --light: #f7f8fa; /* Light Gray */
  --dark: #333740; /* Dark Gray */
  --white: #ffffff; /* White */
  
  /* Accent Colors */
  --accent-light: #b69fef; /* Soft Lavender */
  --accent-dark: #3a5fd9; /* Deep Blue */
  
  /* Standard Function Colors */
  --success: #28a745;
  --info: #5f83ff; /* Using Periwinkle Blue for info */
  --warning: #ffc107;
  --danger: #dc3545;
  
  /* Text */
  --text-primary: #333740; /* Dark Gray */
  --text-secondary: #6c757d;
  --text-light: #f7f8fa; /* Light Gray */
  
  /* Spacing */
  --section-spacing: 5rem;
  --component-spacing: 2.5rem;
}

/* Base styles */
body {
  font-family: 'Inter', 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  margin-bottom: 1rem;
  line-height: 1.3;
}

p {
  margin-bottom: 1.5rem;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.3s ease;
}

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

section {
  padding: 5rem 0;
}

/* Utility classes */
.bg-primary {
  background-color: var(--primary) !important;
}

.bg-light {
  background-color: var(--light) !important;
}

.bg-dark {
  background-color: var(--dark) !important;
}

.text-primary {
  color: var(--primary) !important;
}

.btn-primary {
  background-color: var(--primary);
  border-color: var(--primary);
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  border-radius: 4px;
  transition: all 0.3s ease;
}

.btn-primary:hover {
  background-color: #56b096; /* Darker Teal */
  border-color: #56b096;
}

.btn-secondary {
  background-color: var(--secondary);
  border-color: var(--secondary);
  color: white;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  border-radius: 4px;
  transition: all 0.3s ease;
}

.btn-secondary:hover {
  background-color: #4a6de6; /* Darker Periwinkle */
  border-color: #4a6de6;
}

.btn-accent {
  background-color: var(--accent);
  border-color: var(--accent);
  color: white;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  border-radius: 4px;
  transition: all 0.3s ease;
}

.btn-accent:hover {
  background-color: #634ab0; /* Darker Royal Purple */
  border-color: #634ab0;
}

.btn-navy {
  background-color: var(--primary-dark);
  border-color: var(--primary-dark);
  color: white;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  border-radius: 4px;
  transition: all 0.3s ease;
}

.btn-navy:hover {
  background-color: #0b2f64; /* Darker Navy */
  border-color: #0b2f64;
  border-color: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.btn-outline-primary {
  color: var(--primary);
  border-color: var(--primary);
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  border-radius: 4px;
  transition: all 0.3s ease;
}

.btn-outline-primary:hover {
  background-color: var(--primary);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* This class was duplicated and is now removed */

.btn-lg {
  padding: 1rem 2rem;
  font-size: 1.125rem;
}

/* Newsletter Card */
.newsletter-card {
  background: linear-gradient(135deg, rgba(95, 131, 255, 0.1) 0%, rgba(108, 198, 172, 0.05) 100%);
  padding: 3.5rem;
  border-radius: 12px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
  position: relative;
  overflow: hidden;
  border: none;
}

.newsletter-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 5px;
  background: linear-gradient(90deg, var(--primary) 0%, var(--secondary) 100%);
}

.newsletter-card::after {
  content: "";
  position: absolute;
  bottom: 0;
  right: 0;
  width: 120px;
  height: 120px;
  background-color: rgba(108, 198, 172, 0.05);
  border-radius: 50%;
  z-index: 0;
}

.newsletter-icon {
  width: 90px;
  height: 90px;
  background: linear-gradient(135deg, var(--secondary) 0%, var(--primary) 100%);
  color: white;
  border-radius: 50%;
  font-size: 2.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 2rem;
  box-shadow: 0 10px 25px rgba(95, 131, 255, 0.3);
  position: relative;
  z-index: 1;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.newsletter-card:hover .newsletter-icon {
  transform: translateY(-5px) scale(1.05);
  box-shadow: 0 15px 35px rgba(95, 131, 255, 0.4);
}

.newsletter-card h3 {
  color: var(--primary-dark);
  font-weight: 700;
  margin-bottom: 1.5rem;
  position: relative;
  z-index: 1;
}

.newsletter-card p {
  color: var(--text-secondary);
  font-size: 1.1rem;
  line-height: 1.6;
  margin-bottom: 2rem;
  position: relative;
  z-index: 1;
}

.newsletter-card .form-control {
  padding: 0.75rem 1.5rem;
  height: auto;
  border-radius: 8px;
  font-size: 1.05rem;
  border: 1px solid rgba(0, 0, 0, 0.1);
  background-color: rgba(255, 255, 255, 0.9);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.03);
  transition: all 0.3s ease;
}

.newsletter-card .form-control:focus {
  border-color: var(--secondary);
  box-shadow: 0 0 0 0.25rem rgba(95, 131, 255, 0.25);
}

.newsletter-card .btn-primary {
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  background: linear-gradient(90deg, var(--primary) 0%, var(--secondary) 100%);
  border: none;
  box-shadow: 0 10px 20px rgba(95, 131, 255, 0.25);
  transition: all 0.3s ease;
}

.newsletter-card .btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 15px 30px rgba(95, 131, 255, 0.35);
  background: linear-gradient(90deg, var(--secondary) 0%, var(--primary) 100%);
}

.shadow-sm {
  box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075) !important;
}

.shadow {
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15) !important;
}

.rounded {
  border-radius: 0.5rem !important;
}

.rounded-lg {
  border-radius: 1rem !important;
}

/* Navigation */
.navbar {
  padding: 1rem 0;
  transition: all 0.3s ease;
}

.navbar-brand {
  font-weight: 700;
  font-size: 1.75rem;
  color: var(--primary);
}

.navbar-nav .nav-link {
  font-weight: 600;
  padding: 0.5rem 1rem !important;
  transition: all 0.3s ease;
}

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

.navbar-nav .nav-item.active .nav-link {
  color: var(--primary);
}

/* Style different nav items with different colors */
.navbar-nav .nav-item:nth-child(1) .nav-link:hover,
.navbar-nav .nav-item:nth-child(1).active .nav-link {
  color: var(--primary); /* Teal Green */
}

.navbar-nav .nav-item:nth-child(2) .nav-link:hover,
.navbar-nav .nav-item:nth-child(2).active .nav-link {
  color: var(--secondary); /* Periwinkle Blue */
}

.navbar-nav .nav-item:nth-child(3) .nav-link:hover,
.navbar-nav .nav-item:nth-child(3).active .nav-link {
  color: var(--accent); /* Royal Purple */
}

.navbar-nav .nav-item:nth-child(4) .nav-link:hover,
.navbar-nav .nav-item:nth-child(4).active .nav-link {
  color: var(--primary-dark); /* Navy Blue */
}

.navbar-toggler {
  border: none;
  padding: 0.5rem;
}

.navbar-toggler:focus {
  outline: none;
  box-shadow: none;
}

.navbar.scrolled {
  background-color: white !important;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  padding: 0.75rem 0;
}

.navbar-cta {
  margin-left: 1rem;
}

/* Hero section */
.hero {
  position: relative;
  padding: 8rem 0;
  background: linear-gradient(135deg, var(--primary-light, #a3e0cf) 0%, var(--light, #f7f8fa) 100%);
  overflow: hidden;
}

/* Increased top padding for hero section on mobile devices */
@media (max-width: 768px) {
  .hero {
    padding-top: 13rem; /* Add more top padding on mobile to prevent content cut-off */
  }
}

/* Extra padding for extra small devices */
@media (max-width: 576px) {
  .hero {
    padding-top: 14rem; /* Even more padding for small mobile devices */
  }
}

/* Alternate hero style with different gradient */
.hero.alt-style {
  background: linear-gradient(135deg, rgba(95, 131, 255, 0.1) 0%, rgba(117, 80, 200, 0.05) 100%);
}

.hero-content {
  position: relative;
  z-index: 2;
}

.hero h1 {
  font-size: 3.5rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
  line-height: 1.2;
}

.hero p {
  font-size: 1.25rem;
  margin-bottom: 2rem;
}

/* Responsive font sizes for hero section */
@media (max-width: 992px) {
  .hero h1 {
    font-size: 3rem;
  }
}

@media (max-width: 768px) {
  .hero h1 {
    font-size: 2.5rem;
    margin-top: 1.5rem; /* Add more top margin on mobile */
  }
  
  .hero p {
    font-size: 1.1rem;
  }
  
  .hero-content {
    padding-top: 1rem; /* Add some top padding to the content */
  }
}

.hero-image {
  position: relative;
  z-index: 1;
}

.hero-image img {
  max-width: 100%;
  border-radius: 10px;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

/* Services section */
.services {
  padding: 2rem 0 5rem; /* Reduced top padding to close gap */
  background: linear-gradient(135deg, var(--light) 0%, rgba(163, 224, 207, 0.2) 100%); /* Light teal gradient */
}

@media (max-width: 768px) {
  .services {
    padding: 1.5rem 0;
  }
  
  /* Fix the spacing on category sections for mobile */
  .category-section {
    margin-top: 0;
    padding-top: 0;
  }
  
  .category-section:first-child {
    margin-top: 0;
  }
  
  .category-title {
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
  }
  
  /* Adjust page header spacing on mobile */
  .page-header {
    padding: 1rem 0 0.5rem;
  }
  
  .page-header .display-4 {
    font-size: 2rem;
    margin-top: 0;
  }
  
  .page-header .lead {
    font-size: 1rem;
    margin-bottom: 0.5rem;
  }
}

.service-card {
  height: 100%;
  padding: 2.5rem;
  border-radius: 10px;
  background: white;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  border-top: 3px solid var(--primary); /* Default to Teal accent border */
  border-left: 1px solid rgba(0, 0, 0, 0.05);
  border-right: 1px solid rgba(0, 0, 0, 0.05);
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

@media (max-width: 768px) {
  .service-card {
    padding: 1.5rem;
  }
}

.service-card:nth-child(4n+1) {
  border-top-color: var(--primary); /* Teal Green */
}

.service-card:nth-child(4n+2) {
  border-top-color: var(--secondary); /* Periwinkle Blue */
}

.service-card:nth-child(4n+3) {
  border-top-color: var(--accent); /* Royal Purple */
}

.service-card:nth-child(4n+4) {
  border-top-color: var(--primary-dark); /* Navy Blue */
}

/* Styling for "Who We Serve" icons */
.who-we-serve .service-card .process-icon {
  width: 100px;
  height: 100px;
  background-color: var(--secondary); /* Default to Periwinkle Blue instead of Teal */
  color: white;
  font-size: 2.5rem;
  margin: 0 auto 1.5rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
}

.who-we-serve .service-card:nth-child(1) .process-icon {
  background-color: var(--secondary); /* Periwinkle Blue */
  box-shadow: 0 10px 20px rgba(95, 131, 255, 0.3);
}

.who-we-serve .service-card:nth-child(2) .process-icon {
  background-color: var(--primary-dark); /* Navy Blue */
  box-shadow: 0 10px 20px rgba(14, 59, 125, 0.3);
}

.who-we-serve .service-card:nth-child(3) .process-icon {
  background-color: var(--secondary); /* Periwinkle Blue */
  box-shadow: 0 10px 20px rgba(95, 131, 255, 0.3);
}

.service-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
}

.service-card img {
  margin-bottom: 1.5rem;
  max-width: 100%;
  border-radius: 5px;
}

.service-card h3 {
  margin-bottom: 1rem;
  font-weight: 700;
}

.service-card p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

/* Process section */
.process {
  padding: 5rem 0;
  background-color: var(--light);
}

.process-step {
  text-align: center;
  padding: 2rem;
}

.process-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 1.5rem;
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

.process-step:nth-child(1) .process-icon {
  background: var(--secondary, #5f83ff); /* Periwinkle Blue */
  box-shadow: 0 10px 20px rgba(95, 131, 255, 0.3);
}

.process-step:nth-child(2) .process-icon {
  background: var(--secondary, #5f83ff); /* Periwinkle Blue */
  box-shadow: 0 10px 20px rgba(95, 131, 255, 0.3);
}

.process-step:nth-child(3) .process-icon {
  background: var(--primary-dark, #0e3b7d); /* Navy Blue */
  box-shadow: 0 10px 20px rgba(14, 59, 125, 0.3);
}

.process-step:nth-child(4) .process-icon {
  background: var(--primary, #6cc6ac); /* Teal Green */
  box-shadow: 0 10px 20px rgba(108, 198, 172, 0.3);
}

.process-step h3 {
  margin-bottom: 1rem;
  font-weight: 700;
}

.process-step p {
  color: var(--text-secondary);
}

/* Industries section */
.industries {
  padding: 5rem 0;
}

.industries .process-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 1.5rem;
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

.industries .service-card:nth-child(6n+1) .process-icon {
  background: var(--secondary); /* Periwinkle Blue */
  box-shadow: 0 10px 20px rgba(95, 131, 255, 0.3);
}

.industries .service-card:nth-child(6n+2) .process-icon {
  background: var(--primary-dark); /* Navy Blue */
  box-shadow: 0 10px 20px rgba(14, 59, 125, 0.3);
}

.industries .service-card:nth-child(6n+3) .process-icon {
  background: var(--accent); /* Royal Purple */
  box-shadow: 0 10px 20px rgba(117, 80, 200, 0.3);
}

.industries .service-card:nth-child(6n+4) .process-icon {
  background: var(--primary); /* Teal Green */
  box-shadow: 0 10px 20px rgba(108, 198, 172, 0.3);
}

.industries .service-card:nth-child(6n+5) .process-icon {
  background: var(--secondary); /* Periwinkle Blue */
  box-shadow: 0 10px 20px rgba(95, 131, 255, 0.3);
}

.industries .service-card:nth-child(6n+6) .process-icon {
  background: var(--primary-dark); /* Navy Blue */
  box-shadow: 0 10px 20px rgba(14, 59, 125, 0.3);
}

/* Testimonials */
.testimonials {
  padding: 5rem 0;
}

/* Blog section on homepage */
.blog-section {
  padding: 5rem 0;
  background-color: #fff;
}

/* Blog card styling */
.blog-card {
  background: white;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
  border-top: 3px solid var(--primary);
}

.blog-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
}

.blog-image {
  position: relative;
  overflow: hidden;
}

.blog-image img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.blog-card:hover .blog-image img {
  transform: scale(1.05);
}

.blog-content {
  padding: 1.5rem;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}

.blog-meta {
  color: var(--text-secondary);
  font-size: 0.85rem;
}

.blog-meta span {
  margin-right: 1rem;
}

.blog-meta i {
  margin-right: 0.3rem;
  color: var(--primary);
}

.blog-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  line-height: 1.4;
  margin-top: 0.5rem;
}

.blog-card p {
  color: var(--text-secondary);
  margin: 0.5rem 0;
  flex-grow: 1;
}

.blog-card .btn {
  align-self: flex-start;
  margin-top: auto;
}

.testimonial-card {
  padding: 2.5rem;
  border-radius: 10px;
  background: white;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
  border: 1px solid rgba(0, 0, 0, 0.05);
  margin-bottom: 2rem;
  position: relative;
  overflow: hidden;
  height: 100%;
}

.testimonial-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background-color: var(--secondary); /* Default to Periwinkle Blue instead of teal */
}

.testimonial-card:nth-child(3n+1)::before {
  background-color: var(--secondary); /* Periwinkle Blue */
}

.testimonial-card:nth-child(3n+2)::before {
  background-color: var(--accent); /* Royal Purple */
}

.testimonial-card:nth-child(3n+3)::before {
  background-color: var(--primary-dark); /* Navy Blue */
}

.testimonial-content {
  font-size: 1.1rem;
  font-style: italic;
  margin-bottom: 1.5rem;
  position: relative;
}

.testimonial-content p {
  font-size: 1.1rem;
  line-height: 1.6;
  margin-bottom: 0.5rem;
}

.quote-icon {
  font-size: 1.5rem;
  color: var(--primary-light);
  opacity: 0.5;
  margin-bottom: 1rem;
  display: block;
}

.testimonial-author {
  display: flex;
  align-items: center;
  border-top: 1px solid rgba(0, 0, 0, 0.05);
  padding-top: 1.2rem;
  margin-top: 1.2rem;
}

.testimonial-author-image {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  overflow: hidden;
  margin-right: 1rem;
}

.testimonial-author-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.testimonial-author-info h4 {
  margin-bottom: 0.25rem;
  font-weight: 700;
  color: var(--primary-dark);
}

.testimonial-author-info p {
  color: var(--text-secondary);
  margin-bottom: 0;
  font-size: 0.9rem;
}

/* Case Studies */
.case-study-card {
  padding: 2.5rem;
  border-radius: 10px;
  background: white;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
  border: 1px solid rgba(0, 0, 0, 0.05);
  margin-bottom: 2rem;
  position: relative;
  overflow: hidden;
  height: 100%;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.case-study-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
}

.case-study-card h4 {
  color: var(--primary-dark);
  margin-bottom: 1rem;
  font-weight: 700;
  display: flex;
  align-items: center;
}

.case-study-card h4 i {
  color: var(--secondary);
  margin-right: 0.5rem;
}

.case-study-card p {
  margin-bottom: 1.5rem;
  color: var(--text-secondary);
}

.case-study-results {
  display: flex;
  justify-content: space-around;
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(0, 0, 0, 0.05);
}

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

.result-number {
  display: block;
  font-size: 2rem;
  font-weight: 700;
  color: var(--secondary);
  margin-bottom: 0.5rem;
}

.result-label {
  display: block;
  font-size: 0.9rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* CTA sections */
.cta {
  padding: 5rem 0;
  background-color: var(--accent, #7550c8); /* Royal Purple */
  color: white;
  text-align: center;
  background-image: linear-gradient(135deg, #7550c8 0%, #5f83ff 100%); /* Purple to Periwinkle gradient */
}

.cta h2 {
  margin-bottom: 1.5rem;
  font-weight: 700;
}

.cta p {
  margin-bottom: 2rem;
  font-size: 1.2rem;
  opacity: 0.9;
}

.cta .btn {
  padding: 1rem 2rem;
  font-size: 1.2rem;
  margin-top: 1rem;
}

/* About section */
.about {
  padding: 5rem 0;
}

.about-image {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.about-image img {
  width: 100%;
}

.about-content h2 {
  margin-bottom: 1.5rem;
  font-weight: 700;
}

.about-content p {
  margin-bottom: 1.5rem;
}

/* Blog */
.blog {
  padding: 2rem 0 5rem; /* Reduced top padding to close gap */
  background-color: var(--light);
}

.blog-card {
  height: 100%;
  border-radius: 10px;
  overflow: hidden;
  background: white;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  margin-bottom: 2.5rem; /* Increased spacing between blog cards */
  position: relative;
  display: flex;
  flex-direction: column; /* Enable vertical layout */
}

/* Add colored borders to the bottom of blog cards */
.blog-card::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background-color: var(--primary); /* Default to teal */
}

.blog-card:nth-child(4n+1)::after {
  background-color: var(--primary); /* Teal Green */
}

.blog-card:nth-child(4n+2)::after {
  background-color: var(--secondary); /* Periwinkle Blue */
}

.blog-card:nth-child(4n+3)::after {
  background-color: var(--accent); /* Royal Purple */
}

.blog-card:nth-child(4n+4)::after {
  background-color: var(--primary-dark); /* Navy Blue */
}

.blog-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
}

.blog-image {
  position: relative;
  height: 0;
  padding-bottom: 66.67%; /* 3:2 aspect ratio (2/3 = 0.6667) */
  overflow: hidden;
}

.blog-image img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.blog-card:hover .blog-image img {
  transform: scale(1.05);
}

.blog-content {
  padding: 1.75rem; /* Increased from 1.5rem */
  display: flex;
  flex-direction: column;
  flex-grow: 1; /* Allow content to expand to fill space */
}

.blog-content h3 {
  margin-bottom: 1rem;
  font-weight: 700;
  font-size: 1.25rem;
  line-height: 1.4; /* Improved line height for better readability */
  color: var(--primary-dark); /* Changed color for better contrast */
}

.blog-content p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  flex-grow: 1; /* Allow paragraph to take up available space */
  font-size: 0.95rem; /* Slightly smaller for better spacing */
  line-height: 1.6; /* Improved line height */
}

.blog-meta {
  display: flex;
  align-items: center;
  font-size: 0.85rem; /* Slightly smaller */
  color: var(--text-secondary);
  margin-bottom: 0.75rem; /* Increased from 0.5rem */
  opacity: 0.8; /* Subtle appearance */
}

.blog-meta i {
  margin-right: 0.5rem;
  color: var(--primary); /* Accent color for icons */
}

.blog-meta span {
  margin-right: 1.25rem; /* Increased from 1rem */
}

/* Improve pagination styling */
.pagination {
  margin-top: 2rem;
}

.pagination .page-link {
  color: var(--primary-dark);
  border-color: var(--primary-light);
  margin: 0 0.25rem;
  border-radius: 4px;
  transition: all 0.3s ease;
}

.pagination .page-item.active .page-link {
  background-color: var(--primary);
  border-color: var(--primary);
}

.pagination .page-link:hover {
  background-color: var(--primary-light);
  color: var(--primary-dark);
}

/* Single blog post */
.blog-post {
  padding: 4rem 0 2rem !important;
}

/* Reduce blog post padding on mobile to account for fixed nav */
@media (max-width: 767.98px) {
  .blog-post {
    padding: 6rem 0 1rem !important;
    margin-top: 0 !important;
    padding-top: 6rem !important;
  }
  
  .blog-post-header,
  .blog-post-title {
    margin-top: 1rem !important;
    padding-top: 0.5rem !important;
  }
}

.blog-post-header {
  margin-bottom: 2rem;
}

/* Reduce blog header margin on mobile */
@media (max-width: 767.98px) {
  .blog-post-header {
    margin-bottom: 1.5rem;
  }
}

.blog-post-title {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
}

/* Adjust blog title size on mobile */
@media (max-width: 767.98px) {
  .blog-post-title {
    font-size: 2rem;
    margin-bottom: 1rem;
  }
}

.blog-post-meta {
  display: flex;
  align-items: center;
  font-size: 1rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.blog-post-meta i {
  margin-right: 0.5rem;
}

.blog-post-meta span {
  margin-right: 1.5rem;
}

.blog-featured-image {
  margin-bottom: 2rem;
  border-radius: 10px;
  overflow: hidden;
  position: relative;
  height: 0;
  padding-bottom: 66.67%; /* 3:2 aspect ratio */
}

.blog-featured-image img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.blog-post-content {
  font-size: 1.1rem;
  line-height: 1.8;
}

.blog-post-content h2 {
  margin-top: 2.5rem;
  margin-bottom: 1.5rem;
}

.blog-post-content h3 {
  margin-top: 2rem;
  margin-bottom: 1.25rem;
}

.blog-post-content p {
  margin-bottom: 1.5rem;
}

.blog-post-content ul,
.blog-post-content ol {
  margin-bottom: 1.5rem;
  padding-left: 2rem;
}

.blog-post-content li {
  margin-bottom: 0.5rem;
}

/* FAQs */
.faqs {
  padding: 5rem 0;
}

.faq-item {
  margin-bottom: 1.5rem;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.faq-question {
  background-color: white;
  padding: 1.5rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: all 0.3s ease;
}

.faq-question:after {
  content: '\f107';
  font-family: 'Font Awesome 5 Free';
  font-weight: 900;
  color: var(--primary);
}

.faq-answer {
  padding: 0 1.5rem;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
}

/* Default active state */
.faq-item.active .faq-question {
  background-color: var(--primary);
  color: white;
}

.faq-item.active .faq-question:after {
  content: '\f106';
  color: white;
}

/* Different colored FAQ items based on position */
.faq-item:nth-child(3n+1).active .faq-question {
  background-color: var(--secondary); /* Periwinkle Blue */
}

.faq-item:nth-child(3n+2).active .faq-question {
  background-color: var(--secondary); /* Periwinkle Blue */
}

.faq-item:nth-child(3n+3).active .faq-question {
  background-color: var(--primary-dark); /* Navy Blue */
}

.faq-item.active .faq-answer {
  padding: 1.5rem;
  max-height: 500px;
}

/* Contact */
.contact {
  padding: 5rem 0;
  background-color: var(--light);
}

.contact-info {
  margin-bottom: 3rem;
}

.contact-info h2 {
  margin-bottom: 1.5rem;
  font-weight: 700;
}

.contact-info p {
  margin-bottom: 1.5rem;
}

.contact-info-item {
  display: flex;
  align-items: flex-start;
  margin-bottom: 1.5rem;
}

.contact-info-icon {
  color: var(--primary);
  font-size: 1.5rem;
  margin-right: 1rem;
  margin-top: 0.25rem;
}

.contact-info-content h5 {
  margin-bottom: 0.5rem;
  font-weight: 700;
}

.contact-info-content p {
  margin-bottom: 0;
  color: var(--text-secondary);
}

.contact-form {
  background-color: white;
  padding: 3rem;
  border-radius: 10px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.contact-form h3 {
  margin-bottom: 1.5rem;
  font-weight: 700;
}

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

.form-control {
  height: auto;
  padding: 1rem;
  border: 1px solid #dee2e6;
  border-radius: 5px;
  font-size: 1rem;
}

/* Form control focus states with different colors */
.form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 0.2rem rgba(108, 198, 172, 0.25); /* Teal Green */
}

.form-group:nth-child(4n+2) .form-control:focus {
  border-color: var(--secondary);
  box-shadow: 0 0 0 0.2rem rgba(95, 131, 255, 0.25); /* Periwinkle Blue */
}

.form-group:nth-child(4n+3) .form-control:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 0.2rem rgba(117, 80, 200, 0.25); /* Royal Purple */
}

.form-group:nth-child(4n+4) .form-control:focus {
  border-color: var(--primary-dark);
  box-shadow: 0 0 0 0.2rem rgba(14, 59, 125, 0.25); /* Navy Blue */
}

/* Footer */
.footer {
  background-color: var(--dark);
  color: white;
  padding: 5rem 0 2rem;
}

.footer-logo {
  margin-bottom: 1.5rem;
}

.footer-about p {
  opacity: 0.8;
  margin-bottom: 1.5rem;
}

.footer-heading {
  font-weight: 700;
  margin-bottom: 1.5rem;
  color: white;
}

.footer-links {
  list-style: none;
  padding-left: 0;
  margin-bottom: 2rem;
}

.footer-links li {
  margin-bottom: 0.75rem;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.8);
  transition: all 0.3s ease;
}

.footer-links a:hover {
  color: white;
  text-decoration: none;
}

.footer-social {
  display: flex;
  margin-bottom: 2rem;
}

.footer-social a {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.1);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 1rem;
  transition: all 0.3s ease;
}

.footer-social a:hover {
  transform: translateY(-3px);
}

.footer-social a:nth-child(4n+1):hover {
  background-color: var(--primary); /* Teal Green */
}

.footer-social a:nth-child(4n+2):hover {
  background-color: var(--secondary); /* Periwinkle Blue */
}

.footer-social a:nth-child(4n+3):hover {
  background-color: var(--accent); /* Royal Purple */
}

.footer-social a:nth-child(4n+4):hover {
  background-color: var(--primary-dark); /* Navy Blue */
}

.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
}

.footer-bottom p {
  margin-bottom: 0;
  opacity: 0.7;
  font-size: 0.9rem;
}

/* Responsive styles */
@media (max-width: 991.98px) {
  .navbar-nav {
    background-color: white;
    padding: 1rem;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-top: 1rem;
  }
  
  .navbar-cta {
    margin-left: 0;
    margin-top: 0.5rem;
  }
  
  .hero {
    padding: 6rem 0;
  }
  
  .hero h1 {
    font-size: 2.5rem;
  }
  
  .hero-image {
    margin-top: 3rem;
  }
  
  section {
    padding: 4rem 0;
  }
}

@media (max-width: 767.98px) {
  body {
    font-size: 0.95rem;
  }
  
  h1 {
    font-size: 2.25rem;
  }
  
  h2 {
    font-size: 1.75rem;
  }
  
  .hero {
    padding: 4rem 0;
  }
  
  .hero h1 {
    font-size: 2rem;
  }
  
  .hero p {
    font-size: 1.1rem;
  }
  
  section {
    padding: 3rem 0;
  }
  
  .service-card,
  .testimonial-card,
  .contact-form {
    padding: 1.5rem;
  }
}

/* Animations */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Custom styling for service detail page */
.service-detail-header {
  padding: 4rem 0 2rem !important;
  background-color: var(--light);
  position: relative;
}

/* Reduce header padding on mobile to account for fixed nav */
@media (max-width: 767.98px) {
  .service-detail-header {
    padding: 6rem 0 1rem !important;
    margin-top: 0 !important;
    padding-top: 6rem !important;
  }
  
  .service-detail-header .display-4,
  .service-detail-header h1 {
    margin-top: 1rem !important;
    padding-top: 0.5rem !important;
  }
  
  /* Ensure all page headers have proper spacing on mobile */
  body {
    padding-top: 0 !important;
  }
  
  /* Services page specific mobile fixes */
  .page-header {
    padding: 6rem 0 1rem !important;
    margin-top: 0 !important;
  }
  
  .page-header .display-4,
  .page-header h1 {
    margin-top: 1rem !important;
    padding-top: 0.5rem !important;
  }
  
  .category-title {
    margin-top: 1rem !important;
  }
}

.service-detail-image {
  margin-bottom: 3rem;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
  position: relative;
  height: 0;
  padding-bottom: 66.67%; /* 3:2 aspect ratio */
}

.service-detail-image img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.service-detail-content {
  padding: 2rem 0 !important;
}

/* Reduce service content padding on mobile */
@media (max-width: 767.98px) {
  .service-detail-content {
    padding: 1.5rem 0 !important;
  }
}
